From c5fc66ee58f2c60f2d226868bb1cf5b91badaf53 Mon Sep 17 00:00:00 2001 From: sanine Date: Sat, 1 Oct 2022 20:59:36 -0500 Subject: add ode --- CMakeLists.txt | 3 +- demo/honey.lua | 5 +- libs/ode-0.16.1/CHANGELOG.txt | 1285 ++ libs/ode-0.16.1/CMakeLists.txt | 954 + libs/ode-0.16.1/COPYING | 32 + libs/ode-0.16.1/CSR.txt | 422 + libs/ode-0.16.1/GIMPACT/GIMPACT-LICENSE-BSD.TXT | 29 + libs/ode-0.16.1/GIMPACT/GIMPACT-LICENSE-LGPL.TXT | 502 + libs/ode-0.16.1/GIMPACT/Makefile.am | 4 + libs/ode-0.16.1/GIMPACT/Makefile.in | 641 + .../ode-0.16.1/GIMPACT/include/GIMPACT/Makefile.am | 6 + .../ode-0.16.1/GIMPACT/include/GIMPACT/Makefile.in | 533 + .../GIMPACT/include/GIMPACT/gim_boxpruning.h | 323 + .../GIMPACT/include/GIMPACT/gim_contact.h | 115 + .../GIMPACT/include/GIMPACT/gim_geometry.h | 1885 ++ libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_math.h | 164 + .../GIMPACT/include/GIMPACT/gim_memory.h | 1056 + .../GIMPACT/include/GIMPACT/gim_radixsort.h | 258 + .../include/GIMPACT/gim_tri_capsule_collision.h | 111 + .../GIMPACT/include/GIMPACT/gim_tri_collision.h | 253 + .../include/GIMPACT/gim_tri_sphere_collision.h | 51 + .../GIMPACT/include/GIMPACT/gim_trimesh.h | 544 + libs/ode-0.16.1/GIMPACT/include/GIMPACT/gimpact.h | 45 + libs/ode-0.16.1/GIMPACT/include/Makefile.am | 1 + libs/ode-0.16.1/GIMPACT/include/Makefile.in | 640 + libs/ode-0.16.1/GIMPACT/src/Makefile.am | 19 + libs/ode-0.16.1/GIMPACT/src/Makefile.in | 638 + libs/ode-0.16.1/GIMPACT/src/gim_boxpruning.cpp | 519 + libs/ode-0.16.1/GIMPACT/src/gim_contact.cpp | 132 + libs/ode-0.16.1/GIMPACT/src/gim_math.cpp | 60 + libs/ode-0.16.1/GIMPACT/src/gim_memory.cpp | 878 + .../ode-0.16.1/GIMPACT/src/gim_tri_tri_overlap.cpp | 251 + libs/ode-0.16.1/GIMPACT/src/gim_trimesh.cpp | 391 + .../GIMPACT/src/gim_trimesh_capsule_collision.cpp | 285 + .../GIMPACT/src/gim_trimesh_ray_collision.cpp | 149 + .../GIMPACT/src/gim_trimesh_sphere_collision.cpp | 196 + .../GIMPACT/src/gim_trimesh_trimesh_collision.cpp | 348 + libs/ode-0.16.1/GIMPACT/src/gimpact.cpp | 40 + libs/ode-0.16.1/INSTALL.txt | 173 + libs/ode-0.16.1/LICENSE-BSD.TXT | 34 + libs/ode-0.16.1/LICENSE.TXT | 502 + libs/ode-0.16.1/Makefile.am | 48 + libs/ode-0.16.1/Makefile.in | 941 + libs/ode-0.16.1/OPCODE/COPYING | 30 + libs/ode-0.16.1/OPCODE/Ice/IceAABB.cpp | 405 + libs/ode-0.16.1/OPCODE/Ice/IceAABB.h | 514 + libs/ode-0.16.1/OPCODE/Ice/IceAxes.h | 54 + libs/ode-0.16.1/OPCODE/Ice/IceBoundingSphere.h | 142 + libs/ode-0.16.1/OPCODE/Ice/IceContainer.cpp | 357 + libs/ode-0.16.1/OPCODE/Ice/IceContainer.h | 243 + libs/ode-0.16.1/OPCODE/Ice/IceFPU.h | 282 + libs/ode-0.16.1/OPCODE/Ice/IceHPoint.cpp | 70 + libs/ode-0.16.1/OPCODE/Ice/IceHPoint.h | 160 + libs/ode-0.16.1/OPCODE/Ice/IceIndexedTriangle.cpp | 548 + libs/ode-0.16.1/OPCODE/Ice/IceIndexedTriangle.h | 76 + libs/ode-0.16.1/OPCODE/Ice/IceLSS.h | 75 + libs/ode-0.16.1/OPCODE/Ice/IceMatrix3x3.cpp | 48 + libs/ode-0.16.1/OPCODE/Ice/IceMatrix3x3.h | 499 + libs/ode-0.16.1/OPCODE/Ice/IceMatrix4x4.cpp | 135 + libs/ode-0.16.1/OPCODE/Ice/IceMatrix4x4.h | 457 + libs/ode-0.16.1/OPCODE/Ice/IceMemoryMacros.h | 86 + libs/ode-0.16.1/OPCODE/Ice/IceOBB.cpp | 324 + libs/ode-0.16.1/OPCODE/Ice/IceOBB.h | 177 + libs/ode-0.16.1/OPCODE/Ice/IcePairs.h | 45 + libs/ode-0.16.1/OPCODE/Ice/IcePlane.cpp | 45 + libs/ode-0.16.1/OPCODE/Ice/IcePlane.h | 113 + libs/ode-0.16.1/OPCODE/Ice/IcePoint.cpp | 191 + libs/ode-0.16.1/OPCODE/Ice/IcePoint.h | 530 + libs/ode-0.16.1/OPCODE/Ice/IcePreprocessor.h | 132 + libs/ode-0.16.1/OPCODE/Ice/IceRandom.cpp | 35 + libs/ode-0.16.1/OPCODE/Ice/IceRandom.h | 42 + libs/ode-0.16.1/OPCODE/Ice/IceRay.cpp | 84 + libs/ode-0.16.1/OPCODE/Ice/IceRay.h | 98 + libs/ode-0.16.1/OPCODE/Ice/IceRevisitedRadix.cpp | 520 + libs/ode-0.16.1/OPCODE/Ice/IceRevisitedRadix.h | 65 + libs/ode-0.16.1/OPCODE/Ice/IceSegment.cpp | 57 + libs/ode-0.16.1/OPCODE/Ice/IceSegment.h | 55 + libs/ode-0.16.1/OPCODE/Ice/IceTriList.h | 61 + libs/ode-0.16.1/OPCODE/Ice/IceTriangle.cpp | 286 + libs/ode-0.16.1/OPCODE/Ice/IceTriangle.h | 68 + libs/ode-0.16.1/OPCODE/Ice/IceTypes.h | 161 + libs/ode-0.16.1/OPCODE/Ice/IceUtils.cpp | 39 + libs/ode-0.16.1/OPCODE/Ice/IceUtils.h | 259 + libs/ode-0.16.1/OPCODE/Ice/Makefile.am | 20 + libs/ode-0.16.1/OPCODE/Ice/Makefile.in | 660 + libs/ode-0.16.1/OPCODE/Makefile.am | 45 + libs/ode-0.16.1/OPCODE/Makefile.in | 807 + libs/ode-0.16.1/OPCODE/OPC_AABBCollider.cpp | 696 + libs/ode-0.16.1/OPCODE/OPC_AABBCollider.h | 97 + libs/ode-0.16.1/OPCODE/OPC_AABBTree.cpp | 568 + libs/ode-0.16.1/OPCODE/OPC_AABBTree.h | 137 + libs/ode-0.16.1/OPCODE/OPC_BaseModel.cpp | 119 + libs/ode-0.16.1/OPCODE/OPC_BaseModel.h | 199 + libs/ode-0.16.1/OPCODE/OPC_BoxBoxOverlap.h | 122 + libs/ode-0.16.1/OPCODE/OPC_Collider.cpp | 54 + libs/ode-0.16.1/OPCODE/OPC_Collider.h | 176 + libs/ode-0.16.1/OPCODE/OPC_Common.cpp | 48 + libs/ode-0.16.1/OPCODE/OPC_Common.h | 101 + libs/ode-0.16.1/OPCODE/OPC_HybridModel.cpp | 467 + libs/ode-0.16.1/OPCODE/OPC_HybridModel.h | 106 + libs/ode-0.16.1/OPCODE/OPC_IceHook.h | 80 + libs/ode-0.16.1/OPCODE/OPC_LSSAABBOverlap.h | 525 + libs/ode-0.16.1/OPCODE/OPC_LSSCollider.cpp | 725 + libs/ode-0.16.1/OPCODE/OPC_LSSCollider.h | 99 + libs/ode-0.16.1/OPCODE/OPC_LSSTriOverlap.h | 679 + libs/ode-0.16.1/OPCODE/OPC_MeshInterface.cpp | 393 + libs/ode-0.16.1/OPCODE/OPC_MeshInterface.h | 280 + libs/ode-0.16.1/OPCODE/OPC_Model.cpp | 222 + libs/ode-0.16.1/OPCODE/OPC_Model.h | 65 + libs/ode-0.16.1/OPCODE/OPC_OBBCollider.cpp | 767 + libs/ode-0.16.1/OPCODE/OPC_OBBCollider.h | 142 + libs/ode-0.16.1/OPCODE/OPC_OptimizedTree.cpp | 795 + libs/ode-0.16.1/OPCODE/OPC_OptimizedTree.h | 206 + libs/ode-0.16.1/OPCODE/OPC_Picking.cpp | 183 + libs/ode-0.16.1/OPCODE/OPC_Picking.h | 45 + libs/ode-0.16.1/OPCODE/OPC_PlanesAABBOverlap.h | 50 + libs/ode-0.16.1/OPCODE/OPC_PlanesCollider.cpp | 653 + libs/ode-0.16.1/OPCODE/OPC_PlanesCollider.h | 122 + libs/ode-0.16.1/OPCODE/OPC_PlanesTriOverlap.h | 40 + libs/ode-0.16.1/OPCODE/OPC_RayAABBOverlap.h | 63 + libs/ode-0.16.1/OPCODE/OPC_RayCollider.cpp | 764 + libs/ode-0.16.1/OPCODE/OPC_RayCollider.h | 224 + libs/ode-0.16.1/OPCODE/OPC_RayTriOverlap.h | 89 + libs/ode-0.16.1/OPCODE/OPC_Settings.h | 49 + libs/ode-0.16.1/OPCODE/OPC_SphereAABBOverlap.h | 128 + libs/ode-0.16.1/OPCODE/OPC_SphereCollider.cpp | 739 + libs/ode-0.16.1/OPCODE/OPC_SphereCollider.h | 96 + libs/ode-0.16.1/OPCODE/OPC_SphereTriOverlap.h | 187 + libs/ode-0.16.1/OPCODE/OPC_TreeBuilders.cpp | 306 + libs/ode-0.16.1/OPCODE/OPC_TreeBuilders.h | 178 + libs/ode-0.16.1/OPCODE/OPC_TreeCollider.cpp | 947 + libs/ode-0.16.1/OPCODE/OPC_TreeCollider.h | 246 + libs/ode-0.16.1/OPCODE/OPC_TriBoxOverlap.h | 339 + libs/ode-0.16.1/OPCODE/OPC_TriTriOverlap.h | 299 + libs/ode-0.16.1/OPCODE/OPC_VolumeCollider.cpp | 103 + libs/ode-0.16.1/OPCODE/OPC_VolumeCollider.h | 138 + libs/ode-0.16.1/OPCODE/Opcode.cpp | 82 + libs/ode-0.16.1/OPCODE/Opcode.h | 126 + libs/ode-0.16.1/OPCODE/README-ODE.txt | 13 + libs/ode-0.16.1/OPCODE/ReadMe.txt | 171 + libs/ode-0.16.1/OPCODE/Stdafx.h | 24 + libs/ode-0.16.1/OPCODE/TemporalCoherence.txt | 32 + libs/ode-0.16.1/README.md | 34 + libs/ode-0.16.1/aclocal.m4 | 1158 + libs/ode-0.16.1/bindings/python/INSTALL.txt | 64 + libs/ode-0.16.1/bindings/python/TODO.txt | 15 + libs/ode-0.16.1/bindings/python/demos/tutorial1.py | 49 + libs/ode-0.16.1/bindings/python/demos/tutorial2.py | 135 + libs/ode-0.16.1/bindings/python/demos/tutorial3.py | 284 + libs/ode-0.16.1/bindings/python/ode.pxd | 503 + libs/ode-0.16.1/bindings/python/ode.pyx | 4506 ++++ libs/ode-0.16.1/bindings/python/setup.py | 48 + libs/ode-0.16.1/bootstrap | 28 + libs/ode-0.16.1/build/config-default.h | 113 + libs/ode-0.16.1/build/premake4.exe | Bin 0 -> 261632 bytes libs/ode-0.16.1/build/premake4.lua | 590 + libs/ode-0.16.1/cmake/cmake_uninstall.cmake.in | 17 + libs/ode-0.16.1/compile | 347 + libs/ode-0.16.1/config.guess | 1441 ++ libs/ode-0.16.1/config.h.cmake.in | 109 + libs/ode-0.16.1/config.sub | 1813 ++ libs/ode-0.16.1/configure | 21593 +++++++++++++++++++ libs/ode-0.16.1/configure.ac | 605 + libs/ode-0.16.1/depcomp | 791 + libs/ode-0.16.1/drawstuff/Makefile.am | 4 + libs/ode-0.16.1/drawstuff/Makefile.in | 641 + libs/ode-0.16.1/drawstuff/dstest/Makefile.am | 14 + libs/ode-0.16.1/drawstuff/dstest/Makefile.in | 614 + libs/ode-0.16.1/drawstuff/dstest/dstest.cpp | 125 + libs/ode-0.16.1/drawstuff/src/Makefile.am | 26 + libs/ode-0.16.1/drawstuff/src/Makefile.in | 655 + libs/ode-0.16.1/drawstuff/src/drawstuff.cpp | 1671 ++ libs/ode-0.16.1/drawstuff/src/internal.h | 50 + libs/ode-0.16.1/drawstuff/src/osx.cpp | 347 + libs/ode-0.16.1/drawstuff/src/resource.h | 28 + libs/ode-0.16.1/drawstuff/src/resources.rc | 153 + libs/ode-0.16.1/drawstuff/src/windows.cpp | 536 + libs/ode-0.16.1/drawstuff/src/x11.cpp | 459 + libs/ode-0.16.1/drawstuff/textures/checkered.ppm | Bin 0 -> 9760 bytes libs/ode-0.16.1/drawstuff/textures/ground.ppm | 6 + libs/ode-0.16.1/drawstuff/textures/sky.ppm | 5 + libs/ode-0.16.1/drawstuff/textures/wood.ppm | 5 + libs/ode-0.16.1/include/Makefile.am | 1 + libs/ode-0.16.1/include/Makefile.in | 640 + libs/ode-0.16.1/include/drawstuff/Makefile.am | 2 + libs/ode-0.16.1/include/drawstuff/Makefile.in | 528 + libs/ode-0.16.1/include/drawstuff/drawstuff.h | 325 + libs/ode-0.16.1/include/drawstuff/version.h | 29 + libs/ode-0.16.1/include/ode/Makefile.am | 34 + libs/ode-0.16.1/include/ode/Makefile.in | 642 + libs/ode-0.16.1/include/ode/README | 18 + libs/ode-0.16.1/include/ode/collision.h | 1526 ++ libs/ode-0.16.1/include/ode/collision_space.h | 182 + libs/ode-0.16.1/include/ode/collision_trimesh.h | 316 + libs/ode-0.16.1/include/ode/common.h | 568 + libs/ode-0.16.1/include/ode/compatibility.h | 40 + libs/ode-0.16.1/include/ode/contact.h | 110 + libs/ode-0.16.1/include/ode/cooperative.h | 229 + libs/ode-0.16.1/include/ode/error.h | 63 + libs/ode-0.16.1/include/ode/export-dif.h | 40 + libs/ode-0.16.1/include/ode/mass.h | 144 + libs/ode-0.16.1/include/ode/matrix.h | 200 + libs/ode-0.16.1/include/ode/matrix_coop.h | 291 + libs/ode-0.16.1/include/ode/memory.h | 59 + libs/ode-0.16.1/include/ode/misc.h | 86 + libs/ode-0.16.1/include/ode/objects.h | 3396 +++ libs/ode-0.16.1/include/ode/ode.h | 56 + libs/ode-0.16.1/include/ode/odeconfig.h | 218 + libs/ode-0.16.1/include/ode/odecpp.h | 1355 ++ libs/ode-0.16.1/include/ode/odecpp_collision.h | 467 + libs/ode-0.16.1/include/ode/odeinit.h | 236 + libs/ode-0.16.1/include/ode/odemath.h | 545 + libs/ode-0.16.1/include/ode/odemath_legacy.h | 162 + libs/ode-0.16.1/include/ode/precision.h | 16 + libs/ode-0.16.1/include/ode/precision.h.in | 16 + libs/ode-0.16.1/include/ode/rotation.h | 70 + libs/ode-0.16.1/include/ode/threading.h | 412 + libs/ode-0.16.1/include/ode/threading_impl.h | 292 + libs/ode-0.16.1/include/ode/timer.h | 76 + libs/ode-0.16.1/include/ode/version.h | 6 + libs/ode-0.16.1/include/ode/version.h.in | 6 + libs/ode-0.16.1/install-sh | 501 + libs/ode-0.16.1/libccd/BSD-LICENSE | 44 + libs/ode-0.16.1/libccd/Makefile.am | 6 + libs/ode-0.16.1/libccd/Makefile.in | 804 + libs/ode-0.16.1/libccd/README | 72 + libs/ode-0.16.1/libccd/aclocal.m4 | 10200 +++++++++ libs/ode-0.16.1/libccd/bootstrap | 12 + libs/ode-0.16.1/libccd/configure | 18785 ++++++++++++++++ libs/ode-0.16.1/libccd/configure.ac | 50 + libs/ode-0.16.1/libccd/src/Makefile.am | 22 + libs/ode-0.16.1/libccd/src/Makefile.in | 744 + libs/ode-0.16.1/libccd/src/alloc.c | 38 + libs/ode-0.16.1/libccd/src/ccd.c | 955 + libs/ode-0.16.1/libccd/src/ccd/alloc.h | 52 + libs/ode-0.16.1/libccd/src/ccd/ccd.h | 148 + libs/ode-0.16.1/libccd/src/ccd/compiler.h | 61 + libs/ode-0.16.1/libccd/src/ccd/dbg.h | 65 + libs/ode-0.16.1/libccd/src/ccd/list.h | 155 + libs/ode-0.16.1/libccd/src/ccd/polytope.h | 322 + libs/ode-0.16.1/libccd/src/ccd/precision.h.in | 14 + libs/ode-0.16.1/libccd/src/ccd/quat.h | 231 + libs/ode-0.16.1/libccd/src/ccd/simplex.h | 104 + libs/ode-0.16.1/libccd/src/ccd/support.h | 57 + libs/ode-0.16.1/libccd/src/ccd/vec3.h | 340 + libs/ode-0.16.1/libccd/src/config.h.in | 97 + libs/ode-0.16.1/libccd/src/custom/ccdcustom/quat.h | 69 + libs/ode-0.16.1/libccd/src/custom/ccdcustom/vec3.h | 114 + libs/ode-0.16.1/libccd/src/mpr.c | 572 + libs/ode-0.16.1/libccd/src/polytope.c | 287 + libs/ode-0.16.1/libccd/src/support.c | 39 + libs/ode-0.16.1/libccd/src/testsuites/Makefile.am | 28 + libs/ode-0.16.1/libccd/src/testsuites/Makefile.in | 753 + libs/ode-0.16.1/libccd/src/testsuites/bench.c | 257 + libs/ode-0.16.1/libccd/src/testsuites/bench2.c | 263 + libs/ode-0.16.1/libccd/src/testsuites/boxbox.c | 467 + libs/ode-0.16.1/libccd/src/testsuites/boxbox.h | 32 + libs/ode-0.16.1/libccd/src/testsuites/boxcyl.c | 162 + libs/ode-0.16.1/libccd/src/testsuites/boxcyl.h | 16 + libs/ode-0.16.1/libccd/src/testsuites/common.c | 174 + libs/ode-0.16.1/libccd/src/testsuites/common.h | 14 + libs/ode-0.16.1/libccd/src/testsuites/cu/COPYING | 674 + .../libccd/src/testsuites/cu/COPYING.LESSER | 165 + .../libccd/src/testsuites/cu/Makefile.am | 6 + .../libccd/src/testsuites/cu/Makefile.in | 587 + libs/ode-0.16.1/libccd/src/testsuites/cu/cu.c | 387 + libs/ode-0.16.1/libccd/src/testsuites/cu/cu.h | 164 + libs/ode-0.16.1/libccd/src/testsuites/cylcyl.c | 180 + libs/ode-0.16.1/libccd/src/testsuites/cylcyl.h | 29 + libs/ode-0.16.1/libccd/src/testsuites/main.c | 32 + libs/ode-0.16.1/libccd/src/testsuites/mpr_boxbox.c | 500 + libs/ode-0.16.1/libccd/src/testsuites/mpr_boxbox.h | 26 + libs/ode-0.16.1/libccd/src/testsuites/mpr_boxcyl.c | 165 + libs/ode-0.16.1/libccd/src/testsuites/mpr_boxcyl.h | 16 + libs/ode-0.16.1/libccd/src/testsuites/mpr_cylcyl.c | 179 + libs/ode-0.16.1/libccd/src/testsuites/mpr_cylcyl.h | 23 + libs/ode-0.16.1/libccd/src/testsuites/polytope.c | 398 + libs/ode-0.16.1/libccd/src/testsuites/polytope.h | 24 + .../libccd/src/testsuites/spheresphere.c | 99 + .../libccd/src/testsuites/spheresphere.h | 24 + libs/ode-0.16.1/libccd/src/testsuites/support.c | 85 + libs/ode-0.16.1/libccd/src/testsuites/support.h | 102 + libs/ode-0.16.1/libccd/src/testsuites/vec3.c | 273 + libs/ode-0.16.1/libccd/src/testsuites/vec3.h | 20 + libs/ode-0.16.1/libccd/src/vec3.c | 215 + libs/ode-0.16.1/ltmain.sh | 11156 ++++++++++ libs/ode-0.16.1/m4/libtool.m4 | 8388 +++++++ libs/ode-0.16.1/m4/ltoptions.m4 | 437 + libs/ode-0.16.1/m4/ltsugar.m4 | 124 + libs/ode-0.16.1/m4/ltversion.m4 | 23 + libs/ode-0.16.1/m4/lt~obsolete.m4 | 99 + libs/ode-0.16.1/m4/pkg.m4 | 157 + libs/ode-0.16.1/missing | 215 + libs/ode-0.16.1/ode-config.cmake.in | 13 + libs/ode-0.16.1/ode-config.in | 53 + libs/ode-0.16.1/ode.pc.in | 12 + libs/ode-0.16.1/ode/Makefile.am | 6 + libs/ode-0.16.1/ode/Makefile.in | 643 + libs/ode-0.16.1/ode/README | 158 + libs/ode-0.16.1/ode/TODO | 698 + libs/ode-0.16.1/ode/demo/Makefile.am | 75 + libs/ode-0.16.1/ode/demo/Makefile.in | 1133 + libs/ode-0.16.1/ode/demo/basket_geom.h | 599 + libs/ode-0.16.1/ode/demo/bunny_geom.h | 1366 ++ libs/ode-0.16.1/ode/demo/convex_bunny_geom.h | 468 + libs/ode-0.16.1/ode/demo/convex_prism.h | 28 + libs/ode-0.16.1/ode/demo/demo_I.cpp | 253 + libs/ode-0.16.1/ode/demo/demo_basket.cpp | 276 + libs/ode-0.16.1/ode/demo/demo_boxstack.cpp | 619 + libs/ode-0.16.1/ode/demo/demo_buggy.cpp | 308 + libs/ode-0.16.1/ode/demo/demo_cards.cpp | 237 + libs/ode-0.16.1/ode/demo/demo_chain1.c | 171 + libs/ode-0.16.1/ode/demo/demo_chain2.cpp | 165 + libs/ode-0.16.1/ode/demo/demo_collision.cpp | 1463 ++ libs/ode-0.16.1/ode/demo/demo_convex.cpp | 307 + libs/ode-0.16.1/ode/demo/demo_crash.cpp | 652 + libs/ode-0.16.1/ode/demo/demo_cyl.cpp | 321 + libs/ode-0.16.1/ode/demo/demo_cylvssphere.cpp | 240 + libs/ode-0.16.1/ode/demo/demo_dball.cpp | 194 + libs/ode-0.16.1/ode/demo/demo_dhinge.cpp | 217 + libs/ode-0.16.1/ode/demo/demo_feedback.cpp | 312 + libs/ode-0.16.1/ode/demo/demo_friction.cpp | 205 + libs/ode-0.16.1/ode/demo/demo_gyro2.cpp | 210 + libs/ode-0.16.1/ode/demo/demo_gyroscopic.cpp | 258 + libs/ode-0.16.1/ode/demo/demo_heightfield.cpp | 714 + libs/ode-0.16.1/ode/demo/demo_hinge.cpp | 165 + libs/ode-0.16.1/ode/demo/demo_jointPR.cpp | 434 + libs/ode-0.16.1/ode/demo/demo_jointPU.cpp | 735 + libs/ode-0.16.1/ode/demo/demo_joints.cpp | 1090 + libs/ode-0.16.1/ode/demo/demo_kinematic.cpp | 239 + libs/ode-0.16.1/ode/demo/demo_motion.cpp | 527 + libs/ode-0.16.1/ode/demo/demo_motor.cpp | 209 + libs/ode-0.16.1/ode/demo/demo_moving_convex.cpp | 415 + libs/ode-0.16.1/ode/demo/demo_moving_trimesh.cpp | 677 + libs/ode-0.16.1/ode/demo/demo_ode.cpp | 1380 ++ libs/ode-0.16.1/ode/demo/demo_piston.cpp | 813 + libs/ode-0.16.1/ode/demo/demo_plane2d.cpp | 304 + libs/ode-0.16.1/ode/demo/demo_rfriction.cpp | 258 + libs/ode-0.16.1/ode/demo/demo_slider.cpp | 171 + libs/ode-0.16.1/ode/demo/demo_space.cpp | 232 + libs/ode-0.16.1/ode/demo/demo_space_stress.cpp | 449 + libs/ode-0.16.1/ode/demo/demo_step.cpp | 192 + libs/ode-0.16.1/ode/demo/demo_tracks.cpp | 498 + libs/ode-0.16.1/ode/demo/demo_transmission.cpp | 414 + libs/ode-0.16.1/ode/demo/demo_trimesh.cpp | 605 + libs/ode-0.16.1/ode/demo/halton235_geom.h | 2271 ++ libs/ode-0.16.1/ode/demo/icosahedron_geom.h | 216 + libs/ode-0.16.1/ode/demo/texturepath.h | 26 + libs/ode-0.16.1/ode/demo/world_geom3.h | 9 + libs/ode-0.16.1/ode/doc/Doxyfile.in | 2331 ++ libs/ode-0.16.1/ode/doc/Makefile.am | 11 + libs/ode-0.16.1/ode/doc/Makefile.in | 472 + libs/ode-0.16.1/ode/doc/main.dox | 22 + libs/ode-0.16.1/ode/doc/pix/amotor.jpg | Bin 0 -> 13977 bytes .../ode-0.16.1/ode/doc/pix/ball-and-socket-bad.jpg | Bin 0 -> 9129 bytes libs/ode-0.16.1/ode/doc/pix/ball-and-socket.jpg | Bin 0 -> 10284 bytes libs/ode-0.16.1/ode/doc/pix/body.jpg | Bin 0 -> 15133 bytes libs/ode-0.16.1/ode/doc/pix/contact.jpg | Bin 0 -> 12368 bytes libs/ode-0.16.1/ode/doc/pix/hinge.jpg | Bin 0 -> 10548 bytes libs/ode-0.16.1/ode/doc/pix/hinge2.jpg | Bin 0 -> 14083 bytes libs/ode-0.16.1/ode/doc/pix/joints.jpg | Bin 0 -> 8637 bytes libs/ode-0.16.1/ode/doc/pix/rollingcontact.jpg | Bin 0 -> 12402 bytes libs/ode-0.16.1/ode/doc/pix/sf-graph1.jpg | Bin 0 -> 28191 bytes libs/ode-0.16.1/ode/doc/pix/sf-graph2.jpg | Bin 0 -> 24694 bytes libs/ode-0.16.1/ode/doc/pix/slider.jpg | Bin 0 -> 10276 bytes libs/ode-0.16.1/ode/doc/pix/universal.jpg | Bin 0 -> 13309 bytes libs/ode-0.16.1/ode/src/Makefile.am | 201 + libs/ode-0.16.1/ode/src/Makefile.in | 1100 + libs/ode-0.16.1/ode/src/array.cpp | 81 + libs/ode-0.16.1/ode/src/array.h | 135 + libs/ode-0.16.1/ode/src/box.cpp | 878 + libs/ode-0.16.1/ode/src/capsule.cpp | 416 + .../ode/src/collision_convex_trimesh.cpp | 120 + libs/ode-0.16.1/ode/src/collision_cylinder_box.cpp | 1038 + .../ode/src/collision_cylinder_plane.cpp | 266 + .../ode/src/collision_cylinder_sphere.cpp | 277 + .../ode/src/collision_cylinder_trimesh.cpp | 1171 + libs/ode-0.16.1/ode/src/collision_kernel.cpp | 1247 ++ libs/ode-0.16.1/ode/src/collision_kernel.h | 293 + libs/ode-0.16.1/ode/src/collision_libccd.cpp | 1080 + libs/ode-0.16.1/ode/src/collision_libccd.h | 44 + .../ode-0.16.1/ode/src/collision_quadtreespace.cpp | 609 + libs/ode-0.16.1/ode/src/collision_sapspace.cpp | 853 + libs/ode-0.16.1/ode/src/collision_space.cpp | 864 + libs/ode-0.16.1/ode/src/collision_space_internal.h | 80 + libs/ode-0.16.1/ode/src/collision_std.h | 238 + libs/ode-0.16.1/ode/src/collision_transform.cpp | 234 + libs/ode-0.16.1/ode/src/collision_transform.h | 39 + libs/ode-0.16.1/ode/src/collision_trimesh_box.cpp | 1380 ++ .../ode/src/collision_trimesh_ccylinder.cpp | 1183 + .../ode/src/collision_trimesh_colliders.h | 47 + .../ode/src/collision_trimesh_disabled.cpp | 302 + .../ode/src/collision_trimesh_gimpact.cpp | 424 + .../ode-0.16.1/ode/src/collision_trimesh_gimpact.h | 278 + .../ode/src/collision_trimesh_internal.cpp | 804 + .../ode/src/collision_trimesh_internal.h | 399 + .../ode/src/collision_trimesh_internal_impl.h | 463 + .../ode/src/collision_trimesh_opcode.cpp | 767 + libs/ode-0.16.1/ode/src/collision_trimesh_opcode.h | 333 + .../ode-0.16.1/ode/src/collision_trimesh_plane.cpp | 226 + libs/ode-0.16.1/ode/src/collision_trimesh_ray.cpp | 207 + .../ode/src/collision_trimesh_sphere.cpp | 596 + .../ode/src/collision_trimesh_trimesh.cpp | 1367 ++ .../ode/src/collision_trimesh_trimesh_old.cpp | 2071 ++ libs/ode-0.16.1/ode/src/collision_util.cpp | 613 + libs/ode-0.16.1/ode/src/collision_util.h | 358 + libs/ode-0.16.1/ode/src/common.h | 351 + libs/ode-0.16.1/ode/src/config.h.in | 329 + libs/ode-0.16.1/ode/src/convex.cpp | 1621 ++ libs/ode-0.16.1/ode/src/coop_matrix_types.h | 158 + libs/ode-0.16.1/ode/src/cylinder.cpp | 108 + libs/ode-0.16.1/ode/src/default_threading.cpp | 77 + libs/ode-0.16.1/ode/src/default_threading.h | 55 + libs/ode-0.16.1/ode/src/error.cpp | 179 + libs/ode-0.16.1/ode/src/error.h | 101 + libs/ode-0.16.1/ode/src/export-dif.cpp | 620 + libs/ode-0.16.1/ode/src/fastdot.cpp | 46 + libs/ode-0.16.1/ode/src/fastdot_impl.h | 51 + libs/ode-0.16.1/ode/src/fastldltfactor.cpp | 462 + libs/ode-0.16.1/ode/src/fastldltfactor_impl.h | 1530 ++ libs/ode-0.16.1/ode/src/fastldltsolve.cpp | 222 + libs/ode-0.16.1/ode/src/fastldltsolve_impl.h | 49 + libs/ode-0.16.1/ode/src/fastlsolve.cpp | 230 + libs/ode-0.16.1/ode/src/fastlsolve_impl.h | 1610 ++ libs/ode-0.16.1/ode/src/fastltsolve.cpp | 229 + libs/ode-0.16.1/ode/src/fastltsolve_impl.h | 1440 ++ libs/ode-0.16.1/ode/src/fastvecscale.cpp | 204 + libs/ode-0.16.1/ode/src/fastvecscale_impl.h | 171 + .../ode/src/gimpact_contact_export_helper.cpp | 95 + .../ode/src/gimpact_contact_export_helper.h | 177 + .../ode/src/gimpact_gim_contact_accessor.h | 62 + .../ode/src/gimpact_plane_contact_accessor.h | 62 + libs/ode-0.16.1/ode/src/heightfield.cpp | 1876 ++ libs/ode-0.16.1/ode/src/heightfield.h | 245 + libs/ode-0.16.1/ode/src/joints/Makefile.am | 37 + libs/ode-0.16.1/ode/src/joints/Makefile.in | 668 + libs/ode-0.16.1/ode/src/joints/amotor.cpp | 810 + libs/ode-0.16.1/ode/src/joints/amotor.h | 105 + libs/ode-0.16.1/ode/src/joints/ball.cpp | 186 + libs/ode-0.16.1/ode/src/joints/ball.h | 54 + libs/ode-0.16.1/ode/src/joints/contact.cpp | 361 + libs/ode-0.16.1/ode/src/joints/contact.h | 48 + libs/ode-0.16.1/ode/src/joints/dball.cpp | 314 + libs/ode-0.16.1/ode/src/joints/dball.h | 58 + libs/ode-0.16.1/ode/src/joints/dhinge.cpp | 220 + libs/ode-0.16.1/ode/src/joints/dhinge.h | 46 + libs/ode-0.16.1/ode/src/joints/fixed.cpp | 216 + libs/ode-0.16.1/ode/src/joints/fixed.h | 54 + libs/ode-0.16.1/ode/src/joints/hinge.cpp | 394 + libs/ode-0.16.1/ode/src/joints/hinge.h | 57 + libs/ode-0.16.1/ode/src/joints/hinge2.cpp | 546 + libs/ode-0.16.1/ode/src/joints/hinge2.h | 71 + libs/ode-0.16.1/ode/src/joints/joint.cpp | 931 + libs/ode-0.16.1/ode/src/joints/joint.h | 326 + libs/ode-0.16.1/ode/src/joints/joint_internal.h | 70 + libs/ode-0.16.1/ode/src/joints/joints.h | 48 + libs/ode-0.16.1/ode/src/joints/lmotor.cpp | 214 + libs/ode-0.16.1/ode/src/joints/lmotor.h | 51 + libs/ode-0.16.1/ode/src/joints/null.cpp | 74 + libs/ode-0.16.1/ode/src/joints/null.h | 46 + libs/ode-0.16.1/ode/src/joints/piston.cpp | 729 + libs/ode-0.16.1/ode/src/joints/piston.h | 112 + libs/ode-0.16.1/ode/src/joints/plane2d.cpp | 195 + libs/ode-0.16.1/ode/src/joints/plane2d.h | 54 + libs/ode-0.16.1/ode/src/joints/pr.cpp | 613 + libs/ode-0.16.1/ode/src/joints/pr.h | 100 + libs/ode-0.16.1/ode/src/joints/pu.cpp | 756 + libs/ode-0.16.1/ode/src/joints/pu.h | 88 + libs/ode-0.16.1/ode/src/joints/slider.cpp | 423 + libs/ode-0.16.1/ode/src/joints/slider.h | 59 + libs/ode-0.16.1/ode/src/joints/transmission.cpp | 698 + libs/ode-0.16.1/ode/src/joints/transmission.h | 51 + libs/ode-0.16.1/ode/src/joints/universal.cpp | 803 + libs/ode-0.16.1/ode/src/joints/universal.h | 64 + libs/ode-0.16.1/ode/src/lcp.cpp | 1317 ++ libs/ode-0.16.1/ode/src/lcp.h | 81 + libs/ode-0.16.1/ode/src/mass.cpp | 554 + libs/ode-0.16.1/ode/src/mat.cpp | 231 + libs/ode-0.16.1/ode/src/mat.h | 71 + libs/ode-0.16.1/ode/src/matrix.cpp | 593 + libs/ode-0.16.1/ode/src/matrix.h | 160 + libs/ode-0.16.1/ode/src/memory.cpp | 95 + libs/ode-0.16.1/ode/src/misc.cpp | 217 + libs/ode-0.16.1/ode/src/nextafterf.c | 115 + libs/ode-0.16.1/ode/src/objects.cpp | 138 + libs/ode-0.16.1/ode/src/objects.h | 206 + libs/ode-0.16.1/ode/src/obstack.cpp | 157 + libs/ode-0.16.1/ode/src/obstack.h | 73 + libs/ode-0.16.1/ode/src/ode.cpp | 2325 ++ libs/ode-0.16.1/ode/src/odeinit.cpp | 575 + libs/ode-0.16.1/ode/src/odemath.cpp | 312 + libs/ode-0.16.1/ode/src/odemath.h | 72 + libs/ode-0.16.1/ode/src/odeou.cpp | 107 + libs/ode-0.16.1/ode/src/odeou.h | 107 + libs/ode-0.16.1/ode/src/odetls.cpp | 153 + libs/ode-0.16.1/ode/src/odetls.h | 126 + libs/ode-0.16.1/ode/src/plane.cpp | 146 + libs/ode-0.16.1/ode/src/quickstep.cpp | 3344 +++ libs/ode-0.16.1/ode/src/quickstep.h | 39 + libs/ode-0.16.1/ode/src/ray.cpp | 735 + libs/ode-0.16.1/ode/src/resource_control.cpp | 259 + libs/ode-0.16.1/ode/src/resource_control.h | 151 + libs/ode-0.16.1/ode/src/rotation.cpp | 317 + libs/ode-0.16.1/ode/src/simple_cooperative.cpp | 84 + libs/ode-0.16.1/ode/src/simple_cooperative.h | 73 + libs/ode-0.16.1/ode/src/sphere.cpp | 251 + libs/ode-0.16.1/ode/src/step.cpp | 1672 ++ libs/ode-0.16.1/ode/src/step.h | 40 + libs/ode-0.16.1/ode/src/threaded_solver_ldlt.h | 809 + libs/ode-0.16.1/ode/src/threading_atomics_provs.h | 194 + libs/ode-0.16.1/ode/src/threading_base.cpp | 135 + libs/ode-0.16.1/ode/src/threading_base.h | 291 + libs/ode-0.16.1/ode/src/threading_fake_sync.h | 128 + libs/ode-0.16.1/ode/src/threading_impl.cpp | 282 + libs/ode-0.16.1/ode/src/threading_impl.h | 40 + libs/ode-0.16.1/ode/src/threading_impl_posix.h | 638 + libs/ode-0.16.1/ode/src/threading_impl_templates.h | 1265 ++ libs/ode-0.16.1/ode/src/threading_impl_win.h | 273 + libs/ode-0.16.1/ode/src/threading_pool_posix.cpp | 823 + libs/ode-0.16.1/ode/src/threading_pool_win.cpp | 670 + libs/ode-0.16.1/ode/src/threadingutils.h | 157 + libs/ode-0.16.1/ode/src/timer.cpp | 424 + libs/ode-0.16.1/ode/src/typedefs.h | 74 + libs/ode-0.16.1/ode/src/util.cpp | 1231 ++ libs/ode-0.16.1/ode/src/util.h | 440 + libs/ode-0.16.1/ou/CHANGELOG.TXT | 55 + libs/ode-0.16.1/ou/INSTALL.TXT | 14 + libs/ode-0.16.1/ou/LICENSE-BSD.TXT | 34 + libs/ode-0.16.1/ou/LICENSE-LESSER.TXT | 166 + libs/ode-0.16.1/ou/LICENSE-ZLIB.TXT | 22 + libs/ode-0.16.1/ou/LICENSE.TXT | 675 + libs/ode-0.16.1/ou/Makefile.am | 10 + libs/ode-0.16.1/ou/Makefile.in | 804 + libs/ode-0.16.1/ou/README.TXT | 42 + libs/ode-0.16.1/ou/aclocal.m4 | 10200 +++++++++ libs/ode-0.16.1/ou/bootstrap | 11 + libs/ode-0.16.1/ou/build/make/makefile | 219 + libs/ode-0.16.1/ou/build/make/makefile.os | 41 + libs/ode-0.16.1/ou/build/vs2005/ou.sln | 39 + libs/ode-0.16.1/ou/build/vs2005/ou.vcproj | 494 + libs/ode-0.16.1/ou/build/vs6/ou.dsp | 172 + libs/ode-0.16.1/ou/build/vs6/ou.dsw | 44 + libs/ode-0.16.1/ou/configure | 20569 ++++++++++++++++++ libs/ode-0.16.1/ou/configure.ac | 145 + libs/ode-0.16.1/ou/include/ou/Makefile.am | 17 + libs/ode-0.16.1/ou/include/ou/Makefile.in | 457 + libs/ode-0.16.1/ou/include/ou/assert.h | 188 + libs/ode-0.16.1/ou/include/ou/atomic.h | 1835 ++ libs/ode-0.16.1/ou/include/ou/atomicflags.h | 367 + libs/ode-0.16.1/ou/include/ou/customization.h | 149 + libs/ode-0.16.1/ou/include/ou/enumarrays.h | 256 + libs/ode-0.16.1/ou/include/ou/features.h | 51 + libs/ode-0.16.1/ou/include/ou/flags.h | 35 + libs/ode-0.16.1/ou/include/ou/flagsdefines.h | 37 + libs/ode-0.16.1/ou/include/ou/inttypes.h | 136 + libs/ode-0.16.1/ou/include/ou/macros.h | 79 + libs/ode-0.16.1/ou/include/ou/malloc.h | 48 + libs/ode-0.16.1/ou/include/ou/namespace.h | 43 + libs/ode-0.16.1/ou/include/ou/platform.h | 398 + libs/ode-0.16.1/ou/include/ou/simpleflags.h | 334 + libs/ode-0.16.1/ou/include/ou/templates.h | 90 + libs/ode-0.16.1/ou/include/ou/threadlocalstorage.h | 297 + libs/ode-0.16.1/ou/include/ou/typewrapper.h | 111 + libs/ode-0.16.1/ou/src/ou/Makefile.am | 13 + libs/ode-0.16.1/ou/src/ou/Makefile.in | 598 + libs/ode-0.16.1/ou/src/ou/atomic.cpp | 445 + libs/ode-0.16.1/ou/src/ou/customization.cpp | 64 + libs/ode-0.16.1/ou/src/ou/malloc.cpp | 106 + libs/ode-0.16.1/ou/src/ou/threadlocalstorage.cpp | 1336 ++ libs/ode-0.16.1/ou/test/Makefile.am | 10 + libs/ode-0.16.1/ou/test/Makefile.in | 589 + libs/ode-0.16.1/ou/test/outest.cpp | 9027 ++++++++ libs/ode-0.16.1/test-driver | 148 + libs/ode-0.16.1/tests/Makefile.am | 30 + libs/ode-0.16.1/tests/Makefile.in | 1116 + libs/ode-0.16.1/tests/UnitTest++/COPYING | 20 + libs/ode-0.16.1/tests/UnitTest++/Makefile.am | 6 + libs/ode-0.16.1/tests/UnitTest++/Makefile.in | 643 + libs/ode-0.16.1/tests/UnitTest++/README | 62 + .../tests/UnitTest++/docs/UnitTest++.html | 260 + .../tests/UnitTest++/src/AssertException.cpp | 32 + .../tests/UnitTest++/src/AssertException.h | 28 + libs/ode-0.16.1/tests/UnitTest++/src/CheckMacros.h | 102 + libs/ode-0.16.1/tests/UnitTest++/src/Checks.cpp | 48 + libs/ode-0.16.1/tests/UnitTest++/src/Checks.h | 146 + libs/ode-0.16.1/tests/UnitTest++/src/Config.h | 25 + .../tests/UnitTest++/src/DeferredTestReporter.cpp | 28 + .../tests/UnitTest++/src/DeferredTestReporter.h | 28 + .../tests/UnitTest++/src/DeferredTestResult.cpp | 26 + .../tests/UnitTest++/src/DeferredTestResult.h | 29 + libs/ode-0.16.1/tests/UnitTest++/src/Makefile.am | 33 + libs/ode-0.16.1/tests/UnitTest++/src/Makefile.in | 784 + .../tests/UnitTest++/src/MemoryOutStream.cpp | 143 + .../tests/UnitTest++/src/MemoryOutStream.h | 67 + .../tests/UnitTest++/src/Posix/Makefile.am | 5 + .../tests/UnitTest++/src/Posix/Makefile.in | 627 + .../UnitTest++/src/Posix/SignalTranslator.cpp | 46 + .../tests/UnitTest++/src/Posix/SignalTranslator.h | 42 + .../tests/UnitTest++/src/Posix/TimeHelpers.cpp | 33 + .../tests/UnitTest++/src/Posix/TimeHelpers.h | 28 + .../tests/UnitTest++/src/ReportAssert.cpp | 10 + .../ode-0.16.1/tests/UnitTest++/src/ReportAssert.h | 10 + libs/ode-0.16.1/tests/UnitTest++/src/Test.cpp | 62 + libs/ode-0.16.1/tests/UnitTest++/src/Test.h | 34 + .../tests/UnitTest++/src/TestDetails.cpp | 22 + libs/ode-0.16.1/tests/UnitTest++/src/TestDetails.h | 24 + libs/ode-0.16.1/tests/UnitTest++/src/TestList.cpp | 39 + libs/ode-0.16.1/tests/UnitTest++/src/TestList.h | 32 + libs/ode-0.16.1/tests/UnitTest++/src/TestMacros.h | 99 + .../tests/UnitTest++/src/TestReporter.cpp | 10 + .../ode-0.16.1/tests/UnitTest++/src/TestReporter.h | 20 + .../tests/UnitTest++/src/TestReporterStdout.cpp | 36 + .../tests/UnitTest++/src/TestReporterStdout.h | 19 + .../tests/UnitTest++/src/TestResults.cpp | 60 + libs/ode-0.16.1/tests/UnitTest++/src/TestResults.h | 36 + .../ode-0.16.1/tests/UnitTest++/src/TestRunner.cpp | 60 + libs/ode-0.16.1/tests/UnitTest++/src/TestRunner.h | 17 + libs/ode-0.16.1/tests/UnitTest++/src/TestSuite.h | 14 + .../tests/UnitTest++/src/TimeConstraint.cpp | 28 + .../tests/UnitTest++/src/TimeConstraint.h | 34 + libs/ode-0.16.1/tests/UnitTest++/src/TimeHelpers.h | 7 + libs/ode-0.16.1/tests/UnitTest++/src/UnitTest++.h | 17 + .../tests/UnitTest++/src/Win32/Makefile.am | 4 + .../tests/UnitTest++/src/Win32/Makefile.in | 624 + .../tests/UnitTest++/src/Win32/TimeHelpers.cpp | 46 + .../tests/UnitTest++/src/Win32/TimeHelpers.h | 48 + .../tests/UnitTest++/src/XmlTestReporter.cpp | 126 + .../tests/UnitTest++/src/XmlTestReporter.h | 34 + libs/ode-0.16.1/tests/collision.cpp | 224 + libs/ode-0.16.1/tests/friction.cpp | 176 + libs/ode-0.16.1/tests/joint.cpp | 3054 +++ libs/ode-0.16.1/tests/joints/Makefile.am | 21 + libs/ode-0.16.1/tests/joints/Makefile.in | 638 + libs/ode-0.16.1/tests/joints/amotor.cpp | 324 + libs/ode-0.16.1/tests/joints/ball.cpp | 160 + libs/ode-0.16.1/tests/joints/dball.cpp | 81 + libs/ode-0.16.1/tests/joints/fixed.cpp | 149 + libs/ode-0.16.1/tests/joints/hinge.cpp | 928 + libs/ode-0.16.1/tests/joints/hinge2.cpp | 167 + libs/ode-0.16.1/tests/joints/piston.cpp | 1456 ++ libs/ode-0.16.1/tests/joints/pr.cpp | 1160 + libs/ode-0.16.1/tests/joints/pu.cpp | 920 + libs/ode-0.16.1/tests/joints/slider.cpp | 1332 ++ libs/ode-0.16.1/tests/joints/universal.cpp | 2119 ++ libs/ode-0.16.1/tests/main.cpp | 13 + libs/ode-0.16.1/tests/odemath.cpp | 247 + libs/ode-0.16.1/tools/README.txt | 94 + libs/ode-0.16.1/tools/msw-release.bat | 138 + libs/ode-0.16.1/tools/ode_convex_export.py | 60 + libs/ode-0.16.1/tools/src-release.sh | 117 + 650 files changed, 321056 insertions(+), 4 deletions(-) create mode 100644 libs/ode-0.16.1/CHANGELOG.txt create mode 100644 libs/ode-0.16.1/CMakeLists.txt create mode 100644 libs/ode-0.16.1/COPYING create mode 100644 libs/ode-0.16.1/CSR.txt create mode 100644 libs/ode-0.16.1/GIMPACT/GIMPACT-LICENSE-BSD.TXT create mode 100644 libs/ode-0.16.1/GIMPACT/GIMPACT-LICENSE-LGPL.TXT create mode 100644 libs/ode-0.16.1/GIMPACT/Makefile.am create mode 100644 libs/ode-0.16.1/GIMPACT/Makefile.in create mode 100644 libs/ode-0.16.1/GIMPACT/include/GIMPACT/Makefile.am create mode 100644 libs/ode-0.16.1/GIMPACT/include/GIMPACT/Makefile.in create mode 100644 libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_boxpruning.h create mode 100644 libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_contact.h create mode 100644 libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_geometry.h create mode 100644 libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_math.h create mode 100644 libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_memory.h create mode 100644 libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_radixsort.h create mode 100644 libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_tri_capsule_collision.h create mode 100644 libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_tri_collision.h create mode 100644 libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_tri_sphere_collision.h create mode 100644 libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_trimesh.h create mode 100644 libs/ode-0.16.1/GIMPACT/include/GIMPACT/gimpact.h create mode 100644 libs/ode-0.16.1/GIMPACT/include/Makefile.am create mode 100644 libs/ode-0.16.1/GIMPACT/include/Makefile.in create mode 100644 libs/ode-0.16.1/GIMPACT/src/Makefile.am create mode 100644 libs/ode-0.16.1/GIMPACT/src/Makefile.in create mode 100644 libs/ode-0.16.1/GIMPACT/src/gim_boxpruning.cpp create mode 100644 libs/ode-0.16.1/GIMPACT/src/gim_contact.cpp create mode 100644 libs/ode-0.16.1/GIMPACT/src/gim_math.cpp create mode 100644 libs/ode-0.16.1/GIMPACT/src/gim_memory.cpp create mode 100644 libs/ode-0.16.1/GIMPACT/src/gim_tri_tri_overlap.cpp create mode 100644 libs/ode-0.16.1/GIMPACT/src/gim_trimesh.cpp create mode 100644 libs/ode-0.16.1/GIMPACT/src/gim_trimesh_capsule_collision.cpp create mode 100644 libs/ode-0.16.1/GIMPACT/src/gim_trimesh_ray_collision.cpp create mode 100644 libs/ode-0.16.1/GIMPACT/src/gim_trimesh_sphere_collision.cpp create mode 100644 libs/ode-0.16.1/GIMPACT/src/gim_trimesh_trimesh_collision.cpp create mode 100644 libs/ode-0.16.1/GIMPACT/src/gimpact.cpp create mode 100644 libs/ode-0.16.1/INSTALL.txt create mode 100644 libs/ode-0.16.1/LICENSE-BSD.TXT create mode 100644 libs/ode-0.16.1/LICENSE.TXT create mode 100644 libs/ode-0.16.1/Makefile.am create mode 100644 libs/ode-0.16.1/Makefile.in create mode 100644 libs/ode-0.16.1/OPCODE/COPYING create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceAABB.cpp create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceAABB.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceAxes.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceBoundingSphere.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceContainer.cpp create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceContainer.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceFPU.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceHPoint.cpp create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceHPoint.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceIndexedTriangle.cpp create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceIndexedTriangle.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceLSS.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceMatrix3x3.cpp create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceMatrix3x3.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceMatrix4x4.cpp create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceMatrix4x4.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceMemoryMacros.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceOBB.cpp create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceOBB.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IcePairs.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IcePlane.cpp create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IcePlane.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IcePoint.cpp create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IcePoint.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IcePreprocessor.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceRandom.cpp create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceRandom.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceRay.cpp create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceRay.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceRevisitedRadix.cpp create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceRevisitedRadix.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceSegment.cpp create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceSegment.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceTriList.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceTriangle.cpp create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceTriangle.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceTypes.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceUtils.cpp create mode 100644 libs/ode-0.16.1/OPCODE/Ice/IceUtils.h create mode 100644 libs/ode-0.16.1/OPCODE/Ice/Makefile.am create mode 100644 libs/ode-0.16.1/OPCODE/Ice/Makefile.in create mode 100644 libs/ode-0.16.1/OPCODE/Makefile.am create mode 100644 libs/ode-0.16.1/OPCODE/Makefile.in create mode 100644 libs/ode-0.16.1/OPCODE/OPC_AABBCollider.cpp create mode 100644 libs/ode-0.16.1/OPCODE/OPC_AABBCollider.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_AABBTree.cpp create mode 100644 libs/ode-0.16.1/OPCODE/OPC_AABBTree.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_BaseModel.cpp create mode 100644 libs/ode-0.16.1/OPCODE/OPC_BaseModel.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_BoxBoxOverlap.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_Collider.cpp create mode 100644 libs/ode-0.16.1/OPCODE/OPC_Collider.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_Common.cpp create mode 100644 libs/ode-0.16.1/OPCODE/OPC_Common.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_HybridModel.cpp create mode 100644 libs/ode-0.16.1/OPCODE/OPC_HybridModel.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_IceHook.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_LSSAABBOverlap.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_LSSCollider.cpp create mode 100644 libs/ode-0.16.1/OPCODE/OPC_LSSCollider.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_LSSTriOverlap.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_MeshInterface.cpp create mode 100644 libs/ode-0.16.1/OPCODE/OPC_MeshInterface.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_Model.cpp create mode 100644 libs/ode-0.16.1/OPCODE/OPC_Model.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_OBBCollider.cpp create mode 100644 libs/ode-0.16.1/OPCODE/OPC_OBBCollider.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_OptimizedTree.cpp create mode 100644 libs/ode-0.16.1/OPCODE/OPC_OptimizedTree.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_Picking.cpp create mode 100644 libs/ode-0.16.1/OPCODE/OPC_Picking.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_PlanesAABBOverlap.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_PlanesCollider.cpp create mode 100644 libs/ode-0.16.1/OPCODE/OPC_PlanesCollider.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_PlanesTriOverlap.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_RayAABBOverlap.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_RayCollider.cpp create mode 100644 libs/ode-0.16.1/OPCODE/OPC_RayCollider.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_RayTriOverlap.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_Settings.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_SphereAABBOverlap.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_SphereCollider.cpp create mode 100644 libs/ode-0.16.1/OPCODE/OPC_SphereCollider.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_SphereTriOverlap.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_TreeBuilders.cpp create mode 100644 libs/ode-0.16.1/OPCODE/OPC_TreeBuilders.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_TreeCollider.cpp create mode 100644 libs/ode-0.16.1/OPCODE/OPC_TreeCollider.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_TriBoxOverlap.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_TriTriOverlap.h create mode 100644 libs/ode-0.16.1/OPCODE/OPC_VolumeCollider.cpp create mode 100644 libs/ode-0.16.1/OPCODE/OPC_VolumeCollider.h create mode 100644 libs/ode-0.16.1/OPCODE/Opcode.cpp create mode 100644 libs/ode-0.16.1/OPCODE/Opcode.h create mode 100644 libs/ode-0.16.1/OPCODE/README-ODE.txt create mode 100644 libs/ode-0.16.1/OPCODE/ReadMe.txt create mode 100644 libs/ode-0.16.1/OPCODE/Stdafx.h create mode 100644 libs/ode-0.16.1/OPCODE/TemporalCoherence.txt create mode 100644 libs/ode-0.16.1/README.md create mode 100644 libs/ode-0.16.1/aclocal.m4 create mode 100644 libs/ode-0.16.1/bindings/python/INSTALL.txt create mode 100644 libs/ode-0.16.1/bindings/python/TODO.txt create mode 100755 libs/ode-0.16.1/bindings/python/demos/tutorial1.py create mode 100755 libs/ode-0.16.1/bindings/python/demos/tutorial2.py create mode 100644 libs/ode-0.16.1/bindings/python/demos/tutorial3.py create mode 100644 libs/ode-0.16.1/bindings/python/ode.pxd create mode 100644 libs/ode-0.16.1/bindings/python/ode.pyx create mode 100644 libs/ode-0.16.1/bindings/python/setup.py create mode 100755 libs/ode-0.16.1/bootstrap create mode 100644 libs/ode-0.16.1/build/config-default.h create mode 100644 libs/ode-0.16.1/build/premake4.exe create mode 100644 libs/ode-0.16.1/build/premake4.lua create mode 100644 libs/ode-0.16.1/cmake/cmake_uninstall.cmake.in create mode 100755 libs/ode-0.16.1/compile create mode 100755 libs/ode-0.16.1/config.guess create mode 100644 libs/ode-0.16.1/config.h.cmake.in create mode 100755 libs/ode-0.16.1/config.sub create mode 100755 libs/ode-0.16.1/configure create mode 100644 libs/ode-0.16.1/configure.ac create mode 100755 libs/ode-0.16.1/depcomp create mode 100644 libs/ode-0.16.1/drawstuff/Makefile.am create mode 100644 libs/ode-0.16.1/drawstuff/Makefile.in create mode 100644 libs/ode-0.16.1/drawstuff/dstest/Makefile.am create mode 100644 libs/ode-0.16.1/drawstuff/dstest/Makefile.in create mode 100644 libs/ode-0.16.1/drawstuff/dstest/dstest.cpp create mode 100644 libs/ode-0.16.1/drawstuff/src/Makefile.am create mode 100644 libs/ode-0.16.1/drawstuff/src/Makefile.in create mode 100644 libs/ode-0.16.1/drawstuff/src/drawstuff.cpp create mode 100644 libs/ode-0.16.1/drawstuff/src/internal.h create mode 100644 libs/ode-0.16.1/drawstuff/src/osx.cpp create mode 100644 libs/ode-0.16.1/drawstuff/src/resource.h create mode 100644 libs/ode-0.16.1/drawstuff/src/resources.rc create mode 100644 libs/ode-0.16.1/drawstuff/src/windows.cpp create mode 100644 libs/ode-0.16.1/drawstuff/src/x11.cpp create mode 100644 libs/ode-0.16.1/drawstuff/textures/checkered.ppm create mode 100644 libs/ode-0.16.1/drawstuff/textures/ground.ppm create mode 100644 libs/ode-0.16.1/drawstuff/textures/sky.ppm create mode 100644 libs/ode-0.16.1/drawstuff/textures/wood.ppm create mode 100644 libs/ode-0.16.1/include/Makefile.am create mode 100644 libs/ode-0.16.1/include/Makefile.in create mode 100644 libs/ode-0.16.1/include/drawstuff/Makefile.am create mode 100644 libs/ode-0.16.1/include/drawstuff/Makefile.in create mode 100644 libs/ode-0.16.1/include/drawstuff/drawstuff.h create mode 100644 libs/ode-0.16.1/include/drawstuff/version.h create mode 100644 libs/ode-0.16.1/include/ode/Makefile.am create mode 100644 libs/ode-0.16.1/include/ode/Makefile.in create mode 100644 libs/ode-0.16.1/include/ode/README create mode 100644 libs/ode-0.16.1/include/ode/collision.h create mode 100644 libs/ode-0.16.1/include/ode/collision_space.h create mode 100644 libs/ode-0.16.1/include/ode/collision_trimesh.h create mode 100644 libs/ode-0.16.1/include/ode/common.h create mode 100644 libs/ode-0.16.1/include/ode/compatibility.h create mode 100644 libs/ode-0.16.1/include/ode/contact.h create mode 100644 libs/ode-0.16.1/include/ode/cooperative.h create mode 100644 libs/ode-0.16.1/include/ode/error.h create mode 100644 libs/ode-0.16.1/include/ode/export-dif.h create mode 100644 libs/ode-0.16.1/include/ode/mass.h create mode 100644 libs/ode-0.16.1/include/ode/matrix.h create mode 100644 libs/ode-0.16.1/include/ode/matrix_coop.h create mode 100644 libs/ode-0.16.1/include/ode/memory.h create mode 100644 libs/ode-0.16.1/include/ode/misc.h create mode 100644 libs/ode-0.16.1/include/ode/objects.h create mode 100644 libs/ode-0.16.1/include/ode/ode.h create mode 100644 libs/ode-0.16.1/include/ode/odeconfig.h create mode 100644 libs/ode-0.16.1/include/ode/odecpp.h create mode 100644 libs/ode-0.16.1/include/ode/odecpp_collision.h create mode 100644 libs/ode-0.16.1/include/ode/odeinit.h create mode 100644 libs/ode-0.16.1/include/ode/odemath.h create mode 100644 libs/ode-0.16.1/include/ode/odemath_legacy.h create mode 100644 libs/ode-0.16.1/include/ode/precision.h create mode 100644 libs/ode-0.16.1/include/ode/precision.h.in create mode 100644 libs/ode-0.16.1/include/ode/rotation.h create mode 100644 libs/ode-0.16.1/include/ode/threading.h create mode 100644 libs/ode-0.16.1/include/ode/threading_impl.h create mode 100644 libs/ode-0.16.1/include/ode/timer.h create mode 100644 libs/ode-0.16.1/include/ode/version.h create mode 100644 libs/ode-0.16.1/include/ode/version.h.in create mode 100755 libs/ode-0.16.1/install-sh create mode 100644 libs/ode-0.16.1/libccd/BSD-LICENSE create mode 100644 libs/ode-0.16.1/libccd/Makefile.am create mode 100644 libs/ode-0.16.1/libccd/Makefile.in create mode 100644 libs/ode-0.16.1/libccd/README create mode 100644 libs/ode-0.16.1/libccd/aclocal.m4 create mode 100755 libs/ode-0.16.1/libccd/bootstrap create mode 100755 libs/ode-0.16.1/libccd/configure create mode 100644 libs/ode-0.16.1/libccd/configure.ac create mode 100644 libs/ode-0.16.1/libccd/src/Makefile.am create mode 100644 libs/ode-0.16.1/libccd/src/Makefile.in create mode 100644 libs/ode-0.16.1/libccd/src/alloc.c create mode 100644 libs/ode-0.16.1/libccd/src/ccd.c create mode 100644 libs/ode-0.16.1/libccd/src/ccd/alloc.h create mode 100644 libs/ode-0.16.1/libccd/src/ccd/ccd.h create mode 100644 libs/ode-0.16.1/libccd/src/ccd/compiler.h create mode 100644 libs/ode-0.16.1/libccd/src/ccd/dbg.h create mode 100644 libs/ode-0.16.1/libccd/src/ccd/list.h create mode 100644 libs/ode-0.16.1/libccd/src/ccd/polytope.h create mode 100644 libs/ode-0.16.1/libccd/src/ccd/precision.h.in create mode 100644 libs/ode-0.16.1/libccd/src/ccd/quat.h create mode 100644 libs/ode-0.16.1/libccd/src/ccd/simplex.h create mode 100644 libs/ode-0.16.1/libccd/src/ccd/support.h create mode 100644 libs/ode-0.16.1/libccd/src/ccd/vec3.h create mode 100644 libs/ode-0.16.1/libccd/src/config.h.in create mode 100644 libs/ode-0.16.1/libccd/src/custom/ccdcustom/quat.h create mode 100644 libs/ode-0.16.1/libccd/src/custom/ccdcustom/vec3.h create mode 100644 libs/ode-0.16.1/libccd/src/mpr.c create mode 100644 libs/ode-0.16.1/libccd/src/polytope.c create mode 100644 libs/ode-0.16.1/libccd/src/support.c create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/Makefile.am create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/Makefile.in create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/bench.c create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/bench2.c create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/boxbox.c create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/boxbox.h create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/boxcyl.c create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/boxcyl.h create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/common.c create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/common.h create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/cu/COPYING create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/cu/COPYING.LESSER create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/cu/Makefile.am create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/cu/Makefile.in create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/cu/cu.c create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/cu/cu.h create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/cylcyl.c create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/cylcyl.h create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/main.c create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/mpr_boxbox.c create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/mpr_boxbox.h create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/mpr_boxcyl.c create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/mpr_boxcyl.h create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/mpr_cylcyl.c create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/mpr_cylcyl.h create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/polytope.c create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/polytope.h create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/spheresphere.c create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/spheresphere.h create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/support.c create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/support.h create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/vec3.c create mode 100644 libs/ode-0.16.1/libccd/src/testsuites/vec3.h create mode 100644 libs/ode-0.16.1/libccd/src/vec3.c create mode 100644 libs/ode-0.16.1/ltmain.sh create mode 100644 libs/ode-0.16.1/m4/libtool.m4 create mode 100644 libs/ode-0.16.1/m4/ltoptions.m4 create mode 100644 libs/ode-0.16.1/m4/ltsugar.m4 create mode 100644 libs/ode-0.16.1/m4/ltversion.m4 create mode 100644 libs/ode-0.16.1/m4/lt~obsolete.m4 create mode 100644 libs/ode-0.16.1/m4/pkg.m4 create mode 100755 libs/ode-0.16.1/missing create mode 100644 libs/ode-0.16.1/ode-config.cmake.in create mode 100644 libs/ode-0.16.1/ode-config.in create mode 100644 libs/ode-0.16.1/ode.pc.in create mode 100644 libs/ode-0.16.1/ode/Makefile.am create mode 100644 libs/ode-0.16.1/ode/Makefile.in create mode 100644 libs/ode-0.16.1/ode/README create mode 100644 libs/ode-0.16.1/ode/TODO create mode 100644 libs/ode-0.16.1/ode/demo/Makefile.am create mode 100644 libs/ode-0.16.1/ode/demo/Makefile.in create mode 100644 libs/ode-0.16.1/ode/demo/basket_geom.h create mode 100644 libs/ode-0.16.1/ode/demo/bunny_geom.h create mode 100644 libs/ode-0.16.1/ode/demo/convex_bunny_geom.h create mode 100644 libs/ode-0.16.1/ode/demo/convex_prism.h create mode 100644 libs/ode-0.16.1/ode/demo/demo_I.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_basket.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_boxstack.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_buggy.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_cards.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_chain1.c create mode 100644 libs/ode-0.16.1/ode/demo/demo_chain2.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_collision.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_convex.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_crash.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_cyl.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_cylvssphere.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_dball.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_dhinge.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_feedback.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_friction.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_gyro2.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_gyroscopic.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_heightfield.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_hinge.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_jointPR.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_jointPU.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_joints.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_kinematic.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_motion.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_motor.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_moving_convex.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_moving_trimesh.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_ode.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_piston.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_plane2d.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_rfriction.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_slider.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_space.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_space_stress.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_step.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_tracks.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_transmission.cpp create mode 100644 libs/ode-0.16.1/ode/demo/demo_trimesh.cpp create mode 100644 libs/ode-0.16.1/ode/demo/halton235_geom.h create mode 100644 libs/ode-0.16.1/ode/demo/icosahedron_geom.h create mode 100644 libs/ode-0.16.1/ode/demo/texturepath.h create mode 100644 libs/ode-0.16.1/ode/demo/world_geom3.h create mode 100644 libs/ode-0.16.1/ode/doc/Doxyfile.in create mode 100644 libs/ode-0.16.1/ode/doc/Makefile.am create mode 100644 libs/ode-0.16.1/ode/doc/Makefile.in create mode 100644 libs/ode-0.16.1/ode/doc/main.dox create mode 100644 libs/ode-0.16.1/ode/doc/pix/amotor.jpg create mode 100644 libs/ode-0.16.1/ode/doc/pix/ball-and-socket-bad.jpg create mode 100644 libs/ode-0.16.1/ode/doc/pix/ball-and-socket.jpg create mode 100644 libs/ode-0.16.1/ode/doc/pix/body.jpg create mode 100644 libs/ode-0.16.1/ode/doc/pix/contact.jpg create mode 100644 libs/ode-0.16.1/ode/doc/pix/hinge.jpg create mode 100644 libs/ode-0.16.1/ode/doc/pix/hinge2.jpg create mode 100644 libs/ode-0.16.1/ode/doc/pix/joints.jpg create mode 100644 libs/ode-0.16.1/ode/doc/pix/rollingcontact.jpg create mode 100644 libs/ode-0.16.1/ode/doc/pix/sf-graph1.jpg create mode 100644 libs/ode-0.16.1/ode/doc/pix/sf-graph2.jpg create mode 100644 libs/ode-0.16.1/ode/doc/pix/slider.jpg create mode 100644 libs/ode-0.16.1/ode/doc/pix/universal.jpg create mode 100644 libs/ode-0.16.1/ode/src/Makefile.am create mode 100644 libs/ode-0.16.1/ode/src/Makefile.in create mode 100644 libs/ode-0.16.1/ode/src/array.cpp create mode 100644 libs/ode-0.16.1/ode/src/array.h create mode 100644 libs/ode-0.16.1/ode/src/box.cpp create mode 100644 libs/ode-0.16.1/ode/src/capsule.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_convex_trimesh.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_cylinder_box.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_cylinder_plane.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_cylinder_sphere.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_cylinder_trimesh.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_kernel.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_kernel.h create mode 100644 libs/ode-0.16.1/ode/src/collision_libccd.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_libccd.h create mode 100644 libs/ode-0.16.1/ode/src/collision_quadtreespace.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_sapspace.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_space.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_space_internal.h create mode 100644 libs/ode-0.16.1/ode/src/collision_std.h create mode 100644 libs/ode-0.16.1/ode/src/collision_transform.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_transform.h create mode 100644 libs/ode-0.16.1/ode/src/collision_trimesh_box.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_trimesh_ccylinder.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_trimesh_colliders.h create mode 100644 libs/ode-0.16.1/ode/src/collision_trimesh_disabled.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_trimesh_gimpact.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_trimesh_gimpact.h create mode 100644 libs/ode-0.16.1/ode/src/collision_trimesh_internal.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_trimesh_internal.h create mode 100644 libs/ode-0.16.1/ode/src/collision_trimesh_internal_impl.h create mode 100644 libs/ode-0.16.1/ode/src/collision_trimesh_opcode.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_trimesh_opcode.h create mode 100644 libs/ode-0.16.1/ode/src/collision_trimesh_plane.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_trimesh_ray.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_trimesh_sphere.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_trimesh_trimesh.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_trimesh_trimesh_old.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_util.cpp create mode 100644 libs/ode-0.16.1/ode/src/collision_util.h create mode 100644 libs/ode-0.16.1/ode/src/common.h create mode 100644 libs/ode-0.16.1/ode/src/config.h.in create mode 100644 libs/ode-0.16.1/ode/src/convex.cpp create mode 100644 libs/ode-0.16.1/ode/src/coop_matrix_types.h create mode 100644 libs/ode-0.16.1/ode/src/cylinder.cpp create mode 100644 libs/ode-0.16.1/ode/src/default_threading.cpp create mode 100644 libs/ode-0.16.1/ode/src/default_threading.h create mode 100644 libs/ode-0.16.1/ode/src/error.cpp create mode 100644 libs/ode-0.16.1/ode/src/error.h create mode 100644 libs/ode-0.16.1/ode/src/export-dif.cpp create mode 100644 libs/ode-0.16.1/ode/src/fastdot.cpp create mode 100644 libs/ode-0.16.1/ode/src/fastdot_impl.h create mode 100644 libs/ode-0.16.1/ode/src/fastldltfactor.cpp create mode 100644 libs/ode-0.16.1/ode/src/fastldltfactor_impl.h create mode 100644 libs/ode-0.16.1/ode/src/fastldltsolve.cpp create mode 100644 libs/ode-0.16.1/ode/src/fastldltsolve_impl.h create mode 100644 libs/ode-0.16.1/ode/src/fastlsolve.cpp create mode 100644 libs/ode-0.16.1/ode/src/fastlsolve_impl.h create mode 100644 libs/ode-0.16.1/ode/src/fastltsolve.cpp create mode 100644 libs/ode-0.16.1/ode/src/fastltsolve_impl.h create mode 100644 libs/ode-0.16.1/ode/src/fastvecscale.cpp create mode 100644 libs/ode-0.16.1/ode/src/fastvecscale_impl.h create mode 100644 libs/ode-0.16.1/ode/src/gimpact_contact_export_helper.cpp create mode 100644 libs/ode-0.16.1/ode/src/gimpact_contact_export_helper.h create mode 100644 libs/ode-0.16.1/ode/src/gimpact_gim_contact_accessor.h create mode 100644 libs/ode-0.16.1/ode/src/gimpact_plane_contact_accessor.h create mode 100644 libs/ode-0.16.1/ode/src/heightfield.cpp create mode 100644 libs/ode-0.16.1/ode/src/heightfield.h create mode 100644 libs/ode-0.16.1/ode/src/joints/Makefile.am create mode 100644 libs/ode-0.16.1/ode/src/joints/Makefile.in create mode 100644 libs/ode-0.16.1/ode/src/joints/amotor.cpp create mode 100644 libs/ode-0.16.1/ode/src/joints/amotor.h create mode 100644 libs/ode-0.16.1/ode/src/joints/ball.cpp create mode 100644 libs/ode-0.16.1/ode/src/joints/ball.h create mode 100644 libs/ode-0.16.1/ode/src/joints/contact.cpp create mode 100644 libs/ode-0.16.1/ode/src/joints/contact.h create mode 100644 libs/ode-0.16.1/ode/src/joints/dball.cpp create mode 100644 libs/ode-0.16.1/ode/src/joints/dball.h create mode 100644 libs/ode-0.16.1/ode/src/joints/dhinge.cpp create mode 100644 libs/ode-0.16.1/ode/src/joints/dhinge.h create mode 100644 libs/ode-0.16.1/ode/src/joints/fixed.cpp create mode 100644 libs/ode-0.16.1/ode/src/joints/fixed.h create mode 100644 libs/ode-0.16.1/ode/src/joints/hinge.cpp create mode 100644 libs/ode-0.16.1/ode/src/joints/hinge.h create mode 100644 libs/ode-0.16.1/ode/src/joints/hinge2.cpp create mode 100644 libs/ode-0.16.1/ode/src/joints/hinge2.h create mode 100644 libs/ode-0.16.1/ode/src/joints/joint.cpp create mode 100644 libs/ode-0.16.1/ode/src/joints/joint.h create mode 100644 libs/ode-0.16.1/ode/src/joints/joint_internal.h create mode 100644 libs/ode-0.16.1/ode/src/joints/joints.h create mode 100644 libs/ode-0.16.1/ode/src/joints/lmotor.cpp create mode 100644 libs/ode-0.16.1/ode/src/joints/lmotor.h create mode 100644 libs/ode-0.16.1/ode/src/joints/null.cpp create mode 100644 libs/ode-0.16.1/ode/src/joints/null.h create mode 100644 libs/ode-0.16.1/ode/src/joints/piston.cpp create mode 100644 libs/ode-0.16.1/ode/src/joints/piston.h create mode 100644 libs/ode-0.16.1/ode/src/joints/plane2d.cpp create mode 100644 libs/ode-0.16.1/ode/src/joints/plane2d.h create mode 100644 libs/ode-0.16.1/ode/src/joints/pr.cpp create mode 100644 libs/ode-0.16.1/ode/src/joints/pr.h create mode 100644 libs/ode-0.16.1/ode/src/joints/pu.cpp create mode 100644 libs/ode-0.16.1/ode/src/joints/pu.h create mode 100644 libs/ode-0.16.1/ode/src/joints/slider.cpp create mode 100644 libs/ode-0.16.1/ode/src/joints/slider.h create mode 100644 libs/ode-0.16.1/ode/src/joints/transmission.cpp create mode 100644 libs/ode-0.16.1/ode/src/joints/transmission.h create mode 100644 libs/ode-0.16.1/ode/src/joints/universal.cpp create mode 100644 libs/ode-0.16.1/ode/src/joints/universal.h create mode 100644 libs/ode-0.16.1/ode/src/lcp.cpp create mode 100644 libs/ode-0.16.1/ode/src/lcp.h create mode 100644 libs/ode-0.16.1/ode/src/mass.cpp create mode 100644 libs/ode-0.16.1/ode/src/mat.cpp create mode 100644 libs/ode-0.16.1/ode/src/mat.h create mode 100644 libs/ode-0.16.1/ode/src/matrix.cpp create mode 100644 libs/ode-0.16.1/ode/src/matrix.h create mode 100644 libs/ode-0.16.1/ode/src/memory.cpp create mode 100644 libs/ode-0.16.1/ode/src/misc.cpp create mode 100644 libs/ode-0.16.1/ode/src/nextafterf.c create mode 100644 libs/ode-0.16.1/ode/src/objects.cpp create mode 100644 libs/ode-0.16.1/ode/src/objects.h create mode 100644 libs/ode-0.16.1/ode/src/obstack.cpp create mode 100644 libs/ode-0.16.1/ode/src/obstack.h create mode 100644 libs/ode-0.16.1/ode/src/ode.cpp create mode 100644 libs/ode-0.16.1/ode/src/odeinit.cpp create mode 100644 libs/ode-0.16.1/ode/src/odemath.cpp create mode 100644 libs/ode-0.16.1/ode/src/odemath.h create mode 100644 libs/ode-0.16.1/ode/src/odeou.cpp create mode 100644 libs/ode-0.16.1/ode/src/odeou.h create mode 100644 libs/ode-0.16.1/ode/src/odetls.cpp create mode 100644 libs/ode-0.16.1/ode/src/odetls.h create mode 100644 libs/ode-0.16.1/ode/src/plane.cpp create mode 100644 libs/ode-0.16.1/ode/src/quickstep.cpp create mode 100644 libs/ode-0.16.1/ode/src/quickstep.h create mode 100644 libs/ode-0.16.1/ode/src/ray.cpp create mode 100644 libs/ode-0.16.1/ode/src/resource_control.cpp create mode 100644 libs/ode-0.16.1/ode/src/resource_control.h create mode 100644 libs/ode-0.16.1/ode/src/rotation.cpp create mode 100644 libs/ode-0.16.1/ode/src/simple_cooperative.cpp create mode 100644 libs/ode-0.16.1/ode/src/simple_cooperative.h create mode 100644 libs/ode-0.16.1/ode/src/sphere.cpp create mode 100644 libs/ode-0.16.1/ode/src/step.cpp create mode 100644 libs/ode-0.16.1/ode/src/step.h create mode 100644 libs/ode-0.16.1/ode/src/threaded_solver_ldlt.h create mode 100644 libs/ode-0.16.1/ode/src/threading_atomics_provs.h create mode 100644 libs/ode-0.16.1/ode/src/threading_base.cpp create mode 100644 libs/ode-0.16.1/ode/src/threading_base.h create mode 100644 libs/ode-0.16.1/ode/src/threading_fake_sync.h create mode 100644 libs/ode-0.16.1/ode/src/threading_impl.cpp create mode 100644 libs/ode-0.16.1/ode/src/threading_impl.h create mode 100644 libs/ode-0.16.1/ode/src/threading_impl_posix.h create mode 100644 libs/ode-0.16.1/ode/src/threading_impl_templates.h create mode 100644 libs/ode-0.16.1/ode/src/threading_impl_win.h create mode 100644 libs/ode-0.16.1/ode/src/threading_pool_posix.cpp create mode 100644 libs/ode-0.16.1/ode/src/threading_pool_win.cpp create mode 100644 libs/ode-0.16.1/ode/src/threadingutils.h create mode 100644 libs/ode-0.16.1/ode/src/timer.cpp create mode 100644 libs/ode-0.16.1/ode/src/typedefs.h create mode 100644 libs/ode-0.16.1/ode/src/util.cpp create mode 100644 libs/ode-0.16.1/ode/src/util.h create mode 100644 libs/ode-0.16.1/ou/CHANGELOG.TXT create mode 100644 libs/ode-0.16.1/ou/INSTALL.TXT create mode 100644 libs/ode-0.16.1/ou/LICENSE-BSD.TXT create mode 100644 libs/ode-0.16.1/ou/LICENSE-LESSER.TXT create mode 100644 libs/ode-0.16.1/ou/LICENSE-ZLIB.TXT create mode 100644 libs/ode-0.16.1/ou/LICENSE.TXT create mode 100644 libs/ode-0.16.1/ou/Makefile.am create mode 100644 libs/ode-0.16.1/ou/Makefile.in create mode 100644 libs/ode-0.16.1/ou/README.TXT create mode 100644 libs/ode-0.16.1/ou/aclocal.m4 create mode 100755 libs/ode-0.16.1/ou/bootstrap create mode 100644 libs/ode-0.16.1/ou/build/make/makefile create mode 100644 libs/ode-0.16.1/ou/build/make/makefile.os create mode 100644 libs/ode-0.16.1/ou/build/vs2005/ou.sln create mode 100644 libs/ode-0.16.1/ou/build/vs2005/ou.vcproj create mode 100644 libs/ode-0.16.1/ou/build/vs6/ou.dsp create mode 100644 libs/ode-0.16.1/ou/build/vs6/ou.dsw create mode 100755 libs/ode-0.16.1/ou/configure create mode 100644 libs/ode-0.16.1/ou/configure.ac create mode 100644 libs/ode-0.16.1/ou/include/ou/Makefile.am create mode 100644 libs/ode-0.16.1/ou/include/ou/Makefile.in create mode 100644 libs/ode-0.16.1/ou/include/ou/assert.h create mode 100644 libs/ode-0.16.1/ou/include/ou/atomic.h create mode 100644 libs/ode-0.16.1/ou/include/ou/atomicflags.h create mode 100644 libs/ode-0.16.1/ou/include/ou/customization.h create mode 100644 libs/ode-0.16.1/ou/include/ou/enumarrays.h create mode 100644 libs/ode-0.16.1/ou/include/ou/features.h create mode 100644 libs/ode-0.16.1/ou/include/ou/flags.h create mode 100644 libs/ode-0.16.1/ou/include/ou/flagsdefines.h create mode 100644 libs/ode-0.16.1/ou/include/ou/inttypes.h create mode 100644 libs/ode-0.16.1/ou/include/ou/macros.h create mode 100644 libs/ode-0.16.1/ou/include/ou/malloc.h create mode 100644 libs/ode-0.16.1/ou/include/ou/namespace.h create mode 100644 libs/ode-0.16.1/ou/include/ou/platform.h create mode 100644 libs/ode-0.16.1/ou/include/ou/simpleflags.h create mode 100644 libs/ode-0.16.1/ou/include/ou/templates.h create mode 100644 libs/ode-0.16.1/ou/include/ou/threadlocalstorage.h create mode 100644 libs/ode-0.16.1/ou/include/ou/typewrapper.h create mode 100644 libs/ode-0.16.1/ou/src/ou/Makefile.am create mode 100644 libs/ode-0.16.1/ou/src/ou/Makefile.in create mode 100644 libs/ode-0.16.1/ou/src/ou/atomic.cpp create mode 100644 libs/ode-0.16.1/ou/src/ou/customization.cpp create mode 100644 libs/ode-0.16.1/ou/src/ou/malloc.cpp create mode 100644 libs/ode-0.16.1/ou/src/ou/threadlocalstorage.cpp create mode 100644 libs/ode-0.16.1/ou/test/Makefile.am create mode 100644 libs/ode-0.16.1/ou/test/Makefile.in create mode 100644 libs/ode-0.16.1/ou/test/outest.cpp create mode 100755 libs/ode-0.16.1/test-driver create mode 100644 libs/ode-0.16.1/tests/Makefile.am create mode 100644 libs/ode-0.16.1/tests/Makefile.in create mode 100644 libs/ode-0.16.1/tests/UnitTest++/COPYING create mode 100644 libs/ode-0.16.1/tests/UnitTest++/Makefile.am create mode 100644 libs/ode-0.16.1/tests/UnitTest++/Makefile.in create mode 100644 libs/ode-0.16.1/tests/UnitTest++/README create mode 100644 libs/ode-0.16.1/tests/UnitTest++/docs/UnitTest++.html create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/AssertException.cpp create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/AssertException.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/CheckMacros.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/Checks.cpp create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/Checks.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/Config.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/DeferredTestReporter.cpp create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/DeferredTestReporter.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/DeferredTestResult.cpp create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/DeferredTestResult.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/Makefile.am create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/Makefile.in create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/MemoryOutStream.cpp create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/MemoryOutStream.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/Posix/Makefile.am create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/Posix/Makefile.in create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/Posix/SignalTranslator.cpp create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/Posix/SignalTranslator.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/Posix/TimeHelpers.cpp create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/Posix/TimeHelpers.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/ReportAssert.cpp create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/ReportAssert.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/Test.cpp create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/Test.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/TestDetails.cpp create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/TestDetails.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/TestList.cpp create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/TestList.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/TestMacros.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/TestReporter.cpp create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/TestReporter.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/TestReporterStdout.cpp create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/TestReporterStdout.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/TestResults.cpp create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/TestResults.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/TestRunner.cpp create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/TestRunner.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/TestSuite.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/TimeConstraint.cpp create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/TimeConstraint.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/TimeHelpers.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/UnitTest++.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/Win32/Makefile.am create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/Win32/Makefile.in create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/Win32/TimeHelpers.cpp create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/Win32/TimeHelpers.h create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/XmlTestReporter.cpp create mode 100644 libs/ode-0.16.1/tests/UnitTest++/src/XmlTestReporter.h create mode 100644 libs/ode-0.16.1/tests/collision.cpp create mode 100644 libs/ode-0.16.1/tests/friction.cpp create mode 100644 libs/ode-0.16.1/tests/joint.cpp create mode 100644 libs/ode-0.16.1/tests/joints/Makefile.am create mode 100644 libs/ode-0.16.1/tests/joints/Makefile.in create mode 100644 libs/ode-0.16.1/tests/joints/amotor.cpp create mode 100644 libs/ode-0.16.1/tests/joints/ball.cpp create mode 100644 libs/ode-0.16.1/tests/joints/dball.cpp create mode 100644 libs/ode-0.16.1/tests/joints/fixed.cpp create mode 100644 libs/ode-0.16.1/tests/joints/hinge.cpp create mode 100644 libs/ode-0.16.1/tests/joints/hinge2.cpp create mode 100644 libs/ode-0.16.1/tests/joints/piston.cpp create mode 100644 libs/ode-0.16.1/tests/joints/pr.cpp create mode 100644 libs/ode-0.16.1/tests/joints/pu.cpp create mode 100644 libs/ode-0.16.1/tests/joints/slider.cpp create mode 100644 libs/ode-0.16.1/tests/joints/universal.cpp create mode 100644 libs/ode-0.16.1/tests/main.cpp create mode 100644 libs/ode-0.16.1/tests/odemath.cpp create mode 100644 libs/ode-0.16.1/tools/README.txt create mode 100644 libs/ode-0.16.1/tools/msw-release.bat create mode 100644 libs/ode-0.16.1/tools/ode_convex_export.py create mode 100644 libs/ode-0.16.1/tools/src-release.sh diff --git a/CMakeLists.txt b/CMakeLists.txt index 46db609..911b8ba 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -37,12 +37,13 @@ add_subdirectory(${LIB_ROOT}/honeysuckle) add_subdirectory(${LIB_ROOT}/cglm) add_subdirectory(${LIB_ROOT}/glfw-3.3.8) add_subdirectory(${LIB_ROOT}/cargs) +add_subdirectory(${LIB_ROOT}/ode-0.16.1) set(HONEY_SOURCE ${SRC_ROOT}/main.c) add_executable(honey ${HONEY_SOURCE}) -set(LIBRARIES lua5.1 honeysuckle glfw cargs assimp cairo) +set(LIBRARIES lua5.1 honeysuckle glfw cargs assimp cairo ode) if (WIN32) set(LIBRARIES ${LIBRARIES} opengl32) else() diff --git a/demo/honey.lua b/demo/honey.lua index d543488..4b1526f 100644 --- a/demo/honey.lua +++ b/demo/honey.lua @@ -200,9 +200,8 @@ image.context_move_to(cr, 100, 100) image.context_show_text(cr, "hello, world!") local data = image.surface_get_data(surface) gl.BindTexture(gl.TEXTURE_2D, texture) -gl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_SWIZZLE_R, gl.GREEN) -gl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_SWIZZLE_G, gl.BLUE) -gl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_SWIZZLE_B, gl.ALPHA) +gl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_SWIZZLE_R, gl.BLUE) +gl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_SWIZZLE_B, gl.RED) --gl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_SWIZZLE_A, gl.RED) gl.TexImage2D( gl.TEXTURE_2D, 0, diff --git a/libs/ode-0.16.1/CHANGELOG.txt b/libs/ode-0.16.1/CHANGELOG.txt new file mode 100644 index 0000000..0f0678d --- /dev/null +++ b/libs/ode-0.16.1/CHANGELOG.txt @@ -0,0 +1,1285 @@ +ODE CHANGELOG +------------- + +the rules for this file: + * entries are sorted newest-first. + * summarize sets of changes - dont reproduce every CVS log comment here. + * don't ever delete anything. + * keep the format consistent (79 char width, M/D/Y date format). + +------------------------------------------------------------------------------ +11/12/2018 Oleh Derevenko + * The commentary from 11/05/2018 was wrong. The constraints were not + reset to their natural order and remained randomized. + The other thing that was missing was full contraint reorder without + separation into independent and dependent ones. The algorithm doesn't + converge without it well. + +11/10/2018 Oleh Derevenko + * An incorrect optimization to Jacobian Copy building code from #1938 + that resulted in corrupt data in multi-threaded execution mode was + fixed. + +11/05/2018 Oleh Derevenko + * An unintended change from commit #1898 has been reverted. + The QuickStep used to solve with randomized constraint order + each 8th iteration. The other iterations, the constraints + were reset to their natural order, as generated, with the dependent + constraints gathered in reverse order at end (the reverse order is + somehow important). With the commit #1898 the constraints were + randomly reordered each 8th iteration but then remained + in that randomized order and only were re-randomized on subsequent + multiples of 8. + +10/09/2017 Markus Rickert + * CMake support for project file generation has been added. + +06/14/2017 Oleh Derevenko + * dxHashSpace::collide() has been changed to fault host program + if scene gets too large and causes integer overflow. + +06/06/2017 Oleh Derevenko + * Memory and pointer size integer type use has been changed so that + internal typedefs are used instead of "_t" suffixed types. + +05/09/2017 Oleh Derevenko + * Introduction of cooperative algorithms API. + L*D*LT cooperative factorization and linear equation system + cooperative solving have been implemented. + * AtomicReadReorderBarrier, AtomicStore, AtomicStorePointer functions + have been added and some atomic function implementations have been + improved in OU. + +02/20/2017 Oleh Derevenko + * Project generation options have been changed to have built-in + multithreaded threading implementation enabled by default. + +02/19/2017 Oleh Derevenko + * dWorldStep threaded implementation has been extended to the final + steps of constraint force applications and body position updates + after the LCP solving. Note that body callbacks (if set) may be + called from multiple threads if threaded execution is enabled. + * OU atomicord32 type has been fixed to be unsigned on all supported + platforms. + +01/09/2017 Oleh Derevenko + * dGeomTriMeshDataPreprocess2() public function has been added to + replace dGeomTriMeshDataPreprocess(). Face angles pre-computation + for triangle meshes has been implemented. + +11/13/2016 Oleh Derevenko + * dGeomTriMeshDataGetBuff and dGeomTriMeshDataSetBuff have been marked + deprecated and their functionality implemented via + dGeomTriMeshDataGet and dGeomTriMeshDataSet. Extra function variant + dGeomTriMeshDataGet2() has been added to allow returning data size. + +11/07/2016 Oleh Derevenko + * The implementation of OPCODE TriMesh data pre-processing + (dGeomTriMeshDataPreprocess()) has been optimized to only contain + a sort and a single pass over edges (used to be a sort and O(N^2)). + +10/29/2016 Oleh Derevenko + * dGeomTriMeshDataPreprocess() public function has been changed to + return a boolean status (it can fail in low memory conditions). + +07/10/2016 Oleh Derevenko + * The correct handling of dJOINT_REVERSE mode for AngularMotor Joint + implemented (issue #37). + +06/29/2016 Oleh Derevenko + * A bug fixed with HashSpace calling big boxes collision twice + (both straight and reverse geometries order) since revision #1831. + +06/03/2016 Oleh Derevenko + * dJointSetHinge2Axes public function has been added and + dJointSetHinge2Axis1/2 have been marked deprecated due to being + unsafe. + +05/13/2016 Oleh Derevenko + * ICE Container class allocation strategy fixed to avoid reserving + excess memory with large collections. + +05/10/2016 Oleh Derevenko + * dSafeNormalize3 and dSafeNormalize4 functions changed to leave the + parameter intact instead of replacing it with the X-axis unit in case + of fault. + +04/12/2016 Oleh Derevenko + * A function to create a self-threaded threading implementation object + has been moved back to public headers as there could be a use for it + while running several worlds in parallel threads. + +01/09/2016 Oleh Derevenko + * Hinge2 joint corected to avoid faulting asserts when the axes get + temporarily invalid during assignments (suggested by David Mansolino) + +01/03/2016 Oleh Derevenko + * An invalid memory access fixed in dxSAPSpace::BoxPruning() in case + if there were NaN values in AABBs to be sorted. + +12/25/2015 Oleh Derevenko + * Unexpected joint mode assignment (instead of comparison) fixed within + an dUASSERT in dJointSetTransmissionAxis2() of transmission joint + +11/28/2015 Oleh Derevenko + * Convex-Trimesh collider added (libccd+GIMPACT only)(by Piotr Piastucki) + * dCreateConvex() and dGeomSetConvex() public APIs changed to expect + their parameter arrays as const pointers + +11/01/2015 Oleh Derevenko + * OPCODE mesh colliders' input coordinates have been offset to + mesh-relative frames to decrease potential computational errors + (suggested by luckytrashsc2@g***l.com) + +08/05/2015 Oleh Derevenko + * Implemented change to return highest depth contacts subset for GIMPACT + in cases if contacts count exceeds requested maximum (as suggested in + the issue #36 by Piotr Piastucki) + +11/17/2014 Daniel K. O. + * Added support for using libccd from the system (if found via + pkg-config) + +11/10/2014 Oleh Derevenko + * Floating point division by zero in capsule-ray collision routine + in case if the ray axis was parallel the cylinder and the ray started + from within it fixed (issue #26) + +11/08/2014 Oleh Derevenko + * Threading support has been extended to complete implementation + of QuickStep + +10/29/2014 Daniel K. O. + * Added dJointSetDBallDistance + +10/19/2014 Oleh Derevenko + * Built-in threading implementation compilation fixed for OSX + (clock_gettime() is missing from the system - reported by Bram) + +08/10/2014 Oleh Derevenko + * Declarations of dWorld[Get/Set]AutoDisableLinearAverageThreshold and + dWorld[Get/Set]AutoDisableAngularAverageThreshold have been removed + from public headers (were orphaned since rev.1052) + +07/16/2014 Oleh Derevenko + * Two fixes by Francesco Cat applied (fixes for mistakes made during + code style improvements in the past) + +02/27/14 Daniel K. O. + * Added dODE_VERSION macro to public headers (issue #24). + +02/11/14 Daniel K. O. + * Added dJointGetHinge2Angle2 (issue #12). + +02/07/14 Daniel K. O. + * Added dWorldSetData/dWorldGetData (issue #21). + +01/31/14 Daniel K. O. + * Applied patch #185: Stable, implicit gyroscopic forces. + +01/27/14 Daniel K. O. + * Fixed cylinder AABB computation. + +01/25/14 Daniel K. O. + * Removed ALLOCA calls from dHashSpace; it should not depend + on stack size limits anymore. + +12/06/13 Daniel K. O. + * Applied patch #181: fix some bugs in AMotor joint. + * Applied patch #186: fix some bugs in PU joint. + * Applied patch #182: Transmission joint. + * Applied patch #184: implement rolling friction for contacts. + +08/08/13 Oleh Derevenko + * Joint feedback forces application fixed in QuickStep implementation + (was broken since revision #1919 in old repository (#1927 in new one)) + +08/04/13 Oleh Derevenko + * Bugfix #89 by Luc applied (dJointAddSliderForce() adds a zero force + when the parent body is NULL) + +05/18/13 Oleh Derevenko + * OU library has been included in ODE at revision #46 instead of + being used as an external link due to difficulties using external + references with new protocol used for storage at SF. + +03/03/13 Oleh Derevenko + * Fixed issue with "findex==-1" constraints being intermixed with + "findex!=-1" ones during constraints random reordering in QuickStep. + +02/03/13 Oleh Derevenko + * [u]int[8/16/32] renamed to contain "d" prefix so that global namespace + was not polluted with these names unconditionally. + If your project depended on these types other than just for passing + parameters to ODE calls, add similar typedefs for yourself in some + of your project's global headers. + +01/02/13 Oleh Derevenko + * Applied patch #183 by Joseph Cooper (complementary matrix + calculation fix). + +12/28/12 Oleh Derevenko + * A bug with heightfield data assigned to a wrong field in + dGeomHeightfieldSetHeightfieldData fixed (bug report #88 by Luc). + +12/18/12 Oleh Derevenko + * Fixed issue with some kinds of joints (Ball, DBall, DHinge, Fixed) + might overwrite world ERP value with their custom ERP during + getInfo2() call and that inappropriate value would then be passed + to subsequent joints in solver instead of world ERP. + +12/01/12 Oleh Derevenko + * Fixed issues reported in patches #151 and #22 (collisions with + SAPSpace and QuadTreeSpace might not work because geometries list + was misused in them). + * Applied patch #160 "IsPointInPolygon in convex.cpp returns wrong + results" (by Janis Rucis) + +11/25/12 Oleh Derevenko + * Configuration option --disable-threading-intf added + (--no-threading-intf for Windows/Premake). This allows disabling + threading interface support (external implementations may not be + assigned) but eliminates dependency on OU and use of atomics in + steppers. + +11/05/12 Oleh Derevenko + * Fixed zero comparisons in OPCODE to use relative error instead of + absolute epsilon value (found by Bill Sellers) + +06/08/12 Daniel K. O. + * Removed the need for defining dSINGLE/dDOUBLE; this is stored now in + the generated ode/precision.h header. + * Some code cleanup to get rid of GCC warnings. + +05/30/12 Daniel K. O. + * Made drawstuff draw shadows for lines. + * Fixed dhinge's last constraint to properly handle rotations. + +05/03/12 Daniel K. O. + * Added two new joints: Double Ball and Double Hinge. + +04/22/12 Daniel K. O. + * Fixed plane2d joint: uninitialized variables (reported by Dimitris + Papavasiliou) + +04/14/12 Oleh Derevenko + * Assertion checking macros moved into library private headers. + +04/13/12 Daniel K. O. + * Applied patch from bug #3431829 - better handling of capsule-box with + deep penetrations. + * Fixed zero-mu issues: now either mu or mu2 can be set to zero. + +03/17/12 Oleh Derevenko + * Threaded execution support interface added. Optional built-in threading + implementation added. + Internal threading implementation is excluded by default and to be used, + it must be enabled with configure/premake. + At present, if threading interface is assigned to a world, island + selection and stepping is performed in multiple threads (one thread per + island). + +03/12/12 Oleh Derevenko + * PURE_INLINE macro renamed to ODE_PURE_INLINE and definition of + dNextAfter()/dCopySign() corrected to avoid creating conflicts with + other libraries. + +02/03/12 Oleh Derevenko + * Assertion checking macros moved from common.h to error.h + +12/18/11 Oleh Derevenko + * dIVERIFY macro added (same as dIASSERT in debug mode but evaluates its + expression in release mode) to be used to assert variable value + which is not used further in text while avoiding compiler warning. + * dICHECK macro added (same as dIASSERT but evaluates its expression and + raises assertion fault regardless of compilation mode) to be used to + generate a fault in cases when error is very unlikely but must be + handled and handling is very troublesome (e.g. failure to lock a mutex + due to lack of resources). + +12/07/11 Oleh Derevenko + * Partially fixed size_t to integer conversion warnings + * Fixed type signedness and added casts to size_t wherever necessary + in Step/QuickStep + +11/04/11 Daniel K. O. + * Applied patch #3429454 - fix compilation on some platforms. + +10/28/11 Daniel K. O. + * Fixed a box-capsule bug: more reasonable normal for deep penetrations + (contributed by Georg Martius.) + +10/27/11 Daniel K. O. + * Disabled merging of contacts for trimesh-sphere by default. + * Added new demo: demo_tracks. + +10/17/11 Daniel K. O. + * Added python bindings, contributed by Gideon Klompje. + * Updated some build scripts. + * Changed spheres distribution in demo_space_stress. + +05/17/11 Oleh Derevenko + * A typo in step.cpp fixed (assignment operator in a conditional + instead of comparison) (reported by Bram Stolk) + +01/29/11 Oleh Derevenko + * Heightfield zone boundaries calculation code fixed to also consider + whole next cell after the AABB if the AABB ends exactly at the cell + boundary. + +01/23/11 Daniel K. O. + * Applied patch from Daniel Fiser, add libccd collider for + box-cylinder. + +01/20/11 Daniel K. O. + * Applied patch from Daniel Fiser, fix infinite loop in libccd caused + by numerical problems. + +01/06/11 Daniel K. O. + * Applied patch from Daniel Fiser, efficient libccd tests when using + CONTACTS_UNIMPORTANT. + +12/17/10 Daniel K. O. + * Applied patches from Daniel Fiser for new colliders based on libccd. + +11/08/10 Daniel K. O. + * Applied patches from Daniel Fiser to incorporate libccd for + Cylinder-Cylinder collision tests. + +08/21/10 Oleh Derevenko + * Fix applied to dxReallocateTemporayWorldProcessContext() to remove typo + which caused segmentation fault (by Kyle McKay). + dTestSolveLCP() fixed to avoid exceeding allocated memory pool + (by Kyle McKay). + +07/19/10 Oleh Derevenko + * Patch applied (#3030783) to fix drawstuff dimensions being ignored + in OSX GLUT port (by Danny Price). + + Daniel K. O. + * Applied patch #2991622: dGeomGetRelPointPos, dGeomGetPosRelPoint, + dGeomVectorToWorld, and dGeomVectorFromWorld. + +07/16/10 Daniel K. O. + * Fixed bug #2937076: don't try to build demos if drawstuff is disabled. + +05/02/10 Oleh Derevenko + * Missing extern "C" wrapper has been added to include/ode/export-dif.h + (reported by Danny Price). The change affects dWorldExportDIF() public + function. + +05/02/10 Oleh Derevenko + * Patch applied (#2995450) to generate up to four contacts for box- + plane collision test (by alexdu) and fix contact depths. + +05/02/10 Oleh Derevenko + * dGeomLowLevelControl function added with ability to change/query OPCODE + trimesh-sphere contact merging behavior at runtime. + +02/18/10 Daniel K. O. + * Fixed bug affecting disabled joints and dWorldStep. + +01/16/10 Oleh Derevenko + * Patch applied (#2931174) to make demos work for recent MacOS. + * Patch applied (#2931177) to fix the demos' framerate on X11. + +12/20/09 Oleh Derevenko + * QuadTreeSpace implementation corrected to avoid object-block relation + ambiguity due to numeric errors. + +12/04/09 Oleh Derevenko + * odecpp classes changed to be inheritable and easily expandable + +11/29/09 Oleh Derevenko + * Improvement for trimesh-plane collision (also used in trimesh-heightfield) + to exclude mesh vertices that have already generated contacts from further + examination and contact generation in other triangles (suggested by LR). + +10/25/09 Oleh Derevenko + * Macros changed to static inline functions in odemath.h and related files. + Some code duplication has been eliminated across the files. + + * Fixed handling of --disable-asserts and --enable-double-precision + (absence of --enable-double-precision) in configure script. The script + was not appending compiler defines correctly. + + * dWorldStep implementation changed to remove allocation on stack. + dUSE_MALLOC_FOR_ALLOCA define has been removed as well as corresponding + configuration parameter. Also dMemoryFlag public variable has been removed. + (look for presence of ODE_EXT_malloc_not_alloca configuration string if + your application is dependent on that variable). + +09/05/09 Oleh Derevenko + * dWorldStepFast1 API removed along with dWorld[Get/Set]AutoEnableDepthSF1 + +08/29/09 Oleh Derevenko + * Fixed uninitialized floating point array used in computations. + +08/12/09 Oleh Derevenko + * A typo fixed in dGeomCopyOffsetRotation() (final_posr was used instead + of offset_posr). Reported by Tilmann. + +08/11/09 Daniel K. O. + * Made sure neither dSINGLE or dDOUBLE is defined by default; the user + should always explicitly specify the precision. + +06/27/09 Oleh Derevenko + * New functions have been added: + - dWorldUseSharedWorkingMemory + - dWorldCleanupWorkingMemory + - dWorldSetStepMemoryReservationPolicy + - dWorldSetStepMemoryManager + +06/25/09 Remi Ricard (papaDoc) + * Add limit to the to the second axis of the universal joint + for the pu joint. + +06/14/09 Oleh Derevenko + * dWorldQuickStep re-implemented to avoid memory allocation on stack. + Also several optimizations have been made to decrease memory + requirements and optimize algorithm implementation of dWorldQuickStep. + dWorldStep still remains with old memory allocation however new APIs + mentioned below are fully functional for it. + Both dWorldStep and dWorldQuickStep have been changed to return boolean + success status. + + * dInitODE2() changed to automatically call + AllocateODEDataForThread(dAllocateFlagBasicData) after library + initialization as this is a required initialization minimum that + must always be performed anyway. + +06/05/09 Daniel K. O. + * Removed aliasing issues from OPCODE/Ice, plus some other warnings. + Now it builds on gcc 4.3.2 with '-Wall -Werror -O3". + +05/30/09 Oleh Derevenko + * A minor memory usage optimization for QuickStep. + +05/24/09 Daniel K. O. + * Made the new trimesh collider the default. + * Added a "-texturepath" option to drawstuff. + +05/18/09 Oleh Derevenko + * Heightfield rotation fixed to avoid NaNs while rotating infinite + MIN/MAX heights. + +05/03/09 Oleh Derevenko + * Incorrect parameter order fixed on contact merging in Sphere-Trimesh + collisions. The bug resulted in merged contact remaining with normal + of first contact found. Thanks to Dimitris Papavasiliou for reporting. + +04/23/09 Daniel K. O. + * Fixed bug #2685170: use the C99 __func__ instead of __FUNCTION__ when + a C99 implementation is available. + +04/07/09 Remi Ricard (papaDoc) + * Remove unused code in demo_joints.cpp, reported by Tilmann. + +04/07/09 Remi Ricard (papaDoc) + * Fix bug in collision categories in demo_jointPU, reported by Tilmann + +03/14/09 Oleh Derevenko + * A possibility to initialize/close ODE multiple times recursively has + been added. + Also, now a call to dSpaceSetManualCleanup() is required for each + space right after creation if ODE has been initialized in thread data + manual cleanup mode. + +03/07/09 Oleh Derevenko + * Thread local data has been cleaned up from OPCODE and OdeTls as it is + not used (OPC_SweepAndPrune.* and OPC_BoxPruning.* have been removed + - rebuilding project files is necessary). + +02/07/09 Daniel K. O. + * New house of cards demo, which stresses the friction handling stability. + +01/29/09 Remi Ricard (papaDoc) + * Fix bug: Fix problem when attaching no body to a joint. Before calling + setRelativeValues a check is made for bodies. + * Add unittest + +01/28/09 Daniel K. O. + * Applied patch #2538046: Heightfield AABB bounds patch. + +01/23/09 Remi Ricard (papaDoc) + * Add new function dJointSetUniversalAxis1Offset and dJointSetUniversalAxis2Offset + * Add unittest for those funcitons. + +01/23/09 Remi Ricard (papaDoc) + * Fix problem with dJointGetUniversalAngle2 when the joint is attached to + only a body 2. The sign was inverted. + * Add unit test to verify for this problem + +01/21/09 Remi Ricard (papaDoc) + * Fix bug reported by Tilman: dxJointPU::getInfo1 was setting twice the + limit of limot1 to zero and not limot2 + +01/17/09 Daniel K. O. + * Fixed a bug in dSpaceCollide2: if both geoms are not in spaces they would + not have valid AABBs. + +12/20/08 Daniel K. O. + * New functions: dJointEnable, dJointDisable, dJointIsEnabled + (patch #2454764). + +12/19/08 Daniel K. O. + * Removed inline asm statements that break builds on 64-bit VC++. + +12/09/08 Daniel K. O. + * Applied patch #2381592, which adds support for Kinematic Bodies. + +12/06/08 Oleh Derevenko + + * Applied a patch by Martijn Buijs to make GIMPACT trimesh-ray collisions to + be consistent with those in OPCODE. + * Swapped geometries returned in contacts for OPCODE Trimesh-Plane collisions + as they were returned in unnatural order being different from that in GIMPACT + * Applied a patch by Martijn Buijs to make side1, side2 fields of contact + structure be always initialized, either with -1 for non-trmesh geometries + or with triangle index for trimeshes. These fields were only assigned for + trimesh-trimesh collisions before. + * dGeomTriMeshSetTriMergeCallback/dGeomTriMeshGetTriMergeCallback API added + to set/get user defined callback procedure for trimeshes that would be + invoked when contacts are merged to let user code accumulate attributes of + original contact triangles and generate a fake index by which it would + later be able to determine those attributes. If the callback is not + assigned (the default) -1 is generated as triangle index for merged + contacts (there was an index of first of merged triangles before!!!). + The callback is currently used within OPCODE trimesh-sphere and OPCODE + new trimesh-trimesh collisions. + +11/20/08 Remi Ricard (papaDoc) + * Fix problem with dJointGetPUPosition and + dJointGetPUPositionRate when the joint is attached to only + a body 2. The sign was inverted. + * Fix bug: When a pu joint had only one body attached to position 2, + dJointAttach(jId, 0, bId). The body was not push in the right direction to + move back between the limits. + * Add unit test to check the above problem + * Add the function void dJointSetPUAnchorOffset + * Make the function void dJointSetPUAnchorDelta deprecated + +11/19/08 Remi Ricard (papaDoc) + * Fix bug: When a pr joint had only one body attached to position 2, + dJointAttach(jId, 0, bId). The body was not push in the right direction to + move back between the limits. + * Add unit test to check the above problem + +11/19/08 Remi Ricard (papaDoc) + * Fix problem with dJointGetPRPosition and + dJointGetPRPositionRate when the joint is attached to only + a body 2. The sign was inverted. + * Add unit test to check the above problem + * Increase the tolerance to remove failure in unit test + * Remove compilation warning in unit test with the use of REAL() + +11/18/08 Remi Ricard (papaDoc) + * Fix bug: When a piston joint had only one body attached to position 2, + dJointAttach(jId, 0, bId). The body was not push in the right direction to + move back between the limits. + * Add more functionality to demo_piston.cpp + * Run astyle on modified files. + +11/18/08 Remi Ricard (papaDoc) + * Fix bug: When a slider joint had only one body attached to position 2, + dJointAttach(jId, 0, bId). The body was not push in the right direction to + move back between the limits. + +10/29/08 Oleh Derevenko + + * Premake scripts changed to only include chosen collision library + sources in project on Windows. --all-collis-libs premake option + added to allow inclusion of all collision library sources into the + project + +10/15/08 Remi Ricard (papaDoc) + * Applying patch #2158425 64-bit GIMPACT provided by Mark + William. This patch enable GIMPACT to works on 64-bit machine. + +10/15/08 Remi Ricard (papaDoc) + * Add function dJointGetPRAngle and dJointGetPRAngleRate + +10/15/08 Remi Ricard (papaDoc) + * Enable the motor on the rotoide part of the PR joint + +10/15/08 Remi Ricard (papaDoc) + * Add unit test to check if using directly a joint + or using after setting with default values is the same. + * Add function setRelativeValues called in dJointAttach for + all joints. + +10/10/08 Remi Ricard (papaDoc) + * Fix bug in dJointGetPUAxis2. The axis was not multiplied with the + the rotation matrix of the good body. + * Fix bug if there is only one body on the PU joint the axis returned + was not the right one. + * Add unit test to verify previous bug. + +10/03/08 Rodrigo Hernandez (Kwizatz) + * Added Blender script to create ODE convex geoms under tools. + +10/01/08 Rodrigo Hernandez (Kwizatz) + * Convex-Convex collision detection code is finally stable. + +08/31/08 Daniel K. O. + * Applied patch 2080674: Improved dBodySetRotation; now exact rotation + matrices are preserved until the next simulation step. + +08/07/08 Daniel K. O. + * Fixed strict aliasing issue that was breaking the new trimesh collider. + +07/24/08 Daniel K. O. + * New functions: dBodyGetGyroscopicMode and dBodySetGyroscopicMode + (patch #2019242). + +07/15/08 Remi Ricard (papaDoc) + * Add a new define ODE_API_DEPRECATED to mark function as deprecated + when necessary. + +07/14/08 Remi Ricard (papaDoc) + * Finish adding patch 1336066: Joint feedback in quickstep by jsinecky + * demo_boxstack.cpp can now print joint feedback + +07/11/08 Daniel K. O. + * Bumped version for 0.10.1 + * Added proper usage of libtool's version info. + +07/10/08 Remi Ricard (papaDoc) + * Add new function dJointSetPistonAnchorOffset + * Add unittest for the piston joint + * Fix problem with dJointGetPistonPosition and + dJointGetPistonPositionRate when the joint is attached to only + a body 2. The sign was inverted. + +07/09/08 Remi Ricard (papaDoc) + * Optimize function Multiply1_12q1 in quickstep + Patch proposed by Riemer v.d. Zee and modified by Patrick Baggett + +07/08/08 Remi Ricard (papaDoc) + * Update the slider joint to have the same behavior as the other joint + when there is only a body2 attached to it. + * Update documentation for the slider joint. + * Remove warning by using REAL() + * Add new unittest for dJointGetSliderPositionRate + +07/08/08 Remi Ricard (papaDoc) + * Update unittest for the slider. + * Rename the new function dJointSetHingeAxisDelta to + dJointSetHingeAxisOffset. This remove will remove confusion with + the old function dJointSetHingeAnchorDelta + * Update documentation for the Hinge unittest + * Remove warning by using REAL() + +07/07/08 Daniel K. O. + * Max Correcting Vel doesn't affect bounciness, as before. + +07/03/08 Remi Ricard (papaDoc) + * Add new function dJointSetHingeAxisDelta + * Add unittest for this new function + +06/17/08 Remi Ricard (papaDoc) + + * Move the computation of the Relative Rotation for the slider joint + into a function. + * Add unittest for to check qrel + +06/17/08 Remi Ricard (papaDoc) + + * Remove unused variables. + * Remove a conversion warning between unsigned int and int + +06/17/08 Remi Ricard (papaDoc) + + * Move the function hingeComputeRelativeRotation as a member of + the hinge structure/class. + +06/17/08 Remi Ricard (papaDoc) + + * Move the computation of the Relative Rotation for the fixed joint + into a function. + +06/16/08 Remi Ricard (papaDoc) + + * Add testunit for the dxJointFixed + +06/04/08 Daniel K. O. + + * Moved joints to ode/src/joints, converted them to true virtual + methods. + +06/02/08 Daniel K. O. + + * Added an Auto template to step.cpp to handle memory deallocation. + +05/09/08 Daniel K. O. + + * Applied patch #1335202: Contact Joint Motion (with some corrections), + and added demo_motion. + +05/01/08 Oleh Derevenko + + * Memory leak in GIMPACT fixed (reported by Derek) + +04/28/08 Oleh Derevenko + + * Added possibility to collide a space of lower sublevel as a geometry + against another space of a higher level with dSpaceCollide2. + dSpaceSetSublevel/dSpaceGetSublevel are used for sublevel assignment/ + retrieval. + +04/27/08 Oleh Derevenko + + * Fixed incorrect memory copying which could lead to memory corruption + in GIMPACT (luckily, in unused code) + * Fixed possible memory read beyond the end of allocated buffer along + with unnecessary extra memory copying in GIMPACT. + * Fixed buffer reserve being incorrectly reset to zero for bitsets + what resulted in unnecessary memory reallocations in GIMPACT. + * Implemented support for ability to run collision detection from + multiple threads for separate spaces. + +04/14/08 Oleh Derevenko + + * Fixed possible memory corruption in new trimesh-trimesh collider + in case if two degenerated triangles are checked against each other. + +04/12/08 Oleh Derevenko + + * Fixed sporadic assertion failure on vector normalization caused + by small triangles degenerating into segments during space + transformations. + +03/28/08 Remi + + * Fix a bug in dJointXXXGetInfo. The value in limot.limit was not + always updated. (Ex: If hi and lo limit were changed). + +03/27/08 Remi + + * Added a new Joint: Prismatic Universal (patch #1828454). + + Daniel K. O. + + * Fixed bug #1841309: collide2() method buggy. + +03/18/08 Rodrigo + + * New function: dVector4Copy. + +03/14/08 david + + * Added stub calls for trimesh functions. + * Applied patch #1914232: dGetConfiguration. + * Applied patch #1655333: Optimize the function dNormalize3. + * New function: dSetColliderOverride. + * New function: dCheckConfiguration. + + Daniel K. O. + + * Disabled building shared library by default with autotools. + +03/13/08 david + + * New function: dJointGetNumBodies (patch #1901550). + * New function: dSpaceGetClass (patch #1901637). + * Applied patch #1901649: Add missing function in the export + +03/12/08 Rodrigo + + * Fixed drawstuff build issues on OSX. + +01/12/08 Daniel K. O. + + * Fixed a typedef bug in configure.in. + * Added dCylinder to the C++ wrappers. + * Applied patch 1851394: support for GIMPACT with double precision, + dCollide fix. + * Moved bunny geometry to bunny_geom.h. + +12/11/07 Daniel K. O. + + * Added damping and MaxAngularVel() functions. + * Const-correctness: added const qualifier to some dWorldGet and dBodyGet + functions. + * Updated the odecpp.h header. + +12/07/07 Daniel K. O. + + * Removed most of the compiler warnings from Drawstuff, ODE and + OPCODE + * Upgraded automake requirement to 1.10, and change some Makefile.am + +12/06/07 Rodrigo + + * Modified autotools to use libtool for + library generation and administration + * Removed release and debug flags for configure.in + CPPFLAGS, CFLAGS, CXXFLAGS should be set by the + user to their liking, respecting autotools policies. + +11/30/07 Daniel K. O. + * Applied patch 1813079 (moved callback) + * Replaced moveAndRotateBody by dxStepBody in stepfast.cpp + +11/10/07 david + + * Added 'Sweep and Prune' collision space. + * New Piston joint type with demo, by Remi Ricard + * Added build option to use 16-bit indices for OPCODE trimesh + +11/03/06 david + + * Integrated Christoph Beyer's average based sampling system for body + disabling. + +10/26/06 Francisco Leon + + * Totally refactored trimesh collision system. + Using GIMPACT instead of OPCODE. Now works correctly, and faster. + Visit http://gimpact.sourceforge.net. + + * Finally, test_moving_trimesh.exe works nicely. + + * Fixed autodisable system. Now is possible to set bigger sleeping + threshold values and objects won't be sleeping on the air. They will + rest on the floor properly. + + * dInitODE function added. + + * Is Obligatory to call dInitODE() at the beginning for initialize ODE, + and calling dCloseODE() when the program ends. + +09/20/06 bram + + * Fixed two bugs in cyl/plane collision test. + +09/13/06 Remi + + * New Rotoide - Prismatic joint type + * dJointGetUniversalAngles for efficient angle retrieval. + +08/09/06 david + + * Integrated plane2d joint type which constrains bodies to z == 0. + +07/06/06 david + + * Added heightfield primitive collision code. Simple test available in + ode/test/test_heightfield + +04/03/06 rodrigo + + * Added Convex primitive collision code, + currently only convex-sphere and convex-plane work + +04/01/06 bram + + * Added program to test trimesh vs sphere: ode/test/test_basket + +03/20/06 jason379 + + * Added new autogenerated Visual Studio projects, with Premake scripts + +03/17/06 bram + + * Added plane/cyl intersection test + * Renamed CCylinder to Capsule + +02/04/06 gcarlton + + * Added support for geom offsets. + +10/26/05 rodrigo + + * Removed LIBTOOL from autotools since it was not really required. + * Added a target to build ODE as a shared library, this shared + library gets build alongside the static one, no flags required. + +10/24/05 tfautre + + (Backported patches from STABLE branch, applied by Adam) + + * dRandInt changed for a non-double all-int version. + * mics minor fixes and improvements. + +04/05/05 tfautre + + * Fixed segmentation fault with OPCODE on 64 bits systems. + +03/31/05 tfautre + + * Fixed timer.cpp compiler error on x86-64 using GCC. + +03/29/05 colin + + * Added trimesh preprocessing to mark unneeded edges and verts. Also + added support for preprocessed info to the ccylinder-trimesh + collider. + +12/07/04 adam + + * Important AMotors bugfix + +09/22/04 jeff + + * Assorted small bugfixes and tweaks for + trimesh_{box,ccylinder,trimesh} collisions + +09/21/04 jeff + + * added functions to joint.cpp to allow joint attachment to moving + geoms. + + * added malloc-based memory allocation in step.cpp & lcp.cpp (turned + on with a #define switch in common.h) + +05/29/04 russ + + * added joint feedback to the QuickStep solver + +05/18/04 russ + + * added warm starting to the QuickStep solver + +05/18/04 russ + + * added the QuickStep solver + + * added contact parameter functions. + +05/05/04 adam + + * use dRandInt instead of rand() in stepfast. + +04/21/04 russ + + * added auto-disable support from Aras Pranckevicius (with + modifications by russ). this useful feature can speed up + simulation significantly in some cases. + + * various internal tidyups. + +04/20/04 russ + + * changed the meaning of the 'index' argument to dJointGetBody(): + it was the only remaining API function that does not respect + dJOINT_REVERSE (spotted by Matthew D. Hancher). + + * updated the C++ headers: fixed two minor bugs and added + support for dQuadTreeSpace, dRay, and the dGeom::getSpace() method + (from Matthew D. Hancher). + +04/18/04 russ + + * changed the way that the dInfinity constant is implemented: now it + is #defined to be one of: FLT_MAX, DBL_MAX, HUGE_VAL, HUGE_VALF, or + a large numeric constant. previously it was a variable that was + exported from the library. this simplifies the configuration and + build process quite a bit, especially in the case of DLLs. + + * removed the old, deprecated collision system (geom.cpp,space.cpp, + geom.h,space.h,odecpp_old_collision.h). the ODE_OLD_COLLISION + configuration setting no longer has any meaning. + + * removed support for dGeomGroups, which have been deprecated for + a while and are equivalent to 'spaces' anyway. + +04/13/04 russ + + * bug fix in dMassSetCappedCylinder(), from Matthew D. Hancher. + +04/08/04 russ + + * added trimesh-CCylinder capability, from Vadim Macagon + . + +04/04/04 adam + + * yet another rewrite of triangle-box collision code, this + time based on code donated by Croteam, ported by asko@jetti.org + and tweaked by Erwin. + +04/04/04 adam + + * merged trimesh-trimesh collision code by + Jeffrey Smith . + + * changed it to not break the trimesh interface, fix + some GCC compilation problems, bring it up to date with + ODE changes from 2003-11-15 -> 2004-04-04. + + * add ability to drop meshes on meshes in test_moving_trimesh, + not as good as it could be but it's illustrative. + +01/16/04 adam + + * implement a bunch of ultra-simple TriMesh functions that were + in the headers but not in the code -- patch by + Vadim Macagon + + * disable temporal coherence on trimeshes by default, since + it has scaleability issues that don't make it a general clear win. + +12/01/03 adam + + * implement dxHashSpace::collide2(), not particularly efficiently. + +11/14/03 adam + + * applied several Trimesh fixes and improvements from + Aras Pranckevicius + +10/22/03 adam + + * apply Nguyen Binh's work for removing many dSetZero() calls + and some other extraneous initializations. + +07/29/03 martin + + * added dJointAdd*Torque/Force(). + +07/10/03 russ + + * added the StepFast code, by David Whittaker. + +07/02/03 martin + + * added dMassSet*Total(). + +07/01/03 martin + + * added joint limits and motors to universal joints. + + * reversed the polarity of the dJOINT_REVERSE flag. + +06/30/03 russ + + * added the TriMesh geom class and the quad tree space to the ODE + core. both of these were developed by Erwin de Vries. added OPCODE + to the ODE distribution, this is required by TriMesh. + +06/23/03 martin + + * added dGeomSetQuaternion() and dGeomGetQuaternion() + + * added dJointGet*Anchor2() + +05/07/03 russ + + * added dGeomGetSpace(). + +02/05/03 russ + + * added dMassSetCylinder(). + +12/07/02 russ + + * added dAreConnectedExcluding(). + +11/30/02 russ + + * added the ray geom class. + + * added the dGeomXXXPointDepth() functions. + + * added a collision test infrastructure, and some more tests. + +11/24/02 russ + + * added support for multiple box-box contacts. + +11/10/02 russ + + * added new collision system. select between the old/new system by + setting the ODE_OLD_COLLISION variable in config/user-settings. + +10/28/02 russ + + * fixed two problems in the LCP code to improve the reliability of + the dContactApprox1 contact mode. + + * added a FAQ question about rolling bodies getting stuck when they + hit multiple geoms. + +09/08/02 russ + + * added dClosestLineSegmentPoints(). + * implemented dCollideCB(). + +08/28/02 russ + + * added dJointSetFeedback() and dJointGetFeedback(). + +08/05/02 russ + + * added dGeomTransformSetInfo() and dGeomTransformGetInfo(). + +07/13/02 russ + + * added dBodySetForce(), dBodySetTorque(), dWorldImpulseToForce(), + dBodyGetPosRelPoint(), dBodyGetPosRelPoint(), dBodyVectorToWorld(), + dBodyVectorFromWorld(). + + * added dBodyGetPointVel() (thanks to Colin Reed). + + * added a new C++ interface (from Martin C. Martin, with modifications + by russ). the old C++ interface is now in odecpp_old.h. + +06/25/02 russ + + * added an additional BSD-style licensing option for ODE. + +06/23/02 russ + + * added dCloseODE(), contributed by Nate Waddoups and David McClurg. + +05/16/02 russ + + * added dSpaceQuery(), contributed by Nate Waddoups. + +04/07/02 russ + + * added a section to the documentation for universal joints. + this includes a picture of the joint. + +04/05/02 russ + + * added a universal joint class (generously contributed by + Martin C. Martin). it doesn't (yet) have a motor or joint limits, + but it does come with tests. + +03/11/02 russ + + * makefile changes to accomodate OSs with command line length + limitations (thanks to Norman Lin). + +01/06/02 russ + + * added the dBodySetGravityMode() and dBodyGetGravityMode() + functions, which change the dxBodyNoGravity body flag. + + * added support for building a DLL with MSVC - there is now a + msvc-dll target. thanks to Norman Lin for doing this. + +12/28/01 russ + + * added the dParamCFM joint parameter. + +12/24/01 russ + + * reworked the build system to make it more cross-platform. + there is now a single top-level makefile and a configurator.c + program. see the INSTALL file for details. + +12/04/01 russ + + * the "angular motor" joint has been completed, and a new section + has been added to the documentation. + +11/26/01 russ + + * added a new joint type: "angular motor". using this joint is a good + way to get ball-joint motors and limits. this is work in progress - + it has not been fully implemented or tested yet. + +11/22/01 russ + + * replaced the mmap()-based joint group stack (stack.cpp) with a + malloc()-based arena stack (obstack.cpp). this will be more + portable and should not impact performance. + +11/12/01 russ + + * changed the meaning of the 'flags' parameter to dCollide() and + related functions: now the size of the contact buffer is kept in + the lower 16 bits. this change will be backward compatible. + + * added dBodyGetFiniteRotationMode() and dBodyGetFiniteRotationAxis(). + + * added dBodyAddForceAtRelPos() function. + +11/11/01 russ + + * added the ability to manually enable and disable bodies. + see dBodyEnable(), dBodyDisable(), dBodyIsEnabled(). + + * fixed a potential bug: when a world is destroyed that contains + joints in joint groups, those joints are marked as "deactivated" in + the joint group, so when the joint group is destroyed they can be + ignored. + + * the test_boxstack demo has new options to enable and disable bodies. + + * new configuration parameter in config.h: dEFFICIENT_SIZE. + +11/11/01 russ + + * started the change log for ODE. changes older than today were added + to this file by inspecting the CVS logs. + +11/05/01 russ + + * added REAL() constructions for floating point numbers, to prevent + many warnings when compiling under VC++. + +11/03/01 russ + + * added geometry transform class, documented composite objects. + + * added collision rule: no contacts if both geoms on the same body. + this is not the best rule, may have to remove this in the future. + + * new dMassAdd() function. + + * capped cylinder to capped cylinder collision function. + +10/31/01 russ + + * increase CFM in some demos to make them more robust. + +10/29/01 russ + + * added new accessor functions. + +10/19/01 russ + + * added the dJOINT_TWOBODIES flag to the joint, that says it can not + be attached to just one body. + +10/12/01 russ + + * fixed a collision bug in dCollide() that was causing memory + corruption when multiple contacts were being returned. + +10/11/01 russ + + * joints can now return m=0 to be "inactive". added a "null" joint + to test this. + +10/09/01 russ + + * in the LCP solver, try to fail gracefully when s <= 0. + + * dAABBTestFn() API change. + +10/08/01 russ + + * fixed a contact swapping bug in dCollide(). + +10/07/01 russ + + * added capped cylinder geometry object. + +09/30/01 russ + + * the test_buggy demo now uses geometry groups. + + * added a dAABBTestFn field in the geometry classes. + +09/29/01 russ + + * added geometry groups. + +09/20/01 russ + + * added finite rotation stuff. diff --git a/libs/ode-0.16.1/CMakeLists.txt b/libs/ode-0.16.1/CMakeLists.txt new file mode 100644 index 0000000..feb6a2a --- /dev/null +++ b/libs/ode-0.16.1/CMakeLists.txt @@ -0,0 +1,954 @@ +cmake_minimum_required(VERSION 2.8.11) + +project(ODE) + +include(CheckFunctionExists) +include(CheckIncludeFiles) +include(CMakeDependentOption) +include(GNUInstallDirs) + +set(VERSION_MAJOR 0) +set(VERSION_MINOR 16) +set(VERSION_PATCH 1) +set(VERSION ${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}) + +option(BUILD_SHARED_LIBS "Build shared libraries." OFF) +option(ODE_16BIT_INDICES "Use 16-bit indices for trimeshes (default is 32-bit)." OFF) +option(ODE_NO_BUILTIN_THREADING_IMPL "Disable built-in multithreaded threading implementation." OFF) +option(ODE_NO_THREADING_INTF "Disable threading interface support (external implementations cannot be assigned." OFF) +option(ODE_OLD_TRIMESH "Use old OPCODE trimesh-trimesh collider." OFF) +option(ODE_WITH_DEMOS "Builds the demo applications and DrawStuff library." OFF) +option(ODE_WITH_GIMPACT "Use GIMPACT for trimesh collisions (experimental)." OFF) +option(ODE_WITH_LIBCCD "Use libccd for handling some collision tests absent in ODE." OFF) +option(ODE_WITH_OPCODE "Use old OPCODE trimesh-trimesh collider." ON) +option(ODE_WITH_OU "Use TLS for global caches (allows threaded collision checks for separated spaces)." OFF) +option(ODE_WITH_TESTS "Builds the unit test application." OFF) + +cmake_dependent_option(ODE_WITH_LIBCCD_BOX_CYL "Use libccd for box-cylinder." ON "ODE_WITH_LIBCCD" OFF) +cmake_dependent_option(ODE_WITH_LIBCCD_CAP_CYL "Use libccd for capsule-cylinder." ON "ODE_WITH_LIBCCD" OFF) +cmake_dependent_option(ODE_WITH_LIBCCD_CYL_CYL "Use libccd for cylinder-cylinder." ON "ODE_WITH_LIBCCD" OFF) +cmake_dependent_option(ODE_WITH_LIBCCD_CONVEX_BOX "Use libccd for convex-box." ON "ODE_WITH_LIBCCD" OFF) +cmake_dependent_option(ODE_WITH_LIBCCD_CONVEX_CAP "Use libccd for convex-capsule." ON "ODE_WITH_LIBCCD" OFF) +cmake_dependent_option(ODE_WITH_LIBCCD_CONVEX_CONVEX "Use libccd for convex-convex." ON "ODE_WITH_LIBCCD" OFF) +cmake_dependent_option(ODE_WITH_LIBCCD_CONVEX_CYL "Use libccd for convex-cylinder." ON "ODE_WITH_LIBCCD" OFF) +cmake_dependent_option(ODE_WITH_LIBCCD_CONVEX_SPHERE "Use libccd for convex-sphere." ON "ODE_WITH_LIBCCD" OFF) +cmake_dependent_option(ODE_WITH_LIBCCD_SYSTEM "Use system libccd." OFF "ODE_WITH_LIBCCD" OFF) + +if(CMAKE_SIZEOF_VOID_P EQUAL 4) + option(ODE_DOUBLE_PRECISION "Use double-precision math." OFF) +else() + option(ODE_DOUBLE_PRECISION "Use double-precision math." ON) +endif() + +find_package(OpenGL) +find_package(Threads) + +set(CMAKE_REQUIRED_INCLUDES ${OPENGL_INCLUDE_DIR}) +set(CMAKE_REQUIRED_LIBRARIES ${CMAKE_THREAD_LIBS_INIT} ${OPENGL_LIBRARIES}) + +if(APPLE AND OPENGL_FOUND) + set(HAVE_APPLE_OPENGL_FRAMEWORK ON) +endif() +check_include_files(alloca.h HAVE_ALLOCA_H) +check_function_exists(gettimeofday HAVE_GETTIMEOFDAY) +check_include_files(inttypes.h HAVE_INTTYPES_H) +check_function_exists(isnan HAVE_ISNAN) +check_function_exists(isnanf HAVE_ISNANF) +check_include_files(malloc.h HAVE_MALLOC_H) +check_function_exists(pthread_attr_setstacklazy HAVE_PTHREAD_ATTR_SETSTACKLAZY) +check_function_exists(pthread_condattr_setclock HAVE_PTHREAD_CONDATTR_SETCLOCK) +check_include_files(stdint.h HAVE_STDINT_H) +check_include_files(sys/time.h HAVE_SYS_TIME_H) +check_include_files(sys/types.h HAVE_SYS_TYPES_H) +check_include_files(unistd.h HAVE_UNISTD_H) +check_function_exists(_isnan HAVE__ISNAN) +check_function_exists(_isnanf HAVE__ISNANF) +check_function_exists(__isnan HAVE___ISNAN) +check_function_exists(__isnanf HAVE___ISNANF) +if(APPLE) + set(MAC_OS_X_VERSION 1000) + check_function_exists(OSAtomicAdd32Barrier MAC_OS_X_VERSION_1040) + if(MAC_OS_X_VERSION_1040) + set(MAC_OS_X_VERSION 1040) + endif() + check_function_exists(OSAtomicAnd32OrigBarrier MAC_OS_X_VERSION_1050) + if(MAC_OS_X_VERSION_1050) + set(MAC_OS_X_VERSION 1050) + endif() +endif() +if(CMAKE_SYSTEM_PROCESSOR MATCHES "i686.*|x86.*|x86_64.*|amd64.*|AMD64.*") + set(PENTIUM ON) +endif() +if(CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64.*|amd64.*|AMD64.*") + set(X86_64_SYSTEM ON) +endif() +if(ODE_WITH_OU) + set(_OU_FEATURE_SET _OU_FEATURE_SET_TLS) +elseif(NOT ODE_NO_THREADING_INTF) + set(_OU_FEATURE_SET _OU_FEATURE_SET_ATOMICS) +else() + set(_OU_FEATURE_SET _OU_FEATURE_SET_BASICS) +endif() +set(_OU_NAMESPACE odeou) +if(WIN32 OR CYGWIN) + set(_OU_TARGET_OS _OU_TARGET_OS_WINDOWS) +elseif(APPLE) + set(_OU_TARGET_OS _OU_TARGET_OS_MAC) +elseif(QNXNTO) + set(_OU_TARGET_OS _OU_TARGET_OS_QNX) +elseif(CMAKE_SYSTEM MATCHES "SunOS-4") + set(_OU_TARGET_OS _OU_TARGET_OS_SUNOS) +else() + set(_OU_TARGET_OS _OU_TARGET_OS_GENUNIX) +endif() + +configure_file(config.h.cmake.in ode/src/config.h) + +if(ODE_DOUBLE_PRECISION) + set(CCD_PRECISION CCD_DOUBLE) + set(ODE_PRECISION dDOUBLE) +else() + set(CCD_PRECISION CCD_SINGLE) + set(ODE_PRECISION dSINGLE) +endif() + +configure_file(libccd/src/ccd/precision.h.in include/ccd/precision.h) +configure_file(include/ode/precision.h.in include/ode/precision.h) + +set(ODE_VERSION ${VERSION}) + +configure_file(include/ode/version.h.in include/ode/version.h) + +set( + HDRS + include/ode/collision.h + include/ode/collision_space.h + include/ode/collision_trimesh.h + include/ode/common.h + include/ode/compatibility.h + include/ode/contact.h + include/ode/cooperative.h + include/ode/error.h + include/ode/export-dif.h + include/ode/mass.h + include/ode/matrix.h + include/ode/matrix_coop.h + include/ode/memory.h + include/ode/misc.h + include/ode/objects.h + include/ode/ode.h + include/ode/odeconfig.h + include/ode/odecpp.h + include/ode/odecpp_collision.h + include/ode/odeinit.h + include/ode/odemath.h + include/ode/odemath_legacy.h + include/ode/rotation.h + include/ode/threading.h + include/ode/threading_impl.h + include/ode/timer.h + ${CMAKE_CURRENT_BINARY_DIR}/include/ode/precision.h + ${CMAKE_CURRENT_BINARY_DIR}/include/ode/version.h +) + +set( + SRCS + ode/src/array.cpp + ode/src/array.h + ode/src/box.cpp + ode/src/capsule.cpp + ode/src/collision_cylinder_box.cpp + ode/src/collision_cylinder_plane.cpp + ode/src/collision_cylinder_sphere.cpp + ode/src/collision_kernel.cpp + ode/src/collision_kernel.h + ode/src/collision_quadtreespace.cpp + ode/src/collision_sapspace.cpp + ode/src/collision_space.cpp + ode/src/collision_space_internal.h + ode/src/collision_std.h + ode/src/collision_transform.cpp + ode/src/collision_transform.h + ode/src/collision_trimesh_colliders.h + ode/src/collision_trimesh_disabled.cpp + ode/src/collision_trimesh_gimpact.h + ode/src/collision_trimesh_internal.h + ode/src/collision_trimesh_opcode.h + ode/src/collision_util.cpp + ode/src/collision_util.h + ode/src/common.h + ode/src/convex.cpp + ode/src/coop_matrix_types.h + ode/src/cylinder.cpp + ode/src/default_threading.cpp + ode/src/default_threading.h + ode/src/error.cpp + ode/src/error.h + ode/src/export-dif.cpp + ode/src/fastdot.cpp + ode/src/fastdot_impl.h + ode/src/fastldltfactor.cpp + ode/src/fastldltfactor_impl.h + ode/src/fastldltsolve.cpp + ode/src/fastldltsolve_impl.h + ode/src/fastlsolve.cpp + ode/src/fastlsolve_impl.h + ode/src/fastltsolve.cpp + ode/src/fastltsolve_impl.h + ode/src/fastvecscale.cpp + ode/src/fastvecscale_impl.h + ode/src/heightfield.cpp + ode/src/heightfield.h + ode/src/lcp.cpp + ode/src/lcp.h + ode/src/mass.cpp + ode/src/mat.cpp + ode/src/mat.h + ode/src/matrix.cpp + ode/src/matrix.h + ode/src/memory.cpp + ode/src/misc.cpp + ode/src/nextafterf.c + ode/src/objects.cpp + ode/src/objects.h + ode/src/obstack.cpp + ode/src/obstack.h + ode/src/ode.cpp + ode/src/odeinit.cpp + ode/src/odemath.cpp + ode/src/odemath.h + ode/src/odeou.h + ode/src/odetls.h + ode/src/plane.cpp + ode/src/quickstep.cpp + ode/src/quickstep.h + ode/src/ray.cpp + ode/src/resource_control.cpp + ode/src/resource_control.h + ode/src/rotation.cpp + ode/src/simple_cooperative.cpp + ode/src/simple_cooperative.h + ode/src/sphere.cpp + ode/src/step.cpp + ode/src/step.h + ode/src/threaded_solver_ldlt.h + ode/src/threading_atomics_provs.h + ode/src/threading_base.cpp + ode/src/threading_base.h + ode/src/threading_fake_sync.h + ode/src/threading_impl.cpp + ode/src/threading_impl.h + ode/src/threading_impl_posix.h + ode/src/threading_impl_templates.h + ode/src/threading_impl_win.h + ode/src/threading_pool_posix.cpp + ode/src/threading_pool_win.cpp + ode/src/threadingutils.h + ode/src/timer.cpp + ode/src/typedefs.h + ode/src/util.cpp + ode/src/util.h + ode/src/joints/amotor.cpp + ode/src/joints/amotor.h + ode/src/joints/ball.cpp + ode/src/joints/ball.h + ode/src/joints/contact.cpp + ode/src/joints/contact.h + ode/src/joints/dball.cpp + ode/src/joints/dball.h + ode/src/joints/dhinge.cpp + ode/src/joints/dhinge.h + ode/src/joints/fixed.cpp + ode/src/joints/fixed.h + ode/src/joints/hinge.cpp + ode/src/joints/hinge.h + ode/src/joints/hinge2.cpp + ode/src/joints/hinge2.h + ode/src/joints/joint.cpp + ode/src/joints/joint.h + ode/src/joints/joint_internal.h + ode/src/joints/joints.h + ode/src/joints/lmotor.cpp + ode/src/joints/lmotor.h + ode/src/joints/null.cpp + ode/src/joints/null.h + ode/src/joints/piston.cpp + ode/src/joints/piston.h + ode/src/joints/plane2d.cpp + ode/src/joints/plane2d.h + ode/src/joints/pr.cpp + ode/src/joints/pr.h + ode/src/joints/pu.cpp + ode/src/joints/pu.h + ode/src/joints/slider.cpp + ode/src/joints/slider.h + ode/src/joints/transmission.cpp + ode/src/joints/transmission.h + ode/src/joints/universal.cpp + ode/src/joints/universal.h +) + +if(ODE_WITH_GIMPACT AND NOT ODE_NO_TRIMESH) + list( + APPEND SRCS + GIMPACT/src/gim_boxpruning.cpp + GIMPACT/src/gim_contact.cpp + GIMPACT/src/gim_math.cpp + GIMPACT/src/gim_memory.cpp + GIMPACT/src/gim_tri_tri_overlap.cpp + GIMPACT/src/gim_trimesh.cpp + GIMPACT/src/gim_trimesh_capsule_collision.cpp + GIMPACT/src/gim_trimesh_ray_collision.cpp + GIMPACT/src/gim_trimesh_sphere_collision.cpp + GIMPACT/src/gim_trimesh_trimesh_collision.cpp + GIMPACT/src/gimpact.cpp + ode/src/collision_convex_trimesh.cpp + ode/src/collision_cylinder_trimesh.cpp + ode/src/collision_trimesh_box.cpp + ode/src/collision_trimesh_ccylinder.cpp + ode/src/collision_trimesh_gimpact.cpp + ode/src/collision_trimesh_internal.cpp + ode/src/collision_trimesh_internal_impl.h + ode/src/collision_trimesh_internal.h + ode/src/collision_trimesh_plane.cpp + ode/src/collision_trimesh_ray.cpp + ode/src/collision_trimesh_sphere.cpp + ode/src/collision_trimesh_trimesh.cpp + ode/src/gimpact_contact_export_helper.cpp + ode/src/gimpact_contact_export_helper.h + ode/src/gimpact_gim_contact_accessor.h + ode/src/gimpact_plane_contact_accessor.h + ) +endif() + +if(ODE_WITH_LIBCCD) + if(NOT ODE_WITH_LIBCCD_SYSTEM) + list( + APPEND SRCS + libccd/src/alloc.c + libccd/src/ccd.c + libccd/src/mpr.c + libccd/src/polytope.c + libccd/src/support.c + libccd/src/vec3.c + libccd/src/ccd/alloc.h + libccd/src/ccd/ccd.h + libccd/src/ccd/compiler.h + libccd/src/ccd/dbg.h + libccd/src/ccd/list.h + libccd/src/ccd/quat.h + libccd/src/ccd/polytope.h + libccd/src/ccd/simplex.h + libccd/src/ccd/support.h + libccd/src/ccd/vec3.h + libccd/src/custom/ccdcustom/quat.h + libccd/src/custom/ccdcustom/vec3.h + ) + endif() + + list( + APPEND SRCS + ode/src/collision_libccd.cpp + ode/src/collision_libccd.h + ) +endif() + +if(ODE_WITH_OPCODE AND NOT ODE_NO_TRIMESH) + list( + APPEND SRCS + ode/src/collision_convex_trimesh.cpp + ode/src/collision_cylinder_trimesh.cpp + ode/src/collision_trimesh_box.cpp + ode/src/collision_trimesh_ccylinder.cpp + ode/src/collision_trimesh_internal.cpp + ode/src/collision_trimesh_internal_impl.h + ode/src/collision_trimesh_internal.h + ode/src/collision_trimesh_opcode.cpp + ode/src/collision_trimesh_plane.cpp + ode/src/collision_trimesh_ray.cpp + ode/src/collision_trimesh_sphere.cpp + ode/src/collision_trimesh_trimesh.cpp + ode/src/collision_trimesh_trimesh_old.cpp + OPCODE/OPC_AABBCollider.cpp + OPCODE/OPC_AABBCollider.h + OPCODE/OPC_AABBTree.cpp + OPCODE/OPC_AABBTree.h + OPCODE/OPC_BaseModel.cpp + OPCODE/OPC_BaseModel.h + OPCODE/OPC_BoxBoxOverlap.h + OPCODE/OPC_Collider.cpp + OPCODE/OPC_Collider.h + OPCODE/OPC_Common.cpp + OPCODE/OPC_Common.h + OPCODE/OPC_HybridModel.cpp + OPCODE/OPC_HybridModel.h + OPCODE/OPC_IceHook.h + OPCODE/OPC_LSSAABBOverlap.h + OPCODE/OPC_LSSCollider.cpp + OPCODE/OPC_LSSCollider.h + OPCODE/OPC_LSSTriOverlap.h + OPCODE/OPC_MeshInterface.cpp + OPCODE/OPC_MeshInterface.h + OPCODE/OPC_Model.cpp + OPCODE/OPC_Model.h + OPCODE/OPC_OBBCollider.cpp + OPCODE/OPC_OBBCollider.h + OPCODE/OPC_OptimizedTree.cpp + OPCODE/OPC_OptimizedTree.h + OPCODE/OPC_Picking.cpp + OPCODE/OPC_Picking.h + OPCODE/OPC_PlanesAABBOverlap.h + OPCODE/OPC_PlanesCollider.cpp + OPCODE/OPC_PlanesCollider.h + OPCODE/OPC_PlanesTriOverlap.h + OPCODE/OPC_RayAABBOverlap.h + OPCODE/OPC_RayCollider.cpp + OPCODE/OPC_RayCollider.h + OPCODE/OPC_RayTriOverlap.h + OPCODE/OPC_Settings.h + OPCODE/OPC_SphereAABBOverlap.h + OPCODE/OPC_SphereCollider.cpp + OPCODE/OPC_SphereCollider.h + OPCODE/OPC_SphereTriOverlap.h + OPCODE/OPC_TreeBuilders.cpp + OPCODE/OPC_TreeBuilders.h + OPCODE/OPC_TreeCollider.cpp + OPCODE/OPC_TreeCollider.h + OPCODE/OPC_TriBoxOverlap.h + OPCODE/OPC_TriTriOverlap.h + OPCODE/OPC_VolumeCollider.cpp + OPCODE/OPC_VolumeCollider.h + OPCODE/Opcode.cpp + OPCODE/Opcode.h + OPCODE/Stdafx.h + OPCODE/Ice/IceAABB.cpp + OPCODE/Ice/IceAABB.h + OPCODE/Ice/IceAxes.h + OPCODE/Ice/IceBoundingSphere.h + OPCODE/Ice/IceContainer.cpp + OPCODE/Ice/IceContainer.h + OPCODE/Ice/IceFPU.h + OPCODE/Ice/IceHPoint.cpp + OPCODE/Ice/IceHPoint.h + OPCODE/Ice/IceIndexedTriangle.cpp + OPCODE/Ice/IceIndexedTriangle.h + OPCODE/Ice/IceLSS.h + OPCODE/Ice/IceMatrix3x3.cpp + OPCODE/Ice/IceMatrix3x3.h + OPCODE/Ice/IceMatrix4x4.cpp + OPCODE/Ice/IceMatrix4x4.h + OPCODE/Ice/IceMemoryMacros.h + OPCODE/Ice/IceOBB.cpp + OPCODE/Ice/IceOBB.h + OPCODE/Ice/IcePairs.h + OPCODE/Ice/IcePlane.cpp + OPCODE/Ice/IcePlane.h + OPCODE/Ice/IcePoint.cpp + OPCODE/Ice/IcePoint.h + OPCODE/Ice/IcePreprocessor.h + OPCODE/Ice/IceRandom.cpp + OPCODE/Ice/IceRandom.h + OPCODE/Ice/IceRay.cpp + OPCODE/Ice/IceRay.h + OPCODE/Ice/IceRevisitedRadix.cpp + OPCODE/Ice/IceRevisitedRadix.h + OPCODE/Ice/IceSegment.cpp + OPCODE/Ice/IceSegment.h + OPCODE/Ice/IceTriangle.cpp + OPCODE/Ice/IceTriangle.h + OPCODE/Ice/IceTriList.h + OPCODE/Ice/IceTypes.h + OPCODE/Ice/IceUtils.cpp + OPCODE/Ice/IceUtils.h + ) +endif() + +list( + APPEND SRCS + ode/src/odeou.cpp + ode/src/odeou.h + ode/src/odetls.cpp + ode/src/odetls.h + ou/src/ou/atomic.cpp + ou/src/ou/customization.cpp + ou/src/ou/malloc.cpp + ou/src/ou/threadlocalstorage.cpp +) + +add_library(ODE ${SRCS}) + +set_target_properties( + ODE + PROPERTIES + OUTPUT_NAME ode + POSITION_INDEPENDENT_CODE ON + VERSION ${VERSION} +) + +if(WIN32) + if(BUILD_SHARED_LIBS) + set_target_properties(ODE PROPERTIES DEBUG_POSTFIX d) + else() + set_target_properties( + ODE + PROPERTIES + DEBUG_POSTFIX sd + MINSIZEREL_POSTFIX s + RELEASE_POSTFIX s + RELWITHDEBINFO_POSTFIX s + ) + endif() + + if(ODE_DOUBLE_PRECISION) + set_target_properties(ODE PROPERTIES OUTPUT_NAME ode_double) + else() + set_target_properties(ODE PROPERTIES OUTPUT_NAME ode_single) + endif() +endif() + +target_compile_definitions( + ODE + PRIVATE + -D_OU_NAMESPACE=${_OU_NAMESPACE} + -D_OU_FEATURE_SET=${_OU_FEATURE_SET} + -D_OU_TARGET_OS=${_OU_TARGET_OS} + $<$>:dNODEBUG> + -DdOU_ENABLED +) + +if(APPLE) + target_compile_definitions(ODE PRIVATE -DMAC_OS_X_VERSION=${MAC_OS_X_VERSION}) +endif() + +if(WIN32) + target_compile_definitions(ODE PRIVATE -D_CRT_SECURE_NO_DEPRECATE -D_SCL_SECURE_NO_WARNINGS -D_USE_MATH_DEFINES) +endif() + +if(BUILD_SHARED_LIBS) + target_compile_definitions(ODE PRIVATE -DODE_DLL) +else() + target_compile_definitions(ODE PRIVATE -DODE_LIB) +endif() + +if(ODE_DOUBLE_PRECISION) + target_compile_definitions(ODE PUBLIC -DdIDEDOUBLE PRIVATE -DCCD_IDEDOUBLE) +else() + target_compile_definitions(ODE PUBLIC -DdIDESINGLE PRIVATE -DCCD_IDESINGLE) +endif() + +target_include_directories( + ODE + PUBLIC + $ + $ + $ + $ + $ + $ + $/${CMAKE_INSTALL_INCLUDEDIR}> +) + +if(ODE_16BIT_INDICES) + target_compile_definitions(ODE PRIVATE -DdTRIMESH_16BIT_INDICES) +endif() + +if(NOT ODE_NO_BUILTIN_THREADING_IMPL) + target_compile_definitions(ODE PRIVATE -DdBUILTIN_THREADING_IMPL_ENABLED) +endif() + +if(ODE_NO_THREADING_INTF) + target_compile_definitions(ODE PRIVATE -DdTHREADING_INTF_DISABLED) +endif() + +if(ODE_WITH_GIMPACT AND NOT ODE_NO_TRIMESH) + target_compile_definitions(ODE PRIVATE -DdTRIMESH_ENABLED -DdTRIMESH_GIMPACT) + target_include_directories(ODE PRIVATE $) +endif() + +if(ODE_WITH_LIBCCD) + if(ODE_WITH_LIBCCD_SYSTEM) + find_package(ccd) + target_compile_definitions(ode PRIVATE -DdLIBCCD_ENABLED -DdLIBCCD_SYSTEM) + target_link_libraries(ODE ccd::ccd) + else() + target_compile_definitions(ODE PRIVATE -DdLIBCCD_ENABLED -DdLIBCCD_INTERNAL) + target_include_directories( + ODE + PRIVATE + $ + $ + ) + endif() + + if(ODE_WITH_LIBCCD_BOX_CYL) + target_compile_definitions(ODE PRIVATE -DdLIBCCD_BOX_CYL) + endif() + + if(ODE_WITH_LIBCCD_CAP_CYL) + target_compile_definitions(ODE PRIVATE -DdLIBCCD_CAP_CYL) + endif() + + if(ODE_WITH_LIBCCD_CYL_CYL) + target_compile_definitions(ODE PRIVATE -DdLIBCCD_CYL_CYL) + endif() + + if(ODE_WITH_LIBCCD_CONVEX_BOX) + target_compile_definitions(ODE PRIVATE -DdLIBCCD_CONVEX_BOX) + endif() + + if(ODE_WITH_LIBCCD_CONVEX_CAP) + target_compile_definitions(ODE PRIVATE -DdLIBCCD_CONVEX_CAP) + endif() + + if(ODE_WITH_LIBCCD_CONVEX_CONVEX) + target_compile_definitions(ODE PRIVATE -DdLIBCCD_CONVEX_CONVEX) + endif() + + if(ODE_WITH_LIBCCD_CONVEX_CYL) + target_compile_definitions(ODE PRIVATE -DdLIBCCD_CONVEX_CYL) + endif() + + if(ODE_WITH_LIBCCD_CONVEX_SPHERE) + target_compile_definitions(ODE PRIVATE -DdLIBCCD_CONVEX_SPHERE) + endif() +endif() + +if(ODE_WITH_OPCODE AND NOT ODE_NO_TRIMESH) + target_compile_definitions(ODE PRIVATE -DdTRIMESH_ENABLED -DdTRIMESH_OPCODE) + + if(ODE_OLD_TRIMESH) + target_compile_definitions(ODE PRIVATE -DdTRIMESH_OPCODE_USE_OLD_TRIMESH_TRIMESH_COLLIDER) + endif() + + target_include_directories( + ODE + PRIVATE + $ + $ + ) +endif() + +if(ODE_WITH_OU) + target_compile_definitions(ODE PRIVATE -DdATOMICS_ENABLED -DdTLS_ENABLED) +elseif(NOT ODE_NO_THREADING_INTF) + target_compile_definitions(ODE PRIVATE -DdATOMICS_ENABLED) +endif() + +if(ODE_WITH_OU OR NOT ODE_NO_THREADING_INTF) + target_link_libraries(ODE ${CMAKE_THREAD_LIBS_INIT}) +endif() + +install( + TARGETS ODE + EXPORT ODE + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} COMPONENT development + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} COMPONENT runtime NAMELINK_SKIP + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} COMPONENT runtime +) + +if(BUILD_SHARED_LIBS) + install( + TARGETS ODE + EXPORT ODE + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} COMPONENT development NAMELINK_ONLY + ) +endif() + +if(MSVC AND BUILD_SHARED_LIBS AND NOT CMAKE_VERSION VERSION_LESS 3.1) + install(FILES $ DESTINATION ${CMAKE_INSTALL_BINDIR} CONFIGURATIONS Debug RelWithDebInfo COMPONENT debug) +endif() + +install(FILES ${HDRS} DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/ode COMPONENT development) + +set(prefix ${CMAKE_INSTALL_PREFIX}) +set(exec_prefix "\${prefix}") +set(libdir "\${exec_prefix}/${CMAKE_INSTALL_LIBDIR}") +set(includedir "\${prefix}/${CMAKE_INSTALL_INCLUDEDIR}") +configure_file(ode.pc.in ode.pc @ONLY) +configure_file(ode-config.in ode-config @ONLY) + +install(FILES ${CMAKE_CURRENT_BINARY_DIR}/ode.pc DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig COMPONENT development) +install(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/ode-config DESTINATION ${CMAKE_INSTALL_BINDIR} COMPONENT development) + +if(ODE_WITH_DEMOS) + set( + DRAWSTUFF_SRCS + include/drawstuff/drawstuff.h + include/drawstuff/version.h + drawstuff/src/drawstuff.cpp + drawstuff/src/internal.h + ) + + if(WIN32) + list( + APPEND DRAWSTUFF_SRCS + drawstuff/src/resource.h + drawstuff/src/resources.rc + drawstuff/src/windows.cpp + ) + elseif(APPLE) + list(APPEND DRAWSTUFF_SRCS drawstuff/src/osx.cpp) + else() + list(APPEND DRAWSTUFF_SRCS drawstuff/src/x11.cpp) + endif() + + add_library(drawstuff ${DRAWSTUFF_SRCS}) + target_compile_definitions(drawstuff PUBLIC -DDRAWSTUFF_TEXTURE_PATH="${CMAKE_CURRENT_SOURCE_DIR}/drawstuff/textures") + + if(BUILD_SHARED_LIBS) + target_compile_definitions(drawstuff PRIVATE -DDS_DLL -DUSRDLL) + else() + target_compile_definitions(drawstuff PRIVATE -DDS_LIB) + endif() + + target_include_directories(drawstuff PUBLIC ${OPENGL_INCLUDE_DIR}) + target_link_libraries(drawstuff ODE ${OPENGL_LIBRARIES}) + + if(WIN32) + target_link_libraries(drawstuff winmm) + elseif(APPLE) + find_package(GLUT) + target_include_directories(drawstuff PUBLIC ${GLUT_INCLUDE_DIR}) + target_link_libraries(drawstuff ${GLUT_LIBRARIES}) + else() + find_package(X11) + target_include_directories(drawstuff PUBLIC ${X11_INCLUDE_DIR}) + target_link_libraries(drawstuff ${X11_LIBRARIES}) + endif() + + set( + DEMO_SRCS + ode/demo/demo_boxstack.cpp + ode/demo/demo_buggy.cpp + ode/demo/demo_cards.cpp + ode/demo/demo_chain1.c + ode/demo/demo_chain2.cpp + ode/demo/demo_collision.cpp + ode/demo/demo_convex.cpp + ode/demo/demo_crash.cpp + ode/demo/demo_cylvssphere.cpp + ode/demo/demo_dball.cpp + ode/demo/demo_dhinge.cpp + ode/demo/demo_feedback.cpp + ode/demo/demo_friction.cpp + ode/demo/demo_gyro2.cpp + ode/demo/demo_gyroscopic.cpp + ode/demo/demo_heightfield.cpp + ode/demo/demo_hinge.cpp + ode/demo/demo_I.cpp + ode/demo/demo_jointPR.cpp + ode/demo/demo_jointPU.cpp + ode/demo/demo_joints.cpp + ode/demo/demo_kinematic.cpp + ode/demo/demo_motion.cpp + ode/demo/demo_motor.cpp + ode/demo/demo_ode.cpp + ode/demo/demo_piston.cpp + ode/demo/demo_plane2d.cpp + ode/demo/demo_rfriction.cpp + ode/demo/demo_slider.cpp + ode/demo/demo_space.cpp + ode/demo/demo_space_stress.cpp + ode/demo/demo_step.cpp + ode/demo/demo_transmission.cpp + ) + + if(NOT ODE_NO_TRIMESH) + list( + APPEND DEMO_SRCS + ode/demo/demo_basket.cpp + ode/demo/demo_cyl.cpp + ode/demo/demo_moving_convex.cpp + ode/demo/demo_moving_trimesh.cpp + ode/demo/demo_tracks.cpp + ode/demo/demo_trimesh.cpp + ) + endif() + + foreach(DEMO_SRC ${DEMO_SRCS}) + get_filename_component(DEMO ${DEMO_SRC} NAME_WE) + add_executable(${DEMO} ${DEMO_SRC}) + target_link_libraries(${DEMO} drawstuff) + + if(NOT WIN32 AND ${DEMO} MATCHES "demo_chain1") + target_link_libraries(${DEMO} m) + endif() + endforeach() +endif() + +if(ODE_WITH_TESTS) + set( + TEST_SRCS + tests/collision.cpp + tests/friction.cpp + tests/joint.cpp + tests/main.cpp + tests/odemath.cpp + tests/joints/amotor.cpp + tests/joints/ball.cpp + tests/joints/dball.cpp + tests/joints/fixed.cpp + tests/joints/hinge.cpp + tests/joints/hinge2.cpp + tests/joints/piston.cpp + tests/joints/pr.cpp + tests/joints/pu.cpp + tests/joints/slider.cpp + tests/joints/universal.cpp + tests/UnitTest++/src/AssertException.cpp + tests/UnitTest++/src/AssertException.h + tests/UnitTest++/src/CheckMacros.h + tests/UnitTest++/src/Checks.cpp + tests/UnitTest++/src/Checks.h + tests/UnitTest++/src/Config.h + tests/UnitTest++/src/DeferredTestReporter.cpp + tests/UnitTest++/src/DeferredTestReporter.h + tests/UnitTest++/src/DeferredTestResult.cpp + tests/UnitTest++/src/DeferredTestResult.h + tests/UnitTest++/src/MemoryOutStream.cpp + tests/UnitTest++/src/MemoryOutStream.h + tests/UnitTest++/src/ReportAssert.cpp + tests/UnitTest++/src/ReportAssert.h + tests/UnitTest++/src/Test.cpp + tests/UnitTest++/src/TestDetails.cpp + tests/UnitTest++/src/TestDetails.h + tests/UnitTest++/src/Test.h + tests/UnitTest++/src/TestList.cpp + tests/UnitTest++/src/TestList.h + tests/UnitTest++/src/TestMacros.h + tests/UnitTest++/src/TestReporter.cpp + tests/UnitTest++/src/TestReporter.h + tests/UnitTest++/src/TestReporterStdout.cpp + tests/UnitTest++/src/TestReporterStdout.h + tests/UnitTest++/src/TestResults.cpp + tests/UnitTest++/src/TestResults.h + tests/UnitTest++/src/TestRunner.cpp + tests/UnitTest++/src/TestRunner.h + tests/UnitTest++/src/TestSuite.h + tests/UnitTest++/src/TimeConstraint.cpp + tests/UnitTest++/src/TimeConstraint.h + tests/UnitTest++/src/TimeHelpers.h + tests/UnitTest++/src/UnitTest++.h + tests/UnitTest++/src/XmlTestReporter.cpp + tests/UnitTest++/src/XmlTestReporter.h + ) + + if(WIN32) + list( + APPEND TEST_SRCS + tests/UnitTest++/src/Win32/TimeHelpers.cpp + tests/UnitTest++/src/Win32/TimeHelpers.h + ) + else() + list( + APPEND TEST_SRCS + tests/UnitTest++/src/Posix/SignalTranslator.cpp + tests/UnitTest++/src/Posix/SignalTranslator.h + tests/UnitTest++/src/Posix/TimeHelpers.cpp + tests/UnitTest++/src/Posix/TimeHelpers.h + ) + endif() + + add_executable(tests ${TEST_SRCS}) + target_include_directories(tests PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/tests/UnitTest++/src) + target_link_libraries(tests ODE) + + enable_testing() + add_test(tests ${CMAKE_CURRENT_BINARY_DIR}/tests) +endif() + +include(CMakePackageConfigHelpers) + +configure_package_config_file( + ${CMAKE_CURRENT_SOURCE_DIR}/ode-config.cmake.in ${CMAKE_CURRENT_BINARY_DIR}/ode-config.cmake + INSTALL_DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/ode +) +install( + FILES ${CMAKE_CURRENT_BINARY_DIR}/ode-config.cmake + DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/ode-${VERSION} + COMPONENT development +) +write_basic_package_version_file( + ${CMAKE_CURRENT_BINARY_DIR}/ode-config-version.cmake + VERSION ${VERSION} + COMPATIBILITY ExactVersion +) +install( + FILES ${CMAKE_CURRENT_BINARY_DIR}/ode-config-version.cmake + DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/ode-${VERSION} + COMPONENT development +) +install( + EXPORT ODE + DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/ode-${VERSION} + NAMESPACE ODE:: + FILE ode-export.cmake + COMPONENT development +) + +configure_file(cmake/cmake_uninstall.cmake.in cmake_uninstall.cmake @ONLY) +add_custom_target(uninstall ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake) + +set(CPACK_DEBIAN_PACKAGE_DESCRIPTION "ODE is a free, industrial quality library for simulating articulated rigid body dynamics - for example ground vehicles, legged creatures, and moving objects in VR environments. It is fast, flexible, robust and platform independent, with advanced joints, contact with friction, and built-in collision detection.") + +set(CPACK_COMPONENT_DEVELOPMENT_DEPENDS runtime) +set(CPACK_COMPONENT_DEVELOPMENT_DESCRIPTION "Open Dynamics Engine - development files\n${CPACK_DEBIAN_PACKAGE_DESCRIPTION}") +set(CPACK_COMPONENT_RUNTIME_DESCRIPTION "Open Dynamics Engine - runtime library\n${CPACK_DEBIAN_PACKAGE_DESCRIPTION}") +set(CPACK_DEB_COMPONENT_INSTALL ON) +set(CPACK_DEBIAN_DEVELOPMENT_FILE_NAME "DEB-DEFAULT") +set(CPACK_DEBIAN_DEVELOPMENT_PACKAGE_SECTION "libdevel") +set(CPACK_DEBIAN_PACKAGE_HOMEPAGE "http://www.ode.org/") +set(CPACK_DEBIAN_PACKAGE_NAME "libode") +set(CPACK_DEBIAN_PACKAGE_SECTION "devel") +set(CPACK_DEBIAN_RUNTIME_FILE_NAME "DEB-DEFAULT") +set(CPACK_DEBIAN_RUNTIME_PACKAGE_SECTION "libs") +set(CPACK_DEBIAN_RUNTIME_PACKAGE_SHLIBDEPS ON) +set(CPACK_NSIS_PACKAGE_NAME "ODE ${VERSION}") +set(CPACK_NSIS_URL_INFO_ABOUT "http://www.ode.org/") +set(CPACK_PACKAGE_CONTACT "ode@ode.org") +set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "High performance library for simulating rigid body dynamics") +set(CPACK_PACKAGE_DISPLAY_NAME "ODE ${VERSION}") +set(CPACK_PACKAGE_INSTALL_DIRECTORY "ode-${VERSION}") +set(CPACK_PACKAGE_NAME "ode") +set(CPACK_PACKAGE_VENDOR "") +set(CPACK_PACKAGE_VERSION ${VERSION}) +set(CPACK_PACKAGE_VERSION_MAJOR ${VERSION_MAJOR}) +set(CPACK_PACKAGE_VERSION_MINOR ${VERSION_MINOR}) +set(CPACK_PACKAGE_VERSION_PATCH ${VERSION_PATCH}) +set(CPACK_RESOURCE_FILE_LICENSE ${CMAKE_CURRENT_SOURCE_DIR}/COPYING) +set(CPACK_RPM_COMPONENT_INSTALL ON) +set(CPACK_RPM_DEVELOPMENT_FILE_NAME "RPM-DEFAULT") +set(CPACK_RPM_development_PACKAGE_DESCRIPTION "The ode-devel package contains libraries and header files for developing applications that use ode or ode-double.") +set(CPACK_RPM_development_PACKAGE_NAME "ode-devel") +set(CPACK_RPM_development_PACKAGE_SUMMARY "Development files for ODE") +set(CPACK_RPM_PACKAGE_DESCRIPTION "ODE is an open source, high performance library for simulating rigid body dynamics. It is fully featured, stable, mature and platform independent with an easy to use C/C++ API. It has advanced joint types and integrated collision detection with friction. ODE is useful for simulating vehicles, objects in virtual reality environments and virtual creatures. It is currently used in many computer games, 3D authoring tools and simulation tools.") +set(CPACK_RPM_PACKAGE_GROUP "Development/Libraries") +set(CPACK_RPM_PACKAGE_LICENSE "BSD or LGPLv2+") +set(CPACK_RPM_PACKAGE_NAME "ode") +set(CPACK_RPM_PACKAGE_SUMMARY "High performance library for simulating rigid body dynamics") +set(CPACK_RPM_PACKAGE_URL "http://www.ode.org/") +set(CPACK_RPM_RUNTIME_FILE_NAME "RPM-DEFAULT") + +if(ODE_DOUBLE_PRECISION) + set(CPACK_DEBIAN_DEVELOPMENT_PACKAGE_CONFLICTS "libode-sp-dev") + set(CPACK_DEBIAN_DEVELOPMENT_PACKAGE_DEPENDS "libode6") + set(CPACK_DEBIAN_DEVELOPMENT_PACKAGE_NAME "libode-dev") + set(CPACK_DEBIAN_RUNTIME_PACKAGE_CONFLICTS "libode6sp") + set(CPACK_DEBIAN_RUNTIME_PACKAGE_NAME "libode6") + set(CPACK_RPM_development_PACKAGE_REQUIRES "ode-double") + set(CPACK_RPM_runtime_PACKAGE_CONFLICTS "ode") + set(CPACK_RPM_runtime_PACKAGE_DESCRIPTION "The ode-double package contains a version of the ODE library for simulating rigid body dynamics compiled with double precision.") + set(CPACK_RPM_runtime_PACKAGE_NAME "ode-double") + set(CPACK_RPM_runtime_PACKAGE_SUMMARY "ODE physics library compiled with double precision") +else() + set(CPACK_DEBIAN_DEVELOPMENT_PACKAGE_CONFLICTS "libode-dev") + set(CPACK_DEBIAN_DEVELOPMENT_PACKAGE_DEPENDS "libode6sp") + set(CPACK_DEBIAN_DEVELOPMENT_PACKAGE_NAME "libode-sp-dev") + set(CPACK_DEBIAN_RUNTIME_PACKAGE_CONFLICTS "libode6") + set(CPACK_DEBIAN_RUNTIME_PACKAGE_NAME "libode6sp") + set(CPACK_RPM_development_PACKAGE_REQUIRES "ode") + set(CPACK_RPM_runtime_PACKAGE_CONFLICTS "ode-double") + set(CPACK_RPM_runtime_PACKAGE_NAME "ode") +endif() + +include(CPack) diff --git a/libs/ode-0.16.1/COPYING b/libs/ode-0.16.1/COPYING new file mode 100644 index 0000000..b21a778 --- /dev/null +++ b/libs/ode-0.16.1/COPYING @@ -0,0 +1,32 @@ +ODE is dual-licensed under either: + + * GNU Lesser General Public License v 2.1 or later. + see LICENSE.TXT + + * Modified 3-clause BSD license. + see LICENSE-BSD.TXT + + +Third-party libraries bundled with ODE: + + * GIMPACT: dual-licensed under either: + - GNU Lesser General Public License v 2.1 or later. + see GIMPACT-LICENSE-LGPL.TXT + - Modified 3-clause BSD license. + see GIMPACT/GIMPACT-LICENSE-BSD.TXT + + * libccd: Modified 3-clause BSD License + see libccd/BSD-LICENSE + + * OU/ODER: triple-licensed under either: + - GNU Lesser General Public License v 3 or later. + see ou/LICENSE.TXT + see ou/LICENSE-LESSER.TXT + - Modified 3-clause BSD license. + see ou/LICENSE-BSD.TXT + - ZLIB license. + see ou/LICENSE-ZLIB.TXT + + * OPCODE: under the same terms as ODE + see OPCODE/COPYING + diff --git a/libs/ode-0.16.1/CSR.txt b/libs/ode-0.16.1/CSR.txt new file mode 100644 index 0000000..7d4ca2e --- /dev/null +++ b/libs/ode-0.16.1/CSR.txt @@ -0,0 +1,422 @@ +CODING STYLE REQUIREMENTS + +Copyright (c) 2011-2017 Oleh Derevenko +This article is provided to you under the terms of Artistic License 2.0 +(http://www.opensource.org/licenses/artistic-license-2.0). + +(I) General Coding Requirements +============================================================================= + +1. Not more than one complex construction per function +---------------------------------------------------------------------------- + +A function must not contain more than one* operator from the following set: +for, while, do..while, switch and constructions try..catch, try..finally. +Moreover, those operators/constructions must not appear inside of a +conditional operator. + +* Loop inclusion is allowed if multi-dimensional array must be iterated and +all the elements are uniform and need to be processed linearly. +try..finally construction inclusion is allowed for several resource +allocations that need to be performed together. + + +2. Absence of jumps +---------------------------------------------------------------------------- + +goto and continue operators must not be used. + + +3. Single exit point at the end of function +---------------------------------------------------------------------------- + +A function must not have other exit points except for the end of its +definition. If a function returns a value, return operator must be the last +syntactical construction in the function. + + +4. Zero value means failure +---------------------------------------------------------------------------- + +Function results must be chosen the way that binary zero value had a meaning +of failure. Similarly, types must be designed so that binary zero element +had the meaning of an invalid value (if invalid element concept is applicable +for the type). + + +5. Variables and parameters are initialized with zeroes +---------------------------------------------------------------------------- + +Variables and class fields must be initialized with values of binary zero +presentation. Public enumerated types must be designed to have zero element +and that element is to be the default element. Function default parameters +must be chosen in the form to have binary zero value. + + +6. Variables are not reused +---------------------------------------------------------------------------- + +Variables must not be reused for other purposes after they have already been +used for something. The only value that might be stored in a variable is that +described with its name. + + +7. Parameters passed by value are treated as constants +---------------------------------------------------------------------------- + +Parameters that are passed by value must not be modified*. All of them must +be treated as if they have been implicitly declared with const modifier. + +* An exception could be the case when a value loses its meaning (e.g. a +pointer to an object being deleted). + + +8. Result assignment is performed at the end of function +---------------------------------------------------------------------------- + +Every function returning a result must have a variable to contain the result +of that function. It is to be declared (initialized if necessary) at the +beginning of the function* and the only access to it after that should be its +final value assignment. The assignment should be the last meaningful operator +in an execution branch**. Several assignments, one per each execution branch, +are allowed. + +* It is allowed to declare result variable with assignment immediately before +return operator. +** It is allowed to include technical constructions like logging or +performance measuring after result variable assignment. + + +9. Parameters by reference are not used in expressions +---------------------------------------------------------------------------- + +Parameters of simple types passed by reference must be copied into local +variables at function entry and then be assigned their final values at +function exit. +Output parameters can be initialized at function entry and must be assigned +their final values immediately before the function result variable assignment. + + +(II) Class Design Requirements +============================================================================= + +1. Classes work with their fields on their own +---------------------------------------------------------------------------- + +A function or method must not call several methods of other class, some of +them being used to return and the others being used to assign the class fields. +Such a code must be implemented as a method of that other class. + + +2. No direct access to the fields +---------------------------------------------------------------------------- + +All the work with class fields (including fields of own class) must be +performed with aid of dedicated methods (accessors) that return and assign +field values. Exceptions can be made for constructors/destructors and methods +dedicated for field initialization/finalization. + + +3. Private fields only +---------------------------------------------------------------------------- + +All class fields must be private. + + +4. No code in constructors and destructors +---------------------------------------------------------------------------- + +Class constructors must not have raw code other than doing trivial field +initialization. If creation of contained objects is necessary or other +operations need to be done they are to be performed via calls to the class +methods rather than placed directly in constructor. Initial zero-assignment +to a field is always required even if that field is later to be +unconditionally assigned in methods called from the constructor. +Similarly, a destructor must free contained objects with calls to the class +methods rather than containing that code inline. + + +5. No code in callbacks +---------------------------------------------------------------------------- + +Event handlers, callback interface methods and static callback methods must +not have meaningful code within them. Their implementation should validate +input arguments, convert them to proper internal types if necessary, and call +one or more other methods of the class. These methods must not be declated in +public section. + + +6. No public virtual methods +---------------------------------------------------------------------------- + +Methods declared as virtual must not be public. The public calls to such +methods must be wrapped with ordinary class methods. + + +7. No logical level violations +---------------------------------------------------------------------------- + +Methods of lower logical levels must not call any methods of higher logical +levels of the class. In particular, methods declared as protected and private +must not call methods declared in public sections of own or ancestor classes. +Methods declared as public may only call protected and private methods. +Similarly classes of lower logical levels must not call public methods of +classes at higher logical levels. Such calls are only possible via dedicated +callback methods or callback interfaces. + + +(III) Canonical Function Structures +============================================================================= + +0. Preamble +---------------------------------------------------------------------------- + +Following are general function structures encouraged to be used for coding +all the program logic. Any algorithm with branching can be implemented +with these types of functions. + +Using these function structures helps to make code clear and error-proof. + + +1. A Boolean Function +---------------------------------------------------------------------------- + +The Boolean Function can be used to implement algorithms with conditional +branching. + +bool PerformSomeAction(...) +{ + bool bResult = false; + + // Some linear code + + if (...) + { + // Some linear code + + if (...) // Optionally... + { + bResult = true; + } + } + // Optionally... + else if (...) + { + // Some linear code + + bResult = true; + } + + return bResult; +} + +The idea is to have result variable initialized with false at entry and then +have an arbitrary structure of conditional operators with some branches +changing result variable to true on exit. + + +2. A Validation Function +---------------------------------------------------------------------------- + +The Validation Function is an alternative to Boolean Function to implement +conditional logic. It's mostly convenient for implementing multi-step +algorithms that may fail (like validations or initializations of multiple +items of non-uniform nature). + +bool PerformSomeValidation(...) +{ + bool bResult = false; + + do + { + // Some linear code + + // Optionally... + if ( !(...) ) + { + // Some error handling // Optionally... + break; + } + + // Optionally... + if (...) + { + // Some linear code + + if ( !(...) ) + { + // Some error handling // Optionally... + break; + } + + // Some linear code + } + + bResult = true; + } + while (false); + + return bResult; +} + +If function execution has side effects which need to be rolled back in case +of failures on subsequent steps the function structure can be altered to the +following form. + +bool PerformSomeInitialization(...) +{ + bool bResult = false; + + bool bFirstSideEffectApplied = false, bSecondSideEffectApplied = false, ...; + + do + { + // Some linear code + + if ( !ExecuteFirstSideEffectApplication(...) ) + { + // Some error handling // Optionally... + break; + } + + bFirstSideEffectApplied = true + + // Some linear code + + if ( !ExecuteSecondSideEffectApplication(...) ) + { + // Some error handling // Optionally... + break; + } + + bSecondSideEffectApplied = true + + ... + + // Some linear code + + if ( !ExecuteLastSideEffectApplication(...) ) + { + // Some error handling // Optionally... + break; + } + + bResult = true; + } + while (false); + + if (!bResult) + { + if (bFirstSideEffectApplied) + { + if (bSecondSideEffectApplied) + { + if (...) + { + ... + } + + ExecuteSecondSideEffectRollback(...); + } + + ExecuteFirstSideEffectRollback(...); + } + } + + return bResult; +} + + +3. A Loop Validation Function +---------------------------------------------------------------------------- + +The Loop Validation Function can be used for processing sequences of items +while the processing of each or some individual items can fail. + +bool PerformLoopValidation(...) +{ + bool bAnyFailure = false; + + for (...) // Or any other loop control operator + { + // Some linear code + + if ( !(...) ) + { + // Some error handling // Optional + bAnyFailure = true; + break; + } + + // Some linear code + } + + bool bResult = !bAnyFailure; + return bResult; +} + +In case if a loop processing function may apply side effects on each step +which need to be reverted in case of a failure on subsequent steps the +functions need to be organized in the following four-function two-level +structure. + +bool PerformLoopInitialization(...) +{ + bool bResult = false; + + size_t nFailureItem; + + if (DoPerformLoopInitialization(..., nFailureItem)) + { + bResult = true; + } + else + { + DoPerformLoopFinalization(..., nFailureItem); + } + + return bResult; +} + +void PerformLoopFinalization(...) +{ + DoPerformLoopFinalization(..., npos); // Here "npos" stands for the invalid item index +} + +bool DoPerformLoopInitialization(..., size_t &nOutFailureItem) +{ + bool bAnyFailure = false; + size_t nOutFailureItem = npos; + + for (...) // Or any other loop control operator + { + // Some linear code + + if ( !(...) ) + { + // Some error handling // Optional + nOutFailureItem = ...; + bAnyFailure = true; + break; + } + + // Some linear code + } + + bool bResult = !bAnyFailure; + return bResult; +} + +void DoPerformLoopFinalization(..., size_t nExternalFinalizationEndItem/*=npos*/) +{ + size_t nFinalizationEndItem = nExternalFinalizationEndItem == npos + ? ... /* total item count */ + : nExternalFinalizationEndItem; + + for (... /* loop until nFinalizationEndItem */) // Or any other loop control operator + { + // Some linear code + RevertLoopItemSideEffects(...); + } +} + diff --git a/libs/ode-0.16.1/GIMPACT/GIMPACT-LICENSE-BSD.TXT b/libs/ode-0.16.1/GIMPACT/GIMPACT-LICENSE-BSD.TXT new file mode 100644 index 0000000..95545aa --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/GIMPACT-LICENSE-BSD.TXT @@ -0,0 +1,29 @@ +GIMPACT : Geometric tools for VR. + +Copyright (c) 2006 , Francisco León. +All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, + are permitted provided that the following conditions are met: + + * Redistributions of source code must retain the above copyright notice, this list of + conditions and the following disclaimer. + + * Redistributions in binary form must reproduce the above copyright notice, this list + of conditions and the following disclaimer in the documentation and/or other materials + provided with the distribution. + + * Neither the name of the GIMPACT nor the names of its contributors may be used + to endorse or promote products derived from this software without specific prior + written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS +OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, +INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING + IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH + DAMAGE. \ No newline at end of file diff --git a/libs/ode-0.16.1/GIMPACT/GIMPACT-LICENSE-LGPL.TXT b/libs/ode-0.16.1/GIMPACT/GIMPACT-LICENSE-LGPL.TXT new file mode 100644 index 0000000..60b8156 --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/GIMPACT-LICENSE-LGPL.TXT @@ -0,0 +1,502 @@ + GNU LESSER GENERAL PUBLIC LICENSE + Version 2.1, February 1999 + + Copyright (C) 1991, 1999 Free Software Foundation, Inc. + 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + +[This is the first released version of the Lesser GPL. It also counts + as the successor of the GNU Library Public License, version 2, hence + the version number 2.1.] + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +Licenses are intended to guarantee your freedom to share and change +free software--to make sure the software is free for all its users. + + This license, the Lesser General Public License, applies to some +specially designated software packages--typically libraries--of the +Free Software Foundation and other authors who decide to use it. You +can use it too, but we suggest you first think carefully about whether +this license or the ordinary General Public License is the better +strategy to use in any particular case, based on the explanations below. + + When we speak of free software, we are referring to freedom of use, +not price. Our General Public Licenses are designed to make sure that +you have the freedom to distribute copies of free software (and charge +for this service if you wish); that you receive source code or can get +it if you want it; that you can change the software and use pieces of +it in new free programs; and that you are informed that you can do +these things. + + To protect your rights, we need to make restrictions that forbid +distributors to deny you these rights or to ask you to surrender these +rights. These restrictions translate to certain responsibilities for +you if you distribute copies of the library or if you modify it. + + For example, if you distribute copies of the library, whether gratis +or for a fee, you must give the recipients all the rights that we gave +you. You must make sure that they, too, receive or can get the source +code. If you link other code with the library, you must provide +complete object files to the recipients, so that they can relink them +with the library after making changes to the library and recompiling +it. And you must show them these terms so they know their rights. + + We protect your rights with a two-step method: (1) we copyright the +library, and (2) we offer you this license, which gives you legal +permission to copy, distribute and/or modify the library. + + To protect each distributor, we want to make it very clear that +there is no warranty for the free library. Also, if the library is +modified by someone else and passed on, the recipients should know +that what they have is not the original version, so that the original +author's reputation will not be affected by problems that might be +introduced by others. + + Finally, software patents pose a constant threat to the existence of +any free program. We wish to make sure that a company cannot +effectively restrict the users of a free program by obtaining a +restrictive license from a patent holder. Therefore, we insist that +any patent license obtained for a version of the library must be +consistent with the full freedom of use specified in this license. + + Most GNU software, including some libraries, is covered by the +ordinary GNU General Public License. This license, the GNU Lesser +General Public License, applies to certain designated libraries, and +is quite different from the ordinary General Public License. We use +this license for certain libraries in order to permit linking those +libraries into non-free programs. + + When a program is linked with a library, whether statically or using +a shared library, the combination of the two is legally speaking a +combined work, a derivative of the original library. The ordinary +General Public License therefore permits such linking only if the +entire combination fits its criteria of freedom. The Lesser General +Public License permits more lax criteria for linking other code with +the library. + + We call this license the "Lesser" General Public License because it +does Less to protect the user's freedom than the ordinary General +Public License. It also provides other free software developers Less +of an advantage over competing non-free programs. These disadvantages +are the reason we use the ordinary General Public License for many +libraries. However, the Lesser license provides advantages in certain +special circumstances. + + For example, on rare occasions, there may be a special need to +encourage the widest possible use of a certain library, so that it becomes +a de-facto standard. To achieve this, non-free programs must be +allowed to use the library. A more frequent case is that a free +library does the same job as widely used non-free libraries. In this +case, there is little to gain by limiting the free library to free +software only, so we use the Lesser General Public License. + + In other cases, permission to use a particular library in non-free +programs enables a greater number of people to use a large body of +free software. For example, permission to use the GNU C Library in +non-free programs enables many more people to use the whole GNU +operating system, as well as its variant, the GNU/Linux operating +system. + + Although the Lesser General Public License is Less protective of the +users' freedom, it does ensure that the user of a program that is +linked with the Library has the freedom and the wherewithal to run +that program using a modified version of the Library. + + The precise terms and conditions for copying, distribution and +modification follow. Pay close attention to the difference between a +"work based on the library" and a "work that uses the library". The +former contains code derived from the library, whereas the latter must +be combined with the library in order to run. + + GNU LESSER GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License Agreement applies to any software library or other +program which contains a notice placed by the copyright holder or +other authorized party saying it may be distributed under the terms of +this Lesser General Public License (also called "this License"). +Each licensee is addressed as "you". + + A "library" means a collection of software functions and/or data +prepared so as to be conveniently linked with application programs +(which use some of those functions and data) to form executables. + + The "Library", below, refers to any such software library or work +which has been distributed under these terms. A "work based on the +Library" means either the Library or any derivative work under +copyright law: that is to say, a work containing the Library or a +portion of it, either verbatim or with modifications and/or translated +straightforwardly into another language. (Hereinafter, translation is +included without limitation in the term "modification".) + + "Source code" for a work means the preferred form of the work for +making modifications to it. For a library, complete source code means +all the source code for all modules it contains, plus any associated +interface definition files, plus the scripts used to control compilation +and installation of the library. + + Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running a program using the Library is not restricted, and output from +such a program is covered only if its contents constitute a work based +on the Library (independent of the use of the Library in a tool for +writing it). Whether that is true depends on what the Library does +and what the program that uses the Library does. + + 1. You may copy and distribute verbatim copies of the Library's +complete source code as you receive it, in any medium, provided that +you conspicuously and appropriately publish on each copy an +appropriate copyright notice and disclaimer of warranty; keep intact +all the notices that refer to this License and to the absence of any +warranty; and distribute a copy of this License along with the +Library. + + You may charge a fee for the physical act of transferring a copy, +and you may at your option offer warranty protection in exchange for a +fee. + + 2. You may modify your copy or copies of the Library or any portion +of it, thus forming a work based on the Library, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) The modified work must itself be a software library. + + b) You must cause the files modified to carry prominent notices + stating that you changed the files and the date of any change. + + c) You must cause the whole of the work to be licensed at no + charge to all third parties under the terms of this License. + + d) If a facility in the modified Library refers to a function or a + table of data to be supplied by an application program that uses + the facility, other than as an argument passed when the facility + is invoked, then you must make a good faith effort to ensure that, + in the event an application does not supply such function or + table, the facility still operates, and performs whatever part of + its purpose remains meaningful. + + (For example, a function in a library to compute square roots has + a purpose that is entirely well-defined independent of the + application. Therefore, Subsection 2d requires that any + application-supplied function or table used by this function must + be optional: if the application does not supply it, the square + root function must still compute square roots.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Library, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Library, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote +it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Library. + +In addition, mere aggregation of another work not based on the Library +with the Library (or with a work based on the Library) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may opt to apply the terms of the ordinary GNU General Public +License instead of this License to a given copy of the Library. To do +this, you must alter all the notices that refer to this License, so +that they refer to the ordinary GNU General Public License, version 2, +instead of to this License. (If a newer version than version 2 of the +ordinary GNU General Public License has appeared, then you can specify +that version instead if you wish.) Do not make any other change in +these notices. + + Once this change is made in a given copy, it is irreversible for +that copy, so the ordinary GNU General Public License applies to all +subsequent copies and derivative works made from that copy. + + This option is useful when you wish to copy part of the code of +the Library into a program that is not a library. + + 4. You may copy and distribute the Library (or a portion or +derivative of it, under Section 2) in object code or executable form +under the terms of Sections 1 and 2 above provided that you accompany +it with the complete corresponding machine-readable source code, which +must be distributed under the terms of Sections 1 and 2 above on a +medium customarily used for software interchange. + + If distribution of object code is made by offering access to copy +from a designated place, then offering equivalent access to copy the +source code from the same place satisfies the requirement to +distribute the source code, even though third parties are not +compelled to copy the source along with the object code. + + 5. A program that contains no derivative of any portion of the +Library, but is designed to work with the Library by being compiled or +linked with it, is called a "work that uses the Library". Such a +work, in isolation, is not a derivative work of the Library, and +therefore falls outside the scope of this License. + + However, linking a "work that uses the Library" with the Library +creates an executable that is a derivative of the Library (because it +contains portions of the Library), rather than a "work that uses the +library". The executable is therefore covered by this License. +Section 6 states terms for distribution of such executables. + + When a "work that uses the Library" uses material from a header file +that is part of the Library, the object code for the work may be a +derivative work of the Library even though the source code is not. +Whether this is true is especially significant if the work can be +linked without the Library, or if the work is itself a library. The +threshold for this to be true is not precisely defined by law. + + If such an object file uses only numerical parameters, data +structure layouts and accessors, and small macros and small inline +functions (ten lines or less in length), then the use of the object +file is unrestricted, regardless of whether it is legally a derivative +work. (Executables containing this object code plus portions of the +Library will still fall under Section 6.) + + Otherwise, if the work is a derivative of the Library, you may +distribute the object code for the work under the terms of Section 6. +Any executables containing that work also fall under Section 6, +whether or not they are linked directly with the Library itself. + + 6. As an exception to the Sections above, you may also combine or +link a "work that uses the Library" with the Library to produce a +work containing portions of the Library, and distribute that work +under terms of your choice, provided that the terms permit +modification of the work for the customer's own use and reverse +engineering for debugging such modifications. + + You must give prominent notice with each copy of the work that the +Library is used in it and that the Library and its use are covered by +this License. You must supply a copy of this License. If the work +during execution displays copyright notices, you must include the +copyright notice for the Library among them, as well as a reference +directing the user to the copy of this License. Also, you must do one +of these things: + + a) Accompany the work with the complete corresponding + machine-readable source code for the Library including whatever + changes were used in the work (which must be distributed under + Sections 1 and 2 above); and, if the work is an executable linked + with the Library, with the complete machine-readable "work that + uses the Library", as object code and/or source code, so that the + user can modify the Library and then relink to produce a modified + executable containing the modified Library. (It is understood + that the user who changes the contents of definitions files in the + Library will not necessarily be able to recompile the application + to use the modified definitions.) + + b) Use a suitable shared library mechanism for linking with the + Library. A suitable mechanism is one that (1) uses at run time a + copy of the library already present on the user's computer system, + rather than copying library functions into the executable, and (2) + will operate properly with a modified version of the library, if + the user installs one, as long as the modified version is + interface-compatible with the version that the work was made with. + + c) Accompany the work with a written offer, valid for at + least three years, to give the same user the materials + specified in Subsection 6a, above, for a charge no more + than the cost of performing this distribution. + + d) If distribution of the work is made by offering access to copy + from a designated place, offer equivalent access to copy the above + specified materials from the same place. + + e) Verify that the user has already received a copy of these + materials or that you have already sent this user a copy. + + For an executable, the required form of the "work that uses the +Library" must include any data and utility programs needed for +reproducing the executable from it. However, as a special exception, +the materials to be distributed need not include anything that is +normally distributed (in either source or binary form) with the major +components (compiler, kernel, and so on) of the operating system on +which the executable runs, unless that component itself accompanies +the executable. + + It may happen that this requirement contradicts the license +restrictions of other proprietary libraries that do not normally +accompany the operating system. Such a contradiction means you cannot +use both them and the Library together in an executable that you +distribute. + + 7. You may place library facilities that are a work based on the +Library side-by-side in a single library together with other library +facilities not covered by this License, and distribute such a combined +library, provided that the separate distribution of the work based on +the Library and of the other library facilities is otherwise +permitted, and provided that you do these two things: + + a) Accompany the combined library with a copy of the same work + based on the Library, uncombined with any other library + facilities. This must be distributed under the terms of the + Sections above. + + b) Give prominent notice with the combined library of the fact + that part of it is a work based on the Library, and explaining + where to find the accompanying uncombined form of the same work. + + 8. You may not copy, modify, sublicense, link with, or distribute +the Library except as expressly provided under this License. Any +attempt otherwise to copy, modify, sublicense, link with, or +distribute the Library is void, and will automatically terminate your +rights under this License. However, parties who have received copies, +or rights, from you under this License will not have their licenses +terminated so long as such parties remain in full compliance. + + 9. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Library or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Library (or any work based on the +Library), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Library or works based on it. + + 10. Each time you redistribute the Library (or any work based on the +Library), the recipient automatically receives a license from the +original licensor to copy, distribute, link with or modify the Library +subject to these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties with +this License. + + 11. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Library at all. For example, if a patent +license would not permit royalty-free redistribution of the Library by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Library. + +If any portion of this section is held invalid or unenforceable under any +particular circumstance, the balance of the section is intended to apply, +and the section as a whole is intended to apply in other circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 12. If the distribution and/or use of the Library is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Library under this License may add +an explicit geographical distribution limitation excluding those countries, +so that distribution is permitted only in or among countries not thus +excluded. In such case, this License incorporates the limitation as if +written in the body of this License. + + 13. The Free Software Foundation may publish revised and/or new +versions of the Lesser General Public License from time to time. +Such new versions will be similar in spirit to the present version, +but may differ in detail to address new problems or concerns. + +Each version is given a distinguishing version number. If the Library +specifies a version number of this License which applies to it and +"any later version", you have the option of following the terms and +conditions either of that version or of any later version published by +the Free Software Foundation. If the Library does not specify a +license version number, you may choose any version ever published by +the Free Software Foundation. + + 14. If you wish to incorporate parts of the Library into other free +programs whose distribution conditions are incompatible with these, +write to the author to ask for permission. For software which is +copyrighted by the Free Software Foundation, write to the Free +Software Foundation; we sometimes make exceptions for this. Our +decision will be guided by the two goals of preserving the free status +of all derivatives of our free software and of promoting the sharing +and reuse of software generally. + + NO WARRANTY + + 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO +WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. +EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR +OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY +KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE +LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME +THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN +WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY +AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU +FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR +CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE +LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING +RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A +FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF +SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH +DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Libraries + + If you develop a new library, and you want it to be of the greatest +possible use to the public, we recommend making it free software that +everyone can redistribute and change. You can do so by permitting +redistribution under these terms (or, alternatively, under the terms of the +ordinary General Public License). + + To apply these terms, attach the following notices to the library. It is +safest to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least the +"copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with this library; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + +Also add information on how to contact you by electronic and paper mail. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the library, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the + library `Frob' (a library for tweaking knobs) written by James Random Hacker. + + , 1 April 1990 + Ty Coon, President of Vice + +That's all there is to it! diff --git a/libs/ode-0.16.1/GIMPACT/Makefile.am b/libs/ode-0.16.1/GIMPACT/Makefile.am new file mode 100644 index 0000000..7a4f8e5 --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/Makefile.am @@ -0,0 +1,4 @@ +EXTRA_DIST = GIMPACT-LICENSE-BSD.TXT GIMPACT-LICENSE-LGPL.TXT + +SUBDIRS = include src + diff --git a/libs/ode-0.16.1/GIMPACT/Makefile.in b/libs/ode-0.16.1/GIMPACT/Makefile.in new file mode 100644 index 0000000..e8aa375 --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/Makefile.in @@ -0,0 +1,641 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = GIMPACT +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ + $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ + $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/ode/src/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +SOURCES = +DIST_SOURCES = +RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ + ctags-recursive dvi-recursive html-recursive info-recursive \ + install-data-recursive install-dvi-recursive \ + install-exec-recursive install-html-recursive \ + install-info-recursive install-pdf-recursive \ + install-ps-recursive install-recursive installcheck-recursive \ + installdirs-recursive pdf-recursive ps-recursive \ + tags-recursive uninstall-recursive +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ + distclean-recursive maintainer-clean-recursive +am__recursive_targets = \ + $(RECURSIVE_TARGETS) \ + $(RECURSIVE_CLEAN_TARGETS) \ + $(am__extra_recursive_targets) +AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ + distdir +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +DIST_SUBDIRS = $(SUBDIRS) +am__DIST_COMMON = $(srcdir)/Makefile.in +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +am__relativize = \ + dir0=`pwd`; \ + sed_first='s,^\([^/]*\)/.*$$,\1,'; \ + sed_rest='s,^[^/]*/*,,'; \ + sed_last='s,^.*/\([^/]*\)$$,\1,'; \ + sed_butlast='s,/*[^/]*$$,,'; \ + while test -n "$$dir1"; do \ + first=`echo "$$dir1" | sed -e "$$sed_first"`; \ + if test "$$first" != "."; then \ + if test "$$first" = ".."; then \ + dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ + dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ + else \ + first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ + if test "$$first2" = "$$first"; then \ + dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ + else \ + dir2="../$$dir2"; \ + fi; \ + dir0="$$dir0"/"$$first"; \ + fi; \ + fi; \ + dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ + done; \ + reldir="$$dir2" +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AS = @AS@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CCD_CFLAGS = @CCD_CFLAGS@ +CCD_LIBS = @CCD_LIBS@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DOXYGEN = @DOXYGEN@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +EXTRA_LIBTOOL_LDFLAGS = @EXTRA_LIBTOOL_LDFLAGS@ +FGREP = @FGREP@ +GL_LIBS = @GL_LIBS@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBSTDCXX = @LIBSTDCXX@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +ODE_PRECISION = @ODE_PRECISION@ +ODE_VERSION = @ODE_VERSION@ +ODE_VERSION_INFO = @ODE_VERSION_INFO@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +WINDRES = @WINDRES@ +X11_CFLAGS = @X11_CFLAGS@ +X11_LIBS = @X11_LIBS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_WINDRES = @ac_ct_WINDRES@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +runstatedir = @runstatedir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +EXTRA_DIST = GIMPACT-LICENSE-BSD.TXT GIMPACT-LICENSE-LGPL.TXT +SUBDIRS = include src +all: all-recursive + +.SUFFIXES: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign GIMPACT/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign GIMPACT/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +# This directory's subdirectories are mostly independent; you can cd +# into them and run 'make' without going through this Makefile. +# To change the values of 'make' variables: instead of editing Makefiles, +# (1) if the variable is set in 'config.status', edit 'config.status' +# (which will cause the Makefiles to be regenerated when you run 'make'); +# (2) otherwise, pass the desired values on the 'make' command line. +$(am__recursive_targets): + @fail=; \ + if $(am__make_keepgoing); then \ + failcom='fail=yes'; \ + else \ + failcom='exit 1'; \ + fi; \ + dot_seen=no; \ + target=`echo $@ | sed s/-recursive//`; \ + case "$@" in \ + distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ + *) list='$(SUBDIRS)' ;; \ + esac; \ + for subdir in $$list; do \ + echo "Making $$target in $$subdir"; \ + if test "$$subdir" = "."; then \ + dot_seen=yes; \ + local_target="$$target-am"; \ + else \ + local_target="$$target"; \ + fi; \ + ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ + || eval $$failcom; \ + done; \ + if test "$$dot_seen" = "no"; then \ + $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ + fi; test -z "$$fail" + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-recursive +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ + include_option=--etags-include; \ + empty_fix=.; \ + else \ + include_option=--include; \ + empty_fix=; \ + fi; \ + list='$(SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + test ! -f $$subdir/TAGS || \ + set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ + fi; \ + done; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-recursive + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-recursive + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done + @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + $(am__make_dryrun) \ + || test -d "$(distdir)/$$subdir" \ + || $(MKDIR_P) "$(distdir)/$$subdir" \ + || exit 1; \ + dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ + $(am__relativize); \ + new_distdir=$$reldir; \ + dir1=$$subdir; dir2="$(top_distdir)"; \ + $(am__relativize); \ + new_top_distdir=$$reldir; \ + echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ + echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ + ($(am__cd) $$subdir && \ + $(MAKE) $(AM_MAKEFLAGS) \ + top_distdir="$$new_top_distdir" \ + distdir="$$new_distdir" \ + am__remove_distdir=: \ + am__skip_length_check=: \ + am__skip_mode_fix=: \ + distdir) \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-recursive +all-am: Makefile +installdirs: installdirs-recursive +installdirs-am: +install: install-recursive +install-exec: install-exec-recursive +install-data: install-data-recursive +uninstall: uninstall-recursive + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-recursive +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-recursive + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-recursive + -rm -f Makefile +distclean-am: clean-am distclean-generic distclean-tags + +dvi: dvi-recursive + +dvi-am: + +html: html-recursive + +html-am: + +info: info-recursive + +info-am: + +install-data-am: + +install-dvi: install-dvi-recursive + +install-dvi-am: + +install-exec-am: + +install-html: install-html-recursive + +install-html-am: + +install-info: install-info-recursive + +install-info-am: + +install-man: + +install-pdf: install-pdf-recursive + +install-pdf-am: + +install-ps: install-ps-recursive + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-recursive + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-recursive + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-recursive + +pdf-am: + +ps: ps-recursive + +ps-am: + +uninstall-am: + +.MAKE: $(am__recursive_targets) install-am install-strip + +.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \ + check-am clean clean-generic clean-libtool cscopelist-am ctags \ + ctags-am distclean distclean-generic distclean-libtool \ + distclean-tags distdir dvi dvi-am html html-am info info-am \ + install install-am install-data install-data-am install-dvi \ + install-dvi-am install-exec install-exec-am install-html \ + install-html-am install-info install-info-am install-man \ + install-pdf install-pdf-am install-ps install-ps-am \ + install-strip installcheck installcheck-am installdirs \ + installdirs-am maintainer-clean maintainer-clean-generic \ + mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ + ps ps-am tags tags-am uninstall uninstall-am + +.PRECIOUS: Makefile + + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/libs/ode-0.16.1/GIMPACT/include/GIMPACT/Makefile.am b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/Makefile.am new file mode 100644 index 0000000..347ae72 --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/Makefile.am @@ -0,0 +1,6 @@ +noinst_HEADERS = \ + gim_boxpruning.h gim_contact.h gim_geometry.h \ + gim_math.h gim_memory.h gimpact.h \ + gim_radixsort.h gim_tri_capsule_collision.h gim_tri_collision.h \ + gim_trimesh.h gim_tri_sphere_collision.h + diff --git a/libs/ode-0.16.1/GIMPACT/include/GIMPACT/Makefile.in b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/Makefile.in new file mode 100644 index 0000000..78758f7 --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/Makefile.in @@ -0,0 +1,533 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = GIMPACT/include/GIMPACT +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ + $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ + $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(noinst_HEADERS) \ + $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/ode/src/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +SOURCES = +DIST_SOURCES = +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +HEADERS = $(noinst_HEADERS) +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AS = @AS@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CCD_CFLAGS = @CCD_CFLAGS@ +CCD_LIBS = @CCD_LIBS@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DOXYGEN = @DOXYGEN@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +EXTRA_LIBTOOL_LDFLAGS = @EXTRA_LIBTOOL_LDFLAGS@ +FGREP = @FGREP@ +GL_LIBS = @GL_LIBS@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBSTDCXX = @LIBSTDCXX@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +ODE_PRECISION = @ODE_PRECISION@ +ODE_VERSION = @ODE_VERSION@ +ODE_VERSION_INFO = @ODE_VERSION_INFO@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +WINDRES = @WINDRES@ +X11_CFLAGS = @X11_CFLAGS@ +X11_LIBS = @X11_LIBS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_WINDRES = @ac_ct_WINDRES@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +runstatedir = @runstatedir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +noinst_HEADERS = \ + gim_boxpruning.h gim_contact.h gim_geometry.h \ + gim_math.h gim_memory.h gimpact.h \ + gim_radixsort.h gim_tri_capsule_collision.h gim_tri_collision.h \ + gim_trimesh.h gim_tri_sphere_collision.h + +all: all-am + +.SUFFIXES: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign GIMPACT/include/GIMPACT/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign GIMPACT/include/GIMPACT/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(HEADERS) +installdirs: +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-am + -rm -f Makefile +distclean-am: clean-am distclean-generic distclean-tags + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: + +.MAKE: install-am install-strip + +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ + clean-libtool cscopelist-am ctags ctags-am distclean \ + distclean-generic distclean-libtool distclean-tags distdir dvi \ + dvi-am html html-am info info-am install install-am \ + install-data install-data-am install-dvi install-dvi-am \ + install-exec install-exec-am install-html install-html-am \ + install-info install-info-am install-man install-pdf \ + install-pdf-am install-ps install-ps-am install-strip \ + installcheck installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-generic \ + mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \ + uninstall-am + +.PRECIOUS: Makefile + + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_boxpruning.h b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_boxpruning.h new file mode 100644 index 0000000..cfa6c79 --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_boxpruning.h @@ -0,0 +1,323 @@ +#ifndef GIM_BOXPRUNING_H_INCLUDED +#define GIM_BOXPRUNING_H_INCLUDED + +/*! \file gim_boxpruning.h +\author Francisco León +*/ +/* +----------------------------------------------------------------------------- +This source file is part of GIMPACT Library. + +For the latest info, see http://gimpact.sourceforge.net/ + +Copyright (c) 2006 Francisco Leon. C.C. 80087371. +email: projectileman@yahoo.com + + This library is free software; you can redistribute it and/or + modify it under the terms of EITHER: + (1) The GNU Lesser General Public License as published by the Free + Software Foundation; either version 2.1 of the License, or (at + your option) any later version. The text of the GNU Lesser + General Public License is included with this library in the + file GIMPACT-LICENSE-LGPL.TXT. + (2) The BSD-style license that is included with this library in + the file GIMPACT-LICENSE-BSD.TXT. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files + GIMPACT-LICENSE-LGPL.TXT and GIMPACT-LICENSE-BSD.TXT for more details. + +----------------------------------------------------------------------------- +*/ + + +#include "GIMPACT/gim_radixsort.h" +#include "GIMPACT/gim_geometry.h" + +/*! \defgroup BOX_PRUNNING + +\brief +Tools for find overlapping objects on a scenary. These functions sort boxes for faster collisioin queries, using radix sort or quick sort as convenience. See \ref SORTING . +
    +
  • For using these collision routines, you must create a \ref GIM_AABB_SET by using this function : \ref gim_aabbset_alloc. +
  • The GIM_AABB_SET objects must be updated on their boxes on each query, and they must be update by calling \ref gim_aabbset_update +
  • Before calling collision functions, you must create a pair set with \ref GIM_CREATE_PAIR_SET +
  • For finding collision pairs on a scene (common space for objects), call \ref gim_aabbset_self_intersections +
  • For finding collision pairs between two box sets , call \ref gim_aabbset_box_collision +
  • After using collision routines, you must destroy the pairset with \ref GIM_DESTROY_PAIR_SET +
  • When the box set is no longer used, you must destroy it by calling \ref gim_aabbset_destroy +
+*/ +//! @{ +//! Overlapping pair +struct GIM_PAIR +{ + GUINT32 m_index1; + GUINT32 m_index2; +}; +//typedef struct _GIM_PAIR GIM_PAIR; + +//! Box container +struct GIM_AABB_SET +{ + GUINT32 m_count; + aabb3f m_global_bound;//!< Global calculated bound of all boxes + aabb3f * m_boxes; + GUINT32 * m_maxcoords;//!m_sorted_mincoords == 0, then it allocs the sorted coordinates +*/ +void gim_aabbset_sort(GIM_AABB_SET * aabbset, char calc_global_bound); + +//! log(N) Complete box pruning. Returns a list of overlapping pairs of boxes, each box of the pair belongs to the same set. +/*! +\pre aabbset must be allocated and sorted, the boxes must be already set. +\param aabbset Must be sorted. Global bound isn't required +\param collision_pairs Array of GIM_PAIR elements. Must be initialized before (Reserve size ~ 100) +*/ +void gim_aabbset_self_intersections_sorted(GIM_AABB_SET * aabbset, GDYNAMIC_ARRAY * collision_pairs); + +//! NxN Complete box pruning. Returns a list of overlapping pairs of boxes, each box of the pair belongs to the same set. +/*! +\pre aabbset must be allocated, the boxes must be already set. +\param aabbset Global bound isn't required. Doen't need to be sorted. +\param collision_pairs Array of GIM_PAIR elements. Must be initialized before (Reserve size ~ 100) +*/ +void gim_aabbset_self_intersections_brute_force(GIM_AABB_SET * aabbset, GDYNAMIC_ARRAY * collision_pairs); + +//! log(N) Bipartite box pruning. Returns a list of overlapping pairs of boxes, each box of the pair belongs to a different set. +/*! +\pre aabbset1 and aabbset2 must be allocated and sorted, the boxes must be already set. +\param aabbset1 Must be sorted, Global bound is required. +\param aabbset2 Must be sorted, Global bound is required. +\param collision_pairs Array of GIM_PAIR elements. Must be initialized before (Reserve size ~ 100) +*/ +void gim_aabbset_bipartite_intersections_sorted(GIM_AABB_SET * aabbset1, GIM_AABB_SET * aabbset2, GDYNAMIC_ARRAY * collision_pairs); + +//! NxM Bipartite box pruning. Returns a list of overlapping pairs of boxes, each box of the pair belongs to a different set. +/*! +\pre aabbset1 and aabbset2 must be allocated and sorted, the boxes must be already set. +\param aabbset1 Must be sorted, Global bound is required. +\param aabbset2 Must be sorted, Global bound is required. +\param collision_pairs Array of GIM_PAIR elements. Must be initialized before (Reserve size ~ 100) +*/ +void gim_aabbset_bipartite_intersections_brute_force(GIM_AABB_SET * aabbset1,GIM_AABB_SET * aabbset2, GDYNAMIC_ARRAY * collision_pairs); + + +/* + Brute-Force Vs Sorted pruning +Different approaches must be applied when colliding sets with different number of +elements. When sets have less of 100 boxes, is often better to apply force brute +approach instead of sorted methods, because at lowlevel bruteforce routines gives +better perormance and consumes less resources, due of their simplicity. +But when sets are larger, the complexiity of bruteforce increases exponencially. +In the case of large sets, sorted approach is applied. So GIMPACT has the following +strategies: + +On Sorting sets: +!) When sets have more of 140 boxes, the boxes are sorted by its coded min coord +and the global box is calculated. But when sets are smaller (less of 140 boxes), +Is convenient to apply brute force approach. + +*******************************************************************************/ + +//! Constant for apply approaches between brute force and sorted pruning on bipartite queries +#define GIM_MIN_SORTED_BIPARTITE_PRUNING_BOXES 600 +//! Constant for apply approaches between brute force and sorted pruning for box collision +#define GIM_MIN_SORTED_PRUNING_BOXES 140 + + +//Use these functions for general initialization + +//! Initalizes the set. Sort Boxes if needed. +/*! +\pre aabbset must be allocated. And the boxes must be already set. +\post If the set has less of GIM_MIN_SORTED_BIPARTITE_PRUNING_BOXES boxes, only calcs the global box, + else it Sorts the entire set( Only applicable for large sets) +*/ +void gim_aabbset_update(GIM_AABB_SET * aabbset); + +///Use these functions for general collision + +//! Complete box pruning. Returns a list of overlapping pairs of boxes, each box of the pair belongs to the same set. +/*! +This function sorts the set and then it calls to gim_aabbset_self_intersections_brute_force or gim_aabbset_self_intersections_sorted. This is an example of how to use this function: +\code +//Create contact list +GDYNAMIC_ARRAY collision_pairs; +GIM_CREATE_PAIR_SET(collision_pairs); +//Do collision +gim_aabbset_self_intersections(&aabbset,&collision_pairs); +if(collision_pairs.m_size==0) +{ + GIM_DYNARRAY_DESTROY(collision_pairs);// + return; //no collisioin +} + +//pair pointer +GIM_PAIR *pairs = GIM_DYNARRAY_POINTER(GIM_PAIR,collision_pairs); +GUINT i, ti1,ti2; +for (i=0;im_count >= GIM_MIN_SORTED_PRUNING_BOXES, then it calls to gim_aabbset_sort and then to gim_aabbset_self_intersections_sorted. Global box won't be calculated. +*/ +void gim_aabbset_self_intersections(GIM_AABB_SET * aabbset, GDYNAMIC_ARRAY * collision_pairs); + +//! Collides two sets. Returns a list of overlapping pairs of boxes, each box of the pair belongs to a different set. +/*! +\pre aabbset1 and aabbset2 must be allocated and updated. See gim_aabbset_update. +\param aabbset1 Must be updated. +\param aabbset2 Must be updated. +\param collision_pairs Array of GIM_PAIR elements. Must be initialized before (Reserve size ~ 100) +*/ +void gim_aabbset_bipartite_intersections(GIM_AABB_SET * aabbset1, GIM_AABB_SET * aabbset2, GDYNAMIC_ARRAY * collision_pairs); + +///Function for create Box collision result set + +#define GIM_CREATE_BOXQUERY_LIST(dynarray) GIM_DYNARRAY_CREATE(GUINT32,dynarray,G_ARRAY_GROW_SIZE) + +//! Finds intersections between a box and a set. Return the colliding boxes of the set +/*! +\pre aabbset must be allocated and initialized. +\param test_aabb Box for collision query +\param aabbset Set of boxes .Global bound is required. +\param collided Array of GUINT elements, indices of boxes. Must be initialized before (Reserve size ~ 100) +*/ +void gim_aabbset_box_collision(aabb3f *test_aabb, GIM_AABB_SET * aabbset, GDYNAMIC_ARRAY * collided); + +//! Finds intersections between a box and a set. Return the colliding boxes of the set +/*! +\pre aabbset must be allocated and initialized. +\param vorigin Origin point of ray. +\param vdir Direction vector of ray. +\param tmax Max distance param for ray. +\param aabbset Set of boxes .Global bound is required. +\param collided Array of GUINT elements, indices of boxes. Must be initialized before (Reserve size ~ 100) +*/ +void gim_aabbset_ray_collision(vec3f vorigin,vec3f vdir, GREAL tmax, GIM_AABB_SET * aabbset, GDYNAMIC_ARRAY * collided); + + +/* +For sorting, each box corner must be discretized to a 32 bit integer. +For this, we take the x and z coordinates from the box corner (a vector vec3f) +Then convert the (x,z) pair to an integer. For convenience, we choose an error +constant for converting the coordinates (0.05). +*******************************************************************************/ + +/** + For fitting the coordinate to an integer, we need to constraint the range of its values. So each coord component (x, z) must lie between 0 and 65536. + 20 give us a 0.05 floating point error +*/ +#define ERROR_AABB 20.0f + +/** +An error of 0.05 allows to make coordinates up to 1638.0f and no less of -1638.0f. +So the maximum size of a room should be about 3276x3276 . Its dimensions must lie between [-1638,1638.0f] +*/ +#define MAX_AABB_SIZE 1638.0f + +//! Converts a vector coordinate to an integer for box sorting +/*! +\param vx X component +\param vz Z component +\param uint_key a GUINT +*/ +#define GIM_CONVERT_VEC3F_GUINT_XZ(vx,vz,uint_key)\ +{\ + GUINT32 _z = ((GUINT32)(vz*ERROR_AABB))+32768;\ + uint_key = ((GUINT32)(vx*ERROR_AABB))+32768;\ + uint_key = (uint_key<<16) + _z;\ +}\ + +//! Converts a vector coordinate to an integer for box sorting,rounding to the upper int +/*! +\param vx X component +\param vz Z component +\param uint_key a GUINT +*/ +#define GIM_CONVERT_VEC3F_GUINT_XZ_UPPER(vx,vz,uint_key)\ +{\ + GUINT32 _z = ((GUINT32)ceilf(vz*ERROR_AABB))+32768;\ + uint_key = ((GUINT32)ceilf(vx*ERROR_AABB))+32768;\ + uint_key = (uint_key<<16) + _z;\ +}\ + + +//! Converts a vector coordinate to an integer for box sorting. Secure clamped +/*! +\param vx X component +\param vz Z component +\param uint_key a GUINT +*/ +#define GIM_CONVERT_VEC3F_GUINT_XZ_CLAMPED(vx,vz,uint_key)\ +{\ + GREAL _cx = CLAMP(vx,-MAX_AABB_SIZE,MAX_AABB_SIZE);\ + GREAL _cz = CLAMP(vz,-MAX_AABB_SIZE,MAX_AABB_SIZE);\ + GUINT32 _z = ((GUINT32)(_cz*ERROR_AABB))+32768;\ + uint_key = ((GUINT32)(_cx*ERROR_AABB))+32768;\ + uint_key = (uint_key<<16) + _z;\ +}\ + +//! Converts a vector coordinate to an integer for box sorting. Secure clamped, rounded +/*! +\param vx X component +\param vz Z component +\param uint_key a GUINT +*/ +#define GIM_CONVERT_VEC3F_GUINT_XZ_UPPER_CLAMPED(vx,vz,uint_key)\ +{\ + GREAL _cx = CLAMP(vx,-MAX_AABB_SIZE,MAX_AABB_SIZE);\ + GREAL _cz = CLAMP(vz,-MAX_AABB_SIZE,MAX_AABB_SIZE);\ + GUINT32 _z = ((GUINT32)ceilf(_cz*ERROR_AABB))+32768;\ + uint_key = ((GUINT32)ceilf(_cx*ERROR_AABB))+32768;\ + uint_key = (uint_key<<16) + _z;\ +}\ + +//! @} + +#endif // GIM_BOXPRUNING_H_INCLUDED diff --git a/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_contact.h b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_contact.h new file mode 100644 index 0000000..e7f5b5e --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_contact.h @@ -0,0 +1,115 @@ +#ifndef GIM_CONTACT_H_INCLUDED +#define GIM_CONTACT_H_INCLUDED + +/*! \file gim_contact.h +\author Francisco León +*/ +/* +----------------------------------------------------------------------------- +This source file is part of GIMPACT Library. + +For the latest info, see http://gimpact.sourceforge.net/ + +Copyright (c) 2006 Francisco Leon. C.C. 80087371. +email: projectileman@yahoo.com + + This library is free software; you can redistribute it and/or + modify it under the terms of EITHER: + (1) The GNU Lesser General Public License as published by the Free + Software Foundation; either version 2.1 of the License, or (at + your option) any later version. The text of the GNU Lesser + General Public License is included with this library in the + file GIMPACT-LICENSE-LGPL.TXT. + (2) The BSD-style license that is included with this library in + the file GIMPACT-LICENSE-BSD.TXT. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files + GIMPACT-LICENSE-LGPL.TXT and GIMPACT-LICENSE-BSD.TXT for more details. + +----------------------------------------------------------------------------- +*/ + + +#include "GIMPACT/gim_geometry.h" +#include "GIMPACT/gim_radixsort.h" + +/*! \defgroup CONTACTS +\brief +Functions for managing and sorting contacts resulting from a collision query. +
    +
  • Contact lists must be create by calling \ref GIM_CREATE_CONTACT_LIST +
  • After querys, contact lists must be destroy by calling \ref GIM_DYNARRAY_DESTROY +
  • Contacts can be merge for avoid duplicate results by calling \ref gim_merge_contacts +
+ +*/ +//! @{ +/// Structure for collision results +struct GIM_CONTACT +{ + vec3f m_point; + vec3f m_normal; + GREAL m_depth;//Positive value indicates interpenetration + void * m_handle1; + void * m_handle2; + GUINT32 m_feature1;//Face number + GUINT32 m_feature2;//Face number +}; +//typedef struct _GIM_CONTACT GIM_CONTACT; + +#define CONTACT_DIFF_EPSILON 0.00001f + +#define GIM_CALC_KEY_CONTACT(pos,hash)\ +{\ + GINT32 _coords[] = {(GINT32)(pos[0]*1000.0f+1.0f),(GINT32)(pos[1]*1333.0f),(GINT32)(pos[2]*2133.0f+3.0f)};\ + GUINT32 _hash=0;\ + GUINT32 *_uitmp = (GUINT32 *)(&_coords[0]);\ + _hash = *_uitmp;\ + _uitmp++;\ + _hash += (*_uitmp)<<4;\ + _uitmp++;\ + _hash += (*_uitmp)<<8;\ + hash = _hash;\ +}\ + +///Creates a contact list for queries +#define GIM_CREATE_CONTACT_LIST(contact_array) GIM_DYNARRAY_CREATE(GIM_CONTACT,contact_array,100) + +#define GIM_PUSH_CONTACT(contact_array, point, normal, deep,handle1, handle2, feat1, feat2)\ +{\ + GIM_DYNARRAY_PUSH_EMPTY(GIM_CONTACT,contact_array);\ + GIM_CONTACT * _last = GIM_DYNARRAY_POINTER_LAST(GIM_CONTACT,contact_array);\ + VEC_COPY(_last->m_point,point);\ + VEC_COPY(_last->m_normal,normal);\ + _last->m_depth = deep;\ + _last->m_handle1 = handle1;\ + _last->m_handle2 = handle2;\ + _last->m_feature1 = feat1;\ + _last->m_feature2 = feat2;\ +}\ + +///Receive pointer to contacts +#define GIM_COPY_CONTACTS(dest_contact, source_contact)\ +{\ + VEC_COPY(dest_contact->m_point,source_contact->m_point);\ + VEC_COPY(dest_contact->m_normal,source_contact->m_normal);\ + dest_contact->m_depth = source_contact->m_depth;\ + dest_contact->m_handle1 = source_contact->m_handle1;\ + dest_contact->m_handle2 = source_contact->m_handle2;\ + dest_contact->m_feature1 = source_contact->m_feature1;\ + dest_contact->m_feature2 = source_contact->m_feature2;\ +}\ + +//! Merges duplicate contacts with minimum depth criterion +void gim_merge_contacts(GDYNAMIC_ARRAY * source_contacts, + GDYNAMIC_ARRAY * dest_contacts); + + +//! Merges to an unique contact +void gim_merge_contacts_unique(GDYNAMIC_ARRAY * source_contacts, + GDYNAMIC_ARRAY * dest_contacts); + +//! @} +#endif // GIM_CONTACT_H_INCLUDED diff --git a/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_geometry.h b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_geometry.h new file mode 100644 index 0000000..f2b5ccb --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_geometry.h @@ -0,0 +1,1885 @@ +#ifndef GIM_VECTOR_H_INCLUDED +#define GIM_VECTOR_H_INCLUDED + +/*! \file gim_geometry.h +\author Francisco León +*/ +/* +----------------------------------------------------------------------------- +This source file is part of GIMPACT Library. + +For the latest info, see http://gimpact.sourceforge.net/ + +Copyright (c) 2006 Francisco Leon. C.C. 80087371. +email: projectileman@yahoo.com + + This library is free software; you can redistribute it and/or + modify it under the terms of EITHER: + (1) The GNU Lesser General Public License as published by the Free + Software Foundation; either version 2.1 of the License, or (at + your option) any later version. The text of the GNU Lesser + General Public License is included with this library in the + file GIMPACT-LICENSE-LGPL.TXT. + (2) The BSD-style license that is included with this library in + the file GIMPACT-LICENSE-BSD.TXT. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files + GIMPACT-LICENSE-LGPL.TXT and GIMPACT-LICENSE-BSD.TXT for more details. + +----------------------------------------------------------------------------- +*/ + + +#include "GIMPACT/gim_math.h" + +/*! \defgroup GEOMETRIC_TYPES +\brief +Basic types and constants for geometry +*/ +//! @{ + +//! Integer vector 2D +typedef GINT32 vec2i[2]; +//! Integer vector 3D +typedef GINT32 vec3i[3]; +//! Integer vector 4D +typedef GINT32 vec4i[4]; + +//! Float vector 2D +typedef GREAL vec2f[2]; +//! Float vector 3D +typedef GREAL vec3f[3]; +//! Float vector 4D +typedef GREAL vec4f[4]; + +//! Matrix 2D, row ordered +typedef GREAL mat2f[2][2]; +//! Matrix 3D, row ordered +typedef GREAL mat3f[3][3]; +//! Matrix 4D, row ordered +typedef GREAL mat4f[4][4]; + +//! Quaternion +typedef GREAL quatf[4]; + +//! Axis aligned box +struct aabb3f{ + aabb3f() {} + + template + aabb3f(const tboundfloat &_minX, const tboundfloat &_maxX, const tboundfloat &_minY, const tboundfloat &_maxY, const tboundfloat &_minZ, const tboundfloat &_maxZ): + minX((GREAL)_minX), + maxX((GREAL)_maxX), + minY((GREAL)_minY), + maxY((GREAL)_maxY), + minZ((GREAL)_minZ), + maxZ((GREAL)_maxZ) + { + } + + GREAL minX; + GREAL maxX; + GREAL minY; + GREAL maxY; + GREAL minZ; + GREAL maxZ; +}; +//typedef struct _aabb3f aabb3f; +//! @} + + +/*! \defgroup VECTOR_OPERATIONS +Operations for vectors : vec2f,vec3f and vec4f +*/ +//! @{ + +//! Zero out a 2D vector +#define VEC_ZERO_2(a) \ +{ \ + (a)[0] = (a)[1] = 0.0f; \ +}\ + + +//! Zero out a 3D vector +#define VEC_ZERO(a) \ +{ \ + (a)[0] = (a)[1] = (a)[2] = 0.0f; \ +}\ + + +/// Zero out a 4D vector +#define VEC_ZERO_4(a) \ +{ \ + (a)[0] = (a)[1] = (a)[2] = (a)[3] = 0.0f; \ +}\ + + +/// Vector copy +#define VEC_COPY_2(b,a) \ +{ \ + (b)[0] = (a)[0]; \ + (b)[1] = (a)[1]; \ +}\ + + +/// Copy 3D vector +#define VEC_COPY(b,a) \ +{ \ + (b)[0] = (a)[0]; \ + (b)[1] = (a)[1]; \ + (b)[2] = (a)[2]; \ +}\ + + +/// Copy 4D vector +#define VEC_COPY_4(b,a) \ +{ \ + (b)[0] = (a)[0]; \ + (b)[1] = (a)[1]; \ + (b)[2] = (a)[2]; \ + (b)[3] = (a)[3]; \ +}\ + + +/// Vector difference +#define VEC_DIFF_2(v21,v2,v1) \ +{ \ + (v21)[0] = (v2)[0] - (v1)[0]; \ + (v21)[1] = (v2)[1] - (v1)[1]; \ +}\ + + +/// Vector difference +#define VEC_DIFF(v21,v2,v1) \ +{ \ + (v21)[0] = (v2)[0] - (v1)[0]; \ + (v21)[1] = (v2)[1] - (v1)[1]; \ + (v21)[2] = (v2)[2] - (v1)[2]; \ +}\ + + +/// Vector difference +#define VEC_DIFF_4(v21,v2,v1) \ +{ \ + (v21)[0] = (v2)[0] - (v1)[0]; \ + (v21)[1] = (v2)[1] - (v1)[1]; \ + (v21)[2] = (v2)[2] - (v1)[2]; \ + (v21)[3] = (v2)[3] - (v1)[3]; \ +}\ + + +/// Vector sum +#define VEC_SUM_2(v21,v2,v1) \ +{ \ + (v21)[0] = (v2)[0] + (v1)[0]; \ + (v21)[1] = (v2)[1] + (v1)[1]; \ +}\ + + +/// Vector sum +#define VEC_SUM(v21,v2,v1) \ +{ \ + (v21)[0] = (v2)[0] + (v1)[0]; \ + (v21)[1] = (v2)[1] + (v1)[1]; \ + (v21)[2] = (v2)[2] + (v1)[2]; \ +}\ + + +/// Vector sum +#define VEC_SUM_4(v21,v2,v1) \ +{ \ + (v21)[0] = (v2)[0] + (v1)[0]; \ + (v21)[1] = (v2)[1] + (v1)[1]; \ + (v21)[2] = (v2)[2] + (v1)[2]; \ + (v21)[3] = (v2)[3] + (v1)[3]; \ +}\ + + +/// scalar times vector +#define VEC_SCALE_2(c,a,b) \ +{ \ + (c)[0] = (a)*(b)[0]; \ + (c)[1] = (a)*(b)[1]; \ +}\ + + +/// scalar times vector +#define VEC_SCALE(c,a,b) \ +{ \ + (c)[0] = (a)*(b)[0]; \ + (c)[1] = (a)*(b)[1]; \ + (c)[2] = (a)*(b)[2]; \ +}\ + + +/// scalar times vector +#define VEC_SCALE_4(c,a,b) \ +{ \ + (c)[0] = (a)*(b)[0]; \ + (c)[1] = (a)*(b)[1]; \ + (c)[2] = (a)*(b)[2]; \ + (c)[3] = (a)*(b)[3]; \ +}\ + + +/// accumulate scaled vector +#define VEC_ACCUM_2(c,a,b) \ +{ \ + (c)[0] += (a)*(b)[0]; \ + (c)[1] += (a)*(b)[1]; \ +}\ + + +/// accumulate scaled vector +#define VEC_ACCUM(c,a,b) \ +{ \ + (c)[0] += (a)*(b)[0]; \ + (c)[1] += (a)*(b)[1]; \ + (c)[2] += (a)*(b)[2]; \ +}\ + + +/// accumulate scaled vector +#define VEC_ACCUM_4(c,a,b) \ +{ \ + (c)[0] += (a)*(b)[0]; \ + (c)[1] += (a)*(b)[1]; \ + (c)[2] += (a)*(b)[2]; \ + (c)[3] += (a)*(b)[3]; \ +}\ + + +/// Vector dot product +#define VEC_DOT_2(a,b) ((a)[0]*(b)[0] + (a)[1]*(b)[1]) + + +/// Vector dot product +#define VEC_DOT(a,b) ((a)[0]*(b)[0] + (a)[1]*(b)[1] + (a)[2]*(b)[2]) + +/// Vector dot product +#define VEC_DOT_4(a,b) ((a)[0]*(b)[0] + (a)[1]*(b)[1] + (a)[2]*(b)[2] + (a)[3]*(b)[3]) + +/// vector impact parameter (squared) +#define VEC_IMPACT_SQ(bsq,direction,position) {\ + GREAL _llel_ = VEC_DOT(direction, position);\ + bsq = VEC_DOT(position, position) - _llel_*_llel_;\ +}\ + + +/// vector impact parameter +#define VEC_IMPACT(bsq,direction,position) {\ + VEC_IMPACT_SQ(bsq,direction,position); \ + GIM_SQRT(bsq,bsq); \ +}\ + +/// Vector length +#define VEC_LENGTH_2(a,l)\ +{\ + GREAL _pp = VEC_DOT_2(a,a);\ + GIM_SQRT(_pp,l);\ +}\ + + +/// Vector length +#define VEC_LENGTH(a,l)\ +{\ + GREAL _pp = VEC_DOT(a,a);\ + GIM_SQRT(_pp,l);\ +}\ + + +/// Vector length +#define VEC_LENGTH_4(a,l)\ +{\ + GREAL _pp = VEC_DOT_4(a,a);\ + GIM_SQRT(_pp,l);\ +}\ + +/// Vector inv length +#define VEC_INV_LENGTH_2(a,l)\ +{\ + GREAL _pp = VEC_DOT_2(a,a);\ + GIM_INV_SQRT(_pp,l);\ +}\ + + +/// Vector inv length +#define VEC_INV_LENGTH(a,l)\ +{\ + GREAL _pp = VEC_DOT(a,a);\ + GIM_INV_SQRT(_pp,l);\ +}\ + + +/// Vector inv length +#define VEC_INV_LENGTH_4(a,l)\ +{\ + GREAL _pp = VEC_DOT_4(a,a);\ + GIM_INV_SQRT(_pp,l);\ +}\ + + + +/// distance between two points +#define VEC_DISTANCE(_len,_va,_vb) {\ + vec3f _tmp_; \ + VEC_DIFF(_tmp_, _vb, _va); \ + VEC_LENGTH(_tmp_,_len); \ +}\ + + +/// Vector length +#define VEC_CONJUGATE_LENGTH(a,l)\ +{\ + GREAL _pp = 1.0 - a[0]*a[0] - a[1]*a[1] - a[2]*a[2];\ + GIM_SQRT(_pp,l);\ +}\ + + +/// Vector length +#define VEC_NORMALIZE(a) { \ + GREAL len;\ + VEC_INV_LENGTH(a,len); \ + if(len +Last column is added as the position +*/ +#define MAT_DOT_VEC_3X4(p,m,v) \ +{ \ + p[0] = m[0][0]*v[0] + m[0][1]*v[1] + m[0][2]*v[2] + m[0][3]; \ + p[1] = m[1][0]*v[0] + m[1][1]*v[1] + m[1][2]*v[2] + m[1][3]; \ + p[2] = m[2][0]*v[0] + m[2][1]*v[1] + m[2][2]*v[2] + m[2][3]; \ +}\ + +/*! vector transpose times matrix */ +/*! p[j] = v[0]*m[0][j] + v[1]*m[1][j] + v[2]*m[2][j]; */ +#define VEC_DOT_MAT_3X3(p,v,m) \ +{ \ + p[0] = v[0]*m[0][0] + v[1]*m[1][0] + v[2]*m[2][0]; \ + p[1] = v[0]*m[0][1] + v[1]*m[1][1] + v[2]*m[2][1]; \ + p[2] = v[0]*m[0][2] + v[1]*m[1][2] + v[2]*m[2][2]; \ +}\ + + +/*! affine matrix times vector */ +/** The matrix is assumed to be an affine matrix, with last two + * entries representing a translation */ +#define MAT_DOT_VEC_2X3(p,m,v) \ +{ \ + p[0] = m[0][0]*v[0] + m[0][1]*v[1] + m[0][2]; \ + p[1] = m[1][0]*v[0] + m[1][1]*v[1] + m[1][2]; \ +}\ + + +/** inverse transpose of matrix times vector + * + * This macro computes inverse transpose of matrix m, + * and multiplies vector v into it, to yeild vector p + * + * DANGER !!! Do Not use this on normal vectors!!! + * It will leave normals the wrong length !!! + * See macro below for use on normals. + */ +#define INV_TRANSP_MAT_DOT_VEC_2X2(p,m,v) \ +{ \ + GREAL det; \ + \ + det = m[0][0]*m[1][1] - m[0][1]*m[1][0]; \ + p[0] = m[1][1]*v[0] - m[1][0]*v[1]; \ + p[1] = - m[0][1]*v[0] + m[0][0]*v[1]; \ + \ + /* if matrix not singular, and not orthonormal, then renormalize */ \ + if ((det!=1.0f) && (det != 0.0f)) { \ + det = 1.0f / det; \ + p[0] *= det; \ + p[1] *= det; \ + } \ +}\ + + +/** transform normal vector by inverse transpose of matrix + * and then renormalize the vector + * + * This macro computes inverse transpose of matrix m, + * and multiplies vector v into it, to yeild vector p + * Vector p is then normalized. + */ +#define NORM_XFORM_2X2(p,m,v) \ +{ \ + double len; \ + \ + /* do nothing if off-diagonals are zero and diagonals are \ + * equal */ \ + if ((m[0][1] != 0.0) || (m[1][0] != 0.0) || (m[0][0] != m[1][1])) { \ + p[0] = m[1][1]*v[0] - m[1][0]*v[1]; \ + p[1] = - m[0][1]*v[0] + m[0][0]*v[1]; \ + \ + len = p[0]*p[0] + p[1]*p[1]; \ + GIM_INV_SQRT(len,len); \ + p[0] *= len; \ + p[1] *= len; \ + } else { \ + VEC_COPY_2 (p, v); \ + } \ +}\ + + +/** outer product of vector times vector transpose + * + * The outer product of vector v and vector transpose t yeilds + * dyadic matrix m. + */ +#define OUTER_PRODUCT_2X2(m,v,t) \ +{ \ + m[0][0] = v[0] * t[0]; \ + m[0][1] = v[0] * t[1]; \ + \ + m[1][0] = v[1] * t[0]; \ + m[1][1] = v[1] * t[1]; \ +}\ + + +/** outer product of vector times vector transpose + * + * The outer product of vector v and vector transpose t yeilds + * dyadic matrix m. + */ +#define OUTER_PRODUCT_3X3(m,v,t) \ +{ \ + m[0][0] = v[0] * t[0]; \ + m[0][1] = v[0] * t[1]; \ + m[0][2] = v[0] * t[2]; \ + \ + m[1][0] = v[1] * t[0]; \ + m[1][1] = v[1] * t[1]; \ + m[1][2] = v[1] * t[2]; \ + \ + m[2][0] = v[2] * t[0]; \ + m[2][1] = v[2] * t[1]; \ + m[2][2] = v[2] * t[2]; \ +}\ + + +/** outer product of vector times vector transpose + * + * The outer product of vector v and vector transpose t yeilds + * dyadic matrix m. + */ +#define OUTER_PRODUCT_4X4(m,v,t) \ +{ \ + m[0][0] = v[0] * t[0]; \ + m[0][1] = v[0] * t[1]; \ + m[0][2] = v[0] * t[2]; \ + m[0][3] = v[0] * t[3]; \ + \ + m[1][0] = v[1] * t[0]; \ + m[1][1] = v[1] * t[1]; \ + m[1][2] = v[1] * t[2]; \ + m[1][3] = v[1] * t[3]; \ + \ + m[2][0] = v[2] * t[0]; \ + m[2][1] = v[2] * t[1]; \ + m[2][2] = v[2] * t[2]; \ + m[2][3] = v[2] * t[3]; \ + \ + m[3][0] = v[3] * t[0]; \ + m[3][1] = v[3] * t[1]; \ + m[3][2] = v[3] * t[2]; \ + m[3][3] = v[3] * t[3]; \ +}\ + + +/** outer product of vector times vector transpose + * + * The outer product of vector v and vector transpose t yeilds + * dyadic matrix m. + */ +#define ACCUM_OUTER_PRODUCT_2X2(m,v,t) \ +{ \ + m[0][0] += v[0] * t[0]; \ + m[0][1] += v[0] * t[1]; \ + \ + m[1][0] += v[1] * t[0]; \ + m[1][1] += v[1] * t[1]; \ +}\ + + +/** outer product of vector times vector transpose + * + * The outer product of vector v and vector transpose t yeilds + * dyadic matrix m. + */ +#define ACCUM_OUTER_PRODUCT_3X3(m,v,t) \ +{ \ + m[0][0] += v[0] * t[0]; \ + m[0][1] += v[0] * t[1]; \ + m[0][2] += v[0] * t[2]; \ + \ + m[1][0] += v[1] * t[0]; \ + m[1][1] += v[1] * t[1]; \ + m[1][2] += v[1] * t[2]; \ + \ + m[2][0] += v[2] * t[0]; \ + m[2][1] += v[2] * t[1]; \ + m[2][2] += v[2] * t[2]; \ +}\ + + +/** outer product of vector times vector transpose + * + * The outer product of vector v and vector transpose t yeilds + * dyadic matrix m. + */ +#define ACCUM_OUTER_PRODUCT_4X4(m,v,t) \ +{ \ + m[0][0] += v[0] * t[0]; \ + m[0][1] += v[0] * t[1]; \ + m[0][2] += v[0] * t[2]; \ + m[0][3] += v[0] * t[3]; \ + \ + m[1][0] += v[1] * t[0]; \ + m[1][1] += v[1] * t[1]; \ + m[1][2] += v[1] * t[2]; \ + m[1][3] += v[1] * t[3]; \ + \ + m[2][0] += v[2] * t[0]; \ + m[2][1] += v[2] * t[1]; \ + m[2][2] += v[2] * t[2]; \ + m[2][3] += v[2] * t[3]; \ + \ + m[3][0] += v[3] * t[0]; \ + m[3][1] += v[3] * t[1]; \ + m[3][2] += v[3] * t[2]; \ + m[3][3] += v[3] * t[3]; \ +}\ + + +/** determinant of matrix + * + * Computes determinant of matrix m, returning d + */ +#define DETERMINANT_2X2(d,m) \ +{ \ + d = m[0][0] * m[1][1] - m[0][1] * m[1][0]; \ +}\ + + +/** determinant of matrix + * + * Computes determinant of matrix m, returning d + */ +#define DETERMINANT_3X3(d,m) \ +{ \ + d = m[0][0] * (m[1][1]*m[2][2] - m[1][2] * m[2][1]); \ + d -= m[0][1] * (m[1][0]*m[2][2] - m[1][2] * m[2][0]); \ + d += m[0][2] * (m[1][0]*m[2][1] - m[1][1] * m[2][0]); \ +}\ + + +/** i,j,th cofactor of a 4x4 matrix + * + */ +#define COFACTOR_4X4_IJ(fac,m,i,j) \ +{ \ + int __ii[4], __jj[4], __k; \ + \ + for (__k=0; __k (aabb2).maxX ||\ + (aabb1).maxX < (aabb2).minX ||\ + (aabb1).minY > (aabb2).maxY ||\ + (aabb1).maxY < (aabb2).minY ||\ + (aabb1).minZ > (aabb2).maxZ ||\ + (aabb1).maxZ < (aabb2).minZ )\ + {\ + intersected = 0;\ + }\ +}\ + +#define AXIS_INTERSECT(min,max, a, d,tfirst, tlast,is_intersected) {\ + if(IS_ZERO(d))\ + {\ + is_intersected = !(a < min || a > max);\ + }\ + else\ + {\ + GREAL a0, a1;\ + a0 = (min - a) / (d);\ + a1 = (max - a) / (d);\ + if(a0 > a1) SWAP_NUMBERS(a0, a1);\ + tfirst = MAX(a0, tfirst);\ + tlast = MIN(a1, tlast);\ + if (tlast < tfirst)\ + {\ + is_intersected = 0;\ + }\ + else\ + {\ + is_intersected = 1;\ + }\ + }\ +}\ + +/*! \brief Finds the Ray intersection parameter. + +\param aabb Aligned box +\param vorigin A vec3f with the origin of the ray +\param vdir A vec3f with the direction of the ray +\param tparam Output parameter +\param tmax Max lenght of the ray +\param is_intersected 1 if the ray collides the box, else false + +*/ +#define BOX_INTERSECTS_RAY(aabb, vorigin, vdir, tparam, tmax,is_intersected) { \ + GREAL _tfirst = 0.0f, _tlast = tmax;\ + AXIS_INTERSECT(aabb.minX,aabb.maxX,vorigin[0], vdir[0], _tfirst, _tlast,is_intersected);\ + if(is_intersected)\ + {\ + AXIS_INTERSECT(aabb.minY,aabb.maxY,vorigin[1], vdir[1], _tfirst, _tlast,is_intersected);\ + }\ + if(is_intersected)\ + {\ + AXIS_INTERSECT(aabb.minZ,aabb.maxZ,vorigin[2], vdir[2], _tfirst, _tlast,is_intersected);\ + }\ + tparam = _tfirst;\ +}\ + +#define AABB_PROJECTION_INTERVAL(aabb,direction, vmin, vmax)\ +{\ + GREAL _center[] = {(aabb.minX + aabb.maxX)*0.5f, (aabb.minY + aabb.maxY)*0.5f, (aabb.minZ + aabb.maxZ)*0.5f};\ + \ + GREAL _extend[] = {aabb.maxX-_center[0],aabb.maxY-_center[1],aabb.maxZ-_center[2]};\ + GREAL _fOrigin = VEC_DOT(direction,_center);\ + GREAL _fMaximumExtent = _extend[0]*fabsf(direction[0]) + \ + _extend[1]*fabsf(direction[1]) + \ + _extend[2]*fabsf(direction[2]); \ +\ + vmin = _fOrigin - _fMaximumExtent; \ + vmax = _fOrigin + _fMaximumExtent; \ +}\ + +/*! +classify values: +
    +
  1. 0 : In back of plane +
  2. 1 : Spanning +
  3. 2 : In front of +
+*/ +#define PLANE_CLASSIFY_BOX(plane,aabb,classify)\ +{\ + GREAL _fmin,_fmax; \ + AABB_PROJECTION_INTERVAL(aabb,plane, _fmin, _fmax); \ + if(plane[3] >= _fmax) \ + { \ + classify = 0;/*In back of*/ \ + } \ + else \ + { \ + if(plane[3]+0.000001f>=_fmin) \ + { \ + classify = 1;/*Spanning*/ \ + } \ + else \ + { \ + classify = 2;/*In front of*/ \ + } \ + } \ +}\ +//! @} + +/*! \defgroup GEOMETRIC_OPERATIONS +*/ +//! @{ + + +#define PLANEDIREPSILON 0.0000001f +#define PARALELENORMALS 0.000001f + +#define TRIANGLE_NORMAL(v1,v2,v3,n){\ + vec3f _dif1,_dif2; \ + VEC_DIFF(_dif1,v2,v1); \ + VEC_DIFF(_dif2,v3,v1); \ + VEC_CROSS(n,_dif1,_dif2); \ + VEC_NORMALIZE(n); \ +}\ + +/// plane is a vec4f +#define TRIANGLE_PLANE(v1,v2,v3,plane) {\ + TRIANGLE_NORMAL(v1,v2,v3,plane);\ + plane[3] = VEC_DOT(v1,plane);\ +}\ + +/// Calc a plane from an edge an a normal. plane is a vec4f +#define EDGE_PLANE(e1,e2,n,plane) {\ + vec3f _dif; \ + VEC_DIFF(_dif,e2,e1); \ + VEC_CROSS(plane,_dif,n); \ + VEC_NORMALIZE(plane); \ + plane[3] = VEC_DOT(e1,plane);\ +}\ + +#define DISTANCE_PLANE_POINT(plane,point) (VEC_DOT(plane,point) - plane[3]) + +#define PROJECT_POINT_PLANE(point,plane,projected) {\ + GREAL _dis;\ + _dis = DISTANCE_PLANE_POINT(plane,point);\ + VEC_SCALE(projected,-_dis,plane);\ + VEC_SUM(projected,projected,point); \ +}\ + +#define POINT_IN_HULL(point,planes,plane_count,outside)\ +{\ + GREAL _dis;\ + outside = 0;\ + GUINT32 _i = 0;\ + do\ + {\ + _dis = DISTANCE_PLANE_POINT(planes[_i],point);\ + if(_dis>0.0f) outside = 1;\ + _i++;\ + }while(_i +
  • 0 : Segment in front of plane, s1 closest +
  • 1 : Segment in front of plane, s2 closest +
  • 2 : Segment in back of plane, s1 closest +
  • 3 : Segment in back of plane, s2 closest +
  • 4 : Segment collides plane, s1 in back +
  • 5 : Segment collides plane, s2 in back + +*/ +#define PLANE_CLIP_SEGMENT2(s1,s2,plane,clipped,intersection_type) \ +{\ + GREAL _dis1,_dis2;\ + _dis1 = DISTANCE_PLANE_POINT(plane,s1);\ + _dis2 = DISTANCE_PLANE_POINT(plane,s2);\ + if(_dis1 >-G_EPSILON && _dis2 >-G_EPSILON)\ + {\ + if(_dis1<_dis2) intersection_type = 0;\ + else intersection_type = 1;\ + }\ + else if(_dis1 _dis2) intersection_type = 2;\ + else intersection_type = 3; \ + }\ + else\ + {\ + if(_dis1<_dis2) intersection_type = 4;\ + else intersection_type = 5;\ + VEC_DIFF(clipped,s2,s1);\ + _dis2 = VEC_DOT(clipped,plane);\ + VEC_SCALE(clipped,-_dis1/_dis2,clipped);\ + VEC_SUM(clipped,clipped,s1); \ + }\ +}\ + +//! Confirms if the plane intersect the edge or not +/*! +clipped1 and clipped2 are the vertices behind the plane. +clipped1 is the closest + +intersection_type must have the following values +
      +
    • 0 : Segment in front of plane, s1 closest +
    • 1 : Segment in front of plane, s2 closest +
    • 2 : Segment in back of plane, s1 closest +
    • 3 : Segment in back of plane, s2 closest +
    • 4 : Segment collides plane, s1 in back +
    • 5 : Segment collides plane, s2 in back +
    +*/ +#define PLANE_CLIP_SEGMENT_CLOSEST(s1,s2,plane,clipped1,clipped2,intersection_type)\ +{\ + PLANE_CLIP_SEGMENT2(s1,s2,plane,clipped1,intersection_type);\ + if(intersection_type == 0)\ + {\ + VEC_COPY(clipped1,s1);\ + VEC_COPY(clipped2,s2);\ + }\ + else if(intersection_type == 1)\ + {\ + VEC_COPY(clipped1,s2);\ + VEC_COPY(clipped2,s1);\ + }\ + else if(intersection_type == 2)\ + {\ + VEC_COPY(clipped1,s1);\ + VEC_COPY(clipped2,s2);\ + }\ + else if(intersection_type == 3)\ + {\ + VEC_COPY(clipped1,s2);\ + VEC_COPY(clipped2,s1);\ + }\ + else if(intersection_type == 4)\ + { \ + VEC_COPY(clipped2,s1);\ + }\ + else if(intersection_type == 5)\ + { \ + VEC_COPY(clipped2,s2);\ + }\ +}\ + + +//! Finds the 2 smallest cartesian coordinates of a plane normal +#define PLANE_MINOR_AXES(plane, i0, i1)\ +{\ + GREAL A[] = {fabs(plane[0]),fabs(plane[1]),fabs(plane[2])};\ + if(A[0]>A[1])\ + {\ + if(A[0]>A[2])\ + {\ + i0=1; /* A[0] is greatest */ \ + i1=2;\ + }\ + else \ + {\ + i0=0; /* A[2] is greatest */ \ + i1=1; \ + }\ + }\ + else /* A[0]<=A[1] */ \ + {\ + if(A[2]>A[1]) \ + { \ + i0=0; /* A[2] is greatest */ \ + i1=1; \ + }\ + else \ + {\ + i0=0; /* A[1] is greatest */ \ + i1=2; \ + }\ + } \ +}\ + +//! Ray plane collision +#define RAY_PLANE_COLLISION(plane,vDir,vPoint,pout,tparam,does_intersect)\ +{\ + GREAL _dis,_dotdir; \ + _dotdir = VEC_DOT(plane,vDir);\ + if(_dotdir1.0f)\ + {\ + VEC_COPY(cp,e2);\ + }\ + else \ + {\ + VEC_SCALE(cp,_scalar,_n);\ + VEC_SUM(cp,cp,e1);\ + } \ +}\ + + +/*! \brief Finds the line params where these lines intersect. + +\param dir1 Direction of line 1 +\param point1 Point of line 1 +\param dir2 Direction of line 2 +\param point2 Point of line 2 +\param t1 Result Parameter for line 1 +\param t2 Result Parameter for line 2 +\param dointersect 0 if the lines won't intersect, else 1 + +*/ +#define LINE_INTERSECTION_PARAMS(dir1,point1, dir2, point2,t1,t2,dointersect) {\ + GREAL det;\ + GREAL e1e1 = VEC_DOT(dir1,dir1);\ + GREAL e1e2 = VEC_DOT(dir1,dir2);\ + GREAL e2e2 = VEC_DOT(dir2,dir2);\ + vec3f p1p2;\ + VEC_DIFF(p1p2,point1,point2);\ + GREAL p1p2e1 = VEC_DOT(p1p2,dir1);\ + GREAL p1p2e2 = VEC_DOT(p1p2,dir2);\ + det = e1e2*e1e2 - e1e1*e2e2;\ + if(IS_ZERO(det))\ + {\ + dointersect = 0;\ + }\ + else\ + {\ + t1 = (e1e2*p1p2e2 - e2e2*p1p2e1)/det;\ + t2 = (e1e1*p1p2e2 - e1e2*p1p2e1)/det;\ + dointersect = 1;\ + }\ +}\ + +//! Find closest points on segments +#define SEGMENT_COLLISION(vA1,vA2,vB1,vB2,vPointA,vPointB)\ +{\ + vec3f _AD,_BD,_N;\ + vec4f _M;\ + VEC_DIFF(_AD,vA2,vA1);\ + VEC_DIFF(_BD,vB2,vB1);\ + VEC_CROSS(_N,_AD,_BD);\ + VEC_CROSS(_M,_N,_BD);\ + _M[3] = VEC_DOT(_M,vB1);\ + float _tp; \ + LINE_PLANE_COLLISION(_M,_AD,vA1,vPointA,_tp,0.0f, 1.0f);\ + /*Closest point on segment*/ \ + VEC_DIFF(vPointB,vPointA,vB1);\ + _tp = VEC_DOT(vPointB, _BD); \ + _tp/= VEC_DOT(_BD, _BD); \ + _tp = CLAMP(_tp,0.0f,1.0f); \ + VEC_SCALE(vPointB,_tp,_BD);\ + VEC_SUM(vPointB,vPointB,vB1);\ +}\ + +//! @} + +///Additional Headers for Collision +#include "GIMPACT/gim_tri_collision.h" +#include "GIMPACT/gim_tri_sphere_collision.h" +#include "GIMPACT/gim_tri_capsule_collision.h" + +#endif // GIM_VECTOR_H_INCLUDED diff --git a/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_math.h b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_math.h new file mode 100644 index 0000000..97fdad2 --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_math.h @@ -0,0 +1,164 @@ +#ifndef GIM_MATH_H_INCLUDED +#define GIM_MATH_H_INCLUDED + +/*! \file gim_math.h +\author Francisco León +*/ +/* +----------------------------------------------------------------------------- +This source file is part of GIMPACT Library. + +For the latest info, see http://gimpact.sourceforge.net/ + +Copyright (c) 2006 Francisco Leon. C.C. 80087371. +email: projectileman@yahoo.com + + This library is free software; you can redistribute it and/or + modify it under the terms of EITHER: + (1) The GNU Lesser General Public License as published by the Free + Software Foundation; either version 2.1 of the License, or (at + your option) any later version. The text of the GNU Lesser + General Public License is included with this library in the + file GIMPACT-LICENSE-LGPL.TXT. + (2) The BSD-style license that is included with this library in + the file GIMPACT-LICENSE-BSD.TXT. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files + GIMPACT-LICENSE-LGPL.TXT and GIMPACT-LICENSE-BSD.TXT for more details. + +----------------------------------------------------------------------------- +*/ + +#include "config.h" + +#include +#include +#if HAVE_SYS_TYPES_H +#include +#elif defined(_MSC_VER) +typedef __int32 int32_t; +typedef unsigned __int32 uint32_t; +#elif defined(__GNUC__) +#include +#else +#error "GIMPACT: Must define int32_t and uint32_t" +#endif + + +/*! \defgroup BASIC_TYPES +Basic types and constants +Conventions: +Types starting with G +Constants starting with G_ +*/ +//! @{ +/*! Types */ +#define GREAL float +#define GINT32 int32_t +#define GUINT32 uint32_t + +#ifdef GPTR +#undef GPTR +#endif +#define GPTR void* + +/*! Constants for integers*/ +#define GUINT32_BIT_COUNT 32 +#define GUINT32_EXPONENT 5 + +#define G_FASTMATH 1 +#define G_PI 3.14159265358979f +#define G_HALF_PI 1.5707963f +//267948966 +#define G_TWO_PI 6.28318530f +//71795864 +#define G_ROOT3 1.73205f +#define G_ROOT2 1.41421f +#define G_UINT_INFINITY 65534 +#define G_REAL_INFINITY FLT_MAX +#define G_SIGN_BITMASK 0x80000000 +#define G_USE_EPSILON_TEST +#define G_EPSILON 0.0000001f +//! @} + +/*! \defgroup MATH_FUNCTIONS +mathematical functions +*/ +//! @{ +#define G_DEGTORAD(X) ((X)*3.1415926f/180.0f) +#define G_RADTODEG(X) ((X)*180.0f/3.1415926f) + +//! Integer representation of a floating-point value. +#define IR(x) ((GUINT32&)(x)) + +//! Signed integer representation of a floating-point value. +#define SIR(x) ((GINT32&)(x)) + +//! Absolute integer representation of a floating-point value +#define AIR(x) (IR(x)&0x7fffffff) + +//! Floating-point representation of an integer value. +#define FR(x) ((GREAL&)(x)) + +#define MAX(a,b) ((a)<(b)?(b):(a)) +#define MIN(a,b) ((a)>(b)?(b):(a)) + +#define MAX3(a,b,c) MAX(a,MAX(b,c)) +#define MIN3(a,b,c) MIN(a,MIN(b,c)) + +#define IS_ZERO(value) ((value) < G_EPSILON && (value) > -G_EPSILON) + +#define IS_NEGATIVE(value) ((value) <= -G_EPSILON) + +#define IS_POSISITVE(value) ((value) >= G_EPSILON) + +///returns a clamped number +#define CLAMP(number,minval,maxval) ((number)<(minval)?(minval):((number)>(maxval)?(maxval):(number))) + +///Swap numbers +#define SWAP_NUMBERS(a,b){ \ + (a) = (a)+(b); \ + (b) = (a)-(b); \ + (a) = (a)-(b); \ +}\ + +#define GIM_INV_SQRT(va,isva)\ +{\ + if((va)<=0.0000001f)\ + {\ + (isva) = G_REAL_INFINITY;\ + }\ + else\ + {\ + GREAL _x = (va) * 0.5f;\ + GUINT32 _y = 0x5f3759df - ( IR(va) >> 1);\ + (isva) = FR(_y);\ + (isva) = (isva) * ( 1.5f - ( _x * (isva) * (isva) ) );\ + }\ +}\ + +#define GIM_SQRT(va,sva)\ +{\ + GIM_INV_SQRT(va,sva);\ + (sva) = 1.0f/(sva);\ +}\ + +//! Computes 1.0f / sqrtf(x). Comes from Quake3. See http://www.magic-software.com/3DGEDInvSqrt.html +GREAL gim_inv_sqrt(GREAL f); + +//! Computes sqrtf(x) faster. +/*! +\sa gim_inv_sqrt +*/ +GREAL gim_sqrt(GREAL f); + +//!Initializes mathematical functions +void gim_init_math(); + +//! Generates an unit random +GREAL gim_unit_random(); +//! @} + +#endif // GIM_MATH_H_INCLUDED diff --git a/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_memory.h b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_memory.h new file mode 100644 index 0000000..d007bda --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_memory.h @@ -0,0 +1,1056 @@ +#ifndef GIM_MEMORY_H_INCLUDED +#define GIM_MEMORY_H_INCLUDED +/*! \file gim_memory.h +\author Francisco León +*/ +/* +----------------------------------------------------------------------------- +This source file is part of GIMPACT Library. + +For the latest info, see http://gimpact.sourceforge.net/ + +Copyright (c) 2006 Francisco Leon. C.C. 80087371. +email: projectileman@yahoo.com + + This library is free software; you can redistribute it and/or + modify it under the terms of EITHER: + (1) The GNU Lesser General Public License as published by the Free + Software Foundation; either version 2.1 of the License, or (at + your option) any later version. The text of the GNU Lesser + General Public License is included with this library in the + file GIMPACT-LICENSE-LGPL.TXT. + (2) The BSD-style license that is included with this library in + the file GIMPACT-LICENSE-BSD.TXT. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files + GIMPACT-LICENSE-LGPL.TXT and GIMPACT-LICENSE-BSD.TXT for more details. + +----------------------------------------------------------------------------- +*/ + + +#include "GIMPACT/gim_math.h" +#include + +//#define PREFETCH 1 +//! \defgroup PREFETCH +//! @{ +#ifdef PREFETCH +#include // for prefetch +#define pfval 64 +#define pfval2 128 +//! Prefetch 64 +#define pf(_x,_i) _mm_prefetch((void *)(_x + _i + pfval), 0) +//! Prefetch 128 +#define pf2(_x,_i) _mm_prefetch((void *)(_x + _i + pfval2), 0) +#else +//! Prefetch 64 +#define pf(_x,_i) +//! Prefetch 128 +#define pf2(_x,_i) +#endif +//! @} + +/*! \defgroup ARRAY_UTILITIES +\brief +Functions for manip packed arrays of numbers +*/ +//! @{ +#define GIM_COPY_ARRAYS(dest_array, source_array, element_count)\ +{\ + GUINT32 _i_;\ + for (_i_ = 0; _i_ < (element_count); _i_++)\ + {\ + (dest_array)[_i_] = (source_array)[_i_];\ + }\ +}\ + +#define GIM_COPY_ARRAYS_1(dest_array, source_array, element_count, copy_macro)\ +{\ + GUINT32 _i_;\ + for (_i_=0; _i_ < (element_count); _i_++)\ + {\ + copy_macro((dest_array)[_i_], (source_array)[_i_]);\ + }\ +}\ + + +#define GIM_ZERO_ARRAY(array, element_count)\ +{\ + GUINT32 _i_;\ + for (_i_=0; _i_ < (element_count); _i_++)\ + {\ + (array)[_i_] = 0;\ + }\ +}\ + +#define GIM_CONSTANT_ARRAY(array, element_count, constant)\ +{\ + GUINT32 _i_;\ + for (_i_ = 0; _i_ < (element_count); _i_++)\ + {\ + (array)[_i_] = (constant);\ + }\ +}\ +//! @} + +/*! \defgroup MEMORY_FUNCTION_PROTOTYPES +Function prototypes to allocate and free memory. +*/ +//! @{ +typedef void * gim_alloc_function (size_t size); +typedef void * gim_alloca_function (size_t size);//Allocs on the heap +typedef void * gim_realloc_function (void *ptr, size_t oldsize, size_t newsize); +typedef void gim_free_function (void *ptr, size_t size); +//! @} + +/*! \defgroup MEMORY_FUNCTION_HANDLERS +\brief +Memory Function Handlers + set new memory management functions. if fn is 0, the default handlers are + used. */ +//! @{ +void gim_set_alloc_handler (gim_alloc_function *fn); +// void gim_set_alloca_handler (gim_alloca_function *fn); -- a nonsense +void gim_set_realloc_handler (gim_realloc_function *fn); +void gim_set_free_handler (gim_free_function *fn); +//! @} + +/*! \defgroup MEMORY_FUNCTION_GET_HANDLERS +\brief +get current memory management functions. +*/ +//! @{ +gim_alloc_function *gim_get_alloc_handler (void); +// gim_alloca_function *gim_get_alloca_handler(void); -- a nonsense +gim_realloc_function *gim_get_realloc_handler (void); +gim_free_function *gim_get_free_handler (void); +//! @} + +/*! \defgroup MEMORY_FUNCTIONS +Standar Memory functions +*/ +//! @{ +void * gim_alloc(size_t size); +// void * gim_alloca(size_t size); -- a nonsense +void * gim_realloc(void *ptr, size_t oldsize, size_t newsize); +void gim_free(void *ptr, size_t size); +//! @} + +/*! \defgroup DYNAMIC_ARRAYS +\brief +Dynamic Arrays. Allocated from system memory. +
      +
    • For initializes a dynamic array, use GIM_DYNARRAY_CREATE or GIM_DYNARRAY_CREATE_SIZED. +
    • When an array is no longer used, must be terminated with the macro GIM_DYNARRAY_DESTROY. +
    +*/ +//! @{ +#define G_ARRAY_GROW_SIZE 64 +#define G_ARRAY_BUFFERMANAGER_INIT_SIZE 2 + +//! Dynamic array handle. +struct GDYNAMIC_ARRAY +{ + char * m_pdata; + GUINT32 m_size; + GUINT32 m_reserve_size; +}; +//typedef struct _GDYNAMIC_ARRAY GDYNAMIC_ARRAY; + +//! Creates a dynamic array zero sized +#define GIM_DYNARRAY_CREATE(type, array_data, reserve_size) \ +{ \ + (array_data).m_pdata = (char *)gim_alloc((reserve_size) * sizeof(type)); \ + (array_data).m_size = 0; \ + (array_data).m_reserve_size = (reserve_size); \ +} \ + +//! Creates a dynamic array with n = size elements +#define GIM_DYNARRAY_CREATE_SIZED(type, array_data, size) \ +{ \ + (array_data).m_pdata = (char *)gim_alloc((size) * sizeof(type)); \ + (array_data).m_size = (size); \ + (array_data).m_reserve_size = (size); \ +} \ + +//! Reserves memory for a dynamic array. +#define GIM_DYNARRAY_RESERVE_SIZE(type, array_data, old_size, reserve_size) \ +{ \ + if ((reserve_size) > (array_data).m_reserve_size) \ + { \ + (array_data).m_pdata = (char *) gim_realloc((array_data).m_pdata, (old_size) * sizeof(type), (reserve_size) * sizeof(type)); \ + (array_data).m_reserve_size = (reserve_size); \ + } \ +} \ + +//! Set the size of the array +#define GIM_DYNARRAY_SET_SIZE(type, array_data, size) \ +{ \ + GIM_DYNARRAY_RESERVE_SIZE(type, array_data, (array_data).m_size, size); \ + (array_data).m_size = size; \ +} \ + +//! Gets a pointer from the beginning of the array +#define GIM_DYNARRAY_POINTER(type, array_data) ((type *)((array_data).m_pdata)) + +//! Gets a pointer from the last elemento of the array +#define GIM_DYNARRAY_POINTER_LAST(type, array_data) (((type *)(array_data).m_pdata) + ((array_data).m_size - 1)) + +//! Inserts an element at the last position +#define GIM_DYNARRAY_PUSH_ITEM(type, array_data, item)\ +{ \ + if ((array_data).m_reserve_size <= (array_data).m_size)\ + {\ + GIM_DYNARRAY_RESERVE_SIZE(type, array_data, (array_data).m_size, (array_data).m_size + G_ARRAY_GROW_SIZE); \ + }\ + type * _pt = GIM_DYNARRAY_POINTER(type, array_data); \ + memcpy(&_pt[(array_data).m_size], &(item), sizeof(type)); \ + (array_data).m_size++; \ +} \ + +//! Inserts an element at the last position +#define GIM_DYNARRAY_PUSH_EMPTY(type, array_data) \ +{ \ + if ((array_data).m_reserve_size <= (array_data).m_size) \ + { \ + GIM_DYNARRAY_RESERVE_SIZE(type, array_data, (array_data).m_size, (array_data).m_size + G_ARRAY_GROW_SIZE); \ + } \ + (array_data).m_size++; \ +} \ + +//! Inserts an element +#define GIM_DYNARRAY_INSERT_ITEM(type, array_data, item, index) \ +{ \ + if ((array_data).m_reserve_size <= (array_data).m_size) \ + { \ + GIM_DYNARRAY_RESERVE_SIZE(type, array_data, (array_data).m_size, (array_data).m_size + G_ARRAY_GROW_SIZE); \ + } \ + type * _pt = GIM_DYNARRAY_POINTER(type, array_data); \ + if ((index) < (array_data).m_size - 1) \ + { \ + memmove(&_pt[(index) + 1], &_pt[(index)], ((array_data).m_size - (index)) * sizeof(type)); \ + } \ + memcpy(&_pt[(index)], &(item), sizeof(type)); \ + array_data.m_size++; \ +} \ + +//! Removes an element +#define GIM_DYNARRAY_DELETE_ITEM(type, array_data, index) \ +{ \ + if ((index) < (array_data).m_size - 1) \ + { \ + type * _pt = GIM_DYNARRAY_POINTER(type, array_data);\ + memmove(&_pt[(index)], &_pt[(index) + 1], ((array_data).m_size - (index) - 1) * sizeof(type)); \ + } \ + (array_data).m_size--; \ +} \ + +//! Removes an element at the last position +#define GIM_DYNARRAY_POP_ITEM(array_data) \ +{ \ + if ((array_data).m_size > 0) \ + { \ + (array_data).m_size--; \ + } \ +}\ + +//! Destroys the array +void GIM_DYNARRAY_DESTROY(GDYNAMIC_ARRAY & array_data); +//! @} + +/*! \defgroup BITSET +\brief +Bitsets , based on \ref DYNAMIC_ARRAYS . +
      +
    • For initializes a bitset array, use \ref GIM_BITSET_CREATE or \ref GIM_BITSET_CREATE_SIZED. +
    • When the bitset is no longer used, must be terminated with the macro \ref GIM_DYNARRAY_DESTROY. +
    • For putting a mark on the bitset, call \ref GIM_BITSET_SET +
    • For clearing a mark on the bitset, call \ref GIM_BITSET_CLEAR +
    • For retrieving a bit value from a bitset, call \ref GIM_BITSET_GET- +
    +*/ +//! @{ + +//! Creates a bitset +#define GIM_BITSET_CREATE(array_data) GIM_DYNARRAY_CREATE(GUINT32, array_data, G_ARRAY_GROW_SIZE) + +//! Creates a bitset, with their bits set to 0. +#define GIM_BITSET_CREATE_SIZED(array_data, bits_count) \ +{ \ + GUINT32 array_size = (bits_count) / GUINT32_BIT_COUNT + 1; \ + GIM_DYNARRAY_CREATE(GUINT32, array_data, array_size); \ + GUINT32 * _pt = GIM_DYNARRAY_POINTER(GUINT32, array_data); \ + memset(_pt, 0, sizeof(GUINT32) * ((array_data).m_size)); \ +} \ + +//! Gets the bitset bit count. +#define GIM_BITSET_SIZE(array_data) ((array_data).m_size * GUINT32_BIT_COUNT) + +//! Resizes a bitset, with their bits set to 0. +#define GIM_BITSET_RESIZE(array_data, new_bits_count) \ +{ \ + GUINT32 _oldsize = (array_data).m_size; \ + (array_data).m_size = (new_bits_count) / GUINT32_BIT_COUNT + 1; \ + if (_oldsize < (array_data).m_size) \ + { \ + if ((array_data).m_size > (array_data).m_reserve_size) \ + { \ + GIM_DYNARRAY_RESERVE_SIZE(GUINT32, array_data, _oldsize, (array_data).m_size + G_ARRAY_GROW_SIZE); \ + } \ + GUINT32 * _pt = GIM_DYNARRAY_POINTER(GUINT32, array_data); \ + memset(&_pt[_oldsize], 0, sizeof(GUINT32) * ((array_data).m_size - _oldsize)); \ + } \ +} \ + +//! Sets all bitset bit to 0. +#define GIM_BITSET_CLEAR_ALL(array_data) \ +{ \ + memset((array_data).m_pdata, 0, sizeof(GUINT32) * (array_data).m_size); \ +} \ + +//! Sets all bitset bit to 1. +#define GIM_BITSET_SET_ALL(array_data) \ +{ \ + memset((array_data).m_pdata, 0xFF, sizeof(GUINT32) * (array_data).m_size); \ +} \ + +///Sets the desired bit to 1 +#define GIM_BITSET_SET(array_data, bit_index) \ +{ \ + if ((bit_index) >= GIM_BITSET_SIZE(array_data)) \ + { \ + GIM_BITSET_RESIZE(array_data, bit_index); \ + } \ + GUINT32 * _pt = GIM_DYNARRAY_POINTER(GUINT32, array_data); \ + _pt[(bit_index) >> GUINT32_EXPONENT] |= (1 << ((bit_index) & (GUINT32_BIT_COUNT - 1))); \ +} \ + +///Return 0 or 1 +#define GIM_BITSET_GET(array_data, bit_index, get_value) \ +{ \ + if ((bit_index) >= GIM_BITSET_SIZE(array_data)) \ + { \ + (get_value) = 0; \ + } \ + else \ + { \ + GUINT32 * _pt = GIM_DYNARRAY_POINTER(GUINT32, array_data); \ + (get_value) = _pt[(bit_index) >> GUINT32_EXPONENT] & (1 << ((bit_index) & (GUINT32_BIT_COUNT - 1))); \ + } \ +} \ + +///Sets the desired bit to 0 +#define GIM_BITSET_CLEAR(array_data, bit_index) \ +{ \ + if ((bit_index) < GIM_BITSET_SIZE(array_data)) \ + { \ + GUINT32 * _pt = GIM_DYNARRAY_POINTER(GUINT32, array_data); \ + _pt[(bit_index) >> GUINT32_EXPONENT] &= ~(1 << ((bit_index) & (GUINT32_BIT_COUNT - 1))); \ + } \ +} \ +//! @} + +/*! \defgroup MEMORY_ACCESS_CONSTANTS +\brief +Memory Access constants. +\sa BUFFERS +*/ +//! @{ +#define G_MA_READ_ONLY 1 +#define G_MA_WRITE_ONLY 2 +#define G_MA_READ_WRITE 3 +//! @} + +/*! \defgroup MEMORY_USAGE_CONSTANTS +\brief +Memory usage constants. +\sa BUFFERS +*/ +//! @{ +/// Don't care how memory is used +#define G_MU_EITHER 0 +/// specified once, doesn't allow read information +#define G_MU_STATIC_WRITE 1 +/// specified once, allows to read information from a shadow buffer +#define G_MU_STATIC_READ 2 +/// write directly on buffer, allows to read information from a shadow buffer +#define G_MU_STATIC_READ_DYNAMIC_WRITE 3 +/// upload data to buffer from the shadow buffer, allows to read information from a shadow buffer +#define G_MU_STATIC_READ_DYNAMIC_WRITE_COPY 4 +/// specified once, allows to read information directly from memory +#define G_MU_STATIC_WRITE_DYNAMIC_READ 5 +/// write directly on buffer, allows to read information directly from memory +#define G_MU_DYNAMIC_READ_WRITE 6 +//! @} + +/*! \defgroup BUFFER_ERRORS +\brief +Buffer operation errors +\sa BUFFERS +*/ +//! @{ +#define G_BUFFER_OP_SUCCESS 0 +#define G_BUFFER_OP_INVALID 1 +#define G_BUFFER_OP_STILLREFCOUNTED 2 +//! @} + +/*! \defgroup BUFFER_MANAGER_IDS +\brief +Buffer manager identifiers +\sa BUFFERS, BUFFER_MANAGERS +*/ +//! @{ +enum +{ + G_BUFFER_MANAGER_SYSTEM, + G_BUFFER_MANAGER_SHARED, + + G_BUFFER_MANAGER__MAX +}; +//! @} + +/*! \defgroup BUFFERS +\brief +Buffer operations and structs. +
      +
    • Before using buffers you must initializes GIMPACT buffer managers by calling \ref gimpact_init. +
    • For initializes a buffer, use \ref gim_create_buffer, \ref gim_create_buffer_from_data , \ref gim_create_common_buffer, \ref gim_create_common_buffer_from_data or \ref gim_create_shared_buffer_from_data. +
    • For accessing to the buffer memory, you must call \ref gim_lock_buffer, and then \ref gim_unlock_buffer for finish the access. +
    • When a buffer is no longer needed, you must free it by calling \ref gim_buffer_free. +
    • You must call \ref gimpact_terminate when finish your application. +
    • For a safe manipulation of buffers, use \ref BUFFER_ARRAYS +
    +\sa BUFFER_MANAGERS, BUFFER_ARRAYS +*/ +//! @{ + +struct GBUFFER_MANAGER_DATA; + +//! Buffer handle. +struct GBUFFER_ID +{ + GBUFFER_MANAGER_DATA * m_bm_data; + GUINT32 m_buffer_id; +}; +//typedef struct _GBUFFER_ID GBUFFER_ID; + +//! Buffer internal data +struct GBUFFER_DATA +{ + GPTR m_buffer_handle;//!< if 0, buffer doesn't exists + GUINT32 m_size; + GUINT32 m_usage; + GINT32 m_access; + GUINT32 m_lock_count; + char * m_mapped_pointer; + GBUFFER_ID m_shadow_buffer; + GUINT32 m_refcount;//! Reference counting for safe garbage collection +}; +//typedef struct _GBUFFER_DATA GBUFFER_DATA; +//! @} + +/*! \defgroup BUFFERS_MANAGER_PROTOTYPES +\brief +Function prototypes to allocate and free memory for buffers +\sa BUFFER_MANAGERS, BUFFERS +*/ +//! @{ + +//! Returns a Buffer handle +typedef GPTR gim_buffer_alloc_function(GUINT32 size,int usage); + +//! Returns a Buffer handle, and copies the pdata to the buffer +typedef GPTR gim_buffer_alloc_data_function(const void * pdata,GUINT32 size,int usage); + +//! Changes the size of the buffer preserving the content, and returns the new buffer id +typedef GPTR gim_buffer_realloc_function(GPTR buffer_handle,GUINT32 oldsize,int old_usage,GUINT32 newsize,int new_usage); + +//! It changes the m_buffer_handle member to 0/0 +typedef void gim_buffer_free_function(GPTR buffer_handle,GUINT32 size); + +//! It maps the m_mapped_pointer. Returns a pointer +typedef char * gim_lock_buffer_function(GPTR buffer_handle,int access); + +//! It sets the m_mapped_pointer to 0 +typedef void gim_unlock_buffer_function(GPTR buffer_handle); + +typedef void gim_download_from_buffer_function( + GPTR source_buffer_handle, + GUINT32 source_pos, + void * destdata, + GUINT32 copysize); + +typedef void gim_upload_to_buffer_function( + GPTR dest_buffer_handle, + GUINT32 dest_pos, + void * sourcedata, + GUINT32 copysize); + +typedef void gim_copy_buffers_function( + GPTR source_buffer_handle, + GUINT32 source_pos, + GPTR dest_buffer_handle, + GUINT32 dest_pos, + GUINT32 copysize); +//! @} + + +/*! \defgroup BUFFER_MANAGERS +\brief +Buffer Manager operations +*/ +//! @{ +//! Buffer manager prototype +struct GBUFFER_MANAGER_PROTOTYPE +{ + gim_buffer_alloc_function * alloc_fn; + gim_buffer_alloc_data_function *alloc_data_fn; + gim_buffer_realloc_function * realloc_fn; + gim_buffer_free_function * free_fn; + gim_lock_buffer_function * lock_buffer_fn; + gim_unlock_buffer_function * unlock_buffer_fn; + gim_download_from_buffer_function * download_from_buffer_fn; + gim_upload_to_buffer_function * upload_to_buffer_fn; + gim_copy_buffers_function * copy_buffers_fn; +}; +//typedef struct _GBUFFER_MANAGER_PROTOTYPE GBUFFER_MANAGER_PROTOTYPE; + +//! Buffer manager +struct GBUFFER_MANAGER_DATA +{ + GDYNAMIC_ARRAY m_buffer_array;//!< Array of GBUFFER_DATA objects + GDYNAMIC_ARRAY m_free_positions;//!< Array of GUINT elements. Free positions + const GBUFFER_MANAGER_PROTOTYPE *m_prototype;//!< Prototype of functions + GUINT32 m_buffer_manager_id;//!< Buffer manager id +}; +//typedef struct _GBUFFER_MANAGER_DATA GBUFFER_MANAGER_DATA; + +//! Checks if buffer manager is used +int gim_is_buffer_manager_active(GBUFFER_MANAGER_DATA buffer_managers[], + GUINT32 buffer_manager_id); +//! Adds a buffer Manager to the Memory Singleton +void gim_create_buffer_manager(GBUFFER_MANAGER_DATA buffer_managers[], + GUINT32 buffer_manager_id); +//! Destroys a buffer manager +void gim_destroy_buffer_manager(GBUFFER_MANAGER_DATA buffer_managers[], GUINT32 buffer_manager_id); +void gim_get_buffer_manager_data(GBUFFER_MANAGER_DATA buffer_managers[], + GUINT32 buffer_manager_id,GBUFFER_MANAGER_DATA ** pbm_data); +void gim_init_buffer_managers(GBUFFER_MANAGER_DATA buffer_managers[]); +void gim_terminate_buffer_managers(GBUFFER_MANAGER_DATA buffer_managers[]); + +//! @} + + +/*! \addtogroup BUFFERS +*/ +//! @{ + +//!Creates a buffer on the buffer manager specified by buffer_manager_id +/*! +\param buffer_manager_id +\param buffer_size +\param usage An usage constant. Use G_MU_DYNAMIC_READ_WRITE as default. +\param buffer_id a pointer for receive the new buffer id +\return An error code. 0 if success. +\post m_refcount = 0 +*/ +GUINT32 gim_create_buffer( + GBUFFER_MANAGER_DATA buffer_managers[], + GUINT32 buffer_manager_id, + GUINT32 buffer_size, + int usage, + GBUFFER_ID * buffer_id); + +//!Creates a buffer on the buffer manager specified by buffer_manager_id +/*! +\param buffer_manager_id +\param pdata Data for allocating +\param buffer_size Size of the data buffer +\param usage An usage constant. Use G_MU_DYNAMIC_READ_WRITE as default. +\param buffer_id a pointer for receive the new buffer id +\return An error code. 0 if success. +\post m_refcount = 0 +*/ +GUINT32 gim_create_buffer_from_data( + GBUFFER_MANAGER_DATA buffer_managers[], + GUINT32 buffer_manager_id, + const void * pdata, + GUINT32 buffer_size, + int usage, + GBUFFER_ID * buffer_id); + +//!Allocates on the G_BUFFER_MANAGER_SYSTEM +GUINT32 gim_create_common_buffer(GBUFFER_MANAGER_DATA buffer_managers[], + GUINT32 buffer_size, GBUFFER_ID * buffer_id); +//!Allocates on the G_BUFFER_MANAGER_SYSTEM, and copies the data +GUINT32 gim_create_common_buffer_from_data(GBUFFER_MANAGER_DATA buffer_managers[], + const void * pdata, GUINT32 buffer_size, GBUFFER_ID * buffer_id); +//!Creates a buffer with shared data +GUINT32 gim_create_shared_buffer_from_data(GBUFFER_MANAGER_DATA buffer_managers[], + const void * pdata, GUINT32 buffer_size, GBUFFER_ID * buffer_id); + + +//! Add reference counting to buffer. +GINT32 gim_buffer_add_ref(GBUFFER_ID * buffer_id); + +//! Function for resize buffer, preserving the content +/*! +\param buffer_id +\param newsize +\return An error code. 0 if success. +\post If m_refcount>0 then it decrements it. +*/ +GINT32 gim_buffer_realloc(GBUFFER_ID * buffer_id,GUINT32 newsize); + +//! Eliminates the buffer. +/*! +If the buffer reference counting is <= 1 and is unlocked, then it eliminates the buffer. +*/ +GINT32 gim_buffer_free(GBUFFER_ID * buffer_id); + +//! Locks the buffer for memory access. +/*! +\param buffer_id Id from buffer. +\param access Must have the following values: G_MA_READ_ONLY,G_MA_WRITE_ONLY or G_MA_READ_WRITE. +\param map_pointer Dest Pointer of the memory address from buffer. +\post m_lock_count increases. +*/ +GINT32 gim_lock_buffer(GBUFFER_ID * buffer_id,int access,char ** map_pointer); + +//! Unlocks the buffer for memory access. +GINT32 gim_unlock_buffer(GBUFFER_ID * buffer_id); + +//! Gets the buffer size in bytes +GINT32 gim_get_buffer_size(GBUFFER_ID * buffer_id,GUINT32 * buffer_size); + +//! Determines if the buffer is locked +GINT32 gim_get_buffer_is_locked(GBUFFER_ID * buffer_id,GUINT32 * lock_count); + +//! Copies the content of the buffer to a dest pointer +GINT32 gim_download_from_buffer( + GBUFFER_ID * buffer_id, + GUINT32 source_pos, + void * destdata, + GUINT32 copysize); + +//! Copies the content of a memory pointer to the buffer +GINT32 gim_upload_to_buffer( + GBUFFER_ID * buffer_id, + GUINT32 dest_pos, + void * sourcedata, + GUINT32 copysize); + +//! Copies two buffers. +GINT32 gim_copy_buffers( + GBUFFER_ID * source_buffer_id, + GUINT32 source_pos, + GBUFFER_ID * dest_buffer_id, + GUINT32 dest_pos, + GUINT32 copysize); +//! @} + + +/*! \defgroup BUFFER_ARRAYS + +\brief +Buffered Arrays, for manip elements on a buffer and treat it as an array. +
      +
    • Before using buffer arrays you must initializes GIMPACT buffer managers by calling gimpact_init. +
    • Before creating buffer arrays, you must create a buffer. see \ref BUFFERS. +
    • Create a buffer narray by calling \ref GIM_BUFFER_ARRAY_INIT_TYPE, \ref GIM_BUFFER_ARRAY_INIT_TYPE_OFFSET or \ref GIM_BUFFER_ARRAY_INIT_OFFSET_STRIDE. +
    • For accessing to the array elements, you must call \ref gim_buffer_array_lock, and then \ref gim_buffer_array_unlock for finish the access. +
    • When a buffer array is no longer needed, you must free it by calling \ref GIM_BUFFER_ARRAY_DESTROY. +
    +The following example shows how Buffer arrays can be used: + +\code +int main() +{ + //init gimpact + gimpact_init(); + + //Buffer handle to use + GBUFFER_ID bufferhandle; + + //Create a memory buffer of 100 float numbers + gim_create_common_buffer(100*sizeof(float), &bufferhandle); + + //Create a buffer array from the bufferhandle + GBUFFER_ARRAY buffer_float_array; + GIM_BUFFER_ARRAY_INIT_TYPE(float,buffer_float_array,bufferhandle,100); + + ////Access to the buffer data, set all elements of the array + + int i, count; + count = buffer_float_array.m_element_count; + //Locks the array + gim_buffer_array_lock(&buffer_float_array,G_MA_READ_WRITE); + float * pelements = GIM_BUFFER_ARRAY_POINTER(float, buffer_float_array, 0); // A pointer to the buffer memory + + //fill the array with random numbers + for (i = 0;i < count;i++ ) + { + pelements[i] = gim_unit_random(); + } + //unlock buffer + gim_buffer_array_unlock(&buffer_float_array); + + //Program code + .... + .... + + //Destroy array + GIM_BUFFER_ARRAY_DESTROY(buffer_float_array); + + //terminate gimpact + gimpact_terminate(); +} +\endcode + +\sa BUFFERS +*/ +//! @{ + +//! Buffer managed array struct. +struct GBUFFER_ARRAY +{ + GBUFFER_ID m_buffer_id; + char * m_buffer_data; + char m_byte_stride; + GUINT32 m_byte_offset; + GUINT32 m_element_count; +}; +//typedef struct _GBUFFER_ARRAY GBUFFER_ARRAY; + +//! Sets offset for a buffered array. +#define GIM_BUFFER_ARRAY_SET_OFFSET(_array_data,_offset) (_array_data).m_byte_offset = (_offset)*(_array_data).m_byte_stride; + +//! Sets offset for a buffered array. +#define GIM_BUFFER_ARRAY_GET_OFFSET(_array_data,_offset) (_offset) = (_array_data).m_byte_offset/(_array_data).m_byte_stride; + +//!Return a pointer of the element at the _index +#define GIM_BUFFER_ARRAY_POINTER(_type,_array_data,_index) (_type *)((_array_data).m_buffer_data + (_index)*(_array_data).m_byte_stride) + +//! Sets stride for a buffered array. +#define GIM_BUFFER_ARRAY_SET_STRIDE(_type,_array_data) (_array_data).m_byte_stride = sizeof(_type); + +//! Is array stride equal to the size of the type ? +#define GIM_BUFFER_ARRAY_IS_ALIGNED(_type,_array_data) ((_array_data).m_byte_stride == sizeof(_type)) + +///Verify if two arrays have the same data +#define GIM_BUFFER_ARRAY_ARE_SAME(_array_data1,_array_data2,aresame) \ +{ \ + (aresame) = 1; \ + if ((_array_data1).m_buffer_id.m_buffer_id != (_array_data2).m_buffer_id.m_buffer_id || (_array_data1).m_buffer_id.m_buffer_manager_id != (_array_data2).m_buffer_id.m_buffer_manager_id || (_array_data1).m_byte_offset != (_array_data2).m_byte_offset) \ + { \ + (aresame) = 0; \ + } \ +} \ + +//! Reserve size for a buffered array. +/*! +\pre array_data must be unlocked, and must be the aligned (GIM_BUFFER_ARRAY_IS_ALIGNED ) +*/ +#define GIM_BUFFER_ARRAY_RESERVE_SIZE(type, array_data, reserve_size) \ +{ \ + if ((reserve_size) > (array_data).m_element_count) \ + { \ + GUINT32 _buffer_size, _newarray_size; \ + gim_get_buffer_size(&(array_data).m_buffer_id, _buffer_size); \ + _newarray_size = (reserve_size) * (array_data).m_byte_stride; \ + if(_newarray_size > _buffer_size) \ + { \ + _newarray_size += G_ARRAY_GROW_SIZE * (array_data).m_byte_stride; \ + gim_buffer_realloc(&(array_data).m_buffer_id, _newarray_size); \ + } \ + } \ +} \ + +//! Pushes an element at last position +/*! +\pre array_data must be unlocked, and must be the aligned (GIM_BUFFER_ARRAY_IS_ALIGNED ) +*/ +#define GIM_BUFFER_ARRAY_PUSH_ITEM(type, array_data, item) \ +{ \ + GIM_BUFFER_ARRAY_RESERVE_SIZE(type, array_data, (array_data).m_element_count + 1); \ + gim_buffer_array_lock(&(array_data), G_MA_WRITE_ONLY); \ + type * _pt = GIM_BUFFER_ARRAY_POINTER(type, array_data, (array_data).m_element_count); \ + memcpy(_pt, &(item), sizeof(type)); \ + gim_buffer_array_unlock(&(array_data)); \ + (array_data)->m_element_count++; \ +} \ + +//! Pushes a new element at last position +/*! +\pre array_data must be unlocked, and must be the aligned (GIM_BUFFER_ARRAY_IS_ALIGNED ) +*/ +#define GIM_BUFFER_ARRAY_PUSH_EMPTY(type, array_data) \ +{\ + GIM_BUFFER_ARRAY_RESERVE_SIZE(type, array_data, (array_data).m_element_count + 1); \ + (array_data)->m_element_count++; \ +}\ + +//! Inserts an element +/*! +\pre array_data must be unlocked, and must be the aligned (GIM_BUFFER_ARRAY_IS_ALIGNED ) +*/ +#define GIM_BUFFER_ARRAY_INSERT_ITEM(type, array_data, item, index) \ +{ \ + GIM_BUFFER_ARRAY_RESERVE_SIZE(type, array_data, (array_data).m_element_count + 1); \ + gim_buffer_array_lock(&(array_data), G_MA_WRITE_ONLY); \ + type * _pt = GIM_BUFFER_ARRAY_POINTER(type, array_data, 0); \ + if ((index) < (array_data)->m_element_count - 1) \ + { \ + memmove(&_pt[(index) + 1], &_pt[(index)], ((array_data).m_element_count - (index)) * sizeof(type)); \ + } \ + memcpy(&_pt[(index)], &(item), sizeof(type)); \ + gim_buffer_array_unlock(&(array_data)); \ + (array_data).m_element_count++; \ +} \ + +//! Deletes an element +/*! +\pre array_data must be unlocked, and must be the aligned (GIM_BUFFER_ARRAY_IS_ALIGNED ) +*/ +#define GIM_BUFFER_ARRAY_DELETE_ITEM(type, array_data, index) \ +{ \ + if ((index) < (array_data).m_element_count - 1) \ + { \ + gim_buffer_array_lock(&(array_data), G_MA_WRITE_ONLY); \ + type * _pt = GIM_BUFFER_ARRAY_POINTER(type, array_data, 0); \ + memmove(&_pt[(index)], &_pt[(index) + 1],((array_data).m_element_count - (index) - 1) * sizeof(type)); \ + gim_buffer_array_unlock(&(array_data)); \ + } \ + (array_data).m_element_count--; \ +} \ + +//! Deletes an element at last position +/*! +\pre array_data must be unlocked, and must be the aligned (GIM_BUFFER_ARRAY_IS_ALIGNED ) +*/ +#define GIM_BUFFER_ARRAY_POP_ITEM(array_data) \ +{ \ + if ((array_data).m_element_count > 0) \ + { \ + (array_data).m_element_count--; \ + } \ +} \ + + +//! Initializes an GBUFFER_ARRAY object from a buffer ID +/*! +m_buffer_data will be 0, for acces to the elements, you'd need to call lock_array +\param array_data Array structure to be filled +\param buffer_id A GBUFFER_ID structure which this array_daya will refer to +\param element_count Number of elements +\param offset element offset, it isn't byte offset. 0 is recomended +\param byte_stride size of each element. 0 is recomended. +\post Adds reference to the buffer +\sa gim_buffer_add_ref +*/ +#define GIM_BUFFER_ARRAY_INIT_OFFSET_STRIDE(array_data, buffer_id, element_count, offset, byte_stride) \ +{ \ + (array_data).m_buffer_id.m_buffer_id = (buffer_id).m_buffer_id; \ + (array_data).m_buffer_id.m_buffer_manager_id = (buffer_id).m_buffer_manager_id; \ + (array_data).m_buffer_data = 0; \ + (array_data).m_element_count = (element_count); \ + (array_data).m_byte_stride = (byte_stride); \ + GIM_BUFFER_ARRAY_SET_OFFSET(array_data, offset); \ + gim_buffer_add_ref(&(buffer_id)); \ +} \ + +//! Initializes an GBUFFER_ARRAY object from a buffer ID and a Given type +/*! +m_buffer_data will be 0, for acces to the elements, you'd need to call lock_array +\param type Type of the Array. It determines the stride. +\param array_data Array structure to be filled +\param buffer_id A GBUFFER_ID structure which this array_daya will refer to +\param element_count Number of elements +\param offset element offset, it isn't byte offset. 0 is recomended +\post Adds reference to the buffer +\sa gim_buffer_add_ref +*/ +#define GIM_BUFFER_ARRAY_INIT_TYPE_OFFSET(type, array_data, buffer_id, element_count, offset) \ +{ \ + (array_data).m_buffer_id.m_buffer_id = (buffer_id).m_buffer_id; \ + (array_data).m_buffer_id.m_bm_data = (buffer_id).m_bm_data; \ + (array_data).m_buffer_data = 0; \ + (array_data).m_element_count = (element_count);\ + GIM_BUFFER_ARRAY_SET_STRIDE(type, array_data); \ + GIM_BUFFER_ARRAY_SET_OFFSET(array_data, offset); \ + gim_buffer_add_ref(&(buffer_id)); \ +}\ + +//! Initializes a buffer array giving a data type and a buffer id +/*! +m_buffer_data will be 0, for acces to the elements, you'd need to call lock_array. +\param type Type of the Array. It determines the stride. +\param array_data Array structure to be filled +\param buffer_id A GBUFFER_ID structure which this array_daya will refer to +\param element_count Number of elements +\post Adds reference to the buffer +\sa gim_buffer_add_ref +*/ +#define GIM_BUFFER_ARRAY_INIT_TYPE(type, array_data, buffer_id, element_count) GIM_BUFFER_ARRAY_INIT_TYPE_OFFSET(type, array_data, buffer_id, element_count, 0) + +//! Gain access to the array buffer through the m_buffer_data element +/*! +m_buffer_data pointer will be located at the m_byte_offset position of the buffer m_buffer +Then, You'd need to call unlock_array when finish to using the array access. + +\pre if m_buffer_data != 0, the function returns +\param array_data Array structure to be locked +\param access A constant for access to the buffer. can be G_MA_READ_ONLY,G_MA_WRITE_ONLY or G_MA_READ_WRITE +\return an Buffer error code +*/ +GINT32 gim_buffer_array_lock(GBUFFER_ARRAY * array_data, int access); + +//! close the access to the array buffer through the m_buffer_data element +/*! +\param array_data Array structure to be locked +\return an Buffer error code +*/ +GINT32 gim_buffer_array_unlock(GBUFFER_ARRAY * array_data); + +//! Copy an array by reference +/*! +\post A reference to the m_buffer_id is increased. +*/ +void gim_buffer_array_copy_ref(GBUFFER_ARRAY * source_data,GBUFFER_ARRAY * dest_data); + + +//! Copy an array by value +/*! +\post A new buffer is created +*/ +void gim_buffer_array_copy_value(GBUFFER_ARRAY * source_data, + GBUFFER_MANAGER_DATA dest_buffer_managers[],GBUFFER_ARRAY * dest_data, + GUINT32 buffer_manager_id,int usage); + +//! Destroys an GBUFFER_ARRAY object +/*! +\post Attemps to destroy the buffer, decreases reference counting +*/ +void GIM_BUFFER_ARRAY_DESTROY(GBUFFER_ARRAY & array_data); + +//! Copy the content of the array to a pointer +/*! +\pre dest_data must have the same size as the array_data +\param type +\param array_data A GBUFFERED_ARRAY structure +\param dest_data A type pointer +*/ +#define GIM_BUFFER_ARRAY_DOWNLOAD(type,array_data,dest_data) \ +{ \ + if (GIM_BUFFER_ARRAY_IS_ALIGNED(type, array_data)) \ + { \ + gim_download_from_buffer(&(array_data).m_buffer_id, (array_data).m_byte_offset, (void *)(dest_data), (array_data).m_element_count * (array_data).m_byte_stride); \ + } \ + else \ + { \ + GUINT32 _k_, _ecount_= (array_data).m_element_count; \ + type * _source_vert_; \ + type * _dest_vert_ = (dest_data); \ + gim_buffer_array_lock(&(array_data), G_MA_READ_ONLY); \ + for (_k_ = 0; _k_ < _ecount_; _k_++) \ + { \ + _source_vert_ = GIM_BUFFER_ARRAY_POINTER(type, array_data, _k_); \ + memcpy(_dest_vert_, _source_vert_, sizeof(type)); \ + _dest_vert_++; \ + } \ + gim_buffer_array_unlock(&(array_data)); \ + } \ +} \ + +//! Upload the content of a a pointer to a buffered array +/*! +\pre source_data must have the same size as the array_data +\param type +\param array_data A GBUFFERED_ARRAY structure +\param source_data A void pointer +*/ +#define GIM_BUFFER_ARRAY_UPLOAD(type, array_data, source_data) \ +{ \ + if (GIM_BUFFER_ARRAY_IS_ALIGNED(type, array_data)) \ + { \ + gim_upload_to_buffer(&(array_data).m_buffer_id, (array_data).m_byte_offset, (void *)(source_data), (array_data).m_element_count * (array_data).m_byte_stride); \ + } \ + else \ + { \ + GUINT32 _k_, _ecount_= (array_data).m_element_count; \ + type * _source_vert_ = (source_data); \ + type * _dest_vert_; \ + gim_buffer_array_lock(&(array_data), G_MA_WRITE_ONLY); \ + for (_k_ = 0; _k_ < _ecount_; _k_++) \ + { \ + _dest_vert_ = GIM_BUFFER_ARRAY_POINTER(type, array_data, _k_); \ + memcpy(_dest_vert_, _source_vert_, sizeof(type)); \ + _source_vert_++; \ + } \ + gim_buffer_array_unlock(&(array_data)); \ + } \ +} \ + + +//!Kernel function prototype for process streams, given a buffered array as source and +/*! +\param 1 the uniform arguments +\param 2 the source stream +\param 3 the destination stream +*/ +typedef void (* gim_kernel_func)(void *,GBUFFER_ARRAY *,GBUFFER_ARRAY *); + +//! Generic Stream Processingp loop +/*! + +This macro executes a kernel macro or function for each element of the streams +\pre _src_array->m_count <= _dst_array->m_count + +\param _uniform_data An argument to be passed to the Kernel function +\param _src_array An GBUFFER_ARRAY structure passed as the source stream +\param _dst_array An GBUFFER_ARRAY structure passed as the source stream +\param _kernel Macro or function of the kernel +\param _src_type Required. Type of all elements of the source stream +\param _dst_type Required. Type of all elements of the dest stream +*/ +#define GIM_PROCESS_BUFFER_ARRAY(_uniform_data, _src_array, _dst_array, _kernel, _src_type, _dst_type) \ +{ \ +\ + gim_buffer_array_lock(&(_src_array), G_MA_READ_ONLY); \ + gim_buffer_array_lock(&(_dst_array), G_MA_WRITE_ONLY); \ +\ + GUINT32 _i_, _count_=(_src_array).m_element_count; \ +\ + _src_type * _source_vert_; \ + _dst_type * _dest_vert_; \ + if (GIM_BUFFER_ARRAY_IS_ALIGNED(_src_type, _src_array) && GIM_BUFFER_ARRAY_IS_ALIGNED(_dst_type, _dst_array)) \ + { \ +\ + _source_vert_ = GIM_BUFFER_ARRAY_POINTER(_src_type, _src_array, 0); \ + _dest_vert_ = GIM_BUFFER_ARRAY_POINTER(_dst_type, _dst_array, 0); \ + for (_i_ = 0;_i_< _count_; _i_++) \ + { \ + _kernel(_uniform_data, *_source_vert_, *_dest_vert_); \ + _source_vert_++; \ + _dest_vert_++; \ + } \ + } \ + else \ + { \ + for (_i_ = 0; _i_ < _count_; _i_++) \ + { \ + _source_vert_ = GIM_BUFFER_ARRAY_POINTER(_src_type, _src_array, _i_); \ + _dest_vert_ = GIM_BUFFER_ARRAY_POINTER(_dst_type, _dst_array, _i_); \ + _kernel(_uniform_data, *_source_vert_, *_dest_vert_); \ + } \ + } \ + gim_buffer_array_unlock(&(_src_array)); \ + gim_buffer_array_unlock(&(_dst_array)); \ +} \ + +//! @} + +#endif // GIM_MEMORY_H_INCLUDED diff --git a/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_radixsort.h b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_radixsort.h new file mode 100644 index 0000000..8572b92 --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_radixsort.h @@ -0,0 +1,258 @@ +#ifndef GIM_RADIXSORT_H_INCLUDED +#define GIM_RADIXSORT_H_INCLUDED +/*! \file gim_radixsort.h +\author Francisco León. +Based on the work of Michael Herf : "fast floating-point radix sort" +Avaliable on http://www.stereopsis.com/radix.html +*/ +/* +----------------------------------------------------------------------------- +This source file is part of GIMPACT Library. + +For the latest info, see http://gimpact.sourceforge.net/ + +Copyright (c) 2006 Francisco Leon. C.C. 80087371. +email: projectileman@yahoo.com + + This library is free software; you can redistribute it and/or + modify it under the terms of EITHER: + (1) The GNU Lesser General Public License as published by the Free + Software Foundation; either version 2.1 of the License, or (at + your option) any later version. The text of the GNU Lesser + General Public License is included with this library in the + file GIMPACT-LICENSE-LGPL.TXT. + (2) The BSD-style license that is included with this library in + the file GIMPACT-LICENSE-BSD.TXT. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files + GIMPACT-LICENSE-LGPL.TXT and GIMPACT-LICENSE-BSD.TXT for more details. + +----------------------------------------------------------------------------- +*/ + +#include "GIMPACT/gim_memory.h" + +/*! \defgroup SORTING +\brief +Macros for sorting. +*/ +//! @{ +struct GIM_RSORT_TOKEN +{ + GUINT32 m_key; + GUINT32 m_value; +}; +//typedef struct _GIM_RSORT_TOKEN GIM_RSORT_TOKEN; + +//comparator for sorting +#define RSORT_TOKEN_COMPARATOR(x, y) ((int)((x.m_key) - (y.m_key))) + +// ---- utils for accessing 11-bit quantities +#define D11_0(x) (x & 0x7FF) +#define D11_1(x) (x >> 11 & 0x7FF) +#define D11_2(x) (x >> 22 ) + + +//COMMON FUNCTIONS FOR ACCESSING THE KEY OF AN ELEMENT + + +//For the type of your array, you need to declare a macro for obtaining the key, like these: +#define SIMPLE_GET_FLOAT32KEY(e,key) {key =(GREAL)(e);} + +#define SIMPLE_GET_INTKEY(e,key) {key =(GINT32)(e);} + +#define SIMPLE_GET_UINTKEY(e,key) {key =(GUINT32)(e);} + +//For the type of your array, you need to declare a macro for copy elements, like this: + +#define SIMPLE_COPY_ELEMENTS(dest,src) {dest = src;} + +#define kHist 2048 + +///Radix sort for unsigned integer keys + +#define GIM_RADIX_SORT_RTOKENS(array,sorted,element_count)\ +{\ + GUINT32 i;\ + GUINT32 b0[kHist * 3];\ + GUINT32 *b1 = b0 + kHist;\ + GUINT32 *b2 = b1 + kHist;\ + for (i = 0; i < kHist * 3; i++)\ + {\ + b0[i] = 0;\ + }\ + GUINT32 fi;\ + GUINT32 pos;\ + for (i = 0; i < element_count; i++)\ + {\ + fi = array[i].m_key;\ + b0[D11_0(fi)] ++;\ + b1[D11_1(fi)] ++;\ + b2[D11_2(fi)] ++;\ + }\ + {\ + GUINT32 sum0 = 0, sum1 = 0, sum2 = 0;\ + GUINT32 tsum;\ + for (i = 0; i < kHist; i++)\ + {\ + tsum = b0[i] + sum0;\ + b0[i] = sum0 - 1;\ + sum0 = tsum;\ + tsum = b1[i] + sum1;\ + b1[i] = sum1 - 1;\ + sum1 = tsum;\ + tsum = b2[i] + sum2;\ + b2[i] = sum2 - 1;\ + sum2 = tsum;\ + }\ + }\ + for (i = 0; i < element_count; i++)\ + {\ + fi = array[i].m_key;\ + pos = D11_0(fi);\ + pos = ++b0[pos];\ + sorted[pos].m_key = array[i].m_key;\ + sorted[pos].m_value = array[i].m_value;\ + }\ + for (i = 0; i < element_count; i++)\ + {\ + fi = sorted[i].m_key;\ + pos = D11_1(fi);\ + pos = ++b1[pos];\ + array[pos].m_key = sorted[i].m_key;\ + array[pos].m_value = sorted[i].m_value;\ + }\ + for (i = 0; i < element_count; i++)\ + {\ + fi = array[i].m_key;\ + pos = D11_2(fi);\ + pos = ++b2[pos];\ + sorted[pos].m_key = array[i].m_key;\ + sorted[pos].m_value = array[i].m_value;\ + }\ +}\ + +/// Get the sorted tokens from an array. For generic use. Tokens are GIM_RSORT_TOKEN +#define GIM_RADIX_SORT_ARRAY_TOKENS(array, sorted_tokens, element_count, get_uintkey_macro)\ +{\ + GIM_RSORT_TOKEN * _unsorted = (GIM_RSORT_TOKEN *) gim_alloc(sizeof(GIM_RSORT_TOKEN )*element_count);\ + GUINT32 _i;\ + for (_i=0;_i 0)\ + {\ + _stack_index_ --;\ + _start_ = _start_stack_[_stack_index_];\ + _end_ = _end_stack_[_stack_index_];\ + while (_end_ - _start_ > 2)\ + {\ + _p_ = _start_;\ + _i_ = _start_ + 1;\ + _j_ = _end_ - 1;\ + while (_i_<_j_) \ + {\ + for(; _i_<=_j_ && comp_macro(((array)[_i_]),((array)[_p_]))<=0; _i_++) ;\ + if (_i_ > _j_) \ + {\ + exchange_macro(type, array, _j_, _p_);\ + _i_ = _j_;\ + }\ + else\ + {\ + for(; _i_<=_j_ && comp_macro(((array)[_j_]),((array)[_p_]))>=0; _j_--) ;\ + if (_i_ > _j_) \ + {\ + exchange_macro(type, array, _j_, _p_);\ + _i_ = _j_;\ + }\ + else if (_i_ < _j_)\ + {\ + exchange_macro(type, array, _i_, _j_);\ + if (_i_+2 < _j_) {_i_++; _j_--;}\ + else if (_i_+1 < _j_) _i_++;\ + }\ + }\ + }\ + if (_i_-_start_ > 1 && _end_-_j_ > 1) \ + {\ + if (_i_-_start_ < _end_-_j_-1) \ + {\ + _start_stack_[_stack_index_] = _j_+1;\ + _end_stack_[_stack_index_] = _end_;\ + _stack_index_ ++;\ + _end_ = _i_;\ + }\ + else\ + {\ + _start_stack_[_stack_index_] = _start_;\ + _end_stack_[_stack_index_] = _i_;\ + _stack_index_ ++;\ + _start_ = _j_+1;\ + }\ + }\ + else\ + {\ + if (_i_-_start_ > 1)\ + {\ + _end_ = _i_;\ + }\ + else \ + {\ + _start_ = _j_+1;\ + }\ + }\ + }\ + if (_end_ - _start_ == 2) \ + {\ + if (comp_macro(((array)[_start_]),((array)[_end_-1])) > 0) \ + {\ + exchange_macro(type, array, _start_, _end_-1);\ + }\ + }\ + }\ +}\ + +#define GIM_DEF_EXCHANGE_MACRO(type, _array, _i, _j)\ +{\ + type _e_tmp_ =(_array)[(_i)];\ + (_array)[(_i)]=(_array)[(_j)];\ + (_array)[(_j)]= _e_tmp_;\ +}\ + +#define GIM_COMP_MACRO(x, y) ((GINT32)((x) - (y))) +//! @} +#endif // GIM_RADIXSORT_H_INCLUDED diff --git a/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_tri_capsule_collision.h b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_tri_capsule_collision.h new file mode 100644 index 0000000..2b31604 --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_tri_capsule_collision.h @@ -0,0 +1,111 @@ +#ifndef GIM_TRI_CAPSULE_COLLISION_H_INCLUDED +#define GIM_TRI_CAPSULE_COLLISION_H_INCLUDED + +/*! \file gim_tri_capsule_collision.h +\author Francisco León +*/ +/* +----------------------------------------------------------------------------- +This source file is part of GIMPACT Library. + +For the latest info, see http://gimpact.sourceforge.net/ + +Copyright (c) 2006 Francisco Leon. C.C. 80087371. +email: projectileman@yahoo.com + + This library is free software; you can redistribute it and/or + modify it under the terms of EITHER: + (1) The GNU Lesser General Public License as published by the Free + Software Foundation; either version 2.1 of the License, or (at + your option) any later version. The text of the GNU Lesser + General Public License is included with this library in the + file GIMPACT-LICENSE-LGPL.TXT. + (2) The BSD-style license that is included with this library in + the file GIMPACT-LICENSE-BSD.TXT. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files + GIMPACT-LICENSE-LGPL.TXT and GIMPACT-LICENSE-BSD.TXT for more details. + +----------------------------------------------------------------------------- +*/ + +#include "GIMPACT/gim_memory.h" + +/*! \addtogroup GEOMETRIC_OPERATIONS +*/ +//! @{ + +//! Capsule struct +struct GIM_CAPSULE_DATA +{ + GREAL m_radius; + vec3f m_point1; + vec3f m_point2; +}; +//typedef struct _GIM_CAPSULE_DATA GIM_CAPSULE_DATA; + +#define CALC_CAPSULE_AABB(capsule,aabb)\ +{\ + if(capsule.m_point1[0]G_EPSILON ?1:0; \ + if(_classif == 0) \ + { \ + if(_prevclassif==1) \ + {\ + if(clipped_count u*axe1[i1] + ((vecproj[i2] - u*axe1[i2])/axe2[i2])*axe2[i1] = vecproj[i1] + + --> u*axe1[i1] + vecproj[i2]*axe2[i1]/axe2[i2] - u*axe1[i2]*axe2[i1]/axe2[i2] = vecproj[i1] + + --> u*(axe1[i1] - axe1[i2]*axe2[i1]/axe2[i2]) = vecproj[i1] - vecproj[i2]*axe2[i1]/axe2[i2] + + --> u*((axe1[i1]*axe2[i2] - axe1[i2]*axe2[i1])/axe2[i2]) = (vecproj[i1]*axe2[i2] - vecproj[i2]*axe2[i1])/axe2[i2] + + --> u*(axe1[i1]*axe2[i2] - axe1[i2]*axe2[i1]) = vecproj[i1]*axe2[i2] - vecproj[i2]*axe2[i1] + + --> u = (vecproj[i1]*axe2[i2] - vecproj[i2]*axe2[i1]) /(axe1[i1]*axe2[i2] - axe1[i2]*axe2[i1]) + +if 0.0<= u+v <=1.0 then they are inside of triangle + + */ +#define TRIANGLE_GET_UVPARAMETERS(point,vec1,vec2,vec3,tri_plane,u,v,outside)\ +{\ + vec3f _axe1, _axe2, _vecproj;\ + VEC_DIFF(_axe1,vec2,vec1);\ + VEC_DIFF(_axe2,vec3,vec1);\ + VEC_DIFF(_vecproj,point,vec1);\ + GUINT32 _i1,_i2;\ + PLANE_MINOR_AXES(tri_plane, _i1, _i2);\ + if(fabsf(_axe2[_i2])G_EPSILON)\ + {\ + outside = 1;\ + }\ + else\ + {\ + outside = 0;\ + }\ + }\ +}\ + +//! Finds the collision of a ray and a triangle. +#define RAY_TRIANGLE_INTERSECTION(vOrigin,vDir,vec1,vec2,vec3,tri_plane,pout,u,v,tparam,tmax,does_intersect)\ +{\ + RAY_PLANE_COLLISION(tri_plane,vDir,vOrigin,pout,tparam,does_intersect);\ + if(does_intersect != 0)\ + {\ + if(tparam<-G_EPSILON||tparam>tmax+G_EPSILON)\ + {\ + does_intersect = 0;\ + }\ + else\ + {\ + TRIANGLE_GET_UVPARAMETERS(pout,vec1,vec2,vec3,tri_plane,u,v,does_intersect);\ + does_intersect = !does_intersect;\ + }\ + }\ +}\ + + +//! @} + +#endif // GIM_TRI_COLLISION_H_INCLUDED diff --git a/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_tri_sphere_collision.h b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_tri_sphere_collision.h new file mode 100644 index 0000000..a2a81d6 --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_tri_sphere_collision.h @@ -0,0 +1,51 @@ +#ifndef GIM_TRI_SPHERE_COLLISION_H_INCLUDED +#define GIM_TRI_SPHERE_COLLISION_H_INCLUDED + +/*! \file gim_tri_sphere_collision.h +\author Francisco León +*/ +/* +----------------------------------------------------------------------------- +This source file is part of GIMPACT Library. + +For the latest info, see http://gimpact.sourceforge.net/ + +Copyright (c) 2006 Francisco Leon. C.C. 80087371. +email: projectileman@yahoo.com + + This library is free software; you can redistribute it and/or + modify it under the terms of EITHER: + (1) The GNU Lesser General Public License as published by the Free + Software Foundation; either version 2.1 of the License, or (at + your option) any later version. The text of the GNU Lesser + General Public License is included with this library in the + file GIMPACT-LICENSE-LGPL.TXT. + (2) The BSD-style license that is included with this library in + the file GIMPACT-LICENSE-BSD.TXT. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files + GIMPACT-LICENSE-LGPL.TXT and GIMPACT-LICENSE-BSD.TXT for more details. + +----------------------------------------------------------------------------- +*/ + +/*! \addtogroup GEOMETRIC_OPERATIONS +*/ +//! @{ + +//! Finds the contact points from a collision of a triangle and a sphere +/*! +\param tri +\param center +\param radius +\param contact_data Contains the closest points on the Sphere, and the normal is pointing to triangle +*/ +int gim_triangle_sphere_collision( + GIM_TRIANGLE_DATA *tri, + vec3f center, GREAL radius, + GIM_TRIANGLE_CONTACT_DATA * contact_data); + +//! @} +#endif // GIM_TRI_SPHERE_COLLISION_H_INCLUDED diff --git a/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_trimesh.h b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_trimesh.h new file mode 100644 index 0000000..2983fca --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/include/GIMPACT/gim_trimesh.h @@ -0,0 +1,544 @@ +#ifndef GIM_TRIMESH_H_INCLUDED +#define GIM_TRIMESH_H_INCLUDED +/*! \file gim_trimesh.h +\author Francisco León +*/ +/* +----------------------------------------------------------------------------- +This source file is part of GIMPACT Library. + +For the latest info, see http://gimpact.sourceforge.net/ + +Copyright (c) 2006 Francisco Leon. C.C. 80087371. +email: projectileman@yahoo.com + + This library is free software; you can redistribute it and/or + modify it under the terms of EITHER: + (1) The GNU Lesser General Public License as published by the Free + Software Foundation; either version 2.1 of the License, or (at + your option) any later version. The text of the GNU Lesser + General Public License is included with this library in the + file GIMPACT-LICENSE-LGPL.TXT. + (2) The BSD-style license that is included with this library in + the file GIMPACT-LICENSE-BSD.TXT. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files + GIMPACT-LICENSE-LGPL.TXT and GIMPACT-LICENSE-BSD.TXT for more details. + +----------------------------------------------------------------------------- +*/ + +#include "GIMPACT/gim_boxpruning.h" +#include "GIMPACT/gim_contact.h" + + +///MAsk defines +#define GIM_TRIMESH_TRANSFORMED_REPLY 1 +#define GIM_TRIMESH_NEED_UPDATE 2 + +/*! \addtogroup TRIMESH +\brief +A Trimesh is the basic geometric structure for representing solid objects. +

    CREATING TRIMESHES

    +
      +
    • For creating trimeshes, you must initialize Buffer managers by calling \ref gimpact_init +
    • Then you must define the vertex and index sources by creating them with \ref BUFFER_ARRAYS routines, and then call \ref gim_trimesh_create_from_arrays. +
    • An alternative way for creaing trimesh objects is calling \ref gim_trimesh_create_from_data. +
    • For access to the trimesh data (vertices, triangle indices), you must call \ref gim_trimesh_locks_work_data , and \ref gim_trimesh_unlocks_work_data for finish the access. +
    • Each time when the trimesh data is modified, you must call \ref gim_trimesh_update after. +
    • When a trimesh is no longer needed, you must call \ref gim_trimesh_destroy. +
    + +

    This is an example of how to create a deformable trimesh that shares vertices with the user application:

    +\code +//Declaration of vertices +vec3f trimeshvertices[200]; +//Declaration of indices +GUINT trimeshindices[100]; + +... Initializing vertices and triangle indices at beginning + +//Then create trimesh +GIM_TRIMESH mytrimesh; + +//Calling trimesh create function + +gim_trimesh_create_from_data( +&mytrimesh, +trimeshvertices,200, +0 ,//copy_vertices is 0 +trimeshindices, +100, +0, //copy_indices is 0 +0 //transformed_reply is 0 +); +\endcode +

    Note that parameter transformed_reply is 0, that means that m_transformed_vertex_buffer is a reference to m_source_vertex on the trimesh, and transformations are not avaliable. Use that configuration if you have to simulate a deformable trimesh like cloth or elastic bodies.

    +

    When the trimesh is no longer needed, destroy it safely with gim_trimesh_destroy()

    +

    UPDATING TRIMESHES

    +

    On simulation loops, is needed to update trimeshes every time for update vertices althought updating triangle boxes and planes cache. There is two ways for update trimeshes:

    +
      +
    • Updating vertices directly. You need to access to the \ref GIM_TRIMESH.m_source_vertex_buffer member; a vertex buffer which has access to the source vertices. +\code +// Access to the source vertices +gim_buffer_array_lock(&mytrimesh.m_source_vertex_buffer, G_MA_READ_WRITE); + +//Get a pointer to the vertex buffer +vec3f * vertexpointer = GIM_BUFFER_ARRAY_POINTER(vec3f,mytrimesh.m_source_vertex_buffer,0); + +//Get the amount of vertices +int veccount = mytrimesh.m_source_vertex_buffer.m_element_count; + +//Modify vertices +for (int i=0;itransformed_reply = 0. +
    +
      +
    • Aplying a transformation. Simply use \ref gim_trimesh_set_tranform . Remember that with this method trimeshes must be created with \ref gim_trimesh_create_from_data with parameter transformed_reply = 1. +
    +

    After updating vertices, you must call \ref gim_trimesh_update()

    +

    TRIMESHES COLLISION

    +

    Before collide trimeshes, you need to update them first.

    +

    Then you must use \ref gim_trimesh_trimesh_collision().

    + +*/ +//! @{ + +//! Prototype for updating vertices +typedef void * gim_update_trimesh_function(struct _GIM_TRIMESH *); + +//! Trimesh +struct GIM_TRIMESH +{ + ///Original + //@{ + GBUFFER_ARRAY m_source_vertex_buffer;//!< Buffer of vec3f coordinates + + //! (GUINT) Indices of triangles,groups of three elements. + /*! + Array of GUINT. Triangle indices. Each triple contains indices of the vertices for each triangle. + \invariant must be aligned + */ + GBUFFER_ARRAY m_tri_index_buffer; + //@} + ///Allocated + //@{ + char m_mask;//!< Don't use directly + + //! Allocated transformed vertices vec3f + /*! + Array of vec3f.If gim_trimesh_has_tranformed_reply(this) == 1 then it refers to the m_source_vertex_buffer + \invariant must be aligned + */ + GBUFFER_ARRAY m_transformed_vertex_buffer; + //@} + ///Auxiliary data + //@{ + GIM_AABB_SET m_aabbset; + GDYNAMIC_ARRAY m_planes_cache_buffer;//! Allocated GIM_TRIPLANES_CACHE + GDYNAMIC_ARRAY m_planes_cache_bitset; + gim_update_trimesh_function * m_update_callback;//! If null, then m_transform is applied. + mat4f m_transform; + //@} +}; +//typedef struct _GIM_TRIMESH GIM_TRIMESH; + +/// Info about mesh +//! Return the trimesh triangle count +GUINT32 gim_trimesh_get_triangle_count(GIM_TRIMESH * trimesh); + +//! Returns 1 if the m_transformed_vertex_buffer is a reply of m_source_vertex_buffer +char gim_trimesh_has_tranformed_reply(GIM_TRIMESH * trimesh); + +//! Returns 1 if the trimesh needs to update their aabbset and the planes cache. +char gim_trimesh_needs_update(GIM_TRIMESH * trimesh); + +//! Change the state of the trimesh for force it to update +/*! +Call it after made changes to the trimesh. +\post gim_trimesh_need_update(trimesh) will return 1 +\sa gim_trimesh_needs_update,gim_trimesh_has_tranformed_reply +*/ +void gim_trimesh_post_update(GIM_TRIMESH * trimesh); + +//! Creates the aabb set and the triangles cache +/*! + +\param trimesh +\param vertex_array +\param triindex_array +\param transformed_reply If 1, then the m_transformed_vertices is a reply of the source vertices. Else it just be a reference to the original array. +\post it copies the arrays by reference, and creates the auxiliary data (m_aabbset,m_planes_cache_buffer) +*/ +void gim_trimesh_create_from_arrays(GBUFFER_MANAGER_DATA buffer_managers[], + GIM_TRIMESH * trimesh, GBUFFER_ARRAY * vertex_array, GBUFFER_ARRAY * triindex_array,char transformed_reply); + + + +//! Create a trimesh from vertex array and an index array +/*! +\param trimesh An uninitialized GIM_TRIMESH structure +\param vertex_array A buffer to a vec3f array +\param vertex_count +\param triindex_array +\param index_count +\param copy_vertices If 1, it copies the source vertices in another buffer. Else (0) it constructs a reference to the data. +\param copy_indices If 1, it copies the source vertices in another buffer. Else (0) it constructs a reference to the data. +\param transformed_reply If 1, then the m_transformed_vertices is a reply of the source vertices. Else it just be a reference to the original array. Use 1 if you will apply transformations to the trimesh. See \ref gim_trimesh_set_tranform(). +*/ +void gim_trimesh_create_from_data(GBUFFER_MANAGER_DATA buffer_managers[], + GIM_TRIMESH * trimesh, vec3f * vertex_array, GUINT32 vertex_count,char copy_vertices, + GUINT32 * triindex_array, GUINT32 index_count,char copy_indices,char transformed_reply); + +//! Clears auxiliary data and releases buffer arrays +void gim_trimesh_destroy(GIM_TRIMESH * trimesh); + +//! Copies two meshes +/*! +\param source_trimesh +\param dest_trimesh +\param copy_by_reference If 1, it attach a reference to the source vertices, else it copies the vertices +\param transformed_reply If 1, transformed vertices are reply of source vertives. 1 Is recommended +*/ +void gim_trimesh_copy(GIM_TRIMESH * source_trimesh, + GBUFFER_MANAGER_DATA dest_buffer_managers[], GIM_TRIMESH * dest_trimesh, + char copy_by_reference, char transformed_reply); + + +//! Locks the trimesh for working with it +/*! +\post locks m_tri_index_buffer and m_transformed_vertex_buffer. +\param trimesh +*/ +void gim_trimesh_locks_work_data(GIM_TRIMESH * trimesh); + + +//! unlocks the trimesh +/*! +\post unlocks m_tri_index_buffer and m_transformed_vertex_buffer. +\param trimesh +*/ +void gim_trimesh_unlocks_work_data(GIM_TRIMESH * trimesh); + +//! Updates m_transformed_vertex_buffer +/*! +\pre m_transformed_vertex_buffer must be unlocked +*/ +void gim_trimesh_update_vertices(GIM_TRIMESH * trimesh); + +//! Updates m_aabbset and m_planes_cache_bitset +/*! +\pre gim_trimesh_locks_work_data must be called before +*/ +void gim_trimesh_update_aabbset(GIM_TRIMESH * trimesh); + +//! Calls before perfom collisions. Updates the trimesh if needed +/*! +\post If gim_trimesh_needs_update returns 1, then it calls gim_trimesh_update_vertices and gim_trimesh_update_aabbset +*/ +void gim_trimesh_update(GIM_TRIMESH * trimesh); + +//! Set the transform of a trimesh +/*! +\post This function calls to gim_trimesh_post_update +*/ +void gim_trimesh_set_tranform(GIM_TRIMESH * trimesh, mat4f transform); + +//! Fetch triangle data +/*! +\pre gim_trimesh_locks_work_data must be called before +*/ +void gim_trimesh_get_triangle_data(GIM_TRIMESH * trimesh, GUINT32 triangle_index, GIM_TRIANGLE_DATA * tri_data); + +//! Fetch triangle vertices +/*! +\pre gim_trimesh_locks_work_data must be called before +*/ +void gim_trimesh_get_triangle_vertices(GIM_TRIMESH * trimesh, GUINT32 triangle_index, vec3f v1,vec3f v2,vec3f v3); + +//! Trimesh Trimesh Collisions +/*! +Before use this function you must update each trimesh: +\code +gim_trimesh_update(TriMesh1); +gim_trimesh_update(TriMesh2); +\endcode +Then you must use the trimesh collision in this way: +\code +int collide_trimeshes(GIM_TRIMESH * TriMesh1, GIM_TRIMESH * TriMesh2) +{ + //Create contact list + GDYNAMIC_ARRAY trimeshcontacts; + GIM_CREATE_CONTACT_LIST(trimeshcontacts); + + //Collide trimeshes + gim_trimesh_trimesh_collision(TriMesh1,TriMesh2,&trimeshcontacts); + + if(trimeshcontacts.m_size == 0) //do nothing + { + GIM_DYNARRAY_DESTROY(trimeshcontacts);//clean contact array + return 0; + } + + //Getting a pointer to the contact array + GIM_CONTACT * ptrimeshcontacts = GIM_DYNARRAY_POINTER(GIM_CONTACT,trimeshcontacts); + + int contactcount = trimeshcontacts.m_size; + int i; + //Process contacts + for (i=0;i +
  • m_handle1 points to trimesh1. +
  • m_handle2 points to trimesh2. +
  • m_feature1 Is a triangle index of trimesh1. +
  • m_feature2 Is a triangle index of trimesh2. + + +\param trimesh1 Collider +\param trimesh2 Collidee +\param contacts A GIM_CONTACT array. Must be initialized +*/ +void gim_trimesh_trimesh_collision(GIM_TRIMESH * trimesh1, GIM_TRIMESH * trimesh2, GDYNAMIC_ARRAY * contacts); + + +//! Trimesh Sphere Collisions +/*! +Before use this function you must update the trimesh: +\code +gim_trimesh_update(trimesh); +\endcode +Then you must use this function in this way: +\code +int collide_trimesh_sphere(GIM_TRIMESH * trimesh, vec3f center,GREAL radius) +{ + //Create contact list + GDYNAMIC_ARRAY trimeshcontacts; + GIM_CREATE_CONTACT_LIST(trimeshcontacts); + + //Collide trimeshes + gim_trimesh_sphere_collision(trimesh,center,radius,&trimeshcontacts); + + if(trimeshcontacts.m_size == 0) //do nothing + { + GIM_DYNARRAY_DESTROY(trimeshcontacts);//clean contact array + return 0; + } + + //Getting a pointer to the contact array + GIM_CONTACT * ptrimeshcontacts = GIM_DYNARRAY_POINTER(GIM_CONTACT,trimeshcontacts); + + int contactcount = trimeshcontacts.m_size; + int i; + //Process contacts + for (i=0;i +
  • m_handle1 points to trimesh. +
  • m_handle2 points to NULL. +
  • m_feature1 Is a triangle index of trimesh. + + +\param trimesh +\param center +\param radius +\param contacts A GIM_CONTACT array. Must be initialized +*/ +void gim_trimesh_sphere_collision(GIM_TRIMESH * trimesh,vec3f center,GREAL radius, GDYNAMIC_ARRAY * contacts); + + +//! Trimesh Capsule collision +/*! +Find the closest primitive collided by the ray. + +Before use this function you must update the trimesh: +\code +gim_trimesh_update(trimesh); +\endcode +Then you must use this function in this way: +\code +int collide_trimesh_capsule(GIM_TRIMESH * trimesh, GIM_CAPSULE_DATA * capsule) +{ + //Create contact list + GDYNAMIC_ARRAY trimeshcontacts; + GIM_CREATE_CONTACT_LIST(trimeshcontacts); + + //Collide trimeshes + gim_trimesh_capsule_collision(trimesh,capsule,&trimeshcontacts); + + if(trimeshcontacts.m_size == 0) //do nothing + { + GIM_DYNARRAY_DESTROY(trimeshcontacts);//clean contact array + return 0; + } + + //Getting a pointer to the contact array + GIM_CONTACT * ptrimeshcontacts = GIM_DYNARRAY_POINTER(GIM_CONTACT,trimeshcontacts); + + int contactcount = trimeshcontacts.m_size; + int i; + //Process contacts + for (i=0;i +
  • m_handle1 points to trimesh. +
  • m_handle2 points to NULL. +
  • m_feature1 Is a triangle index of trimesh. + + +\param trimesh +\param capsule +\param contacts A GIM_CONTACT array. Must be initialized +*/ +void gim_trimesh_capsule_collision(GIM_TRIMESH * trimesh, GIM_CAPSULE_DATA * capsule, GDYNAMIC_ARRAY * contacts); + + +///Function for create Trimesh Plane collision result +#define GIM_CREATE_TRIMESHPLANE_CONTACTS(dynarray) GIM_DYNARRAY_CREATE(vec4f,dynarray,G_ARRAY_GROW_SIZE) + +//! Trimesh Plane Collisions +/*! + +Before use this function you must update the trimesh: +\code +gim_trimesh_update(trimesh); +\endcode +Then you must use this function in this way: +\code +int collide_trimesh_plane(GIM_TRIMESH * trimesh, vec4f plane) +{ + //Create contact list + GDYNAMIC_ARRAY tri_plane_contacts; + GIM_CREATE_TRIMESHPLANE_CONTACTS(tri_plane_contacts); + + //Collide trimeshes + gim_trimesh_plane_collision(trimesh,plane,&tri_plane_contacts); + + if(tri_plane_contacts.m_size == 0) //do nothing + { + GIM_DYNARRAY_DESTROY(tri_plane_contacts);//clean contact array + return 0; + } + + //Getting a pointer to the contact array + vec4f * planecontacts = GIM_DYNARRAY_POINTER(vec4f,tri_plane_contacts); + + int contactcount = tri_plane_contacts.m_size; + int i; + //Process contacts + for (i=0;i&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = GIMPACT/include +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ + $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ + $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/ode/src/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +SOURCES = +DIST_SOURCES = +RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ + ctags-recursive dvi-recursive html-recursive info-recursive \ + install-data-recursive install-dvi-recursive \ + install-exec-recursive install-html-recursive \ + install-info-recursive install-pdf-recursive \ + install-ps-recursive install-recursive installcheck-recursive \ + installdirs-recursive pdf-recursive ps-recursive \ + tags-recursive uninstall-recursive +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ + distclean-recursive maintainer-clean-recursive +am__recursive_targets = \ + $(RECURSIVE_TARGETS) \ + $(RECURSIVE_CLEAN_TARGETS) \ + $(am__extra_recursive_targets) +AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ + distdir +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +DIST_SUBDIRS = $(SUBDIRS) +am__DIST_COMMON = $(srcdir)/Makefile.in +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +am__relativize = \ + dir0=`pwd`; \ + sed_first='s,^\([^/]*\)/.*$$,\1,'; \ + sed_rest='s,^[^/]*/*,,'; \ + sed_last='s,^.*/\([^/]*\)$$,\1,'; \ + sed_butlast='s,/*[^/]*$$,,'; \ + while test -n "$$dir1"; do \ + first=`echo "$$dir1" | sed -e "$$sed_first"`; \ + if test "$$first" != "."; then \ + if test "$$first" = ".."; then \ + dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ + dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ + else \ + first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ + if test "$$first2" = "$$first"; then \ + dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ + else \ + dir2="../$$dir2"; \ + fi; \ + dir0="$$dir0"/"$$first"; \ + fi; \ + fi; \ + dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ + done; \ + reldir="$$dir2" +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AS = @AS@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CCD_CFLAGS = @CCD_CFLAGS@ +CCD_LIBS = @CCD_LIBS@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DOXYGEN = @DOXYGEN@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +EXTRA_LIBTOOL_LDFLAGS = @EXTRA_LIBTOOL_LDFLAGS@ +FGREP = @FGREP@ +GL_LIBS = @GL_LIBS@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBSTDCXX = @LIBSTDCXX@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +ODE_PRECISION = @ODE_PRECISION@ +ODE_VERSION = @ODE_VERSION@ +ODE_VERSION_INFO = @ODE_VERSION_INFO@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +WINDRES = @WINDRES@ +X11_CFLAGS = @X11_CFLAGS@ +X11_LIBS = @X11_LIBS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_WINDRES = @ac_ct_WINDRES@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +runstatedir = @runstatedir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +SUBDIRS = GIMPACT +all: all-recursive + +.SUFFIXES: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign GIMPACT/include/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign GIMPACT/include/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +# This directory's subdirectories are mostly independent; you can cd +# into them and run 'make' without going through this Makefile. +# To change the values of 'make' variables: instead of editing Makefiles, +# (1) if the variable is set in 'config.status', edit 'config.status' +# (which will cause the Makefiles to be regenerated when you run 'make'); +# (2) otherwise, pass the desired values on the 'make' command line. +$(am__recursive_targets): + @fail=; \ + if $(am__make_keepgoing); then \ + failcom='fail=yes'; \ + else \ + failcom='exit 1'; \ + fi; \ + dot_seen=no; \ + target=`echo $@ | sed s/-recursive//`; \ + case "$@" in \ + distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ + *) list='$(SUBDIRS)' ;; \ + esac; \ + for subdir in $$list; do \ + echo "Making $$target in $$subdir"; \ + if test "$$subdir" = "."; then \ + dot_seen=yes; \ + local_target="$$target-am"; \ + else \ + local_target="$$target"; \ + fi; \ + ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ + || eval $$failcom; \ + done; \ + if test "$$dot_seen" = "no"; then \ + $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ + fi; test -z "$$fail" + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-recursive +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ + include_option=--etags-include; \ + empty_fix=.; \ + else \ + include_option=--include; \ + empty_fix=; \ + fi; \ + list='$(SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + test ! -f $$subdir/TAGS || \ + set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ + fi; \ + done; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-recursive + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-recursive + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done + @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + $(am__make_dryrun) \ + || test -d "$(distdir)/$$subdir" \ + || $(MKDIR_P) "$(distdir)/$$subdir" \ + || exit 1; \ + dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ + $(am__relativize); \ + new_distdir=$$reldir; \ + dir1=$$subdir; dir2="$(top_distdir)"; \ + $(am__relativize); \ + new_top_distdir=$$reldir; \ + echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ + echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ + ($(am__cd) $$subdir && \ + $(MAKE) $(AM_MAKEFLAGS) \ + top_distdir="$$new_top_distdir" \ + distdir="$$new_distdir" \ + am__remove_distdir=: \ + am__skip_length_check=: \ + am__skip_mode_fix=: \ + distdir) \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-recursive +all-am: Makefile +installdirs: installdirs-recursive +installdirs-am: +install: install-recursive +install-exec: install-exec-recursive +install-data: install-data-recursive +uninstall: uninstall-recursive + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-recursive +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-recursive + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-recursive + -rm -f Makefile +distclean-am: clean-am distclean-generic distclean-tags + +dvi: dvi-recursive + +dvi-am: + +html: html-recursive + +html-am: + +info: info-recursive + +info-am: + +install-data-am: + +install-dvi: install-dvi-recursive + +install-dvi-am: + +install-exec-am: + +install-html: install-html-recursive + +install-html-am: + +install-info: install-info-recursive + +install-info-am: + +install-man: + +install-pdf: install-pdf-recursive + +install-pdf-am: + +install-ps: install-ps-recursive + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-recursive + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-recursive + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-recursive + +pdf-am: + +ps: ps-recursive + +ps-am: + +uninstall-am: + +.MAKE: $(am__recursive_targets) install-am install-strip + +.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \ + check-am clean clean-generic clean-libtool cscopelist-am ctags \ + ctags-am distclean distclean-generic distclean-libtool \ + distclean-tags distdir dvi dvi-am html html-am info info-am \ + install install-am install-data install-data-am install-dvi \ + install-dvi-am install-exec install-exec-am install-html \ + install-html-am install-info install-info-am install-man \ + install-pdf install-pdf-am install-ps install-ps-am \ + install-strip installcheck installcheck-am installdirs \ + installdirs-am maintainer-clean maintainer-clean-generic \ + mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ + ps ps-am tags tags-am uninstall uninstall-am + +.PRECIOUS: Makefile + + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/libs/ode-0.16.1/GIMPACT/src/Makefile.am b/libs/ode-0.16.1/GIMPACT/src/Makefile.am new file mode 100644 index 0000000..2cd230b --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/src/Makefile.am @@ -0,0 +1,19 @@ +noinst_LTLIBRARIES = libGIMPACT.la +AM_CPPFLAGS = -fno-strict-aliasing \ + -I$(top_srcdir)/include \ + -I$(top_builddir)/include \ + -I$(top_srcdir)/ode/src \ + -I$(top_srcdir)/GIMPACT/include + +libGIMPACT_la_SOURCES = gim_boxpruning.cpp \ + gim_contact.cpp \ + gim_math.cpp \ + gim_memory.cpp \ + gim_tri_tri_overlap.cpp \ + gim_trimesh.cpp \ + gim_trimesh_capsule_collision.cpp \ + gim_trimesh_ray_collision.cpp \ + gim_trimesh_sphere_collision.cpp \ + gim_trimesh_trimesh_collision.cpp \ + gimpact.cpp + diff --git a/libs/ode-0.16.1/GIMPACT/src/Makefile.in b/libs/ode-0.16.1/GIMPACT/src/Makefile.in new file mode 100644 index 0000000..70ab49e --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/src/Makefile.in @@ -0,0 +1,638 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = GIMPACT/src +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ + $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ + $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/ode/src/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +LTLIBRARIES = $(noinst_LTLIBRARIES) +libGIMPACT_la_LIBADD = +am_libGIMPACT_la_OBJECTS = gim_boxpruning.lo gim_contact.lo \ + gim_math.lo gim_memory.lo gim_tri_tri_overlap.lo \ + gim_trimesh.lo gim_trimesh_capsule_collision.lo \ + gim_trimesh_ray_collision.lo gim_trimesh_sphere_collision.lo \ + gim_trimesh_trimesh_collision.lo gimpact.lo +libGIMPACT_la_OBJECTS = $(am_libGIMPACT_la_OBJECTS) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/ode/src +depcomp = $(SHELL) $(top_srcdir)/depcomp +am__depfiles_maybe = depfiles +am__mv = mv -f +CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ + $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) +LTCXXCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CXXFLAGS) $(CXXFLAGS) +AM_V_CXX = $(am__v_CXX_@AM_V@) +am__v_CXX_ = $(am__v_CXX_@AM_DEFAULT_V@) +am__v_CXX_0 = @echo " CXX " $@; +am__v_CXX_1 = +CXXLD = $(CXX) +CXXLINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \ + $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CXXLD = $(am__v_CXXLD_@AM_V@) +am__v_CXXLD_ = $(am__v_CXXLD_@AM_DEFAULT_V@) +am__v_CXXLD_0 = @echo " CXXLD " $@; +am__v_CXXLD_1 = +SOURCES = $(libGIMPACT_la_SOURCES) +DIST_SOURCES = $(libGIMPACT_la_SOURCES) +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AS = @AS@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CCD_CFLAGS = @CCD_CFLAGS@ +CCD_LIBS = @CCD_LIBS@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DOXYGEN = @DOXYGEN@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +EXTRA_LIBTOOL_LDFLAGS = @EXTRA_LIBTOOL_LDFLAGS@ +FGREP = @FGREP@ +GL_LIBS = @GL_LIBS@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBSTDCXX = @LIBSTDCXX@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +ODE_PRECISION = @ODE_PRECISION@ +ODE_VERSION = @ODE_VERSION@ +ODE_VERSION_INFO = @ODE_VERSION_INFO@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +WINDRES = @WINDRES@ +X11_CFLAGS = @X11_CFLAGS@ +X11_LIBS = @X11_LIBS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_WINDRES = @ac_ct_WINDRES@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +runstatedir = @runstatedir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +noinst_LTLIBRARIES = libGIMPACT.la +AM_CPPFLAGS = -fno-strict-aliasing \ + -I$(top_srcdir)/include \ + -I$(top_builddir)/include \ + -I$(top_srcdir)/ode/src \ + -I$(top_srcdir)/GIMPACT/include + +libGIMPACT_la_SOURCES = gim_boxpruning.cpp \ + gim_contact.cpp \ + gim_math.cpp \ + gim_memory.cpp \ + gim_tri_tri_overlap.cpp \ + gim_trimesh.cpp \ + gim_trimesh_capsule_collision.cpp \ + gim_trimesh_ray_collision.cpp \ + gim_trimesh_sphere_collision.cpp \ + gim_trimesh_trimesh_collision.cpp \ + gimpact.cpp + +all: all-am + +.SUFFIXES: +.SUFFIXES: .cpp .lo .o .obj +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign GIMPACT/src/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign GIMPACT/src/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): + +clean-noinstLTLIBRARIES: + -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES) + @list='$(noinst_LTLIBRARIES)'; \ + locs=`for p in $$list; do echo $$p; done | \ + sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ + sort -u`; \ + test -z "$$locs" || { \ + echo rm -f $${locs}; \ + rm -f $${locs}; \ + } + +libGIMPACT.la: $(libGIMPACT_la_OBJECTS) $(libGIMPACT_la_DEPENDENCIES) $(EXTRA_libGIMPACT_la_DEPENDENCIES) + $(AM_V_CXXLD)$(CXXLINK) $(libGIMPACT_la_OBJECTS) $(libGIMPACT_la_LIBADD) $(LIBS) + +mostlyclean-compile: + -rm -f *.$(OBJEXT) + +distclean-compile: + -rm -f *.tab.c + +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gim_boxpruning.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gim_contact.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gim_math.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gim_memory.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gim_tri_tri_overlap.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gim_trimesh.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gim_trimesh_capsule_collision.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gim_trimesh_ray_collision.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gim_trimesh_sphere_collision.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gim_trimesh_trimesh_collision.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gimpact.Plo@am__quote@ + +.cpp.o: +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ $< + +.cpp.obj: +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'` + +.cpp.lo: +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LTCXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LTCXXCOMPILE) -c -o $@ $< + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(LTLIBRARIES) +installdirs: +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-generic clean-libtool clean-noinstLTLIBRARIES \ + mostlyclean-am + +distclean: distclean-am + -rm -rf ./$(DEPDIR) + -rm -f Makefile +distclean-am: clean-am distclean-compile distclean-generic \ + distclean-tags + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -rf ./$(DEPDIR) + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ + mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: + +.MAKE: install-am install-strip + +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ + clean-libtool clean-noinstLTLIBRARIES cscopelist-am ctags \ + ctags-am distclean distclean-compile distclean-generic \ + distclean-libtool distclean-tags distdir dvi dvi-am html \ + html-am info info-am install install-am install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am install-info \ + install-info-am install-man install-pdf install-pdf-am \ + install-ps install-ps-am install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-am uninstall uninstall-am + +.PRECIOUS: Makefile + + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/libs/ode-0.16.1/GIMPACT/src/gim_boxpruning.cpp b/libs/ode-0.16.1/GIMPACT/src/gim_boxpruning.cpp new file mode 100644 index 0000000..f2e77d7 --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/src/gim_boxpruning.cpp @@ -0,0 +1,519 @@ + +/* +----------------------------------------------------------------------------- +This source file is part of GIMPACT Library. + +For the latest info, see http://gimpact.sourceforge.net/ + +Copyright (c) 2006 Francisco Leon. C.C. 80087371. +email: projectileman@yahoo.com + + This library is free software; you can redistribute it and/or + modify it under the terms of EITHER: + (1) The GNU Lesser General Public License as published by the Free + Software Foundation; either version 2.1 of the License, or (at + your option) any later version. The text of the GNU Lesser + General Public License is included with this library in the + file GIMPACT-LICENSE-LGPL.TXT. + (2) The BSD-style license that is included with this library in + the file GIMPACT-LICENSE-BSD.TXT. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files + GIMPACT-LICENSE-LGPL.TXT and GIMPACT-LICENSE-BSD.TXT for more details. + +----------------------------------------------------------------------------- +*/ + + +#include "GIMPACT/gim_boxpruning.h" + + + +//! Allocate memory for all aabb set. +void gim_aabbset_alloc(GIM_AABB_SET * aabbset, GUINT32 count) +{ + aabbset->m_count = count; + aabbset->m_boxes = (aabb3f *)gim_alloc(sizeof(aabb3f)*count); + + if(countm_maxcoords = 0; + aabbset->m_sorted_mincoords = 0; + } + else + { + aabbset->m_maxcoords = (GUINT32 *)gim_alloc(sizeof(GUINT32)*aabbset->m_count ); + aabbset->m_sorted_mincoords = (GIM_RSORT_TOKEN *)gim_alloc(sizeof(GIM_RSORT_TOKEN)*aabbset->m_count); + } + aabbset->m_shared = 0; + INVALIDATE_AABB(aabbset->m_global_bound); +} + +//! Destroys the aabb set. +void gim_aabbset_destroy(GIM_AABB_SET * aabbset) +{ + aabbset->m_count = 0; + if(aabbset->m_shared==0) + { + gim_free(aabbset->m_boxes,0); + gim_free(aabbset->m_maxcoords,0); + gim_free(aabbset->m_sorted_mincoords,0); + } + aabbset->m_boxes = 0; + aabbset->m_sorted_mincoords = 0; + aabbset->m_maxcoords = 0; +} + +void gim_aabbset_calc_global_bound(GIM_AABB_SET * aabbset) +{ + aabb3f * paabb = aabbset->m_boxes; + aabb3f * globalbox = &aabbset->m_global_bound; + AABB_COPY((*globalbox),(*paabb)); + + GUINT32 count = aabbset->m_count-1; + paabb++; + while(count) + { + MERGEBOXES(*globalbox,*paabb) + paabb++; + count--; + } +} + + +//! Sorts the boxes for box prunning. +/*! +1) find the integer representation of the aabb coords +2) Sorts the min coords +3) Calcs the global bound +\pre aabbset must be allocated. And the boxes must be already set. +\param aabbset +\param calc_global_bound If 1 , calcs the global bound +\post If aabbset->m_sorted_mincoords == 0, then it allocs the sorted coordinates +*/ +void gim_aabbset_sort(GIM_AABB_SET * aabbset, char calc_global_bound) +{ + if(aabbset->m_sorted_mincoords == 0) + {//allocate + aabbset->m_maxcoords = (GUINT32 *)gim_alloc(sizeof(GUINT32)*aabbset->m_count ); + aabbset->m_sorted_mincoords = (GIM_RSORT_TOKEN *)gim_alloc(sizeof(GIM_RSORT_TOKEN)*aabbset->m_count); + } + + GUINT32 i, count = aabbset->m_count; + aabb3f * paabb = aabbset->m_boxes; + GUINT32 * maxcoords = aabbset->m_maxcoords; + GIM_RSORT_TOKEN * sorted_tokens = aabbset->m_sorted_mincoords; + + if(count<860)//Calibrated on a Pentium IV + { + //Sort by quick sort + //Calculate keys + for(i=0;im_index1 = i;\ + _pair->m_index2 = j;\ +} + +#define PUSH_PAIR_INV(i,j,pairset)\ +{\ + GIM_DYNARRAY_PUSH_EMPTY(GIM_PAIR,pairset);\ + GIM_PAIR * _pair = GIM_DYNARRAY_POINTER(GIM_PAIR,pairset) + (pairset).m_size - 1;\ + _pair->m_index1 = j;\ + _pair->m_index2 = i;\ +} + +#define FIND_OVERLAPPING_FOWARD(\ + curr_index,\ + test_count,\ + test_aabb,\ + max_coord_uint,\ + sorted_tokens,\ + aabbarray,\ + pairset,\ + push_pair_macro)\ +{\ + GUINT32 _i = test_count;\ + char _intersected;\ + GIM_RSORT_TOKEN * _psorted_tokens = sorted_tokens;\ + while(_i>0 && max_coord_uint >= _psorted_tokens->m_key)\ + {\ + AABBCOLLISION(_intersected,test_aabb,aabbarray[_psorted_tokens->m_value]);\ + if(_intersected)\ + {\ + push_pair_macro(curr_index, _psorted_tokens->m_value,pairset);\ + }\ + _psorted_tokens++;\ + _i--;\ + }\ +} + +//! log(N) Complete box pruning. Returns a list of overlapping pairs of boxes, each box of the pair belongs to the same set. +/*! +\pre aabbset must be allocated and sorted, the boxes must be already set. +\param aabbset Must be sorted. Global bound isn't required +\param collision_pairs Array of GIM_PAIR elements. Must be initialized before (Reserve size ~ 100) +*/ +void gim_aabbset_self_intersections_sorted(GIM_AABB_SET * aabbset, GDYNAMIC_ARRAY * collision_pairs) +{ + collision_pairs->m_size = 0; + GUINT32 count = aabbset->m_count; + aabb3f * paabb = aabbset->m_boxes; + GUINT32 * maxcoords = aabbset->m_maxcoords; + GIM_RSORT_TOKEN * sorted_tokens = aabbset->m_sorted_mincoords; + aabb3f test_aabb; + while(count>1) + { + ///current cache variables + GUINT32 curr_index = sorted_tokens->m_value; + GUINT32 max_coord_uint = maxcoords[curr_index]; + AABB_COPY(test_aabb,paabb[curr_index]); + + ///next pairs + sorted_tokens++; + count--; + FIND_OVERLAPPING_FOWARD( curr_index, count, test_aabb, max_coord_uint, sorted_tokens , paabb, (*collision_pairs),PUSH_PAIR); + } +} + +//! NxN Complete box pruning. Returns a list of overlapping pairs of boxes, each box of the pair belongs to the same set. +/*! +\pre aabbset must be allocated, the boxes must be already set. +\param aabbset Global bound isn't required. Doen't need to be sorted. +\param collision_pairs Array of GIM_PAIR elements. Must be initialized before (Reserve size ~ 100) +*/ +void gim_aabbset_self_intersections_brute_force(GIM_AABB_SET * aabbset, GDYNAMIC_ARRAY * collision_pairs) +{ + collision_pairs->m_size = 0; + GUINT32 i,j; + GUINT32 count = aabbset->m_count; + aabb3f * paabb = aabbset->m_boxes; + char intersected; + for (i=0;i< count-1 ;i++ ) + { + for (j=i+1;jm_size = 0; + + AABBCOLLISION(intersected,aabbset1->m_global_bound,aabbset2->m_global_bound); + if(intersected == 0) return; + + GUINT32 count1 = aabbset1->m_count; + aabb3f * paabb1 = aabbset1->m_boxes; + GUINT32 * maxcoords1 = aabbset1->m_maxcoords; + GIM_RSORT_TOKEN * sorted_tokens1 = aabbset1->m_sorted_mincoords; + + GUINT32 count2 = aabbset2->m_count; + aabb3f * paabb2 = aabbset2->m_boxes; + GUINT32 * maxcoords2 = aabbset2->m_maxcoords; + GIM_RSORT_TOKEN * sorted_tokens2 = aabbset2->m_sorted_mincoords; + + GUINT32 curr_index; + + GUINT32 max_coord_uint; + aabb3f test_aabb; + + //Classify boxes + //Find Set intersection + aabb3f int_abbb; + BOXINTERSECTION(aabbset1->m_global_bound,aabbset2->m_global_bound, int_abbb); + + //Clasify set 1 + GIM_RSORT_TOKEN * classified_tokens1 = (GIM_RSORT_TOKEN *) gim_alloc(sizeof(GIM_RSORT_TOKEN)*count1); + GUINT32 i,classified_count1 = 0,classified_count2 = 0; + + + for (i=0;i0&&classified_count2>0) + { + if(sorted_tokens1->m_key <= sorted_tokens2->m_key) + { + ///current cache variables + curr_index = sorted_tokens1->m_value; + max_coord_uint = maxcoords1[curr_index]; + AABB_COPY(test_aabb,paabb1[curr_index]); + ///next pairs + sorted_tokens1++; + classified_count1--; + FIND_OVERLAPPING_FOWARD( curr_index, classified_count2, test_aabb, max_coord_uint, sorted_tokens2 , paabb2, (*collision_pairs), PUSH_PAIR); + } + else ///Switch test + { + ///current cache variables + curr_index = sorted_tokens2->m_value; + max_coord_uint = maxcoords2[curr_index]; + AABB_COPY(test_aabb,paabb2[curr_index]); + ///next pairs + sorted_tokens2++; + classified_count2--; + FIND_OVERLAPPING_FOWARD( curr_index, classified_count1, test_aabb, max_coord_uint, sorted_tokens1 , paabb1, (*collision_pairs), PUSH_PAIR_INV ); + } + } + gim_free(classified_tokens1 ,0); + gim_free(classified_tokens2 ,0); +} + +//! NxM Bipartite box pruning. Returns a list of overlapping pairs of boxes, each box of the pair belongs to a different set. +/*! +\pre aabbset1 and aabbset2 must be allocated and sorted, the boxes must be already set. +\param aabbset1 Must be sorted, Global bound is required. +\param aabbset2 Must be sorted, Global bound is required. +\param collision_pairs Array of GIM_PAIR elements. Must be initialized before (Reserve size ~ 100) +*/ +void gim_aabbset_bipartite_intersections_brute_force(GIM_AABB_SET * aabbset1,GIM_AABB_SET * aabbset2, GDYNAMIC_ARRAY * collision_pairs) +{ + char intersected; + collision_pairs->m_size = 0; + AABBCOLLISION(intersected,aabbset1->m_global_bound,aabbset2->m_global_bound); + if(intersected == 0) return; + + aabb3f int_abbb; + //Find Set intersection + BOXINTERSECTION(aabbset1->m_global_bound,aabbset2->m_global_bound, int_abbb); + //Clasify set 1 + GUINT32 i,j; + GUINT32 classified_count = 0; + + GUINT32 count = aabbset1->m_count; + aabb3f * paabb1 = aabbset1->m_boxes; + aabb3f * paabb2 = aabbset2->m_boxes; + + GUINT32 * classified = (GUINT32 *) gim_alloc(sizeof(GUINT32)*count); + + for (i=0;im_count; + for (i=0;im_count < GIM_MIN_SORTED_BIPARTITE_PRUNING_BOXES) + {//Brute force approach + gim_aabbset_calc_global_bound(aabbset); + } + else + {//Sorted force approach + gim_aabbset_sort(aabbset,1); + } +} + +//! Complete box pruning. Returns a list of overlapping pairs of boxes, each box of the pair belongs to the same set. +/*! +This function sorts the set and then it calls to gim_aabbset_self_intersections_brute_force or gim_aabbset_self_intersections_sorted. + +\param aabbset Set of boxes. Sorting isn't required. +\param collision_pairs Array of GIM_PAIR elements. Must be initialized before (Reserve size ~ 100) +\pre aabbset must be allocated and initialized. +\post If aabbset->m_count >= GIM_MIN_SORTED_PRUNING_BOXES, then it calls to gim_aabbset_sort and then to gim_aabbset_self_intersections_sorted. +*/ +void gim_aabbset_self_intersections(GIM_AABB_SET * aabbset, GDYNAMIC_ARRAY * collision_pairs) +{ + if(aabbset->m_count < GIM_MIN_SORTED_PRUNING_BOXES) + {//Brute force approach + gim_aabbset_self_intersections_brute_force(aabbset,collision_pairs); + } + else + {//Sorted force approach + gim_aabbset_sort(aabbset,0); + gim_aabbset_self_intersections_sorted(aabbset,collision_pairs); + } +} + +//! Collides two sets. Returns a list of overlapping pairs of boxes, each box of the pair belongs to a different set. +/*! +\pre aabbset1 and aabbset2 must be allocated and updated. See . +\param aabbset1 Must be sorted, Global bound is required. +\param aabbset2 Must be sorted, Global bound is required. +\param collision_pairs Array of GIM_PAIR elements. Must be initialized before (Reserve size ~ 100) +*/ +void gim_aabbset_bipartite_intersections(GIM_AABB_SET * aabbset1, GIM_AABB_SET * aabbset2, GDYNAMIC_ARRAY * collision_pairs) +{ + if(aabbset1->m_sorted_mincoords == 0||aabbset2->m_sorted_mincoords == 0) + {//Brute force approach + gim_aabbset_bipartite_intersections_brute_force(aabbset1,aabbset2,collision_pairs); + } + else + {//Sorted force approach + gim_aabbset_bipartite_intersections_sorted(aabbset1,aabbset2,collision_pairs); + } +} + +void gim_aabbset_box_collision(aabb3f *test_aabb, GIM_AABB_SET * aabbset, GDYNAMIC_ARRAY * collided) +{ + collided->m_size = 0; + char intersected; + AABBCOLLISION(intersected,aabbset->m_global_bound,(*test_aabb)); + if(intersected == 0) return; + + GUINT32 i; + GUINT32 count = aabbset->m_count; + aabb3f * paabb = aabbset->m_boxes; + aabb3f _testaabb; + AABB_COPY(_testaabb,*test_aabb); + + for (i=0;i< count;i++ ) + { + AABBCOLLISION(intersected,paabb[i],_testaabb); + if(intersected) + { + GIM_DYNARRAY_PUSH_ITEM(GUINT32,(*collided),i); + } + } +} + +void gim_aabbset_ray_collision(vec3f vorigin,vec3f vdir, GREAL tmax, GIM_AABB_SET * aabbset, GDYNAMIC_ARRAY * collided) +{ + collided->m_size = 0; + char intersected; + GREAL tparam = 0; + BOX_INTERSECTS_RAY(aabbset->m_global_bound, vorigin, vdir, tparam, tmax,intersected); + if(intersected==0) return; + + GUINT32 i; + GUINT32 count = aabbset->m_count; + aabb3f * paabb = aabbset->m_boxes; + + for (i=0;i< count;i++ ) + { + BOX_INTERSECTS_RAY(paabb[i], vorigin, vdir, tparam, tmax,intersected); + if(intersected) + { + GIM_DYNARRAY_PUSH_ITEM(GUINT32,(*collided),i); + } + } + (void)tparam; +} diff --git a/libs/ode-0.16.1/GIMPACT/src/gim_contact.cpp b/libs/ode-0.16.1/GIMPACT/src/gim_contact.cpp new file mode 100644 index 0000000..4b61298 --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/src/gim_contact.cpp @@ -0,0 +1,132 @@ + +/* +----------------------------------------------------------------------------- +This source file is part of GIMPACT Library. + +For the latest info, see http://gimpact.sourceforge.net/ + +Copyright (c) 2006 Francisco Leon. C.C. 80087371. +email: projectileman@yahoo.com + + This library is free software; you can redistribute it and/or + modify it under the terms of EITHER: + (1) The GNU Lesser General Public License as published by the Free + Software Foundation; either version 2.1 of the License, or (at + your option) any later version. The text of the GNU Lesser + General Public License is included with this library in the + file GIMPACT-LICENSE-LGPL.TXT. + (2) The BSD-style license that is included with this library in + the file GIMPACT-LICENSE-BSD.TXT. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files + GIMPACT-LICENSE-LGPL.TXT and GIMPACT-LICENSE-BSD.TXT for more details. + +----------------------------------------------------------------------------- +*/ + +#include "GIMPACT/gim_contact.h" + +void gim_merge_contacts(GDYNAMIC_ARRAY * source_contacts, + GDYNAMIC_ARRAY * dest_contacts) +{ + dest_contacts->m_size = 0; + + GUINT32 source_count = source_contacts->m_size; + GIM_CONTACT * psource_contacts = GIM_DYNARRAY_POINTER(GIM_CONTACT,(*source_contacts)); + //create keys + GIM_RSORT_TOKEN * keycontacts = (GIM_RSORT_TOKEN * )gim_alloc(sizeof(GIM_RSORT_TOKEN)*source_count); + + GUINT32 i; + for(i=0;im_size;i++) + { + key = keycontacts[i].m_key; + scontact = &psource_contacts[keycontacts[i].m_value]; + + if(i>0 && last_key == key) + { + //merge contact + if(pcontact->m_depth > scontact->m_depth + CONTACT_DIFF_EPSILON) + { + GIM_COPY_CONTACTS(pcontact, scontact); + } + } + else + {//add new contact + GIM_DYNARRAY_PUSH_EMPTY(GIM_CONTACT,(*dest_contacts)); + pcontact = GIM_DYNARRAY_POINTER_LAST(GIM_CONTACT,(*dest_contacts)); + GIM_COPY_CONTACTS(pcontact, scontact); + } + last_key = key; + } + gim_free(keycontacts,0); +} + +void gim_merge_contacts_unique(GDYNAMIC_ARRAY * source_contacts, + GDYNAMIC_ARRAY * dest_contacts) +{ + dest_contacts->m_size = 0; + //Traverse the source contacts + GUINT32 source_count = source_contacts->m_size; + if(source_count==0) return; + + GIM_CONTACT * psource_contacts = GIM_DYNARRAY_POINTER(GIM_CONTACT,(*source_contacts)); + + //add the unique contact + GIM_CONTACT * pcontact = 0; + GIM_DYNARRAY_PUSH_EMPTY(GIM_CONTACT,(*dest_contacts)); + pcontact = GIM_DYNARRAY_POINTER_LAST(GIM_CONTACT,(*dest_contacts)); + //set the first contact + GIM_COPY_CONTACTS(pcontact, psource_contacts); + + if(source_count==1) return; + //scale the first contact + VEC_SCALE(pcontact->m_normal,pcontact->m_depth,pcontact->m_normal); + + psource_contacts++; + + //Average the contacts + GUINT32 i; + for(i=1;im_point,pcontact->m_point,psource_contacts->m_point); + VEC_ACCUM(pcontact->m_normal,psource_contacts->m_depth,psource_contacts->m_normal); + psource_contacts++; + } + + GREAL divide_average = 1.0f/((GREAL)source_count); + + VEC_SCALE(pcontact->m_point,divide_average,pcontact->m_point); + + pcontact->m_depth = VEC_DOT(pcontact->m_normal,pcontact->m_normal)*divide_average; + GIM_SQRT(pcontact->m_depth,pcontact->m_depth); + + VEC_NORMALIZE(pcontact->m_normal); + + /*GREAL normal_len; + VEC_INV_LENGTH(pcontact->m_normal,normal_len); + VEC_SCALE(pcontact->m_normal,normal_len,pcontact->m_normal); + + //Deep = LEN(normal)/SQRT(source_count) + GIM_SQRT(divide_average,divide_average); + pcontact->m_depth = divide_average/normal_len; + */ +} + + + diff --git a/libs/ode-0.16.1/GIMPACT/src/gim_math.cpp b/libs/ode-0.16.1/GIMPACT/src/gim_math.cpp new file mode 100644 index 0000000..18efb2c --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/src/gim_math.cpp @@ -0,0 +1,60 @@ +/* +----------------------------------------------------------------------------- +This source file is part of GIMPACT Library. + +For the latest info, see http://gimpact.sourceforge.net/ + +Copyright (c) 2006 Francisco Leon. C.C. 80087371. +email: projectileman@yahoo.com + + This library is free software; you can redistribute it and/or + modify it under the terms of EITHER: + (1) The GNU Lesser General Public License as published by the Free + Software Foundation; either version 2.1 of the License, or (at + your option) any later version. The text of the GNU Lesser + General Public License is included with this library in the + file GIMPACT-LICENSE-LGPL.TXT. + (2) The BSD-style license that is included with this library in + the file GIMPACT-LICENSE-BSD.TXT. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files + GIMPACT-LICENSE-LGPL.TXT and GIMPACT-LICENSE-BSD.TXT for more details. + +----------------------------------------------------------------------------- +*/ + + +#include "GIMPACT/gim_math.h" +#include "stdlib.h" +#include "time.h" + + +GREAL gim_inv_sqrt(GREAL f) +{ + GREAL r; + GIM_INV_SQRT(f,r); + return r; +} + +GREAL gim_sqrt(GREAL f) +{ + GREAL r; + GIM_SQRT(f,r); + return r; +} + +//!Initializes mathematical functions +void gim_init_math() +{ + srand( static_cast< unsigned int >( time( 0 ) ) ); +} + +//! Generates an unit random +GREAL gim_unit_random() +{ + GREAL rn = static_cast< GREAL >( rand() ); + rn/=(GREAL)RAND_MAX; + return rn; +} diff --git a/libs/ode-0.16.1/GIMPACT/src/gim_memory.cpp b/libs/ode-0.16.1/GIMPACT/src/gim_memory.cpp new file mode 100644 index 0000000..cc5188d --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/src/gim_memory.cpp @@ -0,0 +1,878 @@ + +/* +----------------------------------------------------------------------------- +This source file is part of GIMPACT Library. + +For the latest info, see http://gimpact.sourceforge.net/ + +Copyright (c) 2006 Francisco Leon. C.C. 80087371. +email: projectileman@yahoo.com + + This library is free software; you can redistribute it and/or + modify it under the terms of EITHER: + (1) The GNU Lesser General Public License as published by the Free + Software Foundation; either version 2.1 of the License, or (at + your option) any later version. The text of the GNU Lesser + General Public License is included with this library in the + file GIMPACT-LICENSE-LGPL.TXT. + (2) The BSD-style license that is included with this library in + the file GIMPACT-LICENSE-BSD.TXT. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files + GIMPACT-LICENSE-LGPL.TXT and GIMPACT-LICENSE-BSD.TXT for more details. + +----------------------------------------------------------------------------- +*/ + + +#include +#include +#include "GIMPACT/gim_memory.h" +#include +#include "config.h" +//#include "malloc.h" +//#include "mm_malloc.h" + +static gim_alloc_function *g_allocfn = 0; +// static gim_alloca_function *g_allocafn = 0; -- a nonsense +static gim_realloc_function *g_reallocfn = 0; +static gim_free_function *g_freefn = 0; + + +#define VALIDATE_BUFFER_MANAGER(buffer_managers,buffer_manager_id)\ + if(buffer_manager_id>=G_BUFFER_MANAGER__MAX) return G_BUFFER_OP_INVALID;\ + GBUFFER_MANAGER_DATA * bm_data;\ + gim_get_buffer_manager_data(buffer_managers,buffer_manager_id,&bm_data);\ + if(bm_data == 0) return G_BUFFER_OP_INVALID;\ + +#define VALIDATE_BUFFER_ID_PT(buffer_id)\ + GBUFFER_MANAGER_DATA * bm_data = buffer_id->m_bm_data;\ + if(bm_data == 0) return G_BUFFER_OP_INVALID;\ + if(buffer_id->m_buffer_id>=bm_data->m_buffer_array.m_size) return G_BUFFER_OP_INVALID;\ + GBUFFER_DATA * pbuffer = GIM_DYNARRAY_POINTER(GBUFFER_DATA,bm_data->m_buffer_array);\ + pbuffer += buffer_id->m_buffer_id;\ + if(pbuffer->m_buffer_handle==0) return G_BUFFER_OP_INVALID;\ + + +void GIM_BUFFER_ARRAY_DESTROY(GBUFFER_ARRAY & array_data) +{ + gim_buffer_array_unlock(&array_data); + gim_buffer_free(&(array_data).m_buffer_id); +} + +void GIM_DYNARRAY_DESTROY(GDYNAMIC_ARRAY & array_data) +{ + if(array_data.m_pdata != 0) + { + gim_free(array_data.m_pdata,0); + array_data.m_reserve_size = 0; + array_data.m_size = 0; + array_data.m_pdata = 0; + } +} + +void gim_set_alloc_handler (gim_alloc_function *fn) +{ + g_allocfn = fn; +} + +/* -- a nonsense +void gim_set_alloca_handler (gim_alloca_function *fn) +{ + g_allocafn = fn; +} +*/ + +void gim_set_realloc_handler (gim_realloc_function *fn) +{ + g_reallocfn = fn; +} + +void gim_set_free_handler (gim_free_function *fn) +{ + g_freefn = fn; +} + +gim_alloc_function *gim_get_alloc_handler() +{ + return g_allocfn; +} + +/* -- a nonsense +gim_alloca_function *gim_get_alloca_handler() +{ + return g_allocafn; +} +*/ + +gim_realloc_function *gim_get_realloc_handler () +{ + return g_reallocfn; +} + + +gim_free_function *gim_get_free_handler () +{ + return g_freefn; +} + + +void * gim_alloc(size_t size) +{ + void * ptr; +/* + if (g_allocfn) + { + ptr = g_allocfn(size); + } + else +*/ + { + ptr = malloc(size);//_mm_malloc(size,0);*/ + } + assert(ptr); + return ptr; +} + +/* -- a nonsense +void * gim_alloca(size_t size) +{ + if (g_allocafn) return g_allocafn(size); else return alloca(size); +} +*/ + +void * gim_realloc(void *ptr, size_t oldsize, size_t newsize) +{ + /*if (g_reallocfn) return g_reallocfn(ptr,oldsize,newsize); + else return realloc(ptr,newsize);*/ + //return realloc(ptr,newsize); + void * newptr = gim_alloc(newsize); + size_t copysize = newsize> oldsize? oldsize: newsize; + memcpy(newptr,ptr,copysize); + gim_free(ptr,oldsize); + return newptr; +} + +void gim_free(void *ptr, size_t size) +{ + if (!ptr) return; +/* -- if custom allocation function is not used, custom free must not be used too + if (g_freefn) + { + g_freefn(ptr,size); + } + else +*/ + { + free(ptr);//_mm_free(ptr); + } +} + +///******************************* BUFFER MANAGERS ******************************/// + +//!** Basic buffer prototype functions + +static GPTR _system_buffer_alloc_function(GUINT32 size,int usage) +{ + void * newdata = gim_alloc(size); + memset(newdata,0,size); + return (GPTR)newdata; +} + +static GPTR _system_buffer_alloc_data_function(const void * pdata,GUINT32 size,int usage) +{ + void * newdata = gim_alloc(size); + memcpy(newdata,pdata,size); + return (GPTR)(newdata); +} + +static GPTR _system_buffer_realloc_function(GPTR buffer_handle,GUINT32 oldsize,int old_usage,GUINT32 newsize,int new_usage) +{ + void * newdata = gim_realloc(buffer_handle,oldsize,newsize); + return (GPTR)(newdata); +} + +static void _system_buffer_free_function(GPTR buffer_handle,GUINT32 size) +{ + gim_free(buffer_handle,size); +} + +static char * _system_lock_buffer_function(GPTR buffer_handle,int access) +{ + return (char * )(buffer_handle); +} + + +static void _system_unlock_buffer_function(GPTR buffer_handle) +{ +} + +static void _system_download_from_buffer_function( + GPTR source_buffer_handle, + GUINT32 source_pos, + void * destdata, + GUINT32 copysize) +{ + char * pdata; + pdata = (char *)source_buffer_handle; + memcpy(destdata,pdata+source_pos,copysize); +} + +static void _system_upload_to_buffer_function( + GPTR dest_buffer_handle, + GUINT32 dest_pos, + void * sourcedata, + GUINT32 copysize) +{ + char * pdata; + pdata = (char * )dest_buffer_handle; + memcpy(pdata+dest_pos,sourcedata,copysize); +} + +static void _system_copy_buffers_function( + GPTR source_buffer_handle, + GUINT32 source_pos, + GPTR dest_buffer_handle, + GUINT32 dest_pos, + GUINT32 copysize) +{ + char * pdata1,*pdata2; + pdata1 = (char *)source_buffer_handle; + pdata2 = (char *)dest_buffer_handle; + memcpy(pdata2+dest_pos,pdata1+source_pos,copysize); +} + +static GPTR _shared_buffer_alloc_function(GUINT32 size,int usage) +{ + return 0; +} + +static GPTR _shared_buffer_alloc_data_function(const void * pdata,GUINT32 size,int usage) +{ + return (GPTR)pdata; +} + +#if 0 +static GPTR _shared_buffer_realloc_function(GPTR buffer_handle,GUINT32 oldsize,int old_usage,GUINT32 newsize,int new_usage) +{ + return 0; +} +#endif + +static void _shared_buffer_free_function(GPTR buffer_handle,GUINT32 size) +{ +} + +static inline int _is_buffer_manager_data_active(GBUFFER_MANAGER_DATA * bm_data) +{ + return bm_data->m_buffer_array.m_pdata != 0; +} + +static inline void _init_buffer_manager_data(GBUFFER_MANAGER_DATA * bm_data) +{ + bm_data->m_buffer_array.m_pdata = 0; +} + +static const GBUFFER_MANAGER_PROTOTYPE g_bm_prototypes[G_BUFFER_MANAGER__MAX] = +{ + { + &_system_buffer_alloc_function, // alloc_fn; + &_system_buffer_alloc_data_function, // alloc_data_fn; + &_system_buffer_realloc_function, // realloc_fn; + &_system_buffer_free_function, // free_fn; + &_system_lock_buffer_function, // lock_buffer_fn; + &_system_unlock_buffer_function, // unlock_buffer_fn; + &_system_download_from_buffer_function, // download_from_buffer_fn; + &_system_upload_to_buffer_function, // upload_to_buffer_fn; + &_system_copy_buffers_function, // copy_buffers_fn; + }, // G_BUFFER_MANAGER_SYSTEM + + { + &_shared_buffer_alloc_function, // alloc_fn; + &_shared_buffer_alloc_data_function, // alloc_data_fn; + &_system_buffer_realloc_function, // realloc_fn; + &_shared_buffer_free_function, // free_fn; + &_system_lock_buffer_function, // lock_buffer_fn; + &_system_unlock_buffer_function, // unlock_buffer_fn; + &_system_download_from_buffer_function, // download_from_buffer_fn; + &_system_upload_to_buffer_function, // upload_to_buffer_fn; + &_system_copy_buffers_function, // copy_buffers_fn; + }, // G_BUFFER_MANAGER_SHARED +}; + +int gim_is_buffer_manager_active(GBUFFER_MANAGER_DATA buffer_managers[], + GUINT32 buffer_manager_id) +{ + GBUFFER_MANAGER_DATA * bm_data; + bm_data = &buffer_managers[buffer_manager_id]; + return _is_buffer_manager_data_active(bm_data); +} + +//!** Buffer manager operations +void gim_create_buffer_manager(GBUFFER_MANAGER_DATA buffer_managers[], + GUINT32 buffer_manager_id) +{ + GBUFFER_MANAGER_DATA * bm_data; + bm_data = &buffer_managers[buffer_manager_id]; + + if (_is_buffer_manager_data_active(bm_data)) + { + gim_destroy_buffer_manager(buffer_managers, buffer_manager_id); + } + + //CREATE ARRAYS + GIM_DYNARRAY_CREATE(GBUFFER_DATA,bm_data->m_buffer_array,G_ARRAY_BUFFERMANAGER_INIT_SIZE); + GIM_DYNARRAY_CREATE(GUINT32,bm_data->m_free_positions,G_ARRAY_BUFFERMANAGER_INIT_SIZE); + bm_data->m_prototype = g_bm_prototypes + buffer_manager_id; + bm_data->m_buffer_manager_id = buffer_manager_id; +} + +void gim_destroy_buffer_manager(GBUFFER_MANAGER_DATA buffer_managers[], GUINT32 buffer_manager_id) +{ + GBUFFER_MANAGER_DATA * bm_data; + gim_get_buffer_manager_data(buffer_managers,buffer_manager_id,&bm_data); + if(bm_data == 0) return; + //Destroy all buffers + + GBUFFER_DATA * buffers = GIM_DYNARRAY_POINTER(GBUFFER_DATA,bm_data->m_buffer_array); + GUINT32 i, buffer_count = bm_data->m_buffer_array.m_size; + for (i=0;im_buffer_handle!=0) //Is active + { + // free handle + bm_data->m_prototype->free_fn(current_buffer->m_buffer_handle,current_buffer->m_size); + } + } + + //destroy buffer array + GIM_DYNARRAY_DESTROY(bm_data->m_buffer_array); + //destroy free positions + GIM_DYNARRAY_DESTROY(bm_data->m_free_positions); +} +void gim_get_buffer_manager_data(GBUFFER_MANAGER_DATA buffer_managers[], + GUINT32 buffer_manager_id,GBUFFER_MANAGER_DATA ** pbm_data) +{ + GBUFFER_MANAGER_DATA * bm_data; + bm_data = &buffer_managers[buffer_manager_id]; + + if (_is_buffer_manager_data_active(bm_data)) + { + *pbm_data = bm_data; + } + else + { + *pbm_data = 0; + } +} + +void gim_init_buffer_managers(GBUFFER_MANAGER_DATA buffer_managers[]) +{ + GUINT32 i; + for (i=0;im_free_positions.m_size>0)\ + { + GUINT32 * _pointer = GIM_DYNARRAY_POINTER(GUINT32,buffer_manager->m_free_positions); + buffer_id = _pointer[buffer_manager->m_free_positions.m_size-1]; + GIM_DYNARRAY_POP_ITEM(buffer_manager->m_free_positions); + } + else + { + buffer_id = buffer_manager->m_buffer_array.m_size; + GIM_DYNARRAY_PUSH_EMPTY(GBUFFER_DATA,buffer_manager->m_buffer_array); + } +} + +GINT32 _validate_buffer_id(GBUFFER_ID * buffer_id,GBUFFER_DATA ** ppbuffer,GBUFFER_MANAGER_DATA ** pbm_data) +{ + VALIDATE_BUFFER_ID_PT(buffer_id) + *ppbuffer = pbuffer; + *pbm_data = bm_data; + return G_BUFFER_OP_SUCCESS; +} + +GUINT32 gim_create_buffer( + GBUFFER_MANAGER_DATA buffer_managers[], + GUINT32 buffer_manager_id, + GUINT32 buffer_size, + int usage, + GBUFFER_ID * buffer_id) +{ + VALIDATE_BUFFER_MANAGER(buffer_managers,buffer_manager_id) + + GPTR newbufferhandle = bm_data->m_prototype->alloc_fn(buffer_size,usage); + if(newbufferhandle==0) return G_BUFFER_OP_INVALID; + + GET_AVALIABLE_BUFFER_ID(bm_data,buffer_id->m_buffer_id); + buffer_id->m_bm_data = bm_data; + + GBUFFER_DATA * pbuffer = GIM_DYNARRAY_POINTER(GBUFFER_DATA,bm_data->m_buffer_array); + pbuffer += buffer_id->m_buffer_id ; + pbuffer->m_buffer_handle = newbufferhandle; + pbuffer->m_size = buffer_size; + pbuffer->m_usage = usage; + pbuffer->m_lock_count = 0; + pbuffer->m_refcount = 0; + pbuffer->m_mapped_pointer = 0; + + //set shadow buffer if needed + + if(usage == G_MU_STATIC_READ || + usage == G_MU_STATIC_READ_DYNAMIC_WRITE|| + usage == G_MU_STATIC_READ_DYNAMIC_WRITE_COPY) + { + gim_create_common_buffer(buffer_managers,buffer_size,&pbuffer->m_shadow_buffer); + } + else + { + pbuffer->m_shadow_buffer.m_bm_data = 0; + pbuffer->m_shadow_buffer.m_buffer_id = G_UINT_INFINITY; + } + return G_BUFFER_OP_SUCCESS; +} + + +GUINT32 gim_create_buffer_from_data( + GBUFFER_MANAGER_DATA buffer_managers[], + GUINT32 buffer_manager_id, + const void * pdata, + GUINT32 buffer_size, + int usage, + GBUFFER_ID * buffer_id) +{ + VALIDATE_BUFFER_MANAGER(buffer_managers,buffer_manager_id) + + GPTR newbufferhandle = bm_data->m_prototype->alloc_data_fn(pdata,buffer_size,usage); + if(newbufferhandle==0) return G_BUFFER_OP_INVALID; + + GET_AVALIABLE_BUFFER_ID(bm_data,buffer_id->m_buffer_id); + buffer_id->m_bm_data = bm_data; + + GBUFFER_DATA * pbuffer = GIM_DYNARRAY_POINTER(GBUFFER_DATA,bm_data->m_buffer_array); + pbuffer += buffer_id->m_buffer_id ; + pbuffer->m_buffer_handle = newbufferhandle; + pbuffer->m_size = buffer_size; + pbuffer->m_usage = usage; + pbuffer->m_lock_count = 0; + pbuffer->m_mapped_pointer = 0; + pbuffer->m_refcount = 0; + + //set shadow buffer if needed + + if(usage == G_MU_STATIC_READ || + usage == G_MU_STATIC_READ_DYNAMIC_WRITE|| + usage == G_MU_STATIC_READ_DYNAMIC_WRITE_COPY) + { + gim_create_common_buffer_from_data(buffer_managers,pdata,buffer_size,&pbuffer->m_shadow_buffer); + } + else + { + pbuffer->m_shadow_buffer.m_bm_data = 0; + pbuffer->m_shadow_buffer.m_buffer_id = G_UINT_INFINITY; + } + return G_BUFFER_OP_SUCCESS; +} + +GUINT32 gim_create_common_buffer(GBUFFER_MANAGER_DATA buffer_managers[], + GUINT32 buffer_size, GBUFFER_ID * buffer_id) +{ + return gim_create_buffer(buffer_managers,G_BUFFER_MANAGER_SYSTEM,buffer_size,G_MU_DYNAMIC_READ_WRITE,buffer_id); +} + +GUINT32 gim_create_common_buffer_from_data(GBUFFER_MANAGER_DATA buffer_managers[], + const void * pdata, GUINT32 buffer_size, GBUFFER_ID * buffer_id) +{ + return gim_create_buffer_from_data(buffer_managers,G_BUFFER_MANAGER_SYSTEM,pdata,buffer_size,G_MU_DYNAMIC_READ_WRITE,buffer_id); +} + +GUINT32 gim_create_shared_buffer_from_data(GBUFFER_MANAGER_DATA buffer_managers[], + const void * pdata, GUINT32 buffer_size, GBUFFER_ID * buffer_id) +{ + return gim_create_buffer_from_data(buffer_managers,G_BUFFER_MANAGER_SHARED,pdata,buffer_size,G_MU_DYNAMIC_READ_WRITE,buffer_id); +} + +GINT32 gim_buffer_realloc(GBUFFER_ID * buffer_id,GUINT32 newsize) +{ + VALIDATE_BUFFER_ID_PT(buffer_id) + if(pbuffer->m_lock_count>0) return G_BUFFER_OP_INVALID; + GPTR newhandle = buffer_id->m_bm_data->m_prototype->realloc_fn( + pbuffer->m_buffer_handle,pbuffer->m_size,pbuffer->m_usage,newsize,pbuffer->m_usage); + if(newhandle==0) return G_BUFFER_OP_INVALID; + pbuffer->m_buffer_handle = newhandle; + //realloc shadow buffer if any + gim_buffer_realloc(&pbuffer->m_shadow_buffer,newsize); + return G_BUFFER_OP_SUCCESS; +} + +GINT32 gim_buffer_add_ref(GBUFFER_ID * buffer_id) +{ + VALIDATE_BUFFER_ID_PT(buffer_id) + pbuffer->m_refcount++; + return G_BUFFER_OP_SUCCESS; +} + +GINT32 gim_buffer_free(GBUFFER_ID * buffer_id) +{ + VALIDATE_BUFFER_ID_PT(buffer_id) + if(pbuffer->m_lock_count>0) return G_BUFFER_OP_INVALID; + if(pbuffer->m_refcount>0) pbuffer->m_refcount--; + if(pbuffer->m_refcount>0) return G_BUFFER_OP_STILLREFCOUNTED; + + buffer_id->m_bm_data->m_prototype->free_fn( + pbuffer->m_buffer_handle,pbuffer->m_size); + //destroy shadow buffer if needed + gim_buffer_free(&pbuffer->m_shadow_buffer); + // Obtain a free slot index for a new buffer + GIM_DYNARRAY_PUSH_ITEM(GUINT32,bm_data->m_free_positions,buffer_id->m_buffer_id); + pbuffer->m_buffer_handle = 0; + pbuffer->m_size = 0; + pbuffer->m_shadow_buffer.m_bm_data = 0; + pbuffer->m_shadow_buffer.m_buffer_id = G_UINT_INFINITY; + return G_BUFFER_OP_SUCCESS; +} + +GINT32 gim_lock_buffer(GBUFFER_ID * buffer_id,int access,char ** map_pointer) +{ + VALIDATE_BUFFER_ID_PT(buffer_id) + if(pbuffer->m_lock_count>0) + { + if(pbuffer->m_access!=access) return G_BUFFER_OP_INVALID; + pbuffer->m_lock_count++; + *map_pointer = pbuffer->m_mapped_pointer; + return G_BUFFER_OP_SUCCESS; + } + + pbuffer->m_access = access; + + GUINT32 result; + if(pbuffer->m_usage==G_MU_STATIC_WRITE) + { + *map_pointer = 0;///no access + return G_BUFFER_OP_INVALID; + } + else if(pbuffer->m_usage==G_MU_STATIC_READ) + { + if(pbuffer->m_access == G_MA_READ_ONLY) + { + result = gim_lock_buffer(&pbuffer->m_shadow_buffer,access,map_pointer); + if(result!= G_BUFFER_OP_SUCCESS) return G_BUFFER_OP_INVALID; + pbuffer->m_mapped_pointer = *map_pointer; + pbuffer->m_lock_count++; + } + else + { + *map_pointer = 0; + return G_BUFFER_OP_INVALID; + } + } + else if(pbuffer->m_usage==G_MU_STATIC_READ_DYNAMIC_WRITE) + { + if(pbuffer->m_access == G_MA_READ_ONLY) + { + result = gim_lock_buffer(&pbuffer->m_shadow_buffer,access,map_pointer); + if(result!= G_BUFFER_OP_SUCCESS) return G_BUFFER_OP_INVALID; + pbuffer->m_mapped_pointer = *map_pointer; + pbuffer->m_lock_count++; + } + else if(pbuffer->m_access == G_MA_WRITE_ONLY) + { + pbuffer->m_mapped_pointer = buffer_id->m_bm_data->m_prototype->lock_buffer_fn( + pbuffer->m_buffer_handle,access); + *map_pointer = pbuffer->m_mapped_pointer; + pbuffer->m_lock_count++; + } + else if(pbuffer->m_access == G_MA_READ_WRITE) + { + *map_pointer = 0; + return G_BUFFER_OP_INVALID; + } + } + else if(pbuffer->m_usage==G_MU_STATIC_READ_DYNAMIC_WRITE_COPY) + { + result = gim_lock_buffer(&pbuffer->m_shadow_buffer,access,map_pointer); + if(result!= G_BUFFER_OP_SUCCESS) return G_BUFFER_OP_INVALID; + pbuffer->m_mapped_pointer = *map_pointer; + pbuffer->m_lock_count++; + } + else if(pbuffer->m_usage==G_MU_STATIC_WRITE_DYNAMIC_READ) + { + if(pbuffer->m_access == G_MA_READ_ONLY) + { + pbuffer->m_mapped_pointer = buffer_id->m_bm_data->m_prototype->lock_buffer_fn( + pbuffer->m_buffer_handle,access); + *map_pointer = pbuffer->m_mapped_pointer; + pbuffer->m_lock_count++; + } + else + { + *map_pointer = 0; + return G_BUFFER_OP_INVALID; + } + } + else if(pbuffer->m_usage==G_MU_DYNAMIC_READ_WRITE) + { + pbuffer->m_mapped_pointer = buffer_id->m_bm_data->m_prototype->lock_buffer_fn( + pbuffer->m_buffer_handle,access); + *map_pointer = pbuffer->m_mapped_pointer; + pbuffer->m_lock_count++; + } + return G_BUFFER_OP_SUCCESS; +} + +GINT32 gim_unlock_buffer(GBUFFER_ID * buffer_id) +{ + VALIDATE_BUFFER_ID_PT(buffer_id) + if(pbuffer->m_lock_count==0) return G_BUFFER_OP_INVALID; + + if(pbuffer->m_lock_count>1) + { + pbuffer->m_lock_count--; + return G_BUFFER_OP_SUCCESS; + } + + + GUINT32 result; + if(pbuffer->m_usage==G_MU_STATIC_WRITE) + { + pbuffer->m_mapped_pointer = 0; + pbuffer->m_lock_count=0; + return G_BUFFER_OP_INVALID; + } + else if(pbuffer->m_usage==G_MU_STATIC_READ) + { + if(pbuffer->m_access == G_MA_READ_ONLY) + { + result = gim_unlock_buffer(&pbuffer->m_shadow_buffer); + if(result!= G_BUFFER_OP_SUCCESS) return G_BUFFER_OP_INVALID; + pbuffer->m_mapped_pointer = 0; + pbuffer->m_lock_count=0; + } + else + { + pbuffer->m_mapped_pointer = 0; + pbuffer->m_lock_count=0; + return G_BUFFER_OP_INVALID; + } + } + else if(pbuffer->m_usage==G_MU_STATIC_READ_DYNAMIC_WRITE) + { + if(pbuffer->m_access == G_MA_READ_ONLY) + { + result = gim_unlock_buffer(&pbuffer->m_shadow_buffer); + if(result!= G_BUFFER_OP_SUCCESS) return G_BUFFER_OP_INVALID; + pbuffer->m_mapped_pointer = 0; + pbuffer->m_lock_count=0; + } + else if(pbuffer->m_access == G_MA_WRITE_ONLY) + { + buffer_id->m_bm_data->m_prototype->unlock_buffer_fn( + pbuffer->m_buffer_handle); + pbuffer->m_mapped_pointer = 0; + pbuffer->m_lock_count=0; + } + else if(pbuffer->m_access == G_MA_READ_WRITE) + { + pbuffer->m_mapped_pointer = 0; + pbuffer->m_lock_count=0; + return G_BUFFER_OP_INVALID; + } + } + else if(pbuffer->m_usage==G_MU_STATIC_READ_DYNAMIC_WRITE_COPY) + { + result = gim_unlock_buffer(&pbuffer->m_shadow_buffer); + if(result!= G_BUFFER_OP_SUCCESS) return G_BUFFER_OP_INVALID; + pbuffer->m_mapped_pointer = 0; + pbuffer->m_lock_count=0; + if(pbuffer->m_access == G_MA_WRITE_ONLY||pbuffer->m_access == G_MA_READ_WRITE) + { + gim_copy_buffers(&pbuffer->m_shadow_buffer,0,buffer_id,0,pbuffer->m_size); + } + } + else if(pbuffer->m_usage==G_MU_STATIC_WRITE_DYNAMIC_READ) + { + if(pbuffer->m_access == G_MA_READ_ONLY) + { + buffer_id->m_bm_data->m_prototype->unlock_buffer_fn( + pbuffer->m_buffer_handle); + pbuffer->m_mapped_pointer = 0; + pbuffer->m_lock_count=0; + } + else + { + pbuffer->m_mapped_pointer = 0; + pbuffer->m_lock_count=0; + return G_BUFFER_OP_INVALID; + } + } + else if(pbuffer->m_usage==G_MU_DYNAMIC_READ_WRITE) + { + buffer_id->m_bm_data->m_prototype->unlock_buffer_fn( + pbuffer->m_buffer_handle); + pbuffer->m_mapped_pointer = 0; + pbuffer->m_lock_count=0; + } + return G_BUFFER_OP_SUCCESS; +} + +GINT32 gim_get_buffer_size(GBUFFER_ID * buffer_id,GUINT32 * buffer_size) +{ + VALIDATE_BUFFER_ID_PT(buffer_id) + *buffer_size = pbuffer->m_size; + return G_BUFFER_OP_SUCCESS; +} + +GINT32 gim_get_buffer_is_locked(GBUFFER_ID * buffer_id,GUINT32 * lock_count) +{ + VALIDATE_BUFFER_ID_PT(buffer_id) + *lock_count = pbuffer->m_lock_count; + return G_BUFFER_OP_SUCCESS; +} + + +GINT32 gim_download_from_buffer( + GBUFFER_ID * buffer_id, + GUINT32 source_pos, + void * destdata, + GUINT32 copysize) +{ + VALIDATE_BUFFER_ID_PT(buffer_id) + buffer_id->m_bm_data->m_prototype->download_from_buffer_fn( + pbuffer->m_buffer_handle,source_pos,destdata,copysize); + return G_BUFFER_OP_SUCCESS; +} + +GINT32 gim_upload_to_buffer( + GBUFFER_ID * buffer_id, + GUINT32 dest_pos, + void * sourcedata, + GUINT32 copysize) +{ + VALIDATE_BUFFER_ID_PT(buffer_id) + buffer_id->m_bm_data->m_prototype->upload_to_buffer_fn( + pbuffer->m_buffer_handle,dest_pos,sourcedata,copysize); + return G_BUFFER_OP_SUCCESS; +} + +GINT32 gim_copy_buffers( + GBUFFER_ID * source_buffer_id, + GUINT32 source_pos, + GBUFFER_ID * dest_buffer_id, + GUINT32 dest_pos, + GUINT32 copysize) +{ + GBUFFER_MANAGER_DATA * bm_data1,* bm_data2; + GBUFFER_DATA * pbuffer1, * pbuffer2; + void * tempdata; + if(_validate_buffer_id(source_buffer_id,&pbuffer1,&bm_data1)!= G_BUFFER_OP_SUCCESS) return G_BUFFER_OP_INVALID; + + if(_validate_buffer_id(dest_buffer_id,&pbuffer2,&bm_data2)!= G_BUFFER_OP_SUCCESS) return G_BUFFER_OP_INVALID; + + if((bm_data1->m_buffer_manager_id == bm_data2->m_buffer_manager_id)|| + (bm_data1->m_buffer_manager_id == G_BUFFER_MANAGER_SYSTEM && bm_data2->m_buffer_manager_id == G_BUFFER_MANAGER_SHARED)|| + (bm_data1->m_buffer_manager_id == G_BUFFER_MANAGER_SHARED && bm_data2->m_buffer_manager_id == G_BUFFER_MANAGER_SYSTEM) + ) + {//smooth copy + bm_data1->m_prototype->copy_buffers_fn( + pbuffer1->m_buffer_handle,source_pos,pbuffer2->m_buffer_handle,dest_pos,copysize); + } + else if(bm_data1->m_buffer_manager_id == G_BUFFER_MANAGER_SYSTEM || + bm_data1->m_buffer_manager_id == G_BUFFER_MANAGER_SHARED) + { + //hard copy + tempdata = (void *)pbuffer1->m_buffer_handle; + //upload data + bm_data2->m_prototype->upload_to_buffer_fn( + pbuffer2->m_buffer_handle,dest_pos,tempdata,copysize); + } + else + { + //very hard copy + void * tempdata = gim_alloc(copysize); + //download data + bm_data1->m_prototype->download_from_buffer_fn( + pbuffer1->m_buffer_handle,source_pos,tempdata,copysize); + + //upload data + bm_data2->m_prototype->upload_to_buffer_fn( + pbuffer2->m_buffer_handle,dest_pos,tempdata,copysize); + //delete temp buffer + gim_free(tempdata,copysize); + } + return G_BUFFER_OP_SUCCESS; +} + +GINT32 gim_buffer_array_lock(GBUFFER_ARRAY * array_data, int access) +{ + if(array_data->m_buffer_data != 0) return G_BUFFER_OP_SUCCESS; + GINT32 result = gim_lock_buffer(&array_data->m_buffer_id,access,&array_data->m_buffer_data); + if(result!= G_BUFFER_OP_SUCCESS) return result; + array_data->m_buffer_data += array_data->m_byte_offset; + return result; +} + +GINT32 gim_buffer_array_unlock(GBUFFER_ARRAY * array_data) +{ + if(array_data->m_buffer_data == 0) return G_BUFFER_OP_SUCCESS; + GINT32 result = gim_unlock_buffer(&array_data->m_buffer_id); + if(result!= G_BUFFER_OP_SUCCESS) return result; + array_data->m_buffer_data = 0; + return result; +} + +void gim_buffer_array_copy_ref(GBUFFER_ARRAY * source_data,GBUFFER_ARRAY * dest_data) +{ + dest_data->m_buffer_id.m_buffer_id = source_data->m_buffer_id.m_buffer_id; + dest_data->m_buffer_id.m_bm_data = source_data->m_buffer_id.m_bm_data; + dest_data->m_buffer_data = 0; + dest_data->m_byte_stride = source_data->m_byte_stride; + dest_data->m_byte_offset = source_data->m_byte_offset; + dest_data->m_element_count = source_data->m_element_count; + gim_buffer_add_ref(&dest_data->m_buffer_id); +} + +void gim_buffer_array_copy_value(GBUFFER_ARRAY * source_data, + GBUFFER_MANAGER_DATA dest_buffer_managers[],GBUFFER_ARRAY * dest_data, + GUINT32 buffer_manager_id,int usage) +{ + //Create new buffer + GUINT32 buffsize = source_data->m_element_count*source_data->m_byte_stride; + gim_create_buffer(dest_buffer_managers,buffer_manager_id,buffsize,usage,&dest_data->m_buffer_id); + + //copy ref data + dest_data->m_buffer_data = 0; + dest_data->m_byte_stride = source_data->m_byte_stride; + dest_data->m_byte_offset = 0; + dest_data->m_element_count = source_data->m_element_count; + gim_buffer_add_ref(&dest_data->m_buffer_id); + //copy buffers + gim_copy_buffers(&source_data->m_buffer_id,source_data->m_byte_offset,&dest_data->m_buffer_id,0,buffsize); +} diff --git a/libs/ode-0.16.1/GIMPACT/src/gim_tri_tri_overlap.cpp b/libs/ode-0.16.1/GIMPACT/src/gim_tri_tri_overlap.cpp new file mode 100644 index 0000000..5b4e08d --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/src/gim_tri_tri_overlap.cpp @@ -0,0 +1,251 @@ + +/* +----------------------------------------------------------------------------- +This source file is part of GIMPACT Library. + +For the latest info, see http://gimpact.sourceforge.net/ + +Copyright (c) 2006 Francisco Leon. C.C. 80087371. +email: projectileman@yahoo.com + + This library is free software; you can redistribute it and/or + modify it under the terms of EITHER: + (1) The GNU Lesser General Public License as published by the Free + Software Foundation; either version 2.1 of the License, or (at + your option) any later version. The text of the GNU Lesser + General Public License is included with this library in the + file GIMPACT-LICENSE-LGPL.TXT. + (2) The BSD-style license that is included with this library in + the file GIMPACT-LICENSE-BSD.TXT. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files + GIMPACT-LICENSE-LGPL.TXT and GIMPACT-LICENSE-BSD.TXT for more details. + +----------------------------------------------------------------------------- +*/ + +#include "GIMPACT/gim_trimesh.h" + + +#define FABS(x) (float(fabs(x))) /* implement as is fastest on your machine */ + +/* some macros */ + +#define CLASSIFY_TRIPOINTS_BY_FACE(v1,v2,v3,faceplane,out_of_face)\ +{ \ + _distances[0] = DISTANCE_PLANE_POINT(faceplane,v1);\ + _distances[1] = _distances[0] * DISTANCE_PLANE_POINT(faceplane,v2);\ + _distances[2] = _distances[0] * DISTANCE_PLANE_POINT(faceplane,v3); \ + if(_distances[1]>0.0f && _distances[2]>0.0f)\ + {\ + out_of_face = 1;\ + }\ + else\ + {\ + out_of_face = 0;\ + }\ +}\ + +/* sort so that a<=b */ +#define SORT(a,b) \ + if(a>b) \ + { \ + float c; \ + c=a; \ + a=b; \ + b=c; \ + } + + +/* this edge to edge test is based on Franlin Antonio's gem: + "Faster Line Segment Intersection", in Graphics Gems III, + pp. 199-202 */ +#define EDGE_EDGE_TEST(V0,U0,U1) \ + Bx=U0[i0]-U1[i0]; \ + By=U0[i1]-U1[i1]; \ + Cx=V0[i0]-U0[i0]; \ + Cy=V0[i1]-U0[i1]; \ + f=Ay*Bx-Ax*By; \ + d=By*Cx-Bx*Cy; \ + if((f>0 && d>=0 && d<=f) || (f<0 && d<=0 && d>=f)) \ + { \ + e=Ax*Cy-Ay*Cx; \ + if(f>0) \ + { \ + if(e>=0 && e<=f) return 1; \ + } \ + else \ + { \ + if(e<=0 && e>=f) return 1; \ + } \ + } + +#define EDGE_AGAINST_TRI_EDGES(V0,V1,U0,U1,U2) \ +{ \ + float Ax,Ay,Bx,By,Cx,Cy,e,d,f; \ + Ax=V1[i0]-V0[i0]; \ + Ay=V1[i1]-V0[i1]; \ + /* test edge U0,U1 against V0,V1 */ \ + EDGE_EDGE_TEST(V0,U0,U1); \ + /* test edge U1,U2 against V0,V1 */ \ + EDGE_EDGE_TEST(V0,U1,U2); \ + /* test edge U2,U1 against V0,V1 */ \ + EDGE_EDGE_TEST(V0,U2,U0); \ +} + +#define POINT_IN_TRI(V0,U0,U1,U2) \ +{ \ + float a,b,c,d0,d1,d2; \ + /* is T1 completly inside T2? */ \ + /* check if V0 is inside tri(U0,U1,U2) */ \ + a=U1[i1]-U0[i1]; \ + b=-(U1[i0]-U0[i0]); \ + c=-a*U0[i0]-b*U0[i1]; \ + d0=a*V0[i0]+b*V0[i1]+c; \ + \ + a=U2[i1]-U1[i1]; \ + b=-(U2[i0]-U1[i0]); \ + c=-a*U1[i0]-b*U1[i1]; \ + d1=a*V0[i0]+b*V0[i1]+c; \ + \ + a=U0[i1]-U2[i1]; \ + b=-(U0[i0]-U2[i0]); \ + c=-a*U2[i0]-b*U2[i1]; \ + d2=a*V0[i0]+b*V0[i1]+c; \ + if(d0*d1>0.0) \ + { \ + if(d0*d2>0.0) return 1; \ + } \ +} + +int coplanar_tri_tri(GIM_TRIANGLE_DATA *tri1, + GIM_TRIANGLE_DATA *tri2) +{ + short i0,i1; + /* first project onto an axis-aligned plane, that maximizes the area */ + /* of the triangles, compute indices: i0,i1. */ + PLANE_MINOR_AXES(tri1->m_planes.m_planes[0], i0, i1); + + /* test all edges of triangle 1 against the edges of triangle 2 */ + EDGE_AGAINST_TRI_EDGES(tri1->m_vertices[0],tri1->m_vertices[1],tri2->m_vertices[0],tri2->m_vertices[1],tri2->m_vertices[2]); + EDGE_AGAINST_TRI_EDGES(tri1->m_vertices[1],tri1->m_vertices[2],tri2->m_vertices[0],tri2->m_vertices[1],tri2->m_vertices[2]); + EDGE_AGAINST_TRI_EDGES(tri1->m_vertices[2],tri1->m_vertices[0],tri2->m_vertices[0],tri2->m_vertices[1],tri2->m_vertices[2]); + + /* finally, test if tri1 is totally contained in tri2 or vice versa */ + POINT_IN_HULL(tri1->m_vertices[0],(&tri2->m_planes.m_planes[1]),3,i0); + if(i0==0) return 1; + + POINT_IN_HULL(tri2->m_vertices[0],(&tri1->m_planes.m_planes[1]),3,i0); + if(i0==0) return 1; + + return 0; +} + + + +#define NEWCOMPUTE_INTERVALS(VV0,VV1,VV2,D0,D1,D2,D0D1,D0D2,A,B,C,X0,X1) \ +{ \ + if(D0D1>0.0f) \ + { \ + /* here we know that D0D2<=0.0 */ \ + /* that is D0, D1 are on the same side, D2 on the other or on the plane */ \ + A=VV2; B=(VV0-VV2)*D2; C=(VV1-VV2)*D2; X0=D2-D0; X1=D2-D1; \ + } \ + else if(D0D2>0.0f)\ + { \ + /* here we know that d0d1<=0.0 */ \ + A=VV1; B=(VV0-VV1)*D1; C=(VV2-VV1)*D1; X0=D1-D0; X1=D1-D2; \ + } \ + else if(D1*D2>0.0f || D0!=0.0f) \ + { \ + /* here we know that d0d1<=0.0 or that D0!=0.0 */ \ + A=VV0; B=(VV1-VV0)*D0; C=(VV2-VV0)*D0; X0=D0-D1; X1=D0-D2; \ + } \ + else if(D1!=0.0f) \ + { \ + A=VV1; B=(VV0-VV1)*D1; C=(VV2-VV1)*D1; X0=D1-D0; X1=D1-D2; \ + } \ + else if(D2!=0.0f) \ + { \ + A=VV2; B=(VV0-VV2)*D2; C=(VV1-VV2)*D2; X0=D2-D0; X1=D2-D1; \ + } \ + else \ + { \ + /* triangles are coplanar */ \ + return coplanar_tri_tri(tri1,tri2); \ + } \ +}\ + + + +int gim_triangle_triangle_overlap( + GIM_TRIANGLE_DATA *tri1, + GIM_TRIANGLE_DATA *tri2) +{ + vec3f _distances; + char out_of_face; + CLASSIFY_TRIPOINTS_BY_FACE(tri1->m_vertices[0],tri1->m_vertices[1],tri1->m_vertices[2],tri2->m_planes.m_planes[0],out_of_face); + if(out_of_face==1) return 0; + + CLASSIFY_TRIPOINTS_BY_FACE(tri2->m_vertices[0],tri2->m_vertices[1],tri2->m_vertices[2],tri1->m_planes.m_planes[0],out_of_face); + if(out_of_face==1) return 0; + + + float du0=0,du1=0,du2=0,dv0=0,dv1=0,dv2=0; + float D[3]; + float isect1[2], isect2[2]; + float du0du1=0,du0du2=0,dv0dv1=0,dv0dv2=0; + short index; + float vp0,vp1,vp2; + float up0,up1,up2; + float bb,cc,max; + + /* compute direction of intersection line */ + VEC_CROSS(D,tri1->m_planes.m_planes[0],tri2->m_planes.m_planes[0]); + + /* compute and index to the largest component of D */ + max=(float)FABS(D[0]); + index=0; + bb=(float)FABS(D[1]); + cc=(float)FABS(D[2]); + if(bb>max) max=bb,index=1; + if(cc>max) max=cc,index=2; + + /* this is the simplified projection onto L*/ + vp0= tri1->m_vertices[0][index]; + vp1= tri1->m_vertices[1][index]; + vp2= tri1->m_vertices[2][index]; + + up0= tri2->m_vertices[0][index]; + up1= tri2->m_vertices[1][index]; + up2= tri2->m_vertices[2][index]; + + /* compute interval for triangle 1 */ + float a,b,c,x0,x1; + NEWCOMPUTE_INTERVALS(vp0,vp1,vp2,dv0,dv1,dv2,dv0dv1,dv0dv2,a,b,c,x0,x1); + + /* compute interval for triangle 2 */ + float d,e,f,y0,y1; + NEWCOMPUTE_INTERVALS(up0,up1,up2,du0,du1,du2,du0du1,du0du2,d,e,f,y0,y1); + + float xx,yy,xxyy,tmp; + xx=x0*x1; + yy=y0*y1; + xxyy=xx*yy; + + tmp=a*xxyy; + isect1[0]=tmp+b*x1*yy; + isect1[1]=tmp+c*x0*yy; + + tmp=d*xxyy; + isect2[0]=tmp+e*xx*y1; + isect2[1]=tmp+f*xx*y0; + + SORT(isect1[0],isect1[1]); + SORT(isect2[0],isect2[1]); + + if(isect1[1] +#include "GIMPACT/gim_trimesh.h" + +GUINT32 gim_trimesh_get_triangle_count(GIM_TRIMESH * trimesh) +{ + return trimesh->m_tri_index_buffer.m_element_count/3; +} + +//! Creates the aabb set and the triangles cache +/*! + +\param trimesh +\param vertex_array +\param triindex_array +\param transformed_reply If 1, then the m_transformed_vertices is a reply of the source vertices. Else it just be a reference to the original array. +\post it copies the arrays by reference, and creates the auxiliary data (m_aabbset,m_planes_cache_buffer) +*/ +void gim_trimesh_create_from_arrays(GBUFFER_MANAGER_DATA buffer_managers[], + GIM_TRIMESH * trimesh, GBUFFER_ARRAY * vertex_array, GBUFFER_ARRAY * triindex_array,char transformed_reply) +{ + assert(trimesh); + assert(vertex_array); + assert(triindex_array); + gim_buffer_array_copy_ref(vertex_array,&trimesh->m_source_vertex_buffer); + gim_buffer_array_copy_ref(triindex_array,&trimesh->m_tri_index_buffer); + + trimesh->m_mask = GIM_TRIMESH_NEED_UPDATE;//needs update + //Create the transformed vertices + if(transformed_reply==1) + { + trimesh->m_mask |= GIM_TRIMESH_TRANSFORMED_REPLY; + gim_buffer_array_copy_value(vertex_array, + buffer_managers,&trimesh->m_transformed_vertex_buffer,G_BUFFER_MANAGER_SYSTEM,G_MU_DYNAMIC_READ_WRITE); + } + else + { + gim_buffer_array_copy_ref(vertex_array,&trimesh->m_transformed_vertex_buffer); + } + //create the box set + GUINT32 facecount = gim_trimesh_get_triangle_count(trimesh); + + gim_aabbset_alloc(&trimesh->m_aabbset,facecount); + //create the planes cache + GIM_DYNARRAY_CREATE_SIZED(GIM_TRIPLANES_CACHE,trimesh->m_planes_cache_buffer,facecount); + //Create the bitset + GIM_BITSET_CREATE_SIZED(trimesh->m_planes_cache_bitset,facecount); + //Callback is 0 + trimesh->m_update_callback = 0; + //set to identity + IDENTIFY_MATRIX_4X4(trimesh->m_transform); +} + + + +//! Create a trimesh from vertex array and an index array +/*! + +\param trimesh An uninitialized GIM_TRIMESH structure +\param vertex_array A buffer to a vec3f array +\param vertex_count +\param triindex_array +\param index_count +\param copy_vertices If 1, it copies the source vertices in another buffer. Else (0) it constructs a reference to the data. +\param copy_indices If 1, it copies the source vertices in another buffer. Else (0) it constructs a reference to the data. +\param transformed_reply If , then the m_transformed_vertices is a reply of the source vertices. Else it just be a reference to the original array. +*/ +void gim_trimesh_create_from_data(GBUFFER_MANAGER_DATA buffer_managers[], + GIM_TRIMESH * trimesh, vec3f * vertex_array, GUINT32 vertex_count,char copy_vertices, + GUINT32 * triindex_array, GUINT32 index_count,char copy_indices,char transformed_reply) +{ + GBUFFER_ARRAY buffer_vertex_array; + GBUFFER_ARRAY buffer_triindex_array; + + //Create vertices + if(copy_vertices == 1) + { + gim_create_common_buffer_from_data(buffer_managers, + vertex_array, vertex_count*sizeof(vec3f), &buffer_vertex_array.m_buffer_id); + } + else//Create a shared buffer + { + gim_create_shared_buffer_from_data(buffer_managers, + vertex_array, vertex_count*sizeof(vec3f), &buffer_vertex_array.m_buffer_id); + } + GIM_BUFFER_ARRAY_INIT_TYPE(vec3f,buffer_vertex_array,buffer_vertex_array.m_buffer_id,vertex_count); + + + //Create vertices + if(copy_indices == 1) + { + gim_create_common_buffer_from_data(buffer_managers, + triindex_array, index_count*sizeof(GUINT32), &buffer_triindex_array.m_buffer_id); + } + else//Create a shared buffer + { + gim_create_shared_buffer_from_data(buffer_managers, + triindex_array, index_count*sizeof(GUINT32), &buffer_triindex_array.m_buffer_id); + } + GIM_BUFFER_ARRAY_INIT_TYPE(GUINT32,buffer_triindex_array,buffer_triindex_array.m_buffer_id,index_count); + + gim_trimesh_create_from_arrays(buffer_managers, trimesh, + &buffer_vertex_array, &buffer_triindex_array,transformed_reply); + + ///always call this after create a buffer_array + GIM_BUFFER_ARRAY_DESTROY(buffer_vertex_array); + GIM_BUFFER_ARRAY_DESTROY(buffer_triindex_array); +} + +//! Clears auxiliary data and releases buffer arrays +void gim_trimesh_destroy(GIM_TRIMESH * trimesh) +{ + gim_aabbset_destroy(&trimesh->m_aabbset); + + GIM_DYNARRAY_DESTROY(trimesh->m_planes_cache_buffer); + GIM_DYNARRAY_DESTROY(trimesh->m_planes_cache_bitset); + + GIM_BUFFER_ARRAY_DESTROY(trimesh->m_transformed_vertex_buffer); + GIM_BUFFER_ARRAY_DESTROY(trimesh->m_source_vertex_buffer); + GIM_BUFFER_ARRAY_DESTROY(trimesh->m_tri_index_buffer); +} + +//! Copies two meshes +/*! +\pre dest_trimesh shouldn't be created +\post dest_trimesh will be created +\param source_trimesh +\param dest_trimesh +\param copy_by_reference If 1, it attach a reference to the source vertices, else it copies the vertices +\param transformed_reply IF 1, then it forces the m_trasnformed_vertices to be a reply of the source vertices +*/ +void gim_trimesh_copy(GIM_TRIMESH * source_trimesh, + GBUFFER_MANAGER_DATA dest_buffer_managers[], GIM_TRIMESH * dest_trimesh, + char copy_by_reference, char transformed_reply) +{ +/* -- trimesh can not be copied by reference until GBUFFER_MANAGER_DATA is rewritten + to be thread safe and until it is moved back to global variables. + if(copy_by_reference==1) + { + gim_trimesh_create_from_arrays(dest_trimesh, &source_trimesh->m_source_vertex_buffer, &source_trimesh->m_tri_index_buffer,transformed_reply); + } + else +*/ + { + GBUFFER_ARRAY buffer_vertex_array; + GBUFFER_ARRAY buffer_triindex_array; + + gim_buffer_array_copy_value(&source_trimesh->m_source_vertex_buffer, + dest_buffer_managers,&buffer_vertex_array,G_BUFFER_MANAGER_SYSTEM,G_MU_DYNAMIC_READ_WRITE); + + gim_buffer_array_copy_value(&source_trimesh->m_tri_index_buffer, + dest_buffer_managers,&buffer_triindex_array,G_BUFFER_MANAGER_SYSTEM,G_MU_DYNAMIC_READ_WRITE); + + gim_trimesh_create_from_arrays(dest_buffer_managers, dest_trimesh, + &buffer_vertex_array, &buffer_triindex_array,transformed_reply); + + ///always call this after create a buffer_array + GIM_BUFFER_ARRAY_DESTROY(buffer_vertex_array); + GIM_BUFFER_ARRAY_DESTROY(buffer_triindex_array); + } +} +//! Locks the trimesh for working with it +/*! +\post locks m_tri_index_buffer and m_transformed_vertex_buffer. +\param trimesh +*/ +void gim_trimesh_locks_work_data(GIM_TRIMESH * trimesh) +{ + GINT32 res; + res=gim_buffer_array_lock(&trimesh->m_tri_index_buffer,G_MA_READ_ONLY); + assert(res==G_BUFFER_OP_SUCCESS); + res=gim_buffer_array_lock(&trimesh->m_transformed_vertex_buffer,G_MA_READ_ONLY); + assert(res==G_BUFFER_OP_SUCCESS); +} + +//! unlocks the trimesh +/*! +\post unlocks m_tri_index_buffer and m_transformed_vertex_buffer. +\param trimesh +*/ +void gim_trimesh_unlocks_work_data(GIM_TRIMESH * trimesh) +{ + gim_buffer_array_unlock(&trimesh->m_tri_index_buffer); + gim_buffer_array_unlock(&trimesh->m_transformed_vertex_buffer); +} + + +//! Returns 1 if the m_transformed_vertex_buffer is a reply of m_source_vertex_buffer +char gim_trimesh_has_tranformed_reply(GIM_TRIMESH * trimesh) +{ + if(trimesh->m_mask&GIM_TRIMESH_TRANSFORMED_REPLY) return 1; + return 0; +} + +//! Returns 1 if the trimesh needs to update their aabbset and the planes cache. +char gim_trimesh_needs_update(GIM_TRIMESH * trimesh) +{ + if(trimesh->m_mask&GIM_TRIMESH_NEED_UPDATE) return 1; + return 0; +} + +//! Change the state of the trimesh for force it to update +/*! +Call it after made changes to the trimesh. +\post gim_trimesh_need_update(trimesh) will return 1 +*/ +void gim_trimesh_post_update(GIM_TRIMESH * trimesh) +{ + trimesh->m_mask |= GIM_TRIMESH_NEED_UPDATE; +} + +//kernel +#define MULT_MAT_VEC4_KERNEL(_mat,_src,_dst) MAT_DOT_VEC_3X4((_dst),(_mat),(_src)) + +//! Updates m_transformed_vertex_buffer +/*! +\pre m_transformed_vertex_buffer must be unlocked +*/ +void gim_trimesh_update_vertices(GIM_TRIMESH * trimesh) +{ + if(gim_trimesh_has_tranformed_reply(trimesh) == 0) return; //Don't perform transformation + + //Vertices + GBUFFER_ARRAY * psource_vertex_buffer = &trimesh->m_source_vertex_buffer; + GBUFFER_ARRAY * ptransformed_vertex_buffer = &trimesh->m_transformed_vertex_buffer; + //Temp transform + mat4f transform; + COPY_MATRIX_4X4(transform,trimesh->m_transform); + + GIM_PROCESS_BUFFER_ARRAY(transform,(*psource_vertex_buffer),(*ptransformed_vertex_buffer),MULT_MAT_VEC4_KERNEL,vec3f,vec3f); +} + +//! Updates m_aabbset and m_planes_cache_bitset +/*! +\pre gim_trimesh_locks_work_data must be called before +*/ +void gim_trimesh_update_aabbset(GIM_TRIMESH * trimesh) +{ + vec3f * transformed_vertices = GIM_BUFFER_ARRAY_POINTER(vec3f,trimesh->m_transformed_vertex_buffer,0); + assert(transformed_vertices); + + GUINT32 * triangle_indices = GIM_BUFFER_ARRAY_POINTER(GUINT32,trimesh->m_tri_index_buffer,0); + assert(triangle_indices); + // box set + aabb3f * paabb = trimesh->m_aabbset.m_boxes; + GUINT32 triangle_count = gim_trimesh_get_triangle_count(trimesh); + float * v1,*v2,*v3; + GUINT32 i; + for (i=0; im_planes_cache_bitset); + //Sorts set + gim_aabbset_update(&trimesh->m_aabbset); +} + +//! Updates the trimesh if needed +/*! +\post If gim_trimesh_needs_update returns 1, then it calls gim_trimesh_update_vertices and gim_trimesh_update_aabbset +*/ +void gim_trimesh_update(GIM_TRIMESH * trimesh) +{ + if(gim_trimesh_needs_update(trimesh)==0) return; + gim_trimesh_update_vertices(trimesh); + gim_trimesh_locks_work_data(trimesh); + gim_trimesh_update_aabbset(trimesh); + gim_trimesh_unlocks_work_data(trimesh); + + //Clear update flag + trimesh->m_mask &= ~GIM_TRIMESH_NEED_UPDATE; +} + +void gim_trimesh_set_tranform(GIM_TRIMESH * trimesh, mat4f transform) +{ + GREAL diff = 0.0f; + float * originaltrans = &trimesh->m_transform[0][0]; + float * newtrans = &transform[0][0]; + GUINT32 i; + for (i=0;i<16;i++) + { + diff += fabs(originaltrans[i]-newtrans[i]); + } + +// if(IS_ZERO(diff)) return ;///don't need to update + if(diff< 0.00001f) return ;///don't need to update + + COPY_MATRIX_4X4(trimesh->m_transform,transform); + + gim_trimesh_post_update(trimesh); +} + +void gim_trimesh_get_triangle_data(GIM_TRIMESH * trimesh, GUINT32 triangle_index, GIM_TRIANGLE_DATA * tri_data) +{ + vec3f * transformed_vertices = GIM_BUFFER_ARRAY_POINTER(vec3f,trimesh->m_transformed_vertex_buffer,0); + + GUINT32 * triangle_indices = GIM_BUFFER_ARRAY_POINTER(GUINT32,trimesh->m_tri_index_buffer,triangle_index*3); + + + //Copy the vertices + VEC_COPY(tri_data->m_vertices[0],transformed_vertices[triangle_indices[0]]); + VEC_COPY(tri_data->m_vertices[1],transformed_vertices[triangle_indices[1]]); + VEC_COPY(tri_data->m_vertices[2],transformed_vertices[triangle_indices[2]]); + + //Get the planes + GIM_TRIPLANES_CACHE * planes = GIM_DYNARRAY_POINTER(GIM_TRIPLANES_CACHE,trimesh->m_planes_cache_buffer); + planes += triangle_index; + + //verify planes cache + GUINT32 bit_eval; + GIM_BITSET_GET(trimesh->m_planes_cache_bitset,triangle_index,bit_eval); + if(bit_eval == 0)// Needs to calc the planes + { + //Calc the face plane + TRIANGLE_PLANE(tri_data->m_vertices[0],tri_data->m_vertices[1],tri_data->m_vertices[2],planes->m_planes[0]); + //Calc the edge 1 + EDGE_PLANE(tri_data->m_vertices[0],tri_data->m_vertices[1],(planes->m_planes[0]),(planes->m_planes[1])); + + //Calc the edge 2 + EDGE_PLANE(tri_data->m_vertices[1],tri_data->m_vertices[2],(planes->m_planes[0]),(planes->m_planes[2])); + + //Calc the edge 3 + EDGE_PLANE(tri_data->m_vertices[2],tri_data->m_vertices[0],(planes->m_planes[0]), (planes->m_planes[3])); + + //mark + GIM_BITSET_SET(trimesh->m_planes_cache_bitset,triangle_index); + } + + + VEC_COPY_4((tri_data->m_planes.m_planes[0]),(planes->m_planes[0]));//face plane + VEC_COPY_4((tri_data->m_planes.m_planes[1]),(planes->m_planes[1]));//edge1 + VEC_COPY_4((tri_data->m_planes.m_planes[2]),(planes->m_planes[2]));//edge2 + VEC_COPY_4((tri_data->m_planes.m_planes[3]),(planes->m_planes[3]));//edge3 +} + +void gim_trimesh_get_triangle_vertices(GIM_TRIMESH * trimesh, GUINT32 triangle_index, vec3f v1, vec3f v2, vec3f v3) +{ + vec3f * transformed_vertices = GIM_BUFFER_ARRAY_POINTER(vec3f,trimesh->m_transformed_vertex_buffer,0); + + GUINT32 * triangle_indices = GIM_BUFFER_ARRAY_POINTER(GUINT32,trimesh->m_tri_index_buffer,triangle_index*3); + + //Copy the vertices + if (v1 != NULL) + { + VEC_COPY(v1,transformed_vertices[triangle_indices[0]]); + } + + if (v2 != NULL) + { + VEC_COPY(v2,transformed_vertices[triangle_indices[1]]); + } + + if (v3 != NULL) + { + VEC_COPY(v3,transformed_vertices[triangle_indices[2]]); + } +} diff --git a/libs/ode-0.16.1/GIMPACT/src/gim_trimesh_capsule_collision.cpp b/libs/ode-0.16.1/GIMPACT/src/gim_trimesh_capsule_collision.cpp new file mode 100644 index 0000000..bc48aa5 --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/src/gim_trimesh_capsule_collision.cpp @@ -0,0 +1,285 @@ + +/* +----------------------------------------------------------------------------- +This source file is part of GIMPACT Library. + +For the latest info, see http://gimpact.sourceforge.net/ + +Copyright (c) 2006 Francisco Leon. C.C. 80087371. +email: projectileman@yahoo.com + + This library is free software; you can redistribute it and/or + modify it under the terms of EITHER: + (1) The GNU Lesser General Public License as published by the Free + Software Foundation; either version 2.1 of the License, or (at + your option) any later version. The text of the GNU Lesser + General Public License is included with this library in the + file GIMPACT-LICENSE-LGPL.TXT. + (2) The BSD-style license that is included with this library in + the file GIMPACT-LICENSE-BSD.TXT. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files + GIMPACT-LICENSE-LGPL.TXT and GIMPACT-LICENSE-BSD.TXT for more details. + +----------------------------------------------------------------------------- +*/ + +#include "GIMPACT/gim_trimesh.h" + +//! Utility function for find the closest point between a segment and a triangle +/*! + +\param triangle +\param s1 +\param s2 +\param contacts Contains the closest points on the segment (1,2), and the normal points to segment, and m_depth contains the distance + +\post The contacts array is not set to 0. It adds aditional contacts +*/ +void gim_closest_point_triangle_segment(GIM_TRIANGLE_DATA * triangle, vec3f s1,vec3f s2, GDYNAMIC_ARRAY * contacts) +{ + vec3f segment_points[4] = {{0}}; + vec3f closest_points[2] = {{0}}; + GUINT32 intersection_type, out_edge= 10; + GREAL dis, dis_temp,perpend; + vec4f sdiff; + + dis = DISTANCE_PLANE_POINT(triangle->m_planes.m_planes[0],s1); + dis_temp = DISTANCE_PLANE_POINT(triangle->m_planes.m_planes[0],s2); + + if(dis<=0.0f && dis_temp<=0.0f) return; + + VEC_DIFF(sdiff,s2,s1); + perpend = VEC_DOT(sdiff,triangle->m_planes.m_planes[0]); + + if(!IS_ZERO(perpend)) // Not perpendicular + { + if(dis=0.0f && dis_temp>=0.0f) + { + POINT_IN_HULL(closest_points[0],(&triangle->m_planes.m_planes[1]),3,out_edge); + + if(out_edge==0)//Point over face + { + GIM_PUSH_CONTACT((*contacts),closest_points[0] ,triangle->m_planes.m_planes[0] ,dis,0, 0, 0,0); + return; + } + } + else + { + + PLANE_CLIP_SEGMENT(s1,s2,triangle->m_planes.m_planes[0],closest_points[1]); + + POINT_IN_HULL(closest_points[1],(&triangle->m_planes.m_planes[1]),3,out_edge); + + if(out_edge==0)//Point over face + { + GIM_PUSH_CONTACT((*contacts),closest_points[0] ,triangle->m_planes.m_planes[0] ,dis,0, 0, 0,0); + return; + } + } + + } + else // Perpendicular Face + { + //out_edge=10 + //Clip segment by triangle + // Edge1 + PLANE_CLIP_SEGMENT_CLOSEST(s1,s2,triangle->m_planes.m_planes[1],segment_points[0],segment_points[1],intersection_type); + if(intersection_type==0||intersection_type==1) + { + out_edge = 0; + VEC_COPY(closest_points[0],segment_points[0]); + } + else + { + //Edge2 + PLANE_CLIP_SEGMENT_CLOSEST(segment_points[0],segment_points[1],triangle->m_planes.m_planes[2],segment_points[2],segment_points[3],intersection_type); + if(intersection_type==0||intersection_type==1) + { + out_edge = 1; + VEC_COPY(closest_points[0],segment_points[3]); + } + else + { + //Edge3 + PLANE_CLIP_SEGMENT_CLOSEST(segment_points[2],segment_points[3],triangle->m_planes.m_planes[3],closest_points[0],closest_points[1],intersection_type); + if(intersection_type==0||intersection_type==1) + { + out_edge = 2; + } + } + } + //POST closest_points[0] and closest_points[1] are inside the triangle, if out_edge>2 + if(out_edge>2) // Over triangle + { + dis = DISTANCE_PLANE_POINT(triangle->m_planes.m_planes[0],closest_points[0]); + GIM_PUSH_CONTACT((*contacts),closest_points[0] ,triangle->m_planes.m_planes[0] ,dis,0, 0, 0,0); + GIM_PUSH_CONTACT((*contacts),closest_points[1] ,triangle->m_planes.m_planes[0] ,dis,0, 0, 0,0); + return; + } + } + + //Find closest edges + out_edge = 10; + dis = G_REAL_INFINITY; + GUINT32 i; + for(i=0;i<3;i++) + { + SEGMENT_COLLISION(s1,s2,triangle->m_vertices[i],triangle->m_vertices[(i+1)%3],segment_points[0],segment_points[1]); + VEC_DIFF(sdiff,segment_points[0],segment_points[1]); + dis_temp = VEC_DOT(sdiff,sdiff); + if(dis_temp< dis) + { + dis = dis_temp; + out_edge = i; + VEC_COPY(closest_points[0],segment_points[0]); + VEC_COPY(closest_points[1],sdiff);//normal + } + } + if(out_edge>2) return ;// ???? ASSERT this please + + if(IS_ZERO(dis)) + { + //Set face plane + GIM_PUSH_CONTACT((*contacts),closest_points[0] ,triangle->m_planes.m_planes[0] ,0.0f,0, 0, 0,0); + + } + else + { + GIM_SQRT(dis,dis); + VEC_SCALE(closest_points[1],(1.0f/dis),closest_points[1]);//normal + GIM_PUSH_CONTACT((*contacts),closest_points[0] ,closest_points[1],dis,0, 0, 0,0); + } +} + + +//! Utility function for find the closest point between a capsule and a triangle +/*! + +\param triangle +\param capsule +\param contacts Contains the closest points on the capsule, and the normal points to triangle + +\post The contacts array is not set to 0. It adds aditional contacts +*/ +int gim_triangle_capsule_collision(GIM_TRIANGLE_DATA * triangle, GIM_CAPSULE_DATA * capsule, GDYNAMIC_ARRAY * contacts) +{ + GUINT32 old_contact_size = contacts->m_size; + gim_closest_point_triangle_segment(triangle,capsule->m_point1,capsule->m_point2,contacts); + + if (contacts->m_size == old_contact_size) + { + return 0; + } + + GIM_CONTACT * pcontact = GIM_DYNARRAY_POINTER(GIM_CONTACT ,(*contacts)); + pcontact+= old_contact_size; + + if(pcontact->m_depth > capsule->m_radius) + { + contacts->m_size = old_contact_size; + return 0; + } + + vec3f vec; + while(old_contact_sizem_size) + { + //Scale the normal for pointing to triangle + VEC_SCALE(pcontact->m_normal,-1.0f,pcontact->m_normal); + //Fix the contact point + VEC_SCALE(vec,capsule->m_radius,pcontact->m_normal); + VEC_SUM(pcontact->m_point,vec,pcontact->m_point); + //Fix the depth + pcontact->m_depth = capsule->m_radius - pcontact->m_depth; + + pcontact++; + old_contact_size++; + } + + return 1; +} + + +//! Trimesh Capsule collision +/*! +Find the closest primitive collided by the ray +\param trimesh +\param capsule +\param contact +\param contacts A GIM_CONTACT array. Must be initialized +*/ +void gim_trimesh_capsule_collision(GIM_TRIMESH * trimesh, GIM_CAPSULE_DATA * capsule, GDYNAMIC_ARRAY * contacts) +{ + contacts->m_size = 0; + + aabb3f test_aabb; + CALC_CAPSULE_AABB((*capsule),test_aabb); + + GDYNAMIC_ARRAY collision_result; + GIM_CREATE_BOXQUERY_LIST(collision_result); + + gim_aabbset_box_collision(&test_aabb, &trimesh->m_aabbset , &collision_result); + + if(collision_result.m_size==0) + { + GIM_DYNARRAY_DESTROY(collision_result); + } + + //collide triangles + //Locks trimesh + gim_trimesh_locks_work_data(trimesh); + //dummy contacts + GDYNAMIC_ARRAY dummycontacts; + GIM_CREATE_CONTACT_LIST(dummycontacts); + + int cresult; + unsigned int i; + GUINT32 * boxesresult = GIM_DYNARRAY_POINTER(GUINT32,collision_result); + GIM_TRIANGLE_DATA tri_data; + GUINT32 old_contact_size; + GIM_CONTACT * pcontact; + + for(i=0;im_handle1 = trimesh; + pcontact->m_handle2 = capsule; + pcontact->m_feature1 = boxesresult[i]; + pcontact->m_feature2 = 0; + pcontact++; + old_contact_size++; + } + } + } + ///unlocks + gim_trimesh_unlocks_work_data(trimesh); + ///Destroy box result + GIM_DYNARRAY_DESTROY(collision_result); + + //merge contacts + gim_merge_contacts(&dummycontacts,contacts); + + //Destroy dummy + GIM_DYNARRAY_DESTROY(dummycontacts); +} diff --git a/libs/ode-0.16.1/GIMPACT/src/gim_trimesh_ray_collision.cpp b/libs/ode-0.16.1/GIMPACT/src/gim_trimesh_ray_collision.cpp new file mode 100644 index 0000000..e83993e --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/src/gim_trimesh_ray_collision.cpp @@ -0,0 +1,149 @@ + +/* +----------------------------------------------------------------------------- +This source file is part of GIMPACT Library. + +For the latest info, see http://gimpact.sourceforge.net/ + +Copyright (c) 2006 Francisco Leon. C.C. 80087371. +email: projectileman@yahoo.com + + This library is free software; you can redistribute it and/or + modify it under the terms of EITHER: + (1) The GNU Lesser General Public License as published by the Free + Software Foundation; either version 2.1 of the License, or (at + your option) any later version. The text of the GNU Lesser + General Public License is included with this library in the + file GIMPACT-LICENSE-LGPL.TXT. + (2) The BSD-style license that is included with this library in + the file GIMPACT-LICENSE-BSD.TXT. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files + GIMPACT-LICENSE-LGPL.TXT and GIMPACT-LICENSE-BSD.TXT for more details. + +----------------------------------------------------------------------------- +*/ + +#include "GIMPACT/gim_trimesh.h" + + +//! Trimesh Ray Collisions +/*! + +\param trimesh +\param contact +\return 1 if the ray collides, else 0 +*/ +int gim_trimesh_ray_collision(GIM_TRIMESH * trimesh,vec3f origin,vec3f dir, GREAL tmax, GIM_TRIANGLE_RAY_CONTACT_DATA * contact) +{ + GDYNAMIC_ARRAY collision_result; + GIM_CREATE_BOXQUERY_LIST(collision_result); + + gim_aabbset_ray_collision(origin,dir,tmax,&trimesh->m_aabbset,&collision_result); + + if(collision_result.m_size==0) + { + GIM_DYNARRAY_DESTROY(collision_result); + return 0; + } + + //collide triangles + + GUINT32 * boxesresult = GIM_DYNARRAY_POINTER(GUINT32,collision_result); + GIM_TRIANGLE_DATA tridata; + vec3f pout; + GREAL tparam,u,v; + char does_intersect; + + gim_trimesh_locks_work_data(trimesh); + + for(unsigned int i=0;itparam = tparam; + contact->u = u; + contact->v = v; + contact->m_face_id = boxesresult[i]; + VEC_COPY(contact->m_point,pout); + VEC_COPY(contact->m_normal,flippedPlane); + + gim_trimesh_unlocks_work_data(trimesh); + GIM_DYNARRAY_DESTROY(collision_result); + return 1; + } + } + + gim_trimesh_unlocks_work_data(trimesh); + GIM_DYNARRAY_DESTROY(collision_result); + return 0;//no collisiion +} + + +//! Trimesh Ray Collisions closest +/*! +Find the closest primitive collided by the ray +\param trimesh +\param contact +\return 1 if the ray collides, else 0 +*/ +int gim_trimesh_ray_closest_collision(GIM_TRIMESH * trimesh,vec3f origin,vec3f dir, GREAL tmax, GIM_TRIANGLE_RAY_CONTACT_DATA * contact) +{ + GDYNAMIC_ARRAY collision_result; + GIM_CREATE_BOXQUERY_LIST(collision_result); + + gim_aabbset_ray_collision(origin,dir,tmax,&trimesh->m_aabbset,&collision_result); + + if(collision_result.m_size==0) + { + GIM_DYNARRAY_DESTROY(collision_result); + return 0; + } + + //collide triangles + + GUINT32 * boxesresult = GIM_DYNARRAY_POINTER(GUINT32,collision_result); + GIM_TRIANGLE_DATA tridata; + vec3f pout; + GREAL tparam,u,v; + char does_intersect; + contact->tparam = tmax + 0.1f; + + gim_trimesh_locks_work_data(trimesh); + + for(unsigned int i=0;itparam)) + { + contact->tparam = tparam; + contact->u = u; + contact->v = v; + contact->m_face_id = boxesresult[i]; + VEC_COPY(contact->m_point,pout); + VEC_COPY(contact->m_normal,flippedPlane); + } + } + + gim_trimesh_unlocks_work_data(trimesh); + GIM_DYNARRAY_DESTROY(collision_result); + if(contact->tparam > tmax) return 0; + return 1; +} diff --git a/libs/ode-0.16.1/GIMPACT/src/gim_trimesh_sphere_collision.cpp b/libs/ode-0.16.1/GIMPACT/src/gim_trimesh_sphere_collision.cpp new file mode 100644 index 0000000..0d61715 --- /dev/null +++ b/libs/ode-0.16.1/GIMPACT/src/gim_trimesh_sphere_collision.cpp @@ -0,0 +1,196 @@ + +/* +----------------------------------------------------------------------------- +This source file is part of GIMPACT Library. + +For the latest info, see http://gimpact.sourceforge.net/ + +Copyright (c) 2006 Francisco Leon. C.C. 80087371. +email: projectileman@yahoo.com + + This library is free software; you can redistribute it and/or + modify it under the terms of EITHER: + (1) The GNU Lesser General Public License as published by the Free + Software Foundation; either version 2.1 of the License, or (at + your option) any later version. The text of the GNU Lesser + General Public License is included with this library in the + file GIMPACT-LICENSE-LGPL.TXT. + (2) The BSD-style license that is included with this library in + the file GIMPACT-LICENSE-BSD.TXT. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files + GIMPACT-LICENSE-LGPL.TXT and GIMPACT-LICENSE-BSD.TXT for more details. + +----------------------------------------------------------------------------- +*/ + +#include "GIMPACT/gim_trimesh.h" + +int gim_triangle_sphere_collision( + GIM_TRIANGLE_DATA *tri, + vec3f center, GREAL radius, + GIM_TRIANGLE_CONTACT_DATA * contact_data) +{ + contact_data->m_point_count = 0; + + //Find Face plane distance + GREAL dis = DISTANCE_PLANE_POINT(tri->m_planes.m_planes[0],center); + if(dis>radius) return 0; //out + if(dis<-radius) return 0;//Out of triangle + contact_data->m_penetration_depth = dis; + + //Find the most edge + GUINT32 most_edge = 4;//no edge + GREAL max_dis = 0.0f; + dis = DISTANCE_PLANE_POINT(tri->m_planes.m_planes[1],center); + if(dis>radius) return 0;//Out of triangle + if(dis>0.0f) + { + max_dis = dis; + most_edge = 0; + } + + dis = DISTANCE_PLANE_POINT(tri->m_planes.m_planes[2],center); + if(dis>radius) return 0;//Out of triangle + if(dis>max_dis)// && dis>0.0f) + { + max_dis = dis; + most_edge = 1; + } + + dis = DISTANCE_PLANE_POINT(tri->m_planes.m_planes[3],center); + if(dis>radius) return 0;//Out of triangle + if(dis>max_dis)// && dis>0.0f) + { + max_dis = dis; + most_edge = 2; + } + + if(most_edge == 4) //Box is into triangle + { + //contact_data->m_penetration_depth = dis is set above + //Find Face plane point + VEC_COPY(contact_data->m_separating_normal,tri->m_planes.m_planes[0]); + //Find point projection on plane + if(contact_data->m_penetration_depth>=0.0f) + { + VEC_SCALE(contact_data->m_points[0],-radius,contact_data->m_separating_normal); + } + else + { + VEC_SCALE(contact_data->m_points[0],radius,contact_data->m_separating_normal); + } + contact_data->m_penetration_depth = radius - contact_data->m_penetration_depth; + + VEC_SUM(contact_data->m_points[0],contact_data->m_points[0],center); + //Scale normal for pointing to triangle + VEC_SCALE(contact_data->m_separating_normal,-1.0f,contact_data->m_separating_normal); + contact_data->m_point_count = 1; + return 1; + } + //find the edge + vec3f e1,e2; + VEC_COPY(e1,tri->m_vertices[most_edge]); + VEC_COPY(e2,tri->m_vertices[(most_edge+1)%3]); + + CLOSEST_POINT_ON_SEGMENT(contact_data->m_points[0],center,e1,e2); + //find distance + VEC_DIFF(e1,center,contact_data->m_points[0]); + VEC_LENGTH(e1,dis); + if(dis>radius) return 0; + + contact_data->m_penetration_depth = radius - dis; + + if(IS_ZERO(dis)) + { + VEC_COPY(contact_data->m_separating_normal,tri->m_planes.m_planes[most_edge+1]); + VEC_SCALE(contact_data->m_points[0],-radius,contact_data->m_separating_normal); + VEC_SUM(contact_data->m_points[0],contact_data->m_points[0],center); + } + else + { + VEC_SCALE(contact_data->m_separating_normal,1.0f/dis,e1); + VEC_SCALE(contact_data->m_points[0],-radius,contact_data->m_separating_normal); + VEC_SUM(contact_data->m_points[0],contact_data->m_points[0],center); + } + + //Scale normal for pointing to triangle + VEC_SCALE(contact_data->m_separating_normal,-1.0f,contact_data->m_separating_normal); + + contact_data->m_point_count = 1; + return 1; + +} + +//! Trimesh Sphere Collisions +/*! +In each contact +
      +
    • m_handle1 points to trimesh. +
    • m_handle2 points to NULL. +
    • m_feature1 Is a triangle index of trimesh. +
    + +\param trimesh +\param center +\param radius +\param contacts A GIM_CONTACT array. Must be initialized +*/ +void gim_trimesh_sphere_collision(GIM_TRIMESH * trimesh,vec3f center,GREAL radius, GDYNAMIC_ARRAY * contacts) +{ + contacts->m_size = 0; + + aabb3f test_aabb; + test_aabb.minX = center[0]-radius; + test_aabb.maxX = center[0]+radius; + test_aabb.minY = center[1]-radius; + test_aabb.maxY = center[1]+radius; + test_aabb.minZ = center[2]-radius; + test_aabb.maxZ = center[2]+radius; + + GDYNAMIC_ARRAY collision_result; + GIM_CREATE_BOXQUERY_LIST(collision_result); + + gim_aabbset_box_collision(&test_aabb, &trimesh->m_aabbset , &collision_result); + + if(collision_result.m_size==0) + { + GIM_DYNARRAY_DESTROY(collision_result); + } + + //collide triangles + //Locks trimesh + gim_trimesh_locks_work_data(trimesh); + //dummy contacts + GDYNAMIC_ARRAY dummycontacts; + GIM_CREATE_CONTACT_LIST(dummycontacts); + + int cresult; + unsigned int i; + GUINT32 * boxesresult = GIM_DYNARRAY_POINTER(GUINT32,collision_result); + GIM_TRIANGLE_CONTACT_DATA tri_contact_data; + GIM_TRIANGLE_DATA tri_data; + + for(i=0;i0.0f && _distances[2]>0.0f)\ + {\ + out_of_face = 1;\ + }\ + else\ + {\ + out_of_face = 0;\ + }\ +}\ + + +//! Receives the 3 edge planes +#define MOST_DEEP_POINTS(plane,points,point_count,deep_points,deep_points_count,maxdeep)\ +{\ + maxdeep=-1000.0f;\ + GUINT32 _k;\ + GREAL _dist;\ + deep_points_count = 0;\ + for(_k=0;_kmaxdeep)\ + {\ + maxdeep = _dist;\ + _max_candidates[0] = _k;\ + deep_points_count=1;\ + }\ + else if((_dist+G_EPSILON)>=maxdeep)\ + {\ + _max_candidates[deep_points_count] = _k;\ + deep_points_count++;\ + }\ + }\ + if(maxdeep<0.0f)\ + {\ + deep_points_count = 0;\ + }\ + else\ + {\ + for(_k=0;_k0)\ + {\ + _temp_clip_count2 = 0;\ + PLANE_CLIP_POLYGON(tri_edge_planes[1],_temp_clip,_temp_clip_count,_temp_clip2,_temp_clip_count2,MAX_TRI_CLIPPING);\ + if(_temp_clip_count2>0)\ + {\ + PLANE_CLIP_POLYGON(tri_edge_planes[2],_temp_clip2,_temp_clip_count2,clipped_points,clipped_point_count,MAX_TRI_CLIPPING);\ + }\ + }\ +}\ + + + +int _gim_triangle_triangle_collision( + GIM_TRIANGLE_DATA *tri1, + GIM_TRIANGLE_DATA *tri2, + GIM_TRIANGLE_CONTACT_DATA * contact_data) +{ + //Cache variables for triangle intersection + GUINT32 _max_candidates[MAX_TRI_CLIPPING]; + vec3f _temp_clip[MAX_TRI_CLIPPING]; + GUINT32 _temp_clip_count = 0; + vec3f _temp_clip2[MAX_TRI_CLIPPING]; + GUINT32 _temp_clip_count2 = 0; + vec3f clipped_points2[MAX_TRI_CLIPPING]; + vec3f deep_points2[MAX_TRI_CLIPPING]; + vec3f clipped_points1[MAX_TRI_CLIPPING]; + vec3f deep_points1[MAX_TRI_CLIPPING]; + + + + //State variabnles + GUINT32 mostdir=0; + GUINT32 clipped2_count=0; + + //Clip tri2 by tri1 edges + + CLIP_TRI_POINTS_BY_TRI_EDGE_PLANES(tri2->m_vertices,(&tri1->m_planes.m_planes[1]), clipped_points2, clipped2_count); + + if(clipped2_count == 0 ) + { + return 0;//Reject + } + + //find most deep interval face1 + GUINT32 deep2_count=0; + + GREAL maxdeep; + + MOST_DEEP_POINTS((tri1->m_planes.m_planes[0]), clipped_points2, clipped2_count, deep_points2, deep2_count, maxdeep); + if(deep2_count==0) + { +// *perror = 0.0f; + return 0;//Reject + } + + //Normal pointing to triangle1 + VEC_SCALE(contact_data->m_separating_normal,-1.0f,(tri1->m_planes.m_planes[0])); + + + //Clip tri1 by tri2 edges + + GUINT32 clipped1_count=0; + + CLIP_TRI_POINTS_BY_TRI_EDGE_PLANES(tri1->m_vertices,(&tri2->m_planes.m_planes[1]), clipped_points1, clipped1_count); + + if(clipped2_count == 0 ) + { +// *perror = 0.0f; + return 0;//Reject + } + + + //find interval face2 + GUINT32 deep1_count=0; + + GREAL dist; + + MOST_DEEP_POINTS((tri2->m_planes.m_planes[0]), clipped_points1, clipped1_count, deep_points1, deep1_count, dist); + + if(deep1_count==0) + { +// *perror = 0.0f; + return 0; + } + + if(distm_separating_normal,(tri2->m_planes.m_planes[0])); + } + //set deep + contact_data->m_penetration_depth = maxdeep; + + ////check most dir for contacts + if(mostdir==0) + { + contact_data->m_point_count = deep2_count; + for(mostdir=0;mostdirm_points[mostdir] ,deep_points2[mostdir]); + } + } + else + { + contact_data->m_point_count = deep1_count; + for(mostdir=0;mostdirm_points[mostdir] ,deep_points1[mostdir]); + } + } + return 1; +} + + + +//! Finds the contact points from a collision of two triangles +/*! +Returns the contact points, the penetration depth and the separating normal of the collision +between two triangles. The normal is pointing toward triangle 1 from triangle 2 +*/ +int gim_triangle_triangle_collision( + GIM_TRIANGLE_DATA *tri1, + GIM_TRIANGLE_DATA *tri2, + GIM_TRIANGLE_CONTACT_DATA * contact_data) +{ + vec3f _distances; + char out_of_face=0; + + CLASSIFY_TRI_BY_FACE(tri1->m_vertices[0],tri1->m_vertices[1],tri1->m_vertices[2],tri2->m_planes.m_planes[0],out_of_face); + if(out_of_face==1) return 0; + + CLASSIFY_TRI_BY_FACE(tri2->m_vertices[0],tri2->m_vertices[1],tri2->m_vertices[2],tri1->m_planes.m_planes[0],out_of_face); + if(out_of_face==1) return 0; + + return _gim_triangle_triangle_collision(tri1,tri2,contact_data); +} + +//! Trimesh Trimesh Collisions +/*! + +In each contact +
      +
    • m_handle1 points to trimesh1. +
    • m_handle2 points to trimesh2. +
    • m_feature1 Is a triangle index of trimesh1. +
    • m_feature2 Is a triangle index of trimesh2. +
    + +\param trimesh1 Collider +\param trimesh2 Collidee +\param contacts A GIM_CONTACT array. Must be initialized +*/ +void gim_trimesh_trimesh_collision(GIM_TRIMESH * trimesh1, GIM_TRIMESH * trimesh2, GDYNAMIC_ARRAY * contacts) +{ + contacts->m_size = 0; + GDYNAMIC_ARRAY collision_pairs; + GIM_CREATE_PAIR_SET(collision_pairs) + + gim_aabbset_bipartite_intersections(&trimesh1->m_aabbset,&trimesh2->m_aabbset,&collision_pairs); + + if(collision_pairs.m_size==0) + { + GIM_DYNARRAY_DESTROY(collision_pairs); + return; //no collisioin + } + + //Locks meshes + gim_trimesh_locks_work_data(trimesh1); + gim_trimesh_locks_work_data(trimesh2); + + + //pair pointer + GIM_PAIR *pairs = GIM_DYNARRAY_POINTER(GIM_PAIR,collision_pairs); + //dummy contacts + GDYNAMIC_ARRAY dummycontacts; + GIM_CREATE_CONTACT_LIST(dummycontacts); + + //Auxiliary triangle data + GIM_TRIANGLE_CONTACT_DATA tri_contact_data; + GIM_TRIANGLE_DATA tri1data,tri2data; + + + GUINT32 i, ti1,ti2,ci; + int colresult; + for (i=0;im_size = 0; + char classify; + PLANE_CLASSIFY_BOX(plane,trimesh->m_aabbset.m_global_bound,classify); + if(classify>1) return; // in front of plane + + //Locks mesh + gim_trimesh_locks_work_data(trimesh); + //Get vertices + GUINT32 i, vertcount = trimesh->m_transformed_vertex_buffer.m_element_count; + vec3f * vertices = GIM_BUFFER_ARRAY_POINTER(vec3f,trimesh->m_transformed_vertex_buffer,0); + + GREAL dist; + vec4f * result_contact; + + for (i=0;i premake4.exe --with-tests --with-demos vs2008 + + To see a complete list of options use: + + > premake4.exe --help + + Note that Visual Studio 6 is not supported and users are advised to upgrade + to at least Visual Studio 2005 Express (it's free!) + + Using CMake is another option for generating project files for Visual Studio. + See section 5 below for more details on this. + + + + +2. BUILDING WITH AUTOTOOLS (Linux, OS X, MSYS, etc.) +==================================================== + +2.1 FROM SUBVERSION REPOSITORY +------------------------------ + + If you downloaded the source code from Subversion you must bootstrap the + process by running the command: + + $ ./bootstrap + + For this command to work you need a set of tools typically available + on BSD and Linux distributions with development packages installed. OS X + users may need to manually install libtool, autoconf, automake, + pkg-config, and maybe some more. + + If you downloaded a source code package from SourceForge this has + already been done for you. You may see some "underquoted definition" + warnings depending on your platform, these are (for now) harmless + warnings regarding scripts from other m4 installed packages. + +2.2 FROM A RELEASED TARBALL +--------------------------- + + First extract the archive (e.g. tar xvfz ) and enter + the created directory (ode-x.y). + + Run the configure script to autodetect your build environment: + + $ ./configure + + By default this will build ODE as a static library with single-precision + math, trimesh support with OPCODE, and debug symbols enabled. You can + modify these defaults by passing additional parameters to + configure. For a full list of available options, type: + + $ ./configure --help + + Some of the more popular options are + + --enable-double-precision enable double-precision math + --with-trimesh=none disables the trimesh support + --with-trimesh=opcode use OPCODE for trimesh code + --with-trimesh=gimpact use GIMPACT for trimesh code + + --enabled-shared builds a shared library + + To pass specific flags for an optimized build, you must do so + in the CFLAGS and CXXFLAGS enviroment variables, or as arguments + to ./configure. For example if you are building for an athlon xp processor + and you want the compiler to use SSE instructions you can run configure as + follows: + + $ ./configure CFLAGS="-msse -march=atlon-xp" CXXFLAGS="-msse -march=atlon-xp" + + Note that you must set both CFLAGS and CXXFLAGS as ODE contains a mixture of + C and C++ files. + + Once configure has run successfully, build and install ODE: + + $ make + $ make install + + The latter command will also create a pkg-config script that provides + compilation and linking flags for programs. The old stand-alone + "ode-config" script is also installed for compatibility. + + + + +3. BUILDING WITH Code::Blocks +============================= + + Because Code::Blocks supports so many different platforms, we do not + provide workspaces. Instead, use Premake to create a workspace tailored + for your platform and project. Like so: + + $ cd build + $ premake4 --with-tests --with-demos codeblocks + + To see a complete list of options: + + $ cd build + $ premake4 --help + + Using CMake is another option for generating project files for Code::Blocks. + See section 5 below for more details on this. + + + + +4. BUILDING WITH SOMETHING ELSE +=============================== + + ODE uses the Premake tool to provide support for several different toolsets. + Premake adds support for new toolsets on a regular basis, so yours might be + supported. Check the Premake website at http://premake.sourceforge.net/, + and then follow the directions for Code::Blocks above, substituting your + toolset target in place of `codeblocks`. + + Using CMake is another option for generating project files for other + toolsets. See section 5 below for more details on this. + + + + +5. BUILDING WITH CMAKE +====================== + + ODE includes support for CMake to generate project files for various platforms + and IDEs including Unix Makefiles, Ninja, Code::Blocks, Visual Studio. A full + overview of all supported generators can be found at the latest version of the + manual at https://cmake.org/cmake/help/latest/manual/cmake-generators.7.html + + CMake supports and encourages out-of-source builds. In order to generate build + files for your platform, create a build directory at your preferred location + and then call CMake with the path to ODE's source directory as argument, e.g., + one level above the source directory: + + $ cd .. + $ mkdir ode-build + $ cmake ../ode-src + + The existing build directory in the source directory can also be used as a + location for the project files. A different generator than the default one + for the system can be specified as well: + + $ cd build + $ cmake -G"Visual Studio 15 2017 Win64" .. + + QtCreator, CLion, and Visual Studio 2017 also offer the option to open the + source directory with the CMakeLists.txt file directly in the IDE. + + + + diff --git a/libs/ode-0.16.1/LICENSE-BSD.TXT b/libs/ode-0.16.1/LICENSE-BSD.TXT new file mode 100644 index 0000000..112f6a2 --- /dev/null +++ b/libs/ode-0.16.1/LICENSE-BSD.TXT @@ -0,0 +1,34 @@ + +This is the BSD-style license for the Open Dynamics Engine +---------------------------------------------------------- + +Open Dynamics Engine +Copyright (c) 2001-2007, Russell L. Smith. +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: + +Redistributions of source code must retain the above copyright notice, +this list of conditions and the following disclaimer. + +Redistributions in binary form must reproduce the above copyright notice, +this list of conditions and the following disclaimer in the documentation +and/or other materials provided with the distribution. + +Neither the names of ODE's copyright owner nor the names of its +contributors may be used to endorse or promote products derived from +this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS +FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED +TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR +PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING +NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/libs/ode-0.16.1/LICENSE.TXT b/libs/ode-0.16.1/LICENSE.TXT new file mode 100644 index 0000000..cfe59bc --- /dev/null +++ b/libs/ode-0.16.1/LICENSE.TXT @@ -0,0 +1,502 @@ + GNU LESSER GENERAL PUBLIC LICENSE + Version 2.1, February 1999 + + Copyright (C) 1991, 1999 Free Software Foundation, Inc. + 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + +[This is the first released version of the Lesser GPL. It also counts + as the successor of the GNU Library Public License, version 2, hence + the version number 2.1.] + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +Licenses are intended to guarantee your freedom to share and change +free software--to make sure the software is free for all its users. + + This license, the Lesser General Public License, applies to some +specially designated software packages--typically libraries--of the +Free Software Foundation and other authors who decide to use it. You +can use it too, but we suggest you first think carefully about whether +this license or the ordinary General Public License is the better +strategy to use in any particular case, based on the explanations below. + + When we speak of free software, we are referring to freedom of use, +not price. Our General Public Licenses are designed to make sure that +you have the freedom to distribute copies of free software (and charge +for this service if you wish); that you receive source code or can get +it if you want it; that you can change the software and use pieces of +it in new free programs; and that you are informed that you can do +these things. + + To protect your rights, we need to make restrictions that forbid +distributors to deny you these rights or to ask you to surrender these +rights. These restrictions translate to certain responsibilities for +you if you distribute copies of the library or if you modify it. + + For example, if you distribute copies of the library, whether gratis +or for a fee, you must give the recipients all the rights that we gave +you. You must make sure that they, too, receive or can get the source +code. If you link other code with the library, you must provide +complete object files to the recipients, so that they can relink them +with the library after making changes to the library and recompiling +it. And you must show them these terms so they know their rights. + + We protect your rights with a two-step method: (1) we copyright the +library, and (2) we offer you this license, which gives you legal +permission to copy, distribute and/or modify the library. + + To protect each distributor, we want to make it very clear that +there is no warranty for the free library. Also, if the library is +modified by someone else and passed on, the recipients should know +that what they have is not the original version, so that the original +author's reputation will not be affected by problems that might be +introduced by others. + + Finally, software patents pose a constant threat to the existence of +any free program. We wish to make sure that a company cannot +effectively restrict the users of a free program by obtaining a +restrictive license from a patent holder. Therefore, we insist that +any patent license obtained for a version of the library must be +consistent with the full freedom of use specified in this license. + + Most GNU software, including some libraries, is covered by the +ordinary GNU General Public License. This license, the GNU Lesser +General Public License, applies to certain designated libraries, and +is quite different from the ordinary General Public License. We use +this license for certain libraries in order to permit linking those +libraries into non-free programs. + + When a program is linked with a library, whether statically or using +a shared library, the combination of the two is legally speaking a +combined work, a derivative of the original library. The ordinary +General Public License therefore permits such linking only if the +entire combination fits its criteria of freedom. The Lesser General +Public License permits more lax criteria for linking other code with +the library. + + We call this license the "Lesser" General Public License because it +does Less to protect the user's freedom than the ordinary General +Public License. It also provides other free software developers Less +of an advantage over competing non-free programs. These disadvantages +are the reason we use the ordinary General Public License for many +libraries. However, the Lesser license provides advantages in certain +special circumstances. + + For example, on rare occasions, there may be a special need to +encourage the widest possible use of a certain library, so that it becomes +a de-facto standard. To achieve this, non-free programs must be +allowed to use the library. A more frequent case is that a free +library does the same job as widely used non-free libraries. In this +case, there is little to gain by limiting the free library to free +software only, so we use the Lesser General Public License. + + In other cases, permission to use a particular library in non-free +programs enables a greater number of people to use a large body of +free software. For example, permission to use the GNU C Library in +non-free programs enables many more people to use the whole GNU +operating system, as well as its variant, the GNU/Linux operating +system. + + Although the Lesser General Public License is Less protective of the +users' freedom, it does ensure that the user of a program that is +linked with the Library has the freedom and the wherewithal to run +that program using a modified version of the Library. + + The precise terms and conditions for copying, distribution and +modification follow. Pay close attention to the difference between a +"work based on the library" and a "work that uses the library". The +former contains code derived from the library, whereas the latter must +be combined with the library in order to run. + + GNU LESSER GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License Agreement applies to any software library or other +program which contains a notice placed by the copyright holder or +other authorized party saying it may be distributed under the terms of +this Lesser General Public License (also called "this License"). +Each licensee is addressed as "you". + + A "library" means a collection of software functions and/or data +prepared so as to be conveniently linked with application programs +(which use some of those functions and data) to form executables. + + The "Library", below, refers to any such software library or work +which has been distributed under these terms. A "work based on the +Library" means either the Library or any derivative work under +copyright law: that is to say, a work containing the Library or a +portion of it, either verbatim or with modifications and/or translated +straightforwardly into another language. (Hereinafter, translation is +included without limitation in the term "modification".) + + "Source code" for a work means the preferred form of the work for +making modifications to it. For a library, complete source code means +all the source code for all modules it contains, plus any associated +interface definition files, plus the scripts used to control compilation +and installation of the library. + + Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running a program using the Library is not restricted, and output from +such a program is covered only if its contents constitute a work based +on the Library (independent of the use of the Library in a tool for +writing it). Whether that is true depends on what the Library does +and what the program that uses the Library does. + + 1. You may copy and distribute verbatim copies of the Library's +complete source code as you receive it, in any medium, provided that +you conspicuously and appropriately publish on each copy an +appropriate copyright notice and disclaimer of warranty; keep intact +all the notices that refer to this License and to the absence of any +warranty; and distribute a copy of this License along with the +Library. + + You may charge a fee for the physical act of transferring a copy, +and you may at your option offer warranty protection in exchange for a +fee. + + 2. You may modify your copy or copies of the Library or any portion +of it, thus forming a work based on the Library, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) The modified work must itself be a software library. + + b) You must cause the files modified to carry prominent notices + stating that you changed the files and the date of any change. + + c) You must cause the whole of the work to be licensed at no + charge to all third parties under the terms of this License. + + d) If a facility in the modified Library refers to a function or a + table of data to be supplied by an application program that uses + the facility, other than as an argument passed when the facility + is invoked, then you must make a good faith effort to ensure that, + in the event an application does not supply such function or + table, the facility still operates, and performs whatever part of + its purpose remains meaningful. + + (For example, a function in a library to compute square roots has + a purpose that is entirely well-defined independent of the + application. Therefore, Subsection 2d requires that any + application-supplied function or table used by this function must + be optional: if the application does not supply it, the square + root function must still compute square roots.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Library, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Library, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote +it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Library. + +In addition, mere aggregation of another work not based on the Library +with the Library (or with a work based on the Library) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may opt to apply the terms of the ordinary GNU General Public +License instead of this License to a given copy of the Library. To do +this, you must alter all the notices that refer to this License, so +that they refer to the ordinary GNU General Public License, version 2, +instead of to this License. (If a newer version than version 2 of the +ordinary GNU General Public License has appeared, then you can specify +that version instead if you wish.) Do not make any other change in +these notices. + + Once this change is made in a given copy, it is irreversible for +that copy, so the ordinary GNU General Public License applies to all +subsequent copies and derivative works made from that copy. + + This option is useful when you wish to copy part of the code of +the Library into a program that is not a library. + + 4. You may copy and distribute the Library (or a portion or +derivative of it, under Section 2) in object code or executable form +under the terms of Sections 1 and 2 above provided that you accompany +it with the complete corresponding machine-readable source code, which +must be distributed under the terms of Sections 1 and 2 above on a +medium customarily used for software interchange. + + If distribution of object code is made by offering access to copy +from a designated place, then offering equivalent access to copy the +source code from the same place satisfies the requirement to +distribute the source code, even though third parties are not +compelled to copy the source along with the object code. + + 5. A program that contains no derivative of any portion of the +Library, but is designed to work with the Library by being compiled or +linked with it, is called a "work that uses the Library". Such a +work, in isolation, is not a derivative work of the Library, and +therefore falls outside the scope of this License. + + However, linking a "work that uses the Library" with the Library +creates an executable that is a derivative of the Library (because it +contains portions of the Library), rather than a "work that uses the +library". The executable is therefore covered by this License. +Section 6 states terms for distribution of such executables. + + When a "work that uses the Library" uses material from a header file +that is part of the Library, the object code for the work may be a +derivative work of the Library even though the source code is not. +Whether this is true is especially significant if the work can be +linked without the Library, or if the work is itself a library. The +threshold for this to be true is not precisely defined by law. + + If such an object file uses only numerical parameters, data +structure layouts and accessors, and small macros and small inline +functions (ten lines or less in length), then the use of the object +file is unrestricted, regardless of whether it is legally a derivative +work. (Executables containing this object code plus portions of the +Library will still fall under Section 6.) + + Otherwise, if the work is a derivative of the Library, you may +distribute the object code for the work under the terms of Section 6. +Any executables containing that work also fall under Section 6, +whether or not they are linked directly with the Library itself. + + 6. As an exception to the Sections above, you may also combine or +link a "work that uses the Library" with the Library to produce a +work containing portions of the Library, and distribute that work +under terms of your choice, provided that the terms permit +modification of the work for the customer's own use and reverse +engineering for debugging such modifications. + + You must give prominent notice with each copy of the work that the +Library is used in it and that the Library and its use are covered by +this License. You must supply a copy of this License. If the work +during execution displays copyright notices, you must include the +copyright notice for the Library among them, as well as a reference +directing the user to the copy of this License. Also, you must do one +of these things: + + a) Accompany the work with the complete corresponding + machine-readable source code for the Library including whatever + changes were used in the work (which must be distributed under + Sections 1 and 2 above); and, if the work is an executable linked + with the Library, with the complete machine-readable "work that + uses the Library", as object code and/or source code, so that the + user can modify the Library and then relink to produce a modified + executable containing the modified Library. (It is understood + that the user who changes the contents of definitions files in the + Library will not necessarily be able to recompile the application + to use the modified definitions.) + + b) Use a suitable shared library mechanism for linking with the + Library. A suitable mechanism is one that (1) uses at run time a + copy of the library already present on the user's computer system, + rather than copying library functions into the executable, and (2) + will operate properly with a modified version of the library, if + the user installs one, as long as the modified version is + interface-compatible with the version that the work was made with. + + c) Accompany the work with a written offer, valid for at + least three years, to give the same user the materials + specified in Subsection 6a, above, for a charge no more + than the cost of performing this distribution. + + d) If distribution of the work is made by offering access to copy + from a designated place, offer equivalent access to copy the above + specified materials from the same place. + + e) Verify that the user has already received a copy of these + materials or that you have already sent this user a copy. + + For an executable, the required form of the "work that uses the +Library" must include any data and utility programs needed for +reproducing the executable from it. However, as a special exception, +the materials to be distributed need not include anything that is +normally distributed (in either source or binary form) with the major +components (compiler, kernel, and so on) of the operating system on +which the executable runs, unless that component itself accompanies +the executable. + + It may happen that this requirement contradicts the license +restrictions of other proprietary libraries that do not normally +accompany the operating system. Such a contradiction means you cannot +use both them and the Library together in an executable that you +distribute. + + 7. You may place library facilities that are a work based on the +Library side-by-side in a single library together with other library +facilities not covered by this License, and distribute such a combined +library, provided that the separate distribution of the work based on +the Library and of the other library facilities is otherwise +permitted, and provided that you do these two things: + + a) Accompany the combined library with a copy of the same work + based on the Library, uncombined with any other library + facilities. This must be distributed under the terms of the + Sections above. + + b) Give prominent notice with the combined library of the fact + that part of it is a work based on the Library, and explaining + where to find the accompanying uncombined form of the same work. + + 8. You may not copy, modify, sublicense, link with, or distribute +the Library except as expressly provided under this License. Any +attempt otherwise to copy, modify, sublicense, link with, or +distribute the Library is void, and will automatically terminate your +rights under this License. However, parties who have received copies, +or rights, from you under this License will not have their licenses +terminated so long as such parties remain in full compliance. + + 9. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Library or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Library (or any work based on the +Library), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Library or works based on it. + + 10. Each time you redistribute the Library (or any work based on the +Library), the recipient automatically receives a license from the +original licensor to copy, distribute, link with or modify the Library +subject to these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties with +this License. + + 11. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Library at all. For example, if a patent +license would not permit royalty-free redistribution of the Library by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Library. + +If any portion of this section is held invalid or unenforceable under any +particular circumstance, the balance of the section is intended to apply, +and the section as a whole is intended to apply in other circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 12. If the distribution and/or use of the Library is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Library under this License may add +an explicit geographical distribution limitation excluding those countries, +so that distribution is permitted only in or among countries not thus +excluded. In such case, this License incorporates the limitation as if +written in the body of this License. + + 13. The Free Software Foundation may publish revised and/or new +versions of the Lesser General Public License from time to time. +Such new versions will be similar in spirit to the present version, +but may differ in detail to address new problems or concerns. + +Each version is given a distinguishing version number. If the Library +specifies a version number of this License which applies to it and +"any later version", you have the option of following the terms and +conditions either of that version or of any later version published by +the Free Software Foundation. If the Library does not specify a +license version number, you may choose any version ever published by +the Free Software Foundation. + + 14. If you wish to incorporate parts of the Library into other free +programs whose distribution conditions are incompatible with these, +write to the author to ask for permission. For software which is +copyrighted by the Free Software Foundation, write to the Free +Software Foundation; we sometimes make exceptions for this. Our +decision will be guided by the two goals of preserving the free status +of all derivatives of our free software and of promoting the sharing +and reuse of software generally. + + NO WARRANTY + + 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO +WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. +EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR +OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY +KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE +LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME +THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN +WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY +AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU +FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR +CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE +LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING +RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A +FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF +SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH +DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Libraries + + If you develop a new library, and you want it to be of the greatest +possible use to the public, we recommend making it free software that +everyone can redistribute and change. You can do so by permitting +redistribution under these terms (or, alternatively, under the terms of the +ordinary General Public License). + + To apply these terms, attach the following notices to the library. It is +safest to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least the +"copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with this library; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + +Also add information on how to contact you by electronic and paper mail. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the library, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the + library `Frob' (a library for tweaking knobs) written by James Random Hacker. + + , 1 April 1990 + Ty Coon, President of Vice + +That's all there is to it! diff --git a/libs/ode-0.16.1/Makefile.am b/libs/ode-0.16.1/Makefile.am new file mode 100644 index 0000000..c786f5c --- /dev/null +++ b/libs/ode-0.16.1/Makefile.am @@ -0,0 +1,48 @@ +AUTOMAKE_OPTIONS = foreign +ACLOCAL_AMFLAGS = -I m4 --install + +if ENABLE_OU +OU_DIR = ou +endif + +if LIBCCD +if LIBCCD_INTERNAL +LIBCCD_DIR = libccd +endif +endif + +if ENABLE_DEMOS +DRAWSTUFF_DIR = drawstuff +endif + +if GIMPACT +GIMPACT_DIR = GIMPACT +endif + +if OPCODE +OPCODE_DIR = OPCODE +endif + +SUBDIRS = include \ + $(DRAWSTUFF_DIR) \ + $(GIMPACT_DIR) \ + $(OPCODE_DIR) \ + $(OU_DIR) \ + $(LIBCCD_DIR) \ + ode \ + tests + +bin_SCRIPTS = ode-config + +# Utility rule for making a release +release: dist-gzip dist-bzip2 + @echo Created release packages for ${PACKAGE}-${VERSION}. + +EXTRA_DIST = bootstrap build tools \ + CHANGELOG.txt COPYING INSTALL.txt CSR.txt README.md \ + LICENSE.TXT LICENSE-BSD.TXT \ + bindings \ + CMakeLists.txt ode-config.cmake.in config.h.cmake.in cmake + +pkgconfigdir = $(libdir)/pkgconfig +pkgconfig_DATA = ode.pc diff --git a/libs/ode-0.16.1/Makefile.in b/libs/ode-0.16.1/Makefile.in new file mode 100644 index 0000000..2b8787e --- /dev/null +++ b/libs/ode-0.16.1/Makefile.in @@ -0,0 +1,941 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = . +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ + $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ + $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(top_srcdir)/configure \ + $(am__configure_deps) $(am__DIST_COMMON) +am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ + configure.lineno config.status.lineno +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/ode/src/config.h +CONFIG_CLEAN_FILES = ode-config ode.pc +CONFIG_CLEAN_VPATH_FILES = +am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; +am__vpath_adj = case $$p in \ + $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ + *) f=$$p;; \ + esac; +am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; +am__install_max = 40 +am__nobase_strip_setup = \ + srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` +am__nobase_strip = \ + for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" +am__nobase_list = $(am__nobase_strip_setup); \ + for p in $$list; do echo "$$p $$p"; done | \ + sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ + $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ + if (++n[$$2] == $(am__install_max)) \ + { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ + END { for (dir in files) print dir, files[dir] }' +am__base_list = \ + sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ + sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__uninstall_files_from_dir = { \ + test -z "$$files" \ + || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && rm -f $$files; }; \ + } +am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(pkgconfigdir)" +SCRIPTS = $(bin_SCRIPTS) +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +SOURCES = +DIST_SOURCES = +RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ + ctags-recursive dvi-recursive html-recursive info-recursive \ + install-data-recursive install-dvi-recursive \ + install-exec-recursive install-html-recursive \ + install-info-recursive install-pdf-recursive \ + install-ps-recursive install-recursive installcheck-recursive \ + installdirs-recursive pdf-recursive ps-recursive \ + tags-recursive uninstall-recursive +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +DATA = $(pkgconfig_DATA) +RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ + distclean-recursive maintainer-clean-recursive +am__recursive_targets = \ + $(RECURSIVE_TARGETS) \ + $(RECURSIVE_CLEAN_TARGETS) \ + $(am__extra_recursive_targets) +AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ + cscope distdir dist dist-all distcheck +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +CSCOPE = cscope +DIST_SUBDIRS = include drawstuff GIMPACT OPCODE ou libccd ode tests +am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/ode-config.in \ + $(srcdir)/ode.pc.in COPYING compile config.guess config.sub \ + depcomp install-sh ltmain.sh missing +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +distdir = $(PACKAGE)-$(VERSION) +top_distdir = $(distdir) +am__remove_distdir = \ + if test -d "$(distdir)"; then \ + find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \ + && rm -rf "$(distdir)" \ + || { sleep 5 && rm -rf "$(distdir)"; }; \ + else :; fi +am__post_remove_distdir = $(am__remove_distdir) +am__relativize = \ + dir0=`pwd`; \ + sed_first='s,^\([^/]*\)/.*$$,\1,'; \ + sed_rest='s,^[^/]*/*,,'; \ + sed_last='s,^.*/\([^/]*\)$$,\1,'; \ + sed_butlast='s,/*[^/]*$$,,'; \ + while test -n "$$dir1"; do \ + first=`echo "$$dir1" | sed -e "$$sed_first"`; \ + if test "$$first" != "."; then \ + if test "$$first" = ".."; then \ + dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ + dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ + else \ + first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ + if test "$$first2" = "$$first"; then \ + dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ + else \ + dir2="../$$dir2"; \ + fi; \ + dir0="$$dir0"/"$$first"; \ + fi; \ + fi; \ + dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ + done; \ + reldir="$$dir2" +DIST_ARCHIVES = $(distdir).tar.gz +GZIP_ENV = --best +DIST_TARGETS = dist-gzip +distuninstallcheck_listfiles = find . -type f -print +am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \ + | sed 's|^\./|$(prefix)/|' | grep -v '$(infodir)/dir$$' +distcleancheck_listfiles = find . -type f -print +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AS = @AS@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CCD_CFLAGS = @CCD_CFLAGS@ +CCD_LIBS = @CCD_LIBS@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DOXYGEN = @DOXYGEN@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +EXTRA_LIBTOOL_LDFLAGS = @EXTRA_LIBTOOL_LDFLAGS@ +FGREP = @FGREP@ +GL_LIBS = @GL_LIBS@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBSTDCXX = @LIBSTDCXX@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +ODE_PRECISION = @ODE_PRECISION@ +ODE_VERSION = @ODE_VERSION@ +ODE_VERSION_INFO = @ODE_VERSION_INFO@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +WINDRES = @WINDRES@ +X11_CFLAGS = @X11_CFLAGS@ +X11_LIBS = @X11_LIBS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_WINDRES = @ac_ct_WINDRES@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +runstatedir = @runstatedir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +AUTOMAKE_OPTIONS = foreign +ACLOCAL_AMFLAGS = -I m4 --install +@ENABLE_OU_TRUE@OU_DIR = ou +@LIBCCD_INTERNAL_TRUE@@LIBCCD_TRUE@LIBCCD_DIR = libccd +@ENABLE_DEMOS_TRUE@DRAWSTUFF_DIR = drawstuff +@GIMPACT_TRUE@GIMPACT_DIR = GIMPACT +@OPCODE_TRUE@OPCODE_DIR = OPCODE +SUBDIRS = include \ + $(DRAWSTUFF_DIR) \ + $(GIMPACT_DIR) \ + $(OPCODE_DIR) \ + $(OU_DIR) \ + $(LIBCCD_DIR) \ + ode \ + tests + +bin_SCRIPTS = ode-config +EXTRA_DIST = bootstrap build tools \ + CHANGELOG.txt COPYING INSTALL.txt CSR.txt README.md \ + LICENSE.TXT LICENSE-BSD.TXT \ + bindings \ + CMakeLists.txt ode-config.cmake.in config.h.cmake.in cmake + +pkgconfigdir = $(libdir)/pkgconfig +pkgconfig_DATA = ode.pc +all: all-recursive + +.SUFFIXES: +am--refresh: Makefile + @: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + echo ' cd $(srcdir) && $(AUTOMAKE) --foreign'; \ + $(am__cd) $(srcdir) && $(AUTOMAKE) --foreign \ + && exit 0; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + echo ' $(SHELL) ./config.status'; \ + $(SHELL) ./config.status;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + $(SHELL) ./config.status --recheck + +$(top_srcdir)/configure: $(am__configure_deps) + $(am__cd) $(srcdir) && $(AUTOCONF) +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + $(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) +$(am__aclocal_m4_deps): +ode-config: $(top_builddir)/config.status $(srcdir)/ode-config.in + cd $(top_builddir) && $(SHELL) ./config.status $@ +ode.pc: $(top_builddir)/config.status $(srcdir)/ode.pc.in + cd $(top_builddir) && $(SHELL) ./config.status $@ +install-binSCRIPTS: $(bin_SCRIPTS) + @$(NORMAL_INSTALL) + @list='$(bin_SCRIPTS)'; test -n "$(bindir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + if test -f "$$d$$p"; then echo "$$d$$p"; echo "$$p"; else :; fi; \ + done | \ + sed -e 'p;s,.*/,,;n' \ + -e 'h;s|.*|.|' \ + -e 'p;x;s,.*/,,;$(transform)' | sed 'N;N;N;s,\n, ,g' | \ + $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1; } \ + { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ + if ($$2 == $$4) { files[d] = files[d] " " $$1; \ + if (++n[d] == $(am__install_max)) { \ + print "f", d, files[d]; n[d] = 0; files[d] = "" } } \ + else { print "f", d "/" $$4, $$1 } } \ + END { for (d in files) print "f", d, files[d] }' | \ + while read type dir files; do \ + if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ + test -z "$$files" || { \ + echo " $(INSTALL_SCRIPT) $$files '$(DESTDIR)$(bindir)$$dir'"; \ + $(INSTALL_SCRIPT) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \ + } \ + ; done + +uninstall-binSCRIPTS: + @$(NORMAL_UNINSTALL) + @list='$(bin_SCRIPTS)'; test -n "$(bindir)" || exit 0; \ + files=`for p in $$list; do echo "$$p"; done | \ + sed -e 's,.*/,,;$(transform)'`; \ + dir='$(DESTDIR)$(bindir)'; $(am__uninstall_files_from_dir) + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +distclean-libtool: + -rm -f libtool config.lt +install-pkgconfigDATA: $(pkgconfig_DATA) + @$(NORMAL_INSTALL) + @list='$(pkgconfig_DATA)'; test -n "$(pkgconfigdir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(pkgconfigdir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(pkgconfigdir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(pkgconfigdir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(pkgconfigdir)" || exit $$?; \ + done + +uninstall-pkgconfigDATA: + @$(NORMAL_UNINSTALL) + @list='$(pkgconfig_DATA)'; test -n "$(pkgconfigdir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(pkgconfigdir)'; $(am__uninstall_files_from_dir) + +# This directory's subdirectories are mostly independent; you can cd +# into them and run 'make' without going through this Makefile. +# To change the values of 'make' variables: instead of editing Makefiles, +# (1) if the variable is set in 'config.status', edit 'config.status' +# (which will cause the Makefiles to be regenerated when you run 'make'); +# (2) otherwise, pass the desired values on the 'make' command line. +$(am__recursive_targets): + @fail=; \ + if $(am__make_keepgoing); then \ + failcom='fail=yes'; \ + else \ + failcom='exit 1'; \ + fi; \ + dot_seen=no; \ + target=`echo $@ | sed s/-recursive//`; \ + case "$@" in \ + distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ + *) list='$(SUBDIRS)' ;; \ + esac; \ + for subdir in $$list; do \ + echo "Making $$target in $$subdir"; \ + if test "$$subdir" = "."; then \ + dot_seen=yes; \ + local_target="$$target-am"; \ + else \ + local_target="$$target"; \ + fi; \ + ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ + || eval $$failcom; \ + done; \ + if test "$$dot_seen" = "no"; then \ + $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ + fi; test -z "$$fail" + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-recursive +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ + include_option=--etags-include; \ + empty_fix=.; \ + else \ + include_option=--include; \ + empty_fix=; \ + fi; \ + list='$(SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + test ! -f $$subdir/TAGS || \ + set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ + fi; \ + done; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-recursive + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscope: cscope.files + test ! -s cscope.files \ + || $(CSCOPE) -b -q $(AM_CSCOPEFLAGS) $(CSCOPEFLAGS) -i cscope.files $(CSCOPE_ARGS) +clean-cscope: + -rm -f cscope.files +cscope.files: clean-cscope cscopelist +cscopelist: cscopelist-recursive + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + -rm -f cscope.out cscope.in.out cscope.po.out cscope.files + +distdir: $(DISTFILES) + $(am__remove_distdir) + test -d "$(distdir)" || mkdir "$(distdir)" + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done + @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + $(am__make_dryrun) \ + || test -d "$(distdir)/$$subdir" \ + || $(MKDIR_P) "$(distdir)/$$subdir" \ + || exit 1; \ + dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ + $(am__relativize); \ + new_distdir=$$reldir; \ + dir1=$$subdir; dir2="$(top_distdir)"; \ + $(am__relativize); \ + new_top_distdir=$$reldir; \ + echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ + echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ + ($(am__cd) $$subdir && \ + $(MAKE) $(AM_MAKEFLAGS) \ + top_distdir="$$new_top_distdir" \ + distdir="$$new_distdir" \ + am__remove_distdir=: \ + am__skip_length_check=: \ + am__skip_mode_fix=: \ + distdir) \ + || exit 1; \ + fi; \ + done + -test -n "$(am__skip_mode_fix)" \ + || find "$(distdir)" -type d ! -perm -755 \ + -exec chmod u+rwx,go+rx {} \; -o \ + ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ + ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ + ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \ + || chmod -R a+r "$(distdir)" +dist-gzip: distdir + tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz + $(am__post_remove_distdir) + +dist-bzip2: distdir + tardir=$(distdir) && $(am__tar) | BZIP2=$${BZIP2--9} bzip2 -c >$(distdir).tar.bz2 + $(am__post_remove_distdir) + +dist-lzip: distdir + tardir=$(distdir) && $(am__tar) | lzip -c $${LZIP_OPT--9} >$(distdir).tar.lz + $(am__post_remove_distdir) + +dist-xz: distdir + tardir=$(distdir) && $(am__tar) | XZ_OPT=$${XZ_OPT--e} xz -c >$(distdir).tar.xz + $(am__post_remove_distdir) + +dist-tarZ: distdir + @echo WARNING: "Support for distribution archives compressed with" \ + "legacy program 'compress' is deprecated." >&2 + @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 + tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z + $(am__post_remove_distdir) + +dist-shar: distdir + @echo WARNING: "Support for shar distribution archives is" \ + "deprecated." >&2 + @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 + shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz + $(am__post_remove_distdir) + +dist-zip: distdir + -rm -f $(distdir).zip + zip -rq $(distdir).zip $(distdir) + $(am__post_remove_distdir) + +dist dist-all: + $(MAKE) $(AM_MAKEFLAGS) $(DIST_TARGETS) am__post_remove_distdir='@:' + $(am__post_remove_distdir) + +# This target untars the dist file and tries a VPATH configuration. Then +# it guarantees that the distribution is self-contained by making another +# tarfile. +distcheck: dist + case '$(DIST_ARCHIVES)' in \ + *.tar.gz*) \ + GZIP=$(GZIP_ENV) gzip -dc $(distdir).tar.gz | $(am__untar) ;;\ + *.tar.bz2*) \ + bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\ + *.tar.lz*) \ + lzip -dc $(distdir).tar.lz | $(am__untar) ;;\ + *.tar.xz*) \ + xz -dc $(distdir).tar.xz | $(am__untar) ;;\ + *.tar.Z*) \ + uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ + *.shar.gz*) \ + GZIP=$(GZIP_ENV) gzip -dc $(distdir).shar.gz | unshar ;;\ + *.zip*) \ + unzip $(distdir).zip ;;\ + esac + chmod -R a-w $(distdir) + chmod u+w $(distdir) + mkdir $(distdir)/_build $(distdir)/_build/sub $(distdir)/_inst + chmod a-w $(distdir) + test -d $(distdir)/_build || exit 0; \ + dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \ + && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ + && am__cwd=`pwd` \ + && $(am__cd) $(distdir)/_build/sub \ + && ../../configure \ + $(AM_DISTCHECK_CONFIGURE_FLAGS) \ + $(DISTCHECK_CONFIGURE_FLAGS) \ + --srcdir=../.. --prefix="$$dc_install_base" \ + && $(MAKE) $(AM_MAKEFLAGS) \ + && $(MAKE) $(AM_MAKEFLAGS) dvi \ + && $(MAKE) $(AM_MAKEFLAGS) check \ + && $(MAKE) $(AM_MAKEFLAGS) install \ + && $(MAKE) $(AM_MAKEFLAGS) installcheck \ + && $(MAKE) $(AM_MAKEFLAGS) uninstall \ + && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \ + distuninstallcheck \ + && chmod -R a-w "$$dc_install_base" \ + && ({ \ + (cd ../.. && umask 077 && mkdir "$$dc_destdir") \ + && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \ + && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \ + && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \ + distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \ + } || { rm -rf "$$dc_destdir"; exit 1; }) \ + && rm -rf "$$dc_destdir" \ + && $(MAKE) $(AM_MAKEFLAGS) dist \ + && rm -rf $(DIST_ARCHIVES) \ + && $(MAKE) $(AM_MAKEFLAGS) distcleancheck \ + && cd "$$am__cwd" \ + || exit 1 + $(am__post_remove_distdir) + @(echo "$(distdir) archives ready for distribution: "; \ + list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \ + sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x' +distuninstallcheck: + @test -n '$(distuninstallcheck_dir)' || { \ + echo 'ERROR: trying to run $@ with an empty' \ + '$$(distuninstallcheck_dir)' >&2; \ + exit 1; \ + }; \ + $(am__cd) '$(distuninstallcheck_dir)' || { \ + echo 'ERROR: cannot chdir into $(distuninstallcheck_dir)' >&2; \ + exit 1; \ + }; \ + test `$(am__distuninstallcheck_listfiles) | wc -l` -eq 0 \ + || { echo "ERROR: files left after uninstall:" ; \ + if test -n "$(DESTDIR)"; then \ + echo " (check DESTDIR support)"; \ + fi ; \ + $(distuninstallcheck_listfiles) ; \ + exit 1; } >&2 +distcleancheck: distclean + @if test '$(srcdir)' = . ; then \ + echo "ERROR: distcleancheck can only run from a VPATH build" ; \ + exit 1 ; \ + fi + @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ + || { echo "ERROR: files left in build directory after distclean:" ; \ + $(distcleancheck_listfiles) ; \ + exit 1; } >&2 +check-am: all-am +check: check-recursive +all-am: Makefile $(SCRIPTS) $(DATA) +installdirs: installdirs-recursive +installdirs-am: + for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(pkgconfigdir)"; do \ + test -z "$$dir" || $(MKDIR_P) "$$dir"; \ + done +install: install-recursive +install-exec: install-exec-recursive +install-data: install-data-recursive +uninstall: uninstall-recursive + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-recursive +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-recursive + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-recursive + -rm -f $(am__CONFIG_DISTCLEAN_FILES) + -rm -f Makefile +distclean-am: clean-am distclean-generic distclean-libtool \ + distclean-tags + +dvi: dvi-recursive + +dvi-am: + +html: html-recursive + +html-am: + +info: info-recursive + +info-am: + +install-data-am: install-pkgconfigDATA + +install-dvi: install-dvi-recursive + +install-dvi-am: + +install-exec-am: install-binSCRIPTS + +install-html: install-html-recursive + +install-html-am: + +install-info: install-info-recursive + +install-info-am: + +install-man: + +install-pdf: install-pdf-recursive + +install-pdf-am: + +install-ps: install-ps-recursive + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-recursive + -rm -f $(am__CONFIG_DISTCLEAN_FILES) + -rm -rf $(top_srcdir)/autom4te.cache + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-recursive + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-recursive + +pdf-am: + +ps: ps-recursive + +ps-am: + +uninstall-am: uninstall-binSCRIPTS uninstall-pkgconfigDATA + +.MAKE: $(am__recursive_targets) install-am install-strip + +.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \ + am--refresh check check-am clean clean-cscope clean-generic \ + clean-libtool cscope cscopelist-am ctags ctags-am dist \ + dist-all dist-bzip2 dist-gzip dist-lzip dist-shar dist-tarZ \ + dist-xz dist-zip distcheck distclean distclean-generic \ + distclean-libtool distclean-tags distcleancheck distdir \ + distuninstallcheck dvi dvi-am html html-am info info-am \ + install install-am install-binSCRIPTS install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am install-info \ + install-info-am install-man install-pdf install-pdf-am \ + install-pkgconfigDATA install-ps install-ps-am install-strip \ + installcheck installcheck-am installdirs installdirs-am \ + maintainer-clean maintainer-clean-generic mostlyclean \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-am uninstall uninstall-am uninstall-binSCRIPTS \ + uninstall-pkgconfigDATA + +.PRECIOUS: Makefile + + +# Utility rule for making a release +release: dist-gzip dist-bzip2 + @echo Created release packages for ${PACKAGE}-${VERSION}. + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/libs/ode-0.16.1/OPCODE/COPYING b/libs/ode-0.16.1/OPCODE/COPYING new file mode 100644 index 0000000..54a62aa --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/COPYING @@ -0,0 +1,30 @@ +The OPCODE library distributed as part of ODE is licensed under +the same terms as ODE (LGPLv2.1+ and BSD). + +Quoting a public e-mail from the author: + + Re: TriMesh support and OPCODE added to ODE core + Pierre Terdiman wanadoo.fr> + 2003-07-01 21:18:44 GMT + + > If he wants + > to explicitly make it clear that OpCode is good under ODE's + > license, that would be A-1 Super... + + "Opcode is good under ODE's license" + + I didn't put a license to prevent boring questions about licenses, but it + seems it's not enough - I still get as many questions, regarding missing + license. + + The only thing that would NOT be good would be renaming it "TopCode", + changing the author's name, selling it at a very expensive price, and still + managing to make money out of it :) + + ...I should add a license explicitely against this :) + + Pierre + +Source: + http://permalink.gmane.org/gmane.comp.lib.ode/3237 + diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceAABB.cpp b/libs/ode-0.16.1/OPCODE/Ice/IceAABB.cpp new file mode 100644 index 0000000..d96cd88 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceAABB.cpp @@ -0,0 +1,405 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains AABB-related code. + * \file IceAABB.cpp + * \author Pierre Terdiman + * \date January, 29, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * AABB class. + * \class AABB + * \author Pierre Terdiman + * \version 1.0 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace IceMaths; + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the sum of two AABBs. + * \param aabb [in] the other AABB + * \return Self-Reference + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +AABB& AABB::Add(const AABB& aabb) +{ + // Compute new min & max values + Point Min; GetMin(Min); + Point Tmp; aabb.GetMin(Tmp); + Min.Min(Tmp); + + Point Max; GetMax(Max); + aabb.GetMax(Tmp); + Max.Max(Tmp); + + // Update this + SetMinMax(Min, Max); + return *this; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Makes a cube from the AABB. + * \param cube [out] the cube AABB + * \return cube edge length + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +float AABB::MakeCube(AABB& cube) const +{ + Point Ext; GetExtents(Ext); + float Max = Ext.Max(); + + Point Cnt; GetCenter(Cnt); + cube.SetCenterExtents(Cnt, Point(Max, Max, Max)); + return Max; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Makes a sphere from the AABB. + * \param sphere [out] sphere containing the AABB + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABB::MakeSphere(Sphere& sphere) const +{ + GetExtents(sphere.mCenter); + sphere.mRadius = sphere.mCenter.Magnitude() * 1.00001f; // To make sure sphere::Contains(*this) succeeds + GetCenter(sphere.mCenter); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Checks a box is inside another box. + * \param box [in] the other AABB + * \return true if current box is inside input box + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABB::IsInside(const AABB& box) const +{ + if(box.GetMin(0)>GetMin(0)) return false; + if(box.GetMin(1)>GetMin(1)) return false; + if(box.GetMin(2)>GetMin(2)) return false; + if(box.GetMax(0) max.x) ? 2 : 0) // 2 = right + + ((local_eye.y < min.y) ? 4 : 0) // 4 = bottom + + ((local_eye.y > max.y) ? 8 : 0) // 8 = top + + ((local_eye.z < min.z) ? 16 : 0) // 16 = front + + ((local_eye.z > max.z) ? 32 : 0); // 32 = back + + // Look up number of vertices in outline + num = (sdword)gIndexList[pos][7]; + // Zero indicates invalid case + if(!num) return null; + + return &gIndexList[pos][0]; +} + +// calculateBoxArea: computes the screen-projected 2D area of an oriented 3D bounding box + +//const Point& eye, //eye point (in bbox object coordinates) +//const AABB& box, //3d bbox +//const Matrix4x4& mat, //free transformation for bbox +//float width, float height, int& num) +float AABB::ComputeBoxArea(const Point& eye, const Matrix4x4& mat, float width, float height, sdword& num) const +{ + const sbyte* Outline = ComputeOutline(eye, num); + if(!Outline) return -1.0f; + + // Compute box vertices + Point vertexBox[8], dst[8]; + ComputePoints(vertexBox); + + // Transform all outline corners into 2D screen space + for(sdword i=0;i GetMax(0) || p.x < GetMin(0)) return FALSE; \ + if(p.y > GetMax(1) || p.y < GetMin(1)) return FALSE; \ + if(p.z > GetMax(2) || p.z < GetMin(2)) return FALSE; \ + return TRUE; \ + } + + enum AABBType + { + AABB_RENDER = 0, //!< AABB used for rendering. Not visible == not rendered. + AABB_UPDATE = 1, //!< AABB used for dynamic updates. Not visible == not updated. + + AABB_FORCE_DWORD = 0x7fffffff, + }; + +#ifdef USE_MINMAX + + struct ICEMATHS_API ShadowAABB + { + Point mMin; + Point mMax; + }; + + class ICEMATHS_API AABB + { + public: + //! Constructor + inline_ AABB() {} + //! Destructor + inline_ ~AABB() {} + + //! Type-independent methods + AABB_COMMON_METHODS; + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Setups an AABB from min & max vectors. + * \param min [in] the min point + * \param max [in] the max point + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + void SetMinMax(const Point& min, const Point& max) { mMin = min; mMax = max; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Setups an AABB from center & extents vectors. + * \param c [in] the center point + * \param e [in] the extents vector + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + void SetCenterExtents(const Point& c, const Point& e) { mMin = c - e; mMax = c + e; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Setups an empty AABB. + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + void SetEmpty() { Point p(MIN_FLOAT, MIN_FLOAT, MIN_FLOAT); mMin = -p; mMax = p;} + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Setups a point AABB. + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + void SetPoint(const Point& pt) { mMin = mMax = pt; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets the size of the AABB. The size is defined as the longest extent. + * \return the size of the AABB + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + float GetSize() const { Point e; GetExtents(e); return e.Max(); } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Extends the AABB. + * \param p [in] the next point + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + void Extend(const Point& p) + { + if(p.x > mMax.x) mMax.x = p.x; + if(p.x < mMin.x) mMin.x = p.x; + + if(p.y > mMax.y) mMax.y = p.y; + if(p.y < mMin.y) mMin.y = p.y; + + if(p.z > mMax.z) mMax.z = p.z; + if(p.z < mMin.z) mMin.z = p.z; + } + // Data access + + //! Get min point of the box + inline_ void GetMin(Point& min) const { min = mMin; } + //! Get max point of the box + inline_ void GetMax(Point& max) const { max = mMax; } + + //! Get component of the box's min point along a given axis + inline_ float GetMin(udword axis) const { return mMin[axis]; } + //! Get component of the box's max point along a given axis + inline_ float GetMax(udword axis) const { return mMax[axis]; } + + //! Get box center + inline_ void GetCenter(Point& center) const { center = (mMax + mMin)*0.5f; } + //! Get box extents + inline_ void GetExtents(Point& extents) const { extents = (mMax - mMin)*0.5f; } + + //! Get component of the box's center along a given axis + inline_ float GetCenter(udword axis) const { return (mMax[axis] + mMin[axis])*0.5f; } + //! Get component of the box's extents along a given axis + inline_ float GetExtents(udword axis) const { return (mMax[axis] - mMin[axis])*0.5f; } + + //! Get box diagonal + inline_ void GetDiagonal(Point& diagonal) const { diagonal = mMax - mMin; } + inline_ float GetWidth() const { return mMax.x - mMin.x; } + inline_ float GetHeight() const { return mMax.y - mMin.y; } + inline_ float GetDepth() const { return mMax.z - mMin.z; } + + //! Volume + inline_ float GetVolume() const { return GetWidth() * GetHeight() * GetDepth(); } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Computes the intersection between two AABBs. + * \param a [in] the other AABB + * \return true on intersection + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ BOOL Intersect(const AABB& a) const + { + if(mMax.x < a.mMin.x + || a.mMax.x < mMin.x + || mMax.y < a.mMin.y + || a.mMax.y < mMin.y + || mMax.z < a.mMin.z + || a.mMax.z < mMin.z) return FALSE; + + return TRUE; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Computes the 1D-intersection between two AABBs, on a given axis. + * \param a [in] the other AABB + * \param axis [in] the axis (0, 1, 2) + * \return true on intersection + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ BOOL Intersect(const AABB& a, udword axis) const + { + if(mMax[axis] < a.mMin[axis] || a.mMax[axis] < mMin[axis]) return FALSE; + return TRUE; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Recomputes the AABB after an arbitrary transform by a 4x4 matrix. + * Original code by Charles Bloom on the GD-Algorithm list. (I slightly modified it) + * \param mtx [in] the transform matrix + * \param aabb [out] the transformed AABB [can be *this] + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void Rotate(const Matrix4x4& mtx, AABB& aabb) const + { + // The three edges transformed: you can efficiently transform an X-only vector + // by just getting the "X" column of the matrix + Point vx,vy,vz; + mtx.GetRow(0, vx); vx *= (mMax.x - mMin.x); + mtx.GetRow(1, vy); vy *= (mMax.y - mMin.y); + mtx.GetRow(2, vz); vz *= (mMax.z - mMin.z); + + // Transform the min point + aabb.mMin = aabb.mMax = mMin * mtx; + + // Take the transformed min & axes and find new extents + // Using CPU code in the right place is faster... + if(IS_NEGATIVE_FLOAT(vx.x)) aabb.mMin.x += vx.x; else aabb.mMax.x += vx.x; + if(IS_NEGATIVE_FLOAT(vx.y)) aabb.mMin.y += vx.y; else aabb.mMax.y += vx.y; + if(IS_NEGATIVE_FLOAT(vx.z)) aabb.mMin.z += vx.z; else aabb.mMax.z += vx.z; + if(IS_NEGATIVE_FLOAT(vy.x)) aabb.mMin.x += vy.x; else aabb.mMax.x += vy.x; + if(IS_NEGATIVE_FLOAT(vy.y)) aabb.mMin.y += vy.y; else aabb.mMax.y += vy.y; + if(IS_NEGATIVE_FLOAT(vy.z)) aabb.mMin.z += vy.z; else aabb.mMax.z += vy.z; + if(IS_NEGATIVE_FLOAT(vz.x)) aabb.mMin.x += vz.x; else aabb.mMax.x += vz.x; + if(IS_NEGATIVE_FLOAT(vz.y)) aabb.mMin.y += vz.y; else aabb.mMax.y += vz.y; + if(IS_NEGATIVE_FLOAT(vz.z)) aabb.mMin.z += vz.z; else aabb.mMax.z += vz.z; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Checks the AABB is valid. + * \return true if the box is valid + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ BOOL IsValid() const + { + // Consistency condition for (Min, Max) boxes: min < max + if(mMin.x > mMax.x) return FALSE; + if(mMin.y > mMax.y) return FALSE; + if(mMin.z > mMax.z) return FALSE; + return TRUE; + } + + //! Operator for AABB *= float. Scales the extents, keeps same center. + inline_ AABB& operator*=(float s) + { + Point Center; GetCenter(Center); + Point Extents; GetExtents(Extents); + SetCenterExtents(Center, Extents * s); + return *this; + } + + //! Operator for AABB /= float. Scales the extents, keeps same center. + inline_ AABB& operator/=(float s) + { + Point Center; GetCenter(Center); + Point Extents; GetExtents(Extents); + SetCenterExtents(Center, Extents / s); + return *this; + } + + //! Operator for AABB += Point. Translates the box. + inline_ AABB& operator+=(const Point& trans) + { + mMin+=trans; + mMax+=trans; + return *this; + } + private: + Point mMin; //!< Min point + Point mMax; //!< Max point + }; + +#else + + class ICEMATHS_API AABB + { + public: + //! Constructor + inline_ AABB() {} + //! Destructor + inline_ ~AABB() {} + + //! Type-independent methods + AABB_COMMON_METHODS; + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Setups an AABB from min & max vectors. + * \param min [in] the min point + * \param max [in] the max point + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + void SetMinMax(const Point& min, const Point& max) { mCenter = (max + min)*0.5f; mExtents = (max - min)*0.5f; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Setups an AABB from center & extents vectors. + * \param c [in] the center point + * \param e [in] the extents vector + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + void SetCenterExtents(const Point& c, const Point& e) { mCenter = c; mExtents = e; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Setups an empty AABB. + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + void SetEmpty() { mCenter.Zero(); mExtents.Set(MIN_FLOAT, MIN_FLOAT, MIN_FLOAT);} + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Setups a point AABB. + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + void SetPoint(const Point& pt) { mCenter = pt; mExtents.Zero(); } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets the size of the AABB. The size is defined as the longest extent. + * \return the size of the AABB + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + float GetSize() const { return mExtents.Max(); } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Extends the AABB. + * \param p [in] the next point + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + void Extend(const Point& p) + { + Point Max = mCenter + mExtents; + Point Min = mCenter - mExtents; + + if(p.x > Max.x) Max.x = p.x; + if(p.x < Min.x) Min.x = p.x; + + if(p.y > Max.y) Max.y = p.y; + if(p.y < Min.y) Min.y = p.y; + + if(p.z > Max.z) Max.z = p.z; + if(p.z < Min.z) Min.z = p.z; + + SetMinMax(Min, Max); + } + // Data access + + //! Get min point of the box + inline_ void GetMin(Point& min) const { min = mCenter - mExtents; } + //! Get max point of the box + inline_ void GetMax(Point& max) const { max = mCenter + mExtents; } + + //! Get component of the box's min point along a given axis + inline_ float GetMin(udword axis) const { return mCenter[axis] - mExtents[axis]; } + //! Get component of the box's max point along a given axis + inline_ float GetMax(udword axis) const { return mCenter[axis] + mExtents[axis]; } + + //! Get box center + inline_ void GetCenter(Point& center) const { center = mCenter; } + //! Get box extents + inline_ void GetExtents(Point& extents) const { extents = mExtents; } + + //! Get component of the box's center along a given axis + inline_ float GetCenter(udword axis) const { return mCenter[axis]; } + //! Get component of the box's extents along a given axis + inline_ float GetExtents(udword axis) const { return mExtents[axis]; } + + //! Get box diagonal + inline_ void GetDiagonal(Point& diagonal) const { diagonal = mExtents * 2.0f; } + inline_ float GetWidth() const { return mExtents.x * 2.0f; } + inline_ float GetHeight() const { return mExtents.y * 2.0f; } + inline_ float GetDepth() const { return mExtents.z * 2.0f; } + + //! Volume + inline_ float GetVolume() const { return mExtents.x * mExtents.y * mExtents.z * 8.0f; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Computes the intersection between two AABBs. + * \param a [in] the other AABB + * \return true on intersection + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ BOOL Intersect(const AABB& a) const + { + float tx = mCenter.x - a.mCenter.x; float ex = a.mExtents.x + mExtents.x; if(AIR(tx) > IR(ex)) return FALSE; + float ty = mCenter.y - a.mCenter.y; float ey = a.mExtents.y + mExtents.y; if(AIR(ty) > IR(ey)) return FALSE; + float tz = mCenter.z - a.mCenter.z; float ez = a.mExtents.z + mExtents.z; if(AIR(tz) > IR(ez)) return FALSE; + return TRUE; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * The standard intersection method from Gamasutra. Just here to check its speed against the one above. + * \param a [in] the other AABB + * \return true on intersection + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ bool GomezIntersect(const AABB& a) + { + Point T = mCenter - a.mCenter; // Vector from A to B + return ((fabsf(T.x) <= (a.mExtents.x + mExtents.x)) + && (fabsf(T.y) <= (a.mExtents.y + mExtents.y)) + && (fabsf(T.z) <= (a.mExtents.z + mExtents.z))); + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Computes the 1D-intersection between two AABBs, on a given axis. + * \param a [in] the other AABB + * \param axis [in] the axis (0, 1, 2) + * \return true on intersection + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ BOOL Intersect(const AABB& a, udword axis) const + { + float t = mCenter[axis] - a.mCenter[axis]; + float e = a.mExtents[axis] + mExtents[axis]; + if(AIR(t) > IR(e)) return FALSE; + return TRUE; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Recomputes the AABB after an arbitrary transform by a 4x4 matrix. + * \param mtx [in] the transform matrix + * \param aabb [out] the transformed AABB [can be *this] + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void Rotate(const Matrix4x4& mtx, AABB& aabb) const + { + // Compute new center + aabb.mCenter = mCenter * mtx; + + // Compute new extents. FPU code & CPU code have been interleaved for improved performance. + Point Ex(mtx.m[0][0] * mExtents.x, mtx.m[0][1] * mExtents.x, mtx.m[0][2] * mExtents.x); + //IR(Ex.x)&=0x7fffffff; IR(Ex.y)&=0x7fffffff; IR(Ex.z)&=0x7fffffff; + Ex.x = FR( AIR(Ex.x) ); + Ex.y = FR( AIR(Ex.y) ); + Ex.z = FR( AIR(Ex.z) ); + + Point Ey(mtx.m[1][0] * mExtents.y, mtx.m[1][1] * mExtents.y, mtx.m[1][2] * mExtents.y); + //IR(Ey.x)&=0x7fffffff; IR(Ey.y)&=0x7fffffff; IR(Ey.z)&=0x7fffffff; + Ey.x = FR( AIR(Ey.x) ); + Ey.y = FR( AIR(Ey.y) ); + Ey.z = FR( AIR(Ey.z) ); + + Point Ez(mtx.m[2][0] * mExtents.z, mtx.m[2][1] * mExtents.z, mtx.m[2][2] * mExtents.z); + //IR(Ez.x)&=0x7fffffff; IR(Ez.y)&=0x7fffffff; IR(Ez.z)&=0x7fffffff; + Ez.x = FR( AIR(Ez.x) ); + Ez.y = FR( AIR(Ez.y) ); + Ez.z = FR( AIR(Ez.z) ); + + aabb.mExtents.x = Ex.x + Ey.x + Ez.x; + aabb.mExtents.y = Ex.y + Ey.y + Ez.y; + aabb.mExtents.z = Ex.z + Ey.z + Ez.z; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Checks the AABB is valid. + * \return true if the box is valid + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ BOOL IsValid() const + { + // Consistency condition for (Center, Extents) boxes: Extents >= 0 + if(IS_NEGATIVE_FLOAT(mExtents.x)) return FALSE; + if(IS_NEGATIVE_FLOAT(mExtents.y)) return FALSE; + if(IS_NEGATIVE_FLOAT(mExtents.z)) return FALSE; + return TRUE; + } + + //! Operator for AABB *= float. Scales the extents, keeps same center. + inline_ AABB& operator*=(float s) { mExtents*=s; return *this; } + + //! Operator for AABB /= float. Scales the extents, keeps same center. + inline_ AABB& operator/=(float s) { mExtents/=s; return *this; } + + //! Operator for AABB += Point. Translates the box. + inline_ AABB& operator+=(const Point& trans) + { + mCenter+=trans; + return *this; + } + private: + Point mCenter; //!< AABB Center + Point mExtents; //!< x, y and z extents + }; + +#endif + + inline_ void ComputeMinMax(const Point& p, Point& min, Point& max) + { + if(p.x > max.x) max.x = p.x; + if(p.x < min.x) min.x = p.x; + + if(p.y > max.y) max.y = p.y; + if(p.y < min.y) min.y = p.y; + + if(p.z > max.z) max.z = p.z; + if(p.z < min.z) min.z = p.z; + } + + inline_ void ComputeAABB(AABB& aabb, const Point* list, udword nb_pts) + { + if(list) + { + Point Maxi(MIN_FLOAT, MIN_FLOAT, MIN_FLOAT); + Point Mini(MAX_FLOAT, MAX_FLOAT, MAX_FLOAT); + while(nb_pts--) + { +// _prefetch(list+1); // off by one ? + ComputeMinMax(*list++, Mini, Maxi); + } + aabb.SetMinMax(Mini, Maxi); + } + } + +#endif // __ICEAABB_H__ diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceAxes.h b/libs/ode-0.16.1/OPCODE/Ice/IceAxes.h new file mode 100644 index 0000000..8af57e1 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceAxes.h @@ -0,0 +1,54 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains axes definition. + * \file IceAxes.h + * \author Pierre Terdiman + * \date January, 29, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __ICEAXES_H__ +#define __ICEAXES_H__ + + enum PointComponent + { + X = 0, + Y = 1, + Z = 2, + W = 3, + + FORCE_DWORD = 0x7fffffff + }; + + enum AxisOrder + { + AXES_XYZ = (X)|(Y<<2)|(Z<<4), + AXES_XZY = (X)|(Z<<2)|(Y<<4), + AXES_YXZ = (Y)|(X<<2)|(Z<<4), + AXES_YZX = (Y)|(Z<<2)|(X<<4), + AXES_ZXY = (Z)|(X<<2)|(Y<<4), + AXES_ZYX = (Z)|(Y<<2)|(X<<4), + + AXES_FORCE_DWORD = 0x7fffffff + }; + + class ICEMATHS_API Axes + { + public: + + inline_ Axes(AxisOrder order) + { + mAxis0 = (order ) & 3; + mAxis1 = (order>>2) & 3; + mAxis2 = (order>>4) & 3; + } + inline_ ~Axes() {} + + udword mAxis0; + udword mAxis1; + udword mAxis2; + }; + +#endif // __ICEAXES_H__ diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceBoundingSphere.h b/libs/ode-0.16.1/OPCODE/Ice/IceBoundingSphere.h new file mode 100644 index 0000000..945d38c --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceBoundingSphere.h @@ -0,0 +1,142 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code to compute the minimal bounding sphere. + * \file IceBoundingSphere.h + * \author Pierre Terdiman + * \date January, 29, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __ICEBOUNDINGSPHERE_H__ +#define __ICEBOUNDINGSPHERE_H__ + + enum BSphereMethod + { + BS_NONE, + BS_GEMS, + BS_MINIBALL, + + BS_FORCE_DWORD = 0x7fffffff + }; + + class ICEMATHS_API Sphere + { + public: + //! Constructor + inline_ Sphere() {} + //! Constructor + inline_ Sphere(const Point& center, float radius) : mCenter(center), mRadius(radius) {} + //! Constructor + Sphere(udword nb_verts, const Point* verts); + //! Copy constructor + inline_ Sphere(const Sphere& sphere) : mCenter(sphere.mCenter), mRadius(sphere.mRadius) {} + //! Destructor + inline_ ~Sphere() {} + + BSphereMethod Compute(udword nb_verts, const Point* verts); + bool FastCompute(udword nb_verts, const Point* verts); + + // Access methods + inline_ const Point& GetCenter() const { return mCenter; } + inline_ float GetRadius() const { return mRadius; } + + inline_ const Point& Center() const { return mCenter; } + inline_ float Radius() const { return mRadius; } + + inline_ Sphere& Set(const Point& center, float radius) { mCenter = center; mRadius = radius; return *this; } + inline_ Sphere& SetCenter(const Point& center) { mCenter = center; return *this; } + inline_ Sphere& SetRadius(float radius) { mRadius = radius; return *this; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Tests if a point is contained within the sphere. + * \param p [in] the point to test + * \return true if inside the sphere + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ bool Contains(const Point& p) const + { + return mCenter.SquareDistance(p) <= mRadius*mRadius; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Tests if a sphere is contained within the sphere. + * \param sphere [in] the sphere to test + * \return true if inside the sphere + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ bool Contains(const Sphere& sphere) const + { + // If our radius is the smallest, we can't possibly contain the other sphere + if(mRadius < sphere.mRadius) return false; + // So r is always positive or null now + float r = mRadius - sphere.mRadius; + return mCenter.SquareDistance(sphere.mCenter) <= r*r; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Tests if a box is contained within the sphere. + * \param aabb [in] the box to test + * \return true if inside the sphere + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ BOOL Contains(const AABB& aabb) const + { + // I assume if all 8 box vertices are inside the sphere, so does the whole box. + // Sounds ok but maybe there's a better way? + float R2 = mRadius * mRadius; +#ifdef USE_MIN_MAX + const Point& Max = ((ShadowAABB&)&aabb).mMax; + const Point& Min = ((ShadowAABB&)&aabb).mMin; +#else + Point Max; aabb.GetMax(Max); + Point Min; aabb.GetMin(Min); +#endif + Point p; + p.x=Max.x; p.y=Max.y; p.z=Max.z; if(mCenter.SquareDistance(p)>=R2) return FALSE; + p.x=Min.x; if(mCenter.SquareDistance(p)>=R2) return FALSE; + p.x=Max.x; p.y=Min.y; if(mCenter.SquareDistance(p)>=R2) return FALSE; + p.x=Min.x; if(mCenter.SquareDistance(p)>=R2) return FALSE; + p.x=Max.x; p.y=Max.y; p.z=Min.z; if(mCenter.SquareDistance(p)>=R2) return FALSE; + p.x=Min.x; if(mCenter.SquareDistance(p)>=R2) return FALSE; + p.x=Max.x; p.y=Min.y; if(mCenter.SquareDistance(p)>=R2) return FALSE; + p.x=Min.x; if(mCenter.SquareDistance(p)>=R2) return FALSE; + + return TRUE; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Tests if the sphere intersects another sphere + * \param sphere [in] the other sphere + * \return true if spheres overlap + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ bool Intersect(const Sphere& sphere) const + { + float r = mRadius + sphere.mRadius; + return mCenter.SquareDistance(sphere.mCenter) <= r*r; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Checks the sphere is valid. + * \return true if the box is valid + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ BOOL IsValid() const + { + // Consistency condition for spheres: Radius >= 0.0f + if(mRadius < 0.0f) return FALSE; + return TRUE; + } + public: + Point mCenter; //!< Sphere center + float mRadius; //!< Sphere radius + }; + +#endif // __ICEBOUNDINGSPHERE_H__ diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceContainer.cpp b/libs/ode-0.16.1/OPCODE/Ice/IceContainer.cpp new file mode 100644 index 0000000..3eeefe0 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceContainer.cpp @@ -0,0 +1,357 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains a simple container class. + * \file IceContainer.cpp + * \author Pierre Terdiman + * \date February, 5, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains a list of 32-bits values. + * Use this class when you need to store an unknown number of values. The list is automatically + * resized and can contains 32-bits entities (dwords or floats) + * + * \class Container + * \author Pierre Terdiman + * \version 1.0 + * \date 08.15.98 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace IceCore; + +#define MAX_RESERVE_GROWTH_SIZE 65536U + +// Static members +#ifdef CONTAINER_STATS +udword Container::mNbContainers = 0; +udword Container::mUsedRam = 0; +#endif + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. No entries allocated there. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +Container::Container() : mMaxNbEntries(0), mCurNbEntries(0), mEntries(null), mGrowthFactor(2) +{ +#ifdef CONTAINER_STATS + mNbContainers++; + mUsedRam+=sizeof(Container); +#endif +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. Also allocates a given number of entries. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +Container::Container(udword size, float growth_factor) : mMaxNbEntries(0), mCurNbEntries(0), mEntries(null), mGrowthFactor(growth_factor) +{ +#ifdef CONTAINER_STATS + mNbContainers++; + mUsedRam+=sizeof(Container); +#endif + SetSize(size); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Copy constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +Container::Container(const Container& object) : mMaxNbEntries(0), mCurNbEntries(0), mEntries(null), mGrowthFactor(2) +{ +#ifdef CONTAINER_STATS + mNbContainers++; + mUsedRam+=sizeof(Container); +#endif + *this = object; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. Frees everything and leaves. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +Container::~Container() +{ + Empty(); +#ifdef CONTAINER_STATS + mNbContainers--; + mUsedRam-=GetUsedRam(); +#endif +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Clears the container. All stored values are deleted, and it frees used ram. + * \see Reset() + * \return Self-Reference + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +Container& Container::Empty() +{ +#ifdef CONTAINER_STATS + mUsedRam-=mMaxNbEntries*sizeof(udword); +#endif + DELETEARRAY(mEntries); + mCurNbEntries = mMaxNbEntries = 0; + return *this; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Resizes the container. + * \param needed [in] assume the container can be added at least "needed" values + * \return true if success. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool Container::Resize(udword needed) +{ +#ifdef CONTAINER_STATS + // Subtract previous amount of bytes + mUsedRam-=mMaxNbEntries*sizeof(udword); +#endif + + if (MAX_UDWORD - mCurNbEntries < needed) + { + CHECKALLOC(null); + } + + // Get more entries + udword NewMaxNbEntries = mMaxNbEntries ? udword(mMaxNbEntries * mGrowthFactor) : 2; // Default nb Entries = 2 + + if (NewMaxNbEntries <= mMaxNbEntries) NewMaxNbEntries = MAX_UDWORD - mMaxNbEntries < MAX_RESERVE_GROWTH_SIZE ? MAX_UDWORD : mMaxNbEntries + MAX_RESERVE_GROWTH_SIZE; + else if (NewMaxNbEntries - mMaxNbEntries > MAX_RESERVE_GROWTH_SIZE) NewMaxNbEntries = mMaxNbEntries + MAX_RESERVE_GROWTH_SIZE; + + if (NewMaxNbEntries < mCurNbEntries + needed) NewMaxNbEntries = mCurNbEntries + needed; + + // Get some bytes for new entries + udword* NewEntries = new udword[NewMaxNbEntries]; + CHECKALLOC(NewEntries); + + // Copy old data if needed + if(mCurNbEntries) CopyMemory(NewEntries, mEntries, mCurNbEntries*sizeof(udword)); + + // Delete old data + DELETEARRAY(mEntries); + + // Assign new pointer + mEntries = NewEntries; + mMaxNbEntries = NewMaxNbEntries; + +#ifdef CONTAINER_STATS + // Add current amount of bytes + mUsedRam+=mMaxNbEntries*sizeof(udword); +#endif + + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Sets the initial size of the container. If it already contains something, it's discarded. + * \param nb [in] Number of entries + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool Container::SetSize(udword nb) +{ + // Make sure it's empty + Empty(); + + // Checkings + if(!nb) return false; + + // Initialize for nb entries + mMaxNbEntries = nb; + + // Get some bytes for new entries + mEntries = new udword[mMaxNbEntries]; + CHECKALLOC(mEntries); + +#ifdef CONTAINER_STATS + // Add current amount of bytes + mUsedRam+=mMaxNbEntries*sizeof(udword); +#endif + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Refits the container and get rid of unused bytes. + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool Container::Refit() +{ +#ifdef CONTAINER_STATS + // Subtract previous amount of bytes + mUsedRam-=mMaxNbEntries*sizeof(udword); +#endif + + // Get just enough entries + mMaxNbEntries = mCurNbEntries; + if(!mMaxNbEntries) return false; + + // Get just enough bytes + udword* NewEntries = new udword[mMaxNbEntries]; + CHECKALLOC(NewEntries); + +#ifdef CONTAINER_STATS + // Add current amount of bytes + mUsedRam+=mMaxNbEntries*sizeof(udword); +#endif + + // Copy old data + CopyMemory(NewEntries, mEntries, mCurNbEntries*sizeof(udword)); + + // Delete old data + DELETEARRAY(mEntries); + + // Assign new pointer + mEntries = NewEntries; + + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Checks whether the container already contains a given value. + * \param entry [in] the value to look for in the container + * \param location [out] a possible pointer to store the entry location + * \see Add(udword entry) + * \see Add(float entry) + * \see Empty() + * \return true if the value has been found in the container, else false. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool Container::Contains(udword entry, udword* location) const +{ + // Look for the entry + for(udword i=0;i mMaxNbEntries + && !Resize(nb)) + { + IceAbort(); + } + + // Add new entry + CopyMemory(&mEntries[mCurNbEntries], entries, nb*sizeof(uword)); + mCurNbEntries+=nb; + return *this; + } + + inline_ Container& Add(const udword* entries, udword nb) + { + // Resize if needed + if (mCurNbEntries + nb > mMaxNbEntries + && !Resize(nb)) + { + IceAbort(); + } + + // Add new entry + CopyMemory(&mEntries[mCurNbEntries], entries, nb*sizeof(udword)); + mCurNbEntries+=nb; + return *this; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * A O(1) method to add a value in the container. The container is automatically resized if needed. + * The method is inline, not the resize. The call overhead happens on resizes only, which is not a problem since the resizing operation + * costs a lot more than the call overhead... + * + * \param entry [in] a float to store in the container + * \see Add(udword entry) + * \see Empty() + * \see Contains(udword entry) + * \return Self-Reference + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ Container& Add(float entry) + { + // Resize if needed + if (mCurNbEntries == mMaxNbEntries + && !Resize()) + { + IceAbort(); + } + + // Add new entry + mEntries[mCurNbEntries++] = IR(entry); + return *this; + } + + inline_ Container& Add(const float* entries, udword nb) + { + // Resize if needed + if (mCurNbEntries + nb > mMaxNbEntries + && !Resize(nb)) + { + IceAbort(); + } + + // Add new entry + CopyMemory(&mEntries[mCurNbEntries], entries, nb*sizeof(float)); + mCurNbEntries+=nb; + return *this; + } + + //! Add unique [slow] + inline_ Container& AddUnique(udword entry) + { + if(!Contains(entry)) Add(entry); + return *this; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Clears the container. All stored values are deleted, and it frees used ram. + * \see Reset() + * \return Self-Reference + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + Container& Empty(); + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Resets the container. Stored values are discarded but the buffer is kept so that further calls don't need resizing again. + * That's a kind of temporal coherence. + * \see Empty() + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void Reset() + { + // Avoid the write if possible + // ### CMOV + if(mCurNbEntries) mCurNbEntries = 0; + } + + // HANDLE WITH CARE + inline_ void ForceSize(udword size) + { + mCurNbEntries = size; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Sets the initial size of the container. If it already contains something, it's discarded. + * \param nb [in] Number of entries + * \return true if success + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + bool SetSize(udword nb); + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Refits the container and get rid of unused bytes. + * \return true if success + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + bool Refit(); + + // Checks whether the container already contains a given value. + bool Contains(udword entry, udword* location=null) const; + // Deletes an entry - doesn't preserve insertion order. + bool Delete(udword entry); + // Deletes an entry - does preserve insertion order. + bool DeleteKeepingOrder(udword entry); + //! Deletes the very last entry. + inline_ void DeleteLastEntry() { if(mCurNbEntries) mCurNbEntries--; } + //! Deletes the entry whose index is given + inline_ void DeleteIndex(udword index) { ASSERT(index < mCurNbEntries); mEntries[index] = mEntries[--mCurNbEntries]; } + + // Helpers + Container& FindNext(udword& entry, FindMode find_mode=FIND_CLAMP); + Container& FindPrev(udword& entry, FindMode find_mode=FIND_CLAMP); + // Data access. + inline_ udword GetNbEntries() const { return mCurNbEntries; } //!< Returns the current number of entries. + inline_ udword GetEntry(udword i) const { return mEntries[i]; } //!< Returns ith entry + inline_ udword* GetEntries() const { return mEntries; } //!< Returns the list of entries. + + inline_ udword GetFirst() const { return mEntries[0]; } + inline_ udword GetLast() const { return mEntries[mCurNbEntries-1]; } + + // Growth control + inline_ udword GetGrowthFactor() const { return mGrowthFactor; } //!< Returns the growth factor + inline_ void SetGrowthFactor(udword growth) { mGrowthFactor = growth; } //!< Sets the growth factor + inline_ bool IsFull() const { return mCurNbEntries==mMaxNbEntries; } //!< Checks the container is full + inline_ BOOL IsNotEmpty() const { return mCurNbEntries; } //!< Checks the container is empty + + //! Read-access as an array + inline_ udword operator[](udword i) const { ASSERT(i>=0 && i=0 && i>31); + return FR(y); + } + + //! Computes 1.0f / sqrtf(x). + inline_ float frsqrt(float f) + { + float x = f * 0.5f; + udword y = 0x5f3759df - (IR(f) >> 1); + // Iteration... + const float fy = FR(y); + const float result = fy * ( 1.5f - ( x * fy * fy ) ); + // Result + return result; + } + + //! Computes 1.0f / sqrtf(x). Comes from NVIDIA. + inline_ float InvSqrt(const float& x) + { + const udword tmp = (udword(IEEE_1_0 << 1) + IEEE_1_0 - IR(x)) >> 1; + const float y = FR(tmp); + return y * (1.47f - 0.47f * x * y * y); + } + + //! Computes 1.0f / sqrtf(x). Comes from Quake3. Looks like the first one I had above. + //! See http://www.magic-software.com/3DGEDInvSqrt.html + inline_ float RSqrt(float number) + { + int i; + float x2, y; + const float threehalfs = 1.5f; + + x2 = number * 0.5f; + y = number; + i = IR(y); + i = 0x5f3759df - (i >> 1); + y = FR(i); + y = y * (threehalfs - (x2 * y * y)); + + return y; + } + + //! TO BE DOCUMENTED + inline_ float fsqrt(float f) + { + udword y = ( ( SIR(f) - 0x3f800000 ) >> 1 ) + 0x3f800000; + // Iteration...? + // (float&)y = (3.0f - ((float&)y * (float&)y) / f) * (float&)y * 0.5f; + // Result + return FR(y); + } + + //! Returns the float ranged espilon value. + inline_ float fepsilon(float f) + { + udword b = IR(f) & 0xff800000; + udword a = b | 0x00000001; + // Result + return FR(a) - FR(b); + } + + //! Is the float valid ? + inline_ bool IsNAN(float value) { return (IR(value)&0x7f800000) == 0x7f800000; } + inline_ bool IsIndeterminate(float value) { return IR(value) == 0xffc00000; } + inline_ bool IsPlusInf(float value) { return IR(value) == 0x7f800000; } + inline_ bool IsMinusInf(float value) { return IR(value) == 0xff800000; } + + inline_ bool IsValidFloat(float value) + { + if(IsNAN(value)) return false; + if(IsIndeterminate(value)) return false; + if(IsPlusInf(value)) return false; + if(IsMinusInf(value)) return false; + return true; + } + + #define CHECK_VALID_FLOAT(x) ASSERT(IsValidFloat(x)); + +/* + //! FPU precision setting function. + inline_ void SetFPU() + { + // This function evaluates whether the floating-point + // control word is set to single precision/round to nearest/ + // exceptions disabled. If these conditions don't hold, the + // function changes the control word to set them and returns + // TRUE, putting the old control word value in the passback + // location pointed to by pwOldCW. + { + uword wTemp, wSave; + + __asm fstcw wSave + if (wSave & 0x300 || // Not single mode + 0x3f != (wSave & 0x3f) || // Exceptions enabled + wSave & 0xC00) // Not round to nearest mode + { + __asm + { + mov ax, wSave + and ax, not 300h ;; single mode + or ax, 3fh ;; disable all exceptions + and ax, not 0xC00 ;; round to nearest mode + mov wTemp, ax + fldcw wTemp + } + } + } + } +*/ + //! This function computes the slowest possible floating-point value (you can also directly use FLT_EPSILON) + inline_ float ComputeFloatEpsilon() + { + const float f = FR( IR(1.0f) ^ 1 ); + return f - 1.0f; // You can check it's the same as FLT_EPSILON + } + + inline_ bool IsFloatZero(float x, float epsilon=1e-6f) + { + return x*x < epsilon; + } + + #define FCOMI_ST0 _asm _emit 0xdb _asm _emit 0xf0 + #define FCOMIP_ST0 _asm _emit 0xdf _asm _emit 0xf0 + #define FCMOVB_ST0 _asm _emit 0xda _asm _emit 0xc0 + #define FCMOVNB_ST0 _asm _emit 0xdb _asm _emit 0xc0 + + #define FCOMI_ST1 _asm _emit 0xdb _asm _emit 0xf1 + #define FCOMIP_ST1 _asm _emit 0xdf _asm _emit 0xf1 + #define FCMOVB_ST1 _asm _emit 0xda _asm _emit 0xc1 + #define FCMOVNB_ST1 _asm _emit 0xdb _asm _emit 0xc1 + + #define FCOMI_ST2 _asm _emit 0xdb _asm _emit 0xf2 + #define FCOMIP_ST2 _asm _emit 0xdf _asm _emit 0xf2 + #define FCMOVB_ST2 _asm _emit 0xda _asm _emit 0xc2 + #define FCMOVNB_ST2 _asm _emit 0xdb _asm _emit 0xc2 + + #define FCOMI_ST3 _asm _emit 0xdb _asm _emit 0xf3 + #define FCOMIP_ST3 _asm _emit 0xdf _asm _emit 0xf3 + #define FCMOVB_ST3 _asm _emit 0xda _asm _emit 0xc3 + #define FCMOVNB_ST3 _asm _emit 0xdb _asm _emit 0xc3 + + #define FCOMI_ST4 _asm _emit 0xdb _asm _emit 0xf4 + #define FCOMIP_ST4 _asm _emit 0xdf _asm _emit 0xf4 + #define FCMOVB_ST4 _asm _emit 0xda _asm _emit 0xc4 + #define FCMOVNB_ST4 _asm _emit 0xdb _asm _emit 0xc4 + + #define FCOMI_ST5 _asm _emit 0xdb _asm _emit 0xf5 + #define FCOMIP_ST5 _asm _emit 0xdf _asm _emit 0xf5 + #define FCMOVB_ST5 _asm _emit 0xda _asm _emit 0xc5 + #define FCMOVNB_ST5 _asm _emit 0xdb _asm _emit 0xc5 + + #define FCOMI_ST6 _asm _emit 0xdb _asm _emit 0xf6 + #define FCOMIP_ST6 _asm _emit 0xdf _asm _emit 0xf6 + #define FCMOVB_ST6 _asm _emit 0xda _asm _emit 0xc6 + #define FCMOVNB_ST6 _asm _emit 0xdb _asm _emit 0xc6 + + #define FCOMI_ST7 _asm _emit 0xdb _asm _emit 0xf7 + #define FCOMIP_ST7 _asm _emit 0xdf _asm _emit 0xf7 + #define FCMOVB_ST7 _asm _emit 0xda _asm _emit 0xc7 + #define FCMOVNB_ST7 _asm _emit 0xdb _asm _emit 0xc7 + + //! A global function to find MAX(a,b) using FCOMI/FCMOV + inline_ float FCMax2(float a, float b) + { + return (a > b) ? a : b; + } + + //! A global function to find MIN(a,b) using FCOMI/FCMOV + inline_ float FCMin2(float a, float b) + { + return (a < b) ? a : b; + } + + //! A global function to find MAX(a,b,c) using FCOMI/FCMOV + inline_ float FCMax3(float a, float b, float c) + { + return (a > b) ? ((a > c) ? a : c) : ((b > c) ? b : c); + } + + //! A global function to find MIN(a,b,c) using FCOMI/FCMOV + inline_ float FCMin3(float a, float b, float c) + { + return (a < b) ? ((a < c) ? a : c) : ((b < c) ? b : c); + } + + inline_ int ConvertToSortable(float f) + { + int Fi = SIR(f); + int Fmask = (Fi>>31); + Fi ^= Fmask; + Fmask &= ~(1<<31); + Fi -= Fmask; + return Fi; + } + + enum FPUMode + { + FPU_FLOOR = 0, + FPU_CEIL = 1, + FPU_BEST = 2, + + FPU_FORCE_DWORD = 0x7fffffff + }; + + FUNCTION ICECORE_API FPUMode GetFPUMode(); + FUNCTION ICECORE_API void SaveFPU(); + FUNCTION ICECORE_API void RestoreFPU(); + FUNCTION ICECORE_API void SetFPUFloorMode(); + FUNCTION ICECORE_API void SetFPUCeilMode(); + FUNCTION ICECORE_API void SetFPUBestMode(); + + FUNCTION ICECORE_API void SetFPUPrecision24(); + FUNCTION ICECORE_API void SetFPUPrecision53(); + FUNCTION ICECORE_API void SetFPUPrecision64(); + FUNCTION ICECORE_API void SetFPURoundingChop(); + FUNCTION ICECORE_API void SetFPURoundingUp(); + FUNCTION ICECORE_API void SetFPURoundingDown(); + FUNCTION ICECORE_API void SetFPURoundingNear(); + + FUNCTION ICECORE_API int intChop(const float& f); + FUNCTION ICECORE_API int intFloor(const float& f); + FUNCTION ICECORE_API int intCeil(const float& f); + +#endif // __ICEFPU_H__ diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceHPoint.cpp b/libs/ode-0.16.1/OPCODE/Ice/IceHPoint.cpp new file mode 100644 index 0000000..f806a0c --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceHPoint.cpp @@ -0,0 +1,70 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for homogeneous points. + * \file IceHPoint.cpp + * \author Pierre Terdiman + * \date April, 4, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Homogeneous point. + * + * Use it: + * - for clipping in homogeneous space (standard way) + * - to differentiate between points (w=1) and vectors (w=0). + * - in some cases you can also use it instead of Point for padding reasons. + * + * \class HPoint + * \author Pierre Terdiman + * \version 1.0 + * \warning No cross-product in 4D. + * \warning HPoint *= Matrix3x3 doesn't exist, the matrix is first casted to a 4x4 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace IceMaths; + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Point Mul = HPoint * Matrix3x3; +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +Point HPoint::operator*(const Matrix3x3& mat) const +{ + return Point( + x * mat.m[0][0] + y * mat.m[1][0] + z * mat.m[2][0], + x * mat.m[0][1] + y * mat.m[1][1] + z * mat.m[2][1], + x * mat.m[0][2] + y * mat.m[1][2] + z * mat.m[2][2] ); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// HPoint Mul = HPoint * Matrix4x4; +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +HPoint HPoint::operator*(const Matrix4x4& mat) const +{ + return HPoint( + x * mat.m[0][0] + y * mat.m[1][0] + z * mat.m[2][0] + w * mat.m[3][0], + x * mat.m[0][1] + y * mat.m[1][1] + z * mat.m[2][1] + w * mat.m[3][1], + x * mat.m[0][2] + y * mat.m[1][2] + z * mat.m[2][2] + w * mat.m[3][2], + x * mat.m[0][3] + y * mat.m[1][3] + z * mat.m[2][3] + w * mat.m[3][3]); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// HPoint *= Matrix4x4 +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +HPoint& HPoint::operator*=(const Matrix4x4& mat) +{ + float xp = x * mat.m[0][0] + y * mat.m[1][0] + z * mat.m[2][0] + w * mat.m[3][0]; + float yp = x * mat.m[0][1] + y * mat.m[1][1] + z * mat.m[2][1] + w * mat.m[3][1]; + float zp = x * mat.m[0][2] + y * mat.m[1][2] + z * mat.m[2][2] + w * mat.m[3][2]; + float wp = x * mat.m[0][3] + y * mat.m[1][3] + z * mat.m[2][3] + w * mat.m[3][3]; + + x = xp; y = yp; z = zp; w = wp; + + return *this; +} + diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceHPoint.h b/libs/ode-0.16.1/OPCODE/Ice/IceHPoint.h new file mode 100644 index 0000000..a3770cd --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceHPoint.h @@ -0,0 +1,160 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for homogeneous points. + * \file IceHPoint.h + * \author Pierre Terdiman + * \date April, 4, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __ICEHPOINT_H__ +#define __ICEHPOINT_H__ + + class ICEMATHS_API HPoint : public Point + { + public: + + //! Empty constructor + inline_ HPoint() {} + //! Constructor from floats + inline_ HPoint(float xx, float yy, float zz, float ww=0.0f) : Point(xx, yy, zz), w(ww) {} + //! Constructor from array + inline_ HPoint(const float f[4]) : Point(f), w(f[3]) {} + //! Constructor from a Point + inline_ HPoint(const Point& p, float ww=0.0f) : Point(p), w(ww) {} + //! Destructor + inline_ ~HPoint() {} + + //! Clear the point + inline_ HPoint& Zero() { x = y = z = w = 0.0f; return *this; } + + //! Assignment from values + inline_ HPoint& Set(float xx, float yy, float zz, float ww ) { x = xx; y = yy; z = zz; w = ww; return *this; } + //! Assignment from array + inline_ HPoint& Set(const float f[4]) { x = f[X]; y = f[Y]; z = f[Z]; w = f[W]; return *this; } + //! Assignment from another h-point + inline_ HPoint& Set(const HPoint& src) { x = src.x; y = src.y; z = src.z; w = src.w; return *this; } + + //! Add a vector + inline_ HPoint& Add(float xx, float yy, float zz, float ww ) { x += xx; y += yy; z += zz; w += ww; return *this; } + //! Add a vector + inline_ HPoint& Add(const float f[4]) { x += f[X]; y += f[Y]; z += f[Z]; w += f[W]; return *this; } + + //! Subtract a vector + inline_ HPoint& Sub(float xx, float yy, float zz, float ww ) { x -= xx; y -= yy; z -= zz; w -= ww; return *this; } + //! Subtract a vector + inline_ HPoint& Sub(const float f[4]) { x -= f[X]; y -= f[Y]; z -= f[Z]; w -= f[W]; return *this; } + + //! Multiplies by a scalar + inline_ HPoint& Mul(float s) { x *= s; y *= s; z *= s; w *= s; return *this; } + + //! Returns MIN(x, y, z, w); + float Min() const { return MIN(x, MIN(y, MIN(z, w))); } + //! Returns MAX(x, y, z, w); + float Max() const { return MAX(x, MAX(y, MAX(z, w))); } + //! Sets each element to be componentwise minimum + HPoint& Min(const HPoint& p) { x = MIN(x, p.x); y = MIN(y, p.y); z = MIN(z, p.z); w = MIN(w, p.w); return *this; } + //! Sets each element to be componentwise maximum + HPoint& Max(const HPoint& p) { x = MAX(x, p.x); y = MAX(y, p.y); z = MAX(z, p.z); w = MAX(w, p.w); return *this; } + + //! Computes square magnitude + inline_ float SquareMagnitude() const { return x*x + y*y + z*z + w*w; } + //! Computes magnitude + inline_ float Magnitude() const { return sqrtf(x*x + y*y + z*z + w*w); } + + //! Normalize the vector + inline_ HPoint& Normalize() + { + float M = Magnitude(); + if(M) + { + M = 1.0f / M; + x *= M; + y *= M; + z *= M; + w *= M; + } + return *this; + } + + // Arithmetic operators + //! Operator for HPoint Negate = - HPoint; + inline_ HPoint operator-() const { return HPoint(-x, -y, -z, -w); } + + //! Operator for HPoint Plus = HPoint + HPoint; + inline_ HPoint operator+(const HPoint& p) const { return HPoint(x + p.x, y + p.y, z + p.z, w + p.w); } + //! Operator for HPoint Minus = HPoint - HPoint; + inline_ HPoint operator-(const HPoint& p) const { return HPoint(x - p.x, y - p.y, z - p.z, w - p.w); } + + //! Operator for HPoint Mul = HPoint * HPoint; + inline_ HPoint operator*(const HPoint& p) const { return HPoint(x * p.x, y * p.y, z * p.z, w * p.w); } + //! Operator for HPoint Scale = HPoint * float; + inline_ HPoint operator*(float s) const { return HPoint(x * s, y * s, z * s, w * s); } + //! Operator for HPoint Scale = float * HPoint; + inline_ friend HPoint operator*(float s, const HPoint& p) { return HPoint(s * p.x, s * p.y, s * p.z, s * p.w); } + + //! Operator for HPoint Div = HPoint / HPoint; + inline_ HPoint operator/(const HPoint& p) const { return HPoint(x / p.x, y / p.y, z / p.z, w / p.w); } + //! Operator for HPoint Scale = HPoint / float; + inline_ HPoint operator/(float s) const { s = 1.0f / s; return HPoint(x * s, y * s, z * s, w * s); } + //! Operator for HPoint Scale = float / HPoint; + inline_ friend HPoint operator/(float s, const HPoint& p) { return HPoint(s / p.x, s / p.y, s / p.z, s / p.w); } + + //! Operator for float DotProd = HPoint | HPoint; + inline_ float operator|(const HPoint& p) const { return x*p.x + y*p.y + z*p.z + w*p.w; } + // No cross-product in 4D + + //! Operator for HPoint += HPoint; + inline_ HPoint& operator+=(const HPoint& p) { x += p.x; y += p.y; z += p.z; w += p.w; return *this; } + //! Operator for HPoint += float; + inline_ HPoint& operator+=(float s) { x += s; y += s; z += s; w += s; return *this; } + + //! Operator for HPoint -= HPoint; + inline_ HPoint& operator-=(const HPoint& p) { x -= p.x; y -= p.y; z -= p.z; w -= p.w; return *this; } + //! Operator for HPoint -= float; + inline_ HPoint& operator-=(float s) { x -= s; y -= s; z -= s; w -= s; return *this; } + + //! Operator for HPoint *= HPoint; + inline_ HPoint& operator*=(const HPoint& p) { x *= p.x; y *= p.y; z *= p.z; w *= p.w; return *this; } + //! Operator for HPoint *= float; + inline_ HPoint& operator*=(float s) { x*=s; y*=s; z*=s; w*=s; return *this; } + + //! Operator for HPoint /= HPoint; + inline_ HPoint& operator/=(const HPoint& p) { x /= p.x; y /= p.y; z /= p.z; w /= p.w; return *this; } + //! Operator for HPoint /= float; + inline_ HPoint& operator/=(float s) { s = 1.0f / s; x*=s; y*=s; z*=s; w*=s; return *this; } + + // Arithmetic operators + + //! Operator for Point Mul = HPoint * Matrix3x3; + Point operator*(const Matrix3x3& mat) const; + //! Operator for HPoint Mul = HPoint * Matrix4x4; + HPoint operator*(const Matrix4x4& mat) const; + + // HPoint *= Matrix3x3 doesn't exist, the matrix is first casted to a 4x4 + //! Operator for HPoint *= Matrix4x4 + HPoint& operator*=(const Matrix4x4& mat); + + // Logical operators + + //! Operator for "if(HPoint==HPoint)" + inline_ bool operator==(const HPoint& p) const { return ( (x==p.x)&&(y==p.y)&&(z==p.z)&&(w==p.w)); } + //! Operator for "if(HPoint!=HPoint)" + inline_ bool operator!=(const HPoint& p) const { return ( (x!=p.x)||(y!=p.y)||(z!=p.z)||(w!=p.w)); } + + // Cast operators + + //! Cast a HPoint to a Point. w is discarded. +#ifdef _MSC_VER + inline_ operator Point() const { return Point(x, y, z); } + // gcc complains that conversion to a base class will never use a type conversion operator +#endif + + public: + float w; + }; + +#endif // __ICEHPOINT_H__ + diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceIndexedTriangle.cpp b/libs/ode-0.16.1/OPCODE/Ice/IceIndexedTriangle.cpp new file mode 100644 index 0000000..d317113 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceIndexedTriangle.cpp @@ -0,0 +1,548 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains a handy indexed triangle class. + * \file IceIndexedTriangle.cpp + * \author Pierre Terdiman + * \date January, 17, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace IceMaths; + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains an indexed triangle class. + * + * \class Triangle + * \author Pierre Terdiman + * \version 1.0 + * \date 08.15.98 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Flips the winding order. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void IndexedTriangle::Flip() +{ + Swap(mVRef[1], mVRef[2]); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the triangle area. + * \param verts [in] the list of indexed vertices + * \return the area + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +float IndexedTriangle::Area(const Point* verts) const +{ + if(!verts) return 0.0f; + const Point& p0 = verts[0]; + const Point& p1 = verts[1]; + const Point& p2 = verts[2]; + return ((p0-p1)^(p0-p2)).Magnitude() * 0.5f; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the triangle perimeter. + * \param verts [in] the list of indexed vertices + * \return the perimeter + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +float IndexedTriangle::Perimeter(const Point* verts) const +{ + if(!verts) return 0.0f; + const Point& p0 = verts[0]; + const Point& p1 = verts[1]; + const Point& p2 = verts[2]; + return p0.Distance(p1) + + p0.Distance(p2) + + p1.Distance(p2); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the triangle compacity. + * \param verts [in] the list of indexed vertices + * \return the compacity + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +float IndexedTriangle::Compacity(const Point* verts) const +{ + if(!verts) return 0.0f; + float P = Perimeter(verts); + if(P==0.0f) return 0.0f; + return (4.0f*PI*Area(verts)/(P*P)); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the triangle normal. + * \param verts [in] the list of indexed vertices + * \param normal [out] the computed normal + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void IndexedTriangle::Normal(const Point* verts, Point& normal) const +{ + if(!verts) return; + + const Point& p0 = verts[mVRef[0]]; + const Point& p1 = verts[mVRef[1]]; + const Point& p2 = verts[mVRef[2]]; + normal = ((p2-p1)^(p0-p1)).Normalize(); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the triangle denormalized normal. + * \param verts [in] the list of indexed vertices + * \param normal [out] the computed normal + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void IndexedTriangle::DenormalizedNormal(const Point* verts, Point& normal) const +{ + if(!verts) return; + + const Point& p0 = verts[mVRef[0]]; + const Point& p1 = verts[mVRef[1]]; + const Point& p2 = verts[mVRef[2]]; + normal = ((p2-p1)^(p0-p1)); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the triangle center. + * \param verts [in] the list of indexed vertices + * \param center [out] the computed center + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void IndexedTriangle::Center(const Point* verts, Point& center) const +{ + if(!verts) return; + + const Point& p0 = verts[mVRef[0]]; + const Point& p1 = verts[mVRef[1]]; + const Point& p2 = verts[mVRef[2]]; + center = (p0+p1+p2)*INV3; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the centered normal + * \param verts [in] the list of indexed vertices + * \param normal [out] the computed centered normal + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void IndexedTriangle::CenteredNormal(const Point* verts, Point& normal) const +{ + if(!verts) return; + + const Point& p0 = verts[mVRef[0]]; + const Point& p1 = verts[mVRef[1]]; + const Point& p2 = verts[mVRef[2]]; + Point Center = (p0+p1+p2)*INV3; + normal = Center + ((p2-p1)^(p0-p1)).Normalize(); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes a random point within the triangle. + * \param verts [in] the list of indexed vertices + * \param normal [out] the computed centered normal + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void IndexedTriangle::RandomPoint(const Point* verts, Point& random) const +{ + if(!verts) return; + + // Random barycentric coords + float Alpha = UnitRandomFloat(); + float Beta = UnitRandomFloat(); + float Gamma = UnitRandomFloat(); + float OneOverTotal = 1.0f / (Alpha + Beta + Gamma); + Alpha *= OneOverTotal; + Beta *= OneOverTotal; + Gamma *= OneOverTotal; + + const Point& p0 = verts[mVRef[0]]; + const Point& p1 = verts[mVRef[1]]; + const Point& p2 = verts[mVRef[2]]; + random = Alpha*p0 + Beta*p1 + Gamma*p2; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes backface culling. + * \param verts [in] the list of indexed vertices + * \param source [in] source point (in local space) from which culling must be computed + * \return true if the triangle is visible from the source point + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool IndexedTriangle::IsVisible(const Point* verts, const Point& source) const +{ + // Checkings + if(!verts) return false; + + const Point& p0 = verts[mVRef[0]]; + const Point& p1 = verts[mVRef[1]]; + const Point& p2 = verts[mVRef[2]]; + + // Compute denormalized normal + Point Normal = (p2 - p1)^(p0 - p1); + + // Backface culling + return (Normal | source) >= 0.0f; + +// Same as: +// Plane PL(verts[mVRef[0]], verts[mVRef[1]], verts[mVRef[2]]); +// return PL.Distance(source) > PL.d; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes backface culling. + * \param verts [in] the list of indexed vertices + * \param source [in] source point (in local space) from which culling must be computed + * \return true if the triangle is visible from the source point + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool IndexedTriangle::BackfaceCulling(const Point* verts, const Point& source) const +{ + // Checkings + if(!verts) return false; + + const Point& p0 = verts[mVRef[0]]; + const Point& p1 = verts[mVRef[1]]; + const Point& p2 = verts[mVRef[2]]; + + // Compute base +// Point Base = (p0 + p1 + p2)*INV3; + + // Compute denormalized normal + Point Normal = (p2 - p1)^(p0 - p1); + + // Backface culling +// return (Normal | (source - Base)) >= 0.0f; + return (Normal | (source - p0)) >= 0.0f; + +// Same as: (but a bit faster) +// Plane PL(verts[mVRef[0]], verts[mVRef[1]], verts[mVRef[2]]); +// return PL.Distance(source)>0.0f; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the occlusion potential of the triangle. + * \param verts [in] the list of indexed vertices + * \param source [in] source point (in local space) from which occlusion potential must be computed + * \return the occlusion potential + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +float IndexedTriangle::ComputeOcclusionPotential(const Point* verts, const Point& view) const +{ + if(!verts) return 0.0f; + // Occlusion potential: -(A * (N|V) / d^2) + // A = polygon area + // N = polygon normal + // V = view vector + // d = distance viewpoint-center of polygon + + float A = Area(verts); + Point N; Normal(verts, N); + Point C; Center(verts, C); + float d = view.Distance(C); + return -(A*(N|view))/(d*d); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Replaces a vertex reference with another one. + * \param oldref [in] the vertex reference to replace + * \param newref [in] the new vertex reference + * \return true if success, else false if the input vertex reference doesn't belong to the triangle + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool IndexedTriangle::ReplaceVertex(dTriIndex oldref, dTriIndex newref) +{ + if(mVRef[0]==oldref) { mVRef[0] = newref; return true; } + else if(mVRef[1]==oldref) { mVRef[1] = newref; return true; } + else if(mVRef[2]==oldref) { mVRef[2] = newref; return true; } + return false; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Checks whether the triangle is degenerate or not. A degenerate triangle has two common vertex references. This is a zero-area triangle. + * \return true if the triangle is degenerate + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool IndexedTriangle::IsDegenerate() const +{ + if(mVRef[0]==mVRef[1]) return true; + if(mVRef[1]==mVRef[2]) return true; + if(mVRef[2]==mVRef[0]) return true; + return false; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Checks whether the input vertex reference belongs to the triangle or not. + * \param ref [in] the vertex reference to look for + * \return true if the triangle contains the vertex reference + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool IndexedTriangle::HasVertex(dTriIndex ref) const +{ + if(mVRef[0]==ref) return true; + if(mVRef[1]==ref) return true; + if(mVRef[2]==ref) return true; + return false; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Checks whether the input vertex reference belongs to the triangle or not. + * \param ref [in] the vertex reference to look for + * \param index [out] the corresponding index in the triangle + * \return true if the triangle contains the vertex reference + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool IndexedTriangle::HasVertex(dTriIndex ref, dTriIndex* index) const +{ + if(mVRef[0]==ref) { *index = 0; return true; } + if(mVRef[1]==ref) { *index = 1; return true; } + if(mVRef[2]==ref) { *index = 2; return true; } + return false; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Finds an edge in a tri, given two vertex references. + * \param vref0 [in] the edge's first vertex reference + * \param vref1 [in] the edge's second vertex reference + * \return the edge number between 0 and 2, or 0xff if input refs are wrong. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +ubyte IndexedTriangle::FindEdge(dTriIndex vref0, dTriIndex vref1) const +{ + if(mVRef[0]==vref0 && mVRef[1]==vref1) return 0; + else if(mVRef[0]==vref1 && mVRef[1]==vref0) return 0; + else if(mVRef[0]==vref0 && mVRef[2]==vref1) return 1; + else if(mVRef[0]==vref1 && mVRef[2]==vref0) return 1; + else if(mVRef[1]==vref0 && mVRef[2]==vref1) return 2; + else if(mVRef[1]==vref1 && mVRef[2]==vref0) return 2; + return 0xff; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Gets the last reference given the first two. + * \param vref0 [in] the first vertex reference + * \param vref1 [in] the second vertex reference + * \return the last reference, or INVALID_ID if input refs are wrong. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +dTriIndex IndexedTriangle::OppositeVertex(dTriIndex vref0, dTriIndex vref1) const +{ + if(mVRef[0]==vref0 && mVRef[1]==vref1) return mVRef[2]; + else if(mVRef[0]==vref1 && mVRef[1]==vref0) return mVRef[2]; + else if(mVRef[0]==vref0 && mVRef[2]==vref1) return mVRef[1]; + else if(mVRef[0]==vref1 && mVRef[2]==vref0) return mVRef[1]; + else if(mVRef[1]==vref0 && mVRef[2]==vref1) return mVRef[0]; + else if(mVRef[1]==vref1 && mVRef[2]==vref0) return mVRef[0]; + return (dTriIndex)INVALID_ID; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Gets the three sorted vertex references according to an edge number. + * edgenb = 0 => edge 0-1, returns references 0, 1, 2 + * edgenb = 1 => edge 0-2, returns references 0, 2, 1 + * edgenb = 2 => edge 1-2, returns references 1, 2, 0 + * + * \param edgenb [in] the edge number, 0, 1 or 2 + * \param vref0 [out] the returned first vertex reference + * \param vref1 [out] the returned second vertex reference + * \param vref2 [out] the returned third vertex reference + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void IndexedTriangle::GetVRefs(ubyte edgenb, dTriIndex& vref0, dTriIndex& vref1, dTriIndex& vref2) const +{ + if(edgenb==0) + { + vref0 = mVRef[0]; + vref1 = mVRef[1]; + vref2 = mVRef[2]; + } + else if(edgenb==1) + { + vref0 = mVRef[0]; + vref1 = mVRef[2]; + vref2 = mVRef[1]; + } + else if(edgenb==2) + { + vref0 = mVRef[1]; + vref1 = mVRef[2]; + vref2 = mVRef[0]; + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the triangle's smallest edge length. + * \param verts [in] the list of indexed vertices + * \return the smallest edge length + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +float IndexedTriangle::MinEdgeLength(const Point* verts) const +{ + if(!verts) return 0.0f; + + float Min = MAX_FLOAT; + float Length01 = verts[0].Distance(verts[1]); + float Length02 = verts[0].Distance(verts[2]); + float Length12 = verts[1].Distance(verts[2]); + if(Length01 < Min) Min = Length01; + if(Length02 < Min) Min = Length02; + if(Length12 < Min) Min = Length12; + return Min; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the triangle's largest edge length. + * \param verts [in] the list of indexed vertices + * \return the largest edge length + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +float IndexedTriangle::MaxEdgeLength(const Point* verts) const +{ + if(!verts) return 0.0f; + + float Max = MIN_FLOAT; + float Length01 = verts[0].Distance(verts[1]); + float Length02 = verts[0].Distance(verts[2]); + float Length12 = verts[1].Distance(verts[2]); + if(Length01 > Max) Max = Length01; + if(Length02 > Max) Max = Length02; + if(Length12 > Max) Max = Length12; + return Max; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes a point on the triangle according to the stabbing information. + * \param verts [in] the list of indexed vertices + * \param u,v [in] point's barycentric coordinates + * \param pt [out] point on triangle + * \param nearvtx [out] index of nearest vertex + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void IndexedTriangle::ComputePoint(const Point* verts, float u, float v, Point& pt, dTriIndex* nearvtx) const +{ + // Checkings + if(!verts) return; + + // Get face in local or global space + const Point& p0 = verts[mVRef[0]]; + const Point& p1 = verts[mVRef[1]]; + const Point& p2 = verts[mVRef[2]]; + + // Compute point coordinates + pt = (1.0f - u - v)*p0 + u*p1 + v*p2; + + // Compute nearest vertex if needed + if(nearvtx) + { + // Compute distance vector + Point d(p0.SquareDistance(pt), // Distance^2 from vertex 0 to point on the face + p1.SquareDistance(pt), // Distance^2 from vertex 1 to point on the face + p2.SquareDistance(pt)); // Distance^2 from vertex 2 to point on the face + + // Get smallest distance + *nearvtx = mVRef[d.SmallestAxis()]; + } +} + + //************************************** + // Angle between two vectors (in radians) + // we use this formula + // uv = |u||v| cos(u,v) + // u ^ v = w + // |w| = |u||v| |sin(u,v)| + //************************************** + float Angle(const Point& u, const Point& v) + { + float NormU = u.Magnitude(); // |u| + float NormV = v.Magnitude(); // |v| + float Product = NormU*NormV; // |u||v| + if(Product==0.0f) return 0.0f; + float OneOverProduct = 1.0f / Product; + + // Cosinus + float Cosinus = (u|v) * OneOverProduct; + + // Sinus + Point w = u^v; + float NormW = w.Magnitude(); + + float AbsSinus = NormW * OneOverProduct; + + // Remove degeneracy + if(AbsSinus > 1.0f) AbsSinus = 1.0f; + if(AbsSinus < -1.0f) AbsSinus = -1.0f; + + if(Cosinus>=0.0f) return asinf(AbsSinus); + else return (PI-asinf(AbsSinus)); + } + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the angle between two triangles. + * \param tri [in] the other triangle + * \param verts [in] the list of indexed vertices + * \return the angle in radians + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +float IndexedTriangle::Angle(const IndexedTriangle& tri, const Point* verts) const +{ + // Checkings + if(!verts) return 0.0f; + + // Compute face normals + Point n0, n1; + Normal(verts, n0); + tri.Normal(verts, n1); + + // Compute angle + float dp = n0|n1; + if(dp>1.0f) return 0.0f; + if(dp<-1.0f) return PI; + return acosf(dp); + +// return ::Angle(n0,n1); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Checks a triangle is the same as another one. + * \param tri [in] the other triangle + * \return true if same triangle + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool IndexedTriangle::Equal(const IndexedTriangle& tri) const +{ + // Test all vertex references + return (HasVertex(tri.mVRef[0]) && + HasVertex(tri.mVRef[1]) && + HasVertex(tri.mVRef[2])); +} diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceIndexedTriangle.h b/libs/ode-0.16.1/OPCODE/Ice/IceIndexedTriangle.h new file mode 100644 index 0000000..d545e41 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceIndexedTriangle.h @@ -0,0 +1,76 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains a handy indexed triangle class. + * \file IceIndexedTriangle.h + * \author Pierre Terdiman + * \date January, 17, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +#include "ode/common.h" + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __ICEINDEXEDTRIANGLE_H__ +#define __ICEINDEXEDTRIANGLE_H__ + + // Forward declarations +#ifdef _MSC_VER + enum CubeIndex; +#else + typedef int CubeIndex; +#endif + + // An indexed triangle class. + class ICEMATHS_API IndexedTriangle + { + public: + + //! Constructor + inline_ IndexedTriangle() {} + //! Constructor + inline_ IndexedTriangle(dTriIndex r0, dTriIndex r1, dTriIndex r2) { mVRef[0]=r0; mVRef[1]=r1; mVRef[2]=r2; } + //! Copy constructor + inline_ IndexedTriangle(const IndexedTriangle& triangle) + { + mVRef[0] = triangle.mVRef[0]; + mVRef[1] = triangle.mVRef[1]; + mVRef[2] = triangle.mVRef[2]; + } + //! Destructor + inline_ ~IndexedTriangle() {} + + //! Vertex-references + dTriIndex mVRef[3]; + + // Methods + void Flip(); + float Area(const Point* verts) const; + float Perimeter(const Point* verts) const; + float Compacity(const Point* verts) const; + void Normal(const Point* verts, Point& normal) const; + void DenormalizedNormal(const Point* verts, Point& normal) const; + void Center(const Point* verts, Point& center) const; + void CenteredNormal(const Point* verts, Point& normal) const; + void RandomPoint(const Point* verts, Point& random) const; + bool IsVisible(const Point* verts, const Point& source) const; + bool BackfaceCulling(const Point* verts, const Point& source) const; + float ComputeOcclusionPotential(const Point* verts, const Point& view) const; + bool ReplaceVertex(dTriIndex oldref, dTriIndex newref); + bool IsDegenerate() const; + bool HasVertex(dTriIndex ref) const; + bool HasVertex(dTriIndex ref, dTriIndex* index) const; + ubyte FindEdge(dTriIndex vref0, dTriIndex vref1) const; + dTriIndex OppositeVertex(dTriIndex vref0, dTriIndex vref1) const; + inline_ dTriIndex OppositeVertex(ubyte edgenb) const { return mVRef[2-edgenb]; } + void GetVRefs(ubyte edgenb, dTriIndex& vref0, dTriIndex& vref1, dTriIndex& vref2) const; + float MinEdgeLength(const Point* verts) const; + float MaxEdgeLength(const Point* verts) const; + void ComputePoint(const Point* verts, float u, float v, Point& pt, dTriIndex* nearvtx=null) const; + float Angle(const IndexedTriangle& tri, const Point* verts) const; + inline_ Plane PlaneEquation(const Point* verts) const { return Plane(verts[mVRef[0]], verts[mVRef[1]], verts[mVRef[2]]); } + bool Equal(const IndexedTriangle& tri) const; + CubeIndex ComputeCubeIndex(const Point* verts) const; + }; + +#endif // __ICEINDEXEDTRIANGLE_H__ diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceLSS.h b/libs/ode-0.16.1/OPCODE/Ice/IceLSS.h new file mode 100644 index 0000000..bd260c1 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceLSS.h @@ -0,0 +1,75 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for line-swept spheres. + * \file IceLSS.h + * \author Pierre Terdiman + * \date April, 4, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __ICELSS_H__ +#define __ICELSS_H__ + + class ICEMATHS_API LSS : public Segment + { + public: + //! Constructor + inline_ LSS() {} + //! Constructor + inline_ LSS(const Segment& seg, float radius) : Segment(seg), mRadius(radius) {} + //! Destructor + inline_ ~LSS() {} + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Computes an OBB surrounding the LSS. + * \param box [out] the OBB + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + void ComputeOBB(OBB& box); + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Tests if a point is contained within the LSS. + * \param pt [in] the point to test + * \return true if inside the LSS + * \warning point and LSS must be in same space + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ bool Contains(const Point& pt) const { return SquareDistance(pt) <= mRadius*mRadius; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Tests if a sphere is contained within the LSS. + * \param sphere [in] the sphere to test + * \return true if inside the LSS + * \warning sphere and LSS must be in same space + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ bool Contains(const Sphere& sphere) + { + float d = mRadius - sphere.mRadius; + if(d>=0.0f) return SquareDistance(sphere.mCenter) <= d*d; + else return false; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Tests if an LSS is contained within the LSS. + * \param lss [in] the LSS to test + * \return true if inside the LSS + * \warning both LSS must be in same space + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ bool Contains(const LSS& lss) + { + // We check the LSS contains the two spheres at the start and end of the sweep + return Contains(Sphere(lss.mP0, lss.mRadius)) && Contains(Sphere(lss.mP0, lss.mRadius)); + } + + float mRadius; //!< Sphere radius + }; + +#endif // __ICELSS_H__ diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceMatrix3x3.cpp b/libs/ode-0.16.1/OPCODE/Ice/IceMatrix3x3.cpp new file mode 100644 index 0000000..af56d3e --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceMatrix3x3.cpp @@ -0,0 +1,48 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for 3x3 matrices. + * \file IceMatrix3x3.cpp + * \author Pierre Terdiman + * \date April, 4, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * 3x3 matrix. + * DirectX-compliant, ie row-column order, ie m[Row][Col]. + * Same as: + * m11 m12 m13 first row. + * m21 m22 m23 second row. + * m31 m32 m33 third row. + * Stored in memory as m11 m12 m13 m21... + * + * Multiplication rules: + * + * [x'y'z'] = [xyz][M] + * + * x' = x*m11 + y*m21 + z*m31 + * y' = x*m12 + y*m22 + z*m32 + * z' = x*m13 + y*m23 + z*m33 + * + * \class Matrix3x3 + * \author Pierre Terdiman + * \version 1.0 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace IceMaths; + +// Cast operator +Matrix3x3::operator Matrix4x4() const +{ + return Matrix4x4( + m[0][0], m[0][1], m[0][2], 0.0f, + m[1][0], m[1][1], m[1][2], 0.0f, + m[2][0], m[2][1], m[2][2], 0.0f, + 0.0f, 0.0f, 0.0f, 1.0f); +} diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceMatrix3x3.h b/libs/ode-0.16.1/OPCODE/Ice/IceMatrix3x3.h new file mode 100644 index 0000000..e3b950f --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceMatrix3x3.h @@ -0,0 +1,499 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for 3x3 matrices. + * \file IceMatrix3x3.h + * \author Pierre Terdiman + * \date April, 4, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __ICEMATRIX3X3_H__ +#define __ICEMATRIX3X3_H__ + + // Forward declarations + class Quat; + + #define MATRIX3X3_EPSILON (1.0e-7f) + + class ICEMATHS_API Matrix3x3 + { + public: + //! Empty constructor + inline_ Matrix3x3() {} + //! Constructor from 9 values + inline_ Matrix3x3(float m00, float m01, float m02, float m10, float m11, float m12, float m20, float m21, float m22) + { + m[0][0] = m00; m[0][1] = m01; m[0][2] = m02; + m[1][0] = m10; m[1][1] = m11; m[1][2] = m12; + m[2][0] = m20; m[2][1] = m21; m[2][2] = m22; + } + //! Copy constructor + inline_ Matrix3x3(const Matrix3x3& mat) { CopyMemory(m, &mat.m, 9*sizeof(float)); } + //! Destructor + inline_ ~Matrix3x3() {} + + //! Assign values + template + inline_ void Set(trotationfloat m00, trotationfloat m01, trotationfloat m02, + trotationfloat m10, trotationfloat m11, trotationfloat m12, + trotationfloat m20, trotationfloat m21, trotationfloat m22) + { + m[0][0] = (float)m00; m[0][1] = (float)m01; m[0][2] = (float)m02; + m[1][0] = (float)m10; m[1][1] = (float)m11; m[1][2] = (float)m12; + m[2][0] = (float)m20; m[2][1] = (float)m21; m[2][2] = (float)m22; + } + + //! Sets the scale from a Point. The point is put on the diagonal. + inline_ void SetScale(const Point& p) { m[0][0] = p.x; m[1][1] = p.y; m[2][2] = p.z; } + + //! Sets the scale from floats. Values are put on the diagonal. + inline_ void SetScale(float sx, float sy, float sz) { m[0][0] = sx; m[1][1] = sy; m[2][2] = sz; } + + //! Scales from a Point. Each row is multiplied by a component. + inline_ void Scale(const Point& p) + { + m[0][0] *= p.x; m[0][1] *= p.x; m[0][2] *= p.x; + m[1][0] *= p.y; m[1][1] *= p.y; m[1][2] *= p.y; + m[2][0] *= p.z; m[2][1] *= p.z; m[2][2] *= p.z; + } + + //! Scales from floats. Each row is multiplied by a value. + inline_ void Scale(float sx, float sy, float sz) + { + m[0][0] *= sx; m[0][1] *= sx; m[0][2] *= sx; + m[1][0] *= sy; m[1][1] *= sy; m[1][2] *= sy; + m[2][0] *= sz; m[2][1] *= sz; m[2][2] *= sz; + } + + //! Copy from a Matrix3x3 + inline_ void Copy(const Matrix3x3& source) { CopyMemory(m, source.m, 9*sizeof(float)); } + + // Row-column access + //! Returns a row. + inline_ void GetRow(const udword r, Point& p) const { p.x = m[r][0]; p.y = m[r][1]; p.z = m[r][2]; } + //! Returns a row. + inline_ const Point& GetRow(const udword r) const { return *(const Point*)&m[r][0]; } + //! Returns a row. + inline_ Point& GetRow(const udword r) { return *(Point*)&m[r][0]; } + //! Sets a row. + inline_ void SetRow(const udword r, const Point& p) { m[r][0] = p.x; m[r][1] = p.y; m[r][2] = p.z; } + //! Returns a column. + inline_ void GetCol(const udword c, Point& p) const { p.x = m[0][c]; p.y = m[1][c]; p.z = m[2][c]; } + //! Sets a column. + inline_ void SetCol(const udword c, const Point& p) { m[0][c] = p.x; m[1][c] = p.y; m[2][c] = p.z; } + + //! Computes the trace. The trace is the sum of the 3 diagonal components. + inline_ float Trace() const { return m[0][0] + m[1][1] + m[2][2]; } + //! Clears the matrix. + inline_ void Zero() { ZeroMemory(&m, sizeof(m)); } + //! Sets the identity matrix. + inline_ void Identity() { Zero(); m[0][0] = m[1][1] = m[2][2] = 1.0f; } + //! Checks for identity + inline_ bool IsIdentity() const + { + if(IR(m[0][0])!=IEEE_1_0) return false; + if(IR(m[0][1])!=0) return false; + if(IR(m[0][2])!=0) return false; + + if(IR(m[1][0])!=0) return false; + if(IR(m[1][1])!=IEEE_1_0) return false; + if(IR(m[1][2])!=0) return false; + + if(IR(m[2][0])!=0) return false; + if(IR(m[2][1])!=0) return false; + if(IR(m[2][2])!=IEEE_1_0) return false; + + return true; + } + + //! Checks matrix validity + inline_ BOOL IsValid() const + { + for(udword j=0;j<3;j++) + { + for(udword i=0;i<3;i++) + { + if(!IsValidFloat(m[j][i])) return FALSE; + } + } + return TRUE; + } + + //! Makes a skew-symmetric matrix (a.k.a. Star(*) Matrix) + //! [ 0.0 -a.z a.y ] + //! [ a.z 0.0 -a.x ] + //! [ -a.y a.x 0.0 ] + //! This is also called a "cross matrix" since for any vectors A and B, + //! A^B = Skew(A) * B = - B * Skew(A); + inline_ void SkewSymmetric(const Point& a) + { + m[0][0] = 0.0f; + m[0][1] = -a.z; + m[0][2] = a.y; + + m[1][0] = a.z; + m[1][1] = 0.0f; + m[1][2] = -a.x; + + m[2][0] = -a.y; + m[2][1] = a.x; + m[2][2] = 0.0f; + } + + //! Negates the matrix + inline_ void Neg() + { + m[0][0] = -m[0][0]; m[0][1] = -m[0][1]; m[0][2] = -m[0][2]; + m[1][0] = -m[1][0]; m[1][1] = -m[1][1]; m[1][2] = -m[1][2]; + m[2][0] = -m[2][0]; m[2][1] = -m[2][1]; m[2][2] = -m[2][2]; + } + + //! Neg from another matrix + inline_ void Neg(const Matrix3x3& mat) + { + m[0][0] = -mat.m[0][0]; m[0][1] = -mat.m[0][1]; m[0][2] = -mat.m[0][2]; + m[1][0] = -mat.m[1][0]; m[1][1] = -mat.m[1][1]; m[1][2] = -mat.m[1][2]; + m[2][0] = -mat.m[2][0]; m[2][1] = -mat.m[2][1]; m[2][2] = -mat.m[2][2]; + } + + //! Add another matrix + inline_ void Add(const Matrix3x3& mat) + { + m[0][0] += mat.m[0][0]; m[0][1] += mat.m[0][1]; m[0][2] += mat.m[0][2]; + m[1][0] += mat.m[1][0]; m[1][1] += mat.m[1][1]; m[1][2] += mat.m[1][2]; + m[2][0] += mat.m[2][0]; m[2][1] += mat.m[2][1]; m[2][2] += mat.m[2][2]; + } + + //! Sub another matrix + inline_ void Sub(const Matrix3x3& mat) + { + m[0][0] -= mat.m[0][0]; m[0][1] -= mat.m[0][1]; m[0][2] -= mat.m[0][2]; + m[1][0] -= mat.m[1][0]; m[1][1] -= mat.m[1][1]; m[1][2] -= mat.m[1][2]; + m[2][0] -= mat.m[2][0]; m[2][1] -= mat.m[2][1]; m[2][2] -= mat.m[2][2]; + } + //! Mac + inline_ void Mac(const Matrix3x3& a, const Matrix3x3& b, float s) + { + m[0][0] = a.m[0][0] + b.m[0][0] * s; + m[0][1] = a.m[0][1] + b.m[0][1] * s; + m[0][2] = a.m[0][2] + b.m[0][2] * s; + + m[1][0] = a.m[1][0] + b.m[1][0] * s; + m[1][1] = a.m[1][1] + b.m[1][1] * s; + m[1][2] = a.m[1][2] + b.m[1][2] * s; + + m[2][0] = a.m[2][0] + b.m[2][0] * s; + m[2][1] = a.m[2][1] + b.m[2][1] * s; + m[2][2] = a.m[2][2] + b.m[2][2] * s; + } + //! Mac + inline_ void Mac(const Matrix3x3& a, float s) + { + m[0][0] += a.m[0][0] * s; m[0][1] += a.m[0][1] * s; m[0][2] += a.m[0][2] * s; + m[1][0] += a.m[1][0] * s; m[1][1] += a.m[1][1] * s; m[1][2] += a.m[1][2] * s; + m[2][0] += a.m[2][0] * s; m[2][1] += a.m[2][1] * s; m[2][2] += a.m[2][2] * s; + } + + //! this = A * s + inline_ void Mult(const Matrix3x3& a, float s) + { + m[0][0] = a.m[0][0] * s; m[0][1] = a.m[0][1] * s; m[0][2] = a.m[0][2] * s; + m[1][0] = a.m[1][0] * s; m[1][1] = a.m[1][1] * s; m[1][2] = a.m[1][2] * s; + m[2][0] = a.m[2][0] * s; m[2][1] = a.m[2][1] * s; m[2][2] = a.m[2][2] * s; + } + + inline_ void Add(const Matrix3x3& a, const Matrix3x3& b) + { + m[0][0] = a.m[0][0] + b.m[0][0]; m[0][1] = a.m[0][1] + b.m[0][1]; m[0][2] = a.m[0][2] + b.m[0][2]; + m[1][0] = a.m[1][0] + b.m[1][0]; m[1][1] = a.m[1][1] + b.m[1][1]; m[1][2] = a.m[1][2] + b.m[1][2]; + m[2][0] = a.m[2][0] + b.m[2][0]; m[2][1] = a.m[2][1] + b.m[2][1]; m[2][2] = a.m[2][2] + b.m[2][2]; + } + + inline_ void Sub(const Matrix3x3& a, const Matrix3x3& b) + { + m[0][0] = a.m[0][0] - b.m[0][0]; m[0][1] = a.m[0][1] - b.m[0][1]; m[0][2] = a.m[0][2] - b.m[0][2]; + m[1][0] = a.m[1][0] - b.m[1][0]; m[1][1] = a.m[1][1] - b.m[1][1]; m[1][2] = a.m[1][2] - b.m[1][2]; + m[2][0] = a.m[2][0] - b.m[2][0]; m[2][1] = a.m[2][1] - b.m[2][1]; m[2][2] = a.m[2][2] - b.m[2][2]; + } + + //! this = a * b + inline_ void Mult(const Matrix3x3& a, const Matrix3x3& b) + { + m[0][0] = a.m[0][0] * b.m[0][0] + a.m[0][1] * b.m[1][0] + a.m[0][2] * b.m[2][0]; + m[0][1] = a.m[0][0] * b.m[0][1] + a.m[0][1] * b.m[1][1] + a.m[0][2] * b.m[2][1]; + m[0][2] = a.m[0][0] * b.m[0][2] + a.m[0][1] * b.m[1][2] + a.m[0][2] * b.m[2][2]; + m[1][0] = a.m[1][0] * b.m[0][0] + a.m[1][1] * b.m[1][0] + a.m[1][2] * b.m[2][0]; + m[1][1] = a.m[1][0] * b.m[0][1] + a.m[1][1] * b.m[1][1] + a.m[1][2] * b.m[2][1]; + m[1][2] = a.m[1][0] * b.m[0][2] + a.m[1][1] * b.m[1][2] + a.m[1][2] * b.m[2][2]; + m[2][0] = a.m[2][0] * b.m[0][0] + a.m[2][1] * b.m[1][0] + a.m[2][2] * b.m[2][0]; + m[2][1] = a.m[2][0] * b.m[0][1] + a.m[2][1] * b.m[1][1] + a.m[2][2] * b.m[2][1]; + m[2][2] = a.m[2][0] * b.m[0][2] + a.m[2][1] * b.m[1][2] + a.m[2][2] * b.m[2][2]; + } + + //! this = transpose(a) * b + inline_ void MultAtB(const Matrix3x3& a, const Matrix3x3& b) + { + m[0][0] = a.m[0][0] * b.m[0][0] + a.m[1][0] * b.m[1][0] + a.m[2][0] * b.m[2][0]; + m[0][1] = a.m[0][0] * b.m[0][1] + a.m[1][0] * b.m[1][1] + a.m[2][0] * b.m[2][1]; + m[0][2] = a.m[0][0] * b.m[0][2] + a.m[1][0] * b.m[1][2] + a.m[2][0] * b.m[2][2]; + m[1][0] = a.m[0][1] * b.m[0][0] + a.m[1][1] * b.m[1][0] + a.m[2][1] * b.m[2][0]; + m[1][1] = a.m[0][1] * b.m[0][1] + a.m[1][1] * b.m[1][1] + a.m[2][1] * b.m[2][1]; + m[1][2] = a.m[0][1] * b.m[0][2] + a.m[1][1] * b.m[1][2] + a.m[2][1] * b.m[2][2]; + m[2][0] = a.m[0][2] * b.m[0][0] + a.m[1][2] * b.m[1][0] + a.m[2][2] * b.m[2][0]; + m[2][1] = a.m[0][2] * b.m[0][1] + a.m[1][2] * b.m[1][1] + a.m[2][2] * b.m[2][1]; + m[2][2] = a.m[0][2] * b.m[0][2] + a.m[1][2] * b.m[1][2] + a.m[2][2] * b.m[2][2]; + } + + //! this = a * transpose(b) + inline_ void MultABt(const Matrix3x3& a, const Matrix3x3& b) + { + m[0][0] = a.m[0][0] * b.m[0][0] + a.m[0][1] * b.m[0][1] + a.m[0][2] * b.m[0][2]; + m[0][1] = a.m[0][0] * b.m[1][0] + a.m[0][1] * b.m[1][1] + a.m[0][2] * b.m[1][2]; + m[0][2] = a.m[0][0] * b.m[2][0] + a.m[0][1] * b.m[2][1] + a.m[0][2] * b.m[2][2]; + m[1][0] = a.m[1][0] * b.m[0][0] + a.m[1][1] * b.m[0][1] + a.m[1][2] * b.m[0][2]; + m[1][1] = a.m[1][0] * b.m[1][0] + a.m[1][1] * b.m[1][1] + a.m[1][2] * b.m[1][2]; + m[1][2] = a.m[1][0] * b.m[2][0] + a.m[1][1] * b.m[2][1] + a.m[1][2] * b.m[2][2]; + m[2][0] = a.m[2][0] * b.m[0][0] + a.m[2][1] * b.m[0][1] + a.m[2][2] * b.m[0][2]; + m[2][1] = a.m[2][0] * b.m[1][0] + a.m[2][1] * b.m[1][1] + a.m[2][2] * b.m[1][2]; + m[2][2] = a.m[2][0] * b.m[2][0] + a.m[2][1] * b.m[2][1] + a.m[2][2] * b.m[2][2]; + } + + //! Makes a rotation matrix mapping vector "from" to vector "to". + Matrix3x3& FromTo(const Point& from, const Point& to); + + //! Set a rotation matrix around the X axis. + //! 1 0 0 + //! RX = 0 cx sx + //! 0 -sx cx + void RotX(float angle); + //! Set a rotation matrix around the Y axis. + //! cy 0 -sy + //! RY = 0 1 0 + //! sy 0 cy + void RotY(float angle); + //! Set a rotation matrix around the Z axis. + //! cz sz 0 + //! RZ = -sz cz 0 + //! 0 0 1 + void RotZ(float angle); + //! cy sx.sy -sy.cx + //! RY.RX 0 cx sx + //! sy -sx.cy cx.cy + void RotYX(float y, float x); + + //! Make a rotation matrix about an arbitrary axis + Matrix3x3& Rot(float angle, const Point& axis); + + //! Transpose the matrix. + void Transpose() + { + TSwap(m[1][0], m[0][1]); + TSwap(m[2][0], m[0][2]); + TSwap(m[2][1], m[1][2]); + } + + //! this = Transpose(a) + void Transpose(const Matrix3x3& a) + { + m[0][0] = a.m[0][0]; m[0][1] = a.m[1][0]; m[0][2] = a.m[2][0]; + m[1][0] = a.m[0][1]; m[1][1] = a.m[1][1]; m[1][2] = a.m[2][1]; + m[2][0] = a.m[0][2]; m[2][1] = a.m[1][2]; m[2][2] = a.m[2][2]; + } + + //! Compute the determinant of the matrix. We use the rule of Sarrus. + float Determinant() const + { + return (m[0][0]*m[1][1]*m[2][2] + m[0][1]*m[1][2]*m[2][0] + m[0][2]*m[1][0]*m[2][1]) + - (m[2][0]*m[1][1]*m[0][2] + m[2][1]*m[1][2]*m[0][0] + m[2][2]*m[1][0]*m[0][1]); + } +/* + //! Compute a cofactor. Used for matrix inversion. + float CoFactor(ubyte row, ubyte column) const + { + static const sdword gIndex[3+2] = { 0, 1, 2, 0, 1 }; + return (m[gIndex[row+1]][gIndex[column+1]]*m[gIndex[row+2]][gIndex[column+2]] - m[gIndex[row+2]][gIndex[column+1]]*m[gIndex[row+1]][gIndex[column+2]]); + } +*/ + //! Invert the matrix. Determinant must be different from zero, else matrix can't be inverted. + Matrix3x3& Invert() + { + float Det = Determinant(); // Must be !=0 + float OneOverDet = 1.0f / Det; + + Matrix3x3 Temp; + Temp.m[0][0] = +(m[1][1] * m[2][2] - m[2][1] * m[1][2]) * OneOverDet; + Temp.m[1][0] = -(m[1][0] * m[2][2] - m[2][0] * m[1][2]) * OneOverDet; + Temp.m[2][0] = +(m[1][0] * m[2][1] - m[2][0] * m[1][1]) * OneOverDet; + Temp.m[0][1] = -(m[0][1] * m[2][2] - m[2][1] * m[0][2]) * OneOverDet; + Temp.m[1][1] = +(m[0][0] * m[2][2] - m[2][0] * m[0][2]) * OneOverDet; + Temp.m[2][1] = -(m[0][0] * m[2][1] - m[2][0] * m[0][1]) * OneOverDet; + Temp.m[0][2] = +(m[0][1] * m[1][2] - m[1][1] * m[0][2]) * OneOverDet; + Temp.m[1][2] = -(m[0][0] * m[1][2] - m[1][0] * m[0][2]) * OneOverDet; + Temp.m[2][2] = +(m[0][0] * m[1][1] - m[1][0] * m[0][1]) * OneOverDet; + + *this = Temp; + + return *this; + } + + Matrix3x3& Normalize(); + + //! this = exp(a) + Matrix3x3& Exp(const Matrix3x3& a); + +void FromQuat(const Quat &q); +void FromQuatL2(const Quat &q, float l2); + + // Arithmetic operators + //! Operator for Matrix3x3 Plus = Matrix3x3 + Matrix3x3; + inline_ Matrix3x3 operator+(const Matrix3x3& mat) const + { + return Matrix3x3( + m[0][0] + mat.m[0][0], m[0][1] + mat.m[0][1], m[0][2] + mat.m[0][2], + m[1][0] + mat.m[1][0], m[1][1] + mat.m[1][1], m[1][2] + mat.m[1][2], + m[2][0] + mat.m[2][0], m[2][1] + mat.m[2][1], m[2][2] + mat.m[2][2]); + } + + //! Operator for Matrix3x3 Minus = Matrix3x3 - Matrix3x3; + inline_ Matrix3x3 operator-(const Matrix3x3& mat) const + { + return Matrix3x3( + m[0][0] - mat.m[0][0], m[0][1] - mat.m[0][1], m[0][2] - mat.m[0][2], + m[1][0] - mat.m[1][0], m[1][1] - mat.m[1][1], m[1][2] - mat.m[1][2], + m[2][0] - mat.m[2][0], m[2][1] - mat.m[2][1], m[2][2] - mat.m[2][2]); + } + + //! Operator for Matrix3x3 Mul = Matrix3x3 * Matrix3x3; + inline_ Matrix3x3 operator*(const Matrix3x3& mat) const + { + return Matrix3x3( + m[0][0]*mat.m[0][0] + m[0][1]*mat.m[1][0] + m[0][2]*mat.m[2][0], + m[0][0]*mat.m[0][1] + m[0][1]*mat.m[1][1] + m[0][2]*mat.m[2][1], + m[0][0]*mat.m[0][2] + m[0][1]*mat.m[1][2] + m[0][2]*mat.m[2][2], + + m[1][0]*mat.m[0][0] + m[1][1]*mat.m[1][0] + m[1][2]*mat.m[2][0], + m[1][0]*mat.m[0][1] + m[1][1]*mat.m[1][1] + m[1][2]*mat.m[2][1], + m[1][0]*mat.m[0][2] + m[1][1]*mat.m[1][2] + m[1][2]*mat.m[2][2], + + m[2][0]*mat.m[0][0] + m[2][1]*mat.m[1][0] + m[2][2]*mat.m[2][0], + m[2][0]*mat.m[0][1] + m[2][1]*mat.m[1][1] + m[2][2]*mat.m[2][1], + m[2][0]*mat.m[0][2] + m[2][1]*mat.m[1][2] + m[2][2]*mat.m[2][2]); + } + + //! Operator for Point Mul = Matrix3x3 * Point; + inline_ Point operator*(const Point& v) const { return Point(GetRow(0)|v, GetRow(1)|v, GetRow(2)|v); } + + //! Operator for Matrix3x3 Mul = Matrix3x3 * float; + inline_ Matrix3x3 operator*(float s) const + { + return Matrix3x3( + m[0][0]*s, m[0][1]*s, m[0][2]*s, + m[1][0]*s, m[1][1]*s, m[1][2]*s, + m[2][0]*s, m[2][1]*s, m[2][2]*s); + } + + //! Operator for Matrix3x3 Mul = float * Matrix3x3; + inline_ friend Matrix3x3 operator*(float s, const Matrix3x3& mat) + { + return Matrix3x3( + s*mat.m[0][0], s*mat.m[0][1], s*mat.m[0][2], + s*mat.m[1][0], s*mat.m[1][1], s*mat.m[1][2], + s*mat.m[2][0], s*mat.m[2][1], s*mat.m[2][2]); + } + + //! Operator for Matrix3x3 Div = Matrix3x3 / float; + inline_ Matrix3x3 operator/(float s) const + { + if (s) s = 1.0f / s; + return Matrix3x3( + m[0][0]*s, m[0][1]*s, m[0][2]*s, + m[1][0]*s, m[1][1]*s, m[1][2]*s, + m[2][0]*s, m[2][1]*s, m[2][2]*s); + } + + //! Operator for Matrix3x3 Div = float / Matrix3x3; + inline_ friend Matrix3x3 operator/(float s, const Matrix3x3& mat) + { + return Matrix3x3( + s/mat.m[0][0], s/mat.m[0][1], s/mat.m[0][2], + s/mat.m[1][0], s/mat.m[1][1], s/mat.m[1][2], + s/mat.m[2][0], s/mat.m[2][1], s/mat.m[2][2]); + } + + //! Operator for Matrix3x3 += Matrix3x3 + inline_ Matrix3x3& operator+=(const Matrix3x3& mat) + { + m[0][0] += mat.m[0][0]; m[0][1] += mat.m[0][1]; m[0][2] += mat.m[0][2]; + m[1][0] += mat.m[1][0]; m[1][1] += mat.m[1][1]; m[1][2] += mat.m[1][2]; + m[2][0] += mat.m[2][0]; m[2][1] += mat.m[2][1]; m[2][2] += mat.m[2][2]; + return *this; + } + + //! Operator for Matrix3x3 -= Matrix3x3 + inline_ Matrix3x3& operator-=(const Matrix3x3& mat) + { + m[0][0] -= mat.m[0][0]; m[0][1] -= mat.m[0][1]; m[0][2] -= mat.m[0][2]; + m[1][0] -= mat.m[1][0]; m[1][1] -= mat.m[1][1]; m[1][2] -= mat.m[1][2]; + m[2][0] -= mat.m[2][0]; m[2][1] -= mat.m[2][1]; m[2][2] -= mat.m[2][2]; + return *this; + } + + //! Operator for Matrix3x3 *= Matrix3x3 + inline_ Matrix3x3& operator*=(const Matrix3x3& mat) + { + Point TempRow; + + GetRow(0, TempRow); + m[0][0] = TempRow.x*mat.m[0][0] + TempRow.y*mat.m[1][0] + TempRow.z*mat.m[2][0]; + m[0][1] = TempRow.x*mat.m[0][1] + TempRow.y*mat.m[1][1] + TempRow.z*mat.m[2][1]; + m[0][2] = TempRow.x*mat.m[0][2] + TempRow.y*mat.m[1][2] + TempRow.z*mat.m[2][2]; + + GetRow(1, TempRow); + m[1][0] = TempRow.x*mat.m[0][0] + TempRow.y*mat.m[1][0] + TempRow.z*mat.m[2][0]; + m[1][1] = TempRow.x*mat.m[0][1] + TempRow.y*mat.m[1][1] + TempRow.z*mat.m[2][1]; + m[1][2] = TempRow.x*mat.m[0][2] + TempRow.y*mat.m[1][2] + TempRow.z*mat.m[2][2]; + + GetRow(2, TempRow); + m[2][0] = TempRow.x*mat.m[0][0] + TempRow.y*mat.m[1][0] + TempRow.z*mat.m[2][0]; + m[2][1] = TempRow.x*mat.m[0][1] + TempRow.y*mat.m[1][1] + TempRow.z*mat.m[2][1]; + m[2][2] = TempRow.x*mat.m[0][2] + TempRow.y*mat.m[1][2] + TempRow.z*mat.m[2][2]; + return *this; + } + + //! Operator for Matrix3x3 *= float + inline_ Matrix3x3& operator*=(float s) + { + m[0][0] *= s; m[0][1] *= s; m[0][2] *= s; + m[1][0] *= s; m[1][1] *= s; m[1][2] *= s; + m[2][0] *= s; m[2][1] *= s; m[2][2] *= s; + return *this; + } + + //! Operator for Matrix3x3 /= float + inline_ Matrix3x3& operator/=(float s) + { + if (s) s = 1.0f / s; + m[0][0] *= s; m[0][1] *= s; m[0][2] *= s; + m[1][0] *= s; m[1][1] *= s; m[1][2] *= s; + m[2][0] *= s; m[2][1] *= s; m[2][2] *= s; + return *this; + } + + // Cast operators + //! Cast a Matrix3x3 to a Matrix4x4. + operator Matrix4x4() const; + //! Cast a Matrix3x3 to a Quat. + operator Quat() const; + + inline_ const Point& operator[](int row) const { return *(const Point*)&m[row][0]; } + inline_ Point& operator[](int row) { return *(Point*)&m[row][0]; } + + public: + + float m[3][3]; + }; + +#endif // __ICEMATRIX3X3_H__ + diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceMatrix4x4.cpp b/libs/ode-0.16.1/OPCODE/Ice/IceMatrix4x4.cpp new file mode 100644 index 0000000..0b258f0 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceMatrix4x4.cpp @@ -0,0 +1,135 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for 4x4 matrices. + * \file IceMatrix4x4.cpp + * \author Pierre Terdiman + * \date April, 4, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * 4x4 matrix. + * DirectX-compliant, ie row-column order, ie m[Row][Col]. + * Same as: + * m11 m12 m13 m14 first row. + * m21 m22 m23 m24 second row. + * m31 m32 m33 m34 third row. + * m41 m42 m43 m44 fourth row. + * Translation is (m41, m42, m43), (m14, m24, m34, m44) = (0, 0, 0, 1). + * Stored in memory as m11 m12 m13 m14 m21... + * + * Multiplication rules: + * + * [x'y'z'1] = [xyz1][M] + * + * x' = x*m11 + y*m21 + z*m31 + m41 + * y' = x*m12 + y*m22 + z*m32 + m42 + * z' = x*m13 + y*m23 + z*m33 + m43 + * 1' = 0 + 0 + 0 + m44 + * + * \class Matrix4x4 + * \author Pierre Terdiman + * \version 1.0 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace IceMaths; + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Inverts a PR matrix. (which only contains a rotation and a translation) + * This is faster and less subject to FPU errors than the generic inversion code. + * + * \relates Matrix4x4 + * \fn InvertPRMatrix(Matrix4x4& dest, const Matrix4x4& src) + * \param dest [out] destination matrix + * \param src [in] source matrix + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +ICEMATHS_API void IceMaths::InvertPRMatrix(Matrix4x4& dest, const Matrix4x4& src) +{ + dest.m[0][0] = src.m[0][0]; + dest.m[1][0] = src.m[0][1]; + dest.m[2][0] = src.m[0][2]; + dest.m[3][0] = -(src.m[3][0]*src.m[0][0] + src.m[3][1]*src.m[0][1] + src.m[3][2]*src.m[0][2]); + + dest.m[0][1] = src.m[1][0]; + dest.m[1][1] = src.m[1][1]; + dest.m[2][1] = src.m[1][2]; + dest.m[3][1] = -(src.m[3][0]*src.m[1][0] + src.m[3][1]*src.m[1][1] + src.m[3][2]*src.m[1][2]); + + dest.m[0][2] = src.m[2][0]; + dest.m[1][2] = src.m[2][1]; + dest.m[2][2] = src.m[2][2]; + dest.m[3][2] = -(src.m[3][0]*src.m[2][0] + src.m[3][1]*src.m[2][1] + src.m[3][2]*src.m[2][2]); + + dest.m[0][3] = 0.0f; + dest.m[1][3] = 0.0f; + dest.m[2][3] = 0.0f; + dest.m[3][3] = 1.0f; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Compute the cofactor of the Matrix at a specified location +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +float Matrix4x4::CoFactor(udword row, udword col) const +{ + return (( m[(row+1)&3][(col+1)&3]*m[(row+2)&3][(col+2)&3]*m[(row+3)&3][(col+3)&3] + + m[(row+1)&3][(col+2)&3]*m[(row+2)&3][(col+3)&3]*m[(row+3)&3][(col+1)&3] + + m[(row+1)&3][(col+3)&3]*m[(row+2)&3][(col+1)&3]*m[(row+3)&3][(col+2)&3]) + - (m[(row+3)&3][(col+1)&3]*m[(row+2)&3][(col+2)&3]*m[(row+1)&3][(col+3)&3] + + m[(row+3)&3][(col+2)&3]*m[(row+2)&3][(col+3)&3]*m[(row+1)&3][(col+1)&3] + + m[(row+3)&3][(col+3)&3]*m[(row+2)&3][(col+1)&3]*m[(row+1)&3][(col+2)&3])) * ((row + col) & 1 ? -1.0f : +1.0f); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Compute the determinant of the Matrix +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +float Matrix4x4::Determinant() const +{ + return m[0][0] * CoFactor(0, 0) + + m[0][1] * CoFactor(0, 1) + + m[0][2] * CoFactor(0, 2) + + m[0][3] * CoFactor(0, 3); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Compute the inverse of the matrix +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +Matrix4x4& Matrix4x4::Invert() +{ + float Det = Determinant(); + Matrix4x4 Temp; + + if(fabsf(Det) < MATRIX4X4_EPSILON) + return *this; // The matrix is not invertible! Singular case! + + float IDet = 1.0f / Det; + + Temp.m[0][0] = CoFactor(0,0) * IDet; + Temp.m[1][0] = CoFactor(0,1) * IDet; + Temp.m[2][0] = CoFactor(0,2) * IDet; + Temp.m[3][0] = CoFactor(0,3) * IDet; + Temp.m[0][1] = CoFactor(1,0) * IDet; + Temp.m[1][1] = CoFactor(1,1) * IDet; + Temp.m[2][1] = CoFactor(1,2) * IDet; + Temp.m[3][1] = CoFactor(1,3) * IDet; + Temp.m[0][2] = CoFactor(2,0) * IDet; + Temp.m[1][2] = CoFactor(2,1) * IDet; + Temp.m[2][2] = CoFactor(2,2) * IDet; + Temp.m[3][2] = CoFactor(2,3) * IDet; + Temp.m[0][3] = CoFactor(3,0) * IDet; + Temp.m[1][3] = CoFactor(3,1) * IDet; + Temp.m[2][3] = CoFactor(3,2) * IDet; + Temp.m[3][3] = CoFactor(3,3) * IDet; + + *this = Temp; + + return *this; +} + diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceMatrix4x4.h b/libs/ode-0.16.1/OPCODE/Ice/IceMatrix4x4.h new file mode 100644 index 0000000..e2db104 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceMatrix4x4.h @@ -0,0 +1,457 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for 4x4 matrices. + * \file IceMatrix4x4.h + * \author Pierre Terdiman + * \date April, 4, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __ICEMATRIX4X4_H__ +#define __ICEMATRIX4X4_H__ + + // Forward declarations + class PRS; + class PR; + + #define MATRIX4X4_EPSILON (1.0e-7f) + + class ICEMATHS_API Matrix4x4 + { +// void LUBackwardSubstitution( sdword *indx, float* b ); +// void LUDecomposition( sdword* indx, float* d ); + + public: + //! Empty constructor. + inline_ Matrix4x4() {} + //! Constructor from 16 values + inline_ Matrix4x4( float m00, float m01, float m02, float m03, + float m10, float m11, float m12, float m13, + float m20, float m21, float m22, float m23, + float m30, float m31, float m32, float m33) + { + m[0][0] = m00; m[0][1] = m01; m[0][2] = m02; m[0][3] = m03; + m[1][0] = m10; m[1][1] = m11; m[1][2] = m12; m[1][3] = m13; + m[2][0] = m20; m[2][1] = m21; m[2][2] = m22; m[2][3] = m23; + m[3][0] = m30; m[3][1] = m31; m[3][2] = m32; m[3][3] = m33; + } + //! Copy constructor + inline_ Matrix4x4(const Matrix4x4& mat) { CopyMemory(m, &mat.m, 16*sizeof(float)); } + //! Destructor. + inline_ ~Matrix4x4() {} + + //! Assign values (rotation only) + template + inline_ Matrix4x4& Set( trotationfloat m00, trotationfloat m01, trotationfloat m02, + trotationfloat m10, trotationfloat m11, trotationfloat m12, + trotationfloat m20, trotationfloat m21, trotationfloat m22) + { + m[0][0] = (float)m00; m[0][1] = (float)m01; m[0][2] = (float)m02; + m[1][0] = (float)m10; m[1][1] = (float)m11; m[1][2] = (float)m12; + m[2][0] = (float)m20; m[2][1] = (float)m21; m[2][2] = (float)m22; + return *this; + } + //! Assign values + template + inline_ Matrix4x4& Set( trotationfloat m00, trotationfloat m01, trotationfloat m02, textrafloat m03, + trotationfloat m10, trotationfloat m11, trotationfloat m12, textrafloat m13, + trotationfloat m20, trotationfloat m21, trotationfloat m22, textrafloat m23, + toffsetfloat m30, toffsetfloat m31, toffsetfloat m32, textrafloat m33) + { + m[0][0] = (float)m00; m[0][1] = (float)m01; m[0][2] = (float)m02; m[0][3] = (float)m03; + m[1][0] = (float)m10; m[1][1] = (float)m11; m[1][2] = (float)m12; m[1][3] = (float)m13; + m[2][0] = (float)m20; m[2][1] = (float)m21; m[2][2] = (float)m22; m[2][3] = (float)m23; + m[3][0] = (float)m30; m[3][1] = (float)m31; m[3][2] = (float)m32; m[3][3] = (float)m33; + return *this; + } + + //! Copy from a Matrix4x4 + inline_ void Copy(const Matrix4x4& source) { CopyMemory(m, source.m, 16*sizeof(float)); } + + // Row-column access + //! Returns a row. + inline_ void GetRow(const udword r, HPoint& p) const { p.x=m[r][0]; p.y=m[r][1]; p.z=m[r][2]; p.w=m[r][3]; } + //! Returns a row. + inline_ void GetRow(const udword r, Point& p) const { p.x=m[r][0]; p.y=m[r][1]; p.z=m[r][2]; } + //! Returns a row. + inline_ const HPoint& GetRow(const udword r) const { return *(const HPoint*)&m[r][0]; } + //! Returns a row. + inline_ HPoint& GetRow(const udword r) { return *(HPoint*)&m[r][0]; } + //! Sets a row. + inline_ void SetRow(const udword r, const HPoint& p) { m[r][0]=p.x; m[r][1]=p.y; m[r][2]=p.z; m[r][3]=p.w; } + //! Sets a row. + inline_ void SetRow(const udword r, const Point& p) { m[r][0]=p.x; m[r][1]=p.y; m[r][2]=p.z; m[r][3]= (r!=3) ? 0.0f : 1.0f; } + //! Returns a column. + inline_ void GetCol(const udword c, HPoint& p) const { p.x=m[0][c]; p.y=m[1][c]; p.z=m[2][c]; p.w=m[3][c]; } + //! Returns a column. + inline_ void GetCol(const udword c, Point& p) const { p.x=m[0][c]; p.y=m[1][c]; p.z=m[2][c]; } + //! Sets a column. + inline_ void SetCol(const udword c, const HPoint& p) { m[0][c]=p.x; m[1][c]=p.y; m[2][c]=p.z; m[3][c]=p.w; } + //! Sets a column. + inline_ void SetCol(const udword c, const Point& p) { m[0][c]=p.x; m[1][c]=p.y; m[2][c]=p.z; m[3][c]= (c!=3) ? 0.0f : 1.0f; } + + // Translation + //! Returns the translation part of the matrix. + inline_ const HPoint& GetTrans() const { return GetRow(3); } + //! Gets the translation part of the matrix + inline_ void GetTrans(Point& p) const { p.x=m[3][0]; p.y=m[3][1]; p.z=m[3][2]; } + //! Sets the translation part of the matrix, from a Point. + inline_ void SetTrans(const Point& p) { m[3][0]=p.x; m[3][1]=p.y; m[3][2]=p.z; } + //! Sets the translation part of the matrix, from a HPoint. + inline_ void SetTrans(const HPoint& p) { m[3][0]=p.x; m[3][1]=p.y; m[3][2]=p.z; m[3][3]=p.w; } + //! Sets the translation part of the matrix, from floats. + inline_ void SetTrans(float tx, float ty, float tz) { m[3][0]=tx; m[3][1]=ty; m[3][2]=tz; } + + // Scale + //! Sets the scale from a Point. The point is put on the diagonal. + inline_ void SetScale(const Point& p) { m[0][0]=p.x; m[1][1]=p.y; m[2][2]=p.z; } + //! Sets the scale from floats. Values are put on the diagonal. + inline_ void SetScale(float sx, float sy, float sz) { m[0][0]=sx; m[1][1]=sy; m[2][2]=sz; } + //! Scales from a Point. Each row is multiplied by a component. + void Scale(const Point& p) + { + m[0][0] *= p.x; m[1][0] *= p.y; m[2][0] *= p.z; + m[0][1] *= p.x; m[1][1] *= p.y; m[2][1] *= p.z; + m[0][2] *= p.x; m[1][2] *= p.y; m[2][2] *= p.z; + } + //! Scales from floats. Each row is multiplied by a value. + void Scale(float sx, float sy, float sz) + { + m[0][0] *= sx; m[1][0] *= sy; m[2][0] *= sz; + m[0][1] *= sx; m[1][1] *= sy; m[2][1] *= sz; + m[0][2] *= sx; m[1][2] *= sy; m[2][2] *= sz; + } +/* + //! Returns a row. + inline_ HPoint GetRow(const udword row) const { return mRow[row]; } + //! Sets a row. + inline_ Matrix4x4& SetRow(const udword row, const HPoint& p) { mRow[row] = p; return *this; } + //! Sets a row. + Matrix4x4& SetRow(const udword row, const Point& p) + { + m[row][0] = p.x; + m[row][1] = p.y; + m[row][2] = p.z; + m[row][3] = (row != 3) ? 0.0f : 1.0f; + return *this; + } + //! Returns a column. + HPoint GetCol(const udword col) const + { + HPoint Res; + Res.x = m[0][col]; + Res.y = m[1][col]; + Res.z = m[2][col]; + Res.w = m[3][col]; + return Res; + } + //! Sets a column. + Matrix4x4& SetCol(const udword col, const HPoint& p) + { + m[0][col] = p.x; + m[1][col] = p.y; + m[2][col] = p.z; + m[3][col] = p.w; + return *this; + } + //! Sets a column. + Matrix4x4& SetCol(const udword col, const Point& p) + { + m[0][col] = p.x; + m[1][col] = p.y; + m[2][col] = p.z; + m[3][col] = (col != 3) ? 0.0f : 1.0f; + return *this; + } +*/ + //! Computes the trace. The trace is the sum of the 4 diagonal components. + inline_ float Trace() const { return m[0][0] + m[1][1] + m[2][2] + m[3][3]; } + //! Computes the trace of the upper 3x3 matrix. + inline_ float Trace3x3() const { return m[0][0] + m[1][1] + m[2][2]; } + //! Clears the matrix. + inline_ void Zero() { ZeroMemory(&m, sizeof(m)); } + //! Sets the identity matrix. + inline_ void Identity() { Zero(); m[0][0] = m[1][1] = m[2][2] = m[3][3] = 1.0f; } + //! Checks for identity + inline_ bool IsIdentity() const + { + if(IR(m[0][0])!=IEEE_1_0) return false; + if(IR(m[0][1])!=0) return false; + if(IR(m[0][2])!=0) return false; + if(IR(m[0][3])!=0) return false; + + if(IR(m[1][0])!=0) return false; + if(IR(m[1][1])!=IEEE_1_0) return false; + if(IR(m[1][2])!=0) return false; + if(IR(m[1][3])!=0) return false; + + if(IR(m[2][0])!=0) return false; + if(IR(m[2][1])!=0) return false; + if(IR(m[2][2])!=IEEE_1_0) return false; + if(IR(m[2][3])!=0) return false; + + if(IR(m[3][0])!=0) return false; + if(IR(m[3][1])!=0) return false; + if(IR(m[3][2])!=0) return false; + if(IR(m[3][3])!=IEEE_1_0) return false; + return true; + } + + //! Checks matrix validity + inline_ BOOL IsValid() const + { + for(udword j=0;j<4;j++) + { + for(udword i=0;i<4;i++) + { + if(!IsValidFloat(m[j][i])) return FALSE; + } + } + return TRUE; + } + + //! Sets a rotation matrix around the X axis. + void RotX(float angle) { float Cos = cosf(angle), Sin = sinf(angle); Identity(); m[1][1] = m[2][2] = Cos; m[2][1] = -Sin; m[1][2] = Sin; } + //! Sets a rotation matrix around the Y axis. + void RotY(float angle) { float Cos = cosf(angle), Sin = sinf(angle); Identity(); m[0][0] = m[2][2] = Cos; m[2][0] = Sin; m[0][2] = -Sin; } + //! Sets a rotation matrix around the Z axis. + void RotZ(float angle) { float Cos = cosf(angle), Sin = sinf(angle); Identity(); m[0][0] = m[1][1] = Cos; m[1][0] = -Sin; m[0][1] = Sin; } + + //! Makes a rotation matrix about an arbitrary axis + Matrix4x4& Rot(float angle, Point& p1, Point& p2); + + //! Transposes the matrix. + void Transpose() + { + TSwap(m[1][0], m[0][1]); + TSwap(m[2][0], m[0][2]); + TSwap(m[3][0], m[0][3]); + TSwap(m[1][2], m[2][1]); + TSwap(m[1][3], m[3][1]); + TSwap(m[2][3], m[3][2]); + } + + //! Computes a cofactor. Used for matrix inversion. + float CoFactor(udword row, udword col) const; + //! Computes the determinant of the matrix. + float Determinant() const; + //! Inverts the matrix. Determinant must be different from zero, else matrix can't be inverted. + Matrix4x4& Invert(); +// Matrix& ComputeAxisMatrix(Point& axis, float angle); + + // Cast operators + //! Casts a Matrix4x4 to a Matrix3x3. + inline_ operator Matrix3x3() const + { + return Matrix3x3( + m[0][0], m[0][1], m[0][2], + m[1][0], m[1][1], m[1][2], + m[2][0], m[2][1], m[2][2]); + } + //! Casts a Matrix4x4 to a Quat. + operator Quat() const; + //! Casts a Matrix4x4 to a PR. + operator PR() const; + + // Arithmetic operators + //! Operator for Matrix4x4 Plus = Matrix4x4 + Matrix4x4; + inline_ Matrix4x4 operator+(const Matrix4x4& mat) const + { + return Matrix4x4( + m[0][0]+mat.m[0][0], m[0][1]+mat.m[0][1], m[0][2]+mat.m[0][2], m[0][3]+mat.m[0][3], + m[1][0]+mat.m[1][0], m[1][1]+mat.m[1][1], m[1][2]+mat.m[1][2], m[1][3]+mat.m[1][3], + m[2][0]+mat.m[2][0], m[2][1]+mat.m[2][1], m[2][2]+mat.m[2][2], m[2][3]+mat.m[2][3], + m[3][0]+mat.m[3][0], m[3][1]+mat.m[3][1], m[3][2]+mat.m[3][2], m[3][3]+mat.m[3][3]); + } + + //! Operator for Matrix4x4 Minus = Matrix4x4 - Matrix4x4; + inline_ Matrix4x4 operator-(const Matrix4x4& mat) const + { + return Matrix4x4( + m[0][0]-mat.m[0][0], m[0][1]-mat.m[0][1], m[0][2]-mat.m[0][2], m[0][3]-mat.m[0][3], + m[1][0]-mat.m[1][0], m[1][1]-mat.m[1][1], m[1][2]-mat.m[1][2], m[1][3]-mat.m[1][3], + m[2][0]-mat.m[2][0], m[2][1]-mat.m[2][1], m[2][2]-mat.m[2][2], m[2][3]-mat.m[2][3], + m[3][0]-mat.m[3][0], m[3][1]-mat.m[3][1], m[3][2]-mat.m[3][2], m[3][3]-mat.m[3][3]); + } + + //! Operator for Matrix4x4 Mul = Matrix4x4 * Matrix4x4; + inline_ Matrix4x4 operator*(const Matrix4x4& mat) const + { + return Matrix4x4( + m[0][0]*mat.m[0][0] + m[0][1]*mat.m[1][0] + m[0][2]*mat.m[2][0] + m[0][3]*mat.m[3][0], + m[0][0]*mat.m[0][1] + m[0][1]*mat.m[1][1] + m[0][2]*mat.m[2][1] + m[0][3]*mat.m[3][1], + m[0][0]*mat.m[0][2] + m[0][1]*mat.m[1][2] + m[0][2]*mat.m[2][2] + m[0][3]*mat.m[3][2], + m[0][0]*mat.m[0][3] + m[0][1]*mat.m[1][3] + m[0][2]*mat.m[2][3] + m[0][3]*mat.m[3][3], + + m[1][0]*mat.m[0][0] + m[1][1]*mat.m[1][0] + m[1][2]*mat.m[2][0] + m[1][3]*mat.m[3][0], + m[1][0]*mat.m[0][1] + m[1][1]*mat.m[1][1] + m[1][2]*mat.m[2][1] + m[1][3]*mat.m[3][1], + m[1][0]*mat.m[0][2] + m[1][1]*mat.m[1][2] + m[1][2]*mat.m[2][2] + m[1][3]*mat.m[3][2], + m[1][0]*mat.m[0][3] + m[1][1]*mat.m[1][3] + m[1][2]*mat.m[2][3] + m[1][3]*mat.m[3][3], + + m[2][0]*mat.m[0][0] + m[2][1]*mat.m[1][0] + m[2][2]*mat.m[2][0] + m[2][3]*mat.m[3][0], + m[2][0]*mat.m[0][1] + m[2][1]*mat.m[1][1] + m[2][2]*mat.m[2][1] + m[2][3]*mat.m[3][1], + m[2][0]*mat.m[0][2] + m[2][1]*mat.m[1][2] + m[2][2]*mat.m[2][2] + m[2][3]*mat.m[3][2], + m[2][0]*mat.m[0][3] + m[2][1]*mat.m[1][3] + m[2][2]*mat.m[2][3] + m[2][3]*mat.m[3][3], + + m[3][0]*mat.m[0][0] + m[3][1]*mat.m[1][0] + m[3][2]*mat.m[2][0] + m[3][3]*mat.m[3][0], + m[3][0]*mat.m[0][1] + m[3][1]*mat.m[1][1] + m[3][2]*mat.m[2][1] + m[3][3]*mat.m[3][1], + m[3][0]*mat.m[0][2] + m[3][1]*mat.m[1][2] + m[3][2]*mat.m[2][2] + m[3][3]*mat.m[3][2], + m[3][0]*mat.m[0][3] + m[3][1]*mat.m[1][3] + m[3][2]*mat.m[2][3] + m[3][3]*mat.m[3][3]); + } + + //! Operator for HPoint Mul = Matrix4x4 * HPoint; + inline_ HPoint operator*(const HPoint& v) const { return HPoint(GetRow(0)|v, GetRow(1)|v, GetRow(2)|v, GetRow(3)|v); } + + //! Operator for Point Mul = Matrix4x4 * Point; + inline_ Point operator*(const Point& v) const + { + return Point( m[0][0]*v.x + m[0][1]*v.y + m[0][2]*v.z + m[0][3], + m[1][0]*v.x + m[1][1]*v.y + m[1][2]*v.z + m[1][3], + m[2][0]*v.x + m[2][1]*v.y + m[2][2]*v.z + m[2][3] ); + } + + //! Operator for Matrix4x4 Scale = Matrix4x4 * float; + inline_ Matrix4x4 operator*(float s) const + { + return Matrix4x4( + m[0][0]*s, m[0][1]*s, m[0][2]*s, m[0][3]*s, + m[1][0]*s, m[1][1]*s, m[1][2]*s, m[1][3]*s, + m[2][0]*s, m[2][1]*s, m[2][2]*s, m[2][3]*s, + m[3][0]*s, m[3][1]*s, m[3][2]*s, m[3][3]*s); + } + + //! Operator for Matrix4x4 Scale = float * Matrix4x4; + inline_ friend Matrix4x4 operator*(float s, const Matrix4x4& mat) + { + return Matrix4x4( + s*mat.m[0][0], s*mat.m[0][1], s*mat.m[0][2], s*mat.m[0][3], + s*mat.m[1][0], s*mat.m[1][1], s*mat.m[1][2], s*mat.m[1][3], + s*mat.m[2][0], s*mat.m[2][1], s*mat.m[2][2], s*mat.m[2][3], + s*mat.m[3][0], s*mat.m[3][1], s*mat.m[3][2], s*mat.m[3][3]); + } + + //! Operator for Matrix4x4 Div = Matrix4x4 / float; + inline_ Matrix4x4 operator/(float s) const + { + if(s) s = 1.0f / s; + + return Matrix4x4( + m[0][0]*s, m[0][1]*s, m[0][2]*s, m[0][3]*s, + m[1][0]*s, m[1][1]*s, m[1][2]*s, m[1][3]*s, + m[2][0]*s, m[2][1]*s, m[2][2]*s, m[2][3]*s, + m[3][0]*s, m[3][1]*s, m[3][2]*s, m[3][3]*s); + } + + //! Operator for Matrix4x4 Div = float / Matrix4x4; + inline_ friend Matrix4x4 operator/(float s, const Matrix4x4& mat) + { + return Matrix4x4( + s/mat.m[0][0], s/mat.m[0][1], s/mat.m[0][2], s/mat.m[0][3], + s/mat.m[1][0], s/mat.m[1][1], s/mat.m[1][2], s/mat.m[1][3], + s/mat.m[2][0], s/mat.m[2][1], s/mat.m[2][2], s/mat.m[2][3], + s/mat.m[3][0], s/mat.m[3][1], s/mat.m[3][2], s/mat.m[3][3]); + } + + //! Operator for Matrix4x4 += Matrix4x4; + inline_ Matrix4x4& operator+=(const Matrix4x4& mat) + { + m[0][0]+=mat.m[0][0]; m[0][1]+=mat.m[0][1]; m[0][2]+=mat.m[0][2]; m[0][3]+=mat.m[0][3]; + m[1][0]+=mat.m[1][0]; m[1][1]+=mat.m[1][1]; m[1][2]+=mat.m[1][2]; m[1][3]+=mat.m[1][3]; + m[2][0]+=mat.m[2][0]; m[2][1]+=mat.m[2][1]; m[2][2]+=mat.m[2][2]; m[2][3]+=mat.m[2][3]; + m[3][0]+=mat.m[3][0]; m[3][1]+=mat.m[3][1]; m[3][2]+=mat.m[3][2]; m[3][3]+=mat.m[3][3]; + return *this; + } + + //! Operator for Matrix4x4 -= Matrix4x4; + inline_ Matrix4x4& operator-=(const Matrix4x4& mat) + { + m[0][0]-=mat.m[0][0]; m[0][1]-=mat.m[0][1]; m[0][2]-=mat.m[0][2]; m[0][3]-=mat.m[0][3]; + m[1][0]-=mat.m[1][0]; m[1][1]-=mat.m[1][1]; m[1][2]-=mat.m[1][2]; m[1][3]-=mat.m[1][3]; + m[2][0]-=mat.m[2][0]; m[2][1]-=mat.m[2][1]; m[2][2]-=mat.m[2][2]; m[2][3]-=mat.m[2][3]; + m[3][0]-=mat.m[3][0]; m[3][1]-=mat.m[3][1]; m[3][2]-=mat.m[3][2]; m[3][3]-=mat.m[3][3]; + return *this; + } + + //! Operator for Matrix4x4 *= Matrix4x4; + Matrix4x4& operator*=(const Matrix4x4& mat) + { + HPoint TempRow; + + GetRow(0, TempRow); + m[0][0] = TempRow.x*mat.m[0][0] + TempRow.y*mat.m[1][0] + TempRow.z*mat.m[2][0] + TempRow.w*mat.m[3][0]; + m[0][1] = TempRow.x*mat.m[0][1] + TempRow.y*mat.m[1][1] + TempRow.z*mat.m[2][1] + TempRow.w*mat.m[3][1]; + m[0][2] = TempRow.x*mat.m[0][2] + TempRow.y*mat.m[1][2] + TempRow.z*mat.m[2][2] + TempRow.w*mat.m[3][2]; + m[0][3] = TempRow.x*mat.m[0][3] + TempRow.y*mat.m[1][3] + TempRow.z*mat.m[2][3] + TempRow.w*mat.m[3][3]; + + GetRow(1, TempRow); + m[1][0] = TempRow.x*mat.m[0][0] + TempRow.y*mat.m[1][0] + TempRow.z*mat.m[2][0] + TempRow.w*mat.m[3][0]; + m[1][1] = TempRow.x*mat.m[0][1] + TempRow.y*mat.m[1][1] + TempRow.z*mat.m[2][1] + TempRow.w*mat.m[3][1]; + m[1][2] = TempRow.x*mat.m[0][2] + TempRow.y*mat.m[1][2] + TempRow.z*mat.m[2][2] + TempRow.w*mat.m[3][2]; + m[1][3] = TempRow.x*mat.m[0][3] + TempRow.y*mat.m[1][3] + TempRow.z*mat.m[2][3] + TempRow.w*mat.m[3][3]; + + GetRow(2, TempRow); + m[2][0] = TempRow.x*mat.m[0][0] + TempRow.y*mat.m[1][0] + TempRow.z*mat.m[2][0] + TempRow.w*mat.m[3][0]; + m[2][1] = TempRow.x*mat.m[0][1] + TempRow.y*mat.m[1][1] + TempRow.z*mat.m[2][1] + TempRow.w*mat.m[3][1]; + m[2][2] = TempRow.x*mat.m[0][2] + TempRow.y*mat.m[1][2] + TempRow.z*mat.m[2][2] + TempRow.w*mat.m[3][2]; + m[2][3] = TempRow.x*mat.m[0][3] + TempRow.y*mat.m[1][3] + TempRow.z*mat.m[2][3] + TempRow.w*mat.m[3][3]; + + GetRow(3, TempRow); + m[3][0] = TempRow.x*mat.m[0][0] + TempRow.y*mat.m[1][0] + TempRow.z*mat.m[2][0] + TempRow.w*mat.m[3][0]; + m[3][1] = TempRow.x*mat.m[0][1] + TempRow.y*mat.m[1][1] + TempRow.z*mat.m[2][1] + TempRow.w*mat.m[3][1]; + m[3][2] = TempRow.x*mat.m[0][2] + TempRow.y*mat.m[1][2] + TempRow.z*mat.m[2][2] + TempRow.w*mat.m[3][2]; + m[3][3] = TempRow.x*mat.m[0][3] + TempRow.y*mat.m[1][3] + TempRow.z*mat.m[2][3] + TempRow.w*mat.m[3][3]; + + return *this; + } + + //! Operator for Matrix4x4 *= float; + inline_ Matrix4x4& operator*=(float s) + { + m[0][0]*=s; m[0][1]*=s; m[0][2]*=s; m[0][3]*=s; + m[1][0]*=s; m[1][1]*=s; m[1][2]*=s; m[1][3]*=s; + m[2][0]*=s; m[2][1]*=s; m[2][2]*=s; m[2][3]*=s; + m[3][0]*=s; m[3][1]*=s; m[3][2]*=s; m[3][3]*=s; + return *this; + } + + //! Operator for Matrix4x4 /= float; + inline_ Matrix4x4& operator/=(float s) + { + if(s) s = 1.0f / s; + m[0][0]*=s; m[0][1]*=s; m[0][2]*=s; m[0][3]*=s; + m[1][0]*=s; m[1][1]*=s; m[1][2]*=s; m[1][3]*=s; + m[2][0]*=s; m[2][1]*=s; m[2][2]*=s; m[2][3]*=s; + m[3][0]*=s; m[3][1]*=s; m[3][2]*=s; m[3][3]*=s; + return *this; + } + + inline_ const HPoint& operator[](int row) const { return *(const HPoint*)&m[row][0]; } + inline_ HPoint& operator[](int row) { return *(HPoint*)&m[row][0]; } + + public: + + float m[4][4]; + }; + + //! Quickly rotates & translates a vector, using the 4x3 part of a 4x4 matrix + inline_ void TransformPoint4x3(Point& dest, const Point& source, const Matrix4x4& rot) + { + dest.x = rot.m[3][0] + source.x * rot.m[0][0] + source.y * rot.m[1][0] + source.z * rot.m[2][0]; + dest.y = rot.m[3][1] + source.x * rot.m[0][1] + source.y * rot.m[1][1] + source.z * rot.m[2][1]; + dest.z = rot.m[3][2] + source.x * rot.m[0][2] + source.y * rot.m[1][2] + source.z * rot.m[2][2]; + } + + //! Quickly rotates a vector, using the 3x3 part of a 4x4 matrix + inline_ void TransformPoint3x3(Point& dest, const Point& source, const Matrix4x4& rot) + { + dest.x = source.x * rot.m[0][0] + source.y * rot.m[1][0] + source.z * rot.m[2][0]; + dest.y = source.x * rot.m[0][1] + source.y * rot.m[1][1] + source.z * rot.m[2][1]; + dest.z = source.x * rot.m[0][2] + source.y * rot.m[1][2] + source.z * rot.m[2][2]; + } + + ICEMATHS_API void InvertPRMatrix(Matrix4x4& dest, const Matrix4x4& src); + +#endif // __ICEMATRIX4X4_H__ + diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceMemoryMacros.h b/libs/ode-0.16.1/OPCODE/Ice/IceMemoryMacros.h new file mode 100644 index 0000000..ad25c44 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceMemoryMacros.h @@ -0,0 +1,86 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains all memory macros. + * \file IceMemoryMacros.h + * \author Pierre Terdiman + * \date April, 4, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __ICEMEMORYMACROS_H__ +#define __ICEMEMORYMACROS_H__ + +#undef ZeroMemory +#undef CopyMemory +#undef MoveMemory +#undef FillMemory + + //! Clears a buffer. + //! \param addr [in] buffer address + //! \param size [in] buffer length + //! \see FillMemory + //! \see StoreDwords + //! \see CopyMemory + //! \see MoveMemory + inline_ void ZeroMemory(void* addr, udword size) { memset(addr, 0, size); } + + //! Fills a buffer with a given byte. + //! \param addr [in] buffer address + //! \param size [in] buffer length + //! \param val [in] the byte value + //! \see StoreDwords + //! \see ZeroMemory + //! \see CopyMemory + //! \see MoveMemory + inline_ void FillMemory(void* dest, udword size, ubyte val) { memset(dest, val, size); } + + //! Fills a buffer with a given dword. + //! \param addr [in] buffer address + //! \param nb [in] number of dwords to write + //! \param value [in] the dword value + //! \see FillMemory + //! \see ZeroMemory + //! \see CopyMemory + //! \see MoveMemory + //! \warning writes nb*4 bytes ! + inline_ void StoreDwords(udword* dest, udword nb, udword value) + { + while(nb--) *dest++ = value; + } + + //! Copies a buffer. + //! \param addr [in] destination buffer address + //! \param addr [in] source buffer address + //! \param size [in] buffer length + //! \see ZeroMemory + //! \see FillMemory + //! \see StoreDwords + //! \see MoveMemory + inline_ void CopyMemory(void* dest, const void* src, udword size) { memcpy(dest, src, size); } + + //! Moves a buffer. + //! \param addr [in] destination buffer address + //! \param addr [in] source buffer address + //! \param size [in] buffer length + //! \see ZeroMemory + //! \see FillMemory + //! \see StoreDwords + //! \see CopyMemory + inline_ void MoveMemory(void* dest, const void* src, udword size) { memmove(dest, src, size); } + + #define SIZEOFOBJECT sizeof(*this) //!< Gives the size of current object. Avoid some mistakes (e.g. "sizeof(this)"). + //#define CLEAROBJECT { memset(this, 0, SIZEOFOBJECT); } //!< Clears current object. Laziness is my business. HANDLE WITH CARE. + #define DELETESINGLE(x) if (x) { delete x; x = null; } //!< Deletes an instance of a class. + #define DELETEARRAY(x) if (x) { delete []x; x = null; } //!< Deletes an array. + #define SAFE_RELEASE(x) if (x) { (x)->Release(); (x) = null; } //!< Safe D3D-style release + #define SAFE_DESTRUCT(x) if (x) { (x)->SelfDestruct(); (x) = null; } //!< Safe ICE-style release + +#ifdef __ICEERROR_H__ + #define CHECKALLOC(x) if(!x) return SetIceError("Out of memory.", EC_OUT_OF_MEMORY); //!< Standard alloc checking. HANDLE WITH CARE. +#else + #define CHECKALLOC(x) if(!x) return false; +#endif + +#endif // __ICEMEMORYMACROS_H__ diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceOBB.cpp b/libs/ode-0.16.1/OPCODE/Ice/IceOBB.cpp new file mode 100644 index 0000000..0ad1ce3 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceOBB.cpp @@ -0,0 +1,324 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains OBB-related code. + * \file IceOBB.cpp + * \author Pierre Terdiman + * \date January, 29, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * An Oriented Bounding Box (OBB). + * \class OBB + * \author Pierre Terdiman + * \version 1.0 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace IceMaths; + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Tests if a point is contained within the OBB. + * \param p [in] the world point to test + * \return true if inside the OBB + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool OBB::ContainsPoint(const Point& p) const +{ + // Point in OBB test using lazy evaluation and early exits + + // Translate to box space + Point RelPoint = p - mCenter; + + // Point * mRot maps from box space to world space + // mRot * Point maps from world space to box space (what we need here) + + float f = mRot.m[0][0] * RelPoint.x + mRot.m[0][1] * RelPoint.y + mRot.m[0][2] * RelPoint.z; + if(f >= mExtents.x || f <= -mExtents.x) return false; + + f = mRot.m[1][0] * RelPoint.x + mRot.m[1][1] * RelPoint.y + mRot.m[1][2] * RelPoint.z; + if(f >= mExtents.y || f <= -mExtents.y) return false; + + f = mRot.m[2][0] * RelPoint.x + mRot.m[2][1] * RelPoint.y + mRot.m[2][2] * RelPoint.z; + if(f >= mExtents.z || f <= -mExtents.z) return false; + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Builds an OBB from an AABB and a world transform. + * \param aabb [in] the aabb + * \param mat [in] the world transform + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void OBB::Create(const AABB& aabb, const Matrix4x4& mat) +{ + // Note: must be coherent with Rotate() + + aabb.GetCenter(mCenter); + aabb.GetExtents(mExtents); + // Here we have the same as OBB::Rotate(mat) where the obb is (mCenter, mExtents, Identity). + + // So following what's done in Rotate: + // - x-form the center + mCenter *= mat; + // - combine rotation with identity, i.e. just use given matrix + mRot = mat; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the obb planes. + * \param planes [out] 6 box planes + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool OBB::ComputePlanes(Plane* planes) const +{ + // Checkings + if(!planes) return false; + + Point Axis0 = mRot[0]; + Point Axis1 = mRot[1]; + Point Axis2 = mRot[2]; + + // Writes normals + planes[0].n = Axis0; + planes[1].n = -Axis0; + planes[2].n = Axis1; + planes[3].n = -Axis1; + planes[4].n = Axis2; + planes[5].n = -Axis2; + + // Compute a point on each plane + Point p0 = mCenter + Axis0 * mExtents.x; + Point p1 = mCenter - Axis0 * mExtents.x; + Point p2 = mCenter + Axis1 * mExtents.y; + Point p3 = mCenter - Axis1 * mExtents.y; + Point p4 = mCenter + Axis2 * mExtents.z; + Point p5 = mCenter - Axis2 * mExtents.z; + + // Compute d + planes[0].d = -(planes[0].n|p0); + planes[1].d = -(planes[1].n|p1); + planes[2].d = -(planes[2].n|p2); + planes[3].d = -(planes[3].n|p3); + planes[4].d = -(planes[4].n|p4); + planes[5].d = -(planes[5].n|p5); + + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the obb points. + * \param pts [out] 8 box points + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool OBB::ComputePoints(Point* pts) const +{ + // Checkings + if(!pts) return false; + + Point Axis0 = mRot[0]; + Point Axis1 = mRot[1]; + Point Axis2 = mRot[2]; + + Axis0 *= mExtents.x; + Axis1 *= mExtents.y; + Axis2 *= mExtents.z; + + // 7+------+6 0 = --- + // /| /| 1 = +-- + // / | / | 2 = ++- + // / 4+---/--+5 3 = -+- + // 3+------+2 / y z 4 = --+ + // | / | / | / 5 = +-+ + // |/ |/ |/ 6 = +++ + // 0+------+1 *---x 7 = -++ + + pts[0] = mCenter - Axis0 - Axis1 - Axis2; + pts[1] = mCenter + Axis0 - Axis1 - Axis2; + pts[2] = mCenter + Axis0 + Axis1 - Axis2; + pts[3] = mCenter - Axis0 + Axis1 - Axis2; + pts[4] = mCenter - Axis0 - Axis1 + Axis2; + pts[5] = mCenter + Axis0 - Axis1 + Axis2; + pts[6] = mCenter + Axis0 + Axis1 + Axis2; + pts[7] = mCenter - Axis0 + Axis1 + Axis2; + + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes vertex normals. + * \param pts [out] 8 box points + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool OBB::ComputeVertexNormals(Point* pts) const +{ + static const float VertexNormals[] = + { + -INVSQRT3, -INVSQRT3, -INVSQRT3, + INVSQRT3, -INVSQRT3, -INVSQRT3, + INVSQRT3, INVSQRT3, -INVSQRT3, + -INVSQRT3, INVSQRT3, -INVSQRT3, + -INVSQRT3, -INVSQRT3, INVSQRT3, + INVSQRT3, -INVSQRT3, INVSQRT3, + INVSQRT3, INVSQRT3, INVSQRT3, + -INVSQRT3, INVSQRT3, INVSQRT3 + }; + + if(!pts) return false; + + const Point* VN = (const Point*)VertexNormals; + for(udword i=0;i<8;i++) + { + pts[i] = VN[i] * mRot; + } + + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Returns edges. + * \return 24 indices (12 edges) indexing the list returned by ComputePoints() + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +const udword* OBB::GetEdges() const +{ + static const udword Indices[] = { + 0, 1, 1, 2, 2, 3, 3, 0, + 7, 6, 6, 5, 5, 4, 4, 7, + 1, 5, 6, 2, + 3, 7, 4, 0 + }; + return Indices; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Returns local edge normals. + * \return edge normals in local space + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +const Point* OBB::GetLocalEdgeNormals() const +{ + static const float EdgeNormals[] = + { + 0, -INVSQRT2, -INVSQRT2, // 0-1 + INVSQRT2, 0, -INVSQRT2, // 1-2 + 0, INVSQRT2, -INVSQRT2, // 2-3 + -INVSQRT2, 0, -INVSQRT2, // 3-0 + + 0, INVSQRT2, INVSQRT2, // 7-6 + INVSQRT2, 0, INVSQRT2, // 6-5 + 0, -INVSQRT2, INVSQRT2, // 5-4 + -INVSQRT2, 0, INVSQRT2, // 4-7 + + INVSQRT2, -INVSQRT2, 0, // 1-5 + INVSQRT2, INVSQRT2, 0, // 6-2 + -INVSQRT2, INVSQRT2, 0, // 3-7 + -INVSQRT2, -INVSQRT2, 0 // 4-0 + }; + return (const Point*)EdgeNormals; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Returns world edge normal + * \param edge_index [in] 0 <= edge index < 12 + * \param world_normal [out] edge normal in world space + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void OBB::ComputeWorldEdgeNormal(udword edge_index, Point& world_normal) const +{ + ASSERT(edge_index<12); + world_normal = GetLocalEdgeNormals()[edge_index] * mRot; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes an LSS surrounding the OBB. + * \param lss [out] the LSS + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void OBB::ComputeLSS(LSS& lss) const +{ + Point Axis0 = mRot[0]; + Point Axis1 = mRot[1]; + Point Axis2 = mRot[2]; + + switch(mExtents.LargestAxis()) + { + case 0: + lss.mRadius = (mExtents.y + mExtents.z)*0.5f; + lss.mP0 = mCenter + Axis0 * (mExtents.x - lss.mRadius); + lss.mP1 = mCenter - Axis0 * (mExtents.x - lss.mRadius); + break; + case 1: + lss.mRadius = (mExtents.x + mExtents.z)*0.5f; + lss.mP0 = mCenter + Axis1 * (mExtents.y - lss.mRadius); + lss.mP1 = mCenter - Axis1 * (mExtents.y - lss.mRadius); + break; + case 2: + lss.mRadius = (mExtents.x + mExtents.y)*0.5f; + lss.mP0 = mCenter + Axis2 * (mExtents.z - lss.mRadius); + lss.mP1 = mCenter - Axis2 * (mExtents.z - lss.mRadius); + break; + default: {} + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Checks the OBB is inside another OBB. + * \param box [in] the other OBB + * \return TRUE if we're inside the other box + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +BOOL OBB::IsInside(const OBB& box) const +{ + // Make a 4x4 from the box & inverse it + Matrix4x4 M0Inv; + { + Matrix4x4 M0 = box.mRot; + M0.SetTrans(box.mCenter); + InvertPRMatrix(M0Inv, M0); + } + + // With our inversed 4x4, create box1 in space of box0 + OBB _1in0; + Rotate(M0Inv, _1in0); + + // This should cancel out box0's rotation, i.e. it's now an AABB. + // => Center(0,0,0), Rot(identity) + + // The two boxes are in the same space so now we can compare them. + + // Create the AABB of (box1 in space of box0) + const Matrix3x3& mtx = _1in0.mRot; + + float f = fabsf(mtx.m[0][0] * mExtents.x) + fabsf(mtx.m[1][0] * mExtents.y) + fabsf(mtx.m[2][0] * mExtents.z) - box.mExtents.x; + if(f > _1in0.mCenter.x) return FALSE; + if(-f < _1in0.mCenter.x) return FALSE; + + f = fabsf(mtx.m[0][1] * mExtents.x) + fabsf(mtx.m[1][1] * mExtents.y) + fabsf(mtx.m[2][1] * mExtents.z) - box.mExtents.y; + if(f > _1in0.mCenter.y) return FALSE; + if(-f < _1in0.mCenter.y) return FALSE; + + f = fabsf(mtx.m[0][2] * mExtents.x) + fabsf(mtx.m[1][2] * mExtents.y) + fabsf(mtx.m[2][2] * mExtents.z) - box.mExtents.z; + if(f > _1in0.mCenter.z) return FALSE; + if(-f < _1in0.mCenter.z) return FALSE; + + return TRUE; +} diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceOBB.h b/libs/ode-0.16.1/OPCODE/Ice/IceOBB.h new file mode 100644 index 0000000..d6cf43e --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceOBB.h @@ -0,0 +1,177 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains OBB-related code. (oriented bounding box) + * \file IceOBB.h + * \author Pierre Terdiman + * \date January, 13, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __ICEOBB_H__ +#define __ICEOBB_H__ + + // Forward declarations + class LSS; + + class ICEMATHS_API OBB + { + public: + //! Constructor + inline_ OBB() {} + //! Constructor + inline_ OBB(const Point& center, const Point& extents, const Matrix3x3& rot) : mCenter(center), mExtents(extents), mRot(rot) {} + //! Destructor + inline_ ~OBB() {} + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Setups an empty OBB. + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + void SetEmpty() + { + mCenter.Zero(); + mExtents.Set(MIN_FLOAT, MIN_FLOAT, MIN_FLOAT); + mRot.Identity(); + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Tests if a point is contained within the OBB. + * \param p [in] the world point to test + * \return true if inside the OBB + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + bool ContainsPoint(const Point& p) const; + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Builds an OBB from an AABB and a world transform. + * \param aabb [in] the aabb + * \param mat [in] the world transform + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + void Create(const AABB& aabb, const Matrix4x4& mat); + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Recomputes the OBB after an arbitrary transform by a 4x4 matrix. + * \param mtx [in] the transform matrix + * \param obb [out] the transformed OBB + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void Rotate(const Matrix4x4& mtx, OBB& obb) const + { + // The extents remain constant + obb.mExtents = mExtents; + // The center gets x-formed + obb.mCenter = mCenter * mtx; + // Combine rotations + obb.mRot = mRot * Matrix3x3(mtx); + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Checks the OBB is valid. + * \return true if the box is valid + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ BOOL IsValid() const + { + // Consistency condition for (Center, Extents) boxes: Extents >= 0.0f + if(mExtents.x < 0.0f) return FALSE; + if(mExtents.y < 0.0f) return FALSE; + if(mExtents.z < 0.0f) return FALSE; + return TRUE; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Computes the obb planes. + * \param planes [out] 6 box planes + * \return true if success + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + bool ComputePlanes(Plane* planes) const; + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Computes the obb points. + * \param pts [out] 8 box points + * \return true if success + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + bool ComputePoints(Point* pts) const; + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Computes vertex normals. + * \param pts [out] 8 box points + * \return true if success + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + bool ComputeVertexNormals(Point* pts) const; + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Returns edges. + * \return 24 indices (12 edges) indexing the list returned by ComputePoints() + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + const udword* GetEdges() const; + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Returns local edge normals. + * \return edge normals in local space + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + const Point* GetLocalEdgeNormals() const; + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Returns world edge normal + * \param edge_index [in] 0 <= edge index < 12 + * \param world_normal [out] edge normal in world space + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + void ComputeWorldEdgeNormal(udword edge_index, Point& world_normal) const; + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Computes an LSS surrounding the OBB. + * \param lss [out] the LSS + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + void ComputeLSS(LSS& lss) const; + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Checks the OBB is inside another OBB. + * \param box [in] the other OBB + * \return TRUE if we're inside the other box + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + BOOL IsInside(const OBB& box) const; + + inline_ const Point& GetCenter() const { return mCenter; } + inline_ const Point& GetExtents() const { return mExtents; } + inline_ const Matrix3x3& GetRot() const { return mRot; } + + inline_ void GetRotatedExtents(Matrix3x3& extents) const + { + extents = mRot; + extents.Scale(mExtents); + } + + Point mCenter; //!< B for Box + Point mExtents; //!< B for Bounding + Matrix3x3 mRot; //!< O for Oriented + + // Orientation is stored in row-major format, + // i.e. rows = eigen vectors of the covariance matrix + }; + +#endif // __ICEOBB_H__ diff --git a/libs/ode-0.16.1/OPCODE/Ice/IcePairs.h b/libs/ode-0.16.1/OPCODE/Ice/IcePairs.h new file mode 100644 index 0000000..2c09b92 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IcePairs.h @@ -0,0 +1,45 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains a simple pair class. + * \file IcePairs.h + * \author Pierre Terdiman + * \date January, 13, 2003 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __ICEPAIRS_H__ +#define __ICEPAIRS_H__ + + //! A generic couple structure + struct ICECORE_API Pair + { + inline_ Pair() {} + inline_ Pair(udword i0, udword i1) : id0(i0), id1(i1) {} + + udword id0; //!< First index of the pair + udword id1; //!< Second index of the pair + }; + + class ICECORE_API Pairs : private Container + { + public: + // Constructor / Destructor + Pairs() {} + ~Pairs() {} + + inline_ udword GetNbPairs() const { return GetNbEntries()>>1; } + inline_ const Pair* GetPairs() const { return (const Pair*)GetEntries(); } + inline_ const Pair* GetPair(udword i) const { return (const Pair*)&GetEntries()[i+i]; } + + inline_ BOOL HasPairs() const { return IsNotEmpty(); } + + inline_ void ResetPairs() { Reset(); } + inline_ void DeleteLastPair() { DeleteLastEntry(); DeleteLastEntry(); } + + inline_ void AddPair(const Pair& p) { Add(p.id0).Add(p.id1); } + inline_ void AddPair(udword id0, udword id1) { Add(id0).Add(id1); } + }; + +#endif // __ICEPAIRS_H__ diff --git a/libs/ode-0.16.1/OPCODE/Ice/IcePlane.cpp b/libs/ode-0.16.1/OPCODE/Ice/IcePlane.cpp new file mode 100644 index 0000000..394b31b --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IcePlane.cpp @@ -0,0 +1,45 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for planes. + * \file IcePlane.cpp + * \author Pierre Terdiman + * \date April, 4, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Plane class. + * \class Plane + * \author Pierre Terdiman + * \version 1.0 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace IceMaths; + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the plane equation from 3 points. + * \param p0 [in] first point + * \param p1 [in] second point + * \param p2 [in] third point + * \return Self-reference + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +Plane& Plane::Set(const Point& p0, const Point& p1, const Point& p2) +{ + Point Edge0 = p1 - p0; + Point Edge1 = p2 - p0; + + n = Edge0 ^ Edge1; + n.Normalize(); + + d = -(p0 | n); + + return *this; +} diff --git a/libs/ode-0.16.1/OPCODE/Ice/IcePlane.h b/libs/ode-0.16.1/OPCODE/Ice/IcePlane.h new file mode 100644 index 0000000..4d47081 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IcePlane.h @@ -0,0 +1,113 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for planes. + * \file IcePlane.h + * \author Pierre Terdiman + * \date April, 4, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __ICEPLANE_H__ +#define __ICEPLANE_H__ + + #define PLANE_EPSILON (1.0e-7f) + + class ICEMATHS_API Plane + { + public: + //! Constructor + inline_ Plane() { } + //! Constructor from a normal and a distance + inline_ Plane(float nx, float ny, float nz, float d) { Set(nx, ny, nz, d); } + //! Constructor from a point on the plane and a normal + inline_ Plane(const Point& p, const Point& n) { Set(p, n); } + //! Constructor from three points + inline_ Plane(const Point& p0, const Point& p1, const Point& p2) { Set(p0, p1, p2); } + //! Constructor from a normal and a distance + inline_ Plane(const Point& _n, float _d) { n = _n; d = _d; } + //! Copy constructor + inline_ Plane(const Plane& plane) : n(plane.n), d(plane.d) { } + //! Destructor + inline_ ~Plane() { } + + inline_ Plane& Zero() { n.Zero(); d = 0.0f; return *this; } + inline_ Plane& Set(float nx, float ny, float nz, float _d) { n.Set(nx, ny, nz); d = _d; return *this; } + inline_ Plane& Set(const Point& p, const Point& _n) { n = _n; d = - p | _n; return *this; } + Plane& Set(const Point& p0, const Point& p1, const Point& p2); + + inline_ float Distance(const Point& p) const { return (p | n) + d; } + inline_ bool Belongs(const Point& p) const { return fabsf(Distance(p)) < PLANE_EPSILON; } + + inline_ void Normalize() + { + float Denom = 1.0f / n.Magnitude(); + n.x *= Denom; + n.y *= Denom; + n.z *= Denom; + d *= Denom; + } + public: + // Members + Point n; //!< The normal to the plane + float d; //!< The distance from the origin + + // Cast operators + inline_ operator Point() const { return n; } + inline_ operator HPoint() const { return HPoint(n, d); } + + // Arithmetic operators + inline_ Plane operator*(const Matrix4x4& m) const + { + // Old code from Irion. Kept for reference. + Plane Ret(*this); + return Ret *= m; + } + + inline_ Plane& operator*=(const Matrix4x4& m) + { + // Old code from Irion. Kept for reference. + Point n2 = HPoint(n, 0.0f) * m; + d = -((Point) (HPoint( -d*n, 1.0f ) * m) | n2); + n = n2; + return *this; + } + }; + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Transforms a plane by a 4x4 matrix. Same as Plane * Matrix4x4 operator, but faster. + * \param transformed [out] transformed plane + * \param plane [in] source plane + * \param transform [in] transform matrix + * \warning the plane normal must be unit-length + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void TransformPlane(Plane& transformed, const Plane& plane, const Matrix4x4& transform) + { + // Rotate the normal using the rotation part of the 4x4 matrix + transformed.n = plane.n * Matrix3x3(transform); + + // Compute new d + transformed.d = plane.d - (Point(transform.GetTrans())|transformed.n); + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Transforms a plane by a 4x4 matrix. Same as Plane * Matrix4x4 operator, but faster. + * \param plane [in/out] source plane (transformed on return) + * \param transform [in] transform matrix + * \warning the plane normal must be unit-length + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void TransformPlane(Plane& plane, const Matrix4x4& transform) + { + // Rotate the normal using the rotation part of the 4x4 matrix + plane.n *= Matrix3x3(transform); + + // Compute new d + plane.d -= Point(transform.GetTrans())|plane.n; + } + +#endif // __ICEPLANE_H__ diff --git a/libs/ode-0.16.1/OPCODE/Ice/IcePoint.cpp b/libs/ode-0.16.1/OPCODE/Ice/IcePoint.cpp new file mode 100644 index 0000000..428908a --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IcePoint.cpp @@ -0,0 +1,191 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for 3D vectors. + * \file IcePoint.cpp + * \author Pierre Terdiman + * \date April, 4, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * 3D point. + * + * The name is "Point" instead of "Vector" since a vector is N-dimensional, whereas a point is an implicit "vector of dimension 3". + * So the choice was between "Point" and "Vector3", the first one looked better (IMHO). + * + * Some people, then, use a typedef to handle both points & vectors using the same class: typedef Point Vector3; + * This is bad since it opens the door to a lot of confusion while reading the code. I know it may sounds weird but check this out: + * + * \code + * Point P0,P1 = some 3D points; + * Point Delta = P1 - P0; + * \endcode + * + * This compiles fine, although you should have written: + * + * \code + * Point P0,P1 = some 3D points; + * Vector3 Delta = P1 - P0; + * \endcode + * + * Subtle things like this are not caught at compile-time, and when you find one in the code, you never know whether it's a mistake + * from the author or something you don't get. + * + * One way to handle it at compile-time would be to use different classes for Point & Vector3, only overloading operator "-" for vectors. + * But then, you get a lot of redundant code in thoses classes, and basically it's really a lot of useless work. + * + * Another way would be to use homogeneous points: w=1 for points, w=0 for vectors. That's why the HPoint class exists. Now, to store + * your model's vertices and in most cases, you really want to use Points to save ram. + * + * \class Point + * \author Pierre Terdiman + * \version 1.0 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace IceMaths; + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Creates a positive unit random vector. + * \return Self-reference + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +Point& Point::PositiveUnitRandomVector() +{ + x = UnitRandomFloat(); + y = UnitRandomFloat(); + z = UnitRandomFloat(); + Normalize(); + return *this; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Creates a unit random vector. + * \return Self-reference + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +Point& Point::UnitRandomVector() +{ + x = UnitRandomFloat() - 0.5f; + y = UnitRandomFloat() - 0.5f; + z = UnitRandomFloat() - 0.5f; + Normalize(); + return *this; +} + +// Cast operator +// WARNING: not inlined +Point::operator HPoint() const { return HPoint(x, y, z, 0.0f); } + +Point& Point::Refract(const Point& eye, const Point& n, float refractindex, Point& refracted) +{ + // Point EyePt = eye position + // Point p = current vertex + // Point n = vertex normal + // Point rv = refracted vector + // Eye vector - doesn't need to be normalized + Point Env; + Env.x = eye.x - x; + Env.y = eye.y - y; + Env.z = eye.z - z; + + float NDotE = n|Env; + float NDotN = n|n; + NDotE /= refractindex; + + // Refracted vector + refracted = n*NDotE - Env*NDotN; + + return *this; +} + +Point& Point::ProjectToPlane(const Plane& p) +{ + *this-= (p.d + (*this|p.n))*p.n; + return *this; +} + +void Point::ProjectToScreen(float halfrenderwidth, float halfrenderheight, const Matrix4x4& mat, HPoint& projected) const +{ + projected = HPoint(x, y, z, 1.0f) * mat; + projected.w = 1.0f / projected.w; + + projected.x*=projected.w; + projected.y*=projected.w; + projected.z*=projected.w; + + projected.x *= halfrenderwidth; projected.x += halfrenderwidth; + projected.y *= -halfrenderheight; projected.y += halfrenderheight; +} + +void Point::SetNotUsed() +{ + // We use a particular integer pattern : 0xffffffff everywhere. This is a NAN. + x = y = z = FR(0xffffffff); +} + +BOOL Point::IsNotUsed() const +{ + if(IR(x)!=0xffffffff) return FALSE; + if(IR(y)!=0xffffffff) return FALSE; + if(IR(z)!=0xffffffff) return FALSE; + return TRUE; +} + +Point& Point::Mult(const Matrix3x3& mat, const Point& a) +{ + x = a.x * mat.m[0][0] + a.y * mat.m[0][1] + a.z * mat.m[0][2]; + y = a.x * mat.m[1][0] + a.y * mat.m[1][1] + a.z * mat.m[1][2]; + z = a.x * mat.m[2][0] + a.y * mat.m[2][1] + a.z * mat.m[2][2]; + return *this; +} + +Point& Point::Mult2(const Matrix3x3& mat1, const Point& a1, const Matrix3x3& mat2, const Point& a2) +{ + x = a1.x * mat1.m[0][0] + a1.y * mat1.m[0][1] + a1.z * mat1.m[0][2] + a2.x * mat2.m[0][0] + a2.y * mat2.m[0][1] + a2.z * mat2.m[0][2]; + y = a1.x * mat1.m[1][0] + a1.y * mat1.m[1][1] + a1.z * mat1.m[1][2] + a2.x * mat2.m[1][0] + a2.y * mat2.m[1][1] + a2.z * mat2.m[1][2]; + z = a1.x * mat1.m[2][0] + a1.y * mat1.m[2][1] + a1.z * mat1.m[2][2] + a2.x * mat2.m[2][0] + a2.y * mat2.m[2][1] + a2.z * mat2.m[2][2]; + return *this; +} + +Point& Point::Mac(const Matrix3x3& mat, const Point& a) +{ + x += a.x * mat.m[0][0] + a.y * mat.m[0][1] + a.z * mat.m[0][2]; + y += a.x * mat.m[1][0] + a.y * mat.m[1][1] + a.z * mat.m[1][2]; + z += a.x * mat.m[2][0] + a.y * mat.m[2][1] + a.z * mat.m[2][2]; + return *this; +} + +Point& Point::TransMult(const Matrix3x3& mat, const Point& a) +{ + x = a.x * mat.m[0][0] + a.y * mat.m[1][0] + a.z * mat.m[2][0]; + y = a.x * mat.m[0][1] + a.y * mat.m[1][1] + a.z * mat.m[2][1]; + z = a.x * mat.m[0][2] + a.y * mat.m[1][2] + a.z * mat.m[2][2]; + return *this; +} + +Point& Point::Transform(const Point& r, const Matrix3x3& rotpos, const Point& linpos) +{ + x = r.x * rotpos.m[0][0] + r.y * rotpos.m[0][1] + r.z * rotpos.m[0][2] + linpos.x; + y = r.x * rotpos.m[1][0] + r.y * rotpos.m[1][1] + r.z * rotpos.m[1][2] + linpos.y; + z = r.x * rotpos.m[2][0] + r.y * rotpos.m[2][1] + r.z * rotpos.m[2][2] + linpos.z; + return *this; +} + +Point& Point::InvTransform(const Point& r, const Matrix3x3& rotpos, const Point& linpos) +{ + float sx = r.x - linpos.x; + float sy = r.y - linpos.y; + float sz = r.z - linpos.z; + x = sx * rotpos.m[0][0] + sy * rotpos.m[1][0] + sz * rotpos.m[2][0]; + y = sx * rotpos.m[0][1] + sy * rotpos.m[1][1] + sz * rotpos.m[2][1]; + z = sx * rotpos.m[0][2] + sy * rotpos.m[1][2] + sz * rotpos.m[2][2]; + return *this; +} diff --git a/libs/ode-0.16.1/OPCODE/Ice/IcePoint.h b/libs/ode-0.16.1/OPCODE/Ice/IcePoint.h new file mode 100644 index 0000000..7c8a931 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IcePoint.h @@ -0,0 +1,530 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for 3D vectors. + * \file IcePoint.h + * \author Pierre Terdiman + * \date April, 4, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __ICEPOINT_H__ +#define __ICEPOINT_H__ + + // Forward declarations + class HPoint; + class Plane; + class Matrix3x3; + class Matrix4x4; + + #define CROSS2D(a, b) (a.x*b.y - b.x*a.y) + + const float EPSILON2 = 1.0e-20f; + + class ICEMATHS_API Point + { + public: + + //! Empty constructor + inline_ Point() {} + //! Constructor from a single float +// inline_ Point(float val) : x(val), y(val), z(val) {} +// Removed since it introduced the nasty "Point T = *Matrix4x4.GetTrans();" bug....... + //! Constructor from floats + template + inline_ Point(toffsetfloat xx, toffsetfloat yy, toffsetfloat zz) : x((float)xx), y((float)yy), z((float)zz) {} + //! Constructor from array + inline_ Point(const float f[3]) : x(f[X]), y(f[Y]), z(f[Z]) {} + //! Copy constructor + inline_ Point(const Point& p) : x(p.x), y(p.y), z(p.z) {} + //! Destructor + inline_ ~Point() {} + + //! Clears the vector + inline_ Point& Zero() { x = y = z = 0.0f; return *this; } + + //! + infinity + inline_ Point& SetPlusInfinity() { x = y = z = MAX_FLOAT; return *this; } + //! - infinity + inline_ Point& SetMinusInfinity() { x = y = z = MIN_FLOAT; return *this; } + + //! Sets positive unit random vector + Point& PositiveUnitRandomVector(); + //! Sets unit random vector + Point& UnitRandomVector(); + + //! Assignment from values + template + inline_ Point& Set(toffsetfloat xx, toffsetfloat yy, toffsetfloat zz) { x = (float)xx; y = (float)yy; z = (float)zz; return *this; } + //! Assignment from array + inline_ Point& Set(const float f[3]) { x = f[X]; y = f[Y]; z = f[Z]; return *this; } + //! Assignment from another point + inline_ Point& Set(const Point& src) { x = src.x; y = src.y; z = src.z; return *this; } + + //! Adds a vector + inline_ Point& Add(const Point& p) { x += p.x; y += p.y; z += p.z; return *this; } + //! Adds a vector + inline_ Point& Add(float xx, float yy, float zz) { x += xx; y += yy; z += zz; return *this; } + //! Adds a vector + inline_ Point& Add(const float f[3]) { x += f[X]; y += f[Y]; z += f[Z]; return *this; } + //! Adds vectors + inline_ Point& Add(const Point& p, const Point& q) { x = p.x+q.x; y = p.y+q.y; z = p.z+q.z; return *this; } + + //! Subtracts a vector + inline_ Point& Sub(const Point& p) { x -= p.x; y -= p.y; z -= p.z; return *this; } + //! Subtracts a vector + inline_ Point& Sub(float xx, float yy, float zz) { x -= xx; y -= yy; z -= zz; return *this; } + //! Subtracts a vector + inline_ Point& Sub(const float f[3]) { x -= f[X]; y -= f[Y]; z -= f[Z]; return *this; } + //! Subtracts vectors + inline_ Point& Sub(const Point& p, const Point& q) { x = p.x-q.x; y = p.y-q.y; z = p.z-q.z; return *this; } + + //! this = -this + inline_ Point& Neg() { x = -x; y = -y; z = -z; return *this; } + //! this = -a + inline_ Point& Neg(const Point& a) { x = -a.x; y = -a.y; z = -a.z; return *this; } + + //! Multiplies by a scalar + inline_ Point& Mult(float s) { x *= s; y *= s; z *= s; return *this; } + + //! this = a * scalar + inline_ Point& Mult(const Point& a, float scalar) + { + x = a.x * scalar; + y = a.y * scalar; + z = a.z * scalar; + return *this; + } + + //! this = a + b * scalar + inline_ Point& Mac(const Point& a, const Point& b, float scalar) + { + x = a.x + b.x * scalar; + y = a.y + b.y * scalar; + z = a.z + b.z * scalar; + return *this; + } + + //! this = this + a * scalar + inline_ Point& Mac(const Point& a, float scalar) + { + x += a.x * scalar; + y += a.y * scalar; + z += a.z * scalar; + return *this; + } + + //! this = a - b * scalar + inline_ Point& Msc(const Point& a, const Point& b, float scalar) + { + x = a.x - b.x * scalar; + y = a.y - b.y * scalar; + z = a.z - b.z * scalar; + return *this; + } + + //! this = this - a * scalar + inline_ Point& Msc(const Point& a, float scalar) + { + x -= a.x * scalar; + y -= a.y * scalar; + z -= a.z * scalar; + return *this; + } + + //! this = a + b * scalarb + c * scalarc + inline_ Point& Mac2(const Point& a, const Point& b, float scalarb, const Point& c, float scalarc) + { + x = a.x + b.x * scalarb + c.x * scalarc; + y = a.y + b.y * scalarb + c.y * scalarc; + z = a.z + b.z * scalarb + c.z * scalarc; + return *this; + } + + //! this = a - b * scalarb - c * scalarc + inline_ Point& Msc2(const Point& a, const Point& b, float scalarb, const Point& c, float scalarc) + { + x = a.x - b.x * scalarb - c.x * scalarc; + y = a.y - b.y * scalarb - c.y * scalarc; + z = a.z - b.z * scalarb - c.z * scalarc; + return *this; + } + + //! this = mat * a + inline_ Point& Mult(const Matrix3x3& mat, const Point& a); + + //! this = mat1 * a1 + mat2 * a2 + inline_ Point& Mult2(const Matrix3x3& mat1, const Point& a1, const Matrix3x3& mat2, const Point& a2); + + //! this = this + mat * a + inline_ Point& Mac(const Matrix3x3& mat, const Point& a); + + //! this = transpose(mat) * a + inline_ Point& TransMult(const Matrix3x3& mat, const Point& a); + + //! Linear interpolate between two vectors: this = a + t * (b - a) + inline_ Point& Lerp(const Point& a, const Point& b, float t) + { + x = a.x + t * (b.x - a.x); + y = a.y + t * (b.y - a.y); + z = a.z + t * (b.z - a.z); + return *this; + } + + //! Hermite interpolate between p1 and p2. p0 and p3 are used for finding gradient at p1 and p2. + //! this = p0 * (2t^2 - t^3 - t)/2 + //! + p1 * (3t^3 - 5t^2 + 2)/2 + //! + p2 * (4t^2 - 3t^3 + t)/2 + //! + p3 * (t^3 - t^2)/2 + inline_ Point& Herp(const Point& p0, const Point& p1, const Point& p2, const Point& p3, float t) + { + float t2 = t * t; + float t3 = t2 * t; + float kp0 = (2.0f * t2 - t3 - t) * 0.5f; + float kp1 = (3.0f * t3 - 5.0f * t2 + 2.0f) * 0.5f; + float kp2 = (4.0f * t2 - 3.0f * t3 + t) * 0.5f; + float kp3 = (t3 - t2) * 0.5f; + x = p0.x * kp0 + p1.x * kp1 + p2.x * kp2 + p3.x * kp3; + y = p0.y * kp0 + p1.y * kp1 + p2.y * kp2 + p3.y * kp3; + z = p0.z * kp0 + p1.z * kp1 + p2.z * kp2 + p3.z * kp3; + return *this; + } + + //! this = rotpos * r + linpos + inline_ Point& Transform(const Point& r, const Matrix3x3& rotpos, const Point& linpos); + + //! this = trans(rotpos) * (r - linpos) + inline_ Point& InvTransform(const Point& r, const Matrix3x3& rotpos, const Point& linpos); + + //! Returns MIN(x, y, z); + inline_ float Min() const { return MIN(x, MIN(y, z)); } + //! Returns MAX(x, y, z); + inline_ float Max() const { return MAX(x, MAX(y, z)); } + //! Sets each element to be componentwise minimum + inline_ Point& Min(const Point& p) { x = MIN(x, p.x); y = MIN(y, p.y); z = MIN(z, p.z); return *this; } + //! Sets each element to be componentwise maximum + inline_ Point& Max(const Point& p) { x = MAX(x, p.x); y = MAX(y, p.y); z = MAX(z, p.z); return *this; } + + //! Clamps each element + inline_ Point& Clamp(float min, float max) + { + if(xmax) x=max; + if(ymax) y=max; + if(zmax) z=max; + return *this; + } + + //! Computes square magnitude + inline_ float SquareMagnitude() const { return x*x + y*y + z*z; } + //! Computes magnitude + inline_ float Magnitude() const { return sqrtf(x*x + y*y + z*z); } + //! Computes volume + inline_ float Volume() const { return x * y * z; } + + //! Checks the point is near zero + inline_ bool ApproxZero() const { return SquareMagnitude() < EPSILON2; } + + //! Tests for exact zero vector + inline_ BOOL IsZero() const + { + if(IR(x) || IR(y) || IR(z)) return FALSE; + return TRUE; + } + + //! Checks point validity + inline_ BOOL IsValid() const + { + if(!IsValidFloat(x)) return FALSE; + if(!IsValidFloat(y)) return FALSE; + if(!IsValidFloat(z)) return FALSE; + return TRUE; + } + + //! Slighty moves the point + void Tweak(udword coord_mask, udword tweak_mask) + { + if(coord_mask&1) { udword Dummy = IR(x); Dummy^=tweak_mask; x = FR(Dummy); } + if(coord_mask&2) { udword Dummy = IR(y); Dummy^=tweak_mask; y = FR(Dummy); } + if(coord_mask&4) { udword Dummy = IR(z); Dummy^=tweak_mask; z = FR(Dummy); } + } + + #define TWEAKMASK 0x3fffff + #define TWEAKNOTMASK ~TWEAKMASK + //! Slighty moves the point out + inline_ void TweakBigger() + { + udword Dummy = (IR(x)&TWEAKNOTMASK); if(!IS_NEGATIVE_FLOAT(x)) Dummy+=TWEAKMASK+1; x = FR(Dummy); + Dummy = (IR(y)&TWEAKNOTMASK); if(!IS_NEGATIVE_FLOAT(y)) Dummy+=TWEAKMASK+1; y = FR(Dummy); + Dummy = (IR(z)&TWEAKNOTMASK); if(!IS_NEGATIVE_FLOAT(z)) Dummy+=TWEAKMASK+1; z = FR(Dummy); + } + + //! Slighty moves the point in + inline_ void TweakSmaller() + { + udword Dummy = (IR(x)&TWEAKNOTMASK); if(IS_NEGATIVE_FLOAT(x)) Dummy+=TWEAKMASK+1; x = FR(Dummy); + Dummy = (IR(y)&TWEAKNOTMASK); if(IS_NEGATIVE_FLOAT(y)) Dummy+=TWEAKMASK+1; y = FR(Dummy); + Dummy = (IR(z)&TWEAKNOTMASK); if(IS_NEGATIVE_FLOAT(z)) Dummy+=TWEAKMASK+1; z = FR(Dummy); + } + + //! Normalizes the vector + inline_ Point& Normalize() + { + float M = x*x + y*y + z*z; + if(M) + { + M = 1.0f / sqrtf(M); + x *= M; + y *= M; + z *= M; + } + return *this; + } + + //! Sets vector length + inline_ Point& SetLength(float length) + { + float NewLength = length / Magnitude(); + x *= NewLength; + y *= NewLength; + z *= NewLength; + return *this; + } + + //! Clamps vector length + inline_ Point& ClampLength(float limit_length) + { + if(limit_length>=0.0f) // Magnitude must be positive + { + float CurrentSquareLength = SquareMagnitude(); + + if(CurrentSquareLength > limit_length * limit_length) + { + float Coeff = limit_length / sqrtf(CurrentSquareLength); + x *= Coeff; + y *= Coeff; + z *= Coeff; + } + } + return *this; + } + + //! Computes distance to another point + inline_ float Distance(const Point& b) const + { + return sqrtf((x - b.x)*(x - b.x) + (y - b.y)*(y - b.y) + (z - b.z)*(z - b.z)); + } + + //! Computes square distance to another point + inline_ float SquareDistance(const Point& b) const + { + return ((x - b.x)*(x - b.x) + (y - b.y)*(y - b.y) + (z - b.z)*(z - b.z)); + } + + //! Dot product dp = this|a + inline_ float Dot(const Point& p) const { return p.x * x + p.y * y + p.z * z; } + + //! Cross product this = a x b + inline_ Point& Cross(const Point& a, const Point& b) + { + x = a.y * b.z - a.z * b.y; + y = a.z * b.x - a.x * b.z; + z = a.x * b.y - a.y * b.x; + return *this; + } + + //! Vector code ( bitmask = sign(z) | sign(y) | sign(x) ) + inline_ udword VectorCode() const + { + return (IR(x)>>31) | ((IR(y)&SIGN_BITMASK)>>30) | ((IR(z)&SIGN_BITMASK)>>29); + } + + //! Returns largest axis + inline_ PointComponent LargestAxis() const + { + const float* Vals = &x; + PointComponent m = X; + if(Vals[Y] > Vals[m]) m = Y; + if(Vals[Z] > Vals[m]) m = Z; + return m; + } + + //! Returns closest axis + inline_ PointComponent ClosestAxis() const + { + const float* Vals = &x; + PointComponent m = X; + if(AIR(Vals[Y]) > AIR(Vals[m])) m = Y; + if(AIR(Vals[Z]) > AIR(Vals[m])) m = Z; + return m; + } + + //! Returns smallest axis + inline_ PointComponent SmallestAxis() const + { + const float* Vals = &x; + PointComponent m = X; + if(Vals[Y] < Vals[m]) m = Y; + if(Vals[Z] < Vals[m]) m = Z; + return m; + } + + //! Refracts the point + Point& Refract(const Point& eye, const Point& n, float refractindex, Point& refracted); + + //! Projects the point onto a plane + Point& ProjectToPlane(const Plane& p); + + //! Projects the point onto the screen + void ProjectToScreen(float halfrenderwidth, float halfrenderheight, const Matrix4x4& mat, HPoint& projected) const; + + //! Unfolds the point onto a plane according to edge(a,b) + Point& Unfold(Plane& p, Point& a, Point& b); + + //! Hash function from Ville Miettinen + inline_ udword GetHashValue() const + { + const udword* h = (const udword*)(this); + udword f = (h[0]+h[1]*11-(h[2]*17)) & 0x7fffffff; // avoid problems with +-0 + return (f>>22)^(f>>12)^(f); + } + + //! Stuff magic values in the point, marking it as explicitely not used. + void SetNotUsed(); + //! Checks the point is marked as not used + BOOL IsNotUsed() const; + + // Arithmetic operators + + //! Unary operator for Point Negate = - Point + inline_ Point operator-() const { return Point(-x, -y, -z); } + + //! Operator for Point Plus = Point + Point. + inline_ Point operator+(const Point& p) const { return Point(x + p.x, y + p.y, z + p.z); } + //! Operator for Point Minus = Point - Point. + inline_ Point operator-(const Point& p) const { return Point(x - p.x, y - p.y, z - p.z); } + + //! Operator for Point Mul = Point * Point. + inline_ Point operator*(const Point& p) const { return Point(x * p.x, y * p.y, z * p.z); } + //! Operator for Point Scale = Point * float. + inline_ Point operator*(float s) const { return Point(x * s, y * s, z * s ); } + //! Operator for Point Scale = float * Point. + inline_ friend Point operator*(float s, const Point& p) { return Point(s * p.x, s * p.y, s * p.z); } + + //! Operator for Point Div = Point / Point. + inline_ Point operator/(const Point& p) const { return Point(x / p.x, y / p.y, z / p.z); } + //! Operator for Point Scale = Point / float. + inline_ Point operator/(float s) const { s = 1.0f / s; return Point(x * s, y * s, z * s); } + //! Operator for Point Scale = float / Point. + inline_ friend Point operator/(float s, const Point& p) { return Point(s / p.x, s / p.y, s / p.z); } + + //! Operator for float DotProd = Point | Point. + inline_ float operator|(const Point& p) const { return x*p.x + y*p.y + z*p.z; } + //! Operator for Point VecProd = Point ^ Point. + inline_ Point operator^(const Point& p) const + { + return Point( + y * p.z - z * p.y, + z * p.x - x * p.z, + x * p.y - y * p.x ); + } + + //! Operator for Point += Point. + inline_ Point& operator+=(const Point& p) { x += p.x; y += p.y; z += p.z; return *this; } + //! Operator for Point += float. + inline_ Point& operator+=(float s) { x += s; y += s; z += s; return *this; } + + //! Operator for Point -= Point. + inline_ Point& operator-=(const Point& p) { x -= p.x; y -= p.y; z -= p.z; return *this; } + //! Operator for Point -= float. + inline_ Point& operator-=(float s) { x -= s; y -= s; z -= s; return *this; } + + //! Operator for Point *= Point. + inline_ Point& operator*=(const Point& p) { x *= p.x; y *= p.y; z *= p.z; return *this; } + //! Operator for Point *= float. + inline_ Point& operator*=(float s) { x *= s; y *= s; z *= s; return *this; } + + //! Operator for Point /= Point. + inline_ Point& operator/=(const Point& p) { x /= p.x; y /= p.y; z /= p.z; return *this; } + //! Operator for Point /= float. + inline_ Point& operator/=(float s) { s = 1.0f/s; x *= s; y *= s; z *= s; return *this; } + + // Logical operators + + //! Operator for "if(Point==Point)" + inline_ bool operator==(const Point& p) const { return ( (IR(x)==IR(p.x))&&(IR(y)==IR(p.y))&&(IR(z)==IR(p.z))); } + //! Operator for "if(Point!=Point)" + inline_ bool operator!=(const Point& p) const { return ( (IR(x)!=IR(p.x))||(IR(y)!=IR(p.y))||(IR(z)!=IR(p.z))); } + + // Arithmetic operators + + //! Operator for Point Mul = Point * Matrix3x3. + inline_ Point operator*(const Matrix3x3& mat) const + { + class ShadowMatrix3x3{ public: float m[3][3]; }; // To allow inlining + const ShadowMatrix3x3* Mat = (const ShadowMatrix3x3*)&mat; + + return Point( + x * Mat->m[0][0] + y * Mat->m[1][0] + z * Mat->m[2][0], + x * Mat->m[0][1] + y * Mat->m[1][1] + z * Mat->m[2][1], + x * Mat->m[0][2] + y * Mat->m[1][2] + z * Mat->m[2][2] ); + } + + //! Operator for Point Mul = Point * Matrix4x4. + inline_ Point operator*(const Matrix4x4& mat) const + { + class ShadowMatrix4x4{ public: float m[4][4]; }; // To allow inlining + const ShadowMatrix4x4* Mat = (const ShadowMatrix4x4*)&mat; + + return Point( + x * Mat->m[0][0] + y * Mat->m[1][0] + z * Mat->m[2][0] + Mat->m[3][0], + x * Mat->m[0][1] + y * Mat->m[1][1] + z * Mat->m[2][1] + Mat->m[3][1], + x * Mat->m[0][2] + y * Mat->m[1][2] + z * Mat->m[2][2] + Mat->m[3][2]); + } + + //! Operator for Point *= Matrix3x3. + inline_ Point& operator*=(const Matrix3x3& mat) + { + class ShadowMatrix3x3{ public: float m[3][3]; }; // To allow inlining + const ShadowMatrix3x3* Mat = (const ShadowMatrix3x3*)&mat; + + float xp = x * Mat->m[0][0] + y * Mat->m[1][0] + z * Mat->m[2][0]; + float yp = x * Mat->m[0][1] + y * Mat->m[1][1] + z * Mat->m[2][1]; + float zp = x * Mat->m[0][2] + y * Mat->m[1][2] + z * Mat->m[2][2]; + + x = xp; y = yp; z = zp; + + return *this; + } + + //! Operator for Point *= Matrix4x4. + inline_ Point& operator*=(const Matrix4x4& mat) + { + class ShadowMatrix4x4{ public: float m[4][4]; }; // To allow inlining + const ShadowMatrix4x4* Mat = (const ShadowMatrix4x4*)&mat; + + float xp = x * Mat->m[0][0] + y * Mat->m[1][0] + z * Mat->m[2][0] + Mat->m[3][0]; + float yp = x * Mat->m[0][1] + y * Mat->m[1][1] + z * Mat->m[2][1] + Mat->m[3][1]; + float zp = x * Mat->m[0][2] + y * Mat->m[1][2] + z * Mat->m[2][2] + Mat->m[3][2]; + + x = xp; y = yp; z = zp; + + return *this; + } + + // Cast operators + + //! Cast a Point to a HPoint. w is set to zero. + operator HPoint() const; + + inline_ operator const float*() const { return &x; } + inline_ operator float*() { return &x; } + + public: + float x, y, z; + }; + + FUNCTION ICEMATHS_API void Normalize1(Point& a); + FUNCTION ICEMATHS_API void Normalize2(Point& a); + +#endif //__ICEPOINT_H__ diff --git a/libs/ode-0.16.1/OPCODE/Ice/IcePreprocessor.h b/libs/ode-0.16.1/OPCODE/Ice/IcePreprocessor.h new file mode 100644 index 0000000..dbeca38 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IcePreprocessor.h @@ -0,0 +1,132 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains preprocessor stuff. This should be the first included header. + * \file IcePreprocessor.h + * \author Pierre Terdiman + * \date April, 4, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __ICEPREPROCESSOR_H__ +#define __ICEPREPROCESSOR_H__ + + // Check platform + #if defined( _WIN32 ) || defined( WIN32 ) + // #pragma message("Compiling on Windows...") + #define PLATFORM_WINDOWS + #else + // don't issue pragmas on unknown platforms + // #pragma message("Compiling on unknown platform...") + #endif + + // Check compiler + #if defined(_MSC_VER) + // #pragma message("Compiling with VC++...") + #define COMPILER_VISUAL_CPP + #else + // don't issue pragmas on unknown platforms + // #pragma message("Compiling with unknown compiler...") + #endif + + // Check compiler options. If this file is included in user-apps, this + // shouldn't be needed, so that they can use what they like best. + #ifndef ICE_DONT_CHECK_COMPILER_OPTIONS + #ifdef COMPILER_VISUAL_CPP + #if defined(_CHAR_UNSIGNED) + #endif + + #if defined(_CPPRTTI) + #error Please disable RTTI... + #endif + + #if defined(_CPPUNWIND) + #error Please disable exceptions... + #endif + + #if defined(_MT) + // Multithreading + #endif + #endif + #endif + + // Check debug mode + #ifdef DEBUG // May be defined instead of _DEBUG. Let's fix it. + #ifndef _DEBUG + #define _DEBUG + #endif + #endif + + #ifdef _DEBUG + // Here you may define items for debug builds + #endif + + #ifndef THIS_FILE + #define THIS_FILE __FILE__ + #endif + + #ifndef ICE_NO_DLL + #ifdef ICECORE_EXPORTS + #define ICECORE_API __declspec(dllexport) + #else + #define ICECORE_API __declspec(dllimport) + #endif + #else + #define ICECORE_API + #endif + + // Don't override new/delete +// #define DEFAULT_NEWDELETE + #define DONT_TRACK_MEMORY_LEAKS + + #define FUNCTION extern "C" + + // Cosmetic stuff [mainly useful with multiple inheritance] + #define override(base_class) virtual + + // Our own inline keyword, so that: + // - we can switch to __forceinline to check it's really better or not + // - we can remove __forceinline if the compiler doesn't support it +// #define inline_ __forceinline +// #define inline_ inline + + // Contributed by Bruce Mitchener + #if defined(COMPILER_VISUAL_CPP) + #define inline_ __forceinline +// #define inline_ inline + #elif defined(__GNUC__) && __GNUC__ < 3 + #define inline_ inline + #elif defined(__GNUC__) + #define inline_ inline __attribute__ ((always_inline)) + #else + #define inline_ inline + #endif + + // Down the hatch +#ifdef _MSC_VER + #pragma inline_depth( 255 ) +#endif + + #ifdef COMPILER_VISUAL_CPP + #pragma intrinsic(memcmp) + #pragma intrinsic(memcpy) + #pragma intrinsic(memset) + #pragma intrinsic(strcat) + #pragma intrinsic(strcmp) + #pragma intrinsic(strcpy) + #pragma intrinsic(strlen) + #pragma intrinsic(abs) + #pragma intrinsic(labs) + #endif + + // ANSI compliance + #ifdef _DEBUG + // Remove painful warning in debug + inline_ bool __False__(){ return false; } + #define for if(__False__()){} else for + #else + #define for if(0){} else for + #endif + +#endif // __ICEPREPROCESSOR_H__ diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceRandom.cpp b/libs/ode-0.16.1/OPCODE/Ice/IceRandom.cpp new file mode 100644 index 0000000..cc63a04 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceRandom.cpp @@ -0,0 +1,35 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for random generators. + * \file IceRandom.cpp + * \author Pierre Terdiman + * \date August, 9, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace IceCore; + +void IceCore:: SRand(udword seed) +{ + srand(seed); +} + +udword IceCore::Rand() +{ + return rand(); +} + + +static BasicRandom gRandomGenerator(42); + +udword IceCore::GetRandomIndex(udword max_index) +{ + // We don't use rand() since it's limited to RAND_MAX + udword Index = gRandomGenerator.Randomize(); + return Index % max_index; +} + diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceRandom.h b/libs/ode-0.16.1/OPCODE/Ice/IceRandom.h new file mode 100644 index 0000000..3170b33 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceRandom.h @@ -0,0 +1,42 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for random generators. + * \file IceRandom.h + * \author Pierre Terdiman + * \date August, 9, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __ICERANDOM_H__ +#define __ICERANDOM_H__ + + FUNCTION ICECORE_API void SRand(udword seed); + FUNCTION ICECORE_API udword Rand(); + + //! Returns a unit random floating-point value + inline_ float UnitRandomFloat() { return float(Rand()) * ONE_OVER_RAND_MAX; } + + //! Returns a random index so that 0<= index < max_index + ICECORE_API udword GetRandomIndex(udword max_index); + + class ICECORE_API BasicRandom + { + public: + + //! Constructor + inline_ BasicRandom(udword seed=0) : mRnd(seed) {} + //! Destructor + inline_ ~BasicRandom() {} + + inline_ void SetSeed(udword seed) { mRnd = seed; } + inline_ udword GetCurrentValue() const { return mRnd; } + inline_ udword Randomize() { mRnd = mRnd * 2147001325 + 715136305; return mRnd; } + + private: + udword mRnd; + }; + +#endif // __ICERANDOM_H__ + diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceRay.cpp b/libs/ode-0.16.1/OPCODE/Ice/IceRay.cpp new file mode 100644 index 0000000..6cf0330 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceRay.cpp @@ -0,0 +1,84 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for rays. + * \file IceRay.cpp + * \author Pierre Terdiman + * \date April, 4, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Ray class. + * A ray is a half-line P(t) = mOrig + mDir * t, with 0 <= t <= +infinity + * \class Ray + * \author Pierre Terdiman + * \version 1.0 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/* + O = Origin = impact point + i = normalized vector along the x axis + j = normalized vector along the y axis = actually the normal vector in O + D = Direction vector, norm |D| = 1 + N = Projection of D on y axis, norm |N| = normal reaction + T = Projection of D on x axis, norm |T| = tangential reaction + R = Reflexion vector + + ^y + | + | + | + _ _ _| _ _ _ + * * *| + \ | / + \ |N / | + R\ | /D + \ | / | + \ | / + _________\|/______*_______>x + O T + + Let define theta = angle between D and N. Then cos(theta) = |N| / |D| = |N| since D is normalized. + + j|D = |j|*|D|*cos(theta) => |N| = j|D + + Then we simply have: + + D = N + T + + To compute tangential reaction : + + T = D - N + + To compute reflexion vector : + + R = N - T = N - (D-N) = 2*N - D +*/ + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace IceMaths; + +float Ray::SquareDistance(const Point& point, float* t) const +{ + Point Diff = point - mOrig; + float fT = Diff | mDir; + + if(fT<=0.0f) + { + fT = 0.0f; + } + else + { + fT /= mDir.SquareMagnitude(); + Diff -= fT*mDir; + } + + if(t) *t = fT; + + return Diff.SquareMagnitude(); +} diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceRay.h b/libs/ode-0.16.1/OPCODE/Ice/IceRay.h new file mode 100644 index 0000000..0268287 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceRay.h @@ -0,0 +1,98 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for rays. + * \file IceRay.h + * \author Pierre Terdiman + * \date April, 4, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __ICERAY_H__ +#define __ICERAY_H__ + + class ICEMATHS_API Ray + { + public: + //! Constructor + inline_ Ray() {} + //! Constructor + inline_ Ray(const Point& orig, const Point& dir) : mOrig(orig), mDir(dir) {} + //! Copy constructor + inline_ Ray(const Ray& ray) : mOrig(ray.mOrig), mDir(ray.mDir) {} + //! Destructor + inline_ ~Ray() {} + + float SquareDistance(const Point& point, float* t=null) const; + inline_ float Distance(const Point& point, float* t=null) const { return sqrtf(SquareDistance(point, t)); } + + Point mOrig; //!< Ray origin + Point mDir; //!< Normalized direction + }; + + inline_ void ComputeReflexionVector(Point& reflected, const Point& incoming_dir, const Point& outward_normal) + { + reflected = incoming_dir - outward_normal * 2.0f * (incoming_dir|outward_normal); + } + + inline_ void ComputeReflexionVector(Point& reflected, const Point& source, const Point& impact, const Point& normal) + { + Point V = impact - source; + reflected = V - normal * 2.0f * (V|normal); + } + + inline_ void DecomposeVector(Point& normal_compo, Point& tangent_compo, const Point& outward_dir, const Point& outward_normal) + { + normal_compo = outward_normal * (outward_dir|outward_normal); + tangent_compo = outward_dir - normal_compo; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Transforms a direction vector from world space to local space + * \param local_dir [out] direction vector in local space + * \param world_dir [in] direction vector in world space + * \param world [in] world transform + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void ComputeLocalDirection(Point& local_dir, const Point& world_dir, const Matrix4x4& world) + { + // Get world direction back in local space +// Matrix3x3 InvWorld = world; +// local_dir = InvWorld * world_dir; + local_dir = Matrix3x3(world) * world_dir; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Transforms a position vector from world space to local space + * \param local_pt [out] position vector in local space + * \param world_pt [in] position vector in world space + * \param world [in] world transform + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void ComputeLocalPoint(Point& local_pt, const Point& world_pt, const Matrix4x4& world) + { + // Get world vertex back in local space + Matrix4x4 InvWorld = world; + InvWorld.Invert(); + local_pt = world_pt * InvWorld; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Transforms a ray from world space to local space + * \param local_ray [out] ray in local space + * \param world_ray [in] ray in world space + * \param world [in] world transform + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void ComputeLocalRay(Ray& local_ray, const Ray& world_ray, const Matrix4x4& world) + { + // Get world ray back in local space + ComputeLocalDirection(local_ray.mDir, world_ray.mDir, world); + ComputeLocalPoint(local_ray.mOrig, world_ray.mOrig, world); + } + +#endif // __ICERAY_H__ diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceRevisitedRadix.cpp b/libs/ode-0.16.1/OPCODE/Ice/IceRevisitedRadix.cpp new file mode 100644 index 0000000..99a586f --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceRevisitedRadix.cpp @@ -0,0 +1,520 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains source code from the article "Radix Sort Revisited". + * \file IceRevisitedRadix.cpp + * \author Pierre Terdiman + * \date April, 4, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Revisited Radix Sort. + * This is my new radix routine: + * - it uses indices and doesn't recopy the values anymore, hence wasting less ram + * - it creates all the histograms in one run instead of four + * - it sorts words faster than dwords and bytes faster than words + * - it correctly sorts negative floating-point values by patching the offsets + * - it automatically takes advantage of temporal coherence + * - multiple keys support is a side effect of temporal coherence + * - it may be worth recoding in asm... (mainly to use FCOMI, FCMOV, etc) [it's probably memory-bound anyway] + * + * History: + * - 08.15.98: very first version + * - 04.04.00: recoded for the radix article + * - 12.xx.00: code lifting + * - 09.18.01: faster CHECK_PASS_VALIDITY thanks to Mark D. Shattuck (who provided other tips, not included here) + * - 10.11.01: added local ram support + * - 01.20.02: bugfix! In very particular cases the last pass was skipped in the float code-path, leading to incorrect sorting...... + * - 01.02.02: - "mIndices" renamed => "mRanks". That's a rank sorter after all. + * - ranks are not "reset" anymore, but implicit on first calls + * - 07.05.02: - offsets rewritten with one less indirection. + * - 11.03.02: - "bool" replaced with RadixHint enum + * + * \class RadixSort + * \author Pierre Terdiman + * \version 1.4 + * \date August, 15, 1998 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/* +To do: + - add an offset parameter between two input values (avoid some data recopy sometimes) + - unroll ? asm ? + - 11 bits trick & 3 passes as Michael did + - prefetch stuff the day I have a P3 + - make a version with 16-bits indices ? +*/ + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace IceCore; + +#define INVALIDATE_RANKS mCurrentSize|=0x80000000 +#define VALIDATE_RANKS mCurrentSize&=0x7fffffff +#define CURRENT_SIZE (mCurrentSize&0x7fffffff) +#define INVALID_RANKS (mCurrentSize&0x80000000) + +#define CHECK_RESIZE(n) \ + if(n!=mPreviousSize) \ + { \ + if(n>mCurrentSize) Resize(n); \ + else ResetRanks(); \ + mPreviousSize = n; \ + } + +#define CREATE_HISTOGRAMS(type, buffer) \ + /* Clear counters/histograms */ \ + ZeroMemory(mHistogram, 256*4*sizeof(udword)); \ + \ + /* Prepare to count */ \ + ubyte* p = (ubyte*)input; \ + ubyte* pe = &p[nb*4]; \ + udword* h0= &mHistogram[0]; /* Histogram for first pass (LSB) */ \ + udword* h1= &mHistogram[256]; /* Histogram for second pass */ \ + udword* h2= &mHistogram[512]; /* Histogram for third pass */ \ + udword* h3= &mHistogram[768]; /* Histogram for last pass (MSB) */ \ + \ + bool AlreadySorted = true; /* Optimism... */ \ + \ + if(INVALID_RANKS) \ + { \ + /* Prepare for temporal coherence */ \ + type* Running = (type*)buffer; \ + type PrevVal = *Running; \ + \ + while(p!=pe) \ + { \ + /* Read input buffer in previous sorted order */ \ + type Val = *Running++; \ + /* Check whether already sorted or not */ \ + if(ValCurSize) Resize(nb); + mCurrentSize = nb; + INVALIDATE_RANKS; + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Main sort routine. + * This one is for integer values. After the call, mRanks contains a list of indices in sorted order, i.e. in the order you may process your data. + * \param input [in] a list of integer values to sort + * \param nb [in] number of values to sort, must be < 2^31 + * \param hint [in] RADIX_SIGNED to handle negative values, RADIX_UNSIGNED if you know your input buffer only contains positive values + * \return Self-Reference + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +RadixSort& RadixSort::Sort(const udword* input, udword nb, RadixHint hint) +{ + // Checkings + if(!input || !nb || nb&0x80000000) return *this; + + // Stats + mTotalCalls++; + + // Resize lists if needed + CheckResize(nb); + +#ifdef RADIX_LOCAL_RAM + // Allocate histograms & offsets on the stack + udword mHistogram[256*4]; +// udword mOffset[256]; + udword* mLink[256]; +#endif + + // Create histograms (counters). Counters for all passes are created in one run. + // Pros: read input buffer once instead of four times + // Cons: mHistogram is 4Kb instead of 1Kb + // We must take care of signed/unsigned values for temporal coherence.... I just + // have 2 code paths even if just a single opcode changes. Self-modifying code, someone? + if(hint==RADIX_UNSIGNED) { CREATE_HISTOGRAMS(udword, input); } + else { CREATE_HISTOGRAMS(sdword, input); } + + // Compute #negative values involved if needed + udword NbNegativeValues = 0; + if(hint==RADIX_SIGNED) + { + // An efficient way to compute the number of negatives values we'll have to deal with is simply to sum the 128 + // last values of the last histogram. Last histogram because that's the one for the Most Significant Byte, + // responsible for the sign. 128 last values because the 128 first ones are related to positive numbers. + udword* h3= &mHistogram[768]; + for(udword i=128;i<256;i++) NbNegativeValues += h3[i]; // 768 for last histogram, 128 for negative part + } + + // Radix sort, j is the pass number (0=LSB, 3=MSB) + for(udword j=0;j<4;j++) + { + CHECK_PASS_VALIDITY(j); + + // Sometimes the fourth (negative) pass is skipped because all numbers are negative and the MSB is 0xFF (for example). This is + // not a problem, numbers are correctly sorted anyway. + if(PerformPass) + { + // Should we care about negative values? + if(j!=3 || hint==RADIX_UNSIGNED) + { + // Here we deal with positive values only + + // Create offsets +// mOffset[0] = 0; +// for(udword i=1;i<256;i++) mOffset[i] = mOffset[i-1] + CurCount[i-1]; + mLink[0] = mRanks2; + for(udword i=1;i<256;i++) mLink[i] = mLink[i-1] + CurCount[i-1]; + } + else + { + // This is a special case to correctly handle negative integers. They're sorted in the right order but at the wrong place. + + // Create biased offsets, in order for negative numbers to be sorted as well +// mOffset[0] = NbNegativeValues; // First positive number takes place after the negative ones + mLink[0] = &mRanks2[NbNegativeValues]; // First positive number takes place after the negative ones +// for(udword i=1;i<128;i++) mOffset[i] = mOffset[i-1] + CurCount[i-1]; // 1 to 128 for positive numbers + for(udword i=1;i<128;i++) mLink[i] = mLink[i-1] + CurCount[i-1]; // 1 to 128 for positive numbers + + // Fixing the wrong place for negative values +// mOffset[128] = 0; + mLink[128] = mRanks2; +// for(i=129;i<256;i++) mOffset[i] = mOffset[i-1] + CurCount[i-1]; + for(udword i=129;i<256;i++) mLink[i] = mLink[i-1] + CurCount[i-1]; + } + + // Perform Radix Sort + ubyte* InputBytes = (ubyte*)input; + InputBytes += j; + if(INVALID_RANKS) + { +// for(udword i=0;i>24; // Radix byte, same as above. AND is useless here (udword). + // ### cmp to be killed. Not good. Later. +// if(Radix<128) mRanks2[mOffset[Radix]++] = i; // Number is positive, same as above +// else mRanks2[--mOffset[Radix]] = i; // Number is negative, flip the sorting order + if(Radix<128) *mLink[Radix]++ = i; // Number is positive, same as above + else *(--mLink[Radix]) = i; // Number is negative, flip the sorting order + } + VALIDATE_RANKS; + } + else + { + for(udword i=0;i>24; // Radix byte, same as above. AND is useless here (udword). + // ### cmp to be killed. Not good. Later. +// if(Radix<128) mRanks2[mOffset[Radix]++] = mRanks[i]; // Number is positive, same as above +// else mRanks2[--mOffset[Radix]] = mRanks[i]; // Number is negative, flip the sorting order + if(Radix<128) *mLink[Radix]++ = mRanks[i]; // Number is positive, same as above + else *(--mLink[Radix]) = mRanks[i]; // Number is negative, flip the sorting order + } + } + // Swap pointers for next pass. Valid indices - the most recent ones - are in mRanks after the swap. + udword* Tmp = mRanks; mRanks = mRanks2; mRanks2 = Tmp; + } + else + { + // The pass is useless, yet we still have to reverse the order of current list if all values are negative. + if(UniqueVal>=128) + { + if(INVALID_RANKS) + { + // ###Possible? + for(udword i=0;i=SqrLen) + { + fT = 1.0f; + Diff -= Dir; + } + else + { + fT /= SqrLen; + Diff -= fT*Dir; + } + } + + if(t) *t = fT; + + return Diff.SquareMagnitude(); +} diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceSegment.h b/libs/ode-0.16.1/OPCODE/Ice/IceSegment.h new file mode 100644 index 0000000..8d66322 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceSegment.h @@ -0,0 +1,55 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for segments. + * \file IceSegment.h + * \author Pierre Terdiman + * \date April, 4, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __ICESEGMENT_H__ +#define __ICESEGMENT_H__ + + class ICEMATHS_API Segment + { + public: + //! Constructor + inline_ Segment() {} + //! Constructor + inline_ Segment(const Point& p0, const Point& p1) : mP0(p0), mP1(p1) {} + //! Copy constructor + inline_ Segment(const Segment& seg) : mP0(seg.mP0), mP1(seg.mP1) {} + //! Destructor + inline_ ~Segment() {} + + inline_ const Point& GetOrigin() const { return mP0; } + inline_ Point ComputeDirection() const { return mP1 - mP0; } + inline_ void ComputeDirection(Point& dir) const { dir = mP1 - mP0; } + inline_ float ComputeLength() const { return mP1.Distance(mP0); } + inline_ float ComputeSquareLength() const { return mP1.SquareDistance(mP0); } + + inline_ void SetOriginDirection(const Point& origin, const Point& direction) + { + mP0 = mP1 = origin; + mP1 += direction; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Computes a point on the segment + * \param pt [out] point on segment + * \param t [in] point's parameter [t=0 => pt = mP0, t=1 => pt = mP1] + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void ComputePoint(Point& pt, float t) const { pt = mP0 + t * (mP1 - mP0); } + + float SquareDistance(const Point& point, float* t=null) const; + inline_ float Distance(const Point& point, float* t=null) const { return sqrtf(SquareDistance(point, t)); } + + Point mP0; //!< Start of segment + Point mP1; //!< End of segment + }; + +#endif // __ICESEGMENT_H__ diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceTriList.h b/libs/ode-0.16.1/OPCODE/Ice/IceTriList.h new file mode 100644 index 0000000..73f5257 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceTriList.h @@ -0,0 +1,61 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for a triangle container. + * \file IceTrilist.h + * \author Pierre Terdiman + * \date April, 4, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __ICETRILIST_H__ +#define __ICETRILIST_H__ + + class ICEMATHS_API TriList : public Container + { + public: + // Constructor / Destructor + TriList() {} + ~TriList() {} + + inline_ udword GetNbTriangles() const { return GetNbEntries()/9; } + inline_ Triangle* GetTriangles() const { return (Triangle*)GetEntries(); } + + void AddTri(const Triangle& tri) + { + Add(tri.mVerts[0].x).Add(tri.mVerts[0].y).Add(tri.mVerts[0].z); + Add(tri.mVerts[1].x).Add(tri.mVerts[1].y).Add(tri.mVerts[1].z); + Add(tri.mVerts[2].x).Add(tri.mVerts[2].y).Add(tri.mVerts[2].z); + } + + void AddTri(const Point& p0, const Point& p1, const Point& p2) + { + Add(p0.x).Add(p0.y).Add(p0.z); + Add(p1.x).Add(p1.y).Add(p1.z); + Add(p2.x).Add(p2.y).Add(p2.z); + } + }; + + class ICEMATHS_API TriangleList : public Container + { + public: + // Constructor / Destructor + TriangleList() {} + ~TriangleList() {} + + inline_ udword GetNbTriangles() const { return GetNbEntries()/3; } + inline_ IndexedTriangle* GetTriangles() const { return (IndexedTriangle*)GetEntries();} + + void AddTriangle(const IndexedTriangle& tri) + { + Add((udword)tri.mVRef[0]).Add((udword)tri.mVRef[1]).Add((udword)tri.mVRef[2]); + } + + void AddTriangle(udword vref0, udword vref1, udword vref2) + { + Add(vref0).Add(vref1).Add(vref2); + } + }; + +#endif //__ICETRILIST_H__ diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceTriangle.cpp b/libs/ode-0.16.1/OPCODE/Ice/IceTriangle.cpp new file mode 100644 index 0000000..4268ff4 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceTriangle.cpp @@ -0,0 +1,286 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains a handy triangle class. + * \file IceTriangle.cpp + * \author Pierre Terdiman + * \date January, 17, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace IceMaths; + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains a triangle class. + * + * \class Tri + * \author Pierre Terdiman + * \version 1.0 + * \date 08.15.98 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +static sdword VPlaneSideEps(const Point& v, const Plane& plane, float epsilon) +{ + // Compute distance from current vertex to the plane + float Dist = plane.Distance(v); + // Compute side: + // 1 = the vertex is on the positive side of the plane + // -1 = the vertex is on the negative side of the plane + // 0 = the vertex is on the plane (within epsilon) + return Dist > epsilon ? 1 : Dist < -epsilon ? -1 : 0; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Flips the winding order. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void Triangle::Flip() +{ + Point Tmp = mVerts[1]; + mVerts[1] = mVerts[2]; + mVerts[2] = Tmp; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the triangle area. + * \return the area + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +float Triangle::Area() const +{ + const Point& p0 = mVerts[0]; + const Point& p1 = mVerts[1]; + const Point& p2 = mVerts[2]; + return ((p0 - p1)^(p0 - p2)).Magnitude() * 0.5f; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the triangle perimeter. + * \return the perimeter + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +float Triangle::Perimeter() const +{ + const Point& p0 = mVerts[0]; + const Point& p1 = mVerts[1]; + const Point& p2 = mVerts[2]; + return p0.Distance(p1) + + p0.Distance(p2) + + p1.Distance(p2); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the triangle compacity. + * \return the compacity + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +float Triangle::Compacity() const +{ + float P = Perimeter(); + if(P==0.0f) return 0.0f; + return (4.0f*PI*Area()/(P*P)); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the triangle normal. + * \param normal [out] the computed normal + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void Triangle::Normal(Point& normal) const +{ + const Point& p0 = mVerts[0]; + const Point& p1 = mVerts[1]; + const Point& p2 = mVerts[2]; + normal = ((p0 - p1)^(p0 - p2)).Normalize(); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the triangle denormalized normal. + * \param normal [out] the computed normal + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void Triangle::DenormalizedNormal(Point& normal) const +{ + const Point& p0 = mVerts[0]; + const Point& p1 = mVerts[1]; + const Point& p2 = mVerts[2]; + normal = ((p0 - p1)^(p0 - p2)); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the triangle center. + * \param center [out] the computed center + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void Triangle::Center(Point& center) const +{ + const Point& p0 = mVerts[0]; + const Point& p1 = mVerts[1]; + const Point& p2 = mVerts[2]; + center = (p0 + p1 + p2)*INV3; +} + +PartVal Triangle::TestAgainstPlane(const Plane& plane, float epsilon) const +{ + bool Pos = false, Neg = false; + + // Loop through all vertices + for(udword i=0;i<3;i++) + { + // Compute side: + sdword Side = VPlaneSideEps(mVerts[i], plane, epsilon); + + if (Side < 0) Neg = true; + else if (Side > 0) Pos = true; + } + + if (!Pos && !Neg) return TRI_ON_PLANE; + else if (Pos && Neg) return TRI_INTERSECT; + else if (Pos && !Neg) return TRI_PLUS_SPACE; + else if (!Pos && Neg) return TRI_MINUS_SPACE; + + // What?! + return TRI_FORCEDWORD; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the triangle moment. + * \param m [out] the moment + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* +void Triangle::ComputeMoment(Moment& m) +{ + // Compute the area of the triangle + m.mArea = Area(); + + // Compute the centroid + Center(m.mCentroid); + + // Second-order components. Handle zero-area faces. + Point& p = mVerts[0]; + Point& q = mVerts[1]; + Point& r = mVerts[2]; + if(m.mArea==0.0f) + { + // This triangle has zero area. The second order components would be eliminated with the usual formula, so, for the + // sake of robustness we use an alternative form. These are the centroid and second-order components of the triangle's vertices. + m.mCovariance.m[0][0] = (p.x*p.x + q.x*q.x + r.x*r.x); + m.mCovariance.m[0][1] = (p.x*p.y + q.x*q.y + r.x*r.y); + m.mCovariance.m[0][2] = (p.x*p.z + q.x*q.z + r.x*r.z); + m.mCovariance.m[1][1] = (p.y*p.y + q.y*q.y + r.y*r.y); + m.mCovariance.m[1][2] = (p.y*p.z + q.y*q.z + r.y*r.z); + m.mCovariance.m[2][2] = (p.z*p.z + q.z*q.z + r.z*r.z); + m.mCovariance.m[2][1] = m.mCovariance.m[1][2]; + m.mCovariance.m[1][0] = m.mCovariance.m[0][1]; + m.mCovariance.m[2][0] = m.mCovariance.m[0][2]; + } + else + { + const float OneOverTwelve = 1.0f / 12.0f; + m.mCovariance.m[0][0] = m.mArea * (9.0f * m.mCentroid.x*m.mCentroid.x + p.x*p.x + q.x*q.x + r.x*r.x) * OneOverTwelve; + m.mCovariance.m[0][1] = m.mArea * (9.0f * m.mCentroid.x*m.mCentroid.y + p.x*p.y + q.x*q.y + r.x*r.y) * OneOverTwelve; + m.mCovariance.m[1][1] = m.mArea * (9.0f * m.mCentroid.y*m.mCentroid.y + p.y*p.y + q.y*q.y + r.y*r.y) * OneOverTwelve; + m.mCovariance.m[0][2] = m.mArea * (9.0f * m.mCentroid.x*m.mCentroid.z + p.x*p.z + q.x*q.z + r.x*r.z) * OneOverTwelve; + m.mCovariance.m[1][2] = m.mArea * (9.0f * m.mCentroid.y*m.mCentroid.z + p.y*p.z + q.y*q.z + r.y*r.z) * OneOverTwelve; + m.mCovariance.m[2][2] = m.mArea * (9.0f * m.mCentroid.z*m.mCentroid.z + p.z*p.z + q.z*q.z + r.z*r.z) * OneOverTwelve; + m.mCovariance.m[2][1] = m.mCovariance.m[1][2]; + m.mCovariance.m[1][0] = m.mCovariance.m[0][1]; + m.mCovariance.m[2][0] = m.mCovariance.m[0][2]; + } +} +*/ + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the triangle's smallest edge length. + * \return the smallest edge length + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +float Triangle::MinEdgeLength() const +{ + float Min = MAX_FLOAT; + float Length01 = mVerts[0].Distance(mVerts[1]); + float Length02 = mVerts[0].Distance(mVerts[2]); + float Length12 = mVerts[1].Distance(mVerts[2]); + if(Length01 < Min) Min = Length01; + if(Length02 < Min) Min = Length02; + if(Length12 < Min) Min = Length12; + return Min; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the triangle's largest edge length. + * \return the largest edge length + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +float Triangle::MaxEdgeLength() const +{ + float Max = MIN_FLOAT; + float Length01 = mVerts[0].Distance(mVerts[1]); + float Length02 = mVerts[0].Distance(mVerts[2]); + float Length12 = mVerts[1].Distance(mVerts[2]); + if(Length01 > Max) Max = Length01; + if(Length02 > Max) Max = Length02; + if(Length12 > Max) Max = Length12; + return Max; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes a point on the triangle according to the stabbing information. + * \param u,v [in] point's barycentric coordinates + * \param pt [out] point on triangle + * \param nearvtx [out] index of nearest vertex + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void Triangle::ComputePoint(float u, float v, Point& pt, udword* nearvtx) const +{ + // Compute point coordinates + pt = (1.0f - u - v)*mVerts[0] + u*mVerts[1] + v*mVerts[2]; + + // Compute nearest vertex if needed + if(nearvtx) + { + // Compute distance vector + Point d(mVerts[0].SquareDistance(pt), // Distance^2 from vertex 0 to point on the face + mVerts[1].SquareDistance(pt), // Distance^2 from vertex 1 to point on the face + mVerts[2].SquareDistance(pt)); // Distance^2 from vertex 2 to point on the face + + // Get smallest distance + *nearvtx = d.SmallestAxis(); + } +} + +void Triangle::Inflate(float fat_coeff, bool constant_border) +{ + // Compute triangle center + Point TriangleCenter; + Center(TriangleCenter); + + // Don't normalize? + // Normalize => add a constant border, regardless of triangle size + // Don't => add more to big triangles + for(udword i=0;i<3;i++) + { + Point v = mVerts[i] - TriangleCenter; + + if(constant_border) v.Normalize(); + + mVerts[i] += v * fat_coeff; + } +} diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceTriangle.h b/libs/ode-0.16.1/OPCODE/Ice/IceTriangle.h new file mode 100644 index 0000000..a984db8 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceTriangle.h @@ -0,0 +1,68 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains a handy triangle class. + * \file IceTriangle.h + * \author Pierre Terdiman + * \date January, 17, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __ICETRIANGLE_H__ +#define __ICETRIANGLE_H__ + + // Forward declarations + class Moment; + + // Partitioning values + enum PartVal + { + TRI_MINUS_SPACE = 0, //!< Triangle is in the negative space + TRI_PLUS_SPACE = 1, //!< Triangle is in the positive space + TRI_INTERSECT = 2, //!< Triangle intersects plane + TRI_ON_PLANE = 3, //!< Triangle and plane are coplanar + + TRI_FORCEDWORD = 0x7fffffff + }; + + // A triangle class. + class ICEMATHS_API Triangle + { + public: + //! Constructor + inline_ Triangle() {} + //! Constructor + inline_ Triangle(const Point& p0, const Point& p1, const Point& p2) { mVerts[0]=p0; mVerts[1]=p1; mVerts[2]=p2; } + //! Copy constructor + inline_ Triangle(const Triangle& triangle) + { + mVerts[0] = triangle.mVerts[0]; + mVerts[1] = triangle.mVerts[1]; + mVerts[2] = triangle.mVerts[2]; + } + //! Destructor + inline_ ~Triangle() {} + //! Vertices + Point mVerts[3]; + + // Methods + void Flip(); + float Area() const; + float Perimeter() const; + float Compacity() const; + void Normal(Point& normal) const; + void DenormalizedNormal(Point& normal) const; + void Center(Point& center) const; + inline_ Plane PlaneEquation() const { return Plane(mVerts[0], mVerts[1], mVerts[2]); } + + PartVal TestAgainstPlane(const Plane& plane, float epsilon) const; +// float Distance(Point& cp, Point& cq, Tri& tri); + void ComputeMoment(Moment& m); + float MinEdgeLength() const; + float MaxEdgeLength() const; + void ComputePoint(float u, float v, Point& pt, udword* nearvtx=null) const; + void Inflate(float fat_coeff, bool constant_border); + }; + +#endif // __ICETRIANGLE_H__ diff --git a/libs/ode-0.16.1/OPCODE/Ice/IceTypes.h b/libs/ode-0.16.1/OPCODE/Ice/IceTypes.h new file mode 100644 index 0000000..c896623 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/IceTypes.h @@ -0,0 +1,161 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains custom types. + * \file IceTypes.h + * \author Pierre Terdiman + * \date April, 4, 2000 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __ICETYPES_H__ +#define __ICETYPES_H__ + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Things to help us compile on non-windows platforms + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + + #define USE_HANDLE_MANAGER + + // Constants + #define PI 3.1415926535897932384626433832795028841971693993751f //!< PI + #define HALFPI 1.57079632679489661923f //!< 0.5 * PI + #define TWOPI 6.28318530717958647692f //!< 2.0 * PI + #define INVPI 0.31830988618379067154f //!< 1.0 / PI + + #define RADTODEG 57.2957795130823208768f //!< 180.0 / PI, convert radians to degrees + #define DEGTORAD 0.01745329251994329577f //!< PI / 180.0, convert degrees to radians + + #define EXP 2.71828182845904523536f //!< e + #define INVLOG2 3.32192809488736234787f //!< 1.0 / log10(2) + #define LN2 0.693147180559945f //!< ln(2) + #define INVLN2 1.44269504089f //!< 1.0f / ln(2) + + #define INV3 0.33333333333333333333f //!< 1/3 + #define INV6 0.16666666666666666666f //!< 1/6 + #define INV7 0.14285714285714285714f //!< 1/7 + #define INV9 0.11111111111111111111f //!< 1/9 + #define INV255 0.00392156862745098039f //!< 1/255 + + #define SQRT2 1.41421356237f //!< sqrt(2) + #define INVSQRT2 0.707106781188f //!< 1 / sqrt(2) + + #define SQRT3 1.73205080757f //!< sqrt(3) + #define INVSQRT3 0.577350269189f //!< 1 / sqrt(3) + + #define null 0 //!< our own NULL pointer + + // Custom types used in ICE + typedef signed char sbyte; //!< sizeof(sbyte) must be 1 + typedef unsigned char ubyte; //!< sizeof(ubyte) must be 1 + typedef signed short sword; //!< sizeof(sword) must be 2 + typedef unsigned short uword; //!< sizeof(uword) must be 2 + typedef signed int sdword; //!< sizeof(sdword) must be 4 + typedef unsigned int udword; //!< sizeof(udword) must be 4 + typedef signed __int64 sqword; //!< sizeof(sqword) must be 8 + typedef unsigned __int64 uqword; //!< sizeof(uqword) must be 8 + typedef float float32; //!< sizeof(float32) must be 4 + typedef double float64; //!< sizeof(float64) must be 4 + + ICE_COMPILE_TIME_ASSERT(sizeof(ubyte)==1); + ICE_COMPILE_TIME_ASSERT(sizeof(sbyte)==1); + ICE_COMPILE_TIME_ASSERT(sizeof(sword)==2); + ICE_COMPILE_TIME_ASSERT(sizeof(uword)==2); + ICE_COMPILE_TIME_ASSERT(sizeof(udword)==4); + ICE_COMPILE_TIME_ASSERT(sizeof(sdword)==4); + ICE_COMPILE_TIME_ASSERT(sizeof(uqword)==8); + ICE_COMPILE_TIME_ASSERT(sizeof(sqword)==8); + + //! TO BE DOCUMENTED + #define DECLARE_ICE_HANDLE(name) struct name##__ { int unused; }; typedef struct name##__ *name + + typedef udword DynID; //!< Dynamic identifier +#ifdef USE_HANDLE_MANAGER + typedef udword KID; //!< Kernel ID +// DECLARE_ICE_HANDLE(KID); +#else + typedef uword KID; //!< Kernel ID +#endif + typedef udword RTYPE; //!< Relationship-type (!) between owners and references + #define INVALID_ID 0xffffffff //!< Invalid dword ID (counterpart of null pointers) +#ifdef USE_HANDLE_MANAGER + #define INVALID_KID 0xffffffff //!< Invalid Kernel ID +#else + #define INVALID_KID 0xffff //!< Invalid Kernel ID +#endif + #define INVALID_NUMBER 0xDEADBEEF //!< Standard junk value + + // Define BOOL if needed + #ifndef BOOL + typedef int BOOL; //!< Another boolean type. + #endif + + //! Union of a float and a sdword + typedef union { + float f; //!< The float + sdword d; //!< The integer + }scell; + + //! Union of a float and a udword + typedef union { + float f; //!< The float + udword d; //!< The integer + }ucell; + + // Type ranges + #define MAX_SBYTE 0x7f //!< max possible sbyte value + #define MIN_SBYTE 0x80 //!< min possible sbyte value + #define MAX_UBYTE 0xff //!< max possible ubyte value + #define MIN_UBYTE 0x00 //!< min possible ubyte value + #define MAX_SWORD 0x7fff //!< max possible sword value + #define MIN_SWORD 0x8000 //!< min possible sword value + #define MAX_UWORD 0xffff //!< max possible uword value + #define MIN_UWORD 0x0000 //!< min possible uword value + #define MAX_SDWORD 0x7fffffff //!< max possible sdword value + #define MIN_SDWORD 0x80000000 //!< min possible sdword value + #define MAX_UDWORD 0xffffffff //!< max possible udword value + #define MIN_UDWORD 0x00000000 //!< min possible udword value + #define MAX_FLOAT FLT_MAX //!< max possible float value + #define MIN_FLOAT (-FLT_MAX) //!< min possible loat value + #define IEEE_1_0 0x3f800000 //!< integer representation of 1.0 + #define IEEE_255_0 0x437f0000 //!< integer representation of 255.0 + #define IEEE_MAX_FLOAT 0x7f7fffff //!< integer representation of MAX_FLOAT + #define IEEE_MIN_FLOAT 0xff7fffff //!< integer representation of MIN_FLOAT + #define IEEE_UNDERFLOW_LIMIT 0x1a000000 + + #define ONE_OVER_RAND_MAX (1.0f / float(RAND_MAX)) //!< Inverse of the max possible value returned by rand() + + // typedef int (__stdcall* PROC)(); -- Oleh Derevenko: Conflicts with Windows headers in x64 mode //!< A standard procedure call. + typedef bool (*ENUMERATION)(udword value, udword param, udword context); //!< ICE standard enumeration call + typedef void** VTABLE; //!< A V-Table. + + #undef MIN + #undef MAX + #define MIN(a, b) ((a) < (b) ? (a) : (b)) //!< Returns the min value between a and b + #define MAX(a, b) ((a) > (b) ? (a) : (b)) //!< Returns the max value between a and b + #define MAXMAX(a,b,c) ((a) > (b) ? MAX (a,c) : MAX (b,c)) //!< Returns the max value between a, b and c + + template inline_ const T& TMin (const T& a, const T& b) { return b < a ? b : a; } + template inline_ const T& TMax (const T& a, const T& b) { return a < b ? b : a; } + template inline_ void TSetMin (T& a, const T& b) { if(a>b) a = b; } + template inline_ void TSetMax (T& a, const T& b) { if(a> 1) & 0x55555555) | ((n << 1) & 0xaaaaaaaa); + n = ((n >> 2) & 0x33333333) | ((n << 2) & 0xcccccccc); + n = ((n >> 4) & 0x0f0f0f0f) | ((n << 4) & 0xf0f0f0f0); + n = ((n >> 8) & 0x00ff00ff) | ((n << 8) & 0xff00ff00); + n = ((n >> 16) & 0x0000ffff) | ((n << 16) & 0xffff0000); + // Etc for larger intergers (64 bits in Java) + // NOTE: the >> operation must be unsigned! (>>> in java) + } + + //! Count the number of '1' bits in a 32 bit word (from Steve Baker's Cute Code Collection) + inline_ udword CountBits(udword n) + { + // This relies of the fact that the count of n bits can NOT overflow + // an n bit interger. EG: 1 bit count takes a 1 bit interger, 2 bit counts + // 2 bit interger, 3 bit count requires only a 2 bit interger. + // So we add all bit pairs, then each nible, then each byte etc... + n = (n & 0x55555555) + ((n & 0xaaaaaaaa) >> 1); + n = (n & 0x33333333) + ((n & 0xcccccccc) >> 2); + n = (n & 0x0f0f0f0f) + ((n & 0xf0f0f0f0) >> 4); + n = (n & 0x00ff00ff) + ((n & 0xff00ff00) >> 8); + n = (n & 0x0000ffff) + ((n & 0xffff0000) >> 16); + // Etc for larger intergers (64 bits in Java) + // NOTE: the >> operation must be unsigned! (>>> in java) + return n; + } + + //! Even faster? + inline_ udword CountBits2(udword bits) + { + bits = bits - ((bits >> 1) & 0x55555555); + bits = ((bits >> 2) & 0x33333333) + (bits & 0x33333333); + bits = ((bits >> 4) + bits) & 0x0F0F0F0F; + return (bits * 0x01010101) >> 24; + } + + //! Spread out bits. EG 00001111 -> 0101010101 + //! 00001010 -> 0100010000 + //! This is used to interleve to intergers to produce a `Morten Key' + //! used in Space Filling Curves (See DrDobbs Journal, July 1999) + //! Order is important. + inline_ void SpreadBits(udword& n) + { + n = ( n & 0x0000ffff) | (( n & 0xffff0000) << 16); + n = ( n & 0x000000ff) | (( n & 0x0000ff00) << 8); + n = ( n & 0x000f000f) | (( n & 0x00f000f0) << 4); + n = ( n & 0x03030303) | (( n & 0x0c0c0c0c) << 2); + n = ( n & 0x11111111) | (( n & 0x22222222) << 1); + } + + // Next Largest Power of 2 + // Given a binary integer value x, the next largest power of 2 can be computed by a SWAR algorithm + // that recursively "folds" the upper bits into the lower bits. This process yields a bit vector with + // the same most significant 1 as x, but all 1's below it. Adding 1 to that value yields the next + // largest power of 2. For a 32-bit value: + inline_ udword nlpo2(udword x) + { + x |= (x >> 1); + x |= (x >> 2); + x |= (x >> 4); + x |= (x >> 8); + x |= (x >> 16); + return x+1; + } + + //! Test to see if a number is an exact power of two (from Steve Baker's Cute Code Collection) + inline_ bool IsPowerOfTwo(udword n) { return ((n&(n-1))==0); } + + //! Zero the least significant '1' bit in a word. (from Steve Baker's Cute Code Collection) + inline_ void ZeroLeastSetBit(udword& n) { n&=(n-1); } + + //! Set the least significant N bits in a word. (from Steve Baker's Cute Code Collection) + inline_ void SetLeastNBits(udword& x, udword n) { x|=~(~0<> 31; return (x^y)-y; } + + //!< Alternative min function + inline_ sdword min_(sdword a, sdword b) { sdword delta = b-a; return a + (delta&(delta>>31)); } + + // Determine if one of the bytes in a 4 byte word is zero + inline_ BOOL HasNullByte(udword x) { return ((x + 0xfefefeff) & (~x) & 0x80808080); } + + // To find the smallest 1 bit in a word EG: ~~~~~~10---0 => 0----010---0 + inline_ udword LowestOneBit(udword w) { return ((w) & (~(w)+1)); } +// inline_ udword LowestOneBit_(udword w) { return ((w) & (-(w))); } + + // Most Significant 1 Bit + // Given a binary integer value x, the most significant 1 bit (highest numbered element of a bit set) + // can be computed using a SWAR algorithm that recursively "folds" the upper bits into the lower bits. + // This process yields a bit vector with the same most significant 1 as x, but all 1's below it. + // Bitwise AND of the original value with the complement of the "folded" value shifted down by one + // yields the most significant bit. For a 32-bit value: + inline_ udword msb32(udword x) + { + x |= (x >> 1); + x |= (x >> 2); + x |= (x >> 4); + x |= (x >> 8); + x |= (x >> 16); + return (x & ~(x >> 1)); + } + + /* + "Just call it repeatedly with various input values and always with the same variable as "memory". + The sharpness determines the degree of filtering, where 0 completely filters out the input, and 1 + does no filtering at all. + + I seem to recall from college that this is called an IIR (Infinite Impulse Response) filter. As opposed + to the more typical FIR (Finite Impulse Response). + + Also, I'd say that you can make more intelligent and interesting filters than this, for example filters + that remove wrong responses from the mouse because it's being moved too fast. You'd want such a filter + to be applied before this one, of course." + + (JCAB on Flipcode) + */ + inline_ float FeedbackFilter(float val, float& memory, float sharpness) + { + ASSERT(sharpness>=0.0f && sharpness<=1.0f && "Invalid sharpness value in feedback filter"); + if(sharpness<0.0f) sharpness = 0.0f; + else if(sharpness>1.0f) sharpness = 1.0f; + return memory = val * sharpness + memory * (1.0f - sharpness); + } + + //! If you can guarantee that your input domain (i.e. value of x) is slightly + //! limited (abs(x) must be < ((1<<31u)-32767)), then you can use the + //! following code to clamp the resulting value into [-32768,+32767] range: + inline_ int ClampToInt16(int x) + { +// ASSERT(abs(x) < (int)((1<<31u)-32767)); + + int delta = 32767 - x; + x += (delta>>31) & delta; + delta = x + 32768; + x -= (delta>>31) & delta; + return x; + } + + // Generic functions + template inline_ void TSwap(Type& a, Type& b) { const Type c = a; a = b; b = c; } + template inline_ Type TClamp(const Type& x, const Type& lo, const Type& hi) { return ((xhi) ? hi : x); } + + template inline_ void TSort(Type& a, Type& b) + { + if(a>b) TSwap(a, b); + } + + template inline_ void TSort(Type& a, Type& b, Type& c) + { + if(a>b) TSwap(a, b); + if(b>c) TSwap(b, c); + if(a>b) TSwap(a, b); + if(b>c) TSwap(b, c); + } + + // Prevent nasty user-manipulations (strategy borrowed from Charles Bloom) +// #define PREVENT_COPY(curclass) void operator = (const curclass& object) { ASSERT(!"Bad use of operator ="); } + // ... actually this is better ! + #define PREVENT_COPY(cur_class) private: cur_class(const cur_class& object); cur_class& operator=(const cur_class& object); + + //! TO BE DOCUMENTED + #define OFFSET_OF(Class, Member) (size_t)&(((Class*)0)->Member) + //! TO BE DOCUMENTED +#ifndef ARRAYSIZE + #define ARRAYSIZE(p) (sizeof(p)/sizeof((p)[0])) +#endif // #ifndef ARRAYSIZE + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Returns the alignment of the input address. + * \fn Alignment() + * \param address [in] address to check + * \return the best alignment (e.g. 1 for odd addresses, etc) + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + FUNCTION ICECORE_API udword Alignment(udword address); + + #define IS_ALIGNED_2(x) ((x&1)==0) + #define IS_ALIGNED_4(x) ((x&3)==0) + #define IS_ALIGNED_8(x) ((x&7)==0) + + inline_ void _prefetch(void const* ptr) { (void)*(char const volatile *)ptr; } + + // Compute implicit coords from an index: + // The idea is to get back 2D coords from a 1D index. + // For example: + // + // 0 1 2 ... nbu-1 + // nbu nbu+1 i ... + // + // We have i, we're looking for the equivalent (u=2, v=1) location. + // i = u + v*nbu + // <=> i/nbu = u/nbu + v + // Since 0 <= u < nbu, u/nbu = 0 (integer) + // Hence: v = i/nbu + // Then we simply put it back in the original equation to compute u = i - v*nbu + inline_ void Compute2DCoords(udword& u, udword& v, udword i, udword nbu) + { + v = i / nbu; + u = i - (v * nbu); + } + + // In 3D: i = u + v*nbu + w*nbu*nbv + // <=> i/(nbu*nbv) = u/(nbu*nbv) + v/nbv + w + // u/(nbu*nbv) is null since u/nbu was null already. + // v/nbv is null as well for the same reason. + // Hence w = i/(nbu*nbv) + // Then we're left with a 2D problem: i' = i - w*nbu*nbv = u + v*nbu + inline_ void Compute3DCoords(udword& u, udword& v, udword& w, udword i, udword nbu, udword nbu_nbv) + { + w = i / (nbu_nbv); + Compute2DCoords(u, v, i - (w * nbu_nbv), nbu); + } + +#endif // __ICEUTILS_H__ diff --git a/libs/ode-0.16.1/OPCODE/Ice/Makefile.am b/libs/ode-0.16.1/OPCODE/Ice/Makefile.am new file mode 100644 index 0000000..4f3256c --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/Makefile.am @@ -0,0 +1,20 @@ +AM_CPPFLAGS = -I$(top_srcdir)/OPCODE \ + -I$(top_srcdir)/include \ + -I$(top_builddir)/include + +noinst_LTLIBRARIES = libIce.la +libIce_la_SOURCES = \ + IceAABB.cpp IceAABB.h IceAxes.h \ + IceBoundingSphere.h IceContainer.cpp IceContainer.h \ + IceFPU.h IceHPoint.cpp IceHPoint.h \ + IceIndexedTriangle.cpp IceIndexedTriangle.h IceLSS.h \ + IceMatrix3x3.cpp IceMatrix3x3.h IceMatrix4x4.cpp \ + IceMatrix4x4.h IceMemoryMacros.h IceOBB.cpp \ + IceOBB.h IcePairs.h IcePlane.cpp \ + IcePlane.h IcePoint.cpp IcePoint.h \ + IcePreprocessor.h IceRandom.cpp IceRandom.h \ + IceRay.cpp IceRay.h IceRevisitedRadix.cpp \ + IceRevisitedRadix.h IceSegment.cpp IceSegment.h \ + IceTriangle.cpp IceTriangle.h IceTriList.h \ + IceTypes.h IceUtils.cpp IceUtils.h + diff --git a/libs/ode-0.16.1/OPCODE/Ice/Makefile.in b/libs/ode-0.16.1/OPCODE/Ice/Makefile.in new file mode 100644 index 0000000..d5f05b7 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Ice/Makefile.in @@ -0,0 +1,660 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = OPCODE/Ice +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ + $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ + $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/ode/src/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +LTLIBRARIES = $(noinst_LTLIBRARIES) +libIce_la_LIBADD = +am_libIce_la_OBJECTS = IceAABB.lo IceContainer.lo IceHPoint.lo \ + IceIndexedTriangle.lo IceMatrix3x3.lo IceMatrix4x4.lo \ + IceOBB.lo IcePlane.lo IcePoint.lo IceRandom.lo IceRay.lo \ + IceRevisitedRadix.lo IceSegment.lo IceTriangle.lo IceUtils.lo +libIce_la_OBJECTS = $(am_libIce_la_OBJECTS) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/ode/src +depcomp = $(SHELL) $(top_srcdir)/depcomp +am__depfiles_maybe = depfiles +am__mv = mv -f +CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ + $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) +LTCXXCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CXXFLAGS) $(CXXFLAGS) +AM_V_CXX = $(am__v_CXX_@AM_V@) +am__v_CXX_ = $(am__v_CXX_@AM_DEFAULT_V@) +am__v_CXX_0 = @echo " CXX " $@; +am__v_CXX_1 = +CXXLD = $(CXX) +CXXLINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \ + $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CXXLD = $(am__v_CXXLD_@AM_V@) +am__v_CXXLD_ = $(am__v_CXXLD_@AM_DEFAULT_V@) +am__v_CXXLD_0 = @echo " CXXLD " $@; +am__v_CXXLD_1 = +COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ + $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CFLAGS) $(CFLAGS) +AM_V_CC = $(am__v_CC_@AM_V@) +am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) +am__v_CC_0 = @echo " CC " $@; +am__v_CC_1 = +CCLD = $(CC) +LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CCLD = $(am__v_CCLD_@AM_V@) +am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) +am__v_CCLD_0 = @echo " CCLD " $@; +am__v_CCLD_1 = +SOURCES = $(libIce_la_SOURCES) +DIST_SOURCES = $(libIce_la_SOURCES) +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AS = @AS@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CCD_CFLAGS = @CCD_CFLAGS@ +CCD_LIBS = @CCD_LIBS@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DOXYGEN = @DOXYGEN@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +EXTRA_LIBTOOL_LDFLAGS = @EXTRA_LIBTOOL_LDFLAGS@ +FGREP = @FGREP@ +GL_LIBS = @GL_LIBS@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBSTDCXX = @LIBSTDCXX@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +ODE_PRECISION = @ODE_PRECISION@ +ODE_VERSION = @ODE_VERSION@ +ODE_VERSION_INFO = @ODE_VERSION_INFO@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +WINDRES = @WINDRES@ +X11_CFLAGS = @X11_CFLAGS@ +X11_LIBS = @X11_LIBS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_WINDRES = @ac_ct_WINDRES@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +runstatedir = @runstatedir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +AM_CPPFLAGS = -I$(top_srcdir)/OPCODE \ + -I$(top_srcdir)/include \ + -I$(top_builddir)/include + +noinst_LTLIBRARIES = libIce.la +libIce_la_SOURCES = \ + IceAABB.cpp IceAABB.h IceAxes.h \ + IceBoundingSphere.h IceContainer.cpp IceContainer.h \ + IceFPU.h IceHPoint.cpp IceHPoint.h \ + IceIndexedTriangle.cpp IceIndexedTriangle.h IceLSS.h \ + IceMatrix3x3.cpp IceMatrix3x3.h IceMatrix4x4.cpp \ + IceMatrix4x4.h IceMemoryMacros.h IceOBB.cpp \ + IceOBB.h IcePairs.h IcePlane.cpp \ + IcePlane.h IcePoint.cpp IcePoint.h \ + IcePreprocessor.h IceRandom.cpp IceRandom.h \ + IceRay.cpp IceRay.h IceRevisitedRadix.cpp \ + IceRevisitedRadix.h IceSegment.cpp IceSegment.h \ + IceTriangle.cpp IceTriangle.h IceTriList.h \ + IceTypes.h IceUtils.cpp IceUtils.h + +all: all-am + +.SUFFIXES: +.SUFFIXES: .cpp .lo .o .obj +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign OPCODE/Ice/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign OPCODE/Ice/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): + +clean-noinstLTLIBRARIES: + -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES) + @list='$(noinst_LTLIBRARIES)'; \ + locs=`for p in $$list; do echo $$p; done | \ + sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ + sort -u`; \ + test -z "$$locs" || { \ + echo rm -f $${locs}; \ + rm -f $${locs}; \ + } + +libIce.la: $(libIce_la_OBJECTS) $(libIce_la_DEPENDENCIES) $(EXTRA_libIce_la_DEPENDENCIES) + $(AM_V_CXXLD)$(CXXLINK) $(libIce_la_OBJECTS) $(libIce_la_LIBADD) $(LIBS) + +mostlyclean-compile: + -rm -f *.$(OBJEXT) + +distclean-compile: + -rm -f *.tab.c + +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/IceAABB.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/IceContainer.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/IceHPoint.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/IceIndexedTriangle.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/IceMatrix3x3.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/IceMatrix4x4.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/IceOBB.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/IcePlane.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/IcePoint.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/IceRandom.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/IceRay.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/IceRevisitedRadix.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/IceSegment.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/IceTriangle.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/IceUtils.Plo@am__quote@ + +.cpp.o: +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ $< + +.cpp.obj: +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'` + +.cpp.lo: +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LTCXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LTCXXCOMPILE) -c -o $@ $< + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(LTLIBRARIES) +installdirs: +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-generic clean-libtool clean-noinstLTLIBRARIES \ + mostlyclean-am + +distclean: distclean-am + -rm -rf ./$(DEPDIR) + -rm -f Makefile +distclean-am: clean-am distclean-compile distclean-generic \ + distclean-tags + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -rf ./$(DEPDIR) + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ + mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: + +.MAKE: install-am install-strip + +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ + clean-libtool clean-noinstLTLIBRARIES cscopelist-am ctags \ + ctags-am distclean distclean-compile distclean-generic \ + distclean-libtool distclean-tags distdir dvi dvi-am html \ + html-am info info-am install install-am install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am install-info \ + install-info-am install-man install-pdf install-pdf-am \ + install-ps install-ps-am install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-am uninstall uninstall-am + +.PRECIOUS: Makefile + + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/libs/ode-0.16.1/OPCODE/Makefile.am b/libs/ode-0.16.1/OPCODE/Makefile.am new file mode 100644 index 0000000..1e82910 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Makefile.am @@ -0,0 +1,45 @@ +EXTRA_DIST = COPYING \ + ReadMe.txt \ + README-ODE.txt \ + TemporalCoherence.txt + +SUBDIRS = Ice + +noinst_LTLIBRARIES = libOPCODE.la +AM_CPPFLAGS= -I$(top_srcdir)/include \ + -I$(top_builddir)/include + +libOPCODE_la_SOURCES = OPC_AABBCollider.cpp OPC_AABBCollider.h \ + OPC_AABBTree.cpp OPC_AABBTree.h \ + OPC_BaseModel.cpp OPC_BaseModel.h \ + OPC_Collider.cpp OPC_Collider.h \ + OPC_Common.cpp OPC_Common.h \ + OPC_HybridModel.cpp OPC_HybridModel.h \ + OPC_LSSCollider.cpp OPC_LSSCollider.h \ + OPC_MeshInterface.cpp OPC_MeshInterface.h \ + OPC_Model.cpp OPC_Model.h \ + OPC_OBBCollider.cpp OPC_OBBCollider.h \ + Opcode.cpp Opcode.h \ + OPC_OptimizedTree.cpp OPC_OptimizedTree.h \ + OPC_Picking.cpp OPC_Picking.h \ + OPC_PlanesCollider.cpp OPC_PlanesCollider.h \ + OPC_RayCollider.cpp OPC_RayCollider.h \ + OPC_SphereCollider.cpp OPC_SphereCollider.h \ + OPC_TreeBuilders.cpp OPC_TreeBuilders.h \ + OPC_TreeCollider.cpp OPC_TreeCollider.h \ + OPC_VolumeCollider.cpp OPC_VolumeCollider.h \ + OPC_Settings.h \ + OPC_SphereAABBOverlap.h \ + OPC_BoxBoxOverlap.h \ + OPC_SphereTriOverlap.h \ + OPC_PlanesAABBOverlap.h \ + OPC_TriBoxOverlap.h \ + OPC_IceHook.h \ + OPC_PlanesTriOverlap.h \ + OPC_TriTriOverlap.h \ + OPC_LSSAABBOverlap.h \ + OPC_RayAABBOverlap.h \ + Stdafx.h \ + OPC_LSSTriOverlap.h \ + OPC_RayTriOverlap.h + diff --git a/libs/ode-0.16.1/OPCODE/Makefile.in b/libs/ode-0.16.1/OPCODE/Makefile.in new file mode 100644 index 0000000..bc96d41 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Makefile.in @@ -0,0 +1,807 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = OPCODE +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ + $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ + $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/ode/src/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +LTLIBRARIES = $(noinst_LTLIBRARIES) +libOPCODE_la_LIBADD = +am_libOPCODE_la_OBJECTS = OPC_AABBCollider.lo OPC_AABBTree.lo \ + OPC_BaseModel.lo OPC_Collider.lo OPC_Common.lo \ + OPC_HybridModel.lo OPC_LSSCollider.lo OPC_MeshInterface.lo \ + OPC_Model.lo OPC_OBBCollider.lo Opcode.lo OPC_OptimizedTree.lo \ + OPC_Picking.lo OPC_PlanesCollider.lo OPC_RayCollider.lo \ + OPC_SphereCollider.lo OPC_TreeBuilders.lo OPC_TreeCollider.lo \ + OPC_VolumeCollider.lo +libOPCODE_la_OBJECTS = $(am_libOPCODE_la_OBJECTS) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/ode/src +depcomp = $(SHELL) $(top_srcdir)/depcomp +am__depfiles_maybe = depfiles +am__mv = mv -f +CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ + $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) +LTCXXCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CXXFLAGS) $(CXXFLAGS) +AM_V_CXX = $(am__v_CXX_@AM_V@) +am__v_CXX_ = $(am__v_CXX_@AM_DEFAULT_V@) +am__v_CXX_0 = @echo " CXX " $@; +am__v_CXX_1 = +CXXLD = $(CXX) +CXXLINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \ + $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CXXLD = $(am__v_CXXLD_@AM_V@) +am__v_CXXLD_ = $(am__v_CXXLD_@AM_DEFAULT_V@) +am__v_CXXLD_0 = @echo " CXXLD " $@; +am__v_CXXLD_1 = +COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ + $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CFLAGS) $(CFLAGS) +AM_V_CC = $(am__v_CC_@AM_V@) +am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) +am__v_CC_0 = @echo " CC " $@; +am__v_CC_1 = +CCLD = $(CC) +LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CCLD = $(am__v_CCLD_@AM_V@) +am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) +am__v_CCLD_0 = @echo " CCLD " $@; +am__v_CCLD_1 = +SOURCES = $(libOPCODE_la_SOURCES) +DIST_SOURCES = $(libOPCODE_la_SOURCES) +RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ + ctags-recursive dvi-recursive html-recursive info-recursive \ + install-data-recursive install-dvi-recursive \ + install-exec-recursive install-html-recursive \ + install-info-recursive install-pdf-recursive \ + install-ps-recursive install-recursive installcheck-recursive \ + installdirs-recursive pdf-recursive ps-recursive \ + tags-recursive uninstall-recursive +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ + distclean-recursive maintainer-clean-recursive +am__recursive_targets = \ + $(RECURSIVE_TARGETS) \ + $(RECURSIVE_CLEAN_TARGETS) \ + $(am__extra_recursive_targets) +AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ + distdir +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +DIST_SUBDIRS = $(SUBDIRS) +am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp COPYING +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +am__relativize = \ + dir0=`pwd`; \ + sed_first='s,^\([^/]*\)/.*$$,\1,'; \ + sed_rest='s,^[^/]*/*,,'; \ + sed_last='s,^.*/\([^/]*\)$$,\1,'; \ + sed_butlast='s,/*[^/]*$$,,'; \ + while test -n "$$dir1"; do \ + first=`echo "$$dir1" | sed -e "$$sed_first"`; \ + if test "$$first" != "."; then \ + if test "$$first" = ".."; then \ + dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ + dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ + else \ + first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ + if test "$$first2" = "$$first"; then \ + dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ + else \ + dir2="../$$dir2"; \ + fi; \ + dir0="$$dir0"/"$$first"; \ + fi; \ + fi; \ + dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ + done; \ + reldir="$$dir2" +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AS = @AS@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CCD_CFLAGS = @CCD_CFLAGS@ +CCD_LIBS = @CCD_LIBS@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DOXYGEN = @DOXYGEN@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +EXTRA_LIBTOOL_LDFLAGS = @EXTRA_LIBTOOL_LDFLAGS@ +FGREP = @FGREP@ +GL_LIBS = @GL_LIBS@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBSTDCXX = @LIBSTDCXX@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +ODE_PRECISION = @ODE_PRECISION@ +ODE_VERSION = @ODE_VERSION@ +ODE_VERSION_INFO = @ODE_VERSION_INFO@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +WINDRES = @WINDRES@ +X11_CFLAGS = @X11_CFLAGS@ +X11_LIBS = @X11_LIBS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_WINDRES = @ac_ct_WINDRES@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +runstatedir = @runstatedir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +EXTRA_DIST = COPYING \ + ReadMe.txt \ + README-ODE.txt \ + TemporalCoherence.txt + +SUBDIRS = Ice +noinst_LTLIBRARIES = libOPCODE.la +AM_CPPFLAGS = -I$(top_srcdir)/include \ + -I$(top_builddir)/include + +libOPCODE_la_SOURCES = OPC_AABBCollider.cpp OPC_AABBCollider.h \ + OPC_AABBTree.cpp OPC_AABBTree.h \ + OPC_BaseModel.cpp OPC_BaseModel.h \ + OPC_Collider.cpp OPC_Collider.h \ + OPC_Common.cpp OPC_Common.h \ + OPC_HybridModel.cpp OPC_HybridModel.h \ + OPC_LSSCollider.cpp OPC_LSSCollider.h \ + OPC_MeshInterface.cpp OPC_MeshInterface.h \ + OPC_Model.cpp OPC_Model.h \ + OPC_OBBCollider.cpp OPC_OBBCollider.h \ + Opcode.cpp Opcode.h \ + OPC_OptimizedTree.cpp OPC_OptimizedTree.h \ + OPC_Picking.cpp OPC_Picking.h \ + OPC_PlanesCollider.cpp OPC_PlanesCollider.h \ + OPC_RayCollider.cpp OPC_RayCollider.h \ + OPC_SphereCollider.cpp OPC_SphereCollider.h \ + OPC_TreeBuilders.cpp OPC_TreeBuilders.h \ + OPC_TreeCollider.cpp OPC_TreeCollider.h \ + OPC_VolumeCollider.cpp OPC_VolumeCollider.h \ + OPC_Settings.h \ + OPC_SphereAABBOverlap.h \ + OPC_BoxBoxOverlap.h \ + OPC_SphereTriOverlap.h \ + OPC_PlanesAABBOverlap.h \ + OPC_TriBoxOverlap.h \ + OPC_IceHook.h \ + OPC_PlanesTriOverlap.h \ + OPC_TriTriOverlap.h \ + OPC_LSSAABBOverlap.h \ + OPC_RayAABBOverlap.h \ + Stdafx.h \ + OPC_LSSTriOverlap.h \ + OPC_RayTriOverlap.h + +all: all-recursive + +.SUFFIXES: +.SUFFIXES: .cpp .lo .o .obj +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign OPCODE/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign OPCODE/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): + +clean-noinstLTLIBRARIES: + -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES) + @list='$(noinst_LTLIBRARIES)'; \ + locs=`for p in $$list; do echo $$p; done | \ + sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ + sort -u`; \ + test -z "$$locs" || { \ + echo rm -f $${locs}; \ + rm -f $${locs}; \ + } + +libOPCODE.la: $(libOPCODE_la_OBJECTS) $(libOPCODE_la_DEPENDENCIES) $(EXTRA_libOPCODE_la_DEPENDENCIES) + $(AM_V_CXXLD)$(CXXLINK) $(libOPCODE_la_OBJECTS) $(libOPCODE_la_LIBADD) $(LIBS) + +mostlyclean-compile: + -rm -f *.$(OBJEXT) + +distclean-compile: + -rm -f *.tab.c + +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/OPC_AABBCollider.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/OPC_AABBTree.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/OPC_BaseModel.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/OPC_Collider.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/OPC_Common.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/OPC_HybridModel.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/OPC_LSSCollider.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/OPC_MeshInterface.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/OPC_Model.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/OPC_OBBCollider.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/OPC_OptimizedTree.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/OPC_Picking.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/OPC_PlanesCollider.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/OPC_RayCollider.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/OPC_SphereCollider.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/OPC_TreeBuilders.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/OPC_TreeCollider.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/OPC_VolumeCollider.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Opcode.Plo@am__quote@ + +.cpp.o: +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ $< + +.cpp.obj: +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'` + +.cpp.lo: +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LTCXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LTCXXCOMPILE) -c -o $@ $< + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +# This directory's subdirectories are mostly independent; you can cd +# into them and run 'make' without going through this Makefile. +# To change the values of 'make' variables: instead of editing Makefiles, +# (1) if the variable is set in 'config.status', edit 'config.status' +# (which will cause the Makefiles to be regenerated when you run 'make'); +# (2) otherwise, pass the desired values on the 'make' command line. +$(am__recursive_targets): + @fail=; \ + if $(am__make_keepgoing); then \ + failcom='fail=yes'; \ + else \ + failcom='exit 1'; \ + fi; \ + dot_seen=no; \ + target=`echo $@ | sed s/-recursive//`; \ + case "$@" in \ + distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ + *) list='$(SUBDIRS)' ;; \ + esac; \ + for subdir in $$list; do \ + echo "Making $$target in $$subdir"; \ + if test "$$subdir" = "."; then \ + dot_seen=yes; \ + local_target="$$target-am"; \ + else \ + local_target="$$target"; \ + fi; \ + ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ + || eval $$failcom; \ + done; \ + if test "$$dot_seen" = "no"; then \ + $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ + fi; test -z "$$fail" + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-recursive +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ + include_option=--etags-include; \ + empty_fix=.; \ + else \ + include_option=--include; \ + empty_fix=; \ + fi; \ + list='$(SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + test ! -f $$subdir/TAGS || \ + set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ + fi; \ + done; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-recursive + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-recursive + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done + @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + $(am__make_dryrun) \ + || test -d "$(distdir)/$$subdir" \ + || $(MKDIR_P) "$(distdir)/$$subdir" \ + || exit 1; \ + dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ + $(am__relativize); \ + new_distdir=$$reldir; \ + dir1=$$subdir; dir2="$(top_distdir)"; \ + $(am__relativize); \ + new_top_distdir=$$reldir; \ + echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ + echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ + ($(am__cd) $$subdir && \ + $(MAKE) $(AM_MAKEFLAGS) \ + top_distdir="$$new_top_distdir" \ + distdir="$$new_distdir" \ + am__remove_distdir=: \ + am__skip_length_check=: \ + am__skip_mode_fix=: \ + distdir) \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-recursive +all-am: Makefile $(LTLIBRARIES) +installdirs: installdirs-recursive +installdirs-am: +install: install-recursive +install-exec: install-exec-recursive +install-data: install-data-recursive +uninstall: uninstall-recursive + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-recursive +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-recursive + +clean-am: clean-generic clean-libtool clean-noinstLTLIBRARIES \ + mostlyclean-am + +distclean: distclean-recursive + -rm -rf ./$(DEPDIR) + -rm -f Makefile +distclean-am: clean-am distclean-compile distclean-generic \ + distclean-tags + +dvi: dvi-recursive + +dvi-am: + +html: html-recursive + +html-am: + +info: info-recursive + +info-am: + +install-data-am: + +install-dvi: install-dvi-recursive + +install-dvi-am: + +install-exec-am: + +install-html: install-html-recursive + +install-html-am: + +install-info: install-info-recursive + +install-info-am: + +install-man: + +install-pdf: install-pdf-recursive + +install-pdf-am: + +install-ps: install-ps-recursive + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-recursive + -rm -rf ./$(DEPDIR) + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-recursive + +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ + mostlyclean-libtool + +pdf: pdf-recursive + +pdf-am: + +ps: ps-recursive + +ps-am: + +uninstall-am: + +.MAKE: $(am__recursive_targets) install-am install-strip + +.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \ + check-am clean clean-generic clean-libtool \ + clean-noinstLTLIBRARIES cscopelist-am ctags ctags-am distclean \ + distclean-compile distclean-generic distclean-libtool \ + distclean-tags distdir dvi dvi-am html html-am info info-am \ + install install-am install-data install-data-am install-dvi \ + install-dvi-am install-exec install-exec-am install-html \ + install-html-am install-info install-info-am install-man \ + install-pdf install-pdf-am install-ps install-ps-am \ + install-strip installcheck installcheck-am installdirs \ + installdirs-am maintainer-clean maintainer-clean-generic \ + mostlyclean mostlyclean-compile mostlyclean-generic \ + mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \ + uninstall-am + +.PRECIOUS: Makefile + + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/libs/ode-0.16.1/OPCODE/OPC_AABBCollider.cpp b/libs/ode-0.16.1/OPCODE/OPC_AABBCollider.cpp new file mode 100644 index 0000000..a192311 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_AABBCollider.cpp @@ -0,0 +1,696 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for an AABB collider. + * \file OPC_AABBCollider.cpp + * \author Pierre Terdiman + * \date January, 1st, 2002 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains an AABB-vs-tree collider. + * + * \class AABBCollider + * \author Pierre Terdiman + * \version 1.3 + * \date January, 1st, 2002 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace Opcode; + +#include "OPC_BoxBoxOverlap.h" +#include "OPC_TriBoxOverlap.h" + +#define SET_CONTACT(prim_index, flag) \ + /* Set contact status */ \ + mFlags |= flag; \ + mTouchedPrimitives->Add(udword(prim_index)); + +//! AABB-triangle test +#define AABB_PRIM(prim_index, flag) \ + /* Request vertices from the app */ \ + VertexPointers VP; ConversionArea VC; mIMesh->GetTriangle(VP, prim_index, VC); \ + mLeafVerts[0] = *VP.Vertex[0]; \ + mLeafVerts[1] = *VP.Vertex[1]; \ + mLeafVerts[2] = *VP.Vertex[2]; \ + /* Perform triangle-box overlap test */ \ + if(TriBoxOverlap()) \ + { \ + SET_CONTACT(prim_index, flag) \ + } + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +AABBCollider::AABBCollider() +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +AABBCollider::~AABBCollider() +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Generic collision query for generic OPCODE models. After the call, access the results: + * - with GetContactStatus() + * - with GetNbTouchedPrimitives() + * - with GetTouchedPrimitives() + * + * \param cache [in/out] a box cache + * \param box [in] collision AABB in world space + * \param model [in] Opcode model to collide with + * \return true if success + * \warning SCALE NOT SUPPORTED. The matrices must contain rotation & translation parts only. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBCollider::Collide(AABBCache& cache, const CollisionAABB& box, const Model& model) +{ + // Checkings + if(!Setup(&model)) return false; + + // Init collision query + if(InitQuery(cache, box)) return true; + + if(!model.HasLeafNodes()) + { + if(model.IsQuantized()) + { + const AABBQuantizedNoLeafTree* Tree = static_cast(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform collision query + if(SkipPrimitiveTests()) _CollideNoPrimitiveTest(Tree->GetNodes()); + else _Collide(Tree->GetNodes()); + } + else + { + const AABBNoLeafTree* Tree = static_cast(model.GetTree()); + + // Perform collision query + if(SkipPrimitiveTests()) _CollideNoPrimitiveTest(Tree->GetNodes()); + else _Collide(Tree->GetNodes()); + } + } + else + { + if(model.IsQuantized()) + { + const AABBQuantizedTree* Tree = static_cast(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform collision query + if(SkipPrimitiveTests()) _CollideNoPrimitiveTest(Tree->GetNodes()); + else _Collide(Tree->GetNodes()); + } + else + { + const AABBCollisionTree* Tree = static_cast(model.GetTree()); + + // Perform collision query + if(SkipPrimitiveTests()) _CollideNoPrimitiveTest(Tree->GetNodes()); + else _Collide(Tree->GetNodes()); + } + } + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Initializes a collision query : + * - reset stats & contact status + * - check temporal coherence + * + * \param cache [in/out] a box cache + * \param box [in] AABB in world space + * \return TRUE if we can return immediately + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +BOOL AABBCollider::InitQuery(AABBCache& cache, const CollisionAABB& box) +{ + // 1) Call the base method + VolumeCollider::InitQuery(); + + // 2) Keep track of the query box + mBox = box; + + // 3) Setup destination pointer + mTouchedPrimitives = &cache.TouchedPrimitives; + + // 4) Special case: 1-triangle meshes [Opcode 1.3] + if(mCurrentModel && mCurrentModel->HasSingleNode()) + { + if(!SkipPrimitiveTests()) + { + // We simply perform the BV-Prim overlap test each time. We assume single triangle has index 0. + mTouchedPrimitives->Reset(); + + // Perform overlap test between the unique triangle and the box (and set contact status if needed) + AABB_PRIM(udword(0), OPC_CONTACT) + + // Return immediately regardless of status + return TRUE; + } + } + + // 5) Check temporal coherence : + if(TemporalCoherenceEnabled()) + { + // Here we use temporal coherence + // => check results from previous frame before performing the collision query + if(FirstContactEnabled()) + { + // We're only interested in the first contact found => test the unique previously touched face + if(mTouchedPrimitives->GetNbEntries()) + { + // Get index of previously touched face = the first entry in the array + udword PreviouslyTouchedFace = mTouchedPrimitives->GetEntry(0); + + // Then reset the array: + // - if the overlap test below is successful, the index we'll get added back anyway + // - if it isn't, then the array should be reset anyway for the normal query + mTouchedPrimitives->Reset(); + + // Perform overlap test between the cached triangle and the box (and set contact status if needed) + AABB_PRIM(PreviouslyTouchedFace, OPC_TEMPORAL_CONTACT) + + // Return immediately if possible + if(GetContactStatus()) return TRUE; + } + // else no face has been touched during previous query + // => we'll have to perform a normal query + } + else + { + // We're interested in all contacts =>test the new real box N(ew) against the previous fat box P(revious): + if(IsCacheValid(cache) && mBox.IsInside(cache.FatBox)) + { + // - if N is included in P, return previous list + // => we simply leave the list (mTouchedFaces) unchanged + + // Set contact status if needed + if(mTouchedPrimitives->GetNbEntries()) mFlags |= OPC_TEMPORAL_CONTACT; + + // In any case we don't need to do a query + return TRUE; + } + else + { + // - else do the query using a fat N + + // Reset cache since we'll about to perform a real query + mTouchedPrimitives->Reset(); + + // Make a fat box so that coherence will work for subsequent frames + mBox.mExtents *= cache.FatCoeff; + + // Update cache with query data (signature for cached faces) + cache.FatBox = mBox; + } + } + } + else + { + // Here we don't use temporal coherence => do a normal query + mTouchedPrimitives->Reset(); + } + + // 5) Precompute min & max bounds if needed + mMin = box.mCenter - box.mExtents; + mMax = box.mCenter + box.mExtents; + + return FALSE; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Collision query for vanilla AABB trees. + * \param cache [in/out] a box cache + * \param box [in] collision AABB in world space + * \param tree [in] AABB tree + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBCollider::Collide(AABBCache& cache, const CollisionAABB& box, const AABBTree* tree) +{ + // This is typically called for a scene tree, full of -AABBs-, not full of triangles. + // So we don't really have "primitives" to deal with. Hence it doesn't work with + // "FirstContact" + "TemporalCoherence". + ASSERT( !(FirstContactEnabled() && TemporalCoherenceEnabled()) ); + + // Checkings + if(!tree) return false; + + // Init collision query + if(InitQuery(cache, box)) return true; + + // Perform collision query + _Collide(tree); + + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Checks the AABB completely contains the box. In which case we can end the query sooner. + * \param bc [in] box center + * \param be [in] box extents + * \return true if the AABB contains the whole box + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +inline_ BOOL AABBCollider::AABBContainsBox(const Point& bc, const Point& be) +{ + if(mMin.x > bc.x - be.x) return FALSE; + if(mMin.y > bc.y - be.y) return FALSE; + if(mMin.z > bc.z - be.z) return FALSE; + + if(mMax.x < bc.x + be.x) return FALSE; + if(mMax.y < bc.y + be.y) return FALSE; + if(mMax.z < bc.z + be.z) return FALSE; + + return TRUE; +} + +#define TEST_BOX_IN_AABB(center, extents) \ + if(AABBContainsBox(center, extents)) \ + { \ + /* Set contact status */ \ + mFlags |= OPC_CONTACT; \ + _Dump(node); \ + return; \ + } + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for normal AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBCollider::_Collide(const AABBCollisionNode* node) +{ + // Perform AABB-AABB overlap test + if(!AABBAABBOverlap(node->mAABB.mExtents, node->mAABB.mCenter)) return; + + TEST_BOX_IN_AABB(node->mAABB.mCenter, node->mAABB.mExtents) + + if(node->IsLeaf()) + { + AABB_PRIM(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _Collide(node->GetPos()); + + if(ContactFound()) return; + + _Collide(node->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for normal AABB trees, without primitive tests. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBCollider::_CollideNoPrimitiveTest(const AABBCollisionNode* node) +{ + // Perform AABB-AABB overlap test + if(!AABBAABBOverlap(node->mAABB.mExtents, node->mAABB.mCenter)) return; + + TEST_BOX_IN_AABB(node->mAABB.mCenter, node->mAABB.mExtents) + + if(node->IsLeaf()) + { + SET_CONTACT(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _CollideNoPrimitiveTest(node->GetPos()); + + if(ContactFound()) return; + + _CollideNoPrimitiveTest(node->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBCollider::_Collide(const AABBQuantizedNode* node) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Perform AABB-AABB overlap test + if(!AABBAABBOverlap(Extents, Center)) return; + + TEST_BOX_IN_AABB(Center, Extents) + + if(node->IsLeaf()) + { + AABB_PRIM(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _Collide(node->GetPos()); + + if(ContactFound()) return; + + _Collide(node->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized AABB trees, without primitive tests. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBCollider::_CollideNoPrimitiveTest(const AABBQuantizedNode* node) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Perform AABB-AABB overlap test + if(!AABBAABBOverlap(Extents, Center)) return; + + TEST_BOX_IN_AABB(Center, Extents) + + if(node->IsLeaf()) + { + SET_CONTACT(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _CollideNoPrimitiveTest(node->GetPos()); + + if(ContactFound()) return; + + _CollideNoPrimitiveTest(node->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for no-leaf AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBCollider::_Collide(const AABBNoLeafNode* node) +{ + // Perform AABB-AABB overlap test + if(!AABBAABBOverlap(node->mAABB.mExtents, node->mAABB.mCenter)) return; + + TEST_BOX_IN_AABB(node->mAABB.mCenter, node->mAABB.mExtents) + + if(node->HasPosLeaf()) { AABB_PRIM(node->GetPosPrimitive(), OPC_CONTACT) } + else _Collide(node->GetPos()); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) { AABB_PRIM(node->GetNegPrimitive(), OPC_CONTACT) } + else _Collide(node->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for no-leaf AABB trees, without primitive tests. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBCollider::_CollideNoPrimitiveTest(const AABBNoLeafNode* node) +{ + // Perform AABB-AABB overlap test + if(!AABBAABBOverlap(node->mAABB.mExtents, node->mAABB.mCenter)) return; + + TEST_BOX_IN_AABB(node->mAABB.mCenter, node->mAABB.mExtents) + + if(node->HasPosLeaf()) { SET_CONTACT(node->GetPosPrimitive(), OPC_CONTACT) } + else _CollideNoPrimitiveTest(node->GetPos()); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) { SET_CONTACT(node->GetNegPrimitive(), OPC_CONTACT) } + else _CollideNoPrimitiveTest(node->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized no-leaf AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBCollider::_Collide(const AABBQuantizedNoLeafNode* node) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Perform AABB-AABB overlap test + if(!AABBAABBOverlap(Extents, Center)) return; + + TEST_BOX_IN_AABB(Center, Extents) + + if(node->HasPosLeaf()) { AABB_PRIM(node->GetPosPrimitive(), OPC_CONTACT) } + else _Collide(node->GetPos()); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) { AABB_PRIM(node->GetNegPrimitive(), OPC_CONTACT) } + else _Collide(node->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized no-leaf AABB trees, without primitive tests. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBCollider::_CollideNoPrimitiveTest(const AABBQuantizedNoLeafNode* node) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Perform AABB-AABB overlap test + if(!AABBAABBOverlap(Extents, Center)) return; + + TEST_BOX_IN_AABB(Center, Extents) + + if(node->HasPosLeaf()) { SET_CONTACT(node->GetPosPrimitive(), OPC_CONTACT) } + else _CollideNoPrimitiveTest(node->GetPos()); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) { SET_CONTACT(node->GetNegPrimitive(), OPC_CONTACT) } + else _CollideNoPrimitiveTest(node->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for vanilla AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBCollider::_Collide(const AABBTreeNode* node) +{ + // Perform AABB-AABB overlap test + Point Center, Extents; + node->GetAABB()->GetCenter(Center); + node->GetAABB()->GetExtents(Extents); + if(!AABBAABBOverlap(Center, Extents)) return; + + if(node->IsLeaf() || AABBContainsBox(Center, Extents)) + { + mFlags |= OPC_CONTACT; + mTouchedPrimitives->Add(node->GetPrimitives(), node->GetNbPrimitives()); + } + else + { + _Collide(node->GetPos()); + _Collide(node->GetNeg()); + } +} + + + + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +HybridAABBCollider::HybridAABBCollider() +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +HybridAABBCollider::~HybridAABBCollider() +{ +} + +bool HybridAABBCollider::Collide(AABBCache& cache, const CollisionAABB& box, const HybridModel& model) +{ + // We don't want primitive tests here! + mFlags |= OPC_NO_PRIMITIVE_TESTS; + + // Checkings + if(!Setup(&model)) return false; + + // Init collision query + if(InitQuery(cache, box)) return true; + + // Special case for 1-leaf trees + if(mCurrentModel && mCurrentModel->HasSingleNode()) + { + // Here we're supposed to perform a normal query, except our tree has a single node, i.e. just a few triangles + udword Nb = mIMesh->GetNbTriangles(); + + // Loop through all triangles + for(udword i=0;i(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform collision query - we don't want primitive tests here! + _CollideNoPrimitiveTest(Tree->GetNodes()); + } + else + { + const AABBNoLeafTree* Tree = static_cast(model.GetTree()); + + // Perform collision query - we don't want primitive tests here! + _CollideNoPrimitiveTest(Tree->GetNodes()); + } + } + else + { + if(model.IsQuantized()) + { + const AABBQuantizedTree* Tree = static_cast(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform collision query - we don't want primitive tests here! + _CollideNoPrimitiveTest(Tree->GetNodes()); + } + else + { + const AABBCollisionTree* Tree = static_cast(model.GetTree()); + + // Perform collision query - we don't want primitive tests here! + _CollideNoPrimitiveTest(Tree->GetNodes()); + } + } + + // We only have a list of boxes so far + if(GetContactStatus()) + { + // Reset contact status, since it currently only reflects collisions with leaf boxes + Collider::InitQuery(); + + // Change dest container so that we can use built-in overlap tests and get collided primitives + cache.TouchedPrimitives.Reset(); + mTouchedPrimitives = &cache.TouchedPrimitives; + + // Read touched leaf boxes + udword Nb = mTouchedBoxes.GetNbEntries(); + const udword* Touched = mTouchedBoxes.GetEntries(); + + const LeafTriangles* LT = model.GetLeafTriangles(); + const udword* Indices = model.GetIndices(); + + // Loop through touched leaves + while(Nb--) + { + const LeafTriangles& CurrentLeaf = LT[*Touched++]; + + // Each leaf box has a set of triangles + udword NbTris = CurrentLeaf.GetNbTriangles(); + if(Indices) + { + const udword* T = &Indices[CurrentLeaf.GetTriangleIndex()]; + + // Loop through triangles and test each of them + while(NbTris--) + { + udword TriangleIndex = *T++; + AABB_PRIM(TriangleIndex, OPC_CONTACT) + } + } + else + { + udword BaseIndex = CurrentLeaf.GetTriangleIndex(); + + // Loop through triangles and test each of them + while(NbTris--) + { + udword TriangleIndex = BaseIndex++; + AABB_PRIM(TriangleIndex, OPC_CONTACT) + } + } + } + } + + return true; +} diff --git a/libs/ode-0.16.1/OPCODE/OPC_AABBCollider.h b/libs/ode-0.16.1/OPCODE/OPC_AABBCollider.h new file mode 100644 index 0000000..315d2d3 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_AABBCollider.h @@ -0,0 +1,97 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for an AABB collider. + * \file OPC_AABBCollider.h + * \author Pierre Terdiman + * \date January, 1st, 2002 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __OPC_AABBCOLLIDER_H__ +#define __OPC_AABBCOLLIDER_H__ + + struct OPCODE_API AABBCache : VolumeCache + { + AABBCache() : FatCoeff(1.1f) + { + FatBox.mCenter.Zero(); + FatBox.mExtents.Zero(); + } + + // Cached faces signature + CollisionAABB FatBox; //!< Box used when performing the query resulting in cached faces + // User settings + float FatCoeff; //!< mRadius2 multiplier used to create a fat sphere + }; + + class OPCODE_API AABBCollider : public VolumeCollider + { + public: + // Constructor / Destructor + AABBCollider(); + virtual ~AABBCollider(); + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Generic collision query for generic OPCODE models. After the call, access the results: + * - with GetContactStatus() + * - with GetNbTouchedPrimitives() + * - with GetTouchedPrimitives() + * + * \param cache [in/out] a box cache + * \param box [in] collision AABB in world space + * \param model [in] Opcode model to collide with + * \return true if success + * \warning SCALE NOT SUPPORTED. The matrices must contain rotation & translation parts only. + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + bool Collide(AABBCache& cache, const CollisionAABB& box, const Model& model); + // + bool Collide(AABBCache& cache, const CollisionAABB& box, const AABBTree* tree); + protected: + CollisionAABB mBox; //!< Query box in (center, extents) form + Point mMin; //!< Query box min point + Point mMax; //!< Query box max point + // Leaf description + Point mLeafVerts[3]; //!< Triangle vertices + // Internal methods + void _Collide(const AABBCollisionNode* node); + void _Collide(const AABBNoLeafNode* node); + void _Collide(const AABBQuantizedNode* node); + void _Collide(const AABBQuantizedNoLeafNode* node); + void _Collide(const AABBTreeNode* node); + void _CollideNoPrimitiveTest(const AABBCollisionNode* node); + void _CollideNoPrimitiveTest(const AABBNoLeafNode* node); + void _CollideNoPrimitiveTest(const AABBQuantizedNode* node); + void _CollideNoPrimitiveTest(const AABBQuantizedNoLeafNode* node); + // Overlap tests + inline_ BOOL AABBContainsBox(const Point& bc, const Point& be); + inline_ BOOL AABBAABBOverlap(const Point& b, const Point& Pb); + inline_ BOOL TriBoxOverlap(); + // Init methods + BOOL InitQuery(AABBCache& cache, const CollisionAABB& box); + }; + + class OPCODE_API HybridAABBCollider : public AABBCollider + { + public: + // Constructor / Destructor + HybridAABBCollider(); + virtual ~HybridAABBCollider(); + + bool Collide(AABBCache& cache, const CollisionAABB& box, const HybridModel& model); + protected: + Container mTouchedBoxes; + }; + +#endif // __OPC_AABBCOLLIDER_H__ diff --git a/libs/ode-0.16.1/OPCODE/OPC_AABBTree.cpp b/libs/ode-0.16.1/OPCODE/OPC_AABBTree.cpp new file mode 100644 index 0000000..48129a8 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_AABBTree.cpp @@ -0,0 +1,568 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for a versatile AABB tree. + * \file OPC_AABBTree.cpp + * \author Pierre Terdiman + * \date March, 20, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains a generic AABB tree node. + * + * \class AABBTreeNode + * \author Pierre Terdiman + * \version 1.3 + * \date March, 20, 2001 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains a generic AABB tree. + * This is a vanilla AABB tree, without any particular optimization. It contains anonymous references to + * user-provided primitives, which can theoretically be anything - triangles, boxes, etc. Each primitive + * is surrounded by an AABB, regardless of the primitive's nature. When the primitive is a triangle, the + * resulting tree can be converted into an optimized tree. If the primitive is a box, the resulting tree + * can be used for culling - VFC or occlusion -, assuming you cull on a mesh-by-mesh basis (modern way). + * + * \class AABBTree + * \author Pierre Terdiman + * \version 1.3 + * \date March, 20, 2001 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace Opcode; + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +AABBTreeNode::AABBTreeNode() : + mPos (null), +#ifndef OPC_NO_NEG_VANILLA_TREE + mNeg (null), +#endif + mNodePrimitives (null), + mNbPrimitives (0) +{ +#ifdef OPC_USE_TREE_COHERENCE + mBitmask = 0; +#endif +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +AABBTreeNode::~AABBTreeNode() +{ + // Opcode 1.3: + const AABBTreeNode* Pos = GetPos(); +#ifndef OPC_NO_NEG_VANILLA_TREE + const AABBTreeNode* Neg = GetNeg(); + if(!(mPos&1)) DELETESINGLE(Pos); + if(!(mNeg&1)) DELETESINGLE(Neg); +#else + if(!(mPos&1)) DELETEARRAY(Pos); +#endif + mNodePrimitives = null; // This was just a shortcut to the global list => no release + mNbPrimitives = 0; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Splits the node along a given axis. + * The list of indices is reorganized according to the split values. + * \param axis [in] splitting axis index + * \param builder [in] the tree builder + * \return the number of primitives assigned to the first child + * \warning this method reorganizes the internal list of primitives + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +udword AABBTreeNode::Split(udword axis, AABBTreeBuilder* builder) +{ + // Get node split value + float SplitValue = builder->GetSplittingValue(mNodePrimitives, mNbPrimitives, mBV, axis); + + udword NbPos = 0; + // Loop through all node-related primitives. Their indices range from mNodePrimitives[0] to mNodePrimitives[mNbPrimitives-1]. + // Those indices map the global list in the tree builder. + for(udword i=0;iGetSplittingValue(Index, axis); + + // Reorganize the list of indices in this order: positive - negative. + if(PrimitiveValue > SplitValue) + { + // Swap entries + udword Tmp = mNodePrimitives[i]; + mNodePrimitives[i] = mNodePrimitives[NbPos]; + mNodePrimitives[NbPos] = Tmp; + // Count primitives assigned to positive space + NbPos++; + } + } + return NbPos; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Subdivides the node. + * + * N + * / \ + * / \ + * N/2 N/2 + * / \ / \ + * N/4 N/4 N/4 N/4 + * (etc) + * + * A well-balanced tree should have a O(log n) depth. + * A degenerate tree would have a O(n) depth. + * Note a perfectly-balanced tree is not well-suited to collision detection anyway. + * + * \param builder [in] the tree builder + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBTreeNode::Subdivide(AABBTreeBuilder* builder) +{ + // Checkings + if(!builder) return false; + + // Stop subdividing if we reach a leaf node. This is always performed here, + // else we could end in trouble if user overrides this. + if(mNbPrimitives==1) return true; + + // Let the user validate the subdivision + if(!builder->ValidateSubdivision(mNodePrimitives, mNbPrimitives, mBV)) return true; + + bool ValidSplit = true; // Optimism... + udword NbPos; + if(builder->mSettings.mRules & SPLIT_LARGEST_AXIS) + { + // Find the largest axis to split along + Point Extents; mBV.GetExtents(Extents); // Box extents + udword Axis = Extents.LargestAxis(); // Index of largest axis + + // Split along the axis + NbPos = Split(Axis, builder); + + // Check split validity + if(!NbPos || NbPos==mNbPrimitives) ValidSplit = false; + } + else if(builder->mSettings.mRules & SPLIT_SPLATTER_POINTS) + { + // Compute the means + Point Means(0.0f, 0.0f, 0.0f); + for(udword i=0;iGetSplittingValues(Index); + } + Means/=float(mNbPrimitives); + + // Compute variances + Point Vars(0.0f, 0.0f, 0.0f); + for(udword i=0;iGetSplittingValues(Index); + Point Delta = Center - Means; + Vars += Delta * Delta; + } + Vars/=float(mNbPrimitives-1); + + // Choose axis with greatest variance + udword Axis = Vars.LargestAxis(); + + // Split along the axis + NbPos = Split(Axis, builder); + + // Check split validity + if(!NbPos || NbPos==mNbPrimitives) ValidSplit = false; + } + else if(builder->mSettings.mRules & SPLIT_BALANCED) + { + // Test 3 axis, take the best + float Results[3]; + NbPos = Split(0, builder); Results[0] = float(NbPos)/float(mNbPrimitives); + NbPos = Split(1, builder); Results[1] = float(NbPos)/float(mNbPrimitives); + NbPos = Split(2, builder); Results[2] = float(NbPos)/float(mNbPrimitives); + Results[0]-=0.5f; Results[0]*=Results[0]; + Results[1]-=0.5f; Results[1]*=Results[1]; + Results[2]-=0.5f; Results[2]*=Results[2]; + udword Min=0; + if(Results[1]mSettings.mRules & SPLIT_BEST_AXIS) + { + // Test largest, then middle, then smallest axis... + + // Sort axis + Point Extents; mBV.GetExtents(Extents); // Box extents + udword SortedAxis[] = { 0, 1, 2 }; + float* Keys = (float*)&Extents.x; + for(udword j=0;j<3;j++) + { + for(udword i=0;i<2;i++) + { + if(Keys[SortedAxis[i]]mSettings.mRules & SPLIT_FIFTY) + { + // Don't even bother splitting (mainly a performance test) + NbPos = mNbPrimitives>>1; + } + else return false; // Unknown splitting rules + + // Check the subdivision has been successful + if(!ValidSplit) + { + // Here, all boxes lie in the same sub-space. Two strategies: + // - if the tree *must* be complete, make an arbitrary 50-50 split + // - else stop subdividing +// if(builder->mSettings.mRules&SPLIT_COMPLETE) + if(builder->mSettings.mLimit==1) + { + builder->IncreaseNbInvalidSplits(); + NbPos = mNbPrimitives>>1; + } + else return true; + } + + // Now create children and assign their pointers. + if(builder->mNodeBase) + { + // We use a pre-allocated linear pool for complete trees [Opcode 1.3] + AABBTreeNode* Pool = (AABBTreeNode*)builder->mNodeBase; + udword Count = builder->GetCount() - 1; // Count begins to 1... + // Set last bit to tell it shouldn't be freed ### pretty ugly, find a better way. Maybe one bit in mNbPrimitives + ASSERT(!(udword(&Pool[Count+0])&1)); + ASSERT(!(udword(&Pool[Count+1])&1)); + mPos = size_t(&Pool[Count+0])|1; +#ifndef OPC_NO_NEG_VANILLA_TREE + mNeg = size_t(&Pool[Count+1])|1; +#endif + } + else + { + // Non-complete trees and/or Opcode 1.2 allocate nodes on-the-fly +#ifndef OPC_NO_NEG_VANILLA_TREE + mPos = (size_t)new AABBTreeNode; CHECKALLOC(mPos); + mNeg = (size_t)new AABBTreeNode; CHECKALLOC(mNeg); +#else + AABBTreeNode* PosNeg = new AABBTreeNode[2]; + CHECKALLOC(PosNeg); + mPos = (size_t)PosNeg; +#endif + } + + // Update stats + builder->IncreaseCount(2); + + // Assign children + AABBTreeNode* Pos = const_cast(GetPos()); + AABBTreeNode* Neg = const_cast(GetNeg()); + Pos->mNodePrimitives = &mNodePrimitives[0]; + Pos->mNbPrimitives = NbPos; + Neg->mNodePrimitives = &mNodePrimitives[NbPos]; + Neg->mNbPrimitives = mNbPrimitives - NbPos; + + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive hierarchy building in a top-down fashion. + * \param builder [in] the tree builder + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBTreeNode::_BuildHierarchy(AABBTreeBuilder* builder) +{ + // 1) Compute the global box for current node. The box is stored in mBV. + builder->ComputeGlobalBox(mNodePrimitives, mNbPrimitives, mBV); + + // 2) Subdivide current node + Subdivide(builder); + + // 3) Recurse + AABBTreeNode* Pos = const_cast(GetPos()); + AABBTreeNode* Neg = const_cast(GetNeg()); + if(Pos) Pos->_BuildHierarchy(builder); + if(Neg) Neg->_BuildHierarchy(builder); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Refits the tree (top-down). + * \param builder [in] the tree builder + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBTreeNode::_Refit(AABBTreeBuilder* builder) +{ + // 1) Recompute the new global box for current node + builder->ComputeGlobalBox(mNodePrimitives, mNbPrimitives, mBV); + + // 2) Recurse + AABBTreeNode* Pos = const_cast(GetPos()); + AABBTreeNode* Neg = const_cast(GetNeg()); + if(Pos) Pos->_Refit(builder); + if(Neg) Neg->_Refit(builder); +} + + + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +AABBTree::AABBTree() : mIndices(null), mPool(null), mTotalNbNodes(0) +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +AABBTree::~AABBTree() +{ + Release(); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Releases the tree. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBTree::Release() +{ + DELETEARRAY(mPool); + DELETEARRAY(mIndices); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Builds a generic AABB tree from a tree builder. + * \param builder [in] the tree builder + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBTree::Build(AABBTreeBuilder* builder) +{ + // Checkings + if(!builder || !builder->mNbPrimitives) return false; + + // Release previous tree + Release(); + + // Init stats + builder->SetCount(1); + builder->SetNbInvalidSplits(0); + + // Initialize indices. This list will be modified during build. + mIndices = new dTriIndex[builder->mNbPrimitives]; + CHECKALLOC(mIndices); + // Identity permutation + for(udword i=0;imNbPrimitives;i++) mIndices[i] = i; + + // Setup initial node. Here we have a complete permutation of the app's primitives. + mNodePrimitives = mIndices; + mNbPrimitives = builder->mNbPrimitives; + + // Use a linear array for complete trees (since we can predict the final number of nodes) [Opcode 1.3] +// if(builder->mRules&SPLIT_COMPLETE) + if(builder->mSettings.mLimit==1) + { + // Allocate a pool of nodes + mPool = new AABBTreeNode[builder->mNbPrimitives*2 - 1]; + + builder->mNodeBase = mPool; // ### ugly ! + } + + // Build the hierarchy + _BuildHierarchy(builder); + + // Get back total number of nodes + mTotalNbNodes = builder->GetCount(); + + // For complete trees, check the correct number of nodes has been created [Opcode 1.3] + if(mPool) ASSERT(mTotalNbNodes==builder->mNbPrimitives*2 - 1); + + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the depth of the tree. + * A well-balanced tree should have a log(n) depth. A degenerate tree O(n) depth. + * \return depth of the tree + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +udword AABBTree::ComputeDepth() const +{ + return Walk(null, null); // Use the walking code without callback +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Walks the tree, calling the user back for each node. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +udword AABBTree::Walk(WalkingCallback callback, void* user_data) const +{ + // Call it without callback to compute max depth + udword MaxDepth = 0; + udword CurrentDepth = 0; + + struct Local + { + static void _Walk(const AABBTreeNode* current_node, udword& max_depth, udword& current_depth, WalkingCallback callback, void* user_data) + { + // Checkings + if(!current_node) return; + // Entering a new node => increase depth + current_depth++; + // Keep track of max depth + if(current_depth>max_depth) max_depth = current_depth; + + // Callback + if(callback && !(callback)(current_node, current_depth, user_data)) return; + + // Recurse + if(current_node->GetPos()) { _Walk(current_node->GetPos(), max_depth, current_depth, callback, user_data); current_depth--; } + if(current_node->GetNeg()) { _Walk(current_node->GetNeg(), max_depth, current_depth, callback, user_data); current_depth--; } + } + }; + Local::_Walk(this, MaxDepth, CurrentDepth, callback, user_data); + return MaxDepth; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Refits the tree in a top-down way. + * \param builder [in] the tree builder + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBTree::Refit(AABBTreeBuilder* builder) +{ + if(!builder) return false; + _Refit(builder); + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Refits the tree in a bottom-up way. + * \param builder [in] the tree builder + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBTree::Refit2(AABBTreeBuilder* builder) +{ + // Checkings + if(!builder) return false; + + ASSERT(mPool); + + // Bottom-up update + Point Min,Max; + Point Min_,Max_; + udword Index = mTotalNbNodes; + while(Index--) + { + AABBTreeNode& Current = mPool[Index]; + + if(Current.IsLeaf()) + { + builder->ComputeGlobalBox(Current.GetPrimitives(), Current.GetNbPrimitives(), *const_cast(Current.GetAABB())); + } + else + { + Current.GetPos()->GetAABB()->GetMin(Min); + Current.GetPos()->GetAABB()->GetMax(Max); + + Current.GetNeg()->GetAABB()->GetMin(Min_); + Current.GetNeg()->GetAABB()->GetMax(Max_); + + Min.Min(Min_); + Max.Max(Max_); + + const_cast(Current.GetAABB())->SetMinMax(Min, Max); + } + } + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the number of bytes used by the tree. + * \return number of bytes used + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +udword AABBTree::GetUsedBytes() const +{ + udword TotalSize = mTotalNbNodes*GetNodeSize(); + if(mIndices) TotalSize+=mNbPrimitives*sizeof(udword); + return TotalSize; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Checks the tree is a complete tree or not. + * A complete tree is made of 2*N-1 nodes, where N is the number of primitives in the tree. + * \return true for complete trees + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBTree::IsComplete() const +{ + return (GetNbNodes()==GetNbPrimitives()*2-1); +} diff --git a/libs/ode-0.16.1/OPCODE/OPC_AABBTree.h b/libs/ode-0.16.1/OPCODE/OPC_AABBTree.h new file mode 100644 index 0000000..681be9d --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_AABBTree.h @@ -0,0 +1,137 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for a versatile AABB tree. + * \file OPC_AABBTree.h + * \author Pierre Terdiman + * \date March, 20, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __OPC_AABBTREE_H__ +#define __OPC_AABBTREE_H__ + +#ifdef OPC_NO_NEG_VANILLA_TREE + //! TO BE DOCUMENTED + #define IMPLEMENT_TREE(base_class, volume) \ + public: \ + /* Constructor / Destructor */ \ + base_class(); \ + ~base_class(); \ + /* Data access */ \ + inline_ const volume* Get##volume() const { return &mBV; } \ + /* Clear the last bit */ \ + inline_ const base_class* GetPos() const { return (const base_class*)(mPos&~1); } \ + inline_ const base_class* GetNeg() const { const base_class* P = GetPos(); return P ? P+1 : null;} \ + \ + /* We don't need to test both nodes since we can't have one without the other */ \ + inline_ bool IsLeaf() const { return !GetPos(); } \ + \ + /* Stats */ \ + inline_ udword GetNodeSize() const { return SIZEOFOBJECT; } \ + protected: \ + /* Tree-independent data */ \ + /* Following data always belong to the BV-tree, regardless of what the tree actually contains.*/ \ + /* Whatever happens we need the two children and the enclosing volume.*/ \ + volume mBV; /* Global bounding-volume enclosing all the node-related primitives */ \ + size_t mPos; /* "Positive" & "Negative" children */ +#else + //! TO BE DOCUMENTED + #define IMPLEMENT_TREE(base_class, volume) \ + public: \ + /* Constructor / Destructor */ \ + base_class(); \ + ~base_class(); \ + /* Data access */ \ + inline_ const volume* Get##volume() const { return &mBV; } \ + /* Clear the last bit */ \ + inline_ const base_class* GetPos() const { return (const base_class*)(mPos&~1); } \ + inline_ const base_class* GetNeg() const { return (const base_class*)(mNeg&~1); } \ + \ +/* inline_ bool IsLeaf() const { return (!GetPos() && !GetNeg()); } */ \ + /* We don't need to test both nodes since we can't have one without the other */ \ + inline_ bool IsLeaf() const { return !GetPos(); } \ + \ + /* Stats */ \ + inline_ udword GetNodeSize() const { return SIZEOFOBJECT; } \ + protected: \ + /* Tree-independent data */ \ + /* Following data always belong to the BV-tree, regardless of what the tree actually contains.*/ \ + /* Whatever happens we need the two children and the enclosing volume.*/ \ + volume mBV; /* Global bounding-volume enclosing all the node-related primitives */ \ + size_t mPos; /* "Positive" child */ \ + size_t mNeg; /* "Negative" child */ +#endif + + typedef void (*CullingCallback) (udword nb_primitives, udword* node_primitives, BOOL need_clipping, void* user_data); + + class OPCODE_API AABBTreeNode + { + IMPLEMENT_TREE(AABBTreeNode, AABB) + public: + // Data access + inline_ const dTriIndex* GetPrimitives() const { return mNodePrimitives; } + inline_ udword GetNbPrimitives() const { return mNbPrimitives; } + + protected: + // Tree-dependent data + dTriIndex* mNodePrimitives; //!< Node-related primitives (shortcut to a position in mIndices below) + udword mNbPrimitives; //!< Number of primitives for this node + // Internal methods + udword Split(udword axis, AABBTreeBuilder* builder); + bool Subdivide(AABBTreeBuilder* builder); + void _BuildHierarchy(AABBTreeBuilder* builder); + void _Refit(AABBTreeBuilder* builder); + }; + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * User-callback, called for each node by the walking code. + * \param current [in] current node + * \param depth [in] current node's depth + * \param user_data [in] user-defined data + * \return true to recurse through children, else false to bypass them + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + typedef bool (*WalkingCallback) (const AABBTreeNode* current, udword depth, void* user_data); + + class OPCODE_API AABBTree : public AABBTreeNode + { + public: + // Constructor / Destructor + AABBTree(); + ~AABBTree(); + // Build + bool Build(AABBTreeBuilder* builder); + void Release(); + + // Data access + inline_ const dTriIndex* GetIndices() const { return mIndices; } //!< Catch the indices + inline_ udword GetNbNodes() const { return mTotalNbNodes; } //!< Catch the number of nodes + + // Infos + bool IsComplete() const; + // Stats + udword ComputeDepth() const; + udword GetUsedBytes() const; + udword Walk(WalkingCallback callback, void* user_data) const; + + bool Refit(AABBTreeBuilder* builder); + bool Refit2(AABBTreeBuilder* builder); + private: + dTriIndex* mIndices; //!< Indices in the app list. Indices are reorganized during build (permutation). + AABBTreeNode* mPool; //!< Linear pool of nodes for complete trees. Null otherwise. [Opcode 1.3] + // Stats + udword mTotalNbNodes; //!< Number of nodes in the tree. + }; + +#endif // __OPC_AABBTREE_H__ diff --git a/libs/ode-0.16.1/OPCODE/OPC_BaseModel.cpp b/libs/ode-0.16.1/OPCODE/OPC_BaseModel.cpp new file mode 100644 index 0000000..987c4f9 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_BaseModel.cpp @@ -0,0 +1,119 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains base model interface. + * \file OPC_BaseModel.cpp + * \author Pierre Terdiman + * \date May, 18, 2003 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * The base class for collision models. + * + * \class BaseModel + * \author Pierre Terdiman + * \version 1.3 + * \date May, 18, 2003 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace Opcode; + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +BaseModel::BaseModel() : mIMesh(null), mModelCode(0), mSource(null), mTree(null) +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +BaseModel::~BaseModel() +{ + ReleaseBase(); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Releases everything. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void BaseModel::ReleaseBase() +{ + DELETESINGLE(mSource); + DELETESINGLE(mTree); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Creates an optimized tree according to user-settings, and setups mModelCode. + * \param no_leaf [in] true for "no leaf" tree + * \param quantized [in] true for quantized tree + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool BaseModel::CreateTree(bool no_leaf, bool quantized) +{ + DELETESINGLE(mTree); + + // Setup model code + if(no_leaf) mModelCode |= OPC_NO_LEAF; + else mModelCode &= ~OPC_NO_LEAF; + + if(quantized) mModelCode |= OPC_QUANTIZED; + else mModelCode &= ~OPC_QUANTIZED; + + // Create the correct class + if(mModelCode & OPC_NO_LEAF) + { + if(mModelCode & OPC_QUANTIZED) mTree = new AABBQuantizedNoLeafTree; + else mTree = new AABBNoLeafTree; + } + else + { + if(mModelCode & OPC_QUANTIZED) mTree = new AABBQuantizedTree; + else mTree = new AABBCollisionTree; + } + CHECKALLOC(mTree); + + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Refits the collision model. This can be used to handle dynamic meshes. Usage is: + * 1. modify your mesh vertices (keep the topology constant!) + * 2. refit the tree (call this method) + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool BaseModel::Refit() +{ + // Refit the optimized tree + return mTree->Refit(mIMesh); + +// Old code kept for reference : refit the source tree then rebuild ! +// if(!mSource) return false; +// // Ouch... +// mSource->Refit(&mTB); +// // Ouch... +// return mTree->Build(mSource); +} diff --git a/libs/ode-0.16.1/OPCODE/OPC_BaseModel.h b/libs/ode-0.16.1/OPCODE/OPC_BaseModel.h new file mode 100644 index 0000000..eef77a6 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_BaseModel.h @@ -0,0 +1,199 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains base model interface. + * \file OPC_BaseModel.h + * \author Pierre Terdiman + * \date May, 18, 2003 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __OPC_BASEMODEL_H__ +#define __OPC_BASEMODEL_H__ + + //! Model creation structure + struct OPCODE_API OPCODECREATE + { + //! Constructor + inline_ OPCODECREATE(): + mIMesh(null), + mSettings(SPLIT_SPLATTER_POINTS | SPLIT_GEOM_CENTER), + mNoLeaf(true), + mQuantized(true), +#ifdef __MESHMERIZER_H__ + mCollisionHull(false), +#endif // __MESHMERIZER_H__ + mKeepOriginal(false), + mCanRemap(false) + { + } + + inline_ OPCODECREATE(MeshInterface *IMesh, const BuildSettings &Settings, bool NoLeaf, bool Quantized): + mIMesh(IMesh), + mSettings(Settings), + mNoLeaf(NoLeaf), + mQuantized(Quantized), +#ifdef __MESHMERIZER_H__ + mCollisionHull(false), +#endif // __MESHMERIZER_H__ + mKeepOriginal(false), + mCanRemap(false) + { + } + + MeshInterface* mIMesh; //!< Mesh interface (access to triangles & vertices) (*) + BuildSettings mSettings; //!< Builder's settings + bool mNoLeaf; //!< true => discard leaf nodes (else use a normal tree) + bool mQuantized; //!< true => quantize the tree (else use a normal tree) +#ifdef __MESHMERIZER_H__ + bool mCollisionHull; //!< true => use convex hull + GJK +#endif // __MESHMERIZER_H__ + bool mKeepOriginal; //!< true => keep a copy of the original tree (debug purpose) + bool mCanRemap; //!< true => allows OPCODE to reorganize client arrays + + // (*) This pointer is saved internally and used by OPCODE until collision structures are released, + // so beware of the object's lifetime. + }; + + enum ModelFlag + { + OPC_QUANTIZED = (1<<0), //!< Compressed/uncompressed tree + OPC_NO_LEAF = (1<<1), //!< Leaf/NoLeaf tree + OPC_SINGLE_NODE = (1<<2) //!< Special case for 1-node models + }; + + class OPCODE_API BaseModel + { + public: + // Constructor/Destructor + BaseModel(); + virtual ~BaseModel(); + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Builds a collision model. + * \param create [in] model creation structure + * \return true if success + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + virtual bool Build(const OPCODECREATE& create) = 0; + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets the number of bytes used by the tree. + * \return amount of bytes used + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + virtual udword GetUsedBytes() const = 0; + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Refits the collision model. This can be used to handle dynamic meshes. Usage is: + * 1. modify your mesh vertices (keep the topology constant!) + * 2. refit the tree (call this method) + * \return true if success + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + virtual bool Refit(); + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets the source tree. + * \return generic tree + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ const AABBTree* GetSourceTree() const { return mSource; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets the tree. + * \return the collision tree + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ const AABBOptimizedTree* GetTree() const { return mTree; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets the tree. + * \return the collision tree + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ AABBOptimizedTree* GetTree() { return mTree; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets the number of nodes in the tree. + * Should be 2*N-1 for normal trees and N-1 for optimized ones. + * \return number of nodes + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ udword GetNbNodes() const { return mTree->GetNbNodes(); } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Checks whether the tree has leaf nodes or not. + * \return true if the tree has leaf nodes (normal tree), else false (optimized tree) + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ BOOL HasLeafNodes() const { return !(mModelCode & OPC_NO_LEAF); } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Checks whether the tree is quantized or not. + * \return true if the tree is quantized + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ BOOL IsQuantized() const { return mModelCode & OPC_QUANTIZED; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Checks whether the model has a single node or not. This special case must be handled separately. + * \return true if the model has only 1 node + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ BOOL HasSingleNode() const { return mModelCode & OPC_SINGLE_NODE; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets the model's code. + * \return model's code + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ udword GetModelCode() const { return mModelCode; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets the mesh interface. + * \return mesh interface + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ const MeshInterface* GetMeshInterface() const { return mIMesh; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Sets the mesh interface. + * \param imesh [in] mesh interface + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void SetMeshInterface(const MeshInterface* imesh) { mIMesh = imesh; } + + protected: + const MeshInterface* mIMesh; //!< User-defined mesh interface + udword mModelCode; //!< Model code = combination of ModelFlag(s) + AABBTree* mSource; //!< Original source tree + AABBOptimizedTree* mTree; //!< Optimized tree owned by the model + // Internal methods + void ReleaseBase(); + bool CreateTree(bool no_leaf, bool quantized); + }; + +#endif //__OPC_BASEMODEL_H__ diff --git a/libs/ode-0.16.1/OPCODE/OPC_BoxBoxOverlap.h b/libs/ode-0.16.1/OPCODE/OPC_BoxBoxOverlap.h new file mode 100644 index 0000000..757a17d --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_BoxBoxOverlap.h @@ -0,0 +1,122 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * OBB-OBB overlap test using the separating axis theorem. + * - original code by Gomez / Gamasutra (similar to Gottschalk's one in RAPID) + * - optimized for AABB trees by computing the rotation matrix once (SOLID-fashion) + * - the fabs matrix is precomputed as well and epsilon-tweaked (RAPID-style, we found this almost mandatory) + * - Class III axes can be disabled... (SOLID & Intel fashion) + * - ...or enabled to perform some profiling + * - CPU comparisons used when appropriate + * - lazy evaluation sometimes saves some work in case of early exits (unlike SOLID) + * + * \param ea [in] extents from box A + * \param ca [in] center from box A + * \param eb [in] extents from box B + * \param cb [in] center from box B + * \return true if boxes overlap + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +inline_ BOOL AABBTreeCollider::BoxBoxOverlap(const Point& ea, const Point& ca, const Point& eb, const Point& cb) +{ + // Stats + mNbBVBVTests++; + + float t,t2; + + // Class I : A's basis vectors + float Tx = (mR1to0.m[0][0]*cb.x + mR1to0.m[1][0]*cb.y + mR1to0.m[2][0]*cb.z) + mT1to0.x - ca.x; + t = ea.x + eb.x*mAR.m[0][0] + eb.y*mAR.m[1][0] + eb.z*mAR.m[2][0]; + if(GREATER(Tx, t)) return FALSE; + + float Ty = (mR1to0.m[0][1]*cb.x + mR1to0.m[1][1]*cb.y + mR1to0.m[2][1]*cb.z) + mT1to0.y - ca.y; + t = ea.y + eb.x*mAR.m[0][1] + eb.y*mAR.m[1][1] + eb.z*mAR.m[2][1]; + if(GREATER(Ty, t)) return FALSE; + + float Tz = (mR1to0.m[0][2]*cb.x + mR1to0.m[1][2]*cb.y + mR1to0.m[2][2]*cb.z) + mT1to0.z - ca.z; + t = ea.z + eb.x*mAR.m[0][2] + eb.y*mAR.m[1][2] + eb.z*mAR.m[2][2]; + if(GREATER(Tz, t)) return FALSE; + + // Class II : B's basis vectors + t = Tx*mR1to0.m[0][0] + Ty*mR1to0.m[0][1] + Tz*mR1to0.m[0][2]; t2 = ea.x*mAR.m[0][0] + ea.y*mAR.m[0][1] + ea.z*mAR.m[0][2] + eb.x; + if(GREATER(t, t2)) return FALSE; + + t = Tx*mR1to0.m[1][0] + Ty*mR1to0.m[1][1] + Tz*mR1to0.m[1][2]; t2 = ea.x*mAR.m[1][0] + ea.y*mAR.m[1][1] + ea.z*mAR.m[1][2] + eb.y; + if(GREATER(t, t2)) return FALSE; + + t = Tx*mR1to0.m[2][0] + Ty*mR1to0.m[2][1] + Tz*mR1to0.m[2][2]; t2 = ea.x*mAR.m[2][0] + ea.y*mAR.m[2][1] + ea.z*mAR.m[2][2] + eb.z; + if(GREATER(t, t2)) return FALSE; + + // Class III : 9 cross products + // Cool trick: always perform the full test for first level, regardless of settings. + // That way pathological cases (such as the pencils scene) are quickly rejected anyway ! + if(mFullBoxBoxTest || mNbBVBVTests==1) + { + t = Tz*mR1to0.m[0][1] - Ty*mR1to0.m[0][2]; t2 = ea.y*mAR.m[0][2] + ea.z*mAR.m[0][1] + eb.y*mAR.m[2][0] + eb.z*mAR.m[1][0]; if(GREATER(t, t2)) return FALSE; // L = A0 x B0 + t = Tz*mR1to0.m[1][1] - Ty*mR1to0.m[1][2]; t2 = ea.y*mAR.m[1][2] + ea.z*mAR.m[1][1] + eb.x*mAR.m[2][0] + eb.z*mAR.m[0][0]; if(GREATER(t, t2)) return FALSE; // L = A0 x B1 + t = Tz*mR1to0.m[2][1] - Ty*mR1to0.m[2][2]; t2 = ea.y*mAR.m[2][2] + ea.z*mAR.m[2][1] + eb.x*mAR.m[1][0] + eb.y*mAR.m[0][0]; if(GREATER(t, t2)) return FALSE; // L = A0 x B2 + t = Tx*mR1to0.m[0][2] - Tz*mR1to0.m[0][0]; t2 = ea.x*mAR.m[0][2] + ea.z*mAR.m[0][0] + eb.y*mAR.m[2][1] + eb.z*mAR.m[1][1]; if(GREATER(t, t2)) return FALSE; // L = A1 x B0 + t = Tx*mR1to0.m[1][2] - Tz*mR1to0.m[1][0]; t2 = ea.x*mAR.m[1][2] + ea.z*mAR.m[1][0] + eb.x*mAR.m[2][1] + eb.z*mAR.m[0][1]; if(GREATER(t, t2)) return FALSE; // L = A1 x B1 + t = Tx*mR1to0.m[2][2] - Tz*mR1to0.m[2][0]; t2 = ea.x*mAR.m[2][2] + ea.z*mAR.m[2][0] + eb.x*mAR.m[1][1] + eb.y*mAR.m[0][1]; if(GREATER(t, t2)) return FALSE; // L = A1 x B2 + t = Ty*mR1to0.m[0][0] - Tx*mR1to0.m[0][1]; t2 = ea.x*mAR.m[0][1] + ea.y*mAR.m[0][0] + eb.y*mAR.m[2][2] + eb.z*mAR.m[1][2]; if(GREATER(t, t2)) return FALSE; // L = A2 x B0 + t = Ty*mR1to0.m[1][0] - Tx*mR1to0.m[1][1]; t2 = ea.x*mAR.m[1][1] + ea.y*mAR.m[1][0] + eb.x*mAR.m[2][2] + eb.z*mAR.m[0][2]; if(GREATER(t, t2)) return FALSE; // L = A2 x B1 + t = Ty*mR1to0.m[2][0] - Tx*mR1to0.m[2][1]; t2 = ea.x*mAR.m[2][1] + ea.y*mAR.m[2][0] + eb.x*mAR.m[1][2] + eb.y*mAR.m[0][2]; if(GREATER(t, t2)) return FALSE; // L = A2 x B2 + } + return TRUE; +} + +//! A dedicated version when one box is constant +inline_ BOOL OBBCollider::BoxBoxOverlap(const Point& extents, const Point& center) +{ + // Stats + mNbVolumeBVTests++; + + float t,t2; + + // Class I : A's basis vectors + float Tx = mTBoxToModel.x - center.x; t = extents.x + mBBx1; if(GREATER(Tx, t)) return FALSE; + float Ty = mTBoxToModel.y - center.y; t = extents.y + mBBy1; if(GREATER(Ty, t)) return FALSE; + float Tz = mTBoxToModel.z - center.z; t = extents.z + mBBz1; if(GREATER(Tz, t)) return FALSE; + + // Class II : B's basis vectors + t = Tx*mRBoxToModel.m[0][0] + Ty*mRBoxToModel.m[0][1] + Tz*mRBoxToModel.m[0][2]; + t2 = extents.x*mAR.m[0][0] + extents.y*mAR.m[0][1] + extents.z*mAR.m[0][2] + mBoxExtents.x; + if(GREATER(t, t2)) return FALSE; + + t = Tx*mRBoxToModel.m[1][0] + Ty*mRBoxToModel.m[1][1] + Tz*mRBoxToModel.m[1][2]; + t2 = extents.x*mAR.m[1][0] + extents.y*mAR.m[1][1] + extents.z*mAR.m[1][2] + mBoxExtents.y; + if(GREATER(t, t2)) return FALSE; + + t = Tx*mRBoxToModel.m[2][0] + Ty*mRBoxToModel.m[2][1] + Tz*mRBoxToModel.m[2][2]; + t2 = extents.x*mAR.m[2][0] + extents.y*mAR.m[2][1] + extents.z*mAR.m[2][2] + mBoxExtents.z; + if(GREATER(t, t2)) return FALSE; + + // Class III : 9 cross products + // Cool trick: always perform the full test for first level, regardless of settings. + // That way pathological cases (such as the pencils scene) are quickly rejected anyway ! + if(mFullBoxBoxTest || mNbVolumeBVTests==1) + { + t = Tz*mRBoxToModel.m[0][1] - Ty*mRBoxToModel.m[0][2]; t2 = extents.y*mAR.m[0][2] + extents.z*mAR.m[0][1] + mBB_1; if(GREATER(t, t2)) return FALSE; // L = A0 x B0 + t = Tz*mRBoxToModel.m[1][1] - Ty*mRBoxToModel.m[1][2]; t2 = extents.y*mAR.m[1][2] + extents.z*mAR.m[1][1] + mBB_2; if(GREATER(t, t2)) return FALSE; // L = A0 x B1 + t = Tz*mRBoxToModel.m[2][1] - Ty*mRBoxToModel.m[2][2]; t2 = extents.y*mAR.m[2][2] + extents.z*mAR.m[2][1] + mBB_3; if(GREATER(t, t2)) return FALSE; // L = A0 x B2 + t = Tx*mRBoxToModel.m[0][2] - Tz*mRBoxToModel.m[0][0]; t2 = extents.x*mAR.m[0][2] + extents.z*mAR.m[0][0] + mBB_4; if(GREATER(t, t2)) return FALSE; // L = A1 x B0 + t = Tx*mRBoxToModel.m[1][2] - Tz*mRBoxToModel.m[1][0]; t2 = extents.x*mAR.m[1][2] + extents.z*mAR.m[1][0] + mBB_5; if(GREATER(t, t2)) return FALSE; // L = A1 x B1 + t = Tx*mRBoxToModel.m[2][2] - Tz*mRBoxToModel.m[2][0]; t2 = extents.x*mAR.m[2][2] + extents.z*mAR.m[2][0] + mBB_6; if(GREATER(t, t2)) return FALSE; // L = A1 x B2 + t = Ty*mRBoxToModel.m[0][0] - Tx*mRBoxToModel.m[0][1]; t2 = extents.x*mAR.m[0][1] + extents.y*mAR.m[0][0] + mBB_7; if(GREATER(t, t2)) return FALSE; // L = A2 x B0 + t = Ty*mRBoxToModel.m[1][0] - Tx*mRBoxToModel.m[1][1]; t2 = extents.x*mAR.m[1][1] + extents.y*mAR.m[1][0] + mBB_8; if(GREATER(t, t2)) return FALSE; // L = A2 x B1 + t = Ty*mRBoxToModel.m[2][0] - Tx*mRBoxToModel.m[2][1]; t2 = extents.x*mAR.m[2][1] + extents.y*mAR.m[2][0] + mBB_9; if(GREATER(t, t2)) return FALSE; // L = A2 x B2 + } + return TRUE; +} + +//! A special version for 2 axis-aligned boxes +inline_ BOOL AABBCollider::AABBAABBOverlap(const Point& extents, const Point& center) +{ + // Stats + mNbVolumeBVTests++; + + float tx = mBox.mCenter.x - center.x; float ex = extents.x + mBox.mExtents.x; if(GREATER(tx, ex)) return FALSE; + float ty = mBox.mCenter.y - center.y; float ey = extents.y + mBox.mExtents.y; if(GREATER(ty, ey)) return FALSE; + float tz = mBox.mCenter.z - center.z; float ez = extents.z + mBox.mExtents.z; if(GREATER(tz, ez)) return FALSE; + + return TRUE; +} diff --git a/libs/ode-0.16.1/OPCODE/OPC_Collider.cpp b/libs/ode-0.16.1/OPCODE/OPC_Collider.cpp new file mode 100644 index 0000000..f41fc36 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_Collider.cpp @@ -0,0 +1,54 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains base collider class. + * \file OPC_Collider.cpp + * \author Pierre Terdiman + * \date June, 2, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains the abstract class for colliders. + * + * \class Collider + * \author Pierre Terdiman + * \version 1.3 + * \date June, 2, 2001 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace Opcode; + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +Collider::Collider() : + mFlags (0), + mCurrentModel (null), + mIMesh (null) +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +Collider::~Collider() +{ +} diff --git a/libs/ode-0.16.1/OPCODE/OPC_Collider.h b/libs/ode-0.16.1/OPCODE/OPC_Collider.h new file mode 100644 index 0000000..d718e02 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_Collider.h @@ -0,0 +1,176 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains base collider class. + * \file OPC_Collider.h + * \author Pierre Terdiman + * \date June, 2, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __OPC_COLLIDER_H__ +#define __OPC_COLLIDER_H__ + + enum CollisionFlag + { + OPC_FIRST_CONTACT = (1<<0), //!< Report all contacts (false) or only first one (true) + OPC_TEMPORAL_COHERENCE = (1<<1), //!< Use temporal coherence or not + OPC_CONTACT = (1<<2), //!< Final contact status after a collision query + OPC_TEMPORAL_HIT = (1<<3), //!< There has been an early exit due to temporal coherence + OPC_NO_PRIMITIVE_TESTS = (1<<4), //!< Keep or discard primitive-bv tests in leaf nodes (volume-mesh queries) + + OPC_CONTACT_FOUND = OPC_FIRST_CONTACT | OPC_CONTACT, + OPC_TEMPORAL_CONTACT = OPC_TEMPORAL_HIT | OPC_CONTACT, + + OPC_FORCE_DWORD = 0x7fffffff + }; + + class OPCODE_API Collider + { + public: + // Constructor / Destructor + Collider(); + virtual ~Collider(); + + // Collision report + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets the last collision status after a collision query. + * \return true if a collision occured + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ BOOL GetContactStatus() const { return mFlags & OPC_CONTACT; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets the "first contact" mode. + * \return true if "first contact" mode is on + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ BOOL FirstContactEnabled() const { return mFlags & OPC_FIRST_CONTACT; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets the temporal coherence mode. + * \return true if temporal coherence is on + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ BOOL TemporalCoherenceEnabled() const { return mFlags & OPC_TEMPORAL_COHERENCE; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Checks a first contact has already been found. + * \return true if a first contact has been found and we can stop a query + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ BOOL ContactFound() const { return (mFlags&OPC_CONTACT_FOUND)==OPC_CONTACT_FOUND; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Checks there's been an early exit due to temporal coherence; + * \return true if a temporal hit has occured + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ BOOL TemporalHit() const { return mFlags & OPC_TEMPORAL_HIT; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Checks primitive tests are enabled; + * \return true if primitive tests must be skipped + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ BOOL SkipPrimitiveTests() const { return mFlags & OPC_NO_PRIMITIVE_TESTS; } + + // Settings + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Reports all contacts (false) or first contact only (true) + * \param flag [in] true for first contact, false for all contacts + * \see SetTemporalCoherence(bool flag) + * \see ValidateSettings() + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void SetFirstContact(bool flag) + { + if(flag) mFlags |= OPC_FIRST_CONTACT; + else mFlags &= ~OPC_FIRST_CONTACT; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Enable/disable temporal coherence. + * \param flag [in] true to enable temporal coherence, false to discard it + * \see SetFirstContact(bool flag) + * \see ValidateSettings() + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void SetTemporalCoherence(bool flag) + { + if(flag) mFlags |= OPC_TEMPORAL_COHERENCE; + else mFlags &= ~OPC_TEMPORAL_COHERENCE; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Enable/disable primitive tests. + * \param flag [in] true to enable primitive tests, false to discard them + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void SetPrimitiveTests(bool flag) + { + if(!flag) mFlags |= OPC_NO_PRIMITIVE_TESTS; + else mFlags &= ~OPC_NO_PRIMITIVE_TESTS; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Validates current settings. You should call this method after all the settings / callbacks have been defined for a collider. + * \return null if everything is ok, else a string describing the problem + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + virtual const char* ValidateSettings() = 0; + + protected: + udword mFlags; //!< Bit flags + const BaseModel* mCurrentModel; //!< Current model for collision query (owner of touched faces) + // User mesh interface + const MeshInterface* mIMesh; //!< User-defined mesh interface + + // Internal methods + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Setups current collision model + * \param model [in] current collision model + * \return TRUE if success + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ BOOL Setup(const BaseModel* model) + { + // Keep track of current model + mCurrentModel = model; + if(!mCurrentModel) return FALSE; + + mIMesh = model->GetMeshInterface(); + return mIMesh!=null; + } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Initializes a query + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + virtual inline_ void InitQuery() { mFlags &= ~OPC_TEMPORAL_CONTACT; } + }; + +#endif // __OPC_COLLIDER_H__ diff --git a/libs/ode-0.16.1/OPCODE/OPC_Common.cpp b/libs/ode-0.16.1/OPCODE/OPC_Common.cpp new file mode 100644 index 0000000..5b9a9c8 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_Common.cpp @@ -0,0 +1,48 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains common classes & defs used in OPCODE. + * \file OPC_Common.cpp + * \author Pierre Terdiman + * \date March, 20, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * An AABB dedicated to collision detection. + * We don't use the generic AABB class included in ICE, since it can be a Min/Max or a Center/Extents one (depends + * on compilation flags). Since the Center/Extents model is more efficient in collision detection, it was worth + * using an extra special class. + * + * \class CollisionAABB + * \author Pierre Terdiman + * \version 1.3 + * \date March, 20, 2001 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * A quantized AABB. + * Center/Extent model, using 16-bits integers. + * + * \class QuantizedAABB + * \author Pierre Terdiman + * \version 1.3 + * \date March, 20, 2001 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace Opcode; diff --git a/libs/ode-0.16.1/OPCODE/OPC_Common.h b/libs/ode-0.16.1/OPCODE/OPC_Common.h new file mode 100644 index 0000000..f134990 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_Common.h @@ -0,0 +1,101 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains common classes & defs used in OPCODE. + * \file OPC_Common.h + * \author Pierre Terdiman + * \date March, 20, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __OPC_COMMON_H__ +#define __OPC_COMMON_H__ + +// [GOTTFRIED]: Just a small change for readability. +#ifdef OPC_CPU_COMPARE + #define GREATER(x, y) AIR(x) > IR(y) +#else + #define GREATER(x, y) fabsf(x) > (y) +#endif + + class OPCODE_API CollisionAABB + { + public: + //! Constructor + inline_ CollisionAABB() {} + //! Constructor + inline_ CollisionAABB(const AABB& b) { b.GetCenter(mCenter); b.GetExtents(mExtents); } + //! Destructor + inline_ ~CollisionAABB() {} + + //! Get min point of the box + inline_ void GetMin(Point& min) const { min = mCenter - mExtents; } + //! Get max point of the box + inline_ void GetMax(Point& max) const { max = mCenter + mExtents; } + + //! Get component of the box's min point along a given axis + inline_ float GetMin(udword axis) const { return mCenter[axis] - mExtents[axis]; } + //! Get component of the box's max point along a given axis + inline_ float GetMax(udword axis) const { return mCenter[axis] + mExtents[axis]; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Setups an AABB from min & max vectors. + * \param min [in] the min point + * \param max [in] the max point + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void SetMinMax(const Point& min, const Point& max) { mCenter = (max + min)*0.5f; mExtents = (max - min)*0.5f; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Checks a box is inside another box. + * \param box [in] the other box + * \return true if current box is inside input box + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ BOOL IsInside(const CollisionAABB& box) const + { + if(box.GetMin(0)>GetMin(0)) return FALSE; + if(box.GetMin(1)>GetMin(1)) return FALSE; + if(box.GetMin(2)>GetMin(2)) return FALSE; + if(box.GetMax(0)IsValid()) return false; + + // Look for degenerate faces. + //udword NbDegenerate = create.mIMesh->CheckTopology(); + //if(NbDegenerate) Log("OPCODE WARNING: found %d degenerate faces in model! Collision might report wrong results!\n", NbDegenerate); + // We continue nonetheless.... + + Release(); // Make sure previous tree has been discarded + + // 1-1) Setup mesh interface automatically + SetMeshInterface(create.mIMesh); + + bool Status = false; + AABBTree* LeafTree = null; + Internal Data; + + // 2) Build a generic AABB Tree. + mSource = new AABBTree; + CHECKALLOC(mSource); + + // 2-1) Setup a builder. Our primitives here are triangles from input mesh, + // so we use an AABBTreeOfTrianglesBuilder..... + { + AABBTreeOfTrianglesBuilder TB; + TB.mIMesh = create.mIMesh; + TB.mNbPrimitives = create.mIMesh->GetNbTriangles(); + TB.mSettings = create.mSettings; + TB.mSettings.mLimit = 16; // ### Hardcoded, but maybe we could let the user choose 8 / 16 / 32 ... + if(!mSource->Build(&TB)) goto FreeAndExit; + } + + // 2-2) Here's the trick : create *another* AABB tree using the leaves of the first one (which are boxes, this time) + struct Local + { + // A callback to count leaf nodes + static bool CountLeaves(const AABBTreeNode* current, udword /*depth*/, void* user_data) + { + if(current->IsLeaf()) + { + Internal* Data = (Internal*)user_data; + Data->mNbLeaves++; + } + return true; + } + + // A callback to setup leaf nodes in our internal structures + static bool SetupLeafData(const AABBTreeNode* current, udword /*depth*/, void* user_data) + { + if(current->IsLeaf()) + { + Internal* Data = (Internal*)user_data; + + // Get current leaf's box + Data->mLeaves[Data->mNbLeaves] = *current->GetAABB(); + + // Setup leaf data + udword Index = udword((size_t(current->GetPrimitives()) - size_t(Data->mBase)) / sizeof(udword)); + Data->mTriangles[Data->mNbLeaves].SetData(current->GetNbPrimitives(), Index); + + Data->mNbLeaves++; + } + return true; + } + }; + + // Walk the tree & count number of leaves + Data.mNbLeaves = 0; + mSource->Walk(Local::CountLeaves, &Data); + mNbLeaves = Data.mNbLeaves; // Keep track of it + + // Special case for 1-leaf meshes + if(mNbLeaves==1) + { + mModelCode |= OPC_SINGLE_NODE; + Status = true; + goto FreeAndExit; + } + + // Allocate our structures + Data.mLeaves = new AABB[Data.mNbLeaves]; CHECKALLOC(Data.mLeaves); + mTriangles = new LeafTriangles[Data.mNbLeaves]; CHECKALLOC(mTriangles); + + // Walk the tree again & setup leaf data + Data.mTriangles = mTriangles; + Data.mBase = mSource->GetIndices(); + Data.mNbLeaves = 0; // Reset for incoming walk + mSource->Walk(Local::SetupLeafData, &Data); + + // Handle source indices + { + bool MustKeepIndices = true; + if(create.mCanRemap) + { + // We try to get rid of source indices (saving more ram!) by reorganizing triangle arrays... + // Remap can fail when we use callbacks => keep track of indices in that case (it still + // works, only using more memory) + if(create.mIMesh->RemapClient(mSource->GetNbPrimitives(), mSource->GetIndices())) + { + MustKeepIndices = false; + } + } + + if(MustKeepIndices) + { + // Keep track of source indices (from vanilla tree) + mNbPrimitives = mSource->GetNbPrimitives(); + mIndices = new udword[mNbPrimitives]; + CopyMemory(mIndices, mSource->GetIndices(), mNbPrimitives*sizeof(udword)); + } + } + + // Now, create our optimized tree using previous leaf nodes + LeafTree = new AABBTree; + CHECKALLOC(LeafTree); + { + AABBTreeOfAABBsBuilder TB; // Now using boxes ! + TB.mSettings = create.mSettings; + TB.mSettings.mLimit = 1; // We now want a complete tree so that we can "optimize" it + TB.mNbPrimitives = Data.mNbLeaves; + TB.mAABBArray = Data.mLeaves; + if(!LeafTree->Build(&TB)) goto FreeAndExit; + } + + // 3) Create an optimized tree according to user-settings + if(!CreateTree(create.mNoLeaf, create.mQuantized)) goto FreeAndExit; + + // 3-2) Create optimized tree + if(!mTree->Build(LeafTree)) goto FreeAndExit; + + // Finally ok... + Status = true; + +FreeAndExit: // Allow me this one... + DELETESINGLE(LeafTree); + + // 3-3) Delete generic tree if needed + if(!create.mKeepOriginal) DELETESINGLE(mSource); + + return Status; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Gets the number of bytes used by the tree. + * \return amount of bytes used + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +udword HybridModel::GetUsedBytes() const +{ + udword UsedBytes = 0; + if(mTree) UsedBytes += mTree->GetUsedBytes(); + if(mIndices) UsedBytes += mNbPrimitives * sizeof(udword); // mIndices + if(mTriangles) UsedBytes += mNbLeaves * sizeof(LeafTriangles); // mTriangles + return UsedBytes; +} + +inline_ void ComputeMinMax(Point& min, Point& max, const VertexPointers& vp) +{ + // Compute triangle's AABB = a leaf box +#ifdef OPC_USE_FCOMI // a 15% speedup on my machine, not much + min.x = FCMin3(vp.Vertex[0]->x, vp.Vertex[1]->x, vp.Vertex[2]->x); + max.x = FCMax3(vp.Vertex[0]->x, vp.Vertex[1]->x, vp.Vertex[2]->x); + + min.y = FCMin3(vp.Vertex[0]->y, vp.Vertex[1]->y, vp.Vertex[2]->y); + max.y = FCMax3(vp.Vertex[0]->y, vp.Vertex[1]->y, vp.Vertex[2]->y); + + min.z = FCMin3(vp.Vertex[0]->z, vp.Vertex[1]->z, vp.Vertex[2]->z); + max.z = FCMax3(vp.Vertex[0]->z, vp.Vertex[1]->z, vp.Vertex[2]->z); +#else + min = *vp.Vertex[0]; + max = *vp.Vertex[0]; + min.Min(*vp.Vertex[1]); + max.Max(*vp.Vertex[1]); + min.Min(*vp.Vertex[2]); + max.Max(*vp.Vertex[2]); +#endif +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Refits the collision model. This can be used to handle dynamic meshes. Usage is: + * 1. modify your mesh vertices (keep the topology constant!) + * 2. refit the tree (call this method) + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool HybridModel::Refit() +{ + if(!mIMesh) return false; + if(!mTree) return false; + + if(IsQuantized()) return false; + if(HasLeafNodes()) return false; + + const LeafTriangles* LT = GetLeafTriangles(); + const udword* Indices = GetIndices(); + + // Bottom-up update + VertexPointers VP; + ConversionArea VC; + Point Min,Max; + Point Min_,Max_; + udword Index = mTree->GetNbNodes(); + AABBNoLeafNode* Nodes = const_cast(static_cast(static_cast(mTree)->GetNodes())); + while(Index--) + { + AABBNoLeafNode& Current = Nodes[Index]; + + if(Current.HasPosLeaf()) + { + const LeafTriangles& CurrentLeaf = LT[Current.GetPosPrimitive()]; + + Min.SetPlusInfinity(); + Max.SetMinusInfinity(); + + Point TmpMin, TmpMax; + + // Each leaf box has a set of triangles + udword NbTris = CurrentLeaf.GetNbTriangles(); + if(Indices) + { + const udword* T = &Indices[CurrentLeaf.GetTriangleIndex()]; + + // Loop through triangles and test each of them + while(NbTris--) + { + mIMesh->GetTriangle(VP, *T++, VC); + ComputeMinMax(TmpMin, TmpMax, VP); + Min.Min(TmpMin); + Max.Max(TmpMax); + } + } + else + { + udword BaseIndex = CurrentLeaf.GetTriangleIndex(); + + // Loop through triangles and test each of them + while(NbTris--) + { + mIMesh->GetTriangle(VP, BaseIndex++, VC); + ComputeMinMax(TmpMin, TmpMax, VP); + Min.Min(TmpMin); + Max.Max(TmpMax); + } + } + } + else + { + const CollisionAABB& CurrentBox = Current.GetPos()->mAABB; + CurrentBox.GetMin(Min); + CurrentBox.GetMax(Max); + } + + if(Current.HasNegLeaf()) + { + const LeafTriangles& CurrentLeaf = LT[Current.GetNegPrimitive()]; + + Min_.SetPlusInfinity(); + Max_.SetMinusInfinity(); + + Point TmpMin, TmpMax; + + // Each leaf box has a set of triangles + udword NbTris = CurrentLeaf.GetNbTriangles(); + if(Indices) + { + const udword* T = &Indices[CurrentLeaf.GetTriangleIndex()]; + + // Loop through triangles and test each of them + while(NbTris--) + { + mIMesh->GetTriangle(VP, *T++, VC); + ComputeMinMax(TmpMin, TmpMax, VP); + Min_.Min(TmpMin); + Max_.Max(TmpMax); + } + } + else + { + udword BaseIndex = CurrentLeaf.GetTriangleIndex(); + + // Loop through triangles and test each of them + while(NbTris--) + { + mIMesh->GetTriangle(VP, BaseIndex++, VC); + ComputeMinMax(TmpMin, TmpMax, VP); + Min_.Min(TmpMin); + Max_.Max(TmpMax); + } + } + } + else + { + const CollisionAABB& CurrentBox = Current.GetNeg()->mAABB; + CurrentBox.GetMin(Min_); + CurrentBox.GetMax(Max_); + } +#ifdef OPC_USE_FCOMI + Min.x = FCMin2(Min.x, Min_.x); + Max.x = FCMax2(Max.x, Max_.x); + Min.y = FCMin2(Min.y, Min_.y); + Max.y = FCMax2(Max.y, Max_.y); + Min.z = FCMin2(Min.z, Min_.z); + Max.z = FCMax2(Max.z, Max_.z); +#else + Min.Min(Min_); + Max.Max(Max_); +#endif + Current.mAABB.SetMinMax(Min, Max); + } + return true; +} diff --git a/libs/ode-0.16.1/OPCODE/OPC_HybridModel.h b/libs/ode-0.16.1/OPCODE/OPC_HybridModel.h new file mode 100644 index 0000000..c7eb59d --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_HybridModel.h @@ -0,0 +1,106 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for hybrid models. + * \file OPC_HybridModel.h + * \author Pierre Terdiman + * \date May, 18, 2003 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __OPC_HYBRIDMODEL_H__ +#define __OPC_HYBRIDMODEL_H__ + + //! Leaf descriptor + struct LeafTriangles + { + udword Data; //!< Packed data + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets number of triangles in the leaf. + * \return number of triangles N, with 0 < N <= 16 + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ udword GetNbTriangles() const { return (Data & 15)+1; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets triangle index for this leaf. Indexed model's array of indices retrieved with HybridModel::GetIndices() + * \return triangle index + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ udword GetTriangleIndex() const { return Data>>4; } + inline_ void SetData(udword nb, udword index) { ASSERT(nb>0 && nb<=16); nb--; Data = (index<<4)|(nb&15); } + }; + + class OPCODE_API HybridModel : public BaseModel + { + public: + // Constructor/Destructor + HybridModel(); + virtual ~HybridModel(); + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Builds a collision model. + * \param create [in] model creation structure + * \return true if success + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + override(BaseModel) bool Build(const OPCODECREATE& create); + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets the number of bytes used by the tree. + * \return amount of bytes used + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + override(BaseModel) udword GetUsedBytes() const; + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Refits the collision model. This can be used to handle dynamic meshes. Usage is: + * 1. modify your mesh vertices (keep the topology constant!) + * 2. refit the tree (call this method) + * \return true if success + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + override(BaseModel) bool Refit(); + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets array of triangles. + * \return array of triangles + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ const LeafTriangles* GetLeafTriangles() const { return mTriangles; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets array of indices. + * \return array of indices + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ const udword* GetIndices() const { return mIndices; } + + private: + udword mNbLeaves; //!< Number of leaf nodes in the model + LeafTriangles* mTriangles; //!< Array of mNbLeaves leaf descriptors + udword mNbPrimitives; //!< Number of primitives in the model + udword* mIndices; //!< Array of primitive indices + + // Internal methods + void Release(); + }; + +#endif // __OPC_HYBRIDMODEL_H__ diff --git a/libs/ode-0.16.1/OPCODE/OPC_IceHook.h b/libs/ode-0.16.1/OPCODE/OPC_IceHook.h new file mode 100644 index 0000000..4fc6c8a --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_IceHook.h @@ -0,0 +1,80 @@ + +// Should be included by Opcode.h if needed + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __OPC_ICEHOOK_H__ +#define __OPC_ICEHOOK_H__ + + #define ICE_DONT_CHECK_COMPILER_OPTIONS + + // From Windows... + typedef int BOOL; + #ifndef FALSE + #define FALSE 0 + #endif + + #ifndef TRUE + #define TRUE 1 + #endif + + #include + #include + #include + #include + #include + #include + + #ifndef ASSERT + #define ASSERT(exp) {} + #endif + #define ICE_COMPILE_TIME_ASSERT(exp) extern char ICE_Dummy[ (exp) ? 1 : -1 ] + + #define Log {} + #define SetIceError(a,b) false + #define EC_OUTOFMEMORY "Out of memory" + + extern void OPCODE_NORETURN IceAbort(); + + #include "Ice/IcePreprocessor.h" + + #undef ICECORE_API + #define ICECORE_API OPCODE_API + + #include "Ice/IceTypes.h" + #include "Ice/IceFPU.h" + #include "Ice/IceMemoryMacros.h" + + namespace IceCore + { + #include "Ice/IceUtils.h" + #include "Ice/IceContainer.h" + #include "Ice/IcePairs.h" + #include "Ice/IceRevisitedRadix.h" + #include "Ice/IceRandom.h" + } + using namespace IceCore; + + #define ICEMATHS_API OPCODE_API + namespace IceMaths + { + #include "Ice/IceAxes.h" + #include "Ice/IcePoint.h" + #include "Ice/IceHPoint.h" + #include "Ice/IceMatrix3x3.h" + #include "Ice/IceMatrix4x4.h" + #include "Ice/IcePlane.h" + #include "Ice/IceRay.h" + #include "Ice/IceIndexedTriangle.h" + #include "Ice/IceTriangle.h" + #include "Ice/IceTriList.h" + #include "Ice/IceAABB.h" + #include "Ice/IceOBB.h" + #include "Ice/IceBoundingSphere.h" + #include "Ice/IceSegment.h" + #include "Ice/IceLSS.h" + } + using namespace IceMaths; + + +#endif // __OPC_ICEHOOK_H__ diff --git a/libs/ode-0.16.1/OPCODE/OPC_LSSAABBOverlap.h b/libs/ode-0.16.1/OPCODE/OPC_LSSAABBOverlap.h new file mode 100644 index 0000000..c6ba9d3 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_LSSAABBOverlap.h @@ -0,0 +1,525 @@ + +// Following code from Magic-Software (http://www.magic-software.com/) +// A bit modified for Opcode + +inline_ float OPC_PointAABBSqrDist(const Point& point, const Point& center, const Point& extents) +{ + // Compute coordinates of point in box coordinate system + Point Closest = point - center; + + float SqrDistance = 0.0f; + + if(Closest.x < -extents.x) + { + float Delta = Closest.x + extents.x; + SqrDistance += Delta*Delta; + } + else if(Closest.x > extents.x) + { + float Delta = Closest.x - extents.x; + SqrDistance += Delta*Delta; + } + + if(Closest.y < -extents.y) + { + float Delta = Closest.y + extents.y; + SqrDistance += Delta*Delta; + } + else if(Closest.y > extents.y) + { + float Delta = Closest.y - extents.y; + SqrDistance += Delta*Delta; + } + + if(Closest.z < -extents.z) + { + float Delta = Closest.z + extents.z; + SqrDistance += Delta*Delta; + } + else if(Closest.z > extents.z) + { + float Delta = Closest.z - extents.z; + SqrDistance += Delta*Delta; + } + return SqrDistance; +} + +static void Face(int i0, int i1, int i2, Point& rkPnt, const Point& rkDir, const Point& extents, const Point& rkPmE, float* pfLParam, float& rfSqrDistance) +{ + Point kPpE; + float fLSqr, fInv, fTmp, fParam, fT, fDelta; + + kPpE[i1] = rkPnt[i1] + extents[i1]; + kPpE[i2] = rkPnt[i2] + extents[i2]; + if(rkDir[i0]*kPpE[i1] >= rkDir[i1]*rkPmE[i0]) + { + if(rkDir[i0]*kPpE[i2] >= rkDir[i2]*rkPmE[i0]) + { + // v[i1] >= -e[i1], v[i2] >= -e[i2] (distance = 0) + if(pfLParam) + { + rkPnt[i0] = extents[i0]; + fInv = 1.0f/rkDir[i0]; + rkPnt[i1] -= rkDir[i1]*rkPmE[i0]*fInv; + rkPnt[i2] -= rkDir[i2]*rkPmE[i0]*fInv; + *pfLParam = -rkPmE[i0]*fInv; + } + } + else + { + // v[i1] >= -e[i1], v[i2] < -e[i2] + fLSqr = rkDir[i0]*rkDir[i0] + rkDir[i2]*rkDir[i2]; + fTmp = fLSqr*kPpE[i1] - rkDir[i1]*(rkDir[i0]*rkPmE[i0] + rkDir[i2]*kPpE[i2]); + if(fTmp <= 2.0f*fLSqr*extents[i1]) + { + fT = fTmp/fLSqr; + fLSqr += rkDir[i1]*rkDir[i1]; + fTmp = kPpE[i1] - fT; + fDelta = rkDir[i0]*rkPmE[i0] + rkDir[i1]*fTmp + rkDir[i2]*kPpE[i2]; + fParam = -fDelta/fLSqr; + rfSqrDistance += rkPmE[i0]*rkPmE[i0] + fTmp*fTmp + kPpE[i2]*kPpE[i2] + fDelta*fParam; + + if(pfLParam) + { + *pfLParam = fParam; + rkPnt[i0] = extents[i0]; + rkPnt[i1] = fT - extents[i1]; + rkPnt[i2] = -extents[i2]; + } + } + else + { + fLSqr += rkDir[i1]*rkDir[i1]; + fDelta = rkDir[i0]*rkPmE[i0] + rkDir[i1]*rkPmE[i1] + rkDir[i2]*kPpE[i2]; + fParam = -fDelta/fLSqr; + rfSqrDistance += rkPmE[i0]*rkPmE[i0] + rkPmE[i1]*rkPmE[i1] + kPpE[i2]*kPpE[i2] + fDelta*fParam; + + if(pfLParam) + { + *pfLParam = fParam; + rkPnt[i0] = extents[i0]; + rkPnt[i1] = extents[i1]; + rkPnt[i2] = -extents[i2]; + } + } + } + } + else + { + if ( rkDir[i0]*kPpE[i2] >= rkDir[i2]*rkPmE[i0] ) + { + // v[i1] < -e[i1], v[i2] >= -e[i2] + fLSqr = rkDir[i0]*rkDir[i0] + rkDir[i1]*rkDir[i1]; + fTmp = fLSqr*kPpE[i2] - rkDir[i2]*(rkDir[i0]*rkPmE[i0] + rkDir[i1]*kPpE[i1]); + if(fTmp <= 2.0f*fLSqr*extents[i2]) + { + fT = fTmp/fLSqr; + fLSqr += rkDir[i2]*rkDir[i2]; + fTmp = kPpE[i2] - fT; + fDelta = rkDir[i0]*rkPmE[i0] + rkDir[i1]*kPpE[i1] + rkDir[i2]*fTmp; + fParam = -fDelta/fLSqr; + rfSqrDistance += rkPmE[i0]*rkPmE[i0] + kPpE[i1]*kPpE[i1] + fTmp*fTmp + fDelta*fParam; + + if(pfLParam) + { + *pfLParam = fParam; + rkPnt[i0] = extents[i0]; + rkPnt[i1] = -extents[i1]; + rkPnt[i2] = fT - extents[i2]; + } + } + else + { + fLSqr += rkDir[i2]*rkDir[i2]; + fDelta = rkDir[i0]*rkPmE[i0] + rkDir[i1]*kPpE[i1] + rkDir[i2]*rkPmE[i2]; + fParam = -fDelta/fLSqr; + rfSqrDistance += rkPmE[i0]*rkPmE[i0] + kPpE[i1]*kPpE[i1] + rkPmE[i2]*rkPmE[i2] + fDelta*fParam; + + if(pfLParam) + { + *pfLParam = fParam; + rkPnt[i0] = extents[i0]; + rkPnt[i1] = -extents[i1]; + rkPnt[i2] = extents[i2]; + } + } + } + else + { + // v[i1] < -e[i1], v[i2] < -e[i2] + fLSqr = rkDir[i0]*rkDir[i0]+rkDir[i2]*rkDir[i2]; + fTmp = fLSqr*kPpE[i1] - rkDir[i1]*(rkDir[i0]*rkPmE[i0] + rkDir[i2]*kPpE[i2]); + if(fTmp >= 0.0f) + { + // v[i1]-edge is closest + if ( fTmp <= 2.0f*fLSqr*extents[i1] ) + { + fT = fTmp/fLSqr; + fLSqr += rkDir[i1]*rkDir[i1]; + fTmp = kPpE[i1] - fT; + fDelta = rkDir[i0]*rkPmE[i0] + rkDir[i1]*fTmp + rkDir[i2]*kPpE[i2]; + fParam = -fDelta/fLSqr; + rfSqrDistance += rkPmE[i0]*rkPmE[i0] + fTmp*fTmp + kPpE[i2]*kPpE[i2] + fDelta*fParam; + + if(pfLParam) + { + *pfLParam = fParam; + rkPnt[i0] = extents[i0]; + rkPnt[i1] = fT - extents[i1]; + rkPnt[i2] = -extents[i2]; + } + } + else + { + fLSqr += rkDir[i1]*rkDir[i1]; + fDelta = rkDir[i0]*rkPmE[i0] + rkDir[i1]*rkPmE[i1] + rkDir[i2]*kPpE[i2]; + fParam = -fDelta/fLSqr; + rfSqrDistance += rkPmE[i0]*rkPmE[i0] + rkPmE[i1]*rkPmE[i1] + kPpE[i2]*kPpE[i2] + fDelta*fParam; + + if(pfLParam) + { + *pfLParam = fParam; + rkPnt[i0] = extents[i0]; + rkPnt[i1] = extents[i1]; + rkPnt[i2] = -extents[i2]; + } + } + return; + } + + fLSqr = rkDir[i0]*rkDir[i0] + rkDir[i1]*rkDir[i1]; + fTmp = fLSqr*kPpE[i2] - rkDir[i2]*(rkDir[i0]*rkPmE[i0] + rkDir[i1]*kPpE[i1]); + if(fTmp >= 0.0f) + { + // v[i2]-edge is closest + if(fTmp <= 2.0f*fLSqr*extents[i2]) + { + fT = fTmp/fLSqr; + fLSqr += rkDir[i2]*rkDir[i2]; + fTmp = kPpE[i2] - fT; + fDelta = rkDir[i0]*rkPmE[i0] + rkDir[i1]*kPpE[i1] + rkDir[i2]*fTmp; + fParam = -fDelta/fLSqr; + rfSqrDistance += rkPmE[i0]*rkPmE[i0] + kPpE[i1]*kPpE[i1] + fTmp*fTmp + fDelta*fParam; + + if(pfLParam) + { + *pfLParam = fParam; + rkPnt[i0] = extents[i0]; + rkPnt[i1] = -extents[i1]; + rkPnt[i2] = fT - extents[i2]; + } + } + else + { + fLSqr += rkDir[i2]*rkDir[i2]; + fDelta = rkDir[i0]*rkPmE[i0] + rkDir[i1]*kPpE[i1] + rkDir[i2]*rkPmE[i2]; + fParam = -fDelta/fLSqr; + rfSqrDistance += rkPmE[i0]*rkPmE[i0] + kPpE[i1]*kPpE[i1] + rkPmE[i2]*rkPmE[i2] + fDelta*fParam; + + if(pfLParam) + { + *pfLParam = fParam; + rkPnt[i0] = extents[i0]; + rkPnt[i1] = -extents[i1]; + rkPnt[i2] = extents[i2]; + } + } + return; + } + + // (v[i1],v[i2])-corner is closest + fLSqr += rkDir[i2]*rkDir[i2]; + fDelta = rkDir[i0]*rkPmE[i0] + rkDir[i1]*kPpE[i1] + rkDir[i2]*kPpE[i2]; + fParam = -fDelta/fLSqr; + rfSqrDistance += rkPmE[i0]*rkPmE[i0] + kPpE[i1]*kPpE[i1] + kPpE[i2]*kPpE[i2] + fDelta*fParam; + + if(pfLParam) + { + *pfLParam = fParam; + rkPnt[i0] = extents[i0]; + rkPnt[i1] = -extents[i1]; + rkPnt[i2] = -extents[i2]; + } + } + } +} + +static void CaseNoZeros(Point& rkPnt, const Point& rkDir, const Point& extents, float* pfLParam, float& rfSqrDistance) +{ + Point kPmE(rkPnt.x - extents.x, rkPnt.y - extents.y, rkPnt.z - extents.z); + + float fProdDxPy, fProdDyPx, fProdDzPx, fProdDxPz, fProdDzPy, fProdDyPz; + + fProdDxPy = rkDir.x*kPmE.y; + fProdDyPx = rkDir.y*kPmE.x; + if(fProdDyPx >= fProdDxPy) + { + fProdDzPx = rkDir.z*kPmE.x; + fProdDxPz = rkDir.x*kPmE.z; + if(fProdDzPx >= fProdDxPz) + { + // line intersects x = e0 + Face(0, 1, 2, rkPnt, rkDir, extents, kPmE, pfLParam, rfSqrDistance); + } + else + { + // line intersects z = e2 + Face(2, 0, 1, rkPnt, rkDir, extents, kPmE, pfLParam, rfSqrDistance); + } + } + else + { + fProdDzPy = rkDir.z*kPmE.y; + fProdDyPz = rkDir.y*kPmE.z; + if(fProdDzPy >= fProdDyPz) + { + // line intersects y = e1 + Face(1, 2, 0, rkPnt, rkDir, extents, kPmE, pfLParam, rfSqrDistance); + } + else + { + // line intersects z = e2 + Face(2, 0, 1, rkPnt, rkDir, extents, kPmE, pfLParam, rfSqrDistance); + } + } +} + +static void Case0(int i0, int i1, int i2, Point& rkPnt, const Point& rkDir, const Point& extents, float* pfLParam, float& rfSqrDistance) +{ + float fPmE0 = rkPnt[i0] - extents[i0]; + float fPmE1 = rkPnt[i1] - extents[i1]; + float fProd0 = rkDir[i1]*fPmE0; + float fProd1 = rkDir[i0]*fPmE1; + float fDelta, fInvLSqr, fInv; + + if(fProd0 >= fProd1) + { + // line intersects P[i0] = e[i0] + rkPnt[i0] = extents[i0]; + + float fPpE1 = rkPnt[i1] + extents[i1]; + fDelta = fProd0 - rkDir[i0]*fPpE1; + if(fDelta >= 0.0f) + { + fInvLSqr = 1.0f/(rkDir[i0]*rkDir[i0] + rkDir[i1]*rkDir[i1]); + rfSqrDistance += fDelta*fDelta*fInvLSqr; + if(pfLParam) + { + rkPnt[i1] = -extents[i1]; + *pfLParam = -(rkDir[i0]*fPmE0+rkDir[i1]*fPpE1)*fInvLSqr; + } + } + else + { + if(pfLParam) + { + fInv = 1.0f/rkDir[i0]; + rkPnt[i1] -= fProd0*fInv; + *pfLParam = -fPmE0*fInv; + } + } + } + else + { + // line intersects P[i1] = e[i1] + rkPnt[i1] = extents[i1]; + + float fPpE0 = rkPnt[i0] + extents[i0]; + fDelta = fProd1 - rkDir[i1]*fPpE0; + if(fDelta >= 0.0f) + { + fInvLSqr = 1.0f/(rkDir[i0]*rkDir[i0] + rkDir[i1]*rkDir[i1]); + rfSqrDistance += fDelta*fDelta*fInvLSqr; + if(pfLParam) + { + rkPnt[i0] = -extents[i0]; + *pfLParam = -(rkDir[i0]*fPpE0+rkDir[i1]*fPmE1)*fInvLSqr; + } + } + else + { + if(pfLParam) + { + fInv = 1.0f/rkDir[i1]; + rkPnt[i0] -= fProd1*fInv; + *pfLParam = -fPmE1*fInv; + } + } + } + + if(rkPnt[i2] < -extents[i2]) + { + fDelta = rkPnt[i2] + extents[i2]; + rfSqrDistance += fDelta*fDelta; + rkPnt[i2] = -extents[i2]; + } + else if ( rkPnt[i2] > extents[i2] ) + { + fDelta = rkPnt[i2] - extents[i2]; + rfSqrDistance += fDelta*fDelta; + rkPnt[i2] = extents[i2]; + } +} + +static void Case00(int i0, int i1, int i2, Point& rkPnt, const Point& rkDir, const Point& extents, float* pfLParam, float& rfSqrDistance) +{ + float fDelta; + + if(pfLParam) + *pfLParam = (extents[i0] - rkPnt[i0])/rkDir[i0]; + + rkPnt[i0] = extents[i0]; + + if(rkPnt[i1] < -extents[i1]) + { + fDelta = rkPnt[i1] + extents[i1]; + rfSqrDistance += fDelta*fDelta; + rkPnt[i1] = -extents[i1]; + } + else if(rkPnt[i1] > extents[i1]) + { + fDelta = rkPnt[i1] - extents[i1]; + rfSqrDistance += fDelta*fDelta; + rkPnt[i1] = extents[i1]; + } + + if(rkPnt[i2] < -extents[i2]) + { + fDelta = rkPnt[i2] + extents[i2]; + rfSqrDistance += fDelta*fDelta; + rkPnt[i1] = -extents[i2]; + } + else if(rkPnt[i2] > extents[i2]) + { + fDelta = rkPnt[i2] - extents[i2]; + rfSqrDistance += fDelta*fDelta; + rkPnt[i2] = extents[i2]; + } +} + +static void Case000(Point& rkPnt, const Point& extents, float& rfSqrDistance) +{ + float fDelta; + + if(rkPnt.x < -extents.x) + { + fDelta = rkPnt.x + extents.x; + rfSqrDistance += fDelta*fDelta; + rkPnt.x = -extents.x; + } + else if(rkPnt.x > extents.x) + { + fDelta = rkPnt.x - extents.x; + rfSqrDistance += fDelta*fDelta; + rkPnt.x = extents.x; + } + + if(rkPnt.y < -extents.y) + { + fDelta = rkPnt.y + extents.y; + rfSqrDistance += fDelta*fDelta; + rkPnt.y = -extents.y; + } + else if(rkPnt.y > extents.y) + { + fDelta = rkPnt.y - extents.y; + rfSqrDistance += fDelta*fDelta; + rkPnt.y = extents.y; + } + + if(rkPnt.z < -extents.z) + { + fDelta = rkPnt.z + extents.z; + rfSqrDistance += fDelta*fDelta; + rkPnt.z = -extents.z; + } + else if(rkPnt.z > extents.z) + { + fDelta = rkPnt.z - extents.z; + rfSqrDistance += fDelta*fDelta; + rkPnt.z = extents.z; + } +} + +static float SqrDistance(const Ray& rkLine, const Point& center, const Point& extents, float* pfLParam) +{ + // compute coordinates of line in box coordinate system + Point kDiff = rkLine.mOrig - center; + Point kPnt = kDiff; + Point kDir = rkLine.mDir; + +#if 0 + // Apply reflections so that direction vector has nonnegative components. + bool bReflect[3]; + for(int i=0;i<3;i++) + { + if(kDir[i]<0.0f) + { + kPnt[i] = -kPnt[i]; + kDir[i] = -kDir[i]; + bReflect[i] = true; + } + else + { + bReflect[i] = false; + } + } +#endif + + float fSqrDistance = 0.0f; + + if(kDir.x>0.0f) + { + if(kDir.y>0.0f) + { + if(kDir.z>0.0f) CaseNoZeros(kPnt, kDir, extents, pfLParam, fSqrDistance); // (+,+,+) + else Case0(0, 1, 2, kPnt, kDir, extents, pfLParam, fSqrDistance); // (+,+,0) + } + else + { + if(kDir.z>0.0f) Case0(0, 2, 1, kPnt, kDir, extents, pfLParam, fSqrDistance); // (+,0,+) + else Case00(0, 1, 2, kPnt, kDir, extents, pfLParam, fSqrDistance); // (+,0,0) + } + } + else + { + if(kDir.y>0.0f) + { + if(kDir.z>0.0f) Case0(1, 2, 0, kPnt, kDir, extents, pfLParam, fSqrDistance); // (0,+,+) + else Case00(1, 0, 2, kPnt, kDir, extents, pfLParam, fSqrDistance); // (0,+,0) + } + else + { + if(kDir.z>0.0f) Case00(2, 0, 1, kPnt, kDir, extents, pfLParam, fSqrDistance); // (0,0,+) + else + { + Case000(kPnt, extents, fSqrDistance); // (0,0,0) + if(pfLParam) *pfLParam = 0.0f; + } + } + } + return fSqrDistance; +} + +inline_ float OPC_SegmentOBBSqrDist(const Segment& segment, const Point& c0, const Point& e0) +{ + float fLP; + float fSqrDistance = SqrDistance(Ray(segment.GetOrigin(), segment.ComputeDirection()), c0, e0, &fLP); + if(fLP>=0.0f) + { + if(fLP<=1.0f) return fSqrDistance; + else return OPC_PointAABBSqrDist(segment.mP1, c0, e0); + } + else return OPC_PointAABBSqrDist(segment.mP0, c0, e0); +} + +inline_ BOOL LSSCollider::LSSAABBOverlap(const Point& center, const Point& extents) +{ + // Stats + mNbVolumeBVTests++; + + float s2 = OPC_SegmentOBBSqrDist(mSeg, center, extents); + if(s2Add(udword(prim_index)); + +//! LSS-triangle overlap test +#define LSS_PRIM(prim_index, flag) \ + /* Request vertices from the app */ \ + VertexPointers VP; ConversionArea VC; mIMesh->GetTriangle(VP, prim_index, VC); \ + \ + /* Perform LSS-tri overlap test */ \ + if(LSSTriOverlap(*VP.Vertex[0], *VP.Vertex[1], *VP.Vertex[2])) \ + { \ + SET_CONTACT(prim_index, flag) \ + } + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +LSSCollider::LSSCollider() +{ +// mCenter.Zero(); +// mRadius2 = 0.0f; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +LSSCollider::~LSSCollider() +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Generic collision query for generic OPCODE models. After the call, access the results: + * - with GetContactStatus() + * - with GetNbTouchedPrimitives() + * - with GetTouchedPrimitives() + * + * \param cache [in/out] an lss cache + * \param lss [in] collision lss in local space + * \param model [in] Opcode model to collide with + * \param worldl [in] lss world matrix, or null + * \param worldm [in] model's world matrix, or null + * \return true if success + * \warning SCALE NOT SUPPORTED. The matrices must contain rotation & translation parts only. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool LSSCollider::Collide(LSSCache& cache, const LSS& lss, const Model& model, const Matrix4x4* worldl, const Matrix4x4* worldm) +{ + // Checkings + if(!Setup(&model)) return false; + + // Init collision query + if(InitQuery(cache, lss, worldl, worldm)) return true; + + if(!model.HasLeafNodes()) + { + if(model.IsQuantized()) + { + const AABBQuantizedNoLeafTree* Tree = static_cast(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform collision query + if(SkipPrimitiveTests()) _CollideNoPrimitiveTest(Tree->GetNodes()); + else _Collide(Tree->GetNodes()); + } + else + { + const AABBNoLeafTree* Tree = static_cast(model.GetTree()); + + // Perform collision query + if(SkipPrimitiveTests()) _CollideNoPrimitiveTest(Tree->GetNodes()); + else _Collide(Tree->GetNodes()); + } + } + else + { + if(model.IsQuantized()) + { + const AABBQuantizedTree* Tree = static_cast(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform collision query + if(SkipPrimitiveTests()) _CollideNoPrimitiveTest(Tree->GetNodes()); + else _Collide(Tree->GetNodes()); + } + else + { + const AABBCollisionTree* Tree = static_cast(model.GetTree()); + + // Perform collision query + if(SkipPrimitiveTests()) _CollideNoPrimitiveTest(Tree->GetNodes()); + else _Collide(Tree->GetNodes()); + } + } + + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Initializes a collision query : + * - reset stats & contact status + * - setup matrices + * - check temporal coherence + * + * \param cache [in/out] an lss cache + * \param lss [in] lss in local space + * \param worldl [in] lss world matrix, or null + * \param worldm [in] model's world matrix, or null + * \return TRUE if we can return immediately + * \warning SCALE NOT SUPPORTED. The matrices must contain rotation & translation parts only. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +BOOL LSSCollider::InitQuery(LSSCache& cache, const LSS& lss, const Matrix4x4* worldl, const Matrix4x4* worldm) +{ + // 1) Call the base method + VolumeCollider::InitQuery(); + + // 2) Compute LSS in model space: + // - Precompute R^2 + mRadius2 = lss.mRadius * lss.mRadius; + // - Compute segment + mSeg.mP0 = lss.mP0; + mSeg.mP1 = lss.mP1; + // -> to world space + if(worldl) + { + mSeg.mP0 *= *worldl; + mSeg.mP1 *= *worldl; + } + // -> to model space + if(worldm) + { + // Invert model matrix + Matrix4x4 InvWorldM; + InvertPRMatrix(InvWorldM, *worldm); + + mSeg.mP0 *= InvWorldM; + mSeg.mP1 *= InvWorldM; + } + + // 3) Setup destination pointer + mTouchedPrimitives = &cache.TouchedPrimitives; + + // 4) Special case: 1-triangle meshes [Opcode 1.3] + if(mCurrentModel && mCurrentModel->HasSingleNode()) + { + if(!SkipPrimitiveTests()) + { + // We simply perform the BV-Prim overlap test each time. We assume single triangle has index 0. + mTouchedPrimitives->Reset(); + + // Perform overlap test between the unique triangle and the LSS (and set contact status if needed) + LSS_PRIM(udword(0), OPC_CONTACT) + + // Return immediately regardless of status + return TRUE; + } + } + + // 5) Check temporal coherence : + if(TemporalCoherenceEnabled()) + { + // Here we use temporal coherence + // => check results from previous frame before performing the collision query + if(FirstContactEnabled()) + { + // We're only interested in the first contact found => test the unique previously touched face + if(mTouchedPrimitives->GetNbEntries()) + { + // Get index of previously touched face = the first entry in the array + udword PreviouslyTouchedFace = mTouchedPrimitives->GetEntry(0); + + // Then reset the array: + // - if the overlap test below is successful, the index we'll get added back anyway + // - if it isn't, then the array should be reset anyway for the normal query + mTouchedPrimitives->Reset(); + + // Perform overlap test between the cached triangle and the LSS (and set contact status if needed) + LSS_PRIM(PreviouslyTouchedFace, OPC_TEMPORAL_CONTACT) + + // Return immediately if possible + if(GetContactStatus()) return TRUE; + } + // else no face has been touched during previous query + // => we'll have to perform a normal query + } + else + { + // We're interested in all contacts =>test the new real LSS N(ew) against the previous fat LSS P(revious): + + // ### rewrite this + + LSS Test(mSeg, lss.mRadius); // in model space + LSS Previous(cache.Previous, sqrtf(cache.Previous.mRadius)); + +// if(cache.Previous.Contains(Test)) + if(IsCacheValid(cache) && Previous.Contains(Test)) + { + // - if N is included in P, return previous list + // => we simply leave the list (mTouchedFaces) unchanged + + // Set contact status if needed + if(mTouchedPrimitives->GetNbEntries()) mFlags |= OPC_TEMPORAL_CONTACT; + + // In any case we don't need to do a query + return TRUE; + } + else + { + // - else do the query using a fat N + + // Reset cache since we'll about to perform a real query + mTouchedPrimitives->Reset(); + + // Make a fat sphere so that coherence will work for subsequent frames + mRadius2 *= cache.FatCoeff; +// mRadius2 = (lss.mRadius * cache.FatCoeff)*(lss.mRadius * cache.FatCoeff); + + + // Update cache with query data (signature for cached faces) + cache.Previous.mP0 = mSeg.mP0; + cache.Previous.mP1 = mSeg.mP1; + cache.Previous.mRadius = mRadius2; + } + } + } + else + { + // Here we don't use temporal coherence => do a normal query + mTouchedPrimitives->Reset(); + } + + return FALSE; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Collision query for vanilla AABB trees. + * \param cache [in/out] an lss cache + * \param lss [in] collision lss in world space + * \param tree [in] AABB tree + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool LSSCollider::Collide(LSSCache& cache, const LSS& lss, const AABBTree* tree) +{ + // This is typically called for a scene tree, full of -AABBs-, not full of triangles. + // So we don't really have "primitives" to deal with. Hence it doesn't work with + // "FirstContact" + "TemporalCoherence". + ASSERT( !(FirstContactEnabled() && TemporalCoherenceEnabled()) ); + + // Checkings + if(!tree) return false; + + // Init collision query + if(InitQuery(cache, lss)) return true; + + // Perform collision query + _Collide(tree); + + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Checks the LSS completely contains the box. In which case we can end the query sooner. + * \param bc [in] box center + * \param be [in] box extents + * \return true if the LSS contains the whole box + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +inline_ BOOL LSSCollider::LSSContainsBox(const Point& bc, const Point& be) +{ + // Not implemented + return FALSE; +} + +#define TEST_BOX_IN_LSS(center, extents) \ + if(LSSContainsBox(center, extents)) \ + { \ + /* Set contact status */ \ + mFlags |= OPC_CONTACT; \ + _Dump(node); \ + return; \ + } + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for normal AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void LSSCollider::_Collide(const AABBCollisionNode* node) +{ + // Perform LSS-AABB overlap test + if(!LSSAABBOverlap(node->mAABB.mCenter, node->mAABB.mExtents)) return; + + TEST_BOX_IN_LSS(node->mAABB.mCenter, node->mAABB.mExtents) + + if(node->IsLeaf()) + { + LSS_PRIM(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _Collide(node->GetPos()); + + if(ContactFound()) return; + + _Collide(node->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for normal AABB trees, without primitive tests. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void LSSCollider::_CollideNoPrimitiveTest(const AABBCollisionNode* node) +{ + // Perform LSS-AABB overlap test + if(!LSSAABBOverlap(node->mAABB.mCenter, node->mAABB.mExtents)) return; + + TEST_BOX_IN_LSS(node->mAABB.mCenter, node->mAABB.mExtents) + + if(node->IsLeaf()) + { + SET_CONTACT(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _CollideNoPrimitiveTest(node->GetPos()); + + if(ContactFound()) return; + + _CollideNoPrimitiveTest(node->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void LSSCollider::_Collide(const AABBQuantizedNode* node) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Perform LSS-AABB overlap test + if(!LSSAABBOverlap(Center, Extents)) return; + + TEST_BOX_IN_LSS(Center, Extents) + + if(node->IsLeaf()) + { + LSS_PRIM(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _Collide(node->GetPos()); + + if(ContactFound()) return; + + _Collide(node->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized AABB trees, without primitive tests. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void LSSCollider::_CollideNoPrimitiveTest(const AABBQuantizedNode* node) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Perform LSS-AABB overlap test + if(!LSSAABBOverlap(Center, Extents)) return; + + TEST_BOX_IN_LSS(Center, Extents) + + if(node->IsLeaf()) + { + SET_CONTACT(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _CollideNoPrimitiveTest(node->GetPos()); + + if(ContactFound()) return; + + _CollideNoPrimitiveTest(node->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for no-leaf AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void LSSCollider::_Collide(const AABBNoLeafNode* node) +{ + // Perform LSS-AABB overlap test + if(!LSSAABBOverlap(node->mAABB.mCenter, node->mAABB.mExtents)) return; + + TEST_BOX_IN_LSS(node->mAABB.mCenter, node->mAABB.mExtents) + + if(node->HasPosLeaf()) { LSS_PRIM(node->GetPosPrimitive(), OPC_CONTACT) } + else _Collide(node->GetPos()); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) { LSS_PRIM(node->GetNegPrimitive(), OPC_CONTACT) } + else _Collide(node->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for no-leaf AABB trees, without primitive tests. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void LSSCollider::_CollideNoPrimitiveTest(const AABBNoLeafNode* node) +{ + // Perform LSS-AABB overlap test + if(!LSSAABBOverlap(node->mAABB.mCenter, node->mAABB.mExtents)) return; + + TEST_BOX_IN_LSS(node->mAABB.mCenter, node->mAABB.mExtents) + + if(node->HasPosLeaf()) { SET_CONTACT(node->GetPosPrimitive(), OPC_CONTACT) } + else _CollideNoPrimitiveTest(node->GetPos()); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) { SET_CONTACT(node->GetNegPrimitive(), OPC_CONTACT) } + else _CollideNoPrimitiveTest(node->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized no-leaf AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void LSSCollider::_Collide(const AABBQuantizedNoLeafNode* node) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Perform LSS-AABB overlap test + if(!LSSAABBOverlap(Center, Extents)) return; + + TEST_BOX_IN_LSS(Center, Extents) + + if(node->HasPosLeaf()) { LSS_PRIM(node->GetPosPrimitive(), OPC_CONTACT) } + else _Collide(node->GetPos()); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) { LSS_PRIM(node->GetNegPrimitive(), OPC_CONTACT) } + else _Collide(node->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized no-leaf AABB trees, without primitive tests. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void LSSCollider::_CollideNoPrimitiveTest(const AABBQuantizedNoLeafNode* node) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Perform LSS-AABB overlap test + if(!LSSAABBOverlap(Center, Extents)) return; + + TEST_BOX_IN_LSS(Center, Extents) + + if(node->HasPosLeaf()) { SET_CONTACT(node->GetPosPrimitive(), OPC_CONTACT) } + else _CollideNoPrimitiveTest(node->GetPos()); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) { SET_CONTACT(node->GetNegPrimitive(), OPC_CONTACT) } + else _CollideNoPrimitiveTest(node->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for vanilla AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void LSSCollider::_Collide(const AABBTreeNode* node) +{ + // Perform LSS-AABB overlap test + Point Center, Extents; + node->GetAABB()->GetCenter(Center); + node->GetAABB()->GetExtents(Extents); + if(!LSSAABBOverlap(Center, Extents)) return; + + if(node->IsLeaf() || LSSContainsBox(Center, Extents)) + { + mFlags |= OPC_CONTACT; + mTouchedPrimitives->Add(node->GetPrimitives(), node->GetNbPrimitives()); + } + else + { + _Collide(node->GetPos()); + _Collide(node->GetNeg()); + } +} + + + + + + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +HybridLSSCollider::HybridLSSCollider() +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +HybridLSSCollider::~HybridLSSCollider() +{ +} + +bool HybridLSSCollider::Collide(LSSCache& cache, const LSS& lss, const HybridModel& model, const Matrix4x4* worldl, const Matrix4x4* worldm) +{ + // We don't want primitive tests here! + mFlags |= OPC_NO_PRIMITIVE_TESTS; + + // Checkings + if(!Setup(&model)) return false; + + // Init collision query + if(InitQuery(cache, lss, worldl, worldm)) return true; + + // Special case for 1-leaf trees + if(mCurrentModel && mCurrentModel->HasSingleNode()) + { + // Here we're supposed to perform a normal query, except our tree has a single node, i.e. just a few triangles + udword Nb = mIMesh->GetNbTriangles(); + + // Loop through all triangles + for(udword i=0;i(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform collision query - we don't want primitive tests here! + _CollideNoPrimitiveTest(Tree->GetNodes()); + } + else + { + const AABBNoLeafTree* Tree = static_cast(model.GetTree()); + + // Perform collision query - we don't want primitive tests here! + _CollideNoPrimitiveTest(Tree->GetNodes()); + } + } + else + { + if(model.IsQuantized()) + { + const AABBQuantizedTree* Tree = static_cast(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform collision query - we don't want primitive tests here! + _CollideNoPrimitiveTest(Tree->GetNodes()); + } + else + { + const AABBCollisionTree* Tree = static_cast(model.GetTree()); + + // Perform collision query - we don't want primitive tests here! + _CollideNoPrimitiveTest(Tree->GetNodes()); + } + } + + // We only have a list of boxes so far + if(GetContactStatus()) + { + // Reset contact status, since it currently only reflects collisions with leaf boxes + Collider::InitQuery(); + + // Change dest container so that we can use built-in overlap tests and get collided primitives + cache.TouchedPrimitives.Reset(); + mTouchedPrimitives = &cache.TouchedPrimitives; + + // Read touched leaf boxes + udword Nb = mTouchedBoxes.GetNbEntries(); + const udword* Touched = mTouchedBoxes.GetEntries(); + + const LeafTriangles* LT = model.GetLeafTriangles(); + const udword* Indices = model.GetIndices(); + + // Loop through touched leaves + while(Nb--) + { + const LeafTriangles& CurrentLeaf = LT[*Touched++]; + + // Each leaf box has a set of triangles + udword NbTris = CurrentLeaf.GetNbTriangles(); + if(Indices) + { + const udword* T = &Indices[CurrentLeaf.GetTriangleIndex()]; + + // Loop through triangles and test each of them + while(NbTris--) + { + udword TriangleIndex = *T++; + LSS_PRIM(TriangleIndex, OPC_CONTACT) + } + } + else + { + udword BaseIndex = CurrentLeaf.GetTriangleIndex(); + + // Loop through triangles and test each of them + while(NbTris--) + { + udword TriangleIndex = BaseIndex++; + LSS_PRIM(TriangleIndex, OPC_CONTACT) + } + } + } + } + + return true; +} diff --git a/libs/ode-0.16.1/OPCODE/OPC_LSSCollider.h b/libs/ode-0.16.1/OPCODE/OPC_LSSCollider.h new file mode 100644 index 0000000..b4d0893 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_LSSCollider.h @@ -0,0 +1,99 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for an LSS collider. + * \file OPC_LSSCollider.h + * \author Pierre Terdiman + * \date December, 28, 2002 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __OPC_LSSCOLLIDER_H__ +#define __OPC_LSSCOLLIDER_H__ + + struct OPCODE_API LSSCache : VolumeCache + { + LSSCache() + { + Previous.mP0 = Point(0.0f, 0.0f, 0.0f); + Previous.mP1 = Point(0.0f, 0.0f, 0.0f); + Previous.mRadius = 0.0f; + FatCoeff = 1.1f; + } + + // Cached faces signature + LSS Previous; //!< LSS used when performing the query resulting in cached faces + // User settings + float FatCoeff; //!< mRadius2 multiplier used to create a fat LSS + }; + + class OPCODE_API LSSCollider : public VolumeCollider + { + public: + // Constructor / Destructor + LSSCollider(); + virtual ~LSSCollider(); + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Generic collision query for generic OPCODE models. After the call, access the results: + * - with GetContactStatus() + * - with GetNbTouchedPrimitives() + * - with GetTouchedPrimitives() + * + * \param cache [in/out] an lss cache + * \param lss [in] collision lss in local space + * \param model [in] Opcode model to collide with + * \param worldl [in] lss world matrix, or null + * \param worldm [in] model's world matrix, or null + * \return true if success + * \warning SCALE NOT SUPPORTED. The matrices must contain rotation & translation parts only. + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + bool Collide(LSSCache& cache, const LSS& lss, const Model& model, const Matrix4x4* worldl=null, const Matrix4x4* worldm=null); + // + bool Collide(LSSCache& cache, const LSS& lss, const AABBTree* tree); + protected: + // LSS in model space + Segment mSeg; //!< Segment + float mRadius2; //!< LSS radius squared + // Internal methods + void _Collide(const AABBCollisionNode* node); + void _Collide(const AABBNoLeafNode* node); + void _Collide(const AABBQuantizedNode* node); + void _Collide(const AABBQuantizedNoLeafNode* node); + void _Collide(const AABBTreeNode* node); + void _CollideNoPrimitiveTest(const AABBCollisionNode* node); + void _CollideNoPrimitiveTest(const AABBNoLeafNode* node); + void _CollideNoPrimitiveTest(const AABBQuantizedNode* node); + void _CollideNoPrimitiveTest(const AABBQuantizedNoLeafNode* node); + // Overlap tests + inline_ BOOL LSSContainsBox(const Point& bc, const Point& be); + inline_ BOOL LSSAABBOverlap(const Point& center, const Point& extents); + inline_ BOOL LSSTriOverlap(const Point& vert0, const Point& vert1, const Point& vert2); + // Init methods + BOOL InitQuery(LSSCache& cache, const LSS& lss, const Matrix4x4* worldl=null, const Matrix4x4* worldm=null); + }; + + class OPCODE_API HybridLSSCollider : public LSSCollider + { + public: + // Constructor / Destructor + HybridLSSCollider(); + virtual ~HybridLSSCollider(); + + bool Collide(LSSCache& cache, const LSS& lss, const HybridModel& model, const Matrix4x4* worldl=null, const Matrix4x4* worldm=null); + protected: + Container mTouchedBoxes; + }; + +#endif // __OPC_LSSCOLLIDER_H__ diff --git a/libs/ode-0.16.1/OPCODE/OPC_LSSTriOverlap.h b/libs/ode-0.16.1/OPCODE/OPC_LSSTriOverlap.h new file mode 100644 index 0000000..f1d17e4 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_LSSTriOverlap.h @@ -0,0 +1,679 @@ +// Following code from Magic-Software (http://www.magic-software.com/) +// A bit modified for Opcode + +static const float gs_fTolerance = 1e-05f; + +static float OPC_PointTriangleSqrDist(const Point& point, const Point& p0, const Point& p1, const Point& p2) +{ + // Hook + Point TriEdge0 = p1 - p0; + Point TriEdge1 = p2 - p0; + + Point kDiff = p0 - point; + float fA00 = TriEdge0.SquareMagnitude(); + float fA01 = TriEdge0 | TriEdge1; + float fA11 = TriEdge1.SquareMagnitude(); + float fB0 = kDiff | TriEdge0; + float fB1 = kDiff | TriEdge1; + float fC = kDiff.SquareMagnitude(); + float fDet = fabsf(fA00*fA11 - fA01*fA01); + float fS = fA01*fB1-fA11*fB0; + float fT = fA01*fB0-fA00*fB1; + float fSqrDist; + + if(fS + fT <= fDet) + { + if(fS < 0.0f) + { + if(fT < 0.0f) // region 4 + { + if(fB0 < 0.0f) + { + if(-fB0 >= fA00) fSqrDist = fA00+2.0f*fB0+fC; + else fSqrDist = fB0*(-fB0/fA00)+fC; + } + else + { + if(fB1 >= 0.0f) fSqrDist = fC; + else if(-fB1 >= fA11) fSqrDist = fA11+2.0f*fB1+fC; + else fSqrDist = fB1*(-fB1/fA11)+fC; + } + } + else // region 3 + { + if(fB1 >= 0.0f) fSqrDist = fC; + else if(-fB1 >= fA11) fSqrDist = fA11+2.0f*fB1+fC; + else fSqrDist = fB1*(-fB1/fA11)+fC; + } + } + else if(fT < 0.0f) // region 5 + { + if(fB0 >= 0.0f) fSqrDist = fC; + else if(-fB0 >= fA00) fSqrDist = fA00+2.0f*fB0+fC; + else fSqrDist = fB0*(-fB0/fA00)+fC; + } + else // region 0 + { + // minimum at interior point + if(fDet==0.0f) + { + fSqrDist = MAX_FLOAT; + } + else + { + float fInvDet = 1.0f/fDet; + fS *= fInvDet; + fT *= fInvDet; + fSqrDist = fS*(fA00*fS+fA01*fT+2.0f*fB0) + fT*(fA01*fS+fA11*fT+2.0f*fB1)+fC; + } + } + } + else + { + float fTmp0, fTmp1, fNumer, fDenom; + + if(fS < 0.0f) // region 2 + { + fTmp0 = fA01 + fB0; + fTmp1 = fA11 + fB1; + if(fTmp1 > fTmp0) + { + fNumer = fTmp1 - fTmp0; + fDenom = fA00-2.0f*fA01+fA11; + if(fNumer >= fDenom) + { + fSqrDist = fA00+2.0f*fB0+fC; + } + else + { + fS = fNumer/fDenom; + fT = 1.0f - fS; + fSqrDist = fS*(fA00*fS+fA01*fT+2.0f*fB0) + fT*(fA01*fS+fA11*fT+2.0f*fB1)+fC; + } + } + else + { + if(fTmp1 <= 0.0f) fSqrDist = fA11+2.0f*fB1+fC; + else if(fB1 >= 0.0f) fSqrDist = fC; + else fSqrDist = fB1*(-fB1/fA11)+fC; + } + } + else if(fT < 0.0f) // region 6 + { + fTmp0 = fA01 + fB1; + fTmp1 = fA00 + fB0; + if(fTmp1 > fTmp0) + { + fNumer = fTmp1 - fTmp0; + fDenom = fA00-2.0f*fA01+fA11; + if(fNumer >= fDenom) + { + fSqrDist = fA11+2.0f*fB1+fC; + } + else + { + fT = fNumer/fDenom; + fS = 1.0f - fT; + fSqrDist = fS*(fA00*fS+fA01*fT+2.0f*fB0) + fT*(fA01*fS+fA11*fT+2.0f*fB1)+fC; + } + } + else + { + if(fTmp1 <= 0.0f) fSqrDist = fA00+2.0f*fB0+fC; + else if(fB0 >= 0.0f) fSqrDist = fC; + else fSqrDist = fB0*(-fB0/fA00)+fC; + } + } + else // region 1 + { + fNumer = fA11 + fB1 - fA01 - fB0; + if(fNumer <= 0.0f) + { + fSqrDist = fA11+2.0f*fB1+fC; + } + else + { + fDenom = fA00-2.0f*fA01+fA11; + if(fNumer >= fDenom) + { + fSqrDist = fA00+2.0f*fB0+fC; + } + else + { + fS = fNumer/fDenom; + fT = 1.0f - fS; + fSqrDist = fS*(fA00*fS+fA01*fT+2.0f*fB0) + fT*(fA01*fS+fA11*fT+2.0f*fB1)+fC; + } + } + } + } + return fabsf(fSqrDist); +} + +static float OPC_SegmentSegmentSqrDist(const Segment& rkSeg0, const Segment& rkSeg1) +{ + // Hook + Point rkSeg0Direction = rkSeg0.ComputeDirection(); + Point rkSeg1Direction = rkSeg1.ComputeDirection(); + + Point kDiff = rkSeg0.mP0 - rkSeg1.mP0; + float fA00 = rkSeg0Direction.SquareMagnitude(); + float fA01 = -rkSeg0Direction.Dot(rkSeg1Direction); + float fA11 = rkSeg1Direction.SquareMagnitude(); + float fB0 = kDiff.Dot(rkSeg0Direction); + float fC = kDiff.SquareMagnitude(); + float fDet = fabsf(fA00*fA11-fA01*fA01); + + float fB1, fS, fT, fSqrDist, fTmp; + + if(fDet>=gs_fTolerance) + { + // line segments are not parallel + fB1 = -kDiff.Dot(rkSeg1Direction); + fS = fA01*fB1-fA11*fB0; + fT = fA01*fB0-fA00*fB1; + + if(fS >= 0.0f) + { + if(fS <= fDet) + { + if(fT >= 0.0f) + { + if(fT <= fDet) // region 0 (interior) + { + // minimum at two interior points of 3D lines + float fInvDet = 1.0f/fDet; + fS *= fInvDet; + fT *= fInvDet; + fSqrDist = fS*(fA00*fS+fA01*fT+2.0f*fB0) + fT*(fA01*fS+fA11*fT+2.0f*fB1)+fC; + } + else // region 3 (side) + { + fTmp = fA01+fB0; + if(fTmp>=0.0f) fSqrDist = fA11+2.0f*fB1+fC; + else if(-fTmp>=fA00) fSqrDist = fA00+fA11+fC+2.0f*(fB1+fTmp); + else fSqrDist = fTmp*(-fTmp/fA00)+fA11+2.0f*fB1+fC; + } + } + else // region 7 (side) + { + if(fB0>=0.0f) fSqrDist = fC; + else if(-fB0>=fA00) fSqrDist = fA00+2.0f*fB0+fC; + else fSqrDist = fB0*(-fB0/fA00)+fC; + } + } + else + { + if ( fT >= 0.0 ) + { + if ( fT <= fDet ) // region 1 (side) + { + fTmp = fA01+fB1; + if(fTmp>=0.0f) fSqrDist = fA00+2.0f*fB0+fC; + else if(-fTmp>=fA11) fSqrDist = fA00+fA11+fC+2.0f*(fB0+fTmp); + else fSqrDist = fTmp*(-fTmp/fA11)+fA00+2.0f*fB0+fC; + } + else // region 2 (corner) + { + fTmp = fA01+fB0; + if ( -fTmp <= fA00 ) + { + if(fTmp>=0.0f) fSqrDist = fA11+2.0f*fB1+fC; + else fSqrDist = fTmp*(-fTmp/fA00)+fA11+2.0f*fB1+fC; + } + else + { + fTmp = fA01+fB1; + if(fTmp>=0.0f) fSqrDist = fA00+2.0f*fB0+fC; + else if(-fTmp>=fA11) fSqrDist = fA00+fA11+fC+2.0f*(fB0+fTmp); + else fSqrDist = fTmp*(-fTmp/fA11)+fA00+2.0f*fB0+fC; + } + } + } + else // region 8 (corner) + { + if ( -fB0 < fA00 ) + { + if(fB0>=0.0f) fSqrDist = fC; + else fSqrDist = fB0*(-fB0/fA00)+fC; + } + else + { + fTmp = fA01+fB1; + if(fTmp>=0.0f) fSqrDist = fA00+2.0f*fB0+fC; + else if(-fTmp>=fA11) fSqrDist = fA00+fA11+fC+2.0f*(fB0+fTmp); + else fSqrDist = fTmp*(-fTmp/fA11)+fA00+2.0f*fB0+fC; + } + } + } + } + else + { + if ( fT >= 0.0f ) + { + if ( fT <= fDet ) // region 5 (side) + { + if(fB1>=0.0f) fSqrDist = fC; + else if(-fB1>=fA11) fSqrDist = fA11+2.0f*fB1+fC; + else fSqrDist = fB1*(-fB1/fA11)+fC; + } + else // region 4 (corner) + { + fTmp = fA01+fB0; + if ( fTmp < 0.0f ) + { + if(-fTmp>=fA00) fSqrDist = fA00+fA11+fC+2.0f*(fB1+fTmp); + else fSqrDist = fTmp*(-fTmp/fA00)+fA11+2.0f*fB1+fC; + } + else + { + if(fB1>=0.0f) fSqrDist = fC; + else if(-fB1>=fA11) fSqrDist = fA11+2.0f*fB1+fC; + else fSqrDist = fB1*(-fB1/fA11)+fC; + } + } + } + else // region 6 (corner) + { + if ( fB0 < 0.0f ) + { + if(-fB0>=fA00) fSqrDist = fA00+2.0f*fB0+fC; + else fSqrDist = fB0*(-fB0/fA00)+fC; + } + else + { + if(fB1>=0.0f) fSqrDist = fC; + else if(-fB1>=fA11) fSqrDist = fA11+2.0f*fB1+fC; + else fSqrDist = fB1*(-fB1/fA11)+fC; + } + } + } + } + else + { + // line segments are parallel + if ( fA01 > 0.0f ) + { + // direction vectors form an obtuse angle + if ( fB0 >= 0.0f ) + { + fSqrDist = fC; + } + else if ( -fB0 <= fA00 ) + { + fSqrDist = fB0*(-fB0/fA00)+fC; + } + else + { + fB1 = -kDiff.Dot(rkSeg1Direction); + fTmp = fA00+fB0; + if ( -fTmp >= fA01 ) + { + fSqrDist = fA00+fA11+fC+2.0f*(fA01+fB0+fB1); + } + else + { + fT = -fTmp/fA01; + fSqrDist = fA00+2.0f*fB0+fC+fT*(fA11*fT+2.0f*(fA01+fB1)); + } + } + } + else + { + // direction vectors form an acute angle + if ( -fB0 >= fA00 ) + { + fSqrDist = fA00+2.0f*fB0+fC; + } + else if ( fB0 <= 0.0f ) + { + fSqrDist = fB0*(-fB0/fA00)+fC; + } + else + { + fB1 = -kDiff.Dot(rkSeg1Direction); + if ( fB0 >= -fA01 ) + { + fSqrDist = fA11+2.0f*fB1+fC; + } + else + { + fT = -fB0/fA01; + fSqrDist = fC+fT*(2.0f*fB1+fA11*fT); + } + } + } + } + return fabsf(fSqrDist); +} + +inline_ float OPC_SegmentRaySqrDist(const Segment& rkSeg0, const Ray& rkSeg1) +{ + return OPC_SegmentSegmentSqrDist(rkSeg0, Segment(rkSeg1.mOrig, rkSeg1.mOrig + rkSeg1.mDir)); +} + +static float OPC_SegmentTriangleSqrDist(const Segment& segment, const Point& p0, const Point& p1, const Point& p2) +{ + // Hook + const Point TriEdge0 = p1 - p0; + const Point TriEdge1 = p2 - p0; + + const Point& rkSegOrigin = segment.GetOrigin(); + Point rkSegDirection = segment.ComputeDirection(); + + Point kDiff = p0 - rkSegOrigin; + float fA00 = rkSegDirection.SquareMagnitude(); + float fA01 = -rkSegDirection.Dot(TriEdge0); + float fA02 = -rkSegDirection.Dot(TriEdge1); + float fA11 = TriEdge0.SquareMagnitude(); + float fA12 = TriEdge0.Dot(TriEdge1); + float fA22 = TriEdge1.Dot(TriEdge1); + float fB0 = -kDiff.Dot(rkSegDirection); + float fB1 = kDiff.Dot(TriEdge0); + float fB2 = kDiff.Dot(TriEdge1); + float fCof00 = fA11*fA22-fA12*fA12; + float fCof01 = fA02*fA12-fA01*fA22; + float fCof02 = fA01*fA12-fA02*fA11; + float fDet = fA00*fCof00+fA01*fCof01+fA02*fCof02; + + Ray kTriSeg; + Point kPt; + float fSqrDist, fSqrDist0; + + if(fabsf(fDet)>=gs_fTolerance) + { + float fCof11 = fA00*fA22-fA02*fA02; + float fCof12 = fA02*fA01-fA00*fA12; + float fCof22 = fA00*fA11-fA01*fA01; + float fInvDet = 1.0f/fDet; + float fRhs0 = -fB0*fInvDet; + float fRhs1 = -fB1*fInvDet; + float fRhs2 = -fB2*fInvDet; + + float fR = fCof00*fRhs0+fCof01*fRhs1+fCof02*fRhs2; + float fS = fCof01*fRhs0+fCof11*fRhs1+fCof12*fRhs2; + float fT = fCof02*fRhs0+fCof12*fRhs1+fCof22*fRhs2; + + if ( fR < 0.0f ) + { + if ( fS+fT <= 1.0f ) + { + if ( fS < 0.0f ) + { + if ( fT < 0.0f ) // region 4m + { + // min on face s=0 or t=0 or r=0 + kTriSeg.mOrig = p0; + kTriSeg.mDir = TriEdge1; + fSqrDist = OPC_SegmentRaySqrDist(segment, kTriSeg); + kTriSeg.mOrig = p0; + kTriSeg.mDir = TriEdge0; + fSqrDist0 = OPC_SegmentRaySqrDist(segment, kTriSeg); + if(fSqrDist0 1 + { + if ( fS+fT <= 1.0f ) + { + if ( fS < 0.0f ) + { + if ( fT < 0.0f ) // region 4p + { + // min on face s=0 or t=0 or r=1 + kTriSeg.mOrig = p0; + kTriSeg.mDir = TriEdge1; + fSqrDist = OPC_SegmentRaySqrDist(segment, kTriSeg); + kTriSeg.mOrig = p0; + kTriSeg.mDir = TriEdge0; + fSqrDist0 = OPC_SegmentRaySqrDist(segment, kTriSeg); + if(fSqrDist0GetTriangle(triangle_index); + * // Setup pointers to vertices for the collision system + * triangle.Vertex[0] = MyMesh->GetVertex(Tri->mVRef[0]); + * triangle.Vertex[1] = MyMesh->GetVertex(Tri->mVRef[1]); + * triangle.Vertex[2] = MyMesh->GetVertex(Tri->mVRef[2]); + * } + * + * // Setup callbacks + * MeshInterface0->SetCallback(ColCallback, udword(Mesh0)); + * MeshInterface1->SetCallback(ColCallback, udword(Mesh1)); + * \endcode + * + * Of course, you should make this callback as fast as possible. And you're also not supposed + * to modify the geometry *after* the collision trees have been built. The alternative was to + * store the geometry & topology in the collision system as well (as in RAPID) but we have found + * this approach to waste a lot of ram in many cases. + * + * + * POINTERS: + * + * If you're internally using the following canonical structures: + * - a vertex made of three 32-bits floating point values + * - a triangle made of three 32-bits integer vertex references + * ...then you may want to use pointers instead of callbacks. This is the same, except OPCODE will directly + * use provided pointers to access the topology and geometry, without using a callback. It might be faster, + * but probably not as safe. Pointers have been introduced in OPCODE 1.2. + * + * Ex: + * + * \code + * // Setup pointers + * MeshInterface0->SetPointers(Mesh0->GetFaces(), Mesh0->GetVerts()); + * MeshInterface1->SetPointers(Mesh1->GetFaces(), Mesh1->GetVerts()); + * \endcode + * + * + * STRIDES: + * + * If your vertices are D3D-like entities interleaving a position, a normal and/or texture coordinates + * (i.e. if your vertices are FVFs), you might want to use a vertex stride to skip extra data OPCODE + * doesn't need. Using a stride shouldn't be notably slower than not using it, but it might increase + * cache misses. Please also note that you *shouldn't* read from AGP or video-memory buffers ! + * + * + * In any case, compilation flags are here to select callbacks/pointers/strides at compile time, so + * choose what's best for your application. All of this has been wrapped into this MeshInterface. + * + * \class MeshInterface + * \author Pierre Terdiman + * \version 1.3 + * \date November, 27, 2002 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace Opcode; + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +MeshInterface::MeshInterface() : + mNbTris (0), + mNbVerts (0), +#ifdef OPC_USE_CALLBACKS + mUserData (null), + mObjCallback (null), + mExUserData (null), + mObjExCallback (null), +#else + #ifdef OPC_USE_STRIDE + mTriStride (sizeof(IndexedTriangle)), + mVertexStride (sizeof(Point)), + mFetchTriangle (&MeshInterface::FetchTriangleFromSingles), + mFetchExTriangle (&MeshInterface::FetchExTriangleFromSingles), + #endif + mTris (null), + mVerts (null) +#endif +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +MeshInterface::~MeshInterface() +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Checks the mesh interface is valid, i.e. things have been setup correctly. + * \return true if valid + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool MeshInterface::IsValid() const +{ + if(!mNbTris || !mNbVerts) return false; +#ifdef OPC_USE_CALLBACKS + if(!mObjCallback) return false; +#else + if(!mTris || !mVerts) return false; +#endif + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Checks the mesh itself is valid. + * Currently we only look for degenerate faces. + * \return number of degenerate faces + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +udword MeshInterface::CheckTopology() const +{ + // Check topology. If the model contains degenerate faces, collision report can be wrong in some cases. + // e.g. it happens with the standard MAX teapot. So clean your meshes first... If you don't have a mesh cleaner + // you can try this: www.codercorner.com/Consolidation.zip + + udword NbDegenerate = 0; + + VertexPointers VP; + ConversionArea VC; + + // Using callbacks, we don't have access to vertex indices. Nevertheless we still can check for + // redundant vertex pointers, which cover all possibilities (callbacks/pointers/strides). + for(udword i=0;imVRef[0] * VertexStride); + vp.Vertex[1] = (const Point*)(((ubyte*)Verts) + T->mVRef[1] * VertexStride); + vp.Vertex[2] = (const Point*)(((ubyte*)Verts) + T->mVRef[2] * VertexStride); +} + +void MeshInterface::FetchTriangleFromDoubles(VertexPointers& vp, udword index, ConversionArea vc) const +{ + const IndexedTriangle* T = (const IndexedTriangle*)(((ubyte*)mTris) + index * mTriStride); + + const Point* Verts = GetVerts(); + udword VertexStride = GetVertexStride(); + + for (int i = 0; i < 3; i++){ + const double* v = (const double*)(((ubyte*)Verts) + T->mVRef[i] * VertexStride); + + vc[i].x = (float)v[0]; + vc[i].y = (float)v[1]; + vc[i].z = (float)v[2]; + vp.Vertex[i] = &vc[i]; + } +} + +void MeshInterface::FetchExTriangleFromSingles(VertexPointersEx& vpe, udword index, ConversionArea vc) const +{ + const IndexedTriangle* T = (const IndexedTriangle*)(((ubyte*)mTris) + index * mTriStride); + + const Point* Verts = GetVerts(); + udword VertexStride = GetVertexStride(); + + dTriIndex VertIndex0 = T->mVRef[0]; + vpe.Index[0] = VertIndex0; + vpe.vp.Vertex[0] = (const Point*)(((ubyte*)Verts) + VertIndex0 * VertexStride); + + dTriIndex VertIndex1 = T->mVRef[1]; + vpe.Index[1] = VertIndex1; + vpe.vp.Vertex[1] = (const Point*)(((ubyte*)Verts) + VertIndex1 * VertexStride); + + dTriIndex VertIndex2 = T->mVRef[2]; + vpe.Index[2] = VertIndex2; + vpe.vp.Vertex[2] = (const Point*)(((ubyte*)Verts) + VertIndex2 * VertexStride); +} + +void MeshInterface::FetchExTriangleFromDoubles(VertexPointersEx& vpe, udword index, ConversionArea vc) const +{ + const IndexedTriangle* T = (const IndexedTriangle*)(((ubyte*)mTris) + index * mTriStride); + + const Point* Verts = GetVerts(); + udword VertexStride = GetVertexStride(); + + for (int i = 0; i < 3; i++){ + dTriIndex VertIndex = T->mVRef[i]; + vpe.Index[i] = VertIndex; + + const double* v = (const double*)(((ubyte*)Verts) + VertIndex * VertexStride); + vc[i].x = (float)v[0]; + vc[i].y = (float)v[1]; + vc[i].z = (float)v[2]; + vpe.vp.Vertex[i] = &vc[i]; + } +} +#endif +#endif + + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Remaps client's mesh according to a permutation. + * \param nb_indices [in] number of indices in the permutation (will be checked against number of triangles) + * \param permutation [in] list of triangle indices + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool MeshInterface::RemapClient(udword nb_indices, const dTriIndex* permutation) const +{ + // Checkings + if(!nb_indices || !permutation) return false; + if(nb_indices!=mNbTris) return false; + +#ifdef OPC_USE_CALLBACKS + // We can't really do that using callbacks + return false; +#else + IndexedTriangle* Tmp = new IndexedTriangle[mNbTris]; + CHECKALLOC(Tmp); + + #ifdef OPC_USE_STRIDE + udword Stride = mTriStride; + #else + udword Stride = sizeof(IndexedTriangle); + #endif + + for(udword i=0;i= 0.0f; + } + }; + + struct VertexPointersEx + { + VertexPointers vp; + dTriIndex Index[3]; + }; + + typedef Point ConversionArea[3]; + +#ifdef OPC_USE_CALLBACKS + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * User-callback, called by OPCODE to request vertices from the app. + * \param triangle_index [in] face index for which the system is requesting the vertices + * \param triangle [out] triangle's vertices (must be provided by the user) + * \param user_data [in] user-defined data from SetCallback() + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + typedef void (*RequestCallback) (udword triangle_index, VertexPointers& triangle, void* user_data); + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * User-callback, called by OPCODE to request vertex indices from the app. + * \param triangle_index [in] face index for which the system is requesting the vertices + * \param triangle [out] triangle's vertices with indices (must be provided by the user) + * \param user_data [in] user-defined data from SetExCallback() + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + typedef void (*RequestExCallback) (udword triangle_index, VertexPointersEx& triangle, void* user_data); +#endif + + class OPCODE_API MeshInterface + { + public: + // Constructor / Destructor + MeshInterface(); + ~MeshInterface(); + // Common settings + inline_ udword GetNbTriangles() const { return mNbTris; } + inline_ udword GetNbVertices() const { return mNbVerts; } + inline_ void SetNbTriangles(udword nb) { mNbTris = nb; } + inline_ void SetNbVertices(udword nb) { mNbVerts = nb; } + +#ifdef OPC_USE_CALLBACKS + // Callback settings + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Callback control: setups object callback. Must provide triangle-vertices for a given triangle index. + * \param callback [in] user-defined callback + * \param user_data [in] user-defined data + * \return true if success + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + bool SetCallback(RequestCallback callback, void* user_data); + inline_ void* GetUserData() const { return mUserData; } + inline_ RequestCallback GetCallback() const { return mObjCallback; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Callback control: setups object callback. Must provide triangle-vertices for a given triangle index. + * \param callback [in] user-defined callback + * \param user_data [in] user-defined data + * \return true if success + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + bool SetExCallback(RequestExCallback callback, void* user_data); + inline_ void* GetExUserData() const { return mExUserData; } + inline_ RequestExCallback GetExCallback() const { return mObjExCallback; } +#else + // Pointers settings + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Pointers control: setups object pointers. Must provide access to faces and vertices for a given object. + * \param tris [in] pointer to triangles + * \param verts [in] pointer to vertices + * \return true if success + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + bool SetPointers(const IndexedTriangle* tris, const Point* verts); + inline_ const IndexedTriangle* GetTris() const { return mTris; } + inline_ const Point* GetVerts() const { return mVerts; } + + #ifdef OPC_USE_STRIDE + // Strides settings + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Strides control + * \param tri_stride [in] size of a triangle in bytes. The first sizeof(IndexedTriangle) bytes are used to get vertex indices. + * \param vertex_stride [in] size of a vertex in bytes. The first sizeof(Point) bytes are used to get vertex position. + * \return true if success + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + bool SetStrides(udword tri_stride=sizeof(IndexedTriangle), udword vertex_stride=sizeof(Point)); + inline_ udword GetTriStride() const { return mTriStride; } + inline_ udword GetVertexStride() const { return mVertexStride; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Single/Double control + * \param value [in] Indicates if mesh data is provided as array of \c single values. If \c false, data is expected to contain \c double elements. + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void SetSingle(bool value) + { + mFetchTriangle = (value ? &MeshInterface::FetchTriangleFromSingles : &MeshInterface::FetchTriangleFromDoubles); + mFetchExTriangle = (value ? &MeshInterface::FetchExTriangleFromSingles : &MeshInterface::FetchExTriangleFromDoubles); + } + + #else + inline_ bool SetStrides(udword tri_stride=sizeof(IndexedTriangle), udword vertex_stride=sizeof(Point)) { return true; } + inline_ void SetSingle(bool value) {} + inline_ udword GetTriStride() const { return sizeof(IndexedTriangle); } + inline_ udword GetVertexStride() const { return sizeof(Point); } + #endif +#endif + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Fetches a triangle given a triangle index. + * \param vp [out] required triangle's vertex pointers + * \param index [in] triangle index + * \param vc [in,out] storage required for data conversion (pass local variable with same scope as \a vp, as \a vp may point to this memory on return) + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void GetTriangle(VertexPointers& vp, udword index, ConversionArea vc) const + { +#ifdef OPC_USE_CALLBACKS + (mObjCallback)(index, vp, mUserData); +#else + #ifdef OPC_USE_STRIDE + // Since there was conditional statement "if (Single)" which was unpredictable for compiler + // and required both branches to be always generated what made inlining a questionable + // benefit, I consider it better to introduce a forced call + // but get rig of branching and dead code injection. + ((*this).*mFetchTriangle)(vp, index, vc); + #else + const Point* Verts = GetVerts(); + const IndexedTriangle* T = &mTris[index]; + vp.Vertex[0] = &Verts[T->mVRef[0]]; + vp.Vertex[1] = &Verts[T->mVRef[1]]; + vp.Vertex[2] = &Verts[T->mVRef[2]]; + #endif +#endif + } + + inline_ bool GetExTriangle(VertexPointersEx& vpe, udword index, ConversionArea vc) const + { +#ifdef OPC_USE_CALLBACKS + if (mObjExCallback) { (mObjExCallback)(index, vpe, mUserData); return true; } + else { (mObjCallback)(index, vpe.vp, mUserData); return false; } +#else + #ifdef OPC_USE_STRIDE + // Since there was conditional statement "if (Single)" which was unpredictable for compiler + // and required both branches to be always generated what made inlining a questionable + // benefit, I consider it better to introduce a forced call + // but get rig of branching and dead code injection. + ((*this).*mFetchExTriangle)(vpe, index, vc); + return true; + #else + const Point* Verts = GetVerts(); + const IndexedTriangle* T = &mTris[index]; + dTriIndex VertIndex0 = T->mVRef[0]; + vpe.Index[0] = VertIndex0; + vpe.vp.Vertex[0] = &Verts[VertIndex0]; + dTriIndex VertIndex1 = T->mVRef[1]; + vpe.Index[1] = VertIndex1; + vpe.vp.Vertex[1] = &Verts[VertIndex1]; + dTriIndex VertIndex2 = T->mVRef[2]; + vpe.Index[2] = VertIndex2; + vpe.vp.Vertex[2] = &Verts[VertIndex2]; + return true; + #endif +#endif + } + + private: +#ifndef OPC_USE_CALLBACKS + #ifdef OPC_USE_STRIDE + void FetchTriangleFromSingles(VertexPointers& vp, udword index, ConversionArea vc) const; + void FetchTriangleFromDoubles(VertexPointers& vp, udword index, ConversionArea vc) const; + void FetchExTriangleFromSingles(VertexPointersEx& vpe, udword index, ConversionArea vc) const; + void FetchExTriangleFromDoubles(VertexPointersEx& vpe, udword index, ConversionArea vc) const; + #endif +#endif + + public: + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Remaps client's mesh according to a permutation. + * \param nb_indices [in] number of indices in the permutation (will be checked against number of triangles) + * \param permutation [in] list of triangle indices + * \return true if success + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + bool RemapClient(udword nb_indices, const dTriIndex* permutation) const; + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Checks the mesh interface is valid, i.e. things have been setup correctly. + * \return true if valid + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + bool IsValid() const; + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Checks the mesh itself is valid. + * Currently we only look for degenerate faces. + * \return number of degenerate faces + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + udword CheckTopology() const; + private: + + udword mNbTris; //!< Number of triangles in the input model + udword mNbVerts; //!< Number of vertices in the input model +#ifdef OPC_USE_CALLBACKS + // User callback + void* mUserData; //!< User-defined data sent to callback + RequestCallback mObjCallback; //!< Object callback + void* mExUserData; //!< User-defined data sent to ex-callback + RequestExCallback mObjExCallback; //!< Object ex-callback +#else + // User pointers + #ifdef OPC_USE_STRIDE + udword mTriStride; //!< Possible triangle stride in bytes [Opcode 1.3] + udword mVertexStride; //!< Possible vertex stride in bytes [Opcode 1.3] + typedef void (MeshInterface:: *TriangleFetchProc)(VertexPointers& vp, udword index, ConversionArea vc) const; + TriangleFetchProc mFetchTriangle; + typedef void (MeshInterface:: *ExTriangleFetchProc)(VertexPointersEx& vpe, udword index, ConversionArea vc) const; + ExTriangleFetchProc mFetchExTriangle; + #endif + const IndexedTriangle* mTris; //!< Array of indexed triangles + const Point* mVerts; //!< Array of vertices +#endif + }; + +#endif //__OPC_MESHINTERFACE_H__ diff --git a/libs/ode-0.16.1/OPCODE/OPC_Model.cpp b/libs/ode-0.16.1/OPCODE/OPC_Model.cpp new file mode 100644 index 0000000..418dd7e --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_Model.cpp @@ -0,0 +1,222 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for OPCODE models. + * \file OPC_Model.cpp + * \author Pierre Terdiman + * \date March, 20, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * The main collision wrapper, for all trees. Supported trees are: + * - Normal trees (2*N-1 nodes, full size) + * - No-leaf trees (N-1 nodes, full size) + * - Quantized trees (2*N-1 nodes, half size) + * - Quantized no-leaf trees (N-1 nodes, half size) + * + * Usage: + * + * 1) Create a static mesh interface using callbacks or pointers. (see OPC_MeshInterface.cpp). + * Keep it around in your app, since a pointer to this interface is saved internally and + * used until you release the collision structures. + * + * 2) Build a Model using a creation structure: + * + * \code + * Model Sample; + * + * OPCODECREATE OPCC; + * OPCC.IMesh = ...; + * OPCC.Rules = ...; + * OPCC.NoLeaf = ...; + * OPCC.Quantized = ...; + * OPCC.KeepOriginal = ...; + * bool Status = Sample.Build(OPCC); + * \endcode + * + * 3) Create a tree collider and set it up: + * + * \code + * AABBTreeCollider TC; + * TC.SetFirstContact(...); + * TC.SetFullBoxBoxTest(...); + * TC.SetFullPrimBoxTest(...); + * TC.SetTemporalCoherence(...); + * \endcode + * + * 4) Perform a collision query + * + * \code + * // Setup cache + * static BVTCache ColCache; + * ColCache.Model0 = &Model0; + * ColCache.Model1 = &Model1; + * + * // Collision query + * bool IsOk = TC.Collide(ColCache, World0, World1); + * + * // Get collision status => if true, objects overlap + * BOOL Status = TC.GetContactStatus(); + * + * // Number of colliding pairs and list of pairs + * udword NbPairs = TC.GetNbPairs(); + * const Pair* p = TC.GetPairs() + * \endcode + * + * 5) Stats + * + * \code + * Model0.GetUsedBytes() = number of bytes used for this collision tree + * TC.GetNbBVBVTests() = number of BV-BV overlap tests performed during last query + * TC.GetNbPrimPrimTests() = number of Triangle-Triangle overlap tests performed during last query + * TC.GetNbBVPrimTests() = number of Triangle-BV overlap tests performed during last query + * \endcode + * + * \class Model + * \author Pierre Terdiman + * \version 1.3 + * \date March, 20, 2001 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace Opcode; + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +Model::Model() +{ +#ifdef __MESHMERIZER_H__ // Collision hulls only supported within ICE ! + mHull = null; +#endif // __MESHMERIZER_H__ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +Model::~Model() +{ + Release(); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Releases the model. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void Model::Release() +{ + ReleaseBase(); +#ifdef __MESHMERIZER_H__ // Collision hulls only supported within ICE ! + DELETESINGLE(mHull); +#endif // __MESHMERIZER_H__ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Builds a collision model. + * \param create [in] model creation structure + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool Model::Build(const OPCODECREATE& create) +{ + // 1) Checkings + if(!create.mIMesh || !create.mIMesh->IsValid()) return false; + + // For this model, we only support complete trees + if(create.mSettings.mLimit!=1) return SetIceError("OPCODE WARNING: supports complete trees only! Use mLimit = 1.\n", null); + + // Look for degenerate faces. + //udword NbDegenerate = create.mIMesh->CheckTopology(); + //if(NbDegenerate) Log("OPCODE WARNING: found %d degenerate faces in model! Collision might report wrong results!\n", NbDegenerate); + // We continue nonetheless.... + + Release(); // Make sure previous tree has been discarded [Opcode 1.3, thanks Adam] + + // 1-1) Setup mesh interface automatically [Opcode 1.3] + SetMeshInterface(create.mIMesh); + + // Special case for 1-triangle meshes [Opcode 1.3] + udword NbTris = create.mIMesh->GetNbTriangles(); + if(NbTris==1) + { + // We don't need to actually create a tree here, since we'll only have a single triangle to deal with anyway. + // It's a waste to use a "model" for this but at least it will work. + mModelCode |= OPC_SINGLE_NODE; + return true; + } + + // 2) Build a generic AABB Tree. + mSource = new AABBTree; + CHECKALLOC(mSource); + + // 2-1) Setup a builder. Our primitives here are triangles from input mesh, + // so we use an AABBTreeOfTrianglesBuilder..... + { + AABBTreeOfTrianglesBuilder TB; + TB.mIMesh = create.mIMesh; + TB.mSettings = create.mSettings; + TB.mNbPrimitives = NbTris; + if(!mSource->Build(&TB)) return false; + } + + // 3) Create an optimized tree according to user-settings + if(!CreateTree(create.mNoLeaf, create.mQuantized)) return false; + + // 3-2) Create optimized tree + if(!mTree->Build(mSource)) return false; + + // 3-3) Delete generic tree if needed + if(!create.mKeepOriginal) DELETESINGLE(mSource); + +#ifdef __MESHMERIZER_H__ + // 4) Convex hull + if(create.mCollisionHull) + { + // Create hull + mHull = new CollisionHull; + CHECKALLOC(mHull); + + CONVEXHULLCREATE CHC; + // ### doesn't work with strides + CHC.NbVerts = create.mIMesh->GetNbVertices(); + CHC.Vertices = create.mIMesh->GetVerts(); + CHC.UnifyNormals = true; + CHC.ReduceVertices = true; + CHC.WordFaces = false; + mHull->Compute(CHC); + } +#endif // __MESHMERIZER_H__ + + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Gets the number of bytes used by the tree. + * \return amount of bytes used + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +udword Model::GetUsedBytes() const +{ + if(!mTree) return 0; + return mTree->GetUsedBytes(); +} diff --git a/libs/ode-0.16.1/OPCODE/OPC_Model.h b/libs/ode-0.16.1/OPCODE/OPC_Model.h new file mode 100644 index 0000000..98dee56 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_Model.h @@ -0,0 +1,65 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for OPCODE models. + * \file OPC_Model.h + * \author Pierre Terdiman + * \date March, 20, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __OPC_MODEL_H__ +#define __OPC_MODEL_H__ + + class OPCODE_API Model : public BaseModel + { + public: + // Constructor/Destructor + Model(); + virtual ~Model(); + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Builds a collision model. + * \param create [in] model creation structure + * \return true if success + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + override(BaseModel) bool Build(const OPCODECREATE& create); + +#ifdef __MESHMERIZER_H__ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets the collision hull. + * \return the collision hull if it exists + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ const CollisionHull* GetHull() const { return mHull; } +#endif // __MESHMERIZER_H__ + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets the number of bytes used by the tree. + * \return amount of bytes used + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + override(BaseModel) udword GetUsedBytes() const; + + private: +#ifdef __MESHMERIZER_H__ + CollisionHull* mHull; //!< Possible convex hull +#endif // __MESHMERIZER_H__ + // Internal methods + void Release(); + }; + +#endif //__OPC_MODEL_H__ diff --git a/libs/ode-0.16.1/OPCODE/OPC_OBBCollider.cpp b/libs/ode-0.16.1/OPCODE/OPC_OBBCollider.cpp new file mode 100644 index 0000000..730c7cc --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_OBBCollider.cpp @@ -0,0 +1,767 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for an OBB collider. + * \file OPC_OBBCollider.cpp + * \author Pierre Terdiman + * \date January, 1st, 2002 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains an OBB-vs-tree collider. + * + * \class OBBCollider + * \author Pierre Terdiman + * \version 1.3 + * \date January, 1st, 2002 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace Opcode; + +#include "OPC_BoxBoxOverlap.h" +#include "OPC_TriBoxOverlap.h" + +#define SET_CONTACT(prim_index, flag) \ + /* Set contact status */ \ + mFlags |= flag; \ + mTouchedPrimitives->Add(udword(prim_index)); + +//! OBB-triangle test +#define OBB_PRIM(prim_index, flag) \ + /* Request vertices from the app */ \ + VertexPointers VP; ConversionArea VC; mIMesh->GetTriangle(VP, prim_index, VC); \ + /* Transform them in a common space */ \ + TransformPoint(mLeafVerts[0], *VP.Vertex[0], mRModelToBox, mTModelToBox); \ + TransformPoint(mLeafVerts[1], *VP.Vertex[1], mRModelToBox, mTModelToBox); \ + TransformPoint(mLeafVerts[2], *VP.Vertex[2], mRModelToBox, mTModelToBox); \ + /* Perform triangle-box overlap test */ \ + if(TriBoxOverlap()) \ + { \ + SET_CONTACT(prim_index, flag) \ + } + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +OBBCollider::OBBCollider() : mFullBoxBoxTest(true) +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +OBBCollider::~OBBCollider() +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Validates current settings. You should call this method after all the settings and callbacks have been defined. + * \return null if everything is ok, else a string describing the problem + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +const char* OBBCollider::ValidateSettings() +{ + if(TemporalCoherenceEnabled() && !FirstContactEnabled()) return "Temporal coherence only works with ""First contact"" mode!"; + + return VolumeCollider::ValidateSettings(); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Generic collision query for generic OPCODE models. After the call, access the results: + * - with GetContactStatus() + * - with GetNbTouchedPrimitives() + * - with GetTouchedPrimitives() + * + * \param cache [in/out] a box cache + * \param box [in] collision OBB in local space + * \param model [in] Opcode model to collide with + * \param worldb [in] OBB's world matrix, or null + * \param worldm [in] model's world matrix, or null + * \return true if success + * \warning SCALE NOT SUPPORTED. The matrices must contain rotation & translation parts only. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool OBBCollider::Collide(OBBCache& cache, const OBB& box, const Model& model, const Matrix4x4* worldb, const Matrix4x4* worldm) +{ + // Checkings + if(!Setup(&model)) return false; + + // Init collision query + if(InitQuery(cache, box, worldb, worldm)) return true; + + if(!model.HasLeafNodes()) + { + if(model.IsQuantized()) + { + const AABBQuantizedNoLeafTree* Tree = static_cast(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform collision query + if(SkipPrimitiveTests()) _CollideNoPrimitiveTest(Tree->GetNodes()); + else _Collide(Tree->GetNodes()); + } + else + { + const AABBNoLeafTree* Tree = static_cast(model.GetTree()); + + // Perform collision query + if(SkipPrimitiveTests()) _CollideNoPrimitiveTest(Tree->GetNodes()); + else _Collide(Tree->GetNodes()); + } + } + else + { + if(model.IsQuantized()) + { + const AABBQuantizedTree* Tree = static_cast(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform collision query + if(SkipPrimitiveTests()) _CollideNoPrimitiveTest(Tree->GetNodes()); + else _Collide(Tree->GetNodes()); + } + else + { + const AABBCollisionTree* Tree = static_cast(model.GetTree()); + + // Perform collision query + if(SkipPrimitiveTests()) _CollideNoPrimitiveTest(Tree->GetNodes()); + else _Collide(Tree->GetNodes()); + } + } + + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Initializes a collision query : + * - reset stats & contact status + * - setup matrices + * - check temporal coherence + * + * \param cache [in/out] a box cache + * \param box [in] obb in local space + * \param worldb [in] obb's world matrix, or null + * \param worldm [in] model's world matrix, or null + * \return TRUE if we can return immediately + * \warning SCALE NOT SUPPORTED. The matrices must contain rotation & translation parts only. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +BOOL OBBCollider::InitQuery(OBBCache& cache, const OBB& box, const Matrix4x4* worldb, const Matrix4x4* worldm) +{ + // 1) Call the base method + VolumeCollider::InitQuery(); + + // 2) Compute obb in world space + mBoxExtents = box.mExtents; + + Matrix4x4 WorldB; + + if(worldb) + { + WorldB = Matrix4x4( box.mRot * Matrix3x3(*worldb) ); + WorldB.SetTrans(box.mCenter * *worldb); + } + else + { + WorldB = box.mRot; + WorldB.SetTrans(box.mCenter); + } + + // Setup matrices + Matrix4x4 InvWorldB; + InvertPRMatrix(InvWorldB, WorldB); + + if(worldm) + { + Matrix4x4 InvWorldM; + InvertPRMatrix(InvWorldM, *worldm); + + Matrix4x4 WorldBtoM = WorldB * InvWorldM; + Matrix4x4 WorldMtoB = *worldm * InvWorldB; + + mRModelToBox = WorldMtoB; WorldMtoB.GetTrans(mTModelToBox); + mRBoxToModel = WorldBtoM; WorldBtoM.GetTrans(mTBoxToModel); + } + else + { + mRModelToBox = InvWorldB; InvWorldB.GetTrans(mTModelToBox); + mRBoxToModel = WorldB; WorldB.GetTrans(mTBoxToModel); + } + + // 3) Setup destination pointer + mTouchedPrimitives = &cache.TouchedPrimitives; + + // 4) Special case: 1-triangle meshes [Opcode 1.3] + if(mCurrentModel && mCurrentModel->HasSingleNode()) + { + if(!SkipPrimitiveTests()) + { + // We simply perform the BV-Prim overlap test each time. We assume single triangle has index 0. + mTouchedPrimitives->Reset(); + + // Perform overlap test between the unique triangle and the box (and set contact status if needed) + OBB_PRIM(udword(0), OPC_CONTACT) + + // Return immediately regardless of status + return TRUE; + } + } + + // 5) Check temporal coherence: + if(TemporalCoherenceEnabled()) + { + // Here we use temporal coherence + // => check results from previous frame before performing the collision query + if(FirstContactEnabled()) + { + // We're only interested in the first contact found => test the unique previously touched face + if(mTouchedPrimitives->GetNbEntries()) + { + // Get index of previously touched face = the first entry in the array + udword PreviouslyTouchedFace = mTouchedPrimitives->GetEntry(0); + + // Then reset the array: + // - if the overlap test below is successful, the index we'll get added back anyway + // - if it isn't, then the array should be reset anyway for the normal query + mTouchedPrimitives->Reset(); + + // Perform overlap test between the cached triangle and the box (and set contact status if needed) + OBB_PRIM(PreviouslyTouchedFace, OPC_TEMPORAL_CONTACT) + + // Return immediately if possible + if(GetContactStatus()) return TRUE; + } + // else no face has been touched during previous query + // => we'll have to perform a normal query + } + else + { + // ### rewrite this + OBB TestBox(mTBoxToModel, mBoxExtents, mRBoxToModel); + + // We're interested in all contacts =>test the new real box N(ew) against the previous fat box P(revious): + if(IsCacheValid(cache) && TestBox.IsInside(cache.FatBox)) + { + // - if N is included in P, return previous list + // => we simply leave the list (mTouchedFaces) unchanged + + // Set contact status if needed + if(mTouchedPrimitives->GetNbEntries()) mFlags |= OPC_TEMPORAL_CONTACT; + + // In any case we don't need to do a query + return TRUE; + } + else + { + // - else do the query using a fat N + + // Reset cache since we'll about to perform a real query + mTouchedPrimitives->Reset(); + + // Make a fat box so that coherence will work for subsequent frames + TestBox.mExtents *= cache.FatCoeff; + mBoxExtents *= cache.FatCoeff; + + // Update cache with query data (signature for cached faces) + cache.FatBox = TestBox; + } + } + } + else + { + // Here we don't use temporal coherence => do a normal query + mTouchedPrimitives->Reset(); + } + + // Now we can precompute box-box data + + // Precompute absolute box-to-model rotation matrix + for(udword i=0;i<3;i++) + { + for(udword j=0;j<3;j++) + { + // Epsilon value prevents floating-point inaccuracies (strategy borrowed from RAPID) + mAR.m[i][j] = 1e-6f + fabsf(mRBoxToModel.m[i][j]); + } + } + + // Precompute bounds for box-in-box test + mB0 = mBoxExtents - mTModelToBox; + mB1 = - mBoxExtents - mTModelToBox; + + // Precompute box-box data - Courtesy of Erwin de Vries + mBBx1 = mBoxExtents.x*mAR.m[0][0] + mBoxExtents.y*mAR.m[1][0] + mBoxExtents.z*mAR.m[2][0]; + mBBy1 = mBoxExtents.x*mAR.m[0][1] + mBoxExtents.y*mAR.m[1][1] + mBoxExtents.z*mAR.m[2][1]; + mBBz1 = mBoxExtents.x*mAR.m[0][2] + mBoxExtents.y*mAR.m[1][2] + mBoxExtents.z*mAR.m[2][2]; + + mBB_1 = mBoxExtents.y*mAR.m[2][0] + mBoxExtents.z*mAR.m[1][0]; + mBB_2 = mBoxExtents.x*mAR.m[2][0] + mBoxExtents.z*mAR.m[0][0]; + mBB_3 = mBoxExtents.x*mAR.m[1][0] + mBoxExtents.y*mAR.m[0][0]; + mBB_4 = mBoxExtents.y*mAR.m[2][1] + mBoxExtents.z*mAR.m[1][1]; + mBB_5 = mBoxExtents.x*mAR.m[2][1] + mBoxExtents.z*mAR.m[0][1]; + mBB_6 = mBoxExtents.x*mAR.m[1][1] + mBoxExtents.y*mAR.m[0][1]; + mBB_7 = mBoxExtents.y*mAR.m[2][2] + mBoxExtents.z*mAR.m[1][2]; + mBB_8 = mBoxExtents.x*mAR.m[2][2] + mBoxExtents.z*mAR.m[0][2]; + mBB_9 = mBoxExtents.x*mAR.m[1][2] + mBoxExtents.y*mAR.m[0][2]; + + return FALSE; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Checks the OBB completely contains the box. In which case we can end the query sooner. + * \param bc [in] box center + * \param be [in] box extents + * \return true if the OBB contains the whole box + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +inline_ BOOL OBBCollider::OBBContainsBox(const Point& bc, const Point& be) +{ + // I assume if all 8 box vertices are inside the OBB, so does the whole box. + // Sounds ok but maybe there's a better way? +/* +#define TEST_PT(a,b,c) \ + p.x=a; p.y=b; p.z=c; p+=bc; \ + f = p.x * mRModelToBox.m[0][0] + p.y * mRModelToBox.m[1][0] + p.z * mRModelToBox.m[2][0]; if(f>mB0.x || fmB0.y || fmB0.z || f NCx-NEx) return FALSE; + + float NCy = bc.x * mRModelToBox.m[0][1] + bc.y * mRModelToBox.m[1][1] + bc.z * mRModelToBox.m[2][1]; + float NEy = fabsf(mRModelToBox.m[0][1] * be.x) + fabsf(mRModelToBox.m[1][1] * be.y) + fabsf(mRModelToBox.m[2][1] * be.z); + + if(mB0.y < NCy+NEy) return FALSE; + if(mB1.y > NCy-NEy) return FALSE; + + float NCz = bc.x * mRModelToBox.m[0][2] + bc.y * mRModelToBox.m[1][2] + bc.z * mRModelToBox.m[2][2]; + float NEz = fabsf(mRModelToBox.m[0][2] * be.x) + fabsf(mRModelToBox.m[1][2] * be.y) + fabsf(mRModelToBox.m[2][2] * be.z); + + if(mB0.z < NCz+NEz) return FALSE; + if(mB1.z > NCz-NEz) return FALSE; + + return TRUE; +} + +#define TEST_BOX_IN_OBB(center, extents) \ + if(OBBContainsBox(center, extents)) \ + { \ + /* Set contact status */ \ + mFlags |= OPC_CONTACT; \ + _Dump(node); \ + return; \ + } + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for normal AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void OBBCollider::_Collide(const AABBCollisionNode* node) +{ + // Perform OBB-AABB overlap test + if(!BoxBoxOverlap(node->mAABB.mExtents, node->mAABB.mCenter)) return; + + TEST_BOX_IN_OBB(node->mAABB.mCenter, node->mAABB.mExtents) + + if(node->IsLeaf()) + { + OBB_PRIM(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _Collide(node->GetPos()); + + if(ContactFound()) return; + + _Collide(node->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for normal AABB trees, without primitive tests. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void OBBCollider::_CollideNoPrimitiveTest(const AABBCollisionNode* node) +{ + // Perform OBB-AABB overlap test + if(!BoxBoxOverlap(node->mAABB.mExtents, node->mAABB.mCenter)) return; + + TEST_BOX_IN_OBB(node->mAABB.mCenter, node->mAABB.mExtents) + + if(node->IsLeaf()) + { + SET_CONTACT(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _CollideNoPrimitiveTest(node->GetPos()); + + if(ContactFound()) return; + + _CollideNoPrimitiveTest(node->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void OBBCollider::_Collide(const AABBQuantizedNode* node) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Perform OBB-AABB overlap test + if(!BoxBoxOverlap(Extents, Center)) return; + + TEST_BOX_IN_OBB(Center, Extents) + + if(node->IsLeaf()) + { + OBB_PRIM(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _Collide(node->GetPos()); + + if(ContactFound()) return; + + _Collide(node->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized AABB trees, without primitive tests. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void OBBCollider::_CollideNoPrimitiveTest(const AABBQuantizedNode* node) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Perform OBB-AABB overlap test + if(!BoxBoxOverlap(Extents, Center)) return; + + TEST_BOX_IN_OBB(Center, Extents) + + if(node->IsLeaf()) + { + SET_CONTACT(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _CollideNoPrimitiveTest(node->GetPos()); + + if(ContactFound()) return; + + _CollideNoPrimitiveTest(node->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for no-leaf AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void OBBCollider::_Collide(const AABBNoLeafNode* node) +{ + // Perform OBB-AABB overlap test + if(!BoxBoxOverlap(node->mAABB.mExtents, node->mAABB.mCenter)) return; + + TEST_BOX_IN_OBB(node->mAABB.mCenter, node->mAABB.mExtents) + + if(node->HasPosLeaf()) { OBB_PRIM(node->GetPosPrimitive(), OPC_CONTACT) } + else _Collide(node->GetPos()); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) { OBB_PRIM(node->GetNegPrimitive(), OPC_CONTACT) } + else _Collide(node->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for no-leaf AABB trees, without primitive tests. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void OBBCollider::_CollideNoPrimitiveTest(const AABBNoLeafNode* node) +{ + // Perform OBB-AABB overlap test + if(!BoxBoxOverlap(node->mAABB.mExtents, node->mAABB.mCenter)) return; + + TEST_BOX_IN_OBB(node->mAABB.mCenter, node->mAABB.mExtents) + + if(node->HasPosLeaf()) { SET_CONTACT(node->GetPosPrimitive(), OPC_CONTACT) } + else _CollideNoPrimitiveTest(node->GetPos()); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) { SET_CONTACT(node->GetNegPrimitive(), OPC_CONTACT) } + else _CollideNoPrimitiveTest(node->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized no-leaf AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void OBBCollider::_Collide(const AABBQuantizedNoLeafNode* node) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Perform OBB-AABB overlap test + if(!BoxBoxOverlap(Extents, Center)) return; + + TEST_BOX_IN_OBB(Center, Extents) + + if(node->HasPosLeaf()) { OBB_PRIM(node->GetPosPrimitive(), OPC_CONTACT) } + else _Collide(node->GetPos()); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) { OBB_PRIM(node->GetNegPrimitive(), OPC_CONTACT) } + else _Collide(node->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized no-leaf AABB trees, without primitive tests. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void OBBCollider::_CollideNoPrimitiveTest(const AABBQuantizedNoLeafNode* node) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Perform OBB-AABB overlap test + if(!BoxBoxOverlap(Extents, Center)) return; + + TEST_BOX_IN_OBB(Center, Extents) + + if(node->HasPosLeaf()) { SET_CONTACT(node->GetPosPrimitive(), OPC_CONTACT) } + else _CollideNoPrimitiveTest(node->GetPos()); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) { SET_CONTACT(node->GetNegPrimitive(), OPC_CONTACT) } + else _CollideNoPrimitiveTest(node->GetNeg()); +} + + + + + + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +HybridOBBCollider::HybridOBBCollider() +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +HybridOBBCollider::~HybridOBBCollider() +{ +} + +bool HybridOBBCollider::Collide(OBBCache& cache, const OBB& box, const HybridModel& model, const Matrix4x4* worldb, const Matrix4x4* worldm) +{ + // We don't want primitive tests here! + mFlags |= OPC_NO_PRIMITIVE_TESTS; + + // Checkings + if(!Setup(&model)) return false; + + // Init collision query + if(InitQuery(cache, box, worldb, worldm)) return true; + + // Special case for 1-leaf trees + if(mCurrentModel && mCurrentModel->HasSingleNode()) + { + // Here we're supposed to perform a normal query, except our tree has a single node, i.e. just a few triangles + udword Nb = mIMesh->GetNbTriangles(); + + // Loop through all triangles + for(udword i=0;i(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform collision query - we don't want primitive tests here! + _CollideNoPrimitiveTest(Tree->GetNodes()); + } + else + { + const AABBNoLeafTree* Tree = static_cast(model.GetTree()); + + // Perform collision query - we don't want primitive tests here! + _CollideNoPrimitiveTest(Tree->GetNodes()); + } + } + else + { + if(model.IsQuantized()) + { + const AABBQuantizedTree* Tree = static_cast(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform collision query - we don't want primitive tests here! + _CollideNoPrimitiveTest(Tree->GetNodes()); + } + else + { + const AABBCollisionTree* Tree = static_cast(model.GetTree()); + + // Perform collision query - we don't want primitive tests here! + _CollideNoPrimitiveTest(Tree->GetNodes()); + } + } + + // We only have a list of boxes so far + if(GetContactStatus()) + { + // Reset contact status, since it currently only reflects collisions with leaf boxes + Collider::InitQuery(); + + // Change dest container so that we can use built-in overlap tests and get collided primitives + cache.TouchedPrimitives.Reset(); + mTouchedPrimitives = &cache.TouchedPrimitives; + + // Read touched leaf boxes + udword Nb = mTouchedBoxes.GetNbEntries(); + const udword* Touched = mTouchedBoxes.GetEntries(); + + const LeafTriangles* LT = model.GetLeafTriangles(); + const udword* Indices = model.GetIndices(); + + // Loop through touched leaves + while(Nb--) + { + const LeafTriangles& CurrentLeaf = LT[*Touched++]; + + // Each leaf box has a set of triangles + udword NbTris = CurrentLeaf.GetNbTriangles(); + if(Indices) + { + const udword* T = &Indices[CurrentLeaf.GetTriangleIndex()]; + + // Loop through triangles and test each of them + while(NbTris--) + { + udword TriangleIndex = *T++; + OBB_PRIM(TriangleIndex, OPC_CONTACT) + } + } + else + { + udword BaseIndex = CurrentLeaf.GetTriangleIndex(); + + // Loop through triangles and test each of them + while(NbTris--) + { + udword TriangleIndex = BaseIndex++; + OBB_PRIM(TriangleIndex, OPC_CONTACT) + } + } + } + } + + return true; +} diff --git a/libs/ode-0.16.1/OPCODE/OPC_OBBCollider.h b/libs/ode-0.16.1/OPCODE/OPC_OBBCollider.h new file mode 100644 index 0000000..a050118 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_OBBCollider.h @@ -0,0 +1,142 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for an OBB collider. + * \file OPC_OBBCollider.h + * \author Pierre Terdiman + * \date January, 1st, 2002 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __OPC_OBBCOLLIDER_H__ +#define __OPC_OBBCOLLIDER_H__ + + struct OPCODE_API OBBCache : VolumeCache + { + OBBCache() : FatCoeff(1.1f) + { + FatBox.mCenter.Zero(); + FatBox.mExtents.Zero(); + FatBox.mRot.Identity(); + } + + // Cached faces signature + OBB FatBox; //!< Box used when performing the query resulting in cached faces + // User settings + float FatCoeff; //!< extents multiplier used to create a fat box + }; + + class OPCODE_API OBBCollider : public VolumeCollider + { + public: + // Constructor / Destructor + OBBCollider(); + virtual ~OBBCollider(); + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Generic collision query for generic OPCODE models. After the call, access the results: + * - with GetContactStatus() + * - with GetNbTouchedPrimitives() + * - with GetTouchedPrimitives() + * + * \param cache [in/out] a box cache + * \param box [in] collision OBB in local space + * \param model [in] Opcode model to collide with + * \param worldb [in] OBB's world matrix, or null + * \param worldm [in] model's world matrix, or null + * \return true if success + * \warning SCALE NOT SUPPORTED. The matrices must contain rotation & translation parts only. + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + bool Collide(OBBCache& cache, const OBB& box, const Model& model, const Matrix4x4* worldb=null, const Matrix4x4* worldm=null); + + // Settings + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Settings: select between full box-box tests or "SAT-lite" tests (where Class III axes are discarded) + * \param flag [in] true for full tests, false for coarse tests + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void SetFullBoxBoxTest(bool flag) { mFullBoxBoxTest = flag; } + + // Settings + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Validates current settings. You should call this method after all the settings and callbacks have been defined for a collider. + * \return null if everything is ok, else a string describing the problem + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + override(Collider) const char* ValidateSettings(); + + protected: + // Precomputed data + Matrix3x3 mAR; //!< Absolute rotation matrix + Matrix3x3 mRModelToBox; //!< Rotation from model space to obb space + Matrix3x3 mRBoxToModel; //!< Rotation from obb space to model space + Point mTModelToBox; //!< Translation from model space to obb space + Point mTBoxToModel; //!< Translation from obb space to model space + + Point mBoxExtents; + Point mB0; //!< - mTModelToBox + mBoxExtents + Point mB1; //!< - mTModelToBox - mBoxExtents + + float mBBx1; + float mBBy1; + float mBBz1; + + float mBB_1; + float mBB_2; + float mBB_3; + float mBB_4; + float mBB_5; + float mBB_6; + float mBB_7; + float mBB_8; + float mBB_9; + + // Leaf description + Point mLeafVerts[3]; //!< Triangle vertices + // Settings + bool mFullBoxBoxTest; //!< Perform full BV-BV tests (true) or SAT-lite tests (false) + // Internal methods + void _Collide(const AABBCollisionNode* node); + void _Collide(const AABBNoLeafNode* node); + void _Collide(const AABBQuantizedNode* node); + void _Collide(const AABBQuantizedNoLeafNode* node); + void _CollideNoPrimitiveTest(const AABBCollisionNode* node); + void _CollideNoPrimitiveTest(const AABBNoLeafNode* node); + void _CollideNoPrimitiveTest(const AABBQuantizedNode* node); + void _CollideNoPrimitiveTest(const AABBQuantizedNoLeafNode* node); + // Overlap tests + inline_ BOOL OBBContainsBox(const Point& bc, const Point& be); + inline_ BOOL BoxBoxOverlap(const Point& extents, const Point& center); + inline_ BOOL TriBoxOverlap(); + // Init methods + BOOL InitQuery(OBBCache& cache, const OBB& box, const Matrix4x4* worldb=null, const Matrix4x4* worldm=null); + }; + + class OPCODE_API HybridOBBCollider : public OBBCollider + { + public: + // Constructor / Destructor + HybridOBBCollider(); + virtual ~HybridOBBCollider(); + + bool Collide(OBBCache& cache, const OBB& box, const HybridModel& model, const Matrix4x4* worldb=null, const Matrix4x4* worldm=null); + protected: + Container mTouchedBoxes; + }; + +#endif // __OPC_OBBCOLLIDER_H__ diff --git a/libs/ode-0.16.1/OPCODE/OPC_OptimizedTree.cpp b/libs/ode-0.16.1/OPCODE/OPC_OptimizedTree.cpp new file mode 100644 index 0000000..057853e --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_OptimizedTree.cpp @@ -0,0 +1,795 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for optimized trees. Implements 4 trees: + * - normal + * - no leaf + * - quantized + * - no leaf / quantized + * + * \file OPC_OptimizedTree.cpp + * \author Pierre Terdiman + * \date March, 20, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * A standard AABB tree. + * + * \class AABBCollisionTree + * \author Pierre Terdiman + * \version 1.3 + * \date March, 20, 2001 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * A no-leaf AABB tree. + * + * \class AABBNoLeafTree + * \author Pierre Terdiman + * \version 1.3 + * \date March, 20, 2001 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * A quantized AABB tree. + * + * \class AABBQuantizedTree + * \author Pierre Terdiman + * \version 1.3 + * \date March, 20, 2001 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * A quantized no-leaf AABB tree. + * + * \class AABBQuantizedNoLeafTree + * \author Pierre Terdiman + * \version 1.3 + * \date March, 20, 2001 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace Opcode; + +//! Compilation flag: +//! - true to fix quantized boxes (i.e. make sure they enclose the original ones) +//! - false to see the effects of quantization errors (faster, but wrong results in some cases) +static const bool gFixQuantized = true; + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Builds an implicit tree from a standard one. An implicit tree is a complete tree (2*N-1 nodes) whose negative + * box pointers and primitive pointers have been made implicit, hence packing 3 pointers in one. + * + * Layout for implicit trees: + * Node: + * - box + * - data (32-bits value) + * + * if data's LSB = 1 => remaining bits are a primitive pointer + * else remaining bits are a P-node pointer, and N = P + 1 + * + * \relates AABBCollisionNode + * \fn _BuildCollisionTree(AABBCollisionNode* linear, const udword box_id, udword& current_id, const AABBTreeNode* current_node) + * \param linear [in] base address of destination nodes + * \param box_id [in] index of destination node + * \param current_id [in] current running index + * \param current_node [in] current node from input tree + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +static void _BuildCollisionTree(AABBCollisionNode* linear, const udword box_id, udword& current_id, const AABBTreeNode* current_node) +{ + // Current node from input tree is "current_node". Must be flattened into "linear[boxid]". + + // Store the AABB + current_node->GetAABB()->GetCenter(linear[box_id].mAABB.mCenter); + current_node->GetAABB()->GetExtents(linear[box_id].mAABB.mExtents); + // Store remaining info + if(current_node->IsLeaf()) + { + // The input tree must be complete => i.e. one primitive/leaf + ASSERT(current_node->GetNbPrimitives()==1); + // Get the primitive index from the input tree + udword PrimitiveIndex = current_node->GetPrimitives()[0]; + // Setup box data as the primitive index, marked as leaf + linear[box_id].mData = (PrimitiveIndex<<1)|1; + } + else + { + // To make the negative one implicit, we must store P and N in successive order + udword PosID = current_id++; // Get a new id for positive child + udword NegID = current_id++; // Get a new id for negative child + // Setup box data as the forthcoming new P pointer + linear[box_id].mData = (size_t)&linear[PosID]; + // Make sure it's not marked as leaf + ASSERT(!(linear[box_id].mData&1)); + // Recurse with new IDs + _BuildCollisionTree(linear, PosID, current_id, current_node->GetPos()); + _BuildCollisionTree(linear, NegID, current_id, current_node->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Builds a "no-leaf" tree from a standard one. This is a tree whose leaf nodes have been removed. + * + * Layout for no-leaf trees: + * + * Node: + * - box + * - P pointer => a node (LSB=0) or a primitive (LSB=1) + * - N pointer => a node (LSB=0) or a primitive (LSB=1) + * + * \relates AABBNoLeafNode + * \fn _BuildNoLeafTree(AABBNoLeafNode* linear, const udword box_id, udword& current_id, const AABBTreeNode* current_node) + * \param linear [in] base address of destination nodes + * \param box_id [in] index of destination node + * \param current_id [in] current running index + * \param current_node [in] current node from input tree + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +static void _BuildNoLeafTree(AABBNoLeafNode* linear, const udword box_id, udword& current_id, const AABBTreeNode* current_node) +{ + const AABBTreeNode* P = current_node->GetPos(); + const AABBTreeNode* N = current_node->GetNeg(); + // Leaf nodes here?! + ASSERT(P); + ASSERT(N); + // Internal node => keep the box + current_node->GetAABB()->GetCenter(linear[box_id].mAABB.mCenter); + current_node->GetAABB()->GetExtents(linear[box_id].mAABB.mExtents); + + if(P->IsLeaf()) + { + // The input tree must be complete => i.e. one primitive/leaf + ASSERT(P->GetNbPrimitives()==1); + // Get the primitive index from the input tree + udword PrimitiveIndex = P->GetPrimitives()[0]; + // Setup prev box data as the primitive index, marked as leaf + linear[box_id].mPosData = (PrimitiveIndex<<1)|1; + } + else + { + // Get a new id for positive child + udword PosID = current_id++; + // Setup box data + linear[box_id].mPosData = (size_t)&linear[PosID]; + // Make sure it's not marked as leaf + ASSERT(!(linear[box_id].mPosData&1)); + // Recurse + _BuildNoLeafTree(linear, PosID, current_id, P); + } + + if(N->IsLeaf()) + { + // The input tree must be complete => i.e. one primitive/leaf + ASSERT(N->GetNbPrimitives()==1); + // Get the primitive index from the input tree + udword PrimitiveIndex = N->GetPrimitives()[0]; + // Setup prev box data as the primitive index, marked as leaf + linear[box_id].mNegData = (PrimitiveIndex<<1)|1; + } + else + { + // Get a new id for negative child + udword NegID = current_id++; + // Setup box data + linear[box_id].mNegData = (size_t)&linear[NegID]; + // Make sure it's not marked as leaf + ASSERT(!(linear[box_id].mNegData&1)); + // Recurse + _BuildNoLeafTree(linear, NegID, current_id, N); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +AABBCollisionTree::AABBCollisionTree() : mNodes(null) +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +AABBCollisionTree::~AABBCollisionTree() +{ + DELETEARRAY(mNodes); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Builds the collision tree from a generic AABB tree. + * \param tree [in] generic AABB tree + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBCollisionTree::Build(AABBTree* tree) +{ + // Checkings + if(!tree) return false; + // Check the input tree is complete + udword NbTriangles = tree->GetNbPrimitives(); + udword NbNodes = tree->GetNbNodes(); + if(NbNodes!=NbTriangles*2-1) return false; + + // Get nodes + if(mNbNodes!=NbNodes) // Same number of nodes => keep moving + { + mNbNodes = NbNodes; + DELETEARRAY(mNodes); + mNodes = new AABBCollisionNode[NbNodes]; + CHECKALLOC(mNodes); + } + + // Build the tree + udword CurID = 1; + _BuildCollisionTree(mNodes, 0, CurID, tree); + ASSERT(CurID==NbNodes); + + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Refits the collision tree after vertices have been modified. + * \param mesh_interface [in] mesh interface for current model + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBCollisionTree::Refit(const MeshInterface* /*mesh_interface*/) +{ + ASSERT(!"Not implemented since AABBCollisionTrees have twice as more nodes to refit as AABBNoLeafTrees!"); + return false; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Walks the tree and call the user back for each node. + * \param callback [in] walking callback + * \param user_data [in] callback's user data + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBCollisionTree::Walk(GenericWalkingCallback callback, void* user_data) const +{ + if(!callback) return false; + + struct Local + { + static void _Walk(const AABBCollisionNode* current_node, GenericWalkingCallback callback, void* user_data) + { + if(!current_node || !(callback)(current_node, user_data)) return; + + if(!current_node->IsLeaf()) + { + _Walk(current_node->GetPos(), callback, user_data); + _Walk(current_node->GetNeg(), callback, user_data); + } + } + }; + Local::_Walk(mNodes, callback, user_data); + return true; +} + + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +AABBNoLeafTree::AABBNoLeafTree() : mNodes(null) +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +AABBNoLeafTree::~AABBNoLeafTree() +{ + DELETEARRAY(mNodes); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Builds the collision tree from a generic AABB tree. + * \param tree [in] generic AABB tree + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBNoLeafTree::Build(AABBTree* tree) +{ + // Checkings + if(!tree) return false; + // Check the input tree is complete + udword NbTriangles = tree->GetNbPrimitives(); + udword NbExistingNodes = tree->GetNbNodes(); + if(NbExistingNodes!=NbTriangles*2-1) return false; + + udword NbNodes = NbTriangles-1; + // Get nodes + if(mNbNodes!=NbNodes) // Same number of nodes => keep moving + { + mNbNodes = NbNodes; + DELETEARRAY(mNodes); + mNodes = new AABBNoLeafNode[NbNodes]; + CHECKALLOC(mNodes); + } + + // Build the tree + udword CurID = 1; + _BuildNoLeafTree(mNodes, 0, CurID, tree); + ASSERT(CurID==NbNodes); + + return true; +} + +inline_ void ComputeMinMax(Point& min, Point& max, const VertexPointers& vp) +{ + // Compute triangle's AABB = a leaf box +#ifdef OPC_USE_FCOMI // a 15% speedup on my machine, not much + min.x = FCMin3(vp.Vertex[0]->x, vp.Vertex[1]->x, vp.Vertex[2]->x); + max.x = FCMax3(vp.Vertex[0]->x, vp.Vertex[1]->x, vp.Vertex[2]->x); + + min.y = FCMin3(vp.Vertex[0]->y, vp.Vertex[1]->y, vp.Vertex[2]->y); + max.y = FCMax3(vp.Vertex[0]->y, vp.Vertex[1]->y, vp.Vertex[2]->y); + + min.z = FCMin3(vp.Vertex[0]->z, vp.Vertex[1]->z, vp.Vertex[2]->z); + max.z = FCMax3(vp.Vertex[0]->z, vp.Vertex[1]->z, vp.Vertex[2]->z); +#else + min = *vp.Vertex[0]; + max = *vp.Vertex[0]; + min.Min(*vp.Vertex[1]); + max.Max(*vp.Vertex[1]); + min.Min(*vp.Vertex[2]); + max.Max(*vp.Vertex[2]); +#endif +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Refits the collision tree after vertices have been modified. + * \param mesh_interface [in] mesh interface for current model + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBNoLeafTree::Refit(const MeshInterface* mesh_interface) +{ + // Checkings + if(!mesh_interface) return false; + + // Bottom-up update + VertexPointers VP; + ConversionArea VC; + Point Min,Max; + Point Min_,Max_; + udword Index = mNbNodes; + while(Index--) + { + AABBNoLeafNode& Current = mNodes[Index]; + + if(Current.HasPosLeaf()) + { + mesh_interface->GetTriangle(VP, Current.GetPosPrimitive(), VC); + ComputeMinMax(Min, Max, VP); + } + else + { + const CollisionAABB& CurrentBox = Current.GetPos()->mAABB; + CurrentBox.GetMin(Min); + CurrentBox.GetMax(Max); + } + + if(Current.HasNegLeaf()) + { + mesh_interface->GetTriangle(VP, Current.GetNegPrimitive(), VC); + ComputeMinMax(Min_, Max_, VP); + } + else + { + const CollisionAABB& CurrentBox = Current.GetNeg()->mAABB; + CurrentBox.GetMin(Min_); + CurrentBox.GetMax(Max_); + } +#ifdef OPC_USE_FCOMI + Min.x = FCMin2(Min.x, Min_.x); + Max.x = FCMax2(Max.x, Max_.x); + Min.y = FCMin2(Min.y, Min_.y); + Max.y = FCMax2(Max.y, Max_.y); + Min.z = FCMin2(Min.z, Min_.z); + Max.z = FCMax2(Max.z, Max_.z); +#else + Min.Min(Min_); + Max.Max(Max_); +#endif + Current.mAABB.SetMinMax(Min, Max); + } + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Walks the tree and call the user back for each node. + * \param callback [in] walking callback + * \param user_data [in] callback's user data + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBNoLeafTree::Walk(GenericWalkingCallback callback, void* user_data) const +{ + if(!callback) return false; + + struct Local + { + static void _Walk(const AABBNoLeafNode* current_node, GenericWalkingCallback callback, void* user_data) + { + if(!current_node || !(callback)(current_node, user_data)) return; + + if(!current_node->HasPosLeaf()) _Walk(current_node->GetPos(), callback, user_data); + if(!current_node->HasNegLeaf()) _Walk(current_node->GetNeg(), callback, user_data); + } + }; + Local::_Walk(mNodes, callback, user_data); + return true; +} + +// Quantization notes: +// - We could use the highest bits of mData to store some more quantized bits. Dequantization code +// would be slightly more complex, but number of overlap tests would be reduced (and anyhow those +// bits are currently wasted). Of course it's not possible if we move to 16 bits mData. +// - Something like "16 bits floats" could be tested, to bypass the int-to-float conversion. +// - A dedicated BV-BV test could be used, dequantizing while testing for overlap. (i.e. it's some +// lazy-dequantization which may save some work in case of early exits). At the very least some +// muls could be saved by precomputing several more matrices. But maybe not worth the pain. +// - Do we need to dequantize anyway? Not doing the extents-related muls only implies the box has +// been scaled, for example. +// - The deeper we move into the hierarchy, the smaller the extents should be. May not need a fixed +// number of quantization bits. Even better, could probably be best delta-encoded. + + +// Find max values. Some people asked why I wasn't simply using the first node. Well, I can't. +// I'm not looking for (min, max) values like in a standard AABB, I'm looking for the extremal +// centers/extents in order to quantize them. The first node would only give a single center and +// a single extents. While extents would be the biggest, the center wouldn't. +#define FIND_MAX_VALUES \ + /* Get max values */ \ + Point CMax(MIN_FLOAT, MIN_FLOAT, MIN_FLOAT); \ + Point EMax(MIN_FLOAT, MIN_FLOAT, MIN_FLOAT); \ + const udword NbNodes = mNbNodes; \ + for(udword i=0;iCMax.x) CMax.x = cx; \ + float cy = fabsf(Nodes[i].mAABB.mCenter.y); if(cy>CMax.y) CMax.y = cy; \ + float cz = fabsf(Nodes[i].mAABB.mCenter.z); if(cz>CMax.z) CMax.z = cz; \ + float ex = fabsf(Nodes[i].mAABB.mExtents.x); if(ex>EMax.x) EMax.x = ex; \ + float ey = fabsf(Nodes[i].mAABB.mExtents.y); if(ey>EMax.y) EMax.y = ey; \ + float ez = fabsf(Nodes[i].mAABB.mExtents.z); if(ez>EMax.z) EMax.z = ez; \ + } + +#define INIT_QUANTIZATION \ + udword nbc=15; /* Keep one bit for sign */ \ + udword nbe=15; /* Keep one bit for fix */ \ + if(!gFixQuantized) nbe++; \ + \ + /* Compute quantization coeffs */ \ + Point CQuantCoeff, EQuantCoeff; \ + CQuantCoeff.x = CMax.x!=0.0f ? float((1<Min[j]) \ + { \ + mNodes[i].mAABB.mExtents[j]++; \ + /* Prevent wrapping */ \ + if(!mNodes[i].mAABB.mExtents[j]) \ + { \ + mNodes[i].mAABB.mExtents[j]=0xffff; \ + FixMe=false; \ + } \ + } \ + else FixMe=false; \ + }while(FixMe); \ + } \ + } + +#define REMAP_DATA(member, NodeType) \ + /* Fix data */ \ + Data = Nodes[i].member; \ + if(!(Data&1)) \ + { \ + /* Compute box number */ \ + size_t Nb = ((NodeType *)(Data) - (Nodes)); \ + Data = (size_t) &mNodes[Nb]; \ + } \ + /* ...remapped */ \ + mNodes[i].member = Data; + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +AABBQuantizedTree::AABBQuantizedTree() : mNodes(null) +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +AABBQuantizedTree::~AABBQuantizedTree() +{ + DELETEARRAY(mNodes); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Builds the collision tree from a generic AABB tree. + * \param tree [in] generic AABB tree + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBQuantizedTree::Build(AABBTree* tree) +{ + // Checkings + if(!tree) return false; + // Check the input tree is complete + udword NbTriangles = tree->GetNbPrimitives(); + udword NbNodes = tree->GetNbNodes(); + if(NbNodes!=NbTriangles*2-1) return false; + + // Get nodes + mNbNodes = NbNodes; + DELETEARRAY(mNodes); + AABBCollisionNode* Nodes = new AABBCollisionNode[NbNodes]; + CHECKALLOC(Nodes); + + // Build the tree + udword CurID = 1; + _BuildCollisionTree(Nodes, 0, CurID, tree); + + // Quantize + { + mNodes = new AABBQuantizedNode[NbNodes]; + + if (mNodes != null) + { + // Get max values + FIND_MAX_VALUES + + // Quantization + INIT_QUANTIZATION + + // Quantize + size_t Data; + for(udword i=0;iIsLeaf()) + { + _Walk(current_node->GetPos(), callback, user_data); + _Walk(current_node->GetNeg(), callback, user_data); + } + } + }; + Local::_Walk(mNodes, callback, user_data); + return true; +} + + + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +AABBQuantizedNoLeafTree::AABBQuantizedNoLeafTree() : mNodes(null) +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +AABBQuantizedNoLeafTree::~AABBQuantizedNoLeafTree() +{ + DELETEARRAY(mNodes); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Builds the collision tree from a generic AABB tree. + * \param tree [in] generic AABB tree + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBQuantizedNoLeafTree::Build(AABBTree* tree) +{ + // Checkings + if(!tree) return false; + // Check the input tree is complete + udword NbTriangles = tree->GetNbPrimitives(); + udword NbExistingNodes = tree->GetNbNodes(); + if(NbExistingNodes!=NbTriangles*2-1) return false; + + // Get nodes + udword NbNodes = NbTriangles-1; + mNbNodes = NbNodes; + DELETEARRAY(mNodes); + AABBNoLeafNode* Nodes = new AABBNoLeafNode[NbNodes]; + CHECKALLOC(Nodes); + + // Build the tree + udword CurID = 1; + _BuildNoLeafTree(Nodes, 0, CurID, tree); + ASSERT(CurID==NbNodes); + + // Quantize + { + mNodes = new AABBQuantizedNoLeafNode[NbNodes]; + + if (mNodes != null) + { + // Get max values + FIND_MAX_VALUES + + // Quantization + INIT_QUANTIZATION + + // Quantize + size_t Data; + for(udword i=0;iHasPosLeaf()) _Walk(current_node->GetPos(), callback, user_data); + if(!current_node->HasNegLeaf()) _Walk(current_node->GetNeg(), callback, user_data); + } + }; + Local::_Walk(mNodes, callback, user_data); + return true; +} diff --git a/libs/ode-0.16.1/OPCODE/OPC_OptimizedTree.h b/libs/ode-0.16.1/OPCODE/OPC_OptimizedTree.h new file mode 100644 index 0000000..36aea07 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_OptimizedTree.h @@ -0,0 +1,206 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for optimized trees. + * \file OPC_OptimizedTree.h + * \author Pierre Terdiman + * \date March, 20, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __OPC_OPTIMIZEDTREE_H__ +#define __OPC_OPTIMIZEDTREE_H__ + + //! Common interface for a node of an implicit tree + #define IMPLEMENT_IMPLICIT_NODE(base_class, volume) \ + public: \ + /* Constructor / Destructor */ \ + inline_ base_class() : mData(0) {} \ + inline_ ~base_class() {} \ + /* Leaf test */ \ + inline_ BOOL IsLeaf() const { return (mData&1)!=0; } \ + /* Data access */ \ + inline_ const base_class* GetPos() const { return (base_class*)mData; } \ + inline_ const base_class* GetNeg() const { return ((base_class*)mData)+1; } \ + inline_ size_t GetPrimitive() const { return (mData>>1); } \ + /* Stats */ \ + inline_ udword GetNodeSize() const { return SIZEOFOBJECT; } \ + \ + volume mAABB; \ + size_t mData; + + //! Common interface for a node of a no-leaf tree + #define IMPLEMENT_NOLEAF_NODE(base_class, volume) \ + public: \ + /* Constructor / Destructor */ \ + inline_ base_class() : mPosData(0), mNegData(0) {} \ + inline_ ~base_class() {} \ + /* Leaf tests */ \ + inline_ BOOL HasPosLeaf() const { return (mPosData&1)!=0; } \ + inline_ BOOL HasNegLeaf() const { return (mNegData&1)!=0; } \ + /* Data access */ \ + inline_ const base_class* GetPos() const { return (base_class*)mPosData; } \ + inline_ const base_class* GetNeg() const { return (base_class*)mNegData; } \ + inline_ size_t GetPosPrimitive() const { return (mPosData>>1); } \ + inline_ size_t GetNegPrimitive() const { return (mNegData>>1); } \ + /* Stats */ \ + inline_ udword GetNodeSize() const { return SIZEOFOBJECT; } \ + \ + volume mAABB; \ + size_t mPosData; \ + size_t mNegData; + + class OPCODE_API AABBCollisionNode + { + IMPLEMENT_IMPLICIT_NODE(AABBCollisionNode, CollisionAABB) + + inline_ float GetVolume() const { return mAABB.mExtents.x * mAABB.mExtents.y * mAABB.mExtents.z; } + inline_ float GetSize() const { return mAABB.mExtents.SquareMagnitude(); } + inline_ udword GetRadius() const + { + udword* Bits = (udword*)&mAABB.mExtents.x; + udword Max = Bits[0]; + if(Bits[1]>Max) Max = Bits[1]; + if(Bits[2]>Max) Max = Bits[2]; + return Max; + } + + // NB: using the square-magnitude or the true volume of the box, seems to yield better results + // (assuming UNC-like informed traversal methods). I borrowed this idea from PQP. The usual "size" + // otherwise, is the largest box extent. In SOLID that extent is computed on-the-fly each time it's + // needed (the best approach IMHO). In RAPID the rotation matrix is permuted so that Extent[0] is + // always the greatest, which saves looking for it at runtime. On the other hand, it yields matrices + // whose determinant is not 1, i.e. you can't encode them anymore as unit quaternions. Not a very + // good strategy. + }; + + class OPCODE_API AABBQuantizedNode + { + IMPLEMENT_IMPLICIT_NODE(AABBQuantizedNode, QuantizedAABB) + + inline_ uword GetSize() const + { + const uword* Bits = mAABB.mExtents; + uword Max = Bits[0]; + if(Bits[1]>Max) Max = Bits[1]; + if(Bits[2]>Max) Max = Bits[2]; + return Max; + } + // NB: for quantized nodes I don't feel like computing a square-magnitude with integers all + // over the place.......! + }; + + class OPCODE_API AABBNoLeafNode + { + IMPLEMENT_NOLEAF_NODE(AABBNoLeafNode, CollisionAABB) + }; + + class OPCODE_API AABBQuantizedNoLeafNode + { + IMPLEMENT_NOLEAF_NODE(AABBQuantizedNoLeafNode, QuantizedAABB) + }; + + //! Common interface for a collision tree + #define IMPLEMENT_COLLISION_TREE(base_class, node) \ + public: \ + /* Constructor / Destructor */ \ + base_class(); \ + virtual ~base_class(); \ + /* Builds from a standard tree */ \ + override(AABBOptimizedTree) bool Build(AABBTree* tree); \ + /* Refits the tree */ \ + override(AABBOptimizedTree) bool Refit(const MeshInterface* mesh_interface); \ + /* Walks the tree */ \ + override(AABBOptimizedTree) bool Walk(GenericWalkingCallback callback, void* user_data) const; \ + /* Data access */ \ + inline_ const node* GetNodes() const { return mNodes; } \ + /* Stats */ \ + override(AABBOptimizedTree) udword GetUsedBytes() const { return mNbNodes*sizeof(node); } \ + private: \ + node* mNodes; + + typedef bool (*GenericWalkingCallback) (const void* current, void* user_data); + + class OPCODE_API AABBOptimizedTree + { + public: + // Constructor / Destructor + AABBOptimizedTree() : + mNbNodes (0) + {} + virtual ~AABBOptimizedTree() {} + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Builds the collision tree from a generic AABB tree. + * \param tree [in] generic AABB tree + * \return true if success + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + virtual bool Build(AABBTree* tree) = 0; + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Refits the collision tree after vertices have been modified. + * \param mesh_interface [in] mesh interface for current model + * \return true if success + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + virtual bool Refit(const MeshInterface* mesh_interface) = 0; + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Walks the tree and call the user back for each node. + * \param callback [in] walking callback + * \param user_data [in] callback's user data + * \return true if success + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + virtual bool Walk(GenericWalkingCallback callback, void* user_data) const = 0; + + // Data access + virtual udword GetUsedBytes() const = 0; + inline_ udword GetNbNodes() const { return mNbNodes; } + + protected: + udword mNbNodes; + }; + + class OPCODE_API AABBCollisionTree : public AABBOptimizedTree + { + IMPLEMENT_COLLISION_TREE(AABBCollisionTree, AABBCollisionNode) + }; + + class OPCODE_API AABBNoLeafTree : public AABBOptimizedTree + { + IMPLEMENT_COLLISION_TREE(AABBNoLeafTree, AABBNoLeafNode) + }; + + class OPCODE_API AABBQuantizedTree : public AABBOptimizedTree + { + IMPLEMENT_COLLISION_TREE(AABBQuantizedTree, AABBQuantizedNode) + + public: + Point mCenterCoeff; + Point mExtentsCoeff; + }; + + class OPCODE_API AABBQuantizedNoLeafTree : public AABBOptimizedTree + { + IMPLEMENT_COLLISION_TREE(AABBQuantizedNoLeafTree, AABBQuantizedNoLeafNode) + + public: + Point mCenterCoeff; + Point mExtentsCoeff; + }; + +#endif // __OPC_OPTIMIZEDTREE_H__ diff --git a/libs/ode-0.16.1/OPCODE/OPC_Picking.cpp b/libs/ode-0.16.1/OPCODE/OPC_Picking.cpp new file mode 100644 index 0000000..0f4c6c3 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_Picking.cpp @@ -0,0 +1,183 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code to perform "picking". + * \file OPC_Picking.cpp + * \author Pierre Terdiman + * \date March, 20, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace Opcode; + +#ifdef OPC_RAYHIT_CALLBACK + +/* + Possible RayCollider usages: + - boolean query (shadow feeler) + - closest hit + - all hits + - number of intersection (boolean) + +*/ + +bool Opcode::SetupAllHits(RayCollider& collider, CollisionFaces& contacts) +{ + struct Local + { + static void AllContacts(const CollisionFace& hit, void* user_data) + { + CollisionFaces* CF = (CollisionFaces*)user_data; + CF->AddFace(hit); + } + }; + + collider.SetFirstContact(false); + collider.SetHitCallback(Local::AllContacts); + collider.SetUserData(&contacts); + return true; +} + +bool Opcode::SetupClosestHit(RayCollider& collider, CollisionFace& closest_contact) +{ + struct Local + { + static void ClosestContact(const CollisionFace& hit, void* user_data) + { + CollisionFace* CF = (CollisionFace*)user_data; + if(hit.mDistancemDistance) *CF = hit; + } + }; + + collider.SetFirstContact(false); + collider.SetHitCallback(Local::ClosestContact); + collider.SetUserData(&closest_contact); + closest_contact.mDistance = MAX_FLOAT; + return true; +} + +bool Opcode::SetupShadowFeeler(RayCollider& collider) +{ + collider.SetFirstContact(true); + collider.SetHitCallback(null); + return true; +} + +bool Opcode::SetupInOutTest(RayCollider& collider) +{ + collider.SetFirstContact(false); + collider.SetHitCallback(null); + // Results with collider.GetNbIntersections() + return true; +} + +bool Opcode::Picking( +CollisionFace& picked_face, +const Ray& world_ray, const Model& model, const Matrix4x4* world, +float min_dist, float max_dist, const Point& view_point, CullModeCallback callback, void* user_data) +{ + struct Local + { + struct CullData + { + CollisionFace* Closest; + float MinLimit; + CullModeCallback Callback; + void* UserData; + Point ViewPoint; + const MeshInterface* IMesh; + }; + + // Called for each stabbed face + static void RenderCullingCallback(const CollisionFace& hit, void* user_data) + { + CullData* Data = (CullData*)user_data; + + // Discard face if we already have a closer hit + if(hit.mDistance>=Data->Closest->mDistance) return; + + // Discard face if hit point is smaller than min limit. This mainly happens when the face is in front + // of the near clip plane (or straddles it). If we keep the face nonetheless, the user can select an + // object that he may not even be able to see, which is very annoying. + if(hit.mDistance<=Data->MinLimit) return; + + // This is the index of currently stabbed triangle. + udword StabbedFaceIndex = hit.mFaceID; + + // We may keep it or not, depending on backface culling + bool KeepIt = true; + + // Catch *render* cull mode for this face + CullMode CM = (Data->Callback)(StabbedFaceIndex, Data->UserData); + + if(CM!=CULLMODE_NONE) // Don't even compute culling for double-sided triangles + { + // Compute backface culling for current face + + VertexPointers VP; + ConversionArea VC; + Data->IMesh->GetTriangle(VP, StabbedFaceIndex, VC); + if(VP.BackfaceCulling(Data->ViewPoint)) + { + if(CM==CULLMODE_CW) KeepIt = false; + } + else + { + if(CM==CULLMODE_CCW) KeepIt = false; + } + } + + if(KeepIt) *Data->Closest = hit; + } + }; + + RayCollider RC; + RC.SetMaxDist(max_dist); + RC.SetTemporalCoherence(false); + RC.SetCulling(false); // We need all faces since some of them can be double-sided + RC.SetFirstContact(false); + RC.SetHitCallback(Local::RenderCullingCallback); + + picked_face.mFaceID = INVALID_ID; + picked_face.mDistance = MAX_FLOAT; + picked_face.mU = 0.0f; + picked_face.mV = 0.0f; + + Local::CullData Data; + Data.Closest = &picked_face; + Data.MinLimit = min_dist; + Data.Callback = callback; + Data.UserData = user_data; + Data.ViewPoint = view_point; + Data.IMesh = model.GetMeshInterface(); + + if(world) + { + // Get matrices + Matrix4x4 InvWorld; + InvertPRMatrix(InvWorld, *world); + + // Compute camera position in mesh space + Data.ViewPoint *= InvWorld; + } + + RC.SetUserData(&Data); + if(RC.Collide(world_ray, model, world)) + { + return picked_face.mFaceID!=INVALID_ID; + } + return false; +} + +#endif diff --git a/libs/ode-0.16.1/OPCODE/OPC_Picking.h b/libs/ode-0.16.1/OPCODE/OPC_Picking.h new file mode 100644 index 0000000..d22fa38 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_Picking.h @@ -0,0 +1,45 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code to perform "picking". + * \file OPC_Picking.h + * \author Pierre Terdiman + * \date March, 20, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __OPC_PICKING_H__ +#define __OPC_PICKING_H__ + +#ifdef OPC_RAYHIT_CALLBACK + + enum CullMode + { + CULLMODE_NONE = 0, + CULLMODE_CW = 1, + CULLMODE_CCW = 2 + }; + + typedef CullMode (*CullModeCallback)(udword triangle_index, void* user_data); + + OPCODE_API bool SetupAllHits (RayCollider& collider, CollisionFaces& contacts); + OPCODE_API bool SetupClosestHit (RayCollider& collider, CollisionFace& closest_contact); + OPCODE_API bool SetupShadowFeeler (RayCollider& collider); + OPCODE_API bool SetupInOutTest (RayCollider& collider); + + OPCODE_API bool Picking( + CollisionFace& picked_face, + const Ray& world_ray, const Model& model, const Matrix4x4* world, + float min_dist, float max_dist, const Point& view_point, CullModeCallback callback, void* user_data); +#endif + +#endif //__OPC_PICKING_H__ diff --git a/libs/ode-0.16.1/OPCODE/OPC_PlanesAABBOverlap.h b/libs/ode-0.16.1/OPCODE/OPC_PlanesAABBOverlap.h new file mode 100644 index 0000000..5d7576e --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_PlanesAABBOverlap.h @@ -0,0 +1,50 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Planes-AABB overlap test. + * - original code by Ville Miettinen, from Umbra/dPVS (released on the GD-Algorithms mailing list) + * - almost used "as-is", I even left the comments (hence the frustum-related notes) + * + * \param center [in] box center + * \param extents [in] box extents + * \param out_clip_mask [out] bitmask for active planes + * \param in_clip_mask [in] bitmask for active planes + * \return TRUE if boxes overlap planes + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +inline_ BOOL PlanesCollider::PlanesAABBOverlap(const Point& center, const Point& extents, udword& out_clip_mask, udword in_clip_mask) +{ + // Stats + mNbVolumeBVTests++; + + const Plane* p = mPlanes; + + // Evaluate through all active frustum planes. We determine the relation + // between the AABB and a plane by using the concept of "near" and "far" + // vertices originally described by Zhang (and later by Möller). Our + // variant here uses 3 fabs ops, 6 muls, 7 adds and two floating point + // comparisons per plane. The routine early-exits if the AABB is found + // to be outside any of the planes. The loop also constructs a new output + // clip mask. Most FPUs have a native single-cycle fabsf() operation. + + udword Mask = 1; // current mask index (1,2,4,8,..) + udword TmpOutClipMask = 0; // initialize output clip mask into empty. + + while(Mask<=in_clip_mask) // keep looping while we have active planes left... + { + if(in_clip_mask & Mask) // if clip plane is active, process it.. + { + float NP = extents.x*fabsf(p->n.x) + extents.y*fabsf(p->n.y) + extents.z*fabsf(p->n.z); // ### fabsf could be precomputed + float MP = center.x*p->n.x + center.y*p->n.y + center.z*p->n.z + p->d; + + if(NP < MP) // near vertex behind the clip plane... + return FALSE; // .. so there is no intersection.. + if((-NP) < MP) // near and far vertices on different sides of plane.. + TmpOutClipMask |= Mask; // .. so update the clip mask... + } + Mask+=Mask; // mk = (1<Add(udword(prim_index)); + +//! Planes-triangle test +#define PLANES_PRIM(prim_index, flag) \ + /* Request vertices from the app */ \ + mIMesh->GetTriangle(mVP, prim_index, mVC); \ + /* Perform triangle-box overlap test */ \ + if(PlanesTriOverlap(clip_mask)) \ + { \ + SET_CONTACT(prim_index, flag) \ + } + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +PlanesCollider::PlanesCollider() : + mNbPlanes (0), + mPlanes (null) +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +PlanesCollider::~PlanesCollider() +{ + DELETEARRAY(mPlanes); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Validates current settings. You should call this method after all the settings and callbacks have been defined. + * \return null if everything is ok, else a string describing the problem + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +const char* PlanesCollider::ValidateSettings() +{ + if(TemporalCoherenceEnabled() && !FirstContactEnabled()) return "Temporal coherence only works with ""First contact"" mode!"; + + return VolumeCollider::ValidateSettings(); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Generic collision query for generic OPCODE models. After the call, access the results: + * - with GetContactStatus() + * - with GetNbTouchedPrimitives() + * - with GetTouchedPrimitives() + * + * \param cache [in/out] a planes cache + * \param planes [in] list of planes in world space + * \param nb_planes [in] number of planes + * \param model [in] Opcode model to collide with + * \param worldm [in] model's world matrix, or null + * \return true if success + * \warning SCALE NOT SUPPORTED. The matrices must contain rotation & translation parts only. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool PlanesCollider::Collide(PlanesCache& cache, const Plane* planes, udword nb_planes, const Model& model, const Matrix4x4* worldm) +{ + // Checkings + if(!Setup(&model)) return false; + + // Init collision query + if(InitQuery(cache, planes, nb_planes, worldm)) return true; + + udword PlaneMask = (1<(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform collision query + if(SkipPrimitiveTests()) _CollideNoPrimitiveTest(Tree->GetNodes(), PlaneMask); + else _Collide(Tree->GetNodes(), PlaneMask); + } + else + { + const AABBNoLeafTree* Tree = static_cast(model.GetTree()); + + // Perform collision query + if(SkipPrimitiveTests()) _CollideNoPrimitiveTest(Tree->GetNodes(), PlaneMask); + else _Collide(Tree->GetNodes(), PlaneMask); + } + } + else + { + if(model.IsQuantized()) + { + const AABBQuantizedTree* Tree = static_cast(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform collision query + if(SkipPrimitiveTests()) _CollideNoPrimitiveTest(Tree->GetNodes(), PlaneMask); + else _Collide(Tree->GetNodes(), PlaneMask); + } + else + { + const AABBCollisionTree* Tree = static_cast(model.GetTree()); + + // Perform collision query + if(SkipPrimitiveTests()) _CollideNoPrimitiveTest(Tree->GetNodes(), PlaneMask); + else _Collide(Tree->GetNodes(), PlaneMask); + } + } + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Initializes a collision query : + * - reset stats & contact status + * - compute planes in model space + * - check temporal coherence + * + * \param cache [in/out] a planes cache + * \param planes [in] list of planes + * \param nb_planes [in] number of planes + * \param worldm [in] model's world matrix, or null + * \return TRUE if we can return immediately + * \warning SCALE NOT SUPPORTED. The matrix must contain rotation & translation parts only. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +BOOL PlanesCollider::InitQuery(PlanesCache& cache, const Plane* planes, udword nb_planes, const Matrix4x4* worldm) +{ + // 1) Call the base method + VolumeCollider::InitQuery(); + + // 2) Compute planes in model space + if(nb_planes>mNbPlanes) + { + DELETEARRAY(mPlanes); + mPlanes = new Plane[nb_planes]; + } + mNbPlanes = nb_planes; + + if(worldm) + { + Matrix4x4 InvWorldM; + InvertPRMatrix(InvWorldM, *worldm); + +// for(udword i=0;iHasSingleNode()) + { + if(!SkipPrimitiveTests()) + { + // We simply perform the BV-Prim overlap test each time. We assume single triangle has index 0. + mTouchedPrimitives->Reset(); + + // Perform overlap test between the unique triangle and the planes (and set contact status if needed) + udword clip_mask = (1< check results from previous frame before performing the collision query + if(FirstContactEnabled()) + { + // We're only interested in the first contact found => test the unique previously touched face + if(mTouchedPrimitives->GetNbEntries()) + { + // Get index of previously touched face = the first entry in the array + udword PreviouslyTouchedFace = mTouchedPrimitives->GetEntry(0); + + // Then reset the array: + // - if the overlap test below is successful, the index we'll get added back anyway + // - if it isn't, then the array should be reset anyway for the normal query + mTouchedPrimitives->Reset(); + + // Perform overlap test between the cached triangle and the planes (and set contact status if needed) + udword clip_mask = (1< we'll have to perform a normal query + } + else mTouchedPrimitives->Reset(); + } + else + { + // Here we don't use temporal coherence => do a normal query + mTouchedPrimitives->Reset(); + } + + return FALSE; +} + +#define TEST_CLIP_MASK \ + /* If the box is completely included, so are its children. We don't need to do extra tests, we */ \ + /* can immediately output a list of visible children. Those ones won't need to be clipped. */ \ + if(!OutClipMask) \ + { \ + /* Set contact status */ \ + mFlags |= OPC_CONTACT; \ + _Dump(node); \ + return; \ + } + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for normal AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void PlanesCollider::_Collide(const AABBCollisionNode* node, udword clip_mask) +{ + // Test the box against the planes. If the box is completely culled, so are its children, hence we exit. + udword OutClipMask; + if(!PlanesAABBOverlap(node->mAABB.mCenter, node->mAABB.mExtents, OutClipMask, clip_mask)) return; + + TEST_CLIP_MASK + + // Else the box straddles one or several planes, so we need to recurse down the tree. + if(node->IsLeaf()) + { + PLANES_PRIM(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _Collide(node->GetPos(), OutClipMask); + + if(ContactFound()) return; + + _Collide(node->GetNeg(), OutClipMask); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for normal AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void PlanesCollider::_CollideNoPrimitiveTest(const AABBCollisionNode* node, udword clip_mask) +{ + // Test the box against the planes. If the box is completely culled, so are its children, hence we exit. + udword OutClipMask; + if(!PlanesAABBOverlap(node->mAABB.mCenter, node->mAABB.mExtents, OutClipMask, clip_mask)) return; + + TEST_CLIP_MASK + + // Else the box straddles one or several planes, so we need to recurse down the tree. + if(node->IsLeaf()) + { + SET_CONTACT(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _CollideNoPrimitiveTest(node->GetPos(), OutClipMask); + + if(ContactFound()) return; + + _CollideNoPrimitiveTest(node->GetNeg(), OutClipMask); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void PlanesCollider::_Collide(const AABBQuantizedNode* node, udword clip_mask) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Test the box against the planes. If the box is completely culled, so are its children, hence we exit. + udword OutClipMask; + if(!PlanesAABBOverlap(Center, Extents, OutClipMask, clip_mask)) return; + + TEST_CLIP_MASK + + // Else the box straddles one or several planes, so we need to recurse down the tree. + if(node->IsLeaf()) + { + PLANES_PRIM(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _Collide(node->GetPos(), OutClipMask); + + if(ContactFound()) return; + + _Collide(node->GetNeg(), OutClipMask); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void PlanesCollider::_CollideNoPrimitiveTest(const AABBQuantizedNode* node, udword clip_mask) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Test the box against the planes. If the box is completely culled, so are its children, hence we exit. + udword OutClipMask; + if(!PlanesAABBOverlap(Center, Extents, OutClipMask, clip_mask)) return; + + TEST_CLIP_MASK + + // Else the box straddles one or several planes, so we need to recurse down the tree. + if(node->IsLeaf()) + { + SET_CONTACT(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _CollideNoPrimitiveTest(node->GetPos(), OutClipMask); + + if(ContactFound()) return; + + _CollideNoPrimitiveTest(node->GetNeg(), OutClipMask); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for no-leaf AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void PlanesCollider::_Collide(const AABBNoLeafNode* node, udword clip_mask) +{ + // Test the box against the planes. If the box is completely culled, so are its children, hence we exit. + udword OutClipMask; + if(!PlanesAABBOverlap(node->mAABB.mCenter, node->mAABB.mExtents, OutClipMask, clip_mask)) return; + + TEST_CLIP_MASK + + // Else the box straddles one or several planes, so we need to recurse down the tree. + if(node->HasPosLeaf()) { PLANES_PRIM(node->GetPosPrimitive(), OPC_CONTACT) } + else _Collide(node->GetPos(), OutClipMask); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) { PLANES_PRIM(node->GetNegPrimitive(), OPC_CONTACT) } + else _Collide(node->GetNeg(), OutClipMask); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for no-leaf AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void PlanesCollider::_CollideNoPrimitiveTest(const AABBNoLeafNode* node, udword clip_mask) +{ + // Test the box against the planes. If the box is completely culled, so are its children, hence we exit. + udword OutClipMask; + if(!PlanesAABBOverlap(node->mAABB.mCenter, node->mAABB.mExtents, OutClipMask, clip_mask)) return; + + TEST_CLIP_MASK + + // Else the box straddles one or several planes, so we need to recurse down the tree. + if(node->HasPosLeaf()) { SET_CONTACT(node->GetPosPrimitive(), OPC_CONTACT) } + else _CollideNoPrimitiveTest(node->GetPos(), OutClipMask); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) { SET_CONTACT(node->GetNegPrimitive(), OPC_CONTACT) } + else _CollideNoPrimitiveTest(node->GetNeg(), OutClipMask); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized no-leaf AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void PlanesCollider::_Collide(const AABBQuantizedNoLeafNode* node, udword clip_mask) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Test the box against the planes. If the box is completely culled, so are its children, hence we exit. + udword OutClipMask; + if(!PlanesAABBOverlap(Center, Extents, OutClipMask, clip_mask)) return; + + TEST_CLIP_MASK + + // Else the box straddles one or several planes, so we need to recurse down the tree. + if(node->HasPosLeaf()) { PLANES_PRIM(node->GetPosPrimitive(), OPC_CONTACT) } + else _Collide(node->GetPos(), OutClipMask); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) { PLANES_PRIM(node->GetNegPrimitive(), OPC_CONTACT) } + else _Collide(node->GetNeg(), OutClipMask); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized no-leaf AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void PlanesCollider::_CollideNoPrimitiveTest(const AABBQuantizedNoLeafNode* node, udword clip_mask) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Test the box against the planes. If the box is completely culled, so are its children, hence we exit. + udword OutClipMask; + if(!PlanesAABBOverlap(Center, Extents, OutClipMask, clip_mask)) return; + + TEST_CLIP_MASK + + // Else the box straddles one or several planes, so we need to recurse down the tree. + if(node->HasPosLeaf()) { SET_CONTACT(node->GetPosPrimitive(), OPC_CONTACT) } + else _CollideNoPrimitiveTest(node->GetPos(), OutClipMask); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) { SET_CONTACT(node->GetNegPrimitive(), OPC_CONTACT) } + else _CollideNoPrimitiveTest(node->GetNeg(), OutClipMask); +} + + + + + + + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +HybridPlanesCollider::HybridPlanesCollider() +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +HybridPlanesCollider::~HybridPlanesCollider() +{ +} + +bool HybridPlanesCollider::Collide(PlanesCache& cache, const Plane* planes, udword nb_planes, const HybridModel& model, const Matrix4x4* worldm) +{ + // We don't want primitive tests here! + mFlags |= OPC_NO_PRIMITIVE_TESTS; + + // Checkings + if(!Setup(&model)) return false; + + // Init collision query + if(InitQuery(cache, planes, nb_planes, worldm)) return true; + + // Special case for 1-leaf trees + if(mCurrentModel && mCurrentModel->HasSingleNode()) + { + // Here we're supposed to perform a normal query, except our tree has a single node, i.e. just a few triangles + udword Nb = mIMesh->GetNbTriangles(); + + // Loop through all triangles + udword clip_mask = (1<(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform collision query - we don't want primitive tests here! + _CollideNoPrimitiveTest(Tree->GetNodes(), PlaneMask); + } + else + { + const AABBNoLeafTree* Tree = static_cast(model.GetTree()); + + // Perform collision query - we don't want primitive tests here! + _CollideNoPrimitiveTest(Tree->GetNodes(), PlaneMask); + } + } + else + { + if(model.IsQuantized()) + { + const AABBQuantizedTree* Tree = static_cast(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform collision query - we don't want primitive tests here! + _CollideNoPrimitiveTest(Tree->GetNodes(), PlaneMask); + } + else + { + const AABBCollisionTree* Tree = static_cast(model.GetTree()); + + // Perform collision query - we don't want primitive tests here! + _CollideNoPrimitiveTest(Tree->GetNodes(), PlaneMask); + } + } + + // We only have a list of boxes so far + if(GetContactStatus()) + { + // Reset contact status, since it currently only reflects collisions with leaf boxes + Collider::InitQuery(); + + // Change dest container so that we can use built-in overlap tests and get collided primitives + cache.TouchedPrimitives.Reset(); + mTouchedPrimitives = &cache.TouchedPrimitives; + + // Read touched leaf boxes + udword Nb = mTouchedBoxes.GetNbEntries(); + const udword* Touched = mTouchedBoxes.GetEntries(); + + const LeafTriangles* LT = model.GetLeafTriangles(); + const udword* Indices = model.GetIndices(); + + // Loop through touched leaves + udword clip_mask = (1<Distance(*mVP.Vertex[0]); + float d1 = p->Distance(*mVP.Vertex[1]); + float d2 = p->Distance(*mVP.Vertex[2]); + if(d0>0.0f && d1>0.0f && d2>0.0f) return FALSE; +// if(!(IR(d0)&SIGN_BITMASK) && !(IR(d1)&SIGN_BITMASK) && !(IR(d2)&SIGN_BITMASK)) return FALSE; + } + Mask+=Mask; + p++; + } +/* + for(udword i=0;i<6;i++) + { + float d0 = p[i].Distance(mLeafVerts[0]); + float d1 = p[i].Distance(mLeafVerts[1]); + float d2 = p[i].Distance(mLeafVerts[2]); + if(d0>0.0f && d1>0.0f && d2>0.0f) return false; + } +*/ + return TRUE; +} diff --git a/libs/ode-0.16.1/OPCODE/OPC_RayAABBOverlap.h b/libs/ode-0.16.1/OPCODE/OPC_RayAABBOverlap.h new file mode 100644 index 0000000..a8162bf --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_RayAABBOverlap.h @@ -0,0 +1,63 @@ +// Opcode 1.1: ray-AABB overlap tests based on Woo's code +// Opcode 1.2: ray-AABB overlap tests based on the separating axis theorem +// +// The point of intersection is not computed anymore. The distance to impact is not needed anymore +// since we now have two different queries for segments or rays. + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes a segment-AABB overlap test using the separating axis theorem. Segment is cached within the class. + * \param center [in] AABB center + * \param extents [in] AABB extents + * \return true on overlap + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +inline_ BOOL RayCollider::SegmentAABBOverlap(const Point& center, const Point& extents) +{ + // Stats + mNbRayBVTests++; + + float Dx = mData2.x - center.x; if(fabsf(Dx) > extents.x + mFDir.x) return FALSE; + float Dy = mData2.y - center.y; if(fabsf(Dy) > extents.y + mFDir.y) return FALSE; + float Dz = mData2.z - center.z; if(fabsf(Dz) > extents.z + mFDir.z) return FALSE; + + float f; + f = mData.y * Dz - mData.z * Dy; if(fabsf(f) > extents.y*mFDir.z + extents.z*mFDir.y) return FALSE; + f = mData.z * Dx - mData.x * Dz; if(fabsf(f) > extents.x*mFDir.z + extents.z*mFDir.x) return FALSE; + f = mData.x * Dy - mData.y * Dx; if(fabsf(f) > extents.x*mFDir.y + extents.y*mFDir.x) return FALSE; + + return TRUE; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes a ray-AABB overlap test using the separating axis theorem. Ray is cached within the class. + * \param center [in] AABB center + * \param extents [in] AABB extents + * \return true on overlap + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +inline_ BOOL RayCollider::RayAABBOverlap(const Point& center, const Point& extents) +{ + // Stats + mNbRayBVTests++; + +// float Dx = mOrigin.x - center.x; if(fabsf(Dx) > extents.x && Dx*mDir.x>=0.0f) return FALSE; +// float Dy = mOrigin.y - center.y; if(fabsf(Dy) > extents.y && Dy*mDir.y>=0.0f) return FALSE; +// float Dz = mOrigin.z - center.z; if(fabsf(Dz) > extents.z && Dz*mDir.z>=0.0f) return FALSE; + + float Dx = mOrigin.x - center.x; if(GREATER(Dx, extents.x) && Dx*mDir.x>=0.0f) return FALSE; + float Dy = mOrigin.y - center.y; if(GREATER(Dy, extents.y) && Dy*mDir.y>=0.0f) return FALSE; + float Dz = mOrigin.z - center.z; if(GREATER(Dz, extents.z) && Dz*mDir.z>=0.0f) return FALSE; + +// float Dx = mOrigin.x - center.x; if(GREATER(Dx, extents.x) && ((SIR(Dx)-1)^SIR(mDir.x))>=0.0f) return FALSE; +// float Dy = mOrigin.y - center.y; if(GREATER(Dy, extents.y) && ((SIR(Dy)-1)^SIR(mDir.y))>=0.0f) return FALSE; +// float Dz = mOrigin.z - center.z; if(GREATER(Dz, extents.z) && ((SIR(Dz)-1)^SIR(mDir.z))>=0.0f) return FALSE; + + float f; + f = mDir.y * Dz - mDir.z * Dy; if(fabsf(f) > extents.y*mFDir.z + extents.z*mFDir.y) return FALSE; + f = mDir.z * Dx - mDir.x * Dz; if(fabsf(f) > extents.x*mFDir.z + extents.z*mFDir.x) return FALSE; + f = mDir.x * Dy - mDir.y * Dx; if(fabsf(f) > extents.x*mFDir.y + extents.y*mFDir.x) return FALSE; + + return TRUE; +} diff --git a/libs/ode-0.16.1/OPCODE/OPC_RayCollider.cpp b/libs/ode-0.16.1/OPCODE/OPC_RayCollider.cpp new file mode 100644 index 0000000..6a81857 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_RayCollider.cpp @@ -0,0 +1,764 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for a ray collider. + * \file OPC_RayCollider.cpp + * \author Pierre Terdiman + * \date June, 2, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains a ray-vs-tree collider. + * This class performs a stabbing query on an AABB tree, i.e. does a ray-mesh collision. + * + * HIGHER DISTANCE BOUND: + * + * If P0 and P1 are two 3D points, let's define: + * - d = distance between P0 and P1 + * - Origin = P0 + * - Direction = (P1 - P0) / d = normalized direction vector + * - A parameter t such as a point P on the line (P0,P1) is P = Origin + t * Direction + * - t = 0 --> P = P0 + * - t = d --> P = P1 + * + * Then we can define a general "ray" as: + * + * struct Ray + * { + * Point Origin; + * Point Direction; + * }; + * + * But it actually maps three different things: + * - a segment, when 0 <= t <= d + * - a half-line, when 0 <= t < +infinity, or -infinity < t <= d + * - a line, when -infinity < t < +infinity + * + * In Opcode, we support segment queries, which yield half-line queries by setting d = +infinity. + * We don't support line-queries. If you need them, shift the origin along the ray by an appropriate margin. + * + * In short, the lower bound is always 0, and you can setup the higher bound "d" with RayCollider::SetMaxDist(). + * + * Query |segment |half-line |line + * --------|-------------------|---------------|---------------- + * Usages |-shadow feelers |-raytracing |- + * |-sweep tests |-in/out tests | + * + * FIRST CONTACT: + * + * - You can setup "first contact" mode or "all contacts" mode with RayCollider::SetFirstContact(). + * - In "first contact" mode we return as soon as the ray hits one face. If can be useful e.g. for shadow feelers, where + * you want to know whether the path to the light is free or not (a boolean answer is enough). + * - In "all contacts" mode we return all faces hit by the ray. + * + * TEMPORAL COHERENCE: + * + * - You can enable or disable temporal coherence with RayCollider::SetTemporalCoherence(). + * - It currently only works in "first contact" mode. + * - If temporal coherence is enabled, the previously hit triangle is cached during the first query. Then, next queries + * start by colliding the ray against the cached triangle. If they still collide, we return immediately. + * + * CLOSEST HIT: + * + * - You can enable or disable "closest hit" with RayCollider::SetClosestHit(). + * - It currently only works in "all contacts" mode. + * - If closest hit is enabled, faces are sorted by distance on-the-fly and the closest one only is reported. + * + * BACKFACE CULLING: + * + * - You can enable or disable backface culling with RayCollider::SetCulling(). + * - If culling is enabled, ray will not hit back faces (only front faces). + * + * + * + * \class RayCollider + * \author Pierre Terdiman + * \version 1.3 + * \date June, 2, 2001 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * This class describes a face hit by a ray or segment. + * This is a particular class dedicated to stabbing queries. + * + * \class CollisionFace + * \author Pierre Terdiman + * \version 1.3 + * \date March, 20, 2001 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * This class is a dedicated collection of CollisionFace. + * + * \class CollisionFaces + * \author Pierre Terdiman + * \version 1.3 + * \date March, 20, 2001 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace Opcode; + +#include "OPC_RayAABBOverlap.h" +#include "OPC_RayTriOverlap.h" + +#define SET_CONTACT(prim_index, flag) \ + mNbIntersections++; \ + /* Set contact status */ \ + mFlags |= flag; \ + /* In any case the contact has been found and recorded in mStabbedFace */ \ + mStabbedFace.mFaceID = prim_index; + +#ifdef OPC_RAYHIT_CALLBACK + + #define HANDLE_CONTACT(prim_index, flag) \ + SET_CONTACT(prim_index, flag) \ + \ + if(mHitCallback) (mHitCallback)(mStabbedFace, mUserData); + + #define UPDATE_CACHE \ + if(cache && GetContactStatus()) \ + { \ + *cache = mStabbedFace.mFaceID; \ + } +#else + + #define HANDLE_CONTACT(prim_index, flag) \ + SET_CONTACT(prim_index, flag) \ + \ + /* Now we can also record it in mStabbedFaces if available */ \ + if(mStabbedFaces) \ + { \ + /* If we want all faces or if that's the first one we hit */ \ + if(!mClosestHit || !mStabbedFaces->GetNbFaces()) \ + { \ + mStabbedFaces->AddFace(mStabbedFace); \ + } \ + else \ + { \ + /* We only keep closest hit */ \ + CollisionFace* Current = const_cast(mStabbedFaces->GetFaces()); \ + if(Current && mStabbedFace.mDistancemDistance) \ + { \ + *Current = mStabbedFace; \ + } \ + } \ + } + + #define UPDATE_CACHE \ + if(cache && GetContactStatus() && mStabbedFaces) \ + { \ + const CollisionFace* Current = mStabbedFaces->GetFaces(); \ + if(Current) *cache = Current->mFaceID; \ + else *cache = INVALID_ID; \ + } +#endif + +#define SEGMENT_PRIM(prim_index, flag) \ + /* Request vertices from the app */ \ + VertexPointers VP; ConversionArea VC; mIMesh->GetTriangle(VP, prim_index, VC); \ + \ + /* Perform ray-tri overlap test and return */ \ + if(RayTriOverlap(*VP.Vertex[0], *VP.Vertex[1], *VP.Vertex[2])) \ + { \ + /* Intersection point is valid if dist < segment's length */ \ + /* We know dist>0 so we can use integers */ \ + if(IR(mStabbedFace.mDistance)GetTriangle(VP, prim_index, VC); \ + \ + /* Perform ray-tri overlap test and return */ \ + if(RayTriOverlap(*VP.Vertex[0], *VP.Vertex[1], *VP.Vertex[2])) \ + { \ + HANDLE_CONTACT(prim_index, flag) \ + } + + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +RayCollider::RayCollider() : +#ifdef OPC_RAYHIT_CALLBACK + mHitCallback (null), + mUserData (0), +#else + mStabbedFaces (null), + mClosestHit (false), +#endif + mNbRayBVTests (0), + mNbRayPrimTests (0), + mNbIntersections (0), + mMaxDist (MAX_FLOAT), + mCulling (true) + +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +RayCollider::~RayCollider() +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Validates current settings. You should call this method after all the settings and callbacks have been defined. + * \return null if everything is ok, else a string describing the problem + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +const char* RayCollider::ValidateSettings() +{ + if(mMaxDist<0.0f) return "Higher distance bound must be positive!"; + if(TemporalCoherenceEnabled() && !FirstContactEnabled()) return "Temporal coherence only works with ""First contact"" mode!"; +#ifndef OPC_RAYHIT_CALLBACK + if(mClosestHit && FirstContactEnabled()) return "Closest hit doesn't work with ""First contact"" mode!"; + if(TemporalCoherenceEnabled() && mClosestHit) return "Temporal coherence can't guarantee to report closest hit!"; +#endif + if(SkipPrimitiveTests()) return "SkipPrimitiveTests not possible for RayCollider ! (not implemented)"; + return null; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Generic stabbing query for generic OPCODE models. After the call, access the results: + * - with GetContactStatus() + * - in the user-provided destination array + * + * \param world_ray [in] stabbing ray in world space + * \param model [in] Opcode model to collide with + * \param world [in] model's world matrix, or null + * \param cache [in] a possibly cached face index, or null + * \return true if success + * \warning SCALE NOT SUPPORTED. The matrices must contain rotation & translation parts only. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool RayCollider::Collide(const Ray& world_ray, const Model& model, const Matrix4x4* world, udword* cache) +{ + // Checkings + if(!Setup(&model)) return false; + + // Init collision query + if(InitQuery(world_ray, world, cache)) return true; + + if(!model.HasLeafNodes()) + { + if(model.IsQuantized()) + { + const AABBQuantizedNoLeafTree* Tree = static_cast(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform stabbing query + if(IR(mMaxDist)!=IEEE_MAX_FLOAT) _SegmentStab(Tree->GetNodes()); + else _RayStab(Tree->GetNodes()); + } + else + { + const AABBNoLeafTree* Tree = static_cast(model.GetTree()); + + // Perform stabbing query + if(IR(mMaxDist)!=IEEE_MAX_FLOAT) _SegmentStab(Tree->GetNodes()); + else _RayStab(Tree->GetNodes()); + } + } + else + { + if(model.IsQuantized()) + { + const AABBQuantizedTree* Tree = static_cast(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform stabbing query + if(IR(mMaxDist)!=IEEE_MAX_FLOAT) _SegmentStab(Tree->GetNodes()); + else _RayStab(Tree->GetNodes()); + } + else + { + const AABBCollisionTree* Tree = static_cast(model.GetTree()); + + // Perform stabbing query + if(IR(mMaxDist)!=IEEE_MAX_FLOAT) _SegmentStab(Tree->GetNodes()); + else _RayStab(Tree->GetNodes()); + } + } + + // Update cache if needed + UPDATE_CACHE; + return true; +} + + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Initializes a stabbing query : + * - reset stats & contact status + * - compute ray in local space + * - check temporal coherence + * + * \param world_ray [in] stabbing ray in world space + * \param world [in] object's world matrix, or null + * \param face_id [in] index of previously stabbed triangle + * \return TRUE if we can return immediately + * \warning SCALE NOT SUPPORTED. The matrix must contain rotation & translation parts only. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +BOOL RayCollider::InitQuery(const Ray& world_ray, const Matrix4x4* world, udword* face_id) +{ + // Reset stats & contact status + Collider::InitQuery(); + mNbRayBVTests = 0; + mNbRayPrimTests = 0; + mNbIntersections = 0; +#ifndef OPC_RAYHIT_CALLBACK + if(mStabbedFaces) mStabbedFaces->Reset(); +#endif + + // Compute ray in local space + // The (Origin/Dir) form is needed for the ray-triangle test anyway (even for segment tests) + if(world) + { + Matrix3x3 InvWorld = *world; + mDir = InvWorld * world_ray.mDir; + + Matrix4x4 World; + InvertPRMatrix(World, *world); + mOrigin = world_ray.mOrig * World; + } + else + { + mDir = world_ray.mDir; + mOrigin = world_ray.mOrig; + } + + // 4) Special case: 1-triangle meshes [Opcode 1.3] + if(mCurrentModel && mCurrentModel->HasSingleNode()) + { + // We simply perform the BV-Prim overlap test each time. We assume single triangle has index 0. + if(!SkipPrimitiveTests()) + { + // Perform overlap test between the unique triangle and the ray (and set contact status if needed) + SEGMENT_PRIM(udword(0), OPC_CONTACT) + + // Return immediately regardless of status + return TRUE; + } + } + + // Check temporal coherence : + + // Test previously colliding primitives first + if(TemporalCoherenceEnabled() && FirstContactEnabled() && face_id && *face_id!=INVALID_ID) + { +#ifdef OLD_CODE +#ifndef OPC_RAYHIT_CALLBACK + if(!mClosestHit) +#endif + { + // Request vertices from the app + VertexPointers VP; + ConversionArea VC; + mIMesh->GetTriangle(VP, *face_id, VC); + // Perform ray-cached tri overlap test + if(RayTriOverlap(*VP.Vertex[0], *VP.Vertex[1], *VP.Vertex[2])) + { + // Intersection point is valid if: + // - distance is positive (else it can just be a face behind the orig point) + // - distance is smaller than a given max distance (useful for shadow feelers) +// if(mStabbedFace.mDistance>0.0f && mStabbedFace.mDistanceAddFace(mStabbedFace); +#endif + return TRUE; + } + } + } +#else + // New code + // We handle both Segment/ray queries with the same segment code, and a possible infinite limit + SEGMENT_PRIM(*face_id, OPC_TEMPORAL_CONTACT) + + // Return immediately if possible + if(GetContactStatus()) return TRUE; +#endif + } + + // Precompute data (moved after temporal coherence since only needed for ray-AABB) + if(IR(mMaxDist)!=IEEE_MAX_FLOAT) + { + // For Segment-AABB overlap + mData = 0.5f * mDir * mMaxDist; + mData2 = mOrigin + mData; + + // Precompute mFDir; + mFDir.x = fabsf(mData.x); + mFDir.y = fabsf(mData.y); + mFDir.z = fabsf(mData.z); + } + else + { + // For Ray-AABB overlap +// udword x = SIR(mDir.x)-1; +// udword y = SIR(mDir.y)-1; +// udword z = SIR(mDir.z)-1; +// mData.x = FR(x); +// mData.y = FR(y); +// mData.z = FR(z); + + // Precompute mFDir; + mFDir.x = fabsf(mDir.x); + mFDir.y = fabsf(mDir.y); + mFDir.z = fabsf(mDir.z); + } + + return FALSE; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Stabbing query for vanilla AABB trees. + * \param world_ray [in] stabbing ray in world space + * \param tree [in] AABB tree + * \param box_indices [out] indices of stabbed boxes + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool RayCollider::Collide(const Ray& world_ray, const AABBTree* tree, Container& box_indices) +{ + // ### bad design here + + // This is typically called for a scene tree, full of -AABBs-, not full of triangles. + // So we don't really have "primitives" to deal with. Hence it doesn't work with + // "FirstContact" + "TemporalCoherence". + ASSERT( !(FirstContactEnabled() && TemporalCoherenceEnabled()) ); + + // Checkings + if(!tree) return false; + + // Init collision query + // Basically this is only called to initialize precomputed data + if(InitQuery(world_ray)) return true; + + // Perform stabbing query + if(IR(mMaxDist)!=IEEE_MAX_FLOAT) _SegmentStab(tree, box_indices); + else _RayStab(tree, box_indices); + + return true; +} + + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive stabbing query for normal AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void RayCollider::_SegmentStab(const AABBCollisionNode* node) +{ + // Perform Segment-AABB overlap test + if(!SegmentAABBOverlap(node->mAABB.mCenter, node->mAABB.mExtents)) return; + + if(node->IsLeaf()) + { + SEGMENT_PRIM(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _SegmentStab(node->GetPos()); + + if(ContactFound()) return; + + _SegmentStab(node->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive stabbing query for quantized AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void RayCollider::_SegmentStab(const AABBQuantizedNode* node) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Perform Segment-AABB overlap test + if(!SegmentAABBOverlap(Center, Extents)) return; + + if(node->IsLeaf()) + { + SEGMENT_PRIM(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _SegmentStab(node->GetPos()); + + if(ContactFound()) return; + + _SegmentStab(node->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive stabbing query for no-leaf AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void RayCollider::_SegmentStab(const AABBNoLeafNode* node) +{ + // Perform Segment-AABB overlap test + if(!SegmentAABBOverlap(node->mAABB.mCenter, node->mAABB.mExtents)) return; + + if(node->HasPosLeaf()) + { + SEGMENT_PRIM(node->GetPosPrimitive(), OPC_CONTACT) + } + else _SegmentStab(node->GetPos()); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) + { + SEGMENT_PRIM(node->GetNegPrimitive(), OPC_CONTACT) + } + else _SegmentStab(node->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive stabbing query for quantized no-leaf AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void RayCollider::_SegmentStab(const AABBQuantizedNoLeafNode* node) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Perform Segment-AABB overlap test + if(!SegmentAABBOverlap(Center, Extents)) return; + + if(node->HasPosLeaf()) + { + SEGMENT_PRIM(node->GetPosPrimitive(), OPC_CONTACT) + } + else _SegmentStab(node->GetPos()); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) + { + SEGMENT_PRIM(node->GetNegPrimitive(), OPC_CONTACT) + } + else _SegmentStab(node->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive stabbing query for vanilla AABB trees. + * \param node [in] current collision node + * \param box_indices [out] indices of stabbed boxes + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void RayCollider::_SegmentStab(const AABBTreeNode* node, Container& box_indices) +{ + // Test the box against the segment + Point Center, Extents; + node->GetAABB()->GetCenter(Center); + node->GetAABB()->GetExtents(Extents); + if(!SegmentAABBOverlap(Center, Extents)) return; + + if(node->IsLeaf()) + { + box_indices.Add(node->GetPrimitives(), node->GetNbPrimitives()); + } + else + { + _SegmentStab(node->GetPos(), box_indices); + _SegmentStab(node->GetNeg(), box_indices); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive stabbing query for normal AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void RayCollider::_RayStab(const AABBCollisionNode* node) +{ + // Perform Ray-AABB overlap test + if(!RayAABBOverlap(node->mAABB.mCenter, node->mAABB.mExtents)) return; + + if(node->IsLeaf()) + { + RAY_PRIM(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _RayStab(node->GetPos()); + + if(ContactFound()) return; + + _RayStab(node->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive stabbing query for quantized AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void RayCollider::_RayStab(const AABBQuantizedNode* node) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Perform Ray-AABB overlap test + if(!RayAABBOverlap(Center, Extents)) return; + + if(node->IsLeaf()) + { + RAY_PRIM(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _RayStab(node->GetPos()); + + if(ContactFound()) return; + + _RayStab(node->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive stabbing query for no-leaf AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void RayCollider::_RayStab(const AABBNoLeafNode* node) +{ + // Perform Ray-AABB overlap test + if(!RayAABBOverlap(node->mAABB.mCenter, node->mAABB.mExtents)) return; + + if(node->HasPosLeaf()) + { + RAY_PRIM(node->GetPosPrimitive(), OPC_CONTACT) + } + else _RayStab(node->GetPos()); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) + { + RAY_PRIM(node->GetNegPrimitive(), OPC_CONTACT) + } + else _RayStab(node->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive stabbing query for quantized no-leaf AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void RayCollider::_RayStab(const AABBQuantizedNoLeafNode* node) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Perform Ray-AABB overlap test + if(!RayAABBOverlap(Center, Extents)) return; + + if(node->HasPosLeaf()) + { + RAY_PRIM(node->GetPosPrimitive(), OPC_CONTACT) + } + else _RayStab(node->GetPos()); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) + { + RAY_PRIM(node->GetNegPrimitive(), OPC_CONTACT) + } + else _RayStab(node->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive stabbing query for vanilla AABB trees. + * \param node [in] current collision node + * \param box_indices [out] indices of stabbed boxes + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void RayCollider::_RayStab(const AABBTreeNode* node, Container& box_indices) +{ + // Test the box against the ray + Point Center, Extents; + node->GetAABB()->GetCenter(Center); + node->GetAABB()->GetExtents(Extents); + if(!RayAABBOverlap(Center, Extents)) return; + + if(node->IsLeaf()) + { + mFlags |= OPC_CONTACT; + box_indices.Add(node->GetPrimitives(), node->GetNbPrimitives()); + } + else + { + _RayStab(node->GetPos(), box_indices); + _RayStab(node->GetNeg(), box_indices); + } +} diff --git a/libs/ode-0.16.1/OPCODE/OPC_RayCollider.h b/libs/ode-0.16.1/OPCODE/OPC_RayCollider.h new file mode 100644 index 0000000..4a8ab7e --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_RayCollider.h @@ -0,0 +1,224 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for a ray collider. + * \file OPC_RayCollider.h + * \author Pierre Terdiman + * \date June, 2, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __OPC_RAYCOLLIDER_H__ +#define __OPC_RAYCOLLIDER_H__ + + class OPCODE_API CollisionFace + { + public: + //! Constructor + inline_ CollisionFace() {} + //! Destructor + inline_ ~CollisionFace() {} + + udword mFaceID; //!< Index of touched face + float mDistance; //!< Distance from collider to hitpoint + float mU, mV; //!< Impact barycentric coordinates + }; + + class OPCODE_API CollisionFaces : public Container + { + public: + //! Constructor + CollisionFaces() {} + //! Destructor + ~CollisionFaces() {} + + inline_ udword GetNbFaces() const { return GetNbEntries()>>2; } + inline_ const CollisionFace* GetFaces() const { return (const CollisionFace*)GetEntries(); } + + inline_ void Reset() { Container::Reset(); } + + inline_ void AddFace(const CollisionFace& face) { Add(face.mFaceID).Add(face.mDistance).Add(face.mU).Add(face.mV); } + }; + +#ifdef OPC_RAYHIT_CALLBACK + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * User-callback, called by OPCODE to record a hit. + * \param hit [in] current hit + * \param user_data [in] user-defined data from SetCallback() + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + typedef void (*HitCallback) (const CollisionFace& hit, void* user_data); +#endif + + class OPCODE_API RayCollider : public Collider + { + public: + // Constructor / Destructor + RayCollider(); + virtual ~RayCollider(); + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Generic stabbing query for generic OPCODE models. After the call, access the results: + * - with GetContactStatus() + * - in the user-provided destination array + * + * \param world_ray [in] stabbing ray in world space + * \param model [in] Opcode model to collide with + * \param world [in] model's world matrix, or null + * \param cache [in] a possibly cached face index, or null + * \return true if success + * \warning SCALE NOT SUPPORTED. The matrices must contain rotation & translation parts only. + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + bool Collide(const Ray& world_ray, const Model& model, const Matrix4x4* world=null, udword* cache=null); + // + bool Collide(const Ray& world_ray, const AABBTree* tree, Container& box_indices); + // Settings + +#ifndef OPC_RAYHIT_CALLBACK + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Settings: enable or disable "closest hit" mode. + * \param flag [in] true to report closest hit only + * \see SetCulling(bool flag) + * \see SetMaxDist(float max_dist) + * \see SetDestination(StabbedFaces* sf) + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void SetClosestHit(bool flag) { mClosestHit = flag; } +#endif + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Settings: enable or disable backface culling. + * \param flag [in] true to enable backface culling + * \see SetClosestHit(bool flag) + * \see SetMaxDist(float max_dist) + * \see SetDestination(StabbedFaces* sf) + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void SetCulling(bool flag) { mCulling = flag; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Settings: sets the higher distance bound. + * \param max_dist [in] higher distance bound. Default = maximal value, for ray queries (else segment) + * \see SetClosestHit(bool flag) + * \see SetCulling(bool flag) + * \see SetDestination(StabbedFaces* sf) + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void SetMaxDist(float max_dist=MAX_FLOAT) { mMaxDist = max_dist; } + +#ifdef OPC_RAYHIT_CALLBACK + inline_ void SetHitCallback(HitCallback cb) { mHitCallback = cb; } + inline_ void SetUserData(void* user_data) { mUserData = user_data; } +#else + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Settings: sets the destination array for stabbed faces. + * \param cf [in] destination array, filled during queries + * \see SetClosestHit(bool flag) + * \see SetCulling(bool flag) + * \see SetMaxDist(float max_dist) + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void SetDestination(CollisionFaces* cf) { mStabbedFaces = cf; } +#endif + // Stats + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Stats: gets the number of Ray-BV overlap tests after a collision query. + * \see GetNbRayPrimTests() + * \see GetNbIntersections() + * \return the number of Ray-BV tests performed during last query + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ udword GetNbRayBVTests() const { return mNbRayBVTests; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Stats: gets the number of Ray-Triangle overlap tests after a collision query. + * \see GetNbRayBVTests() + * \see GetNbIntersections() + * \return the number of Ray-Triangle tests performed during last query + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ udword GetNbRayPrimTests() const { return mNbRayPrimTests; } + + // In-out test + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Stats: gets the number of intersection found after a collision query. Can be used for in/out tests. + * \see GetNbRayBVTests() + * \see GetNbRayPrimTests() + * \return the number of valid intersections during last query + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ udword GetNbIntersections() const { return mNbIntersections; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Validates current settings. You should call this method after all the settings and callbacks have been defined for a collider. + * \return null if everything is ok, else a string describing the problem + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + override(Collider) const char* ValidateSettings(); + + protected: + // Ray in local space + Point mOrigin; //!< Ray origin + Point mDir; //!< Ray direction (normalized) + Point mFDir; //!< fabsf(mDir) + Point mData, mData2; + // Stabbed faces + CollisionFace mStabbedFace; //!< Current stabbed face +#ifdef OPC_RAYHIT_CALLBACK + HitCallback mHitCallback; //!< Callback used to record a hit + void* mUserData; //!< User-defined data +#else + CollisionFaces* mStabbedFaces; //!< List of stabbed faces + bool mClosestHit; //!< Report closest hit only +#endif + // Stats + udword mNbRayBVTests; //!< Number of Ray-BV tests + udword mNbRayPrimTests; //!< Number of Ray-Primitive tests + // In-out test + udword mNbIntersections; //!< Number of valid intersections + // Dequantization coeffs + Point mCenterCoeff; + Point mExtentsCoeff; + // Settings + float mMaxDist; //!< Valid segment on the ray + + bool mCulling; //!< Stab culled faces or not + // Internal methods + void _SegmentStab(const AABBCollisionNode* node); + void _SegmentStab(const AABBNoLeafNode* node); + void _SegmentStab(const AABBQuantizedNode* node); + void _SegmentStab(const AABBQuantizedNoLeafNode* node); + void _SegmentStab(const AABBTreeNode* node, Container& box_indices); + void _RayStab(const AABBCollisionNode* node); + void _RayStab(const AABBNoLeafNode* node); + void _RayStab(const AABBQuantizedNode* node); + void _RayStab(const AABBQuantizedNoLeafNode* node); + void _RayStab(const AABBTreeNode* node, Container& box_indices); + // Overlap tests + inline_ BOOL RayAABBOverlap(const Point& center, const Point& extents); + inline_ BOOL SegmentAABBOverlap(const Point& center, const Point& extents); + inline_ BOOL RayTriOverlap(const Point& vert0, const Point& vert1, const Point& vert2); + // Init methods + BOOL InitQuery(const Ray& world_ray, const Matrix4x4* world=null, udword* face_id=null); + }; + +#endif // __OPC_RAYCOLLIDER_H__ diff --git a/libs/ode-0.16.1/OPCODE/OPC_RayTriOverlap.h b/libs/ode-0.16.1/OPCODE/OPC_RayTriOverlap.h new file mode 100644 index 0000000..04110a1 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_RayTriOverlap.h @@ -0,0 +1,89 @@ +#define LOCAL_EPSILON 0.000001f + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes a ray-triangle intersection test. + * Original code from Tomas Möller's "Fast Minimum Storage Ray-Triangle Intersection". + * It's been optimized a bit with integer code, and modified to return a non-intersection if distance from + * ray origin to triangle is negative. + * + * \param vert0 [in] triangle vertex + * \param vert1 [in] triangle vertex + * \param vert2 [in] triangle vertex + * \return true on overlap. mStabbedFace is filled with relevant info. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +inline_ BOOL RayCollider::RayTriOverlap(const Point& vert0, const Point& vert1, const Point& vert2) +{ + // Stats + mNbRayPrimTests++; + + // Find vectors for two edges sharing vert0 + Point edge1 = vert1 - vert0; + Point edge2 = vert2 - vert0; + + // Begin calculating determinant - also used to calculate U parameter + Point pvec = mDir^edge2; + + // If determinant is near zero, ray lies in plane of triangle + float det = edge1|pvec; + + if(mCulling) + { + if(det <= LOCAL_EPSILON * FCMin2(edge1.SquareMagnitude(), edge2.SquareMagnitude())) return FALSE; + // From here, det is > 0. So we can use integer cmp. + + // Calculate distance from vert0 to ray origin + Point tvec = mOrigin - vert0; + + // Calculate U parameter and test bounds + mStabbedFace.mU = tvec|pvec; +// if(IR(u)&0x80000000 || u>det) return FALSE; + if(IS_NEGATIVE_FLOAT(mStabbedFace.mU) || IR(mStabbedFace.mU)>IR(det)) return FALSE; + + // Prepare to test V parameter + Point qvec = tvec^edge1; + + // Calculate V parameter and test bounds + mStabbedFace.mV = mDir|qvec; + if(IS_NEGATIVE_FLOAT(mStabbedFace.mV) || mStabbedFace.mU+mStabbedFace.mV>det) return FALSE; + + // Calculate t, scale parameters, ray intersects triangle + mStabbedFace.mDistance = edge2|qvec; + // Det > 0 so we can early exit here + // Intersection point is valid if distance is positive (else it can just be a face behind the orig point) + if(IS_NEGATIVE_FLOAT(mStabbedFace.mDistance)) return FALSE; + // Else go on + float OneOverDet = 1.0f / det; + mStabbedFace.mDistance *= OneOverDet; + mStabbedFace.mU *= OneOverDet; + mStabbedFace.mV *= OneOverDet; + } + else + { + // the non-culling branch + if(FastFabs(det) <= LOCAL_EPSILON * FCMin2(edge1.SquareMagnitude(), edge2.SquareMagnitude())) return FALSE; + float OneOverDet = 1.0f / det; + + // Calculate distance from vert0 to ray origin + Point tvec = mOrigin - vert0; + + // Calculate U parameter and test bounds + mStabbedFace.mU = (tvec|pvec) * OneOverDet; +// if(IR(u)&0x80000000 || u>1.0f) return FALSE; + if(IS_NEGATIVE_FLOAT(mStabbedFace.mU) || IR(mStabbedFace.mU)>IEEE_1_0) return FALSE; + + // prepare to test V parameter + Point qvec = tvec^edge1; + + // Calculate V parameter and test bounds + mStabbedFace.mV = (mDir|qvec) * OneOverDet; + if(IS_NEGATIVE_FLOAT(mStabbedFace.mV) || mStabbedFace.mU+mStabbedFace.mV>1.0f) return FALSE; + + // Calculate t, ray intersects triangle + mStabbedFace.mDistance = (edge2|qvec) * OneOverDet; + // Intersection point is valid if distance is positive (else it can just be a face behind the orig point) + if(IS_NEGATIVE_FLOAT(mStabbedFace.mDistance)) return FALSE; + } + return TRUE; +} diff --git a/libs/ode-0.16.1/OPCODE/OPC_Settings.h b/libs/ode-0.16.1/OPCODE/OPC_Settings.h new file mode 100644 index 0000000..7509888 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_Settings.h @@ -0,0 +1,49 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains compilation flags. + * \file OPC_Settings.h + * \author Pierre Terdiman + * \date May, 12, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __OPC_SETTINGS_H__ +#define __OPC_SETTINGS_H__ + + //! Use CPU comparisons (comment that line to use standard FPU compares) + //#define OPC_CPU_COMPARE + + //! Use FCOMI / FCMOV on Pentium-Pro based processors (comment that line to use plain C++) + #define OPC_USE_FCOMI + + //! Use epsilon value in tri-tri overlap test + #define OPC_TRITRI_EPSILON_TEST + + //! Use tree-coherence or not [not implemented yet] +// #define OPC_USE_TREE_COHERENCE + + //! Use callbacks or direct pointers. Using callbacks might be a bit slower (but probably not much) +// #define OPC_USE_CALLBACKS + + //! Support triangle and vertex strides or not. Using strides might be a bit slower (but probably not much) + #define OPC_USE_STRIDE + + //! Discard negative pointer in vanilla trees + #define OPC_NO_NEG_VANILLA_TREE + + //! Use a callback in the ray collider + //#define OPC_RAYHIT_CALLBACK + + // NB: no compilation flag to enable/disable stats since they're actually needed in the box/box overlap test + +#endif //__OPC_SETTINGS_H__ diff --git a/libs/ode-0.16.1/OPCODE/OPC_SphereAABBOverlap.h b/libs/ode-0.16.1/OPCODE/OPC_SphereAABBOverlap.h new file mode 100644 index 0000000..2278bc0 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_SphereAABBOverlap.h @@ -0,0 +1,128 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Sphere-AABB overlap test, based on Jim Arvo's code. + * \param center [in] box center + * \param extents [in] box extents + * \return TRUE on overlap + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +inline_ BOOL SphereCollider::SphereAABBOverlap(const Point& center, const Point& extents) +{ + // Stats + mNbVolumeBVTests++; + + float d = 0.0f; + + //find the square of the distance + //from the sphere to the box +#ifdef OLDIES + for(udword i=0;i<3;i++) + { + float tmp = mCenter[i] - center[i]; + float s = tmp + extents[i]; + + if(s<0.0f) d += s*s; + else + { + s = tmp - extents[i]; + if(s>0.0f) d += s*s; + } + } +#endif + +//#ifdef NEW_TEST + +// float tmp = mCenter.x - center.x; +// float s = tmp + extents.x; + + float tmp,s; + + tmp = mCenter.x - center.x; + s = tmp + extents.x; + + if(s<0.0f) + { + d += s*s; + if(d>mRadius2) return FALSE; + } + else + { + s = tmp - extents.x; + if(s>0.0f) + { + d += s*s; + if(d>mRadius2) return FALSE; + } + } + + tmp = mCenter.y - center.y; + s = tmp + extents.y; + + if(s<0.0f) + { + d += s*s; + if(d>mRadius2) return FALSE; + } + else + { + s = tmp - extents.y; + if(s>0.0f) + { + d += s*s; + if(d>mRadius2) return FALSE; + } + } + + tmp = mCenter.z - center.z; + s = tmp + extents.z; + + if(s<0.0f) + { + d += s*s; + if(d>mRadius2) return FALSE; + } + else + { + s = tmp - extents.z; + if(s>0.0f) + { + d += s*s; + if(d>mRadius2) return FALSE; + } + } +//#endif + +#ifdef OLDIES +// Point Min = center - extents; +// Point Max = center + extents; + + float d = 0.0f; + + //find the square of the distance + //from the sphere to the box + for(udword i=0;i<3;i++) + { +float Min = center[i] - extents[i]; + +// if(mCenter[i]Max[i]) + if(mCenter[i]>Max) + { + float s = mCenter[i] - Max; + d += s*s; + } + } + } +#endif + return d <= mRadius2; +} diff --git a/libs/ode-0.16.1/OPCODE/OPC_SphereCollider.cpp b/libs/ode-0.16.1/OPCODE/OPC_SphereCollider.cpp new file mode 100644 index 0000000..e2406ec --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_SphereCollider.cpp @@ -0,0 +1,739 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for a sphere collider. + * \file OPC_SphereCollider.cpp + * \author Pierre Terdiman + * \date June, 2, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains a sphere-vs-tree collider. + * This class performs a collision test between a sphere and an AABB tree. You can use this to do a standard player vs world collision, + * in a Nettle/Telemachos way. It doesn't suffer from all reported bugs in those two classic codes - the "new" one by Paul Nettle is a + * debuggued version I think. Collision response can be driven by reported collision data - it works extremely well for me. In sake of + * efficiency, all meshes (that is, all AABB trees) should of course also be kept in an extra hierarchical structure (octree, whatever). + * + * \class SphereCollider + * \author Pierre Terdiman + * \version 1.3 + * \date June, 2, 2001 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace Opcode; + +#include "OPC_SphereAABBOverlap.h" +#include "OPC_SphereTriOverlap.h" + +#define SET_CONTACT(prim_index, flag) \ + /* Set contact status */ \ + mFlags |= flag; \ + mTouchedPrimitives->Add(udword(prim_index)); + +//! Sphere-triangle overlap test +#define SPHERE_PRIM(prim_index, flag) \ + /* Request vertices from the app */ \ + VertexPointers VP; ConversionArea VC; mIMesh->GetTriangle(VP, prim_index, VC); \ + \ + /* Perform sphere-tri overlap test */ \ + if(SphereTriOverlap(*VP.Vertex[0], *VP.Vertex[1], *VP.Vertex[2])) \ + { \ + SET_CONTACT(prim_index, flag) \ + } + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +SphereCollider::SphereCollider() +{ + mCenter.Zero(); + mRadius2 = 0.0f; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +SphereCollider::~SphereCollider() +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Generic collision query for generic OPCODE models. After the call, access the results: + * - with GetContactStatus() + * - with GetNbTouchedPrimitives() + * - with GetTouchedPrimitives() + * + * \param cache [in/out] a sphere cache + * \param sphere [in] collision sphere in local space + * \param model [in] Opcode model to collide with + * \param worlds [in] sphere's world matrix, or null + * \param worldm [in] model's world matrix, or null + * \return true if success + * \warning SCALE NOT SUPPORTED. The matrices must contain rotation & translation parts only. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool SphereCollider::Collide(SphereCache& cache, const Sphere& sphere, const Model& model, const Matrix4x4* worlds, const Matrix4x4* worldm) +{ + // Checkings + if(!Setup(&model)) return false; + + // Init collision query + if(InitQuery(cache, sphere, worlds, worldm)) return true; + + // Special case for 1-leaf trees + if(mCurrentModel && mCurrentModel->HasSingleNode()) + { + // Here we're supposed to perform a normal query, except our tree has a single node, i.e. just a few triangles + udword Nb = mIMesh->GetNbTriangles(); + // Loop through all triangles + for(udword i=0;i(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform collision query + if(SkipPrimitiveTests()) _CollideNoPrimitiveTest(Tree->GetNodes()); + else _Collide(Tree->GetNodes()); + } + else + { + const AABBNoLeafTree* Tree = static_cast(model.GetTree()); + + // Perform collision query + if(SkipPrimitiveTests()) _CollideNoPrimitiveTest(Tree->GetNodes()); + else _Collide(Tree->GetNodes()); + } + } + else + { + if(model.IsQuantized()) + { + const AABBQuantizedTree* Tree = static_cast(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform collision query + if(SkipPrimitiveTests()) _CollideNoPrimitiveTest(Tree->GetNodes()); + else _Collide(Tree->GetNodes()); + } + else + { + const AABBCollisionTree* Tree = static_cast(model.GetTree()); + + // Perform collision query + if(SkipPrimitiveTests()) _CollideNoPrimitiveTest(Tree->GetNodes()); + else _Collide(Tree->GetNodes()); + } + } + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Initializes a collision query : + * - reset stats & contact status + * - setup matrices + * - check temporal coherence + * + * \param cache [in/out] a sphere cache + * \param sphere [in] sphere in local space + * \param worlds [in] sphere's world matrix, or null + * \param worldm [in] model's world matrix, or null + * \return TRUE if we can return immediately + * \warning SCALE NOT SUPPORTED. The matrices must contain rotation & translation parts only. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +BOOL SphereCollider::InitQuery(SphereCache& cache, const Sphere& sphere, const Matrix4x4* worlds, const Matrix4x4* worldm) +{ + // 1) Call the base method + VolumeCollider::InitQuery(); + + // 2) Compute sphere in model space: + // - Precompute R^2 + mRadius2 = sphere.mRadius * sphere.mRadius; + // - Compute center position + mCenter = sphere.mCenter; + // -> to world space + if(worlds) mCenter *= *worlds; + // -> to model space + if(worldm) + { + // Invert model matrix + Matrix4x4 InvWorldM; + InvertPRMatrix(InvWorldM, *worldm); + + mCenter *= InvWorldM; + } + + // 3) Setup destination pointer + mTouchedPrimitives = &cache.TouchedPrimitives; + + // 4) Special case: 1-triangle meshes [Opcode 1.3] + if(mCurrentModel && mCurrentModel->HasSingleNode()) + { + if(!SkipPrimitiveTests()) + { + // We simply perform the BV-Prim overlap test each time. We assume single triangle has index 0. + mTouchedPrimitives->Reset(); + + // Perform overlap test between the unique triangle and the sphere (and set contact status if needed) + SPHERE_PRIM(udword(0), OPC_CONTACT) + + // Return immediately regardless of status + return TRUE; + } + } + + // 5) Check temporal coherence : + if(TemporalCoherenceEnabled()) + { + // Here we use temporal coherence + // => check results from previous frame before performing the collision query + if(FirstContactEnabled()) + { + // We're only interested in the first contact found => test the unique previously touched face + if(mTouchedPrimitives->GetNbEntries()) + { + // Get index of previously touched face = the first entry in the array + udword PreviouslyTouchedFace = mTouchedPrimitives->GetEntry(0); + + // Then reset the array: + // - if the overlap test below is successful, the index we'll get added back anyway + // - if it isn't, then the array should be reset anyway for the normal query + mTouchedPrimitives->Reset(); + + // Perform overlap test between the cached triangle and the sphere (and set contact status if needed) + SPHERE_PRIM(PreviouslyTouchedFace, OPC_TEMPORAL_CONTACT) + + // Return immediately if possible + if(GetContactStatus()) return TRUE; + } + // else no face has been touched during previous query + // => we'll have to perform a normal query + } + else + { + // We're interested in all contacts =>test the new real sphere N(ew) against the previous fat sphere P(revious): + float r = sqrtf(cache.FatRadius2) - sphere.mRadius; + if(IsCacheValid(cache) && cache.Center.SquareDistance(mCenter) < r*r) + { + // - if N is included in P, return previous list + // => we simply leave the list (mTouchedFaces) unchanged + + // Set contact status if needed + if(mTouchedPrimitives->GetNbEntries()) mFlags |= OPC_TEMPORAL_CONTACT; + + // In any case we don't need to do a query + return TRUE; + } + else + { + // - else do the query using a fat N + + // Reset cache since we'll about to perform a real query + mTouchedPrimitives->Reset(); + + // Make a fat sphere so that coherence will work for subsequent frames + mRadius2 *= cache.FatCoeff; +// mRadius2 = (sphere.mRadius * cache.FatCoeff)*(sphere.mRadius * cache.FatCoeff); + + // Update cache with query data (signature for cached faces) + cache.Center = mCenter; + cache.FatRadius2 = mRadius2; + } + } + } + else + { + // Here we don't use temporal coherence => do a normal query + mTouchedPrimitives->Reset(); + } + + return FALSE; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Collision query for vanilla AABB trees. + * \param cache [in/out] a sphere cache + * \param sphere [in] collision sphere in world space + * \param tree [in] AABB tree + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool SphereCollider::Collide(SphereCache& cache, const Sphere& sphere, const AABBTree* tree) +{ + // This is typically called for a scene tree, full of -AABBs-, not full of triangles. + // So we don't really have "primitives" to deal with. Hence it doesn't work with + // "FirstContact" + "TemporalCoherence". + ASSERT( !(FirstContactEnabled() && TemporalCoherenceEnabled()) ); + + // Checkings + if(!tree) return false; + + // Init collision query + if(InitQuery(cache, sphere)) return true; + + // Perform collision query + _Collide(tree); + + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Checks the sphere completely contains the box. In which case we can end the query sooner. + * \param bc [in] box center + * \param be [in] box extents + * \return true if the sphere contains the whole box + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +inline_ BOOL SphereCollider::SphereContainsBox(const Point& bc, const Point& be) +{ + // I assume if all 8 box vertices are inside the sphere, so does the whole box. + // Sounds ok but maybe there's a better way? + Point p; + p.x=bc.x+be.x; p.y=bc.y+be.y; p.z=bc.z+be.z; if(mCenter.SquareDistance(p)>=mRadius2) return FALSE; + p.x=bc.x-be.x; if(mCenter.SquareDistance(p)>=mRadius2) return FALSE; + p.x=bc.x+be.x; p.y=bc.y-be.y; if(mCenter.SquareDistance(p)>=mRadius2) return FALSE; + p.x=bc.x-be.x; if(mCenter.SquareDistance(p)>=mRadius2) return FALSE; + p.x=bc.x+be.x; p.y=bc.y+be.y; p.z=bc.z-be.z; if(mCenter.SquareDistance(p)>=mRadius2) return FALSE; + p.x=bc.x-be.x; if(mCenter.SquareDistance(p)>=mRadius2) return FALSE; + p.x=bc.x+be.x; p.y=bc.y-be.y; if(mCenter.SquareDistance(p)>=mRadius2) return FALSE; + p.x=bc.x-be.x; if(mCenter.SquareDistance(p)>=mRadius2) return FALSE; + + return TRUE; +} + +#define TEST_BOX_IN_SPHERE(center, extents) \ + if(SphereContainsBox(center, extents)) \ + { \ + /* Set contact status */ \ + mFlags |= OPC_CONTACT; \ + _Dump(node); \ + return; \ + } + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for normal AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void SphereCollider::_Collide(const AABBCollisionNode* node) +{ + // Perform Sphere-AABB overlap test + if(!SphereAABBOverlap(node->mAABB.mCenter, node->mAABB.mExtents)) return; + + TEST_BOX_IN_SPHERE(node->mAABB.mCenter, node->mAABB.mExtents) + + if(node->IsLeaf()) + { + SPHERE_PRIM(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _Collide(node->GetPos()); + + if(ContactFound()) return; + + _Collide(node->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for normal AABB trees, without primitive tests. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void SphereCollider::_CollideNoPrimitiveTest(const AABBCollisionNode* node) +{ + // Perform Sphere-AABB overlap test + if(!SphereAABBOverlap(node->mAABB.mCenter, node->mAABB.mExtents)) return; + + TEST_BOX_IN_SPHERE(node->mAABB.mCenter, node->mAABB.mExtents) + + if(node->IsLeaf()) + { + SET_CONTACT(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _CollideNoPrimitiveTest(node->GetPos()); + + if(ContactFound()) return; + + _CollideNoPrimitiveTest(node->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void SphereCollider::_Collide(const AABBQuantizedNode* node) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Perform Sphere-AABB overlap test + if(!SphereAABBOverlap(Center, Extents)) return; + + TEST_BOX_IN_SPHERE(Center, Extents) + + if(node->IsLeaf()) + { + SPHERE_PRIM(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _Collide(node->GetPos()); + + if(ContactFound()) return; + + _Collide(node->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized AABB trees, without primitive tests. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void SphereCollider::_CollideNoPrimitiveTest(const AABBQuantizedNode* node) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Perform Sphere-AABB overlap test + if(!SphereAABBOverlap(Center, Extents)) return; + + TEST_BOX_IN_SPHERE(Center, Extents) + + if(node->IsLeaf()) + { + SET_CONTACT(node->GetPrimitive(), OPC_CONTACT) + } + else + { + _CollideNoPrimitiveTest(node->GetPos()); + + if(ContactFound()) return; + + _CollideNoPrimitiveTest(node->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for no-leaf AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void SphereCollider::_Collide(const AABBNoLeafNode* node) +{ + // Perform Sphere-AABB overlap test + if(!SphereAABBOverlap(node->mAABB.mCenter, node->mAABB.mExtents)) return; + + TEST_BOX_IN_SPHERE(node->mAABB.mCenter, node->mAABB.mExtents) + + if(node->HasPosLeaf()) { SPHERE_PRIM(node->GetPosPrimitive(), OPC_CONTACT) } + else _Collide(node->GetPos()); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) { SPHERE_PRIM(node->GetNegPrimitive(), OPC_CONTACT) } + else _Collide(node->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for no-leaf AABB trees, without primitive tests. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void SphereCollider::_CollideNoPrimitiveTest(const AABBNoLeafNode* node) +{ + // Perform Sphere-AABB overlap test + if(!SphereAABBOverlap(node->mAABB.mCenter, node->mAABB.mExtents)) return; + + TEST_BOX_IN_SPHERE(node->mAABB.mCenter, node->mAABB.mExtents) + + if(node->HasPosLeaf()) { SET_CONTACT(node->GetPosPrimitive(), OPC_CONTACT) } + else _CollideNoPrimitiveTest(node->GetPos()); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) { SET_CONTACT(node->GetNegPrimitive(), OPC_CONTACT) } + else _CollideNoPrimitiveTest(node->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized no-leaf AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void SphereCollider::_Collide(const AABBQuantizedNoLeafNode* node) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Perform Sphere-AABB overlap test + if(!SphereAABBOverlap(Center, Extents)) return; + + TEST_BOX_IN_SPHERE(Center, Extents) + + if(node->HasPosLeaf()) { SPHERE_PRIM(node->GetPosPrimitive(), OPC_CONTACT) } + else _Collide(node->GetPos()); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) { SPHERE_PRIM(node->GetNegPrimitive(), OPC_CONTACT) } + else _Collide(node->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized no-leaf AABB trees, without primitive tests. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void SphereCollider::_CollideNoPrimitiveTest(const AABBQuantizedNoLeafNode* node) +{ + // Dequantize box + const QuantizedAABB& Box = node->mAABB; + const Point Center(float(Box.mCenter[0]) * mCenterCoeff.x, float(Box.mCenter[1]) * mCenterCoeff.y, float(Box.mCenter[2]) * mCenterCoeff.z); + const Point Extents(float(Box.mExtents[0]) * mExtentsCoeff.x, float(Box.mExtents[1]) * mExtentsCoeff.y, float(Box.mExtents[2]) * mExtentsCoeff.z); + + // Perform Sphere-AABB overlap test + if(!SphereAABBOverlap(Center, Extents)) return; + + TEST_BOX_IN_SPHERE(Center, Extents) + + if(node->HasPosLeaf()) { SET_CONTACT(node->GetPosPrimitive(), OPC_CONTACT) } + else _CollideNoPrimitiveTest(node->GetPos()); + + if(ContactFound()) return; + + if(node->HasNegLeaf()) { SET_CONTACT(node->GetNegPrimitive(), OPC_CONTACT) } + else _CollideNoPrimitiveTest(node->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for vanilla AABB trees. + * \param node [in] current collision node + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void SphereCollider::_Collide(const AABBTreeNode* node) +{ + // Perform Sphere-AABB overlap test + Point Center, Extents; + node->GetAABB()->GetCenter(Center); + node->GetAABB()->GetExtents(Extents); + if(!SphereAABBOverlap(Center, Extents)) return; + + if(node->IsLeaf() || SphereContainsBox(Center, Extents)) + { + mFlags |= OPC_CONTACT; + mTouchedPrimitives->Add(node->GetPrimitives(), node->GetNbPrimitives()); + } + else + { + _Collide(node->GetPos()); + _Collide(node->GetNeg()); + } +} + + + + + + + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Constructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +HybridSphereCollider::HybridSphereCollider() +{ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Destructor. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +HybridSphereCollider::~HybridSphereCollider() +{ +} + +bool HybridSphereCollider::Collide(SphereCache& cache, const Sphere& sphere, const HybridModel& model, const Matrix4x4* worlds, const Matrix4x4* worldm) +{ + // We don't want primitive tests here! + mFlags |= OPC_NO_PRIMITIVE_TESTS; + + // Checkings + if(!Setup(&model)) return false; + + // Init collision query + if(InitQuery(cache, sphere, worlds, worldm)) return true; + + // Special case for 1-leaf trees + if(mCurrentModel && mCurrentModel->HasSingleNode()) + { + // Here we're supposed to perform a normal query, except our tree has a single node, i.e. just a few triangles + udword Nb = mIMesh->GetNbTriangles(); + + // Loop through all triangles + for(udword i=0;i(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform collision query - we don't want primitive tests here! + _CollideNoPrimitiveTest(Tree->GetNodes()); + } + else + { + const AABBNoLeafTree* Tree = static_cast(model.GetTree()); + + // Perform collision query - we don't want primitive tests here! + _CollideNoPrimitiveTest(Tree->GetNodes()); + } + } + else + { + if(model.IsQuantized()) + { + const AABBQuantizedTree* Tree = static_cast(model.GetTree()); + + // Setup dequantization coeffs + mCenterCoeff = Tree->mCenterCoeff; + mExtentsCoeff = Tree->mExtentsCoeff; + + // Perform collision query - we don't want primitive tests here! + _CollideNoPrimitiveTest(Tree->GetNodes()); + } + else + { + const AABBCollisionTree* Tree = static_cast(model.GetTree()); + + // Perform collision query - we don't want primitive tests here! + _CollideNoPrimitiveTest(Tree->GetNodes()); + } + } + + // We only have a list of boxes so far + if(GetContactStatus()) + { + // Reset contact status, since it currently only reflects collisions with leaf boxes + Collider::InitQuery(); + + // Change dest container so that we can use built-in overlap tests and get collided primitives + cache.TouchedPrimitives.Reset(); + mTouchedPrimitives = &cache.TouchedPrimitives; + + // Read touched leaf boxes + udword Nb = mTouchedBoxes.GetNbEntries(); + const udword* Touched = mTouchedBoxes.GetEntries(); + + const LeafTriangles* LT = model.GetLeafTriangles(); + const udword* Indices = model.GetIndices(); + + // Loop through touched leaves + while(Nb--) + { + const LeafTriangles& CurrentLeaf = LT[*Touched++]; + + // Each leaf box has a set of triangles + udword NbTris = CurrentLeaf.GetNbTriangles(); + if(Indices) + { + const udword* T = &Indices[CurrentLeaf.GetTriangleIndex()]; + + // Loop through triangles and test each of them + while(NbTris--) + { + udword TriangleIndex = *T++; + SPHERE_PRIM(TriangleIndex, OPC_CONTACT) + } + } + else + { + udword BaseIndex = CurrentLeaf.GetTriangleIndex(); + + // Loop through triangles and test each of them + while(NbTris--) + { + udword TriangleIndex = BaseIndex++; + SPHERE_PRIM(TriangleIndex, OPC_CONTACT) + } + } + } + } + + return true; +} diff --git a/libs/ode-0.16.1/OPCODE/OPC_SphereCollider.h b/libs/ode-0.16.1/OPCODE/OPC_SphereCollider.h new file mode 100644 index 0000000..ac6495e --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_SphereCollider.h @@ -0,0 +1,96 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for a sphere collider. + * \file OPC_SphereCollider.h + * \author Pierre Terdiman + * \date June, 2, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __OPC_SPHERECOLLIDER_H__ +#define __OPC_SPHERECOLLIDER_H__ + + struct OPCODE_API SphereCache : VolumeCache + { + SphereCache() : Center(0.0f,0.0f,0.0f), FatRadius2(0.0f), FatCoeff(1.1f) {} + ~SphereCache() {} + + // Cached faces signature + Point Center; //!< Sphere used when performing the query resulting in cached faces + float FatRadius2; //!< Sphere used when performing the query resulting in cached faces + // User settings + float FatCoeff; //!< mRadius2 multiplier used to create a fat sphere + }; + + class OPCODE_API SphereCollider : public VolumeCollider + { + public: + // Constructor / Destructor + SphereCollider(); + virtual ~SphereCollider(); + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Generic collision query for generic OPCODE models. After the call, access the results: + * - with GetContactStatus() + * - with GetNbTouchedPrimitives() + * - with GetTouchedPrimitives() + * + * \param cache [in/out] a sphere cache + * \param sphere [in] collision sphere in local space + * \param model [in] Opcode model to collide with + * \param worlds [in] sphere's world matrix, or null + * \param worldm [in] model's world matrix, or null + * \return true if success + * \warning SCALE NOT SUPPORTED. The matrices must contain rotation & translation parts only. + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + bool Collide(SphereCache& cache, const Sphere& sphere, const Model& model, const Matrix4x4* worlds=null, const Matrix4x4* worldm=null); + + // + bool Collide(SphereCache& cache, const Sphere& sphere, const AABBTree* tree); + protected: + // Sphere in model space + Point mCenter; //!< Sphere center + float mRadius2; //!< Sphere radius squared + // Internal methods + void _Collide(const AABBCollisionNode* node); + void _Collide(const AABBNoLeafNode* node); + void _Collide(const AABBQuantizedNode* node); + void _Collide(const AABBQuantizedNoLeafNode* node); + void _Collide(const AABBTreeNode* node); + void _CollideNoPrimitiveTest(const AABBCollisionNode* node); + void _CollideNoPrimitiveTest(const AABBNoLeafNode* node); + void _CollideNoPrimitiveTest(const AABBQuantizedNode* node); + void _CollideNoPrimitiveTest(const AABBQuantizedNoLeafNode* node); + // Overlap tests + inline_ BOOL SphereContainsBox(const Point& bc, const Point& be); + inline_ BOOL SphereAABBOverlap(const Point& center, const Point& extents); + BOOL SphereTriOverlap(const Point& vert0, const Point& vert1, const Point& vert2); + // Init methods + BOOL InitQuery(SphereCache& cache, const Sphere& sphere, const Matrix4x4* worlds=null, const Matrix4x4* worldm=null); + }; + + class OPCODE_API HybridSphereCollider : public SphereCollider + { + public: + // Constructor / Destructor + HybridSphereCollider(); + virtual ~HybridSphereCollider(); + + bool Collide(SphereCache& cache, const Sphere& sphere, const HybridModel& model, const Matrix4x4* worlds=null, const Matrix4x4* worldm=null); + protected: + Container mTouchedBoxes; + }; + +#endif // __OPC_SPHERECOLLIDER_H__ diff --git a/libs/ode-0.16.1/OPCODE/OPC_SphereTriOverlap.h b/libs/ode-0.16.1/OPCODE/OPC_SphereTriOverlap.h new file mode 100644 index 0000000..77e59f3 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_SphereTriOverlap.h @@ -0,0 +1,187 @@ + +// This is collision detection. If you do another distance test for collision *response*, +// if might be useful to simply *skip* the test below completely, and report a collision. +// - if sphere-triangle overlap, result is ok +// - if they don't, we'll discard them during collision response with a similar test anyway +// Overall this approach should run faster. + +// Original code by David Eberly in Magic. +BOOL SphereCollider::SphereTriOverlap(const Point& vert0, const Point& vert1, const Point& vert2) +{ + // Stats + mNbVolumePrimTests++; + + // Early exit if one of the vertices is inside the sphere + Point kDiff = vert2 - mCenter; + float fC = kDiff.SquareMagnitude(); + if(fC <= mRadius2) return TRUE; + + kDiff = vert1 - mCenter; + fC = kDiff.SquareMagnitude(); + if(fC <= mRadius2) return TRUE; + + kDiff = vert0 - mCenter; + fC = kDiff.SquareMagnitude(); + if(fC <= mRadius2) return TRUE; + + // Else do the full distance test + Point TriEdge0 = vert1 - vert0; + Point TriEdge1 = vert2 - vert0; + +//Point kDiff = vert0 - mCenter; + float fA00 = TriEdge0.SquareMagnitude(); + float fA01 = TriEdge0 | TriEdge1; + float fA11 = TriEdge1.SquareMagnitude(); + float fB0 = kDiff | TriEdge0; + float fB1 = kDiff | TriEdge1; +//float fC = kDiff.SquareMagnitude(); + float fDet = fabsf(fA00*fA11 - fA01*fA01); + float u = fA01*fB1-fA11*fB0; + float v = fA01*fB0-fA00*fB1; + float SqrDist; + + if(u + v <= fDet) + { + if(u < 0.0f) + { + if(v < 0.0f) // region 4 + { + if(fB0 < 0.0f) + { +// v = 0.0f; + if(-fB0>=fA00) { /*u = 1.0f;*/ SqrDist = fA00+2.0f*fB0+fC; } + else { u = -fB0/fA00; SqrDist = fB0*u+fC; } + } + else + { +// u = 0.0f; + if(fB1>=0.0f) { /*v = 0.0f;*/ SqrDist = fC; } + else if(-fB1>=fA11) { /*v = 1.0f;*/ SqrDist = fA11+2.0f*fB1+fC; } + else { v = -fB1/fA11; SqrDist = fB1*v+fC; } + } + } + else // region 3 + { +// u = 0.0f; + if(fB1>=0.0f) { /*v = 0.0f;*/ SqrDist = fC; } + else if(-fB1>=fA11) { /*v = 1.0f;*/ SqrDist = fA11+2.0f*fB1+fC; } + else { v = -fB1/fA11; SqrDist = fB1*v+fC; } + } + } + else if(v < 0.0f) // region 5 + { +// v = 0.0f; + if(fB0>=0.0f) { /*u = 0.0f;*/ SqrDist = fC; } + else if(-fB0>=fA00) { /*u = 1.0f;*/ SqrDist = fA00+2.0f*fB0+fC; } + else { u = -fB0/fA00; SqrDist = fB0*u+fC; } + } + else // region 0 + { + // minimum at interior point + if(fDet==0.0f) + { +// u = 0.0f; +// v = 0.0f; + SqrDist = MAX_FLOAT; + } + else + { + float fInvDet = 1.0f/fDet; + u *= fInvDet; + v *= fInvDet; + SqrDist = u*(fA00*u+fA01*v+2.0f*fB0) + v*(fA01*u+fA11*v+2.0f*fB1)+fC; + } + } + } + else + { + float fTmp0, fTmp1, fNumer, fDenom; + + if(u < 0.0f) // region 2 + { + fTmp0 = fA01 + fB0; + fTmp1 = fA11 + fB1; + if(fTmp1 > fTmp0) + { + fNumer = fTmp1 - fTmp0; + fDenom = fA00-2.0f*fA01+fA11; + if(fNumer >= fDenom) + { +// u = 1.0f; +// v = 0.0f; + SqrDist = fA00+2.0f*fB0+fC; + } + else + { + u = fNumer/fDenom; + v = 1.0f - u; + SqrDist = u*(fA00*u+fA01*v+2.0f*fB0) + v*(fA01*u+fA11*v+2.0f*fB1)+fC; + } + } + else + { +// u = 0.0f; + if(fTmp1 <= 0.0f) { /*v = 1.0f;*/ SqrDist = fA11+2.0f*fB1+fC; } + else if(fB1 >= 0.0f) { /*v = 0.0f;*/ SqrDist = fC; } + else { v = -fB1/fA11; SqrDist = fB1*v+fC; } + } + } + else if(v < 0.0f) // region 6 + { + fTmp0 = fA01 + fB1; + fTmp1 = fA00 + fB0; + if(fTmp1 > fTmp0) + { + fNumer = fTmp1 - fTmp0; + fDenom = fA00-2.0f*fA01+fA11; + if(fNumer >= fDenom) + { +// v = 1.0f; +// u = 0.0f; + SqrDist = fA11+2.0f*fB1+fC; + } + else + { + v = fNumer/fDenom; + u = 1.0f - v; + SqrDist = u*(fA00*u+fA01*v+2.0f*fB0) + v*(fA01*u+fA11*v+2.0f*fB1)+fC; + } + } + else + { +// v = 0.0f; + if(fTmp1 <= 0.0f) { /*u = 1.0f;*/ SqrDist = fA00+2.0f*fB0+fC; } + else if(fB0 >= 0.0f) { /*u = 0.0f;*/ SqrDist = fC; } + else { u = -fB0/fA00; SqrDist = fB0*u+fC; } + } + } + else // region 1 + { + fNumer = fA11 + fB1 - fA01 - fB0; + if(fNumer <= 0.0f) + { +// u = 0.0f; +// v = 1.0f; + SqrDist = fA11+2.0f*fB1+fC; + } + else + { + fDenom = fA00-2.0f*fA01+fA11; + if(fNumer >= fDenom) + { +// u = 1.0f; +// v = 0.0f; + SqrDist = fA00+2.0f*fB0+fC; + } + else + { + u = fNumer/fDenom; + v = 1.0f - u; + SqrDist = u*(fA00*u+fA01*v+2.0f*fB0) + v*(fA01*u+fA11*v+2.0f*fB1)+fC; + } + } + } + } + + return fabsf(SqrDist) < mRadius2; +} diff --git a/libs/ode-0.16.1/OPCODE/OPC_TreeBuilders.cpp b/libs/ode-0.16.1/OPCODE/OPC_TreeBuilders.cpp new file mode 100644 index 0000000..4a78914 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_TreeBuilders.cpp @@ -0,0 +1,306 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for tree builders. + * \file OPC_TreeBuilders.cpp + * \author Pierre Terdiman + * \date March, 20, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * A builder for AABB-trees of vertices. + * + * \class AABBTreeOfVerticesBuilder + * \author Pierre Terdiman + * \version 1.3 + * \date March, 20, 2001 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * A builder for AABB-trees of AABBs. + * + * \class AABBTreeOfAABBsBuilder + * \author Pierre Terdiman + * \version 1.3 + * \date March, 20, 2001 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * A builder for AABB-trees of triangles. + * + * \class AABBTreeOfTrianglesBuilder + * \author Pierre Terdiman + * \version 1.3 + * \date March, 20, 2001 +*/ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace Opcode; + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the AABB of a set of primitives. + * \param primitives [in] list of indices of primitives + * \param nb_prims [in] number of indices + * \param global_box [out] global AABB enclosing the set of input primitives + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBTreeOfAABBsBuilder::ComputeGlobalBox(const dTriIndex* primitives, udword nb_prims, AABB& global_box) const +{ + // Checkings + if(!primitives || !nb_prims) return false; + + // Initialize global box + global_box = mAABBArray[primitives[0]]; + + // Loop through boxes + for(udword i=1;iGetTriangle(VP, *primitives++, VC); + // Update global box + Min.Min(*VP.Vertex[0]).Min(*VP.Vertex[1]).Min(*VP.Vertex[2]); + Max.Max(*VP.Vertex[0]).Max(*VP.Vertex[1]).Max(*VP.Vertex[2]); + } + global_box.SetMinMax(Min, Max); + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the splitting value along a given axis for a given primitive. + * \param index [in] index of the primitive to split + * \return splitting value + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +Point AABBTreeOfTrianglesBuilder::GetSplittingValues(udword index) const +{ + VertexPointers VP; + ConversionArea VC; + mIMesh->GetTriangle(VP, index, VC); + + return ( *VP.Vertex[0] + *VP.Vertex[1] + *VP.Vertex[2] ) * INV3; +} + + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the splitting value along a given axis for a given primitive. + * \param index [in] index of the primitive to split + * \param axis [in] axis index (0,1,2) + * \return splitting value + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +float AABBTreeOfTrianglesBuilder::GetSplittingValue(udword index, udword axis) const +{ +/* // Compute center of triangle + Point Center; + mTriList[index].Center(mVerts, Center); + // Return value + return Center[axis];*/ + + // Compute correct component from center of triangle +// return (mVerts[mTriList[index].mVRef[0]][axis] +// +mVerts[mTriList[index].mVRef[1]][axis] +// +mVerts[mTriList[index].mVRef[2]][axis])*INV3; + + VertexPointers VP; + ConversionArea VC; + mIMesh->GetTriangle(VP, index, VC); + + // Compute correct component from center of triangle + return ((*VP.Vertex[0])[axis] + +(*VP.Vertex[1])[axis] + +(*VP.Vertex[2])[axis])*INV3; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the splitting value along a given axis for a given node. + * \param primitives [in] list of indices of primitives + * \param nb_prims [in] number of indices + * \param global_box [in] global AABB enclosing the set of input primitives + * \param axis [in] axis index (0,1,2) + * \return splitting value + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +float AABBTreeOfTrianglesBuilder::GetSplittingValue(const dTriIndex* primitives, udword nb_prims, const AABB& global_box, udword axis) const +{ + if(mSettings.mRules&SPLIT_GEOM_CENTER) + { + // Loop through triangles + float SplitValue = 0.0f; + VertexPointers VP; + ConversionArea VC; + for(udword i=0;iGetTriangle(VP, primitives[i], VC); + // Update split value + SplitValue += (*VP.Vertex[0])[axis]; + SplitValue += (*VP.Vertex[1])[axis]; + SplitValue += (*VP.Vertex[2])[axis]; + } + return SplitValue / float(nb_prims*3); + } + else return AABBTreeBuilder::GetSplittingValue(primitives, nb_prims, global_box, axis); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Computes the AABB of a set of primitives. + * \param primitives [in] list of indices of primitives + * \param nb_prims [in] number of indices + * \param global_box [out] global AABB enclosing the set of input primitives + * \return true if success + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBTreeOfVerticesBuilder::ComputeGlobalBox(const dTriIndex* primitives, udword nb_prims, AABB& global_box) const +{ + // Checkings + if(!primitives || !nb_prims) return false; + + // Initialize global box + global_box.SetEmpty(); + + // Loop through vertices + for(udword i=0;iHasLeafNodes()!=cache.Model1->HasLeafNodes()) return false; + if(cache.Model0->IsQuantized()!=cache.Model1->IsQuantized()) return false; + + /* + + Rules: + - perform hull test + - when hulls collide, disable hull test + - if meshes overlap, reset countdown + - if countdown reaches 0, enable hull test + + */ + +#ifdef __MESHMERIZER_H__ + // Handle hulls + if(cache.HullTest) + { + if(cache.Model0->GetHull() && cache.Model1->GetHull()) + { + struct Local + { + static Point* SVCallback(const Point& sv, udword& previndex, udword user_data) + { + CollisionHull* Hull = (CollisionHull*)user_data; + previndex = Hull->ComputeSupportingVertex(sv, previndex); + return (Point*)&Hull->GetVerts()[previndex]; + } + }; + + bool Collide; + + if(0) + { + static GJKEngine GJK; -- not thread safe, store in ThreadLocalData + static bool GJKInitDone=false; -- not thread safe, to be removed + if(!GJKInitDone) + { + GJK.Enable(GJK_BACKUP_PROCEDURE); + GJK.Enable(GJK_DEGENERATE); + GJK.Enable(GJK_HILLCLIMBING); + GJKInitDone = true; + } + GJK.SetCallbackObj0(Local::SVCallback); + GJK.SetCallbackObj1(Local::SVCallback); + GJK.SetUserData0(udword(cache.Model0->GetHull())); + GJK.SetUserData1(udword(cache.Model1->GetHull())); + Collide = GJK.Collide(*world0, *world1, &cache.SepVector); + } + else + { + static SVEngine SVE; -- not thread safe, store in ThreadLocalData + SVE.SetCallbackObj0(Local::SVCallback); + SVE.SetCallbackObj1(Local::SVCallback); + SVE.SetUserData0(udword(cache.Model0->GetHull())); + SVE.SetUserData1(udword(cache.Model1->GetHull())); + Collide = SVE.Collide(*world0, *world1, &cache.SepVector); + } + + if(!Collide) + { + // Reset stats & contact status + mFlags &= ~OPC_CONTACT; + mNbBVBVTests = 0; + mNbPrimPrimTests = 0; + mNbBVPrimTests = 0; + mPairs.Reset(); + return true; + } + } + } + + // Here, hulls collide + cache.HullTest = false; +#endif // __MESHMERIZER_H__ + + // Checkings + if(!Setup(cache.Model0->GetMeshInterface(), cache.Model1->GetMeshInterface())) return false; + + // Simple double-dispatch + bool Status; + if(!cache.Model0->HasLeafNodes()) + { + if(cache.Model0->IsQuantized()) + { + const AABBQuantizedNoLeafTree* T0 = static_cast(cache.Model0->GetTree()); + const AABBQuantizedNoLeafTree* T1 = static_cast(cache.Model1->GetTree()); + Status = Collide(T0, T1, world0, world1, &cache); + } + else + { + const AABBNoLeafTree* T0 = static_cast(cache.Model0->GetTree()); + const AABBNoLeafTree* T1 = static_cast(cache.Model1->GetTree()); + Status = Collide(T0, T1, world0, world1, &cache); + } + } + else + { + if(cache.Model0->IsQuantized()) + { + const AABBQuantizedTree* T0 = static_cast(cache.Model0->GetTree()); + const AABBQuantizedTree* T1 = static_cast(cache.Model1->GetTree()); + Status = Collide(T0, T1, world0, world1, &cache); + } + else + { + const AABBCollisionTree* T0 = static_cast(cache.Model0->GetTree()); + const AABBCollisionTree* T1 = static_cast(cache.Model1->GetTree()); + Status = Collide(T0, T1, world0, world1, &cache); + } + } + +#ifdef __MESHMERIZER_H__ + if(Status) + { + // Reset counter as long as overlap occurs + if(GetContactStatus()) cache.ResetCountDown(); + + // Enable hull test again when counter reaches zero + cache.CountDown--; + if(!cache.CountDown) + { + cache.ResetCountDown(); + cache.HullTest = true; + } + } +#endif + return Status; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Initializes a collision query : + * - reset stats & contact status + * - setup matrices + * + * \param world0 [in] world matrix for first object + * \param world1 [in] world matrix for second object + * \warning SCALE NOT SUPPORTED. The matrices must contain rotation & translation parts only. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBTreeCollider::InitQuery(const Matrix4x4* world0, const Matrix4x4* world1) +{ + // Reset stats & contact status + Collider::InitQuery(); + mNbBVBVTests = 0; + mNbPrimPrimTests = 0; + mNbBVPrimTests = 0; + mPairs.Reset(); + + // Setup matrices + Matrix4x4 InvWorld0, InvWorld1; + if(world0) InvertPRMatrix(InvWorld0, *world0); + else InvWorld0.Identity(); + + if(world1) InvertPRMatrix(InvWorld1, *world1); + else InvWorld1.Identity(); + + Matrix4x4 World0to1 = world0 ? (*world0 * InvWorld1) : InvWorld1; + Matrix4x4 World1to0 = world1 ? (*world1 * InvWorld0) : InvWorld0; + + mR0to1 = World0to1; World0to1.GetTrans(mT0to1); + mR1to0 = World1to0; World1to0.GetTrans(mT1to0); + + // Precompute absolute 1-to-0 rotation matrix + for(udword i=0;i<3;i++) + { + for(udword j=0;j<3;j++) + { + // Epsilon value prevents floating-point inaccuracies (strategy borrowed from RAPID) + mAR.m[i][j] = 1e-6f + fabsf(mR1to0.m[i][j]); + } + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Takes advantage of temporal coherence. + * \param cache [in] cache for a pair of previously colliding primitives + * \return true if we can return immediately + * \warning only works for "First Contact" mode + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBTreeCollider::CheckTemporalCoherence(Pair* cache) +{ + // Checkings + if(!cache) return false; + + // Test previously colliding primitives first + if(TemporalCoherenceEnabled() && FirstContactEnabled()) + { + PrimTest(cache->id0, cache->id1); + if(GetContactStatus()) return true; + } + return false; +} + +#define UPDATE_CACHE \ + if(cache && GetContactStatus()) \ + { \ + cache->id0 = mPairs.GetEntry(0); \ + cache->id1 = mPairs.GetEntry(1); \ + } + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Collision query for normal AABB trees. + * \param tree0 [in] AABB tree from first object + * \param tree1 [in] AABB tree from second object + * \param world0 [in] world matrix for first object + * \param world1 [in] world matrix for second object + * \param cache [in/out] cache for a pair of previously colliding primitives + * \return true if success + * \warning SCALE NOT SUPPORTED. The matrices must contain rotation & translation parts only. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBTreeCollider::Collide(const AABBCollisionTree* tree0, const AABBCollisionTree* tree1, const Matrix4x4* world0, const Matrix4x4* world1, Pair* cache) +{ + // Init collision query + InitQuery(world0, world1); + + // Check previous state + if(CheckTemporalCoherence(cache)) return true; + + // Perform collision query + _Collide(tree0->GetNodes(), tree1->GetNodes()); + + UPDATE_CACHE + + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Collision query for no-leaf AABB trees. + * \param tree0 [in] AABB tree from first object + * \param tree1 [in] AABB tree from second object + * \param world0 [in] world matrix for first object + * \param world1 [in] world matrix for second object + * \param cache [in/out] cache for a pair of previously colliding primitives + * \return true if success + * \warning SCALE NOT SUPPORTED. The matrices must contain rotation & translation parts only. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBTreeCollider::Collide(const AABBNoLeafTree* tree0, const AABBNoLeafTree* tree1, const Matrix4x4* world0, const Matrix4x4* world1, Pair* cache) +{ + // Init collision query + InitQuery(world0, world1); + + // Check previous state + if(CheckTemporalCoherence(cache)) return true; + + // Perform collision query + _Collide(tree0->GetNodes(), tree1->GetNodes()); + + UPDATE_CACHE + + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Collision query for quantized AABB trees. + * \param tree0 [in] AABB tree from first object + * \param tree1 [in] AABB tree from second object + * \param world0 [in] world matrix for first object + * \param world1 [in] world matrix for second object + * \param cache [in/out] cache for a pair of previously colliding primitives + * \return true if success + * \warning SCALE NOT SUPPORTED. The matrices must contain rotation & translation parts only. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBTreeCollider::Collide(const AABBQuantizedTree* tree0, const AABBQuantizedTree* tree1, const Matrix4x4* world0, const Matrix4x4* world1, Pair* cache) +{ + // Init collision query + InitQuery(world0, world1); + + // Check previous state + if(CheckTemporalCoherence(cache)) return true; + + // Setup dequantization coeffs + mCenterCoeff0 = tree0->mCenterCoeff; + mExtentsCoeff0 = tree0->mExtentsCoeff; + mCenterCoeff1 = tree1->mCenterCoeff; + mExtentsCoeff1 = tree1->mExtentsCoeff; + + // Dequantize box A + const AABBQuantizedNode* N0 = tree0->GetNodes(); + const Point a(float(N0->mAABB.mExtents[0]) * mExtentsCoeff0.x, float(N0->mAABB.mExtents[1]) * mExtentsCoeff0.y, float(N0->mAABB.mExtents[2]) * mExtentsCoeff0.z); + const Point Pa(float(N0->mAABB.mCenter[0]) * mCenterCoeff0.x, float(N0->mAABB.mCenter[1]) * mCenterCoeff0.y, float(N0->mAABB.mCenter[2]) * mCenterCoeff0.z); + // Dequantize box B + const AABBQuantizedNode* N1 = tree1->GetNodes(); + const Point b(float(N1->mAABB.mExtents[0]) * mExtentsCoeff1.x, float(N1->mAABB.mExtents[1]) * mExtentsCoeff1.y, float(N1->mAABB.mExtents[2]) * mExtentsCoeff1.z); + const Point Pb(float(N1->mAABB.mCenter[0]) * mCenterCoeff1.x, float(N1->mAABB.mCenter[1]) * mCenterCoeff1.y, float(N1->mAABB.mCenter[2]) * mCenterCoeff1.z); + + // Perform collision query + _Collide(N0, N1, a, Pa, b, Pb); + + UPDATE_CACHE + + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Collision query for quantized no-leaf AABB trees. + * \param tree0 [in] AABB tree from first object + * \param tree1 [in] AABB tree from second object + * \param world0 [in] world matrix for first object + * \param world1 [in] world matrix for second object + * \param cache [in/out] cache for a pair of previously colliding primitives + * \return true if success + * \warning SCALE NOT SUPPORTED. The matrices must contain rotation & translation parts only. + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +bool AABBTreeCollider::Collide(const AABBQuantizedNoLeafTree* tree0, const AABBQuantizedNoLeafTree* tree1, const Matrix4x4* world0, const Matrix4x4* world1, Pair* cache) +{ + // Init collision query + InitQuery(world0, world1); + + // Check previous state + if(CheckTemporalCoherence(cache)) return true; + + // Setup dequantization coeffs + mCenterCoeff0 = tree0->mCenterCoeff; + mExtentsCoeff0 = tree0->mExtentsCoeff; + mCenterCoeff1 = tree1->mCenterCoeff; + mExtentsCoeff1 = tree1->mExtentsCoeff; + + // Perform collision query + _Collide(tree0->GetNodes(), tree1->GetNodes()); + + UPDATE_CACHE + + return true; +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Standard trees +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +// The normal AABB tree can use 2 different descent rules (with different performances) +//#define ORIGINAL_CODE //!< UNC-like descent rules +#define ALTERNATIVE_CODE //!< Alternative descent rules + +#ifdef ORIGINAL_CODE +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for normal AABB trees. + * \param b0 [in] collision node from first tree + * \param b1 [in] collision node from second tree + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBTreeCollider::_Collide(const AABBCollisionNode* b0, const AABBCollisionNode* b1) +{ + // Perform BV-BV overlap test + if(!BoxBoxOverlap(b0->mAABB.mExtents, b0->mAABB.mCenter, b1->mAABB.mExtents, b1->mAABB.mCenter)) return; + + if(b0->IsLeaf() && b1->IsLeaf()) { PrimTest(b0->GetPrimitive(), b1->GetPrimitive()); return; } + + if(b1->IsLeaf() || (!b0->IsLeaf() && (b0->GetSize() > b1->GetSize()))) + { + _Collide(b0->GetNeg(), b1); + if(ContactFound()) return; + _Collide(b0->GetPos(), b1); + } + else + { + _Collide(b0, b1->GetNeg()); + if(ContactFound()) return; + _Collide(b0, b1->GetPos()); + } +} +#endif + +#ifdef ALTERNATIVE_CODE +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for normal AABB trees. + * \param b0 [in] collision node from first tree + * \param b1 [in] collision node from second tree + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBTreeCollider::_Collide(const AABBCollisionNode* b0, const AABBCollisionNode* b1) +{ + // Perform BV-BV overlap test + if(!BoxBoxOverlap(b0->mAABB.mExtents, b0->mAABB.mCenter, b1->mAABB.mExtents, b1->mAABB.mCenter)) + { + return; + } + + if(b0->IsLeaf()) + { + if(b1->IsLeaf()) + { + PrimTest(b0->GetPrimitive(), b1->GetPrimitive()); + } + else + { + _Collide(b0, b1->GetNeg()); + if(ContactFound()) return; + _Collide(b0, b1->GetPos()); + } + } + else if(b1->IsLeaf()) + { + _Collide(b0->GetNeg(), b1); + if(ContactFound()) return; + _Collide(b0->GetPos(), b1); + } + else + { + _Collide(b0->GetNeg(), b1->GetNeg()); + if(ContactFound()) return; + _Collide(b0->GetNeg(), b1->GetPos()); + if(ContactFound()) return; + _Collide(b0->GetPos(), b1->GetNeg()); + if(ContactFound()) return; + _Collide(b0->GetPos(), b1->GetPos()); + } +} +#endif + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// No-leaf trees +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Leaf-leaf test for two primitive indices. + * \param id0 [in] index from first leaf-triangle + * \param id1 [in] index from second leaf-triangle + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBTreeCollider::PrimTest(udword id0, udword id1) +{ + // Request vertices from the app + VertexPointers VP0; + VertexPointers VP1; + ConversionArea VC0; + ConversionArea VC1; + mIMesh0->GetTriangle(VP0, id0, VC0); + mIMesh1->GetTriangle(VP1, id1, VC1); + + // Transform from space 1 to space 0 + Point u0,u1,u2; + TransformPoint(u0, *VP1.Vertex[0], mR1to0, mT1to0); + TransformPoint(u1, *VP1.Vertex[1], mR1to0, mT1to0); + TransformPoint(u2, *VP1.Vertex[2], mR1to0, mT1to0); + + // Perform triangle-triangle overlap test + if(TriTriOverlap(*VP0.Vertex[0], *VP0.Vertex[1], *VP0.Vertex[2], u0, u1, u2)) + { + // Keep track of colliding pairs + mPairs.Add(id0).Add(id1); + // Set contact status + mFlags |= OPC_CONTACT; + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Leaf-leaf test for a previously fetched triangle from tree A (in B's space) and a new leaf from B. + * \param id1 [in] leaf-triangle index from tree B + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +inline_ void AABBTreeCollider::PrimTestTriIndex(udword id1) +{ + // Request vertices from the app + VertexPointers VP; + ConversionArea VC; + mIMesh1->GetTriangle(VP, id1, VC); + + // Perform triangle-triangle overlap test + if(TriTriOverlap(mLeafVerts[0], mLeafVerts[1], mLeafVerts[2], *VP.Vertex[0], *VP.Vertex[1], *VP.Vertex[2])) + { + // Keep track of colliding pairs + mPairs.Add(mLeafIndex).Add(id1); + // Set contact status + mFlags |= OPC_CONTACT; + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Leaf-leaf test for a previously fetched triangle from tree B (in A's space) and a new leaf from A. + * \param id0 [in] leaf-triangle index from tree A + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +inline_ void AABBTreeCollider::PrimTestIndexTri(udword id0) +{ + // Request vertices from the app + VertexPointers VP; + ConversionArea VC; + mIMesh0->GetTriangle(VP, id0, VC); + + // Perform triangle-triangle overlap test + if(TriTriOverlap(mLeafVerts[0], mLeafVerts[1], mLeafVerts[2], *VP.Vertex[0], *VP.Vertex[1], *VP.Vertex[2])) + { + // Keep track of colliding pairs + mPairs.Add(id0).Add(mLeafIndex); + // Set contact status + mFlags |= OPC_CONTACT; + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision of a leaf node from A and a branch from B. + * \param b [in] collision node from second tree + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBTreeCollider::_CollideTriBox(const AABBNoLeafNode* b) +{ + // Perform triangle-box overlap test + if(!TriBoxOverlap(b->mAABB.mCenter, b->mAABB.mExtents)) return; + + // Keep same triangle, deal with first child + if(b->HasPosLeaf()) PrimTestTriIndex(b->GetPosPrimitive()); + else _CollideTriBox(b->GetPos()); + + if(ContactFound()) return; + + // Keep same triangle, deal with second child + if(b->HasNegLeaf()) PrimTestTriIndex(b->GetNegPrimitive()); + else _CollideTriBox(b->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision of a leaf node from B and a branch from A. + * \param b [in] collision node from first tree + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBTreeCollider::_CollideBoxTri(const AABBNoLeafNode* b) +{ + // Perform triangle-box overlap test + if(!TriBoxOverlap(b->mAABB.mCenter, b->mAABB.mExtents)) return; + + // Keep same triangle, deal with first child + if(b->HasPosLeaf()) PrimTestIndexTri(b->GetPosPrimitive()); + else _CollideBoxTri(b->GetPos()); + + if(ContactFound()) return; + + // Keep same triangle, deal with second child + if(b->HasNegLeaf()) PrimTestIndexTri(b->GetNegPrimitive()); + else _CollideBoxTri(b->GetNeg()); +} + +//! Request triangle vertices from the app and transform them +#define FETCH_LEAF(prim_index, imesh, rot, trans) \ + mLeafIndex = prim_index; \ + /* Request vertices from the app */ \ + VertexPointers VP; ConversionArea VC; imesh->GetTriangle(VP, prim_index, VC); \ + /* Transform them in a common space */ \ + TransformPoint(mLeafVerts[0], *VP.Vertex[0], rot, trans); \ + TransformPoint(mLeafVerts[1], *VP.Vertex[1], rot, trans); \ + TransformPoint(mLeafVerts[2], *VP.Vertex[2], rot, trans); + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for no-leaf AABB trees. + * \param a [in] collision node from first tree + * \param b [in] collision node from second tree + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBTreeCollider::_Collide(const AABBNoLeafNode* a, const AABBNoLeafNode* b) +{ + // Perform BV-BV overlap test + if(!BoxBoxOverlap(a->mAABB.mExtents, a->mAABB.mCenter, b->mAABB.mExtents, b->mAABB.mCenter)) return; + + // Catch leaf status + BOOL BHasPosLeaf = b->HasPosLeaf(); + BOOL BHasNegLeaf = b->HasNegLeaf(); + + if(a->HasPosLeaf()) + { + FETCH_LEAF(a->GetPosPrimitive(), mIMesh0, mR0to1, mT0to1) + + if(BHasPosLeaf) PrimTestTriIndex(b->GetPosPrimitive()); + else _CollideTriBox(b->GetPos()); + + if(ContactFound()) return; + + if(BHasNegLeaf) PrimTestTriIndex(b->GetNegPrimitive()); + else _CollideTriBox(b->GetNeg()); + } + else + { + if(BHasPosLeaf) + { + FETCH_LEAF(b->GetPosPrimitive(), mIMesh1, mR1to0, mT1to0) + + _CollideBoxTri(a->GetPos()); + } + else _Collide(a->GetPos(), b->GetPos()); + + if(ContactFound()) return; + + if(BHasNegLeaf) + { + FETCH_LEAF(b->GetNegPrimitive(), mIMesh1, mR1to0, mT1to0) + + _CollideBoxTri(a->GetPos()); + } + else _Collide(a->GetPos(), b->GetNeg()); + } + + if(ContactFound()) return; + + if(a->HasNegLeaf()) + { + FETCH_LEAF(a->GetNegPrimitive(), mIMesh0, mR0to1, mT0to1) + + if(BHasPosLeaf) PrimTestTriIndex(b->GetPosPrimitive()); + else _CollideTriBox(b->GetPos()); + + if(ContactFound()) return; + + if(BHasNegLeaf) PrimTestTriIndex(b->GetNegPrimitive()); + else _CollideTriBox(b->GetNeg()); + } + else + { + if(BHasPosLeaf) + { + // ### That leaf has possibly already been fetched + FETCH_LEAF(b->GetPosPrimitive(), mIMesh1, mR1to0, mT1to0) + + _CollideBoxTri(a->GetNeg()); + } + else _Collide(a->GetNeg(), b->GetPos()); + + if(ContactFound()) return; + + if(BHasNegLeaf) + { + // ### That leaf has possibly already been fetched + FETCH_LEAF(b->GetNegPrimitive(), mIMesh1, mR1to0, mT1to0) + + _CollideBoxTri(a->GetNeg()); + } + else _Collide(a->GetNeg(), b->GetNeg()); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Quantized trees +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized AABB trees. + * \param b0 [in] collision node from first tree + * \param b1 [in] collision node from second tree + * \param a [in] extent from box A + * \param Pa [in] center from box A + * \param b [in] extent from box B + * \param Pb [in] center from box B + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBTreeCollider::_Collide(const AABBQuantizedNode* b0, const AABBQuantizedNode* b1, const Point& a, const Point& Pa, const Point& b, const Point& Pb) +{ + // Perform BV-BV overlap test + if(!BoxBoxOverlap(a, Pa, b, Pb)) return; + + if(b0->IsLeaf() && b1->IsLeaf()) { PrimTest(b0->GetPrimitive(), b1->GetPrimitive()); return; } + + if(b1->IsLeaf() || (!b0->IsLeaf() && (b0->GetSize() > b1->GetSize()))) + { + // Dequantize box + const QuantizedAABB* Box = &b0->GetNeg()->mAABB; + const Point negPa(float(Box->mCenter[0]) * mCenterCoeff0.x, float(Box->mCenter[1]) * mCenterCoeff0.y, float(Box->mCenter[2]) * mCenterCoeff0.z); + const Point nega(float(Box->mExtents[0]) * mExtentsCoeff0.x, float(Box->mExtents[1]) * mExtentsCoeff0.y, float(Box->mExtents[2]) * mExtentsCoeff0.z); + _Collide(b0->GetNeg(), b1, nega, negPa, b, Pb); + + if(ContactFound()) return; + + // Dequantize box + Box = &b0->GetPos()->mAABB; + const Point posPa(float(Box->mCenter[0]) * mCenterCoeff0.x, float(Box->mCenter[1]) * mCenterCoeff0.y, float(Box->mCenter[2]) * mCenterCoeff0.z); + const Point posa(float(Box->mExtents[0]) * mExtentsCoeff0.x, float(Box->mExtents[1]) * mExtentsCoeff0.y, float(Box->mExtents[2]) * mExtentsCoeff0.z); + _Collide(b0->GetPos(), b1, posa, posPa, b, Pb); + } + else + { + // Dequantize box + const QuantizedAABB* Box = &b1->GetNeg()->mAABB; + const Point negPb(float(Box->mCenter[0]) * mCenterCoeff1.x, float(Box->mCenter[1]) * mCenterCoeff1.y, float(Box->mCenter[2]) * mCenterCoeff1.z); + const Point negb(float(Box->mExtents[0]) * mExtentsCoeff1.x, float(Box->mExtents[1]) * mExtentsCoeff1.y, float(Box->mExtents[2]) * mExtentsCoeff1.z); + _Collide(b0, b1->GetNeg(), a, Pa, negb, negPb); + + if(ContactFound()) return; + + // Dequantize box + Box = &b1->GetPos()->mAABB; + const Point posPb(float(Box->mCenter[0]) * mCenterCoeff1.x, float(Box->mCenter[1]) * mCenterCoeff1.y, float(Box->mCenter[2]) * mCenterCoeff1.z); + const Point posb(float(Box->mExtents[0]) * mExtentsCoeff1.x, float(Box->mExtents[1]) * mExtentsCoeff1.y, float(Box->mExtents[2]) * mExtentsCoeff1.z); + _Collide(b0, b1->GetPos(), a, Pa, posb, posPb); + } +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Quantized no-leaf trees +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision of a leaf node from A and a quantized branch from B. + * \param leaf [in] leaf triangle from first tree + * \param b [in] collision node from second tree + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBTreeCollider::_CollideTriBox(const AABBQuantizedNoLeafNode* b) +{ + // Dequantize box + const QuantizedAABB* bb = &b->mAABB; + const Point Pb(float(bb->mCenter[0]) * mCenterCoeff1.x, float(bb->mCenter[1]) * mCenterCoeff1.y, float(bb->mCenter[2]) * mCenterCoeff1.z); + const Point eb(float(bb->mExtents[0]) * mExtentsCoeff1.x, float(bb->mExtents[1]) * mExtentsCoeff1.y, float(bb->mExtents[2]) * mExtentsCoeff1.z); + + // Perform triangle-box overlap test + if(!TriBoxOverlap(Pb, eb)) return; + + if(b->HasPosLeaf()) PrimTestTriIndex(b->GetPosPrimitive()); + else _CollideTriBox(b->GetPos()); + + if(ContactFound()) return; + + if(b->HasNegLeaf()) PrimTestTriIndex(b->GetNegPrimitive()); + else _CollideTriBox(b->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision of a leaf node from B and a quantized branch from A. + * \param b [in] collision node from first tree + * \param leaf [in] leaf triangle from second tree + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBTreeCollider::_CollideBoxTri(const AABBQuantizedNoLeafNode* b) +{ + // Dequantize box + const QuantizedAABB* bb = &b->mAABB; + const Point Pa(float(bb->mCenter[0]) * mCenterCoeff0.x, float(bb->mCenter[1]) * mCenterCoeff0.y, float(bb->mCenter[2]) * mCenterCoeff0.z); + const Point ea(float(bb->mExtents[0]) * mExtentsCoeff0.x, float(bb->mExtents[1]) * mExtentsCoeff0.y, float(bb->mExtents[2]) * mExtentsCoeff0.z); + + // Perform triangle-box overlap test + if(!TriBoxOverlap(Pa, ea)) return; + + if(b->HasPosLeaf()) PrimTestIndexTri(b->GetPosPrimitive()); + else _CollideBoxTri(b->GetPos()); + + if(ContactFound()) return; + + if(b->HasNegLeaf()) PrimTestIndexTri(b->GetNegPrimitive()); + else _CollideBoxTri(b->GetNeg()); +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Recursive collision query for quantized no-leaf AABB trees. + * \param a [in] collision node from first tree + * \param b [in] collision node from second tree + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +void AABBTreeCollider::_Collide(const AABBQuantizedNoLeafNode* a, const AABBQuantizedNoLeafNode* b) +{ + // Dequantize box A + const QuantizedAABB* ab = &a->mAABB; + const Point Pa(float(ab->mCenter[0]) * mCenterCoeff0.x, float(ab->mCenter[1]) * mCenterCoeff0.y, float(ab->mCenter[2]) * mCenterCoeff0.z); + const Point ea(float(ab->mExtents[0]) * mExtentsCoeff0.x, float(ab->mExtents[1]) * mExtentsCoeff0.y, float(ab->mExtents[2]) * mExtentsCoeff0.z); + // Dequantize box B + const QuantizedAABB* bb = &b->mAABB; + const Point Pb(float(bb->mCenter[0]) * mCenterCoeff1.x, float(bb->mCenter[1]) * mCenterCoeff1.y, float(bb->mCenter[2]) * mCenterCoeff1.z); + const Point eb(float(bb->mExtents[0]) * mExtentsCoeff1.x, float(bb->mExtents[1]) * mExtentsCoeff1.y, float(bb->mExtents[2]) * mExtentsCoeff1.z); + + // Perform BV-BV overlap test + if(!BoxBoxOverlap(ea, Pa, eb, Pb)) return; + + // Catch leaf status + BOOL BHasPosLeaf = b->HasPosLeaf(); + BOOL BHasNegLeaf = b->HasNegLeaf(); + + if(a->HasPosLeaf()) + { + FETCH_LEAF(a->GetPosPrimitive(), mIMesh0, mR0to1, mT0to1) + + if(BHasPosLeaf) PrimTestTriIndex(b->GetPosPrimitive()); + else _CollideTriBox(b->GetPos()); + + if(ContactFound()) return; + + if(BHasNegLeaf) PrimTestTriIndex(b->GetNegPrimitive()); + else _CollideTriBox(b->GetNeg()); + } + else + { + if(BHasPosLeaf) + { + FETCH_LEAF(b->GetPosPrimitive(), mIMesh1, mR1to0, mT1to0) + + _CollideBoxTri(a->GetPos()); + } + else _Collide(a->GetPos(), b->GetPos()); + + if(ContactFound()) return; + + if(BHasNegLeaf) + { + FETCH_LEAF(b->GetNegPrimitive(), mIMesh1, mR1to0, mT1to0) + + _CollideBoxTri(a->GetPos()); + } + else _Collide(a->GetPos(), b->GetNeg()); + } + + if(ContactFound()) return; + + if(a->HasNegLeaf()) + { + FETCH_LEAF(a->GetNegPrimitive(), mIMesh0, mR0to1, mT0to1) + + if(BHasPosLeaf) PrimTestTriIndex(b->GetPosPrimitive()); + else _CollideTriBox(b->GetPos()); + + if(ContactFound()) return; + + if(BHasNegLeaf) PrimTestTriIndex(b->GetNegPrimitive()); + else _CollideTriBox(b->GetNeg()); + } + else + { + if(BHasPosLeaf) + { + // ### That leaf has possibly already been fetched + FETCH_LEAF(b->GetPosPrimitive(), mIMesh1, mR1to0, mT1to0) + + _CollideBoxTri(a->GetNeg()); + } + else _Collide(a->GetNeg(), b->GetPos()); + + if(ContactFound()) return; + + if(BHasNegLeaf) + { + // ### That leaf has possibly already been fetched + FETCH_LEAF(b->GetNegPrimitive(), mIMesh1, mR1to0, mT1to0) + + _CollideBoxTri(a->GetNeg()); + } + else _Collide(a->GetNeg(), b->GetNeg()); + } +} diff --git a/libs/ode-0.16.1/OPCODE/OPC_TreeCollider.h b/libs/ode-0.16.1/OPCODE/OPC_TreeCollider.h new file mode 100644 index 0000000..1e943a4 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_TreeCollider.h @@ -0,0 +1,246 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains code for a tree collider. + * \file OPC_TreeCollider.h + * \author Pierre Terdiman + * \date March, 20, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __OPC_TREECOLLIDER_H__ +#define __OPC_TREECOLLIDER_H__ + + //! This structure holds cached information used by the algorithm. + //! Two model pointers and two colliding primitives are cached. Model pointers are assigned + //! to their respective meshes, and the pair of colliding primitives is used for temporal + //! coherence. That is, in case temporal coherence is enabled, those two primitives are + //! tested for overlap before everything else. If they still collide, we're done before + //! even entering the recursive collision code. + struct OPCODE_API BVTCache : Pair + { + //! Constructor + inline_ BVTCache() + { + ResetCache(); + ResetCountDown(); + } + + void ResetCache() + { + Model0 = null; + Model1 = null; + id0 = 0; + id1 = 1; +#ifdef __MESHMERIZER_H__ // Collision hulls only supported within ICE ! + HullTest = true; + SepVector.pid = 0; + SepVector.qid = 0; + SepVector.SV = Point(1.0f, 0.0f, 0.0f); +#endif // __MESHMERIZER_H__ + } + +#ifdef __MESHMERIZER_H__ // Collision hulls only supported within ICE ! + inline_ void ResetCountDown() + { + CountDown = 50; + } +#else + void ResetCountDown(){}; +#endif // __MESHMERIZER_H__ + + const Model* Model0; //!< Model for first object + const Model* Model1; //!< Model for second object + +#ifdef __MESHMERIZER_H__ // Collision hulls only supported within ICE ! + SVCache SepVector; + udword CountDown; + bool HullTest; +#endif // __MESHMERIZER_H__ + }; + + class OPCODE_API AABBTreeCollider : public Collider + { + public: + // Constructor / Destructor + AABBTreeCollider(); + virtual ~AABBTreeCollider(); + // Generic collision query + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Generic collision query for generic OPCODE models. After the call, access the results with: + * - GetContactStatus() + * - GetNbPairs() + * - GetPairs() + * + * \param cache [in] collision cache for model pointers and a colliding pair of primitives + * \param world0 [in] world matrix for first object, or null + * \param world1 [in] world matrix for second object, or null + * \return true if success + * \warning SCALE NOT SUPPORTED. The matrices must contain rotation & translation parts only. + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + bool Collide(BVTCache& cache, const Matrix4x4* world0=null, const Matrix4x4* world1=null); + + // Collision queries + bool Collide(const AABBCollisionTree* tree0, const AABBCollisionTree* tree1, const Matrix4x4* world0=null, const Matrix4x4* world1=null, Pair* cache=null); + bool Collide(const AABBNoLeafTree* tree0, const AABBNoLeafTree* tree1, const Matrix4x4* world0=null, const Matrix4x4* world1=null, Pair* cache=null); + bool Collide(const AABBQuantizedTree* tree0, const AABBQuantizedTree* tree1, const Matrix4x4* world0=null, const Matrix4x4* world1=null, Pair* cache=null); + bool Collide(const AABBQuantizedNoLeafTree* tree0, const AABBQuantizedNoLeafTree* tree1, const Matrix4x4* world0=null, const Matrix4x4* world1=null, Pair* cache=null); + // Settings + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Settings: selects between full box-box tests or "SAT-lite" tests (where Class III axes are discarded) + * \param flag [in] true for full tests, false for coarse tests + * \see SetFullPrimBoxTest(bool flag) + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void SetFullBoxBoxTest(bool flag) { mFullBoxBoxTest = flag; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Settings: selects between full triangle-box tests or "SAT-lite" tests (where Class III axes are discarded) + * \param flag [in] true for full tests, false for coarse tests + * \see SetFullBoxBoxTest(bool flag) + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ void SetFullPrimBoxTest(bool flag) { mFullPrimBoxTest = flag; } + + // Stats + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Stats: gets the number of BV-BV overlap tests after a collision query. + * \see GetNbPrimPrimTests() + * \see GetNbBVPrimTests() + * \return the number of BV-BV tests performed during last query + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ udword GetNbBVBVTests() const { return mNbBVBVTests; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Stats: gets the number of Triangle-Triangle overlap tests after a collision query. + * \see GetNbBVBVTests() + * \see GetNbBVPrimTests() + * \return the number of Triangle-Triangle tests performed during last query + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ udword GetNbPrimPrimTests() const { return mNbPrimPrimTests; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Stats: gets the number of BV-Triangle overlap tests after a collision query. + * \see GetNbBVBVTests() + * \see GetNbPrimPrimTests() + * \return the number of BV-Triangle tests performed during last query + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ udword GetNbBVPrimTests() const { return mNbBVPrimTests; } + + // Data access + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets the number of contacts after a collision query. + * \see GetContactStatus() + * \see GetPairs() + * \return the number of contacts / colliding pairs. + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ udword GetNbPairs() const { return mPairs.GetNbEntries()>>1; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets the pairs of colliding triangles after a collision query. + * \see GetContactStatus() + * \see GetNbPairs() + * \return the list of colliding pairs (triangle indices) + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ const Pair* GetPairs() const { return (const Pair*)mPairs.GetEntries(); } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Validates current settings. You should call this method after all the settings and callbacks have been defined for a collider. + * \return null if everything is ok, else a string describing the problem + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + override(Collider) const char* ValidateSettings(); + + protected: + // Colliding pairs + Container mPairs; //!< Pairs of colliding primitives + // User mesh interfaces + const MeshInterface* mIMesh0; //!< User-defined mesh interface for object0 + const MeshInterface* mIMesh1; //!< User-defined mesh interface for object1 + // Stats + udword mNbBVBVTests; //!< Number of BV-BV tests + udword mNbPrimPrimTests; //!< Number of Primitive-Primitive tests + udword mNbBVPrimTests; //!< Number of BV-Primitive tests + // Precomputed data + Matrix3x3 mAR; //!< Absolute rotation matrix + Matrix3x3 mR0to1; //!< Rotation from object0 to object1 + Matrix3x3 mR1to0; //!< Rotation from object1 to object0 + Point mT0to1; //!< Translation from object0 to object1 + Point mT1to0; //!< Translation from object1 to object0 + // Dequantization coeffs + Point mCenterCoeff0; + Point mExtentsCoeff0; + Point mCenterCoeff1; + Point mExtentsCoeff1; + // Leaf description + Point mLeafVerts[3]; //!< Triangle vertices + udword mLeafIndex; //!< Triangle index + // Settings + bool mFullBoxBoxTest; //!< Perform full BV-BV tests (true) or SAT-lite tests (false) + bool mFullPrimBoxTest; //!< Perform full Primitive-BV tests (true) or SAT-lite tests (false) + // Internal methods + + // Standard AABB trees + void _Collide(const AABBCollisionNode* b0, const AABBCollisionNode* b1); + // Quantized AABB trees + void _Collide(const AABBQuantizedNode* b0, const AABBQuantizedNode* b1, const Point& a, const Point& Pa, const Point& b, const Point& Pb); + // No-leaf AABB trees + void _CollideTriBox(const AABBNoLeafNode* b); + void _CollideBoxTri(const AABBNoLeafNode* b); + void _Collide(const AABBNoLeafNode* a, const AABBNoLeafNode* b); + // Quantized no-leaf AABB trees + void _CollideTriBox(const AABBQuantizedNoLeafNode* b); + void _CollideBoxTri(const AABBQuantizedNoLeafNode* b); + void _Collide(const AABBQuantizedNoLeafNode* a, const AABBQuantizedNoLeafNode* b); + // Overlap tests + void PrimTest(udword id0, udword id1); + inline_ void PrimTestTriIndex(udword id1); + inline_ void PrimTestIndexTri(udword id0); + + inline_ BOOL BoxBoxOverlap(const Point& ea, const Point& ca, const Point& eb, const Point& cb); + inline_ BOOL TriBoxOverlap(const Point& center, const Point& extents); + inline_ BOOL TriTriOverlap(const Point& V0, const Point& V1, const Point& V2, const Point& U0, const Point& U1, const Point& U2); + // Init methods + void InitQuery(const Matrix4x4* world0=null, const Matrix4x4* world1=null); + bool CheckTemporalCoherence(Pair* cache); + + inline_ BOOL Setup(const MeshInterface* mi0, const MeshInterface* mi1) + { + mIMesh0 = mi0; + mIMesh1 = mi1; + + if(!mIMesh0 || !mIMesh1) return FALSE; + + return TRUE; + } + }; + +#endif // __OPC_TREECOLLIDER_H__ diff --git a/libs/ode-0.16.1/OPCODE/OPC_TriBoxOverlap.h b/libs/ode-0.16.1/OPCODE/OPC_TriBoxOverlap.h new file mode 100644 index 0000000..b3a9bde --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_TriBoxOverlap.h @@ -0,0 +1,339 @@ + +//! This macro quickly finds the min & max values among 3 variables +#define FINDMINMAX(x0, x1, x2, min, max) \ + min = max = x0; \ + if(x1max) max=x1; \ + if(x2max) max=x2; + +//! TO BE DOCUMENTED +inline_ BOOL planeBoxOverlap(const Point& normal, const float d, const Point& maxbox) +{ + Point vmin, vmax; + for(udword q=0;q<=2;q++) + { + if(normal[q]>0.0f) { vmin[q]=-maxbox[q]; vmax[q]=maxbox[q]; } + else { vmin[q]=maxbox[q]; vmax[q]=-maxbox[q]; } + } + if((normal|vmin)+d>0.0f) return FALSE; + if((normal|vmax)+d>=0.0f) return TRUE; + + return FALSE; +} + +//! TO BE DOCUMENTED +#define AXISTEST_X01(a, b, fa, fb) \ + min = a*v0.y - b*v0.z; \ + max = a*v2.y - b*v2.z; \ + if(min>max) {const float tmp=max; max=min; min=tmp; } \ + rad = fa * extents.y + fb * extents.z; \ + if(min>rad || max<-rad) return FALSE; + +//! TO BE DOCUMENTED +#define AXISTEST_X2(a, b, fa, fb) \ + min = a*v0.y - b*v0.z; \ + max = a*v1.y - b*v1.z; \ + if(min>max) {const float tmp=max; max=min; min=tmp; } \ + rad = fa * extents.y + fb * extents.z; \ + if(min>rad || max<-rad) return FALSE; + +//! TO BE DOCUMENTED +#define AXISTEST_Y02(a, b, fa, fb) \ + min = b*v0.z - a*v0.x; \ + max = b*v2.z - a*v2.x; \ + if(min>max) {const float tmp=max; max=min; min=tmp; } \ + rad = fa * extents.x + fb * extents.z; \ + if(min>rad || max<-rad) return FALSE; + +//! TO BE DOCUMENTED +#define AXISTEST_Y1(a, b, fa, fb) \ + min = b*v0.z - a*v0.x; \ + max = b*v1.z - a*v1.x; \ + if(min>max) {const float tmp=max; max=min; min=tmp; } \ + rad = fa * extents.x + fb * extents.z; \ + if(min>rad || max<-rad) return FALSE; + +//! TO BE DOCUMENTED +#define AXISTEST_Z12(a, b, fa, fb) \ + min = a*v1.x - b*v1.y; \ + max = a*v2.x - b*v2.y; \ + if(min>max) {const float tmp=max; max=min; min=tmp; } \ + rad = fa * extents.x + fb * extents.y; \ + if(min>rad || max<-rad) return FALSE; + +//! TO BE DOCUMENTED +#define AXISTEST_Z0(a, b, fa, fb) \ + min = a*v0.x - b*v0.y; \ + max = a*v1.x - b*v1.y; \ + if(min>max) {const float tmp=max; max=min; min=tmp; } \ + rad = fa * extents.x + fb * extents.y; \ + if(min>rad || max<-rad) return FALSE; + +// compute triangle edges +// - edges lazy evaluated to take advantage of early exits +// - fabs precomputed (half less work, possible since extents are always >0) +// - customized macros to take advantage of the null component +// - axis vector discarded, possibly saves useless movs +#define IMPLEMENT_CLASS3_TESTS \ + float rad; \ + float min, max; \ + \ + const float fey0 = fabsf(e0.y); \ + const float fez0 = fabsf(e0.z); \ + AXISTEST_X01(e0.z, e0.y, fez0, fey0); \ + const float fex0 = fabsf(e0.x); \ + AXISTEST_Y02(e0.z, e0.x, fez0, fex0); \ + AXISTEST_Z12(e0.y, e0.x, fey0, fex0); \ + \ + const float fey1 = fabsf(e1.y); \ + const float fez1 = fabsf(e1.z); \ + AXISTEST_X01(e1.z, e1.y, fez1, fey1); \ + const float fex1 = fabsf(e1.x); \ + AXISTEST_Y02(e1.z, e1.x, fez1, fex1); \ + AXISTEST_Z0(e1.y, e1.x, fey1, fex1); \ + \ + const Point e2 = mLeafVerts[0] - mLeafVerts[2]; \ + const float fey2 = fabsf(e2.y); \ + const float fez2 = fabsf(e2.z); \ + AXISTEST_X2(e2.z, e2.y, fez2, fey2); \ + const float fex2 = fabsf(e2.x); \ + AXISTEST_Y1(e2.z, e2.x, fez2, fex2); \ + AXISTEST_Z12(e2.y, e2.x, fey2, fex2); + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Triangle-Box overlap test using the separating axis theorem. + * This is the code from Tomas Möller, a bit optimized: + * - with some more lazy evaluation (faster path on PC) + * - with a tiny bit of assembly + * - with "SAT-lite" applied if needed + * - and perhaps with some more minor modifs... + * + * \param center [in] box center + * \param extents [in] box extents + * \return true if triangle & box overlap + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +inline_ BOOL AABBTreeCollider::TriBoxOverlap(const Point& center, const Point& extents) +{ + // Stats + mNbBVPrimTests++; + + // use separating axis theorem to test overlap between triangle and box + // need to test for overlap in these directions: + // 1) the {x,y,z}-directions (actually, since we use the AABB of the triangle + // we do not even need to test these) + // 2) normal of the triangle + // 3) crossproduct(edge from tri, {x,y,z}-directin) + // this gives 3x3=9 more tests + + // move everything so that the boxcenter is in (0,0,0) + Point v0, v1, v2; + v0.x = mLeafVerts[0].x - center.x; + v1.x = mLeafVerts[1].x - center.x; + v2.x = mLeafVerts[2].x - center.x; + + // First, test overlap in the {x,y,z}-directions +#ifdef OPC_USE_FCOMI + // find min, max of the triangle in x-direction, and test for overlap in X + if(FCMin3(v0.x, v1.x, v2.x)>extents.x) return FALSE; + if(FCMax3(v0.x, v1.x, v2.x)<-extents.x) return FALSE; + + // same for Y + v0.y = mLeafVerts[0].y - center.y; + v1.y = mLeafVerts[1].y - center.y; + v2.y = mLeafVerts[2].y - center.y; + + if(FCMin3(v0.y, v1.y, v2.y)>extents.y) return FALSE; + if(FCMax3(v0.y, v1.y, v2.y)<-extents.y) return FALSE; + + // same for Z + v0.z = mLeafVerts[0].z - center.z; + v1.z = mLeafVerts[1].z - center.z; + v2.z = mLeafVerts[2].z - center.z; + + if(FCMin3(v0.z, v1.z, v2.z)>extents.z) return FALSE; + if(FCMax3(v0.z, v1.z, v2.z)<-extents.z) return FALSE; +#else + float min,max; + // Find min, max of the triangle in x-direction, and test for overlap in X + FINDMINMAX(v0.x, v1.x, v2.x, min, max); + if(min>extents.x || max<-extents.x) return FALSE; + + // Same for Y + v0.y = mLeafVerts[0].y - center.y; + v1.y = mLeafVerts[1].y - center.y; + v2.y = mLeafVerts[2].y - center.y; + + FINDMINMAX(v0.y, v1.y, v2.y, min, max); + if(min>extents.y || max<-extents.y) return FALSE; + + // Same for Z + v0.z = mLeafVerts[0].z - center.z; + v1.z = mLeafVerts[1].z - center.z; + v2.z = mLeafVerts[2].z - center.z; + + FINDMINMAX(v0.z, v1.z, v2.z, min, max); + if(min>extents.z || max<-extents.z) return FALSE; +#endif + // 2) Test if the box intersects the plane of the triangle + // compute plane equation of triangle: normal*x+d=0 + // ### could be precomputed since we use the same leaf triangle several times + const Point e0 = v1 - v0; + const Point e1 = v2 - v1; + const Point normal = e0 ^ e1; + const float d = -normal|v0; + if(!planeBoxOverlap(normal, d, extents)) return FALSE; + + // 3) "Class III" tests + if(mFullPrimBoxTest) + { + IMPLEMENT_CLASS3_TESTS + } + return TRUE; +} + +//! A dedicated version where the box is constant +inline_ BOOL OBBCollider::TriBoxOverlap() +{ + // Stats + mNbVolumePrimTests++; + + // Hook + const Point& extents = mBoxExtents; + const Point& v0 = mLeafVerts[0]; + const Point& v1 = mLeafVerts[1]; + const Point& v2 = mLeafVerts[2]; + + // use separating axis theorem to test overlap between triangle and box + // need to test for overlap in these directions: + // 1) the {x,y,z}-directions (actually, since we use the AABB of the triangle + // we do not even need to test these) + // 2) normal of the triangle + // 3) crossproduct(edge from tri, {x,y,z}-directin) + // this gives 3x3=9 more tests + + // Box center is already in (0,0,0) + + // First, test overlap in the {x,y,z}-directions +#ifdef OPC_USE_FCOMI + // find min, max of the triangle in x-direction, and test for overlap in X + if(FCMin3(v0.x, v1.x, v2.x)>mBoxExtents.x) return FALSE; + if(FCMax3(v0.x, v1.x, v2.x)<-mBoxExtents.x) return FALSE; + + if(FCMin3(v0.y, v1.y, v2.y)>mBoxExtents.y) return FALSE; + if(FCMax3(v0.y, v1.y, v2.y)<-mBoxExtents.y) return FALSE; + + if(FCMin3(v0.z, v1.z, v2.z)>mBoxExtents.z) return FALSE; + if(FCMax3(v0.z, v1.z, v2.z)<-mBoxExtents.z) return FALSE; +#else + float min,max; + // Find min, max of the triangle in x-direction, and test for overlap in X + FINDMINMAX(v0.x, v1.x, v2.x, min, max); + if(min>mBoxExtents.x || max<-mBoxExtents.x) return FALSE; + + FINDMINMAX(v0.y, v1.y, v2.y, min, max); + if(min>mBoxExtents.y || max<-mBoxExtents.y) return FALSE; + + FINDMINMAX(v0.z, v1.z, v2.z, min, max); + if(min>mBoxExtents.z || max<-mBoxExtents.z) return FALSE; +#endif + // 2) Test if the box intersects the plane of the triangle + // compute plane equation of triangle: normal*x+d=0 + // ### could be precomputed since we use the same leaf triangle several times + const Point e0 = v1 - v0; + const Point e1 = v2 - v1; + const Point normal = e0 ^ e1; + const float d = -normal|v0; + if(!planeBoxOverlap(normal, d, mBoxExtents)) return FALSE; + + // 3) "Class III" tests - here we always do full tests since the box is a primitive (not a BV) + { + IMPLEMENT_CLASS3_TESTS + } + return TRUE; +} + +//! ...and another one, jeez +inline_ BOOL AABBCollider::TriBoxOverlap() +{ + // Stats + mNbVolumePrimTests++; + + // Hook + const Point& center = mBox.mCenter; + const Point& extents = mBox.mExtents; + + // use separating axis theorem to test overlap between triangle and box + // need to test for overlap in these directions: + // 1) the {x,y,z}-directions (actually, since we use the AABB of the triangle + // we do not even need to test these) + // 2) normal of the triangle + // 3) crossproduct(edge from tri, {x,y,z}-directin) + // this gives 3x3=9 more tests + + // move everything so that the boxcenter is in (0,0,0) + Point v0, v1, v2; + v0.x = mLeafVerts[0].x - center.x; + v1.x = mLeafVerts[1].x - center.x; + v2.x = mLeafVerts[2].x - center.x; + + // First, test overlap in the {x,y,z}-directions +#ifdef OPC_USE_FCOMI + // find min, max of the triangle in x-direction, and test for overlap in X + if(FCMin3(v0.x, v1.x, v2.x)>extents.x) return FALSE; + if(FCMax3(v0.x, v1.x, v2.x)<-extents.x) return FALSE; + + // same for Y + v0.y = mLeafVerts[0].y - center.y; + v1.y = mLeafVerts[1].y - center.y; + v2.y = mLeafVerts[2].y - center.y; + + if(FCMin3(v0.y, v1.y, v2.y)>extents.y) return FALSE; + if(FCMax3(v0.y, v1.y, v2.y)<-extents.y) return FALSE; + + // same for Z + v0.z = mLeafVerts[0].z - center.z; + v1.z = mLeafVerts[1].z - center.z; + v2.z = mLeafVerts[2].z - center.z; + + if(FCMin3(v0.z, v1.z, v2.z)>extents.z) return FALSE; + if(FCMax3(v0.z, v1.z, v2.z)<-extents.z) return FALSE; +#else + float min,max; + // Find min, max of the triangle in x-direction, and test for overlap in X + FINDMINMAX(v0.x, v1.x, v2.x, min, max); + if(min>extents.x || max<-extents.x) return FALSE; + + // Same for Y + v0.y = mLeafVerts[0].y - center.y; + v1.y = mLeafVerts[1].y - center.y; + v2.y = mLeafVerts[2].y - center.y; + + FINDMINMAX(v0.y, v1.y, v2.y, min, max); + if(min>extents.y || max<-extents.y) return FALSE; + + // Same for Z + v0.z = mLeafVerts[0].z - center.z; + v1.z = mLeafVerts[1].z - center.z; + v2.z = mLeafVerts[2].z - center.z; + + FINDMINMAX(v0.z, v1.z, v2.z, min, max); + if(min>extents.z || max<-extents.z) return FALSE; +#endif + // 2) Test if the box intersects the plane of the triangle + // compute plane equation of triangle: normal*x+d=0 + // ### could be precomputed since we use the same leaf triangle several times + const Point e0 = v1 - v0; + const Point e1 = v2 - v1; + const Point normal = e0 ^ e1; + const float d = -normal|v0; + if(!planeBoxOverlap(normal, d, extents)) return FALSE; + + // 3) "Class III" tests - here we always do full tests since the box is a primitive (not a BV) + { + IMPLEMENT_CLASS3_TESTS + } + return TRUE; +} diff --git a/libs/ode-0.16.1/OPCODE/OPC_TriTriOverlap.h b/libs/ode-0.16.1/OPCODE/OPC_TriTriOverlap.h new file mode 100644 index 0000000..fd652c9 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_TriTriOverlap.h @@ -0,0 +1,299 @@ + +//! if OPC_TRITRI_EPSILON_TEST is true then we do a check (if |dv|b) \ + { \ + const float c=a; \ + a=b; \ + b=c; \ + } + +//! Edge to edge test based on Franlin Antonio's gem: "Faster Line Segment Intersection", in Graphics Gems III, pp. 199-202 +#define EDGE_EDGE_TEST(V0, U0, U1) \ + Bx = U0[i0] - U1[i0]; \ + By = U0[i1] - U1[i1]; \ + Cx = V0[i0] - U0[i0]; \ + Cy = V0[i1] - U0[i1]; \ + f = Ay*Bx - Ax*By; \ + d = By*Cx - Bx*Cy; \ + if((f>0.0f && d>=0.0f && d<=f) || (f<0.0f && d<=0.0f && d>=f)) \ + { \ + const float e=Ax*Cy - Ay*Cx; \ + if(f>0.0f) \ + { \ + if(e>=0.0f && e<=f) return TRUE; \ + } \ + else \ + { \ + if(e<=0.0f && e>=f) return TRUE; \ + } \ + } + +//! TO BE DOCUMENTED +#define EDGE_AGAINST_TRI_EDGES(V0, V1, U0, U1, U2) \ +{ \ + float Bx,By,Cx,Cy,d,f; \ + const float Ax = V1[i0] - V0[i0]; \ + const float Ay = V1[i1] - V0[i1]; \ + /* test edge U0,U1 against V0,V1 */ \ + EDGE_EDGE_TEST(V0, U0, U1); \ + /* test edge U1,U2 against V0,V1 */ \ + EDGE_EDGE_TEST(V0, U1, U2); \ + /* test edge U2,U1 against V0,V1 */ \ + EDGE_EDGE_TEST(V0, U2, U0); \ +} + +//! TO BE DOCUMENTED +#define POINT_IN_TRI(V0, U0, U1, U2) \ +{ \ + /* is T1 completly inside T2? */ \ + /* check if V0 is inside tri(U0,U1,U2) */ \ + float a = U1[i1] - U0[i1]; \ + float b = -(U1[i0] - U0[i0]); \ + float c = -a*U0[i0] - b*U0[i1]; \ + float d0 = a*V0[i0] + b*V0[i1] + c; \ + \ + a = U2[i1] - U1[i1]; \ + b = -(U2[i0] - U1[i0]); \ + c = -a*U1[i0] - b*U1[i1]; \ + const float d1 = a*V0[i0] + b*V0[i1] + c; \ + \ + a = U0[i1] - U2[i1]; \ + b = -(U0[i0] - U2[i0]); \ + c = -a*U2[i0] - b*U2[i1]; \ + const float d2 = a*V0[i0] + b*V0[i1] + c; \ + if(d0*d1>0.0f) \ + { \ + if(d0*d2>0.0f) return TRUE; \ + } \ +} + +//! TO BE DOCUMENTED +BOOL CoplanarTriTri(const Point& n, const Point& v0, const Point& v1, const Point& v2, const Point& u0, const Point& u1, const Point& u2) +{ + float A[3]; + short i0,i1; + /* first project onto an axis-aligned plane, that maximizes the area */ + /* of the triangles, compute indices: i0,i1. */ + A[0] = fabsf(n[0]); + A[1] = fabsf(n[1]); + A[2] = fabsf(n[2]); + if(A[0]>A[1]) + { + if(A[0]>A[2]) + { + i0=1; /* A[0] is greatest */ + i1=2; + } + else + { + i0=0; /* A[2] is greatest */ + i1=1; + } + } + else /* A[0]<=A[1] */ + { + if(A[2]>A[1]) + { + i0=0; /* A[2] is greatest */ + i1=1; + } + else + { + i0=0; /* A[1] is greatest */ + i1=2; + } + } + + /* test all edges of triangle 1 against the edges of triangle 2 */ + EDGE_AGAINST_TRI_EDGES(v0, v1, u0, u1, u2); + EDGE_AGAINST_TRI_EDGES(v1, v2, u0, u1, u2); + EDGE_AGAINST_TRI_EDGES(v2, v0, u0, u1, u2); + + /* finally, test if tri1 is totally contained in tri2 or vice versa */ + POINT_IN_TRI(v0, u0, u1, u2); + POINT_IN_TRI(u0, v0, v1, v2); + + return FALSE; +} + +//! TO BE DOCUMENTED +#define NEWCOMPUTE_INTERVALS(VV0, VV1, VV2, D0, D1, D2, D0D1, D0D2, A, B, C, X0, X1) \ +{ \ + if(D0D1>0.0f) \ + { \ + /* here we know that D0D2<=0.0 */ \ + /* that is D0, D1 are on the same side, D2 on the other or on the plane */ \ + A=VV2; B=(VV0 - VV2)*D2; C=(VV1 - VV2)*D2; X0=D2 - D0; X1=D2 - D1; \ + } \ + else if(D0D2>0.0f) \ + { \ + /* here we know that d0d1<=0.0 */ \ + A=VV1; B=(VV0 - VV1)*D1; C=(VV2 - VV1)*D1; X0=D1 - D0; X1=D1 - D2; \ + } \ + else if(D1*D2>0.0f || D0!=0.0f) \ + { \ + /* here we know that d0d1<=0.0 or that D0!=0.0 */ \ + A=VV0; B=(VV1 - VV0)*D0; C=(VV2 - VV0)*D0; X0=D0 - D1; X1=D0 - D2; \ + } \ + else if(D1!=0.0f) \ + { \ + A=VV1; B=(VV0 - VV1)*D1; C=(VV2 - VV1)*D1; X0=D1 - D0; X1=D1 - D2; \ + } \ + else if(D2!=0.0f) \ + { \ + A=VV2; B=(VV0 - VV2)*D2; C=(VV1 - VV2)*D2; X0=D2 - D0; X1=D2 - D1; \ + } \ + else \ + { \ + /* triangles are coplanar */ \ + return CoplanarTriTri(N1, V0, V1, V2, U0, U1, U2); \ + } \ +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Triangle/triangle intersection test routine, + * by Tomas Moller, 1997. + * See article "A Fast Triangle-Triangle Intersection Test", + * Journal of Graphics Tools, 2(2), 1997 + * + * Updated June 1999: removed the divisions -- a little faster now! + * Updated October 1999: added {} to CROSS and SUB macros + * + * int NoDivTriTriIsect(float V0[3],float V1[3],float V2[3], + * float U0[3],float U1[3],float U2[3]) + * + * \param V0 [in] triangle 0, vertex 0 + * \param V1 [in] triangle 0, vertex 1 + * \param V2 [in] triangle 0, vertex 2 + * \param U0 [in] triangle 1, vertex 0 + * \param U1 [in] triangle 1, vertex 1 + * \param U2 [in] triangle 1, vertex 2 + * \return true if triangles overlap + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +inline_ BOOL AABBTreeCollider::TriTriOverlap(const Point& V0, const Point& V1, const Point& V2, const Point& U0, const Point& U1, const Point& U2) +{ + // Stats + mNbPrimPrimTests++; + + // Compute plane equation of triangle(V0,V1,V2) + Point E1 = V1 - V0; + Point E2 = V2 - V0; + const Point N1 = E1 ^ E2; + const float d1 =-N1 | V0; + // Plane equation 1: N1.X+d1=0 + + // Put U0,U1,U2 into plane equation 1 to compute signed distances to the plane + float du0 = (N1|U0) + d1; + float du1 = (N1|U1) + d1; + float du2 = (N1|U2) + d1; + + // Coplanarity robustness check +#ifdef OPC_TRITRI_EPSILON_TEST + float absd1 = FastFabs(d1), sqmagN1 = N1.SquareMagnitude(); + if (absd1>=sqmagN1) + { + if(FastFabs(du0)<=LOCAL_EPSILON*absd1) du0 = 0.0f; + if(FastFabs(du1)<=LOCAL_EPSILON*absd1) du1 = 0.0f; + if(FastFabs(du2)<=LOCAL_EPSILON*absd1) du2 = 0.0f; + } + else + { + if(FastFabs(du0)<=LOCAL_EPSILON*FCMax2(absd1, FCMin2(sqmagN1, U0.SquareMagnitude()))) du0 = 0.0f; + if(FastFabs(du1)<=LOCAL_EPSILON*FCMax2(absd1, FCMin2(sqmagN1, U1.SquareMagnitude()))) du1 = 0.0f; + if(FastFabs(du2)<=LOCAL_EPSILON*FCMax2(absd1, FCMin2(sqmagN1, U2.SquareMagnitude()))) du2 = 0.0f; + } +#endif + const float du0du1 = du0 * du1; + const float du0du2 = du0 * du2; + + if(du0du1>0.0f && du0du2>0.0f) // same sign on all of them + not equal 0 ? + return FALSE; // no intersection occurs + + // Compute plane of triangle (U0,U1,U2) + E1 = U1 - U0; + E2 = U2 - U0; + const Point N2 = E1 ^ E2; + const float d2=-N2 | U0; + // plane equation 2: N2.X+d2=0 + + // put V0,V1,V2 into plane equation 2 + float dv0 = (N2|V0) + d2; + float dv1 = (N2|V1) + d2; + float dv2 = (N2|V2) + d2; + +#ifdef OPC_TRITRI_EPSILON_TEST + float absd2 = FastFabs(d2), sqmagN2 = N2.SquareMagnitude(); + if (absd2>=sqmagN2) + { + if(FastFabs(dv0)<=LOCAL_EPSILON*absd2) dv0 = 0.0f; + if(FastFabs(dv1)<=LOCAL_EPSILON*absd2) dv1 = 0.0f; + if(FastFabs(dv2)<=LOCAL_EPSILON*absd2) dv2 = 0.0f; + } + else + { + if(FastFabs(dv0)<=LOCAL_EPSILON*FCMax2(absd2, FCMin2(sqmagN2, V0.SquareMagnitude()))) dv0 = 0.0f; + if(FastFabs(dv1)<=LOCAL_EPSILON*FCMax2(absd2, FCMin2(sqmagN2, V1.SquareMagnitude()))) dv1 = 0.0f; + if(FastFabs(dv2)<=LOCAL_EPSILON*FCMax2(absd2, FCMin2(sqmagN2, V2.SquareMagnitude()))) dv2 = 0.0f; + } +#endif + + const float dv0dv1 = dv0 * dv1; + const float dv0dv2 = dv0 * dv2; + + if(dv0dv1>0.0f && dv0dv2>0.0f) // same sign on all of them + not equal 0 ? + return FALSE; // no intersection occurs + + // Compute direction of intersection line + const Point D = N1^N2; + + // Compute and index to the largest component of D + float max=fabsf(D[0]); + short index=0; + float bb=fabsf(D[1]); + float cc=fabsf(D[2]); + if(bb>max) max=bb,index=1; + if(cc>max) max=cc,index=2; + + // This is the simplified projection onto L + const float vp0 = V0[index]; + const float vp1 = V1[index]; + const float vp2 = V2[index]; + + const float up0 = U0[index]; + const float up1 = U1[index]; + const float up2 = U2[index]; + + // Compute interval for triangle 1 + float a,b,c,x0,x1; + NEWCOMPUTE_INTERVALS(vp0,vp1,vp2,dv0,dv1,dv2,dv0dv1,dv0dv2,a,b,c,x0,x1); + + // Compute interval for triangle 2 + float d,e,f,y0,y1; + NEWCOMPUTE_INTERVALS(up0,up1,up2,du0,du1,du2,du0du1,du0du2,d,e,f,y0,y1); + + const float xx=x0*x1; + const float yy=y0*y1; + const float xxyy=xx*yy; + + float isect1[2], isect2[2]; + + float tmp=a*xxyy; + isect1[0]=tmp+b*x1*yy; + isect1[1]=tmp+c*x0*yy; + + tmp=d*xxyy; + isect2[0]=tmp+e*xx*y1; + isect2[1]=tmp+f*xx*y0; + + SORT(isect1[0],isect1[1]); + SORT(isect2[0],isect2[1]); + + if(isect1[1]HasPosLeaf()) mTouchedPrimitives->Add(udword(node->GetPosPrimitive())); \ + else _Dump(node->GetPos()); \ + \ + if(ContactFound()) return; \ + \ + if(node->HasNegLeaf()) mTouchedPrimitives->Add(udword(node->GetNegPrimitive())); \ + else _Dump(node->GetNeg()); \ +} + +#define IMPLEMENT_LEAFDUMP(type) \ +void VolumeCollider::_Dump(const type* node) \ +{ \ + if(node->IsLeaf()) \ + { \ + mTouchedPrimitives->Add(udword(node->GetPrimitive())); \ + } \ + else \ + { \ + _Dump(node->GetPos()); \ + \ + if(ContactFound()) return; \ + \ + _Dump(node->GetNeg()); \ + } \ +} + +IMPLEMENT_NOLEAFDUMP(AABBNoLeafNode) +IMPLEMENT_NOLEAFDUMP(AABBQuantizedNoLeafNode) + +IMPLEMENT_LEAFDUMP(AABBCollisionNode) +IMPLEMENT_LEAFDUMP(AABBQuantizedNode) diff --git a/libs/ode-0.16.1/OPCODE/OPC_VolumeCollider.h b/libs/ode-0.16.1/OPCODE/OPC_VolumeCollider.h new file mode 100644 index 0000000..c0b812e --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/OPC_VolumeCollider.h @@ -0,0 +1,138 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Contains base volume collider class. + * \file OPC_VolumeCollider.h + * \author Pierre Terdiman + * \date June, 2, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __OPC_VOLUMECOLLIDER_H__ +#define __OPC_VOLUMECOLLIDER_H__ + + struct OPCODE_API VolumeCache + { + VolumeCache() : Model(null) {} + ~VolumeCache() {} + + Container TouchedPrimitives; //!< Indices of touched primitives + const BaseModel* Model; //!< Owner + }; + + class OPCODE_API VolumeCollider : public Collider + { + public: + // Constructor / Destructor + VolumeCollider(); + virtual ~VolumeCollider() = 0; + + // Collision report + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets the number of touched primitives after a collision query. + * \see GetContactStatus() + * \see GetTouchedPrimitives() + * \return the number of touched primitives + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ udword GetNbTouchedPrimitives() const { return mTouchedPrimitives ? mTouchedPrimitives->GetNbEntries() : 0; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Gets the list of touched primitives after a collision query. + * \see GetContactStatus() + * \see GetNbTouchedPrimitives() + * \return the list of touched primitives (primitive indices) + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ const udword* GetTouchedPrimitives() const { return mTouchedPrimitives ? mTouchedPrimitives->GetEntries() : null; } + + // Stats + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Stats: gets the number of Volume-BV overlap tests after a collision query. + * \see GetNbVolumePrimTests() + * \return the number of Volume-BV tests performed during last query + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ udword GetNbVolumeBVTests() const { return mNbVolumeBVTests; } + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Stats: gets the number of Volume-Triangle overlap tests after a collision query. + * \see GetNbVolumeBVTests() + * \return the number of Volume-Triangle tests performed during last query + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + inline_ udword GetNbVolumePrimTests() const { return mNbVolumePrimTests; } + + // Settings + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Validates current settings. You should call this method after all the settings / callbacks have been defined for a collider. + * \return null if everything is ok, else a string describing the problem + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + override(Collider) const char* ValidateSettings(); + + protected: + // Touched primitives + Container* mTouchedPrimitives; //!< List of touched primitives + + // Dequantization coeffs + Point mCenterCoeff; + Point mExtentsCoeff; + // Stats + udword mNbVolumeBVTests; //!< Number of Volume-BV tests + udword mNbVolumePrimTests; //!< Number of Volume-Primitive tests + // Internal methods + void _Dump(const AABBCollisionNode* node); + void _Dump(const AABBNoLeafNode* node); + void _Dump(const AABBQuantizedNode* node); + void _Dump(const AABBQuantizedNoLeafNode* node); + + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Initializes a query + */ + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + override(Collider) inline_ void InitQuery() + { + // Reset stats & contact status + mNbVolumeBVTests = 0; + mNbVolumePrimTests = 0; + Collider::InitQuery(); + } + + inline_ BOOL IsCacheValid(VolumeCache& cache) + { + // We're going to do a volume-vs-model query. + if(cache.Model!=mCurrentModel) + { + // Cached list was for another model so we can't keep it + // Keep track of new owner and reset cache + cache.Model = mCurrentModel; + return FALSE; + } + else + { + // Same models, no problem + return TRUE; + } + } + }; + +#endif // __OPC_VOLUMECOLLIDER_H__ diff --git a/libs/ode-0.16.1/OPCODE/Opcode.cpp b/libs/ode-0.16.1/OPCODE/Opcode.cpp new file mode 100644 index 0000000..444619a --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Opcode.cpp @@ -0,0 +1,82 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Main file for Opcode.dll. + * \file Opcode.cpp + * \author Pierre Terdiman + * \date March, 20, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/* + Finding a good name is difficult! + Here's the draft for this lib.... Spooky, uh? + + VOID? Very Optimized Interference Detection + ZOID? Zappy's Optimized Interference Detection + CID? Custom/Clever Interference Detection + AID / ACID! Accurate Interference Detection + QUID? Quick Interference Detection + RIDE? Realtime Interference DEtection + WIDE? Wicked Interference DEtection (....) + GUID! + KID ! k-dop interference detection :) + OPCODE! OPtimized COllision DEtection +*/ + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Precompiled Header +#include "Stdafx.h" + +using namespace Opcode; + + +static OPCODE_AbortHandler g_fnAbortHandler = NULL; + + +bool Opcode::InitOpcode(OPCODE_AbortHandler fnAbortHandler/*=NULL*/) +{ + //Log("// Initializing OPCODE\n\n"); +// LogAPIInfo(); + + g_fnAbortHandler = fnAbortHandler; + return true; +} + +bool Opcode::CloseOpcode() +{ + //Log("// Closing OPCODE\n\n"); + + return true; +} + + +#ifdef ICE_MAIN + +void ModuleAttach(HINSTANCE hinstance) +{ +} + +void ModuleDetach() +{ +} + +#endif + +/*extern */ +void OPCODE_NORETURN IceAbort() +{ + if (g_fnAbortHandler != NULL) + { + g_fnAbortHandler(); + } + + abort(); +} diff --git a/libs/ode-0.16.1/OPCODE/Opcode.h b/libs/ode-0.16.1/OPCODE/Opcode.h new file mode 100644 index 0000000..4a98e36 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Opcode.h @@ -0,0 +1,126 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/** + * Main file for Opcode.dll. + * \file Opcode.h + * \author Pierre Terdiman + * \date March, 20, 2001 + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Include Guard +#ifndef __OPCODE_H__ +#define __OPCODE_H__ + +// stddef.h and stdarg.h must be included before Opcode headers +// as they latermay not compile being not able to find types in std:: +#include +#include + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Things to help us compile on non-windows platforms + +#if defined(__APPLE__) || defined(__MACOSX__) +#if __APPLE_CC__ < 1495 +#define sqrtf sqrt +#define sinf sin +#define cosf cos +#define acosf acos +#define asinf asin +#endif +#endif + +#ifndef _MSC_VER +#ifndef __int64 +#define __int64 long long int +#endif +#ifndef __stdcall /* this is defined in MinGW and CygWin, so avoid the warning */ +#define __stdcall /* */ +#endif +#endif + +#if defined(__GNUC__) +#define OPCODE_NORETURN __attribute__((noreturn)) +#elif defined(_MSC_VER) +#define OPCODE_NORETURN __declspec(noreturn) +#else // #if !defined(_MSC_VER) +#define OPCODE_NORETURN +#endif // #if !defined(__GNUC__) + + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Compilation messages +#ifdef _MSC_VER + #if defined(OPCODE_EXPORTS) + // #pragma message("Compiling OPCODE") + #elif !defined(OPCODE_EXPORTS) + // #pragma message("Using OPCODE") + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + // Automatic linking + #ifndef BAN_OPCODE_AUTOLINK + #ifdef _DEBUG + //#pragma comment(lib, "Opcode_D.lib") + #else + //#pragma comment(lib, "Opcode.lib") + #endif + #endif + #endif +#endif + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Preprocessor +#ifndef ICE_NO_DLL + #ifdef OPCODE_EXPORTS + #define OPCODE_API// __declspec(dllexport) + #else + #define OPCODE_API// __declspec(dllimport) + #endif +#else + #define OPCODE_API +#endif + + #include "OPC_Settings.h" + #include "OPC_IceHook.h" + + namespace Opcode + { + // Bulk-of-the-work + #include "OPC_Common.h" + #include "OPC_MeshInterface.h" + // Builders + #include "OPC_TreeBuilders.h" + // Trees + #include "OPC_AABBTree.h" + #include "OPC_OptimizedTree.h" + // Models + #include "OPC_BaseModel.h" + #include "OPC_Model.h" + #include "OPC_HybridModel.h" + // Colliders + #include "OPC_Collider.h" + #include "OPC_VolumeCollider.h" + #include "OPC_TreeCollider.h" + #include "OPC_RayCollider.h" + #include "OPC_SphereCollider.h" + #include "OPC_OBBCollider.h" + #include "OPC_AABBCollider.h" + #include "OPC_LSSCollider.h" + #include "OPC_PlanesCollider.h" + // Usages + #include "OPC_Picking.h" + + + typedef void (*OPCODE_AbortHandler)(); + FUNCTION OPCODE_API bool InitOpcode(OPCODE_AbortHandler fnAbortHandler=NULL); + FUNCTION OPCODE_API bool CloseOpcode(); + } + +#endif // __OPCODE_H__ diff --git a/libs/ode-0.16.1/OPCODE/README-ODE.txt b/libs/ode-0.16.1/OPCODE/README-ODE.txt new file mode 100644 index 0000000..c5d5800 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/README-ODE.txt @@ -0,0 +1,13 @@ + +This is a copy of the OPCODE collision detection library by Pierre Terdiman. +See http://www.codercorner.com/Opcode.htm for more information, and read +the ReadMe.txt in this directory. + +If you want to use the TriList (triangle mesh) geometry class in ODE, the +OPCODE library must be compiled. If you are using the autotools support to +compile ODE, you just have to specify --with-trimesh=opcode when calling ./configure. + +This code was originally written for and compiled on windows, but it has been +ported so that it should compile under unix/gcc too. Your mileage may vary. + +Russ Smith, April 12 2005. diff --git a/libs/ode-0.16.1/OPCODE/ReadMe.txt b/libs/ode-0.16.1/OPCODE/ReadMe.txt new file mode 100644 index 0000000..8a39eff --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/ReadMe.txt @@ -0,0 +1,171 @@ + + OPCODE distribution 1.3 (june 2003) + ----------------------- + + New in Opcode 1.3: + - fixed the divide by 0 bug that was happening when all centers where located on a coordinate axis (thanks to Jorrit T) + - linearized "complete" vanilla AABB trees + - ANSI-compliant "for" loops (for the ones porting it to Linux...) + - callbacks & pointers moved to mesh interface + - support for triangle & vertex strides + - optimized the sphere-triangle overlap code a bit + - dynamic trees (refit) + - more builders + - ValidateSubdivision in builders + - LSS collider + - primitive-bv tests can now be skipped in most volume queries + - temporal coherence now also works for airborne objects + - temporal coherence completed for boxes / all contacts, LSS, etc + - ray-collider now uses a callback + - some common "usages" have been introduced (only picking for now) + - SPLIT_COMPLETE removed (now implicitely using mLimit = 1) + - hybrid collision models + - sweep-and-prune code added, moved from my old Z-Collide lib + - it now works with meshes made of only 1 triangle (except in mesh-mesh case!) + + Disclaimer: + + - I forced myself to actually *do* the release today no matter what. Else it would never have been done. That's + why the code may not be very polished. I also removed a *lot* of things (more usages, distance queries, etc...) + that weren't ready for prime-time (or that were linked to too many of my supporting libs) + + - Some comments may also be obsolete here and there. The old User Manual for Opcode 1.2 may not fit version 1.3 + either, since there's a new "mesh interface" to support strides, etc. + + - Everything in the "Ice" directory has been hacked out of my engine and edited until everything compiled. Don't + expect anything out there to be cute or something. In particular, some CPP files are not even included when not + needed, so you can expect some linker errors if you try messing around with them... + + Otherwise, it should be just like previous version, only better. In particular, hybrid models can be very + memory-friendly (sometimes using like 10 times less ram than the best trees from version 1.2). The possible + speed hit is often invisible (if it even exists), especially using temporal coherence in "all contacts" mode. + (Admittedly, this depends on your particular usage pattern / what you do on collided triangles). + + The sweep-and-prune code is similar to the "vanilla" version found in V-Collide (but that one's better IMHO...) + The simple "radix" version is often just as good, see for yourself. + + OPCODE distribution 1.2 (august 2002) + ----------------------- + + New in Opcode 1.2: + - new VolumeCollider base class + - simplified callback setup + - you can now use callbacks or pointers (setup at compile time) + - destination array not needed anymore in the RayCollider (faster in-out tests) + - renamed classes: AABBRayCollider => RayCollider, AABBSphereCollider => SphereCollider + - the sphere query now only returns a list of faces (extra info discarded). On the other hand it's a lot faster. + - OBB, AABB and planes queries. Original OBB and AABB queries contributed by Erwin de Vries. + - cosmetic changes in OPC_BoxBoxOverlap.h contributed by Gottfried Chen + - some inlining problems fixed + - faster ray-mesh tests using the separating axis theorem + - new split value in AABB tree construction (contributed by Igor Kravtchenko). Provides faster queries most of the time. + - improved temporal coherence for sphere & AABB queries (works in "All contacts" mode) + + Notes: + + - Everything in the "Ice code" directory (in VC++) is basically copy-pasted from my engine, with a lot + of code removed until there was no link error anymore. Don't expect those files to be cute or anything, + they've never been meant to be released and they're often updated/modified/messy. + - Some experimental features have been removed as well. Else I would never have released the 1.2... + - Not as polished/optimal as I would like it to be, but that's life. I promised myself to release it + before october 2002 (one YEAR later ?!).... That's the only reason why it's there. + - Some people reported ColDet was faster. Uh, come on. They were using Opcode in + "All contacts" mode whereas ColDet was doing "first contact"... + + OPCODE distribution 1.1 (october 2001) + ----------------------- + + New in Opcode 1.1: + - stabbing queries + - sphere queries + - abtract base class for colliders + - settings validation methods + - compilation flags now grouped in OPC_Settings.h + - smaller files, new VC++ virtual dirs (cleaner) + + Notes: + + - "override(baseclass)" is a personal cosmetic thing. It's the same as "virtual", but provides more info. + - I code in 1600*1200, so some lines may look a bit long.. + - This version is not as polished as the previous one due to lack of time. The stabbing & sphere queries + can still be optimized: for example by trying other atomic overlap tests. I'm using my first ray-AABB + code, but the newer one seems better. Tim Schröder's one is good as well. See: www.codercorner.com/RayAABB.cpp + - The trees can easily be compressed even more, I save this for later (lack of time, lack of time!) + - I removed various tests before releasing this one: + - a separation line, a.k.a. "front" in QuickCD, because gains were unclear + - distance queries in a PQP style, because it was way too slow + - support for deformable models, too slow as well + - You can easily use Opcode to do your player-vs-world collision detection, in a Nettle/Telemachos way. + If someone out there wants to donate some art / level for the cause, I'd be glad to release a demo. (current + demo uses copyrighted art I'm not allowed to spread) + - Sorry for the lack of real docs and/or solid examples. I just don't have enough time. + + OPCODE distribution 1.0 (march 2001) + ----------------------- + + - First release + + =============================================================================== + + WHAT ? + + OPCODE means OPtimized COllision DEtection. + So this is a collision detection package similar to RAPID. Here's a + quick list of features: + + - C++ interface, developed for Windows systems using VC++ 6.0 + - Works on arbitrary meshes (convex or non-convex), even polygon soups + - Current implementation uses AABB-trees + - Introduces Primitive-BV overlap tests during recursive collision queries (whereas + standard libraries only rely on Primitive-Primitive and BV-BV tests) + - Introduces no-leaf trees, i.e. collision trees whose leaf nodes have been removed + - Supports collision queries on quantized trees (decompressed on-the-fly) + - Supports "first contact" or "all contacts" modes (à la RAPID) + - Uses temporal coherence for "first contact" mode (~10 to 20 times faster, useful + in rigid body simulation during bisection) + - Memory footprint is 7.2 times smaller than RAPID's one, which is ideal for console + games with limited ram (actually, if you use the unmodified RAPID code using double + precision, it's more like 13 times smaller...) + - And yet it often runs faster than RAPID (according to RDTSC, sometimes more than 5 + times faster when objects are deeply overlapping) + - Performance is usually close to RAPID's one in close-proximity situations + - Stabbing, planes & volume queries (sphere, AABB, OBB, LSS) + - Sweep-and-prune + - Now works with deformable meshes + - Hybrid trees + + + What it can be used for: + - standard mesh-mesh collision detection (similar to RAPID, SOLID, QuickCD, PQP, ColDet...) + - N-body collisions (similar to V-Collide) + - camera-vs-world collisions (similar to Telemachos/Paul Nettle/Stan Melax articles) + - shadow feelers to speed up lightmap computations + - in-out tests to speed up voxelization processes + - picking + - rigid body simulation + - view frustum culling + - etc + + WHY ? + + - Because RAPID uses too many bytes. + - Because the idea was nice... + + WHEN ? + + It's been coded in march 2001 following a thread on the GD-Algorithms list. + + GDAlgorithms-list mailing list + GDAlgorithms-list@lists.sourceforge.net + http://lists.sourceforge.net/lists/listinfo/gdalgorithms-list + + WHO ? + + Pierre Terdiman + June, 1, 2003 + + p.terdiman@wanadoo.fr + p.terdiman@codercorner.com + + http://www.codercorner.com + http://www.codercorner.com/Opcode.htm diff --git a/libs/ode-0.16.1/OPCODE/Stdafx.h b/libs/ode-0.16.1/OPCODE/Stdafx.h new file mode 100644 index 0000000..0223a6c --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/Stdafx.h @@ -0,0 +1,24 @@ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +/* + * OPCODE - Optimized Collision Detection + * Copyright (C) 2001 Pierre Terdiman + * Homepage: http://www.codercorner.com/Opcode.htm + */ +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +#if !defined(AFX_STDAFX_H__EFB95044_1D31_11D5_8B0F_0050BAC83302__INCLUDED_) +#define AFX_STDAFX_H__EFB95044_1D31_11D5_8B0F_0050BAC83302__INCLUDED_ + +#if _MSC_VER > 1000 +#pragma once +#endif // _MSC_VER > 1000 + +// Insert your headers here +#define WIN32_LEAN_AND_MEAN // Exclude rarely-used stuff from Windows headers + +#include "Opcode.h" + +//{{AFX_INSERT_LOCATION}} +// Microsoft Visual C++ will insert additional declarations immediately before the previous line. + +#endif // !defined(AFX_STDAFX_H__EFB95044_1D31_11D5_8B0F_0050BAC83302__INCLUDED_) diff --git a/libs/ode-0.16.1/OPCODE/TemporalCoherence.txt b/libs/ode-0.16.1/OPCODE/TemporalCoherence.txt new file mode 100644 index 0000000..fb85931 --- /dev/null +++ b/libs/ode-0.16.1/OPCODE/TemporalCoherence.txt @@ -0,0 +1,32 @@ + +> Hi John, +> +> I know I'll forget to tell you this if I don't write it right now.... +> +> >(2) How is the receiving geometry for the shadow decided? +> +> I wrote about an LSS-test but actually performing a new VFC test (from the +> light's view) is the same. In both cases, here's a trick to take advantage +> of temporal coherence : test the world against a slightly larger than +> necessary LSS or frustum. Keep the list of touched surfaces. Then next +> frame, if the new volume is still contained within the previous one used +for +> the query, you can reuse the same list immediately. Actually it's a bit +> similar to what you did in your sphere-tree, I think. Anyway, now the +O(log +> N) VFC is O(1) for some frames. It's not worth it for the "real" VFC, but +> when you have N virtual frustum to test to drop N shadows, that's another +> story. +> +> Two downsides: +> - You need more ram to keep track of one list of meshes / shadow, but +> usually it's not a lot. +> - By using a larger volume for the query you possibly touch more +> faces/surfaces, which will be rendered in the shadow pass. Usually it's +not +> a problem either since rendering is simply faster than geometric queries +> those days. But of course, "your mileage may vary". +> +> Happy new year ! +> +> Pierre diff --git a/libs/ode-0.16.1/README.md b/libs/ode-0.16.1/README.md new file mode 100644 index 0000000..b28a3b5 --- /dev/null +++ b/libs/ode-0.16.1/README.md @@ -0,0 +1,34 @@ +The Open Dynamics Engine (ODE) +============================== + +![ODE logo](http://bitbucket.org/odedevs/ode/raw/default/web/ODElogo.png) + +Copyright (C) 2001-2007 Russell L. Smith. + + +ODE is a free, industrial quality library for simulating articulated +rigid body dynamics - for example ground vehicles, legged creatures, +and moving objects in VR environments. It is fast, flexible, robust +and platform independent, with advanced joints, contact with friction, +and built-in collision detection. + +This library is free software; you can redistribute it and/or +modify it under the terms of EITHER: + + * The GNU Lesser General Public License version 2.1 or any later. + + * The BSD-style License. + +See the [COPYING](http://bitbucket.org/odedevs/ode/raw/default/COPYING) file for more details. + + * Installation instructions are in the [INSTALL.txt](http://bitbucket.org/odedevs/ode/raw/default/INSTALL.txt) file. + + * The ODE web pages are at [ode.org](http://www.ode.org/). + + * An online manual is at [the Wiki](http://ode-wiki.org/wiki/index.php?title=Manual). + + * API documentation is in the file ode/docs/index.html, or you + can view it on the web at [opende.sf.net/docs/index.html](http://opende.sf.net/docs/index.html). + + * Coding style requirements can be found in the [CSR.txt](http://bitbucket.org/odedevs/ode/raw/default/CSR.txt) file. + diff --git a/libs/ode-0.16.1/aclocal.m4 b/libs/ode-0.16.1/aclocal.m4 new file mode 100644 index 0000000..df157e5 --- /dev/null +++ b/libs/ode-0.16.1/aclocal.m4 @@ -0,0 +1,1158 @@ +# generated automatically by aclocal 1.15 -*- Autoconf -*- + +# Copyright (C) 1996-2014 Free Software Foundation, Inc. + +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])]) +m4_ifndef([AC_AUTOCONF_VERSION], + [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl +m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],, +[m4_warning([this file was generated for autoconf 2.69. +You have another version of autoconf. It may work, but is not guaranteed to. +If you have problems, you may need to regenerate the build system entirely. +To do so, use the procedure documented by the package, typically 'autoreconf'.])]) + +# Copyright (C) 2002-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_AUTOMAKE_VERSION(VERSION) +# ---------------------------- +# Automake X.Y traces this macro to ensure aclocal.m4 has been +# generated from the m4 files accompanying Automake X.Y. +# (This private macro should not be called outside this file.) +AC_DEFUN([AM_AUTOMAKE_VERSION], +[am__api_version='1.15' +dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to +dnl require some minimum version. Point them to the right macro. +m4_if([$1], [1.15], [], + [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl +]) + +# _AM_AUTOCONF_VERSION(VERSION) +# ----------------------------- +# aclocal traces this macro to find the Autoconf version. +# This is a private macro too. Using m4_define simplifies +# the logic in aclocal, which can simply ignore this definition. +m4_define([_AM_AUTOCONF_VERSION], []) + +# AM_SET_CURRENT_AUTOMAKE_VERSION +# ------------------------------- +# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. +# This function is AC_REQUIREd by AM_INIT_AUTOMAKE. +AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], +[AM_AUTOMAKE_VERSION([1.15])dnl +m4_ifndef([AC_AUTOCONF_VERSION], + [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl +_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) + +# AM_AUX_DIR_EXPAND -*- Autoconf -*- + +# Copyright (C) 2001-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets +# $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to +# '$srcdir', '$srcdir/..', or '$srcdir/../..'. +# +# Of course, Automake must honor this variable whenever it calls a +# tool from the auxiliary directory. The problem is that $srcdir (and +# therefore $ac_aux_dir as well) can be either absolute or relative, +# depending on how configure is run. This is pretty annoying, since +# it makes $ac_aux_dir quite unusable in subdirectories: in the top +# source directory, any form will work fine, but in subdirectories a +# relative path needs to be adjusted first. +# +# $ac_aux_dir/missing +# fails when called from a subdirectory if $ac_aux_dir is relative +# $top_srcdir/$ac_aux_dir/missing +# fails if $ac_aux_dir is absolute, +# fails when called from a subdirectory in a VPATH build with +# a relative $ac_aux_dir +# +# The reason of the latter failure is that $top_srcdir and $ac_aux_dir +# are both prefixed by $srcdir. In an in-source build this is usually +# harmless because $srcdir is '.', but things will broke when you +# start a VPATH build or use an absolute $srcdir. +# +# So we could use something similar to $top_srcdir/$ac_aux_dir/missing, +# iff we strip the leading $srcdir from $ac_aux_dir. That would be: +# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` +# and then we would define $MISSING as +# MISSING="\${SHELL} $am_aux_dir/missing" +# This will work as long as MISSING is not called from configure, because +# unfortunately $(top_srcdir) has no meaning in configure. +# However there are other variables, like CC, which are often used in +# configure, and could therefore not use this "fixed" $ac_aux_dir. +# +# Another solution, used here, is to always expand $ac_aux_dir to an +# absolute PATH. The drawback is that using absolute paths prevent a +# configured tree to be moved without reconfiguration. + +AC_DEFUN([AM_AUX_DIR_EXPAND], +[AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl +# Expand $ac_aux_dir to an absolute path. +am_aux_dir=`cd "$ac_aux_dir" && pwd` +]) + +# AM_CONDITIONAL -*- Autoconf -*- + +# Copyright (C) 1997-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_CONDITIONAL(NAME, SHELL-CONDITION) +# ------------------------------------- +# Define a conditional. +AC_DEFUN([AM_CONDITIONAL], +[AC_PREREQ([2.52])dnl + m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], + [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl +AC_SUBST([$1_TRUE])dnl +AC_SUBST([$1_FALSE])dnl +_AM_SUBST_NOTMAKE([$1_TRUE])dnl +_AM_SUBST_NOTMAKE([$1_FALSE])dnl +m4_define([_AM_COND_VALUE_$1], [$2])dnl +if $2; then + $1_TRUE= + $1_FALSE='#' +else + $1_TRUE='#' + $1_FALSE= +fi +AC_CONFIG_COMMANDS_PRE( +[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then + AC_MSG_ERROR([[conditional "$1" was never defined. +Usually this means the macro was only invoked conditionally.]]) +fi])]) + +# Copyright (C) 1999-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + + +# There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be +# written in clear, in which case automake, when reading aclocal.m4, +# will think it sees a *use*, and therefore will trigger all it's +# C support machinery. Also note that it means that autoscan, seeing +# CC etc. in the Makefile, will ask for an AC_PROG_CC use... + + +# _AM_DEPENDENCIES(NAME) +# ---------------------- +# See how the compiler implements dependency checking. +# NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC". +# We try a few techniques and use that to set a single cache variable. +# +# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was +# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular +# dependency, and given that the user is not expected to run this macro, +# just rely on AC_PROG_CC. +AC_DEFUN([_AM_DEPENDENCIES], +[AC_REQUIRE([AM_SET_DEPDIR])dnl +AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl +AC_REQUIRE([AM_MAKE_INCLUDE])dnl +AC_REQUIRE([AM_DEP_TRACK])dnl + +m4_if([$1], [CC], [depcc="$CC" am_compiler_list=], + [$1], [CXX], [depcc="$CXX" am_compiler_list=], + [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'], + [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'], + [$1], [UPC], [depcc="$UPC" am_compiler_list=], + [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'], + [depcc="$$1" am_compiler_list=]) + +AC_CACHE_CHECK([dependency style of $depcc], + [am_cv_$1_dependencies_compiler_type], +[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then + # We make a subdir and do the tests there. Otherwise we can end up + # making bogus files that we don't know about and never remove. For + # instance it was reported that on HP-UX the gcc test will end up + # making a dummy file named 'D' -- because '-MD' means "put the output + # in D". + rm -rf conftest.dir + mkdir conftest.dir + # Copy depcomp to subdir because otherwise we won't find it if we're + # using a relative directory. + cp "$am_depcomp" conftest.dir + cd conftest.dir + # We will build objects and dependencies in a subdirectory because + # it helps to detect inapplicable dependency modes. For instance + # both Tru64's cc and ICC support -MD to output dependencies as a + # side effect of compilation, but ICC will put the dependencies in + # the current directory while Tru64 will put them in the object + # directory. + mkdir sub + + am_cv_$1_dependencies_compiler_type=none + if test "$am_compiler_list" = ""; then + am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` + fi + am__universal=false + m4_case([$1], [CC], + [case " $depcc " in #( + *\ -arch\ *\ -arch\ *) am__universal=true ;; + esac], + [CXX], + [case " $depcc " in #( + *\ -arch\ *\ -arch\ *) am__universal=true ;; + esac]) + + for depmode in $am_compiler_list; do + # Setup a source with many dependencies, because some compilers + # like to wrap large dependency lists on column 80 (with \), and + # we should not choose a depcomp mode which is confused by this. + # + # We need to recreate these files for each test, as the compiler may + # overwrite some of them when testing with obscure command lines. + # This happens at least with the AIX C compiler. + : > sub/conftest.c + for i in 1 2 3 4 5 6; do + echo '#include "conftst'$i'.h"' >> sub/conftest.c + # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with + # Solaris 10 /bin/sh. + echo '/* dummy */' > sub/conftst$i.h + done + echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf + + # We check with '-c' and '-o' for the sake of the "dashmstdout" + # mode. It turns out that the SunPro C++ compiler does not properly + # handle '-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs. + am__obj=sub/conftest.${OBJEXT-o} + am__minus_obj="-o $am__obj" + case $depmode in + gcc) + # This depmode causes a compiler race in universal mode. + test "$am__universal" = false || continue + ;; + nosideeffect) + # After this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested. + if test "x$enable_dependency_tracking" = xyes; then + continue + else + break + fi + ;; + msvc7 | msvc7msys | msvisualcpp | msvcmsys) + # This compiler won't grok '-c -o', but also, the minuso test has + # not run yet. These depmodes are late enough in the game, and + # so weak that their functioning should not be impacted. + am__obj=conftest.${OBJEXT-o} + am__minus_obj= + ;; + none) break ;; + esac + if depmode=$depmode \ + source=sub/conftest.c object=$am__obj \ + depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ + $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ + >/dev/null 2>conftest.err && + grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && + grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && + grep $am__obj sub/conftest.Po > /dev/null 2>&1 && + ${MAKE-make} -s -f confmf > /dev/null 2>&1; then + # icc doesn't choke on unknown options, it will just issue warnings + # or remarks (even with -Werror). So we grep stderr for any message + # that says an option was ignored or not supported. + # When given -MP, icc 7.0 and 7.1 complain thusly: + # icc: Command line warning: ignoring option '-M'; no argument required + # The diagnosis changed in icc 8.0: + # icc: Command line remark: option '-MP' not supported + if (grep 'ignoring option' conftest.err || + grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else + am_cv_$1_dependencies_compiler_type=$depmode + break + fi + fi + done + + cd .. + rm -rf conftest.dir +else + am_cv_$1_dependencies_compiler_type=none +fi +]) +AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) +AM_CONDITIONAL([am__fastdep$1], [ + test "x$enable_dependency_tracking" != xno \ + && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) +]) + + +# AM_SET_DEPDIR +# ------------- +# Choose a directory name for dependency files. +# This macro is AC_REQUIREd in _AM_DEPENDENCIES. +AC_DEFUN([AM_SET_DEPDIR], +[AC_REQUIRE([AM_SET_LEADING_DOT])dnl +AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl +]) + + +# AM_DEP_TRACK +# ------------ +AC_DEFUN([AM_DEP_TRACK], +[AC_ARG_ENABLE([dependency-tracking], [dnl +AS_HELP_STRING( + [--enable-dependency-tracking], + [do not reject slow dependency extractors]) +AS_HELP_STRING( + [--disable-dependency-tracking], + [speeds up one-time build])]) +if test "x$enable_dependency_tracking" != xno; then + am_depcomp="$ac_aux_dir/depcomp" + AMDEPBACKSLASH='\' + am__nodep='_no' +fi +AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) +AC_SUBST([AMDEPBACKSLASH])dnl +_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl +AC_SUBST([am__nodep])dnl +_AM_SUBST_NOTMAKE([am__nodep])dnl +]) + +# Generate code to set up dependency tracking. -*- Autoconf -*- + +# Copyright (C) 1999-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + + +# _AM_OUTPUT_DEPENDENCY_COMMANDS +# ------------------------------ +AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], +[{ + # Older Autoconf quotes --file arguments for eval, but not when files + # are listed without --file. Let's play safe and only enable the eval + # if we detect the quoting. + case $CONFIG_FILES in + *\'*) eval set x "$CONFIG_FILES" ;; + *) set x $CONFIG_FILES ;; + esac + shift + for mf + do + # Strip MF so we end up with the name of the file. + mf=`echo "$mf" | sed -e 's/:.*$//'` + # Check whether this is an Automake generated Makefile or not. + # We used to match only the files named 'Makefile.in', but + # some people rename them; so instead we look at the file content. + # Grep'ing the first line is not enough: some people post-process + # each Makefile.in and add a new line on top of each file to say so. + # Grep'ing the whole file is not good either: AIX grep has a line + # limit of 2048, but all sed's we know have understand at least 4000. + if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then + dirpart=`AS_DIRNAME("$mf")` + else + continue + fi + # Extract the definition of DEPDIR, am__include, and am__quote + # from the Makefile without running 'make'. + DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` + test -z "$DEPDIR" && continue + am__include=`sed -n 's/^am__include = //p' < "$mf"` + test -z "$am__include" && continue + am__quote=`sed -n 's/^am__quote = //p' < "$mf"` + # Find all dependency output files, they are included files with + # $(DEPDIR) in their names. We invoke sed twice because it is the + # simplest approach to changing $(DEPDIR) to its actual value in the + # expansion. + for file in `sed -n " + s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ + sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do + # Make sure the directory exists. + test -f "$dirpart/$file" && continue + fdir=`AS_DIRNAME(["$file"])` + AS_MKDIR_P([$dirpart/$fdir]) + # echo "creating $dirpart/$file" + echo '# dummy' > "$dirpart/$file" + done + done +} +])# _AM_OUTPUT_DEPENDENCY_COMMANDS + + +# AM_OUTPUT_DEPENDENCY_COMMANDS +# ----------------------------- +# This macro should only be invoked once -- use via AC_REQUIRE. +# +# This code is only required when automatic dependency tracking +# is enabled. FIXME. This creates each '.P' file that we will +# need in order to bootstrap the dependency handling code. +AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], +[AC_CONFIG_COMMANDS([depfiles], + [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], + [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) +]) + +# Do all the work for Automake. -*- Autoconf -*- + +# Copyright (C) 1996-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This macro actually does too much. Some checks are only needed if +# your package does certain things. But this isn't really a big deal. + +dnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O. +m4_define([AC_PROG_CC], +m4_defn([AC_PROG_CC]) +[_AM_PROG_CC_C_O +]) + +# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) +# AM_INIT_AUTOMAKE([OPTIONS]) +# ----------------------------------------------- +# The call with PACKAGE and VERSION arguments is the old style +# call (pre autoconf-2.50), which is being phased out. PACKAGE +# and VERSION should now be passed to AC_INIT and removed from +# the call to AM_INIT_AUTOMAKE. +# We support both call styles for the transition. After +# the next Automake release, Autoconf can make the AC_INIT +# arguments mandatory, and then we can depend on a new Autoconf +# release and drop the old call support. +AC_DEFUN([AM_INIT_AUTOMAKE], +[AC_PREREQ([2.65])dnl +dnl Autoconf wants to disallow AM_ names. We explicitly allow +dnl the ones we care about. +m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl +AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl +AC_REQUIRE([AC_PROG_INSTALL])dnl +if test "`cd $srcdir && pwd`" != "`pwd`"; then + # Use -I$(srcdir) only when $(srcdir) != ., so that make's output + # is not polluted with repeated "-I." + AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl + # test to see if srcdir already configured + if test -f $srcdir/config.status; then + AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) + fi +fi + +# test whether we have cygpath +if test -z "$CYGPATH_W"; then + if (cygpath --version) >/dev/null 2>/dev/null; then + CYGPATH_W='cygpath -w' + else + CYGPATH_W=echo + fi +fi +AC_SUBST([CYGPATH_W]) + +# Define the identity of the package. +dnl Distinguish between old-style and new-style calls. +m4_ifval([$2], +[AC_DIAGNOSE([obsolete], + [$0: two- and three-arguments forms are deprecated.]) +m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl + AC_SUBST([PACKAGE], [$1])dnl + AC_SUBST([VERSION], [$2])], +[_AM_SET_OPTIONS([$1])dnl +dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. +m4_if( + m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]), + [ok:ok],, + [m4_fatal([AC_INIT should be called with package and version arguments])])dnl + AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl + AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl + +_AM_IF_OPTION([no-define],, +[AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package]) + AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl + +# Some tools Automake needs. +AC_REQUIRE([AM_SANITY_CHECK])dnl +AC_REQUIRE([AC_ARG_PROGRAM])dnl +AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}]) +AM_MISSING_PROG([AUTOCONF], [autoconf]) +AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}]) +AM_MISSING_PROG([AUTOHEADER], [autoheader]) +AM_MISSING_PROG([MAKEINFO], [makeinfo]) +AC_REQUIRE([AM_PROG_INSTALL_SH])dnl +AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl +AC_REQUIRE([AC_PROG_MKDIR_P])dnl +# For better backward compatibility. To be removed once Automake 1.9.x +# dies out for good. For more background, see: +# +# +AC_SUBST([mkdir_p], ['$(MKDIR_P)']) +# We need awk for the "check" target (and possibly the TAP driver). The +# system "awk" is bad on some platforms. +AC_REQUIRE([AC_PROG_AWK])dnl +AC_REQUIRE([AC_PROG_MAKE_SET])dnl +AC_REQUIRE([AM_SET_LEADING_DOT])dnl +_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], + [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], + [_AM_PROG_TAR([v7])])]) +_AM_IF_OPTION([no-dependencies],, +[AC_PROVIDE_IFELSE([AC_PROG_CC], + [_AM_DEPENDENCIES([CC])], + [m4_define([AC_PROG_CC], + m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl +AC_PROVIDE_IFELSE([AC_PROG_CXX], + [_AM_DEPENDENCIES([CXX])], + [m4_define([AC_PROG_CXX], + m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl +AC_PROVIDE_IFELSE([AC_PROG_OBJC], + [_AM_DEPENDENCIES([OBJC])], + [m4_define([AC_PROG_OBJC], + m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl +AC_PROVIDE_IFELSE([AC_PROG_OBJCXX], + [_AM_DEPENDENCIES([OBJCXX])], + [m4_define([AC_PROG_OBJCXX], + m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl +]) +AC_REQUIRE([AM_SILENT_RULES])dnl +dnl The testsuite driver may need to know about EXEEXT, so add the +dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This +dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below. +AC_CONFIG_COMMANDS_PRE(dnl +[m4_provide_if([_AM_COMPILER_EXEEXT], + [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl + +# POSIX will say in a future version that running "rm -f" with no argument +# is OK; and we want to be able to make that assumption in our Makefile +# recipes. So use an aggressive probe to check that the usage we want is +# actually supported "in the wild" to an acceptable degree. +# See automake bug#10828. +# To make any issue more visible, cause the running configure to be aborted +# by default if the 'rm' program in use doesn't match our expectations; the +# user can still override this though. +if rm -f && rm -fr && rm -rf; then : OK; else + cat >&2 <<'END' +Oops! + +Your 'rm' program seems unable to run without file operands specified +on the command line, even when the '-f' option is present. This is contrary +to the behaviour of most rm programs out there, and not conforming with +the upcoming POSIX standard: + +Please tell bug-automake@gnu.org about your system, including the value +of your $PATH and any error possibly output before this message. This +can help us improve future automake versions. + +END + if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then + echo 'Configuration will proceed anyway, since you have set the' >&2 + echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 + echo >&2 + else + cat >&2 <<'END' +Aborting the configuration process, to ensure you take notice of the issue. + +You can download and install GNU coreutils to get an 'rm' implementation +that behaves properly: . + +If you want to complete the configuration process using your problematic +'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM +to "yes", and re-run configure. + +END + AC_MSG_ERROR([Your 'rm' program is bad, sorry.]) + fi +fi +dnl The trailing newline in this macro's definition is deliberate, for +dnl backward compatibility and to allow trailing 'dnl'-style comments +dnl after the AM_INIT_AUTOMAKE invocation. See automake bug#16841. +]) + +dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not +dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further +dnl mangled by Autoconf and run in a shell conditional statement. +m4_define([_AC_COMPILER_EXEEXT], +m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])]) + +# When config.status generates a header, we must update the stamp-h file. +# This file resides in the same directory as the config header +# that is generated. The stamp files are numbered to have different names. + +# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the +# loop where config.status creates the headers, so we can generate +# our stamp files there. +AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], +[# Compute $1's index in $config_headers. +_am_arg=$1 +_am_stamp_count=1 +for _am_header in $config_headers :; do + case $_am_header in + $_am_arg | $_am_arg:* ) + break ;; + * ) + _am_stamp_count=`expr $_am_stamp_count + 1` ;; + esac +done +echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) + +# Copyright (C) 2001-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_PROG_INSTALL_SH +# ------------------ +# Define $install_sh. +AC_DEFUN([AM_PROG_INSTALL_SH], +[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl +if test x"${install_sh+set}" != xset; then + case $am_aux_dir in + *\ * | *\ *) + install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; + *) + install_sh="\${SHELL} $am_aux_dir/install-sh" + esac +fi +AC_SUBST([install_sh])]) + +# Copyright (C) 2003-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# Check whether the underlying file-system supports filenames +# with a leading dot. For instance MS-DOS doesn't. +AC_DEFUN([AM_SET_LEADING_DOT], +[rm -rf .tst 2>/dev/null +mkdir .tst 2>/dev/null +if test -d .tst; then + am__leading_dot=. +else + am__leading_dot=_ +fi +rmdir .tst 2>/dev/null +AC_SUBST([am__leading_dot])]) + +# Check to see how 'make' treats includes. -*- Autoconf -*- + +# Copyright (C) 2001-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_MAKE_INCLUDE() +# ----------------- +# Check to see how make treats includes. +AC_DEFUN([AM_MAKE_INCLUDE], +[am_make=${MAKE-make} +cat > confinc << 'END' +am__doit: + @echo this is the am__doit target +.PHONY: am__doit +END +# If we don't find an include directive, just comment out the code. +AC_MSG_CHECKING([for style of include used by $am_make]) +am__include="#" +am__quote= +_am_result=none +# First try GNU make style include. +echo "include confinc" > confmf +# Ignore all kinds of additional output from 'make'. +case `$am_make -s -f confmf 2> /dev/null` in #( +*the\ am__doit\ target*) + am__include=include + am__quote= + _am_result=GNU + ;; +esac +# Now try BSD make style include. +if test "$am__include" = "#"; then + echo '.include "confinc"' > confmf + case `$am_make -s -f confmf 2> /dev/null` in #( + *the\ am__doit\ target*) + am__include=.include + am__quote="\"" + _am_result=BSD + ;; + esac +fi +AC_SUBST([am__include]) +AC_SUBST([am__quote]) +AC_MSG_RESULT([$_am_result]) +rm -f confinc confmf +]) + +# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- + +# Copyright (C) 1997-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_MISSING_PROG(NAME, PROGRAM) +# ------------------------------ +AC_DEFUN([AM_MISSING_PROG], +[AC_REQUIRE([AM_MISSING_HAS_RUN]) +$1=${$1-"${am_missing_run}$2"} +AC_SUBST($1)]) + +# AM_MISSING_HAS_RUN +# ------------------ +# Define MISSING if not defined so far and test if it is modern enough. +# If it is, set am_missing_run to use it, otherwise, to nothing. +AC_DEFUN([AM_MISSING_HAS_RUN], +[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl +AC_REQUIRE_AUX_FILE([missing])dnl +if test x"${MISSING+set}" != xset; then + case $am_aux_dir in + *\ * | *\ *) + MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; + *) + MISSING="\${SHELL} $am_aux_dir/missing" ;; + esac +fi +# Use eval to expand $SHELL +if eval "$MISSING --is-lightweight"; then + am_missing_run="$MISSING " +else + am_missing_run= + AC_MSG_WARN(['missing' script is too old or missing]) +fi +]) + +# Helper functions for option handling. -*- Autoconf -*- + +# Copyright (C) 2001-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# _AM_MANGLE_OPTION(NAME) +# ----------------------- +AC_DEFUN([_AM_MANGLE_OPTION], +[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) + +# _AM_SET_OPTION(NAME) +# -------------------- +# Set option NAME. Presently that only means defining a flag for this option. +AC_DEFUN([_AM_SET_OPTION], +[m4_define(_AM_MANGLE_OPTION([$1]), [1])]) + +# _AM_SET_OPTIONS(OPTIONS) +# ------------------------ +# OPTIONS is a space-separated list of Automake options. +AC_DEFUN([_AM_SET_OPTIONS], +[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) + +# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) +# ------------------------------------------- +# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. +AC_DEFUN([_AM_IF_OPTION], +[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) + +# Copyright (C) 1999-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# _AM_PROG_CC_C_O +# --------------- +# Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC +# to automatically call this. +AC_DEFUN([_AM_PROG_CC_C_O], +[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl +AC_REQUIRE_AUX_FILE([compile])dnl +AC_LANG_PUSH([C])dnl +AC_CACHE_CHECK( + [whether $CC understands -c and -o together], + [am_cv_prog_cc_c_o], + [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])]) + # Make sure it works both with $CC and with simple cc. + # Following AC_PROG_CC_C_O, we do the test twice because some + # compilers refuse to overwrite an existing .o file with -o, + # though they will create one. + am_cv_prog_cc_c_o=yes + for am_i in 1 2; do + if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \ + && test -f conftest2.$ac_objext; then + : OK + else + am_cv_prog_cc_c_o=no + break + fi + done + rm -f core conftest* + unset am_i]) +if test "$am_cv_prog_cc_c_o" != yes; then + # Losing compiler, so override with the script. + # FIXME: It is wrong to rewrite CC. + # But if we don't then we get into trouble of one sort or another. + # A longer-term fix would be to have automake use am__CC in this case, + # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" + CC="$am_aux_dir/compile $CC" +fi +AC_LANG_POP([C])]) + +# For backward compatibility. +AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])]) + +# Copyright (C) 2001-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_RUN_LOG(COMMAND) +# ------------------- +# Run COMMAND, save the exit status in ac_status, and log it. +# (This has been adapted from Autoconf's _AC_RUN_LOG macro.) +AC_DEFUN([AM_RUN_LOG], +[{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD + ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD + (exit $ac_status); }]) + +# Check to make sure that the build environment is sane. -*- Autoconf -*- + +# Copyright (C) 1996-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_SANITY_CHECK +# --------------- +AC_DEFUN([AM_SANITY_CHECK], +[AC_MSG_CHECKING([whether build environment is sane]) +# Reject unsafe characters in $srcdir or the absolute working directory +# name. Accept space and tab only in the latter. +am_lf=' +' +case `pwd` in + *[[\\\"\#\$\&\'\`$am_lf]]*) + AC_MSG_ERROR([unsafe absolute working directory name]);; +esac +case $srcdir in + *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) + AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);; +esac + +# Do 'set' in a subshell so we don't clobber the current shell's +# arguments. Must try -L first in case configure is actually a +# symlink; some systems play weird games with the mod time of symlinks +# (eg FreeBSD returns the mod time of the symlink's containing +# directory). +if ( + am_has_slept=no + for am_try in 1 2; do + echo "timestamp, slept: $am_has_slept" > conftest.file + set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` + if test "$[*]" = "X"; then + # -L didn't work. + set X `ls -t "$srcdir/configure" conftest.file` + fi + if test "$[*]" != "X $srcdir/configure conftest.file" \ + && test "$[*]" != "X conftest.file $srcdir/configure"; then + + # If neither matched, then we have a broken ls. This can happen + # if, for instance, CONFIG_SHELL is bash and it inherits a + # broken ls alias from the environment. This has actually + # happened. Such a system could not be considered "sane". + AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken + alias in your environment]) + fi + if test "$[2]" = conftest.file || test $am_try -eq 2; then + break + fi + # Just in case. + sleep 1 + am_has_slept=yes + done + test "$[2]" = conftest.file + ) +then + # Ok. + : +else + AC_MSG_ERROR([newly created file is older than distributed files! +Check your system clock]) +fi +AC_MSG_RESULT([yes]) +# If we didn't sleep, we still need to ensure time stamps of config.status and +# generated files are strictly newer. +am_sleep_pid= +if grep 'slept: no' conftest.file >/dev/null 2>&1; then + ( sleep 1 ) & + am_sleep_pid=$! +fi +AC_CONFIG_COMMANDS_PRE( + [AC_MSG_CHECKING([that generated files are newer than configure]) + if test -n "$am_sleep_pid"; then + # Hide warnings about reused PIDs. + wait $am_sleep_pid 2>/dev/null + fi + AC_MSG_RESULT([done])]) +rm -f conftest.file +]) + +# Copyright (C) 2009-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_SILENT_RULES([DEFAULT]) +# -------------------------- +# Enable less verbose build rules; with the default set to DEFAULT +# ("yes" being less verbose, "no" or empty being verbose). +AC_DEFUN([AM_SILENT_RULES], +[AC_ARG_ENABLE([silent-rules], [dnl +AS_HELP_STRING( + [--enable-silent-rules], + [less verbose build output (undo: "make V=1")]) +AS_HELP_STRING( + [--disable-silent-rules], + [verbose build output (undo: "make V=0")])dnl +]) +case $enable_silent_rules in @%:@ ((( + yes) AM_DEFAULT_VERBOSITY=0;; + no) AM_DEFAULT_VERBOSITY=1;; + *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);; +esac +dnl +dnl A few 'make' implementations (e.g., NonStop OS and NextStep) +dnl do not support nested variable expansions. +dnl See automake bug#9928 and bug#10237. +am_make=${MAKE-make} +AC_CACHE_CHECK([whether $am_make supports nested variables], + [am_cv_make_support_nested_variables], + [if AS_ECHO([['TRUE=$(BAR$(V)) +BAR0=false +BAR1=true +V=1 +am__doit: + @$(TRUE) +.PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then + am_cv_make_support_nested_variables=yes +else + am_cv_make_support_nested_variables=no +fi]) +if test $am_cv_make_support_nested_variables = yes; then + dnl Using '$V' instead of '$(V)' breaks IRIX make. + AM_V='$(V)' + AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' +else + AM_V=$AM_DEFAULT_VERBOSITY + AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY +fi +AC_SUBST([AM_V])dnl +AM_SUBST_NOTMAKE([AM_V])dnl +AC_SUBST([AM_DEFAULT_V])dnl +AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl +AC_SUBST([AM_DEFAULT_VERBOSITY])dnl +AM_BACKSLASH='\' +AC_SUBST([AM_BACKSLASH])dnl +_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl +]) + +# Copyright (C) 2001-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_PROG_INSTALL_STRIP +# --------------------- +# One issue with vendor 'install' (even GNU) is that you can't +# specify the program used to strip binaries. This is especially +# annoying in cross-compiling environments, where the build's strip +# is unlikely to handle the host's binaries. +# Fortunately install-sh will honor a STRIPPROG variable, so we +# always use install-sh in "make install-strip", and initialize +# STRIPPROG with the value of the STRIP variable (set by the user). +AC_DEFUN([AM_PROG_INSTALL_STRIP], +[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl +# Installed binaries are usually stripped using 'strip' when the user +# run "make install-strip". However 'strip' might not be the right +# tool to use in cross-compilation environments, therefore Automake +# will honor the 'STRIP' environment variable to overrule this program. +dnl Don't test for $cross_compiling = yes, because it might be 'maybe'. +if test "$cross_compiling" != no; then + AC_CHECK_TOOL([STRIP], [strip], :) +fi +INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" +AC_SUBST([INSTALL_STRIP_PROGRAM])]) + +# Copyright (C) 2006-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# _AM_SUBST_NOTMAKE(VARIABLE) +# --------------------------- +# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. +# This macro is traced by Automake. +AC_DEFUN([_AM_SUBST_NOTMAKE]) + +# AM_SUBST_NOTMAKE(VARIABLE) +# -------------------------- +# Public sister of _AM_SUBST_NOTMAKE. +AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) + +# Check how to create a tarball. -*- Autoconf -*- + +# Copyright (C) 2004-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# _AM_PROG_TAR(FORMAT) +# -------------------- +# Check how to create a tarball in format FORMAT. +# FORMAT should be one of 'v7', 'ustar', or 'pax'. +# +# Substitute a variable $(am__tar) that is a command +# writing to stdout a FORMAT-tarball containing the directory +# $tardir. +# tardir=directory && $(am__tar) > result.tar +# +# Substitute a variable $(am__untar) that extract such +# a tarball read from stdin. +# $(am__untar) < result.tar +# +AC_DEFUN([_AM_PROG_TAR], +[# Always define AMTAR for backward compatibility. Yes, it's still used +# in the wild :-( We should find a proper way to deprecate it ... +AC_SUBST([AMTAR], ['$${TAR-tar}']) + +# We'll loop over all known methods to create a tar archive until one works. +_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' + +m4_if([$1], [v7], + [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'], + + [m4_case([$1], + [ustar], + [# The POSIX 1988 'ustar' format is defined with fixed-size fields. + # There is notably a 21 bits limit for the UID and the GID. In fact, + # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343 + # and bug#13588). + am_max_uid=2097151 # 2^21 - 1 + am_max_gid=$am_max_uid + # The $UID and $GID variables are not portable, so we need to resort + # to the POSIX-mandated id(1) utility. Errors in the 'id' calls + # below are definitely unexpected, so allow the users to see them + # (that is, avoid stderr redirection). + am_uid=`id -u || echo unknown` + am_gid=`id -g || echo unknown` + AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format]) + if test $am_uid -le $am_max_uid; then + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + _am_tools=none + fi + AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format]) + if test $am_gid -le $am_max_gid; then + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + _am_tools=none + fi], + + [pax], + [], + + [m4_fatal([Unknown tar format])]) + + AC_MSG_CHECKING([how to create a $1 tar archive]) + + # Go ahead even if we have the value already cached. We do so because we + # need to set the values for the 'am__tar' and 'am__untar' variables. + _am_tools=${am_cv_prog_tar_$1-$_am_tools} + + for _am_tool in $_am_tools; do + case $_am_tool in + gnutar) + for _am_tar in tar gnutar gtar; do + AM_RUN_LOG([$_am_tar --version]) && break + done + am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' + am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' + am__untar="$_am_tar -xf -" + ;; + plaintar) + # Must skip GNU tar: if it does not support --format= it doesn't create + # ustar tarball either. + (tar --version) >/dev/null 2>&1 && continue + am__tar='tar chf - "$$tardir"' + am__tar_='tar chf - "$tardir"' + am__untar='tar xf -' + ;; + pax) + am__tar='pax -L -x $1 -w "$$tardir"' + am__tar_='pax -L -x $1 -w "$tardir"' + am__untar='pax -r' + ;; + cpio) + am__tar='find "$$tardir" -print | cpio -o -H $1 -L' + am__tar_='find "$tardir" -print | cpio -o -H $1 -L' + am__untar='cpio -i -H $1 -d' + ;; + none) + am__tar=false + am__tar_=false + am__untar=false + ;; + esac + + # If the value was cached, stop now. We just wanted to have am__tar + # and am__untar set. + test -n "${am_cv_prog_tar_$1}" && break + + # tar/untar a dummy directory, and stop if the command works. + rm -rf conftest.dir + mkdir conftest.dir + echo GrepMe > conftest.dir/file + AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) + rm -rf conftest.dir + if test -s conftest.tar; then + AM_RUN_LOG([$am__untar /dev/null 2>&1 && break + fi + done + rm -rf conftest.dir + + AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) + AC_MSG_RESULT([$am_cv_prog_tar_$1])]) + +AC_SUBST([am__tar]) +AC_SUBST([am__untar]) +]) # _AM_PROG_TAR + +m4_include([m4/libtool.m4]) +m4_include([m4/ltoptions.m4]) +m4_include([m4/ltsugar.m4]) +m4_include([m4/ltversion.m4]) +m4_include([m4/lt~obsolete.m4]) +m4_include([m4/pkg.m4]) diff --git a/libs/ode-0.16.1/bindings/python/INSTALL.txt b/libs/ode-0.16.1/bindings/python/INSTALL.txt new file mode 100644 index 0000000..a0ae378 --- /dev/null +++ b/libs/ode-0.16.1/bindings/python/INSTALL.txt @@ -0,0 +1,64 @@ +1. REQUIREMENTS: + +1. Python 2.4 or higher (http://www.python.org/) + - Tested with Python 2.7 (2.6 on earlier builds) +2. Cython 0.14.1** or higher (http://cython.org/) + - Tested with Cython 0.15 (0.14.1 on earlier builds) +3. ODE shared*** library (or static with -fPIC) + - See the notes on building ODE below. +4. pkg-config (http://www.freedesktop.org/wiki/Software/pkg-config) + - Windows executable (and GLib dependency) can be downloaded from + http://www.gtk.org/download/win32.php + - If you used premake to configure ODE, you may need to create an ode.pc file + in your PKG_CONFIG_PATH manually. See /ode.pc.in + + + +2. BUILDING ODE + + On certain systems (*nix) there is a requirement that a shared library + (such as the python module) contains only position-independent code + (PIC). In those cases, ODE needs to be either compiled as a shared library + too (--enable-shared), or as a static library with PIC (-fPIC). + + Once ODE is built and installed in your desired destination, proceed with + building the wrapper. + + + +3a. BUILDING WITH Visual Studio (Windows) + + python setup.py build_ext + + +3b. BUILDING WITH MINGW (Windows) + + python setup.py build_ext -c mingw32 + + +3c. BUILDING WITH GCC/G++ (Linux, OS X, etc.) + + python setup.py build_ext + + + +4. INSTALLATION + +4a. For system-wide installation (needs administrator privileges): + + python setup.py install + +4b. For user installation: + + python setup.py install --user + + + +5. DEMOS and DOCUMENTATION + + Try running the tutorials in the 'demos' directory. The tutorials were taken + from the PyODE website (http://pyode.sourceforge.net/). + + For usage documentation, please refer to the PyODE API documentation at + http://pyode.sourceforge.net/api-1.2.0/index.html. + diff --git a/libs/ode-0.16.1/bindings/python/TODO.txt b/libs/ode-0.16.1/bindings/python/TODO.txt new file mode 100644 index 0000000..356edc4 --- /dev/null +++ b/libs/ode-0.16.1/bindings/python/TODO.txt @@ -0,0 +1,15 @@ +CODE: +* (setup.py) add package information (version, authors, etc.) +* (setup.py) add 'install' action +* (setup.py) add configurable ODE DLL (currently hard-coded to default single precision) +* (ode.pxd) clean up, add more comments +* (ode.pyx) refactor for a more Pythonic implementation (e.g. replace getters and setters with + properties)? +* (?) Add option to build bindings in ODE's makefiles + + +DOCS: + +* Update and include API docs from PyODE +* Adapt and include PyODE tutorials/demos +* Update license text in ode.pxd and ode.pyx diff --git a/libs/ode-0.16.1/bindings/python/demos/tutorial1.py b/libs/ode-0.16.1/bindings/python/demos/tutorial1.py new file mode 100755 index 0000000..c4266d4 --- /dev/null +++ b/libs/ode-0.16.1/bindings/python/demos/tutorial1.py @@ -0,0 +1,49 @@ +#!/usr/bin/env python + +# http://pyode.sourceforge.net/tutorials/tutorial1.html + +# pyODE example 1: Getting started + +# modified by Gideon Klompje (removed literals and using +# 'ode.Mass.setSphereTotal' instead of 'ode.Mass.setSphere') + +import ode + +# Simulation constants +GRAVITY = (0, -9.81, 0) + +SPHERE_RADIUS = 0.05 +SPHERE_MASS = 1.0 +SPHERE_START_POS = (0, 2, 0) +SPHERE_FORCE = (0, 200, 0) # Initial force to apply to the sphere + +TIME_STEP = 0.04 +TIME_STOP = 2.0 # When to stop the simulation + +# Create a world object +world = ode.World() +world.setGravity(GRAVITY) + +# Create a spherical body inside the world +body = ode.Body(world) +mass = ode.Mass() +mass.setSphereTotal(SPHERE_MASS, SPHERE_RADIUS) +body.setMass(mass) + +body.setPosition(SPHERE_START_POS) +body.addForce(SPHERE_FORCE) + +# Do the simulation... +if __name__ == "__main__": + total_time = 0.0 + while total_time < TIME_STOP: + # output the body's position and velocity + x, y, z = body.getPosition() + u, v, w = body.getLinearVel() + print "%1.2fsec: pos=(%6.3f, %6.3f, %6.3f) vel=(%6.3f, %6.3f, %6.3f)" % \ + (total_time, x, y, z, u, v, w) + + # advance the simulation + world.step(TIME_STEP) + total_time += TIME_STEP + diff --git a/libs/ode-0.16.1/bindings/python/demos/tutorial2.py b/libs/ode-0.16.1/bindings/python/demos/tutorial2.py new file mode 100755 index 0000000..1a4a228 --- /dev/null +++ b/libs/ode-0.16.1/bindings/python/demos/tutorial2.py @@ -0,0 +1,135 @@ +#!/usr/bin/env python + +# http://pyode.sourceforge.net/tutorials/tutorial2.html + +# pyODE example 2: Connecting bodies with joints + +# modified by Gideon Klompje (removed literals and using +# 'ode.Mass.setSphereTotal' instead of 'ode.Mass.setSphere') + + +import ode +import pygame + +from pygame.locals import QUIT, KEYDOWN + +# Constants +WINDOW_RESOLUTION = (640, 480) + +DRAW_SCALE = WINDOW_RESOLUTION[0] / 5 +"""Factor to multiply physical coordinates by to obtain screen size in pixels""" + +DRAW_OFFSET = (WINDOW_RESOLUTION[0] / 2, 50) +"""Screen coordinates (in pixels) that map to the physical origin (0, 0, 0)""" + +BACKGROUND_COLOR = (255, 255, 255) + +GRAVITY = (0, -9.81, 0) + +SPHERE1_POSITION = (1, 0, 0) +SPHERE1_MASS = 1 +SPHERE1_RADIUS = 0.15 +SPHERE1_COLOR = (55, 0, 200) + +SPHERE2_POSITION = (2, 0, 0) +SPHERE2_MASS = 1 +SPHERE2_RADIUS = 0.15 +SPHERE2_COLOR = (55, 0, 200) + +JOINT1_ANCHOR = (0, 0, 0) +JOINT1_COLOR = (200, 0, 55) +JOINT1_WIDTH = 2 +"""Width of the line (in pixels) representing the joint""" + +JOINT2_ANCHOR = SPHERE1_POSITION +JOINT2_COLOR = (200, 0, 55) +JOINT2_WIDTH = 2 +"""Width of the line (in pixels) representing the joint""" + +TIME_STEP = 0.04 + +# Utility functions +def coord(x, y, integer=False): + """ + Convert world coordinates to pixel coordinates. Setting 'integer' to + True will return integer coordinates. + """ + xs = (DRAW_OFFSET[0] + DRAW_SCALE*x) + ys = (DRAW_OFFSET[1] - DRAW_SCALE*y) + + if integer: + return int(round(xs)), int(round(ys)) + else: + return xs, ys + +# Initialize pygame +pygame.init() + +# Open a display +screen = pygame.display.set_mode(WINDOW_RESOLUTION) + +# Create a world object +world = ode.World() +world.setGravity(GRAVITY) + +# Create two bodies +body1 = ode.Body(world) +M = ode.Mass() +M.setSphereTotal(SPHERE1_MASS, SPHERE1_RADIUS) +body1.setMass(M) +body1.setPosition(SPHERE1_POSITION) + +body2 = ode.Body(world) +M = ode.Mass() +M.setSphereTotal(SPHERE2_MASS, SPHERE2_RADIUS) +body2.setMass(M) +body2.setPosition(SPHERE2_POSITION) + +# Connect body1 with the static environment +j1 = ode.BallJoint(world) +j1.attach(body1, ode.environment) +j1.setAnchor(JOINT1_ANCHOR) + +# Connect body2 with body1 +j2 = ode.BallJoint(world) +j2.attach(body1, body2) +j2.setAnchor(JOINT2_ANCHOR) + +# Simulation loop... +if __name__ == "__main__": + fps = 1.0 / TIME_STEP + clk = pygame.time.Clock() + + sph1_rad = int(DRAW_SCALE * SPHERE1_RADIUS) + sph2_rad = int(DRAW_SCALE * SPHERE2_RADIUS) + + loopFlag = True + while loopFlag: + for e in pygame.event.get(): + if e.type==QUIT: + loopFlag=False + if e.type==KEYDOWN: + loopFlag=False + + # Clear the screen + screen.fill(BACKGROUND_COLOR) + + # Draw the two bodies and the lines representing the joints + x1, y1, z1 = body1.getPosition() + x2, y2, z2 = body2.getPosition() + xj1, yj1, zj1 = j1.getAnchor() + xj2, yj2, zj2 = j2.getAnchor() + + pygame.draw.line(screen, JOINT1_COLOR, coord(xj1, yj1), coord(x1, y1), JOINT1_WIDTH) + pygame.draw.line(screen, JOINT2_COLOR, coord(xj2, yj2), coord(x2, y2), JOINT2_WIDTH) + pygame.draw.circle(screen, SPHERE1_COLOR, coord(x1, y1, integer=True), sph1_rad, 0) + pygame.draw.circle(screen, SPHERE2_COLOR, coord(x2, y2, integer=True), sph2_rad, 0) + + pygame.display.flip() + + # Next simulation step + world.step(TIME_STEP) + + # Try to keep the specified framerate + clk.tick(fps) + diff --git a/libs/ode-0.16.1/bindings/python/demos/tutorial3.py b/libs/ode-0.16.1/bindings/python/demos/tutorial3.py new file mode 100644 index 0000000..2644d62 --- /dev/null +++ b/libs/ode-0.16.1/bindings/python/demos/tutorial3.py @@ -0,0 +1,284 @@ +#!/usr/bin/env python + +# http://pyode.sourceforge.net/tutorials/tutorial3.html + +# pyODE example 3: Collision detection + +# Originally by Matthias Baas. +# Updated by Pierre Gay to work without pygame or cgkit. + +import sys, os, random, time +from math import * +from OpenGL.GL import * +from OpenGL.GLU import * +from OpenGL.GLUT import * + +import ode + +# geometric utility functions +def scalp (vec, scal): + vec[0] *= scal + vec[1] *= scal + vec[2] *= scal + +def length (vec): + return sqrt (vec[0]**2 + vec[1]**2 + vec[2]**2) + +# prepare_GL +def prepare_GL(): + """Prepare drawing. + """ + + # Viewport + glViewport(0,0,640,480) + + # Initialize + glClearColor(0.8,0.8,0.9,0) + glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); + glEnable(GL_DEPTH_TEST) + glDisable(GL_LIGHTING) + glEnable(GL_LIGHTING) + glEnable(GL_NORMALIZE) + glShadeModel(GL_FLAT) + + # Projection + glMatrixMode(GL_PROJECTION) + glLoadIdentity() + gluPerspective (45,1.3333,0.2,20) + + # Initialize ModelView matrix + glMatrixMode(GL_MODELVIEW) + glLoadIdentity() + + # Light source + glLightfv(GL_LIGHT0,GL_POSITION,[0,0,1,0]) + glLightfv(GL_LIGHT0,GL_DIFFUSE,[1,1,1,1]) + glLightfv(GL_LIGHT0,GL_SPECULAR,[1,1,1,1]) + glEnable(GL_LIGHT0) + + # View transformation + gluLookAt (2.4, 3.6, 4.8, 0.5, 0.5, 0, 0, 1, 0) + +# draw_body +def draw_body(body): + """Draw an ODE body. + """ + + x,y,z = body.getPosition() + R = body.getRotation() + rot = [R[0], R[3], R[6], 0., + R[1], R[4], R[7], 0., + R[2], R[5], R[8], 0., + x, y, z, 1.0] + glPushMatrix() + glMultMatrixd(rot) + if body.shape=="box": + sx,sy,sz = body.boxsize + glScalef(sx, sy, sz) + glutSolidCube(1) + glPopMatrix() + + +# create_box +def create_box(world, space, density, lx, ly, lz): + """Create a box body and its corresponding geom.""" + + # Create body + body = ode.Body(world) + M = ode.Mass() + M.setBox(density, lx, ly, lz) + body.setMass(M) + + # Set parameters for drawing the body + body.shape = "box" + body.boxsize = (lx, ly, lz) + + # Create a box geom for collision detection + geom = ode.GeomBox(space, lengths=body.boxsize) + geom.setBody(body) + + return body, geom + +# drop_object +def drop_object(): + """Drop an object into the scene.""" + + global bodies, geom, counter, objcount + + body, geom = create_box(world, space, 1000, 1.0,0.2,0.2) + body.setPosition( (random.gauss(0,0.1),3.0,random.gauss(0,0.1)) ) + theta = random.uniform(0,2*pi) + ct = cos (theta) + st = sin (theta) + body.setRotation([ct, 0., -st, 0., 1., 0., st, 0., ct]) + bodies.append(body) + geoms.append(geom) + counter=0 + objcount+=1 + +# explosion +def explosion(): + """Simulate an explosion. + + Every object is pushed away from the origin. + The force is dependent on the objects distance from the origin. + """ + global bodies + + for b in bodies: + l=b.getPosition () + d = length (l) + a = max(0, 40000*(1.0-0.2*d*d)) + l = [l[0] / 4, l[1], l[2] /4] + scalp (l, a / length (l)) + b.addForce(l) + +# pull +def pull(): + """Pull the objects back to the origin. + + Every object will be pulled back to the origin. + Every couple of frames there'll be a thrust upwards so that + the objects won't stick to the ground all the time. + """ + global bodies, counter + + for b in bodies: + l=list (b.getPosition ()) + scalp (l, -1000 / length (l)) + b.addForce(l) + if counter%60==0: + b.addForce((0,10000,0)) + +# Collision callback +def near_callback(args, geom1, geom2): + """Callback function for the collide() method. + + This function checks if the given geoms do collide and + creates contact joints if they do. + """ + + # Check if the objects do collide + contacts = ode.collide(geom1, geom2) + + # Create contact joints + world,contactgroup = args + for c in contacts: + c.setBounce(0.2) + c.setMu(5000) + j = ode.ContactJoint(world, contactgroup, c) + j.attach(geom1.getBody(), geom2.getBody()) + + + +###################################################################### + +# Initialize Glut +glutInit ([]) + +# Open a window +glutInitDisplayMode (GLUT_RGB | GLUT_DEPTH | GLUT_DOUBLE) + +x = 0 +y = 0 +width = 640 +height = 480 +glutInitWindowPosition (x, y); +glutInitWindowSize (width, height); +glutCreateWindow ("testode") + +# Create a world object +world = ode.World() +world.setGravity( (0,-9.81,0) ) +world.setERP(0.8) +world.setCFM(1E-5) + +# Create a space object +space = ode.Space() + +# Create a plane geom which prevent the objects from falling forever +floor = ode.GeomPlane(space, (0,1,0), 0) + +# A list with ODE bodies +bodies = [] + +# The geoms for each of the bodies +geoms = [] + +# A joint group for the contact joints that are generated whenever +# two bodies collide +contactgroup = ode.JointGroup() + +# Some variables used inside the simulation loop +fps = 50 +dt = 1.0/fps +running = True +state = 0 +counter = 0 +objcount = 0 +lasttime = time.time() + + +# keyboard callback +def _keyfunc (c, x, y): + sys.exit (0) + +glutKeyboardFunc (_keyfunc) + +# draw callback +def _drawfunc (): + # Draw the scene + prepare_GL() + for b in bodies: + draw_body(b) + + glutSwapBuffers () + +glutDisplayFunc (_drawfunc) + +# idle callback +def _idlefunc (): + global counter, state, lasttime + + t = dt - (time.time() - lasttime) + if (t > 0): + time.sleep(t) + + counter += 1 + + if state==0: + if counter==20: + drop_object() + if objcount==30: + state=1 + counter=0 + # State 1: Explosion and pulling back the objects + elif state==1: + if counter==100: + explosion() + if counter>300: + pull() + if counter==500: + counter=20 + + glutPostRedisplay () + + # Simulate + n = 4 + + for i in range(n): + # Detect collisions and create contact joints + space.collide((world,contactgroup), near_callback) + + # Simulation step + world.step(dt/n) + + # Remove all contact joints + contactgroup.empty() + + lasttime = time.time() + +glutIdleFunc (_idlefunc) + +glutMainLoop () + diff --git a/libs/ode-0.16.1/bindings/python/ode.pxd b/libs/ode-0.16.1/bindings/python/ode.pxd new file mode 100644 index 0000000..10295c0 --- /dev/null +++ b/libs/ode-0.16.1/bindings/python/ode.pxd @@ -0,0 +1,503 @@ +###################################################################### +# Python Open Dynamics Engine Wrapper +# Copyright (C) 2004 PyODE developers (see file AUTHORS) +# All rights reserved. +# +# This library is free software; you can redistribute it and/or +# modify it under the terms of EITHER: +# (1) The GNU Lesser General Public License as published by the Free +# Software Foundation; either version 2.1 of the License, or (at +# your option) any later version. The text of the GNU Lesser +# General Public License is included with this library in the +# file LICENSE. +# (2) The BSD-style license that is included with this library in +# the file LICENSE-BSD. +# +# This library is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files +# LICENSE and LICENSE-BSD for more details. +###################################################################### + +cdef extern from "stdlib.h": + + void* malloc(long) + void free(void*) + +cdef extern from "stdio.h": + int printf(char*) + +# Include the basic floating point type -> dReal (either float or double) +#include "_precision.pyx" + +cdef extern from "ode/ode.h": + + ctypedef double dReal + + # Dummy structs + cdef struct dxWorld: + int _dummy + cdef struct dxSpace: + int _dummy + cdef struct dxBody: + int _dummy + cdef struct dxGeom: + int _dummy + cdef struct dxJoint: + int _dummy + cdef struct dxJointGroup: + int _dummy + cdef struct dxTriMeshData: + int _dummy + cdef struct dxHeightfieldData: + int _dummy + + # Types + ctypedef dxWorld* dWorldID + ctypedef dxSpace* dSpaceID + ctypedef dxBody* dBodyID + ctypedef dxGeom* dGeomID + ctypedef dxJoint* dJointID + ctypedef dxJointGroup* dJointGroupID + ctypedef dxTriMeshData* dTriMeshDataID + ctypedef dxHeightfieldData* dHeightfieldDataID + ctypedef dReal dVector3[4] + ctypedef dReal dVector4[4] + ctypedef dReal dMatrix3[4*3] + ctypedef dReal dMatrix4[4*4] + ctypedef dReal dMatrix6[8*6] + ctypedef dReal dQuaternion[4] + + cdef extern dReal dInfinity + cdef extern int dAMotorUser + cdef extern int dAMotorEuler + + ctypedef struct dMass: + dReal mass + dVector4 c + dMatrix3 I + + ctypedef struct dJointFeedback: + dVector3 f1 + dVector3 t1 + dVector3 f2 + dVector3 t2 + + ctypedef void dNearCallback(void* data, dGeomID o1, dGeomID o2) + ctypedef dReal dHeightfieldGetHeight( void* p_user_data, int x, int z ) + + ctypedef struct dSurfaceParameters: + int mode + dReal mu + + dReal mu2 + dReal bounce + dReal bounce_vel + dReal soft_erp + dReal soft_cfm + dReal motion1,motion2 + dReal slip1,slip2 + + ctypedef struct dContactGeom: + dVector3 pos + dVector3 normal + dReal depth + dGeomID g1,g2 + + ctypedef struct dContact: + dSurfaceParameters surface + dContactGeom geom + dVector3 fdir1 + + + # World + dWorldID dWorldCreate() + void dWorldDestroy (dWorldID) + + void dCloseODE() + void dInitODE() + + void dWorldSetGravity (dWorldID, dReal x, dReal y, dReal z) + void dWorldGetGravity (dWorldID, dVector3 gravity) + void dWorldSetERP (dWorldID, dReal erp) + dReal dWorldGetERP (dWorldID) + void dWorldSetCFM (dWorldID, dReal cfm) + dReal dWorldGetCFM (dWorldID) + void dWorldStep (dWorldID, dReal stepsize) + void dWorldQuickStep (dWorldID, dReal stepsize) + void dWorldSetQuickStepNumIterations (dWorldID, int num) + int dWorldGetQuickStepNumIterations (dWorldID) + void dWorldSetContactMaxCorrectingVel (dWorldID, dReal vel) + dReal dWorldGetContactMaxCorrectingVel (dWorldID) + void dWorldSetContactSurfaceLayer (dWorldID, dReal depth) + dReal dWorldGetContactSurfaceLayer (dWorldID) + void dWorldSetAutoDisableFlag (dWorldID, int do_auto_disable) + int dWorldGetAutoDisableFlag (dWorldID) + void dWorldSetAutoDisableLinearThreshold (dWorldID, dReal linear_threshold) + dReal dWorldGetAutoDisableLinearThreshold (dWorldID) + void dWorldSetAutoDisableAngularThreshold (dWorldID, dReal angular_threshold) + dReal dWorldGetAutoDisableAngularThreshold (dWorldID) + void dWorldSetAutoDisableSteps (dWorldID, int steps) + int dWorldGetAutoDisableSteps (dWorldID) + void dWorldSetAutoDisableTime (dWorldID, dReal time) + dReal dWorldGetAutoDisableTime (dWorldID) + dReal dWorldGetLinearDamping (dWorldID) + void dWorldSetLinearDamping (dWorldID, dReal scale) + dReal dWorldGetAngularDamping (dWorldID) + void dWorldSetAngularDamping (dWorldID, dReal scale) + void dWorldImpulseToForce (dWorldID, dReal stepsize, + dReal ix, dReal iy, dReal iz, dVector3 force) + + # Body + dBodyID dBodyCreate (dWorldID) + void dBodyDestroy (dBodyID) + + void dBodySetData (dBodyID, void *data) + void *dBodyGetData (dBodyID) + + void dBodySetPosition (dBodyID, dReal x, dReal y, dReal z) + void dBodySetRotation (dBodyID, dMatrix3 R) + void dBodySetQuaternion (dBodyID, dQuaternion q) + void dBodySetLinearVel (dBodyID, dReal x, dReal y, dReal z) + void dBodySetAngularVel (dBodyID, dReal x, dReal y, dReal z) + dReal * dBodyGetPosition (dBodyID) + dReal * dBodyGetRotation (dBodyID) + dReal * dBodyGetQuaternion (dBodyID) + dReal * dBodyGetLinearVel (dBodyID) + dReal * dBodyGetAngularVel (dBodyID) + + void dBodySetMass (dBodyID, dMass *mass) + void dBodyGetMass (dBodyID, dMass *mass) + + void dBodyAddForce (dBodyID, dReal fx, dReal fy, dReal fz) + void dBodyAddTorque (dBodyID, dReal fx, dReal fy, dReal fz) + void dBodyAddRelForce (dBodyID, dReal fx, dReal fy, dReal fz) + void dBodyAddRelTorque (dBodyID, dReal fx, dReal fy, dReal fz) + void dBodyAddForceAtPos (dBodyID, dReal fx, dReal fy, dReal fz, dReal px, dReal py, dReal pz) + void dBodyAddForceAtRelPos (dBodyID, dReal fx, dReal fy, dReal fz, dReal px, dReal py, dReal pz) + void dBodyAddRelForceAtPos (dBodyID, dReal fx, dReal fy, dReal fz, dReal px, dReal py, dReal pz) + void dBodyAddRelForceAtRelPos (dBodyID, dReal fx, dReal fy, dReal fz, dReal px, dReal py, dReal pz) + + dReal * dBodyGetForce (dBodyID) + dReal * dBodyGetTorque (dBodyID) + + void dBodySetForce(dBodyID, dReal x, dReal y, dReal z) + void dBodySetTorque(dBodyID, dReal x, dReal y, dReal z) + + void dBodyGetRelPointPos (dBodyID, dReal px, dReal py, dReal pz, dVector3 result) + void dBodyGetRelPointVel (dBodyID, dReal px, dReal py, dReal pz, dVector3 result) + void dBodyGetPointVel (dBodyID, dReal px, dReal py, dReal pz, + dVector3 result) + void dBodyGetPosRelPoint (dBodyID, dReal px, dReal py, dReal pz, + dVector3 result) + void dBodyVectorToWorld (dBodyID, dReal px, dReal py, dReal pz, + dVector3 result) + void dBodyVectorFromWorld (dBodyID, dReal px, dReal py, dReal pz, + dVector3 result) + + void dBodySetFiniteRotationMode (dBodyID, int mode) + void dBodySetFiniteRotationAxis (dBodyID, dReal x, dReal y, dReal z) + + int dBodyGetFiniteRotationMode (dBodyID) + void dBodyGetFiniteRotationAxis (dBodyID, dVector3 result) + + int dBodyGetNumJoints (dBodyID b) + dJointID dBodyGetJoint (dBodyID, int index) + + void dBodyEnable (dBodyID) + void dBodyDisable (dBodyID) + int dBodyIsEnabled (dBodyID) + + void dBodySetGravityMode (dBodyID b, int mode) + int dBodyGetGravityMode (dBodyID b) + + void dBodySetDynamic (dBodyID) + void dBodySetKinematic (dBodyID) + int dBodyIsKinematic (dBodyID) + + void dBodySetMaxAngularSpeed (dBodyID, dReal max_speed) + + # Joints + dJointID dJointCreateBall (dWorldID, dJointGroupID) + dJointID dJointCreateHinge (dWorldID, dJointGroupID) + dJointID dJointCreateSlider (dWorldID, dJointGroupID) + dJointID dJointCreateContact (dWorldID, dJointGroupID, dContact *) + dJointID dJointCreateUniversal (dWorldID, dJointGroupID) + dJointID dJointCreatePR (dWorldID, dJointGroupID) + dJointID dJointCreateHinge2 (dWorldID, dJointGroupID) + dJointID dJointCreateFixed (dWorldID, dJointGroupID) + dJointID dJointCreateNull (dWorldID, dJointGroupID) + dJointID dJointCreateAMotor (dWorldID, dJointGroupID) + dJointID dJointCreateLMotor (dWorldID, dJointGroupID) + dJointID dJointCreatePlane2D (dWorldID, dJointGroupID) + + void dJointDestroy (dJointID) + + void dJointEnable (dJointID) + void dJointDisable (dJointID) + int dJointIsEnabled (dJointID) + + dJointGroupID dJointGroupCreate (int max_size) + void dJointGroupDestroy (dJointGroupID) + void dJointGroupEmpty (dJointGroupID) + + void dJointAttach (dJointID, dBodyID body1, dBodyID body2) + void dJointSetData (dJointID, void *data) + void *dJointGetData (dJointID) + int dJointGetType (dJointID) + dBodyID dJointGetBody (dJointID, int index) + + void dJointSetBallAnchor (dJointID, dReal x, dReal y, dReal z) + void dJointSetHingeAnchor (dJointID, dReal x, dReal y, dReal z) + void dJointSetHingeAxis (dJointID, dReal x, dReal y, dReal z) + void dJointSetHingeParam (dJointID, int parameter, dReal value) + void dJointAddHingeTorque(dJointID joint, dReal torque) + void dJointSetSliderAxis (dJointID, dReal x, dReal y, dReal z) + void dJointSetSliderParam (dJointID, int parameter, dReal value) + void dJointAddSliderForce(dJointID joint, dReal force) + void dJointSetHinge2Anchor (dJointID, dReal x, dReal y, dReal z) + void dJointSetHinge2Axis1 (dJointID, dReal x, dReal y, dReal z) + void dJointSetHinge2Axis2 (dJointID, dReal x, dReal y, dReal z) + void dJointSetHinge2Param (dJointID, int parameter, dReal value) + void dJointAddHinge2Torques(dJointID joint, dReal torque1, dReal torque2) + void dJointSetUniversalAnchor (dJointID, dReal x, dReal y, dReal z) + void dJointSetUniversalAxis1 (dJointID, dReal x, dReal y, dReal z) + void dJointSetUniversalAxis2 (dJointID, dReal x, dReal y, dReal z) + void dJointSetUniversalParam (dJointID, int parameter, dReal value) + void dJointAddUniversalTorques(dJointID joint, dReal torque1, dReal torque2) + void dJointSetFixed (dJointID) + void dJointSetAMotorNumAxes (dJointID, int num) + void dJointSetAMotorAxis (dJointID, int anum, int rel, dReal x, dReal y, dReal z) + void dJointSetAMotorAngle (dJointID, int anum, dReal angle) + void dJointSetAMotorParam (dJointID, int parameter, dReal value) + void dJointSetAMotorMode (dJointID, int mode) + void dJointAddAMotorTorques (dJointID, dReal torque1, dReal torque2, dReal torque3) + void dJointSetLMotorAxis (dJointID, int anum, int rel, dReal x, dReal y, dReal z) + void dJointSetLMotorNumAxes (dJointID, int num) + void dJointSetLMotorParam (dJointID, int parameter, dReal value) + + void dJointGetBallAnchor (dJointID, dVector3 result) + void dJointGetBallAnchor2 (dJointID, dVector3 result) + void dJointGetHingeAnchor (dJointID, dVector3 result) + void dJointGetHingeAnchor2 (dJointID, dVector3 result) + void dJointGetHingeAxis (dJointID, dVector3 result) + dReal dJointGetHingeParam (dJointID, int parameter) + dReal dJointGetHingeAngle (dJointID) + dReal dJointGetHingeAngleRate (dJointID) + dReal dJointGetSliderPosition (dJointID) + dReal dJointGetSliderPositionRate (dJointID) + void dJointGetSliderAxis (dJointID, dVector3 result) + dReal dJointGetSliderParam (dJointID, int parameter) + void dJointGetHinge2Anchor (dJointID, dVector3 result) + void dJointGetHinge2Anchor2 (dJointID, dVector3 result) + void dJointGetHinge2Axis1 (dJointID, dVector3 result) + void dJointGetHinge2Axis2 (dJointID, dVector3 result) + dReal dJointGetHinge2Param (dJointID, int parameter) + dReal dJointGetHinge2Angle1 (dJointID) + dReal dJointGetHinge2Angle1Rate (dJointID) + dReal dJointGetHinge2Angle2Rate (dJointID) + void dJointGetUniversalAnchor (dJointID, dVector3 result) + void dJointGetUniversalAnchor2 (dJointID, dVector3 result) + void dJointGetUniversalAxis1 (dJointID, dVector3 result) + void dJointGetUniversalAxis2 (dJointID, dVector3 result) + dReal dJointGetUniversalParam (dJointID, int parameter) + dReal dJointGetUniversalAngle1 (dJointID) + dReal dJointGetUniversalAngle2 (dJointID) + dReal dJointGetUniversalAngle1Rate (dJointID) + dReal dJointGetUniversalAngle2Rate (dJointID) + int dJointGetAMotorNumAxes (dJointID) + void dJointGetAMotorAxis (dJointID, int anum, dVector3 result) + int dJointGetAMotorAxisRel (dJointID, int anum) + dReal dJointGetAMotorAngle (dJointID, int anum) + dReal dJointGetAMotorAngleRate (dJointID, int anum) + dReal dJointGetAMotorParam (dJointID, int parameter) + int dJointGetAMotorMode (dJointID) + int dJointGetLMotorNumAxes (dJointID) + void dJointGetLMotorAxis (dJointID, int anum, dVector3 result) + dReal dJointGetLMotorParam (dJointID, int parameter) + void dJointSetPlane2DXParam (dJointID, int parameter, dReal value) + void dJointSetPlane2DYParam (dJointID, int parameter, dReal value) + void dJointSetPlane2DAngleParam (dJointID, int parameter, dReal value) + dReal dJointGetPRPosition (dJointID j) + void dJointSetPRAnchor (dJointID j, dReal x, dReal y, dReal z) + void dJointSetPRAxis1 (dJointID j, dReal x, dReal y, dReal z) + void dJointSetPRAxis2 (dJointID j, dReal x, dReal y, dReal z) + void dJointGetPRAnchor (dJointID j, dVector3 result) + void dJointGetPRAxis1 (dJointID j, dVector3 result) + void dJointGetPRAxis2 (dJointID j, dVector3 result) + + void dJointSetFeedback (dJointID, dJointFeedback *) + dJointFeedback *dJointGetFeedback (dJointID) + + int dAreConnected (dBodyID, dBodyID) + + # Mass + void dMassSetZero (dMass *) + void dMassSetParameters (dMass *, dReal themass, + dReal cgx, dReal cgy, dReal cgz, + dReal I11, dReal I22, dReal I33, + dReal I12, dReal I13, dReal I23) + void dMassSetSphere (dMass *, dReal density, dReal radius) + void dMassSetSphereTotal (dMass *, dReal total_mass, dReal radius) + void dMassSetCapsule (dMass *, dReal density, int direction, dReal radius, dReal length) + void dMassSetCapsuleTotal (dMass *, dReal total_mass, int direction, dReal radius, dReal length) + void dMassSetCylinder (dMass *, dReal density, int direction, + dReal radius, dReal length) + void dMassSetCylinderTotal (dMass *, dReal total_mass, int direction, + dReal radius, dReal length) + void dMassSetBox (dMass *, dReal density, + dReal lx, dReal ly, dReal lz) + void dMassSetBoxTotal (dMass *, dReal total_mass, + dReal lx, dReal ly, dReal lz) + void dMassAdjust (dMass *, dReal newmass) + void dMassTranslate (dMass *, dReal x, dReal y, dReal z) + void dMassRotate (dMass *, dMatrix3 R) + void dMassAdd (dMass *a, dMass *b) + + # Space +# dSpaceID dSimpleSpaceCreate(int space) +# dSpaceID dHashSpaceCreate(int space) + dSpaceID dSimpleSpaceCreate(dSpaceID space) + dSpaceID dHashSpaceCreate(dSpaceID space) + dSpaceID dQuadTreeSpaceCreate (dSpaceID space, dVector3 Center, + dVector3 Extents, int Depth) + + void dSpaceDestroy (dSpaceID) + void dSpaceAdd (dSpaceID, dGeomID) + void dSpaceRemove (dSpaceID, dGeomID) + int dSpaceQuery (dSpaceID, dGeomID) + void dSpaceCollide (dSpaceID space, void *data, dNearCallback *callback) + void dSpaceCollide2 (dGeomID o1, dGeomID o2, void *data, dNearCallback *callback) + + void dHashSpaceSetLevels (dSpaceID space, int minlevel, int maxlevel) + void dHashSpaceGetLevels (dSpaceID space, int *minlevel, int *maxlevel) + + void dSpaceSetCleanup (dSpaceID space, int mode) + int dSpaceGetCleanup (dSpaceID space) + + int dSpaceGetNumGeoms (dSpaceID) + dGeomID dSpaceGetGeom (dSpaceID, int i) + + # Geom + dGeomID dCreateSphere (dSpaceID space, dReal radius) + dGeomID dCreateBox (dSpaceID space, dReal lx, dReal ly, dReal lz) + dGeomID dCreatePlane (dSpaceID space, dReal a, dReal b, dReal c, dReal d) + dGeomID dCreateCapsule (dSpaceID space, dReal radius, dReal length) + dGeomID dCreateCylinder (dSpaceID space, dReal radius, dReal length) + dGeomID dCreateGeomGroup (dSpaceID space) + + void dGeomSphereSetRadius (dGeomID sphere, dReal radius) + void dGeomBoxSetLengths (dGeomID box, dReal lx, dReal ly, dReal lz) + void dGeomPlaneSetParams (dGeomID plane, dReal a, dReal b, dReal c, dReal d) + void dGeomCapsuleSetParams (dGeomID ccylinder, dReal radius, dReal length) + void dGeomCylinderSetParams (dGeomID ccylinder, dReal radius, dReal length) + + dReal dGeomSphereGetRadius (dGeomID sphere) + void dGeomBoxGetLengths (dGeomID box, dVector3 result) + void dGeomPlaneGetParams (dGeomID plane, dVector4 result) + void dGeomCapsuleGetParams (dGeomID ccylinder, dReal *radius, dReal *length) + void dGeomCylinderGetParams (dGeomID ccylinder, dReal *radius, dReal *length) + + dReal dGeomSpherePointDepth (dGeomID sphere, dReal x, dReal y, dReal z) + dReal dGeomBoxPointDepth (dGeomID box, dReal x, dReal y, dReal z) + dReal dGeomPlanePointDepth (dGeomID plane, dReal x, dReal y, dReal z) + dReal dGeomCapsulePointDepth (dGeomID ccylinder, dReal x, dReal y, dReal z) + + dGeomID dCreateRay (dSpaceID space, dReal length) + void dGeomRaySetLength (dGeomID ray, dReal length) + dReal dGeomRayGetLength (dGeomID ray) + void dGeomRaySet (dGeomID ray, dReal px, dReal py, dReal pz, + dReal dx, dReal dy, dReal dz) + void dGeomRayGet (dGeomID ray, dVector3 start, dVector3 dir) + + void dGeomSetData (dGeomID, void *) + void *dGeomGetData (dGeomID) + void dGeomSetBody (dGeomID, dBodyID) + dBodyID dGeomGetBody (dGeomID) + void dGeomSetPosition (dGeomID, dReal x, dReal y, dReal z) + void dGeomSetRotation (dGeomID, dMatrix3 R) + void dGeomSetQuaternion (dGeomID, dQuaternion) + dReal * dGeomGetPosition (dGeomID) + dReal * dGeomGetRotation (dGeomID) + void dGeomGetQuaternion (dGeomID, dQuaternion result) + void dGeomSetOffsetPosition (dGeomID, dReal x, dReal y, dReal z) + void dGeomSetOffsetRotation (dGeomID, dMatrix3 R) + void dGeomClearOffset (dGeomID) + dReal * dGeomGetOffsetPosition (dGeomID) + dReal * dGeomGetOffsetRotation (dGeomID) + void dGeomDestroy (dGeomID) + void dGeomGetAABB (dGeomID, dReal aabb[6]) + dReal *dGeomGetSpaceAABB (dGeomID) + int dGeomIsSpace (dGeomID) + dSpaceID dGeomGetSpace (dGeomID) + int dGeomGetClass (dGeomID) + + void dGeomSetCategoryBits(dGeomID, unsigned long bits) + void dGeomSetCollideBits(dGeomID, unsigned long bits) + unsigned long dGeomGetCategoryBits(dGeomID) + unsigned long dGeomGetCollideBits(dGeomID) + + void dGeomEnable (dGeomID) + void dGeomDisable (dGeomID) + int dGeomIsEnabled (dGeomID) + + void dGeomGroupAdd (dGeomID group, dGeomID x) + void dGeomGroupRemove (dGeomID group, dGeomID x) + int dGeomGroupGetNumGeoms (dGeomID group) + dGeomID dGeomGroupGetGeom (dGeomID group, int i) + + dGeomID dCreateGeomTransform (dSpaceID space) + void dGeomTransformSetGeom (dGeomID g, dGeomID obj) + dGeomID dGeomTransformGetGeom (dGeomID g) + void dGeomTransformSetCleanup (dGeomID g, int mode) + int dGeomTransformGetCleanup (dGeomID g) + void dGeomTransformSetInfo (dGeomID g, int mode) + int dGeomTransformGetInfo (dGeomID g) + + int dCollide (dGeomID o1, dGeomID o2, int flags, dContactGeom *contact, int skip) + + # Trimesh + dTriMeshDataID dGeomTriMeshDataCreate() + void dGeomTriMeshDataDestroy(dTriMeshDataID g) + void dGeomTriMeshDataBuildSingle1 (dTriMeshDataID g, void* Vertices, + int VertexStride, int VertexCount, + void* Indices, int IndexCount, + int TriStride, void* Normals) + + void dGeomTriMeshDataBuildSimple(dTriMeshDataID g, + dReal* Vertices, int VertexCount, + int* Indices, int IndexCount) + + dGeomID dCreateTriMesh (dSpaceID space, dTriMeshDataID Data, + void* Callback, + void* ArrayCallback, + void* RayCallback) + + void dGeomTriMeshSetData (dGeomID g, dTriMeshDataID Data) + + void dGeomTriMeshClearTCCache (dGeomID g) + + void dGeomTriMeshGetTriangle (dGeomID g, int Index, dVector3 *v0, + dVector3 *v1, dVector3 *v2) + + int dGeomTriMeshGetTriangleCount (dGeomID g) + + void dGeomTriMeshGetPoint (dGeomID g, int Index, dReal u, dReal v, + dVector3 Out) + + void dGeomTriMeshEnableTC(dGeomID g, int geomClass, int enable) + int dGeomTriMeshIsTCEnabled(dGeomID g, int geomClass) + + # Heightfield + dHeightfieldDataID dGeomHeightfieldDataCreate() + void dGeomHeightfieldDataDestroy(dHeightfieldDataID g) + void dGeomHeightfieldDataBuildCallback(dHeightfieldDataID d, + void* pUserData, + dHeightfieldGetHeight* pCallback, + dReal width, dReal depth, + int widthSamples, int depthSamples, + dReal scale, dReal offset, + dReal thickness, int bWrap) + dGeomID dCreateHeightfield (dSpaceID space, dHeightfieldDataID data, + int bPlaceable) + diff --git a/libs/ode-0.16.1/bindings/python/ode.pyx b/libs/ode-0.16.1/bindings/python/ode.pyx new file mode 100644 index 0000000..92068f2 --- /dev/null +++ b/libs/ode-0.16.1/bindings/python/ode.pyx @@ -0,0 +1,4506 @@ +###################################################################### +# Python Open Dynamics Engine Wrapper +# Copyright (C) 2004 PyODE developers (see file AUTHORS) +# All rights reserved. +# +# This library is free software; you can redistribute it and/or +# modify it under the terms of EITHER: +# (1) The GNU Lesser General Public License as published by the Free +# Software Foundation; either version 2.1 of the License, or (at +# your option) any later version. The text of the GNU Lesser +# General Public License is included with this library in the +# file LICENSE. +# (2) The BSD-style license that is included with this library in +# the file LICENSE-BSD. +# +# This library is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files +# LICENSE and LICENSE-BSD for more details. +###################################################################### + +from ode cimport * + + +paramLoStop = 0 +paramHiStop = 1 +paramVel = 2 +paramLoVel = 3 +paramHiVel = 4 +paramFMax = 5 +paramFudgeFactor = 6 +paramBounce = 7 +paramCFM = 8 +paramStopERP = 9 +paramStopCFM = 10 +paramSuspensionERP = 11 +paramSuspensionCFM = 12 +paramERP = 13 + +ParamLoStop = 0 +ParamHiStop = 1 +ParamVel = 2 +ParamLoVel = 3 +ParamHiVel = 4 +ParamFMax = 5 +ParamFudgeFactor = 6 +ParamBounce = 7 +ParamCFM = 8 +ParamStopERP = 9 +ParamStopCFM = 10 +ParamSuspensionERP = 11 +ParamSuspensionCFM = 12 +ParamERP = 13 + +ParamLoStop2 = 256 + 0 +ParamHiStop2 = 256 + 1 +ParamVel2 = 256 + 2 +ParamLoVel2 = 256 + 3 +ParamHiVel2 = 256 + 4 +ParamFMax2 = 256 + 5 +ParamFudgeFactor2 = 256 + 6 +ParamBounce2 = 256 + 7 +ParamCFM2 = 256 + 8 +ParamStopERP2 = 256 + 9 +ParamStopCFM2 = 256 + 10 +ParamSuspensionERP2 = 256 + 11 +ParamSuspensionCFM2 = 256 + 12 +ParamERP2 = 256 + 13 + +ParamLoStop3 = 512 + 0 +ParamHiStop3 = 512 + 1 +ParamVel3 = 512 + 2 +ParamLoVel3 = 512 + 3 +ParamHiVel3 = 512 + 4 +ParamFMax3 = 512 + 5 +ParamFudgeFactor3 = 512 + 6 +ParamBounce3 = 512 + 7 +ParamCFM3 = 512 + 8 +ParamStopERP3 = 512 + 9 +ParamStopCFM3 = 512 + 10 +ParamSuspensionERP3 = 512 + 11 +ParamSuspensionCFM3 = 512 + 12 +ParamERP3 = 512 + 13 + +ParamGroup = 256 + +ContactMu2 = 0x001 +ContactAxisDep = 0x001 +ContactFDir1 = 0x002 +ContactBounce = 0x004 +ContactSoftERP = 0x008 +ContactSoftCFM = 0x010 +ContactMotion1 = 0x020 +ContactMotion2 = 0x040 +ContactMotionN = 0x080 +ContactSlip1 = 0x100 +ContactSlip2 = 0x200 +ContactRolling = 0x400 + +ContactApprox0 = 0x0000 +ContactApprox1_1 = 0x1000 +ContactApprox1_2 = 0x2000 +ContactApprox1_N = 0x4000 +ContactApprox1 = 0x7000 + +AMotorUser = dAMotorUser +AMotorEuler = dAMotorEuler + +Infinity = dInfinity + + +import weakref +_geom_c2py_lut = weakref.WeakValueDictionary() + + +cdef class Mass: + """Mass parameters of a rigid body. + + This class stores mass parameters of a rigid body which can be + accessed through the following attributes: + + - mass: The total mass of the body (float) + - c: The center of gravity position in body frame (3-tuple of floats) + - I: The 3x3 inertia tensor in body frame (3-tuple of 3-tuples) + + This class wraps the dMass structure from the C API. + + @ivar mass: The total mass of the body + @ivar c: The center of gravity position in body frame (cx, cy, cz) + @ivar I: The 3x3 inertia tensor in body frame ((I11, I12, I13), (I12, I22, I23), (I13, I23, I33)) + @type mass: float + @type c: 3-tuple of floats + @type I: 3-tuple of 3-tuples of floats + """ + cdef dMass _mass + + def __cinit__(self): + dMassSetZero(&self._mass) + + def setZero(self): + """setZero() + + Set all the mass parameters to zero.""" + dMassSetZero(&self._mass) + + def setParameters(self, mass, cgx, cgy, cgz, I11, I22, I33, I12, I13, I23): + """setParameters(mass, cgx, cgy, cgz, I11, I22, I33, I12, I13, I23) + + Set the mass parameters to the given values. + + @param mass: Total mass of the body. + @param cgx: Center of gravity position in the body frame (x component). + @param cgy: Center of gravity position in the body frame (y component). + @param cgz: Center of gravity position in the body frame (z component). + @param I11: Inertia tensor + @param I22: Inertia tensor + @param I33: Inertia tensor + @param I12: Inertia tensor + @param I13: Inertia tensor + @param I23: Inertia tensor + @type mass: float + @type cgx: float + @type cgy: float + @type cgz: float + @type I11: float + @type I22: float + @type I33: float + @type I12: float + @type I13: float + @type I23: float + """ + dMassSetParameters(&self._mass, mass, cgx, cgy, cgz, + I11, I22, I33, I12, I13, I23) + + def setSphere(self, density, radius): + """setSphere(density, radius) + + Set the mass parameters to represent a sphere of the given radius + and density, with the center of mass at (0,0,0) relative to the body. + + @param density: The density of the sphere + @param radius: The radius of the sphere + @type density: float + @type radius: float + """ + dMassSetSphere(&self._mass, density, radius) + + def setSphereTotal(self, total_mass, radius): + """setSphereTotal(total_mass, radius) + + Set the mass parameters to represent a sphere of the given radius + and mass, with the center of mass at (0,0,0) relative to the body. + + @param total_mass: The total mass of the sphere + @param radius: The radius of the sphere + @type total_mass: float + @type radius: float + """ + dMassSetSphereTotal(&self._mass, total_mass, radius) + + def setCapsule(self, density, direction, radius, length): + """setCapsule(density, direction, radius, length) + + Set the mass parameters to represent a capsule of the given parameters + and density, with the center of mass at (0,0,0) relative to the body. + The radius of the cylinder (and the spherical cap) is radius. The length + of the cylinder (not counting the spherical cap) is length. The + cylinder's long axis is oriented along the body's x, y or z axis + according to the value of direction (1=x, 2=y, 3=z). The first function + accepts the density of the object, the second accepts its total mass. + + @param density: The density of the capsule + @param direction: The direction of the capsule's cylinder (1=x axis, 2=y axis, 3=z axis) + @param radius: The radius of the capsule's cylinder + @param length: The length of the capsule's cylinder (without the caps) + @type density: float + @type direction: int + @type radius: float + @type length: float + """ + dMassSetCapsule(&self._mass, density, direction, radius, length) + + def setCapsuleTotal(self, total_mass, direction, radius, length): + """setCapsuleTotal(total_mass, direction, radius, length) + + Set the mass parameters to represent a capsule of the given parameters + and mass, with the center of mass at (0,0,0) relative to the body. The + radius of the cylinder (and the spherical cap) is radius. The length of + the cylinder (not counting the spherical cap) is length. The cylinder's + long axis is oriented along the body's x, y or z axis according to the + value of direction (1=x, 2=y, 3=z). The first function accepts the + density of the object, the second accepts its total mass. + + @param total_mass: The total mass of the capsule + @param direction: The direction of the capsule's cylinder (1=x axis, 2=y axis, 3=z axis) + @param radius: The radius of the capsule's cylinder + @param length: The length of the capsule's cylinder (without the caps) + @type total_mass: float + @type direction: int + @type radius: float + @type length: float + """ + dMassSetCapsuleTotal(&self._mass, total_mass, direction, + radius, length) + + def setCylinder(self, density, direction, r, h): + """setCylinder(density, direction, r, h) + + Set the mass parameters to represent a flat-ended cylinder of + the given parameters and density, with the center of mass at + (0,0,0) relative to the body. The radius of the cylinder is r. + The length of the cylinder is h. The cylinder's long axis is + oriented along the body's x, y or z axis according to the value + of direction (1=x, 2=y, 3=z). + + @param density: The density of the cylinder + @param direction: The direction of the cylinder (1=x axis, 2=y axis, 3=z axis) + @param r: The radius of the cylinder + @param h: The length of the cylinder + @type density: float + @type direction: int + @type r: float + @type h: float + """ + dMassSetCylinder(&self._mass, density, direction, r, h) + + def setCylinderTotal(self, total_mass, direction, r, h): + """setCylinderTotal(total_mass, direction, r, h) + + Set the mass parameters to represent a flat-ended cylinder of + the given parameters and mass, with the center of mass at + (0,0,0) relative to the body. The radius of the cylinder is r. + The length of the cylinder is h. The cylinder's long axis is + oriented along the body's x, y or z axis according to the value + of direction (1=x, 2=y, 3=z). + + @param total_mass: The total mass of the cylinder + @param direction: The direction of the cylinder (1=x axis, 2=y axis, 3=z axis) + @param r: The radius of the cylinder + @param h: The length of the cylinder + @type total_mass: float + @type direction: int + @type r: float + @type h: float + """ + dMassSetCylinderTotal(&self._mass, total_mass, direction, r, h) + + def setBox(self, density, lx, ly, lz): + """setBox(density, lx, ly, lz) + + Set the mass parameters to represent a box of the given + dimensions and density, with the center of mass at (0,0,0) + relative to the body. The side lengths of the box along the x, + y and z axes are lx, ly and lz. + + @param density: The density of the box + @param lx: The length along the x axis + @param ly: The length along the y axis + @param lz: The length along the z axis + @type density: float + @type lx: float + @type ly: float + @type lz: float + """ + dMassSetBox(&self._mass, density, lx, ly, lz) + + def setBoxTotal(self, total_mass, lx, ly, lz): + """setBoxTotal(total_mass, lx, ly, lz) + + Set the mass parameters to represent a box of the given + dimensions and mass, with the center of mass at (0,0,0) + relative to the body. The side lengths of the box along the x, + y and z axes are lx, ly and lz. + + @param total_mass: The total mass of the box + @param lx: The length along the x axis + @param ly: The length along the y axis + @param lz: The length along the z axis + @type total_mass: float + @type lx: float + @type ly: float + @type lz: float + """ + dMassSetBoxTotal(&self._mass, total_mass, lx, ly, lz) + + def adjust(self, newmass): + """adjust(newmass) + + Adjust the total mass. Given mass parameters for some object, + adjust them so the total mass is now newmass. This is useful + when using the setXyz() methods to set the mass parameters for + certain objects - they take the object density, not the total + mass. + + @param newmass: The new total mass + @type newmass: float + """ + dMassAdjust(&self._mass, newmass) + + def translate(self, t): + """translate(t) + + Adjust mass parameters. Given mass parameters for some object, + adjust them to represent the object displaced by (x,y,z) + relative to the body frame. + + @param t: Translation vector (x, y, z) + @type t: 3-tuple of floats + """ + dMassTranslate(&self._mass, t[0], t[1], t[2]) + +# def rotate(self, R): +# """ +# Given mass parameters for some object, adjust them to +# represent the object rotated by R relative to the body frame. +# """ +# pass + + def add(self, Mass b): + """add(b) + + Add the mass b to the mass object. Masses can also be added using + the + operator. + + @param b: The mass to add to this mass + @type b: Mass + """ + dMassAdd(&self._mass, &b._mass) + + def __getattr__(self, name): + if name == "mass": + return self._mass.mass + elif name == "c": + return self._mass.c[0], self._mass.c[1], self._mass.c[2] + elif name == "I": + return ((self._mass.I[0], self._mass.I[1], self._mass.I[2]), + (self._mass.I[4], self._mass.I[5], self._mass.I[6]), + (self._mass.I[8], self._mass.I[9], self._mass.I[10])) + else: + raise AttributeError("Mass object has no attribute '%s'" % name) + + def __setattr__(self, name, value): + if name == "mass": + self.adjust(value) + elif name == "c": + raise AttributeError("Use the setParameter() method to change c") + elif name == "I": + raise AttributeError("Use the setParameter() method to change I") + else: + raise AttributeError("Mass object has no attribute '%s" % name) + + def __add__(self, Mass b): + self.add(b) + return self + + def __str__(self): + m = str(self._mass.mass) + sc0 = str(self._mass.c[0]) + sc1 = str(self._mass.c[1]) + sc2 = str(self._mass.c[2]) + I11 = str(self._mass.I[0]) + I22 = str(self._mass.I[5]) + I33 = str(self._mass.I[10]) + I12 = str(self._mass.I[1]) + I13 = str(self._mass.I[2]) + I23 = str(self._mass.I[6]) + return ("Mass=%s\n" + "Cg=(%s, %s, %s)\n" + "I11=%s I22=%s I33=%s\n" + "I12=%s I13=%s I23=%s" % + (m, sc0, sc1, sc2, I11, I22, I33, I12, I13, I23)) +# return ("Mass=%s / " +# "Cg=(%s, %s, %s) / " +# "I11=%s I22=%s I33=%s " +# "I12=%s I13=%s I23=%s" % +# (m, sc0, sc1, sc2, I11, I22, I33, I12, I13, I23)) + + +cdef class Contact: + """This class represents a contact between two bodies in one point. + + A Contact object stores all the input parameters for a ContactJoint. + This class wraps the ODE dContact structure which has 3 components:: + + struct dContact { + dSurfaceParameters surface; + dContactGeom geom; + dVector3 fdir1; + }; + + This wrapper class provides methods to get and set the items of those + structures. + """ + + cdef dContact _contact + + def __cinit__(self): + self._contact.surface.mode = ContactBounce + self._contact.surface.mu = dInfinity + + self._contact.surface.bounce = 0.1 + + # getMode + def getMode(self): + """getMode() -> flags + + Return the contact flags. + """ + return self._contact.surface.mode + + # setMode + def setMode(self, flags): + """setMode(flags) + + Set the contact flags. The argument m is a combination of the + ContactXyz flags (ContactMu2, ContactBounce, ...). + + @param flags: Contact flags + @type flags: int + """ + self._contact.surface.mode = flags + + # getMu + def getMu(self): + """getMu() -> float + + Return the Coulomb friction coefficient. + """ + return self._contact.surface.mu + + # setMu + def setMu(self, mu): + """setMu(mu) + + Set the Coulomb friction coefficient. + + @param mu: Coulomb friction coefficient (0..Infinity) + @type mu: float + """ + self._contact.surface.mu = mu + + # getMu2 + def getMu2(self): + """getMu2() -> float + + Return the optional Coulomb friction coefficient for direction 2. + """ + return self._contact.surface.mu2 + + # setMu2 + def setMu2(self, mu): + """setMu2(mu) + + Set the optional Coulomb friction coefficient for direction 2. + + @param mu: Coulomb friction coefficient (0..Infinity) + @type mu: float + """ + self._contact.surface.mu2 = mu + + # getBounce + def getBounce(self): + """getBounce() -> float + + Return the restitution parameter. + """ + return self._contact.surface.bounce + + # setBounce + def setBounce(self, b): + """setBounce(b) + + @param b: Restitution parameter (0..1) + @type b: float + """ + self._contact.surface.bounce = b + + # getBounceVel + def getBounceVel(self): + """getBounceVel() -> float + + Return the minimum incoming velocity necessary for bounce. + """ + return self._contact.surface.bounce_vel + + # setBounceVel + def setBounceVel(self, bv): + """setBounceVel(bv) + + Set the minimum incoming velocity necessary for bounce. Incoming + velocities below this will effectively have a bounce parameter of 0. + + @param bv: Velocity + @type bv: float + """ + self._contact.surface.bounce_vel = bv + + # getSoftERP + def getSoftERP(self): + """getSoftERP() -> float + + Return the contact normal "softness" parameter. + """ + return self._contact.surface.soft_erp + + # setSoftERP + def setSoftERP(self, erp): + """setSoftERP(erp) + + Set the contact normal "softness" parameter. + + @param erp: Softness parameter + @type erp: float + """ + self._contact.surface.soft_erp = erp + + # getSoftCFM + def getSoftCFM(self): + """getSoftCFM() -> float + + Return the contact normal "softness" parameter. + """ + return self._contact.surface.soft_cfm + + # setSoftCFM + def setSoftCFM(self, cfm): + """setSoftCFM(cfm) + + Set the contact normal "softness" parameter. + + @param cfm: Softness parameter + @type cfm: float + """ + self._contact.surface.soft_cfm = cfm + + # getMotion1 + def getMotion1(self): + """getMotion1() -> float + + Get the surface velocity in friction direction 1. + """ + return self._contact.surface.motion1 + + # setMotion1 + def setMotion1(self, m): + """setMotion1(m) + + Set the surface velocity in friction direction 1. + + @param m: Surface velocity + @type m: float + """ + self._contact.surface.motion1 = m + + # getMotion2 + def getMotion2(self): + """getMotion2() -> float + + Get the surface velocity in friction direction 2. + """ + return self._contact.surface.motion2 + + # setMotion2 + def setMotion2(self, m): + """setMotion2(m) + + Set the surface velocity in friction direction 2. + + @param m: Surface velocity + @type m: float + """ + self._contact.surface.motion2 = m + + # getSlip1 + def getSlip1(self): + """getSlip1() -> float + + Get the coefficient of force-dependent-slip (FDS) for friction + direction 1. + """ + return self._contact.surface.slip1 + + # setSlip1 + def setSlip1(self, s): + """setSlip1(s) + + Set the coefficient of force-dependent-slip (FDS) for friction + direction 1. + + @param s: FDS coefficient + @type s: float + """ + self._contact.surface.slip1 = s + + # getSlip2 + def getSlip2(self): + """getSlip2() -> float + + Get the coefficient of force-dependent-slip (FDS) for friction + direction 2. + """ + return self._contact.surface.slip2 + + # setSlip2 + def setSlip2(self, s): + """setSlip2(s) + + Set the coefficient of force-dependent-slip (FDS) for friction + direction 1. + + @param s: FDS coefficient + @type s: float + """ + self._contact.surface.slip2 = s + + # getFDir1 + def getFDir1(self): + """getFDir1() -> (x, y, z) + + Get the "first friction direction" vector that defines a direction + along which frictional force is applied. + """ + return (self._contact.fdir1[0], + self._contact.fdir1[1], + self._contact.fdir1[2]) + + # setFDir1 + def setFDir1(self, fdir): + """setFDir1(fdir) + + Set the "first friction direction" vector that defines a direction + along which frictional force is applied. It must be of unit length + and perpendicular to the contact normal (so it is typically + tangential to the contact surface). + + @param fdir: Friction direction + @type fdir: 3-sequence of floats + """ + self._contact.fdir1[0] = fdir[0] + self._contact.fdir1[1] = fdir[1] + self._contact.fdir1[2] = fdir[2] + + # getContactGeomParams + def getContactGeomParams(self): + """getContactGeomParams() -> (pos, normal, depth, geom1, geom2) + + Get the ContactGeom structure of the contact. + + The return value is a tuple (pos, normal, depth, geom1, geom2) + where pos and normal are 3-tuples of floats and depth is a single + float. geom1 and geom2 are the Geom objects of the geoms in contact. + """ + cdef size_t id1, id2 + + pos = (self._contact.geom.pos[0], + self._contact.geom.pos[1], + self._contact.geom.pos[2]) + normal = (self._contact.geom.normal[0], + self._contact.geom.normal[1], + self._contact.geom.normal[2]) + depth = self._contact.geom.depth + + id1 = self._contact.geom.g1 + id2 = self._contact.geom.g2 + g1 = _geom_c2py_lut[id1] + g2 = _geom_c2py_lut[id2] + return pos, normal, depth, g1, g2 + + # setContactGeomParams + def setContactGeomParams(self, pos, normal, depth, g1=None, g2=None): + """setContactGeomParams(pos, normal, depth, geom1=None, geom2=None) + + Set the ContactGeom structure of the contact. + + @param pos: Contact position, in global coordinates + @type pos: 3-sequence of floats + @param normal: Unit length normal vector + @type normal: 3-sequence of floats + @param depth: Depth to which the two bodies inter-penetrate + @type depth: float + @param geom1: Geometry object 1 that collided + @type geom1: Geom + @param geom2: Geometry object 2 that collided + @type geom2: Geom + """ + + cdef size_t id + + self._contact.geom.pos[0] = pos[0] + self._contact.geom.pos[1] = pos[1] + self._contact.geom.pos[2] = pos[2] + self._contact.geom.normal[0] = normal[0] + self._contact.geom.normal[1] = normal[1] + self._contact.geom.normal[2] = normal[2] + self._contact.geom.depth = depth + if g1 != None: + id = g1._id() + self._contact.geom.g1 = id + else: + self._contact.geom.g1 = 0 + + if g2 != None: + id = g2._id() + self._contact.geom.g2 = id + else: + self._contact.geom.g2 = 0 + + +# World +cdef class World: + """Dynamics world. + + The world object is a container for rigid bodies and joints. + + + Constructor:: + + World() + """ + + cdef dWorldID wid + + def __cinit__(self): + self.wid = dWorldCreate() + + def __dealloc__(self): + if self.wid != NULL: + dWorldDestroy(self.wid) + + # setGravity + def setGravity(self, gravity): + """setGravity(gravity) + + Set the world's global gravity vector. + + @param gravity: Gravity vector + @type gravity: 3-sequence of floats + """ + dWorldSetGravity(self.wid, gravity[0], gravity[1], gravity[2]) + + # getGravity + def getGravity(self): + """getGravity() -> 3-tuple + + Return the world's global gravity vector as a 3-tuple of floats. + """ + cdef dVector3 g + dWorldGetGravity(self.wid, g) + return g[0], g[1], g[2] + + # setERP + def setERP(self, erp): + """setERP(erp) + + Set the global ERP value, that controls how much error + correction is performed in each time step. Typical values are + in the range 0.1-0.8. The default is 0.2. + + @param erp: Global ERP value + @type erp: float + """ + dWorldSetERP(self.wid, erp) + + # getERP + def getERP(self): + """getERP() -> float + + Get the global ERP value, that controls how much error + correction is performed in each time step. Typical values are + in the range 0.1-0.8. The default is 0.2. + """ + return dWorldGetERP(self.wid) + + # setCFM + def setCFM(self, cfm): + """setCFM(cfm) + + Set the global CFM (constraint force mixing) value. Typical + values are in the range 10E-9 - 1. The default is 10E-5 if + single precision is being used, or 10E-10 if double precision + is being used. + + @param cfm: Constraint force mixing value + @type cfm: float + """ + dWorldSetCFM(self.wid, cfm) + + # getCFM + def getCFM(self): + """getCFM() -> float + + Get the global CFM (constraint force mixing) value. Typical + values are in the range 10E-9 - 1. The default is 10E-5 if + single precision is being used, or 10E-10 if double precision + is being used. + """ + return dWorldGetCFM(self.wid) + + # step + def step(self, stepsize): + """step(stepsize) + + Step the world. This uses a "big matrix" method that takes + time on the order of O(m3) and memory on the order of O(m2), where m + is the total number of constraint rows. + + For large systems this will use a lot of memory and can be + very slow, but this is currently the most accurate method. + + @param stepsize: Time step + @type stepsize: float + """ + + dWorldStep(self.wid, stepsize) + + # quickStep + def quickStep(self, stepsize): + """quickStep(stepsize) + + Step the world. This uses an iterative method that takes time + on the order of O(m*N) and memory on the order of O(m), where m is + the total number of constraint rows and N is the number of + iterations. + + For large systems this is a lot faster than dWorldStep, but it + is less accurate. + + @param stepsize: Time step + @type stepsize: float + """ + dWorldQuickStep(self.wid, stepsize) + + # setQuickStepNumIterations + def setQuickStepNumIterations(self, num): + """setQuickStepNumIterations(num) + + Set the number of iterations that the QuickStep method + performs per step. More iterations will give a more accurate + solution, but will take longer to compute. The default is 20 + iterations. + + @param num: Number of iterations + @type num: int + """ + + dWorldSetQuickStepNumIterations(self.wid, num) + + # getQuickStepNumIterations + def getQuickStepNumIterations(self): + """getQuickStepNumIterations() -> int + + Get the number of iterations that the QuickStep method + performs per step. More iterations will give a more accurate + solution, but will take longer to compute. The default is 20 + iterations. + """ + return dWorldGetQuickStepNumIterations(self.wid) + + # setQuickStepNumIterations + def setContactMaxCorrectingVel(self, vel): + """setContactMaxCorrectingVel(vel) + + Set the maximum correcting velocity that contacts are allowed + to generate. The default value is infinity (i.e. no + limit). Reducing this value can help prevent "popping" of + deeply embedded objects. + + @param vel: Maximum correcting velocity + @type vel: float + """ + dWorldSetContactMaxCorrectingVel(self.wid, vel) + + # getQuickStepNumIterations + def getContactMaxCorrectingVel(self): + """getContactMaxCorrectingVel() -> float + + Get the maximum correcting velocity that contacts are allowed + to generate. The default value is infinity (i.e. no + limit). Reducing this value can help prevent "popping" of + deeply embedded objects. + + """ + return dWorldGetContactMaxCorrectingVel(self.wid) + + # setContactSurfaceLayer + def setContactSurfaceLayer(self, depth): + """setContactSurfaceLayer(depth) + + Set the depth of the surface layer around all geometry + objects. Contacts are allowed to sink into the surface layer + up to the given depth before coming to rest. The default value + is zero. Increasing this to some small value (e.g. 0.001) can + help prevent jittering problems due to contacts being + repeatedly made and broken. + + @param depth: Surface layer depth + @type depth: float + """ + dWorldSetContactSurfaceLayer(self.wid, depth) + + # getContactSurfaceLayer + def getContactSurfaceLayer(self): + """getContactSurfaceLayer() + + Get the depth of the surface layer around all geometry + objects. Contacts are allowed to sink into the surface layer + up to the given depth before coming to rest. The default value + is zero. Increasing this to some small value (e.g. 0.001) can + help prevent jittering problems due to contacts being + repeatedly made and broken. + """ + return dWorldGetContactSurfaceLayer(self.wid) + + # setAutoDisableFlag + def setAutoDisableFlag(self, flag): + """setAutoDisableFlag(flag) + + Set the default auto-disable flag for newly created bodies. + + @param flag: True = Do auto disable + @type flag: bool + """ + dWorldSetAutoDisableFlag(self.wid, flag) + + # getAutoDisableFlag + def getAutoDisableFlag(self): + """getAutoDisableFlag() -> bool + + Get the default auto-disable flag for newly created bodies. + """ + return dWorldGetAutoDisableFlag(self.wid) + + # setAutoDisableLinearThreshold + def setAutoDisableLinearThreshold(self, threshold): + """setAutoDisableLinearThreshold(threshold) + + Set the default auto-disable linear threshold for newly created + bodies. + + @param threshold: Linear threshold + @type threshold: float + """ + dWorldSetAutoDisableLinearThreshold(self.wid, threshold) + + # getAutoDisableLinearThreshold + def getAutoDisableLinearThreshold(self): + """getAutoDisableLinearThreshold() -> float + + Get the default auto-disable linear threshold for newly created + bodies. + """ + return dWorldGetAutoDisableLinearThreshold(self.wid) + + # setAutoDisableAngularThreshold + def setAutoDisableAngularThreshold(self, threshold): + """setAutoDisableAngularThreshold(threshold) + + Set the default auto-disable angular threshold for newly created + bodies. + + @param threshold: Angular threshold + @type threshold: float + """ + dWorldSetAutoDisableAngularThreshold(self.wid, threshold) + + # getAutoDisableAngularThreshold + def getAutoDisableAngularThreshold(self): + """getAutoDisableAngularThreshold() -> float + + Get the default auto-disable angular threshold for newly created + bodies. + """ + return dWorldGetAutoDisableAngularThreshold(self.wid) + + # setAutoDisableSteps + def setAutoDisableSteps(self, steps): + """setAutoDisableSteps(steps) + + Set the default auto-disable steps for newly created bodies. + + @param steps: Auto disable steps + @type steps: int + """ + dWorldSetAutoDisableSteps(self.wid, steps) + + # getAutoDisableSteps + def getAutoDisableSteps(self): + """getAutoDisableSteps() -> int + + Get the default auto-disable steps for newly created bodies. + """ + return dWorldGetAutoDisableSteps(self.wid) + + # setAutoDisableTime + def setAutoDisableTime(self, time): + """setAutoDisableTime(time) + + Set the default auto-disable time for newly created bodies. + + @param time: Auto disable time + @type time: float + """ + dWorldSetAutoDisableTime(self.wid, time) + + # getAutoDisableTime + def getAutoDisableTime(self): + """getAutoDisableTime() -> float + + Get the default auto-disable time for newly created bodies. + """ + return dWorldGetAutoDisableTime(self.wid) + + # setLinearDamping + def setLinearDamping(self, scale): + """setLinearDamping(scale) + + Set the world's linear damping scale. + @param scale The linear damping scale that is to be applied to bodies. + Default is 0 (no damping). Should be in the interval [0, 1]. + @type scale: float + """ + dWorldSetLinearDamping(self.wid, scale) + + # getLinearDamping + def getLinearDamping(self): + """getLinearDamping() -> float + + Get the world's linear damping scale. + """ + return dWorldGetLinearDamping(self.wid) + + # setAngularDamping + def setAngularDamping(self, scale): + """setAngularDamping(scale) + + Set the world's angular damping scale. + @param scale The angular damping scale that is to be applied to bodies. + Default is 0 (no damping). Should be in the interval [0, 1]. + @type scale: float + """ + dWorldSetAngularDamping(self.wid, scale) + + # getAngularDamping + def getAngularDamping(self): + """getAngularDamping() -> float + + Get the world's angular damping scale. + """ + return dWorldGetAngularDamping(self.wid) + + # impulseToForce + def impulseToForce(self, stepsize, impulse): + """impulseToForce(stepsize, impulse) -> 3-tuple + + If you want to apply a linear or angular impulse to a rigid + body, instead of a force or a torque, then you can use this + function to convert the desired impulse into a force/torque + vector before calling the dBodyAdd... function. + + @param stepsize: Time step + @param impulse: Impulse vector + @type stepsize: float + @type impulse: 3-tuple of floats + """ + cdef dVector3 force + dWorldImpulseToForce(self.wid, stepsize, + impulse[0], impulse[1], impulse[2], force) + return force[0], force[1], force[2] + + # createBody +# def createBody(self): +# return Body(self) + + # createBallJoint +# def createBallJoint(self, jointgroup=None): +# return BallJoint(self, jointgroup) + + # createHingeJoint +# def createHingeJoint(self, jointgroup=None): +# return HingeJoint(self, jointgroup) + + # createHinge2Joint +# def createHinge2Joint(self, jointgroup=None): +# return Hinge2Joint(self, jointgroup) + + # createSliderJoint +# def createSliderJoint(self, jointgroup=None): +# return SliderJoint(self, jointgroup) + + # createFixedJoint +# def createFixedJoint(self, jointgroup=None): +# return FixedJoint(self, jointgroup) + + # createContactJoint +# def createContactJoint(self, jointgroup, contact): +# return ContactJoint(self, jointgroup, contact) + + +# Body +cdef class Body: + """The rigid body class encapsulating the ODE body. + + This class represents a rigid body that has a location and orientation + in space and that stores the mass properties of an object. + + When creating a Body object you have to pass the world it belongs to + as argument to the constructor:: + + >>> import ode + >>> w = ode.World() + >>> b = ode.Body(w) + """ + + cdef dBodyID bid + # A reference to the world so that the world won't be destroyed while + # there are still joints using it. + cdef object world + + # A dictionary with user attributes + # (set via __getattr__ and __setattr__) + cdef object userattribs + + def __cinit__(self, World world not None): + self.bid = dBodyCreate(world.wid) + + def __init__(self, World world not None): + """Constructor. + + @param world: The world in which the body should be created. + @type world: World + """ + self.world = world + self.userattribs = {} + + def __dealloc__(self): + if self.bid != NULL: + dBodyDestroy(self.bid) + + def __getattr__(self, name): + try: + return self.userattribs[name] + except: + raise AttributeError("Body object has no attribute '%s'" % name) + + def __setattr__(self, name, value): + self.userattribs[name] = value + + def __delattr__(self, name): + try: + del self.userattribs[name] + except: + raise AttributeError("Body object has no attribute '%s'" % name) + + # setPosition + def setPosition(self, pos): + """setPosition(pos) + + Set the position of the body. + + @param pos: The new position + @type pos: 3-sequence of floats + """ + dBodySetPosition(self.bid, pos[0], pos[1], pos[2]) + + # getPosition + def getPosition(self): + """getPosition() -> 3-tuple + + Return the current position of the body. + """ + cdef dReal* p + # The "const" in the original return value is cast away + p = dBodyGetPosition(self.bid) + return p[0], p[1], p[2] + + # setRotation + def setRotation(self, R): + """setRotation(R) + + Set the orientation of the body. The rotation matrix must be + given as a sequence of 9 floats which are the elements of the + matrix in row-major order. + + @param R: Rotation matrix + @type R: 9-sequence of floats + """ + cdef dMatrix3 m + m[0] = R[0] + m[1] = R[1] + m[2] = R[2] + m[3] = 0 + m[4] = R[3] + m[5] = R[4] + m[6] = R[5] + m[7] = 0 + m[8] = R[6] + m[9] = R[7] + m[10] = R[8] + m[11] = 0 + dBodySetRotation(self.bid, m) + + # getRotation + def getRotation(self): + """getRotation() -> 9-tuple + + Return the current rotation matrix as a tuple of 9 floats (row-major + order). + """ + cdef dReal* m + # The "const" in the original return value is cast away + m = dBodyGetRotation(self.bid) + return m[0], m[1], m[2], m[4], m[5], m[6], m[8], m[9], m[10] + + # getQuaternion + def getQuaternion(self): + """getQuaternion() -> 4-tuple + + Return the current rotation as a quaternion. The return value + is a list of 4 floats. + """ + cdef dReal* q + q = dBodyGetQuaternion(self.bid) + return q[0], q[1], q[2], q[3] + + # setQuaternion + def setQuaternion(self, q): + """setQuaternion(q) + + Set the orientation of the body. The quaternion must be given as a + sequence of 4 floats. + + @param q: Quaternion + @type q: 4-sequence of floats + """ + cdef dQuaternion w + w[0] = q[0] + w[1] = q[1] + w[2] = q[2] + w[3] = q[3] + dBodySetQuaternion(self.bid, w) + + # setLinearVel + def setLinearVel(self, vel): + """setLinearVel(vel) + + Set the linear velocity of the body. + + @param vel: New velocity + @type vel: 3-sequence of floats + """ + dBodySetLinearVel(self.bid, vel[0], vel[1], vel[2]) + + # getLinearVel + def getLinearVel(self): + """getLinearVel() -> 3-tuple + + Get the current linear velocity of the body. + """ + cdef dReal* p + # The "const" in the original return value is cast away + p = dBodyGetLinearVel(self.bid) + return p[0], p[1], p[2] + + # setAngularVel + def setAngularVel(self, vel): + """setAngularVel(vel) + + Set the angular velocity of the body. + + @param vel: New angular velocity + @type vel: 3-sequence of floats + """ + dBodySetAngularVel(self.bid, vel[0], vel[1], vel[2]) + + # getAngularVel + def getAngularVel(self): + """getAngularVel() -> 3-tuple + + Get the current angular velocity of the body. + """ + cdef dReal* p + # The "const" in the original return value is cast away + p = dBodyGetAngularVel(self.bid) + return p[0], p[1], p[2] + + # setMass + def setMass(self, Mass mass): + """setMass(mass) + + Set the mass properties of the body. The argument mass must be + an instance of a Mass object. + + @param mass: Mass properties + @type mass: Mass + """ + dBodySetMass(self.bid, &mass._mass) + + # getMass + def getMass(self): + """getMass() -> mass + + Return the mass properties as a Mass object. + """ + cdef Mass m + m = Mass() + dBodyGetMass(self.bid, &m._mass) + return m + + # addForce + def addForce(self, f): + """addForce(f) + + Add an external force f given in absolute coordinates. The force + is applied at the center of mass. + + @param f: Force + @type f: 3-sequence of floats + """ + dBodyAddForce(self.bid, f[0], f[1], f[2]) + + # addTorque + def addTorque(self, t): + """addTorque(t) + + Add an external torque t given in absolute coordinates. + + @param t: Torque + @type t: 3-sequence of floats + """ + dBodyAddTorque(self.bid, t[0], t[1], t[2]) + + # addRelForce + def addRelForce(self, f): + """addRelForce(f) + + Add an external force f given in relative coordinates + (relative to the body's own frame of reference). The force + is applied at the center of mass. + + @param f: Force + @type f: 3-sequence of floats + """ + dBodyAddRelForce(self.bid, f[0], f[1], f[2]) + + # addRelTorque + def addRelTorque(self, t): + """addRelTorque(t) + + Add an external torque t given in relative coordinates + (relative to the body's own frame of reference). + + @param t: Torque + @type t: 3-sequence of floats + """ + dBodyAddRelTorque(self.bid, t[0], t[1], t[2]) + + # addForceAtPos + def addForceAtPos(self, f, p): + """addForceAtPos(f, p) + + Add an external force f at position p. Both arguments must be + given in absolute coordinates. + + @param f: Force + @param p: Position + @type f: 3-sequence of floats + @type p: 3-sequence of floats + """ + dBodyAddForceAtPos(self.bid, f[0], f[1], f[2], p[0], p[1], p[2]) + + # addForceAtRelPos + def addForceAtRelPos(self, f, p): + """addForceAtRelPos(f, p) + + Add an external force f at position p. f is given in absolute + coordinates and p in absolute coordinates. + + @param f: Force + @param p: Position + @type f: 3-sequence of floats + @type p: 3-sequence of floats + """ + dBodyAddForceAtRelPos(self.bid, f[0], f[1], f[2], p[0], p[1], p[2]) + + # addRelForceAtPos + def addRelForceAtPos(self, f, p): + """addRelForceAtPos(f, p) + + Add an external force f at position p. f is given in relative + coordinates and p in relative coordinates. + + @param f: Force + @param p: Position + @type f: 3-sequence of floats + @type p: 3-sequence of floats + """ + dBodyAddRelForceAtPos(self.bid, f[0], f[1], f[2], p[0], p[1], p[2]) + + # addRelForceAtRelPos + def addRelForceAtRelPos(self, f, p): + """addRelForceAtRelPos(f, p) + + Add an external force f at position p. Both arguments must be + given in relative coordinates. + + @param f: Force + @param p: Position + @type f: 3-sequence of floats + @type p: 3-sequence of floats + """ + dBodyAddRelForceAtRelPos(self.bid, f[0], f[1], f[2], p[0], p[1], p[2]) + + # getForce + def getForce(self): + """getForce() -> 3-tuple + + Return the current accumulated force. + """ + cdef dReal* f + # The "const" in the original return value is cast away + f = dBodyGetForce(self.bid) + return f[0], f[1], f[2] + + # getTorque + def getTorque(self): + """getTorque() -> 3-tuple + + Return the current accumulated torque. + """ + cdef dReal* f + # The "const" in the original return value is cast away + f = dBodyGetTorque(self.bid) + return f[0], f[1], f[2] + + # setForce + def setForce(self, f): + """setForce(f) + + Set the body force accumulation vector. + + @param f: Force + @type f: 3-tuple of floats + """ + dBodySetForce(self.bid, f[0], f[1], f[2]) + + # setTorque + def setTorque(self, t): + """setTorque(t) + + Set the body torque accumulation vector. + + @param t: Torque + @type t: 3-tuple of floats + """ + dBodySetTorque(self.bid, t[0], t[1], t[2]) + + # getRelPointPos + def getRelPointPos(self, p): + """getRelPointPos(p) -> 3-tuple + + Utility function that takes a point p on a body and returns + that point's position in global coordinates. The point p + must be given in body relative coordinates. + + @param p: Body point (local coordinates) + @type p: 3-sequence of floats + """ + + cdef dVector3 res + dBodyGetRelPointPos(self.bid, p[0], p[1], p[2], res) + return res[0], res[1], res[2] + + # getRelPointVel + def getRelPointVel(self, p): + """getRelPointVel(p) -> 3-tuple + + Utility function that takes a point p on a body and returns + that point's velocity in global coordinates. The point p + must be given in body relative coordinates. + + @param p: Body point (local coordinates) + @type p: 3-sequence of floats + """ + cdef dVector3 res + dBodyGetRelPointVel(self.bid, p[0], p[1], p[2], res) + return res[0], res[1], res[2] + + # getPointVel + def getPointVel(self, p): + """getPointVel(p) -> 3-tuple + + Utility function that takes a point p on a body and returns + that point's velocity in global coordinates. The point p + must be given in global coordinates. + + @param p: Body point (global coordinates) + @type p: 3-sequence of floats + """ + cdef dVector3 res + dBodyGetPointVel(self.bid, p[0], p[1], p[2], res) + return res[0], res[1], res[2] + + # getPosRelPoint + def getPosRelPoint(self, p): + """getPosRelPoint(p) -> 3-tuple + + This is the inverse of getRelPointPos(). It takes a point p in + global coordinates and returns the point's position in + body-relative coordinates. + + @param p: Body point (global coordinates) + @type p: 3-sequence of floats + """ + cdef dVector3 res + dBodyGetPosRelPoint(self.bid, p[0], p[1], p[2], res) + return res[0], res[1], res[2] + + # vectorToWorld + def vectorToWorld(self, v): + """vectorToWorld(v) -> 3-tuple + + Given a vector v expressed in the body coordinate system, rotate + it to the world coordinate system. + + @param v: Vector in body coordinate system + @type v: 3-sequence of floats + """ + cdef dVector3 res + dBodyVectorToWorld(self.bid, v[0], v[1], v[2], res) + return res[0], res[1], res[2] + + # vectorFromWorld + def vectorFromWorld(self, v): + """vectorFromWorld(v) -> 3-tuple + + Given a vector v expressed in the world coordinate system, rotate + it to the body coordinate system. + + @param v: Vector in world coordinate system + @type v: 3-sequence of floats + """ + cdef dVector3 res + dBodyVectorFromWorld(self.bid, v[0], v[1], v[2], res) + return res[0], res[1], res[2] + + # Enable + def enable(self): + """enable() + + Manually enable a body. + """ + dBodyEnable(self.bid) + + # Disable + def disable(self): + """disable() + + Manually disable a body. Note that a disabled body that is connected + through a joint to an enabled body will be automatically re-enabled + at the next simulation step. + """ + dBodyDisable(self.bid) + + # isEnabled + def isEnabled(self): + """isEnabled() -> bool + + Check if a body is currently enabled. + """ + return dBodyIsEnabled(self.bid) + + # setFiniteRotationMode + def setFiniteRotationMode(self, mode): + """setFiniteRotationMode(mode) + + This function controls the way a body's orientation is updated at + each time step. The mode argument can be: + + - 0: An "infinitesimal" orientation update is used. This is + fast to compute, but it can occasionally cause inaccuracies + for bodies that are rotating at high speed, especially when + those bodies are joined to other bodies. This is the default + for every new body that is created. + + - 1: A "finite" orientation update is used. This is more + costly to compute, but will be more accurate for high speed + rotations. Note however that high speed rotations can result + in many types of error in a simulation, and this mode will + only fix one of those sources of error. + + @param mode: Rotation mode (0/1) + @type mode: int + """ + dBodySetFiniteRotationMode(self.bid, mode) + + # getFiniteRotationMode + def getFiniteRotationMode(self): + """getFiniteRotationMode() -> mode (0/1) + + Return the current finite rotation mode of a body (0 or 1). + See setFiniteRotationMode(). + """ + return dBodyGetFiniteRotationMode(self.bid) + + # setFiniteRotationAxis + def setFiniteRotationAxis(self, a): + """setFiniteRotationAxis(a) + + Set the finite rotation axis of the body. This axis only has a + meaning when the finite rotation mode is set + (see setFiniteRotationMode()). + + @param a: Axis + @type a: 3-sequence of floats + """ + dBodySetFiniteRotationAxis(self.bid, a[0], a[1], a[2]) + + # getFiniteRotationAxis + def getFiniteRotationAxis(self): + """getFiniteRotationAxis() -> 3-tuple + + Return the current finite rotation axis of the body. + """ + cdef dVector3 p + # The "const" in the original return value is cast away + dBodyGetFiniteRotationAxis(self.bid, p) + return p[0], p[1], p[2] + + # getNumJoints + def getNumJoints(self): + """getNumJoints() -> int + + Return the number of joints that are attached to this body. + """ + return dBodyGetNumJoints(self.bid) + + # setGravityMode + def setGravityMode(self, mode): + """setGravityMode(mode) + + Set whether the body is influenced by the world's gravity + or not. If mode is True it is, otherwise it isn't. + Newly created bodies are always influenced by the world's gravity. + + @param mode: Gravity mode + @type mode: bool + """ + dBodySetGravityMode(self.bid, mode) + + # getGravityMode + def getGravityMode(self): + """getGravityMode() -> bool + + Return True if the body is influenced by the world's gravity. + """ + return dBodyGetGravityMode(self.bid) + + def setDynamic(self): + """setDynamic() + + Set a body to the (default) "dynamic" state, instead of "kinematic". + See setKinematic() for more information. + """ + dBodySetDynamic(self.bid) + + def setKinematic(self): + """setKinematic() + + Set the kinematic state of the body (change it into a kinematic body) + + Kinematic bodies behave as if they had infinite mass. This means they don't react + to any force (gravity, constraints or user-supplied); they simply follow + velocity to reach the next position. [from ODE wiki] + + """ + dBodySetKinematic(self.bid) + + def isKinematic(self): + """isKinematic() -> bool + + Return True if the body is kinematic (not influenced by other forces). + + Kinematic bodies behave as if they had infinite mass. This means they don't react + to any force (gravity, constraints or user-supplied); they simply follow + velocity to reach the next position. [from ODE wiki] + + """ + return dBodyIsKinematic(self.bid) + + def setMaxAngularSpeed(self, max_speed): + """setMaxAngularSpeed(max_speed) + + You can also limit the maximum angular speed. In contrast to the damping + functions, the angular velocity is affected before the body is moved. + This means that it will introduce errors in joints that are forcing the + body to rotate too fast. Some bodies have naturally high angular + velocities (like cars' wheels), so you may want to give them a very high + (like the default, dInfinity) limit. + + """ + dBodySetMaxAngularSpeed(self.bid, max_speed) + + +# JointGroup +cdef class JointGroup: + """Joint group. + + Constructor:: + + JointGroup() + """ + + # JointGroup ID + cdef dJointGroupID gid + # A list of Python joints that were added to the group + cdef object jointlist + + def __cinit__(self): + self.gid = dJointGroupCreate(0) + + def __init__(self): + self.jointlist = [] + + def __dealloc__(self): + if self.gid != NULL: + for j in self.jointlist: + j._destroyed() + dJointGroupDestroy(self.gid) + + # empty + def empty(self): + """empty() + + Destroy all joints in the group. + """ + dJointGroupEmpty(self.gid) + for j in self.jointlist: + j._destroyed() + self.jointlist = [] + + def _addjoint(self, j): + """_addjoint(j) + + Add a joint to the group. This is an internal method that is + called by the joints. The group has to know the Python + wrappers because it has to notify them when the group is + emptied (so that the ODE joints won't get destroyed + twice). The notification is done by calling _destroyed() on + the Python joints. + + @param j: The joint to add + @type j: Joint + """ + self.jointlist.append(j) + + +###################################################################### + +# Joint +cdef class Joint: + """Base class for all joint classes.""" + + # Joint id as returned by dJointCreateXxx() + cdef dJointID jid + # A reference to the world so that the world won't be destroyed while + # there are still joints using it. + cdef object world + # The feedback buffer + cdef dJointFeedback* feedback + + cdef object body1 + cdef object body2 + + # A dictionary with user attributes + # (set via __getattr__ and __setattr__) + cdef object userattribs + + def __cinit__(self, *a, **kw): + self.jid = NULL + self.world = None + self.feedback = NULL + self.body1 = None + self.body2 = None + self.userattribs = {} + + def __init__(self, *a, **kw): + raise NotImplementedError("Joint base class can't be used directly") + + def __dealloc__(self): + self.setFeedback(False) + if self.jid != NULL: + dJointDestroy(self.jid) + + def __getattr__(self, name): + try: + return self.userattribs[name] + except: + raise AttributeError("Joint object has no attribute '%s'" % name) + + def __setattr__(self, name, value): + self.userattribs[name] = value + + def __delattr__(self, name): + try: + del self.userattribs[name] + except: + raise AttributeError("Joint object has no attribute '%s'" % name) + + # _destroyed + def _destroyed(self): + """Notify the joint object about an external destruction of the ODE joint. + + This method has to be called when the underlying ODE object + was destroyed by someone else (e.g. by a joint group). The Python + wrapper will then refrain from destroying it again. + """ + self.jid = NULL + + # enable + def enable(self): + """enable() + + Enable the joint. Disabled joints are completely ignored during the + simulation. Disabled joints don't lose the already computed information + like anchors and axes. + """ + dJointEnable(self.jid) + + # disable + def disable(self): + """disable() + + Disable the joint. Disabled joints are completely ignored during the + simulation. Disabled joints don't lose the already computed information + like anchors and axes. + """ + dJointDisable(self.jid) + + # isEnabled + def isEnabled(self): + """isEnabled() -> bool + + Determine whether the joint is enabled. Disabled joints are completely + ignored during the simulation. Disabled joints don't lose the already + computed information like anchors and axes. + """ + return dJointIsEnabled(self.jid) + + # attach + def attach(self, Body body1, Body body2): + """attach(body1, body2) + + Attach the joint to some new bodies. A body can be attached + to the environment by passing None as second body. + + @param body1: First body + @param body2: Second body + @type body1: Body + @type body2: Body + """ + cdef dBodyID id1, id2 + + if body1 == None: + id1 = NULL + else: + id1 = body1.bid + + if body2 == None: + id2 = NULL + else: + id2 = body2.bid + + self.body1 = body1 + self.body2 = body2 + dJointAttach(self.jid, id1, id2) + + # getBody + def getBody(self, index): + """getBody(index) -> Body + + Return the bodies that this joint connects. If index is 0 the + "first" body will be returned, corresponding to the body1 + argument of the attach() method. If index is 1 the "second" body + will be returned, corresponding to the body2 argument of the + attach() method. + + @param index: Bodx index (0 or 1). + @type index: int + """ + + if index == 0: + return self.body1 + elif index == 1: + return self.body2 + else: + raise IndexError() + + # setFeedback + def setFeedback(self, flag=1): + """setFeedback(flag=True) + + Create a feedback buffer. If flag is True then a buffer is + allocated and the forces/torques applied by the joint can + be read using the getFeedback() method. If flag is False the + buffer is released. + + @param flag: Specifies whether a buffer should be created or released + @type flag: bool + """ + + if flag: + # Was there already a buffer allocated? then we're finished + if self.feedback != NULL: + return + # Allocate a buffer and pass it to ODE + self.feedback = malloc(sizeof(dJointFeedback)) + if self.feedback == NULL: + raise MemoryError("can't allocate feedback buffer") + dJointSetFeedback(self.jid, self.feedback) + else: + if self.feedback != NULL: + # Free a previously allocated buffer + dJointSetFeedback(self.jid, NULL) + free(self.feedback) + self.feedback = NULL + + # getFeedback + def getFeedback(self): + """getFeedback() -> (force1, torque1, force2, torque2) + + Get the forces/torques applied by the joint. If feedback is + activated (i.e. setFeedback(True) was called) then this method + returns a tuple (force1, torque1, force2, torque2) with the + forces and torques applied to body 1 and body 2. The + forces/torques are given as 3-tuples. + + If feedback is deactivated then the method always returns None. + """ + cdef dJointFeedback* fb + + fb = dJointGetFeedback(self.jid) + if fb == NULL: + return None + + f1 = (fb.f1[0], fb.f1[1], fb.f1[2]) + t1 = (fb.t1[0], fb.t1[1], fb.t1[2]) + f2 = (fb.f2[0], fb.f2[1], fb.f2[2]) + t2 = (fb.t2[0], fb.t2[1], fb.t2[2]) + return f1, t1, f2, t2 + +###################################################################### + + +# BallJoint +cdef class BallJoint(Joint): + """Ball joint. + + Constructor:: + + BallJoint(world, jointgroup=None) + """ + + def __cinit__(self, World world not None, jointgroup=None): + cdef JointGroup jg + cdef dJointGroupID jgid + + jgid = NULL + if jointgroup != None: + jg = jointgroup + jgid = jg.gid + self.jid = dJointCreateBall(world.wid, jgid) + + def __init__(self, World world not None, jointgroup=None): + self.world = world + if jointgroup != None: + jointgroup._addjoint(self) + + # setAnchor + def setAnchor(self, pos): + """setAnchor(pos) + + Set the joint anchor point which must be specified in world + coordinates. + + @param pos: Anchor position + @type pos: 3-sequence of floats + """ + dJointSetBallAnchor(self.jid, pos[0], pos[1], pos[2]) + + # getAnchor + def getAnchor(self): + """getAnchor() -> 3-tuple of floats + + Get the joint anchor point, in world coordinates. This + returns the point on body 1. If the joint is perfectly + satisfied, this will be the same as the point on body 2. + """ + + cdef dVector3 p + dJointGetBallAnchor(self.jid, p) + return p[0], p[1], p[2] + + # getAnchor2 + def getAnchor2(self): + """getAnchor2() -> 3-tuple of floats + + Get the joint anchor point, in world coordinates. This + returns the point on body 2. If the joint is perfectly + satisfied, this will be the same as the point on body 1. + """ + + cdef dVector3 p + dJointGetBallAnchor2(self.jid, p) + return p[0], p[1], p[2] + + # setParam + def setParam(self, param, value): + pass + + # getParam + def getParam(self, param): + return 0.0 + + +# HingeJoint +cdef class HingeJoint(Joint): + """Hinge joint. + + Constructor:: + + HingeJoint(world, jointgroup=None) + """ + + def __cinit__(self, World world not None, jointgroup=None): + cdef JointGroup jg + cdef dJointGroupID jgid + + jgid = NULL + if jointgroup != None: + jg = jointgroup + jgid = jg.gid + self.jid = dJointCreateHinge(world.wid, jgid) + + def __init__(self, World world not None, jointgroup=None): + self.world = world + if jointgroup != None: + jointgroup._addjoint(self) + + # setAnchor + def setAnchor(self, pos): + """setAnchor(pos) + + Set the hinge anchor which must be given in world coordinates. + + @param pos: Anchor position + @type pos: 3-sequence of floats + """ + dJointSetHingeAnchor(self.jid, pos[0], pos[1], pos[2]) + + # getAnchor + def getAnchor(self): + """getAnchor() -> 3-tuple of floats + + Get the joint anchor point, in world coordinates. This returns + the point on body 1. If the joint is perfectly satisfied, this + will be the same as the point on body 2. + """ + cdef dVector3 p + dJointGetHingeAnchor(self.jid, p) + return p[0], p[1], p[2] + + # getAnchor2 + def getAnchor2(self): + """getAnchor2() -> 3-tuple of floats + + Get the joint anchor point, in world coordinates. This returns + the point on body 2. If the joint is perfectly satisfied, this + will be the same as the point on body 1. + """ + cdef dVector3 p + dJointGetHingeAnchor2(self.jid, p) + return p[0], p[1], p[2] + + # setAxis + def setAxis(self, axis): + """setAxis(axis) + + Set the hinge axis. + + @param axis: Hinge axis + @type axis: 3-sequence of floats + """ + dJointSetHingeAxis(self.jid, axis[0], axis[1], axis[2]) + + # getAxis + def getAxis(self): + """getAxis() -> 3-tuple of floats + + Get the hinge axis. + """ + cdef dVector3 a + dJointGetHingeAxis(self.jid, a) + return a[0], a[1], a[2] + + # getAngle + def getAngle(self): + """getAngle() -> float + + Get the hinge angle. The angle is measured between the two + bodies, or between the body and the static environment. The + angle will be between -pi..pi. + + When the hinge anchor or axis is set, the current position of + the attached bodies is examined and that position will be the + zero angle. + """ + + return dJointGetHingeAngle(self.jid) + + # getAngleRate + def getAngleRate(self): + """getAngleRate() -> float + + Get the time derivative of the angle. + """ + return dJointGetHingeAngleRate(self.jid) + + # addTorque + def addTorque(self, torque): + """addTorque(torque) + + Applies the torque about the hinge axis. + + @param torque: Torque magnitude + @type torque: float + """ + dJointAddHingeTorque(self.jid, torque) + + # setParam + def setParam(self, param, value): + """setParam(param, value) + + Set limit/motor parameters for the joint. + + param is one of ParamLoStop, ParamHiStop, ParamVel, ParamFMax, + ParamFudgeFactor, ParamBounce, ParamCFM, ParamStopERP, ParamStopCFM, + ParamSuspensionERP, ParamSuspensionCFM. + + These parameter names can be optionally followed by a digit (2 + or 3) to indicate the second or third set of parameters. + + @param param: Selects the parameter to set + @param value: Parameter value + @type param: int + @type value: float + """ + + dJointSetHingeParam(self.jid, param, value) + + # getParam + def getParam(self, param): + """getParam(param) -> float + + Get limit/motor parameters for the joint. + + param is one of ParamLoStop, ParamHiStop, ParamVel, ParamFMax, + ParamFudgeFactor, ParamBounce, ParamCFM, ParamStopERP, ParamStopCFM, + ParamSuspensionERP, ParamSuspensionCFM. + + These parameter names can be optionally followed by a digit (2 + or 3) to indicate the second or third set of parameters. + + @param param: Selects the parameter to read + @type param: int + """ + return dJointGetHingeParam(self.jid, param) + + +# SliderJoint +cdef class SliderJoint(Joint): + """Slider joint. + + Constructor:: + + SlideJoint(world, jointgroup=None) + """ + + def __cinit__(self, World world not None, jointgroup=None): + cdef JointGroup jg + cdef dJointGroupID jgid + + jgid = NULL + if jointgroup != None: + jg = jointgroup + jgid = jg.gid + self.jid = dJointCreateSlider(world.wid, jgid) + + def __init__(self, World world not None, jointgroup=None): + self.world = world + if jointgroup != None: + jointgroup._addjoint(self) + + # setAxis + def setAxis(self, axis): + """setAxis(axis) + + Set the slider axis parameter. + + @param axis: Slider axis + @type axis: 3-sequence of floats + """ + dJointSetSliderAxis(self.jid, axis[0], axis[1], axis[2]) + + # getAxis + def getAxis(self): + """getAxis() -> 3-tuple of floats + + Get the slider axis parameter. + """ + cdef dVector3 a + dJointGetSliderAxis(self.jid, a) + return a[0], a[1], a[2] + + # getPosition + def getPosition(self): + """getPosition() -> float + + Get the slider linear position (i.e. the slider's "extension"). + + When the axis is set, the current position of the attached + bodies is examined and that position will be the zero + position. + """ + + return dJointGetSliderPosition(self.jid) + + # getPositionRate + def getPositionRate(self): + """getPositionRate() -> float + + Get the time derivative of the position. + """ + return dJointGetSliderPositionRate(self.jid) + + # addForce + def addForce(self, force): + """addForce(force) + + Applies the given force in the slider's direction. + + @param force: Force magnitude + @type force: float + """ + dJointAddSliderForce(self.jid, force) + + # setParam + def setParam(self, param, value): + dJointSetSliderParam(self.jid, param, value) + + # getParam + def getParam(self, param): + return dJointGetSliderParam(self.jid, param) + + +# UniversalJoint +cdef class UniversalJoint(Joint): + """Universal joint. + + Constructor:: + + UniversalJoint(world, jointgroup=None) + """ + + def __cinit__(self, World world not None, jointgroup=None): + cdef JointGroup jg + cdef dJointGroupID jgid + + jgid = NULL + if jointgroup != None: + jg = jointgroup + jgid = jg.gid + self.jid = dJointCreateUniversal(world.wid, jgid) + + def __init__(self, World world not None, jointgroup=None): + self.world = world + if jointgroup != None: + jointgroup._addjoint(self) + + # setAnchor + def setAnchor(self, pos): + """setAnchor(pos) + + Set the universal anchor. + + @param pos: Anchor position + @type pos: 3-sequence of floats + """ + dJointSetUniversalAnchor(self.jid, pos[0], pos[1], pos[2]) + + # getAnchor + def getAnchor(self): + """getAnchor() -> 3-tuple of floats + + Get the joint anchor point, in world coordinates. This returns + the point on body 1. If the joint is perfectly satisfied, this + will be the same as the point on body 2. + """ + + cdef dVector3 p + dJointGetUniversalAnchor(self.jid, p) + return p[0], p[1], p[2] + + # getAnchor2 + def getAnchor2(self): + """getAnchor2() -> 3-tuple of floats + + Get the joint anchor point, in world coordinates. This returns + the point on body 2. If the joint is perfectly satisfied, this + will be the same as the point on body 1. + """ + + cdef dVector3 p + dJointGetUniversalAnchor2(self.jid, p) + return p[0], p[1], p[2] + + # setAxis1 + def setAxis1(self, axis): + """setAxis1(axis) + + Set the first universal axis. Axis 1 and axis 2 should be + perpendicular to each other. + + @param axis: Joint axis + @type axis: 3-sequence of floats + """ + dJointSetUniversalAxis1(self.jid, axis[0], axis[1], axis[2]) + + # getAxis1 + def getAxis1(self): + """getAxis1() -> 3-tuple of floats + + Get the first univeral axis. + """ + cdef dVector3 a + dJointGetUniversalAxis1(self.jid, a) + return a[0], a[1], a[2] + + # setAxis2 + def setAxis2(self, axis): + """setAxis2(axis) + + Set the second universal axis. Axis 1 and axis 2 should be + perpendicular to each other. + + @param axis: Joint axis + @type axis: 3-sequence of floats + """ + dJointSetUniversalAxis2(self.jid, axis[0], axis[1], axis[2]) + + # getAxis2 + def getAxis2(self): + """getAxis2() -> 3-tuple of floats + + Get the second univeral axis. + """ + cdef dVector3 a + dJointGetUniversalAxis2(self.jid, a) + return a[0], a[1], a[2] + + # addTorques + def addTorques(self, torque1, torque2): + """addTorques(torque1, torque2) + + Applies torque1 about axis 1, and torque2 about axis 2. + + @param torque1: Torque 1 magnitude + @param torque2: Torque 2 magnitude + @type torque1: float + @type torque2: float + """ + dJointAddUniversalTorques(self.jid, torque1, torque2) + + def getAngle1(self): + return dJointGetUniversalAngle1(self.jid) + + def getAngle2(self): + return dJointGetUniversalAngle2(self.jid) + + def getAngle1Rate(self): + return dJointGetUniversalAngle1Rate(self.jid) + + def getAngle2Rate(self): + return dJointGetUniversalAngle2Rate(self.jid) + + # setParam + def setParam(self, param, value): + dJointSetUniversalParam(self.jid, param, value) + + # getParam + def getParam(self, param): + return dJointGetUniversalParam(self.jid, param) + + +# Hinge2Joint +cdef class Hinge2Joint(Joint): + """Hinge2 joint. + + Constructor:: + + Hinge2Joint(world, jointgroup=None) + """ + + def __cinit__(self, World world not None, jointgroup=None): + cdef JointGroup jg + cdef dJointGroupID jgid + + jgid = NULL + if jointgroup != None: + jg = jointgroup + jgid = jg.gid + self.jid = dJointCreateHinge2(world.wid, jgid) + + def __init__(self, World world, jointgroup=None): + self.world = world + if jointgroup != None: + jointgroup._addjoint(self) + + # setAnchor + def setAnchor(self, pos): + """setAnchor(pos) + + Set the hinge-2 anchor. + + @param pos: Anchor position + @type pos: 3-sequence of floats + """ + dJointSetHinge2Anchor(self.jid, pos[0], pos[1], pos[2]) + + # getAnchor + def getAnchor(self): + """getAnchor() -> 3-tuple of floats + + Get the joint anchor point, in world coordinates. This returns + the point on body 1. If the joint is perfectly satisfied, this + will be the same as the point on body 2. + """ + + cdef dVector3 p + dJointGetHinge2Anchor(self.jid, p) + return p[0], p[1], p[2] + + # getAnchor2 + def getAnchor2(self): + """getAnchor2() -> 3-tuple of floats + + Get the joint anchor point, in world coordinates. This returns + the point on body 2. If the joint is perfectly satisfied, this + will be the same as the point on body 1. + """ + + cdef dVector3 p + dJointGetHinge2Anchor2(self.jid, p) + return p[0], p[1], p[2] + + # setAxis1 + def setAxis1(self, axis): + """setAxis1(axis) + + Set the first hinge-2 axis. Axis 1 and axis 2 must not lie + along the same line. + + @param axis: Joint axis + @type axis: 3-sequence of floats + """ + + dJointSetHinge2Axis1(self.jid, axis[0], axis[1], axis[2]) + + # getAxis1 + def getAxis1(self): + """getAxis1() -> 3-tuple of floats + + Get the first hinge-2 axis. + """ + cdef dVector3 a + dJointGetHinge2Axis1(self.jid, a) + return a[0], a[1], a[2] + + # setAxis2 + def setAxis2(self, axis): + """setAxis2(axis) + + Set the second hinge-2 axis. Axis 1 and axis 2 must not lie + along the same line. + + @param axis: Joint axis + @type axis: 3-sequence of floats + """ + dJointSetHinge2Axis2(self.jid, axis[0], axis[1], axis[2]) + + # getAxis2 + def getAxis2(self): + """getAxis2() -> 3-tuple of floats + + Get the second hinge-2 axis. + """ + cdef dVector3 a + dJointGetHinge2Axis2(self.jid, a) + return a[0], a[1], a[2] + + # getAngle + def getAngle1(self): + """getAngle1() -> float + + Get the first hinge-2 angle (around axis 1). + + When the anchor or axis is set, the current position of the + attached bodies is examined and that position will be the zero + angle. + """ + return dJointGetHinge2Angle1(self.jid) + + # getAngle1Rate + def getAngle1Rate(self): + """getAngle1Rate() -> float + + Get the time derivative of the first hinge-2 angle. + """ + return dJointGetHinge2Angle1Rate(self.jid) + + # getAngle2Rate + def getAngle2Rate(self): + """getAngle2Rate() -> float + + Get the time derivative of the second hinge-2 angle. + """ + return dJointGetHinge2Angle2Rate(self.jid) + + # addTorques + def addTorques(self, torque1, torque2): + """addTorques(torque1, torque2) + + Applies torque1 about axis 1, and torque2 about axis 2. + + @param torque1: Torque 1 magnitude + @param torque2: Torque 2 magnitude + @type torque1: float + @type torque2: float + """ + dJointAddHinge2Torques(self.jid, torque1, torque2) + + # setParam + def setParam(self, param, value): + dJointSetHinge2Param(self.jid, param, value) + + # getParam + def getParam(self, param): + return dJointGetHinge2Param(self.jid, param) + + +# FixedJoint +cdef class FixedJoint(Joint): + """Fixed joint. + + Constructor:: + + FixedJoint(world, jointgroup=None) + """ + + def __cinit__(self, World world not None, jointgroup=None): + cdef JointGroup jg + cdef dJointGroupID jgid + + jgid = NULL + if jointgroup != None: + jg = jointgroup + jgid = jg.gid + self.jid = dJointCreateFixed(world.wid, jgid) + + def __init__(self, World world not None, jointgroup=None): + self.world = world + if jointgroup != None: + jointgroup._addjoint(self) + + # setFixed + def setFixed(self): + """setFixed() + + Call this on the fixed joint after it has been attached to + remember the current desired relative offset and desired + relative rotation between the bodies. + """ + dJointSetFixed(self.jid) + + +# ContactJoint +cdef class ContactJoint(Joint): + """Contact joint. + + Constructor:: + + ContactJoint(world, jointgroup, contact) + """ + + def __cinit__(self, World world not None, jointgroup, Contact contact): + cdef JointGroup jg + cdef dJointGroupID jgid + jgid = NULL + if jointgroup != None: + jg = jointgroup + jgid = jg.gid + self.jid = dJointCreateContact(world.wid, jgid, &contact._contact) + + def __init__(self, World world not None, jointgroup, Contact contact): + self.world = world + if jointgroup != None: + jointgroup._addjoint(self) + +# AMotor +cdef class AMotor(Joint): + """AMotor joint. + + Constructor:: + + AMotor(world, jointgroup=None) + """ + + def __cinit__(self, World world not None, jointgroup=None): + cdef JointGroup jg + cdef dJointGroupID jgid + + jgid = NULL + if jointgroup != None: + jg = jointgroup + jgid = jg.gid + self.jid = dJointCreateAMotor(world.wid, jgid) + + def __init__(self, World world not None, jointgroup=None): + self.world = world + if jointgroup != None: + jointgroup._addjoint(self) + + # setMode + def setMode(self, mode): + """setMode(mode) + + Set the angular motor mode. mode must be either AMotorUser or + AMotorEuler. + + @param mode: Angular motor mode + @type mode: int + """ + dJointSetAMotorMode(self.jid, mode) + + # getMode + def getMode(self): + """getMode() + + Return the angular motor mode (AMotorUser or AMotorEuler). + """ + return dJointGetAMotorMode(self.jid) + + # setNumAxes + def setNumAxes(self, int num): + """setNumAxes(num) + + Set the number of angular axes that will be controlled by the AMotor. + num may be in the range from 0 to 3. + + @param num: Number of axes (0-3) + @type num: int + """ + dJointSetAMotorNumAxes(self.jid, num) + + # getNumAxes + def getNumAxes(self): + """getNumAxes() -> int + + Get the number of angular axes that are controlled by the AMotor. + """ + return dJointGetAMotorNumAxes(self.jid) + + # setAxis + def setAxis(self, int anum, int rel, axis): + """setAxis(anum, rel, axis) + + Set an AMotor axis. + + The anum argument selects the axis to change (0,1 or 2). + Each axis can have one of three "relative orientation" modes, + selected by rel: + + 0: The axis is anchored to the global frame. + 1: The axis is anchored to the first body. + 2: The axis is anchored to the second body. + + The axis vector is always specified in global coordinates + regardless of the setting of rel. + + @param anum: Axis number + @param rel: Relative orientation mode + @param axis: Axis + @type anum: int + @type rel: int + @type axis: 3-sequence of floats + """ + dJointSetAMotorAxis(self.jid, anum, rel, axis[0], axis[1], axis[2]) + + # getAxis + def getAxis(self, int anum): + """getAxis(anum) + + Get an AMotor axis. + + @param anum: Axis index (0-2) + @type anum: int + """ + cdef dVector3 a + dJointGetAMotorAxis(self.jid, anum, a) + return a[0], a[1], a[2] + + # getAxisRel + def getAxisRel(self, int anum): + """getAxisRel(anum) -> int + + Get the relative mode of an axis. + + @param anum: Axis index (0-2) + @type anum: int + """ + return dJointGetAMotorAxisRel(self.jid, anum) + + # setAngle + def setAngle(self, int anum, angle): + """setAngle(anum, angle) + + Tell the AMotor what the current angle is along axis anum. + + @param anum: Axis index + @param angle: Angle + @type anum: int + @type angle: float + """ + dJointSetAMotorAngle(self.jid, anum, angle) + + # getAngle + def getAngle(self, int anum): + """getAngle(anum) -> float + + Return the current angle for axis anum. + + @param anum: Axis index + @type anum: int + """ + return dJointGetAMotorAngle(self.jid, anum) + + # getAngleRate + def getAngleRate(self, int anum): + """getAngleRate(anum) -> float + + Return the current angle rate for axis anum. + + @param anum: Axis index + @type anum: int + """ + return dJointGetAMotorAngleRate(self.jid, anum) + + # addTorques + def addTorques(self, torque0, torque1, torque2): + """addTorques(torque0, torque1, torque2) + + Applies torques about the AMotor's axes. + + @param torque0: Torque 0 magnitude + @param torque1: Torque 1 magnitude + @param torque2: Torque 2 magnitude + @type torque0: float + @type torque1: float + @type torque2: float + """ + dJointAddAMotorTorques(self.jid, torque0, torque1, torque2) + + # setParam + def setParam(self, param, value): + dJointSetAMotorParam(self.jid, param, value) + + # getParam + def getParam(self, param): + return dJointGetAMotorParam(self.jid, param) + + +# LMotor +cdef class LMotor(Joint): + """LMotor joint. + + Constructor:: + + LMotor(world, jointgroup=None) + """ + + def __cinit__(self, World world not None, jointgroup=None): + cdef JointGroup jg + cdef dJointGroupID jgid + + jgid = NULL + if jointgroup != None: + jg = jointgroup + jgid = jg.gid + self.jid = dJointCreateLMotor(world.wid, jgid) + + def __init__(self, World world not None, jointgroup=None): + self.world = world + if jointgroup != None: + jointgroup._addjoint(self) + + # setNumAxes + def setNumAxes(self, int num): + """setNumAxes(num) + + Set the number of angular axes that will be controlled by the LMotor. + num may be in the range from 0 to 3. + + @param num: Number of axes (0-3) + @type num: int + """ + dJointSetLMotorNumAxes(self.jid, num) + + # getNumAxes + def getNumAxes(self): + """getNumAxes() -> int + + Get the number of angular axes that are controlled by the LMotor. + """ + return dJointGetLMotorNumAxes(self.jid) + + # setAxis + def setAxis(self, int anum, int rel, axis): + """setAxis(anum, rel, axis) + + Set an LMotor axis. + + The anum argument selects the axis to change (0,1 or 2). + Each axis can have one of three "relative orientation" modes, + selected by rel: + + 0: The axis is anchored to the global frame. + 1: The axis is anchored to the first body. + 2: The axis is anchored to the second body. + + @param anum: Axis number + @param rel: Relative orientation mode + @param axis: Axis + @type anum: int + @type rel: int + @type axis: 3-sequence of floats + """ + dJointSetLMotorAxis(self.jid, anum, rel, axis[0], axis[1], axis[2]) + + # getAxis + def getAxis(self, int anum): + """getAxis(anum) + + Get an LMotor axis. + + @param anum: Axis index (0-2) + @type anum: int + """ + cdef dVector3 a + dJointGetLMotorAxis(self.jid, anum, a) + return a[0], a[1], a[2] + + # setParam + def setParam(self, param, value): + dJointSetLMotorParam(self.jid, param, value) + + # getParam + def getParam(self, param): + return dJointGetLMotorParam(self.jid, param) + + +# Plane2DJoint +cdef class Plane2DJoint(Joint): + """Plane-2D Joint. + + Constructor:: + + Plane2DJoint(world, jointgroup=None) + """ + + def __cinit__(self, World world not None, jointgroup=None): + cdef JointGroup jg + cdef dJointGroupID jgid + + jgid = NULL + if jointgroup != None: + jg = jointgroup + jgid = jg.gid + self.jid = dJointCreatePlane2D(world.wid, jgid) + + def __init__(self, World world not None, jointgroup=None): + self.world = world + if jointgroup != None: + jointgroup._addjoint(self) + + def setXParam(self, param, value): + dJointSetPlane2DXParam(self.jid, param, value) + + def setYParam(self, param, value): + dJointSetPlane2DYParam(self.jid, param, value) + + def setAngleParam(self, param, value): + dJointSetPlane2DAngleParam(self.jid, param, value) + + +# PRJoint +cdef class PRJoint(Joint): + """Prismatic and Rotoide Joint. + + Constructor:: + + PRJoint(world, jointgroup=None) + """ + + def __cinit__(self, World world not None, jointgroup=None): + cdef JointGroup jg + cdef dJointGroupID jgid + + jgid = NULL + if jointgroup != None: + jg = jointgroup + jgid = jg.gid + self.jid = dJointCreatePR(world.wid, jgid) + + def __init__(self, World world not None, jointgroup=None): + self.world = world + if jointgroup != None: + jointgroup._addjoint(self) + + def getPosition(self): + """getPosition() + + Get a PRJoint's linear extension. (i.e. the prismatic's extension) + """ + return dJointGetPRPosition(self.jid) + + def setAnchor(self, pos): + """setAnchor(pos) + + Set a PRJoint anchor. + + @param pos: Anchor position + @type pos: 3-sequence of floats + """ + dJointSetPRAnchor(self.jid, pos[0], pos[1], pos[2]) + + def getAnchor(self): + """getAnchor() + + Get a PRJoint anchor. + """ + cdef dVector3 a + dJointGetPRAnchor(self.jid, a) + return a[0], a[1], a[2] + + def setAxis1(self, axis): + """setAxis1(axis) + + Set a PRJoint's prismatic axis. + + @param axis: Axis + @type axis: 3-sequence of floats + """ + dJointSetPRAxis1(self.jid, axis[0], axis[1], axis[2]) + + def getAxis1(self): + """getAxis1() + + Get a PRJoint's prismatic axis. + """ + cdef dVector3 a + dJointGetPRAxis1(self.jid, a) + return a[0], a[1], a[2] + + def setAxis2(self, axis): + """setAxis2(axis) + + Set a PRJoint's rotoide axis. + + @param axis: Axis + @type axis: 3-sequence of floats + """ + dJointSetPRAxis2(self.jid, axis[0], axis[1], axis[2]) + + def getAxis2(self): + """getAxis2() + + Get a PRJoint's rotoide axis. + """ + cdef dVector3 a + dJointGetPRAxis2(self.jid, a) + return a[0], a[1], a[2] + + +# Geom base class +cdef class GeomObject: + """This is the abstract base class for all geom objects. + """ + + # The id of the geom object as returned by dCreateXxxx() + cdef dGeomID gid + # The space in which the geom was placed (or None). This reference + # is kept so that the space won't be destroyed while there are still + # geoms around that might use it. + cdef object space + # The body that the geom was attached to (or None). + cdef object body + + # A dictionary with user defined attributes + cdef object attribs + + cdef object __weakref__ + + def __cinit__(self, *a, **kw): + self.gid = NULL + self.space = None + self.body = None + self.attribs = {} + + def __init__(self, *a, **kw): + raise NotImplementedError( + "GeomObject base class can't be used directly") + + def __dealloc__(self): + if self.gid != NULL: + dGeomDestroy(self.gid) + self.gid = NULL + + def __getattr__(self, name): + if name in self.attribs: + return self.attribs[name] + else: + raise AttributeError("geom has no attribute '%s'" % name) + + def __setattr__(self, name, val): + self.attribs[name] = val + + def __delattr__(self, name): + if name in self.attribs: + del self.attribs[name] + else: + raise AttributeError("geom has no attribute '%s'" % name) + + def _id(self): + """_id() -> int + + Return the internal id of the geom (dGeomID) as returned by + the dCreateXyz() functions. + + This method has to be overwritten in derived methods. + """ + raise NotImplementedError("Bug: The _id() method is not implemented") + + def placeable(self): + """placeable() -> bool + + Returns True if the geom object is a placeable geom. + + This method has to be overwritten in derived methods. + """ + return False + + def setBody(self, Body body): + """setBody(body) + + Set the body associated with a placeable geom. + + @param body: The Body object or None. + @type body: Body + """ + + if not self.placeable(): + raise ValueError( + "Non-placeable geoms cannot have a body associated to them") + + if body == None: + dGeomSetBody(self.gid, NULL) + else: + dGeomSetBody(self.gid, body.bid) + self.body = body + + def getBody(self): + """getBody() -> Body + + Get the body associated with this geom. + """ + if not self.placeable(): + return environment + + return self.body + + def setPosition(self, pos): + """setPosition(pos) + + Set the position of the geom. If the geom is attached to a body, + the body's position will also be changed. + + @param pos: Position + @type pos: 3-sequence of floats + """ + if not self.placeable(): + raise ValueError("Cannot set a position on non-placeable geoms") + dGeomSetPosition(self.gid, pos[0], pos[1], pos[2]) + + def getPosition(self): + """getPosition() -> 3-tuple + + Get the current position of the geom. If the geom is attached to + a body the returned value is the body's position. + """ + if not self.placeable(): + raise ValueError("Non-placeable geoms do not have a position") + + cdef dReal* p + p = dGeomGetPosition(self.gid) + return p[0], p[1], p[2] + + def setRotation(self, R): + """setRotation(R) + + Set the orientation of the geom. If the geom is attached to a body, + the body's orientation will also be changed. + + @param R: Rotation matrix + @type R: 9-sequence of floats + """ + if not self.placeable(): + raise ValueError("Cannot set a rotation on non-placeable geoms") + + cdef dMatrix3 m + m[0] = R[0] + m[1] = R[1] + m[2] = R[2] + m[3] = 0 + m[4] = R[3] + m[5] = R[4] + m[6] = R[5] + m[7] = 0 + m[8] = R[6] + m[9] = R[7] + m[10] = R[8] + m[11] = 0 + dGeomSetRotation(self.gid, m) + + def getRotation(self): + """getRotation() -> 9-tuple + + Get the current orientation of the geom. If the geom is attached to + a body the returned value is the body's orientation. + """ + if not self.placeable(): + raise ValueError("Non-placeable geoms do not have a rotation") + + cdef dReal* m + m = dGeomGetRotation(self.gid) + return [m[0], m[1], m[2], m[4], m[5], m[6], m[8], m[9], m[10]] + + def getQuaternion(self): + """getQuaternion() -> (w,x,y,z) + + Get the current orientation of the geom. If the geom is attached to + a body the returned value is the body's orientation. + """ + if not self.placeable(): + raise ValueError("Non-placeable geoms do not have an orientation") + + cdef dQuaternion q + dGeomGetQuaternion(self.gid, q) + return q[0], q[1], q[2], q[3] + + def setQuaternion(self, q): + """setQuaternion(q) + + Set the orientation of the geom. If the geom is attached to a body, + the body's orientation will also be changed. + + @param q: Quaternion (w,x,y,z) + @type q: 4-sequence of floats + """ + if not self.placeable(): + raise ValueError("Cannot set a quaternion on non-placeable geoms") + + cdef dQuaternion cq + cq[0] = q[0] + cq[1] = q[1] + cq[2] = q[2] + cq[3] = q[3] + dGeomSetQuaternion(self.gid, cq) + + def setOffsetPosition(self, pos): + """setOffsetPosition(pos) + + Set the offset position of the geom. The geom must be attached to a + body. If the geom did not have an offset, it is automatically created. + This sets up an additional (local) transformation for the geom, since + geoms attached to a body share their global position and rotation. + + @param pos: Position + @type pos: 3-sequence of floats + """ + if self.body == None: + raise ValueError("Cannot set an offset position on a geom before " + "calling setBody") + dGeomSetOffsetPosition(self.gid, pos[0], pos[1], pos[2]) + + def getOffsetPosition(self): + """getOffsetPosition() -> 3-tuple + + Get the offset position of the geom. + """ + cdef dReal* p + p = dGeomGetOffsetPosition(self.gid) + return (p[0],p[1],p[2]) + + def setOffsetRotation(self, R): + """setOffsetRotation(R) + + Set the offset rotation of the geom. The geom must be attached to a + body. If the geom did not have an offset, it is automatically created. + This sets up an additional (local) transformation for the geom, since + geoms attached to a body share their global position and rotation. + + @param R: Rotation matrix + @type R: 9-sequence of floats + """ + if self.body == None: + raise ValueError("Cannot set an offset rotation on a geom before " + "calling setBody") + + cdef dMatrix3 m + m[0] = R[0] + m[1] = R[1] + m[2] = R[2] + m[3] = 0 + m[4] = R[3] + m[5] = R[4] + m[6] = R[5] + m[7] = 0 + m[8] = R[6] + m[9] = R[7] + m[10] = R[8] + m[11] = 0 + dGeomSetOffsetRotation(self.gid, m) + + def getOffsetRotation(self): + """getOffsetRotation() -> 9-tuple + + Get the offset rotation of the geom. + """ + cdef dReal* m + m = dGeomGetOffsetRotation(self.gid) + return [m[0], m[1], m[2], m[4], m[5], m[6], m[8], m[9], m[10]] + + def clearOffset(self): + """clearOffset() + + Disable the offset transform of the geom. + """ + dGeomClearOffset(self.gid) + + def getAABB(self): + """getAABB() -> 6-tuple + + Return an axis aligned bounding box that surrounds the geom. + The return value is a 6-tuple (minx, maxx, miny, maxy, minz, maxz). + """ + cdef dReal aabb[6] + + dGeomGetAABB(self.gid, aabb) + return aabb[0], aabb[1], aabb[2], aabb[3], aabb[4], aabb[5] + + def isSpace(self): + """isSpace() -> bool + + Return 1 if the given geom is a space, or 0 if not.""" + return dGeomIsSpace(self.gid) + + def getSpace(self): + """getSpace() -> Space + + Return the space that the given geometry is contained in, + or return None if it is not contained in any space.""" + return self.space + + def setCollideBits(self, bits): + """setCollideBits(bits) + + Set the "collide" bitfields for this geom. + + @param bits: Collide bit field + @type bits: int/long + """ + dGeomSetCollideBits(self.gid, long(bits)) + + def setCategoryBits(self, bits): + """setCategoryBits(bits) + + Set the "category" bitfields for this geom. + + @param bits: Category bit field + @type bits: int/long + """ + dGeomSetCategoryBits(self.gid, long(bits)) + + def getCollideBits(self): + """getCollideBits() -> long + + Return the "collide" bitfields for this geom. + """ + return dGeomGetCollideBits(self.gid) + + def getCategoryBits(self): + """getCategoryBits() -> long + + Return the "category" bitfields for this geom. + """ + return dGeomGetCategoryBits(self.gid) + + def enable(self): + """enable() + + Enable the geom.""" + dGeomEnable(self.gid) + + def disable(self): + """disable() + + Disable the geom.""" + dGeomDisable(self.gid) + + def isEnabled(self): + """isEnabled() -> bool + + Return True if the geom is enabled.""" + return dGeomIsEnabled(self.gid) + + +# _SpaceIterator +class _SpaceIterator: + """Iterates over the geoms inside a Space. + """ + + def __init__(self, space): + self.space = space + self.idx = 0 + + def __iter__(self): + return self + + def next(self): + if self.idx >= self.space.getNumGeoms(): + raise StopIteration + else: + res = self.space.getGeom(self.idx) + self.idx = self.idx + 1 + return res + + +# SpaceBase +cdef class SpaceBase(GeomObject): + """Space class (container for geometry objects). + + A Space object is a container for geometry objects which are used + to do collision detection. + The space does high level collision culling, which means that it + can identify which pairs of geometry objects are potentially + touching. + + This Space class can be used for both, a SimpleSpace and a HashSpace + (see ODE documentation). + + >>> space = Space(type=0) # Create a SimpleSpace + >>> space = Space(type=1) # Create a HashSpace + """ + + # The id of the space. Actually this is a copy of the value in self.gid + # (as the Space is derived from GeomObject) which can be used without + # casting whenever a *space* id is required. + cdef dSpaceID sid + + # Dictionary with Geomobjects. Key is the ID (geom._id()) and the value + # is the geom object (Python wrapper). This is used in collide_callback() +# cdef object geom_dict + + def __cinit__(self, *a, **kw): + pass + + def __init__(self, *a, **kw): + raise NotImplementedError("The SpaceBase class can't be used directly") + + def __dealloc__(self): + if self.gid != NULL: + dSpaceDestroy(self.sid) + self.sid = NULL + self.gid = NULL + +# def _addgeom(self, geom): +# """Insert the geom object into the dictionary (internal method). +# +# This method has to called in the constructor of a geom object. +# """ +# self.geom_dict[geom._id()]=geom + +# def _id2geom(self, id): +# """Get the Python wrapper that corresponds to an ID. +# +# The ID is the integer value, as returned by geom._id(). +# If the ID is unknown then None is returned. +# """ +# if id in self.geom_dict: +# return self.geom_dict[id] +# else: +# return None + + def _id(self): + cdef size_t id + id = self.sid + return id + + def __len__(self): + return self.getNumGeoms() + + def __iter__(self): + return _SpaceIterator(self) + + def add(self, GeomObject geom): + """add(geom) + + Add a geom to a space. This does nothing if the geom is + already in the space. + + @param geom: Geom object to add + @type geom: GeomObject + """ + + dSpaceAdd(self.sid, geom.gid) + + def remove(self, GeomObject geom): + """remove(geom) + + Remove a geom from a space. + + @param geom: Geom object to remove + @type geom: GeomObject + """ + dSpaceRemove(self.sid, geom.gid) + + def query(self, GeomObject geom): + """query(geom) -> bool + + Return True if the given geom is in the space. + + @param geom: Geom object to check + @type geom: GeomObject + """ + return dSpaceQuery(self.sid, geom.gid) + + def getNumGeoms(self): + """getNumGeoms() -> int + + Return the number of geoms contained within the space. + """ + return dSpaceGetNumGeoms(self.sid) + + def getGeom(self, int idx): + """getGeom(idx) -> GeomObject + + Return the geom with the given index contained within the space. + + @param idx: Geom index (0,1,...,getNumGeoms()-1) + @type idx: int + """ + cdef dGeomID gid + + # Check the index + if idx < 0 or idx >= dSpaceGetNumGeoms(self.sid): + raise IndexError("geom index out of range") + + gid = dSpaceGetGeom(self.sid, idx) + if gid not in _geom_c2py_lut: + raise RuntimeError( + "geom id cannot be translated to a Python object") + + return _geom_c2py_lut[gid] + + def collide(self, arg, callback): + """collide(arg, callback) + + Call a callback function one or more times, for all + potentially intersecting objects in the space. The callback + function takes 3 arguments: + + def NearCallback(arg, geom1, geom2): + + The arg parameter is just passed on to the callback function. + Its meaning is user defined. The geom1 and geom2 arguments are + the geometry objects that may be near each other. The callback + function can call the function collide() (not the Space + method) on geom1 and geom2, perhaps first determining + whether to collide them at all based on other information. + + @param arg: A user argument that is passed to the callback function + @param callback: Callback function + @type callback: callable + """ + + cdef void* data + cdef object tup + tup = (callback, arg) + data = tup + dSpaceCollide(self.sid, data, collide_callback) + + +# Callback function for the dSpaceCollide() call in the Space.collide() method +# The data parameter is a tuple (Python-Callback, Arguments). +# The function calls a Python callback function with 3 arguments: +# def callback(UserArg, Geom1, Geom2) +# Geom1 and Geom2 are instances of GeomXyz classes. +cdef void collide_callback(void* data, dGeomID o1, dGeomID o2): + cdef object tup +# cdef Space space + cdef size_t id1, id2 + +# if (dGeomGetBody(o1)==dGeomGetBody(o2)): +# return + + tup = data + callback, arg = tup + id1 = o1 + id2 = o2 + g1 = _geom_c2py_lut[id1] + g2 = _geom_c2py_lut[id2] + callback(arg, g1, g2) + + +# SimpleSpace +cdef class SimpleSpace(SpaceBase): + """Simple space. + + This does not do any collision culling - it simply checks every + possible pair of geoms for intersection, and reports the pairs + whose AABBs overlap. The time required to do intersection testing + for n objects is O(n**2). This should not be used for large numbers + of objects, but it can be the preferred algorithm for a small + number of objects. This is also useful for debugging potential + problems with the collision system. + """ + + def __cinit__(self, space=None): + cdef SpaceBase sp + cdef dSpaceID parentid + + parentid = NULL + if space != None: + sp = space + parentid = sp.sid + + self.sid = dSimpleSpaceCreate(parentid) + + # Copy the ID + self.gid = self.sid + + dSpaceSetCleanup(self.sid, 0) + _geom_c2py_lut[self.sid] = self + + def __init__(self, space=None): + pass + +# HashSpace +cdef class HashSpace(SpaceBase): + """Multi-resolution hash table space. + + This uses an internal data structure that records how each geom + overlaps cells in one of several three dimensional grids. Each + grid has cubical cells of side lengths 2**i, where i is an integer + that ranges from a minimum to a maximum value. The time required + to do intersection testing for n objects is O(n) (as long as those + objects are not clustered together too closely), as each object + can be quickly paired with the objects around it. + """ + + def __cinit__(self, space=None): + cdef SpaceBase sp + cdef dSpaceID parentid + + parentid = NULL + if space != None: + sp = space + parentid = sp.sid + + self.sid = dHashSpaceCreate(parentid) + + # Copy the ID + self.gid = self.sid + + dSpaceSetCleanup(self.sid, 0) + _geom_c2py_lut[self.sid] = self + + def __init__(self, space=None): + pass + + def setLevels(self, int minlevel, int maxlevel): + """setLevels(minlevel, maxlevel) + + Sets the size of the smallest and largest cell used in the + hash table. The actual size will be 2^minlevel and 2^maxlevel + respectively. + """ + + if minlevel > maxlevel: + raise ValueError( + "minlevel (%d) must be less than or equal to maxlevel (%d)" % + (minlevel, maxlevel)) + + dHashSpaceSetLevels(self.sid, minlevel, maxlevel) + + def getLevels(self): + """getLevels() -> (minlevel, maxlevel) + + Gets the size of the smallest and largest cell used in the + hash table. The actual size is 2^minlevel and 2^maxlevel + respectively. + """ + + cdef int minlevel + cdef int maxlevel + dHashSpaceGetLevels(self.sid, &minlevel, &maxlevel) + return minlevel, maxlevel + + +# QuadTreeSpace +cdef class QuadTreeSpace(SpaceBase): + """Quadtree space. + + This uses a pre-allocated hierarchical grid-based AABB tree to + quickly cull collision checks. It's exceptionally quick for large + amounts of objects in landscape-shaped worlds. The amount of + memory used is 4**depth * 32 bytes. + + Currently getGeom() is not implemented for the quadtree space. + """ + + def __cinit__(self, center, extents, depth, space=None): + cdef SpaceBase sp + cdef dSpaceID parentid + cdef dVector3 c + cdef dVector3 e + + parentid = NULL + if space != None: + sp = space + parentid = sp.sid + + c[0] = center[0] + c[1] = center[1] + c[2] = center[2] + e[0] = extents[0] + e[1] = extents[1] + e[2] = extents[2] + self.sid = dQuadTreeSpaceCreate(parentid, c, e, depth) + + # Copy the ID + self.gid = self.sid + + dSpaceSetCleanup(self.sid, 0) + _geom_c2py_lut[self.sid] = self + + def __init__(self, center, extents, depth, space=None): + pass + + +def Space(space_type=0): + """Space factory function. + + Depending on the type argument this function either returns a + SimpleSpace (space_type=0) or a HashSpace (space_type=1). + + This function is provided to remain compatible with previous + versions of PyODE where there was only one Space class. + + >>> space = Space(space_type=0) # Create a SimpleSpace + >>> space = Space(space_type=1) # Create a HashSpace + """ + if space_type == 0: + return SimpleSpace() + elif space_type == 1: + return HashSpace() + else: + raise ValueError("Unknown space type (%d)" % space_type) + + +# GeomSphere +cdef class GeomSphere(GeomObject): + """Sphere geometry. + + This class represents a sphere centered at the origin. + + Constructor:: + + GeomSphere(space=None, radius=1.0) + """ + + def __cinit__(self, space=None, radius=1.0): + cdef SpaceBase sp + cdef dSpaceID sid + + sid = NULL + if space != None: + sp = space + sid = sp.sid + self.gid = dCreateSphere(sid, radius) +# if space != None: +# space._addgeom(self) + + _geom_c2py_lut[self.gid] = self + + def __init__(self, space=None, radius=1.0): + self.space = space + self.body = None + + def placeable(self): + return True + + def _id(self): + cdef size_t id + id = self.gid + return id + + def setRadius(self, radius): + """setRadius(radius) + + Set the radius of the sphere. + + @param radius: New radius + @type radius: float + """ + dGeomSphereSetRadius(self.gid, radius) + + def getRadius(self): + """getRadius() -> float + + Return the radius of the sphere. + """ + return dGeomSphereGetRadius(self.gid) + + def pointDepth(self, p): + """pointDepth(p) -> float + + Return the depth of the point p in the sphere. Points inside + the geom will have positive depth, points outside it will have + negative depth, and points on the surface will have zero + depth. + + @param p: Point + @type p: 3-sequence of floats + """ + return dGeomSpherePointDepth(self.gid, p[0], p[1], p[2]) + + +# GeomBox +cdef class GeomBox(GeomObject): + """Box geometry. + + This class represents a box centered at the origin. + + Constructor:: + + GeomBox(space=None, lengths=(1.0, 1.0, 1.0)) + """ + + def __cinit__(self, space=None, lengths=(1.0, 1.0, 1.0)): + cdef SpaceBase sp + cdef dSpaceID sid + + sid = NULL + if space != None: + sp = space + sid = sp.sid + self.gid = dCreateBox(sid, lengths[0], lengths[1], lengths[2]) +# if space != None: +# space._addgeom(self) + + _geom_c2py_lut[self.gid] = self + + def __init__(self, space=None, lengths=(1.0, 1.0, 1.0)): + self.space = space + self.body = None + + def placeable(self): + return True + + def _id(self): + cdef size_t id + id = self.gid + return id + + def setLengths(self, lengths): + dGeomBoxSetLengths(self.gid, lengths[0], lengths[1], lengths[2]) + + def getLengths(self): + cdef dVector3 res + dGeomBoxGetLengths(self.gid, res) + return res[0], res[1], res[2] + + def pointDepth(self, p): + """pointDepth(p) -> float + + Return the depth of the point p in the box. Points inside the + geom will have positive depth, points outside it will have + negative depth, and points on the surface will have zero + depth. + + @param p: Point + @type p: 3-sequence of floats + """ + return dGeomBoxPointDepth(self.gid, p[0], p[1], p[2]) + + +# GeomPlane +cdef class GeomPlane(GeomObject): + """Plane geometry. + + This class represents an infinite plane. The plane equation is: + n.x*x + n.y*y + n.z*z = dist + + This object can't be attached to a body. + If you call getBody() on this object it always returns ode.environment. + + Constructor:: + + GeomPlane(space=None, normal=(0,0,1), dist=0) + + """ + + def __cinit__(self, space=None, normal=(0, 0, 1), dist=0): + cdef SpaceBase sp + cdef dSpaceID sid + + sid = NULL + if space != None: + sp = space + sid = sp.sid + self.gid = dCreatePlane(sid, normal[0], normal[1], normal[2], dist) +# if space != None: +# space._addgeom(self) + + _geom_c2py_lut[self.gid] = self + + def __init__(self, space=None, normal=(0, 0, 1), dist=0): + self.space = space + + def _id(self): + cdef size_t id + id = self.gid + return id + + def setParams(self, normal, dist): + dGeomPlaneSetParams(self.gid, normal[0], normal[1], normal[2], dist) + + def getParams(self): + cdef dVector4 res + dGeomPlaneGetParams(self.gid, res) + return ((res[0], res[1], res[2]), res[3]) + + def pointDepth(self, p): + """pointDepth(p) -> float + + Return the depth of the point p in the plane. Points inside the + geom will have positive depth, points outside it will have + negative depth, and points on the surface will have zero + depth. + + @param p: Point + @type p: 3-sequence of floats + """ + return dGeomPlanePointDepth(self.gid, p[0], p[1], p[2]) + + +# GeomCapsule +cdef class GeomCapsule(GeomObject): + """Capped cylinder geometry. + + This class represents a capped cylinder aligned along the local Z axis + and centered at the origin. + + Constructor:: + + GeomCapsule(space=None, radius=0.5, length=1.0) + + The length parameter does not include the caps. + """ + + def __cinit__(self, space=None, radius=0.5, length=1.0): + cdef SpaceBase sp + cdef dSpaceID sid + + sid = NULL + if space != None: + sp = space + sid = sp.sid + self.gid = dCreateCapsule(sid, radius, length) +# if space != None: +# space._addgeom(self) + + _geom_c2py_lut[self.gid] = self + + def __init__(self, space=None, radius=0.5, length=1.0): + self.space = space + self.body = None + + def placeable(self): + return True + + def _id(self): + cdef size_t id + id = self.gid + return id + + def setParams(self, radius, length): + dGeomCapsuleSetParams(self.gid, radius, length) + + def getParams(self): + cdef dReal radius, length + dGeomCapsuleGetParams(self.gid, &radius, &length) + return radius, length + + def pointDepth(self, p): + """pointDepth(p) -> float + + Return the depth of the point p in the cylinder. Points inside the + geom will have positive depth, points outside it will have + negative depth, and points on the surface will have zero + depth. + + @param p: Point + @type p: 3-sequence of floats + """ + return dGeomCapsulePointDepth(self.gid, p[0], p[1], p[2]) + +GeomCCylinder = GeomCapsule # backwards compatibility + + +# GeomCylinder +cdef class GeomCylinder(GeomObject): + """Plain cylinder geometry. + + This class represents an uncapped cylinder aligned along the local Z axis + and centered at the origin. + + Constructor:: + + GeomCylinder(space=None, radius=0.5, length=1.0) + """ + + def __cinit__(self, space=None, radius=0.5, length=1.0): + cdef SpaceBase sp + cdef dSpaceID sid + + sid = NULL + if space != None: + sp = space + sid = sp.sid + self.gid = dCreateCylinder(sid, radius, length) +# if space != None: +# space._addgeom(self) + + _geom_c2py_lut[self.gid] = self + + def __init__(self, space=None, radius=0.5, length=1.0): + self.space = space + self.body = None + + def placeable(self): + return True + + def _id(self): + cdef size_t id + id = self.gid + return id + + def setParams(self, radius, length): + dGeomCylinderSetParams(self.gid, radius, length) + + def getParams(self): + cdef dReal radius, length + dGeomCylinderGetParams(self.gid, &radius, &length) + return radius, length + + ## dGeomCylinderPointDepth not implemented upstream in ODE 0.7 + + +# GeomRay +cdef class GeomRay(GeomObject): + """Ray object. + + A ray is different from all the other geom classes in that it does + not represent a solid object. It is an infinitely thin line that + starts from the geom's position and extends in the direction of + the geom's local Z-axis. + + Constructor:: + + GeomRay(space=None, rlen=1.0) + + """ + + def __cinit__(self, space=None, rlen=1.0): + cdef SpaceBase sp + cdef dSpaceID sid + + sid = NULL + if space != None: + sp = space + sid = sp.sid + self.gid = dCreateRay(sid, rlen) +# if space != None: +# space._addgeom(self) + + _geom_c2py_lut[self.gid] = self + + def __init__(self, space=None, rlen=1.0): + self.space = space + self.body = None + + def _id(self): + cdef size_t id + id = self.gid + return id + + def placeable(self): + return True + + def setLength(self, rlen): + '''setLength(rlen) + + Set length of the ray. + + @param rlen: length of the ray + @type rlen: float''' + dGeomRaySetLength(self.gid, rlen) + + def getLength(self): + '''getLength() -> length + + Get the length of the ray. + + @returns: length of the ray (float)''' + return dGeomRayGetLength(self.gid) + + def set(self, p, u): + '''set(p, u) + + Set the position and rotation of a ray. + + @param p: position + @type p: 3-sequence of floats + @param u: rotation + @type u: 3-sequence of floats''' + dGeomRaySet(self.gid, p[0], p[1], p[2], u[0], u[1], u[2]) + + def get(self): + '''get() -> ((p[0], p[1], p[2]), (u[0], u[1], u[2])) + + Return the position and rotation as a pair of + tuples. + + @returns: position and rotation''' + cdef dVector3 start + cdef dVector3 dir + dGeomRayGet(self.gid, start, dir) + return (start[0], start[1], start[2]), (dir[0], dir[1], dir[2]) + + +# GeomTransform +cdef class GeomTransform(GeomObject): + """GeomTransform. + + A geometry transform "T" is a geom that encapsulates another geom + "E", allowing E to be positioned and rotated arbitrarily with + respect to its point of reference. + + Constructor:: + + GeomTransform(space=None) + """ + + cdef object geom + + def __cinit__(self, space=None): + cdef SpaceBase sp + cdef dSpaceID sid + + sid = NULL + if space != None: + sp = space + sid = sp.sid + self.gid = dCreateGeomTransform(sid) + # Set cleanup mode to 0 as a contained geom will be deleted + # by its Python wrapper class + dGeomTransformSetCleanup(self.gid, 0) +# if space != None: +# space._addgeom(self) + + _geom_c2py_lut[self.gid] = self + + def __init__(self, space=None): + self.space = space + self.body = None + self.geom = None + + self.attribs = {} + + def placeable(self): + return True + + def _id(self): + cdef size_t id + id = self.gid + return id + + def setGeom(self, GeomObject geom not None): + """setGeom(geom) + + Set the geom that the geometry transform encapsulates. + A ValueError exception is thrown if a) the geom is not placeable, + b) the geom was already inserted into a space or c) the geom is + already associated with a body. + + @param geom: Geom object to encapsulate + @type geom: GeomObject + """ + cdef size_t id + + if not geom.placeable(): + raise ValueError( + "Only placeable geoms can be encapsulated by a GeomTransform") + if dGeomGetSpace(geom.gid) != 0: + raise ValueError( + "The encapsulated geom was already inserted into a space") + if dGeomGetBody(geom.gid) != 0: + raise ValueError( + "The encapsulated geom is already associated with a body") + + id = geom._id() + dGeomTransformSetGeom(self.gid, id) + self.geom = geom + + def getGeom(self): + """getGeom() -> GeomObject + + Get the geom that the geometry transform encapsulates. + """ + return self.geom + + def setInfo(self, int mode): + """setInfo(mode) + + Set the "information" mode of the geometry transform. + + With mode 0, when a transform object is collided with another + object, the geom field of the ContactGeom structure is set to the + geom that is encapsulated by the transform object. + + With mode 1, the geom field of the ContactGeom structure is set + to the transform object itself. + + @param mode: Information mode (0 or 1) + @type mode: int + """ + if mode < 0 or mode > 1: + raise ValueError( + "Invalid information mode (%d). Must be either 0 or 1." % mode) + dGeomTransformSetInfo(self.gid, mode) + + def getInfo(self): + """getInfo() -> int + + Get the "information" mode of the geometry transform (0 or 1). + + With mode 0, when a transform object is collided with another + object, the geom field of the ContactGeom structure is set to the + geom that is encapsulated by the transform object. + + With mode 1, the geom field of the ContactGeom structure is set + to the transform object itself. + """ + return dGeomTransformGetInfo(self.gid) + +###################################################################### + + +cdef class TriMeshData: + """This class stores the mesh data. + """ + + cdef dTriMeshDataID tmdid + cdef dReal* vertex_buffer + cdef int* face_buffer + + def __cinit__(self): + self.tmdid = dGeomTriMeshDataCreate() + self.vertex_buffer = NULL + self.face_buffer = NULL + + def __dealloc__(self): + if self.tmdid != NULL: + dGeomTriMeshDataDestroy(self.tmdid) + if self.vertex_buffer != NULL: + free(self.vertex_buffer) + if self.face_buffer != NULL: + free(self.face_buffer) + + def build(self, verts, faces): + """build(verts, faces) + + @param verts: Vertices + @type verts: Sequence of 3-sequences of floats + @param faces: Face definitions (three indices per face) + @type faces: Sequence of 3-sequences of ints + """ + cdef int numverts + cdef int numfaces + cdef dReal* vp + cdef int* fp + cdef int a, b, c + + numverts = len(verts) + numfaces = len(faces) + # Allocate the vertex and face buffer + self.vertex_buffer = malloc(numverts * 4 * sizeof(dReal)) + self.face_buffer = malloc(numfaces * 3 * sizeof(int)) + + # Fill the vertex buffer + vp = self.vertex_buffer + for v in verts: + vp[0] = v[0] + vp[1] = v[1] + vp[2] = v[2] + vp[3] = 0 + vp = vp + 4 + + # Fill the face buffer + fp = self.face_buffer + for f in faces: + a = f[0] + b = f[1] + c = f[2] + if (a < 0 or b < 0 or c < 0 or a >= numverts or b >= numverts or c >= numverts): + raise ValueError("Vertex index out of range") + fp[0] = a + fp[1] = b + fp[2] = c + fp = fp + 3 + + # Pass the data to ODE + dGeomTriMeshDataBuildSimple(self.tmdid, self.vertex_buffer, numverts, + self.face_buffer, numfaces * 3) + +###################################################################### + + +# GeomTriMesh +cdef class GeomTriMesh(GeomObject): + """TriMesh object. + + To construct the trimesh geom you need a TriMeshData object that + stores the actual mesh. This object has to be passed as first + argument to the constructor. + + Constructor:: + + GeomTriMesh(data, space=None) + """ + + # Keep a reference to the data + cdef TriMeshData data + + def __cinit__(self, TriMeshData data not None, space=None): + cdef SpaceBase sp + cdef dSpaceID sid + + self.data = data + + sid = NULL + if space != None: + sp = space + sid = sp.sid + self.gid = dCreateTriMesh(sid, data.tmdid, NULL, NULL, NULL) + + _geom_c2py_lut[self.gid] = self + + def __init__(self, TriMeshData data not None, space=None): + self.space = space + self.body = None + + def placeable(self): + return True + + def _id(self): + cdef size_t id + id = self.gid + return id + + def clearTCCache(self): + """clearTCCache() + + Clears the internal temporal coherence caches. + """ + dGeomTriMeshClearTCCache(self.gid) + + def getTriangle(self, int idx): + """getTriangle(idx) -> (v0, v1, v2) + + @param idx: Triangle index + @type idx: int + """ + + cdef dVector3 v0, v1, v2 + cdef dVector3* vp0 + cdef dVector3* vp1 + cdef dVector3* vp2 + + vp0 = v0 + vp1 = v1 + vp2 = v2 + + dGeomTriMeshGetTriangle(self.gid, idx, vp0, vp1, vp2) + return ((v0[0], v0[1], v0[2]), + (v1[0], v1[1], v1[2]), + (v2[0], v2[1], v2[2])) + + def getTriangleCount(self): + """getTriangleCount() -> n + + Returns the number of triangles in the TriMesh.""" + + return dGeomTriMeshGetTriangleCount(self.gid) + +###################################################################### + + +def collide(geom1, geom2): + """collide(geom1, geom2) -> contacts + + Generate contact information for two objects. + + Given two geometry objects that potentially touch (geom1 and geom2), + generate contact information for them. Internally, this just calls + the correct class-specific collision functions for geom1 and geom2. + + [flags specifies how contacts should be generated if the objects + touch. Currently the lower 16 bits of flags specifies the maximum + number of contact points to generate. If this number is zero, this + function just pretends that it is one - in other words you can not + ask for zero contacts. All other bits in flags must be zero. In + the future the other bits may be used to select other contact + generation strategies.] + + If the objects touch, this returns a list of Contact objects, + otherwise it returns an empty list. + + @param geom1: First Geom + @type geom1: GeomObject + @param geom2: Second Geom + @type geom2: GeomObject + @returns: Returns a list of Contact objects. + """ + + cdef dContactGeom c[150] + cdef size_t id1 + cdef size_t id2 + cdef int i, n + cdef Contact cont + + id1 = geom1._id() + id2 = geom2._id() + + n = dCollide(id1, id2, 150, c, sizeof(dContactGeom)) + res = [] + i = 0 + while i < n: + cont = Contact() + cont._contact.geom = c[i] + res.append(cont) + i = i + 1 + + return res + + +def collide2(geom1, geom2, arg, callback): + """collide2(geom1, geom2, arg, callback) + + Calls the callback for all potentially intersecting pairs that contain + one geom from geom1 and one geom from geom2. + + @param geom1: First Geom + @type geom1: GeomObject + @param geom2: Second Geom + @type geom2: GeomObject + @param arg: A user argument that is passed to the callback function + @param callback: Callback function + @type callback: callable + """ + cdef void* data + cdef object tup + cdef size_t id1 + cdef size_t id2 + + id1 = geom1._id() + id2 = geom2._id() + + tup = (callback, arg) + data = tup + # collide_callback is defined in space.pyx + dSpaceCollide2(id1, id2, data, collide_callback) + + +def areConnected(Body body1, Body body2): + """areConnected(body1, body2) -> bool + + Return True if the two bodies are connected together by a joint, + otherwise return False. + + @param body1: First body + @type body1: Body + @param body2: Second body + @type body2: Body + @returns: True if the bodies are connected + """ + + if body1 is environment: + return False + if body2 is environment: + return False + + return bool(dAreConnected( body1.bid, body2.bid)) + + +def CloseODE(): + """CloseODE() + + Deallocate some extra memory used by ODE that can not be deallocated + using the normal destroy functions. + """ + dCloseODE() + + +def InitODE(): + '''InitODE() + + Initialize some ODE internals. This will be called for you when you + "import ode", but you should call this again if you CloseODE().''' + dInitODE() + + +#environment = Body(None) +environment = None +InitODE() diff --git a/libs/ode-0.16.1/bindings/python/setup.py b/libs/ode-0.16.1/bindings/python/setup.py new file mode 100644 index 0000000..f0c5763 --- /dev/null +++ b/libs/ode-0.16.1/bindings/python/setup.py @@ -0,0 +1,48 @@ +#! /usr/bin/env python +from distutils.core import setup +from distutils.extension import Extension +from subprocess import Popen, PIPE, CalledProcessError + + +try: + from Cython.Distutils import build_ext +except ImportError: + raise SystemExit("Requires Cython (http://cython.org/)") + +try: + ode_cflags = Popen( + ["pkg-config", "--cflags", "ode"], + stdout=PIPE).stdout.read().decode('ascii').split() + ode_libs = Popen( + ["pkg-config", "--libs", "ode"], + stdout=PIPE).stdout.read().decode('ascii').split() +except (OSError, CalledProcessError): + raise SystemExit("Failed to find ODE with 'pkg-config'. Please make sure " + "that it is installed and available on your system path.") + +ode_ext = Extension("ode", ["ode.pyx"], + extra_compile_args=ode_cflags, + extra_link_args=ode_libs) + +if __name__ == "__main__": + setup( + name="Open Dynamics Engine", + version="0.12", + author="Gideon Klompje", +# author_email="", +# maintainer="", +# maintainer_email="", + url="http://www.ode.org", + description="Bindings for the Open Dynamics Engine", + long_description=( + "A free, industrial quality library for simulating articulated " + "rigid body dynamics - for example ground vehicles, legged " + "creatures, and moving objects in VR environments. It's fast, " + "flexible & robust. Built-in collision detection."), +# download_url="https://opende.svn.sourceforge.net/svnroot/opende", +# classifiers=[], +# platforms=[], + license="BSD License, GNU Lesser General Public License (LGPL)", + cmdclass={"build_ext": build_ext}, + ext_modules=[ode_ext] + ) diff --git a/libs/ode-0.16.1/bootstrap b/libs/ode-0.16.1/bootstrap new file mode 100755 index 0000000..24e91f0 --- /dev/null +++ b/libs/ode-0.16.1/bootstrap @@ -0,0 +1,28 @@ +#!/bin/sh + +echo "Please make sure that you use automake 1.11 or later" + echo "Warnings about underquoted definitions are harmless" +if [ `uname -s` = Darwin ]; then + echo "On OSX, install latest libtool, as the OS provided glibtoolize will not work" +fi + +echo "Running aclocal" +aclocal -I m4 --install || exit 1 +echo "Running libtoolize" +libtoolize --copy --automake --install || exit 1 +echo "Running autoheader" +autoheader || exit 1 +echo "Running automake" +automake --foreign --add-missing --copy || exit 1 +echo "Running autoconf" +autoconf || exit 1 + +echo "Running bootstrap in ou directory" +(cd ou && ./bootstrap) + +if [ -d libccd ]; then + echo "Running bootstrap in libccd directory" + (cd libccd && ./bootstrap) +fi; + +echo "Now you are ready to run ./configure" diff --git a/libs/ode-0.16.1/build/config-default.h b/libs/ode-0.16.1/build/config-default.h new file mode 100644 index 0000000..a51e309 --- /dev/null +++ b/libs/ode-0.16.1/build/config-default.h @@ -0,0 +1,113 @@ +/* This file was autogenerated by Premake */ +#ifndef _ODE_CONFIG_H_ +#define _ODE_CONFIG_H_ + + +/****************************************************************** + * CONFIGURATON SETTINGS - you can change these, and then rebuild + * ODE to modify the behavior of the library. + * + * dTRIMESH_ENABLED - enable/disable trimesh support + * dTRIMESH_OPCODE - use the OPCODE trimesh engine + * dTRIMESH_GIMPACT - use the GIMPACT trimesh engine + * Only one trimesh engine should be enabled. + * + * dTRIMESH_16BIT_INDICES (todo: opcode only) + * Setup the trimesh engine to use 16 bit + * triangle indices. The default is to use + * 32 bit indices. Use the dTriIndex type to + * detect the correct index size. + * + * dTRIMESH_OPCODE_USE_NEWOLD_TRIMESH_TRIMESH_COLLIDER + * Use old implementation of trimesh-trimesh collider + * (for backward compatibility only) + * + * dOU_ENABLED + * dATOMICS_ENABLED + * dTLS_ENABLED + * Use generic features of OU library, atomic API + * and TLS API respectively. + * Generic features and atomic API are always enabled, + * unless threading interface support is disabled. + * Using TLS for global variables allows calling ODE + * collision detection functions from multiple threads. + * + * dBUILTIN_THREADING_IMPL_ENABLED + * Include built-in multithreaded threading + * implementation (still must be created and assigned + * to be used). + * + ******************************************************************/ + +#define dTRIMESH_ENABLED 1 +#define dTRIMESH_OPCODE 1 +#define dTRIMESH_16BIT_INDICES 0 + +#define dTRIMESH_OPCODE_USE_OLD_TRIMESH_TRIMESH_COLLIDER 0 + +/* #define dOU_ENABLED 1 */ +/* #define dATOMICS_ENABLED 1 */ +/* #define dTLS_ENABLED 1 */ + +/* #define dTHREADING_INTF_DISABLED 1 */ +/* #define dBUILTIN_THREADING_IMPL_ENABLED 1 */ + + +/****************************************************************** + * SYSTEM SETTINGS - you shouldn't need to change these. If you + * run into an issue with these settings, please report it to + * the ODE bug tracker at: + * http://sf.net/tracker/?group_id=24884&atid=382799 + ******************************************************************/ + +/* Try to identify the platform */ +#if defined(_XENON) + #define ODE_PLATFORM_XBOX360 +#elif defined(SN_TARGET_PSP_HW) + #define ODE_PLATFORM_PSP +#elif defined(SN_TARGET_PS3) + #define ODE_PLATFORM_PS3 +#elif defined(_MSC_VER) || defined(__CYGWIN32__) || defined(__MINGW32__) + #define ODE_PLATFORM_WINDOWS +#elif defined(__linux__) + #define ODE_PLATFORM_LINUX +#elif defined(__APPLE__) && defined(__MACH__) + #define ODE_PLATFORM_OSX +#else + #error "Need some help identifying the platform!" +#endif + +/* Additional platform defines used in the code */ +#if defined(ODE_PLATFORM_WINDOWS) && !defined(WIN32) + #define WIN32 +#endif + +#if defined(__CYGWIN32__) || defined(__MINGW32__) + #define CYGWIN +#endif + +#if defined(ODE_PLATFORM_OSX) + #define macintosh +#endif + +#if !defined(ODE_PLATFORM_OSX) && !defined(ODE_PLATFORM_PS3) + #include +#endif + +#if !defined(ODE_PLATFORM_WINDOWS) + #include +#endif + + +/* Basic OU functionality is required if either atomic API or TLS support + * is enabled. */ +#if (dATOMICS_ENABLED || dTLS_ENABLED) && !dOU_ENABLED +#undef dOU_ENABLED +#define dOU_ENABLED 1 +#endif + + +#include "typedefs.h" + + +#endif diff --git a/libs/ode-0.16.1/build/premake4.exe b/libs/ode-0.16.1/build/premake4.exe new file mode 100644 index 0000000..b4230f1 Binary files /dev/null and b/libs/ode-0.16.1/build/premake4.exe differ diff --git a/libs/ode-0.16.1/build/premake4.lua b/libs/ode-0.16.1/build/premake4.lua new file mode 100644 index 0000000..b97f6ac --- /dev/null +++ b/libs/ode-0.16.1/build/premake4.lua @@ -0,0 +1,590 @@ +---------------------------------------------------------------------- +-- Premake4 configuration script for OpenDE +-- Contributed by Jason Perkins (starkos@industriousone.com) +-- For more information on Premake: http://industriousone.com/premake +---------------------------------------------------------------------- + + ode_version = "0.16.1" + +---------------------------------------------------------------------- +-- Demo list: add/remove demos from here and the rest of the build +-- should just work. +---------------------------------------------------------------------- + + local demos = { + "boxstack", + "buggy", + "cards", + "chain1", + "chain2", + "collision", + "convex", + "crash", + "cylvssphere", + "dball", + "dhinge", + "feedback", + "friction", + "gyroscopic", + "gyro2", + "heightfield", + "hinge", + "I", + "jointPR", + "jointPU", + "joints", + "kinematic", + "motion", + "motor", + "ode", + "piston", + "plane2d", + "rfriction", + "slider", + "space", + "space_stress", + "step", + "transmission" + } + + local trimesh_demos = { + "basket", + "cyl", + "moving_convex", + "moving_trimesh", + "tracks", + "trimesh" + } + + if not _OPTIONS["no-trimesh"] then + demos = table.join(demos, trimesh_demos) + end + + + +---------------------------------------------------------------------- +-- Configuration options +---------------------------------------------------------------------- + + newoption { + trigger = "with-demos", + description = "Builds the demo applications and DrawStuff library" + } + + newoption { + trigger = "with-tests", + description = "Builds the unit test application" + } + + newoption { + trigger = "with-gimpact", + description = "Use GIMPACT for trimesh collisions (experimental)" + } + + newoption { + trigger = "all-collis-libs", + description = "Include sources of all collision libraries into the project" + } + + newoption { + trigger = "with-libccd", + description = "Uses libccd for handling some collision tests absent in ODE." + } + + newoption { + trigger = "no-dif", + description = "Exclude DIF (Dynamics Interchange Format) exports" + } + + newoption { + trigger = "no-trimesh", + description = "Exclude trimesh collision geometry" + } + + newoption { + trigger = "with-ou", + description = "Use TLS for global caches (allows threaded collision checks for separated spaces)" + } + + newoption { + trigger = "no-builtin-threading-impl", + description = "Disable built-in multithreaded threading implementation" + } + + newoption { + trigger = "no-threading-intf", + description = "Disable threading interface support (external implementations cannot be assigned)" + } + + newoption { + trigger = "16bit-indices", + description = "Use 16-bit indices for trimeshes (default is 32-bit)" + } + + newoption { + trigger = "old-trimesh", + description = "Use old OPCODE trimesh-trimesh collider" + } + + newoption { + trigger = "to", + value = "path", + description = "Set the output location for the generated project files" + } + + newoption { + trigger = "only-shared", + description = "Only build shared (DLL) version of the library" + } + + newoption { + trigger = "only-static", + description = "Only build static versions of the library" + } + + newoption { + trigger = "only-single", + description = "Only use single-precision math" + } + + newoption { + trigger = "only-double", + description = "Only use double-precision math" + } + + -- always clean all of the optional components and toolsets + if _ACTION == "clean" then + _OPTIONS["with-demos"] = "" + _OPTIONS["with-tests"] = "" + for action in premake.action.each() do + os.rmdir(action.trigger) + end + os.remove("../ode/src/config.h") + os.remove("../include/ode/version.h") + os.remove("../include/ode/precision.h") + os.remove("../libccd/src/ccd/precision.h") + end + + -- special validation for Xcode + if _ACTION == "xcode3" and (not _OPTIONS["only-static"] and not _OPTIONS["only-shared"]) then + error( + "Xcode does not support different library types in a single project.\n" .. + "Please use one of the flags: --only-static or --only-shared", 0) + end + + -- build the list of configurations, based on the flags. Ends up + -- with configurations like "Debug", "DebugSingle" or "DebugSingleShared" + local configs = { "Debug", "Release" } + + local function addconfigs(...) + local newconfigs = { } + for _, root in ipairs(configs) do + for _, suffix in ipairs(arg) do + table.insert(newconfigs, root .. suffix) + end + end + configs = newconfigs + end + + + if not _OPTIONS["only-single"] and not _OPTIONS["only-double"] then + addconfigs("Single", "Double") + end + + if not _OPTIONS["only-shared"] and not _OPTIONS["only-static"] then + addconfigs("DLL", "Lib") + end + + +---------------------------------------------------------------------- +-- The solution, and solution-wide settings +---------------------------------------------------------------------- + + solution "ode" + + language "C++" + uuid "4DA77C12-15E5-497B-B1BB-5100D5161E15" + location ( _OPTIONS["to"] or _ACTION ) + + includedirs { + "../include", + "../ode/src" + } + + defines { "_MT" } + + -- apply the configuration list built above + configurations (configs) + + configuration { "Debug*" } + defines { "_DEBUG" } + flags { "Symbols" } + + configuration { "Release*" } + defines { "NDEBUG", "dNODEBUG" } + flags { "OptimizeSpeed", "NoFramePointer" } + + configuration { "*Single*" } + defines { "dIDESINGLE", "CCD_IDESINGLE" } + + configuration { "*Double*" } + defines { "dIDEDOUBLE", "CCD_IDEDOUBLE" } + + configuration { "Windows" } + defines { "WIN32" } + + configuration { "MacOSX" } + linkoptions { "-framework Carbon" } + + -- give each configuration a unique output directory + for _, name in ipairs(configurations()) do + configuration { name } + targetdir ( "../lib/" .. name ) + end + + -- disable Visual Studio security warnings + configuration { "vs*" } + defines { "_CRT_SECURE_NO_DEPRECATE", "_SCL_SECURE_NO_WARNINGS" } + + -- enable M_* macros from math.h + configuration { "vs*" } + defines { "_USE_MATH_DEFINES" } + + -- don't remember why we had to do this + configuration { "vs2002 or vs2003", "*Lib" } + flags { "StaticRuntime" } + + + +---------------------------------------------------------------------- +-- The demo projects, automated from list above. These go first so +-- they will be selected as the active project automatically in IDEs +---------------------------------------------------------------------- + + if _OPTIONS["with-demos"] then + for _, name in ipairs(demos) do + + project ( "demo_" .. name ) + + kind "ConsoleApp" + location ( _OPTIONS["to"] or _ACTION ) + files { "../ode/demo/demo_" .. name .. ".*" } + links { "ode", "drawstuff" } + + configuration { "Windows" } + files { "../drawstuff/src/resources.rc" } + links { "user32", "winmm", "gdi32", "opengl32", "glu32" } + + configuration { "MacOSX" } + linkoptions { "-framework Carbon -framework OpenGL -framework AGL" } + + configuration { "not Windows", "not MacOSX" } + links { "GL", "GLU" } + + end + end + + + +---------------------------------------------------------------------- +-- The ODE library project +---------------------------------------------------------------------- + + project "ode" + + -- kind "StaticLib" + location ( _OPTIONS["to"] or _ACTION ) + + includedirs { + "../ode/src/joints", + "../OPCODE", + "../GIMPACT/include", + "../libccd/src/custom", + "../libccd/src" + } + + files { + "../include/ode/*.h", + "../ode/src/joints/*.h", + "../ode/src/joints/*.cpp", + "../ode/src/*.h", + "../ode/src/*.c", + "../ode/src/*.cpp", + } + + excludes { + "../ode/src/collision_std.cpp", + } + + includedirs { "../ou/include" } + files { "../ou/include/**.h", "../ou/src/**.h", "../ou/src/**.cpp" } + defines { "_OU_NAMESPACE=odeou" } + + if _OPTIONS["with-ou"] then + defines { "_OU_FEATURE_SET=_OU_FEATURE_SET_TLS" } + elseif not _OPTIONS["no-threading-intf"] then + defines { "_OU_FEATURE_SET=_OU_FEATURE_SET_ATOMICS" } + else + defines { "_OU_FEATURE_SET=_OU_FEATURE_SET_BASICS" } + end + + if _OPTIONS["with-ou"] or not _OPTIONS["no-threading-intf"] then + if _ACTION == "gmake" then + if os.get() == "windows" then + buildoptions { "-mthreads" } + linkoptions { "-mthreads" } + defines { "HAVE_PTHREAD_ATTR_SETINHERITSCHED=1", "HAVE_PTHREAD_ATTR_SETSTACKLAZY=1" } + else + buildoptions { "-pthread" } + linkoptions { "-pthread" } + end + end + end + + + configuration { "no-dif" } + excludes { "../ode/src/export-dif.cpp" } + + configuration { "no-trimesh" } + excludes { + "../ode/src/collision_trimesh_colliders.h", + "../ode/src/gimpact_contact_export_helper.cpp", + "../ode/src/gimpact_contact_export_helper.h", + "../ode/src/gimpact_gim_contact_accessor.h", + "../ode/src/gimpact_plane_contact_accessor.h", + "../ode/src/collision_trimesh_internal.cpp", + "../ode/src/collision_trimesh_opcode.cpp", + "../ode/src/collision_trimesh_gimpact.cpp", + "../ode/src/collision_trimesh_box.cpp", + "../ode/src/collision_trimesh_ccylinder.cpp", + "../ode/src/collision_cylinder_trimesh.cpp", + "../ode/src/collision_trimesh_ray.cpp", + "../ode/src/collision_trimesh_sphere.cpp", + "../ode/src/collision_trimesh_trimesh.cpp", + "../ode/src/collision_trimesh_trimesh_old.cpp", + "../ode/src/collision_trimesh_plane.cpp", + "../ode/src/collision_convex_trimesh.cpp" + } + + configuration { "not no-trimesh", "with-gimpact or all-collis-libs" } + files { "../GIMPACT/**.h", "../GIMPACT/**.cpp" } + + configuration { "not no-trimesh", "not with-gimpact" } + files { "../OPCODE/**.h", "../OPCODE/**.cpp" } + + configuration { "not no-trimesh", "not all-collis-libs", "with-gimpact" } + excludes { + "../ode/src/collision_trimesh_opcode.cpp" + } + + configuration { "not no-trimesh", "not all-collis-libs", "not with-gimpact" } + excludes { + "../ode/src/gimpact_contact_export_helper.cpp", + "../ode/src/gimpact_contact_export_helper.h", + "../ode/src/gimpact_gim_contact_accessor.h", + "../ode/src/gimpact_plane_contact_accessor.h", + "../ode/src/collision_trimesh_gimpact.cpp" + } + + configuration { "with-libccd" } + files { "../libccd/src/custom/ccdcustom/*.h", "../libccd/src/ccd/*.h", "../libccd/src/*.c" } + defines { "dLIBCCD_ENABLED", "dLIBCCD_INTERNAL", + "dLIBCCD_BOX_CYL", "dLIBCCD_CYL_CYL", "dLIBCCD_CAP_CYL", "dLIBCCD_CONVEX_BOX", + "dLIBCCD_CONVEX_CAP", "dLIBCCD_CONVEX_CYL", "dLIBCCD_CONVEX_SPHERE", "dLIBCCD_CONVEX_CONVEX" } + + configuration { "not with-libccd" } + excludes { "../ode/src/collision_libccd.cpp", "../ode/src/collision_libccd.h" } + + configuration { "windows" } + links { "user32" } + + configuration { "only-static or *Lib" } + kind "StaticLib" + defines "ODE_LIB" + + configuration { "only-shared or *DLL" } + kind "SharedLib" + defines "ODE_DLL" + + configuration { "*DLL" } + defines "_DLL" + + configuration { "Debug" } + targetname "oded" + + configuration { "Release" } + targetname "ode" + + configuration { "DebugSingle*" } + targetname "ode_singled" + + configuration { "ReleaseSingle*" } + targetname "ode_single" + + configuration { "DebugDouble*" } + targetname "ode_doubled" + + configuration { "ReleaseDouble*" } + targetname "ode_double" + + +---------------------------------------------------------------------- +-- Write a custom to build, based on the supplied flags +---------------------------------------------------------------------- + + if _ACTION and _ACTION ~= "clean" then + local infile = io.open("config-default.h", "r") + local text = infile:read("*a") + + if _OPTIONS["no-trimesh"] then + text = string.gsub(text, "#define dTRIMESH_ENABLED 1", "/* #define dTRIMESH_ENABLED 1 */") + text = string.gsub(text, "#define dTRIMESH_OPCODE 1", "/* #define dTRIMESH_OPCODE 1 */") + elseif (_OPTIONS["with-gimpact"]) then + text = string.gsub(text, "#define dTRIMESH_OPCODE 1", "#define dTRIMESH_GIMPACT 1") + end + + text = string.gsub(text, "/%* #define dOU_ENABLED 1 %*/", "#define dOU_ENABLED 1") + if _OPTIONS["with-ou"] or not _OPTIONS["no-threading-intf"] then + text = string.gsub(text, "/%* #define dATOMICS_ENABLED 1 %*/", "#define dATOMICS_ENABLED 1") + end + + if _OPTIONS["with-ou"] then + text = string.gsub(text, "/%* #define dTLS_ENABLED 1 %*/", "#define dTLS_ENABLED 1") + end + + if _OPTIONS["no-threading-intf"] then + text = string.gsub(text, "/%* #define dTHREADING_INTF_DISABLED 1 %*/", "#define dTHREADING_INTF_DISABLED 1") + elseif not _OPTIONS["no-builtin-threading-impl"] then + text = string.gsub(text, "/%* #define dBUILTIN_THREADING_IMPL_ENABLED 1 %*/", "#define dBUILTIN_THREADING_IMPL_ENABLED 1") + end + + if _OPTIONS["16bit-indices"] then + text = string.gsub(text, "#define dTRIMESH_16BIT_INDICES 0", "#define dTRIMESH_16BIT_INDICES 1") + end + + if _OPTIONS["old-trimesh"] then + text = string.gsub(text, "#define dTRIMESH_OPCODE_USE_OLD_TRIMESH_TRIMESH_COLLIDER 0", "#define dTRIMESH_OPCODE_USE_OLD_TRIMESH_TRIMESH_COLLIDER 1") + end + + local outfile = io.open("../ode/src/config.h", "w") + outfile:write(text) + outfile:close() + end + +---------------------------- +-- Write precision headers +---------------------------- + if _ACTION and _ACTION ~= "clean" then + function generateheader(headerfile, placeholder, precstr) + local outfile = io.open(headerfile, "w") + for i in io.lines(headerfile .. ".in") + do + local j,_ = string.gsub(i, placeholder, precstr) + --print("writing " .. j .. " into " .. headerfile) + outfile:write(j .. "\n") + end + outfile:close() + end + + function generate(precstr) + generateheader("../include/ode/precision.h", "@ODE_PRECISION@", "d" .. precstr) + generateheader("../libccd/src/ccd/precision.h", "@CCD_PRECISION@", "CCD_" .. precstr) + end + + if _OPTIONS["only-single"] then + generate("SINGLE") + elseif _OPTIONS["only-double"] then + generate("DOUBLE") + else + generate("UNDEFINEDPRECISION") + end + + generateheader("../include/ode/version.h", "@ODE_VERSION@", ode_version) + + end + + +---------------------------------------------------------------------- +-- The DrawStuff library project +---------------------------------------------------------------------- + + if _OPTIONS["with-demos"] then + + project "drawstuff" + + location ( _OPTIONS["to"] or _ACTION ) + + files { + "../include/drawstuff/*.h", + "../drawstuff/src/internal.h", + "../drawstuff/src/drawstuff.cpp" + } + + configuration { "Debug*" } + targetname "drawstuffd" + + configuration { "only-static or *Lib" } + kind "StaticLib" + defines { "DS_LIB" } + + configuration { "only-shared or *DLL" } + kind "SharedLib" + defines { "DS_DLL", "USRDLL" } + + configuration { "Windows" } + files { "../drawstuff/src/resource.h", "../drawstuff/src/resources.rc", "../drawstuff/src/windows.cpp" } + links { "user32", "opengl32", "glu32", "winmm", "gdi32" } + + configuration { "MacOSX" } + defines { "HAVE_APPLE_OPENGL_FRAMEWORK" } + files { "../drawstuff/src/osx.cpp" } + linkoptions { "-framework Carbon -framework OpenGL -framework AGL" } + + configuration { "not Windows", "not MacOSX" } + files { "../drawstuff/src/x11.cpp" } + links { "X11", "GL", "GLU" } + + end + + +---------------------------------------------------------------------- +-- The automated test application +---------------------------------------------------------------------- + + + if _OPTIONS["with-tests"] then + + project "tests" + + kind "ConsoleApp" + location ( _OPTIONS["to"] or _ACTION ) + + includedirs { + "../tests/UnitTest++/src" + } + + files { + "../tests/*.cpp", + "../tests/joints/*.cpp", + "../tests/UnitTest++/src/*" + } + + links { "ode" } + + configuration { "Windows" } + files { "../tests/UnitTest++/src/Win32/*" } + + configuration { "not Windows" } + files { "../tests/UnitTest++/src/Posix/*" } + + -- add post-build step to automatically run test executable + local path_to_lib = path.getrelative(location(), "../lib") + local command = path.translate(path.join(path_to_lib, "%s/tests")) + + for _, name in ipairs(configurations()) do + configuration { name } + postbuildcommands { command:format(name) } + end + + end + diff --git a/libs/ode-0.16.1/cmake/cmake_uninstall.cmake.in b/libs/ode-0.16.1/cmake/cmake_uninstall.cmake.in new file mode 100644 index 0000000..6aff17a --- /dev/null +++ b/libs/ode-0.16.1/cmake/cmake_uninstall.cmake.in @@ -0,0 +1,17 @@ +if(NOT EXISTS "@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt") + message(FATAL_ERROR "Cannot find install manifest: \"@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt\"") +endif() + +file(READ "@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt" FILES) +string(REGEX REPLACE "\n" ";" FILES "${FILES}") + +foreach(FILE ${FILES}) + message(STATUS "Uninstalling: ${FILE}") + if(EXISTS "${FILE}") + file(REMOVE ${FILE}) + elseif(IS_SYMLINK "${FILE}") + file(REMOVE ${FILE}) + else() + message(STATUS "File \"${FILE}\" does not exist.") + endif() +endforeach() diff --git a/libs/ode-0.16.1/compile b/libs/ode-0.16.1/compile new file mode 100755 index 0000000..a85b723 --- /dev/null +++ b/libs/ode-0.16.1/compile @@ -0,0 +1,347 @@ +#! /bin/sh +# Wrapper for compilers which do not understand '-c -o'. + +scriptversion=2012-10-14.11; # UTC + +# Copyright (C) 1999-2014 Free Software Foundation, Inc. +# Written by Tom Tromey . +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. + +# This file is maintained in Automake, please report +# bugs to or send patches to +# . + +nl=' +' + +# We need space, tab and new line, in precisely that order. Quoting is +# there to prevent tools from complaining about whitespace usage. +IFS=" "" $nl" + +file_conv= + +# func_file_conv build_file lazy +# Convert a $build file to $host form and store it in $file +# Currently only supports Windows hosts. If the determined conversion +# type is listed in (the comma separated) LAZY, no conversion will +# take place. +func_file_conv () +{ + file=$1 + case $file in + / | /[!/]*) # absolute file, and not a UNC file + if test -z "$file_conv"; then + # lazily determine how to convert abs files + case `uname -s` in + MINGW*) + file_conv=mingw + ;; + CYGWIN*) + file_conv=cygwin + ;; + *) + file_conv=wine + ;; + esac + fi + case $file_conv/,$2, in + *,$file_conv,*) + ;; + mingw/*) + file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'` + ;; + cygwin/*) + file=`cygpath -m "$file" || echo "$file"` + ;; + wine/*) + file=`winepath -w "$file" || echo "$file"` + ;; + esac + ;; + esac +} + +# func_cl_dashL linkdir +# Make cl look for libraries in LINKDIR +func_cl_dashL () +{ + func_file_conv "$1" + if test -z "$lib_path"; then + lib_path=$file + else + lib_path="$lib_path;$file" + fi + linker_opts="$linker_opts -LIBPATH:$file" +} + +# func_cl_dashl library +# Do a library search-path lookup for cl +func_cl_dashl () +{ + lib=$1 + found=no + save_IFS=$IFS + IFS=';' + for dir in $lib_path $LIB + do + IFS=$save_IFS + if $shared && test -f "$dir/$lib.dll.lib"; then + found=yes + lib=$dir/$lib.dll.lib + break + fi + if test -f "$dir/$lib.lib"; then + found=yes + lib=$dir/$lib.lib + break + fi + if test -f "$dir/lib$lib.a"; then + found=yes + lib=$dir/lib$lib.a + break + fi + done + IFS=$save_IFS + + if test "$found" != yes; then + lib=$lib.lib + fi +} + +# func_cl_wrapper cl arg... +# Adjust compile command to suit cl +func_cl_wrapper () +{ + # Assume a capable shell + lib_path= + shared=: + linker_opts= + for arg + do + if test -n "$eat"; then + eat= + else + case $1 in + -o) + # configure might choose to run compile as 'compile cc -o foo foo.c'. + eat=1 + case $2 in + *.o | *.[oO][bB][jJ]) + func_file_conv "$2" + set x "$@" -Fo"$file" + shift + ;; + *) + func_file_conv "$2" + set x "$@" -Fe"$file" + shift + ;; + esac + ;; + -I) + eat=1 + func_file_conv "$2" mingw + set x "$@" -I"$file" + shift + ;; + -I*) + func_file_conv "${1#-I}" mingw + set x "$@" -I"$file" + shift + ;; + -l) + eat=1 + func_cl_dashl "$2" + set x "$@" "$lib" + shift + ;; + -l*) + func_cl_dashl "${1#-l}" + set x "$@" "$lib" + shift + ;; + -L) + eat=1 + func_cl_dashL "$2" + ;; + -L*) + func_cl_dashL "${1#-L}" + ;; + -static) + shared=false + ;; + -Wl,*) + arg=${1#-Wl,} + save_ifs="$IFS"; IFS=',' + for flag in $arg; do + IFS="$save_ifs" + linker_opts="$linker_opts $flag" + done + IFS="$save_ifs" + ;; + -Xlinker) + eat=1 + linker_opts="$linker_opts $2" + ;; + -*) + set x "$@" "$1" + shift + ;; + *.cc | *.CC | *.cxx | *.CXX | *.[cC]++) + func_file_conv "$1" + set x "$@" -Tp"$file" + shift + ;; + *.c | *.cpp | *.CPP | *.lib | *.LIB | *.Lib | *.OBJ | *.obj | *.[oO]) + func_file_conv "$1" mingw + set x "$@" "$file" + shift + ;; + *) + set x "$@" "$1" + shift + ;; + esac + fi + shift + done + if test -n "$linker_opts"; then + linker_opts="-link$linker_opts" + fi + exec "$@" $linker_opts + exit 1 +} + +eat= + +case $1 in + '') + echo "$0: No command. Try '$0 --help' for more information." 1>&2 + exit 1; + ;; + -h | --h*) + cat <<\EOF +Usage: compile [--help] [--version] PROGRAM [ARGS] + +Wrapper for compilers which do not understand '-c -o'. +Remove '-o dest.o' from ARGS, run PROGRAM with the remaining +arguments, and rename the output as expected. + +If you are trying to build a whole package this is not the +right script to run: please start by reading the file 'INSTALL'. + +Report bugs to . +EOF + exit $? + ;; + -v | --v*) + echo "compile $scriptversion" + exit $? + ;; + cl | *[/\\]cl | cl.exe | *[/\\]cl.exe ) + func_cl_wrapper "$@" # Doesn't return... + ;; +esac + +ofile= +cfile= + +for arg +do + if test -n "$eat"; then + eat= + else + case $1 in + -o) + # configure might choose to run compile as 'compile cc -o foo foo.c'. + # So we strip '-o arg' only if arg is an object. + eat=1 + case $2 in + *.o | *.obj) + ofile=$2 + ;; + *) + set x "$@" -o "$2" + shift + ;; + esac + ;; + *.c) + cfile=$1 + set x "$@" "$1" + shift + ;; + *) + set x "$@" "$1" + shift + ;; + esac + fi + shift +done + +if test -z "$ofile" || test -z "$cfile"; then + # If no '-o' option was seen then we might have been invoked from a + # pattern rule where we don't need one. That is ok -- this is a + # normal compilation that the losing compiler can handle. If no + # '.c' file was seen then we are probably linking. That is also + # ok. + exec "$@" +fi + +# Name of file we expect compiler to create. +cofile=`echo "$cfile" | sed 's|^.*[\\/]||; s|^[a-zA-Z]:||; s/\.c$/.o/'` + +# Create the lock directory. +# Note: use '[/\\:.-]' here to ensure that we don't use the same name +# that we are using for the .o file. Also, base the name on the expected +# object file name, since that is what matters with a parallel build. +lockdir=`echo "$cofile" | sed -e 's|[/\\:.-]|_|g'`.d +while true; do + if mkdir "$lockdir" >/dev/null 2>&1; then + break + fi + sleep 1 +done +# FIXME: race condition here if user kills between mkdir and trap. +trap "rmdir '$lockdir'; exit 1" 1 2 15 + +# Run the compile. +"$@" +ret=$? + +if test -f "$cofile"; then + test "$cofile" = "$ofile" || mv "$cofile" "$ofile" +elif test -f "${cofile}bj"; then + test "${cofile}bj" = "$ofile" || mv "${cofile}bj" "$ofile" +fi + +rmdir "$lockdir" +exit $ret + +# Local Variables: +# mode: shell-script +# sh-indentation: 2 +# eval: (add-hook 'write-file-hooks 'time-stamp) +# time-stamp-start: "scriptversion=" +# time-stamp-format: "%:y-%02m-%02d.%02H" +# time-stamp-time-zone: "UTC" +# time-stamp-end: "; # UTC" +# End: diff --git a/libs/ode-0.16.1/config.guess b/libs/ode-0.16.1/config.guess new file mode 100755 index 0000000..1659250 --- /dev/null +++ b/libs/ode-0.16.1/config.guess @@ -0,0 +1,1441 @@ +#! /bin/sh +# Attempt to guess a canonical system name. +# Copyright 1992-2015 Free Software Foundation, Inc. + +timestamp='2015-08-20' + +# This file is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 3 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, see . +# +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that +# program. This Exception is an additional permission under section 7 +# of the GNU General Public License, version 3 ("GPLv3"). +# +# Originally written by Per Bothner; maintained since 2000 by Ben Elliston. +# +# You can get the latest version of this script from: +# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD +# +# Please send patches to . + + +me=`echo "$0" | sed -e 's,.*/,,'` + +usage="\ +Usage: $0 [OPTION] + +Output the configuration name of the system \`$me' is run on. + +Operation modes: + -h, --help print this help, then exit + -t, --time-stamp print date of last modification, then exit + -v, --version print version number, then exit + +Report bugs and patches to ." + +version="\ +GNU config.guess ($timestamp) + +Originally written by Per Bothner. +Copyright 1992-2015 Free Software Foundation, Inc. + +This is free software; see the source for copying conditions. There is NO +warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." + +help=" +Try \`$me --help' for more information." + +# Parse command line +while test $# -gt 0 ; do + case $1 in + --time-stamp | --time* | -t ) + echo "$timestamp" ; exit ;; + --version | -v ) + echo "$version" ; exit ;; + --help | --h* | -h ) + echo "$usage"; exit ;; + -- ) # Stop option processing + shift; break ;; + - ) # Use stdin as input. + break ;; + -* ) + echo "$me: invalid option $1$help" >&2 + exit 1 ;; + * ) + break ;; + esac +done + +if test $# != 0; then + echo "$me: too many arguments$help" >&2 + exit 1 +fi + +trap 'exit 1' 1 2 15 + +# CC_FOR_BUILD -- compiler used by this script. Note that the use of a +# compiler to aid in system detection is discouraged as it requires +# temporary files to be created and, as you can see below, it is a +# headache to deal with in a portable fashion. + +# Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still +# use `HOST_CC' if defined, but it is deprecated. + +# Portable tmp directory creation inspired by the Autoconf team. + +set_cc_for_build=' +trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ; +trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ; +: ${TMPDIR=/tmp} ; + { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || + { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } || + { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } || + { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; +dummy=$tmp/dummy ; +tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ; +case $CC_FOR_BUILD,$HOST_CC,$CC in + ,,) echo "int x;" > $dummy.c ; + for c in cc gcc c89 c99 ; do + if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then + CC_FOR_BUILD="$c"; break ; + fi ; + done ; + if test x"$CC_FOR_BUILD" = x ; then + CC_FOR_BUILD=no_compiler_found ; + fi + ;; + ,,*) CC_FOR_BUILD=$CC ;; + ,*,*) CC_FOR_BUILD=$HOST_CC ;; +esac ; set_cc_for_build= ;' + +# This is needed to find uname on a Pyramid OSx when run in the BSD universe. +# (ghazi@noc.rutgers.edu 1994-08-24) +if (test -f /.attbin/uname) >/dev/null 2>&1 ; then + PATH=$PATH:/.attbin ; export PATH +fi + +UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown +UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown +UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown +UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown + +case "${UNAME_SYSTEM}" in +Linux|GNU|GNU/*) + # If the system lacks a compiler, then just pick glibc. + # We could probably try harder. + LIBC=gnu + + eval $set_cc_for_build + cat <<-EOF > $dummy.c + #include + #if defined(__UCLIBC__) + LIBC=uclibc + #elif defined(__dietlibc__) + LIBC=dietlibc + #else + LIBC=gnu + #endif + EOF + eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC' | sed 's, ,,g'` + ;; +esac + +# Note: order is significant - the case branches are not exclusive. + +case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in + *:NetBSD:*:*) + # NetBSD (nbsd) targets should (where applicable) match one or + # more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*, + # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently + # switched to ELF, *-*-netbsd* would select the old + # object file format. This provides both forward + # compatibility and a consistent mechanism for selecting the + # object file format. + # + # Note: NetBSD doesn't particularly care about the vendor + # portion of the name. We always set it to "unknown". + sysctl="sysctl -n hw.machine_arch" + UNAME_MACHINE_ARCH=`(uname -p 2>/dev/null || \ + /sbin/$sysctl 2>/dev/null || \ + /usr/sbin/$sysctl 2>/dev/null || \ + echo unknown)` + case "${UNAME_MACHINE_ARCH}" in + armeb) machine=armeb-unknown ;; + arm*) machine=arm-unknown ;; + sh3el) machine=shl-unknown ;; + sh3eb) machine=sh-unknown ;; + sh5el) machine=sh5le-unknown ;; + earmv*) + arch=`echo ${UNAME_MACHINE_ARCH} | sed -e 's,^e\(armv[0-9]\).*$,\1,'` + endian=`echo ${UNAME_MACHINE_ARCH} | sed -ne 's,^.*\(eb\)$,\1,p'` + machine=${arch}${endian}-unknown + ;; + *) machine=${UNAME_MACHINE_ARCH}-unknown ;; + esac + # The Operating System including object format, if it has switched + # to ELF recently, or will in the future. + case "${UNAME_MACHINE_ARCH}" in + arm*|earm*|i386|m68k|ns32k|sh3*|sparc|vax) + eval $set_cc_for_build + if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ + | grep -q __ELF__ + then + # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout). + # Return netbsd for either. FIX? + os=netbsd + else + os=netbsdelf + fi + ;; + *) + os=netbsd + ;; + esac + # Determine ABI tags. + case "${UNAME_MACHINE_ARCH}" in + earm*) + expr='s/^earmv[0-9]/-eabi/;s/eb$//' + abi=`echo ${UNAME_MACHINE_ARCH} | sed -e "$expr"` + ;; + esac + # The OS release + # Debian GNU/NetBSD machines have a different userland, and + # thus, need a distinct triplet. However, they do not need + # kernel version information, so it can be replaced with a + # suitable tag, in the style of linux-gnu. + case "${UNAME_VERSION}" in + Debian*) + release='-gnu' + ;; + *) + release=`echo ${UNAME_RELEASE} | sed -e 's/[-_].*//' | cut -d. -f1,2` + ;; + esac + # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: + # contains redundant information, the shorter form: + # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. + echo "${machine}-${os}${release}${abi}" + exit ;; + *:Bitrig:*:*) + UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'` + echo ${UNAME_MACHINE_ARCH}-unknown-bitrig${UNAME_RELEASE} + exit ;; + *:OpenBSD:*:*) + UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` + echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE} + exit ;; + *:ekkoBSD:*:*) + echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} + exit ;; + *:SolidBSD:*:*) + echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE} + exit ;; + macppc:MirBSD:*:*) + echo powerpc-unknown-mirbsd${UNAME_RELEASE} + exit ;; + *:MirBSD:*:*) + echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} + exit ;; + *:Sortix:*:*) + echo ${UNAME_MACHINE}-unknown-sortix + exit ;; + alpha:OSF1:*:*) + case $UNAME_RELEASE in + *4.0) + UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` + ;; + *5.*) + UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` + ;; + esac + # According to Compaq, /usr/sbin/psrinfo has been available on + # OSF/1 and Tru64 systems produced since 1995. I hope that + # covers most systems running today. This code pipes the CPU + # types through head -n 1, so we only detect the type of CPU 0. + ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1` + case "$ALPHA_CPU_TYPE" in + "EV4 (21064)") + UNAME_MACHINE="alpha" ;; + "EV4.5 (21064)") + UNAME_MACHINE="alpha" ;; + "LCA4 (21066/21068)") + UNAME_MACHINE="alpha" ;; + "EV5 (21164)") + UNAME_MACHINE="alphaev5" ;; + "EV5.6 (21164A)") + UNAME_MACHINE="alphaev56" ;; + "EV5.6 (21164PC)") + UNAME_MACHINE="alphapca56" ;; + "EV5.7 (21164PC)") + UNAME_MACHINE="alphapca57" ;; + "EV6 (21264)") + UNAME_MACHINE="alphaev6" ;; + "EV6.7 (21264A)") + UNAME_MACHINE="alphaev67" ;; + "EV6.8CB (21264C)") + UNAME_MACHINE="alphaev68" ;; + "EV6.8AL (21264B)") + UNAME_MACHINE="alphaev68" ;; + "EV6.8CX (21264D)") + UNAME_MACHINE="alphaev68" ;; + "EV6.9A (21264/EV69A)") + UNAME_MACHINE="alphaev69" ;; + "EV7 (21364)") + UNAME_MACHINE="alphaev7" ;; + "EV7.9 (21364A)") + UNAME_MACHINE="alphaev79" ;; + esac + # A Pn.n version is a patched version. + # A Vn.n version is a released version. + # A Tn.n version is a released field test version. + # A Xn.n version is an unreleased experimental baselevel. + # 1.2 uses "1.2" for uname -r. + echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` + # Reset EXIT trap before exiting to avoid spurious non-zero exit code. + exitcode=$? + trap '' 0 + exit $exitcode ;; + Alpha\ *:Windows_NT*:*) + # How do we know it's Interix rather than the generic POSIX subsystem? + # Should we change UNAME_MACHINE based on the output of uname instead + # of the specific Alpha model? + echo alpha-pc-interix + exit ;; + 21064:Windows_NT:50:3) + echo alpha-dec-winnt3.5 + exit ;; + Amiga*:UNIX_System_V:4.0:*) + echo m68k-unknown-sysv4 + exit ;; + *:[Aa]miga[Oo][Ss]:*:*) + echo ${UNAME_MACHINE}-unknown-amigaos + exit ;; + *:[Mm]orph[Oo][Ss]:*:*) + echo ${UNAME_MACHINE}-unknown-morphos + exit ;; + *:OS/390:*:*) + echo i370-ibm-openedition + exit ;; + *:z/VM:*:*) + echo s390-ibm-zvmoe + exit ;; + *:OS400:*:*) + echo powerpc-ibm-os400 + exit ;; + arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) + echo arm-acorn-riscix${UNAME_RELEASE} + exit ;; + arm*:riscos:*:*|arm*:RISCOS:*:*) + echo arm-unknown-riscos + exit ;; + SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) + echo hppa1.1-hitachi-hiuxmpp + exit ;; + Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*) + # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. + if test "`(/bin/universe) 2>/dev/null`" = att ; then + echo pyramid-pyramid-sysv3 + else + echo pyramid-pyramid-bsd + fi + exit ;; + NILE*:*:*:dcosx) + echo pyramid-pyramid-svr4 + exit ;; + DRS?6000:unix:4.0:6*) + echo sparc-icl-nx6 + exit ;; + DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*) + case `/usr/bin/uname -p` in + sparc) echo sparc-icl-nx7; exit ;; + esac ;; + s390x:SunOS:*:*) + echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit ;; + sun4H:SunOS:5.*:*) + echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit ;; + sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) + echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit ;; + i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*) + echo i386-pc-auroraux${UNAME_RELEASE} + exit ;; + i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) + eval $set_cc_for_build + SUN_ARCH="i386" + # If there is a compiler, see if it is configured for 64-bit objects. + # Note that the Sun cc does not turn __LP64__ into 1 like gcc does. + # This test works for both compilers. + if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then + if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \ + (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ + grep IS_64BIT_ARCH >/dev/null + then + SUN_ARCH="x86_64" + fi + fi + echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit ;; + sun4*:SunOS:6*:*) + # According to config.sub, this is the proper way to canonicalize + # SunOS6. Hard to guess exactly what SunOS6 will be like, but + # it's likely to be more like Solaris than SunOS4. + echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit ;; + sun4*:SunOS:*:*) + case "`/usr/bin/arch -k`" in + Series*|S4*) + UNAME_RELEASE=`uname -v` + ;; + esac + # Japanese Language versions have a version number like `4.1.3-JL'. + echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'` + exit ;; + sun3*:SunOS:*:*) + echo m68k-sun-sunos${UNAME_RELEASE} + exit ;; + sun*:*:4.2BSD:*) + UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` + test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3 + case "`/bin/arch`" in + sun3) + echo m68k-sun-sunos${UNAME_RELEASE} + ;; + sun4) + echo sparc-sun-sunos${UNAME_RELEASE} + ;; + esac + exit ;; + aushp:SunOS:*:*) + echo sparc-auspex-sunos${UNAME_RELEASE} + exit ;; + # The situation for MiNT is a little confusing. The machine name + # can be virtually everything (everything which is not + # "atarist" or "atariste" at least should have a processor + # > m68000). The system name ranges from "MiNT" over "FreeMiNT" + # to the lowercase version "mint" (or "freemint"). Finally + # the system name "TOS" denotes a system which is actually not + # MiNT. But MiNT is downward compatible to TOS, so this should + # be no problem. + atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) + echo m68k-atari-mint${UNAME_RELEASE} + exit ;; + atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) + echo m68k-atari-mint${UNAME_RELEASE} + exit ;; + *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) + echo m68k-atari-mint${UNAME_RELEASE} + exit ;; + milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) + echo m68k-milan-mint${UNAME_RELEASE} + exit ;; + hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) + echo m68k-hades-mint${UNAME_RELEASE} + exit ;; + *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) + echo m68k-unknown-mint${UNAME_RELEASE} + exit ;; + m68k:machten:*:*) + echo m68k-apple-machten${UNAME_RELEASE} + exit ;; + powerpc:machten:*:*) + echo powerpc-apple-machten${UNAME_RELEASE} + exit ;; + RISC*:Mach:*:*) + echo mips-dec-mach_bsd4.3 + exit ;; + RISC*:ULTRIX:*:*) + echo mips-dec-ultrix${UNAME_RELEASE} + exit ;; + VAX*:ULTRIX*:*:*) + echo vax-dec-ultrix${UNAME_RELEASE} + exit ;; + 2020:CLIX:*:* | 2430:CLIX:*:*) + echo clipper-intergraph-clix${UNAME_RELEASE} + exit ;; + mips:*:*:UMIPS | mips:*:*:RISCos) + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c +#ifdef __cplusplus +#include /* for printf() prototype */ + int main (int argc, char *argv[]) { +#else + int main (argc, argv) int argc; char *argv[]; { +#endif + #if defined (host_mips) && defined (MIPSEB) + #if defined (SYSTYPE_SYSV) + printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0); + #endif + #if defined (SYSTYPE_SVR4) + printf ("mips-mips-riscos%ssvr4\n", argv[1]); exit (0); + #endif + #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD) + printf ("mips-mips-riscos%sbsd\n", argv[1]); exit (0); + #endif + #endif + exit (-1); + } +EOF + $CC_FOR_BUILD -o $dummy $dummy.c && + dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` && + SYSTEM_NAME=`$dummy $dummyarg` && + { echo "$SYSTEM_NAME"; exit; } + echo mips-mips-riscos${UNAME_RELEASE} + exit ;; + Motorola:PowerMAX_OS:*:*) + echo powerpc-motorola-powermax + exit ;; + Motorola:*:4.3:PL8-*) + echo powerpc-harris-powermax + exit ;; + Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*) + echo powerpc-harris-powermax + exit ;; + Night_Hawk:Power_UNIX:*:*) + echo powerpc-harris-powerunix + exit ;; + m88k:CX/UX:7*:*) + echo m88k-harris-cxux7 + exit ;; + m88k:*:4*:R4*) + echo m88k-motorola-sysv4 + exit ;; + m88k:*:3*:R3*) + echo m88k-motorola-sysv3 + exit ;; + AViiON:dgux:*:*) + # DG/UX returns AViiON for all architectures + UNAME_PROCESSOR=`/usr/bin/uname -p` + if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ] + then + if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \ + [ ${TARGET_BINARY_INTERFACE}x = x ] + then + echo m88k-dg-dgux${UNAME_RELEASE} + else + echo m88k-dg-dguxbcs${UNAME_RELEASE} + fi + else + echo i586-dg-dgux${UNAME_RELEASE} + fi + exit ;; + M88*:DolphinOS:*:*) # DolphinOS (SVR3) + echo m88k-dolphin-sysv3 + exit ;; + M88*:*:R3*:*) + # Delta 88k system running SVR3 + echo m88k-motorola-sysv3 + exit ;; + XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3) + echo m88k-tektronix-sysv3 + exit ;; + Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD) + echo m68k-tektronix-bsd + exit ;; + *:IRIX*:*:*) + echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'` + exit ;; + ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. + echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id + exit ;; # Note that: echo "'`uname -s`'" gives 'AIX ' + i*86:AIX:*:*) + echo i386-ibm-aix + exit ;; + ia64:AIX:*:*) + if [ -x /usr/bin/oslevel ] ; then + IBM_REV=`/usr/bin/oslevel` + else + IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} + fi + echo ${UNAME_MACHINE}-ibm-aix${IBM_REV} + exit ;; + *:AIX:2:3) + if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c + #include + + main() + { + if (!__power_pc()) + exit(1); + puts("powerpc-ibm-aix3.2.5"); + exit(0); + } +EOF + if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` + then + echo "$SYSTEM_NAME" + else + echo rs6000-ibm-aix3.2.5 + fi + elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then + echo rs6000-ibm-aix3.2.4 + else + echo rs6000-ibm-aix3.2 + fi + exit ;; + *:AIX:*:[4567]) + IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` + if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then + IBM_ARCH=rs6000 + else + IBM_ARCH=powerpc + fi + if [ -x /usr/bin/lslpp ] ; then + IBM_REV=`/usr/bin/lslpp -Lqc bos.rte.libc | + awk -F: '{ print $3 }' | sed s/[0-9]*$/0/` + else + IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} + fi + echo ${IBM_ARCH}-ibm-aix${IBM_REV} + exit ;; + *:AIX:*:*) + echo rs6000-ibm-aix + exit ;; + ibmrt:4.4BSD:*|romp-ibm:BSD:*) + echo romp-ibm-bsd4.4 + exit ;; + ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and + echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to + exit ;; # report: romp-ibm BSD 4.3 + *:BOSX:*:*) + echo rs6000-bull-bosx + exit ;; + DPX/2?00:B.O.S.:*:*) + echo m68k-bull-sysv3 + exit ;; + 9000/[34]??:4.3bsd:1.*:*) + echo m68k-hp-bsd + exit ;; + hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) + echo m68k-hp-bsd4.4 + exit ;; + 9000/[34678]??:HP-UX:*:*) + HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` + case "${UNAME_MACHINE}" in + 9000/31? ) HP_ARCH=m68000 ;; + 9000/[34]?? ) HP_ARCH=m68k ;; + 9000/[678][0-9][0-9]) + if [ -x /usr/bin/getconf ]; then + sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` + sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` + case "${sc_cpu_version}" in + 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 + 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 + 532) # CPU_PA_RISC2_0 + case "${sc_kernel_bits}" in + 32) HP_ARCH="hppa2.0n" ;; + 64) HP_ARCH="hppa2.0w" ;; + '') HP_ARCH="hppa2.0" ;; # HP-UX 10.20 + esac ;; + esac + fi + if [ "${HP_ARCH}" = "" ]; then + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c + + #define _HPUX_SOURCE + #include + #include + + int main () + { + #if defined(_SC_KERNEL_BITS) + long bits = sysconf(_SC_KERNEL_BITS); + #endif + long cpu = sysconf (_SC_CPU_VERSION); + + switch (cpu) + { + case CPU_PA_RISC1_0: puts ("hppa1.0"); break; + case CPU_PA_RISC1_1: puts ("hppa1.1"); break; + case CPU_PA_RISC2_0: + #if defined(_SC_KERNEL_BITS) + switch (bits) + { + case 64: puts ("hppa2.0w"); break; + case 32: puts ("hppa2.0n"); break; + default: puts ("hppa2.0"); break; + } break; + #else /* !defined(_SC_KERNEL_BITS) */ + puts ("hppa2.0"); break; + #endif + default: puts ("hppa1.0"); break; + } + exit (0); + } +EOF + (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy` + test -z "$HP_ARCH" && HP_ARCH=hppa + fi ;; + esac + if [ ${HP_ARCH} = "hppa2.0w" ] + then + eval $set_cc_for_build + + # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating + # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler + # generating 64-bit code. GNU and HP use different nomenclature: + # + # $ CC_FOR_BUILD=cc ./config.guess + # => hppa2.0w-hp-hpux11.23 + # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess + # => hppa64-hp-hpux11.23 + + if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | + grep -q __LP64__ + then + HP_ARCH="hppa2.0w" + else + HP_ARCH="hppa64" + fi + fi + echo ${HP_ARCH}-hp-hpux${HPUX_REV} + exit ;; + ia64:HP-UX:*:*) + HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` + echo ia64-hp-hpux${HPUX_REV} + exit ;; + 3050*:HI-UX:*:*) + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c + #include + int + main () + { + long cpu = sysconf (_SC_CPU_VERSION); + /* The order matters, because CPU_IS_HP_MC68K erroneously returns + true for CPU_PA_RISC1_0. CPU_IS_PA_RISC returns correct + results, however. */ + if (CPU_IS_PA_RISC (cpu)) + { + switch (cpu) + { + case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break; + case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break; + case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break; + default: puts ("hppa-hitachi-hiuxwe2"); break; + } + } + else if (CPU_IS_HP_MC68K (cpu)) + puts ("m68k-hitachi-hiuxwe2"); + else puts ("unknown-hitachi-hiuxwe2"); + exit (0); + } +EOF + $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` && + { echo "$SYSTEM_NAME"; exit; } + echo unknown-hitachi-hiuxwe2 + exit ;; + 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* ) + echo hppa1.1-hp-bsd + exit ;; + 9000/8??:4.3bsd:*:*) + echo hppa1.0-hp-bsd + exit ;; + *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) + echo hppa1.0-hp-mpeix + exit ;; + hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* ) + echo hppa1.1-hp-osf + exit ;; + hp8??:OSF1:*:*) + echo hppa1.0-hp-osf + exit ;; + i*86:OSF1:*:*) + if [ -x /usr/sbin/sysversion ] ; then + echo ${UNAME_MACHINE}-unknown-osf1mk + else + echo ${UNAME_MACHINE}-unknown-osf1 + fi + exit ;; + parisc*:Lites*:*:*) + echo hppa1.1-hp-lites + exit ;; + C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) + echo c1-convex-bsd + exit ;; + C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) + if getsysinfo -f scalar_acc + then echo c32-convex-bsd + else echo c2-convex-bsd + fi + exit ;; + C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) + echo c34-convex-bsd + exit ;; + C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) + echo c38-convex-bsd + exit ;; + C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) + echo c4-convex-bsd + exit ;; + CRAY*Y-MP:*:*:*) + echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' + exit ;; + CRAY*[A-Z]90:*:*:*) + echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \ + | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \ + -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \ + -e 's/\.[^.]*$/.X/' + exit ;; + CRAY*TS:*:*:*) + echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' + exit ;; + CRAY*T3E:*:*:*) + echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' + exit ;; + CRAY*SV1:*:*:*) + echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' + exit ;; + *:UNICOS/mp:*:*) + echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' + exit ;; + F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) + FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` + FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` + FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` + echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" + exit ;; + 5000:UNIX_System_V:4.*:*) + FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` + FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` + echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" + exit ;; + i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) + echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} + exit ;; + sparc*:BSD/OS:*:*) + echo sparc-unknown-bsdi${UNAME_RELEASE} + exit ;; + *:BSD/OS:*:*) + echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} + exit ;; + *:FreeBSD:*:*) + UNAME_PROCESSOR=`/usr/bin/uname -p` + case ${UNAME_PROCESSOR} in + amd64) + echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; + *) + echo ${UNAME_PROCESSOR}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; + esac + exit ;; + i*:CYGWIN*:*) + echo ${UNAME_MACHINE}-pc-cygwin + exit ;; + *:MINGW64*:*) + echo ${UNAME_MACHINE}-pc-mingw64 + exit ;; + *:MINGW*:*) + echo ${UNAME_MACHINE}-pc-mingw32 + exit ;; + *:MSYS*:*) + echo ${UNAME_MACHINE}-pc-msys + exit ;; + i*:windows32*:*) + # uname -m includes "-pc" on this system. + echo ${UNAME_MACHINE}-mingw32 + exit ;; + i*:PW*:*) + echo ${UNAME_MACHINE}-pc-pw32 + exit ;; + *:Interix*:*) + case ${UNAME_MACHINE} in + x86) + echo i586-pc-interix${UNAME_RELEASE} + exit ;; + authenticamd | genuineintel | EM64T) + echo x86_64-unknown-interix${UNAME_RELEASE} + exit ;; + IA64) + echo ia64-unknown-interix${UNAME_RELEASE} + exit ;; + esac ;; + [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) + echo i${UNAME_MACHINE}-pc-mks + exit ;; + 8664:Windows_NT:*) + echo x86_64-pc-mks + exit ;; + i*:Windows_NT*:* | Pentium*:Windows_NT*:*) + # How do we know it's Interix rather than the generic POSIX subsystem? + # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we + # UNAME_MACHINE based on the output of uname instead of i386? + echo i586-pc-interix + exit ;; + i*:UWIN*:*) + echo ${UNAME_MACHINE}-pc-uwin + exit ;; + amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) + echo x86_64-unknown-cygwin + exit ;; + p*:CYGWIN*:*) + echo powerpcle-unknown-cygwin + exit ;; + prep*:SunOS:5.*:*) + echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + exit ;; + *:GNU:*:*) + # the GNU system + echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-${LIBC}`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` + exit ;; + *:GNU/*:*:*) + # other systems with GNU libc and userland + echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-${LIBC} + exit ;; + i*86:Minix:*:*) + echo ${UNAME_MACHINE}-pc-minix + exit ;; + aarch64:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + aarch64_be:Linux:*:*) + UNAME_MACHINE=aarch64_be + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + alpha:Linux:*:*) + case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in + EV5) UNAME_MACHINE=alphaev5 ;; + EV56) UNAME_MACHINE=alphaev56 ;; + PCA56) UNAME_MACHINE=alphapca56 ;; + PCA57) UNAME_MACHINE=alphapca56 ;; + EV6) UNAME_MACHINE=alphaev6 ;; + EV67) UNAME_MACHINE=alphaev67 ;; + EV68*) UNAME_MACHINE=alphaev68 ;; + esac + objdump --private-headers /bin/sh | grep -q ld.so.1 + if test "$?" = 0 ; then LIBC="gnulibc1" ; fi + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + arc:Linux:*:* | arceb:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + arm*:Linux:*:*) + eval $set_cc_for_build + if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ + | grep -q __ARM_EABI__ + then + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + else + if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ + | grep -q __ARM_PCS_VFP + then + echo ${UNAME_MACHINE}-unknown-linux-${LIBC}eabi + else + echo ${UNAME_MACHINE}-unknown-linux-${LIBC}eabihf + fi + fi + exit ;; + avr32*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + cris:Linux:*:*) + echo ${UNAME_MACHINE}-axis-linux-${LIBC} + exit ;; + crisv32:Linux:*:*) + echo ${UNAME_MACHINE}-axis-linux-${LIBC} + exit ;; + e2k:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + frv:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + hexagon:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + i*86:Linux:*:*) + echo ${UNAME_MACHINE}-pc-linux-${LIBC} + exit ;; + ia64:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + m32r*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + m68*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + mips:Linux:*:* | mips64:Linux:*:*) + eval $set_cc_for_build + sed 's/^ //' << EOF >$dummy.c + #undef CPU + #undef ${UNAME_MACHINE} + #undef ${UNAME_MACHINE}el + #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) + CPU=${UNAME_MACHINE}el + #else + #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) + CPU=${UNAME_MACHINE} + #else + CPU= + #endif + #endif +EOF + eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'` + test x"${CPU}" != x && { echo "${CPU}-unknown-linux-${LIBC}"; exit; } + ;; + openrisc*:Linux:*:*) + echo or1k-unknown-linux-${LIBC} + exit ;; + or32:Linux:*:* | or1k*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + padre:Linux:*:*) + echo sparc-unknown-linux-${LIBC} + exit ;; + parisc64:Linux:*:* | hppa64:Linux:*:*) + echo hppa64-unknown-linux-${LIBC} + exit ;; + parisc:Linux:*:* | hppa:Linux:*:*) + # Look for CPU level + case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in + PA7*) echo hppa1.1-unknown-linux-${LIBC} ;; + PA8*) echo hppa2.0-unknown-linux-${LIBC} ;; + *) echo hppa-unknown-linux-${LIBC} ;; + esac + exit ;; + ppc64:Linux:*:*) + echo powerpc64-unknown-linux-${LIBC} + exit ;; + ppc:Linux:*:*) + echo powerpc-unknown-linux-${LIBC} + exit ;; + ppc64le:Linux:*:*) + echo powerpc64le-unknown-linux-${LIBC} + exit ;; + ppcle:Linux:*:*) + echo powerpcle-unknown-linux-${LIBC} + exit ;; + s390:Linux:*:* | s390x:Linux:*:*) + echo ${UNAME_MACHINE}-ibm-linux-${LIBC} + exit ;; + sh64*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + sh*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + sparc:Linux:*:* | sparc64:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + tile*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + vax:Linux:*:*) + echo ${UNAME_MACHINE}-dec-linux-${LIBC} + exit ;; + x86_64:Linux:*:*) + echo ${UNAME_MACHINE}-pc-linux-${LIBC} + exit ;; + xtensa*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-${LIBC} + exit ;; + i*86:DYNIX/ptx:4*:*) + # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. + # earlier versions are messed up and put the nodename in both + # sysname and nodename. + echo i386-sequent-sysv4 + exit ;; + i*86:UNIX_SV:4.2MP:2.*) + # Unixware is an offshoot of SVR4, but it has its own version + # number series starting with 2... + # I am not positive that other SVR4 systems won't match this, + # I just have to hope. -- rms. + # Use sysv4.2uw... so that sysv4* matches it. + echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION} + exit ;; + i*86:OS/2:*:*) + # If we were able to find `uname', then EMX Unix compatibility + # is probably installed. + echo ${UNAME_MACHINE}-pc-os2-emx + exit ;; + i*86:XTS-300:*:STOP) + echo ${UNAME_MACHINE}-unknown-stop + exit ;; + i*86:atheos:*:*) + echo ${UNAME_MACHINE}-unknown-atheos + exit ;; + i*86:syllable:*:*) + echo ${UNAME_MACHINE}-pc-syllable + exit ;; + i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*) + echo i386-unknown-lynxos${UNAME_RELEASE} + exit ;; + i*86:*DOS:*:*) + echo ${UNAME_MACHINE}-pc-msdosdjgpp + exit ;; + i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*) + UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'` + if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then + echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL} + else + echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL} + fi + exit ;; + i*86:*:5:[678]*) + # UnixWare 7.x, OpenUNIX and OpenServer 6. + case `/bin/uname -X | grep "^Machine"` in + *486*) UNAME_MACHINE=i486 ;; + *Pentium) UNAME_MACHINE=i586 ;; + *Pent*|*Celeron) UNAME_MACHINE=i686 ;; + esac + echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} + exit ;; + i*86:*:3.2:*) + if test -f /usr/options/cb.name; then + UNAME_REL=`sed -n 's/.*Version //p' /dev/null >/dev/null ; then + UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')` + (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486 + (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \ + && UNAME_MACHINE=i586 + (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \ + && UNAME_MACHINE=i686 + (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ + && UNAME_MACHINE=i686 + echo ${UNAME_MACHINE}-pc-sco$UNAME_REL + else + echo ${UNAME_MACHINE}-pc-sysv32 + fi + exit ;; + pc:*:*:*) + # Left here for compatibility: + # uname -m prints for DJGPP always 'pc', but it prints nothing about + # the processor, so we play safe by assuming i586. + # Note: whatever this is, it MUST be the same as what config.sub + # prints for the "djgpp" host, or else GDB configury will decide that + # this is a cross-build. + echo i586-pc-msdosdjgpp + exit ;; + Intel:Mach:3*:*) + echo i386-pc-mach3 + exit ;; + paragon:*:*:*) + echo i860-intel-osf1 + exit ;; + i860:*:4.*:*) # i860-SVR4 + if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then + echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4 + else # Add other i860-SVR4 vendors below as they are discovered. + echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4 + fi + exit ;; + mini*:CTIX:SYS*5:*) + # "miniframe" + echo m68010-convergent-sysv + exit ;; + mc68k:UNIX:SYSTEM5:3.51m) + echo m68k-convergent-sysv + exit ;; + M680?0:D-NIX:5.3:*) + echo m68k-diab-dnix + exit ;; + M68*:*:R3V[5678]*:*) + test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;; + 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0) + OS_REL='' + test -r /etc/.relid \ + && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` + /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ + && { echo i486-ncr-sysv4.3${OS_REL}; exit; } + /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ + && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; + 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) + /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ + && { echo i486-ncr-sysv4; exit; } ;; + NCR*:*:4.2:* | MPRAS*:*:4.2:*) + OS_REL='.3' + test -r /etc/.relid \ + && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` + /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ + && { echo i486-ncr-sysv4.3${OS_REL}; exit; } + /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ + && { echo i586-ncr-sysv4.3${OS_REL}; exit; } + /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \ + && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; + m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) + echo m68k-unknown-lynxos${UNAME_RELEASE} + exit ;; + mc68030:UNIX_System_V:4.*:*) + echo m68k-atari-sysv4 + exit ;; + TSUNAMI:LynxOS:2.*:*) + echo sparc-unknown-lynxos${UNAME_RELEASE} + exit ;; + rs6000:LynxOS:2.*:*) + echo rs6000-unknown-lynxos${UNAME_RELEASE} + exit ;; + PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*) + echo powerpc-unknown-lynxos${UNAME_RELEASE} + exit ;; + SM[BE]S:UNIX_SV:*:*) + echo mips-dde-sysv${UNAME_RELEASE} + exit ;; + RM*:ReliantUNIX-*:*:*) + echo mips-sni-sysv4 + exit ;; + RM*:SINIX-*:*:*) + echo mips-sni-sysv4 + exit ;; + *:SINIX-*:*:*) + if uname -p 2>/dev/null >/dev/null ; then + UNAME_MACHINE=`(uname -p) 2>/dev/null` + echo ${UNAME_MACHINE}-sni-sysv4 + else + echo ns32k-sni-sysv + fi + exit ;; + PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort + # says + echo i586-unisys-sysv4 + exit ;; + *:UNIX_System_V:4*:FTX*) + # From Gerald Hewes . + # How about differentiating between stratus architectures? -djm + echo hppa1.1-stratus-sysv4 + exit ;; + *:*:*:FTX*) + # From seanf@swdc.stratus.com. + echo i860-stratus-sysv4 + exit ;; + i*86:VOS:*:*) + # From Paul.Green@stratus.com. + echo ${UNAME_MACHINE}-stratus-vos + exit ;; + *:VOS:*:*) + # From Paul.Green@stratus.com. + echo hppa1.1-stratus-vos + exit ;; + mc68*:A/UX:*:*) + echo m68k-apple-aux${UNAME_RELEASE} + exit ;; + news*:NEWS-OS:6*:*) + echo mips-sony-newsos6 + exit ;; + R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) + if [ -d /usr/nec ]; then + echo mips-nec-sysv${UNAME_RELEASE} + else + echo mips-unknown-sysv${UNAME_RELEASE} + fi + exit ;; + BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. + echo powerpc-be-beos + exit ;; + BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. + echo powerpc-apple-beos + exit ;; + BePC:BeOS:*:*) # BeOS running on Intel PC compatible. + echo i586-pc-beos + exit ;; + BePC:Haiku:*:*) # Haiku running on Intel PC compatible. + echo i586-pc-haiku + exit ;; + x86_64:Haiku:*:*) + echo x86_64-unknown-haiku + exit ;; + SX-4:SUPER-UX:*:*) + echo sx4-nec-superux${UNAME_RELEASE} + exit ;; + SX-5:SUPER-UX:*:*) + echo sx5-nec-superux${UNAME_RELEASE} + exit ;; + SX-6:SUPER-UX:*:*) + echo sx6-nec-superux${UNAME_RELEASE} + exit ;; + SX-7:SUPER-UX:*:*) + echo sx7-nec-superux${UNAME_RELEASE} + exit ;; + SX-8:SUPER-UX:*:*) + echo sx8-nec-superux${UNAME_RELEASE} + exit ;; + SX-8R:SUPER-UX:*:*) + echo sx8r-nec-superux${UNAME_RELEASE} + exit ;; + Power*:Rhapsody:*:*) + echo powerpc-apple-rhapsody${UNAME_RELEASE} + exit ;; + *:Rhapsody:*:*) + echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE} + exit ;; + *:Darwin:*:*) + UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown + eval $set_cc_for_build + if test "$UNAME_PROCESSOR" = unknown ; then + UNAME_PROCESSOR=powerpc + fi + if test `echo "$UNAME_RELEASE" | sed -e 's/\..*//'` -le 10 ; then + if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then + if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \ + (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ + grep IS_64BIT_ARCH >/dev/null + then + case $UNAME_PROCESSOR in + i386) UNAME_PROCESSOR=x86_64 ;; + powerpc) UNAME_PROCESSOR=powerpc64 ;; + esac + fi + fi + elif test "$UNAME_PROCESSOR" = i386 ; then + # Avoid executing cc on OS X 10.9, as it ships with a stub + # that puts up a graphical alert prompting to install + # developer tools. Any system running Mac OS X 10.7 or + # later (Darwin 11 and later) is required to have a 64-bit + # processor. This is not true of the ARM version of Darwin + # that Apple uses in portable devices. + UNAME_PROCESSOR=x86_64 + fi + echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} + exit ;; + *:procnto*:*:* | *:QNX:[0123456789]*:*) + UNAME_PROCESSOR=`uname -p` + if test "$UNAME_PROCESSOR" = "x86"; then + UNAME_PROCESSOR=i386 + UNAME_MACHINE=pc + fi + echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE} + exit ;; + *:QNX:*:4*) + echo i386-pc-qnx + exit ;; + NEO-?:NONSTOP_KERNEL:*:*) + echo neo-tandem-nsk${UNAME_RELEASE} + exit ;; + NSE-*:NONSTOP_KERNEL:*:*) + echo nse-tandem-nsk${UNAME_RELEASE} + exit ;; + NSR-?:NONSTOP_KERNEL:*:*) + echo nsr-tandem-nsk${UNAME_RELEASE} + exit ;; + *:NonStop-UX:*:*) + echo mips-compaq-nonstopux + exit ;; + BS2000:POSIX*:*:*) + echo bs2000-siemens-sysv + exit ;; + DS/*:UNIX_System_V:*:*) + echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE} + exit ;; + *:Plan9:*:*) + # "uname -m" is not consistent, so use $cputype instead. 386 + # is converted to i386 for consistency with other x86 + # operating systems. + if test "$cputype" = "386"; then + UNAME_MACHINE=i386 + else + UNAME_MACHINE="$cputype" + fi + echo ${UNAME_MACHINE}-unknown-plan9 + exit ;; + *:TOPS-10:*:*) + echo pdp10-unknown-tops10 + exit ;; + *:TENEX:*:*) + echo pdp10-unknown-tenex + exit ;; + KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*) + echo pdp10-dec-tops20 + exit ;; + XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*) + echo pdp10-xkl-tops20 + exit ;; + *:TOPS-20:*:*) + echo pdp10-unknown-tops20 + exit ;; + *:ITS:*:*) + echo pdp10-unknown-its + exit ;; + SEI:*:*:SEIUX) + echo mips-sei-seiux${UNAME_RELEASE} + exit ;; + *:DragonFly:*:*) + echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` + exit ;; + *:*VMS:*:*) + UNAME_MACHINE=`(uname -p) 2>/dev/null` + case "${UNAME_MACHINE}" in + A*) echo alpha-dec-vms ; exit ;; + I*) echo ia64-dec-vms ; exit ;; + V*) echo vax-dec-vms ; exit ;; + esac ;; + *:XENIX:*:SysV) + echo i386-pc-xenix + exit ;; + i*86:skyos:*:*) + echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//' + exit ;; + i*86:rdos:*:*) + echo ${UNAME_MACHINE}-pc-rdos + exit ;; + i*86:AROS:*:*) + echo ${UNAME_MACHINE}-pc-aros + exit ;; + x86_64:VMkernel:*:*) + echo ${UNAME_MACHINE}-unknown-esx + exit ;; +esac + +cat >&2 < in order to provide the needed +information to handle your system. + +config.guess timestamp = $timestamp + +uname -m = `(uname -m) 2>/dev/null || echo unknown` +uname -r = `(uname -r) 2>/dev/null || echo unknown` +uname -s = `(uname -s) 2>/dev/null || echo unknown` +uname -v = `(uname -v) 2>/dev/null || echo unknown` + +/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null` +/bin/uname -X = `(/bin/uname -X) 2>/dev/null` + +hostinfo = `(hostinfo) 2>/dev/null` +/bin/universe = `(/bin/universe) 2>/dev/null` +/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null` +/bin/arch = `(/bin/arch) 2>/dev/null` +/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null` +/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null` + +UNAME_MACHINE = ${UNAME_MACHINE} +UNAME_RELEASE = ${UNAME_RELEASE} +UNAME_SYSTEM = ${UNAME_SYSTEM} +UNAME_VERSION = ${UNAME_VERSION} +EOF + +exit 1 + +# Local variables: +# eval: (add-hook 'write-file-hooks 'time-stamp) +# time-stamp-start: "timestamp='" +# time-stamp-format: "%:y-%02m-%02d" +# time-stamp-end: "'" +# End: diff --git a/libs/ode-0.16.1/config.h.cmake.in b/libs/ode-0.16.1/config.h.cmake.in new file mode 100644 index 0000000..d2f9599 --- /dev/null +++ b/libs/ode-0.16.1/config.h.cmake.in @@ -0,0 +1,109 @@ +#ifndef ODE_CONFIG_H +#define ODE_CONFIG_H + +/* Define to 1 if you have and it should be used (not on Ultrix). */ +#cmakedefine HAVE_ALLOCA_H 1 + +/* Use the Apple OpenGL framework. */ +#cmakedefine HAVE_APPLE_OPENGL_FRAMEWORK 1 + +/* Define to 1 if you have the `gettimeofday' function. */ +#cmakedefine HAVE_GETTIMEOFDAY 1 + +/* Define to 1 if you have the header file. */ +#cmakedefine HAVE_INTTYPES_H 1 + +/* Define to 1 if you have the `isnan' function. */ +#cmakedefine HAVE_ISNAN 1 + +/* Define to 1 if you have the `isnanf' function. */ +#cmakedefine HAVE_ISNANF 1 + +/* Define to 1 if you have the header file. */ +#cmakedefine HAVE_MALLOC_H 1 + +/* Define to 1 if you have the `pthread_attr_setstacklazy' function. */ +#cmakedefine HAVE_PTHREAD_ATTR_SETSTACKLAZY 1 + +/* Define to 1 if you have the `pthread_condattr_setclock' function. */ +#cmakedefine HAVE_PTHREAD_CONDATTR_SETCLOCK 1 + +/* Define to 1 if you have the header file. */ +#cmakedefine HAVE_STDINT_H 1 + +/* Define to 1 if you have the header file. */ +#cmakedefine HAVE_SYS_TIME_H 1 + +/* Define to 1 if you have the header file. */ +#cmakedefine HAVE_SYS_TYPES_H 1 + +/* Define to 1 if you have the header file. */ +#cmakedefine HAVE_UNISTD_H 1 + +/* Define to 1 if you have the `_isnan' function. */ +#cmakedefine HAVE__ISNAN 1 + +/* Define to 1 if you have the `_isnanf' function. */ +#cmakedefine HAVE__ISNANF 1 + +/* Define to 1 if you have the `__isnan' function. */ +#cmakedefine HAVE___ISNAN 1 + +/* Define to 1 if you have the `__isnanf' function. */ +#cmakedefine HAVE___ISNANF 1 + +/* compiling for a pentium on a gcc-based platform? */ +#cmakedefine PENTIUM 1 + +/* compiling for a X86_64 system on a gcc-based platform? */ +#cmakedefine X86_64_SYSTEM 1 + +/* Try to identify the platform */ +#if defined(_XENON) +#define ODE_PLATFORM_XBOX360 +#elif defined(SN_TARGET_PSP_HW) +#define ODE_PLATFORM_PSP +#elif defined(SN_TARGET_PS3) +#define ODE_PLATFORM_PS3 +#elif defined(_MSC_VER) || defined(__CYGWIN32__) || defined(__MINGW32__) +#define ODE_PLATFORM_WINDOWS +#elif defined(__linux__) +#define ODE_PLATFORM_LINUX +#elif defined(__APPLE__) && defined(__MACH__) +#define ODE_PLATFORM_OSX +#else +#error "Need some help identifying the platform!" +#endif + +/* Additional platform defines used in the code */ +#if defined(ODE_PLATFORM_WINDOWS) && !defined(WIN32) +#define WIN32 +#endif + +#if defined(__CYGWIN32__) || defined(__MINGW32__) +#define CYGWIN +#endif + +#if defined(ODE_PLATFORM_OSX) +#define macintosh +#endif + +#ifdef HAVE_ALLOCA_H +#include +#endif + +#ifdef HAVE_MALLOC_H +#include +#endif + +#ifdef HAVE_STDINT_H +#include +#endif + +#ifdef HAVE_INTTYPES_H +#include +#endif + +#include "typedefs.h" + +#endif // ODE_CONFIG_H diff --git a/libs/ode-0.16.1/config.sub b/libs/ode-0.16.1/config.sub new file mode 100755 index 0000000..1acc966 --- /dev/null +++ b/libs/ode-0.16.1/config.sub @@ -0,0 +1,1813 @@ +#! /bin/sh +# Configuration validation subroutine script. +# Copyright 1992-2015 Free Software Foundation, Inc. + +timestamp='2015-08-20' + +# This file is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 3 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, see . +# +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that +# program. This Exception is an additional permission under section 7 +# of the GNU General Public License, version 3 ("GPLv3"). + + +# Please send patches to . +# +# Configuration subroutine to validate and canonicalize a configuration type. +# Supply the specified configuration type as an argument. +# If it is invalid, we print an error message on stderr and exit with code 1. +# Otherwise, we print the canonical config type on stdout and succeed. + +# You can get the latest version of this script from: +# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD + +# This file is supposed to be the same for all GNU packages +# and recognize all the CPU types, system types and aliases +# that are meaningful with *any* GNU software. +# Each package is responsible for reporting which valid configurations +# it does not support. The user should be able to distinguish +# a failure to support a valid configuration from a meaningless +# configuration. + +# The goal of this file is to map all the various variations of a given +# machine specification into a single specification in the form: +# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM +# or in some cases, the newer four-part form: +# CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM +# It is wrong to echo any other type of specification. + +me=`echo "$0" | sed -e 's,.*/,,'` + +usage="\ +Usage: $0 [OPTION] CPU-MFR-OPSYS + $0 [OPTION] ALIAS + +Canonicalize a configuration name. + +Operation modes: + -h, --help print this help, then exit + -t, --time-stamp print date of last modification, then exit + -v, --version print version number, then exit + +Report bugs and patches to ." + +version="\ +GNU config.sub ($timestamp) + +Copyright 1992-2015 Free Software Foundation, Inc. + +This is free software; see the source for copying conditions. There is NO +warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." + +help=" +Try \`$me --help' for more information." + +# Parse command line +while test $# -gt 0 ; do + case $1 in + --time-stamp | --time* | -t ) + echo "$timestamp" ; exit ;; + --version | -v ) + echo "$version" ; exit ;; + --help | --h* | -h ) + echo "$usage"; exit ;; + -- ) # Stop option processing + shift; break ;; + - ) # Use stdin as input. + break ;; + -* ) + echo "$me: invalid option $1$help" + exit 1 ;; + + *local*) + # First pass through any local machine types. + echo $1 + exit ;; + + * ) + break ;; + esac +done + +case $# in + 0) echo "$me: missing argument$help" >&2 + exit 1;; + 1) ;; + *) echo "$me: too many arguments$help" >&2 + exit 1;; +esac + +# Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any). +# Here we must recognize all the valid KERNEL-OS combinations. +maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` +case $maybe_os in + nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \ + linux-musl* | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \ + knetbsd*-gnu* | netbsd*-gnu* | netbsd*-eabi* | \ + kopensolaris*-gnu* | \ + storm-chaos* | os2-emx* | rtmk-nova*) + os=-$maybe_os + basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` + ;; + android-linux) + os=-linux-android + basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`-unknown + ;; + *) + basic_machine=`echo $1 | sed 's/-[^-]*$//'` + if [ $basic_machine != $1 ] + then os=`echo $1 | sed 's/.*-/-/'` + else os=; fi + ;; +esac + +### Let's recognize common machines as not being operating systems so +### that things like config.sub decstation-3100 work. We also +### recognize some manufacturers as not being operating systems, so we +### can provide default operating systems below. +case $os in + -sun*os*) + # Prevent following clause from handling this invalid input. + ;; + -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \ + -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \ + -unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \ + -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\ + -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \ + -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \ + -apple | -axis | -knuth | -cray | -microblaze*) + os= + basic_machine=$1 + ;; + -bluegene*) + os=-cnk + ;; + -sim | -cisco | -oki | -wec | -winbond) + os= + basic_machine=$1 + ;; + -scout) + ;; + -wrs) + os=-vxworks + basic_machine=$1 + ;; + -chorusos*) + os=-chorusos + basic_machine=$1 + ;; + -chorusrdb) + os=-chorusrdb + basic_machine=$1 + ;; + -hiux*) + os=-hiuxwe2 + ;; + -sco6) + os=-sco5v6 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco5) + os=-sco3.2v5 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco4) + os=-sco3.2v4 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco3.2.[4-9]*) + os=`echo $os | sed -e 's/sco3.2./sco3.2v/'` + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco3.2v[4-9]*) + # Don't forget version if it is 3.2v4 or newer. + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco5v6*) + # Don't forget version if it is 3.2v4 or newer. + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -sco*) + os=-sco3.2v2 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -udk*) + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -isc) + os=-isc2.2 + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -clix*) + basic_machine=clipper-intergraph + ;; + -isc*) + basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` + ;; + -lynx*178) + os=-lynxos178 + ;; + -lynx*5) + os=-lynxos5 + ;; + -lynx*) + os=-lynxos + ;; + -ptx*) + basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'` + ;; + -windowsnt*) + os=`echo $os | sed -e 's/windowsnt/winnt/'` + ;; + -psos*) + os=-psos + ;; + -mint | -mint[0-9]*) + basic_machine=m68k-atari + os=-mint + ;; +esac + +# Decode aliases for certain CPU-COMPANY combinations. +case $basic_machine in + # Recognize the basic CPU types without company name. + # Some are omitted here because they have special meanings below. + 1750a | 580 \ + | a29k \ + | aarch64 | aarch64_be \ + | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ + | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ + | am33_2.0 \ + | arc | arceb \ + | arm | arm[bl]e | arme[lb] | armv[2-8] | armv[3-8][lb] | armv7[arm] \ + | avr | avr32 \ + | ba \ + | be32 | be64 \ + | bfin \ + | c4x | c8051 | clipper \ + | d10v | d30v | dlx | dsp16xx \ + | e2k | epiphany \ + | fido | fr30 | frv | ft32 \ + | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ + | hexagon \ + | i370 | i860 | i960 | ia64 \ + | ip2k | iq2000 \ + | k1om \ + | le32 | le64 \ + | lm32 \ + | m32c | m32r | m32rle | m68000 | m68k | m88k \ + | maxq | mb | microblaze | microblazeel | mcore | mep | metag \ + | mips | mipsbe | mipseb | mipsel | mipsle \ + | mips16 \ + | mips64 | mips64el \ + | mips64octeon | mips64octeonel \ + | mips64orion | mips64orionel \ + | mips64r5900 | mips64r5900el \ + | mips64vr | mips64vrel \ + | mips64vr4100 | mips64vr4100el \ + | mips64vr4300 | mips64vr4300el \ + | mips64vr5000 | mips64vr5000el \ + | mips64vr5900 | mips64vr5900el \ + | mipsisa32 | mipsisa32el \ + | mipsisa32r2 | mipsisa32r2el \ + | mipsisa32r6 | mipsisa32r6el \ + | mipsisa64 | mipsisa64el \ + | mipsisa64r2 | mipsisa64r2el \ + | mipsisa64r6 | mipsisa64r6el \ + | mipsisa64sb1 | mipsisa64sb1el \ + | mipsisa64sr71k | mipsisa64sr71kel \ + | mipsr5900 | mipsr5900el \ + | mipstx39 | mipstx39el \ + | mn10200 | mn10300 \ + | moxie \ + | mt \ + | msp430 \ + | nds32 | nds32le | nds32be \ + | nios | nios2 | nios2eb | nios2el \ + | ns16k | ns32k \ + | open8 | or1k | or1knd | or32 \ + | pdp10 | pdp11 | pj | pjl \ + | powerpc | powerpc64 | powerpc64le | powerpcle \ + | pyramid \ + | riscv32 | riscv64 \ + | rl78 | rx \ + | score \ + | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[234]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ + | sh64 | sh64le \ + | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \ + | sparcv8 | sparcv9 | sparcv9b | sparcv9v \ + | spu \ + | tahoe | tic4x | tic54x | tic55x | tic6x | tic80 | tron \ + | ubicom32 \ + | v850 | v850e | v850e1 | v850e2 | v850es | v850e2v3 \ + | visium \ + | we32k \ + | x86 | xc16x | xstormy16 | xtensa \ + | z8k | z80) + basic_machine=$basic_machine-unknown + ;; + c54x) + basic_machine=tic54x-unknown + ;; + c55x) + basic_machine=tic55x-unknown + ;; + c6x) + basic_machine=tic6x-unknown + ;; + leon|leon[3-9]) + basic_machine=sparc-$basic_machine + ;; + m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x | nvptx | picochip) + basic_machine=$basic_machine-unknown + os=-none + ;; + m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k) + ;; + ms1) + basic_machine=mt-unknown + ;; + + strongarm | thumb | xscale) + basic_machine=arm-unknown + ;; + xgate) + basic_machine=$basic_machine-unknown + os=-none + ;; + xscaleeb) + basic_machine=armeb-unknown + ;; + + xscaleel) + basic_machine=armel-unknown + ;; + + # We use `pc' rather than `unknown' + # because (1) that's what they normally are, and + # (2) the word "unknown" tends to confuse beginning users. + i*86 | x86_64) + basic_machine=$basic_machine-pc + ;; + # Object if more than one company name word. + *-*-*) + echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 + exit 1 + ;; + # Recognize the basic CPU types with company name. + 580-* \ + | a29k-* \ + | aarch64-* | aarch64_be-* \ + | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ + | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ + | alphapca5[67]-* | alpha64pca5[67]-* | arc-* | arceb-* \ + | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ + | avr-* | avr32-* \ + | ba-* \ + | be32-* | be64-* \ + | bfin-* | bs2000-* \ + | c[123]* | c30-* | [cjt]90-* | c4x-* \ + | c8051-* | clipper-* | craynv-* | cydra-* \ + | d10v-* | d30v-* | dlx-* \ + | e2k-* | elxsi-* \ + | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \ + | h8300-* | h8500-* \ + | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ + | hexagon-* \ + | i*86-* | i860-* | i960-* | ia64-* \ + | ip2k-* | iq2000-* \ + | k1om-* \ + | le32-* | le64-* \ + | lm32-* \ + | m32c-* | m32r-* | m32rle-* \ + | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ + | m88110-* | m88k-* | maxq-* | mcore-* | metag-* \ + | microblaze-* | microblazeel-* \ + | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ + | mips16-* \ + | mips64-* | mips64el-* \ + | mips64octeon-* | mips64octeonel-* \ + | mips64orion-* | mips64orionel-* \ + | mips64r5900-* | mips64r5900el-* \ + | mips64vr-* | mips64vrel-* \ + | mips64vr4100-* | mips64vr4100el-* \ + | mips64vr4300-* | mips64vr4300el-* \ + | mips64vr5000-* | mips64vr5000el-* \ + | mips64vr5900-* | mips64vr5900el-* \ + | mipsisa32-* | mipsisa32el-* \ + | mipsisa32r2-* | mipsisa32r2el-* \ + | mipsisa32r6-* | mipsisa32r6el-* \ + | mipsisa64-* | mipsisa64el-* \ + | mipsisa64r2-* | mipsisa64r2el-* \ + | mipsisa64r6-* | mipsisa64r6el-* \ + | mipsisa64sb1-* | mipsisa64sb1el-* \ + | mipsisa64sr71k-* | mipsisa64sr71kel-* \ + | mipsr5900-* | mipsr5900el-* \ + | mipstx39-* | mipstx39el-* \ + | mmix-* \ + | mt-* \ + | msp430-* \ + | nds32-* | nds32le-* | nds32be-* \ + | nios-* | nios2-* | nios2eb-* | nios2el-* \ + | none-* | np1-* | ns16k-* | ns32k-* \ + | open8-* \ + | or1k*-* \ + | orion-* \ + | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ + | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \ + | pyramid-* \ + | riscv32-* | riscv64-* \ + | rl78-* | romp-* | rs6000-* | rx-* \ + | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ + | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ + | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \ + | sparclite-* \ + | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | sv1-* | sx*-* \ + | tahoe-* \ + | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ + | tile*-* \ + | tron-* \ + | ubicom32-* \ + | v850-* | v850e-* | v850e1-* | v850es-* | v850e2-* | v850e2v3-* \ + | vax-* \ + | visium-* \ + | we32k-* \ + | x86-* | x86_64-* | xc16x-* | xps100-* \ + | xstormy16-* | xtensa*-* \ + | ymp-* \ + | z8k-* | z80-*) + ;; + # Recognize the basic CPU types without company name, with glob match. + xtensa*) + basic_machine=$basic_machine-unknown + ;; + # Recognize the various machine names and aliases which stand + # for a CPU type and a company and sometimes even an OS. + 386bsd) + basic_machine=i386-unknown + os=-bsd + ;; + 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) + basic_machine=m68000-att + ;; + 3b*) + basic_machine=we32k-att + ;; + a29khif) + basic_machine=a29k-amd + os=-udi + ;; + abacus) + basic_machine=abacus-unknown + ;; + adobe68k) + basic_machine=m68010-adobe + os=-scout + ;; + alliant | fx80) + basic_machine=fx80-alliant + ;; + altos | altos3068) + basic_machine=m68k-altos + ;; + am29k) + basic_machine=a29k-none + os=-bsd + ;; + amd64) + basic_machine=x86_64-pc + ;; + amd64-*) + basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + amdahl) + basic_machine=580-amdahl + os=-sysv + ;; + amiga | amiga-*) + basic_machine=m68k-unknown + ;; + amigaos | amigados) + basic_machine=m68k-unknown + os=-amigaos + ;; + amigaunix | amix) + basic_machine=m68k-unknown + os=-sysv4 + ;; + apollo68) + basic_machine=m68k-apollo + os=-sysv + ;; + apollo68bsd) + basic_machine=m68k-apollo + os=-bsd + ;; + aros) + basic_machine=i386-pc + os=-aros + ;; + asmjs) + basic_machine=asmjs-unknown + ;; + aux) + basic_machine=m68k-apple + os=-aux + ;; + balance) + basic_machine=ns32k-sequent + os=-dynix + ;; + blackfin) + basic_machine=bfin-unknown + os=-linux + ;; + blackfin-*) + basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'` + os=-linux + ;; + bluegene*) + basic_machine=powerpc-ibm + os=-cnk + ;; + c54x-*) + basic_machine=tic54x-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + c55x-*) + basic_machine=tic55x-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + c6x-*) + basic_machine=tic6x-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + c90) + basic_machine=c90-cray + os=-unicos + ;; + cegcc) + basic_machine=arm-unknown + os=-cegcc + ;; + convex-c1) + basic_machine=c1-convex + os=-bsd + ;; + convex-c2) + basic_machine=c2-convex + os=-bsd + ;; + convex-c32) + basic_machine=c32-convex + os=-bsd + ;; + convex-c34) + basic_machine=c34-convex + os=-bsd + ;; + convex-c38) + basic_machine=c38-convex + os=-bsd + ;; + cray | j90) + basic_machine=j90-cray + os=-unicos + ;; + craynv) + basic_machine=craynv-cray + os=-unicosmp + ;; + cr16 | cr16-*) + basic_machine=cr16-unknown + os=-elf + ;; + crds | unos) + basic_machine=m68k-crds + ;; + crisv32 | crisv32-* | etraxfs*) + basic_machine=crisv32-axis + ;; + cris | cris-* | etrax*) + basic_machine=cris-axis + ;; + crx) + basic_machine=crx-unknown + os=-elf + ;; + da30 | da30-*) + basic_machine=m68k-da30 + ;; + decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn) + basic_machine=mips-dec + ;; + decsystem10* | dec10*) + basic_machine=pdp10-dec + os=-tops10 + ;; + decsystem20* | dec20*) + basic_machine=pdp10-dec + os=-tops20 + ;; + delta | 3300 | motorola-3300 | motorola-delta \ + | 3300-motorola | delta-motorola) + basic_machine=m68k-motorola + ;; + delta88) + basic_machine=m88k-motorola + os=-sysv3 + ;; + dicos) + basic_machine=i686-pc + os=-dicos + ;; + djgpp) + basic_machine=i586-pc + os=-msdosdjgpp + ;; + dpx20 | dpx20-*) + basic_machine=rs6000-bull + os=-bosx + ;; + dpx2* | dpx2*-bull) + basic_machine=m68k-bull + os=-sysv3 + ;; + ebmon29k) + basic_machine=a29k-amd + os=-ebmon + ;; + elxsi) + basic_machine=elxsi-elxsi + os=-bsd + ;; + encore | umax | mmax) + basic_machine=ns32k-encore + ;; + es1800 | OSE68k | ose68k | ose | OSE) + basic_machine=m68k-ericsson + os=-ose + ;; + fx2800) + basic_machine=i860-alliant + ;; + genix) + basic_machine=ns32k-ns + ;; + gmicro) + basic_machine=tron-gmicro + os=-sysv + ;; + go32) + basic_machine=i386-pc + os=-go32 + ;; + h3050r* | hiux*) + basic_machine=hppa1.1-hitachi + os=-hiuxwe2 + ;; + h8300hms) + basic_machine=h8300-hitachi + os=-hms + ;; + h8300xray) + basic_machine=h8300-hitachi + os=-xray + ;; + h8500hms) + basic_machine=h8500-hitachi + os=-hms + ;; + harris) + basic_machine=m88k-harris + os=-sysv3 + ;; + hp300-*) + basic_machine=m68k-hp + ;; + hp300bsd) + basic_machine=m68k-hp + os=-bsd + ;; + hp300hpux) + basic_machine=m68k-hp + os=-hpux + ;; + hp3k9[0-9][0-9] | hp9[0-9][0-9]) + basic_machine=hppa1.0-hp + ;; + hp9k2[0-9][0-9] | hp9k31[0-9]) + basic_machine=m68000-hp + ;; + hp9k3[2-9][0-9]) + basic_machine=m68k-hp + ;; + hp9k6[0-9][0-9] | hp6[0-9][0-9]) + basic_machine=hppa1.0-hp + ;; + hp9k7[0-79][0-9] | hp7[0-79][0-9]) + basic_machine=hppa1.1-hp + ;; + hp9k78[0-9] | hp78[0-9]) + # FIXME: really hppa2.0-hp + basic_machine=hppa1.1-hp + ;; + hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893) + # FIXME: really hppa2.0-hp + basic_machine=hppa1.1-hp + ;; + hp9k8[0-9][13679] | hp8[0-9][13679]) + basic_machine=hppa1.1-hp + ;; + hp9k8[0-9][0-9] | hp8[0-9][0-9]) + basic_machine=hppa1.0-hp + ;; + hppa-next) + os=-nextstep3 + ;; + hppaosf) + basic_machine=hppa1.1-hp + os=-osf + ;; + hppro) + basic_machine=hppa1.1-hp + os=-proelf + ;; + i370-ibm* | ibm*) + basic_machine=i370-ibm + ;; + i*86v32) + basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` + os=-sysv32 + ;; + i*86v4*) + basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` + os=-sysv4 + ;; + i*86v) + basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` + os=-sysv + ;; + i*86sol2) + basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` + os=-solaris2 + ;; + i386mach) + basic_machine=i386-mach + os=-mach + ;; + i386-vsta | vsta) + basic_machine=i386-unknown + os=-vsta + ;; + iris | iris4d) + basic_machine=mips-sgi + case $os in + -irix*) + ;; + *) + os=-irix4 + ;; + esac + ;; + isi68 | isi) + basic_machine=m68k-isi + os=-sysv + ;; + leon-*|leon[3-9]-*) + basic_machine=sparc-`echo $basic_machine | sed 's/-.*//'` + ;; + m68knommu) + basic_machine=m68k-unknown + os=-linux + ;; + m68knommu-*) + basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'` + os=-linux + ;; + m88k-omron*) + basic_machine=m88k-omron + ;; + magnum | m3230) + basic_machine=mips-mips + os=-sysv + ;; + merlin) + basic_machine=ns32k-utek + os=-sysv + ;; + microblaze*) + basic_machine=microblaze-xilinx + ;; + mingw64) + basic_machine=x86_64-pc + os=-mingw64 + ;; + mingw32) + basic_machine=i686-pc + os=-mingw32 + ;; + mingw32ce) + basic_machine=arm-unknown + os=-mingw32ce + ;; + miniframe) + basic_machine=m68000-convergent + ;; + *mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*) + basic_machine=m68k-atari + os=-mint + ;; + mips3*-*) + basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'` + ;; + mips3*) + basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown + ;; + monitor) + basic_machine=m68k-rom68k + os=-coff + ;; + morphos) + basic_machine=powerpc-unknown + os=-morphos + ;; + moxiebox) + basic_machine=moxie-unknown + os=-moxiebox + ;; + msdos) + basic_machine=i386-pc + os=-msdos + ;; + ms1-*) + basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'` + ;; + msys) + basic_machine=i686-pc + os=-msys + ;; + mvs) + basic_machine=i370-ibm + os=-mvs + ;; + nacl) + basic_machine=le32-unknown + os=-nacl + ;; + ncr3000) + basic_machine=i486-ncr + os=-sysv4 + ;; + netbsd386) + basic_machine=i386-unknown + os=-netbsd + ;; + netwinder) + basic_machine=armv4l-rebel + os=-linux + ;; + news | news700 | news800 | news900) + basic_machine=m68k-sony + os=-newsos + ;; + news1000) + basic_machine=m68030-sony + os=-newsos + ;; + news-3600 | risc-news) + basic_machine=mips-sony + os=-newsos + ;; + necv70) + basic_machine=v70-nec + os=-sysv + ;; + next | m*-next ) + basic_machine=m68k-next + case $os in + -nextstep* ) + ;; + -ns2*) + os=-nextstep2 + ;; + *) + os=-nextstep3 + ;; + esac + ;; + nh3000) + basic_machine=m68k-harris + os=-cxux + ;; + nh[45]000) + basic_machine=m88k-harris + os=-cxux + ;; + nindy960) + basic_machine=i960-intel + os=-nindy + ;; + mon960) + basic_machine=i960-intel + os=-mon960 + ;; + nonstopux) + basic_machine=mips-compaq + os=-nonstopux + ;; + np1) + basic_machine=np1-gould + ;; + neo-tandem) + basic_machine=neo-tandem + ;; + nse-tandem) + basic_machine=nse-tandem + ;; + nsr-tandem) + basic_machine=nsr-tandem + ;; + op50n-* | op60c-*) + basic_machine=hppa1.1-oki + os=-proelf + ;; + openrisc | openrisc-*) + basic_machine=or32-unknown + ;; + os400) + basic_machine=powerpc-ibm + os=-os400 + ;; + OSE68000 | ose68000) + basic_machine=m68000-ericsson + os=-ose + ;; + os68k) + basic_machine=m68k-none + os=-os68k + ;; + pa-hitachi) + basic_machine=hppa1.1-hitachi + os=-hiuxwe2 + ;; + paragon) + basic_machine=i860-intel + os=-osf + ;; + parisc) + basic_machine=hppa-unknown + os=-linux + ;; + parisc-*) + basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'` + os=-linux + ;; + pbd) + basic_machine=sparc-tti + ;; + pbb) + basic_machine=m68k-tti + ;; + pc532 | pc532-*) + basic_machine=ns32k-pc532 + ;; + pc98) + basic_machine=i386-pc + ;; + pc98-*) + basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + pentium | p5 | k5 | k6 | nexgen | viac3) + basic_machine=i586-pc + ;; + pentiumpro | p6 | 6x86 | athlon | athlon_*) + basic_machine=i686-pc + ;; + pentiumii | pentium2 | pentiumiii | pentium3) + basic_machine=i686-pc + ;; + pentium4) + basic_machine=i786-pc + ;; + pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*) + basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + pentiumpro-* | p6-* | 6x86-* | athlon-*) + basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*) + basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + pentium4-*) + basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + pn) + basic_machine=pn-gould + ;; + power) basic_machine=power-ibm + ;; + ppc | ppcbe) basic_machine=powerpc-unknown + ;; + ppc-* | ppcbe-*) + basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + ppcle | powerpclittle | ppc-le | powerpc-little) + basic_machine=powerpcle-unknown + ;; + ppcle-* | powerpclittle-*) + basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + ppc64) basic_machine=powerpc64-unknown + ;; + ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + ppc64le | powerpc64little | ppc64-le | powerpc64-little) + basic_machine=powerpc64le-unknown + ;; + ppc64le-* | powerpc64little-*) + basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + ps2) + basic_machine=i386-ibm + ;; + pw32) + basic_machine=i586-unknown + os=-pw32 + ;; + rdos | rdos64) + basic_machine=x86_64-pc + os=-rdos + ;; + rdos32) + basic_machine=i386-pc + os=-rdos + ;; + rom68k) + basic_machine=m68k-rom68k + os=-coff + ;; + rm[46]00) + basic_machine=mips-siemens + ;; + rtpc | rtpc-*) + basic_machine=romp-ibm + ;; + s390 | s390-*) + basic_machine=s390-ibm + ;; + s390x | s390x-*) + basic_machine=s390x-ibm + ;; + sa29200) + basic_machine=a29k-amd + os=-udi + ;; + sb1) + basic_machine=mipsisa64sb1-unknown + ;; + sb1el) + basic_machine=mipsisa64sb1el-unknown + ;; + sde) + basic_machine=mipsisa32-sde + os=-elf + ;; + sei) + basic_machine=mips-sei + os=-seiux + ;; + sequent) + basic_machine=i386-sequent + ;; + sh) + basic_machine=sh-hitachi + os=-hms + ;; + sh5el) + basic_machine=sh5le-unknown + ;; + sh64) + basic_machine=sh64-unknown + ;; + sparclite-wrs | simso-wrs) + basic_machine=sparclite-wrs + os=-vxworks + ;; + sps7) + basic_machine=m68k-bull + os=-sysv2 + ;; + spur) + basic_machine=spur-unknown + ;; + st2000) + basic_machine=m68k-tandem + ;; + stratus) + basic_machine=i860-stratus + os=-sysv4 + ;; + strongarm-* | thumb-*) + basic_machine=arm-`echo $basic_machine | sed 's/^[^-]*-//'` + ;; + sun2) + basic_machine=m68000-sun + ;; + sun2os3) + basic_machine=m68000-sun + os=-sunos3 + ;; + sun2os4) + basic_machine=m68000-sun + os=-sunos4 + ;; + sun3os3) + basic_machine=m68k-sun + os=-sunos3 + ;; + sun3os4) + basic_machine=m68k-sun + os=-sunos4 + ;; + sun4os3) + basic_machine=sparc-sun + os=-sunos3 + ;; + sun4os4) + basic_machine=sparc-sun + os=-sunos4 + ;; + sun4sol2) + basic_machine=sparc-sun + os=-solaris2 + ;; + sun3 | sun3-*) + basic_machine=m68k-sun + ;; + sun4) + basic_machine=sparc-sun + ;; + sun386 | sun386i | roadrunner) + basic_machine=i386-sun + ;; + sv1) + basic_machine=sv1-cray + os=-unicos + ;; + symmetry) + basic_machine=i386-sequent + os=-dynix + ;; + t3e) + basic_machine=alphaev5-cray + os=-unicos + ;; + t90) + basic_machine=t90-cray + os=-unicos + ;; + tile*) + basic_machine=$basic_machine-unknown + os=-linux-gnu + ;; + tx39) + basic_machine=mipstx39-unknown + ;; + tx39el) + basic_machine=mipstx39el-unknown + ;; + toad1) + basic_machine=pdp10-xkl + os=-tops20 + ;; + tower | tower-32) + basic_machine=m68k-ncr + ;; + tpf) + basic_machine=s390x-ibm + os=-tpf + ;; + udi29k) + basic_machine=a29k-amd + os=-udi + ;; + ultra3) + basic_machine=a29k-nyu + os=-sym1 + ;; + v810 | necv810) + basic_machine=v810-nec + os=-none + ;; + vaxv) + basic_machine=vax-dec + os=-sysv + ;; + vms) + basic_machine=vax-dec + os=-vms + ;; + vpp*|vx|vx-*) + basic_machine=f301-fujitsu + ;; + vxworks960) + basic_machine=i960-wrs + os=-vxworks + ;; + vxworks68) + basic_machine=m68k-wrs + os=-vxworks + ;; + vxworks29k) + basic_machine=a29k-wrs + os=-vxworks + ;; + w65*) + basic_machine=w65-wdc + os=-none + ;; + w89k-*) + basic_machine=hppa1.1-winbond + os=-proelf + ;; + xbox) + basic_machine=i686-pc + os=-mingw32 + ;; + xps | xps100) + basic_machine=xps100-honeywell + ;; + xscale-* | xscalee[bl]-*) + basic_machine=`echo $basic_machine | sed 's/^xscale/arm/'` + ;; + ymp) + basic_machine=ymp-cray + os=-unicos + ;; + z8k-*-coff) + basic_machine=z8k-unknown + os=-sim + ;; + z80-*-coff) + basic_machine=z80-unknown + os=-sim + ;; + none) + basic_machine=none-none + os=-none + ;; + +# Here we handle the default manufacturer of certain CPU types. It is in +# some cases the only manufacturer, in others, it is the most popular. + w89k) + basic_machine=hppa1.1-winbond + ;; + op50n) + basic_machine=hppa1.1-oki + ;; + op60c) + basic_machine=hppa1.1-oki + ;; + romp) + basic_machine=romp-ibm + ;; + mmix) + basic_machine=mmix-knuth + ;; + rs6000) + basic_machine=rs6000-ibm + ;; + vax) + basic_machine=vax-dec + ;; + pdp10) + # there are many clones, so DEC is not a safe bet + basic_machine=pdp10-unknown + ;; + pdp11) + basic_machine=pdp11-dec + ;; + we32k) + basic_machine=we32k-att + ;; + sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele) + basic_machine=sh-unknown + ;; + sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v) + basic_machine=sparc-sun + ;; + cydra) + basic_machine=cydra-cydrome + ;; + orion) + basic_machine=orion-highlevel + ;; + orion105) + basic_machine=clipper-highlevel + ;; + mac | mpw | mac-mpw) + basic_machine=m68k-apple + ;; + pmac | pmac-mpw) + basic_machine=powerpc-apple + ;; + *-unknown) + # Make sure to match an already-canonicalized machine name. + ;; + *) + echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 + exit 1 + ;; +esac + +# Here we canonicalize certain aliases for manufacturers. +case $basic_machine in + *-digital*) + basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'` + ;; + *-commodore*) + basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'` + ;; + *) + ;; +esac + +# Decode manufacturer-specific aliases for certain operating systems. + +if [ x"$os" != x"" ] +then +case $os in + # First match some system type aliases + # that might get confused with valid system types. + # -solaris* is a basic system type, with this one exception. + -auroraux) + os=-auroraux + ;; + -solaris1 | -solaris1.*) + os=`echo $os | sed -e 's|solaris1|sunos4|'` + ;; + -solaris) + os=-solaris2 + ;; + -svr4*) + os=-sysv4 + ;; + -unixware*) + os=-sysv4.2uw + ;; + -gnu/linux*) + os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'` + ;; + # First accept the basic system types. + # The portable systems comes first. + # Each alternative MUST END IN A *, to match a version number. + # -sysv* is not here because it comes later, after sysvr4. + -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ + | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\ + | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \ + | -sym* | -kopensolaris* | -plan9* \ + | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \ + | -aos* | -aros* | -cloudabi* | -sortix* \ + | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ + | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ + | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \ + | -bitrig* | -openbsd* | -solidbsd* \ + | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ + | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ + | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ + | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ + | -chorusos* | -chorusrdb* | -cegcc* \ + | -cygwin* | -msys* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ + | -mingw32* | -mingw64* | -linux-gnu* | -linux-android* \ + | -linux-newlib* | -linux-musl* | -linux-uclibc* \ + | -uxpv* | -beos* | -mpeix* | -udk* | -moxiebox* \ + | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ + | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ + | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ + | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ + | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ + | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \ + | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es* | -tirtos*) + # Remember, each alternative MUST END IN *, to match a version number. + ;; + -qnx*) + case $basic_machine in + x86-* | i*86-*) + ;; + *) + os=-nto$os + ;; + esac + ;; + -nto-qnx*) + ;; + -nto*) + os=`echo $os | sed -e 's|nto|nto-qnx|'` + ;; + -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \ + | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \ + | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*) + ;; + -mac*) + os=`echo $os | sed -e 's|mac|macos|'` + ;; + -linux-dietlibc) + os=-linux-dietlibc + ;; + -linux*) + os=`echo $os | sed -e 's|linux|linux-gnu|'` + ;; + -sunos5*) + os=`echo $os | sed -e 's|sunos5|solaris2|'` + ;; + -sunos6*) + os=`echo $os | sed -e 's|sunos6|solaris3|'` + ;; + -opened*) + os=-openedition + ;; + -os400*) + os=-os400 + ;; + -wince*) + os=-wince + ;; + -osfrose*) + os=-osfrose + ;; + -osf*) + os=-osf + ;; + -utek*) + os=-bsd + ;; + -dynix*) + os=-bsd + ;; + -acis*) + os=-aos + ;; + -atheos*) + os=-atheos + ;; + -syllable*) + os=-syllable + ;; + -386bsd) + os=-bsd + ;; + -ctix* | -uts*) + os=-sysv + ;; + -nova*) + os=-rtmk-nova + ;; + -ns2 ) + os=-nextstep2 + ;; + -nsk*) + os=-nsk + ;; + # Preserve the version number of sinix5. + -sinix5.*) + os=`echo $os | sed -e 's|sinix|sysv|'` + ;; + -sinix*) + os=-sysv4 + ;; + -tpf*) + os=-tpf + ;; + -triton*) + os=-sysv3 + ;; + -oss*) + os=-sysv3 + ;; + -svr4) + os=-sysv4 + ;; + -svr3) + os=-sysv3 + ;; + -sysvr4) + os=-sysv4 + ;; + # This must come after -sysvr4. + -sysv*) + ;; + -ose*) + os=-ose + ;; + -es1800*) + os=-ose + ;; + -xenix) + os=-xenix + ;; + -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) + os=-mint + ;; + -aros*) + os=-aros + ;; + -zvmoe) + os=-zvmoe + ;; + -dicos*) + os=-dicos + ;; + -nacl*) + ;; + -none) + ;; + *) + # Get rid of the `-' at the beginning of $os. + os=`echo $os | sed 's/[^-]*-//'` + echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2 + exit 1 + ;; +esac +else + +# Here we handle the default operating systems that come with various machines. +# The value should be what the vendor currently ships out the door with their +# machine or put another way, the most popular os provided with the machine. + +# Note that if you're going to try to match "-MANUFACTURER" here (say, +# "-sun"), then you have to tell the case statement up towards the top +# that MANUFACTURER isn't an operating system. Otherwise, code above +# will signal an error saying that MANUFACTURER isn't an operating +# system, and we'll never get to this point. + +case $basic_machine in + score-*) + os=-elf + ;; + spu-*) + os=-elf + ;; + *-acorn) + os=-riscix1.2 + ;; + arm*-rebel) + os=-linux + ;; + arm*-semi) + os=-aout + ;; + c4x-* | tic4x-*) + os=-coff + ;; + c8051-*) + os=-elf + ;; + hexagon-*) + os=-elf + ;; + tic54x-*) + os=-coff + ;; + tic55x-*) + os=-coff + ;; + tic6x-*) + os=-coff + ;; + # This must come before the *-dec entry. + pdp10-*) + os=-tops20 + ;; + pdp11-*) + os=-none + ;; + *-dec | vax-*) + os=-ultrix4.2 + ;; + m68*-apollo) + os=-domain + ;; + i386-sun) + os=-sunos4.0.2 + ;; + m68000-sun) + os=-sunos3 + ;; + m68*-cisco) + os=-aout + ;; + mep-*) + os=-elf + ;; + mips*-cisco) + os=-elf + ;; + mips*-*) + os=-elf + ;; + or32-*) + os=-coff + ;; + *-tti) # must be before sparc entry or we get the wrong os. + os=-sysv3 + ;; + sparc-* | *-sun) + os=-sunos4.1.1 + ;; + *-be) + os=-beos + ;; + *-haiku) + os=-haiku + ;; + *-ibm) + os=-aix + ;; + *-knuth) + os=-mmixware + ;; + *-wec) + os=-proelf + ;; + *-winbond) + os=-proelf + ;; + *-oki) + os=-proelf + ;; + *-hp) + os=-hpux + ;; + *-hitachi) + os=-hiux + ;; + i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent) + os=-sysv + ;; + *-cbm) + os=-amigaos + ;; + *-dg) + os=-dgux + ;; + *-dolphin) + os=-sysv3 + ;; + m68k-ccur) + os=-rtu + ;; + m88k-omron*) + os=-luna + ;; + *-next ) + os=-nextstep + ;; + *-sequent) + os=-ptx + ;; + *-crds) + os=-unos + ;; + *-ns) + os=-genix + ;; + i370-*) + os=-mvs + ;; + *-next) + os=-nextstep3 + ;; + *-gould) + os=-sysv + ;; + *-highlevel) + os=-bsd + ;; + *-encore) + os=-bsd + ;; + *-sgi) + os=-irix + ;; + *-siemens) + os=-sysv4 + ;; + *-masscomp) + os=-rtu + ;; + f30[01]-fujitsu | f700-fujitsu) + os=-uxpv + ;; + *-rom68k) + os=-coff + ;; + *-*bug) + os=-coff + ;; + *-apple) + os=-macos + ;; + *-atari*) + os=-mint + ;; + *) + os=-none + ;; +esac +fi + +# Here we handle the case where we know the os, and the CPU type, but not the +# manufacturer. We pick the logical manufacturer. +vendor=unknown +case $basic_machine in + *-unknown) + case $os in + -riscix*) + vendor=acorn + ;; + -sunos*) + vendor=sun + ;; + -cnk*|-aix*) + vendor=ibm + ;; + -beos*) + vendor=be + ;; + -hpux*) + vendor=hp + ;; + -mpeix*) + vendor=hp + ;; + -hiux*) + vendor=hitachi + ;; + -unos*) + vendor=crds + ;; + -dgux*) + vendor=dg + ;; + -luna*) + vendor=omron + ;; + -genix*) + vendor=ns + ;; + -mvs* | -opened*) + vendor=ibm + ;; + -os400*) + vendor=ibm + ;; + -ptx*) + vendor=sequent + ;; + -tpf*) + vendor=ibm + ;; + -vxsim* | -vxworks* | -windiss*) + vendor=wrs + ;; + -aux*) + vendor=apple + ;; + -hms*) + vendor=hitachi + ;; + -mpw* | -macos*) + vendor=apple + ;; + -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) + vendor=atari + ;; + -vos*) + vendor=stratus + ;; + esac + basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"` + ;; +esac + +echo $basic_machine$os +exit + +# Local variables: +# eval: (add-hook 'write-file-hooks 'time-stamp) +# time-stamp-start: "timestamp='" +# time-stamp-format: "%:y-%02m-%02d" +# time-stamp-end: "'" +# End: diff --git a/libs/ode-0.16.1/configure b/libs/ode-0.16.1/configure new file mode 100755 index 0000000..03ea74f --- /dev/null +++ b/libs/ode-0.16.1/configure @@ -0,0 +1,21593 @@ +#! /bin/sh +# Guess values for system-dependent variables and create Makefiles. +# Generated by GNU Autoconf 2.69 for ODE 0.16.1. +# +# Report bugs to . +# +# +# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. +# +# +# This configure script is free software; the Free Software Foundation +# gives unlimited permission to copy, distribute and modify it. +## -------------------- ## +## M4sh Initialization. ## +## -------------------- ## + +# Be more Bourne compatible +DUALCASE=1; export DUALCASE # for MKS sh +if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : + emulate sh + NULLCMD=: + # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which + # is contrary to our usage. Disable this feature. + alias -g '${1+"$@"}'='"$@"' + setopt NO_GLOB_SUBST +else + case `(set -o) 2>/dev/null` in #( + *posix*) : + set -o posix ;; #( + *) : + ;; +esac +fi + + +as_nl=' +' +export as_nl +# Printing a long string crashes Solaris 7 /usr/bin/printf. +as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo +# Prefer a ksh shell builtin over an external printf program on Solaris, +# but without wasting forks for bash or zsh. +if test -z "$BASH_VERSION$ZSH_VERSION" \ + && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='print -r --' + as_echo_n='print -rn --' +elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='printf %s\n' + as_echo_n='printf %s' +else + if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then + as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' + as_echo_n='/usr/ucb/echo -n' + else + as_echo_body='eval expr "X$1" : "X\\(.*\\)"' + as_echo_n_body='eval + arg=$1; + case $arg in #( + *"$as_nl"*) + expr "X$arg" : "X\\(.*\\)$as_nl"; + arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; + esac; + expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" + ' + export as_echo_n_body + as_echo_n='sh -c $as_echo_n_body as_echo' + fi + export as_echo_body + as_echo='sh -c $as_echo_body as_echo' +fi + +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + PATH_SEPARATOR=: + (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { + (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || + PATH_SEPARATOR=';' + } +fi + + +# IFS +# We need space, tab and new line, in precisely that order. Quoting is +# there to prevent editors from complaining about space-tab. +# (If _AS_PATH_WALK were called with IFS unset, it would disable word +# splitting by setting IFS to empty value.) +IFS=" "" $as_nl" + +# Find who we are. Look in the path if we contain no directory separator. +as_myself= +case $0 in #(( + *[\\/]* ) as_myself=$0 ;; + *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break + done +IFS=$as_save_IFS + + ;; +esac +# We did not find ourselves, most probably we were run as `sh COMMAND' +# in which case we are not to be found in the path. +if test "x$as_myself" = x; then + as_myself=$0 +fi +if test ! -f "$as_myself"; then + $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 + exit 1 +fi + +# Unset variables that we do not need and which cause bugs (e.g. in +# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" +# suppresses any "Segmentation fault" message there. '((' could +# trigger a bug in pdksh 5.2.14. +for as_var in BASH_ENV ENV MAIL MAILPATH +do eval test x\${$as_var+set} = xset \ + && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : +done +PS1='$ ' +PS2='> ' +PS4='+ ' + +# NLS nuisances. +LC_ALL=C +export LC_ALL +LANGUAGE=C +export LANGUAGE + +# CDPATH. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + +# Use a proper internal environment variable to ensure we don't fall + # into an infinite loop, continuously re-executing ourselves. + if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then + _as_can_reexec=no; export _as_can_reexec; + # We cannot yet assume a decent shell, so we have to provide a +# neutralization value for shells without unset; and this also +# works around shells that cannot unset nonexistent variables. +# Preserve -v and -x to the replacement shell. +BASH_ENV=/dev/null +ENV=/dev/null +(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV +case $- in # (((( + *v*x* | *x*v* ) as_opts=-vx ;; + *v* ) as_opts=-v ;; + *x* ) as_opts=-x ;; + * ) as_opts= ;; +esac +exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} +# Admittedly, this is quite paranoid, since all the known shells bail +# out after a failed `exec'. +$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 +as_fn_exit 255 + fi + # We don't want this to propagate to other subprocesses. + { _as_can_reexec=; unset _as_can_reexec;} +if test "x$CONFIG_SHELL" = x; then + as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : + emulate sh + NULLCMD=: + # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which + # is contrary to our usage. Disable this feature. + alias -g '\${1+\"\$@\"}'='\"\$@\"' + setopt NO_GLOB_SUBST +else + case \`(set -o) 2>/dev/null\` in #( + *posix*) : + set -o posix ;; #( + *) : + ;; +esac +fi +" + as_required="as_fn_return () { (exit \$1); } +as_fn_success () { as_fn_return 0; } +as_fn_failure () { as_fn_return 1; } +as_fn_ret_success () { return 0; } +as_fn_ret_failure () { return 1; } + +exitcode=0 +as_fn_success || { exitcode=1; echo as_fn_success failed.; } +as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } +as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } +as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } +if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : + +else + exitcode=1; echo positional parameters were not saved. +fi +test x\$exitcode = x0 || exit 1 +test -x / || exit 1" + as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO + as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO + eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && + test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 + + test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || ( + ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' + ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO + ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO + PATH=/empty FPATH=/empty; export PATH FPATH + test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\ + || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1 +test \$(( 1 + 1 )) = 2 || exit 1" + if (eval "$as_required") 2>/dev/null; then : + as_have_required=yes +else + as_have_required=no +fi + if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : + +else + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +as_found=false +for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + as_found=: + case $as_dir in #( + /*) + for as_base in sh bash ksh sh5; do + # Try only shells that exist, to save several forks. + as_shell=$as_dir/$as_base + if { test -f "$as_shell" || test -f "$as_shell.exe"; } && + { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : + CONFIG_SHELL=$as_shell as_have_required=yes + if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : + break 2 +fi +fi + done;; + esac + as_found=false +done +$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && + { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : + CONFIG_SHELL=$SHELL as_have_required=yes +fi; } +IFS=$as_save_IFS + + + if test "x$CONFIG_SHELL" != x; then : + export CONFIG_SHELL + # We cannot yet assume a decent shell, so we have to provide a +# neutralization value for shells without unset; and this also +# works around shells that cannot unset nonexistent variables. +# Preserve -v and -x to the replacement shell. +BASH_ENV=/dev/null +ENV=/dev/null +(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV +case $- in # (((( + *v*x* | *x*v* ) as_opts=-vx ;; + *v* ) as_opts=-v ;; + *x* ) as_opts=-x ;; + * ) as_opts= ;; +esac +exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} +# Admittedly, this is quite paranoid, since all the known shells bail +# out after a failed `exec'. +$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 +exit 255 +fi + + if test x$as_have_required = xno; then : + $as_echo "$0: This script requires a shell more modern than all" + $as_echo "$0: the shells that I found on your system." + if test x${ZSH_VERSION+set} = xset ; then + $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" + $as_echo "$0: be upgraded to zsh 4.3.4 or later." + else + $as_echo "$0: Please tell bug-autoconf@gnu.org and ode@ode.org about +$0: your system, including any error possibly output before +$0: this message. Then install a modern shell, or manually +$0: run the script under such a shell if you do have one." + fi + exit 1 +fi +fi +fi +SHELL=${CONFIG_SHELL-/bin/sh} +export SHELL +# Unset more variables known to interfere with behavior of common tools. +CLICOLOR_FORCE= GREP_OPTIONS= +unset CLICOLOR_FORCE GREP_OPTIONS + +## --------------------- ## +## M4sh Shell Functions. ## +## --------------------- ## +# as_fn_unset VAR +# --------------- +# Portably unset VAR. +as_fn_unset () +{ + { eval $1=; unset $1;} +} +as_unset=as_fn_unset + +# as_fn_set_status STATUS +# ----------------------- +# Set $? to STATUS, without forking. +as_fn_set_status () +{ + return $1 +} # as_fn_set_status + +# as_fn_exit STATUS +# ----------------- +# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. +as_fn_exit () +{ + set +e + as_fn_set_status $1 + exit $1 +} # as_fn_exit + +# as_fn_mkdir_p +# ------------- +# Create "$as_dir" as a directory, including parents if necessary. +as_fn_mkdir_p () +{ + + case $as_dir in #( + -*) as_dir=./$as_dir;; + esac + test -d "$as_dir" || eval $as_mkdir_p || { + as_dirs= + while :; do + case $as_dir in #( + *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( + *) as_qdir=$as_dir;; + esac + as_dirs="'$as_qdir' $as_dirs" + as_dir=`$as_dirname -- "$as_dir" || +$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$as_dir" : 'X\(//\)[^/]' \| \ + X"$as_dir" : 'X\(//\)$' \| \ + X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$as_dir" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + test -d "$as_dir" && break + done + test -z "$as_dirs" || eval "mkdir $as_dirs" + } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" + + +} # as_fn_mkdir_p + +# as_fn_executable_p FILE +# ----------------------- +# Test if FILE is an executable regular file. +as_fn_executable_p () +{ + test -f "$1" && test -x "$1" +} # as_fn_executable_p +# as_fn_append VAR VALUE +# ---------------------- +# Append the text in VALUE to the end of the definition contained in VAR. Take +# advantage of any shell optimizations that allow amortized linear growth over +# repeated appends, instead of the typical quadratic growth present in naive +# implementations. +if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : + eval 'as_fn_append () + { + eval $1+=\$2 + }' +else + as_fn_append () + { + eval $1=\$$1\$2 + } +fi # as_fn_append + +# as_fn_arith ARG... +# ------------------ +# Perform arithmetic evaluation on the ARGs, and store the result in the +# global $as_val. Take advantage of shells that can avoid forks. The arguments +# must be portable across $(()) and expr. +if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : + eval 'as_fn_arith () + { + as_val=$(( $* )) + }' +else + as_fn_arith () + { + as_val=`expr "$@" || test $? -eq 1` + } +fi # as_fn_arith + + +# as_fn_error STATUS ERROR [LINENO LOG_FD] +# ---------------------------------------- +# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are +# provided, also output the error to LOG_FD, referencing LINENO. Then exit the +# script with STATUS, using 1 if that was 0. +as_fn_error () +{ + as_status=$1; test $as_status -eq 0 && as_status=1 + if test "$4"; then + as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 + fi + $as_echo "$as_me: error: $2" >&2 + as_fn_exit $as_status +} # as_fn_error + +if expr a : '\(a\)' >/dev/null 2>&1 && + test "X`expr 00001 : '.*\(...\)'`" = X001; then + as_expr=expr +else + as_expr=false +fi + +if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then + as_basename=basename +else + as_basename=false +fi + +if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then + as_dirname=dirname +else + as_dirname=false +fi + +as_me=`$as_basename -- "$0" || +$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ + X"$0" : 'X\(//\)$' \| \ + X"$0" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X/"$0" | + sed '/^.*\/\([^/][^/]*\)\/*$/{ + s//\1/ + q + } + /^X\/\(\/\/\)$/{ + s//\1/ + q + } + /^X\/\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + +# Avoid depending upon Character Ranges. +as_cr_letters='abcdefghijklmnopqrstuvwxyz' +as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' +as_cr_Letters=$as_cr_letters$as_cr_LETTERS +as_cr_digits='0123456789' +as_cr_alnum=$as_cr_Letters$as_cr_digits + + + as_lineno_1=$LINENO as_lineno_1a=$LINENO + as_lineno_2=$LINENO as_lineno_2a=$LINENO + eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && + test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { + # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) + sed -n ' + p + /[$]LINENO/= + ' <$as_myself | + sed ' + s/[$]LINENO.*/&-/ + t lineno + b + :lineno + N + :loop + s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ + t loop + s/-\n.*// + ' >$as_me.lineno && + chmod +x "$as_me.lineno" || + { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } + + # If we had to re-execute with $CONFIG_SHELL, we're ensured to have + # already done that, so ensure we don't try to do so again and fall + # in an infinite loop. This has already happened in practice. + _as_can_reexec=no; export _as_can_reexec + # Don't try to exec as it changes $[0], causing all sort of problems + # (the dirname of $[0] is not the place where we might find the + # original and so on. Autoconf is especially sensitive to this). + . "./$as_me.lineno" + # Exit status is that of the last command. + exit +} + +ECHO_C= ECHO_N= ECHO_T= +case `echo -n x` in #((((( +-n*) + case `echo 'xy\c'` in + *c*) ECHO_T=' ';; # ECHO_T is single tab character. + xy) ECHO_C='\c';; + *) echo `echo ksh88 bug on AIX 6.1` > /dev/null + ECHO_T=' ';; + esac;; +*) + ECHO_N='-n';; +esac + +rm -f conf$$ conf$$.exe conf$$.file +if test -d conf$$.dir; then + rm -f conf$$.dir/conf$$.file +else + rm -f conf$$.dir + mkdir conf$$.dir 2>/dev/null +fi +if (echo >conf$$.file) 2>/dev/null; then + if ln -s conf$$.file conf$$ 2>/dev/null; then + as_ln_s='ln -s' + # ... but there are two gotchas: + # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. + # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. + # In both cases, we have to default to `cp -pR'. + ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || + as_ln_s='cp -pR' + elif ln conf$$.file conf$$ 2>/dev/null; then + as_ln_s=ln + else + as_ln_s='cp -pR' + fi +else + as_ln_s='cp -pR' +fi +rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file +rmdir conf$$.dir 2>/dev/null + +if mkdir -p . 2>/dev/null; then + as_mkdir_p='mkdir -p "$as_dir"' +else + test -d ./-p && rmdir ./-p + as_mkdir_p=false +fi + +as_test_x='test -x' +as_executable_p=as_fn_executable_p + +# Sed expression to map a string onto a valid CPP name. +as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" + +# Sed expression to map a string onto a valid variable name. +as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" + +SHELL=${CONFIG_SHELL-/bin/sh} + + +test -n "$DJDIR" || exec 7<&0 &1 + +# Name of the host. +# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, +# so uname gets run too. +ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` + +# +# Initializations. +# +ac_default_prefix=/usr/local +ac_clean_files= +ac_config_libobj_dir=. +LIBOBJS= +cross_compiling=no +subdirs= +MFLAGS= +MAKEFLAGS= + +# Identity of this package. +PACKAGE_NAME='ODE' +PACKAGE_TARNAME='ode' +PACKAGE_VERSION='0.16.1' +PACKAGE_STRING='ODE 0.16.1' +PACKAGE_BUGREPORT='ode@ode.org' +PACKAGE_URL='' + +ac_unique_file="ode/src/ode.cpp" +# Factoring default headers for most tests. +ac_includes_default="\ +#include +#ifdef HAVE_SYS_TYPES_H +# include +#endif +#ifdef HAVE_SYS_STAT_H +# include +#endif +#ifdef STDC_HEADERS +# include +# include +#else +# ifdef HAVE_STDLIB_H +# include +# endif +#endif +#ifdef HAVE_STRING_H +# if !defined STDC_HEADERS && defined HAVE_MEMORY_H +# include +# endif +# include +#endif +#ifdef HAVE_STRINGS_H +# include +#endif +#ifdef HAVE_INTTYPES_H +# include +#endif +#ifdef HAVE_STDINT_H +# include +#endif +#ifdef HAVE_UNISTD_H +# include +#endif" + +enable_option_checking=no +ac_subst_vars='am__EXEEXT_FALSE +am__EXEEXT_TRUE +LTLIBOBJS +LIBCCD_CONVEX_CONVEX_FALSE +LIBCCD_CONVEX_CONVEX_TRUE +LIBCCD_CONVEX_SPHERE_FALSE +LIBCCD_CONVEX_SPHERE_TRUE +LIBCCD_CONVEX_CYL_FALSE +LIBCCD_CONVEX_CYL_TRUE +LIBCCD_CONVEX_CAP_FALSE +LIBCCD_CONVEX_CAP_TRUE +LIBCCD_CONVEX_BOX_FALSE +LIBCCD_CONVEX_BOX_TRUE +LIBCCD_CAP_CYL_FALSE +LIBCCD_CAP_CYL_TRUE +LIBCCD_CYL_CYL_FALSE +LIBCCD_CYL_CYL_TRUE +LIBCCD_BOX_CYL_FALSE +LIBCCD_BOX_CYL_TRUE +LIBCCD_INTERNAL_FALSE +LIBCCD_INTERNAL_TRUE +LIBCCD_FALSE +LIBCCD_TRUE +CCD_LIBS +CCD_CFLAGS +ENABLE_OU_FALSE +ENABLE_OU_TRUE +subdirs +ALLOCA +LIBOBJS +ENABLE_DEMOS_FALSE +ENABLE_DEMOS_TRUE +LIBSTDCXX +ENABLE_DRAWSTUFF_FALSE +ENABLE_DRAWSTUFF_TRUE +OSX_FALSE +OSX_TRUE +X11_FALSE +X11_TRUE +WIN32_FALSE +WIN32_TRUE +GL_LIBS +X11_LIBS +X11_CFLAGS +EXTRA_LIBTOOL_LDFLAGS +ODE_PRECISION +TRIMESH_FALSE +TRIMESH_TRUE +GIMPACT_FALSE +GIMPACT_TRUE +OPCODE_FALSE +OPCODE_TRUE +X86_64_SYSTEM_FALSE +X86_64_SYSTEM_TRUE +HAVE_DOXYGEN_FALSE +HAVE_DOXYGEN_TRUE +DOXYGEN +PKG_CONFIG_LIBDIR +PKG_CONFIG_PATH +PKG_CONFIG +ac_ct_WINDRES +WINDRES +CXXCPP +LT_SYS_LIBRARY_PATH +OTOOL64 +OTOOL +LIPO +NMEDIT +DSYMUTIL +MANIFEST_TOOL +RANLIB +ac_ct_AR +AR +NM +ac_ct_DUMPBIN +DUMPBIN +LD +FGREP +EGREP +GREP +SED +LIBTOOL +OBJDUMP +DLLTOOL +AS +LN_S +CPP +am__fastdepCC_FALSE +am__fastdepCC_TRUE +CCDEPMODE +ac_ct_CC +CFLAGS +CC +am__fastdepCXX_FALSE +am__fastdepCXX_TRUE +CXXDEPMODE +am__nodep +AMDEPBACKSLASH +AMDEP_FALSE +AMDEP_TRUE +am__quote +am__include +DEPDIR +OBJEXT +EXEEXT +ac_ct_CXX +CPPFLAGS +LDFLAGS +CXXFLAGS +CXX +AM_BACKSLASH +AM_DEFAULT_VERBOSITY +AM_DEFAULT_V +AM_V +am__untar +am__tar +AMTAR +am__leading_dot +SET_MAKE +AWK +mkdir_p +MKDIR_P +INSTALL_STRIP_PROGRAM +STRIP +install_sh +MAKEINFO +AUTOHEADER +AUTOMAKE +AUTOCONF +ACLOCAL +VERSION +PACKAGE +CYGPATH_W +am__isrc +INSTALL_DATA +INSTALL_SCRIPT +INSTALL_PROGRAM +host_os +host_vendor +host_cpu +host +build_os +build_vendor +build_cpu +build +ODE_VERSION_INFO +ODE_VERSION +target_alias +host_alias +build_alias +LIBS +ECHO_T +ECHO_N +ECHO_C +DEFS +mandir +localedir +libdir +psdir +pdfdir +dvidir +htmldir +infodir +docdir +oldincludedir +includedir +runstatedir +localstatedir +sharedstatedir +sysconfdir +datadir +datarootdir +libexecdir +sbindir +bindir +program_transform_name +prefix +exec_prefix +PACKAGE_URL +PACKAGE_BUGREPORT +PACKAGE_STRING +PACKAGE_VERSION +PACKAGE_TARNAME +PACKAGE_NAME +PATH_SEPARATOR +SHELL' +ac_subst_files='' +ac_user_opts=' +enable_option_checking +enable_version_info +enable_silent_rules +enable_dependency_tracking +enable_shared +enable_static +with_pic +enable_fast_install +with_aix_soname +with_gnu_ld +with_sysroot +enable_libtool_lock +with_trimesh +enable_double_precision +with_drawstuff +enable_demos +enable_old_trimesh +enable_gprof +enable_threading_intf +enable_ou +enable_builtin_threading_impl +enable_libccd +with_cylinder_cylinder +with_box_cylinder +with_capsule_cylinder +with_convex_box +with_convex_capsule +with_convex_cylinder +with_convex_sphere +with_convex_convex +with_libccd +enable_asserts +' + ac_precious_vars='build_alias +host_alias +target_alias +CXX +CXXFLAGS +LDFLAGS +LIBS +CPPFLAGS +CCC +CC +CFLAGS +CPP +LT_SYS_LIBRARY_PATH +CXXCPP +PKG_CONFIG +PKG_CONFIG_PATH +PKG_CONFIG_LIBDIR +DOXYGEN +X11_CFLAGS +X11_LIBS +CCD_CFLAGS +CCD_LIBS' +ac_subdirs_all='ou +libccd' + +# Initialize some variables set by options. +ac_init_help= +ac_init_version=false +ac_unrecognized_opts= +ac_unrecognized_sep= +# The variables have the same names as the options, with +# dashes changed to underlines. +cache_file=/dev/null +exec_prefix=NONE +no_create= +no_recursion= +prefix=NONE +program_prefix=NONE +program_suffix=NONE +program_transform_name=s,x,x, +silent= +site= +srcdir= +verbose= +x_includes=NONE +x_libraries=NONE + +# Installation directory options. +# These are left unexpanded so users can "make install exec_prefix=/foo" +# and all the variables that are supposed to be based on exec_prefix +# by default will actually change. +# Use braces instead of parens because sh, perl, etc. also accept them. +# (The list follows the same order as the GNU Coding Standards.) +bindir='${exec_prefix}/bin' +sbindir='${exec_prefix}/sbin' +libexecdir='${exec_prefix}/libexec' +datarootdir='${prefix}/share' +datadir='${datarootdir}' +sysconfdir='${prefix}/etc' +sharedstatedir='${prefix}/com' +localstatedir='${prefix}/var' +runstatedir='${localstatedir}/run' +includedir='${prefix}/include' +oldincludedir='/usr/include' +docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' +infodir='${datarootdir}/info' +htmldir='${docdir}' +dvidir='${docdir}' +pdfdir='${docdir}' +psdir='${docdir}' +libdir='${exec_prefix}/lib' +localedir='${datarootdir}/locale' +mandir='${datarootdir}/man' + +ac_prev= +ac_dashdash= +for ac_option +do + # If the previous option needs an argument, assign it. + if test -n "$ac_prev"; then + eval $ac_prev=\$ac_option + ac_prev= + continue + fi + + case $ac_option in + *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; + *=) ac_optarg= ;; + *) ac_optarg=yes ;; + esac + + # Accept the important Cygnus configure options, so we can diagnose typos. + + case $ac_dashdash$ac_option in + --) + ac_dashdash=yes ;; + + -bindir | --bindir | --bindi | --bind | --bin | --bi) + ac_prev=bindir ;; + -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) + bindir=$ac_optarg ;; + + -build | --build | --buil | --bui | --bu) + ac_prev=build_alias ;; + -build=* | --build=* | --buil=* | --bui=* | --bu=*) + build_alias=$ac_optarg ;; + + -cache-file | --cache-file | --cache-fil | --cache-fi \ + | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) + ac_prev=cache_file ;; + -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ + | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) + cache_file=$ac_optarg ;; + + --config-cache | -C) + cache_file=config.cache ;; + + -datadir | --datadir | --datadi | --datad) + ac_prev=datadir ;; + -datadir=* | --datadir=* | --datadi=* | --datad=*) + datadir=$ac_optarg ;; + + -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ + | --dataroo | --dataro | --datar) + ac_prev=datarootdir ;; + -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ + | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) + datarootdir=$ac_optarg ;; + + -disable-* | --disable-*) + ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` + # Reject names that are not valid shell variable names. + expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && + as_fn_error $? "invalid feature name: $ac_useropt" + ac_useropt_orig=$ac_useropt + ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + case $ac_user_opts in + *" +"enable_$ac_useropt" +"*) ;; + *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" + ac_unrecognized_sep=', ';; + esac + eval enable_$ac_useropt=no ;; + + -docdir | --docdir | --docdi | --doc | --do) + ac_prev=docdir ;; + -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) + docdir=$ac_optarg ;; + + -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) + ac_prev=dvidir ;; + -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) + dvidir=$ac_optarg ;; + + -enable-* | --enable-*) + ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` + # Reject names that are not valid shell variable names. + expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && + as_fn_error $? "invalid feature name: $ac_useropt" + ac_useropt_orig=$ac_useropt + ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + case $ac_user_opts in + *" +"enable_$ac_useropt" +"*) ;; + *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" + ac_unrecognized_sep=', ';; + esac + eval enable_$ac_useropt=\$ac_optarg ;; + + -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ + | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ + | --exec | --exe | --ex) + ac_prev=exec_prefix ;; + -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ + | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ + | --exec=* | --exe=* | --ex=*) + exec_prefix=$ac_optarg ;; + + -gas | --gas | --ga | --g) + # Obsolete; use --with-gas. + with_gas=yes ;; + + -help | --help | --hel | --he | -h) + ac_init_help=long ;; + -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) + ac_init_help=recursive ;; + -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) + ac_init_help=short ;; + + -host | --host | --hos | --ho) + ac_prev=host_alias ;; + -host=* | --host=* | --hos=* | --ho=*) + host_alias=$ac_optarg ;; + + -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) + ac_prev=htmldir ;; + -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ + | --ht=*) + htmldir=$ac_optarg ;; + + -includedir | --includedir | --includedi | --included | --include \ + | --includ | --inclu | --incl | --inc) + ac_prev=includedir ;; + -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ + | --includ=* | --inclu=* | --incl=* | --inc=*) + includedir=$ac_optarg ;; + + -infodir | --infodir | --infodi | --infod | --info | --inf) + ac_prev=infodir ;; + -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) + infodir=$ac_optarg ;; + + -libdir | --libdir | --libdi | --libd) + ac_prev=libdir ;; + -libdir=* | --libdir=* | --libdi=* | --libd=*) + libdir=$ac_optarg ;; + + -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ + | --libexe | --libex | --libe) + ac_prev=libexecdir ;; + -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ + | --libexe=* | --libex=* | --libe=*) + libexecdir=$ac_optarg ;; + + -localedir | --localedir | --localedi | --localed | --locale) + ac_prev=localedir ;; + -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) + localedir=$ac_optarg ;; + + -localstatedir | --localstatedir | --localstatedi | --localstated \ + | --localstate | --localstat | --localsta | --localst | --locals) + ac_prev=localstatedir ;; + -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ + | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) + localstatedir=$ac_optarg ;; + + -mandir | --mandir | --mandi | --mand | --man | --ma | --m) + ac_prev=mandir ;; + -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) + mandir=$ac_optarg ;; + + -nfp | --nfp | --nf) + # Obsolete; use --without-fp. + with_fp=no ;; + + -no-create | --no-create | --no-creat | --no-crea | --no-cre \ + | --no-cr | --no-c | -n) + no_create=yes ;; + + -no-recursion | --no-recursion | --no-recursio | --no-recursi \ + | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) + no_recursion=yes ;; + + -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ + | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ + | --oldin | --oldi | --old | --ol | --o) + ac_prev=oldincludedir ;; + -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ + | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ + | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) + oldincludedir=$ac_optarg ;; + + -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) + ac_prev=prefix ;; + -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) + prefix=$ac_optarg ;; + + -program-prefix | --program-prefix | --program-prefi | --program-pref \ + | --program-pre | --program-pr | --program-p) + ac_prev=program_prefix ;; + -program-prefix=* | --program-prefix=* | --program-prefi=* \ + | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) + program_prefix=$ac_optarg ;; + + -program-suffix | --program-suffix | --program-suffi | --program-suff \ + | --program-suf | --program-su | --program-s) + ac_prev=program_suffix ;; + -program-suffix=* | --program-suffix=* | --program-suffi=* \ + | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) + program_suffix=$ac_optarg ;; + + -program-transform-name | --program-transform-name \ + | --program-transform-nam | --program-transform-na \ + | --program-transform-n | --program-transform- \ + | --program-transform | --program-transfor \ + | --program-transfo | --program-transf \ + | --program-trans | --program-tran \ + | --progr-tra | --program-tr | --program-t) + ac_prev=program_transform_name ;; + -program-transform-name=* | --program-transform-name=* \ + | --program-transform-nam=* | --program-transform-na=* \ + | --program-transform-n=* | --program-transform-=* \ + | --program-transform=* | --program-transfor=* \ + | --program-transfo=* | --program-transf=* \ + | --program-trans=* | --program-tran=* \ + | --progr-tra=* | --program-tr=* | --program-t=*) + program_transform_name=$ac_optarg ;; + + -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) + ac_prev=pdfdir ;; + -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) + pdfdir=$ac_optarg ;; + + -psdir | --psdir | --psdi | --psd | --ps) + ac_prev=psdir ;; + -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) + psdir=$ac_optarg ;; + + -q | -quiet | --quiet | --quie | --qui | --qu | --q \ + | -silent | --silent | --silen | --sile | --sil) + silent=yes ;; + + -runstatedir | --runstatedir | --runstatedi | --runstated \ + | --runstate | --runstat | --runsta | --runst | --runs \ + | --run | --ru | --r) + ac_prev=runstatedir ;; + -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \ + | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \ + | --run=* | --ru=* | --r=*) + runstatedir=$ac_optarg ;; + + -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) + ac_prev=sbindir ;; + -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ + | --sbi=* | --sb=*) + sbindir=$ac_optarg ;; + + -sharedstatedir | --sharedstatedir | --sharedstatedi \ + | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ + | --sharedst | --shareds | --shared | --share | --shar \ + | --sha | --sh) + ac_prev=sharedstatedir ;; + -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ + | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ + | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ + | --sha=* | --sh=*) + sharedstatedir=$ac_optarg ;; + + -site | --site | --sit) + ac_prev=site ;; + -site=* | --site=* | --sit=*) + site=$ac_optarg ;; + + -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) + ac_prev=srcdir ;; + -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) + srcdir=$ac_optarg ;; + + -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ + | --syscon | --sysco | --sysc | --sys | --sy) + ac_prev=sysconfdir ;; + -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ + | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) + sysconfdir=$ac_optarg ;; + + -target | --target | --targe | --targ | --tar | --ta | --t) + ac_prev=target_alias ;; + -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) + target_alias=$ac_optarg ;; + + -v | -verbose | --verbose | --verbos | --verbo | --verb) + verbose=yes ;; + + -version | --version | --versio | --versi | --vers | -V) + ac_init_version=: ;; + + -with-* | --with-*) + ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` + # Reject names that are not valid shell variable names. + expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && + as_fn_error $? "invalid package name: $ac_useropt" + ac_useropt_orig=$ac_useropt + ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + case $ac_user_opts in + *" +"with_$ac_useropt" +"*) ;; + *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" + ac_unrecognized_sep=', ';; + esac + eval with_$ac_useropt=\$ac_optarg ;; + + -without-* | --without-*) + ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` + # Reject names that are not valid shell variable names. + expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && + as_fn_error $? "invalid package name: $ac_useropt" + ac_useropt_orig=$ac_useropt + ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + case $ac_user_opts in + *" +"with_$ac_useropt" +"*) ;; + *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" + ac_unrecognized_sep=', ';; + esac + eval with_$ac_useropt=no ;; + + --x) + # Obsolete; use --with-x. + with_x=yes ;; + + -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ + | --x-incl | --x-inc | --x-in | --x-i) + ac_prev=x_includes ;; + -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ + | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) + x_includes=$ac_optarg ;; + + -x-libraries | --x-libraries | --x-librarie | --x-librari \ + | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) + ac_prev=x_libraries ;; + -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ + | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) + x_libraries=$ac_optarg ;; + + -*) as_fn_error $? "unrecognized option: \`$ac_option' +Try \`$0 --help' for more information" + ;; + + *=*) + ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` + # Reject names that are not valid shell variable names. + case $ac_envvar in #( + '' | [0-9]* | *[!_$as_cr_alnum]* ) + as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; + esac + eval $ac_envvar=\$ac_optarg + export $ac_envvar ;; + + *) + # FIXME: should be removed in autoconf 3.0. + $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 + expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && + $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 + : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" + ;; + + esac +done + +if test -n "$ac_prev"; then + ac_option=--`echo $ac_prev | sed 's/_/-/g'` + as_fn_error $? "missing argument to $ac_option" +fi + +if test -n "$ac_unrecognized_opts"; then + case $enable_option_checking in + no) ;; + fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; + *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; + esac +fi + +# Check all directory arguments for consistency. +for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ + datadir sysconfdir sharedstatedir localstatedir includedir \ + oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ + libdir localedir mandir runstatedir +do + eval ac_val=\$$ac_var + # Remove trailing slashes. + case $ac_val in + */ ) + ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` + eval $ac_var=\$ac_val;; + esac + # Be sure to have absolute directory names. + case $ac_val in + [\\/$]* | ?:[\\/]* ) continue;; + NONE | '' ) case $ac_var in *prefix ) continue;; esac;; + esac + as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" +done + +# There might be people who depend on the old broken behavior: `$host' +# used to hold the argument of --host etc. +# FIXME: To remove some day. +build=$build_alias +host=$host_alias +target=$target_alias + +# FIXME: To remove some day. +if test "x$host_alias" != x; then + if test "x$build_alias" = x; then + cross_compiling=maybe + elif test "x$build_alias" != "x$host_alias"; then + cross_compiling=yes + fi +fi + +ac_tool_prefix= +test -n "$host_alias" && ac_tool_prefix=$host_alias- + +test "$silent" = yes && exec 6>/dev/null + + +ac_pwd=`pwd` && test -n "$ac_pwd" && +ac_ls_di=`ls -di .` && +ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || + as_fn_error $? "working directory cannot be determined" +test "X$ac_ls_di" = "X$ac_pwd_ls_di" || + as_fn_error $? "pwd does not report name of working directory" + + +# Find the source files, if location was not specified. +if test -z "$srcdir"; then + ac_srcdir_defaulted=yes + # Try the directory containing this script, then the parent directory. + ac_confdir=`$as_dirname -- "$as_myself" || +$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$as_myself" : 'X\(//\)[^/]' \| \ + X"$as_myself" : 'X\(//\)$' \| \ + X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$as_myself" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + srcdir=$ac_confdir + if test ! -r "$srcdir/$ac_unique_file"; then + srcdir=.. + fi +else + ac_srcdir_defaulted=no +fi +if test ! -r "$srcdir/$ac_unique_file"; then + test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." + as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" +fi +ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" +ac_abs_confdir=`( + cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" + pwd)` +# When building in place, set srcdir=. +if test "$ac_abs_confdir" = "$ac_pwd"; then + srcdir=. +fi +# Remove unnecessary trailing slashes from srcdir. +# Double slashes in file names in object file debugging info +# mess up M-x gdb in Emacs. +case $srcdir in +*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; +esac +for ac_var in $ac_precious_vars; do + eval ac_env_${ac_var}_set=\${${ac_var}+set} + eval ac_env_${ac_var}_value=\$${ac_var} + eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} + eval ac_cv_env_${ac_var}_value=\$${ac_var} +done + +# +# Report the --help message. +# +if test "$ac_init_help" = "long"; then + # Omit some internal or obsolete options to make the list less imposing. + # This message is too long to be a string in the A/UX 3.1 sh. + cat <<_ACEOF +\`configure' configures ODE 0.16.1 to adapt to many kinds of systems. + +Usage: $0 [OPTION]... [VAR=VALUE]... + +To assign environment variables (e.g., CC, CFLAGS...), specify them as +VAR=VALUE. See below for descriptions of some of the useful variables. + +Defaults for the options are specified in brackets. + +Configuration: + -h, --help display this help and exit + --help=short display options specific to this package + --help=recursive display the short help of all the included packages + -V, --version display version information and exit + -q, --quiet, --silent do not print \`checking ...' messages + --cache-file=FILE cache test results in FILE [disabled] + -C, --config-cache alias for \`--cache-file=config.cache' + -n, --no-create do not create output files + --srcdir=DIR find the sources in DIR [configure dir or \`..'] + +Installation directories: + --prefix=PREFIX install architecture-independent files in PREFIX + [$ac_default_prefix] + --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX + [PREFIX] + +By default, \`make install' will install all the files in +\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify +an installation prefix other than \`$ac_default_prefix' using \`--prefix', +for instance \`--prefix=\$HOME'. + +For better control, use the options below. + +Fine tuning of the installation directories: + --bindir=DIR user executables [EPREFIX/bin] + --sbindir=DIR system admin executables [EPREFIX/sbin] + --libexecdir=DIR program executables [EPREFIX/libexec] + --sysconfdir=DIR read-only single-machine data [PREFIX/etc] + --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] + --localstatedir=DIR modifiable single-machine data [PREFIX/var] + --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run] + --libdir=DIR object code libraries [EPREFIX/lib] + --includedir=DIR C header files [PREFIX/include] + --oldincludedir=DIR C header files for non-gcc [/usr/include] + --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] + --datadir=DIR read-only architecture-independent data [DATAROOTDIR] + --infodir=DIR info documentation [DATAROOTDIR/info] + --localedir=DIR locale-dependent data [DATAROOTDIR/locale] + --mandir=DIR man documentation [DATAROOTDIR/man] + --docdir=DIR documentation root [DATAROOTDIR/doc/ode] + --htmldir=DIR html documentation [DOCDIR] + --dvidir=DIR dvi documentation [DOCDIR] + --pdfdir=DIR pdf documentation [DOCDIR] + --psdir=DIR ps documentation [DOCDIR] +_ACEOF + + cat <<\_ACEOF + +Program names: + --program-prefix=PREFIX prepend PREFIX to installed program names + --program-suffix=SUFFIX append SUFFIX to installed program names + --program-transform-name=PROGRAM run sed PROGRAM on installed program names + +System types: + --build=BUILD configure for building on BUILD [guessed] + --host=HOST cross-compile to build programs to run on HOST [BUILD] +_ACEOF +fi + +if test -n "$ac_init_help"; then + case $ac_init_help in + short | recursive ) echo "Configuration of ODE 0.16.1:";; + esac + cat <<\_ACEOF + +Optional Features: + --disable-option-checking ignore unrecognized --enable/--with options + --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) + --enable-FEATURE[=ARG] include FEATURE [ARG=yes] + --disable-version-info don't encode version information in the generated + library + --enable-silent-rules less verbose build output (undo: "make V=1") + --disable-silent-rules verbose build output (undo: "make V=0") + --enable-dependency-tracking + do not reject slow dependency extractors + --disable-dependency-tracking + speeds up one-time build + --enable-shared[=PKGS] build shared libraries [default=no] + --enable-static[=PKGS] build static libraries [default=yes] + --enable-fast-install[=PKGS] + optimize for fast installation [default=yes] + --disable-libtool-lock avoid locking (might break parallel builds) + --enable-double-precision + Configure ODE to work with double precision, if not + specified, single precision is used [default=no] + --disable-demos don't build demos + --enable-old-trimesh enable use of the old trimesh collider + --enable-gprof enable profiling with gprof + --disable-threading-intf + disable threading interface support (external + implementations cannot be assigned) + --enable-ou use TLS for global caches (allows threaded collision + checks for isolated spaces) + --disable-builtin-threading-impl + disable built-in multithreaded threading + implementation + --enable-libccd enable all libccd colliders (except box-cylinder) + --disable-asserts disables debug error checking + +Optional Packages: + --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] + --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) + --with-pic[=PKGS] try to use only PIC/non-PIC objects [default=use + both] + --with-aix-soname=aix|svr4|both + shared library versioning (aka "SONAME") variant to + provide on AIX, [default=aix]. + --with-gnu-ld assume the C compiler uses GNU ld [default=no] + --with-sysroot[=DIR] Search for dependent libraries within DIR (or the + compiler's sysroot if not specified). + --with-trimesh=[opcode|gimpact|none] + use the specified system for trimesh support + [default=opcode] + --with-drawstuff=X11|Win32|OSX|none + force a particular drawstuff implementation or + disable it.[default=autodetect] + --with-cylinder-cylinder=[none,libccd] + use specific collider for cylinder-cylinder + --with-box-cylinder=[default,libccd] + use specific collider for box-cylinder + --with-capsule-cylinder=[none,libccd] + use specific collider for capsule-cylinder + --with-convex-box=[none,libccd] + use specific collider for convex-box + --with-convex-capsule=[none,libccd] + use specific collider for convex-capsule + --with-convex-cylinder=[none,libccd] + use specific collider for convex-cylinder + --with-convex-sphere=[default,libccd] + use specific collider for convex-sphere + --with-convex-convex=[default,libccd] + use specific collider for convex-convex + --with-libccd=[internal|system] + use the specified libccd [default=system] + +Some influential environment variables: + CXX C++ compiler command + CXXFLAGS C++ compiler flags + LDFLAGS linker flags, e.g. -L if you have libraries in a + nonstandard directory + LIBS libraries to pass to the linker, e.g. -l + CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if + you have headers in a nonstandard directory + CC C compiler command + CFLAGS C compiler flags + CPP C preprocessor + LT_SYS_LIBRARY_PATH + User-defined run-time library search path. + CXXCPP C++ preprocessor + PKG_CONFIG path to pkg-config utility + PKG_CONFIG_PATH + directories to add to pkg-config's search path + PKG_CONFIG_LIBDIR + path overriding pkg-config's built-in search path + DOXYGEN set to doxygen binary to generate doxygen docs + X11_CFLAGS C compiler flags for X11, overriding pkg-config + X11_LIBS linker flags for X11, overriding pkg-config + CCD_CFLAGS C compiler flags for CCD, overriding pkg-config + CCD_LIBS linker flags for CCD, overriding pkg-config + +Use these variables to override the choices made by `configure' or to help +it to find libraries and programs with nonstandard names/locations. + +Report bugs to . +_ACEOF +ac_status=$? +fi + +if test "$ac_init_help" = "recursive"; then + # If there are subdirs, report their specific --help. + for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue + test -d "$ac_dir" || + { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || + continue + ac_builddir=. + +case "$ac_dir" in +.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; +*) + ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` + # A ".." for each directory in $ac_dir_suffix. + ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` + case $ac_top_builddir_sub in + "") ac_top_builddir_sub=. ac_top_build_prefix= ;; + *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; + esac ;; +esac +ac_abs_top_builddir=$ac_pwd +ac_abs_builddir=$ac_pwd$ac_dir_suffix +# for backward compatibility: +ac_top_builddir=$ac_top_build_prefix + +case $srcdir in + .) # We are building in place. + ac_srcdir=. + ac_top_srcdir=$ac_top_builddir_sub + ac_abs_top_srcdir=$ac_pwd ;; + [\\/]* | ?:[\\/]* ) # Absolute name. + ac_srcdir=$srcdir$ac_dir_suffix; + ac_top_srcdir=$srcdir + ac_abs_top_srcdir=$srcdir ;; + *) # Relative name. + ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix + ac_top_srcdir=$ac_top_build_prefix$srcdir + ac_abs_top_srcdir=$ac_pwd/$srcdir ;; +esac +ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix + + cd "$ac_dir" || { ac_status=$?; continue; } + # Check for guested configure. + if test -f "$ac_srcdir/configure.gnu"; then + echo && + $SHELL "$ac_srcdir/configure.gnu" --help=recursive + elif test -f "$ac_srcdir/configure"; then + echo && + $SHELL "$ac_srcdir/configure" --help=recursive + else + $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 + fi || ac_status=$? + cd "$ac_pwd" || { ac_status=$?; break; } + done +fi + +test -n "$ac_init_help" && exit $ac_status +if $ac_init_version; then + cat <<\_ACEOF +ODE configure 0.16.1 +generated by GNU Autoconf 2.69 + +Copyright (C) 2012 Free Software Foundation, Inc. +This configure script is free software; the Free Software Foundation +gives unlimited permission to copy, distribute and modify it. +_ACEOF + exit +fi + +## ------------------------ ## +## Autoconf initialization. ## +## ------------------------ ## + +# ac_fn_cxx_try_compile LINENO +# ---------------------------- +# Try to compile conftest.$ac_ext, and return whether this succeeded. +ac_fn_cxx_try_compile () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + rm -f conftest.$ac_objext + if { { ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compile") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + test -z "$ac_cxx_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_cxx_try_compile + +# ac_fn_c_try_compile LINENO +# -------------------------- +# Try to compile conftest.$ac_ext, and return whether this succeeded. +ac_fn_c_try_compile () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + rm -f conftest.$ac_objext + if { { ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compile") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_try_compile + +# ac_fn_c_try_cpp LINENO +# ---------------------- +# Try to preprocess conftest.$ac_ext, and return whether this succeeded. +ac_fn_c_try_cpp () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + if { { ac_try="$ac_cpp conftest.$ac_ext" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } > conftest.i && { + test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || + test ! -s conftest.err + }; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_try_cpp + +# ac_fn_c_try_link LINENO +# ----------------------- +# Try to link conftest.$ac_ext, and return whether this succeeded. +ac_fn_c_try_link () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + rm -f conftest.$ac_objext conftest$ac_exeext + if { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest$ac_exeext && { + test "$cross_compiling" = yes || + test -x conftest$ac_exeext + }; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information + # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would + # interfere with the next link command; also delete a directory that is + # left behind by Apple's compiler. We do this before executing the actions. + rm -rf conftest.dSYM conftest_ipa8_conftest.oo + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_try_link + +# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES +# ------------------------------------------------------- +# Tests whether HEADER exists and can be compiled using the include files in +# INCLUDES, setting the cache variable VAR accordingly. +ac_fn_c_check_header_compile () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +#include <$2> +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + eval "$3=yes" +else + eval "$3=no" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_header_compile + +# ac_fn_c_try_run LINENO +# ---------------------- +# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes +# that executables *can* be run. +ac_fn_c_try_run () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + if { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' + { { case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_try") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; }; then : + ac_retval=0 +else + $as_echo "$as_me: program exited with status $ac_status" >&5 + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=$ac_status +fi + rm -rf conftest.dSYM conftest_ipa8_conftest.oo + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_try_run + +# ac_fn_c_check_func LINENO FUNC VAR +# ---------------------------------- +# Tests whether FUNC exists, setting the cache variable VAR accordingly +ac_fn_c_check_func () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Define $2 to an innocuous variant, in case declares $2. + For example, HP-UX 11i declares gettimeofday. */ +#define $2 innocuous_$2 + +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char $2 (); below. + Prefer to if __STDC__ is defined, since + exists even on freestanding compilers. */ + +#ifdef __STDC__ +# include +#else +# include +#endif + +#undef $2 + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char $2 (); +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined __stub_$2 || defined __stub___$2 +choke me +#endif + +int +main () +{ +return $2 (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + eval "$3=yes" +else + eval "$3=no" +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_func + +# ac_fn_cxx_try_cpp LINENO +# ------------------------ +# Try to preprocess conftest.$ac_ext, and return whether this succeeded. +ac_fn_cxx_try_cpp () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + if { { ac_try="$ac_cpp conftest.$ac_ext" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } > conftest.i && { + test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || + test ! -s conftest.err + }; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_cxx_try_cpp + +# ac_fn_cxx_try_link LINENO +# ------------------------- +# Try to link conftest.$ac_ext, and return whether this succeeded. +ac_fn_cxx_try_link () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + rm -f conftest.$ac_objext conftest$ac_exeext + if { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + test -z "$ac_cxx_werror_flag" || + test ! -s conftest.err + } && test -s conftest$ac_exeext && { + test "$cross_compiling" = yes || + test -x conftest$ac_exeext + }; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information + # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would + # interfere with the next link command; also delete a directory that is + # left behind by Apple's compiler. We do this before executing the actions. + rm -rf conftest.dSYM conftest_ipa8_conftest.oo + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_cxx_try_link + +# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES +# ------------------------------------------------------- +# Tests whether HEADER exists, giving a warning if it cannot be compiled using +# the include files in INCLUDES and setting the cache variable VAR +# accordingly. +ac_fn_c_check_header_mongrel () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + if eval \${$3+:} false; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } +else + # Is the header compilable? +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 +$as_echo_n "checking $2 usability... " >&6; } +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +#include <$2> +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_header_compiler=yes +else + ac_header_compiler=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 +$as_echo "$ac_header_compiler" >&6; } + +# Is the header present? +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 +$as_echo_n "checking $2 presence... " >&6; } +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <$2> +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + ac_header_preproc=yes +else + ac_header_preproc=no +fi +rm -f conftest.err conftest.i conftest.$ac_ext +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 +$as_echo "$ac_header_preproc" >&6; } + +# So? What about this header? +case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( + yes:no: ) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 +$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 +$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} + ;; + no:yes:* ) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 +$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 +$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 +$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 +$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 +$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} +( $as_echo "## -------------------------- ## +## Report this to ode@ode.org ## +## -------------------------- ##" + ) | sed "s/^/$as_me: WARNING: /" >&2 + ;; +esac + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + eval "$3=\$ac_header_compiler" +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_header_mongrel + +# ac_fn_c_check_type LINENO TYPE VAR INCLUDES +# ------------------------------------------- +# Tests whether TYPE exists after having included INCLUDES, setting cache +# variable VAR accordingly. +ac_fn_c_check_type () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + eval "$3=no" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +if (sizeof ($2)) + return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +if (sizeof (($2))) + return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + +else + eval "$3=yes" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_type + +# ac_fn_c_find_intX_t LINENO BITS VAR +# ----------------------------------- +# Finds a signed integer type with width BITS, setting cache variable VAR +# accordingly. +ac_fn_c_find_intX_t () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for int$2_t" >&5 +$as_echo_n "checking for int$2_t... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + eval "$3=no" + # Order is important - never check a type that is potentially smaller + # than half of the expected target width. + for ac_type in int$2_t 'int' 'long int' \ + 'long long int' 'short int' 'signed char'; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default + enum { N = $2 / 2 - 1 }; +int +main () +{ +static int test_array [1 - 2 * !(0 < ($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 1))]; +test_array [0] = 0; +return test_array [0]; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default + enum { N = $2 / 2 - 1 }; +int +main () +{ +static int test_array [1 - 2 * !(($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 1) + < ($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 2))]; +test_array [0] = 0; +return test_array [0]; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + +else + case $ac_type in #( + int$2_t) : + eval "$3=yes" ;; #( + *) : + eval "$3=\$ac_type" ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + if eval test \"x\$"$3"\" = x"no"; then : + +else + break +fi + done +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_find_intX_t + +# ac_fn_c_find_uintX_t LINENO BITS VAR +# ------------------------------------ +# Finds an unsigned integer type with width BITS, setting cache variable VAR +# accordingly. +ac_fn_c_find_uintX_t () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uint$2_t" >&5 +$as_echo_n "checking for uint$2_t... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + eval "$3=no" + # Order is important - never check a type that is potentially smaller + # than half of the expected target width. + for ac_type in uint$2_t 'unsigned int' 'unsigned long int' \ + 'unsigned long long int' 'unsigned short int' 'unsigned char'; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ +static int test_array [1 - 2 * !((($ac_type) -1 >> ($2 / 2 - 1)) >> ($2 / 2 - 1) == 3)]; +test_array [0] = 0; +return test_array [0]; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + case $ac_type in #( + uint$2_t) : + eval "$3=yes" ;; #( + *) : + eval "$3=\$ac_type" ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + if eval test \"x\$"$3"\" = x"no"; then : + +else + break +fi + done +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_find_uintX_t +cat >config.log <<_ACEOF +This file contains any messages produced by compilers while +running configure, to aid debugging if configure makes a mistake. + +It was created by ODE $as_me 0.16.1, which was +generated by GNU Autoconf 2.69. Invocation command line was + + $ $0 $@ + +_ACEOF +exec 5>>config.log +{ +cat <<_ASUNAME +## --------- ## +## Platform. ## +## --------- ## + +hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` +uname -m = `(uname -m) 2>/dev/null || echo unknown` +uname -r = `(uname -r) 2>/dev/null || echo unknown` +uname -s = `(uname -s) 2>/dev/null || echo unknown` +uname -v = `(uname -v) 2>/dev/null || echo unknown` + +/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` +/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` + +/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` +/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` +/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` +/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` +/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` +/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` +/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` + +_ASUNAME + +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + $as_echo "PATH: $as_dir" + done +IFS=$as_save_IFS + +} >&5 + +cat >&5 <<_ACEOF + + +## ----------- ## +## Core tests. ## +## ----------- ## + +_ACEOF + + +# Keep a trace of the command line. +# Strip out --no-create and --no-recursion so they do not pile up. +# Strip out --silent because we don't want to record it for future runs. +# Also quote any args containing shell meta-characters. +# Make two passes to allow for proper duplicate-argument suppression. +ac_configure_args= +ac_configure_args0= +ac_configure_args1= +ac_must_keep_next=false +for ac_pass in 1 2 +do + for ac_arg + do + case $ac_arg in + -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; + -q | -quiet | --quiet | --quie | --qui | --qu | --q \ + | -silent | --silent | --silen | --sile | --sil) + continue ;; + *\'*) + ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; + esac + case $ac_pass in + 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; + 2) + as_fn_append ac_configure_args1 " '$ac_arg'" + if test $ac_must_keep_next = true; then + ac_must_keep_next=false # Got value, back to normal. + else + case $ac_arg in + *=* | --config-cache | -C | -disable-* | --disable-* \ + | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ + | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ + | -with-* | --with-* | -without-* | --without-* | --x) + case "$ac_configure_args0 " in + "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; + esac + ;; + -* ) ac_must_keep_next=true ;; + esac + fi + as_fn_append ac_configure_args " '$ac_arg'" + ;; + esac + done +done +{ ac_configure_args0=; unset ac_configure_args0;} +{ ac_configure_args1=; unset ac_configure_args1;} + +# When interrupted or exit'd, cleanup temporary files, and complete +# config.log. We remove comments because anyway the quotes in there +# would cause problems or look ugly. +# WARNING: Use '\'' to represent an apostrophe within the trap. +# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. +trap 'exit_status=$? + # Save into config.log some information that might help in debugging. + { + echo + + $as_echo "## ---------------- ## +## Cache variables. ## +## ---------------- ##" + echo + # The following way of writing the cache mishandles newlines in values, +( + for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do + eval ac_val=\$$ac_var + case $ac_val in #( + *${as_nl}*) + case $ac_var in #( + *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 +$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; + esac + case $ac_var in #( + _ | IFS | as_nl) ;; #( + BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( + *) { eval $ac_var=; unset $ac_var;} ;; + esac ;; + esac + done + (set) 2>&1 | + case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( + *${as_nl}ac_space=\ *) + sed -n \ + "s/'\''/'\''\\\\'\'''\''/g; + s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" + ;; #( + *) + sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" + ;; + esac | + sort +) + echo + + $as_echo "## ----------------- ## +## Output variables. ## +## ----------------- ##" + echo + for ac_var in $ac_subst_vars + do + eval ac_val=\$$ac_var + case $ac_val in + *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; + esac + $as_echo "$ac_var='\''$ac_val'\''" + done | sort + echo + + if test -n "$ac_subst_files"; then + $as_echo "## ------------------- ## +## File substitutions. ## +## ------------------- ##" + echo + for ac_var in $ac_subst_files + do + eval ac_val=\$$ac_var + case $ac_val in + *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; + esac + $as_echo "$ac_var='\''$ac_val'\''" + done | sort + echo + fi + + if test -s confdefs.h; then + $as_echo "## ----------- ## +## confdefs.h. ## +## ----------- ##" + echo + cat confdefs.h + echo + fi + test "$ac_signal" != 0 && + $as_echo "$as_me: caught signal $ac_signal" + $as_echo "$as_me: exit $exit_status" + } >&5 + rm -f core *.core core.conftest.* && + rm -f -r conftest* confdefs* conf$$* $ac_clean_files && + exit $exit_status +' 0 +for ac_signal in 1 2 13 15; do + trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal +done +ac_signal=0 + +# confdefs.h avoids OS command line length limits that DEFS can exceed. +rm -f -r conftest* confdefs.h + +$as_echo "/* confdefs.h */" > confdefs.h + +# Predefined preprocessor variables. + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_NAME "$PACKAGE_NAME" +_ACEOF + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_TARNAME "$PACKAGE_TARNAME" +_ACEOF + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_VERSION "$PACKAGE_VERSION" +_ACEOF + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_STRING "$PACKAGE_STRING" +_ACEOF + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" +_ACEOF + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_URL "$PACKAGE_URL" +_ACEOF + + +# Let the site file select an alternate cache file if it wants to. +# Prefer an explicitly selected file to automatically selected ones. +ac_site_file1=NONE +ac_site_file2=NONE +if test -n "$CONFIG_SITE"; then + # We do not want a PATH search for config.site. + case $CONFIG_SITE in #(( + -*) ac_site_file1=./$CONFIG_SITE;; + */*) ac_site_file1=$CONFIG_SITE;; + *) ac_site_file1=./$CONFIG_SITE;; + esac +elif test "x$prefix" != xNONE; then + ac_site_file1=$prefix/share/config.site + ac_site_file2=$prefix/etc/config.site +else + ac_site_file1=$ac_default_prefix/share/config.site + ac_site_file2=$ac_default_prefix/etc/config.site +fi +for ac_site_file in "$ac_site_file1" "$ac_site_file2" +do + test "x$ac_site_file" = xNONE && continue + if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 +$as_echo "$as_me: loading site script $ac_site_file" >&6;} + sed 's/^/| /' "$ac_site_file" >&5 + . "$ac_site_file" \ + || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "failed to load site script $ac_site_file +See \`config.log' for more details" "$LINENO" 5; } + fi +done + +if test -r "$cache_file"; then + # Some versions of bash will fail to source /dev/null (special files + # actually), so we avoid doing that. DJGPP emulates it as a regular file. + if test /dev/null != "$cache_file" && test -f "$cache_file"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 +$as_echo "$as_me: loading cache $cache_file" >&6;} + case $cache_file in + [\\/]* | ?:[\\/]* ) . "$cache_file";; + *) . "./$cache_file";; + esac + fi +else + { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 +$as_echo "$as_me: creating cache $cache_file" >&6;} + >$cache_file +fi + +# Check that the precious variables saved in the cache have kept the same +# value. +ac_cache_corrupted=false +for ac_var in $ac_precious_vars; do + eval ac_old_set=\$ac_cv_env_${ac_var}_set + eval ac_new_set=\$ac_env_${ac_var}_set + eval ac_old_val=\$ac_cv_env_${ac_var}_value + eval ac_new_val=\$ac_env_${ac_var}_value + case $ac_old_set,$ac_new_set in + set,) + { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 +$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} + ac_cache_corrupted=: ;; + ,set) + { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 +$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} + ac_cache_corrupted=: ;; + ,);; + *) + if test "x$ac_old_val" != "x$ac_new_val"; then + # differences in whitespace do not lead to failure. + ac_old_val_w=`echo x $ac_old_val` + ac_new_val_w=`echo x $ac_new_val` + if test "$ac_old_val_w" != "$ac_new_val_w"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 +$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} + ac_cache_corrupted=: + else + { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 +$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} + eval $ac_var=\$ac_old_val + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 +$as_echo "$as_me: former value: \`$ac_old_val'" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 +$as_echo "$as_me: current value: \`$ac_new_val'" >&2;} + fi;; + esac + # Pass precious variables to config.status. + if test "$ac_new_set" = set; then + case $ac_new_val in + *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; + *) ac_arg=$ac_var=$ac_new_val ;; + esac + case " $ac_configure_args " in + *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. + *) as_fn_append ac_configure_args " '$ac_arg'" ;; + esac + fi +done +if $ac_cache_corrupted; then + { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 +$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} + as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 +fi +## -------------------- ## +## Main body of script. ## +## -------------------- ## + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + +ODE_VERSION=0.16.1 + + +# Those are instructions from the Libtool manual: +# 1. Start with version information of `0:0:0' for each libtool library. +# +# 2. Update the version information only immediately before a public +# release of your software. More frequent updates are unnecessary, +# and only guarantee that the current interface number gets larger +# faster. +# +# 3. If the library source code has changed at all since the last +# update, then increment REVISION (`C:R:A' becomes `C:r+1:A'). +# +# 4. If any interfaces have been added, removed, or changed since the +# last update, increment CURRENT, and set REVISION to 0. +# +# 5. If any interfaces have been added since the last public release, +# then increment AGE. +# +# 6. If any interfaces have been removed since the last public release, +# then set AGE to 0. +CURRENT=8 +REVISION=1 +AGE=0 + +# Check whether --enable-version-info was given. +if test "${enable_version_info+set}" = set; then : + enableval=$enable_version_info; version_info=$enableval +else + version_info=yes +fi + +if test x$version_info = xyes +then + ODE_VERSION_INFO="-version-info $CURRENT:$REVISION:$AGE" +else + ODE_VERSION_INFO="-avoid-version" +fi + + + + + + +ac_aux_dir= +for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do + if test -f "$ac_dir/install-sh"; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/install-sh -c" + break + elif test -f "$ac_dir/install.sh"; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/install.sh -c" + break + elif test -f "$ac_dir/shtool"; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/shtool install -c" + break + fi +done +if test -z "$ac_aux_dir"; then + as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 +fi + +# These three variables are undocumented and unsupported, +# and are intended to be withdrawn in a future Autoconf release. +# They can cause serious problems if a builder's source tree is in a directory +# whose full name contains unusual characters. +ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. +ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. +ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. + + +# Make sure we can run config.sub. +$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || + as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 +$as_echo_n "checking build system type... " >&6; } +if ${ac_cv_build+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_build_alias=$build_alias +test "x$ac_build_alias" = x && + ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` +test "x$ac_build_alias" = x && + as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 +ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || + as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 +$as_echo "$ac_cv_build" >&6; } +case $ac_cv_build in +*-*-*) ;; +*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; +esac +build=$ac_cv_build +ac_save_IFS=$IFS; IFS='-' +set x $ac_cv_build +shift +build_cpu=$1 +build_vendor=$2 +shift; shift +# Remember, the first character of IFS is used to create $*, +# except with old shells: +build_os=$* +IFS=$ac_save_IFS +case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 +$as_echo_n "checking host system type... " >&6; } +if ${ac_cv_host+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "x$host_alias" = x; then + ac_cv_host=$ac_cv_build +else + ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || + as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 +$as_echo "$ac_cv_host" >&6; } +case $ac_cv_host in +*-*-*) ;; +*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; +esac +host=$ac_cv_host +ac_save_IFS=$IFS; IFS='-' +set x $ac_cv_host +shift +host_cpu=$1 +host_vendor=$2 +shift; shift +# Remember, the first character of IFS is used to create $*, +# except with old shells: +host_os=$* +IFS=$ac_save_IFS +case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac + + + +am__api_version='1.15' + +# Find a good install program. We prefer a C program (faster), +# so one script is as good as another. But avoid the broken or +# incompatible versions: +# SysV /etc/install, /usr/sbin/install +# SunOS /usr/etc/install +# IRIX /sbin/install +# AIX /bin/install +# AmigaOS /C/install, which installs bootblocks on floppy discs +# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag +# AFS /usr/afsws/bin/install, which mishandles nonexistent args +# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" +# OS/2's system install, which has a completely different semantic +# ./install, which can be erroneously created by make from ./install.sh. +# Reject install programs that cannot install multiple files. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 +$as_echo_n "checking for a BSD-compatible install... " >&6; } +if test -z "$INSTALL"; then +if ${ac_cv_path_install+:} false; then : + $as_echo_n "(cached) " >&6 +else + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + # Account for people who put trailing slashes in PATH elements. +case $as_dir/ in #(( + ./ | .// | /[cC]/* | \ + /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ + ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ + /usr/ucb/* ) ;; + *) + # OSF1 and SCO ODT 3.0 have their own names for install. + # Don't use installbsd from OSF since it installs stuff as root + # by default. + for ac_prog in ginstall scoinst install; do + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then + if test $ac_prog = install && + grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then + # AIX install. It has an incompatible calling convention. + : + elif test $ac_prog = install && + grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then + # program-specific install script used by HP pwplus--don't use. + : + else + rm -rf conftest.one conftest.two conftest.dir + echo one > conftest.one + echo two > conftest.two + mkdir conftest.dir + if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && + test -s conftest.one && test -s conftest.two && + test -s conftest.dir/conftest.one && + test -s conftest.dir/conftest.two + then + ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" + break 3 + fi + fi + fi + done + done + ;; +esac + + done +IFS=$as_save_IFS + +rm -rf conftest.one conftest.two conftest.dir + +fi + if test "${ac_cv_path_install+set}" = set; then + INSTALL=$ac_cv_path_install + else + # As a last resort, use the slow shell script. Don't cache a + # value for INSTALL within a source directory, because that will + # break other packages using the cache if that directory is + # removed, or if the value is a relative name. + INSTALL=$ac_install_sh + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 +$as_echo "$INSTALL" >&6; } + +# Use test -z because SunOS4 sh mishandles braces in ${var-val}. +# It thinks the first close brace ends the variable substitution. +test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' + +test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' + +test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 +$as_echo_n "checking whether build environment is sane... " >&6; } +# Reject unsafe characters in $srcdir or the absolute working directory +# name. Accept space and tab only in the latter. +am_lf=' +' +case `pwd` in + *[\\\"\#\$\&\'\`$am_lf]*) + as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;; +esac +case $srcdir in + *[\\\"\#\$\&\'\`$am_lf\ \ ]*) + as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;; +esac + +# Do 'set' in a subshell so we don't clobber the current shell's +# arguments. Must try -L first in case configure is actually a +# symlink; some systems play weird games with the mod time of symlinks +# (eg FreeBSD returns the mod time of the symlink's containing +# directory). +if ( + am_has_slept=no + for am_try in 1 2; do + echo "timestamp, slept: $am_has_slept" > conftest.file + set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` + if test "$*" = "X"; then + # -L didn't work. + set X `ls -t "$srcdir/configure" conftest.file` + fi + if test "$*" != "X $srcdir/configure conftest.file" \ + && test "$*" != "X conftest.file $srcdir/configure"; then + + # If neither matched, then we have a broken ls. This can happen + # if, for instance, CONFIG_SHELL is bash and it inherits a + # broken ls alias from the environment. This has actually + # happened. Such a system could not be considered "sane". + as_fn_error $? "ls -t appears to fail. Make sure there is not a broken + alias in your environment" "$LINENO" 5 + fi + if test "$2" = conftest.file || test $am_try -eq 2; then + break + fi + # Just in case. + sleep 1 + am_has_slept=yes + done + test "$2" = conftest.file + ) +then + # Ok. + : +else + as_fn_error $? "newly created file is older than distributed files! +Check your system clock" "$LINENO" 5 +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +# If we didn't sleep, we still need to ensure time stamps of config.status and +# generated files are strictly newer. +am_sleep_pid= +if grep 'slept: no' conftest.file >/dev/null 2>&1; then + ( sleep 1 ) & + am_sleep_pid=$! +fi + +rm -f conftest.file + +test "$program_prefix" != NONE && + program_transform_name="s&^&$program_prefix&;$program_transform_name" +# Use a double $ so make ignores it. +test "$program_suffix" != NONE && + program_transform_name="s&\$&$program_suffix&;$program_transform_name" +# Double any \ or $. +# By default was `s,x,x', remove it if useless. +ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' +program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"` + +# Expand $ac_aux_dir to an absolute path. +am_aux_dir=`cd "$ac_aux_dir" && pwd` + +if test x"${MISSING+set}" != xset; then + case $am_aux_dir in + *\ * | *\ *) + MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; + *) + MISSING="\${SHELL} $am_aux_dir/missing" ;; + esac +fi +# Use eval to expand $SHELL +if eval "$MISSING --is-lightweight"; then + am_missing_run="$MISSING " +else + am_missing_run= + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5 +$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;} +fi + +if test x"${install_sh+set}" != xset; then + case $am_aux_dir in + *\ * | *\ *) + install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; + *) + install_sh="\${SHELL} $am_aux_dir/install-sh" + esac +fi + +# Installed binaries are usually stripped using 'strip' when the user +# run "make install-strip". However 'strip' might not be the right +# tool to use in cross-compilation environments, therefore Automake +# will honor the 'STRIP' environment variable to overrule this program. +if test "$cross_compiling" != no; then + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. +set dummy ${ac_tool_prefix}strip; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_STRIP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$STRIP"; then + ac_cv_prog_STRIP="$STRIP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_STRIP="${ac_tool_prefix}strip" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +STRIP=$ac_cv_prog_STRIP +if test -n "$STRIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 +$as_echo "$STRIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_STRIP"; then + ac_ct_STRIP=$STRIP + # Extract the first word of "strip", so it can be a program name with args. +set dummy strip; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_STRIP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_STRIP"; then + ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_STRIP="strip" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP +if test -n "$ac_ct_STRIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 +$as_echo "$ac_ct_STRIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_STRIP" = x; then + STRIP=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + STRIP=$ac_ct_STRIP + fi +else + STRIP="$ac_cv_prog_STRIP" +fi + +fi +INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5 +$as_echo_n "checking for a thread-safe mkdir -p... " >&6; } +if test -z "$MKDIR_P"; then + if ${ac_cv_path_mkdir+:} false; then : + $as_echo_n "(cached) " >&6 +else + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in mkdir gmkdir; do + for ac_exec_ext in '' $ac_executable_extensions; do + as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue + case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #( + 'mkdir (GNU coreutils) '* | \ + 'mkdir (coreutils) '* | \ + 'mkdir (fileutils) '4.1*) + ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext + break 3;; + esac + done + done + done +IFS=$as_save_IFS + +fi + + test -d ./--version && rmdir ./--version + if test "${ac_cv_path_mkdir+set}" = set; then + MKDIR_P="$ac_cv_path_mkdir -p" + else + # As a last resort, use the slow shell script. Don't cache a + # value for MKDIR_P within a source directory, because that will + # break other packages using the cache if that directory is + # removed, or if the value is a relative name. + MKDIR_P="$ac_install_sh -d" + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 +$as_echo "$MKDIR_P" >&6; } + +for ac_prog in gawk mawk nawk awk +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_AWK+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$AWK"; then + ac_cv_prog_AWK="$AWK" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_AWK="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +AWK=$ac_cv_prog_AWK +if test -n "$AWK"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 +$as_echo "$AWK" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$AWK" && break +done + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 +$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } +set x ${MAKE-make} +ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` +if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat >conftest.make <<\_ACEOF +SHELL = /bin/sh +all: + @echo '@@@%%%=$(MAKE)=@@@%%%' +_ACEOF +# GNU make sometimes prints "make[1]: Entering ...", which would confuse us. +case `${MAKE-make} -f conftest.make 2>/dev/null` in + *@@@%%%=?*=@@@%%%*) + eval ac_cv_prog_make_${ac_make}_set=yes;; + *) + eval ac_cv_prog_make_${ac_make}_set=no;; +esac +rm -f conftest.make +fi +if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + SET_MAKE= +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + SET_MAKE="MAKE=${MAKE-make}" +fi + +rm -rf .tst 2>/dev/null +mkdir .tst 2>/dev/null +if test -d .tst; then + am__leading_dot=. +else + am__leading_dot=_ +fi +rmdir .tst 2>/dev/null + +# Check whether --enable-silent-rules was given. +if test "${enable_silent_rules+set}" = set; then : + enableval=$enable_silent_rules; +fi + +case $enable_silent_rules in # ((( + yes) AM_DEFAULT_VERBOSITY=0;; + no) AM_DEFAULT_VERBOSITY=1;; + *) AM_DEFAULT_VERBOSITY=1;; +esac +am_make=${MAKE-make} +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 +$as_echo_n "checking whether $am_make supports nested variables... " >&6; } +if ${am_cv_make_support_nested_variables+:} false; then : + $as_echo_n "(cached) " >&6 +else + if $as_echo 'TRUE=$(BAR$(V)) +BAR0=false +BAR1=true +V=1 +am__doit: + @$(TRUE) +.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then + am_cv_make_support_nested_variables=yes +else + am_cv_make_support_nested_variables=no +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5 +$as_echo "$am_cv_make_support_nested_variables" >&6; } +if test $am_cv_make_support_nested_variables = yes; then + AM_V='$(V)' + AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' +else + AM_V=$AM_DEFAULT_VERBOSITY + AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY +fi +AM_BACKSLASH='\' + +if test "`cd $srcdir && pwd`" != "`pwd`"; then + # Use -I$(srcdir) only when $(srcdir) != ., so that make's output + # is not polluted with repeated "-I." + am__isrc=' -I$(srcdir)' + # test to see if srcdir already configured + if test -f $srcdir/config.status; then + as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 + fi +fi + +# test whether we have cygpath +if test -z "$CYGPATH_W"; then + if (cygpath --version) >/dev/null 2>/dev/null; then + CYGPATH_W='cygpath -w' + else + CYGPATH_W=echo + fi +fi + + +# Define the identity of the package. + PACKAGE='ode' + VERSION='0.16.1' + + +cat >>confdefs.h <<_ACEOF +#define PACKAGE "$PACKAGE" +_ACEOF + + +cat >>confdefs.h <<_ACEOF +#define VERSION "$VERSION" +_ACEOF + +# Some tools Automake needs. + +ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} + + +AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} + + +AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} + + +AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} + + +MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} + +# For better backward compatibility. To be removed once Automake 1.9.x +# dies out for good. For more background, see: +# +# +mkdir_p='$(MKDIR_P)' + +# We need awk for the "check" target (and possibly the TAP driver). The +# system "awk" is bad on some platforms. +# Always define AMTAR for backward compatibility. Yes, it's still used +# in the wild :-( We should find a proper way to deprecate it ... +AMTAR='$${TAR-tar}' + + +# We'll loop over all known methods to create a tar archive until one works. +_am_tools='gnutar pax cpio none' + +am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -' + + + + + + +# POSIX will say in a future version that running "rm -f" with no argument +# is OK; and we want to be able to make that assumption in our Makefile +# recipes. So use an aggressive probe to check that the usage we want is +# actually supported "in the wild" to an acceptable degree. +# See automake bug#10828. +# To make any issue more visible, cause the running configure to be aborted +# by default if the 'rm' program in use doesn't match our expectations; the +# user can still override this though. +if rm -f && rm -fr && rm -rf; then : OK; else + cat >&2 <<'END' +Oops! + +Your 'rm' program seems unable to run without file operands specified +on the command line, even when the '-f' option is present. This is contrary +to the behaviour of most rm programs out there, and not conforming with +the upcoming POSIX standard: + +Please tell bug-automake@gnu.org about your system, including the value +of your $PATH and any error possibly output before this message. This +can help us improve future automake versions. + +END + if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then + echo 'Configuration will proceed anyway, since you have set the' >&2 + echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 + echo >&2 + else + cat >&2 <<'END' +Aborting the configuration process, to ensure you take notice of the issue. + +You can download and install GNU coreutils to get an 'rm' implementation +that behaves properly: . + +If you want to complete the configuration process using your problematic +'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM +to "yes", and re-run configure. + +END + as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5 + fi +fi + +ac_config_headers="$ac_config_headers ode/src/config.h" + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 +$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } +set x ${MAKE-make} +ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` +if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat >conftest.make <<\_ACEOF +SHELL = /bin/sh +all: + @echo '@@@%%%=$(MAKE)=@@@%%%' +_ACEOF +# GNU make sometimes prints "make[1]: Entering ...", which would confuse us. +case `${MAKE-make} -f conftest.make 2>/dev/null` in + *@@@%%%=?*=@@@%%%*) + eval ac_cv_prog_make_${ac_make}_set=yes;; + *) + eval ac_cv_prog_make_${ac_make}_set=no;; +esac +rm -f conftest.make +fi +if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + SET_MAKE= +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + SET_MAKE="MAKE=${MAKE-make}" +fi + +ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu +if test -z "$CXX"; then + if test -n "$CCC"; then + CXX=$CCC + else + if test -n "$ac_tool_prefix"; then + for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CXX"; then + ac_cv_prog_CXX="$CXX" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +CXX=$ac_cv_prog_CXX +if test -n "$CXX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 +$as_echo "$CXX" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$CXX" && break + done +fi +if test -z "$CXX"; then + ac_ct_CXX=$CXX + for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_CXX"; then + ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_CXX="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_CXX=$ac_cv_prog_ac_ct_CXX +if test -n "$ac_ct_CXX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 +$as_echo "$ac_ct_CXX" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$ac_ct_CXX" && break +done + + if test "x$ac_ct_CXX" = x; then + CXX="g++" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + CXX=$ac_ct_CXX + fi +fi + + fi +fi +# Provide some information about the compiler. +$as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5 +set X $ac_compile +ac_compiler=$2 +for ac_option in --version -v -V -qversion; do + { { ac_try="$ac_compiler $ac_option >&5" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compiler $ac_option >&5") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + sed '10a\ +... rest of stderr output deleted ... + 10q' conftest.err >conftest.er1 + cat conftest.er1 >&5 + fi + rm -f conftest.er1 conftest.err + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } +done + +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +ac_clean_files_save=$ac_clean_files +ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" +# Try to create an executable without -o first, disregard a.out. +# It will help us diagnose broken compilers, and finding out an intuition +# of exeext. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C++ compiler works" >&5 +$as_echo_n "checking whether the C++ compiler works... " >&6; } +ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` + +# The possible output files: +ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" + +ac_rmfiles= +for ac_file in $ac_files +do + case $ac_file in + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; + * ) ac_rmfiles="$ac_rmfiles $ac_file";; + esac +done +rm -f $ac_rmfiles + +if { { ac_try="$ac_link_default" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link_default") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then : + # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. +# So ignore a value of `no', otherwise this would lead to `EXEEXT = no' +# in a Makefile. We should not override ac_cv_exeext if it was cached, +# so that the user can short-circuit this test for compilers unknown to +# Autoconf. +for ac_file in $ac_files '' +do + test -f "$ac_file" || continue + case $ac_file in + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) + ;; + [ab].out ) + # We found the default executable, but exeext='' is most + # certainly right. + break;; + *.* ) + if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; + then :; else + ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` + fi + # We set ac_cv_exeext here because the later test for it is not + # safe: cross compilers may not add the suffix if given an `-o' + # argument, so we may need to know it at that point already. + # Even if this section looks crufty: it has the advantage of + # actually working. + break;; + * ) + break;; + esac +done +test "$ac_cv_exeext" = no && ac_cv_exeext= + +else + ac_file='' +fi +if test -z "$ac_file"; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +$as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "C++ compiler cannot create executables +See \`config.log' for more details" "$LINENO" 5; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler default output file name" >&5 +$as_echo_n "checking for C++ compiler default output file name... " >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 +$as_echo "$ac_file" >&6; } +ac_exeext=$ac_cv_exeext + +rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out +ac_clean_files=$ac_clean_files_save +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 +$as_echo_n "checking for suffix of executables... " >&6; } +if { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then : + # If both `conftest.exe' and `conftest' are `present' (well, observable) +# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will +# work properly (i.e., refer to `conftest.exe'), while it won't with +# `rm'. +for ac_file in conftest.exe conftest conftest.*; do + test -f "$ac_file" || continue + case $ac_file in + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; + *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` + break;; + * ) break;; + esac +done +else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "cannot compute suffix of executables: cannot compile and link +See \`config.log' for more details" "$LINENO" 5; } +fi +rm -f conftest conftest$ac_cv_exeext +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 +$as_echo "$ac_cv_exeext" >&6; } + +rm -f conftest.$ac_ext +EXEEXT=$ac_cv_exeext +ac_exeext=$EXEEXT +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main () +{ +FILE *f = fopen ("conftest.out", "w"); + return ferror (f) || fclose (f) != 0; + + ; + return 0; +} +_ACEOF +ac_clean_files="$ac_clean_files conftest.out" +# Check that the compiler produces executables we can run. If not, either +# the compiler is broken, or we cross compile. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 +$as_echo_n "checking whether we are cross compiling... " >&6; } +if test "$cross_compiling" != yes; then + { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if { ac_try='./conftest$ac_cv_exeext' + { { case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_try") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; }; then + cross_compiling=no + else + if test "$cross_compiling" = maybe; then + cross_compiling=yes + else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "cannot run C++ compiled programs. +If you meant to cross compile, use \`--host'. +See \`config.log' for more details" "$LINENO" 5; } + fi + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 +$as_echo "$cross_compiling" >&6; } + +rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out +ac_clean_files=$ac_clean_files_save +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 +$as_echo_n "checking for suffix of object files... " >&6; } +if ${ac_cv_objext+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +rm -f conftest.o conftest.obj +if { { ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compile") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then : + for ac_file in conftest.o conftest.obj conftest.*; do + test -f "$ac_file" || continue; + case $ac_file in + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; + *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` + break;; + esac +done +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "cannot compute suffix of object files: cannot compile +See \`config.log' for more details" "$LINENO" 5; } +fi +rm -f conftest.$ac_cv_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 +$as_echo "$ac_cv_objext" >&6; } +OBJEXT=$ac_cv_objext +ac_objext=$OBJEXT +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5 +$as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } +if ${ac_cv_cxx_compiler_gnu+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ +#ifndef __GNUC__ + choke me +#endif + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + ac_compiler_gnu=yes +else + ac_compiler_gnu=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_cv_cxx_compiler_gnu=$ac_compiler_gnu + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 +$as_echo "$ac_cv_cxx_compiler_gnu" >&6; } +if test $ac_compiler_gnu = yes; then + GXX=yes +else + GXX= +fi +ac_test_CXXFLAGS=${CXXFLAGS+set} +ac_save_CXXFLAGS=$CXXFLAGS +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 +$as_echo_n "checking whether $CXX accepts -g... " >&6; } +if ${ac_cv_prog_cxx_g+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_save_cxx_werror_flag=$ac_cxx_werror_flag + ac_cxx_werror_flag=yes + ac_cv_prog_cxx_g=no + CXXFLAGS="-g" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + ac_cv_prog_cxx_g=yes +else + CXXFLAGS="" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + +else + ac_cxx_werror_flag=$ac_save_cxx_werror_flag + CXXFLAGS="-g" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + ac_cv_prog_cxx_g=yes +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_cxx_werror_flag=$ac_save_cxx_werror_flag +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 +$as_echo "$ac_cv_prog_cxx_g" >&6; } +if test "$ac_test_CXXFLAGS" = set; then + CXXFLAGS=$ac_save_CXXFLAGS +elif test $ac_cv_prog_cxx_g = yes; then + if test "$GXX" = yes; then + CXXFLAGS="-g -O2" + else + CXXFLAGS="-g" + fi +else + if test "$GXX" = yes; then + CXXFLAGS="-O2" + else + CXXFLAGS= + fi +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +DEPDIR="${am__leading_dot}deps" + +ac_config_commands="$ac_config_commands depfiles" + + +am_make=${MAKE-make} +cat > confinc << 'END' +am__doit: + @echo this is the am__doit target +.PHONY: am__doit +END +# If we don't find an include directive, just comment out the code. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5 +$as_echo_n "checking for style of include used by $am_make... " >&6; } +am__include="#" +am__quote= +_am_result=none +# First try GNU make style include. +echo "include confinc" > confmf +# Ignore all kinds of additional output from 'make'. +case `$am_make -s -f confmf 2> /dev/null` in #( +*the\ am__doit\ target*) + am__include=include + am__quote= + _am_result=GNU + ;; +esac +# Now try BSD make style include. +if test "$am__include" = "#"; then + echo '.include "confinc"' > confmf + case `$am_make -s -f confmf 2> /dev/null` in #( + *the\ am__doit\ target*) + am__include=.include + am__quote="\"" + _am_result=BSD + ;; + esac +fi + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5 +$as_echo "$_am_result" >&6; } +rm -f confinc confmf + +# Check whether --enable-dependency-tracking was given. +if test "${enable_dependency_tracking+set}" = set; then : + enableval=$enable_dependency_tracking; +fi + +if test "x$enable_dependency_tracking" != xno; then + am_depcomp="$ac_aux_dir/depcomp" + AMDEPBACKSLASH='\' + am__nodep='_no' +fi + if test "x$enable_dependency_tracking" != xno; then + AMDEP_TRUE= + AMDEP_FALSE='#' +else + AMDEP_TRUE='#' + AMDEP_FALSE= +fi + + + +depcc="$CXX" am_compiler_list= + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 +$as_echo_n "checking dependency style of $depcc... " >&6; } +if ${am_cv_CXX_dependencies_compiler_type+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then + # We make a subdir and do the tests there. Otherwise we can end up + # making bogus files that we don't know about and never remove. For + # instance it was reported that on HP-UX the gcc test will end up + # making a dummy file named 'D' -- because '-MD' means "put the output + # in D". + rm -rf conftest.dir + mkdir conftest.dir + # Copy depcomp to subdir because otherwise we won't find it if we're + # using a relative directory. + cp "$am_depcomp" conftest.dir + cd conftest.dir + # We will build objects and dependencies in a subdirectory because + # it helps to detect inapplicable dependency modes. For instance + # both Tru64's cc and ICC support -MD to output dependencies as a + # side effect of compilation, but ICC will put the dependencies in + # the current directory while Tru64 will put them in the object + # directory. + mkdir sub + + am_cv_CXX_dependencies_compiler_type=none + if test "$am_compiler_list" = ""; then + am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` + fi + am__universal=false + case " $depcc " in #( + *\ -arch\ *\ -arch\ *) am__universal=true ;; + esac + + for depmode in $am_compiler_list; do + # Setup a source with many dependencies, because some compilers + # like to wrap large dependency lists on column 80 (with \), and + # we should not choose a depcomp mode which is confused by this. + # + # We need to recreate these files for each test, as the compiler may + # overwrite some of them when testing with obscure command lines. + # This happens at least with the AIX C compiler. + : > sub/conftest.c + for i in 1 2 3 4 5 6; do + echo '#include "conftst'$i'.h"' >> sub/conftest.c + # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with + # Solaris 10 /bin/sh. + echo '/* dummy */' > sub/conftst$i.h + done + echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf + + # We check with '-c' and '-o' for the sake of the "dashmstdout" + # mode. It turns out that the SunPro C++ compiler does not properly + # handle '-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs. + am__obj=sub/conftest.${OBJEXT-o} + am__minus_obj="-o $am__obj" + case $depmode in + gcc) + # This depmode causes a compiler race in universal mode. + test "$am__universal" = false || continue + ;; + nosideeffect) + # After this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested. + if test "x$enable_dependency_tracking" = xyes; then + continue + else + break + fi + ;; + msvc7 | msvc7msys | msvisualcpp | msvcmsys) + # This compiler won't grok '-c -o', but also, the minuso test has + # not run yet. These depmodes are late enough in the game, and + # so weak that their functioning should not be impacted. + am__obj=conftest.${OBJEXT-o} + am__minus_obj= + ;; + none) break ;; + esac + if depmode=$depmode \ + source=sub/conftest.c object=$am__obj \ + depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ + $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ + >/dev/null 2>conftest.err && + grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && + grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && + grep $am__obj sub/conftest.Po > /dev/null 2>&1 && + ${MAKE-make} -s -f confmf > /dev/null 2>&1; then + # icc doesn't choke on unknown options, it will just issue warnings + # or remarks (even with -Werror). So we grep stderr for any message + # that says an option was ignored or not supported. + # When given -MP, icc 7.0 and 7.1 complain thusly: + # icc: Command line warning: ignoring option '-M'; no argument required + # The diagnosis changed in icc 8.0: + # icc: Command line remark: option '-MP' not supported + if (grep 'ignoring option' conftest.err || + grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else + am_cv_CXX_dependencies_compiler_type=$depmode + break + fi + fi + done + + cd .. + rm -rf conftest.dir +else + am_cv_CXX_dependencies_compiler_type=none +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CXX_dependencies_compiler_type" >&5 +$as_echo "$am_cv_CXX_dependencies_compiler_type" >&6; } +CXXDEPMODE=depmode=$am_cv_CXX_dependencies_compiler_type + + if + test "x$enable_dependency_tracking" != xno \ + && test "$am_cv_CXX_dependencies_compiler_type" = gcc3; then + am__fastdepCXX_TRUE= + am__fastdepCXX_FALSE='#' +else + am__fastdepCXX_TRUE='#' + am__fastdepCXX_FALSE= +fi + + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. +set dummy ${ac_tool_prefix}gcc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CC="${ac_tool_prefix}gcc" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_CC"; then + ac_ct_CC=$CC + # Extract the first word of "gcc", so it can be a program name with args. +set dummy gcc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_CC"; then + ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_CC="gcc" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_CC=$ac_cv_prog_ac_ct_CC +if test -n "$ac_ct_CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 +$as_echo "$ac_ct_CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_CC" = x; then + CC="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + CC=$ac_ct_CC + fi +else + CC="$ac_cv_prog_CC" +fi + +if test -z "$CC"; then + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. +set dummy ${ac_tool_prefix}cc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CC="${ac_tool_prefix}cc" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + fi +fi +if test -z "$CC"; then + # Extract the first word of "cc", so it can be a program name with args. +set dummy cc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else + ac_prog_rejected=no +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then + ac_prog_rejected=yes + continue + fi + ac_cv_prog_CC="cc" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +if test $ac_prog_rejected = yes; then + # We found a bogon in the path, so make sure we never use it. + set dummy $ac_cv_prog_CC + shift + if test $# != 0; then + # We chose a different compiler from the bogus one. + # However, it has the same basename, so the bogon will be chosen + # first if we set CC to just the basename; use the full file name. + shift + ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" + fi +fi +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$CC"; then + if test -n "$ac_tool_prefix"; then + for ac_prog in cl.exe + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CC="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$CC" && break + done +fi +if test -z "$CC"; then + ac_ct_CC=$CC + for ac_prog in cl.exe +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_CC"; then + ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_CC="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_CC=$ac_cv_prog_ac_ct_CC +if test -n "$ac_ct_CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 +$as_echo "$ac_ct_CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$ac_ct_CC" && break +done + + if test "x$ac_ct_CC" = x; then + CC="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + CC=$ac_ct_CC + fi +fi + +fi + + +test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "no acceptable C compiler found in \$PATH +See \`config.log' for more details" "$LINENO" 5; } + +# Provide some information about the compiler. +$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 +set X $ac_compile +ac_compiler=$2 +for ac_option in --version -v -V -qversion; do + { { ac_try="$ac_compiler $ac_option >&5" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compiler $ac_option >&5") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + sed '10a\ +... rest of stderr output deleted ... + 10q' conftest.err >conftest.er1 + cat conftest.er1 >&5 + fi + rm -f conftest.er1 conftest.err + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } +done + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 +$as_echo_n "checking whether we are using the GNU C compiler... " >&6; } +if ${ac_cv_c_compiler_gnu+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ +#ifndef __GNUC__ + choke me +#endif + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_compiler_gnu=yes +else + ac_compiler_gnu=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_cv_c_compiler_gnu=$ac_compiler_gnu + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 +$as_echo "$ac_cv_c_compiler_gnu" >&6; } +if test $ac_compiler_gnu = yes; then + GCC=yes +else + GCC= +fi +ac_test_CFLAGS=${CFLAGS+set} +ac_save_CFLAGS=$CFLAGS +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 +$as_echo_n "checking whether $CC accepts -g... " >&6; } +if ${ac_cv_prog_cc_g+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_save_c_werror_flag=$ac_c_werror_flag + ac_c_werror_flag=yes + ac_cv_prog_cc_g=no + CFLAGS="-g" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_prog_cc_g=yes +else + CFLAGS="" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + +else + ac_c_werror_flag=$ac_save_c_werror_flag + CFLAGS="-g" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_prog_cc_g=yes +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_c_werror_flag=$ac_save_c_werror_flag +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 +$as_echo "$ac_cv_prog_cc_g" >&6; } +if test "$ac_test_CFLAGS" = set; then + CFLAGS=$ac_save_CFLAGS +elif test $ac_cv_prog_cc_g = yes; then + if test "$GCC" = yes; then + CFLAGS="-g -O2" + else + CFLAGS="-g" + fi +else + if test "$GCC" = yes; then + CFLAGS="-O2" + else + CFLAGS= + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 +$as_echo_n "checking for $CC option to accept ISO C89... " >&6; } +if ${ac_cv_prog_cc_c89+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_cv_prog_cc_c89=no +ac_save_CC=$CC +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +struct stat; +/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ +struct buf { int x; }; +FILE * (*rcsopen) (struct buf *, struct stat *, int); +static char *e (p, i) + char **p; + int i; +{ + return p[i]; +} +static char *f (char * (*g) (char **, int), char **p, ...) +{ + char *s; + va_list v; + va_start (v,p); + s = g (p, va_arg (v,int)); + va_end (v); + return s; +} + +/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has + function prototypes and stuff, but not '\xHH' hex character constants. + These don't provoke an error unfortunately, instead are silently treated + as 'x'. The following induces an error, until -std is added to get + proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an + array size at least. It's necessary to write '\x00'==0 to get something + that's true only with -std. */ +int osf4_cc_array ['\x00' == 0 ? 1 : -1]; + +/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters + inside strings and character constants. */ +#define FOO(x) 'x' +int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; + +int test (int i, double x); +struct s1 {int (*f) (int a);}; +struct s2 {int (*f) (double a);}; +int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); +int argc; +char **argv; +int +main () +{ +return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; + ; + return 0; +} +_ACEOF +for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ + -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" +do + CC="$ac_save_CC $ac_arg" + if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_prog_cc_c89=$ac_arg +fi +rm -f core conftest.err conftest.$ac_objext + test "x$ac_cv_prog_cc_c89" != "xno" && break +done +rm -f conftest.$ac_ext +CC=$ac_save_CC + +fi +# AC_CACHE_VAL +case "x$ac_cv_prog_cc_c89" in + x) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 +$as_echo "none needed" >&6; } ;; + xno) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 +$as_echo "unsupported" >&6; } ;; + *) + CC="$CC $ac_cv_prog_cc_c89" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 +$as_echo "$ac_cv_prog_cc_c89" >&6; } ;; +esac +if test "x$ac_cv_prog_cc_c89" != xno; then : + +fi + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5 +$as_echo_n "checking whether $CC understands -c and -o together... " >&6; } +if ${am_cv_prog_cc_c_o+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF + # Make sure it works both with $CC and with simple cc. + # Following AC_PROG_CC_C_O, we do the test twice because some + # compilers refuse to overwrite an existing .o file with -o, + # though they will create one. + am_cv_prog_cc_c_o=yes + for am_i in 1 2; do + if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5 + ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } \ + && test -f conftest2.$ac_objext; then + : OK + else + am_cv_prog_cc_c_o=no + break + fi + done + rm -f core conftest* + unset am_i +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5 +$as_echo "$am_cv_prog_cc_c_o" >&6; } +if test "$am_cv_prog_cc_c_o" != yes; then + # Losing compiler, so override with the script. + # FIXME: It is wrong to rewrite CC. + # But if we don't then we get into trouble of one sort or another. + # A longer-term fix would be to have automake use am__CC in this case, + # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" + CC="$am_aux_dir/compile $CC" +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + +depcc="$CC" am_compiler_list= + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 +$as_echo_n "checking dependency style of $depcc... " >&6; } +if ${am_cv_CC_dependencies_compiler_type+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then + # We make a subdir and do the tests there. Otherwise we can end up + # making bogus files that we don't know about and never remove. For + # instance it was reported that on HP-UX the gcc test will end up + # making a dummy file named 'D' -- because '-MD' means "put the output + # in D". + rm -rf conftest.dir + mkdir conftest.dir + # Copy depcomp to subdir because otherwise we won't find it if we're + # using a relative directory. + cp "$am_depcomp" conftest.dir + cd conftest.dir + # We will build objects and dependencies in a subdirectory because + # it helps to detect inapplicable dependency modes. For instance + # both Tru64's cc and ICC support -MD to output dependencies as a + # side effect of compilation, but ICC will put the dependencies in + # the current directory while Tru64 will put them in the object + # directory. + mkdir sub + + am_cv_CC_dependencies_compiler_type=none + if test "$am_compiler_list" = ""; then + am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` + fi + am__universal=false + case " $depcc " in #( + *\ -arch\ *\ -arch\ *) am__universal=true ;; + esac + + for depmode in $am_compiler_list; do + # Setup a source with many dependencies, because some compilers + # like to wrap large dependency lists on column 80 (with \), and + # we should not choose a depcomp mode which is confused by this. + # + # We need to recreate these files for each test, as the compiler may + # overwrite some of them when testing with obscure command lines. + # This happens at least with the AIX C compiler. + : > sub/conftest.c + for i in 1 2 3 4 5 6; do + echo '#include "conftst'$i'.h"' >> sub/conftest.c + # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with + # Solaris 10 /bin/sh. + echo '/* dummy */' > sub/conftst$i.h + done + echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf + + # We check with '-c' and '-o' for the sake of the "dashmstdout" + # mode. It turns out that the SunPro C++ compiler does not properly + # handle '-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs. + am__obj=sub/conftest.${OBJEXT-o} + am__minus_obj="-o $am__obj" + case $depmode in + gcc) + # This depmode causes a compiler race in universal mode. + test "$am__universal" = false || continue + ;; + nosideeffect) + # After this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested. + if test "x$enable_dependency_tracking" = xyes; then + continue + else + break + fi + ;; + msvc7 | msvc7msys | msvisualcpp | msvcmsys) + # This compiler won't grok '-c -o', but also, the minuso test has + # not run yet. These depmodes are late enough in the game, and + # so weak that their functioning should not be impacted. + am__obj=conftest.${OBJEXT-o} + am__minus_obj= + ;; + none) break ;; + esac + if depmode=$depmode \ + source=sub/conftest.c object=$am__obj \ + depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ + $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ + >/dev/null 2>conftest.err && + grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && + grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && + grep $am__obj sub/conftest.Po > /dev/null 2>&1 && + ${MAKE-make} -s -f confmf > /dev/null 2>&1; then + # icc doesn't choke on unknown options, it will just issue warnings + # or remarks (even with -Werror). So we grep stderr for any message + # that says an option was ignored or not supported. + # When given -MP, icc 7.0 and 7.1 complain thusly: + # icc: Command line warning: ignoring option '-M'; no argument required + # The diagnosis changed in icc 8.0: + # icc: Command line remark: option '-MP' not supported + if (grep 'ignoring option' conftest.err || + grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else + am_cv_CC_dependencies_compiler_type=$depmode + break + fi + fi + done + + cd .. + rm -rf conftest.dir +else + am_cv_CC_dependencies_compiler_type=none +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 +$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } +CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type + + if + test "x$enable_dependency_tracking" != xno \ + && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then + am__fastdepCC_TRUE= + am__fastdepCC_FALSE='#' +else + am__fastdepCC_TRUE='#' + am__fastdepCC_FALSE= +fi + + + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 +$as_echo_n "checking how to run the C preprocessor... " >&6; } +# On Suns, sometimes $CPP names a directory. +if test -n "$CPP" && test -d "$CPP"; then + CPP= +fi +if test -z "$CPP"; then + if ${ac_cv_prog_CPP+:} false; then : + $as_echo_n "(cached) " >&6 +else + # Double quotes because CPP needs to be expanded + for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" + do + ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + break +fi + + done + ac_cv_prog_CPP=$CPP + +fi + CPP=$ac_cv_prog_CPP +else + ac_cv_prog_CPP=$CPP +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 +$as_echo "$CPP" >&6; } +ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + +else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "C preprocessor \"$CPP\" fails sanity check +See \`config.log' for more details" "$LINENO" 5; } +fi + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +for ac_prog in gawk mawk nawk awk +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_AWK+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$AWK"; then + ac_cv_prog_AWK="$AWK" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_AWK="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +AWK=$ac_cv_prog_AWK +if test -n "$AWK"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 +$as_echo "$AWK" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$AWK" && break +done + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 +$as_echo_n "checking whether ln -s works... " >&6; } +LN_S=$as_ln_s +if test "$LN_S" = "ln -s"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 +$as_echo "no, using $LN_S" >&6; } +fi + + +case `pwd` in + *\ * | *\ *) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5 +$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;; +esac + + + +macro_version='2.4.6' +macro_revision='2.4.6' + + + + + + + + + + + + + +ltmain=$ac_aux_dir/ltmain.sh + +# Backslashify metacharacters that are still active within +# double-quoted strings. +sed_quote_subst='s/\(["`$\\]\)/\\\1/g' + +# Same as above, but do not quote variable references. +double_quote_subst='s/\(["`\\]\)/\\\1/g' + +# Sed substitution to delay expansion of an escaped shell variable in a +# double_quote_subst'ed string. +delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' + +# Sed substitution to delay expansion of an escaped single quote. +delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' + +# Sed substitution to avoid accidental globbing in evaled expressions +no_glob_subst='s/\*/\\\*/g' + +ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5 +$as_echo_n "checking how to print strings... " >&6; } +# Test print first, because it will be a builtin if present. +if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ + test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='print -r --' +elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='printf %s\n' +else + # Use this function as a fallback that always works. + func_fallback_echo () + { + eval 'cat <<_LTECHO_EOF +$1 +_LTECHO_EOF' + } + ECHO='func_fallback_echo' +fi + +# func_echo_all arg... +# Invoke $ECHO with all args, space-separated. +func_echo_all () +{ + $ECHO "" +} + +case $ECHO in + printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5 +$as_echo "printf" >&6; } ;; + print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5 +$as_echo "print -r" >&6; } ;; + *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5 +$as_echo "cat" >&6; } ;; +esac + + + + + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 +$as_echo_n "checking for a sed that does not truncate output... " >&6; } +if ${ac_cv_path_SED+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ + for ac_i in 1 2 3 4 5 6 7; do + ac_script="$ac_script$as_nl$ac_script" + done + echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed + { ac_script=; unset ac_script;} + if test -z "$SED"; then + ac_path_SED_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in sed gsed; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_SED" || continue +# Check for GNU ac_path_SED and select it if it is found. + # Check for GNU $ac_path_SED +case `"$ac_path_SED" --version 2>&1` in +*GNU*) + ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo '' >> "conftest.nl" + "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_SED_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_SED="$ac_path_SED" + ac_path_SED_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_SED_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_SED"; then + as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 + fi +else + ac_cv_path_SED=$SED +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 +$as_echo "$ac_cv_path_SED" >&6; } + SED="$ac_cv_path_SED" + rm -f conftest.sed + +test -z "$SED" && SED=sed +Xsed="$SED -e 1s/^X//" + + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 +$as_echo_n "checking for grep that handles long lines and -e... " >&6; } +if ${ac_cv_path_GREP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$GREP"; then + ac_path_GREP_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in grep ggrep; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_GREP" || continue +# Check for GNU ac_path_GREP and select it if it is found. + # Check for GNU $ac_path_GREP +case `"$ac_path_GREP" --version 2>&1` in +*GNU*) + ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo 'GREP' >> "conftest.nl" + "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_GREP_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_GREP="$ac_path_GREP" + ac_path_GREP_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_GREP_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_GREP"; then + as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + fi +else + ac_cv_path_GREP=$GREP +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 +$as_echo "$ac_cv_path_GREP" >&6; } + GREP="$ac_cv_path_GREP" + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 +$as_echo_n "checking for egrep... " >&6; } +if ${ac_cv_path_EGREP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 + then ac_cv_path_EGREP="$GREP -E" + else + if test -z "$EGREP"; then + ac_path_EGREP_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in egrep; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_EGREP" || continue +# Check for GNU ac_path_EGREP and select it if it is found. + # Check for GNU $ac_path_EGREP +case `"$ac_path_EGREP" --version 2>&1` in +*GNU*) + ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo 'EGREP' >> "conftest.nl" + "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_EGREP_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_EGREP="$ac_path_EGREP" + ac_path_EGREP_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_EGREP_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_EGREP"; then + as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + fi +else + ac_cv_path_EGREP=$EGREP +fi + + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 +$as_echo "$ac_cv_path_EGREP" >&6; } + EGREP="$ac_cv_path_EGREP" + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 +$as_echo_n "checking for fgrep... " >&6; } +if ${ac_cv_path_FGREP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 + then ac_cv_path_FGREP="$GREP -F" + else + if test -z "$FGREP"; then + ac_path_FGREP_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in fgrep; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_FGREP" || continue +# Check for GNU ac_path_FGREP and select it if it is found. + # Check for GNU $ac_path_FGREP +case `"$ac_path_FGREP" --version 2>&1` in +*GNU*) + ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo 'FGREP' >> "conftest.nl" + "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_FGREP_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_FGREP="$ac_path_FGREP" + ac_path_FGREP_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_FGREP_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_FGREP"; then + as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + fi +else + ac_cv_path_FGREP=$FGREP +fi + + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 +$as_echo "$ac_cv_path_FGREP" >&6; } + FGREP="$ac_cv_path_FGREP" + + +test -z "$GREP" && GREP=grep + + + + + + + + + + + + + + + + + + + +# Check whether --with-gnu-ld was given. +if test "${with_gnu_ld+set}" = set; then : + withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes +else + with_gnu_ld=no +fi + +ac_prog=ld +if test yes = "$GCC"; then + # Check if gcc -print-prog-name=ld gives a path. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 +$as_echo_n "checking for ld used by $CC... " >&6; } + case $host in + *-*-mingw*) + # gcc leaves a trailing carriage return, which upsets mingw + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; + *) + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; + esac + case $ac_prog in + # Accept absolute paths. + [\\/]* | ?:[\\/]*) + re_direlt='/[^/][^/]*/\.\./' + # Canonicalize the pathname of ld + ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` + while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do + ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` + done + test -z "$LD" && LD=$ac_prog + ;; + "") + # If it fails, then pretend we aren't using GCC. + ac_prog=ld + ;; + *) + # If it is relative, then search for the first ld in PATH. + with_gnu_ld=unknown + ;; + esac +elif test yes = "$with_gnu_ld"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 +$as_echo_n "checking for GNU ld... " >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 +$as_echo_n "checking for non-GNU ld... " >&6; } +fi +if ${lt_cv_path_LD+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$LD"; then + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS=$lt_save_ifs + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then + lt_cv_path_LD=$ac_dir/$ac_prog + # Check to see if the program is GNU ld. I'd rather use --version, + # but apparently some variants of GNU ld only accept -v. + # Break only if it was the GNU/non-GNU ld that we prefer. + case `"$lt_cv_path_LD" -v 2>&1 &5 +$as_echo "$LD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi +test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 +$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } +if ${lt_cv_prog_gnu_ld+:} false; then : + $as_echo_n "(cached) " >&6 +else + # I'd rather use --version here, but apparently some GNU lds only accept -v. +case `$LD -v 2>&1 &5 +$as_echo "$lt_cv_prog_gnu_ld" >&6; } +with_gnu_ld=$lt_cv_prog_gnu_ld + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5 +$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; } +if ${lt_cv_path_NM+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$NM"; then + # Let the user override the test. + lt_cv_path_NM=$NM +else + lt_nm_to_check=${ac_tool_prefix}nm + if test -n "$ac_tool_prefix" && test "$build" = "$host"; then + lt_nm_to_check="$lt_nm_to_check nm" + fi + for lt_tmp_nm in $lt_nm_to_check; do + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR + for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do + IFS=$lt_save_ifs + test -z "$ac_dir" && ac_dir=. + tmp_nm=$ac_dir/$lt_tmp_nm + if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then + # Check to see if the nm accepts a BSD-compat flag. + # Adding the 'sed 1q' prevents false positives on HP-UX, which says: + # nm: unknown option "B" ignored + # Tru64's nm complains that /dev/null is an invalid object file + # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty + case $build_os in + mingw*) lt_bad_file=conftest.nm/nofile ;; + *) lt_bad_file=/dev/null ;; + esac + case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in + *$lt_bad_file* | *'Invalid file or object type'*) + lt_cv_path_NM="$tmp_nm -B" + break 2 + ;; + *) + case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in + */dev/null*) + lt_cv_path_NM="$tmp_nm -p" + break 2 + ;; + *) + lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but + continue # so that we can try to find one that supports BSD flags + ;; + esac + ;; + esac + fi + done + IFS=$lt_save_ifs + done + : ${lt_cv_path_NM=no} +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5 +$as_echo "$lt_cv_path_NM" >&6; } +if test no != "$lt_cv_path_NM"; then + NM=$lt_cv_path_NM +else + # Didn't find any BSD compatible name lister, look for dumpbin. + if test -n "$DUMPBIN"; then : + # Let the user override the test. + else + if test -n "$ac_tool_prefix"; then + for ac_prog in dumpbin "link -dump" + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DUMPBIN+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$DUMPBIN"; then + ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +DUMPBIN=$ac_cv_prog_DUMPBIN +if test -n "$DUMPBIN"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 +$as_echo "$DUMPBIN" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$DUMPBIN" && break + done +fi +if test -z "$DUMPBIN"; then + ac_ct_DUMPBIN=$DUMPBIN + for ac_prog in dumpbin "link -dump" +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_DUMPBIN"; then + ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_DUMPBIN="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN +if test -n "$ac_ct_DUMPBIN"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5 +$as_echo "$ac_ct_DUMPBIN" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$ac_ct_DUMPBIN" && break +done + + if test "x$ac_ct_DUMPBIN" = x; then + DUMPBIN=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + DUMPBIN=$ac_ct_DUMPBIN + fi +fi + + case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in + *COFF*) + DUMPBIN="$DUMPBIN -symbols -headers" + ;; + *) + DUMPBIN=: + ;; + esac + fi + + if test : != "$DUMPBIN"; then + NM=$DUMPBIN + fi +fi +test -z "$NM" && NM=nm + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5 +$as_echo_n "checking the name lister ($NM) interface... " >&6; } +if ${lt_cv_nm_interface+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_nm_interface="BSD nm" + echo "int some_variable = 0;" > conftest.$ac_ext + (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5) + (eval "$ac_compile" 2>conftest.err) + cat conftest.err >&5 + (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5) + (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) + cat conftest.err >&5 + (eval echo "\"\$as_me:$LINENO: output\"" >&5) + cat conftest.out >&5 + if $GREP 'External.*some_variable' conftest.out > /dev/null; then + lt_cv_nm_interface="MS dumpbin" + fi + rm -f conftest* +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5 +$as_echo "$lt_cv_nm_interface" >&6; } + +# find the maximum length of command line arguments +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 +$as_echo_n "checking the maximum length of command line arguments... " >&6; } +if ${lt_cv_sys_max_cmd_len+:} false; then : + $as_echo_n "(cached) " >&6 +else + i=0 + teststring=ABCD + + case $build_os in + msdosdjgpp*) + # On DJGPP, this test can blow up pretty badly due to problems in libc + # (any single argument exceeding 2000 bytes causes a buffer overrun + # during glob expansion). Even if it were fixed, the result of this + # check would be larger than it should be. + lt_cv_sys_max_cmd_len=12288; # 12K is about right + ;; + + gnu*) + # Under GNU Hurd, this test is not required because there is + # no limit to the length of command line arguments. + # Libtool will interpret -1 as no limit whatsoever + lt_cv_sys_max_cmd_len=-1; + ;; + + cygwin* | mingw* | cegcc*) + # On Win9x/ME, this test blows up -- it succeeds, but takes + # about 5 minutes as the teststring grows exponentially. + # Worse, since 9x/ME are not pre-emptively multitasking, + # you end up with a "frozen" computer, even though with patience + # the test eventually succeeds (with a max line length of 256k). + # Instead, let's just punt: use the minimum linelength reported by + # all of the supported platforms: 8192 (on NT/2K/XP). + lt_cv_sys_max_cmd_len=8192; + ;; + + mint*) + # On MiNT this can take a long time and run out of memory. + lt_cv_sys_max_cmd_len=8192; + ;; + + amigaos*) + # On AmigaOS with pdksh, this test takes hours, literally. + # So we just punt and use a minimum line length of 8192. + lt_cv_sys_max_cmd_len=8192; + ;; + + bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*) + # This has been around since 386BSD, at least. Likely further. + if test -x /sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` + elif test -x /usr/sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` + else + lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs + fi + # And add a safety zone + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + ;; + + interix*) + # We know the value 262144 and hardcode it with a safety zone (like BSD) + lt_cv_sys_max_cmd_len=196608 + ;; + + os2*) + # The test takes a long time on OS/2. + lt_cv_sys_max_cmd_len=8192 + ;; + + osf*) + # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure + # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not + # nice to cause kernel panics so lets avoid the loop below. + # First set a reasonable default. + lt_cv_sys_max_cmd_len=16384 + # + if test -x /sbin/sysconfig; then + case `/sbin/sysconfig -q proc exec_disable_arg_limit` in + *1*) lt_cv_sys_max_cmd_len=-1 ;; + esac + fi + ;; + sco3.2v5*) + lt_cv_sys_max_cmd_len=102400 + ;; + sysv5* | sco5v6* | sysv4.2uw2*) + kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` + if test -n "$kargmax"; then + lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'` + else + lt_cv_sys_max_cmd_len=32768 + fi + ;; + *) + lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` + if test -n "$lt_cv_sys_max_cmd_len" && \ + test undefined != "$lt_cv_sys_max_cmd_len"; then + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + else + # Make teststring a little bigger before we do anything with it. + # a 1K string should be a reasonable start. + for i in 1 2 3 4 5 6 7 8; do + teststring=$teststring$teststring + done + SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} + # If test is not a shell built-in, we'll probably end up computing a + # maximum length that is only half of the actual maximum length, but + # we can't tell. + while { test X`env echo "$teststring$teststring" 2>/dev/null` \ + = "X$teststring$teststring"; } >/dev/null 2>&1 && + test 17 != "$i" # 1/2 MB should be enough + do + i=`expr $i + 1` + teststring=$teststring$teststring + done + # Only check the string length outside the loop. + lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` + teststring= + # Add a significant safety factor because C++ compilers can tack on + # massive amounts of additional arguments before passing them to the + # linker. It appears as though 1/2 is a usable value. + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` + fi + ;; + esac + +fi + +if test -n "$lt_cv_sys_max_cmd_len"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 +$as_echo "$lt_cv_sys_max_cmd_len" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 +$as_echo "none" >&6; } +fi +max_cmd_len=$lt_cv_sys_max_cmd_len + + + + + + +: ${CP="cp -f"} +: ${MV="mv -f"} +: ${RM="rm -f"} + +if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then + lt_unset=unset +else + lt_unset=false +fi + + + + + +# test EBCDIC or ASCII +case `echo X|tr X '\101'` in + A) # ASCII based system + # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr + lt_SP2NL='tr \040 \012' + lt_NL2SP='tr \015\012 \040\040' + ;; + *) # EBCDIC based system + lt_SP2NL='tr \100 \n' + lt_NL2SP='tr \r\n \100\100' + ;; +esac + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5 +$as_echo_n "checking how to convert $build file names to $host format... " >&6; } +if ${lt_cv_to_host_file_cmd+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 + ;; + esac + ;; + *-*-cygwin* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin + ;; + esac + ;; + * ) # unhandled hosts (and "normal" native builds) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; +esac + +fi + +to_host_file_cmd=$lt_cv_to_host_file_cmd +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5 +$as_echo "$lt_cv_to_host_file_cmd" >&6; } + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5 +$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; } +if ${lt_cv_to_tool_file_cmd+:} false; then : + $as_echo_n "(cached) " >&6 +else + #assume ordinary cross tools, or native build. +lt_cv_to_tool_file_cmd=func_convert_file_noop +case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 + ;; + esac + ;; +esac + +fi + +to_tool_file_cmd=$lt_cv_to_tool_file_cmd +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5 +$as_echo "$lt_cv_to_tool_file_cmd" >&6; } + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 +$as_echo_n "checking for $LD option to reload object files... " >&6; } +if ${lt_cv_ld_reload_flag+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ld_reload_flag='-r' +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5 +$as_echo "$lt_cv_ld_reload_flag" >&6; } +reload_flag=$lt_cv_ld_reload_flag +case $reload_flag in +"" | " "*) ;; +*) reload_flag=" $reload_flag" ;; +esac +reload_cmds='$LD$reload_flag -o $output$reload_objs' +case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + if test yes != "$GCC"; then + reload_cmds=false + fi + ;; + darwin*) + if test yes = "$GCC"; then + reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs' + else + reload_cmds='$LD$reload_flag -o $output$reload_objs' + fi + ;; +esac + + + + + + + + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. +set dummy ${ac_tool_prefix}objdump; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_OBJDUMP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$OBJDUMP"; then + ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +OBJDUMP=$ac_cv_prog_OBJDUMP +if test -n "$OBJDUMP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 +$as_echo "$OBJDUMP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_OBJDUMP"; then + ac_ct_OBJDUMP=$OBJDUMP + # Extract the first word of "objdump", so it can be a program name with args. +set dummy objdump; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_OBJDUMP"; then + ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_OBJDUMP="objdump" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP +if test -n "$ac_ct_OBJDUMP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 +$as_echo "$ac_ct_OBJDUMP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_OBJDUMP" = x; then + OBJDUMP="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + OBJDUMP=$ac_ct_OBJDUMP + fi +else + OBJDUMP="$ac_cv_prog_OBJDUMP" +fi + +test -z "$OBJDUMP" && OBJDUMP=objdump + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5 +$as_echo_n "checking how to recognize dependent libraries... " >&6; } +if ${lt_cv_deplibs_check_method+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_file_magic_cmd='$MAGIC_CMD' +lt_cv_file_magic_test_file= +lt_cv_deplibs_check_method='unknown' +# Need to set the preceding variable on all platforms that support +# interlibrary dependencies. +# 'none' -- dependencies not supported. +# 'unknown' -- same as none, but documents that we really don't know. +# 'pass_all' -- all dependencies passed with no checks. +# 'test_compile' -- check by making test program. +# 'file_magic [[regex]]' -- check by looking for files in library path +# that responds to the $file_magic_cmd with a given extended regex. +# If you have 'file' or equivalent on your system and you're not sure +# whether 'pass_all' will *always* work, you probably want this one. + +case $host_os in +aix[4-9]*) + lt_cv_deplibs_check_method=pass_all + ;; + +beos*) + lt_cv_deplibs_check_method=pass_all + ;; + +bsdi[45]*) + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' + lt_cv_file_magic_cmd='/usr/bin/file -L' + lt_cv_file_magic_test_file=/shlib/libc.so + ;; + +cygwin*) + # func_win32_libid is a shell function defined in ltmain.sh + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + ;; + +mingw* | pw32*) + # Base MSYS/MinGW do not provide the 'file' command needed by + # func_win32_libid shell function, so use a weaker test based on 'objdump', + # unless we find 'file', for example because we are cross-compiling. + if ( file / ) >/dev/null 2>&1; then + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + else + # Keep this pattern in sync with the one in func_win32_libid. + lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' + lt_cv_file_magic_cmd='$OBJDUMP -f' + fi + ;; + +cegcc*) + # use the weaker test based on 'objdump'. See mingw*. + lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' + lt_cv_file_magic_cmd='$OBJDUMP -f' + ;; + +darwin* | rhapsody*) + lt_cv_deplibs_check_method=pass_all + ;; + +freebsd* | dragonfly*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then + case $host_cpu in + i*86 ) + # Not sure whether the presence of OpenBSD here was a mistake. + # Let's accept both of them until this is cleared up. + lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` + ;; + esac + else + lt_cv_deplibs_check_method=pass_all + fi + ;; + +haiku*) + lt_cv_deplibs_check_method=pass_all + ;; + +hpux10.20* | hpux11*) + lt_cv_file_magic_cmd=/usr/bin/file + case $host_cpu in + ia64*) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' + lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so + ;; + hppa*64*) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]' + lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl + ;; + *) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library' + lt_cv_file_magic_test_file=/usr/lib/libc.sl + ;; + esac + ;; + +interix[3-9]*) + # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$' + ;; + +irix5* | irix6* | nonstopux*) + case $LD in + *-32|*"-32 ") libmagic=32-bit;; + *-n32|*"-n32 ") libmagic=N32;; + *-64|*"-64 ") libmagic=64-bit;; + *) libmagic=never-match;; + esac + lt_cv_deplibs_check_method=pass_all + ;; + +# This must be glibc/ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + lt_cv_deplibs_check_method=pass_all + ;; + +netbsd* | netbsdelf*-gnu) + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' + fi + ;; + +newos6*) + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=/usr/lib/libnls.so + ;; + +*nto* | *qnx*) + lt_cv_deplibs_check_method=pass_all + ;; + +openbsd* | bitrig*) + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' + fi + ;; + +osf3* | osf4* | osf5*) + lt_cv_deplibs_check_method=pass_all + ;; + +rdos*) + lt_cv_deplibs_check_method=pass_all + ;; + +solaris*) + lt_cv_deplibs_check_method=pass_all + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + lt_cv_deplibs_check_method=pass_all + ;; + +sysv4 | sysv4.3*) + case $host_vendor in + motorola) + 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]' + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` + ;; + ncr) + lt_cv_deplibs_check_method=pass_all + ;; + sequent) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' + ;; + sni) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib" + lt_cv_file_magic_test_file=/lib/libc.so + ;; + siemens) + lt_cv_deplibs_check_method=pass_all + ;; + pc) + lt_cv_deplibs_check_method=pass_all + ;; + esac + ;; + +tpf*) + lt_cv_deplibs_check_method=pass_all + ;; +os2*) + lt_cv_deplibs_check_method=pass_all + ;; +esac + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 +$as_echo "$lt_cv_deplibs_check_method" >&6; } + +file_magic_glob= +want_nocaseglob=no +if test "$build" = "$host"; then + case $host_os in + mingw* | pw32*) + if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then + want_nocaseglob=yes + else + file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"` + fi + ;; + esac +fi + +file_magic_cmd=$lt_cv_file_magic_cmd +deplibs_check_method=$lt_cv_deplibs_check_method +test -z "$deplibs_check_method" && deplibs_check_method=unknown + + + + + + + + + + + + + + + + + + + + + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. +set dummy ${ac_tool_prefix}dlltool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DLLTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$DLLTOOL"; then + ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +DLLTOOL=$ac_cv_prog_DLLTOOL +if test -n "$DLLTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 +$as_echo "$DLLTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_DLLTOOL"; then + ac_ct_DLLTOOL=$DLLTOOL + # Extract the first word of "dlltool", so it can be a program name with args. +set dummy dlltool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_DLLTOOL"; then + ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_DLLTOOL="dlltool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL +if test -n "$ac_ct_DLLTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 +$as_echo "$ac_ct_DLLTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_DLLTOOL" = x; then + DLLTOOL="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + DLLTOOL=$ac_ct_DLLTOOL + fi +else + DLLTOOL="$ac_cv_prog_DLLTOOL" +fi + +test -z "$DLLTOOL" && DLLTOOL=dlltool + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5 +$as_echo_n "checking how to associate runtime and link libraries... " >&6; } +if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_sharedlib_from_linklib_cmd='unknown' + +case $host_os in +cygwin* | mingw* | pw32* | cegcc*) + # two different shell functions defined in ltmain.sh; + # decide which one to use based on capabilities of $DLLTOOL + case `$DLLTOOL --help 2>&1` in + *--identify-strict*) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib + ;; + *) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback + ;; + esac + ;; +*) + # fallback: assume linklib IS sharedlib + lt_cv_sharedlib_from_linklib_cmd=$ECHO + ;; +esac + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5 +$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; } +sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd +test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO + + + + + + + + +if test -n "$ac_tool_prefix"; then + for ac_prog in ar + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_AR+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$AR"; then + ac_cv_prog_AR="$AR" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_AR="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +AR=$ac_cv_prog_AR +if test -n "$AR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 +$as_echo "$AR" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$AR" && break + done +fi +if test -z "$AR"; then + ac_ct_AR=$AR + for ac_prog in ar +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_AR+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_AR"; then + ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_AR="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_AR=$ac_cv_prog_ac_ct_AR +if test -n "$ac_ct_AR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 +$as_echo "$ac_ct_AR" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$ac_ct_AR" && break +done + + if test "x$ac_ct_AR" = x; then + AR="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + AR=$ac_ct_AR + fi +fi + +: ${AR=ar} +: ${AR_FLAGS=cru} + + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5 +$as_echo_n "checking for archiver @FILE support... " >&6; } +if ${lt_cv_ar_at_file+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ar_at_file=no + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + echo conftest.$ac_objext > conftest.lst + lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 + (eval $lt_ar_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if test 0 -eq "$ac_status"; then + # Ensure the archiver fails upon bogus file names. + rm -f conftest.$ac_objext libconftest.a + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 + (eval $lt_ar_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if test 0 -ne "$ac_status"; then + lt_cv_ar_at_file=@ + fi + fi + rm -f conftest.* libconftest.a + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5 +$as_echo "$lt_cv_ar_at_file" >&6; } + +if test no = "$lt_cv_ar_at_file"; then + archiver_list_spec= +else + archiver_list_spec=$lt_cv_ar_at_file +fi + + + + + + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. +set dummy ${ac_tool_prefix}strip; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_STRIP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$STRIP"; then + ac_cv_prog_STRIP="$STRIP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_STRIP="${ac_tool_prefix}strip" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +STRIP=$ac_cv_prog_STRIP +if test -n "$STRIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 +$as_echo "$STRIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_STRIP"; then + ac_ct_STRIP=$STRIP + # Extract the first word of "strip", so it can be a program name with args. +set dummy strip; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_STRIP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_STRIP"; then + ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_STRIP="strip" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP +if test -n "$ac_ct_STRIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 +$as_echo "$ac_ct_STRIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_STRIP" = x; then + STRIP=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + STRIP=$ac_ct_STRIP + fi +else + STRIP="$ac_cv_prog_STRIP" +fi + +test -z "$STRIP" && STRIP=: + + + + + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. +set dummy ${ac_tool_prefix}ranlib; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_RANLIB+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$RANLIB"; then + ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +RANLIB=$ac_cv_prog_RANLIB +if test -n "$RANLIB"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 +$as_echo "$RANLIB" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_RANLIB"; then + ac_ct_RANLIB=$RANLIB + # Extract the first word of "ranlib", so it can be a program name with args. +set dummy ranlib; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_RANLIB"; then + ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_RANLIB="ranlib" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB +if test -n "$ac_ct_RANLIB"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 +$as_echo "$ac_ct_RANLIB" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_RANLIB" = x; then + RANLIB=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + RANLIB=$ac_ct_RANLIB + fi +else + RANLIB="$ac_cv_prog_RANLIB" +fi + +test -z "$RANLIB" && RANLIB=: + + + + + + +# Determine commands to create old-style static archives. +old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' +old_postinstall_cmds='chmod 644 $oldlib' +old_postuninstall_cmds= + +if test -n "$RANLIB"; then + case $host_os in + bitrig* | openbsd*) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" + ;; + *) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" + ;; + esac + old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" +fi + +case $host_os in + darwin*) + lock_old_archive_extraction=yes ;; + *) + lock_old_archive_extraction=no ;; +esac + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} + +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC + + +# Check for command to grab the raw symbol name followed by C symbol from nm. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5 +$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; } +if ${lt_cv_sys_global_symbol_pipe+:} false; then : + $as_echo_n "(cached) " >&6 +else + +# These are sane defaults that work on at least a few old systems. +# [They come from Ultrix. What could be older than Ultrix?!! ;)] + +# Character class describing NM global symbol codes. +symcode='[BCDEGRST]' + +# Regexp to match symbols that can be accessed directly from C. +sympat='\([_A-Za-z][_A-Za-z0-9]*\)' + +# Define system-specific variables. +case $host_os in +aix*) + symcode='[BCDT]' + ;; +cygwin* | mingw* | pw32* | cegcc*) + symcode='[ABCDGISTW]' + ;; +hpux*) + if test ia64 = "$host_cpu"; then + symcode='[ABCDEGRST]' + fi + ;; +irix* | nonstopux*) + symcode='[BCDEGRST]' + ;; +osf*) + symcode='[BCDEGQRST]' + ;; +solaris*) + symcode='[BDRT]' + ;; +sco3.2v5*) + symcode='[DT]' + ;; +sysv4.2uw2*) + symcode='[DT]' + ;; +sysv5* | sco5v6* | unixware* | OpenUNIX*) + symcode='[ABDT]' + ;; +sysv4) + symcode='[DFNSTU]' + ;; +esac + +# If we're using GNU nm, then use its standard symbol codes. +case `$NM -V 2>&1` in +*GNU* | *'with BFD'*) + symcode='[ABCDGIRSTW]' ;; +esac + +if test "$lt_cv_nm_interface" = "MS dumpbin"; then + # Gets list of data symbols to import. + lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'" + # Adjust the below global symbol transforms to fixup imported variables. + lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'" + lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'" + lt_c_name_lib_hook="\ + -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\ + -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'" +else + # Disable hooks by default. + lt_cv_sys_global_symbol_to_import= + lt_cdecl_hook= + lt_c_name_hook= + lt_c_name_lib_hook= +fi + +# Transform an extracted symbol line into a proper C declaration. +# Some systems (esp. on ia64) link data and code symbols differently, +# so use this general approach. +lt_cv_sys_global_symbol_to_cdecl="sed -n"\ +$lt_cdecl_hook\ +" -e 's/^T .* \(.*\)$/extern int \1();/p'"\ +" -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'" + +# Transform an extracted symbol line into symbol name and symbol address +lt_cv_sys_global_symbol_to_c_name_address="sed -n"\ +$lt_c_name_hook\ +" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ +" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'" + +# Transform an extracted symbol line into symbol name with lib prefix and +# symbol address. +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\ +$lt_c_name_lib_hook\ +" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ +" -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\ +" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'" + +# Handle CRLF in mingw tool chain +opt_cr= +case $build_os in +mingw*) + opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp + ;; +esac + +# Try without a prefix underscore, then with it. +for ac_symprfx in "" "_"; do + + # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. + symxfrm="\\1 $ac_symprfx\\2 \\2" + + # Write the raw and C identifiers. + if test "$lt_cv_nm_interface" = "MS dumpbin"; then + # Fake it for dumpbin and say T for any non-static function, + # D for any global variable and I for any imported variable. + # Also find C++ and __fastcall symbols from MSVC++, + # which start with @ or ?. + lt_cv_sys_global_symbol_pipe="$AWK '"\ +" {last_section=section; section=\$ 3};"\ +" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ +" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ +" /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\ +" /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\ +" /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\ +" \$ 0!~/External *\|/{next};"\ +" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ +" {if(hide[section]) next};"\ +" {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\ +" {split(\$ 0,a,/\||\r/); split(a[2],s)};"\ +" s[1]~/^[@?]/{print f,s[1],s[1]; next};"\ +" s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\ +" ' prfx=^$ac_symprfx" + else + lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" + fi + lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" + + # Check to see that the pipe works correctly. + pipe_works=no + + rm -f conftest* + cat > conftest.$ac_ext <<_LT_EOF +#ifdef __cplusplus +extern "C" { +#endif +char nm_test_var; +void nm_test_func(void); +void nm_test_func(void){} +#ifdef __cplusplus +} +#endif +int main(){nm_test_var='a';nm_test_func();return(0);} +_LT_EOF + + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + # Now try to grab the symbols. + nlist=conftest.nm + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5 + (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s "$nlist"; then + # Try sorting and uniquifying the output. + if sort "$nlist" | uniq > "$nlist"T; then + mv -f "$nlist"T "$nlist" + else + rm -f "$nlist"T + fi + + # Make sure that we snagged all the symbols we need. + if $GREP ' nm_test_var$' "$nlist" >/dev/null; then + if $GREP ' nm_test_func$' "$nlist" >/dev/null; then + cat <<_LT_EOF > conftest.$ac_ext +/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ +#if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE +/* DATA imports from DLLs on WIN32 can't be const, because runtime + relocations are performed -- see ld's documentation on pseudo-relocs. */ +# define LT_DLSYM_CONST +#elif defined __osf__ +/* This system does not cope well with relocations in const data. */ +# define LT_DLSYM_CONST +#else +# define LT_DLSYM_CONST const +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +_LT_EOF + # Now generate the symbol file. + eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' + + cat <<_LT_EOF >> conftest.$ac_ext + +/* The mapping between symbol names and symbols. */ +LT_DLSYM_CONST struct { + const char *name; + void *address; +} +lt__PROGRAM__LTX_preloaded_symbols[] = +{ + { "@PROGRAM@", (void *) 0 }, +_LT_EOF + $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext + cat <<\_LT_EOF >> conftest.$ac_ext + {0, (void *) 0} +}; + +/* This works around a problem in FreeBSD linker */ +#ifdef FREEBSD_WORKAROUND +static const void *lt_preloaded_setup() { + return lt__PROGRAM__LTX_preloaded_symbols; +} +#endif + +#ifdef __cplusplus +} +#endif +_LT_EOF + # Now try linking the two files. + mv conftest.$ac_objext conftstm.$ac_objext + lt_globsym_save_LIBS=$LIBS + lt_globsym_save_CFLAGS=$CFLAGS + LIBS=conftstm.$ac_objext + CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest$ac_exeext; then + pipe_works=yes + fi + LIBS=$lt_globsym_save_LIBS + CFLAGS=$lt_globsym_save_CFLAGS + else + echo "cannot find nm_test_func in $nlist" >&5 + fi + else + echo "cannot find nm_test_var in $nlist" >&5 + fi + else + echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 + fi + else + echo "$progname: failed program was:" >&5 + cat conftest.$ac_ext >&5 + fi + rm -rf conftest* conftst* + + # Do not use the global_symbol_pipe unless it works. + if test yes = "$pipe_works"; then + break + else + lt_cv_sys_global_symbol_pipe= + fi +done + +fi + +if test -z "$lt_cv_sys_global_symbol_pipe"; then + lt_cv_sys_global_symbol_to_cdecl= +fi +if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5 +$as_echo "failed" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 +$as_echo "ok" >&6; } +fi + +# Response file support. +if test "$lt_cv_nm_interface" = "MS dumpbin"; then + nm_file_list_spec='@' +elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then + nm_file_list_spec='@' +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 +$as_echo_n "checking for sysroot... " >&6; } + +# Check whether --with-sysroot was given. +if test "${with_sysroot+set}" = set; then : + withval=$with_sysroot; +else + with_sysroot=no +fi + + +lt_sysroot= +case $with_sysroot in #( + yes) + if test yes = "$GCC"; then + lt_sysroot=`$CC --print-sysroot 2>/dev/null` + fi + ;; #( + /*) + lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` + ;; #( + no|'') + ;; #( + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sysroot" >&5 +$as_echo "$with_sysroot" >&6; } + as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5 + ;; +esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5 +$as_echo "${lt_sysroot:-no}" >&6; } + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a working dd" >&5 +$as_echo_n "checking for a working dd... " >&6; } +if ${ac_cv_path_lt_DD+:} false; then : + $as_echo_n "(cached) " >&6 +else + printf 0123456789abcdef0123456789abcdef >conftest.i +cat conftest.i conftest.i >conftest2.i +: ${lt_DD:=$DD} +if test -z "$lt_DD"; then + ac_path_lt_DD_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in dd; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_lt_DD="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_lt_DD" || continue +if "$ac_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then + cmp -s conftest.i conftest.out \ + && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=: +fi + $ac_path_lt_DD_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_lt_DD"; then + : + fi +else + ac_cv_path_lt_DD=$lt_DD +fi + +rm -f conftest.i conftest2.i conftest.out +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_lt_DD" >&5 +$as_echo "$ac_cv_path_lt_DD" >&6; } + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to truncate binary pipes" >&5 +$as_echo_n "checking how to truncate binary pipes... " >&6; } +if ${lt_cv_truncate_bin+:} false; then : + $as_echo_n "(cached) " >&6 +else + printf 0123456789abcdef0123456789abcdef >conftest.i +cat conftest.i conftest.i >conftest2.i +lt_cv_truncate_bin= +if "$ac_cv_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then + cmp -s conftest.i conftest.out \ + && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1" +fi +rm -f conftest.i conftest2.i conftest.out +test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q" +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_truncate_bin" >&5 +$as_echo "$lt_cv_truncate_bin" >&6; } + + + + + + + +# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. +func_cc_basename () +{ + for cc_temp in $*""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac + done + func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` +} + +# Check whether --enable-libtool-lock was given. +if test "${enable_libtool_lock+set}" = set; then : + enableval=$enable_libtool_lock; +fi + +test no = "$enable_libtool_lock" || enable_libtool_lock=yes + +# Some flags need to be propagated to the compiler or linker for good +# libtool support. +case $host in +ia64-*-hpux*) + # Find out what ABI is being produced by ac_compile, and set mode + # options accordingly. + echo 'int i;' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + case `/usr/bin/file conftest.$ac_objext` in + *ELF-32*) + HPUX_IA64_MODE=32 + ;; + *ELF-64*) + HPUX_IA64_MODE=64 + ;; + esac + fi + rm -rf conftest* + ;; +*-*-irix6*) + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. + echo '#line '$LINENO' "configure"' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + if test yes = "$lt_cv_prog_gnu_ld"; then + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -melf32bsmip" + ;; + *N32*) + LD="${LD-ld} -melf32bmipn32" + ;; + *64-bit*) + LD="${LD-ld} -melf64bmip" + ;; + esac + else + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -32" + ;; + *N32*) + LD="${LD-ld} -n32" + ;; + *64-bit*) + LD="${LD-ld} -64" + ;; + esac + fi + fi + rm -rf conftest* + ;; + +mips64*-*linux*) + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. + echo '#line '$LINENO' "configure"' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + emul=elf + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + emul="${emul}32" + ;; + *64-bit*) + emul="${emul}64" + ;; + esac + case `/usr/bin/file conftest.$ac_objext` in + *MSB*) + emul="${emul}btsmip" + ;; + *LSB*) + emul="${emul}ltsmip" + ;; + esac + case `/usr/bin/file conftest.$ac_objext` in + *N32*) + emul="${emul}n32" + ;; + esac + LD="${LD-ld} -m $emul" + fi + rm -rf conftest* + ;; + +x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ +s390*-*linux*|s390*-*tpf*|sparc*-*linux*) + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. Note that the listed cases only cover the + # situations where additional linker options are needed (such as when + # doing 32-bit compilation for a host where ld defaults to 64-bit, or + # vice versa); the common cases where no linker options are needed do + # not appear in the list. + echo 'int i;' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + case `/usr/bin/file conftest.o` in + *32-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_i386_fbsd" + ;; + x86_64-*linux*) + case `/usr/bin/file conftest.o` in + *x86-64*) + LD="${LD-ld} -m elf32_x86_64" + ;; + *) + LD="${LD-ld} -m elf_i386" + ;; + esac + ;; + powerpc64le-*linux*) + LD="${LD-ld} -m elf32lppclinux" + ;; + powerpc64-*linux*) + LD="${LD-ld} -m elf32ppclinux" + ;; + s390x-*linux*) + LD="${LD-ld} -m elf_s390" + ;; + sparc64-*linux*) + LD="${LD-ld} -m elf32_sparc" + ;; + esac + ;; + *64-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_x86_64_fbsd" + ;; + x86_64-*linux*) + LD="${LD-ld} -m elf_x86_64" + ;; + powerpcle-*linux*) + LD="${LD-ld} -m elf64lppc" + ;; + powerpc-*linux*) + LD="${LD-ld} -m elf64ppc" + ;; + s390*-*linux*|s390*-*tpf*) + LD="${LD-ld} -m elf64_s390" + ;; + sparc*-*linux*) + LD="${LD-ld} -m elf64_sparc" + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; + +*-*-sco3.2v5*) + # On SCO OpenServer 5, we need -belf to get full-featured binaries. + SAVE_CFLAGS=$CFLAGS + CFLAGS="$CFLAGS -belf" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5 +$as_echo_n "checking whether the C compiler needs -belf... " >&6; } +if ${lt_cv_cc_needs_belf+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + lt_cv_cc_needs_belf=yes +else + lt_cv_cc_needs_belf=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5 +$as_echo "$lt_cv_cc_needs_belf" >&6; } + if test yes != "$lt_cv_cc_needs_belf"; then + # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf + CFLAGS=$SAVE_CFLAGS + fi + ;; +*-*solaris*) + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. + echo 'int i;' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + case `/usr/bin/file conftest.o` in + *64-bit*) + case $lt_cv_prog_gnu_ld in + yes*) + case $host in + i?86-*-solaris*|x86_64-*-solaris*) + LD="${LD-ld} -m elf_x86_64" + ;; + sparc*-*-solaris*) + LD="${LD-ld} -m elf64_sparc" + ;; + esac + # GNU ld 2.21 introduced _sol2 emulations. Use them if available. + if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then + LD=${LD-ld}_sol2 + fi + ;; + *) + if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then + LD="${LD-ld} -64" + fi + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; +esac + +need_locks=$enable_libtool_lock + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args. +set dummy ${ac_tool_prefix}mt; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_MANIFEST_TOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$MANIFEST_TOOL"; then + ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL +if test -n "$MANIFEST_TOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5 +$as_echo "$MANIFEST_TOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_MANIFEST_TOOL"; then + ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL + # Extract the first word of "mt", so it can be a program name with args. +set dummy mt; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_MANIFEST_TOOL"; then + ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_MANIFEST_TOOL="mt" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL +if test -n "$ac_ct_MANIFEST_TOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5 +$as_echo "$ac_ct_MANIFEST_TOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_MANIFEST_TOOL" = x; then + MANIFEST_TOOL=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL + fi +else + MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL" +fi + +test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5 +$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; } +if ${lt_cv_path_mainfest_tool+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_path_mainfest_tool=no + echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5 + $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out + cat conftest.err >&5 + if $GREP 'Manifest Tool' conftest.out > /dev/null; then + lt_cv_path_mainfest_tool=yes + fi + rm -f conftest* +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5 +$as_echo "$lt_cv_path_mainfest_tool" >&6; } +if test yes != "$lt_cv_path_mainfest_tool"; then + MANIFEST_TOOL=: +fi + + + + + + + case $host_os in + rhapsody* | darwin*) + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args. +set dummy ${ac_tool_prefix}dsymutil; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DSYMUTIL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$DSYMUTIL"; then + ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +DSYMUTIL=$ac_cv_prog_DSYMUTIL +if test -n "$DSYMUTIL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 +$as_echo "$DSYMUTIL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_DSYMUTIL"; then + ac_ct_DSYMUTIL=$DSYMUTIL + # Extract the first word of "dsymutil", so it can be a program name with args. +set dummy dsymutil; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_DSYMUTIL"; then + ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_DSYMUTIL="dsymutil" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL +if test -n "$ac_ct_DSYMUTIL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5 +$as_echo "$ac_ct_DSYMUTIL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_DSYMUTIL" = x; then + DSYMUTIL=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + DSYMUTIL=$ac_ct_DSYMUTIL + fi +else + DSYMUTIL="$ac_cv_prog_DSYMUTIL" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args. +set dummy ${ac_tool_prefix}nmedit; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_NMEDIT+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$NMEDIT"; then + ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +NMEDIT=$ac_cv_prog_NMEDIT +if test -n "$NMEDIT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5 +$as_echo "$NMEDIT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_NMEDIT"; then + ac_ct_NMEDIT=$NMEDIT + # Extract the first word of "nmedit", so it can be a program name with args. +set dummy nmedit; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_NMEDIT"; then + ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_NMEDIT="nmedit" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT +if test -n "$ac_ct_NMEDIT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5 +$as_echo "$ac_ct_NMEDIT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_NMEDIT" = x; then + NMEDIT=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + NMEDIT=$ac_ct_NMEDIT + fi +else + NMEDIT="$ac_cv_prog_NMEDIT" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args. +set dummy ${ac_tool_prefix}lipo; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_LIPO+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$LIPO"; then + ac_cv_prog_LIPO="$LIPO" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_LIPO="${ac_tool_prefix}lipo" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +LIPO=$ac_cv_prog_LIPO +if test -n "$LIPO"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 +$as_echo "$LIPO" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_LIPO"; then + ac_ct_LIPO=$LIPO + # Extract the first word of "lipo", so it can be a program name with args. +set dummy lipo; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_LIPO+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_LIPO"; then + ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_LIPO="lipo" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO +if test -n "$ac_ct_LIPO"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5 +$as_echo "$ac_ct_LIPO" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_LIPO" = x; then + LIPO=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + LIPO=$ac_ct_LIPO + fi +else + LIPO="$ac_cv_prog_LIPO" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args. +set dummy ${ac_tool_prefix}otool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_OTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$OTOOL"; then + ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_OTOOL="${ac_tool_prefix}otool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +OTOOL=$ac_cv_prog_OTOOL +if test -n "$OTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 +$as_echo "$OTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_OTOOL"; then + ac_ct_OTOOL=$OTOOL + # Extract the first word of "otool", so it can be a program name with args. +set dummy otool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_OTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_OTOOL"; then + ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_OTOOL="otool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL +if test -n "$ac_ct_OTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5 +$as_echo "$ac_ct_OTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_OTOOL" = x; then + OTOOL=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + OTOOL=$ac_ct_OTOOL + fi +else + OTOOL="$ac_cv_prog_OTOOL" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args. +set dummy ${ac_tool_prefix}otool64; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_OTOOL64+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$OTOOL64"; then + ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +OTOOL64=$ac_cv_prog_OTOOL64 +if test -n "$OTOOL64"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5 +$as_echo "$OTOOL64" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_OTOOL64"; then + ac_ct_OTOOL64=$OTOOL64 + # Extract the first word of "otool64", so it can be a program name with args. +set dummy otool64; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_OTOOL64"; then + ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_OTOOL64="otool64" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64 +if test -n "$ac_ct_OTOOL64"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5 +$as_echo "$ac_ct_OTOOL64" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_OTOOL64" = x; then + OTOOL64=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + OTOOL64=$ac_ct_OTOOL64 + fi +else + OTOOL64="$ac_cv_prog_OTOOL64" +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5 +$as_echo_n "checking for -single_module linker flag... " >&6; } +if ${lt_cv_apple_cc_single_mod+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_apple_cc_single_mod=no + if test -z "$LT_MULTI_MODULE"; then + # By default we will add the -single_module flag. You can override + # by either setting the environment variable LT_MULTI_MODULE + # non-empty at configure time, or by adding -multi_module to the + # link flags. + rm -rf libconftest.dylib* + echo "int foo(void){return 1;}" > conftest.c + echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ +-dynamiclib -Wl,-single_module conftest.c" >&5 + $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ + -dynamiclib -Wl,-single_module conftest.c 2>conftest.err + _lt_result=$? + # If there is a non-empty error log, and "single_module" + # appears in it, assume the flag caused a linker warning + if test -s conftest.err && $GREP single_module conftest.err; then + cat conftest.err >&5 + # Otherwise, if the output was created with a 0 exit code from + # the compiler, it worked. + elif test -f libconftest.dylib && test 0 = "$_lt_result"; then + lt_cv_apple_cc_single_mod=yes + else + cat conftest.err >&5 + fi + rm -rf libconftest.dylib* + rm -f conftest.* + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5 +$as_echo "$lt_cv_apple_cc_single_mod" >&6; } + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5 +$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; } +if ${lt_cv_ld_exported_symbols_list+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ld_exported_symbols_list=no + save_LDFLAGS=$LDFLAGS + echo "_main" > conftest.sym + LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + lt_cv_ld_exported_symbols_list=yes +else + lt_cv_ld_exported_symbols_list=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS=$save_LDFLAGS + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5 +$as_echo "$lt_cv_ld_exported_symbols_list" >&6; } + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5 +$as_echo_n "checking for -force_load linker flag... " >&6; } +if ${lt_cv_ld_force_load+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ld_force_load=no + cat > conftest.c << _LT_EOF +int forced_loaded() { return 2;} +_LT_EOF + echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5 + $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5 + echo "$AR cru libconftest.a conftest.o" >&5 + $AR cru libconftest.a conftest.o 2>&5 + echo "$RANLIB libconftest.a" >&5 + $RANLIB libconftest.a 2>&5 + cat > conftest.c << _LT_EOF +int main() { return 0;} +_LT_EOF + echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5 + $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err + _lt_result=$? + if test -s conftest.err && $GREP force_load conftest.err; then + cat conftest.err >&5 + elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then + lt_cv_ld_force_load=yes + else + cat conftest.err >&5 + fi + rm -f conftest.err libconftest.a conftest conftest.c + rm -rf conftest.dSYM + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5 +$as_echo "$lt_cv_ld_force_load" >&6; } + case $host_os in + rhapsody* | darwin1.[012]) + _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; + darwin1.*) + _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; + darwin*) # darwin 5.x on + # if running on 10.5 or later, the deployment target defaults + # to the OS version, if on x86, and 10.4, the deployment + # target defaults to 10.4. Don't you love it? + case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in + 10.0,*86*-darwin8*|10.0,*-darwin[91]*) + _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; + 10.[012][,.]*) + _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; + 10.*) + _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; + esac + ;; + esac + if test yes = "$lt_cv_apple_cc_single_mod"; then + _lt_dar_single_mod='$single_module' + fi + if test yes = "$lt_cv_ld_exported_symbols_list"; then + _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym' + else + _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib' + fi + if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then + _lt_dsymutil='~$DSYMUTIL $lib || :' + else + _lt_dsymutil= + fi + ;; + esac + +# func_munge_path_list VARIABLE PATH +# ----------------------------------- +# VARIABLE is name of variable containing _space_ separated list of +# directories to be munged by the contents of PATH, which is string +# having a format: +# "DIR[:DIR]:" +# string "DIR[ DIR]" will be prepended to VARIABLE +# ":DIR[:DIR]" +# string "DIR[ DIR]" will be appended to VARIABLE +# "DIRP[:DIRP]::[DIRA:]DIRA" +# string "DIRP[ DIRP]" will be prepended to VARIABLE and string +# "DIRA[ DIRA]" will be appended to VARIABLE +# "DIR[:DIR]" +# VARIABLE will be replaced by "DIR[ DIR]" +func_munge_path_list () +{ + case x$2 in + x) + ;; + *:) + eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\" + ;; + x:*) + eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\" + ;; + *::*) + eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" + eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\" + ;; + *) + eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\" + ;; + esac +} + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 +$as_echo_n "checking for ANSI C header files... " >&6; } +if ${ac_cv_header_stdc+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#include +#include + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_header_stdc=yes +else + ac_cv_header_stdc=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +if test $ac_cv_header_stdc = yes; then + # SunOS 4.x string.h does not declare mem*, contrary to ANSI. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "memchr" >/dev/null 2>&1; then : + +else + ac_cv_header_stdc=no +fi +rm -f conftest* + +fi + +if test $ac_cv_header_stdc = yes; then + # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "free" >/dev/null 2>&1; then : + +else + ac_cv_header_stdc=no +fi +rm -f conftest* + +fi + +if test $ac_cv_header_stdc = yes; then + # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. + if test "$cross_compiling" = yes; then : + : +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#if ((' ' & 0x0FF) == 0x020) +# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') +# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) +#else +# define ISLOWER(c) \ + (('a' <= (c) && (c) <= 'i') \ + || ('j' <= (c) && (c) <= 'r') \ + || ('s' <= (c) && (c) <= 'z')) +# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) +#endif + +#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) +int +main () +{ + int i; + for (i = 0; i < 256; i++) + if (XOR (islower (i), ISLOWER (i)) + || toupper (i) != TOUPPER (i)) + return 2; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + +else + ac_cv_header_stdc=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 +$as_echo "$ac_cv_header_stdc" >&6; } +if test $ac_cv_header_stdc = yes; then + +$as_echo "#define STDC_HEADERS 1" >>confdefs.h + +fi + +# On IRIX 5.3, sys/types and inttypes.h are conflicting. +for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ + inttypes.h stdint.h unistd.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default +" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + +for ac_header in dlfcn.h +do : + ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default +" +if test "x$ac_cv_header_dlfcn_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_DLFCN_H 1 +_ACEOF + +fi + +done + + + + +func_stripname_cnf () +{ + case $2 in + .*) func_stripname_result=`$ECHO "$3" | $SED "s%^$1%%; s%\\\\$2\$%%"`;; + *) func_stripname_result=`$ECHO "$3" | $SED "s%^$1%%; s%$2\$%%"`;; + esac +} # func_stripname_cnf + + + + + +# Set options +# Check whether --enable-shared was given. +if test "${enable_shared+set}" = set; then : + enableval=$enable_shared; p=${PACKAGE-default} + case $enableval in + yes) enable_shared=yes ;; + no) enable_shared=no ;; + *) + enable_shared=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, + for pkg in $enableval; do + IFS=$lt_save_ifs + if test "X$pkg" = "X$p"; then + enable_shared=yes + fi + done + IFS=$lt_save_ifs + ;; + esac +else + enable_shared=no +fi + + + + + + + +enable_win32_dll=yes + +case $host in +*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args. +set dummy ${ac_tool_prefix}as; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_AS+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$AS"; then + ac_cv_prog_AS="$AS" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_AS="${ac_tool_prefix}as" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +AS=$ac_cv_prog_AS +if test -n "$AS"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 +$as_echo "$AS" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_AS"; then + ac_ct_AS=$AS + # Extract the first word of "as", so it can be a program name with args. +set dummy as; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_AS+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_AS"; then + ac_cv_prog_ac_ct_AS="$ac_ct_AS" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_AS="as" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_AS=$ac_cv_prog_ac_ct_AS +if test -n "$ac_ct_AS"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AS" >&5 +$as_echo "$ac_ct_AS" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_AS" = x; then + AS="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + AS=$ac_ct_AS + fi +else + AS="$ac_cv_prog_AS" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. +set dummy ${ac_tool_prefix}dlltool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DLLTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$DLLTOOL"; then + ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +DLLTOOL=$ac_cv_prog_DLLTOOL +if test -n "$DLLTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 +$as_echo "$DLLTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_DLLTOOL"; then + ac_ct_DLLTOOL=$DLLTOOL + # Extract the first word of "dlltool", so it can be a program name with args. +set dummy dlltool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_DLLTOOL"; then + ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_DLLTOOL="dlltool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL +if test -n "$ac_ct_DLLTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 +$as_echo "$ac_ct_DLLTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_DLLTOOL" = x; then + DLLTOOL="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + DLLTOOL=$ac_ct_DLLTOOL + fi +else + DLLTOOL="$ac_cv_prog_DLLTOOL" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. +set dummy ${ac_tool_prefix}objdump; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_OBJDUMP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$OBJDUMP"; then + ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +OBJDUMP=$ac_cv_prog_OBJDUMP +if test -n "$OBJDUMP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 +$as_echo "$OBJDUMP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_OBJDUMP"; then + ac_ct_OBJDUMP=$OBJDUMP + # Extract the first word of "objdump", so it can be a program name with args. +set dummy objdump; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_OBJDUMP"; then + ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_OBJDUMP="objdump" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP +if test -n "$ac_ct_OBJDUMP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 +$as_echo "$ac_ct_OBJDUMP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_OBJDUMP" = x; then + OBJDUMP="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + OBJDUMP=$ac_ct_OBJDUMP + fi +else + OBJDUMP="$ac_cv_prog_OBJDUMP" +fi + + ;; +esac + +test -z "$AS" && AS=as + + + + + +test -z "$DLLTOOL" && DLLTOOL=dlltool + + + + + +test -z "$OBJDUMP" && OBJDUMP=objdump + + + + + + + + enable_dlopen=no + + + + + # Check whether --enable-static was given. +if test "${enable_static+set}" = set; then : + enableval=$enable_static; p=${PACKAGE-default} + case $enableval in + yes) enable_static=yes ;; + no) enable_static=no ;; + *) + enable_static=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, + for pkg in $enableval; do + IFS=$lt_save_ifs + if test "X$pkg" = "X$p"; then + enable_static=yes + fi + done + IFS=$lt_save_ifs + ;; + esac +else + enable_static=yes +fi + + + + + + + + + + +# Check whether --with-pic was given. +if test "${with_pic+set}" = set; then : + withval=$with_pic; lt_p=${PACKAGE-default} + case $withval in + yes|no) pic_mode=$withval ;; + *) + pic_mode=default + # Look at the argument we got. We use all the common list separators. + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, + for lt_pkg in $withval; do + IFS=$lt_save_ifs + if test "X$lt_pkg" = "X$lt_p"; then + pic_mode=yes + fi + done + IFS=$lt_save_ifs + ;; + esac +else + pic_mode=default +fi + + + + + + + + + # Check whether --enable-fast-install was given. +if test "${enable_fast_install+set}" = set; then : + enableval=$enable_fast_install; p=${PACKAGE-default} + case $enableval in + yes) enable_fast_install=yes ;; + no) enable_fast_install=no ;; + *) + enable_fast_install=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, + for pkg in $enableval; do + IFS=$lt_save_ifs + if test "X$pkg" = "X$p"; then + enable_fast_install=yes + fi + done + IFS=$lt_save_ifs + ;; + esac +else + enable_fast_install=yes +fi + + + + + + + + + shared_archive_member_spec= +case $host,$enable_shared in +power*-*-aix[5-9]*,yes) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of shared library versioning to provide" >&5 +$as_echo_n "checking which variant of shared library versioning to provide... " >&6; } + +# Check whether --with-aix-soname was given. +if test "${with_aix_soname+set}" = set; then : + withval=$with_aix_soname; case $withval in + aix|svr4|both) + ;; + *) + as_fn_error $? "Unknown argument to --with-aix-soname" "$LINENO" 5 + ;; + esac + lt_cv_with_aix_soname=$with_aix_soname +else + if ${lt_cv_with_aix_soname+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_with_aix_soname=aix +fi + + with_aix_soname=$lt_cv_with_aix_soname +fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_aix_soname" >&5 +$as_echo "$with_aix_soname" >&6; } + if test aix != "$with_aix_soname"; then + # For the AIX way of multilib, we name the shared archive member + # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o', + # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File. + # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag, + # the AIX toolchain works better with OBJECT_MODE set (default 32). + if test 64 = "${OBJECT_MODE-32}"; then + shared_archive_member_spec=shr_64 + else + shared_archive_member_spec=shr + fi + fi + ;; +*) + with_aix_soname=aix + ;; +esac + + + + + + + + + + +# This can be used to rebuild libtool when needed +LIBTOOL_DEPS=$ltmain + +# Always use our own libtool. +LIBTOOL='$(SHELL) $(top_builddir)/libtool' + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +test -z "$LN_S" && LN_S="ln -s" + + + + + + + + + + + + + + +if test -n "${ZSH_VERSION+set}"; then + setopt NO_GLOB_SUBST +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 +$as_echo_n "checking for objdir... " >&6; } +if ${lt_cv_objdir+:} false; then : + $as_echo_n "(cached) " >&6 +else + rm -f .libs 2>/dev/null +mkdir .libs 2>/dev/null +if test -d .libs; then + lt_cv_objdir=.libs +else + # MS-DOS does not allow filenames that begin with a dot. + lt_cv_objdir=_libs +fi +rmdir .libs 2>/dev/null +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 +$as_echo "$lt_cv_objdir" >&6; } +objdir=$lt_cv_objdir + + + + + +cat >>confdefs.h <<_ACEOF +#define LT_OBJDIR "$lt_cv_objdir/" +_ACEOF + + + + +case $host_os in +aix3*) + # AIX sometimes has problems with the GCC collect2 program. For some + # reason, if we set the COLLECT_NAMES environment variable, the problems + # vanish in a puff of smoke. + if test set != "${COLLECT_NAMES+set}"; then + COLLECT_NAMES= + export COLLECT_NAMES + fi + ;; +esac + +# Global variables: +ofile=libtool +can_build_shared=yes + +# All known linkers require a '.a' archive for static linking (except MSVC, +# which needs '.lib'). +libext=a + +with_gnu_ld=$lt_cv_prog_gnu_ld + +old_CC=$CC +old_CFLAGS=$CFLAGS + +# Set sane defaults for various variables +test -z "$CC" && CC=cc +test -z "$LTCC" && LTCC=$CC +test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS +test -z "$LD" && LD=ld +test -z "$ac_objext" && ac_objext=o + +func_cc_basename $compiler +cc_basename=$func_cc_basename_result + + +# Only perform the check for file, if the check method requires it +test -z "$MAGIC_CMD" && MAGIC_CMD=file +case $deplibs_check_method in +file_magic*) + if test "$file_magic_cmd" = '$MAGIC_CMD'; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5 +$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; } +if ${lt_cv_path_MAGIC_CMD+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $MAGIC_CMD in +[\\/*] | ?:[\\/]*) + lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. + ;; +*) + lt_save_MAGIC_CMD=$MAGIC_CMD + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR + ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" + for ac_dir in $ac_dummy; do + IFS=$lt_save_ifs + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/${ac_tool_prefix}file"; then + lt_cv_path_MAGIC_CMD=$ac_dir/"${ac_tool_prefix}file" + if test -n "$file_magic_test_file"; then + case $deplibs_check_method in + "file_magic "*) + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` + MAGIC_CMD=$lt_cv_path_MAGIC_CMD + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | + $EGREP "$file_magic_regex" > /dev/null; then + : + else + cat <<_LT_EOF 1>&2 + +*** Warning: the command libtool uses to detect shared libraries, +*** $file_magic_cmd, produces output that libtool cannot recognize. +*** The result is that libtool may fail to recognize shared libraries +*** as such. This will affect the creation of libtool libraries that +*** depend on shared libraries, but programs linked with such libtool +*** libraries will work regardless of this problem. Nevertheless, you +*** may want to report the problem to your system manager and/or to +*** bug-libtool@gnu.org + +_LT_EOF + fi ;; + esac + fi + break + fi + done + IFS=$lt_save_ifs + MAGIC_CMD=$lt_save_MAGIC_CMD + ;; +esac +fi + +MAGIC_CMD=$lt_cv_path_MAGIC_CMD +if test -n "$MAGIC_CMD"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 +$as_echo "$MAGIC_CMD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + + + +if test -z "$lt_cv_path_MAGIC_CMD"; then + if test -n "$ac_tool_prefix"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5 +$as_echo_n "checking for file... " >&6; } +if ${lt_cv_path_MAGIC_CMD+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $MAGIC_CMD in +[\\/*] | ?:[\\/]*) + lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. + ;; +*) + lt_save_MAGIC_CMD=$MAGIC_CMD + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR + ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" + for ac_dir in $ac_dummy; do + IFS=$lt_save_ifs + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/file"; then + lt_cv_path_MAGIC_CMD=$ac_dir/"file" + if test -n "$file_magic_test_file"; then + case $deplibs_check_method in + "file_magic "*) + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` + MAGIC_CMD=$lt_cv_path_MAGIC_CMD + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | + $EGREP "$file_magic_regex" > /dev/null; then + : + else + cat <<_LT_EOF 1>&2 + +*** Warning: the command libtool uses to detect shared libraries, +*** $file_magic_cmd, produces output that libtool cannot recognize. +*** The result is that libtool may fail to recognize shared libraries +*** as such. This will affect the creation of libtool libraries that +*** depend on shared libraries, but programs linked with such libtool +*** libraries will work regardless of this problem. Nevertheless, you +*** may want to report the problem to your system manager and/or to +*** bug-libtool@gnu.org + +_LT_EOF + fi ;; + esac + fi + break + fi + done + IFS=$lt_save_ifs + MAGIC_CMD=$lt_save_MAGIC_CMD + ;; +esac +fi + +MAGIC_CMD=$lt_cv_path_MAGIC_CMD +if test -n "$MAGIC_CMD"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 +$as_echo "$MAGIC_CMD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + else + MAGIC_CMD=: + fi +fi + + fi + ;; +esac + +# Use C for the default configuration in the libtool script + +lt_save_CC=$CC +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + +# Source file extension for C test sources. +ac_ext=c + +# Object file extension for compiled C test sources. +objext=o +objext=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code="int some_variable = 0;" + +# Code to be used in simple link tests +lt_simple_link_test_code='int main(){return(0);}' + + + + + + + +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} + +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC + +# Save the default compiler, since it gets overwritten when the other +# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. +compiler_DEFAULT=$CC + +# save warnings/boilerplate of simple test code +ac_outfile=conftest.$ac_objext +echo "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$RM conftest* + +ac_outfile=conftest.$ac_objext +echo "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$RM -r conftest* + + +## CAVEAT EMPTOR: +## There is no encapsulation within the following macros, do not change +## the running order or otherwise move them around unless you know exactly +## what you are doing... +if test -n "$compiler"; then + +lt_prog_compiler_no_builtin_flag= + +if test yes = "$GCC"; then + case $cc_basename in + nvcc*) + lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;; + *) + lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;; + esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 +$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } +if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_rtti_exceptions=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="-fno-rtti -fno-exceptions" ## exclude from sc_useless_quotes_in_assignment + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_rtti_exceptions=yes + fi + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 +$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } + +if test yes = "$lt_cv_prog_compiler_rtti_exceptions"; then + lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" +else + : +fi + +fi + + + + + + + lt_prog_compiler_wl= +lt_prog_compiler_pic= +lt_prog_compiler_static= + + + if test yes = "$GCC"; then + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_static='-static' + + case $host_os in + aix*) + # All AIX code is PIC. + if test ia64 = "$host_cpu"; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static='-Bstatic' + fi + lt_prog_compiler_pic='-fPIC' + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + lt_prog_compiler_pic='-fPIC' + ;; + m68k) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the '-m68020' flag to GCC prevents building anything better, + # like '-m68040'. + lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' + ;; + esac + ;; + + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + + mingw* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + lt_prog_compiler_pic='-DDLL_EXPORT' + case $host_os in + os2*) + lt_prog_compiler_static='$wl-static' + ;; + esac + ;; + + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + lt_prog_compiler_pic='-fno-common' + ;; + + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + lt_prog_compiler_static= + ;; + + hpux*) + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag + # sets the default TLS model and affects inlining. + case $host_cpu in + hppa*64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic='-fPIC' + ;; + esac + ;; + + interix[3-9]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + + msdosdjgpp*) + # Just because we use GCC doesn't mean we suddenly get shared libraries + # on systems that don't support them. + lt_prog_compiler_can_build_shared=no + enable_shared=no + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic='-fPIC -shared' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + lt_prog_compiler_pic=-Kconform_pic + fi + ;; + + *) + lt_prog_compiler_pic='-fPIC' + ;; + esac + + case $cc_basename in + nvcc*) # Cuda Compiler Driver 2.2 + lt_prog_compiler_wl='-Xlinker ' + if test -n "$lt_prog_compiler_pic"; then + lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic" + fi + ;; + esac + else + # PORTME Check for flag to pass linker flags through the system compiler. + case $host_os in + aix*) + lt_prog_compiler_wl='-Wl,' + if test ia64 = "$host_cpu"; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static='-Bstatic' + else + lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' + fi + ;; + + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + lt_prog_compiler_pic='-fno-common' + case $cc_basename in + nagfor*) + # NAG Fortran compiler + lt_prog_compiler_wl='-Wl,-Wl,,' + lt_prog_compiler_pic='-PIC' + lt_prog_compiler_static='-Bstatic' + ;; + esac + ;; + + mingw* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + lt_prog_compiler_pic='-DDLL_EXPORT' + case $host_os in + os2*) + lt_prog_compiler_static='$wl-static' + ;; + esac + ;; + + hpux9* | hpux10* | hpux11*) + lt_prog_compiler_wl='-Wl,' + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic='+Z' + ;; + esac + # Is there a better lt_prog_compiler_static that works with the bundled CC? + lt_prog_compiler_static='$wl-a ${wl}archive' + ;; + + irix5* | irix6* | nonstopux*) + lt_prog_compiler_wl='-Wl,' + # PIC (with -KPIC) is the default. + lt_prog_compiler_static='-non_shared' + ;; + + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + case $cc_basename in + # old Intel for x86_64, which still supported -KPIC. + ecc*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-static' + ;; + # icc used to be incompatible with GCC. + # ICC 10 doesn't accept -KPIC any more. + icc* | ifort*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fPIC' + lt_prog_compiler_static='-static' + ;; + # Lahey Fortran 8.1. + lf95*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='--shared' + lt_prog_compiler_static='--static' + ;; + nagfor*) + # NAG Fortran compiler + lt_prog_compiler_wl='-Wl,-Wl,,' + lt_prog_compiler_pic='-PIC' + lt_prog_compiler_static='-Bstatic' + ;; + tcc*) + # Fabrice Bellard et al's Tiny C Compiler + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fPIC' + lt_prog_compiler_static='-static' + ;; + pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) + # Portland Group compilers (*not* the Pentium gcc compiler, + # which looks to be a dead project) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fpic' + lt_prog_compiler_static='-Bstatic' + ;; + ccc*) + lt_prog_compiler_wl='-Wl,' + # All Alpha code is PIC. + lt_prog_compiler_static='-non_shared' + ;; + xl* | bgxl* | bgf* | mpixl*) + # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-qpic' + lt_prog_compiler_static='-qstaticlink' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*) + # Sun Fortran 8.3 passes all unrecognized flags to the linker + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + lt_prog_compiler_wl='' + ;; + *Sun\ F* | *Sun*Fortran*) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + lt_prog_compiler_wl='-Qoption ld ' + ;; + *Sun\ C*) + # Sun C 5.9 + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + lt_prog_compiler_wl='-Wl,' + ;; + *Intel*\ [CF]*Compiler*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fPIC' + lt_prog_compiler_static='-static' + ;; + *Portland\ Group*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fpic' + lt_prog_compiler_static='-Bstatic' + ;; + esac + ;; + esac + ;; + + newsos6) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic='-fPIC -shared' + ;; + + osf3* | osf4* | osf5*) + lt_prog_compiler_wl='-Wl,' + # All OSF/1 code is PIC. + lt_prog_compiler_static='-non_shared' + ;; + + rdos*) + lt_prog_compiler_static='-non_shared' + ;; + + solaris*) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + case $cc_basename in + f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) + lt_prog_compiler_wl='-Qoption ld ';; + *) + lt_prog_compiler_wl='-Wl,';; + esac + ;; + + sunos4*) + lt_prog_compiler_wl='-Qoption ld ' + lt_prog_compiler_pic='-PIC' + lt_prog_compiler_static='-Bstatic' + ;; + + sysv4 | sysv4.2uw2* | sysv4.3*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + lt_prog_compiler_pic='-Kconform_pic' + lt_prog_compiler_static='-Bstatic' + fi + ;; + + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + unicos*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_can_build_shared=no + ;; + + uts4*) + lt_prog_compiler_pic='-pic' + lt_prog_compiler_static='-Bstatic' + ;; + + *) + lt_prog_compiler_can_build_shared=no + ;; + esac + fi + +case $host_os in + # For platforms that do not support PIC, -DPIC is meaningless: + *djgpp*) + lt_prog_compiler_pic= + ;; + *) + lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" + ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; } +if ${lt_cv_prog_compiler_pic+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic=$lt_prog_compiler_pic +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5 +$as_echo "$lt_cv_prog_compiler_pic" >&6; } +lt_prog_compiler_pic=$lt_cv_prog_compiler_pic + +# +# Check to make sure the PIC flag actually works. +# +if test -n "$lt_prog_compiler_pic"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 +$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } +if ${lt_cv_prog_compiler_pic_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic_works=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$lt_prog_compiler_pic -DPIC" ## exclude from sc_useless_quotes_in_assignment + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_pic_works=yes + fi + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5 +$as_echo "$lt_cv_prog_compiler_pic_works" >&6; } + +if test yes = "$lt_cv_prog_compiler_pic_works"; then + case $lt_prog_compiler_pic in + "" | " "*) ;; + *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; + esac +else + lt_prog_compiler_pic= + lt_prog_compiler_can_build_shared=no +fi + +fi + + + + + + + + + + + +# +# Check to make sure the static flag actually works. +# +wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\" +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 +$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } +if ${lt_cv_prog_compiler_static_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_static_works=no + save_LDFLAGS=$LDFLAGS + LDFLAGS="$LDFLAGS $lt_tmp_static_flag" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_static_works=yes + fi + else + lt_cv_prog_compiler_static_works=yes + fi + fi + $RM -r conftest* + LDFLAGS=$save_LDFLAGS + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5 +$as_echo "$lt_cv_prog_compiler_static_works" >&6; } + +if test yes = "$lt_cv_prog_compiler_static_works"; then + : +else + lt_prog_compiler_static= +fi + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 +$as_echo "$lt_cv_prog_compiler_c_o" >&6; } + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 +$as_echo "$lt_cv_prog_compiler_c_o" >&6; } + + + + +hard_links=nottested +if test no = "$lt_cv_prog_compiler_c_o" && test no != "$need_locks"; then + # do not overwrite the value of need_locks provided by the user + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 +$as_echo_n "checking if we can lock with hard links... " >&6; } + hard_links=yes + $RM conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 +$as_echo "$hard_links" >&6; } + if test no = "$hard_links"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5 +$as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;} + need_locks=warn + fi +else + need_locks=no +fi + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } + + runpath_var= + allow_undefined_flag= + always_export_symbols=no + archive_cmds= + archive_expsym_cmds= + compiler_needs_object=no + enable_shared_with_static_runtimes=no + export_dynamic_flag_spec= + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + hardcode_automatic=no + hardcode_direct=no + hardcode_direct_absolute=no + hardcode_libdir_flag_spec= + hardcode_libdir_separator= + hardcode_minus_L=no + hardcode_shlibpath_var=unsupported + inherit_rpath=no + link_all_deplibs=unknown + module_cmds= + module_expsym_cmds= + old_archive_from_new_cmds= + old_archive_from_expsyms_cmds= + thread_safe_flag_spec= + whole_archive_flag_spec= + # include_expsyms should be a list of space-separated symbols to be *always* + # included in the symbol list + include_expsyms= + # exclude_expsyms can be an extended regexp of symbols to exclude + # it will be wrapped by ' (' and ')$', so one must not match beginning or + # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc', + # as well as any symbol that contains 'd'. + exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' + # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out + # platforms (ab)use it in PIC code, but their linkers get confused if + # the symbol is explicitly referenced. Since portable code cannot + # rely on this symbol name, it's probably fine to never include it in + # preloaded symbol tables. + # Exclude shared library initialization/finalization symbols. + extract_expsyms_cmds= + + case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + # FIXME: the MSVC++ port hasn't been tested in a loooong time + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + if test yes != "$GCC"; then + with_gnu_ld=no + fi + ;; + interix*) + # we just hope/assume this is gcc and not c89 (= MSVC++) + with_gnu_ld=yes + ;; + openbsd* | bitrig*) + with_gnu_ld=no + ;; + linux* | k*bsd*-gnu | gnu*) + link_all_deplibs=no + ;; + esac + + ld_shlibs=yes + + # On some targets, GNU ld is compatible enough with the native linker + # that we're better off using the native interface for both. + lt_use_gnu_ld_interface=no + if test yes = "$with_gnu_ld"; then + case $host_os in + aix*) + # The AIX port of GNU ld has always aspired to compatibility + # with the native linker. However, as the warning in the GNU ld + # block says, versions before 2.19.5* couldn't really create working + # shared libraries, regardless of the interface used. + case `$LD -v 2>&1` in + *\ \(GNU\ Binutils\)\ 2.19.5*) ;; + *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;; + *\ \(GNU\ Binutils\)\ [3-9]*) ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + fi + + if test yes = "$lt_use_gnu_ld_interface"; then + # If archive_cmds runs LD, not CC, wlarc should be empty + wlarc='$wl' + + # Set some defaults for GNU ld with shared library support. These + # are reset later if shared libraries are not supported. Putting them + # here allows them to be overridden if necessary. + runpath_var=LD_RUN_PATH + hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' + export_dynamic_flag_spec='$wl--export-dynamic' + # ancient GNU ld didn't support --whole-archive et. al. + if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then + whole_archive_flag_spec=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' + else + whole_archive_flag_spec= + fi + supports_anon_versioning=no + case `$LD -v | $SED -e 's/(^)\+)\s\+//' 2>&1` in + *GNU\ gold*) supports_anon_versioning=yes ;; + *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 + *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... + *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... + *\ 2.11.*) ;; # other 2.11 versions + *) supports_anon_versioning=yes ;; + esac + + # See if GNU ld supports shared libraries. + case $host_os in + aix[3-9]*) + # On AIX/PPC, the GNU linker is very broken + if test ia64 != "$host_cpu"; then + ld_shlibs=no + cat <<_LT_EOF 1>&2 + +*** Warning: the GNU linker, at least up to release 2.19, is reported +*** to be unable to reliably create shared libraries on AIX. +*** Therefore, libtool is disabling shared libraries support. If you +*** really care for shared libraries, you may want to install binutils +*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. +*** You will then need to restart the configuration process. + +_LT_EOF + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds='' + ;; + m68k) + 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)' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + ;; + esac + ;; + + beos*) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + allow_undefined_flag=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + else + ld_shlibs=no + fi + ;; + + cygwin* | mingw* | pw32* | cegcc*) + # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, + # as there is no search path for DLLs. + hardcode_libdir_flag_spec='-L$libdir' + export_dynamic_flag_spec='$wl--export-all-symbols' + allow_undefined_flag=unsupported + always_export_symbols=no + enable_shared_with_static_runtimes=yes + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' + exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' + + if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file, use it as + # is; otherwise, prepend EXPORTS... + archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + ld_shlibs=no + fi + ;; + + haiku*) + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + link_all_deplibs=yes + ;; + + os2*) + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + allow_undefined_flag=unsupported + shrext_cmds=.dll + archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + prefix_cmds="$SED"~ + if test EXPORTS = "`$SED 1q $export_symbols`"; then + prefix_cmds="$prefix_cmds -e 1d"; + fi~ + prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ + cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + enable_shared_with_static_runtimes=yes + ;; + + interix[3-9]*) + hardcode_direct=no + hardcode_shlibpath_var=no + hardcode_libdir_flag_spec='$wl-rpath,$libdir' + export_dynamic_flag_spec='$wl-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + archive_expsym_cmds='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + + gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) + tmp_diet=no + if test linux-dietlibc = "$host_os"; then + case $cc_basename in + diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) + esac + fi + if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ + && test no = "$tmp_diet" + then + tmp_addflag=' $pic_flag' + tmp_sharedflag='-shared' + case $cc_basename,$host_cpu in + pgcc*) # Portland Group C compiler + whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + tmp_addflag=' $pic_flag' + ;; + pgf77* | pgf90* | pgf95* | pgfortran*) + # Portland Group f77 and f90 compilers + whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + tmp_addflag=' $pic_flag -Mnomain' ;; + ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 + tmp_addflag=' -i_dynamic' ;; + efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 + tmp_addflag=' -i_dynamic -nofor_main' ;; + ifc* | ifort*) # Intel Fortran compiler + tmp_addflag=' -nofor_main' ;; + lf95*) # Lahey Fortran 8.1 + whole_archive_flag_spec= + tmp_sharedflag='--shared' ;; + nagfor*) # NAGFOR 5.3 + tmp_sharedflag='-Wl,-shared' ;; + xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below) + tmp_sharedflag='-qmkshrobj' + tmp_addflag= ;; + nvcc*) # Cuda Compiler Driver 2.2 + whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + compiler_needs_object=yes + ;; + esac + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) # Sun C 5.9 + whole_archive_flag_spec='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + compiler_needs_object=yes + tmp_sharedflag='-G' ;; + *Sun\ F*) # Sun Fortran 8.3 + tmp_sharedflag='-G' ;; + esac + archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + + if test yes = "$supports_anon_versioning"; then + archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' + fi + + case $cc_basename in + tcc*) + export_dynamic_flag_spec='-rdynamic' + ;; + xlf* | bgf* | bgxlf* | mpixlf*) + # IBM XL Fortran 10.1 on PPC cannot create shared libs itself + whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive' + hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' + archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' + if test yes = "$supports_anon_versioning"; then + archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' + fi + ;; + esac + else + ld_shlibs=no + fi + ;; + + netbsd* | netbsdelf*-gnu) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' + wlarc= + else + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + fi + ;; + + solaris*) + if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then + ld_shlibs=no + cat <<_LT_EOF 1>&2 + +*** Warning: The releases 2.8.* of the GNU linker cannot reliably +*** create shared libraries on Solaris systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.9.1 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +_LT_EOF + elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs=no + fi + ;; + + sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) + case `$LD -v 2>&1` in + *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) + ld_shlibs=no + cat <<_LT_EOF 1>&2 + +*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot +*** reliably create shared libraries on SCO systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.16.91.0.3 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +_LT_EOF + ;; + *) + # For security reasons, it is highly recommended that you always + # use absolute paths for naming shared libraries, and exclude the + # DT_RUNPATH tag from executables and libraries. But doing so + # requires that you compile everything twice, which is a pain. + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs=no + fi + ;; + esac + ;; + + sunos4*) + archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' + wlarc= + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + *) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs=no + fi + ;; + esac + + if test no = "$ld_shlibs"; then + runpath_var= + hardcode_libdir_flag_spec= + export_dynamic_flag_spec= + whole_archive_flag_spec= + fi + else + # PORTME fill in a description of your system's linker (not GNU ld) + case $host_os in + aix3*) + allow_undefined_flag=unsupported + always_export_symbols=yes + 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' + # Note: this linker hardcodes the directories in LIBPATH if there + # are no directories specified by -L. + hardcode_minus_L=yes + if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then + # Neither direct hardcoding nor static linking is supported with a + # broken collect2. + hardcode_direct=unsupported + fi + ;; + + aix[4-9]*) + if test ia64 = "$host_cpu"; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag= + else + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to GNU nm, but means don't demangle to AIX nm. + # Without the "-l" option, or with the "-B" option, AIX nm treats + # weak defined symbols like other global defined symbols, whereas + # GNU nm marks them as "W". + # While the 'weak' keyword is ignored in the Export File, we need + # it in the Import File for the 'aix-soname' feature, so we have + # to replace the "-B" option with "-P" for AIX nm. + if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then + export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' + else + export_symbols_cmds='`func_echo_all $NM | $SED -e '\''s/B\([^B]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && (substr(\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' + fi + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # have runtime linking enabled, and use it for executables. + # For shared libraries, we enable/disable runtime linking + # depending on the kind of the shared library created - + # when "with_aix_soname,aix_use_runtimelinking" is: + # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables + # "aix,yes" lib.so shared, rtl:yes, for executables + # lib.a static archive + # "both,no" lib.so.V(shr.o) shared, rtl:yes + # lib.a(lib.so.V) shared, rtl:no, for executables + # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a(lib.so.V) shared, rtl:no + # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a static archive + case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) + for ld_flag in $LDFLAGS; do + if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then + aix_use_runtimelinking=yes + break + fi + done + if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then + # With aix-soname=svr4, we create the lib.so.V shared archives only, + # so we don't have lib.a shared libs to link our executables. + # We have to force runtime linking in this case. + aix_use_runtimelinking=yes + LDFLAGS="$LDFLAGS -Wl,-brtl" + fi + ;; + esac + + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + archive_cmds='' + hardcode_direct=yes + hardcode_direct_absolute=yes + hardcode_libdir_separator=':' + link_all_deplibs=yes + file_list_spec='$wl-f,' + case $with_aix_soname,$aix_use_runtimelinking in + aix,*) ;; # traditional, no import file + svr4,* | *,yes) # use import file + # The Import File defines what to hardcode. + hardcode_direct=no + hardcode_direct_absolute=no + ;; + esac + + if test yes = "$GCC"; then + case $host_os in aix4.[012]|aix4.[012].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`$CC -print-prog-name=collect2` + if test -f "$collect2name" && + strings "$collect2name" | $GREP resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + hardcode_direct=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + hardcode_minus_L=yes + hardcode_libdir_flag_spec='-L$libdir' + hardcode_libdir_separator= + fi + ;; + esac + shared_flag='-shared' + if test yes = "$aix_use_runtimelinking"; then + shared_flag="$shared_flag "'$wl-G' + fi + # Need to ensure runtime linking is disabled for the traditional + # shared library, or the linker may eventually find shared libraries + # /with/ Import File - we do not want to mix them. + shared_flag_aix='-shared' + shared_flag_svr4='-shared $wl-G' + else + # not using gcc + if test ia64 = "$host_cpu"; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test yes = "$aix_use_runtimelinking"; then + shared_flag='$wl-G' + else + shared_flag='$wl-bM:SRE' + fi + shared_flag_aix='$wl-bM:SRE' + shared_flag_svr4='$wl-G' + fi + fi + + export_dynamic_flag_spec='$wl-bexpall' + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to export. + always_export_symbols=yes + if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + allow_undefined_flag='-berok' + # Determine the default libpath from the value encoded in an + # empty executable. + if test set = "${lt_cv_aix_libpath+set}"; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath_+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_=/usr/lib:/lib + fi + +fi + + aix_libpath=$lt_cv_aix_libpath_ +fi + + hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath" + archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag + else + if test ia64 = "$host_cpu"; then + hardcode_libdir_flag_spec='$wl-R $libdir:/usr/lib:/lib' + allow_undefined_flag="-z nodefs" + archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an + # empty executable. + if test set = "${lt_cv_aix_libpath+set}"; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath_+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_=/usr/lib:/lib + fi + +fi + + aix_libpath=$lt_cv_aix_libpath_ +fi + + hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + no_undefined_flag=' $wl-bernotok' + allow_undefined_flag=' $wl-berok' + if test yes = "$with_gnu_ld"; then + # We only use this code for GNU lds that support --whole-archive. + whole_archive_flag_spec='$wl--whole-archive$convenience $wl--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + whole_archive_flag_spec='$convenience' + fi + archive_cmds_need_lc=yes + archive_expsym_cmds='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' + # -brtl affects multiple linker settings, -berok does not and is overridden later + compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`' + if test svr4 != "$with_aix_soname"; then + # This is similar to how AIX traditionally builds its shared libraries. + archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' + fi + if test aix != "$with_aix_soname"; then + archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' + else + # used by -dlpreopen to get the symbols + archive_expsym_cmds="$archive_expsym_cmds"'~$MV $output_objdir/$realname.d/$soname $output_objdir' + fi + archive_expsym_cmds="$archive_expsym_cmds"'~$RM -r $output_objdir/$realname.d' + fi + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds='' + ;; + m68k) + 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)' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + ;; + esac + ;; + + bsdi[45]*) + export_dynamic_flag_spec=-rdynamic + ;; + + cygwin* | mingw* | pw32* | cegcc*) + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + case $cc_basename in + cl*) + # Native MSVC + hardcode_libdir_flag_spec=' ' + allow_undefined_flag=unsupported + always_export_symbols=yes + file_list_spec='@' + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=.dll + # FIXME: Setting linknames here is a bad hack. + archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' + archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then + cp "$export_symbols" "$output_objdir/$soname.def"; + echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; + else + $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, )='true' + enable_shared_with_static_runtimes=yes + exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' + # Don't use ranlib + old_postinstall_cmds='chmod 644 $oldlib' + postlink_cmds='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile=$lt_outputfile.exe + lt_tool_outputfile=$lt_tool_outputfile.exe + ;; + esac~ + if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # Assume MSVC wrapper + hardcode_libdir_flag_spec=' ' + allow_undefined_flag=unsupported + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=.dll + # FIXME: Setting linknames here is a bad hack. + archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' + # The linker will automatically build a .lib file if we build a DLL. + old_archive_from_new_cmds='true' + # FIXME: Should let the user specify the lib program. + old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs' + enable_shared_with_static_runtimes=yes + ;; + esac + ;; + + darwin* | rhapsody*) + + + archive_cmds_need_lc=no + hardcode_direct=no + hardcode_automatic=yes + hardcode_shlibpath_var=unsupported + if test yes = "$lt_cv_ld_force_load"; then + whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' + + else + whole_archive_flag_spec='' + fi + link_all_deplibs=yes + allow_undefined_flag=$_lt_dar_allow_undefined + case $cc_basename in + ifort*|nagfor*) _lt_dar_can_shared=yes ;; + *) _lt_dar_can_shared=$GCC ;; + esac + if test yes = "$_lt_dar_can_shared"; then + output_verbose_link_cmd=func_echo_all + archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" + module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" + archive_expsym_cmds="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" + module_expsym_cmds="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" + + else + ld_shlibs=no + fi + + ;; + + dgux*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_shlibpath_var=no + ;; + + # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor + # support. Future versions do this automatically, but an explicit c++rt0.o + # does not break anything, and helps significantly (at the cost of a little + # extra space). + freebsd2.2*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + # Unfortunately, older versions of FreeBSD 2 do not have this feature. + freebsd2.*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes + hardcode_minus_L=yes + hardcode_shlibpath_var=no + ;; + + # FreeBSD 3 and greater uses gcc -shared to do shared libraries. + freebsd* | dragonfly*) + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + hpux9*) + if test yes = "$GCC"; then + archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' + else + archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' + fi + hardcode_libdir_flag_spec='$wl+b $wl$libdir' + hardcode_libdir_separator=: + hardcode_direct=yes + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + export_dynamic_flag_spec='$wl-E' + ;; + + hpux10*) + if test yes,no = "$GCC,$with_gnu_ld"; then + archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' + fi + if test no = "$with_gnu_ld"; then + hardcode_libdir_flag_spec='$wl+b $wl$libdir' + hardcode_libdir_separator=: + hardcode_direct=yes + hardcode_direct_absolute=yes + export_dynamic_flag_spec='$wl-E' + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + fi + ;; + + hpux11*) + if test yes,no = "$GCC,$with_gnu_ld"; then + case $host_cpu in + hppa*64*) + archive_cmds='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + else + case $host_cpu in + hppa*64*) + archive_cmds='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + archive_cmds='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + + # Older versions of the 11.00 compiler do not understand -b yet + # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5 +$as_echo_n "checking if $CC understands -b... " >&6; } +if ${lt_cv_prog_compiler__b+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler__b=no + save_LDFLAGS=$LDFLAGS + LDFLAGS="$LDFLAGS -b" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler__b=yes + fi + else + lt_cv_prog_compiler__b=yes + fi + fi + $RM -r conftest* + LDFLAGS=$save_LDFLAGS + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5 +$as_echo "$lt_cv_prog_compiler__b" >&6; } + +if test yes = "$lt_cv_prog_compiler__b"; then + archive_cmds='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' +else + archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' +fi + + ;; + esac + fi + if test no = "$with_gnu_ld"; then + hardcode_libdir_flag_spec='$wl+b $wl$libdir' + hardcode_libdir_separator=: + + case $host_cpu in + hppa*64*|ia64*) + hardcode_direct=no + hardcode_shlibpath_var=no + ;; + *) + hardcode_direct=yes + hardcode_direct_absolute=yes + export_dynamic_flag_spec='$wl-E' + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + ;; + esac + fi + ;; + + irix5* | irix6* | nonstopux*) + if test yes = "$GCC"; then + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + # Try to use the -exported_symbol ld option, if it does not + # work, assume that -exports_file does not work either and + # implicitly export all symbols. + # This should be the same for all languages, so no per-tag cache variable. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5 +$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; } +if ${lt_cv_irix_exported_symbol+:} false; then : + $as_echo_n "(cached) " >&6 +else + save_LDFLAGS=$LDFLAGS + LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +int foo (void) { return 0; } +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + lt_cv_irix_exported_symbol=yes +else + lt_cv_irix_exported_symbol=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS=$save_LDFLAGS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5 +$as_echo "$lt_cv_irix_exported_symbol" >&6; } + if test yes = "$lt_cv_irix_exported_symbol"; then + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib' + fi + link_all_deplibs=no + else + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib' + fi + archive_cmds_need_lc='no' + hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' + hardcode_libdir_separator=: + inherit_rpath=yes + link_all_deplibs=yes + ;; + + linux*) + case $cc_basename in + tcc*) + # Fabrice Bellard et al's Tiny C Compiler + ld_shlibs=yes + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + netbsd* | netbsdelf*-gnu) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out + else + archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF + fi + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + newsos6) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes + hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' + hardcode_libdir_separator=: + hardcode_shlibpath_var=no + ;; + + *nto* | *qnx*) + ;; + + openbsd* | bitrig*) + if test -f /usr/libexec/ld.so; then + hardcode_direct=yes + hardcode_shlibpath_var=no + hardcode_direct_absolute=yes + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols' + hardcode_libdir_flag_spec='$wl-rpath,$libdir' + export_dynamic_flag_spec='$wl-E' + else + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec='$wl-rpath,$libdir' + fi + else + ld_shlibs=no + fi + ;; + + os2*) + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + allow_undefined_flag=unsupported + shrext_cmds=.dll + archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + prefix_cmds="$SED"~ + if test EXPORTS = "`$SED 1q $export_symbols`"; then + prefix_cmds="$prefix_cmds -e 1d"; + fi~ + prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ + cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + enable_shared_with_static_runtimes=yes + ;; + + osf3*) + if test yes = "$GCC"; then + allow_undefined_flag=' $wl-expect_unresolved $wl\*' + archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + else + allow_undefined_flag=' -expect_unresolved \*' + archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + fi + archive_cmds_need_lc='no' + hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' + hardcode_libdir_separator=: + ;; + + osf4* | osf5*) # as osf3* with the addition of -msym flag + if test yes = "$GCC"; then + allow_undefined_flag=' $wl-expect_unresolved $wl\*' + archive_cmds='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' + else + allow_undefined_flag=' -expect_unresolved \*' + archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ + $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp' + + # Both c and cxx compiler support -rpath directly + hardcode_libdir_flag_spec='-rpath $libdir' + fi + archive_cmds_need_lc='no' + hardcode_libdir_separator=: + ;; + + solaris*) + no_undefined_flag=' -z defs' + if test yes = "$GCC"; then + wlarc='$wl' + archive_cmds='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + else + case `$CC -V 2>&1` in + *"Compilers 5.0"*) + wlarc='' + archive_cmds='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags' + archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' + ;; + *) + wlarc='$wl' + archive_cmds='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + ;; + esac + fi + hardcode_libdir_flag_spec='-R$libdir' + hardcode_shlibpath_var=no + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands '-z linker_flag'. GCC discards it without '$wl', + # but is careful enough not to reorder. + # Supported since Solaris 2.6 (maybe 2.5.1?) + if test yes = "$GCC"; then + whole_archive_flag_spec='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' + else + whole_archive_flag_spec='-z allextract$convenience -z defaultextract' + fi + ;; + esac + link_all_deplibs=yes + ;; + + sunos4*) + if test sequent = "$host_vendor"; then + # Use $CC to link under sequent, because it throws in some extra .o + # files that make .init and .fini sections work. + archive_cmds='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' + fi + hardcode_libdir_flag_spec='-L$libdir' + hardcode_direct=yes + hardcode_minus_L=yes + hardcode_shlibpath_var=no + ;; + + sysv4) + case $host_vendor in + sni) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes # is this really true??? + ;; + siemens) + ## LD is ld it makes a PLAMLIB + ## CC just makes a GrossModule. + archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' + reload_cmds='$CC -r -o $output$reload_objs' + hardcode_direct=no + ;; + motorola) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=no #Motorola manual says yes, but my tests say they lie + ;; + esac + runpath_var='LD_RUN_PATH' + hardcode_shlibpath_var=no + ;; + + sysv4.3*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var=no + export_dynamic_flag_spec='-Bexport' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var=no + runpath_var=LD_RUN_PATH + hardcode_runpath_var=yes + ld_shlibs=yes + fi + ;; + + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) + no_undefined_flag='$wl-z,text' + archive_cmds_need_lc=no + hardcode_shlibpath_var=no + runpath_var='LD_RUN_PATH' + + if test yes = "$GCC"; then + archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + + sysv5* | sco3.2v5* | sco5v6*) + # Note: We CANNOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + no_undefined_flag='$wl-z,text' + allow_undefined_flag='$wl-z,nodefs' + archive_cmds_need_lc=no + hardcode_shlibpath_var=no + hardcode_libdir_flag_spec='$wl-R,$libdir' + hardcode_libdir_separator=':' + link_all_deplibs=yes + export_dynamic_flag_spec='$wl-Bexport' + runpath_var='LD_RUN_PATH' + + if test yes = "$GCC"; then + archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + + uts4*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_shlibpath_var=no + ;; + + *) + ld_shlibs=no + ;; + esac + + if test sni = "$host_vendor"; then + case $host in + sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) + export_dynamic_flag_spec='$wl-Blargedynsym' + ;; + esac + fi + fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 +$as_echo "$ld_shlibs" >&6; } +test no = "$ld_shlibs" && can_build_shared=no + +with_gnu_ld=$with_gnu_ld + + + + + + + + + + + + + + + +# +# Do we need to explicitly link libc? +# +case "x$archive_cmds_need_lc" in +x|xyes) + # Assume -lc should be added + archive_cmds_need_lc=yes + + if test yes,yes = "$GCC,$enable_shared"; then + case $archive_cmds in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 +$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } +if ${lt_cv_archive_cmds_need_lc+:} false; then : + $as_echo_n "(cached) " >&6 +else + $RM conftest* + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$lt_prog_compiler_wl + pic_flag=$lt_prog_compiler_pic + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$allow_undefined_flag + allow_undefined_flag= + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 + (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + then + lt_cv_archive_cmds_need_lc=no + else + lt_cv_archive_cmds_need_lc=yes + fi + allow_undefined_flag=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5 +$as_echo "$lt_cv_archive_cmds_need_lc" >&6; } + archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc + ;; + esac + fi + ;; +esac + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 +$as_echo_n "checking dynamic linker characteristics... " >&6; } + +if test yes = "$GCC"; then + case $host_os in + darwin*) lt_awk_arg='/^libraries:/,/LR/' ;; + *) lt_awk_arg='/^libraries:/' ;; + esac + case $host_os in + mingw* | cegcc*) lt_sed_strip_eq='s|=\([A-Za-z]:\)|\1|g' ;; + *) lt_sed_strip_eq='s|=/|/|g' ;; + esac + lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` + case $lt_search_path_spec in + *\;*) + # if the path contains ";" then we assume it to be the separator + # otherwise default to the standard path separator (i.e. ":") - it is + # assumed that no part of a normal pathname contains ";" but that should + # okay in the real world where ";" in dirpaths is itself problematic. + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` + ;; + *) + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` + ;; + esac + # Ok, now we have the path, separated by spaces, we can step through it + # and add multilib dir if necessary... + lt_tmp_lt_search_path_spec= + lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` + # ...but if some path component already ends with the multilib dir we assume + # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer). + case "$lt_multi_os_dir; $lt_search_path_spec " in + "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*) + lt_multi_os_dir= + ;; + esac + for lt_sys_path in $lt_search_path_spec; do + if test -d "$lt_sys_path$lt_multi_os_dir"; then + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir" + elif test -n "$lt_multi_os_dir"; then + test -d "$lt_sys_path" && \ + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" + fi + done + lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' +BEGIN {RS = " "; FS = "/|\n";} { + lt_foo = ""; + lt_count = 0; + for (lt_i = NF; lt_i > 0; lt_i--) { + if ($lt_i != "" && $lt_i != ".") { + if ($lt_i == "..") { + lt_count++; + } else { + if (lt_count == 0) { + lt_foo = "/" $lt_i lt_foo; + } else { + lt_count--; + } + } + } + } + if (lt_foo != "") { lt_freq[lt_foo]++; } + if (lt_freq[lt_foo] == 1) { print lt_foo; } +}'` + # AWK program above erroneously prepends '/' to C:/dos/paths + # for these hosts. + case $host_os in + mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ + $SED 's|/\([A-Za-z]:\)|\1|g'` ;; + esac + sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` +else + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" +fi +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=.so +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" +need_lib_prefix=unknown +hardcode_into_libs=no + +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown + + + +case $host_os in +aix3*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname.a' + shlibpath_var=LIBPATH + + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='$libname$release$shared_ext$major' + ;; + +aix[4-9]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test ia64 = "$host_cpu"; then + # AIX 5 supports IA64 + library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line '#! .'. This would cause the generated library to + # depend on '.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[01] | aix4.[01].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then + : + else + can_build_shared=no + fi + ;; + esac + # Using Import Files as archive members, it is possible to support + # filename-based versioning of shared library archives on AIX. While + # this would work for both with and without runtime linking, it will + # prevent static linking of such archives. So we do filename-based + # shared library versioning with .so extension only, which is used + # when both runtime linking and shared linking is enabled. + # Unfortunately, runtime linking may impact performance, so we do + # not want this to be the default eventually. Also, we use the + # versioned .so libs for executables only if there is the -brtl + # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. + # To allow for filename-based versioning support, we need to create + # libNAME.so.V as an archive file, containing: + # *) an Import File, referring to the versioned filename of the + # archive as well as the shared archive member, telling the + # bitwidth (32 or 64) of that shared object, and providing the + # list of exported symbols of that shared object, eventually + # decorated with the 'weak' keyword + # *) the shared object with the F_LOADONLY flag set, to really avoid + # it being seen by the linker. + # At run time we better use the real file rather than another symlink, + # but for link time we create the symlink libNAME.so -> libNAME.so.V + + case $with_aix_soname,$aix_use_runtimelinking in + # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + aix,yes) # traditional libtool + dynamic_linker='AIX unversionable lib.so' + # If using run time linking (on AIX 4.2 or later) use lib.so + # instead of lib.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + ;; + aix,no) # traditional AIX only + dynamic_linker='AIX lib.a(lib.so.V)' + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='$libname$release.a $libname.a' + soname_spec='$libname$release$shared_ext$major' + ;; + svr4,*) # full svr4 only + dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)" + library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' + # We do not specify a path in Import Files, so LIBPATH fires. + shlibpath_overrides_runpath=yes + ;; + *,yes) # both, prefer svr4 + dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)" + library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' + # unpreferred sharedlib libNAME.a needs extra handling + postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' + postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' + # We do not specify a path in Import Files, so LIBPATH fires. + shlibpath_overrides_runpath=yes + ;; + *,no) # both, prefer aix + dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)" + library_names_spec='$libname$release.a $libname.a' + soname_spec='$libname$release$shared_ext$major' + # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling + postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' + postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' + ;; + esac + shlibpath_var=LIBPATH + fi + ;; + +amigaos*) + case $host_cpu in + powerpc) + # Since July 2007 AmigaOS4 officially supports .so libraries. + # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + ;; + m68k) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; $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' + ;; + esac + ;; + +beos*) + library_names_spec='$libname$shared_ext' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; + +bsdi[45]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; + +cygwin* | mingw* | pw32* | cegcc*) + version_type=windows + shrext_cmds=.dll + need_version=no + need_lib_prefix=no + + case $GCC,$cc_basename in + yes,*) + # gcc + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + + case $host_os in + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' + + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api" + ;; + mingw* | cegcc*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' + ;; + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' + ;; + esac + dynamic_linker='Win32 ld.exe' + ;; + + *,cl*) + # Native MSVC + libname_spec='$name' + soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' + library_names_spec='$libname.dll.lib' + + case $build_os in + mingw*) + sys_lib_search_path_spec= + lt_save_ifs=$IFS + IFS=';' + for lt_path in $LIB + do + IFS=$lt_save_ifs + # Let DOS variable expansion print the short 8.3 style file name. + lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` + sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" + done + IFS=$lt_save_ifs + # Convert to MSYS style. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` + ;; + cygwin*) + # Convert to unix form, then to dos form, then back to unix form + # but this time dos style (no spaces!) so that the unix form looks + # like /cygdrive/c/PROGRA~1:/cygdr... + sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` + sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` + sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + ;; + *) + sys_lib_search_path_spec=$LIB + if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then + # It is most probably a Windows format PATH. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + # FIXME: find the short name or the path components, as spaces are + # common. (e.g. "Program Files" -> "PROGRA~1") + ;; + esac + + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + dynamic_linker='Win32 link.exe' + ;; + + *) + # Assume MSVC wrapper + library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib' + dynamic_linker='Win32 ld.exe' + ;; + esac + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; + +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' + soname_spec='$libname$release$major$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' + + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib" + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; + +dgux*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` + else + case $host_os in + freebsd[23].*) objformat=aout ;; + *) objformat=elf ;; + esac + fi + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + need_version=no + need_lib_prefix=no + ;; + freebsd-*) + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + need_version=yes + ;; + esac + shlibpath_var=LD_LIBRARY_PATH + case $host_os in + freebsd2.*) + shlibpath_overrides_runpath=yes + ;; + freebsd3.[01]* | freebsdelf3.[01]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ + freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + *) # from 4.6 on, and DragonFly + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + esac + ;; + +haiku*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + dynamic_linker="$host_os runtime_loader" + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LIBRARY_PATH + shlibpath_overrides_runpath=no + sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' + hardcode_into_libs=yes + ;; + +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + if test 32 = "$HPUX_IA64_MODE"; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + sys_lib_dlsearch_path_spec=/usr/lib/hpux32 + else + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + sys_lib_dlsearch_path_spec=/usr/lib/hpux64 + fi + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555, ... + postinstall_cmds='chmod 555 $lib' + # or fails outright, so override atomically: + install_override_mode=555 + ;; + +interix[3-9]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; + *) + if test yes = "$lt_cv_prog_gnu_ld"; then + version_type=linux # correct to gnu/linux during the next big refactor + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='$libname$release$shared_ext$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; + esac + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" + sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" + hardcode_into_libs=yes + ;; + +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; + +linux*android*) + version_type=none # Android doesn't support versioned libraries. + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext' + soname_spec='$libname$release$shared_ext' + finish_cmds= + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + dynamic_linker='Android linker' + # Don't embed -rpath directories since the linker doesn't support them. + hardcode_libdir_flag_spec='-L$libdir' + ;; + +# This must be glibc/ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + + # Some binutils ld are patched to set DT_RUNPATH + if ${lt_cv_shlibpath_overrides_runpath+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_shlibpath_overrides_runpath=no + save_LDFLAGS=$LDFLAGS + save_libdir=$libdir + eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \ + LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\"" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : + lt_cv_shlibpath_overrides_runpath=yes +fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS=$save_LDFLAGS + libdir=$save_libdir + +fi + + shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + # Ideally, we could use ldconfig to report *all* directores which are + # searched for libraries, however this is still not possible. Aside from not + # being certain /sbin/ldconfig is available, command + # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, + # even though it is searched at run-time. Try to do the best guess by + # appending ld.so.conf contents (and includes) to the search path. + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi + + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; + +netbsdelf*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='NetBSD ld.elf_so' + ;; + +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + +newsos6) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +*nto* | *qnx*) + version_type=qnx + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='ldqnx.so' + ;; + +openbsd* | bitrig*) + version_type=sunos + sys_lib_dlsearch_path_spec=/usr/lib + need_lib_prefix=no + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then + need_version=no + else + need_version=yes + fi + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +os2*) + libname_spec='$name' + version_type=windows + shrext_cmds=.dll + need_version=no + need_lib_prefix=no + # OS/2 can only load a DLL with a base name of 8 characters or less. + soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; + v=$($ECHO $release$versuffix | tr -d .-); + n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); + $ECHO $n$v`$shared_ext' + library_names_spec='${libname}_dll.$libext' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=BEGINLIBPATH + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + ;; + +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='$libname$release$shared_ext$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + +rdos*) + dynamic_linker=no + ;; + +solaris*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; + +sunos4*) + version_type=sunos + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test yes = "$with_gnu_ld"; then + need_lib_prefix=no + fi + need_version=yes + ;; + +sysv4 | sysv4.3*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + runpath_var=LD_RUN_PATH + ;; + siemens) + need_lib_prefix=no + ;; + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + ;; + esac + ;; + +sysv4*MP*) + if test -d /usr/nec; then + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' + soname_spec='$libname$shared_ext.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + version_type=sco + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + if test yes = "$with_gnu_ld"; then + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' + else + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' + case $host_os in + sco3.2v5*) + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" + ;; + esac + fi + sys_lib_dlsearch_path_spec='/usr/lib' + ;; + +tpf*) + # TPF is a cross-target only. Preferred cross-host = GNU/Linux. + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +uts4*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +*) + dynamic_linker=no + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 +$as_echo "$dynamic_linker" >&6; } +test no = "$dynamic_linker" && can_build_shared=no + +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test yes = "$GCC"; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +fi + +if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then + sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec +fi + +if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then + sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec +fi + +# remember unaugmented sys_lib_dlsearch_path content for libtool script decls... +configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec + +# ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code +func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" + +# to be used as default LT_SYS_LIBRARY_PATH value in generated libtool +configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 +$as_echo_n "checking how to hardcode library paths into programs... " >&6; } +hardcode_action= +if test -n "$hardcode_libdir_flag_spec" || + test -n "$runpath_var" || + test yes = "$hardcode_automatic"; then + + # We can hardcode non-existent directories. + if test no != "$hardcode_direct" && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, )" && + test no != "$hardcode_minus_L"; then + # Linking always hardcodes the temporary library directory. + hardcode_action=relink + else + # We can link without hardcoding, and we can hardcode nonexisting dirs. + hardcode_action=immediate + fi +else + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + hardcode_action=unsupported +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5 +$as_echo "$hardcode_action" >&6; } + +if test relink = "$hardcode_action" || + test yes = "$inherit_rpath"; then + # Fast installation is not supported + enable_fast_install=no +elif test yes = "$shlibpath_overrides_runpath" || + test no = "$enable_shared"; then + # Fast installation is not necessary + enable_fast_install=needless +fi + + + + + + + if test yes != "$enable_dlopen"; then + enable_dlopen=unknown + enable_dlopen_self=unknown + enable_dlopen_self_static=unknown +else + lt_cv_dlopen=no + lt_cv_dlopen_libs= + + case $host_os in + beos*) + lt_cv_dlopen=load_add_on + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + ;; + + mingw* | pw32* | cegcc*) + lt_cv_dlopen=LoadLibrary + lt_cv_dlopen_libs= + ;; + + cygwin*) + lt_cv_dlopen=dlopen + lt_cv_dlopen_libs= + ;; + + darwin*) + # if libdl is installed we need to link against it + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 +$as_echo_n "checking for dlopen in -ldl... " >&6; } +if ${ac_cv_lib_dl_dlopen+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldl $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dl_dlopen=yes +else + ac_cv_lib_dl_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 +$as_echo "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = xyes; then : + lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl +else + + lt_cv_dlopen=dyld + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + +fi + + ;; + + tpf*) + # Don't try to run any link tests for TPF. We know it's impossible + # because TPF is a cross-compiler, and we know how we open DSOs. + lt_cv_dlopen=dlopen + lt_cv_dlopen_libs= + lt_cv_dlopen_self=no + ;; + + *) + ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" +if test "x$ac_cv_func_shl_load" = xyes; then : + lt_cv_dlopen=shl_load +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 +$as_echo_n "checking for shl_load in -ldld... " >&6; } +if ${ac_cv_lib_dld_shl_load+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char shl_load (); +int +main () +{ +return shl_load (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dld_shl_load=yes +else + ac_cv_lib_dld_shl_load=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 +$as_echo "$ac_cv_lib_dld_shl_load" >&6; } +if test "x$ac_cv_lib_dld_shl_load" = xyes; then : + lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld +else + ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" +if test "x$ac_cv_func_dlopen" = xyes; then : + lt_cv_dlopen=dlopen +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 +$as_echo_n "checking for dlopen in -ldl... " >&6; } +if ${ac_cv_lib_dl_dlopen+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldl $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dl_dlopen=yes +else + ac_cv_lib_dl_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 +$as_echo "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = xyes; then : + lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 +$as_echo_n "checking for dlopen in -lsvld... " >&6; } +if ${ac_cv_lib_svld_dlopen+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lsvld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_svld_dlopen=yes +else + ac_cv_lib_svld_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 +$as_echo "$ac_cv_lib_svld_dlopen" >&6; } +if test "x$ac_cv_lib_svld_dlopen" = xyes; then : + lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 +$as_echo_n "checking for dld_link in -ldld... " >&6; } +if ${ac_cv_lib_dld_dld_link+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dld_link (); +int +main () +{ +return dld_link (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dld_dld_link=yes +else + ac_cv_lib_dld_dld_link=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 +$as_echo "$ac_cv_lib_dld_dld_link" >&6; } +if test "x$ac_cv_lib_dld_dld_link" = xyes; then : + lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld +fi + + +fi + + +fi + + +fi + + +fi + + +fi + + ;; + esac + + if test no = "$lt_cv_dlopen"; then + enable_dlopen=no + else + enable_dlopen=yes + fi + + case $lt_cv_dlopen in + dlopen) + save_CPPFLAGS=$CPPFLAGS + test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" + + save_LDFLAGS=$LDFLAGS + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" + + save_LIBS=$LIBS + LIBS="$lt_cv_dlopen_libs $LIBS" + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 +$as_echo_n "checking whether a program can dlopen itself... " >&6; } +if ${lt_cv_dlopen_self+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test yes = "$cross_compiling"; then : + lt_cv_dlopen_self=cross +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext <<_LT_EOF +#line $LINENO "configure" +#include "confdefs.h" + +#if HAVE_DLFCN_H +#include +#endif + +#include + +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif + +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif + +/* When -fvisibility=hidden is used, assume the code has been annotated + correspondingly for the symbols needed. */ +#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) +int fnord () __attribute__((visibility("default"))); +#endif + +int fnord () { return 42; } +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; + + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else + { + if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + else puts (dlerror ()); + } + /* dlclose (self); */ + } + else + puts (dlerror ()); + + return status; +} +_LT_EOF + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then + (./conftest; exit; ) >&5 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; + x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; + x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;; + esac + else : + # compilation failed + lt_cv_dlopen_self=no + fi +fi +rm -fr conftest* + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 +$as_echo "$lt_cv_dlopen_self" >&6; } + + if test yes = "$lt_cv_dlopen_self"; then + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 +$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } +if ${lt_cv_dlopen_self_static+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test yes = "$cross_compiling"; then : + lt_cv_dlopen_self_static=cross +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext <<_LT_EOF +#line $LINENO "configure" +#include "confdefs.h" + +#if HAVE_DLFCN_H +#include +#endif + +#include + +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif + +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif + +/* When -fvisibility=hidden is used, assume the code has been annotated + correspondingly for the symbols needed. */ +#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) +int fnord () __attribute__((visibility("default"))); +#endif + +int fnord () { return 42; } +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; + + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else + { + if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + else puts (dlerror ()); + } + /* dlclose (self); */ + } + else + puts (dlerror ()); + + return status; +} +_LT_EOF + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then + (./conftest; exit; ) >&5 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; + x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; + x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;; + esac + else : + # compilation failed + lt_cv_dlopen_self_static=no + fi +fi +rm -fr conftest* + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 +$as_echo "$lt_cv_dlopen_self_static" >&6; } + fi + + CPPFLAGS=$save_CPPFLAGS + LDFLAGS=$save_LDFLAGS + LIBS=$save_LIBS + ;; + esac + + case $lt_cv_dlopen_self in + yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; + *) enable_dlopen_self=unknown ;; + esac + + case $lt_cv_dlopen_self_static in + yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; + *) enable_dlopen_self_static=unknown ;; + esac +fi + + + + + + + + + + + + + + + + + +striplib= +old_striplib= +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 +$as_echo_n "checking whether stripping libraries is possible... " >&6; } +if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then + test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" + test -z "$striplib" && striplib="$STRIP --strip-unneeded" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else +# FIXME - insert some real tests, host_os isn't really good enough + case $host_os in + darwin*) + if test -n "$STRIP"; then + striplib="$STRIP -x" + old_striplib="$STRIP -S" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + ;; + esac +fi + + + + + + + + + + + + + # Report what library types will actually be built + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 +$as_echo_n "checking if libtool supports shared libraries... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 +$as_echo "$can_build_shared" >&6; } + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5 +$as_echo_n "checking whether to build shared libraries... " >&6; } + test no = "$can_build_shared" && enable_shared=no + + # On AIX, shared libraries and static libraries use the same namespace, and + # are all built from PIC. + case $host_os in + aix3*) + test yes = "$enable_shared" && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; + + aix[4-9]*) + if test ia64 != "$host_cpu"; then + case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in + yes,aix,yes) ;; # shared object as lib.so file only + yes,svr4,*) ;; # shared object as lib.so archive member only + yes,*) enable_static=no ;; # shared object in lib.a archive as well + esac + fi + ;; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 +$as_echo "$enable_shared" >&6; } + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5 +$as_echo_n "checking whether to build static libraries... " >&6; } + # Make sure either enable_shared or enable_static is yes. + test yes = "$enable_shared" || enable_static=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5 +$as_echo "$enable_static" >&6; } + + + + +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +CC=$lt_save_CC + + if test -n "$CXX" && ( test no != "$CXX" && + ( (test g++ = "$CXX" && `g++ -v >/dev/null 2>&1` ) || + (test g++ != "$CXX"))); then + ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5 +$as_echo_n "checking how to run the C++ preprocessor... " >&6; } +if test -z "$CXXCPP"; then + if ${ac_cv_prog_CXXCPP+:} false; then : + $as_echo_n "(cached) " >&6 +else + # Double quotes because CXXCPP needs to be expanded + for CXXCPP in "$CXX -E" "/lib/cpp" + do + ac_preproc_ok=false +for ac_cxx_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_cxx_try_cpp "$LINENO"; then : + +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_cxx_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + break +fi + + done + ac_cv_prog_CXXCPP=$CXXCPP + +fi + CXXCPP=$ac_cv_prog_CXXCPP +else + ac_cv_prog_CXXCPP=$CXXCPP +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 +$as_echo "$CXXCPP" >&6; } +ac_preproc_ok=false +for ac_cxx_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_cxx_try_cpp "$LINENO"; then : + +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_cxx_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + +else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check +See \`config.log' for more details" "$LINENO" 5; } +fi + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +else + _lt_caught_CXX_error=yes +fi + +ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + +archive_cmds_need_lc_CXX=no +allow_undefined_flag_CXX= +always_export_symbols_CXX=no +archive_expsym_cmds_CXX= +compiler_needs_object_CXX=no +export_dynamic_flag_spec_CXX= +hardcode_direct_CXX=no +hardcode_direct_absolute_CXX=no +hardcode_libdir_flag_spec_CXX= +hardcode_libdir_separator_CXX= +hardcode_minus_L_CXX=no +hardcode_shlibpath_var_CXX=unsupported +hardcode_automatic_CXX=no +inherit_rpath_CXX=no +module_cmds_CXX= +module_expsym_cmds_CXX= +link_all_deplibs_CXX=unknown +old_archive_cmds_CXX=$old_archive_cmds +reload_flag_CXX=$reload_flag +reload_cmds_CXX=$reload_cmds +no_undefined_flag_CXX= +whole_archive_flag_spec_CXX= +enable_shared_with_static_runtimes_CXX=no + +# Source file extension for C++ test sources. +ac_ext=cpp + +# Object file extension for compiled C++ test sources. +objext=o +objext_CXX=$objext + +# No sense in running all these tests if we already determined that +# the CXX compiler isn't working. Some variables (like enable_shared) +# are currently assumed to apply to all compilers on this platform, +# and will be corrupted by setting them based on a non-working compiler. +if test yes != "$_lt_caught_CXX_error"; then + # Code to be used in simple compile tests + lt_simple_compile_test_code="int some_variable = 0;" + + # Code to be used in simple link tests + lt_simple_link_test_code='int main(int, char *[]) { return(0); }' + + # ltmain only uses $CC for tagged configurations so make sure $CC is set. + + + + + + +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} + +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC + + + # save warnings/boilerplate of simple test code + ac_outfile=conftest.$ac_objext +echo "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$RM conftest* + + ac_outfile=conftest.$ac_objext +echo "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$RM -r conftest* + + + # Allow CC to be a program name with arguments. + lt_save_CC=$CC + lt_save_CFLAGS=$CFLAGS + lt_save_LD=$LD + lt_save_GCC=$GCC + GCC=$GXX + lt_save_with_gnu_ld=$with_gnu_ld + lt_save_path_LD=$lt_cv_path_LD + if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then + lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx + else + $as_unset lt_cv_prog_gnu_ld + fi + if test -n "${lt_cv_path_LDCXX+set}"; then + lt_cv_path_LD=$lt_cv_path_LDCXX + else + $as_unset lt_cv_path_LD + fi + test -z "${LDCXX+set}" || LD=$LDCXX + CC=${CXX-"c++"} + CFLAGS=$CXXFLAGS + compiler=$CC + compiler_CXX=$CC + func_cc_basename $compiler +cc_basename=$func_cc_basename_result + + + if test -n "$compiler"; then + # We don't want -fno-exception when compiling C++ code, so set the + # no_builtin_flag separately + if test yes = "$GXX"; then + lt_prog_compiler_no_builtin_flag_CXX=' -fno-builtin' + else + lt_prog_compiler_no_builtin_flag_CXX= + fi + + if test yes = "$GXX"; then + # Set up default GNU C++ configuration + + + +# Check whether --with-gnu-ld was given. +if test "${with_gnu_ld+set}" = set; then : + withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes +else + with_gnu_ld=no +fi + +ac_prog=ld +if test yes = "$GCC"; then + # Check if gcc -print-prog-name=ld gives a path. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 +$as_echo_n "checking for ld used by $CC... " >&6; } + case $host in + *-*-mingw*) + # gcc leaves a trailing carriage return, which upsets mingw + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; + *) + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; + esac + case $ac_prog in + # Accept absolute paths. + [\\/]* | ?:[\\/]*) + re_direlt='/[^/][^/]*/\.\./' + # Canonicalize the pathname of ld + ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` + while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do + ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` + done + test -z "$LD" && LD=$ac_prog + ;; + "") + # If it fails, then pretend we aren't using GCC. + ac_prog=ld + ;; + *) + # If it is relative, then search for the first ld in PATH. + with_gnu_ld=unknown + ;; + esac +elif test yes = "$with_gnu_ld"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 +$as_echo_n "checking for GNU ld... " >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 +$as_echo_n "checking for non-GNU ld... " >&6; } +fi +if ${lt_cv_path_LD+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$LD"; then + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS=$lt_save_ifs + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then + lt_cv_path_LD=$ac_dir/$ac_prog + # Check to see if the program is GNU ld. I'd rather use --version, + # but apparently some variants of GNU ld only accept -v. + # Break only if it was the GNU/non-GNU ld that we prefer. + case `"$lt_cv_path_LD" -v 2>&1 &5 +$as_echo "$LD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi +test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 +$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } +if ${lt_cv_prog_gnu_ld+:} false; then : + $as_echo_n "(cached) " >&6 +else + # I'd rather use --version here, but apparently some GNU lds only accept -v. +case `$LD -v 2>&1 &5 +$as_echo "$lt_cv_prog_gnu_ld" >&6; } +with_gnu_ld=$lt_cv_prog_gnu_ld + + + + + + + + # Check if GNU C++ uses GNU ld as the underlying linker, since the + # archiving commands below assume that GNU ld is being used. + if test yes = "$with_gnu_ld"; then + archive_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + + hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' + export_dynamic_flag_spec_CXX='$wl--export-dynamic' + + # If archive_cmds runs LD, not CC, wlarc should be empty + # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to + # investigate it a little bit more. (MM) + wlarc='$wl' + + # ancient GNU ld didn't support --whole-archive et. al. + if eval "`$CC -print-prog-name=ld` --help 2>&1" | + $GREP 'no-whole-archive' > /dev/null; then + whole_archive_flag_spec_CXX=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' + else + whole_archive_flag_spec_CXX= + fi + else + with_gnu_ld=no + wlarc= + + # A generic and very simple default shared library creation + # command for GNU C++ for the case where it uses the native + # linker, instead of GNU ld. If possible, this setting should + # overridden to take advantage of the native linker features on + # the platform it is being used on. + archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' + fi + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + + else + GXX=no + with_gnu_ld=no + wlarc= + fi + + # PORTME: fill in a description of your system's C++ link characteristics + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } + ld_shlibs_CXX=yes + case $host_os in + aix3*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + aix[4-9]*) + if test ia64 = "$host_cpu"; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag= + else + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # have runtime linking enabled, and use it for executables. + # For shared libraries, we enable/disable runtime linking + # depending on the kind of the shared library created - + # when "with_aix_soname,aix_use_runtimelinking" is: + # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables + # "aix,yes" lib.so shared, rtl:yes, for executables + # lib.a static archive + # "both,no" lib.so.V(shr.o) shared, rtl:yes + # lib.a(lib.so.V) shared, rtl:no, for executables + # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a(lib.so.V) shared, rtl:no + # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a static archive + case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) + for ld_flag in $LDFLAGS; do + case $ld_flag in + *-brtl*) + aix_use_runtimelinking=yes + break + ;; + esac + done + if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then + # With aix-soname=svr4, we create the lib.so.V shared archives only, + # so we don't have lib.a shared libs to link our executables. + # We have to force runtime linking in this case. + aix_use_runtimelinking=yes + LDFLAGS="$LDFLAGS -Wl,-brtl" + fi + ;; + esac + + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + archive_cmds_CXX='' + hardcode_direct_CXX=yes + hardcode_direct_absolute_CXX=yes + hardcode_libdir_separator_CXX=':' + link_all_deplibs_CXX=yes + file_list_spec_CXX='$wl-f,' + case $with_aix_soname,$aix_use_runtimelinking in + aix,*) ;; # no import file + svr4,* | *,yes) # use import file + # The Import File defines what to hardcode. + hardcode_direct_CXX=no + hardcode_direct_absolute_CXX=no + ;; + esac + + if test yes = "$GXX"; then + case $host_os in aix4.[012]|aix4.[012].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`$CC -print-prog-name=collect2` + if test -f "$collect2name" && + strings "$collect2name" | $GREP resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + hardcode_direct_CXX=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + hardcode_minus_L_CXX=yes + hardcode_libdir_flag_spec_CXX='-L$libdir' + hardcode_libdir_separator_CXX= + fi + esac + shared_flag='-shared' + if test yes = "$aix_use_runtimelinking"; then + shared_flag=$shared_flag' $wl-G' + fi + # Need to ensure runtime linking is disabled for the traditional + # shared library, or the linker may eventually find shared libraries + # /with/ Import File - we do not want to mix them. + shared_flag_aix='-shared' + shared_flag_svr4='-shared $wl-G' + else + # not using gcc + if test ia64 = "$host_cpu"; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test yes = "$aix_use_runtimelinking"; then + shared_flag='$wl-G' + else + shared_flag='$wl-bM:SRE' + fi + shared_flag_aix='$wl-bM:SRE' + shared_flag_svr4='$wl-G' + fi + fi + + export_dynamic_flag_spec_CXX='$wl-bexpall' + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to + # export. + always_export_symbols_CXX=yes + if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + # The "-G" linker flag allows undefined symbols. + no_undefined_flag_CXX='-bernotok' + # Determine the default libpath from the value encoded in an empty + # executable. + if test set = "${lt_cv_aix_libpath+set}"; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath__CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath__CXX"; then + lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath__CXX"; then + lt_cv_aix_libpath__CXX=/usr/lib:/lib + fi + +fi + + aix_libpath=$lt_cv_aix_libpath__CXX +fi + + hardcode_libdir_flag_spec_CXX='$wl-blibpath:$libdir:'"$aix_libpath" + + archive_expsym_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag + else + if test ia64 = "$host_cpu"; then + hardcode_libdir_flag_spec_CXX='$wl-R $libdir:/usr/lib:/lib' + allow_undefined_flag_CXX="-z nodefs" + archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an + # empty executable. + if test set = "${lt_cv_aix_libpath+set}"; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath__CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath__CXX"; then + lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath__CXX"; then + lt_cv_aix_libpath__CXX=/usr/lib:/lib + fi + +fi + + aix_libpath=$lt_cv_aix_libpath__CXX +fi + + hardcode_libdir_flag_spec_CXX='$wl-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + no_undefined_flag_CXX=' $wl-bernotok' + allow_undefined_flag_CXX=' $wl-berok' + if test yes = "$with_gnu_ld"; then + # We only use this code for GNU lds that support --whole-archive. + whole_archive_flag_spec_CXX='$wl--whole-archive$convenience $wl--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + whole_archive_flag_spec_CXX='$convenience' + fi + archive_cmds_need_lc_CXX=yes + archive_expsym_cmds_CXX='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' + # -brtl affects multiple linker settings, -berok does not and is overridden later + compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`' + if test svr4 != "$with_aix_soname"; then + # This is similar to how AIX traditionally builds its shared + # libraries. Need -bnortl late, we may have -brtl in LDFLAGS. + archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' + fi + if test aix != "$with_aix_soname"; then + archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' + else + # used by -dlpreopen to get the symbols + archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$MV $output_objdir/$realname.d/$soname $output_objdir' + fi + archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$RM -r $output_objdir/$realname.d' + fi + fi + ;; + + beos*) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + allow_undefined_flag_CXX=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + else + ld_shlibs_CXX=no + fi + ;; + + chorus*) + case $cc_basename in + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + cygwin* | mingw* | pw32* | cegcc*) + case $GXX,$cc_basename in + ,cl* | no,cl*) + # Native MSVC + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + hardcode_libdir_flag_spec_CXX=' ' + allow_undefined_flag_CXX=unsupported + always_export_symbols_CXX=yes + file_list_spec_CXX='@' + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=.dll + # FIXME: Setting linknames here is a bad hack. + archive_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' + archive_expsym_cmds_CXX='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then + cp "$export_symbols" "$output_objdir/$soname.def"; + echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; + else + $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, CXX)='true' + enable_shared_with_static_runtimes_CXX=yes + # Don't use ranlib + old_postinstall_cmds_CXX='chmod 644 $oldlib' + postlink_cmds_CXX='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile=$lt_outputfile.exe + lt_tool_outputfile=$lt_tool_outputfile.exe + ;; + esac~ + func_to_tool_file "$lt_outputfile"~ + if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # g++ + # _LT_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless, + # as there is no search path for DLLs. + hardcode_libdir_flag_spec_CXX='-L$libdir' + export_dynamic_flag_spec_CXX='$wl--export-all-symbols' + allow_undefined_flag_CXX=unsupported + always_export_symbols_CXX=no + enable_shared_with_static_runtimes_CXX=yes + + if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then + archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file, use it as + # is; otherwise, prepend EXPORTS... + archive_expsym_cmds_CXX='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + ld_shlibs_CXX=no + fi + ;; + esac + ;; + darwin* | rhapsody*) + + + archive_cmds_need_lc_CXX=no + hardcode_direct_CXX=no + hardcode_automatic_CXX=yes + hardcode_shlibpath_var_CXX=unsupported + if test yes = "$lt_cv_ld_force_load"; then + whole_archive_flag_spec_CXX='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' + + else + whole_archive_flag_spec_CXX='' + fi + link_all_deplibs_CXX=yes + allow_undefined_flag_CXX=$_lt_dar_allow_undefined + case $cc_basename in + ifort*|nagfor*) _lt_dar_can_shared=yes ;; + *) _lt_dar_can_shared=$GCC ;; + esac + if test yes = "$_lt_dar_can_shared"; then + output_verbose_link_cmd=func_echo_all + archive_cmds_CXX="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" + module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" + archive_expsym_cmds_CXX="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" + module_expsym_cmds_CXX="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" + if test yes != "$lt_cv_apple_cc_single_mod"; then + archive_cmds_CXX="\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dsymutil" + archive_expsym_cmds_CXX="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil" + fi + + else + ld_shlibs_CXX=no + fi + + ;; + + os2*) + hardcode_libdir_flag_spec_CXX='-L$libdir' + hardcode_minus_L_CXX=yes + allow_undefined_flag_CXX=unsupported + shrext_cmds=.dll + archive_cmds_CXX='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + archive_expsym_cmds_CXX='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + prefix_cmds="$SED"~ + if test EXPORTS = "`$SED 1q $export_symbols`"; then + prefix_cmds="$prefix_cmds -e 1d"; + fi~ + prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ + cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + old_archive_From_new_cmds_CXX='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + enable_shared_with_static_runtimes_CXX=yes + ;; + + dgux*) + case $cc_basename in + ec++*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + ghcx*) + # Green Hills C++ Compiler + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + freebsd2.*) + # C++ shared libraries reported to be fairly broken before + # switch to ELF + ld_shlibs_CXX=no + ;; + + freebsd-elf*) + archive_cmds_need_lc_CXX=no + ;; + + freebsd* | dragonfly*) + # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF + # conventions + ld_shlibs_CXX=yes + ;; + + haiku*) + archive_cmds_CXX='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + link_all_deplibs_CXX=yes + ;; + + hpux9*) + hardcode_libdir_flag_spec_CXX='$wl+b $wl$libdir' + hardcode_libdir_separator_CXX=: + export_dynamic_flag_spec_CXX='$wl-E' + hardcode_direct_CXX=yes + hardcode_minus_L_CXX=yes # Not in the search PATH, + # but as the default + # location of the library. + + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + aCC*) + archive_cmds_CXX='$RM $output_objdir/$soname~$CC -b $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test yes = "$GXX"; then + archive_cmds_CXX='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' + else + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + fi + ;; + esac + ;; + + hpux10*|hpux11*) + if test no = "$with_gnu_ld"; then + hardcode_libdir_flag_spec_CXX='$wl+b $wl$libdir' + hardcode_libdir_separator_CXX=: + + case $host_cpu in + hppa*64*|ia64*) + ;; + *) + export_dynamic_flag_spec_CXX='$wl-E' + ;; + esac + fi + case $host_cpu in + hppa*64*|ia64*) + hardcode_direct_CXX=no + hardcode_shlibpath_var_CXX=no + ;; + *) + hardcode_direct_CXX=yes + hardcode_direct_absolute_CXX=yes + hardcode_minus_L_CXX=yes # Not in the search PATH, + # but as the default + # location of the library. + ;; + esac + + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + aCC*) + case $host_cpu in + hppa*64*) + archive_cmds_CXX='$CC -b $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + ia64*) + archive_cmds_CXX='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + *) + archive_cmds_CXX='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + esac + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test yes = "$GXX"; then + if test no = "$with_gnu_ld"; then + case $host_cpu in + hppa*64*) + archive_cmds_CXX='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + ia64*) + archive_cmds_CXX='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + *) + archive_cmds_CXX='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + esac + fi + else + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + fi + ;; + esac + ;; + + interix[3-9]*) + hardcode_direct_CXX=no + hardcode_shlibpath_var_CXX=no + hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' + export_dynamic_flag_spec_CXX='$wl-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + archive_cmds_CXX='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + archive_expsym_cmds_CXX='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + irix5* | irix6*) + case $cc_basename in + CC*) + # SGI C++ + archive_cmds_CXX='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + + # Archives containing C++ object files must be created using + # "CC -ar", where "CC" is the IRIX C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + old_archive_cmds_CXX='$CC -ar -WR,-u -o $oldlib $oldobjs' + ;; + *) + if test yes = "$GXX"; then + if test no = "$with_gnu_ld"; then + archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + else + archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` -o $lib' + fi + fi + link_all_deplibs_CXX=yes + ;; + esac + hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' + hardcode_libdir_separator_CXX=: + inherit_rpath_CXX=yes + ;; + + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + archive_expsym_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib $wl-retain-symbols-file,$export_symbols; mv \$templib $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + + hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' + export_dynamic_flag_spec_CXX='$wl--export-dynamic' + + # Archives containing C++ object files must be created using + # "CC -Bstatic", where "CC" is the KAI C++ compiler. + old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' + ;; + icpc* | ecpc* ) + # Intel C++ + with_gnu_ld=yes + # version 8.0 and above of icpc choke on multiply defined symbols + # if we add $predep_objects and $postdep_objects, however 7.1 and + # earlier do not add the objects themselves. + case `$CC -V 2>&1` in + *"Version 7."*) + archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + ;; + *) # Version 8.0 or newer + tmp_idyn= + case $host_cpu in + ia64*) tmp_idyn=' -i_dynamic';; + esac + archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + ;; + esac + archive_cmds_need_lc_CXX=no + hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' + export_dynamic_flag_spec_CXX='$wl--export-dynamic' + whole_archive_flag_spec_CXX='$wl--whole-archive$convenience $wl--no-whole-archive' + ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler + case `$CC -V` in + *pgCC\ [1-5].* | *pgcpp\ [1-5].*) + prelink_cmds_CXX='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ + compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' + old_archive_cmds_CXX='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ + $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ + $RANLIB $oldlib' + archive_cmds_CXX='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + ;; + *) # Version 6 and above use weak symbols + archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + ;; + esac + + hardcode_libdir_flag_spec_CXX='$wl--rpath $wl$libdir' + export_dynamic_flag_spec_CXX='$wl--export-dynamic' + whole_archive_flag_spec_CXX='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + ;; + cxx*) + # Compaq C++ + archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib $wl-retain-symbols-file $wl$export_symbols' + + runpath_var=LD_RUN_PATH + hardcode_libdir_flag_spec_CXX='-rpath $libdir' + hardcode_libdir_separator_CXX=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' + ;; + xl* | mpixl* | bgxl*) + # IBM XL 8.0 on PPC, with GNU ld + hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' + export_dynamic_flag_spec_CXX='$wl--export-dynamic' + archive_cmds_CXX='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + if test yes = "$supports_anon_versioning"; then + archive_expsym_cmds_CXX='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' + fi + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + no_undefined_flag_CXX=' -zdefs' + archive_cmds_CXX='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + archive_expsym_cmds_CXX='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file $wl$export_symbols' + hardcode_libdir_flag_spec_CXX='-R$libdir' + whole_archive_flag_spec_CXX='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + compiler_needs_object_CXX=yes + + # Not sure whether something based on + # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 + # would be better. + output_verbose_link_cmd='func_echo_all' + + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' + ;; + esac + ;; + esac + ;; + + lynxos*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + + m88k*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + + mvs*) + case $cc_basename in + cxx*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + netbsd*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + archive_cmds_CXX='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' + wlarc= + hardcode_libdir_flag_spec_CXX='-R$libdir' + hardcode_direct_CXX=yes + hardcode_shlibpath_var_CXX=no + fi + # Workaround some broken pre-1.5 toolchains + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' + ;; + + *nto* | *qnx*) + ld_shlibs_CXX=yes + ;; + + openbsd* | bitrig*) + if test -f /usr/libexec/ld.so; then + hardcode_direct_CXX=yes + hardcode_shlibpath_var_CXX=no + hardcode_direct_absolute_CXX=yes + archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' + hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`"; then + archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file,$export_symbols -o $lib' + export_dynamic_flag_spec_CXX='$wl-E' + whole_archive_flag_spec_CXX=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' + fi + output_verbose_link_cmd=func_echo_all + else + ld_shlibs_CXX=no + fi + ;; + + osf3* | osf4* | osf5*) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + + hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' + hardcode_libdir_separator_CXX=: + + # Archives containing C++ object files must be created using + # the KAI C++ compiler. + case $host in + osf3*) old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' ;; + *) old_archive_cmds_CXX='$CC -o $oldlib $oldobjs' ;; + esac + ;; + RCC*) + # Rational C++ 2.4.1 + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + cxx*) + case $host in + osf3*) + allow_undefined_flag_CXX=' $wl-expect_unresolved $wl\*' + archive_cmds_CXX='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $soname `test -n "$verstring" && func_echo_all "$wl-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' + ;; + *) + allow_undefined_flag_CXX=' -expect_unresolved \*' + archive_cmds_CXX='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + archive_expsym_cmds_CXX='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ + echo "-hidden">> $lib.exp~ + $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname $wl-input $wl$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~ + $RM $lib.exp' + hardcode_libdir_flag_spec_CXX='-rpath $libdir' + ;; + esac + + hardcode_libdir_separator_CXX=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test yes,no = "$GXX,$with_gnu_ld"; then + allow_undefined_flag_CXX=' $wl-expect_unresolved $wl\*' + case $host in + osf3*) + archive_cmds_CXX='$CC -shared -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + ;; + *) + archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + ;; + esac + + hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' + hardcode_libdir_separator_CXX=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + + else + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + fi + ;; + esac + ;; + + psos*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + lcc*) + # Lucid + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + solaris*) + case $cc_basename in + CC* | sunCC*) + # Sun C++ 4.2, 5.x and Centerline C++ + archive_cmds_need_lc_CXX=yes + no_undefined_flag_CXX=' -zdefs' + archive_cmds_CXX='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G$allow_undefined_flag $wl-M $wl$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + hardcode_libdir_flag_spec_CXX='-R$libdir' + hardcode_shlibpath_var_CXX=no + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands '-z linker_flag'. + # Supported since Solaris 2.6 (maybe 2.5.1?) + whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract' + ;; + esac + link_all_deplibs_CXX=yes + + output_verbose_link_cmd='func_echo_all' + + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' + ;; + gcx*) + # Green Hills C++ Compiler + archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' + + # The C++ compiler must be used to create the archive. + old_archive_cmds_CXX='$CC $LDFLAGS -archive -o $oldlib $oldobjs' + ;; + *) + # GNU C++ compiler with Solaris linker + if test yes,no = "$GXX,$with_gnu_ld"; then + no_undefined_flag_CXX=' $wl-z ${wl}defs' + if $CC --version | $GREP -v '^2\.7' > /dev/null; then + archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' + archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -shared $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + else + # g++ 2.7 appears to require '-G' NOT '-shared' on this + # platform. + archive_cmds_CXX='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' + archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + fi + + hardcode_libdir_flag_spec_CXX='$wl-R $wl$libdir' + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + whole_archive_flag_spec_CXX='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' + ;; + esac + fi + ;; + esac + ;; + + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) + no_undefined_flag_CXX='$wl-z,text' + archive_cmds_need_lc_CXX=no + hardcode_shlibpath_var_CXX=no + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + archive_cmds_CXX='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + archive_cmds_CXX='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + sysv5* | sco3.2v5* | sco5v6*) + # Note: We CANNOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + no_undefined_flag_CXX='$wl-z,text' + allow_undefined_flag_CXX='$wl-z,nodefs' + archive_cmds_need_lc_CXX=no + hardcode_shlibpath_var_CXX=no + hardcode_libdir_flag_spec_CXX='$wl-R,$libdir' + hardcode_libdir_separator_CXX=':' + link_all_deplibs_CXX=yes + export_dynamic_flag_spec_CXX='$wl-Bexport' + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + archive_cmds_CXX='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + old_archive_cmds_CXX='$CC -Tprelink_objects $oldobjs~ + '"$old_archive_cmds_CXX" + reload_cmds_CXX='$CC -Tprelink_objects $reload_objs~ + '"$reload_cmds_CXX" + ;; + *) + archive_cmds_CXX='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + vxworks*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5 +$as_echo "$ld_shlibs_CXX" >&6; } + test no = "$ld_shlibs_CXX" && can_build_shared=no + + GCC_CXX=$GXX + LD_CXX=$LD + + ## CAVEAT EMPTOR: + ## There is no encapsulation within the following macros, do not change + ## the running order or otherwise move them around unless you know exactly + ## what you are doing... + # Dependencies to place before and after the object being linked: +predep_objects_CXX= +postdep_objects_CXX= +predeps_CXX= +postdeps_CXX= +compiler_lib_search_path_CXX= + +cat > conftest.$ac_ext <<_LT_EOF +class Foo +{ +public: + Foo (void) { a = 0; } +private: + int a; +}; +_LT_EOF + + +_lt_libdeps_save_CFLAGS=$CFLAGS +case "$CC $CFLAGS " in #( +*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; +*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; +*\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;; +esac + +if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + # Parse the compiler output and extract the necessary + # objects, libraries and library flags. + + # Sentinel used to keep track of whether or not we are before + # the conftest object file. + pre_test_object_deps_done=no + + for p in `eval "$output_verbose_link_cmd"`; do + case $prev$p in + + -L* | -R* | -l*) + # Some compilers place space between "-{L,R}" and the path. + # Remove the space. + if test x-L = "$p" || + test x-R = "$p"; then + prev=$p + continue + fi + + # Expand the sysroot to ease extracting the directories later. + if test -z "$prev"; then + case $p in + -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; + -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; + -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; + esac + fi + case $p in + =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; + esac + if test no = "$pre_test_object_deps_done"; then + case $prev in + -L | -R) + # Internal compiler library paths should come after those + # provided the user. The postdeps already come after the + # user supplied libs so there is no need to process them. + if test -z "$compiler_lib_search_path_CXX"; then + compiler_lib_search_path_CXX=$prev$p + else + compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} $prev$p" + fi + ;; + # The "-l" case would never come before the object being + # linked, so don't bother handling this case. + esac + else + if test -z "$postdeps_CXX"; then + postdeps_CXX=$prev$p + else + postdeps_CXX="${postdeps_CXX} $prev$p" + fi + fi + prev= + ;; + + *.lto.$objext) ;; # Ignore GCC LTO objects + *.$objext) + # This assumes that the test object file only shows up + # once in the compiler output. + if test "$p" = "conftest.$objext"; then + pre_test_object_deps_done=yes + continue + fi + + if test no = "$pre_test_object_deps_done"; then + if test -z "$predep_objects_CXX"; then + predep_objects_CXX=$p + else + predep_objects_CXX="$predep_objects_CXX $p" + fi + else + if test -z "$postdep_objects_CXX"; then + postdep_objects_CXX=$p + else + postdep_objects_CXX="$postdep_objects_CXX $p" + fi + fi + ;; + + *) ;; # Ignore the rest. + + esac + done + + # Clean up. + rm -f a.out a.exe +else + echo "libtool.m4: error: problem compiling CXX test program" +fi + +$RM -f confest.$objext +CFLAGS=$_lt_libdeps_save_CFLAGS + +# PORTME: override above test on systems where it is broken +case $host_os in +interix[3-9]*) + # Interix 3.5 installs completely hosed .la files for C++, so rather than + # hack all around it, let's just trust "g++" to DTRT. + predep_objects_CXX= + postdep_objects_CXX= + postdeps_CXX= + ;; +esac + + +case " $postdeps_CXX " in +*" -lc "*) archive_cmds_need_lc_CXX=no ;; +esac + compiler_lib_search_dirs_CXX= +if test -n "${compiler_lib_search_path_CXX}"; then + compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | $SED -e 's! -L! !g' -e 's!^ !!'` +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + lt_prog_compiler_wl_CXX= +lt_prog_compiler_pic_CXX= +lt_prog_compiler_static_CXX= + + + # C++ specific cases for pic, static, wl, etc. + if test yes = "$GXX"; then + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='-static' + + case $host_os in + aix*) + # All AIX code is PIC. + if test ia64 = "$host_cpu"; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static_CXX='-Bstatic' + fi + lt_prog_compiler_pic_CXX='-fPIC' + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + lt_prog_compiler_pic_CXX='-fPIC' + ;; + m68k) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the '-m68020' flag to GCC prevents building anything better, + # like '-m68040'. + lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4' + ;; + esac + ;; + + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + mingw* | cygwin* | os2* | pw32* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + lt_prog_compiler_pic_CXX='-DDLL_EXPORT' + case $host_os in + os2*) + lt_prog_compiler_static_CXX='$wl-static' + ;; + esac + ;; + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + lt_prog_compiler_pic_CXX='-fno-common' + ;; + *djgpp*) + # DJGPP does not support shared libraries at all + lt_prog_compiler_pic_CXX= + ;; + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + lt_prog_compiler_static_CXX= + ;; + interix[3-9]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + sysv4*MP*) + if test -d /usr/nec; then + lt_prog_compiler_pic_CXX=-Kconform_pic + fi + ;; + hpux*) + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag + # sets the default TLS model and affects inlining. + case $host_cpu in + hppa*64*) + ;; + *) + lt_prog_compiler_pic_CXX='-fPIC' + ;; + esac + ;; + *qnx* | *nto*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic_CXX='-fPIC -shared' + ;; + *) + lt_prog_compiler_pic_CXX='-fPIC' + ;; + esac + else + case $host_os in + aix[4-9]*) + # All AIX code is PIC. + if test ia64 = "$host_cpu"; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static_CXX='-Bstatic' + else + lt_prog_compiler_static_CXX='-bnso -bI:/lib/syscalls.exp' + fi + ;; + chorus*) + case $cc_basename in + cxch68*) + # Green Hills C++ Compiler + # _LT_TAGVAR(lt_prog_compiler_static, CXX)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" + ;; + esac + ;; + mingw* | cygwin* | os2* | pw32* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + lt_prog_compiler_pic_CXX='-DDLL_EXPORT' + ;; + dgux*) + case $cc_basename in + ec++*) + lt_prog_compiler_pic_CXX='-KPIC' + ;; + ghcx*) + # Green Hills C++ Compiler + lt_prog_compiler_pic_CXX='-pic' + ;; + *) + ;; + esac + ;; + freebsd* | dragonfly*) + # FreeBSD uses GNU C++ + ;; + hpux9* | hpux10* | hpux11*) + case $cc_basename in + CC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='$wl-a ${wl}archive' + if test ia64 != "$host_cpu"; then + lt_prog_compiler_pic_CXX='+Z' + fi + ;; + aCC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='$wl-a ${wl}archive' + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic_CXX='+Z' + ;; + esac + ;; + *) + ;; + esac + ;; + interix*) + # This is c89, which is MS Visual C++ (no shared libs) + # Anyone wants to do a port? + ;; + irix5* | irix6* | nonstopux*) + case $cc_basename in + CC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='-non_shared' + # CC pic flag -KPIC is the default. + ;; + *) + ;; + esac + ;; + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + case $cc_basename in + KCC*) + # KAI C++ Compiler + lt_prog_compiler_wl_CXX='--backend -Wl,' + lt_prog_compiler_pic_CXX='-fPIC' + ;; + ecpc* ) + # old Intel C++ for x86_64, which still supported -KPIC. + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-static' + ;; + icpc* ) + # Intel C++, used to be incompatible with GCC. + # ICC 10 doesn't accept -KPIC any more. + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-fPIC' + lt_prog_compiler_static_CXX='-static' + ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-fpic' + lt_prog_compiler_static_CXX='-Bstatic' + ;; + cxx*) + # Compaq C++ + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + lt_prog_compiler_pic_CXX= + lt_prog_compiler_static_CXX='-non_shared' + ;; + xlc* | xlC* | bgxl[cC]* | mpixl[cC]*) + # IBM XL 8.0, 9.0 on PPC and BlueGene + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-qpic' + lt_prog_compiler_static_CXX='-qstaticlink' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-Bstatic' + lt_prog_compiler_wl_CXX='-Qoption ld ' + ;; + esac + ;; + esac + ;; + lynxos*) + ;; + m88k*) + ;; + mvs*) + case $cc_basename in + cxx*) + lt_prog_compiler_pic_CXX='-W c,exportall' + ;; + *) + ;; + esac + ;; + netbsd* | netbsdelf*-gnu) + ;; + *qnx* | *nto*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic_CXX='-fPIC -shared' + ;; + osf3* | osf4* | osf5*) + case $cc_basename in + KCC*) + lt_prog_compiler_wl_CXX='--backend -Wl,' + ;; + RCC*) + # Rational C++ 2.4.1 + lt_prog_compiler_pic_CXX='-pic' + ;; + cxx*) + # Digital/Compaq C++ + lt_prog_compiler_wl_CXX='-Wl,' + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + lt_prog_compiler_pic_CXX= + lt_prog_compiler_static_CXX='-non_shared' + ;; + *) + ;; + esac + ;; + psos*) + ;; + solaris*) + case $cc_basename in + CC* | sunCC*) + # Sun C++ 4.2, 5.x and Centerline C++ + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-Bstatic' + lt_prog_compiler_wl_CXX='-Qoption ld ' + ;; + gcx*) + # Green Hills C++ Compiler + lt_prog_compiler_pic_CXX='-PIC' + ;; + *) + ;; + esac + ;; + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + lt_prog_compiler_pic_CXX='-pic' + lt_prog_compiler_static_CXX='-Bstatic' + ;; + lcc*) + # Lucid + lt_prog_compiler_pic_CXX='-pic' + ;; + *) + ;; + esac + ;; + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + case $cc_basename in + CC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-Bstatic' + ;; + esac + ;; + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + lt_prog_compiler_pic_CXX='-KPIC' + ;; + *) + ;; + esac + ;; + vxworks*) + ;; + *) + lt_prog_compiler_can_build_shared_CXX=no + ;; + esac + fi + +case $host_os in + # For platforms that do not support PIC, -DPIC is meaningless: + *djgpp*) + lt_prog_compiler_pic_CXX= + ;; + *) + lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC" + ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; } +if ${lt_cv_prog_compiler_pic_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic_CXX=$lt_prog_compiler_pic_CXX +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_pic_CXX" >&6; } +lt_prog_compiler_pic_CXX=$lt_cv_prog_compiler_pic_CXX + +# +# Check to make sure the PIC flag actually works. +# +if test -n "$lt_prog_compiler_pic_CXX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5 +$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... " >&6; } +if ${lt_cv_prog_compiler_pic_works_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic_works_CXX=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC" ## exclude from sc_useless_quotes_in_assignment + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_pic_works_CXX=yes + fi + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_pic_works_CXX" >&6; } + +if test yes = "$lt_cv_prog_compiler_pic_works_CXX"; then + case $lt_prog_compiler_pic_CXX in + "" | " "*) ;; + *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;; + esac +else + lt_prog_compiler_pic_CXX= + lt_prog_compiler_can_build_shared_CXX=no +fi + +fi + + + + + +# +# Check to make sure the static flag actually works. +# +wl=$lt_prog_compiler_wl_CXX eval lt_tmp_static_flag=\"$lt_prog_compiler_static_CXX\" +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 +$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } +if ${lt_cv_prog_compiler_static_works_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_static_works_CXX=no + save_LDFLAGS=$LDFLAGS + LDFLAGS="$LDFLAGS $lt_tmp_static_flag" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_static_works_CXX=yes + fi + else + lt_cv_prog_compiler_static_works_CXX=yes + fi + fi + $RM -r conftest* + LDFLAGS=$save_LDFLAGS + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_static_works_CXX" >&6; } + +if test yes = "$lt_cv_prog_compiler_static_works_CXX"; then + : +else + lt_prog_compiler_static_CXX= +fi + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o_CXX=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o_CXX=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; } + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o_CXX=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o_CXX=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; } + + + + +hard_links=nottested +if test no = "$lt_cv_prog_compiler_c_o_CXX" && test no != "$need_locks"; then + # do not overwrite the value of need_locks provided by the user + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 +$as_echo_n "checking if we can lock with hard links... " >&6; } + hard_links=yes + $RM conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 +$as_echo "$hard_links" >&6; } + if test no = "$hard_links"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5 +$as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;} + need_locks=warn + fi +else + need_locks=no +fi + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } + + export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' + case $host_os in + aix[4-9]*) + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to GNU nm, but means don't demangle to AIX nm. + # Without the "-l" option, or with the "-B" option, AIX nm treats + # weak defined symbols like other global defined symbols, whereas + # GNU nm marks them as "W". + # While the 'weak' keyword is ignored in the Export File, we need + # it in the Import File for the 'aix-soname' feature, so we have + # to replace the "-B" option with "-P" for AIX nm. + if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then + export_symbols_cmds_CXX='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' + else + export_symbols_cmds_CXX='`func_echo_all $NM | $SED -e '\''s/B\([^B]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && (substr(\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' + fi + ;; + pw32*) + export_symbols_cmds_CXX=$ltdll_cmds + ;; + cygwin* | mingw* | cegcc*) + case $cc_basename in + cl*) + exclude_expsyms_CXX='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' + ;; + *) + export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' + exclude_expsyms_CXX='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' + ;; + esac + ;; + linux* | k*bsd*-gnu | gnu*) + link_all_deplibs_CXX=no + ;; + *) + export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + ;; + esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5 +$as_echo "$ld_shlibs_CXX" >&6; } +test no = "$ld_shlibs_CXX" && can_build_shared=no + +with_gnu_ld_CXX=$with_gnu_ld + + + + + + +# +# Do we need to explicitly link libc? +# +case "x$archive_cmds_need_lc_CXX" in +x|xyes) + # Assume -lc should be added + archive_cmds_need_lc_CXX=yes + + if test yes,yes = "$GCC,$enable_shared"; then + case $archive_cmds_CXX in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 +$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } +if ${lt_cv_archive_cmds_need_lc_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + $RM conftest* + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$lt_prog_compiler_wl_CXX + pic_flag=$lt_prog_compiler_pic_CXX + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$allow_undefined_flag_CXX + allow_undefined_flag_CXX= + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 + (eval $archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + then + lt_cv_archive_cmds_need_lc_CXX=no + else + lt_cv_archive_cmds_need_lc_CXX=yes + fi + allow_undefined_flag_CXX=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc_CXX" >&5 +$as_echo "$lt_cv_archive_cmds_need_lc_CXX" >&6; } + archive_cmds_need_lc_CXX=$lt_cv_archive_cmds_need_lc_CXX + ;; + esac + fi + ;; +esac + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 +$as_echo_n "checking dynamic linker characteristics... " >&6; } + +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=.so +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" +need_lib_prefix=unknown +hardcode_into_libs=no + +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown + + + +case $host_os in +aix3*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname.a' + shlibpath_var=LIBPATH + + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='$libname$release$shared_ext$major' + ;; + +aix[4-9]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test ia64 = "$host_cpu"; then + # AIX 5 supports IA64 + library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line '#! .'. This would cause the generated library to + # depend on '.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[01] | aix4.[01].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then + : + else + can_build_shared=no + fi + ;; + esac + # Using Import Files as archive members, it is possible to support + # filename-based versioning of shared library archives on AIX. While + # this would work for both with and without runtime linking, it will + # prevent static linking of such archives. So we do filename-based + # shared library versioning with .so extension only, which is used + # when both runtime linking and shared linking is enabled. + # Unfortunately, runtime linking may impact performance, so we do + # not want this to be the default eventually. Also, we use the + # versioned .so libs for executables only if there is the -brtl + # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. + # To allow for filename-based versioning support, we need to create + # libNAME.so.V as an archive file, containing: + # *) an Import File, referring to the versioned filename of the + # archive as well as the shared archive member, telling the + # bitwidth (32 or 64) of that shared object, and providing the + # list of exported symbols of that shared object, eventually + # decorated with the 'weak' keyword + # *) the shared object with the F_LOADONLY flag set, to really avoid + # it being seen by the linker. + # At run time we better use the real file rather than another symlink, + # but for link time we create the symlink libNAME.so -> libNAME.so.V + + case $with_aix_soname,$aix_use_runtimelinking in + # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + aix,yes) # traditional libtool + dynamic_linker='AIX unversionable lib.so' + # If using run time linking (on AIX 4.2 or later) use lib.so + # instead of lib.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + ;; + aix,no) # traditional AIX only + dynamic_linker='AIX lib.a(lib.so.V)' + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='$libname$release.a $libname.a' + soname_spec='$libname$release$shared_ext$major' + ;; + svr4,*) # full svr4 only + dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)" + library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' + # We do not specify a path in Import Files, so LIBPATH fires. + shlibpath_overrides_runpath=yes + ;; + *,yes) # both, prefer svr4 + dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)" + library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' + # unpreferred sharedlib libNAME.a needs extra handling + postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' + postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' + # We do not specify a path in Import Files, so LIBPATH fires. + shlibpath_overrides_runpath=yes + ;; + *,no) # both, prefer aix + dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)" + library_names_spec='$libname$release.a $libname.a' + soname_spec='$libname$release$shared_ext$major' + # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling + postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' + postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' + ;; + esac + shlibpath_var=LIBPATH + fi + ;; + +amigaos*) + case $host_cpu in + powerpc) + # Since July 2007 AmigaOS4 officially supports .so libraries. + # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + ;; + m68k) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; $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' + ;; + esac + ;; + +beos*) + library_names_spec='$libname$shared_ext' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; + +bsdi[45]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; + +cygwin* | mingw* | pw32* | cegcc*) + version_type=windows + shrext_cmds=.dll + need_version=no + need_lib_prefix=no + + case $GCC,$cc_basename in + yes,*) + # gcc + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + + case $host_os in + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' + + ;; + mingw* | cegcc*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' + ;; + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' + ;; + esac + dynamic_linker='Win32 ld.exe' + ;; + + *,cl*) + # Native MSVC + libname_spec='$name' + soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' + library_names_spec='$libname.dll.lib' + + case $build_os in + mingw*) + sys_lib_search_path_spec= + lt_save_ifs=$IFS + IFS=';' + for lt_path in $LIB + do + IFS=$lt_save_ifs + # Let DOS variable expansion print the short 8.3 style file name. + lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` + sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" + done + IFS=$lt_save_ifs + # Convert to MSYS style. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` + ;; + cygwin*) + # Convert to unix form, then to dos form, then back to unix form + # but this time dos style (no spaces!) so that the unix form looks + # like /cygdrive/c/PROGRA~1:/cygdr... + sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` + sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` + sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + ;; + *) + sys_lib_search_path_spec=$LIB + if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then + # It is most probably a Windows format PATH. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + # FIXME: find the short name or the path components, as spaces are + # common. (e.g. "Program Files" -> "PROGRA~1") + ;; + esac + + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + dynamic_linker='Win32 link.exe' + ;; + + *) + # Assume MSVC wrapper + library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib' + dynamic_linker='Win32 ld.exe' + ;; + esac + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; + +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' + soname_spec='$libname$release$major$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' + + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; + +dgux*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` + else + case $host_os in + freebsd[23].*) objformat=aout ;; + *) objformat=elf ;; + esac + fi + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + need_version=no + need_lib_prefix=no + ;; + freebsd-*) + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + need_version=yes + ;; + esac + shlibpath_var=LD_LIBRARY_PATH + case $host_os in + freebsd2.*) + shlibpath_overrides_runpath=yes + ;; + freebsd3.[01]* | freebsdelf3.[01]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ + freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + *) # from 4.6 on, and DragonFly + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + esac + ;; + +haiku*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + dynamic_linker="$host_os runtime_loader" + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LIBRARY_PATH + shlibpath_overrides_runpath=no + sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' + hardcode_into_libs=yes + ;; + +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + if test 32 = "$HPUX_IA64_MODE"; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + sys_lib_dlsearch_path_spec=/usr/lib/hpux32 + else + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + sys_lib_dlsearch_path_spec=/usr/lib/hpux64 + fi + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555, ... + postinstall_cmds='chmod 555 $lib' + # or fails outright, so override atomically: + install_override_mode=555 + ;; + +interix[3-9]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; + *) + if test yes = "$lt_cv_prog_gnu_ld"; then + version_type=linux # correct to gnu/linux during the next big refactor + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='$libname$release$shared_ext$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; + esac + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" + sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" + hardcode_into_libs=yes + ;; + +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; + +linux*android*) + version_type=none # Android doesn't support versioned libraries. + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext' + soname_spec='$libname$release$shared_ext' + finish_cmds= + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + dynamic_linker='Android linker' + # Don't embed -rpath directories since the linker doesn't support them. + hardcode_libdir_flag_spec_CXX='-L$libdir' + ;; + +# This must be glibc/ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + + # Some binutils ld are patched to set DT_RUNPATH + if ${lt_cv_shlibpath_overrides_runpath+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_shlibpath_overrides_runpath=no + save_LDFLAGS=$LDFLAGS + save_libdir=$libdir + eval "libdir=/foo; wl=\"$lt_prog_compiler_wl_CXX\"; \ + LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec_CXX\"" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_link "$LINENO"; then : + if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : + lt_cv_shlibpath_overrides_runpath=yes +fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS=$save_LDFLAGS + libdir=$save_libdir + +fi + + shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + # Ideally, we could use ldconfig to report *all* directores which are + # searched for libraries, however this is still not possible. Aside from not + # being certain /sbin/ldconfig is available, command + # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, + # even though it is searched at run-time. Try to do the best guess by + # appending ld.so.conf contents (and includes) to the search path. + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi + + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; + +netbsdelf*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='NetBSD ld.elf_so' + ;; + +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + +newsos6) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +*nto* | *qnx*) + version_type=qnx + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='ldqnx.so' + ;; + +openbsd* | bitrig*) + version_type=sunos + sys_lib_dlsearch_path_spec=/usr/lib + need_lib_prefix=no + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then + need_version=no + else + need_version=yes + fi + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +os2*) + libname_spec='$name' + version_type=windows + shrext_cmds=.dll + need_version=no + need_lib_prefix=no + # OS/2 can only load a DLL with a base name of 8 characters or less. + soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; + v=$($ECHO $release$versuffix | tr -d .-); + n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); + $ECHO $n$v`$shared_ext' + library_names_spec='${libname}_dll.$libext' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=BEGINLIBPATH + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + ;; + +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='$libname$release$shared_ext$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + +rdos*) + dynamic_linker=no + ;; + +solaris*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; + +sunos4*) + version_type=sunos + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test yes = "$with_gnu_ld"; then + need_lib_prefix=no + fi + need_version=yes + ;; + +sysv4 | sysv4.3*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + runpath_var=LD_RUN_PATH + ;; + siemens) + need_lib_prefix=no + ;; + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + ;; + esac + ;; + +sysv4*MP*) + if test -d /usr/nec; then + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' + soname_spec='$libname$shared_ext.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + version_type=sco + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + if test yes = "$with_gnu_ld"; then + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' + else + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' + case $host_os in + sco3.2v5*) + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" + ;; + esac + fi + sys_lib_dlsearch_path_spec='/usr/lib' + ;; + +tpf*) + # TPF is a cross-target only. Preferred cross-host = GNU/Linux. + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +uts4*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +*) + dynamic_linker=no + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 +$as_echo "$dynamic_linker" >&6; } +test no = "$dynamic_linker" && can_build_shared=no + +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test yes = "$GCC"; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +fi + +if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then + sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec +fi + +if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then + sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec +fi + +# remember unaugmented sys_lib_dlsearch_path content for libtool script decls... +configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec + +# ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code +func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" + +# to be used as default LT_SYS_LIBRARY_PATH value in generated libtool +configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 +$as_echo_n "checking how to hardcode library paths into programs... " >&6; } +hardcode_action_CXX= +if test -n "$hardcode_libdir_flag_spec_CXX" || + test -n "$runpath_var_CXX" || + test yes = "$hardcode_automatic_CXX"; then + + # We can hardcode non-existent directories. + if test no != "$hardcode_direct_CXX" && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, CXX)" && + test no != "$hardcode_minus_L_CXX"; then + # Linking always hardcodes the temporary library directory. + hardcode_action_CXX=relink + else + # We can link without hardcoding, and we can hardcode nonexisting dirs. + hardcode_action_CXX=immediate + fi +else + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + hardcode_action_CXX=unsupported +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_CXX" >&5 +$as_echo "$hardcode_action_CXX" >&6; } + +if test relink = "$hardcode_action_CXX" || + test yes = "$inherit_rpath_CXX"; then + # Fast installation is not supported + enable_fast_install=no +elif test yes = "$shlibpath_overrides_runpath" || + test no = "$enable_shared"; then + # Fast installation is not necessary + enable_fast_install=needless +fi + + + + + + + + fi # test -n "$compiler" + + CC=$lt_save_CC + CFLAGS=$lt_save_CFLAGS + LDCXX=$LD + LD=$lt_save_LD + GCC=$lt_save_GCC + with_gnu_ld=$lt_save_with_gnu_ld + lt_cv_path_LDCXX=$lt_cv_path_LD + lt_cv_path_LD=$lt_save_path_LD + lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld + lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld +fi # test yes != "$_lt_caught_CXX_error" + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + + + + + + + + + + + + + + + ac_config_commands="$ac_config_commands libtool" + + + + +# Only expand once: + + +if test -n "$ac_tool_prefix"; then + for ac_prog in windres + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_WINDRES+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$WINDRES"; then + ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_WINDRES="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +WINDRES=$ac_cv_prog_WINDRES +if test -n "$WINDRES"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5 +$as_echo "$WINDRES" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$WINDRES" && break + done +fi +if test -z "$WINDRES"; then + ac_ct_WINDRES=$WINDRES + for ac_prog in windres +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_WINDRES+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_WINDRES"; then + ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_WINDRES="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES +if test -n "$ac_ct_WINDRES"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5 +$as_echo "$ac_ct_WINDRES" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$ac_ct_WINDRES" && break +done + + if test "x$ac_ct_WINDRES" = x; then + WINDRES="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + WINDRES=$ac_ct_WINDRES + fi +fi + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 +$as_echo_n "checking whether byte ordering is bigendian... " >&6; } +if ${ac_cv_c_bigendian+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_cv_c_bigendian=unknown + # See if we're dealing with a universal compiler. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifndef __APPLE_CC__ + not a universal capable compiler + #endif + typedef int dummy; + +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + + # Check for potential -arch flags. It is not universal unless + # there are at least two -arch flags with different values. + ac_arch= + ac_prev= + for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do + if test -n "$ac_prev"; then + case $ac_word in + i?86 | x86_64 | ppc | ppc64) + if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then + ac_arch=$ac_word + else + ac_cv_c_bigendian=universal + break + fi + ;; + esac + ac_prev= + elif test "x$ac_word" = "x-arch"; then + ac_prev=arch + fi + done +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + if test $ac_cv_c_bigendian = unknown; then + # See if sys/param.h defines the BYTE_ORDER macro. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + #include + +int +main () +{ +#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ + && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ + && LITTLE_ENDIAN) + bogus endian macros + #endif + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + # It does; now see whether it defined to BIG_ENDIAN or not. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + #include + +int +main () +{ +#if BYTE_ORDER != BIG_ENDIAN + not big endian + #endif + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_bigendian=yes +else + ac_cv_c_bigendian=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi + if test $ac_cv_c_bigendian = unknown; then + # See if defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + +int +main () +{ +#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) + bogus endian macros + #endif + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + # It does; now see whether it defined to _BIG_ENDIAN or not. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + +int +main () +{ +#ifndef _BIG_ENDIAN + not big endian + #endif + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_bigendian=yes +else + ac_cv_c_bigendian=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi + if test $ac_cv_c_bigendian = unknown; then + # Compile a test program. + if test "$cross_compiling" = yes; then : + # Try to guess by grepping values from an object file. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +short int ascii_mm[] = + { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; + short int ascii_ii[] = + { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; + int use_ascii (int i) { + return ascii_mm[i] + ascii_ii[i]; + } + short int ebcdic_ii[] = + { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; + short int ebcdic_mm[] = + { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; + int use_ebcdic (int i) { + return ebcdic_mm[i] + ebcdic_ii[i]; + } + extern int foo; + +int +main () +{ +return use_ascii (foo) == use_ebcdic (foo); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then + ac_cv_c_bigendian=yes + fi + if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then + if test "$ac_cv_c_bigendian" = unknown; then + ac_cv_c_bigendian=no + else + # finding both strings is unlikely to happen, but who knows? + ac_cv_c_bigendian=unknown + fi + fi +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ + + /* Are we little or big endian? From Harbison&Steele. */ + union + { + long int l; + char c[sizeof (long int)]; + } u; + u.l = 1; + return u.c[sizeof (long int) - 1] == 1; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_c_bigendian=no +else + ac_cv_c_bigendian=yes +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 +$as_echo "$ac_cv_c_bigendian" >&6; } + case $ac_cv_c_bigendian in #( + yes) + $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h +;; #( + no) + ;; #( + universal) + +$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h + + ;; #( + *) + as_fn_error $? "unknown endianness + presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; + esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 +$as_echo_n "checking for inline... " >&6; } +if ${ac_cv_c_inline+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_cv_c_inline=no +for ac_kw in inline __inline__ __inline; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifndef __cplusplus +typedef int foo_t; +static $ac_kw foo_t static_foo () {return 0; } +$ac_kw foo_t foo () {return 0; } +#endif + +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_inline=$ac_kw +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + test "$ac_cv_c_inline" != no && break +done + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 +$as_echo "$ac_cv_c_inline" >&6; } + +case $ac_cv_c_inline in + inline | yes) ;; + *) + case $ac_cv_c_inline in + no) ac_val=;; + *) ac_val=$ac_cv_c_inline;; + esac + cat >>confdefs.h <<_ACEOF +#ifndef __cplusplus +#define inline $ac_val +#endif +_ACEOF + ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5 +$as_echo_n "checking for working volatile... " >&6; } +if ${ac_cv_c_volatile+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + +volatile int x; +int * volatile y = (int *) 0; +return !x && !y; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_volatile=yes +else + ac_cv_c_volatile=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5 +$as_echo "$ac_cv_c_volatile" >&6; } +if test $ac_cv_c_volatile = no; then + +$as_echo "#define volatile /**/" >>confdefs.h + +fi + + + + + + + +if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. +set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_PKG_CONFIG+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $PKG_CONFIG in + [\\/]* | ?:[\\/]*) + ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; +esac +fi +PKG_CONFIG=$ac_cv_path_PKG_CONFIG +if test -n "$PKG_CONFIG"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 +$as_echo "$PKG_CONFIG" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_path_PKG_CONFIG"; then + ac_pt_PKG_CONFIG=$PKG_CONFIG + # Extract the first word of "pkg-config", so it can be a program name with args. +set dummy pkg-config; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $ac_pt_PKG_CONFIG in + [\\/]* | ?:[\\/]*) + ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; +esac +fi +ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG +if test -n "$ac_pt_PKG_CONFIG"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 +$as_echo "$ac_pt_PKG_CONFIG" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_pt_PKG_CONFIG" = x; then + PKG_CONFIG="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + PKG_CONFIG=$ac_pt_PKG_CONFIG + fi +else + PKG_CONFIG="$ac_cv_path_PKG_CONFIG" +fi + +fi +if test -n "$PKG_CONFIG"; then + _pkg_min_version=0.9.0 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5 +$as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } + if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + PKG_CONFIG="" + fi +fi + + +for ac_prog in doxygen +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DOXYGEN+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$DOXYGEN"; then + ac_cv_prog_DOXYGEN="$DOXYGEN" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DOXYGEN="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +DOXYGEN=$ac_cv_prog_DOXYGEN +if test -n "$DOXYGEN"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOXYGEN" >&5 +$as_echo "$DOXYGEN" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$DOXYGEN" && break +done + + if test x$DOXYGEN = xdoxygen; then + HAVE_DOXYGEN_TRUE= + HAVE_DOXYGEN_FALSE='#' +else + HAVE_DOXYGEN_TRUE='#' + HAVE_DOXYGEN_FALSE= +fi + + + +pentium=no +cpu64=no +case "$host_cpu" in + i586 | i686 | i786 ) + pentium=yes + +$as_echo "#define PENTIUM 1" >>confdefs.h + + ;; + x86_64* ) + pentium=yes + cpu64=yes + +$as_echo "#define X86_64_SYSTEM 1" >>confdefs.h + + ;; +esac + + if test x$cpu64 = xyes; then + X86_64_SYSTEM_TRUE= + X86_64_SYSTEM_FALSE='#' +else + X86_64_SYSTEM_TRUE='#' + X86_64_SYSTEM_FALSE= +fi + + + + + + + +for ac_header in alloca.h stdio.h inttypes.h stdint.h stdlib.h math.h \ + string.h stdarg.h malloc.h float.h time.h sys/time.h \ + limits.h stddef.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + + +opcode=no +gimpact=no + +# Check whether --with-trimesh was given. +if test "${with_trimesh+set}" = set; then : + withval=$with_trimesh; trimesh=$withval +else + trimesh=opcode + +fi + +if test "$trimesh" = opcode +then + opcode=yes +fi +if test "$trimesh" = gimpact +then + gimpact=yes +fi + + if test $opcode = yes; then + OPCODE_TRUE= + OPCODE_FALSE='#' +else + OPCODE_TRUE='#' + OPCODE_FALSE= +fi + + if test $gimpact = yes; then + GIMPACT_TRUE= + GIMPACT_FALSE='#' +else + GIMPACT_TRUE='#' + GIMPACT_FALSE= +fi + + if test $opcode = yes -o $gimpact = yes; then + TRIMESH_TRUE= + TRIMESH_FALSE='#' +else + TRIMESH_TRUE='#' + TRIMESH_FALSE= +fi + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if double precision is requested" >&5 +$as_echo_n "checking if double precision is requested... " >&6; } +# Check whether --enable-double-precision was given. +if test "${enable_double_precision+set}" = set; then : + enableval=$enable_double_precision; usedouble=$enableval +else + usedouble=no +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $usedouble" >&5 +$as_echo "$usedouble" >&6; } +if test "$usedouble" = yes; +then + ODE_PRECISION=dDOUBLE +else + ODE_PRECISION=dSINGLE +fi + + + + +# Check whether --with-drawstuff was given. +if test "${with_drawstuff+set}" = set; then : + withval=$with_drawstuff; drawstuff=$withval +else + drawstuff= +fi + + +EXTRA_LIBTOOL_LDFLAGS= +case "$host_os" in + cygwin* | mingw*) + if test "x$drawstuff" = x + then + drawstuff="Win32" # if in a Windows enviroment + fi + EXTRA_LIBTOOL_LDFLAGS="-no-undefined" + ;; + *apple* | *darwin*) # For Mac OS X + if test "x$drawstuff" = x + then + drawstuff="OSX" + fi + CC="$CXX" + LINK="$CXXLINK" + ;; + *) + if test "x$drawstuff" = x + then + drawstuff="X11" # if anything else default to X11 + fi + ;; +esac + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking which drawstuff lib to build" >&5 +$as_echo_n "checking which drawstuff lib to build... " >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $drawstuff" >&5 +$as_echo "$drawstuff" >&6; } + +if test "x$drawstuff" = "xX11" +then + # The built-in macro, X_PATH, causes too many problems, these days everyone uses Xorg, + # so we can ask pkg-config to find it for us. + +pkg_failed=no +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for X11" >&5 +$as_echo_n "checking for X11... " >&6; } + +if test -n "$X11_CFLAGS"; then + pkg_cv_X11_CFLAGS="$X11_CFLAGS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"x11\""; } >&5 + ($PKG_CONFIG --exists --print-errors "x11") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + pkg_cv_X11_CFLAGS=`$PKG_CONFIG --cflags "x11" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi +if test -n "$X11_LIBS"; then + pkg_cv_X11_LIBS="$X11_LIBS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"x11\""; } >&5 + ($PKG_CONFIG --exists --print-errors "x11") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + pkg_cv_X11_LIBS=`$PKG_CONFIG --libs "x11" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi + + + +if test $pkg_failed = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + +if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then + _pkg_short_errors_supported=yes +else + _pkg_short_errors_supported=no +fi + if test $_pkg_short_errors_supported = yes; then + X11_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "x11" 2>&1` + else + X11_PKG_ERRORS=`$PKG_CONFIG --print-errors "x11" 2>&1` + fi + # Put the nasty error message in config.log where it belongs + echo "$X11_PKG_ERRORS" >&5 + + drawstuff="none" +elif test $pkg_failed = untried; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + drawstuff="none" +else + X11_CFLAGS=$pkg_cv_X11_CFLAGS + X11_LIBS=$pkg_cv_X11_LIBS + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + +fi +fi + +if test "x$drawstuff" = "xOSX"; then + +$as_echo "#define HAVE_APPLE_OPENGL_FRAMEWORK 1" >>confdefs.h + + GL_LIBS="-framework OpenGL -framework GLUT" +elif test "x$drawstuff" != "xnone"; then + have_gl_headers=yes + for ac_header in GL/gl.h GL/glu.h GL/glext.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "#ifdef WIN32 + #include + #endif + #if HAVE_GL_GL_H + #include + #endif + #if HAVE_GL_GLU_H + #include + #endif + +" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +else + have_gl_headers=no +fi + +done + + have_gl=no + have_glu=no + TEMP_LDFLAGS="$LDFLAGS" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lGL" >&5 +$as_echo_n "checking for main in -lGL... " >&6; } +if ${ac_cv_lib_GL_main+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lGL $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + +int +main () +{ +return main (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_GL_main=yes +else + ac_cv_lib_GL_main=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_GL_main" >&5 +$as_echo "$ac_cv_lib_GL_main" >&6; } +if test "x$ac_cv_lib_GL_main" = xyes; then : + GL_LIBS="-lGL"; have_gl=yes +fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lGLU" >&5 +$as_echo_n "checking for main in -lGLU... " >&6; } +if ${ac_cv_lib_GLU_main+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lGLU -lGL $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + +int +main () +{ +return main (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_GLU_main=yes +else + ac_cv_lib_GLU_main=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_GLU_main" >&5 +$as_echo "$ac_cv_lib_GLU_main" >&6; } +if test "x$ac_cv_lib_GLU_main" = xyes; then : + GL_LIBS="-lGLU $GL_LIBS"; have_glu=yes +fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lopengl32" >&5 +$as_echo_n "checking for main in -lopengl32... " >&6; } +if ${ac_cv_lib_opengl32_main+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lopengl32 $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + +int +main () +{ +return main (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_opengl32_main=yes +else + ac_cv_lib_opengl32_main=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_opengl32_main" >&5 +$as_echo "$ac_cv_lib_opengl32_main" >&6; } +if test "x$ac_cv_lib_opengl32_main" = xyes; then : + GL_LIBS="-lopengl32"; have_gl=yes +fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lglu32" >&5 +$as_echo_n "checking for main in -lglu32... " >&6; } +if ${ac_cv_lib_glu32_main+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lglu32 -lopengl32 $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + +int +main () +{ +return main (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_glu32_main=yes +else + ac_cv_lib_glu32_main=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_glu32_main" >&5 +$as_echo "$ac_cv_lib_glu32_main" >&6; } +if test "x$ac_cv_lib_glu32_main" = xyes; then : + GL_LIBS="-lglu32 $GL_LIBS"; have_glu=yes +fi + + LDFLAGS="$TEMP_LDFLAGS" + if test $have_gl = no -o $have_glu = no -o $have_gl_headers = no; then + drawstuff="none" + fi +fi + + + if test x$drawstuff = xWin32; then + WIN32_TRUE= + WIN32_FALSE='#' +else + WIN32_TRUE='#' + WIN32_FALSE= +fi + + if test x$drawstuff = xX11; then + X11_TRUE= + X11_FALSE='#' +else + X11_TRUE='#' + X11_FALSE= +fi + + if test x$drawstuff = xOSX; then + OSX_TRUE= + OSX_FALSE='#' +else + OSX_TRUE='#' + OSX_FALSE= +fi + + if test x$drawstuff != xnone; then + ENABLE_DRAWSTUFF_TRUE= + ENABLE_DRAWSTUFF_FALSE='#' +else + ENABLE_DRAWSTUFF_TRUE='#' + ENABLE_DRAWSTUFF_FALSE= +fi + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if demos should be built" >&5 +$as_echo_n "checking if demos should be built... " >&6; } +# Check whether --enable-demos was given. +if test "${enable_demos+set}" = set; then : + enableval=$enable_demos; enable_demos=$enableval +else + enable_demos=yes +fi + +if test x$drawstuff = xnone -a x$enable_demos = xyes ; then + enable_demos=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_demos" >&5 +$as_echo "$enable_demos" >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Demos will not be built because OpenGL doesn't seem to work. See \`config.log' for details." >&5 +$as_echo "$as_me: WARNING: Demos will not be built because OpenGL doesn't seem to work. See \`config.log' for details." >&2;} +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_demos" >&5 +$as_echo "$enable_demos" >&6; } +fi + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lstdc++" >&5 +$as_echo_n "checking for main in -lstdc++... " >&6; } +if ${ac_cv_lib_stdcpp_main+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lstdc++ $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + +int +main () +{ +return main (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_stdcpp_main=yes +else + ac_cv_lib_stdcpp_main=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_stdcpp_main" >&5 +$as_echo "$ac_cv_lib_stdcpp_main" >&6; } +if test "x$ac_cv_lib_stdcpp_main" = xyes; then : + LIBSTDCXX="-lstdc++" +else + LIBSTDCXX= +fi + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lpthread" >&5 +$as_echo_n "checking for main in -lpthread... " >&6; } +if ${ac_cv_lib_pthread_main+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lpthread $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + +int +main () +{ +return main (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_pthread_main=yes +else + ac_cv_lib_pthread_main=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_main" >&5 +$as_echo "$ac_cv_lib_pthread_main" >&6; } +if test "x$ac_cv_lib_pthread_main" = xyes; then : + LIBS="$LIBS -lpthread" +fi + + + + if test x$enable_demos = xyes; then + ENABLE_DEMOS_TRUE= + ENABLE_DEMOS_FALSE='#' +else + ENABLE_DEMOS_TRUE='#' + ENABLE_DEMOS_FALSE= +fi + + + +old_trimesh=no +# Check whether --enable-old-trimesh was given. +if test "${enable_old_trimesh+set}" = set; then : + enableval=$enable_old_trimesh; old_trimesh=$enableval + +fi + +if test x$old_trimesh = xyes -a $trimesh = opcode; then + +$as_echo "#define dTRIMESH_OPCODE_USE_OLD_TRIMESH_TRIMESH_COLLIDER 1" >>confdefs.h + +else + old_trimesh=no +fi + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for gprof" >&5 +$as_echo_n "checking for gprof... " >&6; } +# Check whether --enable-gprof was given. +if test "${enable_gprof+set}" = set; then : + enableval=$enable_gprof; gprof=$enableval +else + gprof=no +fi + +if test "$gprof" != no +then + CFLAGS="-pg $CFLAGS" + CXXFLAGS="-pg $CXXFLAGS" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: enabled" >&5 +$as_echo "enabled" >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lgmon" >&5 +$as_echo_n "checking for main in -lgmon... " >&6; } +if ${ac_cv_lib_gmon_main+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lgmon $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + +int +main () +{ +return main (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_gmon_main=yes +else + ac_cv_lib_gmon_main=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gmon_main" >&5 +$as_echo "$ac_cv_lib_gmon_main" >&6; } +if test "x$ac_cv_lib_gmon_main" = xyes; then : + LIBS="$LIBS -lgmon" +fi + +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + +# Checks for typedefs, structures, and compiler characteristics. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5 +$as_echo_n "checking for stdbool.h that conforms to C99... " >&6; } +if ${ac_cv_header_stdbool_h+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + #ifndef bool + "error: bool is not defined" + #endif + #ifndef false + "error: false is not defined" + #endif + #if false + "error: false is not 0" + #endif + #ifndef true + "error: true is not defined" + #endif + #if true != 1 + "error: true is not 1" + #endif + #ifndef __bool_true_false_are_defined + "error: __bool_true_false_are_defined is not defined" + #endif + + struct s { _Bool s: 1; _Bool t; } s; + + char a[true == 1 ? 1 : -1]; + char b[false == 0 ? 1 : -1]; + char c[__bool_true_false_are_defined == 1 ? 1 : -1]; + char d[(bool) 0.5 == true ? 1 : -1]; + /* See body of main program for 'e'. */ + char f[(_Bool) 0.0 == false ? 1 : -1]; + char g[true]; + char h[sizeof (_Bool)]; + char i[sizeof s.t]; + enum { j = false, k = true, l = false * true, m = true * 256 }; + /* The following fails for + HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */ + _Bool n[m]; + char o[sizeof n == m * sizeof n[0] ? 1 : -1]; + char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1]; + /* Catch a bug in an HP-UX C compiler. See + http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html + http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html + */ + _Bool q = true; + _Bool *pq = &q; + +int +main () +{ + + bool e = &s; + *pq |= q; + *pq |= ! q; + /* Refer to every declared value, to avoid compiler optimizations. */ + return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l + + !m + !n + !o + !p + !q + !pq); + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_header_stdbool_h=yes +else + ac_cv_header_stdbool_h=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5 +$as_echo "$ac_cv_header_stdbool_h" >&6; } + ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default" +if test "x$ac_cv_type__Bool" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE__BOOL 1 +_ACEOF + + +fi + + +if test $ac_cv_header_stdbool_h = yes; then + +$as_echo "#define HAVE_STDBOOL_H 1" >>confdefs.h + +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 +$as_echo_n "checking for inline... " >&6; } +if ${ac_cv_c_inline+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_cv_c_inline=no +for ac_kw in inline __inline__ __inline; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifndef __cplusplus +typedef int foo_t; +static $ac_kw foo_t static_foo () {return 0; } +$ac_kw foo_t foo () {return 0; } +#endif + +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_inline=$ac_kw +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + test "$ac_cv_c_inline" != no && break +done + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 +$as_echo "$ac_cv_c_inline" >&6; } + +case $ac_cv_c_inline in + inline | yes) ;; + *) + case $ac_cv_c_inline in + no) ac_val=;; + *) ac_val=$ac_cv_c_inline;; + esac + cat >>confdefs.h <<_ACEOF +#ifndef __cplusplus +#define inline $ac_val +#endif +_ACEOF + ;; +esac + +ac_fn_c_find_intX_t "$LINENO" "32" "ac_cv_c_int32_t" +case $ac_cv_c_int32_t in #( + no|yes) ;; #( + *) + +cat >>confdefs.h <<_ACEOF +#define int32_t $ac_cv_c_int32_t +_ACEOF +;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for obstacks" >&5 +$as_echo_n "checking for obstacks... " >&6; } +if ${ac_cv_func_obstack+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default + #include "obstack.h" +int +main () +{ +struct obstack mem; + #define obstack_chunk_alloc malloc + #define obstack_chunk_free free + obstack_init (&mem); + obstack_free (&mem, 0); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_func_obstack=yes +else + ac_cv_func_obstack=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_obstack" >&5 +$as_echo "$ac_cv_func_obstack" >&6; } +if test $ac_cv_func_obstack = yes; then + +$as_echo "#define HAVE_OBSTACK 1" >>confdefs.h + +else + case " $LIBOBJS " in + *" obstack.$ac_objext "* ) ;; + *) LIBOBJS="$LIBOBJS obstack.$ac_objext" + ;; +esac + +fi + +ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" +if test "x$ac_cv_type_size_t" = xyes; then : + +else + +cat >>confdefs.h <<_ACEOF +#define size_t unsigned int +_ACEOF + +fi + +ac_fn_c_find_uintX_t "$LINENO" "32" "ac_cv_c_uint32_t" +case $ac_cv_c_uint32_t in #( + no|yes) ;; #( + *) + +$as_echo "#define _UINT32_T 1" >>confdefs.h + + +cat >>confdefs.h <<_ACEOF +#define uint32_t $ac_cv_c_uint32_t +_ACEOF +;; + esac + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lm" >&5 +$as_echo_n "checking for main in -lm... " >&6; } +if ${ac_cv_lib_m_main+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lm $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + +int +main () +{ +return main (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_m_main=yes +else + ac_cv_lib_m_main=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_main" >&5 +$as_echo "$ac_cv_lib_m_main" >&6; } +if test "x$ac_cv_lib_m_main" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_LIBM 1 +_ACEOF + + LIBS="-lm $LIBS" + +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lsunmath" >&5 +$as_echo_n "checking for main in -lsunmath... " >&6; } +if ${ac_cv_lib_sunmath_main+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lsunmath $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + +int +main () +{ +return main (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_sunmath_main=yes +else + ac_cv_lib_sunmath_main=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sunmath_main" >&5 +$as_echo "$ac_cv_lib_sunmath_main" >&6; } +if test "x$ac_cv_lib_sunmath_main" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_LIBSUNMATH 1 +_ACEOF + + LIBS="-lsunmath $LIBS" + +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lrt" >&5 +$as_echo_n "checking for main in -lrt... " >&6; } +if ${ac_cv_lib_rt_main+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lrt $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + +int +main () +{ +return main (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_rt_main=yes +else + ac_cv_lib_rt_main=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_main" >&5 +$as_echo "$ac_cv_lib_rt_main" >&6; } +if test "x$ac_cv_lib_rt_main" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_LIBRT 1 +_ACEOF + + LIBS="-lrt $LIBS" + +fi + +for ac_func in atan2f clock_gettime copysign copysignf cosf fabsf floor fmodf gettimeofday isnan _isnan __isnan isnanf _isnanf __isnanf memmove memset pthread_attr_setstacklazy pthread_attr_setinheritsched pthread_condattr_setclock sinf snprintf sqrt sqrtf strchr strstr vsnprintf +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +fi +done + +# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works +# for constant arguments. Useless! +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5 +$as_echo_n "checking for working alloca.h... " >&6; } +if ${ac_cv_working_alloca_h+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main () +{ +char *p = (char *) alloca (2 * sizeof (int)); + if (p) return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_working_alloca_h=yes +else + ac_cv_working_alloca_h=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5 +$as_echo "$ac_cv_working_alloca_h" >&6; } +if test $ac_cv_working_alloca_h = yes; then + +$as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h + +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5 +$as_echo_n "checking for alloca... " >&6; } +if ${ac_cv_func_alloca_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __GNUC__ +# define alloca __builtin_alloca +#else +# ifdef _MSC_VER +# include +# define alloca _alloca +# else +# ifdef HAVE_ALLOCA_H +# include +# else +# ifdef _AIX + #pragma alloca +# else +# ifndef alloca /* predefined by HP cc +Olibcalls */ +void *alloca (size_t); +# endif +# endif +# endif +# endif +#endif + +int +main () +{ +char *p = (char *) alloca (1); + if (p) return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_func_alloca_works=yes +else + ac_cv_func_alloca_works=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5 +$as_echo "$ac_cv_func_alloca_works" >&6; } + +if test $ac_cv_func_alloca_works = yes; then + +$as_echo "#define HAVE_ALLOCA 1" >>confdefs.h + +else + # The SVR3 libPW and SVR4 libucb both contain incompatible functions +# that cause trouble. Some versions do not even contain alloca or +# contain a buggy version. If you still want to use their alloca, +# use ar to extract alloca.o from them instead of compiling alloca.c. + +ALLOCA=\${LIBOBJDIR}alloca.$ac_objext + +$as_echo "#define C_ALLOCA 1" >>confdefs.h + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5 +$as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; } +if ${ac_cv_os_cray+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#if defined CRAY && ! defined CRAY2 +webecray +#else +wenotbecray +#endif + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "webecray" >/dev/null 2>&1; then : + ac_cv_os_cray=yes +else + ac_cv_os_cray=no +fi +rm -f conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5 +$as_echo "$ac_cv_os_cray" >&6; } +if test $ac_cv_os_cray = yes; then + for ac_func in _getb67 GETB67 getb67; do + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + +cat >>confdefs.h <<_ACEOF +#define CRAY_STACKSEG_END $ac_func +_ACEOF + + break +fi + + done +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5 +$as_echo_n "checking stack direction for C alloca... " >&6; } +if ${ac_cv_c_stack_direction+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ac_cv_c_stack_direction=0 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +find_stack_direction (int *addr, int depth) +{ + int dir, dummy = 0; + if (! addr) + addr = &dummy; + *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1; + dir = depth ? find_stack_direction (addr, depth - 1) : 0; + return dir + dummy; +} + +int +main (int argc, char **argv) +{ + return find_stack_direction (0, argc + !argv + 20) < 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_c_stack_direction=1 +else + ac_cv_c_stack_direction=-1 +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5 +$as_echo "$ac_cv_c_stack_direction" >&6; } +cat >>confdefs.h <<_ACEOF +#define STACK_DIRECTION $ac_cv_c_stack_direction +_ACEOF + + +fi + + +ac_fn_c_check_func "$LINENO" "pthread_condattr_setclock" "ac_cv_func_pthread_condattr_setclock" +if test "x$ac_cv_func_pthread_condattr_setclock" = xyes; then : + +else + ac_cv_func_no_pthread_condattr_setclock=yes +fi + +for ac_func in no_pthread_condattr_setclock +do : + ac_fn_c_check_func "$LINENO" "no_pthread_condattr_setclock" "ac_cv_func_no_pthread_condattr_setclock" +if test "x$ac_cv_func_no_pthread_condattr_setclock" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_NO_PTHREAD_CONDATTR_SETCLOCK 1 +_ACEOF + +fi +done + + + +# Check whether --enable-threading-intf was given. +if test "${enable_threading_intf+set}" = set; then : + enableval=$enable_threading_intf; threading_intf=$enableval +else + threading_intf=yes +fi + +# Check whether --enable-ou was given. +if test "${enable_ou+set}" = set; then : + enableval=$enable_ou; use_ou_tls=$enableval +else + use_ou_tls=no +fi + +use_ou="no" +if test x$use_ou_tls = xyes -o x$threading_intf = xyes +then + use_ou="yes" +fi + +OU_NAMESPACE=odeou + + +$as_echo "#define _OU_NAMESPACE odeou" >>confdefs.h + + +$as_echo "#define dOU_ENABLED 1" >>confdefs.h + + +if test x$use_ou_tls = xyes +then + OU_FEATURE_SET=_OU_FEATURE_SET_TLS + +$as_echo "#define _OU_FEATURE_SET _OU_FEATURE_SET_TLS" >>confdefs.h + +elif test x$use_ou = xyes +then + OU_FEATURE_SET=_OU_FEATURE_SET_ATOMICS + +$as_echo "#define _OU_FEATURE_SET _OU_FEATURE_SET_ATOMICS" >>confdefs.h + +else + OU_FEATURE_SET=_OU_FEATURE_SET_BASICS + +$as_echo "#define _OU_FEATURE_SET _OU_FEATURE_SET_BASICS" >>confdefs.h + +fi + + +if test x$use_ou = xyes +then + +$as_echo "#define dATOMICS_ENABLED 1" >>confdefs.h + + if test x$use_ou_tls = xyes + then + +$as_echo "#define dTLS_ENABLED 1" >>confdefs.h + + fi +fi + +case "$host_os" in + cygwin* | mingw*) + targetos=_OU_TARGET_OS_WINDOWS + ;; + *qnx*) + targetos=_OU_TARGET_OS_QNX + ;; + *apple* | *darwin*) + targetos=_OU_TARGET_OS_MAC + ;; + *sunos*) + targetos=_OU_TARGET_OS_SUNOS + ;; + *aix*) + targetos=_OU_TARGET_OS_AIX + ;; + *) + targetos=_OU_TARGET_OS_GENUNIX + ;; +esac + +if test $targetos = _OU_TARGET_OS_MAC +then + MAC_OS_X_VERSION=1000 + ac_fn_c_check_func "$LINENO" "OSAtomicAdd32Barrier" "ac_cv_func_OSAtomicAdd32Barrier" +if test "x$ac_cv_func_OSAtomicAdd32Barrier" = xyes; then : + MAC_OS_X_VERSION=1040 +fi + + ac_fn_c_check_func "$LINENO" "OSAtomicAnd32OrigBarrier" "ac_cv_func_OSAtomicAnd32OrigBarrier" +if test "x$ac_cv_func_OSAtomicAnd32OrigBarrier" = xyes; then : + MAC_OS_X_VERSION=1050 +fi + + +cat >>confdefs.h <<_ACEOF +#define MAC_OS_X_VERSION $MAC_OS_X_VERSION +_ACEOF + +fi + +if test $targetos = _OU_TARGET_OS_SUNOS +then + ac_fn_c_check_func "$LINENO" "atomic_inc_32_nv" "ac_cv_func_atomic_inc_32_nv" +if test "x$ac_cv_func_atomic_inc_32_nv" = xyes; then : + +else + targetos=_OU_TARGET_OS_GENUNIX +fi + +fi + + +cat >>confdefs.h <<_ACEOF +#define _OU_TARGET_OS $targetos +_ACEOF + + + + +subdirs="$subdirs ou" + + if true; then + ENABLE_OU_TRUE= + ENABLE_OU_FALSE='#' +else + ENABLE_OU_TRUE='#' + ENABLE_OU_FALSE= +fi + + +if test x$threading_intf = xyes +then + # Check whether --enable-builtin-threading-impl was given. +if test "${enable_builtin_threading_impl+set}" = set; then : + enableval=$enable_builtin_threading_impl; use_builtin_threading_impl=$enableval +else + use_builtin_threading_impl=yes +fi + + if test x$use_builtin_threading_impl = xyes + then + +$as_echo "#define dBUILTIN_THREADING_IMPL_ENABLED 1" >>confdefs.h + + fi +else + +$as_echo "#define dTHREADING_INTF_DISABLED 1" >>confdefs.h + + use_builtin_threading_impl=no +fi + +col_cylinder_cylinder=none +col_box_cylinder=default +col_capsule_cylinder=none +col_convex_box=none +col_convex_capsule=none +col_convex_cylinder=none +col_convex_sphere=default +col_convex_convex=default + + +use_libccd=no +libccd_all=no +# Check whether --enable-libccd was given. +if test "${enable_libccd+set}" = set; then : + enableval=$enable_libccd; libccd_all=$enableval +fi + +if test x$libccd_all = xyes +then + col_cylinder_cylinder=libccd + col_capsule_cylinder=libccd + col_convex_box=libccd + col_convex_capsule=libccd + col_convex_cylinder=libccd + col_convex_sphere=libccd + col_convex_convex=libccd + use_libccd=yes +fi + + + +# Check whether --with-cylinder-cylinder was given. +if test "${with_cylinder_cylinder+set}" = set; then : + withval=$with_cylinder_cylinder; col_cylinder_cylinder=$withval +fi + + + +# Check whether --with-box-cylinder was given. +if test "${with_box_cylinder+set}" = set; then : + withval=$with_box_cylinder; col_box_cylinder=$withval +fi + + + +# Check whether --with-capsule-cylinder was given. +if test "${with_capsule_cylinder+set}" = set; then : + withval=$with_capsule_cylinder; col_capsule_cylinder=$withval +fi + + + +# Check whether --with-convex-box was given. +if test "${with_convex_box+set}" = set; then : + withval=$with_convex_box; col_convex_box=$withval +fi + + + +# Check whether --with-convex-capsule was given. +if test "${with_convex_capsule+set}" = set; then : + withval=$with_convex_capsule; col_convex_capsule=$withval +fi + + + +# Check whether --with-convex-cylinder was given. +if test "${with_convex_cylinder+set}" = set; then : + withval=$with_convex_cylinder; col_convex_cylinder=$withval +fi + + + +# Check whether --with-convex-sphere was given. +if test "${with_convex_sphere+set}" = set; then : + withval=$with_convex_sphere; col_convex_sphere=$withval +fi + + + +# Check whether --with-convex-convex was given. +if test "${with_convex_convex+set}" = set; then : + withval=$with_convex_convex; col_convex_convex=$withval +fi + + +if test x$col_cylinder_cylinder = xlibccd -o \ + x$col_box_cylinder = xlibccd -o \ + x$col_capsule_cylinder = xlibccd -o \ + x$col_convex_box = xlibccd -o \ + x$col_convex_capsule = libccd -o \ + x$col_convex_cylinder = xlibccd -o \ + x$col_convex_sphere = libccd -o \ + x$col_convex_convex = libccd +then + use_libccd=yes +fi + + +libccd_source=internal + + +# Check whether --with-libccd was given. +if test "${with_libccd+set}" = set; then : + withval=$with_libccd; libccd_source=$withval +else + libccd_source=system +fi + + +if test x$use_libccd = xyes +then + if test x$libccd_source = xsystem + then + +pkg_failed=no +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCD" >&5 +$as_echo_n "checking for CCD... " >&6; } + +if test -n "$CCD_CFLAGS"; then + pkg_cv_CCD_CFLAGS="$CCD_CFLAGS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"ccd\""; } >&5 + ($PKG_CONFIG --exists --print-errors "ccd") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + pkg_cv_CCD_CFLAGS=`$PKG_CONFIG --cflags "ccd" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi +if test -n "$CCD_LIBS"; then + pkg_cv_CCD_LIBS="$CCD_LIBS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"ccd\""; } >&5 + ($PKG_CONFIG --exists --print-errors "ccd") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + pkg_cv_CCD_LIBS=`$PKG_CONFIG --libs "ccd" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi + + + +if test $pkg_failed = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + +if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then + _pkg_short_errors_supported=yes +else + _pkg_short_errors_supported=no +fi + if test $_pkg_short_errors_supported = yes; then + CCD_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "ccd" 2>&1` + else + CCD_PKG_ERRORS=`$PKG_CONFIG --print-errors "ccd" 2>&1` + fi + # Put the nasty error message in config.log where it belongs + echo "$CCD_PKG_ERRORS" >&5 + + libccd_source=internal +elif test $pkg_failed = untried; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + libccd_source=internal +else + CCD_CFLAGS=$pkg_cv_CCD_CFLAGS + CCD_LIBS=$pkg_cv_CCD_LIBS + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + +fi + fi +fi + +# Configure libccd unconditionally as that may be needed for special make targets +subdirs="$subdirs libccd" + + + if test x$use_libccd != xno; then + LIBCCD_TRUE= + LIBCCD_FALSE='#' +else + LIBCCD_TRUE='#' + LIBCCD_FALSE= +fi + + if test x$libccd_source = xinternal; then + LIBCCD_INTERNAL_TRUE= + LIBCCD_INTERNAL_FALSE='#' +else + LIBCCD_INTERNAL_TRUE='#' + LIBCCD_INTERNAL_FALSE= +fi + + if test x$col_box_cylinder = xlibccd; then + LIBCCD_BOX_CYL_TRUE= + LIBCCD_BOX_CYL_FALSE='#' +else + LIBCCD_BOX_CYL_TRUE='#' + LIBCCD_BOX_CYL_FALSE= +fi + + if test x$col_cylinder_cylinder = xlibccd; then + LIBCCD_CYL_CYL_TRUE= + LIBCCD_CYL_CYL_FALSE='#' +else + LIBCCD_CYL_CYL_TRUE='#' + LIBCCD_CYL_CYL_FALSE= +fi + + if test x$col_capsule_cylinder = xlibccd; then + LIBCCD_CAP_CYL_TRUE= + LIBCCD_CAP_CYL_FALSE='#' +else + LIBCCD_CAP_CYL_TRUE='#' + LIBCCD_CAP_CYL_FALSE= +fi + + if test x$col_convex_box = xlibccd; then + LIBCCD_CONVEX_BOX_TRUE= + LIBCCD_CONVEX_BOX_FALSE='#' +else + LIBCCD_CONVEX_BOX_TRUE='#' + LIBCCD_CONVEX_BOX_FALSE= +fi + + if test x$col_convex_capsule = xlibccd; then + LIBCCD_CONVEX_CAP_TRUE= + LIBCCD_CONVEX_CAP_FALSE='#' +else + LIBCCD_CONVEX_CAP_TRUE='#' + LIBCCD_CONVEX_CAP_FALSE= +fi + + if test x$col_convex_cylinder = xlibccd; then + LIBCCD_CONVEX_CYL_TRUE= + LIBCCD_CONVEX_CYL_FALSE='#' +else + LIBCCD_CONVEX_CYL_TRUE='#' + LIBCCD_CONVEX_CYL_FALSE= +fi + + if test x$col_convex_sphere = xlibccd; then + LIBCCD_CONVEX_SPHERE_TRUE= + LIBCCD_CONVEX_SPHERE_FALSE='#' +else + LIBCCD_CONVEX_SPHERE_TRUE='#' + LIBCCD_CONVEX_SPHERE_FALSE= +fi + + if test x$col_convex_convex = xlibccd; then + LIBCCD_CONVEX_CONVEX_TRUE= + LIBCCD_CONVEX_CONVEX_FALSE='#' +else + LIBCCD_CONVEX_CONVEX_TRUE='#' + LIBCCD_CONVEX_CONVEX_FALSE= +fi + + + + +# Check whether --enable-asserts was given. +if test "${enable_asserts+set}" = set; then : + enableval=$enable_asserts; asserts=$enableval +else + asserts=yes +fi + +if test x$asserts = xno +then + CPPFLAGS="$CPPFLAGS -DdNODEBUG -DNDEBUG" +fi + + + + + +ac_config_files="$ac_config_files Makefile drawstuff/Makefile drawstuff/src/Makefile drawstuff/dstest/Makefile include/Makefile include/drawstuff/Makefile include/ode/Makefile include/ode/version.h include/ode/precision.h ode/Makefile ode/doc/Doxyfile ode/doc/Makefile ode/src/Makefile ode/src/joints/Makefile ode/demo/Makefile OPCODE/Makefile OPCODE/Ice/Makefile GIMPACT/Makefile GIMPACT/include/Makefile GIMPACT/include/GIMPACT/Makefile GIMPACT/src/Makefile tests/Makefile tests/joints/Makefile tests/UnitTest++/Makefile tests/UnitTest++/src/Makefile tests/UnitTest++/src/Posix/Makefile tests/UnitTest++/src/Win32/Makefile ode-config ode.pc" + +cat >confcache <<\_ACEOF +# This file is a shell script that caches the results of configure +# tests run on this system so they can be shared between configure +# scripts and configure runs, see configure's option --config-cache. +# It is not useful on other systems. If it contains results you don't +# want to keep, you may remove or edit it. +# +# config.status only pays attention to the cache file if you give it +# the --recheck option to rerun configure. +# +# `ac_cv_env_foo' variables (set or unset) will be overridden when +# loading this file, other *unset* `ac_cv_foo' will be assigned the +# following values. + +_ACEOF + +# The following way of writing the cache mishandles newlines in values, +# but we know of no workaround that is simple, portable, and efficient. +# So, we kill variables containing newlines. +# Ultrix sh set writes to stderr and can't be redirected directly, +# and sets the high bit in the cache file unless we assign to the vars. +( + for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do + eval ac_val=\$$ac_var + case $ac_val in #( + *${as_nl}*) + case $ac_var in #( + *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 +$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; + esac + case $ac_var in #( + _ | IFS | as_nl) ;; #( + BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( + *) { eval $ac_var=; unset $ac_var;} ;; + esac ;; + esac + done + + (set) 2>&1 | + case $as_nl`(ac_space=' '; set) 2>&1` in #( + *${as_nl}ac_space=\ *) + # `set' does not quote correctly, so add quotes: double-quote + # substitution turns \\\\ into \\, and sed turns \\ into \. + sed -n \ + "s/'/'\\\\''/g; + s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" + ;; #( + *) + # `set' quotes correctly as required by POSIX, so do not add quotes. + sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" + ;; + esac | + sort +) | + sed ' + /^ac_cv_env_/b end + t clear + :clear + s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ + t end + s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ + :end' >>confcache +if diff "$cache_file" confcache >/dev/null 2>&1; then :; else + if test -w "$cache_file"; then + if test "x$cache_file" != "x/dev/null"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 +$as_echo "$as_me: updating cache $cache_file" >&6;} + if test ! -f "$cache_file" || test -h "$cache_file"; then + cat confcache >"$cache_file" + else + case $cache_file in #( + */* | ?:*) + mv -f confcache "$cache_file"$$ && + mv -f "$cache_file"$$ "$cache_file" ;; #( + *) + mv -f confcache "$cache_file" ;; + esac + fi + fi + else + { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 +$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} + fi +fi +rm -f confcache + +test "x$prefix" = xNONE && prefix=$ac_default_prefix +# Let make expand exec_prefix. +test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' + +DEFS=-DHAVE_CONFIG_H + +ac_libobjs= +ac_ltlibobjs= +U= +for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue + # 1. Remove the extension, and $U if already installed. + ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' + ac_i=`$as_echo "$ac_i" | sed "$ac_script"` + # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR + # will be set to the directory where LIBOBJS objects are built. + as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" + as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' +done +LIBOBJS=$ac_libobjs + +LTLIBOBJS=$ac_ltlibobjs + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5 +$as_echo_n "checking that generated files are newer than configure... " >&6; } + if test -n "$am_sleep_pid"; then + # Hide warnings about reused PIDs. + wait $am_sleep_pid 2>/dev/null + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5 +$as_echo "done" >&6; } + if test -n "$EXEEXT"; then + am__EXEEXT_TRUE= + am__EXEEXT_FALSE='#' +else + am__EXEEXT_TRUE='#' + am__EXEEXT_FALSE= +fi + +if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then + as_fn_error $? "conditional \"AMDEP\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${am__fastdepCXX_TRUE}" && test -z "${am__fastdepCXX_FALSE}"; then + as_fn_error $? "conditional \"am__fastdepCXX\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then + as_fn_error $? "conditional \"am__fastdepCC\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi + +if test -z "${HAVE_DOXYGEN_TRUE}" && test -z "${HAVE_DOXYGEN_FALSE}"; then + as_fn_error $? "conditional \"HAVE_DOXYGEN\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${X86_64_SYSTEM_TRUE}" && test -z "${X86_64_SYSTEM_FALSE}"; then + as_fn_error $? "conditional \"X86_64_SYSTEM\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${OPCODE_TRUE}" && test -z "${OPCODE_FALSE}"; then + as_fn_error $? "conditional \"OPCODE\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${GIMPACT_TRUE}" && test -z "${GIMPACT_FALSE}"; then + as_fn_error $? "conditional \"GIMPACT\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${TRIMESH_TRUE}" && test -z "${TRIMESH_FALSE}"; then + as_fn_error $? "conditional \"TRIMESH\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${WIN32_TRUE}" && test -z "${WIN32_FALSE}"; then + as_fn_error $? "conditional \"WIN32\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${X11_TRUE}" && test -z "${X11_FALSE}"; then + as_fn_error $? "conditional \"X11\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${OSX_TRUE}" && test -z "${OSX_FALSE}"; then + as_fn_error $? "conditional \"OSX\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${ENABLE_DRAWSTUFF_TRUE}" && test -z "${ENABLE_DRAWSTUFF_FALSE}"; then + as_fn_error $? "conditional \"ENABLE_DRAWSTUFF\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${ENABLE_DEMOS_TRUE}" && test -z "${ENABLE_DEMOS_FALSE}"; then + as_fn_error $? "conditional \"ENABLE_DEMOS\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${ENABLE_OU_TRUE}" && test -z "${ENABLE_OU_FALSE}"; then + as_fn_error $? "conditional \"ENABLE_OU\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${LIBCCD_TRUE}" && test -z "${LIBCCD_FALSE}"; then + as_fn_error $? "conditional \"LIBCCD\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${LIBCCD_INTERNAL_TRUE}" && test -z "${LIBCCD_INTERNAL_FALSE}"; then + as_fn_error $? "conditional \"LIBCCD_INTERNAL\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${LIBCCD_BOX_CYL_TRUE}" && test -z "${LIBCCD_BOX_CYL_FALSE}"; then + as_fn_error $? "conditional \"LIBCCD_BOX_CYL\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${LIBCCD_CYL_CYL_TRUE}" && test -z "${LIBCCD_CYL_CYL_FALSE}"; then + as_fn_error $? "conditional \"LIBCCD_CYL_CYL\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${LIBCCD_CAP_CYL_TRUE}" && test -z "${LIBCCD_CAP_CYL_FALSE}"; then + as_fn_error $? "conditional \"LIBCCD_CAP_CYL\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${LIBCCD_CONVEX_BOX_TRUE}" && test -z "${LIBCCD_CONVEX_BOX_FALSE}"; then + as_fn_error $? "conditional \"LIBCCD_CONVEX_BOX\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${LIBCCD_CONVEX_CAP_TRUE}" && test -z "${LIBCCD_CONVEX_CAP_FALSE}"; then + as_fn_error $? "conditional \"LIBCCD_CONVEX_CAP\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${LIBCCD_CONVEX_CYL_TRUE}" && test -z "${LIBCCD_CONVEX_CYL_FALSE}"; then + as_fn_error $? "conditional \"LIBCCD_CONVEX_CYL\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${LIBCCD_CONVEX_SPHERE_TRUE}" && test -z "${LIBCCD_CONVEX_SPHERE_FALSE}"; then + as_fn_error $? "conditional \"LIBCCD_CONVEX_SPHERE\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${LIBCCD_CONVEX_CONVEX_TRUE}" && test -z "${LIBCCD_CONVEX_CONVEX_FALSE}"; then + as_fn_error $? "conditional \"LIBCCD_CONVEX_CONVEX\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi + +: "${CONFIG_STATUS=./config.status}" +ac_write_fail=0 +ac_clean_files_save=$ac_clean_files +ac_clean_files="$ac_clean_files $CONFIG_STATUS" +{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 +$as_echo "$as_me: creating $CONFIG_STATUS" >&6;} +as_write_fail=0 +cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 +#! $SHELL +# Generated by $as_me. +# Run this file to recreate the current configuration. +# Compiler output produced by configure, useful for debugging +# configure, is in config.log if it exists. + +debug=false +ac_cs_recheck=false +ac_cs_silent=false + +SHELL=\${CONFIG_SHELL-$SHELL} +export SHELL +_ASEOF +cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 +## -------------------- ## +## M4sh Initialization. ## +## -------------------- ## + +# Be more Bourne compatible +DUALCASE=1; export DUALCASE # for MKS sh +if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : + emulate sh + NULLCMD=: + # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which + # is contrary to our usage. Disable this feature. + alias -g '${1+"$@"}'='"$@"' + setopt NO_GLOB_SUBST +else + case `(set -o) 2>/dev/null` in #( + *posix*) : + set -o posix ;; #( + *) : + ;; +esac +fi + + +as_nl=' +' +export as_nl +# Printing a long string crashes Solaris 7 /usr/bin/printf. +as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo +# Prefer a ksh shell builtin over an external printf program on Solaris, +# but without wasting forks for bash or zsh. +if test -z "$BASH_VERSION$ZSH_VERSION" \ + && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='print -r --' + as_echo_n='print -rn --' +elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='printf %s\n' + as_echo_n='printf %s' +else + if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then + as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' + as_echo_n='/usr/ucb/echo -n' + else + as_echo_body='eval expr "X$1" : "X\\(.*\\)"' + as_echo_n_body='eval + arg=$1; + case $arg in #( + *"$as_nl"*) + expr "X$arg" : "X\\(.*\\)$as_nl"; + arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; + esac; + expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" + ' + export as_echo_n_body + as_echo_n='sh -c $as_echo_n_body as_echo' + fi + export as_echo_body + as_echo='sh -c $as_echo_body as_echo' +fi + +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + PATH_SEPARATOR=: + (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { + (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || + PATH_SEPARATOR=';' + } +fi + + +# IFS +# We need space, tab and new line, in precisely that order. Quoting is +# there to prevent editors from complaining about space-tab. +# (If _AS_PATH_WALK were called with IFS unset, it would disable word +# splitting by setting IFS to empty value.) +IFS=" "" $as_nl" + +# Find who we are. Look in the path if we contain no directory separator. +as_myself= +case $0 in #(( + *[\\/]* ) as_myself=$0 ;; + *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break + done +IFS=$as_save_IFS + + ;; +esac +# We did not find ourselves, most probably we were run as `sh COMMAND' +# in which case we are not to be found in the path. +if test "x$as_myself" = x; then + as_myself=$0 +fi +if test ! -f "$as_myself"; then + $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 + exit 1 +fi + +# Unset variables that we do not need and which cause bugs (e.g. in +# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" +# suppresses any "Segmentation fault" message there. '((' could +# trigger a bug in pdksh 5.2.14. +for as_var in BASH_ENV ENV MAIL MAILPATH +do eval test x\${$as_var+set} = xset \ + && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : +done +PS1='$ ' +PS2='> ' +PS4='+ ' + +# NLS nuisances. +LC_ALL=C +export LC_ALL +LANGUAGE=C +export LANGUAGE + +# CDPATH. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + + +# as_fn_error STATUS ERROR [LINENO LOG_FD] +# ---------------------------------------- +# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are +# provided, also output the error to LOG_FD, referencing LINENO. Then exit the +# script with STATUS, using 1 if that was 0. +as_fn_error () +{ + as_status=$1; test $as_status -eq 0 && as_status=1 + if test "$4"; then + as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 + fi + $as_echo "$as_me: error: $2" >&2 + as_fn_exit $as_status +} # as_fn_error + + +# as_fn_set_status STATUS +# ----------------------- +# Set $? to STATUS, without forking. +as_fn_set_status () +{ + return $1 +} # as_fn_set_status + +# as_fn_exit STATUS +# ----------------- +# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. +as_fn_exit () +{ + set +e + as_fn_set_status $1 + exit $1 +} # as_fn_exit + +# as_fn_unset VAR +# --------------- +# Portably unset VAR. +as_fn_unset () +{ + { eval $1=; unset $1;} +} +as_unset=as_fn_unset +# as_fn_append VAR VALUE +# ---------------------- +# Append the text in VALUE to the end of the definition contained in VAR. Take +# advantage of any shell optimizations that allow amortized linear growth over +# repeated appends, instead of the typical quadratic growth present in naive +# implementations. +if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : + eval 'as_fn_append () + { + eval $1+=\$2 + }' +else + as_fn_append () + { + eval $1=\$$1\$2 + } +fi # as_fn_append + +# as_fn_arith ARG... +# ------------------ +# Perform arithmetic evaluation on the ARGs, and store the result in the +# global $as_val. Take advantage of shells that can avoid forks. The arguments +# must be portable across $(()) and expr. +if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : + eval 'as_fn_arith () + { + as_val=$(( $* )) + }' +else + as_fn_arith () + { + as_val=`expr "$@" || test $? -eq 1` + } +fi # as_fn_arith + + +if expr a : '\(a\)' >/dev/null 2>&1 && + test "X`expr 00001 : '.*\(...\)'`" = X001; then + as_expr=expr +else + as_expr=false +fi + +if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then + as_basename=basename +else + as_basename=false +fi + +if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then + as_dirname=dirname +else + as_dirname=false +fi + +as_me=`$as_basename -- "$0" || +$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ + X"$0" : 'X\(//\)$' \| \ + X"$0" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X/"$0" | + sed '/^.*\/\([^/][^/]*\)\/*$/{ + s//\1/ + q + } + /^X\/\(\/\/\)$/{ + s//\1/ + q + } + /^X\/\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + +# Avoid depending upon Character Ranges. +as_cr_letters='abcdefghijklmnopqrstuvwxyz' +as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' +as_cr_Letters=$as_cr_letters$as_cr_LETTERS +as_cr_digits='0123456789' +as_cr_alnum=$as_cr_Letters$as_cr_digits + +ECHO_C= ECHO_N= ECHO_T= +case `echo -n x` in #((((( +-n*) + case `echo 'xy\c'` in + *c*) ECHO_T=' ';; # ECHO_T is single tab character. + xy) ECHO_C='\c';; + *) echo `echo ksh88 bug on AIX 6.1` > /dev/null + ECHO_T=' ';; + esac;; +*) + ECHO_N='-n';; +esac + +rm -f conf$$ conf$$.exe conf$$.file +if test -d conf$$.dir; then + rm -f conf$$.dir/conf$$.file +else + rm -f conf$$.dir + mkdir conf$$.dir 2>/dev/null +fi +if (echo >conf$$.file) 2>/dev/null; then + if ln -s conf$$.file conf$$ 2>/dev/null; then + as_ln_s='ln -s' + # ... but there are two gotchas: + # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. + # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. + # In both cases, we have to default to `cp -pR'. + ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || + as_ln_s='cp -pR' + elif ln conf$$.file conf$$ 2>/dev/null; then + as_ln_s=ln + else + as_ln_s='cp -pR' + fi +else + as_ln_s='cp -pR' +fi +rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file +rmdir conf$$.dir 2>/dev/null + + +# as_fn_mkdir_p +# ------------- +# Create "$as_dir" as a directory, including parents if necessary. +as_fn_mkdir_p () +{ + + case $as_dir in #( + -*) as_dir=./$as_dir;; + esac + test -d "$as_dir" || eval $as_mkdir_p || { + as_dirs= + while :; do + case $as_dir in #( + *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( + *) as_qdir=$as_dir;; + esac + as_dirs="'$as_qdir' $as_dirs" + as_dir=`$as_dirname -- "$as_dir" || +$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$as_dir" : 'X\(//\)[^/]' \| \ + X"$as_dir" : 'X\(//\)$' \| \ + X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$as_dir" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + test -d "$as_dir" && break + done + test -z "$as_dirs" || eval "mkdir $as_dirs" + } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" + + +} # as_fn_mkdir_p +if mkdir -p . 2>/dev/null; then + as_mkdir_p='mkdir -p "$as_dir"' +else + test -d ./-p && rmdir ./-p + as_mkdir_p=false +fi + + +# as_fn_executable_p FILE +# ----------------------- +# Test if FILE is an executable regular file. +as_fn_executable_p () +{ + test -f "$1" && test -x "$1" +} # as_fn_executable_p +as_test_x='test -x' +as_executable_p=as_fn_executable_p + +# Sed expression to map a string onto a valid CPP name. +as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" + +# Sed expression to map a string onto a valid variable name. +as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" + + +exec 6>&1 +## ----------------------------------- ## +## Main body of $CONFIG_STATUS script. ## +## ----------------------------------- ## +_ASEOF +test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# Save the log message, to keep $0 and so on meaningful, and to +# report actual input values of CONFIG_FILES etc. instead of their +# values after options handling. +ac_log=" +This file was extended by ODE $as_me 0.16.1, which was +generated by GNU Autoconf 2.69. Invocation command line was + + CONFIG_FILES = $CONFIG_FILES + CONFIG_HEADERS = $CONFIG_HEADERS + CONFIG_LINKS = $CONFIG_LINKS + CONFIG_COMMANDS = $CONFIG_COMMANDS + $ $0 $@ + +on `(hostname || uname -n) 2>/dev/null | sed 1q` +" + +_ACEOF + +case $ac_config_files in *" +"*) set x $ac_config_files; shift; ac_config_files=$*;; +esac + +case $ac_config_headers in *" +"*) set x $ac_config_headers; shift; ac_config_headers=$*;; +esac + + +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +# Files that config.status was made for. +config_files="$ac_config_files" +config_headers="$ac_config_headers" +config_commands="$ac_config_commands" + +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +ac_cs_usage="\ +\`$as_me' instantiates files and other configuration actions +from templates according to the current configuration. Unless the files +and actions are specified as TAGs, all are instantiated by default. + +Usage: $0 [OPTION]... [TAG]... + + -h, --help print this help, then exit + -V, --version print version number and configuration settings, then exit + --config print configuration, then exit + -q, --quiet, --silent + do not print progress messages + -d, --debug don't remove temporary files + --recheck update $as_me by reconfiguring in the same conditions + --file=FILE[:TEMPLATE] + instantiate the configuration file FILE + --header=FILE[:TEMPLATE] + instantiate the configuration header FILE + +Configuration files: +$config_files + +Configuration headers: +$config_headers + +Configuration commands: +$config_commands + +Report bugs to ." + +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" +ac_cs_version="\\ +ODE config.status 0.16.1 +configured by $0, generated by GNU Autoconf 2.69, + with options \\"\$ac_cs_config\\" + +Copyright (C) 2012 Free Software Foundation, Inc. +This config.status script is free software; the Free Software Foundation +gives unlimited permission to copy, distribute and modify it." + +ac_pwd='$ac_pwd' +srcdir='$srcdir' +INSTALL='$INSTALL' +MKDIR_P='$MKDIR_P' +AWK='$AWK' +test -n "\$AWK" || AWK=awk +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# The default lists apply if the user does not specify any file. +ac_need_defaults=: +while test $# != 0 +do + case $1 in + --*=?*) + ac_option=`expr "X$1" : 'X\([^=]*\)='` + ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` + ac_shift=: + ;; + --*=) + ac_option=`expr "X$1" : 'X\([^=]*\)='` + ac_optarg= + ac_shift=: + ;; + *) + ac_option=$1 + ac_optarg=$2 + ac_shift=shift + ;; + esac + + case $ac_option in + # Handling of the options. + -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) + ac_cs_recheck=: ;; + --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) + $as_echo "$ac_cs_version"; exit ;; + --config | --confi | --conf | --con | --co | --c ) + $as_echo "$ac_cs_config"; exit ;; + --debug | --debu | --deb | --de | --d | -d ) + debug=: ;; + --file | --fil | --fi | --f ) + $ac_shift + case $ac_optarg in + *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; + '') as_fn_error $? "missing file argument" ;; + esac + as_fn_append CONFIG_FILES " '$ac_optarg'" + ac_need_defaults=false;; + --header | --heade | --head | --hea ) + $ac_shift + case $ac_optarg in + *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; + esac + as_fn_append CONFIG_HEADERS " '$ac_optarg'" + ac_need_defaults=false;; + --he | --h) + # Conflict between --help and --header + as_fn_error $? "ambiguous option: \`$1' +Try \`$0 --help' for more information.";; + --help | --hel | -h ) + $as_echo "$ac_cs_usage"; exit ;; + -q | -quiet | --quiet | --quie | --qui | --qu | --q \ + | -silent | --silent | --silen | --sile | --sil | --si | --s) + ac_cs_silent=: ;; + + # This is an error. + -*) as_fn_error $? "unrecognized option: \`$1' +Try \`$0 --help' for more information." ;; + + *) as_fn_append ac_config_targets " $1" + ac_need_defaults=false ;; + + esac + shift +done + +ac_configure_extra_args= + +if $ac_cs_silent; then + exec 6>/dev/null + ac_configure_extra_args="$ac_configure_extra_args --silent" +fi + +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +if \$ac_cs_recheck; then + set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion + shift + \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 + CONFIG_SHELL='$SHELL' + export CONFIG_SHELL + exec "\$@" +fi + +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +exec 5>>config.log +{ + echo + sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX +## Running $as_me. ## +_ASBOX + $as_echo "$ac_log" +} >&5 + +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +# +# INIT-COMMANDS +# +AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" + + +# The HP-UX ksh and POSIX shell print the target directory to stdout +# if CDPATH is set. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + +sed_quote_subst='$sed_quote_subst' +double_quote_subst='$double_quote_subst' +delay_variable_subst='$delay_variable_subst' +macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`' +macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`' +enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`' +AS='`$ECHO "$AS" | $SED "$delay_single_quote_subst"`' +DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`' +OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`' +enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`' +pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`' +enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`' +shared_archive_member_spec='`$ECHO "$shared_archive_member_spec" | $SED "$delay_single_quote_subst"`' +SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`' +ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`' +PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`' +host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`' +host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`' +host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`' +build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`' +build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`' +build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`' +SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`' +Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`' +GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`' +EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`' +FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`' +LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`' +NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`' +LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`' +max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`' +ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`' +exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`' +lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`' +lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`' +lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`' +lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`' +lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`' +reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`' +reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`' +deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`' +file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`' +file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`' +want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`' +sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`' +AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`' +AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`' +archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`' +STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`' +RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`' +old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`' +old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`' +old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`' +lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`' +CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`' +CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`' +compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`' +GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_import='`$ECHO "$lt_cv_sys_global_symbol_to_import" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`' +lt_cv_nm_interface='`$ECHO "$lt_cv_nm_interface" | $SED "$delay_single_quote_subst"`' +nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`' +lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`' +lt_cv_truncate_bin='`$ECHO "$lt_cv_truncate_bin" | $SED "$delay_single_quote_subst"`' +objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`' +MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`' +lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`' +need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`' +MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`' +DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`' +NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`' +LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`' +OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`' +OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`' +libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`' +shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`' +extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`' +archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`' +enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`' +export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`' +whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`' +compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`' +old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`' +old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`' +archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`' +archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`' +module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`' +module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`' +with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`' +allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`' +no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`' +hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`' +hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`' +hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`' +hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`' +hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`' +inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`' +link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`' +always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`' +export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`' +exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`' +include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`' +prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`' +postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`' +file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`' +variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`' +need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`' +need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`' +version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`' +runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`' +shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`' +shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`' +libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`' +library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`' +soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`' +install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`' +postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`' +postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`' +finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`' +finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`' +hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`' +sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`' +configure_time_dlsearch_path='`$ECHO "$configure_time_dlsearch_path" | $SED "$delay_single_quote_subst"`' +configure_time_lt_sys_library_path='`$ECHO "$configure_time_lt_sys_library_path" | $SED "$delay_single_quote_subst"`' +hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`' +enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`' +enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`' +enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`' +old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`' +striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`' +compiler_lib_search_dirs='`$ECHO "$compiler_lib_search_dirs" | $SED "$delay_single_quote_subst"`' +predep_objects='`$ECHO "$predep_objects" | $SED "$delay_single_quote_subst"`' +postdep_objects='`$ECHO "$postdep_objects" | $SED "$delay_single_quote_subst"`' +predeps='`$ECHO "$predeps" | $SED "$delay_single_quote_subst"`' +postdeps='`$ECHO "$postdeps" | $SED "$delay_single_quote_subst"`' +compiler_lib_search_path='`$ECHO "$compiler_lib_search_path" | $SED "$delay_single_quote_subst"`' +LD_CXX='`$ECHO "$LD_CXX" | $SED "$delay_single_quote_subst"`' +reload_flag_CXX='`$ECHO "$reload_flag_CXX" | $SED "$delay_single_quote_subst"`' +reload_cmds_CXX='`$ECHO "$reload_cmds_CXX" | $SED "$delay_single_quote_subst"`' +old_archive_cmds_CXX='`$ECHO "$old_archive_cmds_CXX" | $SED "$delay_single_quote_subst"`' +compiler_CXX='`$ECHO "$compiler_CXX" | $SED "$delay_single_quote_subst"`' +GCC_CXX='`$ECHO "$GCC_CXX" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_no_builtin_flag_CXX='`$ECHO "$lt_prog_compiler_no_builtin_flag_CXX" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_pic_CXX='`$ECHO "$lt_prog_compiler_pic_CXX" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_wl_CXX='`$ECHO "$lt_prog_compiler_wl_CXX" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_static_CXX='`$ECHO "$lt_prog_compiler_static_CXX" | $SED "$delay_single_quote_subst"`' +lt_cv_prog_compiler_c_o_CXX='`$ECHO "$lt_cv_prog_compiler_c_o_CXX" | $SED "$delay_single_quote_subst"`' +archive_cmds_need_lc_CXX='`$ECHO "$archive_cmds_need_lc_CXX" | $SED "$delay_single_quote_subst"`' +enable_shared_with_static_runtimes_CXX='`$ECHO "$enable_shared_with_static_runtimes_CXX" | $SED "$delay_single_quote_subst"`' +export_dynamic_flag_spec_CXX='`$ECHO "$export_dynamic_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' +whole_archive_flag_spec_CXX='`$ECHO "$whole_archive_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' +compiler_needs_object_CXX='`$ECHO "$compiler_needs_object_CXX" | $SED "$delay_single_quote_subst"`' +old_archive_from_new_cmds_CXX='`$ECHO "$old_archive_from_new_cmds_CXX" | $SED "$delay_single_quote_subst"`' +old_archive_from_expsyms_cmds_CXX='`$ECHO "$old_archive_from_expsyms_cmds_CXX" | $SED "$delay_single_quote_subst"`' +archive_cmds_CXX='`$ECHO "$archive_cmds_CXX" | $SED "$delay_single_quote_subst"`' +archive_expsym_cmds_CXX='`$ECHO "$archive_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`' +module_cmds_CXX='`$ECHO "$module_cmds_CXX" | $SED "$delay_single_quote_subst"`' +module_expsym_cmds_CXX='`$ECHO "$module_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`' +with_gnu_ld_CXX='`$ECHO "$with_gnu_ld_CXX" | $SED "$delay_single_quote_subst"`' +allow_undefined_flag_CXX='`$ECHO "$allow_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`' +no_undefined_flag_CXX='`$ECHO "$no_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_flag_spec_CXX='`$ECHO "$hardcode_libdir_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_separator_CXX='`$ECHO "$hardcode_libdir_separator_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_direct_CXX='`$ECHO "$hardcode_direct_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_direct_absolute_CXX='`$ECHO "$hardcode_direct_absolute_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_minus_L_CXX='`$ECHO "$hardcode_minus_L_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_shlibpath_var_CXX='`$ECHO "$hardcode_shlibpath_var_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_automatic_CXX='`$ECHO "$hardcode_automatic_CXX" | $SED "$delay_single_quote_subst"`' +inherit_rpath_CXX='`$ECHO "$inherit_rpath_CXX" | $SED "$delay_single_quote_subst"`' +link_all_deplibs_CXX='`$ECHO "$link_all_deplibs_CXX" | $SED "$delay_single_quote_subst"`' +always_export_symbols_CXX='`$ECHO "$always_export_symbols_CXX" | $SED "$delay_single_quote_subst"`' +export_symbols_cmds_CXX='`$ECHO "$export_symbols_cmds_CXX" | $SED "$delay_single_quote_subst"`' +exclude_expsyms_CXX='`$ECHO "$exclude_expsyms_CXX" | $SED "$delay_single_quote_subst"`' +include_expsyms_CXX='`$ECHO "$include_expsyms_CXX" | $SED "$delay_single_quote_subst"`' +prelink_cmds_CXX='`$ECHO "$prelink_cmds_CXX" | $SED "$delay_single_quote_subst"`' +postlink_cmds_CXX='`$ECHO "$postlink_cmds_CXX" | $SED "$delay_single_quote_subst"`' +file_list_spec_CXX='`$ECHO "$file_list_spec_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_action_CXX='`$ECHO "$hardcode_action_CXX" | $SED "$delay_single_quote_subst"`' +compiler_lib_search_dirs_CXX='`$ECHO "$compiler_lib_search_dirs_CXX" | $SED "$delay_single_quote_subst"`' +predep_objects_CXX='`$ECHO "$predep_objects_CXX" | $SED "$delay_single_quote_subst"`' +postdep_objects_CXX='`$ECHO "$postdep_objects_CXX" | $SED "$delay_single_quote_subst"`' +predeps_CXX='`$ECHO "$predeps_CXX" | $SED "$delay_single_quote_subst"`' +postdeps_CXX='`$ECHO "$postdeps_CXX" | $SED "$delay_single_quote_subst"`' +compiler_lib_search_path_CXX='`$ECHO "$compiler_lib_search_path_CXX" | $SED "$delay_single_quote_subst"`' + +LTCC='$LTCC' +LTCFLAGS='$LTCFLAGS' +compiler='$compiler_DEFAULT' + +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +\$1 +_LTECHO_EOF' +} + +# Quote evaled strings. +for var in AS \ +DLLTOOL \ +OBJDUMP \ +SHELL \ +ECHO \ +PATH_SEPARATOR \ +SED \ +GREP \ +EGREP \ +FGREP \ +LD \ +NM \ +LN_S \ +lt_SP2NL \ +lt_NL2SP \ +reload_flag \ +deplibs_check_method \ +file_magic_cmd \ +file_magic_glob \ +want_nocaseglob \ +sharedlib_from_linklib_cmd \ +AR \ +AR_FLAGS \ +archiver_list_spec \ +STRIP \ +RANLIB \ +CC \ +CFLAGS \ +compiler \ +lt_cv_sys_global_symbol_pipe \ +lt_cv_sys_global_symbol_to_cdecl \ +lt_cv_sys_global_symbol_to_import \ +lt_cv_sys_global_symbol_to_c_name_address \ +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \ +lt_cv_nm_interface \ +nm_file_list_spec \ +lt_cv_truncate_bin \ +lt_prog_compiler_no_builtin_flag \ +lt_prog_compiler_pic \ +lt_prog_compiler_wl \ +lt_prog_compiler_static \ +lt_cv_prog_compiler_c_o \ +need_locks \ +MANIFEST_TOOL \ +DSYMUTIL \ +NMEDIT \ +LIPO \ +OTOOL \ +OTOOL64 \ +shrext_cmds \ +export_dynamic_flag_spec \ +whole_archive_flag_spec \ +compiler_needs_object \ +with_gnu_ld \ +allow_undefined_flag \ +no_undefined_flag \ +hardcode_libdir_flag_spec \ +hardcode_libdir_separator \ +exclude_expsyms \ +include_expsyms \ +file_list_spec \ +variables_saved_for_relink \ +libname_spec \ +library_names_spec \ +soname_spec \ +install_override_mode \ +finish_eval \ +old_striplib \ +striplib \ +compiler_lib_search_dirs \ +predep_objects \ +postdep_objects \ +predeps \ +postdeps \ +compiler_lib_search_path \ +LD_CXX \ +reload_flag_CXX \ +compiler_CXX \ +lt_prog_compiler_no_builtin_flag_CXX \ +lt_prog_compiler_pic_CXX \ +lt_prog_compiler_wl_CXX \ +lt_prog_compiler_static_CXX \ +lt_cv_prog_compiler_c_o_CXX \ +export_dynamic_flag_spec_CXX \ +whole_archive_flag_spec_CXX \ +compiler_needs_object_CXX \ +with_gnu_ld_CXX \ +allow_undefined_flag_CXX \ +no_undefined_flag_CXX \ +hardcode_libdir_flag_spec_CXX \ +hardcode_libdir_separator_CXX \ +exclude_expsyms_CXX \ +include_expsyms_CXX \ +file_list_spec_CXX \ +compiler_lib_search_dirs_CXX \ +predep_objects_CXX \ +postdep_objects_CXX \ +predeps_CXX \ +postdeps_CXX \ +compiler_lib_search_path_CXX; do + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in + *[\\\\\\\`\\"\\\$]*) + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes + ;; + *) + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" + ;; + esac +done + +# Double-quote double-evaled strings. +for var in reload_cmds \ +old_postinstall_cmds \ +old_postuninstall_cmds \ +old_archive_cmds \ +extract_expsyms_cmds \ +old_archive_from_new_cmds \ +old_archive_from_expsyms_cmds \ +archive_cmds \ +archive_expsym_cmds \ +module_cmds \ +module_expsym_cmds \ +export_symbols_cmds \ +prelink_cmds \ +postlink_cmds \ +postinstall_cmds \ +postuninstall_cmds \ +finish_cmds \ +sys_lib_search_path_spec \ +configure_time_dlsearch_path \ +configure_time_lt_sys_library_path \ +reload_cmds_CXX \ +old_archive_cmds_CXX \ +old_archive_from_new_cmds_CXX \ +old_archive_from_expsyms_cmds_CXX \ +archive_cmds_CXX \ +archive_expsym_cmds_CXX \ +module_cmds_CXX \ +module_expsym_cmds_CXX \ +export_symbols_cmds_CXX \ +prelink_cmds_CXX \ +postlink_cmds_CXX; do + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in + *[\\\\\\\`\\"\\\$]*) + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes + ;; + *) + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" + ;; + esac +done + +ac_aux_dir='$ac_aux_dir' + +# See if we are running on zsh, and set the options that allow our +# commands through without removal of \ escapes INIT. +if test -n "\${ZSH_VERSION+set}"; then + setopt NO_GLOB_SUBST +fi + + + PACKAGE='$PACKAGE' + VERSION='$VERSION' + RM='$RM' + ofile='$ofile' + + + + + + +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 + +# Handling of arguments. +for ac_config_target in $ac_config_targets +do + case $ac_config_target in + "ode/src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS ode/src/config.h" ;; + "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; + "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;; + "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; + "drawstuff/Makefile") CONFIG_FILES="$CONFIG_FILES drawstuff/Makefile" ;; + "drawstuff/src/Makefile") CONFIG_FILES="$CONFIG_FILES drawstuff/src/Makefile" ;; + "drawstuff/dstest/Makefile") CONFIG_FILES="$CONFIG_FILES drawstuff/dstest/Makefile" ;; + "include/Makefile") CONFIG_FILES="$CONFIG_FILES include/Makefile" ;; + "include/drawstuff/Makefile") CONFIG_FILES="$CONFIG_FILES include/drawstuff/Makefile" ;; + "include/ode/Makefile") CONFIG_FILES="$CONFIG_FILES include/ode/Makefile" ;; + "include/ode/version.h") CONFIG_FILES="$CONFIG_FILES include/ode/version.h" ;; + "include/ode/precision.h") CONFIG_FILES="$CONFIG_FILES include/ode/precision.h" ;; + "ode/Makefile") CONFIG_FILES="$CONFIG_FILES ode/Makefile" ;; + "ode/doc/Doxyfile") CONFIG_FILES="$CONFIG_FILES ode/doc/Doxyfile" ;; + "ode/doc/Makefile") CONFIG_FILES="$CONFIG_FILES ode/doc/Makefile" ;; + "ode/src/Makefile") CONFIG_FILES="$CONFIG_FILES ode/src/Makefile" ;; + "ode/src/joints/Makefile") CONFIG_FILES="$CONFIG_FILES ode/src/joints/Makefile" ;; + "ode/demo/Makefile") CONFIG_FILES="$CONFIG_FILES ode/demo/Makefile" ;; + "OPCODE/Makefile") CONFIG_FILES="$CONFIG_FILES OPCODE/Makefile" ;; + "OPCODE/Ice/Makefile") CONFIG_FILES="$CONFIG_FILES OPCODE/Ice/Makefile" ;; + "GIMPACT/Makefile") CONFIG_FILES="$CONFIG_FILES GIMPACT/Makefile" ;; + "GIMPACT/include/Makefile") CONFIG_FILES="$CONFIG_FILES GIMPACT/include/Makefile" ;; + "GIMPACT/include/GIMPACT/Makefile") CONFIG_FILES="$CONFIG_FILES GIMPACT/include/GIMPACT/Makefile" ;; + "GIMPACT/src/Makefile") CONFIG_FILES="$CONFIG_FILES GIMPACT/src/Makefile" ;; + "tests/Makefile") CONFIG_FILES="$CONFIG_FILES tests/Makefile" ;; + "tests/joints/Makefile") CONFIG_FILES="$CONFIG_FILES tests/joints/Makefile" ;; + "tests/UnitTest++/Makefile") CONFIG_FILES="$CONFIG_FILES tests/UnitTest++/Makefile" ;; + "tests/UnitTest++/src/Makefile") CONFIG_FILES="$CONFIG_FILES tests/UnitTest++/src/Makefile" ;; + "tests/UnitTest++/src/Posix/Makefile") CONFIG_FILES="$CONFIG_FILES tests/UnitTest++/src/Posix/Makefile" ;; + "tests/UnitTest++/src/Win32/Makefile") CONFIG_FILES="$CONFIG_FILES tests/UnitTest++/src/Win32/Makefile" ;; + "ode-config") CONFIG_FILES="$CONFIG_FILES ode-config" ;; + "ode.pc") CONFIG_FILES="$CONFIG_FILES ode.pc" ;; + + *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; + esac +done + + +# If the user did not use the arguments to specify the items to instantiate, +# then the envvar interface is used. Set only those that are not. +# We use the long form for the default assignment because of an extremely +# bizarre bug on SunOS 4.1.3. +if $ac_need_defaults; then + test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files + test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers + test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands +fi + +# Have a temporary directory for convenience. Make it in the build tree +# simply because there is no reason against having it here, and in addition, +# creating and moving files from /tmp can sometimes cause problems. +# Hook for its removal unless debugging. +# Note that there is a small window in which the directory will not be cleaned: +# after its creation but before its name has been assigned to `$tmp'. +$debug || +{ + tmp= ac_tmp= + trap 'exit_status=$? + : "${ac_tmp:=$tmp}" + { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status +' 0 + trap 'as_fn_exit 1' 1 2 13 15 +} +# Create a (secure) tmp directory for tmp files. + +{ + tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && + test -d "$tmp" +} || +{ + tmp=./conf$$-$RANDOM + (umask 077 && mkdir "$tmp") +} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 +ac_tmp=$tmp + +# Set up the scripts for CONFIG_FILES section. +# No need to generate them if there are no CONFIG_FILES. +# This happens for instance with `./config.status config.h'. +if test -n "$CONFIG_FILES"; then + + +ac_cr=`echo X | tr X '\015'` +# On cygwin, bash can eat \r inside `` if the user requested igncr. +# But we know of no other shell where ac_cr would be empty at this +# point, so we can use a bashism as a fallback. +if test "x$ac_cr" = x; then + eval ac_cr=\$\'\\r\' +fi +ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' /dev/null` +if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then + ac_cs_awk_cr='\\r' +else + ac_cs_awk_cr=$ac_cr +fi + +echo 'BEGIN {' >"$ac_tmp/subs1.awk" && +_ACEOF + + +{ + echo "cat >conf$$subs.awk <<_ACEOF" && + echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && + echo "_ACEOF" +} >conf$$subs.sh || + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 +ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` +ac_delim='%!_!# ' +for ac_last_try in false false false false false :; do + . ./conf$$subs.sh || + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 + + ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` + if test $ac_delim_n = $ac_delim_num; then + break + elif $ac_last_try; then + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 + else + ac_delim="$ac_delim!$ac_delim _$ac_delim!! " + fi +done +rm -f conf$$subs.sh + +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && +_ACEOF +sed -n ' +h +s/^/S["/; s/!.*/"]=/ +p +g +s/^[^!]*!// +:repl +t repl +s/'"$ac_delim"'$// +t delim +:nl +h +s/\(.\{148\}\)..*/\1/ +t more1 +s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ +p +n +b repl +:more1 +s/["\\]/\\&/g; s/^/"/; s/$/"\\/ +p +g +s/.\{148\}// +t nl +:delim +h +s/\(.\{148\}\)..*/\1/ +t more2 +s/["\\]/\\&/g; s/^/"/; s/$/"/ +p +b +:more2 +s/["\\]/\\&/g; s/^/"/; s/$/"\\/ +p +g +s/.\{148\}// +t delim +' >$CONFIG_STATUS || ac_write_fail=1 +rm -f conf$$subs.awk +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +_ACAWK +cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && + for (key in S) S_is_set[key] = 1 + FS = "" + +} +{ + line = $ 0 + nfields = split(line, field, "@") + substed = 0 + len = length(field[1]) + for (i = 2; i < nfields; i++) { + key = field[i] + keylen = length(key) + if (S_is_set[key]) { + value = S[key] + line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) + len += length(value) + length(field[++i]) + substed = 1 + } else + len += 1 + keylen + } + + print line +} + +_ACAWK +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then + sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" +else + cat +fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ + || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 +_ACEOF + +# VPATH may cause trouble with some makes, so we remove sole $(srcdir), +# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and +# trailing colons and then remove the whole line if VPATH becomes empty +# (actually we leave an empty line to preserve line numbers). +if test "x$srcdir" = x.; then + ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ +h +s/// +s/^/:/ +s/[ ]*$/:/ +s/:\$(srcdir):/:/g +s/:\${srcdir}:/:/g +s/:@srcdir@:/:/g +s/^:*// +s/:*$// +x +s/\(=[ ]*\).*/\1/ +G +s/\n// +s/^[^=]*=[ ]*$// +}' +fi + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +fi # test -n "$CONFIG_FILES" + +# Set up the scripts for CONFIG_HEADERS section. +# No need to generate them if there are no CONFIG_HEADERS. +# This happens for instance with `./config.status Makefile'. +if test -n "$CONFIG_HEADERS"; then +cat >"$ac_tmp/defines.awk" <<\_ACAWK || +BEGIN { +_ACEOF + +# Transform confdefs.h into an awk script `defines.awk', embedded as +# here-document in config.status, that substitutes the proper values into +# config.h.in to produce config.h. + +# Create a delimiter string that does not exist in confdefs.h, to ease +# handling of long lines. +ac_delim='%!_!# ' +for ac_last_try in false false :; do + ac_tt=`sed -n "/$ac_delim/p" confdefs.h` + if test -z "$ac_tt"; then + break + elif $ac_last_try; then + as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 + else + ac_delim="$ac_delim!$ac_delim _$ac_delim!! " + fi +done + +# For the awk script, D is an array of macro values keyed by name, +# likewise P contains macro parameters if any. Preserve backslash +# newline sequences. + +ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* +sed -n ' +s/.\{148\}/&'"$ac_delim"'/g +t rset +:rset +s/^[ ]*#[ ]*define[ ][ ]*/ / +t def +d +:def +s/\\$// +t bsnl +s/["\\]/\\&/g +s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ +D["\1"]=" \3"/p +s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p +d +:bsnl +s/["\\]/\\&/g +s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ +D["\1"]=" \3\\\\\\n"\\/p +t cont +s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p +t cont +d +:cont +n +s/.\{148\}/&'"$ac_delim"'/g +t clear +:clear +s/\\$// +t bsnlc +s/["\\]/\\&/g; s/^/"/; s/$/"/p +d +:bsnlc +s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p +b cont +' >$CONFIG_STATUS || ac_write_fail=1 + +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 + for (key in D) D_is_set[key] = 1 + FS = "" +} +/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { + line = \$ 0 + split(line, arg, " ") + if (arg[1] == "#") { + defundef = arg[2] + mac1 = arg[3] + } else { + defundef = substr(arg[1], 2) + mac1 = arg[2] + } + split(mac1, mac2, "(") #) + macro = mac2[1] + prefix = substr(line, 1, index(line, defundef) - 1) + if (D_is_set[macro]) { + # Preserve the white space surrounding the "#". + print prefix "define", macro P[macro] D[macro] + next + } else { + # Replace #undef with comments. This is necessary, for example, + # in the case of _POSIX_SOURCE, which is predefined and required + # on some systems where configure will not decide to define it. + if (defundef == "undef") { + print "/*", prefix defundef, macro, "*/" + next + } + } +} +{ print } +_ACAWK +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 + as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 +fi # test -n "$CONFIG_HEADERS" + + +eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" +shift +for ac_tag +do + case $ac_tag in + :[FHLC]) ac_mode=$ac_tag; continue;; + esac + case $ac_mode$ac_tag in + :[FHL]*:*);; + :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; + :[FH]-) ac_tag=-:-;; + :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; + esac + ac_save_IFS=$IFS + IFS=: + set x $ac_tag + IFS=$ac_save_IFS + shift + ac_file=$1 + shift + + case $ac_mode in + :L) ac_source=$1;; + :[FH]) + ac_file_inputs= + for ac_f + do + case $ac_f in + -) ac_f="$ac_tmp/stdin";; + *) # Look for the file first in the build tree, then in the source tree + # (if the path is not absolute). The absolute path cannot be DOS-style, + # because $ac_f cannot contain `:'. + test -f "$ac_f" || + case $ac_f in + [\\/$]*) false;; + *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; + esac || + as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; + esac + case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac + as_fn_append ac_file_inputs " '$ac_f'" + done + + # Let's still pretend it is `configure' which instantiates (i.e., don't + # use $as_me), people would be surprised to read: + # /* config.h. Generated by config.status. */ + configure_input='Generated from '` + $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' + `' by configure.' + if test x"$ac_file" != x-; then + configure_input="$ac_file. $configure_input" + { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 +$as_echo "$as_me: creating $ac_file" >&6;} + fi + # Neutralize special characters interpreted by sed in replacement strings. + case $configure_input in #( + *\&* | *\|* | *\\* ) + ac_sed_conf_input=`$as_echo "$configure_input" | + sed 's/[\\\\&|]/\\\\&/g'`;; #( + *) ac_sed_conf_input=$configure_input;; + esac + + case $ac_tag in + *:-:* | *:-) cat >"$ac_tmp/stdin" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; + esac + ;; + esac + + ac_dir=`$as_dirname -- "$ac_file" || +$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$ac_file" : 'X\(//\)[^/]' \| \ + X"$ac_file" : 'X\(//\)$' \| \ + X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$ac_file" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + as_dir="$ac_dir"; as_fn_mkdir_p + ac_builddir=. + +case "$ac_dir" in +.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; +*) + ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` + # A ".." for each directory in $ac_dir_suffix. + ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` + case $ac_top_builddir_sub in + "") ac_top_builddir_sub=. ac_top_build_prefix= ;; + *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; + esac ;; +esac +ac_abs_top_builddir=$ac_pwd +ac_abs_builddir=$ac_pwd$ac_dir_suffix +# for backward compatibility: +ac_top_builddir=$ac_top_build_prefix + +case $srcdir in + .) # We are building in place. + ac_srcdir=. + ac_top_srcdir=$ac_top_builddir_sub + ac_abs_top_srcdir=$ac_pwd ;; + [\\/]* | ?:[\\/]* ) # Absolute name. + ac_srcdir=$srcdir$ac_dir_suffix; + ac_top_srcdir=$srcdir + ac_abs_top_srcdir=$srcdir ;; + *) # Relative name. + ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix + ac_top_srcdir=$ac_top_build_prefix$srcdir + ac_abs_top_srcdir=$ac_pwd/$srcdir ;; +esac +ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix + + + case $ac_mode in + :F) + # + # CONFIG_FILE + # + + case $INSTALL in + [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; + *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; + esac + ac_MKDIR_P=$MKDIR_P + case $MKDIR_P in + [\\/$]* | ?:[\\/]* ) ;; + */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; + esac +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# If the template does not know about datarootdir, expand it. +# FIXME: This hack should be removed a few years after 2.60. +ac_datarootdir_hack=; ac_datarootdir_seen= +ac_sed_dataroot=' +/datarootdir/ { + p + q +} +/@datadir@/p +/@docdir@/p +/@infodir@/p +/@localedir@/p +/@mandir@/p' +case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in +*datarootdir*) ac_datarootdir_seen=yes;; +*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 +$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 + ac_datarootdir_hack=' + s&@datadir@&$datadir&g + s&@docdir@&$docdir&g + s&@infodir@&$infodir&g + s&@localedir@&$localedir&g + s&@mandir@&$mandir&g + s&\\\${datarootdir}&$datarootdir&g' ;; +esac +_ACEOF + +# Neutralize VPATH when `$srcdir' = `.'. +# Shell code in configure.ac might set extrasub. +# FIXME: do we really want to maintain this feature? +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +ac_sed_extra="$ac_vpsub +$extrasub +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +:t +/@[a-zA-Z_][a-zA-Z_0-9]*@/!b +s|@configure_input@|$ac_sed_conf_input|;t t +s&@top_builddir@&$ac_top_builddir_sub&;t t +s&@top_build_prefix@&$ac_top_build_prefix&;t t +s&@srcdir@&$ac_srcdir&;t t +s&@abs_srcdir@&$ac_abs_srcdir&;t t +s&@top_srcdir@&$ac_top_srcdir&;t t +s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t +s&@builddir@&$ac_builddir&;t t +s&@abs_builddir@&$ac_abs_builddir&;t t +s&@abs_top_builddir@&$ac_abs_top_builddir&;t t +s&@INSTALL@&$ac_INSTALL&;t t +s&@MKDIR_P@&$ac_MKDIR_P&;t t +$ac_datarootdir_hack +" +eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ + >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + +test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && + { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && + { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ + "$ac_tmp/out"`; test -z "$ac_out"; } && + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' +which seems to be undefined. Please make sure it is defined" >&5 +$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' +which seems to be undefined. Please make sure it is defined" >&2;} + + rm -f "$ac_tmp/stdin" + case $ac_file in + -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; + *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; + esac \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + ;; + :H) + # + # CONFIG_HEADER + # + if test x"$ac_file" != x-; then + { + $as_echo "/* $configure_input */" \ + && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" + } >"$ac_tmp/config.h" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then + { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 +$as_echo "$as_me: $ac_file is unchanged" >&6;} + else + rm -f "$ac_file" + mv "$ac_tmp/config.h" "$ac_file" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + fi + else + $as_echo "/* $configure_input */" \ + && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ + || as_fn_error $? "could not create -" "$LINENO" 5 + fi +# Compute "$ac_file"'s index in $config_headers. +_am_arg="$ac_file" +_am_stamp_count=1 +for _am_header in $config_headers :; do + case $_am_header in + $_am_arg | $_am_arg:* ) + break ;; + * ) + _am_stamp_count=`expr $_am_stamp_count + 1` ;; + esac +done +echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" || +$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$_am_arg" : 'X\(//\)[^/]' \| \ + X"$_am_arg" : 'X\(//\)$' \| \ + X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$_am_arg" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'`/stamp-h$_am_stamp_count + ;; + + :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 +$as_echo "$as_me: executing $ac_file commands" >&6;} + ;; + esac + + + case $ac_file$ac_mode in + "depfiles":C) test x"$AMDEP_TRUE" != x"" || { + # Older Autoconf quotes --file arguments for eval, but not when files + # are listed without --file. Let's play safe and only enable the eval + # if we detect the quoting. + case $CONFIG_FILES in + *\'*) eval set x "$CONFIG_FILES" ;; + *) set x $CONFIG_FILES ;; + esac + shift + for mf + do + # Strip MF so we end up with the name of the file. + mf=`echo "$mf" | sed -e 's/:.*$//'` + # Check whether this is an Automake generated Makefile or not. + # We used to match only the files named 'Makefile.in', but + # some people rename them; so instead we look at the file content. + # Grep'ing the first line is not enough: some people post-process + # each Makefile.in and add a new line on top of each file to say so. + # Grep'ing the whole file is not good either: AIX grep has a line + # limit of 2048, but all sed's we know have understand at least 4000. + if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then + dirpart=`$as_dirname -- "$mf" || +$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$mf" : 'X\(//\)[^/]' \| \ + X"$mf" : 'X\(//\)$' \| \ + X"$mf" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$mf" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + else + continue + fi + # Extract the definition of DEPDIR, am__include, and am__quote + # from the Makefile without running 'make'. + DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` + test -z "$DEPDIR" && continue + am__include=`sed -n 's/^am__include = //p' < "$mf"` + test -z "$am__include" && continue + am__quote=`sed -n 's/^am__quote = //p' < "$mf"` + # Find all dependency output files, they are included files with + # $(DEPDIR) in their names. We invoke sed twice because it is the + # simplest approach to changing $(DEPDIR) to its actual value in the + # expansion. + for file in `sed -n " + s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ + sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do + # Make sure the directory exists. + test -f "$dirpart/$file" && continue + fdir=`$as_dirname -- "$file" || +$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$file" : 'X\(//\)[^/]' \| \ + X"$file" : 'X\(//\)$' \| \ + X"$file" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$file" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + as_dir=$dirpart/$fdir; as_fn_mkdir_p + # echo "creating $dirpart/$file" + echo '# dummy' > "$dirpart/$file" + done + done +} + ;; + "libtool":C) + + # See if we are running on zsh, and set the options that allow our + # commands through without removal of \ escapes. + if test -n "${ZSH_VERSION+set}"; then + setopt NO_GLOB_SUBST + fi + + cfgfile=${ofile}T + trap "$RM \"$cfgfile\"; exit 1" 1 2 15 + $RM "$cfgfile" + + cat <<_LT_EOF >> "$cfgfile" +#! $SHELL +# Generated automatically by $as_me ($PACKAGE) $VERSION +# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +# NOTE: Changes made to this file will be lost: look at ltmain.sh. + +# Provide generalized library-building support services. +# Written by Gordon Matzigkeit, 1996 + +# Copyright (C) 2014 Free Software Foundation, Inc. +# This is free software; see the source for copying conditions. There is NO +# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + +# GNU Libtool is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of of the License, or +# (at your option) any later version. +# +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program or library that is built +# using GNU Libtool, you may include this file under the same +# distribution terms that you use for the rest of that program. +# +# GNU Libtool is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + + +# The names of the tagged configurations supported by this script. +available_tags='CXX ' + +# Configured defaults for sys_lib_dlsearch_path munging. +: \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"} + +# ### BEGIN LIBTOOL CONFIG + +# Which release of libtool.m4 was used? +macro_version=$macro_version +macro_revision=$macro_revision + +# Whether or not to build shared libraries. +build_libtool_libs=$enable_shared + +# Assembler program. +AS=$lt_AS + +# DLL creation program. +DLLTOOL=$lt_DLLTOOL + +# Object dumper program. +OBJDUMP=$lt_OBJDUMP + +# Whether or not to build static libraries. +build_old_libs=$enable_static + +# What type of objects to build. +pic_mode=$pic_mode + +# Whether or not to optimize for fast installation. +fast_install=$enable_fast_install + +# Shared archive member basename,for filename based shared library versioning on AIX. +shared_archive_member_spec=$shared_archive_member_spec + +# Shell to use when invoking shell scripts. +SHELL=$lt_SHELL + +# An echo program that protects backslashes. +ECHO=$lt_ECHO + +# The PATH separator for the build system. +PATH_SEPARATOR=$lt_PATH_SEPARATOR + +# The host system. +host_alias=$host_alias +host=$host +host_os=$host_os + +# The build system. +build_alias=$build_alias +build=$build +build_os=$build_os + +# A sed program that does not truncate output. +SED=$lt_SED + +# Sed that helps us avoid accidentally triggering echo(1) options like -n. +Xsed="\$SED -e 1s/^X//" + +# A grep program that handles long lines. +GREP=$lt_GREP + +# An ERE matcher. +EGREP=$lt_EGREP + +# A literal string matcher. +FGREP=$lt_FGREP + +# A BSD- or MS-compatible name lister. +NM=$lt_NM + +# Whether we need soft or hard links. +LN_S=$lt_LN_S + +# What is the maximum length of a command? +max_cmd_len=$max_cmd_len + +# Object file suffix (normally "o"). +objext=$ac_objext + +# Executable file suffix (normally ""). +exeext=$exeext + +# whether the shell understands "unset". +lt_unset=$lt_unset + +# turn spaces into newlines. +SP2NL=$lt_lt_SP2NL + +# turn newlines into spaces. +NL2SP=$lt_lt_NL2SP + +# convert \$build file names to \$host format. +to_host_file_cmd=$lt_cv_to_host_file_cmd + +# convert \$build files to toolchain format. +to_tool_file_cmd=$lt_cv_to_tool_file_cmd + +# Method to check whether dependent libraries are shared objects. +deplibs_check_method=$lt_deplibs_check_method + +# Command to use when deplibs_check_method = "file_magic". +file_magic_cmd=$lt_file_magic_cmd + +# How to find potential files when deplibs_check_method = "file_magic". +file_magic_glob=$lt_file_magic_glob + +# Find potential files using nocaseglob when deplibs_check_method = "file_magic". +want_nocaseglob=$lt_want_nocaseglob + +# Command to associate shared and link libraries. +sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd + +# The archiver. +AR=$lt_AR + +# Flags to create an archive. +AR_FLAGS=$lt_AR_FLAGS + +# How to feed a file listing to the archiver. +archiver_list_spec=$lt_archiver_list_spec + +# A symbol stripping program. +STRIP=$lt_STRIP + +# Commands used to install an old-style archive. +RANLIB=$lt_RANLIB +old_postinstall_cmds=$lt_old_postinstall_cmds +old_postuninstall_cmds=$lt_old_postuninstall_cmds + +# Whether to use a lock for old archive extraction. +lock_old_archive_extraction=$lock_old_archive_extraction + +# A C compiler. +LTCC=$lt_CC + +# LTCC compiler flags. +LTCFLAGS=$lt_CFLAGS + +# Take the output of nm and produce a listing of raw symbols and C names. +global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe + +# Transform the output of nm in a proper C declaration. +global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl + +# Transform the output of nm into a list of symbols to manually relocate. +global_symbol_to_import=$lt_lt_cv_sys_global_symbol_to_import + +# Transform the output of nm in a C name address pair. +global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address + +# Transform the output of nm in a C name address pair when lib prefix is needed. +global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix + +# The name lister interface. +nm_interface=$lt_lt_cv_nm_interface + +# Specify filename containing input files for \$NM. +nm_file_list_spec=$lt_nm_file_list_spec + +# The root where to search for dependent libraries,and where our libraries should be installed. +lt_sysroot=$lt_sysroot + +# Command to truncate a binary pipe. +lt_truncate_bin=$lt_lt_cv_truncate_bin + +# The name of the directory that contains temporary libtool files. +objdir=$objdir + +# Used to examine libraries when file_magic_cmd begins with "file". +MAGIC_CMD=$MAGIC_CMD + +# Must we lock files when doing compilation? +need_locks=$lt_need_locks + +# Manifest tool. +MANIFEST_TOOL=$lt_MANIFEST_TOOL + +# Tool to manipulate archived DWARF debug symbol files on Mac OS X. +DSYMUTIL=$lt_DSYMUTIL + +# Tool to change global to local symbols on Mac OS X. +NMEDIT=$lt_NMEDIT + +# Tool to manipulate fat objects and archives on Mac OS X. +LIPO=$lt_LIPO + +# ldd/readelf like tool for Mach-O binaries on Mac OS X. +OTOOL=$lt_OTOOL + +# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4. +OTOOL64=$lt_OTOOL64 + +# Old archive suffix (normally "a"). +libext=$libext + +# Shared library suffix (normally ".so"). +shrext_cmds=$lt_shrext_cmds + +# The commands to extract the exported symbol list from a shared archive. +extract_expsyms_cmds=$lt_extract_expsyms_cmds + +# Variables whose values should be saved in libtool wrapper scripts and +# restored at link time. +variables_saved_for_relink=$lt_variables_saved_for_relink + +# Do we need the "lib" prefix for modules? +need_lib_prefix=$need_lib_prefix + +# Do we need a version for libraries? +need_version=$need_version + +# Library versioning type. +version_type=$version_type + +# Shared library runtime path variable. +runpath_var=$runpath_var + +# Shared library path variable. +shlibpath_var=$shlibpath_var + +# Is shlibpath searched before the hard-coded library search path? +shlibpath_overrides_runpath=$shlibpath_overrides_runpath + +# Format of library name prefix. +libname_spec=$lt_libname_spec + +# List of archive names. First name is the real one, the rest are links. +# The last name is the one that the linker finds with -lNAME +library_names_spec=$lt_library_names_spec + +# The coded name of the library, if different from the real name. +soname_spec=$lt_soname_spec + +# Permission mode override for installation of shared libraries. +install_override_mode=$lt_install_override_mode + +# Command to use after installation of a shared archive. +postinstall_cmds=$lt_postinstall_cmds + +# Command to use after uninstallation of a shared archive. +postuninstall_cmds=$lt_postuninstall_cmds + +# Commands used to finish a libtool library installation in a directory. +finish_cmds=$lt_finish_cmds + +# As "finish_cmds", except a single script fragment to be evaled but +# not shown. +finish_eval=$lt_finish_eval + +# Whether we should hardcode library paths into libraries. +hardcode_into_libs=$hardcode_into_libs + +# Compile-time system search path for libraries. +sys_lib_search_path_spec=$lt_sys_lib_search_path_spec + +# Detected run-time system search path for libraries. +sys_lib_dlsearch_path_spec=$lt_configure_time_dlsearch_path + +# Explicit LT_SYS_LIBRARY_PATH set during ./configure time. +configure_time_lt_sys_library_path=$lt_configure_time_lt_sys_library_path + +# Whether dlopen is supported. +dlopen_support=$enable_dlopen + +# Whether dlopen of programs is supported. +dlopen_self=$enable_dlopen_self + +# Whether dlopen of statically linked programs is supported. +dlopen_self_static=$enable_dlopen_self_static + +# Commands to strip libraries. +old_striplib=$lt_old_striplib +striplib=$lt_striplib + + +# The linker used to build libraries. +LD=$lt_LD + +# How to create reloadable object files. +reload_flag=$lt_reload_flag +reload_cmds=$lt_reload_cmds + +# Commands used to build an old-style archive. +old_archive_cmds=$lt_old_archive_cmds + +# A language specific compiler. +CC=$lt_compiler + +# Is the compiler the GNU compiler? +with_gcc=$GCC + +# Compiler flag to turn off builtin functions. +no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag + +# Additional compiler flags for building library objects. +pic_flag=$lt_lt_prog_compiler_pic + +# How to pass a linker flag through the compiler. +wl=$lt_lt_prog_compiler_wl + +# Compiler flag to prevent dynamic linking. +link_static_flag=$lt_lt_prog_compiler_static + +# Does compiler simultaneously support -c and -o options? +compiler_c_o=$lt_lt_cv_prog_compiler_c_o + +# Whether or not to add -lc for building shared libraries. +build_libtool_need_lc=$archive_cmds_need_lc + +# Whether or not to disallow shared libs when runtime libs are static. +allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes + +# Compiler flag to allow reflexive dlopens. +export_dynamic_flag_spec=$lt_export_dynamic_flag_spec + +# Compiler flag to generate shared objects directly from archives. +whole_archive_flag_spec=$lt_whole_archive_flag_spec + +# Whether the compiler copes with passing no objects directly. +compiler_needs_object=$lt_compiler_needs_object + +# Create an old-style archive from a shared archive. +old_archive_from_new_cmds=$lt_old_archive_from_new_cmds + +# Create a temporary old-style archive to link instead of a shared archive. +old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds + +# Commands used to build a shared archive. +archive_cmds=$lt_archive_cmds +archive_expsym_cmds=$lt_archive_expsym_cmds + +# Commands used to build a loadable module if different from building +# a shared archive. +module_cmds=$lt_module_cmds +module_expsym_cmds=$lt_module_expsym_cmds + +# Whether we are building with GNU ld or not. +with_gnu_ld=$lt_with_gnu_ld + +# Flag that allows shared libraries with undefined symbols to be built. +allow_undefined_flag=$lt_allow_undefined_flag + +# Flag that enforces no undefined symbols. +no_undefined_flag=$lt_no_undefined_flag + +# Flag to hardcode \$libdir into a binary during linking. +# This must work even if \$libdir does not exist +hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec + +# Whether we need a single "-rpath" flag with a separated argument. +hardcode_libdir_separator=$lt_hardcode_libdir_separator + +# Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes +# DIR into the resulting binary. +hardcode_direct=$hardcode_direct + +# Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes +# DIR into the resulting binary and the resulting library dependency is +# "absolute",i.e impossible to change by setting \$shlibpath_var if the +# library is relocated. +hardcode_direct_absolute=$hardcode_direct_absolute + +# Set to "yes" if using the -LDIR flag during linking hardcodes DIR +# into the resulting binary. +hardcode_minus_L=$hardcode_minus_L + +# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR +# into the resulting binary. +hardcode_shlibpath_var=$hardcode_shlibpath_var + +# Set to "yes" if building a shared library automatically hardcodes DIR +# into the library and all subsequent libraries and executables linked +# against it. +hardcode_automatic=$hardcode_automatic + +# Set to yes if linker adds runtime paths of dependent libraries +# to runtime path list. +inherit_rpath=$inherit_rpath + +# Whether libtool must link a program against all its dependency libraries. +link_all_deplibs=$link_all_deplibs + +# Set to "yes" if exported symbols are required. +always_export_symbols=$always_export_symbols + +# The commands to list exported symbols. +export_symbols_cmds=$lt_export_symbols_cmds + +# Symbols that should not be listed in the preloaded symbols. +exclude_expsyms=$lt_exclude_expsyms + +# Symbols that must always be exported. +include_expsyms=$lt_include_expsyms + +# Commands necessary for linking programs (against libraries) with templates. +prelink_cmds=$lt_prelink_cmds + +# Commands necessary for finishing linking programs. +postlink_cmds=$lt_postlink_cmds + +# Specify filename containing input files. +file_list_spec=$lt_file_list_spec + +# How to hardcode a shared library path into an executable. +hardcode_action=$hardcode_action + +# The directories searched by this compiler when creating a shared library. +compiler_lib_search_dirs=$lt_compiler_lib_search_dirs + +# Dependencies to place before and after the objects being linked to +# create a shared library. +predep_objects=$lt_predep_objects +postdep_objects=$lt_postdep_objects +predeps=$lt_predeps +postdeps=$lt_postdeps + +# The library search path used internally by the compiler when linking +# a shared library. +compiler_lib_search_path=$lt_compiler_lib_search_path + +# ### END LIBTOOL CONFIG + +_LT_EOF + + cat <<'_LT_EOF' >> "$cfgfile" + +# ### BEGIN FUNCTIONS SHARED WITH CONFIGURE + +# func_munge_path_list VARIABLE PATH +# ----------------------------------- +# VARIABLE is name of variable containing _space_ separated list of +# directories to be munged by the contents of PATH, which is string +# having a format: +# "DIR[:DIR]:" +# string "DIR[ DIR]" will be prepended to VARIABLE +# ":DIR[:DIR]" +# string "DIR[ DIR]" will be appended to VARIABLE +# "DIRP[:DIRP]::[DIRA:]DIRA" +# string "DIRP[ DIRP]" will be prepended to VARIABLE and string +# "DIRA[ DIRA]" will be appended to VARIABLE +# "DIR[:DIR]" +# VARIABLE will be replaced by "DIR[ DIR]" +func_munge_path_list () +{ + case x$2 in + x) + ;; + *:) + eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\" + ;; + x:*) + eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\" + ;; + *::*) + eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" + eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\" + ;; + *) + eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\" + ;; + esac +} + + +# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. +func_cc_basename () +{ + for cc_temp in $*""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac + done + func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` +} + + +# ### END FUNCTIONS SHARED WITH CONFIGURE + +_LT_EOF + + case $host_os in + aix3*) + cat <<\_LT_EOF >> "$cfgfile" +# AIX sometimes has problems with the GCC collect2 program. For some +# reason, if we set the COLLECT_NAMES environment variable, the problems +# vanish in a puff of smoke. +if test set != "${COLLECT_NAMES+set}"; then + COLLECT_NAMES= + export COLLECT_NAMES +fi +_LT_EOF + ;; + esac + + +ltmain=$ac_aux_dir/ltmain.sh + + + # We use sed instead of cat because bash on DJGPP gets confused if + # if finds mixed CR/LF and LF-only lines. Since sed operates in + # text mode, it properly converts lines to CR/LF. This bash problem + # is reportedly fixed, but why not run on old versions too? + sed '$q' "$ltmain" >> "$cfgfile" \ + || (rm -f "$cfgfile"; exit 1) + + mv -f "$cfgfile" "$ofile" || + (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") + chmod +x "$ofile" + + + cat <<_LT_EOF >> "$ofile" + +# ### BEGIN LIBTOOL TAG CONFIG: CXX + +# The linker used to build libraries. +LD=$lt_LD_CXX + +# How to create reloadable object files. +reload_flag=$lt_reload_flag_CXX +reload_cmds=$lt_reload_cmds_CXX + +# Commands used to build an old-style archive. +old_archive_cmds=$lt_old_archive_cmds_CXX + +# A language specific compiler. +CC=$lt_compiler_CXX + +# Is the compiler the GNU compiler? +with_gcc=$GCC_CXX + +# Compiler flag to turn off builtin functions. +no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX + +# Additional compiler flags for building library objects. +pic_flag=$lt_lt_prog_compiler_pic_CXX + +# How to pass a linker flag through the compiler. +wl=$lt_lt_prog_compiler_wl_CXX + +# Compiler flag to prevent dynamic linking. +link_static_flag=$lt_lt_prog_compiler_static_CXX + +# Does compiler simultaneously support -c and -o options? +compiler_c_o=$lt_lt_cv_prog_compiler_c_o_CXX + +# Whether or not to add -lc for building shared libraries. +build_libtool_need_lc=$archive_cmds_need_lc_CXX + +# Whether or not to disallow shared libs when runtime libs are static. +allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_CXX + +# Compiler flag to allow reflexive dlopens. +export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_CXX + +# Compiler flag to generate shared objects directly from archives. +whole_archive_flag_spec=$lt_whole_archive_flag_spec_CXX + +# Whether the compiler copes with passing no objects directly. +compiler_needs_object=$lt_compiler_needs_object_CXX + +# Create an old-style archive from a shared archive. +old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_CXX + +# Create a temporary old-style archive to link instead of a shared archive. +old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_CXX + +# Commands used to build a shared archive. +archive_cmds=$lt_archive_cmds_CXX +archive_expsym_cmds=$lt_archive_expsym_cmds_CXX + +# Commands used to build a loadable module if different from building +# a shared archive. +module_cmds=$lt_module_cmds_CXX +module_expsym_cmds=$lt_module_expsym_cmds_CXX + +# Whether we are building with GNU ld or not. +with_gnu_ld=$lt_with_gnu_ld_CXX + +# Flag that allows shared libraries with undefined symbols to be built. +allow_undefined_flag=$lt_allow_undefined_flag_CXX + +# Flag that enforces no undefined symbols. +no_undefined_flag=$lt_no_undefined_flag_CXX + +# Flag to hardcode \$libdir into a binary during linking. +# This must work even if \$libdir does not exist +hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_CXX + +# Whether we need a single "-rpath" flag with a separated argument. +hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX + +# Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes +# DIR into the resulting binary. +hardcode_direct=$hardcode_direct_CXX + +# Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes +# DIR into the resulting binary and the resulting library dependency is +# "absolute",i.e impossible to change by setting \$shlibpath_var if the +# library is relocated. +hardcode_direct_absolute=$hardcode_direct_absolute_CXX + +# Set to "yes" if using the -LDIR flag during linking hardcodes DIR +# into the resulting binary. +hardcode_minus_L=$hardcode_minus_L_CXX + +# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR +# into the resulting binary. +hardcode_shlibpath_var=$hardcode_shlibpath_var_CXX + +# Set to "yes" if building a shared library automatically hardcodes DIR +# into the library and all subsequent libraries and executables linked +# against it. +hardcode_automatic=$hardcode_automatic_CXX + +# Set to yes if linker adds runtime paths of dependent libraries +# to runtime path list. +inherit_rpath=$inherit_rpath_CXX + +# Whether libtool must link a program against all its dependency libraries. +link_all_deplibs=$link_all_deplibs_CXX + +# Set to "yes" if exported symbols are required. +always_export_symbols=$always_export_symbols_CXX + +# The commands to list exported symbols. +export_symbols_cmds=$lt_export_symbols_cmds_CXX + +# Symbols that should not be listed in the preloaded symbols. +exclude_expsyms=$lt_exclude_expsyms_CXX + +# Symbols that must always be exported. +include_expsyms=$lt_include_expsyms_CXX + +# Commands necessary for linking programs (against libraries) with templates. +prelink_cmds=$lt_prelink_cmds_CXX + +# Commands necessary for finishing linking programs. +postlink_cmds=$lt_postlink_cmds_CXX + +# Specify filename containing input files. +file_list_spec=$lt_file_list_spec_CXX + +# How to hardcode a shared library path into an executable. +hardcode_action=$hardcode_action_CXX + +# The directories searched by this compiler when creating a shared library. +compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_CXX + +# Dependencies to place before and after the objects being linked to +# create a shared library. +predep_objects=$lt_predep_objects_CXX +postdep_objects=$lt_postdep_objects_CXX +predeps=$lt_predeps_CXX +postdeps=$lt_postdeps_CXX + +# The library search path used internally by the compiler when linking +# a shared library. +compiler_lib_search_path=$lt_compiler_lib_search_path_CXX + +# ### END LIBTOOL TAG CONFIG: CXX +_LT_EOF + + ;; + + esac +done # for ac_tag + + +as_fn_exit 0 +_ACEOF +ac_clean_files=$ac_clean_files_save + +test $ac_write_fail = 0 || + as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 + +export OU_NAMESPACE=$OU_NAMESPACE +export OU_FEATURE_SET=$OU_FEATURE_SET + +# configure is writing to config.log, and then calls config.status. +# config.status does its own redirection, appending to config.log. +# Unfortunately, on DOS this fails, as config.log is still kept open +# by configure, so config.status won't be able to write to it; its +# output is simply discarded. So we exec the FD to /dev/null, +# effectively closing config.log, so it can be properly (re)opened and +# appended to by config.status. When coming back to configure, we +# need to make the FD available again. +if test "$no_create" != yes; then + ac_cs_success=: + ac_config_status_args= + test "$silent" = yes && + ac_config_status_args="$ac_config_status_args --quiet" + exec 5>/dev/null + $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false + exec 5>>config.log + # Use ||, not &&, to avoid exiting from the if with $? = 1, which + # would make configure fail if this is the last instruction. + $ac_cs_success || as_fn_exit 1 +fi + +# +# CONFIG_SUBDIRS section. +# +if test "$no_recursion" != yes; then + + # Remove --cache-file, --srcdir, and --disable-option-checking arguments + # so they do not pile up. + ac_sub_configure_args= + ac_prev= + eval "set x $ac_configure_args" + shift + for ac_arg + do + if test -n "$ac_prev"; then + ac_prev= + continue + fi + case $ac_arg in + -cache-file | --cache-file | --cache-fil | --cache-fi \ + | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) + ac_prev=cache_file ;; + -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ + | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \ + | --c=*) + ;; + --config-cache | -C) + ;; + -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) + ac_prev=srcdir ;; + -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) + ;; + -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) + ac_prev=prefix ;; + -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) + ;; + --disable-option-checking) + ;; + *) + case $ac_arg in + *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; + esac + as_fn_append ac_sub_configure_args " '$ac_arg'" ;; + esac + done + + # Always prepend --prefix to ensure using the same prefix + # in subdir configurations. + ac_arg="--prefix=$prefix" + case $ac_arg in + *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; + esac + ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args" + + # Pass --silent + if test "$silent" = yes; then + ac_sub_configure_args="--silent $ac_sub_configure_args" + fi + + # Always prepend --disable-option-checking to silence warnings, since + # different subdirs can have different --enable and --with options. + ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args" + + ac_popdir=`pwd` + for ac_dir in : $subdirs; do test "x$ac_dir" = x: && continue + + # Do not complain, so a configure script can configure whichever + # parts of a large source tree are present. + test -d "$srcdir/$ac_dir" || continue + + ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)" + $as_echo "$as_me:${as_lineno-$LINENO}: $ac_msg" >&5 + $as_echo "$ac_msg" >&6 + as_dir="$ac_dir"; as_fn_mkdir_p + ac_builddir=. + +case "$ac_dir" in +.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; +*) + ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` + # A ".." for each directory in $ac_dir_suffix. + ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` + case $ac_top_builddir_sub in + "") ac_top_builddir_sub=. ac_top_build_prefix= ;; + *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; + esac ;; +esac +ac_abs_top_builddir=$ac_pwd +ac_abs_builddir=$ac_pwd$ac_dir_suffix +# for backward compatibility: +ac_top_builddir=$ac_top_build_prefix + +case $srcdir in + .) # We are building in place. + ac_srcdir=. + ac_top_srcdir=$ac_top_builddir_sub + ac_abs_top_srcdir=$ac_pwd ;; + [\\/]* | ?:[\\/]* ) # Absolute name. + ac_srcdir=$srcdir$ac_dir_suffix; + ac_top_srcdir=$srcdir + ac_abs_top_srcdir=$srcdir ;; + *) # Relative name. + ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix + ac_top_srcdir=$ac_top_build_prefix$srcdir + ac_abs_top_srcdir=$ac_pwd/$srcdir ;; +esac +ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix + + + cd "$ac_dir" + + # Check for guested configure; otherwise get Cygnus style configure. + if test -f "$ac_srcdir/configure.gnu"; then + ac_sub_configure=$ac_srcdir/configure.gnu + elif test -f "$ac_srcdir/configure"; then + ac_sub_configure=$ac_srcdir/configure + elif test -f "$ac_srcdir/configure.in"; then + # This should be Cygnus configure. + ac_sub_configure=$ac_aux_dir/configure + else + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no configuration information is in $ac_dir" >&5 +$as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;} + ac_sub_configure= + fi + + # The recursion is here. + if test -n "$ac_sub_configure"; then + # Make the cache file name correct relative to the subdirectory. + case $cache_file in + [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;; + *) # Relative name. + ac_sub_cache_file=$ac_top_build_prefix$cache_file ;; + esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&5 +$as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;} + # The eval makes quoting arguments work. + eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \ + --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" || + as_fn_error $? "$ac_sub_configure failed for $ac_dir" "$LINENO" 5 + fi + + cd "$ac_popdir" + done +fi +if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 +$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} +fi + + +chmod +x ode-config + +BUILDDIR=`pwd` + +echo "Configuration:" +echo " Build system type: $build" +echo " Host system type: $host" +echo " Use double precision: $usedouble" +echo " Use drawstuff: $drawstuff" +echo " Demos enabled: $enable_demos" +echo " Use OPCODE: $opcode" +echo " Use GIMPACT: $gimpact" +echo " Use libccd: $use_libccd" + +if test x$use_libccd = xyes +then +echo " libccd source: $libccd_source" +fi + +echo " Custom colliders:" +echo " cylinder-cylinder: $col_cylinder_cylinder" +echo " box-cylinder: $col_box_cylinder" +echo " capsule-cylinder: $col_capsule_cylinder" +echo " convex-box: $col_convex_box" +echo " convex-capsule: $col_convex_capsule" +echo " convex-cylinder: $col_convex_cylinder" +echo " convex-sphere: $col_convex_sphere" +echo " convex-convex: $col_convex_convex" +echo " Is target a Pentium: $pentium" +echo " Is target x86-64: $cpu64" +echo " Use old opcode trimesh collider: $old_trimesh" +echo " TLS for global caches: $use_ou_tls" +echo " Threading intf enabled: $threading_intf" +echo " Built-in threading included: $use_builtin_threading_impl" +echo " Enable debug error check: $asserts" +echo " Headers will be installed in $includedir/ode" +echo " Libraries will be installed in $libdir" +echo " Building in directory $BUILDDIR" + diff --git a/libs/ode-0.16.1/configure.ac b/libs/ode-0.16.1/configure.ac new file mode 100644 index 0000000..6ea9e7c --- /dev/null +++ b/libs/ode-0.16.1/configure.ac @@ -0,0 +1,605 @@ +dnl AC_INIT does not take a macro as a version nr: set it separately! - Bram +AC_INIT([ODE],[0.16.1],[ode@ode.org]) +ODE_VERSION=0.16.1 +AC_SUBST(ODE_VERSION) + +# Those are instructions from the Libtool manual: +# 1. Start with version information of `0:0:0' for each libtool library. +# +# 2. Update the version information only immediately before a public +# release of your software. More frequent updates are unnecessary, +# and only guarantee that the current interface number gets larger +# faster. +# +# 3. If the library source code has changed at all since the last +# update, then increment REVISION (`C:R:A' becomes `C:r+1:A'). +# +# 4. If any interfaces have been added, removed, or changed since the +# last update, increment CURRENT, and set REVISION to 0. +# +# 5. If any interfaces have been added since the last public release, +# then increment AGE. +# +# 6. If any interfaces have been removed since the last public release, +# then set AGE to 0. +CURRENT=8 +REVISION=1 +AGE=0 + +AC_ARG_ENABLE(version-info, + AS_HELP_STRING([--disable-version-info], + [don't encode version information in the generated library]), + version_info=$enableval, + version_info=yes) +if test x$version_info = xyes +then + ODE_VERSION_INFO="-version-info $CURRENT:$REVISION:$AGE" +else + ODE_VERSION_INFO="-avoid-version" +fi +AC_SUBST(ODE_VERSION_INFO) + + +AC_CONFIG_SRCDIR([ode/src/ode.cpp]) +AC_CONFIG_MACRO_DIR([m4]) + +AC_CANONICAL_HOST + +AM_INIT_AUTOMAKE([1.10 foreign]) +AC_CONFIG_HEADERS([ode/src/config.h]) + +dnl This is needed because we have subdirectories +AC_PROG_MAKE_SET +AC_PROG_CXX +AC_PROG_CC +AM_PROG_CC_C_O +AC_PROG_CPP +AC_PROG_AWK +AC_PROG_INSTALL +AC_PROG_LN_S +AC_PROG_MKDIR_P +LT_INIT([disable-shared win32-dll]) +AC_CHECK_TOOLS([WINDRES], [windres]) + +AC_C_BIGENDIAN +AC_C_INLINE +AC_C_VOLATILE +PKG_PROG_PKG_CONFIG + +AC_ARG_VAR([DOXYGEN], [set to doxygen binary to generate doxygen docs]) +AC_CHECK_PROGS([DOXYGEN], [doxygen]) +AM_CONDITIONAL([HAVE_DOXYGEN], [test x$DOXYGEN = xdoxygen]) + + +dnl this may NOT be the machine on which the code is going to run in, +dnl so allow users to compile programs for their target machine. +pentium=no +cpu64=no +case "$host_cpu" in + i586 | i686 | i786 ) + pentium=yes + AC_DEFINE(PENTIUM,1,[compiling for a pentium on a gcc-based platform?]) + ;; + x86_64* ) + pentium=yes + cpu64=yes + AC_DEFINE(X86_64_SYSTEM,1,[compiling for a X86_64 system on a gcc-based platform?]) + ;; +esac + +AM_CONDITIONAL(X86_64_SYSTEM, test x$cpu64 = xyes) + + + + + + +dnl check for required headers +AC_CHECK_HEADERS( [alloca.h stdio.h inttypes.h stdint.h stdlib.h math.h \ + string.h stdarg.h malloc.h float.h time.h sys/time.h \ + limits.h stddef.h]) + + +opcode=no +gimpact=no +AC_ARG_WITH(trimesh, AS_HELP_STRING([--with-trimesh=@<:@opcode|gimpact|none@:>@], + [use the specified system for trimesh support @<:@default=opcode@:>@]), + trimesh=$withval,trimesh=opcode +) +if test "$trimesh" = opcode +then + opcode=yes +fi +if test "$trimesh" = gimpact +then + gimpact=yes +fi + +AM_CONDITIONAL(OPCODE, test $opcode = yes) +AM_CONDITIONAL(GIMPACT, test $gimpact = yes) +AM_CONDITIONAL(TRIMESH, test $opcode = yes -o $gimpact = yes) + + +AC_MSG_CHECKING(if double precision is requested) +AC_ARG_ENABLE(double-precision, + AS_HELP_STRING([--enable-double-precision], + [Configure ODE to work with double precision, if not specified, single precision is used @<:@default=no@:>@]), + usedouble=$enableval,usedouble=no) +AC_MSG_RESULT([$usedouble]) +if test "$usedouble" = yes; +then + ODE_PRECISION=dDOUBLE +else + ODE_PRECISION=dSINGLE +fi +AC_SUBST(ODE_PRECISION) + + +AC_ARG_WITH([drawstuff], + AS_HELP_STRING([--with-drawstuff=X11|Win32|OSX|none], + [force a particular drawstuff implementation or disable it.[default=autodetect]]), + [drawstuff=$withval],[drawstuff=]) + +dnl Set some Platform Specific Variables +EXTRA_LIBTOOL_LDFLAGS= +case "$host_os" in + cygwin* | mingw*) + if test "x$drawstuff" = x + then + drawstuff="Win32" # if in a Windows enviroment + fi + EXTRA_LIBTOOL_LDFLAGS="-no-undefined" + ;; + *apple* | *darwin*) # For Mac OS X + if test "x$drawstuff" = x + then + drawstuff="OSX" + fi + dnl We need to use C++ compilation and linking for ode on Mac + dnl Might as well do it for all code. + CC="$CXX" + LINK="$CXXLINK" + ;; + *) + if test "x$drawstuff" = x + then + drawstuff="X11" # if anything else default to X11 + fi + ;; +esac +AC_SUBST(EXTRA_LIBTOOL_LDFLAGS) + + +dnl Set Drawstuff variables +AC_MSG_CHECKING([which drawstuff lib to build]) +AC_MSG_RESULT($drawstuff) + +if test "x$drawstuff" = "xX11" +then + # The built-in macro, X_PATH, causes too many problems, these days everyone uses Xorg, + # so we can ask pkg-config to find it for us. + PKG_CHECK_MODULES(X11, x11, [], [drawstuff="none"]) +fi + +dnl Check for OpenGL +if test "x$drawstuff" = "xOSX"; then + AC_DEFINE([HAVE_APPLE_OPENGL_FRAMEWORK], [1], + [Use the Apple OpenGL framework.]) + GL_LIBS="-framework OpenGL -framework GLUT" +elif test "x$drawstuff" != "xnone"; then + have_gl_headers=yes + AC_CHECK_HEADERS(GL/gl.h GL/glu.h GL/glext.h, , + [have_gl_headers=no], + [[#ifdef WIN32 + #include + #endif + #if HAVE_GL_GL_H + #include + #endif + #if HAVE_GL_GLU_H + #include + #endif + ]]) + have_gl=no + have_glu=no + TEMP_LDFLAGS="$LDFLAGS" + AC_CHECK_LIB(GL, main, [GL_LIBS="-lGL"; have_gl=yes]) + AC_CHECK_LIB(GLU, main, [GL_LIBS="-lGLU $GL_LIBS"; have_glu=yes], , -lGL) + AC_CHECK_LIB(opengl32, main, [GL_LIBS="-lopengl32"; have_gl=yes]) + AC_CHECK_LIB(glu32, main, [GL_LIBS="-lglu32 $GL_LIBS"; have_glu=yes], , -lopengl32) + LDFLAGS="$TEMP_LDFLAGS" + if test $have_gl = no -o $have_glu = no -o $have_gl_headers = no; then + drawstuff="none" + fi +fi +AC_SUBST(GL_LIBS) + +dnl Set Conditionals +AM_CONDITIONAL(WIN32, test x$drawstuff = xWin32) +AM_CONDITIONAL(X11, test x$drawstuff = xX11) +AM_CONDITIONAL(OSX, test x$drawstuff = xOSX) +AM_CONDITIONAL(ENABLE_DRAWSTUFF, test x$drawstuff != xnone) + +dnl Check if we want to build demos +AC_MSG_CHECKING(if demos should be built) +AC_ARG_ENABLE(demos, + AS_HELP_STRING([--disable-demos], [don't build demos]), + enable_demos=$enableval,enable_demos=yes) +if test x$drawstuff = xnone -a x$enable_demos = xyes ; then + enable_demos=no + AC_MSG_RESULT($enable_demos) + AC_MSG_WARN([Demos will not be built because OpenGL doesn't seem to work. See `config.log' for details.]) +else + AC_MSG_RESULT($enable_demos) +fi + + +dnl stdc++ is required when linking C programs against ode +AC_CHECK_LIB(stdc++,main,[LIBSTDCXX="-lstdc++"],[LIBSTDCXX=]) +AC_SUBST(LIBSTDCXX) +AC_CHECK_LIB(pthread,main,[LIBS="$LIBS -lpthread"]) + + +dnl test if we will build demos +AM_CONDITIONAL(ENABLE_DEMOS, test x$enable_demos = xyes) + + +dnl Check if the user wants the old timesh collider +old_trimesh=no +AC_ARG_ENABLE([old-trimesh], AS_HELP_STRING([--enable-old-trimesh],[enable use of the old trimesh collider]), + [old_trimesh=$enableval] + ) +if test x$old_trimesh = xyes -a $trimesh = opcode; then + AC_DEFINE(dTRIMESH_OPCODE_USE_OLD_TRIMESH_TRIMESH_COLLIDER, 1, + [Use the old trimesh-trimesh collider]) +else + old_trimesh=no +fi + + +dnl Check if the user wants to profile ODE using gprof +AC_MSG_CHECKING(for gprof) +AC_ARG_ENABLE([gprof], + AS_HELP_STRING([--enable-gprof],[enable profiling with gprof]), + gprof=$enableval, + gprof=no) +if test "$gprof" != no +then + CFLAGS="-pg $CFLAGS" + CXXFLAGS="-pg $CXXFLAGS" + AC_MSG_RESULT(enabled) + AC_CHECK_LIB(gmon, main,[LIBS="$LIBS -lgmon"]) +else + AC_MSG_RESULT(no) +fi + +# Checks for typedefs, structures, and compiler characteristics. +AC_HEADER_STDBOOL +AC_C_INLINE +AC_TYPE_INT32_T +AC_FUNC_OBSTACK +AC_TYPE_SIZE_T +AC_TYPE_UINT32_T + +dnl Check for autoscan sugested functions +AC_CHECK_LIB(m, [main]) +AC_CHECK_LIB(sunmath, [main]) +AC_CHECK_LIB(rt, [main]) +AC_CHECK_FUNCS([atan2f clock_gettime copysign copysignf cosf fabsf floor fmodf gettimeofday isnan _isnan __isnan isnanf _isnanf __isnanf memmove memset pthread_attr_setstacklazy pthread_attr_setinheritsched pthread_condattr_setclock sinf snprintf sqrt sqrtf strchr strstr vsnprintf]) +AC_FUNC_ALLOCA + +dnl This trick allows having additional define in case if a function is not found. +dnl It fakes cached value for an inexistent function which is then used to fool function check to produce desired result. +AC_CHECK_FUNC(pthread_condattr_setclock,,ac_cv_func_no_pthread_condattr_setclock=yes) +AC_CHECK_FUNCS(no_pthread_condattr_setclock) + + +AC_ARG_ENABLE([threading-intf], + AS_HELP_STRING([--disable-threading-intf], + [disable threading interface support (external implementations cannot be assigned)] + ), + threading_intf=$enableval,threading_intf=yes) +AC_ARG_ENABLE([ou], + AS_HELP_STRING([--enable-ou], + [use TLS for global caches (allows threaded collision checks for isolated spaces)] + ), + use_ou_tls=$enableval,use_ou_tls=no) +use_ou="no" +if test x$use_ou_tls = xyes -o x$threading_intf = xyes +then + use_ou="yes" +fi + +OU_NAMESPACE=odeou +AC_CONFIG_COMMANDS_POST([export OU_NAMESPACE=$OU_NAMESPACE]) +AC_DEFINE([_OU_NAMESPACE],[odeou],[libou namespace for ODE]) +AC_DEFINE([dOU_ENABLED],[1],[Generic OU features are enabled]) + +if test x$use_ou_tls = xyes +then + OU_FEATURE_SET=_OU_FEATURE_SET_TLS + AC_DEFINE([_OU_FEATURE_SET],[_OU_FEATURE_SET_TLS],[OU features enabled]) +elif test x$use_ou = xyes +then + OU_FEATURE_SET=_OU_FEATURE_SET_ATOMICS + AC_DEFINE([_OU_FEATURE_SET],[_OU_FEATURE_SET_ATOMICS],[OU features enabled]) +else + OU_FEATURE_SET=_OU_FEATURE_SET_BASICS + AC_DEFINE([_OU_FEATURE_SET],[_OU_FEATURE_SET_BASICS],[OU features enabled]) +fi +AC_CONFIG_COMMANDS_POST([export OU_FEATURE_SET=$OU_FEATURE_SET]) + +if test x$use_ou = xyes +then + AC_DEFINE([dATOMICS_ENABLED],[1],[Atomic API of OU is enabled]) + if test x$use_ou_tls = xyes + then + AC_DEFINE([dTLS_ENABLED],[1],[Thread Local Storage API of OU is enabled]) + fi +fi + +case "$host_os" in + cygwin* | mingw*) + targetos=_OU_TARGET_OS_WINDOWS + ;; + *qnx*) + targetos=_OU_TARGET_OS_QNX + ;; + *apple* | *darwin*) + targetos=_OU_TARGET_OS_MAC + ;; + *sunos*) + targetos=_OU_TARGET_OS_SUNOS + ;; + *aix*) + targetos=_OU_TARGET_OS_AIX + ;; + *) + targetos=_OU_TARGET_OS_GENUNIX + ;; +esac + +if test $targetos = _OU_TARGET_OS_MAC +then + MAC_OS_X_VERSION=1000 + AC_CHECK_FUNC([OSAtomicAdd32Barrier], [MAC_OS_X_VERSION=1040]) + AC_CHECK_FUNC([OSAtomicAnd32OrigBarrier], [MAC_OS_X_VERSION=1050]) + AC_DEFINE_UNQUOTED(MAC_OS_X_VERSION, $MAC_OS_X_VERSION, [Mac OS X version setting for OU Library]) +fi + +if test $targetos = _OU_TARGET_OS_SUNOS +then + AC_CHECK_FUNC(atomic_inc_32_nv, [], + [targetos=_OU_TARGET_OS_GENUNIX]) +fi + +AC_DEFINE_UNQUOTED(_OU_TARGET_OS, $targetos, [Target OS setting for OU Library]) + +AC_CONFIG_SUBDIRS([ou]) +AM_CONDITIONAL(ENABLE_OU, true) + +if test x$threading_intf = xyes +then + AC_ARG_ENABLE([builtin-threading-impl], + AS_HELP_STRING([--disable-builtin-threading-impl], + [disable built-in multithreaded threading implementation] + ), + use_builtin_threading_impl=$enableval,use_builtin_threading_impl=yes) + if test x$use_builtin_threading_impl = xyes + then + AC_DEFINE([dBUILTIN_THREADING_IMPL_ENABLED],[1],[Built-in multithreaded threading implementation is included]) + fi +else + AC_DEFINE([dTHREADING_INTF_DISABLED],[1],[Threading interface is disabled]) + use_builtin_threading_impl=no +fi + +col_cylinder_cylinder=none +col_box_cylinder=default +col_capsule_cylinder=none +col_convex_box=none +col_convex_capsule=none +col_convex_cylinder=none +col_convex_sphere=default +col_convex_convex=default + + +use_libccd=no +libccd_all=no +AC_ARG_ENABLE(libccd, AS_HELP_STRING([--enable-libccd], + [enable all libccd colliders (except box-cylinder)]), + libccd_all=$enableval) +if test x$libccd_all = xyes +then + col_cylinder_cylinder=libccd + col_capsule_cylinder=libccd + col_convex_box=libccd + col_convex_capsule=libccd + col_convex_cylinder=libccd + col_convex_sphere=libccd + col_convex_convex=libccd + use_libccd=yes +fi + + +AC_ARG_WITH([cylinder-cylinder], AS_HELP_STRING([--with-cylinder-cylinder=@<:@none,libccd@:>@], [use specific collider for cylinder-cylinder]), + col_cylinder_cylinder=$withval) + +AC_ARG_WITH([box-cylinder], + AS_HELP_STRING([--with-box-cylinder=@<:@default,libccd@:>@], [use specific collider for box-cylinder]), + col_box_cylinder=$withval) + +AC_ARG_WITH([capsule-cylinder], AS_HELP_STRING([--with-capsule-cylinder=@<:@none,libccd@:>@], [use specific collider for capsule-cylinder]), + col_capsule_cylinder=$withval) + +AC_ARG_WITH([convex-box], AS_HELP_STRING([--with-convex-box=@<:@none,libccd@:>@], [use specific collider for convex-box]), + col_convex_box=$withval) + +AC_ARG_WITH([convex-capsule], AS_HELP_STRING([--with-convex-capsule=@<:@none,libccd@:>@], [use specific collider for convex-capsule]), + col_convex_capsule=$withval) + +AC_ARG_WITH([convex-cylinder], AS_HELP_STRING([--with-convex-cylinder=@<:@none,libccd@:>@], [use specific collider for convex-cylinder]), + col_convex_cylinder=$withval) + +AC_ARG_WITH([convex-sphere], AS_HELP_STRING([--with-convex-sphere=@<:@default,libccd@:>@], [use specific collider for convex-sphere]), + col_convex_sphere=$withval) + +AC_ARG_WITH([convex-convex], AS_HELP_STRING([--with-convex-convex=@<:@default,libccd@:>@], [use specific collider for convex-convex]), + col_convex_convex=$withval) + +if test x$col_cylinder_cylinder = xlibccd -o \ + x$col_box_cylinder = xlibccd -o \ + x$col_capsule_cylinder = xlibccd -o \ + x$col_convex_box = xlibccd -o \ + x$col_convex_capsule = libccd -o \ + x$col_convex_cylinder = xlibccd -o \ + x$col_convex_sphere = libccd -o \ + x$col_convex_convex = libccd +then + use_libccd=yes +fi + + +libccd_source=internal + +AC_ARG_WITH(libccd, + [AS_HELP_STRING([--with-libccd=@<:@internal|system@:>@], + [use the specified libccd @<:@default=system@:>@])], + [libccd_source=$withval], + [libccd_source=system]) + +if test x$use_libccd = xyes +then + if test x$libccd_source = xsystem + then + PKG_CHECK_MODULES(CCD, ccd, ,[libccd_source=internal]) + fi +fi + +# Configure libccd unconditionally as that may be needed for special make targets +AC_CONFIG_SUBDIRS([libccd]) + +AM_CONDITIONAL(LIBCCD, test x$use_libccd != xno) +AM_CONDITIONAL(LIBCCD_INTERNAL, test x$libccd_source = xinternal) +AM_CONDITIONAL(LIBCCD_BOX_CYL, test x$col_box_cylinder = xlibccd) +AM_CONDITIONAL(LIBCCD_CYL_CYL, test x$col_cylinder_cylinder = xlibccd) +AM_CONDITIONAL(LIBCCD_CAP_CYL, test x$col_capsule_cylinder = xlibccd) +AM_CONDITIONAL(LIBCCD_CONVEX_BOX, test x$col_convex_box = xlibccd) +AM_CONDITIONAL(LIBCCD_CONVEX_CAP, test x$col_convex_capsule = xlibccd) +AM_CONDITIONAL(LIBCCD_CONVEX_CYL, test x$col_convex_cylinder = xlibccd) +AM_CONDITIONAL(LIBCCD_CONVEX_SPHERE, test x$col_convex_sphere = xlibccd) +AM_CONDITIONAL(LIBCCD_CONVEX_CONVEX, test x$col_convex_convex = xlibccd) + + + +AC_ARG_ENABLE([asserts], + AS_HELP_STRING([--disable-asserts], + [disables debug error checking]), + asserts=$enableval,asserts=yes) +if test x$asserts = xno +then + CPPFLAGS="$CPPFLAGS -DdNODEBUG -DNDEBUG" +fi + + +dnl include found system headers into config.h +AH_TOP([ +#ifndef ODE_CONFIG_H +#define ODE_CONFIG_H +]) +AH_BOTTOM([ + +#ifdef HAVE_ALLOCA_H +#include +#endif +#ifdef HAVE_MALLOC_H +#include +#endif +#ifdef HAVE_STDINT_H +#include +#endif +#ifdef HAVE_INTTYPES_H +#include +#endif + + +#include "typedefs.h" + + +#endif /* #define ODE_CONFIG_H */ +]) + +dnl Finally write our Makefiles +AC_CONFIG_FILES([ + Makefile + drawstuff/Makefile + drawstuff/src/Makefile + drawstuff/dstest/Makefile + include/Makefile + include/drawstuff/Makefile + include/ode/Makefile + include/ode/version.h + include/ode/precision.h + ode/Makefile + ode/doc/Doxyfile + ode/doc/Makefile + ode/src/Makefile + ode/src/joints/Makefile + ode/demo/Makefile + OPCODE/Makefile + OPCODE/Ice/Makefile + GIMPACT/Makefile + GIMPACT/include/Makefile + GIMPACT/include/GIMPACT/Makefile + GIMPACT/src/Makefile + tests/Makefile + tests/joints/Makefile + tests/UnitTest++/Makefile + tests/UnitTest++/src/Makefile + tests/UnitTest++/src/Posix/Makefile + tests/UnitTest++/src/Win32/Makefile + ode-config + ode.pc + ]) +AC_OUTPUT + +chmod +x ode-config + +BUILDDIR=`pwd` + +dnl Print some useful information +echo "Configuration:" +echo " Build system type: $build" +echo " Host system type: $host" +echo " Use double precision: $usedouble" +echo " Use drawstuff: $drawstuff" +echo " Demos enabled: $enable_demos" +echo " Use OPCODE: $opcode" +echo " Use GIMPACT: $gimpact" +echo " Use libccd: $use_libccd" + +if test x$use_libccd = xyes +then +echo " libccd source: $libccd_source" +fi + +echo " Custom colliders:" +echo " cylinder-cylinder: $col_cylinder_cylinder" +echo " box-cylinder: $col_box_cylinder" +echo " capsule-cylinder: $col_capsule_cylinder" +echo " convex-box: $col_convex_box" +echo " convex-capsule: $col_convex_capsule" +echo " convex-cylinder: $col_convex_cylinder" +echo " convex-sphere: $col_convex_sphere" +echo " convex-convex: $col_convex_convex" +echo " Is target a Pentium: $pentium" +echo " Is target x86-64: $cpu64" +echo " Use old opcode trimesh collider: $old_trimesh" +echo " TLS for global caches: $use_ou_tls" +echo " Threading intf enabled: $threading_intf" +echo " Built-in threading included: $use_builtin_threading_impl" +echo " Enable debug error check: $asserts" +echo " Headers will be installed in $includedir/ode" +echo " Libraries will be installed in $libdir" +echo " Building in directory $BUILDDIR" + diff --git a/libs/ode-0.16.1/depcomp b/libs/ode-0.16.1/depcomp new file mode 100755 index 0000000..fc98710 --- /dev/null +++ b/libs/ode-0.16.1/depcomp @@ -0,0 +1,791 @@ +#! /bin/sh +# depcomp - compile a program generating dependencies as side-effects + +scriptversion=2013-05-30.07; # UTC + +# Copyright (C) 1999-2014 Free Software Foundation, Inc. + +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. + +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. + +# Originally written by Alexandre Oliva . + +case $1 in + '') + echo "$0: No command. Try '$0 --help' for more information." 1>&2 + exit 1; + ;; + -h | --h*) + cat <<\EOF +Usage: depcomp [--help] [--version] PROGRAM [ARGS] + +Run PROGRAMS ARGS to compile a file, generating dependencies +as side-effects. + +Environment variables: + depmode Dependency tracking mode. + source Source file read by 'PROGRAMS ARGS'. + object Object file output by 'PROGRAMS ARGS'. + DEPDIR directory where to store dependencies. + depfile Dependency file to output. + tmpdepfile Temporary file to use when outputting dependencies. + libtool Whether libtool is used (yes/no). + +Report bugs to . +EOF + exit $? + ;; + -v | --v*) + echo "depcomp $scriptversion" + exit $? + ;; +esac + +# Get the directory component of the given path, and save it in the +# global variables '$dir'. Note that this directory component will +# be either empty or ending with a '/' character. This is deliberate. +set_dir_from () +{ + case $1 in + */*) dir=`echo "$1" | sed -e 's|/[^/]*$|/|'`;; + *) dir=;; + esac +} + +# Get the suffix-stripped basename of the given path, and save it the +# global variable '$base'. +set_base_from () +{ + base=`echo "$1" | sed -e 's|^.*/||' -e 's/\.[^.]*$//'` +} + +# If no dependency file was actually created by the compiler invocation, +# we still have to create a dummy depfile, to avoid errors with the +# Makefile "include basename.Plo" scheme. +make_dummy_depfile () +{ + echo "#dummy" > "$depfile" +} + +# Factor out some common post-processing of the generated depfile. +# Requires the auxiliary global variable '$tmpdepfile' to be set. +aix_post_process_depfile () +{ + # If the compiler actually managed to produce a dependency file, + # post-process it. + if test -f "$tmpdepfile"; then + # Each line is of the form 'foo.o: dependency.h'. + # Do two passes, one to just change these to + # $object: dependency.h + # and one to simply output + # dependency.h: + # which is needed to avoid the deleted-header problem. + { sed -e "s,^.*\.[$lower]*:,$object:," < "$tmpdepfile" + sed -e "s,^.*\.[$lower]*:[$tab ]*,," -e 's,$,:,' < "$tmpdepfile" + } > "$depfile" + rm -f "$tmpdepfile" + else + make_dummy_depfile + fi +} + +# A tabulation character. +tab=' ' +# A newline character. +nl=' +' +# Character ranges might be problematic outside the C locale. +# These definitions help. +upper=ABCDEFGHIJKLMNOPQRSTUVWXYZ +lower=abcdefghijklmnopqrstuvwxyz +digits=0123456789 +alpha=${upper}${lower} + +if test -z "$depmode" || test -z "$source" || test -z "$object"; then + echo "depcomp: Variables source, object and depmode must be set" 1>&2 + exit 1 +fi + +# Dependencies for sub/bar.o or sub/bar.obj go into sub/.deps/bar.Po. +depfile=${depfile-`echo "$object" | + sed 's|[^\\/]*$|'${DEPDIR-.deps}'/&|;s|\.\([^.]*\)$|.P\1|;s|Pobj$|Po|'`} +tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`} + +rm -f "$tmpdepfile" + +# Avoid interferences from the environment. +gccflag= dashmflag= + +# Some modes work just like other modes, but use different flags. We +# parameterize here, but still list the modes in the big case below, +# to make depend.m4 easier to write. Note that we *cannot* use a case +# here, because this file can only contain one case statement. +if test "$depmode" = hp; then + # HP compiler uses -M and no extra arg. + gccflag=-M + depmode=gcc +fi + +if test "$depmode" = dashXmstdout; then + # This is just like dashmstdout with a different argument. + dashmflag=-xM + depmode=dashmstdout +fi + +cygpath_u="cygpath -u -f -" +if test "$depmode" = msvcmsys; then + # This is just like msvisualcpp but w/o cygpath translation. + # Just convert the backslash-escaped backslashes to single forward + # slashes to satisfy depend.m4 + cygpath_u='sed s,\\\\,/,g' + depmode=msvisualcpp +fi + +if test "$depmode" = msvc7msys; then + # This is just like msvc7 but w/o cygpath translation. + # Just convert the backslash-escaped backslashes to single forward + # slashes to satisfy depend.m4 + cygpath_u='sed s,\\\\,/,g' + depmode=msvc7 +fi + +if test "$depmode" = xlc; then + # IBM C/C++ Compilers xlc/xlC can output gcc-like dependency information. + gccflag=-qmakedep=gcc,-MF + depmode=gcc +fi + +case "$depmode" in +gcc3) +## gcc 3 implements dependency tracking that does exactly what +## we want. Yay! Note: for some reason libtool 1.4 doesn't like +## it if -MD -MP comes after the -MF stuff. Hmm. +## Unfortunately, FreeBSD c89 acceptance of flags depends upon +## the command line argument order; so add the flags where they +## appear in depend2.am. Note that the slowdown incurred here +## affects only configure: in makefiles, %FASTDEP% shortcuts this. + for arg + do + case $arg in + -c) set fnord "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" "$arg" ;; + *) set fnord "$@" "$arg" ;; + esac + shift # fnord + shift # $arg + done + "$@" + stat=$? + if test $stat -ne 0; then + rm -f "$tmpdepfile" + exit $stat + fi + mv "$tmpdepfile" "$depfile" + ;; + +gcc) +## Note that this doesn't just cater to obsosete pre-3.x GCC compilers. +## but also to in-use compilers like IMB xlc/xlC and the HP C compiler. +## (see the conditional assignment to $gccflag above). +## There are various ways to get dependency output from gcc. Here's +## why we pick this rather obscure method: +## - Don't want to use -MD because we'd like the dependencies to end +## up in a subdir. Having to rename by hand is ugly. +## (We might end up doing this anyway to support other compilers.) +## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like +## -MM, not -M (despite what the docs say). Also, it might not be +## supported by the other compilers which use the 'gcc' depmode. +## - Using -M directly means running the compiler twice (even worse +## than renaming). + if test -z "$gccflag"; then + gccflag=-MD, + fi + "$@" -Wp,"$gccflag$tmpdepfile" + stat=$? + if test $stat -ne 0; then + rm -f "$tmpdepfile" + exit $stat + fi + rm -f "$depfile" + echo "$object : \\" > "$depfile" + # The second -e expression handles DOS-style file names with drive + # letters. + sed -e 's/^[^:]*: / /' \ + -e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile" +## This next piece of magic avoids the "deleted header file" problem. +## The problem is that when a header file which appears in a .P file +## is deleted, the dependency causes make to die (because there is +## typically no way to rebuild the header). We avoid this by adding +## dummy dependencies for each header file. Too bad gcc doesn't do +## this for us directly. +## Some versions of gcc put a space before the ':'. On the theory +## that the space means something, we add a space to the output as +## well. hp depmode also adds that space, but also prefixes the VPATH +## to the object. Take care to not repeat it in the output. +## Some versions of the HPUX 10.20 sed can't process this invocation +## correctly. Breaking it into two sed invocations is a workaround. + tr ' ' "$nl" < "$tmpdepfile" \ + | sed -e 's/^\\$//' -e '/^$/d' -e "s|.*$object$||" -e '/:$/d' \ + | sed -e 's/$/ :/' >> "$depfile" + rm -f "$tmpdepfile" + ;; + +hp) + # This case exists only to let depend.m4 do its work. It works by + # looking at the text of this script. This case will never be run, + # since it is checked for above. + exit 1 + ;; + +sgi) + if test "$libtool" = yes; then + "$@" "-Wp,-MDupdate,$tmpdepfile" + else + "$@" -MDupdate "$tmpdepfile" + fi + stat=$? + if test $stat -ne 0; then + rm -f "$tmpdepfile" + exit $stat + fi + rm -f "$depfile" + + if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files + echo "$object : \\" > "$depfile" + # Clip off the initial element (the dependent). Don't try to be + # clever and replace this with sed code, as IRIX sed won't handle + # lines with more than a fixed number of characters (4096 in + # IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines; + # the IRIX cc adds comments like '#:fec' to the end of the + # dependency line. + tr ' ' "$nl" < "$tmpdepfile" \ + | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' \ + | tr "$nl" ' ' >> "$depfile" + echo >> "$depfile" + # The second pass generates a dummy entry for each header file. + tr ' ' "$nl" < "$tmpdepfile" \ + | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \ + >> "$depfile" + else + make_dummy_depfile + fi + rm -f "$tmpdepfile" + ;; + +xlc) + # This case exists only to let depend.m4 do its work. It works by + # looking at the text of this script. This case will never be run, + # since it is checked for above. + exit 1 + ;; + +aix) + # The C for AIX Compiler uses -M and outputs the dependencies + # in a .u file. In older versions, this file always lives in the + # current directory. Also, the AIX compiler puts '$object:' at the + # start of each line; $object doesn't have directory information. + # Version 6 uses the directory in both cases. + set_dir_from "$object" + set_base_from "$object" + if test "$libtool" = yes; then + tmpdepfile1=$dir$base.u + tmpdepfile2=$base.u + tmpdepfile3=$dir.libs/$base.u + "$@" -Wc,-M + else + tmpdepfile1=$dir$base.u + tmpdepfile2=$dir$base.u + tmpdepfile3=$dir$base.u + "$@" -M + fi + stat=$? + if test $stat -ne 0; then + rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" + exit $stat + fi + + for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" + do + test -f "$tmpdepfile" && break + done + aix_post_process_depfile + ;; + +tcc) + # tcc (Tiny C Compiler) understand '-MD -MF file' since version 0.9.26 + # FIXME: That version still under development at the moment of writing. + # Make that this statement remains true also for stable, released + # versions. + # It will wrap lines (doesn't matter whether long or short) with a + # trailing '\', as in: + # + # foo.o : \ + # foo.c \ + # foo.h \ + # + # It will put a trailing '\' even on the last line, and will use leading + # spaces rather than leading tabs (at least since its commit 0394caf7 + # "Emit spaces for -MD"). + "$@" -MD -MF "$tmpdepfile" + stat=$? + if test $stat -ne 0; then + rm -f "$tmpdepfile" + exit $stat + fi + rm -f "$depfile" + # Each non-empty line is of the form 'foo.o : \' or ' dep.h \'. + # We have to change lines of the first kind to '$object: \'. + sed -e "s|.*:|$object :|" < "$tmpdepfile" > "$depfile" + # And for each line of the second kind, we have to emit a 'dep.h:' + # dummy dependency, to avoid the deleted-header problem. + sed -n -e 's|^ *\(.*\) *\\$|\1:|p' < "$tmpdepfile" >> "$depfile" + rm -f "$tmpdepfile" + ;; + +## The order of this option in the case statement is important, since the +## shell code in configure will try each of these formats in the order +## listed in this file. A plain '-MD' option would be understood by many +## compilers, so we must ensure this comes after the gcc and icc options. +pgcc) + # Portland's C compiler understands '-MD'. + # Will always output deps to 'file.d' where file is the root name of the + # source file under compilation, even if file resides in a subdirectory. + # The object file name does not affect the name of the '.d' file. + # pgcc 10.2 will output + # foo.o: sub/foo.c sub/foo.h + # and will wrap long lines using '\' : + # foo.o: sub/foo.c ... \ + # sub/foo.h ... \ + # ... + set_dir_from "$object" + # Use the source, not the object, to determine the base name, since + # that's sadly what pgcc will do too. + set_base_from "$source" + tmpdepfile=$base.d + + # For projects that build the same source file twice into different object + # files, the pgcc approach of using the *source* file root name can cause + # problems in parallel builds. Use a locking strategy to avoid stomping on + # the same $tmpdepfile. + lockdir=$base.d-lock + trap " + echo '$0: caught signal, cleaning up...' >&2 + rmdir '$lockdir' + exit 1 + " 1 2 13 15 + numtries=100 + i=$numtries + while test $i -gt 0; do + # mkdir is a portable test-and-set. + if mkdir "$lockdir" 2>/dev/null; then + # This process acquired the lock. + "$@" -MD + stat=$? + # Release the lock. + rmdir "$lockdir" + break + else + # If the lock is being held by a different process, wait + # until the winning process is done or we timeout. + while test -d "$lockdir" && test $i -gt 0; do + sleep 1 + i=`expr $i - 1` + done + fi + i=`expr $i - 1` + done + trap - 1 2 13 15 + if test $i -le 0; then + echo "$0: failed to acquire lock after $numtries attempts" >&2 + echo "$0: check lockdir '$lockdir'" >&2 + exit 1 + fi + + if test $stat -ne 0; then + rm -f "$tmpdepfile" + exit $stat + fi + rm -f "$depfile" + # Each line is of the form `foo.o: dependent.h', + # or `foo.o: dep1.h dep2.h \', or ` dep3.h dep4.h \'. + # Do two passes, one to just change these to + # `$object: dependent.h' and one to simply `dependent.h:'. + sed "s,^[^:]*:,$object :," < "$tmpdepfile" > "$depfile" + # Some versions of the HPUX 10.20 sed can't process this invocation + # correctly. Breaking it into two sed invocations is a workaround. + sed 's,^[^:]*: \(.*\)$,\1,;s/^\\$//;/^$/d;/:$/d' < "$tmpdepfile" \ + | sed -e 's/$/ :/' >> "$depfile" + rm -f "$tmpdepfile" + ;; + +hp2) + # The "hp" stanza above does not work with aCC (C++) and HP's ia64 + # compilers, which have integrated preprocessors. The correct option + # to use with these is +Maked; it writes dependencies to a file named + # 'foo.d', which lands next to the object file, wherever that + # happens to be. + # Much of this is similar to the tru64 case; see comments there. + set_dir_from "$object" + set_base_from "$object" + if test "$libtool" = yes; then + tmpdepfile1=$dir$base.d + tmpdepfile2=$dir.libs/$base.d + "$@" -Wc,+Maked + else + tmpdepfile1=$dir$base.d + tmpdepfile2=$dir$base.d + "$@" +Maked + fi + stat=$? + if test $stat -ne 0; then + rm -f "$tmpdepfile1" "$tmpdepfile2" + exit $stat + fi + + for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" + do + test -f "$tmpdepfile" && break + done + if test -f "$tmpdepfile"; then + sed -e "s,^.*\.[$lower]*:,$object:," "$tmpdepfile" > "$depfile" + # Add 'dependent.h:' lines. + sed -ne '2,${ + s/^ *// + s/ \\*$// + s/$/:/ + p + }' "$tmpdepfile" >> "$depfile" + else + make_dummy_depfile + fi + rm -f "$tmpdepfile" "$tmpdepfile2" + ;; + +tru64) + # The Tru64 compiler uses -MD to generate dependencies as a side + # effect. 'cc -MD -o foo.o ...' puts the dependencies into 'foo.o.d'. + # At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put + # dependencies in 'foo.d' instead, so we check for that too. + # Subdirectories are respected. + set_dir_from "$object" + set_base_from "$object" + + if test "$libtool" = yes; then + # Libtool generates 2 separate objects for the 2 libraries. These + # two compilations output dependencies in $dir.libs/$base.o.d and + # in $dir$base.o.d. We have to check for both files, because + # one of the two compilations can be disabled. We should prefer + # $dir$base.o.d over $dir.libs/$base.o.d because the latter is + # automatically cleaned when .libs/ is deleted, while ignoring + # the former would cause a distcleancheck panic. + tmpdepfile1=$dir$base.o.d # libtool 1.5 + tmpdepfile2=$dir.libs/$base.o.d # Likewise. + tmpdepfile3=$dir.libs/$base.d # Compaq CCC V6.2-504 + "$@" -Wc,-MD + else + tmpdepfile1=$dir$base.d + tmpdepfile2=$dir$base.d + tmpdepfile3=$dir$base.d + "$@" -MD + fi + + stat=$? + if test $stat -ne 0; then + rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" + exit $stat + fi + + for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" + do + test -f "$tmpdepfile" && break + done + # Same post-processing that is required for AIX mode. + aix_post_process_depfile + ;; + +msvc7) + if test "$libtool" = yes; then + showIncludes=-Wc,-showIncludes + else + showIncludes=-showIncludes + fi + "$@" $showIncludes > "$tmpdepfile" + stat=$? + grep -v '^Note: including file: ' "$tmpdepfile" + if test $stat -ne 0; then + rm -f "$tmpdepfile" + exit $stat + fi + rm -f "$depfile" + echo "$object : \\" > "$depfile" + # The first sed program below extracts the file names and escapes + # backslashes for cygpath. The second sed program outputs the file + # name when reading, but also accumulates all include files in the + # hold buffer in order to output them again at the end. This only + # works with sed implementations that can handle large buffers. + sed < "$tmpdepfile" -n ' +/^Note: including file: *\(.*\)/ { + s//\1/ + s/\\/\\\\/g + p +}' | $cygpath_u | sort -u | sed -n ' +s/ /\\ /g +s/\(.*\)/'"$tab"'\1 \\/p +s/.\(.*\) \\/\1:/ +H +$ { + s/.*/'"$tab"'/ + G + p +}' >> "$depfile" + echo >> "$depfile" # make sure the fragment doesn't end with a backslash + rm -f "$tmpdepfile" + ;; + +msvc7msys) + # This case exists only to let depend.m4 do its work. It works by + # looking at the text of this script. This case will never be run, + # since it is checked for above. + exit 1 + ;; + +#nosideeffect) + # This comment above is used by automake to tell side-effect + # dependency tracking mechanisms from slower ones. + +dashmstdout) + # Important note: in order to support this mode, a compiler *must* + # always write the preprocessed file to stdout, regardless of -o. + "$@" || exit $? + + # Remove the call to Libtool. + if test "$libtool" = yes; then + while test "X$1" != 'X--mode=compile'; do + shift + done + shift + fi + + # Remove '-o $object'. + IFS=" " + for arg + do + case $arg in + -o) + shift + ;; + $object) + shift + ;; + *) + set fnord "$@" "$arg" + shift # fnord + shift # $arg + ;; + esac + done + + test -z "$dashmflag" && dashmflag=-M + # Require at least two characters before searching for ':' + # in the target name. This is to cope with DOS-style filenames: + # a dependency such as 'c:/foo/bar' could be seen as target 'c' otherwise. + "$@" $dashmflag | + sed "s|^[$tab ]*[^:$tab ][^:][^:]*:[$tab ]*|$object: |" > "$tmpdepfile" + rm -f "$depfile" + cat < "$tmpdepfile" > "$depfile" + # Some versions of the HPUX 10.20 sed can't process this sed invocation + # correctly. Breaking it into two sed invocations is a workaround. + tr ' ' "$nl" < "$tmpdepfile" \ + | sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' \ + | sed -e 's/$/ :/' >> "$depfile" + rm -f "$tmpdepfile" + ;; + +dashXmstdout) + # This case only exists to satisfy depend.m4. It is never actually + # run, as this mode is specially recognized in the preamble. + exit 1 + ;; + +makedepend) + "$@" || exit $? + # Remove any Libtool call + if test "$libtool" = yes; then + while test "X$1" != 'X--mode=compile'; do + shift + done + shift + fi + # X makedepend + shift + cleared=no eat=no + for arg + do + case $cleared in + no) + set ""; shift + cleared=yes ;; + esac + if test $eat = yes; then + eat=no + continue + fi + case "$arg" in + -D*|-I*) + set fnord "$@" "$arg"; shift ;; + # Strip any option that makedepend may not understand. Remove + # the object too, otherwise makedepend will parse it as a source file. + -arch) + eat=yes ;; + -*|$object) + ;; + *) + set fnord "$@" "$arg"; shift ;; + esac + done + obj_suffix=`echo "$object" | sed 's/^.*\././'` + touch "$tmpdepfile" + ${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@" + rm -f "$depfile" + # makedepend may prepend the VPATH from the source file name to the object. + # No need to regex-escape $object, excess matching of '.' is harmless. + sed "s|^.*\($object *:\)|\1|" "$tmpdepfile" > "$depfile" + # Some versions of the HPUX 10.20 sed can't process the last invocation + # correctly. Breaking it into two sed invocations is a workaround. + sed '1,2d' "$tmpdepfile" \ + | tr ' ' "$nl" \ + | sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' \ + | sed -e 's/$/ :/' >> "$depfile" + rm -f "$tmpdepfile" "$tmpdepfile".bak + ;; + +cpp) + # Important note: in order to support this mode, a compiler *must* + # always write the preprocessed file to stdout. + "$@" || exit $? + + # Remove the call to Libtool. + if test "$libtool" = yes; then + while test "X$1" != 'X--mode=compile'; do + shift + done + shift + fi + + # Remove '-o $object'. + IFS=" " + for arg + do + case $arg in + -o) + shift + ;; + $object) + shift + ;; + *) + set fnord "$@" "$arg" + shift # fnord + shift # $arg + ;; + esac + done + + "$@" -E \ + | sed -n -e '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \ + -e '/^#line [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \ + | sed '$ s: \\$::' > "$tmpdepfile" + rm -f "$depfile" + echo "$object : \\" > "$depfile" + cat < "$tmpdepfile" >> "$depfile" + sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile" + rm -f "$tmpdepfile" + ;; + +msvisualcpp) + # Important note: in order to support this mode, a compiler *must* + # always write the preprocessed file to stdout. + "$@" || exit $? + + # Remove the call to Libtool. + if test "$libtool" = yes; then + while test "X$1" != 'X--mode=compile'; do + shift + done + shift + fi + + IFS=" " + for arg + do + case "$arg" in + -o) + shift + ;; + $object) + shift + ;; + "-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI") + set fnord "$@" + shift + shift + ;; + *) + set fnord "$@" "$arg" + shift + shift + ;; + esac + done + "$@" -E 2>/dev/null | + sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::\1:p' | $cygpath_u | sort -u > "$tmpdepfile" + rm -f "$depfile" + echo "$object : \\" > "$depfile" + sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::'"$tab"'\1 \\:p' >> "$depfile" + echo "$tab" >> "$depfile" + sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::\1\::p' >> "$depfile" + rm -f "$tmpdepfile" + ;; + +msvcmsys) + # This case exists only to let depend.m4 do its work. It works by + # looking at the text of this script. This case will never be run, + # since it is checked for above. + exit 1 + ;; + +none) + exec "$@" + ;; + +*) + echo "Unknown depmode $depmode" 1>&2 + exit 1 + ;; +esac + +exit 0 + +# Local Variables: +# mode: shell-script +# sh-indentation: 2 +# eval: (add-hook 'write-file-hooks 'time-stamp) +# time-stamp-start: "scriptversion=" +# time-stamp-format: "%:y-%02m-%02d.%02H" +# time-stamp-time-zone: "UTC" +# time-stamp-end: "; # UTC" +# End: diff --git a/libs/ode-0.16.1/drawstuff/Makefile.am b/libs/ode-0.16.1/drawstuff/Makefile.am new file mode 100644 index 0000000..def863c --- /dev/null +++ b/libs/ode-0.16.1/drawstuff/Makefile.am @@ -0,0 +1,4 @@ +if ENABLE_DRAWSTUFF +SUBDIRS = src dstest +EXTRA_DIST = textures +endif diff --git a/libs/ode-0.16.1/drawstuff/Makefile.in b/libs/ode-0.16.1/drawstuff/Makefile.in new file mode 100644 index 0000000..a57e158 --- /dev/null +++ b/libs/ode-0.16.1/drawstuff/Makefile.in @@ -0,0 +1,641 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = drawstuff +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ + $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ + $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/ode/src/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +SOURCES = +DIST_SOURCES = +RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ + ctags-recursive dvi-recursive html-recursive info-recursive \ + install-data-recursive install-dvi-recursive \ + install-exec-recursive install-html-recursive \ + install-info-recursive install-pdf-recursive \ + install-ps-recursive install-recursive installcheck-recursive \ + installdirs-recursive pdf-recursive ps-recursive \ + tags-recursive uninstall-recursive +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ + distclean-recursive maintainer-clean-recursive +am__recursive_targets = \ + $(RECURSIVE_TARGETS) \ + $(RECURSIVE_CLEAN_TARGETS) \ + $(am__extra_recursive_targets) +AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ + distdir +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +DIST_SUBDIRS = src dstest +am__DIST_COMMON = $(srcdir)/Makefile.in +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +am__relativize = \ + dir0=`pwd`; \ + sed_first='s,^\([^/]*\)/.*$$,\1,'; \ + sed_rest='s,^[^/]*/*,,'; \ + sed_last='s,^.*/\([^/]*\)$$,\1,'; \ + sed_butlast='s,/*[^/]*$$,,'; \ + while test -n "$$dir1"; do \ + first=`echo "$$dir1" | sed -e "$$sed_first"`; \ + if test "$$first" != "."; then \ + if test "$$first" = ".."; then \ + dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ + dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ + else \ + first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ + if test "$$first2" = "$$first"; then \ + dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ + else \ + dir2="../$$dir2"; \ + fi; \ + dir0="$$dir0"/"$$first"; \ + fi; \ + fi; \ + dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ + done; \ + reldir="$$dir2" +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AS = @AS@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CCD_CFLAGS = @CCD_CFLAGS@ +CCD_LIBS = @CCD_LIBS@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DOXYGEN = @DOXYGEN@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +EXTRA_LIBTOOL_LDFLAGS = @EXTRA_LIBTOOL_LDFLAGS@ +FGREP = @FGREP@ +GL_LIBS = @GL_LIBS@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBSTDCXX = @LIBSTDCXX@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +ODE_PRECISION = @ODE_PRECISION@ +ODE_VERSION = @ODE_VERSION@ +ODE_VERSION_INFO = @ODE_VERSION_INFO@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +WINDRES = @WINDRES@ +X11_CFLAGS = @X11_CFLAGS@ +X11_LIBS = @X11_LIBS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_WINDRES = @ac_ct_WINDRES@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +runstatedir = @runstatedir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +@ENABLE_DRAWSTUFF_TRUE@SUBDIRS = src dstest +@ENABLE_DRAWSTUFF_TRUE@EXTRA_DIST = textures +all: all-recursive + +.SUFFIXES: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign drawstuff/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign drawstuff/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +# This directory's subdirectories are mostly independent; you can cd +# into them and run 'make' without going through this Makefile. +# To change the values of 'make' variables: instead of editing Makefiles, +# (1) if the variable is set in 'config.status', edit 'config.status' +# (which will cause the Makefiles to be regenerated when you run 'make'); +# (2) otherwise, pass the desired values on the 'make' command line. +$(am__recursive_targets): + @fail=; \ + if $(am__make_keepgoing); then \ + failcom='fail=yes'; \ + else \ + failcom='exit 1'; \ + fi; \ + dot_seen=no; \ + target=`echo $@ | sed s/-recursive//`; \ + case "$@" in \ + distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ + *) list='$(SUBDIRS)' ;; \ + esac; \ + for subdir in $$list; do \ + echo "Making $$target in $$subdir"; \ + if test "$$subdir" = "."; then \ + dot_seen=yes; \ + local_target="$$target-am"; \ + else \ + local_target="$$target"; \ + fi; \ + ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ + || eval $$failcom; \ + done; \ + if test "$$dot_seen" = "no"; then \ + $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ + fi; test -z "$$fail" + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-recursive +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ + include_option=--etags-include; \ + empty_fix=.; \ + else \ + include_option=--include; \ + empty_fix=; \ + fi; \ + list='$(SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + test ! -f $$subdir/TAGS || \ + set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ + fi; \ + done; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-recursive + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-recursive + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done + @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + $(am__make_dryrun) \ + || test -d "$(distdir)/$$subdir" \ + || $(MKDIR_P) "$(distdir)/$$subdir" \ + || exit 1; \ + dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ + $(am__relativize); \ + new_distdir=$$reldir; \ + dir1=$$subdir; dir2="$(top_distdir)"; \ + $(am__relativize); \ + new_top_distdir=$$reldir; \ + echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ + echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ + ($(am__cd) $$subdir && \ + $(MAKE) $(AM_MAKEFLAGS) \ + top_distdir="$$new_top_distdir" \ + distdir="$$new_distdir" \ + am__remove_distdir=: \ + am__skip_length_check=: \ + am__skip_mode_fix=: \ + distdir) \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-recursive +all-am: Makefile +installdirs: installdirs-recursive +installdirs-am: +install: install-recursive +install-exec: install-exec-recursive +install-data: install-data-recursive +uninstall: uninstall-recursive + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-recursive +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-recursive + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-recursive + -rm -f Makefile +distclean-am: clean-am distclean-generic distclean-tags + +dvi: dvi-recursive + +dvi-am: + +html: html-recursive + +html-am: + +info: info-recursive + +info-am: + +install-data-am: + +install-dvi: install-dvi-recursive + +install-dvi-am: + +install-exec-am: + +install-html: install-html-recursive + +install-html-am: + +install-info: install-info-recursive + +install-info-am: + +install-man: + +install-pdf: install-pdf-recursive + +install-pdf-am: + +install-ps: install-ps-recursive + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-recursive + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-recursive + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-recursive + +pdf-am: + +ps: ps-recursive + +ps-am: + +uninstall-am: + +.MAKE: $(am__recursive_targets) install-am install-strip + +.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \ + check-am clean clean-generic clean-libtool cscopelist-am ctags \ + ctags-am distclean distclean-generic distclean-libtool \ + distclean-tags distdir dvi dvi-am html html-am info info-am \ + install install-am install-data install-data-am install-dvi \ + install-dvi-am install-exec install-exec-am install-html \ + install-html-am install-info install-info-am install-man \ + install-pdf install-pdf-am install-ps install-ps-am \ + install-strip installcheck installcheck-am installdirs \ + installdirs-am maintainer-clean maintainer-clean-generic \ + mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ + ps ps-am tags tags-am uninstall uninstall-am + +.PRECIOUS: Makefile + + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/libs/ode-0.16.1/drawstuff/dstest/Makefile.am b/libs/ode-0.16.1/drawstuff/dstest/Makefile.am new file mode 100644 index 0000000..cf7550c --- /dev/null +++ b/libs/ode-0.16.1/drawstuff/dstest/Makefile.am @@ -0,0 +1,14 @@ +noinst_PROGRAMS= dstest +AM_CPPFLAGS = -I$(top_srcdir)/drawstuff/src -I$(top_srcdir)/include + +dstest_SOURCES= dstest.cpp +dstest_LDADD=$(top_builddir)/drawstuff/src/libdrawstuff.la \ + @GL_LIBS@ + +if WIN32 +resources.o: $(top_srcdir)/drawstuff/src/resources.rc $(top_srcdir)/drawstuff/src/resource.h + $(WINDRES) $(top_srcdir)/drawstuff/src/resources.rc -o resources.o + +dstest_LDADD += resources.o +endif + diff --git a/libs/ode-0.16.1/drawstuff/dstest/Makefile.in b/libs/ode-0.16.1/drawstuff/dstest/Makefile.in new file mode 100644 index 0000000..e043d07 --- /dev/null +++ b/libs/ode-0.16.1/drawstuff/dstest/Makefile.in @@ -0,0 +1,614 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +noinst_PROGRAMS = dstest$(EXEEXT) +@WIN32_TRUE@am__append_1 = resources.o +subdir = drawstuff/dstest +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ + $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ + $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/ode/src/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +PROGRAMS = $(noinst_PROGRAMS) +am_dstest_OBJECTS = dstest.$(OBJEXT) +dstest_OBJECTS = $(am_dstest_OBJECTS) +dstest_DEPENDENCIES = $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(am__append_1) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/ode/src +depcomp = $(SHELL) $(top_srcdir)/depcomp +am__depfiles_maybe = depfiles +am__mv = mv -f +CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ + $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) +LTCXXCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CXXFLAGS) $(CXXFLAGS) +AM_V_CXX = $(am__v_CXX_@AM_V@) +am__v_CXX_ = $(am__v_CXX_@AM_DEFAULT_V@) +am__v_CXX_0 = @echo " CXX " $@; +am__v_CXX_1 = +CXXLD = $(CXX) +CXXLINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \ + $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CXXLD = $(am__v_CXXLD_@AM_V@) +am__v_CXXLD_ = $(am__v_CXXLD_@AM_DEFAULT_V@) +am__v_CXXLD_0 = @echo " CXXLD " $@; +am__v_CXXLD_1 = +SOURCES = $(dstest_SOURCES) +DIST_SOURCES = $(dstest_SOURCES) +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AS = @AS@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CCD_CFLAGS = @CCD_CFLAGS@ +CCD_LIBS = @CCD_LIBS@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DOXYGEN = @DOXYGEN@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +EXTRA_LIBTOOL_LDFLAGS = @EXTRA_LIBTOOL_LDFLAGS@ +FGREP = @FGREP@ +GL_LIBS = @GL_LIBS@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBSTDCXX = @LIBSTDCXX@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +ODE_PRECISION = @ODE_PRECISION@ +ODE_VERSION = @ODE_VERSION@ +ODE_VERSION_INFO = @ODE_VERSION_INFO@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +WINDRES = @WINDRES@ +X11_CFLAGS = @X11_CFLAGS@ +X11_LIBS = @X11_LIBS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_WINDRES = @ac_ct_WINDRES@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +runstatedir = @runstatedir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +AM_CPPFLAGS = -I$(top_srcdir)/drawstuff/src -I$(top_srcdir)/include +dstest_SOURCES = dstest.cpp +dstest_LDADD = $(top_builddir)/drawstuff/src/libdrawstuff.la @GL_LIBS@ \ + $(am__append_1) +all: all-am + +.SUFFIXES: +.SUFFIXES: .cpp .lo .o .obj +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign drawstuff/dstest/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign drawstuff/dstest/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): + +clean-noinstPROGRAMS: + @list='$(noinst_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list + +dstest$(EXEEXT): $(dstest_OBJECTS) $(dstest_DEPENDENCIES) $(EXTRA_dstest_DEPENDENCIES) + @rm -f dstest$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(dstest_OBJECTS) $(dstest_LDADD) $(LIBS) + +mostlyclean-compile: + -rm -f *.$(OBJEXT) + +distclean-compile: + -rm -f *.tab.c + +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dstest.Po@am__quote@ + +.cpp.o: +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ $< + +.cpp.obj: +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'` + +.cpp.lo: +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LTCXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LTCXXCOMPILE) -c -o $@ $< + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(PROGRAMS) +installdirs: +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-generic clean-libtool clean-noinstPROGRAMS \ + mostlyclean-am + +distclean: distclean-am + -rm -rf ./$(DEPDIR) + -rm -f Makefile +distclean-am: clean-am distclean-compile distclean-generic \ + distclean-tags + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -rf ./$(DEPDIR) + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ + mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: + +.MAKE: install-am install-strip + +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ + clean-libtool clean-noinstPROGRAMS cscopelist-am ctags \ + ctags-am distclean distclean-compile distclean-generic \ + distclean-libtool distclean-tags distdir dvi dvi-am html \ + html-am info info-am install install-am install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am install-info \ + install-info-am install-man install-pdf install-pdf-am \ + install-ps install-ps-am install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-am uninstall uninstall-am + +.PRECIOUS: Makefile + + +@WIN32_TRUE@resources.o: $(top_srcdir)/drawstuff/src/resources.rc $(top_srcdir)/drawstuff/src/resource.h +@WIN32_TRUE@ $(WINDRES) $(top_srcdir)/drawstuff/src/resources.rc -o resources.o + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/libs/ode-0.16.1/drawstuff/dstest/dstest.cpp b/libs/ode-0.16.1/drawstuff/dstest/dstest.cpp new file mode 100644 index 0000000..27f042f --- /dev/null +++ b/libs/ode-0.16.1/drawstuff/dstest/dstest.cpp @@ -0,0 +1,125 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#include +#include +#include + + +#ifndef M_PI +#define M_PI (3.14159265358979323846) +#endif + + +void start() +{ + // adjust the starting viewpoint a bit + float xyz[3],hpr[3]; + dsGetViewpoint (xyz,hpr); + hpr[0] += 7; + dsSetViewpoint (xyz,hpr); +} + + +void simLoop (int pause) +{ + float pos[3]; + float R[12]; + static float a = 0; + + if (!pause) a += 0.02f; + if (a > (2*M_PI)) a -= (float) (2*M_PI); + float ca = (float) cos(a); + float sa = (float) sin(a); + + dsSetTexture (DS_WOOD); + + float b = (a > M_PI) ? (2*(a-(float)M_PI)) : a*2; + pos[0] = -0.3f; + pos[1] = 0; + pos[2] = (float) (0.1f*(2*M_PI*b - b*b) + 0.65f); + R[0] = ca; R[1] = 0; R[2] = -sa; + R[4] = 0; R[5] = 1; R[6] = 0; + R[8] = sa; R[9] = 0; R[10] = ca; + dsSetColor (1,0.8f,0.6f); + dsDrawSphere (pos,R,0.3f); + + dsSetTexture (DS_NONE); + + pos[0] = -0.2f; + pos[1] = 0.8f; + pos[2] = 0.4f; + R[0] = ca; R[1] = -sa; R[2] = 0; + R[4] = sa; R[5] = ca; R[6] = 0; + R[8] = 0; R[9] = 0; R[10] = 1; + float sides[3] = {0.1f,0.4f,0.8f}; + dsSetColor (0.6f,0.6f,1); + dsDrawBox (pos,R,sides); + + dsSetTexture (DS_WOOD); + + float r = 0.3f; // cylinder radius + float d = (float)cos(a*2) * 0.4f; + float cd = (float)cos(-d/r); + float sd = (float)sin(-d/r); + pos[0] = -0.2f; + pos[1] = -1 + d; + pos[2] = 0.3f; + R[0] = 0; R[1] = 0; R[2] = -1; + R[4] = -sd; R[5] = cd; R[6] = 0; + R[8] = cd; R[9] = sd; R[10] = 0; + dsSetColor (0.4f,1,1); + dsDrawCylinder (pos,R,0.8f,r); + + pos[0] = 0; + pos[1] = 0; + pos[2] = 0.2f; + R[0] = 0; R[1] = sa; R[2] = -ca; + R[4] = 0; R[5] = ca; R[6] = sa; + R[8] = 1; R[9] = 0; R[10] = 0; + dsSetColor (1,0.9f,0.2f); + dsDrawCappedCylinder (pos,R,0.8f,0.2f); +} + + +void command (int cmd) +{ + dsPrint ("received command %d (`%c')\n",cmd,cmd); +} + + +int main (int argc, char **argv) +{ + // setup pointers to callback functions + dsFunctions fn; + fn.version = DS_VERSION; + fn.start = &start; + fn.step = &simLoop; + fn.command = command; + fn.stop = 0; + fn.path_to_textures = 0; // uses default + + // run simulation + dsSimulationLoop (argc,argv,400,400,&fn); + + return 0; +} diff --git a/libs/ode-0.16.1/drawstuff/src/Makefile.am b/libs/ode-0.16.1/drawstuff/src/Makefile.am new file mode 100644 index 0000000..911f4fd --- /dev/null +++ b/libs/ode-0.16.1/drawstuff/src/Makefile.am @@ -0,0 +1,26 @@ +# Drawstuff is meant as an aid for testing and not as a full +# rendering library. + +noinst_LTLIBRARIES = libdrawstuff.la +libdrawstuff_la_SOURCES = drawstuff.cpp internal.h +AM_CPPFLAGS = -I$(top_srcdir)/include \ + -I$(top_builddir)/include \ + -I$(top_srcdir)/ode/src \ + -DDEFAULT_PATH_TO_TEXTURES='"$(top_srcdir)/drawstuff/textures/"' \ + $(X11_CFLAGS) + +if WIN32 +libdrawstuff_la_SOURCES+= windows.cpp resource.h resources.rc +libdrawstuff_la_LIBADD = -lwinmm -lgdi32 +libdrawstuff_la_LDFLAGS = -no-undefined +endif + +if X11 +libdrawstuff_la_SOURCES+= x11.cpp +libdrawstuff_la_LIBADD = $(X11_LIBS) +endif + +if OSX +libdrawstuff_la_SOURCES+= osx.cpp +endif + diff --git a/libs/ode-0.16.1/drawstuff/src/Makefile.in b/libs/ode-0.16.1/drawstuff/src/Makefile.in new file mode 100644 index 0000000..4fb86f7 --- /dev/null +++ b/libs/ode-0.16.1/drawstuff/src/Makefile.in @@ -0,0 +1,655 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + +# Drawstuff is meant as an aid for testing and not as a full +# rendering library. + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +@WIN32_TRUE@am__append_1 = windows.cpp resource.h resources.rc +@X11_TRUE@am__append_2 = x11.cpp +@OSX_TRUE@am__append_3 = osx.cpp +subdir = drawstuff/src +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ + $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ + $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/ode/src/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +LTLIBRARIES = $(noinst_LTLIBRARIES) +am__DEPENDENCIES_1 = +@X11_TRUE@libdrawstuff_la_DEPENDENCIES = $(am__DEPENDENCIES_1) +am__libdrawstuff_la_SOURCES_DIST = drawstuff.cpp internal.h \ + windows.cpp resource.h resources.rc x11.cpp osx.cpp +@WIN32_TRUE@am__objects_1 = windows.lo +@X11_TRUE@am__objects_2 = x11.lo +@OSX_TRUE@am__objects_3 = osx.lo +am_libdrawstuff_la_OBJECTS = drawstuff.lo $(am__objects_1) \ + $(am__objects_2) $(am__objects_3) +libdrawstuff_la_OBJECTS = $(am_libdrawstuff_la_OBJECTS) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = +libdrawstuff_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX \ + $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CXXLD) \ + $(AM_CXXFLAGS) $(CXXFLAGS) $(libdrawstuff_la_LDFLAGS) \ + $(LDFLAGS) -o $@ +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/ode/src +depcomp = $(SHELL) $(top_srcdir)/depcomp +am__depfiles_maybe = depfiles +am__mv = mv -f +CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ + $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) +LTCXXCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CXXFLAGS) $(CXXFLAGS) +AM_V_CXX = $(am__v_CXX_@AM_V@) +am__v_CXX_ = $(am__v_CXX_@AM_DEFAULT_V@) +am__v_CXX_0 = @echo " CXX " $@; +am__v_CXX_1 = +CXXLD = $(CXX) +CXXLINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \ + $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CXXLD = $(am__v_CXXLD_@AM_V@) +am__v_CXXLD_ = $(am__v_CXXLD_@AM_DEFAULT_V@) +am__v_CXXLD_0 = @echo " CXXLD " $@; +am__v_CXXLD_1 = +COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ + $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CFLAGS) $(CFLAGS) +AM_V_CC = $(am__v_CC_@AM_V@) +am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) +am__v_CC_0 = @echo " CC " $@; +am__v_CC_1 = +CCLD = $(CC) +LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CCLD = $(am__v_CCLD_@AM_V@) +am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) +am__v_CCLD_0 = @echo " CCLD " $@; +am__v_CCLD_1 = +SOURCES = $(libdrawstuff_la_SOURCES) +DIST_SOURCES = $(am__libdrawstuff_la_SOURCES_DIST) +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AS = @AS@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CCD_CFLAGS = @CCD_CFLAGS@ +CCD_LIBS = @CCD_LIBS@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DOXYGEN = @DOXYGEN@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +EXTRA_LIBTOOL_LDFLAGS = @EXTRA_LIBTOOL_LDFLAGS@ +FGREP = @FGREP@ +GL_LIBS = @GL_LIBS@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBSTDCXX = @LIBSTDCXX@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +ODE_PRECISION = @ODE_PRECISION@ +ODE_VERSION = @ODE_VERSION@ +ODE_VERSION_INFO = @ODE_VERSION_INFO@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +WINDRES = @WINDRES@ +X11_CFLAGS = @X11_CFLAGS@ +X11_LIBS = @X11_LIBS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_WINDRES = @ac_ct_WINDRES@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +runstatedir = @runstatedir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +noinst_LTLIBRARIES = libdrawstuff.la +libdrawstuff_la_SOURCES = drawstuff.cpp internal.h $(am__append_1) \ + $(am__append_2) $(am__append_3) +AM_CPPFLAGS = -I$(top_srcdir)/include \ + -I$(top_builddir)/include \ + -I$(top_srcdir)/ode/src \ + -DDEFAULT_PATH_TO_TEXTURES='"$(top_srcdir)/drawstuff/textures/"' \ + $(X11_CFLAGS) + +@WIN32_TRUE@libdrawstuff_la_LIBADD = -lwinmm -lgdi32 +@X11_TRUE@libdrawstuff_la_LIBADD = $(X11_LIBS) +@WIN32_TRUE@libdrawstuff_la_LDFLAGS = -no-undefined +all: all-am + +.SUFFIXES: +.SUFFIXES: .cpp .lo .o .obj +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign drawstuff/src/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign drawstuff/src/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): + +clean-noinstLTLIBRARIES: + -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES) + @list='$(noinst_LTLIBRARIES)'; \ + locs=`for p in $$list; do echo $$p; done | \ + sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ + sort -u`; \ + test -z "$$locs" || { \ + echo rm -f $${locs}; \ + rm -f $${locs}; \ + } + +libdrawstuff.la: $(libdrawstuff_la_OBJECTS) $(libdrawstuff_la_DEPENDENCIES) $(EXTRA_libdrawstuff_la_DEPENDENCIES) + $(AM_V_CXXLD)$(libdrawstuff_la_LINK) $(libdrawstuff_la_OBJECTS) $(libdrawstuff_la_LIBADD) $(LIBS) + +mostlyclean-compile: + -rm -f *.$(OBJEXT) + +distclean-compile: + -rm -f *.tab.c + +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/drawstuff.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/osx.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/windows.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/x11.Plo@am__quote@ + +.cpp.o: +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ $< + +.cpp.obj: +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'` + +.cpp.lo: +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LTCXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LTCXXCOMPILE) -c -o $@ $< + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(LTLIBRARIES) +installdirs: +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-generic clean-libtool clean-noinstLTLIBRARIES \ + mostlyclean-am + +distclean: distclean-am + -rm -rf ./$(DEPDIR) + -rm -f Makefile +distclean-am: clean-am distclean-compile distclean-generic \ + distclean-tags + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -rf ./$(DEPDIR) + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ + mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: + +.MAKE: install-am install-strip + +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ + clean-libtool clean-noinstLTLIBRARIES cscopelist-am ctags \ + ctags-am distclean distclean-compile distclean-generic \ + distclean-libtool distclean-tags distdir dvi dvi-am html \ + html-am info info-am install install-am install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am install-info \ + install-info-am install-man install-pdf install-pdf-am \ + install-ps install-ps-am install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-am uninstall uninstall-am + +.PRECIOUS: Makefile + + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/libs/ode-0.16.1/drawstuff/src/drawstuff.cpp b/libs/ode-0.16.1/drawstuff/src/drawstuff.cpp new file mode 100644 index 0000000..351be93 --- /dev/null +++ b/libs/ode-0.16.1/drawstuff/src/drawstuff.cpp @@ -0,0 +1,1671 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001-2003 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +/* + +simple graphics. + +the following command line flags can be used (typically under unix) + -notex Do not use any textures + -noshadow[s] Do not draw any shadows + -pause Start the simulation paused + -texturepath Inform an alternative textures path + +TODO +---- + +manage openGL state changes better + +*/ + +#ifdef WIN32 +#include +#endif + +#include +#include "config.h" + +#ifdef HAVE_APPLE_OPENGL_FRAMEWORK +#include +#include +#else +#include +#include +#endif + +#include "drawstuff/drawstuff.h" +#include "internal.h" + +//*************************************************************************** +// misc + +#ifndef DEFAULT_PATH_TO_TEXTURES +#if 0 +#define DEFAULT_PATH_TO_TEXTURES "..\\textures\\" +#else +#define DEFAULT_PATH_TO_TEXTURES "../textures/" +#endif +#endif + +#ifndef M_PI +#define M_PI (3.14159265358979323846) +#endif + +// constants to convert degrees to radians and the reverse +#define RAD_TO_DEG (180.0/M_PI) +#define DEG_TO_RAD (M_PI/180.0) + +// light vector. LIGHTZ is implicitly 1 +#define LIGHTX (1.0f) +#define LIGHTY (0.4f) + +// ground and sky +#define SHADOW_INTENSITY (0.65f) +#define GROUND_R (0.5f) // ground color for when there's no texture +#define GROUND_G (0.5f) +#define GROUND_B (0.3f) + +const float ground_scale = 1.0f/1.0f; // ground texture scale (1/size) +const float ground_ofsx = 0.5; // offset of ground texture +const float ground_ofsy = 0.5; +const float sky_scale = 1.0f/4.0f; // sky texture scale (1/size) +const float sky_height = 1.0f; // sky height above viewpoint + +//*************************************************************************** +// misc mathematics stuff + +static void normalizeVector3 (float v[3]) +{ + float len = v[0]*v[0] + v[1]*v[1] + v[2]*v[2]; + if (len <= 0.0f) { + v[0] = 1; + v[1] = 0; + v[2] = 0; + } + else { + len = 1.0f / (float)sqrt(len); + v[0] *= len; + v[1] *= len; + v[2] *= len; + } +} + +static void crossProduct3(float res[3], const float a[3], const float b[3]) +{ + float res_0 = a[1]*b[2] - a[2]*b[1]; + float res_1 = a[2]*b[0] - a[0]*b[2]; + float res_2 = a[0]*b[1] - a[1]*b[0]; + // Only assign after all the calculations are over to avoid incurring memory aliasing + res[0] = res_0; + res[1] = res_1; + res[2] = res_2; +} + +//*************************************************************************** +// PPM image object + +typedef unsigned char byte; + +class Image { + int image_width,image_height; + byte *image_data; +public: + Image (char *filename); + // load from PPM file + ~Image(); + int width() { return image_width; } + int height() { return image_height; } + byte *data() { return image_data; } +}; + + +// skip over whitespace and comments in a stream. + +static void skipWhiteSpace (char *filename, FILE *f) +{ + int c,d; + for(;;) { + c = fgetc(f); + if (c==EOF) dsError ("unexpected end of file in \"%s\"",filename); + + // skip comments + if (c == '#') { + do { + d = fgetc(f); + if (d==EOF) dsError ("unexpected end of file in \"%s\"",filename); + } while (d != '\n'); + continue; + } + + if (c > ' ') { + ungetc (c,f); + return; + } + } +} + + +// read a number from a stream, this return 0 if there is none (that's okay +// because 0 is a bad value for all PPM numbers anyway). + +static int readNumber (char *filename, FILE *f) +{ + int c,n=0; + for(;;) { + c = fgetc(f); + if (c==EOF) dsError ("unexpected end of file in \"%s\"",filename); + if (c >= '0' && c <= '9') n = n*10 + (c - '0'); + else { + ungetc (c,f); + return n; + } + } +} + + +Image::Image (char *filename) +{ + FILE *f = fopen (filename,"rb"); + if (!f) dsError ("Can't open image file `%s'",filename); + + // read in header + if (fgetc(f) != 'P' || fgetc(f) != '6') + dsError ("image file \"%s\" is not a binary PPM (no P6 header)",filename); + skipWhiteSpace (filename,f); + + // read in image parameters + image_width = readNumber (filename,f); + skipWhiteSpace (filename,f); + image_height = readNumber (filename,f); + skipWhiteSpace (filename,f); + int max_value = readNumber (filename,f); + + // check values + if (image_width < 1 || image_height < 1) + dsError ("bad image file \"%s\"",filename); + if (max_value != 255) + dsError ("image file \"%s\" must have color range of 255",filename); + + // read either nothing, LF (10), or CR,LF (13,10) + int c = fgetc(f); + if (c == 10) { + // LF + } + else if (c == 13) { + // CR + c = fgetc(f); + if (c != 10) ungetc (c,f); + } + else ungetc (c,f); + + // read in rest of data + image_data = new byte [image_width*image_height*3]; + if (fread (image_data,image_width*image_height*3,1,f) != 1) + dsError ("Can not read data from image file `%s'",filename); + fclose (f); +} + + +Image::~Image() +{ + delete[] image_data; +} + +//*************************************************************************** +// Texture object. + +class Texture { + Image *image; + GLuint name; +public: + Texture (char *filename); + ~Texture(); + void bind (int modulate); +}; + + +Texture::Texture (char *filename) +{ + image = new Image (filename); + glGenTextures (1,&name); + glBindTexture (GL_TEXTURE_2D,name); + + // set pixel unpacking mode + glPixelStorei (GL_UNPACK_SWAP_BYTES, 0); + glPixelStorei (GL_UNPACK_ROW_LENGTH, 0); + glPixelStorei (GL_UNPACK_ALIGNMENT, 1); + glPixelStorei (GL_UNPACK_SKIP_ROWS, 0); + glPixelStorei (GL_UNPACK_SKIP_PIXELS, 0); + + // glTexImage2D (GL_TEXTURE_2D, 0, 3, image->width(), image->height(), 0, + // GL_RGB, GL_UNSIGNED_BYTE, image->data()); + gluBuild2DMipmaps (GL_TEXTURE_2D, 3, image->width(), image->height(), + GL_RGB, GL_UNSIGNED_BYTE, image->data()); + + // set texture parameters - will these also be bound to the texture??? + glTexParameterf (GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT); + glTexParameterf (GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT); + + glTexParameterf (GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR); + glTexParameterf (GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, + GL_LINEAR_MIPMAP_LINEAR); + + glTexEnvf (GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_DECAL); +} + + +Texture::~Texture() +{ + delete image; + glDeleteTextures (1,&name); +} + + +void Texture::bind (int modulate) +{ + glBindTexture (GL_TEXTURE_2D,name); + glTexEnvi (GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, + modulate ? GL_MODULATE : GL_DECAL); +} + +//*************************************************************************** +// the current drawing state (for when the user's step function is drawing) + +static float color[4] = {0,0,0,0}; // current r,g,b,alpha color +static int tnum = 0; // current texture number + +//*************************************************************************** +// OpenGL utility stuff + +static void setCamera (float x, float y, float z, float h, float p, float r) +{ + glMatrixMode (GL_MODELVIEW); + glLoadIdentity(); + glRotatef (90, 0,0,1); + glRotatef (90, 0,1,0); + glRotatef (r, 1,0,0); + glRotatef (p, 0,1,0); + glRotatef (-h, 0,0,1); + glTranslatef (-x,-y,-z); +} + + +// sets the material color, not the light color + +static void setColor (float r, float g, float b, float alpha) +{ + GLfloat light_ambient[4],light_diffuse[4],light_specular[4]; + light_ambient[0] = r*0.3f; + light_ambient[1] = g*0.3f; + light_ambient[2] = b*0.3f; + light_ambient[3] = alpha; + light_diffuse[0] = r*0.7f; + light_diffuse[1] = g*0.7f; + light_diffuse[2] = b*0.7f; + light_diffuse[3] = alpha; + light_specular[0] = r*0.2f; + light_specular[1] = g*0.2f; + light_specular[2] = b*0.2f; + light_specular[3] = alpha; + glMaterialfv (GL_FRONT_AND_BACK, GL_AMBIENT, light_ambient); + glMaterialfv (GL_FRONT_AND_BACK, GL_DIFFUSE, light_diffuse); + glMaterialfv (GL_FRONT_AND_BACK, GL_SPECULAR, light_specular); + glMaterialf (GL_FRONT_AND_BACK, GL_SHININESS, 5.0f); +} + + +static void setTransform (const float pos[3], const float R[12]) +{ + GLfloat matrix[16]; + matrix[0]=R[0]; + matrix[1]=R[4]; + matrix[2]=R[8]; + matrix[3]=0; + matrix[4]=R[1]; + matrix[5]=R[5]; + matrix[6]=R[9]; + matrix[7]=0; + matrix[8]=R[2]; + matrix[9]=R[6]; + matrix[10]=R[10]; + matrix[11]=0; + matrix[12]=pos[0]; + matrix[13]=pos[1]; + matrix[14]=pos[2]; + matrix[15]=1; + glPushMatrix(); + glMultMatrixf (matrix); +} +static void setTransformD (const double pos[3], const double R[12]) +{ + GLdouble matrix[16]; + matrix[0]=R[0]; + matrix[1]=R[4]; + matrix[2]=R[8]; + matrix[3]=0; + matrix[4]=R[1]; + matrix[5]=R[5]; + matrix[6]=R[9]; + matrix[7]=0; + matrix[8]=R[2]; + matrix[9]=R[6]; + matrix[10]=R[10]; + matrix[11]=0; + matrix[12]=pos[0]; + matrix[13]=pos[1]; + matrix[14]=pos[2]; + matrix[15]=1; + glPushMatrix(); + glMultMatrixd (matrix); +} + + +// set shadow projection transform + +static void setShadowTransform() +{ + GLfloat matrix[16]; + for (int i=0; i<16; i++) matrix[i] = 0; + matrix[0]=1; + matrix[5]=1; + matrix[8]=-LIGHTX; + matrix[9]=-LIGHTY; + matrix[15]=1; + glPushMatrix(); + glMultMatrixf (matrix); +} + +static void drawConvex (const float *_planes, unsigned int _planecount, + const float *_points, unsigned int /*_pointcount*/, + const unsigned int *_polygons) +{ + unsigned int polyindex=0; + for(unsigned int i=0;i<_planecount;++i) + { + unsigned int pointcount=_polygons[polyindex]; + polyindex++; + glBegin (GL_POLYGON); + glNormal3f(_planes[(i*4)+0], + _planes[(i*4)+1], + _planes[(i*4)+2]); + for(unsigned int j=0;j 0) { + float q1[3],q2[3],q3[3]; // sub-vertices + for (i=0; i<3; i++) { + q1[i] = 0.5f*(p1[i]+p2[i]); + q2[i] = 0.5f*(p2[i]+p3[i]); + q3[i] = 0.5f*(p3[i]+p1[i]); + } + float length1 = (float)(1.0/sqrt(q1[0]*q1[0]+q1[1]*q1[1]+q1[2]*q1[2])); + float length2 = (float)(1.0/sqrt(q2[0]*q2[0]+q2[1]*q2[1]+q2[2]*q2[2])); + float length3 = (float)(1.0/sqrt(q3[0]*q3[0]+q3[1]*q3[1]+q3[2]*q3[2])); + for (i=0; i<3; i++) { + q1[i] *= length1; + q2[i] *= length2; + q3[i] *= length3; + } + drawPatch (p1,q1,q3,level-1); + drawPatch (q1,p2,q2,level-1); + drawPatch (q1,q2,q3,level-1); + drawPatch (q3,q2,p3,level-1); + } + else { + glNormal3f (p1[0],p1[1],p1[2]); + glVertex3f (p1[0],p1[1],p1[2]); + glNormal3f (p2[0],p2[1],p2[2]); + glVertex3f (p2[0],p2[1],p2[2]); + glNormal3f (p3[0],p3[1],p3[2]); + glVertex3f (p3[0],p3[1],p3[2]); + } +} + + +// draw a sphere of radius 1 + +static int sphere_quality = 1; + +static void drawSphere() +{ + // icosahedron data for an icosahedron of radius 1.0 +# define ICX 0.525731112119133606f +# define ICZ 0.850650808352039932f + static GLfloat idata[12][3] = { + {-ICX, 0, ICZ}, + {ICX, 0, ICZ}, + {-ICX, 0, -ICZ}, + {ICX, 0, -ICZ}, + {0, ICZ, ICX}, + {0, ICZ, -ICX}, + {0, -ICZ, ICX}, + {0, -ICZ, -ICX}, + {ICZ, ICX, 0}, + {-ICZ, ICX, 0}, + {ICZ, -ICX, 0}, + {-ICZ, -ICX, 0} + }; + + static int index[20][3] = { + {0, 4, 1}, {0, 9, 4}, + {9, 5, 4}, {4, 5, 8}, + {4, 8, 1}, {8, 10, 1}, + {8, 3, 10}, {5, 3, 8}, + {5, 2, 3}, {2, 7, 3}, + {7, 10, 3}, {7, 6, 10}, + {7, 11, 6}, {11, 0, 6}, + {0, 1, 6}, {6, 1, 10}, + {9, 0, 11}, {9, 11, 2}, + {9, 2, 5}, {7, 2, 11}, + }; + + static GLuint listnum = 0; + if (listnum==0) { + listnum = glGenLists (1); + glNewList (listnum,GL_COMPILE); + glBegin (GL_TRIANGLES); + for (int i=0; i<20; i++) { + drawPatch (&idata[index[i][2]][0],&idata[index[i][1]][0], + &idata[index[i][0]][0],sphere_quality); + } + glEnd(); + glEndList(); + } + glCallList (listnum); +} + + +static void drawSphereShadow (float px, float py, float pz, float radius) +{ + // calculate shadow constants based on light vector + static int init=0; + static float len2,len1,scale; + if (!init) { + len2 = LIGHTX*LIGHTX + LIGHTY*LIGHTY; + len1 = 1.0f/(float)sqrt(len2); + scale = (float) sqrt(len2 + 1); + init = 1; + } + + // map sphere center to ground plane based on light vector + px -= LIGHTX*pz; + py -= LIGHTY*pz; + + const float kx = 0.96592582628907f; + const float ky = 0.25881904510252f; + float x=radius, y=0; + + glBegin (GL_TRIANGLE_FAN); + for (int i=0; i<24; i++) { + // for all points on circle, scale to elongated rotated shadow and draw + float x2 = (LIGHTX*x*scale - LIGHTY*y)*len1 + px; + float y2 = (LIGHTY*x*scale + LIGHTX*y)*len1 + py; + glTexCoord2f (x2*ground_scale+ground_ofsx,y2*ground_scale+ground_ofsy); + glVertex3f (x2,y2,0); + + // rotate [x,y] vector + float xtmp = kx*x - ky*y; + y = ky*x + kx*y; + x = xtmp; + } + glEnd(); +} + + +static void drawTriangle (const float *v0, const float *v1, const float *v2, int solid) +{ + float u[3],v[3],normal[3]; + u[0] = v1[0] - v0[0]; + u[1] = v1[1] - v0[1]; + u[2] = v1[2] - v0[2]; + v[0] = v2[0] - v0[0]; + v[1] = v2[1] - v0[1]; + v[2] = v2[2] - v0[2]; + crossProduct3(normal,u,v); + normalizeVector3 (normal); + + glBegin(solid ? GL_TRIANGLES : GL_LINE_STRIP); + glNormal3fv (normal); + glVertex3fv (v0); + glVertex3fv (v1); + glVertex3fv (v2); + glEnd(); +} + +static void drawTriangleD (const double *v0, const double *v1, const double *v2, int solid) +{ + float u[3],v[3],normal[3]; + u[0] = float( v1[0] - v0[0] ); + u[1] = float( v1[1] - v0[1] ); + u[2] = float( v1[2] - v0[2] ); + v[0] = float( v2[0] - v0[0] ); + v[1] = float( v2[1] - v0[1] ); + v[2] = float( v2[2] - v0[2] ); + crossProduct3(normal,u,v); + normalizeVector3 (normal); + + glBegin(solid ? GL_TRIANGLES : GL_LINE_STRIP); + glNormal3fv (normal); + glVertex3dv (v0); + glVertex3dv (v1); + glVertex3dv (v2); + glEnd(); +} + + +// draw a capped cylinder of length l and radius r, aligned along the x axis + +static int capped_cylinder_quality = 3; + +static void drawCapsule (float l, float r) +{ + int i,j; + float tmp,nx,ny,nz,start_nx,start_ny,a,ca,sa; + // number of sides to the cylinder (divisible by 4): + const int n = capped_cylinder_quality*4; + + l *= 0.5; + a = float(M_PI*2.0)/float(n); + sa = (float) sin(a); + ca = (float) cos(a); + + // draw cylinder body + ny=1; nz=0; // normal vector = (0,ny,nz) + glBegin (GL_TRIANGLE_STRIP); + for (i=0; i<=n; i++) { + glNormal3d (ny,nz,0); + glVertex3d (ny*r,nz*r,l); + glNormal3d (ny,nz,0); + glVertex3d (ny*r,nz*r,-l); + // rotate ny,nz + tmp = ca*ny - sa*nz; + nz = sa*ny + ca*nz; + ny = tmp; + } + glEnd(); + + // draw first cylinder cap + start_nx = 0; + start_ny = 1; + for (j=0; j<(n/4); j++) { + // get start_n2 = rotated start_n + float start_nx2 = ca*start_nx + sa*start_ny; + float start_ny2 = -sa*start_nx + ca*start_ny; + // get n=start_n and n2=start_n2 + nx = start_nx; ny = start_ny; nz = 0; + float nx2 = start_nx2, ny2 = start_ny2, nz2 = 0; + glBegin (GL_TRIANGLE_STRIP); + for (i=0; i<=n; i++) { + glNormal3d (ny2,nz2,nx2); + glVertex3d (ny2*r,nz2*r,l+nx2*r); + glNormal3d (ny,nz,nx); + glVertex3d (ny*r,nz*r,l+nx*r); + // rotate n,n2 + tmp = ca*ny - sa*nz; + nz = sa*ny + ca*nz; + ny = tmp; + tmp = ca*ny2- sa*nz2; + nz2 = sa*ny2 + ca*nz2; + ny2 = tmp; + } + glEnd(); + start_nx = start_nx2; + start_ny = start_ny2; + } + + // draw second cylinder cap + start_nx = 0; + start_ny = 1; + for (j=0; j<(n/4); j++) { + // get start_n2 = rotated start_n + float start_nx2 = ca*start_nx - sa*start_ny; + float start_ny2 = sa*start_nx + ca*start_ny; + // get n=start_n and n2=start_n2 + nx = start_nx; ny = start_ny; nz = 0; + float nx2 = start_nx2, ny2 = start_ny2, nz2 = 0; + glBegin (GL_TRIANGLE_STRIP); + for (i=0; i<=n; i++) { + glNormal3d (ny,nz,nx); + glVertex3d (ny*r,nz*r,-l+nx*r); + glNormal3d (ny2,nz2,nx2); + glVertex3d (ny2*r,nz2*r,-l+nx2*r); + // rotate n,n2 + tmp = ca*ny - sa*nz; + nz = sa*ny + ca*nz; + ny = tmp; + tmp = ca*ny2- sa*nz2; + nz2 = sa*ny2 + ca*nz2; + ny2 = tmp; + } + glEnd(); + start_nx = start_nx2; + start_ny = start_ny2; + } +} + + +// draw a cylinder of length l and radius r, aligned along the z axis + +static void drawCylinder (float l, float r, float zoffset) +{ + int i; + float tmp,ny,nz,a,ca,sa; + const int n = 24; // number of sides to the cylinder (divisible by 4) + + l *= 0.5; + a = float(M_PI*2.0)/float(n); + sa = (float) sin(a); + ca = (float) cos(a); + + // draw cylinder body + ny=1; nz=0; // normal vector = (0,ny,nz) + glBegin (GL_TRIANGLE_STRIP); + for (i=0; i<=n; i++) { + glNormal3d (ny,nz,0); + glVertex3d (ny*r,nz*r,l+zoffset); + glNormal3d (ny,nz,0); + glVertex3d (ny*r,nz*r,-l+zoffset); + // rotate ny,nz + tmp = ca*ny - sa*nz; + nz = sa*ny + ca*nz; + ny = tmp; + } + glEnd(); + + // draw top cap + glShadeModel (GL_FLAT); + ny=1; nz=0; // normal vector = (0,ny,nz) + glBegin (GL_TRIANGLE_FAN); + glNormal3d (0,0,1); + glVertex3d (0,0,l+zoffset); + for (i=0; i<=n; i++) { + if (i==1 || i==n/2+1) + setColor (color[0]*0.75f,color[1]*0.75f,color[2]*0.75f,color[3]); + glNormal3d (0,0,1); + glVertex3d (ny*r,nz*r,l+zoffset); + if (i==1 || i==n/2+1) + setColor (color[0],color[1],color[2],color[3]); + + // rotate ny,nz + tmp = ca*ny - sa*nz; + nz = sa*ny + ca*nz; + ny = tmp; + } + glEnd(); + + // draw bottom cap + ny=1; nz=0; // normal vector = (0,ny,nz) + glBegin (GL_TRIANGLE_FAN); + glNormal3d (0,0,-1); + glVertex3d (0,0,-l+zoffset); + for (i=0; i<=n; i++) { + if (i==1 || i==n/2+1) + setColor (color[0]*0.75f,color[1]*0.75f,color[2]*0.75f,color[3]); + glNormal3d (0,0,-1); + glVertex3d (ny*r,nz*r,-l+zoffset); + if (i==1 || i==n/2+1) + setColor (color[0],color[1],color[2],color[3]); + + // rotate ny,nz + tmp = ca*ny + sa*nz; + nz = -sa*ny + ca*nz; + ny = tmp; + } + glEnd(); +} + +//*************************************************************************** +// motion model + +// current camera position and orientation +static float view_xyz[3]; // position x,y,z +static float view_hpr[3]; // heading, pitch, roll (degrees) + + +// initialize the above variables + +static void initMotionModel() +{ + view_xyz[0] = 2; + view_xyz[1] = 0; + view_xyz[2] = 1; + view_hpr[0] = 180; + view_hpr[1] = 0; + view_hpr[2] = 0; +} + + +static void wrapCameraAngles() +{ + for (int i=0; i<3; i++) { + while (view_hpr[i] > 180) view_hpr[i] -= 360; + while (view_hpr[i] < -180) view_hpr[i] += 360; + } +} + + +// call this to update the current camera position. the bits in `mode' say +// if the left (1), middle (2) or right (4) mouse button is pressed, and +// (deltax,deltay) is the amount by which the mouse pointer has moved. + +void dsMotion (int mode, int deltax, int deltay) +{ + float side = 0.01f * float(deltax); + float fwd = (mode==4) ? (0.01f * float(deltay)) : 0.0f; + float s = (float) sin (view_hpr[0]*DEG_TO_RAD); + float c = (float) cos (view_hpr[0]*DEG_TO_RAD); + + if (mode==1) { + view_hpr[0] += float (deltax) * 0.5f; + view_hpr[1] += float (deltay) * 0.5f; + } + else { + view_xyz[0] += -s*side + c*fwd; + view_xyz[1] += c*side + s*fwd; + if (mode==2 || mode==5) view_xyz[2] += 0.01f * float(deltay); + } + wrapCameraAngles(); +} + +//*************************************************************************** +// drawing loop stuff + +// the current state: +// 0 = uninitialized +// 1 = dsSimulationLoop() called +// 2 = dsDrawFrame() called +static int current_state = 0; + +// textures and shadows +static int use_textures=1; // 1 if textures to be drawn +static int use_shadows=1; // 1 if shadows to be drawn +static Texture *sky_texture = 0; +static Texture *ground_texture = 0; +static Texture *wood_texture = 0; +static Texture *checkered_texture = 0; + +static Texture *texture[4+1]; // +1 since index 0 is not used + + + +#if !defined(macintosh) || defined(ODE_PLATFORM_OSX) + +void dsStartGraphics (int /*width*/, int /*height*/, dsFunctions *fn) +{ + + const char *prefix = DEFAULT_PATH_TO_TEXTURES; + if (fn->version >= 2 && fn->path_to_textures) prefix = fn->path_to_textures; + char *s = (char*) alloca (strlen(prefix) + 20); + + strcpy (s,prefix); + strcat (s,"/sky.ppm"); + texture[DS_SKY] = sky_texture = new Texture (s); + + strcpy (s,prefix); + strcat (s,"/ground.ppm"); + texture[DS_GROUND] = ground_texture = new Texture (s); + + strcpy (s,prefix); + strcat (s,"/wood.ppm"); + texture[DS_WOOD] = wood_texture = new Texture (s); + + strcpy (s,prefix); + strcat (s,"/checkered.ppm"); + texture[DS_CHECKERED] = checkered_texture = new Texture (s); +} + +#else // macintosh + +void dsStartGraphics (int width, int height, dsFunctions *fn) +{ + + // All examples build into the same dir + char *prefix = "::::drawstuff:textures"; + char *s = (char*) alloca (strlen(prefix) + 20); + + strcpy (s,prefix); + strcat (s,":sky.ppm"); + sky_texture = new Texture (s); + + strcpy (s,prefix); + strcat (s,":ground.ppm"); + ground_texture = new Texture (s); + + strcpy (s,prefix); + strcat (s,":wood.ppm"); + wood_texture = new Texture (s); +} + +#endif + + +void dsStopGraphics() +{ + delete sky_texture; + delete ground_texture; + delete wood_texture; + sky_texture = 0; + ground_texture = 0; + wood_texture = 0; +} + + +static void drawSky (float view_xyz[3]) +{ + glDisable (GL_LIGHTING); + if (use_textures) { + glEnable (GL_TEXTURE_2D); + sky_texture->bind (0); + } + else { + glDisable (GL_TEXTURE_2D); + glColor3f (0,0.5,1.0); + } + + // make sure sky depth is as far back as possible + glShadeModel (GL_FLAT); + glEnable (GL_DEPTH_TEST); + glDepthFunc (GL_LEQUAL); + glDepthRange (1,1); + + const float ssize = 1000.0f; + static float offset = 0.0f; + + float x = ssize*sky_scale; + float z = view_xyz[2] + sky_height; + + glBegin (GL_QUADS); + glNormal3f (0,0,-1); + glTexCoord2f (-x+offset,-x+offset); + glVertex3f (-ssize+view_xyz[0],-ssize+view_xyz[1],z); + glTexCoord2f (-x+offset,x+offset); + glVertex3f (-ssize+view_xyz[0],ssize+view_xyz[1],z); + glTexCoord2f (x+offset,x+offset); + glVertex3f (ssize+view_xyz[0],ssize+view_xyz[1],z); + glTexCoord2f (x+offset,-x+offset); + glVertex3f (ssize+view_xyz[0],-ssize+view_xyz[1],z); + glEnd(); + + offset = offset + 0.002f; + if (offset > 1) offset -= 1; + + glDepthFunc (GL_LESS); + glDepthRange (0,1); +} + + +static void drawGround() +{ + glDisable (GL_LIGHTING); + glShadeModel (GL_FLAT); + glEnable (GL_DEPTH_TEST); + glDepthFunc (GL_LESS); + // glDepthRange (1,1); + + if (use_textures) { + glEnable (GL_TEXTURE_2D); + ground_texture->bind (0); + } + else { + glDisable (GL_TEXTURE_2D); + glColor3f (GROUND_R,GROUND_G,GROUND_B); + } + + // ground fog seems to cause problems with TNT2 under windows + /* + GLfloat fogColor[4] = {0.5, 0.5, 0.5, 1}; + glEnable (GL_FOG); + glFogi (GL_FOG_MODE, GL_EXP2); + glFogfv (GL_FOG_COLOR, fogColor); + glFogf (GL_FOG_DENSITY, 0.05f); + glHint (GL_FOG_HINT, GL_NICEST); // GL_DONT_CARE); + glFogf (GL_FOG_START, 1.0); + glFogf (GL_FOG_END, 5.0); + */ + + const float gsize = 100.0f; + const float offset = 0; // -0.001f; ... polygon offsetting doesn't work well + + glBegin (GL_QUADS); + glNormal3f (0,0,1); + glTexCoord2f (-gsize*ground_scale + ground_ofsx, + -gsize*ground_scale + ground_ofsy); + glVertex3f (-gsize,-gsize,offset); + glTexCoord2f (gsize*ground_scale + ground_ofsx, + -gsize*ground_scale + ground_ofsy); + glVertex3f (gsize,-gsize,offset); + glTexCoord2f (gsize*ground_scale + ground_ofsx, + gsize*ground_scale + ground_ofsy); + glVertex3f (gsize,gsize,offset); + glTexCoord2f (-gsize*ground_scale + ground_ofsx, + gsize*ground_scale + ground_ofsy); + glVertex3f (-gsize,gsize,offset); + glEnd(); + + glDisable (GL_FOG); +} + + +static void drawPyramidGrid() +{ + // setup stuff + glEnable (GL_LIGHTING); + glDisable (GL_TEXTURE_2D); + glShadeModel (GL_FLAT); + glEnable (GL_DEPTH_TEST); + glDepthFunc (GL_LESS); + + // draw the pyramid grid + for (int i=-1; i<=1; i++) { + for (int j=-1; j<=1; j++) { + glPushMatrix(); + glTranslatef ((float)i,(float)j,(float)0); + if (i==1 && j==0) setColor (1,0,0,1); + else if (i==0 && j==1) setColor (0,0,1,1); + else setColor (1,1,0,1); + const float k = 0.03f; + glBegin (GL_TRIANGLE_FAN); + glNormal3f (0,-1,1); + glVertex3f (0,0,k); + glVertex3f (-k,-k,0); + glVertex3f ( k,-k,0); + glNormal3f (1,0,1); + glVertex3f ( k, k,0); + glNormal3f (0,1,1); + glVertex3f (-k, k,0); + glNormal3f (-1,0,1); + glVertex3f (-k,-k,0); + glEnd(); + glPopMatrix(); + } + } +} + + +void dsDrawFrame (int width, int height, dsFunctions *fn, int pause) +{ + if (current_state < 1) dsDebug ("internal error"); + current_state = 2; + + // setup stuff + glEnable (GL_LIGHTING); + glEnable (GL_LIGHT0); + glDisable (GL_TEXTURE_2D); + glDisable (GL_TEXTURE_GEN_S); + glDisable (GL_TEXTURE_GEN_T); + glShadeModel (GL_FLAT); + glEnable (GL_DEPTH_TEST); + glDepthFunc (GL_LESS); + glEnable (GL_CULL_FACE); + glCullFace (GL_BACK); + glFrontFace (GL_CCW); + + // setup viewport + glViewport (0,0,width,height); + glMatrixMode (GL_PROJECTION); + glLoadIdentity(); + const float vnear = 0.1f; + const float vfar = 100.0f; + const float k = 0.8f; // view scale, 1 = +/- 45 degrees + if (width >= height) { + float k2 = float(height)/float(width); + glFrustum (-vnear*k,vnear*k,-vnear*k*k2,vnear*k*k2,vnear,vfar); + } + else { + float k2 = float(width)/float(height); + glFrustum (-vnear*k*k2,vnear*k*k2,-vnear*k,vnear*k,vnear,vfar); + } + + // setup lights. it makes a difference whether this is done in the + // GL_PROJECTION matrix mode (lights are scene relative) or the + // GL_MODELVIEW matrix mode (lights are camera relative, bad!). + static GLfloat light_ambient[] = { 0.5, 0.5, 0.5, 1.0 }; + static GLfloat light_diffuse[] = { 1.0, 1.0, 1.0, 1.0 }; + static GLfloat light_specular[] = { 1.0, 1.0, 1.0, 1.0 }; + glLightfv (GL_LIGHT0, GL_AMBIENT, light_ambient); + glLightfv (GL_LIGHT0, GL_DIFFUSE, light_diffuse); + glLightfv (GL_LIGHT0, GL_SPECULAR, light_specular); + glColor3f (1.0, 1.0, 1.0); + + // clear the window + glClearColor (0.5,0.5,0.5,0); + glClear (GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); + + // snapshot camera position (in MS Windows it is changed by the GUI thread) + float view2_xyz[3]; + float view2_hpr[3]; + memcpy (view2_xyz,view_xyz,sizeof(float)*3); + memcpy (view2_hpr,view_hpr,sizeof(float)*3); + + // go to GL_MODELVIEW matrix mode and set the camera + glMatrixMode (GL_MODELVIEW); + glLoadIdentity(); + setCamera (view2_xyz[0],view2_xyz[1],view2_xyz[2], + view2_hpr[0],view2_hpr[1],view2_hpr[2]); + + // set the light position (for some reason we have to do this in model view. + static GLfloat light_position[] = { LIGHTX, LIGHTY, 1.0, 0.0 }; + glLightfv (GL_LIGHT0, GL_POSITION, light_position); + + // draw the background (ground, sky etc) + drawSky (view2_xyz); + drawGround(); + + // draw the little markers on the ground + drawPyramidGrid(); + + // leave openGL in a known state - flat shaded white, no textures + glEnable (GL_LIGHTING); + glDisable (GL_TEXTURE_2D); + glShadeModel (GL_FLAT); + glEnable (GL_DEPTH_TEST); + glDepthFunc (GL_LESS); + glColor3f (1,1,1); + setColor (1,1,1,1); + + // draw the rest of the objects. set drawing state first. + color[0] = 1; + color[1] = 1; + color[2] = 1; + color[3] = 1; + tnum = 0; + if (fn->step) fn->step (pause); +} + + +int dsGetShadows() +{ + return use_shadows; +} + + +void dsSetShadows (int a) +{ + use_shadows = (a != 0); +} + + +int dsGetTextures() +{ + return use_textures; +} + + +void dsSetTextures (int a) +{ + use_textures = (a != 0); +} + +//*************************************************************************** +// C interface + +// sets lighting and texture modes, sets current color +static void setupDrawingMode() +{ + glEnable (GL_LIGHTING); + if (tnum) { + if (use_textures) { + glEnable (GL_TEXTURE_2D); + texture[tnum]->bind (1); + glEnable (GL_TEXTURE_GEN_S); + glEnable (GL_TEXTURE_GEN_T); + glTexGeni (GL_S,GL_TEXTURE_GEN_MODE,GL_OBJECT_LINEAR); + glTexGeni (GL_T,GL_TEXTURE_GEN_MODE,GL_OBJECT_LINEAR); + static GLfloat s_params[4] = {1.0f,1.0f,0.0f,1}; + static GLfloat t_params[4] = {0.817f,-0.817f,0.817f,1}; + glTexGenfv (GL_S,GL_OBJECT_PLANE,s_params); + glTexGenfv (GL_T,GL_OBJECT_PLANE,t_params); + } + else { + glDisable (GL_TEXTURE_2D); + } + } + else { + glDisable (GL_TEXTURE_2D); + } + setColor (color[0],color[1],color[2],color[3]); + + if (color[3] < 1) { + glEnable (GL_BLEND); + glBlendFunc (GL_SRC_ALPHA,GL_ONE_MINUS_SRC_ALPHA); + } + else { + glDisable (GL_BLEND); + } +} + + +static void setShadowDrawingMode() +{ + glDisable (GL_LIGHTING); + if (use_textures) { + glEnable (GL_TEXTURE_2D); + ground_texture->bind (1); + glColor3f (SHADOW_INTENSITY,SHADOW_INTENSITY,SHADOW_INTENSITY); + glEnable (GL_TEXTURE_2D); + glEnable (GL_TEXTURE_GEN_S); + glEnable (GL_TEXTURE_GEN_T); + glTexGeni (GL_S,GL_TEXTURE_GEN_MODE,GL_EYE_LINEAR); + glTexGeni (GL_T,GL_TEXTURE_GEN_MODE,GL_EYE_LINEAR); + static GLfloat s_params[4] = {ground_scale,0,0,ground_ofsx}; + static GLfloat t_params[4] = {0,ground_scale,0,ground_ofsy}; + glTexGenfv (GL_S,GL_EYE_PLANE,s_params); + glTexGenfv (GL_T,GL_EYE_PLANE,t_params); + } + else { + glDisable (GL_TEXTURE_2D); + glColor3f (GROUND_R*SHADOW_INTENSITY,GROUND_G*SHADOW_INTENSITY, + GROUND_B*SHADOW_INTENSITY); + } + glDepthRange (0,0.9999); +} + + +extern "C" void dsSimulationLoop (int argc, char **argv, + int window_width, int window_height, + dsFunctions *fn) +{ + if (current_state != 0) dsError ("dsSimulationLoop() called more than once"); + current_state = 1; + + // look for flags that apply to us + int initial_pause = 0; + for (int i=1; ipath_to_textures = argv[i]; + } + + if (fn->version > DS_VERSION) + dsDebug ("bad version number in dsFunctions structure"); + + initMotionModel(); + dsPlatformSimLoop (window_width,window_height,fn,initial_pause); + + current_state = 0; +} + + +extern "C" void dsSetViewpoint (float xyz[3], float hpr[3]) +{ + if (current_state < 1) dsError ("dsSetViewpoint() called before simulation started"); + if (xyz) { + view_xyz[0] = xyz[0]; + view_xyz[1] = xyz[1]; + view_xyz[2] = xyz[2]; + } + if (hpr) { + view_hpr[0] = hpr[0]; + view_hpr[1] = hpr[1]; + view_hpr[2] = hpr[2]; + wrapCameraAngles(); + } +} + + +extern "C" void dsGetViewpoint (float xyz[3], float hpr[3]) +{ + if (current_state < 1) dsError ("dsGetViewpoint() called before simulation started"); + if (xyz) { + xyz[0] = view_xyz[0]; + xyz[1] = view_xyz[1]; + xyz[2] = view_xyz[2]; + } + if (hpr) { + hpr[0] = view_hpr[0]; + hpr[1] = view_hpr[1]; + hpr[2] = view_hpr[2]; + } +} + + +extern "C" void dsSetTexture (int texture_number) +{ + if (current_state != 2) dsError ("drawing function called outside simulation loop"); + tnum = texture_number; +} + + +extern "C" void dsSetColor (float red, float green, float blue) +{ + if (current_state != 2) dsError ("drawing function called outside simulation loop"); + color[0] = red; + color[1] = green; + color[2] = blue; + color[3] = 1; +} + + +extern "C" void dsSetColorAlpha (float red, float green, float blue, + float alpha) +{ + if (current_state != 2) dsError ("drawing function called outside simulation loop"); + color[0] = red; + color[1] = green; + color[2] = blue; + color[3] = alpha; +} + + +extern "C" void dsDrawBox (const float pos[3], const float R[12], + const float sides[3]) +{ + if (current_state != 2) dsError ("drawing function called outside simulation loop"); + setupDrawingMode(); + glShadeModel (GL_FLAT); + setTransform (pos,R); + drawBox (sides); + glPopMatrix(); + + if (use_shadows) { + setShadowDrawingMode(); + setShadowTransform(); + setTransform (pos,R); + drawBox (sides); + glPopMatrix(); + glPopMatrix(); + glDepthRange (0,1); + } +} + +extern "C" void dsDrawConvex (const float pos[3], const float R[12], + const float *_planes,unsigned int _planecount, + const float *_points, unsigned int _pointcount, + const unsigned int *_polygons) +{ + if (current_state != 2) dsError ("drawing function called outside simulation loop"); + setupDrawingMode(); + glShadeModel (GL_FLAT); + setTransform (pos,R); + drawConvex(_planes,_planecount,_points,_pointcount,_polygons); + glPopMatrix(); + if (use_shadows) { + setShadowDrawingMode(); + setShadowTransform(); + setTransform (pos,R); + drawConvex(_planes,_planecount,_points,_pointcount,_polygons); + glPopMatrix(); + glPopMatrix(); + glDepthRange (0,1); + } +} + + +extern "C" void dsDrawSphere (const float pos[3], const float R[12], + float radius) +{ + if (current_state != 2) dsError ("drawing function called outside simulation loop"); + setupDrawingMode(); + glEnable (GL_NORMALIZE); + glShadeModel (GL_SMOOTH); + setTransform (pos,R); + glScaled (radius,radius,radius); + drawSphere(); + glPopMatrix(); + glDisable (GL_NORMALIZE); + + // draw shadows + if (use_shadows) { + glDisable (GL_LIGHTING); + if (use_textures) { + ground_texture->bind (1); + glEnable (GL_TEXTURE_2D); + glDisable (GL_TEXTURE_GEN_S); + glDisable (GL_TEXTURE_GEN_T); + glColor3f (SHADOW_INTENSITY,SHADOW_INTENSITY,SHADOW_INTENSITY); + } + else { + glDisable (GL_TEXTURE_2D); + glColor3f (GROUND_R*SHADOW_INTENSITY,GROUND_G*SHADOW_INTENSITY, + GROUND_B*SHADOW_INTENSITY); + } + glShadeModel (GL_FLAT); + glDepthRange (0,0.9999); + drawSphereShadow (pos[0],pos[1],pos[2],radius); + glDepthRange (0,1); + } +} + + +extern "C" void dsDrawTriangle (const float pos[3], const float R[12], + const float *v0, const float *v1, + const float *v2, int solid) +{ + if (current_state != 2) dsError ("drawing function called outside simulation loop"); + setupDrawingMode(); + glShadeModel (GL_FLAT); + setTransform (pos,R); + drawTriangle (v0, v1, v2, solid); + glPopMatrix(); +} + + +extern "C" void dsDrawTriangles (const float pos[3], const float R[12], + const float *v, int n, int solid) +{ + if (current_state != 2) dsError ("drawing function called outside simulation loop"); + setupDrawingMode(); + glShadeModel (GL_FLAT); + setTransform (pos,R); + int i; + for (i = 0; i < n; ++i, v += 9) + drawTriangle (v, v + 3, v + 6, solid); + glPopMatrix(); +} + + +extern "C" void dsDrawCylinder (const float pos[3], const float R[12], + float length, float radius) +{ + if (current_state != 2) dsError ("drawing function called outside simulation loop"); + setupDrawingMode(); + glShadeModel (GL_SMOOTH); + setTransform (pos,R); + drawCylinder (length,radius,0); + glPopMatrix(); + + if (use_shadows) { + setShadowDrawingMode(); + setShadowTransform(); + setTransform (pos,R); + drawCylinder (length,radius,0); + glPopMatrix(); + glPopMatrix(); + glDepthRange (0,1); + } +} + + +extern "C" void dsDrawCapsule (const float pos[3], const float R[12], + float length, float radius) +{ + if (current_state != 2) dsError ("drawing function called outside simulation loop"); + setupDrawingMode(); + glShadeModel (GL_SMOOTH); + setTransform (pos,R); + drawCapsule (length,radius); + glPopMatrix(); + + if (use_shadows) { + setShadowDrawingMode(); + setShadowTransform(); + setTransform (pos,R); + drawCapsule (length,radius); + glPopMatrix(); + glPopMatrix(); + glDepthRange (0,1); + } +} + + +static void drawLine(const float pos1[3], const float pos2[3]) +{ + glDisable (GL_LIGHTING); + glLineWidth (2); + glShadeModel (GL_FLAT); + glBegin (GL_LINES); + glVertex3f (pos1[0],pos1[1],pos1[2]); + glVertex3f (pos2[0],pos2[1],pos2[2]); + glEnd(); +} + + +extern "C" void dsDrawLine (const float pos1[3], const float pos2[3]) +{ + setupDrawingMode(); + glColor4f(color[0], color[1], color[2], color[3]); + drawLine(pos1, pos2); + + if (use_shadows) { + setShadowDrawingMode(); + setShadowTransform(); + + drawLine(pos1, pos2); + + glPopMatrix(); + glDepthRange (0,1); + } +} + + +extern "C" void dsDrawBoxD (const double pos[3], const double R[12], + const double sides[3]) +{ + int i; + float pos2[3],R2[12],fsides[3]; + for (i=0; i<3; i++) pos2[i]=(float)pos[i]; + for (i=0; i<12; i++) R2[i]=(float)R[i]; + for (i=0; i<3; i++) fsides[i]=(float)sides[i]; + dsDrawBox (pos2,R2,fsides); +} + +extern "C" void dsDrawConvexD (const double pos[3], const double R[12], + const double *_planes, unsigned int _planecount, + const double *_points, unsigned int _pointcount, + const unsigned int *_polygons) +{ + if (current_state != 2) dsError ("drawing function called outside simulation loop"); + setupDrawingMode(); + glShadeModel (GL_FLAT); + setTransformD (pos,R); + drawConvexD(_planes,_planecount,_points,_pointcount,_polygons); + glPopMatrix(); + if (use_shadows) { + setShadowDrawingMode(); + setShadowTransform(); + setTransformD (pos,R); + drawConvexD(_planes,_planecount,_points,_pointcount,_polygons); + glPopMatrix(); + glPopMatrix(); + glDepthRange (0,1); + } +} + +void dsDrawSphereD (const double pos[3], const double R[12], float radius) +{ + int i; + float pos2[3],R2[12]; + for (i=0; i<3; i++) pos2[i]=(float)pos[i]; + for (i=0; i<12; i++) R2[i]=(float)R[i]; + dsDrawSphere (pos2,R2,radius); +} + + +void dsDrawTriangleD (const double pos[3], const double R[12], + const double *v0, const double *v1, + const double *v2, int solid) +{ + int i; + float pos2[3],R2[12]; + for (i=0; i<3; i++) pos2[i]=(float)pos[i]; + for (i=0; i<12; i++) R2[i]=(float)R[i]; + + setupDrawingMode(); + glShadeModel (GL_FLAT); + setTransform (pos2,R2); + drawTriangleD (v0, v1, v2, solid); + glPopMatrix(); +} + + +extern "C" void dsDrawTrianglesD (const double pos[3], const double R[12], + const double *v, int n, int solid) +{ + int i; + float pos2[3],R2[12]; + for (i=0; i<3; i++) pos2[i]=(float)pos[i]; + for (i=0; i<12; i++) R2[i]=(float)R[i]; + + if (current_state != 2) dsError ("drawing function called outside simulation loop"); + setupDrawingMode(); + glShadeModel (GL_FLAT); + setTransform (pos2,R2); + for (i = 0; i < n; ++i, v += 9) + drawTriangleD (v, v + 3, v + 6, solid); + glPopMatrix(); +} + + +void dsDrawCylinderD (const double pos[3], const double R[12], + float length, float radius) +{ + int i; + float pos2[3],R2[12]; + for (i=0; i<3; i++) pos2[i]=(float)pos[i]; + for (i=0; i<12; i++) R2[i]=(float)R[i]; + dsDrawCylinder (pos2,R2,length,radius); +} + + +void dsDrawCapsuleD (const double pos[3], const double R[12], + float length, float radius) +{ + int i; + float pos2[3],R2[12]; + for (i=0; i<3; i++) pos2[i]=(float)pos[i]; + for (i=0; i<12; i++) R2[i]=(float)R[i]; + dsDrawCapsule (pos2,R2,length,radius); +} + + +void dsDrawLineD (const double _pos1[3], const double _pos2[3]) +{ + int i; + float pos1[3],pos2[3]; + for (i=0; i<3; i++) pos1[i]=(float)_pos1[i]; + for (i=0; i<3; i++) pos2[i]=(float)_pos2[i]; + dsDrawLine (pos1,pos2); +} + + +void dsSetSphereQuality (int n) +{ + sphere_quality = n; +} + + +void dsSetCapsuleQuality (int n) +{ + capped_cylinder_quality = n; +} + +void dsSetDrawMode(int mode) +{ + switch(mode) + { + case DS_POLYFILL: + glPolygonMode(GL_FRONT,GL_FILL); + break; + case DS_WIREFRAME: + glPolygonMode(GL_FRONT,GL_LINE); + break; + } +} diff --git a/libs/ode-0.16.1/drawstuff/src/internal.h b/libs/ode-0.16.1/drawstuff/src/internal.h new file mode 100644 index 0000000..de1aa11 --- /dev/null +++ b/libs/ode-0.16.1/drawstuff/src/internal.h @@ -0,0 +1,50 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +/* functions supplied and used by the platform specific code */ + +#ifndef __DS_INTERNAL_H +#define __DS_INTERNAL_H + +#include "drawstuff/drawstuff.h" + + +// supplied by platform specific code + +void dsPlatformSimLoop (int window_width, int window_height, + dsFunctions *fn, int initial_pause); + + +// used by platform specific code + +void dsStartGraphics (int width, int height, dsFunctions *fn); +void dsDrawFrame (int width, int height, dsFunctions *fn, int pause); +void dsStopGraphics(); +void dsMotion (int mode, int deltax, int deltay); + +int dsGetShadows(); +void dsSetShadows (int a); + +int dsGetTextures(); +void dsSetTextures (int a); + +#endif diff --git a/libs/ode-0.16.1/drawstuff/src/osx.cpp b/libs/ode-0.16.1/drawstuff/src/osx.cpp new file mode 100644 index 0000000..bc69bfe --- /dev/null +++ b/libs/ode-0.16.1/drawstuff/src/osx.cpp @@ -0,0 +1,347 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +// Platform-specific code for Mac OS X using Carbon+AGL +// +// Created using x11.cpp and the window-initialization -routines from GLFW +// as reference. +// Not thoroughly tested and is certain to contain deficiencies and bugs + +#include +#include +#include +#include +#include "config.h" +#include "common.h" + +#ifdef HAVE_SYS_TIME_H +#include +#endif + +#include +#include +#include "internal.h" + +#include +#include + +// Global variables + +static bool paused = false; // 1 if in `pause' mode +static bool singlestep = false; // 1 if single step key pressed +static bool writeframes = false; // 1 if frame files to be written + +static int windowWidth = -1; +static int windowHeight = -1; +static int mouseButtonMode = 0; +static bool mouseWithOption = false; // Set if dragging the mouse with alt pressed +static bool mouseWithControl = false; // Set if dragging the mouse with ctrl pressed + +static dsFunctions* functions = NULL; +static int windowReference; +static int frame = 1; +static int prev_x = 0; +static int prev_y = 0; + +//*************************************************************************** +// error handling for unix + +static void printMessage (const char *msg1, const char *msg2, va_list ap) +{ + fflush (stderr); + fflush (stdout); + fprintf (stderr,"\n%s: ",msg1); + vfprintf (stderr,msg2,ap); + fprintf (stderr,"\n"); + fflush (stderr); +} + +extern "C" void dsError (const char *msg, ...) +{ + va_list ap; + va_start (ap,msg); + printMessage ("Error",msg,ap); + va_end (ap); + exit (1); +} + + +extern "C" void dsDebug (const char *msg, ...) +{ + va_list ap; + va_start (ap,msg); + printMessage ("INTERNAL ERROR",msg,ap); + va_end (ap); + // *((char *)0) = 0; ... commit SEGVicide ? + abort(); +} + +extern "C" void dsPrint (const char *msg, ...) +{ + va_list ap; + va_start (ap,msg); + vprintf (msg,ap); + va_end (ap); +} + +static void captureFrame( int num ){ + + fprintf( stderr,"\rcapturing frame %04d", num ); + unsigned char buffer[windowWidth*windowHeight][3]; + glReadPixels( 0, 0, windowWidth, windowHeight, GL_RGB, GL_UNSIGNED_BYTE, &buffer ); + char s[100]; + sprintf (s,"frame%04d.ppm",num); + FILE *f = fopen (s,"wb"); + if( !f ){ + dsError( "can't open \"%s\" for writing", s ); + } + fprintf( f,"P6\n%d %d\n255\n", windowWidth, windowHeight ); + for( int y=windowHeight-1; y>-1; y-- ){ + fwrite( buffer[y*windowWidth], 3*windowWidth, 1, f ); + } + fclose (f); +} + +extern "C" void dsStop() +{ +} + +extern "C" double dsElapsedTime() +{ +#if HAVE_GETTIMEOFDAY + static double prev=0.0; + timeval tv ; + + gettimeofday(&tv, 0); + double curr = tv.tv_sec + (double) tv.tv_usec / 1000000.0 ; + if (!prev) + prev=curr; + double retval = curr-prev; + prev=curr; + if (retval>1.0) retval=1.0; + if (retval= 'a' && key <= 'z') + uppercase = key - ('a' - 'A'); + else + uppercase = key; + + int modifierMask = osxGetModifierMask(); + if (modifierMask == 0) + { + if( key >= ' ' && key <= 126 && functions -> command ) + functions -> command( key ); + } + else if (modifierMask & GLUT_ACTIVE_CTRL) + { + // ctrl+key was pressed + uppercase += 'A' - 1; + switch(uppercase ){ + case 'T': + dsSetTextures( !dsGetTextures() ); + break; + case 'S': + dsSetShadows( !dsGetShadows() ); + break; + case 'X': + exit(0); + break; + case 'P': + paused = !paused; + singlestep = false; + break; + case 'O': + if( paused ){ + singlestep = true; + } + break; + case 'V': { + float xyz[3],hpr[3]; + dsGetViewpoint( xyz,hpr ); + printf( "Viewpoint = (%.4f,%.4f,%.4f,%.4f,%.4f,%.4f)\n", xyz[0], xyz[1], xyz[2], hpr[0], hpr[1], hpr[2] ); + break; + } + case 'W': + writeframes = !writeframes; + if( writeframes ){ + printf( "Now writing frames to PPM files\n" ); + } + break; + } + } +} + +void osxMouseEventHandler(int button, int state, int x, int y) +{ + prev_x = x; + prev_y = y; + bool buttonDown = false; + switch( state ){ + case GLUT_DOWN: + buttonDown = true; + case GLUT_UP: + if( button == GLUT_LEFT_BUTTON ){ + int modifierMask = osxGetModifierMask(); + if( modifierMask & GLUT_ACTIVE_CTRL ){ + // Ctrl+button == right + button = GLUT_RIGHT_BUTTON; + mouseWithControl = true; + } + else if( modifierMask & GLUT_ACTIVE_ALT ){ + // Alt+button == left+right + mouseButtonMode = 5; + mouseWithOption = true; + return; + } + } + if( buttonDown ){ + if( button == GLUT_LEFT_BUTTON ) mouseButtonMode |= 1; // Left + if( button == GLUT_MIDDLE_BUTTON ) mouseButtonMode |= 2; // Middle + if( button == GLUT_RIGHT_BUTTON ) mouseButtonMode |= 4; // Right + } + else{ + if( button == GLUT_LEFT_BUTTON ) mouseButtonMode &= (~1); // Left + if( button == GLUT_MIDDLE_BUTTON ) mouseButtonMode &= (~2); // Middle + if( button == GLUT_RIGHT_BUTTON ) mouseButtonMode &= (~4); // Right + } + return; + } +} + +void osxMotionEventHandler(int x, int y) +{ + dsMotion( mouseButtonMode, x - prev_x, y - prev_y ); + prev_x = x; + prev_y = y; +} + +void osxWindowReshapeEventHandler(int width, int height) +{ + windowWidth = width; + windowHeight = height; +} + +static void osxCreateMainWindow( int width, int height ) +{ + int argc = 1; + char* argv[2]; + argv[0] = (char*)""; + argv[1] = NULL; + glutInit(&argc, argv); + glutInitDisplayMode(GLUT_RGBA | GLUT_DOUBLE | GLUT_DEPTH); + glutInitWindowSize(width, height); + + windowReference = glutCreateWindow("ODE - Drawstuff"); + windowWidth = width; + windowHeight = height; +} + +void osxRedisplayEventHandler() +{ + dsDrawFrame( windowWidth, windowHeight, functions, paused && !singlestep ); + singlestep = false; + glutSwapBuffers(); + + // capture frames if necessary + if( !paused && writeframes ){ + captureFrame( frame ); + frame++; + } +} + +void osxTimerEventHandler(int); + +void osxInstallTimerHandler() +{ + glutTimerFunc(1000/60, osxTimerEventHandler, 0); +} + +void osxTimerEventHandler(int) +{ + glutPostRedisplay(); + osxInstallTimerHandler(); +} + +int osxInstallEventHandlers() +{ + glutKeyboardFunc(osxKeyEventHandler); + glutMouseFunc(osxMouseEventHandler); + glutMotionFunc(osxMotionEventHandler); + glutDisplayFunc(osxRedisplayEventHandler); + glutReshapeFunc(osxWindowReshapeEventHandler); + osxInstallTimerHandler(); + return GL_TRUE; +} + +extern void dsPlatformSimLoop( int givenWindowWidth, int givenWindowHeight, dsFunctions *fn, int givenPause ){ + + functions = fn; + + paused = givenPause; + + osxCreateMainWindow( givenWindowWidth, givenWindowHeight ); + osxInstallEventHandlers(); + + dsStartGraphics( windowWidth, windowHeight, fn ); + + static bool firsttime=true; + if( firsttime ) + { + fprintf + ( + stderr, + "\n" + "Simulation test environment v%d.%02d\n" + " Ctrl-P : pause / unpause (or say `-pause' on command line).\n" + " Ctrl-O : single step when paused.\n" + " Ctrl-T : toggle textures (or say `-notex' on command line).\n" + " Ctrl-S : toggle shadows (or say `-noshadow' on command line).\n" + " Ctrl-V : print current viewpoint coordinates (x,y,z,h,p,r).\n" + " Ctrl-W : write frames to ppm files: frame/frameNNN.ppm\n" + " Ctrl-X : exit.\n" + "\n" + "Change the camera position by clicking + dragging in the window.\n" + " Left button - pan and tilt.\n" + " Right button (or Ctrl + button) - forward and sideways.\n" + " Left + Right button (or middle button, or Alt + button) - sideways and up.\n" + "\n",DS_VERSION >> 8,DS_VERSION & 0xff + ); + firsttime = false; + } + + if( fn -> start ) fn->start(); + + glutMainLoop(); +} diff --git a/libs/ode-0.16.1/drawstuff/src/resource.h b/libs/ode-0.16.1/drawstuff/src/resource.h new file mode 100644 index 0000000..15802b6 --- /dev/null +++ b/libs/ode-0.16.1/drawstuff/src/resource.h @@ -0,0 +1,28 @@ +//{{NO_DEPENDENCIES}} +// Microsoft Developer Studio generated include file. +// Used by resources.rc +// +#define IDD_MSGDLG 101 +#define IDR_MENU1 102 +#define IDD_ABOUT 103 +#define IDR_ACCELERATOR1 104 +#define IDC_LIST1 1000 +#define IDM_EXIT 40001 +#define IDM_ABOUT 40002 +#define IDM_PAUSE 40003 +#define IDM_PERF_MONITOR 40004 +#define IDM_SHADOWS 40005 +#define IDM_TEXTURES 40006 +#define IDM_SAVE_SETTINGS 40007 +#define IDM_SINGLE_STEP 40008 + +// Next default values for new objects +// +#ifdef APSTUDIO_INVOKED +#ifndef APSTUDIO_READONLY_SYMBOLS +#define _APS_NEXT_RESOURCE_VALUE 108 +#define _APS_NEXT_COMMAND_VALUE 40009 +#define _APS_NEXT_CONTROL_VALUE 1001 +#define _APS_NEXT_SYMED_VALUE 101 +#endif +#endif diff --git a/libs/ode-0.16.1/drawstuff/src/resources.rc b/libs/ode-0.16.1/drawstuff/src/resources.rc new file mode 100644 index 0000000..61611f7 --- /dev/null +++ b/libs/ode-0.16.1/drawstuff/src/resources.rc @@ -0,0 +1,153 @@ +//Microsoft Developer Studio generated resource script. +// +#include "resource.h" + +#define APSTUDIO_READONLY_SYMBOLS +///////////////////////////////////////////////////////////////////////////// +// +// Generated from the TEXTINCLUDE 2 resource. +// +//#include "afxres.h" + +// added by RLS to make this work with windres +#include "winresrc.h" +#define IDC_STATIC (-1) + +///////////////////////////////////////////////////////////////////////////// +#undef APSTUDIO_READONLY_SYMBOLS + +///////////////////////////////////////////////////////////////////////////// +// English (U.S.) resources + +#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU) +#ifdef _WIN32 +LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US +#pragma code_page(1252) +#endif //_WIN32 + +///////////////////////////////////////////////////////////////////////////// +// +// Dialog +// + +IDD_ABOUT DIALOG DISCARDABLE 0, 0, 257, 105 +STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU +CAPTION "About" +FONT 8, "MS Sans Serif" +BEGIN + DEFPUSHBUTTON "OK",IDOK,200,84,50,14 + LTEXT "Simulation test environment",IDC_STATIC,7,7,243,8 + LTEXT "Change the camera position by clicking + dragging in the main window.", + IDC_STATIC,7,24,243,8 + LTEXT "Left button - pan and tilt.",IDC_STATIC,25,37,225,8 + LTEXT "Right button - forward and sideways.",IDC_STATIC,25,48, + 225,8 + LTEXT "Left + Right button (or middle button) - sideways and up.", + IDC_STATIC,25,59,225,8 +END + + +#ifdef APSTUDIO_INVOKED +///////////////////////////////////////////////////////////////////////////// +// +// TEXTINCLUDE +// + +1 TEXTINCLUDE DISCARDABLE +BEGIN + "resource.h\0" +END + +2 TEXTINCLUDE DISCARDABLE +BEGIN + //"#include ""afxres.h""\r\n" + "\0" +END + +3 TEXTINCLUDE DISCARDABLE +BEGIN + "\r\n" + "\0" +END + +#endif // APSTUDIO_INVOKED + + +///////////////////////////////////////////////////////////////////////////// +// +// Menu +// + +IDR_MENU1 MENU DISCARDABLE +BEGIN + POPUP "&File" + BEGIN + MENUITEM "&Exit\tCtrl+X", IDM_EXIT + END + POPUP "&Simulation" + BEGIN + MENUITEM "&Pause\tCtrl+P", IDM_PAUSE + MENUITEM "Single Step\tCtrl+O", IDM_SINGLE_STEP + MENUITEM "Performance &Monitor", IDM_PERF_MONITOR, GRAYED + MENUITEM SEPARATOR + MENUITEM "&Shadows\tCtrl+S", IDM_SHADOWS, CHECKED + MENUITEM "&Textures\tCtrl+T", IDM_TEXTURES, CHECKED + MENUITEM SEPARATOR + MENUITEM "S&ave Settings", IDM_SAVE_SETTINGS, GRAYED + END + POPUP "&Help" + BEGIN + MENUITEM "&About", IDM_ABOUT + END +END + + +///////////////////////////////////////////////////////////////////////////// +// +// DESIGNINFO +// + +#ifdef APSTUDIO_INVOKED +GUIDELINES DESIGNINFO DISCARDABLE +BEGIN + IDD_ABOUT, DIALOG + BEGIN + LEFTMARGIN, 7 + RIGHTMARGIN, 250 + VERTGUIDE, 25 + TOPMARGIN, 7 + BOTTOMMARGIN, 98 + END +END +#endif // APSTUDIO_INVOKED + + +///////////////////////////////////////////////////////////////////////////// +// +// Accelerator +// + +IDR_ACCELERATOR1 ACCELERATORS DISCARDABLE +BEGIN + "O", IDM_SINGLE_STEP, VIRTKEY, CONTROL, NOINVERT + "P", IDM_PAUSE, VIRTKEY, CONTROL, NOINVERT + "S", IDM_SHADOWS, VIRTKEY, CONTROL, NOINVERT + "T", IDM_TEXTURES, VIRTKEY, CONTROL, NOINVERT + "X", IDM_EXIT, VIRTKEY, CONTROL, NOINVERT +END + +#endif // English (U.S.) resources +///////////////////////////////////////////////////////////////////////////// + + + +#ifndef APSTUDIO_INVOKED +///////////////////////////////////////////////////////////////////////////// +// +// Generated from the TEXTINCLUDE 3 resource. +// + + +///////////////////////////////////////////////////////////////////////////// +#endif // not APSTUDIO_INVOKED + diff --git a/libs/ode-0.16.1/drawstuff/src/windows.cpp b/libs/ode-0.16.1/drawstuff/src/windows.cpp new file mode 100644 index 0000000..b136ddc --- /dev/null +++ b/libs/ode-0.16.1/drawstuff/src/windows.cpp @@ -0,0 +1,536 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#if defined(WIN32) || defined(__CYGWIN__)// this prevents warnings when dependencies built +#include +#endif +#include +#include +#include + +#include "config.h" +#include "common.h" +#include "resource.h" +#include "internal.h" + +//*************************************************************************** +// application globals + +static HINSTANCE ghInstance = 0; +static int gnCmdShow = 0; +static HACCEL accelerators = 0; +static HWND main_window = 0; + +//*************************************************************************** +// error and message handling + +static void errorBox (const char *title, const char *msg, va_list ap) +{ + char s[1000]; + vsprintf (s,msg,ap); + MessageBox (0,s,title,MB_OK | MB_APPLMODAL | MB_ICONEXCLAMATION); +} + + +static void dsWarning (const char *msg, ...) +{ + va_list ap; + va_start (ap,msg); + errorBox ("Warning",msg,ap); + va_end (ap); +} + + +extern "C" void dsError (const char *msg, ...) +{ + va_list ap; + va_start (ap,msg); + errorBox ("Error",msg,ap); + va_end (ap); + exit (1); +} + + +extern "C" void dsDebug (const char *msg, ...) +{ + va_list ap; + va_start (ap,msg); + errorBox ("INTERNAL ERROR",msg,ap); + va_end (ap); + // *((char *)0) = 0; ... commit SEGVicide ? + abort(); + exit (1); // should never get here, but just in case... +} + + +extern "C" void dsPrint (const char *msg, ...) +{ + va_list ap; + va_start (ap,msg); + vprintf (msg,ap); + va_end (ap); +} + +//*************************************************************************** +// rendering thread + +// globals used to communicate with rendering thread + +static volatile int renderer_run = 1; +static volatile int renderer_pause = 0; // 0=run, 1=pause +static volatile int renderer_ss = 0; // single step command +static volatile int renderer_width = 1; +static volatile int renderer_height = 1; +static dsFunctions *renderer_fn = 0; +static volatile HDC renderer_dc = 0; +static volatile int keybuffer[16]; // fifo ring buffer for keypresses +static volatile int keybuffer_head = 0; // index of next key to put in (modified by GUI) +static volatile int keybuffer_tail = 0; // index of next key to take out (modified by renderer) + + +static void setupRendererGlobals() +{ + renderer_run = 1; + renderer_pause = 0; + renderer_ss = 0; + renderer_width = 1; + renderer_height = 1; + renderer_fn = 0; + renderer_dc = 0; + keybuffer[16]; + keybuffer_head = 0; + keybuffer_tail = 0; +} + + +static unsigned CALLBACK renderingThread (LPVOID lpParam) +{ + // create openGL context and make it current + HGLRC glc = wglCreateContext (renderer_dc); + if (glc==NULL) dsError ("could not create OpenGL context"); + if (wglMakeCurrent (renderer_dc,glc) != TRUE) + dsError ("could not make OpenGL context current"); + + // test openGL capabilities + int maxtsize=0; + glGetIntegerv (GL_MAX_TEXTURE_SIZE,&maxtsize); + if (maxtsize < 128) dsWarning ("max texture size too small (%dx%d)", + maxtsize,maxtsize); + + dsStartGraphics (renderer_width,renderer_height,renderer_fn); + if (renderer_fn->start) renderer_fn->start(); + + while (renderer_run) { + // need to make local copy of renderer_ss to help prevent races + int ss = renderer_ss; + dsDrawFrame (renderer_width,renderer_height,renderer_fn, + renderer_pause && !ss); + if (ss) renderer_ss = 0; + + // read keys out of ring buffer and feed them to the command function + while (keybuffer_head != keybuffer_tail) { + if (renderer_fn->command) renderer_fn->command (keybuffer[keybuffer_tail]); + keybuffer_tail = (keybuffer_tail+1) & 15; + } + + // swap buffers + SwapBuffers (renderer_dc); + } + + if (renderer_fn->stop) renderer_fn->stop(); + dsStopGraphics(); + + // delete openGL context + wglMakeCurrent (NULL,NULL); + wglDeleteContext (glc); + + return 123; // magic value used to test for thread termination +} + +//*************************************************************************** +// window handling + +// callback function for "about" dialog box + +static LRESULT CALLBACK AboutDlgProc (HWND hDlg, UINT uMsg, WPARAM wParam, + LPARAM lParam) +{ + switch (uMsg) { + case WM_INITDIALOG: + return TRUE; + case WM_COMMAND: + switch (wParam) { + case IDOK: + EndDialog (hDlg, TRUE); + return TRUE; + } + break; + } + return FALSE; +} + + +// callback function for the main window + +static LRESULT CALLBACK mainWndProc (HWND hWnd, UINT msg, WPARAM wParam, + LPARAM lParam) +{ + static int button=0,lastx=0,lasty=0; + int ctrl = int(wParam & MK_CONTROL); + + switch (msg) { + case WM_LBUTTONDOWN: + case WM_MBUTTONDOWN: + case WM_RBUTTONDOWN: + if (msg==WM_LBUTTONDOWN) button |= 1; + else if (msg==WM_MBUTTONDOWN) button |= 2; + else button |= 4; + lastx = SHORT(LOWORD(lParam)); + lasty = SHORT(HIWORD(lParam)); + SetCapture (hWnd); + break; + + case WM_LBUTTONUP: + case WM_MBUTTONUP: + case WM_RBUTTONUP: + if (msg==WM_LBUTTONUP) button &= ~1; + else if (msg==WM_MBUTTONUP) button &= ~2; + else button &= ~4; + if (button==0) ReleaseCapture(); + break; + + case WM_MOUSEMOVE: { + int x = SHORT(LOWORD(lParam)); + int y = SHORT(HIWORD(lParam)); + if (button) dsMotion (button,x-lastx,y-lasty); + lastx = x; + lasty = y; + break; + } + + case WM_CHAR: { + if (wParam >= ' ' && wParam <= 126) { + int nexth = (keybuffer_head+1) & 15; + if (nexth != keybuffer_tail) { + keybuffer[keybuffer_head] = int(wParam); + keybuffer_head = nexth; + } + } + break; + } + + case WM_SIZE: + // lParam will contain the size of the *client* area! + renderer_width = LOWORD(lParam); + renderer_height = HIWORD(lParam); + break; + + case WM_COMMAND: + switch (wParam & 0xffff) { + case IDM_ABOUT: + DialogBox (ghInstance,MAKEINTRESOURCE(IDD_ABOUT),hWnd, + (DLGPROC) AboutDlgProc); + break; + case IDM_PAUSE: { + renderer_pause ^= 1; + CheckMenuItem (GetMenu(hWnd),IDM_PAUSE, + renderer_pause ? MF_CHECKED : MF_UNCHECKED); + if (renderer_pause) renderer_ss = 0; + break; + } + case IDM_SINGLE_STEP: { + if (renderer_pause) + renderer_ss = 1; + else + SendMessage( hWnd, WM_COMMAND, IDM_PAUSE, 0 ); + break; + } + case IDM_PERF_MONITOR: { + dsWarning ("Performance monitor not yet implemented."); + break; + } + case IDM_TEXTURES: { + static int tex = 1; + tex ^= 1; + CheckMenuItem (GetMenu(hWnd),IDM_TEXTURES, + tex ? MF_CHECKED : MF_UNCHECKED); + dsSetTextures (tex); + break; + } + case IDM_SHADOWS: { + static int shadows = 1; + shadows ^= 1; + CheckMenuItem (GetMenu(hWnd),IDM_SHADOWS, + shadows ? MF_CHECKED : MF_UNCHECKED); + dsSetShadows (shadows); + break; + } + case IDM_SAVE_SETTINGS: { + dsWarning ("\"Save Settings\" not yet implemented."); + break; + } + case IDM_EXIT: + PostQuitMessage (0); + break; + } + break; + + case WM_CLOSE: + PostQuitMessage (0); + break; + + default: + return (DefWindowProc (hWnd, msg, wParam, lParam)); + } + + return 0; +} + + +// this comes from an MSDN example. believe it or not, this is the recommended +// way to get the console window handle. + +static HWND GetConsoleHwnd() +{ + // the console window title to a "unique" value, then find the window + // that has this title. + char title[1024]; + wsprintf (title,"DrawStuff:%d/%d",GetTickCount(),GetCurrentProcessId()); + SetConsoleTitle (title); + Sleep(40); // ensure window title has been updated + return FindWindow (NULL,title); +} + + +static void drawStuffStartup() +{ + static int startup_called = 0; + if (startup_called) return; + startup_called = 1; + if (!ghInstance) + ghInstance = GetModuleHandleA (NULL); + gnCmdShow = SW_SHOWNORMAL; // @@@ fix this later + + // redirect standard I/O to a new console (except on cygwin and mingw) +#if !defined(__CYGWIN__) && !defined(__MINGW32__) + FreeConsole(); + if (AllocConsole()==0) dsError ("AllocConsole() failed"); + if (freopen ("CONIN$","rt",stdin)==0) dsError ("could not open stdin"); + if (freopen ("CONOUT$","wt",stdout)==0) dsError ("could not open stdout"); + if (freopen ("CONOUT$","wt",stderr)==0) dsError ("could not open stderr"); + BringWindowToTop (GetConsoleHwnd()); + SetConsoleTitle ("DrawStuff Messages"); +#endif + + // register the window class + WNDCLASS wc; + wc.style = CS_OWNDC | CS_VREDRAW | CS_HREDRAW; + wc.lpfnWndProc = mainWndProc; + wc.cbClsExtra = 0; + wc.cbWndExtra = 0; + wc.hInstance = ghInstance; + wc.hIcon = LoadIcon (NULL,IDI_APPLICATION); + wc.hCursor = LoadCursor (NULL,IDC_ARROW); + wc.hbrBackground = (HBRUSH) (COLOR_WINDOW+1); + wc.lpszMenuName = MAKEINTRESOURCE(IDR_MENU1); + wc.lpszClassName = "SimAppClass"; + if (RegisterClass (&wc)==0) dsError ("could not register window class"); + + // load accelerators + accelerators = LoadAccelerators (ghInstance, + MAKEINTRESOURCE(IDR_ACCELERATOR1)); + if (accelerators==NULL) dsError ("could not load accelerators"); +} + + +void dsPlatformSimLoop (int window_width, int window_height, + dsFunctions *fn, int initial_pause) +{ + drawStuffStartup(); + setupRendererGlobals(); + renderer_pause = initial_pause; + + // create window - but first get window size for desired size of client area. + // if this adjustment isn't made then the openGL area will be shifted into + // the nonclient area and determining the frame buffer coordinate from the + // client area coordinate will be hard. + RECT winrect; + winrect.left = 50; + winrect.top = 80; + winrect.right = winrect.left + window_width; + winrect.bottom = winrect.top + window_height; + DWORD style = WS_OVERLAPPEDWINDOW | WS_CLIPCHILDREN | WS_CLIPSIBLINGS; + AdjustWindowRect (&winrect,style,1); + char title[100]; + sprintf (title,"Simulation test environment v%d.%02d", + DS_VERSION >> 8,DS_VERSION & 0xff); + main_window = CreateWindow ("SimAppClass",title,style, + winrect.left,winrect.top,winrect.right-winrect.left,winrect.bottom-winrect.top, + NULL,NULL,ghInstance,NULL); + if (main_window==NULL) dsError ("could not create main window"); + ShowWindow (main_window, gnCmdShow); + + HDC dc = GetDC (main_window); // get DC for this window + if (dc==NULL) dsError ("could not get window DC"); + + // set pixel format for DC + + PIXELFORMATDESCRIPTOR pfd = { + sizeof(PIXELFORMATDESCRIPTOR), // size of this pfd + 1, // version number + PFD_DRAW_TO_WINDOW | // support window + PFD_SUPPORT_OPENGL | // support OpenGL + PFD_DOUBLEBUFFER, // double buffered + PFD_TYPE_RGBA, // RGBA type + 24, // 24-bit color depth + 0, 0, 0, 0, 0, 0, // color bits ignored + 0, // no alpha buffer + 0, // shift bit ignored + 0, // no accumulation buffer + 0, 0, 0, 0, // accum bits ignored + 32, // 32-bit z-buffer + 0, // no stencil buffer + 0, // no auxiliary buffer + PFD_MAIN_PLANE, // main layer + 0, // reserved + 0, 0, 0 // layer masks ignored + }; + // get the best available match of pixel format for the device context + int iPixelFormat = ChoosePixelFormat (dc,&pfd); + if (iPixelFormat==0) + dsError ("could not find a good OpenGL pixel format"); + // set the pixel format of the device context + if (SetPixelFormat (dc,iPixelFormat,&pfd)==FALSE) + dsError ("could not set DC pixel format for OpenGL"); + + // ********** + // start the rendering thread + + // set renderer globals + renderer_dc = dc; + renderer_width = window_width; + renderer_height = window_height; + renderer_fn = fn; + + unsigned threadId; + HANDLE hThread; + + hThread = (HANDLE)_beginthreadex( + NULL, // no security attributes + 0, // use default stack size + &renderingThread, // thread function + NULL, // argument to thread function + 0, // use default creation flags + &threadId); // returns the thread identifier + + if (hThread==NULL) dsError ("Could not create rendering thread"); + + // ********** + // start GUI message processing + + MSG msg; + while (GetMessage (&msg,main_window,0,0)) { + if (!TranslateAccelerator (main_window,accelerators,&msg)) { + TranslateMessage (&msg); + DispatchMessage (&msg); + } + } + + // terminate rendering thread + renderer_run = 0; + DWORD ret = WaitForSingleObject (hThread,2000); + if (ret==WAIT_TIMEOUT) dsWarning ("Could not kill rendering thread (1)"); + DWORD exitcode=0; + if (!(GetExitCodeThread (hThread,&exitcode) && exitcode == 123)) + dsWarning ("Could not kill rendering thread (2)"); + CloseHandle (hThread); // dont need thread handle anymore + + // destroy window + DestroyWindow (main_window); +} + + +extern "C" void dsStop() +{ + // just calling PostQuitMessage() here wont work, as this function is + // typically called from the rendering thread, not the GUI thread. + // instead we must post the message to the GUI window explicitly. + + if (main_window) PostMessage (main_window,WM_QUIT,0,0); +} + + +extern "C" double dsElapsedTime() +{ + static double prev=0.0; + double curr = timeGetTime()/1000.0; + if (!prev) + prev=curr; + double retval = curr-prev; + prev=curr; + if (retval>1.0) retval=1.0; + if (retval +#include +#include +#include +#include +#include +#include +#include +#include "config.h" +#include "common.h" + +#ifdef HAVE_SYS_TIME_H +#include +#endif +#ifdef HAVE_UNISTD_H +#include +#endif + +#include +#include +#include "internal.h" + +//*************************************************************************** +// error handling for unix + +static void printMessage (const char *msg1, const char *msg2, va_list ap) +{ + fflush (stderr); + fflush (stdout); + fprintf (stderr,"\n%s: ",msg1); + vfprintf (stderr,msg2,ap); + fprintf (stderr,"\n"); + fflush (stderr); +} + + +extern "C" void dsError (const char *msg, ...) +{ + va_list ap; + va_start (ap,msg); + printMessage ("Error",msg,ap); + va_end (ap); + exit (1); +} + + +extern "C" void dsDebug (const char *msg, ...) +{ + va_list ap; + va_start (ap,msg); + printMessage ("INTERNAL ERROR",msg,ap); + va_end (ap); + // *((char *)0) = 0; ... commit SEGVicide ? + abort(); +} + + +extern "C" void dsPrint (const char *msg, ...) +{ + va_list ap; + va_start (ap,msg); + vprintf (msg,ap); + va_end (ap); +} + +//*************************************************************************** +// openGL window + +// X11 display info +static Display *display=0; +static int screen=0; +static XVisualInfo *visual=0; // best visual for openGL +static Colormap colormap=0; // window's colormap +static Atom wm_protocols_atom = 0; +static Atom wm_delete_window_atom = 0; + +// window and openGL +static Window win=0; // X11 window, 0 if not initialized +static int width=0,height=0; // window size +static GLXContext glx_context=0; // openGL rendering context +static int last_key_pressed=0; // last key pressed in the window +static int run=1; // 1 if simulation running +static int pausemode=0; // 1 if in `pause' mode +static int singlestep=0; // 1 if single step key pressed +static int writeframes=0; // 1 if frame files to be written + + +static void createMainWindow (int _width, int _height) +{ + // create X11 display connection + display = XOpenDisplay (NULL); + if (!display) dsError ("can not open X11 display"); + screen = DefaultScreen(display); + + // get GL visual + static int attribListDblBuf[] = {GLX_RGBA, GLX_DOUBLEBUFFER, GLX_DEPTH_SIZE,16, + GLX_RED_SIZE,4, GLX_GREEN_SIZE,4, GLX_BLUE_SIZE,4, None}; + static int attribList[] = {GLX_RGBA, GLX_DEPTH_SIZE,16, + GLX_RED_SIZE,4, GLX_GREEN_SIZE,4, GLX_BLUE_SIZE,4, None}; + visual = glXChooseVisual (display,screen,attribListDblBuf); + if (!visual) visual = glXChooseVisual (display,screen,attribList); + if (!visual) dsError ("no good X11 visual found for OpenGL"); + + // create colormap + colormap = XCreateColormap (display,RootWindow(display,screen), + visual->visual,AllocNone); + + // initialize variables + win = 0; + width = _width; + height = _height; + glx_context = 0; + last_key_pressed = 0; + + if (width < 1 || height < 1) dsDebug (0,"bad window width or height"); + + // create the window + XSetWindowAttributes attributes; + attributes.background_pixel = BlackPixel(display,screen); + attributes.colormap = colormap; + attributes.event_mask = ButtonPressMask | ButtonReleaseMask | + KeyPressMask | KeyReleaseMask | ButtonMotionMask | PointerMotionHintMask | + StructureNotifyMask; + win = XCreateWindow (display,RootWindow(display,screen),50,50,width,height, + 0,visual->depth, InputOutput,visual->visual, + CWBackPixel | CWColormap | CWEventMask,&attributes); + + // associate a GLX context with the window + glx_context = glXCreateContext (display,visual,0,GL_TRUE); + if (!glx_context) dsError ("can't make an OpenGL context"); + + // set the window title + XTextProperty window_name; + window_name.value = (unsigned char *) "Simulation"; + window_name.encoding = XA_STRING; + window_name.format = 8; + window_name.nitems = strlen((char *) window_name.value); + XSetWMName (display,win,&window_name); + + // participate in the window manager 'delete yourself' protocol + wm_protocols_atom = XInternAtom (display,"WM_PROTOCOLS",False); + wm_delete_window_atom = XInternAtom (display,"WM_DELETE_WINDOW",False); + if (XSetWMProtocols (display,win,&wm_delete_window_atom,1)==0) + dsError ("XSetWMProtocols() call failed"); + + // pop up the window + XMapWindow (display,win); + XSync (display,win); +} + + +static void destroyMainWindow() +{ + glXDestroyContext (display,glx_context); + XDestroyWindow (display,win); + XSync (display,0); + XCloseDisplay(display); + display = 0; + win = 0; + glx_context = 0; +} + + +static void handleEvent (XEvent &event, dsFunctions *fn) +{ + static int mx=0,my=0; // mouse position + static int mode = 0; // mouse button bits + + switch (event.type) { + + case ButtonPress: { + if (event.xbutton.button == Button1) mode |= 1; + if (event.xbutton.button == Button2) mode |= 2; + if (event.xbutton.button == Button3) mode |= 4; + mx = event.xbutton.x; + my = event.xbutton.y; + } + return; + + case ButtonRelease: { + if (event.xbutton.button == Button1) mode &= (~1); + if (event.xbutton.button == Button2) mode &= (~2); + if (event.xbutton.button == Button3) mode &= (~4); + mx = event.xbutton.x; + my = event.xbutton.x; + } + return; + + case MotionNotify: { + if (event.xmotion.is_hint) { + Window root,child; + unsigned int mask; + XQueryPointer (display,win,&root,&child,&event.xbutton.x_root, + &event.xbutton.y_root,&event.xbutton.x,&event.xbutton.y, + &mask); + } + dsMotion (mode, event.xmotion.x - mx, event.xmotion.y - my); + mx = event.xmotion.x; + my = event.xmotion.y; + } + return; + + case KeyPress: { + KeySym key; + XLookupString (&event.xkey,NULL,0,&key,0); + if ((event.xkey.state & ControlMask) == 0) { + if (key >= ' ' && key <= 126 && fn->command) fn->command (key); + } + else if (event.xkey.state & ControlMask) { + switch (key) { + case 't': case 'T': + dsSetTextures (dsGetTextures() ^ 1); + break; + case 's': case 'S': + dsSetShadows (dsGetShadows() ^ 1); + break; + case 'x': case 'X': + run = 0; + break; + case 'p': case 'P': + pausemode ^= 1; + singlestep = 0; + break; + case 'o': case 'O': + if (pausemode) singlestep = 1; + break; + case 'v': case 'V': { + float xyz[3],hpr[3]; + dsGetViewpoint (xyz,hpr); + printf ("Viewpoint = (%.4f,%.4f,%.4f,%.4f,%.4f,%.4f)\n", + xyz[0],xyz[1],xyz[2],hpr[0],hpr[1],hpr[2]); + break; + } + case 'w': case 'W': + writeframes ^= 1; + if (writeframes) printf ("Now writing frames to PPM files\n"); + break; + } + } + last_key_pressed = key; // a kludgy place to put this... + } + return; + + case KeyRelease: { + // hmmmm... + } + return; + + case ClientMessage: + if (event.xclient.message_type == wm_protocols_atom && + event.xclient.format == 32 && + Atom(event.xclient.data.l[0]) == wm_delete_window_atom) { + run = 0; + return; + } + return; + + case ConfigureNotify: + width = event.xconfigure.width; + height = event.xconfigure.height; + return; + } +} + + +// return the index of the highest bit +static int getHighBitIndex (unsigned int x) +{ + int i = 0; + while (x) { + i++; + x >>= 1; + } + return i-1; +} + + +// shift x left by i, where i can be positive or negative +#define SHIFTL(x,i) (((i) >= 0) ? ((x) << (i)) : ((x) >> (-i))) + + +static void captureFrame (int num) +{ + fprintf (stderr,"capturing frame %04d\n",num); + + char s[100]; + sprintf (s,"frame/frame%04d.ppm",num); + FILE *f = fopen (s,"wb"); + if (!f) dsError ("can't open \"%s\" for writing",s); + fprintf (f,"P6\n%d %d\n255\n",width,height); + XImage *image = XGetImage (display,win,0,0,width,height,~0,ZPixmap); + + int rshift = 7 - getHighBitIndex (image->red_mask); + int gshift = 7 - getHighBitIndex (image->green_mask); + int bshift = 7 - getHighBitIndex (image->blue_mask); + + for (int y=0; yred_mask,rshift); + b[1] = SHIFTL(pixel & image->green_mask,gshift); + b[2] = SHIFTL(pixel & image->blue_mask,bshift); + fwrite (b,3,1,f); + } + } + fclose (f); + XDestroyImage (image); +} + +void processDrawFrame(int *frame, dsFunctions *fn) +{ + dsDrawFrame (width,height,fn,pausemode && !singlestep); + singlestep = 0; + + glFlush(); + glXSwapBuffers (display,win); + XSync (display,0); + + // capture frames if necessary + if (pausemode==0 && writeframes) { + captureFrame (*frame); + (*frame)++; + } +} + +void microsleep(int usecs) +{ +#ifdef HAVE_UNISTD_H + usleep(usecs); +#endif +} + +void dsPlatformSimLoop (int window_width, int window_height, dsFunctions *fn, + int initial_pause) +{ + pausemode = initial_pause; + createMainWindow (window_width, window_height); + glXMakeCurrent (display,win,glx_context); + + dsStartGraphics (window_width,window_height,fn); + + static bool firsttime=true; + if (firsttime) + { + fprintf + ( + stderr, + "\n" + "Simulation test environment v%d.%02d\n" + " Ctrl-P : pause / unpause (or say `-pause' on command line).\n" + " Ctrl-O : single step when paused.\n" + " Ctrl-T : toggle textures (or say `-notex' on command line).\n" + " Ctrl-S : toggle shadows (or say `-noshadow' on command line).\n" + " Ctrl-V : print current viewpoint coordinates (x,y,z,h,p,r).\n" + " Ctrl-W : write frames to ppm files: frame/frameNNN.ppm\n" + " Ctrl-X : exit.\n" + "\n" + "Change the camera position by clicking + dragging in the window.\n" + " Left button - pan and tilt.\n" + " Right button - forward and sideways.\n" + " Left + Right button (or middle button) - sideways and up.\n" + "\n",DS_VERSION >> 8,DS_VERSION & 0xff + ); + firsttime = false; + } + + if (fn->start) fn->start(); + +#if HAVE_GETTIMEOFDAY + timeval tv; + gettimeofday(&tv, 0); + double prev = tv.tv_sec + (double) tv.tv_usec / 1000000.0 ; +#endif + + int frame = 1; + run = 1; + while (run) { + // read in and process all pending events for the main window + XEvent event; + while (run && XPending (display)) { + XNextEvent (display,&event); + handleEvent (event,fn); + } + +#if HAVE_GETTIMEOFDAY + gettimeofday(&tv, 0); + double curr = tv.tv_sec + (double) tv.tv_usec / 1000000.0 ; + if (curr-prev >= 1.0/60.0) + { + prev = curr; + processDrawFrame(&frame, fn); + } + else + microsleep(1000); +#else + processDrawFrame(&frame, fn); +#endif + }; + + if (fn->stop) fn->stop(); + dsStopGraphics(); + + destroyMainWindow(); +} + + +extern "C" void dsStop() +{ + run = 0; +} + + +extern "C" double dsElapsedTime() +{ +#if HAVE_GETTIMEOFDAY + static double prev=0.0; + timeval tv ; + + gettimeofday(&tv, 0); + double curr = tv.tv_sec + (double) tv.tv_usec / 1000000.0 ; + if (!prev) + prev=curr; + double retval = curr-prev; + prev=curr; + if (retval>1.0) retval=1.0; + if (retvalB9o€wulttslnv‚“Œ”£œ¥Œ‹“Œ‹“…„’ŒŒš}‡’{||”“›Œ”•|„…ultnv‚Œ”•™š¤{{ƒ„†™™š¤…„’ŒŒšŒ”•u{{u{{|„…lksmk…Œ—£œ§²{{ƒ‰Š¡Œ”•}‡’{{ƒ™š¤Œ”•˜Ž£™š¤™š¤ŒŒš™š¤„Š„|‚z”››œ››{||”š””š”£››‹„‹““““““redƒ„„…‹‹‹‹„{u{‹’Šlri””‹‹„„|‚zƒ||‹‹„š””{tttslƒ||ƒ„„™š¤„„Š{tt„Š„sle‹‹‹’ŒŒ‹’Šz‚l”››ƒƒ|uzt¦§¨ŒŒš{u{’ŒŒ›”›{u{„Š„ztl{{tlldœ¤¦ƒ‚usle“““sleŠŠ}tt{j]\f]cf]cultult™š¤˜Ž£lks{ttedk\[b{{ƒllkddc]bZ{{tlld{ttƒ}ƒ¦§¨‹„„]cd„„Š{u{tts…‹‹UTS|‚ztts“““uztekdlld|„…›¢›ztl\[b‹‹„£œ¥“““‹‹‹„„Šmtt›¢›lksSKJ{ttlrikk]dc\UUYsle[[TjcVmttkd\ƒ||rg]tts{||‹‹„tllsleJHFddcdc\b[Uult{||›”›\[[:97‹„„zll{{ttslztlsreUMRztltts\UZ{{t{{tttslekŠ}|”“›ult…„’{{tŠƒ}kk]d\\{u{„‰vtzlŒ”•‹„„tslzlllrif]c‹„‹‚|u‚utUTSult‹‹‹tzl“Œ”’ŒŒ“““Œ‹“f]cƒ||‹‹‹‹„‹‹„„ult{u{{u{ƒƒ|Š}ƒldd[TTSKJ{{t“Œ”Š~‹ztl{tt{ttreddc\{tt‹„„‹…’‹„„””‹{||uztSKJ{zmek]lrittsldd‚v‚u{{UMRultD;9UTSLKRlri…‹’›¢›{u{{u{’ŒŒ{{ƒŒ”•{{ƒtt{lekttslriƒ}ƒtts]cd{{ƒu{{{{ƒlks˜Ž£‰Š¡„†™‹„‹¦§¨ª³·mtt{{ƒ^fsœ¤¦…„’…‹’…‹šŒŒš|„…œ¤¦Œ—£mttœ¤¦Œ”•œ¤¦{{ƒŒ”•~’“™š¤tt{…‹‹”“›tllƒ„„“Œ”Œ”•ŒŒš“Œ”„„Š{{ƒ‹…’Œ‹“””‹{|||‚zedk|„…|„…¦§¨„Š„{tt“Œ”’ŒŒ£››ƒ„„SKJ’ŒŒš””{ttŠ}|j]\tllJHF{{ƒ™š¤{{ƒlri|‚zdc\ƒ„„tsl{||{{ƒ‹’Š„„Š{{ƒkd\ztl””‹š””„„Š…‹‹\UZƒ}ƒƒƒ|{||f]c‚v‚Š~‹f]c{{ƒ˜Ž£¦§¨{tt”››ƒ||lek‚|u{ttuztult…‹’ttsŒ”•ƒ}ƒƒ||Š}ƒƒ}ƒ””‹lldƒ}ƒ{tt‹…’™š¤“Œ”u{{ultlks’…‹“““Œ”•{{ƒ‹„„œ››‹‹‹Œ”•tts|‚z\UZllk[TTddctsl]bZtzlSKJreduzt”“›u{{lddŠ}|‹‹„{ttekd‹„„ztfred[[T{{tek]redllkŠƒ}¦§¨[TT:97‹‹„zll””‹kk]d\\kd\lldred\[bf]clldlri{u{„„Š’ŒŒ{||tzllddœ¤¦f]cƒƒ|llkult’ŒŒ{zmztl”“›ŠŠ}‚v{kd\tts‘…„£œ¥lks‹„‹ƒ}ƒmttu{{mttuzt‹„„ƒ„„]cd‹„„’ŒŒult‚ut|„…“““ƒ„„¤¤„Š„„Š„ƒƒ|[[T|„…{ttƒƒ|ƒ„„{||ƒ||lri„Š„ƒ||‹…’ztlbVZ“““[[T‹‹„ƒ||cbVlldMRKd\\ekdƒ}ƒƒ„„SKJj]\SKJUMRultƒ„„{zmƒƒ|mwŒ‹“Œ‹“{{ƒŒ”•ƒ}ƒƒ}Šult…‹‹…„’„†™Œ‹“‹‹„{{ƒƒ„„›²„„Š|„…œ¤¦…„’”“›”››Œ”•]cd]cd}‡’lkslks…„’tt{˜Ž£{{ƒ\[b{{ƒf]c…‹’mtt™š¤„„Š…‹‹™š¤{zmƒ}Š‚v{”“›„„Š…‹’œ¤¦œ¤¦™š¤¨©´¨©´¬¶Ã“““‹’Š¤¤‹’Š‹’Š¨©´‹‹‹ª³·œ¤¦›¢›{zm‹’Š‹‹„ƒ„„“Œ”tts|„…„„Š]cd“Œ”„„Šlek…‹‹tsltt{ztltts|‚ztsl{zm£››£œ¥tsl‹‹‹ultu{{tll‰|vƒƒ|tlltsl{{ƒŠŠ}b[U‰Š¡™š¤“Œ”‹…š‚v{ƒ}ƒ‚v{ldd”“›{{ƒ”“›…‹‹fkkƒ}ŠUTSƒ}ƒ“Œ”‹„‹“Œ”‹‹‹{|||„…„„Šllk{tt{{t‹„‹š””£››‹„‹£››ƒ}ƒtlllek‚v‚ƒ}Šldd{u{ƒ||tt{Œ‹“|„……„’‹‹‹{u{‹„„cbV„„Š|„…lldiq]jV[Šƒ}”››››”ztl‹„„tslSKJ‚utVTLlri‚v‚lriUTSlddJHFFD;llktts›¢›SKJ:97lld{u{Œ”•‘…„£››ƒ||rg]JHFlek[[T|‚zekdldd™š¤bVU‹‹‹|‚zVTLek]|‚zdc\…‹‹|‚z„Š}‹‹‹‹‹„š””ƒƒ|ƒƒ|tsl‹‹‹…‹’£œ¥tll‹„‹‹‹‹„„Š‚ut{||tt{‹‹„llk“Œ”ekd‘…„tllƒ‚uƒ„„{{t[[Tœ››{{ƒ…‹‹|‚z{{ƒVTLtt{””‹tllttsŠ}ƒtsl“Œ”{tttts[TTyl„{u{lddekdVTLUMR‚wlsre{u{kd\lksu{{\UZf]csleg\rred™š¤mtt‚v{{||Œ‹“{u{ƒ}ƒƒ||lek{||{{ƒ{{ƒŒ‹“™š¤{||‹…š}‡’‹„‹„„Š{{ƒ…‹šŒ”•tt{„„Š…‹’|„…mttmtt^fs{{ƒ‰Š¡|„…„„Š{{ƒ{{ƒŒ‹“Œ”•{{ƒ¦§¨|„…Œ‹“Œ”•‹‹‹¨©´¦§¨™š¤…‹’™š¤¨©´„Š„›¢›}‡’¦§¨¨©´··Äƒ„„‹‹‹ƒ}ƒldd‚v{‹‹‹‹’ŠšŒ›¢›””‹™š¤tlluzt“Œ”tsl{{tf]cJHFf]cult¦§¨Œ”•tt{œ¤¦Œ”•œ››ƒ‚u”š”Œ”•‹‹‹ƒƒ||„…œ¤¦™š¤”“›[[Tsle[[Tkd\f]c‹„„›”›“Œ”Œ‹“ƒ||tt{\UZ{{ƒ|„…\[blkslri]bZ¦§¨ttssle{ttŒ”•tts„Š„zllkd\tllultŠ}ƒlekmttedk“Œ”{{ƒ“Œ”{{ƒ{{ƒ…‹‹{{ƒlld¨©´ƒ„„|‚z„Š„lld‹‹‹¦§¨¦§¨œ››lri¦§¨tts…‹‹‹’ŠcbVUTStt{|‚z\[[{{t\UZ{ttttssre„Š„slerfkƒ||‚|u{ttƒ„„fkkddc[[Tllkz‚lmttlriztl¦§¨UMR:97ƒƒ|‚|ukd\ztlu{{šŒylekd\{tttll„Š„ek]llk|„…{ttƒ||{||‚wl„Š}]bZ‹’Šlriuzt…‹‹””‹ldd”“›ƒ}ƒ{{t‚|u‹„‹uztult“Œ”{{ƒult{||”š”ƒ||“““ƒƒ||‚z{{ƒf]czllultƒ||SKJ{ttsleuztƒ||{{ƒMRKUMRlek‘Œ…””‹“Œ”š””f]c{ttdc\tlld\\tsltllj]\VTLVTL‹u…tt{‚v‚tslƒƒ|[[T[TT\UZult’ŒŒzll“Œ”ultedkldd|‚z””‹{u{›”›lddddc{{ƒtts{{ƒ”“›Œ”•…‹’‹„‹{{ƒyl„„„Š™š¤lksŒŒšŒ—£|„…\UZŒ‹“mtt|„…{{ƒnv‚{{ƒ…‹š¦§¨˜Ž£“Œ”Œ‹“™š¤‹„‹|„…”“›{{ƒnv‚{{ƒ{{ƒ}‡’”›››¢›‹‹„Œ—£››”‹…’¦§¨“““’ŒŒ¨©´ª³·u{{”››”››„Š}™š¤‹’Š…‹‹Œ”•lri‹‹‹uzt”š”llk‹‹„lek{||f]c\[[›”›¤¤œ›››¢›“Œ”Œ‹“”“›…‹‹‹‹‹“““„„Š‹’Šllk|‚zŒ”•Œ”•{ttultmwlekb[Ulri”š”‘…„”››mtt’…‹“““f]cƒ„„sle“Œ”›¢›{ttVZ[mtt‹’Š]cdnv‚|„…lks]bZŒ”•£››››”Œ”•Œ”•‹‹„‹‹„‹„‹¦§¨‹…’“Œ”“Œ”ª³·‹‹‹zlltsl‹‹‹”š”ldd{ttultfkku{{“““{{ƒ™š¤Œ”•‹„‹‹…’ldd„Š„tsl\[[lri{{t¤¤tt{d\\VTLƒ||‹‹‹””‹ttslrikd\ƒƒ|SKJaWM[[Tf]c[TTVTL‹’Šlldlri«²«JHFUUYsleƒ||lddƒ||‹’Š‹„‹…‹‹{ttultedk‰ƒvlritsltts{{ƒƒ||{zmult’ŒŒƒ‚ntzlsretts|‚zztl‹‹„{tt{{t{{ƒ|‚z‹‹„£²tll£››‚ut”š”¨©´’ŒŒƒƒ|]bZkd\’ŒŒŒ‹“{u{ztlldd{{ƒd\\edktt{‹‹„œ››ƒ||UUY[[TLKR{{ƒf]cultttslksultUMRlksddc\UZ\UZlekƒ}ƒrfkŠ}|‹„„tsl|„…{{tultttsƒ}ƒ{||šŒtll“Œ”f]cmtt{{tj]\f]cƒ}ƒmk…{tt|‚zmttu{{lks{{ƒ|„…lksult\UZtlllek‹…’ƒ„„\[bƒƒ|^^qŒ”•\[[mtt|„…Œ”•n…{{ƒMSSultœ§²¨©´›²{{ƒ~’“{{ƒœ¤¦^fs}‡’Œ—£œ¤¦‰Š¡š””š””¦§¨“““‹‹‹¦§¨‹„„‹’Š“““œ¤¦›¢›{||„„Š}‡’Œ‹“™š¤|„…›¢›œ¤¦‹’ŠŒ”•llk{ttƒƒ|]bZƒƒ|‹‹‹„Š„„Š}ƒ„„{{ƒ‚ut“Œ”tll‹’Š¨©´œ››‹„„“““ƒƒ|ƒ‚uƒ||‹„„‹„‹¦§¨œ¤¦{{tƒ||‹‹‹…‹‹lriŒ”•|‚z‹„‹tt{{||SKJekdƒ„„{{t„Š„œ¤¦|„…{{ƒlri|„…Œ‹“œ››ƒƒ|‹„‹{{t“““‹‹‹uzt”š””››‹’Šœ¤¦”››œ››Œ‹“¦§¨”“›‹‹‹£œ¥””‹“Œ”“Œ”{u{ƒ}ƒŒ—£mttfkkult‚|uuztuzt”››lks¨©´ult“Œ”ttsb[U|‚zult””‹lekƒ||ƒƒ|srerg]ƒ||d\\ddc„Š„ztllldFD;f]clkskk]|‚z|‚z””‹””‹››”llk3+*ttsUMRf]cr]g{u{‹„‹Œ”•tsl‹„„lek{zmsletzl…‹‹š””„Š„lek’…‹””‹£œ¥Šƒ}Šƒ}ttsldd|‚zztl{{t{u{{||Š}ƒƒ||Š}|Š}|‹„„kd\ult{{ƒ‹’Š›¢›Œ”•…‹‹tslƒƒ|ƒ}Š‹„‹{u{[[TddclldŒ‹“„Š„ƒ„„{||VTLJHFVZTtsllks‹„„{u{„„Š“““{||{{t{{ƒ„„Š\[[\[[„Š}f]c{ttlldš””tts‹‹„f]c‚|uttskk]aWMVTLedklksmttƒ||f]clddtt{\[bult{||Œ‹“ŒŒš„„Š™š¤ŒŒšŒŒš{{ƒ‹„‹{u{|„…{{t™š¤ƒ}Š„Š„{{ƒttstts…‹’mtt™š¤\[bedk\[bŒŒš™š¤™š¤™š¤…‹šmttª³·Œ”•{{ƒmttnv‚Œ”•œ§²µ¶·£œ¥£²Š~‹{{t’ŒŒ‹‹‹”››¦§¨¦§¨…‹‹ttssreƒƒ|tts{||‹…’œ¤¦|„…‹’Š›¢›¦§¨|„…‹’Štts…‹‹|‚z„Š}œ¤¦‹’Š|‚z„Š}”››„Š„¦§¨“““¦§¨{{t|‚z‚wlƒ‚u£››’ŒŒ’ŒŒ²««{u{ultŒŒš›”›tt{œ››lek””‹“““‹’Š™š¤\[[ƒ||{||llk{{ƒ\[blks}‡’}‡’VZ[UMRedk…‹’uzt™š¤ƒ}ƒ{{t™š¤¨©´ª³·œ¤¦œ¤¦™š¤›¢›”š”‹’Š”››œ¤¦œ¤¦fkk{{ƒ{{ƒ{{ƒ‘…„f]cŠ}ƒ“““‹„‹ultult[[Tmttfkk„„Šƒ„„…‹‹‹„‹lek{tt„Š„{tt¨©´ƒƒ|‹„„ddckk]yfdtts£œ¥ƒ||kk]|„…ttsSKJtt{tzl[[T]cdlek‘ˆ}²««UTS*)(“Œ”ultbVZlek{{t{u{ƒ||{{ƒ‚wluztlri””‹u{{{||f]cu{{|‚zƒ||‹„„£››Š}|šŒultrg]››”‚wl””‹£››Œ”•‹‹„sle‚utƒ||{ttƒƒ|tt{…‹’œ››{{t|‚z’ŒŒƒƒ|‹’ŠŒ‹“uztf]c[TTddctlld\\tllkd\ldd\[[ultttsekdlks‹„‹lksƒ||UTSd\\llk…‹‹VTLtt{ttsƒƒ|{||{||[[Tg\rLKR‹„„lksf]cek]dc\‹„„VTLkd\]cd]cdek]ƒ||ƒ„„‹…’™š¤”“›…„’ƒ}Š…‹‹…„’“““ultŒ”•|„…llk¦§¨”“›œ¤¦™š¤lks“Œ”mtt{{ƒ{{ƒ|„…{{ƒedk|„…\[[edk{{ƒ{{ƒ„vŒŒ”•uzt{{ƒ™š¤{{ƒtt{™š¤Œ”•œ¤¦™š¤¦§¨ƒ„„Š}ƒ{u{‹„„|‚z››”‹’Š“Œ”™š¤tsllksultultƒ||œ¤¦„„Štllƒƒ|Œ”•¨©´|„…{||„„Šœ››…‹‹Œ”•]bZtts”“›tt{…‹‹…‹‹\[[lri””‹|‚z¦§¨tzl]bZttsu{{tll‚wlƒ}Šƒ„„ƒ‚uƒ„„|‚zedkuztu{{Œ”•{{ƒ™š¤ƒ„„…‹’mttult{{t{{ƒlri\[b]cdmtt|‚zz}lri|„…lksœ¤¦„„Š¨©´Œ”•œ¤¦…‹’Œ”•œ¤¦ª³·”››f]c|„…‹’Šš””u{{œ››Œ‹““Œ”\UZŠ}|ultƒ}ƒtll{tt‚|uUMRllk“Œ”{{t£œ¥™š¤lksultlks‹…’{u{mttttsŠƒ}ƒ}ƒ[[TSKJbVZŠƒ}tt{‹„„„Š}[TTllktslkd\ƒ||sle|‚ztll{{t¦§¨llk74,SKJtll’…‹ddcmttldd{{tsle‘Œ…“Œ”f]cslesle|„…lri|‚z‚|u{tt‹‹„£››¦§¨‚|u…‹‹ƒ„„‹’Šsreƒƒ|Œ‹“™š¤’ŒŒlld‹‹‹mtt‹„„ƒƒ|ddctt{”š”‹’Š„Š„{u{tslr]Zu{{‹‹„‚|uultllkfkkSKJ]bZ]bZF=CF=Cmttlriœ¤¦ƒ„„|„…{{t‹…’Œ”•tsllkstlltts]bZlekuzt|„…ddc„Š„lkslrid\\sleu{{slesred\\cbVtllƒ}ƒuztlritll{tt„„Š…‹‹Œ‹“ŒŒš£œ¥œ§²{{ƒ‹„‹œ¤¦™š¤ŒŒšllk™š¤‹„‹Œ‹“‹„‹{u{ƒ}ƒlks|„…{{ƒŒ”•|„…tt{|„…|„…›²›”›nv‚|„…{{ƒlks“Œ”{||…„’ƒ}Š£²“Œ”£œ¥™š¤{{ƒ™š¤tll‹„„tts[TT{ttŒŒš”“›¦§¨¦§¨ƒ}ƒ’…‹‚v{š””‹‹‹ztlƒ||mtt{u{…„’{||Œ”•œ¤¦ƒ„„™š¤SKJŒ‹“‚|u{{tŠ~‹…‹’Œ‹“{{ƒ|„…”š”edk|„…tsltzl{{t‹’Š‹‹‹›¢››¢›’ŒŒ{{ƒƒ„„lekŒ”•Œ‹“tt{Œ”•…‹’{{ƒmttldd]cd‚v‚lksu{{\[bUUYŒ—£mttŒ—£|„…{{ƒ{{ƒVZ[„„Š…‹‹Œ”•«²«™š¤¦§¨|„…mtt”“›™š¤™š¤tt{„„Šlks™š¤lks…„’Œ‹“ult\[[dc\ƒ||UMRyflreddc\j]\„„Šj]\{ttllkedkb[Uultult]cddc\[TTVTLtll[[Ttllr]gƒ}ƒ{{t››”‹‹„ekdultbVZj]\UTSC8.JHFldd²««›¢›JHF!ekd{{ƒ{{tultllksle|‚zb[Uš””‹„‹{{ƒ“Œ”£››ƒ||œ››…‹‹ƒƒ|’ŒŒŠŠ}{ttŠŠ}‹„„œ››‚v{‹„„‘Œ…ƒƒ|ttssle’ŒŒƒ‚uƒ„„„Š„‹„‹œ¤¦”››f]cŠƒ}’ŒŒmtt{{t…‹‹lri|„…‹’Š{||‹„‹tt{™š¤dc\tllekdlld‚v‚mk…mttŒ”•œ››Œ”•„„Š{|||„…„Š„rfkekdƒ„„[TTekdlld‹‹„mttek]…‹‹ƒ}ƒ‹„„lek\UZVTLlksŠ}ƒred’ŒŒult„„Š‹‹„d\\“““››”…„’”“›…‹’‹…’{{ƒŒŒš{||¦§¨}‡’˜Ž£\[[ddcult{||ƒ}Šƒ„„¦§¨lks|„…ttsŒ”•„Š„ŒŒš‹‹‹|„…”››„vŒ‹…’…‹‹„„Š|„…”››|„…”››™š¤Œ‹“Š~‹™š¤‹…’Œ”•|„…Œ”•œ¤¦™š¤”››Œ”•›”›‹‹„£œ¥”“›lks{u{£œ¥›”›…‹‹“““…‹‹…‹‹ldd{{ƒ‹‹‹mttœ¤¦Œ”•œ¤¦MSSUTSttsŒ”•“~ˆztl‹„‹‰v|]bZ””‹cbV¦§¨””‹|‚z””‹Œ‹“Œ‹“„„Š„„Š„„Š\UZddc\[[[TT{||™š¤Œ”•|„…™š¤mtt\UZlksultJHF\[bŒŒšUMRƒ}Š|„…Œ”•ƒ||œ››“““ult{{tultœ¤¦œ¤¦…„’Œ‹“™š¤µ¶·|„…|‚z‹’ŠŒ”•…‹’“Œ”Š~‹‹„‹{{ƒœ¤¦£œ¥ƒ}Šf]c[TTleksleztl{u{red“Œ”{tt‹„„‘…„™š¤rfkultƒƒ|ddc‹‹‹”“›ztlƒƒ|œ››ƒ||j]\„„Šƒ‚uƒƒ|cbVddcztlllkƒ}ƒkd\ƒ‚u{{tƒ||{zmµ¶·MRK*)(|‚ztlltts[TTlriredtslƒƒ|””‹ƒ}ƒ’ŒŒlldƒ||„„Š‹‹‹ƒ‚n‹„„²¬µƒƒ|‚|uŠƒ}œ››«²«‹„‹“““{zmlri™š¤’ŒŒztlbVUŒ‹“{tt|‚ztt{””‹uzttts””‹‹’Š‹„„|‚z”››ƒ||“Œ”tts‹‹‹…‹‹“Œ”š””“““mttUTS^^qlks{u{…‹‹™š¤…‹‹Œ”•{{ƒŒ”•{||‹’Šlddztldc\œ››ult„Š„…‹‹ŠŠ}‹„„‹…’ƒ||ƒ}ƒ{{ƒ”“›…‹‹“““£››Š}ƒ\UZ{{ƒƒ||ƒ}ƒµ¶·¦§¨Œ‹“™š¤‹‹‹†~‘|„…Œ‹“{u{uzt…‹‹{{ƒ|„…‹‹‹ult‹‹‹„„Š„„Šœ¤¦mtt™š¤…‹‹œ¤¦…‹’…‹’Œ”•ƒ„„¦§¨„„Š™š¤””‹“““edk‹‹‹“““Œ”•{tt…‹‹¦§¨™š¤llkŒ‹“‹’Šult|„…ult“““Œ”•“““‹‹‹›¢›œ››¨©´|‚zƒƒ|{||£››‹‹„tzl‹’Šsle{||„„Š|„……‹‹”š”‹‹„]bZŒ”•ult{||{zmƒ||{{ƒ|‚zŒ”•›¢›{{t””‹„Š}{{t{{tƒƒ|£›››¢›ƒ„„{{tdc\tsl[TT‹‹„kk]f]cf]c{{ƒtt{„„Štt{lek|„…tt{fkkmtt]cdŒ”•}‡’…„’™š¤”š”’ŒŒ£œ¥‹…’|„…£²¬¶Ã™š¤™š¤‰Š¡{{ƒ”“›£œ¥™š¤™š¤””‹š””ultƒƒ|”“›ƒ}ƒ{||tsl{||llkedkŒ”•„„Š‹„‹¨©´ƒ}ƒƒ||“Œ”Œ‹“{u{“Œ”ldd“Œ”{tt“Œ”ƒ||slesleŒ‹“‹„„{{tj]\„Š}kd\ek]dc\ekdredVTLb[UVTL]bZSKJlksµ¶·VTL*)(ƒƒ|{u{{u{ztltts‚utsre‚|u””‹{{ƒ‹’Š™š¤b[U|‚zult‚ut”››|„…iq]{{t””‹‹‹„œ››{||™‹†b[U{zmŒ”•Œ”•{{t‹‹‹‹„‹|‚z{||{u{tt{tt{”››«²«”š”tslmttuzt|‚z…‹‹ƒ}ƒŒ‹“„„Štts¤¤uztlritsl]cdMRKllkmtttll‹’Š\[[Œ‹“|„…ztl{{ƒ{{t{tt‚|utsl{tt|‚zbVZ‹‹‹Š}ƒŠ}ƒ“““‹„‹›”›{ttmtt‹‹„‘Œ…lldSKJlddJHF’ŒŒ|‚zƒ}ƒ|„…ƒ}Šlri’…‹œ››mtt£œ¥‹„„mtt{{ƒ|„…ƒ}ƒ›”›‚wl†~‘¨©´¦§¨™š¤Œ”•œ››œ¤¦mtt|‚z”››œ¤¦…‹’tt{|„……‹’‹…’{||…‹‹ultu{{mttmttŒ—£…„’lks””‹¦§¨«²«¦§¨¦§¨œ››œ¤¦{||Œ”•”››…„’œ¤¦„„Š”“›lks…‹‹|„……‹’ddcf]c”“›µ¶·{{ƒ{u{¦§¨…‹‹ƒ„„Œ‹“lks””‹[TT\[[dc\|‚ztsl“Œ””“›«²«„Š„››”œ››|‚z‹‹„Šƒ}ƒ}ƒ{{ƒd\\llk’ŒŒ‹‹„tsl™š¤{{tƒ}ƒttsdc\ult[[TUUYlriuztMRKtllllkyl„ddc{{ƒ“Œ”£²ŒŒš”“›ult””‹{||ƒ}ƒ‹…’™š¤tt{¨©´„„Šƒ„„ƒ„„Œ”•„„Šztl„Š„”š”{||tsltt{u{{ddc”“›™š¤œ¤¦”“›”››‹’Š„Š„‹‹‹„Š„Œ”•“Œ”\[blldlddedkdc\‹’Š{{t‹„„lldj]\{ttSKJSKJ]bZlridc\d\\j]\j]\lddekdttsƒ„„²««UTS*)({tti\Vldd{ttŒ‹“‹„‹Šƒ}£››zllsre‹„„{{t{{tllkš””’ŒŒtsl›”›lrid\\yle’ŒŒ‹’Š¦§¨ƒ||“Œ”‹‹„{u{lldyle‹‹‹ttsŠ}|{||„„Šd\\…‹‹‚|u‹‹„ƒƒ|{|||„…lrikd\…‹‹kd\„Š„œ¤¦”››“Œ”uztu{{uzt]cdUMR]cdddcd\\Œ‹“]bZult\UZd\\ƒ‚nsleu{{ƒ||{ttf]c{{tdc\ƒƒ|ƒ„„Šƒ}JHF{tt[TT‚|utslƒƒ|mwUMRtts“Œ”‹„„lksultlkstts{u{‹’Š™š¤“““{{ƒš””£œ¥|„…|„…{||œ››“Œ”””‹Œ—£„Š„‹…’ŒŒš…‹’ƒ„„…‹‹{{t¡¡“““|„…lks{{ƒ{{ƒ…‹’¨©´{{ƒ”“›‰Š¡{{ƒ{{ƒ…„’{{ƒnv‚lksŒ”•»ÂÇŒ‹“…‹š”“›…‹‹››””š”œ››‹’Š„„Š¨©´œ¤¦”››ult‹’Šu{{‹„„›”›‹„‹“Œ”¦§¨‚ut„„Š”“›‹’Š£œ¥™š¤{{ƒ”“›tts{{ƒ{||‹„„”›››”›¦§¨ŒŒš…‹’¦§¨“Œ”\UZŒ‹“”“›ult‹…’]cdult„„Š{ttult™š¤“Œ”llkŒ‹“|„…ultedk“Œ”…„’Œ‹“tts\[bf]cult¨©´{u{ŒŒš{{ƒŒ”•ƒ„„„„Šttsmtt|„…tt{„„ŠmttŒ”•{{ƒ›¢›Œ‹“œ¤¦‹’ŠŠƒ}Œ”•lld|‚z‹…’œ››“““dc\‚v{tts”š”|‚z„Š„š””d\\lks…‹‹|„…d\\red{{ƒ“““ƒ}Š\[[tslSKJƒ||tsl{ttultdkVSKJVTLVZTmtt\UZredtllztl\[[SKJ{{t²««JHF*)(dc\ultd\\i\Vƒ„„{tt››”‘Œ…ƒƒ|~’“…„’sre‹„„d\\‚v{„„Š’ŒŒƒ„„lldek]f]c‹„„…‹‹|‚zƒ||£››‹„„’…‹””‹zll‹‹„ƒ„„‹‹„tll‹’Š‹„„„Š„{tt‹‹„””‹ƒ„„tt{|‚z‹‹„|„…llk››”™š¤|„…ƒ||„Š}ek]|„…cbV„„Šlldmttd\\lldllkedk{{ƒŒ‹“llkultttsŠ~‹’…‹bVU››”[[T‹„‹ƒƒ|sreddcttsf]c‰v|ƒ||ƒ„„sleb[U‚|u‹‹‹ƒ„„tt{d\\\[bLKR™š¤”“›™š¤“Œ”{{ƒƒ„„“Œ”llku{{”››”“›{||Š}ƒrfkŠ}ƒ™š¤{{ƒ{u{zllœ¤¦Œ”•¦§¨Œ‹“u{{…‹‹™š¤™š¤ult™š¤…„’ult…„’™š¤{{ƒ‹…’{{ƒ›²›²œ§²”“›{{ƒ‹‹‹™š¤””‹”“›œ››“““tsl…‹‹”“›ƒ}ƒŒ‹“Œ”•|„…{||lldmtt…‹‹›¢›Ž¡›œ¤¦¦§¨lri›¢›Œ”•tts…‹‹‹‹„slemtt\[bultƒ}ƒ|‚z“““uzt‹‹‹›¢›…‹‹lld„Š„‹‹‹…‹‹ttslri“““œ››ƒ‚uƒ„„rfkƒ}ƒ“Œ”‹„„dc\JHFf]cƒ„„ultlldult{u{f]cƒ}Š…‹‹{||mttlldŒ”•œ¤¦{{ƒ”“›‹„‹ƒ}ƒ„„Š…‹‹™š¤›”›{u{”››ztl|‚z¤¤‹‹‹{{ttslsleƒ‚udc\„Š„ztlƒƒ|tzl“““slelksekd{{t¦§¨{||ultleksleUTSŒ‹“{||d\\slett{‰ƒvldd{ttsle‹’Š{{tUUYztlult|„…ƒ„„”š”sremttSKJcbV””‹F=C*)(d\\tts[TT‚v{{tt”“›{{tƒ‚u{zmultred{{tŠƒ}ldd‘Œ…“Œ”llk|‚z\[blld{{ƒ‹‹‹Œ‹“ƒ„„‹‹„‚|uƒ‚u””‹£››|„…µ¶·”“›„„Šult„Š„‹„‹|‚z“““››”‹‹„”š”f]c”››|‚z‹’Š„Š„Šƒ}ttsu{{]cd”š”JHFƒ}Š[[Tf]c\[[tt{ulttlllriŒ”•{{ƒƒ}ƒlekedkllk|‚z„Š„‚|u‚|udc\llkb[Ui\VUTSlddUMRkd\VTLrg]f]cf]c“Œ”‹„‹¦§¨‹„‹‚|u|„……„’„„Š…‹‹‰ƒv…„’ŒŒšƒ„„œ¤¦Œ‹“™š¤{{ƒ{||tll¦§¨Šƒ}‹„‹™š¤”“›Œ”•“““Œ”•ª³·ƒ„„ƒƒ|‹’Šuztlks{{ƒ{{ƒ™š¤Œ‹“‹’Š…‹’|„…}‡’{{ƒ^fs}|’~’““Œ”œ¤¦œ¤¦ƒ}Šƒ„„‹‹‹ƒ„„tllƒƒ|tt{‹‹„œ¤¦tsl››”lriƒ‚u‹„‹llkƒ}ƒlektt{¦§¨¨©´ƒ}ƒŒ‹““Œ”‹’Šlld“Œ”f]ctts{tt|„…uztj]\™š¤’ŒŒœ››‹‹„ƒƒ|„Š}tzl””‹ŠŠ}”››µ¶·ƒ‚ukjVš””ƒ||ztlšŒtll\[[„„Šddcult‹…’„„Šult‹„‹›”›{u{{{ƒtll‹’Šuzt‚|uœ››tll{{ƒ˜Ž£„„Š|„……‹’”››…‹‹{{ƒ“Œ”{u{Œ‹“u{{ƒ„„œ¤¦œ››{||]bZlriUTSd\\u{{‹„‹f]cŠ}ƒult{||™š¤d\\{ttsle‚|uztlƒ}ƒ‹„‹u{{Œ”•ƒƒ|’ŒŒ{||{u{ƒ||’…‹¦§¨„Š„¦§¨‹’Š{||ƒƒ|ƒƒ|Œ”•Œ”•‚|uƒ}ƒJHF[TTkd\¤¤VTL74,ulttsltts“Œ””š”“Œ”bVUƒƒ|‚wl[TTsle{tt{ttult‰ƒvlek‹„‹lldlriekdƒ||tllŒ”•|„…‚ut‚|uŠŠ}ƒƒ|’ŒŒ{||‹‹„|‚z‹„„„„Š””‹{tt{{t›”›¤¤‹‹„|‚zult…‹’„Š„‹’Štslultƒ}ƒ”“›{||”››ekdf]cUMRVZ[\[bƒ}ƒƒ||‹‹‹u{{Œ”•ek]”››”“›™š¤‹„„[TTlri{{ƒƒƒ|ddclridc\j]\Œ”•lriultlekŠ}ƒ””‹[TTƒ}ƒ„„Š…‹‹¨©´Šƒ}Œ”•”››™š¤£²…‹‹…‹‹¦§¨{{ƒŠ~‹|„…„Š„ŒŒštt{ƒ}ƒuzt“Œ”lriƒ}ƒ„„Š™š¤Œ”•”“›‹’Š|‚zu{{Œ‹“lriuzt{||“Œ”“““Œ”•lkstt{‹…’›”›™š¤¨©´™š¤¨©´¨©´{{ƒ™š¤Œ”•¨©´™š¤“““ƒ||lld|„…”››|‚zƒ|||‚z”››œ››¦§¨¦§¨››”¦§¨‘…„tts{tt“Œ”Œ‹“¨©´“““£œ¥…‹‹‹‹„lekŒ”•UTSttsŒ‹“‹…’„„Š‹‹‹ƒ„„“Œ”ƒ}ƒš””Š}|£››{zm¤¤¤¤››”œ››¦§¨‹‹„{{t‚v{tts„Š„““““““VTLlldlldSKJ‹„‹™š¤lekedk›¢›«²«œ§²uztttsƒ}ƒƒ}ƒƒ„„…„’™š¤£œ¥“Œ”™š¤‹„‹{u{”“›{ttult¨©´µ¶·Š~‹ttsƒ||mttf]cŒŒšƒ}Šƒ„„lld‹‹„‚v{”››‹…’ƒ}ƒtt{ztlrfkult›”›bVU™š¤u{{ƒƒ|ult…‹‹sle”“›‰ƒv‹„„{{ƒƒ„„‹‹„ƒ}ƒ{||„Š„‹‹‹’ŒŒcbV{{tedk{||„Š„¤¤JHF*)({{ƒlddttsztl“““ultcbVƒ||””‹rfk{zm’ŒŒ„Š}tll‹‹„j]\‘Œ…uztuztztflddd\\ƒƒ|tt{¦§¨™š¤ƒ‚uƒƒ|’ŒŒ{||„„Šlri{{t”“›œ››››”™š¤‹„„”“›ƒƒ|llklek…‹‹«²«£››{||ƒ||‹’Štts…‹‹|„…‘Œ…‹„‹|„…}‡’mttƒ}ƒd\\š””{||srett{Œ”•›¢››”›™š¤lekztltzlkd\“Œ”ƒƒ|kk]kd\{zmƒ}Š{ttu{{lrilld‹„„f]cztlŠ~‹{{tddc‹„„Œ”•„vŒŒ”•„Š„…‹‹mtt›”›rfkUTStsl{{ƒ|„…lld’ŒŒ‹…’…‹‹tslyl„ult™š¤{||…‹’mtt{||{{tleku{{›”›ƒ}ƒ‹„‹|„…Œ‹“‹’Š“Œ”œ¤¦œ››¨©´”“›„„Š{u{„Š„”“›Œ”•ƒ„„Œ”•lri‹’Šƒ„„œ¤¦‹’Š…‹‹uzt{u{··Ä“““¨©´„„Š’ŒŒŠ}ƒ’ŒŒ’ŒŒbVZ„„Šsle£››“Œ”‹’Šult””‹¦§¨›”›‘Œ…Š}ƒ¦§¨²¬µ›”›”“›¨©´¦§¨lek¢—‹’Š›¢›œ››››”›¢›“““rg]sleŠŠ}lri{zm“““tzl{{t””‹[[Tllduztƒ‚u™š¤Œ”•{{ƒmtt„„Š™š¤ƒ}Š]bZ…„’ult‹uŠ{u{‹„‹“Œ”£œ¥“Œ”ult‹…’tsl“Œ”lksVZT{{ƒŒ”•u{{‹„‹™š¤ƒ}ƒ{u{ƒ}ƒ„„Š‹…’‹…’{{ƒƒ}Šlldsle|‚z{{ttslkd\ultlksultƒ}ƒddcu{{bVZ…‹‹„Š„’ŒŒ[TTd\\{tt{tttygtts{{t‹‹„lektllkd\‚|ulkslldtsl£œ¥FD;*)(Œ”•‰|vtt{rg]ƒƒ|ƒ„„‚|u‹‹„tsltsltll{u{kd\|„…‰ƒvztl›”›lri‹’Š’ŒŒedk{{ƒ£››Œ‹“‚|uultz‚llld{{ƒŠ}ƒ›”›”››lldf]cƒ}Š{{tŒ”•tll“““›¢›Œ”•ttsœ¤¦”››¦§¨|„…\[[rfkƒ||uzt|‚z”“›Œ”•u{{‹„‹ŒŒšlri{{ƒ””‹‹’Š…‹‹{{ƒ‹„„|‚zœ››ƒ||ƒ}Š‹’ŠŒ”•{ttƒ}ƒrg]‹‹‹{{t|‚z„Š}ƒ}ƒ“““|‚zlriuztƒ}ƒlek‹…’‹„„lldllk”š”†~‘u{{…‹‹llkŒ‹“{u{Œ‹“ƒ||{||ttsœ››™š¤{||‚v‚tts‹„„{ttf]ctt{£››|„…‹„„”“›{{t”š”{{t›¢›ddcƒ}ƒu{{¸Á¹œ§²™š¤¦§¨¦§¨‹’Štts{{ƒ|„…mtt™š¤œ¤¦tt{Œ‹“u{{{{ƒ|„…”“›”››“Œ”ƒ||‹‹‹²¬µœ¤¦””‹{u{edk‹„„{{ƒ…„’”››“““u{{¦§¨”“›‹…’’ŒŒ£››¤¤£››¦§¨¨©´Œ‹““Œ”¨©´¦§¨”“›‹‹„redtllš””›¢›¦§¨Šƒ}£œ¥VTLztl„Š}¤¤ƒ‚u‹„„sleztlVTL{u{Œ‹“Š}ƒ“Œ”“Œ”‹„‹f]c™š¤£²£œ¥…„’|„…u{{mtttt{lksŒ”•“““œ¤¦™š¤™š¤œ¤¦››”ƒƒ||‚z„Š„|„…‹’Š‹‹„|„…u{{¨©´Œ‹““Œ”“~ˆbVUtslŠ~‹”››„„ŠJHFek]lks\[[¦§¨lrilri\UZbVUŒŒšƒ„„’…‹ult“““kd\zll[TTd\\uzt‚|usre’ŒŒd\\uztmw[[TSKJƒƒ|JHFd\\ult”“›JHF*)(‚|uztl”š”redƒ‚ulekrg]ztl¦§¨’…‹”š”‹‹„ult‹’ŠŠƒ}sre£››ult|‚z‘Œ…tts‹„‹fkk|‚zŠ}ƒ‹„„””‹£››’ŒŒ“Œ”sre…‹‹œ¤¦llk{u{›¢›“Œ”¤¤ƒ„„›¢›{||„Š„¨©´¦§¨¦§¨”››{u{lldu{{…‹š|„…uztultLKRVTL\UZlek“Œ””››”››uzt‹„„‹‹‹tts{u{…‹’™š¤œ¤¦[[T{{ƒlldultllkƒƒ|‚|u‹’Šztlƒ}ƒred„Š„ƒ„„‚v‚lddš””tsl{ttœ››¨©´uzt…‹‹lldlksƒ||Š~‹›”›‹„„lri[TTtslf]c„„Š‚uttsltll‚v{Š}ƒ”“›ƒ||ƒ||‹„‹lksƒ||‹‹‹|‚zult{{ƒ¦§¨Œ”•œ¤¦™š¤Œ”•¡¡œ¤¦œ¤¦|„…|„…Œ”•„„Š¦§¨{{ƒ”“›„„Š“Œ”£œ¥™š¤™š¤‹„‹¨©´¦§¨{{ƒ¨©´›”›™š¤™š¤““““Œ”Š}ƒ²««{u{llk…‹‹’…‹··Ä‚v‚yfdƒ||‹‹‹‹„‹™š¤™š¤rfk“Œ”‹…’ƒ}ƒ‹’Š›”›™š¤ƒ„„‹‹‹Œ‹“{||ƒ„„ztluztlri‹’Š|„…lrillktt{|„…‹’Š{{ƒ]cd]cdœ¤¦mttfkkfkk{{ƒŒ—£¬¶Ã™š¤|„…}‡’™š¤…‹’…„’”“›|„…Œ”•{{ƒ‹…’mtt{||„„Š‹‹‹¸Á¹lld””‹Œ”•lri‹‹„kk]ƒ„„ƒ„„lldŒ‹“…‹‹‹„‹…‹’ddc|‚zlld‹„‹ƒ||„„Šddcldd{{ƒ{{ƒJHFUUYu{{lddJHFf]clddƒ||ttsllkŒ‹“lri‚v{ddclldj]\dc\Š}ƒ„„Šƒ}ƒlriƒƒ|¦§¨JHFJHFuztlld{ttztlšŒllkjV[|‚z|‚zkd\“Œ””š”Œ”•uzttsl””‹‘…„„„Š„Š}|‚z“““ztlŠƒ}tsltts{tt„Š„¦§¨‹„„œ¤¦”››{||“Œ”Œ‹“ult|‚zlek£››µ¶·ª³·›¢›…‹’¦§¨Œ”•‹‹‹£œ¥œ¤¦‹‹‹”››uzt]bZMRKlld]bZ|„…tt{‹„‹…‹‹‹‹„™š¤{{tllk…‹‹‹’Šƒ||œ››u{{…‹‹„Š„ƒƒ|Œ‹“|‚zbVUtsl‹’Šlldfkk|„…‹„„tslsred\\fkklddŠ}|{{tƒ}Š¦§¨{||…„’‹’Štts]bZ{u{¦§¨†~‘¤¤ƒƒ|ƒ||{u{tts{||f]c‚|u“Œ”|„…ttsœ¤¦””‹ŒŒšŠ~‹ldduztu{{…‹‹…‹’ƒ„„|„……‹‹Œ—£Œ”•}‡’|„…|„…mtt|„…ƒ„„‰Š¡Œ”•‹…’œ››™š¤{{ƒ|„…Œ”•™š¤|„…£œ¥‹…’“Œ”ttstt{²¬µ””‹¨©´“Œ”…‹‹™š¤uzt{ttƒ„„‚ut¦§¨Š~‹“Œ”ƒ}ƒ‘Œ…Š~‹f]cmw’…‹ƒ}ƒš”””“›‹„‹ª³·‹„‹llklek“““œ››tts{{ƒlrilri’ŒŒŒ‹“…‹‹…‹’™š¤edkultJHFlks{{ƒ…‹š{{ƒlksedk|‚z’ˆ|‚zŒ—£Œ”•lks””‹|‚zuzt‹‹‹„Š„¦§¨¦§¨‹„‹Œ‹“›¢›Š}|””‹Šƒ}ƒƒ|ƒ‚u””‹VTL””‹‰|vŠŠ}slerr]tzl|‚zƒƒ|[TTƒƒ|lriŠŠ}‹’Šƒƒ|tslUTS”“›d\\|„…ekd‹…’uztyl„[[TŠƒ}“““‹„‹Š~‹””‹VZT””‹lek‚v‚lldultztlf]c{ttF=Ckk]rg]²««UTS*)(slej]\…‹‹Š}|‚|ulddŠŠ}ŠŠ}‹’Š›”›”“›””‹“““ttsrg]sle‚|utt{VTLsleztlŠ}ƒ„„Š‹„„zll›”›”š”””‹¤¤ƒƒ|œ¤¦“Œ”¦§¨Š}ƒ‹„‹u{{{{ƒ“Œ”¤¤’…‹Œ”•ttsŒ‹“‹’Š¦§¨“Œ”¦§¨£œ¥™š¤|‚z‹‹‹lriUTSJHF[TT{{ƒ{{ƒƒ„„œ››ŠŠ}œ¤¦ƒƒ|uzt{{t{||fkkŒ”•œ¤¦tslmttsre{ttu{{Šƒ}b[Uƒ„„…‹‹ƒ}ƒ{||””‹tzlkd\74,{u{ztlŠƒ}ztl™š¤ƒƒ|ƒƒ|uztmtt{u{™š¤‹…’f]clriŒ”•‹„„d\\„„ŠŒ‹“ƒ„„lddttsultult›²Œ‹“ƒ}Š“““ƒ„„[TTlks{{ƒŒ”•‹‹‹…„’|‚z|„…fkk‹’Š|„…‹’Š|„…¦§¨““““Œ”{{ƒ“Œ”‹‹‹‹…’”“›ttsu{{›¢›””‹]cdtts{u{ƒ||\[[ƒ}ƒ”“›“Œ”ƒƒ|kd\{zm‹‹‹Œ‹“ttsšŒŒ”•ekdttsf]ctlldc\tzlJHF{||lkstll’…‹¦§¨’…‹£œ¥‹…’”“›{{ƒ”“›¦§¨lkszlld\\dc\‚v{red‰v|{u{f]cedku{{ª³·””‹ƒ„„“~ˆllkekduzt›¢›|‚z‹’Š›¢›‹’ŠŒ”•ttsmtt‹’Š‹‹‹ƒ}Š£››“““›¢›{||tll„Š„kk]{||tll›¢›‹‹„llklri|‚zVTLek]„Š„””‹dc\‹’Š|‚z””‹ƒƒ|dc\{{t{||lksmttultœ¤¦mtt{{ƒƒ}ƒ{{ƒ…„’Œ”•‹‹„””‹™š¤ƒƒ|[TTsresle{||lld]bZrr]JHFttsJHF{zm‚|u””‹JHF:97tsllrilldƒƒ|Šƒ}‹„„ƒƒ|‘Œ…‹’Š””‹Œ‹“‹’Šƒ„„‹’ŠŠƒ}Šƒ}‘Œ…’ŒŒƒ‚uƒ‚ukd\Œ”•‚v{™š¤œ¤¦Œ‹“””‹››”ƒƒ|”“›¦§¨“Œ”Œ”•tt{ƒ}ƒ{u{”“›Œ‹“›”›u{{“Œ”lksƒ||lriš””œ¤¦’ŒŒƒ„„|„…|„…{||llkmttf]c{{ƒ{||“Œ”‹‹„{{t|‚zœ››ƒ„„Œ”•”š”uzt„Š„lek„„Šdc\tt{Œ‹“kk]lekƒ||d\\|‚z|‚z{||ƒ||ƒ||‹‹„kd\VTL{||tll£œ¥sre¨©´¦§¨|„…„Š„ƒ||”š”’…‹UMR†~‘’ŒŒœ››ƒ}ƒ‹„„{ttš””œ››‹’Šƒ||kk]ƒ}ƒ{{ƒ›”›¦§¨‹„‹‹’Š{u{Œ”•{{ƒ|„…{tt‹’Š|‚zƒƒ|„„Š“““Œ‹“„Š„{||{||{{ƒ…‹‹™š¤ƒ„„{||„Š„…‹‹„„Šœ¤¦„Š}ttsuztUTSUTSSKJSKJƒƒ|‹„‹“Œ”…‹’Œ‹“Š}ƒ‚ut£œ¥ultš””sle„Š„lksddcd\\lekƒ||uztddctslƒ}ƒ¦§¨{u{…‹‹\[bƒ}ƒ””‹„„Š„„Š{{ƒf]c]cdJHFultllkŒ”•‹‹‹tslƒ||””‹lddD;9lldbVUuztekd|‚z{ttek]|‚z›¢›Œ”•‹’Š‹‹„|‚z|‚z””‹‹’Š›¢›‹’Š“““‹’Šœ¤¦Œ”•|‚z|‚z‹‹„ƒ„„ƒƒ|‘Œ…ƒƒ|yle‘…„ekd’ŒŒ‘ˆ}ƒ||ƒ||[[TbVU‹’Š‹„„ƒ„„‹‹‹”“›{||‹’Šœ››Œ‹“ƒ||{{t‹…’|„…™š¤dc\…‹‹\[[mtt›”›lld[[TSKJVTLƒ„„„Š}tts‹„„|„…\[b{{tj]\””‹JHF*)({tt|‚z‹‹„‚|uŠŠ}Šƒ}‚|u{zmdc\‹‹„leklld|„…‘…„{{t››”slellk””‹””‹ƒ||‹‹„’ŒŒuzt{||Š}ƒz‚lƒ||ƒ||llkš””{u{|‚z†~‘“Œ””š”{{ƒ‚v{¦§¨Œ‹“mttlekŒ”•ƒ‚u™š¤Œ”•¦§¨œ››‹‹„llk{{ƒldd|„…{{ƒekdœ§²{ttƒ„„”“›|‚z…‹‹ƒ„„‹’Šƒƒ|tts“Œ”ldd{u{|‚z‹…’‚|u|‚z›”›tllztldc\‹’Šœ¤¦‹„„””‹››”b[U[[TddcVZTtlldc\ekdldduztlriƒ||{ttlek‹„„ƒ}ƒ„Š„u{{ekd’ŒŒ{||™š¤¤¤ƒ}ƒzll{{ƒ‹„‹ult¦§¨¦§¨£œ¥’ŒŒ‹‹„›”›mtt{{ƒ¦§¨{{ƒƒ„„{{ƒŒ‹“‹‹‹”››™š¤mttek]lriƒƒ|ƒ„„|‚zœ¤¦…„’|‚z‹‹‹”š”{{t„Š„‹‹„lldultttsUUYŒ‹“dc\“““›”›„„Š‹„„£››‰v|£››··Ä’ŒŒŠ}|‚v{s_qred”“›ƒ}ƒVTL‹„„]cd’ŒŒ¦§¨›¢›tzl‹‹„tzlmtt‹’Š{||‹‹‹f]c[[T|„…lksedk‹„‹\[[ƒ}ƒ‹„‹tt{‚|u{{ƒƒ}ƒb[U{{ƒd\\tt{|„…™š¤mtt{{ƒ”››{{ƒ…‹’™š¤¦§¨£²‹‹‹ŒŒš‹’Š“““Š}ƒšŒ‹„„ƒƒ|œ¤¦”››ƒ||‹‹‹redslej]\ultbVU£œ¥r]Z‹„„cbVkd\sle‹„„lddkd\{tt“Œ”tll‹…’\UZ„Š„VZ[dc\edkŒ”•uzt[[TŒ‹“[TT\UZƒ„„lld[[Tzll‹…’””‹kd\š””‹„„›”›ŒŒšVTLj]\œ¤¦>EC:97ultŒ”•|‚z{{t“““zll ztl”š”‘Œ…VTLƒƒ|„Š}Š}|šŒ£››‹‹„„Š„š””Š}|red”“›{tt”“›{tttll”š”“““tts‹uŠult™š¤‹…’…„’“Œ”ƒƒ|™š¤¦§¨ƒƒ|ultdc\{u{“““¦§¨’ŒŒŠ}ƒ„Š„‚v‚…‹’edk„„Š{{ƒ{|||„…LKRtslmtt‹‹‹u{{‹‹„ttsd\\ttsuztldduztj]\ƒƒ|tt{llklddkk]tt{‚|uldd|„…›¢›™š¤{zm„Š„™š¤„Š„„„Š|‚zlrid\\‹„„ƒ||ekdlekœ¤¦|‚z|‚z{u{{zm[TT|‚zttsUTS‚|u{{t‹’Š’ŒŒ›”›ƒ||Œ”•œ¤¦™š¤˜Ž£{{ƒ“““{tt“Œ”fkklks{{ƒŒ”•‹…’ŒŒšª³·‹‹‹…‹‹Œ”•Œ‹“|„…”››]cd…‹’tt{fkktt{|„…|„…”››mttulttts”“›™š¤…‹’‹„‹“Œ”“Œ”£œ¥f]c|‚z¦§¨|‚z”››{u{“Œ”‹…’{u{‹’Šult’ŒŒ’…‹“Œ”kd\SKJkd\tllŒ‹“Œ”•’ŒŒ…‹’ƒ}Š{{t{{t„Š}‚uttslSKJJHFb[Uƒƒ|tsl‰ƒvlddƒƒ|]bZ”“›dc\mtt|„…ttsVZTult…‹’|„…{{ƒ‹…’ŒŒšƒ}ƒ{u{‹„‹ƒ}ƒ’ŒŒ··Ä‹…’£œ¥ƒ||bVU“““››”Š~‹ult|‚zŠŠ}dc\ldd|‚ztslUTSSKJ””‹‹‹„lld[TTslej]\\[[MRKŒ”•[[T{{tƒ„„„Š„lksllk{||œ››{||Œ”•mttlrimttddc[TTj]\„Š„Šƒ}kk]lddtsl‹‹„‹‹„£››u{{{u{\[bVZ[ƒ}ƒƒƒ|JHF*)(tll|‚z‚|u””‹‹’Šyle‚utkd\sleƒ||j]\{{t“““‰ƒv¤¤›¢›””‹ddcŠƒ}kk]ztl’…‹’ŒŒ‹„‹ƒ||ƒ}ƒtts‹’ŠŠ}|ƒ„„{tt…‹‹„„Štt{Œ‹“£œ¥™š¤”“›|‚z”š”””‹„„Štts{tttslƒ„„{{t{u{tsllriŒŒš‹uŠVTL\[b[[Tedk‚|u¦§¨ƒ„„|‚zlektt{{{ƒlddttsƒ||leklddlldtllŠƒ}‘Œ……‹‹››”tllƒ||„Š„tsl\[[{||ult{{tMSS|‚z|‚zu{{ƒƒ|„„Š„Š„lddu{{|„…”“›{ttƒƒ|sleSKJfkkVTL{ttztltzl‚|uŠƒ}“Œ”{{t„„Š{{ƒ‹‹‹{zmtll‚v{“Œ”ult›”›{{ƒƒ„„”“›ƒ„„¦§¨”››|‚znv‚ultmtt„Š„…‹’£œ¥œ››“““œ¤¦“““”“›ult‹‹‹|‚z…‹‹ª³·²¬µ£œ¥”“›œ››™š¤œ››¦§¨¦§¨¦§¨‘Œ…ttstt{Œ”•ƒƒ|{{tkd\›”›„„Š”“›dc\”“›{{ƒ‹‹„kd\ultŠƒ}‹„„‹’Š{tt’ŒŒŠƒ}šŒ‘…„“Œ”‹‹„kd\iq]|‚zUTSƒƒ|””‹{tt‹’Šllk‹‹‹[TTedklksu{{„„Š]bZVZ[lri]cdlek‹„‹|„…lekllk„„Šllkkk]‹‹„‹‹‹{ttœ¤¦{{tllkƒ||ƒ‚u””‹››”‹‹„‚|ulksllkb[Udc\VTLjcVcbV]bZlddVTLƒ}ƒ”“›dc\\[[uzt{{tlksttslddmtt|‚z™š¤]cd“““‹„„‹‹„lld{u{‹’Š[[TVTL{{tlrillk{{tƒ‚uddc[[TedkmttUMR‹‹„>EC74,ƒ|||‚z„Š„‘Œ…tsl‚|utllkd\{zmldd|‚z]bZ‹‹„‚|uŠƒ}Šƒ}¤¤œ››tt{{zmœ¤¦ƒƒ|ztl{u{lks‹„„”››|‚zŠ}|“Œ”ƒ}ƒ£œ¥‹’Šu{{”“›’…‹ƒ||‹„‹œ››Œ”•Œ”•{ttf]c[[Tsre{|||‚ztsl‹‹„ldd„„Š“Œ”]cdtt{””‹{{ƒlks|„…™š¤œ››lksfkkƒ||ƒ„„tllSKJlddSKJ[[TlekŠƒ}‹‹„ƒ„„‹‹‹ult‹‹„ekdlld\[[ƒƒ|‹„„‚|uMSS\[b\[[lld„Š„Œ”•Œ”•d\\edk„Š„”š”š””f]cœ››kd\|‚z„Š„ultƒ|||‚z¤¤ult‹‹‹ƒ„„’ŒŒ“Œ”ultŠ}|ƒ„„edkf]c{{ƒœ¤¦…‹’›”›„„Šlksƒ„„|„…{{ƒmttmtt|„…{u{…‹‹›¢›œ¤¦Œ‹“|„…tsl{{ƒ{{ƒŒ‹“¨©´™š¤Œ‹“£œ¥¦§¨£œ¥¦§¨µ¶·»ÂǦ§¨Šƒ}sre‹’Š‚ut“Œ”sreŠŠ}”š”{{t{u{‹‹‹¦§¨Œ”•Œ‹“’ŒŒ‹„„{tt›”››”›¦§¨…‹‹|‚z¦§¨š””‰‰w‰ƒv{{tƒ‚ukd\‚|ulldtslŒ”•›¢›{{tœ¤¦…‹‹tt{lek…„’lks‹„‹“Œ”™š¤ultŒ‹“›¢›£œ¥‹…’ƒ}ƒu{{ulttts{ttŠ~‹ultllkƒ||ƒƒ|£œ¥llkœ¤¦Œ”•u{{™š¤ttsƒƒ|‹„„‘Œ…kd\‹„„ƒ||ult|‚zllk’…‹kd\ƒ‚usre„Š}VZTŒ”•ekd„Š„lksJHFUMRlri|„…]cd…„’›¢›‹„‹ƒ„„bVZ|‚zlldUTS‚|ulldƒƒ|ƒƒ|dc\sleVTLJHFJHFJHFztlJHF3+*{u{››”ƒ‚u]bZtsl‚|u{tt‚ut{{tjcVb[Ukd\ttssle£›››¢›ƒ||{u{’…‹{u{’ŒŒrfk‚ut“““fkkƒ}ƒƒ„„llkœ››ult‹„„{||Œ”•ƒ}ƒ›”››”›„„Š’…‹‹’Š|‚z„„Šf]c{u{‹‹‹‹’Š‹„‹zll\[[tt{”››…‹’lekdc\\[bf]cult{{tllk„Š„‹‹„llkƒ„„lddƒ}ƒ‹„‹‹„„ƒ‚u‹„‹f]c‚v{‚|u‹„„“““ultVTL›¢›“““uztttsslef]cƒ||ddc\[[|‚z„Š}œ››u{{Œ”•ldd…‹’…‹‹„Š„ƒ||Œ—£››”ª³·|„…tllrfktts™š¤””‹lek{||{||ƒ„„‹…’tzlƒ„„{{t¦§¨“““|„…{u{|„…Šƒ}lriedkllkƒ}Š{{ƒ¦§¨|„…|„…ƒ„„“““…‹‹Œ”•|‚z””‹‹’Š›¢›‹’Š|„……‹‹„Š„…‹‹”››”“›{{ƒ¦§¨”“›™š¤ƒ||š””bVU¦§¨ª³·redtll£œ¥‹’Š’ŒŒ‹„„ÃÄƨ©´¦§¨Œ”•‹„‹“““’ŒŒ‘Œ…‚|uš””dc\ŠŠ}‚|u””‹””‹‚v‚›¢›‰‘~]bZuztkd\lek‰‘~\UZ‹‹„Œ”•ª³·›”›””‹|„…bVZultf]cf]cƒ}Šƒ}ƒƒ}Š‹’Š™š¤fkk{{ƒ{{ƒmttUTStzl‹„‹Œ‹“Š}ƒ‹„‹›”›tllultult”š”£››‹…’{{tultdc\Œ‹“u{{uztekd[[Tlridc\|‚z„Š„lrisleddctzldc\VZ[lriUTS\[[ddcVZT|„…‹„„fkkƒ}ƒbVU™š¤tt{ƒƒ|tsl‹„„lld{zmlriƒ‚ulldf]c{ttUTS|‚z›¢›JHF*)(lksuztuzt””‹”››zllƒ‚uƒ‚u{tt{tt£››uzt””‹šŒŠƒ}””‹’ŒŒ{u{ƒƒ|bVU‚|uŠƒ}tllƒ}ƒ{||ª³·‹„‹Œ”•¦§¨uzt‹‹„›¢›”“›œ¤¦{u{£œ¥lek‚v‚Œ‹“tts{||’}™‚v{{u{{||{{t{u{SKJlld{{t|„…{u{””‹„„Š…‹šult{u{lld{||{||{tt„Š„ƒ}ƒj]\Š}ƒs_qzllƒ}ƒ‹„„‹„‹tsl‚|ud\\zllcbVtslŒ”•mtt„Š„tsl\[[tll\UZ{zmuzt›¢›”š”u{{ª³·u{{|„…„„Š{{tƒ}ƒ“Œ”œ››š””¦§¨ttslekŠƒ}uzt{{tult‘ˆ}{tt{{ƒŠ~‹‹‹„‹’Š””‹ƒ„„š””ttstt{{{ƒuzt…‹‹”“›‹‹‹™š¤™š¤…„’tt{lddƒ„„™š¤|‚zu{{Œ”•ª³·‹‹„|‚z„Š„|„…”š”›¢›tslƒ„„…‹‹tt{tt{ddcddcSKJ{tttll“Œ”™š¤”“›‚v{…‹‹ƒ}ƒ‹„„£œ¥¦§¨£œ¥“Œ”¨©´“Œ”¨©´¦§¨µ¶·ƒ||™š¤ztl“Œ”””‹mw‹‹„{||uztfkkMRKlrilrillk”››ddc…‹‹ŠŠ}{||edk{{ƒf]cleku{{”››u{{mtt{{ƒtslŒ”•ƒƒ|‹’Šmtt”››™š¤„„Š|‚z{||Œ”•™š¤”“›¦§¨œ››tslƒƒ|dc\Œ”•{u{edkƒƒ|JHF„Š„VTLVTLŒ”•iq]VTLu{{]bZ„Š„lekllkuzt\UZ‹„‹ttsJHF]bZ‚v‚JHF]cd]bZSKJ‹„„›”›‚utƒ}ƒŒ‹“ƒ‚ub[UlldcbVzll|„…Šƒ}|„…{{t|‚zmttmttšŒJHF*)(ldd”š”{zm‰ƒvƒ‚u{zmŠŠ}ƒƒ|{{t‚ut‰|vŒ‹“””‹¤¤‚ut‹‹‹‚v{{||tts‘Œ…‚|u’ŒŒ¦§¨™š¤{tttts““““Œ”{zm“Œ”“Œ”ƒ}ƒ‹’ŠŒ‹“{u{tll‘…„tt{ztl|„…{||ƒ}Š‚v‚{||llktlllldlddlri‹’Š˜Ž£Œ‹“ƒ}ƒ{{ƒf]cultƒ||ƒ}ƒŒ”•mtt’ŒŒ‹‹„f]cƒ||ultrfkulttll“Œ”Š~‹ŠŠ}{tt{||{ttddctzluzt‹’ŠŒ”•‹‹‹£››š””ttsuztƒƒ|‹’Šƒƒ|edkttsŒ”•›¢›{||Œ”•œ››ŒŒš²¬µ””‹¦§¨{{ƒ›”›{{tmtt””‹ƒ||’ŒŒ{tt”“›¦§¨¦§¨Šƒ}””‹Œ”•ƒƒ|ttsƒ}ƒd\\lekttstt{‹‹‹|„…„„Šƒ}Š›”›‹„„“Œ”ƒ}ƒ™š¤£œ¥‹„‹’ŒŒƒ„„”“›Œ”•tts{tt¤¤™š¤”››“““ekdŒ‹“Š}|b[Uzll„„Š{tt¦§¨œ››œ¤¦Œ”•ƒ}ƒlksult{u{“Œ”†~‘™š¤™š¤²¬µƒ}ƒ™š¤tll“““Œ‹“¨©´‚v{£œ¥’ŒŒ“Œ”‚v{tll£››‹’Š{{ƒ|‚z|‚z„Š„Œ”•‹‹„””‹‹‹„lld„„Š…„’f]cƒ}Š„„Š”“›{{ƒ…‹‹]cduzt™š¤ª³·›¢›œ¤¦”››¦§¨„Š„‹’Šƒ}ƒ£››{{ƒœ¤¦…‹’„Š„””‹‹’Š‘ˆ}“Œ”‚v{[[Tuzt{||{{tVTLcbVllk|„…tzl[[TuztUTSuzt\UZVZ[‹„‹Œ”•ekdtll\[[uztUMRlri[[Tttsƒ}ƒ’ŒŒ£œ¥|‚zƒ„„‘Œ…kk]ekd{zmƒ„„‹’Šƒƒ||‚ztzl[[Tedk‚v{:973+*|‚ztts‹‹„lld{zm‘ˆ}ƒ||ztl”š”„Š„lddœ¤¦””‹¤¤‚|utslƒ||‹„„Œ‹“‹‹„‹‹„¦§¨‹„‹”“›Œ”•’…‹™š¤››”‹‹„¦§¨£œ¥…‹’¦§¨™š¤“Œ”{tt”›››”›ŒŒšµ¶·™š¤··Ä…‹’‹‹‹{{t“““‹‹‹{u{ƒ||lrif]c{{ƒ\UZ\[b™š¤f]c{{ƒŒ‹“‹‹‹…‹‹™š¤…‹‹Š}ƒ“Œ”ƒ||[TTƒ}ƒ\UZ{u{sle’‘~””‹”“›“Œ”‚ut|‚zƒƒ|‹’Š‹’ŠlriuztSKJ{||ult“Œ”œ››‹„„lksMSS|„…„„ŠŒ”•{{ƒ”š”‹‹‹ƒ}ƒ‹‹„|‚zlks¦§¨’ŒŒ{||‹„‹ƒ||‹„‹„Š}‹„‹µ¶·œ›››”›ƒƒ|‹„„›”›uztƒ}Š{ttttsŒ”•‹„„„Š„„„ŠŒ‹“Œ‹“ƒ||ultƒ}ƒ„vŒ¦§¨ƒ„„uzt””‹’…‹ƒ„„ª³·tts…‹‹Œ‹““Œ”lddŒ”•lddtsl›¢›‹…’£››¦§¨™š¤µ¶·lksŒ‹“Š}ƒ“““ultlks™š¤ult‹‹‹™š¤„„ŠlddlddŠ~‹‹„‹ƒ||™š¤Š}ƒ…‹’Œ”•”››”“›ultœ¤¦tllŠƒ}“““””‹¤¤™š¤|‚zlridc\“““|‚zekd„Š„lri|„…tslŒ”•f]c™š¤ƒ||{{tŒ”•ƒ„„ƒ„„{{ƒ…‹‹uzt“Œ”„„Šµ¶·¦§¨|‚zƒ„„ƒƒ|lldllduztkk]“““]bZ””‹{tt„„Šllk[[T|„…mttddc‹’Šƒ„„‹’ŠVTL{{ƒ”››ƒ}ƒŒ‹“f]cUTSlkslkslri{||Œ”•lksttsult››”ultlks‹„„£››””‹ŠŠ}ƒƒ|‹‹„{{tdc\]bZ|‚z[[T[[T¦§¨LKR*)({{ƒtll””‹œ››{zm|‚z‘Œ…{{t””‹””‹£››™…””‹‘}zŠ}|””‹{tttt{Œ‹“uzt“Œ”£››ƒ}ƒ“Œ”{||ƒ}ƒŒ‹“Š}|””‹“Œ”œ››Œ‹“ddcƒ„„“““”“›’ŒŒ…‹‹{u{Œ”•™š¤{{ƒ¨©´Œ”•{||ttslek‹„„u{{ttslek\UZlddVZ[£œ¥ƒ}ƒlkstt{{||tll’ŒŒttsrfkŠ}|‰v|lddrg]‚v{„„Š“““„„Š‘Œ…Œ”•‚utldd‹’Šlldekdtzlekd„Š„tlllldŠ~‹{{ƒŒ‹““““}‡’\[[f]cŒŒš|‚z{||’ŒŒllk‹‹„llkƒ„„”››‹‹‹{tt’ŒŒšŒ²««››”“““£œ¥‹…’‹‹„|„…š””lldƒ„„tts{u{‹„‹‹„„{{ƒ“Œ”{{ƒ™š¤…‹‹Œ”•ƒ„„ddc¨©´ttsult™š¤ult{{ƒ¦§¨””‹Œ”•|‚z‹‹„{{ƒ™š¤Š}ƒd\\„„Š{tt‚v{ƒ}Štt{tll”“›œ¤¦…‹‹“Œ”›”›™š¤“Œ”f]c‚ut{{ƒ“Œ”\UZ‹„‹rfk™š¤ultƒƒ|ƒ||“““‘Œ…uzt¦§¨llkŠ}ƒ‹„‹›”›‹„‹ƒ„„sle{u{”“›‹’Šœ››d\\]bZtslŒ”•lrillkmtt{ttmtt‹„‹d\\ƒ|||„…Œ”•”››™š¤…‹‹„„Š…„’“Œ”“Œ”¨©´‚v{…‹‹ultŒ‹“|„…‹’Štsltzl{||ƒƒ|lriuztlks“Œ”””‹ztlƒƒ|‘Œ…|‚z{{t{{t[TTlldekdƒ}ƒd\\{u{d\\[TTJHFVZTuzt{||ekdf]c{{ƒlekƒ||‹„‹…‹‹lrizllztl“““tzl|‚z{{t„Š„]bZ‹’Š]cdu{{²²¬:97*)(kk][TTƒ‚uƒƒ|uzt‘Œ…Šƒ}””‹²²¬””‹‘ˆ}Šƒ}””‹sleŠ}|””‹¦§¨›”›™š¤œ¤¦‘Œ…“Œ”“Œ”ultƒ„„¦§¨¦§¨ƒ„„Š}|››”²««™š¤‹‹‹ƒ„„“Œ”£œ¥œ››“““œ››””‹„„Š“Œ””››£››{||‹‹„‹’ŠŒ‹“edk|‚zŠƒ}{{ƒd\\]cd‹’Š|‚zŒ‹“ƒ}Š”››£››™š¤ƒ}ƒ›”›Š~‹ylemttkd\ddcf]c{u{sreŠ}ƒttskd\“Œ”‹’Šzlldc\llktslttsd\\|„…ultu{{tts‹’Šlrilksddc”“›lksddcƒ||lksŠƒ}¦§¨Šƒ}|„…””‹|‚z{{ƒ…‹‹Œ‹“››”{tt‹‹‹Œ‹“‹„„rfk{zmtsl{{tŒ”•“““‹„‹””‹œ››‚v‚{{ƒ¨©´™š¤ƒ}ƒ‹„‹ttsƒƒ|ƒ„„…‹‹”“›‹„‹{{t¦§¨ƒƒ|™š¤ttsŒ”•Œ‹“„„Š£œ¥”š”¦§¨ƒƒ|‹„„{{t“Œ”‘Œ…™š¤‰v|‹‹„‹‹„¦§¨Š}ƒƒ}ŠŒ‹“’}™„„Š„„Š”“›ƒ}ƒ‹…š\[b£²ƒ}ƒddc”š”{{ttllf]cƒ‚ulritsl›”›Š}|{zmƒ||ƒ}ƒ„Š}]cd„„Šu{{u{{[TT{{ƒmtt‚v{”“›|„…ztl…‹‹{{ƒtll{u{¦§¨œ¤¦…‹’…‹‹{{ƒ|‚z‹‹‹™š¤…‹’”“›”“›Œ‹“š””|‚z‹’Š|‚z””‹lrikk]|‚z”š”Šƒ}tzl¤¤“““tllƒ„„llk“Œ”“Œ”{ttŒ‹“ƒƒ|\[[kk]ƒ||tllVZT‹‹‹|„…u{{tt{|‚z‹„‹]bZƒ}ƒ[TTtt{lri{||ultlld|‚zllkekd[TT{||mtttzltll{||²««F=C7-2‚ut‹‹‹„Š„ztlƒ||‹„‹{zmsrekd\{{t¤¤sle›¢›ult””‹‹‹„‘…„‹„‹ƒ„„z‚l’ŒŒ‚utš””{u{‹„‹Šƒ}ƒ}ƒmtt£››Šƒ}™š¤{u{‹’ŠŒ‹“‹…’Œ”•“Œ”“Œ”™š¤uztŒ‹“›”›…‹’‹’Š’ŒŒ|„…„Š„lksmttŒŒš{ttu{{{{tuztŒ”•dc\tt{ult{||ƒ„„›¢›…„’ƒ||tll‹„„[TT{{tddc‚ut{||„Š„\[[Œ‹“{||Œ‹“‹‹„ekdlldƒƒ|{{t{||tts\[blksƒƒ|™š¤‹‹„lrilks}‡’Œ”•™š¤‹‹„›”›llklddllk„„Šllkf]c\[[“Œ”””‹›”›‘Œ…œ››tts‹„‹Œ‹“‚|u’ŒŒƒ„„lldu{{£››™š¤œ¤¦…‹‹”“››”›edk‹…’“Œ”™š¤Š}ƒƒ„„„„Š‹…š‹…’””‹Š}ƒ‘Œ…‚ut‹„‹‘ˆ}‚|u‹’Š{||Š}|tts‹’Šsreƒ„„Šƒ}Š}ƒ£œ¥£››Œ‹“‹’Š„Š}™š¤›”›“Œ”‹u…œ››“Œ”Š}ƒ{{ƒ“Œ”“Œ”‹‹‹„„Šf]c{u{‹„„zllldd‹’Š£››ztl{ttttslksedkFD;kd\””‹z‚l[TTŒ”•“Œ”™š¤}‡’UMR\UZ…‹’|„…„„Šlks…‹šedk…‹‹UTS…„’Œ‹“™š¤u{{u{{™š¤|‚zyl„¦§¨{{tŠƒ}‹‹‹{{tllkd\\ƒ||{{ƒ|„…ult{||]bZ{{t”››””‹lddVTL¦§¨„Š„{||”“›ƒ||“““{{t|„…mttf]cuztultlks‹„‹llktt{{u{edkrfktllƒ}ƒlri{{ƒ{tt‚|u„Š}ztl[[TztlŠ~‹|„…{{tlldlld²««JHF*)(tsld\\|‚z’ŒŒƒ„„ztl‚wl[[TŠŠ}‚v{’ŒŒu{{‘Œ…’ŒŒƒ}ƒ‹‹„‘…„{ttƒ}ƒ„Š„‹’Š“~ˆzll‹‹‹£››„Š}‰‘~„„Š‹‹„„Š„“Œ”™š¤ttstts{u{‹‹‹|‚z¦§¨Œ”•‹’Š™š¤{||™š¤ƒ||tll‹’Šlritt{\[b|„…ƒ}Šœ¤¦ekdldd|„…ƒƒ|‹„„ŒŒšllk{{t|‚z|‚ztslƒ}ƒ‹„‹{{ƒult…‹‹{{tcbV{ttŠ}ƒ“Œ”ƒ||cbV‚|u{||”š”›¢›‹’Š„„ŠVTL\UZŒ‹“Œ”•Œ”•ƒƒ|œ¤¦{{ƒŒ‹“ƒ„„”š”‹’Š“““|„…ƒ||‚|uyle|„…{tt„Š„ƒƒ|ƒ„„ƒ„„‘…„”“›tllŒ‹“llktts|‚ztts‹‹„„„Š”“›ƒ||Š~‹Œ”•„Š„|„…f]c{{ƒŒ‹““Œ”Š~‹ƒƒ|¨©´lld{u{{{ƒ›”›“Œ”lri{{ƒ’…‹Œ”•‘…„£œ¥‹„‹{{ƒŒ”•›”›™š¤‹‹‹ztl‹„„¦§¨‹‹„ƒ„„””‹“““Šƒ}‹„‹tlltsl‹‹‹ƒ}Šf]c{u{tts{||‹‹„Œ‹“[[T¢“d\\zllj]\‹„‹‚v‚“Œ”‘Œ…››”SKJ‚v{sre\[[œ››””‹Šƒ}|„……‹‹{{ƒmtt„„Šf]cŠ}ƒttsƒ}ƒtzlVZTƒ}Š\[[ultdc\lri|„…{{tu{{œ¤¦œ¤¦””‹…‹‹‹‹‹‹„„””‹ƒ„„ultƒ}ƒddc”“›Š}|VZTVTLuztmttJHF|‚z|‚z”››lld›¢›„Š}›¢›‹‹‹lld‹‹‹ƒ}ƒtts|„…ultf]cddc[TTtslf]c”“›‹„‹{{trfkŒ‹“>EC{{tVTLlldllk{ttfkktsl|‚z”š”]bZ›¢›£››:97:97Š}ƒƒ||››”tll‚|u¦§¨{{t|„…ztl{{t¦§¨‚|uŠƒ}“Œ”ƒ‚uŠƒ}¦§¨|„…ult””‹dc\sle“Œ”‹„‹‹…’“Œ”‘…„rfkƒƒ|‚v{“Œ”ƒ„„¦§¨{{t‹„‹‹‹‹“““¨©´ƒ„„|„…{||‚v‚tt{¦§¨{{t]cd…‹’tt{uzt…„’{ttœ¤¦ddclri]bZrfk“Œ”|„…{{tŒ‹“|„…u{{ultlriredu{{ƒƒ|r]g{{tƒ}ƒlddƒ||‹„„lddredred›¢›¦§¨œ¤¦„Š„›¢›mttUMRu{{{tt{||srett{ƒ}ƒŒ”•{{ƒª³·””‹£œ¥›¢›ƒ||””‹rfk{||{||ttslri…‹‹‹‹„œ››”“›{||¦§¨‹‹‹ŠŠ}‹‹‹“““›¢›‹„„”“›Œ”•{tt…‹‹‹‹‹”“›Š~‹f]c‚v‚ƒƒ|œ¤¦\[[‚v‚…‹‹Œ”•tt{„„Š“Œ”llk“Œ”‚|u|‚zœ››„„Š‹‹„|„…–¢‹‹…’”››ƒ||lld”š”tt{ƒ„„‹‹„ztfŠƒ}¨©´’…‹”“›„Š„‹’Š{||dc\f]c‹„‹ƒ}ƒ””‹Š}|””‹Šƒ}kd\‹’ŠlekVZTlrisleredzlltllztlsreVTL{{t‹‹„£››‹…š‹„‹‹‹‹‚v‚{{ƒlks|‚z’ŒŒ„Š„uztsle…‹‹\[b]cdƒ}ƒŠ~‹ƒ„„uztmtt”››Œ”•Œ”•ttsmttddc{|||‚z{||sleJHFƒƒ|\[[‹’Š[TTdc\„Š„„Š}lri”“›|‚z\[[›¢›ƒ„„]cd‹’Š„Š„rg]š””ekdtslƒ||ddcuzttt{ƒƒ|Œ‹“„„Šlld‰|vdc\u{{SKJdc\tslVTLlld[TTsreƒ||lriaWMSKJ|‚z£››D;9*)(ƒ„„“Œ”Šƒ}tslƒ‚u’ŒŒ››”‘Œ…’ŒŒ””‹“Œ”Šƒ}£››¦§¨£››{{t¦§¨ƒƒ|‹’Š“““lek‹’ŠaWMª³·‹„‹›”›…‹‹‚ut‹’Š£››Œ”•|„…””‹ŠŠ}£››Œ‹“œ››²¬µµ¶·Œ”•›”›ƒ}ƒŒ”•ƒƒ|[[T’ŒŒ[[T]bZmttd\\ƒ„„{zm’…‹„Š„tsl„„ŠŒ‹“{{t’ŒŒƒ||„Š„ƒ}ƒš””lriztlŠƒ}{ttldd„Š}{u{Œ‹“”“›‹„„‹„‹Š}ƒult…‹‹|„…„Š„|‚z‹‹„‹’Š|‚z””‹„Š„ekd””‹u{{f]cztlƒ„„…‹š”››¦§¨ttsƒ„„„Š}ztfddc‹„„{{tsre‹„‹„Š„ƒ||{tt{||„„ŠŒ”•”š”¦§¨…‹‹›¢›””‹‹‹‹lksult™š¤Œ‹“ƒ„„tt{llk{{ƒsle{{ƒŒ‹“‹‹‹|„…¦§¨Œ‹“…‹‹{{t‹„‹ultŠ}ƒ‰ƒvœ¤¦„„Š’ŒŒ…‹‹llk„„ŠtllcbVŒ‹“’…‹|‚zƒƒ|ztltt{‹„„¦§¨{||mwsreƒ„„‹’Šsleult{tt…‹‹‹„„ŠŠ}ƒ„„ƒ‚uzll‚utylelritll£œ¥‹„‹””‹tlltzlkd\b[UddcŠƒ}lek™š¤›”›edk›”›‚utƒ||„Š„|„…u{{‹’Š|‚zllk{{ƒƒƒ|Œ”•tslŒ”•››”‹‹„™š¤u{{ƒ}ƒlldƒ}ƒUTS””‹|‚z[[Tultuzt¦§¨tt{mtt{{t{{tlld]bZbVUultultUMRŠ}ƒ{||‘Œ…‹’Šb[Uztlf]c{{ƒ…‹‹ultult””‹|„…{||{{ƒ{{ƒkd\„„Štt{fkkf]cd\\‹‹‹‚utzll{{tlrilridc\\[[ekduztš””:97*)(tzlsre‹‹„ƒ}ƒ{tttts””‹¤¤£››“““’ŒŒ‘…„“Œ”²««ƒƒ|‘Œ…ƒ„„{ttttsƒƒ||‚z«²«Œ”•{tt¨©´£œ¥¤¤…‹‹‘Œ…ƒ||¦§¨“““›”›¦§¨›”›™š¤‹‹‹¤¤œ››‹’ŠddclddŒ‹“|„…]bZ\[bƒ||tt{‹’Š‚v‚ƒ}ƒb[U‹‹„|‚z‹’ŠŒ‹“ƒƒ|‹‹‹‹„„{||u{{ldd›”›‹‹‹{u{ŠŠ}kd\zllkd\lek”“›‚v{kd\edkŠƒ}{{ƒ“““|„…£››tts„„Š„Š„[[T{{ƒ‹’Šmttdc\]cdSKJlek…‹‹lkskk]‹‹„{||“““tsllldllkslelld[[T{ttƒ}ƒ£œ¥‹„‹››”’ŒŒ|„…£œ¥””‹ddc|‚zlddƒ}ƒŒ”•‚v{¦§¨‹‹‹Œ‹“’ŒŒult“Œ”œ¤¦ŒŒš“Œ”uztttsŒ”•ldd…„’mwƒ„„{tt“Œ”“““‹‹‹“Œ”’ŒŒultŒ‹“”“›”“›‚v{ƒ„„{||™š¤”››ƒƒ|‹„‹tllš””Œ‹“œ››tsl{{tŒ”•””‹{||\UZ{{ƒ‹‹„µ¶·‹‹‹œ¤¦ƒƒ|{tt‹‹„”š”‹„‹£œ¥’ŒŒ‘Œ…SKJttsjcVldd]bZƒƒ|‹„‹ƒ„„™š¤Š}|lekf]c‹„‹dc\“““„Š„‹’Šttsœ››„Š„“““¨©´„„Š{{ƒŠƒ}lri…‹‹{{ƒƒ}ƒyl„edkbVZj]\›”›[[T‚|uekdd\\{{ƒ{ttddcttsf]c[[Tek]sleult“““lksFD;zllztlƒ||‹„‹tt{UMRfkkultu{{‚|uJHFƒ„„red“Œ”ƒ}ƒŠƒ}{{ƒ{||\UZztl{||ƒƒ||‚z”š”]bZkk]dc\\[[UTS]bZ¦§¨:97*)({{t{ttlddred’ŒŒƒ}ƒ¤¤{zm„Š}²²¬š…Ž‹’Šztfztl¦§¨ƒƒ|“Œ”„Š„£œ¥µ¶·“““¦§¨¦§¨“Œ”…‹‹”š”¦§¨£œ¥›¢›ƒ}ƒ¨©´’ŒŒ‹„„””‹{||””‹‹‹‹„Š„{ttƒ||{||››”ddc{{ƒ‹‹„ƒ||lek”“›Œ”•”“›tlld\\lld‹’Šœ¤¦ƒ}ƒ“Œ”‹„‹sredc\Œ”•“Œ”„Š„u{{{||sleSKJ‹„‹ƒƒ|tlltllzll‹„„r]g“Œ”mtt„„Š“““¤¤Œ”•{||ƒ„„tslƒ}Šœ¤¦|‚z{{tuztd\\ƒ||”››ddc‹’Š–¢‹ƒƒ|ztllritts‹‹‹ztlƒ„„|‚zƒƒ|ƒ||{u{‚ut’ŒŒ‹„„„Š„{{ƒ‹’Šlld‹„‹{{tƒ}ƒ““““Œ”Š}|lek“Œ””“›ultƒ}ƒ™š¤“Œ”tt{tts”š””››œ››{{ƒUTSlksttslriœ››‹‹‹“Œ”tts{u{ƒ||›¢›ƒ}ƒ‹„‹„„Š‚|uek]™š¤‚|u²««{||”“›tsl“““Œ”•{{t””‹ƒ||{||tts|‚z‘Œ…“““ƒ„„š””{{t£œ¥‹‹„”“›\UZ£››ddcztl‹’Šdc\VTLVTLek]tllŒ”•ª³·{ttyfltt{\[[ƒ}Š[TTtt{leku{{VTL]cduzt…‹‹„„Š„„Šu{{lksd\\|‚z››”f]c¦§¨lri{u{j]\edkttsllk]bZllkƒ„„{{ƒ\[[SKJek]tll‰|v””‹VZT“Œ”[TT{||dc\ldd[[T‚v‚lksf]cƒ}ƒttsf]cJHF]cd{{ƒlek“Œ”‹‹„tt{Œ”•fkkƒ}ƒ‚v{|‚zsle\[b‰‘~lrisre]bZ[[TFD;ƒ||“Œ”:97:97rfkkd\‹‹„{tt£œ¥””‹‹’Š›¢›{{t£››ƒƒ|””‹›¢›‹„„²¬µ‹’Š™š¤£œ¥š””‹‹„¤¤”“›²¬µ“““œ››™š¤””‹”š”››”|„…µ¶·‹’Š¦§¨¦§¨œ¤¦›”›œ››ƒ„„š””‹‹‹‹„‹¦§¨|‚zultƒ}ƒ‹‹‹”š”¤¤¦§¨{{ƒlektts{{tllkŒ”•{u{‹‹‹‹‹„…‹‹¤¤™š¤‹‹‹{{ƒ”“›‹„‹{ttb[UbVZtslƒƒ|ult£››ztf”››‚v{œ››{u{llkztl„Š„ƒ„„UTS‹‹„{{ƒsre™š¤ƒƒ|mtt‹„„ƒ||”š”…‹‹mttŠƒ}‹„„‹„„ek]Šƒ}{{ƒ’ŒŒ\[[lrisle{u{ƒ}ƒrfkš””ƒ}ƒ‹’Š£œ¥‹‹„lri‹„‹ƒƒ||„…|„…™š¤””‹““““Œ”ƒ}Š™š¤‹‹‹“““tslultmtt…‹‹„Š„ƒ||…‹‹llk‚|uƒ}ƒ{u{‹„‹Š}ƒ”“›ttsllkŠƒ}¦§¨{||š””dc\{||ult|‚z{{ttslultš””ƒ||£›››¢›uzt‹‹„›¢›Œ”•„„Š£œ¥¬¶Ã“Œ”£œ¥›”›‹’Š²¬µƒƒ|{||{||‹‹„Œ‹“‘Œ…lld‹’Š‰ƒvŠƒ}‹‹‹ŠŠ}Œ”•ƒ„„ultbVUf]clddƒ}ƒedk[[Tlriult›”›”››™š¤‹„„ultlri”“›ek]{{tdkVmttƒ}Šztlult’ŒŒ„„Štt{llkUMRLKRƒ}ƒ“Œ”{tttts{{ƒ\[[ttsttsŠ}|kk]llk|„…ƒ||£œ¥uztlek™š¤Š}ƒ{{ƒf]cJHF‹‹‹{||VTLlriƒ}ƒ|„…Œ”•mttllk\[b{u{ultllkttssre{{trg]|‚zuztMRK\[[dc\¦§¨:97*)(dc\ztl’ŒŒ‹‹„„Š}””‹‹‹„ƒ||››”¤¤{u{ƒ‚uŠ}|’ŒŒ¨©´œ¤¦{||¦§¨”››‹’Š«²«µ¶·œ¤¦œ¤¦”“›“Œ”œ››„„Š¦§¨„„Šƒ}ƒ™š¤“““”››‹‹‹‹’Š‹‹‹ƒ‚u‹’Š¦§¨£œ¥²¬µ”››uzt‹‹‹²««{{tœ¤¦‹’ŠŒ”•{{ƒ{u{SKJ[TT|‚z“Œ”kd\‹‹„„Š„‹„„u{{‘Œ…UTSƒ||j]\{zmlddƒ}ƒrfk{{ƒtll’ŒŒ{tt‹„‹{tt“Œ””››™š¤£››{||„Š„JHFtsl‚v{{{tu{{”››„Š„uzt‹„„ttsŒ”•|‚z””‹lldd\\“““¤¤‹‹‹‚v{|‚z„Š}‚|ullkf]cultult‚|u”š”{tt|‚z{||Œ”•œ¤¦”››Œ”•”“›„vŒ|„…yl„“““Œ”•’ŒŒ””‹ult{u{|„…{u{{||ztl‹…’‹‹„ult[TT{tt’ŒŒ‹„‹{{ƒ‹„‹[TT‹‹‹‹„‹‹‹‹tlltsl{u{tlltslred‘ˆ}’ŒŒ›”››”›{||Œ‹“¦§¨”š”ttsœ¤¦¨©´…‹‹‹‹‹“““›”›“Œ”{tt‹„„|„…uzt{u{ƒ||¨©´››”‹’Š‹…’ƒƒ|‹‹‹|‚z“““‹‹‹“““ƒ„„“Œ”Œ‹“{tt{{ƒ[TT]bZb[UlriŒ‹“uztdc\{tt{{tredult|‚z{||{{t{zm{{t{{t“““‹’ŠVTLŒ”•‹…š\UZtts‹„‹d\\ƒ„„œ››ƒ}ƒddcƒ||\UZek]SKJ{{ttt{UMRŒ‹“{{t‹„‹‹„‹„„Šd\\VZTUMRlri{ttddc…‹‹ƒ||„Š}‹…’d\\tsltts[TT|„…„Š„Š}|u{{z‚llriŠƒ}ddcUTS[TTlektslFD;,55‹‹‹››”Šƒ}yleŠƒ}‹‹„’ŒŒ‚ut””‹ƒ||‹‹„Š}ƒ{{ƒƒƒ|ƒ}ƒ‹‹„„„Š…‹‹›¢›¤¤¤¤‹’ŠŠ~‹¤¤‹…’‘Œ…˜Ž£ƒƒ|‹„‹sre›”›|‚zœ››ƒ„„‚|ulri|„…‹‹„“Œ”tll‹„‹™š¤…‹’u{{|‚z‹„‹‹‹‹…‹’ŠŠ}ult‰|v{||dc\£œ¥fkkleklks’ŒŒ†~‘£››ƒƒ|œ››Œ”•{||””‹j]\tllŠ~‹{u{‚ut‚ut“Œ”tts{u{ƒ}ƒ„„Š{||”“›‹‹„uztuztllklld\UZ„Š„Œ”•VTL{{ƒ|‚z|„…›¢›œ¤¦lrikk]‹„„‹„„{{t™š¤ƒ}ƒtllrr]””‹{{ttt{lddf]c’…‹‚v{‹‹‹¦§¨lri™š¤‹‹‹”››¦§¨Œ”•Œ‹“Œ‹“¦§¨£²ƒƒ|”“›Š~‹”››{{ƒ…„’|„…]bZŠ}ƒŠ~‹“““fkkŠ}|llkb[U‘…„{u{£œ¥ƒ||d\\‹’Šƒ||’…‹tzldc\cbV{{ƒdc\””‹‘Œ…j]\ddc‹…’Š}ƒœ››Œ”•œ§²|‚z”“›u{{tslŠŠ}¦§¨‹„‹{||…‹‹™š¤‹’ŠleklekŠƒ}‹„„zll|‚z‹„‹‰ƒv²²¬…‹’sle…‹‹“Œ”ƒ}ƒ‚v{VZ[ultultbVZ‘…„ƒ}Šƒƒ|tll…‹‹SKJVZ[uztUUYUTS|„…‹‹„ddctslllkŒ‹“™š¤‹„‹‹’Š¦§¨‹‹„{{ƒƒ}ŠŒ‹“{tt‹„‹lekŒ‹““Œ”u{{lri{{ƒ{{tztltll[TT™š¤{{ƒ{tt‚utƒ}ƒ‹„‹ddcUUYllkœ››lri‹„„tt{ztl‹„‹VTLƒƒ|{{tldd“Œ”tslmtt‹‹„ƒ„„lriztl‹’ŠtslUTSJHF’…‹:97*)(Œ‹“„Š}“““{||””‹Šut„Š}tll¦§¨{{t‹‹„››””š”””‹“““œ¤¦¦§¨ztlµ¶·‹‹„µ¶·””‹Œ‹“”š”ult“““’ŒŒuzt™š¤‹‹‹£œ¥ƒ„„{{t‹‹‹›¢›|„…‹‹‹{||‚|uƒƒ|ƒ}ƒ|‚zŒ”•lksƒ„„{tt‹‹‹…‹‹Œ‹“…‹’ƒƒ|tslœ¤¦{ttŒ”•›”›¦§¨“Œ”‹„„ƒƒ|ƒƒ|‹’Š‚v{””‹ddc‚utJHFƒ}ƒtts„„ŠŠƒ}bVU{u{{{t{u{‹„‹{{ƒ…„’slerfk{{ƒ|„…{{tult\[[]cd[[TmttlriVTLlri|„…œ››ztlƒ||lld””‹ƒƒ|{ttd\\{{ƒ””‹Šƒ}{{ƒtllŠ~‹’…‹“Œ”™š¤ƒ||›”›„Š}‹‹‹’ŒŒ£œ¥ƒ„„‹‹„™š¤ƒ}ƒ…‹’‹„„œ¤¦lri{tt{||ƒ„„llkzll|„…sle‹’Šllk{u{‹„„sletll‚|uƒ||Šƒ}lkstzl“Œ”ƒ||”“›„Š„ƒ‚uŒ‹“lld’ŒŒ””‹‰|v“~ˆ‹„‹™š¤™š¤“““ƒ„„{tt{u{\[[„Š}œ››“““{||uzt[[Trfk‹‹„d\\{u{š…ŽŒ‹“¦§¨œ››ƒ„„“““tsl|‚z‚|uƒ„„ult{u{UUY\[[ldd{{t{u{‚utult{{tƒ}ƒ…‹‹Œ”•ult‹’Šj]\lek„„Štt{ztllriddcŒ”•‹„„{ttb[ULKRVZ[lks…‹šf]cttslddult‹’Šƒ||{u{ult‚ut{{tbVU{||VZT\[[Œ‹“{{t’ŒŒtll¦§¨‹‹„VZ[mtt{ttmtt{{tf]cSKJ{u{ƒƒ|„„Š\UZztldc\SKJ‚v{tsl{{tuztuzt|„…\[[VZTUTS¤¤:97*)(ƒ||kd\›¢›{{t››”¤¤‹‹‹›”›ztl‘Œ…¤¤™‹†ƒ||sretts£››‹‹‹¦§¨”š”’ŒŒtslœ¤¦ª³·µ¶·¦§¨™š¤‹‹‹”š”‹„‹”“›”“›””‹¦§¨ª³·¦§¨¦§¨tt{Šƒ}|‚z”“›{u{£œ¥UTSztl|‚z{||…‹‹ƒ„„‹’Šttsƒ„„{||œ¤¦ekd‹„„“““™š¤bVZekdƒ‚u›”›‚|uVTL\UZ{||“Œ”f]cŒŒšult{u{‹‹„“Œ”Š}ƒ|„…lek‚v{{u{›”›leklksf]clldUMR{{ƒcbV…‹‹””‹‹„‹ddcSKJuztddc‚|u‹‹„“Œ”sleœ››{u{››”Š}ƒƒ„„„Š„kd\ult‹„‹Œ”•Š}ƒ”“››¢›™š¤“Œ”¦§¨¦§¨œ¤¦„„Š«²«£››™š¤‹„„ƒ„„“““ƒ}ƒ‹’Š‹„‹“Œ”£œ¥Œ”•{{t{{ƒ‹„‹¨©´{ttdc\‹‹„…„’zllztl‚utƒƒ||‚z››”‹„‹‚v{{tt„Š„tslŒ‹“ƒƒ|‘…„kd\ƒ}ƒ’ŒŒj]\Š~‹£››‹’Š‘Œ…œ››”“›…‹‹œ¤¦‹’Š”“›{{ƒ{tttts[TT”š”mttu{{kk]lekƒ‚u””‹ƒ„„–¢‹‘…„…‹‹{ttuztlekedklrimttd\\\[[ƒ||{{ƒult‚wl{u{Œ”•Œ”•‹’ŠUTSedkd\\ƒƒ|UUYtllf]ctts‹„‹ŠŠ}|‚zƒ||UTS\[[llkœ¤¦UMRrededk{{ƒ‹‹„ƒƒ|lek|„…sreƒ||‚utddclrimtttt{{u{ƒƒ|””‹lri\[b\[b[[Tlri{||lldf]c‹…’™š¤¨©´mtt›”›tll„Š„lekdc\ƒ‚u‹‹‹ƒ‚uttsmtt‚v{[[Tekd£œ¥:97*)(ztlƒ‚u›¢›tsl››”‹’Š‹‹‹”››„Š}£›››¢›””‹”“›ƒ||¸Á¹¨©´£››{tt£››ƒƒ|‹‹„„„Š“““™š¤““““Œ”Œ”•¨©´Œ‹“”“›ƒƒ|{{ƒ›¢›ŠŠ}tsl”››ƒ}ƒ‹‹‹‹„„“Œ”{tt|‚zUTS]cdlritllŒŒš‹„‹|„…lkslldtsl…„’mttŒ”•Œ‹“”“›Œ”•ƒƒ|‚|uult””‹‚wltslrfkƒ}ƒj]\\[[uztleksresre{||{u{‹‹‹£››’…‹“““ƒ||‹‹‹“Œ”{||d\\ƒ}ƒ{tttt{|‚z‚|ulks”“›”››“““››”Šƒ}››”²¬µ›¢››”›‚|u‹…’lld„Š„Šƒ}ª³·¨©´“Œ”š””‹„‹|‚z™š¤’…‹|„…Œ‹“ƒ„„tllu{{’…‹””‹ƒ||ƒƒ|¦§¨œ››u{{”“›”“›…‹‹„„Šƒƒ|sleƒ}ƒ£œ¥{u{‹‹„Šƒ}œ››ldd””‹Œ‹“›”›œ››››”™š¤…‹‹“““¦§¨‹‹„£œ¥›¢›‚v{‚|u“Œ”‹„„‹„‹mwtll{{tŠƒ}Šƒ}ttsfkklri{{t’ŒŒ“Œ”{||‹’Š‹’Š|‚z‹„„ƒ„„tts{u{b[U{||i\V‰ƒv¤¤llkŠƒ}‹‹‹tt{‹‹‹lriSKJb[U]bZ{u{llk{tt‹„‹dc\uztfkk„Š„ddc{u{ƒ||””‹Šƒ}tzl{zmtsl{ttztllldllktt{„„Šƒ||lri{u{slef]c|„…{{t›”›MRK…„’sretzlsretslUUYUTSŠ~‹ttsldd¦§¨{||{u{\[b[TTf]ctslcbVtlltt{ƒ„„b[UUUY{{ƒkd\ultJHFleklld{ttfkkƒ}ƒUTSJHFVTL|‚zŠƒ}JHF*)(„Š}‹‹„‹’Š‚ut„Š„›”›|‚z“““¦§¨‘…„¤¤ƒ||‘ˆ}‹‹‹£››”“›””‹‹’Š››”{ttµ¶·£››Š}ƒ{||‚v{œ¤¦”“›¨©´Œ”•‹‹‹ƒ||›¢›uzt|‚zttsŒ”•|„…lri‚|u”š”‹‹‹edk]cd]cdf]ctsl{u{|‚z{{ƒtt{ult‹’Šœ¤¦‹’Š‹’ŠŒ‹“‹„„‹„„”“›››”’ŒŒƒƒ|„Š„bVUlriŒ‹“f]cJHFbVZlekƒƒ|ult‚v‚sleƒ„„zll‹„„“““‹„„tt{ƒ}Šfkk„Š„j]\ƒ}ƒ‹„‹{ttultŒ”•‹‹„{zm{||ƒƒ|‹„„ƒƒ|¦§¨ƒ„„Š}|’…‹Š~‹ƒ‚n|‚z””‹™š¤‹„„…‹‹tll’ŒŒ””‹{u{‹„„…‹‹“Œ”‹‹„Œ‹“{{t|‚zœ››Œ‹“ddctll„Š„¨©´“Œ”Œ”•œ››’…‹”š”ztl{{ƒ|‚z’ŒŒ‹’Š‹‹„ƒƒ|Š}ƒ‹…’Œ”•Š}ƒŒ‹“Šƒ}¤¤’…‹’ŒŒ‹„‹Šƒ}{||‹„‹ƒƒ|ƒ||ƒƒ|ƒ||Š~‹ult…‹‹‹‹‹zll‹‹‹„Š„{||llkkd\lek£››Š}ƒsle‹„‹ƒ„„{tt”š”‹’Š‹„„‚|ullkllkzll””‹Š~‹[[Ttlltt{[TT\[[ddcSKJ‚utredu{{tt{‹„„|‚z‹’Š|‚zlridc\tt{‹‹‹„Š„Œ”•””‹lrif]c{u{{||{u{Œ‹“lkslektllylezlltsl„„ŠmttsleultJHF{{ƒek]lld…‹‹zlllldekdztl‹’Š‹‹‹‹‹„|‚zŒ”•]cd|„…ekd’ŒŒœ¤¦UTSultJHFVTLkd\Œ‹“‚v{sleƒƒ|tt{tll{{tttsƒ}ƒlek{{tlks]bZ¤¤F=C*)(lld|‚z‹’Š‹‹„£››“Œ”£œ¥š””µ¶·š””””‹’ŒŒ¦§¨‘…„¦§¨|„…tsl””‹””‹’ŒŒ‰ƒv£››tllŒ‹“Š~‹rfk„„Š’ŒŒ{{ƒtts{||”“›ttstllƒ||ƒ„„”š”Œ‹“‹‹„sre‹„‹mttu{{fkk|„…uzt{ttuztmttƒ}ƒ{||‹„‹|„…|‚z‹’ŠŒ‹“{||uztƒ||‘…„š””tts“Œ”ƒ}ƒtt{f]cJHFfkk{||ddc{ttš””ƒ}ƒult‹„‹¨©´‘Œ…ult“Œ”|‚zddcsleƒ„„„„Šƒ„„…‹’Š}ƒ„„ŠlrillkŒ”•”››ƒƒ|£››’…‹£››‹’Š›”›sleƒ||tllƒƒ|‹’Š“Œ”{{ƒƒ||‹„‹šŒlrilks“““¦§¨“Œ”‚|u{||…‹’ƒ„„ƒ||{u{tll‹„‹|‚ztt{”š”¨©´ƒ„„Œ‹“¦§¨š””Œ”•“Œ”œ››‚v‚””‹[[T‚|uš””™š¤‹‹‹™š¤›¢›’ŒŒ|„…ztl‚|u‚wl‹„‹‹’ŠzllsleuztŠut{u{yfdllklld‹‹‹¦§¨{||‹…’{u{cbVƒ}ƒƒ„„”››¤¤ƒ||Œ”•‹’Š‹‹‹””‹‹‹‹’ŒŒttszllb[U‹’ŠŠƒ}’ŒŒtts“Œ”rg]ult“Œ”UMRrfk[TT{||ttslldllkJHFedk{zm]bZredƒ||„Š„cbVlkslksŠ}|ultrfk…‹’ulttts|„…ultƒ„„¦§¨››”ŒŒš[TTztlVTL{{ƒƒƒ|ult[[T‹‹„{zmfkklrilekJHFdc\tsl‰‘~Œ”•lddlldlriƒƒ|{{t‹‹‹“Œ”ztlSKJƒ||mttiWUd\\lritzl„Š}ldd{||ƒ„„“Œ”tzl‹’Šfkk²««LKR*)(u{{”›››¢›£››ƒ||‹„„“Œ””“›²²¬¦§¨²««‹„„‘…„ƒƒ|‹‹„””‹›¢›””‹£››¤¤¦§¨“Œ”‚v{£››£œ¥‹„‹Œ‹“”››‹’Š‹„‹™š¤¦§¨””‹|‚z{|||‚z…‹‹ƒ}ƒ{||²««‹‹‹¨©´™š¤…‹‹››”‹‹„{||‹’Šlks„„ŠlddlrilriŒ”•„Š„{{ƒ‹„„ƒƒ|‚|uƒ||ztlŒ‹““““{||„„Š„„Š‚|uJHFƒƒ|rfk{tt“Œ”{{ƒkd\‹„‹lek’…‹š””lks”››f]cmtt‹‹‹bVUƒ„„ult[TTtts]bZdc\tsl”“›››”‹„„‚v{ztlttsekdƒ||‹„„”š”ƒ‚u‹‹„‹„‹ddc\UZsle‹„„‹‹„”š”{ttu{{‹’Štts„„Š…‹‹‘Œ…š””|‚z{tt²««|‚z{u{ƒ„„™š¤™š¤ttsœ››‹‹‹…‹‹ƒ||‹‹„™š¤‹„„\UZztl‚wlƒƒ|‹‹‹„„Š¦§¨™š¤mw””‹ƒƒ|‚|urfkœ››‘Œ…š…Ž””‹Š}|“Œ”f]cult‹‹„slešŒƒ‚u{{ƒƒ„„””‹ƒ}Š{{ƒ£››¦§¨uzt\[[ƒ„„{||››”‹…’‚utƒ}ƒŠ}ƒzllztfVTL‹‹„”››lekddcŠ}ƒ‹„„lddultkd\mtt…„’š””ekd]bZƒ||SKJuzt\UZ„Š„ƒ„„dc\kk]{||zll‹‹‹‚v{Œ‹“‹…’£œ¥|„…tts{{t{{t““““Œ”UTSdc\tt{JHF]cdddcjcVlriyflu{{›¢›Œ‹“{{ƒ[[Tmtt|‚z™š¤lri“Œ”|‚zlks{{tmttVTLredcbV“Œ”lksdc\ttsƒ„„uzt‹’Šƒ||tsl{||ddcfkk]bZ‹’Š››”JHF*)(|„…‹’Š|‚z‚|u””‹Š}|‹‹‹“““š””²²¬›¢›Œ”•Š~‹Š}ƒ“““””‹››”“Œ”š””sre›”›²««›”›“Œ”¨©´£œ¥›”›£››¨©´¦§¨Œ‹“Œ”•„Š}„„Š„„Š…‹’|‚z|„…tslƒ„„ƒ||tt{™š¤œ¤¦¨©´‹’Š|„…u{{mttlekulttsl„Š„tts{||Œ‹“Œ‹“lldslelldultŒ‹“™š¤f]c‹’Šƒ}ƒfkktt{…‹‹f]c‹„‹{{tlritll|„…ldd‹’Šult“““…‹‹ultttslldƒ}ƒ{u{{zmtllultekd›”›ƒƒ|’ŒŒŒ‹“£œ¥‘Œ…{zmƒ„„‚|uultult‹‹„‹‹„£››|„…ttsddc‘Œ…’…‹{{tedkred¦§¨{{ƒƒ„„ƒ}ƒ…‹‹ttsƒ}ƒ¦§¨œ¤¦£œ¥‹‹„“Œ”|„…llkŒ‹“{{ƒ…‹‹£››ƒ}ƒ‹„„‹„„{||ult‹‹‹‹„„“Œ”ƒ„„››”‹„‹ª³·£²š””™š¤‚|u‚|usle„Š„¤¤Šƒ}‹„„sle£œ¥yfl[TT{||‘Œ…ddc{||”››„Š„lri“Œ”¤¤””‹’ŒŒ{tttslŒ‹“‹‹„œ››“““lks“Œ”£››i\V‚|u{u{{tttll{u{‰Š¡{{ƒ‹„‹rg]tllƒ}ƒ‚v{ttsred“““tslztltslVZT\[[ekdu{{ek]ultbVZf]clekƒƒ|ldduztƒ}ƒŒ‹“rfk‹„‹¤¤‹‹‹lksu{{ult|‚z|„…›¢›{||lld[TTf]clriƒƒ|{||]bZddcllduzt”››|„…lld‹’Šuztƒ}ƒbVUtlltlltll‹‹‹ƒ‚u‰ƒv|‚zfkktzltslllkllklek\[b|‚zVTLsle¤¤\[b:97]bZrr]œ››””‹œ››‚ut£œ¥²««¦§¨²²¬¦§¨¦§¨«²«¦§¨‹’Šµ¶·“Œ”œ››«²«‘Œ…²¬µ¨©´„„Šƒ}Š“Œ”Œ”•‹„„œ¤¦Œ”•œ¤¦£œ¥“““ztlƒƒ|\[[{tt|„…kd\lld{{t’…‹ultu{{tt{ultu{{lksmttedk{{ƒƒ||{||„„Štll|‚zf]cƒ„„ƒ||kd\”š”tlllldlldƒ}ƒ“““llkƒ||{{ƒ|‚zultedkekd{u{ƒ||JHFtll”››„Š„UTSmttultuzt\UZŒ‹“Š}ƒ|‚zd\\ultŒ”•]bZ”š”d\\””‹tts{zm’ŒŒtts¤¤š””š””ƒƒ|””‹ƒ||[TT…‹‹ƒƒ|””‹’…‹ƒƒ|ƒ„„lldƒ|||‚z|‚z{{ƒ|‚zƒ||“““œ¤¦“Œ”™š¤“Œ”u{{dc\{u{‹„‹llkƒ}ƒƒ}ƒ™š¤ƒƒ|›”›¦§¨šŒƒ||‚v{›”›ƒ||ƒ||ƒ||lksƒ}ƒ””‹{tt‹„„’ŒŒ”š”‹’Š‘Œ…šŒ‚|uult‹‹‹ultleklek„„ŠŠƒ}””‹‹‹„‹‹„¦§¨Œ”•’ŒŒƒ||‚ut‹‹‹‚ut””‹fkk‹‹„ddcŠŠ}‚wlj]\{yfj]\f]c‚|uekdllk‚v{ultd\\i\V[TT‚v{‚v{tts‚ut™š¤ek]lddƒ||\[[ult{{ttllfkk|„…f]c‹„„‹„„”š”™š¤„Š„””‹uztldd{u{uztŠ}ƒŒ”•u{{””‹|„…UTS…‹‹„Š„‹„„ƒ„„ult{{t”š”„„Š]cd“““VZ[„Š}›¢›uztJHFMRK{{t|‚zSKJ\UZlld„„Šƒ}Š{{ƒllduztƒ„„„Š„llk“““tllƒƒ|JHFJHFVTLllk¦§¨\[[&&ek]{||Œ”•¤¤Š}|™š¤¦§¨²««£œ¥‹‹‹£››‹‹‹¦§¨›¢›¤¤””‹“““””‹‹’Šƒ||¦§¨¨©´›”›‹„‹¨©´{{ƒ››”“““’ŒŒ‹’Š™š¤“““”š”Œ”•ldd„Š„ƒ„„|„…|‚zŠŠ}{||ƒ}ƒ|„…lriultlksmtt„Š„lriUMR{{ƒsle{{ƒŒ”•lriultŠ}ƒ››”bVZtslfkkƒ}ƒ‹‹‹{u{ddc{tt]cdUTS|„…mw’ŒŒ{||d\\ƒƒ|dc\“Œ”llk£œ¥{||lriƒ||{ttu{{ultlddŠŠ}{ttUTS…‹‹VTL…‹‹rfk„Š„{u{sle››”lritll››”ztllld”š”š””{||ƒ}ƒddc”››{ttƒƒ|tts‰v|b[U„„ŠŒ”•uzt‹‹„|„……‹‹”“›’ŒŒ“Œ”„„Š…‹‹…‹’“Œ”{||…„’œ››‹‹‹“““sle’ŒŒ{{tttsult¨©´™š¤tsl’ŒŒtllultred‚|ulddVTLcbVœ›››¢›Šƒ}ƒ||’…‹’…‹Œ”•ldd‹„‹ƒ||Š}ƒ‚v‚‹‹„Š}|ƒƒ|””‹‹‹„¦§¨¤¤››”ttsttsœ››ddctsl‹‹‹‘Œ…lek‹‹„””‹SKJd\\{{t\[[dc\ƒ}Š‹„‹ult”š”…‹’{||¦§¨llkƒ||‹’Šœ¤¦‚v{‹„„{u{mttlldƒ„„f]cbVZ‹„‹f]cŠ}ƒddcttslekŠ}ƒ\UZ‚v‚›”›‚|uultredUUY{zmmtt«²«|‚z›”›{{tultƒ||ƒ||„Š„~’“lrilriŒ”•™š¤tsltsl|‚z|‚zf]cu{{{tttllƒ„„£œ¥llklddekd|‚ztzlƒƒ|ztlƒ}ƒ\UZlek\[[VTLslemtt¤¤MRK%&‹‹‹tsl–¢‹››”lldƒ„„{tt’ŒŒ‹’Š¦§¨¦§¨“““””‹šŒ¦§¨””‹µ¶·œ››””‹¤¤œ¤¦›”›¨©´”“›„„Š¦§¨ƒ||ƒ„„Œ‹“ult‹’Š””‹¦§¨œ¤¦š””‹„„uztuzt|‚zƒƒ|›”›‹‹‹UTS|„…{{ƒ|„…[[T\[[]cdlekd\\{ttlek“Œ”lrif]cldd{{ƒŠƒ}sleƒ}ƒ’ŒŒ‹’Š‹„‹mttSKJllklldsleƒ„„{ttddc{ttj]\llk‹„„lritlluzt|„…‹‹‹lld™š¤ƒƒ|™š¤Šƒ}{ttbVU]cdVZTlld’ŒŒ‹‹„ult””‹””‹’ŒŒ£››slef]cdc\ztl‹„„ŒŒšŒ”•ƒ||œ››‹‹„”š”{||ƒ||‹’Šmtt››”…‹‹ƒ„„›”›Œ”•„Š„ƒ„„tsl”››œ¤¦mtt{{ƒtlltt{ƒƒ|tll{{ƒsleztl„„Š¤¤{u{ƒ||›”›‚|ukk]‚v{dc\™š¤¦§¨‰v|f]cŒ‹“™š¤ŠŠ}‰|v””‹”“›’ŒŒŒ”•ƒ}ƒf]c‹…’“Œ”Š}ƒƒ||‚|u„„Š‹‹‹¦§¨kd\ƒ||kd\””‹ƒ}ƒ\[[ztlsre“““{tt{{t{||sre[[Tlddkk]””‹{||bVZ{{t{{tzll”š”f]c’ŒŒlek‹„„¦§¨¦§¨“““{tttsltt{ztl‹‹‹‹„„lek“Œ”ultŠ}ƒ{{tf]c’…‹‚|uddc›”›{{ƒj]\{u{f]c\[b™š¤Œ—£…‹‹|‚zlekƒƒ|mttlek„Š„ƒ„„œ¤¦]cdtts|‚zƒ}ƒ[[T{tt„Š„lddlld„Š„lldƒ}ƒ‹‹„ekd\[[dc\lri”››‹‹„ƒ„„u{{{u{ƒ}ƒllkmttf]clddddc››”MRK*)(VZTmttztl””‹™š¤™š¤””‹’ŒŒ””‹‚|uŠ}|‹’Š””‹””‹‹‹„¦§¨š””¦§¨›¢›Šƒ}‹…’¨©´›”›„„Š“““›¢›“““™š¤{{t‹’Š”››¦§¨¦§¨œ››£œ¥›¢›“““‹’Š|‚z“““ƒ„„lek‹’Š…‹‹llkƒ„„tsl|‚z…‹‹ƒ}Š[TTd\\{{ƒ{u{ƒ„„ƒ}Šf]cttstsl‹„„Œ‹“’ŒŒ‹‹„{tttslmttJHFlld‹„‹ƒ„„[[T{{ƒllkj]\VTLƒ||“Œ”“Œ”ldd|‚z{ttllkult¤¤’…‹|‚z‹„„{||ƒ„„MRKƒ‚utll””‹‹„„››”‰|vƒƒ|j]\‹„„ƒ}ƒlldsle‘Œ…ultttsƒ}ƒ””‹ƒƒ|œ¤¦”š”Šƒ}|‚zš””ƒ„„›”›‹‹‹ƒ„„Œ‹“…‹‹‹‹„ƒ}ƒƒ}ƒtt{“Œ”™š¤|‚z‹„‹‹‹„œ››ƒ}ƒ{ttƒ}ƒ‚ut‹‹‹rfkb[Utll“Œ”[[TlksbVZ“Œ”Š}|{tt‘Œ…”š”rg]””‹Šƒ}¤¤›¢›ŠŠ}ult‹„‹tt{tts‹„‹‹„‹‘ˆ}ŠŠ}£››‘…„lksrfkƒƒ|j]\{{tllkllk‹‹„‹‹‹ƒ}ƒ‚ut{u{lri„Š„Šƒ}ddckk]ƒƒ|{u{ttstll|„…lek‹‹‹b[U{tttts{zmuzt“Œ”‹„‹{tt“““uztztl”››lddƒ}Š{{ƒƒ}ƒ£œ¥¦§¨ƒ}ƒƒƒ|tsl[[Tƒ||ƒ}ƒtll“Œ”‹’Šyl„\UZ|„…œ§²„„Šƒ}ƒ[TT„„ŠVZTtlllri|„……„’‹’Štllztlrfkultd\\ult|‚zŒ”•ƒ‚u{tt{{t{{tlldŒ‹“{||]bZtzl‹‹‹‹’Š””‹{{ƒlekmttlldztl‹‹‹¦§¨dc\>EC‹’Š„Š„››”“““’ŒŒ“Œ”ttsœ››“““¤¤“““{u{Š}|‘Œ…£›››”›š””ƒ„„›¢›››”™š¤¦§¨“Œ”¦§¨Œ‹“ƒƒ|¦§¨¦§¨‹‹‹|‚z“Œ”{{ƒ|‚z‹’Š””‹‹„‹”››‹’Šuzt“Œ”ƒ}ƒSKJ|„…]bZVTLkd\lld]cd\[blek{u{{tt{{ƒ‹‹‹ekdlldult‘…„‘Œ…””‹{||Œ‹“›”›{tt{{t{ttSKJlld|„…™š¤‹‹„‹„‹„Š„£››lri‹„‹uzt|„…‹‹„‹‹‹{ttƒ||u{{u{{{{ƒ|„…“Œ”ulttt{lri›¢›‹„„››”‹‹‹²««‘Œ…”“›ƒƒ|zllttstts„Š„œ¤¦tt{…‹‹kk]‹‹‹¤¤£œ¥‹’Š‚utŒ”•Š}ƒ„Š„”››Œ”•”“›{u{…‹‹tllttsƒ}ƒ…‹‹™š¤™š¤„Š„tts„Š}œ¤¦‚v{‚|u…‹‹mtt“Œ”ldd[[Tlldsleztlult¨©´“Œ”’ŒŒ£œ¥llkƒƒ|lddš””ztlŒ‹“{{tœ››““““““mtt{tt{u{›”›‹‹„zll‚utš””„Š}››”{{tƒ||››”‘ˆ}ƒ||tsl››”{||‹‹‹sle‹‹‹“““[[T‹„„lldlriŒ”•{{ƒ‹‹‹{{ƒtt{{u{lks‹„„uzt{||sled\\SKJƒ„„[[Tuzt””‹{||ƒƒ|ƒ}ƒš”””“›{u{ƒ„„‹„„‹‹„‹’Š|„…’ŒŒ“Œ”tsl‹„‹|‚z{||ƒ|||„…lks]bZmttslemttedktsl¦§¨mttldd{{t”“›{||ultttsj]\„„Šllk‹‹‹lld{ttƒ}Šlek{{ƒŒ‹“tts‹‹„tll[[TmttŠ}ƒlek„Š„{||{{tlldlld²¬µ]cd-1+tsl‹„„››”ƒƒ|{||··Ä¤¤£››‹‹‹”š”¦§¨ult²¬µ£œ¥ƒƒ|¤¤¦§¨¤¤ƒƒ|Œ”•š””Œ‹“¨©´’ŒŒª³·œ››µ¶·œ››š””¤¤”“›››””š”|‚z…‹’ƒ}ƒƒ}ƒ‹‹„œ¤¦ƒƒ|‹„„lddu{{uztllkŒ‹“”››tt{Œ—£‹‹‹lek{u{…‹š‹„‹‹‹‹ƒƒ|ztl››”ƒ‚u‹‹„{||{||ƒ}ƒ„Š}Šƒ}kd\‹„‹lld‹‹‹…‹‹„Š„{||u{{£››…‹’zll¦§¨lkstzlmtt‘…„‹„„š””tts“Œ”{||ldd{||…‹‹mtt|‚zƒƒ|œ››”“›ŠŠ}ŠŠ}ddcœ››‹‹„’…‹{zm|‚z“““{ttlriddcŠƒ}‹‹„Œ”•™š¤Šƒ}‹’Š›”›‹‹‹ƒ„„tt{{{ƒŒ‹“„„Š“Œ”{{ƒ¦§¨{{ƒ’ŒŒ‹„‹”š”tllttsfkktsl‹‹„…‹‹{||“““{ttƒ„„{u{d\\SKJu{{rfk‚v{™š¤Œ‹“‹‹„””‹zll{{tƒƒ|ƒƒ|{{tƒ‚u{||Œ‹“tts‹„„‹…’kd\tsl‹‹‹¦§¨ƒ||lek‚utƒƒ|ƒ„„‹‹‹””‹u{{ƒ„„ztl”š”””‹’ŒŒ‹’Š‹‹„sre{||]bZtsl{||tlluztuztsle{ttedkzll|‚ztsltllj]\zllslelld‹‹„Œ”•ƒƒ|’ŒŒ{ttƒ||tsldc\tsltt{lrikd\slered{u{lddddc‚|u\[bllk…‹‹mtt¦§¨SKJtsl„„Š…‹’lrib[Uedk{{ƒœ››ƒ„„ultedkƒ}ƒ|‚ztll”š”Šƒ}‹‹‹zll\UZllktt{ttslksmtttt{[[T„„Šultlri{{t„„Šlrisle\[b¦§¨LKR%&£››Œ”•£œ¥£œ¥™š¤£²£››¦§¨””‹„Š„‹‹‹ƒ}ƒ£››››”¦§¨››”¤¤{||ƒ„„‹’Šœ¤¦¤¤··Ä¦§¨¦§¨‹’Š£››…‹’ƒƒ|{{ƒ{tt„Š}{{ƒ{{tŒ”•”š”|„…Œ‹“Œ‹“‚|u››”tll…‹’|‚zVTLlddmttmtt…‹‹lks¦§¨ttsultŒ”•|‚z‹‹‹\[[¦§¨ztl‹‹‹d\\””‹tll‹‹„’ŒŒlld™š¤“““™š¤{{ƒtsl{{ƒsleŒ”•œ››™š¤“Œ”‹…’|„…lldƒ||{tt„„ŠUTSlek„Š„{zm{{ƒLKRekd„Š„‚|ukk]‹‹‹¤¤””‹Œ”•|‚zœ››{ttttsƒ‚u’ŒŒ‹„‹uztƒ}ƒƒ||””‹{{t{||‚|uƒƒ|šŒfkk””‹ƒ„„tts{||„„Š{||Œ‹“„Š„|‚z£››{||ttsu{{Œ”•lddlddd\\‘Œ…ttsŠ~‹™š¤[[T„Š„tsl‹„‹ƒ||’ŒŒŠ}ƒƒ}Š‹’ŠŠƒ}‚|u’ŒŒ{{t\[[¦§¨j]\lriSKJ£œ¥„„Š“““Šƒ}ƒ„„ƒ||Š}||‚ztzlƒ„„Šƒ}’ŒŒ‹‹„{ttŠƒ}lddƒƒ|{{tƒ„„”››tll{||¤¤lddrg]{u{”››lrilri\[[|„…„„Š‹„‹mtt{{t|‚z{{tVTLbVZztl“Œ”{{ttsldc\]bZllk‹„‹ƒƒ|ttsldd‹‹„™š¤{u{ƒƒ|tt{‹u…‹…’‚|u„„Š{||Œ”•[[TŒ”•œ§²{{ƒ\[b¦§¨Œ”•tt{‹’Šb[Umtt{{ƒ{ttrfk’…‹{u{UTSlritlltts”››ƒ}ƒult‹‹„{||ddclri‹„‹{||…‹’tsl|„…b[Utts‹„‹llk‹„‹[TT\[[¦§¨ek]FD;Œ”•””‹¦§¨œ¤¦ƒ}ƒ¨©´‹„„¦§¨µ¶·¦§¨¤¤’‘~£œ¥¦§¨¦§¨²²¬‹’Š“““ª³·œ¤¦™š¤‘…„œ¤¦Œ”•|„…‹‹„š””„Š„™š¤¨©´‹„‹”“›¦§¨““““Œ”››”{{t”“›‹„„ƒ||{tt’ŒŒ|„…lri{u{llklri“““\[[{{ƒ{||{u{dc\›”›‹’Š“Œ”””‹£››{tttslƒ„„zllƒ||{tt£œ¥Šƒ}ƒ}ƒ‹‹‹Œ”•‹„‹ƒ||‘…„sre‚utƒ„„›”›{||ddcƒ}Š…‹‹tts“Œ”›”›‹’Š„„Šƒ„„’ŒŒ‹„„Œ”•lrikk]š””llkllkš””‹„„lld{{t‘…„UMRttstslŒ”•ultŒ”•››”››”››”uzt„„Š¤¤„Š}”š”{ttƒ„„ult‹‹‹”“›‹‹„lekekdlriddcu{{ƒ}ƒlldtt{uzttts{{t|„…ƒ}ƒldd‹„„ult›¢›Š~‹|‚zŠ}ƒSKJ{u{‚v{sre‹„„ƒƒ|ztlŠƒ}””‹ƒƒ|ƒƒ|ƒ||mttllk„„Š„Š}{tt‚v{ƒ„„Šƒ}ldd‹…’\[[’ŒŒ’ŒŒ¨©´””‹”š”‹‹„lldjcV‘ˆ}]bZkk]bVZ{ttƒ„„„Š}ƒ‚u{zm‹’ŠVTL‹‹„\[[|„…\[[f]clddekdƒƒ|sle{tt’ŒŒ‚utf]cVTLƒƒ|UTS“““œ¤¦‹‹‹’ŒŒ]bZztluztlri””‹dc\Œ”•’ŒŒƒ}ƒrfk\UZ“““|‚z„„ŠŒ”•|„…u{{{{ƒttsƒ}ƒ¦§¨¦§¨‹‹„u{{„Š„“Œ”Œ‹“¦§¨tt{u{{|‚zŠ}|lri”“›lddf]cVZT”“›{||UTS“Œ”ttsVTLtslŠ~‹‹„‹dc\ultu{{ultŒ‹“llk¨©´UTS)+2››”ƒ||ƒ„„ƒ„„š””¨©´¦§¨«²«›¢›™‹†››”‹„‹’ŒŒ””‹“““‹‹„™š¤››”ƒƒ|”›››”›”š”œ›››¢›“““™š¤”“›¦§¨Œ”•¨©´”››Œ‹““““”››””‹z‚l¦§¨œ››…„’{{tƒƒ|ƒƒ||‚z{{ƒ“““ƒ„„ddc{||lksƒ}Š‹…’ƒ„„“Œ”‹’Šuzt{{t„Š}œ››“Œ”‹„„{u{{u{‚utlddf]ctllztlƒ‚uVTLultƒƒ|d\\Œ‹“ultVTLƒ}ƒ{{ƒllkllk{tt‘…„£œ¥Œ”•‹‹„{u{u{{Œ”•‹‹‹‹‹‹‹‹„„Š„ztlŒ”•tts¦§¨š””“““‹’Škd\‹„‹JHFlriƒƒ|tll‹’Š¦§¨›”›””‹¤¤Œ”•ƒƒ|ƒ||¦§¨œ››lldƒƒ|tll‹’Šsle“““Œ‹“|„…“““…‹’‹„‹ztl\[[””‹ƒ}Šš””{||Œ‹“‹‹„tt{ƒƒ|”š”‹…’|„…zll{{tŒ‹“ƒ}ƒllkƒ„„‹„‹ƒ„„dc\‹‹„yleƒ‚u’ŒŒ‹„‹tllttsƒ}ƒ{tt„Š}uzt¤¤Šƒ}{tt{u{“Œ”ttsdc\{||””‹{{tllk‹‹„ztlztflddœ››lrillkddc‹’Šek]|‚zdc\|‚zdc\lddUTSf]clekred…‹‹¤¤[[T{{ƒ“Œ”‚|u{{t„Š}”››„Š„edkŠ}|’ŒŒ„Š„Œ‹“››”œ¤¦‹…šsre”››tt{{u{‹’Šlrimttuztddcekd”“›uzt””‹]bZ™š¤edk|‚ziq]lks{||sletll‚utultµ¶·{||uztu{{ƒ„„dc\tts‹„‹{{ƒŒ”•dc\‹…’tts\[[|‚zddc{ttuzt‹„‹ƒ}ƒ{u{”š”tll¦§¨\[bLKR|‚z…‹‹ª³·Œ‹“’ŒŒ“Œ”››”ƒ‚u–¢‹„Š}¦§¨‰ƒv’ŒŒ‹‹„¤¤|„…¦§¨››”ƒ||‹‹‹”››’ŒŒ£››‹’Š¨©´£œ¥··Äœ¤¦‹…’¨©´¦§¨¦§¨„„Šª³·š””¤¤¤¤œ¤¦ƒ„„ƒ||š””ƒ||fkkƒ„„{{ƒ‹„‹{||””‹{{ƒ£œ¥“Œ”ƒ}ƒult{u{tslŒ‹“tt{””‹Š}ƒ››”‹„‹tslldd‘Œ…¦§¨’ŒŒdc\rg]llk{ttlldsle‚ut‘…„”››ultŠŠ}llk{||d\\“Œ”‚|u‹‹„›¢›™š¤Œ”•|„…{{ƒllkdc\]bZ‹„„ttslek‚|u‘Œ…ldd«²«Œ‹“{u{ƒ}ƒcbV”š”ƒ„„{||””‹’ŒŒ¤¤‹‹‹š””{ttƒ‚u¦§¨„Š„‹’Š¨©´{ttŒ”•‹‹‹‹„„£œ¥”“›‹‹‹{||{{ƒ‹‹‹…‹‹ƒƒ|‹‹‹|‚z{u{…‹‹ttsult{||fkk\[[Œ‹“u{{‹‹„Œ”•{u{{ttƒƒ|“Œ”{tt{zm{tt‹‹„‚|u””‹ƒƒ|ldd\UZ‹’Š“Œ”‹’Š“““sle’ŒŒd\\kd\{tt{{tlldmtt]bZekdttsƒ„„šŒƒ}ƒbVZŠ}ƒ…‹‹llklldkd\SKJddc{u{ztlllktzlb[U{u{{tt{{tu{{lriƒ||r]g¦§¨ƒ||¦§¨”š”…‹‹ƒ‚u‹‹‹›”›cbV””‹‹„‹|‚z„„Š‹’Š›¢›œ¤¦‹„„ƒ}ƒ””‹„Š„‹’Š|„…|‚zekdœ§²|‚z|‚z‹‹‹mttuztƒ||d\\UMR›¢›‹’Šƒ||lksf]c››””››{{t›¢›]bZŒ”•‚|u“Œ”uztmtt[[Tttslri|‚zdc\JHFƒ}ƒtllƒ}ƒ[TT{ttultd\\¦§¨MSSLKRœ¤¦›”›”“›£œ¥‚v{ƒ||’…‹””‹¦§¨¦§¨¤¤²¬µ“Œ”¦§¨ƒƒ|“““tzlª³·‹’Š¨©´‹’Š£œ¥Ÿ±¯¦§¨¦§¨”“›…‹‹¦§¨£œ¥””‹™š¤…‹‹ƒ„„“““‹‹‹™š¤””‹’ŒŒ…‹‹‹…’edk‘Œ…\[bŒ”•ƒ}Šµ¶·lks™š¤œ¤¦„„Š‹„‹‹…’ƒ||œ¤¦ƒ||Œ‹“llkztl’ŒŒ|‚z„Š„{{t“Œ”ƒ||’…‹lld‚|u’ŒŒtsl{||…‹‹Šƒ}‹„„sleu{{’ŒŒ‹‹„|‚z\[[ttsƒ‚u“Œ”ƒ}ƒekd‹‹‹llkœ¤¦tt{ddctzltsljcVƒ||¤¤œ››‘Œ……„’‹‹„‘…„‹‹‹{||›¢›|‚z“““‹’Š‹„„zllŠ}|ƒƒ|{tt’…‹‹’ŠŒ‹“u{{“““‹‹‹zll’ŒŒƒ„„{{tŒ‹“„Š„‹„„”“›ƒ||{tt”“›ƒƒ|tt{tsltts›¢›tllŒ‹“tt{tt{\[[“““ultllkƒ}ƒlks¤¤„Š„‹u…{{tƒƒ|››”Œ‹““Œ”ƒ}ƒtts{u{ƒ||ttsœ››””‹”“›‘Œ…ƒ||Š}|{ttsle{tt[TTkd\tsl{u{ƒ„„{{tŒ‹“kd\””‹{u{‚v{JHFŠ}|ztllri‹‹„{ttultbVUdc\{u{lekŠƒ}ttstts‚utƒƒ|ƒƒ|{{ƒ‚ut«²«›¢›„Š„{||„„Š‹„„‹‹‹ztlƒ„„|‚z£œ¥‹’Š¦§¨Œ”•sleƒ„„š””|„…tzlŒ—£…‹‹Œ”•|„…]bZ|„…]bZu{{\[buztJHF\[b{tt]bZyle\UZŒ‹“{||tllredVZTek]fkklddlekedk|„…ttsu{{]bZ]bZ|‚z‚v{ultƒ„„‹‹‹ƒƒ|ƒ||sle\[b¦§¨MRKUTS|„…cbVƒ„„£œ¥“~ˆ‹„„””‹Š}ƒ|‚zƒ‚n’ŒŒš””sle|„…{||“““¦§¨›¢›¦§¨¨©´£›››¢›«²«lld‹‹‹«²«œ¤¦”“›“““œ››Œ”•¡¡’ŒŒª³·”“›llk‹‹„lri‹’Š‚|u{||‚|u{{ƒŒ”•ult‹‹‹{{ƒƒ}Š{{ƒlkslldd\\‚utƒ}ƒƒ}ƒztl‹‹„‚ut‚v{‹‹„lek‚|ured’…‹{u{{u{{ttŠƒ}lddldddc\sle‘…„›”›‹„„ƒƒ|¦§¨|‚z\[[{||‹„„ult‹‹‹{u{\UZllkƒ„„f]cf]ctzlsreSKJƒƒ|tzl[TT‚ut‹…’sle‚|u“Œ”[[Tƒ‚u””‹”“›™š¤››”›”›¦§¨¦§¨{||‘…„tsltsltsluzttts’…‹ƒ}Šš””š””„„ŠŒ”•‚|uƒ}ƒ›”›uzt™š¤š””ƒ„„ldd‹’Š{{tlddŒ”•ƒƒ|ƒƒ|ztlƒ}ƒf]cuztultœ›››”›Œ‹“””‹‚|u|‚ztslœ¤¦ƒ„„ŠŠ}¦§¨ult“Œ”””‹”››ƒ„„”››’ŒŒ‘…„ƒ}ƒŠ}|ult{||d\\“Œ”Šƒ}ultƒƒ|{{tƒƒ|‚|u‘…„yle{||‚|usle{{t¤¤ƒƒ|ƒƒ|tsllldFD;uztllktzllld\[[lldƒ}Šdc\bVZSKJtzlztl‹’Šlriultztl“““kd\””‹¦§¨›”›ª³·{{tkk]ztlŒ”•tsl…‹‹uzt„Š„u{{mtt‚v{u{{{||lksddcllkMSSlldult‹…š„Š}{{tUMRf]clektll”š”{{tlld{||u{{„„Štll\[[dc\]cd]bZlri‹’Š‹„‹„„Š‚utultŠƒ}Š~‹UMRf]c£››JHF?;C„Š„„„Š“Œ”£››‹„‹ƒƒ|‹‹„’ŒŒŠŠ}””‹Šƒ}Œ”•¸Á¹¦§¨¦§¨›¢›”š”¦§¨œ¤¦œ¤¦¦§¨‹„„œ¤¦‹’Š‹uŠƒ„„…‹‹“““¨©´¦§¨Œ”•…‹’Œ‹““Œ”ŠŠ}’ŒŒœ››|‚ztsl‹„‹£œ¥‹„„uztUUY¦§¨Š}ƒlksultlksmtt…‹’ƒƒ|ƒ||œ¤¦{u{ƒ}ƒ{{tƒ||“Œ”|‚z”››“““‹„‹‹„‹‹‹‹Šƒ}ldd†~‘{u{™š¤‹‹‹“Œ”””‹cbV{{tƒ‚uƒ‚u{zm‹„„j]\‹’Šƒ||¦§¨ttstts|‚ztllf]cƒ}ƒƒƒ|lrilriƒ‚ulri„Š„{tt{||zll‚ut‹„‹““““““ƒƒ|›”›™š¤’ŒŒ‘…„¦§¨ƒ||””‹ƒ|||‚z{u{{{ƒ”š”ult‹„„’ŒŒƒ„„tll„„Š‹’Š’ŒŒ{u{’ŒŒu{{“Œ”ƒ„„tsl{{t…‹‹ƒƒ|ƒ„„tllf]cƒ„„”“›“““{{ƒƒ||{tt{{ƒzll\[[ƒ||‹„„{||ƒ‚uu{{b[Usle‘…„jV[‚|u‹‹‹ƒ„„””‹ƒ„„ztlŠƒ}œ¤¦š””tts““““Œ”Œ”•‚v{ƒ}ƒj]\‰|v‘…„””‹¤¤‘…„{tt{tt‹‹‹[TT‚|u£œ¥Š}|ylett{sreƒ||tll‹‹‹‘Œ…lddiq]{u{‹…’|„…ƒ||kd\{{ttsl„„Šf]ctll{u{b[Ulksztl|„…™š¤uzt{{t‹„‹mtt{||\[b|„…lks…‹‹UTS“Œ”{||\[[|„…lkssle\[bllk\[bUMRttsuzt\[b{{ƒlekdc\tt{ƒ‚u‹‹„\[[{{tƒƒ|[[T”š”{{t|„…{{tultlddƒ}ƒtll™š¤”“›››”lddbVZldd¦§¨\UZJHFlks|„…‹„‹£œ¥™š¤‚|uŠƒ}”š”””‹””‹””‹«²«¤¤¤¤””‹œ¤¦¦§¨‹’Š¨©´«²«µ¶·›¢›{{t””‹¨©´œ¤¦Œ”•”››Œ”•’ŒŒ‹‹‹Œ‹“™š¤¦§¨|‚zœ¤¦‚|u‹’Š„Š„yleult¦§¨]cd{{tlekultŒ‹“edklksu{{|„…”š”dc\„„Šlek”“›{||¤¤‹„‹{{tlri{ttŒ‹“’ŒŒ¨©´ultlddUTS¦§¨ƒƒ|ƒ„„ƒ||”››sleddc\[[lriƒƒ|lek[[T{tttll‚|u„Š„ƒ„„|„…uztJHFlkscbV|‚zllk””‹|‚z„Š}””‹””‹Š}|kd\ƒ„„Œ”•|‚z‹‹„tll„Š}‹„‹›”›²««“Œ”¤¤tll„Š}Œ‹“š””‹’Š{{ƒ‹‹„ƒ||{tt“““’ŒŒƒƒ|“Œ”’…‹‹„‹ddcult“““‹„„””‹‹’Š„„Štll[TT“Œ”„Š„{u{ƒ„„ƒ}ƒœ››ƒ}ƒ²²¬’ŒŒ|‚z„Š„ƒ‚n„„Š”š”{||{{t‹‹„lddmwŠ}|‹‹‹|„…“Œ”ƒ„„Šƒ}ylebVZŠ}|œ››ekdƒ}ƒ{ttkd\zll{ttš””‹„„’ŒŒ‹„„‘…„››”’ŒŒ{u{ult“Œ”‘…„[TTƒ}ƒ[TT„Š„lri{u{{ttŠƒ}mtttt{‹‹‹ultllkztlUTS£››tll…‹‹›”›‹„„“Œ”{tt{tt[[Tllkš””\[[››”‹„„ttsLKR[TTtzl\[[SKJmtt|„…mttœ¤¦ddcu{{lekœ¤¦dc\ult’ŒŒ“““‹„„lks{u{ult[[Tœ›››¢›‹’Štzl{{tƒ}ƒfkkfkkƒƒ|{||uztƒ„„uzt{tt{{tŠ}ƒult£›››”›kd\tll£››JHF*)(”››“““‹„„‘…„‹‹„”“››”›””‹|‚zz‚l£››œ››œ››“““›¢›··Ä«²«ª³·¦§¨µ¶·«²«œ››²²¬Œ”•‹’Šœ¤¦£œ¥œ¤¦‹’Š”š”œ¤¦”“›Š}|¦§¨œ¤¦œ¤¦Š}ƒŒ”•‹‹„lldƒ}Šult„„Š””‹Œ‹““Œ”{u{„„Šllk|„…›¢›‘…„“““lri{tt“Œ”””‹‹„„š””””‹“Œ”ƒ||‚ut£››œ››””‹‹„‹ddc„Š„ƒ||„„Š’ŒŒ‹„‹{u{f]c[TTlldcbVŠ}ƒUTSšŒ‹„„’ŒŒƒ‚n[[Tlrikd\{{ƒlri{{t‹‹„lri{zm{tt›¢›ƒƒ|“““zll{{t‹‹‹‹‹‹“““Šƒ}|‚zƒ||ƒ„„‘…„¦§¨’ŒŒ{{t‹…’ƒƒ|œ¤¦Šƒ}””‹”“›‹„„‹„„fkk‚ut“““tslult‹‹‹œ››u{{ƒ}ƒ”š”‹’Šƒ}ƒddcŒ‹“tt{ƒ||lddlddƒ„„{{ƒd\\ult‹‹„‚v{{tt››”lri‚ut|‚z„Š}uztztlzllƒ||tllttsš””¦§¨‹’Šuzt‚|u›”››”›lddztl„„Šttsƒ||lek‚|uttsek]ƒ||Šƒ}“Œ”‘ˆ}£››š””ŠŠ}“““lekƒ||ztlsle‚wl‹„„dc\uztztl{ttuzt„Š„‹’Š„„Š“““‹‹„|‚z¤¤Œ‹“ƒ„„llkldd„„Š“““‹‹„œ››u{{ƒƒ|{{t]bZ{u{SKJUMRmttSKJ]cd]bZ|‚zŒ”•mtt‹’ŠŒ”•lri„„ŠMRKƒ}ƒf]clldJHFdc\UTSd\\mtt|„…tll‹„„‹‹„lriekdlriƒƒ|\[[tlltt{dc\lridc\{u{{{ƒlddlektllƒ}ƒd\\ldd¦§¨JHF$›¢›ƒƒ|”“›’ŒŒ”š”£œ¥™š¤‘Œ…””‹¦§¨””‹¦§¨¦§¨š””¦§¨œ¤¦ª³·¨©´¦§¨µ¶·‹’Šœ››£››‹’ŠŒ”•”››Œ‹“”››œ››lek‹’Š™š¤‹‹‹¦§¨ª³·…‹‹’ŒŒ„Š„tsl{{t£œ¥‹…’\UZUTSƒƒ|{ttlri|„…lri|„…z‚l’ŒŒ””‹„Š„„„Š‹‹‹tll“Œ”‹„„›”›‚utŒ‹“‰ƒv£››Œ”•””‹ƒ„„{||tts‹„‹sle¦§¨ƒ„„bVU‹’Šldd|‚zdc\ƒƒ|j]\dc\redzlluzt”š”ttsJHFlek{{ƒsretsl{||Œ”•œ››››”{zm{||Šƒ}sleultƒƒ|uztŠŠ}tts”››ƒ||ult¤¤œ››tzl{||‹’Š”š”„Š„”š””š”‹‹‹››”tt{ƒƒ|lri…‹‹‚v{{u{ƒ|||‚zmtt‹„„ult‹…’ek]š””{u{tts‹‹„“Œ”zll’ŒŒ“Œ”‚v{‹‹‹lekƒ‚utslcbV|‚zuztkd\ƒ„„„Š}zll’ŒŒ£œ¥Šƒ}tsl|‚z„Š„“““‚|u‚v{’ŒŒ‘…„red„„Š{{ƒ“““r]glrilld{u{{u{Š}|[[Tkd\‘ˆ}‚|u‹‹„|‚zj]\lddf]ckd\{u{Œ‹“Šƒ}[TT‹‹„dc\|„…‹‹‹ek][TTlld{{t{||¦§¨“““{u{ult¦§¨¦§¨›”›{||›¢›|„…mtt{{tUTSddc|‚zŒ‹“\[blri””‹‹’Šmtt™š¤uztŒŒšlriu{{leku{{lksŒ‹“mttlri{{ƒ{||{{t{{ƒ|„…zllddcttsuztllk„„Šuzt|‚zlekdc\ztl{u{ultƒ„„ƒ}ƒŠ}ƒ{tt“Œ”{||ttsult¦§¨VZT*)(”››“Œ”””‹‚|utsl’ŒŒ‚wlŠŠ}””‹¤¤µ¶·””‹£››››”£››ƒ„„””‹¦§¨£››¤¤»ÂǤ¤¤¤œ¤¦|‚z‹’Š··Äœ¤¦„„Šƒ||Œ”•œ¤¦…‹‹››””››tzl””‹œ¤¦“““|‚z“Œ”‹„‹|„…|‚z™š¤[TTVTL[TTlriu{{‚ut‚v{tllŒ”•”“›””‹’…‹ƒ||‚v{Šƒ}Š}ƒzll£››Š}ƒƒ„„lld{{tlld”“›lekyfd†~‘ƒ}ƒkd\tsl{tt’…‹””‹{{t{ttƒ||‰v|uztllklddŒ”•cbV{u{SKJlri|‚z‹‹‹tzldc\””‹‹‹„“Œ”‘Œ…‘…„{u{{zm‹’Š{tt„„Š””‹{ttŠƒ}tsltsl|‚z›”›|‚z””‹‹’Šƒ‚uŒ‹“tsl‚|uttsƒ||‹‹‹ŠŠ}ultult|„…ttsuzt{{tƒ}ƒ‚|utsl‹’Š{{ƒtlltts{{t™š¤²««‹„‹ult|‚zdc\tslƒ„„‚v{ƒ||{{t”š”œ¤¦‚|u£››“Œ”‹„„‚ut{{tuzttzl{zmŠ}|‚|u‚|u’ŒŒš””„Š„uztƒ||“Œ”‹„‹Š}ƒ|‚ztllztfb[Uekdttsj]\ƒ‚u|‚zllkŒ‹“{u{Š~‹{u{{||ƒ||[[T”š”ƒƒ|]cdUTS‚|uf]cbVU‘Œ…b[U{{tj]\Œ”•llk{||Š}ƒ‹‹‹‹‹„{tt[[T[[Td\\llk“Œ”|‚z{tt{{ƒ|„…Œ”•lksŒ”•ª³·œ¤¦{{ƒ‹’ŠMSSlriVTLbVUf]cUMR>B9ƒ||ª³·“Œ”|„…]cdtts]cd|„…ek]™š¤„Š„Šƒ}…‹‹{{t|‚z{tt’ŒŒb[U‹„‹{u{ult{tt’ŒŒr]Z‹„‹{ttœ››MRK*)(””‹²¬µ£œ¥””‹ultmw””‹Ä¿¤¤””‹›¢›£››²««””‹£œ¥¦§¨¦§¨£››£››¦§¨²²¬‚wl‹‹„””‹›¢›{||£œ¥œ¤¦‹„„¦§¨‹„‹{ttllk¦§¨“““Œ‹“ƒ‚u„Š„’ŒŒ|‚z¤¤‹‹‹…‹’FD;„Š„ultu{{u{{fkkUTS{ttzll‹„‹…‹‹ƒ}ƒ‹‹„š””d\\{u{lld‹„„Š}|ƒ||‹‹„ƒ}ƒuzt{ttkk]ƒ„„UMRrfk‚utttsSKJztlrfk””‹tsl\UZ“““‹’Š‘Œ…‚wlllkttsb[Uldd{||{||¦§¨kk]ƒ}ƒek]|„…””‹‹„„‹‹„š””ult“““‹‹‹lld”š”llk{ttƒ}ƒslesle{tttsl{u{”š”«²«¤¤”š”ƒ„„Šƒ}Š}|‚ut‹‹„“““ƒƒ|’ŒŒuztƒ„„u{{{{ƒ{{tƒ}ƒlri‹’Š“““ƒ||ttslriƒ„„”“›Œ‹“ult{tt{{tkk]{{tultttsllddc\{{t{zm{{tj]\zll‚v{‹„„{u{tllƒƒ|tzlb[U{{tŠ}|š””tllŠ}|œ¤¦ƒ}ƒult“Œ”£››Š}ƒlrilri“Œ”VTL{zm‚|u‚|u“““›¢›ultlddzll‘…„ztlf]ctts|‚z{tt{||uztlldtsl{||fkkek]tts{zmddctllš””VTLultuztbVUlriuztekdŒ”•””‹¦§¨Œ‹“f]c‹’Š…‹‹…‹’”››œ¤¦ttstt{u{{UUYJHF]bZƒ}Š{{ƒ[[Ttsl{{ƒŒ”•‹’ŠmttŒ”•‰ƒv{{tldduztttslriuztuzt{zmƒ„„llkf]ctllkd\ldd‚v{rfkztl‚v{leklek«²«JHF,55llklksƒ}ƒ””‹š””£››¤¤››”|‚z¤¤’‘~µ¶·²²¬²««š””¦§¨¤¤‚v{uzt„Š}¤¤£››¦§¨‹‹„|‚zœ››œ¤¦”“›{ttœ››ƒ||ztl‹‹„‰|v\[[lritlllld{{t{{tƒ„„Š~‹…„’tyguzttll‹‹„|‚zŠ}ƒ{||rg]‹‹‹kk]‹‹‹‹‹‹ƒ}ƒƒƒ|ult‹„‹ƒƒ|›”›‘Œ…“““œ››Œ‹“tsllekŠƒ}‚v{zll[[Tb[Uultrfkƒƒ|‚|u{u{„Š}£››”“›{{ƒŠ}|{u{…‹‹ƒ}ƒ‹‹„‹„„ƒ„„tt{jcVi\Vƒ‚uƒ||ƒƒ|›¢›¦§¨“““””‹‹‹‹{u{ƒƒ|sreztf{u{‚|u|‚z‘…„{zm|„…tsl‹‹‹‹’Š|‚z…‹‹›”›|‚z“Œ”ƒƒ|ƒ}ƒ”“›œ¤¦ƒƒ|tll{{tŒ”•Œ”•Š}ƒŒ”•Š~‹{u{‹’Š’…‹ƒ}ƒfkku{{tll’…‹ult{ttš””\[b{{tƒƒ|sleƒƒ|lektll|‚zƒ‚u{u{‚|u£››£œ¥‹‹‹ƒ}ƒ‹’Š”››{||tsltslrg]ƒƒ|sle’ŒŒ“““{{tƒƒ|“Œ”tsl’…‹››”kk]ult‹„„ƒƒ|ƒ||lld‹‹‹ƒ}ƒ‚ut{||bVUrg]kd\lek£››ƒ||tslƒ„„uzttts{u{z‚lmtt{zmztlj]\tts{{ƒ‘…„ŒŒšz‚lekdtll|„…„Š„„Š„yl„]bZ‹’Š‚|u{||‹’Š‹‹‹Œ‹“Œ‹“‹‹„¨©´fkk|„…\[b„„ŠUTSD;9lksmtt‚|u{{ƒlks”š”mtt{{ƒŠ}ƒ’ŒŒ“Œ”‹’Š‹‹‹{||tts‚uttsltt{|‚ztlllekredf]cf]cƒ}ƒ{ttŠƒ}tlltll¦§¨MRK*)(ƒ„„ƒ||¦§¨¦§¨£››²²¬¦§¨‰ƒv¦§¨µ¶·ÃÄƤ¤µ¶·“Œ”””‹”š”£œ¥¦§¨µ¶·››”””‹‹„„‹‹‹œ››“Œ”tts¦§¨™š¤²²¬””‹¤¤‹’Š”››Šƒ}ttsVTLtts”š”‹‹‹uzt{ttttsƒ„„]bZƒƒ|¦§¨uztllk„Š„{{tztlƒƒ|‹‹‹Œ”•uztd\\lddƒ||‚|uztlŠ}ƒ””‹‚utedk„Š„tts“Œ”lld’ŒŒldd™š¤Šƒ}„Š}‹‹„Šƒ}f]c‹‹‹{{tldd„„Š‹‹„™š¤‚uttts[TTSKJŒ‹“lriekdƒ‚uŠƒ}tts‰v|“Œ”²¬µ¤¤¤¤£››‹‹‹ƒ}ƒ™š¤ƒ‚ukk]‹„‹””‹ƒ||‹‹‹››”‹’Šztlultƒƒ|‹’Š””‹‹„„“Œ”ƒ}ƒŠƒ}{||ƒƒ|Œ”•{ttlrikk]{u{…‹‹¨©´ƒƒ|tll{||Œ”•‹‹„ƒ}ƒ{||u{{‹„„{{tult‚|uƒ}ƒ”š”””‹tsl””‹œ¤¦‚v{›”›{{trg]{{t‘Œ…ƒ||›”›‚ut“Œ”“Œ”››”{{t’ŒŒ’…‹d\\ttskk]’ŒŒ”“›‰‘~¦§¨ttsŒ”•œ››‰|vsre››”‚|u{{tdc\kk]ƒ||ƒƒ|d\\{u{slered{tt{tttll\[[{u{lld{||VTL{tt|„…ttslldztl’ŒŒŒ”•lks{||‹„‹lritts‹„‹Œ”•uzt™š¤lddtll|‚z”››llk{||ƒ„„‹’Š’ŒŒ‹’ŠVZT\UZlrislef]cu{{{{ƒ‹…štlldc\UTSlri‹’Šlks…‹‹ƒƒ|‹„‹{|||„…œ¤¦{|||‚zddctslƒ}ƒekd{tt[TTƒƒ|{tt{u{Šƒ}{tt››”Šƒ}dc\µ¶·JHF*)(„Š}“Œ”œ¤¦‘ˆ}””‹£œ¥‘Œ…£››””‹»ÂǦ§¨²²¬²««²««¦§¨¦§¨œ››¨©´›”›£››“““ƒƒ|ƒ||tzl™š¤…‹‹ƒ}ƒ‹’Š¤¤¦§¨£œ¥ŠŠ}ƒ‚u¦§¨uztuzt“Œ”››”ƒ}ƒ‹‹‹tslttsŠƒ}ddc‹’Š|‚z„Š}|‚zlridc\ƒ||ttsuzt„Š„ƒ||ldd{u{d\\zll£››š””œ¤¦¦§¨¦§¨¦§¨ƒƒ|‹‹‹”š”{{ƒ²¬µ’ŒŒ£››‘Œ…‹‹„tllƒ}ƒtts…‹‹„Š„‹„‹yleš””tllƒƒ|mttVTL’ŒŒtt{”“›ƒƒ|kd\ƒ„„ƒ‚uVTL’ŒŒ‚|u‚wlš””tt{‚|ullkdc\tslult‹„„ƒ||‘Œ…‘Œ…‹‹‹jcVmw{zm¦§¨£œ¥‹…’™š¤‹’Š›”›{u{{||‹‹„“““{u{‹‹‹Œ”•Œ‹“{||‹‹‹ƒ„„{{t‹‹‹tslƒ|||„……‹‹{||‹„„›”›ƒ}ƒ‹„‹tts‹‹„|‚z{zm¤¤tll{u{ƒƒ|{{t›¢›{{t””‹ƒ||ƒ||{{t‹’Š|„…‚|uŠ}ƒyleƒ||red„Š„””‹ƒ||’ŒŒ‘Œ…””‹ƒ„„dc\uzt””‹‹’Šƒ||slekd\mtttzl\[[ultƒ||’…‹‘…„sle“Œ”ƒ||‹‹‹ƒ„„|‚z„„Š{{tb[UtllŒ”•„Š„lld…‹‹”“›ƒ||””‹„„Šœ››|„…ztlœ››„Š„Œ”•’…‹lddŒ”•tts„Š}|‚zmtt™š¤”“››¢›{tt{{ƒmtt””‹|„…Œ”•tt{ƒ}ƒred‚v{lksŒ”•ekdleklksztllek„„Šuzt„Š„dc\[[Tekdlekƒ}ƒlld{||[TTtlllddlek{tt‚ut„Š}Š}|]bZ··ÄJHFF=C‹„„Š~‹””‹²««²««£œ¥””‹ƒƒ|‰‘~¢—£››ƒƒ|šŒ‘…„‘Œ…š””²««››”²¬µ··Ä“Œ”œ››Œ”•›¢›llk“““‹‹‹{tt››”£››Š}ƒ‹„„¦§¨ŠŠ}‹‹‹„„Š…‹‹lritts‘Œ…‹‹„tsldc\ttsƒƒ|\[[[[Tkd\VTL[[Tr]g‹‹‹‹’Šek]“Œ”{ttlldllk‚ut”š”‹„„ƒƒ|‹’Štts„Š„‹‹‹zlldc\{||“Œ”rfk¤¤”“›››”„„Štsl‹’Šƒƒ|‹’Š“““‹‹„ƒ||tllllktzlƒ||‚wlŒ‹“{||redsleSKJ{{tƒƒ|zllsletsl{zmlekf]c„Š„rg]„‰vttsŠ}ƒ{||š””””‹¦§¨‹‹„””‹sle|‚z””‹“Œ”“Œ”‹’Šƒ}Šu{{{tt¤¤‹„„‚utƒ}Štt{ƒ}ƒllkllkƒƒ|“Œ”lld‹‹‹{tt”“›”››‹‹„{ttult‹‹„‹„„f]c›¢›ƒƒ|ƒ‚u‹‹„ƒ„„‹„‹›”›‹„„¤¤ŠŠ}sre£œ¥{||‹‹„„Š„‚|u{tt‹„„llk{tt””‹JHFtts{zmrg]{{tŒ”•ƒ„„{{t‹„„¦§¨£››jcVdc\sre]cd{{t¤¤¦§¨“Œ”š””‚uttts‚utœ››Œ‹“‹’Š[TTddcsref]clldult‹’Š„Š„™š¤u{{›”›kk]“Œ””“›ª³·ztl„Š}‹’Šult“Œ”Œ‹“u{{š””„„Š‹‹„|„…‹’Š“““lri]bZlldfkkVZT]cdllk{ttŒ‹“‚|u‹„„VZ[mttŠƒ}‹…’llkŒ”•{ttmtt]bZedkdc\{||fkk{u{lddzll{{ƒtllultyfdred››”ldd‹’Šƒ||ƒƒ|¤¤JHF*)(tsl’ŒŒ”š”²²¬¢—š””””‹’‘~‚wl””‹¦§¨‘Œ…£››¤¤“Œ”²¬µ¨©´²¬µ“““œ¤¦¦§¨£œ¥«²«‹‹„“““™š¤‹‹‹„Š„¦§¨‘Œ…£œ¥¦§¨‰|v¤¤™š¤u{{‹‹‹››”Šƒ}¦§¨{||dc\uzt„Š„]bZ{||ƒƒ|‹’Štzllriƒ}ƒŒ”•‹‹„Œ‹“‚|u{tt{ttƒƒ|‘Œ…Šƒ}kd\r]gztl¦§¨tsl{||llkVTLtt{‹„„‹„„Šƒ}uzt’ŒŒ„Š„‹„„{||sre{{tƒ„„‹‹‹sle’ŒŒtslƒƒ|“““lddtt{{{ƒkd\sre‹„‹|‚z‹‹‹tllƒ||{zm„Š}f]cVTLztl‰|v’ŒŒŒ‹“sle„„Šœ¤¦ƒ‚u‹’Šƒƒ|£››‹’ŠŠŠ}“““Œ‹“”“›…‹‹’ŒŒmtttsl››”›”›‹„‹Œ”•ultd\\lks‹„‹“““ldd|‚z‹„„™š¤™š¤tts‹‹„‹„„Š}ƒtsl[TTƒƒ|{zmdc\ztl‹‹„‹„‹{tt‚|u¦§¨ŠŠ}””‹{{tult{ttlri„Š}”“›zllult‹‹‹tll‚|u””‹f]cultŠŠ}Œ”•sreŒ”•””‹«²«’…‹“““ƒƒ|lddredSKJtslcbVtllƒ||ƒ||sle£œ¥‹„‹VTLb[Uddc‹‹‹|„…tll‹„‹{{tllkuzt|‚zSKJlri{||‹„„£œ¥“““‹‹„¦§¨{tt›¢››”›‹„‹’ŒŒlriŒ”•{{ƒkd\¨©´Œ”•™š¤uzt„Š„ŠŠ}JHF|„…lriƒ}ƒf]c\UZ]bZult|„…ƒ}ƒƒ}ƒ’…‹lkslrimtt|‚zttsSKJlriuztedklksƒ||ƒƒ|tts‹‹‹ttsrfkd\\{u{Š}ƒ‹‹„Š}ƒ{||£››:97*)(œ¤¦’ŒŒŠƒ}²««²««²««š””¦§¨””‹‘ˆ}µ¶·²««“Œ”²««²¬µ²¬µ¦§¨™š¤‹‹‹¤¤ƒ}ƒ¦§¨“Œ”“““œ¤¦”“›Œ‹“››”¦§¨””‹£››“Œ”llk²²¬{{tuzt£œ¥ƒ„„tll£œ¥¦§¨Œ”•|„…‹’Š|‚ztzl‹’Š‹…’lri””‹ƒ„„”“›{zmŒ”•””‹{tt{ttƒƒ|Šutztltsl››”Šƒ}“““‘Œ…{||{zm{||„„Š{{ƒ{u{ƒƒ|uzt{{tVTLf]c|‚z‹‹‹{||ƒ„„d\\£››£››{zmdkV[[Tddc‹’Šƒ}Š‚|u[[Tƒ„„{{ƒ„„Š{ttsleƒƒ|ƒƒ|f]c{u{ƒ„„”››š””Š}ƒ’ŒŒ{ttŒ”•‘Œ…””‹£››¤¤¤¤‹‹‹’ŒŒ“Œ”ƒƒ|‹‹„œ››tsl“““‹„„‹‹‹tt{ult‹…’zllddc’ŒŒ{ttƒ||{{tu{{‹’Š”“›‚ut‚|u“Œ”Œ‹“tll{zm„Š„ƒ||ƒƒ|‚wl“““‚v{šŒyl„›”›””‹‘Œ…Š}ƒ{ttsleŠƒ}{{t{tt›”›ƒ„„{ttlddekd‹‹‹‚ut„Š}””‹””‹{{tµ¶·“““¦§¨’ŒŒ”››„Š„redkd\VTLsleldd{||‚|u{ttŠŠ}|‚z{tt‘…„ƒ„„lldlriztl››”‹„„{{tVZ[‹’Štts]bZ{||Š}ƒ‹„‹tllŠƒ}{zm{tt{||””‹‹‹‹‹„„‹„„ztlfkk“Œ”rg]Œ”•™š¤tt{mtttsl”“›ddc…‹‹MRKlkslriƒ}ƒtlltts{{ƒ“Œ”{{ƒŠ}|Œ”•{||ekduztttsedk””‹lrilksŒ‹“ƒƒ|lri[TT{{ƒ{u{ƒ||kd\{tttlltts{{t‹’Š””‹:97*)(£››¦§¨””‹’…‹£››ƒ||£››ŠŠ}‘ˆ}››”””‹£››²¬µ²¬µ²««£œ¥²¬µ™š¤£››”››ƒ||““““““µ¶·„„Š”š”¦§¨››”››”Š}ƒš””ƒ}ƒ”š”„Š}¦§¨ƒ}ƒ£››‹‹„Š}ƒ‚|u‹‹‹|‚z‹’Š[[Tkk]|‚z¦§¨“Œ”|‚z„Š}¨©´”š”{zm|„…›¢›£››‹„‹‚|uztl‹‹„‹„„””‹””‹Œ‹“ƒ‚u|‚z‹‹‹{||f]cttstll{{t‹’Škd\ƒ„„“Œ”’ŒŒtzl„„Šf]c\UZ‘Œ…{{t‚ut{tt|‚zekdƒ}ƒttsz‚lrg]‹…’’…‹ƒ‚uƒ||››”‹’Š””‹ƒ}ƒ‹„„‹„„{||‚utf]c‹„„{||lddkd\tll¦§¨sle‹’Š|‚zƒ||{||„„Šƒ„„{ttttsŠŠ}š””ƒ||„„Š‹‹‹£²’ŒŒŒ”•œ››ƒƒ|{u{|‚z|‚z]cdtts{{ƒ‹„„„„Šƒƒ|ƒ„„ƒ||tts’ŒŒ‹„„””‹‹’Štts”“›ult{||””‹ztl‚wl””‹zll„Š}{{t‹‹„œ¤¦£››ƒ„„\UZ””‹‹’Š{{t{{tš””››”ƒ‚n{||…‹‹‚wl“Œ”ldd‘Œ…{zm{u{mwzllbVUkd\lddslef]c[[Tredtlluzt{zm\[b‹„‹””‹j]\ƒ„„VTL|‚z{{tVTLlri{tt‘…„\UZek]…‹‹lld{{ƒ‹’Štt{ddclddUMRlld…„’ztl“““tt{ddcleklddf]c‚v{lksVZTf]ccbV{{ƒlldddc{{ƒult‚v‚‹‹‹lksfkk…‹‹|‚zuztœ¤¦lld\[[mtt{||ldd|‚ztt{ƒ}ƒllklddztf‹„„ttsƒƒ|lriVTL’ŒŒ:97*)(›”›¨©´«²«²««’…‹Š}|²²¬²¬µ‹‹„‘Œ…””‹¦§¨£œ¥²««²««£œ¥µ¶·¨©´‹‹‹Šƒ}„Š„‹‹„’…‹™š¤„Š„”››“Œ”››”ŠŠ}µ¶·›”›Š~‹‹’Š¦§¨¨©´‹„‹‹„‹ŠŠ}””‹ƒ‚uƒ||dc\llkƒ||{{tiq]…„’|‚zuzt‹‹„tzlŒ‹“{{t‹‹‹‚|u‹„‹„Š}‘…„’…‹sleŠƒ}¤¤²²¬““““Œ”“““‹’Šttstlltsluzttzl”››d\\{ttlddrfkkd\{{tdc\{tt‚ut‹„„u{{tllrg]UTStll„Š„sleš””ult„„Šred‚|uš””‹’Š‹’Š{{tœ››|„…[[Trg]j]\tllldd{{ttsl{ttzll‚|u›¢›„Š„“Œ”‹‹‹ddclld‘Œ…“““’ŒŒƒ„„¦§¨{{ƒŒ‹“…„’{||{||””‹lekŒ”•‹’Š{{ƒlldultmtt{ttdc\„Š„‘Œ…{ttŠƒ}{ttuzt””‹œ¤¦£››‘…„‘Œ…{u{ƒ}ƒztl’ŒŒ””‹£››“““ŠŠ}“Œ”tsl„Š„ulttts|‚z„Š„ult‚utrg]{{t‚|uVTLSKJkd\|„…ƒ||{{tztlttsd\\ztltll””‹zllkd\f]clld[TT\UZultVTLsrelri]bZ{ttd\\:97{ttekdƒ‚ntt{ztljV[{u{VTL[[Tdc\‹‹‹ƒƒ|lek|„…”››{ttultŒ‹“lddŒ‹“{||lldŠ}|UMRbVUƒ}ƒmttFD;llkuztf]clri{{ƒult{tt[[TVZ[nv‚\[b]cd‹’Štsllkstsluztf]clddd\\lkstsllekƒ}ƒbVUzllƒ||tllƒƒ|ddcb[U‘Œ…:97*)(£››¦§¨‹‹„£››£œ¥¤¤»ÂÇœ¤¦–¢‹¤¤¤¤¤¤²««‘Œ…šŒ“““œ¤¦¦§¨”š”ƒ‚u{zmzllƒ}ƒ‹„‹ƒƒ|{||VZTœ›››¢›¨©´ŒŒš“““””‹£››‹‹‹ƒƒ|“Œ”‘Œ…sle‹‹„ult”š”tzl‚utƒƒ|u{{‹‹‹|„…]bZ[TT{{ƒƒ‚ukd\Œ”•””‹sletsl‘…„“““{zmŠŠ}”š”””‹‹‹„””‹„Š„{{tttsƒ}ƒœ››Œ”•{||ƒƒ|ddc{||SKJzllslesreUUY‹„‹‚|uƒƒ|UTS{ttVTLJHFƒƒ|{u{{{taWMmtttsl{u{Š}|œ››””‹‹‹‹…„’tzldc\uzt‚ut{||ƒ}ƒ“Œ”‘Œ…š””‹‹‹‹„‹{tt“““¦§¨ƒ}Šult‚ut„Š„ƒ}ƒ|„…‹„„™š¤””‹|„…lek”“›‹„‹Œ”•ƒ||’ŒŒ“““{{ƒllk‹‹„\[[uzttlllldlks‚|u’ŒŒ‹’Š””‹|‚z‹’Šƒ||“““”“›ƒ}ƒŠ}ƒƒƒ|‚|u””‹‹‹„tllƒ}ƒƒ‚u””‹ƒƒ||‚zƒ}ƒVTL‹‹„„‰vek]tll{zmaWMlldVTLkk]rg]\[[‹’Š‹‹‹‹„„{tttts{u{‚|u{{tultƒ||[TTultbVUSKJŠ}ƒdc\dc\‹„‹{||ldd[TTlrildddc\‚|u‹‹„ƒ||‚v{™š¤‹‹‹tzl{{t{{tƒ‚utllƒ„„{{t¦§¨{ttŒ‹“Šƒ}‚v{„Š„™š¤‹’Š‹„„Š~‹ƒ}ƒedkVZ[\UZVZTfkklldUUY{|||‚z]cdekd|„…|„…mttlekVZTlksuzt|„…u{{lek‹‹„ƒ„„f]clddultsleultƒ||ztl‹‹„{ttsre‹„„JHF74,ƒ}ƒ£››””‹£››£››£››››”››”››”£››‘ˆ}™‹†››”‘Œ…²««š””›”›‹’Š‹‹‹””‹””‹‹‹„ƒ||”››ƒ„„¦§¨„„Šµ¶·¦§¨‚v{œ¤¦{{ƒ™š¤””‹¨©´{{t¨©´‹‹‹tsl¦§¨ƒ||‹‹„™š¤ƒƒ|{tttslddcMRKuztsre\UZ‹’Š‹„„‹’Šƒ||‹„„ƒƒ|‘…„‘…„Š}ƒ””‹‘Œ…ztl”“›ƒ‚uƒ„„lldVTLƒ||{u{ƒ}Š‹‹„lddf]c{{ƒrfkŠ~‹rr]››”ƒ}ƒ‚v{ƒ||Šƒ}ƒ||£››tzl‹’Š‹‹‹’ŒŒ”“›‹„„…‹‹…‹‹“Œ”””‹’ŒŒ|‚z{||“Œ”lksƒƒ|{{ƒ‚|uƒ„„ƒ||”“›‘}z‘Œ…š””ƒƒ|””‹{{tƒƒ|“Œ”tt{›”›‹‹„‚ut“““{tt’ŒŒ¦§¨›”›{{ƒ…„’|‚z…‹‹“Œ”’ŒŒ‹„‹|‚zƒ||‹‹„tt{mttƒƒ|””‹Œ‹“‚|u‹‹„{{tztlƒƒ|””‹‹’Šƒƒ|“Œ”lekƒ}ƒlri”š”rg]|‚z{ttddc‹„„‚wl|‚z”“›œ¤¦{ttŠŠ}dc\‚|uŠŠ}‚wlcbVkd\ztld\\tzl{{t‹‹„lldkd\tllllk››”£œ¥‹„„{ttsred\\””‹llklekŠ}ƒredkd\SKJekd\[[dc\\[[UTSsre\[b{{ƒdc\rfkult›¢›„Š„›¢›Œ”•””‹ultƒ}ƒllkƒ}ƒUMR\[[lldddc{||{u{ƒƒ|{{t{ttulttll›”›ƒ}Š|„…£œ¥|‚z|„…tt{ƒ}ƒ™š¤„Š„MRK{{ƒmtt{||tsl{||mtt|„…ttsƒ}ƒŒ‹“{{ƒUMRSKJred‹„„‹‹‹ƒƒ|lddd\\ttsƒ‚u””‹>B9:97‹„„Š}|‘ˆ}‘ˆ}Š}|£œ¥¤¤‚|u–¢‹£››²²¬£œ¥‹’Š£››£››“““œ¤¦ƒ„„‹‹‹”š”‹’Š’ŒŒ””‹”š”””‹¦§¨£œ¥£œ¥”“›””‹ƒ||“““ƒ‚u””‹“““sre¦§¨‚|u{||Šƒ}tlllri‹‹„‘…„lritslult„„Šmtt|‚z„„Š‚|u‹„‹tsltslrfkƒ„„””‹{tt„Š}‹„‹ƒƒ|„Š}¦§¨kd\[[T|‚zkk]””‹„„ŠŠŠ}‹‹„redUMRbVUrfkƒ||VTL‹‹‹ldd{tt‹„‹‹„„‚ut‚|u‚ut[[TVTLb[Uztl£››f]clks‹„„‚utŠƒ}“““|‚z„„Šred‚|ulri””‹tsllekƒ„„Œ‹“zll”“›‹’Š‹„„ƒƒ||‚z{ttƒ}ƒ…‹‹‹„„ƒ||Œ‹“‹„„‹„„‹’Š™š¤|„…Œ”•›¢›ekd“““Š}|tts|„…”š”|„…tslŠ~‹Œ‹“œ¤¦{u{sle{{ƒyle’ŒŒƒ„„‚utŠ}|f]ctts‹„‹‹„‹lri››”‹„„–¢‹š””‹‹„‹‹„‹„„›¢›UTSd\\lldtsltzl””‹llk¢—{yfsle‚wltsltllƒƒ|ƒ„„lek‚|u‹uŠiWUslettsƒ„„sleƒ„„lekƒ||ult‹…’ult|„…VTLztlkk]Š}ƒ{||]bZƒ‚ulddtt{tts{zmbVUƒ}ƒf]c„„Šœ››|„…””‹Œ”•ttstslƒ„„{u{‹’Š„„ŠŠ}ƒlektll|‚zaWM£››lks{{ƒ{||‹…’¦§¨Œ‹“š””…‹‹ƒ}ƒfkk|„…\[[VZ[ult\[bttsekdf]c“““{{ƒ{||‹„‹„Š„ƒ„„srett{j]\‚|uj]\lddlddddc‹‹‹lri””‹JHF-1+“Œ”™‹†sle£››››”‘…„‰ƒv‚|u¢—‘ˆ}¤¤¤¤””‹{zm¨©´²¬µ£œ¥””‹¦§¨ƒƒ|””‹ztf„Š}{tt”›››¢›„Š„£››‹’Šš””¨©´“Œ”””‹Œ‹“[TT“~ˆ“Œ”‹’Š‹„„‚|utll[[Tr]Zrfkult{||œ¤¦„„Šllk”š”¦§¨ƒ||UMR“Œ”ƒ}ƒŠƒ}ŠŠ}tllbVZ›”›{zm„Š}šŒtsl‹‹„kk]uzttslš””UTSmw¤¤\UZ{{ƒSKJ’ŒŒkd\ztfdc\‹‹‹{u{‚|u‚utƒ||Šƒ}“Œ”lld{tt|‚zŠ}|’ŒŒzll{{tƒ||’ŒŒ‘…„‘Œ…ekd\UZ{{ƒrg]{zmjcVlldultƒ||œ››››”ƒƒ|‹‹„‹‹‹„Š„lri“““›”›‹‹‹£œ¥‹„‹ƒ||{zmu{{tsltt{llkmttUUY…‹‹“Œ”redu{{llk|‚z…‹‹“““uzt›”›‹’Š“Œ”{||Š}|dc\ƒ}ƒ’…‹£››ƒ||lksf]credult””‹{{tsle¦§¨{ttœ¤¦“““’ŒŒrr]tt{‹…’ƒ„„‘Œ…ƒƒ|””‹ƒ||ƒƒ|{zm{{t‘Œ…‚wltllztlƒƒ|j]\VTLƒƒ|Šƒ}‰ƒvd\\ult‹‹„‹‹„ƒ„„tllultf]cuztlri{||[[Tztlf]c‹„‹‚utek]ekduzt{{ƒztltllult„„Š¦§¨ƒƒ|lri””‹›¢›tt{ztl”“›lek{{t|‚z‹„„”››{tt“““Šƒ}“Œ”{{ƒŒ‹“”“›{{ƒ\[[|„…“Œ”ƒƒ|lks…‹’|„……‹‹u{{{{ƒVZTllkztlult{{t{{ƒƒ„„{{ƒttsƒƒ|tslƒ}ƒlddbVUbVU‹„„tts{{tuzttsl‰ƒvMRK*)(‚wl‘…„{tt£››››”””‹¤¤š””¢—’ŒŒ‹‹‹Šƒ}µ¶·¦§¨¦§¨²««²««“““œ››‘Œ…””‹””‹Šƒ}Œ”•‹‹„ƒ„„‹„„ƒ||ƒ||{{ƒ””‹››”“Œ”¦§¨ƒ}ƒ£œ¥ƒƒ|‹’Šlj¦§¨“Œ”sle‚utyflƒ||…‹’‹„‹{{ƒ„Š„¦§¨…‹‹‹„‹ŠŠ}Šƒ}‹„„Šƒ}|„…Š}ƒ‹‹‹²««››”¤¤ultuztztl\[[‚v‚””‹“Œ”””‹¦§¨„Š„‹„„lldddc{tt‚utƒ}Šttsƒ„„b[U£››lkstts£››bVUUMRj]\zllztfiWUƒ}ƒd\\Š}|‚utult››”ƒƒ|ƒ„„ldd‹’ŠtslSKJlddredƒ||ƒ„„œ››””‹i\VŠƒ}|‚z‹‹‹‚v{‹‹‹ƒ„„ƒ}ƒ“Œ”œ¤¦‹„„“““ƒ„„ƒ„„lldedktslƒ„„‚|uzllddclksztl‹…’›¢›‹’Šƒƒ|Šƒ}{u{“Œ”llk„Š„¦§¨kd\“~ˆllktslttsƒ}ƒd\\{{tlld‘Œ…llkƒ||‹‹‹ƒ||‚v{‚|u¦§¨”š”£››£››{{ƒ‹„‹¤¤‹’Šƒƒ|‹‹‹sre””‹œ¤¦kd\‹’Š{u{¦§¨”“›lekƒ||uzt‹’Š{{tddcttsfkk‚v{ƒ}ƒƒ„„UTS{{tƒ||‘Œ…Š~‹”“›…‹‹„Š„‹‹„uzt{||‘ˆ}kd\“Œ”kd\›”›rg]lritzl“““„Š„uztŒ‹“›”›”“›z‚l””‹›¢›tts”“›‹„„{tttllŒ”•|„…{{ƒƒ||f]cddc‚utŒ‹“ƒ„„…‹’|„…lrif]cŒ”•ƒ}ƒ„„Šddcuztu{{tts[TTllk“Œ”{tt{u{bVU’ŒŒlek{ttldd””‹‹‹„{{t¦§¨JHF*)(zll‚wl‹„„’ŒŒ’ŒŒÃ¼¿¤¤””‹Ä¿’ŒŒ‚wlŠ}|‘…„¦§¨£››‹„‹£››¦§¨””‹””‹‹‹„‘Œ…Šƒ}‹‹‹››”‹’Š„Š„“Œ”œ››¦§¨¨©´£œ¥¨©´¦§¨‹…’ƒ}ƒ›”›““““Œ”””‹‘…„i\Vtslzll””‹llkƒ||tllekdlri‹’Šƒ}ƒœ››”››“Œ”ƒ‚u‹„„‹„„‹„„«²«¦§¨{{tslelldlrilldaWM[[Tj]\›”›ŠŠ}|‚zƒ„„dc\ult“Œ”‚utSKJ\[[VTLtllztl‚v{‹‹‹lekUMR{||\UZzllƒ‚usledc\{{ƒ{u{‚ut{tt‚|uƒ„„llkd\\ƒƒ|{ttŠƒ}{tt‹„„ƒ||’ŒŒƒƒ|‘…„””‹‹„„””‹tts‹„„‹„‹ƒ„„fkk‚v{ƒ„„›”›tll‹„‹leklks„„Š|‚z|„…ƒ||’ŒŒult{{ƒult{||ƒ„„Œ”•{ttlldƒ}ŠlddUTStsl‹„„Šƒ}ƒ}ƒ{ttztff]cUTSd\\lriƒƒ|tsllldVTL[[Tsre{u{lldtslddc{ttŠƒ}slekd\llkƒ‚u‹’Š””‹„Š}{ttœ¤¦{{t“““ƒ}ƒtsl„Š}‰|vkk]‹‹‹llkuztultƒ}ƒultldd“Œ”{ttttstts{zmtslƒ||’ŒŒœ¤¦ƒ„„ƒƒ|lkstzllks‹‹‹lekdc\‚utsleVTLlekƒƒ|{||b[U{u{ƒ}ƒ|„…‹’Šsle{||tll{{ƒƒƒ|‰|vtll{{ƒ†~‘“““tslldd{tt‹‹‹{{ƒ\[[mtt|„…lks“Œ”„Š„›”›™š¤„„Š|‚z{{ƒ\[[‹„‹…‹‹‘Œ…“Œ”š””slered{u{‹‹„ƒ„„„Š„„Š„ƒƒ|£››:97*)(’ŒŒšŒšŒš””£››¤¤‹‹„¼À¯¤¤²²¬œ››£››²««£››²¬µ¨©´²²¬µ¶·›¢›””‹š””Š}ƒŠŠ}“““¦§¨¦§¨ƒ}ƒ£››£››£œ¥Š}ƒ£››‹„‹””‹ult{ttƒ}ƒ{{tzll‹‹„›”›‘ˆ}slezllUTSVTLtsltts{||‹‹„‹’Šœ››{u{ƒ„„¦§¨‘Œ…Œ”•{tt¦§¨¦§¨„Š}””‹‚uttsl{||‚|u‚|uUTSredrfkuztdc\VTLƒ}ƒ{tt£œ¥””‹VTLƒ}ƒd\\›”›uztyfd‚|udc\Šutƒ||Š}|f]c{ttƒƒ|ttsUTS’ŒŒƒ‚u{||kd\Œ‹“ƒƒ|ƒ„„‹„„sleŠƒ}‹‹‹{tt‹„‹œ››Šƒ}šŒ’ŒŒƒ||‹‹„‹’Šƒ||’ŒŒ…‹‹Šƒ}ƒ}ƒlektsldc\{zmtt{{{ƒtt{ƒƒ|{{ƒƒ||“““™š¤bVZƒ„„”››{||‹‹‹{tttts”“›d\\[TT[[T‹„„‹‹„ulttllŠ~‹tll{u{ƒ||Šƒ}VTLƒƒ|››”ztl…‹‹{||aWMbVUVTLSKJcbVlek[[TaWMMRKrg]››”{||””‹ŠŠ}‹„„d\\‚v{Šƒ}‹„„{tt{{tVTLƒ‚u„Š„¦§¨b[U{tt\UZ{{tUTSkd\{||ult{{ttslb[Uult‹„‹{{t™š¤|„…{{tbVUŠƒ}lek\UZ‹„‹zll›¢›£œ¥ƒƒ|tll]bZ‹„‹‹‹‹{{tŒ”•š””Œ‹“ƒ„„Œ‹“””‹ƒ„„¦§¨„„Š{u{tts|‚zƒ}ƒttsf]c{{ƒ\[[\[b]cd]cd\[b…‹‹{u{{{ƒ{{ƒuzt|„…tslu{{‹‹‹{{ƒ’ŒŒ“Œ”‚utztlkd\ztllld‹‹„‹‹„[[T¦§¨D;9:97””‹£››‚wl™…‹„„””‹¦§¨””‹¤¤“““¦§¨¤¤²««£››²««£››¦§¨¦§¨””‹””‹™‹†’ŒŒ„„Šƒƒ|””‹¦§¨Œ”•£œ¥²««¨©´£››¦§¨£››’ŒŒ‚utult{tt‹’Š£››‘ˆ}›”›‚|u››”››”Œ”•lld‚|ubVZuzt„Š}{yfŠƒ}lri£››ƒ}ƒŠƒ}ƒ„„ttsƒ‚uš””ƒƒ|‘Œ…ƒƒ|ztl¦§¨‹‹„‚|usre“Œ”lddkk]kd\[[T[[T{tt‚|ub[Uredƒ}ƒult‚v{|„…Š}|ƒ||Œ”•f]cr]Zult’ŒŒcbVjcV{||‹‹„ultred‹‹‹{{tlldrfklrillk|‚z‹„„‹‹‹“Œ”rfkƒ„„„Š}Š}|¦§¨ƒ||ƒƒ|„Š}tll‹‹‹u{{’ŒŒ‹„„edkœ››|‚zlld|„…‚utddcmtt…‹‹ƒ||Š~‹jV[edkzll“Œ”lri…‹‹‹’Šu{{tt{‹‹„sleuzt¤¤‚|uultš””{u{‹‹‹’ŒŒrg]¤¤mtt|‚zƒ‚u{tt[TTbVUb[U[TT3+*kd\kd\ek]cbVlld‘ˆ}ztl‹„„‘ˆ}{ttƒƒ|‚utŒ‹“tsl””‹“Œ”VTLtsl‚|u|‚zŒ”•{tt‚v{“““\[[‹„‹dc\b[Uddcb[Ub[U””‹lld\[[{u{£››lldultllddc\tsllekllkŠ~‹sleuztlritsl””‹u{{ultlddƒ„„„‰vŠƒ}Š}|Š}|Œ”•››”£œ¥{u{‹„‹f]cllk›¢›ƒ}ƒlddlekmttmttdc\tt{mttedktll“Œ”|„…ƒ}ƒlri\[[{{tuztŒ‹“‚utslezll‹„„’ŒŒkd\red{ttdc\uztlldµ¶·UMR:97‘ˆ}ljljŠƒ}Šƒ}sle‹„„‘ˆ}›¢›‘Œ…””‹£››£››²¬µµ¶·šŒ¦§¨¦§¨””‹””‹›¢›d\\|‚ztsltzl‹‹‹”“›““““““‹„„£œ¥£››””‹‚|u‰v|””‹¦§¨ƒƒ|”š”‘Œ…„„Šztl‹‹„tts‚v{“““””‹{{ƒ”“›ƒ„„uzt{{ƒlld{tt²¬µ””‹dc\{{t²««“Œ”””‹ƒƒ|”š”››”lldrfk{||ƒ||Š}|ƒ„„‚|ulldlldbVU{tt‚v{yleek]{ttddcƒ||]bZtsl‹‹„‹„‹“Œ”{zmldd‚utdc\aWMddcttsredš””tll››”{{tzll{{tldd‚ut‘Œ…‹‹„£››b[U„Š}ƒ„„‹‹„‹‹‹uzt‘ˆ}„Š„{ttsle\[[ƒ||llktts‹„„{||‹’Šlri…„’ƒ„„fkk|„…rg]ult‚|ullk{||llkƒ„„|„…‹‹‹|‚ztll„Š„kd\llk¤¤””‹£œ¥’ŒŒuzt‘…„Œ”•f]c{{ttsl‹’Šsle|‚ztllultVTLj]\{ttrfk‚|u“““‹’Šb[U‰ƒv“““šŒVTL‚|ulld{{t‹„„dc\‹‹‹ƒƒ|uzttslsledkV‹‹„ƒ‚uƒƒ|llk{tt‚v{tsl’ŒŒrg]lldVTLlri‚v‚tts¦§¨””‹‹‹„llkb[Ullkttsrfk{u{›”›£››llk‹‹„”››|‚zƒƒ|{{ƒd\\ldd”š”‚|u’ŒŒ‘…„”“›lriƒ‚u‹‹‹ultf]cldd|„…tt{ddctt{{{ƒedklri\[bu{{ultd\\lksek]lkslri\[[{ttƒ„„ƒ}ƒ‹„‹Š}|tlllddi\Vlri‚wlj]\ƒƒ|ƒƒ|tzl¤¤VTLJHF‚wl‰ƒv“~ˆŠ}|‘…„””‹µ¶·£œ¥š””¦§¨²²¬²««›”›£œ¥Â¾Æ²««²««²¬µ‘…„‹„„””‹tts„Š}›¢›‹‹„›¢›‹‹‹¦§¨¦§¨£œ¥¦§¨£››””‹œ¤¦¢—Šƒ}’ŒŒ›¢›››”‹„„ttsldd‘Œ…„Š„tll{{ƒ‚ut“““ult…‹‹„Š„‹„„lrilekƒ‚u£››{{tƒ||’ŒŒš””””‹ttslriultttsŠƒ}£œ¥””‹’ŒŒ‹„„ƒ‚u›¢›kk]SKJ“““j]\‘Œ…ldd„„Š[TTƒ}ƒ|‚ztt{ƒ||zllbVUVTLbVZ{tt{tt“““{{t]bZyleš””“Œ”ƒ||„„Šd\\|„…{{t‹‹‹‚|u‘Œ…Š}ƒ””‹‹’Š‹„„sletsl‹„„„Š„tll””‹tll|„…ztllek{u{{tt{{tœ¤¦Œ‹“ttsttsu{{ult›”›ttstllulttt{ddc…‹‹llkulttlltt{ƒƒ|””‹ulttsl[TTtllœ››tslƒ||›”›š””‹‹„ultztlkd\‚|ullk‘Œ…‘Œ…kk]”››‘…„UMR„Š„„Š}”š”srezll‚|uyleŠ}ƒSKJllk{ttsreVTLƒ‚uuzt{{t£››ztl”š”ƒ„„„Š„‹‹‹\[[{tt{ttŠ}|j]\{ttƒƒ|sletllzllƒ}ƒ‹„„„Š}LKRuzt‚utŒ‹“ljedk‚v{‚|uttslridc\””‹‚|u”“›{tt‚|utsl‹’Š”“›¦§¨‹„‹tslŠ~‹lksttsf]cztl]cd[TTtzl{||mtt{{ƒu{{‹’ŠUUY]cdkd\uztƒƒ|””‹lriUTS{||d\\{tt{u{‹„„yleyleyleJHFkd\red{{t{{tŠƒ}¤¤JHF*)( ””‹£››‚wl’ŒŒ“““¦§¨›¢›¢—²««Ã¼¿²¬µ²««£œ¥£œ¥Ã¼¿²¬µ””‹ƒ||“Œ””š”””‹¦§¨¤¤””‹›¢›“Œ”””‹›¢›ƒƒ|Œ”•Š}|¤¤ult“Œ”š””””‹‹‹„œ››ƒƒ|rfk””‹²««‹„„jcV{{t“Œ”‹‹‹ldd””‹”š”ƒ„„{||ƒ„„|‚z’ŒŒƒ„„ult‹‹‹j]\””‹lldldd{{tcbV{tt„„Š„Š„‚wl‹„„””‹{{tcbVSKJš””‚|ukd\j]\lld’ŒŒ{ttœ››tllƒ}ƒ™…kd\tsl‚ut¤¤tyg””‹|‚zdc\‚uttllƒ}ƒšŒtll{{t‹’Šœ¤¦ƒ„„’ŒŒŠƒ}f]csle‹„„uztŠƒ}ƒƒ|ƒƒ|rg]b[U{u{{u{lld{tt{tttts{||ƒƒ|„Š„„Š„ƒ}Š‹‹‹ƒƒ|“““ldd›”›{u{u{{””‹“““„Š„Œ”•tlllekŒ”•œ››””‹{{ƒ„Š„”“›{tt‘…„ƒƒ|š””‚v{Š}|ƒ||ztl{{tsleVTL[[Tzll””‹ŠŠ}¦§¨£œ¥‘}z“Œ”›¢›¦§¨ƒƒ|’ŒŒŠ}|’ŒŒredtsldc\‹‹„]bZldd¤¤ƒ„„{||”››ek]mtt“““|„…rfkzllultƒ}ƒ“Œ”‹„„kd\tslcbV„Š}edktll’ŒŒš””{ttuzt{{ƒd\\VTLbVUlrib[Uldddc\dc\„Š}ŠŠ}¨©´¨©´‚|uztl””‹“Œ”¤¤”“›ƒ„„{tt{{tf]ctsl{tt|‚zmttVTLdc\|„…{{ƒ{{ƒœ¤¦tt{ekdddcƒ„„{{t{||ƒƒ|d\\uztlldtlltllƒ||tllztlllkr]Zƒ}ƒŠ}ƒŠƒ}kk]{{t²²¬FD;74,¤¤“~ˆ’‘~‘ˆ}£››¦§¨š””£››£››¤¤£››¤¤¦§¨²¬µš””››”›”›œ››¦§¨£œ¥‹’Š£œ¥‹‹‹œ¤¦µ¶·””‹ƒ||‹‹„‚|u‹„„“““œ››{{t‹‹„›”›tsl‘ˆ}sre‹’Š‹‹„tts“Œ”‘ˆ}Œ‹“bVUddc™š¤Š}ƒlek„„Š‘Œ…‹‹‹|„…ƒ||””‹‚|u„„Šƒ„„››”™š¤””‹“Œ”‹„„{{ttsl£››ƒ}ƒ|‚z‚|u‹…’¢“‹‹‹[[Tj]\\[[tts‚|uƒƒ|¦§¨mtt“Œ”ult‹’ŠbVUŠƒ}VTLcbV[TTŠƒ}rfkekd\[[uzt‹‹‹j]\MRKultrg]sle{{t‹’Šƒ„„{tt{||’ŒŒtllƒ||tts‹„„ƒ||‹‹„|‚zj]\yle“Œ”“““‹„‹ƒ||Œ”•“““ƒ„„|‚z¨©´™š¤|„…llk”›››”›“““|‚z{u{””‹¦§¨d\\“““ƒƒ|ult{||ƒ„„|‚z…‹‹„Š„ƒ}ƒŠ}|‹‹„[TTƒ||‹‹„››”ƒ„„ztl{zmrg]d\\ekdztl‚wltslƒ}ƒŒ‹“ƒ||’ŒŒ‹‹„™‹†Šƒ}‚ut‹„‹™‹†Šƒ}”“›‚utdc\£››kk]¤¤„Š}””‹{{tƒ||ƒƒ|ultlekkk]{ttsleŠ}|yleƒ||[[Tek]tzltllultult‚utb[UŒ‹“lri\[[bVZ‚wld\\””‹sleultƒ„„ztl‹’Š’ŒŒ™š¤{u{ƒ}ƒ{zm‚uttll‘ˆ}¦§¨”“›™š¤„Š„ƒ„„‚|uƒƒ|tsl{{tMRK‹‹‹ƒ„„‹‹„{||{||lri{||””‹lddekd“Œ”d\\f]cddc‹‹„{tt‘…„‘ˆ}{ttcbV‹‹‹‚|u{{tšŒ‚|u‚|u‹’Š¦§¨VTL-1+””‹‹„„‘ˆ}’…‹£œ¥¦§¨›¢›£››œ››Šƒ}¢—£››£››²««£œ¥²««””‹£œ¥¦§¨¢—‹„‹ƒ„„uzt{{t››”µ¶·Œ”•‘ˆ}“Œ”Œ‹“”››“Œ”¦§¨„Š}‹‹‹‘Œ…llkdc\ƒ‚uztfsre’ŒŒrg]Œ‹“lddttsultƒ‚urfkŠ}ƒ{{t{ttƒ„„‘Œ…‹„„››”{||‹„„ƒ‚u¨©´š””{{ƒšŒ‹‹„tzllddultsleŠƒ}‹„‹Š}ƒttsVTLrfkf]c‚v{ƒƒ|lri“Œ”{||{||lld‚|u’ŒŒztlkd\ƒ„„ztl‚|u[TTdc\‚|utsltllbVZƒ||Š}|tslsre|‚z¦§¨ƒƒ|cbVkk]{||{tt›¢›{||tslƒ„„‹‹„¤¤‚|u“““ŒŒštts{||{ttuzt\[[ŒŒš›¢›‹’Šƒƒ|Œ”•lks™š¤£œ¥“Œ”ztl“Œ”“““‚|uekd‹„„{ttƒ||f]cŠ}ƒdc\{||lldmttrfkldd{ttŠ}ƒ‹‹„ƒƒ|zllŠ}|ztltllƒ||‹„„{{t{tt{{tƒƒ|“““‚|uš””kd\kk]™š¤™š¤tsl‰v|red””‹ƒ}ƒ‚|u””‹tll¦§¨ztlddclri|‚zŒŒš{||uztŠƒ}{ttzll“““‹‹„ztlddcllduzt{{ttll{ttŠ}|zllultldd{u{lldr]g{{ƒsleztl{{ƒuzt£››tsl‚|uœ¤¦™š¤{||‰|vƒƒ|¨©´²««{u{”“›“Œ”{u{{u{rfklri|‚zult‹’Š››”Œ”•“““ttsƒ}ƒVZ[ƒ„„‹„‹|‚zlritts{|||‚z]bZtslsleš””ztlŠ}|‰|vdc\llkŠ}|‚ut››”{tt|‚z¦§¨[[T*)(tll‚wl‘…„ƒ}ƒ’ŒŒ››”“Œ”›”›¦§¨£››£››£››“Œ”ü¿²««¦§¨£œ¥£››£œ¥”››£››Š}ƒŠŠ}š””‹’ŠŒ‹“Š}ƒª³·’…‹‹„„””‹ƒƒ|””‹ƒ„„{ttŠ}ƒztf„Š„””‹¤¤{zm“““ƒ‚uultb[UlldVTLrg]ultzlltsltllult£››””‹slef]cƒ}ƒ|‚z‹„„””‹œ››llkƒ„„‘…„{{t£œ¥ztlbVUŠ}ƒtll\UZJHF[TTtllllk[TTldd{u{f]c{tt{||sleulti\VVTLVTLkd\ztlekdcbVcbVƒ„„Œ‹“ttstlllddtll’ŒŒ‚ut‹’Š‹’ŠŠƒ}lddŠƒ}ƒ}ƒ‹„‹tts””‹š””šŒ‘Œ…ultƒ||{ttƒƒ|f]c{{t{{ƒŠƒ}{{ƒ|‚znv‚{u{‹‹‹‹’Š…„’›”›”“›„„ŠŒ‹“››”„Š„…‹‹ƒ||ult¨©´Œ”•{u{‹‹„ƒƒ|„Š}tts‹„‹ƒƒ|rg]{ttƒƒ|jcVSKJjcV{{tf]c£››{zmtslƒ„„tzltll\UZzllƒ||‘Œ…ŠŠ}ult‚v{‚|ušŒŠ}|‹‹„“““ƒ||ƒ}ƒ{||zllf]cdc\tsl{{ƒ‚|uƒƒ|[[T‹‹„Š}ƒ’…‹…‹‹{||Š}|ek]‰‘~|„…slef]cmttzlltllbVZSKJ{||ƒ||{{ƒ“Œ”{{t‹„„{||„Š„”š”›¢›‹„„\UZ‚v{{tt¨©´””‹‹„„””‹lek‚utztlƒ„„„„Š{ttŠƒ}VTLŠƒ}‹’Š„Š„‘…„{{t„„Šu{{ultult{ttŒ‹“„Š„“Œ”„Š„‹’Šuzt|‚zƒ}ƒ‘…„{ttb[U‚|utllyle{tt‚ut‰ƒvŠŠ}sre¦§¨D;9*)(Š}|š””“Œ”‰|v¦§¨ŠŠ}²¬µ¤¤²²¬£››””‹¤¤›”›¦§¨šŒšŒ“~ˆ£››œ››…‹‹sre‹‹„Šƒ}‘…„¦§¨›¢›šŒ”š”Š}ƒƒ||ƒƒ|‹‹„‹„„ƒ}ƒ”“›„Š„‹‹‹ƒƒ|z‚ltslŠƒ}‹„„””‹tt{‚v{‹‹„Šƒ}VTLultult‘Œ…‹„„”››“““›”›‹„„tt{“““ƒƒ|›¢›‹’Šf]c‹‹„{||‹‹„kd\ƒ}ƒsrebVUbVUult{u{\[[sleultlldƒ||b[U”“›“““Œ‹“ƒ„„tslbVUSKJFD;]bZSKJsrekd\[[Tlddd\\‹„„ztltzlƒ„„”š”ttskk]sle‚ut‚|u{tt™š¤”››œ››“Œ”‘…„¦§¨‚v‚ƒ„„£››‹„‹‹„‹ztl‹„‹Œ”•™š¤ƒ|||‚z|‚zlksf]ctt{fkklksUMRŒ”•‹‹„Š}ƒ”››tslœ››œ¤¦£››“Œ”{{ƒ‹‹‹”“›lldŒ”•›”›lekƒ‚uƒ||ƒ||lldsletslb[Uztfldd{tt‘Œ…Œ”•{{t{{tlldultcbV‚ut‚|u‚|ušŒ£››ultŠ}ƒj]\{tttts‰|vrg]tll{ttd\\„Š„uzt””‹{{tuztrg]bVZlddlddtts‚|u’…‹ƒ}ƒMRK|„…tslƒ„„rfk‚v{UMRbVZƒ„„‹‹„ƒ}ŠŠ}ƒƒƒ|{{ƒtll{tt„Š}œ››sre‹„„tts‹‹‹Œ‹““““Šƒ}f]cŠutŠ}|{{tš””™š¤“““dc\‹‹‹dc\ƒ}ƒƒ||ƒƒ|ƒƒ|„„Šddcf]cf]c‹‹‹{||“Œ”‘Œ…{{ƒŒ”•‚utƒ„„ŠŠ}‹‹‹zlltllredj]\‚|utslj]\redƒ||‹‹„ztl›¢›JHF*)(™š¤’‘~²««‚ut‹„‹£››²²¬£››””‹””‹£››Ã¼¿””‹“““ü¿””‹²««›”›‹‹‹”“››¢›£››¦§¨š””””‹¤¤tslšŒ‹‹„“““ƒ||ztl‘Œ…uztš””Œ‹“””‹“““ztl‚utkd\rfk””‹ldd‹‹‹‹„‹’ŒŒ‹‹‹’ŒŒ£››‚utJHFuzt{||””‹£››‹„„›”›””‹{||uztŒ‹“”››tzl£œ¥{{t{{ƒlrizllrg]{||lddlrijcVtts‚v{””‹ultf]cSKJ”“›tll{||Š}|{{t{tt[[TUTSVTLj]\llklddlkstts‚v‚š””Š}ƒƒ„„{||r]Zekdddc‹‹„””‹ƒ„„ƒƒ|‹„‹ƒ||ztl’…‹{||ƒ||Š}ƒj]\{tt™š¤llkuzt{{ƒ’ŒŒ„„Š|„…u{{{||{{ƒlksedk{u{”š”ƒ„„ŒŒštsl|‚z|‚ztts“Œ”¦§¨“Œ”lks{{tkd\lksttsedk{tt{u{{{tultllddc\redred‚ut{tt””‹tts¦§¨ƒ||ttstllkd\yfd””‹zll£››‚|uŒ‹“ultdc\d\\””‹‹„„‹„„{tt{u{Š}ƒ„Š„ldd{{ttts‹„‹”››‰v|lddllk{ttŠ}ƒ‹‹„‚|usre{||tsllddlek‚|uUMRultbVZtts[[T{u{ƒ||tslƒƒ|tllƒ„„“Œ”‹‹„’ŒŒ‹„„ultƒ„„ƒ||š””ultbVU™š¤{{t‹„‹Œ”•d\\[TT|„…tzlšŒ”š”fkkŠƒ}sre™š¤Œ‹“{||““““““lri‚|uldd…‹‹{||‹‹‹{||ƒ||Š}|{u{‚wl{zmtlld\\‚ut‚wl‰v|rg]rg]¤¤FD;74,””‹‘}z£››j]\’ŒŒ¤¤Ã¼¿£œ¥²««™‹†²¬µ‹„„£œ¥œ››””‹£››šŒ|‚z‹„„””‹‰ƒvŠƒ}””‹¤¤¦§¨µ¶·››”’ŒŒƒ||{{tsle””‹››”š””’ŒŒllk‹‹„{{t›¢›ƒƒ|ƒƒ|{tt‹‹„tt{{tttts{zmztlƒ||£œ¥tllƒ||‹„„”“›œ››‹’Šƒ}ƒƒ||‹‹‹’ŒŒ|‚zlddtts[[T‹‹‹{{tƒ„„tzlkd\{tt{u{[TTd\\[TT‹„‹ƒ}Š{tt{{tŒ‹“ddc™š¤ƒ„„[TTd\\ekdrg]kk]bVZllkldd[TTtzllritllš””‹‹„“Œ”[[Td\\b[U{{t{tt›¢›{{t‹‹„‹„‹ttsŠ}|Š}ƒƒ}ƒ‹„„ƒƒ|‹„„{u{‹’Šƒ||“Œ”ƒ„„u{{{{tƒ„„llkƒ„„tt{{{ƒ…‹‹|„…“Œ””››„Š„ƒ}ƒtts„Š„„Š}ƒƒ|ƒ„„‚v‚””‹tt{Š}|{u{tll{u{{u{ƒ}ƒƒ||›”›››”llkdc\red‘}zf]cƒ}ƒ’ŒŒ{||‹’Š‚ut{{tUTS‚|utllsre‹‹‹‘Œ…ylettsŠƒ}‘Œ…ƒƒ|yfd{{tƒ||sleyflƒ}ƒŒ‹“{{tŒ”•‚ut‹‹„ƒ}ƒ{{ƒƒ||‚v{{u{Šƒ}“Œ”‚v{„Š„‹‹‹VTL‚v‚{{ƒ””‹edktllf]c‹‹„[[T‹„‹››”slelddllk””‹››”{zm‹„„“Œ”””‹u{{¦§¨””‹ultztlrg]{zm{{t|„…„„Štll{{t|„…²««…‹‹]bZ‹‹‹…‹‹tt{”“›|‚zlek|„…Œ”•ŠŠ}ddclekd\\kd\llkddc{tt‹„„Š}|uztldd\UZf]cŠ}|‘Œ…‰ƒv‹„„””‹>B93+*ƒ||‘…„£››£››”“›µ¶·Ã¼¿š””””‹‘ˆ}¤¤¦§¨£››”“›²««š””ª³·Š}||‚z¤¤›¢›£››¦§¨‹‹„”“›””‹¦§¨¦§¨œ¤¦tt{ƒ‚u‹„„‰‘~’ŒŒ‘…„’ŒŒ‘Œ…‹‹‹››”””‹lld{ttkd\tts‘…„{ttlldj]\tll’ŒŒ£››ƒ„„‚v{f]c‹„„tsl{tt‹„„ƒ„„{ttrg]ddctllƒƒ|šŒ”“›ƒ„„”š”Š}|’ŒŒ›”›llkiWU]bZtlluztœ¤¦tsl{{t{||ultlekdc\Š}|JHF{||ƒƒ|ttsƒ„„rfktllJHF{||‹‹‹‚v{srellkddckd\b[Utslslekk]d\\{||ƒƒ|lekyleztl’…‹Šƒ}ddctts›”›„Š}Œ”•‹‹‹‹„„u{{uzt|‚zƒ„„Œ”•‹„‹œ¤¦…„’…‹’™š¤uztddc\[[|‚zƒƒ|„Š„‹„„ƒ}ƒ\[bf]clks“Œ”lddƒ||ƒ}ƒœ¤¦ƒ}ŠŒ‹“…‹‹œ¤¦“Œ”‘Œ…„Š}œ››ƒƒ|j]\‹‹‹lld””‹i\V{{tzllkd\ldd„Š}ƒƒ|i\Vƒ||llktlllld{||llkŠ}|b[UbVU‚utbVZ‹„‹{ttsre‹’Šttszllƒ}ƒult‹„‹ƒ||{ttŠŠ}lek{{tƒ}ƒ[[Tddcttstlledktll{{ƒƒƒ|¦§¨Œ‹“Š}ƒsrecbV{{tsre™š¤u{{kk]‘Œ…ƒ„„Œ”•£››£œ¥tll‰|vzll‚|uƒ||ƒ||ult{ttƒƒ|‹‹‹‹’Š„Š„‹’Šµ¶·{||{||Œ‹“Œ”•“““ƒ‚n{u{Šƒ}ultƒƒ|tsld\\rfk„Š„Š}|{zm‹„„tll{zmŠ}|zllyleztlkd\kd\””‹:97*)(ƒ„„‹„„Šƒ}¦§¨¤¤²¬µ£››£œ¥š””²¬µ ¦§¨¦§¨£œ¥£››’…‹šŒ›¢›ƒ‚uƒƒ|””‹››”””‹£››«²«¦§¨£››ƒ„„’ŒŒ‹‹„ƒ||’ŒŒztf{u{yfd‚ut”š”„„Š‹‹„£››{zm‹„„ƒ‚ulddšŒ‹‹‹tsl‚v{ƒ}ƒœ››Šƒ}…‹‹Š}ƒ’ŒŒllksle{{ƒ…‹‹„Š„ƒƒ|ƒ‚uldd„Š„ŠŠ}››”Œ”•‹‹„tzl‚|uddcƒ„„lriƒƒ|FD;d\\u{{]bZllkd\\rfklddlddsrezllSKJŠ}ƒtsl|‚zsleVTLtsldc\ƒƒ|lddsleVTLzll‹‹„lld’…‹››”rg]sre‹‹‹ldd‹„„ultd\\{u{ƒ||‹„„{ttŒ‹“‚|uztlƒ||‹„‹‹„‹mttllk|„…{{ƒœ¤¦|„……‹’ƒ}ƒŒ”•Œ‹“ƒ||œ¤¦ddcŒ‹“lriuzt‹‹„{ttlkslekUUY‹„‹ƒ}Šƒ||‹„‹‹„„kk]ldddc\‹’Šƒ}ƒ‹„„š””‘Œ…š””’…‹tllsrekd\bVZultlld‚v{bVZbVZœ››lddlriŠ~‹kd\‚v‚Šƒ}{{ƒƒƒ|Š}|f]c›”›lddultœ››ldd{||llkd\\kk]‹„„{u{‹‹„‚v{ƒ||ƒ||ƒƒ|{||tsl{u{‹‹‹VTL{zmbVUddctts„„Š™š¤lriztltllUTSš”””“›””‹››”ulttsl…‹‹š…Ž¦§¨Œ‹“‰|vttsrg]ƒ||tsl‚v‚ƒ||›¢›kd\[[T„„Š‹’Š¦§¨£››£››œ¤¦Œ”•“Œ”‹‹‹{{ƒ’ŒŒtllƒ„„ƒ„„ƒƒ|lekƒ||{tt‰|v‚utztfzllsle‹„„ƒ||kd\‚wl‹‹„¤¤:97*)(ldd‹„‹Šutš””œ›››”›š””£››‘ˆ}¢“‘ˆ}£››™š¤¦§¨£››µ¶·£››¦§¨{{tƒ‚u¦§¨””‹‘Œ…‚ut¤¤”š”œ››‚|uƒ||ƒ}Š¤¤””‹š””tts‚wl‚v{{{t“““‚|u‹‹„›¢›“Œ”‚|u‹„„’ŒŒ„Š„š””””‹“Œ”Š}|sle{||f]crfk“““{{tƒ||ƒ}ƒ«²«‹‹‹zll‘Œ…{||‹’Š¦§¨›¢›Œ”•d\\rg]redldd…‹‹ztlllkf]cŠ}ƒrfk[[Ttll‘ˆ}tt{j]\VTLkk]lldslettslridc\ƒ||tll„Š}dc\‹„‹tyg|„…ztllddj]\mtt{zm‚ut””‹{{t‹’Šš””ƒ||f]c‚v{tlllddd\\’ŒŒ‹„„ƒ}ƒŒ‹“ƒ„„›”›ƒ„„ƒ}ƒ„Š„ekdŒŒš|„……‹‹{{ƒtt{“““„„Š|‚z{u{””‹‹’Š‹‹‹„Š„tlllek{||Š~‹{{ƒ“Œ”‹„‹™š¤{{tllkleksle›¢›””‹|‚z‹„„sle‚|u{ttllklriredkk]VZTzllredbVZ[[T{{t{ttƒ}ƒultddc{ttƒƒ|””‹Šutredrfk‘…„{u{ƒ„„{{ƒ{||ŠŠ}lriztl]bZ\[[‚ut‘Œ…“Œ”VTLƒƒ|lld“Œ”lriddctsl{zm[[Tf]c„„Štsl{ttƒ}ƒš””””‹‹„„‚v{“Œ”„„Š£››‘…„lek{||bVZ‹„‹‘Œ…™š¤Šƒ}{u{ztl‹„„{{tš””kd\‹‹„uztuzt|‚zƒƒ|š””{{ƒ“Œ”|„…|‚z…‹‹œ››tt{‚ut{||{{t{zm‹„‹lldlldd\\sletll‚|u‘…„zllldd‘…„Š}|yleƒƒ|Šƒ}>B9&&‹‹‹£œ¥“Œ”‹‹‹›”››”›››”£œ¥¢“¦§¨Š~‹{tt“Œ”¦§¨£œ¥²««£›››¢›ŠŠ}‘Œ…š””ƒ‚u£››œ¤¦«²«{{tœ››ƒƒ|ƒ||¦§¨‚ut¤¤””‹’ŒŒrr]redtsl{u{tsl£œ¥ŠŠ}ztl¤¤Œ”•’ŒŒ‹’ŠŠ}|’ŒŒ{{tŠƒ}{{t{||‹‹„zllš””sle“““‹„„Œ”•ƒƒ|tllŠƒ}‹‹‹Šƒ}ultƒ„„{tttllsle’ŒŒultllksretts‹‹‹„„Škd\\[[tllf]c‹„‹sreztl‹„„d\\tts”š”‹„‹””‹tllŠƒ}{{tVTLUTS[[Tlldztlkd\b[U{||ŠŠ}kk]ekduztƒ||kd\lddlkszllƒ||“““{ttkd\‘Œ…‹’Šu{{“Œ”{{ƒ””‹ddcek]lks|„…”››…‹’mtt‹„‹Œ‹“|„…edkƒ}ƒ‹‹‹|„…ƒƒ|‹‹‹š””{u{„„Š““““Œ”ƒ}ƒ£œ¥ddc{||‘Œ…ƒ||“Œ”””‹“~ˆcbVkk]tllkd\“Œ”f]clrib[U‹‹‹ƒ||”››j]\ztf{||{u{{zmƒ||ldd{ttƒƒ|‹‹‹ƒ‚ud\\Š}ƒƒ||rfkŠƒ}‚|utslttsœ››‹’Š{||tslkk]ƒ}ƒ‚ut‹‹„{ttredsrej]\‹‹„ttsUTS”š”tts’ŒŒ{u{{||£œ¥“Œ”‹„„¤¤{tt›”›’ŒŒ””‹Š~‹ultŠ}|uzttts™š¤zll{||‚|u“~ˆ{zmztlƒƒ|£œ¥zll””‹srelriƒ}ƒ‹„„Œ”•¨©´¦§¨|‚zekd“““‹’Šekdslellkldd‚|u‚|uƒƒ|tzl“Œ”‚|u{zmƒƒ|‘Œ…{tt‘ˆ}‰|vredkk]i\V””‹D;9*)(››”œ¤¦””‹{{t“““œ››¦§¨“Œ”‰|v£œ¥””‹‘…„£››£œ¥£œ¥“Œ”£››|„…‹‹„ƒƒ|¦§¨š””Šƒ}ƒ„„ƒ‚u››”‹„„œ››‚|u‹„‹‚utztl‘ˆ}‹‹„„Š}yleb[U[[Tzllf]czllŠ~‹{ttult‹‹„””‹š””tsl{u{kd\{tt|‚zš””kd\”“›‹„„š””ƒ||Œ”•£œ¥zllƒƒ|›”›‹‹‹‹‹‹ƒ„„ultlldzll‰|vŠ}|sledkV‚v{dc\Œ”•dc\{ttƒ||ƒ}ƒ“““lridc\kk]mttSKJ‹’Š{{trfk“““FD;sre{{ttll{{t|„…[TTb[UsleŠƒ}b[U{{tsreƒ||tll{||‹’ŠtllŠ}ƒŠ~‹‚v{‹„‹ƒ||š”””š”‹‹„“““tt{lldultuztmtt{{ƒ{{ƒ{{ƒlrilksŒ”•‹’Š|‚zŒ‹“{u{‹’Šuztultƒ||ƒ}ƒœ¤¦ttsldd‹„„lks”“›{u{‹‹„Œ‹“{{t‹„„‰ƒvu{{{u{ƒƒ|Š}ƒ’…‹Œ”•‹’Šyle{||tsl{{ƒztlkd\d\\f]cuztŠƒ}tzl{||””‹›¢›œ¤¦””‹bVUrg]ƒ}ƒ‹‹„‰|v{tttslkd\ŠŠ}‹‹‹ƒƒ|ƒ||“Œ”{u{{ttrg]kd\[[Tlldtsl]bZult””‹››”{tt{{ƒ‹’Šsle›”›ztlztfš””ƒ„„š””””‹‹„„ztl‚utƒ}ƒ…‹‹ƒ||²²¬”“›‚|u“Œ”ztlsle“““Š}ƒ‹‹„lekœ››|‚z‚wlŠŠ}tll‹‹‹„Š}ek]{||™š¤„Š„{||‹‹„ƒ„„tsl‘Œ…ƒ||{||{ttƒ||JHFŠƒ}i\V‹„„ŠutztlŠ}|‹„„‚wlred²²¬FD;*)(„‰v““““““£››£››¦§¨£››£››šŒ‘…„²¬µ£››¤¤››”²««²¬µ²¬µ¦§¨ƒƒ|‘ˆ}‚ut¢—’ŒŒ’ŒŒ‹‹‹“~ˆ‚v‚”š”£››‹„„ldd£››››”“Œ”‹‹„{ttƒ‚ubVUš””{||tsltll{{t{||‹‹„„Š„‹‹„‹’ŠŒ‹“ult››”uztttsƒ‚u’ŒŒŠ}|{tt’ŒŒƒ„„{||‹‹„‚|u’ŒŒ„Š}”š”””‹lri‹‹‹Š}ƒsleldd›”›Šƒ}FD;{||ult|‚zƒ}ƒlri{ttttsllkekdu{{lldb[Ulri‚utUTStygtll„Š„sreuztŠƒ}„Š„ztlsre[TTaWM|‚zztl‹‹„rfklldƒ||ŠŠ}tllƒ}ƒ£››‹„‹tllš””ƒ|||‚zƒ„„‹„‹lks„„Šlrilek]cd|„…”“›|„……‹’lkstt{Œ”•Œ”•Œ‹“ƒ}ƒfkkllk{ttultlek“Œ”„„Šƒ„„sle£››{{ƒ“Œ”›”›£œ¥{{t{{t|‚z„Š}{u{‘Œ…ultrfktsltt{rg]lld‹‹‹‚utUTSzllyleslekk]{{t{||lddƒ„„ƒ„„““““““’ŒŒ‚utlekf]c{u{{u{r]gƒ||ƒ||{||ƒƒ|Šƒ}‹…’tllredtzlsleVTL|‚z{{ttllŒ”•‹‹„‹‹„ƒ„„ttsllk{tt‚v{œ››ƒ||””‹‹„„¦§¨‹„„£››£››¦§¨ƒ„„]bZ{{ƒ„‰v™š¤¤¤™š¤£››ulttslƒ||Šƒ}tsl{{t‹‹„Šƒ}ŠŠ}mttmtt“Œ”£››“““u{{‹’Š›”›””‹{{t‹‹‹lddlldtzlllk{ttj]\‹„„lddsleƒ||‚|uztlsletslrg]¦§¨JHF*)(’‘~{{t‘ˆ}²¬µ£œ¥²««¦§¨“““£››šŒ£››£œ¥¤¤‘…„²¬µ£››šŒ‹‹‹ŠŠ}‘Œ…‹‹„‚|uzll›”›››”£››Šƒ}‘Œ…‹‹„{{t™š¤‹‹„Šƒ}ƒ„„‰|v’…‹|‚zŠƒ}‹„„’ŒŒ„Š„{||srelri‹’Š‹’Š””‹„Š}„Š}ƒ}ƒ‚|u…‹‹‹‹„’ŒŒ‹‹„|‚z{{ƒŠƒ}{{t™š¤yfl””‹Šƒ}sle„„Š””‹llkŒ‹“””‹r]ZbVZ“““““““Œ”“““ƒ„„ƒ„„Œ”•llkred{ttddc[[Tlld‹‹„Šƒ}lldlldƒ||tzltll[[Tddc{||rg]dc\b[Usreslesleƒ‚nsreŠŠ}{{ttllƒƒ|lritzl””‹²¬µ‹„„zlltllƒ}ƒŒ”•tts{{ƒult„„Š]cd|‚z{{ƒ|„…Œ”•|„…u{{Œ”•…‹‹|„…mttlriultuzt{{ƒultf]clks\[bmtt›”›’ŒŒultŒŒš‹‹‹ƒ„„lddztldc\kk]‹‹‹{tt‚utƒ}ƒ‹„‹llkddcƒƒ|””‹Œ‹“sre{tt‚utzllztl{{ƒ{u{kd\d\\ƒ„„¦§¨‚ut{u{¤¤š””‚utred{tt{||ztltllkk]\[[¤¤lriŠƒ}ultŠƒ}uzt‚wl|‚zmttŒ”•Š}ƒtt{’…‹””‹£œ¥mtt]bZ„Š„Š}ƒttsŠƒ}‘…„‘Œ…š””sre™š¤””‹µ¶·tts{u{{||¦§¨œ¤¦š””››”“Œ”“““„Š„‹„‹””‹‚v{ztl››”[[T‹‹‹‹„„‹‹‹‘ˆ}z‚l”››ƒ„„…‹’‹„„„Š}lldttscbVlldttssrerg]sle{{t‚utztl‚|ui\V‘…„zllƒ‚utll””‹JHF!””‹”š”›”›œ››²²¬¦§¨²¬µ£››‘Œ…””‹š””‹„„£››’…‹Â¾Æ£œ¥£››“Œ”ƒ‚u£››œ¤¦’ŒŒŠƒ}£œ¥{{t‘ˆ}{tt{{t„„Š‹’Š””‹’ŒŒœ››””‹””‹’ŒŒttsztl””‹‚|uƒ„„{||‹„„™š¤ƒƒ|lldŠƒ}tsldc\dc\kk]tsl›¢›ƒƒ|‚ut£››ƒ||ƒƒ|„Š„‹„‹Šƒ}””‹zllllk‹„‹œ››{u{{tt‹„„b[Uš””ƒ}Š{{ttsl{{ƒ„„ŠlribVZlritlllriVZTUTStlluztf]c„Š}ƒ„„‹‹‹mtttslkd\ƒ||‹‹‹‰ƒvuztyle››”‹„„šŒ{zm{u{JHFƒ||‹‹„|„…ƒƒ|“““{zm“Œ”¦§¨œ››|„…”››„Š}„Š„{{ƒ“““|„…|„…‹‹„…‹’lkslksekd“Œ”}‡’™š¤|„…„„Š„†™‹„‹fkk„Š„dc\ult‹‹‹tt{ƒƒ|lddd\\tsl”“›{u{œ¤¦tts‚|uVTLƒ‚nƒ}ƒ‹‹„ult£››f]cult|‚z‘Œ…ƒ„„lks{{ƒƒ||ztl‚|u{{t„Š„lekttsldd”š”Œ”•{||‹„„‘Œ…lddrfkbVZdc\{{t››”””‹u{{tll{{t{ttƒƒ|ŠutŠ}||‚zŠ}|ƒ‚uŒ‹“{zmkd\u{{ztlrg]ƒ||llk›¢›ƒ‚uƒ}ƒ‘Œ…’ŒŒŠ}|ƒ||Šƒ}¤¤£››š””“Œ”{ttlri’…‹””‹‹„‹””‹{ttŠ}|²««“““‹‹‹‹„„Š}ƒ„Š„{||‘Œ…sre“Œ”{{t‹‹‹|‚z””‹{{tƒƒ|ƒƒ|sletslŠƒ}{{t{{tztl[[Tƒ‚u[TTsleultb[UztlŠƒ}ƒƒ|{ttŠŠ}‚v{ult>B9*)(””‹¦§¨””‹ƒ||‹‹‹²««²««£››¦§¨¦§¨”š”¦§¨¤¤›¢›¤¤¦§¨¦§¨¤¤””‹””‹”››¤¤‚v{‹‹‹‚v{zll‹„„tts’…‹“Œ”“““””‹£››“Œ”’‘~‹„„dc\lekyle‚v{’ŒŒ{{ƒ‹‹‹{{ƒldd{||’ŒŒ{{td\\[[Tuztllkƒ‚n””‹£››‘Œ…ƒ}ƒƒ‚uldd“Œ”œ››¢—sle|‚z£œ¥ƒ„„ztlƒ„„ƒ‚u‚|uƒ||tts|‚ztts‹‹‹œ¤¦{tt„Š„‹‹‹‚|uƒ„„{{t[[T””‹\[[ƒ||‹‹„ƒƒ|ldd‹‹„Š}|ttsƒ||ƒƒ|Š}|slesle””‹jcVƒ||kd\‹‹„tzlttsƒƒ|ƒ„„ƒ‚u£››‰|v’…‹“Œ”ƒ}ƒ‹’Š{tt{||‹‹„{{ƒ„Š„ƒ„„{{ƒ…‹‹ƒ}ƒŒ”•{{ƒtslmttmttŒ”•mttmttuztŒ‹“\[b\[[{||lddƒ„„lekultult’ŒŒ„„Š|„…rfkœ¤¦‹„„{ttlddƒ„„”š”œ››dc\ƒ}ƒ“Œ”tsllldttsldddc\[[Tlld‘Œ…‹„„lld{{t{{ƒ[[TbVUkd\tts„„Šldd‹’Šedkzll\UZd\\tll‹„„{||uzt””‹“““‹’Šlriultzll\UZ{{ttyg[TTMRK\[[llk\UZŒ‹“{ttult‹’Š¦§¨¦§¨‹„„‹‹„ƒ}ƒ‚wlkk]››”‘…„µ¶·’…‹™š¤‹…’ƒ||‹„„‹‹‹£››’ŒŒ’ŒŒ£››™š¤ttsztl‘Œ…‹’Šdc\{{tƒ‚ulld››”ƒ||tzl|‚zŒ”•{zmkd\ƒƒ|lriiq]lldtllsrebVU{zmztl‹‹„ztlŠƒ}‚|u””‹tllyleŠƒ}“““”š”D;9*)(‘Œ…‹‹„£››’ŒŒ›”›“Œ”²««£››£››‘Œ…”“›ŠŠ}‚wl¦§¨µ¶·£››£››ƒƒ|«²«””‹‹‹„‚wlƒ||””‹kd\„Š„{{t{||{tt{{t£››¤¤ƒ‚u„Š„››”{||{{trfkrg]ƒ}ƒ””‹Š}ƒ{{t{u{‹’Š‹’Š‚wlƒƒ|{tt{u{„Š„d\\ƒƒ|¤¤š””˜Ž£µ¶·’ŒŒƒ‚u‹’Šztlƒ‚uƒƒ|ƒ„„ztlƒƒ|SKJttssle“Œ”Šƒ}bVU[[Tultllkult„„Šlksƒƒ|ƒ„„llk‚|u[[Td\\tts|„…ƒ‚u{{t‚|u‚|u“Œ”„Š„‹‹‹‹’Š‚|u{{tf]c””‹’ŒŒ‘…„sleƒ||{{tsleztl””‹lld‚v{ztl“Œ”””‹tsl”š”tll‹‹‹™š¤edklld{{ƒ{{ƒ|‚z…„’›¢›tt{…„’|„…mtt{{ƒmttu{{{||‹„‹{{ƒllduztd\\\UZlks[[Tf]clld{u{llkŒŒš{{tldd››”cbV”š”‹„„ultlddultƒ||ƒ}ƒdc\{{t{tt[TTUMR{ttb[UmwVTLrfk{u{VTLSKJ{tt{{t‚v{‚v‚red„Š„ldd[TTtsldc\|„…‹‹„„Š„””‹šŒƒ„„‚utsle‘}z„Š}ekdllkllk„„Šldd{||’ŒŒ£››ƒ„„{{ƒuzt””‹‹‹„Šƒ}sre‹„‹Š}ƒ²««²²¬£››£››‰|vlekllk’ŒŒ‹‹‹‹‹‹‹‹„Š}|zll‹„‹ƒ}ƒ’ŒŒ‹„„ƒ||‹„„ttsƒƒ|£››Œ”•›¢›{{t„Š}„Š„|„…ztl‹„‹b[Uƒƒ|{tt‘Œ…{||{{tlddtts‹‹‹‚|u‚utztlƒ||’ŒŒ‚ut””‹ƒ||‚wlŠƒ}:97*)(››”¤¤²««£œ¥µ¶·š””””‹‘Œ…š””µ¶·µ¶·š””«²«²²¬£››¦§¨¢“ƒƒ||‚zƒ‚u‹‹„¦§¨£›››”›‹‹„tll””‹‹‹„œ¤¦{||¢“’ŒŒ¤¤tts‹‹„ƒ||‘Œ…f]cultttssleb[U’ŒŒ‚v‚ƒ‚u‹’Š“Œ”››”]bZ[TT|‚zddcb[U|‚z›”›‚|u‹„„‹„‹ƒƒ|tslŠƒ}kd\{zm‹‹‹‚v{ª³·ƒ||llk’ŒŒ›”›lddsleŠƒ}‹„„›¢›ult”“››”›ttsb[Uƒ}ƒcbV„Š}‘Œ…Œ”•ƒ||‹‹„tlli\VVTLSKJkd\‹‹‹tll{{t‚|uyletll‚|u‘ˆ}‚|u‹„„tslsle{||b[U’…‹””‹{tt‘…„‹„„tsltsldc\{u{{ttlks‹‹„{{ƒ{||uzt{{ƒ›¢›mtt„„Š|„…Œ—£mtt|‚z|„…|‚z›”›|„…{||llk{ttlek{||{{ƒd\\bVZbVZ{u{£››|‚zƒ}ƒ””‹‚|uƒ„„ƒ„„z‚lult‹‹‹‹‹‹tlluztdc\redUTSztf›”›kk]SKJƒƒ|‹„‹lekkd\f]ctllVTLmttd\\tslƒƒ|”“›ƒƒ|‚|u\[[””‹“Œ”‹’Š“““£››‹‹‹kd\{||‹„„{tt‹„„sle‹„‹ƒ}ƒldd„„Š{{ƒ‚v{ƒ}ŠlksmtttllsleultztlultUMRldd””‹’…‹“““‚utllkuzt™š¤tts“Œ”£œ¥’ŒŒ¤¤£œ¥ƒ„„‹„‹šŒzllsre‹‹‹ƒƒ|››”””‹Šƒ}‚|uŠƒ}„Š„ŠŠ}“““lddztfsre‘Œ…ƒƒ|ƒƒ|]bZredƒ||ƒ‚u{{t‹„„‹„„‚wlztlztlšŒƒ||tsl‚wlJHF*)(£››¦§¨ÃÄƵ¶·¦§¨‹„„£››šŒ‘…„£››²²¬¸Á¹””‹µ¶·£œ¥š””Šƒ}¦§¨””‹ƒ‚u‹‹„‰|v“Œ”“““›”›£››’ŒŒ‚|uƒ}ƒ›”›‹„„yleŠŠ}ƒ„„’ŒŒ“““’…‹“Œ”£››„Š„ƒƒ|‚|uuzt‹„‹’ŒŒ””‹””‹››”mtt{{td\\ƒƒ|‚|uŒ‹“£››Šƒ}{zm‚|u‹‹‹ƒƒ|‚|uŠƒ}ƒƒ|„„Š”š”{||f]csresre‘Œ…Š}ƒultllksle{||ultultuztlldd\\{u{VTL]bZ{{tsre“Œ”‘Œ…{zmƒ}ƒJHFSKJdc\dc\‚|uztf[[Ttllkd\‚|u””‹ƒ||Šƒ}Šƒ}lldkd\ztlj]\‹„‹‘…„{tt‘Œ…tsl{{t{ttttstllddclddlekmttu{{mttœ¤¦|„…tt{{{ƒŒŒš{{ƒttslks“““²¬µtt{Œ”•|„…”“›Š}ƒ‹…’“Œ”ƒ||ttsf]cƒ}ƒbVZylelri¤¤|‚zsre{||kk]’ŒŒ{||‚|uldd„Š„|‚zkd\rg]‘Œ…œ¤¦‰|vsreztl‹„‹rfkƒƒ|Šƒ}‹„‹rfk“““ztlkk]b[U‚|uƒ}ƒzlltlltllf]c”š”{{t‹‹‹„„Šrfkrg]rfk””‹uzt|‚z„Š}{u{leklektlllekƒ||ttsmtt£››‹’Š‚utŠ}|‚v‚zll’ŒŒƒ‚nllkŠ}|‹„„‹„‹ult™š¤f]c‹‹„””‹Š}|‘Œ…‹„‹lddšŒ‹‹‹£››tsl{u{‹’ŠŠƒ}””‹‹‹„Šƒ}tll„Š„{||Šƒ}‹„‹¤¤‚wlŠƒ}{{t[[Tdc\tll””‹tslŠƒ}‚|uƒ||‚|u‘ˆ}{tt“~ˆ’ŒŒ‹„„ztlD;9*)(£›››¢›²¬µ¦§¨²««¦§¨²««²««£››’…‹µ¶·²²¬‹’Š””‹››”£œ¥šŒ‹’Š¤¤«²«››”ƒ‚u£››‹‹‹‚ut››”‹„„‹’ŠŠŠ}lld’ŒŒ’ŒŒ¦§¨‚wl{tt{u{zll’ŒŒ{{t‹’ŠttsŠ}ƒMRK‹‹‹sre|‚zŠ}ƒ‚|udc\‹‹‹¦§¨‹‹„››”‹’Šƒ||{{tlriƒ‚u‹’Š‹’Š‚utŠŠ}‚|utsl‹‹„››”Š}|“““ƒ||zllƒ||ƒ||ztld\\ddcsre„Š„\UZ{{tƒƒ|Š}|‹‹‹ƒ‚u{{t‘Œ…””‹‹‹„dc\j]\f]cVTLsleƒ„„lddttsuztŠƒ}ŠŠ}b[Utll‰|vyleztlkd\kd\‚wlf]ctsl‘Œ…Šƒ}Šƒ}d\\ƒ||Š}ƒƒ„„{ttllk“““ƒ„„„„Štts{{ƒn…{{ƒƒ„„mttŒ”•lkslksultlek„„Š™š¤|„…mtt’ŒŒtt{ult]cd‚v{bVZ{tttt{tsllld{{tz‚l{{t‹‹„ƒ‚utsl’…‹f]cj]\llk{{tŒ”•””‹{{t‚ut{{t‹„„‘Œ…ƒ‚u{{tlek{zm‚|urfklks…‹‹„Š„ƒ||kd\Šƒ}ƒƒ|SKJf]ccbVƒ||sre›¢›lddƒ}ƒƒ„„slesletsl‘Œ…‚|uzllttsult””‹‹…’“““lriekd”››œ››|„…„„Š{tt“Œ”ƒ||£››¤¤‹‹„š””{tt{||{ttƒ„„rfkƒ||‹„„Š}ƒ{u{Šƒ}‹„‹tll‚|ud\\‚|u[[Ttsl‚|usrekd\lldŠƒ}œ››‹’Š››”lldrg]ƒ‚u‹‹„‹’Š‹’Šƒƒ|‚v{””‹kd\ƒ||r]Zš””sle‚|uredredVTLcbV£››FD;*)(¢—¦§¨£œ¥’ŒŒš””šŒ£œ¥¼À¯µ¶·¦§¨¦§¨¦§¨¤¤²²¬‰|v£››¦§¨››”›¢›{zm{{t‘ˆ}Šƒ}››”{{tƒ‚u‹„„‚|u{u{¦§¨£œ¥››”‹’Šƒ||‹„„{{taWM’ŒŒœ››llkƒƒ|ƒ„„{{t‹„„”š”‹‹„redllk{||„„Š‹’Š‚ut¦§¨›¢›{ttŠƒ}tzlSKJJHFVTLš””{tt››”{zm””‹‹‹‹b[U|„…£››ult{tt‚utldd[TT””‹ult{ttd\\slej]\kd\|‚zƒ‚udc\slelddkd\f]ctslb[UJHFƒƒ|tts{u{””‹dc\{tt‚|u‘ˆ}llk‰ƒv‹„„‹‹„””‹ttsƒƒ|lddƒ„„””‹tts{{ttslcbV‹„‹””‹ƒ||{{tƒ}ƒtts…‹‹…‹‹lks|„…|„…{{ƒ{{ƒŒ”•VZ[]bZfkklksleklkslrimttƒƒ|\[[\UZUUY{ttldd{u{‹‹‹›”›„Š„{{t””‹cbV‘…„‹’Š[[Ttllultldd{||sretsl‹‹„tts‹„‹{zmkk]lldƒ}ƒƒ||{||ƒ‚ušŒd\\‹„„tll|‚z‚v{kd\b[Utzlu{{tsl|‚ztslƒ||‹‹„tll„Š}{{tkd\‰|vVTLlldslelri{tt{u{ƒ„„‹‹‹lksmtttt{|‚z¨©´œ¤¦”š”ƒƒ|›¢›Šƒ}ƒ||{||tsl{tt‘Œ…›”›ultƒ}ƒ{||uzt“Œ”kd\ƒ||Š}|Šƒ}‹‹‹bVU{ttd\\ttstslƒ‚uuzttslƒƒ|{||{{tuztf]cult{zmzll‘Œ…””‹uztŠƒ}ztl””‹rg]d\\j]\tllrg]rg]Š}|ƒ||{{tztl¦§¨UTS*)(¤¤¤¤£››šŒ“Œ”¦§¨²««¤¤¦§¨¤¤¤¤¸Á¹””‹›¢›šŒ²¬µ™š¤””‹›¢›‘ˆ}‚|u{ttrfk{{tœ››’ŒŒ£››ztl‹‹‹‘Œ…“Œ”tll{{t‹„„‹‹‹{||rg]{{t{||zll|‚zƒ||ƒ„„tts{||š””‹„„{{t\[[llk‚|u”“›š””””‹›”››”›ƒ„„Š}||‚ztyg‚v{ttsj]\“Œ”¦§¨‘Œ…Š}|Œ‹“‚|u{u{bVUztlŠƒ}VTL]bZldd„„Šllk\[[UMRtll[[Ttsl{||›”›dc\{zmlrij]\tll{zmtsltlldc\{{tztlŠ}ƒ{ttkd\VTLlldbVUb[U{{tŠ}|Šƒ}rfkŠ}ƒƒƒ|‹„„”š”‹„„››”‹„‹ƒ„„VTLsre{{ƒ|„…tt{Œ‹“|„…Œ”•„Š„{{ƒllk…‹’nv‚{||mttd\\{{ƒfkk|„…ttsf]cUTSlks\[[bVZƒ}ƒ‚v‚‚|u’…‹”š”Šƒ}‰‘~sreƒƒ|llk{{tttsllkd\\ztllri[[Tƒƒ||‚z‹„‹„Š„„Š}sreŠ}ƒƒ}ƒƒ„„dc\tllf]c{ttŠ}ƒƒƒ|tts‹„‹{{ƒ{u{„Š„”“›sle{{t|‚zŠƒ}{{t{{ƒ{{t[TTtllVZT[[Tƒ||{||ƒƒ|bVU{u{llk‹„‹…‹‹”››‹’Š‹‹‹œ››¦§¨|‚zu{{ƒ||£››’ŒŒ‹‹„¦§¨{||\UZ{{ƒlri‹„„”š”zll””‹zll¦§¨““““““sle‹‹„“Œ”tts››”{tt‹‹‹‹‹„‰ƒv|‚z{{tlddj]\ztl{zmslesleƒƒ|ƒ}ƒ‹„„’ŒŒztltsl{ttSKJlldek]‰ƒvƒ||sle‚utsle²««SKJ*)(‘ˆ}“Œ”²««›”›ÃÄƨ©´£››™‹†””‹””‹””‹›¢›¤¤””‹£œ¥¦§¨”››‹‹„Šƒ}{zm{zmtllŠ}ƒƒ||ƒƒ|›”›„Š„‹‹„tll‹‹„‹„„Œ”•’ŒŒ“““{u{„„Šlld[TTlrisleƒ„„‹‹„‹‹„Š}|{{t¤¤¦§¨|‚z‹‹‹’…‹ek]{tt››”‹‹„ƒ}ƒ‚|u„„Š‹„„sle{{tldd‘Œ…¦§¨¦§¨£››zllš””‹‹„{tt‹„„ƒ||{ttkd\{u{{{tttsttsƒ}ƒlldSKJ]bZuztkd\tslŠ}ƒ{{ttllVTLd\\[TTD;9{{tlld‚v{sre{||‹„‹kd\ztldkVkd\‹„„ƒƒ|b[U{{t””‹ƒ}ƒ‹’Š””‹¦§¨‹„„ztlƒƒ|’ŒŒ{{tlrisle‹‹‹ƒ„„Œ”•œ¤¦lksmttmtt{{ƒVZ[{{ƒ…‹‹fkkmtt…‹‹{u{ulttsllksƒ„„d\\d\\„„Š£››“Œ”š””llkƒ„„¤¤‚|u””‹kk]sreuztttskd\tt{\[[lldredztl{{t””‹Š}ƒllksle‚|utll“““‹„‹\UZƒ||’…‹ult{u{{tt{||dc\jcVtslult{{t’ŒŒ‚|u{zm{{ttts{tt{u{j]\d\\edkekdƒƒ|{{ƒ{||tts{{ƒ˜Ž£Œ‹“ŠŠ}u{{…‹‹‹‹„{{tš””‹’ŠŒ‹“tts››”‹‹„””‹“Œ”‹‹„ƒ„„ƒ}ƒ“““uztƒƒ|{tt¦§¨£››‚v{ƒƒ|{||›”›{{tŠŠ}ttslld‹„„ttsult››”{{t…‹‹›¢›Šƒ}lridc\b[UcbVƒƒ|‘Œ…llkkk]‚|utsl{tt‚ut‹„„ztlrg]ddcƒ„„ƒ||red¤¤D;9:97£››£››¦§¨²¬µ¤¤¦§¨£œ¥””‹¤¤’ŒŒµ¶·¤¤¦§¨«²«¦§¨“Œ”£››”š”””‹‚wlŠƒ}ƒ||“Œ”“““„Š}¦§¨ƒ}ƒ’ŒŒ{tt¤¤ƒ||²««ƒ||ƒ„„{ttŒ”•‹„„‚|uuzt‹’Š””‹rg]llktts{zmš””ultb[U\[[‹‹‹[TT{||kd\{||{ttsled\\ƒƒ|‹‹‹‹‹„œ››””‹£››ƒ„„‚|u‘Œ…‚v{tsl”š”j]\‹’Šdc\sled\\ƒ||kd\lek{{ƒddcldd\[[dc\[[Td\\“Œ”f]cslesle{ttb[U[TT]bZrfkldd‚utƒƒ|bVZj]\ztlztlŠ}|kd\|‚z{zm‹‹„“““ztf|‚zŠŠ}„Š„ŠŠ}rfktsl{||’ŒŒ|‚zkd\tt{‹‹‹{{ƒlri‹„‹{ttlri\[[|„…„„Š”››…‹‹mtt…‹‹{{ƒ…‹‹]cd\[bttsf]c{u{lks{{ƒf]cddc\UZ{||ƒƒ|lld{{tƒƒ|kk]kk]{{tlri„„Šldd{{ttllddcult]bZŠ~‹uzt{{tb[Uƒ}ƒf]cf]c{ttj]\’ŒŒ{tt‹„‹sresle‚|u‹‹‹lddult{{tttsƒƒ|››”‚|u‹„‹‹’Š{||‚|u|‚zult„Š„UTS{ttttsttsf]c{{ƒ{u{’ŒŒ„Š„„Š„ztl”š”‹„‹„Š}Œ”•‚ut{{ƒ{||’ŒŒ’ŒŒƒ}ƒ‹„„ƒ„„{||…‹‹lrizllŠƒ}‘Œ…”“›””‹‹„„ƒ‚u‹‹„ƒ‚u{||‚|uuztttsƒ||{{ttsluzt‹‹„ƒ||“““‹‹„ƒƒ|sre{{t‚wl{{ttslztf‹‹‹kd\ztlŠ}|sre’ŒŒƒ||{{ttsl{||¦§¨FD;*)(‰ƒv£œ¥¦§¨””‹£œ¥²¬µ¦§¨šŒ››”¤¤¤¤””‹””‹””‹“““µ¶·£œ¥‹’Š‰ƒvƒ‚uƒ||redredƒ‚u””‹‹‹‹{u{œ››ƒ„„””‹ƒ||‹„„Š}ƒ‹’Šƒ„„{ttztlŠƒ}{||Šƒ}””‹š””””‹œ¤¦lld{{tred[TTldd{ttslelekrg]sledc\tslƒ||“Œ”ƒƒ|‹‹‹š””‘Œ…””‹ƒ}ƒ‘…„‹„„tll‚v{[[Td\\ƒ„„‚|uztltll{||”“›ƒ}Š”“›uztf]c]bZlddb[Ulddd\\{u{{{t‚ut‹„„ƒ‚uldd„‰vredVTLkk]lddbVZ‚|uslelddŠ}|ldd{ttllkƒƒ|‚|u‚|u{{tŠƒ}{||sle‚utztl’ŒŒƒ||lriƒ„„|„…{{ƒŒŒš{{ƒtt{]cdult{{ƒmtt{{ƒ|„…tt{edkf]clksllkekdmtt{{t‹„‹ƒ„„lks{u{lek\[[d\\ek]lldllkkd\ƒƒ|‹„„tslsreldd\[[d\\sleƒ}ƒllkŒ‹“tsl‹„‹“““‹‹„sleŒ‹“ddclddtt{‚ut‚v{{ttultldd‚|u‘Œ…‹‹‹VTLkd\UTSƒ‚uœ¤¦ƒƒ|Šƒ}{tt{||uzt‘…„ldd…‹‹]bZtsllksœ››{{ƒ{u{lksult[[Tlektsl””‹œ¤¦‹’Šllkuzt|‚z‹‹„‹’Štzl“Œ”Š}ƒ¦§¨lekŠƒ}|‚zlld{u{ƒƒ|ƒƒ|’ŒŒ‹‹‹‹‹‹ƒ„„b[USKJd\\mwFD;[TTllkƒƒ|ttsƒ‚udc\{tt››”{zmŒ”•ek]llkcbV[[TŠƒ}{{t]bZtllsre{ttjcVyle‹„„’…‹Šƒ}sle£››SKJ*)(Šƒ}œ¤¦£œ¥“““£›››”››”›¤¤£œ¥µ¶·“Œ”ƒƒ|„Š}«²«ƒ„„”“›‹’Š””‹””‹‹‹„””‹ƒ„„{ttlld„Š„‹’Š{ttlldƒ||‹‹„š””Šƒ}|‚z’ŒŒ›”›{||“Œ”{{t‹‹‹„Š„‘Œ…“Œ”ƒ„„|‚z{{ttts{||‹„„ƒ„„ult‚|uŠ}ƒ‰|v{zmtyg’…‹rfk‘…„{{t„Š}ƒƒ|{tt›”›tsl’ŒŒƒ||zllƒ||ztlƒ}ƒ{ttldd[TTƒ}ƒ„Š„{{tddc{||tsltlltsl{u{ek]lektllrfkztl{ttlddkk]kd\ddcf]ckd\b[Uekdd\\zllaWMMRKƒ||{||‹‹„lri{ttj]\{zmŠŠ}{yf|‚zkk]ŠŠ}{tt”“›””‹‹„„‹‹‹¦§¨ƒ}ƒ‹…’uztddc|„…|‚zlksmtt…‹’uztllkmttf]c\[bultekdlksultƒ||iq]b[U{u{ƒ}ƒ{u{\[[ldd{{t{{t[TT{{tlldtsl{zmlldƒ}ƒdc\sleddcd\\aWMlriƒ„„ƒƒ|{{tVTLlldtllr]gtt{Š}ƒ‘…„lddd\\tsl‚utddcztlddcb[U{||[[Tlld‹„„”››{{t]bZƒƒ|ƒ||u{{”››{||””‹““““Œ”™š¤\UZ\UZSKJkd\ekdtll{tt|‚zf]c{||lksfkktslttsb[Uf]c{||‚v{{u{{ttllktsltllaWM|‚z{tt{||ztl{tt’ŒŒj]\tsl‹‹„ƒ||dc\dc\lri{zm{{ƒ[[Tredƒ„„””‹‚|uƒƒ|ƒƒ|lldtslsre{zmtsltllcbV{ttkd\ztl{{t{ttmttldd™…D;9:97ƒƒ|š””¨©´›”›‘Œ…²««£œ¥¦§¨µ¶·‹„„šŒ””‹ƒƒ|¤¤œ››¦§¨uzt›¢››¢›‘Œ…’…‹‘Œ…{tt’ŒŒ‚v{ƒƒ|{u{””‹™š¤‹‹„™š¤‹‹„‚|uƒ„„‹‹‹“““{zm„Š„”š”|‚zƒ||{ttultlri|‚zƒƒ|¦§¨|‚zŠƒ}‘Œ…ƒƒ|ƒƒ|{zmtsldc\red{{tƒ||{||„Š„|„…sle‹„‹red{u{{ttredlldslelddlekj]\dc\SKJslelritslƒ„„b[U{||ddcƒ„„uzt{{t{{tldd{{t[TT{tt{zmSKJ|„…‚utsle{{ttll{ttztl‰ƒv[TTsle“““lrilld{ttj]\Š}|kd\tslllkztlbVZttsƒ}ƒ‹‹„{{tdc\lkslksddc{{ƒ{{ƒƒ„„llkmttƒ„„u{{ddc\[[UUYUMR{{ƒ{{ƒuztmttlddlek‹‹„dc\ddclekllkultŠŠ}lrilddlriƒ‚u””‹{ttd\\lek{{t{||ztlldd|‚zƒ„„kk]VTL{u{j]\b[U\[bd\\[TT‚|ub[Ured{||[TTllkVTLb[Uredb[Uj]\]cd{||ƒ„„j]\tlltts”››ekd{u{{||{ttVTLlri{u{ƒ||…„’tllŒ”•{||tllkd\‹’Š{||“““]cd|‚zdc\lksƒ||ddcbVUSKJztlVTL[TTlrittscbV{||sletygtts|‚zrg]‹‹‹ƒ||ƒ||{u{lddztllriƒ„„Šƒ}|‚z„Š}dc\ldd[[T|‚zttskd\[[Td\\tslb[Utzl[[T[TTkd\{||„Š}redƒƒ|ƒ||tslj]\£››SKJ*)(‹‹„””‹£œ¥£›››”›£œ¥›”›””‹”››’ŒŒ›”›¤¤››”›¢›ƒ„„‹‹„”››””‹ultŠƒ}{tt‹„‹‚|u””‹‹‹„ztlƒ||‹„‹Œ‹“{zmƒƒ|‚wl“Œ”ƒ}ƒ{{tlksŠŠ}{{t{|||‚zztlsredc\„„Šsre“““ŒŒš{ttšŒ’ŒŒŠƒ}ƒƒ|‚utŠƒ}{{tzllekd’ŒŒttslddllktll{||kk]{{t‚|uultult‹‹‹“Œ”tll\[b]bZbVU[TTtslf]c{||tsltlltllƒ}ƒlldkk]tlld\\kd\j]\ƒƒ|ƒ‚uFD;tll{ttsleVTLb[UlddVTLztlƒ||tts“Œ”ultkd\cbVdc\{zmƒ‚usletts„Š}tll‹„‹…‹‹“““‹‹„[[T]cdslelks{{ƒ{{ƒedkddc{||u{{mtt\UZ\[bJHFVZ[lkstt{ddc„„Šlksƒ}Šlks[[Td\\lekllkf]ctts“““‹‹„‘ˆ}VTLtslttsbVZ[[T[TTzllkk]ƒ||mttz‚ldc\lks‹’Šƒ||VTL\UZSKJd\\lekkd\zlllddlldddcSKJVTL[TTtslƒ}ƒ\[[dc\tslVTLVTLŒ‹“lrildd\UZlldd\\{u{llkllk{tt„„Štts„„ŠtllbVZlkslridc\uztŒ”•mttƒ}ƒlektlluztlekj]\b[Uu{{d\\{tttts[TTVTLtslVTLkk]ddc‚|uddcŠƒ}{{t’ŒŒŠƒ}tllƒ||ekdƒƒ|[TTdc\lld‚|uultttsf]cƒ„„{||kk]sre‹‹‹dc\kd\lddztlddcb[U‚utlld{ttƒ||sle£››JHF*)(Šƒ}‚|u“““š””¨©´“Œ”“Œ”’ŒŒ¦§¨£››²««”››“““›¢›Œ”•ƒ‚uŒ‹“„Š„ƒ„„ƒƒ|…‹‹‹„„{tttsl{{ƒ””‹››”tt{‹‹‹””‹{ttsle‹‹„Œ‹“tsl{{tzllztl‹‹„llk‘Œ…ƒ||UTSkk]dc\ekd{ttlddtslulttsltslkd\|‚z|‚zkk]{||d\\{||lddlri‚|uttsŠƒ}ttsSKJddctllƒ„„Œ‹“ult[[TVTLSKJllkJHFSKJ\UZdc\ldd‹„‹|„…tsllldtslb[UUTS[TT]bZVTLj]\b[UVTL{tttslVTLzllztlztfldd{u{lrilddJHFb[UVTLkd\redtslttsƒ||{ttllk{{ƒtsllldUTSttsekd{{ƒ]cdf]cllkƒ„„tts{{ƒ…„’\[bfkkVZ[ƒ}Šu{{lksddc|„…{u{“Œ”ŒŒš{tttlledkuztlek‚utuzttsltslVTLtt{\[[d\\[TTekdj]\{{tlddkk]„Š„tzl[TT\[[d\\b[Umttllkllkldddc\\UZlekbVZlldtllzllŠ}ƒtslj]\[[Tdc\lldttslldllkuztkd\edk\UZVTLb[UJHFf]cUTS…‹‹u{{Œ‹“ddcb[Ukd\…„’UTSlriuzt]bZttslddMRK„Š„„„Š{ttUMR[TT{tt„„Šllk[[TlddcbV\[[{ttlldj]\[[Ttslsreƒ||kd\ddcb[Uddctll]bZkd\ƒƒ|lldtlltslƒ||{||ultŠƒ}d\\dc\ztldc\kd\tsl{u{sle‰|vsleddc{{tlld²««[TTD;9ztl’…‹¤¤‘Œ…‘Œ…ƒ||“““‹‹‹{||››””“›…‹‹…‹‹Œ”•„Š„“““ƒƒ|„Š„{{t|‚zllk‹„„””‹|‚zƒƒ|tts{||llkd\\kd\{u{’ŒŒƒ}ƒ‹„„lrilldlldztlkk]lldtsl””‹tslu{{sleedk[[TVTLrfkf]credkd\kd\]cd|‚zsleƒ}ƒlldtts{||ekdf]ctlllld|‚zslelld‹„„tts{tt{||tllcbVzll[TTdc\d\\{u{]bZbVU{tt\[[VTL[[Tkd\\[bb[U[TTtllslekd\|‚z[TT‚utztl\[[b[Usletsl{||tts[TT[TTlld|‚z‘Œ…d\\tsl{{t{{t{||lldtllttsd\\[[Td\\{{ƒlrif]cfkklkslks|‚z{||mtttt{VZ[LKRVZ[mttmtt]cd\[[\[bd\\d\\lddlekmttedk\[[r]guztekdekdd\\lridc\{{t[TTlldd\\FD;[TTd\\kd\tslUTSlld\[[[TTkk]f]cj]\f]cf]c[TTtllf]cbVZUTSllkkd\ttslksllkd\\SKJmttUTSUMRd\\tllSKJ[TT\[br]gf]cUMRUTSztlddcslelkszlltll\UZtllVTL{||llddc\lldtt{VZTtt{„Š}‹„‹ultd\\d\\tt{mttekdlkssleVTLkd\{{tdc\dc\{{tldd[TTztl\[[dc\d\\b[Uddcd\\f]cb[UcbVlldlld{{ttslcbV[TTztlVTLkd\dc\lldtllb[Urg][TTUTSredkd\””‹[TT:97{||››”’ŒŒ²²¬“Œ”“““ƒ„„Š}|”››“““ttsllk„Š„ƒƒ|tt{mttƒƒ|…‹‹‹„„ŠŠ}{{ƒ{u{ztl‹„‹‹„„tts{u{{u{ƒ„„llk{{ƒƒ}ƒ{tt{ttkd\kd\dc\{u{tsldc\slelldƒƒ|{{ƒ{||{||ƒƒ|tllttstlldc\{ttkd\{||…‹‹{u{|‚zlld|‚zVZTSKJkd\lek|‚ztts\[[JHFf]clrildd{||sledc\ttsttsllddc\\[[JHFd\\UTSdc\ztfkd\\UZsleVTLd\\tslaWM[[Tllk{ttkd\lldlritslƒ||uztƒ„„tts{||{{tlld{u{kk]ztf„Š}{{tlridc\lddultekd]bZdc\llkSKJtlllksmttlksVZ[f]cllkUTSlks\[b\[btt{\[bult\[bVTL\[bJHFUUY[TTdc\UMR\[bd\\UTS[[T[[TVTLMRK\[[|‚ztllttsekdd\\b[USKJUTSSKJ\[[dc\lldttsllkj]\d\\leklddUMR[TT{tt\UZleklldtsld\\VTLkd\[TTuzt[[Tƒ„„ddcu{{ƒ„„{ttd\\JHFmtt[TTldddc\\UZtts{u{u{{SKJ\UZ[TTVTLUTSekdlldedkddc[TTllkddcddclridc\JHFedkttsult\[[[[Tllktslf]ccbV[TTkk][[TlldSKJSKJtlltlld\\fkkd\\sretslllkVTL{||{{t[[TVTLUTSd\\ldd[[Tdc\tllrg]]bZttskd\ldddc\d\\[TTztl²««JHF*)(‹„„ƒ||‹‹„’ŒŒ‹„„‹„„{{t„„Šƒ„„‹„„tzl{||tll|„…llkƒ„„|‚zttstllƒƒ|tt{lddƒ}ƒ„„Šb[Uƒ„„{||ddcllk[[Tultlksultu{{{ttd\\JHFdc\VTLek]lld{{t{{tlddldd…‹’ƒ||sre|„…ƒ||„„Šlriƒ||ddc{||{{t|„…u{{ddcddcedk{u{{u{tsl[[TJHF[[T\[[ddc{u{lddultkd\f]c[TTddcd\\dc\cbVlddultuztkk]b[U[TT[[TVTL\UZtllVTLb[Udc\kd\redlldVTLb[Ulldtzl{||tllekddc\lldtll{{tlddztltsl]bZlrilldlddttslld{||\[[UUY]cdedktt{mtt\[b]cd\[bUUY\[bmttlkslksUUYfkkUTS]bZUMRJHFUMR:97JHF:97UTSUTSJHFllkllkVTLSKJllk]cdcbVLKRb[Ub[U[[T\[[SKJVTL\[[dc\lriddcVTLdc\llkf]cllklddlldlddUMRUTStts\[bkd\VTLllkJHFtllbVZuztttslddddcbVU[TT[TTUTSJHFJHFddcUUYUMR\[bJHFJHF[TTdc\d\\ekd[TTUTSJHFVTL\[[]cdD;9f]clld]bZd\\VTLSKJVTLJHFllktt{‚|uekdUTS]bZdc\JHFkd\[TT[TTtll[[TVTL]cdb[U[[TSKJVTLdc\lldFD;[TTUTSSKJJHF[TT[TTdc\dc\b[Ulddd\\VTL\[[bVUd\\jcVkd\ŠŠ}JHF-1+{tt‚|u„Š„ƒ}ƒ{tttts{||{tttts„„Šdc\“Œ”uzt„„Šllkttsu{{tts|‚zJHFedkleksle\[[sleek]llk\UZf]c{{tf]cedkSKJtts{ttlddlrillddc\\[[]bZ{{ttslUTSldd{u{llklksfkkllkultkd\[[TUTS]bZ[[Td\\tllUTSddctts\[[\[[dc\VZTJHFJHFJHFFD;UTSVZTVZTtllredd\\VTLVTLdc\kd\UTSd\\kk]dc\ddcUTS[TTdc\bVUcbVJHF[[T]bZtllb[UJHFd\\tllb[Umtt[TTUTS\[[VTLb[U[TTdc\VTLb[U[[Tddc[TTUTS\[[cbVVTLddcf]cf]cUTSlksllkVZ[]cdultmtt\[[edk\UZJHFLKRUMRJHFLKRUTSJHFJHF)+2:97F=CF=CJHF:97D;9d\\d\\VTLdc\VZTLKRJHFUTSJHFFD;JHFFD;UTSMSStllMRKUTS\[[UTS\[[\[[[TTf]cSKJSKJD;9JHFUTSUMRlddVZTUTSlekdc\lks\[[[TTddcF=CSKJFD;UMR:97JHF:97:97MSS:97\[[UUY\[bllkult{||JHFJHFFD;>B9>ECJHF:97JHFLKRUTS\UZ[TTUMRMRKd\\VTLJHFekdlldlddJHFF=CFD;MRKSKJSKJlldlddSKJllkUTS[[TJHFJHFD;9D;9:97:97>B9:97>EC:97D;9:97JHF[[TSKJSKJlddJHFFD;\UZJHFJHFSKJSKJ¦§¨SKJ*)(ztl{{tƒ||{{t{tt{ttllkdc\lldldddc\[[TJHFedkdc\ddcmttlkstts]bZllklddtllultVTLMRKJHFUTS]bZ[[TUTSJHF\[[UTS\[[tslbVZllktsl[TT]bZ]bZFD;JHF>ECJHFJHFJHFVZ[UTSddc[[Td\\UTSVTLd\\SKJ\[[\[[UTSVZ[JHFJHFD;9dc\JHFJHFUTSSKJUTSJHFJHFd\\JHFJHFJHF:97UTSJHF:97FD;JHFVTLJHFJHFJHFdc\[[Tkd\JHFD;9JHFJHFJHFFD;FD;SKJ[TT[[Tldd\[[JHFddc\[[lldd\\[[Tddcllddc\VTLFD;JHF]cdllkddcldd\[[[TTd\\]cd\[[]cdJHFLKRJHF]cd*)($:97*)(*)(?;C:97:97*)()+2:97:97:97:97UUY3+**)(74,!*)(*)(*)(*)(*)(74,*)(*)(*)(JHF*)(:97*)(:97*)(74,3+**)(*)(3+**)(*)(7-2*)(:97*)(*)(*)(:97*)(,55*)(*)(*)(*)(*)(*)(*)(:97&&%&*)(>EC-1+%&FD;)+2LKRLKRUTS?;CJHF*)($*)(*)(,55*)(*)(F=C*)(*)(*)(*)(*)(74,:97-1+*)(*)(*)(:97:97JHF*)(74,-1+*)(*)(*)(74,3+**)(*)(&&*)(*)(*)(!*)(*)(*)(*)(*)(*)(*)(*)(:97*)(*)(:97*)(*)(D;9:97*)(-1+VTLSKJFD;\UZ[[TJHFSKJJHFLKRJHFSKJSKJ3+*:97:97JHFJHF74,:97LKRUTSMRKMRKJHF:97*)(:97*)(:973+*:97*)(:97:97JHFLKR>ECJHF,55:977-2*)(-1+74,:9774,-1+3+**)(*)()+2*)(*)(*)()+2:97JHF:97,55*)(*)(*)()+2*)(*)(?;C*)(74,:97*)(:977-2*)(JHF*)(&&*)(*)(3+*:97*)(3+**)(*)(*)(*)(74,3+*&&&&3+**)(*)(&&-1+*)(*)(*)(SKJ*)(*)(:97*)(D;9:97:9774,74,*)(*)(>EC*)(:97*)(*)(*)(*)(*)(*)(74,*)(-1+,55,55:97)+2*)(,55:97:97:97LKRJHF?;CUUYf]c\[b\[b\[[[TTSKJUMRJHFllkUTSllkJHFMRKVTLUTSJHFF=CVTLJHFFD;JHFJHFUTSJHFJHF>ECJHF>ECJHFJHFJHF:97LKR:97F=CJHF:97D;9:97:97:97:97FD;:97:97:97JHFF=CLKRJHF\[b\[[MRKMRKdc\]cdLKRek]UTS\[bMSSMRKJHF\UZJHFJHFVZTMRKJHFMRKJHFJHFJHF:97:97:97:97JHF>B9JHFMRKJHF:97D;9UMRVTLJHFFD;VTL[[TD;9JHFFD;>B9:97:97>B9D;9FD;JHFJHF>B9D;9:97JHFD;9FD;UTSSKJD;9FD;SKJD;9SKJJHF[TT[TTJHFJHFVTLVTL:97[[Tdc\VTLllkbVZf]cek]>B9VZ[\UZ>EC\[[VZ[UUY\[[\[bLKRVZTfkk]cd\[[[TTUTS>B9MRKMSSJHFSKJddc[TTVTLVZ[UUY\UZUMR\[[MRKllkVTLJHF:97SKJ[[TVZTJHFJHFVTL\[bJHFMSS[TTLKRJHF:97JHFD;9:97JHF:97JHF\[bf]cJHF:97VTLJHFJHF>EC:97>B9JHFSKJ:97:97SKJJHFJHFJHFJHFFD;SKJD;9MRKJHF74,JHF:97:97JHFFD;UMRD;9SKJbVUFD;MRKb[UJHF:97UMRMRKMSSLKRFD;:97FD;JHFekd:97JHFUMR]bZJHFUTS:97JHF\[[LKR\[bLKRMSSJHFLKRMSSOS`OS`JHF¦§¨¦§¨“Œ”¦§¨¦§¨™š¤¦§¨¨©´…‹‹¦§¨›”›¦§¨›¢›¦§¨«²«››”²««¦§¨›¢›µ¶·µ¶·²««²««””‹¤¤¤¤£œ¥”“›¦§¨²««””‹””‹œ¤¦ƒƒ|‹‹„ztl›¢›šŒ‚v{¦§¨²²¬²««²««£››£››š””¦§¨“Œ”¦§¨tsl’…‹¤¤£œ¥Šƒ}¤¤²««››”¤¤¦§¨¤¤››”¦§¨²¬µ¦§¨¦§¨¨©´¦§¨¦§¨¦§¨£››¦§¨£››¦§¨¦§¨œ››«²«¦§¨µ¶···Ä¤¤£››””‹’ŒŒ‘Œ…‹„„””‹””‹‰ƒv¦§¨£››¦§¨µ¶·¤¤¤¤²²¬¦§¨¦§¨¦§¨›¢›¤¤””‹””‹¤¤Šƒ}””‹²²¬¦§¨””‹ult”š”Šƒ}‚wlztl£››¦§¨²««¤¤¦§¨£››™…£››£››²««””‹²««ŠŠ}²²¬[[T\UZ²²¬²²¬¦§¨¢—š””£››¤¤¦§¨ª³·²²¬¦§¨µ¶·Ä¿¾Ƶ¶·µ¶·µ¶·¦§¨¦§¨µ¶·¦§¨¦§¨£››‘ˆ}µ¶·µ¶·ÃÄƦ§¨µ¶·²««‹‹‹¤¤µ¶·¤¤›”›µ¶·²««²««²²¬µ¶·¦§¨Ã¼¿¦§¨¦§¨’ŒŒ«²«””‹¦§¨¦§¨¦§¨²¬µ”š”¤¤‹‹‹””‹ƒ„„£œ¥£œ¥£››¦§¨²²¬µ¶·””‹¤¤¦§¨›¢›¤¤“““‹’Š”š”’ŒŒ‹„„‹‹‹£››››”²««””‹£››£››¢—””‹””‹””‹ƒ||¤¤²««£››””‹£››²²¬¦§¨²««¦§¨””‹¦§¨¦§¨£››‘ˆ}¦§¨²««¤¤ƒ„„£››””‹””‹ƒ||””‹š””””‹µ¶·¦§¨²²¬¦§¨²²¬¦§¨¤¤¦§¨¦§¨¦§¨œ¤¦¦§¨¦§¨¦§¨¦§¨µ¶·œ¤¦¨©´lks)+2?;CLKRdc\ultd\\7-2>/Att{\[[f]c]bZ!:97%lrilridc\ddc:97SKJlddlldSKJƒƒ|:97*)(JHF[[TLKRJHF\[[JHFSKJVTLldd{u{f]ckd\]cdddcred{zmSKJVTL3+*:97%JHF\UZlld7-274,%&$VZTuzttll[[TUTSMSSVZTVTLVTLtlldc\tll[[Tddc[[TJHFJHFUMRekdddcUTS74,@/7 74,73FD;VTLRP:tslredbVUVTLD;9MRKFD;FD;D;9C8.]bZ&&&&3+*FD;D;93+*3)D;9dc\VTL3)FD;%&&0FD;SKJD;9D;9VTL²²¬dc\[[TVTLjcVƒ||SKJ>R.VTLJHFGSu]cd’ˆ|‚z|‚zlrityglldsreD;9SKJsre{{t‹‹‹‚|u{tt‹„„lddf]cMRKƒ}ƒ{tttllek]f]c[[T]cdUMRD;9UUY"%VTLFD;JHF\[bf]cMRKfkktsllri[[T ,55-1+>B9VTLUMRD;9VTLVTLlldSKJ\[[sre{||VTLd\\{ttSKJfkkJHFD;9SKJsleVTLcbV>B9VTLVTLyledc\3+*"FD;FD;d\\D;9Q?@SKJ >B9*)(:97*)(]bZ7-2SKJ3+*dc\zllUTScbVJHFlldtslJHFlldf]cJHF\[[LKR%&-1+,55{{ƒVZ[llkUMRlks]bZJHFF=CLKRf]clddlek\UZf]cMSSSKJf]c>ECf]c74,[[T]bZVTLttstllƒƒ|]bZedk{u{[TT{ttUTSLKR\[bUMRJHFVZTUTSJHFJHFVTLdc\lldultVTLtlldc\uzt{ttSKJSKJSKJ74,UTSf]cf]cJHFkk]JHFD;974,*)(>B9*)(JHF3+*fkkultUTSJHF\UZUMRVZ[[TTd\\lrio€wd\\uzt]bZtsl\UZLKRultuzttts\[[lddFD;-1+FD;>B9%)*)("*)(FD;SKJFD;j]\UMR[[TFD;SKJ:97C8.D;9D;9SKJFD;JHFFD;JHFtllUMR:97SKJb[UVTLFD;JHFVTLD;9F=CPF=JHFD;9D;9SKJJHF¦§¨VTLJHF‰ƒvƒ‚u‚|u‰|v‹„„lri’ˆcbVJHFtsl‹’Š\[bSKJ7-2[TTuzt|„…lldllk…‹‹lrib[UJHFb[Uult‹‹‹„„Šult[[Tlek{{tlldSKJ\[b{{ƒ{{tj]\tllultekdSKJSKJ\UZD;9ldd\[[[[TekdF=CVZ[JHFdc\uztultlri:97]cdfkkMRKJHFttsddc\[bJHF[[Tdc\]bZlriUTSddcVTLSKJUTSf]clri[TTztlb[UVTLVTLlldVTLVTLlddd\\cbVSKJMRKVTLkd\{ttb[UUMR\UZFD;*)(:97[[TFD;[TT:97>EC:97[[TJHFFD;sle[[TMRKVZTSKJVZT\[[>EC\[[UUYUUY>EC>ECJHFJHFUUY]cdJHF\UZ]cdlksddc>ECedkJHFddcj]\UTS\UZ\[[edkbVZf]c\[b[TT:97D;9[[TMRKb[Uek]VZTUUYJHFUUYVTL]cdd\\f]c\[b\[bD;9lriMSSSKJd\\[[T[TTsle\UZ\[[UTSb[Ullk\[bSKJtll\[[SKJSKJ*)(UMRUMRSKJJHF&&3+*:97JHF74,:97JHFLKRSKJf]c]cdf]c]cdedkVTLb[UVZTmtt[[T[[T]bZ[[TUTSu{{ddc{{t{u{lksf]c]bZ]bZVTLlri&&&&SKJaWM[TT[[TVTL[TTb[UFD;3+*FD;FD;VTL74,D;9VTLSKJ[TTd\\[TTD;9SKJJHFdc\JHFJHF[[T[TTJHFbVUUTSaWM[TTVTLtll¢—llkSKJtsl{{t{zm’…‹{u{kk]]bZ|‚zMRKdc\VTLJHF%UMR{||ttsttsŒ”•\[[|„…tzlrfklddult„Š„{||ekdlddldddc\…‹‹ddcb[Umtttt{ldddc\{ttultlriUMRUUY|„…dc\lekmttVTL\[[F=CMRKVTLfkk{u{{ttMSSMRK\[b:97ekdb[Udc\ult\[[:97dc\JHF[TTMRKddcu{{dc\j]\d\\[TTllkSKJkd\j]\d\\tll[[TlddmttVTLlldVTLJHFFD;D;9SKJJHF[TTddcD;9D;9*)(FD;b[U:97SKJsle:97SKJVTLddcVTLlld{||VZTddc{||llkF=CultlrimttJHF]cd>ECLKR:97MSS\[bMSS]cdVTL\[bddc>ECSKJ\[b\[[{||ƒ}ƒ„„ŠJHFddcbVUulttts\[[FD;:97VTL3+*JHFVTL:97d\\:97]bZdc\ekdddcUMRLKRD;9[[T[[TJHFf]cbVZkk]tlldc\zllSKJb[Ukk]edkf]c{u{lek]bZUTStt{f]clddUMRUTSSKJJHFVZTFD;VTL:97FD;FD;lddJHF‚v{fkkVZ[VZ[\[[sleƒ„„lldlkslriJHF[[Tkk]\UZdc\VZTƒ„„{ttVTLlks]bZ[[TJHFJHF&& +&&3)[TTSKJbVUkd\f]csleSKJ:97FD;&&FD;PF=FD;VTL[[T[TT[TTb[Ured:97[TT[[TVTLFD;VTLJHF[TTVTLf]cVTLSKJVTLD;9lldš””bVZJHF{zmŠŠ}’ŒŒ{ttlddMRKmttiq]z‚l‹’Š|‚zUMRVZTJHFSKJƒƒ|„Š„tt{d\\lkstts[TTJHF„Š„…‹’{{tlrid\\[TT[TT]bZ[TTddclldlddlldSKJJHFedkUUYJHFlekJHFUMR[TT\[[{zmUTS\[bMSSVTL]cd{{ƒ…‹‹UTSekdSKJLKRddcSKJllkJHF[[TFD;]bZlek]bZek]\UZVZ[UMRkd\lddztluzt[TTb[Ulekd\\{u{FD;VTLmttmttllkSKJMRK74,D;9VTLVTLb[USKJbVZ[TT&&PF=VTLVTL\UZek]>B9D;9tsl\[[ekdkk]mttdc\llk{ttllkSKJ\UZ{{ƒllk\[b]cd>ECLKR:97LKR{{ƒ|‚z\[bf]ctt{MSS\[bVZ[LKRttslldj]\iWUUUYldd[TTf]cf]cJHFJHFJHFFD;JHF[TTtlldc\FD;JHFbVZlldlldddcJHFUMRSKJSKJSKJJHFSKJ{ttSKJkd\ulttll[TTSKJ{zm\[[ult{ttj]\cbV]cd\[bJHFf]c‚v‚\UZkk]jcVVTLMRKVTLsreUMRFD;UTSlek‹„„llkUMRUTS]cd{u{{{tddcu{{]bZuzt[TTsred\\b[UVTLVTL{ttVTLf]cFD;74,VTLVTL>B9 :97*)([[TD;9SKJVTLkd\d\\VTLredb[UPF=FD;sreVTLjcVek]UMRldd[TTUMRlddSKJkd\b[UFD;D;9SKJdc\JHFtll[[TSKJ74,SKJlld£››f]cLKR‘Œ…ƒ‚usle‚v{JHFVTLsreFD;ZbN‹’Šlldf]cmttUMRŒŒš{{ƒŒ”•‹’Šekd””‹ttsttstll„Š„{||‹‹„|„…{||ultsleek]llkdc\ddctlltllddcd\\\[[mtttt{\UZUTSJHFb[U\[[{{ƒJHFUMRVZ[UTStslu{{{||\UZ\[b[TT]cd>B9FD;f]ctt{:97\[[VTLdc\[[TlritslMRKFD;[TT[[Tredtts{zmdc\UTSd\\SKJSKJD;9VTL]bZrfkttsFD;!D;9VTLJHF\[[SKJUMRVTLJHFSKJj]\d\\D;9i\VJHFD;9ztlUTSlek[[TekdVZTekdlddtsllekd\\]cd{{tbVZJHF\[b>ECLKR]cdlkstsl{{ƒmtt{{ƒf]cJHFUTSultlddVTLUMRf]c\UZf]c‚v{lekUTS]cd>B9MRKVTLVZT{{t‹‹‹lek¦§¨fkktlltts{||]bZF=C74,SKJddc|„…lldlekf]cdc\zlltll‹„„‚|ubVUb[Ulekd\\tllultddcSKJSKJf]cUMRldd\UZSKJD;9JHF[[TVTLSKJVTLVTLJHFƒ}ƒŠ}ƒ{{ƒllk]cd[TTd\\sleultleku{{œ¤¦ƒƒ|tslf]cVTLFD;[[Td\\UMRD;974,MSSVTLFD;%>B974,MRKJHFj]\kd\FD;UMRcbVjcVkd\ztfcbVC8.VTLFD;VTLek]VTL[TTkd\PF=JHFVTLjcV{zmd\\PF=FD;SKJ[TTSKJbVUVTLcbV]bZtsl¤¤ek]JHF‘Œ…‘Œ…ƒ„„’ŒŒzllf]clri]bZšŒztlƒƒ|g\rq^„¬¶Ã¨©´œ¤¦µ¶·”››|„…¨©´‹‹„”“›Š~‹tllultuztddcf]c{u{{ttƒ„„“““{{tuztœ››ƒ‚utllultfkk‹‹„f]cSKJ‚v{dc\{u{ddcƒ}ŠJHF{{ƒlrid\\„Š„|‚z\[[UTSUUYlksJHFddcD;9edk…‹’VTL:97lldƒ||{||ttslldldd[TTUTSj]\b[UVTLSKJ:97{u{lddSKJrg]b[Ullkllk{{t{{ƒD;9JHFMRKVTLUTSuzt[TTddcD;9:97sle[TTdc\SKJHR>SKJrfktslmttJHFdc\ttslrilriƒ„„|‚z“Œ”ƒƒ|lek{{t†~‘MSSmtt^fsfkkŒ”•Œ‹“tt{mtt„„Š{{ƒ\[b{||[[T\[bultkd\\[bVZTmttlek“~ˆmtt{{ƒmtt{u{JHF[[Tdc\’ŒŒƒƒ|llktlltsluzt{u{ultllkJHFUMR]cdcbVVZTddcF=Cb[Uƒ||tlltlllddlld{{tdc\mtttllƒ}ƒzlldc\d\\SKJ[TTlekrfkbVZ‚wlaWM74,JHFlriD;9ddctllekdŒ‹“ttszll”“›u{{u{{VTL{zmb[U{{ƒu{{‹’Štllƒ‚utll]bZ]bZztlcbVultUMRF=CSKJiq]MRK3+**)( *)(JHFredsleb[Ub[Ukk]cbVtslVTLFD;ZbNdc\jcVztfFD;]bZbVUtslb[UVTL[TTtslŠƒ}VTLZbNkd\rg]j]\{tt‰|vcbVFD;tll|‚z¦§¨>B9SKJ‘ˆ}›”›‹‹‹Šƒ}]cdjcVmttkk]ekd‹’Šš””ult„Š„‹’Š¨©´”“›»ÂÇœ¤¦›¢›¬¶Ã‹’Š”š”{{ƒ””‹’ŒŒ{u{{||›”›ƒ}ƒztlª³·››””š”{{ƒ›”›‚|u‹„„ttsllk\[[b[U\[b]cd|‚z“Œ”{u{””‹\UZ]bZlkslld„Š}{||llkVZTMRKF=C>ECrfk[TTMRKttsJHFlddllk|„…“““mtttllj]\redUMRJHFSKJcbVVTLFD;ek]‹„„dc\j]\lldJHFlekttsuzt]bZSKJ]bZ‹„„ult‚|u[TTUTS]cdVTL[[TsleVTLD;9aWMVTLtll{{tuzttsl›¢›{||lriŒ”•“““œ¤¦™š¤‹„„¨©´|‚zzlllksOS`]bZlks]cdtts…‹‹\[b‹‹‹†~‘\[bddcUTS{||‹’Šƒ||{ttddcedkzllf]c{{ƒfkkUMRttsJHFllkVTLlddztl{ttttsdc\lri]bZddcttsVZ[JHFrfkf]cllk[[TSKJ‹„„””‹ƒ}ƒlddrfkjcVslekk]lld‹…’ƒ||‹„„|„…SKJ{{ƒUTS‚v{\[b[TTb[Uuzt[[T\UZkjVJHFD;9VTLllk‹‹‹bVZ{{ƒddc\[[\[[ƒƒ|›¢›lldddcrfktzl{||”š”…‹‹b[UFD;d\\VTL{ttd\\UTSFD;\[[FD;&&%74,>B9uzt{tt{yfztl{zmb[UaWMSKJVTLJHFVTLVTLVTL|‚zkk]VTLkd\lldbVUSKJ[TTkk]sleaWMVTLkd\SKJj]\tll‚utd\\ƒ‚ulektslª³·VZ[SKJzll£››„‰v’ŒŒŠƒ}aWMtts]bZUTSƒƒ|Šƒ}Š}ƒ]bZdc\›”›ª³·¦§¨Œ”•|„…™š¤d\\‹‹„ztlƒƒ|tts{zm“““j]\f]c“““¦§¨””‹«²«¦§¨‹„‹{ttƒ}ƒ\[[‹‹‹Œ‹“\[bf]cf]cŠŠ}ƒƒ|ŒŒšƒ||™š¤mtt“Œ”„Š„tyg””‹{||UUYtt{ttsllkUMRUMRnv‚„„Š\[[ŠŠ}ddctt{{{tƒ„„{{t\[[lddUMRredkd\lldaWMb[Urfklddsletllldddc\lld‚v‚ƒ„„UTSJHFuzt‚v{tllkd\ƒ||LKRJHF]bZb[Uƒ‚uMRKUTSkk]JHFbVU””‹dc\{{ƒsleult|‚ztts{{t{{tult…‹‹…‹‹„Š„tts]cdMSS>ECMSSldd„†™mttf]c}‡’ult{{t]bZdc\f]cSKJf]c[TTleklrif]c’ŒŒ‹„‹tts]cdD;9MRKFD;[[TSKJbVU[[T{ttlldƒƒ|\[bekd„„ŠlritslUMRlld™š¤ttsbVUttsŠƒ}›”›ƒ||‹„„‚|ulldiq]…‹‹ƒ„„{tt‹‹„‹‹‹ƒ||lkslek“Œ”tll™š¤‰|vƒ„„FD;JHF\[[dc\ultlriƒ„„ƒ}ƒllk{||tts{{ƒ{{ƒb[UztflldddcUUYiq]zllƒ‚uddctsl]bZf]cultf]ckk]\[bC8.D;9]bZJHF!FD; 74,VZTtllš””‚wlldd‚wl[TTSKJrg]C8.dc\sreaWMaWMPF=JHFFD;{ttSKJSKJ[TTVTLek]i\VSKJVTLVTLSKJ‚|ukd\VTLsrellktsl²²¬\UZ3+*Š}||‚zrr]‘Œ…tzlrg]ekd|‚zlld‹’Š‰ƒv‚ut!VTL{yf¦§¨ª³·›¢›u{{¦§¨|„…rfk[TTlri™š¤ƒ„„™š¤¦§¨””‹””‹›¢›¦§¨„Š„ƒ„„‹„„‚|uj]\”“›|‚zLKR‹‹„{||tt{|„…FD;ƒ}Šƒ||…‹‹lksƒ}ƒultlri{||lrif]cuztedklksf]ctllttsllkUUY„Š„VTLdc\dc\…‹‹SKJ[TTd\\llk{||ƒ||ƒ„„SKJsle\UZf]cylemwrg]”“›ekdddcƒ}ƒVZ[JHFVTL{{tslekk]tll\[[ekdd\\VTLb[U{ttSKJkk]kd\{u{‚|uldd{zm’ŒŒ{ttƒ‚uŒ”•|‚z{ttlldultyl„tzlddcMSS\[bMSSUUYddc\[bMSSlks{{ƒƒ„„mtt\UZlld{{ƒtsl{ttƒ||f]c]bZŒ‹““~ˆultfkkztfMRKMRKtt{SKJr]ZVTLj]\sle‹‹„{{tlkskk]ttsdc\JHF]cdlri‹„‹Œ”•tll{tt””‹“Œ”ƒ||’…‹””‹ztllldttsŠŠ}’ŒŒœ››”“›|„…f]cf]cultƒ„„‹„„i\Vfkk]bZultkk]SKJ>B9VTLƒƒ|tsl‹„‹{{ƒ…‹’Œ”•mtt]bZdc\{zm…‹‹\[b|‚ztllƒƒ|tt{f]clri‹„„Š}|tllek]JHFsleJHFaWMJHF*)(:97!JHFbVZd\\j]\sle‚|ubVUVTLsleaWMztfztfHI/VTLFD;jcVVTLVTLSKJSKJJHFkjVŠƒ}VTLd\\d\\bVUSKJztl[TTkd\VTLult{tt¦§¨>EC:97{||„‰v„‰v²««™š¤ƒ‚uƒƒ|››”‚v{{||’ŒŒƒ}ƒ*)(&&ƒ‚n¨©´‹’Šddc|„…Š}ƒƒ||VTLD;9‹„„‹‹‹tll“““…‹‹‹„„””‹‚|u””‹”š”{{ƒƒ||””‹SKJ…‹‹tzl{zm„Š„™š¤“““\[[ztfƒ}ƒ{||ƒ„„VTL[TTb[U{{t‹‹‹ztl[TTSKJUTSMRKf]cUMRllklddultlekddcztld\\VTL‚wl\[[rfkkd\Š}|{||b[Ukd\red‹„‹{u{iq]‚|u[TT|„…tslekd[TTJHFD;9[[Td\\‚|u’ŒŒsle{||JHFVZTdc\kk]VTLVTLVTLjcVd\\{{t]bZ{{t{zmƒƒ||‚z”š”›¢›Šƒ}ƒ||lek{{ƒtsl{u{{u{>EC>EC]cd\[[\[bmtt\[b{{ƒ”“›ultFD;d\\lkslld[TTlekUMR|„…¦§¨{u{ultŠ~‹mtt[[TVTLllkSKJztlredlld[[TtsluztVZTJHFFD;lriƒ}ƒf]cbVZztftzlš””’ŒŒ’…‹redƒ„„Š~‹{zmsleFD;sletsl“Œ”š””{u{ddcJHFUTSSKJf]c„Š„rfk\[[‹’Šd\\JHFJHFlldMRKƒƒ|ult{{ƒtll{u{{{ƒekdsletsl›¢›mttŠ}|‹’Šƒ||ŠŠ}„„Š|‚z|‚zz‚lƒ||lksƒ}ƒUMR\UZlekb[U\UZJHFVZT?;C3+*:97SKJ‚|uŠƒ}ztl‹‹‹rg]r]ZcbVd\\SKJi\VjcVcbVcbVVTLVTLaWMztl[TT[TTsre‘Œ…jcVredb[Utllred{ttredrg]cbV[[Tƒƒ|µ¶·\[[:97œ››””‹£››£››{u{š””ÃÄÆ””‹…‹’]bZ£››{{ƒ|„…lks’ŒŒ””‹…‹‹…‹‹‹‹‹“Œ”Š}|dc\iWUredƒ||tsl‹„‹“Œ”red””‹‹‹„’…‹cbV‹‹‹£››‹„‹f]cŒ”•fkklri››”Œ‹“Š}|lri]bZldd‹„‹…‹‹\UZj]\lddlldƒ‚uttslekSKJUTS\[[{u{rfkŒ”•bVZJHF[[TŒ‹“llduzt‹„„‚wld\\[[T\[[tll‚|uƒ||{{tlld„Š„f]c‚utb[UUMRztlŒ‹“bVZ„Š}JHF[TT\[[uztdc\‚|uŠƒ}…‹‹\[[“““‹‹„srelddkjVƒ‚nVTLaWMj]\VZTllk››”‹„‹d\\ekd‹’Š„Š}{u{{u{[[T„Š}{u{“““f]cMSSn…{{ƒ~’“…‹štts”š”tt{\UZJHF\[[|‚z|‚zœ››ultlekf]cŒ‹“‚v‚›”›ddcekdJHFmtt…‹’{ttŠ}|{tt{||SKJkd\››”|‚ztzluztkd\j]\F=C\UZSKJ{||{u{kd\‚uttlltllult{u{ztl‚wl\[[{zm‹u…ztl”“›[TT\[b\[[\[[llklriƒ}ƒUTS\[[tllŠ}|mttiq]FD;]bZ‚utƒ}ƒddcVTLddcŒ‹“kd\{tt\UZ‹‹‹ƒ„„tslš””ƒ||›¢›‹’Štyg|„…‹„„f]cUMR\[bd\\ƒƒ|VTLUTS>B9JHFUUY3)JHF‹„‹j]\‚|u‘Œ…‚|uslecbVdc\jcVŠƒ}aWMSKJb[Udc\rg]ƒ‚nrg]d\\rg]lldb[U‹„„ztfaWMSKJlldd\\‘…„ƒ||VTLdc\j]\“““Ä¿VZ[JHF£œ¥²¬µ””‹››”‘…„¢—””‹tslu{{]bZƒ}ƒ†~‘^~Y3+*’ŒŒœ¤¦Œ”•¦§¨™š¤ƒ}ƒ|‚zVTLiWUyle¦§¨£››‹„„|‚zŠ}|slesle‹‹„”š”|„…Š}ƒ“““\UZ]bZ›¢›|‚z„Š„¦§¨‹’Štzl{{ƒllkš””„Š„mttj]\dc\{{t›”›tsltts‹„‹\UZttsJHFSKJd\\lriult{u{{tt‹’Š””‹ƒ||Œ‹“UMRd\\‚ut{ttŠƒ}lddldd[TT””‹‚utš””Šƒ}ultkd\lddttstllUTSSKJUTSddc›”›’ŒŒb[Ulri|‚zƒ}ƒlriœ››””‹sresreJHFlddƒƒ|“““ƒ„„£œ¥”“›„Š„›¢›”š”œ››‹„‹{zm\[b{u{f]clrilri{||uzt{{ƒ…„’{{ƒuzt}‡’ƒ„„\[bJHFVTLfkk|‚z…‹‹{{tultƒ}Šlri‚wl{u{tsltyg›¢›mttlriVTLmw“~ˆsle|‚zŒ”•bVU{zmVTLf]cŒ”•bVZlddŠ}|‚v{zllf]cSKJ‚utultŠ}ƒzllllkcbVkd\{||b[Uƒ}ƒŠƒ}SKJSKJ“Œ”llkŒ‹“…‹‹…‹‹‹„‹]bZekdd\\f]cFD;VTLaWMcbVj]\ddc{u{\[bƒ„„Œ”•‰‘~d\\ekd„Š„„Š„‹‹„‹„„œ››„„ŠŒŒšFD;|‚zŠ}|ƒ}Šƒ}ƒtt{D;9lksJHF:C+MSSJHF MRK’ŒŒttsi\Vlld{{tkd\f]crr]‹’Šrr]ultzllkd\VTLrg]VTLrg]j]\‚|uj]\FD;sletllƒ‚u\[[{yf[TTUMRaWMŠ}|VTL‚|u‹’Š‚|u¾ÆUUYJHF£œ¥£œ¥£››“Œ”ƒ‚n£››¤¤VTLƒ}ƒJHF‹‹‹{{ƒLKRr]gšŒ‹‹„|‚zª³·”š”œ››‹„„kk]Œ‹“›¢››”››¢›Œ‹“”š”‹„„‹„„š””kk]…‹‹Œ”•ƒƒ|{||d\\lld”š”™š¤¦§¨{||{tttsl“Œ””“›ƒ}ƒ{||]bZ{{ƒred‹’Šttsƒƒ|ldd{{ƒlek]bZbVZlksƒ„„ƒƒ|{{tllk£››””‹¦§¨¦§¨”“›ƒ|||‚z‚|u{tt‹‹„i\Vredd\\ƒƒ|‹„„’ŒŒj]\\[[tslŒ”•ŠŠ}[[Tƒ||lks\UZtt{sle‚v‚ƒ}ƒ|‚z‚|uf]cuztek]ztlkk]tslSKJ\[[{zm…‹‹ztl””‹Š}ƒ{zmuzt››””››fkktt{{{ƒ‹„‹tts[TTUTSlld[TTtts”››|„…„Š„mtt]bZtt{ekdtslllk‹‹‹ŠŠ}mttd\\UMRekdtlltllleku{{MRK]bZ|„…kd\|‚zkd\‚wlcbV|‚ztslekdlddttslldyleultzll…‹‹{tt‚utSKJzll£››“Œ”‹„„¦§¨‘Œ…‹‹„ttssle{tttslldd|„…{ttultlriuzt…‹‹VTLJHF[[TUTS‹„„FD;JHFkk]rg]|‚zœ››‹„‹tsl|‚z|‚z›¢›{tt{{t”š”„„Š‹‹„£œ¥‹‹‹d\\tt{fkkVTLredtts[TT\UZ:97SKJVTLFD;:97%:97\[[dc\llk””‹ztlb[UjcV‘Œ…d\\kjVd\\aWMdc\VTLPF=SKJylelddVTLSKJVTLdc\{zmrg]{yfrg]bVZjV[zll‚wl{{t‚|uƒ||‹‹„µ¶·\[[74,¦§¨£››””‹£œ¥ldd‘ˆ}rr]b[Uƒ}ƒj]\ljƒ}Š:97SKJztl”“››¢›»ÂÇŒ”•‚wlƒ||llk‹„„£œ¥“~ˆ{||¦§¨¤¤‚v{‘…„kk]””‹›”›{{ƒƒ||œ¤¦’ŒŒ‹‹„””‹’ŒŒ{zm‘…„£œ¥“Œ”‹„„ƒ}ƒ{ttmtt[[Tf]clddƒ}ƒ‹„„{u{tllmttllkŠ}ƒtts{{ƒtsl‹’Š|„…VTL¦§¨››””››‚ut|‚z{||”š”rg]ƒ}ƒ{||sleVZTFD;red‰|vztfsle\[btslŒ‹“‹’Štts{ttldd‹…’[[Ttll””‹ƒ||œ¤¦ƒ‚u\UZultlldkd\cbVztlj]\bVU¤¤‹‹„lri‹„‹ƒ„„uzttslƒƒ|”››ƒ}ƒ‹…’{tt…‹‹‹„‹{{ƒJHFiq]llk[[T{u{{{ƒ|„…mtt{{ƒttsekdVTLddc‹‹„ƒƒ|ttsj]\Š~‹ddc{ttf]c{||]bZMRKmttu{{|‚zŠƒ}{||tsl”š”llk‚|u…‹‹tsltts{tt\UZŒ”•{tt|„…bVUllkredrg]ƒ}ƒ£œ¥‚utƒ„„‰|v¦§¨””‹{tt‚utbVUd\\VTLtllttslksƒ}ƒƒ}ƒÂ¾Æœ¤¦œ¤¦|„…f]c{ttdkVkk]jV[‹’Šllkf]c{zmfkkVTLz‚ldkVœ››œ¤¦”š”„„ŠŠƒ}|„…UTSekd:97r]gUTS:97ultedkJHFD;9dc\,553+*[[TD;9JHF[TTUTS‚|uŠŠ}{{tƒ||zll{zm‚utrg]rg]kd\SKJVTLVTL[[TVTLVTLldd[TTVTLsreƒ‚usreiq]VTLsle‚utredƒ||lld‚wlztlƒƒ|µ¶·\[b:97“““£œ¥‘Œ…‚wl{ttŠ}|‘ˆ}z‚lJHFœ¤¦š””jcV.1SKJ“Œ”µ¶·‹’ŠªÁŲ¬µ’…‹ultf]clld‚v{ƒ||‚v{™š¤ƒƒ|tll‚|u¤¤|‚z¦§¨Œ”•“““™š¤››”ƒƒ|‚wl‘…„›¢›{ttrfk}‡’ult“““œ››lritslƒ}ƒ””‹‹’Štzllrilks‹’ŠŒ‹“SKJf]c{tt””‹ŠŠ}UTS‹‹„‹„‹|‚zred{||‚v{‹„„tsl‚utb[Uztl{||[[Tzllkd\i\VlddŠŠ}ultuztƒ||”š”tllb[USKJ[[Tllk‚v{‹‹„yleldd’‘~[[TMRKkk]d\\SKJkk]j]\ŠŠ}””‹„Š„{{tultŠ}|tslu{{uzt{||¦§¨‚v{„„Š{u{{{ƒ|„…LKR\UZlddllk{{ƒ{{ƒlksnv‚mtt‹’ŠUTSVTL]bZtt{llktllƒ}ƒŒŒšŒ”•Š}|tslMRK]bZ]bZiq]]cdtzl[[Tsre{zm‹’Š{{t|„…|‚zttsƒ||rg]ƒ„„f]cƒƒ|‚v{dc\llkSKJ‚v{{tt£››ƒ}ƒllkztl|‚ztslztfƒ}ƒj]\rfkŠŠ}sle\[[ultekd„Š„Œ”•{{ƒ{{ƒlri…‹’z‚lJHFtzltslyle‹„‹ƒƒ|b[Uuztlrilrilld|‚zŒ”•„„Štt{™š¤„„Š]cdlrisreztlf]c{{ƒ“Œ”tll*)(SKJkd\VTL3+**)(D;93+*JHFJHF{{tztl‘Œ…Šƒ}ztfVTLSKJjcVVTLSKJb[UVTLkk]jcV‚wlj]\kd\i\V[[Tkk]ƒ‚u{{ttslZbNzllr]Zzllyle””‹[TTkd\{{tµ¶·LKRLKR›”›‹‹‹›¢›£œ¥f]c‘ˆ}¢—„Š}tt{““““Œ”j]\JHFUTS’…‹Œ‹“„Š„¦§¨¨©´²««™‹†ldd]bZ‚|u‹’Š|‚z{{tred[TTsle£››mttmttuztš””{{t|‚z‹‹„{{t’ŒŒ|„…¤¤›”››”›{{ƒ{{t„Š}{||{||ult¤¤‹‹‹lld\UZllk{||lddb[Ud\\‚v{uzt‚ut„„Šlri{||dc\jcV{{ƒllkƒ||ƒ„„{tt\[[kd\{ttb[Uƒƒ|tslƒƒ|ƒƒ|sleSKJ‹‹„›”›””‹r]glldf]c\UZVTLŠ}ƒƒƒ|ƒ„„{{tVTL{ttlksSKJtsl[[TJHFš””‹…’‹’Š{{tlriƒ„„…‹‹mttuztuzt|‚z|„…ultllk{{ƒ“Œ”{{ƒlks{{ƒƒ}ƒ|„…edk{{ƒœ¤¦|„…Œ”•‹„„{||sleddcddclldƒƒ|f]cŒ‹“…„’¤¤{tttslVTLVZ[tzl‹…’ƒ„„tsl“““‹‹„{ttddc…‹‹|„…|‚z””‹„Š}‚utƒƒ|‹‹‹mwUTS{{tslelek‚v{Š}ƒŠ}ƒtts‚utsre\[[b[U{ttŠƒ}‹…’“““{{tsleƒ„„‹‹‹lksd\\ldduzt„„ŠŒ”•mtt‹„‹œ¤¦„Š}[TT|‚zttsŒ‹“”š”JHFz}››”llk|„…™š¤Œ”•“Œ”{{ƒ\UZek][[Tƒ||š””tlllksƒƒ|mttSKJzllekd\[b?;CFD;"[TTƒ„„slei\Vsle‚utVTLrr]bVUPF=VTLjcVd\\lldVTLsrelddi\VVTLSKJ‚wlz‚lŠ}|lrirg]b[U{ttbVU‚ut‰|v’ŒŒ‚|ukk]|‚z¦§¨VZTUTSultƒ„„””‹‘}zrg]‘Œ…ƒ‚u–¢‹„Š„j]\j]\bVUMRKSKJ{tt¨©´œ¤¦›¢›”“›µ¶·£››‚ut””‹ztl‹„„{{t··Ä|‚zŠƒ}‚|usle‹‹‹u{{‹’Š{||{ttƒ‚u{zm{tt‹„‹””‹ƒƒ|š””{||Š}ƒ™š¤‹‹‹{ttlri¦§¨’ŒŒ™š¤‚|u‚v{d\\lek\[[]bZ[TTf]c„Š}uztƒ„„bVZ“Œ”ƒ||‚wldc\lddd\\‹’Š{zmtlltsl‹„„{ttj]\ztf„Š„kk]SKJŠ}ƒ|„…£››››”{tt{ttJHF[TTd\\ult’…‹ekdJHF[[TSKJ\UZdc\dc\SKJVTLultult‚|uµ¶·u{{{u{…‹‹|„…‹’Š››”|‚z„„Š{ttŒŒš„„Š£²‹…’\[b\UZult™š¤lksu{{ŒŒš{u{Œ”•kjVu{{\UZJHFj]\]bZ]cd\UZ{tt‹„‹‹„‹„Š}””‹…‹‹tzldc\Œ”•™š¤‹‹„››”{{t’ŒŒ{||sre|‚z‚|uredf]cSKJœ¤¦llkf]cVTLJHFSKJbVUŠ~‹yleš””bVZFD;kd\{yf””‹d\\{zmzll‹‹‹ƒƒ|rfku{{d\\r]g{{tf]cJHFultf]c„Š„]bZ]bZek]{{t‹„‹\[[{{ƒ{{ƒllkf]csleƒ„„„Š„‹‹‹tt{ŒŒš„Š„edk{{t“““ldd‚|u‹„‹|„…jcV{||ekd\[[VZT[TTF=CFD;74,lldf]ctll‚wlƒƒ|‚utVTL[[TVTLb[UVTLb[Ulrikk]bVZddcƒ„„SKJsle{ttVTL{zmƒ‚u|‚ztsllldlddtll‚v{rr]‚wlztf{{t‚wl¦§¨fkkMRKtts£››Š}|‹„„tzl’…‹‹’Š””‹ƒ}ƒjcVVTL|‚zF=C?;C¤¤›¢›„Š„…‹‹ƒ}ƒ›¢›tslsleƒƒ|ƒ„„šŒ|‚z”š”””‹Š}ƒ¦§¨‹‹„ƒ‚u]bZ‹’Š…‹‹”››ƒƒ|{{tƒ||“Œ”rfk²¬µ¤¤{u{tsl¦§¨™š¤lddekd£œ¥ƒ||Œ‹“››””“›d\\ƒ}ŠlldllkbVUzll¤¤|‚z[[Tsreultƒ‚uldd‹„„tsl‚wl‚|u{{t…‹‹tslf]cekdPF=bVUŠŠ}j]\[[T’ŒŒƒ}Šlddtt{f]c{tt:97lldUMRultekd]cdVTLbVUbVZfkk|„…ztltslSKJ{tttsllri‹‹„‚|u{{ƒlri‹‹„„Š„‹‹„œ››‹‹‹ƒ„„fkklkstt{JHFVZ[›¢›g\rmtt\[b{{ƒtt{ƒ„„œ¤¦d\\[[TVTLVTL{zmcbVtts{u{bVU{u{‹‹‹››”“““uztVZTttsuztuzt„Š„ldd””‹››”f]c„Š}„Š„[TTtsl‹’ŠMRK[[T{{ƒ‚v{d\\ƒ||tsl‘…„’ŒŒ’ŒŒf]c››”‚utrg]VTLkd\’…‹{{tlek[[TŠ}ƒtygllk””‹ljVTL[TT\[[|‚zlddƒƒ|dc\lri”››‹‹‹ƒ„„edkekd]cd{{ƒ\UZ[[TŠ}|uzt“““Œ”•{{tmttttsŒ”•lriVTLsle…‹‹lldr]ZD;93+*|‚zkd\{yfFD;JHFSKJjcVMRK‚|uƒƒ|dc\‚utkk]SKJtsl]bZbVUkjVsre[[TtllD;9aWMslesreultj]\sre””‹ƒ‚usreredtts‚ut£››ult‚wlƒ‚u{{t‘…„µ¶·]cdMRK‹„„“Œ”’ŒŒ£››£››™š¤ª³·š…Ž\[[{ttldd]bZ]bZzll‚wlƒƒ|‹„‹„Š„Š}ƒ””‹ƒ||SKJFD;š””‹‹„Šƒ}„Š„ƒ‚u“Œ”š””{tt”››tll‹’ŠŒ”•‹„„{{tŠŠ}ƒƒ|tllƒ||£››|‚zƒ„„¤¤red{||cbV]bZ{u{£œ¥›¢›¦§¨ztl\UZƒ}Š¨©´|‚zŠ}ƒ‹…’{||tslƒ„„dc\š””¤¤{tt“Œ”‹‹‹ƒ||Šƒ}‹‹„“““slekd\ultsleztlult‰|vtll{ttllktllredUMRtslVTLtts{tt…‹‹{ttekd]bZaWMred‹„„llkƒƒ|‹‹‹””‹kd\Œ”•ƒ‚uœ››¤¤”“›‚|uƒ„„”“›‹’Š„Š„{||ultlek„Š„{{ƒddc]cdf]ctslŒ”•{{ƒ“Œ”lks{{ƒ…‹’j]\VTLFD;[[Tlddƒƒ|‹‹‹ultllk{||„„Šlriƒƒ|{{t{{t{|||‚zd\\‘Œ…‹‹„tzl””‹{{t|‚zƒ‚u‹‹„Šƒ}[[T3+*lektllyfltsld\\lddŠ}|‚ut{tt‚wl{u{VTLcbVŠ}ƒƒ||‹„‹‹‹„[TTVTLVZT‚utƒ„„tsl…‹‹{u{{yfmtt\[[{u{kjVŠ}|ƒ„„“Œ”¦§¨“““™š¤tzl|„…lkslldkd\„„Šllku{{‹‹„‹‹„|‚ztt{””‹VTLƒ‚usleJHFbVUUTS:97UTSD;9VTLiq]JHF%PF=b[Ulekrg]„Š}|‚zƒ||‚|utslkk]kjVVTLdc\llkdc\JHFb[Ukd\[[Tb[U{tt‚wl‚wl‰ƒvtsl{zmš…Žred²««‰|v¤¤sleŠŠ}‘ˆ}‹‹‹¦§¨\[[JHFŒ”•¦§¨“Œ”‹„„ŠŠ}‹’Š‹’Šultdc\dc\‹„„kd\VTL’}™£›››¢›””‹«²«…‹’{{ƒ[[Tdc\b[U¦§¨””‹kd\›¢›lri’ŒŒƒ||””‹Šƒ}tzluzt|‚z™š¤sre›¢›””‹tllr]gz‚l‹‹„lri””‹¤¤››”‚|u”“›Š}ƒš””””‹ŠŠ}ƒ„„‹‹„|‚zttsVZTŠ}|{{ƒtsl[[T‚|u‘Œ…ŠŠ}‹‹„ƒ||llk“Œ”tllƒƒ|‘Œ…tslŠƒ}Šƒ}lddred‹„„aWMtllƒ„„cbVJHF[TTult{u{j]\UTSllk„Š„Œ‹“ztl|„…››”tzlkd\ultƒ„„{{tŒ”•’ŒŒ‘…„›¢›ztltslkk]‚|u‹„‹{||lkscbV””‹mttŠŠ}›”›‹…’lksJHFuztmtt|„…ulttt{ŒŒš…‹š„Š„{||mtt\[[{zmSKJMRKlek‘…„ult„Š„„„Šult[TTlritsl|‚ztsllri…‹’{tt””‹µ¶·ƒ„„Œ‹““““‹‹„ƒƒ|š””|‚zdc\b[Uedkrfkred‹‹„[TTƒ}ƒŠ}ƒ‹„„Œ‹“””‹‚v{[TTkk]‚|u‚ut‰‰w‚v{lldƒ||SKJd\\tll{||j]\mtt„Š}ƒ„„tsl{zmztl|‚zª³·¤¤“““ƒ}ƒf]c]bZu{{{ttƒ||ztlred…‹’‹‹‹u{{Œ”•Œ‹“””‹tsl‹‹„ƒ‚u|‚zƒƒ|UMR7-2SKJFD;MRKLKRtt{3+*73JHF[[T‚utsledkV[TTPF=VTLFD;bVZƒ‚u‚|u{zmtsl]bZ{||i\VztlSKJ‹‹‹edk„Š„¤¤‚wl|‚zr]Zljzll‰|vlj‚|uŠƒ}ƒƒ|‚v{¦§¨[TT:97ƒ„„tsl’ŒŒƒ‚uuzt£››Œ”•””‹„Š„\[[Š}|lld]cd“~ˆ””‹›¢›””‹””‹f]c[TTb[Uyletzl{{ƒztl„Š„””‹[TT“Œ”bVUƒƒ|’ŒŒ{{tddc”š”‹„‹lrisreVTLtllult‹‹„kd\Œ”•”š”ƒ‚uš””‹„‹|‚z™š¤””‹{zmŠƒ}›¢›lritzl{tt‹’Š¤¤‹‹‹ƒ„„{{ttslkk]ŠŠ}red‘Œ…“Œ”tsl‚ut’ŒŒztllri{zmaWMƒ‚ujcVd\\SKJVTLkd\{u{\[[lri{{tf]cSKJ{{ƒ[TTrfkttsƒ||lri’ŒŒ’ŒŒyfllek‹‹„{{tult{ttsresre{zmŠŠ}sretll‹„„{||lri‹„„kk]{||{{t“Œ”ultf]cVTLVZ[|‚z]cdmtt‹…’llk„„Šƒ}Šttsdc\MRKjcVtslztl””‹ultf]ctslult£››Š}ƒ„Š„dc\|‚zVTLttsultƒ||’…‹‹‹„››”›¢›„Š„Œ‹“‚|uztliq]lriSKJu{{UMR|‚zSKJf]cŠ}ƒ’ŒŒ‹‹‹‹…’{||ƒ}ƒf]csre{u{lddŠƒ}ultuzt\UZVTLlrilld‹‹‹{u{ddcek]lddkk]b[Usle„Š„ƒ}ƒ’…‹‹…’’ŒŒœ¤¦‹…’\[b””‹{zm…„’ztl{||‹‹‹|‚zƒ„„„Š„„Š}]bZƒ‚uƒ}ƒ|‚zttsmttlks[[TVTLFD;74,UTS3):97iq]dc\|‚z{{tVTL‘…„‚|uƒ„„cbV[TTVTL|‚zsle\[[VTL‚|uztlŠƒ}ƒƒ|edktll‚wl‚|utsllldd\\d\\Š}|ztlƒ||ƒ‚u{zmƒ‚u‚v{£››UTS*)(‹‹‹“““‘Œ…ztfVTL‰|vlriVTL”š”llkr]Zb[U:973+*‹’Šœ››¦§¨rfkyfl‚|ubVUVTLFD;redƒƒ|””‹››”ultult‹„‹”“›Œ”•‹’Š¡¡¨©´Œ‹“{{ttsl£œ¥‚v{lri¦§¨‹‹„…‹‹‹‹‹““““Œ”‹‹‹lks™š¤™š¤‹„„””‹”š”„Š„uzt›¢›”š”””‹tt{‘}zedkaWMek]‚|uztfzll‹„„ƒƒ|tll{tt‚wlkd\rg]sleŠ}|ztllrir]gSKJf]cb[Uekd‚|u{ttŒ‹“d\\UTSult‹‹‹ƒ„„‹„„tslsleƒƒ|kd\uzt‹…’„Š„lkskd\SKJlld””‹|‚zlld…‹’‹„„„Š„Œ”•{{ƒtzllldlldŠ}ƒddcf]clksJHF]bZmtt\[[tt{ƒ}Š{{ƒu{{…‹‹bVZFD;tslddclld‚|uu{{lks{{tƒ„„ƒƒ|’ŒŒ{{tuztekdUTSŠ~‹ztlŒŒštt{‹‹„£››‹„„uztŒ‹“{{tztlŠƒ}kjVuztŒ‹“ultjV[””‹‰|vjV[‚v‚ƒ||„„Š‚utf]c{{tcbVƒƒ|{||‘Œ…“Œ”ztfultb[Uttstll””‹ddcƒ„„MRKlriVTLFD;lld|„…llk{u{llkš””’ŒŒ™š¤“Œ”mttœ¤¦ƒ„„‹‹„‹…’™š¤llkŒ”•tt{ŠŠ}”š”¦§¨“Œ”lriekd]cdf]cbVUVTL>B9FD;:97FD;&&C8.{{t„Š}‹‹„kk]ultsleulttslJHFVTLVTLsre]bZVTLbVZlldlddcbVlld’ŒŒ„Š}‚wlttskk]ƒ||ƒ||Š}|‚wlbVU‚|usrei\V‚|u‘ˆ}>B9:97››”ƒ„„‘Œ…””‹jV[bVZu{{i\Vekdllkkd\aWMVTLJHF¤¤™š¤™š¤|„…tts{u{sle\[[tzlr]gtslldd|‚z’ŒŒƒ||“““£œ¥ƒ||lri|‚zƒƒ|™š¤‹‹„SKJ„Š}™š¤{|||‚zkk]tsl|„…“““ƒ„„Šƒ}VZ[™š¤‹„‹›”›’ŒŒ‹‹„‹’Š|„…{zmƒ}ƒ””‹„Š„ztflld{zm{||„Š}SKJb[Uƒ„„ƒƒ|[TTredzllztllddƒ‚uylelj{u{tllƒ||llktllƒ„„””‹ƒ„„ultb[U{{ƒJHFtsl{||lriƒ‚u‚v{]bZƒ}ƒ|„…Šƒ}u{{tts‚wlsle‚|ulld‹’Š¦§¨‹„„ƒ}ƒ„Š„ztlŠ}|ƒ‚udc\ekd’…‹rfk{{ƒmttF=C>EC]bZf]c”“›…‹’…‹šƒ„„”››dc\\[bVTLVTLUTS‚|ui\VF=Clld‹„‹‹‹„ª³·‹’Šiq]dc\[[Tƒ„„ƒ||{||šŒƒ‚u›¢›„„Šuztuzttsl””‹›¢›Œ”•]bZ™š¤redultƒƒ|rg]f]c[TT|„…‚v{Œ”•ƒ}ƒ|‚z‚|u‚v{Š}|{zmƒ||ƒ„„redbVUUTS{u{lldƒ|||„…lri|‚z‹‹‹kd\d\\kk]u{{ult\UZšŒtts\UZtt{…‹’¨©´’ŒŒ™š¤”››‹„„u{{{||‹‹‹”››ƒ„„¤¤‹„„lrilld>EC%FD;74,FD;SKJVZT3+*&&C8.yle|‚zƒƒ|ƒƒ||‚z‘Œ…Šƒ}JHFJHFlri]bZVTL:97VTL{u{tzlŠ}ƒlddrfkllk{zmlriƒƒ|VTL‘Œ…rfkŠƒ}‰|v{u{””‹Šƒ}‚utztfµ¶·MRK*)(‹’Š‚ut|‚z‘ˆ}{zmJHF|‚zllkuztlekttsi\VD;9D;9‹‹„«²«ŠŠ}Œ‹“””‹{{ƒcbV[TT‹’Šedk‹‹„ƒ||¤¤’ŒŒ™‹†‹‹‹’…‹b[Uƒ„„lri¦§¨ª³·””‹kk]Œ”•”“›ddclldVTLekdSKJj]\F=Cj]\{{ƒ„„Šƒ„„››”’ŒŒsle]bZlld{zm‹‹‹””‹‹’Šrg]ddcf]cj]\‹‹‹š””“Œ”j]\ddclddŠƒ}š””tzlztlsleƒ}ƒ‚ut{||Š~‹“Œ”fkkŠ}ƒ|„…tslmttf]ctslUMRSKJ‹„‹lksslef]clddddc{{ƒŒ”•‹„‹tslƒ„„tts’ŒŒlriuzttslz‚l{||‚utsreƒ||’ŒŒ…‹‹uztVTLtllultddcedkekdLKRu{{lkstts…‹’œ››Œ‹“”“›{tt{{ƒj]\MRKVZTrfklektsluztƒ}ƒ“Œ”“““ttstsllks‹„„…‹’„Š„ttsƒƒ|lldŒŒšŒ”•‹‹‹{||ldd“Œ”‰‘~„Š}mtt{{ƒ“Œ”£œ¥‹’Š‹„„lek‹‹‹ƒ||tts”“›‹„„ƒƒ|ƒƒ|‘Œ…‚wl››”£››b[U\UZtllrfkldd‚v{”››”››|‚zƒ}ƒ„Š„j]\‚|uSKJ{{ƒJHFddcredult„„Štt{ult‹„‹{zmµ¶·”››ultldd‹‹‹…‹‹”››‹„„¤¤‚utlldllk]bZ:97aWM3+*C8.Q?@F=C%&&&tlllri{zm‘Œ…VTLƒ||VTLƒƒ|ztl{u{JHFVTLlldJHF\UZ[TTtsllddtlld\\tts[[Tsre[[TVTLkd\kd\ŠŠ}£››£››rg]Šƒ}sle‚utµ¶·MSS:97tslƒƒ|“““‚wlekdJHF|‚ztt{uztdc\|„…rg]74,bVU…‹‹”››””‹“““UTS{||ddcekdlritsl‹‹‹’ŒŒ‹‹‹‹‹‹Šƒ}sleƒ„„””‹llkVZ[‹’Šœ››‹’Š{tt\UZ„Š„{||ƒƒ|VTLSKJ]bZ’ŒŒœ›››”›FD;[TT“Œ”¤¤¤¤‹„‹‹‹„œ¤¦””‹|‚z¤¤mttrg]tts‘…„‹‹‹d\\rg]Š}|{ttƒ„„‹„„kk]tsllldtsl‚v{{zmkd\ldd’ŒŒƒ„„mtt„Š}ƒ}Š‹„„ƒ„„{u{f]cultUMRztlult’ŒŒj]\Š}ƒkd\llkƒ||lri„„Š{||ttsf]c[[Tsreƒ„„‹‹„‹‹„{tt””‹{||ttstsl{tt{||‹‹„Šƒ}lek{ttuztMSSmtt“Œ”{u{ek]{u{{u{f]ckd\lddd\\SKJtsl’ŒŒf]cdc\{{t[[Ttllf]c\[[u{{mtt{||ekd‰|vŒ”•kd\””‹‚|u›¢›²¬µƒ„„Œ‹“‹‹„{ttVTL[[TVZTlri‚|uœ¤¦Šƒ}“Œ””››ƒƒ|{u{tsl{u{{tt‹‹„‹„„‚|u|‚zllkultlddslej]\{u{j]\‹‹‹ƒ}ƒƒ„„tzl“““‹‹„Šƒ}UMR[[Tj]\{tt‹„„ultf]c\UZ‹‹‹slerg]‹‹‹f]c{tt„‰v‹’Šfkk””‹f]ctsl\UZŠ}ƒ{u{{{ƒ:97lldmttF=CFD;>B9FD;|‚zj]\|‚z|‚z‚wlsletzlaWMrfk[[T[TTlri{zm\UZ‹’ŠlddcbVtsllldSKJttsttsVTL[[Ttllsre[[Td\\{zmrg]lldrg]ƒƒ|‰|v{zmÃÄÆJHF3+*{{t””‹”š”¢—rr][TT”“›|„…ƒƒ|llk{{t‚|uC8.JHF{{t“““uztœ››{{t”“›ƒ}ƒlksdkVŒ‹“lld‹’Š‹‹„ƒƒ|‹‹„¦§¨œ¤¦\[[|„…ƒ„„‹„„£œ¥ztl‹‹‹“““tzl””‹|‚z“Œ”lri£œ¥ƒ}ƒ{u{‚utultª³·{{t’ŒŒ‹„„‹’Š‹‹‹tslkd\””‹jcVš””‘Œ…ƒƒ|‚|usleƒ„„‘…„r]gyledc\d\\‚|ulld{{tsletllrfklddllkyleœ¤¦ekd{u{edktzl{zmlekf]c{{ƒVTLrfk‹…’””‹]bZ|‚z[TTŒ”•{u{ƒ„„tzl”š”fkk{{t””‹redlri””‹‚v{lld[[Ttslzll’ŒŒ|‚z{{tƒ}ƒ’ŒŒ…‹’lek{||Œ—££››‹…’Œ‹“{{ƒ{{ƒ{u{ttsttsfkkd\\\[[‹’Š™š¤zll{u{››”ƒ||ƒ||¤¤]cd|„……‹‹“Œ”|„…››”Œ”•‚utƒƒ|tsl“Œ”””‹Œ”•œ››””‹ƒ„„JHFmtt{{t…„’‹’Šœ¤¦«²«‘Œ…ƒ‚uult””‹“Œ”tt{kd\{zm’ŒŒ‘Œ…sre{u{\UZlekult’ŒŒ“Œ”š””‹„„|„…lrirg]””‹iq]ƒ||“““ttsldd‹„‹[TT“Œ”ultƒ||lldredlld‚v{“Œ”Œ”•ƒ||“Œ”ƒ„„¤¤kk]u{{“Œ”VTLb[U…‹‹\[bSKJ{{ƒr]gUMRƒ‚uVTL]bZJHF\[b{||‚|u“Œ”dc\kk]ultrg]\UZtsl„Š„tzlddclddu{{tts{{tVTLredUTSUTS]bZdc\]bZrg]SKJrg]{yfkd\i\VSKJsreldd¦§¨SKJ:97””‹‹„„{zm‘Œ…]bZttslri„Š„ƒ‚ukd\dc\rg]PF=bVU‚v{œ››”š”œ¤¦ztl”“›Š}ƒtsl„Š„”››ƒ||“““¦§¨‹…’‚ut{||ddc‹‹‹b[Utts””‹Œ‹“lddkd\lrilritzlŒ”•ƒ‚u„„Š‹„‹µ¶·„„Š“Œ”tts¨©´Š~‹£››d\\dc\ldd…‹‹jcVVTL{{t{ttztltslƒƒ|ztl{{t’ŒŒŠ}|Šƒ}rg]mw{zm{zmredrg]‚v{lddred”“›ult‚v{fkkd\\‹„‹kk]ƒƒ|‹‹„‹„‹lek\[[kd\ƒ}ƒtllƒ„„|‚zek]uztŠ}ƒuztlri‚|ufkkƒƒ|”š”{tttslƒƒ|{tt“““‹’Š“““lddƒƒ|”š”‹’Š™š¤ulttllb[Ukk]|„…œ¤¦™š¤Œ”•£œ¥fkk|‚z‹‹‹{tt[[Tslelri„„Š|‚zŒ”•¦§¨‹’Š{||‹…’{{tVZTdc\\UZ|„…|„…llkŒ‹“ƒ„„“Œ”‹‹„£œ¥ƒ}ƒ›¢›ƒ||ekdttstts”“›{u{””‹{{tttsztluzt£››‹„‹‚v{tlld\\sre‹’Š’ŒŒ‘Œ…{tt‹„„d\\Š}ƒ{{tldd[TT…‹‹lldbVU’ŒŒ›”›tll‚utllktzl‚|ubVZlekllkSKJlri[TTttsd\\{zm’ŒŒ¨©´„„Šƒ||ƒ„„“““›”›‹‹„tllbVZkd\„Š}]cdu{{:97{{ƒJHFD;9”š”|„…]bZ:97dc\{||rg]‚wlekdtslztlllkultsrettsŠ}|mtt{{ƒ{tt|‚zš””{||ƒ||d\\slesrett{ŠŠ}b[Ub[UcbVrg]””‹cbVjcV‚wlrg]µ¶·ddc*)(‹’Šœ››„Š„zll›¢›u{{lld„„ŠsleUTScbV{zmHI/ultult¤¤‹’Š‹’Šred™š¤f]c{zm‹‹‹tts{{t”››‹„„£››ult¦§¨ult…‹’dc\{||tts¨©´”š”„Š„„Š}…‹‹Œ”•ƒ||cbVtt{{{ƒ£œ¥tts‚ut‚v‚ddc”“›š””ƒ||f]c‹‹‹UTSkk]lldVTL{{tƒƒ|‚|ud\\ztlsreƒ||‘Œ…‰ƒvbVU‚utlrilldVTLVTLd\\kd\b[U]bZ’…‹{{ƒJHFd\\ultek]tslƒ||ƒ}ƒlri]bZdc\lek]cduzt{{ƒkd\b[UUTSult„Š}slelek””‹ek]‹„„tsl{{tred{{t{zmj]\lkscbV{{t|‚zult’…‹kd\lekUTS{{ƒekd{{ƒ”“›“Œ”{||ƒ„„œ¤¦‹‹‹‹„„›”›„Š„‹’Š{||tllƒ„„ek]tt{ƒ}ƒ{||‹’Šlldlek{{ƒŒ”•tslŒ”•‹’Š’ŒŒ›¢›“““”“›”š”ƒƒ||‚zmttf]c]cd…‹šddcztl|„…ƒ‚u|‚zuzt„„Š‹„‹{{ƒf]clksƒƒ|¤¤«²«››””š”„„Š{u{zllult‹‹‹fkk“Œ”’ŒŒ‹„‹‹„„tlllldsle‚|u£››{{ƒƒ||lrildd‚|ubVUttsultztfŠƒ}tll…‹‹rfk{{t…‹‹‹„„cbV{||mttƒƒ|UTS]bZUMRD;9\[bekdzllVTL{ttedkSKJ>B9f]c{zmredVTL„Š}Š}ƒb[U\[[{{ƒfkk‹‹‹{||lks{{ƒ[[Tllkdc\dc\‹‹‹u{{Šƒ}‹„„„Š„dc\lri‹‹„{zm””‹›¢›ljsle‰‘~²««[TT:97››”””‹¦§¨’ŒŒuztttsj]\f]cVTLbVU{{t{ttFD;JHFyfl‘Œ…zllmtttsldc\d\\kk]”š”“““‹„„”››””‹…‹‹šŒŒ‹“lks‹’ŠŠƒ}llk„Š„µ¶·œ¤¦…‹’{|||‚z|„…{||ƒ„„uzt‹„‹”“›ultšŒlrittsœ¤¦’ŒŒ{tt„Š„ult{||sleŠŠ}£››{zmslesreVTLtllsre’…‹i\V‚wlultš””lldztllldtllkd\VTLSKJƒƒ|ƒ}ƒlektslzlllriVTLd\\{ttultuzt\[[VTLrfkttsttsuztkd\b[Ulriƒ}ƒ{zmrfkJHFJHF74,b[U{{tVTLllktslsrelriƒ‚utsl|‚z‹„„ult‹…’bVU{u{ekdmttfkk£œ¥ƒ}ŠŒ‹“¦§¨{{ƒu{{f]cƒ}ƒJHFcbVllk‹’Š„Š}{||‹„„…‹‹£››{||lldŠƒ}|„…Œ”•Œ”•|‚z…‹’ƒ„„‘…„‹’ŠŠ}|{{ƒu{{JHF]bZredyl„lksllksreztf|‚z’ŒŒ’ŒŒ¤¤{{t{u{‹…šf]cd\\lldsle‹‹„|‚z„Š„Œ‹“\[[tllztlred“““{ttŠ}ƒtll…‹‹ek]bVUtsl‹‹‹²««š””‚v‚{{ƒŠ}|ultekdlek‹„„yle‹„„œ››œ››lld‹‹‹“Œ”tzl{||slemttuztMRKVTLJHFFD;FD;tzlD;9lldsre]cdJHFJHFddcaWMrg]VTLtslƒƒ|edklddlek{{ƒllkUTSddc{tttzlult{||llkultŠ}|ƒ„„‹‹„{{tSKJi\V””‹{zm””‹£››¤¤{||ŠŠ}‹‹‹VTL:97‘Œ…„Š„‹„„‰ƒv‹‹„ƒ„„‹‹‹[TTjcVkk]kk]VTLbVU%UTStslƒƒ|…‹’{{tlrid\\lksuztœ¤¦ldd””‹“Œ”{||¤¤“Œ”“““””‹ƒ}ƒ”››››”£œ¥z‚l¦§¨‹„‹ekddc\ƒ||…‹‹ƒ„„\UZultkd\‚v{VTLddc”š”lek›”›“““œ››lld›¢›ult‹„„kd\rg]‚|u{{tlddlrid\\ŠŠ}›”›‚wlred\[[sref]c‚|uVTLSKJVTL‚|uultredfkkd\\|„…dc\lldlektlllld[[T‚v{f]c{ttlri„Š„d\\zlllriultztl\[buztddclldrfkuztcbVllk‹‹„„Š„Šƒ}{||lddƒ}ƒ|‚zƒ||Š}ƒmttŒ‹“lks|„…”››tsl]bZ|„…ttsƒ}Štts\UZtts]bZultlldlks‚|uƒ||tllldd£œ¥ƒ„„llk…‹‹‰Š¡ƒ}ŠfkkŒ”•„Š„‹‹‹lld››”“Œ”‹’Š‹‹„›¢›\[b„Š„lldtt{d\\dc\„Š}ƒ„„‰|v‚|u‹’Š„„Šƒ„„‹„‹edk{||[[T‹‹„{{tƒƒ|‹„„‹’Š™š¤’ŒŒr]gŠ}|‹„‹‹„„œ››{{ƒ|‚zrg]llk‹‹„‚|uƒ}ƒƒ„„ƒ„„ƒ||rfk“Œ”‹‹‹tt{{u{zllkd\Š}|tt{sre‹’Štllƒƒ|\UZddcek]…‹‹‹„„|‚z\[b>B9\[[ddc\UZVTLJHFC8.JHFFD;ddcylecbVztllriztlllkddclek{ttttsllkllktts””‹‹„„ddclek{tt|„…tsl’ŒŒsrerfkcbV‰ƒv‰|v£››””‹‰|v“Œ”‚|u¤¤VZ[JHF‚|u{{tœ››Š}|ƒƒ|{{ƒ™š¤†~‘lldtllkk]‰ƒvsleD;9UMRultsle{{t‹‹„“““uztu{{Œ”•“““››””š”™š¤‘…„ult‚utldd[[T’ŒŒddcŒ‹“‹‹„“““Œ”•š””tts”››‹‹„Œ‹“”››œ¤¦“Œ”Š}ƒ¦§¨b[UllkŒ”•£œ¥›”›|‚ztslœ¤¦llklldlldrg]cbV‚|uVTLj]\{{tztlztl‹‹„red“Œ”d\\ƒ‚u‹’Š{ttFD;cbV{{t¤¤’ŒŒultztlSKJ]bZMRKkk]ƒ}ƒ“Œ”u{{tsl››”“Œ”‹’Š|‚zu{{Šƒ}‹‹‹ttsƒ}ƒylef]c›¢›]cdlridc\”››‹’Š{ttœ¤¦{zmultlld{||tllllk{u{ƒ„„[[Tdc\]cdlks…‹’lks‹’Š{{ƒtt{lks‹uŠbVZldd\[[{tt\[[]cd‚utƒ}Štllƒ}ƒ“““‹’Šƒƒ|Œ”•‹…’lks··Ä‹’Š‹’Š“Œ”’ŒŒkk]“Œ”›”›ttsuztllk{{t{||edkJHF“““‘Œ…”“›‚utuzt””‹›”›lek‚v{Š~‹tlltsl’ŒŒlriƒƒ|‹„„”“›ƒ||ultj]\‚|utts{ttlddƒ||b[Usleš””lri””‹“““{||Œ‹“ƒƒ|”“›“Œ”ƒƒ|‹„‹“Œ”ƒ||š””“““{{tslemttjV[tsl‹’ŠŒŒšllkmttSKJMRK]cdJHFD;9JHFSKJD;9fkkaWMedk‚v{ddcrg]{zm››”lld{zm„Š„tts„„Š{u{bVU|‚ztllƒ}ƒ“““|„…‹„‹lddttsŠƒ}lldŒ‹“tslrg]b[Uƒƒ|ztlƒƒ|‰|v‘ˆ}rg]››”µ¶·UUYLKR‰ƒv¤¤Š}ƒ™‹†ƒƒ|[TT{ttuzt‚|uƒ„„i\Vrg]FD;VTL[TT{||dc\|‚zƒ||tts]bZ\UZ››”’ŒŒŠ}ƒœ¤¦ƒ„„‹„‹‹’Š’…‹‹’Š|„…tt{dc\ƒ}ƒƒ„„„Š}jcVzll…‹‹lri¦§¨‹„‹„Š„ƒ„„lks“““›”›ekd‹…’‹‹„¦§¨¦§¨”š”d\\lks›¢›tslŠŠ}srerfksre{{t‘Œ…””‹‚ut‹„„›”›jV[Š}ƒ{||ƒ‚uƒ||tzlek]cbVmtt[[T‹„„lekSKJlld|‚z››”’ŒŒ’…‹‚ut|‚z[TT””‹…‹‹tsl|„…‹‹‹slelldFD;sreƒ||“Œ”|‚zƒ„„{{t‚|uƒ„„ƒƒ|”“›‹‹„‹‹„‹„‹£œ¥“Œ”‚v{‹’ŠŠƒ}{ttultuzt|„…MSSmttu{{ttsllklkstt{{||Š}ƒlekuztƒ‚uddcultttsƒ„„{{ƒ™š¤ldd”“›”š”™š¤··Ä„„Š|‚zfkk“““‹…’”š”tslztlƒƒ|uzt‹’ŠŒ‹“‹„‹‹…’tlllekdc\‹„„‹’Š“Œ”‘…„‹’Š›”›’…‹¨©´ƒ||VTL„Š}ƒ||ƒƒ|Œ”•{ttŒ‹“”“›””‹tts“Œ”u{{ƒ||ƒ„„’…‹‘Œ…‚wllks|‚zkk]ƒ}ƒsle“Œ”Š~‹‚v{œ¤¦redrfknƒ’…‹£››“Œ”tslŒ”•cbVztlƒ‚u{||ŒŒšƒ||UTSFD;ZbN:97:97SKJ[TTcbVsreSKJVTL[[T{u{[TTsleult‚wlcbVŒ”•dc\{ttlekƒ„„ztlnv‚mttƒ}ƒ‹‹„ƒ„„tllf]clddcbVdc\‹„‹kk]‘ˆ}ƒ||ƒ‚u””‹””‹‚wl‚|u£››“““¤¤\UZ>ECztf›¢›‹„„rg]iq][[TŠ}ƒllkztlkd\tts””‹redFD;{tt{tt‘…„|„…|‚zŒ”•ekd{{ƒ‹„„ƒƒ|ƒ||¦§¨¨©´²¬µ£››“Œ”‹’Šmttƒ„„tll{{tekd››”kk]Œ‹“‹‹„ƒ„„™š¤tt{”››‹„„Œ‹“‚ut“Œ””š”ekd’ŒŒŒ‹“‘Œ…{{t””‹tt{ƒ„„”š”‹‹„””‹Š}|‹„„{{tjcVƒƒ|ƒ||””‹‚wl{{t\[[d\\lld{||iq]rfk„‰vdc\d\\[TT\[[tts””‹llk|„…š””’ŒŒ‚v{ƒ„„f]csle{u{ƒƒ|…‹’lldSKJd\\tll‹‹‹‚|u£œ¥ztflld‹‹„””‹uzt{{t“Œ”Œ”•‹„„|„…‹„„œ››ƒ„„Œ”•ztlbVZddctsllld}‡’|‚z{{ƒddcŒ”•ƒ„„lksƒ}ƒddc“““\[[{||tt{{{ƒ””‹‹„‹„„ŠšŒ{tt“““ƒ||¨©´™š¤›¢›lkstt{ƒ„„…„’””‹{{t{u{œ››”“›Œ”•„„Š…‹‹‹„‹™š¤lriztlrfkf]czllztltsl›¢›ƒ}ƒƒ„„ultldd|‚zƒ||‹‹‹dc\‹‹„£œ¥š””b[Ukd\{zmtslŠ}|Œ‹“‹„„””‹ƒ||ƒ}ƒlriSKJrfkultf]cƒ}ƒ“““lks‚|u™š¤ƒ}ƒš””Š}|ƒ||Šƒ}‹‹„„Š„””‹{zmƒ}Š|‚z’ŒŒttsb[Ullk\[bFD;%UMR[TTtzlJHFVTL’ˆVTLlriŠ}|kd\Šƒ}ƒƒ|llkttsllkddcllkƒƒ|ult{{ƒ{u{„Š„Œ‹“u{{lksult‹‹‹‹„‹{||ƒ‚u{tt››”¤¤””‹‚|u‚v{¦§¨‰|v‹’Š›”›UMRJHF{{t””‹j]\‚|uttsb[Ub[Ured‰|v‚|u{ttztlD;9FD;{{ƒ“Œ”sle|‚z‹‹„œ¤¦llk[TT|‚z“Œ”‹„‹„Š„‚v‚µ¶·››”|„…œ¤¦mtt…‹‹|‚z”š”|„…{{tƒ„„{||”“›{||ƒ„„lkskd\f]c{u{‘Œ…{tt‹„„ƒ}ƒ¨©´{ttrg]‚|uldd{u{Š}|tllkk]tsl’…‹[[TVTLš””|‚z“Œ”‘Œ…‰‘~‰‰wtlllritsld\\JHF’ŒŒƒƒ|tslƒ||{tttts\[bekdllktsl‘Œ…‚|u‹„„lritlllek‹„‹|‚zdc\‹‹„lldttsd\\‹„„bVUtlltts[[T[TT{{ƒttsVTL{u{›¢›lridc\Š}ƒƒ||ƒ||‹‹„lddf]c{{t”š”{{ƒmttfkklldmttuzttt{lksVZ[{||ztlVZTƒƒ|llkultŒ”•’ŒŒ\[b‚v{‹’Š«²«ƒ||™š¤¦§¨¦§¨Œ‹“{{ƒu{{™š¤”“›ƒƒ|›”›ƒƒ|‹„‹|„…µ¶·›¢›™š¤„„Š™š¤‹’Šf]csre‹„‹tllllkkd\‹„‹‹„‹{||d\\llkult””‹tts‹‹„]bZ‹„„lld[[TSKJult‚v{{||’ŒŒ“““{||“Œ”tzli\V{tt„Š„Š}ƒ‹„„š””fkk\UZ{u{tllƒ||redƒ„„””‹ƒ„„„‰vuztdc\{||ekdj]\tlllddVTLMRK[[T>B9\[[kd\tsl\[[MRK*)(u{{{||redj]\‹‹„œ››ttsekd[TT[TTddc‹„„edk\[[tts|‚ztts|„…„„Šlek„Š„lddƒ}ƒ‰‘~‰ƒv‹‹„››”””‹””‹ ™‹†tll””‹µ¶·\[[,55‹‹„ƒƒ|‹’ŠjcVz‚l]bZttsztlƒƒ|‚utFD;sref]cVTL‹„‹“Œ”d\\œ¤¦››”œ¤¦„„Š™š¤lek”“›‘…„”“›tts“Œ”ª³·ª³·¨©´ÂÅÓ›¢›ª³·”››ƒ„„””‹|‚z“““{{tf]cultŒ‹“ƒƒ|{ttd\\Š}ƒŒ‹“tzl„„Š”“›ƒ}ƒtllƒƒ|redu{{zllkd\‚wlƒƒ|‹„„„Š}›”›i\V‰‰w‹„„Šƒ}{zmƒƒ|ƒ||lldbVUttsb[Uƒƒ|tygredzll‚v{\UZ[[Tkk]{{ƒlks››”kd\rr]lld‹„‹uztmwœ››ƒ||„Š„d\\ddcultzllŠ}|yle’ŒŒsle‚|ubVU{||SKJŠ}|[[TultŠƒ}ƒ||zllllktts‚utƒ„„uzt\UZMSSMSS|„…UTSUTS\[[ult\[b|„…“Œ”{||{||››”ƒ„„ultedkddc‹„„‚v{{{t”š”{||œ¤¦ŒŒš‹…š{||mttª³·Œ‹“¦§¨ª³·“Œ”‹‹‹Œ”•”š”ƒ‚u‹’Štt{llk{|||‚zf]ccbVtllmtt“““|‚z\UZ‚v{jV[sle[[Tkd\{||ttstts{tt‚|u””‹ztlkd\š””tts“Œ”„„Škd\‹‹„r]g‹‹‹tsl‹‹‹‹„‹Œ‹“sle‚ut|„…ƒ|||‚z“Œ”‚ut|‚ztts£››ƒƒ|£››¤¤“Œ”lrimtt‚utœ››|„…{ttek]JHFJHFFD;JHF{||MSSMRKƒ}ƒJHF|‚zƒ„„‹‹„‘Œ…dc\ƒ„„UTSyfllekf]c“““mttred‹…’llkŒ”•tts‹„„{tt‹’Štllœ¤¦ƒƒ|‰ƒv{zmŠƒ}››”›¢›¢—“Œ”{ttŠƒ}²««MRK:97£››{tt‚|usreSKJsrezll{{t‚|u‚|ubVZsrekk]SKJrfk’…‹Š}ƒ‹’ŠŠƒ}lks„„Š|‚zedkUTSƒ||”››™š¤š””Œ”•‘…„¦§¨œ¤¦œ¤¦››”|„…lri‘Œ…’…‹tllddcrfkf]cultš””£››{u{‹‹„{{t|‚zddc‹„‹f]c‚|u”“›…‹‹lri|‚zrfk{{t‹„„’ŒŒ„Š„{tt’ŒŒtslzllƒ‚uzll‘Œ…ƒƒ|ttsb[Ullkdc\ƒ‚uVTLd\\‹„‹f]cddcekdf]cf]c|„…£››Š}ƒtsl’ŒŒ{tt‚v‚{tt‹’Š„Š}lldSKJtllbVZztf“Œ”Š}|ultdkVƒƒ|zllƒ„„œ››‚v{{{t‰ƒv{ttred{{tƒ}ƒult{|||„…ultllk>ECMSSUTSllkddc…‹‹{{ƒmttfkkƒ„„{tt{||ekd{||f]clksddctlltll{{tœ››”››„„Š”“›ult”››ultŒ”•ƒ}ƒ›¢›ÌÖЦ§¨¦§¨™š¤”››‚|uuzt“Œ”Œ”•”“›sreœ››ƒ„„ƒ||‘Œ…{{tƒ„„ƒ„„ƒ||‹…’{{t{{t²««{tt„Š„{||ttsztl„Š„{ttkd\ƒƒ|ultƒ„„{||lld…‹‹›”›’ŒŒƒ||ƒ}ƒ{{ƒ…‹‹‚|ulddult|‚ztzlƒ„„œ››Œ‹“’ŒŒ“Œ”ztlƒ‚uztl{ttyfl…‹‹lddtll{u{VTL\[[FD;F=CUMRd\\ƒ„„[[TZbNedkUTS™š¤Œ”•µ¶·‚|u{{t{||rfkƒƒ|‹‹„|‚zƒƒ|ttstslŠ}ƒlriu{{]cd„„Š™š¤“““{{t“““{{t‹„„‘Œ…kk]‘Œ…{{t‚ut£››tll{zm²««llk7-2ŠŠ}””‹ƒ„„””‹cbVkd\‚wlƒƒ|tzlœ››yfd{||SKJPF=ƒ„„„Š„‹„‹‹’Škd\Œ”•|‚z{{ƒ]bZztld\\|‚zŒ‹“‹„‹tsl“Œ”ƒ}ƒ„Š„…‹‹„‰vœ¤¦„„Šd\\››”’ŒŒlldf]cŒ‹“{{ƒ‘Œ…rfktlllks›”›‹’Štts¦§¨{{ƒƒ}ƒtsl‹‹„MRKlks‹‹‹{tt{zmtll{||ƒƒ|””‹[TTredkd\Š}ƒƒ‚uddcƒ||ƒ||u{{lldbVZ[[Tek]\[[{u{leklekŠ}ƒ|‚zultsleekdtllkd\redllksleuztcbVlldFD;lekj]\ztl‰|v{tt‹„„ƒ||ƒƒ|“Œ””››ƒ}ƒult“““ƒ||i\Vredrfkult{ttultlrifkklld|‚z]cdmttultuzt„Š„ult^^qf]cƒ||ƒ}ƒfkk„Š}ƒ||”››uztf]c‹„„‹„„{||‹’Š“““|„…f]ctlltslddc¨©´„Š„¨©´¦§¨“Œ”˜Ž£lri„Š}ƒ}ƒ{||{tttt{ultlddzlluzt£››‹’Štzl‹‹‹{u{‰v|ƒ}ƒddc‹‹„›”›lldlldƒƒ|™š¤‚utƒƒ|‚ut‹„‹slekd\ult¦§¨ƒƒ|kd\{{t‚wl‹…’£››ƒ„„ƒ„„‚|u’…‹…‹‹lriztllekƒƒ|ƒ}ƒ£œ¥”››tll„Š}‹’Š‹„„“Œ”lld“Œ”Š}|Œ”•kd\VZTVTL:97UMR{zmekdUTSFD;MRK]bZ|‚z””‹””‹sle{{t|‚z{{t‹„„Œ‹“ztl{{tllkd\\sle|„…ttskk]llkldd‹‹„lektsl‹’Šztl{tt‹‹„{zm‹’Š‚v{Šƒ}ƒ||ŠŠ}²²¬VTL*)(œ››tzlœ››ljcbV|‚zzll””‹tzlkd\sreŠ}|74,D;9{{t”š”ƒ„„œ››tll„Š}{||ƒ}ƒ„Š„ƒ„„ultœ¤¦“““¤¤‘…„jV[yfd|‚z”››””‹ƒƒ|„Š}Š~‹ƒ||‹„‹tslƒ}ƒƒ}Šµ¶·””‹šŒµ¶·¦§¨{{ƒƒƒ|tt{œ››¨©´’ŒŒ[[Tddcek]slettsƒƒ|ª³·‹‹‹{zmultsle\[[kd\tslVTLƒƒ|{{tlddlddulttll‹‹‹JHFultred’ŒŒtsl{{ƒbVZmttlri‰v|mttkd\kd\dc\‹’Š›”›|‚z„Š}{{ttslUTS{{t{ttljtlltll{u{’…‹‹„‹tts‹‹„’ŒŒ„Š„ultredlddkd\{ttult{||edkultJHFmtt\[bfkk{tt|‚z„„Š…„’ult|„…{||‚v‚UTSdc\“““Œ‹“llkŒ”•‰|v‚v{Œ”•‹‹‹u{{mtt{{ƒ“Œ”Œ”•‹‹‹ƒƒ|‹’Š{{ƒ””‹‘…„£››‹’ŠŒ”•ƒ}ƒ‚v{{tt[[T‚|uƒƒ|¤¤ƒ||’}™„Š}|‚z“Œ”‹„‹Š}|”“›››”{zmƒ||{{tmttttsƒ„„zllƒƒ|›¢›uzt‹„„’ŒŒd\\{{ttslztf|‚ztslƒ}Šƒ}ƒtslsle””‹ƒ}ƒ{u{kd\d\\””‹››”„„Š„Š„ƒ}Š„Š„ekd”š”“Œ”rfkJHFƒ||bVUlekb[USKJJHFFD;MRKSKJVTLJHFƒƒ|\UZ|„…f]cƒƒ|‚|uŠ}|llk…‹‹ekdƒ||lri{||kd\MRKred{|||‚ztts‹‹„ƒ||ultu{{{||…‹‹{||kd\‚|u«²«„Š}ŠŠ}{{tsle‚|uŠŠ}µ¶·JHF-1+|‚z“““‘Œ…rg]kk]jcV‰ƒv”š”b[U‹‹„ƒ„„b[UVTL3+*‘Œ…„Š„‹…’ttsVTLƒ}ƒtts|‚zmtt£œ¥””‹tt{‹‹‹›”›¦§¨œ››ƒ}ƒ”“›llktt{¦§¨¨©´£››‹„‹{tttslf]clkstsl“Œ”‹…’{{ƒƒ||‚v‚”š”¦§¨„„Š‹„‹Œ‹“‹‹‹ultttsdc\f]c‚ut„„Šƒ||‹‹‹redi\Vkd\zllVTLldd{||[[Tllkƒ||ttssredc\ƒ„„bVUttsSKJƒ}ƒultllklriœ››redztltsl„Š}d\\ztlƒ„„{tt’ŒŒdc\‹’Šd\\”š”‚|uztlŠ}|cbVkk]kd\“Œ”ƒ||ƒ„„Š}|””‹’ŒŒ‚wl“Œ”kd\ult{{ƒultƒ„„lldfkk|„…JHF\[btlluzt‹„„„„Š{{ƒ}|’Œ‹“{{t{u{”š”’ŒŒƒ„„ddcƒ„„tll„„Š‹…šœ››Œ”•{||”››’ŒŒlriŒ‹“”››{tt|„…|‚zƒ||›”›””‹ƒ}ƒ”“›edk…‹‹|‚z“““‹‹„sle…‹‹lek¦§¨{||tslƒ„„ƒ}ƒŠ}ƒ{{t{{t“““{{t|‚zdc\‹‹‹rfkœ¤¦””‹’ŒŒ‹„„Š}ƒ‹„„{||‹’Š‘Œ…llkƒ„„’…‹ult|„…‹„„‹„‹›”›Œ”•{{tslett{”š”‹„‹“““{{ƒƒƒ|””‹‹‹„Š}|bVZlldlekztluztkd\D;9VTLFD;[TTsleUTSf]c&&\[b„Š„‹‹‹‹„‹‚|u‹‹‹‹’Š…‹‹Š}ƒŠ~‹””‹sleƒƒ|ƒ}ƒ‹„‹ƒ}Šlld‹‹„ztlttstts‹‹„“““‹’Š”š”‚ut‹‹„lld‹‹‹ƒƒ|‚v{yletslƒƒ|¦§¨:9774,ƒƒ|ƒ‚u{{t‚|urr]rg]‘Œ…tslyle{u{ƒƒ|ƒƒ|VTLSKJŠŠ}œ››ƒ}Š¦§¨ƒƒ|ƒ„„„Š}tt{lri‹’Š£œ¥uzt…‹‹“““””‹£››‹„„ult|‚z«²«|„…ƒ||‘Œ…™š¤›¢›…‹‹dc\Œ”•ƒ„„d\\[[TUTSrfkldd‹‹‹|„…ƒ}ƒ“Œ”Œ‹“™š¤“““„Š„j]\“Œ”b[U“Œ”{{t‹„„š””‹’Škk]{ttƒƒ|kk]uzt|‚ztts“Œ”f]c{{tsletslƒ}ƒd\\‚v{|‚z{{ƒultƒ„„’ŒŒ‹‹„{||Šƒ}Œ”•uzt‹‹„‹‹‹¦§¨{||jcV\[bƒ||{u{”š”‹„„š…Žult‚ut{{t‹‹‹‹‹‹tllŠ}|Šƒ}‹„„{u{ƒ„„Œ”•”“›f]cƒ}ƒ‹’Šlri|„…lri]cd\[[ekd…‹‹‹„‹tt{{{ƒ…„’‹‹‹tsl{u{{||ƒ||„„Šƒ„„ekdtllŒŒš†~‘llk„„Š…‹’“Œ”“Œ”„„Š„Š„Œ‹“’ŒŒ“““‚wlult‹„„µ¶·Œ‹“…„’‚wlult|‚z„Š}ƒƒ|ult“““ult{tt{{t{ttƒ„„“Œ”£››ƒ||sle’ŒŒtsldc\{||œ››lek{{t{{tŠƒ}‹„„“Œ”£œ¥¦§¨“““¦§¨ƒ„„ƒƒ|“““tll‹‹‹‹„„„„Šmwmttd\\mttztl‹‹„{u{š””’…‹{{t‹’Š|„…‹„„redlldtllŠ}|‘Œ…rg]uzttygC8.dc\[TT‹‹‹ldd\[bmtt„Š„”“›\[bkd\rfk…‹’{{t[[T‹„‹|„…š””‹‹„ttsŒ”•‚v{’ŒŒ{{tslellk”“›””‹‹„‹¦§¨‹’Š£››››”ƒƒ|‹’Š¤¤‹„‹ztl››”‚utü¿SKJ:97kd\kjVŠƒ}ztlkd\ŠŠ}d\\tsl|‚zuztƒ}ƒ{zm[TT‹„„{zmuzt”“›£œ¥ƒ‚u£œ¥ƒƒ|b[U£œ¥{||{u{Œ‹““Œ”{{ƒ{{t’ŒŒ‘Œ…››”Œ”•{||‹’Š”“›””‹£››tts\[[ek]|„…u{{ƒ‚ulksult{{t{{ƒƒ‚uu{{”“›’ŒŒ“““„„Š‚ut‹‹‹Œ”•ƒ}ƒ‘Œ…”“›“Œ”ª³·ƒ||b[Usreƒ||sreŠƒ}tt{ƒ||‚|u“““ult{ttsretzlŒ”•d\\lrir]Z|‚z‚ut“Œ”‘…„‹‹„œ¤¦tts{{t‹„‹{{ƒ{ttek]tslkd\d\\tll‹‹‹£››‹„„¦§¨››”tlllddf]cƒƒ|llkŠ}|„Š„ƒ||ldd£››sreƒ}ƒ{{ƒ“““ƒƒ|]bZ…‹‹„Š„{||…‹’{u{|‚z|„…ƒ}ƒmtt{||…‹‹|‚z‹„„ttstt{ƒ}ƒtllultƒ„„ldd£œ¥™š¤¨©´œ¤¦“Œ”“Œ”š””¦§¨«²«‹‹‹ƒ„„ƒ‚u¦§¨‹‹„‹’Š‹„‹‹…’f]c„„Štts››”””‹››”µ¶·‹…’tzl‹‹‹””‹|‚zŠ}ƒ‚ut{||ldd’ŒŒ””‹|„…{tt{{t„Š„{zmuzt””‹›”›“““£œ¥”“›œ››””‹{u{ƒ||{tt›”›ttsƒ}ƒlddldd{{t[TTllk‚|u¦§¨ƒƒ|”“›ƒ}ƒu{{‹’Šƒ„„’ŒŒ‹„‹‹„‹Š~‹ztf{{tsleŒ‹“kk]D;9ult{{ƒ|‚z…‹’mttUUYƒ„„d\\fkkzll‚|u›¢›ƒ„„uztƒ}ƒ{u{’ŒŒ‹‹‹\[[‹„„Š~‹ddc]bZ[[Tddctsl‹’ŠŒ”•Œ”•tslb[Uƒƒ|{||””‹¤¤“Œ”£››‚v{ztl¦§¨[[T74,››”„Š„{zmŠƒ}Šƒ}|‚z{zm|‚zllduztœ››‹‹„ƒ|||‚z‹„„Œ”•Œ”•“““ztlldd[TTddc|„…{u{{u{’ŒŒ‹„‹”››Šƒ}Šƒ}„„Šƒ„„VZ[u{{…‹‹¦§¨‹„„ƒƒ|ldduztdc\lksŒ”•lriŒ”•ult‘…„{tttsluzt”“›Œ‹“{{ƒd\\œ››‹’Š‹„‹ƒ}ƒ‘ˆ}ultŠ}ƒzll{ttœ››lddœ››››”Šƒ}{{t{{ƒlddtsl{||ƒ‚uƒ||kd\‚|uultj]\tllllkrfk‹‹„ƒ||{{tœ››ƒƒ|›”›{ttlld|‚zrfkj]\‚v{mttƒ}ƒlekrg]Š}ƒ‘…„‘…„ztl“Œ”›¢›‘Œ…tsllddƒ„„{tt{{ƒƒ}ƒredƒ„„„„Šuztkd\b[Utts{||{{ƒ„„Šƒ„„|„…{u{~’“mttlks[[T{||llkdc\rfkmtttt{|„…””‹ƒ}ƒ“Œ”f]c‹…’™š¤£››››”Š~‹tsl‹’Š{{ƒtt{‹‹‹{zm””‹£››ƒ„„¦§¨ƒ}ƒŒ”•‹‹‹‹’Š””‹œ››™š¤Œ‹“‚|uœ¤¦‘Œ…{||“““‚v{ƒ}ƒ‚|uŠƒ}lldƒƒ|lld‚ut¤¤‹‹„”š”‚ut‹„„›”››”›‹„„tts›”›š””‚utƒ„„“Œ”Š~‹mw„„Š{ttƒƒ|ddc“““ƒƒ|››”lks”š”{u{…‹‹|‚z”››“Œ”‹„„ƒ}ƒ‹„‹ƒ||d\\sred\\|‚z‰|v™š¤ttsŒ”•\[b>B9f]cJHFtll{||uztkd\tsl{{ƒŠ}ƒ“Œ”„„Šš””|‚z””‹„Š}›¢›{||lld{{t\UZmttƒƒ|‹„‹llktslSKJVTLkk]kk]{{tš””Š}|’ŒŒtll¦§¨VZT-1+‹‹„””‹ƒ||‘…„‚|ukd\tzlVTL[TTllkŠƒ}ƒ‚ulrilks{{t|‚zlksƒƒ|sre‹‹‹[[TUTSUUYƒ}Šzllœ››£œ¥”š”››”ƒ||‹‹‹lri|„…cbVŒ”•…‹‹‹…’slettslrikk]lddlkstts|„…”“›‚|u[[TŒ”•„Š„ttsekdldd„Š„tt{„Š„„„Š‹‹‹[TTztltts{u{‚ut|‚z”š”””‹ƒ‚uƒ‚u‘Œ…‹‹‹tll‹„„{u{lddkk]‰ƒvlddredbVUtlllldƒ}ƒtt{ƒ||ƒƒ||‚zƒƒ|b[Utts{{t{u{Œ‹“sleSKJd\\d\\„Š}sleldd[TTddc’…‹ek]‹‹‹„Š„“““‚ut‹‹„llk{u{{{t””‹„„Š[TTkd\|„…slelrimttlek|„…ƒ||‹’ŠŒ‹“{{ƒ…‹’{{ƒ{||llk{|||‚z’…‹‹…’|„…{||ƒ||{u{ƒ}ƒ‹‹‹{{ƒƒ}ƒ¦§¨›”›ƒ„„|‚z„Š„ult¦§¨”››’ŒŒ“““{||”››{{ƒ‹‹‹|‚zlld„Š„ŠŠ}‹’Š{||›”›“““„Š„¤¤“““Š}|{u{{u{ƒƒ|””‹ƒƒ|tslœ››¤¤ƒ||ƒƒ|””‹{zm””‹d\\f]c‹‹‹„Š„sle{||Š}ƒ››”“Œ”{u{”“›£œ¥””‹uztbVU|‚z‹‹‹kd\‹‹‹tsl…‹‹“““|‚z”››œ››’ŒŒ]bZ‹„„š””tll„Š}Šƒ}sletzl{{ƒlddtzltt{SKJJHFFD;llk|‚z››”tsl|‚ztt{sle“Œ”ztl{u{kd\Œ”•‹„‹ekd{u{[[TbVUtts|‚ztsltt{lldlrib[UaWMcbVdc\tslŒ‹“ƒ}ƒtsl‰|v’ŒŒJHF3+*ƒ}ƒ””‹‚|u‚wl””‹tsltslsletll„Š„lriƒƒ|u{{sle“““{||ddclri‘Œ…\[[ttsf]cUTSzll“~ˆ{u{’ŒŒ¦§¨sreƒ||’ŒŒŒ”•mtt|‚zf]cttssle¦§¨ddctsl:97ek]VTL[[T‹‹‹ttslri{||ƒƒ|{||“““”››”“›„vŒƒ|||‚z‹…’{u{zll‚v{‹„‹„Š}ult„Š„‹„„‚|u‹„„ztlœ››‹‹‹ƒ„„ult”“›‘Œ…sreyfd‹„‹sleredd\\kd\bVUtts‹‹„sreƒƒ|’ŒŒ‘Œ…]cddc\{||ttsredredUMRd\\…‹‹‚|ud\\yleŠ~‹‚|uƒ„„‹„„‹’Š{tt‹„„„Š}{u{ttsreduztƒ}ƒtll‹’Šƒ„„{u{\[b]cdyl„lksƒ„„|„…”››|„…Œ”•ƒ}ƒ’…‹llkƒ„„{{ƒ„Š„“Œ”ƒƒ|ƒ„„ƒ}ƒ›”››”›“““”“›Œ‹“››”›”›Š}|‹’Š¦§¨”››|‚ztsllld‚|uƒ„„„„Šult’ŒŒ‹‹‹|‚zš””›¢›‹‹„\[bƒ}ƒ{tt|‚zsleœ››ult‚|u‚v{Šƒ}š””tslƒ„„ŠŠ}{zmsle‹‹„ƒƒ|‚|u’ŒŒ£œ¥‹„„{u{ƒ„„‚utlldŒ”•{{t¦§¨ultƒ||ƒ}ƒ‹„‹ƒ„„ƒ||¤¤tts‚|u‹„„”š”dc\tt{”››¦§¨œ››£››Œ‹“Œ”•’ŒŒzll|‚zj]\[[TŠ}|SKJ‹„„ŠŠ}SKJVTL[TTlrimttddc‚wl{{tu{{Œ‹“tt{ƒ||{u{‚v{b[Utsl„Š„{{ƒŒ”•Šƒ}lldlekƒƒ|‹’Šultttstsl‚v{{zm¤¤tsl””‹››”‹‹‹“““{tt«²«JHF*)(ƒ}ƒuztƒ||f]c‚|udc\‚|ulritllUTS‚|ulri”š”““““Œ””š”Œ”•‘ˆ}SKJ‰ƒvlldekd\[[UMR{tt£››‹„„£›››¢›œ››Šƒ}™š¤‹’ŠlksŠƒ}ƒ„„‹’Š{{tred„Š„lldSKJ{||tslŠ~‹uztlri™š¤ƒƒ||‚z™š¤…‹’”“›”“›ƒ||¦§¨œ››ultƒ||zllztlŠŠ}£››dc\ƒƒ|Šƒ}’ŒŒrg]£œ¥ƒ„„|‚z”“›d\\tlltsl{ttƒ„„rg]ultSKJ{||ƒƒ|{{tsre{{t‹‹‹‘ˆ}ƒ||tsld\\mttƒ„„{ttƒ„„‹‹„ƒ„„slešŒldddkVbVU{||”“›{||mtt‹’Š‹„„uztllk{{ƒ‘Œ…ƒ}ƒŒ‹“lld{||[[TbVU\[bd\\\[bedkƒƒ|]bZ…‹’u{{Œ”•„„Š‹’Š|‚ztts‚|u{u{¦§¨ƒƒ|ƒ}Š{{ƒ¨©´¦§¨ƒ„„¨©´„„Šzll{u{„Š„|‚z‹‹‹”“›leklld””‹[[TlldŒŒš{{ƒ|„…„Š„|‚zztlœ¤¦‚utVZTƒ}ƒ””‹ŠŠ}››”“““£œ¥š…Ž{tt[TTkd\ek]‹’Šƒ„„‹‹„Šƒ}‹‹„‹‹„Š}|‘Œ…‹„‹ƒ}ƒŠ}|ƒ„„Œ‹“„Š„ttstslš””ƒ||„Š„››”“““‹’Š{u{‹’ŠŠ}ƒƒ||ƒ||„Š„ƒ}Šƒ||‹’Šƒ||”š”‚|uƒ„„”“›bVUƒ||rg]ztl|„…ult[TT{{tƒ„„slelrif]c{{ƒldd{|||‚z“““{{t‹‹„{||d\\f]ckd\VZTtts{u{¦§¨{tt‚v{‹’Š“““lksƒ„„”››‹’Šƒ„„šŒ¤¤›¢››¢›«²«£œ¥›¢›¦§¨‘Œ…””‹VTL*)(sreƒƒ|lriztl‚|uVTL””‹{{t‘Œ…„Š„ƒ}ƒ”š”‹‹‹{tt[[T|‚z„Š„‹‹„b[U£œ¥{tt]cd…‹‹£››’ŒŒœ¤¦‚ut“Œ”ƒ||ƒ}ƒƒƒ|ƒ}ƒ…‹‹z‚lŠ}ƒ„‰vsle[TTUTScbV‚|udc\‹„‹ŒŒš™š¤{||ƒ‚uƒ}ƒ›¢›u{{‹‹‹“““”››‚v{ƒ}ƒtsl£œ¥ƒ}ƒtll‹‹‹‚ut|‚z‹’Šek]zll{zm››”‰ƒv{{tuzttll‰|v„„Šƒ}ƒbVUztl›”›sleredƒ}ƒlddŠ}ƒsle””‹ƒƒ|llddc\””‹{ttllkd\\{ttkd\tll|‚zj]\”››Šƒ}ƒ}ƒ‘Œ…{ttŠƒ}šŒllk‹’Šllkƒ||‚v{ƒ}Š””‹tllŒ”•{{ƒ“Œ”tts„Š„tslmttf]c{{ƒmtt“““uzt{{ƒ|‚z|„…Œ‹““““{ttVZ[{ttŠƒ}uztŒ”•‚v{Š~‹…„’ƒ||tll“““”“›””‹‹„„’ŒŒœ››Œ”•{||ddc‚v{‹‹„Šƒ}”››‹‹„“Œ”™š¤Œ”•‹‹„”š”¤¤››”dc\{||£››’ŒŒ””‹’ŒŒrfkŠ}ƒš””Šƒ}ztlŠŠ}tsl„Š„œ››ztf{{t{ttkd\sle‹„„”“›‚|u|‚zultŠŠ}‹„‹‹„„‹„„··Ä‹‹„£œ¥Œ”•ƒƒ|‹„„j]\ƒ}ƒŒ‹“red„Š„™š¤¦§¨Œ‹“”“›‚|utsl¤¤{||‚utlldtzl…‹‹{{tSKJ‚utVTL{{t’‘~f]cJHFlrittsŒ”•ŠŠ}“““‹‹‹”š”ultj]\ƒ}ƒ’ŒŒllktsllksƒƒ|“““’ŒŒ”š”{zm„Š„{{tƒ}ƒƒ„„tsl››”‹’Š””‹›¢›’‘~²¬µµ¶·µ¶·¤¤¦§¨\[b)+2Šƒ}””‹ƒƒ|››”‘ˆ}dkV‹’Š‚|u‹‹„‹‹‹Š}ƒsreVTLsle‚|uŒ”•lrimttztl‹‹‹|„…\[[lrizll’ŒŒ‚|uuztVTL¤¤“Œ”šŒ“Œ”‹„‹lld“““”š”“Œ”Šƒ}‹„„lri‹‹‹f]ctsllri{{ƒ™š¤¨©´‹‹‹”š”…„’{{ƒ{u{‹„‹™š¤tllsleŠƒ}{u{‹‹‹‹’Šƒ}ƒsle{ttj]\„Š}ldd{zm‚|u””‹ƒ||‹‹‹sle‹„„„„Šdc\‰|vj]\‹‹„“““‹„‹]bZŒ‹“”››tll{{t‹’Š{zm‹„‹{u{‚|u“““Œ‹“kd\’…‹ttsedktlllddsleztf{u{ƒ||‰ƒv{tttsldc\‚v{‚|u{u{ƒ‚u›”›””‹edk{u{ƒ„„ttslldult{{t{||™š¤|‚zuzt|„…Œ”•|„…|„…|‚zlksu{{{zmƒ„„lekŠ}ƒtt{ƒ}ƒ““““““Œ‹“Œ”•‹‹‹£››ultlksƒƒ|ƒ„„„„Š{||‘Œ…”š”š””‹’Šƒ„„„„Š|„…ttsŠ}ƒ‘Œ…‹‹„‹„„{{ƒultœ››”“›¦§¨›”››”›yfl‚|u””‹‘Œ…””‹sre””‹ŠŠ}„Š„‹‹‹yfdztl‚|u‚|uƒ„„‹’Š‹‹‹‹‹‹‹„„{ttœ››’ŒŒ‹„„|‚z|‚zrfklri{ttult“Œ”¦§¨¦§¨›”›‹„‹ƒ„„|„…›¢›‹‹‹{tt‹‹„{{tš””uzt„Š}lldztfVTLSKJsleuzt[TT:97f]cmtt\[[lri”š”™š¤{{tmttƒ}ƒ“Œ”{u{¦§¨„Š„ƒƒ|“Œ”‹’Šƒƒ|‹„‹„Š}ek]tlltt{[TTƒ„„“““””‹ƒ‚uŠŠ}”š”¦§¨™š¤£œ¥››”¦§¨¦§¨JHF*)(‹‹„‹‹„lri‘Œ…ztliq]‹’Š‹‹„‹‹„lld{u{VTLtsld\\ƒƒ|ƒ„„uzt™š¤ƒ||uzt‹’Šu{{u{{tll‹„„œ¤¦ulttts{||£››¤¤œ››Œ‹“‘Œ…rfk“Œ”š””œ››‹„„ƒ„„ldd\[[{{t„Š„{ttƒ„„“Œ”tt{ƒ„„u{{|‚zultœ››red‹‹„²««ƒ||{{ƒ“““tll‹„„b[U’ŒŒ{||tts{zmslei\VŠƒ}{tt‹„„‚utddcddckd\‚|ud\\„Š}tllƒ||zll‘…„UTStll|‚z””‹ƒ‚usle“Œ”{u{ttsŠŠ}Šƒ}{||{ttƒ„„f]ctll‚wlš””lldsleƒ|||‚z‹‹‹”š”›”›‹‹„“““{u{ultttstts{ttƒ||ƒ||‹‹‹lksƒ||lriu{{|„…„„Š„„Š|„…VZT]cdu{{{{ƒ]bZ‹’ŠŠƒ}™š¤’ŒŒ{u{tll“Œ”lri‹’Š„„Š™š¤¦§¨Š}|sleƒƒ|ulttts‹‹‹£œ¥””‹‘Œ…«²«””‹Œ‹““““{{tJHFztl{{tŠƒ}ultŠ~‹tll‹„„£›››”›£››Š}|‘ˆ}lj²««lri‹‹„{zm‹’Š””‹ƒ„„Š}|zllkd\šŒ‹„„‹‹‹|‚zƒ||UTS{tt{||š””’ŒŒ‹‹„‹„„tll\[[Š}|{tt{u{’ŒŒŒ‹“‹’Šƒ„„‹„‹Œ”•œ¤¦‹’Š“““¦§¨ƒ„„œ››“Œ”|‚z]cdztlVTLSKJŠƒ}…‹‹Œ‹“MRKSKJuztd\\mtt‘Œ…„„Š‹„‹“Œ””“›“Œ”›”›œ››‹‹‹ƒƒ|tt{|„……‹’ƒ}ƒ‹’Šƒ}ƒ‹‹„ttslkstllƒ„„š””tsl›¢›{{t‚|ullkƒ||ttsƒƒ|¦§¨MSS*)(cbV„Š}Œ”•{{tƒƒ|cbV’ŒŒdc\‹‹„sreŒŒšztlekdldd‚|u‹’Š‹’Š¦§¨¦§¨¦§¨|‚zJHF¦§¨ƒƒ|[TTred[[T‹’ŠŠ}ƒœ››‹’Š²««Š~‹{zm””‹llk’ŒŒ{{t‚ut…‹‹„Š}|„…›¢›”››{{ƒlksƒ}Š|‚z„Š„…‹‹‹„„™š¤ƒ}Š‚wl””‹‚v{Œ”•yflf]clld{||‹’Š‚|uddcdc\uztb[U‹‹‹ƒ||{||²««Š}|ƒ„„tllkd\„Š„lek‚ut{ttƒ}ƒtt{ƒƒ|lektll„„Š„Š„ztlrg]”š”tts{u{lld‚v{{{tddcVTLƒ||ƒ„„‹’Šultƒƒ|sleiq]]bZlri’ŒŒ›¢›Šƒ}Œ‹“\[[‰v|sleƒ||’…‹{ttœ¤¦”“›“Œ”{{tu{{u{{fkk“Œ”ƒ}ƒmtt{{ƒ\[bŒ”•tsl„Š„{{tkd\lekultddc{u{UMRuzt‹‹„uzt›”›¦§¨ƒ‚u”š”Œ‹“…‹‹{{tllk¦§¨‘Œ…“““µ¶·ƒ„„{u{’ŒŒiq]‹‹„tllŠŠ}‹‹„‹„‹ƒ„„šŒ{{ƒ‹„„’ŒŒš””’ŒŒ²««Šƒ}{tttslƒƒ|ttsuztŠ}|ƒ||b[Utsl››”š””Œ”•„Š„uzt“Œ”„„Š{u{ƒ||ultƒ}ƒ‹„„{ttedk’ŒŒSKJsle¦§¨tt{ƒ‚u“““œ››“Œ”„Š„‹‹‹¤¤š””””‹Š}ƒ¦§¨…‹‹sle‹‹„cbVrr]SKJdkVŒ‹“Œ‹“MRKf]ctzlmwekdŠƒ}ƒ„„›”›‹’ŠŒ‹“”“›“Œ”ldd”››„Š}tts‘ˆ}…‹‹£œ¥‹‹‹ƒ„„{||Œ‹“ƒ„„‹‹‹“““tll|‚z{{ttslztlƒ„„Š}ƒƒ„„ult²¬µ[TT*)({{t¤¤„Š„’ŒŒšŒlks{zm{ttƒ||{{t„„Šuzt‹’Štslyle””‹{{t‹„‹””‹”››Œ”•|‚z¨©´²««ult‹’Šuzt{||f]c””‹{tt››”‹‹‹¦§¨›”›mtttlltzlttssle]bZ„Š„ƒ„„„Š}lri\[[™š¤\[[uzttt{tts{ttƒ„„£››ƒƒ|uzt¦§¨ttslddb[U‹‹„|‚zƒ„„ddc{{tlriztl“Œ”ŠŠ}‹‹„š””ztlttsztllddb[U‹„‹‚|uslekd\{{tŠƒ}’ŒŒ“Œ”|‚z””‹{||›¢›„Š„{{ƒ””‹‹‹„j]\ƒƒ|VTLtll“““|‚z¦§¨{u{“““š””””‹ttsllk{{tŒ‹““““œ››tllztl|‚z’ŒŒ£››ƒ}ƒ¦§¨tlledku{{ddc|‚z|„…”“›ekdmttmtt|„…ƒƒ|tll“““ztlztlultult…‹‹ttsƒ}ƒ‹‹‹‹„„Œ”•£››¦§¨‚v{ƒƒ|”“›œ››Œ”•ŠŠ}¨©´¦§¨›¢›¦§¨›¢›¦§¨‹„‹ƒƒ|ƒ„„{{t‹‹„{zmœ¤¦{{ƒlddƒ||‹„„”“›“~ˆš””œ››‹„‹‚|u‚|udc\›¢›””‹ƒ||‚|uƒ||£››Šƒ}„Š}ƒ„„‹‹‹””‹ª³·„Š„u{{ƒ}ƒš””ƒ}Š{||““““““…‹‹ƒ||tll‹„„tts£››ƒƒ|lddedklld‹‹‹””‹ztlkd\“““£œ¥¤¤ƒ„„‚|ukk]b[U{tt‘Œ…”››†~‘mttƒ}Štts{||llk‹‹„VZ[{ttƒ||“Œ”“Œ”‹…’mwmttuzt{||¦§¨ƒ„„ƒ||Œ”•Šƒ}‹’Šœ››„„Š‹’Šddcƒ||””‹[[T{u{{zm£œ¥{{ƒƒ}ƒŠ}|”š”LKR)+2ƒ‚u‹’Š“““d\\Œ”•Š}ƒ‚|usleuzt””‹tt{‹„‹VZ[VTL‹„„„Š}\UZ‚|uƒƒ|…‹‹u{{|‚z…‹‹”“›£››‹‹‹lriuztcbV‚|u’ŒŒ‹„„„Š„››”„Š„„„Š‹’Šƒƒ|ƒ}ƒƒƒ|tsl\[[|‚zu{{‚|ulks£²u{{”š”œ››tzlŒ‹“|‚z“““’ŒŒƒƒ|‹‹„ztl{u{{{tœ››lritts‰ƒvtslsleylelrirg]¤¤ztl‚|uƒ„„ultƒ}ƒztlcbVf]cš””d\\‚|u{zmŠ}|{u{lldtslddcƒ„„|‚zƒ‚u””‹ƒƒ|tsl{||d\\sle‚|u{||sre‚|u‹„‹‘Œ…d\\‰|v‹’Škk]tlltsl‹‹‹uztŠƒ}sreŠŠ}ƒƒ|‹„‹„Š„ƒ||{u{„Š„Œ”•{{ƒ”››„„Š|„…ttsŒ”•|„…‹„„‹‹‹„Š„ztlƒ„„Š}ƒƒ„„{||‹’Š¦§¨”š”œ¤¦¦§¨¦§¨£››µ¶·²««‹’Š“““‹„„Š}ƒ¤¤µ¶·ª³·””‹¨©´‹’Štt{sreŠ}ƒ’ŒŒš””ddctslult›”›{{ƒ‹‹‹ƒ}ƒ›”›‘…„‹‹„tll››”|‚z|‚z¦§¨™š¤‚|u„Š}‘ˆ}››”””‹yle‹‹‹‹‹‹{||¦§¨‹’Šllk„„Šƒ}ƒ“Œ”‹„‹£œ¥‹’Š‹’Šf]cred…‹’ldd”››ldd|‚z’ŒŒ”››¤¤ƒ‚uultdc\£››ztl”š”‹‹„|‚z‹‹„VTLš”””š”‹’Š{u{Œ”•lek{{t‚v{llk‹’Šu{{‚v{lekƒ}ƒ‚v{‹„‹ƒƒ|{tt|„…llk¦§¨Š}ƒ’ŒŒƒ„„¦§¨‹‹‹™š¤‹’ŠŒ”•‹„‹ƒ„„Šƒ}kk]ult‘…„“Œ”›”›f]c[TT¤¤JHF:97sreƒƒ|‹„‹”š”‹‹„{ttƒƒ|[[Tb[Uƒ||‹„„Œ”•lldtlllrilld[[T|‚zƒ}ƒtzl{||mttƒ„„{{t››”‰‘~ultƒƒ|‚|u‘Œ…’ŒŒƒ||ƒ}ƒtslœ¤¦|„…‹„„dc\\UZ\[[{{ƒddcztlVZ[ztlƒ}ƒŒ‹“}‡’„Š„|‚z“Œ”ƒ}ƒlriddcŠŠ}{{tœ››sreƒ}ƒ{||‹’Š|‚z{ttdc\ttsƒƒ|lldkk]ztlSKJi\V[[T{{ƒek]ƒ||‹’Š{ttzll{ttj]\ƒƒ|zll“Œ”‚utztlœ¤¦llk{tt{||ƒƒ|ztlŠƒ}zllllkdc\lldultUTS‚|ub[UsleŠƒ}sre››”‹‹‹ƒ||””‹{{t“Œ”|‚zŠƒ}‘Œ…“““{{t“Œ”{||\[[{u{{|||„…]cd|„…‹„‹{||ƒƒ|¨©´‹‹‹{{t{u{{zmŠƒ}‘…„zllƒ„„red‹‹‹‹‹„”š”Œ”•|„…“““‹‹‹£››””‹„Š„¦§¨¦§¨›¢›¤¤²««‹‹„”š”{{t‹„‹‹’Š‹„„¨©´ƒƒ|µ¶·tzl{||{{ƒŒ”•¦§¨¦§¨‹„‹£››ƒ||’ŒŒ{tt‘Œ…‚wllriŒ”•“““ƒ||‚|u‰ƒv””‹Šut“““”“›œ¤¦lri‹„‹£œ¥”››‹’Šš””{u{{tt{||{||{||ult‹„„‹„‹ƒ}ƒ„„Šƒƒ|ƒ||{tt‹‹‹‹‹„{zmyleƒƒ|‹‹„‹„‹”“›‹’Šuzt””‹]bZ“““¤¤|‚z£œ¥u{{ult]cdf]c„Š„ƒƒ|“““„Š„„„Šult“Œ”‘Œ…››”dc\ƒƒ|‹„‹ƒ„„lekredsre‚v‚{||‹„„{|||‚zbVUrfk¢—{{tlld‚|uldd{ttzll‚ut‹‹‹:97JHF‹‹„{{t|„…sleƒ||„„Šƒ||‚|uƒƒ|‹‹„‹„‹ekdlri””‹tslƒƒ|Œ”•ƒ||tllŒ”•|„…VZT‹’Š{{t””‹„Š„ƒ„„«²«‹‹„š””ƒ||ŠŠ}…‹‹’ŒŒ”“›{||b[U|„…sreŠŠ}lekttslri„„Š\[[lkssleVZ[{u{…‹‹£œ¥ƒ„„{tt{{tƒ||lri‹’Š{tttllVZ[ƒ||ƒƒ|f]cƒƒ|{||sretsllddsre{{tsre{{td\\{||ƒ„„lld””‹d\\‰|vƒ||b[Ukd\‹‹‹ldd’…‹œ¤¦‹’ŠtslŒ”•lldb[UUMRtll‹‹„‹‹‹red’ŒŒ„„Š[TTtsl{||Šƒ}‹‹„{||¦§¨¦§¨{tt‹„„œ››”š”‹‹„‚ut‚|ukd\tt{uzt›”›„„Š‹‹‹ldd{tttt{fkkmtt{ttu{{{{ƒ”“›’…‹‹’Šƒ‚uldd“Œ””“›tt{™š¤ª³·“““«²«£œ¥›”›¦§¨£››‹‹„‹‹‹{||›¢›£œ¥£››‚|utsl«²«“““‚v‚rfk“Œ”™š¤”››››”‹‹‹{||{u{“““ƒ„„tts“Œ”“Œ”{||‰|v‰ƒv””‹””‹”š”œ››‚v{‘Œ…{{t‹’Š‘Œ…š””“““{{ƒ{{t{{t“Œ”™š¤“““””‹¨©´“Œ”¦§¨¤¤Œ”•tzl“Œ”zll‹„„ƒ||lldŠŠ}“““”››”››‹‹„µ¶·²²¬‹‹‹Œ”•ƒ||„Š„\[[ƒ||ttsMRKztl“““|„…Œ”•lkslksƒ}ƒbVZ…‹‹¦§¨„Š„›”›‹’Šult›”›Œ”•‹’Š„Š}„Š}ƒ„„‚ut{u{{u{‹’Š‹„‹„„Šƒ„„SKJlrifkkred‚|u“““ƒƒ|Šƒ}‹‹‹ƒ||‚utldd””‹JHF:97rg]|‚zƒƒ|tzllri‹„‹¦§¨‘Œ…ƒ}ƒtllƒ}ƒ{{t]bZVTLƒ||‹‹„œ§²›¢›llk‹’ŠŒ”•tts|„…“““d\\“““tt{‹‹„d\\\[[£œ¥yle{tttlllks‹‹„ttslldVTL‹‹„leku{{edk‹’Šd\\UTSultŒ‹“ƒ„„{u{‹’Šslelrilldƒ‚uƒ||‹’ŠŠƒ}ƒ„„{ttztlldd|‚z‹„„tts‚v{lldŠŠ}j]\jcVkd\VTLtzlŠ~‹ult{zm‚|u[TTšŒ‘Œ…jcV¤¤ult””‹‹‹„›¢››¢›{u{{{tdc\Šƒ}bVUldddc\{{ƒ””‹“Œ”ƒ„„ztl‚|utsl‹„„rg]„Š}Œ‹“„Š„ƒ||ƒ}ƒ„Š„{{tlddztlkd\sle{|||‚zult|„…ƒƒ|”š”{u{Œ‹“…‹‹tts„„ŠlriedkUMRtll“““{{t‹‹„ƒ„„{u{ƒ„„£››¦§¨”š”œ¤¦µ¶·››”„Š„š””œ››”š”›¢›“Œ”ƒ}ƒšŒ‹’Š‹‹„„Š„“Œ”ƒƒ|¦§¨£œ¥rfkƒ„„¤¤„Š}{{t„„Šœ››ƒ}ƒœ››‹„‹ultiWUzllrg]‚utztf””‹„Š„Š}|ztl‚|ukd\‚|uŠƒ}‹’Šu{{tts‹‹‹œ››š””mttllk{||ult“Œ”tsl›¢›uzt¨©´ƒ„„“Œ”ƒ}ƒ„Š„|‚z›”›”š”œ¤¦“Œ”‹’Š‹’ŠŒ‹“ult£œ¥uztzlllddttsVTL[[Tsreœ¤¦f]cJHFultultzll{tttll””‹‹‹„‹„„Œ”•’ŒŒŒ‹“{u{|‚zƒ||Œ‹“{{tsledc\|‚z‰‰w{{ƒddcƒ||tsl{||ztltllƒƒ|‰ƒv£››lddultlddƒ‚uƒ„„D;9,55ƒƒ|UTS{||lld\[[{u{tll“““|‚z‹„„‹„„uztult‚|u{tt‹’Š…‹‹’ŒŒ‚v{lkslks]cdddc{{t‹‹‹cbVŠ~‹‹‹„d\\‚wlf]c‘Œ…ƒ||‘Œ…£œ¥ƒ‚utzl[[Tmttlld\[bttstt{lri‹‹„tts‹‹„tslŒ”•ƒƒ|ztl‹‹‹|„…zlldc\{||”››sleVZTuztlriƒƒ|”“›tts{ttŠ}ƒƒƒ|MRK£››‚wl{{tsle“““‹„„tllkd\tslsle£››{u{lri‚wltt{Šƒ}tll„Š„”š”tll…‹‹lld‹„‹‚utb[Uredllkƒ||Š}ƒ{tt“““{{tŠƒ}‘Œ…Š}|ulttzlf]c‹‹‹‹‹„‹’Š{{tsled\\‹„„‚|u{u{\[[]cdƒ}ƒŒ”•ttsƒ„„‹…’ƒ}Š‹„„{||edk{u{kd\„„Šƒ„„|‚z„Š„š””ƒ}ƒƒ}ƒkk]ª³·tts£œ¥š””‘Œ…””‹£›››¢›œ››“Œ”¨©´“Œ”‚ut²²¬²««œ¤¦œ¤¦„„Š›”›¦§¨[[Tztl”››œ››ƒƒ|ƒ}ƒƒ„„{u{{{t‹„‹š””Š}|b[Uztl‘Œ…‚|uek]¦§¨£œ¥ŠŠ}‰‘~‚utztf¤¤””‹“Œ”Œ‹“{||‹‹‹’ŒŒ{||tll£œ¥ulttt{tsl”š”™š¤ŒŒš£››””‹„Š„“Œ”‹‹„ƒƒ|™š¤œ¤¦‚|u¦§¨‹‹‹sreƒ‚u‹„„u{{lld|„…JHFdc\tsl‘Œ…[[TUMRMSSUMRultlks{{t{{t“Œ”{ttlddŒ‹“{||llkuzt{{tƒ„„ttsŒ”•››”{tt‹’Šlld[TT‚v{ƒ„„„Š„‚ut‹„„‹‹„””‹Šƒ}››”lldldd‹‹„“~ˆ£œ¥:97*)(ƒƒ|ƒ„„ƒ}ƒztlu{{ƒƒ|d\\Šƒ}‚|u|„…tts{{tUTS£››…„’”››ttsredldd{u{llkekdtt{¤¤‹‹„{{tlld{||ttstll“““‹„‹‚v{‹„„mttdc\ƒ||ekdlrikd\{ttŒ”•™š¤lriƒ„„|„…Œ”•tts„Š}|‚ztllŒ‹“‹’ŠŠŠ}tzl„Š„Š}ƒ{u{LKRd\\rr]f]cd\\ddcf]c‚utdc\kk]ztl›¢›¤¤””‹ƒ„„tt{srekd\[TT[TTj]\ultsleŠƒ}ƒ„„‚utŠ}|Œ”•tslult{{ƒƒ„„ƒ||‘…„‚|uult“““tslŠ}ƒ””‹{yf‚|u‘Œ…‘Œ…‹‹„z‚l‹‹‹uzttllrg]|„…tsl›”›{u{’ŒŒ{tt‚v‚dc\{ttƒ„„‹’Š‹‹‹„Š„{{ƒ‹‹‹‹„„{u{{{ƒ{tt‹„„red‘…„‹‹„¦§¨‹„‹”“›ƒ}ƒ‹„„”š”›¢›„Š„£›››”›¤¤ztl‚|u‹’Š{u{‚|u’…‹šŒ¤¤››”ƒƒ|‹‹„Œ”•rfk™š¤llk‚|uƒƒ|¨©´‹’Š‹‹‹ƒ„„tts‹„‹¨©´“““‚utzllrg]Šƒ}jcVsreŒ”•‚v{‹’Š””‹redŠŠ}ztlkd\„Š}VTLtsl””‹‚v{’ŒŒƒ„„››”‹„‹kk]››”lri‹’Šedktll›”›{{t™š¤¦§¨‹‹„œ››™š¤¨©´«²«”››‹„‹„Š„…‹’{{ƒmttd\\VZTƒƒ|ƒ||”š”ƒƒ|[TTJHFf]c{{ƒf]ctsl‹‹„”“›‹‹‹‚ut“Œ”lri|„…{||uzt¦§¨™š¤ƒ}ƒ””‹‚|uƒƒ|‚wlƒ„„ult{||‹‹‹““““Œ”“Œ”’…‹‚ut‹‹„‹„„Œ”•‹„„Šƒ}£œ¥JHF*)(‹‹„‹„‹ƒƒ|ƒ||mtt””‹ztl‚|u‚ut›”›¤¤{{tlri{||d\\ldd‹’Š]bZƒ}ƒƒ}Š|‚z|‚z„Š„‹‹‹‹‹„”››¦§¨™š¤‚|u””‹Œ‹“¦§¨‹„„””‹”š”uztlrillddc\{{tztl‹„‹rfk‹…’’ŒŒkk]™š¤|„…”š”[TT{||tts{||{ttlldllkmw’ŒŒ\UZƒ„„{zm‹„„{u{ƒ||‹‹‹‚v{tslsreztf‚wlkk]ddcdc\ultzll‹„‹{tt‚v{{{tkd\dc\’ŒŒƒ„„d\\›”›d\\[[Tkd\rfktslVTL‚ut£››„Š„tslb[U“Œ”{ttulttllztltll‚ut|‚zlriŒ‹“f]cŠƒ}“““{zm‹„„››”Š}ƒd\\f]clri‹„„{||‹’Š|‚zlldtt{‹„‹‹„„‹„‹{{ƒ|„…ƒ||Š}|ƒ„„ƒ„„Œ‹“‹„„’…‹ttsŠŠ}œ¤¦uztsleŠ}ƒ’…‹£››¦§¨£››‹‹„ultŠ}ƒ‚v{“““Šƒ}¦§¨„Š}ƒƒ|…‹‹zll‹‹‹“““‹‹‹dc\‘Œ…dc\{||ƒ||mtt””‹tll‚v{’ŒŒ{ttŠ}|Š}|kk]sle‹‹„‚v{‚utztfƒ}ƒ››”””‹|‚zsreSKJllk{||kk]›¢›…‹‹›¢›“Œ”‹‹‹ldd|„…Œ”•„„Š¦§¨‹‹„’…‹ƒ}ƒ””‹”š”œ››ƒ„„£œ¥|‚z{{ƒ“““‹‹‹lekttsƒ„„lrilddlri’ŒŒ„‰v{ttf]clriƒ}ƒ“Œ”‹„„›¢›ƒƒ|{u{Š}|‹„„…‹‹‹’Š|„…ƒ„„ƒ„„‘Œ…Š~‹¦§¨ztlŠŠ}‹’Š{{tŒ”•‹„‹tts|‚z{u{{u{Š}|£››™‹†¦§¨¦§¨ƒ||“““ŠŠ}£››:97*)(Šƒ}Œ”•‘…„{ttŠ}|ƒ}Š‘Œ…ƒ||{||ƒ„„Œ‹“›¢›llkkd\{u{…‹‹”“›’ŒŒ‹‹‹tts“““\[[z‚l{||‹‹‹µ¶·“““¦§¨‚|u›¢›”“›Œ‹“{{tslerfk„Š„‹‹„‹‹„›¢›{{tdc\ƒ}ƒ‹„„›¢›‹‹„ek]f]c|„…ƒƒ|‹‹„‚v{„Š„‹„‹“““zll{tt{u{[TT{{tllkzll{ttllklribVUultf]cdc\{{tVTLƒ||ƒƒ|lri{zmkk]ƒƒ|lddtllŠŠ}‹„‹VTLredƒ}ƒ“““›”›„„Š‹‹‹ƒ„„f]c|‚zsle‹„„ƒ||tllddc””‹š””‹‹‹ƒ„„‹’Š{zmbVUƒ‚u“““dc\ƒ„„[[T‹‹‹{{t‹’Š“““‘Œ…ƒ||Š}ƒztlttsultttsfkkllk|‚z\[bttsƒ„„“Œ”mttlri‹‹‹tts‹‹‹””‹ult‚ut›”›ult‚|u{{t„Š„ttstll“Œ”£››š””£››{{tƒ„„redf]cŠ}ƒ””‹‹‹„””‹¦§¨›¢›ƒƒ|\UZ”š”|‚z››”tsldc\{||‹’Šult‹‹‹{{t‚v{ztlƒ}ƒzll¦§¨b[Utzlƒ„„œ››Šƒ}dc\‘…„Šƒ}‚wl{zm{{tuzt‹‹„œ››{tttzl{ttƒ}ƒ››”{{t¤¤uzt”š”‹‹‹‹„„‹‹„“““u{{‹„„Œ”•”“›„Š}“““tsl{ttfkkŠ}|‹‹‹ƒ„„{||sle]cdtts‚|u|‚zƒƒ|Œ—£edkf]cultƒ}Š„Š}ƒƒ|¨©´š””””‹|„…ƒ‚u‹‹‹ƒ„„ƒƒ|‰|v›”›™š¤µ¶·¤¤››”›¢›“Œ”“““”š”ƒ„„lddultultredš””£››£››“Œ”’…‹‚wl¦§¨JHF)+2››”ŠŠ}ult‹„‹”“››”›£œ¥‚v{sle‹„‹‹„‹lldlek[TTlks‚v{Œ”•ƒƒ|ƒ}ƒ„„Š”››uztu{{{u{‹‹‹¦§¨„Š}¦§¨¤¤ƒƒ|¦§¨£›››”›‹’Š‚|u£œ¥”š”ƒ„„mtt[TT|‚zlek{||ƒ„„{||lldultddctsl„Š„sle™š¤’ŒŒjV[{{trfk‹„‹lek‚v{ƒ„„f]cƒ||lddd\\d\\b[Ullk””‹rg]{{tkd\|„…‹‹„Š}|ttsttsƒ||sle‘Œ…””‹ƒ‚n‚|u„„Šš””œ››””‹ƒ„„ƒ}ƒlddlddtllkd\‚utrg]f]cztlƒƒ|’…‹‹‹„ƒ‚uƒ}ƒb[Ullddc\ƒ||ƒ}ƒ{u{llk{||tsl‚|u””‹{tt‹„„ddcŠŠ}{u{ddcƒ„„‹„„“““tt{{{ttt{„„Š™š¤ƒ„„UTS‚v{lek|‚zddcd\\‹‹‹kd\ztl…‹‹“Œ”“Œ”¦§¨Â¾Æ£››””‹¤¤«²«””‹Š}ƒult‰|v“Œ”uzt„Š}‹’Šƒ„„œ››‹„‹‹‹‹ŠŠ}„Š„{||™š¤¦§¨“Œ”{ttd\\œ››š””ƒ||‹„‹“Œ”š””””‹ƒ„„‹’Š“Œ”‹’Š‹‹„²¬µsre‹‹„sretsl¦§¨Œ”•›¢›‚v{Šƒ}{{tƒ||“““‹’Š‹‹„lld|‚zƒƒ|ldd“““‹‹„“““ƒ}ƒuztƒ||{u{„„Š‹‹„ƒ„„‹„„tts£œ¥ƒƒ|…‹‹‹„„]bZ‹„„‚|u|‚zœ››‚|u\[b\[bbVU‹„‹kk]ƒ„„“““›¢›ƒƒ|ƒ„„“Œ”tsllld{u{Š}|£œ¥¦§¨dc\””‹¤¤{zm”“›œ››Œ‹“œ››„Š„“Œ”‹„„‹„„zll¦§¨‹„„£œ¥‘Œ…‹‹„²²¬\[b*)(zll[[T{tt‚|uddc{tt„Š„œ¤¦ƒ||ult{{t‚|u„Š„š””ƒ}ƒedk{||“Œ”tt{‚|uztl|‚z„Š„ult“Œ”tzl”š”‹‹„„Š„‹‹‹“Œ”ƒ||ƒ„„ztltts]cd””‹|‚z‹’Š””‹|„…u{{‹„‹…‹‹llklddtllmttƒƒ|š””ŠŠ}tts‹„„{u{ƒ}ƒ™š¤tllUMRllkttstll{ttmwSKJ[[Td\\“““’…‹cbV‚|uyle‹‹„ƒ„„š””‚|ulldŠƒ}tts‹‹„sleŠŠ}””‹£œ¥{u{™š¤“Œ”zllrfkf]ctsl{tt{tt{zmŠ}ƒ…‹‹ƒ||‹„„™š¤”››ƒƒ|‹„‹‹‹‹kd\llkƒƒ||‚z‹„‹zlltsl{zmƒƒ|’ŒŒ{ttš””„Š„‹’Štlltsl|„…{{t{||“Œ”{u{Œ”•‹‹‹‹…’”“›lri‚v{ult{||¦§¨“““ƒ||‹„„ƒƒ|£››””‹“Œ”“Œ”£²Ã¼¿¦§¨{zm¦§¨Œ‹“œ››²¬µ{{t‘…„f]c“““›¢›¦§¨ƒ||„„Š‹„‹ŠŠ}{{tœ››lri””‹ƒƒ|‹„‹‚v{lekf]c‚wl{||“Œ”šŒ””‹ƒƒ|“““›”›œ››{{t“Œ”sre””‹¦§¨‹’Š|‚z–¢‹‹‹‹ddc‹„„{{t‹„„šŒtslŠƒ}llk\[[ƒ}ƒztlƒ}ƒƒ}ƒfkk¦§¨“““Œ‹“””‹“Œ”Œ”•ultllksle‹‹‹“““|‚z{||„Š„VTL\UZ„Š}£œ¥lddedkUMRŒŒšf]c‹‹‹{{tult{||‚ut‹‹‹ttslddllk””‹Š~‹›”›’…‹uzt‘Œ…tsl””‹‹‹‹Š~‹„„Š|‚z‹‹„ƒ„„‹‹‹Š}ƒj]\‘Œ…ƒƒ|‹‹„tt{š””µ¶·f]c*)(tll‚|uš””‹…’mtt{u{Š}|{zmtslf]c|‚zlrikd\[TTtt{‚|ulri™š¤ƒ}ƒdc\„„Š„Š}ƒ„„‹„„{tt¤¤œ››Œ‹“›”›tts²««‹‹‹‹„‹‹‹„{{tƒ||”››ƒƒ|„Š„ƒ‚uŒ”•”“›tt{“Œ”Š~‹‹‹„‹’Š{{ƒVTL‚v{|‚z™š¤‹‹‹’…‹|„…ƒ}Š‹„‹‹‹‹ƒ}ƒŒ”•‚utdc\kd\\[[‚utƒ||{{t‹‹„‚|ulri‰v|ttsttsllkƒ„„|‚z’…‹j]\‹’Š{u{i\Vsreš””›”›Šƒ}ƒ||VTL‹„„ylellkztfmwlddtsl{zmƒƒ|„Š}{u{‹„„‰ƒv‚utœ››ƒ‚ullk„Š„sreƒ}ƒd\\kk]Šƒ}‚ut{tt‹„„‚ut{||ekdƒ„„”š”tslƒ}ƒƒƒ|{||{{t{{ƒ››”ŒŒš™š¤{u{‹„‹¦§¨{{t¦§¨µ¶·‹’Š‹‹‹“““£œ¥Œ”•‘Œ…£œ¥‹„„‘…„’ŒŒ™š¤ƒƒ|¨©´tll‚v‚““““Œ”{u{œ››””‹“Œ”ekdŒ‹“ƒ}ƒ‘Œ…ƒƒ|‹„„kk]ttsrfk‹‹„‚v{ƒ||zll‹„„lri›”›‘Œ…‹‹‹¦§¨”››£››‹’Š‘Œ…‚utŠƒ}{{t‹’Š‹‹„‹’Š”š”{u{tsl{{t‹‹‹u{{ddcttsƒ‚u…‹‹{||ƒ„„{{t„Š„‹’Š¦§¨{u{“““tll›¢›‹„„‹‹‹‹„„‹„‹””‹…‹‹”››lek{{ƒ|„…d\\ult{zm¤¤ultlkslks{u{rfkdc\ƒ„„ƒ}ƒlri{{t”“›ƒ}ƒ„Š„{{t‚ut{tt›”›Œ‹“‹’Šƒƒ|llk{zmƒ}ƒƒ||tts{zm{{ttllrfkŠƒ}{ttsreƒ||{yf‹’Šztl””‹JHF?;C‘Œ…‘Œ…”››‹„„ƒ}ƒtzlulttll[[T›”›‹‹„\[[ultƒ||tllƒ||Œ”•|‚zƒ||’…‹‘…„lri“Œ”‹‹„”“›“““ekdlld‹„„u{{ult‚|ukk][TT{ttkd\ddc‚|uƒ„„{{t„„Šƒ||“Œ”“Œ”tllek]‹„„ddc‰‰w„Š„[[Tllkd\\…‹‹f]c{u{llk‚utlrittstllultsle{ttj]\{||ddcsleztl[TTred‹’Šlddzllƒ||\[[‚v{{||{{t™š¤{ttlld’ŒŒ‹‹„u{{{||lek“Œ”£››tslƒ||ztl…‹’tsl„Š„”š”|‚z£œ¥š””””‹|„…{{ƒƒ‚ulriƒƒ|lld‹„„dc\{ttƒƒ|ztfultƒ||‹„„lks{{t“Œ”|„…‹‹‹›”›””‹{u{tll™š¤llk£››£œ¥‹‹‹dc\|‚z””‹œ››‹„‹¤¤’ŒŒult””‹”››tllƒ}ƒultƒƒ|‹‹„lld”š””››lriŒ”•tllƒ||””‹kk]‚ut¨©´›”›„„Š‹„„‹„„››”tts{||››”…‹‹rg]ƒ||šŒ£œ¥‹„‹ƒ„„ƒ}ƒŠ}|ƒ||‹„‹{||²¬µŒ”•Šƒ}ƒ‚ukk]‰ƒv›¢›‹’Š”š”ƒƒ|’ŒŒ‹„„¦§¨œ››ƒ„„ldd|„…|„…‰‘~]bZult‹…’ƒƒ|››”sleƒ„„llkƒ}ƒ””‹‹„‹|‚zƒ}ƒ{u{„Š„ƒ„„„„Š‹‹‹„„Š|‚z]bZŒ‹“›¢›„Š}|„…JHFlksult›”›‹’Šƒƒ|’…‹ƒƒ|tllŠ}ƒ{{ƒª³·“Œ”‚wl‘…„„vŒ‹‹‹¨©´””‹sletts””‹‚ut’ŒŒ{||ttsœ››ztl“Œ”‘…„‚|uztl‹‹‹{{tek]¤¤:97*)(‘Œ…tlltslekdult‹„„Š}|ultkd\mttƒƒ||„…u{{kd\{u{lddekd{{ƒlekVTL™š¤œ¤¦œ¤¦”š”“““ƒ„„œ¤¦{{ƒ{|||„…’ŒŒ››”¨©´lldtll|‚z›”›ƒ||tslƒ„„¦§¨”“›ult”š”|„…‹’Šƒ„„ddcƒ||ƒ}ƒ{{t\UZllk„„Š‹‹‹{u{ƒ}ƒultj]\“Œ”r]g{||ƒ||{u{j]\›”›Šƒ}tsl‰|v”››Šƒ}ª³·ult{yfšŒtzl‚utbVUllkzll’ŒŒf]cƒ||‚uttts\UZ{{tztlƒ||ƒƒ|‹‹„šŒlld{{tz‚lŒ”•tts”››””‹{{t’ŒŒtts‚ut{||‹‹„ƒ„„“““d\\‹„‹ztf’ŒŒzll‹„„’ŒŒƒ„„››”ult…‹‹ƒ||š””Œ”•{u{›”›lks‹„„”››llk“““Œ‹“””‹ztl™š¤œ››²¬µ£››{{t{{tllk‘Œ…‚v{š””””‹œ¤¦‹‹‹›¢›œ¤¦“Œ””“›{{ƒ‚utkd\lld”š”‹„‹’ŒŒ¨©´‹„„ƒ„„{{tƒ„„tzl›¢›‹‹‹‘…„¦§¨››”£œ¥¦§¨£››“Œ”£››‚|u{{tƒ„„‹„„”š”{u{“Œ”dc\‚ut{{tjcVœ››“““{u{lek›¢›””‹„Š„mtt‹’Šuzttzllrimtt\UZmtt”š”œ››{tt‹’Š‹„‹›”›¦§¨œ››ztltt{Œ”•¦§¨”“›„„Š›”›”“›‹’ŠtllŒ”•œ¤¦ƒƒ|UUYUMR\[bult‹’Š”››…‹‹uzttll“““ƒ}Š{||lks””‹ulttt{lddƒ„„“Œ”sretslƒ||‹„„tllƒ„„‹‹„{u{“Œ”‚ut‚v{ŠŠ}{{t|‚zƒ||lld¦§¨VTL74,‹’Šš””‹’Štt{“Œ”ƒ||‚v{[[T]bZlek‹„„”š”ztllri{{ƒult{||llkultkd\sle¦§¨Œ”•‹’Š¦§¨Œ‹“¦§¨‚utš””ƒ„„“““”››{{tƒ||””‹Šƒ}{||“““b[U›¢›œ§²£œ¥Œ‹“mttŒ”•‹„‹ultf]c‹„‹ldd‹„„tts‹„‹uztSKJ[TTultult„„Šllki\Vƒ}ƒ{tt‹„„””‹j]\£››ƒ||¤¤Œ”•‹„„dc\‹‹„ŠŠ}{{tVTL‚utSKJtzlb[U{ttSKJ{ttkd\ƒ„„bVU[TTŠƒ}{ttuzt‹„„zllkk]tll{||‘…„‹’Š“““lddbVU‚utkk]lri‹‹‹ttsŠŠ}…‹‹|‚z“Œ”¤¤‹„„{ttrfk‹‹„{ttŠƒ}‹…’‹‹‹”š”tts”“›tllš””{{ƒƒ„„„„Š“Œ””“›{tt›¢›kd\”››“Œ”‘…„ultttslld‹„„sle›”›ƒ}ƒ£››‹’Š“““”š”““““Œ”|„…‹…’Œ”•‹„„””‹£››“Œ”Šƒ}“Œ”“Œ”¦§¨›¢›’…‹u{{tzlƒ}ƒedk“““¦§¨‰v|red¦§¨“Œ”‚ut|„…Šƒ}‹‹„{||”“›‘Œ…£››‹’Š{zmŠƒ}„Š„¦§¨š””œ››™š¤››”‹„‹Šƒ}Œ”•{{tƒƒ||‚z|‚z’ˆllk”š”|‚zddcƒ„„…‹‹ƒ||{u{‹u…„Š}tt{‹„‹”››”š”Œ”•µ¶·œ››lri‹’ŠŒŒš¨©´‹’Šƒ}Š[TTf]clek¦§¨{||lld|‚zmtttt{{{tƒ||tt{{u{redd\\ƒ}ƒ™š¤””‹{u{‹‹„tslztlulttll‚ut„Š}‹„„Šƒ}šŒ{tt‹„„…‹‹tzlmtt{zm›¢›JHF:97{{t‘ˆ}dc\…‹‹Œ‹“š””ztlztlllk‹’Šdc\ƒƒ|cbVz‚l„„Šult››”llk{||ultŠƒ}„‰v|„…ƒƒ|ƒ}ƒ“““‹’Štt{¦§¨¦§¨{tt”››tt{‹‹„lriztl{||tllƒƒ|VZT|‚z™š¤tt{fkkllkƒ||[TTJHFf]c\[[lldultf]cf]c\UZllk‹„„ult‹‹‹lekyfllek¤¤ƒ}ƒ{zmŠŠ}‚wlSKJšŒd\\JHF{{t|‚zsre’ŒŒ{{tƒ||red{{t‚|usre{||Š}|cbVtllzll‹’Š{tt‹‹„‹„„ztl‚uttllllkƒ||‹‹„{tttzlVTLtll]bZkd\ƒ‚uƒƒ|”››‹‹„™š¤lld{ttƒƒ|‹’Š“Œ”‚v{’ŒŒŠ}|››”{|||„…„Š„tt{Œ”•“Œ”‹„„„„Š‹‹‹{ttmttultzllƒ„„¤¤ƒ}ƒlddldd£››“Œ”ddcƒƒ|ƒƒ|‘…„¤¤””‹Œ”•”››tts”š”””‹£œ¥ƒ„„Š}ƒ¦§¨ƒ‚u››”£œ¥’ŒŒ“Œ”£²‚|uredu{{ztl’‘~Š}|ƒƒ|š””£œ¥{tt‹„„b[U£››kd\Š}ƒkd\‹’Š‹„‹ƒƒ|£››£››””‹Š}|{{ttts””‹””‹£œ¥{{tlri‹’ŠŒ‹“tsllriz}‹’ŠŒ”•tsl“““ult””‹ztlzllœ¤¦Š}ƒƒ||{ttŒ”•„Š„ztl”š”…‹‹”››‹’Š”“›ƒƒ||‚z\[[›¢›lldŒ”•‹‹„’ŒŒ{u{‹…’’ŒŒŒ”•ƒ„„œ¤¦™š¤‹…’‹„‹uzt‹„‹¤¤‹„„{tttll¦§¨ƒƒ|{zm„„ŠŠ}|ulttll”››{zm{{t’ŒŒš””tll‹‹„‹‹‹”š”“““””‹¤¤JHF*)(ultcbV|‚zttsƒ„„]bZŒ”•red{ttj]\‹’Štslƒƒ|kk]ult¤¤”“›Œ”•f]ckd\bVU‹’Š…‹‹dc\d\\¤¤‹’Š|‚zŠ}|ƒ}ƒŒ‹“ƒƒ|“Œ”zll£œ¥{{t{{ƒllkuzto€wlkstt{™š¤u{{Œ”•UMRd\\ldd‚v{UMRj]\ultmwtsledkUTSƒ||ƒƒ|ƒƒ|tt{‘Œ…tll‹‹„‹‹„{{t[[T{ttredztllldlriƒ}ƒtzl{{td\\ƒ‚u‚|uƒ||ƒ‚u{||£››ldd{tt[TTd\\FD;rr]{tt{tt“““š””tll‹„‹ƒ„„‹‹‹tsllldd\\ztl{{t””‹ztltzl{{t|‚z’…‹‹‹‹…‹‹‹„„ztlƒ„„rfk”“›‹‹„{u{‹‹‹{{ƒztllddj]\mtt‹„‹{ttlek“““„Š„tt{\[bllk|‚z””‹™š¤ƒƒ|ƒ||tll{||„Š„’ŒŒ„Š„¦§¨œ››£œ¥{||”š”ª³·œ¤¦ƒ‚uŒ”•Š}ƒ··Ä£œ¥¦§¨«²«œ››f]cŒ‹“‹„„{{tƒ„„f]c‹’Š‹„„“““ldd{ttŠ}ƒtllŠ}ƒcbVddc{u{š””ƒ||ztlttsƒƒ|Šƒ}–¢‹››”””‹ƒƒ|ƒ„„š””£œ¥„„Šztl{{t‹‹„…‹‹u{{lddlriŒ”•mtt]cd]cdŠ}ƒedkj]\‚|u‹‹„¦§¨redult”š”™š¤’ŒŒ™š¤š””¦§¨uztƒ}Š|„…dc\tlllri|„…|‚ztt{u{{™š¤{{tƒ||„Š„ƒƒ|œ¤¦ƒ}ƒtslƒ}ƒ|‚zƒ}ƒ‹„„‚|umtt{u{{zm„Š„ztlddcztlult‹‹‹{ttztlƒ||kd\‚|uultf]c{{ƒƒ||”š”£››“““>EC:97tslSKJ{{tŒ‹“‹’ŠVTL‚wlŠ}|{u{d\\rg]|‚z„Š}mtt‹’Šš””™š¤{{tbVZ{u{sre|„…‹‹‹ƒƒ|{||zll|‚z{u{””‹”š”uzt”››ulttll{{tlddƒ}Š{tt|‚z‹’ŠUTSŒ‹“ult\[blrilldf]ctll£œ¥mwtsllek‹„‹””‹…‹‹JHFuzt¦§¨{tt[[T›”›{||kk]’ŒŒ‚utSKJred‚v{‹’Šllk|‚z‹’Š‰ƒv‹„„d\\tslultedkƒ}ƒ“““ƒƒ||„…b[Uztl‘Œ…„Š}kjV‚|utllƒ„„{{t{tt›”›dc\ƒƒ|ƒƒ|{||lldƒ‚u””‹‘Œ…””‹‹„„‹„‹”š”ƒ}ƒƒ}ƒtts{tt‹‹„{{t‹„„ƒ}ƒƒƒ|{||Œ”•‹„‹”“›|„…{||Œ”•ttslektt{{tt{||Œ”•‹„„œ››‹‹‹¦§¨ƒ}ƒ{{t’ŒŒ‚v{tslŒ”•š””‘Œ…“Œ”¦§¨››”’ŒŒµ¶·œ¤¦‹’Štslœ››{tt…‹‹¦§¨›¢›¦§¨“““‹…’ƒ}ƒš””¤¤¦§¨£››š””›¢›¦§¨ª³·œ››‹„‹‹„„{tttts{zm‹„„£››{tt{{t{ttŒ‹“\UZred‹’Š{u{uztš””Šƒ}œ››‹„‹{ttbVU{|||„…]bZŒ”•‹’Š›¢›Œ”•…‹‹‹‹„ult””‹‹’Š“““„„Šult“““š””‹„‹“““|‚zultdc\llkkd\tlledkttsultfkklks\[blekllk{{ƒkk]‹’Šœ¤¦¤¤Œ”•œ››¦§¨ekdttsƒ}Š{||‹‹„“Œ”{u{uzt{{tdc\|‚z‘Œ…“Œ”ƒ„„Œ”•{{tztf‘…„ƒ„„›”›llkšŒ””‹“““’…‹‹’Š:977-2”››‹‹„ŠŠ}”š”llk{u{ƒƒ|‹„„„„Š{u{tzllld|‚zlldu{{ttstt{lriultŠŠ}]bZkd\{ttƒ||tll””‹lld’ŒŒŠƒ}‘Œ…|‚zƒ}ƒ”“›rfk¤¤‹’Š“““|‚zƒƒ|{||™š¤llktt{„Š„lksf]c{u{SKJƒ}Š{ttlldŒ‹“tll{tt‚v{…‹‹|‚z|‚zuzt[TTƒ||llk‚wlrfkVTLsleƒ||slettslld‹‹„tts|‚zsleƒ||aWMSKJFD;ztlultu{{“Œ”[TT””‹slelldkd\‚|utsltts„Š„‹„‹uzttllb[Utyg{{ƒ””‹ztlsrekk]‹„‹{{t™š¤¦§¨››”“Œ”ddc””‹‹„„sle‹…’ƒ„„”š”‹‹‹|‚ztts…‹‹ƒ}Š{tttt{{||“““ddc‹…’{||{{ƒtts„„Š‹„‹¤¤Š~‹“““‘…„ƒ}ƒ›¢›‹’Š››”{{t£œ¥™š¤’ŒŒµ¶·œ¤¦œ¤¦¤¤””‹¨©´µ¶·™š¤œ››µ¶·¦§¨“Œ”£œ¥“Œ”f]cƒ„„mw‹„‹‚wl‚|u””‹””‹””‹„Š„„„Š“Œ”uztbVU››”“Œ”lld‹‹„ddctsl‹„‹{ttsle‚|uƒ„„ult“Œ”{||“Œ”rg]ƒƒ|Šƒ}ƒ„„lri{||œ››mtt|‚z„„Štt{ddc’…‹“““›¢›{||rfk››”£œ¥‹‹‹„Š}ztlŒ”•zll‹’Šƒ||lddŒ”•ƒƒ|‚v{uztVTLultSKJtslŒ‹“[[Ttzl‹’Š‹‹„{||{||„Š„{tt””‹„Š„““““““Œ”•{{ƒ‹’Šultƒƒ|ƒ„„{{t‹„„{u{“““”š”‹„„Š}|ƒ||tsl{u{‚|u{tt|„…uzt”š”>B9*)(zllƒ|||„…“Œ”{{tllklddbVUd\\lddek]UTSlri[[T{{ƒtslult{{td\\„Š}u{{cbVbVZ››”ƒ}ƒsleb[U{||zll‹„„{||”“›ƒ}ƒtsl{ttƒ‚u|‚z„„Šuzt|„…|„…{{ƒ\[bJHFJHF\[[f]cd\\\UZb[Ud\\ƒ„„ttsd\\VTLƒ}ƒ‹„‹{zmtsl{||‚|u{{tƒƒ|„„Šf]c]bZsleldd£››ddclld|‚ztzl‚|utllaWMsre{{ƒ{zmŒ‹“j]\tllƒ||‹„„tslztlf]cb[U|‚z{||Šƒ}Œ‹“dc\|„…zll‹‹„Œ”•ek]tsl‚ut‘Œ…{ttƒƒ|lri‚v‚‹‹„ƒ}ƒ¤¤tlliq]tsld\\{||{{t‹„‹|‚z›”›{{ƒƒ}ƒš””Œ‹“›”›ƒ}ƒ{{ƒ{||ƒ}ƒ”š”{u{ƒ||‹„„Œ”•Š}ƒ‹„„¦§¨’ŒŒ‹’Š”“›”››“Œ”™š¤‹‹‹””‹¦§¨‹’Š¨©´{{ƒ”“›ƒ}ƒŠ}ƒ“Œ”¤¤œ¤¦sle“““Š~‹£œ¥’ŒŒ“““œ›››¢›‹’Šƒ||‚|u{{tƒ|||‚z“Œ”ŒŒš\[[‚v{„Š}ztl{||“““‹„‹tsllldj]\ttstzl{||‚wl“Œ”ƒ}ƒƒ„„lldƒ||››”„Š„„„Šlldmttlks|„…lksuzt„„Š“Œ”››”‹‹‹{{ttts“Œ”ƒ}ƒ‹‹‹“““””‹Œ”•{{tƒƒ|ƒƒ|’ŒŒ‹‹‹lriƒ„„œ¤¦”“›Œ”•r]glldƒ„„mtt|‚z„Š„lddœ§²‚v{‹’Š’ŒŒƒ„„‹‹‹‘…„‘Œ…tt{{{ƒƒƒ|‹„‹š””Š~‹’ŒŒ‹‹‹‹„‹‹’Š{{t…‹‹{{t’ŒŒ“Œ”dc\VTLtllVTL]bZ’ŒŒJHFJHF“““‹‹‹|‚z|„…]bZSKJd\\ultddcd\\b[U|„…|‚zlekttssleultuzt‹‹‹‹„„{{t{{ƒ‹„‹“““ƒƒ|‘Œ…‹’Š|‚zllkldd|‚ztts{u{lddƒ}ƒ|‚z|‚zMRKddcult]bZlddultf]cmtt„„Štsl[TTultd\\lddu{{Š}ƒtllj]\„„Šf]c‚|ukd\{||{u{[TTŠ}|{u{sreztl‹„„{zmcbVƒ||„Š„tzltzlultkd\{||’ŒŒllk…‹‹zll‚utult‹‹„¦§¨kd\VTLsle””‹|‚zdc\“Œ”ƒ||ztl’ŒŒsresre”š”kk]tsl‚utsleldd‹‹‹‹…’ulttlllddllkSKJiq]tsl‹„„ƒ}ƒ‹‹‹Œ”•{tt{{ƒ{||llk‹’Š{{ƒ™š¤’ŒŒ™š¤|‚zŒ‹“™š¤ƒ||tts“““{{tkd\””‹ƒ||¦§¨Œ”•{||ƒ}ƒ””‹£œ¥‹„‹”š”›¢›”››™š¤ult‹‹‹|‚z™š¤£œ¥uzt‹’Šœ››¨©´Œ‹““Œ”tsl|„…{{tœ››‚|u¦§¨“““œ¤¦Šƒ}™š¤ldd¦§¨Œ”•“Œ”‹„„’ŒŒ‹„„£œ¥Œ‹“ƒ„„dc\ldd‹„‹””‹‹‹„‹„‹‚|utt{ƒ„„›”›‹‹‹…‹‹tt{œ¤¦tsl|„…|„…{{t¨©´”š”„„ŠŒ”•{{ƒ|„…tts’ŒŒ””‹‚utŠƒ}Œ‹“sle™š¤””‹”››‚ut{||ª³·Œ”•£œ¥ekdœ¤¦£››…‹’Œ”•œ§²|‚z‹‹‹”››”š”¦§¨™š¤œ›››¢›tsl”š”ƒ}ƒztl{u{llkƒ||¦§¨‘…„ƒ}ƒ‘Œ…‚v{ƒ„„””‹{{t{||{ttj]\ttsŠ}ƒ|‚zttsddc„Š„‹„„SKJ*)({||dc\lddtllVTLf]c‹‹‹{u{uztttstslu{{””‹lriu{{f]c‹‹‹ƒ„„u{{lld‹‹„Œ‹“‹„„ƒ„„…‹‹’ŒŒƒ||ƒ||²¬µdc\b[U¦§¨‹„„„„Šllk“““‹„„uzttzlddcu{{d\\ddcJHFVZTSKJ“““’ŒŒ‚v{tt{[TTlksƒ||tsld\\[TTddc””‹‚|utts’…‹{||red{ttd\\sle””‹d\\ƒ}ƒ\[[z‚lŒ”•ƒ„„bVZŠ}|’ŒŒƒ||ƒ||{||‚v{rg]rfkkd\‹„‹ƒƒ|kd\{{tslesrelld‹„„red|‚zsletslztl…‹‹{tt‚|uš…ŽŠ}|“Œ”‹’ŠŠ}ƒ{{t‚|u{tttslƒƒ|sleƒƒ|‚v{tsl{tt”››ƒ„„£››tts|„…ƒƒ|{u{ttstt{ƒ„„mtt“Œ”™š¤‚v{llk{ttŠŠ}™š¤ztl£œ¥‹„„‹‹‹¨©´’ŒŒ™š¤“Œ”“Œ”„Š}‹‹‹|‚z¦§¨ƒ„„„Š}¦§¨“Œ”‹„„„Š„µ¶·Â¾Æ£››£››Š~‹›¢›”š”„„Š›¢›Šƒ}¦§¨‹‹‹{tt¦§¨””‹‹’Š›”›{||“Œ”tts‚ut£››’ŒŒ‹„„‘Œ…{||Š}ƒŠƒ}ƒ}Š”š”‘Œ…‘Œ…”“›ultœ››››”|„…lriš”””››|„…’ˆŒ‹“…‹’|„…|‚z”“›ult|„…dc\“““²¬µ’ŒŒœ››{u{ƒ}ƒ”“›‚|u{zm{tt‹‹„™š¤Œ‹“‹„‹„Š„Œ‹“ƒ}ƒ{ttttsu{{ª³·¦§¨ƒ„„Œ”•Œ‹“j]\””‹””‹uzt‹„„tsl‚v{ƒ}ƒuzt‹‹‹‹‹‹bVUƒ||ztl‹„‹Œ‹“{{t{tt{{t‚ut{ttllk‚|u{{t|‚z\[[dc\‹‹‹:97&&UTSd\\d\\u{{ztl|„…š””™š¤{{tƒ„„œ¤¦””‹|‚z|„…“““”š”“Œ”mtt‹‹„„Š„sle”››£œ¥‹’Š‹’Š‹‹„{{tlld›”›sletts‹‹„£œ¥ª³·{tt“““ekd…‹’ekdsrelrif]c‹„‹{{ƒmttsle{zmzllƒ||Œ‹“¦§¨ldd››”lektlledkult{{t\[[|„…£œ¥f]cttslddtslkd\sleSKJ‹‹‹\[[leklldtts{u{tll””‹{{tƒ}ƒš””ztlrfkttssle””‹VTLtllsleztf{u{uztŠ}ƒf]csredc\Šƒ}sre{u{{zm{||£››Š}|‹‹„“““lldkd\‹„‹{tttlld\\„Š„sreœ››„Š„{{t™š¤Œ‹“ƒ||ttstll{u{mtt””‹{tt”“›‹‹‹{{ƒ{{ƒ{tt{{ƒf]c”››”“›‹‹„Š~‹£œ¥ttsŒ—£››”tts’…‹ƒ}ŠŒ”•‹’ŠŒ”•ƒƒ|tsllri…‹’¦§¨‹‹‹“““»ÂÇ”š”“Œ”²¬µ›”›””‹tsltsl›¢›š””Š}|ult”š”””‹‹„‹‚|u{u{{{t{u{š””›”›ƒ„„tts‹‹‹ƒ}ƒ{{ƒ“Œ”llk›”›‹’Šƒ||š””|‚z‹„‹{{ƒ‹‹„|„…mtt\[[‹„„ƒ„„|„…|„…Œ‹“mttŒ”•f]cd\\|‚zƒƒ|‚ut‹…’‹…’‹„‹„Š„tllmtt‹„‹tll”š”ƒƒ|›¢›…‹‹™š¤mtt™š¤¨©´ztl{ttŒ”•Ž¡›”››u{{œ¤¦ttsƒ}ƒ¦§¨‹‹„Œ”•”››ƒƒ|lrilekttsŠ}|{||{tt{{tƒƒ|‹‹„š””ƒ‚uuzt‹„„‚ut‚v{lks‘…„‹„„{||{{ƒJHF£››:97*)([[TSKJJHF\[[lri“Œ”{||‹„‹tsl{ttlri‹’Š|‚zŠŠ}ƒ„„u{{™š¤kd\„Š„ƒ„„£››…‹’‚v‚›¢›Œ”•|‚z‹„‹œ¤¦“Œ”¦§¨„Š„Œ”•¦§¨“Œ””š”¦§¨f]cf]cVTLek]kk]Œ”•ultd\\VTLŠ}ƒ{||„Š„f]ctt{Œ”•edkš””lddedk„„ŠuztVTLmtt…‹’ldd„Š„‹‹‹ƒ||kd\lddzlllksƒ||š””|„…{||{u{ƒ||lddtlld\\u{{ƒƒ|f]c[TTtllƒ||‚|u{zmj]\zllj]\{{t”“›tllŒ‹“{{tSKJ…‹‹¤¤|‚z„„ŠŠ}|ldd‹„„‹‹„ƒ}ƒ{ttƒ‚u‹‹‹„Š„“““ldd‹‹„‹’Š“““|‚z…‹‹{{ƒ{tt{{t{{ƒ‹‹„sle{||„Š„uzttts{u{ƒ||{{ƒ{tt{u{‹’ŠtslŒ‹“‹„„Œ‹“£œ¥tslŒ”•llktt{“Œ”lek„Š„”š”|„…›¢›œ››„‰vŒ”•œ››¨©´ª³·…‹’œ¤¦tt{‚v{²¬µ””‹œ¤¦Š}|‹‹„‹‹„ƒƒ|Œ”•””‹œ››ƒ}ƒ‘Œ…™š¤ƒƒ|‹„‹{||£››’…‹Œ‹“””‹›”›£››£››{{ƒ›”››¢›¦§¨œ››ƒƒ|Œ‹“{tt‚v{ƒ}ƒƒ„„‹„„zllmtt™š¤|„…ŒŒšJHFlldlks{ttsleldd“““™š¤‹„„‘…„‹’Šš””™š¤‹‹„‹‹„””‹Œ”•œ¤¦”››Œ‹“dc\…„’ƒ}ƒttsƒ„„{u{lld’…‹„„Š¦§¨llk“Œ”“““{||tts|‚z“Œ”lek{{ƒult‚|uztl‚v{‚|u‹‹„š””‹„„„„Štzlœ››‰|vtlluzt”š”ttsllklld{{t››”SKJ*)(lkslldVTLUTSsref]ctllbVZtzllldmtt|‚z{{tƒƒ||‚zƒ„„Œ”•‹’Š‹’Šlld›¢›Œ”•šŒ¦§¨{||\[[‹’Š‹‹„””‹ƒ}Š{||…‹‹tll››”|‚z›¢›ŒŒšult”››lld{||mtt£››dc\MSS“““…‹‹”››’…‹{{ƒ„Š}lriztlsrezllŒ”•ttslddztl{||‹„„llkf]cllkultVTLsre{zmzllƒƒ|f]ctsl{||{u{dc\SKJ‹„‹ultlldƒ„„nƒf]c{||ŠŠ}””‹‰ƒvŠƒ}ult{||ƒƒ|‹„‹tts{zm{tt””‹‹‹‹“““{||{tt{tt‘…„tslŠ}ƒ£››ƒƒ|‹‹‹kd\sleulttllƒƒ|£››{{tŠƒ}ƒ„„”››‚ut…‹‹“Œ”llkllkttsllk™š¤{u{ddc…‹’Œ‹““““‚|uƒ||”››”š”’ŒŒ¦§¨œ¤¦|‚z‹’Š{{ƒ{u{ƒ}ŠŒ”•‹‹„|‚z‹„‹¦§¨›¢›«²«™š¤”“›„„Šš””‹‹‹ƒ}ƒ‹„„]cdƒ„„|„…š””uztkd\’ŒŒ{tttsl”š”Œ‹“{tt›”›ƒƒ|‹„„lek›”›¦§¨Œ”•{tt¤¤‹„„’ŒŒ£œ¥ŠŠ}tzlš””ƒƒ|”š”‹‹‹tllƒ}ƒ|„…redUMRtt{…‹‹UTS„„Š…„’ƒ„„…‹‹ƒ}ƒ“Œ”‹‹„ŠŠ}Š}|¦§¨µ¶·“Œ”‹‹‹“““tll“Œ”””‹››”›¢›Œ”•…‹‹lri„Š„{u{¨©´ŒŒš…‹‹u{{’ŒŒŒ”•”š”‹‹‹tt{™š¤uzt™š¤tts„„Š›”›¦§¨ƒ„„ƒƒ|tslš”””“›‰v|ƒƒ|Š}ƒkk]|„…ldd¦§¨š””’ŒŒ”š”‹‹„””‹{u{“““{||²««JHF3+*”››ƒƒ||„…UTSdc\Š}|‚ut[TT{||lkstsl|‚zƒƒ||‚z|‚zƒ}ƒ“Œ”lri’ŒŒ{{ƒ””‹|‚z›”›{||‹’Šƒ||ekd…‹‹rfkkd\ƒ‚uttsƒ||“Œ”‹‹‹›¢›ª³·‹„„mtt>B9JHFlksƒƒ|tsl””‹\UZ{{ƒ…‹’Œ‹“\UZfkk››”VTLult‚|u‹„‹¦§¨…‹‹d\\\[[ult‹‹„ek]llkbVUj]\tzlztlslekd\ult¦§¨‹’ŠŠƒ}ldd{tt{u{tt{b[USKJiWU{u{”“›ƒ„„{zmVTLrg]sreedkƒ||{ttttsƒ„„„Š„‹„„Š}|‹‹‹zlltllƒ||rg]ztlƒ||ztlbVUlddu{{Šƒ}kd\lldtsl‹’Štllsle{{t‹‹„{ttllkedk{ttttslldedk{u{tt{llklks|„…sre„Š}Œ”•Œ”•¦§¨ÂÅÓ”“›¦§¨…‹’”š”œ¤¦”“›“Œ”‹‹„|‚z¦§¨ƒ„„ƒ‚u›¢›œ¤¦™š¤£››{u{{{ƒ””‹‚v{lrif]cdc\”“›œ¤¦ƒƒ|ƒ‚u“““„„Š‹‹„‰‰wsretts{tt””‹£œ¥„Š„š””‹„‹”“›‹‹‹„Š„ult‚v‚tllult|‚z„Š„{{tœ¤¦‹„‹’ŒŒ‚v{ƒ„„ldd{tt{||œ¤¦…‹’…‹‹{{ƒ›¢›lkslek‹„„‹„„ƒƒ|‹‹„‹u…’…‹‹„‹‹‹„’ŒŒ{{ƒ››”{{t¦§¨ŠŠ}¦§¨™š¤…„’{{tult„„Š|‚zŒ”•llktslmtt£œ¥|„…llklddlek{{ƒ{{tƒ„„‹„„ƒƒ|‚v{’ŒŒ¨©´¦§¨š””ƒ||””‹“Œ”‹„‹œ››‰ƒvkd\redulttsldc\sleƒ}ƒlekƒ„„””‹JHF{{tlldkd\UMRUTSlksSKJUTS]bZƒ||lritslkk]tslllk{tt{||ƒ||Š}|‚ut|‚z¦§¨‚v‚œ¤¦|‚z‹‹„|‚ztsl‹‹‹‹‹„…‹‹llkj]\Œ‹“|‚z£œ¥{u{tt{\[[|‚zlldŒŒš“Œ”uztkk]ƒ||tt{lek{u{“““dc\f]cuzt‚|ucbVu{{tzlddcƒƒ|dc\sleƒƒ|””‹‹‹„VTLb[Ulri{zm‚v‚ek]lldsle{||’ŒŒllkd\\›”›JHFttsb[UbVUztl{zmtzlŠŠ}SKJ]bZfkk|‚z‹„‹tll“Œ”[[TtslultŠ}|ƒ}ƒllkyle‚|u’…‹tllƒ||‚v{ztld\\{||yletlllri‚wlj]\‹„‹uzt‹‹‹ldduztult“Œ”‹„„{{ƒ{u{{{ƒŒ‹“lekmttddc„„Š™š¤{||¦§¨Œ”•{||··Ä¨©´œ¤¦Œ”•|‚z™š¤‹‹„u{{”“›ƒ„„ª³·¨©´ª³·Œ‹“¦§¨Œ”•‹„‹tsl™š¤œ››’ŒŒ‹„‹’ŒŒ¤¤”››“Œ”“““‹’Šƒ||‹‹‹¦§¨tsl“Œ”‹‹„ƒ}ƒtll£œ¥ƒ„„£››‹„‹‹„‹ƒ„„‹’Š‹‹‹Š}ƒttsš””‹‹‹{{tƒƒ|ƒƒ|[[T“““{|||‚ztllƒ}ƒƒ„„œ¤¦mtt|„…fkk£œ¥”“›“Œ”‚v{‹„‹„Š„|‚z“Œ”‹„„tlllri‹‹‹‹„‹£œ¥ldd‹‹„‰‰w”š”|„…{{ƒu{{¨©´Œ‹“lri„„Šllk{{tlks‹’ŠŒ”•‹’Šylelks{{ƒtslƒƒ|‹„„lks‚v{‹‹‹{{ƒŠ}ƒ‹„‹ztlztlbVZƒ}ƒ™š¤ztld\\Šƒ}{u{„Š„ƒ}ƒsrelekedkƒ„„£››JHF:97llklldj]\lek[[T„„Štslldd{||lekdc\dc\{ttb[UŒ‹“lkstsl‚|uŠƒ}ŠŠ}ƒƒ|Œ”•{{ƒœ¤¦””‹“““‹‹‹sleœ››{u{ttsŠ}ƒ›”›‹’Šlldƒ}ƒlddmtt|„…mtttll{{ƒ¨©´“““sle‹‹‹ƒ„„f]cJHFlks|„…b[UJHF{{tD;9u{{ƒƒ|‹‹‹œ››tts{||b[U]bZ[TTƒ||‹’Šƒ„„dc\ƒ||ttstsllldllkztl{{ƒ‹’ŠlekbVZf]cƒ||‚v{Š}|ƒ||ztfrg]VTLd\\lldllkttsf]cƒ„„ƒ‚u|‚z‚|uŠ}ƒlld‚|utll‘ˆ}zll’ŒŒrg]j]\{{td\\|‚z‹„„ztltt{‹‹‹uzt‚v{„Š„lldlldƒ„„mtt…‹’ƒ}ƒ„„Š{u{Œ”•|„…mttllk\[[›”›‹’Š{{ƒŒ”•|‚zƒ„„£²”››|„…œ§²›¢›Œ”•„„Š£œ¥“““Œ”•‹„‹{{ƒª³·››”lks™š¤£››ƒ||{{t¨©´“““œ››Œ‹“„Š„”››¨©´‹’Š¦§¨¦§¨„Š„uzt¦§¨“Œ”{u{›”›‹„„’ŒŒƒ||””‹ultddc“““slerfk{u{{tt‹‹‹œ¤¦{{ttzl]bZmttƒ„„Œ‹“lri{ttŒŒš{tt\[[mttŒ”•{{ƒƒ}ŠŒ”•tt{‹‹„fkk{{tƒ„„ƒ}Šztlœ››uzt’ŒŒ“Œ”{{ƒ‘Œ…‘Œ…ƒ‚u„„Šedkƒ}ƒ‹‹‹¨©´{u{lriultnƒ|„…{{ƒ”“›lri‚utš””“““‹‹‹{{ƒ››”¦§¨”“›ƒ„„‹’Š£œ¥fkk‹„„‚|u””‹{tttzl£›››”›{{t‚v{{u{tsllddcbVSKJlddf]c£››JHF*)(\[[[TTSKJ‹’Šdc\ƒ}ƒ[TT‹’Š{{tlddSKJtsliq]b[U{{tek]‹‹‹sle””‹lldlrittsultlld]bZ”š”ddc£››ttsf]cttsu{{ultUMR‚|ulddultŒ‹“}‡’|‚z{tt”“›yfl{||‚|utsltt{edkSKJlksuzt{{tJHFtll\[[‹’Škk]›¢›ƒ„„‹‹‹ƒ||lldœ››Šƒ}{zm{ttddcb[U{||z‚l‹’Š”“›{||b[Ud\\VTLf]c\[[b[UUMRj]\‚|u{tt‘Œ…‚|uredsreƒƒ|…„’„Š„{||„Š„uzt”š”kd\kd\ƒ„„™š¤Šƒ}{{tƒƒ|tsl{u{‘Œ…lritlllld{ttzllyleƒƒ|tslttsŒ”•lldekd‹‹„{{ƒŒ‹“yl„]cdultuztult{{ƒ{||tt{¦§¨…‹‹”››uzt…‹‹¦§¨Œ‹“¨©´œ¤¦lrimtt…‹’Œ‹“‹‹‹ƒ„„‹‹‹|„…“Œ””››|„…£œ¥¨©´¤¤‹„„œ¤¦“““¦§¨··Ä‹…’ŠŠ}{{ƒ{u{{{ƒƒƒ|…‹‹”››“““µ¶·Š}ƒ{ttƒ}ƒƒ||“Œ”ƒ}ƒ{ttƒ}ƒ„„Š“Œ”‹‹„‹‹‹“Œ”‹…’…‹‹|‚zœ¤¦mttddctzl{{ƒultf]cƒ||UUYlddœ¤¦|„……‹‹rfk‹…’mttf]cd\\edk£››”››{u{ƒ||ƒ||››”“““lld“Œ”’ŒŒµ¶·’ŒŒƒ„„™š¤‚|u£œ¥Œ‹“‹„„”››„„Šmtt„Š„f]c‹…’Œ‹“’ŒŒ’…‹„Š}„„Š‹‹„‹‹„²¬µ‹„„ttslri„„Šƒ||llkƒƒ|ttsred{{tŠ}ƒ{{tƒƒ|tll‹„„\[[{{tkd\‹„‹ek]fkk¢—FD;3+*Œ”•VTLb[Ulrisrelddƒ||[TTJHFd\\\[[ƒ||sre{zmƒƒ|ztl‚utztlztllld””‹…‹‹“Œ””››ult|„…uzt‹‹„{u{uztultƒ||tt{llk„Š„lektlld\\[TT\[[[[TŒ”•œ››„„ŠbVUztlb[Uttsf]cf]c{||Šƒ}[[TVZTŒ”•|‚z…‹‹tzl|‚z{tt{u{{zmrg]“Œ”ztfkd\dc\{{tultlrikk][TT„Š„’ŒŒttsƒƒ|„„Šdc\ek]\[[mwiWUzlltsl’ŒŒlldldd|„…Œ”•lri””‹|„…tsl‹’Š‚utŠ}|‹„‹£››srekk]kd\ekd‚v{bVZdc\ƒ}ƒtygb[Uƒ||redlldlekult|‚ztts{{t{{tƒ}ƒ„„Š”“›{{ƒ{{ƒ]cd{{ƒ”“›tt{{||™š¤|‚z{{ƒ›¢›Œ”•tt{‹…’£œ¥…‹‹{{ƒª³·…‹š‹‹„‹‹„”››Œ‹“Š}|“Œ”¨©´…‹‹™š¤‹„‹š””‹‹‹{||‹’ŠedkUUY{{ƒ¦§¨tt{š””ultŒ”•‹‹‹¦§¨£œ¥¤¤uzt’ŒŒult£œ¥‹…’’ŒŒ{||{{tldd„Š}{{tred’…‹ztl”››”š”…‹‹š””tsltts{tt{u{ƒ}Štslu{{ƒ„„‹’Šlksƒ„„mttƒ}Š]cdtts‚ut{{ƒƒ„„|‚z”“›£››rfk‹‹‹’…‹œ››‚|u’ŒŒ“““¤¤™š¤„„Š‹’Š™š¤tt{‹„‹“““{u{„„ŠŒ”•lks‹…’Œ‹“£››”š”ƒ„„‹‹„Œ‹“’ŒŒ£œ¥ttstllulttts’…‹f]cz‚llri{u{‹„„œ››‹‹„‚uttts’ŒŒ|„…]cd‹‹‹{u{{{tllk””‹SKJ*)(|‚zd\\\UZ[[TJHFƒ„„ultddc|‚zsle‚ut‹’Š|‚z””‹“““‚v{ultlldzll|‚z“““kd\ƒ„„™š¤‹‹‹œ››Œ”•{{t‚v{ƒ}ƒ…„’kk]f]czll¦§¨ddcnƒult…‹’›¢›ult“Œ”£œ¥”š”tt{kd\{{ƒf]cult\[b{||\[[„Š„llk“““œ¤¦tt{dkV]bZ{u{|‚zslesleztl‘Œ…ekdlri{||[TT{zmsle‚wlƒ}ƒŠ}|”“›{||“Œ”‚wlƒ||dc\Š~‹‚wlŠŠ}ƒ‚nŠŠ}kk]›¢›tslƒ„„lri‰ƒv…‹’|‚ztsl‘ˆ}Šƒ}ztlcbV|‚zd\\‚utultŠ}ƒedk{{ttlltslb[Utlltllƒ||mtt{{tuztkk]lld{{tlks{{ƒ‹‹‹ƒ}Š…‹‹{{ƒ{{ƒtt{ƒ„„ƒ||Œ‹“™š¤™š¤„„ŠŒ”•‹‹‹‹‹‹¨©´™š¤Œ”•…‹’¨©´¨©´¦§¨›¢›…‹štll‹‹„™š¤£œ¥¦§¨£œ¥¦§¨Œ”•ƒ„„{{tš”””“›{{ƒ«²«mttƒƒ|¨©´{{ƒƒ}ƒ™š¤”š”ztl{u{‹„„£œ¥¦§¨›”›µ¶·£››Šƒ}‹„„„„Šttstsl{ttƒ||…„’ƒ„„|‚z‹„„{||Œ‹“ztlult„„Š‹‹‹nv‚{||lri‹„‹„„Š[[T{||{{ƒŒŒšf]c„Š„[[Tƒ„„{{t²¬µlritsl‹‹‹tt{”“›‚|uš””‹‹„“Œ”ƒ}Š›¢›””‹…‹‹™š¤„„Š”“›‹‹‹|‚z“““™š¤{{ƒ“Œ”ƒ||{||{||sle{u{{u{j]\j]\¨©´Œ‹“œ››‚v{{{t””‹‹„‹”“›¤¤Šƒ}’ŒŒ“Œ”tllƒƒ|uztuzt‹„‹„Š„{||””‹D;9*)(f]cVTLlriu{{sre{u{ztlVTLttsddc[TTuztlri‹’Štzl‹„‹£œ¥uzt””‹lriult|‚z{tt¦§¨“Œ”ƒ„„”š”{{t’ŒŒ”››{||d\\llklriƒƒ|tts‚v{{tt‹…’Œ”•‹‹„ƒ||›”›ultultŠƒ}„Š„uzt”“›JHF[[T‚utlritlldc\”“›tt{]bZkd\tsl{u{red‹„„slelddtslŠƒ}sle\[[{{t‹’ŠbVU{{tztfŒ‹“‘…„rfkldd‹‹„sreŠ~‹r]g{||ƒƒ|{u{lri›¢›ƒ„„|„…lek[TTb[Utsl[[Tsle‘…„dc\tllrg]|‚z‚|u{tt{u{kd\{zm[TTƒƒ|ƒƒ|‹„„’ŒŒztltt{uztƒ„„lri“Œ”ƒ„„ƒ}ƒtt{‹„‹}‡’“““…‹’Œ”•{{ƒ…„’|„…”“›|„…edkƒ„„Œ—£œ¤¦{{ƒ{{ƒ„„Š|„……‹’‹‹‹œ¤¦“““…‹’‹’Š”š”¦§¨¨©´ƒ}Š£œ¥·¶Ñœ¤¦Œ”•„„Š”››ƒ}ƒtzl„„Š{{ƒlks{u{Œ”•Š}ƒ¦§¨‹‹‹tts„Š„{u{llk‹„‹‚v{µ¶·¦§¨{u{tll{u{tllƒƒ|{ttultllkttsu{{‹’Š¦§¨””‹¨©´|„…{u{lks†~‘edk›”›„Š„“““„„Š„„Šlks{{ƒlksb[Uyle’ŒŒ””‹“““››”ƒƒ|››”¦§¨“““{tt’ŒŒ‚ut„Š„Œ‹“ƒ|||‚z“““‹‹‹ª³·…‹‹ƒ„„tt{|„…”“›‹„‹™š¤tll‹„„tts{{ttsl‹„„‹’Š‹„„“““Œ”•œ››š…Žƒ‚u’ŒŒŠƒ}ƒ}ƒ|„…ƒƒ|’ŒŒ{tt’ŒŒƒ||ttsƒ„„{||{tttslfkk””‹MRK*)(leksre]bZ{tt„Š„lddkd\d\\UTSUMR{{tuztmttdc\{zm‚v‚tll“““ldd|„…SKJu{{|„…|„…‚|uª³·Œ”•ƒ‚u‹‹„™š¤‹„‹Œ‹“ƒ„„¦§¨kk]\[blksŒ”•edkldd…‹’bVU„„Š””‹{tt‹‹„{zm{{ƒ{u{{u{tllƒƒ|tzl””‹|„…””‹[[TbVUlri“Œ”£››FD;ttsredkd\b[Ud\\{zmVTL›¢›ƒƒ|[TTllkƒ||{||b[U{ttŠ}|sle’ŒŒƒ||kd\lldƒ‚n{{tlld‹‹„{||Œ‹“|„…“““ƒ}ƒlriƒƒ|‹„‹’ŒŒttsb[U‹’Šek]ztlrg]‹„„ƒ‚uztf[TTtts‹‹„‚v‚zllkd\Œ”•llkuztddc‚|u{tttt{tsl™š¤œ››“““™š¤™š¤…‹š|„…Œ”•ŒŒšttsfkkƒ}ƒ{u{{{ƒ›”›{{ƒ}‡’Œ”•|„…|„……‹’}‡’mtt|„…¨©´tts··Ä™š¤…‹’›¢›‹„„‹‹‹‹„‹“““œ››¨©´ttsrfk£œ¥£››‹„„“Œ”“Œ””š”‹‹„‹‹„{u{zll{||‹’Š‚wlœ¤¦|‚zƒ„„uztlkslri|‚zttsf]clekekd„Š„|‚zŒ”•™š¤|„…lkslriultlksdc\tsl|„…‹‹„Š}ƒUUY{{ƒƒ}Š›”›š””kd\””‹›”›œ››‹„‹‹„„¦§¨“Œ”sle””‹ult{{t{{ƒƒ||‹‹„””‹‹‹‹{u{{{ƒ™š¤„„Š{||Œ”•“Œ”f]crfkŠ}|lriztl‹„„‹„‹›¢›‹‹„tt{Š~‹ƒƒ|ddcŠŠ}””‹ƒ||{u{ttsŒ”•‹„‹”š”‹„„ultddcƒ„„{ttultsre\[[ƒ||JHF*)(llklldkd\lldƒ‚u‹„‹ddcd\\UTS{u{ddcttszllddc{zmtll{||tts‚|u„Š„„Š„”š”œ¤¦‹’Šƒ}ƒlkssretsl’ŒŒlri“Œ”j]\j]\¤¤”š”{||lekƒ}ŠŠŠ}{||[[Tf]c“Œ”|‚zzllkd\ttstslƒ„„‹‹‹lri’ŒŒ>EC|‚zŒ”•{u{uztztlŠ}ƒ’ŒŒ{{t{{tsle‹„„bVZu{{ldd{{tlld|‚zlriVTL£œ¥VTLultkd\ƒ||j]\ƒ||]cd‚v{VTLdc\dc\ƒ„„tzl{ttuzt’ŒŒ…‹’‹„‹yle{{tllk‚utƒ||ŠŠ}llktsl‹‹‹tllztl“Œ”{{tek]sleƒƒ|‚utƒ}ƒldd‹„„‹’Šƒƒ|‹‹‹lldƒ}ƒ“““‹„‹{||“Œ”mtt{{ƒ{{ƒlks…‹’|„…tt{”“›{||„„Š{{ƒ™š¤Œ”•ŒŒš|„…}‡’}‡’|‚z…‹’Œ”•tts™š¤“““œ¤¦Œ”•”››lksnv‚mtt“““|‚z{{ƒ™š¤ƒ}ƒƒƒ|ƒ}ƒ‹‹‹mttztl’ŒŒult“Œ”Œ”•{u{ƒƒ|¨©´“““ƒ||{{t“Œ”ƒ||llkddcttsƒƒ|Œ”•’ŒŒ‚v{lks{u{{{tƒ„„Œ”•{u{{{ƒ…‹’ultlksUMR™š¤”››‹’Š|„…lri|‚z]bZUMRd\\b[U‹‹‹llk‹„„”š”|‚z{zm‹„„›”›ƒ}ƒldd’ŒŒŠ}|ƒ„„{tt£œ¥›¢›sre›”›“Œ”¦§¨‚v{Œ—£‹‹„“““ƒ||llkd\\{ttsreƒƒ|›”›œ››“““‹„„ƒ}ƒ{{ƒkd\lddƒ„„›¢›ƒ||›”›“Œ”‰|vŠƒ}œ››ƒƒ|ddc\[[d\\[TT\UZ[[Tƒ}ƒ¤¤74,74,lddVTLb[U‹‹„uztdc\ddc{u{u{{dc\d\\tsl]bZddcredlritllsleƒƒ|ekd™š¤ƒƒ|lekª³·”“›lek„„Š²²¬ultu{{b[U¦§¨tlllri‹‹„{{ƒtt{Œ”•‹‹„SKJUTS{u{{tt””‹’ŒŒtsllldtt{yl„ttsztltllƒƒ|kk]\[[ddc„Š}¦§¨ƒ}ŠultttsŠƒ}|‚zj]\‚|uztlu{{tllƒƒ|ttsƒ„„d\\fkk{tt“Œ”ult{||Œ‹“ƒ„„ƒƒ|“Œ”{zm|„…lksdc\Š}|Œ”•ztf{u{“Œ”“Œ”¦§¨tts‚utult[TTek]ƒ||ztl{ttkd\ztlƒ„„”š”››”{tt{zm‚|uultldduztŒ”•{{ƒƒƒ|{{t‹„‹uztllk‹‹‹…„’ultf]c|„…nv‚fkk{||Œ—£ŒŒš{{ƒ£œ¥“Œ”œ¤¦u{{Œ‹“Œ”•…‹‹|„…|„…|„…ƒ}Š”››tts„„Š™š¤‹„‹ƒ||{{ƒŒ—£mtt””‹„Š„™š¤”››™š¤dc\{{ƒƒƒ|{tt¤¤“““„„Šµ¶·ult¨©´œ››£œ¥zlltllllk”“›ttsu{{‹‹‹”“›”››ekd”“›ƒ}ƒtzlƒ}ƒlldtts…‹‹f]crfkŒ‹“\UZd\\\UZ‹…’|‚ztsl‹’Š‹„„uzt]cd|„…lks[[Tš””{u{‹„„„Š„¦§¨µ¶·”“›‹„„ƒƒ|uzt²²¬{tttts{||{tt‹‹„Šƒ}¦§¨Œ‹“”››‹„„Œ”•”››„„Š›”›{u{bVUƒƒ|”š”‰ƒv{||™š¤“““‚|u”“›ult¦§¨ŠŠ}„Š„|‚z…‹‹ult”“›{||ƒ}ƒkd\‚|uƒ„„|„…Œ”•lrif]c|„…tt{²««JHF3+*bVZllkj]\tll]cdlld]cdult{{tUTS“““[[TlriVTL‚|u„„Šlksd\\j]\ttsœ¤¦‹‹„›¢›™š¤lddldd”››‹‹‹ldd…‹‹‚ut””‹“Œ”››”d\\uztttsedk‘Œ…lekƒ„„“Œ”{u{ƒƒ|‚v{‹’Š|„…{{tslellkVZTlri|‚zz‚lddc™š¤ttstll|„…š””u{{‘Œ…sreb[U{ttŠ}ƒsled\\tts„Š„{ttldd\[b››”ldd{zmtt{„vŒ™š¤tzl‹„‹f]cdc\lri‚|ukk]{yfd\\llkf]c{{tŠƒ}‹’Štlltll{u{‹‹„…‹‹‘Œ…””‹‚utj]\zll|„…‹’Šsle{{t””‹›”›‚v{œ››{{ƒƒ„„‹„„tsl„Š„‹‹‹‹„„”š”{{ƒƒ„„“Œ”¨©´Œ”•Œ—£Œ‹“‹„‹”“›‹‹‹¨©´™š¤ª³·”“›ŒŒš|„…œ¤¦|„…Œ‹“|‚zŒ—£¦§¨…‹‹£œ¥™š¤ƒ||œ››„„Šlks™š¤››”„Š„œ§²{||redƒ}Š‹„‹ƒ„„‹‹‹{tt”››‹‹‹ultŒ‹“··Äƒƒ|ldd‹„„Œ‹“tt{sleuzt‹„‹ƒƒ|fkkƒ}ƒ…‹‹ƒ}ƒlld{||{{ƒ‹’Š…‹‹ƒ„„{u{MSSf]cUTS”“›f]cmtt{{ƒƒƒ|™š¤Œ”•‹‹‹u{{edkedktslƒ||ƒ}ƒ“Œ”””‹ŠŠ}‚wl“““›”›{||”š”‹„„‹‹„„Š„ultƒ}ƒbVU[[Tƒ}ƒtts]bZŒ‹“ƒ„„Š}|{||“Œ”‚v{{tt¦§¨«²«‹’Štsl¨©´…‹‹“Œ”Œ”•Œ‹“{tt[[Ttsl‹‹‹„„ŠŠ}|sle‰ƒvƒ||ultuztŒ”•uztƒƒ|tllUUYddc\[[£››:97&&red{zmJHFVTLMRKƒ‚u\[[[TTVTLJHFVTLtslsle[TTllddc\””‹i\Vtsltts“““ƒ„„lriœ¤¦£››\[bddcƒ||ultœ››{ttƒ||“““ƒƒ|Š}ƒ™š¤{{ƒlksSKJedk{{ƒƒ}Šlld‹‹‹sleƒ„„]cd‹’ŠbVZUTSVTLdkVfkkFD;„Š„aWM]bZVTLSKJƒ||uzt‹„„lri’ŒŒldd’ŒŒ“Œ”lddƒ}ƒtts{ttddctllƒ||redf]cŠ}ƒzlld\\tzlƒ„„{ttuztdkVVTLŠŠ}JHFredf]cult{||tll“Œ”{u{’…‹lekƒ„„{tt{||‚|u‹„„tllƒ||ldd|‚zŠƒ}tts‚ut{ttf]c‚|u‹’Š››”{|||‚zŠƒ}ƒƒ||„…‚v{™š¤…„’‹…’…„’}‡’lks{u{ŒŒš™š¤™š¤|„…Œ‹“›²¦§¨…„’tt{œ¤¦}‡’ª³·…‹’‹„‹{||œ¤¦›²›²œ¤¦›¢›¨©´Œ”•Œ”•£››«²«…‹‹‹‹‹‹…š{{ƒ‚v{‹‹‹ult«²«œ¤¦™š¤“Œ”ƒƒ|¨©´£œ¥rfk”“›£œ¥„„Šƒ}Š„„Š…‹’‚|u{||{{ƒƒ}ƒ{tt{{ƒ››”£œ¥›¢›œ¤¦”››¨©´|„…|‚zd\\“““{{ƒ]bZƒ}ƒlldƒ}ƒœ¤¦ƒƒ|{{ƒJHFult”š”‹‹‹tt{…„’‹„‹””‹tzl{||{tt¦§¨”š”’…‹ƒƒ|„„ŠŒ”•“Œ”|„…lldldd|„…›”›ƒ||Œ”•|‚z„„Š‹„‹™š¤š””sreƒƒ|{yff]c‹’ŠŒ”•|„…ƒ}ƒ{{ƒ‹„„lriVTLek]ƒ}ƒ‹„‹llkcbVldd[[Ttlledk\[buztztl[TTUTSedk””‹:97&&\[[SKJVTLz‚lVZTek]FD;ultd\\|‚z‹‹‹lldsre’ŒŒsle…‹‹kd\jcV‹’Šƒƒ|llk‹’Šlld\[[„Š}uztƒ„„„Š„“Œ””š”‹…’‹…’ª³·£››{tttsl{||›”›tllf]ctlllldŒ”•Œ‹“‚ut”š””››\[[ultSKJ{{ƒ{zm[[TVZTlddJHFu{{lddVTLtlllldd\\tsltsl‚v{‹’Šztllrillkttsj]\lriUTSb[UlddŠƒ}lddƒ}ƒultzllf]ckd\lritzluzt››”‚wllddttsƒƒ|‚utreddc\‚uttts{{ƒ“““Œ”•‹’Šƒ||Šƒ}‚wl{{t{{tddctlllriŠŠ}redddc{{tztltsluzt|„…‹„‹”š”u{{„Š„ƒ}Š„Š„’ŒŒ…„’{{ƒ{{ƒ‹…’™š¤u{{ŒŒš{{ƒ”››…‹’Œ—£{{ƒ{{ƒŒ”•…‹’“Œ”Œ”•¨©´™š¤…‹‹Œ”•™š¤£››‹‹‹™š¤edkœ¤¦›¢›¦§¨™š¤”››‹„„›”›”››œ›››¢›¦§¨‰‘~ŒŒš£œ¥µ¶·¨©´‹„„¦§¨¦§¨™š¤‹…’„Š„|„…ƒ||“Œ”tt{Œ‹“‘Œ…“Œ”Œ”•‹‹„‹…’”››lrimttŒ”•‹’Šekd{u{rfklks\[buzt’ŒŒ“Œ”u{{Œ”•…‹‹f]c[TT„Š}“Œ”ult”“›œ¤¦‹’Š‹’Š‘…„{|||‚ztts“Œ”ult‹’Š“Œ”ƒ}ƒ‹„‹|‚zb[Utts£œ¥‹„„{||{tt‹‹‹ƒ}ƒƒ}ƒ”“›‚|u|‚z„Š„Œ”•‹„‹«²«“Œ”ldd\[[‚|u]bZkk]sleŠ}ƒldd{||„Š„{{t{tt››”‹‹‹|„…|‚ztlllek{||JHF£››JHF3+*edkek]lldb[Udc\lld\UZVTLVTL[TTlddlld{{ttlllddƒƒ|Šƒ}yle¤¤‹‹‹{||{{t„„Š|„…{u{‹’Š”“›ƒ„„‹„‹›¢›”››{u{{{ƒšŒ›¢›fkkr]Z{{ƒs_q‹…’rfklek™š¤lld”››‹‹„uzt‚v{ƒ‚uldd‹’Šƒƒ|MRK]bZVZ[llklld‚utekd‹„„ddcztl]bZUMRztfdc\Šƒ}JHF\[[f]cƒƒ|Š}ƒ{||j]\tllkd\d\\…‹’ƒ||{ttttslks„„Šƒƒ|œ¤¦Šƒ}£œ¥Š}|lldllkultlddlld””‹{tt‚v{››”‹‹„“““rg]’…‹’ŒŒ{tt{ttlldf]c{{ttllllklddredƒƒ|{{t›¢›¤¤œ¤¦“““”š”””‹™š¤u{{…‹‹Œ”•…‹’„„Š…‹’™š¤œ¤¦Œ—£mtt™š¤‹…’”“›{{ƒlks›²œ§²œ§²œ¤¦”››£²{{ƒ{||lri‹‹„sre…‹’u{{…‹‹|„…|‚z|‚zŒ”•””‹‹…’ultœ¤¦“““ª³·”››ŒŒštts“Œ”™š¤„Š}„„Šƒ}ƒ‹„‹“Œ”Š}ƒu{{ztl{{t”“›ttsj]\š””uzt‚|ubVZmttŒ”•VZ[|‚z…‹‹tts{{ƒ‚|uf]c‹…’”“›””‹ŒŒštllekdUTSlks†~‘[[T{{tlks{{t¦§¨””‹¦§¨’ŒŒtllƒƒ|£››‘…„ldd„Š„tt{Œ”•‹‹‹£²‹„‹ƒ}ƒ›”›ult…‹‹“Œ”edk›”›tt{{{t‚|uƒƒ|„Š„|„…‹„„{||lldlksultb[Ulld{{t[[Trfkult’…‹ƒƒ|lld””‹”š”„Š„‹‹‹ekd‹‹„[TTtslddc²²¬FD;*)(ultddcSKJD;9JHFcbVf]cSKJ[TTldd\[[tslŒ”•[[Trfk„Š„Š}|lld{zm‹’Šuzt{{tlri„Š„ƒ„„’ŒŒŒ‹“„Š„{tt’ŒŒ\[[‹„„{{ƒf]c«²«„Š„…‹‹{||Š}ƒƒ„„‹‹‹ultŠ}ƒbVZ„„ŠbVU…‹’š””””‹{{t›¢›Ž¡›ult]bZultldd[[Tlddlld“““[TT‚|ub[Ulld‚|u{ttek]ddcddcVTLSKJFD;kk]ult{{tddcuztVTLtllbVZ{||[TTtslldd¦§¨lritllŠ}|ƒ„„{{tƒ||bVUttsredredzll‹‹‹{{t|‚z{{tztl|„…|‚z‚utœ¤¦kd\…‹‹ztl‹„‹edk|‚z…‹‹lld‹„„‹„‹‹„„”››Œ‹“uzt|„…{{ƒŒ”•}‡’¨©´œ¤¦™š¤›²œ¤¦™š¤ƒ}Š‹„‹„†™}|’{{ƒ{{ƒŒ—£œ¤¦|„……‹šf]ctt{ultŒ”•…‹’‹‹„‹’Š„„Š{||¨©´«²«‹’Š…‹‹mttŠ~‹…„’{{ƒŠƒ}””‹œ¤¦|„…Œ‹““Œ”‹„„Œ”•„Š}ƒ||„Š„…‹’{tt‹’Š{{ƒŒ‹“d\\{||f]c‚v{r]g{{ƒ‚wl{|||‚z]cd|‚z|‚z„Š„{{ƒ|‚z{||f]c™š¤tslƒƒ||„…lld‹‹„†~‘‹’Š£œ¥„Š„ƒ||{{ƒlld…‹‹‹„‹‹‹„ƒ||“““Šƒ}ƒ||Œ‹“tsl‹‹‹™š¤ldd„„Š’ŒŒrfk“Œ”ƒ}ƒldd…‹‹{u{|„…›”›ƒ„„tt{ƒ||«²«lriƒ}Š™š¤Œ”•{||{||Œ‹“d\\kd\tsl\UZlddultu{{uzt|‚z’…‹’…‹‹’Šƒ„„‹’ŠŠ}|f]cVZT\UZ¦§¨UMRlddVTLFD;FD;‹‹„[[T‚ut[TTfkkƒ}ƒ[TT[[T‹‹„lek[[Tƒ„„ztfVTLcbVdc\‹‹„tslfkk“““|‚zmttek]’…‹ƒ||tzl“““{{tttsœ››¤¤’…‹tt{ddc‹‹„ƒ}ƒš””’…‹‹„„Œ”•¦§¨VTL\UZ””‹”š”|„…‹‹‹”š”ª³·lriedkdc\|‚zztlttstllekd‹„„SKJ‹‹„ttskk]ƒƒ|uztlldSKJ‚|utsltlld\\f]ckjVƒƒ|SKJb[Uztluztulttsl‘Œ…‹’Š|‚zsle{tt‹‹‹‹‹„Š}ƒlks[[Tkd\red‹„„ƒƒ|kk]u{{‘Œ…lddllk{{ƒsledc\f]cƒ„„š””Š}ƒult”››‹’Štllztlƒ||llk{||{{ƒƒ„„ƒ}Šmtt™š¤}|’{{ƒŒŒš™š¤‹…’nv‚˜Ž£}‡’ult{{ƒ™š¤›²}|’{{ƒ}‡’Œ”•|„…Œ‹“Œ‹“™š¤|„…ŒŒš¦§¨”š”…‹‹Œ—£”š”|„…tzl|„…Œ”•|‚zultƒ||‹’Š””‹“Œ”„Š„¦§¨lks{tt…‹‹„Š„{||›”›Œ‹““Œ”o€w|„…{ttsle|„…‹’Š‹‹‹ult¦§¨‹’Šredekd…‹‹œ¤¦|‚z]cd|„…mtttslmttedkŒ‹“‹‹„uztcbV\[[››”œ§²|„…™š¤‹„„ƒ||f]cŠ}|œ››œ¤¦š””‚v{š””[TT{{ƒ””‹”››Œ”•tllŠƒ}{{ƒd\\ƒ}ƒŠƒ}{{t{||ddcddc…‹’“Œ”rfktsluztddcult¦§¨llk‹‹‹”š””“›‹‹‹dc\››”‚|uUMRƒ}ƒtsl{||tsld\\ttsddcu{{{u{{ttlekVZTddc²««D;9*)(dc\VTLFD;D;9ek]kk]bVUult{{tlksd\\lrilriVTLlks‚|uj]\cbVlldVZTuztMRKƒ„„u{{{ttŒ”•lriœ¤¦u{{ƒ‚u{tt“““‹‹‹mtt²²¬ttsƒƒ|mttf]c™š¤tsl‹„„ult„Š„Œ”•ŠŠ}”“›ƒƒ|ulttts]bZ„„Šƒ„„{ttultztl{{tztl]bZ“Œ”{zmlri\UZ„Š}{u{Š}|d\\uztƒ}Šƒƒ|Š}|sreœ››‘ˆ}f]c‚v‚{{tlddSKJ‹„„ddc‚v‚ek]VTL[TTdc\llkddc\[bƒ„„ƒ||”š”tsllldredUTSlldkd\ƒ„„redVTL{||[[TFD;llklddtsltsl{{ƒf]cfkktsl‹„‹ƒ||llkultlrifkk„„Šmtt|„…‹’Š|„…{{ƒ…„’Œ”•”“›œ§²¡¡mk…}|’Œ—£{{ƒlks{tt‹…š|„…¨©´Œ”•…‹‹”“›™š¤Œ—£¨©´‹„‹Œ”•‹„‹Œ‹“¦§¨|‚z‹‹‹lri|„…Œ‹“{u{}‡’’ŒŒ{{tƒƒ||‚z™š¤]cdlks…‹‹Šƒ}œ››{tt™š¤Œ‹“ŒŒš…‹‹lek››”…„’ª³·‹’Š¤¤{{ƒ{u{ƒ„„›¢›mtt™š¤{||VTL|‚z]bZtsl„„Šult‹’Šdc\‹‹„”š”™š¤™š¤|„…‹…’”š”’ŒŒ‚v‚{{ƒult¦§¨‹’Šœ››{u{ƒ||tsllek¦§¨Šƒ}ƒ„„“Œ”{u{{ttƒ}ƒ„„Š{u{sle“Œ”‚v{f]c{{tƒ}ƒƒ„„ƒ||lriztledk{{ƒ|„…››”™š¤“““¦§¨sle‘Œ…{u{d\\{||‹‹„mtttslultdc\|‚z{{ƒkd\ldd\[[tt{\[[¦§¨SKJ&&j]\Šƒ}f]cVTLJHF]bZzlltll]bZllklld››”tzlsleuztultVTLtll]bZ[[Tu{{tzl”š”llk|‚z‹’Š|‚zŒ”•{{td\\²²¬{||Œ”•ekd‹’Šlld{{ƒf]cedkš””lldbVU“Œ”lddult[[Ttt{SKJ{ttlddu{{lriUTSdc\rfkƒƒ|tsl{{ttslzll|‚zƒ||{ttttslldddcMRKf]clkstsl‘Œ…ekdƒƒ|‘…„{{ƒldddc\{u{FD;Q?@ultƒ}Šdc\ƒƒ||‚z{{t†~‘„Š„mttlldultŠƒ}|‚z{zmf]cuztŠŠ}{||UTSylerfk{ttdc\sle{||VTLtzlbVUlddllkdc\lddƒ||ztfllklddƒ}ƒu{{mtttt{uzt…‹’nv‚ŒŒšedklkstt{¨©´œ¤¦Œ”•›²œ§²“Œ”¨©´lks}‡’}‡’|„…u{{¦§¨„„Š£œ¥™š¤™š¤£œ¥œ››|„…|„…œ››œ››œ¤¦›¢›{{ƒu{{ultyl„ttsµ¶·‹„‹Œ”•\[[lkstsl…‹‹llk‹‹‹lri…‹‹{{ƒ””‹{||›”›„Š„„„Š{{ƒ¦§¨“Œ”£œ¥„Š„ldd|‚zlksƒ}ƒmttlrirfk\UZd\\\[b‹’Š{{ƒ‹‹„››”tslmttlkslksƒ„„{tt{tt|„…¦§¨’ŒŒ’ŒŒœ¤¦Šƒ}Œ‹“””‹ƒ||™š¤£››””‹{||’…‹{{ƒultult{{ƒ|‚z‹„„œ››|‚z™š¤{{t{{ƒƒ||””‹|‚zƒ||{||œ››‹’Šœ¤¦‹’Šƒ}Š„„Š’ŒŒ{{tddc{tt{{ƒkd\lriƒƒ|lld{ttƒ„„ttsƒ„„ztlfkk]cdllk””‹bVU-1+ldd{{tF=CsletllSKJ{zmzllldd\UZslelldddcd\\ƒ„„‹„„r]ZŠƒ}„Š}|„…JHF{zmfkku{{‹’Š„Š}lriuztƒ}ƒƒƒ|“““”š”tt{kd\{||VZTlksllk“““‹’Š›¢›[TTƒƒ|uzt„Š„Šƒ}›”›lddtlllriUUYVZTVZTUTS‹‹„‹‹‹{{tslettskd\ƒ„„VTLkd\tsl‹’Š…‹‹[[T\UZ‹’Š‰|vkd\ƒƒ|{{tsleƒ||SKJ””‹f]csre{tt{{ƒultƒƒ|rg]‹’Š„Š}lddtslbVUlri‹„„‚v{d\\UTSslekk]ƒ||”š”‹‹‹{{tŠ}|{ttttsek]{||ztlttslddjV[\[[\UZ{ttult‹‹‹ƒƒ|{{ƒ{||fkk“““£²„„Š…‹’{{ƒnv‚{||u{{{{ƒ„†™Œ—£œ¤¦}‡’Œ—£{{ƒ{{ƒyl„{{ƒ…‹’Œ”•™š¤™š¤ttsŠ~‹œ§²ŒŒšª³·™š¤£››‹’Štzl›¢›lldª³·ª³·lrimtt™š¤tll¦§¨ztlŒ‹“Œ”•ƒ}ƒ‹‹‹zllƒƒ|‹‹‹“Œ”™š¤{{ƒ””‹”“›‹‹‹bVZ|„…‹‹„‹„„{tt{{ƒ[[Ttll…‹’|‚zŒŒš„Š„[[Tƒ„„„„Š‹‹„ttsŒ”•|‚z]cduzt{{t{{ƒUMR|„…d\\{zmƒ}ƒ‹„„…‹‹ƒƒ|‹„„ƒ„„sleldd‹„„”“››”›””‹¦§¨ƒ}ƒ“Œ”¦§¨{u{{u{…‹‹Œ”•””‹ƒ}ƒ„Š„|‚z‹‹‹”“›‹„„ddc{||„Š„{{ƒult‹’Š’ŒŒ|‚z“““kd\“““››”„„Šš””redŠ}|tzl“““sle[[T|‚z]bZb[U[TT\[[UTSf]c¦§¨FD;*)(f]c‚|uSKJ]bZlddJHFddclldddc\[[“~ˆtzlekd{||ult“Œ”“Œ”tzlu{{Œ‹“llklldtt{ekd›¢›lkszlltt{uztƒ‚u‹’Š}|’””‹‹’ŠtsltllVTL{tt‹’Šztl…‹‹uztVTLlri‹‹„ƒƒ|‹‹‹‹„‹{tt]bZJHFb[U]cd]bZmtt{tt{zm‹‹‹[[Tlld{u{sreult{||]bZttslld[TTcbVVTLb[U””‹[TT{zmi\VbVZtllƒ}ƒsletlledkUMRek]kk]””‹VTLlddUTS“Œ”‹„‹‚utultkd\{||“Œ”cbV{tt|‚z‹‹‹””‹tllbVZuzttsl{||ƒƒ|lld‰ƒvtsllksbVZ{||ulttll{{ƒultmttfkk„Š„™š¤‹‹‹“““Œ—£{{ƒlksŽ¡›mtt‹…š…„’Œ”•…‹šŒ—£|„…„„Š…„’…‹š~’“ekdŒ”•ƒ}Š›”›ŒŒš…„’£››‹„‹™š¤›¢›“““›”›”š”ƒ||””‹ª³·ª³·‹‹‹{{ƒ‹’Š‹‹‹‘…„™š¤Œ”•{{ƒš””¦§¨“Œ”››”ldd‹‹‹£œ¥ŒŒš{{ƒ™š¤Šƒ}|‚zŒ”•ztlƒ„„{u{{||’…‹{{ƒŒ”•›”›‹’Š‚utf]c™š¤“Œ”ƒ„„lriUUYmttUTSdc\]cdtts{{ƒekdlek‹„‹lekŒ”•››”ttstzl‚wlŠ~‹›”›‹‹‹”“›lksœ§²|„…£œ¥{{ƒtsl{{ƒ™š¤‹‹„¦§¨Š~‹‹‹„u{{‹‹„ƒ}ƒƒ}ƒ‹‹‹ƒƒ|‚|u{||tt{fkk„Š„Š}|ultlri{{t‚|uƒ}ƒƒ„„ƒ}ƒƒƒ|ƒƒ|””‹‘Œ…ztlƒ„„tslVTL{ttultfkkUTS¦§¨MRK*)({tti\Vkd\FD;bVUPF=dc\UMRdc\sle„Š}tsl{u{ttstll›¢›jcV‚|utygƒ„„ƒƒ|u{{d\\mttekd„Š„ƒ}ƒŠƒ}|„…ƒ}Šuzt|„…|‚z””‹b[UddctllŠ}ƒŠŠ}\[[‹…’{zmj]\„Š„’ŒŒ‹„„[TT’ŒŒtlltts…‹‹Œ”•u{{lrillk›”›tllztld\\‚v{|„…ztlVTLttstzl{{ƒ{||„„Š[[Tb[U{{tŠŠ}\[[VTLJHFlddiq]d\\VTLlld]bZSKJJHFƒƒ|ƒƒ|ƒ||f]c„Š}ƒ}ƒddcd\\tll‚|u”“›“““lld£››‹’Š{u{’ŒŒŒ‹“ƒƒ|mtttsl{||Œ”•mttƒƒ|mwtts‹„‹[TTtll|‚z„Š„ƒƒ|ddcMSSlek™š¤Œ‹“lks|„…}‡’…„’|„…{{ƒ‹‹‹Œ”•Œ”•™š¤ƒ„„…‹’¨©´{{ƒŒ—£nv‚Œ”•…‹‹“““£²”››ŒŒš””‹{u{{{ƒ¦§¨ƒ}ƒ‹„„‹‹‹|‚zœ¤¦œ¤¦»ÂÇ‹„‹lks\[b›”›{tt„„ŠŒ”•Œ”•]bZ‹„‹‹„„””‹ult’ŒŒ„†™{{tœ¤¦””‹Œ”•„Š}tts„„Šultœ¤¦‹„„{||¦§¨”š”ª³·„„Šƒ„„£œ¥{{ƒ{{tŒ‹“JHF\[[LKRMRKVTL\[bJHFu{{u{{red£œ¥Š~‹|‚z“Œ”tts¦§¨›”›¨©´²««”“›””‹”“›Œ”•Œ”•‰v|ƒƒ|ª³·ttstt{…‹‹‹…’ultœ››“““ƒ}ƒ“““™š¤ƒ||ekd…‹‹ddcedk‹„‹ldd{zmmttultdc\ƒƒ|llk‹„‹‹„‹‹„„{{ƒ››”‹„„sle‹’Šdc\ƒ„„{tt]bZ]bZVZT£››b[U*)(f]ckk]Š}|FD;UMR{tt[[TVTLSKJVTLj]\VTL{u{ƒ||tlllldkk]ztl‹‹„‹‹‹”š”tslmtt\UZ„Š„Œ”•{u{‹‹‹™š¤{{ƒ«²«›¢›{||‹‹„{{tƒ„„‚utekdbVZUMR™š¤‹‹„{u{{||‚|u‹‹„lek‘Œ…””‹{{ƒuzt{{tekdJHFUMRldd|‚z‰|vf]c‹‹„{||ztl{ttVZ[‰‘~”››{{ttll{tt[[Tkd\ƒ}ƒFD;VZTd\\lddb[UtlllldlddJHFultekdƒ‚u””‹ƒ„„dc\tslƒ||dc\“Œ”¦§¨{{tkk]{ttƒƒ|‘Œ…››”ultredtt{|‚ztsl‹‹„Œ‹“š””{{tzllLKRmttƒ}ƒbVU{{ƒlri“““uztmtt{{ƒtt{}|’{||Œ”•{{ƒ|„……‹šŒ—£™š¤{{ƒ|„……‹’œ§²·¶Ñ¨©´”“›{{ƒœ¤¦œ¤¦|„…}‡’“““¦§¨œ¤¦Œ‹“¦§¨‹‹‹¨©´£›››¢›Œ”•™š¤””‹‹‹‹|‚zfkkf]clksŒ—£zll‹„‹‚v‚¬¶Ãš””lldredƒƒ|ƒ||„„Šœ››Œ‹“Œ”•Œ”•œ››Œ”•¦§¨lld|„…{tt”››‹’Š{u{„„Š„Š„{||uzt|‚z{tttt{JHF„„Š†~‘ƒ}ŠŒ”•…‹’zlluztlriVZTlrillkŠ}|llk„„Š{u{›”›‚|uztlƒ}ƒultƒƒ|™š¤¦§¨¦§¨‘Œ…”››™š¤”“›ƒ}Šf]clldƒ}ƒ{{ƒ‹„„‹‹‹„Š„ldd|„…llktts…‹’ekd£œ¥‚v‚tll‹„„ƒ||{ttleksletll‹„„‹„„ƒ||JHF{||zllkd\JHFUTSlek‚utfkk\[[ddc‘ˆ}JHFSKJbVZkk]b[UPF=3+*FD;[TTD;9JHFlddtsldc\{ttdc\‚ut{u{{||ƒƒ|¤¤ƒƒ|ttslddddcult[TT|„…™š¤“Œ”¬¶Ã¨©´œ¤¦Œ”•‰‘~iq]„Š„tllb[UddcUUYf]c{tt|‚zddc{u{dc\‚v{tslultƒ„„rg]Œ”•|‚zekd[TTlks‘…„{||lek”“›ƒ||b[Uš””›”›[[TŒ”•UTS{ttrfksresle”››j]\ttsUUYuzttllVTLleksre‚ut‚wl\[bƒƒ|“““ddcultlld‹‹„ƒ||\[[{{ƒ£œ¥””‹‹‹„‹„‹{{tš””{{tlksredultœ››Œ”•£››{||tllmttrg]ttstt{{u{ult{u{””‹…‹‹{{ƒ…‹‹…‹‹Œ—£Œ”•u{{{{ƒŒ”•Œ—£Œ‹“…‹šŒŒšŒ”•…‹šŒ”•™š¤Œ—£»ÂÇ”››™š¤œ¤¦…‹‹Œ”•‹„‹™š¤¦§¨š””™š¤¦§¨™š¤›¢››”›‹„‹tzlŒ”•”›››¢›Œ”•u{{yl„MSSuzt{{t”“›“““Œ”•„Š„ƒ}ƒƒ}ƒ‹’Š„Š}”“›™š¤tts™š¤”“››¢›|„…‹„‹|‚z\[b›”›u{{{{t“Œ”Œ—£|„…[TT„„Šmtt\[[{{ƒUTSultŒ”•“Œ”™š¤|‚zlddllk{{ƒŒ”•llk‚|u‚v{Œ”•ttstt{ultztl‚v{“Œ”ƒ„„›”›”››ª³·¦§¨‹…’›¢›ƒ„„|„…\UZƒ}Šrfk’ŒŒ‹„„ldd’ŒŒŒ”•„Š„‹„‹ƒ||”››llkmttƒ}ƒ„„Šmttu{{ultttsŒŒš‰|v{{ƒ‹„‹zllSKJd\\lriu{{ek]„Š„|‚zsleztl[TTVZTllk¦§¨:97*)(u{{SKJJHFSKJ3+*SKJD;9F=Cf]crfkVTLƒƒ|{tt‹„‹“~ˆddcsrejcVlldlld”››edk[TTƒ„„mttƒ„„‹u…‹„‹lriƒ„„ek]lri”š”«²«ƒƒ|ƒ„„ztl‹„„{ttƒ}ƒƒƒ|u{{[TTd\\VTL{{tult››”‹„„Œ‹“u{{u{{ttsfkkUMRb[Ulld{tt\UZŠŠ}VTL’ŒŒ‚v{„Š„‹‹„ultƒ||redlks”š”‹’Ši\V[[T‹’Štyg‹’Šlddult‚|uƒ‚uƒ„„f]c|‚ztlltslVZ[„Š„tzl[[T{u{ult‹„‹“““‚|u¦§¨ƒƒ|tts””‹£œ¥£œ¥”››””‹”››{{t{u{VTLlri“Œ”{u{“Œ”…‹‹›”›ddc’ŒŒultkd\u{{Œ”•™š¤ŒŒš‹‹‹…‹š…‹šmtt{{ƒ|„…„„Š|„…ŒŒš{{ƒŒ”•™š¤œ§²…‹‹‹‹‹|„…¨©´™š¤™š¤Œ‹“{{tŠ}ƒ†~‘“Œ”‹‹‹|„…’ŒŒª³·š””œ¤¦œ¤¦‹‹‹‹’Š”››\[[tt{{||ƒ}Šƒƒ|Œ”•‹’ŠŒ”•Œ”•œ››™š¤‹‹‹‹„‹ddcƒ}Š›¢›}‡’™š¤Œ”•ƒ}ƒ„Š„‹’Š„„ŠUTSVTLb[UŒ”•lriuzttt{lri[TTultultult{{ƒ™š¤Œ”•tlllrilks|‚zlks“Œ”‚utf]c{{ƒultŠŠ}tts{||{ttŠ~‹ƒ||‚v{£››tzllkssreUTSddcnƒVZ[lksŒ‹“ƒ||lddƒ„„ƒ||ƒƒ|uztƒ„„›”›{{ƒ{u{Œ”•ƒ„„…„’”››ƒ„„ƒ}ƒ{||œ››‹’Š‹‹„‹‹‹sle[TT\[b]bZsletslVTLekdztl‹u…[TTu{{llk²««UMR*)(\[[rg]bVUVTLVTLkd\ttsƒƒ|rfkŠ~‹ƒ„„tzlƒƒ|ƒ||[TTtt{‹‹‹kd\VTL{{ƒ„Š„tsl‚|uƒ„„f]c[[T{{ƒ”“›ttsmttek]{{tuztlriVTLlek‹„„ttssle‹„‹„„Šttsuztkk]r]Z“Œ”¦§¨Š}|kd\f]cJHFddcfkkf]cUMR{u{lldult[TT””‹[TTrfk{{td\\‹‹‹ƒƒ|™‹†ult¨©´”š”lks‚|u“““|„…tlllldkd\{u{|‚z‚ut‹‹„‹…štslb[Uddctsluzt”š”‚|uƒ}Š‚v‚{{ƒš””tllœ››‹„„””‹tts“Œ”’ŒŒª³·››”{||‹„„tts‚ut‹’Šzllƒ}Š{{ƒldd{u{‹„‹‹‹‹ƒ}Šllk‚|u|„…Œ—£œ¤¦Œ”•™š¤}‡’{{ƒ{{ƒ}‡’|„…mtt…„’Œ”•}‡’™š¤ƒ„„”“›„„Š|„…Œ”•Œ”•Œ”•™š¤ddcŒ”•ttsŒ‹“ult¦§¨œ››‹…’‹‹‹|‚z””‹ƒƒ|”“›Œ”•£œ¥™š¤lkslks”››Œ”•‹’ŠŒ”•{{ƒ‹‹‹‹u…uzttll‹‹‹…„’Œ”•mtt\[b„„Šmttmtttt{ultlks‹’Š[TTuztVTLddcƒ„„fkk{tt†~‘™š¤„„Šlddyl„{{ƒttslri{{ƒ‹‹‹|„…œ¤¦ztlš””ult|‚zŠ}|£œ¥”š”{{t{u{{u{‹‹„Œ”•tts{||lriƒ„„tt{ddcu{{\UZ‹„‹tsl{ttŠŠ}ultƒ}ƒ¨©´ƒ}ƒ{ttŒ”•{{ƒtt{…‹‹llk{||ddcf]crfkƒ||’ŒŒ››”Š}|tslbVUf]c‚|u\UZ{zmƒƒ|tts[[Ttsld\\|„…{||¤¤MRK:97{ttdc\D;9SKJVTLVTLf]c\UZbVZ‚v{uzt{||slekd\ekdlkstzlŠƒ}uztlrifkkƒ„„ƒ||ttsƒ||\[[ekdtll\[[\[[mtt‰ƒv{ttVTLdc\rfklddtll‹„„{u{|„…ttsƒƒ|UTS{{t‚v{¤¤tllbVUVTL\[bttsult\[bllkŠ}ƒ{{ttllddc“““ƒƒ|UTS|‚zVTL|‚zultrfkult¦§¨„Š}¦§¨i\VŒ”•|„…{{ttt{‚utlriztllriu{{lddœ¤¦lj|„…‹„‹„Š„{||{ttƒ„„‹„‹{u{‹‹‹Šƒ}„Š}lddŠƒ}{{t‹…’ƒ}ƒƒ„„‚|uttskd\tts‹„‹Œ”•‹‹‹ƒ}ƒtts|‚z‹‹‹lks…‹‹{{ƒ|‚zƒƒ|edklri|„…„Š„…‹’|„……„’ŒŒš}‡’ŒŒš|„…Œ—£|„…”››œ¤¦”“›¬¶Ã¦§¨…‹š¦§¨œ§²œ§²›”›µ¶·¦§¨Œ”•œ¤¦“Œ”™š¤ƒ}Š£œ¥’ŒŒ›¢›”š”œ››“““lri“““ultttsd\\{||„„Š‹’Šœ¤¦¤¤f]c’ŒŒ|„…tt{¨©´ƒ}ƒœ¤¦Œ”•u{{Œ”•…‹’œ¤¦lks|„…mttlld[TTekd|„…”››ƒ||{{ƒ“““‹’Š“““{{tekd£›››”›„„Š‹‹„…‹šek]ddckd\ult›”›{u{ttsldd›”›¦§¨ƒƒ|“Œ”tlllek|‚zuzt|„…sre‹„‹{u{[TTtslultult{{tƒ|||‚z’ŒŒ“Œ”Œ”•ƒ}ƒ‹‹‹tt{lksmtt{{ƒ{{ƒ„„Šllk{{ƒtts‹‹„œ››””‹tsl{{tŠ}ƒrfkVTLtllVTL]bZ{||ƒ||tllf]c[[Tddcƒ„„MSS*)(tslb[U[[TaWMJHFSKJuztVTL[TTultddcdc\{zmlld„„ŠŒ”•cbVUTScbVŠ}|\UZ{ttultš””œ¤¦„Š}u{{tll|„…tts„Š„ztl{{tdc\tt{{tt{{tekd““““Œ”Œ‹“\[[srekd\ƒƒ|‰|v’ŒŒšŒ{u{r]g|‚zddc„„Šlks‹„‹‹„„lldyl„d\\tts„Š„tlltll[[T[[TŠ}|{ttlri|‚zVTLrfk‘Œ…tllŒ‹“sreldd{ttUTSkd\…‹‹UTS]bZ›¢›’ŒŒu{{‹„‹uzttlllld{{ƒsle\[[ƒƒ|„Š„‹’Šuzt””‹”š”‹‹‹f]c|„…ttsddclekœ››”››|„…‹„„{u{ttsttskd\edklldŒ‹“‹‹‹{||{{ƒ\[b|„……‹‹…‹’{{ƒtt{Œ—£Œ”•œ¤¦›²{{ƒŒ”•{{ƒŒ—£Œ—£™š¤lksœ§²…‹‹£œ¥›¢›Œ”•œ››ƒ„„Œ”•„Š„”“›Œ”•œ››ƒ}ƒ…‹‹Œ”•…‹‹¦§¨œ››™š¤“Œ”\UZ]cdldd|‚zŒ‹“ƒƒ|”š”tt{‹…’¦§¨ƒ||™š¤‹’Š›²¦§¨lriedk\UZ‹‹‹ttsttsmtt]bZlriƒƒ|u{{\[[›”›“Œ”|‚zkd\lddƒ‚u”š”ƒ||SKJtt{Œ”•u{{‹„‹“Œ”ult“““£œ¥ulttt{Œ”•ƒƒ|‹„„“““¦§¨¦§¨¤¤š””{|||„…ult]bZƒ}ƒUUY]cdldd{{ƒœ››{{t|‚z‹‹‹””‹‹…’”››„„Šlek…‹‹{{ƒ|„…lks|‚zuztulttt{ttsƒ}ƒ‚utƒ||dc\‚|urfk‚v{{||{tt|‚z]bZUTSsle[TTllkUTStt{£››LKRD;9lldkd\[TTVTLPF=VTLVTLf]cultf]cddc{{tdc\{u{kd\‹’Šlrilldtslkd\VZTred“Œ”{u{«²«uztu{{ƒƒ|lddŒ”•ldd{tt…‹‹]bZMSSlddkd\‹‹„ƒƒ|{u{…‹’lks|‚zdc\Šƒ}lddŠƒ}‹„‹Šƒ}lriUUY|‚z{{ƒ:97lksult|‚zultƒ„„››”{{td\\mtt{{tllk“Œ”rfk[[Tdc\Š}|‹„„Š}|‹‹‹{||ƒ„„‹‹„ƒ‚u{{tsle|„…|„…lek›¢›”š”””‹œ¤¦¦§¨ƒ||Œ”•ƒ}ƒtll{{t|‚z‚|u‹‹‹{{tlld|‚zuztlddŒ‹“„Š}‹‹„‹„„¨©´’ŒŒŒ”•‹‹„lks|„…]bZUTS{u{{||ttsƒ„„{||mtt\[b|„……‹’…‹‹|„……‹’Œ—£Œ—£™š¤¬¶Ã™š¤|„…~’“„†™|„…{u{{{ƒŒ—£”››¨©´|„…™š¤Œ”•™š¤¨©´|„…™š¤u{{‹…’’ŒŒekd|„…œ¤¦‹‹‹tllmttd\\lksŒ”•‹‹„£²rfk„Š„Œ”•ƒ„„‹„„“Œ”ƒ„„œ¤¦ƒ}ƒ…‹‹Œ”•{{ƒrfku{{llkekdldd‹‹‹¦§¨””‹ztltt{ekd„„Š{{tŠ}|tll|‚z|‚zmttrfkƒƒ||„…fkk{||ddcultult‹‹‹™š¤rfk™š¤{{ƒŠ}ƒƒ„„”š”””‹“Œ”„Š„Œ”•œ››‹’ŠŒ‹“ƒ„„”“›{{ƒƒ}Š[[T…‹’‹„„{u{ƒ‚u{||””‹edktzlult{tt|„…{{ƒtts{{ƒu{{|„…‹’Š“Œ”lldŠ}|{{tddc‚|uJHFJHFlddttsult‹‹„{{tlritsl[TTllkdc\ddc””‹FD;:97UTS]bZd\\VTLSKJrg]lriyle{{tekdlrilldkk]]bZ‹„„edktsl””‹uzt{||edkŠ}ƒ{u{ƒƒ|{tttslŒ”•ƒƒ|lld…‹‹‹‹‹{ttƒƒ|mtt{{t{||[[T››”tts‹‹‹\[[Œ”•|‚z£››‹’Š“““š”””››{{ƒœ››\[[”“›ekdUTSf]cUTS”š”|„…‚v‚[[Tlks{ttlks[[Tƒ}ŠSKJr]gSKJUMRkd\ŠŠ}b[Uultekdllk”š”aWMŠƒ}ƒ||›¢›…‹‹{{ƒŠƒ}¨©´œ¤¦¦§¨‹’Šœ››“Œ”{u{zll‹„„uztƒ}ƒ|‚zldd‹‹„tsl“““lddlekƒ||‹‹‹{ttuztƒ||uztƒ„„llktt{|‚z{{ƒ”“›ƒ„„…‹’{{t‹„‹mtt|„…œ§²”››œ§²Œ”•lks|„…œ§²™š¤··Äª³·…„’{{ƒŒ”•…‹’{{ƒ{{ƒ‰Š¡tts“Œ”{{ƒŠ~‹…‹’¦§¨Œ”•··Ä‹‹„\[[”“›tllf]cekd|„…››”|„…™š¤‹…’ƒ}Šu{{tt{{u{{{ƒtts{u{lritts“Œ”tt{mtt{{ƒmtt‹‹„™š¤lekrfk“““u{{\[[ƒƒ|ŒŒšztl‹’Šdc\lldkd\ƒƒ|lldu{{‹‹„d\\ƒ||“Œ”ult{{ƒŒ”•tllF=CŠ}ƒ‹…’’…‹‘}zŠ~‹ƒ}ƒ{tt‹‹‹‘Œ…ƒƒ|Šƒ}œ››„Š„{{ƒllk|‚zŒ‹“uzt{u{‹„‹œ¤¦‹‹„|„……‹‹‹„‹mtt…‹‹|„…”“›”››ƒ}Šllk{{ƒŒ‹“œ¤¦”››™š¤…‹’…‹‹ƒƒ|”››’ŒŒ“““rg]VTLFD;[TTUTSekdlddztlllkllkdc\[[TUMRztlUTS””‹:97:97sreb[UlddSKJsreD;9lddSKJldd{||lld‹‹„srezllf]cŒ”•sle‚utƒ‚uultlld{tt‹„„””‹ƒ||]bZlriƒ||tsl|„…Œ”•’ŒŒ‚ut‹’Š[[T[[T[[Ttsltsl™š¤Œ”•‹’Šœ››{{tlddƒ}ƒttsttsŠ~‹uzt|„…‹‹„MSS\[[[TT‹„‹]bZ[TTi\Vƒƒ|{u{{{tƒ„„ƒ||{ttsrej]\leklddcbV‹’Šrg]{{t{tttllƒ„„tyg‚|uttslldƒ„„mttdc\UTS‹‹‹›¢›²²¬‘Œ…£œ¥œ¤¦‹„‹‹’Š‹’Š””‹“““f]c‚ut|‚zƒ„„{tt‚|u„„Š“““{||{||ddcƒ„„ultedk{{ƒ|‚zlksŒŒš‹‹‹œ››|„…}‡’œ¤¦|„…™š¤|„…|„…Œ”•…„’œ§²^fs…„’·¶Ñ…‹’Œ‹“œ§²”“›„Š„ƒ„„{{ƒ{{ƒŒ”•”››{{ƒŒ”•›¢›™š¤£››¨©´ƒƒ|ultŠ}ƒ“Œ”™š¤tsllks…‹’”š”‹’ŠŒŒš„„Šu{{mttmttlksŒ”•Œ‹“ddc{||ƒ}ƒmttlks…‹’™š¤Œ”•‹‹‹lrimttŠ}|lritsl‹‹„lriƒƒ|‹„‹”“›Œ”•{{t›”›“““ƒ„„ƒ„„sre¦§¨{{tred„Š„lld]bZ\[bUMR{{ƒ{{ƒred‚v{“Œ”™š¤Šƒ}{u{‘Œ…ƒ||‹„‹uzt‹‹‹™š¤tsl|„…]bZŒ‹“ƒ||…‹‹tll¨©´‹’Š™š¤tt{‹’Šmtt‚v{uztƒ„„ƒ}ƒ›¢›lksƒ„„mttuztekd…‹‹llk‹‹„tlltzlek][[Tlldsletts„Š„‚v{ƒƒ|ddcekdtslztlultdc\,55ƒ||FD;74,{{tlrif]c{zmlriFD;\[[VTL{||‹„‹|‚zsle|‚zttsjV[tslrg]tslslej]\sleƒ||lekllk{{ttzl“““llddc\|„…{||“““ek]”››b[U{ttlri‰ƒvlri\[[¦§¨Œ”•ekd…‹‹uzt‚|u‹‹„tt{{{ƒƒ„„lri|„…kd\UTS\UZdc\[TTlldbVU{{t\[[„„ŠlldVZTultyle‹„„ƒ}ƒ„„ŠcbVkk]lri{zm‹„„zll[TTsreztlf]c]bZ|„…UTSlri„Š„]bZ‹„„‹‹„ztl{||«²«“Œ”““““““‹’Štslƒ||‹‹„d\\‹‹‹{ttmtt{u{””‹’…‹tt{‹‹‹œ››‹„‹ƒ}Š]cdtts{{ƒlksƒ||ƒ}ƒ{tt™š¤‰Š¡…‹‹Œ”•}‡’|„…}‡’Œ—£{{ƒ|„…Œ”•}‡’¨©´™š¤Œ—£›²‹‹‹‹„‹ƒ}Š…‹š­À¶œ¤¦™š¤Œ‹“™š¤µ¶·{{ƒ›”›|‚zŒŒš“Œ”ult”š”mtttts“““uzt„Š„}‡’edk|‚zmttUTS\[b]bZŒ”•dc\tsl{{ƒnv‚]cdŒ—£“““…‹’‹„„d\\\[[|‚z“““‹‹„„„Š{u{tllj]\”“›|„…£››ldddc\|„…mtt|‚zƒ}ƒ‚v{£œ¥lks™š¤Š}ƒ‚v‚{{ƒ‚wltt{‹‹‹yl„“Œ”‚v{ŠŠ}‚utŠƒ}ƒ„„œ¤¦‹’Š„Š„™š¤Œ”•™š¤””‹llktll…„’ulttt{‹‹„…‹’“~ˆtzlŠƒ}™š¤„Š„|„…ƒ}Šnv‚œ§²„Š„“Œ”ddcmttlksd\\lrilddd\\ekd{tt{{t‹„„ddc{||Š}ƒ{tttzltts{zmj]\\UZUTSUTS””‹JHF74,lridkVSKJVTLJHFbVZVTLbVUtllŒ‹“u{{d\\srelksztlƒ„„kk]tslztlddclri{ttƒ||””‹‹‹‹”š”Œ‹“ztlfkk{||tzlƒ}ƒ]bZmtt{u{llk|‚z‹’ŠFD;MSSlriœ››lri]bZ{{ƒtll‹„‹”››lkslddllkƒ„„ddctll\[bultuzt\[bƒ}ƒtslŠƒ}‹’Šlks]bZ„„ŠUMRƒ„„ƒ||ƒ„„b[Uƒ„„ult£››rg]LKR{ttkk]UTSlddVTL[TTUMR‹„‹lriœ››œ››ƒ‚u{u{”“›lld‹„‹Œ”•„Š„‹’Š‘Œ…{||{tt‹„„ª³·š””™š¤ƒƒ|‘Œ…‹„„kd\tzl…‹‹ƒ„„…„’\[bek]tt{“Œ”Œ‹“{{ƒu{{™š¤|„…ŒŒšmttŒ—£…‹’¬¶Ã™š¤Œ—£Œ—£Œ”•…‹‹™š¤ƒ}ŠŒ—£”“›ª³·”››ƒ}ƒ™š¤™š¤™š¤Œ‹“Œ‹“ª³·“Œ”“Œ”{{ƒ|‚z£œ¥‹…’ulttt{tt{Œ”•ƒ„„‹„„UTSultlksu{{}‡’|„…lksekd]bZ]bZtslƒ}ƒ””‹|„…mk…Œ”•”“›”“›\[b\[[kk]|‚zultztl‘…„tlllri|‚zddcultttsek]]cdMRK‹‹‹ƒ}ŠUMR‚v{œ¤¦Œ”•‹‹‹Š~‹{{ƒ‹„‹ult””‹£²‚v{llk‹„„£œ¥š””œ››„„Š¦§¨‹‹‹¦§¨Œ”•Œ”•Œ”•|‚zmttmttf]c|„…ek]\[bultllktts£œ¥‹‹‹|„…{{ƒ…‹‹}‡’ƒ„„Œ”•{{ƒlksVZTJHF{ttultUTSu{{tlllld{{tedkŒ‹“ƒ||sletsl{||kk]SKJSKJaWM|„…š””ekd*)(kd\kk]bVUVTL:97D;9\UZbVU‹„„llk]bZtsl„Š}f]ckd\mttcbV‹„‹ldd\[[‹’Šztlztllldmtt’ŒŒŒ”•‹‹„cbVƒƒ|dc\„„Šb[Ulld‹‹„‹„„|„…]bZ]cdekdJHFu{{MRKVZ[llkkd\edk{||{{ƒŒ”•|„…„Š„lddldd{{ƒlks|‚zllk‘Œ…tslztl‚utUMRjcVƒ„„j]\lddbVZ{|||‚z‹‹„‹‹‹››”‚|uf]crfkrg]\[[ldddc\{||mtt”“›|‚z{{t‹„„[TT\[[\[btslttsƒƒ|ƒ||{||”š”lekƒƒ|‹„„™š¤red¦§¨‹„„lld£››mttu{{uzt{u{{{ƒlkstslƒ}Š{{ƒ”››u{{{{ƒfkkmttu{{|„…mttmtt}‡’†~‘œ§²Œ—£›²{||“Œ”†~‘†~‘‹’Š”››µ¶·{u{|„…nv‚{u{|„…“““{|||„…¨©´š””u{{²¬µ£œ¥›”›|„…Œ”•ttsult{u{mtt}|’mttfkkŒ”•|„…mtt|‚z|„…Œ”•“““ult”››œ¤¦mtt…‹‹„„ŠŒŒšleklldllk{||VTLŠƒ}UTS[TTlldVTL{||‚utJHFtllJHFtslkd\¦§¨lks¦§¨›¢›tslƒ‚uƒ}ŠJHFleksleŒ”•™š¤ƒ}ŠŒŒš“Œ”’…‹‹„‹‘Œ…“““”š”‹„‹Œ”•¨©´ttsuztŒ”•lri\[blksu{{tsl\[bƒ}ƒf]cƒ||Š~‹tt{{||˜Ž£|„…”“›tts{tt{||mtt|„…uztlldf]clri‹’Šlld{{tztl]cd\[[redVTL[[T|‚zrg]FD;[[Tdc\SKJ””‹:97*)(UTSVTLaWMVTLSKJJHFf]ckk]‹„‹‹„‹llkSKJlrikd\zllrfkd\\lrilriVTLƒ}Šyle‚|ubVUmtt{zmŒ”•{{tkd\tts{{t{ttƒƒ||‚zƒ||ldd‹’Š‹‹‹„Š„lrilksekdmtttzlultƒ||{{ƒlri‹„‹mtt›”›…‹’ƒ„„‹‹‹ƒ}ƒtt{|‚z„Š„redrg]››”lrifkk{{t„„Šlddsle‚|utsllriŒ”•Š}|ƒ„„Š}|D;9ƒ||…‹‹lldulttt{[[TŒ‹“lddttslrid\\b[UJHFd\\lldtt{ƒ„„“““ƒ„„ƒ„„”››{tt”“›uztkd\{{ƒf]ctsl”“›{{t{u{{ttult{{ƒmttƒ||{{ƒtt{]bZ]cd{{ƒmttmttŒ”•mtt{{ƒnv‚…‹’…„’œ§²™š¤™š¤™š¤mtt{{ƒŒ—£|„…”››¨©´lksƒ„„{{ƒ”“›“Œ”¨©´„„Š”“›œ¤¦ƒ}ƒlrif]c‹„‹{u{[TT¨©´edklekuzt…‹‹lks]bZlrimttmttmtt~’“‹’ŠŒ”•Œ‹“u{{„„Šmtt„„ŠŒŒš{{ƒ{u{„„Šƒƒ||‚z‹’Štllkk]lddb[Uƒ||”š”{{tultlekdc\MRKllkrfkf]c’ŒŒ‹’Š“““‹‹‹œ››’ŒŒf]cUMRtll{{ƒ”“›™š¤¦§¨„Š„ƒ||‹„„Œ”•‹„„‹‹„‘…„¨©´”“›ultuztŒ”•ƒ||””‹ƒ}ƒmtt‹’ŠlksVTL\[[u{{tslultttsult{{ƒ{{ƒedkƒ}ƒmttVZ[„„Štts‹‹‹™š¤{{ƒuzt\[[tlltsl\[btts[TTztlVZTkd\VTLb[UyleUTS[TTµ¶·JHF>ECSKJVTLJHF74,[TTrfkŠƒ}b[Uƒ}ƒf]cllklld{||UMR\[[VZTi\V]bZlriekdVTL””‹|‚ztll|‚z‹’Šfkk‹‹„tzl‹‹„‹’Š¦§¨””‹fkk[[Trg]ekd{{ƒ™š¤tll…‹’‹’Š¦§¨ƒ„„ƒ||{u{g\rUTSedkkd\u{{Œ”•Œ”•‹‹„mttŒ‹“‹’ŠmttSKJult|‚z{u{£››ddcd\\{u{lddsleldd|‚z]cdred|„…cbVd\\f]c”“›Œ”•š””„Š„|‚zmttd\\\[[ƒ„„‚utttsu{{uztuzt“Œ”‹‹„‹’Š¦§¨”š”Œ”•””‹Œ‹“ƒ„„Œ‹“ttsult|‚z{{t„„Šƒ||ƒƒ|lriƒ}ƒmtt|‚z“Œ”lkskd\{{ƒ‹„‹¨©´Œ”•Œ—£¬¶Ã…‹’|„…{{ƒœ§²Œ—£lks…„’„Š„™š¤¦§¨Œ”•|„…™š¤”“›ƒ}Š‹…’{{ƒœ§²™š¤”“›‹’Š{{ƒuztš””“““™š¤”“›£››tsl|„…Œ‹“llktt{„„Š|‚z[[Tmttu{{|„…Œ—£|„…Œ”•|„…‹‹„”“›…‹’Œ”•u{{lek|„…lkslrimttu{{lld‹„‹|‚z¨©´„Š}lrib[Uekdr]g\[[VTLf]cŠƒ}{||f]cmttult“““ƒƒ|{u{f]c™š¤Œ‹“ƒ||tyg{tt’…‹„Š}”š”lekrfk“Œ”’ŒŒœ››¦§¨{ttƒ}ƒ„„Š|‚zŒ”•„Š„¨©´“““|‚z„Š„”››{||llkllk{u{”“›tts{{ƒ{{ƒlksŒ”•ttstllŒ”•}‡’uzt{{ƒ’ŒŒ…‹‹\[[d\\ek]d\\edkllklddtsllri[[TVTLb[Uultlddu{{¦§¨UMR*)(aWMVTLd\\VTL[[TD;9[TTb[U{u{]bZ{{tttsztlSKJlld’ŒŒƒ||tsltsluztddc‚|u{zm‹‹‹ekdkd\ddc‹‹„\[[lldtts‹„„tygŒ”•b[UŠŠ}sle\[[|‚z”“›™š¤…‹‹¸Á¹lri››”Œ‹“|„…uzt]cdlri{{ƒ|‚z]bZf]c{{ƒlrimttŒ‹“b[Ud\\\[[ƒ||lldlld{{ƒlldtslsleekd|‚zldddc\tslj]\VTL‚v{u{{ƒ„„‘Œ……‹‹MRKVZTƒƒ|uztsreŠƒ}ƒ„„|‚z¦§¨‹’ŠŒ‹“‹„„¦§¨Œ”•ƒ„„|‚z””‹£œ¥{||ƒ||{{t‹„„tslƒƒ|œ››{{ƒ››”‹…’ultmttVZTtt{{{ƒ|„…™š¤ƒ}Š…‹‹}‡’™š¤Œ”•}‡’œ¤¦Œ—£‹…š}‡’†~‘|„…lri‹‹‹Œ—£¨©´‹‹‹œ§²|‚z“Œ”Œ”•ŒŒšƒ}Šƒ„„Œ‹“¤¤‹‹‹ª³·™š¤ultult|„…‹…’{{ƒ‹…’…‹‹‹„‹Œ”•lldu{{uzttsl}‡’|„…œ››™š¤œ¤¦nv‚Œ”•‹‹‹œ¤¦œ¤¦{{ƒ„„Šmtt{u{„Š„ttsekdƒ„„Šƒ}ldd„„Š“““””‹‹‹„ddckd\Œ”•uzt{{ƒSKJttsUMRdc\D;9{ttMRKsle{{ƒƒ}Š{{ƒtll{{tƒ}ƒ™š¤”š”lrid\\kd\ƒ„„{ttƒƒ|œ››…‹‹ƒ}Šƒ}ƒ‹„‹{{t“““¨©´™š¤{u{ª³·ƒ}Šƒƒ|u{{mttu{{tll…‹‹lks|„…ŒŒš{{ƒf]c{||{tt{{ƒ{{ƒlrilksƒ„„tsl{ttlld{{tmttultkd\rfk{{ƒ]bZkk]tllVTLUTS]bZ²²¬]bZ:97Šƒ}VTLtzli\VJHFi\VUMRVTL‹…’\[[\[[mttnƒ‰v|uzttll“Œ”Š}|bVU„Š„‹‹„¤¤ultlld]bZedk|„…sre{ttkd\bVUf]cŠƒ}œ¤¦”š”|‚z[TTtll‹„„œ¤¦‹’Š[[Tllkd\\ƒ||ƒ}ƒœ¤¦”š”u{{edk„Š„‹’ŠVTL\[b\[bVTLdc\{||ƒ||ztlttsred]bZek]cbV…‹’››”’ŒŒllk]cdedkd\\lld]bZkk]tslUTS[[Tedk{||lriddcu{{mttsrei\Vƒ„„„„ŠŒ‹“Œ‹“”››²²¬¦§¨{||uzt„„Š{||{{ƒ{{ƒ‹‹„‹’ŠŒ‹“UTSƒ||‹‹‹|„…|„…ttstt{tt{œ››…‹’ƒ}ƒtllŒ—£|„…u{{}‡’{{ƒ™š¤œ§²Œ—£Œ—£¨©´¬¶Ãœ§²…‹š‹„„mtt“Œ”Œ”•‹‹‹œ§²]cdœ¤¦‹…’|„…Š~‹‹‹‹{||™š¤„Š„™š¤µ¶·™š¤™š¤™š¤„„Šœ¤¦™š¤…‹š‹…’‹’Š”“›ŒŒšlriª³·]cdu{{]cd…‹š~’“|„…‹‹„„Š„u{{mttƒ}ƒ…„’mtt{u{“““cbV]cdf]cSKJtts‹’Š‹’Štllztlddcƒ„„ttsekdlrilksSKJ]cd|„…[TTlriddc[[T{u{lksyl„‹‹‹Œ”•Œ”•tts“““ƒ„„‹„„zll‹„‹“Œ”›¢›{||””‹|‚z™š¤¦§¨„Š„tslœ¤¦›¢›{{ƒ‹‹‹{{ƒ„Š„|„…‹„„ŒŒš{tt…‹‹}‡’“Œ”tt{ŒŒš‹‹‹›”›lri|„…]bZmtttt{tllƒ„„ddcuztbVU\[[…‹‹tsl|‚z‹‹‹srecbVyfdlddred[[T¦§¨JHF*)(kd\VTLek]VTLMRKD;9{{t[TTlddJHFVTL\[[tt{{u{{||zll‹‹„Šƒ}›”›”››ekd‹’Šƒƒ|“““””‹ttsƒ}ƒtsllekkd\VZT\[[{ttSKJ{{tzll’ŒŒ‚|u|‚ztsltlluzt{tt„Š}ƒ‚uƒ||Œ”•””‹Œ”•\[bcbVn…fkkbVZSKJz‚l„„Šttstllkd\Š}ƒVTL|‚zƒ„„lek[TTtsld\\]bZ‹’Š¨©´ult¤¤”“›[TT„„ŠUMRultrfklri]bZUMR|„…lriVZT{tt‹‹‹‹‹‹{{ƒ|‚z™š¤›¢›‘Œ…Œ‹“|‚ztsl’ŒŒult…‹‹ƒ||[[Tfkkuztƒ}Štts„Š„‹„„ƒ„„{||Œ‹“”š”Œ‹“’ŒŒ‹‹‹…‹’{{ƒmtt{{ƒŒ‹“nv‚Œ”•…‹’…‹šœ§²|„…›²{{ƒ“““™š¤¦§¨u{{f]cŒ—£‹‹‹{u{”“›…‹‹£œ¥‹„„ƒ}Š‹„‹™š¤uzt™š¤edkŒ”•™š¤œ¤¦¦§¨…„’œ¤¦µ¶·Œ”•’ŒŒ…‹‹]cd|‚zVZ[mtt]cdœ§²‹’ŠŒ”•ddcuztŒ”•fkklksŒ”•Œ”•lksUTSSKJtsl‹’Š{{t]cd{{tuztŒ‹“’…‹|‚z’ŒŒŒ‹“Œ”•ttsƒ||fkktt{lrif]cttsƒ„„[TT[[TVTL{u{ttsmttœ¤¦Œ”•”š”tzl{ttƒ||‹„„Šƒ}”››„Š„‹‹‹Œ”•‹‹‹¦§¨“““‹’Š™š¤„Š„‹‹‹‹„‹‹„„™š¤Œ”•‹„‹{u{{u{{||u{{{{ƒlkslksttsf]c]cdlks|„…\[b|„…ttstsl{ttƒƒ|tll{||uztlld|‚z[[TVTLJHFlld[[T]bZult²²¬UTS*)(dc\[[TJHFaWMD;9D;9jV[FD;JHF\[[b[Uf]cult‹‹„d\\lekƒ}ƒtt{ultiq][[TŠŠ}z‚lŒ”•ƒƒ|ek]‹‹„u{{ƒ}ƒ‚uttzlƒƒ|Šƒ}rg]j]\Š}ƒ‘…„zlllddek]mtt{{t‹‹„ttslri{u{œ¤¦ƒƒ|tll{{ƒƒ||lldMRKSKJF=C„Š„{{trfk””‹r]Z’ŒŒtllbVU]bZekdsle{tttllƒ‚uekdtlltll››”…‹‹‚v{ult{u{\[[ultfkk>B9tll|„…‹’ŠcbVekd””‹u{{‹„„ƒ||{{ƒœ››ƒƒ|„Š„™š¤ttszlllddmtttslttstt{ƒ„„œ››››”{{t…‹‹tts|„…{tt™š¤mttlriuzt|„…\[b}‡’…‹’…„’…„’Œ”•Œ”•}‡’Œ—£…‹šœ¤¦™š¤{{ƒ¦§¨Œ—£…‹‹ƒ„„Œ”•ª³·‹‹‹™š¤Œ”•Œ‹““Œ”™š¤™š¤”››”››“Œ”™š¤›”›™š¤†~‘™š¤u{{lks“Œ”…‹‹‹’Škd\f]c|‚z|„…mttVZTnv‚|„……‹’llkƒ„„u{{…‹‹Œ”•ult…‹šƒ}ƒf]c¤¤{|||‚zllk|‚z{{t]bZsleƒ||ƒ„„””‹”“›dc\ƒ||\[[{tt\[b[TTŠ}ƒtzl|„…VTLek]JHF{u{”››Œ”•Œ”•¨©´{{ƒ¦§¨ƒ„„š””{ttœ››‹’Šuzt‹‹‹tslŠ}ƒŠ~‹tll|„…ztl|„…]bZ{||„„Š|„…‹’ŠŒ”•u{{‹„‹{{ƒŒ”•…‹’ŒŒš…„’“““{ttu{{mtt]cd…‹‹{{ƒƒ||‹’Šb[Uekd{ttfkkZbN|‚z\UZekdSKJVTLldd[[Tdc\VTL¦§¨:97*)(slejcVD;93+*JHF74,JHF[TTultƒ}ƒ‚|ulldttsŒ”•ult“Œ”ƒ||ult[[TttsUTS[[Tek]””‹„Š„„Š„Œ‹“„„Š“““š””ddc{{ƒ…‹‹|‚z‚|uult‹„‹‹„‹ultƒ„„”››ultlks“Œ”uzt\UZlritslek]{u{tsllri]cd?;C{tt[[T‹’Šsle{tt‚|ulriJHFddcdc\ddcd\\tllƒ‚uVTL[TTttsd\\ultttsb[Uult[TTUMR[TT‹’Šlri{||ttsekdfkk›¢›Š}|ƒ}ƒ““““““ƒ}ƒtll›¢›llk··Ä“““„„Š“Œ”mtt”š”uzt¦§¨‹‹‹ztl{|||‚zƒ‚uŒ”•{{ƒ‹„„…‹‹tslœ››™š¤mtt{{ƒ|„……‹’Œ—£™š¤ª³·Œ”•}‡’|„…œ§²ª³·¡¡ƒ}ƒƒ}ƒ‹…’™š¤„„Š¬¶Ã£œ¥¦§¨ª³·œ¤¦œ§²›¢›™š¤Œ‹“œ§²|„…£œ¥‚v‚¦§¨™š¤™š¤lks…„’œ¤¦]cduztmttu{{{{ƒtts|„…Œ”•fkkmtt|„…Œ”•{{ƒ‹‹‹edk]bZlks}|’‹‹„ƒ}Šrfk{{t…‹’’ˆtsl‹’Š]bZ[[TUTSŠ~‹u{{‚|u„„Šekd[[Tdc\u{{VZ[lrilekuztuzttsllrilriultd\\|„…‹’Štt{”“›”››¦§¨Œ”•¦§¨mw””‹‹‹„tslVTL{{ƒ™š¤{||”››‹‹‹ƒ„„”“›ƒ}ƒtslllk„Š„“““”“›ƒ„„lriult™š¤{{ƒ‹„‹ƒ}ƒtt{ƒ„„lks]bZ{{ƒ{u{{||‹‹„f]cdc\SKJ„„Štslƒƒ|llk[TT[[TztlVTLsrett{d\\¤¤JHF*)(j]\cbVJHFSKJF=CF=C[[T[[TbVUƒ}ƒ{{tƒ||²««’ŒŒ{u{tlllekllktll{zmdc\kd\{{t{{tlri]bZ”“›‹‹‹™š¤ƒ„„“““‚wl””‹…‹’ƒ}ƒƒ||red|„…ƒ}Šsle‹’Š„„Š£œ¥…„’Œ”•œ¤¦”››SKJlektllŠ~‹‹’ŠŠƒ}\[bultleklritsld\\’ŒŒ{ttddc‚v{mttƒ„„“““tllb[U“Œ”d\\‹‹‹kd\b[UbVZdc\lddF=Cf]clekŒ”•mttf]cmttttsu{{…‹‹lri“Œ”Šƒ}ƒƒ|ƒ„„lldtsl…‹‹“Œ”„Š„Œ”•‹…š{u{²²¬fkkŒ‹“uzt››”ƒ„„‹’Š”š””š”f]cƒƒ|{ttlld”››„Š„…‹’{{ƒ|„…{{ƒ…‹šœ¤¦œ§²œ§²}‡’}‡’|„…Œ—£œ§²tt{™š¤{{t“““„Š„…‹‹¬¶Ãœ››‹‹„…„’£œ¥¨©´“Œ”lks„„Š…‹’lek£››™š¤Œ‹“Š~‹„„Šmttœ§²Œ”•“Œ”lddmttUTS”š”|„…mtt”“›|‚zœ¤¦Œ—£tt{{||…‹‹…‹‹{{ƒlks{{t‹…’tll‹‹‹“““¤¤kk]uztVZTddclekbVZtslkd\lksŒ”•VTL]bZtlluzt[TTtll‹’Š]bZekdu{{{{ƒ{{ƒ“““|‚zlri{{ƒ{u{lld››”{u{‚v{’ŒŒekd{{tzll„Š„ƒ||Š}|{{ƒœ››„Š„ttsŒ‹“}‡’f]cmttŒ”•f]clri{{ƒmtt]bZedk„†™ŒŒš‹…’mtt‹‹„tt{dc\]cdu{{tts‹’Š‹’Šllk{tt|‚zztl]cdlek[[T{{trg]VTL[[TSKJldd¦§¨\[[*)(sleJHFbVZJHFJHFVTLVTLkd\[TT’ŒŒ{{t„Š„ƒ||ttsrfk{{ƒ’…‹{{ttslllklri“““””‹llkttsu{{f]cŠŠ}ƒ}ƒ{{t””‹ek]lksfkkŠ}ƒƒ„„ttstzlƒ„„d\\uzt”“›]cdultttsœ››Œ”•d\\…‹‹UUYƒ|||‚zddcdc\UMRdc\mtt‹‹‹rg]lek““““Œ”lddlri{ttjcV¦§¨‹‹„[TTj]\ek][TT{ttƒ}Š|„…llk{tt‚v{ƒ}Š|‚ztt{\[[]cd\[[…‹’™š¤„„Šƒ||”“›{||Œ‹“{||tsl|‚ztt{{||ekd“Œ”ƒ}ƒœ››|‚z”››sle”“›“““ƒ„„„Š„›¢›|„…ekd]bZ|‚zƒ„„dc\…‹‹…‹š…‹’„†™™š¤œ¤¦™š¤Œ—£…‹šŒ—£Œ—£}|’|„…Œ”•{{ƒœ››{{ƒ{||‹‹‹{{ƒƒ„„œ››Œ”•Œ”•Œ”•™š¤œ§²œ¤¦|„…™š¤‹…š‹„„ultŒŒš··ÄŒ—£™š¤œ¤¦œ¤¦lks]cdlksmttlri\[b…‹šmttŒ”•mttƒ„„ult…‹‹œ§²{{t{{ƒ{{tƒ}ƒ‹„‹“Œ”tts{{t]bZ[[T|‚zuzt“Œ”“Œ”llk””‹f]c{{ƒ]bZek]tsl\[[JHFmttmtt”››|„…{||ddcztl[[T\[[’ŒŒ™š¤”“›Œ‹“¦§¨ƒ}ƒlld’ŒŒ„Š„¦§¨{{tlld‘…„›”›”››uztŠŠ}lkslld\[[tsl}‡’uzt|„…{{ƒlks{||VZ[{{ƒƒ||lekŒ‹“lddlri{{ƒ[[T{{ƒƒ„„tsl…‹‹{{t]bZƒƒ|{u{‹‹‹{zmedkddc[[Tdc\VTLztl\UZldd¦§¨LKR*)(ztf{{t{ttUMRVTLj]\|‚zrg]‚v{f]ckd\tts{u{fkk‚v{„„Štt{slekd\dc\ttsuzt””‹lks”š”{u{tt{’…‹‹‹‹‹„‹{||’ŒŒ”š”Œ”•{ttƒ„„\UZ‚|uf]ckk]{{t””‹{{ƒ\[buztœ¤¦”š”tslmttlkstsl‹’Š{||SKJ\[[[TT|„…[[Tdc\’ŒŒtllkd\lkskd\‚uttzl‚|u{zm¦§¨tsld\\š””kk]lld{{ƒultf]cƒ||ult]cdlkslks{||lek›¢›‘Œ……‹’ƒ}Šœ¤¦ƒ‚u··Ä‹‹‹¦§¨ekd‘…„{||ult£œ¥’ŒŒ””‹Œ”•‹‹‹””‹{{ƒƒ„„”››„„Š“Œ”|‚ztts‹‹‹™š¤{||{||Œ”•{tt„„Šlksœ¤¦}|’„„Š…‹’|„…Œ”•}|’…‹šŒ—£{{ƒ‹’ŠŒ”•™š¤ŒŒš|„…£œ¥{u{\[b“““·¶Ñ£œ¥¨©´Œ”•¦§¨ªÁÅ™š¤¨©´{||‹…’¨©´œ¤¦œ§²Œ—£œ¤¦Œ”•u{{|„…mtt\[[tts}‡’|„…mtt]cdfkkddcŒ”•ƒ„„|„…‹‹„ultlri‚v‚{||d\\[TT”š”kd\kd\fkksre\UZJHFmtttts{{ƒ„„ŠVTLb[U‚utmtt\[b\[b|„…{||u{{ƒƒ|[[Tlldƒ}ƒ}‡’{{ƒŒ‹“”“›‹„‹‚|u{ttœ››{u{|„…‹‹„{tt’ŒŒœ››{ttmtt“Œ”ƒ‚u”š”ŒŒšnv‚mttmtttsl‚v‚Œ”•ultmtttt{…‹‹”“›‹„‹ƒ||uztu{{ultmttUUYult{{t{||œ››]bZsle\[[UTS[[Tllkdc\VTLVTLVTLd\\jV[SKJ¦§¨\[b74,red]bZlddekd[TTSKJ]bZSKJf]cb[Utslddcztl{{ƒrfk‚v‚ult‹’Šdc\kk]{{tkk]dc\ult„Š„{{t‚|ud\\ƒ}Š[TTtzllri[[Tekdtsl¦§¨tll„„Štts|‚z|‚zŒ”•fkkƒ}ƒu{{{||uzt]cdJHFlksdc\[[TtllSKJ“Œ”tsl|‚zmtt‘Œ…tll‹„‹VTLsretllƒƒ|{zmf]cllk{{t{ttUTS‹„„ztl{ttllkf]ctllf]cSKJJHFult„„Šu{{JHFtt{„Š}”››Œ‹“œ¤¦{tt{u{’…‹›”›mtt‚v‚ª³·dc\lek„Š„””‹lldkk]{||edk{{t|„…„Š„™š¤|„…ª³·ult{{ƒmtttts|‚ztt{uzt{{ƒª³·™š¤Œ”•mk…{{ƒ{{ƒ™š¤™š¤ƒ}Šœ¤¦lekƒ„„d\\‹’Š|„…ƒ}ƒ‹„„f]clksª³·‹…’‹„‹|‚zŒ”•”“›»ÂÇ|‚z{{t“Œ”„„Šœ››Œ”•¨©´ª³·œ¤¦Œ”•fkkVZ[„„Š|„…{{ƒ^fs]cdmtt\[b”“›Œ”•”š”ultœ¤¦{{ƒ™š¤f]cƒ||tsl‹’Šddc’…‹JHF|„…ƒ‚u‚utf]cult\[[lkstt{{ttult‹‹‹™š¤Œ—£nv‚\[[]bZekd]bZJHFddcult‹„‹™š¤…‹’…‹‹¨©´„Š„“Œ”‹„‹kk]|„…{||tllƒ||tslult\[[Œ‹“ƒƒ|SKJf]cŒ—£|„…Œ”•{||tslŒ”•”š”…‹‹mttlks{{ƒ“Œ”“““mtttslult”š”yl„\UZtsluztultuztƒ||ddcd\\kd\UTStslVTL[TTlld]bZrg]d\\œ¤¦LKR*)(bVUVTL74,JHFJHFf]clldUMR{tt|‚zƒƒ|uztb[Uƒ}Š“Œ”‹„‹{u{ztl{{tkk]b[U„Š„[[T{{tdc\‚v{Œ”•‚ut{{ƒ{tt{{tlricbV|‚zlekƒ||tts{tttslultƒ„„…‹‹{u{{u{tts|‚zmttUTS\[bUMRd\\ekdVTL[[TbVZult‹‹„{{ƒsrered[TTbVUf]cSKJ‘Œ…””‹sletsl{zm¦§¨u{{ƒ}ƒ[TTSKJƒ||bVZlddllk{u{SKJf]clkstt{MSS“““‹‹‹‹‹‹{u{„„Šƒƒ|”“›™š¤‚|u‹’Šddc”››lksƒ„„‹…’¦§¨tslult{{t£œ¥‹’Š“““…‹‹›¢›Œ‹“{||{{ƒ{{ƒ\[btt{Œ”•{{ƒ‹„‹™š¤™š¤™š¤Œ‹“mtt}‡’}‡’lksmk…†~‘tts„„Š{{tƒ}ƒttsu{{“Œ”‹…’™š¤œ¤¦|„…tsl‹„„]cdu{{œ¤¦…‹’{tt‹‹‹lks‹„‹™š¤…‹‹œ§²Œ”•‹…šœ¤¦]cdUTSƒ}Šnv‚mttVZ[\[b\[b|„…ƒ}ƒ\[[|„…ƒ}ŠŒ”•|„…‹…’{{ƒ{u{””‹MRK{{ƒ™š¤f]cllkkd\{{ƒlksŒ‹“ƒ„„lksmtt|‚z…‹’‹…’^fs\[[mttu{{{{t|‚zVTLtsltslVTLfkk…‹‹{{ƒœ››‹…’›”›ult‹‹„ƒ‚u¤¤‹’Š“Œ”„„Š‹„„j]\…‹‹u{{ƒƒ|Œ”•f]cultLKRƒ„„…‹‹ƒ}ƒlddttsŒ”•ƒ}ŠŒ‹“…‹’™š¤…‹‹lekuzt{u{|„…lksmttlri|„…lriuztlekultd\\dc\UMRek]sle[TT]bZSKJ\[b[TT¦§¨MSS-1+VTL[TTPF=UTSddc\[[lld‚utred|‚z|‚zƒ„„ƒ||u{{{ttbVZlek{zmj]\VTLmttdc\tzl|„…‹‹„{||lekƒ}ƒ‹…’{{t’ŒŒ{{t\[[Šƒ}UMRƒ}ƒtt{|‚z{{ƒfkkš””ƒ„„™š¤‹…’{{ƒ™š¤|‚z“““ŒŒš‚wlVTLtsl[TTlks„vŒSKJ|‚z„„Šddc{||ƒ}ƒlddj]\tts‰|vJHF[TT‹‹„‚|urfk{{tult’ŒŒsleƒ„„ttstll{tt…„’MSSf]cult„„Š\[bldd{ttŒ‹“ultf]clekœ¤¦Œ‹“‹’Š|‚z™š¤”››‹…’{||Œ‹“‹‹„„Š„ƒ||™š¤ƒ}ƒŒ”•…‹‹lld|„……„’uzt{||mttedk|‚zœ§²™š¤œ¤¦™š¤™š¤¦§¨¦§¨›²‰Š¡|„…‰Š¡{{ƒmttŒ”•‹„„uztŒ”•“““›”›œ››£œ¥Œ—£‹‹„llk‹‹„”š”ult|„…™š¤œ¤¦|‚zf]cf]c{{ƒ™š¤}‡’¨©´”››ŒŒšmtt]cd\[[ldd|„…Œ”•mtt{{ƒVZ[lks{{ƒlksmtt{{ƒlek\[blks{u{Œ‹“{ttSKJ{u{tll{u{VZ[‹‹„tt{llkddclddrfk|„…ƒ„„{{ƒtt{edk|„……‹šmtt‹‹‹]cd]cdlld{||{ttultŒ”•„„Š„Š„{{ƒ]cd{{t{tt¤¤ƒ„„‹‹„œ››u{{u{{‹„‹Œ‹“|‚z[TTtt{{{ƒ|„…u{{‹‹‹ekd{{t{||tllfkk{u{VZT|„…‹…š{||ddc|„…ult…‹‹ldd{tt|‚zekdddcUMRztlfkk‘Œ…‹„„SKJVTLdc\D;9JHFlldVTLldd¦§¨JHF,55sled\\:97JHFredbVUlri{u{tllUTSVTLlriultf]cult‹„‹ult‹‹„“Œ”]bZ{{ƒ„Š„tsl]bZ„Š„‚|uf]clekultdc\””‹llk…‹‹VTLVZTlek{{ƒ¦§¨›”›UTSd\\…‹‹{||tt{ƒ}Š™š¤”š”‹„„Œ”•ult‘Œ…‹‹„{{tJHFƒ„„f]c„Š„ult{tt›”›sleztl‹„„rfk£››redrr]slettsšŒ›¢›“Œ”™š¤{||‘Œ…{{ƒrfk{zm\UZJHFddc{{ƒ\UZLKRŠ}ƒƒ„„£œ¥‹„‹{u{ldd’…‹Œ”•‹’Š|‚zmtt‹‹‹ƒ||™š¤lks”››‹‹‹‚ut‚|u‹„„{||{ttŒ”•‹’ŠŒ”•“““[[Tmk…uzt“Œ”lks{{ƒ…‹šœ§²··ÄŒ—£¨©´™š¤™š¤™š¤}‡’†~‘mtt‹„‹{{t{{tŒ”•{{ƒ“““¨©´¨©´™š¤µ¶·ƒ}Šš””™š¤]cd{||Œ”•{{ƒ„„Šult{{ƒ‹…’Œ”•…‹‹{{ƒttstt{{||]cd…‹‹tts]cd|‚zŒ”•n…mttlkslks™š¤”››ŒŒšultu{{ƒ}ƒƒ}ŠŠ}ƒ‹‹„‹„‹uztg\rŒ”•Œ”•š””ƒ}ƒ”“›edkƒ||f]c|„…{{ƒ|„…lks\[blksŒ—£nv‚›¢›|‚z{{ƒ“Œ”‹„‹Š}|tll…‹’“Œ””“›”“›…„’tsl‘…„tslult…‹‹œ¤¦’ŒŒtt{ƒ}ŠŒ”•mtt„Š„…‹’“~ˆ™š¤mttfkk‹„‹ƒ}ƒ‹…’ttsfkkttsu{{{{ƒ{{ƒ\[[mttmttUMRllkƒ}ŠmttuztUTSfkkUTSSKJ|‚ztsl[TTSKJ[[Trg]aWMlrilddcbVult¦§¨LKR,55‚wl[TT\UZddcJHFtll[[Tultllk]bZtzl{ttult[TT”“›tsl„„Š‹’Šƒ||SKJmttŒ”•|‚zttsek]Œ”•lddœ››llkd\\{||d\\mttJHFVZTbVZlks’…‹mtt|„…„Š}Œ‹“„„Šƒ}Š{{ƒ‹’Šu{{lks™š¤{ttsle[[TUMR?;Cf]cSKJ„Š}lekttstt{„„Šf]cƒƒ|UMRkk]ztlŠ}|VTLuzt…„’”š”f]cƒ||VTL‹„„…‹‹lddldd[[Tekdd\\mttlks\[b{|||„…lksldd{{ƒ‹„‹ttsŠ}ƒ|‚zu{{{{ƒ‹’Š‹„‹ƒ||…‹‹››”|„…ƒƒ|ƒ}ƒtll‹‹„Šƒ}Œ”•‹’Šƒ||„Š„tll{{ƒ‹„‹”“›{{ƒœ¤¦…‹‹Œ‹“…„’œ§²¨©´Œ—£·¶Ñ™š¤…„’‰Š¡„†™u{{b[Ulld{{ƒƒ||£››£œ¥”››‹„‹¦§¨ultŠ~‹¦§¨|‚z|„…™š¤¦§¨œ¤¦ƒ„„¨©´£²mtt™š¤lks”“›lddŒ”•mttœ¤¦“““Œ—£|„…{{ƒnv‚œ¤¦]cd|„…\[b|‚zlek\UZlks‹„‹ŒŒšlek‹’Šƒ„„’‘~ƒ}ƒƒ„„…‹‹Š}ƒlks„„Š„„ŠŠ}ƒ…„’lks{||{{ƒLKR…‹š{{ƒ\[b~’“|„…Œ”•mtt„„Šd\\…‹‹£œ¥Œ”•”“›”š”‹…’Œ”•lriŠŠ}‹‹„”“›’ŒŒ¦§¨š””{{t‹…’|„…|„…lks{u{™š¤œ¤¦Œ—£|„…tllf]cfkk“Œ”lriu{{ultu{{{{ƒƒ|||„…mttlksŒ‹“lks…‹’ƒ„„…‹‹lks]cddc\\[[dc\[TTultddcsre{ttlrikd\ztlVTL¦§¨MSS:97tzlŠŠ}ultSKJVTLVZTVTL[TT[[Tf]c‚utllkŒ‹“dc\lekb[Uttsƒ}ƒtt{ƒ|||„…mtt|‚zuztlldƒƒ|f]clksult‹„„ultœ››œ¤¦|‚zddc“Œ”Œ”•{ttJHFtsl‚|u|„…u{{ƒ„„|„…ttstt{…‹’ƒ}ƒtlld\\iq]lriUMR|„…d\\llktlllri\UZ[TTsleŠƒ}\[[ultŠƒ}’ŒŒztl¦§¨‹„„”š”\[[ƒ||]cdJHF[TTVZTVTL\[[ekdSKJ^fsmttSKJdc\ldd„„Š“Œ”„„Š™š¤ult‹‹‹“Œ””š”ƒ}ƒƒƒ|ƒ}ƒ„„Šƒ„„{||’ŒŒ…‹‹uztllklldtll›¢›{||{{tzlltts\[bƒ}ƒult˜Ž£u{{Œ”•ulttt{™š¤„†™„„Š‹…š…‹’ŒŒš™š¤Œ—£“Œ”lek{u{›”›ƒ}ƒ“Œ”{u{µ¶·›¢›‹„„“Œ”™š¤¨©´ª³·œ§²›¢›|„…œ¤¦‚v{£œ¥ƒ}ƒŒ—£Œ”•…„’…‹‹”“›|„…œ¤¦lri¨©´{{ƒ|„…Œ—£œ¤¦}‡’mttlektt{‹’Š‚v‚”››ŒŒš„„Š„„Š[TT„Š„{{t‹‹‹{{t{{t„Š„ztl]bZ‹…’{{ƒƒ||ŒŒštts{||JHFVZ[lksn…MSSmttmtt{||fkk\[[™š¤œ¤¦Œ‹“‹‹‹›”›|„…“Œ”‹’Šlddƒ„„‹‹‹‹…’Œ”•””‹“““Š}|‹„‹nv‚ultdc\™š¤tt{edkUUY{||ƒ„„ŒŒš{{ƒmtt]cd\[b^fs‹’Š…„’mttmttmttf]cmtttsl„Š„ekduztUTSƒƒ|‚utleklrid\\f]ccbVlddSKJlldUMRr]ZVTLµ¶·OS`)+2‹’Šƒƒ|llkFD;[[TSKJFD;SKJVZTUMRJHFJHFtsllldredSKJ{||‹„‹UTS\[b¨©´ekd›¢›|‚z|„…tts{||ƒ„„mtt‹…’{||lri™š¤œ››]cd‚v‚uzt‹’Šztl[TTztltts™š¤\[btsl{{ƒ…‹‹{u{UTS‹‹„ƒ„„|„…]bZ{{ƒJHFddcultŠ}|\[[d\\srelri{ttŠ}|rfksrebVZdc\edksleddcu{{\[[ekdf]c\UZ|„…d\\|‚z[[T\[[\[b™š¤d\\{{td\\£œ¥‹„‹¨©´Œ”•¦§¨ƒ||lritts‹„‹…‹‹ƒ}ƒ‹‹‹ƒ„„{tt¦§¨œ¤¦ƒ||ƒƒ||„…””‹›¢›‹‹‹…‹’’ŒŒttsUUY{{ƒŒŒš™š¤œ¤¦Œ”•}‡’ŒŒš¬¶Ã†~‘„„ŠŒ—£œ››¨©´…„’Œ—£uzt¦§¨…‹’›”›tt{†~‘‹„‹{tt{||‹„‹™š¤™š¤{tt…‹‹}‡’Œ”•ƒ„„’ŒŒ“““‹…’™š¤˜Ž£Œ”•lksœ¤¦Œ”•…‹‹]cdlriddcult|„…uztŒ”•|„…¬¶ÃŒ‹“™š¤ƒ„„“““‹„‹ddcultult[TTtllekdiq]]bZ„Š„ekdkd\{{ƒ\[[ekdf]c™š¤ƒ„„{u{lksmtttt{|„…|„…n…Ž¡›ek]|„…„Š„lksuzt“Œ””››“Œ”mtt{{ƒlks{{ƒš””œ››†~‘‘Œ…“““‹‹„“““tllŒ”•„„Š’ŒŒƒ}Š|„…{{ƒlksŒ”•ddc{u{{{tult|„…mtt|„…{{ƒlksfkk\[b]cd\[b]cdfkkddcuzt]cdlri|‚z{||[TTb[Ukd\sleb[UyleyfdllkJHFaWMlriœ¤¦OS`*)(ttsƒ}ƒ{ttd\\sre{{tb[UVTL74,JHFFD;UTSVZTkd\redjV[{u{ekdmtt{{tult{{t‹’Š|‚zu{{lkslri\UZuztƒ}ƒ[TTƒ„„Œ‹“lri]cdddc{||UTStt{„„Š›¢›|„…tts{u{|„…››”uztultUTSlddztl|‚zek]{{ƒ:97f]c\[[{ttlld”“›{u{|‚z“Œ”{ttƒ„„rfk{tt‹„„sref]cUMR[[TlriJHFƒ||\[b{{ƒƒ„„™š¤Œ”•ult]bZultƒ}ƒƒ||mtt’ŒŒ„„ŠŒŒšekdtt{£œ¥”“›ª³·“Œ”„Š„{||{||œ¤¦‹„„ŠŠ}{{tª³·‹„‹”š”ƒ}ƒu{{„„Š|„…’ŒŒ{{ƒultmk…ƒ}Šœ§²œ¤¦~’“œ¤¦ult›²œ¤¦Œ—£Œ—£…‹šŒ—£„„Š|„…“Œ”tllœ¤¦œ››ŒŒš}‡’š””µ¶·“Œ”“““›”›‹…’›”›œ¤¦|„…«²«Œ—£Œ‹“¦§¨™š¤lks™š¤™š¤Œ—£Œ”•…‹’¨©´¡¡…‹‹“““{ttŸ±¯VZ[{{ƒ]cdmttUUY…‹‹„Š„ult”“›yl„Œ‹“f]cf]c‚wlddcJHF[[Tƒƒ|edk’ŒŒ„Š„ulttt{š””edkmttŠƒ}]cdMRK{{ƒ|„…OS`lriŒ”•]bZLKR{{ƒlksuztyl„™š¤“Œ”“Œ”™š¤…‹‹…‹‹‘Œ…‹‹‹ƒ}ƒ‹’Šš””››”‹„„Œ‹“…‹’edkttslekmttfkkƒ„„Œ‹“{||…‹’|„…ƒ„„\[[f]c\[b]cd{{ƒlks|„…Œ”•}‡’‹„„…‹‹ƒƒ||„…lksVZT…‹‹‹’Šf]ckd\b[Uf]c[[Trg]red{{tekd]bZtsl¨©´JHF,55mttlldbVUFD;b[Uz‚lekd[[Tekdlri›¢›SKJlld„Š„ƒ}ƒ{u{{u{d\\UTS…„’lks|‚zlrimttu{{mttllk\[[llk\[[ldd{tt{||lri{{ƒ„„Šulttsl{{ƒmttƒƒ|{||ƒ}ƒƒ}ƒult„„Š{{ƒttsdc\{{t{{t„Š„[[TlksJHFJHFd\\„„Š|‚z{{ƒ‚|uŒ‹“tsl[TTrfkVTLrfkdc\FD;sleekd[TTkk]|„…lldƒ}ƒ{u{JHF{{ƒ\[[UUY]bZ{u{SKJllk„Š„zlllek{||„„Š‹‹‹ƒƒ||„……‹‹…„’‹’Šƒ}ƒ‹„„Œ”•lld›”›‹‹„“Œ”lriŠƒ}ldd|‚z{{ƒŒ”•llk“Œ”lks‹’Šlekmtt“Œ”œ¤¦Œ‹“{{ƒ|„…Œ—£Œ”•œ§²‰Š¡™š¤{{ƒ™š¤ \ No newline at end of file diff --git a/libs/ode-0.16.1/drawstuff/textures/sky.ppm b/libs/ode-0.16.1/drawstuff/textures/sky.ppm new file mode 100644 index 0000000..8b541b1 --- /dev/null +++ b/libs/ode-0.16.1/drawstuff/textures/sky.ppm @@ -0,0 +1,5 @@ +P6 +# Created by Paint Shop Pro +128 128 +255 +¾çýÃéþËîÿÎïÿÆéÿÂçÿºçÿ·åÿ²àÿ°Ýþµàÿ¹åþÃëÿÍðÿÏðÿÐíûÑîüÏïþÇìÿ½æü´àù´âü¹åÿºæÿ¹åÿµâÿ±Þý«Ùú¦×ø§ÙüªÜÿ¶âýÉîÿÐñÿÚõüâúþëýýíýüïÿþìþÿìþÿãüÿÛøÿÊíÿÄéÿ­Ûÿ£Ôü£Øÿ¤Úþ§Üü±ãþ°ãÿ¤Ûÿ ÕýŸÔþ ÕÿŸÔþŸÕÿ›ÔÿšÕÿ™×þ˜×ÿ”Ñý™ÒÿšÓþ›Õý¡Ùþ¥Úü­Þü°ßù»åû½èû½æü»çÿ¸åÿ®Þÿ§ÛÿÓÿšÓÿ•Ðü•Ðü—Òþ“Òþ‘Ðû›Óø§Ùú¾èÿÄêÿÌðÿÆîÿºæÿ¦×ø Öú“Óÿ‹Íý„Çü€Äÿ}Ãÿ}Ãÿ~ÄÿÆþ€ÇýƒÉýƒÈÿÆÿƒÈÿÆÿ€ÄÿÅÿÅÿÆÿ€Åþ~Äÿ}ÄÿÆÿ…ÈÿŒËÿÌÿ„Çü…ÊÿˆÍÿ‹ÌÿŽÍÿ‘ÐÿÎÿ™Ôÿ ×þ±âÿ´áþ¸äÿÂêÿÃèÿ»ãý·àü®Üý©Ùý¥Ö÷©Ö÷¯ÛøÂëÿÊðÿÇëÿÆéýËîÿÉîÿÌðÿÆïÿ¿éÿºæÿ»çÿ¼èÿ»çÿ¹åÿµäÿ²àÿ¨Ùú£Õø Ôù¢Öý²ßüÄêÿËðÿØöÿÞùÿéþÿêþýìþþíÿÿêþÿ×õÿÎðü½ãö·áù®Ûú¬Ùú³àÿ½çÿÂëÿÐôÿÏôÿ¼éÿ³àÿ­Ûü®Üþ¨Úÿ£ØÿŸÕÿ‘ÎúŽÍùÏû‘Îû•Ïý–Ñý˜Óý×ý ØýªÜý¬Ýû¸æÿ»çÿ¶âý²áÿ¬Ýþ ÔûÒü˜Ðÿ•ÏýÍú‘Îû”Ñþ‘Ñÿ‘Ñý˜Òø Ôù·äÿÀéÿÇïÿÀìÿ¸æÿ¥ÙþŸÖý‘ÑÿŠÌþ…Èÿ}Áþy¿ý{Àÿ}Ãÿ€ÆÿÈÿÆý‚ÉÿÇÿ}ÃÿzÀüÅÿÅÿÅÿ~Äÿ|ÂýzÀûzÂýÆÿ…ÈÿŠÉþŠÉþ…Æþ†ÉÿŒÏÿÎÿÍþÍþÍþ”Ïû˜Òú¨Ýÿ°Þÿ²àÿ·ãÿ¸áý±Ýú®Ûú¤Öù Òõ¤Ö÷­Ûü³ßüÃéÿÆìÿ¼âùºà÷ÃéÿÅíÿÈðÿÃíÿ¼æÿºäý½çÿ½çÿ¼æÿ·ãþ³âÿ®ßÿ¨Úý¢ÖûŸÕûŸÔü±ÞýÀèÿÇíÿÔôÿÛøÿåýÿèþüìÿÿíÿÿëÿþ×øÿÍóÿ¾ä÷¹ãùµáüµáüÁëÿÍòÿÒóÿÚ÷ýØöÿÆïÿÁéÿ¸âû³ßü®Üþ¥Ùÿ ×ÿ‘ÎûËúŽÎþÎý”Ñÿ•Òÿ–Óÿ›ÖÿœÖü¥Ûÿ¨Ýý³äÿ·æÿ³âÿªÛü¦ØûŸÔü˜Ñü•Ïý’ÏþŽÌû‘Ïþ”Òÿ‘Ñÿ’Òÿ˜ÒúÓù²àÿºçÿ½éÿ¸æÿ³ãÿ¥Ùÿ ×ÿŽÎþ‰Ëý…Èÿ~ÂÿzÀþz¿ÿ|ÂÿÅÿÆþ€Åþ€Çÿ~Äÿ{Áÿy¿ý~Äÿ~Äÿ~Äÿ~Äÿ|Âý{ÁüxÀûÆÿ…Èÿ‰ÈýŠÉþŠËÿŠÍÿŒÏÿÎÿÌûÍü‘Îý“Îú—Ðû¤Úÿ£Øÿ¥Úÿ®àÿ±ßÿªÚÿ¥ÙþšÑø—Îõ¢Öû´âÿ»çÿÉíÿÈîÿ¹áû³Üø³àý·äÿºçÿ·ãÿ²Þû¹ãü»ãý¼æÿ½çÿ¶ãÿ®ßÿªÜÿ¡×ýÔûšÔü›Õý«Ýÿ¸åÿÀêÿÍòÿÓõÿÚ÷ýßûþéÿÿçÿýéÿýáÿÿØúÿÉíûÆëûÉîÿÊïÿÔõÿÚ÷ÿÙõùàõöß÷÷Úöÿ×õÿÏðÿÉìÿ¹âþªÜÿ¡Öÿ’ÐÿÎÿ‹ÌÿŽÍÿÏÿÏÿÐþ”Óÿ‘Ðû›ÖþžØþ¨Þÿªßÿ¥Ùþ¡×ýŸÖý˜Óÿ“ÐýÍþŽÍÿŽÍÿÎÿÎÿÏÿÏÿ’Ïü–Ïú£×þ¨Úÿ¨Øü¤Øý¥ÙÿžÕþ—Òþ‹Êý†ÈüƒÅÿÃÿ|Âÿy¾ÿz¿ÿ}Ãÿ~Äÿ‚ÇÿÇÿx¿ýv½ýu¼üw¾þzÁÿzÁÿzÁÿzÂýyÁüw¿ù€Åþ„ÇüˆÇüŠËÿŒÏÿŠÍÿˆÊþ‘Îû•Îù”Íø–Ïú“Éõ“ÊóÔý›ÑÿžÔÿ©Ýÿ¬Ýÿ£×ÿ Õý˜Ñü•ÐúŸÕû±âÿ¼éÿÌðÿËðÿ¼åÿ´àý°ßý±ßÿ´âÿ´ßÿ±Ýúºäý¹áû»åþºæÿ´ãÿ¬Þÿ¨ÜÿžÕü˜Òú˜Ñü›Ôÿ¥Ùþ²áÿ¸åÿÆìÿËïÿÕóýÜùÿçÿÿäþýæÿüæÿÿßþÿÐñúÎîùÐòþÒóÿÚúÿÝøÿÝöúåûùæûüßøýÚõüÚøÿÕöÿÂêÿ¯ßÿ£Øÿ‘Ïÿ‹Íÿ…Èý‹ÍÿŽÍÿÌÿÍýÐþÍü—ÔÿšÕý¡Ûÿ¤ÜÿžÕü¡Øÿ×ÿ“Ðý‘ÏþÏÿÏÿÏÿÎÿŽÍÿŒÎÿŒÎÿÍü”ÏûžÓý Õý¡ÕüŸÔü¡Öÿ™Òý”ÏûŒËÿ…Æü‚Äþ~Âÿ{Áÿz¿ÿz¿ÿ}ÃÿÅÿ‚ÈÿƒÉÿw¾üu¼üt»ût»ûyÀÿzÁÿyÀÿx¿ýw¿ú{Ãý‚Çþ„Çü†ÅúˆÉÿŒÏÿ‰Ìÿ‡Éû•ÐúœÓúÒúŸÔü™Îö™Îö¡Øÿ”Ìû–ÏüšÐüžÓý™Òý“Îú“Óÿ”ÒÿšÕÿªÞÿ²ãÿÃèÿÅíÿ¾êÿ¸äÿ®Üý¬Úû®Üý²Þû±Ýú³Üø·ßù¸äÿ´áþ®ßÿ£Ùÿ ×ÿœÕÿ›Ôÿ›ÖÿÖÿŸÔü¨Úý­Þÿµáü½åþËïÿÐòþÚ÷ýÛ÷ûàúûíÿÿíÿÿæûüåýÿãþÿßüÿÛùÿÛøþßûÿäÿÿäþÿãøûàøüÞùÿÚøÿÍóÿ±âÿ¡ÕüÎýÎÿ†Éÿ‡ÉýŒÎÿŠÌÿ‰ËÿŠÌÿ‹ÍÿÏÿ‘Ïþ“Ðü’Ïû•Ðü”Ïû’ÏüÏýÏÿŒÎÿŒÎÿŒÎÿŒÎÿŽÍÿÏÿÏÿÏÿ‘Ïÿ”Îü•Îû–Ïü•Îû—Ðý˜Óÿ•ÒÿŽÍÿŠËÿ‚Äþ~Âÿ~ÄÿzÀþy¿ý~Äÿ|Âÿ|ÀýÅÿ{Âÿx¿ÿw¾þv½ýw¾þv½ýw¾üzÂýÇÿÈÿ†Éþ…Èý…Äù„ÅûŠÍÿŠÍÿÐÿ¢Ùÿªßÿµãÿ¸çÿ²ãÿ¬Þÿ Ôû•Îû•Îû–Ìø™Ïû—Òþ‘ÎûÒÿ’Òÿ–Óÿ£Øÿ©Ûþ¸âû¿èÿ»çÿµáþ®Ûú±Þû³àý³ßú²Þùµáü´Ýùµáþ²ßþªÜÿÔû×ÿ™Ôÿ›ÖÿŸØÿž×ÿÔû¢Øü§Üþ¯Þü¶âýÈìÿÌïÿ×õÿÛøÿÝùüêýûîþûëþüêÿÿèÿÿãÿÿÞûÿÚ÷ýÞûÿæÿÿåÿÿãøýß÷ûÜ÷ÿÚøÿÎôÿ³äÿ¢ÖýÍüŽÍÿ†ÉþˆÊþ‰Ëÿ‡Êþ†Éý„ÇûŠÍÿÏÿŽÎþÍüÍüÍúÍúÍüÏÿÎÿ‹Íÿ‰Ìÿ‰Ëÿ‹ÌÿÎÿÏÿÏÿÏÿÎÿ‘Îý“Íý’Ìú‘Ëù”ÎüšÔÿš×ÿÎÿ‹ÌÿƒÅÿÄÿ~Äÿ|Âþ{Áý~Äÿ}Ãÿ}ÁþÅÿ~Äÿ|ÂÿzÀþw½ûy¿ýx¾üx¾ü|ÂþÇÿÈþˆËÿ†Éþ‚Ãù„Åý‹ÎÿŠÍÿ‘Ïþ¨Þÿ´çÿÁíÿÄðÿ¾ëÿµäÿ¤Öû§Ýÿ¦ÝÿœÑû˜Ïø”ÑþÐÿŠÐÿŒÏÿÌÿ“Ìù˜Íõ¬Ýý¸çÿ½éÿ¼æÿ¼äý¿åüÂêÿ½çÿ½çÿ¸äÿ¸äÿ°Þÿ«Üý¢ØþšÓþ–Ñý•Ðü˜ÓÿŸØÿŸÕÿ×ÿ ×þ¤Úÿ©Ûþ¯Ýÿ¾çÿÃèÿÒóÿÙöÿÝøÿãøûçûúéþÿéþÿäýÿáúþÝùýÞúþàüÿáýÿßøÿÚõþÛöÿÛùÿÕöÿÅîÿµäÿ«ßÿ“ÐýŒÌüŒÍÿÎÿ‰ËýŠÍÿ‰Ìÿ„ÇüƒÆû†Çý…Çû‡ÆùŠÉüÍÿÎÿÎÿÏÿŒÎÿ…Çù†Èú‰ËÿÌÿŽËÿÌÿÍÿÎÿÎÿ‘Ïÿ‘Ïÿ‘Ïÿ“Ðÿ–Ðÿ™Ñÿ™ÓÿÎÿŒÎÿ…ÈýÆÿ€Çÿ~Äÿ~ÄÿÇÿÅÿ‚Çÿ‚ÈÿÅÿ|Âþ{Áý|Âÿ|ÂÿzÀüzÀü~ÄÿƒÊÿ†ÍÿŽÑÿÐÿ‹ÌÿŒÍÿÐÿÎÿ’Ïü«Ýÿ¸çÿÌñÿÒøÿÏøÿÈðÿµâÿ©Þÿ¨Þÿ›Ðø—Î÷“ÐýÐÿˆÍÿ†ÍÿˆÉÿÌþ•Îû£Ùû¬ßþºæÿ¿èþÇêýËïÿÌïÿÃìÿÅïÿºèÿ¹æÿ«Üý§ÛÿÔý”ÏûÍú”Ïû–ÑýÓÿžÓýœÖþ×ÿ¢Ùÿ¤Øÿ§×ÿ®ÙûµÞüÇêÿÎíÿ×óÿÛöÿÞùÿÜ÷þÛ÷ûÛ÷ûÛ÷ûßøüäüþéþÿåúýÝôú×ôÿÖóÿÒóÿËïÿ»æù«Üú¥Úü•ÐüÎý‘ÐÿÎÿŽÍÿÏÿÏÿŒÏÿ‡Êÿ†Éþ‡ÊÿŠÌÿŒËÿÍÿÏÿÏÿÏÿŒÎÿ‹Íÿ‹ÍÿŽÍÿÌÿÌÿÌÿÌþÍÿÎÿÎÿÎÿ‘Ïÿ“Ïÿ”Îþ—Ïþ˜ÒÿÏÿŽÐÿˆËÿ‚ÇþÈþ~Åý~Äÿ}Ãþy¿ú}Âý‚ÇÿÆÿÆÿÆÿ€Äÿ~ÂÿÃÿÄÿÆÿ‚Çþ„Ëÿ‡ÊþˆËÿ‰Êÿ‡Èÿ†Èÿ‡Èþ“Îú©Úú´àùÆèòÍîõÒôÿÌñÿ¼äþªàÿ©ßÿ›Òù–Íö‘ÎýŽÎþ†Ëÿ…Êÿ†ÇýËý•Îû£ØúªÝü¹åþÀéýÈìüËïÿÉìÿ¿èþÂìÿ¹çÿ¸çÿ«Ýÿ©ÝÿœÕÿ‘ÎúÌù”Îü–Ñý›ÑýžÓý×ýžØÿ¤Ûÿ¤Ùÿ¦×ÿªÖù±ÜüÄèÿÊêÿÖóÿÛ÷ÿÝùÿÙ÷ÿØöþÛøÿÛøþÛ÷ûâúþçüÿåúûÞöúÓòÿÐñÿÉîÿÄêýµâù¨ÙùŸÔö•Îù”Îü’ÏþÍüÍþŽÍÿÏÿÐÿ…Èý…Èý‡ÊÿŽÏÿÏÿŒËþÎÿÏÿÏÿŒÎÿÒÿÑÿŽÍÿÍÿ‘ÎÿÎÿÎÿŽÍÿŽÍÿŽÍÿŽÍÿÎÿÌþ’Ìü™Ñÿ›ÕÿÏÿŽÐÿˆËÿƒÈÿ‚Éÿ€Æÿ€Æÿ}Ãþz¿ú{Àù€ÅþƒÈÿ„Éÿ…ÇÿƒÅÿÃÿ‚ÄþÆÿÆÿÆý…Ëÿ†ÉýˆËÿŒÏÿŠÌÿ„Æÿ…ÈýÌù¡ÖøªÛù½ãðÆèòÍòÿÌòÿ¿çÿ°äÿ©Þÿ˜Ñü”ÎüŽÍÿÌÿ‡ÉýŠÉü‹Éú–ÐÿžÔÿ°Þÿ´áÿºäú¿êûÇîÿÄíÿÃëÿ¾èÿ¾èÿ»éÿ³äÿ¥Ùþ¢Øþ—Òü“Òþ’Ñý™Öÿ›ÖÿœÒþÔý¡×ý¤Úÿ¤Üÿ£Ùý£×üªÛü°ßý¼äþÀåÿÉìÿÔôÿÓóþÐòþÎïþÍîÿÍîýÔôÿÜùÿßúÿäüþÞúþÍóÿÅîÿ¸âû²ßü¬Üÿ¥ÖþÑùžÓû¡Öþ¢×ÿœÒÿ•Íü’Ïþ‘ÏÿÌÿ‰Èû‡Éý‰Ëý‹ÏÿŠÍÿŽÎþÏÿÏÿÏÿÎÿÌÿŽÍÿÎÿÎÿÎÿŽÐÿŽÐÿÑÿ‘Ðÿ‘ÎÿÍÿ•Îÿ•Íþ–Ïü›Ôÿ™ÔÿŽÍÿŠÉþˆËÿÆÿ€ÄÿÇÿ‚Çÿ€ÂüÂù‚Åü„Éÿ‡Éÿ…Æþ…ÆüŠÉþŠÉþ…ÆüƒÆý‚ÇÿƒÈÿ„Åû‡Èþ…Èý‡Ìÿ‡Îÿ€Çý„ÊþÏÿ–Õÿ›Øÿ©Ûü°ßýµäÿ´ãÿ·æÿªßÿ¤Ùÿ•Ðü“ÐýÌÿˆÊþ‰ËÿŒËÿŽÌý˜ÒÿžÔÿ²àÿ¶ãÿ¹æû¿êûÂëýÆïÿÆîÿ¿éÿ»çÿ»éÿ´âÿ¦Øý¢Öý™Óû—Ôÿ•Òþœ×ÿž×ÿžÕü Öü¤Øý§Ûÿ¦Üÿ¤Øý¤Øý®ßÿ³àÿ¼äþ¿äþÆéÿÑñÿÑñþÍîÿÌíÿÈëþÈëþÑñÿÚöÿÜ÷ÿàùþÜùÿËñÿ¿èü³Ýö¯Üù¬Üÿ©Úÿ¤Øÿ¥Ùÿ¦Úÿ¦Ûÿ Öÿ—Ïþ”Îþ“ÐÿÍþËü‹ÊýÍýÏÿŽÍÿÍüŽÎüŽÎüŽÎþ‹ÍÿŽÍÿŽÍÿÎÿ‘ÏÿÎÿÌÿŽÍÿ‘Ðÿ’Ðÿ‘Íÿ‘Íÿ”Îþ–Ìú™ÏûŸÖýœÖþÍþŽÌÿÎÿ„ÆÿÆÿ‚Çÿ‚ÇÿÃýÄûƒÆý†Ëÿ†Èÿ„Åý†ÇýŽÍÿŽÍÿ‰Êÿ†ÉÿƒÈÿ„Éÿ…Æü†ÈüƒÆúˆËÿ‡Íÿ‚Èü†ÉýÍý’Ïû–Ñý¢Øü¤Ùû¥Úü¥Úü«àÿ•Îû•Ïý‘ÎýŒÊû‡Éý‡Êÿ‡Êÿ‹ÍÿÎÿ–Óÿ›Ôÿ­Ýÿ±âÿºêÿ¾ìÿ¼éÿ¼èÿ¾êÿ¶âý³ßø³ßø·äÿªØü¦ÖüŸÓúŸÖýžÕü¢Øþ£Ùý§Ùú¨Ûú¨ÙúªÛüªÛü«Üý­Þÿ±ßÿµâÿ¿èÿÂêÿÃèÿÈëÿÇêþÅèþÅçÿÃçÿÃçÿÉéÿÑðÿÒïÿÕñýÕõÿÄêý¹âø²Üõ±Þû¯Ýÿ­ßÿ¯áÿ­ßÿ¬Þÿ«ßÿ Õÿ™Íü›ÑÿžÔÿ Öÿ ÖÿŸÕÿŸÕÿ›Ñý˜Îú“Íû‘Ïþ‘ÏþÐÿŽÐÿ‹Íÿ‹ÍÿŽÍÿÍþÌþÎÿÎý‘ÎýÍü™ÑÿžÔÿ Õÿ¤ØÿªÜÿ«Üý¥×úœÓü—Ðû”ÎþÊÿŒËÿ…Èÿ…Èÿ…Èÿ…Èý„Çü†Éþ‡Êÿ†Çý‡ÉýÌÿÌÿÎÿŒÍÿ„Æÿ‚ÄþƒÄúŠÉþŠÉþˆÊþ‰ÈýŒËþŽÌý‘Îý”Íú•Îù™Ôÿ—Ôÿ”Ñý’Ïû’ÏûÉùÍüÍþŠÉü†Éþ‰Ìÿ‡ÊÿŒÎÿÎÿ“Ðÿ—Ñÿ¦×ÿ¬Þÿ·éÿ¼ìÿ¸æþ¶âý·ãÿ´àû²Þ÷³ßø¹äÿ®Úý«Ùý¤Öù£×ü£×ü§Ùú¨Ûú«Üú®Ýù°Ýü±Þý±Þý²ßÿ´áÿ²ßþµáþ¾çÿÁèÿÁæÿÇëÿÇêÿÆèÿÅéÿÅéÿÅéÿÅèþÎïÿÏîÿÑîþÑòÿÅëÿ»äú²Üõ¯Ûø«Ùû®Þÿ®Þÿ¬Üÿ«Ýÿ«Ýÿ¦ÚÿŸÒý¢Öþ¥Ùÿ¦Úÿ«Üÿ¬ÝÿªÞÿ¥Ùÿ¡Òú“Ì÷‘ÎûÎýÏÿŒÎÿ‹Íÿ‹ÍÿŽÍÿÍþÌþ‘Îý’Ïþ’Ìú’ÌúÓÿ£Øÿ§Øÿ®ßÿ³áÿ³àý­Üú£×üŸÓú—ÍûËýÎÿŠËÿ‰Êÿ‰Ìÿ‰Ìÿ†ÉþˆËÿŠÍÿŠÌÿ‰ËÿÌÿŒËÿÎÿ‹ÌÿƒÅÿƒÄþ‚Ãù‹ÊÿÌÿÎÿŽÍÿŽÌýÍþ‘Îý”Íú•Îû‘ÏþÐÿ‘ÑÿÐÿŽÎþ‡Æû†Åú…Æü†Çý…Èý…Èý‹ÎÿÑÿÏÿŒÊùÊ÷™Îø Öü®ãÿ±æÿ¬Ýý­Ûý®Üþ¶âÿ¹åÿ»çÿ½æÿ¶ßÿ´ßÿ±Þý°ßýµäÿ¶äþ¸æþ½êÿ½êÿÁëÿÁéÿ¿çÿ½äÿ¿æÿ¿çÿ½çÿ¼äþ½äÿ¿çÿÃéþÄèþÄèþÅéÿÆêÿÇëÿÆêÿÍðÿÏóÿÎïþÎòÿÅîÿÀèÿ³ßú²Þû´áÿµãÿ±ßÿ¯Ýþ°ßý°ßý±ßÿ¯Üûµáþ¸äÿ»åý¼æþÁëÿÃíÿ½çÿ¶àøŸÕûšÕÿ–Óÿ‘ÑÿÏÿŒÎÿŒÎÿÎÿÎÿ‘Îý”Îü—ÒþœÒþœÓü¦×ÿ«Ûÿµâÿ½çÿÂèÿÈìÿÆìÿ¹åþ´àý¨ÙúÒü›ÔÿÍþŽÌÿŽÍÿ‹Íÿ†ÈúŠÎÿ‰ÍþˆÊþˆÊþ‹ÍÿŒÍÿ‹Ìÿ‡ÈÿƒÄüŠËÿ†Éÿ‰Ìÿ‰ÌÿÏÿÏÿ‘Ïÿ’Ðÿ’ÎÿÍþÎÿÏÿŒÏÿŒÏÿŒÏÿ‰Ìÿ†Çý‡Èþ…Èÿ„Çþ‰ÌÿÐÿŒÎÿÌÿÍþŠÈ÷ˆÅò˜ÎúžÕþ¦Üÿ¦Üþ¤Ùû¦ÖúªØü¹æÿ»éÿ¾êÿ¿èÿ¹âÿ¶ßý³ßü·ãþ¼èÿÀíÿ¼éþÄïÿÆñÿÃìÿÂçÿÀåÿÀåÿÅêÿÂçÿ¿çÿ¾æÿ¾æÿ¿çÿÉïÿÈîÿÇíÿÈíÿÉíÿÈíÿÉîÿËðÿÍòÿÎòÿÌòÿÃìÿÀèÿ´àû²Þû´áÿ±Þÿ±Þÿ¶ãÿ¹æÿ»éÿ»éÿ¼éÿ¼åû¾çûÊïÿÉîÿÏôÿÐõÿÇìüÁèù«àÿ›Öÿ˜Õÿ‘ÑÿŠÌþŒÏÿŒÏÿÏÿ’Ðÿ’Ïþ–ÎýœÕÿžÕþŸÕû«Ûÿ¯Ýþ¹ãüÈîÿÎñÿÎïÿÊíÿÆìÿÂëÿ²Þû£ÕúŸÔü“ÍûŽÌýŽÍÿÌÿŽÐÿ‹ÍÿŠÎÿˆÌý‡Ëü†Èü‡Èþ‹Êÿ‰Èþ‡ÆüŒÍÿŠÍÿŒÏÿÐÿÏÿÎÿÌþ’Îÿ‘ÏÿŽÍÿÏÿÏÿ‹Íÿ‹ÍÿŽÐÿÎÿˆÍÿ„Éÿ‚Çÿ‰ÌÿŽÏÿŒÍÿÎÿ‘Ïÿ“ÐÿÍúÌù‘Îû•Ðü˜ÓûšÔúœÓú Ôü§×ÿµâÿ¸åÿÁîÿ¾æÿÁéÿÂêÿÄìÿÇðÿÉïÿËñÿÆìÿÉðÿÊïÿÇìÿÄèþÅèüÈëÿÉìÿÍðÿÉîÿÁåûÁåûÆìÿÆíþÆíüÇîýÊïÿÊíÿÈìüÊîüËñþËóÿÆîøÄìøÃìÿÃíÿºæÿ¶âý³àÿ´áÿ²Þû¶âý»åþ¼åûÅïÿÎóÿÑóýÐòûÕôùØõûÝüÿÞýÿÕöýÎðù²ãÿ™Óû•ÐúÍýŒËþ†Éþ‡Êþ‹Íÿ‘Ïÿ”Îþ˜ÑþšÓþ Õý¥Ùþ·äÿ¹åþÄêýÖöÿÙ÷ÿÜ÷ÿÝøÿÛøÿ×÷ÿÇìÿ±Þû«ÜýšÐü“ÍûÍþÍýÏÿŽÐÿŠÌþˆËÿ‰Ìÿ‹Îÿ†ÇýˆÇü‰ÈýÎÿ’Ðÿ‘ÓÿÎÿŽÌý’Ìú–Ïü•Îû”ÎüÎÿ‹Íÿ‹ÎÿÏÿ‹Êý‡ÆùˆÇüŠÉþ‚ÈÿÇÿƒÈÿ†Éÿ‹ÌÿŽÍÿ‘Ïþ”Ñÿ˜Óÿ—Òü•ÒþÏÿÍüŽÍù‘Îú–ÑýÓÿ¢Õÿ®Üþ°ÝúºçüÁêÿÄíÿÃìÿÄêýÊïÿÍòÿÊïÿÉìÿÉìÿÇìþÉîÿÈëþÊîþÏðÿÏïþÍíüÍîýËïýÉíýÆëýÆìÿÆíþÊïÿÌïÿÍîÿËìýËïÿÎóÿÎõÿÅïýÂìü¿èþ½çÿµáü¶âý¼èÿµáþ´Ýùºâû¿èþÃéüÈìüÖöÿßüÿàûÿåþÿäýÿæÿÿäÿÿÛùÿÒóü°ßý˜Ïö’ËöŠÊú†Èú…Èý‡ÊÿŽÍÿ‘Îý”Îþ›Ôÿ›Ôÿ¤Øÿ¬ÞÿºèÿÀêÿÎòÿÝúÿàùÿâúþæûþéÿýçÿÿØøÿÀæýµáþ¡Õü˜ÏøÍüÍûŠÌü‰ËýŠÌÿŠÍÿŠÍÿ‰ÌÿŒÎÿŠÉþŒËþ˜Õÿ™Ôÿ˜ÑüÔû Öú¦Öú¦×ø£Ó÷ Ò÷–ÏúÎÿÏÿŽÐÿŠÍÿƒÆúƒÄú…Æü€Æÿ‚Èÿ„Éÿ…Çÿ‹ÊÿÎÿ’Ñý–Óÿ™Ôþ™Ôþ—ÔÿÏÿŽÎþŽÌûÏû–ÓÿžÔÿ¢Õÿ«Ûÿ®Ýù·äù¿èüÄíÿÃìþÅëþÍòÿÍòÿÊíÿÊíÿËîÿÉîÿÉîÿËïÿÌðþÐòþÑñþÖöÿÖöÿÐòþÌíüËïÿÆìÿÆìÿÉîÿËîÿÌíÿËìÿÌíÿÌñÿÌñÿÃìþÀéû¿çÿ¾èÿ·ãþµáü¶âÿ·ãþ¸âû½æüÁêþÉîÿÌíþØõÿÞùÿâûÿèÿÿàøüßøýÞùÿÚøÿÔòü·äÿÒú•ÎùŠÊú…Çù†Ìÿ‰ÏÿÏÿÍü•Íü™Òÿ™Òÿ¦Úÿ­ßÿ¹çÿÀëþÑóÿßúÿãüÿéþÿìÿÿíÿüìÿÿàüÿÇëÿ¼æÿ£×üšÑú“ÐýÏý‹ÍýˆÊü‹Íÿ‹ÎÿŠÍÿ‡ÊÿÏÿŠÉüËüšÔÿžÕþžÔú¬Þÿ³äÿ¹åÿ·ãÿ¯ÛøªØùœÑù’ÏüÏÿÐÿ‰Ïÿ„Êþ„Çü‚Åü~ÄÿÅÿ€ÅÿÃý„ÅûˆÇü•Óÿš×ÿœ×ÿÖÿØÿÏÿŒÎÿŽÎþ‘Ñÿ™ÖÿŸÕÿ¡Ôÿ¯Ýÿ²ßü¸âøºã÷ÅîÿÉïÿÅêúÊîþÊîþÆéüÉìÿÐñÿÎïÿÑóÿÔöÿÖöÿ×õÿÙ÷ÿÞûÿáþÿàþÿ×÷ÿÇëùÈìÿÅëÿÅéÿÇêÿÉéþÉéþÌïÿËîÿÉîÿÁçú¾äù½çÿ»åþ¶ßûµáü½éÿÁëÿÄìÿÇíÿÈîÿÒöÿÖöÿ×ôÿÔðüÖñüàøÿáøÿÝõÿÛöÿÚöÿÕòÿ»èÿžÒù–ÍôÎúÐÿÓÿ’Õÿ•Ôÿ‘Îý“Íý‘Éø”Íú¦Ûÿ­ßÿ¸äýÂëÿÒôÿÞúþäýÿëÿÿìÿýîÿùìÿýåþÿÎïÿÃéÿ«Üü¡Õúš×ÿ–ÕÿÏÿÎÿŽÍÿ‹Íÿ‹Íÿ‹ÎÿÐÿŒËþŽÌûœÖþ¨Üÿ©Øô½çýÊðÿÔõÿÓóÿÏðÿÆêÿ°ßýŸÖÿ–ÓÿŠÍÿ‰Ïÿ‡Ìÿ„Éÿ|Ãû|Äÿ}ÅÿÅÿ}Ãþ~Ãü€ÅüÐÿ—Öÿ™×ÿ™Óÿ’ÏþŠÎÿŠÎÿŽÎþŽÎü™Óÿ£Øÿ¨Ùÿ´àýºäý¼åû½åþÄêÿÆëþÊëúÎïÿÍñÿÄéüÇêþÑðÿÓðÿÚõþÜ÷þØõûÛøþÜùýçÿÿçÿÿàýÿÛùÿÉíýÃçÿÄèÿÁçþÀäúÇìÿÌñÿÍòÿËïÿÊîüËìûÆéü¾åÿ¾åÿºâüºäýÁëÿÈñÿÆïÿÆíþÊñÿÎòÿÖ÷ÿÏïúÐñÿÏóÿ×÷ÿàüÿÞùÿÞùÿÚöÿÖôþ¹åÿ£Õú™Íô’Í÷‘Îú’ÒÿŽÐÿ‘ÑÿŽÌýŽÌý’Ìü”Îü¡Øÿ¥Ùþ¶ãÿÂìÿÔõÿßúÿåýÿìÿÿéüúðÿüðÿÿèýÿØôÿÑòÿ»äÿ«Üü›Õýš×ÿÐÿÎÿÍþÎÿÏÿŽÑÿŠÐÿ‹ÍÿÏûŸÕû·æÿ¶âûÇîÿÓ÷ÿâýÿãüÿÝøÿÓðþ·áù¦ÜÿšÕÿŒÌü‹ÍÿˆËÿ„Çü~Ãü|Äÿ|Äÿ|Äÿ|ÃÿyÁüw¿ùÄýƒÆý†Åû‹Èþ‹Éü‰ÍüŒÎþÐÿÎý—Ðý¥Ùÿ­Þÿ¶âý»åýÅëÿÉïÿÈëÿËìýÒðûÒòÿÎïÿËîÿÌïÿÓòÿ×ôÿÞõûåýÿãÿÿåÿÿæÿÿèÿÿçÿÿäýÿÞûÿÎïÿ¿äþ½äÿ¾èÿ¿éÿ¿éÿ¾èþÄíÿÃéüÅêüÌðþËðÿÅêÿÄéÿÁçþÂèÿÉïÿÆìÿÂèûÃìþÈòÿÉðÿÐòþËïÿÃìÿÁêÿÊïÿÎïÿ×óþÛöÿÛøþÙöþÊóÿµâÿªÛûŸÕùœÔù‘ÏøŽÍø‘ÏþÍþËýÍü’ÏüœÕÿ¡Öþ²áÿ»çÿÎòÿÖóûÝöûéþÿëÿþíÿÿíÿÿéüÿÞöÿØõÿÇíÿ¹åÿ£Ùý×ÿŽÍù“Ðÿ‘Ëù–Ðþ—ÑÿŽÎüÌÿ‘Ñÿ”ÑýŸÓø»çÿÇíÿØúÿàþÿæÿÿèÿÿäýÿÛ÷ÿÄêÿ¬Þÿ¢Øþ“ÑÿÏÿ‡Éý†ÉþƒÈÿ|Äÿ{Ãþ{Ãþ|Ãÿw¿út¼÷zÀû}ÂûÂúˆÇý‰ÈýˆÌûŠÌüŽÎþÍü˜Ñþ§Ûÿ°áÿ»äÿ¿çÿÊðÿÊðÿÍîÿÐðýÙõÿ×õÿÎîýÎïÿËïÿÏïþÔñÿãúÿèÿÿæÿÿâÿÿâþÿêÿÿêÿÿæþÿßúÿÐðÿ¾æÿ¹åÿ¹åÿ¼èÿ»çÿ·ãþ¼æÿ¿èüÄêýËðÿÊïÿÇëÿÇëÿÃèûÃéüÉïÿÅëþÀæùÂëýÈñÿÅïÿÈíýÇíÿ¾èÿ»åþÆêÿËìÿÖòýÜ÷ÿßúÿÝøÿÎóÿ¾èÿ¶äþ«Þý¥ÚúœÖü™Ôü—Ôÿ‘ÍÿŽÊüËýÌû™ÒýžÓû¯Ýþ¹åÿÊïÿÔòüÙôûæþÿêÿÿìÿÿíÿÿèýÿß÷ÿÛ÷ÿÊïÿ¾èÿ©Þþ¢Úý”Ïù”Ñþ“ÎúÓÿŸÕÿ•Ðü‘Îû—Ôÿ™ÔþžÒ÷½éÿËðÿÝûÿàýÿâûÿäýÿÜøÿÕõÿÄìÿ²ãÿªÞÿ˜ÖÿÑÿ‡ÉýˆËÿ…Êÿ|Àý|Âþ~Äÿ~Äÿv½ûsºøu¼úzÀþ€ÄÿÃÿ„ÇþŠÌü‹ËûËúÌùžÔÿ©Ûþ±ßÿ½åÿÃéÿÌïÿËïÿÚöÿáüÿèÿÿâûÿÞúÿÖöÿÐòþÎîûÔòýàùþæÿÿåÿÿÝùüßøüìÿÿëÿþêþÿäûÿÕñýÀéýµãû­Ú÷°Ýü°Üÿ­Ùü¶áÿÂìÿÈñÿÍôÿÌòÿÔôÿÕõÿÐñÿÌðÿÌñÿÆìÿ¾çû¼åû¿éÿ½çÿ·ãþ³àÿ®ßÿ¯Ýþ½åÿÃçýÓïûÛöÿáúÿÜøüÏí÷ÎðüÌòÿÄïÿ»èÿ¯àþ§ÜþŸÖÿ•Ïý‘ËûŽÍÿŒÌü“ÐüšÔüªÜÿ´ãÿÀéýÒôÿØöÿßûÿåþÿèÿÿêÿÿæþÿßøýÚ÷ÿÊîüÅëþ»éÿ²äÿ¦ÜþŸÙÿ Õý«Ýÿ®ÞÿªÜÿ¥Ùþ¤Ûÿ¡ØÿŸÓø½éÿÑòÿÙ÷ÿÓñüÐðýÏðÿÆìÿÀéÿµâÿ¯ßÿ«Ýÿ”ÒÿŒÍÿƒÄú„Çþ€Åþ}¿û€ÂþƒÇÿÅÿx¿ÿw¾þv½ýw¾ü}Ãÿ~ÄÿƒÈÿŽÎþÏý”Ñþ–ÑýŸÖÿ­Þÿ³àÿÄêÿÉîÿÏðÿÖôþäýÿèÿÿìÿÿìÿÿëÿÿÚöÿÓñûÓñûØöþÚóøàùþáýÿÛ÷úàøüêþýìÿýìÿÿëþÿß÷ÿÎóÿÅîÿ½åþ¼åÿ¹âÿ¶ßÿ»âÿÅéÿÊîþÓõÿÓôýÚ÷ÿÛùÿÕõÿÐòþÊîþÇíÿÁçþ³Ýö´Þ÷²ßü¯Ýÿ Ôû¡Õü£×ü±Þý¿äþÑíûÙôÿâûÿàùþÛ÷ûÚ÷ûÚùþÔöÿÍñÿ¾èþ³áû¥×üšÐþ”Ìû“ÓÿÐÿ“Ðý—Òü¤Ùû­ÞþºäüÌðÿÑóÿÚøÿâÿÿæÿÿèÿÿæþÿÝöúÚóøÔòüÐòþÉïÿ¾èþ³âþ¬àÿ®Þÿ²Þû³ßúµáþ´âÿ©Ûÿ¡ÕüœÒø¸æÿÆìÿÅèþºà÷µãû²áýªßÿ¢Øü›Óø¡ØÿžÕþÊÿˆÉÿ„Åý„Æÿ‚Çÿ…Æÿ„Æÿ€Åÿ~ÄÿzÁÿx¿ýw¾üzÁÿÅÿÅÿƒÈÿ‘Ïþ”Òÿ•Òÿ—Òþ¡Öþ°Þÿ¶áÿÄêÿÊïÿÖøÿÖôüæþÿéþÿîÿÿëÿÿçüÿÛöÿÖóûÕòø×ôúßøüÛôùÜøüäÿÿçÿÿëÿþìÿýìÿÿìÿÿàøÿÎðüËïÿÆëþÄèÿÂåÿÁäÿÆèÿËìÿÑñþÖôüÑï÷ÙöüÛùÿÑñüÏñýÊîþÇíÿÅëÿ¹ãüµÞú±ÞýªÚþ¡ÕüŸÔü Ôû°Ýþ½âýÒïÿ×óÿÛöýÝøÿÝöúâþÿßûÿÙ÷ÿÖöÿÉïÿÁëÿ¬ÝþÓÿ–Îý‘Ïÿ“Óÿ˜Õÿ˜Óû¢×ù©ÚúºäüÉíýÎïþØöÿÜùÿäÿÿèÿÿèÿÿáùûÝöúÚ÷ÿÓóþÈíýÆìÿ²àø¨Úû®Üþ¼åÿ¹ãü¶ßû¼éÿ¥×üžÒùÓù¯áÿ½æÿ¹âþ±Þû¨Ýý¡ÙüžÙÿšØÿ’Ïû•Òÿ—Ñÿ‰Èþ†Çÿ‰ÊÿˆËÿ†Éÿ„Åý„Åý‚ÄþÄý}Ãþ}Ãþ€Æÿ‚Èÿ…ÊÿƒÈÿ‰Êÿ’Ïþ•Òÿ˜Òÿ™Òý Ôû¯Üý¶ßûÃèûÉíýÔõþÛúÿëÿÿíÿÿóÿýîüýìûÿâùÿßøýáúþäþÿçÿÿåþÿáýÿàüÿäýÿéýüêþýëÿÿåüÿÙõÿ×õÿ×õÿÖóÿÔôÿÔóÿÔôÿÖóÿÚôÿÝõÿßöþÜõüÔòüÔòüÊê÷ÈéøÄçúÇíÿÅîÿÀéÿºæÿ¶ãÿ¶äÿ«Ýÿ£×þ¢Öý°Ýþ¿çÿÑòÿÙöÿÛùÿÜúÿÞùÿáúÿàùþàûÿÝúÿÒóÿÉïÿ´ãÿ¢×ÿ›Ôÿ‘Îû”Ñý˜Óû›Òù¨Úû°ßû½æüÉíýÎðüØöÿÜùÿàüýãýþæþþêÿÿèÿÿäÿÿàýÿÔöÿÌðÿºàõ±Ýø¯Ûö·ßø¸àú¶ãÿ®ßÿ ÕýŸÖýŸÔüÑø¡Õü¢Ùÿž×ÿ•Ôÿ‘ÑÿŒÐÿÓÿŽÑÿ‹Íÿ‹Êÿ„Åý…Æÿ‹ÌÿŠÍÿ„Çü†Çý†ÇýƒÆý‚Åü€ÅþÆþÈÿƒÊÿ†Ëÿ‡Êÿ‹Ìÿ“Ðÿ–ÓÿšÓÿ›Ñý Ôû°Ýü·áúÅèûËìûÖôþÝúÿëÿÿîÿÿôÿþòüýïýÿéüÿåýÿçÿÿéÿÿèÿÿçÿÿâþÿÝúþáýÿéþÿëÿþèýÿàùþÕòÿÚöÿÚöÿÚöÿØöÿ×õÿ×õÿÚöÿÜ÷ÿßöþáõþÝôüÔôÿÓóÿÊëúÆêúÅêýÃìÿÂìÿ½éÿ»çÿºæÿ¹æÿ¯àÿªÜÿªÜÿµâÿ¿çÿÐñÿÖõÿ×÷ÿ×÷ÿÜøÿÜ÷þßøÿàûÿÞùÿÒóÿËðÿ¶ãÿ¢×ÿ›Ôÿ™ÔÿšÕÿ›ÕûžÔø«Üü²áû¾çûËìýÎîûØôÿÛøþàüýáûüãûûèýþéþÿåþÿàûÿÕõÿÏðÿÁæù¹ãû¶àù¸âú¸âû³áÿ¨ÜÿœÖþ×ÿŸÖý˜Íõ™Ïû™Óÿ•ÒÿÏÿÏÿ‡Íÿ‹ÑÿŠÐÿ‡Êÿ†Çý…Æþ…Æþ‹ÌÿŠÍÿ„ÇüÏÿÏÿˆÊþ„ÇüƒÉý…ËÿƒÉý†ÉþŠÌÿÌÿ‘Ïÿ•Ïý˜ÒÿÓÿŸÔÿ§Øÿ·ãÿ½åÿÈìüÎðüÙ÷ÿÛøþêÿÿíÿÿ÷ÿÿøÿÿöÿÿòÿÿïÿÿìÿÿìÿþèýþæþÿàüÿÛøüàüÿèÿÿçÿÿßøý×ôüÍîÿÓðÿÕñÿÙ÷ÿÛùÿÝüÿÝüþÜúüÞúþàùÿã÷ÿÝôÿÒöÿÑòÿÊíÿÄéûÂèûÃìÿÀêÿ¹åþºæÿ¾ëÿ½çý¸äý²áÿ­Þü´áþ»ãýÄçûÉêýÊíÿÉîÿÐðÿÓñüØôÿÚõþØóüÒòÿËîÿ´áþ¢×ÿž×ÿœÖþžÕü¡×û§Ùú¶ãÿ»çÿÇìÿÐðýÔðüÛöýáúÿäþÿåýÿçüýéýþêþÿäûÿßøÿ×õÿÒòÿÐóÿÈîÿÄíÿºæÿµâÿ¢ØüŸÙÿ–Õÿ”Óÿ ×ÿœÓü“Ñÿ‹Êÿ‰Èý†Èú‰ËýŒÎÿŒÎÿ‡ÊþˆËÿ†Éÿ‡Èÿ†ÇÿˆËÿ‰ÌÿˆÌýÏÿÏÿˆÊþ„Çû†ÉýŠÍÿˆËÿŠÌÿÍýÍþ“Ðÿ–Ðþ™ÑÿÓÿ Õÿ¬Üÿ¸äÿ¿çÿÉíýÏñýÙ÷ÿÚùþèÿÿíÿÿ÷ÿÿøÿÿöÿÿóÿÿïÿÿíÿÿëþúêþÿåýÿßûþÛøüßûþçÿÿäüþÚõüÕóýÌïÿÏîÿÓðÿÙ÷ÿÛùÿÛýþÜþýÚúùÜøüáùÿâøÿÛõÿÎóÿÍðÿÈíÿÁçú¾äùÁêÿ¿éÿ¸åü¸åü¼æü½æø»åû¶åÿ²áý¶âý¸âû¿âøÁäøÄéüÅêýËìÿÒïÿØôÿÖñüÕðûÒïýÉìÿ±Þû ÖüÖÿ¡Øÿ£Ùÿ§Üþ¬ßþ¼èÿÁëÿÌïÿÕóþ×óþàùÿåüÿéÿÿëÿÿéýþåùúäøùÞõûÜõüÙ÷ÿÕõÿ×úÿÌñÿÈîÿ¸äý±àþšÔú—Ôÿ“ÓÿÐþœÖþžÕþ—ÕÿŠËÿ‰Ëÿ‰Èû‹ËûÏÿŽÎþˆÊüÏÿ‰Êÿ„Çþ„ÇþŠÍÿŒÏÿŠÎÿ‘ÏÿÎÿŽÎþŽÍÿŒÎÿŒÎÿÏÿŒÎÿŽÍÿÏÿ‘Ïÿ•Ðú˜ÑüŸÖý Öü«Üý¾çÿÇíÿÒñÿÕòÿÛöÿáúÿëÿÿïÿÿ÷ÿÿöÿüôÿûñÿÿîÿÿèÿÿçÿÿâþÿÞúûÜøùßùúãûýâúþÞ÷üØôÿÒñÿÉìÿÐñÿÑóÿÒôÿÕ÷ÿØúÿÕ÷ÿÕöÿ×õÿØöþÜùÿÛùÿÎóÿÈïÿÁçú¼åùÁëÿ¼èÿºæÿ·äÿµâÿ°ßý«Þû¶éÿ´åÿ²áý´àûºãÿºâüºâü»åþ»äÿÈìÿÍðÿÐóÿÎõÿÉòÿÀïÿ¹éÿªÜý¡Öþ¤Ùÿ©ÝÿªÝü°ßû·ãüÇíÿÌðÿØöÿÜõüßøýèÿÿéþÿèýþéþÿêÿÿæûþáùýÝöýÛöÿÛ÷ÿÚöÿÒòÿÏñýÃêû¶âý¯ÝþŸÔþšÐþ”Îü•ÏýžÕþžÕü™Òÿ•Ïý’ÏþÎÿÌÿÌÿÌÿÌÿÎÿ‘ÍÿŠÊú‰ËûÏÿŽÐÿÏÿ’Îÿ‘ÍÿÍþÍý‹Íÿ‹ÍÿÏÿŒÎÿÌÿÎÿÎÿ”Ïù—ÐûžÓû Ôù°Þÿ¼æÿÆêÿÐïÿÕòÿÞöÿåýÿìþþïÿþöÿÿøÿüõÿüñÿÿíÿþæþþäýÿáÿÿßûüÝúøâúúçüýåýÿàùÿ×ôÿÑðÿÆéÿÊëúÍïûÑòÿÔõÿÑòÿÉíýËïÿÎðüÒòýÖ÷ÿÕ÷ÿËòÿÆìÿ¾çû»åû½éÿºçÿ¸åÿµáÿ´àÿ®ßÿ©ßÿ¬âÿ¬ßþ¬Ýý´àýµÞü¶ßý¸áý¹åÿ»çÿÅéÿËîÿËñÿÃðÿÀïÿ¸êÿ±äÿ¥Úü¢×ÿ¤ÙÿªÜÿ«Þýµãý½çÿÊïÿÏðÿÚõþÝöúáùûêÿÿéþÿêþÿêþÿêÿÿæþÿäýÿÙôýØóüÙõÿØöÿÒòÿÎòþÄêý¶ãÿ±ßÿ£Öÿ›Ïþ”Ìû•ÎûžÕþ ÖüŸÔüšÐü–Ïü’ÎÿÌÿÎÿÎÿÍÿ‘Îý“ÍûÌøÎú’Òÿ‘ÑÿÎÿ’Îÿ’ÎÿÎÿÎÿÏÿŽÐÿÏÿŒÎÿÌÿÌÿÎÿ•Ðü™ÒÿŸÔþ¢ÖýµãÿÀêÿÈìÿÒòÿ×õÿãüÿìÿÿîþþïýýôþýøÿþ÷ÿýôÿÿïÿþçüýãûÿàüÿßûüâüýçÿÿéþÿãûÿÞ÷üÕóþÏïþÆéýÐñÿÏñýÉíýÈíÿÇíÿÃéÿ»äú¿åüÃéþÈîÿÆïÿ¾èÿ¸äý³ßú¯Ý÷¯Þü¯àÿ¬ÝþªÚþ©Ùý£×üžÔøÕú£Ùÿ¥Ùÿ¤Öû£Ó÷¬Ùú±Üüºãÿ½çÿÊëþÎïÿÈíÿ»åû¹åþ¯àþ¥×øœÐõ£×ÿ¤×ÿ¦Ûý«Ýþ»èÿÁíÿÍòÿÒóÿÛöÿäüþèýÿëÿþêþýíÿÿìþÿëÿÿåþÿáüÿÕñýÐíûÍîÿÎïÿÇìÿÁêþ¶âý­ÞÿªÜÿ ÕÿžÔÿšÐüÒú©Þÿ¯áÿ¬Ýþ¤Øý ÕýšÓÿ–ÐÿËýËýÍü•Îû˜Ñþ›Õý×ÿØÿšÕÿ“Ðÿ”Îÿ”Îÿ’Îÿ’Ðÿ“Óÿ”ÔÿŽÐÿÎÿÎÿ’Ðÿ“Ñÿ˜ÒÿÕÿ¨Ýÿ©Ýÿ³áÿ¿éÿÈíÿÑñüÖôüãüÿêýÿñÿÿõÿÿöÿÿöÿü÷ÿÿõÿÿñÿÿìÿÿêÿÿâûÿßøüáúþçÿÿéþÿäüÿßøýÖóûÒðûÊëúÍïûÍîýÈíÿÄíÿºæÿ³àÿ¬Úü©Úû«Üý¯Ýþ¯Ýþ¬ÝþªÛü­ÞÿªÜý¨Úýªßÿ©Þÿ§Ýÿ¥ÛÿžÖûÔû•Ï÷—ÒþšÔÿœÖÿÓÿ«Ýÿ³áÿ¾èÿÅêÿÏðÿÍðÿÇíÿ·ãÿ´áÿ¦×ÿÑùšÏùŸÖÿœÓú Öú¥Úü´ãÿºæÿÌñÿÔõÿÜ÷ÿèýÿëÿÿëþüíÿþïÿþîÿÿëÿÿÜ÷ÿ×óþÍîÿÄçû½åþ»åþ°Üù®Üý£×ü¡Öþ ×ÿÓÿ Öÿ¢Öý¨Úý¸çÿ½ëÿºæÿ´áþ®ßÿ¨Üÿ¤ÙÿÖÿÖÿÓÿžÓû£Øÿ«Ýÿ¬Üÿ¨Üÿ¤ÙÿœÒþ”Îþ”Îþ’Ïþ‘Ïÿ‘Ñÿ’ÒÿÏÿŽÍÿÎÿ“Ñÿ“Ñÿ–Ðþ™Ñÿ§ÜÿªÞÿ³áÿ½çÿÆëþÒòýØöþåþÿêþÿñÿÿõÿÿöÿÿ÷ÿÿ÷ÿÿõÿÿòÿÿìÿÿêÿÿäüÿàøüáùýéþÿéþÿåýÿàùþØõýÕóûÎðúÐòþÐñÿÇíÿÃíÿ¶åÿ®ßÿ¤Õý Öü¡×ý£×þ£×þ¢Öý¢ÖýªÞÿ«ßÿ©Ýÿ©ßÿªàÿ¨àÿ¥ÝÿÔûžÕþ—Ðý“Ðÿ”Ðÿ•Óÿ—Ñÿ§Üÿ±áÿ¾èÿÆìÿÎòÿÊðÿÄìÿ¶âÿ±ÞÿŸÒÿ˜Îü˜ÑþšÕÿ—ÒúœÔù¢×ù±âÿ¸æÿÊïÿÒóÿÜ÷ÿèýÿëÿÿëþüîÿÿïÿþíÿÿêÿÿÛ÷ÿ×ôÿÊíÿÁçþ¹åÿ¶ãÿ©Úû¤ØýÔûžÔÿž×ÿžÔÿ ×ÿ§Ùü­Þþ¿ìÿÄïÿÄíÿ½çÿ¶äþ®ßÿªÜÿ Õÿ ×ÿŸÔü£×ü¨Üÿ´âÿ³àÿ­Þÿ«Ýÿ Õý–Ðÿ•Ïÿ‘ÎýÍüÏÿÏÿŽÎþÍýŽÌÿÎÿ‘Ïÿ“Íý—ÏþŸÔþ¥Ùÿ²àÿºäúÃèúÑòûÙøýëÿÿîÿÿôÿÿôÿÿöÿÿ÷ÿÿ÷ÿÿòÿÿðÿÿëÿÿêþÿãøýãøýåúÿèýÿçüÿåýÿãüÿÜøüÙöüÚøÿÔöÿÎòÿÀéý¹åþªÜÿ¤Øÿž×ÿ˜Òÿ—Ñÿ”Ïû‘Ìø˜Ñþ›Ôÿ£Úÿ¨Ýÿ­ãÿ¦Üÿ¡Øÿ¡Ûÿ¡Ýÿ“ÎöÓÿÓÿÌÿÊÿÏÿÍÿšÓþ¥Ùÿ´áþ½åÿ¿éÿ¶ãÿ³áÿ§Ûÿ Ôÿ–Ðÿ“Ïÿ’Ðÿ•Ôÿ”ÓþœÔù¡Öø²àÿ¹åÿÈíÿÎïÿÜ÷ÿèýÿéüÿîÿÿðÿÿíÿÿíÿÿãüÿÚ÷ÿÔõÿÁéÿ¹åÿ±ãÿªÞÿ—Íù”Ìû•Ïÿ—Ñÿ™Óÿ¡Øÿ¥Ûÿ¬Û÷³áùÈïþÌðüÎðüÊîþÄêý´àû¯Þü¤Öù Ôù¥×ü«Ýÿ²âÿºæÿ¼èÿ´áÿ°Þÿ¨Üÿ•Ïÿ•Ïÿ‘ÎýÍüÎÿÏÿŽÎþŽÎþÍÿÎÿ‘Íÿ“Íû–ÏüÒü¢Öý®Ýû¹ãùÂçùÐñúØ÷üéÿÿíÿÿôÿÿôÿÿõÿÿôÿÿõÿÿñÿÿïÿÿëÿÿêÿÿäùüäùþåúýçüÿæûþäýÿäýÿßûÿÜùÿÛøÿØøÿÑõÿÀéÿ·ãþ¦ØýžÓý”Ñþ’Ïþ“ÐÿÍúÊ÷”Îü—Ðý Öÿ¢Ùÿ¦Ûÿ¥Ûÿ¢Ùÿ×ýœØý”Ï÷šÐüžÔÿ”ÐÿÎÿÏÿÍÿšÓÿ£Øÿ¯Ýþµáþµãý±ßÿ­Ýÿ£ØÿÓÿšÓÿ—Óÿ“Ñÿ“Óÿ“ÒýžÔú¥×ú³âÿºæÿÈíÿÎïÿÛöÿâùÿçüÿìÿÿíÿÿìÿÿêýÿßøÿÔôÿÌñÿºæÿ²àÿ©Þÿ¤Ûÿ“ËúÍü’Îÿ”Ñÿ–Óÿ ×þ§Ýÿ°ßùºäúÌòÿÒóüÑòûÎïþÉîþ½çÿ¶äþ§Øù¤Öù§Ùü¬Þÿ±âÿ¼èÿ½éÿµâÿ°Þÿ§Ùþ”Ìý”Ìý’ÌüÍüÍüÍüŽÎþÍþÍþÌþÍü–Ñû™Òý Õý¤Øý¯Þü½çýÆëýÑñü×õýåþÿëýýñÿÿòÿÿñÿÿîüüïýþëýýêþýêÿþêÿþíÿÿìÿÿíÿÿíÿÿêÿÿçÿÿçÿÿäÿÿãþÿÝúÿØõÿÑòÿÀåÿ¶âÿ¢ØþšÓþ’Ïþ–Ôÿ˜Öÿ—Ôÿ”ÑþÍú’ÍùÔý¡ÖþŸÓú ÖüŸÔü˜Òú˜Óû—Òü˜ÏøÓÿ™Ñÿ–Ðþ“Íý“Íû–ÏüœÓüžÒùžÒ÷¦Öú¦Öú¥×üžÓý™ÏûšÕÿ™Ôÿ—Òþ˜Óÿ˜Óý¡Õú§Øù³àý»äÿÈíÿÎïÿÚöÿÞ÷þâùÿèýÿèýÿçüÿÞöúÓïúÈëþ¿èþ¯Ýþ¥×ü›Ôÿ™ÓÿÌÿ‘Ïÿ’Ðÿ”Ñÿ˜Óÿ¡Ùþ©Þþ¹æûÇîÿØøÿÛøþÜ÷þ×õÿÓõÿÇíÿ¼æÿ­Úû«Ùû­Ýÿ¯àÿ¯àÿµâÿ¶ãÿ³áÿ®Þÿ¤Øÿ”Ìû”Ìû“ÍýÍüÍüŽÌûŽÎüÍþÎÿ’Îÿ’Ïþ—Òü›Ôÿ£Ùÿ¨Üÿ³âÿ¾èþÇìÿÑñüÖôüãüÿëýýðÿÿñÿÿïÿþìüüíýýëýýêþýêÿþëÿÿëÿþëýýëÿþìÿÿéÿÿåþÿãüÿßøýÞùÿÝøÿ×ôÿÏðÿÀåÿ¶âÿ£Ùÿ›Ôÿ“Ðý–Õÿ™Öÿ—Òü”ÏùÍú“ÎúŸÖÿ£Øÿ£Õú ÔùžÒù›ÕýØÿ™ÔüŸÖýŸÖýÓÿšÓþ™Òÿ•Îû—ÍùšÐü™Ðù™Ðù£Óù¦Öú¥×úžÒ÷›ÏöžÕüžÕüœÓúÒúžÓû§×û¬Úû¶âý½åÿÊíÿÏðÿÚöÿßøÿßøÿæýÿèÿÿãûÿÝöýÒðûÇëÿ¾èÿªÚþ Ôû–Ðþ“ÏÿÍÿÎÿ‘Ïÿ“Ðý—Òü¢Øü¬ßþ¾èþÊïÿÚøÿÜøüßøýØöþÕõÿÉíÿ½åÿ®Ûü¬Úü®Þÿ®Þÿ¯ßÿ²àÿ±ßÿ¯ßÿ«Ýÿ¡×ýšÒÿšÒÿ˜Òÿ•Òÿ‘ÏþÎýÍüÍþ‘Íÿ–Òÿ˜Õÿ™ÔüžØÿ¨Þÿ¬áÿ·æÿÀêÿÈíÿÏïüÔòüÞ÷üêþýìÿûíÿüíÿþíÿÿëýýêþýéÿýèÿþéÿÿïÿÿíÿþìÿýéþÿçüÿâûÿÞ÷üÛôûÞ÷þâûÿÚöÿÒñÿÁæÿ¶âÿ£×þœÓü˜Õÿ™×ÿØÿ™Óø•Ñö—Òþ›Ôÿ¥Úÿ§ÛÿªÚþ¨Úÿ¨Ùÿ¢×ÿ ÚÿÖÿ¢Úÿ¡×û Öü¢Öý¢Öý¤ØÿœÒþ›Ôÿ—Ôÿ—Ôÿ¨Øÿ²Þÿ³áÿ®ßý¬Þù°âý±ãþ´ãÿ±Þÿ²Ýÿ¸åÿ¹æÿ¾èÿ¿çÿÇêþËìýÑïú×ôüÚõþÞùÿßúÿßúÿÞùÿÓóÿÆìÿ¼èÿ¦ØýÒü“ÍÿÌÿŽËÿ‘Ïÿ‘Îý”Ïû˜Òú£Øú³äÿÄíÿÎòÿÚ÷ÿß÷ûàøüÞùÿÛùÿÌñÿÃëÿ¶ãÿ±ßÿªÚÿ¨ØþªÚþ¬Üÿ¨Úÿ¤Øÿ¢Öý›ÒùŸÔüÔûœÖþÖÿ–Ñý‘ÎúÍùÍù•ÐüšÕÿœÕÿ ×ÿ¥Úÿ­ßÿ±ßÿ¿èÿÈîÿËðÿÐñÿÕõÿÙ÷ÿåþÿéþÿéþÿêÿþéÿýèþüêþüëÿýëÿýëÿýðÿÿíÿÿéýþàøüÜøüÔòüÒðúÍíúÏïüÐðÿÍðÿÉîÿ½çÿ·ãþªÝü¥Úü¡×ýŸ×ü£Ùÿ¡×ûžÔøŸ×ú¢Úý©ßÿ©ßÿ¨Üÿ¦Úÿ¤Øÿ£×ü£Ùý¥Úú©Ûü²áÿ³áû´àû»çÿµáüªÛû¦Øû£Ûÿ¤Þÿ³áÿÄìÿÈîÿÊîþÊëüÅêúÆëûÉîþÍîýËëøÉðÿÆïÿÆïÿÅîÿ¿èþ¿åüÃçýÍîÿÒòÿØöÿØöÿÓõÿÓóÿÑðÿÁéÿ¸åÿ¡Ýÿ™ØÿÏÿÍþ“Íý’Ïü•ÐüšÑøŸÕû¯Þü¹åÿÉîÿÏðÿÚ÷ÿÚöúÝøÿÚöÿÙ÷ÿÑòÿÈíÿ½æÿ¶áÿ¦Öü¡Ôÿ£ÖÿŸÕÿ ÖÿŸÕÿÓÿšÓþ Öü ÖüŸÖý×ÿ–Ñû”ÏùÍù“Îø–ÑûœÖþ×ÿ¡Øÿ¦Úÿ­Ýÿ°Ýþ½çÿÅëþÉìÿÎïþÒóÿ×÷ÿßûÿäüÿåýÿçÿÿèÿþæÿüéÿýêþýëÿþìþþïÿÿíÿÿéüÿÞ÷üÛöýÖöÿÓóþÎïþÌðÿÍîÿÌñÿÈîÿ½çý·ãü­Þü©Üû©Ûü¦ÛýªÜÿ©Ûþ¤Ùûž×õ¢Øú¨Þÿ©Þÿ¨Ýÿ¤Øÿ£×þ¤Øý¥ÚüªÝü¯Þüµãýºäü½æüÂëÿ½æü°Þø«Úø¥Ûý¨àÿµâÿÈîÿÌïÿÕóþÕóþÏïüÍïûÐòüÔòúÒï÷ÎðúÊðûÈïÿÉïÿÁêÿ¾æÿ½æüÆëþÊîþÏñýÏñýÍóÿÐñÿÍìÿ»âÿ±ßÿ›Ùÿ“ÖÿŽÎþÍþ•Íþ”Îü•ÐúœÓú¢Öû²ßþ»åþÉìÿÏðÿÚùþÚõüÜøÿÛ÷ÿÙ÷ÿÏðÿÈëþ¾æÿ¶âÿ¨Øþ¡Ôÿ¡Õÿ¡×ÿŸØÿ›Ôÿ›ÑÿœÒÿ¢Øþ¢Øþ ×þžØÿšÕÿ™Ôþ–Óÿ™Ôþ›Öÿ×ÿ×ÿ¥Úÿ§Ûÿ­Þÿ±Þý¾èÿÇíÿÉìÿÉêûÌíüÏïüÖóûÚõüÝùýáýÿãÿÿçÿÿæÿÿåÿÿçÿÿèÿÿåøþéüÿçûÿÞùÿÚøÿÕ÷ÿÓõÿÎïþËïÿÍîÿËîÿÆëý¾äùºãù¶ãúµáú¸æÿ½éÿ¾êÿºãÿ´âü¬ÞÿªÜÿ¨Üÿ¨Ûÿ¤×ÿ¡Ôÿ¡Ôÿ¥Öþ©Ûÿ¯àÿ¶âÿ¼æþÈîÿÌñÿÎñÿËðÿÀéÿºäý°áÿ°áÿ¼èÿÍòÿÓôÿÛùÿÜøÿÛùÿ×÷ÿ×ùÿßýÿÞùÿÞúþÛ÷û×õÿÖöÿÎñÿÉíÿ¿èþÁêÿÄíÿÆïÿÆðÿÄëüÆëýÃçÿ°Ûû§Ùú™×ÿ‘ÔÿÍýŽÌý’Ìü•ÏýšÔü¢Øþ¨Üÿ·äÿ¼æÿÊíÿÐðÿÚ÷ýÛ÷ûÚõþÜøÿÙõÿÎîûÌíþÁçþ¹ãüªØú ÔüžÑþšÏû›Ðü›ÐúœÑû¡Öÿ¡Öþ¡Öþ ×ÿÖÿœ×ÿœ×ÿš×ÿ›Öÿ›ÖÿœÖþœÖþ¤Ùÿ§Ûÿ®ßÿ²ßþ¿éÿÉïÿËîÿÊëüÌíþÏïüÔòýØõýÚ÷ÿÞûÿßüÿåÿÿâþÿáýÿâýÿåþÿÞõûáøÿàùÿØôÿÕóýÔöÿÒôÿËïýÉíýÊíÿÍñÿËîÿÄéüÃèûÀéýÀéÿÂëÿÌòÿÍóÿÄèþ½åþ±âÿ­Ýÿ©Úÿ¨Ùÿ¡Ôÿ¡Ôÿ¢Óþ¦Öþ©Ùÿ±ßÿ»äÿÃéþÏòÿÓôÿÔôÿÐñÿÉîÿÂëÿ¸æÿµâÿºäüÌïÿÒóÿÜøÿÛöÿÚøÿÖöÿ×ùÿàþÿáüÿäüÿâúüÛöýÚöÿÑòÿËîÿÃéþ¿èþ¿èþ¾éü¾éü¾çù¿èü»ãý­Ûü¥Úü—Öÿ“ÔþÏÿÍþ”Îÿ—ÒþœÖþ¥Ûÿ¬Þÿ¸äÿ¿éÿÌïÿÑñþÚ÷ýÚöúÙôýÛøÿÙõÿÑñüÐñÿÊîÿÀèÿ¬Úû¤Øÿ¢Õÿ˜ËöšÍøžÒúŸÓû¢ÖþŸÔü ÕýžÕþšÓþœ×ÿžÙÿ™Öÿ™Ôÿ—Òü›Ôÿ×ÿ¡×ý¦Úÿ­Þþ¯Üù¹ãûÅëÿÉîÿÉìÿËîÿÊîþÌíþÏðÿÑòÿÖöÿØùÿÚøÿÓóþÑñüÒòÿÓôÿÙöÿÚ÷ÿØõÿÒòÿÑñþÒóÿÑòÿÉíýÆéüÈëþÏðÿÎïþÍîýÎïþÏðÿÏðÿÕõÿÝûÿÝùÿ×óÿÒòÿ½æÿ³ßüªÚþ¨Ùÿ ÓÿŸÒÿ¡Òý§×ý¯Ýÿ¹åÿÁêÿÏóÿÙöÿÛ÷ÿÝøÿÛöÿØõÿÒóÿÇíÿÃéþ¾äùÉêûÎîûÛöÿÛöÿ×óÿ×ôÿÕõÿØöÿÜ÷ÿß÷ûàøüÝöûØóüÔòýÒòÿÍñÿÇìÿÆëþÅëÿÃìÿ½êÿ¹æý­Úù£Õú Öü”Òù’Ñú‘Ïþ“Ñÿ–Òÿ–Ñý ×þªÞÿ±âÿ»çÿÁéÿÍñÿÒòÿÝúÿßûÿàùÿÝöýÛöýÚ÷ÿÙ÷ÿÏóÿÆíþ³ßúªÜý¥ÙþÒúÔýžÕþÒüœÑûŸÔü ÕýÔý™ÒýšÕÿœ×ÿ–Óÿ–Ñý•Ðú›ÔÿŸÖÿ¤ØýªÜÿ°Þÿ¯Üù·áùÆìÿÉíÿÈëþÉìÿÆéüÆëþÉîÿÍñÿÔöÿÖøÿÓóÿÍïûÉíûÊîþÌïÿÎïÿÏðÿÏðÿÎïþÎïþÎïþÎïþÉíýÇêýÌïÿÔôÿÔôÿÔôÿÖöÿÙ÷ÿØöÿÚöÿÝøÿÞ÷þÜõüÙõÿÄíÿºäý®ÜþªÚÿŸÒýŸÒý¡Òû«Ùû±ßÿ¼èÿÂèûÒóÿÙõÿÚõþÞ÷þàùÿÚöÿ×õÿÌðþÈíÿÅëþËìýÏìúÙôÿÚõþÖôÿÕõÿÕõÿÕóþÙõÿÜõüÞ÷þÜ÷þØóüÕóý×õÿÎîýÊëüÊíÿÎñÿÌóÿÂïÿ¼èÿªØúŸÓúžÖû—Óø“Ñø’Ïû’Ïþ–Ðÿ–Ïú¡×ý­ßÿ²ãÿ½éÿÀèÿÎïÿÒòÿßüÿâþÿãüÿÞ÷üÝöûÝùýÛøþÕõÿÌðÿ¼æþ²ãÿ¬ÞÿÔûÔýœÓü›ÒûÔýœÑù›ÐøœÓü›ÔÿšÕÿ™Ôÿ•Òÿ–Ñý•ÐüšÓþ¡Øÿªßÿ­ßÿ±àþ¶ãÿ»åýÄêÿÇëÿËîÿÉìÿÂæü¾äûÀæýÂèýÉîÿÍñÿÍñÿÇìþÂèû¼åû¼äþ¾æÿ¿èþÀéýÅêüÇìþËïÿËïÿËïÿËîÿÎñÿÐñÿÓóÿÕõÿØôÿÙôýÙôûåþÿèÿÿèýÿæûþâûÿÍñýÄëü´âü¬ÝýžÔú¦Üÿ©Ýÿ³äÿ½ëÿÃîÿÊïÿÏïüÔñùÙò÷ãøýäùþáøþßøÿÖôþÑñüÊïÿÎïÿÑñþÚõÿÚõÿÖóÿÐñÿÌíþÑñÿÕòÿÑñþÑóÿÕõÿÖöÿØöÿÙ÷ÿ×óþÖòþÔðüÒîüÒòÿÄîÿ»çÿ¬Üÿ¤Ùÿ¤ÚÿŸÕ÷Óõ™Ð÷—Ðû—ÐýÔû¤Øý­Þÿ²àÿ½æÿÂèÿÎïÿÓóÿÜùÿçÿÿçÿÿéþÿêýÿéþÿçÿÿÝøÿØöÿÉïÿºèÿ²áÿ¦Üÿ¥ßÿ¡ÛÿœÕÿ—Òü˜Í÷›ÐúžÔÿ›Ôÿ—Ñÿ–Ðþ”Ñþ•Ïý”Ïû™ÒýŸÖÿªßÿ­ßÿ³âÿ¸åÿ¼æþÄêÿÆêÿÈìÿÇëÿÀæý½åþ½åþ¾çýÄêýÉîþÍòÿÅëÿÀéÿ·ãüµáþ²Þûµßø·áù¿èüÄêýÈíÿÊïÿÌïÿÌïÿÌïÿÍîÿÏñýÓóþ×óþÙôýÜõüèÿÿêÿÿèýÿçÿÿæÿÿÔöÿËðÿ¶äü¬ÝûÓù£Ûÿ§Ýÿ²äÿ»éÿÅîÿÉîþÐðýÒï÷ØñöæûþéüÿæþÿäýÿÚ÷ÿÕóýÊïÿÐñÿÔôÿÚöÿØôÿÑñÿÍîÿÆéüÍìþÏïþÍñÿÎòÿÒóÿÕõÿÙ÷ÿÚøÿÚõþØóþÕðûÑëøÒïýÅîÿ¼èÿ®àÿ©ßÿ©ßÿ¥Úù¦Ùø ÔùÒú™ÏûŸÔü©Ýÿ¬Ýþ°ßýÁéÿÂèÿÍîýÑñüÚ÷ýçÿÿêÿÿëþÿìþÿìþþëÿÿåýÿßúÿÎòÿ¾èÿ³àý¦Üÿ§Þÿ¥Üÿ¢ÙÿœÖþÒüŸÔþÓÿ˜Ñþ”Îü•Ïý‘Îû’Ìú“Îú™Òÿ ×ÿ«Ýþ­Þþ¶ãÿ»éÿ¼æþÃéÿÄèþÅéÿÅéÿÀåÿ½æÿ¼åÿ½åÿÃéþÉîÿÊïÿÅëÿÀêÿ¸åÿ±ßÿ©ÛüªÛû¯Þú»èÿÁêþÇìþÊïÿÏòÿÍðÿÊíÿÌïÿÍñÿÔôÿØöÿÞùÿàüÿãüÿâûÿáúþæÿÿåÿÿÙúÿÎòÿ´àû©Úû›ÔÿœÕÿ ×þªÝü²áûÂíÿÌóÿÒôÿÓðøÖòöçÿÿêÿÿéÿÿçÿÿÚ÷ýÕòúÄéûÌïÿÔôÿØöÿÕòÿÎïÿÊíÿÃçýÆéýËëÿÕöÿÔõÿÖôÿØöÿÚ÷ÿÙöü×ôüÖôÿÒòÿÍîÿÏðÿÆìÿ¼æÿ¨Úÿ¬àÿ²äÿ¾ìÿÀìÿ¶ãÿ­Þÿ£×ÿ§ÛÿªÚþ°Þÿ´áþ¾æÿÃéþÌíüÏïúÙöúèÿÿíÿÿòÿÿòÿÿôÿþôÿþìþÿçüÿÔñÿ¿åüµßø­Ûü¬Ýý¬Ýþ¨ÚûŸÔö§Üÿ¥ÚÿŸÕÿ›Ôÿ–Ðþ”Îü’Ïü“Íû“Îú˜ÑþŸÖÿ¨Ûú­Þþ´áþ¸æÿ½çÿÂèÿÁçþÅéÿÅéÿÃèÿ¼èÿ½æÿ½çÿÁçüÃèûÂæüÀèÿ½æÿ±ßÿ®Üþ¦Üÿ¨Ýÿ®áÿ»éÿ¾èÿÄéüÈíÿÌïÿÈëÿÅèþÉîÿÊïÿÏñýÑñüØõýÚ÷ýÙõùÙõùÙõùÞûÿßüÿÔñÿÊëþ´áÿªÜÿ•Íþ–Ðÿ˜Ðÿ£Õú©×ø½çÿÆïÿÏóÿØöÿÝøÿæþÿêÿÿèÿÿäýÿØõûÓðøÅêüÉîÿÐñÿÕòÿÑñÿÎñÿÌðÿÂêÿÅéÿËîÿÕñÿÕðûÚõüÞùÿáýÿÞûÿÚøÿÏóÿÈîÿ¿éÿÂêÿÅèû»ãü¨Øü®ÞÿµãÿÁêÿÅëþ¼æÿ´áþ¬Þÿ­ßÿªÛü´áÿºæÿ¾æÿÄèþÎïþÑñüÛøüéÿÿïþÿõÿÿ÷ÿÿøÿü÷ÿûñÿÿìþÿÛõÿÇêþÀåÿ¸âû¹ãû½çÿ»çÿµáþªÞÿ¦Ûÿ¡×ÿž×ÿ–Ðþ‘Îû”Ñþ’Ïþ“Íû—ÐýÔý§Ùú­Þþ³àý¶äþ½çÿÂèÿÁçþÄêÿÅëÿÅêÿÀéÿÀêÿÀèÿÁçþÁçüÀæýÀêÿ¼èÿ±Þÿ­Ûý¨Ýÿ©Þþ°ãÿ½ëÿ¿éÿÁçúÆëþÈíÿÅèþÃæüÈîÿÉðÿËðÿÍñÿÔôÿØöÿÙöþÛøþÚ÷ýàýÿàÿÿÐñÿÃçý­Ýÿ¦Ûÿ˜Òÿ—Ñÿ™Ñÿ£Õú¦×ø»çÿÄïÿÏóÿÜúÿáüÿêÿÿëÿÿèÿÿäýÿØõûÒðøÅêüÇìþÍîÿÏïþÎîýÌïÿÊîÿÀèÿÂçÿÇíÿÒîüÓîùÞ÷þåüÿéÿÿæÿÿÛùÿËðÿÂëÿµäÿ·äÿ·ßù°Ûû¡Òú¥ÖþªÛü¸äý¿èþ¹ãü³ßü¯Ýÿ®Þÿ®Üþ´áÿºæÿÃéÿÆéýÐðýÕóýÝùýìÿÿðþÿõÿþøÿÿøÿü÷ÿûõÿÿðÿÿàøÿÍîÿÇêþÆìÿÇíÿÆïÿÄìÿ¹ãü²äÿ«ÝÿŸÔüÔý–Ðþ”Ñþ“Ñÿ’ÐÿÍü”Îü˜Ñþ£Ôü¨Øþ²àÿ³àý¹æý¾çý¿èüÁêÿÂëÿÂëÿÆìÿÃéþÂèýÀéÿ¾èÿ¾êÿ»éÿ¹çÿ±ßù®Ýù¨Ù÷´ãÿ»éÿ¾èÿ¿çÿÀæýÂèÿÀæýÀæýÁæÿÃîÿÃîÿÅîÿÄíÿÉíÿÎñÿÑòÿÖôþÛøþßûüÚùþ¸åú«Ýøœ×ÿ•ÓÿÌÿ–Îÿ™Íü¡Óø§ÙúµäÿÀêÿÌïÿÞùÿâùÿëÿþíÿþëÿÿåþÿÜúÿÔôÿÁåûÉìÿËîÿÈëÿÇêþÉìÿÉîÿÁêÿ·ãü»çÿÍîÿÕòÿçýÿíÿÿîþþíýýà÷ýÎñÿÃíÿ¥ÙþŸÖÿ—Ñÿ–Ðÿ•Ïý—Ðû—Ñù­ãÿ²æÿ²âÿ°Þÿ°Ýþ°Ýþ´ßÿ»äÿ¿çÿÅêýÌíþÓðøÛôùèýþïÿþôþýöüü÷ýýøÿþøÿÿöÿÿïÿÿèýÿÜõüØóüÏïüÐñÿËïÿÊíÿÈîÿ¶èÿ­ßÿŸÔüžÕþ–Ðþ’Ïü‘Ïÿ‘ÏÿÍü•Ïý˜Ñþ Ôû¦Øý²àÿ³àýºçþ¾çý¿èüÅëÿÆìÿÇíÿÅëÿÅëÿÄêÿ¿èþ¿éÿÀìÿ¹çÿ¶äþ²áý±àþ¬Û÷¶ãÿ»éÿ½çÿ¿çÿÃéÿÃéþÃçýÄêÿÄêÿÀéû¿èúÃéüÂèûÇìÿÍðÿÎïÿÑòûÖôüÙöúÒóú²àø§Øø—Òþ‘ÏÿÌÿ–ÐÿšÐþŸÓú¤Ùû³âÿÀêÿÉìÿØôÿÞ÷üëÿþíÿþíÿÿçÿÿÝúÿÖôÿÄéüÉíÿÊîÿÆêÿÃçýÅéÿÆìÿ½åþ²Þù¹åÿÈëþÓðþåýÿìÿÿðÿÿïÿÿâùÿÍðÿÂêÿ¤ØýžÕþ”Îÿ‘ÍÿÍú“Îø–Ðø§Þÿ¬ãÿ¬àÿ«Ýÿ«Ûÿ¬Úü±Þÿ¹åÿ¾èÿÅéÿÊëüÕñüÞ÷þëÿÿðÿÿóÿýôýüõþýøÿÿøÿÿôÿÿïÿÿéþÿàùÿÜ÷þÕñÿÖóÿÍîÿÊëþËðÿ³åÿ¯áÿ§Üÿ¢Ùÿ”Îü‘ÎûÍþÍþ’Ïþ—Ñÿ™Òÿ Õý¥Ùÿ°áÿ³âÿ¼éÿÀéÿÃéþÆìÿÆìÿÇíÿÃéþÆìÿÅëÿÀéÿÂìÿ»çÿ¶ãÿ´ãÿ²ãÿ¯àþµäÿÂîÿÆòÿÁêÿÃéþÈíÿÉìÿÉíýÌðÿÊïÿÅèûÀãöÄèøÊîüÉë÷ÇéõÔôÿÔõþÕöÿÏïúÆêúªÜý Öü’ÒÿŒÐÿŽÑÿÎý•Îû›Ðú Õý¬Þÿ¹åÿÈíÿ×õÿÛ÷ûêþýëþüîÿÿëÿÿâùÿÛóýÈíÿÃéÿÁçþÀæýÁçþ¼äþ¸áý¬Øõ®Üý´âÿÁåûÌìûßúÿåýÿìþþîÿÿæýÿÏóÿÃìÿªÛûŸÕû“Ïÿ’ÎÿŽÌýËúÌø’Ïü–Ñý•Îù•ÎùŸÔþ¥Öþ«ÛÿµäÿºçÿÅëÿÈëþÚöÿäýÿîÿÿðÿýòÿÿóÿÿóÿÿôÿÿôÿÿñÿÿïÿÿéüÿâúþÝõùØòÿÖòÿÐíýÏîÿËîÿ¯áÿ­ßÿ¦Ûÿ¡Øÿ”Îü’ÏüÍþÍþ“Ðÿ—Ñÿ—ÒþžÕþ¢×ÿ­ßÿ±àþºæÿÀéÿÃéþÅëÿÅëÿÅëÿÅëÿÆìÿÅëÿ¿çÿ»çÿ¹åÿ·æÿ·æÿ³äÿ°áÿ³àýÀìÿÆðÿÃéþÄêýÊîþËïýËïûÏñýÍñýÍîÿÉèúÍíüÓóÿÎïøÊëôÙúÿÙúÿÙùÿÐðýÄéü¦ÚÿœÓúŽÐÿŠÐÿŠÐÿŽÍù’Íù™ÏûÒþ§Ûÿ³áûÅìý×õÿÙõùèüûëþüñÿÿíÿÿæûÿÞõýÉîÿÀæý½ãú¾æÿÀèÿ¹âþ²Þû©Ö÷«Ûÿ¯ßÿ¿åúÊëúÜùÿâùÿéýþìÿÿåþÿÐôÿÅîÿ¬Ýû Ôù’ÐÿÎÿÍýŠÊúˆÈøÍûÎýŽËøÌùšÓÿ¡Öþ¨Úÿ²ãÿ¹æÿÃéÿÈëÿÛ÷ÿåþÿîÿÿðÿýñÿÿðþþïÿþðÿÿðþþîþýìþþêþÿéþÿâúüÖñüÔðþÑîþÒñÿÉìÿ®àÿ¦Øû›Ðø›Òû•Ïý’ÏüÍþŽÌý“Ðÿ—Ñÿ–Ñý ×ÿ¤Ùÿ­ßÿ¯àÿ¹çÿ½çý¿èüÄêýÄêýÅëÿÁçþ½æü¾çý¿çÿ¹ãü¹åÿºèÿ·æÿ²áý²áýÀêÿÇíÿÈîÿÄèøËìûØöÿÚøÿÙøýØ÷üÜûÿÜøÿÛ÷ÿÜøÿÚ÷ÿØõùÚùüØúüÙùÿØøÿÌíÿÁåÿ¢Öþ–ÌøŒÎþ‰Ïÿ†ÍûÏû‘Îú•ÎûšÐþ¡Öÿ¯ÞüÁêþÒòý×ôúêÿÿíÿÿõÿÿõÿÿðÿÿèùÿÌíþ¾çû½æü¿çÿ¾èÿµâÿ´áÿ­Ûÿ¦Öþ¨Ùÿ¾æÿÈíýÙúÿÞùÿçüÿéþÿâûÿÒóÿÈîÿ¯ÞøŸÔô“ÑÿÍþ‘ÐÿŠÌÿ„ÇûˆËÿŽÐÿŽÐÿŒÎÿ“ÑÿšÓþ¢Øþ­ßÿ³áÿ½åþÃèûÙõÿãüÿðÿÿóÿÿîÿÿìþþëÿþëÿþêþýéýþêÿÿêÿÿìÿÿçüýÓïúÒòÿÐôÿÏòÿÇíÿ­ßÿ§ÙüœÑùšÑú’ÌúÍú‘Ïÿ‘Ïÿ’Ïþ•Ïý–Ïü ×ÿ¥Úÿ­ßÿ°áÿ·åý»åû¾çýÀéÿÁêÿÂêÿ¿çÿ¼æþ»åý¸âú·áùºäü¹ãû¹ãû½çÿÀêÿËðÿÒóÿÍïûÍëõÖóûæÿÿåþÿáûüãýþãýþâûÿâúÿãüÿäýÿßûüÞúûØõùÚøÿÚ÷ÿËêþÄæÿ§ÙþžÓûÐþŒÐÿŠÐÿÏýÏû”Îü—ÏþŸÔÿ®ßÿÁëÿÌíüÖôþåýÿëÿÿñÿÿóÿÿðÿÿìûÿØõÿÈíÿÂèû¿èþÀêÿºæÿ´áÿ®ÜþªÚþ­Ýÿ¾èÿÆìÿÓõÿ×õÿàùþãüÿÝøÿÓôÿÎôÿºæÿ«Üü–Óÿ“Ðý‘ÏÿÌÿ‹ÍÿÏÿŽÐÿŒÎÿŽÍÿ–Ôÿ×ÿ¢ØþªÛü°ßýºäúÁæùØóþâùÿïÿÿñÿýìþþèýþéþÿçÿÿåýÿÞöúßùúèÿÿçÿÿãûÿÕ÷ÿÍõÿÅïÿ¾éúµâù®àÿ¨ÚýžÓû›Òû’ÌúÌùÎÿÎÿ‘Îý”Îü•Îû¡Öÿ¦Úÿ®àÿ±âÿ¸æþ¹æý¼æþ¾èÿ¾èÿ¿éÿ¿éÿ»åþ¹ãü¸âú¹áú¼äý½æü¼åû¿èþÆìÿÕöÿ×ôÿÓñûÕð÷Þ÷üçÿÿçÿÿçüýæþþåýýâúþâùÿäûÿåýÿãüÿßûþÙöúÙ÷ÿÚøÿÏìüÉéþ¬Úû£Õú‘ÐüÏÿ‹ÏÿÏý‘Ðü“Îú”Ïû›ÑýªÛü¼æÿÊíÿÓóÿÞ÷üçüÿíÿÿñÿÿîþþìûþÜøÿÍîÿÆéüÂèýÀêÿ¾êÿ¸åÿ°Þÿ®Üþ±ßÿÀêÿÄíÿÎòÿÓóþÞùÿáýÿÜùÿÒóÿÏôÿÁëÿµäÿšÕÿ–Ñý‘ÏþÎÿ‘ÐÿÎÿÎÿŽÎþ‘Ïþš×ÿÔû¡Õú§Øø¬Û÷ºãùÄçûÙôÿãúÿïÿÿñÿýíÿÿçüýèýþèÿÿäüÿÜõúÛ÷úãüÿäýÿáúÿÕùÿÌöÿÀëû·ä÷°Þõ¨Úý¥×úžÓûœÓü–Ðþ–ÓÿÎÿÎÿ‘Îý”Îü•Îû¥Öþ©Ûÿ¯àÿ³âÿ¸æÿ»çÿ¹åþ¶âûµãýµãý·åÿµáüµáú¼æþÃéÿÃéþÈëþÇêýËìýÒòÿÜøÿßøÿâùÿèýÿêþÿíýýïÿþîþýïÿþìÿýéýüèýþéþÿçÿÿáøþÞ÷þÜ÷ÿÞùÿàûÿÚõþÒðûÀéÿ²ßü—Î÷ÌûÎÿ‘Ïÿ“Ðÿ—Òþ˜ÓýŸÖý¨Øü·àþÌðÿÔõÿÛöýãúÿëÿÿíÿÿíÿÿíÿÿäüÿÓñüÎîûÃæù¿åøÆðÿÅïÿ½éÿ·ãü¶âûµáú»åýÈïÿÑòÿÛ÷ÿÜùÿÚöÿÎïÿÊíÿÀèÿ¶ãÿ¡ÛÿžØþšÕÿ•Ïÿ“Ðÿ‘Îý•Ïÿ˜ÑþšÓþ Õý¢Öû¬Þÿ´ãÿ·åÿÃéþÏðÿÞùÿæýÿïÿÿðþþíÿÿëÿÿêÿÿâûÿÞùÿ×ôü×ôüÚ÷ÿÝøÿÛöÿÏóÿÇðÿ¿êý¸åú°Þö¨Úý¤ÖùÒú›Òû—Ñÿ˜ÕÿÎÿÎÿ’Ïþ•Ïý—Ðý¤Öû©Ùý±ßÿ³âþ¸æÿ»çÿ¸äý²àú²àú³àý²ßü´àûµáú¼æþÇíÿÉîÿÎïÿÏïþÓðþ×óÿáúÿåüÿéþÿîÿÿîÿÿñÿÿóÿÿòÿÿòÿÿòÿÿëÿýéÿýéþÿæþÿßöþÜòýÞöÿÜ÷ÿàûÿÞùÿØõýËðÿ¼æþœÑù“ÍûÍÿ’Îÿ•Ïÿ—ÒþšÕý¢Úÿ¬Üÿ¸áÿÊîÿÐñÿÙöþáúÿéþÿìÿÿîÿÿíÿÿæÿÿ×óþÕóþÅéùÂçùÇðÿÆðÿÀêÿ»åû¸âø±Ýø´àùÅëþÌðÿ×õÿÙõÿÙ÷ÿÏðÿÊíÿÀåÿ´àý¢Úÿ ØýœÕÿ–Îý•Ïý—Ïþ™Ñÿ Õÿ¡Öÿ£×ü§Ùú±âÿµãý¶âûÀæûÍîÿÝøÿåüÿðÿÿòÿÿìþþëÿÿæþÿÝùýÜ÷ÿÖôþÖôþÙõÿÛ÷ÿÚõÿÎñÿÇíÿÀéÿ½çÿ²Þùºçÿ³âÿ§Ùü Ôû›ÔÿžØÿ’Îÿ’Îÿ–ÐÿšÒÿÓÿ¥Õû¨Øü®ßÿ²áÿ¶åÿ¶åÿ´áþ¯Þü°ßý±âÿ°ßû»éÿ¼èÿÃéþÑôÿØ÷ÿÚöÿÛ÷ÿÞùÿß÷ÿéþÿêþÿëýÿíýýïýþôÿÿöÿÿõÿþôþÿ÷ÿÿòÿýïÿýïÿÿíÿÿãùÿàöÿÝõÿÔïøÙôûäÿÿàýÿÔöÿÊðÿ¬ÞÿžÔÿÌÿÍÿ‘Íÿ’Ïû•ÓüŸÙþ¨Úÿ°Ûý¿çÿÅêýÖöÿÙöþáúÿåýÿêÿÿêÿÿâûÿÙôýÚöÿÍíúÈéøÌïÿÌñÿÃéüÁêüÂëý±Ýö²Þù»äúÂèûÐñÿÕóþÚöÿÒòÿÍîÿ½âü°Ü÷¡×ûŸÕû¡Öþ Õÿ¡Öÿ¤Øÿ¤Õý¨ØüªÛü°ßýµâÿ½éÿ¾èÿÀéÿÎòÿÕõÿåüÿëþÿðÿÿñÿÿïÿÿáùûÞõûÛöÿ×óÿ×õÿ×õÿØùÿ×÷ÿÖóÿÇêþ¾âú¼âùÂçÿ¿çÿÍòÿÇíÿ³Üø«Øù¤Õÿ¢ÕÿšÏÿ›ÐÿœÔÿžÔÿÒþ£Ôü¥Öþ©Ûþ¬Ýþ°áÿ±âÿ³áÿ¬Ýþ«Ûÿ°Þÿ³àýÀêÿÅîÿÍñÿÔòýÜøÿÜôþÞ÷þäýÿäýÿçüÿëýÿìþÿðÿÿòÿÿõÿÿõÿÿöÿÿöÿÿõýÿöÿþòÿüðÿÿïÿÿçûÿáøÿÖñüÏëöÐîöÚûÿàÿÿ×õÿÊïÿ¬ÞÿÖÿŽÍÿŽÍÿÍÿÍüÏûØÿ£×þ­Ûý¸äýÀêÿÍóÿÕ÷ÿßüÿâýÿçþÿçÿÿÞúþÝúÿÝúÿ×õÿÓñüÍíüËìýÃèûÄíÿÀëþ¶àöµß÷µâù»åýÌñÿÖøÿÚõüÙöþÕõÿ¼åû­Ûõ¡×ý£Ùÿ£×ü¨Úý¬Ýþ²áÿ¶ãÿ²àú°ÞøµáúÁçþÄêÿÊðÿÍòÿÕóýßúÿêüþðþÿòÿÿñÿÿæþþÛöýÖðýÓîÿÕðÿ×õýÙøûØûýÓõÿÍñÿ½ãú»äúÀæûÂèûÈíýÙ÷ÿÒòýÉìÿÈîÿ¹äÿ²Þÿ©Úÿ¦×ÿ¢Öþ¢Öþ¢Öþ ÕýŸÔü¡Õü£×ü¦Ûû­ßÿ®ßÿ§×û§×û²àÿ¼èÿÈñÿÐõÿ×÷ÿÜ÷ÿàùþàøüâúþéÿÿèÿÿèýÿêþÿêþÿíÿÿïÿÿòþþóÿÿõÿÿ÷ÿÿ÷ÿÿ÷ÿýõÿúôÿÿóÿÿìýÿéüÿÜóûÓîõÔïøÚ÷ýÜùÿÔòúÉíýªÜý›ÕýŠÉü†Èü‹Êÿ‘ÏÿÍü“ÐüžÕþ¢Öû­Üú³áû¿êýÇîÿÒôÿÕõÿØôÿÙôÿÚøÿÚ÷ýÜùÿáüÿáüÿÙ÷ÿÒòýÂæöÃìþÃîÿ¾èÿ·àü±Þû¸åÿÈñÿÏòÿÞùÿÖòþÎíÿ»åþ²áÿ¬Þÿ®àÿ±ßÿ¹åÿ¾èÿÄíÿÅîÿÃìÿÂëÿÂèûÈéüÊíÿÐóÿÕöÿÝúÿåýÿïýýóÿýôÿÿîÿÿäþûØõýÓîÿÐêÿÐìÿÙ÷ÿÚùüØüüÏóÿËîÿÆëþÇìþÍñÿÒôÿÛùÿßüÿÚøÿÐòþÎòÿÆïÿÁíÿ´âÿ­Þÿ¦Øû¤Öû¢ÖýŸÔþžÓýžÓûŸÕû¤ÙûªÜÿªÜý¤Ôø§Õù´áÿ¿éÿÌòÿÒ÷ÿÛùÿßøÿäüÿãûÿäüþçÿÿæÿÿéþÿêþÿëÿÿíÿÿïÿÿðþþòþþõÿÿ÷ÿÿ÷ÿÿöÿüöÿüöÿÿöÿÿðÿÿìþÿèûÿà÷ýà÷ýâûÿãüÿ×õýÉíý¨Úû™ÓûŠÉü†Èü‹Êÿ‘ÏÿÎý“ÐýœÕÿ Õý¨Ùú®Ýû¹æý¿èüÉîþÍñÿÐðýÒïý×õÿÚ÷ÿÝúÿäÿÿäÿÿÜùÿÖôþÃç÷ÅëÿÃìÿ¼åÿ´ßÿ±Þÿ¶ãÿÃëÿÊîÿÚ÷ÿÔñÿÈëÿ¸äÿ²áÿ°áÿ³áÿµâÿ¿éÿÄíÿÉïÿÊïÿËðÿÊïÿÇëûËìýÍîÿÐôÿÕ÷ÿÞúþéþÿñÿÿôÿþòÿÿíÿÿæÿýÚ÷ÿÕñÿÐêÿÏëÿ×õÿØ÷üÙûýÓõÿÎñÿÏðÿÐñÿÔôÿÙ÷ÿàûÿáùýäýÿäÿÿßþÿÖøÿÓùÿÅðÿ¾éü°Þö¬Ùø©ÚûžÔÿ›Ñý—Ðû™Óû ×þ Öü¡Õú¦Ôö«ØùºãÿÁçüÎòÿÖøÿÝúÿâúüäùúæûüèýþçÿÿçÿÿæþþéþÿêÿÿìÿÿîÿÿïÿþñÿÿôÿþõÿþôþýöÿüöÿü÷ÿÿ÷ÿÿöÿÿöÿÿõÿÿòÿÿñÿÿîþýêþÿÜúÿÌïÿ§Ùú›ÒûŽÍÿŒËÿŒÊýÍþÍþ“Ñÿ”Ñÿ™ÒÿžÓý¡ÕüªÛû¯Þú¹ãü½åþÃéþÇëÿÑîÿÙõÿÞúÿäÿÿâþÿÚøú×öûÉíûÄêÿ¿äÿ¯Úý®Úÿ²àÿ²àÿ¶âÿ½åÿÇëÿÅéÿ½äÿ´áÿ±ßÿ·ãü¼æÿ¿èþÈíÿÌðþÓóÿÕõÿ×øÿÖ÷ÿÔõþ×õÿÔôÿÔöÿÖöÿÜøüêÿÿðÿýòÿüðÿÿêÿÿèÿÿÝúÿØôÿÑíÿÐíÿÔôÿÕöÿ×øÿÒôÿÏðÿÐíûÒîùÙôûÞ÷þèýÿéýÿæûÿàøüßùúÚùû×ùûÎóûÈîû½æüºáþµâÿž×ÿ™Òý‘Îú’Ïû˜ÓÿžÕþŸÕû­Ûýµàÿ¿çÿÆêúÖ÷ÿÞüÿçÿÿêÿÿèüûêÿþêÿþæþþäþýâüýãýþåýÿéþÿêÿÿëýýëþüñÿýòÿþõÿýõÿþ÷ÿÿ÷ÿÿøþþøþþùÿÿûÿÿùÿÿùÿÿ÷ÿþñÿÿÖöÿËðÿ­ßÿ¡Øÿ‘ÏÿŽÍÿŽÌÿ’ÐÿÏÿÏÿÍÿ”Ðÿ™Óÿ›Ôÿ Õý¦Úÿ­Ûý­Üú³àý¸äÿËëÿÒïÿØôÿÞûÿàüÿÜúüÙøýËïýÄéÿ¼ãÿ²Þÿ«Ùý¬Úü±Þÿµáþ¶âý¶âû±Ýú°Ýü²ãÿ³âÿÃéþÇíÿÌðÿÒòÿÖôþÜùÿàýÿÝúÿÚ÷ýÛøþÖôüÓôýÓôýÖôüÜõùèýþíÿþîÿÿìÿÿæÿÿãÿÿÚ÷ýÔòüÍìþÌëÿÌìûÍíúÑñüÑñÿÐïÿØõÿÙõÿÚõþÝöýà÷ýáõþáõþßöüÞ÷ûÛ÷úÙöúÔõüÏñýÅéÿÁæÿ½æÿ¡Øÿ—Ðû‘ÎúÌùš×ÿ™ÒýŸÔü¯Üý·âÿÉïÿÊëüÙúÿßþÿèÿÿèýþêþýêÿþêÿþåýýâüýÜøûßûþãýþçÿÿêÿÿêþýíÿþñÿÿðÿýñÿýôþÿôþÿ÷ÿÿúÿÿüÿÿüÿÿüÿýûÿýûÿýõþùðþþÏïüÀåø¨Úû ×ÿÎÿÍÿÍÿŽÍÿŽÍÿÌÿŽÌÿ‘ÏÿšÔÿœÔÿÓÿŸÔþ¥×ü«Üý°Þÿ´áÿÁåÿÌëÿÒòÿÛúÿÜùýØ÷úÓôûÉíýÁæÿºáÿ¯Ýÿ­Ýÿ°ßý²ßü³áû³áû°Þø®Ýù°ßý´åÿ¸çÿÄêÿÉîÿËïÿÔôÿÚøÿÜ÷þÞùÿÞúþÝùýÜùýÙøýÕöÿÔõþ×õýÝöûçüÿîÿÿíÿÿéÿÿâþÿÛùûÚøÿ×õÿÌíþËìÿÊëþÍîÿÔõÿ×÷ÿ×öÿÚúÿÛùÿÚøÿÙõÿÜôþÜóÿÝõÿÞöÿÞöÿÞ÷þÜ÷þÛ÷ÿÛ÷ÿÕôÿÐðÿÊïÿ®àÿ¢Øþ–ÑýÍú”Òÿ–Ñý™Ðù°Ýþ½æÿÍðÿÏðÿÛùÿÝúÿäýÿçüýéþÿéþÿçÿÿáýÿßûþÛøþÛøþÛøüáúþâûÿæûþèýþìÿþíÿþíÿþñÿÿóÿÿõÿÿ÷ÿÿûÿþûÿþûÿüûÿýøÿþôÿûîþýÓôÿÆëþªÜÿ ×ÿ“ÏÿÍÿ‘ÏÿŒËÿ‹ÊÿŒÎÿÎÿ’Îÿ–Ðÿ—Ñÿ™ÒÿžÔÿ£×ÿ¦ÚÿªÜý¬Þÿ¸áýÂæþÇìÿÐôÿÒôÿÏóÿÌñÿÃìÿ»æÿ·ãÿ²ãÿ²ãÿ·äÿ¸äý·åü¶æý¬âþªßþ«àÿ´åÿ¹çÿÁçþÄêÿËîÿÑñþÓñü×ôüÙöþÚ÷ýÚ÷ýÛøþØöþÔõþÓóþÖôÿÚõþáøþëÿÿêÿÿßüÿÓõþÕöÿÒòÿÒóÿÍòÿÉíÿÅéÿÆêÿÌïÿÑòÿÒòÿÏóÿÎòÿÓôÿÒóÿÔñÿÕñýÖòþÚõÿÛöÿÞöÿÞöÿÜ÷ÿÜøÿÙöÿÒñÿÌðÿ±âÿ¨Úý˜Ñü”Îü“Ñÿ˜ÒÿšÑú°Ýþ¼åÿÉìÿÏðÿÛ÷ÿÜùÿåþÿêÿÿéþÿçÿÿåþÿßüÿÝúþÚ÷ÿÙöþÙöüÜøüßøýâúþæûþëÿþìþþìÿýðÿÿñÿÿôÿÿõÿÿùÿÿùÿýùÿûøÿþöÿýðÿüìþþ×øÿÉïÿ©ÛþÔýÌþÍÿ‘ÏÿŠÉþ‡ÉýŠÌÿŽÎþ’Îÿ”Îþ•Ïÿ™ÒÿŸÕÿ£×ÿ¦Úÿ¨ÚýªÜý¶âý¾æÿÂëÿÊðÿÊïÿÈíÿÅëþ½çÿµâÿ³áÿ±áÿ²ãÿ¸äÿºäý¸åü¶åÿ¬ãÿ¨Þÿ©àÿ²ãÿ¸åÿ¾æÿÁêÿÊïÿÏðÿÐðýÔòü×óþ×ôü×õýØöþÖôüÒôþÒòÿÓóÿ×óþßøÿéÿÿæÿÿ×øÿËïûÎðüÎïþÍñÿÈîÿÄêÿÀèÿÃéÿÈìÿÏðÿÐðýÍñÿËðÿÏóÿÑòÿÐðÿÑóýÑóýÕõÿÙ÷ÿÛ÷ÿÜ÷ÿÝøÿÞùÿÝúÿ×ôüÑóÿ·ãþ¬ÛùšÏ÷•Ðü”ÒÿšÔÿŸÕÿµâÿÀéÿÌïÿÒóÿÛ÷ÿÚöÿàùÿãûÿåýÿâûÿÞùÿÙ÷ÿØöÿÕóþÖôÿ×õÿÙöþÛöÿÞ÷üáùýéþÿëþÿìþÿíÿÿîÿÿðÿÿñÿÿôþýõþýôÿûòÿÿñÿÿëÿþçÿÿÏóÿÂèý§×ûŸÔþ–ÐÿÌÿŽÊþŠÇý†Èü‡ÉýŽÌû–Ðþ–Ðþ–ÐþžÔÿ Õÿ£×ÿ¥Ùþ¥Úú©Üû°âýµãý¹åÿ¿èÿ¾èÿºãÿ·ãÿ²ßþ©Ûü©Ûþ¬Üÿ°Ýÿ¸áÿºáþ¹âþµäÿ¨àÿ Úÿ¡Ùþ­Ûý°Ýü·ãÿ»äÿÂêÿÊïÿÌïÿÏïþÐðÿÐðýÑñþÓóÿÕõÿÓôÿÓôÿÓôÿØôÿÛöÿáüÿÜøÿÉïüÁçúÂåùÈíÿÇíÿ½çýºæÿ¹åÿºãÿ¿èþÌðþÏñûÍñÿËïÿÏðÿÐñÿÏîÿÑöþÒ÷ÿÔöÿÕõÿØôÿØôÿÜ÷ÿÞùÿßûÿÚøúÕöý¾èÿ°Ýú™Îö•Îù’Ðÿ—Ôÿ Öÿ´áÿ½æÿÉìÿÏðÿÙõÿØôÿÞ÷þà÷ýáøþÞ÷þÚõüÕóýÔòüÐðýÕòÿ×õÿÛøÿÜ÷ÿÝöûàùýçÿÿêÿÿëÿÿìÿÿìÿÿðÿÿñÿÿôþýôþýòþüñÿÿîÿÿêÿÿæÿÿÌðÿ½ãø¦Öú Õÿ™ÓÿËÿ‹ÇûŒÉÿŠÌÿ‰ËÿÎú™Òÿ™Òÿ˜ÑþžÔÿ Õÿ£×ÿ¥Ùþ§Ùú©Üû©Ü÷­ßú²áýºæÿºåÿ´ßÿ²ßÿ­Ûý¢×ù£Øú¦×ÿ«ØÿµÞþ·Þý·àÿ³áÿ¤Ûÿ›ÔÿœÓü§ÕùªÖù²ßþµáþ¼äþÆêÿËîÿÎïÿÏðÿÎïþÎïþÑòÿÒôÿÑòÿÏòÿÑòÿÖñÿÙóÿÞøÿÕóþÂéø½æú¾âøÂæüÂèÿ½çýºæÿµâÿµáþ¼åûËïýÏñûÎðüËìûÍíüÐðÿÓðÿÌíþÏðÿÒóÿÐñÿÊíÿÊîþÐñÿÕõÿÛùÿÚ÷ÿÙ÷ÿÅëÿ³ßøžÓõ˜ÒøÒý”Ôÿ—Öÿ©Þþ±âÿ¾èÿÂëÿÎñÿÕöÿÛùÿÛöýÝõÿÓïúÑïúËïýÉîþÍðÿÐñÿÒóÿÙõÿÜ÷ÿÝöýâùÿëÿÿëþÿìÿÿìÿÿìÿÿíÿÿíÿÿïÿÿðþþïýýñÿÿòÿÿïýýéýþÐñÿ¿åú¥×ú¡Øÿ–ÔÿËþŠÈûˆÇúŠÉþŽÐÿ’Ðÿ–Óÿ—Ôÿ˜Õÿœ×ÿ›Õû¤Úþ¨Ýÿ­Þÿ¬Ýþ§Ûÿ¥Ùÿ¥ÙÿªÜÿªÜÿªÚþ¨Úÿ¢ÖýÒúšÏù™Òý™Òý¢Öý©Ûÿ§Ûÿ¤Ùÿ˜Õÿ”Ñÿ–ÐþŸÔÿ¢Õÿ¦×ÿ¨Øü±Þý¿éÿÂëÿÌñÿÍñÿÎïþÎðüÏðÿÎïÿÌïÿÌðÿÎïÿÐíûÖôÿÐðÿÈëÿ´áþ­Þÿ¯Üû·ãÿ¸äÿµãý¶ãÿ°Ýú°Þø·ãüºçþ½çýÄçûÇçüÎïÿÎïÿÎïÿÂäýÁåýÁçþÂçÿ¾æÿ½åþºãùÁçüÐóÿÑòÿÌïÿ¾çÿ±Þý¡ÕúŸÖý™×ÿ—ÕþšÕý¥Úü¬ÝýµâÿÀêÿÅëÿÈíÿÒòÿÙõÿÓïûÏìúËìûÅêýÁçüÄéüÎïÿÓóÿÚöÿÚõþáøþæûÿìÿÿìþÿíÿÿìÿÿìÿÿíÿÿíÿÿïÿÿïÿÿðÿÿòÿÿóÿÿñÿÿíÿÿÝûÿÌñÿ¦×ø›Òù’ÐÿÎÿŽÌÿŠÉþŠÉþ‰ËÿÌÿÎÿÎýÏú•Ðø›Õû£Ùý§Üþ®Þÿ°Þÿ§Ûÿ ÕÿŸÔü£×ü¥Ùþ«ßÿªÞÿ£ØÿœÒþšÐþ“Ðý’Ïû˜ÒúžÓûŸÖÿœÕÿš×ÿ–Óÿ™ÒÿœÑûžÒú§×ÿªÚÿ³àÿÀèÿÂèÿÇìþÊíÿÌðÿËïÿÇêýÈëÿÉìÿÊïÿÌïÿÏñýÑñþÌíÿÄèÿ®Üþ£Ùÿ¦Øû­Ûý®ßÿ³áÿ²àÿ±àþ¯Þü±àü²áýµäÿ½æÿ»åþ¾èÿ¾èÿ»åþºßú·ßù¸áý»äÿ¹åÿ¸äÿ°ÜõµßøÃìÿÇíÿÄéÿ¶ãÿ®Üþ¢Öý Õý×ÿžØÿ£ØÿªÜÿ­Þÿ²ßü¹åþ¿èþÅëÿÐñÿØôÿÖòÿÎîýÊëüÂèý¾çýÅèûÏïüÖôÿÜ÷ÿÞ÷þåúÿèûÿíÿÿìþÿìþÿìþþëÿþìþþìþþîþþîþþðÿÿòÿÿóÿÿòÿÿîÿÿÝùÿÍðÿ©ÚúŸÕû“Ðÿ‘ÏÿÎÿŒËÿ‰ËÿˆÊþÌÿÎÿÎý‘Ðü—Òü›Õý£Ùÿ©Ûÿ°Þÿ±Ýÿ©Ýÿ ÕýŸÓú£×ü¥Úü¦Úÿ¦Úÿ ×þ›Ôÿ›Ôÿ‘ÎûÍú’Ìô—Ìô˜Ïö—Î÷›ÖÿšÕÿÓÿŸÓú¡Òú«Ùý¯ÛÿµáþÂçÿÁçþÆëþÈëÿÊíÿÊíÿÅéÿÅèþÅéÿÈìÿÉîÿÎïþÏðÿÉìÿÁçþªÛü Õý¡Õú¦Øû©Ûþ¯ßÿ­Þÿ¯àÿ­Þþ¯àÿ¯àÿ²àÿ¶åÿ³âÿ´ãÿ¶åÿ±àþ¬Úü¬Úü¬Üÿ­Ýÿ«ÝÿªÜÿ¤Öù£Õø¨Ùú¬Ýþ¬Üÿ£Öÿ¢Õÿ¥Öÿ¦×ÿªÚþ²àÿµáÿ·äÿ´áÿ¯Üû­Ùö»ãýÄêÿÍðÿÐðÿ×ôÿÌíÿÄçû¾äû¿çÿÏïü×ôüÜ÷þåýÿéþÿìþÿìþÿïÿÿïÿÿîþþìþþìþþìþþìþþîþþîþþïÿÿðÿÿïÿÿðÿÿïÿÿåýÿÔôÿµâÿ©Ýÿ‘ÎûÍþÍÿ‹Íÿ‹Íÿ‰Ëÿ‹ÊýÍþ‘Ïþ”Óÿœ×ÿ Öÿ¥Ùÿ©Úÿ¯Üÿ±ÝÿªÚÿ¥×ü¤Öù¨Úû©Ûþ¨Úý¦ÚÿžÕü˜Ñü™ÔÿžÛÿÚÿŸÖÿ Öü¡Õú¡×ýŸÖý£Ûþ§Üþ²áÿµáþ¼ãÿ¿äÿÁåÿÇëÿÇêÿÉìÿÅéÿÆêÿÆìÿÁéÿÀåÿ¾æÿ¾èÿÀéÿÅëþÉîÿÃéÿºäý£×ü™ÒýšÑú›ÒûÔý¢×ÿ¢×ÿ¢Øþ¢Öý¨Üÿ¥Ùþ¥×ü£ÛÿžØýŸÙÿŸÙÿœÖü Ò÷£Õú¦Úÿ§Ûÿ¦Ûÿ¦Ûÿ ÕýŸÔüŸÕû¡×ý¢×ÿÓÿŸÕÿ¨Ùÿ¬Üÿ´áÿ½æÿ¾çÿ»çÿ¸äÿ´àý¬Øó¹áûÂèÿÊíÿÍîÿÐïÿÊëþÄçûÀæýÁéÿÐðûÛ÷ûâûÿêÿÿëÿÿîÿÿïÿÿðþÿðþÿïýþìÿýìÿýìþþìþþìþþìþþìþÿíÿÿìþÿíÿÿîÿÿæýÿØõÿ¶ãÿ¨Ýÿ‘ÎûÍþŽÍÿ‹ÍÿŠËÿˆËÿ‹ÊýÍü‘Ïþ“Òþœ×ÿ¡×ÿ¦ÚÿªÛÿ°Üÿ±Ûÿ­ÛÿªÛü«Üý®ßÿ®ßÿ¬Þÿªßÿ ×þ˜Ñü™Ôÿ—Ôÿ—ÔÿœÓúžÒ÷ ÒõŸÔö¤Úþ©Þþ°áÿ»çÿ¿éÿÈêÿÇéÿÇêþÌïÿÌïÿÊíÿÇìÿÇíÿÄìÿ½çÿ½åÿ»åþ¹åþºæÿ¿èþÅëÿ¾æÿ¶âÿ¡Õü–Ñý•Îû–Ïü–ÏüšÐüÓÿŸÖÿŸÔþ£Øÿ Öü Ôû×ýšÖû›Öþ™Ôü–ÑùŸÔþŸÔþ ×ÿ¡ØÿŸÕÿÓÿšÓÿ™Òÿ—Ñÿ‘Îý’Ïþš×ÿ¡Ûÿ«Ýÿ´áÿÀæýÆëþÆëþÀæû¼åùºäü¾èÿÀéÿÅëÿÌïÿÍîÿÎíÿÍîÿÊíÿÈìÿÊîÿÖôüáúþåÿÿëÿÿìþþïÿþïÿþðþÿïýþîýÿìþþëÿþêþýëÿÿëÿÿêÿÿëÿÿëÿÿèýÿèüÿëÿÿàùÿ×ôÿ¹æÿ¦Úÿ‘ÎûÍÿŽÍÿ‰Êÿ†Éþ‰ÌÿŒÎÿÎý—Õÿ™×ÿ›Ôÿ¢ØÿªÛÿ­Ýÿ®Úý³Þÿµàÿ·ãÿ¹åÿºæÿºæÿ´áþ³âÿ®àÿ£ÙÿÔû™ÓûŸÖý­ßÿ³áÿ±àü°ßû²ãÿ¶åÿ»èÿÊðÿÎóÿÔôÿÖôÿ×õÿÔôÿÒôþÊðýËðÿÄîÿ½êÿ´âü´àý±àþ®ßý®ßý±Þû¸äÿ³àý¯ÝþžÕþ’ÏüËý‘Íÿ‘ÍÿÌû‘Îý›ÕÿœÕÿœÕÿÔýŸÕÿœ×ÿœ×ÿšÕý™ÔüšÕý Õý Õý¢Ùÿ¤Ùÿ¡Øÿ Öÿ™Òÿ—Òþ•ÒÿÎÿ’Ðÿ™ÖÿžÙÿ©Ûü³àýÃéþÇëûÈìüÅêüÃêûÂëÿÁêÿÆêÿÉîÿÑòÿÐðÿÑñÿÐïÿÎïÿËîÿÌïÿÛøÿãüÿæÿÿêÿÿêþÿðÿÿðÿÿðÿÿñÿÿðÿÿìÿÿìÿÿìÿÿíÿÿëÿÿèÿÿæýÿãüÿáúÿáùÿãüÿÜõüÓóÿ»èÿ©Ýÿ”ÑÿÍÿŽÍÿ‡Èþ…Èý†ÉþŒÎÿÎý–Ôÿ˜Öÿ›ÔÿžÔÿ¨Ùÿ¯Ýÿ±Üü¶ßÿ»äÿ¾æÿ¿çÿ¿çÿ¾èÿºæÿ¹çÿ³äÿ«Ýÿ¦Úÿ¢Øü¦Ûý¶åÿºçÿ»çÿ¹åþ¸æÿ¹çþ¿êýÌñÿÒôÿÙ÷ÿØöþÙ÷ÿÖ÷þÓõþÏõÿÍôÿÃíÿ»éÿ²áû±Þý®ßÿ¬Þÿ­ßÿ°ßý´ãÿ°ßý«ÜýÔý‘ÏþŽÌÿÎÿÍÿÍþ‘Íÿ–Ðÿ–Ðþ—Ðý—ÐûšÐüœÖþœÖþ›Õý™ÓûœÓü©Ûþ©Ûþ¬Þÿ­ßÿªÞÿ©ÝÿžÕþšÓþ•ÒÿÎÿ‘Ïÿ˜ÓýœÖþ§Ùú³âÿÆïÿÎóÿÐôÿÌòÿËñþÌñÿÌðÿÑñÿÔôÿÙöÿÚöÿÛ÷ÿÙõÿ×õÿÖôÿØõÿØôÿÞùÿáýÿçÿÿéþÿìÿÿìÿÿìÿÿíÿÿìÿÿêÿÿêÿÿéÿÿêÿÿäýÿàûÿ×ôüÑïúÔòýÖóÿÕóþÓïûÊíÿµæÿ¤Üÿ’ÐÿŠÉüŠÉþ‡Êÿ‡Êÿ‰ÌÿŒÎÿÎÿ”Òÿ–ÓÿšÓÿÔý§Ùü°ßý¸âû½åþÃéÿÄèþÆéýÆéüÆéüÆëþÅêý½æüµáü´àû¶äþºæÿÄíÿÉîÿÉîÿÇíÿÅîÿÅîÿÊïÿÔôÿØöÿÚ÷ýÚ÷ýØ÷üÓôûÐòûÊñÿÃìþµáú®Ý÷¦×÷¥Ö÷£×ü¢Úÿ£Ûÿ¦Ûý¨Úû§Ùü£×ü™ÒÿÎÿ‹Íÿ‹Íÿ‹ÍÿŽÍÿÎÿ”Ñÿ•Òÿ™ÔÿšÓþœÕÿÔýÔûŸÔüžÓû£×þ®ßÿ®ßÿ°áÿ±âÿ¯àÿ®Þÿ¤Øÿ Õý—ÒþÍü‘Îý™ÒýŸÖÿ©Ûþ³áÿÁëÿËñÿÍòÿËðÿÊïÿÌðþÐòþÖôÿØöÿÛ÷ÿÝøÿÜ÷ÿÜ÷ÿÚ÷ÿÙöþÛ÷ÿØôÿÛøÿßúÿäýÿæþÿêÿÿêÿÿêÿÿëÿÿêÿÿéÿÿèÿÿèÿÿèÿÿàûÿÝúÿÑïúËëøÏïüÓôÿÓõÿÌìùÄéü­ßÿ×ýÏÿˆÊþ‡Éý‡Êÿ‰Ìÿ‹ÎÿŒÎÿÐÿ“Ñÿ•ÒÿšÓþžÕü¨Ùú¯Þúºäú¿èüÈëÿÈëþËìýÍîÿÎïþÏðÿÍîÿÅêý¿åü¾ãý¼çúÀéûÉîþÎïþÏðÿÍñÿÊðÿÊïÿÌïÿÖóÿ×õÿØöþØöþ×õýÑñüÎðüÆíþÀéÿ²ßü­Üú§Øù¤Öù Öü×ýŸÙÿ£Ûÿ¢Øü¢Öû Öü—ÑÿÎÿ‹ÍÿŠÍÿŠÍÿŒÎÿÏÿ‘Ïþ“Òþ–Óÿ™ÔþœÖþÔýŸÔþ¡Öÿ£×ÿªÛÿ¶âý¶âý¹åÿºæÿ¸äÿµâÿ«Üý¤Øý›Òû“Îú”ÎüœÒÿ¡Õÿ¥ÖÿªÚÿ²ßÿ¼åÿÂçÿÉíÿËðÿÓôÿÕóýÜ÷þÞùÿàùþãûÿáøþäûÿâûÿßøýßöü×õÿ×õÿ×õÿÛöýÞ÷üÞ÷ûßùúâüýåýÿçÿÿæÿÿåþÿàüÿßúÿÚ÷ÿ×õÿÌìùÄèøÇëûÏôÿÒõÿÎïÿÄíÿ«áÿœ×ÿ‹Íÿ‡Êÿ†Çý†ÉþˆËÿ‰ÌÿŒÎÿÐÿ‘Îý’Ïü›Ñý Öü­Þü¹çÿÆñÿÊñÿÏðÿÐïÿÒïÿÔòýÖòý×óþÖôþÔñÿÏïþÍîÿÌðþÍòû×õýÚ÷ÿÜùÿÛùÿÎòÿÌðÿÍîÿÒïýÓïûÔñÿÒòÿÒòÿÍîÿÈëÿ¼äý¹âþ°Üÿ­Úÿ¨Ùÿ§ÛÿÔû–Ñû–ÔûŸÙÿŸ×ü ÕýžÕþ•ÒÿÏÿŒÍÿˆËÿ‰ÌÿÏÿŽÎþÎý’Ñý—ÕþšÕýœÖþžÔÿŸÕÿ£Øÿ¤ÙÿªÞÿ´áø¶ãú½çÿ¾æÿ¾æÿ½çÿµãý¬Ýý›Òû‘Ïÿ‘Íÿ™Òÿ›ÓÿšÓÿ›Ôÿ¢Ùÿ¨Úû¯ÞúºäúÃìþÍïû×ôúÝöúßøüäüþçùùëþüæøøåúýÞúÿÕõÿÅëþÆïÿÈñÿÈñÿÉïÿÊïÿËïÿÒòýØöÿÛøÿÕ÷ÿÒ÷ÿÍôÿÊñÿÈîÿÈîÿÅëÿÆéÿÇêþÏðÿÕòÿãüÿáýÿÆïÿµãý—ÏôÎúŽÌûŒËþÌÿŽÍÿÏÿÎÿ”Ñÿ•ÐüŸÕû­Þÿ¿çÿÌïÿÝùÿáúÿæýÿæþÿæþÿèýÿèýÿçüÿæûÿâùÿàùÿÞùÿÞúþâþÿÝùýÚõü×÷ÿÔöÿËðÿÁêÿ¼æþ½çÿÀêÿÉïÿÉïÿÉíÿÂæÿ¾äû¾äù¼åû»åþ¸äÿ±ßÿ¬ÞÿœÔù’ÍùŽËø—Öÿ˜×ÿ™×ÿ—Õþ“Îú‘Ëû’ÐÿÎÿÌÿŒËþÌÿÍþÍü•Ðü™ÒýœÒþœÑûžÓý¡Õü£×þ®Þÿµâù·äû½çÿ¾æÿ¾æÿ¾èÿ¸æþ°âýŸÖý’Ðÿ‘Ïÿ•Îû—Ïþ—Ñÿ–ÓÿžØÿ¢Øú§Ú÷²ßö¾çùÍïûØõûÞ÷üáúþäüþçúøîþûèúúæûÿÚúÿÏòÿ»åý¼èÿ¼êÿ½éÿ¼èÿ¿éÿÁêþËïÿÒôÿÖôÿÍòÿÉòÿÃîÿÀêÿÀêÿÂëÿÄêÿÆéÿÊêÿÑðÿÖòÿæûþæÿÿÔøÿÅîÿ¥Ø÷–Ñù’ÏûŽÌýŽÌÿÎÿÏÿÎÿ”Ñþ–Ñý¡×ý®ßÿÃéÿÏðÿâúÿèûÿéþÿéÿýéÿýêþýêþýìÿÿìÿÿéþÿæþÿæýÿäüþçÿÿâûÿÝøÿÖöÿÒóÿÉîÿ½çÿ·ãþµâÿ¶äþ½çÿ½çÿÁèÿ¿çÿ½åþ»äø»äø¼æþ¹åþ´áÿ­àÿœÔù“ÍûËü’Òÿ–Öÿ™Øÿ˜×ÿ—Òþ•Ïÿ‘ÏÿÎÿÌÿŒËþŽÍÿŽÌÿÍþ”Îü—ÐýšÐüÒüžÓûŸÓú¤Öû¬Ýþµäÿ·äÿºæÿ¼åÿ¾æÿ¿çÿ¸æýµåü¦Üþ—Òþ”Îü–Ìú–Ïü˜ÑþšÓþžÕþ¦Ûý°áÿ¼éÿÃìÿÌðÿ×õÿÝúÿßüÿßûÿáùûéýþåúÿàøÿËîÿ¿äþ¦Õñ§ØöªÛù¯Þü±àü³ßø¹ãûÈîÿÍðÿÍîýÄçúÂçú¼âõ»áôÂçúÅêýÇêýÍîýÑñÿÙõÿÜôþçüýèÿÿãÿÿÙúÿµáú©Þÿ¡Øÿ’ÏþÎÿÎÿÎÿÎý”Ñþ˜Óÿ¥Ûÿ«Üý¾æÿÇêþÖòþàøÿêÿÿëÿÿìÿÿíÿÿíÿÿìþþìþþêþÿéþÿéþÿêÿÿèýþáùýßøýÕóýÐðûÅéù¾äû¼äýºäý·ãü³áû±Þû³Þþ¶áÿ¶âý·äû·äû·åÿµäÿ®àÿ«àÿšÔü’ÎÿŽÍÿ†Èü‡ÉûÐý‘Ñÿ“Ðÿ“ÏÿŽÍÿ‹ÍÿŠÌÿ‰ËÿŒÎÿŽÍÿŽÍÿ‘Îý•Îû—ÍûŸÕÿ ×ÿŸÔü¢Öý­Ýÿ²ãÿ³äÿ·äÿ¸ãÿ¾æÿ¿çÿ»èý¹çþ­âÿ¡ØÿœÕÿšÐþ›ÑÿÓÿÓÿÔû¨Ýÿ±âÿ¿éÿÂëÿÍñÿÖöÿÝûÿÞüÿÜúÿßûÿåýÿàùÿÚöÿÃéþ¶ßû£Ôõ£Õø¥×ú©ÚûªÛû²ßü¸äýÉïÿÌñÿÉìÿÄåöÁä÷¿äöÀå÷ÉìÿÌðÿÎïþÔòýÙõÿÞùÿàùþéþÿçÿÿäÿÿÞüÿÁçü²ãÿ¨Üÿ“ÐýÏÿÏÿ‘Ïÿ‘Îý˜Òÿ™Ôþ¦Üÿ¬Þÿ½çÿÅéÿÒïýÚöÿæþÿêÿÿìÿÿíÿÿîÿÿðÿÿîÿÿîÿÿìÿÿìÿÿìÿÿçüýß÷ùßöüØõýÖôþÊëúÃèûÃéþ¾æÿ¼æÿ´ãý±àü°Ýþ³àÿ´áþ´âú´âú²áý®ßÿ¥Ùþ¦Üÿ™Òý‘ÏÿÎÿ†ÇýƒÆúŠÎýŽÐÿ‘Ïÿ‘ÎÿŠËÿ‰Ìÿ‡ÊÿˆËÿŠÍÿÏÿÎÿ’Ïþ•Ðü–ÏüÓÿŸÖÿ Õý£×ÿ®àÿ«àÿ«àÿ±ßÿ³àÿ¼äþ¿èþ½èù½èùµäþªÜý¥Ùþ¢×ÿ¡Öÿ£Øÿ¢×ÿ Ôû©Úû®Ûú´Þ÷·àöËîÿÑòÿÔõÿÑõÿÐôÿÙûÿÙùÿÐñÿÈëþ³àýªÛüŸÖÿÔýÔýŸÕû¢Öû­Ûü´áÿÆîÿÉïÿÆêÿÈéúËëúÑñÿÓóÿÙ÷ÿÛùÿßüÿàùþäýÿéÿÿèÿÿèÿÿèÿÿçÿÿåþÿÒòÿÀêÿ¯àÿ•ÐúŽÎüÏÿÎý–ÐþœÕÿœÕÿ¥Ùÿ«ÝÿµáþºäüÇêþÍîÿÜ÷þäüþèýþìÿÿíÿÿíýüîþýïÿþïÿÿîþþðÿÿìÿýëÿÿçüÿÞ÷þÞùÿÚøÿÓôÿÍðÿÇìÿÅëÿ¸æý¶âû¶âÿ½æÿ¼èÿ·åü¸æý¶åÿ¯àÿ¢ÖûžÕü˜ÒÿÊÿŽÍÿ‰Êÿ…ÈýˆËÿˆËÿ‡ÈþˆÉÿ…ÈÿƒÈÿ‚Çþ„Éÿ‰ÌÿÏÿÏÿ‘Ïÿ”Ñþ–Ðþ™ÒÿœÕÿ¡Öÿ¤Øÿ¬Ýÿ¨ÞÿªÞÿ°Þÿ²ßÿ¼äþ¾çûÁëûÁëûºçþ®ßý«Ûÿ¥Ùÿ¤×ÿ§Ûÿ¦Úÿ¤Öû­Ûü³ßüºâü»áøÉîÿËïÿÍñÿÊïÿÉðÿÓøÿÒöÿÈíÿÀæý«Üü¤ØýšÕÿ™ÔÿšÓþ¡Øÿ¤ÚÿªÛü³àÿÅïÿÉîÿÇëÿÍîÿÑñÿ×÷ÿÛøÿÞúÿßüÿãþÿâûÿæþÿêÿÿéÿÿæÿÿçÿÿåüÿáúÿÎîûÁëÿ²áÿ•ÐúŽÎüŒÐÿ‘Îý—ÑÿÖÿžÕþ¤Øÿ¬Þÿ´áþ»åþÉíÿÌïÿÙöþáúþåýÿëÿÿíÿÿîþýîþýñÿÿðÿÿðþÿîþýîþýðÿÿëÿÿÝôúÞ÷þÝùÿØøÿÓôÿÏðÿÍòÿ¾éü»åý¼ãÿÁéÿÁëÿ½êÿ¿ìÿ½ëÿ·æÿ¨ÚÿÔû™ÓÿŒÉÿŒËÿ‰Êÿ‹ÌÿŒÏÿ‹ÎÿˆËÿ‰Êÿ„Çþ‚ÇþÆýƒÈÿˆËÿŒÎÿÏÿÐÿ“Ðÿ–Ðþ›Ôÿž×ÿ£Øÿ¦Úÿ¬Ýÿ¡Öö¤Ùù°ÞÿµàÿÃéÿÇìþÑõÿÓ÷ÿÅïÿ»åþµàÿ§Ùþ¥×ü§Ùþ­Ýÿ·åÿ·ãÿ»äÿÁçþ¿åüÄéüÉìÿÅëþ¾çû¿éÿÁëÿ¿éÿ´àù°Ýú£ÙÿšÓþ‘ÏÿÎÿ”Ñþ ×ÿªÞÿ¶äÿ¶ãÿÁéÿÆìÿÇëÿÒòÿÙöÿÚøÿÛ÷ÿãþÿãÿÿáúþæþÿëÿÿåúûãûýÚ÷ýÚ÷ÿÕñüÐîùÄçú½éÿ²ãÿ‘Ìø‡Çõ‹ÍÿÍü—ÐýŸÖÿ Õý¨Úÿ¯àÿ¼èÿ»åþÅëÿËïÿÓóÿÛøÿÜ÷þæþÿëþÿðÿÿïÿþïýýòþþóÿÿïýýïÿþðÿÿíÿÿäùþßöüÛöÿÚöÿØöÿÓóÿÒóÿÌñÿÊïÿÅéÿÊîÿÉîÿÊðÿÉïÿÁëÿ¹åÿ«Ùû¡×ý—Ðý“Íÿ’ÎÿÏÿ‘ÐÿÏÿŒÐÿ…Èÿ†ÈÿƒÆý…Êÿ‚Çþ‚Çþ…Èý‰Ëÿ‹Íÿ‘Ïÿ’Ïü•ÏýšÐüšÑú Õý¤Øÿ§Ùþ°âý±ãþ·ãþ¼äþÊëþÎîûÖ÷ÿÖ÷ÿÏóÿÇëÿÀçÿ­Þþ«Üü³áÿ¸åÿ¸äÿ¿éÿÁéÿÃéþÃéþÆëþÉìÿÁçþ»åýµãû²áû²àúªÛû¥ÚüšÕÿ”ÑÿŽÍÿŽÌý”Ñÿ¤Ùÿ­ßÿ»çÿ¾èÿÄêÿÆëþÈëþÐòþÔôÿÚøÿÙ÷ÿÝùýàùþàøüäüþåýÿáùýÝøÿÑòÿÌíþ¿ä÷»áø³àý¬áÿ£Úÿ‘ÎûÍýŽÎþ”Ñÿ˜Ñþ¡Öÿ£×þ®Þÿ³áÿ¾çÿ¿çÿÇíÿÊîÿÎòÿÕõÿÕóýÛöýäüÿìþÿîþþðþþóÿÿôÿÿõÿÿóÿÿíÿÿêüþáöûÝõùÝöýÜ÷ÿÜøÿÙ÷ÿÖöÿÍñýÌðþËîÿËîÿÉîÿÅìýÃêûºäü´àû¬Úû¦Øû ÕýœÒÿšÒÿ™Óÿ—Ôÿ’ÑýÏý„Æú…ÆþŠËÿˆËÿ†Éþ…Èý‡ÊÿÏÿÎÿÍü”Ïû™ÒÿÒúžÔú¥Ùþ«Ýÿ±âÿ¹éÿ¹çÿ»åý¿åüÎíÿÔòýØöþ×õýÒóÿÊìÿÆëÿ²áÿ®Ýû³àý¶âý·áùÂëÿÆìÿÆêÿÆëþÇìÿÉìÿÁçþ¼æþµäþ¯áü¬Û÷¥×øŸÕù“ÐýÍþÎÿÍþ•ÏýŸÓú§×û»äÿÀèÿÉîÿÊîþÊëúÎðüÐòüÖ÷ÿ×õýÚöúÜøüàùýäýÿáúþßøýÛøÿËðÿÅéÿµßø°ÜùªÜÿ¥Üÿœ×ÿÎýÍþÏÿ”Ñÿ˜Ñþ Õÿ¢Öý­Þÿ³àÿ½çÿÀèÿÈìÿËîÿËïÿÒóÿÑñþÙôýâùÿêüÿíüÿñÿÿóÿÿôÿÿõÿÿòÿÿìþÿéûÿâ÷üß÷ûáúÿÞùÿÜøÿ×õÿÓóþÊðûÈîûËðÿÌðÿÍòÿÅëþÁêü¶âû±Þû«Ùû¨Úû§Ûÿ¥Øÿ¡ÖÿÓÿ×ÿ–Ñû‘ÎúˆÈøŠËÿŒÎÿ‹ÍÿŠÌÿˆÊþŠÌÿÏÿÏÿÍü–ÏüœÒÿ Öü£×üªÜÿ®ßÿ¶äÿ¼éü½êýÄêýÉìÿØõÿÝùÿÚ÷ûÙöüÏïþÅçÿÆëÿºéÿµãý°Üõ³à÷¼åûÄêýÊïÿÊïÿËðÿÆëýÈëÿÁçþÀêÿºéÿ³äÿ°áÿ§ÙüŸÕû‘ÏþÏÿŽÍÿ•Òÿ˜ÓÿœÎó¥Óô¼äýÇíÿÕöÿÔöÿÓóþÏôýÎôýÔ÷ýÓôûÖó÷Ú÷ûãÿÿâþÿáüÿÛöÿÓðþÁéÿ¸áý¥Ö÷ŸÓú˜Õÿ“Óÿ‘ÑÿŠÉüŠÉüŽÌûÍü—Ðý¡Öþ¤Øý±àþ¹åÿ¿çÿÅëÿÉìÿÊêÿÄëüËðÿÍñÿÙ÷ÿÞùÿåøþéûýðþÿñýýóÿÿóÿÿðÿÿëýÿêýÿêÿÿéÿÿâûÿÜ÷ÿÛ÷ÿÔòüÎîùÄîúÅìýÉïÿÂêÿÁëÿ¼éþºèÿ°ßû©Úú¥×ú«Üü°áÿ®ÞÿªÛÿ¥Ùÿ¢ØþœÖûšÖû‘Îû‘Ïÿ‘ÐÿÎÿÏÿ‰Èû‰ÈûÍÿÎÿ“Íû™Òÿ Öÿ§ÛÿªÜý¬Ýý¯Ýþµâÿ¿éùÃêûÊîüÏðÿÙõÿÜùÿÚ÷ÿØôÿËêüÀâûÂçÿ¾ìÿ¼èÿ·äû¹ãù¾çûÄêýÉïÿËðÿËñÿÆëþÆêÿ¾çýÁëÿ¼ëÿ·æÿ°áÿ¦ØûÓùÍúŽÎþŒËþ—ÔÿœÕÿŸÑô¨×õÀæýËîÿØøÿÙ÷ÿÚ÷ÿÖ÷þÓöüÕöýÓôûÕòøÚ÷ýàüÿÞúþâýÿÜøÿÏïþ¼åÿ³àÿ¢ÖûžÕþ™ØÿŽÐÿÏÿˆÇú‡ÆùËþÍü˜Ñþ¥ÚÿªÜÿ¶ãÿ¾çÿÃèÿÈìÿÉìÿÉêýÃéüÊïÿÍñÿÛùÿÞùÿãøûçûüïÿÿîþþðÿÿóÿÿñÿÿëýÿêüþêýÿêÿÿÞ÷þØôÿØôÿÒðûËíùÃíýÁêþÄîÿ¸äý¶âûµâùµãû¬Ýû§Ùú¤Øý«Üü±ßÿ­Ýÿ«Ûÿ«Ûÿ¯ßÿ«àÿªÞÿœÒþ–Ðÿ“ÑÿÐÿÏÿˆÇú„ÆúÌÿÍþ”ÎüšÓþ¡×ÿªÞÿ¬Þÿ­Þþ¯Þü¶âýÎêöÏëöÖó÷ÚöúÜ÷þÚ÷ÿÔóÿÍíÿÂçÿ½çÿ»èÿÂìÿÂêÿ½æü½æüÂëÿÆìÿÆïÿÃëÿÆîÿ¾èÿ·ãü·ãü¸æþ¹çÿ¶ãÿ´âÿ©Ýÿ£Ùÿ•Ðú’Íù‘Ëû—Ïþ™Ðù­Ûü¹åÿÏòÿÕõÿãûÿäûÿâõûàøüÞ÷ûÔïøÑëøÑíùÔðüÛøþÛøþÜùÿÖòþËìý²ãÿ«ÛÿŸÔþ›Ôÿ”ÓþŽÏù‹ÎùŒÌüÌÿÍÿ’Îÿ™Òÿ¤ØÿªÜÿ·ãÿ¿æÿÈìÿÌïÿÎïÿÌíþÆìÿËïÿÐòþÛøþáúþãù÷äú÷çýûæÿÿäÿÿëÿþìÿýìþþìþþçûüäùüßøÿÙ÷ÿØõÿÍîÿÇìÿ¿éÿ½æÿ´áÿ²áÿ³àý¶âý¸äÿ©Úú£Øø¦Üÿ­Þÿ±ßÿ¯Ýþ³àÿ¶Ýú¾áýÌðÿÇìÿ²Ýý¤ØýžÕþ‘ÎûÍþ†Éý„ÇþŠÍÿ‹Îÿ‘Ïþ™ÓûŸÖýªàÿªßÿ±âÿ¶ãÿÀåÿÒðûÓñûÙøûÝúþÝúÿÜøÿÑðÿÅèþ¾æÿ»éÿ¹çÿÀêÿÁëÿ¿èþ¾çýÀæûÄêÿÅëÿ¿çÿÂêÿ»åþ±ßù±Þû²áý´ãÿ²àÿ°áÿ§Ûÿ¡Øÿ—Òü”Ïû’ÍùÔýŸÕû³àý¾èÿÎòÿÕõÿåþÿçþÿåøþäýÿàûÿÖòýÓïýÒïýÔòýÙ÷ÿÙ÷ÿÙ÷ÿÑîüÇèû°áÿ¨Øü›Ðü—Ðý‘ÐüŽÎúÍùŽÌûÍÿ‘Íÿ•ÏÿœÒþ§Øÿ­ÝÿºæÿÁéÿÊïÿÏòÿÐñÿÏïþÅêüÊîüÐòüÝúþäþÿåûùæüùéÿýåÿÿâþÿéÿÿêÿÿëÿÿìÿÿèýÿäüÿÝøÿ×õÿÔñÿÌíþÇìþ¼æÿ¹âþ²ßþ³àÿµáþºäý¼æÿ¯Þü¨Ûú©Þÿ¯Ýþ´ãÿ²ßþµâÿ½åþÄèþÐóÿÎòÿ¿éÿ­Þÿ¡Øÿ‘ÎûÎýˆËÿ„Çþ‡ÊÿˆËÿÎÿšÓþŸÖÿªàÿªßÿ´ãÿ¹åÿÄèÿÙ÷ÿÚøÿâÿÿäÿÿàÿÿÞüÿÊíÿ¿åü±Ýø³âü´ãý²Þù¸áýÀèÿÁêÿÁçüÆëþÃéþ½âüºßù¯Ûø©Úû¥×ü¥×ü§Ùþ¥ÙþŸÕû›ÕýšÕÿ™Öÿ™Öÿ©ßÿ´åÿ¶åÿ¾èþÄëüÌîøÒóúâþÿäÿÿåþÿÝûÿÙùÿÓóÿÑðÿÓòÿÓóÿ×øÿØùÿÖöÿÍìþÄçûªÜ÷¢ÔõšÏû™Ñÿ™Öÿ”Óÿ•Òþ—Òü—Òü›ÑýŸÔü¤Øý¯Ýþ´áþÁêÿËïÿÓôÿ×÷ÿÖôÿÓñüÌìùÍíøÓñûãüÿçÿÿêÿþêÿþçÿÿáúþÛ÷ûÛøÿÚ÷ÿÚ÷ÿÛöýÚõüÙôýÙõÿÔòýÏïüÌíüËïÿÀéÿºäý´àû·áú·áùÂèÿÅëÿºæÿ´áþ¯àÿ°ßû´ãýµãý¹æýÊïÿÒóÿØöÿÕõÿÏõÿ½êÿ­áÿ“ÎúŽÍùŒÎÿŠÍÿ„Çþ†ÉþÎÿ™Ôÿž×ÿ§Ýÿ©Ûüµâÿ½çÿÎîÿÙöþÚ÷ýâþÿåÿÿäÿÿáÿÿÍîÿÄèþ²Þ÷²âù´ãý±Ýú¶ßûÀèÿÅëÿÆëþÈíÿÆêÿ¾äûºßù®Ú÷©Ùÿ¡Õý Ôû ÔûŸÔüžÕü›ÖÿšÕÿ—Ôÿ—Öÿ­âÿºéÿ¼êÿÄíÿÊïÿÒôýÕöýÞûÿÞûÿÝúÿÕõÿÓóÿÐïÿÑðÿÒñÿÒòÿ×÷ÿØùÿÖöÿÎíÿÅêý¬Þ÷¤×öœÑýÓÿœÖÿšÔÿ›ÖÿžØþ ×þ¢Øþ¥Úü¬Ýý³àýºäýÄéüËîÿÔôÿÙ÷ÿÚøÿÙõÿÔòýÓïúÖóûäýÿèÿÿéÿýçÿÿæÿÿàüÿÞùÿ×õÿÔôÿÓóþÕóýÔòüÔðûÖòýÓñüÑñþÐñÿÐñÿÆìÿ¾æÿ¹ãü¹ãû¹âøÆëþÊíÿÁéÿ¸äý±àþ°ßû±àüµãý¹æýËðÿÖöÿÛøÿÚ÷ÿÖøÿÅðÿ³åÿ”ÏùÊ÷ŠÌÿ‹Ìÿ„Çþ†ÉþÍý–Óÿœ×ÿ¥Ûÿ§Ùú´áþ¾æÿÐðÿçÿÿçÿÿêÿþëÿþçÿýåÿÿ×õÿÏîÿÄêÿ¼éüºéý¹åÿ¹ãüÃéþÉîÿÐñÿÔõÿÔõÿÎñÿÇëÿ¼åÿ²âÿ¥Úÿ¢×ÿžÓý›ÒûŸÖÿ Úÿœ×ÿ—Òú›Ùÿ²áÿ¿çÿÀéÿÊîþÐñÿÕõÿÔôÿÎïþËìýÉìÿËïÿÊîþÍíÿÏïÿÐìÿÏìü×õÿØöÿ×ôÿÑðÿÊïÿ¶êÿ­àýÒþšÎþ“ËþŸÕÿ¢Ùÿ«àÿ°ãÿ¶åÿ¸æþÀêÿÆìÿÉìÿÎîùÔòýÙôýÚõüÜøüÞ÷üåþÿßøýáùýèÿÿëÿÿèÿÿæÿÿàüÿÛøÿÚöÿÏôÿÍôÿËðÿÌðÿÌîúÌì÷ÏíøÓñüÖöÿØøÿÕõÿÊíÿÄéüÁçþÀæû¿ä÷ÌíÿÏðÿÇëÿ¾æÿ±Þû°ßýªØù´áþ¸äýÊîþÕóþàùÿáúÿÚ÷ÿÈíÿ¸çÿ—ÑùÊö†Åø„Åû‚ÇþƒÈÿ‡ÉûÍü•Òÿ¡×ý¤Öù±Þû½åþÒñÿèüýìÿÿíÿüíÿúìÿüêþüâûÿÚöÿÍîýÉðÿÈòÿ½çÿ½åþÈëþÎïþÖôÿÙ÷ÿÚ÷ÿÔóÿÍîÿ¿äþ±Ýÿ§Ùþ¦Øý¨Ùÿ¨Üÿ§Ûÿ¥Ûÿ£Ùý¡Öø¢×ù´ÜöÆéÿÈëÿÐïÿÒòÿÔóÿÐñÿÃèÿ½äÿ±Þÿ´Þö¸á÷ÄêÿÉíÿÏîÿÏîÿÔòýÖôÿÕòÿÍìÿËïÿ¶êÿ©ÞýœÑû˜ÌûšÎþ¥Ùÿ¬Þÿ¶äüºçþÅîÿËñÿÍñÿÒòÿ×õÿÜ÷þÝöûäüÿåýÿæþÿêÿÿêÿÿéþÿéþÿçÿÿèÿÿâûÿâþÿØöþÏïüÌìûÄêýÁìÿÆíþÈíÿÍïûÎîùÒðúÕóû×óþÚöÿÚøÿÓóÿÍîÿÆëýÎñÿÑõÿÓóÿÒñÿÊíÿÁçþ°ÝüªÚþ§×ÿ°Þÿ¶áÿÊíÿÓðÿÝõÿß÷ÿÚöÿÆëþ²áýœÓú–ÑûŽÎþŒÎÿƒÈÿ„ÉÿŠÍÿÐÿ’ÐÿœÓü Ôù´áÿ¾èÿÐñÿèûÿëÿÿëÿûëþøìÿûêþüåüÿÝøÿÐðÿÌðþÊñÿ½çÿÁçüÍîýÓóþÛøÿÞùÿßúÿÙöÿÒòÿÄèþ´Ýû¬Úû¬Úû¯àÿ²ãÿ¯àÿ¯àÿ®ßÿ®Ýû®Ýû½áùÏïÿÔóÿØõÿØõÿÔóÿÎñÿ¿èÿ¶ãÿ§Øÿ©Øö­ÛõºãÿÀçÿËíÿÌïÿÏïþÎïþÍîÿÆéÿÅêÿ±äÿ©ÞþœÑû˜ÍùÐýªÜÿ°Þÿºäü¿èüËðÿÍñÿÑñüØôÿÛöýáùýãûÿèýÿéþÿéþÿëÿÿíÿÿéýþæûüæþÿèÿÿÝøÿÝúÿÑñüÇëûÅèûÁçü¾çûÂéúÈíÿÐòþÑñüØõýØõûÙôýÜ÷ÿÜùÿØöÿÓóÿÍñÿÑõÿÓ÷ÿÓóÿÒñÿÈìÿÀèÿ¯Þü¬Þÿ¥Öÿ­ÝÿµâÿÇëÿÐïÿÛóÿÝõÿÚöÿÃèû¯ÞúÓù™ÓûÐþŽÐÿ„Éÿ…ÊÿŠÍÿÏÿ’Ðÿ—ÐûžÔúµãÿ¼èÿÎñÿÛöÿàûÿåÿÿåýýêÿÿéÿÿáùÿÜöÿÑðÿËïÿÊïÿÆìÿÉîÿØöÿÝúÿåýÿêÿÿëÿÿáüÿÚ÷ÿÎîûÅèû¿åü¼åû¾æÿ¾èÿÁéÿÃëÿÇíÿÊîÿÈìÿËìýÖóÿ×ôÿØôÿÖôÿÍðÿÅëÿ¯Ýþ¦Úÿ™Óÿ–Ñù—Óø¡Öþ¨Ùÿ¶ãÿºæÿ½çÿ½êÿ»çÿ´áÿ°Þÿ§Üü§Ûÿ¤×ÿ¢Õÿ«Ýÿ²áý·äûÃéüÈëÿÏîÿØôÿÝøÿåüÿéþÿìÿÿëÿÿìþþìþþìþþìþÿîÿÿêþÿçüýáúþÝùýØöÿÔôÿÈíý½ãø¼âùÀæûÀåøÆéüÎïþÚøÿÜøÿÜ÷þàùýàùþÝöûÛôùÜ÷þÚøÿÔöÿÏðÿÎïþÏïþÊëü½ãú·ãü¬Ýþ¨Üÿ¥Úÿ¨Úÿ¬ÝýÄêÿÈëþÕóþÙ÷ÿÖöÿÀæù³áû¤ØýŸÖýÎý‹ÍÿÆÿ‚Çÿ…Èÿ‰ËÿŒËþ”ÎüšÓþ±ãÿ·æÿÈîÿÖôÿÜúÿáþÿáýÿåþÿåþÿÝ÷ÿÙôÿÐñÿËîÿÉîÿËðÿÏóÿÝûÿãÿÿêÿþëÿþëÿÿãüÿÜ÷þÔòýÐðÿÈëþÆëýÆëþÅëÿÉíÿÍðÿÎñÿÏðÿÏîÿÑñþ×õÿÖôþ×óþÔòüÈìü½æú§Øù¡×ý–ÓÿÐüÐü•ÒþÓÿªÛÿ­Þÿ®Ýù°âý°áÿ­ßÿ©Ûÿ¥Úü¥Ùÿ¥Ùÿ¤Øÿ¬Ýþ³áùºäúÅêüËìÿÐíÿÚõÿáúÿéþÿìÿÿíÿÿíÿÿíýýíýýïÿÿíÿÿíÿÿìÿÿéþÿàùýÚõüÕõÿÒôÿÈïÿ¼åûºâûÂæüÃèúËìýÐðýÛ÷ÿÞùÿâûÿæÿÿæÿÿáúþßøüÜøüÛøÿÔôÿÌíüÊëúÍîÿÈéü¸àù·ãþ«Ýþ¦Úÿ¦Ûÿ¥Úü©Úú¿èþÆêúÕõÿØùÿÕ÷ÿÀêú´âü¥Úü Øý‘ÏþÏÿÆÿ€ÅþÆý‡Èþ‹Êÿ‘Îý–Ñý§Ûÿ­Þþ¿éÿÇêýÏóÿÖøÿÔõþÑòûÑñüÑðÿÎïÿÈìÿÄêÿÄêýÊîúÐòüàüÿçÿÿìÿüíÿüìÿþéþÿçÿÿãÿÿÚ÷ýÖôþÔôÿÔöÿÔõÿÍîÿÖöÿ×÷ÿØôÿÛõÿÜùÿßüÿÞûÿÛùÿÖôþ¾ãõ´Þô¢×÷×ý‘Ñÿ‡Íÿ‡Íÿ‹ÍÿÎÿ˜Òÿ›ÔÿšÒ÷˜Ðõ™Ð÷Öÿ›Ôÿ ÔûŸÓú©Ýÿ®àÿµäÿ½çý¾çùÊëüÏîÿØóÿÜ÷ÿäüÿíÿÿîÿÿïÿþñÿÿîüýïýþòÿÿòÿÿñÿÿíÿÿêþÿâùÿÝøÿÑñüÎïþÍòÿÄêÿÀéÿÊíÿÐñÿ×÷ÿØöÿÞùÿâþÿãüÿåÿÿçÿÿéþÿéþÿÝöûÛöýÔôÿÌíþÊëüËïÿÊíÿ¾æÿ»çÿªÛü§Üþ¡×û§ÜüªÝúµàóÁæöØùÿÛüÿÕ÷ÿÅïý¼éÿ­ßÿ£Ûÿ‘ÑÿŽÐÿƒÈÿ‚Çÿ„ÇþˆÊþŒËÿ’ÐÿÍú˜ÏöŸÔö²àúÃèûËðÿÐôÿÍñÿÎòþËñüÅêúÅêüÂèû¿èüÆìÿÑñü×õÿãÿÿéÿÿêþýîÿÿîÿÿìÿÿêÿÿåÿþÞ÷ûÚõüØõýÔôÿÔõÿÔõÿÕõÿÖöÿÙ÷ÿÛøÿàûÿßúÿÝúÿÚøÿÒóÿ·ßø®Ûø¢Øþ›ÔÿÌÿ‡ÉýˆÊþÎÿ’Ðÿ”Îþ”Îü–Ïú–Ïú–Ïú™ÔÿœÕÿ Öü¡×ý©Þÿ¯âÿºèÿÁçüÅêüÎîûÑîüØôÿÛöýçÿÿíÿÿñÿÿñÿýõÿÿîüüïýýóÿÿðÿÿðÿÿíÿÿëÿÿäøÿßõÿÚôÿÖòÿÎïþÅéùÆìùÎðüÔòýÜùÿÞúýàúûÞúûåÿÿâþÿæÿÿíÿÿêþÿÜ÷þÛ÷ÿ×ôÿÈéüÂãöÌðÿÊïÿÃìÿÁëÿ¶âÿ¯Ýÿ«Ýÿ§ÙüªÛü´ÞöÀåøØöÿßûÿÝûÿÌîúÄêÿ«ÜüÓ÷ÏÿŒÏÿ…Êÿ‚Çþ…ÇûÎÿÎÿËý”Ìý›ÒûŸÓú­Þþ¼áü¼äý¿èþÃéþÁêü½æø¹âô·àô½æü¾æÿÁçþÎðüÑóÿÒîùÔïøà÷ýçüÿèýÿæþþçÿÿâþÿÝùý×óþÔòýÑòÿÑôÿÊíÿÍîÿÐðÿ×õÿÛøÿßøýÛöýØõýÑñþÉêûÀêÿ²ßÿ™Ðù•ÏýŠÌÿ‡Èþ‰ËÿÌÿÌÿ’Îÿ•Òÿ—Ñÿ”Íú”Íø˜Ñü›Õý Öú¤Øý®àÿ²ãÿ¼æÿÂçúÅèûÎîûÏïúÙõÿÞùÿçÿÿíÿÿðÿÿñÿÿðÿüïýýïýýïþÿíÿÿëÿþëÿþêþÿèûÿæúÿá÷ÿÜ÷ÿØöÿÐòüÎòþ×÷ÿÚøÿÛ÷úÝ÷øàúûßûüáþÿãÿÿæÿÿëýýæúûàûÿÞùÿØóÿÌëýÈéúÌðþÌòÿÉðÿÉïÿÀèÿ¶ãÿ®ßÿ¥Ö÷¨×õ·á÷ÈíÿÝúÿâþÿãÿÿØöÿÎóÿ®ÜýÓù‹ÍÿˆÍÿ…Êÿ‚ÇþƒÅùŒËþŽÍÿ‘Ïÿ“Ñÿ™Ôþ›Õý¦Üÿ¬×ù¯Úüµàÿ¶ßý·àüºãÿ¹ãü·ßù¾åÿÄéÿÂçÿÁçúÅêýËîÿÏðÿÏïü×õÿÙõÿÝúÿáþÿâÿÿ×÷ÿÍñÿÈëþÂèýÃéÿÈîÿÊíÿÌíÿÓðþÖòýÞ÷þÜ÷þÙöþÓóþÌíþ»åþ³áÿ›ÒûÌù†ÉþƒÈÿ†Éÿ…Èý†ÈüŽÍÿ“Ñÿ•Ïý›ÔÿžÔÿŸÖÿ¡×ý§Ùú«Ýþµäÿ¸åÿ¼æþÄêýÇêýÏðÿÐòþÛùÿàûÿåýÿíÿÿîÿÿðÿÿðÿüðÿÿðÿÿìþÿìþÿêýÿéþÿéþÿèýþèýþçÿÿäýÿÙöüÖöÿ×ùÿØöÿÜùÿãüÿäüþâüýàüÿÙøýßüÿäýÿåùúäøùÞ÷ûÝöý×ñþÔðþÓñüÒôþÐõþËðÿÊïÿ¾æÿ·åÿ«Üú©Úø¯ÞøÉòÿÑõÿâþÿæÿÿçÿÿÛùÿÍóÿ¥×ü—Î÷„Åû‚Äþ‚ÄþƒÆý‹ÊÿÎÿÏÿÑÿ‘Ôÿ”Õÿ”Óü×ý¦Òõ©Õø°Ûý¯Úü³Üü¸áÿ½æÿ½äÿ½äÿÄèÿÄéÿ¾çý½æüÄêÿÉíÿÍðÿÒóÿÓóÿÔôÿ×÷ÿØøÿÕöÿËðÿÅëÿ¾æÿ½åþÀèÿÆêÿÉìÿÒòÿÖôÿØóúÛöýÛöýÖöÿÐñÿ¼äþ·äÿœÖþÍú†Éþ„ÉÿƒÈÿƒÆý†ÇýŽÍÿÐÿ“ÐýÖÿ ×ÿ£Øÿ¥Ùþ¬Ýý¯àÿ¸åÿºæÿ¾æÿÅëþÇìÿÏðÿÐñÿÛùÿßúÿäüÿìÿÿìÿÿñÿÿñÿýðÿÿðÿÿìÿÿëþÿëÿÿêÿÿéþÿêÿþêÿþèÿÿåÿþÙõùÚøÿÙùÿØôÿÜ÷þåþÿæþÿáûüÝùüØöþÛùÿßûÿáôøáõöß÷ùßöüÛóÿØôÿØöÿÖøÿÕ÷ÿÌòÿÊïÿ½åþ°Ýú¨Ûø¯àþ´ãýÈòÿ×ùÿæÿÿéÿÿçÿÿ×øÿÄìÿžÒù“Ì÷„ÅûÃýÃýƒÆýŒËÿÏÿÏÿÒÿÔÿ”Õÿ”Óü›Õý±ßÿ®Üý³áÿ¸åÿºæÿ¼èÿÂìÿÅíÿ»àúÁæÿÂêÿ»çÿ½éÿºæÿ¸äÿ»çÿÁëÿÃèÿÄèþÇìÿÊïÿÈîÿÂêÿ½çÿ·ãÿµáþ¹âÿÀèÿÆìÿÐñÿÓóÿÔñùÛöýÞùÿâþÿÛûÿËðÿÁíÿŸÖý“Ðý‰Ìÿ‡ÌÿƒÈÿ‚Èü‰ÌÿÎÿŽÎþ–ÓÿœÓüžÓû§Ûÿ­ßÿµâÿ¶ãÿºæÿ¾èÿÀéÿÅëþÆëýÍîÿÍîÿÖöÿÝøÿáùýëÿÿêþýñÿÿòÿÿíýýìþÿëÿÿèýÿÞöÿÞ÷þÞ÷ûâûøãüøåÿûæÿýÞúýÞúÿÚøÿÙõÿÝøÿãüÿâùÿÜõúØóúÍíøÓóþÚöÿà÷ýåúýäùúâúþÞöÿÚöÿÚøÿ×ùÿÓøÿËðÿÇíÿºãÿ²àÿžÐó¨Úû°ÞÿÅîÿÎòÿáüÿâýÿÛöÿÄèø³ßü–Ëõ“ÍûŠÍÿ†Ëÿ‡ÉÿˆÉÿˆÇü‹ÉüŽÍÿ”Óÿ•Õÿ˜Õÿ˜ÓÿŸÔü¹æÿºçÿºèÿ¼èÿÁëÿÃíÿÀèÿÀæýÁåûÇìÿÈîÿ¾èÿ»çÿ¹åÿ¶ãÿ±Þý¶ãÿ¼åÿ»ãü»äúÃéþÁêÿ¾èÿ¹åÿ±Þý¯Üû´ßÿÂêÿÅêÿÏðÿÐïÿÏìôÚõüÝøÿÞúÿÛøÿÒöÿÇðÿ£Ùÿ“Îú‰Ëÿ†Éÿ†ÉþˆËÿ‹Îÿ‘Ðÿ‘Ñÿ–ÓÿÔý Öü«Ýÿ®ßÿ¶âý¸äÿ¾èÿ½çÿÁêÿÉîÿËîÿÌíþÌíþÏïúÙôýãûÿëÿÿìÿÿñÿÿñÿÿìüüîÿÿçüÿâöýÜ÷ÿØóüÙõùÞø÷ãþùæÿüæÿýàüÿÜøÿÖôÿÑíøÖñúâûÿãúÿ×òûÒîùÍïûÏñý×õÿßøÿß÷ûæûüãûÿß÷ÿ×óþÕóýÔöÿÒ÷ÿÇîÿÀéÿ¸ãÿ«Ûÿ¤Øÿ¥×üªÚþ»ãýÅèþÖòÿÛ÷ÿÖóÿÂæü°Ýþ—Íû‘Íÿ‹Íÿ„Éÿ…Çÿ‡ÈÿÊÿÎÿÎÿ’Îÿ–Ïÿ™ÑÿœÒþªÜÿÅðÿÈóÿÉòÿÅîÿÄêýÅëþÈíÿÇìüÆêøÈìøÉíûÅëÿ¿èþ¶âý³âÿ¬Þÿ©Ûþ«Üý®Ûø±Ýø¼æþ½åþ¾èÿ¼èÿµâÿ®Üý°Ýüºãÿ½åÿÆêÿÊíÿÖôþÛøÿÛøÿÜ÷ÿÙõÿÍîÿÄèÿ©ÙýŸÔþ‘ÏÿÏÿŽÎþÌÿÎÿÐÿÏÿšÕÿŸÖý£×ü­Þÿ¯Þü´àû¸âû¾æÿ¾æÿÅëÿÉîÿÊíÿÍìþÎîýÔòýÚõüäüþêþÿêþýîþýñÿÿìþÿëþÿäøÿßöþÓóÿÏïüÏðùÓðô×õ÷âþÿåÿÿßüÿÕòúÑïùÒðúÖóûßúÿßúÿÕñÿÎîýÇìÿÉîÿÎòÿÚøÿÛøÿàùþß÷ÿÙõÿÔôÿÒôÿÊðýÅïý¿éÿ¸äÿ«Øÿ¥Øÿ¡×ÿ Õÿ£×ÿ±Üþ¸ßüÄæÿÇéÿÁæÿ®Ûü¥Öþ•Ïý‘ÏÿŠÌÿ‡ÌÿŠËÿŠËÿŽÌýŽÌýŽÎþ–ËÿšÌÿ¢Òÿ©ÖÿºåÿÊòþÍõÿÏôÿÊïÿÇêýÈëþËïÿÊîüÌîúÍïùÍïùÈíÿÁçú´àù°ßýªÜÿ£×ü¥×ú©Øö®Ûø¹åþ½æü¾æÿ½çÿ·äÿ¯Ýþ±Þý¶âÿºäýÄêÿÉîÿÓóþÛøÿÚ÷ÿÛöÿØóþÌëýÃæü¬Ùú¤Õý˜Òÿ‘ÎýÍúÍü‘Ïþ“Ñÿ“Ñÿ™Ôÿ Õý£×ü¯Ýÿ¯Þü¶âýºãÿ¿çÿ¿èþÆìÿÊíÿÍîÿÎîýÏïüÖôþÚöúåúýêþÿëÿþïÿþðÿÿëÿÿéüÿà÷ýÞ÷þÒóÿÌðþÎðüÑïùÖôüàýÿâÿÿÝúÿÖóûÒðúÑïùÔòüÞùÿÞùÿÔñÿÎïÿÄêÿÄêÿÊïÿÖöÿÙ÷ÿÛöÿÚõÿÕòÿÏðÿÌðÿÄîþÀëüºæÿµâÿ¥Ôþ ÕÿÕÿŸÕÿ¡Öÿ®Úý´Ýý¼áü¿äÿ·âÿ§ÙüžÒú”ÎþÍÿ†Èÿ†ËÿŒÍÿŽÍÿŽÌûÍüŽÎü–ÊúÍý©Öÿ°Üÿ¿èÿÏïúÑñüÓóþÒòÿÏîÿÏîÿÏîÿÎîýÑñþÕõÿ×øÿÖôþÎðü¿èþ¶äþ©Þÿ£Ùÿ¢Öû§Ùú­Þþ»çÿÁêþÀæû¾çý»çÿ´áÿ±Þý³ßü¶âû¾çûÅëÿÎðüÛùÿÞûÿáúÿÞöÿÔðþÌëý¶Ýú®Úý¤×ÿ ÕÿÓÿ—Ðý–Ñý”Ñþ”Ñý™Ôþ¡×ý¦Úÿ±ßÿ¯Þü³àýµáü»åþ½æüÆëþÎïÿÑñÿÔòýÖôþÛöÿÝöûçüÿìÿÿìÿÿðÿÿìþþêýÿæûþâùÿàøÿÊðýÅìûÅìýÆéüËìý×ôÿ×ôÿÖôþÛùÿÙ÷ÿÏïúÑñüÚöÿÚöÿÒñÿÍðÿ¿éÿ¹åþ¼æüÊïÿÎòÿ×ôÿÖóÿÏðÿÄêýÀéý¸åú²âù«Ûÿ§ØÿœÐÿ•Îû•Ðü™ÒýŸÖÿªÜÿ¯Ýþ±Þû²áÿ«ßÿ Úÿ™Òý’ÏþÌÿÆÿ…ÊÿŒÍÿÌÿŽËø‘Ðü’Òþ Ôû¦Öú´âÿ»çÿÁéÿÔòüÔòüÖôÿ×ôÿÕòÿÓðÿÒïÿÑîþÑñþ×÷ÿÛùÿÙöþÓóþÄíÿ»çÿªßÿ¥Ûÿ£ÙýªÜý°áÿ¼èÿÃìÿÃéþÂëÿ¾êÿµâÿ²ßþ³ßü·ãü¼çúÂëÿÎòþÛùÿÝúÿâûÿáøÿÙóÿÔñÿÀåÿ´ßÿ¨Ùÿ¥Ùÿ¢×ÿœÒþšÓþ—Ôÿ–Óÿœ×ÿ£Ùÿ¨Ýÿ±ßÿ®Ýû°Ýú³ßú»åþ½æüÈíÿÎïÿÒòÿØôÿÙõÿÜ÷þáúÿéþÿìÿÿìÿÿïÿÿìþþêýÿçüÿçþÿãûÿÌòÿÄîþÅëþÄçûÈèýÏîÿÑðÿÔñÿÙ÷ÿÚøÿÑñüÓóþÙ÷ÿØõÿÏïÿÊîÿ½éÿ¶âý¸âúÄêýÉîþÐðÿÑðÿËîÿÁçü¼åû³áø¯Þø¤Õý Óþ›Ñÿ‘ÌöÎ÷•ÐúšÔú§Üþ­Þþ¯Þü¬Ýý¤Üÿ™×ÿ˜ÑüÍþ‰Ëÿ‚Çþ…ÊÿŽÐÿÏÿ‘Îú–Õÿ™Úÿ§Ýÿ­Þþ·æÿ½éÿÄíÿÚõÿÙôÿØóüÙôýÛöýÚ÷ýÚ÷ÿÚøÿÕõÿÖøÿÚúÿÜ÷ÿÚøÿËðÿÂëÿ°ßý¨Øþ¦Øý®ßÿ¶åÿÁîÿÆëþÈíÿÇíÿ¼èÿ¸æÿ³áûºæÿ½çÿÂèýÈíÿÖöÿÜ÷ÿáúÿéþÿéþÿäüÿßúÿÎïÿÂèý²Þû¬Üÿ¦ØýžÒùŸÔþŸÕÿ›Ôÿ¥Üÿ¨Þÿ§Ûÿ«Þý­àý¬Û÷¯Þú·ãü½çýÉîÿÓóÿØöÿÞùÿâûÿçÿÿçÿÿêÿÿìþÿîýÿïýþðþÿðþÿïþÿëÿÿëÿÿßüÿÙ÷ÿÑñüÍîýÎïÿÊîþÌíþÓðþÙöþÛöÿÞ÷üßøýÞùÿÚöÿÌðÿÉïÿµáú¬Û÷«Úøµäÿ½ëÿÆìÿÂèý¾èÿ·ãþ¯Þü¤ÙûœÓú’ÏüÎÿ‹ÊÿŠËÿ‘Ðÿ‘Îû–Ñû§ßÿ«áÿ©ßÿ¥Ûÿ›Ñÿ—ÑÿÌþÎÿˆÊþƒÈÿƒÊÿŒÏÿÏÿ’Ðù¡Ùü§Ýÿ±àþ´áþ»åþ¾æÿÊðÿÕñÿÔñÿÙõÿÝùÿàýÿàýÿÜùÿÛùÿÓóþÑóÿÓóþÚ÷ÿÜøÿÎòÿÇîÿ¸æÿ¯Ýÿ«Ûÿ°Þÿ´ãÿ»èÿÅëÿÆìÿÂêÿ¹åþ¶äþµãý»åý¿èþÇìÿÊíÿÏìúßúÿäýÿåúûçûüéÿÿçÿÿÚøÿÐñÿ½æü°ÝþªÛü§Ùþ¦Úÿ§Üÿ¦Ûÿ¤Ùÿ¨Üÿ§Üü¬ßü¯áü²ßü´âü»åýÀéýËïÿÕóýÙöþàùýãûýçÿÿçÿÿêÿÿíÿÿðÿÿôÿÿôþÿïýþîþþëÿÿëÿÿìÿÿçÿÿáýÿÜúÿÙùÿÒôÿÐòþÕóþàûÿåýÿëÿÿçÿÿáýÿÞûÿÑõÿËòÿµáúªÙ÷¦×÷©Ûþ°áÿ½æú½çý¹åþ´ãÿ­ßÿÔû“ÎúˆÇú†Èü€Åþ|ÁüƒÆý‹ÊýÍü™ÔþØÿž×ÿ›Öÿ•ÏÿÌþÍÿŠÉþ„Çû…Ëÿ‡ÍÿˆÌýŠÊø—Ñù®ãÿµæÿ¸åÿ¸åÿ»åþ½åþÅëÿÍìþÎîýÔñÿØöÿÝúÿÝúÿÝúÿÛùÿÖôÿÑñþÒòýØõýÚøÿÎòÿÈïÿ»éÿ®ÜÿªÚÿ°Þÿ´ãÿ¹çÿ¼æþ½åþ»åþ´âü´âü¶äþ¼æþÀéýÊíÿÍîÿÐíûßúÿãÿÿçüýéýþêÿÿçÿÿßüÿ×÷ÿÅêý³àý°ÞÿªÜÿ«Üÿ©Ýÿ§Üÿ¥Ùÿ«Ýÿ«Þý²áý´ãý¶âý¸äý¾çýÃéþÎïþÙõÿÝøÿãûýçüýéþÿèýþëÿÿðÿÿòÿÿõÿÿõÿÿòþþîüýìþÿìþÿëÿÿéÿÿåþÿàýÿÛùÿÒòýÑñüÖòýÞùÿãüÿéþÿäüüÝùýÜùÿÏóÿÉïÿ¶âûªØù¥Ö÷¦Øý¬Ýþ¼æü¿éÿ¹åÿ³áÿ®àÿÔý•Ðü‹Êÿ†ÉþÄý{ÀûÄý‡Éý‹ËûÎú“Ðý”Ñþ”Ñþ‘ÎýŽÌý‘ÏÿˆÊþ…ÇûˆÎÿŠÐÿŒÎÿŒÌúšÔú²äÿ¸çÿ¹æÿ¸åÿ·ãþ¹ãüÀéÿÃçÿÃçýÇêýÌíþÓóþÖôþ×ôü×óþÕóþÓðþÓïûÔðûÖôþÎòþÊñÿ»çÿ°Þÿ¬Üÿ¬Üÿ­Þþ­ßú¯Þú°ßý¯Þü¯Þü²áý·ãþÀèÿÆìÿÎïÿÐðÿØöÿÛøÿàüÿéÿÿëÿÿêÿþéþÿçÿÿäÿÿ×÷ÿÀèÿºçÿ°Þÿ«Ûÿ¨Úÿ§Ûÿ«Ýÿ±ßÿµâÿ»åý¼æþÁéÿÂëÿÈíÿËîÿ×ôÿÝøÿãúÿçûüçûúéüúëýýíÿþòÿþõÿÿ÷ÿÿöÿÿôÿþóÿýðþþðþÿíýüìÿýêþýçÿÿáúÿÖñúÖòýÙõÿÜ÷ÿÝöýèÿÿçÿýßûþÜùÿÊîþÄêÿ´áþ§×û£Õú¦×ÿ¬Üÿ¸äý»çÿµâÿ¬Þÿ§Ûÿ˜Ñþ’ÏþŠËÿ…Êÿ{Ãý}ÆýÊÿ€ÇÿÄýÃý‚ÃýƒÄú†ÈüŒÎþÏÿŽÍÿ‰Ëÿ†ÈüŠÍÿŒÏÿÍü‘Îú¡×ý¶åÿºæÿ¶åÿ´ãÿ°Þø²àúºäüÀåÿ¿äþÂæüÇêýÒòÿÖôÿ×óþ×óþ×óþÕñýÔðüÔðüÔòýÏóÿÌóÿ¹åþ°Þÿ­Ýÿ«Ýÿ¬Þÿ«Þý­Þþ¬Ýþ«Üý«Üü±àü¶âýÃìÿÈîÿÎïÿÐðÿÖöÿÛøÿÝøÿäüþéþÿëÿþéÿýèÿÿèÿÿÜùÿÆìÿÀêÿ±Þý¬Úü¨Úÿ©Ûÿ­Ýÿ³àÿ·ãþ½æü¾çýÂèÿÃéþÈëþÍîÿÖôÿßøýãûÿéýþêüüêýùìÿýïÿþòÿþõÿÿ÷ÿþöÿý÷ÿÿöÿÿñÿÿðþþïþûïÿüìÿýëÿÿäüÿÙôûØóüÚõþÜ÷ÿÛöÿäüüäýúßüÿÛùÿÉîÿÂëÿ±Þý¤Ôú Ñù¤Øÿ¬Ýÿ·äÿ¹æÿ´âÿ«ßÿ§Ýÿ–ÐþŽÌý†ÉÿƒÈÿ|Äþ}Æý€Ëÿ|ÄÿzÀü|ÀýÃÿÁû‚Åü‰ÍþÏÿŒËþÌÿˆÊþŠÌÿÏÿŽÍù“Îø¤Øýµäÿ¸äÿµäÿ°âý®Ý÷²àú¹åþ½æÿ¼åÿ½ãúÀäúÏðÿÕõÿÛ÷ÿÜ÷ÿÜ÷ÿÚõÿÙóÿÖóÿÕóþÍñýÈðü¼éÿ¯Ýþ­Ýÿ«Ýÿ©Þÿ©ßÿ§Ýÿ¢Øþ¢Öý©Ûþ°ßý»èÿÂëÿÇìÿÎïþÎîýÒôþÜúÿÜùÿÜõùâúþêÿÿèýÿêÿÿêÿÿãüÿÑòÿÈìÿ·ßù°Üù¬Ýþ­Ýÿ¯àÿ¸äÿ½çÿÃéþÄéüÄèþÆéýÑòÿÐñÿÖòýÞ÷üåúÿéýþéýüìÿýëýýìÿýðÿýóÿÿõÿÿôÿþõÿÿóÿÿñÿÿïýþòÿþïÿþìÿýêÿÿçüÿÞ÷üÛôûÖñúÜ÷ÿÝøÿâþÿÞûùÙ÷ÿÕ÷ÿÆìÿ½æÿ«ÙýÐûÐû¡Öÿ£ØÿªÜÿªÜÿ¨Üÿ¢ÙÿŸØÿ“ÑÿÎÿƒÈÿÇÿ‚Êÿ~Éÿ|ÇÿwÁþu¿þu¼þx¿ÿ{Áÿ{ÁüƒÉýŽÒÿŒÎÿÌÿÌÿÎÿ’Ðÿ˜Õÿ›Ôÿ¨Úÿ´áÿ¶áÿ²ãÿ¯âÿ¯áüµäÿºæÿ»çÿ¼åÿ½ãú¿ãùËìûÐðûÚ÷ÿÞùÿßúÿÚõÿØóþ×ôÿÔôÿÌðüÆîú¹æû¬ÚûªÚþ¥Ùþ¢Øü Øû¦Ýÿ¢×ÿ Õý¦Úÿ³âÿ¸åÿÀéÿÅëþÌðÿÎïþÑóýÚøÿÚøÿÚöúßøýèýÿæûÿåúýåýÿãüÿÔôÿÌïÿ½ãú¶àù¯Ýþ¬Ýþ°áÿ¹æÿ¾èÿÄêÿÆëþÅéÿÆéÿÎïÿÏðÿÖôÿàùÿäüÿéþÿëÿþìÿÿíÿÿìþþíÿþðÿýóÿÿðÿÿñÿÿòÿÿðÿÿîþþðÿÿïÿþíÿÿìÿÿèÿÿßøýÜõüÖñúÜ÷ÿÝøÿàüÿÜúüÔõþÐôÿÁéÿ¸ãÿªÚÿ Õÿ Õÿ Öÿ Öÿ Õý¡ÖþŸÖÿ›Ôÿ™Ôÿ‘ÏÿŒËÿƒÈÿ‚ÈÿÉÿ~ÇþzÅþxÂÿvÀÿu¿ÿw¾ÿ|Âÿ|Âþ‚Éÿ‹ÏÿŒÎÿŽÍÿŽÍÿÐÿ’Ðÿ˜ÒÿšÓþ¦Úÿ±ßÿ°Ýþ­ÞþªÝü®ßý¶åÿ¾êÿÀèÿÁéÿÇëÿÉìÿÐðûÔòüßúÿèÿÿèÿÿÞ÷þÚõÿØõÿÓóÿÌîúÅëøºåø°ßý«Ûÿ¢×ÿ ×þ›Õû›Ôÿ ÖÿŸÕÿ¢Öý°áÿ³àý¼æþÀéÿÈíÿËðÿÑóÿÕõÿÙ÷ÿÛ÷ÿÛöÿß÷ÿÝöýÛôùÞõûáúÿÚ÷ÿ×õÿÌïÿÂëÿ°Ýü¨ÙúªÜÿ¶åÿ¹åÿ¿èþÃéÿÆìÿÅëÿÉîÿÌïÿÓóÿÛ÷ÿßúÿäüÿåýÿèÿÿéþÿéþÿéþÿéþÿêÿþëÿÿìÿÿìÿÿêýÿêýÿéþÿæþÿåýÿâúþáøþÞ÷þÚõüÔñùØôÿÚöÿÜúÿÖ÷þÊîþÄêÿµàÿ¬Üÿ¡Öÿ›Óÿ™Óÿ•Ïý‘Îû‘Îý’Ïþ’Ïþ‘ÎýÍþ‰ÈýƒÄúƒÆý‚Çÿ}Ãþ}Ãþ}Ãþ|Äÿ|ÃÿyÃÿv½û|Âþ|ÂýƒÈÿŠÍÿŽÍÿ‘Ïÿ’Ðÿ“Ñÿ“Ðÿ“Íû–Ïü Õÿ¤Øÿ¦ØýªÜÿªÜý¯àÿ´ãÿ¸äÿÀæýÃéþÎñÿÓôÿÚøÿÜùÿâþÿåþÿåþÿàùþÜ÷ÿÒïÿÏïþÎðúÊðûÂíþ³âÿªÚþŸÔüžÕþšÓþ—ÑÿœÔÿÖÿ£×þ¬Ýþ±Þý¸äý¼æþÀéýÅëÿÏðÿÓóÿÕõÿÙõÿØòÿÙóÿÚôÿÜ÷ÿÜ÷ÿÛöÿßøýßøÿÕõÿËðÿ±àü©Úû¥×ü­Þþ³âÿ»åþ¼æþ¾èÿÂêÿÅëÿÇíÿËïÿÔôÿØöÿÛøþÞúþãüÿâûÿåþÿæÿÿãÿÿáýþäýÿãüÿãûÿáøþáøþÜ÷þÛøÿÚ÷ýÙôûÚõþÝøÿÜùÿÚöÿØöÿÙ÷ÿÕ÷ÿÎòþÀæû¸âû«Øÿ¦×ÿ™ÑÿÍüÍüÎýŽÎþ‹ÎÿŠÍÿ‹ÍÿŒËÿŒËÿŒËÿ‡Èþ‡Èÿ†ÉÿÆÿ„Æÿ„ÆÿÆÿÆþ~ÇþzÃú|Ãû|Áú„ÆÿÎÿÍÿ‘Ïþ’Ðÿ’Ðÿ’Ïþ“Íû•Ïý™ÒÿžÔÿ¡×ÿ¬Þÿ­ßÿ²àÿµâÿ¹åÿÂæüÆëþÏóÿÓõÿØöþÚ÷ýàùýàùýäüÿàùþÛöÿÑîÿÎîýÎðúÌòýÆñÿ¸çÿ°àÿ¥Úÿ¡Øÿ˜Óÿ˜Òÿ˜Ðÿ™Òý¡ÕüªÛü¯Üû·ãü¹æý¾éüÃìÿÏðÿÓóÿÔôÿÖóÿ×òÿ×òÿØôÿÚöÿÚöÿÚ÷ÿâúþáøþÖöÿÍòÿ´ãÿ¬Ýþ£×üªÛü±ßÿ·ãþ¶âû¹åþ½çÿ¾çýÄêÿÉíýÑñþÓóþØõýÚ÷ýßúÿÞùÿÝøÿÜøüÛøüÜúüÜøüÛ÷ûÝöûÝöýÞ÷þØõýØöÿ×õýÖóû×óþÛ÷ÿÛ÷ÿÚøÿØöÿÕõÿÒôÿËïýºãù±Ýú¦Öþ¡Ôÿ–ÎÿÍþÍþÏýŒÎþˆÍÿ‡ÌÿˆËÿˆÉÿˆÊþ‹ÊÿŠÉÿ†Çý…Èý…Çÿ…Åÿ„ÆÿÆÿ€Çý€Çý|ÃùÄû~Ãú…ÆÿËÿÍÿ’Ïþ’Ïþ’Ïþ‘Îý‘Îý“Ðÿ™Óÿ›ÔÿÖÿ¨ÙÿªÚþ¯Ýÿ²ßÿ¹åÿÆìÿËïÿÐñÿÑîþÔòýÓñûÙ÷ÿØùÿÛøüÝ÷øÝöûÐíûÏíøÖôþÙ÷ÿÔöÿÉïÿÁëÿªÚþ Ôü™Òÿ•Óÿ”Ðÿ•ÏýšÐüžÓû¨Ýÿ©Ýÿ­ßÿºæÿÁêÿÌïÿÓóÿ×óÿÙñûÚòüÙôÿØôÿØöÿÚöÿÜ÷ÿáúþãüÿÛûÿÑöÿ·äÿ­Þþ ÖüŸÖý ×þ¤Ûÿªàÿ¬ßþ­àý°ßû³áù¾éüÈïÿÌñÿÏóÿÎòÿÌðþËðÿÊïÿÊðÿÇíÿÈîÿÊïÿÍñÿÍñÿÏïüÏïüÑñþÍîýÏðÿÌíþÌíþÎïÿÐñÿÒóÿÍîÿÊëüÀéý¹æý«Üý¤Úÿ–ÐþÌû’ÎÿŽÌûÍû‹Òÿ‰Ïÿ‹ÌÿˆÉÿ‡ÊÿƒÈÿ‚Çÿ~Äÿ|Âþ‚Çÿ€ÅÿÆÿÆÿ‚Çÿ‚ÇÿÆÿÆý€ÅþƒÅÿ‚ÄþƒÅÿŠÍÿÐÿŠÎÿŒÐÿÏÿŽÍÿŽÌÿÎÿ—Ôÿœ×ÿœ×ÿŸÔþ¡ÔÿªÜÿ¯ÝÿµàÿÂçÿÇíÿÎïÿÐíýÒðûÒðûÓõÿÖøÿÛúÿÝ÷øÜõùÔòýÓñûÙöþÛøÿ×õÿËîÿÃëÿ°Þÿ¥Öþ–Ïü’Ðÿ’Îÿ•Ïÿ™ÒýŸÕÿ Ùÿ¤Ùÿ¨Üÿ¸äÿ¿çÿÊîÿÓóÿÙõÿÝôüÝôúÜ÷þÛøÿÚöÿÚöÿÝöýãüÿàüÿØøÿÎóÿ·åÿ®ßÿ¡Ùþ›Õý™Ôþ™Ôþ×ÿ¥Ûÿ§Üþ«Üü¯Þú¸åüÁêÿÄíÿÉïÿÈïÿÅëþÀéý¿èþÁëÿ¼èÿ¿éÿ¼æÿÁêÿÅëÿÉíýÌðÿÐñÿÍîÿÌðÿÈëþÈëÿÉìÿÉîÿÌñÿÊïÿÇìþ¾èÿ¸æÿ©Ýÿ Úÿ“ÐÿÌû’ÏþŽÍùŽÎü‹Òÿ‰ÏÿŒËÿˆÉÿ‡ÉÿƒÉÿÇÿ{ÃþyÀþ~Äÿ}ÃÿÅÿÅÿÆÿ‚ÇÿÆÿÆÿ€ÅþƒÅÿƒÅÿ„ÆÿŠÍÿ‰Ïÿ‡ÍþˆÎÿˆËÿŠÌÿŽÍÿÎÿ“Ðÿ™Ôÿ›ÖÿŸÕÿ Õÿ¨Üÿ­Ýÿ³àÿºãùÀéýÌðÿÏïþÒïýÎîýÌðþÎòÿÖöÿÜ÷þÜ÷þÚøÿÙ÷ÿÚ÷ÿÙöþÓñüÍðÿÅíÿ¶äÿ«Üÿ–Ìú’Ïþ•Ïý—Ðý›ÒûÔýšÔüŸÖý¤Øý²áýºãÿÃéÿÍìþÔñÿÞ÷üÞõûÞúþÞùÿßúÿâûÿæûÿåýÿÞúþÏïúÇìþ¸æÿ³äÿžÕü˜Òú™Ôþ—Òü—ÒüœÒþÔý£×þ¨Úý±Þÿ¶âÿ»äÿ¾çÿ½çÿºãÿ´àý³àÿ¶ãÿ²àÿ²Þÿ°Üÿ³Þþ·àü½åþÃéÿËðÿËïÿÉîÿÄèþÁçüÁæÿ¾æÿ¿çÿÁëÿ½çÿ­Úù®Üþ§Ûÿ ×ÿšÓþšÔüœÓü—Ñù“ÎúŽÎþŠÌþˆÇü†ÇýˆÊÿƒÉÿ€Æÿ}ÅÿzÁÿ{Áý|ÂþÅÿÅÿ€Åþ€Åþ€ÅþÄý€ÅþƒÅÿƒÅÿ†ÈÿŠÍÿˆÎÿ‡Íÿ‡Íÿ„ÇüˆÉÿÎÿŽÍÿËý“Ðý—ÑÿšÓÿœÒÿ£Øÿ§Øÿ¬Úü¸âøÀéýÌðÿÏïþÏïþÍîýÊïÿÉîþÑòÿÚöÿÛøÿÙ÷ÿÚøÿÛøÿÙöþÓñüÌïÿÃëÿ³áÿ©Ûÿ—Íù”Îü—Ðý›ÑýžÓûžÕüœÖþŸÖý¢Øþ­Þü´àýÀéÿËìýÐðýÜøüßøýáýÿáýÿâþÿåþÿêþÿåýÿÝùýÍíøÆëý¹çÿ³äÿ£ÚÿšÓþ˜ÓÿÍùÌø•Ïý—ÐýŸÔþ¤ØÿªÚþ³àÿµâÿ¸ãÿ¸ãÿ´áÿ±Þÿ¯Ýÿ°Ýÿ«Ûÿ¬Ùÿ­Úÿ°Üÿ²Ýý¹âþ¾æÿÈíÿÉîÿÈíÿÃéÿ¾æÿ»äÿ¹âþ¸äÿ¸åÿ³âþ¨Öø¨Øþ¤ÙÿŸÖýœÖü Øý¤ÚþŸÕûšÑúÍüŒÊý‡Æû„Åû†ÈÿÇÿ~Äÿ~Æÿ|Ãÿy¿ûzÀü}Ãþ€ÆÿÆÿ€ÅþÄý~ÃüÆÿƒÅÿ„Æÿ‡Éÿ‰Ìÿ†Ìÿ†Ìÿ…ÊÿƒÆý‡ÈþŽÍÿŽÍÿÍþ’Ïü“Ðý–Ðþ—ÏþŸÔÿ¢Öþ©×û»æùÂëÿÊïÿÌíþÌíþÉíýÄêÿÁçüÄéüÍìþÏìüÓñü×õÿÛøÿÚ÷ÿÖôÿÊíÿÂëÿ°Þÿ¦Øý›Ñý—ÐýŸÕÿ£Øÿ©Ýÿ§Þÿ¤ÛÿžØÿŸÖý§Ùü®Üý¼æþÍòÿÔöÿÜøüâûÿèÿÿçÿÿçÿÿêÿÿíýüëÿÿãüÿÒòýËïÿ´âüªÛûžÕü™Ôþ•Òþ’Ïû”Ñþ‘Íÿ‘ÍÿšÓÿžÔÿ¡Õý§Ùþ¨Øþ©ÙÿªÚþªÜÿ¬Þÿ¨Ùÿ¨Ùÿ¤×ÿ¦Úÿ£×ÿªÜÿ­Þÿµâÿ¸åÿ¿èüÅëþÁêþ¼æÿ¶âÿ¬ÚûªÛü©Ûþ¤Øý ÖúÐûžÑþÔýžÖû§Þü¬âþ¸êÿ³äÿ«ÝÿžÔÿ˜Òÿ‹Êÿ†Çý…ÇÿÅÿ}Ãþ|Äÿ|Ãÿx¾ú{Áý|ÂýÅÿÆÿÆÿÆÿÆÿ‚Çÿ‚ÄþƒÅÿ†Èÿ…Çÿ‚ÇÿƒÅÿ…Çÿ…Èÿ‡ÈÿŽÍÿŽÍÿÎÿÎÿÍþÎÿÍü—ÐýœÑû¨Úÿ¾éüÄïÿÌñÿËïÿËïÿÉîÿÂèý½æüÂæüÇèûÇçöÏìúÓñüÙõÿÙöþÖôÿÌðÿÆïÿ³áÿ¨ÚÿžÕþžÔÿ¤Ùÿ§ÜÿªÞÿ¨àÿ¦ÝÿŸÙÿ ×þ¨Úý°Þÿ¹ãüÎóÿÕ÷ÿÛ÷ûáúþåÿÿåÿÿçÿÿêÿÿïÿþîÿÿæÿÿÖôÿÌðÿ²Þù¦×÷¢Ùÿ›Öÿ•ÒþÍù’Ïü‘Ïÿ’Îÿ›Óÿž×ÿ Õý¤Øÿ¥×ü¦Øý§ÙþªÜÿ¥Ùÿ¡Õý¡Ôÿ Óþ¢×ÿ¥Ùÿ¬Þÿ®àÿ´ãÿ·äÿ½æúÂëÿ¿èþ¸äÿ³ßü¨Öø¥×ø£×üžÔúœÔù˜Ëø˜Ìû›ÒûŸ×ü¯åÿµéÿ¾îÿºéÿ°àÿ¤ØÿžÖÿÌÿ‡Èþ…ÇÿÅÿ}Ãþ|Äÿ}ÄÿzÀü}ÃÿÅÿ~Äÿ€Åþ‚ÇÿƒÈÿƒÈÿ‚Çÿ‚ÄþƒÅÿ†ÈÿƒÅÿƒÈÿƒÅÿ†Èÿ‡ÊÿˆÉÿÎÿŽÍÿÌÿŽÌýÍþÎÿÍü–Ïü›Ñý©Ûÿ \ No newline at end of file diff --git a/libs/ode-0.16.1/drawstuff/textures/wood.ppm b/libs/ode-0.16.1/drawstuff/textures/wood.ppm new file mode 100644 index 0000000..a53d2dc --- /dev/null +++ b/libs/ode-0.16.1/drawstuff/textures/wood.ppm @@ -0,0 +1,5 @@ +P6 +# Created by Paint Shop Pro +256 256 +255 +ÛÛÛÐÐÐÇÇÇÉÉÉÌÌÌÌÌÌÌÌÌÍÍÍÎÎÎÐÐÐÑÑÑÑÑÑÑÑÑÑÑÑÐÐÐÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÍÍÍÊÊÊÉÉÉÇÇÇÃÃÃÌÌÌÌÌÌÇÇÇ¿¿¿°°°¬¬¬¸¸¸±±±±±±µµµ»»»»»»¼¼¼ÉÉÉØØØÕÕÕÔÔÔØØØâââêêêæææØØØÊÊÊÃÃÃÑÑÑÜÜÜîîîîîîäääçççäääÙÙÙÛÛÛÐÐÐÇÇÇÅÅż¼¼æææçççèèèæææÛÛÛæææèèèâââãããÛÛÛèèèçççæææãããàààâââçççêêêêêêëëëîîîñññòòòòòòñññïïïëëëçççääääääèèèêêêêêêççççççÝÝÝíííèèèÎÎÎÂÂÂÂÂÂÇÇÇÆÆÆÅÅÅÂÂÂÂÂÂÂÂÂÃÃÃÅÅÅÅÅÅÅÅÅÆÆÆÅÅÅÎÎÎÅÅÅ°°°´´´······ÍÍÍØØØÌÌÌ»»»¼¼¼ÇÇÇÐÐÐÊÊÊÉÉÉÎÎÎÀÀÀººº¾¾¾¸¸¸¼¼¼¾¾¾ÃÃÿ¿¿³³³³³³¼¼¼¿¿¿¸¸¸ÂÂÂÉÉÉÇÇÇ»»»¸¸¸ÅÅÅÑÑÑÕÕÕØØØÑÑÑÆÆÆØØØãããÒÒÒÉÉÉÉÉÉÆÆÆÍÍÍÊÊÊ»»»ÍÍÍäää×××ÐÐÐÐÐÐÔÔÔØØØØØØ×××ÒÒÒÑÑÑÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÎÎÎÌÌÌÊÊÊÇÇÇÊÊÊÍÍÍÌÌÌÀÀÀºººÅÅÅÇÇÇ»»»ÍÍÍÆÆÆÇÇÇÅÅÅ»»»»»»¿¿¿¸¸¸¸¸¸¿¿¿ÃÃÃÃÃÃÆÆÆÇÇÇÃÃÿ¿¿ÆÆƸ¸¸ÝÝÝçççØØØÇÇÇÐÐÐÍÍÍÕÕÕÔÔÔäääíííßßßÝÝÝãããÝÝÝÜÜÜÙÙÙÕÕÕÑÑÑÍÍÍÊÊÊÉÉÉÆÆÆÆÆÆÇÇÇÉÉÉÌÌÌÌÌÌÇÇÇÅÅÅÀÀÀÆÆÆÉÉÉÃÃø¸¸±±±±±±´´´³³³¿¿¿ÍÍÍÑÑÑÌÌÌÉÉÉÎÎÎÕÕÕÒÒÒÊÊÊÅÅÅÇÇÇÊÊÊÊÊÊÌÌÌÎÎÎÎÎÎÐÐÐÐÐÐÑÑÑÑÑÑÑÑÑÐÐÐÐÐÐÐÐÐÎÎÎÎÎÎÍÍÍÌÌÌÊÊÊÊÊÊÉÉÉÂÂÂÍÍÍÎÎÎÉÉÉÀÀÀ´´´­­­³³³³³³···ººº¸¸¸ºººÀÀÀÍÍÍ×××ÒÒÒÔÔÔÙÙÙâââèèèæææÛÛÛÐÐÐÌÌÌÎÎÎÑÑÑâââêêêæææçççàààßßßÜÜÜÑÑÑÌÌÌÅÅŸ¸¸ßßßçççßßßàààÛÛÛãããäääÝÝÝãããàààßßßâââæææçççççççççêêêíííêêêêêêèèèçççæææäääääääääãããßßßÝÝÝßßßâââãããâââßßßãããÜÜÜèèèÛÛÛ¼¼¼»»»ÀÀÀÀÀÀÆÆÆÆÆÆÅÅÅÃÃÃÃÃÃÃÃÃÆÆÆÇÇÇÇÇÇÉÉÉÉÉÉÊÊÊÀÀÀ±±±´´´»»»¿¿¿ÌÌÌÐÐÐÆÆÆ¿¿¿ÆÆÆÍÍÍÐÐÐÍÍÍÌÌÌÌÌ̼¼¼ºººÀÀÀ»»»ÀÀÀÀÀÀÃÃÿ¿¿¸¸¸ºººÂÂÂÃÃÿ¿¿¾¾¾ÂÂÂÀÀÀººº¼¼¼ÌÌÌ×××ØØØÕÕÕÎÎÎÂÂÂÒÒÒÝÝÝÐÐÐÊÊÊÊÊÊÇÇÇÂÂÂÃÃÃÂÂÂÔÔÔâââÒÒÒÍÍÍÑÑÑÔÔÔÕÕÕÕÕÕÒÒÒÐÐÐÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÍÍÍÊÊÊÉÉÉÇÇÇÅÅÅÉÉÉÐÐÐÊÊÊ»»»¸¸¸ÀÀÀÃÃõµµ´´´¿¿¿ÆÆƼ¼¼µµµººº¼¼¼ÀÀÀÃÃÃÃÃÃÃÃÃÆÆÆÇÇÇÀÀÀ¸¸¸ÉÉÉ¿¿¿±±±ÒÒÒÛÛÛÑÑÑÇÇÇÒÒÒÇÇÇÕÕÕÐÐÐäääçççÝÝÝÝÝÝàààÝÝÝÜÜÜÙÙÙÕÕÕÑÑÑÍÍÍÊÊÊÉÉÉÇÇÇÉÉÉÉÉÉÊÊÊÌÌÌÊÊÊÇÇÇÅÅÅÂÂÂÉÉÉÐÐÐÑÑÑÍÍÍÉÉÉÊÊÊÍÍÍÊÊÊÉÉÉÊÊÊÍÍÍÑÑÑÑÑÑÎÎÎÊÊÊÇÇÇÅÅÅÃÃÃÆÆÆÇÇÇÉÉÉÊÊÊÎÎÎÎÎÎÎÎÎÐÐÐÑÑÑÑÑÑÑÑÑÑÑÑÐÐÐÐÐÐÐÐÐÍÍÍÌÌÌÌÌÌÌÌÌÌÌÌÍÍÍÇÇÇÐÐÐÐÐÐÇÇǾ¾¾´´´°°°´´´···¾¾¾¾¾¾······ÃÃÃÑÑÑÕÕÕÑÑÑÒÒÒÙÙÙâââçççæææßßßØØØÒÒÒÌÌÌÅÅÅÑÑÑçççæææçççÝÝÝàààÙÙÙÐÐÐÎÎÎÃÃø¸¸ÝÝÝêêêàààãããßßßäääâââÛÛÛâââããããããçççêêêêêêçççæææèèèíííóóóóóóïïïêêêãããààààààãããëëëçççäääæææêêêëëëêêêèèèæææßßßíííØØØ´´´ºººÅÅÅ¿¿¿ÆÆÆÇÇÇÇÇÇÆÆÆÃÃÃÃÃÃÆÆÆÊÊÊÇÇÇÉÉÉÌÌÌ···´´´µµµ¿¿¿ÌÌÌÌÌÌÇÇÇÂÂÂÆÆÆÑÑÑÕÕÕÑÑÑÑÑÑÐÐÐÉÉÉ»»»ÂÂÂÉÉÉÃÃÃÊÊÊÎÎÎÌÌÌÇÇÇÅÅÅÅÅÅÅÅÅÃÃÃÂÂÂÃÃÃÆÆÆÃÃþ¾¾ÂÂÂÎÎÎÕÕÕÔÔÔÎÎÎÌÌÌÅÅÅÔÔÔÝÝÝÎÎÎÇÇÇÇÇÇÇÇǼ¼¼ÅÅÅÑÑÑ×××ØØØÐÐÐÎÎÎÒÒÒÒÒÒÒÒÒÑÑÑÍÍÍÌÌÌÊÊÊÌÌÌÍÍÍÍÍÍÍÍÍÌÌÌÊÊÊÉÉÉÆÆÆÆÆÆÃÃÃÀÀÀÌÌÌÑÑÑÀÀÀ´´´»»»ÅÅÅÆÆƾ¾¾¿¿¿ÅÅÅ»»»°°°µµµ¾¾¾¾¾¾¾¾¾ÀÀÀÃÃÃÉÉÉÍÍÍÇÇǼ¼¼ÊÊÊ¿¿¿¯¯¯ÎÎÎÕÕÕÎÎÎÉÉÉÒÒÒÀÀÀ×××ÊÊÊæææàààÝÝÝßßßßßßÜÜÜÛÛÛØØØÕÕÕÑÑÑÎÎÎÌÌÌÊÊÊÊÊÊÌÌÌÍÍÍÍÍÍÊÊÊÇÇÇÆÆÆÆÆÆ¿¿¿ÃÃÃÊÊÊÐÐÐÐÐÐÎÎÎÎÎÎÎÎÎÊÊÊÃÃÿ¿¿ÅÅÅÐÐÐÕÕÕÒÒÒÌÌÌÀÀÀÂÂÂÅÅÅÆÆÆÆÆÆÆÆÆÊÊÊÍÍÍÍÍÍÎÎÎÎÎÎÐÐÐÐÐÐÑÑÑÑÑÑÑÑÑÑÑÑÐÐÐÍÍÍÊÊÊÊÊÊÌÌÌÎÎÎÐÐÐÒÒÒÐÐÐÌÌÌÇÇÇ¿¿¿³³³³³³ººº»»»¿¿¿¾¾¾···¸¸¸ÂÂÂÎÎÎÔÔÔÐÐÐÒÒÒÙÙÙàààäääæææãããààà×××ÌÌÌÀÀÀÊÊÊæææäääçççÝÝÝØØØ×××ÐÐÐÌÌÌÂÂÂÃÃÃâââíííàààÛÛÛÕÕÕÕÕÕÑÑÑÌÌÌÎÎÎÒÒÒÌÌÌÐÐÐÒÒÒÔÔÔÕÕÕÛÛÛäääíííøøøùùùöööñññèèèäääæææèèèêêêäääßßßÝÝÝâââæææèèèèèèçççßßßíííÙÙÙ³³³¸¸¸ÅÅÅ¿¿¿ÅÅÅÇÇÇÇÇÇÆÆÆÂÂÂÂÂÂÆÆÆÊÊÊÆÆÆÆÆÆÌÌ̺ºº°°°¸¸¸»»»ÇÇÇÔÔÔÎÎÎÅÅÅÀÀÀÇÇÇÔÔÔ×××ÒÒÒÐÐÐÒÒÒÇÇÇÀÀÀÍÍÍÔÔÔÎÎÎÒÒÒÒÒÒÍÍÍÍÍÍÑÑÑÐÐÐÉÉÉÅÅÅÅÅÅÊÊÊÍÍÍÊÊÊÃÃÃÀÀÀÅÅÅÉÉÉÉÉÉ¿¿¿ÅÅÅÆÆÆÛÛÛäääÕÕÕÎÎÎÍÍÍÆÆÆÂÂÂÒÒÒßßßÔÔÔÌÌÌÐÐÐÔÔÔÔÔÔÒÒÒÑÑÑÍÍÍÉÉÉÇÇÇÇÇÇÊÊÊÌÌÌÌÌÌÊÊÊÉÉÉÇÇÇÆÆÆÅÅÅÃÃÃÇÇǼ¼¼ÀÀÀÌÌÌÉÉÉ¿¿¿¼¼¼»»»ÍÍÍ»»»¾¾¾¿¿¿¾¾¾¿¿¿ÀÀÀÀÀÀÀÀÀÆÆÆÇÇÇÆÆÆÉÉÉÆÆƼ¼¼ÇÇÇ¿¿¿´´´ÕÕÕÛÛÛÔÔÔÌÌÌÐÐп¿¿ØØØÉÉÉèèèÝÝÝßßßâââßßßÜÜÜÛÛÛØØØÕÕÕÑÑÑÎÎÎÌÌÌÊÊÊÌÌÌÍÍÍÎÎÎÍÍÍÉÉÉÆÆÆÆÆÆÆÆÆ¿¿¿ÀÀÀÀÀÀÃÃÃÃÃÃÀÀÀ¼¼¼ººº······¸¸¸¾¾¾ÃÃÃÊÊÊÎÎÎÐÐп¿¿ÃÃÃÆÆÆÆÆÆÅÅÅÆÆÆÉÉÉÌÌÌÍÍÍÍÍÍÍÍÍÍÍÍÎÎÎÐÐÐÐÐÐÑÑÑÑÑÑÐÐÐÍÍÍÊÊÊÌÌÌÍÍÍÑÑÑÒÒÒ×××ÌÌÌÊÊÊÑÑÑÇÇǵµµ³³³¼¼¼¾¾¾ººº¸¸¸ººº»»»¾¾¾ÇÇÇÒÒÒÑÑÑÔÔÔØØØÝÝÝâââäääææææææÔÔÔÎÎÎÆÆÆÊÊÊèèèàààæææßßßÒÒÒÙÙÙÒÒÒÉÉÉÀÀÀÑÑÑççççççæææØØØÐÐÐÌÌÌÌÌÌÊÊÊÉÉÉÊÊÊÉÉÉÌÌÌÍÍÍÎÎÎÐÐÐÕÕÕÝÝÝäääëëëîîîñññîîîèèèææææææèèèæææßßßÕÕÕÑÑÑÕÕÕÝÝÝãããæææààà×××æææØØصµµ´´´¼¼¼»»»ÃÃÃÅÅÅÆÆÆÃÃÃÀÀÀ¿¿¿ÃÃÃÉÉÉÉÉÉÉÉÉÌÌ̸¸¸³³³ÂÂÂÇÇÇÔÔÔÒÒÒÎÎÎÆÆÆÀÀÀÃÃÃÊÊÊÍÍÍÌÌÌÉÉÉÍÍÍÅÅÅÅÅÅÔÔÔÙÙÙÕÕÕÑÑÑÀÀÀÀÀÀÇÇÇÒÒÒÔÔÔÌÌÌÇÇÇÊÊÊÊÊÊÐÐÐÐÐÐÉÉÉÀÀÀÀÀÀÆÆÆÉÉÉÍÍÍÔÔÔÒÒÒßßßãããÐÐÐÉÉÉÇÇÇÍÍÍÑÑÑßßßãããÔÔÔÍÍÍÔÔÔÔÔÔÔÔÔÒÒÒÐÐÐÌÌÌÇÇÇÆÆÆÇÇÇÉÉÉÊÊÊÉÉÉÇÇÇÆÆÆÅÅÅÃÃÃÃÃÃÂÂÂÇÇǼ¼¼¾¾¾ÆÆÆÉÉÉÉÉÉÀÀÀ³³³¿¿¿ÂÂÂÀÀÀ¿¿¿ÃÃÃÇÇÇÀÀÀ¸¸¸¾¾¾ÂÂÂÌÌÌÌÌÌÅÅÅÆÆÆÉÉÉÀÀÀÇÇÇ¿¿¿¸¸¸ÙÙÙÜÜÜ×××ÍÍÍÍÍÍÃÃÃÕÕÕÌÌÌëëëßßßââââââàààÛÛÛÛÛÛØØØÕÕÕÑÑÑÎÎÎÌÌÌÌÌÌÌÌÌÍÍÍÎÎÎÌÌÌÇÇÇÅÅÅÅÅÅÆÆÆÅÅž¾¾¼¼¼¾¾¾¼¼¼···´´´±±±µµµººº»»»»»»»»»ÀÀÀÅÅÅ¿¿¿ÃÃÃÆÆÆÅÅÅÃÃÃÆÆÆÉÉÉÉÉÉÊÊÊÊÊÊÊÊÊÌÌÌÍÍÍÎÎÎÐÐÐÑÑÑÑÑÑÎÎÎÍÍÍÌÌÌÌÌÌÎÎÎÒÒÒÔÔÔÒÒÒÉÉÉÎÎÎÙÙÙÑÑѾ¾¾µµµ¸¸¸¼¼¼······¼¼¼¾¾¾¼¼¼ÃÃÃÎÎÎÕÕÕÕÕÕ×××ÙÙÙßßßãããæææçççÒÒÒÐÐÐÌÌÌÌÌÌíííÝÝÝâââÝÝÝÔÔÔÛÛÛÒÒÒÉÉÉÂÂÂÝÝÝêêêàààèèèÙÙÙÒÒÒÐÐÐÒÒÒ×××ÑÑÑÔÔÔØØØÛÛÛÛÛÛÛÛÛÛÛÛÙÙÙÛÛÛÛÛÛàààäääêêêíííëëëêêêêêêëëëêêêâââÙÙÙ×××ÛÛÛãããèèèêêêÝÝÝ×××âââ×××¼¼¼ººº¼¼¼¿¿¿ÃÃÃÅÅÅÅÅÅÃÃÃÀÀÀÀÀÀÃÃÃÇÇÇÌÌÌÌÌÌÊÊʾ¾¾»»»ÉÉÉÔÔÔßßßÐÐÐÎÎÎÉÉÉÃÃÃÀÀÀÀÀÀÃÃÃÃÃÃÂÂÂÅÅÅÂÂÂÊÊÊÔÔÔ×××ÕÕÕÇÇǸ¸¸¼¼¼ÆÆÆÐÐÐÎÎÎÇÇÇÅÅÅÉÉÉÐÐÐÕÕÕ×××ÔÔÔÎÎÎÐÐÐÕÕÕÛÛÛÛÛÛàààØØØÙÙÙØØØÇÇÇÆÆÆÉÉÉØØØÝÝÝàààãããÜÜÜ×××ØØØÐÐÐÕÕÕÔÔÔÑÑÑÌÌÌÇÇÇÆÆÆÉÉÉÌÌÌÉÉÉÉÉÉÆÆÆÅÅÅÃÃÿ¿¿ÂÂÂÃÃÃÃÃÃÇÇÇÅÅŵµµºººÉÉÉÌÌÌÃÃÃÂÂÂÇÇÇÆÆÆÃÃÃÅÅÅÆÆÆÑÑÑÐÐÐÃÃÃÃÃÃÆÆÆ»»»ÉÉÉ¿¿¿···××××××ÕÕÕÐÐÐÎÎÎÌÌÌÎÎÎÎÎÎëëëâââäääàààâââÛÛÛÙÙÙØØØÕÕÕÑÑÑÎÎÎÍÍÍÌÌÌÌÌÌÌÌÌÊÊÊÉÉÉÆÆÆÅÅÅÃÃÃÃÃÃÀÀÀ¼¼¼ºººººº¼¼¼¾¾¾»»»¸¸¸µµµ···¸¸¸»»»¼¼¼¼¼¼¼¼¼¼¼¼¾¾¾ÂÂÂÃÃÃÀÀÀÀÀÀÆÆÆÉÉÉÉÉÉÉÉÉÉÉÉÉÉÉÉÉÉÊÊÊÍÍÍÎÎÎÐÐÐÐÐÐÎÎÎÍÍÍÍÍÍÎÎÎÐÐÐÒÒÒÕÕÕÑÑÑÍÍÍÔÔÔØØØÐÐÐÆÆÆ¿¿¿······¸¸¸»»»¾¾¾¿¿¿ÂÂÂÆÆÆÉÉÉÙÙÙ×××ÕÕÕ×××ÜÜÜâââææææææÔÔÔÑÑÑÍÍÍÊÊÊïïïÜÜÜßßßÙÙÙ×××ÕÕÕÍÍÍÌÌÌÊÊÊèèèëëëàààÝÝÝÒÒÒÔÔÔÑÑÑÒÒÒÕÕÕÎÎÎÕÕÕÎÎÎÎÎÎÑÑÑÔÔÔØØØÛÛÛÜÜÜÜÜÜßßßãããçççëëëîîîîîîîîîíííâââÝÝÝÛÛÛÜÜÜàààääääääãããÜÜÜÝÝÝàààÌÌ̼¼¼ÀÀÀÂÂÂÆÆÆÆÆÆÅÅÅÅÅÅÃÃÃÂÂÂÃÃÃÅÅÅÆÆÆÌÌÌÌÌ̾¾¾¾¾¾ÆÆÆ×××ÜÜÜÒÒÒÒÒÒÑÑÑÎÎÎÉÉÉÅÅÅÃÃÃÃÃÃÅÅÅÅÅÅÆÆÆÒÒÒÒÒÒÔÔÔ××׿¿¿¼¼¼ÅÅÅÎÎÎÑÑÑÌÌÌÆÆÆÇÇÇÍÍÍØØØ×××ÔÔÔÔÔÔÔÔÔÕÕÕØØØÙÙÙÉÉÉÑÑÑÊÊÊÐÐÐÒÒÒÌÌÌÔÔÔÝÝÝÙÙÙäääàààæææäääÙÙÙØØØÒÒÒÕÕÕÕÕÕÒÒÒÍÍÍÊÊÊÉÉÉÊÊÊÍÍÍÉÉÉÇÇÇÆÆÆÃÃÃÂÂÂÂÂÂÂÂÂÂÂÂÀÀÀÀÀÀÅÅÅÅÅÅÀÀÀÅÅÅÆÆƼ¼¼³³³ÂÂÂÆÆÆÀÀÀÅÅÅÊÊÊÐÐÐ×××ÒÒÒÌÌÌÑÑÑÐÐÐÃÃÃÃÃð°°ÍÍÍ»»»ÙÙÙØØØØØØÕÕÕÐÐÐÔÔÔÆÆÆÑÑÑèèèæææãããÛÛÛàààÛÛÛÙÙÙ×××ÕÕÕÑÑÑÐÐÐÍÍÍÌÌÌÊÊÊÉÉÉÆÆÆÅÅÅÅÅÅÃÃÃÃÃúºº¸¸¸µµµ···»»»»»»ººº···µµµµµµ···ººº¾¾¾ÀÀÀÀÀÀ¿¿¿»»»¿¿¿¿¿¿¼¼¼¿¿¿ÆÆÆÊÊÊÇÇÇÉÉÉÇÇÇÇÇÇÇÇÇÉÉÉÌÌÌÎÎÎÐÐÐÎÎÎÎÎÎÍÍÍÍÍÍÎÎÎÑÑÑÔÔÔÕÕÕÔÔÔÔÔÔÕÕÕÐÐÐÇÇÇÌÌÌÉÉɺºº³³³ººº¿¿¿¾¾¾ÀÀÀÇÇÇÉÉÉÅÅÅÜÜÜØØØÔÔÔÕÕÕÛÛÛâââäääæææÕÕÕÑÑÑÌÌÌÇÇÇñññÜÜÜÝÝÝÕÕÕÕÕÕÎÎÎÆÆÆÍÍÍÑÑÑïïïíííäääÛÛÛÕÕÕÝÝÝÛÛÛØØØØØØÐÐÐÙÙÙÕÕÕÑÑÑÍÍÍÎÎÎÔÔÔÙÙÙÜÜÜÝÝÝÝÝÝßßßãããçççêêêëëëëëëêêêÜÜÜÜÜÜßßßäääèèèèèèãããÝÝÝÕÕÕÝÝÝØØغºº³³³¿¿¿ÀÀÀÃÃÃÇÇÇÆÆÆÅÅÅÃÃÃÅÅÅÆÆÆÆÆÆÇÇÇÇÇÇÇÇǸ¸¸ººº¼¼¼¿¿¿ÑÑÑÕÕÕÛÛÛÛÛÛÛÛÛÙÙÙÕÕÕÐÐÐÊÊÊÇÇÇÍÍÍÊÊÊÍÍÍÛÛÛÔÔÔÔÔÔÛÛÛ¼¼¼¿¿¿ÊÊÊÔÔÔÔÔÔÎÎÎÎÎÎÕÕÕÜÜÜØØØÐÐÐÆÆÆÅÅÅÉÉÉÊÊÊÆÆÆÀÀÀÂÂÂÍÍÍÉÉÉÍÍÍÐÐÐÉÉÉÑÑÑÙÙÙÕÕÕæææãããêêêèèèÕÕÕÔÔÔÙÙÙ×××ÕÕÕÒÒÒÐÐÐÌÌÌÊÊÊÍÍÍÎÎÎÉÉÉÇÇÇÆÆÆÃÃÃÂÂÂÀÀÀÂÂÂÂÂÂÅÅÅ¿¿¿ÀÀÀÅÅÅÂÂÂÅÅÅÆÆÆ¿¿¿³³³¼¼¼¿¿¿ÃÃÃÊÊÊÅÅž¾¾ÀÀÀ¿¿¿···¿¿¿ÊÊÊÌÌÌ×××ØØØÃÃÃÎÎÎÆÆÆÂÂÂâââàààßßßÙÙÙÑÑÑØØØ¿¿¿ÒÒÒæææçççããã×××àààÛÛÛÙÙÙ×××ÕÕÕÑÑÑÐÐÐÍÍÍÌÌÌÉÉÉÆÆÆÃÃÃÃÃÃÃÃÃÃÃÃÂÂÂÀÀÀ¼¼¼»»»ººº»»»»»»ºººµµµ±±±···¸¸¸ººººººººº»»»¾¾¾ÀÀÀ¿¿¿ÀÀÀ¿¿¿»»»¼¼¼ÃÃÃÆÆÆÅÅÅÊÊÊÉÉÉÇÇÇÉÉÉÌÌÌÎÎÎÎÎÎÍÍÍÒÒÒÑÑÑÎÎÎÍÍÍÍÍÍÍÍÍÎÎÎÐÐÐÎÎÎÕÕÕÒÒÒÇÇÇÇÇÇÎÎÎÌÌÌÀÀÀ³³³µµµººº¼¼¼¾¾¾ÀÀÀÅÅÅÇÇÇâââÜÜÜÕÕÕÒÒÒ×××ÜÜÜàààâââ×××ÐÐÐÑÑÑÊÊÊñññàààÝÝÝÛÛÛÐÐÐÌÌÌßßßêêêèèèëëëçççêêêÛÛÛÙÙÙØØØÕÕÕÔÔÔÒÒÒÒÒÒÑÑÑÎÎÎÒÒÒÕÕÕØØØÙÙÙÙÙÙÜÜÜßßßØØØâââäääàààäääîîîëëëßßßçççßßßãããèèèæææââââââßßßÙÙÙ×××ÌÌ̼¼¼¸¸¸ÂÂÂÇÇÇÅÅÅÉÉÉÅÅÅÇÇÇÉÉÉÅÅÅÇÇÇÌÌÌÉÉÉÐÐÐÆÆƾ¾¾¿¿¿Â¿¿¿¿¿¿ÀÀÀÃÃÃÉÉÉÑÑÑÙÙÙÜÜÜØØØÒÒÒÒÒÒÑÑÑÕÕÕ×××ÑÑÑÔÔÔÎÎμ¼¼ÍÍÍØØØÍÍÍÍÍÍÕÕÕßßßßßßÆÆÆÇÇÇÇÇÇÅÅÅ¿¿¿¼¼¼ÂÂÂÅÅž¾¾ÀÀÀÆÆÆÆÆÆÃÃÃÌÌÌÜÜÜßßß×××ÙÙÙÜÜÜÝÝÝÜÜÜÙÙÙ××××××ØØØÕÕÕÑÑÑÎÎÎÎÎÎÐÐÐÑÑÑÐÐÐÎÎÎÌÌÌÉÉÉÃÃÿ¿¿¼¼¼»»»¼¼¼¾¾¾¾¾¾ÆÆÆÆÆÆÂÂÂÂÂÂÃÃÃÌÌÌÛÛÛÃÃúºº¾¾¾ÎÎÎÂÂÂÍÍÍÎÎÎÇÇÇÃÃÃÌÌÌÉÉÉÆÆÆÊÊÊÌÌÌÎÎÎÛÛÛÊÊÊÆÆƸ¸¸ßßßÙÙÙÛÛÛÍÍÍÒÒÒ×××ØØØÆÆÆããããããÛÛÛÛÛÛÔÔÔØØØÕÕÕÒÒÒÑÑÑÐÐÐÍÍÍÊÊÊÆÆÆÇÇÇÆÆÆÆÆÆÅÅÅÃÃÃÂÂÂÀÀÀ¿¿¿»»»¸¸¸¸¸¸»»»ººº´´´´´´¸¸¸ºººººººººººº»»»¼¼¼¾¾¾¿¿¿¾¾¾ÀÀÀÀÀÀ¾¾¾¿¿¿ÅÅÅÆÆÆÅÅÅÉÉÉÇÇÇÇÇÇÊÊÊÍÍÍÎÎÎÎÎÎÍÍÍÑÑÑÐÐÐÎÎÎÎÎÎÍÍÍÍÍÍÎÎÎÎÎÎÌÌÌÎÎÎÍÍÍÉÉÉÊÊÊÐÐÐÎÎÎÇÇÇ¿¿¿»»»ººº¾¾¾ÃÃÃÆÆÆÇÇÇÙÙÙÙÙÙÛÛÛÜÜÜÝÝÝÜÜÜÛÛÛÙÙÙÐÐÐÊÊÊÍÍÍÉÉÉíííÝÝÝÛÛÛØØØÐÐÐÎÎÎãããíííëëëíííæææäää×××××××××ÕÕÕÔÔÔÔÔÔÒÒÒÒÒÒÎÎÎÎÎÎÐÐÐÑÑÑÒÒÒ×××ÛÛÛßßßÝÝÝââââââßßßâââêêêëëëçççèèèâââçççîîîèèèãããàààÛÛÛÜÜÜÎÎξ¾¾¿¿¿ÂÂÂÅÅÅÇÇÇÉÉÉÅÅÅÇÇÇÉÉÉÆÆÆÉÉÉÍÍÍÊÊÊÎÎÎÅÅž¾¾ÀÀÀÅÅÅÅÅÅÅÅÅÅÅÅÃÃÃÃÃÃÅÅÅÇÇÇÌÌÌÒÒÒÙÙÙÝÝÝÕÕÕÒÒÒÔÔÔÔÔÔÒÒÒÒÒÒÌÌÌÀÀÀÉÉÉÔÔÔÌÌÌÌÌÌÑÑÑØØØàààÒÒÒÇÇÇÆÆÆÂÂÂÂÂÂÌÌÌÒÒÒÒÒÒÐÐÐÂÂÂÅÅÅÆÆÆÇÇÇÐÐÐÛÛÛÝÝÝ×××ÔÔÔÕÕÕ×××ÕÕÕÔÔÔÒÒÒÔÔÔÕÕÕÒÒÒÑÑÑÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÍÍÍÉÉÉÃÃÿ¿¿¾¾¾¾¾¾¾¾¾¾¾¾ÂÂÂÅÅÅÃÃÃÅÅÅÇÇÇÃÃÃÃÃÃÎÎÎÉÉÉ»»»»»»ÐÐÐÃÃÃÌÌÌÎÎÎÑÑÑÒÒÒÔÔÔÎÎÎÎÎÎÔÔÔÒÒÒÍÍÍÐÐÐÍÍÍÍÍÍ¿¿¿âââÛÛÛÛÛÛÐÐÐÔÔÔ×××ÙÙÙÉÉÉãããàààÙÙÙÙÙÙÔÔÔ×××ÕÕÕÒÒÒÑÑÑÐÐÐÍÍÍÉÉÉÆÆÆÆÆÆÆÆÆÅÅÅÃÃÃÂÂÂÀÀÀ¿¿¿¿¿¿»»»······ººººººµµµµµµ¸¸¸¸¸¸¸¸¸ºººººº»»»¼¼¼¿¿¿¿¿¿»»»¿¿¿ÂÂÂÀÀÀÃÃÃÆÆÆÇÇÇÅÅÅÇÇÇÇÇÇÉÉÉÌÌÌÎÎÎÐÐÐÎÎÎÍÍÍÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÍÍÍÍÍÍÉÉÉÇÇÇÇÇÇÊÊÊÍÍÍÎÎÎÎÎÎÎÎÎÇÇÇÀÀÀ»»»»»»ÂÂÂÅÅÅÃÃÃÀÀÀÐÐÐÔÔÔÙÙÙÝÝÝÜÜÜØØØÔÔÔÑÑÑÌÌÌÉÉÉÌÌÌÉÉÉçççÜÜÜÛÛÛØØØÑÑÑÒÒÒæææîîîíííîîîãããÜÜÜÔÔÔÔÔÔÕÕÕÕÕÕÕÕÕÔÔÔÒÒÒÑÑÑ×××ÕÕÕÔÔÔÔÔÔØØØßßßãããæææãããâââßßßÜÜÜÝÝÝãããêêêïïïëëëäääçççêêêæææâââßßßØØØÙÙÙÅÅŸ¸¸ÂÂÂÇÇÇÂÂÂÃÃÃÊÊÊÇÇÇÃÃÃÇÇÇÉÉÉÆÆÆÊÊÊÎÎÎÌÌÌÉÉÉ¿¿¿ººº¾¾¾ÂÂÂÃÃÃÂÂÂÂÂÂÂÂÂÃÃÃÃÃÃÂÂÂÃÃÃÊÊÊ×××âââÛÛÛÙÙÙ×××ØØØÛÛÛÔÔÔÌÌÌÌÌÌÂÂÂÊÊÊÆÆÆÆÆÆÆÆÆÇÇÇÎÎÎÊÊÊÌÌÌÊÊÊÂÂÂÆÆÆØØØÙÙÙÔÔÔÙÙÙÅÅÅÆÆÆÉÉÉÎÎÎÕÕÕÙÙÙÙÙÙ×××ÍÍÍÍÍÍÎÎÎÍÍÍÍÍÍÎÎÎÑÑÑÒÒÒÎÎÎÐÐÐÑÑÑÑÑÑÐÐÐÐÐÐÐÐÐÐÐÐÎÎÎÉÉÉÃÃÿ¿¿¿¿¿ÀÀÀ¿¿¿¿¿¿¾¾¾¿¿¿¿¿¿ÃÃÃÊÊÊÅÅÅÀÀÀÆÆÆÔÔÔÅÅÅÆÆÆÜÜÜÎÎÎÌÌÌÉÉÉÍÍÍÆÆÆÐÐÐÒÒÒÐÐÐÍÍÍÇÇÇÉÉÉÐÐÐÊÊÊÐÐÐÉÉÉäääÝÝÝßßßØØØÜÜÜ×××ÛÛÛÍÍÍâââÜÜÜ××××××ÕÕÕ×××ÔÔÔÒÒÒÑÑÑÐÐÐÍÍÍÉÉÉÆÆÆÆÆÆÅÅÅÃÃÃÂÂÂÀÀÀ¿¿¿¿¿¿¾¾¾¸¸¸µµµµµµºººººº······ººº¸¸¸¸¸¸¸¸¸ººº»»»¾¾¾¿¿¿ÀÀÀ»»»ÀÀÀÃÃÃÂÂÂÃÃÃÇÇÇÉÉÉÆÆÆÆÆÆÇÇÇÉÉÉÍÍÍÐÐÐÑÑÑÎÎÎÍÍÍÌÌÌÍÍÍÎÎÎÐÐÐÐÐÐÎÎÎÌÌÌÊÊÊÊÊÊÆÆÆÆÆÆÌÌÌÎÎÎÌÌÌÌÌÌÎÎÎÉÉÉ»»»¸¸¸¼¼¼ÀÀÀÀÀÀ¿¿¿ÉÉÉÍÍÍÑÑÑÒÒÒÑÑÑÐÐÐÐÐÐÐÐÐÐÐÐÍÍÍÎÎÎÊÊÊãããÜÜÜÜÜÜÛÛÛÒÒÒÔÔÔæææëëëèèèëëëààà×××ÕÕÕÕÕÕ×××ØØØØØØÕÕÕÒÒÒÑÑÑÒÒÒÑÑÑÐÐÐÔÔÔÙÙÙÝÝÝààààààäääßßßÛÛÛÛÛÛÙÙÙÜÜÜæææñññèèèââââââãããÝÝÝÝÝÝßßßÙÙÙÎÎο¿¿»»»ÆÆÆÌÌÌÅÅÅÃÃÃÌÌÌÇÇÇÃÃÃÇÇÇÊÊÊÇÇÇÌÌÌÐÐÐÍÍÍÃÃü¼¼¸¸¸¼¼¼ÀÀÀÀÀÀÀÀÀÂÂÂÀÀÀÂÂÂÅÅÅÆÆÆÇÇÇÌÌÌÑÑÑ×××ÎÎÎÐÐÐÌÌÌÎÎÎÔÔÔÊÊÊ¿¿¿ÅÅÅ¿¿¿ÃÃÃÆÆÆÊÊÊÌÌÌÊÊÊÍÍÍÍÍÍÇÇÇÊÊÊÂÂÂÆÆÆØØØÕÕÕÐÐÐÝÝÝÎÎÎÌÌÌÎÎÎ×××ÛÛÛØØØÕÕÕÕÕÕÌÌÌÊÊÊÉÉÉÇÇÇÇÇÇÊÊÊÍÍÍÐÐÐÍÍÍÐÐÐÒÒÒÒÒÒÑÑÑÐÐÐÑÑÑÒÒÒÑÑÑÌÌÌÃÃÃÀÀÀÂÂÂÃÃÿ¿¿···ÀÀÀÀÀÀ¾¾¾ÃÃÃÇÇÇÆÆÆÇÇÇØØØÊÊÊÂÂÂÎÎÎÂÂÂÇÇÇÌÌÌÕÕÕÜÜÜ×××ÌÌÌÅÅÅÆÆÆÌÌÌÑÑÑ×××ÊÊÊ×××ÔÔÔçççÝÝÝÜÜÜÙÙÙÙÙÙØØØÝÝÝÒÒÒâââØØØÔÔÔÔÔÔ×××ÕÕÕÒÒÒÑÑÑÐÐÐÎÎÎÍÍÍÉÉÉÆÆÆÅÅÅÅÅÅÃÃÃÂÂÂÀÀÀ¿¿¿¾¾¾¼¼¼¸¸¸´´´´´´¸¸¸ººº¸¸¸¸¸¸ººº¸¸¸¸¸¸¸¸¸ººº»»»¾¾¾¿¿¿ÀÀÀ¾¾¾ÂÂÂÅÅÅÂÂÂÀÀÀÆÆÆÉÉÉÉÉÉÅÅÅÆÆÆÉÉÉÌÌÌÐÐÐÑÑÑÐÐÐÍÍÍÊÊÊÌÌÌÎÎÎÐÐÐÐÐÐÍÍÍÊÊÊÉÉÉÎÎÎÇÇÇÆÆÆÌÌÌÌÌÌÇÇÇÅÅÅÉÉÉÎÎÎÊÊÊ»»»¸¸¸ººº¾¾¾ÂÂÂÃÃÃÆÆÆÌÌÌÍÍÍÍÍÍÎÎÎÐÐÐÑÑÑÒÒÒÐÐÐÎÎÎÊÊÊÙÙÙÙÙÙÛÛÛÙÙÙÔÔÔÑÑÑãããæææãããäääÜÜÜ×××ØØØÙÙÙÛÛÛÛÛÛØØØÕÕÕÒÒÒÑÑÑÐÐÐÑÑÑÔÔÔÙÙÙÝÝÝàààßßßÜÜÜâââÛÛÛØØØÙÙÙØØØ×××ßßßêêêâââÝÝÝàààãããßßßààààààÙÙÙÀÀÀ¿¿¿ÃÃÃÊÊÊÌÌÌÆÆÆÆÆÆÌÌÌÉÉÉÅÅÅÇÇÇÊÊÊÇÇÇÌÌÌÑÑÑÎÎξ¾¾ºººººº¿¿¿ÂÂÂÂÂÂÅÅÅÉÉÉÅÅÅÅÅÅÅÅÅÉÉÉÍÍÍÎÎÎÌÌÌÉÉÉÇÇÇÊÊÊÇÇÇÌÌÌÑÑÑÇÇǼ¼¼ÃÃÃÇÇÇÃÃÃÃÃÃÅÅÅÆÆÆÅÅÅÃÃÃÅÅÅ¿¿¿ÉÉÉÆÆÆÊÊÊ×××ÑÑÑÐÐÐããã×××ÒÒÒÕÕÕÜÜÜÝÝÝÕÕÕÑÑÑÔÔÔÎÎÎÌÌÌÉÉÉÆÆÆÇÇÇÉÉÉÌÌÌÎÎÎÌÌÌÐÐÐÒÒÒÔÔÔÒÒÒÒÒÒÒÒÒÔÔÔÕÕÕÎÎÎÆÆÆÃÃÃÃÃÃÅÅÅ¿¿¿ÀÀÀÒÒÒÎÎμ¼¼»»»ÆÆÆÌÌÌÌÌÌÐÐÐÍÍÍÅÅÅÇÇǸ¸¸ÂÂÂÂÂÂÃÃÃÊÊÊÇÇÇÉÉÉÌÌÌÐÐÐÔÔÔ×××ÕÕÕÍÍÍßßßßßßçççÛÛÛØØØÕÕÕÑÑÑÛÛÛàààØØØâââÕÕÕÔÔÔÒÒÒ×××ÔÔÔÑÑÑÐÐÐÎÎÎÎÎÎÍÍÍÉÉÉÆÆÆÅÅÅÃÃÃÃÃÿ¿¿¾¾¾¾¾¾¼¼¼···³³³±±±···ºººººº¸¸¸ººº······¸¸¸ººº»»»¾¾¾ÀÀÀ¾¾¾ÃÃÃÆÆÆÂÂÂÀÀÀÃÃÃÇÇÇÇÇÇÅÅÅÅÅÅÆÆÆÊÊÊÎÎÎÐÐÐÐÐÐÎÎÎÊÊÊÌÌÌÍÍÍÎÎÎÎÎÎÍÍÍÊÊÊÉÉÉÎÎÎÉÉÉÆÆÆÉÉÉÉÉÉÃÃÃÂÂÂÃÃÃÎÎÎÑÑÑÑÑÑÍÍÍÆÆƾ¾¾ººº¸¸¸¾¾¾ÃÃÃÉÉÉÎÎÎÐÐÐÐÐÐÐÐÐÐÐÐÎÎÎÎÎÎÍÍÍÉÉÉÑÑÑÔÔÔ×××ÕÕÕÔÔÔÎÎÎßßßäääàààßßßÙÙÙÛÛÛÛÛÛÛÛÛÛÛÛÙÙÙØØØÕÕÕÒÒÒÑÑÑÔÔÔ×××ÛÛÛßßßããããããâââàààÝÝÝÙÙÙØØØÙÙÙÙÙÙÕÕÕØØØßßßÙÙÙÛÛÛâââçççäääæææããã×××¼¼¼ÃÃÃÊÊÊÍÍÍÊÊÊÊÊÊÊÊÊÌÌÌÊÊÊÆÆÆÉÉÉÌÌÌÉÉÉÌÌÌÑÑÑÎÎδ´´´´´¸¸¸¼¼¼¼¼¼¼¼¼ÂÂÂÉÉÉÊÊÊÇÇÇÅÅÅÆÆÆÌÌÌÍÍÍÊÊÊÆÆÆÉÉÉÌÌÌÌÌÌÎÎÎÑÑÑÌÌÌÇÇÇÉÉÉÉÉÉÀÀÀ¿¿¿»»»¼¼¼ÂÂÂÀÀÀÅÅÅÇÇÇÒÒÒÔÔÔÒÒÒÕÕÕÐÐÐÑÑÑàààÛÛÛ×××ØØØÛÛÛÙÙÙÒÒÒÐÐÐÑÑÑÐÐÐÍÍÍÉÉÉÇÇÇÉÉÉÌÌÌÍÍÍÎÎÎÎÎÎÐÐÐÒÒÒÔÔÔÔÔÔÕÕÕ××××××ØØØÒÒÒÊÊÊÆÆÆÅÅÅÃÃÃÂÂÂÀÀÀÑÑÑãããÛÛÛÀÀÀºººÃÃÃÉÉÉÊÊÊÅÅÅÐÐÐÐÐÐÔÔÔÉÉÉÐÐÐÆÆÆÀÀÀ»»»ÀÀÀÍÍÍÔÔÔÑÑÑÐÐÐÑÑÑÎÎÎÉÉÉÝÝÝàààâââØØØÙÙÙÜÜÜÕÕÕßßßãããÜÜÜâââÒÒÒÕÕÕÑÑÑ×××ÒÒÒÐÐÐÎÎÎÎÎÎÎÎÎÌÌÌÉÉÉÆÆÆÅÅÅÃÃÃÃÃÃÂÂÂÀÀÀ¿¿¿¾¾¾¼¼¼¸¸¸³³³±±±···ºººººº¸¸¸¸¸¸······¸¸¸ººº»»»¾¾¾ÀÀÀ¼¼¼ÅÅÅÇÇÇÅÅÅÀÀÀÂÂÂÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÇÇÇÌÌÌÎÎÎÐÐÐÎÎÎÊÊÊÌÌÌÍÍÍÍÍÍÍÍÍÌÌÌÊÊÊÉÉÉÉÉÉÆÆÆÅÅÅÆÆÆÆÆÆÅÅÅÃÃÃÂÂÂÊÊÊÎÎÎÒÒÒÔÔÔÐÐÐÇÇÇ»»»´´´¼¼¼¿¿¿ÃÃÃÉÉÉÌÌÌÍÍÍÌÌÌÉÉÉÊÊÊÍÍÍÎÎÎÍÍÍÑÑÑ×××ØØØÔÔÔÒÒÒÌÌÌÝÝÝèèèâââÛÛÛØØØàààØØØØØØ××××××ÕÕÕÔÔÔÒÒÒÑÑÑÕÕÕÕÕÕ×××ØØØÙÙÙÛÛÛÝÝÝßßßÝÝÝÛÛÛÙÙÙÙÙÙÙÙÙØØØ××××××ÕÕÕ×××ÝÝÝàààßßßâââàààÔÔÔÃÃÃÆÆÆÉÉÉÌÌÌÌÌÌÍÍÍÍÍÍÍÍÍÌÌÌÇÇÇÊÊÊÍÍÍÉÉÉÌÌÌÐÐÐÍÍÍ»»»¾¾¾ÂÂÂÃÃü¼¼···¼¼¼ÆÆÆÉÉÉÇÇÇÆÆÆÅÅÅÆÆÆÇÇÇÉÉÉÉÉÉÃÃÃÃÃÃÆÆÆÆÆÆÃÃÃÇÇÇÊÊÊÆÆÆÅÅÅÅÅÅÎÎÎÊÊÊÌÌÌÕÕÕ×××ßßßÔÔÔÛÛÛÝÝÝØØØÔÔÔÑÑÑÒÒÒÕÕÕÙÙÙ×××ÕÕÕÕÕÕÒÒÒÐÐÐÐÐÐÑÑÑÐÐÐÌÌÌÉÉÉÉÉÉÌÌÌÎÎÎÐÐÐÐÐÐÑÑÑÑÑÑÑÑÑÒÒÒÕÕÕØØØÙÙÙÙÙÙÙÙÙÕÕÕÎÎÎÉÉÉÅÅÅÂÂÂÀÀÀÀÀÀÑÑÑØØØÐÐп¿¿¾¾¾ÂÂÂÆÆÆÌÌÌÅÅÅÌÌÌÊÊÊÒÒÒÎÎÎÛÛÛÛÛÛàààæææØØØÐÐÐÍÍÍÍÍÍÒÒÒÕÕÕÍÍÍÊÊÊààààààÛÛÛÕÕÕÙÙÙãããÜÜÜãããæææààààààÒÒÒ×××ÑÑÑ×××ÑÑÑÐÐÐÎÎÎÍÍÍÍÍÍÌÌÌÉÉÉÆÆÆÅÅÅÅÅÅÃÃÃÂÂÂÀÀÀ¿¿¿¾¾¾¾¾¾¸¸¸³³³±±±µµµººº¸¸¸······µµµ······ººº»»»¿¿¿ÀÀÀ»»»ÃÃÃÉÉÉÆÆÆÂÂÂÂÂÂÂÂÂÀÀÀÅÅÅÃÃÃÃÃÃÆÆÆÊÊÊÎÎÎÐÐÐÎÎÎÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÊÊÊÉÉÉÅÅÅÃÃÃÂÂÂÃÃÃÅÅÅÆÆÆÆÆÆÃÃÃÐÐÐÊÊÊÅÅÅÅÅÅÇÇÇÉÉÉÅÅÅ¿¿¿¼¼¼»»»»»»¾¾¾ÂÂÂÅÅÅÅÅÅÃÃÃÉÉÉÍÍÍÒÒÒÔÔÔÕÕÕÛÛÛÜÜÜ×××ÑÑÑÉÉÉÝÝÝíííäääÙÙÙØØØäääÕÕÕÔÔÔÔÔÔÒÒÒÒÒÒÒÒÒÒÒÒÒÒÒÝÝÝÝÝÝÛÛÛØØØØØØÛÛÛâââèèèàààÝÝÝÛÛÛÙÙÙÙÙÙÙÙÙ×××ÔÔÔ×××ÔÔÔÕÕÕÔÔÔÑÑÑØØØÜÜÜÒÒÒÍÍÍÆÆÆÅÅÅÊÊÊÎÎÎÎÎÎÎÎÎÐÐÐÍÍÍÉÉÉÌÌÌÍÍÍÉÉÉÌÌÌÐÐÐÍÍÍÑÑÑÕÕÕØØØÒÒÒÅÅÅ»»»¾¾¾ÇÇÇÂÂÂÅÅÅÇÇÇÇÇÇÃÃÃÃÃÃÆÆÆÊÊÊÆÆÆÃÃÃÇÇÇÅÅž¾¾ÉÉÉÑÑÑÊÊÊÎÎÎ×××çççÜÜÜÒÒÒÔÔÔÍÍÍÒÒÒÔÔÔØØØÛÛÛ×××ÔÔÔØØØÙÙÙÔÔÔÕÕÕÕÕÕÒÒÒÐÐÐÎÎÎÎÎÎÐÐÐÐÐÐÍÍÍÊÊÊÉÉÉÊÊÊÍÍÍÑÑÑÒÒÒÒÒÒÔÔÔÑÑÑÑÑÑÒÒÒ×××ÛÛÛÛÛÛÛÛÛÛÛÛØØØÑÑÑÊÊÊÃÃÃÀÀÀÀÀÀÀÀÀÂÂÂÀÀÀ»»»»»»ÀÀÀÂÂÂÃÃÃÎÎÎÑÑÑÑÑÑÌÌÌÔÔÔÊÊÊÍÍÍÊÊÊÕÕÕÒÒÒÌÌÌÐÐÐÑÑÑÎÎÎÒÒÒÙÙÙÕÕÕÙÙÙëëëæææØØØÐÐÐÔÔÔßßß×××æææçççâââàààÒÒÒØØØÑÑÑ×××ÑÑÑÎÎÎÍÍÍÍÍÍÍÍÍÌÌÌÉÉÉÆÆÆÅÅÅÅÅÅÃÃÃÂÂÂÀÀÀ¿¿¿¾¾¾¾¾¾ººº³³³±±±µµµººº¸¸¸···µµµµµµ······ººº¼¼¼¿¿¿ÀÀÀÃÃÃÂÂÂÂÂÂÆÆÆÂÂÂÇÇÇÇÇǼ¼¼ÃÃÃÃÃÃÅÅÅÀÀÀÃÃÃÍÍÍÐÐÐÍÍÍÎÎÎÇÇÇÉÉÉÌÌÌÍÍÍÎÎÎÍÍÍÊÊÊÉÉÉÆÆÆÃÃÃÃÃÃÆÆÆÅÅÅÀÀÀÂÂÂÉÉÉÆÆÆÅÅÅÃÃÃÂÂÂÃÃÃÇÇÇÊÊÊÍÍÍÅÅÅÊÊÊÍÍÍÌÌÌÇÇÇÃÃÃÀÀÀ¿¿¿ÆÆÆÆÆÆÌÌÌÒÒÒÙÙÙÝÝÝÜÜÜ×××ÌÌÌÐÐÐÙÙÙâââßßß×××ÔÔÔÕÕÕÝÝÝÛÛÛØØØÕÕÕÔÔÔÒÒÒÑÑÑÐÐÐÙÙÙÙÙÙÛÛÛÝÝÝßßßààààààààà×××ØØØÙÙÙØØØÕÕÕÔÔÔÒÒÒÑÑÑÊÊÊÐÐÐãããßßßÔÔÔ×××ÕÕÕÕÕÕÔÔÔÃÃþ¾¾ÊÊÊÎÎÎÆÆÆÇÇÇÑÑÑÎÎÎÊÊÊÇÇÇÆÆÆÇÇÇÉÉÉÇÇÇÇÇÇÇÇÇÆÆÆÉÉÉÌÌÌÇÇÇÀÀÀÅÅÅÎÎÎÑÑÑÔÔÔÔÔÔÍÍÍÊÊÊÎÎÎÕÕÕ×××ÙÙÙßßßÒÒÒÂÂÂÅÅÅÊÊÊÊÊÊÍÍÍâââ×××ÐÐÐÐÐÐÐÐÐÍÍÍÎÎÎÔÔÔÒÒÒÔÔÔ××××××ÕÕÕÔÔÔÔÔÔÔÔÔÒÒÒÒÒÒÑÑÑÑÑÑÐÐÐÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÐÐÐÐÐÐÑÑÑÔÔÔÕÕÕ×××ÔÔÔÔÔÔÔÔÔ×××ØØØÙÙÙ×××ÔÔÔÜÜÜÙÙÙÒÒÒÒÒÒÛÛÛâââÝÝÝÔÔÔÃÃÿ¿¿¾¾¾ÀÀÀÂÂÂÂÂÂÆÆÆÊÊÊÍÍÍÐÐÐÒÒÒÑÑÑÎÎÎÌÌÌÊÊÊÌÌÌÊÊÊÌÌÌÌÌÌÍÍÍÎÎÎÒÒÒÒÒÒÒÒÒëëëÛÛÛßßßØØØÒÒÒÜÜÜÙÙÙÛÛÛêêêàààêêê×××ÑÑÑÐÐÐÔÔÔÍÍÍÑÑÑÐÐÐÎÎÎÍÍÍÌÌÌÊÊÊÉÉÉÇÇÇÀÀÀ¿¿¿ÃÃÃÃÃþ¾¾ÀÀÀ¿¿¿´´´µµµ¯¯¯³³³ººº···µµµºººººº»»»´´´³³³···»»»¼¼¼ÂÂÂÇÇÇÆÆÆÅÅÅÇÇÇÂÂÂÆÆÆÇÇÇ¿¿¿ÇÇÇÃÃÃÅÅÅÀÀÀÂÂÂÌÌÌÎÎÎÍÍÍÐÐÐÎÎÎÎÎÎÐÐÐÎÎÎÍÍÍÉÉÉÅÅÅÃÃÃÆÆÆÃÃÃÅÅÅÇÇÇÅÅÅÀÀÀÂÂÂÆÆÆÅÅÅÃÃÃÀÀÀÀÀÀÀÀÀÃÃÃÆÆÆÉÉÉÇÇÇÉÉÉÉÉÉÉÉÉÉÉÉÌÌÌÒÒÒ×××ÔÔÔÕÕÕÙÙÙÜÜÜÜÜÜØØØÑÑÑÍÍÍÊÊÊÎÎÎ×××ÜÜÜÙÙÙÒÒÒÐÐÐÒÒÒÑÑÑÒÒÒÒÒÒÑÑÑÎÎÎÍÍÍÐÐÐÒÒÒÕÕÕ×××××××××ØØØØØØÛÛÛÜÜÜÝÝÝÝÝÝÜÜÜØØØÔÔÔÎÎÎÌÌÌÉÉÉÎÎÎÒÒÒæææäääÝÝÝàààÛÛÛ×××ÍÍÍ¿¿¿ÉÉÉÍÍÍÇÇÇÇÇÇÐÐÐÍÍÍÊÊÊÆÆÆÅÅÅÆÆÆÇÇÇÇÇÇÆÆÆÊÊÊÊÊÊÌÌÌÍÍÍÌÌÌÌÌÌÑÑÑ×××ÛÛÛßßßÝÝÝ×××ÑÑÑÒÒÒ×××ØØØÔÔÔÛÛÛÔÔÔÊÊÊÒÒÒÝÝÝâââäääÜÜÜÙÙÙØØØÙÙÙÙÙÙÕÕÕÑÑÑÐÐÐÒÒÒÔÔÔÔÔÔÔÔÔÑÑÑÑÑÑÒÒÒÔÔÔÑÑÑÑÑÑÑÑÑÐÐÐÐÐÐÐÐÐÐÐÐÎÎÎÑÑÑÑÑÑÑÑÑÒÒÒÔÔÔÕÕÕØØØØØØ×××ÕÕÕÕÕÕ×××ØØØÙÙÙÙÙÙÙÙÙÙÙÙÕÕÕÐÐÐÑÑÑÛÛÛææææææßßßÔÔÔÇÇÇ¿¿¿ÂÂÂÉÉÉÊÊÊÊÊÊÊÊÊÎÎÎÐÐÐÑÑÑÑÑÑÎÎÎÍÍÍÊÊÊÊÊÊÌÌÌÌÌÌÍÍÍÎÎÎÍÍÍÉÉÉÅÅÅÃÃÃèèèàààçççÝÝÝÕÕÕÜÜÜßßßäääíííâââêêêÕÕÕÑÑÑÐÐÐÕÕÕÐÐÐÒÒÒÑÑÑÐÐÐÎÎÎÌÌÌÊÊÊÉÉÉÉÉÉÃÃÃÀÀÀÃÃþ¾¾ÀÀÀÀÀÀ······°°°´´´»»»······»»»ººº´´´±±±³³³¸¸¸»»»»»»¾¾¾ÂÂÂÉÉÉÇÇÇÇÇÇÀÀÀÅÅÅÇÇÇÀÀÀÊÊÊÃÃÃÃÃþ¾¾¿¿¿ÊÊÊÎÎÎÍÍÍÐÐÐÑÑÑÑÑÑÑÑÑÐÐÐÌÌÌÇÇÇÃÃÿ¿¿ÅÅÅÅÅÅÅÅÅÆÆÆÅÅÅÀÀÀÂÂÂÅÅÅÃÃÿ¿¿¾¾¾¾¾¾¿¿¿ÂÂÂÃÃÃÉÉÉÅÅÅÀÀÀ¼¼¼»»»»»»ÀÀÀÅÅÅÊÊÊÌÌÌÍÍÍÑÑÑÔÔÔÒÒÒÐÐÐÑÑÑÊÊÊÎÎÎÕÕÕÜÜÜÛÛÛÔÔÔÔÔÔØØØÕÕÕØØØÙÙÙÔÔÔÊÊÊÆÆÆÉÉÉÍÍÍÌÌÌÍÍÍÐÐÐÐÐÐÎÎÎÑÑÑÕÕÕÙÙÙÛÛÛØØØ×××ÕÕÕÒÒÒÎÎÎÊÊÊÉÉÉÐÐÐÑÑÑâââãããßßßâââ×××ÌÌÌÅÅÅÀÀÀÂÂÂÆÆÆÉÉÉÇÇÇÉÉÉÍÍÍÊÊÊÉÉÉÅÅÅÃÃÃÅÅÅÅÅÅÅÅÅÅÅÅÇÇÇÊÊÊÉÉÉÉÉÉÊÊÊÑÑÑÕÕÕ×××ÐÐÐ×××ØØØÔÔÔÑÑÑÔÔÔ××××××ÙÙÙßßßØØØÎÎÎÑÑÑÙÙÙÜÜÜÝÝÝÙÙÙØØØÔÔÔÑÑÑÑÑÑÒÒÒÒÒÒÑÑÑÒÒÒÒÒÒÑÑÑÎÎÎÌÌÌÍÍÍÐÐÐÔÔÔÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÑÑÑÑÑÑÑÑÑÔÔÔÔÔÔÔÔÔÕÕÕ×××ØØØÛÛÛÜÜÜÙÙÙÙÙÙÙÙÙØØØØØØÙÙÙÛÛÛÝÝÝÛÛÛÕÕÕÐÐÐÑÑÑÛÛÛäääçççãããØØØÌÌÌÂÂÂÃÃÃÊÊÊÍÍÍÎÎÎÎÎÎÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÎÎÎÌÌÌÉÉÉÎÎÎÇÇÇÅÅÅÉÉÉÉÉÉÉÉÉÍÍÍÕÕÕßßßÝÝÝäääÜÜÜÑÑÑÕÕÕÝÝÝçççîîîãããêêêÔÔÔÒÒÒÑÑÑÕÕÕÔÔÔÒÒÒÒÒÒÑÑÑÐÐÐÍÍÍÌÌÌÊÊÊÊÊÊÆÆÆÃÃÃÃÃþ¾¾ÂÂÂÃÃúºº···³³³µµµ¾¾¾···ººº»»»ººº°°°´´´ººº¾¾¾¿¿¿»»»»»»ÀÀÀÇÇÇÇÇÇÉÉÉÀÀÀÃÃÃÆÆÆ¿¿¿ÉÉɼ¼¼¾¾¾ÉÉÉÍÍÍÍÍÍÑÑÑÍÍÍÎÎÎÎÎÎÎÎÎÍÍÍÉÉÉÆÆÆÃÃÃÂÂÂÂÂÂÂÂÂÂÂÂÀÀÀ¿¿¿ÂÂÂÅÅÅÂÂÂÀÀÀ¿¿¿¼¼¼¼¼¼¾¾¾¿¿¿¿¿¿ÀÀÀ¿¿¿ÂÂÂÊÊÊÑÑÑÕÕÕÙÙÙÝÝÝÛÛÛÕÕÕÊÊÊÉÉÉÎÎÎÎÎÎÌÌÌÎÎÎÐÐÐÔÔÔÜÜÜããããããÝÝÝÝÝÝâââààààààßßßÙÙÙÒÒÒÍÍÍÍÍÍÎÎÎÌÌÌÐÐÐÑÑÑÐÐÐÌÌÌÌÌÌÎÎÎÒÒÒÑÑÑÎÎÎÐÐÐÔÔÔÕÕÕÕÕÕÕÕÕ×××ßßßÛÛÛçççèèèçççêêêÛÛÛÌÌ̾¾¾ÀÀÀÃÃÃÅÅÅÇÇÇÉÉÉÊÊÊÊÊÊÉÉÉÇÇÇÅÅÅÃÃÃÃÃÃÃÃÃÅÅÅÅÅÅÇÇÇÊÊÊÊÊÊÇÇÇÊÊÊÒÒÒÒÒÒÎÎÎÃÃÃÌÌÌÒÒÒÑÑÑÑÑÑÔÔÔÕÕÕÕÕÕÐÐÐÕÕÕÒÒÒÊÊÊÎÎÎÙÙÙßßßÝÝÝØØØØØØÒÒÒÊÊÊÊÊÊÑÑÑÕÕÕÒÒÒÒÒÒÑÑÑÍÍÍÉÉÉÆÆÆÉÉÉÎÎÎÒÒÒÎÎÎÎÎÎÎÎÎÐÐÐÑÑÑÑÑÑÒÒÒÒÒÒ×××××××××ØØØÙÙÙÛÛÛÝÝÝÝÝÝÝÝÝÝÝÝÝÝÝÜÜÜÙÙÙØØØÛÛÛÜÜÜßßßÙÙÙÔÔÔÔÔÔØØØÝÝÝÝÝÝÛÛÛÍÍÍÉÉÉÆÆÆÇÇÇÉÉÉÊÊÊÎÎÎÕÕÕÑÑÑÐÐÐÐÐÐÐÐÐÑÑÑÐÐÐÌÌÌÉÉÉÅÅÅÂÂÂÉÉÉ×××ÛÛÛ×××ÙÙÙãããÛÛÛÜÜÜßßßÙÙÙÒÒÒÔÔÔÝÝÝçççîîîäääêêêÒÒÒÔÔÔÒÒÒ××××××ÔÔÔÔÔÔÒÒÒÑÑÑÎÎÎÍÍÍÌÌÌÊÊÊÇÇÇÅÅÅÅÅÅÃÃÃÀÀÀÅÅÅÅÅźºº···µµµ···ÀÀÀ···¾¾¾»»»ººº±±±¼¼¼ÂÂÂÅÅÅÅÅÅ¿¿¿¼¼¼ÃÃÃÂÂÂÅÅÅÇÇÇÀÀÀºººÃÃÃÀÀÀ¼¼¼¼¼¼ÇÇÇÍÍÍÍÍÍÑÑÑÊÊÊÌÌÌÍÍÍÎÎÎÍÍÍÊÊÊÇÇÇÆÆÆ¿¿¿¿¿¿¿¿¿¼¼¼»»»¿¿¿ÃÃÃÇÇÇÂÂÂÀÀÀ¿¿¿¾¾¾¼¼¼¼¼¼¾¾¾¾¾¾¼¼¼ººº¼¼¼ÇÇÇÎÎÎÎÎÎÎÎÎÑÑÑäääØØØÇÇÇÃÃÃÍÍÍÉÉÉÀÀÀÃÃÃØØØÜÜÜäääêêêèèèàààÝÝÝàààÝÝÝÛÛÛØØØØØØÜÜÜÝÝÝÜÜÜÛÛÛÙÙÙÝÝÝßßßÜÜÜÕÕÕÎÎÎÍÍÍÎÎÎÕÕÕÒÒÒÔÔÔÛÛÛÝÝÝÝÝÝàààäääæææÝÝÝççççççèèèîîîàààÑÑÑ»»»¿¿¿ÃÃÃÅÅÅÆÆÆÊÊÊÊÊÊÉÉÉÉÉÉÇÇÇÆÆÆÃÃÃÂÂÂÃÃÃÃÃÃÅÅÅÍÍÍÑÑÑÑÑÑÎÎÎÑÑÑÕÕÕÑÑÑÉÉÉÉÉÉÒÒÒÙÙÙÙÙÙ×××ØØØØØØÕÕÕÎÎÎÒÒÒÒÒÒÎÎÎÒÒÒàààèèèæææ×××ÛÛÛÙÙÙÔÔÔÒÒÒ××××××ÒÒÒÒÒÒÐÐÐÌÌÌÆÆÆÅÅÅÆÆÆÌÌÌÐÐÐÍÍÍÍÍÍÎÎÎÐÐÐÑÑÑÑÑÑÒÒÒÒÒÒØØØØØØØØØÙÙÙÛÛÛÜÜÜÝÝÝßßßßßßââââââàààÜÜÜØØØØØØØØØßßßÛÛÛ×××ÕÕÕÕÕÕÕÕÕÔÔÔÒÒÒÌÌÌÉÉÉÊÊÊÎÎÎÐÐÐÎÎÎÐÐÐÔÔÔÒÒÒÑÑÑÐÐÐÑÑÑÒÒÒÑÑÑÍÍÍÉÉÉÉÉÉÉÉÉÒÒÒâââäääÜÜÜÜÜÜäääããããããÜÜÜÛÛÛÛÛÛÜÜÜãããçççëëëæææêêêÔÔÔ×××ÔÔÔÕÕÕ×××ÕÕÕÔÔÔÒÒÒÑÑÑÐÐÐÍÍÍÌÌÌÌÌÌÇÇÇÅÅÅÆÆÆÆÆÆÅÅÅÇÇÇÅÅÅ···¸¸¸ººº¸¸¸ÃÃ÷··ÀÀÀ¼¼¼ººº´´´ÂÂÂÇÇÇÅÅÅÆÆÆÀÀÀ¼¼¼ÃÃþ¾¾ÂÂÂÇÇÇÂÂÂÂÂÂÀÀÀ···¿¿¿¿¿¿ÀÀÀ¼¼¼¾¾¾ÉÉÉÎÎÎÍÍÍÑÑÑÍÍÍÍÍÍÎÎÎÎÎÎÍÍÍÉÉÉÆÆÆÃÃþ¾¾ÀÀÀ¿¿¿¼¼¼»»»¿¿¿ÅÅÅÆÆÆÀÀÀ¿¿¿¾¾¾¾¾¾¼¼¼¼¼¼¼¼¼¾¾¾¿¿¿¸¸¸ºººÇÇÇÒÒÒÕÕÕ×××ÛÛÛÒÒÒÎÎÎÂÂÂÅÅÅÑÑÑÌÌÌÀÀÀÇÇÇàààãããçççêêêãããÙÙÙÕÕÕ×××ØØØÔÔÔÑÑÑÕÕÕÝÝÝãããâââÝÝÝÜÜÜàààääääääâââÝÝÝÜÜÜÜÜÜãããààààààæææãããßßßâââèèèâââÛÛÛããããããäääíííâââ×××¾¾¾¿¿¿ÂÂÂÅÅÅÉÉÉÊÊÊÊÊÊÉÉÉÉÉÉÉÉÉÇÇÇÅÅÅÃÃÃÃÃÃÅÅÅÇÇÇÍÍÍÎÎÎÐÐÐÑÑÑÑÑÑÑÑÑÊÊÊÃÃÃÉÉÉÔÔÔÛÛÛÜÜÜÛÛÛÜÜÜÜÜÜÙÙÙØØØÙÙÙØØØÑÑÑÐÐÐÛÛÛãããÝÝÝØØØÙÙÙØØØÒÒÒÐÐÐÑÑÑÔÔÔÔÔÔÑÑÑÐÐÐÌÌÌÇÇÇÅÅÅÆÆÆÊÊÊÎÎÎÍÍÍÎÎÎÎÎÎÐÐÐÑÑÑÑÑÑÒÒÒÒÒÒ××××××ØØØØØØÙÙÙÜÜÜÝÝÝßßßàààââââââàààÝÝÝÙÙÙ×××ÕÕÕÙÙÙÕÕÕÔÔÔÔÔÔÔÔÔÑÑÑÑÑÑÒÒÒØØØÑÑÑÎÎÎ×××ÜÜÜÛÛÛÒÒÒÎÎÎÒÒÒÒÒÒÒÒÒÔÔÔÒÒÒÑÑÑÎÎÎÌÌÌÍÍÍÍÍÍÕÕÕÝÝÝßßßÛÛÛÝÝÝäääääääää××××××ÜÜÜÜÜÜààààààçççäääêêêÕÕÕÙÙÙÕÕÕÔÔÔÕÕÕÕÕÕÕÕÕÔÔÔÑÑÑÐÐÐÎÎÎÍÍÍÌÌÌÇÇÇÅÅÅÆÆÆÇÇÇÆÆÆÉÉÉÅÅÅ···¸¸¸¼¼¼ºººÆÆƵµµÃÃü¼¼ººº³³³ÅÅÅÆÆÆÂÂÂÅÅÅ¿¿¿ºººÀÀÀ¼¼¼ÂÂÂÇÇÇ¿¿¿µµµ¾¾¾¾¾¾ÀÀÀ¼¼¼¿¿¿ÌÌÌÎÎÎÍÍÍÑÑÑÍÍÍÎÎÎÎÎÎÎÎÎÍÍÍÉÉÉÆÆÆÃÃÃÀÀÀÅÅÅÅÅÅÀÀÀ¿¿¿ÂÂÂÃÃþ¾¾¼¼¼¼¼¼¼¼¼»»»»»»»»»¼¼¼ººº±±±´´´ÅÅÅÒÒÒÕÕÕØØØÜÜÜØØØÛÛÛÕÕÕ×××ÜÜÜÐÐÐÇÇÇ×××äääãããäääãããÜÜÜÒÒÒÑÑÑÔÔÔÙÙÙ×××ÔÔÔÕÕÕÙÙÙÜÜÜÛÛÛÙÙÙ×××ÙÙÙÝÝÝâââããããããããããããäääâââãããæææâââÙÙÙÝÝÝèèèêêêäääíííëëëêêêïïïçççÜÜÜÃÃÃÀÀÀÀÀÀÆÆÆÊÊÊÌÌÌÊÊÊÊÊÊÊÊÊÊÊÊÉÉÉÇÇÇÅÅÅÃÃÃÆÆÆÉÉÉÉÉÉÉÉÉÌÌÌÐÐÐÑÑÑÍÍÍÉÉÉÇÇÇÇÇÇÑÑÑÙÙÙÛÛÛÙÙÙÛÛÛÙÙÙØØØÔÔÔÒÒÒÒÒÒÍÍÍÌÌÌÙÙÙæææàààÙÙÙ×××ÔÔÔÐÐÐÍÍÍÊÊÊÎÎÎÔÔÔÐÐÐÎÎÎÍÍÍÉÉÉÆÆÆÆÆÆÉÉÉÌÌÌÎÎÎÎÎÎÐÐÐÐÐÐÑÑÑÑÑÑÑÑÑÒÒÒÕÕÕÕÕÕ××××××ØØØÛÛÛÜÜÜÝÝÝàààßßßÝÝÝÝÝÝÜÜÜÛÛÛØØØ××××××ÒÒÒÑÑÑÒÒÒÒÒÒÑÑÑÔÔÔØØØÜÜÜÕÕÕÔÔÔÜÜÜãããßßßØØØÒÒÒÔÔÔÕÕÕ×××ÕÕÕÔÔÔÑÑÑÐÐÐÎÎÎÃÃÃÍÍÍÙÙÙââââââÝÝÝÛÛÛÜÜÜâââæææÕÕÕÔÔÔÙÙÙ×××ÛÛÛÜÜÜâââãããêêê×××ÝÝÝ×××ÑÑÑÒÒÒÕÕÕÔÔÔÒÒÒÑÑÑÐÐÐÍÍÍÌÌÌÌÌÌÊÊÊÅÅÅÅÅÅÆÆÆÅÅÅÉÉÉÆÆƸ¸¸¸¸¸¿¿¿»»»ÉÉɵµµÆÆƼ¼¼ººº´´´ÇÇÇÉÉÉÃÃÃÉÉɸ¸¸¾¾¾¾¾¾ÃÃÃÉÉÉÂÂÂÀÀÀ¿¿¿µµµ¿¿¿¾¾¾ÀÀÀ¾¾¾ÀÀÀÍÍÍÐÐÐÍÍÍÐÐÐÊÊÊÌÌÌÍÍÍÎÎÎÍÍÍÊÊÊÇÇÇÆÆÆÃÃÃÉÉÉÊÊÊÆÆÆÃÃÃÅÅÅÃÃÿ¿¿»»»»»»»»»ººººººººº»»»»»»µµµ¯¯¯³³³ÆÆÆÔÔÔÔÔÔÒÒÒÔÔÔÕÕÕÝÝÝÛÛÛØØØØØØÊÊÊÌÌÌäääãããâââàààßßßØØØÒÒÒÔÔÔÛÛÛ×××ØØØØØØØØØ×××ØØØÙÙÙÛÛÛØØØØØØÙÙÙÙÙÙÛÛÛÛÛÛÙÙÙØØØÙÙÙØØØÛÛÛàààÛÛÛÔÔÔÛÛÛèèèëëëæææïïïëëëæææèèèÝÝÝÔÔÔÇÇÇÀÀÀ¿¿¿ÇÇÇÍÍÍÌÌÌÊÊÊÌÌÌÊÊÊÌÌÌÊÊÊÉÉÉÅÅÅÅÅÅÇÇÇÊÊÊÍÍÍÊÊÊÍÍÍÔÔÔ×××ÑÑÑÑÑÑÔÔÔÒÒÒÛÛÛàààÝÝÝÙÙÙ×××ÔÔÔÑÑÑÕÕÕÔÔÔÒÒÒÎÎÎÌÌÌÜÜÜèèèããã××××××ÛÛÛßßßÛÛÛÑÑÑÍÍÍÐÐÐÎÎÎÎÎÎÎÎÎÌÌÌÉÉÉÇÇÇÉÉÉÊÊÊÎÎÎÐÐÐÐÐÐÐÐÐÐÐÐÑÑÑÑÑÑÑÑÑÕÕÕÕÕÕÕÕÕÕÕÕØØØÙÙÙÛÛÛÜÜÜàààÝÝÝÛÛÛÙÙÙÛÛÛÜÜÜÛÛÛÙÙÙØØØÒÒÒÐÐÐÑÑÑÑÑÑÐÐÐÕÕÕÜÜÜÔÔÔÔÔÔØØØßßßàààÜÜÜÛÛÛÜÜÜÔÔÔÕÕÕØØØ×××ÔÔÔÑÑÑÐÐÐÑÑÑÐÐÐ×××ÜÜÜÜÜÜÙÙÙÙÙÙÛÛÛÜÜÜæææíííÜÜÜÙÙÙÜÜÜ×××ÝÝÝàààßßßãããëëëØØØàààØØØÐÐÐÐÐÐÕÕÕÔÔÔÒÒÒÑÑÑÐÐÐÍÍÍÌÌÌÌÌÌÌÌÌÆÆÆÅÅÅÃÃÃÃÃÃÉÉÉÆÆƺºº¸¸¸ÀÀÀ»»»ÊÊʵµµÇÇǼ¼¼ººº···ÌÌÌÍÍÍÉÉÉÎÎÎÇÇÇ»»»¾¾¾Â¿¿¿ÀÀÀÉÉÉÆÆƾ¾¾ÀÀÀÆÆƼ¼¼¿¿¿ÉÉɺººÕÕÕÎÎÎÕÕÕÐÐÐÌÌÌÍÍÍÇÇÇÉÉÉÑÑÑÑÑÑÍÍÍÍÍÍÌÌÌÌÌÌÎÎÎÒÒÒÒÒÒÎÎÎÅÅž¾¾¸¸¸···¸¸¸ººº»»»ºººµµµ³³³¬¬¬°°°ÂÂÂÑÑÑÐÐÐÍÍÍÐÐÐÑÑÑØØØÛÛÛÑÑÑÔÔÔÎÎÎÊÊÊÝÝÝçççÛÛÛãããÜÜÜÝÝÝ×××ÍÍÍÒÒÒÎÎÎÕÕÕÛÛÛßßßâââßßßÙÙÙ×××ÕÕÕÝÝÝÛÛÛÛÛÛÛÛÛÛÛÛÛÛÛÜÜÜßßßÙÙÙÙÙÙÙÙÙÛÛÛÜÜÜßßßâââäääãããæææíííîîîççççççâââÔÔÔÕÕÕÎÎÎÂÂÂÀÀÀÌÌÌÎÎÎÌÌÌÎÎÎÊÊÊÊÊÊÉÉÉÇÇÇÇÇÇÇÇÇÆÆÆÆÆÆÊÊÊÐÐÐÔÔÔÔÔÔÒÒÒÔÔÔÔÔÔÔÔÔàààÙÙÙÕÕÕÕÕÕÕÕÕÒÒÒÒÒÒÔÔÔÒÒÒÎÎÎÐÐÐÍÍÍÆÆÆãããââââââßßßàààëëëíííÛÛÛÍÍÍÌÌÌÌÌÌÑÑÑÐÐÐÐÐÐÎÎÎÍÍÍÌÌÌÉÉÉÉÉÉÐÐÐÉÉÉÇÇÇÎÎÎÒÒÒÐÐÐÍÍÍÍÍÍÑÑÑÔÔÔÕÕÕ×××ÙÙÙÛÛÛÝÝÝâââÝÝÝÜÜÜÙÙÙÙÙÙÛÛÛÛÛÛÙÙÙ××××××ÕÕÕÑÑÑÎÎÎÍÍÍÎÎÎÒÒÒÕÕÕÝÝÝÔÔÔØØØààààààßßßßßßÛÛÛÛÛÛÜÜÜÙÙÙÕÕÕÕÕÕØØØÕÕÕÎÎÎÊÊÊÔÔÔÝÝÝÝÝÝÜÜÜÜÜÜÜÜÜÛÛÛãããÝÝÝãããèèèàààÜÜÜßßßÝÝÝäääâââèèèèèèÛÛÛÒÒÒÒÒÒÒÒÒÕÕÕ×××××××××ÔÔÔÑÑÑÍÍÍÊÊÊÂÂÂÅÅÅÆÆÆÉÉÉÉÉÉÇÇÇÆÆÆÅÅž¾¾ÆÆÆÍÍÍÅÅż¼¼ÃÃÃÆÆƾ¾¾¸¸¸ÊÊÊÊÊÊÌÌÌÍÍÍÉÉÉÍÍÍÎÎÎÆÆÆ¿¿¿ÂÂÂÆÆÆÅÅÅ¿¿¿¼¼¼ÆÆƾ¾¾¾¾¾ÃÃ÷··ÑÑÑÌÌÌÒÒÒÌÌÌÌÌÌÑÑÑÎÎÎÍÍÍÑÑÑÎÎÎÊÊÊÎÎÎÌÌÌÍÍÍÐÐÐÒÒÒÒÒÒÎÎÎÇÇÇÂÂÂÅÅÅÃÃÃÂÂÂÀÀÀÀÀÀ¼¼¼¸¸¸´´´¯¯¯³³³ÆÆÆÒÒÒÊÊÊÉÉÉÐÐÐÐÐÐÔÔÔ×××ÑÑÑÕÕÕÐÐÐÇÇÇÔÔÔØØØÛÛÛÝÝÝÕÕÕØØØÔÔÔÍÍÍÑÑÑÌÌÌÍÍÍÎÎÎÐÐÐÐÐÐÎÎÎÍÍÍÌÌÌÌÌÌÜÜÜÝÝÝÜÜÜÙÙÙ××××××ÔÔÔÒÒÒØØØØØØØØØÙÙÙÛÛÛÝÝÝßßßàààâââàààäääççççççêêêæææÙÙÙØØØÕÕÕÉÉÉÂÂÂÊÊÊÌÌÌÉÉÉÉÉÉÊÊÊÊÊÊÉÉÉÇÇÇÆÆÆÆÆÆÇÇÇÉÉÉÑÑÑÌÌÌÊÊÊÎÎÎÑÑÑÒÒÒØØØàààßßßÙÙÙÕÕÕ××××××ÔÔÔÒÒÒÕÕÕÔÔÔÑÑÑÐÐÐÌÌÌÅÅÅââââââàààãããâââçççççç×××ÍÍÍÍÍÍÍÍÍÑÑÑÐÐÐÎÎÎÍÍÍÌÌÌÌÌÌÌÌÌÌÌÌÒÒÒÍÍÍÊÊÊÍÍÍÐÐÐÎÎÎÍÍÍÐÐÐÌÌÌÐÐÐÔÔÔÔÔÔÔÔÔÕÕÕÜÜÜãããÝÝÝÜÜÜÛÛÛÙÙÙÙÙÙØØØ×××ÕÕÕÐÐÐÎÎÎÍÍÍÎÎÎÑÑÑÔÔÔ×××ØØØØØØÑÑÑØØØãããâââÝÝÝÙÙÙÒÒÒàààâââßßßÛÛÛÙÙÙÙÙÙÔÔÔÍÍÍÐÐÐØØØßßßßßßßßßâââãããâââÝÝÝØØØÝÝÝãããÝÝÝÜÜÜââââââäääßßßâââÝÝÝÐÐÐÇÇÇÌÌÌÍÍÍÑÑÑÒÒÒÒÒÒÔÔÔÔÔÔÒÒÒÒÒÒÑÑÑÇÇÇÃÃÿ¿¿¾¾¾¾¾¾ÃÃÃÇÇÇÌÌÌ···ÃÃÃÎÎÎÇÇÇ»»»¾¾¾ÃÃþ¾¾ºººÌÌÌÊÊÊÊÊÊÌÌÌÆÆÆÊÊÊÌÌÌÌÌÌ¿¿¿ÂÂÂÅÅÅÀÀÀÃÃúººÆÆÆ¿¿¿»»»¾¾¾´´´ÍÍÍÉÉÉÐÐÐÉÉÉÊÊÊÔÔÔÔÔÔÑÑÑÑÑÑÊÊÊÇÇÇÎÎÎÊÊÊÍÍÍÒÒÒÔÔÔÒÒÒÎÎÎÊÊÊÉÉÉÌÌÌÊÊÊÇÇÇÆÆÆÅÅÅÀÀÀ»»»¸¸¸¯¯¯°°°ÇÇÇÒÒÒÆÆÆÆÆÆÒÒÒÑÑÑÑÑÑÒÒÒÍÍÍÐÐÐÍÍÍÉÉÉÑÑÑÔÔÔÜÜÜÛÛÛÒÒÒÔÔÔÒÒÒÐÐÐÔÔÔÐÐÐÑÑÑÎÎÎÊÊÊÉÉÉÉÉÉÌÌÌÍÍÍÍÍÍÑÑÑØØØÛÛÛØØØÙÙÙßßßßßßÙÙÙÛÛÛÛÛÛÛÛÛÜÜÜÜÜÜÝÝÝßßßßßßâââÜÜÜßßßâââäääëëëëëëâââ×××ÛÛÛÐÐÐÅÅÅÇÇÇÌÌÌÉÉÉÉÉÉÉÉÉÊÊÊÊÊÊÇÇÇÅÅÅÆÆÆÉÉÉÍÍÍÒÒÒÅÅÅÀÀÀÌÌÌÔÔÔÕÕÕÜÜÜèèèÝÝÝØØØÕÕÕØØØØØØÕÕÕÔÔÔÕÕÕÔÔÔÔÔÔÎÎÎÊÊÊÃÃÃàààããããããêêêããããããàààÒÒÒÌÌÌÎÎÎÐÐÐÑÑÑÎÎÎÍÍÍÊÊÊÊÊÊÌÌÌÎÎÎÐÐÐ×××ÑÑÑÍÍÍÍÍÍÍÍÍÍÍÍÎÎÎÑÑÑÐÐÐÒÒÒ×××ÒÒÒÊÊÊÊÊÊÒÒÒÙÙÙÛÛÛÜÜÜÜÜÜÛÛÛØØØÕÕÕÒÒÒÒÒÒÍÍÍÌÌÌÊÊÊÍÍÍÒÒÒ×××ØØØ×××ÜÜÜ×××ßßßêêêêêêèèèæææßßßäääæææäääàààÝÝÝÜÜÜ×××ÑÑÑÑÑÑ×××ÛÛÛÜÜÜßßßæææèèèèèèàààÛÛÛÝÝÝâââÝÝÝÝÝÝäääçççêêêäääæææâââÒÒÒÉÉÉÌÌÌÍÍÍÑÑÑÑÑÑÐÐÐÐÐÐÑÑÑÑÑÑÒÒÒÔÔÔÍÍÍÉÉÉÃÃÿ¿¿ÀÀÀÆÆÆÎÎÎÔÔÔ»»»ÆÆÆÕÕÕÑÑÑÂÂÂÀÀÀÇÇÇÅÅż¼¼ÎÎÎÌÌÌÊÊÊÊÊÊÅÅÅÇÇÇÉÉÉÎÎξ¾¾ÂÂÂÃÃþ¾¾ÉÉɸ¸¸ÉÉÉÃÃû»»»»»µµµÊÊÊÉÉÉÎÎÎÇÇÇÊÊÊÒÒÒÒÒÒÑÑÑÑÑÑÌÌÌÆÆÆÊÊÊÆÆÆÍÍÍÕÕÕ×××ÔÔÔÐÐÐÍÍÍÍÍÍÉÉÉÇÇÇÆÆÆÆÆÆÆÆÆÅÅÅÀÀÀ¾¾¾¬¬¬¬¬¬ÃÃÃÒÒÒÇÇÇÌÌÌ×××ÐÐÐÐÐÐÌÌÌÅÅÅÃÃÃÆÆÆÍÍÍØØØÝÝÝÙÙÙÙÙÙ×××ÔÔÔÑÑÑÐÐÐÔÔÔ×××ØØØÒÒÒÍÍÍÌÌÌÍÍÍÑÑÑÒÒÒÔÔÔÎÎÎØØØÙÙÙÒÒÒÔÔÔÛÛÛÛÛÛÒÒÒâââàààßßßÝÝÝßßßàààâââããããããßßßàààâââàààæææëëëçççÔÔÔÛÛÛÒÒÒÃÃÃÆÆÆÍÍÍÍÍÍÌÌÌÇÇÇÊÊÊÊÊÊÇÇÇÅÅÅÆÆÆÌÌÌÑÑÑÌÌÌÀÀÀ¾¾¾ÉÉÉÕÕÕÙÙÙßßßçççÜÜÜØØØ×××ÙÙÙÙÙÙÕÕÕÔÔÔÔÔÔÔÔÔÕÕÕÊÊÊÇÇÇÅÅÅàààæææêêêñññçççãããßßßÒÒÒÌÌÌÎÎÎÎÎÎÐÐÐÎÎÎÌÌÌÉÉÉÊÊÊÍÍÍÑÑÑÔÔÔ×××ÔÔÔÑÑÑÐÐÐÎÎÎÍÍÍÎÎÎÐÐÐÑÑÑÐÐÐÒÒÒÎÎÎÆÆÆÆÆÆÍÍÍÐÐÐØØØÛÛÛÜÜÜÛÛÛ×××ÒÒÒÐÐÐÐÐÐÐÐÐÌÌÌÉÉÉÌÌÌÑÑÑÕÕÕÕÕÕÔÔÔ×××ÐÐÐÒÒÒÛÛÛßßßæææëëëçççääääääãããâââàààßßßÜÜÜÙÙÙÎÎÎÒÒÒÕÕÕ×××ÜÜÜæææëëëëëëêêêæææääääääãããâââçççíííëëëèèèíííëëëÛÛÛÐÐÐÎÎÎÍÍÍÔÔÔÒÒÒÑÑÑÎÎÎÍÍÍÌÌÌÌÌÌÌÌÌÊÊÊÉÉÉÇÇÇÆÆÆÇÇÇÊÊÊÍÍÍÎÎÎÃÃÃÆÆÆÒÒÒÒÒÒÅÅÅÅÅÅÌÌÌÇÇÇÂÂÂÒÒÒÎÎÎÌÌÌÊÊÊÅÅÅÇÇÇÇÇÇÐÐп¿¿ÀÀÀÅÅž¾¾ÌÌ̺ººÌÌÌÅÅÅ»»»¼¼¼¼¼¼ÌÌÌÌÌÌÐÐÐÉÉÉÌÌÌÐÐÐÍÍÍÍÍÍÒÒÒÐÐÐÇÇÇÆÆÆÃÃÃÌÌÌÕÕÕÙÙÙÕÕÕÑÑÑÎÎÎÎÎÎÉÉÉÇÇÇÆÆÆÆÆÆÇÇÇÇÇÇÅÅÅÃÃí­­¯¯¯ÂÂÂÑÑÑÍÍÍÐÐÐÒÒÒÆÆÆÉÉɾ¾¾ººº¿¿¿ÌÌÌ×××ÝÝÝÒÒÒÕÕÕØØØÒÒÒÌÌÌÌÌÌÐÐÐØØØÕÕÕÑÑÑÍÍÍÌÌÌÎÎÎÑÑÑÒÒÒÒÒÒÜÜÜãããäääÝÝÝßßßêêêëëëæææãããàààÝÝÝÛÛÛÛÛÛÝÝÝàààãããäääâââææææææÜÜÜÝÝÝçççêêê×××ÜÜÜÑÑÑÂÂÂÅÅÅÌÌÌÌÌÌÊÊÊÇÇÇÉÉÉÊÊÊÇÇÇÆÆÆÇÇÇÎÎÎÔÔÔÅÅÅÀÀÀ¿¿¿ÃÃÃÎÎÎÙÙÙâââãããÜÜÜØØØ×××ÙÙÙÙÙÙÕÕÕÒÒÒÔÔÔÒÒÒÔÔÔÅÅÅÉÉÉÊÊÊàààèèèñññóóóèèèæææâââÔÔÔÍÍÍÍÍÍÌÌÌÎÎÎÍÍÍÌÌÌÊÊÊÌÌÌÎÎÎÒÒÒÕÕÕÔÔÔÕÕÕÕÕÕÒÒÒÑÑÑÐÐÐÎÎÎÍÍÍÊÊÊÆÆÆÊÊÊÍÍÍÇÇÇÌÌÌÒÒÒÐÐÐÔÔÔ×××ÙÙÙÙÙÙÕÕÕÑÑÑÎÎÎÎÎÎÐÐÐÊÊÊÆÆÆÇÇÇÍÍÍÒÒÒÔÔÔÔÔÔÙÙÙÒÒÒÔÔÔÙÙÙÝÝÝêêêòòòïïïçççæææäääâââßßßÜÜÜÛÛÛÜÜÜÐÐÐÒÒÒÕÕÕÕÕÕÜÜÜæææëëëëëëëëëèèèççççççæææäääèèèñññæææâââæææäääÕÕÕÌÌÌÍÍÍÍÍÍÒÒÒÑÑÑÐÐÐÎÎÎÌÌÌÇÇÇÆÆÆÃÃÃÂÂÂÃÃÃÅÅÅÆÆÆÆÆÆÅÅÅÃÃÃÃÃÃÇÇǼ¼¼ÅÅÅÊÊÊÀÀÀÂÂÂÉÉÉÂÂÂÆÆÆÕÕÕÑÑÑÎÎÎÍÍÍÆÆÆÊÊÊÊÊÊÐÐÐÅÅÅÀÀÀÊÊʾ¾¾ÊÊÊ»»»ÍÍÍÅÅÅ»»»¿¿¿ÆÆÆÐÐÐÐÐÐÑÑÑÌÌÌÎÎÎÐÐÐÌÌÌÌÌÌÒÒÒÐÐÐÇÇÇÆÆÆÃÃÃÌÌÌÔÔÔØØØÕÕÕÐÐÐÎÎÎÎÎÎÎÎÎÍÍÍÊÊÊÉÉÉÉÉÉÇÇÇÅÅÅÃÃñ±±¸¸¸ÆÆÆÐÐÐÎÎÎÎÎÎÉÉɼ¼¼¿¿¿»»»¼¼¼···»»»ÇÇÇÌÌÌÑÑÑÌÌÌÎÎÎ×××ÑÑÑÉÉÉÊÊÊÊÊÊÒÒÒÑÑÑÐÐÐÎÎÎÎÎÎÐÐÐÑÑÑÑÑÑÑÑÑÊÊÊÐÐÐÑÑÑÎÎÎÒÒÒÜÜÜàààÝÝÝÝÝÝÛÛÛØØØÕÕÕÕÕÕØØØÛÛÛÝÝÝâââàààççççççÜÜÜÙÙÙâââæææßßßÝÝÝÍÍÍ¿¿¿ÃÃÃÉÉÉÇÇÇÅÅÅÆÆÆÇÇÇÉÉÉÉÉÉÉÉÉÌÌÌÐÐÐÕÕÕÅÅÅÃÃÃÀÀÀ¾¾¾ÅÅÅÒÒÒÝÝÝâââßßßÙÙÙÕÕÕØØØ×××ÒÒÒÑÑÑÑÑÑÐÐÐÐÐÐÂÂÂÑÑÑ×××àààçççõõõñññçççäääâââÔÔÔÍÍÍÌÌÌÊÊÊÍÍÍÌÌÌÌÌÌÍÍÍÎÎÎÐÐÐÒÒÒÔÔÔÑÑÑÔÔÔÕÕÕÕÕÕÔÔÔÒÒÒÎÎÎÉÉÉÉÉÉÅÅÅÍÍÍÒÒÒÊÊÊÌÌÌÑÑÑÊÊÊÎÎÎÒÒÒÕÕÕØØØ×××ÒÒÒÐÐÐÍÍÍÌÌÌÇÇÇÃÃÃÅÅÅÊÊÊÐÐÐÔÔÔÕÕÕÌÌÌÇÇÇÌÌÌÐÐÐÒÒÒÜÜÜàààÙÙÙëëëèèèçççäääßßßØØØ×××ØØØÕÕÕÙÙÙÛÛÛÛÛÛÝÝÝäääèèèèèèæææçççäääæææèèèçççèèèòòòèèèââââââÜÜÜÎÎÎÉÉÉÐÐÐÔÔÔÐÐÐÎÎÎÎÎÎÍÍÍÌÌÌÉÉÉÆÆÆÆÆÆÅÅÅÅÅÅÅÅÅÃÃÃÅÅÅÆÆÆÇÇÇÇÇÇÎÎλ»»ÀÀÀÊÊÊÂÂÂÅÅÅÌÌÌÃÃÃÆÆÆ×××ÑÑÑÎÎÎÎÎÎÉÉÉÍÍÍÎÎÎÑÑÑÍÍÍÃÃÃÐÐп¿¿ÆÆÆ»»»ÊÊÊÀÀÀºººÂÂÂÎÎÎÒÒÒÒÒÒÒÒÒÌÌÌÒÒÒÕÕÕÑÑÑÎÎÎÑÑÑÎÎÎÇÇÇÉÉÉÆÆÆÌÌÌÑÑÑÒÒÒÑÑÑÎÎÎÎÎÎÎÎÎÎÎÎÌÌÌÉÉÉÆÆÆÆÆÆÅÅÅ¿¿¿°°°ÂÂÂÍÍÍÍÍÍÍÍÍÇÇÇÀÀÀ¿¿¿¼¼¼»»»ÀÀÀººº¼¼¼ÉÉÉÉÉÉÍÍÍÎÎÎÍÍÍÕÕÕÑÑÑÐÐÐÑÑÑÉÉÉÍÍÍÎÎÎÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÑÑÑÒÒÒÑÑÑÒÒÒÑÑÑÐÐÐÐÐÐÐÐÐÐÐÐÎÎÎ××××××ÕÕÕÕÕÕÕÕÕ×××ØØØÙÙÙÜÜÜØØØßßßäääßßßÜÜÜßßßÝÝÝäääÙÙÙÅÅÅ»»»ÃÃÃÉÉÉÅÅÅÅÅÅÅÅÅÆÆÆÇÇÇÉÉÉÌÌÌÎÎÎÒÒÒÔÔÔÃÃÃÂÂÂÂÂÂÂÂÂÃÃÃÇÇÇÒÒÒÝÝÝàààÙÙÙÕÕÕÕÕÕÕÕÕÑÑÑÎÎÎÐÐÐÌÌÌÍÍÍÂÂÂÝÝÝäääàààâââòòòèèèààààààÝÝÝÑÑÑÊÊÊÌÌÌÌÌÌÊÊÊÌÌÌÎÎÎÐÐÐÑÑÑÑÑÑÑÑÑÐÐÐÐÐÐÒÒÒÔÔÔÔÔÔÕÕÕÕÕÕÐÐÐÆÆÆÉÉÉÉÉÉÙÙÙÜÜÜÌÌÌÇÇÇÍÍÍÆÆÆÊÊÊÍÍÍÑÑÑÕÕÕØØØÕÕÕÑÑÑÍÍÍÉÉÉÇÇÇÅÅÅÅÅÅÇÇÇÌÌÌÎÎÎÑÑÑÐÐÐÎÎÎÒÒÒ×××ÙÙÙâââäääÜÜÜêêêèèèèèèêêêãããÙÙÙÕÕÕ×××ÙÙÙßßßâââÝÝÝÛÛÛÜÜÜÝÝÝÜÜÜæææêêêèèèêêêîîîèèèçççñññîîîæææãããÝÝÝÐÐÐÌÌÌÒÒÒØØØÑÑÑÑÑÑÎÎÎÍÍÍÌÌÌÊÊÊÊÊÊÊÊÊÊÊÊÇÇÇÆÆÆÅÅÅÆÆÆÊÊÊÐÐÐÒÒÒÑÑѼ¼¼ÆÆÆÒÒÒÇÇÇÆÆÆÐÐÐÉÉÉÅÅÅÔÔÔÐÐÐÎÎÎÍÍÍÉÉÉÎÎÎÑÑÑÔÔÔÔÔÔÅÅÅÕÕÕ¿¿¿ÃÃúººÇÇǾ¾¾¸¸¸ÃÃÃÒÒÒÔÔÔÔÔÔÒÒÒÍÍÍÔÔÔÛÛÛØØØÒÒÒÐÐÐÊÊÊÇÇÇÍÍÍÉÉÉÌÌÌÎÎÎÎÎÎÍÍÍÍÍÍÎÎÎÐÐÐÇÇÇÅÅÅÂÂÂÀÀÀÀÀÀÀÀÀ¾¾¾¼¼¼ªªªÅÅÅÐÐÐÌÌÌÊÊÊÃÃÿ¿¿ÇÇÇÀÀÀ¿¿¿ÅÅż¼¼¾¾¾ÍÍÍÎÎÎÕÕÕ×××ÐÐÐ×××ÕÕÕØØØÜÜÜÍÍÍÌÌÌÉÉÉÊÊÊÌÌÌÊÊÊÉÉÉÉÉÉÌÌÌÎÎÎÍÍÍÍÍÍÎÎÎÑÑÑÑÑÑÎÎÎÎÎÎÎÎÎÔÔÔÕÕÕ×××ØØØÙÙÙÙÙÙØØØØØØØØØÐÐÐÕÕÕââââââàààÝÝÝØØØãããÔÔÔ¼¼¼···ÅÅÅÊÊÊÇÇÇÉÉÉÅÅÅÅÅÅÇÇÇÊÊÊÍÍÍÑÑÑÒÒÒÔÔÔ¿¿¿¾¾¾ÃÃÃÌÌÌÇÇÇÀÀÀÇÇÇ×××âââÛÛÛÕÕÕÔÔÔÒÒÒÎÎÎÍÍÍÐÐÐÊÊÊÌÌÌÃÃÃçççîîîàààÝÝÝîîîâââÛÛÛÛÛÛÛÛÛÎÎÎÉÉÉÍÍÍÎÎÎÉÉÉÌÌÌÎÎÎÒÒÒÒÒÒÒÒÒÐÐÐÎÎÎÐÐÐÒÒÒÒÒÒÑÑÑÔÔÔ×××ÐÐÐÆÆÆÀÀÀÇÇÇßßßãããÌÌÌÆÆÆÐÐÐÍÍÍÇÇÇÊÊÊÎÎÎÔÔÔØØØ×××ÒÒÒÍÍÍÊÊÊÊÊÊÉÉÉÇÇÇÆÆÆÆÆÆÇÇÇÉÉÉÑÑÑÎÎÎÒÒÒÕÕÕØØØäääêêêâââääääääêêêîîîèèèÝÝÝØØØØØØÛÛÛàààãããÝÝÝ×××ÔÔÔÒÒÒÐÐÐíííñññïïïïïïóóóëëëæææîîîëëëääääääàààÑÑÑÊÊÊÐÐÐÒÒÒØØØÕÕÕÑÑÑÍÍÍÊÊÊÊÊÊÌÌÌÍÍÍÃÃÃÂÂÂÂÂÂÂÂÂÆÆÆÊÊÊÐÐÐÒÒÒÊÊʸ¸¸ÆÆÆÔÔÔÅÅÅÀÀÀÌÌÌÇÇÇÂÂÂÒÒÒÎÎÎÌÌÌÍÍÍÉÉÉÐÐÐÑÑÑÔÔÔ×××ÎÎÎÃÃÃÑÑѺºº¸¸¸ÇÇÇÀÀÀºººÑÑÑÐÐÐ×××ÔÔÔÒÒÒÐÐÐÑÑÑÔÔÔÕÕÕÎÎÎÎÎÎÎÎÎÆÆÆÐÐÐÆÆÆÎÎÎÑÑÑÍÍÍÊÊÊÎÎÎÑÑÑÐÐÐÇÇÇ¿¿¿¿¿¿¾¾¾µµµ···¸¸¸°°°ÎÎÎÕÕÕÑÑÑÀÀÀºººÂÂÂÇÇÇÃÃÿ¿¿»»»»»»ÂÂÂÉÉÉÍÍÍÐÐÐÔÔÔÔÔÔÍÍÍÔÔÔÒÒÒÕÕÕÙÙÙÌÌÌÌÌÌÑÑÑÌÌÌÌÌÌÊÊÊÂÂÂÀÀÀÅÅÅÀÀÀÅÅÅÆÆÆÊÊÊÊÊÊÊÊÊÇÇÇÅÅÅÃÃÃÆÆÆÍÍÍÐÐÐÇÇÇÃÃÃÉÉÉÑÑÑ×××ÔÔÔÙÙÙÒÒÒ×××èèèçççÛÛÛÝÝÝãããßßßÙÙÙÒÒÒÍÍÍÉÉÉÆÆÆÃÃÃÂÂÂÃÃÃÆÆÆÉÉÉÍÍÍÔÔÔÛÛÛßßßÅÅÅ¿¿¿ÃÃÃÇÇÇÅÅÅÉÉÉÍÍÍÆÆÆØØØÜÜÜÑÑÑÑÑÑÒÒÒÐÐÐÕÕÕÉÉÉÌÌ̼¼¼ÃÃÃàààîîîãããàààëëëØØØÒÒÒÕÕÕÒÒÒÔÔÔÔÔÔÆÆÆÅÅÅÐÐÐÍÍÍÌÌÌÊÊÊÍÍÍÒÒÒØØØÛÛÛÎÎÎÐÐÐÑÑÑÔÔÔÍÍÍÔÔÔÛÛÛÀÀÀÅÅÅÎÎÎÜÜÜÙÙÙÊÊÊÊÊÊÑÑÑÍÍÍÉÉÉÉÉÉÌÌÌÑÑÑ××××××ÑÑÑÌÌÌÉÉÉÌÌÌÊÊÊÅÅÅÍÍÍÉÉÉÇÇÇêêêÎÎÎÍÍÍÑÑÑØØØÙÙÙÙÙÙßßßççççççïïïòòòêêêßßßÙÙÙ×××ÕÕÕÜÜÜÜÜÜÙÙÙÕÕÕÑÑÑÑÑÑÔÔÔ×××ØØØãããíííòòòóóóïïïäääÙÙÙíííãããêêêçççÍÍÍÆÆÆÑÑÑÎÎÎÑÑÑ×××ØØØÑÑÑÍÍÍÍÍÍÌÌÌÉÉÉÕÕÕÒÒÒÊÊÊÊÊÊÉÉÉÑÑÑÜÜÜÍÍ;¾¾ÂÂÂÆÆÆØØØÅÅÅÉÉÉÍÍÍ¿¿¿ÀÀÀ×××ØØØÎÎÎÐÐÐÔÔÔÑÑÑÑÑÑÔÔÔÔÔÔÊÊÊÊÊÊÕÕÕ¼¼¼ÂÂÂÇÇÇÅÅż¼¼ÊÊÊÒÒÒ×××ÔÔÔÒÒÒÐÐÐØØØØØØÛÛÛØØØÜÜÜÙÙÙÇÇÇÇÇÇÎÎÎÎÎÎÍÍÍÊÊÊÊÊÊÍÍÍÌÌÌÉÉÉÀÀÀÉÉÉ×××ÜÜÜ×××ÔÔÔ××××××ÙÙÙÎÎÎÇÇÇÉÉÉÇÇÇÀÀÀ¾¾¾¿¿¿ÊÊÊÆÆÆÅÅÅÉÉÉÎÎÎÎÎÎÑÑÑÔÔÔ¼¼¼¾¾¾ÊÊÊÍÍÍÑÑÑÕÕÕÇÇÇÃÃÃÊÊÊÉÉÉÊÊÊÆÆƸ¸¸···»»»»»»»»»¼¼¼¾¾¾ÀÀÀÂÂÂÂÂÂÃÃÃÃÃÃÂÂÂÇÇÇÉÉÉÅÅÅÂÂÂÇÇÇÎÎÎÑÑÑÕÕÕÜÜÜÕÕÕ×××çççæææÙÙÙÛÛÛêêêææææææçççÙÙÙÉÉÉÅÅÅÍÍÍÅÅÅÆÆÆÇÇÇÊÊÊÍÍÍÑÑÑØØØÜÜÜØØØÎÎÎÌÌÌÍÍÍÌÌÌÍÍÍÊÊÊÀÀÀÛÛÛâââØØØ×××ÔÔÔÐÐÐÔÔÔÌÌÌÊÊÊÂÂÂÉÉÉßßßêêêäääàààæææäääÛÛÛÙÙÙÔÔÔ×××ÙÙÙÎÎÎÌÌÌÍÍÍÍÍÍÍÍÍÍÍÍÎÎÎÑÑÑÔÔÔÕÕÕÙÙÙÙÙÙØØØØØØÊÊÊÊÊÊÕÕÕÂÂÂÇÇÇÇÇÇÌÌÌÌÌÌÇÇÇÌÌÌÍÍÍÅÅÅÅÅÅÅÅÅÆÆÆÌÌÌÑÑÑÑÑÑÍÍÍÉÉÉÇÇÇÇÇÇÉÉÉÃÃÃÇÇÇÆÆÆÅÅÅÜÜÜÐÐÐÐÐÐÒÒÒÙÙÙÜÜÜÛÛÛÝÝÝâââãããêêêëëëäääÜÜÜÙÙÙØØØ×××ÝÝÝÜÜÜØØØÕÕÕÒÒÒÒÒÒÔÔÔ×××ÔÔÔÛÛÛãããçççêêêêêêãããÛÛÛæææßßßÜÜÜÝÝÝ×××ÌÌÌÊÊÊÐÐÐÌÌÌÐÐÐÑÑÑÌÌÌÊÊÊÍÍÍÐÐÐÎÎÎÎÎÎÐÐÐÎÎÎÑÑÑÎÎÎÍÍÍÑÑÑÀÀÀ¿¿¿ÅÅÅÆÆÆÛÛÛÌÌÌÎÎÎÑÑÑÊÊÊÇÇÇÒÒÒ×××ÒÒÒÒÒÒÒÒÒÒÒÒÔÔÔ×××ÐÐÐÅÅÅÎÎÎØØØÀÀÀÍÍÍÉÉÉÇÇǾ¾¾¿¿¿××××××ÔÔÔÒÒÒÐÐÐÜÜÜØØØÙÙÙÙÙÙäääãããÌÌÌÇÇÇÔÔÔÍÍÍÇÇÇÇÇÇÊÊÊÉÉÉÆÆÆÅÅÅ¿¿¿ÎÎÎÛÛÛßßßÝÝÝ×××ÔÔÔØØØÙÙÙÊÊÊÅÅÅÌÌÌÊÊʼ¼¼µµµºººººº´´´±±±´´´µµµ³³³´´´···¿¿¿ÂÂÂÇÇÇÃÃÃÅÅÅÌÌÌÆÆÆÃÃÃÉÉÉÇÇÇÌÌÌÅÅŵµµ±±±¸¸¸ººº¯¯¯°°°±±±µµµººº¾¾¾ÀÀÀ¿¿¿ÅÅÅÆÆÆÅÅÅÆÆÆÊÊÊÎÎÎÐÐÐÔÔÔØØØÔÔÔÕÕÕããããããÛÛÛßßßææææææêêêëëëßßßÊÊÊÀÀÀÂÂÂÆÆÆÇÇÇÊÊÊÌÌÌÍÍÍÐÐÐÕÕÕØØØßßßØØØÔÔÔÑÑÑÌÌÌÍÍÍÐÐÐÌÌÌÝÝÝãããßßßÜÜÜØØØÒÒÒÕÕÕÑÑÑÅÅÅÍÍÍØØØàààãããââââââãããíííßßßÙÙÙÔÔÔØØØÝÝÝÒÒÒÐÐÐÊÊÊÌÌÌÍÍÍÎÎÎÐÐÐÐÐÐÎÎÎÎÎÎÉÉÉÎÎÎ×××àààÔÔÔÍÍÍÔÔÔÉÉÉÆÆÆÂÂÂÂÂÂÂÂÂÃÃÃÉÉÉÊÊÊÃÃÃÃÃÃÃÃÃÆÆÆÌÌÌÒÒÒ×××ÕÕÕÒÒÒÊÊÊÆÆÆÊÊÊÆÆÆÆÆÆÌÌÌÌÌÌÕÕÕÔÔÔÒÒÒÕÕÕÛÛÛÝÝÝÝÝÝÜÜÜÝÝÝàààääääääßßßÛÛÛÛÛÛÛÛÛÙÙÙßßßÜÜÜØØØÕÕÕÔÔÔÕÕÕÕÕÕÕÕÕÒÒÒ×××ÛÛÛÝÝÝâââçççæææàààããããããÙÙÙØØØÛÛÛÇÇǺººÅÅÅÊÊÊÍÍÍÍÍÍÊÊÊÊÊÊÎÎÎÒÒÒÒÒÒÌÌÌÎÎÎÑÑÑÒÒÒÑÑÑÆÆÆÇÇǺººÀÀÀÆÆÆÅÅÅÛÛÛÒÒÒÑÑÑÒÒÒÕÕÕÉÉÉÆÆÆÎÎÎÕÕÕÔÔÔÒÒÒØØØÛÛÛÜÜÜÇÇÇÅÅÅÍÍÍÔÔÔÅÅÅÐÐÐÉÉÉÆÆƾ¾¾···ØØØ×××ÕÕÕÕÕÕÔÔÔÜÜÜ×××ÕÕÕÔÔÔßßßâââÒÒÒÑÑÑÔÔÔÌÌÌÆÆÆÇÇÇÆÆÆÂÂÂÂÂÂÇÇÇÉÉÉÔÔÔÕÕÕ×××ßßßÛÛÛÔÔÔÙÙÙÊÊÊÍÍÍÍÍÍÇÇÇ¿¿¿ººº······¾¾¾¸¸¸·········³³³´´´···¸¸¸¾¾¾ÀÀÀ»»»¾¾¾ÇÇÇÊÊÊÉÉÉÃÃÿ¿¿ÀÀÀ¼¼¼±±±¯¯¯³³³±±±¦¦¦©©©¬¬¬³³³¸¸¸¼¼¼¾¾¾¾¾¾ÃÃÃÅÅÅÇÇÇÊÊÊÎÎÎÑÑÑÒÒÒÒÒÒÎÎÎÑÑÑÍÍÍÎÎÎÛÛÛàààßßßäääÝÝÝãããçççäääàààÕÕÕÃÃó³³ÃÃÃÇÇÇÊÊÊÍÍÍÍÍÍÎÎÎÔÔÔØØØÝÝÝßßßÝÝÝÕÕÕÉÉÉÇÇÇÒÒÒÜÜÜââââââßßßÝÝÝÜÜÜÙÙÙØØØÒÒÒÀÀÀØØØçççãããÜÜÜßßßääääääæææÙÙÙÕÕÕÒÒÒØØØÜÜÜÐÐÐÌÌÌÊÊÊÌÌÌÍÍÍÎÎÎÎÎÎÍÍÍÊÊÊÉÉÉÇÇÇÉÉÉÐÐÐÜÜÜÒÒÒÆÆÆÉÉÉÀÀÀÂÂÂÂÂÂÂÂÂÂÂÂÀÀÀÅÅÅÇÇÇÇÇÇÃÃÃÅÅÅÇÇÇÎÎÎ×××ÜÜÜßßßÝÝÝÔÔÔÇÇÇÍÍÍÊÊÊÊÊÊ×××ØØØØØØ×××ÕÕÕÕÕÕÙÙÙÝÝÝßßßßßßßßßàààãããàààÜÜÜÛÛÛÝÝÝÝÝÝÛÛÛßßßÛÛÛ×××ÕÕÕ×××××××××ÕÕÕ×××ÙÙÙÛÛÛÜÜÜãããêêêêêêæææâââëëëæææâââäääÔÔÔÂÂÂÆÆÆÉÉÉÊÊÊÌÌÌÍÍÍÎÎÎÐÐÐÑÑÑÒÒÒÎÎÎÐÐÐÐÐÐÎÎÎÎÎο¿¿ÆÆƾ¾¾ÀÀÀÇÇÇÂÂÂØØØÔÔÔÐÐÐÎÎÎØØØÐÐÐÂÂÂÉÉÉØØØÕÕÕÑÑÑØØØÛÛÛßßßÂÂÂÉÉÉÆÆÆÊÊÊÇÇÇÊÊÊÇÇÇ»»»µµµØØØØØØ×××ØØØØØØÜÜÜÙÙÙÙÙÙÔÔÔÛÛÛÝÝÝÒÒÒØØØÍÍÍÉÉÉÇÇÇÆÆÆÀÀÀ¼¼¼ÃÃÃÎÎÎØØØÝÝÝÙÙÙ×××ÜÜÜØØØÑÑÑÕÕÕÇÇÇÐÐÐÐÐÐÃÃü¼¼¿¿¿¾¾¾¸¸¸»»»···µµµ···´´´±±±³³³···ºººÀÀÀÀÀÀ¿¿¿¼¼¼ººº···¯¯¯¸¸¸°°°­­­­­­ªªª¬¬¬­­­¦¦¦¦¦¦©©©­­­µµµ»»»¾¾¾»»»¸¸¸ÃÃÃÃÃÃÇÇÇÍÍÍÑÑÑÒÒÒÒÒÒÒÒÒÎÎÎÎÎÎÊÊÊÊÊÊÒÒÒØØØÜÜÜäääßßßæææêêêêêêèèèâââÑÑÑ¿¿¿¿¿¿ÅÅÅÊÊÊÍÍÍÍÍÍÐÐÐÔÔÔÙÙÙÝÝÝæææçççßßßÔÔÔÎÎÎÔÔÔÝÝÝëëëâââÜÜÜÛÛÛÜÜÜÛÛÛÒÒÒÍÍÍÉÉÉÝÝÝèèèâââÝÝÝäääçççàààÛÛÛÒÒÒÕÕÕÔÔÔÙÙÙÛÛÛÌÌÌÆÆÆÊÊÊÊÊÊÊÊÊÌÌÌÌÌÌÊÊÊÊÊÊÉÉÉÐÐÐÇÇÇ¿¿¿ÉÉÉÆÆƾ¾¾ÃÃÿ¿¿ÂÂÂÂÂÂÀÀÀÀÀÀÂÂÂÂÂÂÃÃÃÆÆÆÆÆÆÆÆÆÉÉÉÎÎÎÔÔÔØØØÛÛÛÜÜÜßßßÎÎÎÐÐÐÍÍÍÌÌÌÛÛÛÝÝÝØØØÙÙÙØØØ××××××ÜÜÜâââãããããããããäääâââÜÜÜÜÜÜßßßßßßÜÜÜßßßÛÛÛØØØ×××ØØØØØØØØØ×××ÛÛÛÜÜÜÜÜÜÝÝÝæææíííëëëæææäääêêêèèèãããâââÙÙÙÆÆÆ···ÂÂÂÂÂÂÅÅÅÊÊÊÍÍÍÍÍÍÍÍÍÎÎÎÍÍÍÍÍÍÐÐÐÍÍÍÒÒÒ¼¼¼ÆÆÆÅÅÅÆÆÆÌÌÌÅÅÅÛÛÛÕÕÕÐÐÐÍÍÍÕÕÕÝÝÝÌÌÌÎÎÎÛÛÛØØØÔÔÔ×××ØØØØØØÀÀÀÐÐÐÀÀÀÃÃÃÉÉÉÆÆÆÆÆƾ¾¾¸¸¸¾¾¾ÕÕÕ×××ÕÕÕÙÙÙÙÙÙÜÜÜÝÝÝâââÜÜÜßßßÜÜÜÎÎÎÒÒÒÉÉÉÉÉÉÉÉÉÃÃü¼¼¼¼¼ÇÇÇÔÔÔ×××ÝÝÝÝÝÝØØØÑÑÑÉÉÉÅÅÅÉÉÉÎÎÎÌÌÌÆÆÆÂÂÂÂÂÂÃÃÃÀÀÀ»»»¾¾¾»»»»»»¼¼¼»»»¸¸¸»»»ÀÀÀººº¾¾¾ººº¾¾¾¿¿¿»»»¼¼¼¸¸¸¸¸¸­­­©©©¬¬¬­­­³³³±±±¨¨¨¬¬¬­­­°°°µµµ»»»¾¾¾»»»···¿¿¿¿¿¿ÃÃÃÊÊÊÎÎÎÍÍÍÍÍÍÎÎÎÑÑÑÑÑÑÍÍÍÊÊÊÍÍÍÑÑÑ×××ÜÜÜàààãããêêêîîîêêêàààÙÙÙ×××»»»ÂÂÂÊÊÊÎÎÎÎÎÎÐÐÐÕÕÕÙÙÙÛÛÛãããæææçççêêêäääßßßàààñññâââÜÜÜ××××××ÔÔÔÇÇÇÅÅÅØØØßßßàààÜÜÜßßßçççããã×××ÔÔÔÑÑÑØØØØØØØØØ×××ÉÉÉÆÆÆÉÉÉÉÉÉÉÉÉÉÉÉÉÉÉÊÊÊÊÊÊÌÌÌÍÍÍÅÅźººÂÂÂÃÃþ¾¾ÃÃÃÀÀÀÇÇÇÃÃû»»»»»ÂÂÂÀÀÀ¾¾¾ÀÀÀÑÑÑÑÑÑÒÒÒÔÔÔÕÕÕ×××ØØØØØØæææÑÑÑÐÐÐÍÍÍÍÍÍØØØØØØÕÕÕÛÛÛÛÛÛÙÙÙ×××ÛÛÛâââææææææääääääãããÝÝÝÜÜÜààààààÜÜÜÝÝÝÛÛÛÙÙÙØØØØØØÙÙÙØØØØØØÛÛÛÛÛÛÜÜÜÝÝÝæææíííëëëããããããàààâââãããâââàààÑÑѸ¸¸¾¾¾»»»»»»¿¿¿ÃÃÃÆÆÆÇÇÇÌÌÌÉÉÉÇÇÇÐÐÐÐÐÐÜÜܾ¾¾ÅÅÅÅÅÅÍÍÍÑÑÑÍÍÍàààÕÕÕÑÑÑÐÐÐÑÑÑÜÜÜÑÑÑÐÐÐ×××ÜÜÜßßßßßßÝÝÝÌÌÌÆÆÆÒÒÒ¿¿¿ÃÃÃÇÇÇÇÇÇÃÃû»»···ÊÊÊÔÔÔÕÕÕÔÔÔ×××ØØØÛÛÛÜÜÜßßßÛÛÛÝÝÝÛÛÛÊÊÊÍÍÍÉÉÉÊÊÊÇÇÇ¿¿¿¼¼¼ÂÂÂÍÍÍÔÔÔÑÑÑÐÐÐÔÔÔÒÒÒÍÍÍÌÌÌÍÍÍÌÌÌÊÊÊÃÃÿ¿¿ÀÀÀÀÀÀ¼¼¼¸¸¸¸¸¸···µµµµµµ···µµµ´´´···¾¾¾ÆÆÆ···¿¿¿ÀÀÀ¸¸¸¼¼¼»»»¾¾¾´´´³³³µµµµµµººº»»»³³³´´´°°°­­­¯¯¯´´´ººº»»»»»»¼¼¼¼¼¼ÀÀÀÇÇÇÊÊÊÇÇÇÉÉÉÍÍÍÑÑÑÒÒÒÑÑÑÐÐÐÎÎÎÐÐÐÔÔÔ×××àààâââäääæææäääàààààààà຺ºÂÂÂÌÌÌÐÐÐÎÎÎÐÐÐÔÔÔÙÙÙØØØßßßàààæææïïïïïïêêêíííêêêÝÝÝÛÛÛÒÒÒÍÍÍÊÊÊÀÀÀÆÆÆßßßàààÝÝÝÛÛÛÜÜÜÜÜÜØØØÒÒÒÒÒÒÒÒÒÛÛÛÕÕÕÐÐÐÍÍÍÅÅÅÆÆÆÅÅÅÅÅÅÇÇÇÉÉÉÊÊÊÌÌÌÍÍÍÍÍÍÎÎÎÎÎÎÆÆÆÇÇÇÆÆÆ¿¿¿ÃÃÿ¿¿ÍÍÍÊÊʾ¾¾ÀÀÀ¼¼¼¼¼¼ÆÆÆÕÕÕ×××ØØØÙÙÙÙÙÙÙÙÙØØØØØØãããÐÐÐÍÍÍÎÎÎÔÔÔÙÙÙÕÕÕÛÛÛÜÜÜßßßÝÝÝÛÛÛÛÛÛàààäääãããàààãããâââÝÝÝÜÜÜßßßàààÝÝÝÛÛÛÜÜÜÛÛÛÛÛÛÙÙÙØØØÙÙÙÙÙÙÛÛÛÜÜÜÜÜÜßßßçççïïïíííæææàààÜÜÜãããëëëæææàààÝÝÝÙÙÙÍÍ͸¸¸···¸¸¸¼¼¼ÃÃÃÌÌÌÆÆÆÅÅÅÍÍÍÎÎÎßßß¾¾¾ÃÃÃÅÅÅÍÍÍÑÑÑÑÑÑâââÑÑÑÒÒÒÒÒÒÊÊÊÕÕÕÔÔÔÍÍÍÌÌÌØØØâââßßßØØØÂÂÂÊÊÊÔÔÔÂÂÂÆÆÆÆÆÆÌÌÌ»»»···ÔÔÔÑÑÑÕÕÕÑÑÑÔÔÔ×××ØØØÕÕÕÕÕÕÑÑÑØØØÙÙÙÊÊÊÊÊÊÌÌÌÌÌÌÅÅż¼¼¼¼¼ÇÇÇÐÐÐÑÑÑÙÙÙÊÊÊÅÅÅÅÅÅÀÀÀÅÅÅÆÆÆ»»»¼¼¼¾¾¾¿¿¿»»»µµµ°°°¯¯¯±±±´´´³³³³³³´´´³³³±±±´´´»»»µµµ³³³­­­ÀÀÀÆÆƸ¸¸ººº···¼¼¼······¸¸¸´´´···»»»···ººº±±±©©©¦¦¦¬¬¬µµµ¼¼¼¾¾¾¾¾¾¾¾¾ÂÂÂÉÉÉÊÊÊÇÇÇÉÉÉÎÎÎÍÍÍÐÐÐÔÔÔÕÕÕÑÑÑÑÑÑÕÕÕ×××äääçççâââÛÛÛâââíííëëëßßß»»»ÃÃÃÌÌÌÐÐÐÎÎÎÎÎÎÒÒÒØØØÝÝÝäääâââßßßãããäääçççòòòßßßÕÕÕÙÙÙÐÐÐÇÇÇÅÅÅÀÀÀÍÍÍßßßâââãããÝÝÝÔÔÔÍÍÍÎÎÎÔÔÔÒÒÒÒÒÒÙÙÙÐÐÐÆÆÆÃÃþ¾¾ÆÆÆÂÂÂÃÃÃÆÆÆÉÉÉÌÌÌÍÍÍÍÍÍÍÍÍÉÉÉÎÎÎÆÆÆÅÅÅÅÅÅÆÆÆÕÕÕÙÙÙÑÑÑÕÕÕÎÎÎÅÅÅ¿¿¿···¾¾¾ÔÔÔÍÍÍÐÐÐÒÒÒÔÔÔÕÕÕÕÕÕÕÕÕÕÕÕÝÝÝÍÍÍÌÌÌÒÒÒÜÜÜßßßÛÛÛäääÜÜÜââââââÝÝÝÜÜÜßßßâââàààÛÛÛààààààÝÝÝÜÜÜßßßàààßßßÛÛÛÜÜÜÜÜÜÛÛÛÙÙÙØØØÙÙÙÛÛÛÝÝÝÝÝÝÝÝÝàààêêêóóóòòòëëëäääãããêêêêêêÒÒÒ¸¸¸»»»ÑÑÑâââÐÐм¼¼´´´³³³···ÀÀÀÌÌÌÉÉÉÅÅÅÉÉÉÉÉÉÝÝݺººÂÂÂÅÅÅÉÉÉÌÌÌÐÐÐàààÌÌÌÐÐÐÒÒÒÃÃÃ×××ÛÛÛÍÍÍÀÀÀÎÎÎØØØÎÎÎÅÅÅÂÂÂÔÔÔ×××ÆÆÆÃÃÃÑÑÑÐÐп¿¿···¼¼¼ÐÐÐÙÙÙÑÑÑÐÐÐ×××ØØØÝÝÝÐÐÐÍÍÍÔÔÔÔÔÔÔÔÔÒÒÒÌÌÌÍÍÍÊÊÊÌÌ̼¼¼»»»ÑÑÑÕÕÕÍÍÍÊÊÊÆÆÆÅÅÅÇÇÇÊÊÊÆÆƼ¼¼µµµÂ¼¼¼¯¯¯»»»ÅÅÅ¿¿¿¾¾¾°°°¯¯¯¯¯¯¯¯¯¯¯¯­­­¬¬¬­­­¯¯¯´´´±±±ÃÃþ¾¾°°°´´´¬¬¬µµµ°°°¯¯¯¬¬¬¬¬¬µµµ»»»´´´´´´¯¯¯©©©©©©±±±ººº»»»¸¸¸¾¾¾¿¿¿ÃÃÃÆÆÆÉÉÉÊÊÊÌÌÌÌÌÌÎÎÎÐÐÐÕÕÕÎÎÎÕÕÕÙÙÙÐÐÐÛÛÛÕÕÕäääØØØßßßòòòîîîííííííàààÂÂÂÊÊÊÍÍÍÐÐÐØØØÎÎÎÛÛÛØØØÛÛÛÝÝÝßßßàààâââããããããÝÝÝÒÒÒÌÌÌÉÉÉÍÍ;¾¾´´´ÙÙÙ×××ÝÝÝÔÔÔÉÉÉÌÌÌÌÌÌÆÆÆÇÇÇ×××ÒÒÒÛÛÛÕÕÕ¾¾¾ºººÃÃÿ¿¿¾¾¾ÀÀÀÅÅÅÉÉÉÌÌÌÍÍÍÍÍÍÌÌÌÌÌÌÊÊÊÆÆÆÍÍÍÛÛÛØØØÐÐÐÒÒÒÒÒÒÎÎÎÐÐÐÕÕÕ×××ÑÑÑÐÐÐÑÑÑÑÑÑÔÔÔ×××ØØØØØØÕÕÕÒÒÒÐÐÐÝÝÝÝÝÝÕÕÕÛÛÛÝÝÝÜÜÜßßß×××ÜÜÜàààßßßßßßæææäääâââäääÜÜÜÛÛÛÙÙÙÙÙÙÛÛÛÝÝÝàààâââààààààßßßÝÝÝÛÛÛÙÙÙÙÙÙØØØààààààâââãããæææêêêíííïïïíííëëëëëëêêêÙÙÙººº···ÑÑÑÔÔÔµµµ°°°³³³³³³···¼¼¼ÊÊÊÂÂÂÀÀÀÀÀÀÊÊÊÊÊÊÎÎλ»»ÅÅÅÂÂÂÇÇÇØØØßßß×××ÒÒÒÑÑÑÉÉÉÇÇÇÙÙÙÙÙÙÍÍÍÉÉÉÅÅÅÃÃÃÊÊÊÍÍÍÍÍÍÎÎÎÐÐÐÎÎÎÉÉÉÅÅÅÅÅŵµµÊÊÊ×××ÕÕÕÐÐÐÐÐÐÔÔÔØØØÜÜÜÎÎÎÌÌÌÐÐÐÎÎÎÎÎÎÐÐÐÌÌÌÊÊÊÃÃÃÆÆƾ¾¾¾¾¾ÐÐÐÐÐÐÉÉÉÃÃÃÉÉÉÍÍÍÊÊʼ¼¼¼¼¼ÀÀÀººº­­­¯¯¯ÀÀÀÅÅÅÅÅÅÉÉÉ¿¿¿³³³¦¦¦¥¥¥°°°¸¸¸¸¸¸´´´ººº¾¾¾ÇÇÇ···±±±©©©³³³¯¯¯¬¬¬¥¥¥¥¥¥¨¨¨¨¨¨¬¬¬­­­¨¨¨³³³···±±±©©©¬¬¬···ººº³³³ºººººº»»»¼¼¼¿¿¿ÅÅÅÊÊÊÐÐÐÒÒÒÕÕÕÛÛÛÕÕÕØØØÙÙÙÐÐÐÙÙÙàààæææÛÛÛßßßïïïíííèèèîîîæææÃÃÃÊÊÊÎÎÎÐÐÐÕÕÕÎÎÎØØØ×××ÙÙÙÝÝÝàààââââââàààßßßÝÝÝÔÔÔÑÑÑÍÍÍÇÇǸ¸¸¸¸¸ÝÝÝØØØÕÕÕÌÌÌÇÇÇÍÍÍÑÑÑÐÐÐÎÎÎÎÎÎÍÍÍØØØ×××¾¾¾Â»»»¾¾¾ÀÀÀÅÅÅÉÉÉÌÌÌÍÍÍÍÍÍÍÍÍÐÐÐÆÆÆÃÃÃÍÍÍ×××ÛÛÛ×××ÎÎÎÑÑÑÎÎÎÎÎÎÐÐÐÎÎÎÊÊÊÍÍÍÑÑÑÎÎÎÎÎÎÑÑÑÔÔÔ×××ØØØ×××ÕÕÕ×××ßßßÜÜÜàààÝÝÝ×××ÝÝÝÛÛÛßßßææææææãããæææàààÜÜÜâââßßßÝÝÝÜÜÜÜÜÜÝÝÝßßßâââããããããâââàààßßßÝÝÝÜÜÜÜÜÜÜÜÜàààââââââãããæææèèèêêêëëëêêêçççäääêêêæææÑÑÑÍÍÍÝÝÝÜÜÜ´´´ªªª³³³···¸¸¸ºººÇÇÇÂÂÂÂÂÂÂÂÂÊÊÊÍÍÍÑÑÑ»»»¿¿¿ÇÇÇÇÇÇÔÔÔÛÛÛÕÕÕÒÒÒÔÔÔÐÐÐÅÅÅÐÐÐ×××ÕÕÕÒÒÒÌÌÌÆÆÆÆÆÆÒÒÒÍÍÍÍÍÍÑÑÑÑÑÑÉÉÉÂÂÂÀÀÀÀÀÀ×××ÙÙÙÎÎÎÑÑÑÔÔÔÒÒÒÔÔÔÕÕÕÌÌÌÍÍÍÒÒÒÐÐÐÐÐÐÒÒÒÎÎÎÎÎÎÅÅÅÉÉÉÅÅÅÇÇÇ×××ÒÒÒÊÊÊÀÀÀÉÉÉÍÍÍÇÇǼ¼¼¸¸¸¾¾¾ÃÃúºº©©©···ÃÃü¼¼¼¼¼ÀÀÀÀÀÀÊÊʺººªªªªªª¸¸¸Â¼¼¼¿¿¿ÆÆÆÆÆÆ°°°···¸¸¸ÀÀÀ¼¼¼¼¼¼µµµ···ºººµµµ´´´°°°¥¥¥¨¨¨´´´µµµ©©©©©©µµµ»»»´´´ººº»»»¾¾¾¿¿¿ÀÀÀÆÆÆÍÍÍÒÒÒÒÒÒÕÕÕÛÛÛ×××ØØØ×××ÎÎÎÔÔÔæææâââÛÛÛÝÝÝíííîîîçççòòòëëëÂÂÂÉÉÉÒÒÒÑÑÑÕÕÕÑÑÑÕÕÕÔÔÔØØØÜÜÜßßßàààßßßÜÜÜÙÙÙÑÑÑÍÍÍÎÎÎÅÅźºº»»»ÉÉÉãããäääÕÕÕÌÌÌÊÊÊÌÌÌÎÎÎÍÍÍÇÇÇÍÍÍÊÊÊÒÒÒÒÒÒÅÅÅÂÂÂÅÅž¾¾¾¾¾ÀÀÀÅÅÅÉÉÉÌÌÌÍÍÍÍÍÍÌÌÌÊÊÊÅÅÅÍÍÍÕÕÕÕÕÕÙÙÙÙÙÙÌÌÌÔÔÔÔÔÔ×××ØØØÕÕÕÒÒÒÕÕÕÛÛÛÒÒÒÐÐÐÐÐÐÑÑÑÕÕÕÙÙÙÙÙÙÙÙÙÒÒÒÛÛÛÛÛÛßßßÛÛÛÔÔÔÙÙÙØØØÒÒÒÜÜÜàààâââæææäääâââçççâââààààààßßßßßßàààãããäääçççæææãããâââàààààààààâââããããããäääææææææçççççççççóóóíííçççëëëîîîäääÛÛÛßßßÐÐб±±­­­³³³´´´······ÀÀÀÀÀÀÃÃÃÂÂÂÉÉÉÍÍÍ×××¼¼¼ºººÇÇÇÆÆÆÐÐÐÜÜÜÙÙÙÒÒÒÐÐÐÍÍÍÊÊÊÎÎÎÙÙÙßßß×××ÍÍÍÉÉÉÆÆÆÍÍÍÕÕÕÒÒÒÉÉÉÉÉÉÎÎÎÇÇÇ···ÕÕÕÛÛÛÔÔÔÍÍÍÔÔÔÙÙÙÒÒÒÊÊÊÌÌÌÊÊÊÒÒÒÙÙÙ×××××××××ÑÑÑÐÐÐÉÉÉÌÌÌÅÅÅÉÉÉÜÜÜØØØÊÊÊÆÆÆÆÆƼ¼¼»»»¾¾¾¾¾¾¼¼¼¯¯¯©©©ºººººº³³³¸¸¸···¾¾¾ÀÀÀ¾¾¾»»»¼¼¼ÀÀÀÃÃÃÂÂÂÀÀÀ¿¿¿ÀÀÀººº¬¬¬ÅÅÅÊÊÊÊÊʾ¾¾¾¾¾ÃÃÃÅÅÅÅÅÅÉÉÉÅÅÅ´´´¤¤¤±±±µµµ­­­¨¨¨¯¯¯µµµµµµ···»»»ÀÀÀÅÅÅÅÅÅÆÆÆÊÊÊÍÍÍÎÎÎÑÑÑÕÕÕÒÒÒÑÑÑÎÎÎÍÍÍÑÑÑßßß×××ØØØÜÜÜëëëïïïæææóóóæææÀÀÀÇÇÇ×××ÔÔÔÕÕÕÔÔÔÒÒÒÕÕÕ×××ÙÙÙÜÜÜÝÝÝÜÜÜØØØÕÕÕÐÐÐÌÌÌÊÊÊÀÀÀ¼¼¼ÎÎÎàààãããÜÜÜÌÌÌÉÉÉÎÎÎÌÌÌÍÍÍÑÑÑÎÎÎÍÍÍÆÆÆÇÇÇÆÆƾ¾¾¾¾¾Â¾¾¾¾¾¾ÀÀÀÅÅÅÉÉÉÌÌÌÌÌÌÌÌÌÊÊÊÂÂÂÍÍÍÜÜÜààà×××ÔÔÔÔÔÔÐÐÐÎÎÎÐÐÐÒÒÒ×××××××××ÕÕÕ×××ÙÙÙ×××ÔÔÔÔÔÔ×××ØØØØØØÕÕÕÛÛÛÝÝÝØØØÝÝÝàààÜÜÜßßßØØØÕÕÕÜÜÜÜÜÜàààçççäääßßßàààââââââââââââàààâââäääæææêêêèèèæææäääääääääæææçççæææççççççççççççæææäääãããúúúòòòííííííïïïêêêàààÜÜܵµµ°°°···±±±¬¬¬´´´···¸¸¸ÀÀÀÃÃÃÀÀÀÆÆÆÍÍÍÙÙÙ¿¿¿¸¸¸ÃÃÃÃÃÃÑÑÑãããäääÕÕÕÌÌÌÉÉÉÐÐÐÎÎÎÜÜÜäääØØØÐÐÐÔÔÔÕÕÕÐÐÐÔÔÔÑÑÑÉÉÉÆÆÆÊÊÊÆÆƼ¼¼ããã×××ÒÒÒÒÒÒÔÔÔÕÕÕÒÒÒÉÉÉÌÌÌÍÍÍÔÔÔØØØÔÔÔÔÔÔÕÕÕÐÐÐÇÇÇÇÇÇÊÊʼ¼¼¿¿¿ØØØ×××ÇÇÇÉÉÉÅÅż¼¼···»»»ÀÀÀ¾¾¾µµµ°°°ºººÂ´´´³³³µµµ­­­µµµ³³³¸¸¸¾¾¾ÀÀÀÀÀÀ¿¿¿¿¿¿ÀÀÀ¼¼¼µµµ¯¯¯ªªªÅÅÅÃÃþ¾¾ÂÂÂÅÅÅÆÆÆ¿¿¿»»»Âººº¡¡¡ªªª±±±···´´´ªªª¤¤¤¨¨¨¯¯¯±±±´´´ººº¾¾¾ÀÀÀÃÃÃÆÆÆÉÉÉÌÌÌÎÎÎÐÐÐÐÐÐÌÌÌÊÊÊÑÑÑÔÔÔÔÔÔÐÐÐØØØÜÜÜçççëëëâââëëë×××¾¾¾ÉÉÉØØØ××××××ÕÕÕÒÒÒ×××ÕÕÕÕÕÕ×××ØØØØØØÕÕÕÑÑÑÕÕÕÇÇÇÇÇÇÑÑÑ×××âââèèèÝÝÝÔÔÔÉÉÉÍÍÍÑÑÑÉÉÉÆÆÆÌÌÌÌÌÌÉÉÉÂÂÂÀÀÀ¿¿¿»»»¼¼¼¿¿¿»»»¿¿¿ÂÂÂÅÅÅÉÉÉÊÊÊÊÊÊÉÉÉÉÉÉÌÌÌÙÙÙàààÝÝÝØØØÑÑÑÑÑÑÙÙÙÜÜÜØØØÒÒÒÒÒÒ×××ÙÙÙ×××ÒÒÒ×××ÕÕÕÒÒÒÒÒÒÔÔÔÔÔÔÒÒÒÑÑÑ×××ÙÙÙÑÑÑÕÕÕ×××ÔÔÔÙÙÙÕÕÕÜÜÜÝÝÝÛÛÛâââïïïñññçççäääâââãããäääãããââââââäääçççêêêêêêèèèççççççèèèèèèêêêêêêêêêêêêèèèçççæææãããâââïïïëëëêêêëëëëëëèèèäääàà຺º´´´ººº°°°©©©³³³µµµ···¾¾¾Â¾¾¾ÂÂÂÉÉÉÙÙÙ¾¾¾ÀÀÀÃÃÃÑÑÑäääêêêÝÝÝÔÔÔÕÕÕ×××ÎÎÎØØØäääàààßßßâââÝÝÝÛÛÛÎÎÎÌÌÌÒÒÒÍÍÍ¿¿¿ÀÀÀÑÑÑàààÕÕÕ×××ØØØÎÎÎÍÍÍÒÒÒÐÐÐÑÑÑÎÎÎÑÑÑÐÐÐÉÉÉÍÍÍÐÐÐÊÊÊÇÇÇÇÇÇÍÍ;¾¾¼¼¼ÔÔÔ×××ÎÎÎÆÆÆÇÇǺººººº¾¾¾¼¼¼µµµ¦¦¦¸¸¸ºººµµµÂÂÂÇÇÇÂÂÂÌÌÌ´´´´´´´´´···ººº¼¼¼¼¼¼¼¼¼´´´¯¯¯³³³±±±Â¾¾¾ÃÃÃÆÆƺºº¾¾¾ÀÀÀ»»»»»»ÃÃû»»¡¡¡©©©­­­´´´···°°°¦¦¦©©©³³³µµµµµµ···ººº¿¿¿ÆÆÆÌÌÌÐÐÐÊÊÊÍÍÍÍÍÍÐÐÐÊÊÊÉÉÉ××××××ÎÎÎÐÐÐ×××ÙÙÙßßßâââßßßâââÅÅÅÀÀÀÊÊÊÕÕÕ×××ÕÕÕÕÕÕÒÒÒ×××ÔÔÔÒÒÒÒÒÒÕÕÕÔÔÔÑÑÑÍÍÍÉÉɸ¸¸¼¼¼ÝÝÝêêêâââßßßÕÕÕÑÑÑÎÎÎÑÑÑÎÎÎÅÅž¾¾¿¿¿ÀÀÀÇÇÇÅÅÅÅÅÅÇÇÇÇÇÇÇÇÇÆÆÆÂÂÂÂÂÂÃÃÃÆÆÆÉÉÉÉÉÉÉÉÉÆÆÆÅÅÅßßßßßßÕÕÕÒÒÒ×××ÔÔÔÔÔÔâââñññèèèÜÜÜÒÒÒÔÔÔÙÙÙÙÙÙÕÕÕÎÎÎÎÎÎÐÐÐÐÐÐÑÑÑÒÒÒÔÔÔÕÕÕÔÔÔÜÜÜØØØØØØÒÒÒÍÍÍÙÙÙÝÝÝââââââàààçççùùùÿÿÿõõõòòòæææèèèêêêçççäääâââãããæææèèèèèèèèèèèèêêêêêêêêêêêêêêêêêêèèèçççæææãããâââàààèèèäääçççêêêæææââââââßßßÒÒÒ¸¸¸³³³°°°­­­³³³´´´»»»¼¼¼ÀÀÀ¾¾¾ÃÃÃÇÇÇÒÒÒ¿¿¿ÀÀÀÃÃÃÇÇÇÎÎÎÛÛÛäääààààààèèèäääÛÛÛÙÙÙâââççççççßßßÔÔÔßßßÑÑÑÐÐÐÕÕÕÍÍ;¾¾ÇÇÇàààÙÙÙÙÙÙÙÙÙÔÔÔÍÍÍÎÎÎÒÒÒÒÒÒÍÍÍÌÌÌÐÐÐÎÎÎÊÊÊÎÎÎÎÎÎÆÆÆÊÊÊÅÅÅÎÎÎÇÇÇÀÀÀÍÍÍÔÔÔÙÙÙÇÇÇÍÍÍÊÊÊÀÀÀ¼¼¼¿¿¿¾¾¾······»»»···ÀÀÀÎÎÎÊÊÊÉÉÉÎÎÎÆÆÆ¿¿¿¸¸¸µµµ¸¸¸ººº¸¸¸µµµ¯¯¯¯¯¯¾¾¾¼¼¼ÅÅÅÂÂÂÇÇǾ¾¾»»»···»»»¿¿¿¿¿¿¾¾¾³³³¡¡¡¤¤¤ªªª´´´¸¸¸µµµ³³³´´´ºººÀÀÀ¼¼¼»»»¼¼¼ÃÃÃÉÉÉÌÌÌÌÌÌÆÆÆÊÊÊÌÌÌÐÐÐÇÇÇÆÆÆÕÕÕÔÔÔÊÊÊÔÔÔÔÔÔÒÒÒÔÔÔÛÛÛäääãã㸸¸ÆÆÆÍÍÍÐÐÐÒÒÒÒÒÒÒÒÒÔÔÔÕÕÕÒÒÒÑÑÑÒÒÒÔÔÔÒÒÒÍÍÍÇÇÇÅÅÅÂÂÂÆÆÆßßßâââÒÒÒÒÒÒÐÐÐÇÇÇÌÌÌÉÉÉÂÂÂÂÂÂÀÀÀ¿¿¿ÀÀÀ¿¿¿¿¿¿ÀÀÀÃÃÃÆÆÆÉÉÉÇÇÇÇÇÇÅÅÅÆÆÆÇÇÇÉÉÉÉÉÉÆÆÆÃÃÃÂÂÂæææØØØÎÎÎÑÑÑÔÔÔÑÑÑØØØæææëëëèèèßßßÒÒÒÍÍÍÐÐÐÒÒÒÑÑÑÐÐÐÒÒÒÒÒÒÒÒÒÒÒÒÕÕÕÜÜÜââââââëëëèèèèèèãããÝÝÝèèèëëëïïïñññîîîïïïøøøöööïïïïïïïïïñññòòòîîîçççââââââãããäääæææèèèêêêëëëêêêêêêèèèèèèèèèæææãããàààßßßÝÝÝÝÝÝíííâââäääêêêãããÝÝÝÜÜÜÙÙÙÔÔÔµµµ°°°°°°¯¯¯±±±´´´¾¾¾¼¼¼¿¿¿ÀÀÀÉÉÉÆÆÆÌÌ̸¸¸ÀÀÀÃÃÃÉÉÉÉÉÉÊÊÊÒÒÒÕÕÕÛÛÛçççêêêçççßßßÛÛÛàààâââÛÛÛÕÕÕÙÙÙÝÝÝÜÜÜÐÐÐÅÅÅÆÆÆÕÕÕãããÕÕÕÝÝÝÕÕÕÊÊÊÐÐÐ×××ÒÒÒÎÎÎÃÃÃÇÇÇÑÑÑ×××ÕÕÕ×××ÒÒÒÅÅÅÅÅÅ»»»ÇÇÇÉÉÉÀÀÀÀÀÀÉÉÉÙÙÙÌÌÌÐÐÐÍÍÍÃÃÃÂÂÂÅÅÅ¿¿¿´´´Â¸¸¸±±±ÊÊÊÔÔÔÇÇÇÌÌÌÎÎÎ×××ÑÑÑÇÇÇÀÀÀººº···´´´±±±¯¯¯°°°ÂÂÂÀÀÀÆÆƼ¼¼žžž¦¦¦›››¤¤¤···»»»´´´¬¬¬¡¡¡¦¦¦±±±¸¸¸¸¸¸···ºººººº···ÀÀÀ¾¾¾»»»¾¾¾ÃÃÃÃÃÿ¿¿»»»ÀÀÀÆÆÆÇÇÇÎÎÎÅÅÅÀÀÀÑÑÑÌÌÌÆÆÆÕÕÕÑÑÑÍÍÍÍÍÍØØØíííêêê±±±ÌÌÌÐÐÐÌÌÌÐÐÐÎÎÎÐÐÐÕÕÕÔÔÔÑÑÑÑÑÑÒÒÒÕÕÕÒÒÒÊÊÊÃÃÃ×××æææãããßßßÒÒÒÆÆÆÍÍÍÊÊÊÎÎÎÔÔÔÆÆÆ»»»¿¿¿¿¿¿···µµµ°°°¯¯¯­­­¯¯¯´´´ººº¾¾¾ÂÂÂÆÆÆÇÇÇÉÉÉÉÉÉÇÇÇÆÆÆÂÂÂÀÀÀàààÎÎÎÑÑÑÙÙÙÑÑÑÌÌÌÙÙÙçççâââèèèèèèßßßÕÕÕÔÔÔ××××××ÙÙÙÛÛÛÛÛÛØØØ×××ÙÙÙãããëëëãããçççãããææææææâââçççäääèèèïïïïïïïïïóóóòòòïïïõõõöööøøøøøøòòòèèèâââàààâââãããäääçççêêêëëëêêêèèèççççççæææãããßßßÝÝÝÜÜÜÛÛÛÛÛÛíííÝÝÝßßßèèèæææßßßÝÝÝÛÛÛ¾¾¾°°°³³³°°°ªªª±±±´´´»»»»»»¿¿¿ÃÃÃÍÍÍÇÇÇÆÆƱ±±¾¾¾ÂÂÂÉÉÉÅÅÅ¿¿¿ÃÃÃÆÆÆÌÌÌ×××ÝÝÝèèèâââÔÔÔÔÔÔÙÙÙàààíííÐÐÐØØØÙÙÙÌÌÌÎÎÎâââãããÛÛÛæææÝÝÝÕÕÕÑÑÑÒÒÒÔÔÔÎÎÎÊÊÊÑÑÑÒÒÒÔÔÔÕÕÕ×××ÕÕÕÕÕÕÔÔÔÎÎÎÆÆƼ¼¼ÂÂÂÅÅÅÆÆÆßßßÕÕÕÆÆÆÐÐо¾¾ÀÀÀ»»»­­­¿¿¿¿¿¿ÆÆÆÐÐÐÑÑÑÍÍÍÍÍÍÒÒÒØØØ×××ÕÕÕÑÑÑÇÇǸ¸¸°°°°°°©©©±±±¿¿¿ÉÉÉÉÉɵµµ­­­¥¥¥¤¤¤žžž¡¡¡©©©¨¨¨¦¦¦¯¯¯¯¯¯¸¸¸´´´°°°¢¢¢¯¯¯´´´¿¿¿¼¼¼»»»µµµ³³³ºººÆÆÆÊÊÊÇÇÇÇÇÇ···µµµºººÇÇÇÊÊÊÃÃÃ×××ØØØÐÐÐÍÍÍÕÕÕØØØÔÔÔ×××ÝÝÝßß߸¸¸ÉÉÉÐÐÐÊÊÊÔÔÔÍÍÍÔÔÔ×××ÑÑÑÑÑÑÕÕÕÎÎÎÅÅÅÉÉÉÕÕÕêêêØØØÌÌÌÊÊÊÆÆÆ¿¿¿ÃÃÃÎÎÎÀÀÀÇÇÇÀÀÀ»»»°°°­­­¼¼¼ÀÀÀ¿¿¿ÀÀÀÇÇÇÇÇǾ¾¾´´´±±±ºººµµµ¾¾¾ÉÉÉÉÉÉÇÇÇÆÆÆÀÀÀÛÛÛÑÑÑÍÍÍÑÑÑØØØÝÝÝæææïïïßßßâââãããßßßØØØÕÕÕØØØÜÜÜÑÑÑãããíííçççäääëëëîîîêêêèèèãããääääääøøøêêêääääääêêêíííïïïñññïïïïïïñññóóóøøøòòòõõõêêêâââãããÜÜÜãããæææÜÜÜäääñññêêêâââäääæææääääääâââßßßÜÜÜÙÙÙØØØ×××èèèæææãããâââââââââßßßÜÜÜØØؼ¼¼¯¯¯°°°¬¬¬°°°¼¼¼Â¿¿¿ÀÀÀÉÉÉÒÒÒ×××ÔÔÔÑÑÑÑÑѺººººº¿¿¿ÆÆÆÇÇÇÆÆÆÇÇÇÌÌÌÙÙÙïïïæææØØØÝÝÝíííóóóßßßßßßÒÒÒÊÊÊÎÎÎÙÙÙàààÜÜÜ×××ÝÝÝÙÙÙ×××ÕÕÕÑÑÑÌÌÌÌÌÌÎÎÎÔÔÔÕÕÕ×××ØØØØØØØØØ×××ÕÕÕÒÒÒÊÊÊÇÇÇ¿¿¿»»»»»»ÒÒÒÕÕÕÆÆÆÐÐо¾¾¸¸¸»»»ººº¸¸¸ÀÀÀÍÍÍÒÒÒÕÕÕÒÒÒÎÎÎÊÊÊÌÌÌÍÍÍÒÒÒÕÕÕÎÎξ¾¾±±±¬¬¬´´´»»»ÃÃÃÉÉÉÉÉÉÃÃû»»´´´ººº´´´¨¨¨¢¢¢¦¦¦¥¥¥¨¨¨³³³³³³»»»¸¸¸³³³©©©­­­±±±···ÀÀÀÀÀÀ¼¼¼µµµ···¾¾¾ÅÅÅÇÇÇÇÇÇÅÅÅÃÃúºº¼¼¼ÅÅÅÅÅÅÕÕÕÉÉÉÌÌÌÔÔÔÜÜÜØØØÑÑÑ×××ääääää¾¾¾¾¾¾ÀÀÀÂÂÂÌÌÌÇÇÇÎÎÎÑÑÑÍÍÍÌÌÌÌÌÌÉÉÉÊÊÊ×××çççàààÕÕÕÎÎÎÎÎÎÎÎÎÊÊÊÌÌÌÑÑѵµµÂ¼¼¼µµµµµµ¼¼¼ÉÉÉÃÃÃÃÃÃÂÂÂÃÃÃÉÉÉÊÊÊÆÆÆÃÃÿ¿¿´´´ºººÉÉÉÊÊÊÅÅÅÃÃÃÂÂÂÝÝÝÕÕÕÑÑÑ×××àààãããâââààà×××ÛÛÛàààæææèèèêêêêêêêêêÝÝÝæææèèèääääääçççäääÝÝÝÛÛÛÛÛÛæææäääíííèèèîîîçççïïïíííèèèääääääçççíííñññòòòñññúúúõõõñññïïïæææèèèëëëäääççççççßßßÝÝÝââââââàààßßßÜÜÜÙÙÙØØØ×××××××××ààààààâââãããäääãããâââàààæææÍÍͺºº´´´±±±´´´ººº¼¼¼ÂÂÂÂÂÂÅÅÅÌÌÌÐÐÐÑÑÑÕÕÕÜÜÜàààâââçççëëëäää×××ÍÍÍÊÊÊÂÂÂÝÝÝäääãããæææÝÝÝÔÔÔÐÐÐÜÜÜÊÊÊÆÆÆÜÜÜêêêãããÝÝÝÝÝÝÔÔÔÕÕÕ×××ÕÕÕÍÍÍÅÅÅÊÊÊÔÔÔ×××ØØØÙÙÙÙÙÙÙÙÙÙÙÙ××××××ÎÎÎÇÇÇÊÊÊÆÆÆ¿¿¿µµµ···ÑÑÑØØØÆÆÆÌÌÌÀÀÀ¾¾¾´´´¼¼¼Â¸¸¸ÇÇÇÒÒÒÔÔÔÔÔÔÕÕÕÎÎÎÅÅÅÂÂÂÅÅÅÍÍÍÕÕÕÒÒÒÆÆƸ¸¸³³³¿¿¿ÀÀÀÃÃÃÅÅÅÃÃÃÀÀÀ¼¼¼ºººÂ¾¾¾±±±¨¨¨¨¨¨¤¤¤¦¦¦°°°µµµµµµµµµªªª©©©¨¨¨°°°³³³¿¿¿¿¿¿¼¼¼···´´´¸¸¸»»»»»»¿¿¿ÆÆÆÆÆÆ»»»¿¿¿ÇÇǼ¼¼¸¸¸ÀÀÀÆÆÆÑÑÑØØØÔÔÔÐÐÐØØØçççóóóÕÕÕ¾¾¾»»»ÀÀÀÃÃÃÂÂÂÆÆÆÌÌÌÇÇÇÃÃÃÃÃÃÉÉÉÒÒÒÜÜÜãããÔÔÔÎÎÎÇÇǼ¼¼¸¸¸´´´±±±ÃÃü¼¼³³³¼¼¼ÃÃÿ¿¿¾¾¾µµµ»»»¼¼¼¾¾¾¾¾¾¿¿¿ÃÃÃÇÇÇÉÉÉÆÆÆ´´´µµµÆÆÆÉÉÉÃÃÃÃÃÃÃÃÃ×××ÕÕÕÒÒÒÒÒÒÙÙÙãããæææäääÜÜÜÜÜÜÝÝÝãããçççêêêèèèæææíííèèèæææçççêêêèèèâââÛÛÛ³³³¼¼¼ÒÒÒ×××ÙÙÙâââñññèèèîîîíííëëëëëëíííïïïïïïñññîîîïïïùùùùùùøøøöööïïïñññóóóóóóóóóëëëààààààäääãããèèèæææâââÜÜÜÙÙÙ×××××××××ææææææäääâââàààßßßßßßààààààÒÒÒ»»»¯¯¯³³³¸¸¸¾¾¾ÅÅÅÃÃÃÅÅÅÊÊÊÐÐÐÐÐÐÍÍÍÎÎÎÔÔÔÕÕÕÕÕÕØØØÜÜÜÜÜÜØØØÙÙÙÝÝÝÊÊÊÑÑÑâââëëëæææ×××ÐÐÐÜÜÜÎÎÎÒÒÒÛÛÛíííîîîâââßßßÝÝÝÐÐÐÕÕÕ×××ÑÑÑÉÉÉÉÉÉÐÐÐ×××ØØØØØØÙÙÙÙÙÙÙÙÙØØØ×××ÕÕÕÍÍÍÇÇÇÍÍÍÇÇǼ¼¼´´´ºººÔÔÔÛÛÛÆÆÆÅÅÅ»»»¾¾¾¸¸¸¿¿¿¼¼¼ÆÆÆÎÎÎÔÔÔÒÒÒÑÑÑÐÐÐÌÌÌÆÆÆÅÅÅÃÃÃÇÇÇÐÐÐÒÒÒÌÌÌÅÅÅÂÂÂÇÇÇÇÇÇÆÆÆÅÅÅÃÃÃÂÂÂÀÀÀ¿¿¿¾¾¾Â¾¾¾···´´´­­­¨¨¨¬¬¬¼¼¼µµµ´´´¥¥¥¬¬¬ªªªººº¾¾¾¾¾¾¾¾¾»»»ººººººººº¸¸¸µµµºººÀÀÀ¼¼¼´´´¼¼¼ÉÉÉÅÅż¼¼»»»¾¾¾ÂÂÂÃÃÃÅÅÅÎÎÎÙÙÙäääØØØ»»»¸¸¸¿¿¿¸¸¸ººº¼¼¼µµµµµµ¸¸¸ÀÀÀÒÒÒâââäääÝÝÝÌÌÌÌÌÌÇÇÇÂÂÂÂÂÂÆÆÆÅÅÅÀÀÀººº´´´°°°ÂÂÂÆÆƺººººº»»»¸¸¸¼¼¼¼¼¼¸¸¸···»»»ÀÀÀÃÃÃÉÉɸ¸¸µµµ¿¿¿ÃÃÃÅÅÅÆÆÆ¿¿¿ÉÉÉÎÎÎÊÊÊÉÉÉÐÐÐØØØÜÜÜàààÜÜÜ×××ÔÔÔÔÔÔ×××ÛÛÛÜÜÜëëëãããàààæææêêêçççâââààà°°°´´´¼¼¼¼¼¼¿¿¿ÐÐÐçççîîîäääæææèèèîîîòòòóóóñññîîîóóóòòòóóóòòòòòòöööùùùÿÿÿóóóöööùùùóóóèèèââââââäääßßßÝÝÝÛÛÛÛÛÛÜÜÜàààãããæææîîîëëëçççàààÜÜÜÝÝÝâââæææâââÝÝÝÆÆÆ°°°­­­¯¯¯³³³¿¿¿ÃÃÃÆÆÆÌÌÌÑÑÑÎÎÎÊÊÊÌÌÌÑÑÑÙÙÙÔÔÔÐÐÐÐÐÐÐÐÐÒÒÒÜÜÜæææÛÛÛÀÀÀÐÐÐÛÛÛÑÑÑÒÒÒØØØàààÉÉÉæææîîîëëëàààÙÙÙÛÛÛÍÍÍÑÑÑØØØÕÕÕÊÊÊÉÉÉÔÔÔÙÙÙÕÕÕ×××ØØØØØØØØØØØØÕÕÕÔÔÔÒÒÒÔÔÔÍÍÍÑÑÑÇÇǸ¸¸´´´¼¼¼ÔÔÔÔÔÔÉÉÉÆÆƸ¸¸»»»ºººÃÃø¸¸ÒÒÒÒÒÒÔÔÔ×××ÒÒÒÉÉÉÃÃÃÅÅÅÇÇÇÆÆÆÉÉÉÐÐÐÔÔÔÐÐÐÍÍÍÌÌÌÌÌÌÊÊÊÉÉÉÇÇÇÆÆÆÆÆÆÅÅÅÅÅÅ¿¿¿ÇÇÇÉÉÉÅÅÅ···¬¬¬ªªª¸¸¸°°°¯¯¯¤¤¤ªªª¨¨¨µµµººº¾¾¾¾¾¾¿¿¿¾¾¾ºººººº¾¾¾Â¼¼¼ÇÇÇÅÅž¾¾»»»¸¸¸¼¼¼ÅÅÅÀÀÀ¿¿¿¿¿¿ÀÀÀÃÃÃÆÆÆÍÍÍÕÕÕäääëëëÛÛÛÝÝÝæææÝÝÝâââäääçççíííîîîëëëëëëêêêàààÒÒÒÎÎÎÍÍÍÃÃõµµ°°°³³³±±±ªªª­­­ººº»»»¼¼¼µµµ±±±ÀÀÀÆÆÆÅÅÅÇÇÇÇÇǼ¼¼ººº»»»¿¿¿ÆÆÆ¿¿¿¼¼¼¸¸¸ºººÆÆÆÊÊÊ¿¿¿»»»ÌÌÌØØØÕÕÕÎÎÎÍÍÍÎÎÎÍÍÍÔÔÔÒÒÒÐÐÐÌÌÌÉÉÉÎÎÎÙÙÙãããàààÜÜÜÝÝÝääääääßßßßßßäääßßßÔÔÔ¾¾¾³³³±±±¾¾¾ÔÔÔîîîïïïîîîîîîñññõõõùùùùùùùùùæææèèèëëëïïïòòòñññïïïíííïïïîîîïïïñññêêêÝÝÝÝÝÝçççææææææäääæææèèèíííñññóóóèèèèèèçççäääããããããèèèíííâââçççÙÙÙÃÃ÷··­­­­­­ºººÂÂÂÂÂÂÅÅÅÇÇÇÉÉÉÊÊÊÔÔÔÝÝÝãããàààßßßÝÝÝÙÙÙÕÕÕ×××ÛÛÛæææÂÂÂÅÅÅÍÍÍÎÎÎÛÛÛÙÙÙÕÕÕÃÃÃêêêëëëÝÝÝÔÔÔØØØàààÆÆÆ×××ØØØÑÑÑÉÉÉÎÎÎÛÛÛÝÝÝÕÕÕ×××ØØØØØØØØØ×××ÔÔÔÑÑÑÐÐÐÑÑÑÌÌÌÎÎη··¾¾¾ÉÉÉØØØÉÉÉÊÊÊÌÌ̼¼¼¸¸¸µµµÊÊÊÀÀÀ×××ÔÔÔ×××ÙÙÙÔÔÔÆÆÆ¿¿¿ÀÀÀÇÇÇÆÆÆÌÌÌÒÒÒÔÔÔÐÐÐÊÊÊÊÊÊÀÀÀÀÀÀ¿¿¿¿¿¿¿¿¿ÀÀÀÂÂÂÃÃÃÀÀÀÉÉÉÇÇÇ¿¿¿¸¸¸­­­ªªª¾¾¾»»»¼¼¼ººº»»»µµµººº¼¼¼µµµ¸¸¸»»»···¯¯¯¬¬¬¸¸¸ÆÆƺººÂ¿¿¿ÀÀÀ¾¾¾­­­­­­³³³»»»¿¿¿ÅÅÅÆÆÆÆÆÆÆÆÆÌÌÌÒÒÒÕÕÕäääßßßäääêêêãããææææææàààêêêïïïçççÝÝÝØØØÒÒÒÎÎÎÇÇÇÆÆƾ¾¾µµµ´´´ººº»»»¸¸¸ººº¼¼¼µµµ······¸¸¸ÇÇÇÌÌÌÐÐÐÎÎÎÍÍÍÊÊʸ¸¸µµµ»»»ÂÂÂÃÃ÷··³³³ÃÃÃÌÌÌ¿¿¿ÃÃÃÊÊÊÐÐÐÑÑÑÐÐÐÑÑÑÑÑÑÎÎÎÉÉÉÍÍÍÑÑÑÑÑÑÎÎÎÒÒÒÜÜÜäääßßßßßßäääèèèçççâââãããèèèñññèèèÍÍÍÀÀÀ······¾¾¾ØØØëëëíííïïïñññòòòòòòïïïîîîöööõõõíííîîîïïïñññùùùøøøòòòîîîëëëïïïíííâââäääõõõõõõóóóñññîîîíííííííííîîîçççèèèëëëëëëêêêçççæææäääãããçççäää×××ÆÆÆ···´´´¼¼¼ÂÂÂÂÂÂÅÅÅÉÉÉÊÊÊÊÊÊÐÐÐØØØÕÕÕÕÕÕÙÙÙÝÝÝÝÝÝØØØØØØÛÛÛêêê×××ÅÅÅÃÃÃÔÔÔßßßÔÔÔÍÍ;¾¾ãããäääßßßÙÙÙÜÜÜæææÎÎÎØØØÒÒÒÎÎÎÐÐÐÕÕÕÙÙÙÙÙÙØØØØØØÙÙÙÙÙÙØØØ×××ÔÔÔÑÑÑÐÐÐÌÌÌÆÆÆÊÊʼ¼¼µµµÇÇÇÔÔÔÙÙÙÇÇÇÇÇÇÇÇÇÀÀÀ¿¿¿¸¸¸ÑÑÑÎÎÎØØØØØØ×××ÔÔÔÍÍÍÆÆÆÂÂÂÂÂÂÆÆÆÆÆÆÊÊÊÐÐÐÎÎÎÆÆÆÂÂÂÃÃø¸¸¸¸¸¸¸¸¸¸¸»»»¿¿¿ÂÂÂÅÅÅÀÀÀÇÇÇÅÅÅ¿¿¿ÂÂÂÀÀÀ¸¸¸´´´³³³´´´µµµ»»»µµµ´´´±±±···´´´³³³´´´µµµ³³³¯¯¯°°°µµµ°°°···¯¯¯µµµ»»»´´´ººº¾¾¾­­­­­­°°°´´´ººº¿¿¿ÃÃÃÅÅÅÎÎÎØØØ×××ØØØÜÜÜÛÛÛÛÛÛÕÕÕÔÔÔÙÙÙÝÝÝÜÜÜØØØÕÕÕÔÔÔÒÒÒ¾¾¾¼¼¼ºººººº»»»¿¿¿¿¿¿¾¾¾ººº···±±±¿¿¿ÊÊÊÌÌÌÔÔÔÒÒÒÑÑÑÊÊÊÉÉÉÌÌÌÅÅŵµµ³³³»»»ÀÀÀÅÅÅÅÅźºº±±±¼¼¼ÉÉÉÃÃÃÀÀÀ¾¾¾»»»¼¼¼¾¾¾ÂÂÂÉÉÉÑÑÑÉÉÉÌÌÌÎÎÎÐÐÐÐÐÐÐÐÐÔÔÔ×××ÙÙÙÜÜÜâââççççççææææææèèèßßßäääÛÛÛÒÒÒºººµµµ´´´ÀÀÀäääèèèíííïïïïïïëëëèèèæææèèèàààÇÇÇÀÀÀÃÃÃÌÌÌâââçççñññòòòïïïñññóóóïïïïïïüüüíííëëëëëëêêêèèèêêêêêêêêêëëëëëëëëëêêêèèèæææâââÝÝÝîîîâââÙÙÙÑÑÑÀÀÀ´´´µµµ¸¸¸ÃÃÃÃÃÃÇÇÇÎÎÎÐÐÐÊÊÊÉÉÉÊÊÊÕÕÕÕÕÕÙÙÙÝÝÝÝÝÝÛÛÛÛÛÛßßßàààÝÝÝÇÇÇÃÃÃÒÒÒÒÒÒÌÌÌÇÇǼ¼¼âââèèèïïïæææÙÙÙâââÑÑÑØØØÍÍÍÌÌÌØØØÜÜÜÕÕÕÒÒÒÙÙÙÙÙÙÛÛÛÛÛÛÙÙÙØØØÔÔÔÑÑÑÐÐÐÎÎÎÊÊÊÍÍÍ»»»´´´ÉÉÉÑÑÑÐÐÐÎÎÎÃÃþ¾¾ÀÀÀÇÇÇ¿¿¿ØØØÕÕÕÛÛÛÜÜÜ×××ÉÉÉÃÃÃÆÆÆÉÉÉÇÇÇÇÇÇÆÆÆÇÇÇÉÉÉÅÅž¾¾¼¼¼ÀÀÀ¾¾¾¼¼¼¼¼¼¾¾¾ÀÀÀÆÆÆÍÍÍÐÐÐÅÅÅÍÍÍÍÍÍÊÊÊÑÑÑÒÒÒÌÌÌÇÇÇÅÅÅÇÇÇÅÅÅÐÐÐÇÇÇÌÌÌÊÊÊÕÕÕ¿¿¿µµµµµµÀÀÀÊÊʱ±±¥¥¥¯¯¯ÅÅÅÆÆÆÉÉÉÅÅÅ···»»»¾¾¾µµµ¬¬¬¥¥¥ªªª¼¼¼ÊÊÊÍÍÍÇÇÇÔÔÔÕÕÕÔÔÔÔÔÔÙÙÙââââââÙÙÙßßßØØØÔÔÔ×××ÙÙÙÕÕÕÊÊÊÀÀÀÃÃÃÂÂÂÀÀÀÀÀÀ¿¿¿ººº´´´°°°°°°ÇÇÇÐÐÐÒÒÒÐÐÐÎÎÎÒÒÒÉÉÉÒÒÒÇÇÇÆÆÆÎÎÎÉÉɸ¸¸···ÂÂÂÂÂÂÃÃÃÅÅž¾¾±±±···ÅÅÅÉÉÉÅÅÅÅÅÅÆÆÆÆÆÆ¿¿¿»»»ÅÅÅÒÒÒÉÉÉÆÆÆÅÅÅÆÆÆÉÉÉÊÊÊÊÊÊÊÊÊÊÊÊÎÎÎÔÔÔÙÙÙßßßãããâââßßßÜÜÜææææææÙÙÙ³³³³³³¸¸¸¾¾¾¼¼¼¼¼¼¼¼¼ºººººº¼¼¼ÂÂÂÆÆÆÃÃÃÉÉÉÂÂÂÊÊÊÍÍÍÇÇÇÊÊÊÂÂÂäääïïïññññññöööõõõïïïòòòÿÿÿÿÿÿúúúøøøõõõòòòñññïïïëëëçççãããâââãããææææææææææææÊÊʼ¼¼ººº³³³³³³¿¿¿ÅÅÅÆÆÆÃÃÃÃÃÃÇÇÇÊÊÊÊÊÊÍÍÍÑÑÑÒÒÒÕÕÕÜÜÜããããããÝÝÝÛÛÛÜÜÜØØØàààÛÛÛßßßßßßÕÕÕÔÔÔÌÌ̼¼¼ÀÀÀæææêêêÙÙÙääääää×××ÛÛÛÎÎÎÐÐÐØØØØØØÛÛÛÝÝÝÙÙÙÕÕÕØØØÙÙÙÛÛÛØØØÒÒÒÎÎÎÌÌÌÑÑÑÎÎο¿¿ºººÎÎÎÛÛÛÔÔÔÎÎÎÉÉÉÂÂÂÎÎÎÊÊÊÅÅÅÑÑÑ×××ÝÝÝäääÛÛÛÑÑÑÍÍÍÉÉÉÅÅÅÆÆÆÌÌÌÊÊÊÊÊÊÊÊÊÇÇÇÅÅž¾¾¼¼¼Â¿¿¿¾¾¾ÃÃÃÍÍÍÑÑÑÐÐÐÊÊÊÍÍÍÂÂÂÂÂÂÌÌÌÐÐÐÒÒÒÔÔÔÎÎÎÎÎÎÍÍÍÑÑÑ×××ØØØÔÔÔÒÒÒÔÔÔÐÐÐÐÐÐÎÎÎÌÌÌÊÊÊÉÉÉÇÇÇÆÆÆÃÃÃÅÅÅÉÉÉÌÌÌÊÊÊÃÃ÷··¯¯¯···ÀÀÀÇÇÇÀÀÀ···µµµÀÀÀÌÌÌÅÅÅÀÀÀÅÅÅÆÆÆÜÜÜÐÐÐÊÊÊÅÅÅÐÐÐÍÍÍÊÊÊÊÊÊÌÌÌÌÌÌÊÊÊÉÉÉÃÃþ¾¾ÀÀÀºººººº³³³¬¬¬ÅÅÅÍÍÍÍÍÍÐÐÐÑÑÑÒÒÒÒÒÒÒÒÒÑÑÑÇÇÇÉÉÉÎÎÎÉÉɸ¸¸³³³¼¼¼ÂÂÂÀÀÀÉÉÉÇÇÇÃÃþ¾¾°°°¯¯¯¾¾¾ÉÉÉÇÇÇÇÇÇÅÅÅ¿¿¿»»»ººº»»»ÕÕÕÐÐÐÊÊÊÇÇÇÃÃÃÂÂÂÇÇÇÎÎÎÊÊÊÐÐÐÒÒÒÒÒÒÙÙÙãããäääàààâââÒÒÒàààÔÔÔ···µµµººº¼¼¼¾¾¾ÂÂÂÆÆÆÅÅÅÂÂÂÀÀÀÃÃÃÆÆÆÆÆÆÉÉÉÎÎÎÎÎÎÌÌÌÇÇÇÆÆÆÆÆÆÇÇÇÜÜÜíííïïïëëëíííñññóóóöööõõõòòòòòòóóóöööúúúÿÿÿöööïïïèèèçççëëëëëëäääßßß´´´¸¸¸¾¾¾ÀÀÀÀÀÀ¿¿¿¾¾¾¿¿¿ÅÅÅÅÅÅÇÇÇÌÌÌÐÐÐÑÑÑÑÑÑÐÐÐÑÑÑÕÕÕÛÛÛàààâââàààÝÝÝÛÛÛÛÛÛØØØÛÛÛààààààØØØÑÑÑÐÐÐÃÃÃÒÒÒïïïëëëßßßäääßßß×××ÜÜÜÒÒÒÔÔÔÜÜÜÛÛÛÛÛÛÛÛÛÕÕÕÛÛÛÙÙÙÙÙÙ×××ÔÔÔÒÒÒÑÑÑÐÐÐÍÍÍÉÉɼ¼¼¾¾¾ÐÐÐÙÙÙÔÔÔÐÐÐÒÒÒÆÆÆÍÍÍÇÇÇÅÅÅÒÒÒ×××ÜÜÜÙÙÙÒÒÒÎÎÎÎÎÎÍÍÍÉÉÉÇÇÇÊÊÊÌÌÌÊÊÊÉÉÉÇÇÇÅÅÅÃÃÃÀÀÀ¿¿¿ÅÅÅÂÂÂÃÃÃÇÇÇÐÐÐÔÔÔÒÒÒÐÐÐÒÒÒÉÉÉÇÇÇÍÍÍÌÌÌÎÎÎÔÔÔÔÔÔÒÒÒÌÌÌÅÅÅÅÅÅÅÅÅÇÇÇÐÐÐØØØ××××××ÕÕÕÒÒÒÑÑÑÐÐÐÎÎÎÍÍÍÅÅÅÇÇÇÌÌÌÑÑÑÔÔÔÐÐÐÉÉÉÃÃû»»¼¼¼¿¿¿ÃÃþ¾¾µµµµµµ¼¼¼ÎÎÎÌÌÌÍÍÍÉÉÉÕÕÕÌÌÌÐÐÐÔÔÔÎÎÎÎÎÎÍÍÍÍÍÍÌÌÌÊÊÊÆÆÆÃÃû»»´´´»»»¿¿¿ÉÉÉÌÌÌÉÉÉÙÙÙÐÐÐÒÒÒÕÕÕØØØØØØ×××ÕÕÕÒÒÒÕÕÕÎÎÎÌÌÌÃÃ÷··¸¸¸¿¿¿¼¼¼ÃÃÃÆÆÆÆÆÆÆÆÆÅÅż¼¼···¸¸¸ÂÂÂÆÆÆÅÅÅÀÀÀ¿¿¿ÂÂÂÀÀÀ»»»¿¿¿¿¿¿ÃÃÃÉÉÉÉÉÉÆÆÆÇÇÇÍÍÍÒÒÒÑÑÑÐÐÐÍÍÍÍÍÍÑÑÑÒÒÒÒÒÒÜÜÜØØØäääàààÆÆƸ¸¸ººº¾¾¾ÀÀÀÅÅÅÉÉÉÌÌÌÌÌÌÉÉÉÃÃÃÀÀÀÇÇÇÌÌÌÎÎÎÐÐÐÍÍÍÊÊÊÇÇÇÇÇÇÂÂÂÔÔÔãããççççççêêêïïïòòòóóóñññîîîîîîîîîñññòòòòòòëëëÜÜÜÇÇǺºº···ººº¾¾¾¿¿¿ÀÀÀÃÃÃÇÇÇÇÇÇÆÆÆÃÃÃÃÃÃÃÃÿ¿¿ÂÂÂÆÆÆÊÊÊÎÎÎÐÐÐÎÎÎÎÎÎÒÒÒ×××ÛÛÛßßßàààßßßÜÜÜÙÙÙÛÛÛØØØÙÙÙÝÝÝÝÝÝÕÕÕÎÎÎÍÍÍÃÃÃàààòòòçççãããâââ×××ÙÙÙÙÙÙÔÔÔÕÕÕÛÛÛÙÙÙ×××ÔÔÔÎÎÎØØØØØØØØØ×××ÕÕÕÒÒÒÑÑÑÎÎÎÉÉɼ¼¼ÅÅÅÔÔÔØØØÒÒÒÑÑÑÕÕÕÉÉÉÉÉÉÆÆÆÇÇÇÒÒÒØØØÝÝÝÐÐÐÍÍÍÌÌÌÎÎÎÐÐÐÍÍÍÌÌÌÌÌÌÌÌÌÊÊÊÉÉÉÇÇÇÆÆÆÅÅÅÃÃÃÃÃÃÅÅÅÅÅÅÆÆÆÊÊÊÎÎÎÒÒÒÑÑÑÐÐÐÐÐÐÊÊÊÐÐÐÔÔÔÎÎÎÍÍÍÕÕÕØØØÊÊÊÃÃÿ¿¿ÀÀÀÀÀÀÀÀÀÅÅÅÊÊÊÇÇÇÇÇÇÆÆÆÃÃÿ¿¿¾¾¾¾¾¾»»»¾¾¾ÃÃÃÉÉÉÎÎÎÑÑÑÑÑÑÐÐл»»¼¼¼ÊÊÊÐÐÐÊÊÊÉÉÉÐÐЯ¯¯´´´ººº¸¸¸Â¾¾¾ÉÉÉ××××××ÒÒÒÌÌÌÅÅÅ¿¿¿¾¾¾¿¿¿ÂÂÂÉÉɼ¼¼ÃÃÃÌÌÌÑÑÑÕÕÕÑÑÑÒÒÒÑÑÑÒÒÒ×××ÙÙÙÙÙÙ×××ÔÔÔÑÑÑÒÒÒÍÍÍÇÇÇ»»»³³³»»»ÃÃÿ¿¿Â¿¿¿¿¿¿ÃÃÃÆÆÆÇÇÇÀÀÀ´´´»»»ÅÅÅÇÇÇÀÀÀ¾¾¾ÃÃÃÃÃü¼¼ººº¼¼¼ÂÂÂÊÊÊÌÌÌÇÇÇÇÇÇÌÌÌÉÉÉÇÇÇÉÉÉÊÊÊÌÌÌÊÊÊÌÌÌÎÎÎÕÕÕÜÜÜâââäääÎÎγ³³³³³»»»ÀÀÀÃÃÃÉÉÉÎÎÎÒÒÒÑÑÑÌÌÌÆÆÆÊÊÊÍÍÍÑÑÑÑÑÑÐÐÐÍÍÍÊÊÊÉÉÉ¿¿¿ÇÇÇÍÍÍÊÊÊÅÅÅÂÂÂÂÂÂÂÂÂÛÛÛØØØÒÒÒÐÐÐÎÎÎÌÌÌÇÇÇÃÃÃÌÌÌÉÉÉÆÆÆÅÅÅÆÆÆÆÆÆÅÅÅÃÃÃÍÍÍÎÎÎÎÎÎÍÍÍÊÊÊÇÇÇÆÆÆÆÆÆ¿¿¿ÂÂÂÇÇÇÌÌÌÎÎÎÐÐÐÐÐÐÐÐÐÕÕÕØØØÜÜÜßßßßßßÝÝÝÙÙÙ×××ÙÙÙ×××ØØØÛÛÛÙÙÙÒÒÒÌÌÌÉÉÉ»»»ãããëëëÜÜÜâââÜÜÜÐÐÐÛÛÛÕÕÕÑÑÑÑÑÑÔÔÔÒÒÒÑÑÑÎÎÎÊÊÊÎÎÎÑÑÑÔÔÔØØØØØØÔÔÔÎÎÎÉÉÉÇÇÇ¿¿¿ÀÀÀÎÎÎÙÙÙÕÕÕÐÐÐÒÒÒÐÐÐÇÇÇÆÆÆÆÆÆÇÇÇÎÎÎ×××ßßßÑÑÑÎÎÎÍÍÍÍÍÍÎÎÎÎÎÎÍÍÍÍÍÍÍÍÍÌÌÌÉÉÉÇÇÇÆÆÆÆÆÆÆÆÆÇÇÇÅÅÅÆÆÆÇÇÇÉÉÉÊÊÊÊÊÊÊÊÊÊÊÊÅÅÅÇÇÇÔÔÔÛÛÛÑÑÑÍÍÍÒÒÒÕÕÕÆÆÆÂÂÂÀÀÀÃÃÃÃÃÿ¿¿¼¼¼¾¾¾¿¿¿¿¿¿¾¾¾»»»ººº¸¸¸···µµµ±±±´´´···¼¼¼ÃÃÃÉÉÉÍÍÍÐÐÐÐÐÐÆÆÆÀÀÀÂÂÂÅÅÅÃÃÃÃÃÃÆÆÆÆÆÆÌÌÌÎÎÎÌÌÌÉÉɼ¼¼¸¸¸ÂÂÂÃÃÃÂÂÂÀÀÀ¾¾¾¾¾¾ÂÂÂÉÉÉÐÐÐÅÅż¼¼ÆÆÆÑÑÑÒÒÒØØØÙÙÙÒÒÒ××××××ØØØÙÙÙÙÙÙØØØ×××ÕÕÕÊÊÊÍÍÍÌÌ̼¼¼­­­´´´¾¾¾ºººÀÀÀººººººººº¸¸¸¾¾¾»»»©©©µµµÀÀÀÉÉÉÅÅÅ¿¿¿¿¿¿ÀÀÀ¿¿¿ººº¸¸¸¸¸¸ººº···´´´µµµººº¼¼¼¾¾¾ÆÆÆÐÐÐÒÒÒÎÎÎÌÌÌÎÎÎÎÎÎÛÛÛÛÛÛâââÒÒÒ±±±³³³ÀÀÀÃÃÃÆÆÆÉÉÉÍÍÍÎÎÎÐÐÐÎÎÎÎÎÎÌÌÌÎÎÎÑÑÑÔÔÔÒÒÒÐÐÐÍÍÍÌÌÌÍÍÍÎÎÎÐÐÐÍÍÍÉÉÉÆÆÆÆÆÆÅÅÅÎÎÎÍÍÍÍÍÍÐÐÐÒÒÒÔÔÔÑÑÑÍÍÍÌÌÌÍÍÍÑÑÑÔÔÔÔÔÔÒÒÒÑÑÑÐÐÐÑÑÑÑÑÑÐÐÐÎÎÎÌÌÌÉÉÉÇÇÇÇÇÇÆÆÆÉÉÉÌÌÌÎÎÎÐÐÐÑÑÑÒÒÒÔÔÔØØØÙÙÙÜÜÜßßßÝÝÝÜÜÜØØØÕÕÕ×××ÕÕÕ×××××××××ÑÑÑÌÌÌÇÇÇ¿¿¿äääãããØØØààà×××ÍÍÍÛÛÛÔÔÔÔÔÔÑÑÑÐÐÐÑÑÑÒÒÒÐÐÐÎÎÎÊÊÊÌÌÌÎÎÎÒÒÒÔÔÔÒÒÒÍÍÍÇÇÇÇÇÇÀÀÀÆÆÆ×××ÜÜÜÕÕÕÐÐÐÑÑÑÉÉÉÉÉÉÇÇÇÉÉÉÇÇÇÅÅÅÍÍÍ×××ÕÕÕÕÕÕÒÒÒÎÎÎÌÌÌÍÍÍÎÎÎÎÎÎÍÍÍÌÌÌÊÊÊÇÇÇÇÇÇÇÇÇÇÇÇÉÉÉÇÇÇÉÉÉÊÊÊÉÉÉÇÇÇÆÆÆÅÅÅÅÅÅÃÃÃÇÇÇÔÔÔÙÙÙÍÍÍÆÆÆÌÌÌÐÐÐÒÒÒÉÉÉ¿¿¿¿¿¿¾¾¾¾¾¾ÀÀÀ¾¾¾¾¾¾¼¼¼»»»ººº¸¸¸······µµµ···¸¸¸»»»¿¿¿ÅÅÅÊÊÊÎÎÎÒÒÒÔÔÔÍÍÍ»»»¾¾¾¿¿¿¼¼¼¼¼¼ÀÀÀÀÀÀÆÆÆÉÉÉÀÀÀ¸¸¸¼¼¼···¾¾¾ÅÅÅÊÊÊÊÊÊÉÉÉÇÇÇÇÇǺºº¾¾¾ÌÌÌÕÕÕÒÒÒØØØàààÙÙÙÜÜÜÛÛÛØØØ××××××ØØØÙÙÙÛÛÛÒÒÒ××××××ÆÆƵµµµµµµµµªªª···´´´······µµµÂÂÂÉÉÉÀÀÀµµµµµµ¼¼¼ÅÅÅÆÆÆ¿¿¿ÂÂÂÇÇÇÃÃÃÀÀÀÀÀÀ¼¼¼¸¸¸»»»ÀÀÀ¿¿¿¿¿¿ÆÆÆÐÐÐÑÑÑÌÌÌÇÇÇÉÉÉÉÉÉ×××ÕÕÕàààÙÙÙ¸¸¸µµµÂÂÂÂÂÂÆÆÆÌÌÌÍÍÍÊÊÊÉÉÉÊÊÊÎÎÎÌÌÌÎÎÎÑÑÑÔÔÔÔÔÔÒÒÒÐÐÐÎÎÎÊÊÊÉÉÉÉÉÉÉÉÉÉÉÉÇÇÇÉÉÉÊÊÊÆÆÆÇÇÇÌÌÌÑÑÑÕÕÕØØØ×××ÔÔÔ××××××ÕÕÕÒÒÒÑÑÑÒÒÒÔÔÔ×××ÒÒÒÒÒÒÑÑÑÑÑÑÐÐÐÎÎÎÍÍÍÌÌÌÍÍÍÍÍÍÍÍÍÎÎÎÐÐÐÒÒÒÔÔÔÕÕÕÙÙÙÛÛÛÝÝÝßßßÝÝÝÛÛÛØØØÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÔÔÔÑÑÑÍÍÍÇÇÇÔÔÔèèèàààÜÜÜàààÒÒÒÍÍÍØØØ×××ÛÛÛ×××ÔÔÔ×××ØØØ××××××ÎÎÎÌÌÌÉÉÉÉÉÉÌÌÌÍÍÍÌÌÌÉÉÉÅÅÅ¿¿¿ÊÊÊÛÛÛÜÜÜÔÔÔÑÑÑÐÐÐÉÉÉÌÌÌÆÆÆÊÊÊÉÉɾ¾¾ÂÂÂÌÌÌÔÔÔØØØ×××ÑÑÑÌÌÌÌÌÌÎÎÎÎÎÎÌÌÌÌÌÌÊÊÊÉÉÉÉÉÉÇÇÇÇÇÇÇÇÇÌÌÌÌÌÌÌÌÌÊÊÊÉÉÉÆÆÆÅÅÅÃÃÃÉÉÉÉÉÉÑÑÑÑÑÑÅÅÅ¿¿¿ÇÇÇÍÍÍÕÕÕÊÊÊÀÀÀ¿¿¿¿¿¿¾¾¾¿¿¿Â¸¸¸¸¸¸······µµµµµµµµµµµµ¸¸¸¸¸¸ººº»»»¼¼¼¿¿¿ÅÅÅÇÇÇÇÇÇ×××ÜÜÜÒÒÒÎÎÎÒÒÒÕÕÕÒÒÒÊÊÊÉÉɾ¾¾ÆÆÆÌÌÌÎÎÎÆÆÆÌÌÌÉÉÉÌÌÌÎÎÎÎÎÎÌÌÌÅÅÅ¿¿¿»»»»»»ÊÊÊÔÔÔØØØÔÔÔÔÔÔÜÜÜ×××ØØØÔÔÔÎÎÎÊÊÊÊÊÊÎÎÎÔÔÔØØØÛÛÛØØØ×××ÐÐÐÉÉÉÇÇÇ¿¿¿­­­¥¥¥¦¦¦©©©ªªªªªª´´´¿¿¿Âººº­­­¬¬¬¼¼¼ÉÉÉÇÇÇÃÃÃÃÃþ¾¾¼¼¼¾¾¾¿¿¿¾¾¾ººº»»»¿¿¿ÅÅÅÂÂÂÀÀÀÅÅÅÇÇÇÉÉÉÇÇÇÉÉÉÇÇÇÑÑÑÔÔÔÝÝÝØØغººªªª¯¯¯´´´¼¼¼ÆÆÆÊÊÊÌÌÌÌÌÌÍÍÍÎÎÎÊÊÊÌÌÌÎÎÎÒÒÒÕÕÕÕÕÕÒÒÒÐÐÐÔÔÔÐÐÐÍÍÍÌÌÌÉÉÉÆÆÆÅÅÅÇÇÇÑÑÑÔÔÔØØØÛÛÛÜÜÜÛÛÛÙÙÙØØØ×××ØØØÛÛÛÜÜÜÝÝÝÝÝÝÝÝÝÝÝÝÕÕÕÕÕÕÕÕÕ×××ØØØØØØÕÕÕÔÔÔÐÐÐÎÎÎÎÎÎÐÐÐÔÔÔÕÕÕ×××ÕÕÕÛÛÛÜÜÜÝÝÝßßßÝÝÝÛÛÛØØØ×××ÕÕÕÕÕÕÕÕÕÒÒÒÑÑÑÐÐÐÊÊÊÅÅÅäääçççÜÜÜßßßÝÝÝÎÎÎÐÐÐÔÔÔØØØßßßÜÜÜ×××ÛÛÛÜÜÜØØØØØØÕÕÕÐÐÐÉÉÉÇÇÇÉÉÉÊÊÊÉÉÉÆÆƾ¾¾¼¼¼ÌÌÌÛÛÛØØØÔÔÔÒÒÒÎÎÎÌÌÌÌÌÌ¿¿¿ÇÇÇÍÍÍÀÀÀÂÂÂÆÆÆÉÉÉÔÔÔÛÛÛ×××ÎÎÎÍÍÍÍÍÍÍÍÍÌÌÌÌÌÌÌÌÌÊÊÊÉÉÉÇÇÇÆÆÆÅÅÅÉÉÉÉÉÉÇÇÇÇÇÇÆÆÆÅÅÅÃÃÃÂÂÂÇÇÇÅÅÅÊÊÊÍÍÍÃÃÃÀÀÀÇÇÇÌÌÌÉÉɾ¾¾ÀÀÀ¿¿¿¼¼¼¼¼¼¸¸¸¸¸¸¸¸¸ºººººººººººººººµµµ¸¸¸ººººººººº»»»¿¿¿ÂÂÂÂÂÂÑÑÑÜÜÜÛÛÛ×××××××××ÕÕÕÔÔÔÎÎλ»»ÀÀÀÃÃÃÌÌÌÅÅÅÎÎÎÊÊÊÇÇÇÅÅÅÂÂÂÂÂÂÂÂÂÂÂÂÀÀÀ´´´ÌÌÌÐÐÐÔÔÔÕÕÕÕÕÕÜÜÜ×××ÒÒÒÍÍÍÇÇÇÃÃÃÃÃÃÉÉÉÐÐÐÕÕÕÙÙÙÒÒÒÒÒÒÔÔÔÒÒÒÒÒÒÍÍÍÀÀÀÇÇÇÉÉÉÆÆÆ¿¿¿¸¸¸···¼¼¼¼¼¼³³³­­­´´´¾¾¾ÀÀÀÃÃÃÅÅÅÅÅÅÃÃÃÅÅÅÇÇÇÅÅÅÀÀÀÂÂÂÆÆÆÅÅÅ¿¿¿¿¿¿ÅÅÅÌÌÌÍÍÍÉÉÉÉÉÉÊÊÊÔÔÔÙÙÙØØØÇÇÇ´´´±±±µµµ¸¸¸¼¼¼ÃÃÃÊÊÊÎÎÎÎÎÎÌÌÌÆÆÆÇÇÇÌÌÌÑÑÑÕÕÕ×××ÔÔÔÑÑÑÌÌÌÇÇÇÆÆÆÉÉÉÇÇÇÅÅÅÅÅÅÉÉÉÇÇÇÍÍÍÔÔÔØØØÙÙÙÛÛÛÝÝÝàààÝÝÝÜÜÜÙÙÙØØØØØØÙÙÙÛÛÛÛÛÛØØØ×××ØØØÛÛÛÜÜÜÜÜÜÙÙÙ×××ÔÔÔÑÑÑÒÒÒ×××ßßßâââßßßÛÛÛÜÜÜÝÝÝßßßßßßßßßÜÜÜÙÙÙØØØÕÕÕ×××ÕÕÕÐÐÐÍÍÍÌÌÌÆÆƾ¾¾ëëëàààÔÔÔßßßÛÛÛÌÌÌÒÒÒÑÑÑÕÕÕàààÝÝÝØØØÜÜÜÛÛÛÔÔÔÔÔÔ×××ÑÑÑÍÍÍÍÍÍÍÍÍÊÊÊÅÅÅ¿¿¿···ºººÊÊÊØØØÕÕÕÒÒÒÔÔÔÎÎÎÌÌÌÇÇǵµµÃÃÃÑÑÑÇÇÇÇÇÇÉÉɼ¼¼ÍÍÍÛÛÛÛÛÛÒÒÒÎÎÎÍÍÍÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÉÉÉÇÇÇÅÅÅÃÃÃÃÃÃÂÂÂÂÂÂÂÂÂÃÃÃÂÂÂÀÀÀ¾¾¾¾¾¾¼¼¼ÆÆÆÎÎÎÉÉÉÆÆÆÌÌÌÍÍÍ»»»···»»»¾¾¾¾¾¾»»»»»»µµµµµµ······¸¸¸¸¸¸ºººººº¸¸¸»»»¾¾¾¾¾¾¾¾¾¿¿¿ÂÂÂÅÅÅÂÂÂÊÊÊÔÔÔÛÛÛÙÙÙ××××××ÙÙÙÕÕÕÎÎθ¸¸»»»ºººÀÀÀ»»»ÅÅÅÃÃÃÀÀÀ¾¾¾¾¾¾¾¾¾¼¼¼¸¸¸µµµµµµÐÐÐÌÌÌÍÍÍÔÔÔÒÒÒÕÕÕÎÎÎØØØÒÒÒÍÍÍÉÉÉÊÊÊÐÐÐØØØÜÜÜØØØÒÒÒÕÕÕ×××ÐÐÐÍÍÍÎÎÎÊÊÊÇÇÇÊÊÊÆÆÆÆÆÆÆÆƸ¸¸­­­´´´¾¾¾¾¾¾ººº±±±¯¯¯´´´¿¿¿ÇÇÇÊÊÊÆÆÆ¿¿¿»»»µµµ···¼¼¼ÉÉÉÇÇÇÅÅÅÃÃÃÉÉÉÑÑÑÍÍÍÃÃÃÉÉÉÃÃÃÒÒÒÛÛÛâââäää×××ÔÔÔÊÊÊ»»»¼¼¼ÅÅÅÊÊÊÇÇÇÀÀÀÅÅÅÆÆÆÊÊÊÐÐÐÕÕÕØØØÕÕÕÒÒÒÐÐÐÌÌÌÊÊÊÍÍÍÌÌÌÇÇÇÉÉÉÎÎÎÌÌÌÒÒÒÙÙÙÛÛÛÙÙÙØØØÛÛÛßßß×××××××××ÙÙÙÛÛÛÜÜÜÛÛÛØØØ××××××ØØØÛÛÛÜÜÜÜÜÜØØØÔÔÔ×××ÕÕÕØØØàààëëëîîîèèèâââÝÝÝÝÝÝßßßàààßßßÝÝÝÛÛÛÙÙÙ×××ØØØÕÕÕÍÍÍÉÉÉÇÇÇÀÀÀ¸¸¸îîîïïïÙÙÙâââââââââÕÕÕÐÐÐÕÕÕÕÕÕ×××ÙÙÙÛÛÛÙÙÙ×××ÔÔÔÔÔÔÐÐÐÎÎÎÐÐÐÎÎÎÇÇÇÃÃÃÅÅŵµµÌÌÌÙÙÙÕÕÕÔÔÔÙÙÙÔÔÔÉÉÉÎÎÎÇÇǾ¾¾´´´±±±µµµÀÀÀÇÇÇÇÇÇÆÆÆÌÌÌÜÜÜãããÎÎÎÅÅÅÒÒÒÊÊÊÊÊÊÆÆÆÀÀÀÃÃÃÉÉÉÆÆÆ¿¿¿ÃÃÃÂÂÂÀÀÀ¿¿¿¾¾¾¾¾¾¾¾¾¾¾¾ÂÂÂÀÀÀ¾¾¾¼¼¼ÅÅÅÌÌÌÇÇÇ¿¿¿¸¸¸¸¸¸ººº»»»»»»»»»ºººººº¸¸¸···µµµµµµµµµ···¸¸¸ºººººº¾¾¾»»»ºººÀÀÀÀÀÀÃÃÃÑÑÑ×××ÙÙÙÛÛÛ×××ØØØÛÛÛÙÙÙÕÕÕØØØÉÉÉ»»»ººº¾¾¾¾¾¾¿¿¿ÀÀÀ¿¿¿¼¼¼»»»¼¼¼¿¿¿¾¾¾»»»¸¸¸´´´ÅÅÅÐÐÐÎÎÎÊÊÊÍÍÍÎÎÎÎÎÎÐÐÐÑÑÑÌÌÌÅÅÅÊÊÊ×××ÙÙÙÕÕÕ××××××ÕÕÕÔÔÔÑÑÑÐÐÐÎÎÎÎÎÎÊÊÊÌÌÌÆÆÆÇÇÇÉÉɺºº©©©¬¬¬±±±»»»ÀÀÀ»»»¯¯¯ªªª³³³¾¾¾ÅÅž¾¾¸¸¸µµµ±±±¯¯¯´´´¾¾¾ÍÍ;¾¾ÉÉÉÒÒÒÒÒÒÎÎÎÍÍÍÆÆÆÇÇÇÊÊÊÐÐÐ×××ÜÜÜßßßßßßâââØØØÀÀÀ´´´¼¼¼¿¿¿¼¼¼ÀÀÀ¿¿¿ÂÂÂÆÆÆÉÉÉÎÎÎÔÔÔÑÑÑÌÌÌÉÉÉÆÆÆÊÊÊÊÊÊÊÊÊÌÌÌÉÉÉÇÇÇÌÌÌÎÎÎÒÒÒÔÔÔÕÕÕ×××ÙÙÙÛÛÛÙÙÙ××××××ØØØÜÜÜÝÝÝÝÝÝÜÜÜÙÙÙÛÛÛÜÜÜÝÝÝßßßÝÝÝÜÜÜÛÛÛÝÝÝÙÙÙÙÙÙãããîîîñññçççÜÜÜßßßÛÛÛØØØÙÙÙÝÝÝßßßÛÛÛ×××ÑÑÑ×××ÅÅż¼¼ÆÆÆäääâââäääèèèíííÙÙÙâââàààâââØØØÔÔÔÛÛÛÙÙÙØØØØØØØØØ×××ÔÔÔÑÑÑÎÎÎÍÍÍÌÌÌÍÍÍÉÉÉÃÃÿ¿¿¾¾¾¿¿¿ÐÐÐÙÙÙÕÕÕÔÔÔ×××ÑÑÑÆÆÆÊÊÊÇÇÇÀÀÀºººµµµ···¼¼¼ÀÀÀÇÇÇÃÃÃÀÀÀÌÌÌÛÛÛ×××ÊÊÊÉÉÉÇÇÇÊÊÊÉÉÉÅÅÅÃÃÃÃÃÃÃÃÃÂÂÂÀÀÀÀÀÀ¿¿¿¼¼¼»»»»»»»»»»»»»»»»»»¸¸¸···¼¼¼Â¿¿¿¸¸¸µµµ···¸¸¸ººº»»»»»»ºººººº···············¸¸¸ººº»»»···µµµºººÆÆÆÍÍÍÇÇÇÉÉÉÔÔÔÍÍÍÎÎÎÐÐÐÒÒÒÙÙÙßßßØØØÍÍÍÃÃúºº´´´···¾¾¾¿¿¿ÀÀÀÃÃþ¾¾¾¾¾¿¿¿¿¿¿¿¿¿¾¾¾¼¼¼»»»°°°¸¸¸ÀÀÀÅÅÅÊÊÊÍÍÍÍÍÍÌÌÌ×××ÜÜÜÕÕÕÉÉÉÌÌÌÙÙÙÛÛÛÐÐÐÍÍÍÍÍÍÎÎÎÎÎÎÎÎÎÎÎÎÐÐÐÐÐÐÆÆÆÅÅŵµµ©©©¥¥¥³³³ºººÀÀÀÀÀÀ»»»······ººº±±±±±±±±±±±±­­­¬¬¬¯¯¯´´´ÉÉÉÆÆÆÀÀÀ¿¿¿ÃÃÃÊÊÊÉÉÉÅÅÅÊÊÊÊÊÊÉÉÉÉÉÉÊÊÊÎÎÎÒÒÒÕÕÕÝÝÝããããããÝÝÝ×××ÉÉɺºº´´´³³³µµµ¸¸¸¸¸¸¾¾¾ÆÆÆÌÌÌÌÌÌÌÌÌÊÊÊÊÊÊÉÉÉÇÇÇÉÉÉÉÉÉÉÉÉÊÊÊÍÍÍÑÑÑÒÒÒÔÔÔÔÔÔ×××ØØØØØØ××××××ØØØÛÛÛÝÝÝÝÝÝÜÜÜÜÜÜÛÛÛÛÛÛÛÛÛÛÛÛÛÛÛÜÜÜÜÜÜÙÙÙÙÙÙÙÙÙßßßãããäääàààÜÜÜÜÜÜÙÙÙÙÙÙÛÛÛßßßßßßÛÛÛ×××ÐÐÐÒÒÒÉÉÉÒÒÒÛÛÛëëëãããçççÜÜÜãããÔÔÔßßßâââçççãããäääçççâââÙÙÙÔÔÔÒÒÒÔÔÔÔÔÔÕÕÕÐÐÐÎÎÎÌÌÌÇÇÇÅÅÅÃÃÃÃÃÃÃÃÃÌÌÌÒÒÒØØØ×××ÔÔÔÒÒÒÍÍÍÃÃÃÇÇÇÇÇÇÆÆƼ¼¼¸¸¸······ÆÆÆÇÇÇÀÀÀÀÀÀÐÐÐÛÛÛÔÔÔÊÊÊÇÇÇÉÉÉÊÊÊÉÉɾ¾¾¿¿¿ÅÅÅÀÀÀ¿¿¿¼¼¼»»»¸¸¸¸¸¸······¸¸¸¸¸¸···µµµ···ººº¸¸¸´´´³³³´´´µµµ¸¸¸ºººººººººººº······¸¸¸¸¸¸¸¸¸ººº»»»»»»¿¿¿µµµ¼¼¼ÊÊÊÅÅŵµµ°°°µµµººº¿¿¿ÇÇÇÎÎÎÔÔÔÒÒÒÇÇÇ»»»¾¾¾»»»»»»¿¿¿ÂÂÂÂÂÂÀÀÀ¿¿¿ÃÃÃÆÆÆÅÅÅÂÂÂÀÀÀ¾¾¾¾¾¾´´´¯¯¯¯¯¯¸¸¸ÅÅÅÉÉÉÊÊÊÊÊÊÑÑÑØØØÕÕÕÇÇÇÌÌÌÝÝÝàààÒÒÒÑÑÑÑÑÑÐÐÐÐÐÐÎÎÎÎÎÎÍÍÍÍÍÍÌÌÌÉÉÉÉÉÉÇÇÇÃÃÿ¿¿µµµ¨¨¨¬¬¬°°°···¾¾¾Â¿¿¿¼¼¼ÀÀÀÂÂÂÃÃÃÂÂÂÂÂÂÀÀÀ»»»µµµ¿¿¿ÇÇÇÇÇǼ¼¼¾¾¾ÌÌÌÑÑÑÌÌÌÆÆÆÆÆÆÃÃÃÂÂÂÂÂÂÇÇÇÒÒÒÛÛÛâââãããëëëîîîçççäääãããßßßââââââÙÙÙÉÉɾ¾¾¾¾¾¿¿¿ÀÀÀÂÂÂÆÆÆÅÅÅÆÆÆÇÇÇÆÆÆÆÆÆÇÇÇÊÊÊÍÍÍÐÐÐÑÑÑÑÑÑÑÑÑÒÒÒÕÕÕ×××ÕÕÕÕÕÕØØØÛÛÛÜÜÜÜÜÜÜÜÜßßßÜÜÜÙÙÙ××××××ØØØÛÛÛÜÜÜÙÙÙÛÛÛÜÜÜÛÛÛÙÙÙÙÙÙÜÜÜßßßØØØØØØÙÙÙÜÜÜàààßßßÙÙÙÕÕÕÐÐÐÌÌÌÇÇÇãããëëëíííãããëëëæææíííÙÙÙßßßÜÜÜàààßßßãããçççäääßßßÜÜÜÙÙÙØØØÔÔÔÑÑÑÒÒÒÑÑÑÊÊÊÅÅÅÅÅÅÌÌÌÑÑÑÒÒÒÕÕÕÔÔÔ××××××ÒÒÒÒÒÒÎÎÎÅÅÅÇÇÇÊÊÊÊÊÊÇÇÇÀÀÀººº³³³°°°ÆÆÆÎÎÎÍÍÍÅÅÅÉÉÉÔÔÔÙÙÙØØØÎÎÎÊÊÊÇÇÇÇÇǼ¼¼¿¿¿ÆÆÆÀÀÀ¿¿¿¾¾¾»»»¸¸¸······µµµººººººººº······µµµµµµ´´´°°°±±±³³³µµµ···¸¸¸ººº»»»¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¿¿¿ºººÅÅÅÎÎÎÀÀÀ´´´µµµ···ººº¾¾¾¾¾¾ºººµµµµµµ¸¸¸¼¼¼ÀÀÀÂÂÂÅÅÅÆÆÆÅÅÅÂÂÂÀÀÀÀÀÀÂÂÂÅÅÅÅÅÅÃÃÃÃÃÃÃÃÿ¿¿ººº»»»­­­¨¨¨³³³¿¿¿ÂÂÂÆÆÆÌÌÌÌÌÌÌÌÌÉÉÉÃÃÃÇÇÇØØØßßßÕÕÕÔÔÔÒÒÒÑÑÑÐÐÐÐÐÐÎÎÎÍÍÍÌÌÌÊÊÊÆÆÆÇÇÇÆÆÆ¿¿¿ÀÀÀ»»»©©©¬¬¬­­­°°°´´´¸¸¸»»»¼¼¼¼¼¼Â¿¿¿¿¿¿ÅÅÅÉÉÉÀÀÀ´´´µµµÃÃÃÉÉÉÀÀÀ¿¿¿ÉÉÉÐÐÐÍÍÍÎÎÎÎÎÎÌÌÌÅÅÅ¿¿¿ÂÂÂÊÊÊÔÔÔßßß×××ÛÛÛàààßßßçççíííçççèèèêêêâââÐÐÐÀÀÀ»»»¼¼¼¿¿¿µµµ¿¿¿¼¼¼ÂÂÂÉÉÉÅÅÅÅÅÅÃÃÃÊÊÊÍÍÍÐÐÐÐÐÐÐÐÐÐÐÐÑÑÑÒÒÒÔÔÔÔÔÔÕÕÕ×××ÙÙÙÛÛÛÜÜÜÜÜÜßßßÜÜÜØØØÕÕÕÔÔÔÕÕÕ×××ÙÙÙÙÙÙÛÛÛÛÛÛÙÙÙØØØÙÙÙÜÜÜàààÕÕÕ×××ÙÙÙÝÝÝàààßßßÙÙÙÔÔÔÎÎÎÇÇÇÂÂÂãããëëëëëëçççïïïëëëñññÛÛÛßßßÛÛÛßßßßßßæææÝÝÝâââæææêêêèèèàààÔÔÔÌÌÌÎÎÎÌÌÌÇÇÇÉÉÉÍÍÍÕÕÕÙÙÙÛÛÛ×××ÒÒÒÕÕÕ×××ÑÑÑÔÔÔÔÔÔÉÉÉÉÉÉÌÌÌÍÍÍÉÉɺºº³³³¯¯¯ÆÆÆÌÌÌÑÑÑÍÍÍÇÇÇÌÌÌÕÕÕÛÛÛØØØÍÍÍÅÅÅÃÃÃÃÃÃÀÀÀÀÀÀÆÆÆÃÃÿ¿¿¼¼¼»»»ººº¸¸¸¸¸¸»»»ºººººº¸¸¸µµµ³³³³³³´´´°°°°°°±±±³³³µµµ¸¸¸ººº»»»ºººººº¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸»»»ÀÀÀÌÌÌÊÊʺºº¸¸¸ÂÂÂÃÃÃÃÃÃÆÆÆÉÉÉÇÇǼ¼¼¼¼¼¿¿¿ÀÀÀÅÅÅÉÉÉÇÇÇÃÃÃÃÃÃÃÃÃÅÅźººººº¸¸¸¸¸¸¿¿¿ÅÅÅÀÀÀµµµµµµªªªªªª¸¸¸ÂÂÂÂÂÂÅÅÅÍÍÍÒÒÒÅÅÅÂÂÂÅÅÅÅÅÅÍÍÍØØØ×××ÎÎÎÍÍÍÌÌÌÍÍÍÐÐÐÑÑÑÐÐÐÎÎÎÌÌÌÇÇÇÉÉÉÇÇÇÀÀÀÅÅÅÃÃô´´¾¾¾¼¼¼¸¸¸±±±­­­¯¯¯´´´ºººªªª°°°´´´´´´ºººÃÃÃÅÅÅÀÀÀ³³³»»»ÂÂÂÃÃÃÀÀÀ¾¾¾¿¿¿ÀÀÀÍÍÍÐÐÐÐÐÐÊÊÊÂÂÂÀÀÀÆÆÆÍÍÍÊÊÊÉÉÉ×××ããããããäääâââÕÕÕäääëëëîîîçççàààßßßâââäää¿¿¿ÆÆƺºº¼¼¼ÆÆÆÂÂÂÅÅÅÅÅÅÉÉÉÌÌÌÎÎÎÐÐÐÐÐÐÐÐÐÑÑÑÒÒÒÑÑÑÒÒÒÔÔÔ×××ØØØÙÙÙÛÛÛÜÜÜÜÜÜÛÛÛØØØ×××ÔÔÔÒÒÒÒÒÒÒÒÒÔÔÔÔÔÔÒÒÒÔÔÔØØØÛÛÛÜÜÜÜÜÜÕÕÕ×××ÙÙÙÜÜÜÝÝÝÜÜÜØØØÔÔÔÌÌÌÉÉÉÂÂÂäääëëëîîîïïïñññçççîîîÙÙÙàààÝÝÝäääæææíííãããããããããäääãããßßßÙÙÙÕÕÕÇÇÇÂÂÂÃÃÃÎÎÎØØØÙÙÙ×××ÕÕÕÔÔÔÑÑÑÕÕÕÕÕÕÐÐÐØØØÛÛÛÍÍÍÊÊÊÌÌÌÌÌÌÉÉɺºº´´´±±±ÃÃÃÂÂÂÇÇÇÍÍÍÊÊÊÊÊÊÎÎÎÎÎÎÜÜÜÑÑÑÇÇÇÃÃÃÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÃÃÃÀÀÀ¿¿¿¼¼¼¼¼¼»»»»»»ººº·········´´´°°°°°°±±±°°°°°°±±±³³³´´´···ººº»»»»»»ººº¸¸¸¸¸¸¸¸¸ººº¼¼¼¾¾¾ÆÆÆÍÍÍÑÑÑÅÅŵµµ···¾¾¾¿¿¿ÍÍÍÅÅž¾¾¿¿¿ÂÂÂÃÃÃÃÃÃÃÃð°°´´´µµµ°°°ªªª©©©ªªªªªª°°°°°°¯¯¯¯¯¯¸¸¸Â¿¿¿´´´ªªª¦¦¦¬¬¬¾¾¾ÇÇÇÆÆÆÆÆÆÌÌÌÔÔÔ¿¿¿¿¿¿ÉÉÉÉÉÉÍÍÍÙÙÙÝÝÝ×××ÔÔÔÑÑÑÑÑÑÔÔÔÔÔÔÑÑÑÍÍÍÍÍÍÊÊÊÊÊÊÇÇÇÅÅÅÇÇÇÉÉÉÅÅÅÊÊÊÉÉÉÃÃúºº³³³³³³¼¼¼ÆÆÆÇÇÇÐÐÐÒÒÒÉÉÉ»»»µµµººº¿¿¿µµµ´´´»»»ÆÆÆÇÇÇÀÀÀ¾¾¾ÃÃÿ¿¿ÆÆÆÌÌÌÊÊÊÆÆÆÂÂÂÅÅÅÉÉÉ¿¿¿ÆÆÆÔÔÔÝÝÝßßßâââæææäääÝÝÝæææíííëëëèèèèèèçççäääØØØÙÙÙ»»»···ÀÀÀ¼¼¼ÅÅÅÆÆÆÆÆÆÉÉÉÌÌÌÍÍÍÍÍÍÎÎÎÐÐÐÑÑÑÎÎÎÑÑÑÔÔÔÕÕÕ×××ØØØÛÛÛÜÜÜÛÛÛÛÛÛØØØ×××ÔÔÔÑÑÑÎÎÎÍÍÍÍÍÍÊÊÊÉÉÉÍÍÍÒÒÒ××××××ÕÕÕØØØØØØÙÙÙÛÛÛÛÛÛÙÙÙ×××ÕÕÕÌÌÌÍÍÍÇÇÇëëëñññóóóøøøòòòñññöööâââçççâââãããßßßàààêêêäääÝÝÝÙÙÙÙÙÙÛÛÛÜÜÜÜÜÜÎÎÎÂÂÂÀÀÀÑÑÑÛÛÛ×××ÑÑÑÑÑÑÑÑÑÑÑÑØØØÕÕÕÎÎÎÛÛÛàààÎÎÎÊÊÊÌÌÌÌÌÌÉÉÉ»»»···´´´ººº¸¸¸ÂÂÂÍÍÍÎÎÎÐÐÐÍÍÍÂÂÂÙÙÙ×××ÐÐÐÉÉÉÆÆÆÆÆÆÆÆÆÅÅÅÃÃÃÂÂÂÀÀÀ¿¿¿¾¾¾¾¾¾¼¼¼¼¼¼ºººµµµ´´´···µµµ±±±¯¯¯±±±±±±±±±±±±±±±´´´µµµ¸¸¸ººº»»»ººº¸¸¸ººº»»»ÀÀÀÅÅÅÉÉÉÍÍÍÐÐÐÌÌÌÅÅÅÂÂÂÀÀÀÀÀÀÅÅźºº±±±¯¯¯´´´ººººººµµµ³³³ÀÀÀÆÆÆÆÆƾ¾¾¸¸¸······µµµ³³³¸¸¸···±±±´´´¾¾¾¾¾¾···¬¬¬¦¦¦©©©···ÃÃÃÇÇÇÇÇÇÉÉÉÎÎξ¾¾ÀÀÀÊÊÊÉÉÉÑÑÑÜÜÜÛÛÛÙÙÙÕÕÕÐÐÐÎÎÎÎÎÎÍÍÍÉÉÉÃÃÃÀÀÀÀÀÀ¼¼¼»»»¼¼¼¼¼¼¿¿¿ÇÇÇÊÊÊÊÊÊÊÊÊÆÆÆÃÃÃÅÅÅÌÌÌÑÑÑÎÎÎÔÔÔØØØÕÕÕÇÇǾ¾¾¿¿¿ÆÆÆ»»»³³³´´´ÀÀÀÊÊÊÇÇÇÆÆÆÊÊÊÃÃÃÉÉÉÎÎÎÎÎÎÇÇÇÀÀÀ¾¾¾¼¼¼ÅÅÅÇÇÇÆÆÆÉÉÉÐÐÐ×××ÝÝÝæææÛÛÛàààæææçççêêêíííêêêäääãããââ⺺º³³³¾¾¾¸¸¸¿¿¿¿¿¿ÂÂÂÅÅÅÇÇÇÊÊÊÊÊÊÌÌÌÍÍÍÎÎÎÍÍÍÐÐÐÒÒÒÕÕÕÕÕÕ×××ÙÙÙÜÜÜÛÛÛÛÛÛØØØÕÕÕÑÑÑÎÎÎÍÍÍÌÌÌÉÉÉÇÇÇÇÇÇÊÊÊÎÎÎÒÒÒÕÕÕÕÕÕÛÛÛÛÛÛÙÙÙØØØ×××ÕÕÕÕÕÕÕÕÕÐÐÐÎÎÎÆÆÆïïïóóóóóóüüüöööîîîõõõãããêêêççççççßßßÝÝÝãããàààßßßÝÝÝÜÜÜÛÛÛ×××ÔÔÔÝÝÝÇÇÇÀÀÀÐÐÐÛÛÛÕÕÕÐÐÐÔÔÔÎÎÎÑÑÑÛÛÛÕÕÕÍÍÍÜÜÜâââÎÎÎÉÉÉÊÊÊÌÌÌÉÉÉÃÃü¼¼¸¸¸µµµ°°°···ÆÆÆÐÐÐÐÐÐÔÔÔÎÎξ¾¾ÔÔÔÙÙÙØØØÎÎÎÆÆÆÆÆÆÇÇÇÅÅÅÂÂÂÂÂÂÀÀÀ¿¿¿¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾···µµµ¸¸¸¸¸¸´´´±±±´´´±±±±±±±±±±±±³³³µµµ¸¸¸ººº»»»ººº¸¸¸ººº¿¿¿ÆÆÆÍÍÍÑÑÑÉÉÉÆÆÆ»»»»»»ÃÃû»»±±±µµµÇÇÇ¿¿¿ºººººººººººº¿¿¿ÆÆÆ¿¿¿ÆÆÆÉÉÉÅÅÅÂÂÂÅÅÅÅÅÅÃÃÿ¿¿ÇÇÇÇÇÇ»»»µµµººº¼¼¼ººº¸¸¸ªªª¢¢¢©©©¸¸¸ÃÃÃÆÆÆÆÆÆÎÎÎÂÂÂÆÆÆÌÌÌÆÆÆÎÎÎÕÕÕÌÌÌÇÇÇÃÃÿ¿¿¿¿¿Â¾¾¾ººº¿¿¿¿¿¿ººº¸¸¸¾¾¾ººº¾¾¾ÎÎÎÌÌÌÍÍÍÎÎÎÐÐÐÑÑÑÐÐÐÎÎÎÍÍÍÙÙÙÕÕÕÕÕÕ×××ÑÑÑÃÃúºº¸¸¸Âµµµ¯¯¯µµµÀÀÀÃÃÃÂÂÂÀÀÀ¾¾¾ÅÅÅÍÍÍÐÐÐÌÌÌÇÇÇÃÃÃÃÃÃÀÀÀÅÅÅÂÂÂÌÌÌàààæææßßßàààÜÜÜàààâââãããèèèíííêêêäääÝÝÝÝÝݵµµ±±±¿¿¿···ºººµµµ¾¾¾ÀÀÀÅÅÅÆÆÆÇÇÇÉÉÉÊÊÊÍÍÍÍÍÍÐÐÐÒÒÒÔÔÔÕÕÕ×××ÙÙÙÜÜÜÜÜÜÛÛÛ×××ÔÔÔÐÐÐÍÍÍÌÌÌÊÊÊÊÊÊÌÌÌÌÌÌÌÌÌÌÌÌÐÐÐÕÕÕÛÛÛÝÝÝÜÜÜÙÙÙÕÕÕÔÔÔÔÔÔÕÕÕ×××ÕÕÕÍÍÍÀÀÀîîîñññîîîüüüüüüöööúúúúúúòòòçççâââãããèèèãããàààÝÝÝÛÛÛÙÙÙØØØÙÙÙÙÙÙÕÕÕÆÆÆÂÂÂÐÐÐÛÛÛ×××ÑÑÑÒÒÒÒÒÒÎÎÎ×××ÒÒÒØØØàààÎÎÎÅÅÅÆÆÆÇÇÇÇÇÇÆÆÆÃÃþ¾¾ºººµµµ±±±···¾¾¾³³³ºººÎÎÎÍÍÍÇÇǸ¸¸×××àààÔÔÔÍÍÍÇÇÇÃÃÃÆÆÆÀÀÀÂÂÂÃÃÿ¿¿¾¾¾¾¾¾¿¿¿ººººººººº¸¸¸···µµµµµµµµµ±±±···ºººµµµ´´´······´´´´´´···ºººÀÀÀÆÆÆÉÉÉÉÉÉÇÇÇ¿¿¿¸¸¸¼¼¼Â¼¼¼ºººÀÀÀÅÅÅÆÆÆÅÅÅÃÃÃÃÃÃÆÆÆÉÉÉÉÉÉÉÉÉÆÆÆÅÅÅÂÂÂÀÀÀÀÀÀÀÀÀÂÂÂÃÃÃÂÂÂÂÂÂÃÃÃÅÅÅ´´´¬¬¬¼¼¼¿¿¿»»»´´´ªªª¦¦¦©©©´´´¿¿¿ÇÇÇÉÉÉÍÍÍÂÂÂÃÃÃÊÊÊÆÆÆÊÊÊÊÊÊÉÉÉÆÆÆÃÃÿ¿¿¼¼¼¼¼¼¼¼¼¾¾¾Â¾¾¾»»»»»»»»»»»»»»»¼¼¼ÍÍÍÐÐÐÎÎÎÉÉÉÂÂÂÂÂÂÊÊÊÒÒÒÙÙÙ×××ÛÛÛÔÔÔÌÌÌÔÔÔÊÊʨ¨¨ÀÀÀ¼¼¼±±±­­­µµµ¿¿¿Â¾¾¾¾¾¾ÅÅÅÍÍÍÑÑÑÎÎÎÌÌÌÍÍÍÀÀÀ¾¾¾ÊÊÊÙÙÙàààçççæææÛÛÛØØØßßßßßßàààëëëïïïèèèäääâââãããÕÕÕ»»»°°°µµµ»»»···¸¸¸¼¼¼¼¼¼ÇÇÇÆÆƼ¼¼ÅÅÅÇÇÇÌÌÌÒÒÒÕÕÕÒÒÒÒÒÒ×××ÕÕÕÑÑÑÙÙÙÙÙÙØØØ×××ÔÔÔÐÐÐÍÍÍÊÊÊÊÊÊÊÊÊÊÊÊÌÌÌÎÎÎÑÑÑÔÔÔÕÕÕ×××ÝÝÝÙÙÙÒÒÒÔÔÔÑÑÑÐÐÐ×××ØØØÅÅÅÆÆÆëëëõõõñññÿÿÿõõõõõõùùùúúúõõõëëëãããàààâââààààààÝÝÝÜÜÜÛÛÛÛÛÛÙÙÙÙÙÙ×××ÎÎÎÍÍÍØØØàààÜÜÜ×××ÔÔÔÑÑÑÐÐÐÒÒÒÑÑÑ×××ÙÙÙÐÐÐÉÉÉÆÆÆÇÇÇÉÉÉÉÉÉÆÆÆ¿¿¿ºººµµµ¬¬¬¯¯¯···³³³´´´ÂÂÂÉÉÉÔÔÔÆÆÆ×××ÝÝÝÕÕÕÎÎÎÊÊÊÆÆÆÆÆÆÇÇÇÉÉÉÇÇÇÆÆÆÃÃÿ¿¿¾¾¾¼¼¼ÃÃÃÀÀÀ»»»···´´´µµµ¸¸¸ºººººº¼¼¼ººº´´´³³³¸¸¸¼¼¼¼¼¼¼¼¼¾¾¾ÀÀÀÆÆÆÌÌÌÍÍÍÌÌÌÉÉɺºººººÀÀÀÀÀÀººº¾¾¾ÅÅÅÃÃþ¾¾¾¾¾¾¾¾¿¿¿ÀÀÀÀÀÀ¾¾¾¼¼¼ÂÂÂÂÂÂÃÃÃÃÃÃÂÂÂÂÂÂÀÀÀÀÀÀ¿¿¿ÂÂÂÀÀÀÃÃø¸¸¯¯¯¼¼¼Â¼¼¼ººº´´´¯¯¯¬¬¬°°°ºººÂÂÂÉÉÉÍÍÍÂÂÂÃÃÃÊÊÊÆÆÆÉÉÉÊÊÊÇÇÇÆÆÆ¿¿¿¼¼¼¼¼¼¼¼¼¼¼¼ººººººººº¼¼¼ÅÅÅÌÌÌÐÐÐÎÎÎÀÀÀÃÃÃÆÆÆÃÃÿ¿¿ÀÀÀÆÆÆÌÌÌÜÜÜÕÕÕ×××ÔÔÔÎÎÎÕÕÕÎÎΰ°°³³³¼¼¼ÀÀÀ¸¸¸­­­¬¬¬´´´¼¼¼ºººººº¿¿¿ÆÆÆÊÊÊÊÊÊÍÍÍÒÒÒÉÉÉÂÂÂÆÆÆÍÍÍÑÑÑÛÛÛâââÝÝÝßßßãããÝÝÝÜÜÜçççîîîêêêèèèÜÜÜßßßÜÜÜÎÎμ¼¼³³³³³³···ºººÀÀÀ¼¼¼¾¾¾»»»ºººÅÅÅÆÆÆÆÆÆÆÆÆÊÊÊÑÑÑ×××ÙÙÙßßßâââÜÜÜÛÛÛØØØÕÕÕÒÒÒÎÎÎÌÌÌÊÊÊÊÊÊÊÊÊÌÌÌÍÍÍÎÎÎÐÐÐÑÑÑÒÒÒÕÕÕÙÙÙÕÕÕÔÔÔÕÕÕÎÎÎÇÇÇÌÌÌÀÀÀ¾¾¾ÉÉÉæææîîîñññÿÿÿïïïóóóöööùùùöööïïïæææßßßÜÜÜßßßÝÝÝÜÜÜÜÜÜÛÛÛÛÛÛÛÛÛÛÛÛÑÑÑÒÒÒÕÕÕÙÙÙÝÝÝÛÛÛÕÕÕÐÐÐÑÑÑÐÐÐÍÍÍÒÒÒÒÒÒÎÎÎÎÎÎÌÌÌÅÅÅÇÇÇÊÊÊÊÊÊÇÇÇÀÀÀºººµµµ±±±³³³»»»···µµµ¿¿¿ÃÃÃÎÎÎÃÃÃÍÍÍÙÙÙÜÜÜÒÒÒÌÌÌÍÍÍÌÌÌÇÇÇÆÆÆÃÃÃÂÂÂÀÀÀÀÀÀÀÀÀÀÀÀ¿¿¿¼¼¼»»»»»»¾¾¾ÃÃÃÇÇÇÊÊÊÉÉÉÉÉÉÆÆÆÀÀÀ¿¿¿ÃÃÃÉÉÉÊÊÊÌÌÌÌÌÌÌÌÌÍÍÍÍÍÍÊÊÊÅÅÅÀÀÀ¼¼¼¼¼¼¼¼¼¸¸¸¸¸¸ÅÅÅÌÌÌÂÂÂÀÀÀ¾¾¾»»»»»»»»»¼¼¼»»»»»»¾¾¾¾¾¾¾¾¾¾¾¾¿¿¿ÀÀÀÀÀÀÂÂÂÀÀÀÇÇÇÀÀÀ¾¾¾³³³ºººÀÀÀ¾¾¾¿¿¿¿¿¿¸¸¸±±±¯¯¯´´´ºººÉÉÉÎÎÎÂÂÂÅÅÅÊÊÊÆÆÆÉÉÉÉÉÉÇÇÇÅÅÅ¿¿¿¼¼¼»»»»»»»»»ººº¼¼¼¼¼¼¾¾¾ÇÇÇÒÒÒÕÕÕÎÎθ¸¸»»»¿¿¿ÀÀÀÂÂÂÂÂÂÅÅÅÇÇÇ×××ÒÒÒ×××ØØØÑÑÑÒÒÒÑÑÑÀÀÀ´´´µµµººº»»»¸¸¸±±±¯¯¯¯¯¯¼¼¼»»»¼¼¼¿¿¿ÀÀÀ¿¿¿ÆÆÆÍÍÍÉÉÉÃÃÃÂÂÂÂÂÂÅÅÅÎÎÎÜÜÜßßßâââäääÝÝÝÜÜÜçççîîîêêêçççâââßßßââââââÑÑѸ¸¸­­­°°°ºººÆÆÆ»»»µµµ¸¸¸ÅÅÅÂÂÂÊÊÊÆÆÆÇÇÇÐÐÐÔÔÔÐÐÐÑÑÑØØØÜÜÜÛÛÛ×××ÒÒÒÐÐÐÌÌÌÊÊÊÉÉÉÉÉÉÊÊÊÍÍÍÎÎÎÐÐÐÑÑÑÐÐÐÐÐÐÔÔÔÒÒÒÎÎÎÐÐÐÐÐÐÉÉÉÇÇÇÎÎÎÆÆÆÎÎÎÜÜÜêêêëëëöööÿÿÿñññóóóõõõööööööòòòëëëãããÝÝÝÝÝÝÜÜÜÙÙÙØØØØØØØØØÙÙÙÛÛÛÎÎÎ×××ÜÜÜÛÛÛÙÙÙÙÙÙÕÕÕÎÎÎÐÐÐÒÒÒÌÌÌÔÔÔÑÑÑÅÅÅÊÊÊÉÉÉÆÆÆÇÇÇÉÉÉÇÇÇÅÅÅÀÀÀ»»»¸¸¸¸¸¸¼¼¼Âººº¾¾¾ÍÍÍÇÇÇ»»»ÂÂÂ×××ããã×××ÌÌÌÍÍÍÌÌÌÎÎÎÍÍÍÌÌÌÍÍÍÎÎÎÑÑÑÒÒÒÔÔÔÑÑÑÑÑÑÑÑÑÑÑÑÐÐÐÌÌÌÆÆÆÂÂÂÅÅÅÆÆÆÇÇÇÆÆÆÃÃÃÃÃÃÅÅÅÆÆÆÇÇÇÆÆÆÃÃÿ¿¿¼¼¼ºººÀÀÀººº´´´³³³¸¸¸ÉÉÉÍÍÍÀÀÀ¼¼¼»»»»»»¼¼¼¾¾¾¼¼¼ºººµµµ¿¿¿¾¾¾¼¼¼»»»¾¾¾ÀÀÀÅÅÅÇÇÇÅÅÅÎÎÎÅÅÅÃÃô´´µµµ¼¼¼ÀÀÀÂÂÂÀÀÀ¾¾¾¸¸¸³³³±±±°°°ÉÉÉÎÎÎÃÃÃÅÅÅÌÌÌÇÇÇÉÉÉÉÉÉÆÆÆÅÅÅ¿¿¿¼¼¼»»»»»»»»»»»»¿¿¿¼¼¼»»»ÃÃÃÎÎÎÍÍÍ»»»¾¾¾ÀÀÀÃÃÃÆÆÆÉÉÉÉÉÉÊÊÊÍÍÍÎÎÎØØØÜÜÜÒÒÒÐÐÐÒÒÒÐÐÐÀÀÀµµµ°°°¸¸¸¿¿¿»»»±±±­­­´´´µµµººº¼¼¼¼¼¼»»»¿¿¿ÇÇÇ¿¿¿¿¿¿ÀÀÀÀÀÀÂÂÂÊÊÊ×××ÝÝÝßßßãããààààààëëëîîîçççãããçççßßßÝÝÝæææàààÍÍͼ¼¼¸¸¸ÛÛÛäääàààØØØÉÉɼ¼¼¾¾¾···¾¾¾¼¼¼ÀÀÀÉÉÉÍÍÍÌÌÌÎÎÎÒÒÒ×××ÕÕÕÒÒÒÎÎÎÌÌÌÉÉÉÉÉÉÉÉÉÇÇÇÊÊÊÎÎÎÑÑÑÒÒÒÒÒÒÒÒÒÑÑÑÔÔÔÎÎÎÊÊÊÉÉÉÆÆÆÆÆÆÑÑÑãããäääèèèîîîîîîíííöööÿÿÿñññóóóóóóóóóóóóòòòîîîèèèäääÝÝÝÛÛÛ×××ÔÔÔÒÒÒÔÔÔ×××ÙÙÙÔÔÔßßßäääàààÜÜÜÜÜÜÙÙÙÔÔÔÐÐÐÒÒÒÍÍÍÔÔÔÎÎο¿¿ÅÅÅÃÃÃÇÇÇÇÇÇÆÆÆÃÃÃÀÀÀ¾¾¾¼¼¼»»»ººº¼¼¼Â¼¼¼ÀÀÀÐÐÐÌÌÌÊÊÊÆÆÆÂÂÂÐÐÐßßßÛÛÛÔÔÔÑÑÑÍÍÍÐÐÐÒÒÒÕÕÕØØØ×××ÔÔÔÐÐÐÌÌÌÌÌÌÊÊÊÊÊÊÉÉÉÅÅž¾¾´´´¬¬¬ªªªªªª¬¬¬¬¬¬©©©¨¨¨¨¨¨ªªª©©©¨¨¨¦¦¦¨¨¨¬¬¬¯¯¯±±±±±±ººº´´´···¼¼¼¾¾¾ÅÅÅÇÇÇ¿¿¿ÂÂÂÉÉÉÎÎÎÐÐÐÌÌÌÃÃü¼¼¾¾¾¾¾¾¼¼¼¼¼¼¼¼¼¼¼¼¾¾¾¾¾¾ÆÆÆÐÐÐÆÆÆÆÆÆÅÅÅ···¸¸¸ÀÀÀÅÅÅÀÀÀ¾¾¾¿¿¿ÀÀÀ¼¼¼³³³ªªªÊÊÊÐÐÐÅÅÅÇÇÇÍÍÍÇÇÇÉÉÉÇÇÇÆÆÆÅÅÅÃÃÃÀÀÀ¾¾¾¼¼¼»»»»»»µµµ»»»»»»ºººÂÂÂÎÎÎÌÌÌÀÀÀÃÃÃÂÂÂÃÃÃÅÅÅÇÇÇÊÊÊÌÌÌÌÌÌÊÊÊÉÉÉÐÐÐ×××ÕÕÕÔÔÔÔÔÔÑÑÑÇÇǸ¸¸¯¯¯±±±···¸¸¸······¢¢¢¨¨¨³³³¼¼¼¿¿¿¾¾¾ÀÀÀÇÇǼ¼¼ÀÀÀÂÂÂÂÂÂÂÂÂÇÇÇÐÐÐÙÙÙÝÝÝäääâââàààêêêíííçççäääãããßßßÝÝÝàààâââÝÝÝ×××ÐÐÐØØØÝÝÝÙÙÙÛÛÛÎÎλ»»ººº¸¸¸ÂÂÂÆÆÆÆÆÆÃÃÃÃÃÃÉÉÉÎÎÎÐÐÐÐÐÐÎÎÎÌÌÌÉÉÉÇÇÇÇÇÇÇÇÇÇÇÇÆÆÆÊÊÊÎÎÎÒÒÒÕÕÕÕÕÕÔÔÔÒÒÒÒÒÒÐÐÐÍÍÍÉÉÉÀÀÀÆÆÆÜÜÜòòòòòòíííîîîîîîíííòòòñññêêêòòòñññïïïïïïîîîíííëëëêêêàààÜÜÜ×××ÒÒÒÑÑÑÑÑÑÒÒÒÕÕÕÑÑÑÜÜÜãããßßßÙÙÙØØØÕÕÕÒÒÒÎÎÎÒÒÒÑÑÑÑÑÑÊÊÊÀÀÀÀÀÀÂÂÂÇÇÇÅÅÅ¿¿¿¼¼¼»»»»»»¼¼¼¿¿¿¼¼¼ÃÃÿ¿¿¼¼¼¿¿¿ÂÂÂÐÐÐÐÐÐÃÃÃÃÃÃÐÐÐÛÛÛàààßßßÙÙÙÐÐÐÕÕÕÙÙÙÙÙÙÑÑÑÅÅŸ¸¸³³³³³³°°°¯¯¯±±±µµµ···µµµ´´´»»»¸¸¸µµµµµµ³³³±±±´´´ºººµµµ´´´³³³µµµººº¾¾¾ÀÀÀ°°°µµµÅÅÅÊÊÊÂÂÂÀÀÀÅÅÅÅÅÅÌÌÌÌÌÌÌÌÌÎÎÎÐÐÐÐÐÐÍÍÍÊÊÊÒÒÒÔÔÔ×××ØØØÕÕÕÐÐÐÊÊÊÆÆÆÃÃÃÌÌÌÆÆÆÉÉÉÆÆƼ¼¼ÅÅÅÌÌÌÉÉɾ¾¾ÀÀÀÅÅÅÃÃø¸¸­­­ÌÌÌÑÑÑÇÇÇÊÊÊÎÎÎÉÉÉÊÊÊÉÉÉÆÆÆÆÆÆÃÃÿ¿¿¾¾¾¼¼¼»»»ººº¾¾¾¿¿¿ÀÀÀÇÇÇÐÐÐÎÎÎÅÅÅÅÅÅÃÃÃÃÃÃÃÃÃÅÅÅÆÆÆÇÇÇÇÇÇÌÌÌÃÃÃÃÃÃÌÌÌÕÕÕÙÙÙÔÔÔÌÌÌÎÎμ¼¼ªªª©©©±±±¸¸¸¸¸¸···¤¤¤±±±¾¾¾Â¿¿¿¾¾¾ÀÀÀÀÀÀÆÆÆÅÅÅÀÀÀÀÀÀÂÂÂÉÉÉÔÔÔßßßäääàààÜÜÜâââçççèèèëëëäääêêêèèèàààÜÜÜÝÝÝßßßÝÝÝÛÛÛÜÜÜÙÙÙãããâââÙÙÙâââæææâââäääÝÝÝÌÌÌÀÀÀÂÂÂÇÇÇÇÇÇÊÊÊÉÉÉÉÉÉÇÇÇÆÆÆÆÆÆÆÆÆÆÆÆÇÇÇÊÊÊÎÎÎÒÒÒÔÔÔÔÔÔÒÒÒÒÒÒÎÎÎÎÎÎÑÑÑÌÌÌÃÃÃÌÌÌâââïïïîîîçççíííïïïòòòóóóíííëëëïïïïïïíííëëëèèèçççèèèèèèâââßßßÛÛÛ×××ÔÔÔÑÑÑÐÐÐÐÐÐÊÊÊÔÔÔÝÝÝÝÝÝØØØÒÒÒÎÎÎÍÍÍÎÎÎÐÐÐÒÒÒÊÊÊÅÅÅÅÅÅÂÂÂÅÅÅÃÃÿ¿¿¾¾¾»»»ºººººººººÂ¾¾¾ÆÆÆÃÃþ¾¾»»»ºººÆÆÆÐÐÐÊÊÊÃÃÃÆÆÆÒÒÒÙÙÙÛÛÛÝÝÝÛÛÛÝÝÝÝÝÝÕÕÕÉÉɾ¾¾¸¸¸···¾¾¾ººº´´´µµµººº¿¿¿ÀÀÀÀÀÀ»»»¸¸¸···¸¸¸µµµ±±±³³³¸¸¸···µµµ´´´´´´·········µµµµµµ¿¿¿ÊÊÊÉÉÉÂÂÂÇÇÇÍÍÍÇÇÇÐÐÐÌÌÌÇÇÇÅÅÅÆÆÆÇÇÇÉÉÉÉÉÉÊÊÊÌÌÌÎÎÎÐÐÐÎÎÎÌÌÌÇÇÇÅÅÅÅÅÅÉÉÉÉÉÉÍÍÍÅÅž¾¾ÍÍÍÒÒÒÎÎÎÇÇÇÃÃÃÅÅÅÇÇÇÆÆÆ¿¿¿···ÍÍÍÔÔÔÊÊÊÌÌÌÑÑÑÊÊÊÊÊÊÉÉÉÇÇÇÆÆÆÅÅÅÃÃÃÀÀÀ¿¿¿¼¼¼»»»¿¿¿ÀÀÀÅÅÅÉÉÉÎÎÎÑÑÑÎÎÎÉÉÉÂÂÂÂÂÂÃÃÃÃÃÃÃÃÃÃÃÃÅÅÅÆÆÆÇÇÇÃÃÿ¿¿ÂÂÂÌÌÌÔÔÔÒÒÒÍÍÍÐÐÐÃÃô´´¬¬¬±±±ºººººº´´´¤¤¤¨¨¨±±±¼¼¼ÀÀÀ¼¼¼ººº»»»¾¾¾ÆÆÆÆÆÆÃÃÃÅÅÅÂÂÂÅÅÅÎÎÎÛÛÛãããâââÛÛÛßßßäääèèèïïïêêêîîîíííãããÜÜÜÛÛÛÛÛÛÛÛÛßßßàààÛÛÛààààààßßßçççççççççíííëëëßßßÎÎÎÇÇÇÉÉÉÍÍÍÉÉÉÉÉÉÉÉÉÉÉÉÇÇÇÆÆÆÅÅÅÅÅÅÇÇÇÊÊÊÍÍÍÎÎÎÐÐÐÎÎÎÍÍÍÍÍÍÉÉÉÇÇÇÊÊÊÆÆÆÅÅÅ×××çççèèèëëëêêêóóóïïïïïïòòòëëëïïïîîîíííëëëèèèæææãããääääääãããâââßßßÜÜÜØØØÒÒÒÎÎÎÌÌÌÌÌÌÕÕÕàààäääßßßÕÕÕÐÐÐÎÎÎÎÎÎÍÍÍÒÒÒÅÅÅÀÀÀÉÉÉÅÅÅÉÉÉÀÀÀÀÀÀ¿¿¿¾¾¾»»»ººº······¸¸¸»»»ÆÆÆÅÅÅÇÇÇÍÍÍÀÀÀ»»»ÎÎÎ×××ÑÑÑÇÇÇÆÆÆÃÃÃÅÅÅÐÐÐÛÛÛÙÙÙÑÑÑÅÅŸ¸¸µµµ¾¾¾ÆÆƼ¼¼······»»»¿¿¿¿¿¿¾¾¾ºººººº¼¼¼Â¿¿¿···´´´···µµµµµµ···ººº»»»»»»¸¸¸µµµÆÆÆÇÇÇÅÅż¼¼¿¿¿ÒÒÒØØØÇÇÇÕÕÕ×××ÙÙÙÜÜÜÜÜÜ×××ÐÐÐÊÊÊÎÎÎÍÍÍÍÍÍÎÎÎÐÐÐÒÒÒ×××ØØØÉÉÉÊÊÊÍÍÍÑÑѼ¼¼ÐÐÐÒÒÒÑÑÑÍÍÍÊÊÊÇÇÇÇÇÇÆÆÆÃÃÿ¿¿ÎÎÎÕÕÕÊÊÊÍÍÍÒÒÒÌÌÌÌÌÌÉÉÉÇÇÇÇÇÇÆÆÆÅÅÅ¿¿¿¾¾¾¼¼¼»»»¼¼¼ÂÂÂÌÌÌÑÑÑÒÒÒÑÑÑÑÑÑÀÀÀÂÂÂÅÅÅÅÅÅÅÅÅÃÃÃÅÅÅÆÆÆ¿¿¿ÆÆÆÅÅÅ¿¿¿¿¿¿ÇÇÇÐÐÐÔÔÔÉÉÉÎÎÎÊÊʼ¼¼±±±³³³¸¸¸»»»¤¤¤¥¥¥­­­¸¸¸¿¿¿¿¿¿¿¿¿ÀÀÀ´´´ÀÀÀÅÅÅÆÆÆÊÊÊÆÆÆÃÃÃÊÊÊÒÒÒàààãããàààâââäääæææíííäääããããããããããããâââßßßÜÜÜÜÜÜäääÝÝÝÝÝÝàààãããèèèßßßàààçççñññïïïßßßÌÌÌÆÆÆÍÍÍÌÌÌÌÌÌÌÌÌÊÊÊÉÉÉÆÆÆÅÅÅÃÃÃÉÉÉÊÊÊÌÌÌÌÌÌÌÌÌÊÊÊÉÉÉÇÇÇÅÅÅÀÀÀ¾¾¾»»»ÃÃÃÝÝÝîîîçççíííñññøøøèèèàààçççäääíííóóóâââêêêæææàààèèèäääàààÝÝÝßßßÛÛÛãããÝÝÝÎÎÎÐÐÐÐÐÐÃÃÃÙÙÙßßßÙÙÙÙÙÙ×××ÎÎÎÊÊÊÊÊÊÔÔÔÔÔÔÆÆÆ¿¿¿ÅÅÅÉÉÉÅÅž¾¾»»»ººº¸¸¸······¸¸¸»»»±±±¸¸¸ÂÂÂÊÊÊÎÎÎÌÌÌÆÆƾ¾¾ÇÇÇÑÑÑÕÕÕÑÑÑÌÌÌÉÉÉÉÉɸ¸¸µµµµµµººº¾¾¾¿¿¿¿¿¿¿¿¿ººº¸¸¸¸¸¸ººº¾¾¾ÀÀÀ¿¿¿¾¾¾ÀÀÀ¸¸¸¸¸¸¿¿¿¿¿¿···±±±´´´´´´µµµµµµ³³³°°°³³³»»»ÂÂÂÃÃÃÇÇÇÌÌÌÃÃÃÂÂÂÉÉÉÌÌÌÎÎÎ×××ÒÒÒ×××ÛÛÛÑÑÑÎÎÎÕÕÕØØØàààÝÝÝÝÝÝÒÒÒÆÆÆÌÌÌØØØØØØÙÙÙÐÐÐÌÌÌÉÉÉÇÇÇÍÍÍÒÒÒÐÐÐÔÔÔÒÒÒÆÆÆÉÉÉÌÌÌÉÉÉÌÌÌÃÃÃÐÐÐØØØÝÝÝÔÔÔÉÉÉÐÐÐÒÒÒÉÉÉÇÇÇÉÉÉÉÉÉÅÅÅÀÀÀ¾¾¾¾¾¾¿¿¿¾¾¾ÂÂÂÍÍÍ×××ÐÐÐÀÀÀ¼¼¼ÃÃÃÅÅÅÅÅÅÅÅÅÃÃÃÂÂÂÀÀÀÀÀÀ¿¿¿¿¿¿¾¾¾¾¾¾¼¼¼¾¾¾¿¿¿ÂÂÂÂÂÂÐÐÐÒÒÒÎÎÎÉÉÉÅÅźºº´´´¼¼¼µµµ´´´©©©´´´Â¿¿¿ÀÀÀÀÀÀ¼¼¼¼¼¼ÐÐÐÃÃÃÂÂÂÍÍÍÀÀÀÆÆÆÍÍÍÔÔÔÛÛÛÝÝÝßßßâââçççíííóóóîîîçççâââßßßßßßààààààßßßßßßßßßÝÝÝÝÝÝßßßãããçççèèèçççíííîîîàààÌÌÌÇÇÇÑÑÑÎÎÎÌÌÌÇÇÇÅÅÅÅÅÅÆÆÆÅÅÅÂÂÂÇÇÇÊÊÊÉÉÉÃÃÃÂÂÂÅÅÅÅÅÅÀÀÀÃÃúººÇÇÇÅÅÅÝÝÝèèèêêêêêêñññëëëäääâââãããçççëëëîîîëëëçççíííëëëçççèèèäääâââÝÝÝßßßØØØÛÛÛØØØÎÎÎÐÐÐÊÊÊÌÌÌÜÜÜâââÝÝÝàààßßßÕÕÕÐÐÐÌÌÌÒÒÒÐÐÐÆÆÆÀÀÀÅÅÅÆÆÆÀÀÀ­­­±±±´´´´´´±±±¯¯¯ªªª¦¦¦±±±···ÀÀÀÉÉÉÎÎÎÎÎÎÌÌÌÉÉÉÃÃÃÃÃÿ¿¿¾¾¾ÀÀÀÆÆÆÌÌÌÃÃÃÉÉÉÉÉÉÅÅÅÃÃÃÆÆÆÃÃü¼¼ÂÂÂÀÀÀÀÀÀÂÂÂÃÃÃÀÀÀ¼¼¼ºººÀÀÀ···´´´ººº»»»···¸¸¸¾¾¾žžžžžž¡¡¡©©©´´´¾¾¾ÀÀÀ¾¾¾ÃÃÃÇÇÇÇÇÇÇÇÇÎÎÎÔÔÔØØØãããÙÙÙÙÙÙÙÙÙÔÔÔÔÔÔÝÝÝâââÜÜÜÛÛÛÝÝÝÛÛÛÒÒÒ×××ÙÙÙÑÑÑÛÛÛØØØÙÙÙØØØÎÎÎÊÊÊÊÊÊÃÃû»»ÂÂÂÂÂÂÌÌÌÐÐÐÍÍÍÐÐÐÊÊÊÅÅÅÎÎÎÝÝÝÝÝÝÐÐÐÐÐÐÒÒÒÉÉÉÉÉÉÉÉÉÉÉÉÆÆÆ¿¿¿¿¿¿¿¿¿ÀÀÀÂÂÂÉÉÉÑÑÑÌÌÌÀÀÀ¿¿¿ÆÆÆÅÅÅÅÅÅÃÃÃÂÂÂÂÂÂÀÀÀ¿¿¿¿¿¿¾¾¾¾¾¾¼¼¼»»»¼¼¼¾¾¾¿¿¿ÀÀÀÀÀÀÇÇÇÊÊÊÍÍÍÌÌÌ¿¿¿µµµ¸¸¸»»»¸¸¸ªªª³³³ÂÂÂÀÀÀÂÂÂÀÀÀÅÅÅÀÀÀÐÐÐÆÆÆÃÃÃÊÊʾ¾¾ÅÅÅÃÃÃÑÑÑßßßàààÛÛÛØØØÝÝÝäääÙÙÙÝÝÝäääçççæææâââßßßÝÝÝßßßßßßßßßÝÝÝÝÝÝßßßãããæææîîîëëëíííîîîãããÑÑÑÇÇÇÆÆÆÒÒÒÌÌÌÆÆÆÅÅÅÀÀÀ¾¾¾ÃÃÃÌÌÌÅÅÅÇÇÇÆÆÆÂÂÂÂÂÂÅÅž¾¾ÇÇÇÃÃÃØØØÛÛÛçççãããäääëëëòòòîîîçççããããããäääæææçççãããîîîïïïïïïëëëÝÝÝØØØ×××ÝÝÝãããÛÛÛÛÛÛØØØÔÔÔÕÕÕÌÌÌÌÌÌ×××ÙÙÙ×××ÛÛÛÜÜÜÒÒÒÉÉÉÍÍÍÎÎÎÊÊÊÃÃÃÂÂÂÅÅÅÀÀÀººº···ÀÀÀÉÉÉÉÉÉÆÆÆÃÃø¸¸¬¬¬°°°µµµ¿¿¿ÇÇÇÎÎÎÐÐÐÑÑÑÐÐÐÐÐÐÎÎÎÌÌÌÇÇÇÅÅÅÃÃÃÂÂÂÃÃÃÂÂÂÌÌÌÌÌÌÀÀÀ»»»ÀÀÀ¾¾¾¾¾¾¾¾¾¿¿¿ÀÀÀ¿¿¿¼¼¼ººº±±±¬¬¬­­­¬¬¬¦¦¦¥¥¥©©©¯¯¯¯¯¯³³³ºººÀÀÀÅÅž¾¾ÉÉÉÌÌÌÎÎÎÒÒÒÑÑÑÐÐÐÕÕÕÛÛÛÝÝÝÕÕÕÛÛÛÜÜÜÜÜÜØØØÜÜÜ×××ÜÜÜÛÛÛÝÝÝßßßÝÝÝßßßÝÝÝÔÔÔÕÕÕÙÙÙäääæææÛÛÛ×××ÙÙÙ×××ÍÍÍÌÌÌÂÂÂÊÊÊÒÒÒÒÒÒÑÑÑÇÇÇÆÆÆÆÆÆÙÙÙâââÔÔÔÒÒÒÕÕÕÊÊÊÊÊÊÊÊÊÊÊÊÇÇÇÃÃÃÀÀÀÀÀÀÀÀÀÅÅÅÂÂÂÃÃÃÉÉÉÆÆÆÀÀÀÂÂÂÉÉÉÅÅÅÃÃÃÃÃÃÂÂÂÀÀÀ¿¿¿¿¿¿¾¾¾¼¼¼»»»ººººººººº»»»¼¼¼¾¾¾ºººÀÀÀÆÆÆÍÍÍÐÐеµµµµµÀÀÀ¼¼¼ªªª±±±ÀÀÀÂÂÂÅÅÅÃÃÃÉÉÉÂÂÂÍÍÍÇÇÇÆÆÆÇÇǼ¼¼ÅÅÅ¿¿¿ÌÌÌÙÙÙàààßßßÛÛÛÜÜÜàààßßßäääèèèêêêçççãããããããããàààààààààßßßÝÝÝßßßãããçççîîîíííííííííèèèÝÝÝÐÐÐÃÃÃÎÎÎÇÇÇÊÊÊÕÕÕÕÕÕÇÇÇÀÀÀÂÂÂÆÆÆÅÅÅÀÀÀ¾¾¾¿¿¿ÃÃÃÃÃÃÀÀÀ»»»ÂÂÂàààíííñññäääçççõõõîîîêêêæææããããããääääääãããßßßöööïïïëëëæææÌÌÌÂÂÂÃÃÃÐÐÐààààààÝÝÝØØØÕÕÕØØØÎÎÎ×××ÛÛÛÙÙÙÙÙÙÜÜÜÝÝÝÔÔÔÉÉÉÎÎÎÊÊÊÅÅÅÂÂÂÃÃü¼¼µµµ¯¯¯»»»ÃÃõµµ¥¥¥±±±¸¸¸ÂÂÂÊÊÊÐÐÐÒÒÒÒÒÒÒÒÒ××××××ØØØÙÙÙ×××ÐÐÐÇÇÇÀÀÀ¾¾¾ÂÂÂÀÀÀµµµ°°°···ÂÂÂÇÇǼ¼¼¾¾¾ÀÀÀÀÀÀ¾¾¾···°°°¬¬¬µµµ±±±³³³······°°°­­­¯¯¯±±±µµµººº¼¼¼¼¼¼¼¼¼¾¾¾¿¿¿ÀÀÀÅÅÅÇÇÇÔÔÔÕÕÕÒÒÒÜÜÜââââââÕÕÕØØØÔÔÔØØØÕÕÕÝÝÝ×××ßßßÝÝÝÝÝÝßßßßßßâââãããâââÛÛÛÝÝÝäääâââÑÑÑÌÌÌÑÑÑÒÒÒÛÛÛÒÒÒÀÀÀÃÃÃÊÊÊÎÎÎÕÕÕÐÐÐÔÔÔÆÆÆÒÒÒßßßÕÕÕÔÔÔØØØÍÍÍÍÍÍÌÌÌÊÊÊÉÉÉÆÆÆÃÃÃÂÂÂÂÂÂÅÅÅÀÀÀ¿¿¿ÃÃÃÃÃÃÂÂÂÃÃÃÉÉÉÃÃÃÂÂÂÂÂÂÀÀÀ¿¿¿¾¾¾¾¾¾¾¾¾»»»ººº¸¸¸······¸¸¸ººº»»»¾¾¾ÃÃÃÆÆÆÌÌÌÎÎεµµµµµÀÀÀ¼¼¼©©©­­­¾¾¾ÂÂÂÇÇÇÆÆÆÆÆƾ¾¾ÅÅÅÅÅÅÆÆÆÆÆÆ¿¿¿ÇÇÇÃÃÃÅÅÅÍÍÍÛÛÛäääæææææææææííííííëëëêêêèèèçççççççççãããããããããààààààâââäääèèèëëëîîîîîîííííííëëëßßßÒÒÒÊÊÊÇÇÇÎÎÎâââîîîæææÑÑÑÃÃÃÃÃÿ¿¿ººº···ººº¿¿¿ÀÀÀÀÀÀ³³³ÃÃÃßßßîîîïïïèèèíííøøøäääâââââââââäääçççççççççßßßøøøîîîçççàààÃÃ÷··ººº»»»×××àààÝÝÝÕÕÕÒÒÒÙÙÙÔÔÔÝÝÝÛÛÛÙÙÙØØØØØØ×××ÎÎÎÃÃÃÍÍÍÆÆÆ¿¿¿¸¸¸´´´···ÂÂÂÆÆÆÃÃÃÆÆÆÉÉÉÀÀÀ³³³´´´¼¼¼ÇÇÇÐÐÐÒÒÒÒÒÒÒÒÒÑÑÑÕÕÕÔÔÔÒÒÒÔÔÔ×××ÕÕÕÒÒÒÎÎÎÆÆÆÃÃÃÀÀÀ¾¾¾···µµµ¿¿¿ÍÍÍÆÆÆ¿¿¿µµµ­­­¬¬¬°°°¸¸¸¿¿¿¿¿¿¾¾¾¿¿¿ÀÀÀ¿¿¿ººº···¸¸¸»»»ºººººº······¸¸¸¼¼¼¿¿¿¼¼¼ÃÃÃÂÂÂÐÐÐÒÒÒÌÌÌÙÙÙÝÝÝçççÛÛÛÝÝÝÒÒÒØØØÔÔÔàààÙÙÙÝÝÝàààââââââààààààæææîîîââââââæææàààÐÐÐÌÌÌÑÑÑÔÔÔÑÑÑÔÔÔÊÊÊÆÆÆ¿¿¿»»»ÇÇÇÌÌÌ×××ÌÌÌ×××àààÕÕÕÐÐÐÕÕÕÑÑÑÎÎÎÍÍÍÌÌÌÉÉÉÇÇÇÆÆÆÃÃÃÂÂÂÃÃÃÀÀÀ¿¿¿ÂÂÂÃÃÃÃÃÃÃÃÃÅÅÅÂÂÂÂÂÂÀÀÀ¿¿¿¾¾¾¾¾¾¼¼¼¼¼¼ººº¸¸¸···µµµ···¸¸¸ººº»»»ÀÀÀÆÆÆÉÉÉÍÍÍÐÐÐÃÃ÷·····¾¾¾»»»¨¨¨ªªª»»»ÂÂÂÇÇÇÆÆÆÅÅÅ»»»¾¾¾ÀÀÀÃÃÃÃÃÿ¿¿ÅÅÅÆÆÆÂÂÂÆÆÆÒÒÒÝÝÝâââçççëëëëëëèèèçççêêêîîîïïïêêêäääèèèèèèçççæææääääääèèèëëëëëëòòòóóóïïïîîîñññíííæææíííêêêææææææíííëëëÙÙÙÆÆÆÀÀÀ¿¿¿¾¾¾¿¿¿ÂÂÂÂÂÂÀÀÀ¿¿¿ÅÅÅ×××ãããêêêèèèëëëíííêêêÝÝÝÝÝÝßßßâââæææèèèèèèèèèàààóóóîîîæææàààÉÉɺºº¾¾¾¸¸¸ÔÔÔßßßÝÝÝÕÕÕÕÕÕâââàààÝÝÝØØØØØØÕÕÕÎÎÎÌÌÌÇÇÇ¿¿¿ÌÌÌÃÃÃÀÀÀÂÂÂÀÀÀººº···¸¸¸¼¼¼ÀÀÀÂÂÂÀÀÀÃÃÃÇÇÇÃÃúºº¸¸¸ÀÀÀÌÌÌÒÒÒÔÔÔÒÒÒÑÑÑÑÑÑÕÕÕÔÔÔÒÒÒÔÔÔ×××ØØØÕÕÕÔÔÔÎÎÎÉÉÉÉÉÉÌÌÌÃÃ÷··µµµ¿¿¿±±±µµµ»»»¿¿¿ÀÀÀÂÂÂÂÂÂÃÃÃÅÅÅ¿¿¿»»»µµµ±±±±±±´´´¾¾¾···³³³···ÅÅÅÐÐÐÕÕÕÕÕÕÍÍÍÕÕÕÐÐÐØØØ×××ÎÎÎÜÜÜÜÜÜãããØØØÜÜÜÊÊÊÎÎÎÉÉÉÙÙÙÒÒÒÙÙÙàààæææççççççãããæææñññÝÝÝÝÝÝãããäääÝÝÝßßßæææäääÐÐÐ×××ÒÒÒÒÒÒÌÌÌÀÀÀ¼¼¼ÊÊÊÎÎÎÜÜÜãããØØØÎÎÎÐÐÐÒÒÒÐÐÐÍÍÍÊÊÊÉÉÉÉÉÉÆÆÆÅÅÅÂÂÂÂÂÂÀÀÀÀÀÀÃÃÃÃÃÃÃÃÃÂÂÂÂÂÂÀÀÀÀÀÀ¿¿¿¾¾¾¾¾¾¼¼¼»»»»»»······µµµµµµ···¸¸¸»»»¼¼¼¿¿¿ÆÆÆÌÌÌÑÑÑÒÒÒÅÅÅ···¸¸¸»»»¼¼¼ªªª¬¬¬ºººÀÀÀÇÇÇÅÅÅÆÆÆ¿¿¿»»»¼¼¼ÀÀÀ¿¿¿¿¿¿ÃÃÃÂÂÂÅÅÅÌÌÌÍÍÍÎÎÎÙÙÙèèèöööïïïêêêëëëïïïòòòïïïíííîîîîîîíííëëëèèèêêêîîîñññòòòøøøøøøòòòïïïñññòòòïïïíííóóóòòòêêêêêêñññîîîäääæææääääääâââØØØÉÉɼ¼¼¸¸¸ÛÛÛêêêæææêêêèèèñññîîîâââàààßßßßßßâââäääææææææäääâââëëëîîîæææàààÑÑѾ¾¾ÀÀÀ¼¼¼ÎÎÎÑÑÑÑÑÑÎÎÎÑÑÑãããæææãããßßßàààÝÝÝÑÑÑÍÍÍÎÎÎÉÉÉÉÉÉ¿¿¿Â¾¾¾´´´µµµ¾¾¾ÂÂÂÂÂÂÂÂÂÃÃÃÇÇÇÇÇÇÃÃü¼¼¾¾¾ÅÅÅÎÎÎÒÒÒÒÒÒÑÑÑÒÒÒÔÔÔÔÔÔÕÕÕØØØÙÙÙÛÛÛØØØÕÕÕÑÑÑÐÐÐÌÌÌÍÍÍÐÐÐÊÊÊ¿¿¿¸¸¸¸¸¸¿¿¿ÃÃÃÉÉÉÊÊÊÇÇÇÃÃÃÀÀÀ¿¿¿Â¾¾¾»»»»»»¾¾¾ÀÀÀÃÃü¼¼···»»»ÆÆÆÐÐÐÑÑÑÐÐÐÒÒÒàààØØØßßßßßßÛÛÛíííçççêêêÙÙÙÔÔÔ±±±³³³´´´ÕÕÕÛÛÛÛÛÛàààâââæææëëëçççæææïïïäääÜÜÜÜÜÜÝÝÝÛÛÛßßßàààÛÛÛÕÕÕÒÒÒÉÉÉÐÐÐ×××ÔÔÔÑÑÑÅÅÅÀÀÀÊÊÊÒÒÒÙÙÙÝÝÝØØØÐÐÐÑÑÑÐÐÐÍÍÍÊÊÊÉÉÉÉÉÉÇÇÇÅÅÅÂÂÂÂÂÂÃÃÃÃÃÃÃÃÃÂÂÂÂÂÂÂÂÂÂÂÂÀÀÀ¿¿¿¿¿¿¾¾¾¼¼¼»»»»»»ººº···µµµµµµµµµ¸¸¸ººº¼¼¼¾¾¾ÆÆÆÌÌÌÎÎÎÐÐÐÍÍÍ¿¿¿´´´¸¸¸»»»ÀÀÀ±±±±±±»»»¿¿¿ÅÅÅÂÂÂÅÅÅÀÀÀºººººº¿¿¿ÅÅÅÅÅž¾¾Â¿¿¿ÂÂÂÇÇÇÆÆÆÃÃÃÎÎÎÝÝÝöööóóóñññïïïïïïòòòõõõøøøóóóóóóòòòïïïîîîïïïòòòõõõùùùøøøöööóóóòòòòòòóóóòòòîîîóóóõõõïïïíííîîîîîîêêêçççèèèíííîîîèèèàààÜÜÜßßßçççñññæææïïïëëëñññíííàààâââààààààâââäääæææäääããããããæææîîîæææßßßÔÔÔ¼¼¼¾¾¾ºººÀÀÀ»»»»»»¾¾¾ÆÆÆÙÙÙÝÝÝßßßÜÜÜßßßÜÜÜÍÍÍÉÉÉÍÍÍÊÊÊÇÇÇÀÀÀÀÀÀ¼¼¼±±±µµµÀÀÀ¿¿¿¼¼¼¼¼¼ÂÂÂÅÅÅ»»»µµµÀÀÀÇÇÇÎÎÎÒÒÒÑÑÑÑÑÑÔÔÔ×××ÍÍÍÍÍÍÐÐÐÑÑÑÔÔÔ××××××ØØØÐÐÐÐÐÐÎÎÎÎÎÎÐÐÐÎÎÎÇÇÇÂÂÂÇÇÇÊÊÊÊÊÊÉÉÉÅÅÅÃÃÃÃÃÃÅÅÅÇÇÇÊÊÊÊÊÊÇÇǾ¾¾»»»ººº¸¸¸ººº¼¼¼ÂÂÂÉÉÉÐÐÐÕÕÕØØØØØØçççÛÛÛÜÜÜÙÙÙÕÕÕæææÜÜÜëëëÜÜÜØØر±±°°°°°°×××ÝÝÝââââââÜÜÜàààëëëèèèçççñññòòòãããÛÛÛÙÙÙÛÛÛàààâââÙÙÙâââÛÛÛÇÇÇÆÆÆÉÉÉÉÉÉÎÎÎÉÉÉÂÂÂÅÅÅÀÀÀÊÊÊâââäääÔÔÔÍÍÍÐÐÐÍÍÍÊÊÊÉÉÉÉÉÉÇÇÇÅÅÅÂÂÂÃÃÃÅÅÅÅÅÅÃÃÃÂÂÂÀÀÀ¿¿¿¿¿¿¾¾¾¾¾¾¼¼¼»»»ººººººµµµµµµµµµ···¸¸¸»»»¾¾¾ÀÀÀÒÒÒÔÔÔÐÐÐÉÉÉÃÃ÷··±±±¸¸¸¼¼¼ÅÅŸ¸¸µµµ¼¼¼¾¾¾ÃÃÃÀÀÀÀÀÀ¿¿¿¸¸¸¸¸¸ÀÀÀÊÊÊÌÌÌÃÃÃÃÃü¼¼¼¼¼ÆÆÆÉÉÉÇÇÇÌÌÌÕÕÕÙÙÙãããïïïõõõõõõóóóõõõùùùøøøøøøöööóóóñññòòòõõõøøøùùùõõõñññòòòõõõöööóóóòòòöööñññëëëëëëëëëíííííííííèèèææææææäääàààÜÜÜâââëëëîîîóóóæææõõõíííêêêâââÙÙÙâââààààààâââäääææææææäääâââêêêæææèèèßßßÇÇÇÀÀÀ···¾¾¾ÀÀÀÅÅÅÃÃÃÀÀÀ¿¿¿ÂÂÂÆÆÆÝÝÝßßß×××ÑÑÑÒÒÒÍÍÍÉÉÉÐÐп¿¿Â¾¾¾······¼¼¼ÀÀÀ¿¿¿¾¾¾¿¿¿»»»ÆÆÆÅÅÅÍÍÍÀÀÀ»»»¼¼¼ÀÀÀÉÉÉÐÐÐÕÕÕ×××ÕÕÕÔÔÔÐÐÐÑÑÑÔÔÔ×××ØØØØØØ×××ÕÕÕÕÕÕÐÐÐÍÍÍÎÎÎÔÔÔ×××ÒÒÒÍÍÍÎÎÎÍÍÍÊÊÊÇÇÇÆÆÆÅÅÅÆÆÆÆÆÆÇÇÇÆÆÆÃÃÃÃÃÃÃÃÃÃÃÃÀÀÀ¾¾¾»»»¸¸¸ÅÅÅÕÕÕ××××××ÙÙÙØØØàààäääÝÝÝäää×××ÔÔÔíííÝÝÝçççààà×××ÀÀÀ¬¬¬³³³ÒÒÒçççÜÜÜæææäääãããèèèæææäääíííãããîîîíííßßßÙÙÙÝÝÝßßßÜÜÜØØØÛÛÛÜÜÜÙÙÙÔÔÔÍÍÍÉÉÉÇÇÇÇÇÇÉÉÉÅÅÅÐÐÐÒÒÒêêêãããÒÒÒÑÑÑÎÎÎÍÍÍÌÌÌÊÊÊÇÇÇÇÇÇÉÉÉÅÅÅÃÃÃÂÂÂÂÂÂÀÀÀÀÀÀÀÀÀÀÀÀÀÀÀ¿¿¿¼¼¼»»»ºººººº¸¸¸¸¸¸ººº¸¸¸¸¸¸µµµµµµ»»»ÅÅÅÍÍÍÌÌÌÌÌÌÍÍÍÊÊÊÀÀÀµµµ³³³µµµ¸¸¸¿¿¿¸¸¸±±±ºººÀÀÀ¾¾¾¼¼¼¼¼¼¼¼¼»»»³³³¯¯¯¿¿¿ÉÉÉ¿¿¿ÀÀÀÃÃÃÆÆÆÆÆÆÇÇÇÇÇÇÊÊÊÌÌÌÕÕÕ×××ÝÝÝêêêöööúúúõõõîîîîîîøøøüüüõõõîîîïïïöööúúúòòòòòòòòòòòòóóóõõõööööööóóóòòòïïïîîîíííííííííîîîãããâââãããæææäääßßßâââçççîîîïïïñññîîîèèèãããßßßßßßààà×××ÛÛÛãããâââãããæææâââíííîîîãããÝÝÝÌÌ̵µµµµµ±±±¾¾¾ÀÀÀÃÃÃÆÆÆÉÉÉÉÉÉÆÆÆÅÅÅÕÕÕÙÙÙÕÕÕÔÔÔØØØÒÒÒÌÌÌÎÎÎÃÃÃÃÃþ¾¾¸¸¸¸¸¸¾¾¾ÀÀÀ¾¾¾ÀÀÀ¿¿¿ÇÇÇÃÃÃÇÇǼ¼¼¸¸¸¾¾¾ÂÂÂÊÊÊÑÑÑ×××ØØØØØØ×××××××××ÕÕÕ××××××ÕÕÕÔÔÔÒÒÒÔÔÔÕÕÕ××××××ÕÕÕÔÔÔÔÔÔÔÔÔÌÌÌÍÍÍÍÍÍÍÍÍÍÍÍÊÊÊÉÉÉÆÆÆÅÅÅÆÆÆÆÆÆÅÅÅÃÃÃÂÂÂÂÂÂÃÃÃÀÀÀ¿¿¿ÇÇÇÎÎÎÌÌÌÑÑÑÜÜÜààààààäääÝÝÝâââÕÕÕ×××íííÜÜÜîîîèèèãããÒÒÒ¿¿¿ÀÀÀÕÕÕâââàààâââØØØÑÑÑÜÜÜëëëñññïïïññññññïïïíííæææÜÜÜ×××ÕÕÕÕÕÕØØØÛÛÛÛÛÛØØØÒÒÒÌÌÌÉÉÉÑÑÑÇÇÇÂÂÂÑÑÑÌÌÌØØØØØØÛÛÛâââÝÝÝÕÕÕÌÌÌÉÉÉÊÊÊÉÉÉÅÅÅ¿¿¿¿¿¿¼¼¼»»»ºººººº¸¸¸¸¸¸···¸¸¸ººº»»»¼¼¼ÂÂÂÊÊÊÒÒÒÍÍÍÎÎÎÎÎÎÊÊÊ¿¿¿µµµºººÂ¸¸¸³³³¼¼¼Â¿¿¿Â¿¿¿···´´´³³³¸¸¸ÆÆÆÉÉÉ»»»ÀÀÀÃÃÃÆÆÆÇÇÇÆÆÆÇÇÇÉÉÉÊÊÊÍÍÍÐÐÐ×××ßßßçççïïïõõõøøøïïïöööøøøóóóïïïñññóóóóóóïïïïïïïïïïïïñññóóóõõõöööóóóòòòïïïíííëëëëëëíííîîîèèèææææææçççæææãããæææëëëöööóóóîîîçççãããààààààâââãããÛÛÛßßßæææãããããããããàààëëëãããÒÒÒÉÉɸ¸¸¬¬¬´´´ººº¿¿¿¿¿¿ÃÃÃÊÊÊÑÑÑÑÑÑÊÊÊÅÅÅÇÇÇÍÍÍÎÎÎÐÐÐ×××ÕÕÕÍÍÍÊÊÊÅÅÅÃÃþ¾¾»»»»»»¿¿¿¾¾¾»»»¿¿¿ÂÂÂÀÀÀÇÇǺºººººÀÀÀÆÆÆÍÍÍÒÒÒ×××ÙÙÙÙÙÙÙÙÙÙÙÙ×××ÕÕÕÔÔÔÕÕÕÕÕÕÔÔÔÑÑÑÕÕÕÕÕÕÕÕÕÔÔÔÑÑÑÑÑÑÔÔÔ×××ÐÐÐÐÐÐÐÐÐÎÎÎÌÌÌÊÊÊÉÉÉÇÇÇÅÅÅÆÆÆÉÉÉÊÊÊÉÉÉÆÆÆÂÂÂÀÀÀ¿¿¿ÉÉÉØØØÝÝÝ×××ÙÙÙààààààßßßäääÝÝÝÝÝÝÕÕÕÛÛÛíííÛÛÛêêêçççèèèããã××××××ßßßâââçççÒÒÒ¾¾¾···ÂÂÂØØØæææãããäääçççïïïóóóíííäääßßßÝÝÝÕÕÕÔÔÔÕÕÕØØØÛÛÛØØØÒÒÒÌÌÌÃÃÃÅÅÅÆÆÆÑÑÑÅÅÅÌÌÌÊÊÊÊÊÊÝÝÝàààÜÜÜÑÑÑÌÌÌÌÌÌÊÊÊÃÃÃÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÃÃÿ¿¿¾¾¾¼¼¼»»»ººººººººººººµµµººº¼¼¼¼¼¼¾¾¾ÃÃÃÌÌÌÑÑÑÌÌÌÉÉÉÅÅż¼¼±±±¬¬¬µµµÃÃû»»³³³µµµ¾¾¾¾¾¾»»»¾¾¾¼¼¼³³³±±±¸¸¸ÀÀÀÉÉÉÇÇǾ¾¾ÀÀÀÃÃÃÆÆÆÇÇÇÆÆÆÆÆÆÆÆÆÇÇÇÇÇÇÌÌÌÐÐÐÑÑÑÔÔÔÝÝÝíííùùùïïïóóóõõõñññïïïïïïîîîëëëëëëëëëëëëíííîîîñññòòòóóóõõõòòòîîîëëëêêêêêêíííîîîîîîëëëêêêêêêèèèçççêêêîîîóóóïïïêêêæææããããããããããããçççàààãããèèèçççãããâââßßßäääÐÐп¿¿ººº±±±°°°ººº¿¿¿¾¾¾ÀÀÀÆÆÆÍÍÍÑÑÑÐÐÐÊÊÊÅÅž¾¾ÀÀÀÂÂÂÅÅÅÍÍÍÑÑÑÍÍÍÆÆÆ¿¿¿¼¼¼¼¼¼¿¿¿ÀÀÀ»»»µµµººº¼¼¼ÂÂÂÇÇǾ¾¾»»»¾¾¾ÆÆÆÊÊÊÐÐÐÕÕÕØØØØØØØØØÙÙÙÔÔÔÑÑÑÐÐÐÑÑÑÔÔÔÕÕÕÔÔÔÑÑÑÐÐÐÐÐÐÑÑÑ×××ÜÜÜÛÛÛÔÔÔÍÍÍÒÒÒÐÐÐÌÌÌÉÉÉÉÉÉÌÌÌÐÐÐÒÒÒÑÑÑÍÍÍÉÉÉÇÇÇÇÇÇÆÆÆ¿¿¿¾¾¾ÊÊÊÝÝÝãããÝÝÝßßßàààØØØÝÝÝãããÝÝÝÙÙÙÕÕÕÝÝÝëëëÛÛÛæææãããèèèêêêââââââäääàààÜÜÜ¿¿¿µµµÀÀÀÅÅÅÆÆÆÇÇÇÃÃÃÇÇÇØØØêêêîîîèèèëëëîîîçççÙÙÙÔÔÔÐÐÐÑÑÑØØØÛÛÛ×××ÒÒÒÌÌÌÌÌÌÇÇÇÌÌ̾¾¾ÇÇÇÊÊÊÍÍÍÅÅÅÎÎÎ×××ØØØÔÔÔÍÍÍÉÉÉÇÇÇÊÊÊÊÊÊÊÊÊÉÉÉÆÆÆÃÃÃÂÂÂÀÀÀ¿¿¿¾¾¾¼¼¼»»»ºººººººººººº¸¸¸¼¼¼¼¼¼ººº»»»ÀÀÀÆÆÆÉÉÉÊÊÊ···¯¯¯¦¦¦¦¦¦±±±¿¿¿¿¿¿´´´°°°ºººÃÃÿ¿¿¸¸¸ºººµµµ±±±µµµ¿¿¿ÅÅÅÅÅÅÃÃÃÅÅÅÀÀÀÃÃÃÆÆÆÇÇÇÆÆÆÅÅÅÅÅÅÆÆÆÇÇÇÊÊÊÊÊÊÉÉÉÇÇÇÎÎÎÜÜÜèèèëëëïïïòòòñññíííêêêççççççççççççèèèêêêëëëîîîñññòòòõõõòòòíííêêêèèèêêêíííîîîñññïïïííííííëëëêêêëëëíííæææææææææèèèêêêêêêæææâââçççãããæææêêêèèèäääââââââæææÆÆÆ···µµµ³³³´´´······¼¼¼ÂÂÂÉÉÉÍÍÍÌÌÌÉÉÉÇÇÇÇÇǼ¼¼¼¼¼»»»»»»ÂÂÂÌÌÌÎÎÎÉÉɼ¼¼ººº»»»¿¿¿Â¿¿¿¸¸¸³³³¸¸¸»»»ÃÃÃÆÆÆÃÃø¸¸ººº¾¾¾ÇÇÇÍÍÍÔÔÔ××××××ÕÕÕÕÕÕÕÕÕÎÎÎÍÍÍÍÍÍÐÐÐÑÑÑÒÒÒÑÑÑÎÎÎÊÊÊÑÑÑßßßëëëïïïèèèÛÛÛÐÐÐÑÑÑÐÐÐÎÎÎÎÎÎÑÑÑ×××ÜÜÜàààßßßÙÙÙÐÐÐÆÆÆ¿¿¿¿¿¿ÃÃÃÇÇÇÆÆÆÇÇÇÎÎÎÎÎÎÍÍÍ×××ÜÜÜ×××ÜÜÜàààÜÜÜØØØÕÕÕÝÝÝçççÜÜÜëëëçççêêêëëëäääãããäääÝÝÝÛÛÛÃÃþ¾¾ÇÇÇÇÇÇÆÆÆÉÉÉÇÇÇÂÂÂÉÉÉÙÙÙãããæææíííîîîãããâââØØØÎÎÎÌÌÌÒÒÒØØØÛÛÛÙÙÙÜÜÜÎÎÎÆÆÆ×××ÊÊÊÌÌÌÌÌÌÔÔÔÀÀÀÂÂÂÌÌÌ×××ÙÙÙÒÒÒÊÊÊÇÇÇÉÉÉÉÉÉÇÇÇÆÆÆÃÃÃÂÂÂÀÀÀ¿¿¿¾¾¾¼¼¼¼¼¼»»»ºººººº»»»»»»¼¼¼¾¾¾¼¼¼¸¸¸»»»ÃÃÃÆÆÆÅÅÅÉÉÉ»»»­­­¨¨¨©©©­­­···ÀÀÀ¿¿¿°°°­­­ºººÂ¾¾¾»»»¾¾¾´´´±±±´´´¿¿¿ÆÆÆÃÃÃÂÂÂÆÆÆÀÀÀÃÃÃÆÆÆÆÆÆÆÆÆÅÅÅÅÅÅÆÆÆÉÉÉÉÉÉÇÇÇÆÆÆÆÆÆÉÉÉÐÐÐÔÔÔæææëëëññññññêêêäääãããçççääääääæææçççèèèëëëîîîïïïóóóñññíííêêêèèèêêêíííïïïïïïïïïïïïîîîîîîíííêêêçççàààâââäääèèèëëëèèèäääßßßããããããäääèèèêêêäääãããæææããã¾¾¾´´´······»»»¸¸¸´´´»»»ÂÂÂÉÉÉÌÌÌÉÉÉÆÆÆÆÆÆÉÉÉÃÃÃÀÀÀ¾¾¾ººº¼¼¼ÊÊÊÑÑÑÌÌ̼¼¼»»»¼¼¼ÀÀÀ¼¼¼···³³³¼¼¼¼¼¼ÅÅÅÅÅÅÃÃó³³´´´ºººÅÅÅÌÌÌÔÔÔØØØ×××ÔÔÔÑÑÑÑÑÑÍÍÍÎÎÎÍÍÍÍÍÍÍÍÍÌÌÌÍÍÍÍÍÍØØØâââíííñññïïïëëëêêêêêêÜÜÜÝÝÝÝÝÝÝÝÝÜÜÜÜÜÜÛÛÛÛÛÛØØØßßßàààØØØÊÊÊÂÂÂÃÃÃÉÉÉÎÎÎÉÉÉÇÇÇÆÆÆÆÆÆÒÒÒÝÝÝÜÜÜÜÜÜÝÝÝÜÜÜØØØ×××ÜÜÜâââàààêêêæææêêêëëëæææçççêêêæææÂÂÂÃÃÃÉÉÉÎÎÎÑÑÑÕÕÕÒÒÒÊÊÊÉÉɺººÅÅÅßßßêêêîîîíííâââèèèàààÕÕÕÐÐÐÒÒÒ×××ÛÛÛÜÜÜÕÕÕÎÎÎÊÊÊ×××ÍÍÍÑÑÑÊÊÊÆÆÆÑÑÑÇÇÇÃÃÃÍÍÍØØØØØØÐÐÐÆÆÆÆÆÆÅÅÅÃÃÃÀÀÀ¿¿¿¿¿¿¿¿¿¿¿¿¾¾¾¼¼¼»»»»»»ººº»»»»»»»»»¿¿¿¿¿¿¼¼¼ºººÀÀÀÌÌÌÊÊÊÃÃúºº¯¯¯¥¥¥¥¥¥ªªª±±±¸¸¸ÀÀÀ¼¼¼¬¬¬¦¦¦°°°´´´µµµ¸¸¸»»»ººº´´´°°°¸¸¸ÅÅÅÅÅÅÀÀÀÃÃÃÂÂÂÃÃÃÆÆÆÆÆÆÅÅÅÅÅÅÇÇÇÉÉÉÇÇÇÆÆÆÆÆÆÆÆÆÇÇÇÉÉÉÊÊÊÊÊÊãããçççëëëîîîêêêããããããçççäääääääääæææèèèêêêííííííñññïïïíííêêêêêêíííïïïñññïïïññññññïïïîîîîîîèèèãããææææææäääããããããâââßßßÝÝÝàààââââââäääçççãããâââèèèÛÛÛ···µµµ»»»¸¸¸¼¼¼»»»¼¼¼ººº¿¿¿ÅÅÅÊÊÊÌÌÌÊÊÊÉÉÉÇÇÇÃÃÃÃÃü¼¼ºººÆÆÆÎÎÎÆÆÆÅÅÅÀÀÀÀÀÀÂÂÂÀÀÀºººµµµµµµ¾¾¾»»»ÅÅÅÃÃÃÃÃñ±±´´´¸¸¸¿¿¿ÇÇÇÑÑÑ×××ÕÕÕÒÒÒÑÑÑÐÐÐÍÍÍÎÎÎÍÍÍÊÊÊÇÇÇÉÉÉÎÎÎÔÔÔæææèèèèèèæææâââãããíííóóóèèèçççæææãããßßßÙÙÙÕÕÕÒÒÒ×××ÝÝÝäääæææßßßÕÕÕÍÍÍÉÉÉÎÎÎÉÉÉÌÌÌÐÐÐÌÌÌÑÑÑÝÝÝâââÜÜÜÛÛÛÛÛÛÙÙÙØØØÙÙÙÝÝÝäääßßßßßßçççëëëæææçççíííëëë¾¾¾ÆÆÆÆÆÆÃÃÃÍÍÍÕÕÕÕÕÕÐÐÐÉÉɺººÇÇÇãããëëëîîîñññçççíííèèèãããÜÜÜØØØØØØØØØÙÙÙØØØÙÙÙÑÑÑÎÎÎÀÀÀÑÑÑÎÎÎÆÆÆÎÎÎÎÎÎÇÇÇÂÂÂÌÌÌÙÙÙØØØÍÍÍÐÐÐÍÍÍÉÉÉÅÅÅÀÀÀÀÀÀÀÀÀÀÀÀ¼¼¼¼¼¼»»»»»»»»»»»»»»»¼¼¼¿¿¿¿¿¿¼¼¼¼¼¼ÆÆÆÎÎÎÇÇǸ¸¸¬¬¬©©©¨¨¨ªªª¬¬¬­­­´´´¼¼¼»»»­­­ªªª±±±±±±³³³···µµµ¼¼¼»»»³³³´´´¾¾¾ÀÀÀ¿¿¿ÅÅÅÃÃÃÅÅÅÅÅÅÅÅÅÅÅÅÆÆÆÊÊÊÍÍÍÊÊÊÌÌÌÌÌÌÊÊÊÇÇÇÆÆÆÇÇÇÉÉÉäääââââââèèèëëëèèèääääääææææææææææææçççêêêëëëëëëîîîííííííëëëíííïïïñññóóóòòòóóóòòòîîîîîîïïïêêêãããçççæææãããßßßÜÜÜÜÜÜÜÜÜßßßßßßâââààààààäääàààßßßèèèÛÛÛ···ººº¼¼¼´´´···¸¸¸¾¾¾»»»¼¼¼ÀÀÀÉÉÉÐÐÐÐÐÐÌÌÌÆÆÆÀÀÀÀÀÀÃÃþ¾¾¸¸¸ÂÂÂÉÉɾ¾¾ÍÍÍÇÇÇÃÃþ¾¾···µµµ¸¸¸ºººµµµÂÂÂÂÂÂÅÅų³³···»»»ºººÃÃÃÐÐÐ×××ÕÕÕÒÒÒÑÑÑÐÐÐÌÌÌÌÌÌÌÌÌÇÇÇÆÆÆÊÊÊÕÕÕÝÝÝâââßßßÝÝÝÜÜÜÝÝÝßßßààààààæææãããàààÜÜÜÙÙÙØØØØØØØØØæææßßßÙÙÙÝÝÝäääæææÜÜÜÑÑÑÌÌÌÆÆÆÌÌÌÎÎÎÆÆÆÉÉÉÙÙÙæææÜÜÜØØØÛÛÛÛÛÛÙÙÙ×××ÛÛÛèèèÜÜÜßßßèèèëëëâââàààãããâââÃÃÃÊÊÊÇÇÇÌÌÌØØØÕÕÕÊÊÊÊÊÊÆÆÆÇÇÇÜÜÜêêêäääêêêòòòèèèîîîîîîíííçççßßßÙÙÙ××××××ÝÝÝßßßÝÝÝâââÐÐÐÔÔÔÎÎÎÌÌ̺ººÌÌÌÍÍ;¾¾ÀÀÀ×××ààà×××ßßßÛÛÛÔÔÔÌÌÌÆÆƼ¼¼¼¼¼»»»»»»»»»»»»»»»¼¼¼¿¿¿¿¿¿¼¼¼¼¼¼ÅÅÅÌÌÌ¿¿¿ªªª¯¯¯±±±···¸¸¸³³³¯¯¯´´´¾¾¾¿¿¿···¼¼¼ÃÃÃÀÀÀ¾¾¾¼¼¼µµµ¸¸¸¿¿¿»»»´´´···¸¸¸¾¾¾ÊÊÊÅÅÅÅÅÅÅÅÅÃÃÃÃÃÃÆÆÆÌÌÌÐÐÐÎÎÎÑÑÑÑÑÑÌÌÌÅÅÅÀÀÀÅÅÅÊÊÊçççÝÝÝÛÛÛäääîîîîîîçççãããççççççæææççççççèèèêêêëëëííííííííííííîîîñññòòòóóóõõõöööòòòííííííïïïíííæææâââââââââàààÜÜÜÛÛÛÜÜÜßßßßßßâââßßßÝÝÝâââÜÜÜÜÜÜèè謬¬¾¾¾¿¿¿ººº»»»»»»···ººººººÃÃÃÊÊÊÌÌÌÌÌÌÌÌÌÉÉÉÃÃÃÆÆÆÅÅÅÇÇÇÂÂÂÀÀÀ¼¼¼µµµÃÃÃÎÎÎÍÍÍÇÇǾ¾¾ººº»»»¸¸¸³³³³³³µµµÂÂÂÆÆƼ¼¼¸¸¸¸¸¸³³³¸¸¸ÂÂÂÎÎÎÔÔÔÒÒÒÎÎÎÍÍÍÌÌÌÇÇÇÐÐÐÍÍÍÀÀÀÀÀÀÐÐÐÝÝÝàààØØØÙÙÙÛÛÛÛÛÛÙÙÙÙÙÙÜÜÜßßßÜÜÜâââæææäääßßßÙÙÙ×××ØØØÜÜÜÝÝÝÜÜÜÙÙÙÙÙÙÝÝÝçççîîîÎÎÎÍÍÍÌÌÌÌÌÌÌÌÌÎÎÎÑÑÑÒÒÒÐÐÐÎÎÎÙÙÙÝÝÝÝÝÝÛÛÛÒÒÒØØØâââèèèæææçççãããÝÝÝæææäääÂÂÂÆÆÆÊÊÊÐÐÐÑÑÑÑÑÑÐÐÐÍÍÍÇÇÇ¿¿¿ççççççïïïóóóêêêîîîñññèèèàààÜÜÜÜÜÜÜÜÜÛÛÛ×××ÙÙÙ×××ÝÝÝäääÛÛÛÊÊÊÉÉÉÔÔÔÒÒÒÀÀÀÎÎÎÊÊʺºº¿¿¿ÊÊÊ××××××ØØØÙÙÙÕÕÕÉÉÉ¿¿¿ÅÅÅÐÐÐÐÐÐÀÀÀµµµ···ºººººº»»»¿¿¿ÅÅÅ¿¿¿ÊÊÊÊÊÊÅÅż¼¼©©©ªªª¸¸¸···¸¸¸ººº¾¾¾¾¾¾ºººµµµ¸¸¸¼¼¼ÀÀÀÀÀÀ¼¼¼»»»¾¾¾ÀÀÀªªªÀÀÀ¾¾¾´´´»»»¸¸¸´´´¿¿¿¼¼¼¸¸¸ÀÀÀÎÎÎÑÑÑÉÉÉÉÉÉÑÑÑÊÊÊÐÐÐÑÑÑÊÊÊÃÃÃÅÅÅÆÆÆÅÅÅÇÇÇÆÆÆ×××æææäääæææëëëêêêèèèççççççæææææææææææææææççççççæææçççëëëñññöööúúúõõõöööøøøöööóóóñññòòòòòòâââäääÝÝÝßßßîîîñññíííïïïïïïîîîëëëêêêíííïïïæææÙÙÙººº···»»»¿¿¿¾¾¾ºººººº»»»¼¼¼ÅÅÅÌÌÌÊÊÊÊÊÊÊÊÊÇÇÇÃÃÃÅÅÅÂÂÂÅÅÅÀÀÀ¿¿¿µµµÂÂÂÂÂÂÆÆÆÆÆÆ¿¿¿ººº···´´´¯¯¯¸¸¸···¿¿¿ÅÅÅÃÃÃÆÆÆÆÆƼ¼¼µµµ¿¿¿ÊÊÊÑÑÑÑÑÑÎÎÎÌÌÌÌÌÌÉÉÉÉÉÉÆÆÆÅÅÅÍÍÍÙÙÙÛÛÛÕÕÕÙÙÙÛÛÛÝÝÝÜÜÜÙÙÙÙÙÙÛÛÛÝÝÝàààãããæææãããÝÝÝÙÙÙÙÙÙÜÜÜÙÙÙÙÙÙØØØÔÔÔÒÒÒØØØàààèèèÌÌÌÍÍÍÎÎÎÑÑÑÑÑÑÐÐÐÍÍÍÌÌÌÐÐÐÊÊÊÒÒÒ×××ÙÙÙÙÙÙÐÐÐÔÔÔØØØããããããçççëëëëëëëëëÜÜÜÀÀÀÃÃÃÉÉÉÍÍÍÐÐÐÎÎÎÍÍÍÌÌÌÃÃÃÃÃÃæææçççñññòòòîîîêêêäääàààÜÜÜÛÛÛÜÜÜÝÝÝÝÝÝÛÛÛ×××ØØØÙÙÙÜÜÜÛÛÛØØØÕÕÕÕÕÕÔÔÔÀÀÀÐÐÐÒÒÒ¾¾¾ºººÅÅÅ×××ÔÔÔÕÕÕØØØØØØÒÒÒÎÎÎÐÐÐÒÒÒÊÊÊÇÇÇÃÃþ¾¾¸¸¸¸¸¸¾¾¾ÃÃÃÐÐÐÅÅÅÅÅż¼¼´´´±±±©©©±±±¸¸¸ººº»»»»»»ººº¸¸¸¸¸¸¸¸¸³³³µµµ······µµµµµµººº¼¼¼ªªªººº¼¼¼»»»¿¿¿¼¼¼ºººÀÀÀÐÐÐÅÅž¾¾ÆÆÆÑÑÑÒÒÒÊÊÊÂÂÂÍÍÍÑÑÑÐÐÐÉÉÉÃÃÃÃÃÃÃÃÃÂÂÂÅÅÅÃÃÃÌÌÌ×××ÜÜÜàààçççëëëêêêèèèçççæææääääääääääääææææææçççèèèëëëïïïòòòõõõòòòóóóõõõõõõòòòòòòòòòóóóçççãããÜÜÜÝÝÝçççëëëèèèçççëëëíííêêêèèèêêêëëëãããÙÙÙÌÌ̵µµµµµÂ¿¿¿ººº¾¾¾¾¾¾ÂÂÂÇÇÇÊÊÊÊÊÊÉÉÉÉÉÉÇÇÇÅÅÅÆÆÆÂÂÂÃÃÃÀÀÀÃÃÿ¿¿³³³ººº¸¸¸ÂÂÂÇÇÇÃÃû»»µµµ±±±°°°³³³¸¸¸ÂÂÂÅÅÅÂÂÂÉÉÉÎÎÎÊÊÊ´´´¼¼¼ÇÇÇÍÍÍÎÎÎÌÌÌÊÊÊÊÊÊÆÆÆÅÅÅÆÆÆÍÍÍØØØÜÜÜ×××ÐÐÐÙÙÙÜÜÜàààßßßÛÛÛÙÙÙÛÛÛßßßãããääääääâââÜÜÜÛÛÛÝÝÝàààÛÛÛÛÛÛØØØÔÔÔÑÑÑÔÔÔÝÝÝäääÎÎÎÐÐÐÐÐÐÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÊÊÊÑÑÑÔÔÔÙÙÙÛÛÛÑÑÑÔÔÔÙÙÙèèèäääãããèèèëëëÝÝÝ»»»¾¾¾ÀÀÀÅÅÅÉÉÉÌÌÌÌÌÌÊÊÊÉÉÉÅÅÅÎÎÎèèèêêêòòòòòòõõõæææßßßÝÝÝÝÝÝßßßßßßßßßÝÝÝÝÝÝ×××ÛÛÛÙÙÙÕÕÕÛÛÛäääàààÒÒÒØØØÀÀÀÌÌÌÕÕÕÇÇǼ¼¼¿¿¿ÍÍÍÔÔÔÔÔÔÒÒÒÑÑÑÑÑÑÐÐÐÌÌÌÇÇÇÍÍÍÑÑÑÌÌ̼¼¼···¿¿¿ÇÇÇÊÊÊÎÎÎÃÃü¼¼¯¯¯¨¨¨©©©¬¬¬···µµµ······ººº»»»ººº···´´´³³³´´´´´´µµµ···¸¸¸¼¼¼¾¾¾¸¸¸»»»¾¾¾ÀÀÀ¿¿¿ÂÂÂÆÆÆÆÆÆÇÇÇÆÆÆÆÆÆÊÊÊÒÒÒÒÒÒÎÎÎÇÇÇÊÊÊÊÊÊÇÇÇÆÆÆÉÉÉÊÊÊÉÉÉÅÅÅÃÃÃÃÃÃÍÍÍÙÙÙßßßàààçççêêêèèèçççæææããããããââââââãããäääçççêêêíííîîîïïïïïïòòòóóóóóóóóóïïïîîîíííîîîçççßßßÛÛÛÜÜÜßßßäääçççâââèèèèèèèèèççççççæææàààÛÛÛØØØÀÀÀ···¾¾¾¿¿¿¼¼¼¿¿¿ÂÂÂÆÆÆÉÉÉÊÊÊÉÉÉÆÆÆÆÆÆÆÆÆÆÆÆÌÌÌÅÅÅÅÅÅÀÀÀÃÃü¼¼­­­±±±¼¼¼ÅÅÅÊÊÊÆÆÆ»»»´´´µµµ¸¸¸´´´µµµ¾¾¾ÂÂÂÀÀÀÇÇÇÌÌÌÆÆƸ¸¸¿¿¿ÆÆÆÌÌÌÌÌÌÊÊÊÇÇÇÇÇÇÅÅÅÇÇÇÎÎÎ××××××ÑÑÑÑÑÑÕÕÕ×××ÛÛÛßßßßßßÜÜÜÛÛÛÝÝÝàààäääæææäääâââßßßÝÝÝàààããããããâââßßßÙÙÙÕÕÕØØØàààçççÐÐÐÐÐÐÑÑÑÒÒÒÔÔÔÔÔÔÕÕÕÕÕÕÒÒÒÐÐÐÙÙÙÙÙÙÛÛÛÝÝÝÕÕÕØØØ×××êêêçççàààçççîîîÝÝݵµµººº¼¼¼ÀÀÀÅÅÅÇÇÇÇÇÇÆÆÆÅÅÅÑÑÑàààñññîîîóóóñññúúúããããããäääææææææâââÝÝÝÜÜÜÛÛÛÛÛÛÝÝÝÛÛÛ×××ÛÛÛäääßßßÑÑÑÙÙÙÃÃÃÃÃÃÑÑÑÑÑÑÉÉÉÃÃÿ¿¿ÑÑÑÑÑÑÐÐÐÌÌÌÌÌÌÌÌÌÉÉÉÅÅÅÍÍÍÒÒÒÍÍÍÂÂÂÂÂÂÍÍÍÌÌÌÀÀÀ¼¼¼¸¸¸´´´­­­©©©ªªª°°°¸¸¸³³³­­­ªªª³³³¾¾¾ÀÀÀ···­­­³³³³³³´´´···ººº¼¼¼¾¾¾¾¾¾ÇÇǺººµµµ···­­­¬¬¬³³³´´´¸¸¸ÃÃÃÍÍÍÌÌÌÇÇÇÌÌÌÕÕÕÝÝÝÔÔÔÑÑÑÍÍÍÇÇÇÅÅÅÂÂÂÀÀÀ¿¿¿ÅÅÅÅÅÅÃÃÃÍÍÍßßßàààÙÙÙßßßêêêèèèæææãããâââàààààààààâââäääçççêêêíííïïïïïïïïïòòòóóóóóóñññëëëæææäääãããâââÛÛÛÝÝÝàààÜÜÜàààçççãããäääççççççæææäääãããàààÝÝÝßßßÔÔÔÀÀÀ···¼¼¼ÀÀÀÂÂÂÆÆÆÇÇÇÇÇÇÉÉÉÇÇÇÅÅÅÃÃÃÅÅÅÆÆÆÉÉÉÃÃþ¾¾¿¿¿»»»¬¬¬³³³ÃÃÃÇÇÇÉÉɸ¸¸³³³¸¸¸ÀÀÀÃÃõµµ´´´¾¾¾ÇÇÇÍÍÍÆÆÆ´´´¾¾¾ÂÂÂÇÇÇÊÊÊÊÊÊÇÇÇÅÅÅÃÃÃÌÌÌÎÎÎÔÔÔ×××ÐÐÐÇÇÇÍÍÍÙÙÙÔÔÔØØØÜÜÜÜÜÜÜÜÜÜÜÜàààããããããäääääääääãããâââââââââççççççäääßßßÛÛÛÛÛÛâââçççÑÑÑÒÒÒÔÔÔÔÔÔÔÔÔÒÒÒÑÑÑÐÐÐÐÐÐÔÔÔàààÝÝÝÛÛÛÛÛÛÕÕÕÛÛÛÔÔÔèèèãããÙÙÙÜÜÜäääÙÙÙµµµ···¸¸¸¼¼¼ÀÀÀÂÂÂÃÃÃÃÃÃÂÂÂãããóóóùùùòòòóóóñññÿÿÿãããäääçççèèèçççâââÜÜÜÛÛÛÛÛÛÜÜÜÝÝÝÜÜÜÜÜÜÝÝÝÝÝÝÛÛÛ×××ÒÒÒÇÇÇÅÅÅÍÍÍÐÐÐÎÎÎÉÉɾ¾¾ÃÃÃÊÊÊÑÑÑÒÒÒÐÐÐÍÍÍÍÍÍÍÍÍÇÇÇÑÑÑÔÔÔÎÎÎÎÎÎÎÎÎÀÀÀ¯¯¯±±±³³³±±±°°°¯¯¯¯¯¯´´´µµµ­­­¨¨¨¤¤¤ªªª···¾¾¾ººº³³³¯¯¯°°°±±±´´´···ºººººº¸¸¸»»»¬¬¬­­­´´´±±±···ÃÃÃÅÅÅÀÀÀÂÂÂÉÉÉÎÎÎÐÐÐÌÌÌÌÌÌÐÐÐÕÕÕÑÑÑÌÌÌÇÇÇÅÅÅÀÀÀ¿¿¿¿¿¿ÂÂÂÃÃÃÀÀÀÊÊÊÜÜÜßßßÙÙÙßßßæææäääãããâââàààßßßßßßßßßãããäääçççêêêîîîñññòòòòòòîîîïïïïïïíííèèèãããàààßßßßßßßßßçççèèèÜÜÜÜÜÜääääääãããäääææææææäääâââââââââàààâââÍÍ͸¸¸»»»ÀÀÀÂÂÂÆÆÆÇÇÇÆÆÆÆÆÆÆÆÆÅÅÅÂÂÂÂÂÂÆÆÆÀÀÀ¼¼¼¾¾¾ººº»»»ººº³³³¿¿¿ÆÆÆÅÅž¾¾···´´´»»»ÅÅÅÍÍÍ»»»¸¸¸ÅÅÅÉÉÉÆÆÆ¿¿¿µµµÂÂÂÅÅÅÇÇÇÉÉÉÉÉÉÆÆÆÂÂÂÀÀÀØØØÒÒÒÐÐÐÑÑÑÎÎÎÌÌÌÎÎÎ×××ÒÒÒÔÔÔ×××ØØØÙÙÙÝÝÝàààäääâââãããäääææææææäääãããâââääääääãããßßßÛÛÛÙÙÙÝÝÝâââãããÝÝÝÕÕÕÎÎÎÍÍÍÎÎÎÒÒÒÕÕÕÒÒÒ×××ãããÜÜÜØØØÙÙÙÕÕÕÙÙÙßßßëëëãããÛÛÛÜÜÜàààÙÙÙ¾¾¾´´´µµµººº¼¼¼¿¿¿¿¿¿ÀÀÀ¿¿¿îîîùùùÿÿÿóóóóóóïïïÿÿÿæææàààãããäääãããâââààààààãããâââÝÝÝÝÝÝàààßßßÛÛÛÛÛÛßßßÉÉÉÎÎÎÌÌÌÍÍÍÊÊÊÇÇÇÍÍÍÆÆÆ»»»ÂÂÂÍÍÍÒÒÒÌÌÌÂÂÂÀÀÀÆÆÆÎÎÎÑÑÑÒÒÒÍÍÍÆÆƾ¾¾µµµ°°°³³³···³³³³³³³³³±±±´´´¯¯¯¬¬¬ªªªªªª©©©¬¬¬±±±¸¸¸¼¼¼³³³µµµ···¸¸¸¸¸¸ºººººº»»»Â»»»¿¿¿ÆÆÆÂÂÂÅÅÅÌÌÌÉÉÉÂÂÂÂÂÂÇÇÇÑÑÑÔÔÔÎÎÎÇÇÇÅÅÅÍÍÍÉÉÉÇÇÇÆÆÆÅÅÅÃÃÃÆÆÆÊÊÊÀÀÀ¾¾¾¼¼¼ÅÅÅÒÒÒÙÙÙÜÜÜãããàààßßßßßßÝÝÝÝÝÝÝÝÝßßßßßßäääæææèèèëëëîîîïïïñññòòòçççèèèëëëëëëèèèäääããããããäääçççíííëëëàààÜÜÜßßßààààààßßßâââääääääããããããæææâââæææÛÛÛÆÆÆ»»»¾¾¾ÂÂÂÃÃÃÅÅÅÃÃÃÃÃÃÆÆÆÅÅÅÀÀÀÂÂÂÆÆƺººººº¼¼¼µµµµµµ···µµµÉÉÉÇÇÇÃÃÃÀÀÀ¿¿¿¾¾¾¾¾¾ÂÂÂÊÊÊÌÌ̼¼¼ÀÀÀÌÌÌÃÃ÷··ºººÀÀÀÀÀÀÂÂÂÅÅÅÆÆÆÆÆÆÃÃÃÀÀÀ¿¿¿ÜÜÜÔÔÔÍÍÍÍÍÍÐÐÐÑÑÑÑÑÑÒÒÒÕÕÕÒÒÒÒÒÒÔÔÔ×××ÜÜÜßßßâââââââââäääæææææææææäääãããßßßââââââÝÝÝÙÙÙØØØÙÙÙÝÝÝïïïèèèàààØØØÕÕÕØØØßßßãããÝÝÝÜÜÜâââÙÙÙØØØßßßØØØØØØëëëîîîäääæææííííííæææÑÑѳ³³´´´···ººº¼¼¼¾¾¾¾¾¾¾¾¾ëëëòòòúúúòòòóóóïïïùùùçççââââââãããäääæææèèèîîîñññïïïçççàààßßßßßßÜÜÜÜÜÜßßßÊÊÊÑÑÑÌÌÌÍÍÍÇÇÇ¿¿¿ÌÌÌÐÐо¾¾ÀÀÀÅÅÅ¿¿¿³³³µµµÂÂÂÐÐÐÆÆÆÂÂÂÅÅÅÀÀÀµµµ±±±µµµ´´´»»»µµµ¸¸¸ºººµµµµµµ©©©¬¬¬±±±´´´³³³­­­¬¬¬°°°µµµ»»»¼¼¼¼¼¼ººº···¸¸¸¼¼¼¿¿¿¸¸¸ººº¿¿¿ÀÀÀÀÀÀÆÆÆÉÉÉÆÆƸ¸¸ÃÃÃÎÎÎÔÔÔÒÒÒÐÐÐÊÊÊÆÆÆÔÔÔÐÐÐÌÌÌÉÉɼ¼¼¾¾¾ÃÃÃÅÅÅÀÀÀÅÅÅÍÍÍÐÐÐÕÕÕÜÜÜâââÛÛÛÛÛÛÛÛÛÛÛÛÜÜÜÝÝÝßßßàààäääçççêêêíííîîîíííëëëêêêæææèèèííííííëëëèèèçççæææëëëíííèèèææææææâââÝÝÝÝÝÝÜÜÜÙÙÙÛÛÛàààãããâââãããæææããããããâââÒÒÒ»»»ºººÂÂÂÀÀÀÃÃÃÂÂÂÂÂÂÆÆÆÅÅÅ¿¿¿ÀÀÀÆÆÆ»»»»»»¾¾¾´´´±±±±±±µµµÌÌÌÉÉÉÃÃÃÂÂÂÆÆÆÉÉÉÇÇÇÊÊÊÐÐÐÍÍ͸¸¸ºººÇÇÇÀÀÀ±±±···ÃÃþ¾¾¿¿¿ÀÀÀÂÂÂÃÃÃÂÂÂÀÀÀ¾¾¾ØØØÔÔÔÐÐÐÍÍÍÐÐÐÒÒÒÒÒÒÑÑÑ×××ÔÔÔÐÐÐÐÐÐÕÕÕÛÛÛÝÝÝÝÝÝââââââãããääääääæææääääääÝÝÝàààâââßßßÛÛÛØØØÙÙÙÜÜÜèèèëëëïïïòòòñññîîîêêêçççëëëãããàààØØØÜÜÜæææßßßÛÛÛñññêêêÜÜÜâââçççÝÝÝÑÑÑ»»»±±±´´´µµµ¸¸¸»»»¼¼¼¾¾¾¾¾¾äääçççöööïïïòòòïïïöööèèèçççççççççèèèíííòòòøøøüüüÿÿÿòòòäääÜÜÜÜÜÜÝÝÝÝÝÝÛÛÛÒÒÒÑÑÑÅÅÅÍÍÍÊÊʾ¾¾ÉÉÉÑÑÑÎÎξ¾¾µµµººº¸¸¸³³³¾¾¾ÒÒÒÃÃó³³³³³ÇÇÇÎÎο¿¿¯¯¯­­­±±±»»»¸¸¸¿¿¿ÃÃü¼¼¸¸¸¥¥¥¯¯¯´´´»»»¾¾¾ººº±±±©©©¥¥¥»»»»»»¸¸¸³³³¯¯¯°°°···¼¼¼ºººÀÀÀÀÀÀ»»»¼¼¼ÃÃÃÆÆÆÆÆƺººÉÉÉÒÒÒÑÑÑÑÑÑÕÕÕÍÍÍ¿¿¿ÒÒÒÎÎÎÌÌÌÉÉÉ»»»¾¾¾ÆÆÆÊÊÊÇÇÇÒÒÒÛÛÛÕÕÕÕÕÕÛÛÛÙÙÙ××××××ØØØÙÙÙÛÛÛÝÝÝàààâââäääçççëëëîîîîîîëëëæææâââêêêíííïïïïïïíííêêêçççæææîîîíííàààßßßêêêèèèßßßÝÝÝÙÙÙÕÕÕ×××ÝÝÝâââââââââæææßßßçççßßßßßßÛÛÛ±±±¼¼¼¿¿¿ÀÀÀÅÅÅÅÅÅÂÂÂÀÀÀÃÃÃÃÃÃÀÀÀººº¾¾¾°°°¼¼¼»»»­­­ÂÂÂÇÇÇÆÆÆÊÊÊÎÎÎÑÑÑÑÑÑÐÐÐÎÎÎÎÎÎÌÌ̾¾¾»»»ºººÅÅÅ°°°°°°ºººµµµººº¾¾¾ÂÂÂÂÂÂÀÀÀÂÂÂÂÂÂ×××ÙÙÙÉÉÉÌÌÌÑÑÑÊÊÊÎÎÎÎÎÎÎÎÎÊÊÊÑÑÑÔÔÔÐÐÐÔÔÔÜÜÜÙÙÙßßßàààãããäääääääääãããâââæææâââàààâââßßßØØØÕÕÕ×××ßßßãããææææææãããâââäääèèèêêêäääãããäääãããÝÝÝÝÝÝâââëëëëëëâââêêêÜÜÜÐÐеµµ±±±´´´µµµµµµ»»»¼¼¼ÃÃü¼¼âââæææòòòííííííîîîêêêõõõÿÿÿæææäääæææíííõõõùùùùùùöööóóóñññëëëãããÛÛÛØØØØØØÙÙÙÒÒÒæææÍÍÍÅÅÅÕÕÕÎÎÎÊÊÊÎÎÎÍÍÍÊÊʾ¾¾¾¾¾»»»¸¸¸ÊÊÊÔÔÔÍÍÍÍÍÍÑÑÑÎÎÎÉÉÉÌÌÌÃÃí­­±±±³³³»»»¾¾¾»»»¾¾¾¸¸¸ªªª°°°¾¾¾Âººº···ººº³³³¨¨¨¼¼¼»»»´´´©©©¨¨¨¯¯¯µµµµµµ»»»···ºººÂ¿¿¿µµµµµµ¼¼¼ÂÂÂÍÍÍÑÑÑÐÐÐÑÑÑÕÕÕÍÍÍÀÀÀÎÎÎÍÍÍÃÃÃÊÊÊÉÉɾ¾¾ÃÃÃÂÂÂÉÉÉÑÑÑÙÙÙØØØÕÕÕÔÔÔÔÔÔÔÔÔÔÔÔÎÎÎÎÎÎÕÕÕÛÛÛÛÛÛÜÜÜâââääääääçççíííïïïíííçççãããâââæææëëëïïïïïïîîîëëëëëëíííæææßßßÛÛÛØØØØØØâââíííàààÜÜÜÙÙÙÛÛÛàààæææçççæææëëëñññæææäääããã···ººº»»»¿¿¿Â¾¾¾¾¾¾ÀÀÀÀÀÀ¾¾¾¼¼¼¾¾¾°°°ººº¸¸¸¯¯¯ÅÅÅÍÍÍÉÉÉÌÌÌÑÑÑÒÒÒÒÒÒÑÑÑÐÐÐÐÐÐÐÐÐÅÅž¾¾ÆÆÆ´´´´´´¼¼¼···ººº¾¾¾ÀÀÀÀÀÀ¿¿¿ÀÀÀÂÂÂÊÊÊÒÒÒÉÉÉÉÉÉÎÎÎÌÌÌÑÑÑÑÑÑÉÉÉÉÉÉÐÐÐÒÒÒÎÎÎÒÒÒÛÛÛÛÛÛßßßàààâââãããäääãããâââàààçççäääãããæææäääßßßÝÝÝàààäääææææææäääâââãããèèèîîîæææãããâââããããããâââæææíííêêêëëëæææäääÍÍÍÃÃ÷··µµµ´´´µµµ³³³»»»¾¾¾ÀÀÀºººâââçççñññêêêèèèëëëèèèòòòúúúæææëëëòòòøøøùùùøøøöööõõõõõõòòòëëëãããÜÜÜÙÙÙÜÜÜààà×××âââÊÊÊÅÅÅÔÔÔÐÐÐÌÌÌÊÊÊÅÅÅÍÍÍÍÍÍÐÐÐÆÆƼ¼¼ÊÊÊÕÕÕÑÑÑÑÑÑÔÔÔÔÔÔÐÐÐÐÐÐÅÅÅ­­­±±±³³³ººº¼¼¼»»»ÀÀÀ¸¸¸¬¬¬¸¸¸ÃÃÃÀÀÀ»»»µµµ°°°¬¬¬­­­¬¬¬¨¨¨¢¢¢¦¦¦±±±¸¸¸»»»¿¿¿ºººººº¾¾¾»»»³³³µµµ¾¾¾ÆÆÆÐÐÐÔÔÔÑÑÑÒÒÒÕÕÕÎÎÎÂÂÂÍÍÍÍÍÍÉÉÉÌÌÌÌÌÌÆÆƺººÊÊÊ×××ßßßÛÛÛØØØÛÛÛÕÕÕÌÌÌÅÅŵµµ´´´ÊÊÊÜÜÜÝÝÝÛÛÛÜÜÜâââæææèèèçççäääæææïïïøøøóóóïïïëëëèèèëëëîîîñññòòòßßßÙÙÙ××××××ÕÕÕÔÔÔØØØÝÝÝãããßßßÙÙÙÛÛÛàààæææèèèèèèëëëîîîàààÛÛÛßßß···ººº¿¿¿¾¾¾¿¿¿¾¾¾ºººººº¾¾¾¾¾¾»»»¼¼¼¾¾¾±±±¸¸¸µµµ°°°ÉÉÉÔÔÔÌÌÌÐÐÐÔÔÔÕÕÕÔÔÔÒÒÒÒÒÒÒÒÒÑÑÑÌÌÌÉÉÉ¿¿¿ÆÆƵµµ¸¸¸¾¾¾ººº¼¼¼¾¾¾¾¾¾¾¾¾¾¾¾¿¿¿ÀÀÀÇÇÇ×××ÑÑÑÍÍÍÎÎÎÍÍÍÑÑÑÐÐÐÎÎÎÐÐÐÕÕÕÕÕÕÑÑÑÒÒÒÙÙÙÛÛÛßßßßßßâââââââââàààßßßßßßãããââââââææææææããããããæææäääçççèèèçççæææçççëëëïïïëëëêêêêêêèèèäääàààâââæææëëëëëëêêêßßß¼¼¼µµµººº»»»ººº»»»´´´»»»ÀÀÀºººµµµßßßæææíííãããâââæææãããíííòòòæææïïïøøøùùùóóóîîîïïïòòòõõõóóóîîîæææÝÝÝÛÛÛßßßäääÜÜÜÝÝÝÍÍÍÉÉÉÑÑÑÑÑÑÍÍÍÇÇǸ¸¸ÅÅÅÊÊÊÑÑÑÉÉɼ¼¼ÃÃÃÅÅÅÔÔÔÔÔÔÕÕÕÕÕÕÔÔÔÔÔÔÉÉɵµµ´´´´´´ººº¼¼¼ºººÀÀÀÆÆƬ¬¬³³³¿¿¿ÆÆÆ¿¿¿³³³¯¯¯³³³³³³°°°ªªª¦¦¦ªªª´´´¸¸¸¸¸¸ÀÀÀ¼¼¼»»»¼¼¼ºººµµµ¼¼¼ÉÉÉÊÊÊÑÑÑÔÔÔÒÒÒÔÔÔÕÕÕÎÎÎÃÃÃÐÐÐÊÊÊÉÉÉÃÃÃÅÅÅÊÊÊÇÇÇÆÆÆÔÔÔÜÜÜÙÙÙÌÌÌÆÆÆÉÉÉÀÀÀ°°°³³³¨¨¨¦¦¦¸¸¸ÎÎÎÙÙÙÜÜÜÜÜÜÛÛÛÝÝÝâââããããããæææèèèèèèõõõïïïëëëëëëïïïññññññïïïãããÝÝÝÙÙÙÙÙÙØØØ××××××ØØØæææàààÛÛÛÛÛÛàààæææêêêêêêäääçççßßßÙÙÙÜÜÜ···¸¸¸ÀÀÀ¿¿¿ÀÀÀ¼¼¼¸¸¸¸¸¸¾¾¾¾¾¾»»»¼¼¼¾¾¾´´´¸¸¸···µµµÌÌÌØØØÐÐÐÒÒÒ×××ØØØ×××ÕÕÕÕÕÕÕÕÕÑÑÑÎÎÎÌÌ̾¾¾Â´´´···¼¼¼¼¼¼¾¾¾¾¾¾¼¼¼»»»¼¼¼¾¾¾ÀÀÀÀÀÀÔÔÔÔÔÔÊÊÊÉÉÉÊÊÊÊÊÊÊÊÊÉÉÉÍÍÍÑÑÑÒÒÒÑÑÑÔÔÔÛÛÛßßßßßßßßßààààààßßßßßßÝÝÝÜÜÜÜÜÜÙÙÙÜÜÜàààâââßßßßßßâââÜÜÜâââèèèííííííëëëëëëëëëãããæææêêêëëëèèèæææäääæææïïïëëëîîîÝÝݸ¸¸µµµÂººº¾¾¾ÃÃõµµµµµÝÝÝëëëñññäääãããèèèçççîîîòòòíííòòòõõõòòòíííêêêîîîóóóóóóóóóñññèèèàààÜÜÜßßßãããßßßÜÜÜÕÕÕÒÒÒÐÐÐÐÐÐÐÐÐÌÌÌ»»»¾¾¾ºººÃÃÃÉÉÉ¿¿¿³³³ÌÌÌÑÑÑÔÔÔÔÔÔÒÒÒÔÔÔÎÎÎÅÅŵµµµµµ¼¼¼¿¿¿»»»¿¿¿ÅÅÅ´´´°°°···ÂÂÂÀÀÀ´´´±±±ººº´´´°°°ªªª¬¬¬±±±¸¸¸»»»ººº°°°­­­­­­°°°¯¯¯°°°ºººÆÆÆÉÉÉÍÍÍÑÑÑÑÑÑÒÒÒÔÔÔÎÎÎÆÆÆØØØÎÎÎÎÎÎÃÃü¼¼¿¿¿¼¼¼ÇÇÇÜÜÜØØØÉÉÉ···±±±µµµ°°°¤¤¤­­­´´´³³³¯¯¯···ÌÌÌÙÙÙÛÛÛÝÝÝßßßÜÜÜÛÛÛÝÝÝãããäääãããëëëííííííîîîîîîîîîííííííëëëäääÛÛÛ×××ÔÔÔÒÒÒÑÑÑÑÑÑäääßßßÛÛÛÛÛÛàààæææççççççããããããæææàààÜÜܺºº¸¸¸¿¿¿ÅÅÅÃÃÿ¿¿»»»¼¼¼ÀÀÀÀÀÀ¼¼¼»»»¼¼¼¸¸¸ºººººº»»»ÍÍÍØØØÔÔÔ×××ÙÙÙÙÙÙØØØ××××××ØØØÔÔÔÑÑÑÍÍ;¾¾ÃÃõµµ¸¸¸¾¾¾¾¾¾¿¿¿¾¾¾¼¼¼»»»»»»¾¾¾ÀÀÀÆÆÆØØØÜÜÜÑÑÑÐÐÐÒÒÒÐÐÐÑÑÑÜÜÜßßßßßßÜÜÜÙÙÙØØØÛÛÛßßßßßßßßßßßßÝÝÝÜÜÜÛÛÛÛÛÛÙÙÙØØØ×××ØØØÜÜÜÝÝÝÛÛÛÛÛÛÝÝÝÙÙÙßßßæææëëëííííííëëëëëëäääçççêêêèèèçççæææææææææóóóëëëïïïâââÅÅž¾¾ÉÉÉÅÅÅÃÃÃÃÃþ¾¾ÂÂÂÆÆƵµµÀÀÀàààæææëëëÝÝÝÝÝÝãããâââçççêêêïïïïïïñññïïïîîîîîîïïïòòòïïïòòòòòòîîîæææßßßÜÜÜÜÜÜßßßÜÜÜßßßÛÛÛÑÑÑÎÎÎÐÐÐÑÑÑÍÍÍÆÆÆ···¼¼¼ÇÇÇÇÇÇÆÆƸ¸¸ºººÆÆÆÑÑÑÔÔÔÕÕÕÔÔÔÐÐÐÎÎα±±³³³¼¼¼ÃÃÿ¿¿¾¾¾ÀÀÀ¾¾¾¿¿¿±±±­­­¸¸¸¿¿¿ººº¸¸¸¿¿¿¿¿¿¸¸¸±±±°°°°°°°°°­­­ªªª¯¯¯¯¯¯°°°³³³´´´µµµ¾¾¾ÆÆÆÃÃÃÇÇÇÊÊÊÍÍÍÐÐÐÑÑÑÎÎÎÉÉÉÀÀÀ»»»ÉÉÉÊÊÊÅÅÅÀÀÀ¿¿¿ÑÑÑÔÔÔÉÉÉ»»»µµµµµµ···¸¸¸¸¸¸µµµÀÀÀÀÀÀ±±±­­­»»»ÇÇÇÊÊÊÍÍÍÙÙÙââââââßßßãããçççèèèèèèíííîîîëëëçççæææêêêîîîïïïëëëäääßßßÝÝÝÜÜÜØØØÕÕÕàààÜÜÜÛÛÛÜÜÜàààäääãããâââãããÒÒÒÔÔÔÎÎÎÉÉÉ···ÃÃÃÊÊÊÉÉÉÇÇÇÃÃÿ¿¿ÂÂÂÆÆÆÃÃÿ¿¿¼¼¼¼¼¼»»»»»»¼¼¼ÂÂÂÎÎÎ××××××ÙÙÙÛÛÛÛÛÛÙÙÙØØØÙÙÙÙÙÙÙÙÙÒÒÒÎÎÎÂÂÂÇÇǸ¸¸»»»Â¿¿¿¿¿¿¿¿¿¾¾¾¼¼¼¼¼¼¿¿¿Â»»»ÉÉÉÒÒÒÐÐÐÕÕÕÝÝÝÛÛÛàààßßßâââßßßÜÜÜÝÝÝÛÛÛÙÙÙÝÝÝßßßÝÝÝÝÝÝÜÜÜÙÙÙØØØØØØ×××ÙÙÙØØØÙÙÙÝÝÝßßßÜÜÜÜÜÜßßßßßßàààãããæææçççêêêíííîîîîîîîîîêêêääääääçççèèèçççõõõëëëñññçççÕÕÕÅÅÅÊÊÊÆÆÆÀÀÀ¿¿¿ÀÀÀÃÃÃÅÅŸ¸¸ÑÑÑäääâââèèèÜÜÜÝÝÝãããàààäääçççääääääçççêêêíííëëëèèèæææíííïïïòòòòòòíííäääÜÜÜØØØÜÜÜÛÛÛãããßßß×××ÑÑÑÎÎÎÔÔÔÔÔÔÑÑÑÀÀÀ¼¼¼¾¾¾ÀÀÀÉÉÉÅÅÅ­­­¼¼¼ÊÊÊÒÒÒØØØÕÕÕÎÎÎÎÎΰ°°¯¯¯ºººÃÃÃÀÀÀÀÀÀ¾¾¾ÅÅÅ´´´ªªª¯¯¯»»»¿¿¿¿¿¿¿¿¿»»»···´´´¸¸¸»»»»»»ººº»»»¿¿¿¿¿¿ÀÀÀÂÂÂÃÃÃÅÅÅÇÇÇÊÊÊÂÂÂÃÃÃÆÆÆÊÊÊÍÍÍÐÐÐÎÎÎÊÊÊ¿¿¿¾¾¾ÆÆÆÉÉÉÃÃþ¾¾¿¿¿ÍÍÍÀÀÀººº···¼¼¼¿¿¿¼¼¼¾¾¾ÃÃÃÀÀÀÀÀÀÀÀÀ¼¼¼µµµ³³³³³³´´´±±±ÀÀÀÎÎÎ×××ÝÝÝäääâââÛÛÛÜÜÜäääíííîîîêêêääääääæææêêêíííïïïîîîîîîëëëæææßßßÝÝÝÜÜÜÛÛÛÜÜÜàààãããâââßßßààà»»»ºººººº»»»ºººÐÐÐÐÐÐÌÌÌÊÊÊÇÇÇÃÃÃÆÆÆÉÉÉÆÆÆ¿¿¿¿¿¿¾¾¾»»»ººº¾¾¾ÇÇÇÐÐÐ×××ÙÙÙÛÛÛÜÜÜÜÜÜÛÛÛÙÙÙÙÙÙÛÛÛÜÜÜÐÐÐÉÉÉÂÂÂÊÊʸ¸¸ºººÃÃþ¾¾¿¿¿ÀÀÀ¿¿¿¾¾¾¿¿¿ÀÀÀÃÃÃÆÆÆÇÇÇÌÌÌÅÅÅÇÇÇÇÇǺºº¿¿¿¾¾¾ÃÃÃÃÃÃÇÇÇÔÔÔØØØÙÙÙàààßßßÝÝÝÜÜÜÙÙÙØØØ×××ÕÕÕÕÕÕÛÛÛÙÙÙÛÛÛàààâââßßßàààãããäääääääääæææçççèèèêêêêêêäääæææäääæææíííõõõöööóóóòòòêêêòòòëëëàààÃÃÃÂÂÂÅÅÅÀÀÀ¼¼¼ÅÅÅÅÅÅ¿¿¿¸¸¸ÛÛÛàààèèèñññçççèèèîîîêêêîîîñññâââãããæææèèèèèèèèèæææäääëëëîîîòòòóóóòòòëëëâââÙÙÙÛÛÛ×××ÝÝÝÜÜÜÜÜÜØØØÊÊÊÑÑÑÐÐÐÔÔÔÉÉɾ¾¾······ÆÆÆÇÇÇ···¼¼¼¾¾¾ÆÆÆÔÔÔÕÕÕÍÍÍÍÍ͸¸¸³³³¸¸¸ÀÀÀ¿¿¿¿¿¿ÀÀÀ¿¿¿¿¿¿¸¸¸°°°­­­···ÃÃÃÃÃü¼¼ÅÅÅÀÀÀÀÀÀÃÃÃÃÃÃÀÀÀ¿¿¿ÀÀÀ¾¾¾¼¼¼¼¼¼¾¾¾ÀÀÀÂÂÂÃÃÃÂÂÂÃÃÃÃÃÃÅÅÅÉÉÉÍÍÍÎÎÎÍÍÍÌÌÌ¿¿¿ÃÃÃÀÀÀÀÀÀÂÂÂÇÇÇÌÌÌÆÆƳ³³µµµ»»»ÀÀÀ¿¿¿¼¼¼¼¼¼¾¾¾Â¿¿¿¿¿¿ÀÀÀ¾¾¾µµµ°°°­­­°°°³³³±±±µµµÃÃÃÒÒÒÑÑÑÆÆÆÃÃÃÍÍÍÛÛÛæææëëëêêêãããßßßÝÝÝæææëëëëëëêêêèèèãããÝÝÝàààÝÝÝÛÛÛÜÜÜàààããããããàààâââ³³³¸¸¸ÀÀÀÃÃÃÅÅÅÑÑÑÂÂÂÌÌÌÌÌÌÉÉÉÆÆÆÇÇÇÌÌÌÆÆÆ¿¿¿ÃÃþ¾¾»»»¸¸¸¾¾¾ÉÉÉÐÐÐ×××ÛÛÛÜÜÜÝÝÝÜÜÜÛÛÛÙÙÙÙÙÙÛÛÛÙÙÙÊÊÊÃÃþ¾¾ÇÇÇ´´´µµµÀÀÀ¾¾¾¿¿¿ÀÀÀÀÀÀ¿¿¿ÀÀÀÂÂÂÃÃÃÆÆÆÃÃÃÇÇÇÅÅÅÍÍÍÐÐÐÂÂÂÉÉÉÃÃÃÇÇÇÃÃÃÇÇÇÔÔÔÙÙÙ×××ÜÜÜßßßÝÝÝÛÛÛÙÙÙ×××ÕÕÕÕÕÕÔÔÔÙÙÙØØØÙÙÙàààâââàààâââææææææçççêêêëëëëëëêêêæææãããâââæææêêêîîîöööüüüöööíííïïïêêêòòòíííäää¿¿¿»»»ÃÃÃÃÃÿ¿¿ÉÉÉÆÆƺºº´´´ÜÜÜØØØßßßèèèâââãããçççãããçççêêêîîîññññññïïïííííííñññõõõêêêíííñññõõõöööñññæææßßßÛÛÛÔÔÔØØØØØØàààÜÜÜÇÇÇÌÌÌÑÑÑØØØÎÎÎÃÃúºº¸¸¸ÆÆÆÇÇÇÉÉÉ´´´¸¸¸ÌÌÌÔÔÔÎÎÎÎÎÎÅÅźººººº¿¿¿¼¼¼¼¼¼¿¿¿¾¾¾¸¸¸»»»···°°°µµµÅÅÅÅÅźºº¿¿¿¾¾¾¿¿¿ÃÃÃÃÃÃÀÀÀ¿¿¿ÃÃúºº¸¸¸¸¸¸»»»¿¿¿ÃÃÃÃÃÃÂÂÂÆÆÆÅÅÅÆÆÆÊÊÊÍÍÍÍÍÍÌÌÌÊÊÊÃÃÃÑÑÑÇÇÇÅÅÅÉÉÉÍÍÍÇÇÇ©©©­­­ºººÂÂÂÀÀÀ¿¿¿ÀÀÀÂÂÂÀÀÀ¿¿¿ÃÃÃÃÃÿ¿¿¼¼¼¼¼¼ºººµµµ­­­´´´µµµ³³³µµµ¿¿¿¾¾¾´´´µµµ¸¸¸ÂÂÂÑÑÑâââêêêèèèããããããêêêîîîêêêççççççæææâââäääàààÜÜÜÜÜÜàààääääääãããÔÔÔÅÅźºº¼¼¼ÅÅÅÉÉÉÉÉÉÉÉÉÍÍÍÊÊÊÇÇÇÇÇÇÉÉÉÉÉÉÇÇÇÆÆÆÃÃÃÆÆÆÀÀÀÃÃÃÀÀÀ¾¾¾ÐÐÐÙÙÙàààÝÝÝØØØÑÑÑÐÐÐÔÔÔÙÙÙÜÜÜÕÕÕÐÐп¿¿¿¿¿ÊÊÊ»»»¯¯¯¾¾¾»»»ÀÀÀ¾¾¾¾¾¾ÃÃÃÇÇÇÆÆÆÊÊÊÉÉÉÉÉÉÊÊÊÍÍÍÍÍÍÌÌÌÉÉÉÇÇÇÇÇÇÇÇÇÂÂÂÙÙÙØØØÙÙÙØØØÝÝÝàààßßßØØØÔÔÔÕÕÕ×××ÔÔÔÛÛÛÜÜÜÜÜÜÝÝÝàààäääçççèèèëëëèèèâââäääîîîèèèãããêêêñññõõõöööõõõõõõøøøøøøóóóøøøúúúøøøàà྾¾ÅÅÅ¿¿¿Â¿¿¿ÅÅÅÊÊʼ¼¼­­­···ÎÎÎÙÙÙçççÛÛÛÙÙÙÍÍÍÀÀÀØØØÛÛÛèèèççççççèèèææææææëëëóóóñññíííñññïïïêêêñññòòòæææÜÜÜØØØ×××ÕÕÕÛÛÛßßßÕÕÕÌÌÌÌÌÌÕÕÕÑÑÑÐÐп¿¿ÍÍÍÐÐÐÉÉÉÊÊÊÂÂÂÂÂÂÌÌÌÒÒÒÐÐÐÎÎÎÐÐÐÌÌÌÑÑÑÊÊÊ»»»µµµ¼¼¼Â¿¿¿¼¼¼ÃÃúºº¯¯¯ºººÆÆÆÃÃÿ¿¿ÀÀÀÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÀÀÀÀÀÀ¾¾¾¸¸¸···¼¼¼¿¿¿¾¾¾¾¾¾ÀÀÀÃÃÃÃÃÃÆÆÆÉÉÉÆÆÆÃÃÃÉÉÉÔÔÔÐÐÐÊÊÊÉÉÉÔÔÔÎÎÎÐÐкºº´´´···¸¸¸¾¾¾ÆÆÆÉÉÉÆÆÆÅÅÅÆÆÆÇÇÇÆÆÆÃÃÃÂÂÂÀÀÀ¿¿¿¿¿¿¾¾¾¼¼¼»»»»»»¾¾¾ÂÂÂÃÃÃÃÃÃÂÂÂÀÀÀºººµµµ»»»ÉÉÉÛÛÛæææëëëæææãããäääïïïëëëçççíííàààÛÛÛßßßàààÔÔÔßßßÛÛÛàààãããÃÃÿ¿¿ÀÀÀÇÇÇÊÊÊÉÉÉÇÇÇÉÉÉÐÐÐÍÍÍÌÌÌÌÌÌÍÍÍÍÍÍÌÌÌÉÉÉÇÇÇÉÉÉÀÀÀÃÃÃÀÀÀ¿¿¿ÑÑÑÜÜÜâââßßßØØØÒÒÒÐÐÐÑÑÑÕÕÕ×××ÙÙÙÕÕÕÆÆÆÀÀÀÃÃû»»´´´¼¼¼ººº¿¿¿ÀÀÀ¾¾¾¼¼¼ÀÀÀÂÂÂÂÂÂÊÊÊÊÊÊÊÊÊÊÊÊÌÌÌÌÌÌÊÊÊÉÉÉÉÉÉÅÅÅÇÇÇÇÇÇÛÛÛÒÒÒ×××ÜÜÜÛÛÛÝÝÝÝÝÝÙÙÙ×××ØØØÙÙÙØØØØØØØØØÛÛÛßßßæææèèèèèèæææäääíííîîîîîîïïïíííîîîúúúäääëëëïïïïïïïïïñññïïïëëëêêêïïïíííÛÛÛÇÇÇÅÅÅÇÇÇÃÃþ¾¾»»»ÀÀÀÇÇÇÀÀÀ³³³´´´¿¿¿···Â¸¸¸¾¾¾»»»³³³ÀÀÀ»»»ÙÙÙÜÜÜàààãããàààÝÝÝäääîîîõõõõõõöööóóóïïïòòòòòòëëëçççäääÝÝÝ××××××ÛÛÛ×××ÑÑÑÍÍÍÒÒÒÑÑÑÑÑÑ»»»ÂÂÂÆÆÆÊÊÊÍÍ;¾¾ºººÌÌÌ×××ÑÑÑÍÍÍÑÑÑÎÎÎÒÒÒÐÐÐÀÀÀ´´´´´´»»»¿¿¿¿¿¿Â¸¸¸³³³¾¾¾ÆÆÆÃÃÃÂÂÂÀÀÀÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÀÀÀÀÀÀ¾¾¾ººº¸¸¸¼¼¼¾¾¾¾¾¾ÀÀÀÅÅÅ»»»»»»¼¼¼¿¿¿¾¾¾¿¿¿ÅÅÅÌÌÌÐÐÐÆÆÆÊÊÊÒÒÒÐÐÐÑÑѱ±±­­­»»»ººº¾¾¾ÅÅÅÇÇÇÅÅÅÅÅÅÇÇÇÀÀÀÃÃÃÇÇÇÇÇÇÃÃü¼¼»»»¾¾¾¾¾¾ÃÃÃÇÇÇÊÊÊÉÉÉÆÆÆÅÅÅÅÅÅÀÀÀ¾¾¾ººº¸¸¸»»»ÆÆÆÒÒÒÜÜÜäääçççæææîîîîîîëëëíííßßßßßßÜÜÜßßßÝÝÝòòòèèèâââÛÛÛ···¾¾¾ÇÇÇÎÎÎÎÎÎÊÊÊÌÌÌÐÐÐÒÒÒÑÑÑÐÐÐÑÑÑÑÑÑÑÑÑÐÐÐÎÎÎÌÌÌÌÌÌÂÂÂÃÃÃÀÀÀ¿¿¿ÑÑÑÜÜÜâââÝÝÝØØØÕÕÕÒÒÒÐÐÐÐÐÐÑÑÑÙÙÙÙÙÙÑÑÑÆÆÆ¿¿¿¾¾¾ººº´´´¾¾¾¿¿¿¾¾¾¸¸¸¸¸¸¾¾¾ÃÃÃÆÆÆÉÉÉÊÊÊÌÌÌÍÍÍÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÃÃÃÇÇÇÌÌÌÜÜÜÐÐÐÕÕÕÜÜÜÙÙÙÜÜÜÝÝÝÙÙÙØØØÙÙÙÛÛÛÛÛÛ×××ØØØÜÜÜâââäääèèèëëëïïïòòòöööóóóõõõüüüüüüõõõòòòêêêïïïïïïëëëæææææææææãããêêêêêêÜÜÜÇÇÇ¿¿¿ÃÃÃÆÆÆÉÉÉÇÇÇÅÅÅÅÅÅÇÇÇÆÆÆÀÀÀ¼¼¼¾¾¾µµµ¼¼¼´´´ÀÀÀÆÆÆ¿¿¿Â´´´···¼¼¼ÉÉÉ×××ÝÝÝàààæææíííëëëòòòóóóïïïïïïïïïïïïòòòèèèæææÝÝÝ××××××ÜÜÜâââàààÎÎÎÑÑÑÒÒÒÔÔÔ»»»¿¿¿ÃÃÃÎÎÎÍÍͺºº···ÍÍÍÛÛÛÔÔÔÎÎÎÒÒÒÍÍÍÒÒÒÑÑÑÃÃô´´°°°¸¸¸Â¿¿¿······ÂÂÂÆÆÆÃÃÃÃÃÃÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÀÀÀ¿¿¿»»»¸¸¸¸¸¸»»»¾¾¾ÀÀÀÆÆÆÍÍÍÑÑÑÑÑÑÍÍÍÆÆÆÃÃÃÆÆÆÇÇÇÆÆÆÇÇÇÀÀÀÌÌÌÒÒÒÒÒÒÒÒÒ±±±±±±¾¾¾»»»¾¾¾ÂÂÂÅÅÅÅÅÅÆÆÆÊÊÊÌÌÌÇÇÇÇÇÇÌÌÌÊÊÊÃÃÃÀÀÀÃÃÿ¿¿ÂÂÂÅÅÅÆÆÆÇÇÇÆÆÆÃÃÃÂÂÂÉÉÉÉÉÉÇÇÇÃÃþ¾¾ººº¸¸¸¸¸¸ØØØçççããããããæææãããäääÝÝÝòòòèèèæææâââëëëÑÑÑÀÀÀ···¾¾¾ÃÃÃÊÊÊÎÎÎÎÎÎÎÎÎÒÒÒ×××ÔÔÔÔÔÔÔÔÔÔÔÔÔÔÔÔÔÔÒÒÒÒÒÒÌÌÌÌÌÌÃÃÃÅÅÅ¿¿¿ÎÎÎ×××ÝÝÝØØØÕÕÕÕÕÕÔÔÔÐÐÐÎÎÎÎÎÎÑÑÑ×××ÙÙÙÌÌ̾¾¾ÀÀÀ¾¾¾¯¯¯···ºººººººººººº¾¾¾ÃÃÃÇÇÇÇÇÇÊÊÊÎÎÎÐÐÐÎÎÎÎÎÎÐÐÐÒÒÒÑÑÑÇÇÇÊÊÊÊÊÊÙÙÙÒÒÒ×××ÕÕÕÛÛÛÜÜÜÜÜÜÙÙÙØØØØØØÙÙÙÛÛÛÙÙÙÜÜÜàààããããããæææòòòÿÿÿúúúÿÿÿüüüööööööùùùøøøóóóóóóñññæææÔÔÔÆÆÆÂÂÂÀÀÀ¿¿¿ÜÜÜÜÜÜÉÉɸ¸¸¾¾¾ÅÅÅÉÉÉÐÐÐÑÑÑÎÎÎÉÉÉÆÆÆÆÆÆÆÆÆÆÆÆÃÃÃÅÅÅÇÇÇ¿¿¿ÉÉÉÐÐÐÉÉÉÇÇǺºº···´´´µµµÀÀÀÍÍÍÕÕÕÝÝÝãããîîîùùùøøøññññññëëëèèèñññòòòïïïàààØØØ×××ØØØÜÜÜÕÕÕÍÍÍÑÑÑ×××ÕÕÕÀÀÀÌÌÌÊÊÊÑÑÑÅÅż¼¼¿¿¿ÐÐÐÛÛÛ×××ÑÑÑÒÒÒÊÊÊÑÑÑÍÍͼ¼¼±±±µµµ¿¿¿ÅÅźºº´´´ºººÂÂÂÃÃÃÂÂÂÃÃÃÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÀÀÀ¿¿¿¿¿¿µµµµµµ···ººº¼¼¼ÃÃÃÍÍÍÔÔÔÍÍÍÍÍÍÉÉÉÂÂÂÃÃÃÉÉÉÊÊÊÆÆÆÆÆÆÊÊÊÑÑÑØØØÕÕÕÆÆÆ´´´···¿¿¿»»»»»»ÀÀÀÃÃÃÅÅÅÉÉÉÎÎÎÆÆƸ¸¸°°°ºººÅÅÅÇÇÇÆÆÆÆÆÆÎÎÎÎÎÎÎÎÎÍÍÍÌÌÌÊÊÊÊÊÊÊÊÊÇÇÇÅÅÅÅÅÅÇÇÇÌÌÌÇÇÇ¿¿¿······àààïïïîîîêêêæææïïïöööîîîçççèèèâââßßß¾¾¾···¿¿¿ÉÉÉÊÊÊÌÌÌÎÎÎÑÑÑÕÕÕ×××ØØØÔÔÔÔÔÔÕÕÕÕÕÕÕÕÕÔÔÔÕÕÕÕÕÕÉÉÉÊÊÊÃÃÃÆÆÆÃÃÿ¿¿ÊÊÊÎÎÎÕÕÕÑÑÑÐÐÐÕÕÕ×××ÒÒÒÎÎÎÐÐÐÎÎÎÒÒÒÙÙÙÍÍÍ»»»¿¿¿Â³³³©©©­­­´´´ººº¼¼¼¼¼¼¾¾¾¿¿¿ÅÅÅÉÉÉÍÍÍÎÎÎÐÐÐÑÑÑÔÔÔ×××ÕÕÕÍÍÍÎÎÎÆÆÆÕÕÕØØØÛÛÛÎÎÎØØØØØØÙÙÙÙÙÙØØØØØØÛÛÛÝÝÝâââÝÝÝàààçççëëëïïïøøøÿÿÿüüüúúúõõõïïïòòòøøøöööíííçççæææÜÜÜÎÎÎÆÆÆÅÅÅÆÆÆÆÆÆÀÀÀÅÅż¼¼ºººÇÇÇÐÐÐÐÐÐÔÔÔÐÐÐÐÐÐÍÍÍÇÇÇÅÅÅÆÆÆÆÆÆÆÆÆÊÊÊÌÌÌÅÅÅÉÉÉÉÉÉÆÆÆÆÆÆÀÀÀÃÃû»»´´´±±±´´´¿¿¿ÑÑÑâââæææïïïïïïíííïïïêêêçççïïïóóóñññÝÝÝÙÙÙÛÛÛØØØØØØÉÉÉÍÍÍÒÒÒØØØÑÑÑÂÂÂ×××ÎÎÎÉÉɾ¾¾ÆÆÆÎÎÎÕÕÕÙÙÙÙÙÙÕÕÕÑÑÑÎÎÎÑÑÑÆÆƳ³³°°°¾¾¾ÅÅÅ¿¿¿Â´´´°°°ºººÀÀÀÂÂÂÀÀÀÀÀÀÀÀÀÂÂÂÂÂÂÀÀÀÀÀÀ¿¿¿¾¾¾¼¼¼···¸¸¸ºººººº»»»ÂÂÂÊÊÊÐÐÐÉÉÉÊÊÊÅÅÅ¿¿¿ÀÀÀÇÇÇÇÇÇÂÂÂÎÎÎâââÛÛÛâââÕÕÕ°°°³³³µµµ¼¼¼ºººººº¿¿¿ÂÂÂÅÅÅÊÊÊÑÑÑÀÀÀµµµ°°°»»»ÌÌÌÔÔÔÕÕÕÕÕÕÎÎÎÑÑÑÑÑÑÐÐÐÍÍÍÌÌÌÍÍÍÎÎÎÐÐÐÊÊÊÅÅÅÅÅÅÊÊÊÍÍÍÊÊÊÇÇǺººØØØßßßãããêêêçççæææàààçççãããçççßßß×××´´´µµµÆÆÆÍÍÍÎÎÎÐÐÐÑÑÑÕÕÕÙÙÙØØØÔÔÔÔÔÔÕÕÕÕÕÕÔÔÔÔÔÔÔÔÔ×××ØØØÉÉÉÊÊÊÃÃÃÇÇÇÅÅÅ¿¿¿ÇÇÇÊÊÊÐÐÐÉÉÉÊÊÊÔÔÔØØØÔÔÔÐÐÐÒÒÒÐÐÐÒÒÒÕÕÕÌÌ̺ºººººÂ¿¿¿¬¬¬ªªª¬¬¬¯¯¯°°°³³³ºººÀÀÀ¿¿¿ÂÂÂÆÆÆÉÉÉÌÌÌÎÎÎÐÐÐÑÑÑÔÔÔÐÐÐÒÒÒÅÅÅÐÐÐ×××ßßßÐÐÐ××××××ØØØÛÛÛÛÛÛÛÛÛßßßãããäääÝÝÝßßßîîîúúúüüüöööõõõöööòòòòòòööööööñññàààÊÊÊÀÀÀÅÅÅÅÅÅÃÃÃÆÆÆÌÌÌÎÎÎÌÌÌÀÀÀ¾¾¾¾¾¾ÉÉÉÐÐÐÒÒÒÕÕÕÐÐÐÔÔÔ×××ÔÔÔÐÐÐÍÍÍÌÌÌÊÊÊÉÉÉÉÉÉÆÆÆÅÅÅÃÃÃÂÂÂÆÆÆÇÇÇ¿¿¿ÀÀÀ¾¾¾´´´³³³ÃÃÃÕÕÕâââæææèèèîîîòòòîîîëëëïïïíííîîîÛÛÛÜÜÜßßßÛÛÛÝÝÝÌÌÌÎÎÎÔÔÔÙÙÙÌÌ̼¼¼ØØØÉÉÉ¿¿¿ÂÂÂÑÑÑÜÜÜÙÙÙØØØÛÛÛÙÙÙÑÑÑÕÕÕÑÑÑÀÀÀ°°°³³³ÀÀÀÃÃû»»Â³³³¯¯¯···¾¾¾ÂÂÂÃÃÿ¿¿ÀÀÀÀÀÀÀÀÀ¿¿¿¿¿¿¼¼¼»»»»»»»»»¾¾¾¼¼¼ººº»»»¿¿¿ÂÂÂÂÂÂÕÕÕÒÒÒÎÎÎÉÉÉÉÉÉÊÊÊÇÇÇÃÃÃÍÍÍçççÛÛÛâââ×××¥¥¥µµµººº»»»¸¸¸ººº¿¿¿ÃÃÃÅÅÅÉÉÉÐÐШ¨¨ªªª°°°´´´¸¸¸¼¼¼¾¾¾¾¾¾ÀÀÀ»»»ºººÃÃÃÒÒÒÙÙÙÕÕÕÍÍÍÒÒÒÒÒÒÐÐÐÌÌÌÇÇÇÅÅÅÆÆÆÇÇÇ»»»¾¾¾³³³»»»ÑÑÑâââêêêãããäääàààæææààààààÂÂÂÀÀÀÍÍÍÍÍÍÑÑÑÒÒÒÑÑÑÒÒÒØØØØØØÕÕÕ×××××××××ÕÕÕÔÔÔÕÕÕÙÙÙÜÜÜÍÍÍÌÌÌÅÅÅÇÇÇÆÆÆ¿¿¿ÇÇÇÊÊÊÌÌÌÅÅÅÆÆÆÑÑÑØØØÔÔÔÑÑÑÔÔÔÑÑÑÑÑÑ×××ÒÒÒÃÃø¸¸¼¼¼ÅÅÅ»»»µµµ°°°¯¯¯­­­¯¯¯···ÀÀÀºººººº¼¼¼¿¿¿ÃÃÃÅÅÅÅÅÅÅÅÅÐÐÐÍÍÍÕÕÕÉÉÉÌÌÌÐÐÐâââÝÝÝßßßÜÜÜÝÝÝàààßßßÜÜÜÝÝÝãããâââÝÝÝäääóóóÿÿÿøøøòòòóóóïïïóóóÿÿÿüüüäääÑÑÑÉÉÉÂÂÂÎÎÎÐÐÐÐÐÐÎÎÎÑÑÑÕÕÕÒÒÒÌÌÌÔÔÔÍÍÍÉÉÉÆÆÆÅÅÅÊÊÊÒÒÒÔÔÔÙÙÙØØØÙÙÙÛÛÛÛÛÛ×××ÒÒÒÒÒÒÇÇÇÆÆÆÆÆÆÃÃÃÂÂÂÃÃÃÅÅÅÇÇÇÅÅÅÊÊÊÎÎÎÎÎεµµ´´´»»»äääàààæææñññóóóñññíííçççòòòøøøäääâââÝÝÝÕÕÕßßßÑÑÑÒÒÒÒÒÒÛÛÛÌÌÌ»»»ÔÔÔÇÇÇÆÆÆÒÒÒÛÛÛßßßÜÜÜÛÛÛÜÜÜÙÙÙÔÔÔÕÕÕÉÉÉ»»»···ººº¾¾¾¿¿¿¿¿¿ÃÃô´´°°°µµµ¼¼¼ÅÅÅÇÇÇ¿¿¿¿¿¿¿¿¿¿¿¿¾¾¾¼¼¼»»»ººº¸¸¸ººº¼¼¼¼¼¼»»»»»»¿¿¿¾¾¾¸¸¸ÍÍÍÊÊÊÉÉÉÌÌÌÌÌÌÉÉÉÉÉÉÉÉÉÅÅÅÜÜÜÒÒÒÙÙÙ××צ¦¦···¾¾¾»»»¸¸¸»»»ÀÀÀÃÃÃÃÃÃÅÅÅÉÉɬ¬¬···¿¿¿¼¼¼¾¾¾ÂÂÂÅÅÅÃÃÃÃÃúºº³³³¼¼¼ÐÐÐÜÜÜÜÜÜÕÕÕÎÎÎÐÐÐÑÑÑÑÑÑÍÍÍÊÊÊÉÉÉÉÉÉÆÆÆÇÇǾ¾¾¼¼¼ºººÂÂÂÛÛÛâââêêêääääääÜÜÜßßßÆÆÆÃÃÃÊÊÊÍÍÍÒÒÒÔÔÔÎÎÎÌÌÌÒÒÒÙÙÙÛÛÛÙÙÙÙÙÙØØØÕÕÕÔÔÔÕÕÕÛÛÛßßßÑÑÑÎÎÎÆÆÆÇÇÇÆÆÆÀÀÀÉÉÉÌÌÌÌÌÌÃÃÃÅÅÅÑÑÑØØØÔÔÔÑÑÑÔÔÔÍÍÍÑÑÑÙÙÙÝÝÝÐÐкºº···ÃÃþ¾¾¼¼¼¾¾¾ÀÀÀ¼¼¼´´´³³³µµµµµµ´´´´´´···»»»¼¼¼»»»ºººÊÊÊÉÉÉ×××ÎÎÎÊÊÊÉÉÉâââëëëèèèæææääääääàààÛÛÛÛÛÛßßßÝÝÝàààíííöööóóóëëëïïïúúúÿÿÿóóóïïïäääÍÍÍÂÂÂÌÌÌÒÒÒÔÔÔÑÑÑÎÎÎÌÌÌÑÑÑØØØ×××ÑÑÑÔÔÔÎÎÎÒÒÒÔÔÔÌÌÌÎÎÎÔÔÔÑÑÑßßßÕÕÕÐÐÐÔÔÔ×××ÕÕÕÔÔÔÔÔÔÕÕÕÒÒÒÒÒÒÐÐÐÐÐÐÑÑÑÌÌÌÌÌÌÊÊÊÅÅÅÃÃÃÇÇÇÊÊÊÆÆÆÀÀÀ¿¿¿ººº³³³ÀÀÀØØØäääëëëíííæææëëëöööæææãããÜÜÜ×××êêêæææÔÔÔÑÑÑÜÜÜÐÐм¼¼ÔÔÔÌÌÌ×××âââßßßÜÜÜÝÝÝÝÝÝÜÜÜÙÙÙ×××ÑÑÑ¿¿¿···¾¾¾ÀÀÀ»»»¾¾¾ÇÇÇÅÅŵµµ±±±µµµ»»»ÆÆÆÊÊÊÀÀÀ¾¾¾¾¾¾¾¾¾¾¾¾¼¼¼ººº¸¸¸···´´´¸¸¸ºººººº¾¾¾Â¾¾¾···ÔÔÔÎÎÎÍÍÍÐÐÐÌÌÌÃÃÃÀÀÀÃÃÃÅÅÅÕÕÕÎÎÎÒÒÒÕÕÕ¨¨¨¯¯¯µµµ»»»ººº¼¼¼ÂÂÂÃÃÃÂÂÂÂÂÂÅÅű±±¼¼¼ÂÂÂÂÂÂÌÌÌÜÜÜãããÝÝÝÆÆÆÃÃþ¾¾···³³³ºººÉÉÉÕÕÕäääÛÛÛÑÑÑÌÌÌÌÌÌÌÌÌÉÉÉÆÆÆÌÌÌÆÆÆÃÃÃÇÇǾ¾¾¸¸¸ÀÀÀ···ººº¸¸¸¾¾¾»»»ÆÆÆ»»»ÃÃÃÑÑÑÒÒÒ×××ÒÒÒÒÒÒÛÛÛÙÙÙÕÕÕÙÙÙØØØßßßÒÒÒÑÑÑ××××××ÛÛÛÙÙÙÒÒÒÐÐÐÇÇÇÅÅÅÇÇÇÃÃÃÂÂÂÌÌÌÍÍÍÀÀÀÃÃÃÑÑÑÔÔÔÒÒÒÒÒÒÒÒÒÎÎÎÐÐÐÙÙÙÜÜÜÐÐÐÅÅž¾¾±±±ÅÅÅÃÃÃÂÂÂÂÂÂÀÀÀ¼¼¼´´´¯¯¯°°°³³³ÅÅÅÑÑÑÅÅźºº¸¸¸µµµÀÀÀÇÇÇÊÊÊÉÉÉÇÇÇÊÊÊÊÊÊÇÇÇÌÌÌÍÍÍèèèÜÜÜããããããÜÜÜÝÝÝÜÜÜàààíííïïïîîîöööÿÿÿöööüüüãããÉÉÉÊÊÊÔÔÔÑÑÑÒÒÒÔÔÔÑÑÑÔÔÔÎÎÎÕÕÕÙÙÙÔÔÔ×××ÔÔÔÍÍÍÐÐÐÑÑÑÐÐÐÍÍÍÍÍÍÒÒÒØØØÛÛÛØØØ××××××ÔÔÔÑÑÑ×××àààßßßÜÜÜ×××ÑÑÑÎÎÎÍÍÍÐÐÐÒÒÒÑÑÑÕÕÕÉÉÉÎÎÎÔÔÔÑÑÑÐÐл»»¿¿¿ºººÆÆÆ¿¿¿¿¿¿ÜÜÜîîîöööïïïñññóóóëëëÜÜÜàààæææßßß×××ÎÎÎÔÔÔÑÑÑÆÆÆÐÐÐÑÑÑ¿¿¿ãããàààßßßààààààßßßÛÛÛØØØÇÇÇ¿¿¿ºººººº»»»»»»¾¾¾ÂÂÂÂÂÂÃÃꪪªªª¾¾¾¿¿¿ÀÀÀÅÅÅ¿¿¿¾¾¾¼¼¼»»»ººº¸¸¸¸¸¸¸¸¸ºººººº¾¾¾ÃÃõµµ»»»···ÊÊÊÃÃÃÌÌÌÐÐÐÌÌÌÇÇÇÆÆÆÅÅÅÂÂÂÂÂÂÇÇÇÐÐÐÍÍÍÑÑÑÉÉɱ±±¯¯¯¼¼¼······ÅÅž¾¾¼¼¼ÌÌ̼¼¼±±±´´´¾¾¾ÎÎÎÑÑÑâââÙÙÙâââÝÝÝÍÍÍÆÆƸ¸¸···»»»ºººÙÙÙØØØÔÔÔÍÍÍÍÍÍÎÎÎÊÊÊÃÃÃÌÌÌÌÌÌÌÌÌÊÊÊÇÇÇÃÃÿ¿¿¼¼¼ººº»»»¼¼¼¾¾¾ÀÀÀÅÅÅÊÊÊÐÐÐÕÕÕØØØÔÔÔÔÔÔÛÛÛÛÛÛÙÙÙßßßÝÝÝëëëâââÜÜÜßßßÝÝÝÙÙÙÍÍÍÒÒÒÐÐÐÇÇÇÃÃÃÆÆÆÂÂÂÂÂÂÌÌÌÍÍÍÂÂÂÆÆÆÔÔÔÔÔÔÑÑÑÒÒÒÑÑÑÌÌÌÉÉÉÑÑÑØØØÔÔÔÑÑÑÉÉÉ»»»¼¼¼»»»»»»¾¾¾ÀÀÀÃÃÃÂÂÂÀÀÀÇÇÇÅÅÅÊÊÊÐÐÐÇÇÇÂÂÂÀÀÀºººÅÅÅÊÊÊÌÌÌÉÉÉÇÇÇÊÊÊÌÌÌÊÊÊÌÌÌÎÎÎëëëßßßæææäääÜÜÜÝÝÝãããæææîîîñññíííòòòöööñññÜÜÜÔÔÔÉÉÉÉÉÉÐÐÐÔÔÔ×××ÕÕÕÑÑÑÙÙÙÔÔÔ×××ØØØÛÛÛÝÝÝÔÔÔÕÕÕÔÔÔÑÑÑÐÐÐÑÑÑÕÕÕÛÛÛÝÝÝõõõæææØØØ××××××ÐÐÐÆÆÆ¿¿¿¿¿¿¿¿¿¾¾¾ººººººÃÃÃÕÕÕäääÒÒÒÝÝÝ×××ÔÔÔÌÌÌÇÇÇÐÐÐÍÍÍÆÆÆÅÅÅÉÉɾ¾¾¼¼¼ÊÊÊ×××íííóóóïïïùùùùùùæææÝÝÝßßßØØØçççØØØÙÙÙ×××ÊÊÊÒÒÒÜÜÜÒÒÒÛÛÛßßßßßßÛÛÛÙÙÙÜÜÜÜÜÜ××׿¿¿ººº¸¸¸»»»¼¼¼¼¼¼¿¿¿ÅÅÅÃÃÃÅÅÅ­­­¬¬¬¾¾¾¾¾¾¼¼¼¾¾¾ÂÂÂÀÀÀ¾¾¾»»»¸¸¸·········¸¸¸ººº¼¼¼ÀÀÀ···Â¼¼¼ÊÊÊÆÆÆÍÍÍÐÐÐÊÊÊÆÆÆÆÆÆÆÆÆÅÅÅÇÇÇÂÂÂÌÌÌÎÎÎÐÐÐÎÎμ¼¼´´´ººº¸¸¸ºººÂ¿¿¿ÅÅÅÌÌÌ´´´´´´´´´¸¸¸ÂÂÂÆÆÆÛÛÛÕÕÕÝÝÝâââÎÎÎÃÃÿ¿¿¿¿¿ÀÀÀ¼¼¼ÇÇÇÑÑÑÕÕÕÑÑÑÊÊÊÉÉÉÊÊÊÉÉÉÉÉÉÊÊÊÌÌÌÌÌÌÊÊÊÆÆÆ¿¿¿ÂÂÂÂÂÂÂÂÂÃÃÃÇÇÇÌÌÌÑÑÑÔÔÔÕÕÕÛÛÛÛÛÛÛÛÛÝÝÝÜÜÜØØØÙÙÙÔÔÔàààÐÐÐÅÅÅÌÌÌ×××ÙÙÙÎÎÎÔÔÔÐÐÐÆÆÆÂÂÂÃÃÃÀÀÀÀÀÀÊÊÊÊÊÊÃÃÃÊÊÊÕÕÕÔÔÔÐÐÐÐÐÐÎÎÎÌÌÌÇÇÇÌÌÌÔÔÔÙÙÙÙÙÙÎÎο¿¿ÀÀÀ¾¾¾¼¼¼¼¼¼¿¿¿ÂÂÂÃÃÃÅÅÅÐÐÐÊÊÊÉÉÉÉÉÉÉÉÉÌÌÌÆÆÆ»»»ÆÆÆÊÊÊÌÌÌÊÊÊÉÉÉÌÌÌÍÍÍÍÍÍÍÍÍÑÑÑîîîâââçççäääÜÜÜÝÝÝäääçççîîîñññîîîñññóóóïïïÃÃÃÊÊÊÎÎÎÌÌÌÎÎÎØØØÛÛÛ×××ÒÒÒßßßØØØÙÙÙØØØßßßàààÒÒÒ×××ÔÔÔÑÑÑÑÑÑÕÕÕØØØÛÛÛÛÛÛÃÃÃÇÇÇÉÉÉÆÆƼ¼¼ºººÃÃÃÐÐÐâââäääæææààà×××ÍÍÍÉÉÉÇÇÇÌÌÌ×××ØØØÙÙÙÔÔÔÐÐÐÕÕÕÒÒÒÎÎÎÐÐÐÌÌÌ¿¿¿¼¼¼ÃÃÃäääöööîîîõõõùùùèèèßßßãããäääàààÑÑÑ×××ÜÜÜÎÎÎÐÐÐÜÜÜ×××ÐÐÐÜÜÜàààÛÛÛÙÙÙÝÝÝÛÛÛÑÑѺºº···¸¸¸»»»¼¼¼»»»¿¿¿ÅÅÅÅÅÅÅÅů¯¯°°°¿¿¿¿¿¿¿¿¿¾¾¾ÂÂÂÀÀÀ¾¾¾ººº¸¸¸µµµµµµµµµ»»»¼¼¼¼¼¼¾¾¾¸¸¸ÉÉÉÀÀÀÆÆÆÉÉÉÍÍÍÎÎÎÊÊÊÅÅÅÆÆÆÇÇÇÉÉÉÇÇÇ»»»ÉÉÉÒÒÒÑÑÑÐÐо¾¾¬¬¬¸¸¸ººº¼¼¼ÂÂÂÂÂÂÉÉÉÇÇǬ¬¬°°°³³³´´´¼¼¼ÂÂÂßßßÛÛÛßßßâââÔÔÔÍÍÍÊÊÊÆÆÆÃÃÃÃÃÃÀÀÀºººÊÊÊØØØÕÕÕÊÊÊÅÅÅÇÇÇÍÍÍÇÇÇÉÉÉÌÌÌÍÍÍÌÌÌÊÊÊÇÇÇÅÅÅÃÃÃÂÂÂÂÂÂÃÃÃÇÇÇÍÍÍÑÑÑÔÔÔÜÜÜßßßÝÝÝÙÙÙØØØØØØ×××ÕÕÕâââäääÌÌÌ¿¿¿ÉÉÉÒÒÒÜÜÜ×××ÒÒÒÐÐÐÅÅÅÀÀÀ¿¿¿¿¿¿ÉÉÉÇÇÇÅÅÅÎÎÎØØØÒÒÒÍÍÍÍÍÍÌÌÌÎÎÎÍÍÍÐÐÐ×××ÙÙÙÕÕÕÉÉÉ»»»ÆÆÆÃÃÿ¿¿¼¼¼¼¼¼¾¾¾¿¿¿ÀÀÀÆÆÆÆÆÆÅÅÅÂÂÂÅÅÅÇÇÇ¿¿¿±±±ÀÀÀÅÅÅÉÉÉÌÌÌÌÌÌÍÍÍÎÎÎÎÎÎÐÐÐÒÒÒïïïâââäääãããÜÜÜßßßßßßãããèèèîîîñññóóóõõõóóóÌÌÌÊÊÊÔÔÔÒÒÒÐÐÐÙÙÙØØØÕÕÕ×××àààßßßêêêãããêêêêêêàààëëëêêêäääÝÝÝÕÕÕÍÍÍÇÇÇÃÃÃÉÉÉÆÆÆÆÆÆÌÌÌÔÔÔØØØØØØ×××ÂÂÂÀÀÀÅÅÅÎÎÎÙÙÙââââââßßßÐÐÐÍÍÍÉÉÉÐÐÐÙÙÙÛÛÛÕÕÕÊÊÊÑÑÑÐÐÐÍÍÍÍÍÍÌÌÌ¿¿¿ÂÂÂÜÜÜîîîñññõõõóóóíííääääääííí×××ÌÌÌÐÐÐÛÛÛÎÎÎÉÉÉÙÙÙÙÙÙÍÍÍÕÕÕÛÛÛÝÝÝßßßÝÝÝÒÒÒÆÆÆ»»»ºººººº»»»¸¸¸···»»»ÂÂÂÃÃÃÃÃð°°±±±¾¾¾¿¿¿Â¾¾¾¼¼¼»»»¸¸¸······µµµ···¾¾¾ÀÀÀ¼¼¼»»»¸¸¸ÎÎÎÃÃÃÂÂÂÉÉÉÍÍÍÐÐÐÍÍÍÉÉÉÆÆÆÇÇÇÊÊÊÊÊʼ¼¼ÅÅÅÊÊÊÍÍÍÉÉɵµµ¨¨¨ºººººº¿¿¿ÃÃÿ¿¿ÀÀÀ¼¼¼ªªªªªª°°°´´´»»»ÃÃÃàààÙÙÙ×××ÜÜÜÛÛÛÛÛÛØØØÍÍÍÃÃÃÃÃÃÇÇÇ»»»ÇÇÇÔÔÔÕÕÕÐÐÐÌÌÌÊÊÊÌÌÌÌÌÌÌÌÌÌÌÌÍÍÍÍÍÍÌÌÌÊÊÊÊÊÊÆÆÆÅÅÅÅÅÅÆÆÆÊÊÊÎÎÎÒÒÒÕÕÕâââàààÜÜÜÔÔÔÑÑÑ×××ÜÜÜÙÙÙÜÜÜÜÜÜÍÍÍÑÑÑÜÜÜÛÛÛÝÝÝÜÜÜÒÒÒÎÎÎÅÅÅÀÀÀ¾¾¾¾¾¾ÇÇÇÆÆÆÆÆÆÑÑÑØØØÒÒÒÍÍÍÎÎÎÌÌÌÍÍÍÒÒÒ×××ÙÙÙØØØÍÍÍ¿¿¿¸¸¸¿¿¿¿¿¿¾¾¾¾¾¾¾¾¾¿¿¿ÂÂÂÃÃÃÅÅÅÉÉÉÆÆÆÀÀÀÀÀÀÀÀÀ»»»³³³µµµ»»»ÅÅÅÌÌÌÎÎÎÎÎÎÎÎÎÐÐÐÒÒÒÒÒÒëëëÜÜÜàààâââÜÜÜàààÜÜÜßßßäääëëëñññóóóóóóõõõàààÉÉÉÎÎÎÒÒÒÑÑÑ×××ÒÒÒÕÕÕÝÝÝßßßÙÙÙèèèÑÑÑÉÉÉÃÃþ¾¾ÂÂÂÅÅÅÆÆÆÃÃÿ¿¿¾¾¾ÂÂÂÆÆÆÉÉÉÌÌÌÎÎÎÒÒÒ×××ÔÔÔÊÊÊÂÂÂßßßÕÕÕÌÌÌÉÉÉÍÍÍÐÐÐÎÎÎÌÌÌçççÛÛÛÐÐÐÎÎÎÔÔÔÙÙÙ×××ÔÔÔÎÎÎÌÌÌÌÌÌÕÕÕÔÔÔÇÇÇÆÆÆÐÐÐÜÜÜöööúúúõõõöööêêêÛÛÛâââãããÛÛÛÑÑÑ×××ÎÎÎÆÆÆÙÙÙãããÕÕÕÍÍÍÌÌÌÔÔÔÙÙÙÒÒÒÅÅż¼¼¾¾¾ººº¸¸¸¸¸¸···µµµ¼¼¼ÃÃÃÂÂÂÀÀÀ°°°¯¯¯µµµµµµ»»»»»»···············¸¸¸¸¸¸¸¸¸»»»¾¾¾»»»ººººººÑÑÑÇÇÇÃÃÃÇÇÇÌÌÌÐÐÐÑÑÑÎÎÎÉÉÉÇÇÇÉÉÉÎÎÎÅÅÅÃÃÃÃÃÃÉÉÉÅÅű±±³³³¾¾¾¸¸¸ÀÀÀÅÅž¾¾µµµ°°°¯¯¯­­­±±±³³³¸¸¸¿¿¿ÛÛÛÒÒÒÐÐÐØØØÛÛÛÝÝÝßßßØØØÍÍÍÇÇÇÌÌÌÃÃÃÃÃÃÉÉÉÑÑÑØØØØØØÒÒÒÎÎÎÒÒÒÑÑÑÎÎÎÍÍÍÌÌÌÍÍÍÍÍÍÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÒÒÒ×××ÛÛÛÝÝÝÜÜÜÝÝÝàààßßßÝÝÝãããâââÕÕÕÊÊÊÍÍÍÆÆÆÔÔÔàààÛÛÛÙÙÙÛÛÛÐÐÐÍÍÍÅÅÅÀÀÀ¼¼¼»»»ÃÃÃÊÊÊÊÊÊÕÕÕÛÛÛÕÕÕÒÒÒÒÒÒÎÎÎÌÌÌÕÕÕÛÛÛÛÛÛ×××ÉÉɾ¾¾»»»¾¾¾¿¿¿ÀÀÀÀÀÀ¿¿¿ÀÀÀÂÂÂÅÅÅÅÅÅÉÉÉÆÆÆÀÀÀÃÃÃÅÅÅÅÅÅÆÆƯ¯¯µµµÀÀÀÌÌÌÐÐÐÎÎÎÎÎÎÐÐÐÒÒÒÐÐÐæææ×××ÝÝÝàààÜÜÜßßßÝÝÝàààâââèèèññññññîîîñññêêêÀÀÀÂÂÂÍÍÍÐÐÐÔÔÔÎÎÎØØØààààààÝÝÝóóóÕÕÕÍÍÍÌÌÌÍÍÍÑÑÑÐÐÐÌÌÌÆÆÆÀÀÀÃÃÃÊÊÊÑÑÑÍÍÍØØØÝÝÝØØØÐÐÐÍÍÍÒÒÒ×××ÍÍÍÐÐÐÔÔÔ×××ØØØØØØÙÙÙÛÛÛÐÐÐÍÍÍÐÐÐÊÊÊÃÃÃÃÃÃÆÆÆÑÑÑÌÌÌÐÐÐÍÍÍÔÔÔÔÔÔÌÌÌÉÉÉÅÅÅÍÍÍíííöööñññöööíííßßßäääçççëëë×××ØØØ×××ÅÅÅÎÎÎÛÛÛÝÝÝÊÊÊ¿¿¿ÅÅÅÌÌÌÅÅż¼¼»»»¾¾¾¸¸¸µµµ···¸¸¸ºººÀÀÀÇÇÇÃÃÃÃÃô´´°°°­­­¨¨¨¯¯¯­­­­­­°°°³³³µµµ¸¸¸¸¸¸¸¸¸¸¸¸µµµ¸¸¸¸¸¸¸¸¸¸¸¸ÑÑÑÉÉÉÉÉÉÆÆÆÊÊÊÑÑÑ×××ÒÒÒÊÊÊÇÇÇÉÉÉÅÅÅÇÇÇÎÎÎÑÑÑÕÕÕÇÇÇ°°°···ÀÀÀ¸¸¸ÀÀÀÅÅÅ¿¿¿´´´¬¬¬³³³³³³´´´´´´»»»ÀÀÀÝÝÝÛÛÛàààØØØ×××ÔÔÔÛÛÛãããÜÜÜÐÐÐÌÌÌÇÇÇÀÀÀ¿¿¿ÉÉÉ×××ÛÛÛÙÙÙÕÕÕ×××ÕÕÕÑÑÑÎÎÎÍÍÍÎÎÎÎÎÎÐÐÐÎÎÎÐÐÐÑÑÑÑÑÑÒÒÒÕÕÕÛÛÛßßßãããäääëëëíííêêêîîîæææÑÑÑÔÔÔÙÙÙÑÑÑÕÕÕÜÜÜÕÕÕÔÔÔÒÒÒÎÎÎÍÍÍÅÅÅÂÂÂÃÃü¼¼ºººÀÀÀÐÐÐÐÐÐÙÙÙßßßÛÛÛÙÙÙÛÛÛÔÔÔÑÑÑÙÙÙÛÛÛØØØÕÕÕÊÊÊ¿¿¿¿¿¿ÃÃÃÅÅÅÅÅÅÃÃÃÀÀÀÀÀÀÂÂÂÅÅÅÆÆÆÆÆÆÂÂÂÂÂÂÉÉÉÆÆÆÀÀÀÆÆƯ¯¯´´´¿¿¿ÌÌÌÐÐÐÎÎÎÎÎÎÑÑÑÐÐÐÌÌÌàààÒÒÒÜÜÜàààÛÛÛÛÛÛÝÝÝààààààçççñññîîîèèèîîîèè躺º¿¿¿ÌÌÌÎÎÎÕÕÕÐÐÐÛÛÛßßßãããßßßïïïÉÉÉÇÇÇÊÊÊÎÎÎæææßßßÕÕÕÎÎÎÌÌÌÌÌÌÊÊÊÊÊÊßßß×××ÌÌÌÉÉÉÎÎÎ×××ÒÒÒÉÉÉÅÅÅÆÆÆÉÉÉÊÊÊÉÉÉÉÉÉÌÌÌÎÎÎÐÐÐÎÎÎÛÛÛÙÙÙÕÕÕÔÔÔÐÐÐÛÛÛÇÇÇÝÝÝÔÔÔÍÍÍÒÒÒÎÎÎÎÎÎÌÌÌÅÅÅÙÙÙëëëññññññêêêçççêêêâââóóóØØØ×××ßßßÆÆÆÅÅÅÒÒÒÝÝÝÐÐÐÅÅÅÃÃÃÅÅÅÀÀÀ¿¿¿¿¿¿ÀÀÀ»»»···ººº¼¼¼¼¼¼ÀÀÀÅÅÅÅÅÅÇÇǾ¾¾¸¸¸¯¯¯¥¥¥ªªª¨¨¨¨¨¨¬¬¬±±±µµµ¸¸¸¸¸¸···µµµµµµ¸¸¸ººº»»»···ÊÊÊÃÃÃÇÇÇÆÆÆÊÊÊÒÒÒØØØÔÔÔÌÌÌÇÇÇÊÊÊÀÀÀÆÆÆÛÛÛààà××ׯ¯¯µµµÂ¸¸¸¿¿¿ÂÂÂÃÃÿ¿¿°°°³³³´´´´´´µµµ¿¿¿ÃÃÃÛÛÛØØØâââÝÝÝØØØÐÐÐ×××äääàààÑÑÑÌÌÌÊÊÊÃÃÃÀÀÀÃÃÃÉÉÉÍÍÍÒÒÒÙÙÙÕÕÕÕÕÕÔÔÔÒÒÒÒÒÒÑÑÑÑÑÑÐÐÐÍÍÍÐÐÐÒÒÒÑÑÑÐÐÐÑÑÑÙÙÙßßßúúúõõõñññêêêæææîîîëëëØØØÍÍÍÙÙÙÔÔÔÕÕÕÛÛÛ×××ÕÕÕÎÎÎÍÍÍÌÌÌÅÅÅÂÂÂÃÃü¼¼¸¸¸¿¿¿ÔÔÔÔÔÔÜÜÜâââßßßßßßàààÙÙÙÙÙÙÝÝÝÙÙÙÕÕÕ×××ÍÍÍÀÀÀÀÀÀÅÅÅÆÆÆÆÆÆÃÃÃÂÂÂÃÃÃÇÇÇÌÌÌÌÌÌÉÉÉÂÂÂÅÅÅÊÊʼ¼¼¬¬¬¬¬¬³³³µµµ¿¿¿ÌÌÌÐÐÐÍÍÍÎÎÎÔÔÔÌÌÌÇÇÇÝÝÝÑÑÑÜÜÜàààØØØØØØÛÛÛÝÝÝÝÝÝäääñññîîîèèèïïïççç»»»ÅÅÅÎÎÎÐÐÐØØØÒÒÒÜÜÜÝÝÝçççâââëëëÀÀÀÇÇÇÐÐÐÑÑÑçççßßßÙÙÙÛÛÛââââââÛÛÛÑÑÑÅÅÅÐÐÐÕÕÕÒÒÒÍÍÍÊÊÊÇÇÇÂÂÂßßßÜÜÜÛÛÛÝÝÝâââãããàààÜÜÜÛÛÛÊÊÊÊÊÊÊÊÊÒÒÒ×××ÉÉÉÊÊÊÆÆÆëëëÙÙÙÉÉÉÒÒÒÔÔÔ×××ÙÙÙÂÂÂÍÍÍëëëÿÿÿõõõæææâââÝÝÝäääüüü×××ÐÐÐàààÊÊÊÊÊÊÝÝÝØØØ×××ÒÒÒÌÌÌÇÇÇÆÆÆÅÅÅÃÃÃÅÅž¾¾»»»¼¼¼¿¿¿¼¼¼¼¼¼¿¿¿ÅÅÅÊÊÊÆÆÆÃÃõµµªªª¯¯¯¬¬¬¥¥¥©©©°°°µµµ¸¸¸···´´´³³³ººº¼¼¼¼¼¼¼¼¼´´´Â»»»ÃÃÃÇÇÇÊÊÊÑÑÑØØØÕÕÕÌÌÌÉÉÉÌÌÌÌÌÌÉÉÉÜÜÜÜÜÜÅÅÅ´´´°°°¸¸¸ÀÀÀººº¿¿¿¿¿¿ÇÇÇÍÍÍ···°°°³³³±±±´´´¾¾¾¼¼¼ÉÉÉ¿¿¿ÇÇÇãããßßßÕÕÕ×××ßßßÙÙÙÍÍÍÍÍÍÍÍÍÉÉÉÆÆƼ¼¼¼¼¼ÉÉÉØØØÒÒÒÔÔÔÕÕÕ×××ÕÕÕÔÔÔÑÑÑÐÐÐÐÐÐÕÕÕÙÙÙ×××ÔÔÔÕÕÕÝÝÝæææèèèíííäääÛÛÛñññøøøæææèèèÊÊÊÔÔÔßßßàààÙÙÙÑÑÑÌÌÌÊÊÊÐÐÐÍÍÍ¿¿¿ÌÌÌÀÀÀ»»»¼¼¼ÅÅÅÒÒÒÙÙÙßßßÝÝÝÜÜÜÝÝÝÜÜÜØØØÙÙÙÔÔÔÒÒÒÔÔÔÌÌ̾¾¾ºººÀÀÀÃÃÃÆÆÆÅÅÅÂÂÂÀÀÀÀÀÀ»»»±±±°°°±±±¼¼¼ÇÇÇ¿¿¿­­­©©©°°°···ºººÀÀÀÉÉÉÎÎÎÑÑÑÎÎÎÌÌÌÇÇÇÌÌÌÕÕÕÝÝÝÝÝÝØØØÙÙÙâââßßßÝÝÝßßßöööñññèèèÿÿÿîîîßßßÆÆƺººÊÊÊÇÇÇÕÕÕÔÔÔ×××ÛÛÛààààààäääÒÒÒ¿¿¿ÌÌÌÔÔÔÜÜÜÐÐÐÐÐÐÆÆÆÃÃÃÉÉÉÉÉÉØØØÉÉÉÍÍÍÌÌ̾¾¾ÆÆÆÒÒÒÛÛÛÒÒÒÒÒÒÔÔÔÕÕÕ×××ØØØÙÙÙÙÙÙÙÙÙ×××ØØØÙÙÙÒÒÒÉÉÉÍÍÍÙÙÙÎÎÎÉÉÉÛÛÛÙÙÙØØØÑÑÑÛÛÛÑÑÑÎÎλ»»õõõøøøòòòõõõêêêãããëëëîîîÝÝÝØØØâââÐÐÐÆÆÆßßßßßß×××ÎÎÎÊÊÊÊÊÊÌÌÌÊÊÊÇÇÇÃÃÿ¿¿¼¼¼»»»»»»¼¼¼¼¼¼ÂÂÂÉÉÉ»»»»»»³³³ªªª­­­¦¦¦¢¢¢¦¦¦´´´¼¼¼ºººµµµ´´´µµµººº¼¼¼»»»»»»¿¿¿ÀÀÀ¿¿¿ÉÉÉÐÐÐÎÎÎÔÔÔÇÇÇÌÌÌÉÉÉÐÐÐÊÊÊÆÆÆÕÕÕÝÝÝÐÐЬ¬¬···»»»¼¼¼¼¼¼ººº¾¾¾ÎÎÎÙÙÙÉÉÉ­­­³³³±±±···¿¿¿ÃÃÃÂÂÂÃÃÃÉÉÉÉÉÉÑÑÑÔÔÔÒÒÒØØØÝÝÝ×××ÉÉÉÉÉÉÒÒÒÐÐÐÇÇÇÇÇÇÇÇÇÆÆÆÊÊÊÕÕÕÒÒÒÙÙÙ×××ÕÕÕØØØÑÑÑÕÕÕÙÙÙÛÛÛÛÛÛÙÙÙÙÙÙßßßêêêóóóâââèèèëëëãããçççêêêàààëëëçççâââÙÙÙÔÔÔÑÑÑÎÎÎÌÌÌÉÉÉÎÎÎÊÊʺººÇÇǾ¾¾¿¿¿ÅÅÅÎÎÎÐÐÐØØØÝÝÝÜÜÜÙÙÙÙÙÙØØØÕÕÕÒÒÒÍÍÍÎÎÎÒÒÒÌÌÌ¿¿¿»»»¿¿¿¿¿¿ÃÃÃÅÅÅÂÂÂÀÀÀ¾¾¾···´´´±±±±±±³³³­­­¨¨¨­­­¸¸¸ººº¼¼¼ÂÂÂÉÉÉÎÎÎÐÐÐÍÍÍÊÊÊÉÉÉÉÉÉÍÍÍÕÕÕÜÜÜÜÜÜÝÝÝÝÝÝÜÜÜàààâââõõõïïïíííÿÿÿîîîêêê×××¾¾¾ÆÆÆÃÃÃÐÐÐÔÔÔØØØÜÜÜàààßßßààà×××ÅÅÅÇÇÇÑÑÑÑÑÑÐÐÐ×××ÙÙÙ×××ÔÔÔÐÐÐÔÔÔÃÃÃÐÐÐÛÛÛÛÛÛ×××ÔÔÔÑÑÑÍÍÍÌÌÌÌÌÌÌÌÌÍÍÍÎÎÎÐÐÐÐÐÐÑÑÑÍÍÍÉÉÉÊÊÊÑÑÑÐÐÐÇÇÇÆÆÆÍÍÍÑÑÑßßßÑÑÑÅÅÅçççÜÜÜÍÍÍÙÙÙÔÔÔ¾¾¾ÝÝÝîîîõõõòòòïïïæææîîîèèèÛÛÛØØØàààÕÕÕÊÊÊÒÒÒÛÛÛÕÕÕÒÒÒÔÔÔ×××ÔÔÔÌÌÌÃÃÃÆÆÆÅÅÅ¿¿¿¼¼¼¼¼¼¼¼¼¼¼¼ÂÂÂÅÅÅÆÆÆÆÆÆÃÃþ¾¾¾¾¾ÆÆƸ¸¸°°°°°°µµµººº»»»¼¼¼»»»µµµ³³³¸¸¸¿¿¿ÀÀÀÂÂÂÃÃÃÙÙÙÙÙÙÑÑÑ×××ÍÍÍÒÒÒÊÊÊÊÊÊÌÌÌÍÍÍÝÝÝäääÒÒÒ¬¬¬¸¸¸¾¾¾¸¸¸¾¾¾¿¿¿¿¿¿ÆÆÆÐÐÐÒÒÒÎÎÎÃÃÃÀÀÀººº±±±³³³¼¼¼ÀÀÀ¾¾¾ÐÐÐÕÕÕ×××ÕÕÕÙÙÙàààÜÜÜÑÑÑÑÑÑÝÝÝßßßÕÕÕÐÐÐÊÊÊÉÉÉÍÍÍîîîßßßØØØÐÐÐÔÔÔßßßÝÝÝâââãããêêêîîîëëëäääàààãããçççããããããëëëæææàààßßßÜÜÜçççàààÛÛÛÔÔÔÑÑÑÒÒÒÒÒÒÎÎÎÊÊÊÇÇÇÆÆƸ¸¸ÉÉÉÅÅÅÇÇÇÍÍÍÔÔÔÍÍÍ×××ÜÜÜÛÛÛ×××ÕÕÕÒÒÒÐÐÐÑÑÑÍÍÍÎÎÎÑÑÑÍÍÍÀÀÀ¼¼¼¿¿¿¼¼¼ÀÀÀÃÃÃÃÃÃÂÂÂÂÂÂÀÀÀ¾¾¾ªªª­­­°°°±±±°°°°°°³³³´´´»»»¾¾¾ÂÂÂÇÇÇÍÍÍÍÍÍÊÊÊÇÇÇÊÊÊÇÇÇÆÆÆÌÌÌØØØâââàààÛÛÛÛÛÛàààãããòòòïïïïïïÿÿÿîîîîîîæææÀÀÀÅÅÅÅÅÅÍÍÍÕÕÕØØØÜÜÜÝÝÝÜÜÜÛÛÛÜÜÜÎÎÎÂÂÂÎÎÎÑÑÑÑÑÑÎÎÎÑÑÑÐÐÐÌÌÌÒÒÒÕÕÕÐÐÐÒÒÒÑÑÑÍÍÍÊÊÊÌÌÌÎÎÎÐÐÐÆÆÆÇÇÇÇÇÇÇÇÇÇÇÇÇÇÇÉÉÉÉÉÉÆÆÆ¿¿¿¿¿¿ÇÇÇÊÊÊÇÇÇÅÅÅÇÇÇÑÑÑÐÐÐÐÐÐÊÊÊÒÒÒÍÍÍÍÍÍÍÍÍÒÒÒÂÂÂÇÇÇäääùùùñññóóóæææîîîãããØØØØØØÝÝÝÜÜÜÑÑÑÇÇÇÜÜÜÙÙÙ×××××××××ÕÕÕÑÑÑÎÎÎÊÊÊÉÉÉÅÅÅ¿¿¿¾¾¾¾¾¾¾¾¾ÀÀÀ¿¿¿ÅÅÅÇÇÇÀÀÀ¼¼¼ÀÀÀÆÆÆ¿¿¿¸¸¸°°°­­­±±±¸¸¸ººº···µµµ¸¸¸»»»¼¼¼¿¿¿ÀÀÀÀÀÀ¿¿¿ÇÇÇÐÐÐÐÐÐ×××ÌÌÌÎÎÎÊÊÊÐÐÐÍÍÍÑÑÑäääèèè××ׯ¯¯»»»ÅÅÅ»»»ÀÀÀÃÃÃÃÃÃÃÃÃÊÊÊØØØãããÕÕÕÒÒÒÉÉÉ»»»···¼¼¼ÂÂÂÂÂÂÐÐÐ×××ÙÙÙÛÛÛàààäääààà×××ãããçççãããàààãããÜÜÜÎÎÎÇÇÇæææÜÜÜßßßÜÜÜàààäääÜÜÜÜÜÜàààæææêêêæææÛÛÛÐÐÐÌÌÌÌÌÌïïïÝÝÝââââââÜÜÜÝÝÝÛÛÛÜÜÜÑÑÑÒÒÒÔÔÔÒÒÒÎÎÎÌÌÌÉÉÉÇÇÇÀÀÀÅÅž¾¾ÔÔÔÒÒÒÒÒÒÐÐÐÐÐÐÊÊÊÔÔÔÛÛÛØØØÔÔÔÑÑÑÐÐÐÍÍÍÔÔÔÐÐÐÎÎÎÐÐÐÊÊʼ¼¼¿¿¿¼¼¼ÀÀÀÅÅÅÃÃÃÂÂÂÀÀÀÀÀÀÀÀÀ¥¥¥¯¯¯¸¸¸»»»¿¿¿ÀÀÀ¼¼¼´´´ººº»»»¿¿¿ÆÆÆÊÊÊÌÌÌÉÉÉÆÆÆÉÉÉÇÇÇÃÃÃÆÆÆÒÒÒààààààÙÙÙÛÛÛÝÝÝâââòòòòòòîîîøøøïïïæææêêêÀÀÀÆÆÆÉÉÉÎÎÎÕÕÕÔÔÔØØØØØØØØØ×××ßßßÕÕÕ¿¿¿ÎÎÎÕÕÕÕÕÕÇÇÇÇÇÇÆÆÆÅÅÅÕÕÕØØØÎÎÎÌÌÌÇÇÇÃÃÃÂÂÂÅÅÅÉÉÉÊÊÊÊÊÊÊÊÊÉÉÉÉÉÉÇÇÇÇÇÇÇÇÇÆÆÆÊÊʾ¾¾ÀÀÀÅÅÅÆÆÆÉÉÉÎÎÎÅÅÅÎÎÎÎÎÎÍÍÍÙÙÙ×××ÔÔÔÜÜÜÎÎÎÇÇÇÂÂÂÙÙÙòòòòòòñññæææèèèäääÛÛÛ×××ÝÝÝâââØØØÌÌÌ×××ÙÙÙÛÛÛØØØÕÕÕÔÔÔ×××ÛÛÛÐÐÐÍÍÍÉÉÉÅÅÅÂÂÂÀÀÀ¿¿¿¿¿¿¾¾¾»»»ÂÂÂÃÃü¼¼¼¼¼¿¿¿···¬¬¬­­­¬¬¬¬¬¬³³³¼¼¼»»»´´´¾¾¾ÐÐÐÒÒÒ¿¿¿±±±¸¸¸¼¼¼ººº···ÅÅÅÌÌÌÕÕÕÊÊÊÍÍÍÉÉÉÐÐÐÎÎÎÑÑÑßßßäääÙÙÙµµµ¿¿¿ÉÉÉÆÆÆÂÂÂÂÂÂÆÆÆÉÉÉÊÊÊÑÑÑÙÙÙÌÌÌÌÌÌÌÌÌÊÊʸ¸¸¸¸¸¿¿¿ÆÆÆÐÐÐÙÙÙßßßääääääÜÜÜÑÑÑççççççâââæææñññêêêÔÔÔÇÇÇÑÑÑÙÙÙîîîóóóóóóñññãããâââçççäääâââÝÝÝ×××ÑÑÑÌÌÌÇÇÇõõõÜÜÜÛÛÛÛÛÛØØØÜÜÜØØØÔÔÔÙÙÙÕÕÕÎÎÎÆÆÆÀÀÀ¿¿¿ÀÀÀÃÃÃÅÅÅÌÌÌÆÆÆÛÛÛÙÙÙÙÙÙÑÑÑÊÊÊÇÇÇÐÐÐ×××ÕÕÕÑÑÑÐÐÐÎÎÎÌÌÌÎÎÎÊÊÊÆÆÆÆÆÆÃÃÿ¿¿¿¿¿ÀÀÀÀÀÀÂÂÂÅÅÅÅÅÅ¿¿¿¿¿¿Â­­­µµµ»»»»»»ÀÀÀÇÇÇÆÆÆÀÀÀ···¸¸¸¼¼¼ÂÂÂÇÇÇÊÊÊÉÉÉÇÇÇÉÉÉÉÉÉÇÇÇÆÆÆÎÎÎÛÛÛßßßÛÛÛÝÝÝÛÛÛâââóóóóóóíííñññïïïäääççç¿¿¿ÃÃÃÇÇÇÍÍÍÒÒÒÑÑÑÒÒÒÒÒÒÔÔÔÒÒÒÝÝÝÕÕÕÀÀÀÑÑÑÎÎÎØØØÔÔÔÙÙÙÙÙÙÔÔÔÛÛÛÕÕÕÊÊÊÉÉÉÇÇÇÉÉÉÊÊÊÊÊÊÊÊÊÊÊÊÍÍÍÍÍÍÌÌÌÊÊÊÉÉÉÇÇÇÆÆÆÅÅÅÆÆÆÃÃÃÂÂÂÂÂÂÂÂÂÂÂÂÉÉÉÐÐÐØØØÂÂÂÌÌÌØØØÌÌÌØØØãããÎÎÎÐÐÐÎÎÎÊÊÊÍÍÍßßßñññîîîëëëâââêêêààà×××ßßßâââÛÛÛÛÛÛÐÐÐÒÒÒ×××ÛÛÛÜÜÜÛÛÛ×××ÔÔÔÒÒÒÐÐÐÌÌÌÇÇÇÅÅÅÂÂÂÂÂÂÀÀÀ¿¿¿ÀÀÀÆÆÆÅÅÅÃÃÃÌÌÌÇÇDZ±±°°°³³³³³³³³³ºººÂ¼¼¼¸¸¸ÉÉÉÊÊʸ¸¸³³³ÀÀÀÐÐÐÒÒÒÉÉÉÌÌÌÆÆÆÑÑÑÌÌÌÒÒÒÉÉÉÇÇÇÍÍÍÌÌÌÔÔÔÜÜÜÜÜÜ»»»ÃÃÃÌÌÌÌÌÌÃÃÿ¿¿ÅÅÅÉÉÉÆÆÆÇÇÇÌÌÌÇÇÇÆÆÆÌÌÌÒÒÒÑÑÑÅÅÅ»»»¸¸¸¾¾¾ÆÆÆÑÑÑØØØÜÜÜÛÛÛÔÔÔÌÌÌ×××ÝÝÝàààèèèñññèèè×××ÐÐÐÀÀÀÉÉÉÜÜÜâââæææêêêæææëëëäääÝÝÝ××××××ÜÜÜÜÜÜÔÔÔÌÌÌîîîÜÜÜÜÜÜ×××ÐÐÐÔÔÔÒÒÒÒÒÒÒÒÒÌÌÌÃÃÃÀÀÀÆÆÆÌÌÌÎÎÎÎÎÎÒÒÒÕÕÕÉÉÉÙÙÙ×××ØØØÐÐÐÇÇÇÃÃÃÊÊÊÎÎÎÎÎÎÍÍÍÐÐÐÎÎÎÊÊÊÀÀÀ¼¼¼ºººººº¼¼¼¿¿¿ÂÂÂÅÅÅÅÅÅÃÃÃÅÅÅÆÆÆÃÃÿ¿¿¿¿¿ÀÀÀ¯¯¯µµµººº»»»ÀÀÀÇÇÇÇÇÇÃÃ÷··¸¸¸¼¼¼ÂÂÂÇÇÇÊÊÊÉÉÉÇÇÇÉÉÉÉÉÉÊÊÊÌÌÌÑÑÑÙÙÙÝÝÝÝÝÝßßßßßßæææóóóõõõïïïîîîïïïëëëâââ¼¼¼ÀÀÀÃÃÃÌÌÌÐÐÐÎÎÎÎÎÎÐÐÐÑÑÑÒÒÒ×××ÍÍÍÅÅÅÔÔÔÅÅÅÑÑÑÙÙÙàààâââÜÜÜÙÙÙÑÑÑÍÍÍÉÉÉÅÅÅÆÆÆÇÇÇÉÉÉÌÌÌÑÑÑÍÍÍÍÍÍÊÊÊÇÇÇÆÆÆÃÃÃÀÀÀÀÀÀ¼¼¼¿¿¿ÂÂÂÃÃÃÂÂÂÀÀÀÂÂÂÆÆÆÇÇÇÝÝÝÅÅž¾¾ÕÕÕÔÔÔÂÂÂßßß×××ÕÕÕÒÒÒÃÃÃÉÉÉííííííõõõßßßëëëæææÜÜÜààààààÝÝÝäääÙÙÙÒÒÒÎÎÎÑÑÑÙÙÙÜÜÜ×××ÐÐÐÔÔÔÑÑÑÎÎÎÊÊÊÆÆÆÅÅÅÃÃÃÃÃÃÇÇÇÉÉÉÉÉÉÆÆÆÇÇÇÌÌ̯¯¯¸¸¸¾¾¾ÂÂÂÃÃÃÃÃþ¾¾¸¸¸ÃÃÃÅÅÅÅÅÅÅÅÅÅÅÅÆÆÆÆÆÆÆÆÆÍÍÍÍÍÍÅÅÅÌÌÌÇÇÇÐÐÐÊÊÊÌÌÌÌÌÌÉÉÉÍÍÍ×××ÜÜܼ¼¼ÀÀÀÇÇÇÆÆÆÀÀÀ¾¾¾ÀÀÀÀÀÀ¿¿¿ÃÃÃÊÊÊÎÎÎÍÍÍÊÊÊÍÍÍÕÕÕØØØÉÉÉ···¼¼¼ÀÀÀÅÅÅÉÉÉÍÍÍÎÎÎÍÍÍÌÌÌÌÌÌÐÐÐÕÕÕâââïïïêêêÙÙÙÒÒÒÕÕÕÎÎÎÐÐÐÌÌÌÍÍÍÑÑÑÌÌÌÎÎÎÕÕÕÎÎÎÊÊÊÑÑÑÜÜÜÝÝÝÑÑÑÅÅÅâââÛÛÛÝÝÝÒÒÒÌÌÌÐÐÐÌÌÌÌÌÌÉÉÉÇÇÇÉÉÉÍÍÍÔÔÔÛÛÛÜÜÜÜÜÜÙÙÙÛÛÛÊÊÊÕÕÕÒÒÒÔÔÔÌÌÌ¿¿¿ÂÂÂÅÅÅÆÆÆÉÉÉÎÎÎÍÍÍÉÉɸ¸¸µµµ´´´···¼¼¼ÂÂÂÆÆÆÇÇÇÆÆÆÂÂÂÂÂÂÅÅÅÆÆÆÂÂÂÀÀÀ¬¬¬³³³»»»ÀÀÀÃÃÃÅÅÅÃÃû»»¼¼¼¿¿¿ÅÅÅÉÉÉÌÌÌÊÊÊÉÉÉÊÊÊÆÆÆÇÇÇÐÐÐÙÙÙÝÝÝßßßßßßßßßçççïïïñññóóóöööòòòëëëëëëÕÕÕºººÅÅÅÅÅÅÑÑÑÐÐÐÎÎÎÍÍÍÑÑÑÑÑÑÔÔÔÍÍÍÀÀÀÇÇÇÔÔÔÊÊÊÎÎÎÔÔÔÑÑÑÐÐÐÒÒÒÐÐÐÎÎÎÇÇÇÅÅÅÅÅÅÉÉÉÉÉÉÆÆÆÇÇÇÌÌÌÍÍÍÍÍÍÊÊÊÇÇÇÃÃÃÀÀÀ¾¾¾¼¼¼ºººººº¼¼¼¿¿¿ÂÂÂÂÂÂÀÀÀ¿¿¿¾¾¾ÎÎÎÍÍÍÒÒÒÐÐÐÕÕÕÕÕÕçççÛÛÛÕÕÕÔÔÔÇÇÇÅÅÅçççëëëøøøâââçççêêêäääßßßÝÝÝßßßâââãããÛÛÛÐÐÐÌÌÌÎÎÎÒÒÒÕÕÕÕÕÕÔÔÔÒÒÒÎÎÎÊÊÊÇÇÇÆÆÆÆÆÆÅÅÅÊÊÊÌÌÌÉÉÉÇÇÇÇÇÇÀÀÀ¸¸¸µµµ¿¿¿ÃÃÃÉÉÉÌÌÌÇÇÇ¿¿¿»»»»»»ÀÀÀ¾¾¾ÀÀÀÉÉÉÎÎÎÊÊÊÃÃÃÀÀÀÂÂÂÇÇÇÇÇÇÔÔÔÎÎÎ×××ÐÐÐÑÑÑÌÌÌÍÍÍÑÑÑØØØÛÛÛ······¿¿¿¿¿¿¼¼¼¼¼¼¼¼¼¼¼¼¼¼¼ÀÀÀÃÃÃÅÅÅÃÃÃÂÂÂÃÃÃÍÍÍÒÒÒÌÌÌ¿¿¿»»»¼¼¼¿¿¿ÂÂÂÅÅÅÆÆÆÇÇÇÉÉÉÉÉÉÉÉÉÌÌÌÜÜÜîîîêêêÙÙÙÑÑÑÝÝÝØØØÛÛÛ×××ØØØßßßÛÛÛßßßØØØÔÔÔÒÒÒØØØßßßÝÝÝÒÒÒÉÉÉÛÛÛÙÙÙÙÙÙÍÍÍÌÌÌÐÐÐÆÆÆÃÃÃØØØÜÜÜßßßÛÛÛÕÕÕÔÔÔØØØÜÜÜÛÛÛÛÛÛÊÊÊÕÕÕÑÑÑÒÒÒÇÇÇ»»»»»»¾¾¾¾¾¾¿¿¿ÆÆÆÍÍÍÍÍÍÇÇǺºº¸¸¸¸¸¸»»»ÀÀÀÆÆÆÉÉÉÉÉÉÇÇÇÀÀÀÀÀÀÅÅÅÆÆÆÃÃÃÂÂÂÃÃñ±±µµµ»»»¿¿¿ÂÂÂÂÂÂÅÅÅÆÆÆÀÀÀÀÀÀÃÃÃÇÇÇÊÊÊÌÌÌÊÊÊÉÉÉÌÌÌÃÃÃÅÅÅÒÒÒßßßâââààààààßßßñññùùùïïïòòòÿÿÿöööèèèãããÇÇǺººÌÌÌÍÍÍÙÙÙÑÑÑÎÎÎÎÎÎÒÒÒÑÑÑÕÕÕÆÆƸ¸¸ÉÉÉÔÔÔÕÕÕÒÒÒÕÕÕÆÆÆÂÂÂÊÊÊÆÆÆÊÊÊÌÌÌÉÉÉÉÉÉÊÊÊÊÊÊÆÆÆÉÉÉÐÐÐÐÐÐÎÎÎÌÌÌÇÇÇÅÅÅÀÀÀ¾¾¾¼¼¼¾¾¾ºººµµµ¸¸¸ÀÀÀÆÆÆÅÅÅÀÀÀÅÅÅÊÊÊÎÎÎÙÙÙÍÍÍÐÐÐÆÆÆÅÅÅØØØÑÑÑÑÑÑÒÒÒÊÊÊæææëëëóóóæææãããêêêëëëÝÝÝÛÛÛßßßÛÛÛÛÛÛßßßßßß×××ÌÌÌÇÇÇÍÍÍÕÕÕÔÔÔÒÒÒÎÎÎÌÌÌÉÉÉÇÇÇÆÆÆÆÆÆÇÇÇÇÇÇÆÆÆÌÌÌÍÍÍ¿¿¿»»»ÌÌÌÍÍÍÉÉÉÉÉÉÇÇÇÃÃÿ¿¿ÇÇÇÔÔÔÆÆÆÇÇÇÃÃþ¾¾¾¾¾ÂÂÂÆÆÆÆÆÆÆÆÆÊÊÊÌÌÌâââçççíííØØØÌÌÌÊÊÊÑÑÑØØØÝÝÝÛÛÛ±±±°°°¸¸¸»»»»»»»»»¼¼¼ÀÀÀ¼¼¼¸¸¸¿¿¿¿¿¿ÆÆÆÎÎÎÎÎÎÍÍÍÐÐÐØØØ···ººº¿¿¿ÃÃÃÅÅÅÅÅÅÃÃÃÅÅÅÂÂÂÊÊÊÒÒÒßßßèèèààà×××ØØØòòòïïïóóóçççÝÝÝÜÜÜÙÙÙâââÝÝÝÜÜÜÛÛÛÛÛÛÛÛÛØØØÑÑÑÌÌÌÔÔÔÙÙÙÐÐÐÐÐÐÅÅÅÅÅÅÂÂÂÜÜÜãããæææãããÙÙÙÕÕÕ×××ØØØØØØÐÐÐÒÒÒ××××××ÒÒÒÌÌÌÆÆÆÃÃÿ¿¿¼¼¼»»»¾¾¾¿¿¿¿¿¿ÆÆÆÍÍÍÇÇǼ¼¼µµµ»»»ÃÃÃÇÇÇÊÊÊÌÌÌÇÇÇÌÌÌÌÌÌÊÊÊÊÊÊÇÇÇ»»»¬¬¬­­­³³³»»»ÂÂÂÆÆÆÇÇÇÅÅÅÂÂÂÂÂÂÀÀÀÅÅÅÌÌÌÌÌÌÇÇÇÉÉÉÐÐÐÊÊÊÌÌÌÍÍÍâââÜÜÜÜÜÜÙÙÙçççüüüõõõóóóøøøøøøñññíííïïïÝÝÝÇÇÇÃÃÃÎÎÎÐÐÐÎÎÎÑÑÑÑÑÑÆÆÆÒÒÒÊÊÊÌÌÌÛÛÛ¼¼¼ÙÙÙÀÀÀÃÃÃÎÎÎÌÌÌÃÃÃÆÆÆÇÇÇÆÆÆÊÊÊÇÇÇÇÇÇÇÇÇÇÇÇÇÇÇÉÉÉÊÊÊÌÌÌÍÍÍÊÊÊÇÇÇÃÃÃÀÀÀ¿¿¿¾¾¾¾¾¾ººº¸¸¸¸¸¸¸¸¸ººº¼¼¼¿¿¿ÀÀÀÃÃÃÃÃÃÐÐÐÎÎÎÅÅÅÒÒÒÛÛÛÆÆÆÛÛÛÑÑÑÐÐÐÑÑѾ¾¾ÂÂÂçççòòòîîîäääÜÜÜßßßèèèñññëëëßßßØØØÒÒÒÒÒÒÙÙÙÜÜÜÒÒÒÇÇÇ»»»ÑÑÑÊÊÊÐÐÐÆÆÆÆÆÆÅÅÅÉÉÉÉÉÉÌÌÌÎÎÎÇÇǼ¼¼ÂÂÂÐÐÐÑÑÑÅÅÅÀÀÀ¿¿¿¿¿¿»»»¸¸¸ÀÀÀÍÍÍÊÊÊÂÂÂÀÀÀÆÆÆÌÌÌÊÊÊÊÊÊÍÍÍèèèâââßßßàààãããèèèëëëêêêäääàààÕÕÕÜÜÜäääÌÌ̯¯¯¯¯¯±±±µµµÀÀÀµµµ³³³···µµµÂÂÂÂÂÂÅÅÅÊÊÊÎÎÎÎÎÎÍÍÍÊÊÊàààÌÌÌ······Â¿¿¿»»»ÃÃÃÇÇÇÆÆÆÌÌÌÕÕÕ×××ÕÕÕÔÔÔÕÕÕñññíííêêêëëëçççàààßßßààààààÙÙÙÜÜÜÒÒÒ×××ÜÜÜÌÌÌÅÅÅÛÛÛÙÙÙÌÌÌÊÊÊÅÅÅÍÍÍÑÑÑâââäääçççæææßßßØØØÕÕÕÒÒÒÐÐÐÌÌÌÎÎÎÑÑÑÑÑÑÎÎÎÉÉÉÃÃÃÀÀÀ¿¿¿¿¿¿ÀÀÀ¿¿¿»»»¼¼¼ÂÂÂÑÑÑÇÇÇÀÀÀÅÅÅÉÉÉÊÊÊÉÉÉÇÇÇÊÊÊÍÍÍÎÎÎÍÍÍÊÊÊÃÃõµµ©©©­­­³³³»»»ÃÃÃÇÇÇÉÉÉÇÇÇÆÆÆÅÅÅÇÇÇÇÇÇÇÇÇÇÇÇÉÉÉÉÉÉÉÉÉÒÒÒ××××××ãããßßßæææçççïïïïïïëëëÿÿÿòòòÇÇÇÉÉÉãããàààÂÂÂÀÀÀÊÊÊÒÒÒÑÑÑÐÐÐÒÒÒÐÐÐÌÌÌÌÌÌÉÉÉÎÎÎÊÊÊ»»»ÕÕÕÍÍÍÇÇÇÎÎÎÊÊÊÂÂÂÆÆÆÇÇÇÆÆÆÊÊÊÇÇÇÇÇÇÇÇÇÇÇÇÇÇÇÉÉÉÊÊÊÌÌÌÌÌÌÉÉÉÆÆÆ¿¿¿¾¾¾¼¼¼¼¼¼ººº¸¸¸¸¸¸¸¸¸ººº¼¼¼¿¿¿ÀÀÀÆÆÆÂÂÂÊÊÊÎÎÎÍÍÍÔÔÔÕÕÕÆÆÆÛÛÛÝÝÝ××××××ÎÎÎÃÃÃÔÔÔæææíííëëëçççààààààæææçççäääïïïãããØØØØØØÛÛÛØØØÎÎÎÇÇǼ¼¼ÒÒÒÍÍÍÒÒÒÉÉÉÉÉÉÇÇÇÌÌÌÎÎÎÊÊÊÇÇÇÃÃÿ¿¿ÆÆÆÊÊʺººÆÆÆÍÍÍÍÍÍÐÐÐÕÕÕÑÑÑÆÆÆÌÌÌÆÆÆÅÅÅÍÍÍÙÙÙÝÝÝÜÜÜÙÙÙÝÝÝçççíííêêêææææææèèèêêêàààäääÛÛÛÙÙÙßßßÌÌ̱±±¬¬¬±±±¬¬¬­­­¯¯¯¬¬¬°°°···´´´ººº¼¼¼ÂÂÂÃÃÃÅÅÅÇÇÇÌÌÌÐÐÐÑÑÑÒÒÒÑÑÑÑÑÑÎÎμ¼¼ÆÆÆÂÂÂÇÇÇÐÐÐÔÔÔÐÐÐÍÍÍÕÕÕàààïïïçççæææïïïøøøöööîîîèèèÝÝÝÝÝÝãããÛÛÛ×××ØØØÊÊÊÆÆÆßßß×××ÊÊÊÆÆÆÂÂÂÔÔÔâââæææÛÛÛàààãããßßßÜÜÜÙÙÙÕÕÕÑÑÑÐÐÐÑÑÑÑÑÑÑÑÑÐÐÐÌÌÌÇÇÇÃÃÃÂÂÂÀÀÀÂÂÂÃÃÿ¿¿¸¸¸···ºººÂ¼¼¼¼¼¼ÅÅÅÍÍÍÎÎÎÎÎÎÎÎÎÒÒÒÑÑÑÑÑÑÐÐÐÊÊÊ¿¿¿···³³³±±±···¾¾¾ÃÃÃÉÉÉÊÊÊÊÊÊÉÉÉÆÆÆÊÊÊÊÊÊÅÅÅÆÆÆÍÍÍÎÎÎÊÊÊÜÜÜàààÝÝÝâââàààîîîòòòöööñññòòòÿÿÿëëëÀÀÀÀÀÀÑÑÑ¿¿¿ÅÅÅÎÎÎÐÐÐÍÍÍÒÒÒ×××ÒÒÒÐÐÐÇÇÇÌÌÌÒÒÒººº¼¼¼ÅÅÅÌÌÌÌÌÌÍÍÍÇÇÇÂÂÂÅÅÅÇÇÇÇÇÇÉÉÉÇÇÇÆÆÆÆÆÆÆÆÆÇÇÇÉÉÉÊÊÊÊÊÊÉÉÉÇÇÇÅÅÅ¿¿¿¼¼¼¼¼¼»»»¸¸¸¸¸¸¸¸¸¸¸¸ººº¼¼¼¿¿¿ÀÀÀÆÆÆÀÀÀÃÃÃÎÎÎÕÕÕÒÒÒÍÍÍÊÊÊ¿¿¿ØØØÐÐÐÐÐÐ×××ÇÇÇÆÆÆÔÔÔçççíííêêêßßßÛÛÛàààæææêêêïïïäää×××ÑÑÑ×××ÜÜÜ×××ÍÍÍ¿¿¿ÕÕÕÎÎÎÕÕÕÌÌÌÌÌÌÊÊÊÍÍÍÑÑÑÉÉÉÆÆÆÅÅÅÃÃÃÉÉÉÇÇǾ¾¾ÊÊÊÍÍÍÇÇÇÀÀÀÅÅÅÐÐÐÎÎÎÃÃÃÀÀÀÆÆÆÍÍÍ×××àààççççççâââæææííííííçççæææèèèèèèçççÝÝÝçççâââÜÜÜäääßßßÑÑÑÍÍÍÊÊʵµµªªª¯¯¯»»»ÆÆÆÅÅÅ···±±±¸¸¸ÀÀÀÅÅÅÅÅÅÅÅÅÅÅÅÃÃÃÌÌÌÒÒÒÕÕÕÙÙÙßßß×××ÇÇÇÂÂÂÂÂÂÇÇÇÐÐÐÔÔÔÔÔÔÔÔÔÝÝÝêêêçççÝÝÝÙÙÙâââñññúúúüüüúúúüüüóóóîîîàààØØØÕÕÕÉÉÉÅÅÅ×××ÒÒÒÌÌÌÇÇǾ¾¾ÑÑÑêêêãããÙÙÙÝÝÝßßßÛÛÛÙÙÙÙÙÙØØØÒÒÒÑÑÑÐÐÐÐÐÐÎÎÎÎÎÎÌÌÌÉÉÉÆÆÆ¿¿¿¿¿¿ÀÀÀÃÃü¼¼»»»¿¿¿¾¾¾¼¼¼¿¿¿ÉÉÉÎÎÎÎÎÎÌÌÌÍÍÍÒÒÒÍÍÍÊÊÊÉÉÉÃÃúºº¸¸¸¾¾¾ººº¼¼¼ÀÀÀÆÆÆÉÉÉÊÊÊÊÊÊÊÊÊÅÅÅÇÇÇÇÇÇÇÇÇÍÍÍÕÕÕØØØ×××àààßßßÝÝÝâââæææïïïõõõùùùüüüüüüçççÎÎÎÌÌÌÑÑÑÍÍÍÉÉÉÑÑÑÐÐÐÐÐÐÐÐÐÒÒÒ×××ÕÕÕÐÐÐÒÒÒÌÌÌÒÒÒ×××»»»ÐÐо¾¾ÍÍÍÑÑÑÍÍÍÅÅÅÂÂÂÅÅÅÇÇÇÇÇÇÆÆÆÆÆÆÅÅÅÅÅÅÅÅÅÆÆÆÇÇÇÉÉÉÉÉÉÆÆÆÅÅÅÃÃÃÀÀÀ¿¿¿¼¼¼»»»ººº¸¸¸¸¸¸¸¸¸¸¸¸ººº¼¼¼¿¿¿ÀÀÀÆÆÆÂÂÂÀÀÀÍÍÍ×××ÍÍÍÇÇÇÒÒÒÃÃÃÜÜÜÛÛÛØØØÙÙÙÐÐÐÇÇÇÀÀÀäääíííèèèÜÜÜÛÛÛßßßàààããããããàààÙÙÙÔÔÔ×××ÜÜÜØØØÎÎÎÀÀÀ×××ÐÐÐÕÕÕÌÌÌÌÌÌÊÊÊÎÎÎÐÐÐÊÊÊÌÌÌÊÊÊÃÃÃÆÆÆÊÊÊÆÆÆÊÊÊÀÀÀ¾¾¾ÃÃÃÅÅÅ¿¿¿¼¼¼¾¾¾ÊÊÊÙÙÙäääãããÝÝÝÝÝÝßßßÝÝÝâââäääãããæææëëëèèèãããäääíííòòòêêêâââæææäääàààãããÛÛÛÑÑÑÐÐÐÎÎÎÌÌÌÎÎÎÒÒÒÍÍÍ°°°µµµººº¾¾¾ÅÅÅÊÊÊÌÌÌÉÉÉÊÊÊÍÍÍÇÇÇÍÍÍßßßäääÕÕÕÉÉÉÉÉÉÉÉÉÊÊÊ×××æææèèèæææèèèÜÜÜ×××ÒÒÒÔÔÔÜÜÜæææîîîòòòëëëäääâââãããèèèæææÕÕÕÇÇÇÉÉÉÍÍÍÐÐÐÊÊʼ¼¼ÇÇÇçççÜÜÜààààààÜÜÜÔÔÔÑÑÑÒÒÒÑÑÑÎÎÎÉÉÉÉÉÉÉÉÉÇÇÇÆÆÆÅÅÅÃÃÃÂÂÂÂÂÂÀÀÀÀÀÀÃÃÿ¿¿ÂÂÂÆÆÆÃÃÃÃÃÃÇÇÇÑÑÑÔÔÔÑÑÑÎÎÎÐÐÐÅÅÅÂÂÂÂÂÂÃÃÿ¿¿ººº»»»ÂÂÂÂÂÂÃÃÃÅÅÅÇÇÇÉÉÉÉÉÉÉÉÉÉÉÉÆÆÆÅÅÅÉÉÉÑÑÑ×××ÙÙÙÝÝÝããããããÛÛÛÜÜÜçççïïïïïïóóóúúúîîîäääÎÎÎÅÅÅÐÐÐ×××ÕÕÕÙÙÙÕÕÕÒÒÒÔÔÔØØØÛÛÛÕÕÕÍÍÍÌÌÌÊÊÊÊÊÊÇÇÇÃÃü¼¼ØØظ¸¸ÇÇÇÔÔÔÌÌÌÅÅÅÃÃÃÅÅÅÆÆÆÆÆÆÅÅÅÃÃÃÃÃÃÃÃÃÃÃÃÅÅÅÅÅÅÆÆÆÇÇÇÅÅÅÃÃÃÂÂÂÀÀÀ¿¿¿¼¼¼»»»ººº¸¸¸¸¸¸···¸¸¸ººº»»»¾¾¾¿¿¿ÃÃÃÅÅÅÂÂÂÉÉÉÑÑÑÇÇÇÆÆÆÛÛÛÌÌÌÐÐÐ×××ßßß×××ÐÐÐÐÐм¼¼ÛÛÛíííëëëßßßÜÜÜÜÜÜØØØÛÛÛâââçççæææÝÝÝ××××××ÕÕÕÑÑÑÀÀÀ×××ÑÑÑ×××ÍÍÍÍÍÍÌÌÌÎÎÎÑÑÑÊÊÊÊÊÊÉÉÉÂÂÂÂÂÂÇÇÇÇÇÇÉÉÉÂÂÂÉÉÉÛÛÛßßßÒÒÒÑÑÑÜÜÜÒÒÒÛÛÛÙÙÙÊÊÊ»»»···¸¸¸ºººÅÅÅÎÎÎÜÜÜîîîõõõæææÜÜÜæææííííííæææâââàààÛÛÛÙÙÙàààâââÝÝÝàààÜÜÜÒÒÒÒÒÒÙÙÙÙÙÙ××××××ÍÍÍ¿¿¿···ººº¿¿¿ÂÂÂÃÃÃÍÍÍÌÌÌÊÊÊÕÕÕÝÝÝÝÝÝÜÜÜÍÍÍÍÍÍÌÌÌÛÛÛïïïîîîßßßÛÛÛÕÕÕÕÕÕÕÕÕ×××ÛÛÛÝÝÝÝÝÝÜÜÜ×××ÒÒÒÎÎÎ×××àààßßßØØØÎÎÎÀÀÀÍÍÍÒÒÒÍÍ;¾¾¿¿¿ãããÙÙÙÝÝÝÜÜÜÕÕÕÎÎÎÍÍÍÐÐÐÐÐÐÍÍÍÅÅÅÇÇÇÉÉÉÇÇÇÅÅÅÃÃÃÃÃÃÃÃÃÆÆÆÃÃÃÃÃÃÅÅÅÃÃÃÀÀÀÃÃÃÊÊÊÃÃÃÃÃÃÉÉÉÐÐÐÐÐÐÌÌÌÊÊÊÍÍÍÀÀÀÃÃÃÇÇÇÍÍÍÌÌÌÇÇÇÇÇÇÊÊÊÉÉÉÉÉÉÇÇÇÇÇÇÇÇÇÇÇÇÉÉÉÉÉÉÊÊÊÉÉÉÐÐÐÛÛÛÝÝÝÛÛÛÝÝÝäääæææÙÙÙßßßíííúúúóóóöööúúúêêêÍÍÍÉÉÉÔÔÔÒÒÒØØØÝÝÝÒÒÒÑÑÑÒÒÒÒÒÒÔÔÔÔÔÔÎÎÎÍÍÍÕÕÕÕÕÕÎÎÎÀÀÀ···ÀÀÀÐÐеµµÀÀÀÕÕÕÊÊÊÆÆÆÆÆÆÅÅÅÅÅÅÆÆÆÃÃÃÂÂÂÀÀÀÀÀÀÀÀÀÂÂÂÃÃÃÅÅÅÅÅÅÃÃÃÃÃÃÂÂÂÀÀÀ¿¿¿¼¼¼»»»ººº¸¸¸·········¸¸¸»»»¾¾¾¿¿¿ÂÂÂÆÆÆÃÃÃÅÅÅÊÊÊÇÇÇÊÊÊÙÙÙÎÎξ¾¾ÅÅÅÛÛÛÒÒÒÊÊÊÔÔÔÆÆÆÂÂÂâââíííãããààààààßßßæææßßßääääääÝÝÝÔÔÔÑÑÑÕÕÕØØØÂÂÂØØØÑÑÑØØØÍÍÍÎÎÎÌÌÌÐÐÐÒÒÒÇÇÇÅÅÅÆÆÆÂÂÂÂÂÂÆÆÆÃÃÃØØØÔÔÔÐÐÐÍÍÍÉÉÉÃÃÃÃÃÃÉÉÉâââÛÛÛÌÌ̾¾¾···»»»¿¿¿Â¼¼¼ÂÂÂÉÉÉßßßõõõîîîäääíííääääääãããäääààà×××ÒÒÒ×××æææÛÛÛØØØÙÙÙÙÙÙßßßãããÝÝÝàààçççãããÐÐо¾¾»»»¾¾¾¿¿¿ÀÀÀÎÎÎÑÑÑÎÎÎÔÔÔÙÙÙÝÝÝäääÇÇÇÐÐÐÒÒÒÝÝÝëëëâââÑÑÑÑÑÑ×××ÕÕÕÕÕÕÛÛÛäääíííêêêâââçççãããÕÕÕÒÒÒÎÎÎÉÉÉÐÐÐÑÑÑÂÂÂÎÎÎÑÑÑÌÌ̼¼¼ãããÝÝÝÕÕÕÕÕÕÑÑÑÍÍÍÍÍÍÐÐÐÍÍÍÇÇÇÂÂÂÇÇÇÌÌÌÊÊÊÆÆÆÂÂÂÃÃÃÆÆÆÅÅÅÂÂÂÂÂÂÅÅÅÃÃÃÂÂÂÆÆÆÌÌÌÍÍÍÌÌÌÍÍÍÍÍÍÇÇǾ¾¾»»»¾¾¾ÇÇÇÌÌÌÐÐÐÐÐÐÐÐÐÒÒÒÒÒÒÑÑÑÌÌÌÊÊÊÉÉÉÇÇÇÇÇÇÇÇÇÊÊÊÌÌÌÆÆÆÍÍÍØØØßßßßßßÜÜÜÝÝÝâââãããÛÛÛãããêêêüüüøøøúúúøøøëëëÐÐÐÊÊÊÒÒÒÒÒÒ×××ÛÛÛÒÒÒÐÐÐÕÕÕÑÑÑÌÌÌÑÑÑÔÔÔÕÕÕÛÛÛâââÑÑÑÆÆÆÂÂÂÕÕÕÊÊÊÅÅÅÉÉÉÕÕÕÉÉÉÇÇÇÊÊÊÅÅÅÃÃÃÅÅÅ¿¿¿¿¿¿¿¿¿¿¿¿¿¿¿ÀÀÀÂÂÂÃÃÿ¿¿¾¾¾»»»ººº············¸¸¸»»»¾¾¾¿¿¿ÀÀÀÅÅÅÃÃÃÀÀÀÇÇÇÐÐÐÑÑÑÐÐÐÛÛÛÔÔÔÊÊÊÑÑÑÒÒÒÎÎÎÑÑÑÇÇǵµµÙÙÙçççãããèèèëëëèèèîîîàààââââââßßßØØØÒÒÒÔÔÔÛÛÛÅÅÅÛÛÛÔÔÔÙÙÙÐÐÐÐÐÐÎÎÎÒÒÒÌÌÌÅÅÅÉÉÉÌÌÌÆÆÆÆÆÆÌÌÌÎÎÎÔÔÔ×××ÔÔÔÐÐÐÐÐÐÒÒÒÍÍÍÅÅÅÆÆƼ¼¼³³³³³³···¾¾¾ÅÅÅÊÊÊÍÍÍÊÊÊ¿¿¿ÉÉÉêêêöööîîîëëëèèèêêêèèèâââÙÙÙÕÕÕÑÑÑÍÍÍØØØÙÙÙâââãããÛÛÛÝÝÝæææçççàààèèèëëëâââØØØÎÎο¿¿°°°¿¿¿ÉÉÉÌÌÌÍÍÍ×××ÛÛÛÝÝÝäääÂÂÂÐÐÐÕÕÕÜÜÜäääÙÙÙÍÍÍ×××ØØØÛÛÛÝÝÝâââêêêóóóòòòíííäääçççàààãããÛÛÛÍÍÍÐÐÐÎÎÎÉÉÉÑÑÑÎÎÎÇÇÇÆÆÆ¿¿¿æææãããÕÕÕ×××ÔÔÔÐÐÐÍÍÍÌÌÌÅÅÅ»»»ºººÀÀÀÇÇÇÆÆÆÀÀÀ¼¼¼¾¾¾Â¿¿¿¾¾¾ÀÀÀÅÅÅÅÅÅÅÅÅÇÇÇÎÎÎÌÌÌÊÊÊÍÍÍÎÎÎÊÊÊÃÃÃÅÅÅÉÉÉÌÌÌÍÍÍÊÊÊÅÅÅÅÅÅÍÍÍÑÑÑÐÐÐÌÌÌÊÊÊÇÇÇÆÆÆÇÇÇÉÉÉÌÌÌÍÍ;¾¾ÎÎÎÜÜÜßßßÝÝÝààààààßßßÝÝÝÛÛÛããããããøøøøøøüüüñññÆÆÆÐÐÐÍÍÍÐÐÐÝÝÝÕÕÕÌÌÌ×××ÎÎÎØØØÒÒÒÎÎÎÜÜÜæææÛÛÛÐÐÐÍÍ͵µµ···ÃÃÃÛÛÛ¼¼¼ÊÊÊÊÊÊÕÕÕÉÉÉÉÉÉÌÌÌÅÅÅÂÂÂÃÃÃÀÀÀ¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¿¿¿ÀÀÀÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÀÀÀ¾¾¾»»»ººº············¸¸¸»»»¾¾¾¿¿¿ÂÂÂÃÃÃÀÀÀ¾¾¾ÇÇÇ×××ÕÕÕÇÇÇÉÉÉÛÛÛÅÅŸ¸¸ÌÌÌÕÕÕÑÑÑÆÆÆÀÀÀÝÝÝæææâââïïïóóóèèèæææïïïíííííííííæææØØØÒÒÒÔÔÔÆÆÆÜÜÜ×××ÜÜÜÒÒÒÒÒÒÑÑÑÕÕÕ¿¿¿ÃÃÃÒÒÒØØØÌÌÌÉÉÉ×××ãããÎÎÎÎÎÎÉÉÉÅÅÅÆÆÆÆÆƺºº¨¨¨¬¬¬©©©­­­µµµººº»»»ÀÀÀÉÉÉÐÐÐØØØÌÌÌÇÇÇãããõõõíííæææÝÝÝâââßßßÒÒÒÎÎÎÙÙÙÝÝÝ×××ÎÎÎÔÔÔâââèèèâââßßßàààÝÝÝ×××ÙÙÙÛÛÛßßßêêêëëëÔÔÔ¸¸¸···ÀÀÀÆÆÆÊÊÊÒÒÒ×××ÝÝÝêêêÀÀÀÎÎÎÒÒÒØØØäääÜÜÜÕÕÕàààÕÕÕäääññññññîîîêêêäääßßßæææäääÛÛÛâââßßßÐÐÐÑÑÑÊÊÊàààÌÌÌÍÍÍÊÊÊÇÇÇÔÔÔÛÛÛæææÔÔÔÜÜÜÒÒÒÔÔÔÙÙÙÎÎÎÅÅż¼¼ÇÇÇÆÆÆÅÅÅÅÅÅÃÃÃÃÃÃÃÃÃÅÅÅÃÃÃÀÀÀ»»»¿¿¿ÉÉÉÉÉÉÇÇÇÎÎÎÍÍÍÌÌÌÎÎÎÌÌÌ¿¿¿µµµ»»»ÆÆÆÍÍÍÑÑÑÐÐÐÉÉÉÇÇÇÌÌÌÐÐÐÐÐÐÑÑÑÌÌÌÍÍÍÃÃÃÊÊÊÅÅÅÍÍÍÌÌÌëëëãããÜÜÜÜÜÜàààãããàààÛÛÛßßßæææâââñññòòòóóóÿÿÿäääÍÍÍÑÑÑ×××ÙÙÙ×××ÒÒÒÎÎÎÌÌÌÐÐÐÌÌÌÉÉÉÔÔÔÊÊÊØØØ°°°¼¼¼···µµµÆÆÆÝÝÝÆÆƺººÐÐÐÆÆÆÝÝÝÐÐÐÅÅÅÃÃÃÅÅÅÆÆÆÅÅÅ¿¿¿¾¾¾¾¾¾¼¼¼¼¼¼¼¼¼¿¿¿ÀÀÀÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÀÀÀ¿¿¿¾¾¾ººº¸¸¸¸¸¸ººº»»»¼¼¼¾¾¾¾¾¾ÀÀÀÅÅÅÂÂÂÆÆÆÉÉÉÒÒÒÜÜÜÌÌÌÕÕÕÉÉÉÉÉɾ¾¾ÒÒÒÎÎÎÇÇÇÊÊÊÀÀÀ···°°°±±±¼¼¼ÍÍÍãããõõõòòòõõõïïïïïïâââßßßÑÑÑÕÕÕÊÊÊÛÛÛßßßÛÛÛÜÜÜØØØÒÒÒÔÔÔÅÅÅÃÃÃÉÉÉÃÃÃÃÃÃàààêêêÎÎγ³³ÅÅÅ···°°°©©©µµµ¯¯¯¬¬¬±±±°°°­­­°°°´´´ººº¿¿¿ÆÆÆÒÒÒÑÑÑÃÃÃÍÍÍæææööööööÜÜÜäääÜÜÜØØØÛÛÛÜÜÜÙÙÙØØØÛÛÛÒÒÒÙÙÙçççÜÜÜÜÜÜæææÙÙÙÒÒÒçççêêêèèèääääääçççäääÝÝݸ¸¸···¿¿¿ÍÍÍÑÑÑÒÒÒÜÜÜêêê¿¿¿ÊÊÊÑÑÑÜÜÜíííëëëßßßÛÛÛßßßëëëïïïçççäääèèèæææÝÝÝçççÝÝÝâââÕÕÕØØØÒÒÒ×××ÆÆÆÔÔÔÉÉÉÀÀÀ¸¸¸ÂÂÂÙÙÙÜÜÜÒÒÒÍÍÍÙÙÙÑÑÑÑÑÑÎÎÎÂÂÂÀÀÀÀÀÀÇÇÇÇÇÇÆÆÆÆÆÆÅÅÅÃÃÃÂÂÂÂÂÂÆÆÆÅÅÅ¿¿¿ÅÅÅÎÎÎÌÌÌÇÇÇÍÍÍÌÌÌÎÎÎÎÎÎÉÉÉ¿¿¿ººº¿¿¿ÉÉÉÎÎÎÑÑÑÐÐÐÉÉÉÇÇÇÊÊÊÎÎÎÎÎÎÊÊÊÆÆÆÉÉÉÂÂÂÍÍÍÍÍÍÜÜÜàààãããßßßÜÜÜÝÝÝãããäääâââÝÝÝããããããßßßïïïïïïòòòóóóÇÇÇÍÍÍÑÑÑ×××ØØØÕÕÕÒÒÒÐÐÐÎÎÎÐÐÐÍÍÍÌÌÌÒÒÒÍÍÍÛÛÛµµµ¾¾¾¿¿¿¸¸¸ÆÆÆÒÒÒÆÆÆÆÆÆÑÑÑÀÀÀ×××ÔÔÔÊÊÊÃÃÃÂÂÂÀÀÀ»»»¸¸¸¾¾¾¼¼¼¼¼¼»»»¼¼¼¾¾¾ÀÀÀÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÀÀÀ¿¿¿¿¿¿ºººººººººººº»»»¼¼¼¾¾¾¿¿¿ÅÅÅÉÉÉÅÅÅÇÇÇÉÉÉÐÐÐ×××ÆÆÆÒÒÒÌÌÌÐÐÐÅÅÅÒÒÒÍÍÍÆÆÆÆÆƼ¼¼¸¸¸»»»¾¾¾ÀÀÀÇÇÇÐÐÐèèèóóóöööòòòäääèèèãããÝÝÝÒÒÒØØØßßßâââàààßßß×××ÌÌÌÊÊÊÌÌÌÔÔÔÔÔÔÔÔÔßßßÕÕÕ´´´¦¦¦­­­©©©¯¯¯ŸŸŸ¥¥¥¥¥¥ªªª°°°¯¯¯¯¯¯¯¯¯³³³···¼¼¼ÀÀÀÃÃÃÂÂÂÊÊÊäääõõõïïïèèèâââÜÜÜÝÝÝÛÛÛÕÕÕÕÕÕØØØÕÕÕÎÎÎÑÑÑÕÕÕßßßØØØØØØßßß×××ÕÕÕÔÔÔÕÕÕÔÔÔÕÕÕÝÝÝæææçççãããÐÐо¾¾µµµÂÂÂÎÎÎÔÔÔßßßîîîÊÊÊÊÊÊÑÑÑßßßèèèêêêäääÝÝÝßßßèèèîîîîîîîîîñññíííæææâââØØØØØØÎÎÎÐÐÐÐÐÐØØØÌÌÌÌÌÌÊÊʼ¼¼¾¾¾ÐÐÐßßßßßßÎÎÎÐÐÐØØØÐÐÐÐÐÐÍÍÍÃÃÃÇÇÇÊÊÊÅÅÅÅÅÅÆÆÆÆÆÆÆÆÆÅÅÅÅÅÅÅÅÅÉÉÉÉÉÉÅÅÅÉÉÉÑÑÑÎÎÎÉÉÉÌÌÌÍÍÍÑÑÑÐÐÐÆÆÆÀÀÀ¿¿¿ÅÅÅÌÌÌÐÐÐÑÑÑÐÐÐÉÉÉÇÇÇÊÊÊÍÍÍÍÍÍÌÌÌÊÊÊÑÑÑÊÊÊÒÒÒÑÑÑßßßâââÝÝÝÝÝÝÝÝÝàààããããããàààßßßââââââæææõõõóóóøøøóóó¿¿¿ÎÎÎÑÑÑÕÕÕÕÕÕÔÔÔÒÒÒÑÑÑÐÐÐÑÑÑÐÐÐÎÎÎÑÑÑÐÐÐÛÛÛ¼¼¼¿¿¿Â¾¾¾ÎÎÎÉÉÉÃÃÃÎÎÎÑÑÑ¿¿¿¿¿¿ÍÍÍÊÊÊ¿¿¿Â¼¼¼¿¿¿¼¼¼»»»»»»»»»»»»¼¼¼¿¿¿ÀÀÀÂÂÂÂÂÂÃÃÃÃÃÃÃÃÃÂÂÂÀÀÀÀÀÀ¼¼¼¼¼¼¼¼¼¼¼¼¼¼¼¾¾¾¿¿¿ÀÀÀÅÅÅÇÇÇÆÆÆÊÊÊÊÊÊÎÎÎÕÕÕÅÅÅÑÑÑÊÊÊÐÐÐÃÃÃÒÒÒÒÒÒÎÎÎÍÍÍÀÀÀ¾¾¾¿¿¿Â¾¾¾¼¼¼¾¾¾ÀÀÀ×××îîîîîîàààããããããÎÎÎÛÛÛÔÔÔÙÙÙßßßÜÜÜÝÝÝ×××ÃÃÃÐÐÐÌÌÌÅÅÅÃÃÃÎÎÎÝÝÝÝÝÝÒÒÒ¯¯¯©©©¯¯¯¼¼¼©©©¨¨¨©©©···±±±±±±±±±°°°±±±¸¸¸¾¾¾¾¾¾¿¿¿ÉÉÉàààòòòóóóêêêÝÝÝßßßßßßâââàààÛÛÛØØØØØØÒÒÒÊÊÊÍÍÍÎÎÎ×××ÔÔÔÔÔÔ×××ÔÔÔØØØØØØ×××ÒÒÒÔÔÔÜÜÜæææêêêçççíííÑÑÑ»»»¾¾¾ÌÌÌÒÒÒØØØâââ×××ÊÊÊÐÐÐÝÝÝàààäääêêêäää×××ÜÜÜæææîîîòòòñññíííèèèÝÝÝÝÝÝàààÒÒÒÍÍÍÌÌÌÛÛÛÛÛÛÅÅÅÃÃþ¾¾ÔÔÔäääÛÛÛÙÙÙ×××ÔÔÔÒÒÒÉÉÉÍÍÍÎÎÎÉÉÉÌÌÌÊÊÊÃÃÃÃÃÃÃÃÃÃÃÃÅÅÅÆÆÆÉÉÉÊÊÊÊÊÊÌÌÌÆÆÆÇÇÇÐÐÐÎÎÎÉÉÉÌÌÌÎÎÎ×××ÑÑÑÅÅÅÂÂÂÅÅÅÇÇÇÍÍÍÎÎÎÐÐÐÎÎÎÉÉÉÉÉÉÍÍÍÎÎÎÍÍÍÊÊÊÎÎÎÜÜÜØØØÝÝÝÔÔÔØØØ×××ßßßßßßàààââââââàààßßßÝÝÝÜÜÜàààîîîùùùñññõõõóóóÃÃÃÍÍÍÐÐÐÒÒÒÒÒÒÒÒÒÑÑÑÑÑÑÒÒÒÒÒÒÑÑÑÑÑÑÍÍÍÑÑÑÕÕÕ¾¾¾»»»¼¼¼ÂÂÂÜÜÜÅÅÅ¿¿¿ÐÐÐÎÎÎÀÀÀ¸¸¸ÒÒÒÑÑÑÀÀÀÀÀÀ¼¼¼µµµ»»»»»»»»»ººººººººº¼¼¼¾¾¾¿¿¿ÂÂÂÂÂÂÃÃÃÃÃÃÃÃÃÃÃÃÂÂÂÀÀÀ¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¿¿¿ÀÀÀÀÀÀ¿¿¿ÅÅÅÅÅÅÌÌÌÌÌÌÐÐÐ×××ÉÉÉÒÒÒÇÇÇÇÇÇ´´´ÂÂÂÉÉÉÉÉÉÅÅÅÊÊÊÆÆÆÆÆÆÉÉÉÉÉÉÅÅÅÅÅÅÇÇÇ···ÊÊÊçççñññãããàààèèèÕÕÕÝÝÝÔÔÔÑÑÑÑÑÑÑÑÑÒÒÒÎÎÎÃÃÃÔÔÔÑÑÑÃÃÃÂÂÂÐÐÐ×××ØØØÝÝÝÑÑÑÉÉÉÇÇÇÐÐо¾¾´´´¦¦¦´´´³³³±±±¯¯¯¨¨¨¥¥¥°°°¸¸¸´´´ßßßçççúúúöööîîîëëëâââäääæææâââßßßàààÛÛÛÑÑÑÌÌÌÍÍÍÊÊÊÉÉÉÐÐÐÔÔÔÔÔÔÑÑÑÒÒÒÙÙÙÛÛÛÙÙÙÕÕÕÒÒÒÒÒÒØØØßßßãããñññãããÍÍÍÅÅÅÌÌÌÒÒÒÒÒÒÕÕÕÝÝÝÎÎÎÌÌÌÔÔÔØØØßßßèèèîîîæææßßßÜÜÜàààâââßßßÝÝÝßßßÜÜÜÕÕÕÎÎÎÆÆÆÉÉÉÍÍÍÍÍÍÅÅÅ¿¿¿µµµ´´´×××äääÔÔÔÒÒÒÕÕÕÒÒÒÎÎÎÅÅÅÉÉÉÆÆƾ¾¾ÃÃÃÀÀÀÉÉÉÇÇÇÅÅÅÂÂÂÂÂÂÅÅÅÇÇÇÉÉÉÊÊÊÊÊÊÃÃÃÀÀÀÉÉÉÌÌÌÉÉÉÌÌÌÑÑÑÙÙÙÑÑÑÅÅÅÆÆÆÉÉÉÉÉÉÎÎÎÍÍÍÐÐÐÎÎÎÊÊÊÊÊÊÐÐÐÐÐÐÍÍÍÆÆÆÍÍÍÝÝÝÜÜÜâââ×××ÙÙÙ×××ßßßßßßàààààààààßßßàààâââßßßàààíííòòòèèèíííççç¾¾¾ÊÊÊÍÍÍÎÎÎÐÐÐÐÐÐÐÐÐÐÐÐÑÑÑÔÔÔÑÑÑÑÑÑÊÊÊÑÑÑÊÊʺºº···»»»ÂÂÂàààÀÀÀÃÃÃÑÑÑÊÊÊ¿¿¿¸¸¸ÒÒÒÒÒÒ¾¾¾···¾¾¾»»»»»»ººººººººº»»»¾¾¾¿¿¿ÀÀÀÂÂÂÃÃÃÃÃÃÃÃÃÃÃÃÂÂÂÂÂÂÀÀÀ¿¿¿¿¿¿¿¿¿¿¿¿ÀÀÀÀÀÀ¿¿¿ÃÃÃÅÅÅÌÌÌÌÌÌÎÎÎ×××ÌÌÌÇÇÇÆÆÆÎÎθ¸¸¾¾¾ÇÇÇÑÑÑÑÑÑÙÙÙÔÔÔÐÐÐÐÐÐÎÎÎÊÊÊÌÌÌÎÎÎÊÊÊÍÍÍÙÙÙîîîàààÝÝÝïïïëëëÙÙÙÙÙÙÒÒÒÎÎÎÐÐÐÊÊÊÅÅÅÇÇÇÔÔÔÕÕÕÎÎÎÍÍÍÔÔÔÐÐÐÌÌÌ×××××××××ÎÎÎÐÐÐÍÍÍÆÆƦ¦¦±±±±±±±±±´´´±±±µµµÎÎÎâââßßßîîîêêêñññèèèââââââÜÜÜäääâââÜÜÜØØØ×××ÑÑÑÉÉÉÆÆÆÊÊÊÉÉÉÇÇÇÌÌÌÕÕÕ×××ÐÐÐÒÒÒØØØÕÕÕ×××ØØØÔÔÔÎÎÎÑÑÑÝÝÝèèèàààêêêÝÝÝÉÉÉÊÊÊÔÔÔ×××ÙÙÙÛÛÛÔÔÔÉÉÉÇÇÇÐÐÐ×××ãããóóóõõõêêêãããäääçççèèèîîîøøøÜÜÜÜÜÜÔÔÔÑÑÑÑÑÑÔÔÔÌÌÌÅÅÅÀÀÀ±±±´´´ÎÎÎÛÛÛÙÙÙÙÙÙÑÑÑÕÕÕÒÒÒÍÍÍÎÎο¿¿³³³¾¾¾ÂÂÂÐÐÐÍÍÍÉÉÉÅÅÅÂÂÂÂÂÂÂÂÂÃÃÃÆÆÆÇÇǾ¾¾ºººÃÃÃÊÊÊÊÊÊÍÍÍÒÒÒØØØÎÎÎÆÆÆÌÌÌÌÌÌÉÉÉÑÑÑÐÐÐÑÑÑÎÎÎÌÌÌÍÍÍÑÑÑÑÑÑÍÍÍÐÐÐÑÑÑÜÜÜ×××ÝÝÝÕÕÕÛÛÛÙÙÙÛÛÛÜÜÜÝÝÝàààâââãããæææçççäääàààçççîîîîîîïïïàà྾¾ÅÅÅÇÇÇÌÌÌÍÍÍÍÍÍÍÍÍÎÎÎÐÐÐÒÒÒÎÎÎÑÑÑÇÇÇÑÑѾ¾¾···µµµ¼¼¼¿¿¿ØØØ»»»ÊÊÊÑÑÑÇÇǼ¼¼»»»ÍÍÍÌÌÌÂÂÂÂÂÂÀÀÀ¾¾¾ÅÅÅ»»»»»»ººººººººº¼¼¼¾¾¾¿¿¿ÀÀÀÀÀÀÂÂÂÃÃÃÃÃÃÃÃÃÂÂÂÂÂÂÂÂÂÀÀÀÀÀÀ¿¿¿¿¿¿ÀÀÀÀÀÀÂÂÂÂÂÂÅÅÅÅÅÅÍÍÍÌÌÌÌÌÌÔÔÔÌÌ̼¼¼ÉÉÉÝÝÝÃÃû»»ÀÀÀÐÐÐÒÒÒØØØÔÔÔÒÒÒÔÔÔÒÒÒÎÎÎÎÎÎÑÑÑÐÐÐÊÊÊÆÆÆíííâââÜÜÜæææêêêØØØÝÝÝÛÛÛØØØØØØÍÍÍÃÃÃÊÊÊÒÒÒÔÔÔÍÍÍÌÌÌÑÑÑÎÎÎÎÎÎÛÛÛÐÐÐÕÕÕÐÐÐÎÎÎÕÕÕÒÒÒ¨¨¨°°°±±±±±±³³³¬¬¬­­­ÊÊÊàààÙÙÙãããâââàààÙÙÙÛÛÛãããßßßÛÛÛÛÛÛÝÝÝÙÙÙÐÐÐÊÊÊÌÌÌÍÍÍÊÊÊÉÉÉÊÊÊÉÉÉÔÔÔ×××ÒÒÒ××××××ÕÕÕØØØÛÛÛØØØÑÑÑÐÐÐÜÜÜêêêßßßîîîàààÆÆÆÅÅÅÐÐÐÔÔÔÙÙÙ×××ØØØÌÌÌÂÂÂÉÉÉÑÑÑÛÛÛíííúúúöööóóóõõõïïïæææÝÝÝÝÝÝÅÅÅÔÔÔÕÕÕÑÑÑÃÃÃÀÀÀ¾¾¾ÃÃþ¾¾±±±ÃÃÃÔÔÔÕÕÕààààààÑÑÑ×××ÑÑÑÌÌÌÍÍÍ¿¿¿´´´ÅÅÅÌÌÌÍÍÍÌÌÌÊÊÊÇÇÇÅÅÅÃÃÃÂÂÂÀÀÀÂÂÂÃÃû»»···ÀÀÀÊÊÊÌÌÌÎÎÎÐÐÐÔÔÔÊÊÊÇÇÇÑÑÑÎÎÎÊÊÊÕÕÕÔÔÔÔÔÔÑÑÑÎÎÎÎÎÎÑÑÑÎÎÎÊÊÊÜÜÜÙÙÙÝÝÝÕÕÕÛÛÛÔÔÔÙÙÙØØØÙÙÙÛÛÛßßßâââæææççççççæææäääãããêêêòòòóóóëëëÔÔÔ¾¾¾ÀÀÀÃÃÃÇÇÇÊÊÊÊÊÊÊÊÊÌÌÌÍÍÍÑÑÑÊÊÊÑÑÑÉÉÉÔÔÔ´´´µµµ¸¸¸¼¼¼¾¾¾ÒÒÒºººÍÍÍÇÇÇÃÃÃÂÂÂÎÎÎÎÎÎÉÉɾ¾¾¼¼¼»»»¼¼¼¼¼¼»»»ºººººº»»»¼¼¼¾¾¾¿¿¿¿¿¿¿¿¿ÀÀÀÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÀÀÀ¿¿¿¿¿¿ÀÀÀÀÀÀÀÀÀÂÂÂÃÃÃÃÃÃÌÌÌÊÊÊÊÊÊÕÕÕÎÎÎÀÀÀÌÌÌßßß¿¿¿°°°´´´¿¿¿»»»ÒÒÒÐÐÐÑÑÑÔÔÔÕÕÕÒÒÒÒÒÒÕÕÕÒÒÒÑÑÑÂÂÂøøøñññëëëãããæææßßßÝÝÝÝÝÝÝÝÝÛÛÛÑÑÑÊÊÊÌÌÌ×××ÔÔÔÎÎÎÐÐÐÔÔÔÑÑÑÌÌÌÌÌÌ×××ÙÙÙÙÙÙÙÙÙØØØÐÐС¡¡©©©°°°±±±´´´¯¯¯°°°ÑÑÑêêêàààãããçççâââßßßäääêêêçççØØØØØØÛÛÛØØØÐÐÐÌÌÌÎÎÎÑÑÑÐÐÐÌÌÌÍÍÍÆÆÆÐÐÐÕÕÕÒÒÒÙÙÙÕÕÕÕÕÕÕÕÕ×××ÕÕÕÑÑÑÎÎÎ×××àààæææêêêÔÔÔÀÀÀÆÆÆÌÌÌÊÊÊÑÑÑÒÒÒÙÙÙ×××ÉÉÉÅÅÅÌÌÌ×××ßßß×××ÛÛÛàààäääàààØØØÑÑÑÎÎÎÒÒÒÜÜÜÑÑÑÎÎÎÆÆÆÉÉɾ¾¾ÀÀÀ³³³ªªªÐÐÐàààÔÔÔÛÛÛÜÜÜÑÑÑÑÑÑÅÅÅ»»»Â»»»¸¸¸ÉÉÉÍÍÍÆÆÆÇÇÇÉÉÉÉÉÉÉÉÉÆÆÆÅÅÅÃÃÿ¿¿ÂºººµµµÂÂÂÌÌÌÎÎÎÐÐÐÍÍÍÐÐÐÇÇÇÉÉÉÕÕÕÑÑÑÌÌÌÙÙÙØØØØØØÔÔÔÐÐÐÎÎÎÐÐÐÍÍÍÇÇÇÝÝÝÙÙÙÝÝÝÕÕÕÝÝÝ×××ÜÜÜÙÙÙÜÜÜÝÝÝâââæææèèèçççäääàààßßßçççñññóóóîîî×××»»»°°°¾¾¾ÂÂÂÆÆÆÉÉÉÉÉÉÉÉÉÉÉÉÊÊÊÑÑÑÉÉÉÐÐÐÉÉÉÕÕÕ°°°µµµ¾¾¾¸¸¸¿¿¿ÒÒÒ»»»ÊÊÊ»»»ÂÂÂÌÌÌÑÑÑÇÇÇÀÀÀ¿¿¿¼¼¼¾¾¾ÀÀÀ¿¿¿¼¼¼»»»»»»ººº»»»¼¼¼¿¿¿ÀÀÀ¾¾¾¿¿¿ÀÀÀÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÀÀÀ¿¿¿¿¿¿¿¿¿ÀÀÀÀÀÀ¾¾¾¿¿¿ÀÀÀÊÊÊÊÊÊÍÍÍÙÙÙÕÕÕÇÇÇÊÊÊØØؼ¼¼¼¼¼ÌÌÌØØØÎÎÎØØØÔÔÔÑÑÑÒÒÒÒÒÒÐÐÐÒÒÒ×××ØØØÙÙÙ¼¼¼öööòòòóóóäääçççèèèÛÛÛÙÙÙÜÜÜÕÕÕÒÒÒÑÑÑÌÌÌÙÙÙÐÐÐÉÉÉÊÊÊÒÒÒ×××ÒÒÒÌÌÌÉÉÉÇÇÇÕÕÕßßßØØØÐÐШ¨¨³³³­­­°°°µµµ¯¯¯°°°ÔÔÔëëëàààçççßßßÔÔÔãããæææÕÕÕÒÒÒÍÍÍÒÒÒÎÎÎÎÎÎÎÎÎÌÌÌÆÆÆÉÉÉÐÐÐÎÎÎÎÎÎÃÃÃÊÊÊÑÑÑÒÒÒÜÜÜÔÔÔÛÛÛØØØØØØÜÜÜßßßßßßãããèèèäääÜÜÜÃÃü¼¼ÍÍÍÐÐÐÇÇÇÎÎÎÑÑÑÙÙÙßßßÒÒÒÂÂÂÉÉÉÕÕÕÒÒÒ××××××ÕÕÕÔÔÔÕÕÕÜÜÜæææíííØØØßßßÎÎÎÇÇǾ¾¾ÀÀÀµµµ»»»°°°­­­ÑÑÑØØØÔÔÔàààÔÔÔÊÊÊÀÀÀÉÉÉÉÉÉ»»»ÅÅÅÐÐÐÇÇÇÇÇÇÉÉÉÊÊÊÊÊÊÉÉÉÆÆÆÅÅÅÃÃÃÅÅÅÆÆÆ»»»´´´¸¸¸ÇÇÇÐÐÐÇÇÇ»»»ÀÀÀÂÂÂÉÉÉÒÒÒ×××ÔÔÔÒÒÒÕÕÕÕÕÕÕÕÕÎÎÎÔÔÔÒÒÒÉÉÉÊÊÊÆÆÆÙÙÙÝÝÝââââââàààÝÝÝÜÜÜÜÜÜàààâââãããææææææääääääæææßßßøøøòòòñññêêêÝÝݼ¼¼ººº¼¼¼ÂÂÂÇÇÇÇÇÇÆÆÆÅÅÅÉÉÉÌÌÌÐÐÐÎÎÎÑÑÑ××׺ºº´´´¸¸¸ÅÅÅÙÙÙÑÑÑÂÂÂÐÐÐÅÅŵµµÐÐÐØØØÕÕÕÆÆÆÂÂÂÀÀÀ¼¼¼¿¿¿ÃÃü¼¼ºººººº»»»¼¼¼¼¼¼¾¾¾¿¿¿¿¿¿¿¿¿¿¿¿¿¿¿¿¿¿¿¿¿ÂÂÂÃÃÃÅÅÅÂÂÂÀÀÀ¾¾¾¼¼¼¼¼¼¿¿¿ÂÂÂÃÃÿ¿¿ÌÌÌÊÊÊÊÊÊÛÛÛÒÒÒºººÌÌÌÔÔÔ¿¿¿ÝÝÝÊÊÊÑÑÑÍÍÍÕÕÕÕÕÕÑÑÑÒÒÒÎÎÎÌÌÌÔÔÔÙÙÙÔÔÔÍÍÍîîîëëëøøøäääææææææ×××ÝÝÝÜÜÜÝÝÝÍÍÍÐÐÐÊÊÊÎÎÎÕÕÕÒÒÒÆÆÆÂÂÂÌÌÌÑÑÑÎÎÎÒÒÒÂÂÂÅÅÅÐÐÐÒÒÒØØØÊÊʨ¨¨±±±¸¸¸­­­°°°³³³ÔÔÔßßßäääÙÙÙÔÔÔÛÛÛäääææææææßßßÐÐÐÐÐÐÒÒÒÔÔÔÑÑÑÎÎÎÍÍÍÎÎÎÐÐÐÔÔÔÉÉÉÃÃÃÐÐÐÕÕÕÑÑÑ×××ÝÝÝêêêæææíííêêêííííííßßßããã××׿¿¿ÊÊÊÊÊÊÉÉÉÌÌÌÌÌÌÙÙÙÒÒÒîîîÙÙÙ¼¼¼ÉÉÉÇÇÇÉÉÉÅÅÅÒÒÒÝÝÝæææñññùùùòòòäääâââÛÛÛÅÅÅÐÐÐÀÀÀµµµ±±±¸¸¸ÎÎÎÆÆÆÙÙÙÕÕÕÉÉÉÎÎÎÅÅźººÅÅÅÅÅÅÀÀÀ´´´»»»ÉÉÉÆÆÆÍÍÍÐÐÐÐÐÐÍÍÍÊÊÊÆÆÆÃÃÃÅÅÅÆÆÆÆÆÆ¿¿¿»»»¿¿¿ÆÆÆÇÇÇÃÃþ¾¾¾¾¾¾¾¾ÃÃÃÍÍÍÒÒÒÒÒÒÔÔÔØØØÛÛÛØØØÍÍÍÒÒÒÑÑÑÊÊÊÎÎÎÍÍÍÙÙÙÛÛÛÜÜÜÜÜÜÛÛÛÜÜÜßßßâââàààâââäääæææææææææääääääèèèõõõñññøøøíííØØغºº»»»¿¿¿ÃÃÃÇÇÇÇÇÇÅÅÅÅÅÅÉÉÉÍÍÍÍÍÍÊÊÊÉÉÉÆÆƵµµ¸¸¸ÆÆÆÒÒÒÔÔÔÌÌ̼¼¼ÌÌÌÆÆƺººÊÊÊÇÇÇÎÎÎÉÉÉÉÉÉÇÇÇÅÅÅÃÃÃÃÃÿ¿¿ºººººº»»»¼¼¼¼¼¼¾¾¾¿¿¿¿¿¿¿¿¿¿¿¿¿¿¿ÀÀÀÂÂÂÃÃÃÅÅÅÅÅÅÃÃÃÀÀÀ¿¿¿¼¼¼¾¾¾¿¿¿ÂÂÂÃÃÃÃÃÃÅÅÅÃÃÃÊÊÊÇÇÇÇÇÇÒÒÒÉÉɾ¾¾ÐÐÐÔÔÔ»»»¸¸¸ÙÙÙÉÉÉÉÉÉÒÒÒÕÕÕÐÐÐÌÌÌÐÐÐÎÎÎÍÍÍÒÒÒÔÔÔ×××ÎÎÎææææææùùùèèèâââãããÔÔÔÝÝÝââââââÐÐÐÍÍÍÆÆÆÎÎÎÙÙÙßßßÔÔÔÇÇÇÃÃÃÃÃÃÂÂÂ×××ÐÐÐÍÍÍÉÉÉÊÊÊ×××ÎÎί¯¯¯¯¯³³³±±±ÀÀÀÉÉÉàààæææëëëÙÙÙÕÕÕÜÜÜæææææææææàààÒÒÒÒÒÒÔÔÔÕÕÕÒÒÒÐÐÐÎÎÎÎÎÎÐÐÐÊÊÊÊÊÊÎÎÎÙÙÙÝÝÝÙÙÙ×××ÕÕÕîîîææææææãããæææíííèèèäääÉÉÉ¿¿¿ÂÂÂÊÊÊÉÉÉÉÉÉÐÐÐÔÔÔÌÌÌÒÒÒîîîâââÍÍÍÑÑÑÌÌÌÉÉÉÕÕÕâââêêêèèèèèèëëëæææÛÛÛÙÙÙÎÎÎÆÆÆÇÇÇ°°°­­­¥¥¥¦¦¦ÝÝÝÕÕÕ×××ÐÐÐÃÃÃÇÇÇÇÇǾ¾¾ÆÆÆÀÀÀ¼¼¼µµµ¼¼¼ÆÆÆÅÅÅÎÎÎÎÎÎÍÍÍÊÊÊÆÆÆÃÃÃÂÂÂÅÅÅÇÇÇÇÇÇÃÃÃÅÅÅÇÇÇÅÅž¾¾¾¾¾ÃÃÃÀÀÀÀÀÀÃÃÃÍÍÍÒÒÒÔÔÔØØØÝÝÝÙÙÙ×××ÍÍÍÒÒÒÔÔÔÑÑÑÙÙÙÙÙÙÝÝÝßßßàààßßßÝÝÝÜÜÜÛÛÛÜÜÜääääääææææææçççççççççäääóóóøøøöööõõõÜÜÜÊÊʼ¼¼¿¿¿ÃÃÃÆÆÆÇÇÇÇÇÇÆÆÆÇÇÇÌÌÌÐÐÐÙÙÙÕÕÕÐÐÐÀÀÀ»»»ÃÃÃÕÕÕÙÙÙÐÐÐÇÇǺººÆÆÆÇÇÇÀÀÀÇÇǺººÌÌÌÐÐÐÎÎÎÍÍÍÍÍÍÇÇÇ¿¿¿¼¼¼ºººººº»»»¼¼¼¼¼¼¾¾¾¿¿¿¿¿¿¿¿¿ÀÀÀÂÂÂÃÃÃÅÅÅÅÅÅÅÅÅÅÅÅÃÃÃÂÂÂÀÀÀ¾¾¾¾¾¾ÀÀÀÂÂÂÃÃÃÅÅÅÉÉÉÇÇÇÇÇÇÅÅÅÅÅÅÊÊÊ¿¿¿¿¿¿ÇÇÇÊÊʸ¸¸´´´ÊÊʼ¼¼¿¿¿ÉÉÉÊÊÊÇÇÇÇÇÇÎÎÎÐÐÐÎÎÎÑÑÑÒÒÒ×××ÐÐÐæææëëëüüüèèèâââêêê×××ÛÛÛãããàààÍÍÍÉÉÉÅÅÅÂÂÂÌÌÌÔÔÔÔÔÔÎÎÎÉÉÉÇÇÇÇÇÇÆÆÆÇÇÇÅÅÅÀÀÀÌÌÌßßßâââÔÔÔ©©©¯¯¯¸¸¸ÑÑÑßßßêêêçççêêêØØØØØØßßßæææææææææâââÙÙÙÔÔÔÕÕÕÔÔÔÒÒÒÐÐÐÎÎÎÎÎÎÎÎÎâââÝÝÝÙÙÙÕÕÕÕÕÕØØØÙÙÙÛÛÛíííäääßßßàààâââêêêëëëÕÕÕ¾¾¾ÀÀÀÉÉÉÌÌÌÇÇÇÊÊÊÔÔÔ×××ÑÑÑßßßèèèàààØØØÙÙÙÜÜÜßßßÛÛÛæææíííçççããããããâââÝÝÝØØØÇÇÇÌÌÌÆÆÆ···ÑÑÑÙÙÙÛÛÛàààÛÛÛÔÔÔÍÍÍÃÃÃÆÆÆÌÌÌ»»»ÂÂÂÃÃÃÉÉÉÊÊÊÃÃÃÊÊÊÃÃÃÃÃÃÃÃÃÂÂÂÀÀÀÂÂÂÅÅÅÇÇÇÊÊÊÆÆÆÇÇÇÍÍÍÆÆÆ»»»¾¾¾ÇÇÇÊÊÊÉÉÉÌÌÌÒÒÒÕÕÕ×××ÛÛÛßßßÕÕÕÔÔÔÍÍÍ×××ÛÛÛÙÙÙââââââãããââââââàààààààààãããäääóóóõõõóóóòòòóóóööööööóóóõõõøøøöööàà྾¾ºººÂÂÂÅÅÅÆÆÆÇÇÇÉÉÉÉÉÉÉÉÉÍÍÍÒÒÒØØØâââßßßÙÙÙÀÀÀÅÅÅÍÍÍÜÜÜÕÕÕÍÍÍÉÉÉ¿¿¿ÆÆÆÇÇÇÆÆÆÌÌ̼¼¼ÃÃÃÌÌÌÉÉÉÇÇÇÑÑÑÎÎÎÀÀÀ¼¼¼ºººººº»»»¼¼¼¼¼¼¾¾¾¿¿¿¿¿¿¿¿¿ÀÀÀÂÂÂÅÅÅÆÆÆÆÆÆÆÆÆÅÅÅÅÅÅÃÃÃÂÂÂÀÀÀ¿¿¿ÀÀÀÂÂÂÃÃÃÆÆÆÊÊÊÊÊÊÅÅÅÃÃÃÆÆÆÆÆƾ¾¾ÅÅÅ···¸¸¸¾¾¾ÇÇÇÌÌ̺ºººººÀÀÀÅÅÅÇÇÇÌÌÌÎÎÎÎÎÎÍÍÍÎÎÎÔÔÔÑÑÑÍÍÍêêêõõõúúúæææçççøøøßßßØØØÝÝÝØØØÉÉÉÇÇÇÊÊÊÆÆÆÃÃÃÂÂÂÆÆÆÊÊÊÍÍÍÌÌÌÊÊÊÅÅÅÅÅÅÂÂÂÅÅÅÎÎÎ×××ÝÝÝãããâââàààßßßäääæææäääÛÛÛÕÕÕ×××ÙÙÙßßßäääæææææææææãããøøøöööóóóîîîèèèãããàààÝÝÝçççàààßßß×××ÕÕÕØØØØØØÝÝÝêêêãããßßßäääâââæææäää¼¼¼ÀÀÀÉÉÉÐÐÐÍÍÍÊÊÊÎÎÎÒÒÒÒÒÒÛÛÛëëëäääàààààààààëëëñññÛÛÛãããçççäääãããäääãããàààÙÙÙÌÌÌÅÅÅ···³³³ÑÑÑÜÜÜÕÕÕÉÉÉÇÇÇÆÆÆÇÇÇÇÇÇÎÎÎÒÒÒÌÌÌ¿¿¿¸¸¸ÃÃÃÊÊÊÍÍÍÊÊÊÀÀÀÅÅÅ¿¿¿ÀÀÀÃÃÃÃÃÃÃÃÃÃÃÃÆÆÆÇÇÇÍÍÍÇÇÇÇÇÇÍÍÍÉÉÉÀÀÀÃÃÃÍÍÍÒÒÒÐÐÐÑÑÑÕÕÕ×××ÕÕÕÕÕÕØØØÔÔÔÕÕÕÒÒÒßßßãããÝÝÝâââßßßÝÝÝÛÛÛÙÙÙÛÛÛàààèèèñññõõõîîîîîîíííèèèêêêîîîîîîèèèëëëäääßßßÉÉɳ³³µµµÆÆÆÇÇÇÇÇÇÇÇÇÉÉÉÊÊÊÎÎÎÔÔÔÛÛÛßßßßßßÝÝÝÔÔÔ¸¸¸ÅÅÅÑÑÑÜÜÜÑÑÑÎÎÎÍÍÍÊÊÊÊÊÊÆÆÆÉÉÉÒÒÒÌÌ̾¾¾Â»»»¾¾¾ÐÐÐÔÔÔÇÇǾ¾¾ºººººº»»»¼¼¼¼¼¼¾¾¾¿¿¿¿¿¿¿¿¿ÀÀÀÂÂÂÅÅÅÅÅÅÆÆÆÅÅÅÅÅÅÆÆÆÅÅÅÃÃÃÂÂÂÂÂÂÂÂÂÃÃÃÃÃÃÆÆÆÉÉÉÉÉÉÃÃÃÃÃÃÇÇÇÅÅÅÃÃÃÅÅÅ»»»ÅÅÅÍÍÍÎÎεµµ···¼¼¼ÀÀÀÇÇÇÉÉÉÅÅÅÃÃÃÆÆÆÇÇÇÑÑÑÌÌÌÅÅÅÝÝÝñññöööæææêêêùùùâââ×××ÛÛÛÒÒÒÌÌÌÍÍÍÒÒÒÙÙÙÐÐÐÆÆÆ¿¿¿¼¼¼»»»ÅÅÅÆÆÆÆÆÆÉÉÉÎÎÎÐÐÐÕÕÕÜÜÜæææçççäääÝÝÝâââèèèèèèßßßÕÕÕÙÙÙßßßãããççççççèèèêêêâââàààâââãããääääääææææææÛÛÛ×××àààÝÝÝÝÝÝàààÜÜÜçççêêêäääàààèèèäääæææßßßµµµÅÅÅÍÍÍÎÎÎÍÍÍÐÐÐÕÕÕÕÕÕÐÐÐÔÔÔêêêãããçççîîîäääèèèçççàààãããããããããääääääÝÝÝ×××ÐÐÐÍÍÍ¿¿¿¼¼¼ÎÎÎßßßæææÒÒÒÇÇÇÆÆÆÇÇÇÅÅÅÅÅÅÉÉÉ»»»ÃÃø¸¸ÀÀÀÅÅÅÅÅÅÆÆÆÀÀÀÃÃÃÅÅÅÆÆÆÉÉÉÉÉÉÇÇÇÇÇÇÇÇÇÉÉÉÎÎÎÊÊÊÊÊÊÍÍÍÊÊÊÆÆÆÊÊÊÔÔÔÔÔÔÑÑÑÑÑÑÔÔÔÔÔÔÐÐÐÐÐÐÒÒÒÙÙÙÜÜÜÙÙÙäääæææÝÝÝÝÝÝÙÙÙÕÕÕØØØÝÝÝäääêêêîîîîîîîîîõõõùùùöööòòòòòòõõõîîîäääÙÙÙÅÅž¾¾¾¾¾¼¼¼ÇÇÇÅÅÅÉÉÉÉÉÉÉÉÉÌÌÌÐÐÐ×××ÝÝÝâââæææäääÒÒÒºººÂÂÂÒÒÒ×××ÍÍÍÍÍÍÎÎÎÒÒÒÐÐÐÅÅÅÆÆÆÑÑÑÒÒÒÇÇÇÆÆƼ¼¼ºººÇÇÇÐÐÐÅÅÅ···ºººººº»»»¼¼¼¼¼¼¾¾¾¿¿¿¿¿¿¾¾¾¿¿¿ÀÀÀÂÂÂÃÃÃÃÃÃÃÃÃÅÅÅÇÇÇÆÆÆÅÅÅÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÆÆÆÆÆÆÉÉÉÅÅÅÇÇÇÇÇÇ¿¿¿ÅÅŵµµµµµÅÅÅÃÃÃÀÀÀ······³³³···¸¸¸¾¾¾¿¿¿»»»¾¾¾ÆÆÆÉÉÉÆÆÆÇÇǾ¾¾ÉÉÉäääòòòèèèçççíííßßßØØØÝÝÝÒÒÒÔÔÔÕÕÕÙÙÙÕÕÕÕÕÕÒÒÒÊÊʾ¾¾¼¼¼¼¼¼»»»ÀÀÀÆÆÆÆÆÆÉÉÉÕÕÕÜÜÜØØØÎÎÎÙÙÙäääÝÝÝääääääàààÐÐÐ×××ÜÜÜÝÝÝàààçççèèèèèèíííèèèçççäääãããâââàààßßßÜÜÜàààâââñññêêêçççîîîäääííííííæææâââäääãããæææÜÜÜ¿¿¿ÃÃÃÊÊÊÉÉÉÊÊÊÔÔÔÛÛÛØØØÔÔÔÐÐÐàààÝÝÝäääëëëâââàààÜÜÜâââààààààâââäääãããÛÛÛÑÑÑÊÊÊÇÇǸ¸¸¾¾¾ÙÙÙÝÝÝßßßÌÌÌÃÃÃÀÀÀÉÉÉÃÃÃÇÇÇÐÐÐÂÂÂÀÀÀÉÉɼ¼¼ÂÂÂÀÀÀ¾¾¾ÅÅÅÅÅÅÆÆÆÆÆÆÇÇÇÉÉÉÉÉÉÉÉÉÉÉÉÌÌÌÍÍÍÍÍÍÐÐÐÑÑÑÍÍÍÆÆÆÆÆÆÐÐÐÜÜÜ×××ÑÑÑÐÐÐÑÑÑÒÒÒÐÐÐÒÒÒ×××ÝÝÝßßßÙÙÙâââãããÜÜÜßßßÛÛÛßßßâââèèèïïïóóóòòòíííçççíííóóóóóóïïïíííêêêÛÛÛÊÊÊÇÇǺºº»»»»»»ÅÅÅ¿¿¿ÆÆÆÃÃÃÉÉÉÉÉÉÉÉÉÌÌÌÐÐÐÕÕÕÛÛÛÝÝÝäääçççÒÒÒÂÂÂÆÆÆ×××ÑÑÑÉÉÉÉÉÉÊÊÊÔÔÔÔÔÔÆÆÆÂÂÂÇÇÇÌÌÌÑÑÑÍÍÍÇÇÇÀÀÀÀÀÀÉÉÉÅÅÅ´´´ºººººº»»»¼¼¼¼¼¼¾¾¾¿¿¿¿¿¿¾¾¾¾¾¾¾¾¾¿¿¿ÀÀÀÂÂÂÃÃÃÃÃÃÇÇÇÇÇÇÆÆÆÅÅÅÅÅÅÃÃÃÃÃÃÃÃÃÆÆÆÃÃÃÉÉÉÇÇÇÊÊÊÃÃô´´¿¿¿ÎÎξ¾¾ººº±±±´´´¬¬¬¯¯¯ŸŸŸ¨¨¨¤¤¤©©©¯¯¯¯¯¯±±±³³³¬¬¬¼¼¼ÀÀÀ»»»ÉÉÉèèèóóóçççäääçççãããÜÜÜßßßÑÑÑØØØØØØÛÛÛÌÌÌÔÔÔØØØÑÑÑÌÌÌÍÍÍÎÎÎÊÊÊÆÆÆÃÃÃÇÇÇÇÇÇÅÅÅÐÐÐÙÙÙÑÑÑÎÎÎØØØèèèæææëëëâââÜÜÜÎÎÎÜÜÜâââßßßßßßæææçççäääêêêêêêçççääääääääääääâââßßßâââíííÿÿÿæææßßßïïïäääâââëëëâââßßßÝÝÝÝÝÝÜÜÜÍÍÍ¿¿¿¿¿¿ÆÆÆÅÅÅÇÇÇÒÒÒ×××ÕÕÕØØØ×××ÛÛÛØØØÜÜÜàààÝÝÝßßßÝÝÝÝÝÝßßßàààâââàààÝÝÝØØØÕÕÕÎÎο¿¿ÃÃÃÎÎÎãããââââââÔÔÔÊÊÊÃÃÃÎÎÎÆÆÆÊÊÊ×××ÅÅÅÇÇÇÎÎÎÂÂÂÇÇÇ¿¿¿ÇÇÇÉÉÉÇÇÇÂÂÂÂÂÂÃÃÃÃÃÃÅÅÅÉÉÉÍÍÍÑÑÑÌÌÌÕÕÕØØØÎÎÎÃÃÃÅÅÅÒÒÒàààØØØÒÒÒÐÐÐÑÑÑÒÒÒÔÔÔÙÙÙßßßßßßÝÝÝ×××ÝÝÝàààÜÜÜãããâââñññîîîêêêëëëïïïöööùùùüüüæææîîîñññíííèèèàààÌÌ̵µµ»»»¿¿¿ÆÆƸ¸¸¿¿¿»»»ÅÅÅÃÃÃÉÉÉÉÉÉÉÉÉÊÊÊÎÎÎÒÒÒ×××ØØØÍÍÍØØØÉÉÉÅÅÅÉÉÉÙÙÙÌÌÌÅÅÅÅÅÅÅÅÅÒÒÒÕÕÕÇÇǾ¾¾¼¼¼ÀÀÀÍÍÍÌÌÌÌÌÌÆÆÆ¿¿¿ÊÊÊÎÎÎÀÀÀºººººº»»»¼¼¼¼¼¼¾¾¾¿¿¿¿¿¿¾¾¾¼¼¼¼¼¼¼¼¼¾¾¾¿¿¿ÂÂÂÃÃÃÉÉÉÇÇÇÇÇÇÆÆÆÅÅÅÃÃÃÃÃÃÃÃÃÇÇÇÂÂÂÉÉÉÌÌÌÍÍÍÀÀÀªªª¸¸¸¾¾¾°°°···³³³°°°©©©ÇÇÇÕÕÕÝÝÝ×××ÛÛÛãããâââßßßÒÒÒ¾¾¾¸¸¸ººº¼¼¼×××úúúøøøääääääíííêêêàààßßßÌÌÌÕÕÕØØØÛÛÛØØØÝÝÝÜÜÜÒÒÒÒÒÒØØØÔÔÔÊÊÊÒÒÒ¿¿¿ÂÂÂÊÊÊÅÅÅÌÌÌØØØÕÕÕÙÙÙÕÕÕÜÜÜÕÕÕÜÜÜÒÒÒÜÜÜÝÝÝâââäääßßßÝÝÝæææäääâââæææèèèæææããããããääääääâââßßßâââëëëëëë¼¼¼´´´ÝÝÝäääçççæææÜÜÜÝÝÝØØØØØØÒÒÒºººµµµ¾¾¾ÅÅÅÅÅÅÇÇÇÐÐÐÐÐÐÐÐÐØØØÛÛÛØØØÙÙÙÝÝÝßßßààààààÝÝÝàààãããäääâââÛÛÛÔÔÔÒÒÒÔÔÔÊÊÊ´´´ÒÒÒäääíííãããÙÙÙÌÌÌÐÐÐÊÊÊÉÉÉÍÍÍÒÒÒÑÑÑÉÉÉ¿¿¿ÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÃÃÿ¿¿ÅÅÅÍÍÍÑÑÑÒÒÒÒÒÒÑÑÑÑÑÑ×××ØØØÔÔÔÍÍÍÌÌÌÒÒÒÙÙÙÜÜÜàààÐÐÐÔÔÔÒÒÒÔÔÔÔÔÔÍÍÍÙÙÙ×××ÝÝÝâââóóóííííííæææïïïîîîïïïòòòõõõöööøøøùùùùùùñññóóóõõõíííØØØÃÃþ¾¾ÃÃÿ¿¿ÀÀÀÀÀÀ¿¿¿¾¾¾¿¿¿ÂÂÂÅÅÅÉÉÉÆÆÆÅÅÅÇÇÇÌÌÌÑÑÑÒÒÒÔÔÔÛÛÛÔÔÔÀÀÀÃÃÃÆÆÆ×××ÎÎÎÆÆÆÉÉÉÑÑÑÑÑÑÒÒÒÎÎÎÎÎÎÍÍÍ···¸¸¸ÀÀÀÐÐÐÀÀÀ¾¾¾ÔÔÔÎÎξ¾¾»»»¼¼¼¼¼¼¼¼¼»»»»»»¾¾¾¿¿¿¼¼¼¼¼¼¼¼¼¼¼¼¾¾¾ÀÀÀÃÃÃÅÅÅÉÉÉÇÇÇÆÆÆÅÅÅÃÃÃÃÃÃÅÅÅÆÆÆÆÆÆÊÊÊÆÆÆÌÌÌÔÔÔÃÃó³³»»»»»»³³³°°°­­­žžž©©©ÍÍÍÑÑÑ×××ÕÕÕÑÑÑ×××ãããÝÝÝÕÕÕÙÙÙØØØæææèèèèèèóóóõõõêêêäääëëëöööÜÜÜàààÒÒÒÔÔÔÝÝÝÕÕÕÙÙÙßßßÝÝÝÔÔÔÐÐÐÕÕÕÒÒÒÊÊÊÑÑÑÂÂÂÆÆÆÊÊÊÍÍÍÉÉÉâââÜÜÜØØØÑÑÑØØØÝÝÝØØØ×××ÝÝÝßßßâââßßßâââçççèèèææææææêêêäääàààßßßâââãããßßßßßßäääàààäääÝÝÝ»»»»»»±±±ÙÙÙÝÝÝÛÛÛ···³³³µµµ······°°°ºººÂÂÂÃÃÃÅÅÅÉÉÉÍÍÍÑÑÑÔÔÔ××××××ÙÙÙÛÛÛÝÝÝßßßàààààààààÛÛÛÝÝÝÜÜÜÕÕÕÒÒÒÔÔÔÑÑÑÌÌÌ···ºººÝÝÝâââÝÝÝæææÕÕÕÎÎÎÍÍÍÎÎÎÎÎÎÐÐÐÎÎÎÍÍÍÊÊÊÇÇÇ¿¿¿¿¿¿¿¿¿ÀÀÀÂÂÂÅÅÅÇÇÇÉÉÉÃÃÃÅÅÅÇÇÇÌÌÌÐÐÐÑÑÑÍÍÍÊÊÊØØØÙÙÙÕÕÕÍÍÍÌÌÌÑÑÑØØØÛÛÛÔÔÔÇÇÇÍÍÍÐÐÐÔÔÔÕÕÕÔÔÔààààààääääääóóóïïïõõõîîîòòòîîîîîîîîîïïïññññññïïïîîîöööîîîäääØØØÉÉÉ»»»¸¸¸¾¾¾¿¿¿¿¿¿¿¿¿¾¾¾¾¾¾¾¾¾ÂÂÂÅÅÅÇÇÇÆÆÆÆÆÆÇÇÇÌÌÌÐÐÐÒÒÒÔÔÔÍÍÍÆÆƺººÅÅÅÌÌÌÜÜÜÕÕÕÑÑÑÊÊÊÐÐÐÍÍÍÊÊÊÂÂÂÀÀÀÇÇǸ¸¸ÀÀÀÂÂÂÉÉɼ¼¼ÆÆÆÇÇǾ¾¾»»»¼¼¼¼¼¼¼¼¼»»»»»»¼¼¼¿¿¿¼¼¼¼¼¼¼¼¼¼¼¼¾¾¾ÀÀÀÃÃÃÅÅÅÉÉÉÇÇÇÆÆÆÅÅÅÃÃÃÃÃÃÅÅÅÆÆÆÆÆÆÉÉÉÆÆÆÍÍÍÕÕÕÆÆÆ´´´»»»Â¾¾¾´´´¬¬¬¦¦¦¾¾¾ÛÛÛÒÒÒ×××ÑÑÑÍÍÍÕÕÕãããæææãããäääãããëëëêêêêêêñññíííâââÜÜÜêêêïïïÛÛÛêêêÜÜÜÕÕÕÛÛÛÛÛÛÛÛÛßßßÜÜÜÒÒÒÐÐÐÕÕÕÕÕÕÐÐÐÊÊÊÀÀÀÇÇÇÌÌÌÎÎÎÌÌÌãããÛÛÛØØØ×××ÜÜÜÜÜÜ×××ÛÛÛâââßßßâââßßßàààãããàààÛÛÛÙÙÙÜÜÜâââãããäääæææãããÛÛÛÕÕÕÔÔÔãããäääÛÛÛ¸¸¸¸¸¸±±±ÕÕÕØØØÎÎεµµ´´´µµµ···¾¾¾¼¼¼Â¿¿¿ÂÂÂÅÅÅÉÉÉÍÍÍÑÑÑÒÒÒÔÔÔ×××ØØØÙÙÙÛÛÛÜÜÜÜÜÜÛÛÛÛÛÛàààÕÕÕÑÑÑ×××ÔÔÔÉÉÉÂÂÂÅÅÅÉÉÉÊÊÊäääâââßßßæææÕÕÕÔÔÔÔÔÔÒÒÒÑÑÑÎÎÎÍÍÍÌÌÌÍÍÍÍÍÍÐÐÐÐÐÐÐÐÐÎÎÎÍÍÍÌÌÌÊÊÊÊÊÊÎÎÎÌÌÌÉÉÉÍÍÍÔÔÔÕÕÕÐÐÐÊÊÊÙÙÙÙÙÙÕÕÕÎÎÎÍÍÍÒÒÒØØØÙÙÙÛÛÛÐÐÐÒÒÒÑÑÑÑÑÑÑÑÑÑÑÑÜÜÜæææëëëëëëóóóëëëóóóèèèãããçççæææçççíííòòòöööõõõóóóäääØØØÌÌÌÃÃÿ¿¿¼¼¼¾¾¾¿¿¿¾¾¾¿¿¿¿¿¿¾¾¾¼¼¼¼¼¼ÀÀÀÃÃÃÆÆÆÆÆÆÉÉÉÉÉÉÊÊÊÍÍÍÐÐÐÒÒÒÃÃÃÃÃþ¾¾ÊÊÊÆÆÆÎÎÎÆÆÆÇÇÇÐÐÐÒÒÒÎÎÎÌÌ̾¾¾···¾¾¾µµµÊÊÊÆÆÆÃÃÃÅÅÅ»»»¸¸¸ÀÀÀ¿¿¿»»»¼¼¼¼¼¼»»»»»»»»»¼¼¼¿¿¿¾¾¾¼¼¼¼¼¼¼¼¼¾¾¾ÀÀÀÃÃÃÅÅÅÉÉÉÇÇÇÆÆÆÅÅÅÃÃÃÃÃÃÅÅÅÆÆÆÅÅÅÇÇÇÆÆÆÎÎÎÙÙÙÉÉÉ···»»»»»»ÀÀÀµµµªªª­­­ÊÊÊàààÎÎÎÑÑÑÐÐÐØØØâââäääãããâââÝÝÝêêêèèèçççêêêîîîçççÜÜÜÜÜÜÜÜÜãããÕÕÕçççÜÜÜÒÒÒÕÕÕ×××ÔÔÔÛÛÛßßßÛÛÛÙÙÙÛÛÛÕÕÕÌÌÌÃÃÃÃÃÃÍÍÍÎÎÎÑÑÑÎÎÎäääØØØÛÛÛÝÝÝàààÜÜÜØØØÝÝÝâââÛÛÛãããâââââââââßßßÝÝÝàààæææÛÛÛÝÝÝàààßßßØØØÔÔÔÒÒÒÐÐÐäääâââØØصµµ´´´¯¯¯ÊÊÊÊÊÊ°°°¨¨¨°°°´´´···ÀÀÀ¿¿¿»»»¾¾¾ÀÀÀÅÅÅÉÉÉÍÍÍÐÐÐÐÐÐÑÑÑÕÕÕÕÕÕ××××××××××××ÕÕÕÕÕÕ×××ÒÒÒÒÒÒÒÒÒÇÇǼ¼¼ÃÃÃÔÔÔÕÕÕØØØæææàààãããêêêÝÝÝäääãããÙÙÙÎÎÎÉÉÉÌÌÌÐÐÐÎÎÎÌÌÌÉÉÉÌÌÌÐÐÐÒÒÒÒÒÒÐÐÐÌÌÌÉÉÉÑÑÑÎÎÎÌÌÌÎÎÎÒÒÒÔÔÔÑÑÑÍÍÍ×××ØØØÕÕÕÐÐÐÎÎÎÕÕÕÙÙÙÙÙÙÙÙÙÒÒÒÑÑÑÑÑÑÒÒÒÔÔÔÙÙÙäääãããîîîññññññÝÝÝàààÔÔÔÉÉÉÂÂÂÃÃÃÇÇÇÒÒÒßßßèèèëëëëëëÊÊÊÅÅÅÀÀÀ¿¿¿ÀÀÀÂÂÂÀÀÀÀÀÀ¿¿¿¿¿¿¿¿¿¾¾¾¼¼¼¼¼¼¿¿¿ÂÂÂÃÃÃÆÆÆÊÊÊÊÊÊÊÊÊÌÌÌÍÍÍÐÐи¸¸¼¼¼ºººÆÆÆÇÇÇÔÔÔÍÍÍÊÊÊ××××××ÔÔÔ×××ÉÉÉ»»»»»»¯¯¯ÊÊÊÊÊÊÃÃÃÆÆƺºº³³³ÀÀÀ¾¾¾ººº»»»¼¼¼»»»ºººººº¼¼¼¿¿¿¾¾¾¾¾¾¾¾¾¾¾¾¿¿¿ÂÂÂÅÅÅÆÆÆÉÉÉÇÇÇÆÆÆÃÃÃÃÃÃÃÃÃÅÅÅÅÅÅÂÂÂÆÆÆÅÅÅÐÐÐÛÛÛÌÌ̺ºº¾¾¾¨¨¨¸¸¸³³³©©©¬¬¬ÂÂÂ×××ÌÌÌØØØÕÕÕÜÜÜÝÝÝÔÔÔÕÕÕßßßàààãããÝÝÝÝÝÝçççíííæææâââæææÝÝÝêêêâââíííããããããâââÝÝÝÑÑÑØØØÜÜÜÙÙÙØØØ×××ÐÐÐÇÇÇÆÆÆÊÊÊÔÔÔÑÑÑÒÒÒÐÐÐäääØØØÝÝÝßßßàààßßßÜÜÜÛÛÛÙÙÙ×××ÕÕÕÙÙÙßßßâââßßßÜÜÜÛÛÛÜÜÜàààßßßßßß×××ÍÍÍÐÐÐÕÕÕÕÕÕÜÜÜØØØÍÍͬ¬¬¨¨¨¤¤¤³³³°°°­­­¥¥¥¦¦¦©©©ªªªµµµÀÀÀÃÃþ¾¾¿¿¿ÂÂÂÆÆÆÉÉÉÌÌÌÎÎÎÐÐÐÔÔÔÔÔÔÔÔÔÔÔÔÔÔÔÔÔÔÔÔÔÔÔÔÍÍÍÕÕÕÒÒÒÃÃû»»ÆÆÆÛÛÛçççÝÝÝàààæææßßßæææëëëàààëëëëëëßßßÑÑÑÊÊÊÊÊÊÍÍÍÎÎÎÍÍÍÉÉÉÌÌÌÍÍÍÎÎÎÎÎÎÌÌÌÉÉÉÆÆÆÉÉÉÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÌÌÌÌÌÌÑÑÑÔÔÔÒÒÒÑÑÑÒÒÒÙÙÙÜÜÜÛÛÛØØØÒÒÒÌÌÌÍÍÍÐÐÐÔÔÔßßßæææàààîîîòòòêêêÉÉÉÌÌÌÇÇÇÀÀÀÌÌÌÇÇÇÅÅÅÆÆÆÉÉÉÉÉÉÅÅÅÀÀÀÅÅÅÇÇÇÉÉÉÇÇÇÃÃÃÀÀÀ¾¾¾¼¼¼ÀÀÀÀÀÀÀÀÀ¾¾¾¼¼¼¼¼¼¿¿¿ÂÂÂÃÃÃÆÆÆÊÊÊÌÌÌÊÊÊÊÊÊÌÌÌÍÍÍÃÃÃÅÅŸ¸¸¾¾¾ÃÃÃÛÛÛ×××ÎÎÎÕÕÕÑÑÑÍÍÍÔÔÔÎÎÎÅÅű±±ÃÃÃÌÌÌÇÇÇÆÆÆ»»»ºººÆÆÆ»»»ººº»»»¼¼¼»»»ºººººº¼¼¼¾¾¾¿¿¿¾¾¾¾¾¾¾¾¾ÀÀÀÂÂÂÅÅÅÆÆÆÇÇÇÆÆÆÅÅÅÂÂÂÂÂÂÂÂÂÃÃÃÃÃÃÀÀÀÅÅÅÅÅÅÎÎÎÛÛÛÍÍͼ¼¼Â¢¢¢···µµµ­­­©©©±±±ÊÊÊÕÕÕÛÛÛÕÕÕØØØ×××ÐÐÐ×××âââàààØØØÑÑÑÕÕÕäääêêêæææçççïïïÛÛÛâââÙÙÙäääÝÝÝàààÝÝÝÜÜÜÒÒÒÑÑÑÌÌÌÅÅÅÂÂÂÃÃÃÆÆÆÅÅÅÎÎÎÔÔÔÙÙÙÒÒÒÔÔÔÐÐÐâââØØØÙÙÙÕÕÕ×××àààâââÙÙÙ×××ÜÜÜàààêêêõõõùùùóóóçççÛÛÛÑÑÑÐÐÐÎÎÎÔÔÔÕÕÕÍÍÍÑÑÑÛÛÛÛÛÛàààÛÛÛÑÑÑ´´´¬¬¬©©©­­­¨¨¨±±±¨¨¨¨¨¨°°°¯¯¯°°°¾¾¾ÆÆÆ¿¿¿¿¿¿¿¿¿ÀÀÀÃÃÃÉÉÉÍÍÍÐÐÐÑÑÑÑÑÑÑÑÑÒÒÒÒÒÒÔÔÔÔÔÔÕÕÕÑÑÑÕÕÕÊÊʸ¸¸¼¼¼ÔÔÔäääâââèèèèèèçççâââçççæææÛÛÛäääæææãããÛÛÛÑÑÑÉÉÉÇÇÇÌÌÌÐÐÐÔÔÔÑÑÑÎÎÎÌÌÌÊÊÊÉÉÉÉÉÉÉÉÉÊÊÊÍÍÍÎÎÎÎÎÎÌÌÌÊÊÊÍÍÍÎÎÎÍÍÍÑÑÑÒÒÒÔÔÔØØØÜÜÜÝÝÝÙÙÙØØØÔÔÔÉÉÉÊÊÊÎÎÎÑÑÑÜÜÜÝÝÝâââîîîïïïããã¾¾¾ÅÅÅÌÌÌÍÍÍÑÑÑÎÎÎÍÍÍÎÎÎÑÑÑÑÑÑÎÎÎÌÌÌÉÉÉÎÎÎÐÐÐÊÊÊÃÃÃÀÀÀÀÀÀÀÀÀÂÂÂÃÃÃÂÂÂÀÀÀ¾¾¾¾¾¾ÀÀÀÃÃÃÃÃÃÆÆÆÊÊÊÌÌÌÌÌÌÊÊÊÉÉÉÉÉÉÎÎÎÒÒÒÆÆÆ¿¿¿±±±¾¾¾¿¿¿ÃÃÃÇÇÇ»»»ÃÃÃÆÆÆÇÇÇÌÌ̼¼¼»»»ÇÇÇÊÊÊÃÃü¼¼ÃÃÃÇÇǸ¸¸ººº»»»»»»»»»ºººººº»»»¾¾¾¿¿¿¿¿¿¿¿¿¿¿¿ÀÀÀÃÃÃÆÆÆÇÇÇÆÆÆÅÅÅÃÃÃÀÀÀÀÀÀÀÀÀ¿¿¿ÅÅÅÃÃÃÌÌÌ×××ÌÌÌ¿¿¿ÉÉÉ°°°Â»»»³³³¬¬¬©©©ÂÂÂÙÙÙØØØÕÕÕÕÕÕØØØÙÙÙÝÝÝÙÙÙÐÐÐÒÒÒÍÍÍÕÕÕâââãããàààçççîîîíííãããÛÛÛîîîêêêçççàààèèèêêêçççâââÜÜÜÙÙÙÙÙÙÛÛÛÛÛÛ×××ÙÙÙÙÙÙÒÒÒÕÕÕÍÍÍÜÜÜÕÕÕÑÑÑÊÊÊÌÌÌÛÛÛäääÜÜÜÛÛÛèèèäääêêêëëëêêêçççâââÙÙÙÑÑÑÒÒÒÎÎÎÛÛÛæææÝÝÝÜÜÜâââÝÝÝâââÝÝÝ×××»»»±±±±±±¯¯¯ªªª¨¨¨¥¥¥©©©¸¸¸´´´­­­µµµµµµ¿¿¿¾¾¾¼¼¼¾¾¾ÀÀÀÅÅÅÊÊÊÎÎÎÐÐÐÐÐÐÐÐÐÐÐÐÑÑÑÒÒÒÔÔÔÔÔÔÒÒÒÒÒÒÊÊÊÀÀÀ¿¿¿ÉÉÉÕÕÕÛÛÛèèèçççææææææèèèäääßßßãããßßßàààÝÝÝØØØÐÐÐÊÊÊÊÊÊÍÍÍÅÅÅÆÆÆÉÉÉÌÌÌÎÎÎÑÑÑÒÒÒÒÒÒÕÕÕÔÔÔÔÔÔÔÔÔÔÔÔÒÒÒÐÐÐÎÎÎÌÌÌÐÐÐÔÔÔ×××ÛÛÛßßßÛÛÛÕÕÕÔÔÔÒÒÒÉÉÉÐÐÐ×××ÙÙÙâââÜÜÜäääêêêíííæææÀÀÀÉÉÉÒÒÒÔÔÔÒÒÒÒÒÒÒÒÒÒÒÒÔÔÔÒÒÒÑÑÑÐÐÐÊÊÊÍÍÍÍÍÍÉÉÉÆÆÆÇÇÇÉÉÉÆÆÆÅÅÅÅÅÅÅÅÅÂÂÂÀÀÀÀÀÀÂÂÂÅÅÅÅÅÅÆÆÆÉÉÉÌÌÌÍÍÍÌÌÌÇÇÇÅÅÅÅÅÅÌÌÌÌÌÌÎÎθ¸¸±±±¯¯¯¼¼¼¸¸¸¸¸¸³³³···»»»ÅÅÅÐÐи¸¸¿¿¿ÉÉɼ¼¼ÇÇÇÅÅŸ¸¸ººº»»»»»»ººººººººº»»»¾¾¾ÀÀÀ¿¿¿¿¿¿¿¿¿ÀÀÀÃÃÃÆÆÆÇÇÇÅÅÅÃÃÃÀÀÀ¿¿¿¿¿¿¿¿¿ÀÀÀÀÀÀ¾¾¾ÅÅÅÃÃÃÉÉÉÒÒÒÇÇÇÀÀÀÐÐкººÉÉɼ¼¼´´´´´´¬¬¬³³³ÀÀÀÌÌÌÒÒÒÒÒÒÑÑÑÔÔÔÔÔÔÐÐÐÍÍÍÎÎÎÍÍÍØØØâââÜÜÜÛÛÛãããèèèëëëÜÜÜÒÒÒæææääääääÙÙÙâââßßßàààââââââàààÛÛÛ×××ÒÒÒÙÙÙØØØÕÕÕÑÑÑØØØÊÊÊÕÕÕÒÒÒÐÐÐÌÌÌÉÉÉÒÒÒàààßßßâââïïïëëëèèèäääàààãããêêêíííêêêíííÛÛÛßßßæææÙÙÙÒÒÒÙÙÙÙÙÙÔÔÔÐÐÐÊÊÊ°°°¦¦¦ªªª¨¨¨¨¨¨©©©¨¨¨¤¤¤ªªª¦¦¦¨¨¨¸¸¸µµµ¼¼¼¼¼¼»»»¼¼¼¿¿¿ÃÃÃÇÇÇÊÊÊÑÑÑÐÐÐÎÎÎÎÎÎÎÎÎÎÎÎÐÐÐÑÑÑÍÍÍÎÎÎÐÐÐÊÊÊ¿¿¿»»»ÍÍÍãããêêêääääääëëëëëëèèèèèèæææÜÜÜÛÛÛÙÙÙÙÙÙØØØÔÔÔÌÌÌÆÆÆÌÌÌÑÑÑØØØßßßâââßßßÛÛÛØØØØØØÔÔÔÐÐÐÑÑÑÔÔÔÒÒÒÌÌÌÅÅÅÌÌÌÑÑÑÕÕÕØØØÜÜÜßßßÙÙÙÑÑÑããããããÕÕÕÛÛÛÝÝÝÙÙÙÜÜÜÐÐÐãããæææëëëëëëÊÊÊÎÎÎÒÒÒÐÐÐÕÕÕÕÕÕÕÕÕÔÔÔÒÒÒÑÑÑÐÐÐÎÎÎÌÌÌÎÎÎÍÍÍÉÉÉÉÉÉÌÌÌÉÉÉÂÂÂÆÆÆÆÆÆÆÆÆÃÃÃÂÂÂÀÀÀÃÃÃÆÆÆÅÅÅÆÆÆÇÇÇÊÊÊÍÍÍÌÌÌÇÇÇÃÃÃÌÌÌÆÆÆÊÊÊãããÙÙÙÆÆƯ¯¯±±±°°°···µµµ······ÂÂÂÎÎκºº¸¸¸ÆÆÆ¿¿¿¼¼¼ÇÇÇÀÀÀ¸¸¸ºººººº»»»ººº¸¸¸ººº»»»¾¾¾ÀÀÀÀÀÀ¿¿¿ÀÀÀÂÂÂÃÃÃÆÆÆÇÇÇÃÃÃÂÂÂÀÀÀ¿¿¿¾¾¾¾¾¾¿¿¿¿¿¿¾¾¾ÅÅÅÂÂÂÇÇÇÐÐÐÆÆÆÂÂÂÔÔÔ···ÇÇǸ¸¸´´´»»»¯¯¯¢¢¢ŸŸŸ¤¤¤ÂÂÂÔÔÔÕÕÕÕÕÕÍÍÍÆÆÆÌÌÌÌÌÌÍÍÍÙÙÙàààØØØØØØâââäääëëëâââØØØããããããëëëÝÝÝÜÜÜàààààààààâââàààÜÜÜÙÙÙØØØØØØÔÔÔÑÑÑÑÑÑÙÙÙÉÉÉÑÑÑÐÐÐÔÔÔÒÒÒÌÌÌÍÍÍÛÛÛàààäääïïïÝÝÝÝÝÝÜÜÜÜÜÜãããëëëëëëäääÕÕÕ···°°°···¯¯¯³³³ÉÉÉÔÔÔÕÕÕÐÐÐÊÊʱ±±¨¨¨±±±¯¯¯´´´©©©¯¯¯©©©ªªª¨¨¨°°°Â···ººº»»»»»»¾¾¾ÀÀÀÃÃÃÆÆÆÇÇÇÑÑÑÐÐÐÎÎÎÌÌÌÌÌÌÌÌÌÌÌÌÍÍÍÌÌÌÊÊÊÊÊÊÇÇÇÀÀÀÂÂÂÕÕÕíííóóóêêêêêêñññëëëçççêêêãããæææÜÜÜàààãããÙÙÙ×××ÛÛÛÛÛÛÙÙÙ×××ÕÕÕ×××ÙÙÙÜÜÜÜÜÜÛÛÛâââÝÝÝÔÔÔÔÔÔÛÛÛÔÔÔÎÎÎÕÕÕÙÙÙÙÙÙÝÝÝÜÜÜÙÙÙßßßãããÝÝÝÌÌÌÎÎÎÑÑÑÒÒÒÙÙÙßßßÝÝÝ×××àààæææñññçççÉÉÉÒÒÒÊÊÊÎÎÎÐÐÐÑÑÑÔÔÔÔÔÔÔÔÔÑÑÑÎÎÎÌÌÌÍÍÍÔÔÔÍÍÍÍÍÍÌÌÌÉÉÉÐÐÐÃÃÃÀÀÀÆÆÆÉÉÉÆÆÆÃÃÃÆÆÆÉÉÉÆÆÆÅÅÅÅÅÅÆÆÆÆÆÆÆÆÆÆÆÆÅÅÅÅÅÅÅÅÅÐÐÐÌÌÌÉÉÉÆÆÆÌÌÌÍÍͪªª±±±¬¬¬±±±°°°´´´»»»ºººÂ¿¿¿°°°»»»ÀÀÀµµµÇÇÇ»»»»»»ººººººººººººººº»»»¼¼¼¾¾¾ÀÀÀÀÀÀ¿¿¿ÀÀÀÀÀÀÃÃÃÅÅÅÆÆÆÃÃÃÂÂÂÀÀÀ¾¾¾¾¾¾¾¾¾¿¿¿¿¿¿ÂÂÂÂÂÂÀÀÀÃÃÃÅÅÅÜÜÜÎÎÎÆÆƸ¸¸ÍÍÍÃÃþ¾¾°°°¯¯¯¿¿¿¤¤¤¥¥¥¿¿¿ÑÑÑÕÕÕÕÕÕÍÍÍÎÎÎÝÝÝÝÝÝâââÝÝÝÕÕÕ×××âââäääàààäääëëëÛÛÛÙÙÙßßßÝÝÝâââÝÝÝßßß×××ßßßæææÜÜÜ×××ØØØ×××ÙÙÙÎÎÎÕÕÕÙÙÙÎÎÎÐÐÐÛÛÛØØØÑÑÑÌÌÌÐÐÐæææÛÛÛßßßãããíííÜÜܸ¸¸±±±¼¼¼ÀÀÀÑÑÑÒÒÒ´´´¼¼¼¿¿¿Â¾¾¾µµµ¬¬¬¦¦¦ÐÐÐÀÀÀ°°°ªªª±±±···µµµ°°°°°°°°°°°°´´´¸¸¸ºººººº···¸¸¸¸¸¸ººº¼¼¼¿¿¿ÃÃÃÇÇÇÉÉÉÌÌÌÌÌÌÊÊÊÊÊÊÉÉÉÇÇÇÉÉÉÉÉÉÇÇÇÊÊÊÊÊÊÀÀÀºººÃÃÃÜÜÜòòòñññíííêêêêêêíííëëëçççãããâââÜÜÜãããçççßßßÙÙÙÙÙÙ×××ÛÛÛÙÙÙØØØÙÙÙÜÜÜÝÝÝÜÜÜÛÛÛßßßÛÛÛÒÒÒÒÒÒØØØÕÕÕÔÔÔÛÛÛÙÙÙÙÙÙÝÝÝÜÜÜØØØÝÝÝâââÜÜÜÕÕÕØØØØØØÕÕÕØØØÜÜÜÛÛÛ×××ÝÝÝæææòòòãããÌÌÌÐÐÐÊÊÊÇÇÇÎÎÎÐÐÐÒÒÒÒÒÒÑÑÑÎÎÎÌÌÌÉÉÉÉÉÉÎÎÎÇÇÇÉÉÉÊÊÊÇÇÇÍÍÍÃÃÿ¿¿¿¿¿ÀÀÀÅÅÅÉÉÉÊÊÊÉÉÉÆÆÆÇÇÇÉÉÉÊÊÊÊÊÊÉÉÉÇÇÇÆÆÆÆÆÆÌÌÌÌÌÌÎÎÎÊÊÊÎÎÎÜÜÜÔÔÔÀÀÀ°°°°°°°°°±±±´´´ºººÐÐл»»°°°¾¾¾ÂµµµÍÍÍ¿¿¿»»»ºººººººººººº»»»»»»¼¼¼¾¾¾ÀÀÀÀÀÀÀÀÀÂÂÂÃÃÃÃÃÃÅÅÅÅÅÅÂÂÂÀÀÀ¿¿¿¼¼¼¼¼¼¼¼¼¾¾¾¾¾¾¿¿¿ÂÂÂÂÂÂÅÅÅÆÆÆÙÙÙÇÇÇÀÀÀ¾¾¾¾¾¾»»»¿¿¿¸¸¸´´´ººº¯¯¯ªªªµµµÂÂÂÎÎÎ××××××ÑÑÑÑÑÑàààßßß×××ÍÍÍÐÐÐÜÜÜçççêêêèèèîîîßßßÛÛÛàààßßßãããßßßñññäääÝÝÝÝÝÝÜÜÜÝÝÝàààßßßÜÜÜØØØæææëëëÙÙÙÑÑÑ×××ÒÒÒÔÔÔ×××ÜÜÜÜÜÜÛÛÛóóóêêêäää¾¾¾´´´¼¼¼¿¿¿±±±···ÀÀÀ¸¸¸ÀÀÀÂÂÂÃÃþ¾¾¸¸¸³³³¯¯¯°°°­­­¬¬¬¯¯¯´´´¸¸¸¸¸¸···¸¸¸······ººº¼¼¼¾¾¾¼¼¼ºººººººººººº¼¼¼¾¾¾ÂÂÂÅÅÅÆÆÆÊÊÊÉÉÉÉÉÉÇÇÇÆÆÆÅÅÅÅÅÅÆÆÆÃÃÃÆÆÆÃÃü¼¼ÅÅÅØØØèèèîîîíííëëëèèèêêêëëëëëëçççäääâââßßßäääçççàààÛÛÛÛÛÛØØØÜÜÜÜÜÜÛÛÛÜÜÜÝÝÝÝÝÝÜÜÜÛÛÛÛÛÛØØØÒÒÒÑÑÑ××××××ÙÙÙàààÛÛÛÙÙÙÝÝÝÝÝÝÙÙÙÝÝÝßßßØØØÊÊÊÐÐÐÑÑÑÐÐÐÒÒÒØØØÜÜÜÜÜÜàààèèèòòòØØØÇÇÇÉÉÉÌÌÌÆÆÆÍÍÍÎÎÎÑÑÑÑÑÑÐÐÐÍÍÍÉÉÉÆÆÆÆÆÆÊÊÊÃÃÃÅÅÅÆÆÆÃÃÃÅÅÅ¿¿¿ÊÊÊÃÃû»»¼¼¼ÅÅÅÊÊÊÉÉÉÉÉÉÇÇÇÉÉÉÌÌÌÍÍÍÍÍÍÌÌÌÉÉÉÇÇÇÉÉÉÆÆÆÅÅÅÍÍÍÉÉÉÅÅÅÔÔÔÛÛÛÒÒÒ´´´­­­±±±µµµ´´´¸¸¸ÐÐл»»³³³¿¿¿Â···ÎÎλ»»»»»»»»ººº»»»»»»¼¼¼¾¾¾¿¿¿ÀÀÀÀÀÀÃÃÃÅÅÅÆÆÆÅÅÅÅÅÅÃÃÃÀÀÀ¿¿¿¾¾¾»»»»»»»»»¼¼¼¼¼¼¾¾¾ÀÀÀÀÀÀÆÆÆÆÆÆÕÕÕÀÀÀ»»»ÐÐл»»ºººÀÀÀÀÀÀ»»»³³³´´´¬¬¬¥¥¥¨¨¨³³³ÂÂÂÒÒÒÝÝÝÜÜÜÙÙÙÛÛÛÙÙÙØØØÜÜÜäääêêêíííæææêêêÙÙÙÔÔÔÛÛÛÛÛÛÜÜÜÙÙÙíííäää×××ÔÔÔàààëëëííííííàààÜÜÜäääãããÐÐÐÉÉÉÒÒÒ×××ÑÑÑÕÕÕàààÙÙÙÙÙÙäää¿¿¿µµµÂÂÂÂÂÂÊÊÊÌÌÌÂÂÂÂÂÂÆÆÆÅÅÅÇÇÇÆÆÆÅÅÅÃÃÿ¿¿¼¼¼¸¸¸···¥¥¥ªªª±±±´´´³³³³³³µµµººº¼¼¼¼¼¼¼¼¼¼¼¼¾¾¾¾¾¾»»»ººººººººº»»»»»»¼¼¼¿¿¿ÀÀÀÂÂÂÇÇÇÆÆÆÆÆÆÅÅÅÅÅÅÃÃÃÃÃÿ¿¿¼¼¼ÅÅÅ×××êêêïïïíííæææçççèèèêêêëëëêêêçççæææäääâââàààßßßÙÙÙØØØÛÛÛÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÛÛÛÙÙÙØØØ×××ÔÔÔÒÒÒÔÔÔ×××ÛÛÛàààÙÙÙÙÙÙßßßàààÜÜÜßßßÝÝÝÒÒÒÎÎÎÔÔÔ×××ÔÔÔÑÑÑÒÒÒ××××××èèèîîîíííÊÊÊÂÂÂÃÃÃÐÐÐÌÌÌÍÍÍÎÎÎÑÑÑÒÒÒÑÑÑÍÍÍÉÉÉÅÅÅÇÇÇÇÇÇÀÀÀÀÀÀÃÃþ¾¾»»»¼¼¼ØØØÕÕÕÆÆÆ»»»ÀÀÀÇÇÇÆÆÆÂÂÂÇÇÇÉÉÉÌÌÌÍÍÍÍÍÍÌÌÌÉÉÉÇÇÇÊÊÊÂÂÂÀÀÀÊÊÊÊÊÊÂÂÂÃÃÃÆÆÆ××׸¸¸°°°´´´»»»¸¸¸³³³¿¿¿ÇÇÇ···¿¿¿ÀÀÀ´´´ÊÊÊ¿¿¿¿¿¿»»»»»»»»»»»»¼¼¼¼¼¼¾¾¾¿¿¿ÀÀÀÂÂÂÅÅÅÇÇÇÇÇÇÆÆÆÅÅÅÃÃÃÂÂÂÀÀÀ¾¾¾¼¼¼»»»¼¼¼¼¼¼¾¾¾¼¼¼ÀÀÀÀÀÀÅÅÅÆÆÆÔÔÔ¿¿¿¾¾¾ÕÕÕÃÃü¼¼¼¼¼ÂÂÂÃÃþ¾¾»»»¿¿¿±±±¬¬¬©©©¦¦¦´´´ÇÇÇÊÊÊÛÛÛÛÛÛÙÙÙ×××ØØØÝÝÝæææêêêãããäääÙÙÙÑÑÑØØØÛÛÛÛÛÛÙÙÙæææèèèÜÜÜ×××äääëëëäääâââëëëããããããßßßÒÒÒÒÒÒàààèèèÜÜÜØØØàààââââââÕÕÕºººÇÇÇÉÉÉÇÇÇÇÇÇÉÉÉÍÍÍÍÍÍÇÇÇÅÅÅÌÌÌÊÊÊÇÇÇÅÅž¾¾»»»ººº³³³···ººº···±±±°°°···¾¾¾ººººººººº»»»»»»ººº¸¸¸¸¸¸»»»»»»»»»¼¼¼¼¼¼¾¾¾¾¾¾¾¾¾ÃÃÃÃÃÃÃÃÃÃÃÃÅÅÅÅÅÅÃÃÃÂÂÂÀÀÀ¼¼¼ÅÅÅÙÙÙèèèëëëëëëîîîâââäääçççêêêêêêèèèçççæææàààâââßßßÙÙÙ××××××ØØØÛÛÛÙÙÙÙÙÙÙÙÙÙÙÙÙÙÙØØØØØØØØØØØØØØØØØØÔÔÔÑÑÑÔÔÔÙÙÙÜÜÜØØØÙÙÙàààãããààààààÜÜÜÎÎÎÒÒÒÛÛÛàààÝÝÝÙÙÙÛÛÛÜÜÜÜÜÜëëëîîîãããÃÃÃÂÂÂÃÃÃÑÑÑÍÍÍÍÍÍÐÐÐÒÒÒÔÔÔÒÒÒÐÐÐÊÊÊÇÇÇÅÅž¾¾¼¼¼ÀÀÀ»»»···ÃÃÃÝÝÝäääÒÒÒ»»»¼¼¼ÆÆÆÅÅÅÀÀÀÆÆÆÇÇÇÉÉÉÊÊÊÊÊÊÉÉÉÇÇÇÆÆÆÇÇÇÆÆÆÊÊÊÍÍÍÎÎÎÌÌÌÆÆÆÆÆÆÍÍÍ¿¿¿¼¼¼µµµ´´´···±±±···ÔÔÔ»»»¾¾¾¿¿¿°°°Â»»»Â»»»»»»»»»»»»¼¼¼¼¼¼¾¾¾¿¿¿ÀÀÀÃÃÃÆÆÆÉÉÉÉÉÉÆÆÆÃÃÃÂÂÂÃÃÿ¿¿¾¾¾¾¾¾¾¾¾¾¾¾¿¿¿¼¼¼Â¿¿¿ÃÃÃÇÇÇÔÔÔÂÂÂÆÆÆÅÅÅÉÉÉ»»»³³³ºººÉÉÉÎÎÎÃÃÃÆÆƾ¾¾¾¾¾¸¸¸ªªª©©©¯¯¯¬¬¬ØØØÝÝÝßßßÝÝÝÜÜÜàààããããããæææçççààà×××ÜÜÜàààßßßâââÝÝÝèèèäääÝÝÝäääæææßßßßßßäääßßßàààãããßßßÝÝÝâââãããÜÜÜâââæææäääÝÝÝÅÅž¾¾ÐÐÐÅÅÅÉÉÉÉÉÉÇÇÇÉÉÉÆÆÆÅÅÅÉÉÉÌÌÌÌÌÌÊÊÊÇÇÇÅÅÅ¿¿¿»»»¸¸¸ººº»»»ººº···µµµ···¼¼¼ÀÀÀ···¸¸¸ººº»»»»»»»»»»»»»»»¾¾¾¾¾¾¾¾¾¾¾¾¼¼¼¼¼¼¼¼¼¼¼¼ÂÂÂÀÀÀÀÀÀÃÃÃÇÇÇÇÇÇÆÆÆÅÅż¼¼ÇÇÇÜÜÜííííííæææäääëëëâââäääçççêêêêêêèèèçççæææÛÛÛàààßßßÛÛÛÙÙÙØØØÔÔÔÕÕÕ×××ØØØØØØ×××ÕÕÕÕÕÕØØØÙÙÙÙÙÙÙÙÙÙÙÙÔÔÔÌÌÌÐÐÐØØØÙÙÙÙÙÙÙÙÙàààãããàààâââÝÝÝÐÐÐÍÍÍ×××ÝÝÝÝÝÝÝÝÝàààããããããæææççç×××ÅÅÅÆÆÆÆÆÆÍÍÍÉÉÉÍÍÍÐÐÐÔÔÔÕÕÕÕÕÕÑÑÑÍÍÍÉÉÉÀÀÀ¾¾¾¼¼¼»»»ÀÀÀ»»»ºººÑÑÑÙÙÙãããÐÐз··»»»ÅÅÅÅÅÅÅÅÅÆÆÆÆÆÆÇÇÇÇÇÇÇÇÇÇÇÇÆÆÆÆÆÆÆÆÆÍÍÍÔÔÔÎÎÎÌÌÌÌÌÌÆÆÆÌÌÌÃÃÃÇÇÇÌÌ̸¸¸­­­´´´···¿¿¿ÔÔÔ¼¼¼¼¼¼¼¼¼­­­ÀÀÀ»»»ÀÀÀ»»»»»»ººº»»»»»»¼¼¼¾¾¾¿¿¿ÀÀÀÃÃÃÆÆÆÇÇÇÇÇÇÆÆÆÃÃÃÀÀÀÃÃÃÂÂÂÀÀÀ¿¿¿¾¾¾¾¾¾¿¿¿¿¿¿¼¼¼Â¼¼¼ÀÀÀÇÇÇÔÔÔÃÃÃÎÎλ»»ÌÌÌ°°°±±±ÀÀÀÉÉÉÂÂÂÀÀÀ»»»¼¼¼¾¾¾»»»ºººµµµ­­­ºººÇÇÇÒÒÒÕÕÕÙÙÙâââäääâââàààäääãããØØØÙÙÙÝÝÝÙÙÙàààÛÛÛâââãããàààâââããããããçççàààÙÙÙÙÙÙßßßàààÝÝÝÝÝÝÝÝÝëëëÿÿÿÿÿÿæææ×××ÉÉÉÉÉÉÃÃÃÉÉÉÍÍÍÍÍÍÌÌÌÊÊÊÉÉÉÊÊÊÎÎÎÌÌÌÌÌÌÌÌÌÊÊÊÇÇǾ¾¾»»»¼¼¼»»»ººº»»»»»»»»»ººº¸¸¸¸¸¸»»»¾¾¾¿¿¿¿¿¿¿¿¿¿¿¿ÀÀÀ¿¿¿¿¿¿¿¿¿¿¿¿¿¿¿¾¾¾¼¼¼¼¼¼ÀÀÀ¿¿¿ÀÀÀÃÃÃÇÇÇÉÉÉÇÇÇÃÃ÷··×××ññññññèèèçççèèèçççæææçççèèèêêêëëëêêêçççæææÙÙÙãããàààÙÙÙÛÛÛÙÙÙÕÕÕ××××××××××××ÕÕÕÔÔÔÕÕÕÙÙÙÝÝÝÛÛÛÙÙÙÙÙÙÐÐÐÅÅÅÌÌÌÙÙÙÛÛÛÝÝÝÛÛÛßßßàààßßßãããàààÔÔÔÒÒÒÙÙÙÝÝÝÛÛÛØØØÛÛÛÜÜÜÛÛÛâââàààÆÆÆÂÂÂÅÅÅÆÆÆÇÇÇÆÆÆÊÊÊÍÍÍÒÒÒÕÕÕÕÕÕÒÒÒÍÍÍÊÊÊÅÅÅÀÀÀÀÀÀ»»»¿¿¿ººº···ØØØ×××ÕÕÕ¿¿¿±±±¼¼¼ÀÀÀ¿¿¿ÇÇÇÇÇÇÆÆÆÆÆÆÅÅÅÅÅÅÆÆÆÆÆÆÇÇÇÊÊÊÍÍÍÕÕÕÎÎÎÐÐÐÍÍÍ¿¿¿ÇÇÇÂÂÂÉÉÉÎÎξ¾¾µµµ¿¿¿ÀÀÀÆÆÆÅÅŸ¸¸¿¿¿ººº¬¬¬ÉÉÉÀÀÀ»»»ºººººººººººº»»»»»»¼¼¼¾¾¾ÂÂÂÃÃÃÆÆÆÆÆÆÆÆÆÅÅÅÃÃÃÀÀÀÂÂÂÀÀÀ¿¿¿¾¾¾¼¼¼¼¼¼¾¾¾¿¿¿»»»Â»»»ÀÀÀÇÇÇÒÒÒÂÂÂÐÐо¾¾ÌÌÌÎÎλ»»³³³µµµ···ÆÆÆÉÉÉÃÃúººµµµ»»»»»»µµµ´´´¨¨¨µµµººº±±±¸¸¸ÐÐÐààààààÜÜÜàààäääÕÕÕÒÒÒÕÕÕÎÎÎÙÙÙãããßßßààààààÛÛÛØØØÜÜÜÝÝÝæææàààÜÜÜÜÜÜÝÝÝßßßäääíííæææÝÝÝÛÛÛ¿¿¿¾¾¾ÅÅÅÍÍÍÆÆÆÌÌÌÉÉÉÉÉÉÌÌÌÊÊÊÌÌÌÌÌÌÇÇÇÊÊÊÌÌÌÌÌÌÌÌÌÊÊÊÇÇÇÃÃÃÂÂÂÂÂÂÀÀÀ¿¿¿¾¾¾¼¼¼»»»¸¸¸···»»»¾¾¾ÀÀÀÀÀÀÀÀÀÀÀÀÂÂÂÃÃÃÀÀÀÀÀÀÂÂÂÂÂÂÀÀÀ¿¿¿¾¾¾¼¼¼ÂÂÂÀÀÀÀÀÀÃÃÃÇÇÇÇÇÇÃÃÿ¿¿ºººÛÛÛòòòîîîèèèîîîñññêêêíííëëëèèèêêêëëëëëëçççäääßßßçççàààÕÕÕ×××ØØØØØØÜÜÜØØØØØØ×××ÔÔÔÔÔÔÕÕÕÛÛÛàààÜÜÜÙÙÙØØØÍÍÍ¿¿¿ÉÉÉÛÛÛÝÝÝâââÜÜÜÝÝÝÜÜÜÜÜÜããããããØØØÔÔÔÙÙÙÜÜÜÛÛÛÜÜÜâââææææææâââÜÜܸ¸¸¼¼¼¿¿¿ÃÃÃÅÅÅÉÉÉÇÇÇÌÌÌÑÑÑÕÕÕÕÕÕÒÒÒÍÍÍÊÊÊÍÍÍÇÇÇÆÆƾ¾¾¾¾¾µµµ³³³ØØØ×××ÉÉÉ°°°­­­¾¾¾¼¼¼¸¸¸ÅÅÅÉÉÉÇÇÇÅÅÅÅÅÅÅÅÅÅÅÅÇÇÇÉÉÉÌÌÌÉÉÉÐÐÐÔÔÔßßßÛÛÛÃÃÃÇÇÇÆÆÆÅÅÅÉÉÉÃÃÃÆÆÆÐÐÐÉÉÉÆÆƳ³³µµµÂ¸¸¸­­­ÒÒÒÆÆƵµµººººººººººººººº»»»¼¼¼¾¾¾ÂÂÂÃÃÃÅÅÅÆÆÆÆÆÆÅÅÅÂÂÂÀÀÀÀÀÀ¿¿¿¾¾¾¼¼¼»»»»»»¼¼¼¾¾¾ºººÂ»»»ÀÀÀÇÇÇÑÑѾ¾¾ÍÍÍÀÀÀÃÃÃ×××ÉÉɼ¼¼µµµ°°°ÕÕÕÆÆÆÅÅŸ¸¸±±±¸¸¸µµµ±±±···´´´ÅÅÅÅÅŵµµ¸¸¸ÎÎÎÜÜÜØØØßßßäääëëëÛÛÛÔÔÔÕÕÕÍÍÍØØØÙÙÙÎÎÎÔÔÔÜÜÜØØØ×××ÜÜÜÛÛÛÛÛÛÙÙÙØØØ××××××ØØØãããñññââ⺺ºÀÀÀ¼¼¼ÊÊÊÐÐÐÎÎÎÒÒÒÍÍÍÊÊÊÐÐÐÒÒÒÌÌÌÍÍÍÐÐÐÌÌÌÊÊÊÌÌÌÌÌÌÌÌÌÌÌÌÊÊÊÉÉÉÉÉÉÃÃÃÃÃÿ¿¿¼¼¼¼¼¼¿¿¿Â»»»¾¾¾ÀÀÀÀÀÀ¿¿¿¾¾¾¿¿¿ÂÂÂÀÀÀÂÂÂÃÃÃÃÃÃÂÂÂÀÀÀ¿¿¿¾¾¾ÃÃÃÀÀÀÀÀÀÂÂÂÆÆÆÅÅÅ¿¿¿»»»ÀÀÀ×××èèèëëëíííòòòõõõññññññíííêêêêêêíííëëëçççãããßßßààààààÝÝÝØØØ×××ÙÙÙÝÝÝÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÝÝÝÙÙÙÎÎÎØØØÕÕÕÉÉÉ×××ßßßßßßÜÜÜÝÝÝãããæææâââÜÜÜÜÜÜÛÛÛÜÜÜÙÙÙÕÕÕÙÙÙãããäääßßßÕÕÕ¾¾¾···ºººÃÃÃÀÀÀµµµÇÇÇÃÃÃÊÊÊÒÒÒÕÕÕÒÒÒÎÎÎÎÎÎÐÐÐÉÉÉÇÇÇÆÆƼ¼¼µµµ°°°¬¬¬ªªª¬¬¬­­­±±±µµµ»»»¿¿¿ÃÃÃÃÃÃÃÃÃÂÂÂÂÂÂÀÀÀÂÂÂÅÅÅÆÆÆÇÇÇÔÔÔÊÊÊÐÐÐÝÝÝÛÛÛØØØÎÎÎÉÉÉÍÍÍÒÒÒ±±±ÆÆƼ¼¼ººººººÀÀÀÀÀÀ±±±¸¸¸ÆÆƼ¼¼´´´³³³´´´···¸¸¸ººº»»»¾¾¾ÀÀÀÂÂÂÃÃÃÅÅÅÆÆÆÅÅÅ¿¿¿¾¾¾¼¼¼»»»ºººººº»»»»»»ººº¸¸¸ººº»»»¸¸¸¿¿¿ÂÂÂÎÎÎÀÀÀÊÊÊÅÅÅÂÂÂÕÕÕÌÌÌ···¿¿¿¿¿¿»»»ÅÅÅÆÆÆ»»»¾¾¾±±±¸¸¸µµµ¾¾¾ººº¾¾¾Â¿¿¿¸¸¸´´´´´´µµµ±±±âââêêêëëëÎÎÎÙÙÙÎÎÎÙÙÙÛÛÛÔÔÔÙÙÙæææçççßßßÙÙÙÛÛÛÒÒÒÛÛÛÙÙÙãããäääàààæææÝÝÝ···¸¸¸¾¾¾ÃÃÃÉÉÉÎÎÎÑÑÑÔÔÔÎÎÎÎÎÎÎÎÎÍÍÍÍÍÍÌÌÌÌÌÌÌÌÌÊÊÊÊÊÊÉÉÉÉÉÉÇÇÇÆÆÆÆÆÆÅÅÅÅÅÅÃÃÃÃÃÃÂÂÂÀÀÀ¿¿¿¾¾¾¾¾¾¼¼¼¾¾¾¿¿¿ÂÂÂÂÂÂÂÂÂÀÀÀ¿¿¿ÃÃÃÃÃÃÂÂÂÂÂÂÂÂÂÃÃÃÃÃÃÃÃþ¾¾ÂÂÂÅÅÅÇÇÇÃÃø¸¸¿¿¿×××äääæææëëëñññíííâââÝÝÝààààààëëëëëëêêêîîîêêêãããèèèßßßàààâââßßßÙÙÙÙÙÙÜÜÜààààààßßßÜÜÜÙÙÙÙÙÙÜÜÜßßßâââÝÝÝÜÜÜÒÒÒÙÙÙ×××ÐÐÐÛÛÛßßßßßßÝÝÝàààããããããÝÝÝÙÙÙÛÛÛßßßßßßÜÜÜÙÙÙÙÙÙßßßãããããã»»»µµµºººººº¾¾¾¼¼¼¼¼¼ÕÕÕ¾¾¾ÅÅÅÎÎÎÔÔÔÒÒÒÐÐÐÎÎÎÎÎÎÊÊÊÉÉÉÆÆÆ»»»´´´¯¯¯¬¬¬ªªªªªª¬¬¬°°°µµµ»»»¿¿¿ÂÂÂÂÂÂÀÀÀ¿¿¿¿¿¿¿¿¿ÂÂÂÅÅÅÆÆÆÊÊÊÔÔÔÎÎÎ×××âââãããæææÜÜÜÌÌÌÃÃÃÇÇǵµµÐÐо¾¾ÃÃø¸¸ÀÀÀ¸¸¸¼¼¼Â¸¸¸µµµ³³³³³³´´´···¸¸¸¸¸¸ººº¼¼¼¿¿¿ÂÂÂÃÃÃÅÅÅÅÅÅÃÃÃÀÀÀ¾¾¾¼¼¼ººº···µµµµµµ···¸¸¸···µµµ»»»»»»¸¸¸¾¾¾¿¿¿ÊÊʸ¸¸¿¿¿ÍÍÍ¿¿¿ÎÎÎÐÐÐÆÆÆÊÊÊÆÆÆÀÀÀ¸¸¸ÃÃÿ¿¿¼¼¼±±±¼¼¼···³³³»»»¾¾¾ÀÀÀ¿¿¿»»»·········¸¸¸ÕÕÕÙÙÙëëëàààèèèÔÔÔÔÔÔ×××ÒÒÒØØØçççîîîæææÙÙÙÔÔÔßßßæææãããàààâââæææäää×××µµµ¸¸¸¼¼¼ÂÂÂÆÆÆÌÌÌÎÎÎÑÑÑÎÎÎÍÍÍÍÍÍÍÍÍÌÌÌÌÌÌÌÌÌÊÊÊÊÊÊÊÊÊÉÉÉÉÉÉÇÇÇÆÆÆÅÅÅÅÅÅÃÃÃÃÃÃÃÃÃÂÂÂÂÂÂÀÀÀÀÀÀ¿¿¿¿¿¿¿¿¿ÀÀÀÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÅÅÅÅÅÅÅÅÅ¿¿¿¼¼¼ÂÂÂÀÀÀ¸¸¸ÂÂÂÜÜÜîîîîîîíííëëëèèèãããÝÝÝÜÜÜßßßÝÝÝãããæææèèèëëëêêêçççêêêàààâââãããàààÝÝÝÝÝÝâââäääâââàààßßßÝÝÝÝÝÝßßßâââãããÜÜÜßßßÙÙÙÜÜÜÛÛÛÙÙÙààààààØØØÛÛÛâââæææãããÛÛÛØØØÙÙÙâââØØØÔÔÔÛÛÛãããäääÝÝÝÙÙÙ±±±···¿¿¿»»»¸¸¸µµµºººÑÑѺºº¿¿¿ÉÉÉÐÐÐÒÒÒÑÑÑÎÎÎÌÌÌÌÌÌÉÉÉÆÆÆ¿¿¿ººº³³³­­­ªªªªªª©©©ªªª¯¯¯···¼¼¼¿¿¿¿¿¿¾¾¾¼¼¼»»»»»»¼¼¼ÀÀÀÅÅÅÇÇÇÊÊÊÎÎÎÎÎÎÔÔÔ×××ÛÛÛàààÕÕÕÇÇÇ···»»»ºººØØØÅÅž¾¾ÊÊÊ°°°ÀÀÀÀÀÀÀÀÀ¼¼¼¯¯¯°°°°°°±±±´´´···¸¸¸¸¸¸ººº»»»¾¾¾ÂÂÂÃÃÃÅÅÅÅÅÅ¿¿¿¼¼¼ººº¸¸¸µµµ´´´´´´µµµ······µµµººº»»»¸¸¸¿¿¿ÂÂÂÌÌÌ···»»»ÉÉÉ»»»ÊÊÊÜÜÜÝÝÝÛÛÛÍÍÍÀÀÀµµµÅÅÅÇÇÇÆÆƺºº¾¾¾¸¸¸´´´¼¼¼¾¾¾¾¾¾¾¾¾¾¾¾¼¼¼»»»»»»¸¸¸ÀÀÀ»»»ÔÔÔÛÛÛîîîäääèèèââââââãããæææèèèçççæææèèèâââââââââÜÜÜßßßàààÎÎο¿¿µµµ···»»»¿¿¿ÃÃÃÇÇÇÌÌÌÍÍÍÍÍÍÍÍÍÌÌÌÌÌÌÌÌÌÌÌÌÊÊÊÊÊÊÊÊÊÊÊÊÉÉÉÉÉÉÇÇÇÆÆÆÆÆÆÅÅÅÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÃÂÂÂÂÂÂÂÂÂÃÃÃÃÃÃÅÅÅÅÅÅÃÃÃÃÃÃÅÅÅÅÅÅÆÆÆÆÆÆÆÆÆÆÆÆÇÇÇ¿¿¿¼¼¼¾¾¾ÔÔÔíííóóóîîîîîîêêêãããÝÝÝÜÜÜÜÜÜÛÛÛÜÜÜÛÛÛâââèèèêêêêêêêêêçççâââãããäääãããââââââæææèèèàààâââãããäääãããâââßßßÜÜÜÛÛÛâââàààßßßßßßãããæææâââÊÊÊÐÐÐÜÜÜäääãããÝÝÝÝÝÝââââââÕÕÕÒÒÒÛÛÛÜÜÜÌÌ̺ºº°°°¸¸¸¾¾¾¾¾¾ººº»»»ººº¸¸¸ÀÀÀ¼¼¼¿¿¿ÅÅÅÌÌÌÐÐÐÑÑÑÍÍÍÊÊÊÊÊÊÇÇÇÃÃü¼¼µµµ°°°¬¬¬©©©©©©¨¨¨¨¨¨­­­µµµ»»»¼¼¼»»»»»»¸¸¸···¸¸¸»»»ÀÀÀÅÅÅÆÆÆÇÇÇÆÆÆÊÊÊÎÎÎÌÌÌÑÑÑ×××ÍÍͼ¼¼°°°¸¸¸¾¾¾×××···ÇÇÇ°°°ÅÅÅÅÅÅÀÀÀººº¬¬¬­­­°°°±±±´´´·········¸¸¸»»»¼¼¼ÂÂÂÃÃÃÅÅÅÃÃþ¾¾ººº¸¸¸ººº···´´´´´´···¸¸¸¸¸¸¸¸¸···¸¸¸¸¸¸ÃÃÃÊÊÊÔÔÔ¾¾¾¿¿¿ÆÆƼ¼¼ÇÇÇØØØÝÝÝÝÝÝÔÔÔÇÇDZ±±µµµ¾¾¾ÆÆÆÃÃÿ¿¿ÀÀÀÆÆÆ¿¿¿¾¾¾¼¼¼¾¾¾ÀÀÀÂÂÂÀÀÀ¿¿¿ÇÇÇÆÆƺººÂÂÂÀÀÀÒÒÒÒÒÒÛÛÛæææçççßßßÙÙÙÜÜÜßßßàààäääâââØØØÜÜÜàààäää×××µµµ¯¯¯···¸¸¸»»»¾¾¾ÂÂÂÆÆÆÉÉÉÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÊÊÊÊÊÊÊÊÊÌÌÌÊÊÊÊÊÊÉÉÉÇÇÇÇÇÇÆÆÆÆÆÆÅÅÅÅÅÅÅÅÅÆÆÆÆÆÆÆÆÆÆÆÆÇÇÇÆÆÆÅÅÅÂÂÂÂÂÂÂÂÂÃÃÃÅÅÅÆÆÆÃÃÃÅÅÅÆÆÆÇÇÇÇÇÇÇÇÇÇÇÇÇÇÇÃÃÿ¿¿ºººÃÃÃÝÝÝíííîîîîîîæææèèèèèèàààÝÝÝßßßÜÜÜ×××ÛÛÛÕÕÕßßßêêêèèèççççççßßßæææææææææäääãããäääçççèèèãããäääæææäääãããàààÜÜÜÙÙÙÜÜÜâââäääâââãããëëëêêêæææãããââââââßßßØØØÎÎÎÎÎÎÒÒÒÒÒÒÑÑÑØØØßßßÔÔÔ¾¾¾µµµ»»»ººº¿¿¿»»»ºººÂÂÂÂÂÂÀÀÀ¿¿¿ÅÅÅÃÃÃÅÅÅÉÉÉÍÍÍÐÐÐÍÍÍÊÊÊÇÇÇÅÅÅ¿¿¿ººº³³³¯¯¯¬¬¬ªªªªªª©©©©©©¯¯¯µµµºººººº···¸¸¸···´´´···¼¼¼ÀÀÀÅÅÅÆÆÆÅÅÅÃÃÃÌÌÌÐÐÐÍÍÍ×××ÙÙÙÐÐг³³µµµÅÅÅÆÆÆÔÔÔ¿¿¿³³³Â···ÉÉÉÃÃþ¾¾¸¸¸°°°±±±°°°³³³´´´·········¸¸¸ººº¼¼¼ÂÂÂÃÃÃÃÃÃÃÃÃÀÀÀ¾¾¾ººº······´´´³³³±±±´´´·········´´´···¸¸¸ÆÆÆÍÍÍ××׿¿¿ÀÀÀÉÉÉÆÆÆÃÃÃÃÃÃÅÅÅÑÑÑÜÜÜØØØÃÃõµµ°°°···ÃÃÃÃÃÿ¿¿¼¼¼¾¾¾ÂÂÂÆÆÆÆÆÆÅÅÅÉÉÉÎÎÎÇÇÇÅÅźººÃÃÿ¿¿»»»ÎÎÎàààæææãããâââÜÜÜÙÙÙâââçççÝÝÝâââçççêêêÕÕÕ³³³³³³¸¸¸ººº»»»¾¾¾ÂÂÂÆÆÆÉÉÉÌÌÌÊÊÊÊÊÊÊÊÊÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÍÍÍÌÌÌÌÌÌÊÊÊÉÉÉÇÇÇÇÇÇÆÆÆÆÆÆÆÆÆÇÇÇÇÇÇÉÉÉÉÉÉÉÉÉÊÊÊÇÇÇÅÅÅÃÃÃÂÂÂÀÀÀÂÂÂÅÅÅÆÆÆÆÆÆÆÆÆÆÆÆÇÇÇÇÇÇÇÇÇÇÇÇÇÇÇÆÆÆÀÀÀÂÂÂØØØòòòòòòäääâââäääçççäääÜÜÜÙÙÙÜÜÜÛÛÛÕÕÕÛÛÛÔÔÔÝÝÝêêêçççãããâââÙÙÙèèèèèèçççäääääääääæææççççççæææâââßßßÜÜÜÜÜÜÜÜÜÜÜÜÝÝÝàààæææãããçççïïïëëëêêêêêêàààØØØÒÒÒÎÎÎÍÍÍÒÒÒÛÛÛ×××ÒÒÒÒÒÒÒÒÒÉÉɺºº¸¸¸ÀÀÀ»»»ÅÅÅ¿¿¿ÀÀÀÅÅÅÀÀÀÃÃÃÅÅÅÉÉÉÇÇÇÆÆÆÇÇÇÊÊÊÍÍÍÌÌÌÊÊÊÆÆÆÃÃþ¾¾¸¸¸´´´±±±±±±°°°¯¯¯­­­¯¯¯³³³···ºººººº······µµµ´´´···¾¾¾ÃÃÃÅÅÅÃÃÃÆÆÆÅÅÅÎÎÎÎÎÎÎÎÎÔÔÔÍÍÍÅÅű±±ÀÀÀÒÒÒÑÑÑÔÔÔ³³³Â»»»ÊÊÊÃÃü¼¼ººº´´´···³³³´´´µµµ¸¸¸¸¸¸¸¸¸¸¸¸ººº¼¼¼ÂÂÂÂÂÂÃÃÃÃÃþ¾¾»»»¸¸¸µµµ³³³°°°¯¯¯±±±´´´µµµ···´´´¸¸¸»»»ÆÆÆÊÊÊÑÑѺºººººÃÃÃÌÌÌÇÇÇÀÀÀ¼¼¼ÅÅÅØØØÙÙÙÛÛÛÃÃñ±±¯¯¯ÇÇÇÒÒÒÐÐп¿¿ÅÅÅ¿¿¿¿¿¿ÃÃÃÇÇÇÊÊÊÊÊÊÃÃÃÇÇÇÇÇÇÉÉÉÅÅÅÎÎÎÉÉɼ¼¼»»»ÌÌÌÔÔÔÜÜÜçççæææãããîîîäääæææãããÝÝÝÝÝÝÍÍ͵µµ¸¸¸¸¸¸¸¸¸ººº¼¼¼ÀÀÀÅÅÅÉÉÉÌÌÌÊÊÊÊÊÊÌÌÌÌÌÌÌÌÌÌÌÌÍÍÍÍÍÍÎÎÎÍÍÍÍÍÍÌÌÌÊÊÊÉÉÉÉÉÉÉÉÉÉÉÉÉÉÉÉÉÉÊÊÊÊÊÊÌÌÌÌÌÌÌÌÌÉÉÉÇÇÇÅÅÅÃÃÃÃÃÃÅÅÅÆÆÆÇÇÇÉÉÉÇÇÇÇÇÇÆÆÆÆÆÆÆÆÆÇÇÇÇÇÇÇÇÇÂÂÂÒÒÒëëëñññëëëèèèçççëëëçççßßß×××ÔÔÔÕÕÕ×××ÕÕÕÙÙÙÕÕÕÜÜÜçççæææàààÝÝÝÜÜÜíííêêêçççäääããããããããããããäääâââÝÝÝÛÛÛÙÙÙÛÛÛÜÜÜÝÝÝàààÝÝÝæææäääèèèòòòëëëíííëëëÝÝÝÒÒÒÎÎÎÐÐÐÐÐÐÒÒÒ×××ÀÀÀ···±±±···»»»»»»¼¼¼ÀÀÀÀÀÀÊÊÊÃÃÃÆÆÆÆÆƼ¼¼ÀÀÀÅÅÅÆÆÆÆÆÆÆÆÆÇÇÇÊÊÊÊÊÊÊÊÊÉÉÉÆÆÆÃÃÿ¿¿ººº······¸¸¸¸¸¸´´´µµµ···ººº»»»¼¼¼»»»»»»···µµµµµµºººÀÀÀÅÅÅÅÅÅÂÂÂÅÅÅÆÆÆÍÍÍÉÉÉÍÍÍÎÎκºº´´´µµµÂÂÂÒÒÒÔÔÔÕÕÕ³³³ÆÆƸ¸¸ÊÊÊÃÃû»»ºººµµµººº···µµµ···¸¸¸ººº¸¸¸¸¸¸»»»¼¼¼ÀÀÀÂÂÂÃÃÃÃÃÿ¿¿¼¼¼ººº¸¸¸µµµ³³³±±±´´´¸¸¸ººº»»»¸¸¸¾¾¾¿¿¿ÉÉÉÊÊÊÐÐз··¸¸¸¼¼¼ÌÌÌÌÌÌÍÍÍÆÆÆÀÀÀÍÍÍÑÑÑÕÕÕ···°°°ÇÇÇÑÑÑØØØÑÑÑÆÆÆÃÃÃÂÂÂÂÂÂÅÅÅÉÉÉÌÌÌÍÍÍÐÐÐÌÌÌÍÍÍÎÎÎÊÊÊÍÍÍÍÍÍÅÅÅ¿¿¿¸¸¸ªªªµµµÑÑÑØØØÔÔÔÝÝÝÙÙÙâââÙÙÙ×××ÑÑѺºº­­­···µµµµµµ···ººº¾¾¾ÃÃÃÇÇÇÊÊÊÊÊÊÌÌÌÌÌÌÌÌÌÍÍÍÍÍÍÍÍÍÎÎÎÐÐÐÐÐÐÎÎÎÍÍÍÌÌÌÌÌÌÊÊÊÊÊÊÊÊÊÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÍÍÍÍÍÍÌÌÌÊÊÊÉÉÉÇÇÇÇÇÇÇÇÇÉÉÉÉÉÉÌÌÌÊÊÊÇÇÇÅÅÅÃÃÃÅÅÅÆÆÆÇÇÇÇÇÇÉÉÉÜÜÜîîîîîîîîîòòòòòòêêêâââÛÛÛ×××ÕÕÕÔÔÔÔÔÔÕÕÕÕÕÕÔÔÔ×××ßßßäääßßßßßßèèèîîîëëëèèèäääãããâââààààààÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜâââÛÛÛääääääêêêòòòëëëïïïàààÕÕÕÎÎÎÒÒÒØØØØØØÔÔÔÒÒÒºººµµµµµµ¸¸¸»»»¼¼¼ÀÀÀÅÅÅÃÃÃÇÇǾ¾¾ÅÅÅÊÊÊ¿¿¿ÃÃÃÆÆÆÂÂÂÃÃÃÆÆÆÇÇÇÉÉÉÉÉÉÉÉÉÇÇÇÇÇÇÅÅÅÀÀÀ¼¼¼»»»»»»¾¾¾¿¿¿¸¸¸»»»¼¼¼¾¾¾¿¿¿¾¾¾¾¾¾¾¾¾···µµµ···»»»ÂÂÂÆÆÆÃÃÃÀÀÀ¿¿¿ÅÅÅÌÌÌÇÇÇÑÑÑÑÑÑ···´´´···¾¾¾ÊÊÊÒÒÒÔÔÔÀÀÀ±±±ÇÇÇ´´´ÉÉÉÅÅż¼¼¸¸¸µµµººº¸¸¸µµµ¸¸¸ºººººº¸¸¸ººº»»»¼¼¼ÀÀÀÂÂÂÃÃÃÃÃÃÃÃÃÀÀÀ¾¾¾»»»¿¿¿»»»¸¸¸¸¸¸»»»¾¾¾ÀÀÀ»»»ÀÀÀÅÅÅÍÍÍÍÍÍÒÒÒ»»»¾¾¾ÂÂÂÍÍÍÌÌÌÒÒÒÌÌ̼¼¼ÉÉÉÐÐÐÕÕÕÅÅÅÀÀÀ···»»»¯¯¯¼¼¼ÊÊÊÇÇÇÅÅÅÃÃÃÂÂÂÅÅÅÉÉÉÍÍÍÐÐÐÒÒÒÌÌÌÔÔÔÙÙÙÐÐÐÆÆÆÉÉÉÊÊÊÃÃÃÅÅźºº³³³´´´¬¬¬³³³ÒÒÒÔÔÔÜÜÜÔÔÔÜÜÜÔÔÔªªª¥¥¥¸¸¸³³³³³³´´´···»»»ÀÀÀÆÆÆÉÉÉÌÌÌÌÌÌÌÌÌÍÍÍÍÍÍÎÎÎÎÎÎÎÎÎÑÑÑÐÐÐÐÐÐÎÎÎÍÍÍÌÌÌÌÌÌÊÊÊÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÎÎÎÍÍÍÌÌÌÌÌÌÊÊÊÊÊÊÊÊÊÌÌÌÎÎÎÌÌÌÇÇÇÃÃÃÂÂÂÃÃÃÆÆÆÇÇÇàààëëëíííëëëîîîèèèßßßÝÝÝâââÙÙÙ×××ÛÛÛÛÛÛ×××ÔÔÔÕÕÕÑÑÑÒÒÒÑÑÑÙÙÙãããßßßâââõõõîîîèèèãããàààâââàààÝÝÝÙÙÙØØØÛÛÛ×××ØØØßßßàààÜÜÜßßßäääæææææææææíííõõõñññçççÕÕÕÔÔÔÔÔÔÕÕÕØØØÕÕÕÌÌÌÅÅž¾¾¼¼¼»»»¼¼¼¿¿¿ÃÃÃÇÇÇÊÊÊÃÃÃÀÀÀÂÂÂÉÉÉÌÌÌÇÇÇÃÃÃÃÃÃÉÉÉÉÉÉÊÊÊÌÌÌÌÌÌÊÊÊÊÊÊÉÉÉÆÆÆÅÅż¼¼µµµ···¿¿¿Â¿¿¿¿¿¿¾¾¾¾¾¾¿¿¿ÂÂÂÃÃÃÀÀÀ¿¿¿¾¾¾ÂÂÂÃÃþ¾¾¾¾¾ÂÂÂÇÇÇÂÂÂÅÅÅÊÊÊÆÆÆÑÑÑÒÒÒ»»»»»»»»»¸¸¸¿¿¿¼¼¼ÒÒÒµµµÃÃõµµÂÂÂÆÆƾ¾¾»»»¿¿¿¼¼¼´´´¸¸¸¸¸¸ººº»»»¼¼¼¾¾¾¿¿¿¿¿¿ÆÆÆÂÂÂÀÀÀÂÂÂÀÀÀ»»»¸¸¸¼¼¼»»»¾¾¾¾¾¾ÀÀÀÅÅž¾¾¼¼¼ÆÆÆÃÃþ¾¾ÃÃÃÅÅÅÎÎÎÎÎλ»»¿¿¿ÆÆÆÐÐÐ×××ÔÔÔÊÊÊÂÂÂÀÀÀÅÅÅÌÌÌ×××àààèèèÙÙÙÇÇDZ±±ÊÊÊÇÇÇÍÍÍÐÐÐÌÌÌÐÐÐÕÕÕÑÑÑØØØÎÎÎÎÎÎÑÑÑÐÐÐÔÔÔÒÒÒÉÉÉÇÇÇÃÃþ¾¾»»»ººº···±±±­­­ÙÙÙÒÒÒâââÔÔÔ¯¯¯···ªªª³³³´´´»»»¸¸¸µµµ¿¿¿ÆÆÆÃÃÃÃÃÃÐÐÐÐÐÐÎÎÎÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÐÐÐÐÐÐÐÐÐÎÎÎÎÎÎÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÎÎÎÑÑÑÒÒÒÑÑÑÎÎÎÉÉÉÆÆÆÉÉÉÎÎÎÎÎÎÊÊÊÉÉÉÌÌÌÇÇǼ¼¼¿¿¿ÃÃÃÆÆÆÀÀÀÃÃÃèèèõõõúúúïïïîîîäääØØØßßßÛÛÛÔÔÔÜÜÜÜÜÜÜÜÜàààÛÛÛØØØàààÔÔÔÐÐÐÒÒÒ×××èèèçççÛÛÛóóóëëëçççãããâââàààßßßÛÛÛ×××ÐÐÐÙÙÙÙÙÙØØØÜÜÜÑÑÑÆÆÆÆÆÆÝÝÝâââæææèèèëëëëëëçççãããØØØÛÛÛàààäääãããØØØÇÇÇ»»»ÀÀÀÀÀÀÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÇÇÇÅÅÅÂÂÂÃÃÃÂÂÂÂÂÂÆÆÆÍÍÍÆÆÆÉÉÉÍÍÍÐÐÐÐÐÐÌÌÌÇÇÇÅÅÅÆÆÆÃÃþ¾¾¸¸¸ºººÀÀÀÃÃÃÀÀÀÅÅÅÃÃÃÀÀÀÀÀÀÂÂÂÅÅÅÆÆÆÆÆÆÆÆÆÀÀÀ¼¼¼¼¼¼ÀÀÀÅÅÅÃÃÃÂÂÂÇÇÇÇÇÇÌÌÌÆÆÆÍÍÍÑÑѼ¼¼µµµ»»»¾¾¾»»»ÂÂÂÒÒÒ¼¼¼¼¼¼¾¾¾»»»Â¼¼¼ººº¾¾¾¾¾¾¸¸¸ºººººº»»»¼¼¼¾¾¾¾¾¾¿¿¿¿¿¿ÅÅÅÂÂÂÂÂÂÃÃÿ¿¿ººº¸¸¸»»»ÂÂÂÃÃÃÅÅÅÉÉÉÍÍÍÍÍÍÊÊÊÉÉÉÇÇÇ¿¿¿ÂÂÂÅÅÅÐÐÐÎÎμ¼¼ÂÂÂÇÇÇÎÎÎÔÔÔÑÑÑÆÆƾ¾¾¾¾¾ÀÀÀÃÃÃÊÊÊÉÉÉÍÍÍÑÑÑÜÜÜàààÊÊÊÀÀÀ¼¼¼ÊÊÊØØØÔÔÔÊÊÊÌÌÌÍÍÍãããÍÍÍÍÍÍÜÜÜØØØÍÍÍÍÍÍÒÒÒÆÆƾ¾¾¼¼¼¾¾¾¾¾¾ºººµµµ¬¬¬­­­ÑÑÑÔÔÔ¬¬¬³³³¬¬¬°°°³³³ººº¸¸¸···ÀÀÀÇÇÇÆÆÆÉÉÉÐÐÐÐÐÐÎÎÎÍÍÍÍÍÍÍÍÍÎÎÎÎÎÎÐÐÐÐÐÐÐÐÐÎÎÎÎÎÎÎÎÎÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÐÐÐÑÑÑÑÑÑÐÐÐÐÐÐÒÒÒÍÍÍÉÉÉÉÉÉÊÊÊÊÊÊÊÊÊÌÌÌÆÆÆÐÐÐÝÝÝäääîîîíííêêêöööêêêêêêàààààààààÝÝÝäääâââßßßàààØØØÒÒÒØØØÙÙÙØØØÜÜÜÕÕÕÒÒÒÒÒÒÕÕÕæææèèèßßßñññæææäääãããâââßßßÜÜÜØØØÕÕÕ×××ßßßØØØ×××âââÛÛÛÌÌÌÎÎÎàààãããêêêïïïëëëâââÝÝÝÝÝÝàààààààààÝÝÝÙÙÙÑÑÑÉÉÉÅÅÅÃÃÃÃÃÃÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÆÆÆÃÃÃÃÃÃÇÇÇÇÇÇÅÅÅÆÆÆÉÉÉÉÉÉÌÌÌÎÎÎÑÑÑÐÐÐÌÌÌÇÇÇÃÃÃÃÃÃÃÃÿ¿¿¼¼¼¾¾¾ÂÂÂÃÃÃÂÂÂÃÃÃÃÃÿ¿¿¼¼¼»»»»»»¼¼¼Â¿¿¿¼¼¼¾¾¾ÂÂÂÅÅÅ¿¿¿¿¿¿ÀÀÀÊÊÊÉÉÉÍÍÍÕÕÕÅÅű±±µµµ¾¾¾¸¸¸ÃÃÃÊÊÊ´´´¾¾¾µµµÃÃÃÀÀÀ¾¾¾»»»»»»¼¼¼¾¾¾¾¾¾»»»»»»¼¼¼¾¾¾¾¾¾¿¿¿ÀÀÀÀÀÀÅÅÅÃÃÃÅÅÅÅÅÅÀÀÀ»»»ººº¼¼¼¿¿¿ÅÅÅÉÉÉÆÆÆÂÂÂÆÆÆÐÐÐ×××ÍÍÍÃÃÃÃÃÃÉÉÉÑÑÑÌÌ̾¾¾ÆÆÆÎÎÎÔÔÔ×××ÑÑÑÆÆÆ¿¿¿¾¾¾ÀÀÀ¾¾¾ÉÉÉÅÅÅ¿¿¿ÅÅÅÙÙÙàààÅÅÅÃÃû»»ÀÀÀÎÎÎÑÑÑÐÐÐÕÕÕÛÛÛÙÙÙÐÐÐØØØçççäääØØØÔÔÔ×××ÊÊÊÆÆÆÂÂÂÂÂÂÃÃÃÃÃÃÀÀÀ¾¾¾³³³±±±×××ÜÜÜ­­­±±±´´´¸¸¸´´´»»»¼¼¼¼¼¼ÂÂÂÇÇÇÉÉÉÌÌÌÐÐÐÎÎÎÎÎÎÍÍÍÍÍÍÎÎÎÎÎÎÐÐÐÑÑÑÐÐÐÐÐÐÐÐÐÐÐÐÎÎÎÎÎÎÎÎÎÍÍÍÎÎÎÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÍÍÍÌÌÌÊÊÊÊÊÊÍÍÍÎÎÎÌÌÌÉÉÉ»»»âââøøøøøøóóóññññññîîîíííçççÙÙÙØØØÛÛÛÛÛÛßßßÛÛÛããããããØØØÎÎÎÒÒÒØØØÕÕÕÒÒÒÕÕÕÕÕÕÒÒÒÑÑÑâââêêêãããîîîããããããâââàààÝÝÝÙÙÙØØØ×××ÔÔÔÑÑѾ¾¾¿¿¿ÜÜÜãããÙÙÙÝÝÝãããÝÝÝàààæææâââÔÔÔÎÎÎÒÒÒãããàààØØØÎÎÎÇÇÇÅÅÅÆÆÆÉÉÉÇÇÇÆÆÆÅÅÅÅÅÅÇÇÇÊÊÊÍÍÍÐÐÐÇÇÇÃÃÃÅÅÅÌÌÌÐÐÐÌÌÌÆÆÆÃÃÃÐÐÐÎÎÎÍÍÍÌÌÌÊÊÊÉÉÉÇÇÇÇÇÇÂÂÂÂÂÂÀÀÀÀÀÀÀÀÀ¿¿¿ÃÃÃÇÇÇÉÉÉÇÇÇÅÅÅÃÃÃÅÅÅÃÃÃÊÊÊÐÐÐÎÎÎÆÆÆÃÃÃÆÆÆÌÌÌÒÒÒÎÎÎÎÎÎÉÉÉÍÍÍâââäääÑÑѵµµ»»»ÆÆÆÇÇÇÀÀÀ···»»»»»»ÇÇÇ¿¿¿»»»¼¼¼¿¿¿¼¼¼¾¾¾ÀÀÀ¾¾¾¾¾¾¾¾¾¿¿¿ÀÀÀÀÀÀÂÂÂÂÂÂÃÃÃÅÅÅÇÇÇÇÇÇÃÃÃÀÀÀÀÀÀÂÂÂÆÆÆÉÉÉÃÃúºº´´´°°°···ÆÆÆÍÍÍÉÉÉÉÉÉÎÎÎÐÐÐÃÃü¼¼ÉÉÉÒÒÒÔÔÔÔÔÔÎÎÎÆÆÆ¿¿¿¾¾¾¿¿¿ÇÇÇÙÙÙÙÙÙÎÎÎÇÇÇÒÒÒßßßÍÍÍÇÇÇÃÃÃÃÃÃÇÇÇÎÎÎÕÕÕÔÔÔÍÍÍÙÙÙæææèèèÝÝÝ×××ÛÛÛÙÙÙÍÍÍÑÑÑÌÌÌÇÇÇÅÅÅÆÆÆÅÅÅ¿¿¿···´´´ÍÍÍÕÕÕ¯¯¯°°°°°°¸¸¸···¼¼¼ÀÀÀÃÃÃÅÅÅÆÆÆÉÉÉÌÌÌÎÎÎÎÎÎÎÎÎÎÎÎÎÎÎÐÐÐÐÐÐÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÍÍÍÐÐÐÒÒÒÑÑÑÐÐÐÎÎÎÎÎÎÐÐÐÆÆÆÌÌÌÐÐÐÐÐÐÍÍÍÊÊÊÆÆÆÀÀÀÃÃÃëëëüüüüüüóóóñññúúúñññïïïêêêâââàààâââäääèèèèèèÛÛÛâââßßßÕÕÕÕÕÕÙÙÙÕÕÕÌÌÌÕÕÕØØØÒÒÒÎÎÎÝÝÝèèèçççëëëäääãããâââßßßÛÛÛØØØ××××××ÔÔÔÐÐп¿¿ÀÀÀÜÜÜäääÝÝÝààà×××ÉÉÉÃÃÃÌÌÌÍÍÍÆÆÆÂÂÂÇÇÇÃÃÃÆÆÆÊÊÊÌÌÌÌÌÌÎÎÎÔÔÔØØØÎÎÎÎÎÎÍÍÍÌÌÌÊÊÊÌÌÌÍÍÍÍÍÍÌÌÌÊÊÊÌÌÌÎÎÎÍÍÍÇÇÇÇÇÇÊÊÊÐÐÐÎÎÎÍÍÍÊÊÊÉÉÉÇÇÇÆÆÆÆÆÆÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÀÀÀÀÀÀÀÀÀÃÃÃÆÆÆÊÊÊÊÊÊÇÇÇÅÅÅÅÅÅÅÅż¼¼ÃÃÃÆÆƼ¼¼­­­©©©±±±¾¾¾ÌÌÌÍÍÍÍÍÍÊÊÊÌÌÌÜÜÜÝÝÝÆÆƸ¸¸»»»ØØØÌÌÌ»»»ÃÃúººÊÊÊÆÆƾ¾¾»»»ÀÀÀ¾¾¾¾¾¾ÂÂÂÀÀÀÀÀÀÀÀÀÀÀÀÂÂÂÂÂÂÃÃÃÃÃÃÂÂÂÆÆÆÉÉÉÊÊÊÉÉÉÇÇÇÇÇÇÇÇÇÍÍÍÃÃñ±±¯¯¯ººº±±±¬¬¬ºººÊÊÊÐÐÐÐÐÐÑÑÑÊÊÊ»»»»»»ÉÉÉÐÐÐÑÑÑÐÐÐÊÊÊÅÅÅ¿¿¿¾¾¾¿¿¿ÇÇÇÕÕÕØØØÒÒÒÆÆÆÍÍÍâââßßßÊÊÊÉÉÉÅÅÅÂÂÂÆÆÆÍÍÍÑÑÑÕÕÕÒÒÒÛÛÛÕÕÕÃÃÃÂÂÂÒÒÒâââæææÒÒÒÍÍÍÇÇÇÆÆÆÇÇÇÇÇÇÅÅż¼¼¼¼¼ÌÌÌßßßÍÍÍÃÃð°°´´´µµµºººÀÀÀÆÆÆÇÇÇÉÉÉÌÌÌÍÍÍÍÍÍÍÍÍÍÍÍÎÎÎÎÎÎÐÐÐÑÑÑÒÒÒÒÒÒÒÒÒÔÔÔÔÔÔÔÔÔÔÔÔÔÔÔÔÔÔÐÐÐÒÒÒÔÔÔÒÒÒÐÐÐÎÎÎÎÎÎÐÐÐÍÍÍÐÐÐÑÑÑÌÌÌÅÅÅÂÂÂÅÅÅÇÇÇèèèöööõõõøøøöööóóóöööçççÝÝÝÜÜÜÛÛÛÔÔÔÐÐÐÎÎÎÐÐÐÒÒÒÒÒÒßßßäääÜÜÜÕÕÕØØØØØØÑÑÑÔÔÔÙÙÙÒÒÒÎÎÎÙÙÙäääêêêèèèæææäääâââÝÝÝÛÛÛÕÕÕÑÑÑÎÎκºº¿¿¿¿¿¿ÀÀÀÆÆƺºº¸¸¸ÇÇǺºº´´´¾¾¾ÆÆÆÆÆÆÆÆÆÌÌÌÌÌÌÎÎÎÑÑÑÑÑÑÎÎÎÍÍÍÎÎÎÐÐÐÕÕÕÕÕÕÒÒÒÐÐÐÍÍÍÉÉÉÆÆÆÃÃÃÉÉÉÐÐÐÙÙÙÛÛÛÑÑÑÆÆÆÆÆÆÍÍÍÉÉÉÊÊÊÌÌÌÌÌÌÊÊÊÆÆÆÃÃÃÀÀÀÂÂÂÀÀÀÂÂÂÂÂÂÀÀÀ¼¼¼¼¼¼¿¿¿ÃÃÃÃÃÃÃÃÃÂÂÂÀÀÀÂÂÂÃÃÃÅÅÅÑÑÑÍÍ͵µµ¬¬¬¬¬¬µµµ¾¾¾ÐÐÐÝÝÝãããèèèçççàààÒÒÒµµµ³³³ºººÒÒÒÃÃ÷··ÆÆÆ···ÍÍÍÅÅÅ¿¿¿¾¾¾ÂÂÂÃÃÿ¿¿¿¿¿ÃÃÃÂÂÂÂÂÂÃÃÃÃÃÃÃÃÃÃÃÃÅÅÅÅÅÅÃÃÃÇÇÇÊÊÊÊÊÊÌÌÌÎÎÎÌÌÌÉÉÉÔÔÔÊÊÊ···¯¯¯´´´´´´ºººÌÌÌÉÉÉÒÒÒÍÍÍÊÊÊÃÃ÷··¾¾¾ÊÊÊÔÔÔÔÔÔÒÒÒÐÐÐÍÍÍÊÊÊÉÉÉÉÉÉÉÉÉÍÍÍÎÎÎÒÒÒÉÉÉÆÆÆÑÑÑÍÍÍÛÛÛ×××ÒÒÒÐÐÐÌÌÌÅÅÅÐÐÐäääÔÔÔÊÊÊÂÂÂÂÂÂÀÀÀ¾¾¾ÊÊÊãããÑÑÑÍÍÍÇÇÇÆÆÆÉÉÉÊÊÊÊÊÊÇÇǸ¸¸µµµ»»»ØØØ×××ÌÌÌ´´´´´´µµµ´´´¼¼¼ÆÆÆÇÇÇÊÊÊÐÐÐÑÑÑÍÍÍÍÍÍÍÍÍÎÎÎÐÐÐÑÑÑÒÒÒÔÔÔÕÕÕÕÕÕÕÕÕÕÕÕ××××××××××××ÔÔÔÔÔÔÕÕÕÔÔÔÒÒÒÐÐÐÐÐÐÐÐÐÑÑÑÊÊÊÅÅÅÃÃÃÃÃÃÊÊÊÙÙÙèèèüüüøøøóóóöööïïïæææãããÛÛÛàààßßßâââØØØÎÎÎÌÌÌÆÆÆÌÌÌÑÑÑÙÙÙâââÜÜÜÒÒÒÕÕÕÜÜÜÛÛÛÒÒÒØØØÑÑÑÑÑÑ×××ßßßèèèæææçççäääâââßßßÙÙÙÑÑÑÆÆƾ¾¾¸¸¸¼¼¼ÆÆÆÇÇǾ¾¾···´´´°°°¾¾¾···¸¸¸ÀÀÀÉÉÉÊÊÊÍÍÍÒÒÒÕÕÕÔÔÔÒÒÒÑÑÑÐÐÐÐÐÐÒÒÒÔÔÔÔÔÔÑÑÑÍÍÍÉÉÉÇÇÇÇÇÇÊÊÊÌÌÌÎÎÎÒÒÒÛÛÛàààÛÛÛÎÎÎÆÆÆÆÆÆÆÆÆÇÇÇÉÉÉÉÉÉÇÇÇÅÅÅ¿¿¿ÂÂÂÀÀÀÀÀÀ¾¾¾¸¸¸¸¸¸¼¼¼¾¾¾¿¿¿ÂÂÂÆÆÆÊÊÊÌÌÌÊÊÊÉÉÉÃÃû»»°°°ªªªªªª°°°´´´···ÊÊÊ×××ÑÑÑÑÑÑÑÑÑÇÇÇÀÀÀ±±±°°°ÃÃþ¾¾¼¼¼¼¼¼ÇÇÇÂÂÂÉÉÉÃÃÃÂÂÂÀÀÀÂÂÂÀÀÀÀÀÀÂÂÂÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÆÆÆÉÉÉÊÊÊÉÉÉÍÍÍÐÐÐÊÊÊÃÃÃÒÒÒÑÑÑÎÎξ¾¾ªªª³³³ÉÉÉÐÐÐÊÊÊÑÑÑ»»»¼¼¼ºººÆÆÆÊÊÊÒÒÒÒÒÒÒÒÒÒÒÒÔÔÔÒÒÒÑÑÑÐÐÐÒÒÒÔÔÔÔÔÔÙÙÙÑÑÑÊÊÊÎÎÎÃÃÃÝÝÝâââãããçççâââÍÍÍÂÂÂÌÌÌÅÅÅÀÀÀÀÀÀÌÌÌÍÍÍ¿¿¿ÀÀÀØØØÕÕÕÐÐÐÊÊÊÇÇÇÊÊÊÌÌÌÌÌÌÊÊÊÀÀÀ´´´µµµÛÛÛâââãããÙÙÙÜÜÜ¿¿¿···ºººÂÂÂÂÂÂÇÇÇÐÐÐÑÑÑÌÌÌÌÌÌÍÍÍÎÎÎÐÐÐÒÒÒÔÔÔÕÕÕ××××××ØØØØØØÙÙÙÙÙÙÙÙÙÙÙÙØØØ×××ÕÕÕÕÕÕÔÔÔÒÒÒÑÑÑÎÎÎÌÌÌ¿¿¿¼¼¼ÍÍÍÜÜÜãããîîîúúúõõõíííõõõöööêêêääääääèèèÎÎÎÊÊÊÑÑÑÌÌÌÌÌÌÐÐÐÊÊÊÐÐÐÑÑÑÒÒÒÙÙÙÙÙÙÒÒÒÕÕÕÝÝÝÜÜÜÐÐÐÕÕÕÐÐÐÔÔÔ×××ÙÙÙçççæææèèèæææãããàààÙÙÙÍÍ;¾¾±±±ºººµµµ¼¼¼¿¿¿µµµ···¾¾¾¸¸¸´´´···¼¼¼ÃÃÃÆÆÆÇÇÇÊÊÊÎÎÎÒÒÒÒÒÒÒÒÒÒÒÒÒÒÒÒÒÒÒÒÒÒÒÒÍÍÍÆÆÆ¿¿¿»»»¿¿¿ÊÊÊ×××àààãããØØØÑÑÑÕÕÕÛÛÛ×××ÍÍÍÅÅÅÉÉÉÇÇÇÅÅÅÃÃÃÂÂÂÂÂÂÂÂÂÃÃÿ¿¿¿¿¿ÀÀÀ¼¼¼µµµµµµ»»»ÃÃÃÆÆÆÉÉÉÌÌÌÉÉɾ¾¾°°°¦¦¦ªªª¨¨¨¦¦¦ªªª°°°µµµ···µµµ¸¸¸ÅÅŸ¸¸¸¸¸¾¾¾´´´´´´±±±···×××´´´ÂÂÂÍÍÍÐÐÐ×××ÌÌÌÂÂÂÃÃÃÃÃÃÀÀÀ¿¿¿ÀÀÀÅÅÅÇÇÇÅÅÅÅÅÅÅÅÅÅÅÅÆÆÆÆÆÆÆÆÆÆÆÆÉÉÉÊÊÊÉÉÉÇÇÇÌÌÌÎÎÎÇÇǾ¾¾¯¯¯···ÎÎÎÊÊʵµµÊÊÊßßßÊÊÊÌÌÌÐÐи¸¸°°°¸¸¸¿¿¿ÌÌÌÊÊÊÆÆÆÇÇÇÉÉÉÊÊÊÍÍÍÎÎÎÍÍÍÊÊÊÌÌÌÎÎÎÊÊÊÌÌÌÇÇÇÊÊÊØØØÑÑÑÆÆÆÎÎÎÐÐÐØØØäääàààÍÍÍÃÃÃÊÊÊÔÔÔÒÒÒÍÍÍÌÌÌÅÅÅ¿¿¿ÆÆÆÛÛÛÕÕÕÎÎÎÊÊÊÊÊÊÌÌÌÉÉÉÇÇÇÇÇdz³³´´´ÛÛÛÛÛÛÝÝÝÛÛÛÙÙÙÊÊʼ¼¼ººº¾¾¾¼¼¼ÂÂÂÌÌÌÍÍÍÌÌÌÌÌÌÍÍÍÎÎÎÐÐÐÒÒÒÕÕÕ×××ØØØØØØÙÙÙÙÙÙÛÛÛÛÛÛÛÛÛÜÜÜÙÙÙØØØÕÕÕÕÕÕ×××ÕÕÕÑÑÑÎÎÎÉÉɼ¼¼ÂÂÂâââøøøöööîîîîîîùùùçççíííêêêàààâââÜÜÜßßßÑÑÑÇÇÇÌÌÌÇÇÇÌÌÌÒÒÒÊÊÊÍÍÍÐÐÐÌÌÌÔÔÔÙÙÙ×××ØØØÛÛÛØØØÎÎÎÔÔÔÐÐÐÕÕÕÕÕÕÕÕÕææææææÝÝÝÝÝÝãããÛÛÛÒÒÒÇÇǵµµ´´´µµµ»»»ÀÀÀÂÂÂÀÀÀ¾¾¾»»»»»»¸¸¸»»»¾¾¾ÂÂÂÇÇÇÍÍÍÒÒÒ××××××àààÜÜÜÒÒÒÔÔÔÕÕÕÒÒÒ××׿¿¿ÊÊÊÊÊÊÃÃû»»´´´µµµÇÇÇÌÌÌÉÉÉÍÍÍãããÕÕÕÐÐÐÀÀÀÅÅÅÃÃÃÂÂÂÀÀÀ¾¾¾¾¾¾¼¼¼¼¼¼»»»ÀÀÀÃÃÿ¿¿ººº¸¸¸······»»»ÊÊÊÎÎξ¾¾¯¯¯­­­¯¯¯­­­ªªª©©©¸¸¸¾¾¾¬¬¬¬¬¬ºººººº¿¿¿´´´···¼¼¼······¾¾¾¿¿¿ÍÍͼ¼¼ÀÀÀººº···ÊÊÊÌÌ̾¾¾ÀÀÀÂÂÂÃÃÃÃÃÃÅÅÅÅÅÅÅÅÅÅÅÅÉÉÉÉÉÉÅÅÅÅÅÅÌÌÌÉÉÉÇÇÇÒÒÒÒÒÒÅÅÅÐÐÐÉÉÉÌÌÌÑÑѸ¸¸µµµººº¿¿¿ÍÍÍÔÔÔÐÐÐÐÐÐÑÑÑÌÌÌØØØÊÊÊ»»»···¾¾¾ÅÅÅÆÆÆÃÃÃÀÀÀÃÃÃÃÃÃÅÅÅÅÅż¼¼ºººÅÅÅÃÃÿ¿¿ÀÀÀÅÅÅÃÃÃÆÆÆÐÐÐÐÐп¿¿ÆÆÆ×××êêêÆÆÆÉÉÉÙÙÙêêêèèèãããÕÕÕÅÅÅÀÀÀºººÔÔÔÐÐÐ×××ÑÑÑÍÍÍÎÎÎÆÆÆÍÍÍÊÊÊÀÀÀ···´´´ÐÐÐäääÛÛÛààààààÑÑÑ»»»···¾¾¾¾¾¾ÂÂÂÒÒÒÌÌÌÅÅÅÉÉÉÉÉÉÍÍÍÒÒÒÎÎÎÔÔÔÔÔÔÔÔÔÕÕÕØØØÛÛÛÜÜÜÝÝÝßßßÛÛÛÑÑÑÑÑÑ××××××ÙÙÙÔÔÔÆÆƼ¼¼ÇÇÇæææøøøòòòõõõõõõäääâââäääëëëäääããããããÑÑÑÆÆÆÉÉÉÊÊÊÊÊÊÌÌÌÌÌÌÍÍÍÎÎÎÎÎÎÎÎÎÑÑÑÊÊÊÙÙÙçççÛÛÛÒÒÒÒÒÒÕÕÕÐÐÐÍÍÍÎÎÎÑÑÑ×××âââîîîèèèßßßàààØØØÌÌ̾¾¾³³³»»»¼¼¼¿¿¿Â¿¿¿¼¼¼»»»»»»¼¼¼¼¼¼¿¿¿ÅÅÅÊÊÊÎÎÎÎÎÎÍÍÍÃÃÃÍÍÍÌÌÌÆÆÆÉÉÉÊÊÊÇÇÇÊÊÊÅÅÅÍÍÍÌÌÌÅÅÅÆÆÆÅÅÅ¿¿¿ÀÀÀ¾¾¾¼¼¼¾¾¾ÌÌÌãããÔÔÔÐÐÐÉÉÉÃÃÃÃÃÃÀÀÀ¿¿¿¾¾¾¾¾¾¾¾¾¾¾¾Â¼¼¼ººº¼¼¼»»»···¸¸¸¼¼¼¿¿¿Â¾¾¾±±±­­­±±±´´´±±±ªªª­­­ÂÂÂÌÌ̺ºº±±±¸¸¸¸¸¸»»»¸¸¸¿¿¿ÃÃø¸¸µµµÃÃÃÎÎμ¼¼¸¸¸¸¸¸ÂÂÂÉÉÉÎÎÎÎÎÎÃÃÃÂÂÂÂÂÂÂÂÂÃÃÃÃÃÃÅÅÅÆÆÆÆÆÆÇÇÇÊÊÊÇÇÇÉÉÉÍÍÍÉÉÉÊÊÊÕÕÕÜÜÜÐÐÐØØØÑÑÑÐÐÐÎÎεµµµµµ¾¾¾¼¼¼ººº¿¿¿ÍÍÍÕÕÕÕÕÕÒÒÒÅÅž¾¾¸¸¸¼¼¼ÅÅÅÉÉÉÆÆÆÀÀÀ¿¿¿ÀÀÀ»»»»»»ÂÂÂÃÃÃÅÅÅÐÐÐÔÔÔÒÒÒÃÃÃÀÀÀÅÅÅ¿¿¿ÃÃÃÍÍÍÕÕÕÑÑÑÐÐÐÊÊÊÌÌÌãããÑÑÑØØØãããâââÝÝÝäääßßßÑÑÑÌÌÌ¿¿¿ÇÇÇÍÍÍÙÙÙÒÒÒÑÑÑ×××ÎÎÎÍÍÍÊÊÊÅÅÅ»»»´´´ÇÇÇßßßâââãããßßßàààÝÝÝØØØÍÍÍ»»»···ÆÆÆÆÆÆÆÆÆÊÊÊÃÃÃÆÆÆÒÒÒÒÒÒÕÕÕÑÑÑÔÔÔ×××ÕÕÕÔÔÔÕÕÕÙÙÙÝÝÝßßßÙÙÙàààäääÛÛÛÑÑÑÌÌÌÅÅÅÎÎÎÝÝÝñññõõõíííêêêèèèäääßßßÝÝÝãããÛÛÛ××××××ÍÍÍÌÌÌÊÊÊÊÊÊÊÊÊÌÌÌÌÌÌÍÍÍÍÍÍÍÍÍÊÊÊÍÍÍÊÊÊÛÛÛâââ×××ÒÒÒÑÑÑÐÐÐÍÍÍÌÌÌÎÎÎÑÑÑÔÔÔÜÜÜæææçççßßßÝÝÝÍÍͼ¼¼······ÂÂÂÂÂÂÂÂÂÃÃÃÀÀÀ¿¿¿¾¾¾¾¾¾¿¿¿¼¼¼ÃÃÃÊÊÊÉÉÉÅÅÅÅÅÅÊÊÊÑÑÑÇÇÇÎÎÎÍÍÍÉÉÉÉÉÉÆÆÆÃÃÃÃÃÃÅÅÅÐÐÐÔÔÔÔÔÔÙÙÙÒÒÒÅÅž¾¾ÃÃÃÀÀÀ»»»ÃÃÃÕÕÕÍÍÍÍÍÍÅÅÅÂÂÂÂÂÂÀÀÀ¿¿¿¿¿¿¿¿¿¿¿¿ÀÀÀÅÅż¼¼¼¼¼ÃÃÿ¿¿´´´³³³»»»ÊÊÊ»»»­­­­­­µµµ¼¼¼¸¸¸°°°¯¯¯­­­ÀÀÀÐÐÐÀÀÀ´´´¸¸¸»»»¾¾¾¾¾¾Âººº¸¸¸ÂÂÂÉÉÉÃÃúººÊÊÊÔÔÔÆÆÆÃÃþ¾¾ÂÂÂÂÂÂÂÂÂÂÂÂÃÃÃÅÅÅÇÇÇÇÇÇÇÇÇÌÌÌÌÌÌÌÌÌÌÌÌÊÊÊÍÍÍØØØÙÙÙÍÍÍÕÕÕÑÑÑÐÐÐÎÎο¿¿ÆÆÆÃÃÃÃÃø¸¸µµµÌÌÌÛÛÛ×××ÒÒÒ¼¼¼»»»¼¼¼ÂÂÂÉÉÉÊÊÊÅÅž¾¾¾¾¾¿¿¿¸¸¸¸¸¸ÆÆÆÑÑÑÔÔÔØØØÜÜÜßßß»»»ÅÅž¾¾ÀÀÀÌÌÌÐÐÐÐÐÐÕÕÕÎÎÎÅÅÅâââÜÜÜâââÎÎÎÅÅÅÃÃÃÔÔÔÛÛÛßßßâââÍÍÍ»»»ÇÇÇ×××ÒÒÒÔÔÔÜÜÜÕÕÕÍÍÍÊÊÊÉÉÉ¿¿¿ººº¼¼¼ÑÑÑçççäääæææîîîñññêêêØØØÅÅÅÅÅÅÕÕÕääääääâââÉÉÉÀÀÀÍÍÍÍÍÍÎÎÎÎÎÎÑÑÑÕÕÕ×××ØØØÙÙÙÜÜÜßßßÛÛÛÜÜÜããããããÒÒÒÅÅÅÆÆÆÉÉÉâââòòòùùùòòòçççààààààæææñññæææäääÙÙÙÑÑÑÍÍÍÇÇÇÐÐÐÊÊÊÊÊÊÊÊÊÌÌÌÌÌÌÌÌÌÌÌÌÌÌÌÆÆÆÆÆÆÌÌÌÝÝÝÜÜÜÑÑÑÔÔÔÐÐÐÌÌÌÊÊÊÌÌÌÐÐÐÑÑÑÐÐÐÕÕÕÜÜÜÛÛÛÜÜÜßßßÅÅű±±ººº¿¿¿ÂÂÂÃÃÃÃÃÃÃÃÃÂÂÂÀÀÀÀÀÀÀÀÀ¾¾¾ÅÅÅÊÊÊÇÇÇÂÂÂÃÃÃÍÍÍ×××ÕÕÕ×××ÕÕÕÑÑÑÐÐÐÍÍÍÊÊÊÉÉÉÑÑÑÙÙÙØØØÕÕÕÛÛÛ×××ÊÊÊÃÃÃÌÌÌÍÍÍÀÀÀ¼¼¼ÆÆÆÊÊÊÎÎÎÀÀÀÃÃÃÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÃÃÃÃÃÿ¿¿ÂÂÂÅÅž¾¾´´´···Â¾¾¾´´´°°°···¼¼¼¾¾¾¼¼¼¾¾¾¸¸¸¬¬¬³³³ÀÀÀ»»»³³³ºººÀÀÀÆÆÆÆÆÆÃÃÃÀÀÀÅÅÅÎÎÎÌÌÌ¿¿¿ÌÌÌ¿¿¿¸¸¸ÌÌÌÑÑÑÃÃÃÃÃÃÆÆÆÃÃÃÂÂÂÂÂÂÀÀÀÂÂÂÅÅÅÉÉÉÊÊÊÉÉÉÍÍÍÎÎÎÍÍÍÊÊÊÌÌÌÒÒÒÛÛÛ¿¿¿µµµ¼¼¼»»»»»»»»»¸¸¸ÅÅÅÃÃÃÊÊÊÅÅŸ¸¸ÂÂÂÕÕÕÔÔÔÀÀÀ¾¾¾¾¾¾¾¾¾ÂÂÂÇÇÇÊÊÊÇÇÇÅÅż¼¼ÀÀÀ»»»¼¼¼ÐÐÐÜÜÜÛÛÛØØØ×××ÝÝݼ¼¼µµµÇÇÇÀÀÀÂÂÂÌÌÌÉÉÉÆÆÆÎÎÎÑÑÑÅÅÅÛÛÛÕÕÕÕÕÕÌÌÌÉÉÉÆÆÆÉÉÉÇÇÇØØØãããÆÆƺººÂÂÂÍÍÍÎÎÎÑÑÑ×××ÔÔÔÑÑÑÍÍÍÇÇÇÀÀÀÀÀÀ···ÃÃÃææææææêêêêêêëëëêêêãããÝÝÝâââîîîëëëíííëëëÔÔÔÅÅÅÇÇÇÀÀÀÂÂÂÍÍÍÎÎÎÑÑÑ×××ÜÜÜÝÝÝÜÜÜÙÙÙâââàààÙÙÙÌÌÌÂÂÂÉÉÉÛÛÛêêêïïïöööùùùïïïãããàààäääçççæææÔÔÔÐÐÐÌÌÌÊÊÊÉÉÉÇÇÇÔÔÔÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÃÃÃÃÃÃÍÍÍßßßÙÙÙÎÎÎÕÕÕÑÑÑÊÊÊÉÉÉÍÍÍÑÑÑÒÒÒÎÎÎÐÐÐÔÔÔÙÙÙÝÝÝæææÍÍ͵µµ¼¼¼ÃÃÃÅÅÅÆÆÆÆÆÆÅÅÅÃÃÃÃÃÃÀÀÀ¿¿¿¾¾¾Â¿¿¿¿¿¿ÅÅÅÍÍÍÑÑÑÑÑÑÎÎÎÐÐÐÍÍÍÍÍÍÎÎÎÎÎÎÎÎÎÎÎÎÍÍÍÒÒÒÛÛÛØØØÕÕÕÙÙÙ×××ÍÍÍÉÉÉÉÉÉÊÊÊ¿¿¿ÃÃÃÉÉÉÐÐÐÔÔÔÇÇÇÅÅÅÃÃÃÃÃÃÃÃÃÃÃÃÅÅÅÆÆÆÆÆÆÃÃÃÀÀÀ¾¾¾¼¼¼¼¼¼¿¿¿ÃÃÃÆÆÆ´´´ºººÃÃÃÉÉɾ¾¾ÌÌÌÝÝÝÉÉɳ³³­­­···¸¸¸´´´ºººÂÂÂÂÂÂÆÆÆÀÀÀ»»»ÉÉÉØØØÍÍÍ´´´ÑÑѸ¸¸ÀÀÀÎÎÎÇÇÇÃÃÃÂÂÂÇÇÇÃÃÃÃÃÃÂÂÂÂÂÂÃÃÃÇÇÇÊÊÊÌÌÌÍÍÍÎÎÎÎÎÎÌÌÌÉÉÉÍÍÍÕÕÕÙÙÙÃÃÃÀÀÀÇÇÇÇÇÇÃÃÃÀÀÀ¾¾¾ÆÆÆÀÀÀÆÆÆÇÇǸ¸¸···ÕÕÕØØس³³¼¼¼¼¼¼¾¾¾¿¿¿ÂÂÂÅÅÅÇÇÇÇÇǾ¾¾ÀÀÀ»»»¼¼¼ÎÎÎÛÛÛ×××ÒÒÒÐÐÐÙÙÙÀÀÀ¼¼¼ÐÐÐÊÊÊÃÃÃÊÊÊÌÌÌÅÅÅÊÊÊÕÕÕÃÃÃÉÉÉÃÃÃÉÉÉÙÙÙÙÙÙØØØÒÒÒÃÃÃÌÌÌßßßÎÎÎÃÃÃÂÂÂÂÂÂÉÉÉÊÊÊÇÇÇÍÍÍÔÔÔÐÐÐÅÅÅÂÂÂÇÇÇ···¼¼¼àààçççææææææëëëñññïïïíííîîîïïïñññòòòùùùîîîßßßÑÑÑÀÀÀ¾¾¾µµµ»»»ÃÃÃÉÉÉÍÍÍÒÒÒØØØÝÝÝÜÜÜßßß×××ÊÊÊÐÐÐãããóóóùùùöööñññóóóîîîàààãããêêêàààãããÌÌÌÆÆÆÆÆÆÊÊÊÊÊÊÅÅÅÎÎÎÊÊÊÊÊÊÊÊÊÉÉÉÉÉÉÇÇÇÇÇÇÇÇÇÂÂÂÂÂÂÌÌÌßßßÙÙÙÎÎÎ×××ÒÒÒÌÌÌÌÌÌÐÐÐÔÔÔÔÔÔÐÐÐÐÐÐÒÒÒæææßßßêêêÝÝÝ»»»¿¿¿ÇÇÇÌÌÌÉÉÉÆÆÆÃÃÿ¿¿»»»¸¸¸¼¼¼¾¾¾ÃÃÃÌÌÌÒÒÒÔÔÔÐÐÐÊÊÊÎÎÎÇÇÇÊÊÊÎÎÎÌÌÌÊÊÊÊÊÊÇÇÇÊÊÊÕÕÕØØØÕÕÕØØØ×××ÐÐÐÎÎÎÇÇÇÀÀÀ¼¼¼ÔÔÔÔÔÔÐÐÐÍÍÍÉÉÉÅÅÅÅÅÅÃÃÃÃÃÃÃÃÃÅÅÅÅÅÅÆÆÆÆÆÆÅÅÅÀÀÀÀÀÀÅÅÅÅÅż¼¼°°°µµµ´´´´´´µµµ³³³³³³¼¼¼ÉÉÉÕÕÕ¸¸¸¼¼¼¿¿¿»»»¼¼¼ÂÂÂÌÌÌÒÒÒÍÍÍÅÅÅÌÌÌÑÑÑÃÃó³³ÌÌ̸¸¸ÊÊÊÑÑÑÃÃÿ¿¿ÀÀÀÃÃÃÃÃÃÃÃÃÅÅÅÆÆÆÉÉÉÌÌÌÍÍÍÐÐÐÍÍÍÍÍÍÌÌÌÊÊÊÑÑÑÕÕÕÑÑÑ¿¿¿ÆÆÆÎÎÎÐÐÐÌÌÌÇÇÇÅÅÅÅÅÅÉÉÉÃÃÃÅÅÅ»»»¼¼¼àààççç»»»¿¿¿ÀÀÀÂÂÂÀÀÀ¼¼¼ºººººº»»»¼¼¼¼¼¼µµµ¸¸¸ÇÇÇÐÐÐÎÎÎÎÎÎÒÒÒÙÙÙÐÐÐÊÊÊØØØÕÕÕÃÃÃÅÅÅÆÆÆÅÅÅÇÇÇÔÔÔÃÃÃÂÂÂÂÂÂÑÑÑÑÑÑÐÐÐÒÒÒØØØÊÊÊÇÇÇÝÝÝäääÑÑÑÉÉÉ¿¿¿ÆÆÆÅÅž¾¾ÉÉÉÔÔÔÑÑÑÃÃÃÃÃÃÇÇÇ»»»ÃÃÃâââêêêëëëíííóóóõõõëëëæææèèèèèèëëëèèèòòòóóóòòòñññçççëëëëëëïïïñññäääÔÔÔÊÊÊÍÍÍÔÔÔÎÎÎÔÔÔÎÎÎÍÍÍÝÝÝñññõõõòòòøøøíííïïïëëëÜÜÜàààçççÙÙÙçççÑÑÑÌÌÌÊÊÊÍÍÍÊÊÊ¿¿¿ÅÅÅÊÊÊÉÉÉÉÉÉÇÇÇÆÆÆÆÆÆÅÅÅÅÅÅÂÂÂÃÃÃÇÇÇÙÙÙÛÛÛÑÑÑ×××ÔÔÔÑÑÑÐÐÐÑÑÑÔÔÔÒÒÒÐÐÐÑÑÑ×××êêêÜÜÜçççßß߸¸¸¾¾¾ÇÇÇÌÌÌÇÇÇ¿¿¿¿¿¿¿¿¿¾¾¾¼¼¼»»»ÃÃÃÍÍÍÐÐÐÍÍÍÊÊÊÌÌÌÎÎÎÎÎÎÇÇÇÍÍÍÔÔÔÐÐÐÌÌÌÉÉÉÂÂÂÑÑÑÙÙÙÔÔÔÊÊÊÊÊÊÍÍÍÔÔÔÝÝÝÊÊÊ¿¿¿»»»ÙÙÙÒÒÒÉÉÉÅÅÅÃÃÃÃÃÃÂÂÂÂÂÂÀÀÀÀÀÀÂÂÂÂÂÂÃÃÃÆÆÆÅÅÅÅÅÅÇÇÇÃÃúºº°°°¬¬¬ÎÎθ¸¸ºººÂÂÂÆÆÆÃÃÃÀÀÀÕÕÕÍÍÍÇÇÇÆÆÆÅÅÅÂÂÂÆÆÆÍÍÍßßßßßßØØØÕÕÕ×××ÌÌÌÂÂÂÅÅŸ¸¸»»»ÉÉÉÌÌÌÂÂÂÃÃÃÆÆÆÅÅÅÃÃÃÅÅÅÆÆÆÇÇÇÉÉÉÌÌÌÍÍÍÎÎÎÎÎÎÊÊÊÌÌÌÎÎÎÐÐÐÕÕÕÒÒÒÅÅÅÅÅÅÎÎÎÒÒÒÐÐÐÐÐÐÔÔÔÕÕÕÒÒÒÎÎÎÅÅÅÅÅÅÃÃÃÅÅÅÛÛÛßßßÅÅÅÆÆÆÇÇÇÆÆÆÀÀÀººº···¸¸¸¼¼¼µµµ···µµµ¼¼¼ÊÊÊÌÌÌÉÉÉÍÍÍÒÒÒÕÕÕÜÜÜÔÔÔÛÛÛÛÛÛÀÀÀ¿¿¿ººº¿¿¿¼¼¼ÊÊÊÇÇÇÌÌÌÊÊÊ×××ÇÇÇÅÅÅÃÃÃÒÒÒÎÎÎÅÅÅÒÒÒÜÜÜÛÛÛÕÕÕÇÇÇÇÇÇÅÅž¾¾ÌÌÌÒÒÒÐÐÐÆÆÆÇÇÇÀÀÀ¾¾¾ÔÔÔêêêññññññïïïóóóîîîàààßßßçççêêêîîîçççêêêæææêêêòòòíííëëëîîîòòòòòòêêêÛÛÛÌÌÌÃÃÃÂÂÂÍÍÍÇÇǾ¾¾ÅÅÅÜÜÜêêêîîîòòòñññííííííäääØØØÛÛÛßßßÙÙÙÎÎÎÃÃÃÆÆÆÅÅÅÆÆÆÆÆÆÀÀÀÉÉÉÉÉÉÉÉÉÇÇÇÆÆÆÅÅÅÃÃÃÂÂÂÂÂÂÂÂÂÃÃÃÀÀÀÑÑÑÛÛÛÒÒÒÒÒÒÔÔÔÕÕÕÑÑÑÑÑÑÑÑÑÑÑÑÐÐÐÔÔÔÙÙÙâââØØØãããÕÕÕººº¸¸¸¿¿¿ÅÅÅÆÆƼ¼¼»»»¾¾¾ÀÀÀÃÃÃÅÅÅÉÉÉÊÊÊÊÊÊÉÉÉÇÇÇÇÇÇÊÊÊÎÎÎÆÆÆ¿¿¿ÉÉÉ×××ÔÔÔÐÐÐÍÍÍÅÅÅÐÐÐÛÛÛÙÙÙÍÍÍÉÉÉÉÉÉÎÎÎÙÙÙÇÇÇ¿¿¿¸¸¸ÑÑÑÉÉÉÇÇÇÇÇÇÃÃÃÂÂÂÀÀÀ¿¿¿¿¿¿¾¾¾¿¿¿¿¿¿¿¿¿Â¿¿¿ÀÀÀ¿¿¿³³³©©©´´´ÉÉɸ¸¸······»»»ÀÀÀÃÃÿ¿¿ÎÎÎÐÐÐÍÍÍÇÇÇÃÃÃÃÃÃÎÎÎÜÜÜÒÒÒÉÉÉÂÂÂÍÍÍÒÒÒÀÀÀ»»»ÌÌ̼¼¼ÎÎÎÌÌÌÆÆƾ¾¾¸¸¸ÀÀÀ¼¼¼ÃÃÃÅÅÅÆÆÆÉÉÉÌÌÌÍÍÍÎÎÎÎÎÎÍÍÍÇÇÇÌÌÌÑÑÑÔÔÔØØØÑÑÑ»»»ÂÂÂÌÌÌÆÆƼ¼¼»»»ÆÆÆÑÑÑÎÎÎÇÇÇÂÂÂÅÅÅÇÇÇÃÃÃÃÃÃÃÃþ¾¾ÃÃÃÅÅÅÅÅÅ¿¿¿»»»¿¿¿ÉÉÉÒÒÒ¯¯¯´´´»»»ÇÇÇÔÔÔÎÎÎÉÉÉÎÎÎÐÐÐÎÎÎàààÕÕÕØØØÜÜܾ¾¾»»»µµµ¿¿¿´´´ÃÃÃÍÍÍ×××ÊÊÊÊÊʾ¾¾¿¿¿¼¼¼ÊÊÊÒÒÒÎÎÎÑÑÑÒÒÒÝÝÝßßßÐÐÐÌÌÌÆÆÆÃÃÃÑÑÑÐÐÐÍÍÍÊÊÊÌÌ̺ºº¾¾¾ãããóóóöööêêêçççëëëëëëãããæææîîîëëëêêêëëëñññêêêïïïùùùêêêÜÜÜÜÜÜÝÝÝäääîîîóóóëëëØØØÇÇÇ¿¿¿»»»¾¾¾×××ñññîîîäääêêêçççíííëëëßßß××××××ÙÙÙßßßÌÌÌÇÇÇÐÐÐÌÌÌÆÆÆÆÆÆÃÃÃÎÎÎÉÉÉÇÇÇÆÆÆÅÅÅÃÃÃÂÂÂÀÀÀ¿¿¿ÀÀÀÃÃû»»ÊÊÊÛÛÛÒÒÒÐÐÐÒÒÒ×××ÒÒÒÐÐÐÐÐÐÎÎÎÎÎÎÔÔÔÜÜÜâââÜÜÜèèèÔÔÔ···»»»¾¾¾¼¼¼ÆÆÆ»»»ºººººº···¾¾¾ÅÅÅÂÂÂÃÃÃÊÊÊÍÍÍÌÌÌÌÌÌÎÎÎÌÌÌÆÆÆÉÉÉÍÍÍÑÑÑÑÑÑÎÎÎÍÍÍÎÎÎÑÑÑÝÝÝÑÑÑÌÌÌÔÔÔÕÕÕÎÎÎÌÌÌÐÐÐÑÑÑÜÜÜÔÔÔ¾¾¾ÉÉÉÔÔÔÅÅÅÆÆƼ¼¼»»»¿¿¿ÂÂÂÀÀÀ¿¿¿Â¼¼¼ÆÆÆÀÀÀ°°°­­­ººº¿¿¿¸¸¸¼¼¼µµµµµµ´´´°°°»»»ÍÍÍÑÑÑÀÀÀÍÍÍÙÙÙßßßÜÜÜ×××ÔÔÔÔÔÔÅÅż¼¼ººº¾¾¾ÀÀÀ¿¿¿ÀÀÀÆÆÆ»»»ÆÆÆÌÌÌÇÇÇÀÀÀÀÀÀÂÂÂÃÃÿ¿¿ÍÍÍÇÇÇÊÊÊÎÎÎÇÇÇÊÊÊÐÐÐÊÊÊÌÌÌÉÉÉØØØÒÒÒÕÕÕÉÉÉÊÊÊÐÐÐÅÅÅÅÅÅÍÍÍÉÉÉ¿¿¿ÅÅÅÒÒÒÆÆÆÇÇÇÇÇÇÆÆÆÆÆÆÅÅÅÅÅÅÇÇÇÃÃÃÆÆÆÊÊÊÃÃø¸¸ÕÕÕÐÐÐÎÎÎÎÎÎÎÎÎÎÎÎÌÌÌÉÉÉÇÇÇÉÉÉÊÊÊÍÍÍÎÎÎØØØÎÎÎÙÙÙ×××´´´¼¼¼ÜÜÜØØØÎÎÎÂÂÂÀÀÀÇÇÇÉÉÉÅÅÅÂÂÂÔÔÔÑÑÑÃÃÃÊÊÊÕÕÕÑÑÑÉÉÉÕÕÕäääÍÍÍÊÊÊÃÃÿ¿¿ÝÝÝÔÔÔÑÑÑÍÍÍÆÆÆ···çççëëëïïïèèèïïïîîîêêêæææèèèïïïòòòïïïõõõíííñññîîîëëëæææÙÙÙÛÛÛ×××ÙÙÙâââíííòòòñññêêêäääÇÇÇ­­­¾¾¾ãããæææàààèèèíííçççîîîëëëßßßØØØØØØÕÕÕÍÍÍÎÎÎÉÉÉÍÍÍÎÎÎÆÆÆÅÅÅÆÆÆ¿¿¿ÆÆÆÇÇÇÇÇÇÅÅÅÂÂÂÀÀÀÂÂÂÅÅÅ¿¿¿ÃÃÿ¿¿ÇÇÇÕÕÕ×××ÎÎÎÉÉÉÌÌÌÒÒÒ×××ÒÒÒÍÍÍÎÎÎÔÔÔäääÛÛÛâââ×××¼¼¼¸¸¸ÀÀÀ¿¿¿ººº¾¾¾Â¿¿¿ÃÃÃÆÆÆ¿¿¿ÉÉÉÊÊÊÉÉÉÇÇÇÆÆÆÉÉÉÊÊÊÉÉÉÔÔÔÑÑÑÍÍÍÇÇÇÃÃÃÆÆÆÍÍÍÔÔÔÝÝÝÔÔÔÐÐÐÑÑÑÑÑÑÉÉÉÂÂÂÂÂÂÊÊÊÔÔÔ×××ÀÀÀºººÊÊÊÌÌÌÉÉÉÉÉÉÆÆÆ¿¿¿ÀÀÀÃÃÃÆÆÆÇÇÇÇÇǾ¾¾³³³°°°³³³¸¸¸¼¼¼¾¾¾µµµ¾¾¾ÌÌÌÊÊʺºº¸¸¸ÆÆÆÍÍͼ¼¼ÃÃÃÌÌÌÐÐÐÐÐÐÊÊÊÃÃÿ¿¿ÉÉÉÅÅÅ¿¿¿»»»¼¼¼ÀÀÀÅÅÅÆÆÆÒÒÒÒÒÒÍÍÍÅÅÅÂÂÂÃÃÃÅÅÅÂÂÂÆÆÆÌÌÌÆÆÆÌÌÌÒÒÒÎÎÎÐÐÐÌÌÌÀÀÀÎÎÎÑÑÑÒÒÒÃÃÃÉÉÉÊÊÊÐÐÐÅÅÅÂÂÂÊÊÊÕÕÕÑÑÑÅÅÅÂÂÂÉÉÉÔÔÔÔÔÔÔÔÔÕÕÕÔÔÔÍÍÍÆÆÆÀÀÀÂÂÂÅÅÅÉÉÉÅÅż¼¼×××ÑÑÑÌÌÌÌÌÌÍÍÍÌÌÌÊÊÊÆÆÆÆÆÆÇÇÇÉÉÉÇÇÇÊÊÊÕÕÕÎÎÎÙÙÙÕÕÕµµµ»»»ÕÕÕ×××ÕÕÕÎÎÎÅÅÅÀÀÀÉÉÉÑÑÑÑÑÑ××××××ÐÐÐÍÍÍÔÔÔÒÒÒÊÊÊÎÎÎàààÍÍÍÍÍÍÃÃþ¾¾ÙÙÙÒÒÒÊÊÊÆÆÆ¿¿¿ÀÀÀçççîîîëëëëëëññññññïïïëëëëëëïïïïïïíííïïïàààÝÝÝÝÝÝâââæææÜÜÜÝÝÝäääâââÜÜÜØØØÝÝÝçççëëëêêêÛÛÛÆÆÆÍÍÍääääääÝÝÝâââçççòòòòòòêêêÜÜÜ×××ØØØÔÔÔÊÊÊÆÆÆÃÃÃÇÇÇÉÉÉÂÂÂÃÃÃÇÇÇÃÃÃÉÉÉÉÉÉÉÉÉÇÇÇÅÅÅÂÂÂÀÀÀÀÀÀÂÂÂÅÅÅ¿¿¿ÆÆÆÕÕÕÙÙÙÕÕÕÔÔÔÑÑÑÐÐÐÎÎÎÉÉÉÆÆÆÍÍÍÕÕÕßßßØØØÛÛÛÜÜÜÅÅŵµµ¼¼¼¼¼¼ÅÅż¼¼ººººººººº¿¿¿ÆÆÆÆÆÆÉÉÉÅÅÅÃÃÃÃÃÃÆÆÆÇÇÇÌÌÌÐÐÐÕÕÕÐÐÐÉÉÉÂÂÂÀÀÀÆÆÆÎÎÎÔÔÔàààØØØÑÑÑÐÐÐÑÑÑÑÑÑÑÑÑÒÒÒ»»»ÇÇÇÕÕÕÆÆÆ¿¿¿ÌÌÌÇÇÇÂÂÂÃÃÃÅÅÅÆÆÆÆÆÆÉÉÉÍÍÍÒÒÒÕÕÕ¼¼¼ºººµµµµµµ¼¼¼ÀÀÀ¾¾¾···´´´ÀÀÀÐÐÐÎÎξ¾¾»»»ÉÉÉÒÒÒÇÇÇ»»»ººº¾¾¾ÇÇÇÎÎÎÑÑÑÎÎÎÕÕÕÔÔÔÍÍÍÉÉÉÊÊÊÇÇÇÀÀÀÙÙÙÒÒÒÇÇÇÂÂÂÅÅÅÊÊÊÊÊÊÆÆÆÀÀÀÅÅÅÆÆÆÑÑÑÔÔÔÒÒÒØØØÐÐÐÙÙÙÎÎο¿¿ÃÃÃÇÇÇÐÐÐÅÅž¾¾»»»ÃÃÃÐÐÐÛÛÛÛÛÛÎÎÎÆÆÆÇÇÇÇÇÇÇÇÇÌÌÌÐÐÐÔÔÔÕÕÕÑÑÑÊÊÊÅÅÅÆÆÆÅÅÅÃÃü¼¼ÔÔÔÐÐÐÉÉÉÉÉÉÉÉÉÇÇÇÆÆÆÃÃÃÃÃÃÆÆÆÇÇÇÊÊÊÍÍÍ×××ÑÑÑ×××ÐÐб±±´´´ÒÒÒÒÒÒÕÕÕÕÕÕÍÍÍÅÅÅÌÌÌÙÙÙÔÔÔÌÌÌÑÑÑ×××ÑÑÑÒÒÒØØØÔÔÔÇÇÇÝÝÝÎÎÎÑÑÑÆÆƾ¾¾ÒÒÒÒÒÒÐÐÐÊÊÊ¿¿¿×××îîîùùùñññùùùõõõöööóóóëëëæææäääàààÜÜÜâââÜÜÜàààÛÛÛ×××ØØØØØØãããÝÝÝââââââÙÙÙÙÙÙãããëëëîîîñññææææææííííííääääääëëëããããããÜÜÜÔÔÔÔÔÔ×××ÎÎÎÃÃÃÇÇÇÆÆÆÉÉÉÇÇÇÂÂÂÀÀÀÅÅÅÃÃÿ¿¿¼¼¼ºººººº»»»¾¾¾¿¿¿ÀÀÀÅÅÅÆÆÆÃÃü¼¼¿¿¿ÌÌÌÒÒÒÒÒÒÒÒÒÑÑÑÑÑÑÐÐÐÊÊÊÆÆÆÇÇÇÌÌÌÔÔÔØØØÙÙÙàààÎÎκºº»»»°°°´´´³³³³³³µµµººº¿¿¿ÃÃÃÃÃÃÇÇÇ¿¿¿ÅÅÅÇÇÇÅÅÅÇÇÇÌÌÌÍÍÍÌÌÌÉÉÉÉÉÉÊÊÊÍÍÍÐÐÐÑÑÑÒÒÒÕÕÕØØØÙÙÙØØØÔÔÔÊÊÊÂÂÂÍÍÍÍÍÍÆÆƸ¸¸¾¾¾ÇÇÇÃÃÃÍÍͼ¼¼¸¸¸···±±±¬¬¬¯¯¯µµµ­­­»»»ÆÆÆÅÅÅ»»»···¾¾¾ÅÅÅÆÆÆÉÉÉÍÍÍÉÉÉÀÀÀ¼¼¼¾¾¾ÀÀÀÌÌÌÍÍÍÎÎÎÎÎÎÌÌÌÆÆÆ¿¿¿»»»¿¿¿ÆÆÆÊÊÊÆÆÆÃÃþ¾¾ºººÑÑÑÊÊÊÃÃÃÂÂÂÆÆÆÊÊÊÉÉÉÅÅÅÉÉÉÎÎÎ×××àààÕÕÕÑÑÑÜÜÜ×××ÒÒÒÐÐÐÉÉÉÆÆÆÃÃÃÆÆÆÇÇÇÊÊÊÌÌÌÕÕÕÛÛÛàààâââÜÜÜØØØÝÝÝÎÎÎÌÌÌÌÌÌÉÉÉÅÅÅÊÊÊÎÎÎÊÊÊÉÉÉÇÇÇ¿¿¿¿¿¿¸¸¸ÐÐÐÎÎÎÉÉÉÆÆÆÆÆÆÃÃÃÂÂÂÀÀÀÂÂÂÅÅÅÆÆÆÌÌÌÎÎÎÕÕÕÑÑÑÕÕÕÎÎθ¸¸¸¸¸ÔÔÔÎÎÎÍÍÍÑÑÑÕÕÕÔÔÔÒÒÒÔÔÔÎÎÎÃÃÃÇÇÇÔÔÔÒÒÒÎÎÎÔÔÔÙÙÙÉÉÉàààÑÑÑÔÔÔÆÆÆÀÀÀÎÎÎÒÒÒÍÍÍÅÅÅ»»»âââèèèõõõèèèøøøãããççççççâââÝÝÝÝÝÝÝÝÝÜÜÜàààØØØÜÜÜÜÜÜÝÝÝßßßÙÙÙßßßÝÝÝßßßàààßßßÝÝÝÜÜÜÙÙÙØØØãããæææâââàààãããÝÝÝÛÛÛääääääßßß×××ÒÒÒ×××ÛÛÛÔÔÔÉÉÉÉÉÉÊÊÊÍÍÍÌÌÌÆÆÆÃÃÃÅÅÅÅÅÅÉÉÉÀÀÀ···±±±´´´»»»ÂÂÂÆÆÆÆÆÆÇÇÇÃÃû»»¸¸¸¾¾¾ÂÂÂÂÂÂÆÆÆÉÉÉÌÌÌÐÐÐÐÐÐÎÎÎÎÎÎÎÎÎÍÍÍØØØÛÛÛàààÕÕÕÊÊÊÇÇǵµµ¯¯¯¯¯¯¬¬¬¯¯¯µµµ»»»¿¿¿Â¼¼¼¼¼¼ÃÃÃÅÅÅÀÀÀ¼¼¼¾¾¾ÌÌÌÍÍÍÎÎÎÐÐÐÑÑÑÐÐÐÎÎÎÍÍÍÍÍÍÒÒÒØØØÛÛÛÛÛÛØØØÐÐÐÇÇÇÌÌÌÉÉÉÑÑÑ×××ØØØÉÉɳ³³µµµ¼¼¼°°°¯¯¯···¸¸¸´´´¾¾¾ÑÑѺºººººÂÂÂÀÀÀ¸¸¸¿¿¿ÐÐÐÅÅÅÇÇÇÉÉÉÊÊÊÌÌÌÇÇÇ¿¿¿ººº¾¾¾ÀÀÀÂÂÂÀÀÀÂÂÂÊÊÊÕÕÕßßß¾¾¾»»»»»»¼¼¼¼¼¼¾¾¾ÅÅÅÍÍÍÎÎÎÊÊÊÅÅÅÃÃÃÃÃÃÅÅÅÅÅÅÆÆÆÐÐÐÔÔÔ×××ÛÛÛÎÎÎÆÆÆÐÐÐÇÇÇÅÅÅÇÇÇÉÉÉÆÆÆÊÊÊÎÎÎ×××ØØØÐÐÐÒÒÒÉÉÉÃÃÃÆÆÆÆÆÆÌÌÌÙÙÙÜÜÜÛÛÛÙÙÙÎÎÎÀÀÀÃÃÃÍÍÍÊÊÊÀÀÀ¼¼¼ÃÃþ¾¾ÐÐÐÐÐÐÆÆÆÅÅÅÂÂÂÀÀÀ¿¿¿¿¿¿ÂÂÂÃÃÃÅÅÅÇÇÇÉÉÉÎÎÎÍÍÍÒÒÒÒÒÒÉÉÉÊÊÊÎÎÎÊÊÊÇÇÇÉÉÉÒÒÒÛÛÛÕÕÕÊÊÊÐÐÐÉÉÉÆÆÆÎÎÎÔÔÔÊÊÊÉÉÉØØØÍÍÍçççÕÕÕÔÔÔÆÆÆÉÉÉÎÎÎÒÒÒÉÉÉÃÃÃÅÅÅîîîêêêïïïâââëëëãããæææãããÜÜÜ×××××××××ÕÕÕÝÝÝÕÕÕÙÙÙÙÙÙÛÛÛÝÝÝÙÙÙàààßßßÕÕÕÐÐÐÔÔÔÙÙÙØØØÒÒÒÐÐÐÛÛÛäääâââßßßäääßßßÛÛÛãããêêêàààÔÔÔÍÍÍÑÑÑÕÕÕÑÑÑÉÉÉÆÆÆÉÉÉÊÊÊÊÊÊÇÇÇÅÅÅÂÂÂÃÃü¼¼µµµ­­­ªªª¯¯¯···¿¿¿ÅÅÅÂÂÂÆÆÆÅÅÅ¿¿¿ººº¸¸¸¸¸¸¸¸¸ÕÕÕÔÔÔÐÐÐÍÍÍÊÊÊÊÊÊÇÇÇÆÆÆÌÌÌÕÕÕØØØÙÙÙØØØÙÙÙØØØÌÌÌÆÆÆ···°°°³³³´´´···»»»´´´³³³···¿¿¿ÅÅÅÅÅÅÂÂÂÀÀÀÕÕÕÕÕÕÔÔÔÑÑÑÎÎÎÍÍÍÌÌÌÌÌÌÔÔÔÒÒÒÒÒÒÕÕÕ××××××ØØØÛÛÛØØØÂÂÂÉÉÉÍÍÍÃÃÃÆÆÆÐÐÐÜÜÜÛÛÛÐÐÐÎÎÎÔÔÔÎÎμ¼¼¸¸¸ÀÀÀÉÉÉ»»»µµµ¾¾¾ÆÆÆÆÆÆÃÃÃÃÃþ¾¾ÃÃÃÅÅÅÆÆÆÌÌÌÌÌÌÌÌÌÑÑÑ­­­»»»ÍÍÍØØØØØØÕÕÕÒÒÒÔÔÔÔÔÔÍÍÍÌÌÌÐÐÐÐÐÐÌÌÌÐÐÐÙÙÙÍÍÍÉÉÉÅÅÅÃÃÃÅÅÅÆÆÆÍÍÍÒÒÒÑÑÑÎÎÎÇÇÇÍÍÍÍÍÍÉÉÉÍÍÍÂÂÂÑÑѼ¼¼¾¾¾ÌÌÌÛÛÛÎÎÎÑÑÑÙÙÙàààÛÛÛÉÉɾ¾¾ÀÀÀ¿¿¿ÉÉÉàààÕÕÕÕÕÕÙÙÙÑÑÑÂÂÂÇÇÇÑÑÑÊÊʵµµ¿¿¿¾¾¾ÎÎÎÇÇÇÒÒÒÐÐÐÃÃÃÃÃÃÀÀÀ¾¾¾¼¼¼¿¿¿ÂÂÂÅÅÅÆÆÆÊÊÊÊÊÊÊÊÊÉÉÉÌÌÌÍÍÍÊÊÊÍÍÍÃÃÃÆÆÆÅÅÅÂÂÂÇÇÇÐÐÐÐÐÐÉÉÉÊÊÊÌÌÌÆÆÆÌÌÌÕÕÕÐÐÐÎÎÎÝÝÝÐÐÐííí×××ÑÑÑÆÆÆÔÔÔÑÑÑÑÑÑÆÆÆÇÇÇÛÛÛøøøïïïíííãããßßßÛÛÛÝÝÝÝÝÝÙÙÙÙÙÙßßßâââààààààØØØÙÙÙÒÒÒÌÌÌÌÌÌÌÌÌØØØÙÙÙÙÙÙÜÜÜÜÜÜØØØÒÒÒÕÕÕÙÙÙÌÌÌÔÔÔÔÔÔÒÒÒÕÕÕÐÐÐÊÊÊÐÐÐ×××ÒÒÒÐÐÐÐÐÐÒÒÒÑÑÑÊÊÊÂÂÂÉÉÉÌÌÌÇÇÇÃÃÃÃÃþ¾¾······±±±¯¯¯¬¬¬¬¬¬¯¯¯±±±´´´µµµ»»»¿¿¿ÅÅÅÃÃÃÀÀÀ¾¾¾»»»¸¸¸ÂÂÂÅÅÅÇÇÇÊÊÊÐÐÐÔÔÔÒÒÒÍÍÍÌÌÌÌÌÌÑÑÑÔÔÔØØØÜÜÜ×××ÔÔÔÐÐÐÒÒÒÌÌÌÇÇÇÉÉÉ······µµµ···ººº¿¿¿ÇÇÇÐÐÐÑÑÑÎÎÎØØØØØØÕÕÕÐÐÐÊÊÊÉÉÉÊÊÊÎÎÎÒÒÒÐÐÐÒÒÒØØØÒÒÒÇÇÇ¿¿¿¿¿¿âââÑÑÑÛÛÛØØØÇÇÇÇÇÇÅÅÅÀÀÀ»»»»»»¿¿¿ÅÅÅÅÅž¾¾···µµµ···ÀÀÀÇÇÇÅÅÅÀÀÀÀÀÀ¿¿¿ÆÆÆÊÊÊÆÆÆÀÀÀÂÂÂÃÃÃÇÇÇÒÒÒÊÊÊÎÎÎÒÒÒÕÕÕÔÔÔÒÒÒÔÔÔ×××ÕÕÕÒÒÒÑÑÑÑÑÑÐÐÐÍÍÍÊÊÊÉÉÉÉÉÉÃÃÃÀÀÀÅÅÅÊÊÊÌÌÌÐÐÐÕÕÕ×××ÕÕÕÇÇÇÊÊÊÒÒÒÑÑÑÒÒÒÍÍÍÉÉÉÃÃÃÒÒÒ×××ÎÎα±±ÀÀÀßßßÕÕÕÐÐÐÀÀÀ¼¼¼ÀÀÀ»»»ÂÂÂÜÜÜ×××ÑÑÑÔÔÔÍÍÍ¿¿¿ÅÅÅÉÉɺºº¾¾¾ÉÉÉÆÆÆÕÕÕÌÌÌÐÐÐÎÎÎÀÀÀÅÅÅÀÀÀ¼¼¼¼¼¼¿¿¿ÃÃÃÆÆÆÇÇÇÍÍÍÌÌÌÇÇÇÅÅÅÂÂÂÀÀÀÂÂÂÀÀÀ¾¾¾¿¿¿¿¿¿¾¾¾¾¾¾ÂÂÂÆÆÆÉÉÉÅÅÅÆÆÆÇÇÇÉÉÉÐÐÐÕÕÕÙÙÙÝÝÝÍÍÍíííÔÔÔÍÍÍÆÆÆßßßÔÔÔÎÎÎÃÃÃÇÇÇäääëëëæææÝÝÝãããÕÕÕâââäääâââÝÝÝÝÝÝßßßÝÝÝÙÙÙäääÒÒÒÌÌÌÇÇÇÊÊÊÍÍÍÅÅÅÆÆÆÒÒÒäääëëëàààÔÔÔÔÔÔ××××××ÔÔÔ××××××ØØØ×××ÑÑÑÍÍÍÐÐÐÍÍÍÎÎÎÒÒÒÕÕÕ×××ÔÔÔÎÎÎÊÊÊÌÌÌÌÌ̼¼¼ÀÀÀ¾¾¾···¸¸¸ÇÇÇÆÆÆÅÅÅÀÀÀ»»»µµµ³³³³³³³³³¸¸¸¿¿¿ÃÃÃÅÅÅÀÀÀ¼¼¼ººº¸¸¸¾¾¾ÃÃÃÉÉÉÑÑÑ×××ÒÒÒÉÉÉÊÊÊÂÂÂÌÌÌÒÒÒØØØ×××ÉÉÉÍÍÍÑÑÑÕÕÕÐÐÐÎÎÎÕÕÕÒÒÒÍÍÍÐÐÐÊÊÊÊÊÊÇÇÇÅÅÅÌÌÌ×××ØØØÒÒÒÔÔÔÕÕÕÕÕÕÐÐÐÊÊÊÉÉÉÌÌÌÐÐÐ×××ÑÑÑÒÒÒÙÙÙÔÔÔÅÅž¾¾ÂÂÂÙÙÙÕÕÕØØØÒÒÒÕÕÕØØØÅÅŵµµ¾¾¾ÀÀÀ¼¼¼···»»»ÆÆÆÊÊÊÆÆÆÅÅž¾¾»»»¾¾¾ÂÂÂÀÀÀ¾¾¾¾¾¾¼¼¼ÂÂÂÀÀÀ¿¿¿ÆÆÆÅÅÅÂÂÂÉÉÉÍÍÍÎÎÎÒÒÒ×××ÙÙÙ×××ÐÐÐÊÊÊÊÊÊÊÊÊÆÆÆ¿¿¿ÀÀÀÉÉÉÊÊÊÆÆÆÉÉÉÂÂÂÀÀÀÉÉÉÎÎÎÍÍÍÇÇÇÅÅÅÒÒÒ×××ÅÅÅ¿¿¿Â¼¼¼¾¾¾ÀÀÀÃÃÃÌÌÌÔÔÔÃÃÃÃÃÿ¿¿ÊÊÊÇÇÇÆÆÆÆÆƾ¾¾ÃÃÃÌÌÌÂÂÂÃÃÃßßßÛÛÛÐÐÐÎÎÎÇÇǾ¾¾ÉÉÉÌÌÌ···ÐÐÐ×××ÍÍÍ×××ÇÇÇÉÉÉÊÊÊ¿¿¿ÅÅÅÀÀÀ¼¼¼»»»¿¿¿ÃÃÃÆÆÆÇÇÇÇÇÇÆÆÆÂÂÂÀÀÀ¼¼¼ººº¾¾¾¼¼¼¿¿¿¸¸¸µµµººº»»»ººº¾¾¾ÆÆÆÆÆÆÆÆÆÊÊÊÉÉÉÆÆÆÒÒÒÛÛÛÒÒÒÇÇÇëëëÑÑÑÉÉÉÇÇÇççç×××ÌÌÌÎÎÎÑÑÑïïïãããàààÙÙÙïïïßßßßßßâââàààßßßßßßàààÜÜÜÕÕÕÍÍÍÅÅÅÊÊÊÊÊÊÍÍÍÐÐÐÉÉÉÎÎο¿¿ÎÎÎÎÎÎÅÅÅÎÎÎçççëëëÛÛÛ×××ÔÔÔÔÔÔ×××ÔÔÔÐÐÐÍÍÍÎÎÎÕÕÕÑÑÑÊÊÊÅÅÅÂÂÂÃÃÃÉÉÉÍÍÍÃÃÃÃÃúºº¸¸¸ÃÃÃÇÇÇÆÆÆÊÊÊÃÃÃÃÃÃÅÅÅÃÃÃÂÂÂÂÂÂÅÅÅÉÉɯ¯¯³³³ºººÀÀÀ¾¾¾ºººµµµ»»»¼¼¼¼¼¼¾¾¾ÇÇÇÒÒÒÔÔÔÎÎÎÑÑÑÉÉÉÎÎÎÎÎÎ×××ßßßÔÔÔÔÔÔÐÐÐÑÑÑÔÔÔÙÙÙÝÝÝÝÝÝÛÛÛ×××ÒÒÒÒÒÒÒÒÒÕÕÕÙÙÙÛÛÛÙÙÙØØØ×××ÎÎÎÍÍÍÒÒÒÔÔÔÎÎÎÍÍÍÑÑÑÎÎÎÕÕÕÕÕÕÍÍÍÅÅÅÂÂÂÃÃÃÃÃÃÂÂÂÇÇÇÎÎÎÑÑÑÐÐÐÎÎÎÍÍÍÍÍÍÌÌÌÌÌÌÌÌÌÊÊÊÇÇÇÃÃÿ¿¿¼¼¼¿¿¿¾¾¾¾¾¾¼¼¼¼¼¼¼¼¼¾¾¾¾¾¾ÀÀÀ¿¿¿ÂÂÂÆÆÆÇÇÇÆÆÆÉÉÉÎÎÎÍÍÍÒÒÒººº¸¸¸¿¿¿ÇÇÇØØØÇÇÇÅÅÅÉÉÉÌÌÌÉÉÉÃÃÃÀÀÀÅÅÅÉÉÉÂÂÂÉÉÉÉÉÉÕÕÕÕÕÕÃÃÃÉÉÉØØØ¿¿¿ÉÉÉÒÒÒØØØ×××ÔÔÔÒÒÒÒÒÒÝÝÝÑÑÑÅÅÅÀÀÀÀÀÀÀÀÀÂÂÂÆÆÆÅÅÅÂÂÂÂÂÂÅÅÅÃÃÃÃÃÃÍÍÍØØØÕÕÕÑÑÑÇÇǼ¼¼ÆÆÆÇÇÇ¿¿¿×××ÌÌÌÐÐÐÊÊÊÆÆÆÉÉÉÅÅÅ¿¿¿ÂÂÂÃÃÃÂÂÂÂÂÂÂÂÂÅÅÅÇÇÇÊÊÊÌÌÌÇÇÇÅÅÅÀÀÀ¾¾¾»»»ººººººººººººººººººººº»»»¼¼¼¿¿¿¿¿¿ÂÂÂÇÇÇÍÍÍÉÉÉÅÅÅÒÒÒÛÛÛÐÐÐÒÒÒÒÒÒâââ¼¼¼ÅÅÅàààÜÜÜÎÎÎÉÉÉâââëëë×××ßßßèèèÙÙÙäääÍÍÍÐÐÐÌÌÌÔÔÔßßßíííÐÐÐÊÊÊÍÍÍÍÍÍÍÍÍÎÎÎÍÍÍÍÍÍÌÌÌÌÌÌÉÉÉÉÉÉÊÊÊÊÊÊÊÊÊÉÉÉÇÇÇÆÆÆÉÉÉâââÝÝÝÐÐÐÊÊÊÐÐÐ×××¼¼¼ÇÇÇÆÆÆÃÃÃÊÊÊÉÉÉÂÂÂÃÃþ¾¾ÊÊÊÑÑÑÌÌÌÊÊÊÎÎÎÐÐÐÌÌÌÃÃÃÃÃÃÂÂÂÂÂÂÂÂÂÃÃÃÃÃÃÅÅÅÃÃÃÃÃô´´µµµ¾¾¾ÂÂÂÇÇÇ···¼¼¼ÆÆÆÃÃÿ¿¿ÇÇÇÎÎÎÎÎÎÐÐÐÐÐÐÇÇÇÍÍÍÍÍÍÔÔÔÛÛÛÒÒÒÔÔÔÔÔÔÒÒÒÑÑÑÑÑÑÕÕÕÙÙÙÜÜÜßßßÛÛÛÕÕÕÎÎÎÌÌÌÍÍÍÔÔÔÙÙÙÝÝÝÔÔÔÑÑÑÌÌÌÊÊÊÌÌÌÑÑÑÔÔÔÕÕÕÒÒÒÕÕÕÒÒÒÇÇǾ¾¾¾¾¾ÀÀÀÃÃÃÑÑÑÒÒÒÒÒÒÎÎÎÉÉÉÅÅÅÂÂÂÀÀÀÃÃÃÃÃÃÂÂÂÂÂÂÀÀÀ¾¾¾¼¼¼»»»¿¿¿¾¾¾¾¾¾¼¼¼¼¼¼¼¼¼¾¾¾¾¾¾ÂÂÂÀÀÀÀÀÀÅÅÅÅÅÅÅÅÅÉÉÉÐÐд´´ÅÅźººººº¸¸¸¼¼¼ÑÑÑÊÊÊÉÉÉÆÆÆÅÅÅÅÅÅÇÇÇÉÉÉÉÉÉÉÉÉÌÌÌÔÔÔÀÀÀ¸¸¸ÆÆÆÔÔÔÑÑѾ¾¾ÕÕÕÒÒÒÍÍÍÉÉÉÉÉÉÎÎÎÙÙÙâââÙÙÙÎÎÎÃÃÿ¿¿¼¼¼ºººººº¼¼¼ÂÂÂÀÀÀÀÀÀÀÀÀ¿¿¿ÀÀÀÉÉÉÑÑÑÛÛÛÒÒÒÃÃþ¾¾ÇÇÇÃÃü¼¼ÍÍÍÌÌÌÍÍÍÇÇÇÅÅÅÊÊÊÆÆÆÀÀÀÂÂÂÀÀÀÀÀÀÂÂÂÂÂÂÅÅÅÆÆÆÉÉÉÊÊÊÅÅÅÃÃÃÀÀÀ¼¼¼ººº¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸ººº»»»¾¾¾¿¿¿ÀÀÀÃÃÃÆÆÆÌÌÌÊÊÊÆÆÆÑÑÑÙÙÙÕÕÕÑÑÑÔÔÔàààÉÉÉÔÔÔÜÜÜÕÕÕÍÍÍÆÆÆçççëëëÛÛÛàààßßßÐÐÐÙÙÙÑÑÑÔÔÔÎÎÎÎÎÎÒÒÒßßßÌÌÌÌÌÌÐÐÐÐÐÐÐÐÐÐÐÐÐÐÐÎÎÎÎÎÎÎÎÎÉÉÉÉÉÉÊÊÊÊÊÊÉÉÉÇÇÇÆÆÆÅÅż¼¼ÊÊÊÅÅÅ¿¿¿¼¼¼¿¿¿ÇÇǾ¾¾ÅÅÅÉÉÉÇÇÇÆÆÆÉÉÉÂÂÂÀÀÀÉÉÉÀÀÀÊÊÊÎÎÎÇÇÇÃÃÃÇÇÇÉÉÉÆÆÆÇÇÇÅÅÅ¿¿¿»»»»»»¿¿¿ÃÃÃÆÆÆÆÆÆÉÉɺººµµµ´´´¸¸¸ÆÆÆÂÂÂÃÃÃÉÉÉÅÅÅ¿¿¿ÃÃÃÃÃÃÂÂÂÅÅÅÍÍÍÉÉÉÌÌÌÊÊÊÎÎÎÔÔÔÐÐÐÑÑÑ×××ÔÔÔÑÑÑÎÎÎÐÐÐÔÔÔÙÙÙÝÝÝÕÕÕÔÔÔÔÔÔÕÕÕ××××××ÔÔÔÑÑÑÐÐÐÒÒÒÎÎÎÆÆÆÉÉÉÒÒÒÕÕÕÐÐÐÔÔÔÛÛÛÛÛÛÐÐÐÃÃü¼¼ººº···ÒÒÒÑÑÑÎÎÎÉÉÉÃÃÃÀÀÀ¿¿¿ÀÀÀ¼¼¼»»»»»»»»»ººº»»»»»»»»»¿¿¿¾¾¾¾¾¾¼¼¼¼¼¼¾¾¾¾¾¾¿¿¿ÃÃÃÀÀÀ¿¿¿ÂÂÂÂÂÂÂÂÂÉÉÉÐÐа°°ÅÅÅÅÅÅÇÇÇÂÂÂÀÀÀÔÔÔÒÒÒÍÍÍÊÊÊÇÇÇÆÆÆÊÊÊÎÎÎÑÑÑÑÑÑØØØÕÕÕÇÇÇÊÊÊÍÍÍÂÂÂÃÃÃÉÉÉÉÉÉÆÆÆ¿¿¿¼¼¼¿¿¿ÂÂÂÆÆÆÅÅÅ¿¿¿»»»»»»»»»···¸¸¸»»»¼¼¼¿¿¿¿¿¿»»»¸¸¸¼¼¼ÂÂÂÆÆÆ×××ÑÑÑ¿¿¿ÂÂÂÌÌÌÀÀÀ¸¸¸¾¾¾ÐÐÐÎÎÎÆÆÆÂÂÂÅÅÅÃÃÃÀÀÀÀÀÀ¾¾¾¿¿¿ÀÀÀÃÃÃÅÅÅÅÅÅÆÆÆÆÆÆÀÀÀÀÀÀ¾¾¾¼¼¼ººº¸¸¸···µµµ···¸¸¸¸¸¸ººº¼¼¼¿¿¿ÀÀÀÂÂÂÅÅÅÅÅÅÊÊÊÌÌÌÉÉÉÎÎÎØØØÜÜÜÔÔÔ×××ÙÙÙÑÑÑàààÔÔÔÍÍÍÍÍ;¾¾êêêçççÜÜÜãããÕÕÕÉÉÉÒÒÒÕÕÕ×××ÒÒÒÎÎÎÍÍÍÕÕÕÉÉÉÎÎÎÒÒÒÒÒÒÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÑÊÊÊÊÊÊÊÊÊÉÉÉÇÇÇÆÆÆÃÃÃÃÃÃÊÊÊÉÉÉÂÂÂÅÅÅÃÃÿ¿¿ÆÆÆÉÉÉÉÉÉÍÍÍÇÇǾ¾¾ÀÀÀÆÆÆÅÅÅÃÃÿ¿¿ÆÆÆÆÆƾ¾¾¸¸¸»»»»»»¸¸¸¾¾¾ºººµµµ±±±°°°³³³···ºººÂÂÂÉÉÉ»»»±±±°°°ÀÀÀÉÉÉÀÀÀÃÃÃÀÀÀ¿¿¿ÀÀÀ¿¿¿¿¿¿ÊÊÊÍÍÍÌÌÌÌÌÌÉÉÉÉÉÉÌÌÌÊÊÊÍÍÍÕÕÕÕÕÕ×××ÔÔÔÒÒÒÑÑÑÔÔÔ×××ØØØØØØÙÙÙÜÜÜÝÝÝÛÛÛÕÕÕÑÑÑÌÌÌÑÑÑÑÑÑÍÍÍÍÍÍÐÐÐÊÊÊÀÀÀ»»»ÇÇÇÒÒÒÔÔÔÑÑÑÑÑÑÑÑÑÐÐÐÌÌÌÊÊÊÇÇÇÃÃÃÀÀÀ¿¿¿ÀÀÀÀÀÀ¼¼¼»»»ººº¸¸¸¸¸¸»»»¼¼¼¾¾¾¾¾¾¾¾¾¼¼¼¼¼¼¼¼¼¾¾¾¿¿¿¿¿¿Â¿¿¿¼¼¼¿¿¿¿¿¿ÀÀÀÇÇÇÐÐи¸¸ÆÆÆÇÇÇÌÌÌÇÇÇÂÂÂÍÍÍÍÍÍÀÀÀÉÉÉÒÒÒ×××ÕÕÕÕÕÕÙÙÙÜÜÜ´´´ÊÊÊÇÇÇÃÃÃÆÆÆÎÎÎÝÝÝâââÅÅÅÅÅÅÃÃÃÃÃÃÂÂÂÀÀÀ¾¾¾¼¼¼µµµ³³³´´´¸¸¸¸¸¸···¸¸¸»»»ºººÀÀÀÀÀÀºººµµµººº¾¾¾¼¼¼ÇÇÇÌÌÌ»»»ÀÀÀÊÊÊ»»»°°°ÐÐÐÎÎÎÉÉÉ¿¿¿¾¾¾¾¾¾ÀÀÀ¼¼¼¾¾¾ÀÀÀÃÃÃÃÃÃÃÃÃÃÃþ¾¾¾¾¾¼¼¼»»»ººº···µµµ´´´······¸¸¸ººº¼¼¼¿¿¿ÂÂÂÃÃÃÅÅÅÅÅÅÉÉÉÍÍÍÊÊÊÌÌÌ×××ãããÔÔÔÛÛÛÑÑÑÍÍÍßßßÉÉÉÇÇÇÊÊÊ···èèèàààÝÝÝæææÐÐÐÊÊÊÕÕÕØØØÔÔÔÔÔÔÐÐÐÐÐÐÕÕÕÍÍÍÐÐÐÑÑÑÑÑÑÐÐÐÐÐÐÐÐÐÐÐÐÑÑÑÑÑÑÌÌÌÌÌÌÊÊÊÉÉÉÇÇÇÅÅÅÃÃÃÃÃÃÉÉÉÅÅÅÂÂÂÇÇÇÇÇÇÅÅÅÆÆÆÊÊÊÉÉÉÆÆƾ¾¾¸¸¸¾¾¾ÆÆÆÅÅÅ¿¿¿ÂÂÂÇÇÇÇÇÇÀÀÀ»»»»»»ººº···¬¬¬­­­±±±´´´µµµ···µµµµµµµµµ¿¿¿ÆÆÆÅÅźºº±±±¸¸¸ÂÂÂÉÉÉÊÊÊÅÅÅÃÃúºººººÆÆÆÍÍÍÎÎÎÌÌÌÉÉÉÆÆÆÅÅÅÇÇÇÇÇÇÐÐÐÒÒÒÕÕÕÕÕÕÔÔÔÒÒÒÔÔÔÕÕÕÛÛÛÜÜÜßßßããããããàààÙÙÙÔÔÔÌÌÌÍÍÍÎÎÎÐÐÐÐÐÐÌÌÌÅÅž¾¾ÆÆÆÎÎÎÔÔÔÐÐÐÌÌÌÌÌÌÎÎÎÎÎÎÌÌÌÊÊÊÆÆÆ¿¿¿¼¼¼ººº¸¸¸¼¼¼»»»¸¸¸······¸¸¸»»»¼¼¼¼¼¼¼¼¼¼¼¼¼¼¼¼¼¼¾¾¾¾¾¾¿¿¿ÀÀÀ¼¼¼¼¼¼¾¾¾¿¿¿ÀÀÀÇÇÇÐÐÐÀÀÀÊÊÊÌÌÌÐÐÐÊÊÊÃÃÃÊÊÊÎÎÎÐÐÐÑÑÑÐÐÐÉÉÉÀÀÀ¼¼¼¿¿¿ÅÅÅÂÂÂÊÊÊÃÃÃÉÉÉÐÐÐÇÇÇÃÃû»»ÆÆƺºº´´´´´´···¼¼¼¿¿¿···´´´´´´······´´´´´´¸¸¸»»»ÂÂÂÃÃü¼¼···¸¸¸ººº¸¸¸»»»ÇÇǺºº···¿¿¿ÂÂÂÃÃó³³ÀÀÀÅÅÅÌÌÌÊÊÊÃÃþ¾¾¾¾¾¾¾¾»»»¼¼¼¿¿¿ÂÂÂÃÃÃÃÃÃÀÀÀÀÀÀ¼¼¼¼¼¼»»»»»»ººº¸¸¸···µµµ···¸¸¸¸¸¸»»»¼¼¼¿¿¿ÂÂÂÃÃÃÅÅÅÅÅÅÇÇÇÌÌÌÍÍÍÌÌÌÕÕÕäääÎÎÎÙÙÙÌÌÌÆÆÆÙÙÙÅÅÅÅÅÅ¿¿¿¼¼¼çççÛÛÛÝÝÝæææÎÎÎÎÎÎØØØÕÕÕÊÊÊÌÌÌÇÇÇÍÍÍÔÔÔÐÐÐÐÐÐÊÊÊÌÌÌÌÌÌÌÌÌÍÍÍÎÎÎÎÎÎÐÐÐÍÍÍÌÌÌÊÊÊÇÇÇÆÆÆÅÅÅÃÃÃÃÃþ¾¾¿¿¿ÃÃÃÃÃÃÆÆÆÇÇÇÅÅÅÃÃÃÅÅŵµµ´´´ÀÀÀººº¾¾¾ÌÌÌÐÐÐÔÔÔÕÕÕÑÑÑÎÎÎÌÌÌÉÉÉÅÅÅÇÇÇÉÉÉÊÊÊÉÉÉÅÅż¼¼µµµ°°°°°°´´´ÀÀÀÇÇǸ¸¸µµµ¼¼¼ÊÊÊÌÌÌÉÉÉÇÇÇÆÆÆ¿¿¿¿¿¿ÌÌÌÌÌÌÎÎÎÉÉÉÊÊÊÇÇÇÃÃÃÇÇÇÅÅÅÌÌÌÌÌÌÍÍÍÎÎÎÐÐÐÔÔÔØØØÛÛÛØØØÙÙÙÜÜÜàààâââßßßÙÙÙÕÕÕÐÐÐÍÍÍÊÊÊÊÊÊÌÌÌÊÊÊÉÉÉÇÇǼ¼¼ÇÇÇÐÐÐÎÎÎÌÌÌÌÌÌÍÍÍÌÌÌÉÉÉÆÆÆÃÃÃÀÀÀ¾¾¾»»»···´´´¸¸¸···´´´³³³³³³´´´µµµ···»»»»»»ººº»»»»»»¼¼¼¾¾¾¿¿¿¾¾¾¼¼¼¾¾¾ÃÃÃÅÅÅÆÆÆÌÌÌÒÒÒÃÃÃÉÉÉÐÐÐÒÒÒÊÊÊÂÂÂÊÊÊÕÕÕÔÔÔÐÐÐÊÊÊÆÆÆÇÇÇÌÌÌÎÎÎÐÐÐÐÐÐÊÊÊÅÅÅÔÔÔÑÑÑ´´´³³³Â³³³µµµ¸¸¸¼¼¼ÀÀÀÅÅÅÉÉÉÌÌ̾¾¾¸¸¸µµµ···¸¸¸···¸¸¸¼¼¼¼¼¼ÂÂÂÃÃÿ¿¿ººº¸¸¸·········ÃÃþ¾¾³³³µµµ¿¿¿ÇÇÇÀÀÀ³³³ºººÇÇÇÎÎÎÉÉÉÅÅÅ»»»»»»¼¼¼¿¿¿ÂÂÂÂÂÂÂÂÂÀÀÀ¿¿¿¼¼¼¼¼¼»»»ºººººº¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸ººº»»»¾¾¾¿¿¿ÂÂÂÃÃÃÅÅÅÆÆÆÇÇÇÊÊÊÍÍÍÍÍÍÒÒÒâââÍÍÍÔÔÔÌÌÌÆÆÆØØØÇÇÇÃÃô´´ÊÊÊæææØØØÝÝÝãããÍÍÍÎÎÎÕÕÕÐÐп¿¿Â¾¾¾ÅÅÅÉÉÉÊÊÊÊÊÊÃÃÃÅÅÅÆÆÆÉÉÉÌÌÌÌÌÌÍÍÍÍÍÍÊÊÊÉÉÉÇÇÇÆÆÆÅÅÅÃÃÃÃÃÃÃÃÃÅÅÅÇÇÇÍÍÍÅÅÅÀÀÀÅÅž¾¾ººº¸¸¸³³³»»»ÃÃþ¾¾¸¸¸ÆÆÆÕÕÕ×××ØØØÛÛÛÙÙÙØØØÔÔÔÐÐÐÍÍÍÍÍÍÎÎÎÎÎÎÎÎÎÎÎÎÌÌÌÉÉÉÇÇǸ¸¸±±±ºººÂÂÂÃÃü¼¼µµµ¾¾¾ÃÃÃÉÉÉÇÇÇÇÇÇÌÌÌÉÉÉÉÉÉÑÑÑÇÇÇÌÌÌÆÆÆÊÊÊÊÊÊÆÆÆÊÊÊÅÅÅÉÉÉÇÇÇÇÇÇÉÉÉÍÍÍÑÑÑÔÔÔÕÕÕÛÛÛÕÕÕÎÎÎÌÌÌÎÎÎÔÔÔÙÙÙÜÜÜÔÔÔÕÕÕÐÐÐÇÇÇÇÇÇÎÎÎÐÐÐÊÊʵµµÃÃÃÐÐÐÒÒÒÐÐÐÎÎÎÍÍÍÊÊÊÅÅÅ¿¿¿¾¾¾¾¾¾¼¼¼ººº···´´´³³³³³³±±±±±±³³³´´´µµµ¸¸¸¸¸¸¸¸¸ºººººº»»»¼¼¼¾¾¾¾¾¾¾¾¾ÃÃÃÊÊÊÍÍÍÍÍÍÑÑÑ××׿¿¿ÅÅÅÌÌÌÇÇÇÀÀÀÂÂÂÌÌ̸¸¸»»»ÀÀÀÆÆÆÊÊÊÇÇÇÃÃþ¾¾ÅÅÅØØØÌÌ̸¸¸´´´¼¼¼ÐÐÐÕÕÕÐÐÐ×××ÝÝÝßßßÜÜÜÕÕÕÑÑÑÎÎÎÊÊÊÀÀÀ¸¸¸¸¸¸ººº»»»¾¾¾Â¾¾¾¿¿¿ÂÂÂÃÃü¼¼µµµ´´´···¸¸¸¿¿¿ÇÇÇÀÀÀ¸¸¸¼¼¼ÂÂÂÊÊʼ¼¼···¼¼¼ÅÅÅÆÆÆÉÉÉÆÆÆ»»»¼¼¼¾¾¾¿¿¿ÀÀÀÂÂÂÀÀÀÀÀÀ¿¿¿¾¾¾¼¼¼»»»ººººººººº»»»¼¼¼ºººººº»»»»»»¾¾¾¿¿¿ÀÀÀÂÂÂÃÃÃÉÉÉÇÇÇÉÉÉÎÎÎÎÎÎÑÑÑÜÜÜ×××ÐÐÐÊÊÊÉÉÉØØØÊÊÊÆÆƵµµ×××ààà×××ÝÝÝàààÎÎÎÎÎÎÎÎÎÆÆƸ¸¸ÇÇÇÂÂÂÅÅÅ¿¿¿¿¿¿¾¾¾¼¼¼¿¿¿ÃÃÃÇÇÇÊÊÊÌÌÌÌÌÌÌÌÌÆÆÆÅÅÅÃÃÃÀÀÀÀÀÀÀÀÀÀÀÀÀÀÀÅÅÅÃÃÃÆÆƸ¸¸±±±µµµ¯¯¯³³³···¼¼¼Â¿¿¿»»»ÉÉÉ×××ÕÕÕØØØØØØØØØØØØ×××ÒÒÒÐÐÐÍÍÍÎÎÎÎÎÎÎÎÎÍÍÍÍÍÍÌÌÌÌÌÌÊÊÊÃÃô´´ºººÀÀÀÃÃÿ¿¿¸¸¸ÅÅÅÇÇÇÎÎÎÌÌÌÇÇÇÊÊÊÇÇÇÃÃÃÅÅÅÅÅÅÊÊÊÃÃÃÊÊÊÍÍÍÉÉÉÎÎÎÇÇÇÇÇÇÇÇÇÇÇÇÉÉÉÌÌÌÍÍÍÊÊÊÉÉÉÍÍÍÊÊÊÉÉÉÉÉÉÍÍÍÐÐÐÒÒÒÒÒÒØØØßßßÙÙÙÉÉÉÇÇÇÒÒÒÑÑÑÅÅÅÇÇÇÐÐÐÔÔÔÐÐÐÊÊÊÊÊÊÊÊÊÊÊÊÇÇÇÃÃþ¾¾»»»»»»ººº¸¸¸µµµ³³³³³³³³³³³³´´´µµµ···¸¸¸¸¸¸¸¸¸¸¸¸¸¸¸ººº»»»¼¼¼¾¾¾¾¾¾ÀÀÀÇÇÇÐÐÐÔÔÔÒÒÒÕÕÕÙÙÙÒÒÒÅÅÅÃÃÃÍÍÍÒÒÒÍÍÍÅÅÅÆÆÆÅÅÅÇÇÇÊÊÊÉÉÉÇÇÇÌÌÌÕÕÕßßßÀÀÀ¿¿¿¯¯¯···ÊÊÊÍÍÍÌÌÌÅÅÅÉÉÉÉÉÉÉÉÉÇÇÇÉÉÉÐÐÐÜÜÜæææÜÜÜÎÎÎÀÀÀ»»»ººº¸¸¸ººº¼¼¼¾¾¾¼¼¼ÀÀÀÅÅž¾¾´´´±±±µµµ···»»»ÒÒÒÒÒÒÃÃû»»¸¸¸ÊÊÊÐÐм¼¼´´´···¼¼¼ÇÇÇÇÇÇ»»»¾¾¾¾¾¾¿¿¿ÀÀÀÀÀÀÀÀÀÀÀÀ¿¿¿¿¿¿¾¾¾»»»ºººººº»»»¼¼¼¾¾¾»»»»»»»»»¼¼¼¼¼¼¿¿¿ÀÀÀÂÂÂÂÂÂÊÊÊÇÇÇÆÆÆÎÎÎÐÐÐÐÐÐØØØäääÎÎÎÉÉÉÇÇÇÕÕÕÌÌÌÊÊÊ¿¿¿ÙÙÙÙÙÙÔÔÔÝÝÝßßßÒÒÒÐÐÐÍÍ;¾¾¸¸¸ÒÒÒÐÐÐÌÌÌ»»»···´´´¸¸¸¼¼¼ÂÂÂÇÇÇÌÌÌÍÍÍÌÌÌÌÌÌÂÂÂÀÀÀ¿¿¿¾¾¾¼¼¼¾¾¾¾¾¾¿¿¿¾¾¾···»»»°°°¬¬¬±±±±±±¿¿¿ÅÅž¾¾¼¼¼¾¾¾ÅÅÅØØØàààÔÔÔÝÝÝÜÜÜÙÙÙÙÙÙ×××ÕÕÕÒÒÒÑÑÑÍÍÍÎÎÎÐÐÐÐÐÐÐÐÐÎÎÎÌÌÌÊÊÊÉÉÉ···¾¾¾ÃÃÃÅÅÅÀÀÀ···ÆÆÆ¿¿¿ÉÉÉÇÇÇÃÃÃÉÉÉÌÌÌÆÆÆÅÅÅÆÆÆÅÅÅÅÅÅÉÉÉÍÍÍÐÐÐÍÍÍÉÉÉÍÍÍÉÉÉÆÆÆÆÆÆÊÊÊÎÎÎÐÐÐÑÑÑØØØ×××ÔÔÔÑÑÑÊÊÊÅÅÅÉÉÉÑÑÑÒÒÒÎÎÎÔÔÔÕÕÕÆÆÆ¿¿¿ÊÊÊÑÑÑÉÉÉÃÃÃÔÔÔØØØÑÑÑÍÍÍÅÅÅÅÅÅÃÃÿ¿¿»»»¼¼¼ÀÀÀ¾¾¾······³³³±±±µµµµµµ³³³µµµ¼¼¼µµµ···¸¸¸ººººººººººººººººººÐÐÐÇÇÇÀÀÀ¾¾¾ººº¿¿¿¸¸¸ÕÕÕÂÂÂÃÃÃÔÔÔÔÔÔÍÍÍÐÐÐÕÕÕÒÒÒÊÊʾ¾¾¿¿¿ÌÌÌÊÊÊÀÀÀ¾¾¾´´´¾¾¾ÊÊÊÎÎÎÊÊÊÆÆÆÆÆÆÉÉÉÅÅÅÃÃÃÂÂÂÂÂÂÅÅÅÉÉÉÍÍÍÐÐÐÐÐÐÒÒÒÕÕÕÒÒÒÉÉÉÀÀÀ»»»»»»¸¸¸¼¼¼ÀÀÀÀÀÀººº···ººº¼¼¼¼¼¼ÃÃÃÌÌÌÐÐÐÑÑÑÃÃø¸¸ÂÂÂÌÌÌÀÀÀÀÀÀÀÀÀµµµµµµÃÃÃÊÊÊÀÀÀ»»»¿¿¿ÀÀÀ»»»¾¾¾ÃÃþ¾¾¼¼¼¼¼¼¼¼¼¼¼¼¾¾¾¾¾¾¿¿¿ÀÀÀ¿¿¿¾¾¾¼¼¼»»»»»»¼¼¼¿¿¿ÀÀÀÆÆÆÌÌÌÉÉÉÍÍÍÒÒÒÍÍÍÍÍÍÛÛÛÇÇÇÑÑÑÉÉÉÉÉɸ¸¸ÑÑÑÀÀÀÆÆƯ¯¯ëëëßßßØØØßßßÐÐÐÑÑÑ»»»¾¾¾ÍÍÍÛÛÛÑÑѸ¸¸±±±»»»···¼¼¼ÃÃÃÉÉÉÌÌÌÌÌÌÌÌÌÌÌÌÂÂÂÀÀÀ¿¿¿¾¾¾¼¼¼ººº¸¸¸···±±±±±±±±±ÂÂÂÅÅÅÃÃÃÊÊÊ»»»ÅÅÅ»»»±±±»»»ÐÐÐÔÔÔÌÌÌÉÉÉÎÎÎÝÝÝÑÑÑÐÐÐÔÔÔÎÎÎÑÑÑÐÐÐÍÍÍÊÊÊÇÇÇÉÉÉÎÎÎÑÑÑÍÍÍÉÉɵµµººº»»»ÂÂÂÉÉÉ»»»ÀÀÀÆÆÆÆÆÆÇÇÇÉÉÉÊÊÊÊÊÊÊÊÊÉÉÉÇÇÇÉÉÉÊÊÊÉÉÉÉÉÉÊÊÊÎÎÎÒÒÒÊÊÊÊÊÊÉÉÉÊÊÊÌÌÌÍÍÍÍÍÍÌÌÌÒÒÒÑÑÑÒÒÒÒÒÒÍÍÍÅÅÅÃÃÃÇÇÇÎÎÎÉÉÉÎÎÎÒÒÒÍÍÍÌÌÌÎÎÎÌÌÌÊÊÊÀÀÀÌÌÌÎÎÎÉÉÉÊÊÊÇÇÇÊÊÊÅÅÅÇÇÇÅÅÅ¿¿¿»»»»»»¸¸¸´´´ºººººº¸¸¸¸¸¸´´´³³³µµµ»»»ººº»»»¼¼¼¼¼¼¾¾¾¿¿¿ÀÀÀÃÃÃÀÀÀÒÒÒÌÌÌÊÊÊÍÍÍÌÌÌÑÑÑÎÎÎÊÊÊÇÇÇÊÊÊÉÉɼ¼¼ººº¾¾¾¾¾¾ººº¾¾¾»»»ÅÅÅÑÑѱ±±»»»ÅÅÅÌÌÌÑÑÑÐÐÐÇÇÇ¿¿¿»»»»»»¾¾¾¾¾¾¼¼¼¼¼¼¾¾¾ÂÂÂÆÆÆÉÉÉÎÎÎÍÍÍÐÐÐÐÐÐÒÒÒÎÎÎÀÀÀ¼¼¼»»»¼¼¼ÀÀÀÂÂÂÀÀÀÀÀÀÂÂÂÂÂÂÑÑÑÔÔÔÆÆÆÃÃÃÒÒÒÎÎλ»»ºººÅÅÅÆÆÆÇÇÇÆÆÆÅÅÅÀÀÀÀÀÀÅÅÅÉÉÉÀÀÀ¿¿¿ÀÀÀ¼¼¼»»»¼¼¼¼¼¼¾¾¾¾¾¾¼¼¼¼¼¼¾¾¾¿¿¿ÀÀÀÀÀÀ¾¾¾¼¼¼¼¼¼»»»»»»¼¼¼¾¾¾¿¿¿ÂÂÂÉÉÉÌÌÌÌÌÌÍÍÍÌÌÌÑÑÑÜÜÜÍÍÍÐÐÐÎÎÎÒÒÒ¼¼¼ÐÐÐÂÂÂÃÃð°°çççÛÛÛÒÒÒÔÔÔÇÇÇÑÑÑÌÌ̺ºº¸¸¸¿¿¿ÉÉÉÆÆƸ¸¸µµµ¼¼¼¸¸¸¾¾¾ÅÅÅÊÊÊÍÍÍÍÍÍÍÍÍÍÍÍÌÌÌÅÅž¾¾ººº¸¸¸¸¸¸···´´´³³³¸¸¸»»»ÅÅÅÃÃÃÂÂÂÉÉÉ»»»···µµµµµµÃÃÃÕÕÕ×××ÍÍÍÌÌÌÍÍÍÛÛÛÔÔÔÑÑÑÔÔÔÍÍÍÑÑÑÎÎÎÎÎÎÌÌÌÌÌÌÍÍÍÎÎÎÉÉɼ¼¼³³³´´´¿¿¿ÃÃÃÃÃÿ¿¿µµµ¸¸¸ÇÇÇÆÆÆÇÇÇÇÇÇÇÇÇÇÇÇÆÆÆÇÇÇÇÇÇÅÅÅÉÉÉÌÌÌÇÇÇÃÃÃÅÅÅÍÍÍ×××ÊÊÊÍÍÍÐÐÐÑÑÑÐÐÐÎÎÎÍÍÍÌÌÌÎÎÎÍÍÍÎÎÎÒÒÒÑÑÑÊÊÊÇÇÇÉÉÉÆÆÆÂÂÂÅÅÅÊÊÊÎÎÎÔÔÔÑÑÑÅÅÅÎÎο¿¿ÀÀÀººº³³³······ºººÃÃÃÊÊÊÍÍÍÉÉÉÃÃÿ¿¿ººº´´´±±±µµµ···´´´´´´¸¸¸¼¼¼¿¿¿¸¸¸ºººººº¸¸¸···ººº¾¾¾Â°°°ÀÀÀÀÀÀÀÀÀ¿¿¿ÇÇÇÎÎÎÔÔÔÒÒÒÔÔÔÐÐÐÉÉÉÌÌÌÌÌÌÂÂÂÇÇÇÍÍÍÆÆÆÊÊÊÕÕÕÅÅž¾¾ÜÜÜÉÉÉÌÌÌÎÎÎÍÍÍÇÇÇÀÀÀ¼¼¼»»»»»»ººº¸¸¸¸¸¸»»»¾¾¾ÂÂÂÃÃÃÍÍÍÉÉÉÊÊÊÉÉÉØØØÙÙÙ¾¾¾¸¸¸»»»¾¾¾¼¼¼¼¼¼ÂÂÂÉÉÉÎÎÎÒÒÒÕÕÕ×××¼¼¼µµµÑÑÑÙÙÙÊÊÊÃÃþ¾¾ÊÊÊÊÊÊÇÇÇÍÍÍÉÉÉ¿¿¿ÀÀÀÌÌÌÆÆÆÀÀÀ¿¿¿¿¿¿ººº¸¸¸¾¾¾¿¿¿¿¿¿¾¾¾¾¾¾¾¾¾¿¿¿ÀÀÀ»»»»»»»»»»»»¼¼¼¼¼¼¼¼¼¾¾¾¿¿¿ÅÅÅÍÍÍÌÌÌÇÇÇÌÌÌÕÕÕÙÙÙÒÒÒÍÍÍÔÔÔÛÛÛ¾¾¾ÎÎÎÅÅž¾¾¬¬¬ßßßÛÛÛ××××××ÊÊÊÑÑÑÉÉÉÀÀÀ»»»¸¸¸»»»¼¼¼ºººººº¼¼¼»»»ÀÀÀÇÇÇÌÌÌÍÍÍÎÎÎÎÎÎÎÎÎÎÎÎÉÉÉÀÀÀ»»»¸¸¸µµµ³³³°°°···¿¿¿ÃÃÃÆÆÆÂÂÂÀÀÀÅÅÅ»»»³³³»»»ÃÃÃÎÎÎØØØÑÑÑÆÆÆÆÆÆÉÉÉ×××ÕÕÕÔÔÔÒÒÒÍÍÍÎÎÎÍÍÍÅÅÅÉÉÉÍÍÍÎÎÎÊÊÊÃÃû»»µµµºººÅÅÅÆÆƾ¾¾µµµ¬¬¬±±±ÃÃÃÅÅÅÇÇÇÉÉÉÆÆÆÃÃÃÂÂÂÅÅÅÆÆÆÀÀÀÅÅÅÇÇÇÆÆÆÂÂÂÃÃÃÉÉÉÐÐÐÌÌÌÐÐÐÔÔÔÔÔÔÒÒÒÑÑÑÐÐÐÑÑÑÎÎÎÉÉÉÉÉÉÎÎÎÒÒÒÑÑÑÒÒÒÕÕÕÀÀÀÀÀÀ¿¿¿ÀÀÀÉÉÉÑÑÑÎÎÎÃÃÃÐÐÐÃÃÃÆÆÆÀÀÀ¸¸¸¸¸¸°°°¬¬¬µµµ¾¾¾ÃÃÃÆÆÆÇÇÇÆÆƾ¾¾³³³³³³µµµ´´´±±±´´´»»»¼¼¼···Â¿¿¿¿¿¿ÂÂÂÊÊÊÐÐÐÂÂÂÆÆÆÂÂÂÂÂÂÅÅÅÀÀÀÂÂÂÇÇÇÇÇÇÃÃÃÌÌÌÔÔÔ×××ÜÜÜÝÝÝØØØ×××ÝÝÝÜÜÜÜÜÜÛÛÛÇÇǼ¼¼ÌÌÌÃÃÃÅÅÅÅÅÅÆÆÆÅÅÅÃÃÃÀÀÀ¿¿¿¼¼¼»»»»»»»»»¼¼¼¿¿¿ÂÂÂÅÅÅÊÊÊÅÅÅÅÅÅÂÂÂÔÔÔØØغºº³³³ººº¿¿¿»»»···¾¾¾ÉÉÉÕÕÕàààÐÐÐÍÍ͸¸¸µµµÇÇÇÒÒÒÕÕÕÒÒÒ»»»ÆÆÆÇÇÇÆÆÆÌÌÌÌÌÌÆÆÆÂÂÂÀÀÀÊÊÊÇÇÇ¿¿¿¿¿¿»»»ºººÂ¿¿¿¿¿¿ÀÀÀÀÀÀÂÂÂÀÀÀÀÀÀ¿¿¿ºººººº»»»¼¼¼¼¼¼¼¼¼¼¼¼¼¼¼¿¿¿ÂÂÂÌÌÌÍÍÍÇÇÇÐÐÐØØØÐÐÐÔÔÔÉÉÉÒÒÒÛÛÛ¼¼¼ÉÉÉÃÃúºº¬¬¬ÛÛÛÝÝÝÜÜÜÝÝÝØØØÙÙÙÇÇÇÊÊÊÆÆƾ¾¾¼¼¼¼¼¼¼¼¼¼¼¼¼¼¼ÀÀÀÇÇÇÌÌÌÍÍÍÍÍÍÎÎÎÐÐÐÊÊÊÊÊÊÆÆÆÀÀÀ¸¸¸´´´³³³³³³¼¼¼ÅÅÅÇÇÇÅÅÅÀÀÀÂÂÂÀÀÀ···¸¸¸ÅÅÅÎÎÎ×××ØØØÌÌÌÂÂÂÆÆÆÆÆÆÒÒÒØØØ×××ÒÒÒÎÎÎÍÍÍÌÌÌÍÍÍÒÒÒÒÒÒÊÊʾ¾¾···¸¸¸¼¼¼ÀÀÀ»»»´´´´´´°°°­­­´´´¿¿¿ÃÃÃÇÇÇÇÇÇÃÃÃÂÂÂÃÃÃÆÆÆÂÂÂÂÂÂÃÃÃÆÆÆÉÉÉÊÊÊÉÉÉÇÇÇÉÉÉÊÊÊÍÍÍÎÎÎÍÍÍÍÍÍÐÐÐÑÑÑÌÌÌÆÆÆÆÆÆÌÌÌÑÑÑÑÑÑÒÒÒÔÔÔÃÃÃÆÆÆÃÃÿ¿¿ÃÃÃÊÊÊÌÌÌÇÇÇ¿¿¿ºººÆÆÆÆÆÆ···­­­ªªª­­­°°°µµµÀÀÀÇÇǸ¸¸¸¸¸···³³³³³³»»»ÃÃÃÀÀÀ······µµµ³³³¯¯¯­­­¯¯¯´´´¸¸¸ÅÅž¾¾ÃÃÃÔÔÔÛÛÛØØØÝÝÝÑÑÑÔÔÔÛÛÛ×××ÇÇǾ¾¾ÀÀÀÀÀÀ¿¿¿¾¾¾¿¿¿ÃÃÃÇÇÇÉÉÉÃÃÃÂÂÂÀÀÀÀÀÀÀÀÀ¿¿¿¾¾¾»»»¼¼¼¼¼¼¼¼¼¼¼¼¾¾¾ÀÀÀÂÂÂÃÃÃÆÆÆÅÅÅÅÅÅÀÀÀÎÎÎÔÔÔ¿¿¿¸¸¸···ÅÅÅÅÅż¼¼¾¾¾ÃÃÃÌÌÌØØØ×××ÇÇÇ···¾¾¾¾¾¾ÀÀÀÒÒÒÍÍÍ»»»ÀÀÀÉÉÉÌÌÌÌÌÌÐÐÐÐÐÐÅÅÅ···ÎÎÎÒÒÒÃÃþ¾¾¼¼¼»»»ÀÀÀ¾¾¾¿¿¿ÂÂÂÅÅÅÅÅÅ¿¿¿¼¼¼¸¸¸ººº»»»»»»¼¼¼¼¼¼¾¾¾¾¾¾ÃÃÃÂÂÂÉÉÉÍÍÍÍÍÍÕÕÕÕÕÕÇÇÇÑÑÑÇÇÇÎÎÎÎÎλ»»ÇÇǸ¸¸±±±ÜÜÜäääàààÜÜÜÜÜÜæææ×××ÌÌÌÎÎÎÌÌÌÆÆÆÂÂÂÀÀÀ¿¿¿¼¼¼¾¾¾ÂÂÂÇÇÇÊÊÊÌÌÌÍÍÍÎÎÎÐÐÐÉÉÉÌÌÌÉÉÉÀÀÀµµµ³³³ºººÀÀÀÅÅÅÆÆÆÆÆÆÀÀÀÀÀÀ»»»´´´¾¾¾ÉÉÉÒÒÒ××××××ÌÌÌÆÆÆÎÎÎÅÅÅÐÐÐÛÛÛØØØÑÑÑÐÐÐÍÍÍÌÌÌÍÍÍÌÌÌÇÇÇÀÀÀººº···»»»¿¿¿¸¸¸¸¸¸°°°¯¯¯···¸¸¸±±±±±±ºººÀÀÀÆÆÆÉÉÉÆÆÆÃÃÃÅÅÅÆÆÆÆÆÆÃÃÃÂÂÂÆÆÆÍÍÍÎÎÎÌÌÌÆÆÆÂÂÂÃÃÃÃÃÃÅÅÅÅÅÅÆÆÆÉÉÉÌÌÌÆÆÆÃÃÃÅÅÅÊÊÊÍÍÍÉÉÉÆÆÆÅÅÅÉÉÉÎÎÎÌÌÌÆÆÆÆÆÆÇÇÇÉÉÉÍÍÍÃÃû»»¿¿¿ººº´´´¼¼¼»»»ººº³³³°°°¬¬¬¯¯¯»»»ÉÉÉÌÌÌÆÆÆÃÃÿ¿¿»»»»»»ÀÀÀÃÃÿ¿¿¸¸¸ÀÀÀÀÀÀ¿¿¿ÀÀÀÃÃÃÉÉÉÍÍÍÎÎξ¾¾ÃÃÃÇÇÇ¿¿¿ÀÀÀÆÆÆÆÆÆÔÔÔÕÕÕÛÛÛÛÛÛÌÌÌ»»»¼¼¼»»»¯¯¯¸¸¸³³³±±±°°°³³³ÃÃÃÍÍÍÅÅÅ¿¿¿¿¿¿¾¾¾¾¾¾¾¾¾¼¼¼»»»»»»»»»»»»»»»»»»¼¼¼¾¾¾ÀÀÀÀÀÀÂÂÂÆÆÆÅÅÅÆÆÆÌÌÌÒÒÒÎÎÎÀÀÀ¸¸¸ÎÎÎÒÒÒÉÉÉÇÇǾ¾¾ÃÃÃÜÜÜÃÃô´´Â»»»¼¼¼ÔÔÔÆÆƼ¼¼¾¾¾ÌÌÌÔÔÔÐÐÐÒÒÒÔÔÔÉÉɺººÎÎÎÕÕÕÉÉÉ¿¿¿¼¼¼¼¼¼¼¼¼¼¼¼¿¿¿ÃÃÃÅÅÅÅÅž¾¾»»»ººººººººº»»»¼¼¼¾¾¾¿¿¿¿¿¿ÆÆÆÅÅÅÉÉÉÎÎÎÒÒÒ×××ÒÒÒÉÉÉÊÊÊÌÌÌÊÊÊÀÀÀÀÀÀÍÍÍÀÀÀ¾¾¾°°°ÑÑÑæææëëëßßßÙÙÙäääßßßÇÇÇÌÌÌÍÍÍÌÌÌÉÉÉÆÆÆÃÃÃÀÀÀÀÀÀÅÅÅÉÉÉÌÌÌÍÍÍÍÍÍÎÎÎÐÐÐÎÎÎÍÍÍÆÆÆ»»»³³³···ÃÃÃÐÐÐÉÉÉÇÇÇÆÆÆ¿¿¿ÀÀÀ¿¿¿µµµ»»»ÌÌÌÒÒÒÕÕÕØØØØØØÍÍÍÇÇÇÎÎÎÇÇÇÌÌÌÛÛÛÙÙÙÑÑÑÔÔÔÎÎÎÌÌÌ¿¿¿»»»···¸¸¸¾¾¾¿¿¿¼¼¼···¨¨¨¯¯¯¯¯¯°°°»»»¾¾¾»»»¼¼¼ººº¿¿¿ÅÅÅÇÇÇÇÇÇÆÆÆÆÆÆÇÇÇÇÇǾ¾¾¿¿¿ÅÅÅÉÉÉÊÊÊÉÉÉÂÂÂÀÀÀÀÀÀÀÀÀÂÂÂÅÅÅÅÅÅÅÅÅÇÇÇÃÃÃÃÃÃÇÇÇÇÇÇÃÃÃÀÀÀÂÂÂÇÇÇÍÍÍÍÍÍÌÌÌÍÍÍÅÅÅÀÀÀÇÇÇÒÒÒÉÉÉÉÉÉ»»»±±±»»»¾¾¾¾¾¾ºººººº¸¸¸µµµºººÂÂÂÅÅÅÃÃÃÇÇÇÆÆÆÃÃþ¾¾···µµµµµµ¾¾¾»»»¸¸¸···¸¸¸ººº···´´´»»»ÇÇÇÐÐм¼¼´´´ººº»»»ÍÍÍÒÒÒÎÎÎÉÉɼ¼¼³³³¸¸¸»»»±±±ªªª±±±¿¿¿ÍÍÍÔÔÔÒÒÒÇÇǺºº¼¼¼¼¼¼¾¾¾¾¾¾¾¾¾¼¼¼¼¼¼¼¼¼¼¼¼¼¼¼¼¼¼¼¼¼¾¾¾¿¿¿ÀÀÀÀÀÀÃÃÃÆÆÆÂÂÂÊÊÊÊÊÊÎÎÎØØؼ¼¼¿¿¿ÕÕÕ×××ÎÎÎÒÒÒÌÌ̼¼¼»»»ÙÙÙÉÉÉ···ÀÀÀ¼¼¼ÀÀÀÙÙÙÉÉɾ¾¾¿¿¿ÇÇÇÍÍÍÌÌÌÊÊÊÌÌÌÎÎÎÂÂÂÅÅÅÌÌÌÍÍÍÃÃÿ¿¿¿¿¿¾¾¾¿¿¿ÀÀÀÂÂÂÂÂÂÂÂÂÀÀÀ¾¾¾¼¼¼»»»»»»ººº»»»¼¼¼¾¾¾ÀÀÀÂÂÂÆÆÆÉÉÉÊÊÊÎÎÎÔÔÔÒÒÒÑÑÑÕÕÕÃÃÃÔÔÔÉÉɸ¸¸ÌÌÌØØØÃÃÃÅÅŵµµ¼¼¼ÑÑÑíííççç×××ÛÛÛÜÜÜÎÎÎÌÌÌÊÊÊÎÎÎÑÑÑÎÎÎÉÉÉÆÆÆÅÅÅÇÇÇÌÌÌÎÎÎÎÎÎÐÐÐÑÑÑÔÔÔÒÒÒÌÌÌÀÀÀººº»»»ÂÂÂÌÌÌÑÑÑÌÌÌÉÉÉÊÊÊÃÃÿ¿¿ººº´´´ÇÇÇÔÔÔ×××ØØØÛÛÛÝÝÝÒÒÒÇÇÇÉÉÉÊÊÊÊÊÊÛÛÛØØØÑÑÑ×××ÐÐÐÌÌ̾¾¾¼¼¼¼¼¼¾¾¾¾¾¾¸¸¸°°°©©©¥¥¥°°°³³³´´´¾¾¾ÃÃÃÂÂÂÃÃÃÀÀÀÂÂÂÅÅÅÆÆÆÆÆÆÇÇÇÉÉÉÉÉÉÅÅÅ¿¿¿ºººµµµ¸¸¸¿¿¿ÆÆÆÊÊÊÆÆÆÃÃÃÂÂÂÃÃÃÆÆÆÆÆÆÅÅÅÃÃÃÌÌÌÆÆÆÃÃÃÃÃÃÃÃÃÃÃÃÆÆÆÊÊÊÂÂÂÇÇÇÉÉÉÍÍÍÐÐÐÃÃø¸¸¾¾¾ÀÀÀÀÀÀÌÌÌÅÅźººººº±±±©©©³³³ººº¾¾¾ººº´´´³³³³³³±±±©©©¯¯¯¸¸¸¿¿¿¼¼¼¸¸¸ÀÀÀÎÎδ´´´´´···ÀÀÀÎÎÎ×××ØØØ×××ÍÍÍÎÎÎÌÌÌ···¸¸¸Â¸¸¸»»»ÃÃû»»¾¾¾¾¾¾···ºººÍÍÍÛÛÛÒÒÒÎÎÎÃÃÃÂÂÂÅÅž¾¾¸¸¸¾¾¾ÀÀÀÂÂÂÂÂÂÀÀÀ¾¾¾»»»ºººººº¿¿¿¿¿¿¿¿¿ÀÀÀÀÀÀÂÂÂÂÂÂÃÃÃÅÅÅÆÆƾ¾¾ÊÊÊÇÇÇÉÉÉ×××±±±ÆÆÆØØØÔÔÔÍÍÍØØØÕÕÕÅÅÅ¿¿¿ØØØ×××ÀÀÀ¿¿¿»»»ÀÀÀÛÛÛÌÌÌÀÀÀ¾¾¾¾¾¾Â¾¾¾ÂÂÂÒÒÒÉÉɺºº¿¿¿ÍÍÍÊÊÊÃÃÃÃÃÃÅÅÅÂÂÂÀÀÀÀÀÀ¿¿¿¿¿¿¾¾¾¾¾¾¿¿¿¼¼¼»»»ºººººº»»»¾¾¾ÂÂÂÃÃÃÃÃÃÊÊÊÌÌÌÎÎÎÔÔÔÎÎÎÑÑÑâââÀÀÀÛÛÛÊÊÊ´´´ÕÕÕâââÆÆÆÊÊÊÉÉɯ¯¯´´´ÝÝÝæææÔÔÔ×××ÜÜÜÛÛÛÐÐÐÊÊÊÑÑÑØØØÕÕÕÎÎÎÊÊÊÇÇÇÊÊÊÎÎÎÑÑÑÑÑÑÒÒÒÔÔÔÕÕÕÒÒÒÉÉɾ¾¾¾¾¾ÆÆÆÍÍÍÍÍÍÊÊÊÌÌÌÊÊÊÐÐÐÇÇǾ¾¾´´´³³³ÒÒÒÎÎÎÑÑÑÔÔÔÜÜÜäääÜÜÜÎÎÎÍÍÍÌÌÌÊÊÊÛÛÛØØØÒÒÒØØØÑÑÑÌÌÌ´´´¾¾¾ÆÆÆÆÆƼ¼¼´´´±±±´´´­­­µµµµµµµµµÀÀÀÇÇÇÃÃÃÀÀÀÇÇÇÆÆÆÅÅÅÃÃÃÅÅÅÇÇÇÉÉÉÊÊÊÀÀÀ³³³°°°¸¸¸»»»µµµ¾¾¾ÎÎÎÆÆÆÇÇÇÇÇÇÆÆÆÅÅÅÆÆÆÉÉÉÌÌÌÕÕÕÒÒÒÌÌÌÀÀÀµµµÇÇÇÇÇÇÅÅÅÀÀÀÐÐÐÕÕÕÔÔÔÌÌÌ···¸¸¸···ºººÂÂÂÌÌÌÊÊʼ¼¼¾¾¾±±±°°°±±±ºººÀÀÀ¾¾¾µµµ­­­¯¯¯¼¼¼¿¿¿¸¸¸¿¿¿ÆÆƸ¸¸¯¯¯¯¯¯°°°±±±¬¬¬±±±±±±´´´ÝÝÝÛÛÛÃÃÿ¿¿¾¾¾¼¼¼ÀÀÀ¾¾¾¿¿¿ÆÆƱ±±¸¸¸³³³ÀÀÀÇÇÇÉÉÉÂÂÂÀÀÀÃÃÃÆÆƼ¼¼¸¸¸»»»¾¾¾ÆÆƾ¾¾»»»¾¾¾»»»´´´³³³···µµµ»»»¾¾¾¼¼¼¾¾¾ÃÃÃÃÃÿ¿¿ÉÉÉ»»»ÅÅÅÇÇÇÅÅÅÌÌÌÆÆƼ¼¼ÆÆÆÕÕÕÑÑÑÌÌÌÅÅÅÛÛÛ´´´¿¿¿ÒÒÒÕÕÕÔÔÔººººººÑÑÑÐÐÐÌÌÌÉÉÉÂÂÂÂÂÂÌÌÌÐÐÐÉÉÉÀÀÀ¼¼¼ÅÅÅÌÌ̼¼¼ÕÕÕÌÌÌÃÃÃÇÇÇÀÀÀÀÀÀÀÀÀ¿¿¿¿¿¿¾¾¾¾¾¾¼¼¼¼¼¼¾¾¾ººº»»»¿¿¿Â¿¿¿ÀÀÀÅÅÅÃÃÃÍÍÍÉÉÉÎÎÎÙÙÙÍÍÍÇÇÇÜÜÜÊÊÊÎÎÎâââÉÉɳ³³»»»ØØØÌÌÌÀÀÀÀÀÀ¿¿¿ÌÌÌÛÛÛØØØÑÑÑÙÙÙÙÙÙèèèÕÕÕÉÉÉÎÎÎÊÊÊÐÐÐÙÙÙÑÑÑÒÒÒÒÒÒÒÒÒÔÔÔÕÕÕ×××ØØØÐÐÐÆÆƸ¸¸»»»ÍÍÍÍÍÍ»»»°°°¸¸¸ÌÌÌÎÎÎÃÃÿ¿¿ººº¸¸¸ÔÔÔÔÔÔÙÙÙÛÛÛØØØÙÙÙÒÒÒÃÃÃÌÌÌÒÒÒâââØØØÛÛÛÔÔÔÐÐи¸¸ºººÃÃÃÅÅźºº´´´ººº¾¾¾¾¾¾¸¸¸°°°¯¯¯³³³¸¸¸ÂÂÂÅÅż¼¼ÃÃÃÉÉÉÊÊÊÅÅÅÃÃÃÆÆÆÆÆÆÃÃû»»ºººÀÀÀÉÉɱ±±±±±¾¾¾ÉÉÉÊÊÊÌÌÌÌÌÌÌÌÌÍÍÍÑÑÑÔÔÔÑÑÑÑÑÑÇÇǵµµ¸¸¸´´´ÆÆÆÂÂÂÅÅÅÂÂÂÍÍÍÑÑÑÒÒÒÎÎμ¼¼¸¸¸¼¼¼¸¸¸»»»ÆÆÆÐÐÐÒÒÒÐÐÐÎÎÎÉÉÉÇÇÇÀÀÀººº¼¼¼ÀÀÀ¼¼¼´´´ººº¼¼¼ººº»»»ÃÃÃÀÀÀ³³³¯¯¯¯¯¯ªªªªªª©©©³³³¸¸¸ºººÒÒÒ···¼¼¼»»»ºººÀÀÀ¿¿¿¿¿¿Â¼¼¼ÕÕÕÎÎÎÑÑÑÍÍÍÇÇǾ¾¾ÀÀÀ¿¿¿¼¼¼ººº»»»¾¾¾¼¼¼¼¼¼¼¼¼»»»´´´­­­­­­±±±´´´ººº¾¾¾¼¼¼¼¼¼ÀÀÀ¿¿¿ÇÇǾ¾¾ÅÅÅÅÅÅÆÆÆÊÊÊÀÀÀ»»»ÊÊÊÔÔÔÎÎÎÍÍÍÊÊÊàààÃÃÃ×××ÍÍÍÒÒÒ×××ÆÆÆÇÇÇØØØÐÐÐÅÅÅÂÂÂÅÅÅÊÊÊÐÐÐÔÔÔÑÑÑÆÆƼ¼¼¾¾¾ÍÍÍÀÀÀÔÔÔÍÍÍ¿¿¿¿¿¿¿¿¿¿¿¿¾¾¾¾¾¾¾¾¾¾¾¾¼¼¼»»»¸¸¸ººº¿¿¿ÂÂÂÀÀÀÂÂÂÆÆÆÅÅÅÅÅÅÉÉÉÎÎÎÐÐÐÍÍÍÑÑÑÜÜÜÌÌÌÕÕÕÙÙÙÉÉÉ»»»´´´ÃÃÃÒÒÒÆÆÆÃÃúºººººÍÍÍÝÝÝÛÛÛÑÑÑÜÜÜàààÍÍÍÊÊÊÕÕÕÑÑÑÌÌÌÃÃÃÌÌÌÍÍÍÐÐÐÔÔÔ×××ØØØØØØ×××ÕÕÕÐÐÐÀÀÀ···¸¸¸ººº»»»Â¸¸¸ÆÆÆÐÐÐÊÊÊÀÀÀ¾¾¾¼¼¼···ÍÍÍÎÎÎØØØÜÜÜÜÜÜâââàààÕÕÕÒÒÒÎÎÎÜÜÜÛÛÛÛÛÛÐÐÐÍÍ͸¸¸ÀÀÀÅÅÅ¿¿¿´´´°°°¸¸¸¾¾¾¼¼¼ººº°°°¯¯¯¯¯¯¬¬¬´´´ÀÀÀÅÅÅÀÀÀÅÅÅÅÅÅÂÂÂÃÃÃÇÇÇÇÇÇÃÃô´´»»»ÇÇÇÎÎγ³³···ÅÅÅÌÌÌÍÍÍÎÎÎÎÎÎÎÎÎÐÐÐÒÒÒÕÕÕÎÎÎÑÑÑÆÆƱ±±´´´µµµÇÇÇ¿¿¿ÃÃÃÃÃÃÊÊÊÌÌÌÐÐÐÑÑÑÃÃû»»¼¼¼µµµ±±±···¼¼¼¾¾¾¾¾¾¼¼¼³³³¿¿¿ÅÅž¾¾ººº¿¿¿¾¾¾···ÃÃû»»³³³¼¼¼ÆÆÆ»»»³³³µµµ¯¯¯¬¬¬¬¬¬¦¦¦©©©±±±³³³¼¼¼¾¾¾ºººÅÅž¾¾ÅÅÅ¿¿¿Â»»»ÛÛÛÎÎÎÍÍÍÌÌÌÆÆÆÉÉɼ¼¼¼¼¼¼¼¼¼¼¼¼¼¼»»»»»»»»»¾¾¾¼¼¼µµµ¬¬¬©©©­­­°°°°°°¯¯¯µµµ»»»¼¼¼¾¾¾ÂÂÂÃÃÃÃÃÃÅÅÅÂÂÂÃÃÃÀÀÀÉÉÉÊÊÊ»»»»»»ÝÝÝØØØÇÇÇÅÅÅÃÃÃÔÔÔ···ÃÃÃÒÒÒÕÕÕÕÕÕÇÇÇÉÉÉØØØÔÔÔÌÌÌÀÀÀÉÉÉÐÐÐÐÐÐÐÐÐÐÐÐÅÅŵµµ¸¸¸ÍÍÍÃÃÃÐÐÐÍÍÍÀÀÀ¼¼¼¾¾¾¼¼¼¼¼¼¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¼¼¼»»»¼¼¼¿¿¿ÂÂÂÀÀÀÃÃÃÆÆÆÉÉÉÅÅÅÐÐÐÕÕÕÊÊÊÊÊÊÒÒÒÍÍÍÆÆÆÙÙÙÎÎÎÃÃ÷·····ÙÙÙÊÊÊÇÇǼ¼¼°°°¼¼¼ÜÜÜæææ×××ÔÔÔÜÜÜÔÔÔÎÎÎÊÊÊÆÆÆÉÉÉÅÅÅÍÍÍÌÌÌÌÌÌÎÎÎÒÒÒÕÕÕÕÕÕÔÔÔÕÕÕØØØÑÑÑÅÅż¼¼¸¸¸»»»ÃÃü¼¼¿¿¿ÍÍÍÐÐÐÃÃÿ¿¿ÀÀÀ¸¸¸ÌÌÌÐÐÐÙÙÙÝÝÝÛÛÛÝÝÝàààÙÙÙàààÑÑÑàààãããâââÔÔÔÔÔÔ¿¿¿ÆÆÆÅÅÅ»»»°°°­­­···¾¾¾¼¼¼µµµ³³³»»»ÀÀÀµµµ±±±¼¼¼ÆÆÆ¿¿¿ÀÀÀÀÀÀÀÀÀÅÅÅÉÉÉÆÆƱ±±»»»ÇÇÇÎÎÎÆÆÆ»»»¿¿¿ÉÉÉÌÌÌÍÍÍÎÎÎÍÍÍÌÌÌÊÊÊÊÊÊÌÌÌÎÎÎÐÐÐÉÉÉ»»»¿¿¿ºººÇÇÇ¿¿¿¿¿¿ÆÆÆÌÌÌÊÊÊÌÌÌÎÎÎÉÉÉÀÀÀ»»»»»»¼¼¼»»»¸¸¸µµµµµµ···­­­¼¼¼ÆÆÆÀÀÀººººººÀÀÀÅÅÅ···ººº¸¸¸ÇÇÇÎÎξ¾¾´´´µµµµµµ¸¸¸ººº¯¯¯¥¥¥ªªª±±±´´´´´´¯¯¯ººº»»»»»»ÅÅÅÅÅÅÅÅÅ¿¿¿µµµ×××ÍÍÍÍÍÍÌÌÌ¿¿¿¾¾¾¾¾¾»»»ºººººº»»»»»»ººº···µµµ´´´°°°¯¯¯¸¸¸ÀÀÀµµµ¤¤¤···»»»ÀÀÀÀÀÀ¿¿¿¾¾¾¾¾¾¿¿¿ÀÀÀÃÃþ¾¾ÍÍÍÌÌ̸¸¸¾¾¾×××ÍÍÍ»»»»»»ÀÀÀÒÒÒ···µµµ¿¿¿ÅÅÅÃÃø¸¸»»»ÊÊÊÑÑÑÑÑÑÐÐÐÔÔÔ×××ÔÔÔÐÐÐÉÉɼ¼¼±±±···ÌÌÌÀÀÀÅÅÅÍÍÍ»»»»»»»»»»»»¼¼¼¼¼¼¾¾¾¿¿¿¿¿¿¿¿¿ÂÂÂÀÀÀ¿¿¿¿¿¿ÀÀÀÂÂÂÃÃÃÆÆÆÆÆÆÅÅÅÔÔÔÙÙÙÍÍÍÎÎÎÒÒÒÇÇÇÌÌÌâââÊÊÊ¿¿¿Â¿¿¿±±±ÎÎÎÌÌÌÇÇÇÅÅŸ¸¸´´´ÊÊÊäääæææÑÑÑÛÛÛÙÙÙ×××ÍÍÍÇÇÇÍÍÍÅÅÅÌÌÌÊÊÊÌÌÌÑÑÑÕÕÕ×××ÑÑÑÌÌÌÑÑÑ××××××ÔÔÔÑÑÑÎÎÎÊÊÊÇÇÇÃÃÃÀÀÀÇÇÇÍÍÍÊÊÊÆÆÆÃÃü¼¼¼¼¼ÂÂÂÑÑÑÙÙÙÙÙÙÝÝÝâââßßßàààÒÒÒãããçççäääÛÛÛÙÙÙ¿¿¿ÅÅÅÅÅÅ¿¿¿´´´°°°µµµ»»»¼¼¼´´´³³³¿¿¿ÉÉɼ¼¼±±±···ÀÀÀÀÀÀÀÀÀÀÀÀÃÃÃÇÇÇÇÇǼ¼¼ºººÀÀÀÌÌÌÑÑÑÎÎÎÅÅÅ»»»¸¸¸ÆÆÆÉÉÉÊÊÊÊÊÊÉÉÉÆÆÆÆÆÆÆÆÆÌÌÌÊÊÊÊÊÊÊÊÊÍÍͺººÂ¿¿¿ºººÆÆÆÍÍÍÌÌÌÇÇÇÉÉÉÌÌÌÉÉÉÆÆÆÊÊÊÍÍÍÊÊÊÅÅż¼¼µµµ±±±´´´···¿¿¿ÅÅŸ¸¸´´´µµµ¬¬¬¿¿¿ÃÃÃÍÍÍÎÎλ»»´´´°°°¬¬¬±±±±±±ªªª¦¦¦­­­¸¸¸···ÆÆƵµµ¸¸¸ººººººÂÂÂÂÂÂÅÅÅÆÆÆ¿¿¿ÜÜÜÒÒÒÑÑÑÊÊÊ¿¿¿¼¼¼¿¿¿»»»¸¸¸¸¸¸ººº¸¸¸µµµ³³³³³³±±±­­­¯¯¯¿¿¿ÎÎÎÅÅÅ°°°³³³···¼¼¼ÂÂÂÃÃÃÃÃÃÅÅÅÆÆƾ¾¾ÃÃþ¾¾ÎÎÎÍÍ͸¸¸¿¿¿ÅÅÅÉÉÉÃÃÃÃÃÃÇÇÇÕÕÕÀÀÀ¸¸¸¯¯¯¸¸¸¼¼¼»»»¼¼¼ÅÅÅÐÐÐÒÒÒ××××××ÙÙÙÜÜÜ×××ÆÆƸ¸¸±±±»»»ÉÉɼ¼¼¸¸¸ÉÉÉÅÅž¾¾ººº»»»»»»¼¼¼¾¾¾¾¾¾¿¿¿ÀÀÀÀÀÀÂÂÂÂÂÂÀÀÀ¿¿¿ÂÂÂÆÆÆÊÊÊÍÍÍÎÎÎÒÒÒ×××ÕÕÕÍÍÍÉÉÉÉÉÉÅÅÅßßßäääÊÊÊÂÂÂÀÀÀ¾¾¾¬¬¬¼¼¼ÐÐÐÅÅÅÆÆÆÅÅÅ´´´µµµÐÐÐäääèèèäääÕÕÕÔÔÔÔÔÔ×××ÙÙÙÌÌÌÃÃÃÇÇÇÐÐÐÛÛÛãããâââÛÛÛÒÒÒÔÔÔÔÔÔÔÔÔÔÔÔ×××ÝÝÝÝÝÝ×××ÎÎÎÊÊÊÂÂÂÅÅÅÐÐÐÐÐÐÆÆÆÃÃúºº¾¾¾ÍÍÍÙÙÙÙÙÙÜÜÜßßßÜÜÜÔÔÔÐÐÐàààÝÝÝßßßÛÛÛ×××···ÀÀÀÆÆÆÅÅż¼¼µµµµµµ»»»¾¾¾¾¾¾±±±±±±µµµ­­­©©©´´´¿¿¿ÃÃÃÃÃÃÆÆÆÉÉÉÉÉÉÃÃü¼¼···ÆÆÆÆÆÆÇÇÇÊÊÊÍÍÍÊÊÊ¿¿¿´´´¿¿¿ÃÃÃÇÇÇÉÉÉÉÉÉÇÇÇÇÇÇÇÇÇÅÅÅÃÃÃÊÊÊÐÐÐÒÒÒ···¾¾¾¼¼¼¸¸¸ÆÆÆÊÊÊÌÌÌÇÇÇÃÃÃÌÌÌÊÊÊÎÎÎÍÍÍÌÌÌÉÉÉÉÉÉÃÃ÷··ªªª¯¯¯¤¤¤¨¨¨¾¾¾ÍÍÍÅÅÅ···°°°»»»ÌÌÌÀÀÀ¼¼¼ººº¯¯¯···³³³¬¬¬³³³­­­±±±¿¿¿ÉÉÉÐÐÐÌÌÌÝÝÝÍÍÍÊÊÊÀÀÀ»»»ÂÂÂÂÂÂÂÂÂÆÆÆÇÇÇÝÝÝÕÕÕÐÐÐÅÅÅÉÉÉÇÇǾ¾¾»»»¸¸¸¸¸¸¸¸¸···´´´±±±µµµ´´´­­­ªªªºººÎÎÎÕÕÕÍÍͱ±±³³³¸¸¸ÂÂÂÆÆÆÇÇÇÇÇÇÉÉɾ¾¾Â¿¿¿ÍÍÍÌÌÌ···¼¼¼ºººÇÇÇÑÑÑÒÒÒÊÊÊÆÆƸ¸¸´´´¸¸¸¾¾¾ºººººº¸¸¸¸¸¸ÃÃÃÃÃÃÃÃÃÃÃÃÊÊÊÕÕÕÔÔÔÃÃó³³­­­¼¼¼ÅÅż¼¼±±±ÂÂÂÅÅÅ»»»¼¼¼¼¼¼¾¾¾¾¾¾¿¿¿ÀÀÀÀÀÀÀÀÀ¿¿¿ÂÂÂÂÂÂÃÃÃÇÇÇÎÎÎÔÔÔÔÔÔÑÑÑÔÔÔÐÐÐÊÊÊÉÉÉÆÆÆÆÆÆÐÐÐàààÒÒÒÂÂÂÅÅÅÀÀÀººº´´´¿¿¿ÕÕÕÅÅÅÂÂÂÆÆƺºº­­­ºººÎÎÎÝÝÝêêêäääßßßØØØÒÒÒÛÛÛÛÛÛàààßßßÝÝÝÝÝÝßßßÝÝÝÙÙÙÕÕÕÛÛÛÜÜÜßßßØØØÔÔÔÙÙÙÛÛÛÒÒÒÕÕÕÒÒÒÅÅÅÂÂÂÑÑÑÔÔÔÌÌÌÊÊÊÆÆÆÅÅÅÐÐÐÜÜÜÝÝÝÜÜÜÜÜÜ×××ÑÑÑÕÕÕâââÙÙÙßßßÛÛÛÔÔÔ¸¸¸ÀÀÀÅÅÅÆÆÆ¿¿¿¸¸¸···»»»¿¿¿ÅÅŵµµ¯¯¯¯¯¯ªªª­­­¸¸¸¾¾¾ÂÂÂÅÅÅÇÇÇÊÊÊÅÅż¼¼¸¸¸¸¸¸ÊÊÊÇÇÇÃÃÃÃÃÃÉÉÉÍÍÍÆÆƼ¼¼ººº¾¾¾ÃÃÃÆÆÆÆÆÆÅÅÅÅÅÅÅÅÅÀÀÀÆÆÆÎÎÎÎÎÎÎÎη··¿¿¿¾¾¾¼¼¼ÃÃÃÂÂÂÊÊÊÊÊÊÃÃÃÊÊÊÉÉÉÉÉÉÇÇÇÃÃÃÃÃÃÉÉÉÎÎÎÌÌÌÅÅž¾¾¬¬¬¢¢¢­­­ÀÀÀÉÉÉÇÇÇÅÅÅÃÃÃÍÍÍ´´´¯¯¯¯¯¯¨¨¨´´´°°°©©©´´´©©©±±±ÂÂÂÂÂÂÀÀÀ¾¾¾ÉÉÉÊÊÊÐÐо¾¾µµµÇÇÇÍÍÍÊÊÊÊÊÊÎÎÎÜÜÜÛÛÛÕÕÕÃÃÃÊÊÊ¿¿¿»»»ººº¸¸¸¸¸¸······µµµ³³³­­­­­­¬¬¬±±±ÃÃÃÕÕÕØØØÑÑѼ¼¼¸¸¸»»»ÂÂÂÅÅÅÀÀÀ»»»ººº¿¿¿ÀÀÀÀÀÀ¿¿¿ÉÉÉÇÇÇ´´´µµµ°°°µµµÅÅÅÔÔÔÎÎξ¾¾µµµ¸¸¸»»»ººº¯¯¯³³³µµµ±±±µµµ­­­³³³´´´»»»ÅÅÅÉÉÉÃÃø¸¸°°°¸¸¸¿¿¿ÃÃñ±±»»»ÂÂÂÇÇÇ¿¿¿¾¾¾¾¾¾¿¿¿¿¿¿ÀÀÀÀÀÀÀÀÀ¿¿¿ÅÅÅÉÉÉÊÊÊÎÎÎÔÔÔÕÕÕÑÑÑ¿¿¿ÀÀÀÀÀÀÅÅÅÊÊÊÉÉÉÐÐÐßßßÉÉɾ¾¾¾¾¾¾¾¾¾¾¾»»»ÅÅÅÍÍÍÎÎÎÉÉÉÃÃÃÃÃÃÀÀÀ¸¸¸···Â´´´ÕÕÕàààäääâââÔÔÔÔÔÔØØØÜÜÜÙÙÙ××××××ÛÛÛâââçççëëëßßßâââçççâââÙÙÙÜÜÜÛÛÛÎÎÎØØØØØØÑÑÑÉÉÉÍÍÍÔÔÔÔÔÔÐÐÐÇÇÇÀÀÀÇÇÇØØØßßßäääæææàààØØØÝÝÝãããÙÙÙâââ×××ÎÎÎÀÀÀÆÆƼ¼¼ººº¸¸¸ººº¼¼¼¿¿¿ÀÀÀ¸¸¸¸¸¸¸¸¸´´´···»»»¸¸¸¼¼¼¿¿¿ÅÅÅÅÅż¼¼µµµ¸¸¸ÂÂÂÆÆÆÉÉÉÉÉÉÉÉÉÍÍÍÎÎÎÃÃô´´···»»»ÀÀÀ¿¿¿¾¾¾¼¼¼ÀÀÀÌÌÌÔÔÔÍÍÍÊÊʺººÅÅÅÀÀÀÀÀÀÀÀÀ»»»ÉÉÉÎÎÎÆÆÆÉÉÉÅÅÅÇÇÇÇÇÇÃÃû»»»»»ÃÃÃÊÊÊÍÍÍÆÆƺºº¬¬¬¦¦¦¬¬¬³³³³³³°°°µµµ¿¿¿­­­···¼¼¼­­­¬¬¬žžžÉÉÉÛÛÛÎÎÎÐÐÐØØØÇÇÇÀÀÀÂÂÂÀÀÀÔÔÔâââÆÆƸ¸¸ÑÑÑÙÙÙÑÑÑóóóèèèÜÜÜÒÒÒÐÐп¿¿ÌÌ̺ºº¸¸¸¸¸¸¸¸¸············µµµ³³³©©©¤¤¤­­­ÆÆÆÛÛÛÛÛÛÑÑÑ°°°­­­°°°¼¼¼ÆÆÆÆÆÆÂÂÂÂÂÂÀÀÀ¿¿¿ÀÀÀ¿¿¿ÅÅÅÃÃð°°¯¯¯¸¸¸­­­···ÔÔÔØØØÀÀÀµµµ¸¸¸´´´´´´°°°ÅÅÅÒÒÒÍÍÍÅÅű±±···ºººººº»»»ÃÃÃÌÌÌÉÉÉ¿¿¿³³³¼¼¼ÉÉÉ´´´···¾¾¾ÉÉÉ¿¿¿¿¿¿¿¿¿ÀÀÀÀÀÀÀÀÀÂÂÂÂÂÂÂÂÂÊÊÊÐÐÐÑÑÑÒÒÒÕÕÕÑÑÑÊÊÊÃÃÃÀÀÀÅÅÅÍÍÍÊÊÊÂÂÂÂÂÂÍÍ͵µµºººÃÃõµµ···ºººÎÎÎÐÐÐÂÂÂÐÐÐÌÌÌÂÂÂÅÅÅÆÆÆÂÂÂÃÃúººÀÀÀ°°°ºººÛÛÛâââÛÛÛÔÔÔÙÙÙÛÛÛÝÝÝßßßÝÝÝÛÛÛØØØ×××ÝÝÝÝÝÝâââàààßßßêêêíííÝÝÝ×××ÙÙÙÛÛÛÑÑÑÇÇÇÑÑÑÛÛÛÒÒÒÑÑÑÃÃÃÆÆÆÔÔÔÜÜÜââââââÛÛÛÛÛÛÝÝÝÝÝÝÔÔÔßßßÌÌÌÃÃÃÂÂÂÌÌÌÀÀÀ´´´±±±···¼¼¼¿¿¿¾¾¾¸¸¸µµµ¸¸¸¸¸¸±±±´´´¸¸¸³³³µµµ»»»ÀÀÀ¿¿¿µµµ±±±»»»ÊÊÊÃÃÃÂÂÂÀÀÀÃÃÃÇÇÇÌÌÌÍÍÍÍÍÍÇÇÇ»»»ººº¾¾¾ÀÀÀÀÀÀ¿¿¿ÎÎÎÌÌÌÍÍÍÐÐÐÊÊÊÀÀÀ¿¿¿ÅÅÅÃÃÃÂÂÂÂÂÂÅÅÅÉÉÉÊÊÊÉÉÉÆÆƸ¸¸¿¿¿ºººººº¾¾¾»»»ÌÌÌÌÌ̺ºº¨¨¨¥¥¥¦¦¦¨¨¨©©©­­­³³³­­­¯¯¯µµµ±±±©©©°°°Â»»»ÃÃÃÅÅž¾¾ÃÃÃÉÉÉÃÃÃÂÂÂÊÊÊÉÉÉÙÙÙÎÎÎÒÒÒãããÔÔÔÕÕÕÜÜÜÛÛÛØØØÒÒÒÍÍÍÇÇǾ¾¾¸¸¸······´´´³³³³³³´´´µµµ¥¥¥¢¢¢³³³ÊÊÊÒÒÒ××××××ÐÐÐ¥¥¥°°°ººº¾¾¾ÂÂÂÇÇÇÆÆÆ¿¿¿ÀÀÀ¾¾¾¿¿¿ÀÀÀÂÂÂÉÉÉÇÇÇ»»»­­­¬¬¬¼¼¼××××××¾¾¾°°°···³³³´´´±±±ÃÃÃßßßÛÛÛÉÉÉÊÊʵµµ······±±±»»»Â¾¾¾ÍÍÍÆÆƱ±±ºººÇÇÇÌÌ̾¾¾³³³ÇÇÇÅÅÅ¿¿¿ÀÀÀÃÃÃÃÃÃÃÃÃÃÃÃÊÊÊÊÊÊÎÎÎÔÔÔÒÒÒÌÌÌÇÇÇÉÉÉÌÌÌÔÔÔÎÎÎÂÂÂÀÀÀÍÍÍÐÐÐÇÇǼ¼¼¿¿¿±±±¸¸¸ÌÌÌÑÑÑÑÑÑÊÊÊÊÊÊÊÊÊÉÉÉÆÆÆÅÅÅÅÅÅÅÅÅÆÆÆÍÍÍÊÊÊ¿¿¿ÃÃü¼¼···×××îîîÔÔÔØØØ×××ØØØ×××ÝÝÝèèèÛÛÛñññííííííúúúñññàààçççààààààæææÝÝÝÙÙÙÜÜÜÍÍÍÂÂÂÑÑÑØØØÔÔÔÀÀÀÂÂÂÝÝÝäääÙÙÙÝÝÝÑÑÑÙÙÙàààÙÙÙÊÊÊÀÀÀÂÂÂÇÇÇ¿¿¿ÇÇDZ±±¸¸¸Â¼¼¼ÅÅÅ»»»ÀÀÀ¼¼¼¸¸¸ººº¸¸¸±±±±±±»»»ºººÂÂÂÊÊÊ···µµµÊÊÊÍÍÍÍÍÍÅÅÅ¿¿¿ÂÂÂÆÆÆÊÊÊÊÊÊÊÊÊÉÉÉÃÃþ¾¾ººº»»»¼¼¼»»»ºººÌÌÌÎÎÎÑÑÑÎÎÎÅÅž¾¾ÀÀÀÆÆÆÅÅÅÃÃÃÂÂÂÂÂÂÃÃÃÅÅÅÅÅÅÃÃû»»···»»»ººº»»»¾¾¾¿¿¿ÉÉÉÀÀÀ¸¸¸­­­©©©¨¨¨¤¤¤¡¡¡¡¡¡¢¢¢©©©°°°³³³±±±³³³¸¸¸¿¿¿ÂÂÂ×××ÙÙÙÇÇÇÀÀÀÂÂÂÂÂÂÅÅÅÆÆÆÌÌÌÜÜÜÍÍÍÐÐÐæææÝÝÝßßßÛÛÛÙÙÙ×××ÒÒÒÌÌÌÆÆÆÀÀÀ¾¾¾´´´±±±±±±µµµ¸¸¸µµµ°°°ªªªµµµ±±±¿¿¿ÐÐÐÔÔÔ××××××ÒÒÒ¯¯¯°°°···¾¾¾¾¾¾ººº···¸¸¸¾¾¾»»»¿¿¿ÀÀÀÀÀÀÆÆÆÇÇǼ¼¼³³³±±±ºººÆÆÆÉÉÉÀÀÀ¸¸¸¸¸¸´´´ººº´´´¾¾¾ÛÛÛâââÑÑÑÉÉÉ´´´³³³´´´¬¬¬¬¬¬±±±°°°¾¾¾¾¾¾Â¿¿¿´´´¼¼¼ÆÆÆ¿¿¿ÌÌÌÍÍÍÇÇÇÀÀÀ¾¾¾ÃÃÃÇÇÇÇÇÇÃÃÃÃÃÃÇÇÇÎÎÎÑÑÑÌÌÌÂÂÂÀÀÀÅÅÅÑÑÑÊÊÊÂÂÂÀÀÀÍÍÍÕÕÕÎÎο¿¿»»»¼¼¼···ÊÊÊÜÜÜÕÕÕÎÎÎÌÌÌÎÎÎÊÊÊÊÊÊÍÍÍÍÍÍÊÊÊÌÌÌÐÐÐÉÉÉÉÉÉÂÂÂÌÌÌÍÍ;¾¾³³³æææßßßÙÙÙàààÛÛÛÙÙÙææææææíííêêêâââïïïöööíííïïïïïïãããæææãããßßßÙÙÙ×××ÐÐÐÉÉÉÕÕÕØØØÌÌÌÃÃÃÒÒÒÜÜÜÜÜÜßßßÜÜÜÙÙÙÔÔÔÊÊÊÃÃÃÀÀÀÃÃÃÇÇÇÉÉÉÇÇǪªª¯¯¯»»»¸¸¸Â¼¼¼¾¾¾»»»»»»···­­­©©©­­­³³³¸¸¸¾¾¾Âµµµ»»»ÉÉÉÃÃÃÂÂÂÅÅÅÀÀÀ¼¼¼¿¿¿ÅÅÅÊÊÊÌÌÌÌÌÌÌÌÌÉÉÉÃÃÿ¿¿¼¼¼»»»ººººººÌÌÌÒÒÒÔÔÔÊÊʾ¾¾»»»ÂÂÂÇÇÇÅÅÅÅÅÅÃÃÃÀÀÀ¿¿¿¾¾¾¿¿¿Âººº¾¾¾»»»¾¾¾¼¼¼¿¿¿ÉÉÉÆÆƾ¾¾¼¼¼ºººµµµ±±±¯¯¯©©©¢¢¢¤¤¤¯¯¯±±±ªªª¬¬¬ºººÅÅÅÇÇǸ¸¸ÑÑÑÒÒÒ¼¼¼ÃÃÃÍÍÍÔÔÔ¿¿¿ÎÎÎããã××××××èèèßßßØØØÛÛÛÙÙÙ×××ÑÑÑÌÌÌÆÆÆ¿¿¿´´´¯¯¯¯¯¯´´´···³³³°°°¯¯¯ÊÊÊÇÇÇÐÐÐØØØØØØØØØØØØÕÕÕÉÉɺºº´´´¿¿¿ÃÃúººµµµººº¸¸¸¸¸¸¾¾¾ÀÀÀ¿¿¿ÃÃÃÇÇÇÀÀÀººº³³³±±±ºººÀÀÀ¿¿¿¼¼¼ººº···ÀÀÀººº¸¸¸ÑÑÑààà×××ÊÊÊÆÆÆÂÂÂÉÉɼ¼¼­­­°°°±±±···ºººÇÇÇÍÍͺºº¸¸¸ÅÅÅÀÀÀ¼¼¼ÇÇÇÍÍÍÍÍÍÇÇÇÃÃÃÇÇÇÊÊÊÊÊÊÉÉÉÎÎÎÕÕÕÔÔÔÉÉɾ¾¾ÀÀÀÊÊÊÑÑѾ¾¾ºººÅÅÅÙÙÙÔÔÔÇÇÇ»»»ººº¸¸¸»»»ÙÙÙæææÒÒÒÌÌÌÎÎÎÐÐÐÊÊÊÉÉÉÌÌÌÌÌÌÉÉÉÊÊÊÎÎÎÑÑÑÑÑÑÇÇÇÉÉÉÐÐÐÒÒÒÑÑÑÅÅÅÉÉÉÀÀÀ¸¸¸¾¾¾»»»¼¼¼ÒÒÒÜÜÜäääãããÐÐÐÆÆÆÃÃþ¾¾ÎÎÎçççÝÝÝëëëîîîæææØØØÝÝÝØØØÍÍÍÒÒÒÛÛÛ×××ÉÉÉÆÆÆÒÒÒÛÛÛÛÛÛÜÜÜÑÑÑÆÆÆÀÀÀÂÂÂÆÆÆÇÇÇÇÇÇÉÉÉÅÅŪªª¯¯¯µµµ­­­···»»»ººº¸¸¸¿¿¿¾¾¾´´´¼¼¼ÆÆÆ´´´···ººº¸¸¸ÆÆÆÎÎÎÅÅÅÆÆÆÆÆÆÀÀÀ»»»»»»ÀÀÀÉÉÉÍÍÍÐÐÐÎÎÎÎÎÎÌÌÌÇÇÇÃÃÃÀÀÀÂÂÂÃÃÃÎÎÎÒÒÒÐÐÐÃÃû»»¾¾¾ÃÃÃÅÅÅÃÃÃÃÃÃÅÅÅ¿¿¿¾¾¾¿¿¿ÀÀÀ¿¿¿ÇÇǾ¾¾ÀÀÀ¿¿¿¿¿¿ÑÑÑÅÅž¾¾¾¾¾¸¸¸´´´µµµººº´´´©©©¢¢¢­­­°°°©©©ªªª···¿¿¿¿¿¿¿¿¿ÍÍÍÇÇÇÃÃÃÆÆÆÆÆÆÉÉÉÆÆÆ×××ÝÝÝëëëãããäääîîîâââÛÛÛÜÜÜÛÛÛ×××ÒÒÒÍÍÍÉÉÉÅÅÅÃÃø¸¸···´´´±±±­­­¯¯¯»»»ÉÉÉØØØØØØÜÜÜßßßÝÝÝÛÛÛÙÙÙØØØÕÕÕ»»»ªªª°°°¸¸¸···³³³³³³´´´µµµ¼¼¼ÀÀÀ¾¾¾ÂÂÂÆÆÆÃÃÃÃÃ󳳬¬¬···¿¿¿»»»ººº¾¾¾¼¼¼ÅÅż¼¼´´´ÃÃÃÒÒÒÔÔÔÑÑÑÉÉÉÅÅÅÒÒÒÇÇÇ­­­¬¬¬­­­©©©³³³°°°ÅÅÅÍÍÍÀÀÀÂÂÂÇÇÇÀÀÀ¾¾¾ÊÊÊÑÑÑÎÎÎÌÌÌÎÎÎÐÐÐÍÍÍÔÔÔÔÔÔÔÔÔÐÐÐÆÆÆ¿¿¿ÆÆÆÐÐÐÊÊʸ¸¸¿¿¿ÐÐÐÝÝÝÇÇǾ¾¾¼¼¼¸¸¸ººº¿¿¿ÙÙÙàààÎÎÎÎÎÎÑÑÑÍÍÍÌÌÌÉÉÉÇÇÇÉÉÉÍÍÍÐÐÐÐÐÐÕÕÕÍÍÍ¿¿¿»»»ÀÀÀÊÊÊÑÑÑÐÐÐÊÊÊÎÎÎÊÊÊÊÊÊÃÃþ¾¾ÉÉÉÊÊÊ¿¿¿ÃÃÃÅÅÅÌÌÌÒÒÒÎÎÎÐÐÐÙÙÙÒÒÒòòòøøøîîîÝÝÝÜÜÜÕÕÕÛÛÛÒÒÒÕÕÕÙÙÙÒÒÒÆÆÆÌÌÌÔÔÔÑÑÑÌÌÌÆÆÆÀÀÀÃÃÃÊÊÊÎÎÎÌÌÌÇÇÇÆÆÆÊÊÊÀÀÀÅÅÅ¿¿¿¬¬¬±±±¼¼¼¿¿¿»»»ÀÀÀ¾¾¾´´´ÂÂÂÍÍ;¾¾ÃÃÃÆÆÆÂÂÂÅÅÅÎÎÎÉÉÉ¿¿¿ÆÆÆÎÎÎÉÉÉÀÀÀ¼¼¼¾¾¾ÃÃÃÊÊÊÎÎÎÑÑÑÒÒÒÒÒÒÑÑÑÍÍÍÌÌÌÍÍÍÐÐÐÑÑÑÐÐÐÇÇǾ¾¾»»»ÂÂÂÃÃÿ¿¿¿¿¿ÂÂÂÆÆÆÆÆÆÃÃÃÀÀÀÀÀÀ¿¿¿ÆÆƺººÀÀÀ¾¾¾¿¿¿×××ÆÆƼ¼¼´´´¨¨¨¢¢¢ªªª´´´°°°¥¥¥©©©···ÇÇÇÒÒÒÔÔÔÐÐÐÇÇÇÂÂÂÆÆÆÊÊÊ¿¿¿ÇÇÇÒÒÒÌÌÌÍÍÍÉÉÉßßßÔÔÔÐÐÐÍÍÍÐÐÐÕÕÕÒÒÒÕÕÕÜÜÜÛÛÛØØØÔÔÔÐÐÐÍÍÍÊÊÊÉÉÉ¿¿¿¸¸¸°°°¯¯¯¸¸¸ÌÌÌÜÜÜÜÜÜàààâââââââââßßßÛÛÛÙÙÙÜÜÜÌÌÌ···­­­­­­±±±´´´´´´³³³³³³»»»ÀÀÀ¾¾¾¿¿¿ÆÆÆÅÅÅÊÊÊ»»»°°°³³³¸¸¸¸¸¸¼¼¼ÀÀÀÂÂÂÃÃü¼¼´´´µµµ¼¼¼ÉÉÉØØؾ¾¾¼¼¼ÒÒÒÌÌ̱±±°°°°°°¦¦¦···©©©ºººÑÑÑÆÆƺººÃÃÃÆÆÆÀÀÀÂÂÂÃÃÃÇÇÇÑÑÑØØØÕÕÕÌÌÌØØØÎÎÎÅÅÅÀÀÀ¿¿¿ÀÀÀÉÉÉÑÑÑÉÉɸ¸¸ÆÆÆÕÕÕßßß¿¿¿¸¸¸¼¼¼µµµÀÀÀÊÊÊÛÛÛÛÛÛÐÐÐÔÔÔÒÒÒÌÌÌÑÑÑÐÐÐÉÉÉÍÍÍÙÙÙÜÜÜÔÔÔÃÃþ¾¾ÀÀÀÌÌÌØØØÛÛÛÔÔÔÐÐÐÇÇÇ×××ßßßëëëäääÒÒÒÎÎÎÍÍÍÍÍÍÍÍÍØØØàààßßßßßßààààààÒÒÒêêêñññöööãããßßßÕÕÕàààÕÕÕÌÌÌÔÔÔÛÛÛÐÐÐÊÊÊÌÌÌÆÆÆÂÂÂÃÃÃÆÆÆÍÍÍÑÑÑÑÑÑÍÍÍÉÉÉÀÀÀÇÇÇÅÅÅÉÉɬ¬¬©©©³³³¾¾¾¾¾¾ÇÇÇÀÀÀ±±±¾¾¾ÌÌÌ¿¿¿ÆÆÆÊÊÊÉÉÉÌÌÌÍÍÍÂÂÂÃÃÃÒÒÒÙÙÙÔÔÔÌÌÌÃÃþ¾¾¿¿¿ÅÅÅÉÉÉÑÑÑÒÒÒÕÕÕÕÕÕÒÒÒÑÑÑÑÑÑÒÒÒÐÐÐÊÊÊÀÀÀ»»»¾¾¾ÂÂÂÀÀÀ¼¼¼¾¾¾ÀÀÀÅÅÅÇÇÇÆÆÆÅÅÅ»»»¾¾¾´´´¿¿¿¼¼¼¿¿¿×××ÇÇǾ¾¾°°°¡¡¡¤¤¤ªªª©©©¡¡¡ŸŸŸ©©©¾¾¾ÑÑÑÕÕÕÊÊÊÀÀÀ¾¾¾ÀÀÀÃÃí­­´´´ÂÂÂÉÉÉßßßèèèäääÕÕÕÎÎÎÔÔÔÙÙÙØØØØØØÝÝÝÛÛÛÙÙÙ×××ÔÔÔÑÑÑÎÎÎÎÎÎÍÍÍÉÉÉÆÆÆ»»»³³³ºººÌÌÌÙÙÙÜÜÜÜÜÜââââââàààäääãããßßßÜÜÜààààààÕÕÕ¾¾¾¯¯¯°°°µµµ¸¸¸³³³±±±ºººÂ¾¾¾¿¿¿ÅÅÅÆÆÆÌÌÌÊÊÊ¿¿¿±±±¯¯¯ºººÀÀÀÂÂÂÃÃÿ¿¿ºººµµµ¯¯¯¯¯¯ÀÀÀÛÛÛ¾¾¾¿¿¿ÕÕÕÐÐм¼¼ÂÂÂÀÀÀ···³³³´´´···ÊÊÊÍÍÍ»»»···»»»ÀÀÀ¿¿¿¾¾¾ÀÀÀÆÆÆÍÍÍÒÒÒÔÔÔ×××ÉÉɼ¼¼¼¼¼ÂÂÂÇÇÇÐÐÐ×××ÌÌ̺ººÇÇÇÑÑÑâââÀÀÀ»»»¸¸¸´´´ÉÉÉÙÙÙäääÜÜÜÕÕÕÙÙÙÐÐÐÑÑÑ×××ÕÕÕÍÍÍÎÎÎÔÔÔÐÐÐÃÃúºº»»»ÊÊÊÒÒÒÒÒÒÍÍÍÂÂÂÆÆÆÉÉÉÌÌÌÎÎÎãããàààÅÅÅÃÃÃÐÐÐëëëàààäääÛÛÛÊÊÊÐÐÐÛÛÛäääÛÛÛÙÙÙàààúúúäääçççÜÜÜÛÛÛÙÙÙÊÊÊÐÐÐÝÝÝÙÙÙÐÐÐÉÉÉÂÂÂÅÅÅÉÉÉÍÍÍÐÐÐÐÐÐÍÍÍÊÊÊÉÉÉÇÇÇÅÅÅ¿¿¿ÂÂÂÃÃ÷··­­­±±±´´´¿¿¿ÊÊÊ°°°¸¸¸ÉÉÉÇÇǼ¼¼ÂÂÂÅÅÅÌÌÌÇÇÇÀÀÀÑÑÑàààÛÛÛÙÙÙÕÕÕÌÌÌ¿¿¿ÂÂÂÇÇÇÐÐÐÑÑÑÒÒÒÑÑÑÎÎÎÌÌÌÊÊÊÉÉÉÌÌÌÃÃþ¾¾¾¾¾¿¿¿¾¾¾¼¼¼¼¼¼¿¿¿ÀÀÀÂÂÂÅÅÅÆÆÆÅÅÅÂÂÂÀÀÀ»»»¸¸¸ÇÇÇÂÂÂÂÂÂÒÒÒÅÅŸ¸¸¯¯¯¨¨¨¦¦¦©©©©©©¨¨¨¦¦¦¬¬¬¯¯¯µµµ¿¿¿ÃÃÃÅÅÅÇÇÇÍÍÍÃÃÃÍÍÍ°°°©©©³³³ÂÂÂàààäääÒÒÒÐÐÐÐÐÐ××××××ÑÑÑÒÒÒÕÕÕ×××ÕÕÕÒÒÒÑÑÑÐÐÐÐÐÐÐÐÐÐÐÐÉÉÉÌÌ̵µµ¾¾¾ÕÕÕÝÝÝ×××ÝÝÝãããßßßÛÛÛãããæææâââàààÛÛÛâââÝÝÝÊÊʺººµµµ³³³¯¯¯µµµ±±±¸¸¸Â¿¿¿ÀÀÀÅÅÅÅÅÅÉÉÉÑÑÑÐÐп¿¿´´´¸¸¸¾¾¾¾¾¾¿¿¿ººº···´´´¯¯¯¯¯¯ÀÀÀÕÕÕÃÃÃÂÂÂÎÎÎÅÅźººÂÂÂÀÀÀºººžžž­­­¬¬¬¼¼¼ÎÎÎÇÇÇÃÃÃÀÀÀ¾¾¾¿¿¿Âººº···ÆÆÆØØØÉÉÉÀÀÀ»»»¿¿¿ÇÇÇÍÍÍÔÔÔÙÙÙÌÌ̾¾¾ÊÊÊÍÍÍßßßÅÅÅÀÀÀ¸¸¸´´´ÌÌÌßßßèèèÛÛÛÒÒÒÙÙÙÐÐÐÕÕÕÔÔÔÔÔÔ×××ÔÔÔÊÊʼ¼¼³³³¾¾¾ÇÇÇØØØÑÑÑÌÌÌÐÐÐÑÑÑÝÝÝÆÆÆ¿¿¿ÕÕÕÛÛÛÉÉÉÔÔÔíííÐÐÐÍÍÍÛÛÛßßßäääêêêßßßÛÛÛØØØÑÑÑÕÕÕöööäääëëëÝÝÝ×××ÜÜÜÒÒÒÑÑÑÙÙÙÜÜÜ×××ÎÎÎÆÆÆÇÇÇÊÊÊÎÎÎÐÐÐÎÎÎÌÌÌÉÉÉÆÆÆÎÎÎÌÌÌÅÅÅÃÃÃÊÊÊÇÇÇ¿¿¿ÀÀÀ³³³ººº¾¾¾···¯¯¯³³³»»»¼¼¼ÆÆÆÆÆÆÇÇÇÐÐÐÀÀÀ¼¼¼ÒÒÒØØØÕÕÕÙÙÙÙÙÙÒÒÒÇÇÇÂÂÂÅÅÅÊÊÊÎÎÎÐÐÐÎÎÎÍÍÍÊÊÊÅÅÅ¿¿¿ÆÆÆÀÀÀ¿¿¿ÀÀÀ¿¿¿ºººººº¿¿¿ÂÂÂÀÀÀÀÀÀÀÀÀÃÃÃÃÃÃÀÀÀ¿¿¿ÍÍÍÂÂÂÃÃÃÑÑÑÊÊÊÅÅÅÎÎά¬¬©©©ªªª¯¯¯­­­¨¨¨¨¨¨¬¬¬´´´³³³¯¯¯¯¯¯³³³¼¼¼ÇÇÇÐÐо¾¾ÕÕÕÀÀÀ¸¸¸ÃÃÃÐÐÐßßßÍÍÍÍÍÍÒÒÒÔÔÔÒÒÒÍÍÍÊÊÊÑÑÑÕÕÕÒÒÒÑÑÑÐÐÐÎÎÎÎÎÎÎÎÎÐÐÐÐÐÐÆÆÆÑÑÑÊÊÊ···ºººÑÑÑÝÝÝØØØàààäääÜÜÜØØØâââçççääääääâââãããâââÙÙÙÒÒÒÊÊʼ¼¼¯¯¯···±±±¸¸¸ÂÂÂÀÀÀÀÀÀÅÅÅÅÅÅÅÅÅÐÐÐØØØÒÒÒ···µµµººº¼¼¼···´´´´´´±±±µµµÂÂÂÐÐÐÐÐÐÌÌÌÍÍͼ¼¼´´´¿¿¿¼¼¼¸¸¸¦¦¦¬¬¬¢¢¢¯¯¯¿¿¿ÆÆÆÐÐÐÇÇÇ¿¿¿¼¼¼ÀÀÀÃÃúºº±±±»»»ÎÎεµµ³³³µµµ¾¾¾ÆÆÆÉÉÉÎÎÎÒÒÒÉÉÉ¿¿¿ÐÐÐÊÊÊÜÜÜÃÃÃÆÆƾ¾¾···ÊÊÊÜÜÜæææÕÕÕÊÊÊÕÕÕÒÒÒÑÑÑÌÌÌÒÒÒâââãããÐÐо¾¾»»»ÂÂÂÉÉÉÕÕÕÇÇÇÅÅÅÎÎÎÃÃÿ¿¿ÃÃÃÆÆÆÀÀÀÎÎÎÒÒÒÅÅÅÊÊÊÛÛÛÎÎÎÕÕÕàààÝÝÝââââââÒÒÒÙÙÙÎÎÎÕÕÕÔÔÔïïïãããëëëÙÙÙÛÛÛßßßÛÛÛÕÕÕÕÕÕÙÙÙÛÛÛÔÔÔÍÍÍÅÅÅÇÇÇÌÌÌÐÐÐÑÑÑÎÎÎÉÉÉÅÅż¼¼¿¿¿¿¿¿»»»ÀÀÀ»»»¿¿¿±±±±±±¯¯¯±±±¿¿¿ÊÊÊÌÌÌÊÊÊÉÉÉÅÅÅÇÇÇÒÒÒÂÂÂÂÂÂÜÜÜØØØ×××ÔÔÔÔÔÔÕÕÕÎÎÎÅÅÅÂÂÂÅÅÅÊÊÊÃÃÃÅÅÅÆÆÆÂÂÂÆÆÆÊÊÊÃÃÃÆÆÆÃÃÃÀÀÀ¿¿¿ÀÀÀÂÂÂÀÀÀ¿¿¿¾¾¾¿¿¿ÃÃþ¾¾»»»ÌÌÌÕÕÕÌÌ̺ºº­­­°°°···±±±¬¬¬°°°³³³ªªªªªª©©©©©©ªªª­­­¯¯¯¯¯¯³³³±±±······­­­ÅÅÅÂÂÂÇÇÇàààÙÙÙÑÑÑÐÐÐÔÔÔÕÕÕÒÒÒÍÍÍÔÔÔÔÔÔÒÒÒÒÒÒÒÒÒÒÒÒÒÒÒÒÒÒÒÒÒÒÒÒÑÑÑÐÐÐÎÎÎÎÎÎÎÎÎÐÐÐÌÌÌÐÐÐÍÍÍ¿¿¿»»»ÒÒÒçççÛÛÛææææææâââäääàààâââîîîèèèêêêêêêçççääääääßßßÐÐп¿¿°°°³³³ºººÂÂÂÃÃÃÀÀÀÀÀÀÃÃÃÇÇÇÀÀÀÉÉÉÐÐÐÃÃø¸¸¸¸¸···´´´±±±°°°³³³³³³³³³»»»ÅÅÅÅÅÅÅÅÅÇÇÇÃÃû»»ºººµµµ©©©ŸŸŸ¤¤¤©©©¯¯¯´´´¾¾¾ÇÇÇÎÎÎÆÆƸ¸¸¼¼¼ÅÅž¾¾´´´±±±°°°³³³µµµ´´´ºººÅÅÅÆÆÆÇÇÇÔÔÔÊÊʾ¾¾ÇÇÇÒÒÒàààÌÌÌÃÃþ¾¾ÂÂÂÆÆÆßßßãããÔÔÔÍÍÍÉÉÉÎÎÎÍÍÍ×××ÜÜÜÜÜÜØØØÊÊʾ¾¾¿¿¿ÍÍÍÜÜÜÊÊÊÊÊÊÐÐÐÂÂÂÀÀÀºººÑÑÑÎÎÎÍÍÍÐÐÐÒÒÒÔÔÔÐÐÐÌÌÌÌÌÌâââæææçççÝÝÝÕÕÕÝÝÝÙÙÙÔÔÔÛÛÛÎÎÎÀÀÀèèèàààçççØØØâââàààÕÕÕ¿¿¿ÙÙÙÜÜÜÔÔÔÍÍÍÂÂÂßßßÎÎÎÆÆÆÆÆÆÃÃÃÊÊʸ¸¸¿¿¿¸¸¸···¾¾¾ÃÃÃÃÃÃÃÃÃÅÅÅ©©©¯¯¯°°°ÃÃÃÌÌÌÃÃÃÊÊÊÇÇÇÇÇÇÇÇÇÆÆÆÅÅÅÆÆÆÊÊÊÑÑÑÕÕÕ¿¿¿¾¾¾¾¾¾ÀÀÀÀÀÀ¿¿¿ÂÂÂÆÆÆÉÉÉÃÃÃÇÇÇÌÌÌÇÇÇÇÇÇÇÇÇÀÀÀ¿¿¿ÂÂÂÆÆÆÊÊÊÌÌÌÉÉÉÅÅÅÀÀÀÅÅÅ¿¿¿»»»¾¾¾ÅÅÅÍÍÍÃÃð°°¸¸¸¬¬¬¯¯¯µµµ°°°¬¬¬°°°³³³­­­¬¬¬ªªªªªª¬¬¬­­­¯¯¯°°°¸¸¸···ººº¸¸¸¬¬¬ÃÃÃÇÇÇÐÐÐÝÝÝÝÝÝàààæææèèèäääÙÙÙÑÑÑÕÕÕÕÕÕÕÕÕÔÔÔÔÔÔÒÒÒÑÑÑÑÑÑÒÒÒÒÒÒÑÑÑÐÐÐÐÐÐÐÐÐÐÐÐÑÑÑÌÌÌÌÌÌÊÊÊÀÀÀ¾¾¾ÐÐÐääääääçççãããâââëëëäääàààííííííïïïíííçççààààààâââÛÛÛÒÒÒ¸¸¸±±±°°°¸¸¸¿¿¿¿¿¿¿¿¿ÃÃÃÆÆÆÇÇÇÌÌÌÇÇǼ¼¼»»»¼¼¼···³³³¯¯¯°°°······±±±¬¬¬ªªª¸¸¸···¿¿¿ÀÀÀ´´´©©©¤¤¤¢¢¢¤¤¤¨¨¨¬¬¬­­­³³³ÀÀÀÎÎθ¸¸¼¼¼ÅÅž¾¾µµµ´´´³³³³³³µµµµµµºººÃÃÃÅÅÅÇÇÇÔÔÔÐÐп¿¿ÆÆÆÑÑÑßßßÌÌÌÅÅÅÀÀÀ¼¼¼¾¾¾ÕÕÕßßßÛÛÛÙÙÙÕÕÕ×××ÐÐÐÙÙÙÕÕÕÊÊÊÆÆÆÂÂÂÀÀÀÆÆÆÐÐÐÐÐÐÀÀÀÉÉÉÎÎÎÅÅÅÊÊÊÐÐÐÍÍÍÌÌÌÊÊÊÌÌÌÎÎÎÐÐÐÍÍÍÌÌÌÉÉÉÔÔÔÒÒÒ×××ÕÕÕÕÕÕãããâââçççßßßØØØÌÌÌëëëëëëäääÐÐÐÙÙÙâââÛÛÛÉÉÉßßßàààÔÔÔÉÉÉçççóóóÛÛÛÎÎÎÆÆƺººÃÃÿ¿¿ÌÌÌÀÀÀººº¿¿¿ÉÉÉÌÌÌÉÉÉÆÆÆÆÆÆÊÊÊÅÅÅÉÉÉÆÆÆÀÀÀÊÊÊÊÊÊÊÊÊÍÍÍÐÐÐÐÐÐÌÌÌÇÇÇÅÅÅÅÅÅÊÊÊÉÉÉÅÅÅÀÀÀÃÃÃÉÉÉÍÍÍÎÎÎÊÊÊÆÆÆÇÇÇÉÉÉÆÆÆÅÅÅÃÃü¼¼¿¿¿ÅÅÅÍÍÍÒÒÒÒÒÒÐÐÐÌÌÌÇÇÇÊÊÊÉÉÉÅÅÅÇÇÇÎÎÎÉÉɺºº¯¯¯···­­­¯¯¯´´´±±±­­­°°°³³³±±±°°°¯¯¯¬¬¬¬¬¬­­­±±±³³³ººº······ººº¯¯¯ÅÅÅÍÍÍÙÙÙÜÜÜØØØÔÔÔÒÒÒÕÕÕØØØØØØÙÙÙÙÙÙÙÙÙÙÙÙØØØ×××ÔÔÔÑÑÑÐÐÐÔÔÔÒÒÒÑÑÑÐÐÐÐÐÐÑÑÑÒÒÒÒÒÒÎÎÎÉÉÉÆÆÆÀÀÀººº¿¿¿ÐÐÐàààèèèãããäääñññêêêàààîîîòòòñññïïïèèèããããããææææææãããÑÑÑ¿¿¿´´´ºººÀÀÀ¿¿¿¾¾¾ÀÀÀÆÆÆÍÍÍÎÎÎÀÀÀµµµ¾¾¾ÀÀÀµµµ¸¸¸±±±°°°µµµ»»»¸¸¸±±±¬¬¬¨¨¨¥¥¥°°°···¬¬¬¤¤¤¥¥¥¨¨¨©©©¨¨¨¨¨¨ªªª©©©­­­¼¼¼ÍÍ;¾¾¸¸¸¾¾¾ÃÃþ¾¾···µµµµµµ³³³µµµ···ºººÀÀÀÃÃÃÊÊÊÕÕÕØØØÅÅÅÉÉÉÔÔÔäääÐÐÐÉÉÉÆÆƾ¾¾ºººÌÌÌØØØÝÝÝàààÙÙÙØØØÕÕÕÛÛÛÎÎλ»»µµµ»»»ÂÂÂÌÌÌÝÝÝÑÑÑÀÀÀÇÇÇÍÍÍÀÀÀÆÆÆÙÙÙÇÇÇÇÇÇÇÇÇÇÇÇÊÊÊÌÌÌÌÌÌÌÌÌÑÑÑÔÔÔÐÐÐÕÕÕÕÕÕÑÑÑÕÕÕÕÕÕäääÐÐÐØØØÐÐÐàààòòòæææÙÙÙÜÜÜäääÛÛÛÌÌÌÛÛÛÝÝÝÙÙÙÒÒÒçççëëëÜÜÜÝÝÝÕÕÕÃÃÃÎÎÎÕÕÕÕÕÕÊÊÊÀÀÀÀÀÀÃÃÃÅÅÅÃÃÃÃÃÃÀÀÀÊÊÊÊÊÊÉÉÉÃÃÿ¿¿ÇÇÇÇÇÇÅÅÅÊÊÊÐÐÐÒÒÒÐÐÐÌÌÌÇÇÇÆÆÆÒÒÒÒÒÒÌÌÌÃÃÃÅÅÅÍÍÍÎÎÎÌÌÌÐÐÐÊÊÊÅÅÅÂÂÂÀÀÀÀÀÀÀÀÀ¿¿¿ÉÉÉÌÌÌÐÐÐÑÑÑÐÐÐÐÐÐÑÑÑÑÑÑÍÍÍÐÐÐÌÌÌÍÍÍÑÑÑÅÅŸ¸¸¼¼¼¸¸¸±±±°°°´´´´´´±±±³³³´´´···µµµ±±±¯¯¯­­­°°°³³³···µµµ±±±°°°¼¼¼¸¸¸ÌÌÌÑÑÑÙÙÙÔÔÔÔÔÔÔÔÔÕÕÕÕÕÕ×××ÙÙÙÙÙÙÝÝÝÝÝÝÝÝÝÜÜÜÙÙÙ×××ÒÒÒÐÐÐÔÔÔÑÑÑÐÐÐÐÐÐÑÑÑÒÒÒÒÒÒÑÑÑÊÊÊÂÂÂÂÂÂÀÀÀ»»»···ÃÃÃãããêêêèèèêêêñññèèèãããóóóöööïïïïïïïïïíííêêêèèèçççäääÔÔÔ···¾¾¾Â¾¾¾¼¼¼ÂÂÂÃÃÃÍÍÍÌÌÌ¿¿¿···¼¼¼¾¾¾µµµººº´´´³³³µµµ»»»¼¼¼¸¸¸³³³­­­¨¨¨ªªª¬¬¬¨¨¨¬¬¬µµµ···­­­­­­ªªª©©©¬¬¬µµµÀÀÀÆÆÆ»»»¼¼¼ÀÀÀÃÃþ¾¾¸¸¸µµµµµµ´´´µµµ¸¸¸»»»¿¿¿ÅÅÅÍÍÍÕÕÕÙÙÙÇÇÇÐÐÐÜÜÜëëëÕÕÕÎÎÎÊÊÊÅÅÅ¿¿¿ÊÊÊÑÑÑ×××ØØØÑÑÑÔÔÔÛÛÛÛÛÛÎÎξ¾¾ººº¸¸¸¿¿¿ÌÌÌãããÙÙÙÉÉÉÆÆÆÎÎλ»»×××ÅÅÅÅÅÅÅÅÅÆÆÆÇÇÇÉÉÉÌÌÌÎÎÎÍÍÍÍÍÍÎÎÎ×××ÙÙÙÕÕÕÙÙÙßßßÕÕÕ¾¾¾ÔÔÔÉÉÉÇÇÇããã××××××ÝÝÝàààÕÕÕÑÑÑÛÛÛØØØÛÛÛÜÜÜæææèèèâââæææÜÜÜÊÊÊÔÔÔÜÜÜÕÕÕÒÒÒÌÌÌ···´´´¸¸¸¿¿¿ÂÂÂÉÉÉÇÇÇÀÀÀ¼¼¼¾¾¾Â¿¿¿ÂÂÂÆÆÆÊÊÊÍÍÍÍÍÍÎÎÎÑÑÑÒÒÒÍÍÍÎÎÎÌÌÌÆÆÆÉÉÉÐÐÐÑÑÑÍÍÍÍÍÍÊÊÊÆÆÆÅÅÅÇÇÇÉÉÉÉÉÉÊÊÊÐÐÐÑÑÑÑÑÑÐÐÐÎÎÎÎÎÎÑÑÑÔÔÔÎÎÎÎÎÎÇÇÇÊÊÊÎÎÎÀÀÀ´´´ººººººµµµ³³³µµµ¸¸¸¸¸¸µµµ¸¸¸ººº¸¸¸···³³³°°°±±±···»»»¼¼¼´´´±±±ÉÉÉÊÊÊÕÕÕÒÒÒÑÑÑÎÎÎÒÒÒÙÙÙßßßàààßßßÜÜÜÛÛÛàààààààààßßßÜÜÜØØØÒÒÒÑÑÑÒÒÒÑÑÑÎÎÎÐÐÐÑÑÑÑÑÑÐÐÐÎÎÎÊÊÊÂÂÂÆÆÆÃÃÿ¿¿µµµ»»»ãããëëëòòòñññïïïçççêêêúúúöööñññòòòòòòòòòîîîçççãããâââ»»»´´´´´´¼¼¼ÀÀÀ¼¼¼¾¾¾ÅÅÅÂÂÂÆÆÆÇÇÇÅÅÅ¿¿¿ººº···¸¸¸´´´µµµ¸¸¸ººº»»»ººº´´´¯¯¯³³³¯¯¯¬¬¬©©©¯¯¯ÂÂÂÌÌ̬¬¬­­­¨¨¨¥¥¥±±±ÂÂÂÃÃø¸¸¸¸¸ÀÀÀÅÅż¼¼¸¸¸´´´´´´´´´···ººº¼¼¼¿¿¿ÇÇÇÐÐÐÒÒÒÑÑÑÇÇÇÔÔÔßßßêêêÔÔÔÍÍÍÉÉÉÂÂÂÂÂÂÌÌÌÍÍÍÍÍÍÍÍÍÊÊÊÕÕÕÜÜÜÜÜÜÕÕÕÐÐÐÌÌÌ¿¿¿»»»ÅÅÅÑÑÑÙÙÙÑÑÑÃÃÃÑÑÑÌÌ̺ººØØØÅÅÅÅÅÅÆÆÆÆÆÆÇÇÇÊÊÊÍÍÍÎÎÎÔÔÔÐÐÐÑÑÑÑÑÑÎÎÎÐÐÐÙÙÙèèèÑÑÑ¿¿¿ÛÛÛ×××ÜÜÜöööêêêîîî××××××ÎÎÎßßßãããÕÕÕØØØßßßííííííæææãããØØØÒÒÒÜÜÜàààØØØÙÙÙÕÕÕÉÉɼ¼¼¸¸¸¼¼¼ÃÃÃÇÇÇÃÃÿ¿¿···¼¼¼ÊÊÊÎÎÎÎÎÎÇÇÇÉÉÉÊÊÊÌÌÌÊÊÊÌÌÌÐÐÐÑÑÑÑÑÑÒÒÒÒÒÒÑÑÑÒÒÒÔÔÔÒÒÒÐÐÐÆÆÆÌÌÌÍÍÍÑÑÑØØØØØØÔÔÔÕÕÕÒÒÒÒÒÒÒÒÒÒÒÒÐÐÐÎÎÎÎÎÎÐÐÐÐÐÐÑÑÑÒÒÒÐÐÐÉÉÉ»»»µµµ»»»»»»ºººµµµµµµ¼¼¼¼¼¼¸¸¸»»»ººº»»»ººº···´´´µµµººº¿¿¿ÆÆƾ¾¾¸¸¸×××ØØØÙÙÙÒÒÒÊÊÊÐÐÐÑÑÑÑÑÑÒÒÒÕÕÕÙÙÙÝÝÝßßßààààààßßßÝÝÝÙÙÙÕÕÕÒÒÒÐÐÐÑÑÑÎÎÎÎÎÎÐÐÐÑÑÑÐÐÐÌÌÌÇÇǾ¾¾¼¼¼Â»»»¼¼¼¸¸¸¸¸¸æææîîîøøøöööñññèèèïïïÿÿÿõõõõõõóóóòòòòòòíííæææââââââ³³³µµµ¼¼¼Â¿¿¿ÀÀÀÅÅÅÀÀÀÃÃÃÆÆÆÌÌÌÊÊÊ»»»µµµ¼¼¼ººº»»»»»»»»»¼¼¼ÂÂÂÃÃü¼¼»»»¸¸¸³³³ºººÍÍÍÎÎκºº©©©¨¨¨¢¢¢¥¥¥µµµÆÆÆÀÀÀ¯¯¯µµµÃÃÃÉÉɼ¼¼¸¸¸´´´´´´······»»»¿¿¿ÂÂÂÌÌÌÒÒÒÐÐÐÉÉÉÉÉÉØØØØØØÝÝÝÊÊÊÇÇÇÃÃþ¾¾ÃÃÃÐÐÐÎÎÎÌÌÌÉÉÉÇÇÇÙÙÙÙÙÙÝÝÝÜÜÜÜÜÜÛÛÛÌÌ̾¾¾¼¼¼ÂÂÂÒÒÒÙÙÙÃÃÃÎÎÎÐÐз··ÔÔÔÆÆÆÅÅÅÆÆÆÇÇÇÊÊÊÌÌÌÍÍÍÍÍÍÆÆÆÆÆÆÐÐÐÎÎÎÍÍÍÒÒÒØØØæææÎÎÎÂÂÂÍÍÍÉÉÉÝÝÝäääÒÒÒÎÎÎ×××ÕÕÕÇÇÇßßßßßßÔÔÔÝÝÝèèèæææææææææäääßßßàààãããÝÝÝÛÛÛÛÛÛØØØÒÒÒÐÐÐÐÐÐÐÐÐÍÍ͸¸¸´´´ººº¼¼¼ÉÉÉ×××ÔÔÔÒÒÒÆÆÆÉÉÉÍÍÍÍÍÍÍÍÍÌÌÌÌÌÌÍÍÍÒÒÒÑÑÑÒÒÒÔÔÔÑÑÑÌÌÌÉÉÉÉÉÉÉÉÉÐÐÐÑÑÑÕÕÕÝÝÝÜÜÜÕÕÕÕÕÕÕÕÕÔÔÔÒÒÒÑÑÑÑÑÑÑÑÑÐÐÐÐÐÐÔÔÔÔÔÔÕÕÕÎÎο¿¿···¼¼¼ÀÀÀººº»»»´´´´´´¼¼¼¾¾¾ººº»»»ººº»»»¼¼¼»»»¸¸¸¸¸¸¼¼¼ÂÂÂÅÅÅ¿¿¿»»»ÛÛÛØØØÔÔÔÑÑÑÍÍÍÎÎÎÐÐÐÒÒÒÕÕÕÙÙÙÜÜÜÝÝÝÝÝÝÝÝÝÜÜÜÛÛÛØØØÕÕÕÑÑÑÐÐÐÎÎÎÎÎÎÍÍÍÍÍÍÐÐÐÑÑÑÎÎÎÇÇÇÀÀÀººº¾¾¾Â´´´¼¼¼ÂÂÂÂÂÂñññòòòøøøøøøøøøñññòòòüüüòòòóóóññññññóóóñññêêêäääää人ºÀÀÀÅÅÅÅÅÅÅÅÅÅÅÅÃÃÃÂÂÂÀÀÀÆÆÆÊÊÊÑÑÑÑÑѺººÂÂÂÅÅÅÀÀÀ»»»ºººÂÂÂÐÐÐÕÕÕÒÒÒÐÐÐÍÍÍÊÊÊÅÅÅÂÂÂÉÉÉÃÃð°°­­­¥¥¥¢¢¢¬¬¬¼¼¼Âººº°°°°°°ÅÅÅÊÊÊÀÀÀ¼¼¼ºººµµµµµµ¸¸¸···¼¼¼ÀÀÀÅÅÅÐÐÐÕÕÕÍÍÍÌÌÌÔÔÔßßßÒÒÒÎÎÎÀÀÀÆÆÆÅÅÅÇÇÇÐÐÐÛÛÛ×××ÑÑÑÉÉÉÂÂÂÒÒÒÕÕÕâââàààÙÙÙÛÛÛ×××ÆÆƸ¸¸ÀÀÀÇÇÇÝÝÝÉÉÉÆÆÆÌÌ̸¸¸ÐÐÐÆÆÆÅÅÅÅÅÅÇÇÇÌÌÌÍÍÍÌÌÌÊÊÊÉÉÉÌÌÌ×××ÑÑÑÐÐÐÔÔÔÌÌÌÎÎÎÑÑÑÎÎÎÃÃû»»ãããÙÙÙÒÒÒÒÒÒØØØÙÙÙÆÆÆÙÙÙØØØÙÙÙêêêñññëëëãããäääæææàààÝÝÝ×××ÌÌÌÑÑÑÕÕÕØØØ××××××ÙÙÙ×××ÑÑÑ´´´³³³ÅÅÅÍÍÍÒÒÒÐÐп¿¿¼¼¼ÅÅÅÇÇÇÌÌÌÍÍÍÍÍÍÌÌÌÌÌÌÍÍÍÑÑÑÐÐÐÒÒÒÕÕÕÒÒÒÊÊÊÉÉÉÎÎÎÑÑÑÕÕÕÑÑÑÑÑÑØØØÕÕÕÎÎÎÑÑÑÛÛÛÕÕÕÐÐÐÎÎÎÐÐÐÒÒÒÔÔÔÔÔÔÛÛÛÊÊʺºº³³³ºººÀÀÀ»»»¸¸¸»»»´´´³³³¼¼¼¾¾¾¸¸¸ººº¸¸¸¼¼¼¾¾¾¼¼¼ºººººº¿¿¿ÃÃû»»ººº···ØØØÑÑÑÌÌÌÐÐÐÒÒÒÊÊÊÌÌÌÎÎÎÒÒÒ×××ÙÙÙÙÙÙØØØÛÛÛÙÙÙ×××ÔÔÔÐÐÐÎÎÎÍÍÍÌÌÌÍÍÍÌÌÌÌÌÌÎÎÎÑÑÑÍÍÍÅÅż¼¼ßßßâââÜÜÜ¿¿¿ÂÂÂÅÅž¾¾èèèõõõööööööÿÿÿøøøòòòùùùñññíííëëëïïïøøøøøøïïïæææããã···¾¾¾¿¿¿¾¾¾ÀÀÀÇÇÇÇÇÇÀÀÀÀÀÀÊÊÊÎÎÎÒÒÒÔÔÔÇÇÇ¿¿¿ÆÆÆÆÆƼ¼¼¾¾¾ÉÉÉÒÒÒÎÎÎÃÃÃÆÆÆÃÃÃÇÇÇÌÌÌÌÌÌÑÑÑÒÒÒÊÊÊ´´´¦¦¦¥¥¥···Â¾¾¾···¸¸¸¬¬¬ÃÃÃÊÊÊÀÀÀ¾¾¾»»»¸¸¸¸¸¸ººº···¼¼¼ÂÂÂÇÇÇÒÒÒ×××ÌÌÌÕÕÕßßßçççÐÐÐÆÆƼ¼¼ÉÉÉÉÉÉ×××ÝÝÝçççààà×××ÉÉɺººÆÆÆÒÒÒäääàààÐÐÐÕÕÕÝÝÝÎÎθ¸¸¾¾¾ºººÜÜÜÍÍ;¾¾ÉÉɾ¾¾ÔÔÔÆÆÆÃÃÃÃÃÃÆÆÆÌÌÌÍÍÍÊÊÊÆÆÆÊÊÊÇÇÇÐÐÐÉÉÉÐÐÐÝÝÝ×××ØØØßßßçççÊÊÊ···ãããÎÎÎ×××âââÐÐÐÜÜÜÊÊÊÝÝÝÛÛÛãããñññëëëñññÜÜÜØØØÙÙÙ××××××ÒÒÒÌÌÌÂÂÂÎÎÎØØØ×××ÑÑÑÑÑÑÐÐÐÎÎδ´´´´´ÊÊÊÔÔÔÔÔÔÎÎξ¾¾ÀÀÀÌÌÌÌÌÌÌÌÌÊÊÊÇÇÇÇÇÇÉÉÉÌÌÌÐÐÐÊÊÊÑÑÑÕÕÕÌÌÌÉÉÉÒÒÒØØØÕÕÕÑÑÑÌÌÌÉÉÉÊÊÊÍÍÍÐÐÐÑÑÑÕÕÕÕÕÕÔÔÔÔÔÔÔÔÔÕÕÕØØØØØØÌÌÌ»»»···ººº¸¸¸»»»¼¼¼µµµ´´´´´´µµµ¸¸¸»»»¼¼¼¸¸¸µµµ»»»¼¼¼¾¾¾¿¿¿¿¿¿¿¿¿ÃÃÃÇÇǼ¼¼ºººÍÍÍãããÔÔÔÔÔÔÊÊÊÒÒÒÕÕÕÎÎÎÑÑÑØØØÙÙÙßßßãããÜÜÜÕÕÕÔÔÔÑÑÑÍÍÍÍÍÍÍÍÍÊÊÊÇÇÇÌÌÌÊÊÊÉÉÉÌÌÌÑÑÑÒÒÒÊÊʾ¾¾âââäääâââæææçççíííóóóãããóóóõõõîîîèèèñññóóóïïïïïïêêêïïïöööüüüÿÿÿùùùñññêêêäää¾¾¾ÅÅÅÃÃÃÃÃÃÐÐÐÆÆÆÅÅÅÆÆÆÌÌÌÌÌÌÊÊÊÐÐз··¼¼¼ÂÂÂÅÅÅÆÆÆ¿¿¿ÃÃÃÕÕÕÛÛÛÉÉɺºº»»»ÀÀÀÅÅÅÇÇÇÆÆÆÆÆÆÊÊÊÎÎγ³³¯¯¯­­­´´´¾¾¾ÀÀÀººº±±±­­­»»»ÇÇÇÉÉÉÅÅÅÂÂÂÂÂÂÀÀÀ¿¿¿¾¾¾ÂÂÂÉÉÉÔÔÔÜÜÜÒÒÒÅÅÅÔÔÔèèèÒÒÒÉÉÉÇÇÇÂÂÂØØØÝÝÝòòòêêêçççèèèàààÒÒÒÌÌÌÐÐÐÝÝÝÝÝÝÐÐÐÒÒÒÊÊÊÌÌÌØØصµµ¾¾¾¼¼¼ÍÍÍÑÑÑ¿¿¿ÍÍÍÆÆÆÔÔÔÍÍÍÊÊÊÇÇÇÇÇÇÊÊÊÊÊÊÉÉÉÆÆÆÉÉÉÎÎÎÎÎÎÐÐÐÌÌÌÒÒÒäääÝÝÝÒÒÒßßßÀÀÀ¼¼¼æææçççÐÐÐÕÕÕÎÎÎæææÇÇÇÛÛÛØØØíííñññãããÛÛÛØØØÕÕÕÔÔÔÒÒÒÑÑÑÍÍÍÊÊÊÉÉÉÃÃÃÆÆÆÆÆÆÅÅÅÔÔÔÐÐа°°°°°¿¿¿ÀÀÀÌÌÌÊÊʸ¸¸»»»ÀÀÀÇÇÇÍÍÍÎÎÎÅÅÅÉÉÉÌÌÌÅÅÅÐÐÐÎÎÎÌÌÌÍÍÍÊÊÊÀÀÀÅÅÅÒÒÒØØØÐÐÐÍÍÍÊÊÊÊÊÊÌÌÌÎÎÎÐÐÐÐÐÐÒÒÒÔÔÔÔÔÔÔÔÔÕÕÕÕÕÕÕÕÕÕÕÕÌÌ̺ºº´´´······¸¸¸»»»µµµ´´´´´´µµµ¸¸¸»»»»»»¸¸¸µµµ···ººº¼¼¼¼¼¼¾¾¾ÀÀÀ¼¼¼ÀÀÀÑÑÑàààÕÕÕÕÕÕÉÉÉÒÒÒÕÕÕÒÒÒÙÙÙßßßÛÛÛÛÛÛÜÜÜÕÕÕ×××ÔÔÔÌÌÌ¿¿¿¸¸¸¼¼¼ÆÆÆÍÍÍÉÉÉÊÊÊÇÇÇÉÉÉÉÉÉÇÇÇÃÃÃÅÅÅííííííæææçççêêêíííèèèÌÌÌàààíííîîîçççèèèêêêêêêíííëëëíííîîîòòòööööööóóóïïïààà»»»ÃÃÃÇÇÇÇÇÇÑÑÑÇÇÇÇÇÇÉÉÉÍÍÍÌÌÌÉÉÉÍÍ͵µµ»»»ÂÂÂÀÀÀÃÃÃÅÅÅÍÍÍÙÙÙÔÔÔÅÅž¾¾¼¼¼ÃÃÃÇÇÇÉÉÉÉÉÉÉÉÉÊÊÊÊÊÊÉÉÉÃÃÿ¿¿ÂÂÂÆÆÆÅÅźºº°°°­­­»»»ÇÇÇÉÉÉÅÅÅÅÅÅÅÅÅÅÅÅ¿¿¿ÆÆÆÐÐÐÕÕÕÛÛÛÜÜÜÔÔÔÊÊÊÛÛÛâââÊÊÊÃÃÿ¿¿¿¿¿ÝÝÝèèèÑÑÑÒÒÒßßßïïïòòòçççààààààÝÝÝ×××ÇÇÇÎÎÎÍÍÍÑÑÑßßßÂÂÂÅÅÅÂÂÂÌÌÌÎÎÎÆÆÆÐÐÐÅÅÅÜÜÜÌÌÌÊÊÊÇÇÇÉÉÉÌÌÌÍÍÍÌÌÌÌÌÌÊÊÊÍÍÍÊÊÊÐÐÐÐÐÐÕÕÕâââØØØÇÇÇÊÊÊÉÉÉÑÑÑàààãããÜÜÜÙÙÙÍÍÍÛÛÛÉÉÉÜÜÜÔÔÔëëëîîîÝÝÝÛÛÛØØØÕÕÕÒÒÒÒÒÒÐÐÐÍÍÍÊÊÊÇÇÇÃÃÃÆÆÆÆÆÆÆÆÆÕÕÕÒÒÒ···»»»ÀÀÀ···ººº»»»±±±»»»ÃÃÃÃÃÃÂÂÂÇÇÇÃÃÃÅÅÅÇÇÇÂÂÂÌÌÌÎÎÎÉÉÉÇÇÇÅÅÅÅÅÅÍÍÍÕÕÕÕÕÕÍÍÍÌÌÌÊÊÊÊÊÊÍÍÍÎÎÎÎÎÎÎÎÎÐÐÐÑÑÑÒÒÒÔÔÔÔÔÔÒÒÒÑÑÑÐÐÐÌÌÌ»»»±±±³³³´´´···¸¸¸µµµµµµµµµ···¸¸¸»»»»»»ººº¸¸¸···¼¼¼ÀÀÀÂÂÂÆÆÆÌÌÌÌÌÌÇÇÇ¿¿¿ÌÌÌÛÛÛßßß××××××ÌÌÌÕÕÕ×××ØØØÝÝÝàààÛÛÛØØØØØØÔÔÔÒÒÒÉÉɾ¾¾¸¸¸´´´»»»ÇÇÇÀÀÀÃÃþ¾¾ÀÀÀ¿¿¿¿¿¿ÅÅÅÜÜÜíííîîîæææèèèîîîñññäää¼¼¼ÇÇÇãããïïïèèèçççèèèêêêïïïòòòíííèèèêêêïïïóóóõõõóóóããã¿¿¿ÂÂÂÇÇÇÉÉÉÎÎÎÉÉÉÍÍÍÉÉÉÍÍÍÍÍÍÍÍÍÌÌÌ´´´¸¸¸¾¾¾¼¼¼ÅÅÅÍÍÍØØØÛÛÛÌÌÌ¿¿¿ÂÂÂÆÆÆÍÍÍÐÐÐÍÍÍÊÊÊÌÌÌÇÇÇÂÂÂÆÆÆ¿¿¿ÂÂÂÆÆÆÃÃúºº±±±¬¬¬»»»ÇÇÇÊÊÊÇÇÇÉÉÉÌÌÌÌÌ̾¾¾ÊÊÊÑÑÑÔÔÔÒÒÒÐÐÐÎÎÎÍÍÍÜÜÜ×××ÆÆÆÉÉÉÀÀÀ¾¾¾ÜÜÜçççÔÔÔÕÕÕßßßëëëîîîæææàààâââããã×××ÆÆÆÍÍÍÎÎÎÐÐÐÝÝÝÊÊʾ¾¾ÇÇÇÑÑÑÊÊÊÌÌÌ×××ÊÊÊßßßÐÐÐÍÍÍÌÌÌÊÊÊÌÌÌÍÍÍÍÍÍÍÍÍÊÊÊÊÊÊÇÇÇÎÎÎÒÒÒ×××ÝÝÝÑÑÑÊÊÊÌÌÌÎÎÎÔÔÔÜÜÜÜÜÜ×××ÕÕÕÔÔÔÕÕÕÔÔÔãããÔÔÔòòòóóóàààÛÛÛØØØÕÕÕÒÒÒÑÑÑÎÎÎÌÌÌÉÉÉÆÆÆÂÂÂÅÅÅÆÆÆÇÇÇ×××ØØØÂÂÂÌÌÌÉÉÉ···³³³······ÀÀÀÇÇǺººÃÃÃÇÇÇÆÆÆÇÇÇÆÆÆÎÎÎÌÌÌÅÅÅÆÆÆÐÐÐÙÙÙÜÜÜ×××ÑÑÑÐÐÐÎÎÎÌÌÌÌÌÌÍÍÍÎÎÎÐÐÐÎÎÎÐÐÐÐÐÐÑÑÑÑÑÑÐÐÐÎÎÎÎÎÎÍÍÍÐÐÐÀÀÀµµµ´´´´´´´´´´´´´´´µµµµµµ···ººº»»»»»»»»»»»»ÂÂÂÇÇÇÊÊÊÉÉÉÊÊÊÎÎÎÉÉÉ¿¿¿ÃÃÃ×××âââÛÛÛØØØÙÙÙÐÐÐÛÛÛÙÙÙÙÙÙÛÛÛÛÛÛÙÙÙØØØ×××ÕÕÕÆÆÆ»»»¿¿¿ÑÑÑÕÕÕÃÃø¸¸»»»ÀÀÀµµµ»»»¸¸¸¸¸¸ÂÂÂæææèèèíííèèèêêêîîîòòòäää¾¾¾¿¿¿ÝÝÝïïïîîîîîîñññòòòöööùùùñññèèèçççíííòòòóóóòòòèèèÆÆÆÂÂÂÆÆÆÆÆÆÉÉÉÆÆÆÎÎÎÇÇÇÍÍÍÍÍÍÒÒÒÊÊÊ´´´µµµ¸¸¸¾¾¾ÌÌÌÕÕÕØØØ×××ÉÉɼ¼¼¾¾¾ÂÂÂÇÇÇÉÉÉÃÃÃÃÃÃÆÆÆÃÃü¼¼¸¸¸······»»»¿¿¿¿¿¿¸¸¸³³³­­­»»»ÉÉÉÍÍÍÎÎÎÐÐÐÑÑÑÑÑÑÎÎÎ×××ÐÐÐÌÌÌÉÉÉÅÅÅÉÉÉÍÍÍâââÎÎÎÆÆÆÍÍÍ¿¿¿»»»ØØØààà×××ÙÙÙäääïïïòòòêêêãããàààÔÔÔÊÊÊÂÂÂÎÎÎÑÑÑÔÔÔäääààà´´´ÊÊÊÝÝÝÊÊÊÉÉÉÜÜÜÒÒÒ×××ÕÕÕÒÒÒÐÐÐÍÍÍÊÊÊÉÉÉÉÉÉÉÉÉÉÉÉÊÊÊÆÆÆÍÍÍÐÐÐÐÐÐ×××ÐÐÐÂÂÂÎÎÎÀÀÀ¸¸¸ÙÙÙãããÒÒÒßßßØØØÎÎÎÛÛÛãããÐÐÐóóóõõõàààÛÛÛØØØÔÔÔÒÒÒÐÐÐÎÎÎÊÊÊÇÇÇÆÆÆÂÂÂÅÅÅÇÇÇÉÉÉÕÕÕÙÙÙÍÍÍÑÑÑÎÎξ¾¾µµµ»»»¿¿¿ÂÂÂÅÅÅÀÀÀ±±±¿¿¿ÉÉÉÅÅÅÆÆÆÆÆÆÍÍÍÃÃÃÂÂÂÌÌÌÜÜÜãããÛÛÛÔÔÔ×××ØØØÔÔÔÎÎÎÌÌÌÍÍÍÎÎÎÐÐÐÐÐÐÑÑÑÐÐÐÎÎÎÍÍÍÌÌÌÌÌÌÌÌÌÌÌÌÒÒÒÇÇǼ¼¼¸¸¸···³³³±±±´´´´´´µµµ···ººº»»»¼¼¼¾¾¾¿¿¿¾¾¾ÃÃÃÇÇÇÉÉÉÌÌÌÎÎÎÉÉÉÀÀÀÅÅÅ×××âââÕÕÕÕÕÕ×××ÑÑÑÛÛÛÜÜÜÛÛÛØØØÙÙÙÜÜÜÙÙÙÑÑÑÍÍ;¾¾ÀÀÀÎÎÎâââæææØØØÇÇÇ¿¿¿³³³´´´­­­¾¾¾¸¸¸»»»ÂÂÂäääêêêñññïïïîîîêêêëëëæææÇÇÇÊÊÊâââîîîîîîóóóøøøóóóòòòöööïïïêêêëëëïïïóóóñññíííßßßÅÅÅÂÂÂÇÇÇÉÉÉÇÇÇÅÅÅÌÌÌÍÍÍÎÎÎÌÌÌÐÐа°°µµµ»»»ÂÂÂÔÔÔØØØÐÐÐÎÎÎÉÉɾ¾¾···µµµ¸¸¸¸¸¸µµµ···¼¼¼¾¾¾ººº¼¼¼»»»»»»¼¼¼¾¾¾»»»···³³³°°°¼¼¼ÉÉÉÎÎÎÒÒÒ×××ÕÕÕÒÒÒÔÔÔÙÙÙÊÊÊÍÍÍ×××ÕÕÕÝÝÝâââæææÌÌÌÂÂÂÆÆƸ¸¸¼¼¼ÛÛÛãããçççææææææêêêêêêèèèèèèëëëÍÍÍÉÉÉÉÉÉÔÔÔÒÒÒÑÑÑÝÝÝããã¾¾¾ÊÊÊãããÍÍÍÀÀÀÑÑÑÐÐÐÐÐÐÔÔÔÒÒÒÐÐÐÌÌÌÉÉÉÇÇÇÆÆÆÆÆÆÅÅÅÌÌÌÆÆÆÊÊÊÊÊÊÆÆÆÐÐÐÑÑÑ¿¿¿ÌÌ̾¾¾¬¬¬ÌÌÌâââÒÒÒÙÙÙÑÑÑÇÇÇØØØÙÙÙÊÊÊëëëíííÝÝÝÛÛÛØØØÕÕÕÒÒÒÐÐÐÍÍÍÊÊÊÇÇÇÆÆÆÃÃÃÅÅÅÇÇÇÊÊÊÒÒÒØØØÕÕÕÐÐÐÍÍÍÀÀÀ´´´ºººÀÀÀ¾¾¾¼¼¼¾¾¾­­­»»»ÅÅÅÂÂÂÂÂÂÂÂÂÇÇÇ»»»ÇÇÇÔÔÔÛÛÛ×××ÌÌÌÎÎÎÝÝÝÛÛÛ×××ÐÐÐÍÍÍÍÍÍÎÎÎÑÑÑÑÑÑÑÑÑÐÐÐÍÍÍÊÊÊÉÉÉÉÉÉÉÉÉÉÉÉÐÐÐÌÌÌÅÅž¾¾ººº±±±¯¯¯µµµ±±±´´´···ººº»»»¾¾¾ÀÀÀÃÃÃÉÉÉÊÊÊÐÐÐÔÔÔÕÕÕÒÒÒÍÍÍÉÉÉÃÃÃÎÎÎßßßÔÔÔÕÕÕÔÔÔÒÒÒØØØÛÛÛÝÝÝÙÙÙÙÙÙÜÜÜÕÕÕÇÇÇÂÂÂÂÂÂØØØæææãããßßßâââÝÝÝÑÑѳ³³······ÌÌ̺ºº»»»¾¾¾ØØØæææîîîïïïñññêêêèèèîîîßßßÜÜÜæææçççêêêóóóóóóëëëèèèíííêêêêêêîîîñññïïïèèèãããÉÉÉ¿¿¿ÀÀÀÉÉÉÍÍÍÊÊÊÆÆÆÇÇÇÑÑÑÑÑÑÉÉÉÍÍ͸¸¸­­­···¿¿¿ÂÂÂ×××ØØØÉÉÉÆÆÆÇÇÇ¿¿¿···ÂÂÂÀÀÀ¿¿¿»»»ººº¸¸¸¸¸¸ººº¼¼¼»»»ººººººººº¸¸¸µµµ´´´µµµ¾¾¾ÅÅÅÊÊÊÑÑÑØØØ×××ÑÑÑÍÍÍÕÕÕÅÅÅÒÒÒæææãããæææäääØØØÇÇÇÅÅÅÆÆƾ¾¾ÇÇÇÜÜÜÝÝÝÝÝÝàààæææêêêçççÝÝÝÒÒÒÍÍÍÑÑÑÑÑÑÔÔÔ×××ÑÑÑÊÊÊÎÎÎÔÔÔ×××ÇÇÇÛÛÛÍÍÍÂÂÂÃÃÃÆÆÆÎÎÎÉÉÉÊÊÊÊÊÊÊÊÊÇÇÇÆÆÆÆÆÆÆÆÆÂÂÂÊÊÊÅÅÅÇÇÇÆÆÆ¿¿¿ÇÇÇÎÎÎÉÉÉÂÂÂÇÇǺºº¿¿¿ÙÙÙÔÔÔÌÌÌÍÍÍÍÍÍÙÙÙÕÕÕÒÒÒëëëèèèàààÜÜÜÙÙÙÕÕÕÒÒÒÑÑÑÎÎÎÊÊÊÇÇÇÇÇÇÅÅÅÆÆÆÉÉÉÊÊÊÎÎÎÔÔÔ×××ÒÒÒÒÒÒÇÇÇ´´´¸¸¸ÅÅÅ¿¿¿ÀÀÀÃÃ÷··¿¿¿ÃÃÃÅÅÅÆÆÆÂÂÂÇÇǼ¼¼ÑÑÑØØØÑÑÑÌÌÌÊÊÊÍÍÍ×××ØØØÔÔÔÐÐÐÍÍÍÎÎÎÐÐÐÐÐÐÐÐÐÐÐÐÎÎÎÍÍÍÌÌÌÉÉÉÇÇÇÆÆÆÆÆÆÇÇÇÌÌÌÇÇǼ¼¼±±±­­­···°°°³³³···ººº»»»¿¿¿ÃÃÃÇÇÇäääââââââäääÝÝÝÎÎÎÆÆÆÇÇÇÆÆÆÉÉÉâââÜÜÜÝÝÝÙÙÙÛÛÛÙÙÙÙÙÙßßßÛÛÛÕÕÕÒÒÒÌÌÌÅÅÅÇÇÇÒÒÒçççïïïäääÜÜÜâââãããÝÝÝÒÒÒÕÕÕÕÕÕßßß´´´µµµ¼¼¼ÔÔÔæææëëëîîîóóóíííëëëõõõïïïêêêèèèâââæææñññîîîççççççæææçççëëëîîîíííäääØØØÎÎο¿¿¾¾¾¾¾¾ÅÅÅÉÉÉÉÉÉÆÆÆÅÅÅÌÌÌÍÍÍÉÉÉÔÔÔººº°°°µµµ»»»¾¾¾ÑÑÑÕÕÕÉÉÉÂÂÂÀÀÀ¾¾¾¾¾¾ÑÑÑÍÍÍÊÊÊÉÉɸ¸¸···¼¼¼·········µµµµµµµµµ¸¸¸ººº¼¼¼¼¼¼¼¼¼ÀÀÀÊÊÊÔÔÔÔÔÔÎÎÎÕÕÕÝÝÝÇÇÇÔÔÔãããÔÔÔÐÐÐÊÊÊÉÉÉÇÇÇÌÌÌÇÇÇÅÅÅÒÒÒÛÛÛÑÑÑÑÑÑÔÔÔ×××ØØØ×××ÔÔÔÐÐÐÍÍÍÉÉÉÊÊÊÎÎÎÒÒÒÒÒÒÒÒÒÑÑÑÒÒÒàààÃÃÃÍÍÍÊÊÊÑÑÑÉÉÉ¿¿¿ÊÊÊÂÂÂÅÅÅÇÇÇÇÇÇÅÅÅÂÂÂÂÂÂÂÂÂÀÀÀÇÇÇ¿¿¿ÃÃÃÇÇÇ¿¿¿ÂÂÂÆÆÆÎÎκººÂ¾¾¾ÇÇÇàààØØØÔÔÔÉÉÉØØØÜÜÜ×××âââïïïçççãããÝÝÝÛÛÛ×××ÔÔÔÑÑÑÎÎÎÊÊÊÇÇÇÉÉÉÇÇÇÇÇÇÊÊÊÊÊÊÉÉÉÍÍÍÕÕÕÒÒÒÕÕÕÍÍÍ´´´µµµÅÅÅÂÂÂÅÅÅÃÃÿ¿¿ÀÀÀ¼¼¼ÂÂÂÃÃû»»ÂÂÂÅÅÅÛÛÛÙÙÙÊÊÊÌÌÌÔÔÔÐÐÐÊÊÊÒÒÒÑÑÑÎÎÎÎÎÎÐÐÐÐÐÐÐÐÐÎÎÎÎÎÎÎÎÎÎÎÎÍÍÍÊÊÊÇÇÇÅÅÅÃÃÃÀÀÀÉÉÉÉÉÉÅÅž¾¾°°°¬¬¬¸¸¸¯¯¯±±±µµµººº¼¼¼ÀÀÀÆÆÆÊÊÊßßßÛÛÛÝÝÝæææàààÑÑÑÌÌÌÒÒÒÌÌÌÊÊÊèèèèèèèèèâââãããÝÝÝØØØßßßÙÙÙÍÍÍÇÇÇÃÃÃÇÇÇ×××ãããçççëëëíííçççàààÜÜÜÛÛÛßßßààààààççç³³³¾¾¾ÕÕÕóóóñññññññññøøøïïïèèèòòòîîîïïïçççßßßäääïïïíííèèèîîîæææèèèííííííçççØØØÇÇǼ¼¼ÂÂÂÃÃü¼¼¼¼¼¿¿¿ÃÃÃÆÆÆÃÃÃÂÂÂÉÉÉÍÍÍÝÝÝ´´´±±±³³³¸¸¸ÌÌÌÒÒÒÌÌ̺ºº»»»ÆÆÆÉÉÉÃÃÃÅÅÅÊÊÊÅÅÅ······Â¾¾¾¼¼¼»»»¸¸¸µµµ···ººº»»»ÀÀÀ¼¼¼······ÃÃÃÐÐÐÒÒÒÍÍÍÒÒÒÜÜÜÆÆÆÒÒÒâââÐÐÐÍÍÍÉÉÉÌÌÌÐÐÐÐÐÐÀÀÀÀÀÀÕÕÕÙÙÙÎÎÎÑÑÑÔÔÔ×××ØØØ×××ÕÕÕÒÒÒÐÐÐÍÍÍÌÌÌÌÌÌÍÍÍÔÔÔÕÕÕÎÎÎÊÊÊ××׿¿¿ÆÆÆÆÆÆàààØØØÂÂÂÅÅÅÂÂÂÅÅÅÇÇÇÆÆƾ¾¾»»»»»»ÀÀÀÅÅźººÂÂÂÌÌ̾¾¾¿¿¿ãããÉÉɺºº···ÙÙÙäääÉÉÉØØØ¿¿¿ÛÛÛÙÙÙÔÔÔçççíííßßßàààßßßÜÜÜØØØÔÔÔÒÒÒÎÎÎÊÊÊÇÇÇÉÉÉÉÉÉÉÉÉÌÌÌÊÊÊÅÅÅÉÉÉÒÒÒÉÉÉÎÎÎÌÌ̱±±±±±ÀÀÀ»»»¾¾¾ºººººº···­­­µµµ¸¸¸­­­³³³ \ No newline at end of file diff --git a/libs/ode-0.16.1/include/Makefile.am b/libs/ode-0.16.1/include/Makefile.am new file mode 100644 index 0000000..0a0830e --- /dev/null +++ b/libs/ode-0.16.1/include/Makefile.am @@ -0,0 +1 @@ +SUBDIRS = ode drawstuff diff --git a/libs/ode-0.16.1/include/Makefile.in b/libs/ode-0.16.1/include/Makefile.in new file mode 100644 index 0000000..3a7f2b2 --- /dev/null +++ b/libs/ode-0.16.1/include/Makefile.in @@ -0,0 +1,640 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = include +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ + $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ + $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/ode/src/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +SOURCES = +DIST_SOURCES = +RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ + ctags-recursive dvi-recursive html-recursive info-recursive \ + install-data-recursive install-dvi-recursive \ + install-exec-recursive install-html-recursive \ + install-info-recursive install-pdf-recursive \ + install-ps-recursive install-recursive installcheck-recursive \ + installdirs-recursive pdf-recursive ps-recursive \ + tags-recursive uninstall-recursive +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ + distclean-recursive maintainer-clean-recursive +am__recursive_targets = \ + $(RECURSIVE_TARGETS) \ + $(RECURSIVE_CLEAN_TARGETS) \ + $(am__extra_recursive_targets) +AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ + distdir +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +DIST_SUBDIRS = $(SUBDIRS) +am__DIST_COMMON = $(srcdir)/Makefile.in +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +am__relativize = \ + dir0=`pwd`; \ + sed_first='s,^\([^/]*\)/.*$$,\1,'; \ + sed_rest='s,^[^/]*/*,,'; \ + sed_last='s,^.*/\([^/]*\)$$,\1,'; \ + sed_butlast='s,/*[^/]*$$,,'; \ + while test -n "$$dir1"; do \ + first=`echo "$$dir1" | sed -e "$$sed_first"`; \ + if test "$$first" != "."; then \ + if test "$$first" = ".."; then \ + dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ + dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ + else \ + first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ + if test "$$first2" = "$$first"; then \ + dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ + else \ + dir2="../$$dir2"; \ + fi; \ + dir0="$$dir0"/"$$first"; \ + fi; \ + fi; \ + dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ + done; \ + reldir="$$dir2" +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AS = @AS@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CCD_CFLAGS = @CCD_CFLAGS@ +CCD_LIBS = @CCD_LIBS@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DOXYGEN = @DOXYGEN@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +EXTRA_LIBTOOL_LDFLAGS = @EXTRA_LIBTOOL_LDFLAGS@ +FGREP = @FGREP@ +GL_LIBS = @GL_LIBS@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBSTDCXX = @LIBSTDCXX@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +ODE_PRECISION = @ODE_PRECISION@ +ODE_VERSION = @ODE_VERSION@ +ODE_VERSION_INFO = @ODE_VERSION_INFO@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +WINDRES = @WINDRES@ +X11_CFLAGS = @X11_CFLAGS@ +X11_LIBS = @X11_LIBS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_WINDRES = @ac_ct_WINDRES@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +runstatedir = @runstatedir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +SUBDIRS = ode drawstuff +all: all-recursive + +.SUFFIXES: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign include/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign include/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +# This directory's subdirectories are mostly independent; you can cd +# into them and run 'make' without going through this Makefile. +# To change the values of 'make' variables: instead of editing Makefiles, +# (1) if the variable is set in 'config.status', edit 'config.status' +# (which will cause the Makefiles to be regenerated when you run 'make'); +# (2) otherwise, pass the desired values on the 'make' command line. +$(am__recursive_targets): + @fail=; \ + if $(am__make_keepgoing); then \ + failcom='fail=yes'; \ + else \ + failcom='exit 1'; \ + fi; \ + dot_seen=no; \ + target=`echo $@ | sed s/-recursive//`; \ + case "$@" in \ + distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ + *) list='$(SUBDIRS)' ;; \ + esac; \ + for subdir in $$list; do \ + echo "Making $$target in $$subdir"; \ + if test "$$subdir" = "."; then \ + dot_seen=yes; \ + local_target="$$target-am"; \ + else \ + local_target="$$target"; \ + fi; \ + ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ + || eval $$failcom; \ + done; \ + if test "$$dot_seen" = "no"; then \ + $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ + fi; test -z "$$fail" + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-recursive +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ + include_option=--etags-include; \ + empty_fix=.; \ + else \ + include_option=--include; \ + empty_fix=; \ + fi; \ + list='$(SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + test ! -f $$subdir/TAGS || \ + set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ + fi; \ + done; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-recursive + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-recursive + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done + @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + $(am__make_dryrun) \ + || test -d "$(distdir)/$$subdir" \ + || $(MKDIR_P) "$(distdir)/$$subdir" \ + || exit 1; \ + dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ + $(am__relativize); \ + new_distdir=$$reldir; \ + dir1=$$subdir; dir2="$(top_distdir)"; \ + $(am__relativize); \ + new_top_distdir=$$reldir; \ + echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ + echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ + ($(am__cd) $$subdir && \ + $(MAKE) $(AM_MAKEFLAGS) \ + top_distdir="$$new_top_distdir" \ + distdir="$$new_distdir" \ + am__remove_distdir=: \ + am__skip_length_check=: \ + am__skip_mode_fix=: \ + distdir) \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-recursive +all-am: Makefile +installdirs: installdirs-recursive +installdirs-am: +install: install-recursive +install-exec: install-exec-recursive +install-data: install-data-recursive +uninstall: uninstall-recursive + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-recursive +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-recursive + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-recursive + -rm -f Makefile +distclean-am: clean-am distclean-generic distclean-tags + +dvi: dvi-recursive + +dvi-am: + +html: html-recursive + +html-am: + +info: info-recursive + +info-am: + +install-data-am: + +install-dvi: install-dvi-recursive + +install-dvi-am: + +install-exec-am: + +install-html: install-html-recursive + +install-html-am: + +install-info: install-info-recursive + +install-info-am: + +install-man: + +install-pdf: install-pdf-recursive + +install-pdf-am: + +install-ps: install-ps-recursive + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-recursive + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-recursive + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-recursive + +pdf-am: + +ps: ps-recursive + +ps-am: + +uninstall-am: + +.MAKE: $(am__recursive_targets) install-am install-strip + +.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \ + check-am clean clean-generic clean-libtool cscopelist-am ctags \ + ctags-am distclean distclean-generic distclean-libtool \ + distclean-tags distdir dvi dvi-am html html-am info info-am \ + install install-am install-data install-data-am install-dvi \ + install-dvi-am install-exec install-exec-am install-html \ + install-html-am install-info install-info-am install-man \ + install-pdf install-pdf-am install-ps install-ps-am \ + install-strip installcheck installcheck-am installdirs \ + installdirs-am maintainer-clean maintainer-clean-generic \ + mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ + ps ps-am tags tags-am uninstall uninstall-am + +.PRECIOUS: Makefile + + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/libs/ode-0.16.1/include/drawstuff/Makefile.am b/libs/ode-0.16.1/include/drawstuff/Makefile.am new file mode 100644 index 0000000..14a9fb1 --- /dev/null +++ b/libs/ode-0.16.1/include/drawstuff/Makefile.am @@ -0,0 +1,2 @@ +noinst_HEADERS = drawstuff.h version.h + diff --git a/libs/ode-0.16.1/include/drawstuff/Makefile.in b/libs/ode-0.16.1/include/drawstuff/Makefile.in new file mode 100644 index 0000000..3bc421d --- /dev/null +++ b/libs/ode-0.16.1/include/drawstuff/Makefile.in @@ -0,0 +1,528 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = include/drawstuff +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ + $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ + $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(noinst_HEADERS) \ + $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/ode/src/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +SOURCES = +DIST_SOURCES = +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +HEADERS = $(noinst_HEADERS) +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AS = @AS@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CCD_CFLAGS = @CCD_CFLAGS@ +CCD_LIBS = @CCD_LIBS@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DOXYGEN = @DOXYGEN@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +EXTRA_LIBTOOL_LDFLAGS = @EXTRA_LIBTOOL_LDFLAGS@ +FGREP = @FGREP@ +GL_LIBS = @GL_LIBS@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBSTDCXX = @LIBSTDCXX@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +ODE_PRECISION = @ODE_PRECISION@ +ODE_VERSION = @ODE_VERSION@ +ODE_VERSION_INFO = @ODE_VERSION_INFO@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +WINDRES = @WINDRES@ +X11_CFLAGS = @X11_CFLAGS@ +X11_LIBS = @X11_LIBS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_WINDRES = @ac_ct_WINDRES@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +runstatedir = @runstatedir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +noinst_HEADERS = drawstuff.h version.h +all: all-am + +.SUFFIXES: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign include/drawstuff/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign include/drawstuff/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(HEADERS) +installdirs: +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-am + -rm -f Makefile +distclean-am: clean-am distclean-generic distclean-tags + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: + +.MAKE: install-am install-strip + +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ + clean-libtool cscopelist-am ctags ctags-am distclean \ + distclean-generic distclean-libtool distclean-tags distdir dvi \ + dvi-am html html-am info info-am install install-am \ + install-data install-data-am install-dvi install-dvi-am \ + install-exec install-exec-am install-html install-html-am \ + install-info install-info-am install-man install-pdf \ + install-pdf-am install-ps install-ps-am install-strip \ + installcheck installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-generic \ + mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \ + uninstall-am + +.PRECIOUS: Makefile + + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/libs/ode-0.16.1/include/drawstuff/drawstuff.h b/libs/ode-0.16.1/include/drawstuff/drawstuff.h new file mode 100644 index 0000000..9a3ac20 --- /dev/null +++ b/libs/ode-0.16.1/include/drawstuff/drawstuff.h @@ -0,0 +1,325 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001-2003 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +/** @defgroup drawstuff DrawStuff + +DrawStuff is a library for rendering simple 3D objects in a virtual +environment, for the purposes of demonstrating the features of ODE. +It is provided for demonstration purposes and is not intended for +production use. + +@section Notes + +In the virtual world, the z axis is "up" and z=0 is the floor. + +The user is able to click+drag in the main window to move the camera: + * left button - pan and tilt. + * right button - forward and sideways. + * left + right button (or middle button) - sideways and up. +*/ + + +#ifndef __DRAWSTUFF_H__ +#define __DRAWSTUFF_H__ + +/* Define a DLL export symbol for those platforms that need it */ +#if defined(ODE_PLATFORM_WINDOWS) + #if defined(DS_DLL) + #define DS_API __declspec(dllexport) + #elif !defined(DS_LIB) + #define DS_DLL_API __declspec(dllimport) + #endif +#endif + +#if !defined(DS_API) + #define DS_API +#endif + +#ifdef __cplusplus +extern "C" { +#endif + + +#include + + +/* texture numbers */ + enum DS_TEXTURE_NUMBER + { + DS_NONE = 0, /* uses the current color instead of a texture */ + DS_WOOD, + DS_CHECKERED, + DS_GROUND, + DS_SKY + }; + +/* draw modes */ + +#define DS_POLYFILL 0 +#define DS_WIREFRAME 1 + +/** + * @struct dsFunctions + * @brief Set of functions to be used as callbacks by the simulation loop. + * @ingroup drawstuff + */ +typedef struct dsFunctions { + int version; /* put DS_VERSION here */ + /* version 1 data */ + void (*start)(); /* called before sim loop starts */ + void (*step) (int pause); /* called before every frame */ + void (*command) (int cmd); /* called if a command key is pressed */ + void (*stop)(); /* called after sim loop exits */ + /* version 2 data */ + const char *path_to_textures; /* if nonzero, path to texture files */ +} dsFunctions; + + +/** + * @brief Does the complete simulation. + * @ingroup drawstuff + * This function starts running the simulation, and only exits when the simulation is done. + * Function pointers should be provided for the callbacks. + * @param argv supports flags like '-notex' '-noshadow' '-pause' + * @param fn Callback functions. + */ +DS_API void dsSimulationLoop (int argc, char **argv, + int window_width, int window_height, + struct dsFunctions *fn); + +/** + * @brief exit with error message. + * @ingroup drawstuff + * This function displays an error message then exit. + * @param msg format strin, like printf, without the newline character. + */ +DS_API void dsError (const char *msg, ...); + +/** + * @brief exit with error message and core dump. + * @ingroup drawstuff + * this functions tries to dump core or start the debugger. + * @param msg format strin, like printf, without the newline character. + */ +DS_API void dsDebug (const char *msg, ...); + +/** + * @brief print log message + * @ingroup drawstuff + * @param msg format string, like printf, without the \n. + */ +DS_API void dsPrint (const char *msg, ...); + +/** + * @brief Sets the viewpoint + * @ingroup drawstuff + * @param xyz camera position. + * @param hpr contains heading, pitch and roll numbers in degrees. heading=0 + * points along the x axis, pitch=0 is looking towards the horizon, and + * roll 0 is "unrotated". + */ +DS_API void dsSetViewpoint (float xyz[3], float hpr[3]); + + +/** + * @brief Gets the viewpoint + * @ingroup drawstuff + * @param xyz position + * @param hpr heading,pitch,roll. + */ +DS_API void dsGetViewpoint (float xyz[3], float hpr[3]); + +/** + * @brief Stop the simulation loop. + * @ingroup drawstuff + * Calling this from within dsSimulationLoop() + * will cause it to exit and return to the caller. it is the same as if the + * user used the exit command. using this outside the loop will have no + * effect. + */ +DS_API void dsStop(); + +/** + * @brief Get the elapsed time (on wall-clock) + * @ingroup drawstuff + * It returns the nr of seconds since the last call to this function. + */ +DS_API double dsElapsedTime(); + +/** + * @brief Toggle the rendering of textures. + * @ingroup drawstuff + * It changes the way objects are drawn. these changes will apply to all further + * dsDrawXXX() functions. + * @param the texture number must be a DS_xxx texture constant. + * The current texture is colored according to the current color. + * At the start of each frame, the texture is reset to none and the color is + * reset to white. + */ +DS_API void dsSetTexture (int texture_number); + +/** + * @brief Set the color with which geometry is drawn. + * @ingroup drawstuff + * @param red Red component from 0 to 1 + * @param green Green component from 0 to 1 + * @param blue Blue component from 0 to 1 + */ +DS_API void dsSetColor (float red, float green, float blue); + +/** + * @brief Set the color and transparency with which geometry is drawn. + * @ingroup drawstuff + * @param alpha Note that alpha transparency is a misnomer: it is alpha opacity. + * 1.0 means fully opaque, and 0.0 means fully transparent. + */ +DS_API void dsSetColorAlpha (float red, float green, float blue, float alpha); + +/** + * @brief Draw a box. + * @ingroup drawstuff + * @param pos is the x,y,z of the center of the object. + * @param R is a 3x3 rotation matrix for the object, stored by row like this: + * [ R11 R12 R13 0 ] + * [ R21 R22 R23 0 ] + * [ R31 R32 R33 0 ] + * @param sides[] is an array of x,y,z side lengths. + */ +DS_API void dsDrawBox (const float pos[3], const float R[12], const float sides[3]); + +/** + * @brief Draw a sphere. + * @ingroup drawstuff + * @param pos Position of center. + * @param R orientation. + * @param radius + */ +DS_API void dsDrawSphere (const float pos[3], const float R[12], float radius); + +/** + * @brief Draw a triangle. + * @ingroup drawstuff + * @param pos Position of center + * @param R orientation + * @param v0 first vertex + * @param v1 second + * @param v2 third vertex + * @param solid set to 0 for wireframe + */ +DS_API void dsDrawTriangle (const float pos[3], const float R[12], + const float *v0, const float *v1, const float *v2, int solid); + +/** + * @brief Draw triangles. + * @ingroup drawstuff + * @param pos Position of center + * @param R orientation + * @param v list of vertices (x0, y0, z0, x1, y1, z1, ...) + * @param n number of vertices + * @param solid set to 0 for wireframe + */ +DS_API void dsDrawTriangles (const float pos[3], const float R[12], + const float *v, const int n, int solid); + +/** + * @brief Draw a z-aligned cylinder + * @ingroup drawstuff + */ +DS_API void dsDrawCylinder (const float pos[3], const float R[12], + float length, float radius); + +/** + * @brief Draw a z-aligned capsule + * @ingroup drawstuff + */ +DS_API void dsDrawCapsule (const float pos[3], const float R[12], + float length, float radius); + +/** + * @brief Draw a line. + * @ingroup drawstuff + */ +DS_API void dsDrawLine (const float pos1[3], const float pos2[3]); + +/** + * @brief Draw a convex shape. + * @ingroup drawstuff + */ +DS_API void dsDrawConvex(const float pos[3], const float R[12], + const float *_planes, + unsigned int _planecount, + const float *_points, + unsigned int _pointcount, + const unsigned int *_polygons); + + /* these drawing functions are identical to the ones above, except they take + * double arrays for `pos' and `R'. + */ +DS_API void dsDrawBoxD (const double pos[3], const double R[12], + const double sides[3]); +DS_API void dsDrawSphereD (const double pos[3], const double R[12], + const float radius); +DS_API void dsDrawTriangleD (const double pos[3], const double R[12], + const double *v0, const double *v1, const double *v2, int solid); +DS_API void dsDrawTrianglesD (const double pos[3], const double R[12], + const double *v, const int n, int solid); +DS_API void dsDrawCylinderD (const double pos[3], const double R[12], + float length, float radius); +DS_API void dsDrawCapsuleD (const double pos[3], const double R[12], + float length, float radius); +DS_API void dsDrawLineD (const double pos1[3], const double pos2[3]); +DS_API void dsDrawConvexD(const double pos[3], const double R[12], + const double *_planes, + unsigned int _planecount, + const double *_points, + unsigned int _pointcount, + const unsigned int *_polygons); + +/** + * @brief Set the quality with which curved objects are rendered. + * @ingroup drawstuff + * Higher numbers are higher quality, but slower to draw. + * This must be set before the first objects are drawn to be effective. + * Default sphere quality is 1, default capsule quality is 3. + */ +DS_API void dsSetSphereQuality (int n); /* default = 1 */ +DS_API void dsSetCapsuleQuality (int n); /* default = 3 */ + +/** + * @brief Set Drawmode 0=Polygon Fill,1=Wireframe). + * Use the DS_POLYFILL and DS_WIREFRAME macros. + * @ingroup drawstuff + */ +DS_API void dsSetDrawMode(int mode); + +/* Backwards compatible API */ +#define dsDrawCappedCylinder dsDrawCapsule +#define dsDrawCappedCylinderD dsDrawCapsuleD +#define dsSetCappedCylinderQuality dsSetCapsuleQuality + +/* closing bracket for extern "C" */ +#ifdef __cplusplus +} +#endif + +#endif + diff --git a/libs/ode-0.16.1/include/drawstuff/version.h b/libs/ode-0.16.1/include/drawstuff/version.h new file mode 100644 index 0000000..71d95f4 --- /dev/null +++ b/libs/ode-0.16.1/include/drawstuff/version.h @@ -0,0 +1,29 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#ifndef __VERSION_H +#define __VERSION_H + +/* high byte is major version, low byte is minor version */ +#define DS_VERSION 0x0002 + +#endif diff --git a/libs/ode-0.16.1/include/ode/Makefile.am b/libs/ode-0.16.1/include/ode/Makefile.am new file mode 100644 index 0000000..ad06509 --- /dev/null +++ b/libs/ode-0.16.1/include/ode/Makefile.am @@ -0,0 +1,34 @@ +libode_la_includedir = $(includedir)/ode +libode_la_include_HEADERS = \ + collision.h \ + collision_space.h \ + collision_trimesh.h \ + common.h \ + compatibility.h \ + contact.h \ + cooperative.h \ + error.h \ + export-dif.h \ + mass.h \ + matrix.h matrix_coop.h \ + memory.h \ + misc.h \ + objects.h \ + ode.h \ + odeconfig.h \ + odecpp.h \ + odecpp_collision.h \ + odeinit.h \ + odemath.h \ + odemath_legacy.h \ + rotation.h \ + threading.h \ + threading_impl.h \ + timer.h + + +EXTRA_DIST = README precision.h.in version.h.in + +dist_libode_la_include_HEADERS = precision.h version.h + + diff --git a/libs/ode-0.16.1/include/ode/Makefile.in b/libs/ode-0.16.1/include/ode/Makefile.in new file mode 100644 index 0000000..1dac65e --- /dev/null +++ b/libs/ode-0.16.1/include/ode/Makefile.in @@ -0,0 +1,642 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = include/ode +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ + $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ + $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(dist_libode_la_include_HEADERS) \ + $(libode_la_include_HEADERS) $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/ode/src/config.h +CONFIG_CLEAN_FILES = version.h precision.h +CONFIG_CLEAN_VPATH_FILES = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +SOURCES = +DIST_SOURCES = +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; +am__vpath_adj = case $$p in \ + $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ + *) f=$$p;; \ + esac; +am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; +am__install_max = 40 +am__nobase_strip_setup = \ + srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` +am__nobase_strip = \ + for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" +am__nobase_list = $(am__nobase_strip_setup); \ + for p in $$list; do echo "$$p $$p"; done | \ + sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ + $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ + if (++n[$$2] == $(am__install_max)) \ + { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ + END { for (dir in files) print dir, files[dir] }' +am__base_list = \ + sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ + sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__uninstall_files_from_dir = { \ + test -z "$$files" \ + || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && rm -f $$files; }; \ + } +am__installdirs = "$(DESTDIR)$(libode_la_includedir)" \ + "$(DESTDIR)$(libode_la_includedir)" +HEADERS = $(dist_libode_la_include_HEADERS) \ + $(libode_la_include_HEADERS) +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/precision.h.in \ + $(srcdir)/version.h.in README +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AS = @AS@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CCD_CFLAGS = @CCD_CFLAGS@ +CCD_LIBS = @CCD_LIBS@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DOXYGEN = @DOXYGEN@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +EXTRA_LIBTOOL_LDFLAGS = @EXTRA_LIBTOOL_LDFLAGS@ +FGREP = @FGREP@ +GL_LIBS = @GL_LIBS@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBSTDCXX = @LIBSTDCXX@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +ODE_PRECISION = @ODE_PRECISION@ +ODE_VERSION = @ODE_VERSION@ +ODE_VERSION_INFO = @ODE_VERSION_INFO@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +WINDRES = @WINDRES@ +X11_CFLAGS = @X11_CFLAGS@ +X11_LIBS = @X11_LIBS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_WINDRES = @ac_ct_WINDRES@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +runstatedir = @runstatedir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +libode_la_includedir = $(includedir)/ode +libode_la_include_HEADERS = \ + collision.h \ + collision_space.h \ + collision_trimesh.h \ + common.h \ + compatibility.h \ + contact.h \ + cooperative.h \ + error.h \ + export-dif.h \ + mass.h \ + matrix.h matrix_coop.h \ + memory.h \ + misc.h \ + objects.h \ + ode.h \ + odeconfig.h \ + odecpp.h \ + odecpp_collision.h \ + odeinit.h \ + odemath.h \ + odemath_legacy.h \ + rotation.h \ + threading.h \ + threading_impl.h \ + timer.h + +EXTRA_DIST = README precision.h.in version.h.in +dist_libode_la_include_HEADERS = precision.h version.h +all: all-am + +.SUFFIXES: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign include/ode/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign include/ode/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): +version.h: $(top_builddir)/config.status $(srcdir)/version.h.in + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ +precision.h: $(top_builddir)/config.status $(srcdir)/precision.h.in + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs +install-dist_libode_la_includeHEADERS: $(dist_libode_la_include_HEADERS) + @$(NORMAL_INSTALL) + @list='$(dist_libode_la_include_HEADERS)'; test -n "$(libode_la_includedir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(libode_la_includedir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(libode_la_includedir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(libode_la_includedir)'"; \ + $(INSTALL_HEADER) $$files "$(DESTDIR)$(libode_la_includedir)" || exit $$?; \ + done + +uninstall-dist_libode_la_includeHEADERS: + @$(NORMAL_UNINSTALL) + @list='$(dist_libode_la_include_HEADERS)'; test -n "$(libode_la_includedir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(libode_la_includedir)'; $(am__uninstall_files_from_dir) +install-libode_la_includeHEADERS: $(libode_la_include_HEADERS) + @$(NORMAL_INSTALL) + @list='$(libode_la_include_HEADERS)'; test -n "$(libode_la_includedir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(libode_la_includedir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(libode_la_includedir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(libode_la_includedir)'"; \ + $(INSTALL_HEADER) $$files "$(DESTDIR)$(libode_la_includedir)" || exit $$?; \ + done + +uninstall-libode_la_includeHEADERS: + @$(NORMAL_UNINSTALL) + @list='$(libode_la_include_HEADERS)'; test -n "$(libode_la_includedir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(libode_la_includedir)'; $(am__uninstall_files_from_dir) + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(HEADERS) +installdirs: + for dir in "$(DESTDIR)$(libode_la_includedir)" "$(DESTDIR)$(libode_la_includedir)"; do \ + test -z "$$dir" || $(MKDIR_P) "$$dir"; \ + done +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-am + -rm -f Makefile +distclean-am: clean-am distclean-generic distclean-tags + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: install-dist_libode_la_includeHEADERS \ + install-libode_la_includeHEADERS + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: uninstall-dist_libode_la_includeHEADERS \ + uninstall-libode_la_includeHEADERS + +.MAKE: install-am install-strip + +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ + clean-libtool cscopelist-am ctags ctags-am distclean \ + distclean-generic distclean-libtool distclean-tags distdir dvi \ + dvi-am html html-am info info-am install install-am \ + install-data install-data-am \ + install-dist_libode_la_includeHEADERS install-dvi \ + install-dvi-am install-exec install-exec-am install-html \ + install-html-am install-info install-info-am \ + install-libode_la_includeHEADERS install-man install-pdf \ + install-pdf-am install-ps install-ps-am install-strip \ + installcheck installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-generic \ + mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \ + uninstall-am uninstall-dist_libode_la_includeHEADERS \ + uninstall-libode_la_includeHEADERS + +.PRECIOUS: Makefile + + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/libs/ode-0.16.1/include/ode/README b/libs/ode-0.16.1/include/ode/README new file mode 100644 index 0000000..9d7e99a --- /dev/null +++ b/libs/ode-0.16.1/include/ode/README @@ -0,0 +1,18 @@ + +this is the public C interface to the ODE library. + +all these files should be includable from C, i.e. they should not use any +C++ features. everything should be protected with + + #ifdef __cplusplus + extern "C" { + #endif + + ... + + #ifdef __cplusplus + } + #endif + +the only exceptions are the odecpp.h and odecpp_collisioh.h files, which define a C++ wrapper for +the C interface. remember to keep this in sync! diff --git a/libs/ode-0.16.1/include/ode/collision.h b/libs/ode-0.16.1/include/ode/collision.h new file mode 100644 index 0000000..fef6e7b --- /dev/null +++ b/libs/ode-0.16.1/include/ode/collision.h @@ -0,0 +1,1526 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001-2003 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#ifndef _ODE_COLLISION_H_ +#define _ODE_COLLISION_H_ + +#include +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * @defgroup collide Collision Detection + * + * ODE has two main components: a dynamics simulation engine and a collision + * detection engine. The collision engine is given information about the + * shape of each body. At each time step it figures out which bodies touch + * each other and passes the resulting contact point information to the user. + * The user in turn creates contact joints between bodies. + * + * Using ODE's collision detection is optional - an alternative collision + * detection system can be used as long as it can supply the right kinds of + * contact information. + */ + + +/* ************************************************************************ */ +/* general functions */ + +/** + * @brief Destroy a geom, removing it from any space. + * + * Destroy a geom, removing it from any space it is in first. This one + * function destroys a geom of any type, but to create a geom you must call + * a creation function for that type. + * + * When a space is destroyed, if its cleanup mode is 1 (the default) then all + * the geoms in that space are automatically destroyed as well. + * + * @param geom the geom to be destroyed. + * @ingroup collide + */ +ODE_API void dGeomDestroy (dGeomID geom); + + +/** + * @brief Set the user-defined data pointer stored in the geom. + * + * @param geom the geom to hold the data + * @param data the data pointer to be stored + * @ingroup collide + */ +ODE_API void dGeomSetData (dGeomID geom, void* data); + + +/** + * @brief Get the user-defined data pointer stored in the geom. + * + * @param geom the geom containing the data + * @ingroup collide + */ +ODE_API void *dGeomGetData (dGeomID geom); + + +/** + * @brief Set the body associated with a placeable geom. + * + * Setting a body on a geom automatically combines the position vector and + * rotation matrix of the body and geom, so that setting the position or + * orientation of one will set the value for both objects. Setting a body + * ID of zero gives the geom its own position and rotation, independent + * from any body. If the geom was previously connected to a body then its + * new independent position/rotation is set to the current position/rotation + * of the body. + * + * Calling these functions on a non-placeable geom results in a runtime + * error in the debug build of ODE. + * + * @param geom the geom to connect + * @param body the body to attach to the geom + * @ingroup collide + */ +ODE_API void dGeomSetBody (dGeomID geom, dBodyID body); + + +/** + * @brief Get the body associated with a placeable geom. + * @param geom the geom to query. + * @sa dGeomSetBody + * @ingroup collide + */ +ODE_API dBodyID dGeomGetBody (dGeomID geom); + + +/** + * @brief Set the position vector of a placeable geom. + * + * If the geom is attached to a body, the body's position will also be changed. + * Calling this function on a non-placeable geom results in a runtime error in + * the debug build of ODE. + * + * @param geom the geom to set. + * @param x the new X coordinate. + * @param y the new Y coordinate. + * @param z the new Z coordinate. + * @sa dBodySetPosition + * @ingroup collide + */ +ODE_API void dGeomSetPosition (dGeomID geom, dReal x, dReal y, dReal z); + + +/** + * @brief Set the rotation matrix of a placeable geom. + * + * If the geom is attached to a body, the body's rotation will also be changed. + * Calling this function on a non-placeable geom results in a runtime error in + * the debug build of ODE. + * + * @param geom the geom to set. + * @param R the new rotation matrix. + * @sa dBodySetRotation + * @ingroup collide + */ +ODE_API void dGeomSetRotation (dGeomID geom, const dMatrix3 R); + + +/** + * @brief Set the rotation of a placeable geom. + * + * If the geom is attached to a body, the body's rotation will also be changed. + * + * Calling this function on a non-placeable geom results in a runtime error in + * the debug build of ODE. + * + * @param geom the geom to set. + * @param Q the new rotation. + * @sa dBodySetQuaternion + * @ingroup collide + */ +ODE_API void dGeomSetQuaternion (dGeomID geom, const dQuaternion Q); + + +/** + * @brief Get the position vector of a placeable geom. + * + * If the geom is attached to a body, the body's position will be returned. + * + * Calling this function on a non-placeable geom results in a runtime error in + * the debug build of ODE. + * + * @param geom the geom to query. + * @returns A pointer to the geom's position vector. + * @remarks The returned value is a pointer to the geom's internal + * data structure. It is valid until any changes are made + * to the geom. + * @sa dBodyGetPosition + * @ingroup collide + */ +ODE_API const dReal * dGeomGetPosition (dGeomID geom); + + +/** + * @brief Copy the position of a geom into a vector. + * @ingroup collide + * @param geom the geom to query + * @param pos a copy of the geom position + * @sa dGeomGetPosition + */ +ODE_API void dGeomCopyPosition (dGeomID geom, dVector3 pos); + + +/** + * @brief Get the rotation matrix of a placeable geom. + * + * If the geom is attached to a body, the body's rotation will be returned. + * + * Calling this function on a non-placeable geom results in a runtime error in + * the debug build of ODE. + * + * @param geom the geom to query. + * @returns A pointer to the geom's rotation matrix. + * @remarks The returned value is a pointer to the geom's internal + * data structure. It is valid until any changes are made + * to the geom. + * @sa dBodyGetRotation + * @ingroup collide + */ +ODE_API const dReal * dGeomGetRotation (dGeomID geom); + + +/** + * @brief Get the rotation matrix of a placeable geom. + * + * If the geom is attached to a body, the body's rotation will be returned. + * + * Calling this function on a non-placeable geom results in a runtime error in + * the debug build of ODE. + * + * @param geom the geom to query. + * @param R a copy of the geom rotation + * @sa dGeomGetRotation + * @ingroup collide + */ +ODE_API void dGeomCopyRotation(dGeomID geom, dMatrix3 R); + + +/** + * @brief Get the rotation quaternion of a placeable geom. + * + * If the geom is attached to a body, the body's quaternion will be returned. + * + * Calling this function on a non-placeable geom results in a runtime error in + * the debug build of ODE. + * + * @param geom the geom to query. + * @param result a copy of the rotation quaternion. + * @sa dBodyGetQuaternion + * @ingroup collide + */ +ODE_API void dGeomGetQuaternion (dGeomID geom, dQuaternion result); + + +/** + * @brief Return the axis-aligned bounding box. + * + * Return in aabb an axis aligned bounding box that surrounds the given geom. + * The aabb array has elements (minx, maxx, miny, maxy, minz, maxz). If the + * geom is a space, a bounding box that surrounds all contained geoms is + * returned. + * + * This function may return a pre-computed cached bounding box, if it can + * determine that the geom has not moved since the last time the bounding + * box was computed. + * + * @param geom the geom to query + * @param aabb the returned bounding box + * @ingroup collide + */ +ODE_API void dGeomGetAABB (dGeomID geom, dReal aabb[6]); + + +/** + * @brief Determing if a geom is a space. + * @param geom the geom to query + * @returns Non-zero if the geom is a space, zero otherwise. + * @ingroup collide + */ +ODE_API int dGeomIsSpace (dGeomID geom); + + +/** + * @brief Query for the space containing a particular geom. + * @param geom the geom to query + * @returns The space that contains the geom, or NULL if the geom is + * not contained by a space. + * @ingroup collide + */ +ODE_API dSpaceID dGeomGetSpace (dGeomID); + + +/** + * @brief Given a geom, this returns its class. + * + * The ODE classes are: + * @li dSphereClass + * @li dBoxClass + * @li dCylinderClass + * @li dPlaneClass + * @li dRayClass + * @li dConvexClass + * @li dGeomTransformClass + * @li dTriMeshClass + * @li dSimpleSpaceClass + * @li dHashSpaceClass + * @li dQuadTreeSpaceClass + * @li dFirstUserClass + * @li dLastUserClass + * + * User-defined class will return their own number. + * + * @param geom the geom to query + * @returns The geom class ID. + * @ingroup collide + */ +ODE_API int dGeomGetClass (dGeomID geom); + + +/** + * @brief Set the "category" bitfield for the given geom. + * + * The category bitfield is used by spaces to govern which geoms will + * interact with each other. The bitfield is guaranteed to be at least + * 32 bits wide. The default category values for newly created geoms + * have all bits set. + * + * @param geom the geom to set + * @param bits the new bitfield value + * @ingroup collide + */ +ODE_API void dGeomSetCategoryBits (dGeomID geom, unsigned long bits); + + +/** + * @brief Set the "collide" bitfield for the given geom. + * + * The collide bitfield is used by spaces to govern which geoms will + * interact with each other. The bitfield is guaranteed to be at least + * 32 bits wide. The default category values for newly created geoms + * have all bits set. + * + * @param geom the geom to set + * @param bits the new bitfield value + * @ingroup collide + */ +ODE_API void dGeomSetCollideBits (dGeomID geom, unsigned long bits); + + +/** + * @brief Get the "category" bitfield for the given geom. + * + * @param geom the geom to set + * @param bits the new bitfield value + * @sa dGeomSetCategoryBits + * @ingroup collide + */ +ODE_API unsigned long dGeomGetCategoryBits (dGeomID); + + +/** + * @brief Get the "collide" bitfield for the given geom. + * + * @param geom the geom to set + * @param bits the new bitfield value + * @sa dGeomSetCollideBits + * @ingroup collide + */ +ODE_API unsigned long dGeomGetCollideBits (dGeomID); + + +/** + * @brief Enable a geom. + * + * Disabled geoms are completely ignored by dSpaceCollide and dSpaceCollide2, + * although they can still be members of a space. New geoms are created in + * the enabled state. + * + * @param geom the geom to enable + * @sa dGeomDisable + * @sa dGeomIsEnabled + * @ingroup collide + */ +ODE_API void dGeomEnable (dGeomID geom); + + +/** + * @brief Disable a geom. + * + * Disabled geoms are completely ignored by dSpaceCollide and dSpaceCollide2, + * although they can still be members of a space. New geoms are created in + * the enabled state. + * + * @param geom the geom to disable + * @sa dGeomDisable + * @sa dGeomIsEnabled + * @ingroup collide + */ +ODE_API void dGeomDisable (dGeomID geom); + + +/** + * @brief Check to see if a geom is enabled. + * + * Disabled geoms are completely ignored by dSpaceCollide and dSpaceCollide2, + * although they can still be members of a space. New geoms are created in + * the enabled state. + * + * @param geom the geom to query + * @returns Non-zero if the geom is enabled, zero otherwise. + * @sa dGeomDisable + * @sa dGeomIsEnabled + * @ingroup collide + */ +ODE_API int dGeomIsEnabled (dGeomID geom); + + +enum +{ + dGeomCommonControlClass = 0, + dGeomColliderControlClass = 1 +}; + +enum +{ + dGeomCommonAnyControlCode = 0, + + dGeomColliderSetMergeSphereContactsControlCode = 1, + dGeomColliderGetMergeSphereContactsControlCode = 2 +}; + +enum +{ + dGeomColliderMergeContactsValue__Default = 0, /* Used with Set... to restore default value*/ + dGeomColliderMergeContactsValue_None = 1, + dGeomColliderMergeContactsValue_Normals = 2, + dGeomColliderMergeContactsValue_Full = 3 +}; + +/** + * @brief Execute low level control operation for geometry. + * + * The variable the dataSize points to must be initialized before the call. + * If the size does not match the one expected for the control class/code function + * changes it to the size expected and returns failure. This implies the function + * can be called with NULL data and zero size to test if control class/code is supported + * and obtain required data size for it. + * + * dGeomCommonAnyControlCode applies to any control class and returns success if + * at least one control code is available for the given class with given geom. + * + * Currently there are the folliwing control classes supported: + * @li dGeomColliderControlClass + * + * For dGeomColliderControlClass there are the following codes available: + * @li dGeomColliderSetMergeSphereContactsControlCode (arg of type int, dGeomColliderMergeContactsValue_*) + * @li dGeomColliderGetMergeSphereContactsControlCode (arg of type int, dGeomColliderMergeContactsValue_*) + * + * @param geom the geom to control + * @param controlClass the control class + * @param controlCode the control code for the class + * @param dataValue the control argument pointer + * @param dataSize the control argument size provided or expected + * @returns Boolean execution status + * @ingroup collide + */ +ODE_API int dGeomLowLevelControl (dGeomID geom, int controlClass, int controlCode, void *dataValue, int *dataSize); + + +/** + * @brief Get world position of a relative point on geom. + * + * Calling this function on a non-placeable geom results in the same point being + * returned. + * + * @ingroup collide + * @param result will contain the result. + */ +ODE_API void dGeomGetRelPointPos +( + dGeomID geom, dReal px, dReal py, dReal pz, + dVector3 result +); + +/** + * @brief takes a point in global coordinates and returns + * the point's position in geom-relative coordinates. + * + * Calling this function on a non-placeable geom results in the same point being + * returned. + * + * @remarks + * This is the inverse of dGeomGetRelPointPos() + * @ingroup collide + * @param result will contain the result. + */ +ODE_API void dGeomGetPosRelPoint +( + dGeomID geom, dReal px, dReal py, dReal pz, + dVector3 result +); + +/** + * @brief Convert from geom-local to world coordinates. + * + * Calling this function on a non-placeable geom results in the same vector being + * returned. + * + * @ingroup collide + * @param result will contain the result. + */ +ODE_API void dGeomVectorToWorld +( + dGeomID geom, dReal px, dReal py, dReal pz, + dVector3 result +); + +/** + * @brief Convert from world to geom-local coordinates. + * + * Calling this function on a non-placeable geom results in the same vector being + * returned. + * + * @ingroup collide + * @param result will contain the result. + */ +ODE_API void dGeomVectorFromWorld +( + dGeomID geom, dReal px, dReal py, dReal pz, + dVector3 result +); + + +/* ************************************************************************ */ +/* geom offset from body */ + +/** + * @brief Set the local offset position of a geom from its body. + * + * Sets the geom's positional offset in local coordinates. + * After this call, the geom will be at a new position determined from the + * body's position and the offset. + * The geom must be attached to a body. + * If the geom did not have an offset, it is automatically created. + * + * @param geom the geom to set. + * @param x the new X coordinate. + * @param y the new Y coordinate. + * @param z the new Z coordinate. + * @ingroup collide + */ +ODE_API void dGeomSetOffsetPosition (dGeomID geom, dReal x, dReal y, dReal z); + + +/** + * @brief Set the local offset rotation matrix of a geom from its body. + * + * Sets the geom's rotational offset in local coordinates. + * After this call, the geom will be at a new position determined from the + * body's position and the offset. + * The geom must be attached to a body. + * If the geom did not have an offset, it is automatically created. + * + * @param geom the geom to set. + * @param R the new rotation matrix. + * @ingroup collide + */ +ODE_API void dGeomSetOffsetRotation (dGeomID geom, const dMatrix3 R); + + +/** + * @brief Set the local offset rotation of a geom from its body. + * + * Sets the geom's rotational offset in local coordinates. + * After this call, the geom will be at a new position determined from the + * body's position and the offset. + * The geom must be attached to a body. + * If the geom did not have an offset, it is automatically created. + * + * @param geom the geom to set. + * @param Q the new rotation. + * @ingroup collide + */ +ODE_API void dGeomSetOffsetQuaternion (dGeomID geom, const dQuaternion Q); + + +/** + * @brief Set the offset position of a geom from its body. + * + * Sets the geom's positional offset to move it to the new world + * coordinates. + * After this call, the geom will be at the world position passed in, + * and the offset will be the difference from the current body position. + * The geom must be attached to a body. + * If the geom did not have an offset, it is automatically created. + * + * @param geom the geom to set. + * @param x the new X coordinate. + * @param y the new Y coordinate. + * @param z the new Z coordinate. + * @ingroup collide + */ +ODE_API void dGeomSetOffsetWorldPosition (dGeomID geom, dReal x, dReal y, dReal z); + + +/** + * @brief Set the offset rotation of a geom from its body. + * + * Sets the geom's rotational offset to orient it to the new world + * rotation matrix. + * After this call, the geom will be at the world orientation passed in, + * and the offset will be the difference from the current body orientation. + * The geom must be attached to a body. + * If the geom did not have an offset, it is automatically created. + * + * @param geom the geom to set. + * @param R the new rotation matrix. + * @ingroup collide + */ +ODE_API void dGeomSetOffsetWorldRotation (dGeomID geom, const dMatrix3 R); + + +/** + * @brief Set the offset rotation of a geom from its body. + * + * Sets the geom's rotational offset to orient it to the new world + * rotation matrix. + * After this call, the geom will be at the world orientation passed in, + * and the offset will be the difference from the current body orientation. + * The geom must be attached to a body. + * If the geom did not have an offset, it is automatically created. + * + * @param geom the geom to set. + * @param Q the new rotation. + * @ingroup collide + */ +ODE_API void dGeomSetOffsetWorldQuaternion (dGeomID geom, const dQuaternion); + + +/** + * @brief Clear any offset from the geom. + * + * If the geom has an offset, it is eliminated and the geom is + * repositioned at the body's position. If the geom has no offset, + * this function does nothing. + * This is more efficient than calling dGeomSetOffsetPosition(zero) + * and dGeomSetOffsetRotation(identiy), because this function actually + * eliminates the offset, rather than leaving it as the identity transform. + * + * @param geom the geom to have its offset destroyed. + * @ingroup collide + */ +ODE_API void dGeomClearOffset(dGeomID geom); + + +/** + * @brief Check to see whether the geom has an offset. + * + * This function will return non-zero if the offset has been created. + * Note that there is a difference between a geom with no offset, + * and a geom with an offset that is the identity transform. + * In the latter case, although the observed behaviour is identical, + * there is a unnecessary computation involved because the geom will + * be applying the transform whenever it needs to recalculate its world + * position. + * + * @param geom the geom to query. + * @returns Non-zero if the geom has an offset, zero otherwise. + * @ingroup collide + */ +ODE_API int dGeomIsOffset(dGeomID geom); + + +/** + * @brief Get the offset position vector of a geom. + * + * Returns the positional offset of the geom in local coordinates. + * If the geom has no offset, this function returns the zero vector. + * + * @param geom the geom to query. + * @returns A pointer to the geom's offset vector. + * @remarks The returned value is a pointer to the geom's internal + * data structure. It is valid until any changes are made + * to the geom. + * @ingroup collide + */ +ODE_API const dReal * dGeomGetOffsetPosition (dGeomID geom); + + +/** + * @brief Copy the offset position vector of a geom. + * + * Returns the positional offset of the geom in local coordinates. + * If the geom has no offset, this function returns the zero vector. + * + * @param geom the geom to query. + * @param pos returns the offset position + * @ingroup collide + */ +ODE_API void dGeomCopyOffsetPosition (dGeomID geom, dVector3 pos); + + +/** + * @brief Get the offset rotation matrix of a geom. + * + * Returns the rotational offset of the geom in local coordinates. + * If the geom has no offset, this function returns the identity + * matrix. + * + * @param geom the geom to query. + * @returns A pointer to the geom's offset rotation matrix. + * @remarks The returned value is a pointer to the geom's internal + * data structure. It is valid until any changes are made + * to the geom. + * @ingroup collide + */ +ODE_API const dReal * dGeomGetOffsetRotation (dGeomID geom); + + +/** + * @brief Copy the offset rotation matrix of a geom. + * + * Returns the rotational offset of the geom in local coordinates. + * If the geom has no offset, this function returns the identity + * matrix. + * + * @param geom the geom to query. + * @param R returns the rotation matrix. + * @ingroup collide + */ +ODE_API void dGeomCopyOffsetRotation (dGeomID geom, dMatrix3 R); + + +/** + * @brief Get the offset rotation quaternion of a geom. + * + * Returns the rotation offset of the geom as a quaternion. + * If the geom has no offset, the identity quaternion is returned. + * + * @param geom the geom to query. + * @param result a copy of the rotation quaternion. + * @ingroup collide + */ +ODE_API void dGeomGetOffsetQuaternion (dGeomID geom, dQuaternion result); + + +/* ************************************************************************ */ +/* collision detection */ + +/* + * Just generate any contacts (disables any contact refining). + */ +#define CONTACTS_UNIMPORTANT 0x80000000 + +/** + * + * @brief Given two geoms o1 and o2 that potentially intersect, + * generate contact information for them. + * + * Internally, this just calls the correct class-specific collision + * functions for o1 and o2. + * + * @param o1 The first geom to test. + * @param o2 The second geom to test. + * + * @param flags The flags specify how contacts should be generated if + * the geoms touch. The lower 16 bits of flags is an integer that + * specifies the maximum number of contact points to generate. You must + * ask for at least one contact. + * Additionally, following bits may be set: + * CONTACTS_UNIMPORTANT -- just generate any contacts (skip contact refining). + * All other bits in flags must be set to zero. In the future the other bits + * may be used to select from different contact generation strategies. + * + * @param contact Points to an array of dContactGeom structures. The array + * must be able to hold at least the maximum number of contacts. These + * dContactGeom structures may be embedded within larger structures in the + * array -- the skip parameter is the byte offset from one dContactGeom to + * the next in the array. If skip is sizeof(dContactGeom) then contact + * points to a normal (C-style) array. It is an error for skip to be smaller + * than sizeof(dContactGeom). + * + * @returns If the geoms intersect, this function returns the number of contact + * points generated (and updates the contact array), otherwise it returns 0 + * (and the contact array is not touched). + * + * @remarks If a space is passed as o1 or o2 then this function will collide + * all objects contained in o1 with all objects contained in o2, and return + * the resulting contact points. This method for colliding spaces with geoms + * (or spaces with spaces) provides no user control over the individual + * collisions. To get that control, use dSpaceCollide or dSpaceCollide2 instead. + * + * @remarks If o1 and o2 are the same geom then this function will do nothing + * and return 0. Technically speaking an object intersects with itself, but it + * is not useful to find contact points in this case. + * + * @remarks This function does not care if o1 and o2 are in the same space or not + * (or indeed if they are in any space at all). + * + * @ingroup collide + */ +ODE_API int dCollide (dGeomID o1, dGeomID o2, int flags, dContactGeom *contact, + int skip); + +/** + * @brief Determines which pairs of geoms in a space may potentially intersect, + * and calls the callback function for each candidate pair. + * + * @param space The space to test. + * + * @param data Passed from dSpaceCollide directly to the callback + * function. Its meaning is user defined. The o1 and o2 arguments are the + * geoms that may be near each other. + * + * @param callback A callback function is of type @ref dNearCallback. + * + * @remarks Other spaces that are contained within the colliding space are + * not treated specially, i.e. they are not recursed into. The callback + * function may be passed these contained spaces as one or both geom + * arguments. + * + * @remarks dSpaceCollide() is guaranteed to pass all intersecting geom + * pairs to the callback function, but may also pass close but + * non-intersecting pairs. The number of these calls depends on the + * internal algorithms used by the space. Thus you should not expect + * that dCollide will return contacts for every pair passed to the + * callback. + * + * @sa dSpaceCollide2 + * @ingroup collide + */ +ODE_API void dSpaceCollide (dSpaceID space, void *data, dNearCallback *callback); + + +/** + * @brief Determines which geoms from one space may potentially intersect with + * geoms from another space, and calls the callback function for each candidate + * pair. + * + * @param space1 The first space to test. + * + * @param space2 The second space to test. + * + * @param data Passed from dSpaceCollide directly to the callback + * function. Its meaning is user defined. The o1 and o2 arguments are the + * geoms that may be near each other. + * + * @param callback A callback function is of type @ref dNearCallback. + * + * @remarks This function can also test a single non-space geom against a + * space. This function is useful when there is a collision hierarchy, i.e. + * when there are spaces that contain other spaces. + * + * @remarks Other spaces that are contained within the colliding space are + * not treated specially, i.e. they are not recursed into. The callback + * function may be passed these contained spaces as one or both geom + * arguments. + * + * @remarks Sublevel value of space affects how the spaces are iterated. + * Both spaces are recursed only if their sublevels match. Otherwise, only + * the space with greater sublevel is recursed and the one with lesser sublevel + * is used as a geom itself. + * + * @remarks dSpaceCollide2() is guaranteed to pass all intersecting geom + * pairs to the callback function, but may also pass close but + * non-intersecting pairs. The number of these calls depends on the + * internal algorithms used by the space. Thus you should not expect + * that dCollide will return contacts for every pair passed to the + * callback. + * + * @sa dSpaceCollide + * @sa dSpaceSetSublevel + * @ingroup collide + */ +ODE_API void dSpaceCollide2 (dGeomID space1, dGeomID space2, void *data, dNearCallback *callback); + + +/* ************************************************************************ */ +/* standard classes */ + +/* the maximum number of user classes that are supported */ +enum { + dMaxUserClasses = 4 +}; + +/* class numbers - each geometry object needs a unique number */ +enum { + dSphereClass = 0, + dBoxClass, + dCapsuleClass, + dCylinderClass, + dPlaneClass, + dRayClass, + dConvexClass, + dGeomTransformClass, + dTriMeshClass, + dHeightfieldClass, + + dFirstSpaceClass, + dSimpleSpaceClass = dFirstSpaceClass, + dHashSpaceClass, + dSweepAndPruneSpaceClass, /* SAP */ + dQuadTreeSpaceClass, + dLastSpaceClass = dQuadTreeSpaceClass, + + dFirstUserClass, + dLastUserClass = dFirstUserClass + dMaxUserClasses - 1, + dGeomNumClasses +}; + + +/** + * @defgroup collide_sphere Sphere Class + * @ingroup collide + */ + +/** + * @brief Create a sphere geom of the given radius, and return its ID. + * + * @param space a space to contain the new geom. May be null. + * @param radius the radius of the sphere. + * + * @returns A new sphere geom. + * + * @remarks The point of reference for a sphere is its center. + * + * @sa dGeomDestroy + * @sa dGeomSphereSetRadius + * @ingroup collide_sphere + */ +ODE_API dGeomID dCreateSphere (dSpaceID space, dReal radius); + + +/** + * @brief Set the radius of a sphere geom. + * + * @param sphere the sphere to set. + * @param radius the new radius. + * + * @sa dGeomSphereGetRadius + * @ingroup collide_sphere + */ +ODE_API void dGeomSphereSetRadius (dGeomID sphere, dReal radius); + + +/** + * @brief Retrieves the radius of a sphere geom. + * + * @param sphere the sphere to query. + * + * @sa dGeomSphereSetRadius + * @ingroup collide_sphere + */ +ODE_API dReal dGeomSphereGetRadius (dGeomID sphere); + + +/** + * @brief Calculate the depth of the a given point within a sphere. + * + * @param sphere the sphere to query. + * @param x the X coordinate of the point. + * @param y the Y coordinate of the point. + * @param z the Z coordinate of the point. + * + * @returns The depth of the point. Points inside the sphere will have a + * positive depth, points outside it will have a negative depth, and points + * on the surface will have a depth of zero. + * + * @ingroup collide_sphere + */ +ODE_API dReal dGeomSpherePointDepth (dGeomID sphere, dReal x, dReal y, dReal z); + + +/*--> Convex Functions*/ +ODE_API dGeomID dCreateConvex (dSpaceID space, + const dReal *_planes, + unsigned int _planecount, + const dReal *_points, + unsigned int _pointcount, + const unsigned int *_polygons); + +ODE_API void dGeomSetConvex (dGeomID g, + const dReal *_planes, + unsigned int _count, + const dReal *_points, + unsigned int _pointcount, + const unsigned int *_polygons); +/*<-- Convex Functions*/ + +/** + * @defgroup collide_box Box Class + * @ingroup collide + */ + +/** + * @brief Create a box geom with the provided side lengths. + * + * @param space a space to contain the new geom. May be null. + * @param lx the length of the box along the X axis + * @param ly the length of the box along the Y axis + * @param lz the length of the box along the Z axis + * + * @returns A new box geom. + * + * @remarks The point of reference for a box is its center. + * + * @sa dGeomDestroy + * @sa dGeomBoxSetLengths + * @ingroup collide_box + */ +ODE_API dGeomID dCreateBox (dSpaceID space, dReal lx, dReal ly, dReal lz); + + +/** + * @brief Set the side lengths of the given box. + * + * @param box the box to set + * @param lx the length of the box along the X axis + * @param ly the length of the box along the Y axis + * @param lz the length of the box along the Z axis + * + * @sa dGeomBoxGetLengths + * @ingroup collide_box + */ +ODE_API void dGeomBoxSetLengths (dGeomID box, dReal lx, dReal ly, dReal lz); + + +/** + * @brief Get the side lengths of a box. + * + * @param box the box to query + * @param result the returned side lengths + * + * @sa dGeomBoxSetLengths + * @ingroup collide_box + */ +ODE_API void dGeomBoxGetLengths (dGeomID box, dVector3 result); + + +/** + * @brief Return the depth of a point in a box. + * + * @param box the box to query + * @param x the X coordinate of the point to test. + * @param y the Y coordinate of the point to test. + * @param z the Z coordinate of the point to test. + * + * @returns The depth of the point. Points inside the box will have a + * positive depth, points outside it will have a negative depth, and points + * on the surface will have a depth of zero. + */ +ODE_API dReal dGeomBoxPointDepth (dGeomID box, dReal x, dReal y, dReal z); + + +ODE_API dGeomID dCreatePlane (dSpaceID space, dReal a, dReal b, dReal c, dReal d); +ODE_API void dGeomPlaneSetParams (dGeomID plane, dReal a, dReal b, dReal c, dReal d); +ODE_API void dGeomPlaneGetParams (dGeomID plane, dVector4 result); +ODE_API dReal dGeomPlanePointDepth (dGeomID plane, dReal x, dReal y, dReal z); + +ODE_API dGeomID dCreateCapsule (dSpaceID space, dReal radius, dReal length); +ODE_API void dGeomCapsuleSetParams (dGeomID ccylinder, dReal radius, dReal length); +ODE_API void dGeomCapsuleGetParams (dGeomID ccylinder, dReal *radius, dReal *length); +ODE_API dReal dGeomCapsulePointDepth (dGeomID ccylinder, dReal x, dReal y, dReal z); + +/* For now we want to have a backwards compatible C-API, note: C++ API is not.*/ +#define dCreateCCylinder dCreateCapsule +#define dGeomCCylinderSetParams dGeomCapsuleSetParams +#define dGeomCCylinderGetParams dGeomCapsuleGetParams +#define dGeomCCylinderPointDepth dGeomCapsulePointDepth +#define dCCylinderClass dCapsuleClass + +ODE_API dGeomID dCreateCylinder (dSpaceID space, dReal radius, dReal length); +ODE_API void dGeomCylinderSetParams (dGeomID cylinder, dReal radius, dReal length); +ODE_API void dGeomCylinderGetParams (dGeomID cylinder, dReal *radius, dReal *length); + +ODE_API dGeomID dCreateRay (dSpaceID space, dReal length); +ODE_API void dGeomRaySetLength (dGeomID ray, dReal length); +ODE_API dReal dGeomRayGetLength (dGeomID ray); +ODE_API void dGeomRaySet (dGeomID ray, dReal px, dReal py, dReal pz, + dReal dx, dReal dy, dReal dz); +ODE_API void dGeomRayGet (dGeomID ray, dVector3 start, dVector3 dir); + +/* + * Set/get ray flags that influence ray collision detection. + * These flags are currently only noticed by the trimesh collider, because + * they can make a major differences there. + */ +ODE_API_DEPRECATED ODE_API void dGeomRaySetParams (dGeomID g, int FirstContact, int BackfaceCull); +ODE_API_DEPRECATED ODE_API void dGeomRayGetParams (dGeomID g, int *FirstContact, int *BackfaceCull); +ODE_API void dGeomRaySetFirstContact (dGeomID g, int firstContact); +ODE_API int dGeomRayGetFirstContact (dGeomID g); +ODE_API void dGeomRaySetBackfaceCull (dGeomID g, int backfaceCull); +ODE_API int dGeomRayGetBackfaceCull (dGeomID g); +ODE_API void dGeomRaySetClosestHit (dGeomID g, int closestHit); +ODE_API int dGeomRayGetClosestHit (dGeomID g); + +#include "collision_trimesh.h" + +ODE_API_DEPRECATED ODE_API dGeomID dCreateGeomTransform (dSpaceID space); +ODE_API_DEPRECATED ODE_API void dGeomTransformSetGeom (dGeomID g, dGeomID obj); +ODE_API_DEPRECATED ODE_API dGeomID dGeomTransformGetGeom (dGeomID g); +ODE_API_DEPRECATED ODE_API void dGeomTransformSetCleanup (dGeomID g, int mode); +ODE_API_DEPRECATED ODE_API int dGeomTransformGetCleanup (dGeomID g); +ODE_API_DEPRECATED ODE_API void dGeomTransformSetInfo (dGeomID g, int mode); +ODE_API_DEPRECATED ODE_API int dGeomTransformGetInfo (dGeomID g); + + +/* ************************************************************************ */ +/* heightfield functions */ + + +/* Data storage for heightfield data.*/ +struct dxHeightfieldData; +typedef struct dxHeightfieldData* dHeightfieldDataID; + + +/** + * @brief Callback prototype + * + * Used by the callback heightfield data type to sample a height for a + * given cell position. + * + * @param p_user_data User data specified when creating the dHeightfieldDataID + * @param x The index of a sample in the local x axis. It is a value + * in the range zero to ( nWidthSamples - 1 ). + * @param x The index of a sample in the local z axis. It is a value + * in the range zero to ( nDepthSamples - 1 ). + * + * @return The sample height which is then scaled and offset using the + * values specified when the heightfield data was created. + * + * @ingroup collide + */ +typedef dReal dHeightfieldGetHeight( void* p_user_data, int x, int z ); + + + +/** + * @brief Creates a heightfield geom. + * + * Uses the information in the given dHeightfieldDataID to construct + * a geom representing a heightfield in a collision space. + * + * @param space The space to add the geom to. + * @param data The dHeightfieldDataID created by dGeomHeightfieldDataCreate and + * setup by dGeomHeightfieldDataBuildCallback, dGeomHeightfieldDataBuildByte, + * dGeomHeightfieldDataBuildShort or dGeomHeightfieldDataBuildFloat. + * @param bPlaceable If non-zero this geom can be transformed in the world using the + * usual functions such as dGeomSetPosition and dGeomSetRotation. If the geom is + * not set as placeable, then it uses a fixed orientation where the global y axis + * represents the dynamic 'height' of the heightfield. + * + * @return A geom id to reference this geom in other calls. + * + * @ingroup collide + */ +ODE_API dGeomID dCreateHeightfield( dSpaceID space, + dHeightfieldDataID data, int bPlaceable ); + + +/** + * @brief Creates a new empty dHeightfieldDataID. + * + * Allocates a new dHeightfieldDataID and returns it. You must call + * dGeomHeightfieldDataDestroy to destroy it after the geom has been removed. + * The dHeightfieldDataID value is used when specifying a data format type. + * + * @return A dHeightfieldDataID for use with dGeomHeightfieldDataBuildCallback, + * dGeomHeightfieldDataBuildByte, dGeomHeightfieldDataBuildShort or + * dGeomHeightfieldDataBuildFloat. + * @ingroup collide + */ +ODE_API dHeightfieldDataID dGeomHeightfieldDataCreate(void); + + +/** + * @brief Destroys a dHeightfieldDataID. + * + * Deallocates a given dHeightfieldDataID and all managed resources. + * + * @param d A dHeightfieldDataID created by dGeomHeightfieldDataCreate + * @ingroup collide + */ +ODE_API void dGeomHeightfieldDataDestroy( dHeightfieldDataID d ); + + + +/** + * @brief Configures a dHeightfieldDataID to use a callback to + * retrieve height data. + * + * Before a dHeightfieldDataID can be used by a geom it must be + * configured to specify the format of the height data. + * This call specifies that the heightfield data is computed by + * the user and it should use the given callback when determining + * the height of a given element of it's shape. + * + * @param d A new dHeightfieldDataID created by dGeomHeightfieldDataCreate + * + * @param width Specifies the total 'width' of the heightfield along + * the geom's local x axis. + * @param depth Specifies the total 'depth' of the heightfield along + * the geom's local z axis. + * + * @param widthSamples Specifies the number of vertices to sample + * along the width of the heightfield. Each vertex has a corresponding + * height value which forms the overall shape. + * Naturally this value must be at least two or more. + * @param depthSamples Specifies the number of vertices to sample + * along the depth of the heightfield. + * + * @param scale A uniform scale applied to all raw height data. + * @param offset An offset applied to the scaled height data. + * + * @param thickness A value subtracted from the lowest height + * value which in effect adds an additional cuboid to the base of the + * heightfield. This is used to prevent geoms from looping under the + * desired terrain and not registering as a collision. Note that the + * thickness is not affected by the scale or offset parameters. + * + * @param bWrap If non-zero the heightfield will infinitely tile in both + * directions along the local x and z axes. If zero the heightfield is + * bounded from zero to width in the local x axis, and zero to depth in + * the local z axis. + * + * @ingroup collide + */ +ODE_API void dGeomHeightfieldDataBuildCallback( dHeightfieldDataID d, + void* pUserData, dHeightfieldGetHeight* pCallback, + dReal width, dReal depth, int widthSamples, int depthSamples, + dReal scale, dReal offset, dReal thickness, int bWrap ); + +/** + * @brief Configures a dHeightfieldDataID to use height data in byte format. + * + * Before a dHeightfieldDataID can be used by a geom it must be + * configured to specify the format of the height data. + * This call specifies that the heightfield data is stored as a rectangular + * array of bytes (8 bit unsigned) representing the height at each sample point. + * + * @param d A new dHeightfieldDataID created by dGeomHeightfieldDataCreate + * + * @param pHeightData A pointer to the height data. + * @param bCopyHeightData When non-zero the height data is copied to an + * internal store. When zero the height data is accessed by reference and + * so must persist throughout the lifetime of the heightfield. + * + * @param width Specifies the total 'width' of the heightfield along + * the geom's local x axis. + * @param depth Specifies the total 'depth' of the heightfield along + * the geom's local z axis. + * + * @param widthSamples Specifies the number of vertices to sample + * along the width of the heightfield. Each vertex has a corresponding + * height value which forms the overall shape. + * Naturally this value must be at least two or more. + * @param depthSamples Specifies the number of vertices to sample + * along the depth of the heightfield. + * + * @param scale A uniform scale applied to all raw height data. + * @param offset An offset applied to the scaled height data. + * + * @param thickness A value subtracted from the lowest height + * value which in effect adds an additional cuboid to the base of the + * heightfield. This is used to prevent geoms from looping under the + * desired terrain and not registering as a collision. Note that the + * thickness is not affected by the scale or offset parameters. + * + * @param bWrap If non-zero the heightfield will infinitely tile in both + * directions along the local x and z axes. If zero the heightfield is + * bounded from zero to width in the local x axis, and zero to depth in + * the local z axis. + * + * @ingroup collide + */ +ODE_API void dGeomHeightfieldDataBuildByte( dHeightfieldDataID d, + const unsigned char* pHeightData, int bCopyHeightData, + dReal width, dReal depth, int widthSamples, int depthSamples, + dReal scale, dReal offset, dReal thickness, int bWrap ); + +/** + * @brief Configures a dHeightfieldDataID to use height data in short format. + * + * Before a dHeightfieldDataID can be used by a geom it must be + * configured to specify the format of the height data. + * This call specifies that the heightfield data is stored as a rectangular + * array of shorts (16 bit signed) representing the height at each sample point. + * + * @param d A new dHeightfieldDataID created by dGeomHeightfieldDataCreate + * + * @param pHeightData A pointer to the height data. + * @param bCopyHeightData When non-zero the height data is copied to an + * internal store. When zero the height data is accessed by reference and + * so must persist throughout the lifetime of the heightfield. + * + * @param width Specifies the total 'width' of the heightfield along + * the geom's local x axis. + * @param depth Specifies the total 'depth' of the heightfield along + * the geom's local z axis. + * + * @param widthSamples Specifies the number of vertices to sample + * along the width of the heightfield. Each vertex has a corresponding + * height value which forms the overall shape. + * Naturally this value must be at least two or more. + * @param depthSamples Specifies the number of vertices to sample + * along the depth of the heightfield. + * + * @param scale A uniform scale applied to all raw height data. + * @param offset An offset applied to the scaled height data. + * + * @param thickness A value subtracted from the lowest height + * value which in effect adds an additional cuboid to the base of the + * heightfield. This is used to prevent geoms from looping under the + * desired terrain and not registering as a collision. Note that the + * thickness is not affected by the scale or offset parameters. + * + * @param bWrap If non-zero the heightfield will infinitely tile in both + * directions along the local x and z axes. If zero the heightfield is + * bounded from zero to width in the local x axis, and zero to depth in + * the local z axis. + * + * @ingroup collide + */ +ODE_API void dGeomHeightfieldDataBuildShort( dHeightfieldDataID d, + const short* pHeightData, int bCopyHeightData, + dReal width, dReal depth, int widthSamples, int depthSamples, + dReal scale, dReal offset, dReal thickness, int bWrap ); + +/** + * @brief Configures a dHeightfieldDataID to use height data in + * single precision floating point format. + * + * Before a dHeightfieldDataID can be used by a geom it must be + * configured to specify the format of the height data. + * This call specifies that the heightfield data is stored as a rectangular + * array of single precision floats representing the height at each + * sample point. + * + * @param d A new dHeightfieldDataID created by dGeomHeightfieldDataCreate + * + * @param pHeightData A pointer to the height data. + * @param bCopyHeightData When non-zero the height data is copied to an + * internal store. When zero the height data is accessed by reference and + * so must persist throughout the lifetime of the heightfield. + * + * @param width Specifies the total 'width' of the heightfield along + * the geom's local x axis. + * @param depth Specifies the total 'depth' of the heightfield along + * the geom's local z axis. + * + * @param widthSamples Specifies the number of vertices to sample + * along the width of the heightfield. Each vertex has a corresponding + * height value which forms the overall shape. + * Naturally this value must be at least two or more. + * @param depthSamples Specifies the number of vertices to sample + * along the depth of the heightfield. + * + * @param scale A uniform scale applied to all raw height data. + * @param offset An offset applied to the scaled height data. + * + * @param thickness A value subtracted from the lowest height + * value which in effect adds an additional cuboid to the base of the + * heightfield. This is used to prevent geoms from looping under the + * desired terrain and not registering as a collision. Note that the + * thickness is not affected by the scale or offset parameters. + * + * @param bWrap If non-zero the heightfield will infinitely tile in both + * directions along the local x and z axes. If zero the heightfield is + * bounded from zero to width in the local x axis, and zero to depth in + * the local z axis. + * + * @ingroup collide + */ +ODE_API void dGeomHeightfieldDataBuildSingle( dHeightfieldDataID d, + const float* pHeightData, int bCopyHeightData, + dReal width, dReal depth, int widthSamples, int depthSamples, + dReal scale, dReal offset, dReal thickness, int bWrap ); + +/** + * @brief Configures a dHeightfieldDataID to use height data in + * double precision floating point format. + * + * Before a dHeightfieldDataID can be used by a geom it must be + * configured to specify the format of the height data. + * This call specifies that the heightfield data is stored as a rectangular + * array of double precision floats representing the height at each + * sample point. + * + * @param d A new dHeightfieldDataID created by dGeomHeightfieldDataCreate + * + * @param pHeightData A pointer to the height data. + * @param bCopyHeightData When non-zero the height data is copied to an + * internal store. When zero the height data is accessed by reference and + * so must persist throughout the lifetime of the heightfield. + * + * @param width Specifies the total 'width' of the heightfield along + * the geom's local x axis. + * @param depth Specifies the total 'depth' of the heightfield along + * the geom's local z axis. + * + * @param widthSamples Specifies the number of vertices to sample + * along the width of the heightfield. Each vertex has a corresponding + * height value which forms the overall shape. + * Naturally this value must be at least two or more. + * @param depthSamples Specifies the number of vertices to sample + * along the depth of the heightfield. + * + * @param scale A uniform scale applied to all raw height data. + * @param offset An offset applied to the scaled height data. + * + * @param thickness A value subtracted from the lowest height + * value which in effect adds an additional cuboid to the base of the + * heightfield. This is used to prevent geoms from looping under the + * desired terrain and not registering as a collision. Note that the + * thickness is not affected by the scale or offset parameters. + * + * @param bWrap If non-zero the heightfield will infinitely tile in both + * directions along the local x and z axes. If zero the heightfield is + * bounded from zero to width in the local x axis, and zero to depth in + * the local z axis. + * + * @ingroup collide + */ +ODE_API void dGeomHeightfieldDataBuildDouble( dHeightfieldDataID d, + const double* pHeightData, int bCopyHeightData, + dReal width, dReal depth, int widthSamples, int depthSamples, + dReal scale, dReal offset, dReal thickness, int bWrap ); + +/** + * @brief Manually set the minimum and maximum height bounds. + * + * This call allows you to set explicit min / max values after initial + * creation typically for callback heightfields which default to +/- infinity, + * or those whose data has changed. This must be set prior to binding with a + * geom, as the the AABB is not recomputed after it's first generation. + * + * @remarks The minimum and maximum values are used to compute the AABB + * for the heightfield which is used for early rejection of collisions. + * A close fit will yield a more efficient collision check. + * + * @param d A dHeightfieldDataID created by dGeomHeightfieldDataCreate + * @param min_height The new minimum height value. Scale, offset and thickness is then applied. + * @param max_height The new maximum height value. Scale and offset is then applied. + * @ingroup collide + */ +ODE_API void dGeomHeightfieldDataSetBounds( dHeightfieldDataID d, + dReal minHeight, dReal maxHeight ); + + +/** + * @brief Assigns a dHeightfieldDataID to a heightfield geom. + * + * Associates the given dHeightfieldDataID with a heightfield geom. + * This is done without affecting the GEOM_PLACEABLE flag. + * + * @param g A geom created by dCreateHeightfield + * @param d A dHeightfieldDataID created by dGeomHeightfieldDataCreate + * @ingroup collide + */ +ODE_API void dGeomHeightfieldSetHeightfieldData( dGeomID g, dHeightfieldDataID d ); + + +/** + * @brief Gets the dHeightfieldDataID bound to a heightfield geom. + * + * Returns the dHeightfieldDataID associated with a heightfield geom. + * + * @param g A geom created by dCreateHeightfield + * @return The dHeightfieldDataID which may be NULL if none was assigned. + * @ingroup collide + */ +ODE_API dHeightfieldDataID dGeomHeightfieldGetHeightfieldData( dGeomID g ); + + + +/* ************************************************************************ */ +/* utility functions */ + +ODE_API void dClosestLineSegmentPoints (const dVector3 a1, const dVector3 a2, + const dVector3 b1, const dVector3 b2, + dVector3 cp1, dVector3 cp2); + +ODE_API int dBoxTouchesBox (const dVector3 _p1, const dMatrix3 R1, + const dVector3 side1, const dVector3 _p2, + const dMatrix3 R2, const dVector3 side2); + +/* The meaning of flags parameter is the same as in dCollide()*/ +ODE_API int dBoxBox (const dVector3 p1, const dMatrix3 R1, + const dVector3 side1, const dVector3 p2, + const dMatrix3 R2, const dVector3 side2, + dVector3 normal, dReal *depth, int *return_code, + int flags, dContactGeom *contact, int skip); + +ODE_API void dInfiniteAABB (dGeomID geom, dReal aabb[6]); + + +/* ************************************************************************ */ +/* custom classes */ + +typedef void dGetAABBFn (dGeomID, dReal aabb[6]); +typedef int dColliderFn (dGeomID o1, dGeomID o2, + int flags, dContactGeom *contact, int skip); +typedef dColliderFn * dGetColliderFnFn (int num); +typedef void dGeomDtorFn (dGeomID o); +typedef int dAABBTestFn (dGeomID o1, dGeomID o2, dReal aabb[6]); + +typedef struct dGeomClass { + int bytes; + dGetColliderFnFn *collider; + dGetAABBFn *aabb; + dAABBTestFn *aabb_test; + dGeomDtorFn *dtor; +} dGeomClass; + +ODE_API int dCreateGeomClass (const dGeomClass *classptr); +ODE_API void * dGeomGetClassData (dGeomID); +ODE_API dGeomID dCreateGeom (int classnum); + +/** + * @brief Sets a custom collider function for two geom classes. + * + * @param i The first geom class handled by this collider + * @param j The second geom class handled by this collider + * @param fn The collider function to use to determine collisions. + * @ingroup collide + */ +ODE_API void dSetColliderOverride (int i, int j, dColliderFn *fn); + + +/* ************************************************************************ */ + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/libs/ode-0.16.1/include/ode/collision_space.h b/libs/ode-0.16.1/include/ode/collision_space.h new file mode 100644 index 0000000..30cc536 --- /dev/null +++ b/libs/ode-0.16.1/include/ode/collision_space.h @@ -0,0 +1,182 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001-2003 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#ifndef _ODE_COLLISION_SPACE_H_ +#define _ODE_COLLISION_SPACE_H_ + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +struct dContactGeom; + +/** + * @brief User callback for geom-geom collision testing. + * + * @param data The user data object, as passed to dSpaceCollide. + * @param o1 The first geom being tested. + * @param o2 The second geom being test. + * + * @remarks The callback function can call dCollide on o1 and o2 to generate + * contact points between each pair. Then these contact points may be added + * to the simulation as contact joints. The user's callback function can of + * course chose not to call dCollide for any pair, e.g. if the user decides + * that those pairs should not interact. + * + * @ingroup collide + */ +typedef void dNearCallback (void *data, dGeomID o1, dGeomID o2); + + +ODE_API dSpaceID dSimpleSpaceCreate (dSpaceID space); +ODE_API dSpaceID dHashSpaceCreate (dSpaceID space); +ODE_API dSpaceID dQuadTreeSpaceCreate (dSpaceID space, const dVector3 Center, const dVector3 Extents, int Depth); + + +/* SAP */ +/* Order XZY or ZXY usually works best, if your Y is up. */ +#define dSAP_AXES_XYZ ((0)|(1<<2)|(2<<4)) +#define dSAP_AXES_XZY ((0)|(2<<2)|(1<<4)) +#define dSAP_AXES_YXZ ((1)|(0<<2)|(2<<4)) +#define dSAP_AXES_YZX ((1)|(2<<2)|(0<<4)) +#define dSAP_AXES_ZXY ((2)|(0<<2)|(1<<4)) +#define dSAP_AXES_ZYX ((2)|(1<<2)|(0<<4)) + +ODE_API dSpaceID dSweepAndPruneSpaceCreate( dSpaceID space, int axisorder ); + + + +ODE_API void dSpaceDestroy (dSpaceID); + +ODE_API void dHashSpaceSetLevels (dSpaceID space, int minlevel, int maxlevel); +ODE_API void dHashSpaceGetLevels (dSpaceID space, int *minlevel, int *maxlevel); + +ODE_API void dSpaceSetCleanup (dSpaceID space, int mode); +ODE_API int dSpaceGetCleanup (dSpaceID space); + +/** +* @brief Sets sublevel value for a space. +* +* Sublevel affects how the space is handled in dSpaceCollide2 when it is collided +* with another space. If sublevels of both spaces match, the function iterates +* geometries of both spaces and collides them with each other. If sublevel of one +* space is greater than the sublevel of another one, only the geometries of the +* space with greater sublevel are iterated, another space is passed into +* collision callback as a geometry itself. By default all the spaces are assigned +* zero sublevel. +* +* @note +* The space sublevel @e IS @e NOT automatically updated when one space is inserted +* into another or removed from one. It is a client's responsibility to update sublevel +* value if necessary. +* +* @param space the space to modify +* @param sublevel the sublevel value to be assigned +* @ingroup collide +* @see dSpaceGetSublevel +* @see dSpaceCollide2 +*/ +ODE_API void dSpaceSetSublevel (dSpaceID space, int sublevel); + +/** +* @brief Gets sublevel value of a space. +* +* Sublevel affects how the space is handled in dSpaceCollide2 when it is collided +* with another space. See @c dSpaceSetSublevel for more details. +* +* @param space the space to query +* @returns the sublevel value of the space +* @ingroup collide +* @see dSpaceSetSublevel +* @see dSpaceCollide2 +*/ +ODE_API int dSpaceGetSublevel (dSpaceID space); + + +/** +* @brief Sets manual cleanup flag for a space. +* +* Manual cleanup flag marks a space as eligible for manual thread data cleanup. +* This function should be called for every space object right after creation in +* case if ODE has been initialized with @c dInitFlagManualThreadCleanup flag. +* +* Failure to set manual cleanup flag for a space may lead to some resources +* remaining leaked until the program exit. +* +* @param space the space to modify +* @param mode 1 for manual cleanup mode and 0 for default cleanup mode +* @ingroup collide +* @see dSpaceGetManualCleanup +* @see dInitODE2 +*/ +ODE_API void dSpaceSetManualCleanup (dSpaceID space, int mode); + +/** +* @brief Get manual cleanup flag of a space. +* +* Manual cleanup flag marks a space space as eligible for manual thread data cleanup. +* See @c dSpaceSetManualCleanup for more details. +* +* @param space the space to query +* @returns 1 for manual cleanup mode and 0 for default cleanup mode of the space +* @ingroup collide +* @see dSpaceSetManualCleanup +* @see dInitODE2 +*/ +ODE_API int dSpaceGetManualCleanup (dSpaceID space); + +ODE_API void dSpaceAdd (dSpaceID, dGeomID); +ODE_API void dSpaceRemove (dSpaceID, dGeomID); +ODE_API int dSpaceQuery (dSpaceID, dGeomID); +ODE_API void dSpaceClean (dSpaceID); +ODE_API int dSpaceGetNumGeoms (dSpaceID); +ODE_API dGeomID dSpaceGetGeom (dSpaceID, int i); + +/** + * @brief Given a space, this returns its class. + * + * The ODE classes are: + * @li dSimpleSpaceClass + * @li dHashSpaceClass + * @li dSweepAndPruneSpaceClass + * @li dQuadTreeSpaceClass + * @li dFirstUserClass + * @li dLastUserClass + * + * The class id not defined by the user should be between + * dFirstSpaceClass and dLastSpaceClass. + * + * User-defined class will return their own number. + * + * @param space the space to query + * @returns The space class ID. + * @ingroup collide + */ +ODE_API int dSpaceGetClass(dSpaceID space); + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/libs/ode-0.16.1/include/ode/collision_trimesh.h b/libs/ode-0.16.1/include/ode/collision_trimesh.h new file mode 100644 index 0000000..aa8f624 --- /dev/null +++ b/libs/ode-0.16.1/include/ode/collision_trimesh.h @@ -0,0 +1,316 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001-2003 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +/* + * TriMesh code by Erwin de Vries. + * + * Trimesh data. + * This is where the actual vertexdata (pointers), and BV tree is stored. + * Vertices should be single precision! + * This should be more sophisticated, so that the user can easyly implement + * another collision library, but this is a lot of work, and also costs some + * performance because some data has to be copied. + */ + +#ifndef _ODE_COLLISION_TRIMESH_H_ +#define _ODE_COLLISION_TRIMESH_H_ + +#ifdef __cplusplus +extern "C" { +#endif + +/* + * Data storage for triangle meshes. + */ +struct dxTriMeshData; +typedef struct dxTriMeshData* dTriMeshDataID; + + +typedef enum +{ + dMTV__MIN, + + dMTV_FIRST = dMTV__MIN, + dMTV_SECOND, + dMTV_THIRD, + + dMTV__MAX, + +} dMeshTriangleVertex; + +/* + * These don't make much sense now, but they will later when we add more + * features. + */ +ODE_API dTriMeshDataID dGeomTriMeshDataCreate(void); +ODE_API void dGeomTriMeshDataDestroy(dTriMeshDataID g); + + +/* + * The values of data_id that can be used with dGeomTriMeshDataSet/dGeomTriMeshDataGet + */ +enum +{ + dTRIMESHDATA__MIN, + + dTRIMESHDATA_FACE_NORMALS = dTRIMESHDATA__MIN, + dTRIMESHDATA_USE_FLAGS, + + dTRIMESHDATA__MAX, + +#ifndef TRIMESH_FACE_NORMALS // Define this name during the header inclusion if you need it for something else + // Included for backward compatibility -- please use the corrected name above. Sorry. + TRIMESH_FACE_NORMALS = dTRIMESHDATA_FACE_NORMALS, +#endif +}; + +/* + * The flags of the dTRIMESHDATA_USE_FLAGS data elements + */ +enum +{ + dMESHDATAUSE_EDGE1 = 0x01, + dMESHDATAUSE_EDGE2 = 0x02, + dMESHDATAUSE_EDGE3 = 0x04, + dMESHDATAUSE_VERTEX1 = 0x08, + dMESHDATAUSE_VERTEX2 = 0x10, + dMESHDATAUSE_VERTEX3 = 0x20, +}; + +/* + * Set and get the TriMeshData additional data + * Note: The data is NOT COPIED on assignment + */ +ODE_API void dGeomTriMeshDataSet(dTriMeshDataID g, int data_id, void *in_data); +ODE_API void *dGeomTriMeshDataGet(dTriMeshDataID g, int data_id); +ODE_API void *dGeomTriMeshDataGet2(dTriMeshDataID g, int data_id, dsizeint *pout_size/*=NULL*/); + + + +/** + * We need to set the last transform after each time step for + * accurate collision response. These functions get and set that transform. + * It is stored per geom instance, rather than per dTriMeshDataID. + */ +ODE_API void dGeomTriMeshSetLastTransform( dGeomID g, const dMatrix4 last_trans ); +ODE_API const dReal* dGeomTriMeshGetLastTransform( dGeomID g ); + +/* + * Build a TriMesh data object with single precision vertex data. + */ +ODE_API void dGeomTriMeshDataBuildSingle(dTriMeshDataID g, + const void* Vertices, int VertexStride, int VertexCount, + const void* Indices, int IndexCount, int TriStride); +/* same again with a normals array (used as trimesh-trimesh optimization) */ +ODE_API void dGeomTriMeshDataBuildSingle1(dTriMeshDataID g, + const void* Vertices, int VertexStride, int VertexCount, + const void* Indices, int IndexCount, int TriStride, + const void* Normals); +/* +* Build a TriMesh data object with double precision vertex data. +*/ +ODE_API void dGeomTriMeshDataBuildDouble(dTriMeshDataID g, + const void* Vertices, int VertexStride, int VertexCount, + const void* Indices, int IndexCount, int TriStride); +/* same again with a normals array (used as trimesh-trimesh optimization) */ +ODE_API void dGeomTriMeshDataBuildDouble1(dTriMeshDataID g, + const void* Vertices, int VertexStride, int VertexCount, + const void* Indices, int IndexCount, int TriStride, + const void* Normals); + +/* + * Simple build. Single/double precision based on dSINGLE/dDOUBLE! + */ +ODE_API void dGeomTriMeshDataBuildSimple(dTriMeshDataID g, + const dReal* Vertices, int VertexCount, + const dTriIndex* Indices, int IndexCount); +/* same again with a normals array (used as trimesh-trimesh optimization) */ +ODE_API void dGeomTriMeshDataBuildSimple1(dTriMeshDataID g, + const dReal* Vertices, int VertexCount, + const dTriIndex* Indices, int IndexCount, + const int* Normals); + + +/* + * Data preprocessing build request flags. + */ +enum +{ + dTRIDATAPREPROCESS_BUILD__MIN, + + dTRIDATAPREPROCESS_BUILD_CONCAVE_EDGES = dTRIDATAPREPROCESS_BUILD__MIN, // Used to optimize OPCODE trimesh-capsule collisions; allocates 1 byte per triangle; no extra data associated + dTRIDATAPREPROCESS_BUILD_FACE_ANGLES, // Used to aid trimesh-convex collisions; memory requirements depend on extra data + + dTRIDATAPREPROCESS_BUILD__MAX, +}; + +/* + * Data preprocessing extra values for dTRIDATAPREPROCESS_BUILD_FACE_ANGLES. + */ +enum +{ + dTRIDATAPREPROCESS_FACE_ANGLES_EXTRA__MIN, + + dTRIDATAPREPROCESS_FACE_ANGLES_EXTRA_BYTE_POSITIVE = dTRIDATAPREPROCESS_FACE_ANGLES_EXTRA__MIN, // Build angles for convex edges only and store as bytes; allocates 3 bytes per triangle; stores angles (0..180] in 1/254 fractions leaving two values for the flat and all the concaves + dTRIDATAPREPROCESS_FACE_ANGLES_EXTRA_BYTE_ALL, // Build angles for all the edges and store in bytes; allocates 3 bytes per triangle; stores angles [-180..0) and (0..180] in 1/127 fractions plus a value for the flat angle + dTRIDATAPREPROCESS_FACE_ANGLES_EXTRA_WORD_ALL, // Build angles for all the edges and store in words; allocates 6 bytes per triangle; stores angles [-180..0) and (0..180] in 1/32767 fractions plus a value for the flat angle + + dTRIDATAPREPROCESS_FACE_ANGLES_EXTRA__MAX, + + dTRIDATAPREPROCESS_FACE_ANGLES_EXTRA__DEFAULT = dTRIDATAPREPROCESS_FACE_ANGLES_EXTRA_BYTE_POSITIVE, // The default value assumed if the extra data is not provided +}; + + +/* + * Pre-process the trimesh data according to the request flags. + * + * buildRequestFlags is a bitmask of 1U << dTRIDATAPREPROCESS_BUILD_... + * It is allowed to call the function multiple times provided the bitmasks are different each time. + * + * requestExtraData is an optional pointer to array of extra parameters per bitmask bits + * (only the elements indexed by positions of raised bits are examined; + * defaults are assumed if the pointer is NULL) + * + * The function returns a boolean status the only failure reason being insufficient memory. + */ +ODE_API int dGeomTriMeshDataPreprocess2(dTriMeshDataID g, unsigned int buildRequestFlags, const dintptr *requestExtraData/*=NULL | const dintptr (*)[dTRIDATAPREPROCESS_BUILD__MAX]*/); + +/* + * Obsolete. Equivalent to calling dGeomTriMeshDataPreprocess2(g, (1U << dTRIDATAPREPROCESS_BUILD_CONCAVE_EDGES), NULL) + */ +ODE_API int dGeomTriMeshDataPreprocess(dTriMeshDataID g); + + + +/* + * Get and set the internal preprocessed trimesh data buffer (see the enumerated type above), for loading and saving + * These functions are deprecated. Use dGeomTriMeshDataSet/dGeomTriMeshDataGet2 with dTRIMESHDATA_USE_FLAGS instead. + */ +ODE_API_DEPRECATED ODE_API void dGeomTriMeshDataGetBuffer(dTriMeshDataID g, unsigned char** buf, int* bufLen); +ODE_API_DEPRECATED ODE_API void dGeomTriMeshDataSetBuffer(dTriMeshDataID g, unsigned char* buf); + + +/* + * Per triangle callback. Allows the user to say if he wants a collision with + * a particular triangle. + */ +typedef int dTriCallback(dGeomID TriMesh, dGeomID RefObject, int TriangleIndex); +ODE_API void dGeomTriMeshSetCallback(dGeomID g, dTriCallback* Callback); +ODE_API dTriCallback* dGeomTriMeshGetCallback(dGeomID g); + +/* + * Per object callback. Allows the user to get the list of triangles in 1 + * shot. Maybe we should remove this one. + */ +typedef void dTriArrayCallback(dGeomID TriMesh, dGeomID RefObject, const int* TriIndices, int TriCount); +ODE_API void dGeomTriMeshSetArrayCallback(dGeomID g, dTriArrayCallback* ArrayCallback); +ODE_API dTriArrayCallback* dGeomTriMeshGetArrayCallback(dGeomID g); + +/* + * Ray callback. + * Allows the user to say if a ray collides with a triangle on barycentric + * coords. The user can for example sample a texture with alpha transparency + * to determine if a collision should occur. + */ +typedef int dTriRayCallback(dGeomID TriMesh, dGeomID Ray, int TriangleIndex, dReal u, dReal v); +ODE_API void dGeomTriMeshSetRayCallback(dGeomID g, dTriRayCallback* Callback); +ODE_API dTriRayCallback* dGeomTriMeshGetRayCallback(dGeomID g); + +/* + * Triangle merging callback. + * Allows the user to generate a fake triangle index for a new contact generated + * from merging of two other contacts. That index could later be used by the + * user to determine attributes of original triangles used as sources for a + * merged contact. + */ +typedef int dTriTriMergeCallback(dGeomID TriMesh, int FirstTriangleIndex, int SecondTriangleIndex); +ODE_API void dGeomTriMeshSetTriMergeCallback(dGeomID g, dTriTriMergeCallback* Callback); +ODE_API dTriTriMergeCallback* dGeomTriMeshGetTriMergeCallback(dGeomID g); + +/* + * Trimesh class + * Construction. Callbacks are optional. + */ +ODE_API dGeomID dCreateTriMesh(dSpaceID space, dTriMeshDataID Data, dTriCallback* Callback, dTriArrayCallback* ArrayCallback, dTriRayCallback* RayCallback); + +ODE_API void dGeomTriMeshSetData(dGeomID g, dTriMeshDataID Data); +ODE_API dTriMeshDataID dGeomTriMeshGetData(dGeomID g); + + +/* enable/disable/check temporal coherence*/ +ODE_API void dGeomTriMeshEnableTC(dGeomID g, int geomClass, int enable); +ODE_API int dGeomTriMeshIsTCEnabled(dGeomID g, int geomClass); + +/* + * Clears the internal temporal coherence caches. When a geom has its + * collision checked with a trimesh once, data is stored inside the trimesh. + * With large worlds with lots of seperate objects this list could get huge. + * We should be able to do this automagically. + */ +ODE_API void dGeomTriMeshClearTCCache(dGeomID g); + + +/* + * returns the TriMeshDataID + */ +ODE_API dTriMeshDataID dGeomTriMeshGetTriMeshDataID(dGeomID g); + +/* + * Gets a triangle. + */ +ODE_API void dGeomTriMeshGetTriangle(dGeomID g, int Index, dVector3* v0, dVector3* v1, dVector3* v2); + +/* + * Gets the point on the requested triangle and the given barycentric + * coordinates. + */ +ODE_API void dGeomTriMeshGetPoint(dGeomID g, int Index, dReal u, dReal v, dVector3 Out); + +/* + +This is how the strided data works: + +struct StridedVertex{ + dVector3 Vertex; + // Userdata +}; +int VertexStride = sizeof(StridedVertex); + +struct StridedTri{ + int Indices[3]; + // Userdata +}; +int TriStride = sizeof(StridedTri); + +*/ + + +ODE_API int dGeomTriMeshGetTriangleCount (dGeomID g); + +ODE_API void dGeomTriMeshDataUpdate(dTriMeshDataID g); + +#ifdef __cplusplus +} +#endif + +#endif /* _ODE_COLLISION_TRIMESH_H_ */ + diff --git a/libs/ode-0.16.1/include/ode/common.h b/libs/ode-0.16.1/include/ode/common.h new file mode 100644 index 0000000..b0a5793 --- /dev/null +++ b/libs/ode-0.16.1/include/ode/common.h @@ -0,0 +1,568 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#ifndef _ODE_COMMON_H_ +#define _ODE_COMMON_H_ + +#include +#include + + +#ifdef __cplusplus +extern "C" { +#endif + + +/* configuration stuff */ + +/* constants */ + +/* pi and 1/sqrt(2) are defined here if necessary because they don't get + * defined in on some platforms (like MS-Windows) + */ + +#ifndef M_PI +#define M_PI REAL(3.1415926535897932384626433832795029) +#endif +#ifndef M_PI_2 +#define M_PI_2 REAL(1.5707963267948966192313216916398) +#endif +#ifndef M_SQRT1_2 +#define M_SQRT1_2 REAL(0.7071067811865475244008443621048490) +#endif + + +/* floating point data type, vector, matrix and quaternion types */ + +#if defined(dSINGLE) +typedef float dReal; +#ifdef dDOUBLE +#error You can only #define dSINGLE or dDOUBLE, not both. +#endif /* dDOUBLE */ +#elif defined(dDOUBLE) +typedef double dReal; +#else +#error You must #define dSINGLE or dDOUBLE +#endif + +/* Detect if we've got both trimesh engines enabled. */ +#if dTRIMESH_ENABLED +#if dTRIMESH_OPCODE && dTRIMESH_GIMPACT +#error You can only #define dTRIMESH_OPCODE or dTRIMESH_GIMPACT, not both. +#endif +#endif /* dTRIMESH_ENABLED */ + +/* + * Define a type for indices, either 16 or 32 bit, based on build option + * TODO: Currently GIMPACT only supports 32 bit indices. + */ +#if dTRIMESH_16BIT_INDICES +#if dTRIMESH_GIMPACT +typedef duint32 dTriIndex; +#else /* dTRIMESH_GIMPACT */ +typedef duint16 dTriIndex; +#endif /* dTRIMESH_GIMPACT */ +#else /* dTRIMESH_16BIT_INDICES */ +typedef duint32 dTriIndex; +#endif /* dTRIMESH_16BIT_INDICES */ + +/* round an integer up to a multiple of 4, except that 0 and 1 are unmodified + * (used to compute matrix leading dimensions) + */ +#define dPAD(a) (((a) > 1) ? (((a) + 3) & (int)(~3)) : (a)) + +typedef enum { + dSA__MIN, + + dSA_X = dSA__MIN, + dSA_Y, + dSA_Z, + + dSA__MAX, +} dSpaceAxis; + +typedef enum { + dMD__MIN, + + dMD_LINEAR = dMD__MIN, + dMD_ANGULAR, + + dMD__MAX, +} dMotionDynamics; + +typedef enum { + dDA__MIN, + + dDA__L_MIN = dDA__MIN + dMD_LINEAR * dSA__MAX, + + dDA_LX = dDA__L_MIN + dSA_X, + dDA_LY = dDA__L_MIN + dSA_Y, + dDA_LZ = dDA__L_MIN + dSA_Z, + + dDA__L_MAX = dDA__L_MIN + dSA__MAX, + + dDA__A_MIN = dDA__MIN + dMD_ANGULAR * dSA__MAX, + + dDA_AX = dDA__A_MIN + dSA_X, + dDA_AY = dDA__A_MIN + dSA_Y, + dDA_AZ = dDA__A_MIN + dSA_Z, + + dDA__A_MAX = dDA__A_MIN + dSA__MAX, + + dDA__MAX = dDA__MIN + dMD__MAX * dSA__MAX, +} dDynamicsAxis; + +typedef enum { + dV3E__MIN, + + dV3E__AXES_MIN = dV3E__MIN, + + dV3E_X = dV3E__AXES_MIN + dSA_X, + dV3E_Y = dV3E__AXES_MIN + dSA_Y, + dV3E_Z = dV3E__AXES_MIN + dSA_Z, + + dV3E__AXES_MAX = dV3E__AXES_MIN + dSA__MAX, + + dV3E_PAD = dV3E__AXES_MAX, + + dV3E__MAX, + + dV3E__AXES_COUNT = dV3E__AXES_MAX - dV3E__AXES_MIN, +} dVec3Element; + +typedef enum { + dV4E__MIN, + + dV4E_X = dV4E__MIN + dSA_X, + dV4E_Y = dV4E__MIN + dSA_Y, + dV4E_Z = dV4E__MIN + dSA_Z, + dV4E_O = dV4E__MIN + dSA__MAX, + + dV4E__MAX, +} dVec4Element; + +typedef enum { + dM3E__MIN, + + dM3E__X_MIN = dM3E__MIN + dSA_X * dV3E__MAX, + + dM3E__X_AXES_MIN = dM3E__X_MIN + dV3E__AXES_MIN, + + dM3E_XX = dM3E__X_MIN + dV3E_X, + dM3E_XY = dM3E__X_MIN + dV3E_Y, + dM3E_XZ = dM3E__X_MIN + dV3E_Z, + + dM3E__X_AXES_MAX = dM3E__X_MIN + dV3E__AXES_MAX, + + dM3E_XPAD = dM3E__X_MIN + dV3E_PAD, + + dM3E__X_MAX = dM3E__X_MIN + dV3E__MAX, + + dM3E__Y_MIN = dM3E__MIN + dSA_Y * dV3E__MAX, + + dM3E__Y_AXES_MIN = dM3E__Y_MIN + dV3E__AXES_MIN, + + dM3E_YX = dM3E__Y_MIN + dV3E_X, + dM3E_YY = dM3E__Y_MIN + dV3E_Y, + dM3E_YZ = dM3E__Y_MIN + dV3E_Z, + + dM3E__Y_AXES_MAX = dM3E__Y_MIN + dV3E__AXES_MAX, + + dM3E_YPAD = dM3E__Y_MIN + dV3E_PAD, + + dM3E__Y_MAX = dM3E__Y_MIN + dV3E__MAX, + + dM3E__Z_MIN = dM3E__MIN + dSA_Z * dV3E__MAX, + + dM3E__Z_AXES_MIN = dM3E__Z_MIN + dV3E__AXES_MIN, + + dM3E_ZX = dM3E__Z_MIN + dV3E_X, + dM3E_ZY = dM3E__Z_MIN + dV3E_Y, + dM3E_ZZ = dM3E__Z_MIN + dV3E_Z, + + dM3E__Z_AXES_MAX = dM3E__Z_MIN + dV3E__AXES_MAX, + + dM3E_ZPAD = dM3E__Z_MIN + dV3E_PAD, + + dM3E__Z_MAX = dM3E__Z_MIN + dV3E__MAX, + + dM3E__MAX = dM3E__MIN + dSA__MAX * dV3E__MAX, +} dMat3Element; + +typedef enum { + dM4E__MIN, + + dM4E__X_MIN = dM4E__MIN + dV4E_X * dV4E__MAX, + + dM4E_XX = dM4E__X_MIN + dV4E_X, + dM4E_XY = dM4E__X_MIN + dV4E_Y, + dM4E_XZ = dM4E__X_MIN + dV4E_Z, + dM4E_XO = dM4E__X_MIN + dV4E_O, + + dM4E__X_MAX = dM4E__X_MIN + dV4E__MAX, + + dM4E__Y_MIN = dM4E__MIN + dV4E_Y * dV4E__MAX, + + dM4E_YX = dM4E__Y_MIN + dV4E_X, + dM4E_YY = dM4E__Y_MIN + dV4E_Y, + dM4E_YZ = dM4E__Y_MIN + dV4E_Z, + dM4E_YO = dM4E__Y_MIN + dV4E_O, + + dM4E__Y_MAX = dM4E__Y_MIN + dV4E__MAX, + + dM4E__Z_MIN = dM4E__MIN + dV4E_Z * dV4E__MAX, + + dM4E_ZX = dM4E__Z_MIN + dV4E_X, + dM4E_ZY = dM4E__Z_MIN + dV4E_Y, + dM4E_ZZ = dM4E__Z_MIN + dV4E_Z, + dM4E_ZO = dM4E__Z_MIN + dV4E_O, + + dM4E__Z_MAX = dM4E__Z_MIN + dV4E__MAX, + + dM4E__O_MIN = dM4E__MIN + dV4E_O * dV4E__MAX, + + dM4E_OX = dM4E__O_MIN + dV4E_X, + dM4E_OY = dM4E__O_MIN + dV4E_Y, + dM4E_OZ = dM4E__O_MIN + dV4E_Z, + dM4E_OO = dM4E__O_MIN + dV4E_O, + + dM4E__O_MAX = dM4E__O_MIN + dV4E__MAX, + + dM4E__MAX = dM4E__MIN + dV4E__MAX * dV4E__MAX, +} dMat4Element; + +typedef enum { + dQUE__MIN, + + dQUE_R = dQUE__MIN, + + dQUE__AXIS_MIN, + + dQUE_I = dQUE__AXIS_MIN + dSA_X, + dQUE_J = dQUE__AXIS_MIN + dSA_Y, + dQUE_K = dQUE__AXIS_MIN + dSA_Z, + + dQUE__AXIS_MAX = dQUE__AXIS_MIN + dSA__MAX, + + dQUE__MAX = dQUE__AXIS_MAX, +} dQuatElement; + +/* these types are mainly just used in headers */ +typedef dReal dVector3[dV3E__MAX]; +typedef dReal dVector4[dV4E__MAX]; +typedef dReal dMatrix3[dM3E__MAX]; +typedef dReal dMatrix4[dM4E__MAX]; +typedef dReal dMatrix6[(dMD__MAX * dV3E__MAX) * (dMD__MAX * dSA__MAX)]; +typedef dReal dQuaternion[dQUE__MAX]; + + +/* precision dependent scalar math functions */ + +#if defined(dSINGLE) + +#define REAL(x) (x##f) /* form a constant */ +#define dRecip(x) ((1.0f/(x))) /* reciprocal */ +#define dSqrt(x) (sqrtf(x)) /* square root */ +#define dRecipSqrt(x) ((1.0f/sqrtf(x))) /* reciprocal square root */ +#define dSin(x) (sinf(x)) /* sine */ +#define dCos(x) (cosf(x)) /* cosine */ +#define dFabs(x) (fabsf(x)) /* absolute value */ +#define dAtan2(y,x) (atan2f(y,x)) /* arc tangent with 2 args */ +#define dAsin(x) (asinf(x)) +#define dAcos(x) (acosf(x)) +#define dFMod(a,b) (fmodf(a,b)) /* modulo */ +#define dFloor(x) floorf(x) /* floor */ +#define dCeil(x) ceilf(x) /* ceil */ +#define dCopySign(a,b) _ode_copysignf(a, b) /* copy value sign */ +#define dNextAfter(x, y) _ode_nextafterf(x, y) /* next value after */ + +#ifdef HAVE___ISNANF +#define dIsNan(x) (__isnanf(x)) +#elif defined(HAVE__ISNANF) +#define dIsNan(x) (_isnanf(x)) +#elif defined(HAVE_ISNANF) +#define dIsNan(x) (isnanf(x)) +#else + /* + fall back to _isnan which is the VC way, + this may seem redundant since we already checked + for _isnan before, but if isnan is detected by + configure but is not found during compilation + we should always make sure we check for __isnanf, + _isnanf and isnanf in that order before falling + back to a default + */ +#define dIsNan(x) (_isnan(x)) +#endif + +#elif defined(dDOUBLE) + +#define REAL(x) (x) +#define dRecip(x) (1.0/(x)) +#define dSqrt(x) sqrt(x) +#define dRecipSqrt(x) (1.0/sqrt(x)) +#define dSin(x) sin(x) +#define dCos(x) cos(x) +#define dFabs(x) fabs(x) +#define dAtan2(y,x) atan2((y),(x)) +#define dAsin(x) asin(x) +#define dAcos(x) acos(x) +#define dFMod(a,b) (fmod((a),(b))) +#define dFloor(x) floor(x) +#define dCeil(x) ceil(x) +#define dCopySign(a,b) _ode_copysign(a, b) +#define dNextAfter(x, y) _ode_nextafter(x, y) + +#ifdef HAVE___ISNAN +#define dIsNan(x) (__isnan(x)) +#elif defined(HAVE__ISNAN) +#define dIsNan(x) (_isnan(x)) +#elif defined(HAVE_ISNAN) +#define dIsNan(x) (isnan(x)) +#else +#define dIsNan(x) (_isnan(x)) +#endif + +#else +#error You must #define dSINGLE or dDOUBLE +#endif + +ODE_PURE_INLINE dReal dMin(dReal x, dReal y) { return x <= y ? x : y; } +ODE_PURE_INLINE dReal dMax(dReal x, dReal y) { return x <= y ? y : x; } + + +/* internal object types (all prefixed with `dx') */ + +struct dxWorld; /* dynamics world */ +struct dxSpace; /* collision space */ +struct dxBody; /* rigid body (dynamics object) */ +struct dxGeom; /* geometry (collision object) */ +struct dxJoint; /* joint */ +struct dxJointGroup;/* joint group */ + + +typedef struct dxWorld *dWorldID; +typedef struct dxSpace *dSpaceID; +typedef struct dxBody *dBodyID; +typedef struct dxGeom *dGeomID; +typedef struct dxJoint *dJointID; +typedef struct dxJointGroup *dJointGroupID; + + +/* error numbers */ + +enum { + d_ERR_UNKNOWN = 0, /* unknown error */ + d_ERR_IASSERT, /* internal assertion failed */ + d_ERR_UASSERT, /* user assertion failed */ + d_ERR_LCP /* user assertion failed */ +}; + + +/* joint type numbers */ + +typedef enum { + dJointTypeNone = 0, /* or "unknown" */ + dJointTypeBall, + dJointTypeHinge, + dJointTypeSlider, + dJointTypeContact, + dJointTypeUniversal, + dJointTypeHinge2, + dJointTypeFixed, + dJointTypeNull, + dJointTypeAMotor, + dJointTypeLMotor, + dJointTypePlane2D, + dJointTypePR, + dJointTypePU, + dJointTypePiston, + dJointTypeDBall, + dJointTypeDHinge, + dJointTypeTransmission, +} dJointType; + + +/* an alternative way of setting joint parameters, using joint parameter + * structures and member constants. we don't actually do this yet. + */ + +/* +typedef struct dLimot { + int mode; + dReal lostop, histop; + dReal vel, fmax; + dReal fudge_factor; + dReal bounce, soft; + dReal suspension_erp, suspension_cfm; +} dLimot; + +enum { + dLimotLoStop = 0x0001, + dLimotHiStop = 0x0002, + dLimotVel = 0x0004, + dLimotFMax = 0x0008, + dLimotFudgeFactor = 0x0010, + dLimotBounce = 0x0020, + dLimotSoft = 0x0040 +}; +*/ + + +/* standard joint parameter names. why are these here? - because we don't want + * to include all the joint function definitions in joint.cpp. hmmmm. + * MSVC complains if we call D_ALL_PARAM_NAMES_X with a blank second argument, + * which is why we have the D_ALL_PARAM_NAMES macro as well. please copy and + * paste between these two. + */ + +#define D_ALL_PARAM_NAMES(start) \ + /* parameters for limits and motors */ \ + dParamLoStop = start, \ + dParamHiStop, \ + dParamVel, \ + dParamLoVel, \ + dParamHiVel, \ + dParamFMax, \ + dParamFudgeFactor, \ + dParamBounce, \ + dParamCFM, \ + dParamStopERP, \ + dParamStopCFM, \ + /* parameters for suspension */ \ + dParamSuspensionERP, \ + dParamSuspensionCFM, \ + dParamERP, \ + + /* + * \enum D_ALL_PARAM_NAMES_X + * + * \var dParamGroup This is the starting value of the different group + * (i.e. dParamGroup1, dParamGroup2, dParamGroup3) + * It also helps in the use of parameter + * (dParamGroup2 | dParamFMax) == dParamFMax2 + */ +#define D_ALL_PARAM_NAMES_X(start,x) \ + dParamGroup ## x = start, \ + /* parameters for limits and motors */ \ + dParamLoStop ## x = start, \ + dParamHiStop ## x, \ + dParamVel ## x, \ + dParamLoVel ## x, \ + dParamHiVel ## x, \ + dParamFMax ## x, \ + dParamFudgeFactor ## x, \ + dParamBounce ## x, \ + dParamCFM ## x, \ + dParamStopERP ## x, \ + dParamStopCFM ## x, \ + /* parameters for suspension */ \ + dParamSuspensionERP ## x, \ + dParamSuspensionCFM ## x, \ + dParamERP ## x, + +enum { + D_ALL_PARAM_NAMES(0) + dParamsInGroup, /* < Number of parameter in a group */ + D_ALL_PARAM_NAMES_X(0x000,1) + D_ALL_PARAM_NAMES_X(0x100,2) + D_ALL_PARAM_NAMES_X(0x200,3) + + /* add a multiple of this constant to the basic parameter numbers to get + * the parameters for the second, third etc axes. + */ + dParamGroup=0x100 +}; + + +/* angular motor mode numbers */ + +enum { + dAMotorUser = 0, + dAMotorEuler = 1 +}; + +/* transmission joint mode numbers */ + +enum { + dTransmissionParallelAxes = 0, + dTransmissionIntersectingAxes = 1, + dTransmissionChainDrive = 2 +}; + + +/* joint force feedback information */ + +typedef struct dJointFeedback { + dVector3 f1; /* force applied to body 1 */ + dVector3 t1; /* torque applied to body 1 */ + dVector3 f2; /* force applied to body 2 */ + dVector3 t2; /* torque applied to body 2 */ +} dJointFeedback; + + +/* private functions that must be implemented by the collision library: + * (1) indicate that a geom has moved, (2) get the next geom in a body list. + * these functions are called whenever the position of geoms connected to a + * body have changed, e.g. with dBodySetPosition(), dBodySetRotation(), or + * when the ODE step function updates the body state. + */ + +void dGeomMoved (dGeomID); +dGeomID dGeomGetBodyNext (dGeomID); + +/** + * dGetConfiguration returns the specific ODE build configuration as + * a string of tokens. The string can be parsed in a similar way to + * the OpenGL extension mechanism, the naming convention should be + * familiar too. The following extensions are reported: + * + * ODE + * ODE_single_precision + * ODE_double_precision + * ODE_EXT_no_debug + * ODE_EXT_trimesh + * ODE_EXT_opcode + * ODE_EXT_gimpact + * ODE_OPC_16bit_indices + * ODE_OPC_new_collider + * ODE_EXT_mt_collisions + * ODE_EXT_threading + * ODE_THR_builtin_impl + */ +ODE_API const char* dGetConfiguration (void); + +/** + * Helper to check for a token in the ODE configuration string. + * Caution, this function is case sensitive. + * + * @param token A configuration token, see dGetConfiguration for details + * + * @return 1 if exact token is present, 0 if not present + */ +ODE_API int dCheckConfiguration( const char* token ); + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/libs/ode-0.16.1/include/ode/compatibility.h b/libs/ode-0.16.1/include/ode/compatibility.h new file mode 100644 index 0000000..b370986 --- /dev/null +++ b/libs/ode-0.16.1/include/ode/compatibility.h @@ -0,0 +1,40 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#ifndef _ODE_COMPATIBILITY_H_ +#define _ODE_COMPATIBILITY_H_ + +/* + * ODE's backward compatibility system ensures that as ODE's API + * evolves, user code will not break. + */ + +/* + * These new rotation function names are more consistent with the + * rest of the API. + */ +#define dQtoR(q,R) dRfromQ((R),(q)) +#define dRtoQ(R,q) dQfromR((q),(R)) +#define dWtoDQ(w,q,dq) dDQfromW((dq),(w),(q)) + + +#endif diff --git a/libs/ode-0.16.1/include/ode/contact.h b/libs/ode-0.16.1/include/ode/contact.h new file mode 100644 index 0000000..9756f26 --- /dev/null +++ b/libs/ode-0.16.1/include/ode/contact.h @@ -0,0 +1,110 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#ifndef _ODE_CONTACT_H_ +#define _ODE_CONTACT_H_ + +#include + +#ifdef __cplusplus +extern "C" { +#endif + + +enum { + dContactMu2 = 0x001, /**< Use axis dependent friction */ + dContactAxisDep = 0x001, /**< Same as above */ + dContactFDir1 = 0x002, /**< Use FDir for the first friction value */ + dContactBounce = 0x004, /**< Restore collision energy anti-parallel to the normal */ + dContactSoftERP = 0x008, /**< Don't use global erp for penetration reduction */ + dContactSoftCFM = 0x010, /**< Don't use global cfm for penetration constraint */ + dContactMotion1 = 0x020, /**< Use a non-zero target velocity for the constraint */ + dContactMotion2 = 0x040, + dContactMotionN = 0x080, + dContactSlip1 = 0x100, /**< Force-dependent slip. */ + dContactSlip2 = 0x200, + dContactRolling = 0x400, /**< Rolling/Angular friction */ + + dContactApprox0 = 0x0000, + dContactApprox1_1 = 0x1000, + dContactApprox1_2 = 0x2000, + dContactApprox1_N = 0x4000, /**< For rolling friction */ + dContactApprox1 = 0x7000 +}; + + +typedef struct dSurfaceParameters { + /* must always be defined */ + int mode; + dReal mu; + + /* only defined if the corresponding flag is set in mode */ + dReal mu2; + dReal rho; /**< Rolling friction */ + dReal rho2; + dReal rhoN; /**< Spinning friction */ + dReal bounce; /**< Coefficient of restitution */ + dReal bounce_vel; /**< Bouncing threshold */ + dReal soft_erp; + dReal soft_cfm; + dReal motion1,motion2,motionN; + dReal slip1,slip2; +} dSurfaceParameters; + + +/** + * @brief Describe the contact point between two geoms. + * + * If two bodies touch, or if a body touches a static feature in its + * environment, the contact is represented by one or more "contact + * points", described by dContactGeom. + * + * The convention is that if body 1 is moved along the normal vector by + * a distance depth (or equivalently if body 2 is moved the same distance + * in the opposite direction) then the contact depth will be reduced to + * zero. This means that the normal vector points "in" to body 1. + * + * @ingroup collide + */ +typedef struct dContactGeom { + dVector3 pos; /*< contact position*/ + dVector3 normal; /*< normal vector*/ + dReal depth; /*< penetration depth*/ + dGeomID g1,g2; /*< the colliding geoms*/ + int side1,side2; /*< (to be documented)*/ +} dContactGeom; + + +/* contact info used by contact joint */ + +typedef struct dContact { + dSurfaceParameters surface; + dContactGeom geom; + dVector3 fdir1; +} dContact; + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/libs/ode-0.16.1/include/ode/cooperative.h b/libs/ode-0.16.1/include/ode/cooperative.h new file mode 100644 index 0000000..879477c --- /dev/null +++ b/libs/ode-0.16.1/include/ode/cooperative.h @@ -0,0 +1,229 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001-2003 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#ifndef _ODE_COOPERATIVE_H_ +#define _ODE_COOPERATIVE_H_ + + +#include +#include + + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * @defgroup coop Cooperative Algorithms + * + * Algorithms implemented as multiple threads doing work cooperatively. + */ + + +struct dxCooperative; +struct dxResourceRequirements; +struct dxResourceContainer; + +/** + * @brief A container for cooperative algorithms shared context + * + * The Cooperative is a container for cooperative algorithms shared context. + * At present it contains threading object (either a real one or a defaulted + * self-threading). + * + * Cooperative use in functions performing computations must be serialized. That is, + * functions referring to a single instance of Cooperative object must not be called in + * parallel. + */ +typedef struct dxCooperative *dCooperativeID; + + +/** + * @brief A container for resource requirements information + * + * The ResourceRequirements object is a container for descriptive information + * regarding what resources (memory, synchronization objects, etc.) need to be + * allocated for particular computations. The object can be used for accumulating + * resource requirement maxima over multiple functions and then allocating resources + * that would suffice for any of those function calls. + * + * ResourceRequirements objects maintain relations to Cooperative objects since + * amounts of resources that could be required can depend on characteristics of + * shared context, e.g. on maximal number of threads in the threading object. + * + * @ingroup coop + * @see dCooperativeID + * @see dResourceContainerID + */ +typedef struct dxResourceRequirements *dResourceRequirementsID; + +/** + * @brief A container for algorithm allocated resources + * + * The ResourceContainer object can contain resources allocated according to information + * in a ResourceRequirements. The resources inherit link to the threading object + * from the requirements they are allocated according to. + * + * @ingroup coop + * @see dResourceRequirementsID + * @see dCooperativeID + */ +typedef struct dxResourceContainer *dResourceContainerID; + + + /** + * @brief Creates a Cooperative object related to the specified threading. + * + * NULL's are allowed for the threading. In this case the default (global) self-threading + * object will be used. + * + * Use @c dCooperativeDestroy to destroy the object. The Cooperative object must exist + * until after all the objects referencing it are destroyed. + * + * @param functionInfo The threading functions to use + * @param threadingImpl The threading implementation object to use + * @returns The Cooperative object instance or NULL if allocation fails. + * @ingroup coop + * @see dCooperativeDestroy + */ +ODE_API dCooperativeID dCooperativeCreate(const dThreadingFunctionsInfo *functionInfo/*=NULL*/, dThreadingImplementationID threadingImpl/*=NULL*/); + + /** + * @brief Destroys Cooperative object. + * + * The Cooperative object can only be destroyed after all the objects referencing it. + * + * @param cooperative A Cooperative object to be deleted (NULL is allowed) + * @ingroup coop + * @see dCooperativeCreate + */ +ODE_API void dCooperativeDestroy(dCooperativeID cooperative); + + + /** + * @brief Creates a ResourceRequirements object related to a Cooperative. + * + * The object is purely descriptive and does not contain any resources by itself. + * The actual resources are allocated by means of ResourceContainer object. + * + * The object is created with empty requirements. It can be then used to accumulate + * requirements for one or more function calls and can be cloned or merged with others. + * The actual requirements information is added to the object by computation related + * functions. + * + * Use @c dResourceRequirementsDestroy to delete the object when it is no longer needed. + * + * @param cooperative A Cooperative object to be used + * @returns The ResourceRequirements object instance or NULL if allocation fails + * @ingroup coop + * @see dResourceRequirementsDestroy + * @see dResourceRequirementsClone + * @see dResourceRequirementsMergeIn + * @see dCooperativeCreate + * @see dResourceContainerAcquire + */ +ODE_API dResourceRequirementsID dResourceRequirementsCreate(dCooperativeID cooperative); + + /** + * @brief Destroys ResourceRequirements object. + * + * The ResourceRequirements object can be destroyed at any time with no regards + * to other objects' lifetime. + * + * @param requirements A ResourceRequirements object to be deleted (NULL is allowed) + * @ingroup coop + * @see dResourceRequirementsCreate + */ +ODE_API void dResourceRequirementsDestroy(dResourceRequirementsID requirements); + + /** + * @brief Clones ResourceRequirements object. + * + * The function creates a copy of the ResourceRequirements object with all the + * contents and the relation to Cooperative matching. The object passed in + * the parameter is not changed. + * + * The object created with the function must later be destroyed with @c dResourceRequirementsDestroy. + * + * @param requirements A ResourceRequirements object to be cloned + * @returns A handle to the new object or NULL if allocation fails + * @ingroup coop + * @see dResourceRequirementsCreate + * @see dResourceRequirementsDestroy + * @see dResourceRequirementsMergeIn + */ +ODE_API dResourceRequirementsID dResourceRequirementsClone(/*const */dResourceRequirementsID requirements); + + /** + * @brief Merges one ResourceRequirements object into another ResourceRequirements object. + * + * The function updates @a summaryRequirements requirements to be also sufficient + * for the purposes @a extraRequirements could be used for. The @a extraRequirements + * object is not changed. The both objects should normally have had been created + * with the same Cooperative object. + * + * @param summaryRequirements A ResourceRequirements object to be changed + * @param extraRequirements A ResourceRequirements the requirements to be taken from + * @ingroup coop + * @see dResourceRequirementsCreate + * @see dResourceRequirementsDestroy + * @see dResourceRequirementsClone + */ +ODE_API void dResourceRequirementsMergeIn(dResourceRequirementsID summaryRequirements, /*const */dResourceRequirementsID extraRequirements); + + + /** + * @brief Allocates resources as specified in ResourceRequirements object. + * + * The ResourceContainer object can be used in cooperative computation algorithms. + * + * The same @a requirements object can be passed to many resource allocations + * (with or without modifications) and can be deleted immediately, without waiting + * for the ResourceContainer object destruction. + * + * Use @c dResourceContainerDestroy to delete the object and release the resources + * when they are no longer needed. + * + * @param requirements The ResourceRequirements object to allocate resources according to + * @returns A ResourceContainer object instance with the resources allocated or NULL if allocation fails + * @ingroup coop + * @see dResourceContainerDestroy + * @see dResourceRequirementsCreate + */ +ODE_API dResourceContainerID dResourceContainerAcquire(/*const */dResourceRequirementsID requirements); + + /** + * @brief Destroys ResourceContainer object and releases resources allocated in it. + * + * @param resources A ResourceContainer object to be deleted (NULL is allowed) + * @ingroup coop + * @see dResourceContainerAcquire + */ +ODE_API void dResourceContainerDestroy(dResourceContainerID resources); + + +#ifdef __cplusplus +} // extern "C" +#endif + + +#endif // #ifndef _ODE_COOPERATIVE_H_ diff --git a/libs/ode-0.16.1/include/ode/error.h b/libs/ode-0.16.1/include/ode/error.h new file mode 100644 index 0000000..ae511e7 --- /dev/null +++ b/libs/ode-0.16.1/include/ode/error.h @@ -0,0 +1,63 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +/* this comes from the `reuse' library. copy any changes back to the source */ + +#ifndef _ODE_ERROR_H_ +#define _ODE_ERROR_H_ + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/* all user defined error functions have this type. error and debug functions + * should not return. + */ +typedef void dMessageFunction (int errnum, const char *msg, va_list ap); + +/* set a new error, debug or warning handler. if fn is 0, the default handlers + * are used. + */ +ODE_API void dSetErrorHandler (dMessageFunction *fn); +ODE_API void dSetDebugHandler (dMessageFunction *fn); +ODE_API void dSetMessageHandler (dMessageFunction *fn); + +/* return the current error, debug or warning handler. if the return value is + * 0, the default handlers are in place. + */ +ODE_API dMessageFunction *dGetErrorHandler(void); +ODE_API dMessageFunction *dGetDebugHandler(void); +ODE_API dMessageFunction *dGetMessageHandler(void); + +/* generate a fatal error, debug trap or a message. */ +ODE_API void ODE_NORETURN dError (int num, const char *msg, ...); +ODE_API void ODE_NORETURN dDebug (int num, const char *msg, ...); +ODE_API void dMessage (int num, const char *msg, ...); + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/libs/ode-0.16.1/include/ode/export-dif.h b/libs/ode-0.16.1/include/ode/export-dif.h new file mode 100644 index 0000000..f6578ac --- /dev/null +++ b/libs/ode-0.16.1/include/ode/export-dif.h @@ -0,0 +1,40 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#ifndef _ODE_EXPORT_DIF_ +#define _ODE_EXPORT_DIF_ + +#include + + +#ifdef __cplusplus +extern "C" { +#endif + +ODE_API void dWorldExportDIF (dWorldID w, FILE *file, const char *world_name); + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/libs/ode-0.16.1/include/ode/mass.h b/libs/ode-0.16.1/include/ode/mass.h new file mode 100644 index 0000000..af89cb1 --- /dev/null +++ b/libs/ode-0.16.1/include/ode/mass.h @@ -0,0 +1,144 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#ifndef _ODE_MASS_H_ +#define _ODE_MASS_H_ + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +struct dMass; +typedef struct dMass dMass; + +/** + * Check if a mass structure has valid value. + * The function check if the mass and innertia matrix are positive definits + * + * @param m A mass structure to check + * + * @return 1 if both codition are met + */ +ODE_API int dMassCheck(const dMass *m); + +ODE_API void dMassSetZero (dMass *); + +ODE_API void dMassSetParameters (dMass *, dReal themass, + dReal cgx, dReal cgy, dReal cgz, + dReal I11, dReal I22, dReal I33, + dReal I12, dReal I13, dReal I23); + +ODE_API void dMassSetSphere (dMass *, dReal density, dReal radius); +ODE_API void dMassSetSphereTotal (dMass *, dReal total_mass, dReal radius); + +ODE_API void dMassSetCapsule (dMass *, dReal density, int direction, + dReal radius, dReal length); +ODE_API void dMassSetCapsuleTotal (dMass *, dReal total_mass, int direction, + dReal radius, dReal length); + +ODE_API void dMassSetCylinder (dMass *, dReal density, int direction, + dReal radius, dReal length); +ODE_API void dMassSetCylinderTotal (dMass *, dReal total_mass, int direction, + dReal radius, dReal length); + +ODE_API void dMassSetBox (dMass *, dReal density, + dReal lx, dReal ly, dReal lz); +ODE_API void dMassSetBoxTotal (dMass *, dReal total_mass, + dReal lx, dReal ly, dReal lz); + +ODE_API void dMassSetTrimesh (dMass *, dReal density, dGeomID g); + +ODE_API void dMassSetTrimeshTotal (dMass *m, dReal total_mass, dGeomID g); + +ODE_API void dMassAdjust (dMass *, dReal newmass); + +ODE_API void dMassTranslate (dMass *, dReal x, dReal y, dReal z); + +ODE_API void dMassRotate (dMass *, const dMatrix3 R); + +ODE_API void dMassAdd (dMass *a, const dMass *b); + + +/* Backwards compatible API */ +ODE_API_DEPRECATED ODE_API void dMassSetCappedCylinder(dMass *a, dReal b, int c, dReal d, dReal e); +ODE_API_DEPRECATED ODE_API void dMassSetCappedCylinderTotal(dMass *a, dReal b, int c, dReal d, dReal e); + + +struct dMass { + dReal mass; + dVector3 c; + dMatrix3 I; + +#ifdef __cplusplus + dMass() + { dMassSetZero (this); } + void setZero() + { dMassSetZero (this); } + void setParameters (dReal themass, dReal cgx, dReal cgy, dReal cgz, + dReal I11, dReal I22, dReal I33, + dReal I12, dReal I13, dReal I23) + { dMassSetParameters (this,themass,cgx,cgy,cgz,I11,I22,I33,I12,I13,I23); } + + void setSphere (dReal density, dReal radius) + { dMassSetSphere (this,density,radius); } + void setSphereTotal (dReal total, dReal radius) + { dMassSetSphereTotal (this,total,radius); } + + void setCapsule (dReal density, int direction, dReal radius, dReal length) + { dMassSetCapsule (this,density,direction,radius,length); } + void setCapsuleTotal (dReal total, int direction, dReal radius, dReal length) + { dMassSetCapsule (this,total,direction,radius,length); } + + void setCylinder(dReal density, int direction, dReal radius, dReal length) + { dMassSetCylinder (this,density,direction,radius,length); } + void setCylinderTotal(dReal total, int direction, dReal radius, dReal length) + { dMassSetCylinderTotal (this,total,direction,radius,length); } + + void setBox (dReal density, dReal lx, dReal ly, dReal lz) + { dMassSetBox (this,density,lx,ly,lz); } + void setBoxTotal (dReal total, dReal lx, dReal ly, dReal lz) + { dMassSetBoxTotal (this,total,lx,ly,lz); } + + void setTrimesh(dReal density, dGeomID g) + { dMassSetTrimesh (this, density, g); } + void setTrimeshTotal(dReal total, dGeomID g) + { dMassSetTrimeshTotal (this, total, g); } + + void adjust (dReal newmass) + { dMassAdjust (this,newmass); } + void translate (dReal x, dReal y, dReal z) + { dMassTranslate (this,x,y,z); } + void rotate (const dMatrix3 R) + { dMassRotate (this,R); } + void add (const dMass *b) + { dMassAdd (this,b); } +#endif +}; + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/libs/ode-0.16.1/include/ode/matrix.h b/libs/ode-0.16.1/include/ode/matrix.h new file mode 100644 index 0000000..65939b4 --- /dev/null +++ b/libs/ode-0.16.1/include/ode/matrix.h @@ -0,0 +1,200 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +/* optimized and unoptimized vector and matrix functions */ + +#ifndef _ODE_MATRIX_H_ +#define _ODE_MATRIX_H_ + +#include + + +#ifdef __cplusplus +extern "C" { +#endif + + +/* set a vector/matrix of size n to all zeros, or to a specific value. */ + +ODE_API void dSetZero (dReal *a, int n); +ODE_API void dSetValue (dReal *a, int n, dReal value); + + +/* get the dot product of two n*1 vectors. if n <= 0 then + * zero will be returned (in which case a and b need not be valid). + */ + +ODE_API dReal dDot (const dReal *a, const dReal *b, int n); + + +/* get the dot products of (a0,b), (a1,b), etc and return them in outsum. + * all vectors are n*1. if n <= 0 then zeroes will be returned (in which case + * the input vectors need not be valid). this function is somewhat faster + * than calling dDot() for all of the combinations separately. + */ + +/* NOT INCLUDED in the library for now. +void dMultidot2 (const dReal *a0, const dReal *a1, + const dReal *b, dReal *outsum, int n); +*/ + + +/* matrix multiplication. all matrices are stored in standard row format. + * the digit refers to the argument that is transposed: + * 0: A = B * C (sizes: A:p*r B:p*q C:q*r) + * 1: A = B' * C (sizes: A:p*r B:q*p C:q*r) + * 2: A = B * C' (sizes: A:p*r B:p*q C:r*q) + * case 1,2 are equivalent to saying that the operation is A=B*C but + * B or C are stored in standard column format. + */ + +ODE_API void dMultiply0 (dReal *A, const dReal *B, const dReal *C, int p,int q,int r); +ODE_API void dMultiply1 (dReal *A, const dReal *B, const dReal *C, int p,int q,int r); +ODE_API void dMultiply2 (dReal *A, const dReal *B, const dReal *C, int p,int q,int r); + + +/* do an in-place cholesky decomposition on the lower triangle of the n*n + * symmetric matrix A (which is stored by rows). the resulting lower triangle + * will be such that L*L'=A. return 1 on success and 0 on failure (on failure + * the matrix is not positive definite). + */ + +ODE_API int dFactorCholesky (dReal *A, int n); + + +/* solve for x: L*L'*x = b, and put the result back into x. + * L is size n*n, b is size n*1. only the lower triangle of L is considered. + */ + +ODE_API void dSolveCholesky (const dReal *L, dReal *b, int n); + + +/* compute the inverse of the n*n positive definite matrix A and put it in + * Ainv. this is not especially fast. this returns 1 on success (A was + * positive definite) or 0 on failure (not PD). + */ + +ODE_API int dInvertPDMatrix (const dReal *A, dReal *Ainv, int n); + + +/* check whether an n*n matrix A is positive definite, return 1/0 (yes/no). + * positive definite means that x'*A*x > 0 for any x. this performs a + * cholesky decomposition of A. if the decomposition fails then the matrix + * is not positive definite. A is stored by rows. A is not altered. + */ + +ODE_API int dIsPositiveDefinite (const dReal *A, int n); + + +/* factorize a matrix A into L*D*L', where L is lower triangular with ones on + * the diagonal, and D is diagonal. + * A is an n*n matrix stored by rows, with a leading dimension of n rounded + * up to 4. L is written into the strict lower triangle of A (the ones are not + * written) and the reciprocal of the diagonal elements of D are written into + * d. + */ +ODE_API void dFactorLDLT (dReal *A, dReal *d, int n, int nskip); + + +/* solve L*x=b, where L is n*n lower triangular with ones on the diagonal, + * and x,b are n*1. b is overwritten with x. + * the leading dimension of L is `nskip'. + */ +ODE_API void dSolveL1 (const dReal *L, dReal *b, int n, int nskip); + + +/* solve L'*x=b, where L is n*n lower triangular with ones on the diagonal, + * and x,b are n*1. b is overwritten with x. + * the leading dimension of L is `nskip'. + */ +ODE_API void dSolveL1T (const dReal *L, dReal *b, int n, int nskip); + + +/* in matlab syntax: a(1:n) = a(1:n) .* d(1:n) + */ + +ODE_API void dScaleVector (dReal *a, const dReal *d, int n); + +/* The function is an alias for @c dScaleVector. + * It has been deprecated because of a wrong naming schema used. + */ +ODE_API_DEPRECATED ODE_API void dVectorScale (dReal *a, const dReal *d, int n); + + +/* given `L', a n*n lower triangular matrix with ones on the diagonal, + * and `d', a n*1 vector of the reciprocal diagonal elements of an n*n matrix + * D, solve L*D*L'*x=b where x,b are n*1. x overwrites b. + * the leading dimension of L is `nskip'. + */ + +ODE_API void dSolveLDLT (const dReal *L, const dReal *d, dReal *b, int n, int nskip); + + +/* given an L*D*L' factorization of an n*n matrix A, return the updated + * factorization L2*D2*L2' of A plus the following "top left" matrix: + * + * [ b a' ] <-- b is a[0] + * [ a 0 ] <-- a is a[1..n-1] + * + * - L has size n*n, its leading dimension is nskip. L is lower triangular + * with ones on the diagonal. only the lower triangle of L is referenced. + * - d has size n. d contains the reciprocal diagonal elements of D. + * - a has size n. + * the result is written into L, except that the left column of L and d[0] + * are not actually modified. see ldltaddTL.m for further comments. + */ +ODE_API void dLDLTAddTL (dReal *L, dReal *d, const dReal *a, int n, int nskip); + + +/* given an L*D*L' factorization of a permuted matrix A, produce a new + * factorization for row and column `r' removed. + * - A has size n1*n1, its leading dimension in nskip. A is symmetric and + * positive definite. only the lower triangle of A is referenced. + * A itself may actually be an array of row pointers. + * - L has size n2*n2, its leading dimension in nskip. L is lower triangular + * with ones on the diagonal. only the lower triangle of L is referenced. + * - d has size n2. d contains the reciprocal diagonal elements of D. + * - p is a permutation vector. it contains n2 indexes into A. each index + * must be in the range 0..n1-1. + * - r is the row/column of L to remove. + * the new L will be written within the old L, i.e. will have the same leading + * dimension. the last row and column of L, and the last element of d, are + * undefined on exit. + * + * a fast O(n^2) algorithm is used. see ldltremove.m for further comments. + */ +ODE_API void dLDLTRemove (dReal **A, const int *p, dReal *L, dReal *d, + int n1, int n2, int r, int nskip); + + +/* given an n*n matrix A (with leading dimension nskip), remove the r'th row + * and column by moving elements. the new matrix will have the same leading + * dimension. the last row and column of A are untouched on exit. + */ +ODE_API void dRemoveRowCol (dReal *A, int n, int nskip, int r); + +#ifdef __cplusplus +} +#endif + + +#endif diff --git a/libs/ode-0.16.1/include/ode/matrix_coop.h b/libs/ode-0.16.1/include/ode/matrix_coop.h new file mode 100644 index 0000000..b38bf90 --- /dev/null +++ b/libs/ode-0.16.1/include/ode/matrix_coop.h @@ -0,0 +1,291 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001-2003 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#ifndef _ODE_MATRIX_COOP_H_ +#define _ODE_MATRIX_COOP_H_ + + +#include +#include +#include + + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * @defgroup matrix_coop Matrix Cooperative Algorithms + * + * Cooperative algorithms operating on matrices and vectors. + * + * @ingroup coop + */ + + +/** + * @brief Estimates resource requirements for a @c dCooperativelyFactorLDLT call + * + * The function updates the contents of @a requirements to also suffice for calling + * @c dCooperativelyFactorLDLT with the given parameters. + * + * Note: The requirements that could have already been in the @a requirements parameter + * are never decreased. + * + * @param requirements The ResourceRequirements object to update + * @param maximalAllowedThreadCount Maximal value of allowedThreadCount parameter that is going to be used + * @param maximalRowCount Maximal value of rowCount parameter that is going to be used + * @ingroup matrix_coop + * @see dCooperativelyFactorLDLT + * @see dResourceRequirementsCreate + */ +ODE_API void dEstimateCooperativelyFactorLDLTResourceRequirements(dResourceRequirementsID requirements, + unsigned maximalAllowedThreadCount, unsigned maximalRowCount); + +/** + * @brief Cooperatively factorizes a matrix `A' into L*D*L' + * + * The function factorizes a matrix `A' into L*D*L', where `L' is lower triangular with ones on + * the diagonal, and `D' is diagonal. + * @a A is a rowCount*rowCount matrix stored by rows, with a leading dimension of @a rowCount rounded + * up at least to 4 elements. `L; is written into the strict lower triangle of @a A + * (the ones are not written) and the reciprocal of the diagonal elements of `D' are written into @a d. + * + * The @a resources must have had been allocated from a ResourceRequirements object + * estimated in @c dEstimateCooperativelyFactorLDLTResourceRequirements. + * + * The operation is performed cooperatively by up to @a allowedThreadCount threads + * from thread pool available in @a resources. The threading must must not be simultaneously + * used (via other @c dResourceContainerID instances) in other calls that employ its features. + * + * @param resources The resources allocated for the function + * @param allowedThreadCount Maximum thread count to use (the actual thread count could be less, depending on other parameters) + * @param A The `A' matrix + * @param d The `d' vector + * @param rowCount The row count in @a A and @a d + * @param rowskip The actual number of elements to be added to skip to next row in @a A + * @ingroup matrix_coop + * @see dEstimateCooperativelyFactorLDLTResourceRequirements + * @see dResourceContainerAcquire + * @see dCooperativelySolveLDLT + */ +ODE_API void dCooperativelyFactorLDLT(dResourceContainerID resources, unsigned allowedThreadCount, + dReal *A, dReal *d, unsigned rowCount, unsigned rowSkip); + + +/** + * @brief Estimates resource requirements for a @c dCooperativelySolveLDLT call + * + * The function updates the contents of @a requirements to also suffice for calling + * @c dCooperativelySolveLDLT with the given parameters. + * + * Note: The requirements that could have already been in the @a requirements parameter + * are never decreased. + * + * @param requirements The ResourceRequirements object to update + * @param maximalAllowedThreadCount Maximal value of allowedThreadCount parameter that is going to be used + * @param maximalRowCount Maximal value of rowCount parameter that is going to be used + * @ingroup matrix_coop + * @see dCooperativelySolveLDLT + * @see dResourceRequirementsCreate + */ +ODE_API void dEstimateCooperativelySolveLDLTResourceRequirements(dResourceRequirementsID requirements, + unsigned maximalAllowedThreadCount, unsigned maximalRowCount); + +/** + * @brief Cooperatively solves L*D*L'*x=b + * + * Given `L', a rowCount*rowCount lower triangular matrix with ones on the diagonal, + * and `d', a rowCount*1 vector of the reciprocal diagonal elements of a rowCount*rowCount matrix + * D, the function solves L*D*L'*x=b where `x' and `b' are rowCount*1. + * The leading dimension of @a L is @a rowSkip. The resulting vector `x' overwrites @a b. + * + * The @a resources must have had been allocated from a ResourceRequirements object + * estimated in @c dEstimateCooperativelySolveLDLTResourceRequirements. + * + * The operation is performed cooperatively by up to @a allowedThreadCount threads + * from thread pool available in @a resources. The threading must must not be simultaneously + * used (via other @c dResourceContainerID instances) in other calls that employ its features. + * + * @param resources The resources allocated for the function + * @param allowedThreadCount Maximum thread count to use (the actual thread count could be less, depending on other parameters) + * @param L The `L' matrix + * @param d The `d' vector + * @param b The `b' vector; also the result is stored here + * @param rowCount The row count in @a L, @a d and @a b + * @param rowskip The actual number of elements to be added to skip to next row in @a L + * @ingroup matrix_coop + * @see dEstimateCooperativelySolveLDLTResourceRequirements + * @see dResourceContainerAcquire + * @see dCooperativelyFactorLDLT + */ +ODE_API void dCooperativelySolveLDLT(dResourceContainerID resources, unsigned allowedThreadCount, + const dReal *L, const dReal *d, dReal *b, unsigned rowCount, unsigned rowSkip); + + +/** + * @brief Estimates resource requirements for a @c dCooperativelySolveL1Straight call + * + * The function updates the contents of @a requirements to also suffice for calling + * @c dCooperativelySolveL1Straight with the given parameters. + * + * Note: The requirements that could have already been in the @a requirements parameter + * are never decreased. + * + * @param requirements The ResourceRequirements object to update + * @param maximalAllowedThreadCount Maximal value of allowedThreadCount parameter that is going to be used + * @param maximalRowCount Maximal value of rowCount parameter that is going to be used + * @ingroup matrix_coop + * @see dCooperativelySolveL1Straight + * @see dResourceRequirementsCreate + */ +ODE_API void dEstimateCooperativelySolveL1StraightResourceRequirements(dResourceRequirementsID requirements, + unsigned maximalAllowedThreadCount, unsigned maximalRowCount); + +/** + * @brief Cooperatively solves L*x=b + * + * The function solves L*x=b, where `L' is rowCount*rowCount lower triangular with ones on the diagonal, + * and `x', `b' are rowCount*1. The leading dimension of @a L is @a rowSkip. + * @a b is overwritten with `x'. + * + * The @a resources must have had been allocated from a ResourceRequirements object + * estimated in @c dEstimateCooperativelySolveL1StraightResourceRequirements. + * + * The operation is performed cooperatively by up to @a allowedThreadCount threads + * from thread pool available in @a resources. The threading must must not be simultaneously + * used (via other @c dResourceContainerID instances) in other calls that employ its features. + * + * @param resources The resources allocated for the function + * @param allowedThreadCount Maximum thread count to use (the actual thread count could be less, depending on other parameters) + * @param L The `L' matrix + * @param b The `b' vector; also the result is stored here + * @param rowCount The row count in @a L and @a b + * @param rowskip The actual number of elements to be added to skip to next row in @a L + * @ingroup matrix_coop + * @see dEstimateCooperativelySolveL1StraightResourceRequirements + * @see dResourceContainerAcquire + * @see dCooperativelyFactorLDLT + */ +ODE_API void dCooperativelySolveL1Straight(dResourceContainerID resources, unsigned allowedThreadCount, + const dReal *L, dReal *b, unsigned rowCount, unsigned rowSkip); + + +/** + * @brief Estimates resource requirements for a @c dCooperativelySolveL1Transposed call + * + * The function updates the contents of @a requirements to also suffice for calling + * @c dCooperativelySolveL1Transposed with the given parameters. + * + * Note: The requirements that could have already been in the @a requirements parameter + * are never decreased. + * + * @param requirements The ResourceRequirements object to update + * @param maximalAllowedThreadCount Maximal value of allowedThreadCount parameter that is going to be used + * @param maximalRowCount Maximal value of rowCount parameter that is going to be used + * @ingroup matrix_coop + * @see dCooperativelySolveL1Transposed + * @see dResourceRequirementsCreate + */ +ODE_API void dEstimateCooperativelySolveL1TransposedResourceRequirements(dResourceRequirementsID requirements, + unsigned maximalAllowedThreadCount, unsigned maximalRowCount); + +/** + * @brief Cooperatively solves L'*x=b + * + * The function solves L'*x=b, where `L' is rowCount*rowCount lower triangular with ones on the diagonal, + * and `x', b are rowCount*1. The leading dimension of @a L is @a rowSkip. + * @a b is overwritten with `x'. + * + * The @a resources must have had been allocated from a ResourceRequirements object + * estimated in @c dEstimateCooperativelySolveL1TransposedResourceRequirements. + * + * The operation is performed cooperatively by up to @a allowedThreadCount threads + * from thread pool available in @a resources. The threading must must not be simultaneously + * used (via other @c dResourceContainerID instances) in other calls that employ its features. + * + * @param resources The resources allocated for the function + * @param allowedThreadCount Maximum thread count to use (the actual thread count could be less, depending on other parameters) + * @param L The `L' matrix + * @param b The `b' vector; also the result is stored here + * @param rowCount The row count in @a L and @a b + * @param rowskip The actual number of elements to be added to skip to next row in @a L + * @ingroup matrix_coop + * @see dEstimateCooperativelySolveL1TransposedResourceRequirements + * @see dResourceContainerAcquire + * @see dCooperativelyFactorLDLT + */ +ODE_API void dCooperativelySolveL1Transposed(dResourceContainerID resources, unsigned allowedThreadCount, + const dReal *L, dReal *b, unsigned rowCount, unsigned rowSkip); + + +/** + * @brief Estimates resource requirements for a @c dCooperativelyScaleVector call + * + * The function updates the contents of @a requirements to also suffice for calling + * @c dCooperativelyScaleVector with the given parameters. + * + * Note: The requirements that could have already been in the @a requirements parameter + * are never decreased. + * + * @param requirements The ResourceRequirements object to update + * @param maximalAllowedThreadCount Maximal value of allowedThreadCount parameter that is going to be used + * @param maximalElementCount Maximal value of elementCount parameter that is going to be used + * @ingroup matrix_coop + * @see dCooperativelyScaleVector + * @see dResourceRequirementsCreate + */ +ODE_API void dEstimateCooperativelyScaleVectorResourceRequirements(dResourceRequirementsID requirements, + unsigned maximalAllowedThreadCount, unsigned maximalElementCount); + +/** + * @brief Multiplies elements of one vector by corresponding element of another one + * + * In matlab syntax, the operation performed is: dataVector(1:elementCount) = dataVector(1:elementCount) .* scaleVector(1:elementCount) + * + * The @a resources must have had been allocated from a ResourceRequirements object + * estimated in @c dEstimateCooperativelyScaleVectorResourceRequirements. + * + * The operation is performed cooperatively by up to @a allowedThreadCount threads + * from thread pool available in @a resources. The threading must must not be simultaneously + * used (via other @c dResourceContainerID instances) in other calls that employ its features. + * + * @param resources The resources allocated for the function + * @param allowedThreadCount Maximum thread count to use (the actual thread count could be less, depending on other parameters) + * @param dataVector The vector to be scaled in place + * @param scaleVector The scale vector + * @param elementCount The number of elements in @a dataVector and @a scaleVector + * @ingroup matrix_coop + * @see dEstimateCooperativelyScaleVectorResourceRequirements + * @see dResourceContainerAcquire + * @see dCooperativelyFactorLDLT + */ +ODE_API void dCooperativelyScaleVector(dResourceContainerID resources, unsigned allowedThreadCount, + dReal *dataVector, const dReal *scaleVector, unsigned elementCount); + + +#ifdef __cplusplus +} // extern "C" +#endif + + +#endif // #ifndef _ODE_MATRIX_COOP_H_ diff --git a/libs/ode-0.16.1/include/ode/memory.h b/libs/ode-0.16.1/include/ode/memory.h new file mode 100644 index 0000000..8e49202 --- /dev/null +++ b/libs/ode-0.16.1/include/ode/memory.h @@ -0,0 +1,59 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +/* this comes from the `reuse' library. copy any changes back to the source */ + +#ifndef _ODE_MEMORY_H_ +#define _ODE_MEMORY_H_ + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/* function types to allocate and free memory */ +typedef void * dAllocFunction (dsizeint size); +typedef void * dReallocFunction (void *ptr, dsizeint oldsize, dsizeint newsize); +typedef void dFreeFunction (void *ptr, dsizeint size); + +/* set new memory management functions. if fn is 0, the default handlers are + * used. */ +ODE_API void dSetAllocHandler (dAllocFunction *fn); +ODE_API void dSetReallocHandler (dReallocFunction *fn); +ODE_API void dSetFreeHandler (dFreeFunction *fn); + +/* get current memory management functions */ +ODE_API dAllocFunction *dGetAllocHandler (void); +ODE_API dReallocFunction *dGetReallocHandler (void); +ODE_API dFreeFunction *dGetFreeHandler (void); + +/* allocate and free memory. */ +ODE_API void * dAlloc (dsizeint size); +ODE_API void * dRealloc (void *ptr, dsizeint oldsize, dsizeint newsize); +ODE_API void dFree (void *ptr, dsizeint size); + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/libs/ode-0.16.1/include/ode/misc.h b/libs/ode-0.16.1/include/ode/misc.h new file mode 100644 index 0000000..01655ea --- /dev/null +++ b/libs/ode-0.16.1/include/ode/misc.h @@ -0,0 +1,86 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +/* miscellaneous math functions. these are mostly useful for testing */ + +#ifndef _ODE_MISC_H_ +#define _ODE_MISC_H_ + +#include + + +#ifdef __cplusplus +extern "C" { +#endif + + +/* return 1 if the random number generator is working. */ +ODE_API int dTestRand(void); + +/* return next 32 bit random number. this uses a not-very-random linear + * congruential method. + */ +ODE_API unsigned long dRand(void); + +/* get and set the current random number seed. */ +ODE_API unsigned long dRandGetSeed(void); +ODE_API void dRandSetSeed (unsigned long s); + +/* return a random integer between 0..n-1. the distribution will get worse + * as n approaches 2^32. + */ +ODE_API int dRandInt (int n); + +/* return a random real number between 0..1 */ +ODE_API dReal dRandReal(void); + +/* print out a matrix */ +ODE_API void dPrintMatrix (const dReal *A, int n, int m, const char *fmt, FILE *f); + +/* make a random vector with entries between +/- range. A has n elements. */ +ODE_API void dMakeRandomVector (dReal *A, int n, dReal range); + +/* make a random matrix with entries between +/- range. A has size n*m. */ +ODE_API void dMakeRandomMatrix (dReal *A, int n, int m, dReal range); + +/* clear the upper triangle of a square matrix */ +ODE_API void dClearUpperTriangle (dReal *A, int n); + +/* return the maximum element difference between the two n*m matrices */ +ODE_API dReal dMaxDifference (const dReal *A, const dReal *B, int n, int m); + +/* return the maximum element difference between the lower triangle of two + * n*n matrices */ +ODE_API dReal dMaxDifferenceLowerTriangle (const dReal *A, const dReal *B, int n); + + +#ifdef __cplusplus +} +#endif + + +#ifdef __cplusplus +static inline void dPrintMatrix (const dReal *A, int n, int m, const char *fmt="%10.4f ") { dPrintMatrix(A, n, m, fmt, stdout); } +#endif + + +#endif diff --git a/libs/ode-0.16.1/include/ode/objects.h b/libs/ode-0.16.1/include/ode/objects.h new file mode 100644 index 0000000..4796d56 --- /dev/null +++ b/libs/ode-0.16.1/include/ode/objects.h @@ -0,0 +1,3396 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#ifndef _ODE_OBJECTS_H_ +#define _ODE_OBJECTS_H_ + +#include +#include +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * @defgroup world World + * + * The world object is a container for rigid bodies and joints. Objects in + * different worlds can not interact, for example rigid bodies from two + * different worlds can not collide. + * + * All the objects in a world exist at the same point in time, thus one + * reason to use separate worlds is to simulate systems at different rates. + * Most applications will only need one world. + */ + +/** + * @brief Create a new, empty world and return its ID number. + * @return an identifier + * @ingroup world + */ +ODE_API dWorldID dWorldCreate(void); + + +/** + * @brief Destroy a world and everything in it. + * + * This includes all bodies, and all joints that are not part of a joint + * group. Joints that are part of a joint group will be deactivated, and + * can be destroyed by calling, for example, dJointGroupEmpty(). + * @ingroup world + * @param world the identifier for the world the be destroyed. + */ +ODE_API void dWorldDestroy (dWorldID world); + + +/** + * @brief Set the user-data pointer + * @param world the world to set the data on + * @param data + * @ingroup world + */ +ODE_API void dWorldSetData (dWorldID world, void* data); + + +/** + * @brief Get the user-data pointer + * @param world the world to set the data on + * @param data + * @ingroup world + */ +ODE_API void* dWorldGetData (dWorldID world); + + +/** + * @brief Set the world's global gravity vector. + * + * The units are m/s^2, so Earth's gravity vector would be (0,0,-9.81), + * assuming that +z is up. The default is no gravity, i.e. (0,0,0). + * + * @ingroup world + */ +ODE_API void dWorldSetGravity (dWorldID, dReal x, dReal y, dReal z); + + +/** + * @brief Get the gravity vector for a given world. + * @ingroup world + */ +ODE_API void dWorldGetGravity (dWorldID, dVector3 gravity); + + +/** + * @brief Set the global ERP value, that controls how much error + * correction is performed in each time step. + * @ingroup world + * @param dWorldID the identifier of the world. + * @param erp Typical values are in the range 0.1--0.8. The default is 0.2. + */ +ODE_API void dWorldSetERP (dWorldID, dReal erp); + +/** + * @brief Get the error reduction parameter. + * @ingroup world + * @return ERP value + */ +ODE_API dReal dWorldGetERP (dWorldID); + + +/** + * @brief Set the global CFM (constraint force mixing) value. + * @ingroup world + * @param cfm Typical values are in the range @m{10^{-9}} -- 1. + * The default is 10^-5 if single precision is being used, or 10^-10 + * if double precision is being used. + */ +ODE_API void dWorldSetCFM (dWorldID, dReal cfm); + +/** + * @brief Get the constraint force mixing value. + * @ingroup world + * @return CFM value + */ +ODE_API dReal dWorldGetCFM (dWorldID); + + +#define dWORLDSTEP_THREADCOUNT_UNLIMITED dTHREADING_THREAD_COUNT_UNLIMITED + +/** + * @brief Set maximum threads to be used for island stepping + * + * The actual number of threads that is going to be used will be the minimum + * of this limit and number of threads in the threading pool. By default + * there is no limit (@c dWORLDSTEP_THREADCOUNT_UNLIMITED). + * + * @warning + * WARNING! Running island stepping in multiple threads requires allocating + * individual stepping memory buffer for each of those threads. The size of buffers + * allocated is the size needed to handle the largest island in the world. + * + * Note: Setting a limit for island stepping does not affect threading at lower + * levels in stepper functions. The sub-calls scheduled from them can be executed + * in as many threads as there are available in the pool. + * + * @param w The world affected + * @param count Thread count limit value for island stepping + * @ingroup world + * @see dWorldGetStepIslandsProcessingMaxThreadCount + */ +ODE_API void dWorldSetStepIslandsProcessingMaxThreadCount(dWorldID w, unsigned count); +/** + * @brief Get maximum threads that are allowed to be used for island stepping. + * + * Please read commentaries to @c dWorldSetStepIslandsProcessingMaxThreadCount for + * important information regarding the value returned. + * + * @param w The world queried + * @returns Current thread count limit value for island stepping + * @ingroup world + * @see dWorldSetStepIslandsProcessingMaxThreadCount + */ +ODE_API unsigned dWorldGetStepIslandsProcessingMaxThreadCount(dWorldID w); + +/** + * @brief Set the world to use shared working memory along with another world. + * + * The worlds allocate working memory internally for simulation stepping. This + * memory is cached among the calls to @c dWordStep and @c dWorldQuickStep. + * Similarly, several worlds can be set up to share this memory caches thus + * reducing overall memory usage by cost of making worlds inappropriate for + * simultaneous simulation in multiple threads. + * + * If null value is passed for @a from_world parameter the world is detached from + * sharing and returns to defaults for working memory, reservation policy and + * memory manager as if just created. This can also be used to enable use of shared + * memory for a world that has already had working memory allocated privately. + * Normally using shared memory after a world has its private working memory allocated + * is prohibited. + * + * Allocation policy used can only increase world's internal reserved memory size + * and never decreases it. @c dWorldCleanupWorkingMemory can be used to release + * working memory for a world in case if number of objects/joint decreases + * significantly in it. + * + * With sharing working memory worlds also automatically share memory reservation + * policy and memory manager. Thus, these parameters need to be customized for + * initial world to be used as sharing source only. + * + * If worlds share working memory they must also use compatible threading implementations + * (i.e. it is illegal for one world to perform stepping with self-threaded implementation + * when the other world is assigned a multi-threaded implementation). + * For more information read section about threading approaches in ODE. + * + * Failure result status means a memory allocation failure. + * + * @param w The world to use the shared memory with. + * @param from_world Null or the world the shared memory is to be used from. + * @returns 1 for success and 0 for failure. + * + * @ingroup world + * @see dWorldCleanupWorkingMemory + * @see dWorldSetStepMemoryReservationPolicy + * @see dWorldSetStepMemoryManager + */ +ODE_API int dWorldUseSharedWorkingMemory(dWorldID w, dWorldID from_world/*=NULL*/); + +/** + * @brief Release internal working memory allocated for world + * + * The worlds allocate working memory internally for simulation stepping. This + * function can be used to free world's internal memory cache in case if number of + * objects/joints in the world decreases significantly. By default, internal + * allocation policy is used to only increase cache size as necessary and never + * decrease it. + * + * If a world shares its working memory with other worlds the cache deletion + * affects all the linked worlds. However the shared status itself remains intact. + * + * The function call does affect neither memory reservation policy nor memory manager. + * + * @param w The world to release working memory for. + * + * @ingroup world + * @see dWorldUseSharedWorkingMemory + * @see dWorldSetStepMemoryReservationPolicy + * @see dWorldSetStepMemoryManager + */ +ODE_API void dWorldCleanupWorkingMemory(dWorldID w); + + +#define dWORLDSTEP_RESERVEFACTOR_DEFAULT 1.2f +#define dWORLDSTEP_RESERVESIZE_DEFAULT 65536U + +/** + * @struct dWorldStepReserveInfo + * @brief Memory reservation policy descriptor structure for world stepping functions. + * + * @c struct_size should be assigned the size of the structure. + * + * @c reserve_factor is a quotient that is multiplied by required memory size + * to allocate extra reserve whenever reallocation is needed. + * + * @c reserve_minimum is a minimum size that is checked against whenever reallocation + * is needed to allocate expected working memory minimum at once without extra + * reallocations as number of bodies/joints grows. + * + * @ingroup world + * @see dWorldSetStepMemoryReservationPolicy + */ +typedef struct +{ + unsigned struct_size; + float reserve_factor; /* Use float as precision does not matter here*/ + unsigned reserve_minimum; + +} dWorldStepReserveInfo; + +/** + * @brief Set memory reservation policy for world to be used with simulation stepping functions + * + * The function allows to customize reservation policy to be used for internal + * memory which is allocated to aid simulation for a world. By default, values + * of @c dWORLDSTEP_RESERVEFACTOR_DEFAULT and @c dWORLDSTEP_RESERVESIZE_DEFAULT + * are used. + * + * Passing @a policyinfo argument as NULL results in reservation policy being + * reset to defaults as if the world has been just created. The content of + * @a policyinfo structure is copied internally and does not need to remain valid + * after the call returns. + * + * If the world uses working memory sharing, changing memory reservation policy + * affects all the worlds linked together. + * + * Failure result status means a memory allocation failure. + * + * @param w The world to change memory reservation policy for. + * @param policyinfo Null or a pointer to policy descriptor structure. + * @returns 1 for success and 0 for failure. + * + * @ingroup world + * @see dWorldUseSharedWorkingMemory + */ +ODE_API int dWorldSetStepMemoryReservationPolicy(dWorldID w, const dWorldStepReserveInfo *policyinfo/*=NULL*/); + +/** +* @struct dWorldStepMemoryFunctionsInfo +* @brief World stepping memory manager descriptor structure +* +* This structure is intended to define the functions of memory manager to be used +* with world stepping functions. +* +* @c struct_size should be assigned the size of the structure +* +* @c alloc_block is a function to allocate memory block of given size. +* +* @c shrink_block is a function to shrink existing memory block to a smaller size. +* It must preserve the contents of block head while shrinking. The new block size +* is guaranteed to be always less than the existing one. +* +* @c free_block is a function to delete existing memory block. +* +* @ingroup init +* @see dWorldSetStepMemoryManager +*/ +typedef struct +{ + unsigned struct_size; + void *(*alloc_block)(dsizeint block_size); + void *(*shrink_block)(void *block_pointer, dsizeint block_current_size, dsizeint block_smaller_size); + void (*free_block)(void *block_pointer, dsizeint block_current_size); + +} dWorldStepMemoryFunctionsInfo; + +/** +* @brief Set memory manager for world to be used with simulation stepping functions +* +* The function allows to customize memory manager to be used for internal +* memory allocation during simulation for a world. By default, @c dAlloc/@c dRealloc/@c dFree +* based memory manager is used. +* +* Passing @a memfuncs argument as NULL results in memory manager being +* reset to default one as if the world has been just created. The content of +* @a memfuncs structure is copied internally and does not need to remain valid +* after the call returns. +* +* If the world uses working memory sharing, changing memory manager +* affects all the worlds linked together. +* +* Failure result status means a memory allocation failure. +* +* @param w The world to change memory reservation policy for. +* @param memfuncs Null or a pointer to memory manager descriptor structure. +* @returns 1 for success and 0 for failure. +* +* @ingroup world +* @see dWorldUseSharedWorkingMemory +*/ +ODE_API int dWorldSetStepMemoryManager(dWorldID w, const dWorldStepMemoryFunctionsInfo *memfuncs); + +/** + * @brief Assign threading implementation to be used for [quick]stepping the world. + * + * @warning It is not recommended to assign the same threading implementation to + * different worlds if they are going to be called in parallel. In particular this + * makes resources preallocation for threaded calls to lose its sense. + * Built-in threading implementation is likely to crash if misused this way. + * + * @param w The world to change threading implementation for. + * @param functions_info Pointer to threading functions structure + * @param threading_impl ID of threading implementation object + * + * @ingroup world + */ +ODE_API void dWorldSetStepThreadingImplementation(dWorldID w, const dThreadingFunctionsInfo *functions_info, dThreadingImplementationID threading_impl); + +/** + * @brief Step the world. + * + * This uses a "big matrix" method that takes time on the order of m^3 + * and memory on the order of m^2, where m is the total number of constraint + * rows. For large systems this will use a lot of memory and can be very slow, + * but this is currently the most accurate method. + * + * Failure result status means that the memory allocation has failed for operation. + * In such a case all the objects remain in unchanged state and simulation can be + * retried as soon as more memory is available. + * + * @param w The world to be stepped + * @param stepsize The number of seconds that the simulation has to advance. + * @returns 1 for success and 0 for failure + * + * @ingroup world + */ +ODE_API int dWorldStep (dWorldID w, dReal stepsize); + +/** + * @brief Quick-step the world. + * + * This uses an iterative method that takes time on the order of m*N + * and memory on the order of m, where m is the total number of constraint + * rows N is the number of iterations. + * For large systems this is a lot faster than dWorldStep(), + * but it is less accurate. + * + * QuickStep is great for stacks of objects especially when the + * auto-disable feature is used as well. + * However, it has poor accuracy for near-singular systems. + * Near-singular systems can occur when using high-friction contacts, motors, + * or certain articulated structures. For example, a robot with multiple legs + * sitting on the ground may be near-singular. + * + * There are ways to help overcome QuickStep's inaccuracy problems: + * + * \li Increase CFM. + * \li Reduce the number of contacts in your system (e.g. use the minimum + * number of contacts for the feet of a robot or creature). + * \li Don't use excessive friction in the contacts. + * \li Use contact slip if appropriate + * \li Avoid kinematic loops (however, kinematic loops are inevitable in + * legged creatures). + * \li Don't use excessive motor strength. + * \liUse force-based motors instead of velocity-based motors. + * + * Increasing the number of QuickStep iterations may help a little bit, but + * it is not going to help much if your system is really near singular. + * + * Failure result status means that the memory allocation has failed for operation. + * In such a case all the objects remain in unchanged state and simulation can be + * retried as soon as more memory is available. + * + * @param w The world to be stepped + * @param stepsize The number of seconds that the simulation has to advance. + * @returns 1 for success and 0 for failure + * + * @ingroup world + */ +ODE_API int dWorldQuickStep (dWorldID w, dReal stepsize); + + +/** +* @brief Converts an impulse to a force. +* @ingroup world +* @remarks +* If you want to apply a linear or angular impulse to a rigid body, +* instead of a force or a torque, then you can use this function to convert +* the desired impulse into a force/torque vector before calling the +* BodyAdd... function. +* The current algorithm simply scales the impulse by 1/stepsize, +* where stepsize is the step size for the next step that will be taken. +* This function is given a dWorldID because, in the future, the force +* computation may depend on integrator parameters that are set as +* properties of the world. +*/ +ODE_API void dWorldImpulseToForce +( + dWorldID, dReal stepsize, + dReal ix, dReal iy, dReal iz, dVector3 force + ); + + +/** + * @brief Set the number of iterations that the QuickStep method performs per + * step. + * @ingroup world + * @remarks + * More iterations will give a more accurate solution, but will take + * longer to compute. + * @param num The default is 20 iterations. + */ +ODE_API void dWorldSetQuickStepNumIterations (dWorldID, int num); + + +/** + * @brief Get the number of iterations that the QuickStep method performs per + * step. + * @ingroup world + * @return nr of iterations + */ +ODE_API int dWorldGetQuickStepNumIterations (dWorldID); + +/** + * @brief Set the SOR over-relaxation parameter + * @ingroup world + * @param over_relaxation value to use by SOR + */ +ODE_API void dWorldSetQuickStepW (dWorldID, dReal over_relaxation); + +/** + * @brief Get the SOR over-relaxation parameter + * @ingroup world + * @returns the over-relaxation setting + */ +ODE_API dReal dWorldGetQuickStepW (dWorldID); + +/* World contact parameter functions */ + +/** + * @brief Set the maximum correcting velocity that contacts are allowed + * to generate. + * @ingroup world + * @param vel The default value is infinity (i.e. no limit). + * @remarks + * Reducing this value can help prevent "popping" of deeply embedded objects. + */ +ODE_API void dWorldSetContactMaxCorrectingVel (dWorldID, dReal vel); + +/** + * @brief Get the maximum correcting velocity that contacts are allowed + * to generated. + * @ingroup world + */ +ODE_API dReal dWorldGetContactMaxCorrectingVel (dWorldID); + +/** + * @brief Set the depth of the surface layer around all geometry objects. + * @ingroup world + * @remarks + * Contacts are allowed to sink into the surface layer up to the given + * depth before coming to rest. + * @param depth The default value is zero. + * @remarks + * Increasing this to some small value (e.g. 0.001) can help prevent + * jittering problems due to contacts being repeatedly made and broken. + */ +ODE_API void dWorldSetContactSurfaceLayer (dWorldID, dReal depth); + +/** + * @brief Get the depth of the surface layer around all geometry objects. + * @ingroup world + * @returns the depth + */ +ODE_API dReal dWorldGetContactSurfaceLayer (dWorldID); + + +/** + * @defgroup disable Automatic Enabling and Disabling + * @ingroup world bodies + * + * Every body can be enabled or disabled. Enabled bodies participate in the + * simulation, while disabled bodies are turned off and do not get updated + * during a simulation step. New bodies are always created in the enabled state. + * + * A disabled body that is connected through a joint to an enabled body will be + * automatically re-enabled at the next simulation step. + * + * Disabled bodies do not consume CPU time, therefore to speed up the simulation + * bodies should be disabled when they come to rest. This can be done automatically + * with the auto-disable feature. + * + * If a body has its auto-disable flag turned on, it will automatically disable + * itself when + * @li It has been idle for a given number of simulation steps. + * @li It has also been idle for a given amount of simulation time. + * + * A body is considered to be idle when the magnitudes of both its + * linear average velocity and angular average velocity are below given thresholds. + * The sample size for the average defaults to one and can be disabled by setting + * to zero with + * + * Thus, every body has six auto-disable parameters: an enabled flag, a idle step + * count, an idle time, linear/angular average velocity thresholds, and the + * average samples count. + * + * Newly created bodies get these parameters from world. + */ + +/** + * @brief Get auto disable linear average threshold for newly created bodies. + * @ingroup disable + * @return the threshold + */ +ODE_API dReal dWorldGetAutoDisableLinearThreshold (dWorldID); + +/** + * @brief Set auto disable linear average threshold for newly created bodies. + * @param linear_average_threshold default is 0.01 + * @ingroup disable + */ +ODE_API void dWorldSetAutoDisableLinearThreshold (dWorldID, dReal linear_average_threshold); + +/** + * @brief Get auto disable angular average threshold for newly created bodies. + * @ingroup disable + * @return the threshold + */ +ODE_API dReal dWorldGetAutoDisableAngularThreshold (dWorldID); + +/** + * @brief Set auto disable angular average threshold for newly created bodies. + * @param linear_average_threshold default is 0.01 + * @ingroup disable + */ +ODE_API void dWorldSetAutoDisableAngularThreshold (dWorldID, dReal angular_average_threshold); + +/** + * @brief Get auto disable sample count for newly created bodies. + * @ingroup disable + * @return number of samples used + */ +ODE_API int dWorldGetAutoDisableAverageSamplesCount (dWorldID); + +/** + * @brief Set auto disable average sample count for newly created bodies. + * @ingroup disable + * @param average_samples_count Default is 1, meaning only instantaneous velocity is used. + * Set to zero to disable sampling and thus prevent any body from auto-disabling. + */ +ODE_API void dWorldSetAutoDisableAverageSamplesCount (dWorldID, unsigned int average_samples_count ); + +/** + * @brief Get auto disable steps for newly created bodies. + * @ingroup disable + * @return nr of steps + */ +ODE_API int dWorldGetAutoDisableSteps (dWorldID); + +/** + * @brief Set auto disable steps for newly created bodies. + * @ingroup disable + * @param steps default is 10 + */ +ODE_API void dWorldSetAutoDisableSteps (dWorldID, int steps); + +/** + * @brief Get auto disable time for newly created bodies. + * @ingroup disable + * @return nr of seconds + */ +ODE_API dReal dWorldGetAutoDisableTime (dWorldID); + +/** + * @brief Set auto disable time for newly created bodies. + * @ingroup disable + * @param time default is 0 seconds + */ +ODE_API void dWorldSetAutoDisableTime (dWorldID, dReal time); + +/** + * @brief Get auto disable flag for newly created bodies. + * @ingroup disable + * @return 0 or 1 + */ +ODE_API int dWorldGetAutoDisableFlag (dWorldID); + +/** + * @brief Set auto disable flag for newly created bodies. + * @ingroup disable + * @param do_auto_disable default is false. + */ +ODE_API void dWorldSetAutoDisableFlag (dWorldID, int do_auto_disable); + + +/** + * @defgroup damping Damping + * @ingroup bodies world + * + * Damping serves two purposes: reduce simulation instability, and to allow + * the bodies to come to rest (and possibly auto-disabling them). + * + * Bodies are constructed using the world's current damping parameters. Setting + * the scales to 0 disables the damping. + * + * Here is how it is done: after every time step linear and angular + * velocities are tested against the corresponding thresholds. If they + * are above, they are multiplied by (1 - scale). So a negative scale value + * will actually increase the speed, and values greater than one will + * make the object oscillate every step; both can make the simulation unstable. + * + * To disable damping just set the damping scale to zero. + * + * You can also limit the maximum angular velocity. In contrast to the damping + * functions, the angular velocity is affected before the body is moved. + * This means that it will introduce errors in joints that are forcing the body + * to rotate too fast. Some bodies have naturally high angular velocities + * (like cars' wheels), so you may want to give them a very high (like the default, + * dInfinity) limit. + * + * @note The velocities are damped after the stepper function has moved the + * object. Otherwise the damping could introduce errors in joints. First the + * joint constraints are processed by the stepper (moving the body), then + * the damping is applied. + * + * @note The damping happens right after the moved callback is called; this way + * it still possible use the exact velocities the body has acquired during the + * step. You can even use the callback to create your own customized damping. + */ + +/** + * @brief Get the world's linear damping threshold. + * @ingroup damping + */ +ODE_API dReal dWorldGetLinearDampingThreshold (dWorldID w); + +/** + * @brief Set the world's linear damping threshold. + * @param threshold The damping won't be applied if the linear speed is + * below this threshold. Default is 0.01. + * @ingroup damping + */ +ODE_API void dWorldSetLinearDampingThreshold(dWorldID w, dReal threshold); + +/** + * @brief Get the world's angular damping threshold. + * @ingroup damping + */ +ODE_API dReal dWorldGetAngularDampingThreshold (dWorldID w); + +/** + * @brief Set the world's angular damping threshold. + * @param threshold The damping won't be applied if the angular speed is + * below this threshold. Default is 0.01. + * @ingroup damping + */ +ODE_API void dWorldSetAngularDampingThreshold(dWorldID w, dReal threshold); + +/** + * @brief Get the world's linear damping scale. + * @ingroup damping + */ +ODE_API dReal dWorldGetLinearDamping (dWorldID w); + +/** + * @brief Set the world's linear damping scale. + * @param scale The linear damping scale that is to be applied to bodies. + * Default is 0 (no damping). Should be in the interval [0, 1]. + * @ingroup damping + */ +ODE_API void dWorldSetLinearDamping (dWorldID w, dReal scale); + +/** + * @brief Get the world's angular damping scale. + * @ingroup damping + */ +ODE_API dReal dWorldGetAngularDamping (dWorldID w); + +/** + * @brief Set the world's angular damping scale. + * @param scale The angular damping scale that is to be applied to bodies. + * Default is 0 (no damping). Should be in the interval [0, 1]. + * @ingroup damping + */ +ODE_API void dWorldSetAngularDamping(dWorldID w, dReal scale); + +/** + * @brief Convenience function to set body linear and angular scales. + * @param linear_scale The linear damping scale that is to be applied to bodies. + * @param angular_scale The angular damping scale that is to be applied to bodies. + * @ingroup damping + */ +ODE_API void dWorldSetDamping(dWorldID w, + dReal linear_scale, + dReal angular_scale); + +/** + * @brief Get the default maximum angular speed. + * @ingroup damping + * @sa dBodyGetMaxAngularSpeed() + */ +ODE_API dReal dWorldGetMaxAngularSpeed (dWorldID w); + + +/** + * @brief Set the default maximum angular speed for new bodies. + * @ingroup damping + * @sa dBodySetMaxAngularSpeed() + */ +ODE_API void dWorldSetMaxAngularSpeed (dWorldID w, dReal max_speed); + + + +/** + * @defgroup bodies Rigid Bodies + * + * A rigid body has various properties from the point of view of the + * simulation. Some properties change over time: + * + * @li Position vector (x,y,z) of the body's point of reference. + * Currently the point of reference must correspond to the body's center of mass. + * @li Linear velocity of the point of reference, a vector (vx,vy,vz). + * @li Orientation of a body, represented by a quaternion (qs,qx,qy,qz) or + * a 3x3 rotation matrix. + * @li Angular velocity vector (wx,wy,wz) which describes how the orientation + * changes over time. + * + * Other body properties are usually constant over time: + * + * @li Mass of the body. + * @li Position of the center of mass with respect to the point of reference. + * In the current implementation the center of mass and the point of + * reference must coincide. + * @li Inertia matrix. This is a 3x3 matrix that describes how the body's mass + * is distributed around the center of mass. Conceptually each body has an + * x-y-z coordinate frame embedded in it that moves and rotates with the body. + * + * The origin of this coordinate frame is the body's point of reference. Some values + * in ODE (vectors, matrices etc) are relative to the body coordinate frame, and others + * are relative to the global coordinate frame. + * + * Note that the shape of a rigid body is not a dynamical property (except insofar as + * it influences the various mass properties). It is only collision detection that cares + * about the detailed shape of the body. + */ + + +/** + * @brief Get auto disable linear average threshold. + * @ingroup bodies disable + * @return the threshold + */ +ODE_API dReal dBodyGetAutoDisableLinearThreshold (dBodyID); + +/** + * @brief Set auto disable linear average threshold. + * @ingroup bodies disable + * @return the threshold + */ +ODE_API void dBodySetAutoDisableLinearThreshold (dBodyID, dReal linear_average_threshold); + +/** + * @brief Get auto disable angular average threshold. + * @ingroup bodies disable + * @return the threshold + */ +ODE_API dReal dBodyGetAutoDisableAngularThreshold (dBodyID); + +/** + * @brief Set auto disable angular average threshold. + * @ingroup bodies disable + * @return the threshold + */ +ODE_API void dBodySetAutoDisableAngularThreshold (dBodyID, dReal angular_average_threshold); + +/** + * @brief Get auto disable average size (samples count). + * @ingroup bodies disable + * @return the nr of steps/size. + */ +ODE_API int dBodyGetAutoDisableAverageSamplesCount (dBodyID); + +/** + * @brief Set auto disable average buffer size (average steps). + * @ingroup bodies disable + * @param average_samples_count the nr of samples to review. + */ +ODE_API void dBodySetAutoDisableAverageSamplesCount (dBodyID, unsigned int average_samples_count); + + +/** + * @brief Get auto steps a body must be thought of as idle to disable + * @ingroup bodies disable + * @return the nr of steps + */ +ODE_API int dBodyGetAutoDisableSteps (dBodyID); + +/** + * @brief Set auto disable steps. + * @ingroup bodies disable + * @param steps the nr of steps. + */ +ODE_API void dBodySetAutoDisableSteps (dBodyID, int steps); + +/** + * @brief Get auto disable time. + * @ingroup bodies disable + * @return nr of seconds + */ +ODE_API dReal dBodyGetAutoDisableTime (dBodyID); + +/** + * @brief Set auto disable time. + * @ingroup bodies disable + * @param time nr of seconds. + */ +ODE_API void dBodySetAutoDisableTime (dBodyID, dReal time); + +/** + * @brief Get auto disable flag. + * @ingroup bodies disable + * @return 0 or 1 + */ +ODE_API int dBodyGetAutoDisableFlag (dBodyID); + +/** + * @brief Set auto disable flag. + * @ingroup bodies disable + * @param do_auto_disable 0 or 1 + */ +ODE_API void dBodySetAutoDisableFlag (dBodyID, int do_auto_disable); + +/** + * @brief Set auto disable defaults. + * @remarks + * Set the values for the body to those set as default for the world. + * @ingroup bodies disable + */ +ODE_API void dBodySetAutoDisableDefaults (dBodyID); + + +/** + * @brief Retrieves the world attached to te given body. + * @remarks + * + * @ingroup bodies + */ +ODE_API dWorldID dBodyGetWorld (dBodyID); + +/** + * @brief Create a body in given world. + * @remarks + * Default mass parameters are at position (0,0,0). + * @ingroup bodies + */ +ODE_API dBodyID dBodyCreate (dWorldID); + +/** + * @brief Destroy a body. + * @remarks + * All joints that are attached to this body will be put into limbo: + * i.e. unattached and not affecting the simulation, but they will NOT be + * deleted. + * @ingroup bodies + */ +ODE_API void dBodyDestroy (dBodyID); + +/** + * @brief Set the body's user-data pointer. + * @ingroup bodies + * @param data arbitraty pointer + */ +ODE_API void dBodySetData (dBodyID, void *data); + +/** + * @brief Get the body's user-data pointer. + * @ingroup bodies + * @return a pointer to the user's data. + */ +ODE_API void *dBodyGetData (dBodyID); + +/** + * @brief Set position of a body. + * @remarks + * After setting, the outcome of the simulation is undefined + * if the new configuration is inconsistent with the joints/constraints + * that are present. + * @ingroup bodies + */ +ODE_API void dBodySetPosition (dBodyID, dReal x, dReal y, dReal z); + +/** + * @brief Set the orientation of a body. + * @ingroup bodies + * @remarks + * After setting, the outcome of the simulation is undefined + * if the new configuration is inconsistent with the joints/constraints + * that are present. + */ +ODE_API void dBodySetRotation (dBodyID, const dMatrix3 R); + +/** + * @brief Set the orientation of a body. + * @ingroup bodies + * @remarks + * After setting, the outcome of the simulation is undefined + * if the new configuration is inconsistent with the joints/constraints + * that are present. + */ +ODE_API void dBodySetQuaternion (dBodyID, const dQuaternion q); + +/** + * @brief Set the linear velocity of a body. + * @ingroup bodies + */ +ODE_API void dBodySetLinearVel (dBodyID, dReal x, dReal y, dReal z); + +/** + * @brief Set the angular velocity of a body. + * @ingroup bodies + */ +ODE_API void dBodySetAngularVel (dBodyID, dReal x, dReal y, dReal z); + +/** + * @brief Get the position of a body. + * @ingroup bodies + * @remarks + * When getting, the returned values are pointers to internal data structures, + * so the vectors are valid until any changes are made to the rigid body + * system structure. + * @sa dBodyCopyPosition + */ +ODE_API const dReal * dBodyGetPosition (dBodyID); + + +/** + * @brief Copy the position of a body into a vector. + * @ingroup bodies + * @param body the body to query + * @param pos a copy of the body position + * @sa dBodyGetPosition + */ +ODE_API void dBodyCopyPosition (dBodyID body, dVector3 pos); + + +/** + * @brief Get the rotation of a body. + * @ingroup bodies + * @return pointer to a 4x3 rotation matrix. + */ +ODE_API const dReal * dBodyGetRotation (dBodyID); + + +/** + * @brief Copy the rotation of a body. + * @ingroup bodies + * @param body the body to query + * @param R a copy of the rotation matrix + * @sa dBodyGetRotation + */ +ODE_API void dBodyCopyRotation (dBodyID, dMatrix3 R); + + +/** + * @brief Get the rotation of a body. + * @ingroup bodies + * @return pointer to 4 scalars that represent the quaternion. + */ +ODE_API const dReal * dBodyGetQuaternion (dBodyID); + + +/** + * @brief Copy the orientation of a body into a quaternion. + * @ingroup bodies + * @param body the body to query + * @param quat a copy of the orientation quaternion + * @sa dBodyGetQuaternion + */ +ODE_API void dBodyCopyQuaternion(dBodyID body, dQuaternion quat); + + +/** + * @brief Get the linear velocity of a body. + * @ingroup bodies + */ +ODE_API const dReal * dBodyGetLinearVel (dBodyID); + +/** + * @brief Get the angular velocity of a body. + * @ingroup bodies + */ +ODE_API const dReal * dBodyGetAngularVel (dBodyID); + +/** + * @brief Set the mass of a body. + * @ingroup bodies + */ +ODE_API void dBodySetMass (dBodyID, const dMass *mass); + +/** + * @brief Get the mass of a body. + * @ingroup bodies + */ +ODE_API void dBodyGetMass (dBodyID, dMass *mass); + +/** + * @brief Add force at centre of mass of body in absolute coordinates. + * @ingroup bodies + */ +ODE_API void dBodyAddForce (dBodyID, dReal fx, dReal fy, dReal fz); + +/** + * @brief Add torque at centre of mass of body in absolute coordinates. + * @ingroup bodies + */ +ODE_API void dBodyAddTorque (dBodyID, dReal fx, dReal fy, dReal fz); + +/** + * @brief Add force at centre of mass of body in coordinates relative to body. + * @ingroup bodies + */ +ODE_API void dBodyAddRelForce (dBodyID, dReal fx, dReal fy, dReal fz); + +/** + * @brief Add torque at centre of mass of body in coordinates relative to body. + * @ingroup bodies + */ +ODE_API void dBodyAddRelTorque (dBodyID, dReal fx, dReal fy, dReal fz); + +/** + * @brief Add force at specified point in body in global coordinates. + * @ingroup bodies + */ +ODE_API void dBodyAddForceAtPos (dBodyID, dReal fx, dReal fy, dReal fz, + dReal px, dReal py, dReal pz); +/** + * @brief Add force at specified point in body in local coordinates. + * @ingroup bodies + */ +ODE_API void dBodyAddForceAtRelPos (dBodyID, dReal fx, dReal fy, dReal fz, + dReal px, dReal py, dReal pz); +/** + * @brief Add force at specified point in body in global coordinates. + * @ingroup bodies + */ +ODE_API void dBodyAddRelForceAtPos (dBodyID, dReal fx, dReal fy, dReal fz, + dReal px, dReal py, dReal pz); +/** + * @brief Add force at specified point in body in local coordinates. + * @ingroup bodies + */ +ODE_API void dBodyAddRelForceAtRelPos (dBodyID, dReal fx, dReal fy, dReal fz, + dReal px, dReal py, dReal pz); + +/** + * @brief Return the current accumulated force vector. + * @return points to an array of 3 reals. + * @remarks + * The returned values are pointers to internal data structures, so + * the vectors are only valid until any changes are made to the rigid + * body system. + * @ingroup bodies + */ +ODE_API const dReal * dBodyGetForce (dBodyID); + +/** + * @brief Return the current accumulated torque vector. + * @return points to an array of 3 reals. + * @remarks + * The returned values are pointers to internal data structures, so + * the vectors are only valid until any changes are made to the rigid + * body system. + * @ingroup bodies + */ +ODE_API const dReal * dBodyGetTorque (dBodyID); + +/** + * @brief Set the body force accumulation vector. + * @remarks + * This is mostly useful to zero the force and torque for deactivated bodies + * before they are reactivated, in the case where the force-adding functions + * were called on them while they were deactivated. + * @ingroup bodies + */ +ODE_API void dBodySetForce (dBodyID b, dReal x, dReal y, dReal z); + +/** + * @brief Set the body torque accumulation vector. + * @remarks + * This is mostly useful to zero the force and torque for deactivated bodies + * before they are reactivated, in the case where the force-adding functions + * were called on them while they were deactivated. + * @ingroup bodies + */ +ODE_API void dBodySetTorque (dBodyID b, dReal x, dReal y, dReal z); + +/** + * @brief Get world position of a relative point on body. + * @ingroup bodies + * @param result will contain the result. + */ +ODE_API void dBodyGetRelPointPos +( + dBodyID, dReal px, dReal py, dReal pz, + dVector3 result +); + +/** + * @brief Get velocity vector in global coords of a relative point on body. + * @ingroup bodies + * @param result will contain the result. + */ +ODE_API void dBodyGetRelPointVel +( + dBodyID, dReal px, dReal py, dReal pz, + dVector3 result +); + +/** + * @brief Get velocity vector in global coords of a globally + * specified point on a body. + * @ingroup bodies + * @param result will contain the result. + */ +ODE_API void dBodyGetPointVel +( + dBodyID, dReal px, dReal py, dReal pz, + dVector3 result +); + +/** + * @brief takes a point in global coordinates and returns + * the point's position in body-relative coordinates. + * @remarks + * This is the inverse of dBodyGetRelPointPos() + * @ingroup bodies + * @param result will contain the result. + */ +ODE_API void dBodyGetPosRelPoint +( + dBodyID, dReal px, dReal py, dReal pz, + dVector3 result +); + +/** + * @brief Convert from local to world coordinates. + * @ingroup bodies + * @param result will contain the result. + */ +ODE_API void dBodyVectorToWorld +( + dBodyID, dReal px, dReal py, dReal pz, + dVector3 result +); + +/** + * @brief Convert from world to local coordinates. + * @ingroup bodies + * @param result will contain the result. + */ +ODE_API void dBodyVectorFromWorld +( + dBodyID, dReal px, dReal py, dReal pz, + dVector3 result +); + +/** + * @brief controls the way a body's orientation is updated at each timestep. + * @ingroup bodies + * @param mode can be 0 or 1: + * \li 0: An ``infinitesimal'' orientation update is used. + * This is fast to compute, but it can occasionally cause inaccuracies + * for bodies that are rotating at high speed, especially when those + * bodies are joined to other bodies. + * This is the default for every new body that is created. + * \li 1: A ``finite'' orientation update is used. + * This is more costly to compute, but will be more accurate for high + * speed rotations. + * @remarks + * Note however that high speed rotations can result in many types of + * error in a simulation, and the finite mode will only fix one of those + * sources of error. + */ +ODE_API void dBodySetFiniteRotationMode (dBodyID, int mode); + +/** + * @brief sets the finite rotation axis for a body. + * @ingroup bodies + * @remarks + * This is axis only has meaning when the finite rotation mode is set + * If this axis is zero (0,0,0), full finite rotations are performed on + * the body. + * If this axis is nonzero, the body is rotated by performing a partial finite + * rotation along the axis direction followed by an infinitesimal rotation + * along an orthogonal direction. + * @remarks + * This can be useful to alleviate certain sources of error caused by quickly + * spinning bodies. For example, if a car wheel is rotating at high speed + * you can call this function with the wheel's hinge axis as the argument to + * try and improve its behavior. + */ +ODE_API void dBodySetFiniteRotationAxis (dBodyID, dReal x, dReal y, dReal z); + +/** + * @brief Get the way a body's orientation is updated each timestep. + * @ingroup bodies + * @return the mode 0 (infitesimal) or 1 (finite). + */ +ODE_API int dBodyGetFiniteRotationMode (dBodyID); + +/** + * @brief Get the finite rotation axis. + * @param result will contain the axis. + * @ingroup bodies + */ +ODE_API void dBodyGetFiniteRotationAxis (dBodyID, dVector3 result); + +/** + * @brief Get the number of joints that are attached to this body. + * @ingroup bodies + * @return nr of joints + */ +ODE_API int dBodyGetNumJoints (dBodyID b); + +/** + * @brief Return a joint attached to this body, given by index. + * @ingroup bodies + * @param index valid range is 0 to n-1 where n is the value returned by + * dBodyGetNumJoints(). + */ +ODE_API dJointID dBodyGetJoint (dBodyID, int index); + + + + +/** + * @brief Set rigid body to dynamic state (default). + * @param dBodyID identification of body. + * @ingroup bodies + */ +ODE_API void dBodySetDynamic (dBodyID); + +/** + * @brief Set rigid body to kinematic state. + * When in kinematic state the body isn't simulated as a dynamic + * body (it's "unstoppable", doesn't respond to forces), + * but can still affect dynamic bodies (e.g. in joints). + * Kinematic bodies can be controlled by position and velocity. + * @note A kinematic body has infinite mass. If you set its mass + * to something else, it loses the kinematic state and behaves + * as a normal dynamic body. + * @param dBodyID identification of body. + * @ingroup bodies + */ +ODE_API void dBodySetKinematic (dBodyID); + +/** + * @brief Check wether a body is in kinematic state. + * @ingroup bodies + * @return 1 if a body is kinematic or 0 if it is dynamic. + */ +ODE_API int dBodyIsKinematic (dBodyID); + +/** + * @brief Manually enable a body. + * @param dBodyID identification of body. + * @ingroup bodies + */ +ODE_API void dBodyEnable (dBodyID); + +/** + * @brief Manually disable a body. + * @ingroup bodies + * @remarks + * A disabled body that is connected through a joint to an enabled body will + * be automatically re-enabled at the next simulation step. + */ +ODE_API void dBodyDisable (dBodyID); + +/** + * @brief Check wether a body is enabled. + * @ingroup bodies + * @return 1 if a body is currently enabled or 0 if it is disabled. + */ +ODE_API int dBodyIsEnabled (dBodyID); + +/** + * @brief Set whether the body is influenced by the world's gravity or not. + * @ingroup bodies + * @param mode when nonzero gravity affects this body. + * @remarks + * Newly created bodies are always influenced by the world's gravity. + */ +ODE_API void dBodySetGravityMode (dBodyID b, int mode); + +/** + * @brief Get whether the body is influenced by the world's gravity or not. + * @ingroup bodies + * @return nonzero means gravity affects this body. + */ +ODE_API int dBodyGetGravityMode (dBodyID b); + +/** + * @brief Set the 'moved' callback of a body. + * + * Whenever a body has its position or rotation changed during the + * timestep, the callback will be called (with body as the argument). + * Use it to know which body may need an update in an external + * structure (like a 3D engine). + * + * @param b the body that needs to be watched. + * @param callback the callback to be invoked when the body moves. Set to zero + * to disable. + * @ingroup bodies + */ +ODE_API void dBodySetMovedCallback(dBodyID b, void (*callback)(dBodyID)); + + +/** + * @brief Return the first geom associated with the body. + * + * You can traverse through the geoms by repeatedly calling + * dBodyGetNextGeom(). + * + * @return the first geom attached to this body, or 0. + * @ingroup bodies + */ +ODE_API dGeomID dBodyGetFirstGeom (dBodyID b); + + +/** + * @brief returns the next geom associated with the same body. + * @param g a geom attached to some body. + * @return the next geom attached to the same body, or 0. + * @sa dBodyGetFirstGeom + * @ingroup bodies + */ +ODE_API dGeomID dBodyGetNextGeom (dGeomID g); + + +/** + * @brief Resets the damping settings to the current world's settings. + * @ingroup bodies damping + */ +ODE_API void dBodySetDampingDefaults(dBodyID b); + +/** + * @brief Get the body's linear damping scale. + * @ingroup bodies damping + */ +ODE_API dReal dBodyGetLinearDamping (dBodyID b); + +/** + * @brief Set the body's linear damping scale. + * @param scale The linear damping scale. Should be in the interval [0, 1]. + * @ingroup bodies damping + * @remarks From now on the body will not use the world's linear damping + * scale until dBodySetDampingDefaults() is called. + * @sa dBodySetDampingDefaults() + */ +ODE_API void dBodySetLinearDamping(dBodyID b, dReal scale); + +/** + * @brief Get the body's angular damping scale. + * @ingroup bodies damping + * @remarks If the body's angular damping scale was not set, this function + * returns the world's angular damping scale. + */ +ODE_API dReal dBodyGetAngularDamping (dBodyID b); + +/** + * @brief Set the body's angular damping scale. + * @param scale The angular damping scale. Should be in the interval [0, 1]. + * @ingroup bodies damping + * @remarks From now on the body will not use the world's angular damping + * scale until dBodyResetAngularDamping() is called. + * @sa dBodyResetAngularDamping() + */ +ODE_API void dBodySetAngularDamping(dBodyID b, dReal scale); + +/** + * @brief Convenience function to set linear and angular scales at once. + * @param linear_scale The linear damping scale. Should be in the interval [0, 1]. + * @param angular_scale The angular damping scale. Should be in the interval [0, 1]. + * @ingroup bodies damping + * @sa dBodySetLinearDamping() dBodySetAngularDamping() + */ +ODE_API void dBodySetDamping(dBodyID b, dReal linear_scale, dReal angular_scale); + +/** + * @brief Get the body's linear damping threshold. + * @ingroup bodies damping + */ +ODE_API dReal dBodyGetLinearDampingThreshold (dBodyID b); + +/** + * @brief Set the body's linear damping threshold. + * @param threshold The linear threshold to be used. Damping + * is only applied if the linear speed is above this limit. + * @ingroup bodies damping + */ +ODE_API void dBodySetLinearDampingThreshold(dBodyID b, dReal threshold); + +/** + * @brief Get the body's angular damping threshold. + * @ingroup bodies damping + */ +ODE_API dReal dBodyGetAngularDampingThreshold (dBodyID b); + +/** + * @brief Set the body's angular damping threshold. + * @param threshold The angular threshold to be used. Damping is + * only used if the angular speed is above this limit. + * @ingroup bodies damping + */ +ODE_API void dBodySetAngularDampingThreshold(dBodyID b, dReal threshold); + +/** + * @brief Get the body's maximum angular speed. + * @ingroup damping bodies + * @sa dWorldGetMaxAngularSpeed() + */ +ODE_API dReal dBodyGetMaxAngularSpeed (dBodyID b); + +/** + * @brief Set the body's maximum angular speed. + * @ingroup damping bodies + * @sa dWorldSetMaxAngularSpeed() dBodyResetMaxAngularSpeed() + * The default value is dInfinity, but it's a good idea to limit + * it at less than 500 if the body has the gyroscopic term + * enabled. + */ +ODE_API void dBodySetMaxAngularSpeed(dBodyID b, dReal max_speed); + + + +/** + * @brief Get the body's gyroscopic state. + * + * @return nonzero if gyroscopic term computation is enabled (default), + * zero otherwise. + * @ingroup bodies + */ +ODE_API int dBodyGetGyroscopicMode(dBodyID b); + + +/** + * @brief Enable/disable the body's gyroscopic term. + * + * Disabling the gyroscopic term of a body usually improves + * stability. It also helps turning spining objects, like cars' + * wheels. + * + * @param enabled nonzero (default) to enable gyroscopic term, 0 + * to disable. + * @ingroup bodies + */ +ODE_API void dBodySetGyroscopicMode(dBodyID b, int enabled); + + + + +/** + * @defgroup joints Joints + * + * In real life a joint is something like a hinge, that is used to connect two + * objects. + * In ODE a joint is very similar: It is a relationship that is enforced between + * two bodies so that they can only have certain positions and orientations + * relative to each other. + * This relationship is called a constraint -- the words joint and + * constraint are often used interchangeably. + * + * A joint has a set of parameters that can be set. These include: + * + * + * \li dParamLoStop Low stop angle or position. Setting this to + * -dInfinity (the default value) turns off the low stop. + * For rotational joints, this stop must be greater than -pi to be + * effective. + * \li dParamHiStop High stop angle or position. Setting this to + * dInfinity (the default value) turns off the high stop. + * For rotational joints, this stop must be less than pi to be + * effective. + * If the high stop is less than the low stop then both stops will + * be ineffective. + * \li dParamVel Desired motor velocity (this will be an angular or + * linear velocity). + * \li dParamFMax The maximum force or torque that the motor will use to + * achieve the desired velocity. + * This must always be greater than or equal to zero. + * Setting this to zero (the default value) turns off the motor. + * \li dParamFudgeFactor The current joint stop/motor implementation has + * a small problem: + * when the joint is at one stop and the motor is set to move it away + * from the stop, too much force may be applied for one time step, + * causing a ``jumping'' motion. + * This fudge factor is used to scale this excess force. + * It should have a value between zero and one (the default value). + * If the jumping motion is too visible in a joint, the value can be + * reduced. + * Making this value too small can prevent the motor from being able to + * move the joint away from a stop. + * \li dParamBounce The bouncyness of the stops. + * This is a restitution parameter in the range 0..1. + * 0 means the stops are not bouncy at all, 1 means maximum bouncyness. + * \li dParamCFM The constraint force mixing (CFM) value used when not + * at a stop. + * \li dParamStopERP The error reduction parameter (ERP) used by the + * stops. + * \li dParamStopCFM The constraint force mixing (CFM) value used by the + * stops. Together with the ERP value this can be used to get spongy or + * soft stops. + * Note that this is intended for unpowered joints, it does not really + * work as expected when a powered joint reaches its limit. + * \li dParamSuspensionERP Suspension error reduction parameter (ERP). + * Currently this is only implemented on the hinge-2 joint. + * \li dParamSuspensionCFM Suspension constraint force mixing (CFM) value. + * Currently this is only implemented on the hinge-2 joint. + * + * If a particular parameter is not implemented by a given joint, setting it + * will have no effect. + * These parameter names can be optionally followed by a digit (2 or 3) + * to indicate the second or third set of parameters, e.g. for the second axis + * in a hinge-2 joint, or the third axis in an AMotor joint. + */ + + +/** + * @brief Create a new joint of the ball type. + * @ingroup joints + * @remarks + * The joint is initially in "limbo" (i.e. it has no effect on the simulation) + * because it does not connect to any bodies. + * @param dJointGroupID set to 0 to allocate the joint normally. + * If it is nonzero the joint is allocated in the given joint group. + */ +ODE_API dJointID dJointCreateBall (dWorldID, dJointGroupID); + +/** + * @brief Create a new joint of the hinge type. + * @ingroup joints + * @param dJointGroupID set to 0 to allocate the joint normally. + * If it is nonzero the joint is allocated in the given joint group. + */ +ODE_API dJointID dJointCreateHinge (dWorldID, dJointGroupID); + +/** + * @brief Create a new joint of the slider type. + * @ingroup joints + * @param dJointGroupID set to 0 to allocate the joint normally. + * If it is nonzero the joint is allocated in the given joint group. + */ +ODE_API dJointID dJointCreateSlider (dWorldID, dJointGroupID); + +/** + * @brief Create a new joint of the contact type. + * @ingroup joints + * @param dJointGroupID set to 0 to allocate the joint normally. + * If it is nonzero the joint is allocated in the given joint group. + */ +ODE_API dJointID dJointCreateContact (dWorldID, dJointGroupID, const dContact *); + +/** + * @brief Create a new joint of the hinge2 type. + * @ingroup joints + * @param dJointGroupID set to 0 to allocate the joint normally. + * If it is nonzero the joint is allocated in the given joint group. + */ +ODE_API dJointID dJointCreateHinge2 (dWorldID, dJointGroupID); + +/** + * @brief Create a new joint of the universal type. + * @ingroup joints + * @param dJointGroupID set to 0 to allocate the joint normally. + * If it is nonzero the joint is allocated in the given joint group. + */ +ODE_API dJointID dJointCreateUniversal (dWorldID, dJointGroupID); + +/** + * @brief Create a new joint of the PR (Prismatic and Rotoide) type. + * @ingroup joints + * @param dJointGroupID set to 0 to allocate the joint normally. + * If it is nonzero the joint is allocated in the given joint group. + */ +ODE_API dJointID dJointCreatePR (dWorldID, dJointGroupID); + +/** + * @brief Create a new joint of the PU (Prismatic and Universal) type. + * @ingroup joints + * @param dJointGroupID set to 0 to allocate the joint normally. + * If it is nonzero the joint is allocated in the given joint group. + */ +ODE_API dJointID dJointCreatePU (dWorldID, dJointGroupID); + +/** + * @brief Create a new joint of the Piston type. + * @ingroup joints + * @param dJointGroupID set to 0 to allocate the joint normally. + * If it is nonzero the joint is allocated in the given + * joint group. + */ +ODE_API dJointID dJointCreatePiston (dWorldID, dJointGroupID); + +/** + * @brief Create a new joint of the fixed type. + * @ingroup joints + * @param dJointGroupID set to 0 to allocate the joint normally. + * If it is nonzero the joint is allocated in the given joint group. + */ +ODE_API dJointID dJointCreateFixed (dWorldID, dJointGroupID); + +ODE_API dJointID dJointCreateNull (dWorldID, dJointGroupID); + +/** + * @brief Create a new joint of the A-motor type. + * @ingroup joints + * @param dJointGroupID set to 0 to allocate the joint normally. + * If it is nonzero the joint is allocated in the given joint group. + */ +ODE_API dJointID dJointCreateAMotor (dWorldID, dJointGroupID); + +/** + * @brief Create a new joint of the L-motor type. + * @ingroup joints + * @param dJointGroupID set to 0 to allocate the joint normally. + * If it is nonzero the joint is allocated in the given joint group. + */ +ODE_API dJointID dJointCreateLMotor (dWorldID, dJointGroupID); + +/** + * @brief Create a new joint of the plane-2d type. + * @ingroup joints + * @param dJointGroupID set to 0 to allocate the joint normally. + * If it is nonzero the joint is allocated in the given joint group. + */ +ODE_API dJointID dJointCreatePlane2D (dWorldID, dJointGroupID); + +/** + * @brief Create a new joint of the double ball type. + * @ingroup joints + * @param dJointGroupID set to 0 to allocate the joint normally. + * If it is nonzero the joint is allocated in the given joint group. + */ +ODE_API dJointID dJointCreateDBall (dWorldID, dJointGroupID); + +/** + * @brief Create a new joint of the double hinge type. + * @ingroup joints + * @param dJointGroupID set to 0 to allocate the joint normally. + * If it is nonzero the joint is allocated in the given joint group. + */ +ODE_API dJointID dJointCreateDHinge (dWorldID, dJointGroupID); + +/** + * @brief Create a new joint of the Transmission type. + * @ingroup joints + * @param dJointGroupID set to 0 to allocate the joint normally. + * If it is nonzero the joint is allocated in the given joint group. + */ +ODE_API dJointID dJointCreateTransmission (dWorldID, dJointGroupID); + + +/** + * @brief Destroy a joint. + * @ingroup joints + * + * disconnects it from its attached bodies and removing it from the world. + * However, if the joint is a member of a group then this function has no + * effect - to destroy that joint the group must be emptied or destroyed. + */ +ODE_API void dJointDestroy (dJointID); + + +/** + * @brief Create a joint group + * @ingroup joints + * @param max_size deprecated. Set to 0. + */ +ODE_API dJointGroupID dJointGroupCreate (int max_size); + +/** + * @brief Destroy a joint group. + * @ingroup joints + * + * All joints in the joint group will be destroyed. + */ +ODE_API void dJointGroupDestroy (dJointGroupID); + +/** + * @brief Empty a joint group. + * @ingroup joints + * + * All joints in the joint group will be destroyed, + * but the joint group itself will not be destroyed. + */ +ODE_API void dJointGroupEmpty (dJointGroupID); + +/** + * @brief Return the number of bodies attached to the joint + * @ingroup joints + */ +ODE_API int dJointGetNumBodies(dJointID); + +/** + * @brief Attach the joint to some new bodies. + * @ingroup joints + * + * If the joint is already attached, it will be detached from the old bodies + * first. + * To attach this joint to only one body, set body1 or body2 to zero - a zero + * body refers to the static environment. + * Setting both bodies to zero puts the joint into "limbo", i.e. it will + * have no effect on the simulation. + * @remarks + * Some joints, like hinge-2 need to be attached to two bodies to work. + */ +ODE_API void dJointAttach (dJointID, dBodyID body1, dBodyID body2); + +/** + * @brief Manually enable a joint. + * @param dJointID identification of joint. + * @ingroup joints + */ +ODE_API void dJointEnable (dJointID); + +/** + * @brief Manually disable a joint. + * @ingroup joints + * @remarks + * A disabled joint will not affect the simulation, but will maintain the anchors and + * axes so it can be enabled later. + */ +ODE_API void dJointDisable (dJointID); + +/** + * @brief Check wether a joint is enabled. + * @ingroup joints + * @return 1 if a joint is currently enabled or 0 if it is disabled. + */ +ODE_API int dJointIsEnabled (dJointID); + +/** + * @brief Set the user-data pointer + * @ingroup joints + */ +ODE_API void dJointSetData (dJointID, void *data); + +/** + * @brief Get the user-data pointer + * @ingroup joints + */ +ODE_API void *dJointGetData (dJointID); + +/** + * @brief Get the type of the joint + * @ingroup joints + * @return the type, being one of these: + * \li dJointTypeBall + * \li dJointTypeHinge + * \li dJointTypeSlider + * \li dJointTypeContact + * \li dJointTypeUniversal + * \li dJointTypeHinge2 + * \li dJointTypeFixed + * \li dJointTypeNull + * \li dJointTypeAMotor + * \li dJointTypeLMotor + * \li dJointTypePlane2D + * \li dJointTypePR + * \li dJointTypePU + * \li dJointTypePiston + */ +ODE_API dJointType dJointGetType (dJointID); + +/** + * @brief Return the bodies that this joint connects. + * @ingroup joints + * @param index return the first (0) or second (1) body. + * @remarks + * If one of these returned body IDs is zero, the joint connects the other body + * to the static environment. + * If both body IDs are zero, the joint is in ``limbo'' and has no effect on + * the simulation. + */ +ODE_API dBodyID dJointGetBody (dJointID, int index); + +/** + * @brief Sets the datastructure that is to receive the feedback. + * + * The feedback can be used by the user, so that it is known how + * much force an individual joint exerts. + * @ingroup joints + */ +ODE_API void dJointSetFeedback (dJointID, dJointFeedback *); + +/** + * @brief Gets the datastructure that is to receive the feedback. + * @ingroup joints + */ +ODE_API dJointFeedback *dJointGetFeedback (dJointID); + +/** + * @brief Set the joint anchor point. + * @ingroup joints + * + * The joint will try to keep this point on each body + * together. The input is specified in world coordinates. + */ +ODE_API void dJointSetBallAnchor (dJointID, dReal x, dReal y, dReal z); + +/** + * @brief Set the joint anchor point. + * @ingroup joints + */ +ODE_API void dJointSetBallAnchor2 (dJointID, dReal x, dReal y, dReal z); + +/** + * @brief Param setting for Ball joints + * @ingroup joints + */ +ODE_API void dJointSetBallParam (dJointID, int parameter, dReal value); + +/** + * @brief Set hinge anchor parameter. + * @ingroup joints + */ +ODE_API void dJointSetHingeAnchor (dJointID, dReal x, dReal y, dReal z); + +ODE_API void dJointSetHingeAnchorDelta (dJointID, dReal x, dReal y, dReal z, dReal ax, dReal ay, dReal az); + +/** + * @brief Set hinge axis. + * @ingroup joints + */ +ODE_API void dJointSetHingeAxis (dJointID, dReal x, dReal y, dReal z); + +/** + * @brief Set the Hinge axis as if the 2 bodies were already at angle appart. + * @ingroup joints + * + * This function initialize the Axis and the relative orientation of each body + * as if body1 was rotated around the axis by the angle value. \br + * Ex: + *
    + * dJointSetHingeAxis(jId, 1, 0, 0);
    + * // If you request the position you will have: dJointGetHingeAngle(jId) == 0
    + * dJointSetHingeAxisDelta(jId, 1, 0, 0, 0.23);
    + * // If you request the position you will have: dJointGetHingeAngle(jId) == 0.23
    + * 
    + + * @param j The Hinge joint ID for which the axis will be set + * @param x The X component of the axis in world frame + * @param y The Y component of the axis in world frame + * @param z The Z component of the axis in world frame + * @param angle The angle for the offset of the relative orientation. + * As if body1 was rotated by angle when the Axis was set (see below). + * The rotation is around the new Hinge axis. + * + * @note Usually the function dJointSetHingeAxis set the current position of body1 + * and body2 as the zero angle position. This function set the current position + * as the if the 2 bodies where \b angle appart. + * @warning Calling dJointSetHingeAnchor or dJointSetHingeAxis will reset the "zero" + * angle position. + */ +ODE_API void dJointSetHingeAxisOffset (dJointID j, dReal x, dReal y, dReal z, dReal angle); + +/** + * @brief set joint parameter + * @ingroup joints + */ +ODE_API void dJointSetHingeParam (dJointID, int parameter, dReal value); + +/** + * @brief Applies the torque about the hinge axis. + * + * That is, it applies a torque with specified magnitude in the direction + * of the hinge axis, to body 1, and with the same magnitude but in opposite + * direction to body 2. This function is just a wrapper for dBodyAddTorque()} + * @ingroup joints + */ +ODE_API void dJointAddHingeTorque(dJointID joint, dReal torque); + +/** + * @brief set the joint axis + * @ingroup joints + */ +ODE_API void dJointSetSliderAxis (dJointID, dReal x, dReal y, dReal z); + +/** + * @ingroup joints + */ +ODE_API void dJointSetSliderAxisDelta (dJointID, dReal x, dReal y, dReal z, dReal ax, dReal ay, dReal az); + +/** + * @brief set joint parameter + * @ingroup joints + */ +ODE_API void dJointSetSliderParam (dJointID, int parameter, dReal value); + +/** + * @brief Applies the given force in the slider's direction. + * + * That is, it applies a force with specified magnitude, in the direction of + * slider's axis, to body1, and with the same magnitude but opposite + * direction to body2. This function is just a wrapper for dBodyAddForce(). + * @ingroup joints + */ +ODE_API void dJointAddSliderForce(dJointID joint, dReal force); + +/** + * @brief set anchor + * @ingroup joints + */ +ODE_API void dJointSetHinge2Anchor (dJointID, dReal x, dReal y, dReal z); + +/** + * @brief set both axes (optionally) + * + * This can change both axes at once avoiding transitions via invalid states + * while changing axes one by one and having the first changed axis coincide + * with the other axis existing direction. + * + * At least one of the axes must be not NULL. If NULL is passed, the corresponding + * axis retains its existing value. + * + * @ingroup joints + */ +ODE_API void dJointSetHinge2Axes (dJointID j, const dReal *axis1/*=[dSA__MAX],=NULL*/, const dReal *axis2/*=[dSA__MAX],=NULL*/); + +/** + * @brief set axis + * + * Deprecated. Use @fn dJointSetHinge2Axes instead. + * + * @ingroup joints + * @see dJointSetHinge2Axes + */ +ODE_API_DEPRECATED ODE_API void dJointSetHinge2Axis1 (dJointID j, dReal x, dReal y, dReal z); + +/** + * @brief set axis + * + * Deprecated. Use @fn dJointSetHinge2Axes instead. + * + * @ingroup joints + * @see dJointSetHinge2Axes + */ +ODE_API_DEPRECATED ODE_API void dJointSetHinge2Axis2 (dJointID j, dReal x, dReal y, dReal z); + +/** + * @brief set joint parameter + * @ingroup joints + */ +ODE_API void dJointSetHinge2Param (dJointID, int parameter, dReal value); + +/** + * @brief Applies torque1 about the hinge2's axis 1, torque2 about the + * hinge2's axis 2. + * @remarks This function is just a wrapper for dBodyAddTorque(). + * @ingroup joints + */ +ODE_API void dJointAddHinge2Torques(dJointID joint, dReal torque1, dReal torque2); + +/** + * @brief set anchor + * @ingroup joints + */ +ODE_API void dJointSetUniversalAnchor (dJointID, dReal x, dReal y, dReal z); + +/** + * @brief set axis + * @ingroup joints + */ +ODE_API void dJointSetUniversalAxis1 (dJointID, dReal x, dReal y, dReal z); + +/** + * @brief Set the Universal axis1 as if the 2 bodies were already at + * offset1 and offset2 appart with respect to axis1 and axis2. + * @ingroup joints + * + * This function initialize the axis1 and the relative orientation of + * each body as if body1 was rotated around the new axis1 by the offset1 + * value and as if body2 was rotated around the axis2 by offset2. \br + * Ex: +*
    + * dJointSetHuniversalAxis1(jId, 1, 0, 0);
    + * // If you request the position you will have: dJointGetUniversalAngle1(jId) == 0
    + * // If you request the position you will have: dJointGetUniversalAngle2(jId) == 0
    + * dJointSetHuniversalAxis1Offset(jId, 1, 0, 0, 0.2, 0.17);
    + * // If you request the position you will have: dJointGetUniversalAngle1(jId) == 0.2
    + * // If you request the position you will have: dJointGetUniversalAngle2(jId) == 0.17
    + * 
    + * + * @param j The Hinge joint ID for which the axis will be set + * @param x The X component of the axis in world frame + * @param y The Y component of the axis in world frame + * @param z The Z component of the axis in world frame + * @param angle The angle for the offset of the relative orientation. + * As if body1 was rotated by angle when the Axis was set (see below). + * The rotation is around the new Hinge axis. + * + * @note Usually the function dJointSetHingeAxis set the current position of body1 + * and body2 as the zero angle position. This function set the current position + * as the if the 2 bodies where \b offsets appart. + * + * @note Any previous offsets are erased. + * + * @warning Calling dJointSetUniversalAnchor, dJointSetUnivesalAxis1, + * dJointSetUniversalAxis2, dJointSetUniversalAxis2Offset + * will reset the "zero" angle position. + */ +ODE_API void dJointSetUniversalAxis1Offset (dJointID, dReal x, dReal y, dReal z, + dReal offset1, dReal offset2); + +/** + * @brief set axis + * @ingroup joints + */ +ODE_API void dJointSetUniversalAxis2 (dJointID, dReal x, dReal y, dReal z); + +/** + * @brief Set the Universal axis2 as if the 2 bodies were already at + * offset1 and offset2 appart with respect to axis1 and axis2. + * @ingroup joints + * + * This function initialize the axis2 and the relative orientation of + * each body as if body1 was rotated around the axis1 by the offset1 + * value and as if body2 was rotated around the new axis2 by offset2. \br + * Ex: + *
    + * dJointSetHuniversalAxis2(jId, 0, 1, 0);
    + * // If you request the position you will have: dJointGetUniversalAngle1(jId) == 0
    + * // If you request the position you will have: dJointGetUniversalAngle2(jId) == 0
    + * dJointSetHuniversalAxis2Offset(jId, 0, 1, 0, 0.2, 0.17);
    + * // If you request the position you will have: dJointGetUniversalAngle1(jId) == 0.2
    + * // If you request the position you will have: dJointGetUniversalAngle2(jId) == 0.17
    + * 
    + + * @param j The Hinge joint ID for which the axis will be set + * @param x The X component of the axis in world frame + * @param y The Y component of the axis in world frame + * @param z The Z component of the axis in world frame + * @param angle The angle for the offset of the relative orientation. + * As if body1 was rotated by angle when the Axis was set (see below). + * The rotation is around the new Hinge axis. + * + * @note Usually the function dJointSetHingeAxis set the current position of body1 + * and body2 as the zero angle position. This function set the current position + * as the if the 2 bodies where \b offsets appart. + * + * @note Any previous offsets are erased. + * + * @warning Calling dJointSetUniversalAnchor, dJointSetUnivesalAxis1, + * dJointSetUniversalAxis2, dJointSetUniversalAxis2Offset + * will reset the "zero" angle position. + */ + + +ODE_API void dJointSetUniversalAxis2Offset (dJointID, dReal x, dReal y, dReal z, + dReal offset1, dReal offset2); + +/** + * @brief set joint parameter + * @ingroup joints + */ +ODE_API void dJointSetUniversalParam (dJointID, int parameter, dReal value); + +/** + * @brief Applies torque1 about the universal's axis 1, torque2 about the + * universal's axis 2. + * @remarks This function is just a wrapper for dBodyAddTorque(). + * @ingroup joints + */ +ODE_API void dJointAddUniversalTorques(dJointID joint, dReal torque1, dReal torque2); + + +/** + * @brief set anchor + * @ingroup joints + */ +ODE_API void dJointSetPRAnchor (dJointID, dReal x, dReal y, dReal z); + +/** + * @brief set the axis for the prismatic articulation + * @ingroup joints + */ +ODE_API void dJointSetPRAxis1 (dJointID, dReal x, dReal y, dReal z); + +/** + * @brief set the axis for the rotoide articulation + * @ingroup joints + */ +ODE_API void dJointSetPRAxis2 (dJointID, dReal x, dReal y, dReal z); + +/** + * @brief set joint parameter + * @ingroup joints + * + * @note parameterX where X equal 2 refer to parameter for the rotoide articulation + */ +ODE_API void dJointSetPRParam (dJointID, int parameter, dReal value); + +/** + * @brief Applies the torque about the rotoide axis of the PR joint + * + * That is, it applies a torque with specified magnitude in the direction + * of the rotoide axis, to body 1, and with the same magnitude but in opposite + * direction to body 2. This function is just a wrapper for dBodyAddTorque()} + * @ingroup joints + */ +ODE_API void dJointAddPRTorque (dJointID j, dReal torque); + + +/** +* @brief set anchor +* @ingroup joints +*/ +ODE_API void dJointSetPUAnchor (dJointID, dReal x, dReal y, dReal z); + +/** + * @brief set anchor + * @ingroup joints + */ +ODE_API_DEPRECATED ODE_API void dJointSetPUAnchorDelta (dJointID, dReal x, dReal y, dReal z, + dReal dx, dReal dy, dReal dz); + +/** + * @brief Set the PU anchor as if the 2 bodies were already at [dx, dy, dz] appart. + * @ingroup joints + * + * This function initialize the anchor and the relative position of each body + * as if the position between body1 and body2 was already the projection of [dx, dy, dz] + * along the Piston axis. (i.e as if the body1 was at its current position - [dx,dy,dy] when the + * axis is set). + * Ex: + *
    + * dReal offset = 3;
    + * dVector3 axis;
    + * dJointGetPUAxis(jId, axis);
    + * dJointSetPUAnchor(jId, 0, 0, 0);
    + * // If you request the position you will have: dJointGetPUPosition(jId) == 0
    + * dJointSetPUAnchorOffset(jId, 0, 0, 0, axis[X]*offset, axis[Y]*offset, axis[Z]*offset);
    + * // If you request the position you will have: dJointGetPUPosition(jId) == offset
    + * 
    + * @param j The PU joint for which the anchor point will be set + * @param x The X position of the anchor point in world frame + * @param y The Y position of the anchor point in world frame + * @param z The Z position of the anchor point in world frame + * @param dx A delta to be substracted to the X position as if the anchor was set + * when body1 was at current_position[X] - dx + * @param dx A delta to be substracted to the Y position as if the anchor was set + * when body1 was at current_position[Y] - dy + * @param dx A delta to be substracted to the Z position as if the anchor was set + * when body1 was at current_position[Z] - dz + */ +ODE_API void dJointSetPUAnchorOffset (dJointID, dReal x, dReal y, dReal z, + dReal dx, dReal dy, dReal dz); + +/** + * @brief set the axis for the first axis or the universal articulation + * @ingroup joints + */ +ODE_API void dJointSetPUAxis1 (dJointID, dReal x, dReal y, dReal z); + +/** + * @brief set the axis for the second axis or the universal articulation + * @ingroup joints + */ +ODE_API void dJointSetPUAxis2 (dJointID, dReal x, dReal y, dReal z); + +/** + * @brief set the axis for the prismatic articulation + * @ingroup joints + */ +ODE_API void dJointSetPUAxis3 (dJointID, dReal x, dReal y, dReal z); + +/** + * @brief set the axis for the prismatic articulation + * @ingroup joints + * @note This function was added for convenience it is the same as + * dJointSetPUAxis3 + */ +ODE_API void dJointSetPUAxisP (dJointID id, dReal x, dReal y, dReal z); + + + +/** + * @brief set joint parameter + * @ingroup joints + * + * @note parameterX where X equal 2 refer to parameter for second axis of the + * universal articulation + * @note parameterX where X equal 3 refer to parameter for prismatic + * articulation + */ +ODE_API void dJointSetPUParam (dJointID, int parameter, dReal value); + +/** + * @brief Applies the torque about the rotoide axis of the PU joint + * + * That is, it applies a torque with specified magnitude in the direction + * of the rotoide axis, to body 1, and with the same magnitude but in opposite + * direction to body 2. This function is just a wrapper for dBodyAddTorque()} + * @ingroup joints + */ +ODE_API void dJointAddPUTorque (dJointID j, dReal torque); + + + + +/** + * @brief set the joint anchor + * @ingroup joints + */ +ODE_API void dJointSetPistonAnchor (dJointID, dReal x, dReal y, dReal z); + +/** + * @brief Set the Piston anchor as if the 2 bodies were already at [dx,dy, dz] appart. + * @ingroup joints + * + * This function initialize the anchor and the relative position of each body + * as if the position between body1 and body2 was already the projection of [dx, dy, dz] + * along the Piston axis. (i.e as if the body1 was at its current position - [dx,dy,dy] when the + * axis is set). + * Ex: + *
    + * dReal offset = 3;
    + * dVector3 axis;
    + * dJointGetPistonAxis(jId, axis);
    + * dJointSetPistonAnchor(jId, 0, 0, 0);
    + * // If you request the position you will have: dJointGetPistonPosition(jId) == 0
    + * dJointSetPistonAnchorOffset(jId, 0, 0, 0, axis[X]*offset, axis[Y]*offset, axis[Z]*offset);
    + * // If you request the position you will have: dJointGetPistonPosition(jId) == offset
    + * 
    + * @param j The Piston joint for which the anchor point will be set + * @param x The X position of the anchor point in world frame + * @param y The Y position of the anchor point in world frame + * @param z The Z position of the anchor point in world frame + * @param dx A delta to be substracted to the X position as if the anchor was set + * when body1 was at current_position[X] - dx + * @param dx A delta to be substracted to the Y position as if the anchor was set + * when body1 was at current_position[Y] - dy + * @param dx A delta to be substracted to the Z position as if the anchor was set + * when body1 was at current_position[Z] - dz + */ +ODE_API void dJointSetPistonAnchorOffset(dJointID j, dReal x, dReal y, dReal z, + dReal dx, dReal dy, dReal dz); + + /** + * @brief set the joint axis + * @ingroup joints + */ +ODE_API void dJointSetPistonAxis (dJointID, dReal x, dReal y, dReal z); + +/** + * This function set prismatic axis of the joint and also set the position + * of the joint. + * + * @ingroup joints + * @param j The joint affected by this function + * @param x The x component of the axis + * @param y The y component of the axis + * @param z The z component of the axis + * @param dx The Initial position of the prismatic join in the x direction + * @param dy The Initial position of the prismatic join in the y direction + * @param dz The Initial position of the prismatic join in the z direction + */ +ODE_API_DEPRECATED ODE_API void dJointSetPistonAxisDelta (dJointID j, dReal x, dReal y, dReal z, dReal ax, dReal ay, dReal az); + +/** + * @brief set joint parameter + * @ingroup joints + */ +ODE_API void dJointSetPistonParam (dJointID, int parameter, dReal value); + +/** + * @brief Applies the given force in the slider's direction. + * + * That is, it applies a force with specified magnitude, in the direction of + * prismatic's axis, to body1, and with the same magnitude but opposite + * direction to body2. This function is just a wrapper for dBodyAddForce(). + * @ingroup joints + */ +ODE_API void dJointAddPistonForce (dJointID joint, dReal force); + + +/** + * @brief Call this on the fixed joint after it has been attached to + * remember the current desired relative offset and desired relative + * rotation between the bodies. + * @ingroup joints + */ +ODE_API void dJointSetFixed (dJointID); + +/* + * @brief Sets joint parameter + * + * @ingroup joints + */ +ODE_API void dJointSetFixedParam (dJointID, int parameter, dReal value); + +/** + * @brief set the nr of axes + * @param num 0..3 + * @ingroup joints + */ +ODE_API void dJointSetAMotorNumAxes (dJointID, int num); + +/** + * @brief set axis + * @ingroup joints + */ +ODE_API void dJointSetAMotorAxis (dJointID, int anum, int rel, + dReal x, dReal y, dReal z); + +/** + * @brief Tell the AMotor what the current angle is along axis anum. + * + * This function should only be called in dAMotorUser mode, because in this + * mode the AMotor has no other way of knowing the joint angles. + * The angle information is needed if stops have been set along the axis, + * but it is not needed for axis motors. + * @ingroup joints + */ +ODE_API void dJointSetAMotorAngle (dJointID, int anum, dReal angle); + +/** + * @brief set joint parameter + * @ingroup joints + */ +ODE_API void dJointSetAMotorParam (dJointID, int parameter, dReal value); + +/** + * @brief set mode + * @ingroup joints + */ +ODE_API void dJointSetAMotorMode (dJointID, int mode); + +/** + * @brief Applies torque0 about the AMotor's axis 0, torque1 about the + * AMotor's axis 1, and torque2 about the AMotor's axis 2. + * @remarks + * If the motor has fewer than three axes, the higher torques are ignored. + * This function is just a wrapper for dBodyAddTorque(). + * @ingroup joints + */ +ODE_API void dJointAddAMotorTorques (dJointID, dReal torque1, dReal torque2, dReal torque3); + +/** + * @brief Set the number of axes that will be controlled by the LMotor. + * @param num can range from 0 (which effectively deactivates the joint) to 3. + * @ingroup joints + */ +ODE_API void dJointSetLMotorNumAxes (dJointID, int num); + +/** + * @brief Set the AMotor axes. + * @param anum selects the axis to change (0,1 or 2). + * @param rel Each axis can have one of three ``relative orientation'' modes + * \li 0: The axis is anchored to the global frame. + * \li 1: The axis is anchored to the first body. + * \li 2: The axis is anchored to the second body. + * @remarks The axis vector is always specified in global coordinates + * regardless of the setting of rel. + * @ingroup joints + */ +ODE_API void dJointSetLMotorAxis (dJointID, int anum, int rel, dReal x, dReal y, dReal z); + +/** + * @brief set joint parameter + * @ingroup joints + */ +ODE_API void dJointSetLMotorParam (dJointID, int parameter, dReal value); + +/** + * @ingroup joints + */ +ODE_API void dJointSetPlane2DXParam (dJointID, int parameter, dReal value); + +/** + * @ingroup joints + */ + +ODE_API void dJointSetPlane2DYParam (dJointID, int parameter, dReal value); + +/** + * @ingroup joints + */ +ODE_API void dJointSetPlane2DAngleParam (dJointID, int parameter, dReal value); + +/** + * @brief Get the joint anchor point, in world coordinates. + * + * This returns the point on body 1. If the joint is perfectly satisfied, + * this will be the same as the point on body 2. + */ +ODE_API void dJointGetBallAnchor (dJointID, dVector3 result); + +/** + * @brief Get the joint anchor point, in world coordinates. + * + * This returns the point on body 2. You can think of a ball and socket + * joint as trying to keep the result of dJointGetBallAnchor() and + * dJointGetBallAnchor2() the same. If the joint is perfectly satisfied, + * this function will return the same value as dJointGetBallAnchor() to + * within roundoff errors. dJointGetBallAnchor2() can be used, along with + * dJointGetBallAnchor(), to see how far the joint has come apart. + */ +ODE_API void dJointGetBallAnchor2 (dJointID, dVector3 result); + +/** + * @brief get joint parameter + * @ingroup joints + */ +ODE_API dReal dJointGetBallParam (dJointID, int parameter); + +/** + * @brief Get the hinge anchor point, in world coordinates. + * + * This returns the point on body 1. If the joint is perfectly satisfied, + * this will be the same as the point on body 2. + * @ingroup joints + */ +ODE_API void dJointGetHingeAnchor (dJointID, dVector3 result); + +/** + * @brief Get the joint anchor point, in world coordinates. + * @return The point on body 2. If the joint is perfectly satisfied, + * this will return the same value as dJointGetHingeAnchor(). + * If not, this value will be slightly different. + * This can be used, for example, to see how far the joint has come apart. + * @ingroup joints + */ +ODE_API void dJointGetHingeAnchor2 (dJointID, dVector3 result); + +/** + * @brief get axis + * @ingroup joints + */ +ODE_API void dJointGetHingeAxis (dJointID, dVector3 result); + +/** + * @brief get joint parameter + * @ingroup joints + */ +ODE_API dReal dJointGetHingeParam (dJointID, int parameter); + +/** + * @brief Get the hinge angle. + * + * The angle is measured between the two bodies, or between the body and + * the static environment. + * The angle will be between -pi..pi. + * Give the relative rotation with respect to the Hinge axis of Body 1 with + * respect to Body 2. + * When the hinge anchor or axis is set, the current position of the attached + * bodies is examined and that position will be the zero angle. + * @ingroup joints + */ +ODE_API dReal dJointGetHingeAngle (dJointID); + +/** + * @brief Get the hinge angle time derivative. + * @ingroup joints + */ +ODE_API dReal dJointGetHingeAngleRate (dJointID); + +/** + * @brief Get the slider linear position (i.e. the slider's extension) + * + * When the axis is set, the current position of the attached bodies is + * examined and that position will be the zero position. + + * The position is the distance, with respect to the zero position, + * along the slider axis of body 1 with respect to + * body 2. (A NULL body is replaced by the world). + * @ingroup joints + */ +ODE_API dReal dJointGetSliderPosition (dJointID); + +/** + * @brief Get the slider linear position's time derivative. + * @ingroup joints + */ +ODE_API dReal dJointGetSliderPositionRate (dJointID); + +/** + * @brief Get the slider axis + * @ingroup joints + */ +ODE_API void dJointGetSliderAxis (dJointID, dVector3 result); + +/** + * @brief get joint parameter + * @ingroup joints + */ +ODE_API dReal dJointGetSliderParam (dJointID, int parameter); + +/** + * @brief Get the joint anchor point, in world coordinates. + * @return the point on body 1. If the joint is perfectly satisfied, + * this will be the same as the point on body 2. + * @ingroup joints + */ +ODE_API void dJointGetHinge2Anchor (dJointID, dVector3 result); + +/** + * @brief Get the joint anchor point, in world coordinates. + * This returns the point on body 2. If the joint is perfectly satisfied, + * this will return the same value as dJointGetHinge2Anchor. + * If not, this value will be slightly different. + * This can be used, for example, to see how far the joint has come apart. + * @ingroup joints + */ +ODE_API void dJointGetHinge2Anchor2 (dJointID, dVector3 result); + +/** + * @brief Get joint axis + * @ingroup joints + */ +ODE_API void dJointGetHinge2Axis1 (dJointID, dVector3 result); + +/** + * @brief Get joint axis + * @ingroup joints + */ +ODE_API void dJointGetHinge2Axis2 (dJointID, dVector3 result); + +/** + * @brief get joint parameter + * @ingroup joints + */ +ODE_API dReal dJointGetHinge2Param (dJointID, int parameter); + +/** + * @brief Get angle + * @ingroup joints + */ +ODE_API dReal dJointGetHinge2Angle1 (dJointID); + +/** + * @brief Get angle + * @ingroup joints + */ +ODE_API dReal dJointGetHinge2Angle2 (dJointID); + +/** + * @brief Get time derivative of angle + * @ingroup joints + */ +ODE_API dReal dJointGetHinge2Angle1Rate (dJointID); + +/** + * @brief Get time derivative of angle + * @ingroup joints + */ +ODE_API dReal dJointGetHinge2Angle2Rate (dJointID); + +/** + * @brief Get the joint anchor point, in world coordinates. + * @return the point on body 1. If the joint is perfectly satisfied, + * this will be the same as the point on body 2. + * @ingroup joints + */ +ODE_API void dJointGetUniversalAnchor (dJointID, dVector3 result); + +/** + * @brief Get the joint anchor point, in world coordinates. + * @return This returns the point on body 2. + * @remarks + * You can think of the ball and socket part of a universal joint as + * trying to keep the result of dJointGetBallAnchor() and + * dJointGetBallAnchor2() the same. If the joint is + * perfectly satisfied, this function will return the same value + * as dJointGetUniversalAnchor() to within roundoff errors. + * dJointGetUniversalAnchor2() can be used, along with + * dJointGetUniversalAnchor(), to see how far the joint has come apart. + * @ingroup joints + */ +ODE_API void dJointGetUniversalAnchor2 (dJointID, dVector3 result); + +/** + * @brief Get axis + * @ingroup joints + */ +ODE_API void dJointGetUniversalAxis1 (dJointID, dVector3 result); + +/** + * @brief Get axis + * @ingroup joints + */ +ODE_API void dJointGetUniversalAxis2 (dJointID, dVector3 result); + + +/** + * @brief get joint parameter + * @ingroup joints + */ +ODE_API dReal dJointGetUniversalParam (dJointID, int parameter); + +/** + * @brief Get both angles at the same time. + * @ingroup joints + * + * @param joint The universal joint for which we want to calculate the angles + * @param angle1 The angle between the body1 and the axis 1 + * @param angle2 The angle between the body2 and the axis 2 + * + * @note This function combine getUniversalAngle1 and getUniversalAngle2 together + * and try to avoid redundant calculation + */ +ODE_API void dJointGetUniversalAngles (dJointID, dReal *angle1, dReal *angle2); + +/** + * @brief Get angle + * @ingroup joints + */ +ODE_API dReal dJointGetUniversalAngle1 (dJointID); + +/** + * @brief Get angle + * @ingroup joints + */ +ODE_API dReal dJointGetUniversalAngle2 (dJointID); + +/** + * @brief Get time derivative of angle + * @ingroup joints + */ +ODE_API dReal dJointGetUniversalAngle1Rate (dJointID); + +/** + * @brief Get time derivative of angle + * @ingroup joints + */ +ODE_API dReal dJointGetUniversalAngle2Rate (dJointID); + + + +/** + * @brief Get the joint anchor point, in world coordinates. + * @return the point on body 1. If the joint is perfectly satisfied, + * this will be the same as the point on body 2. + * @ingroup joints + */ +ODE_API void dJointGetPRAnchor (dJointID, dVector3 result); + +/** + * @brief Get the PR linear position (i.e. the prismatic's extension) + * + * When the axis is set, the current position of the attached bodies is + * examined and that position will be the zero position. + * + * The position is the "oriented" length between the + * position = (Prismatic axis) dot_product [(body1 + offset) - (body2 + anchor2)] + * + * @ingroup joints + */ +ODE_API dReal dJointGetPRPosition (dJointID); + +/** + * @brief Get the PR linear position's time derivative + * + * @ingroup joints + */ +ODE_API dReal dJointGetPRPositionRate (dJointID); + + +/** + * @brief Get the PR angular position (i.e. the twist between the 2 bodies) + * + * When the axis is set, the current position of the attached bodies is + * examined and that position will be the zero position. + * @ingroup joints + */ +ODE_API dReal dJointGetPRAngle (dJointID); + +/** + * @brief Get the PR angular position's time derivative + * + * @ingroup joints + */ +ODE_API dReal dJointGetPRAngleRate (dJointID); + + +/** + * @brief Get the prismatic axis + * @ingroup joints + */ +ODE_API void dJointGetPRAxis1 (dJointID, dVector3 result); + +/** + * @brief Get the Rotoide axis + * @ingroup joints + */ +ODE_API void dJointGetPRAxis2 (dJointID, dVector3 result); + +/** + * @brief get joint parameter + * @ingroup joints + */ +ODE_API dReal dJointGetPRParam (dJointID, int parameter); + + + +/** + * @brief Get the joint anchor point, in world coordinates. + * @return the point on body 1. If the joint is perfectly satisfied, + * this will be the same as the point on body 2. + * @ingroup joints + */ +ODE_API void dJointGetPUAnchor (dJointID, dVector3 result); + +/** + * @brief Get the PU linear position (i.e. the prismatic's extension) + * + * When the axis is set, the current position of the attached bodies is + * examined and that position will be the zero position. + * + * The position is the "oriented" length between the + * position = (Prismatic axis) dot_product [(body1 + offset) - (body2 + anchor2)] + * + * @ingroup joints + */ +ODE_API dReal dJointGetPUPosition (dJointID); + +/** + * @brief Get the PR linear position's time derivative + * + * @ingroup joints + */ +ODE_API dReal dJointGetPUPositionRate (dJointID); + +/** + * @brief Get the first axis of the universal component of the joint + * @ingroup joints + */ +ODE_API void dJointGetPUAxis1 (dJointID, dVector3 result); + +/** + * @brief Get the second axis of the Universal component of the joint + * @ingroup joints + */ +ODE_API void dJointGetPUAxis2 (dJointID, dVector3 result); + +/** + * @brief Get the prismatic axis + * @ingroup joints + */ +ODE_API void dJointGetPUAxis3 (dJointID, dVector3 result); + +/** + * @brief Get the prismatic axis + * @ingroup joints + * + * @note This function was added for convenience it is the same as + * dJointGetPUAxis3 + */ +ODE_API void dJointGetPUAxisP (dJointID id, dVector3 result); + + + + +/** + * @brief Get both angles at the same time. + * @ingroup joints + * + * @param joint The Prismatic universal joint for which we want to calculate the angles + * @param angle1 The angle between the body1 and the axis 1 + * @param angle2 The angle between the body2 and the axis 2 + * + * @note This function combine dJointGetPUAngle1 and dJointGetPUAngle2 together + * and try to avoid redundant calculation + */ +ODE_API void dJointGetPUAngles (dJointID, dReal *angle1, dReal *angle2); + +/** + * @brief Get angle + * @ingroup joints + */ +ODE_API dReal dJointGetPUAngle1 (dJointID); + +/** + * @brief * @brief Get time derivative of angle1 + * + * @ingroup joints + */ +ODE_API dReal dJointGetPUAngle1Rate (dJointID); + + +/** + * @brief Get angle + * @ingroup joints + */ +ODE_API dReal dJointGetPUAngle2 (dJointID); + +/** + * @brief * @brief Get time derivative of angle2 + * + * @ingroup joints + */ +ODE_API dReal dJointGetPUAngle2Rate (dJointID); + + /** + * @brief get joint parameter + * @ingroup joints + */ +ODE_API dReal dJointGetPUParam (dJointID, int parameter); + + + + + +/** + * @brief Get the Piston linear position (i.e. the piston's extension) + * + * When the axis is set, the current position of the attached bodies is + * examined and that position will be the zero position. + * @ingroup joints + */ +ODE_API dReal dJointGetPistonPosition (dJointID); + +/** + * @brief Get the piston linear position's time derivative. + * @ingroup joints + */ +ODE_API dReal dJointGetPistonPositionRate (dJointID); + +/** + * @brief Get the Piston angular position (i.e. the twist between the 2 bodies) + * + * When the axis is set, the current position of the attached bodies is + * examined and that position will be the zero position. + * @ingroup joints + */ +ODE_API dReal dJointGetPistonAngle (dJointID); + +/** + * @brief Get the piston angular position's time derivative. + * @ingroup joints + */ +ODE_API dReal dJointGetPistonAngleRate (dJointID); + + +/** + * @brief Get the joint anchor + * + * This returns the point on body 1. If the joint is perfectly satisfied, + * this will be the same as the point on body 2 in direction perpendicular + * to the prismatic axis. + * + * @ingroup joints + */ +ODE_API void dJointGetPistonAnchor (dJointID, dVector3 result); + +/** + * @brief Get the joint anchor w.r.t. body 2 + * + * This returns the point on body 2. You can think of a Piston + * joint as trying to keep the result of dJointGetPistonAnchor() and + * dJointGetPistonAnchor2() the same in the direction perpendicular to the + * pirsmatic axis. If the joint is perfectly satisfied, + * this function will return the same value as dJointGetPistonAnchor() to + * within roundoff errors. dJointGetPistonAnchor2() can be used, along with + * dJointGetPistonAnchor(), to see how far the joint has come apart. + * + * @ingroup joints + */ +ODE_API void dJointGetPistonAnchor2 (dJointID, dVector3 result); + +/** + * @brief Get the prismatic axis (This is also the rotoide axis. + * @ingroup joints + */ +ODE_API void dJointGetPistonAxis (dJointID, dVector3 result); + +/** + * @brief get joint parameter + * @ingroup joints + */ +ODE_API dReal dJointGetPistonParam (dJointID, int parameter); + + +/** + * @brief Get the number of angular axes that will be controlled by the + * AMotor. + * @param num can range from 0 (which effectively deactivates the + * joint) to 3. + * This is automatically set to 3 in dAMotorEuler mode. + * @ingroup joints + */ +ODE_API int dJointGetAMotorNumAxes (dJointID); + +/** + * @brief Get the AMotor axes. + * @param anum selects the axis to change (0,1 or 2). + * @param rel Each axis can have one of three ``relative orientation'' modes. + * \li 0: The axis is anchored to the global frame. + * \li 1: The axis is anchored to the first body. + * \li 2: The axis is anchored to the second body. + * @ingroup joints + */ +ODE_API void dJointGetAMotorAxis (dJointID, int anum, dVector3 result); + +/** + * @brief Get axis + * @remarks + * The axis vector is always specified in global coordinates regardless + * of the setting of rel. + * There are two GetAMotorAxis functions, one to return the axis and one to + * return the relative mode. + * + * For dAMotorEuler mode: + * \li Only axes 0 and 2 need to be set. Axis 1 will be determined + automatically at each time step. + * \li Axes 0 and 2 must be perpendicular to each other. + * \li Axis 0 must be anchored to the first body, axis 2 must be anchored + to the second body. + * @ingroup joints + */ +ODE_API int dJointGetAMotorAxisRel (dJointID, int anum); + +/** + * @brief Get the current angle for axis. + * @remarks + * In dAMotorUser mode this is simply the value that was set with + * dJointSetAMotorAngle(). + * In dAMotorEuler mode this is the corresponding euler angle. + * @ingroup joints + */ +ODE_API dReal dJointGetAMotorAngle (dJointID, int anum); + +/** + * @brief Get the current angle rate for axis anum. + * @remarks + * In dAMotorUser mode this is always zero, as not enough information is + * available. + * In dAMotorEuler mode this is the corresponding euler angle rate. + * @ingroup joints + */ +ODE_API dReal dJointGetAMotorAngleRate (dJointID, int anum); + +/** + * @brief get joint parameter + * @ingroup joints + */ +ODE_API dReal dJointGetAMotorParam (dJointID, int parameter); + +/** + * @brief Get the angular motor mode. + * @param mode must be one of the following constants: + * \li dAMotorUser The AMotor axes and joint angle settings are entirely + * controlled by the user. This is the default mode. + * \li dAMotorEuler Euler angles are automatically computed. + * The axis a1 is also automatically computed. + * The AMotor axes must be set correctly when in this mode, + * as described below. + * When this mode is initially set the current relative orientations + * of the bodies will correspond to all euler angles at zero. + * @ingroup joints + */ +ODE_API int dJointGetAMotorMode (dJointID); + +/** + * @brief Get nr of axes. + * @ingroup joints + */ +ODE_API int dJointGetLMotorNumAxes (dJointID); + +/** + * @brief Get axis. + * @ingroup joints + */ +ODE_API void dJointGetLMotorAxis (dJointID, int anum, dVector3 result); + +/** + * @brief get joint parameter + * @ingroup joints + */ +ODE_API dReal dJointGetLMotorParam (dJointID, int parameter); + +/** + * @brief get joint parameter + * @ingroup joints + */ +ODE_API dReal dJointGetFixedParam (dJointID, int parameter); + + +/** + * @brief get the contact point of the first wheel of the Transmission joint. + * @ingroup joints + */ +ODE_API void dJointGetTransmissionContactPoint1(dJointID, dVector3 result); + +/** + * @brief get contact point of the second wheel of the Transmission joint. + * @ingroup joints + */ +ODE_API void dJointGetTransmissionContactPoint2(dJointID, dVector3 result); + +/** + * @brief set the first axis for the Transmission joint + * @remarks This is the axis around which the first body is allowed to + * revolve and is attached to it. It is given in global coordinates + * and can only be set explicitly in intersecting-axes mode. For the + * parallel-axes and chain modes which share one common axis of + * revolution for both gears dJointSetTransmissionAxis should be used. + * @ingroup joints + */ +ODE_API void dJointSetTransmissionAxis1(dJointID, dReal x, dReal y, dReal z); + +/** + * @brief get first axis for the Transmission joint + * @remarks In parallel-axes and chain mode the common axis with + * respect to the first body is returned. If the joint constraint is + * satisfied it should be the same as the axis return with + * dJointGetTransmissionAxis2 or dJointGetTransmissionAxis. + * @ingroup joints + */ +ODE_API void dJointGetTransmissionAxis1(dJointID, dVector3 result); + +/** + * @brief set second axis for the Transmission joint + * @remarks This is the axis around which the second body is allowed + * to revolve and is attached to it. It is given in global + * coordinates and can only be set explicitly in intersecting-axes + * mode. For the parallel-axes and chain modes which share one common + * axis of revolution for both gears dJointSetTransmissionAxis should + * be used. + * @ingroup joints + */ +ODE_API void dJointSetTransmissionAxis2(dJointID, dReal x, dReal y, dReal z); + +/** + * @brief get second axis for the Transmission joint + * @remarks In parallel-axes and chain mode the common axis with + * respect to the second body is returned. If the joint constraint is + * satisfied it should be the same as the axis return with + * dJointGetTransmissionAxis1 or dJointGetTransmissionAxis. + * @ingroup joints + */ +ODE_API void dJointGetTransmissionAxis2(dJointID, dVector3 result); + +/** + * @brief set the first anchor for the Transmission joint + * @remarks This is the point of attachment of the wheel on the + * first body. It is given in global coordinates. + * @ingroup joints + */ +ODE_API void dJointSetTransmissionAnchor1(dJointID, dReal x, dReal y, dReal z); + +/** + * @brief get the first anchor of the Transmission joint + * @ingroup joints + */ +ODE_API void dJointGetTransmissionAnchor1(dJointID, dVector3 result); + +/** + * @brief set the second anchor for the Transmission joint + * @remarks This is the point of attachment of the wheel on the + * second body. It is given in global coordinates. + * @ingroup joints + */ +ODE_API void dJointSetTransmissionAnchor2(dJointID, dReal x, dReal y, dReal z); + +/** + * @brief get the second anchor for the Transmission joint + * @ingroup joints + */ +ODE_API void dJointGetTransmissionAnchor2(dJointID, dVector3 result); + +/** + * @brief set a Transmission joint parameter + * @ingroup joints + */ +ODE_API void dJointSetTransmissionParam(dJointID, int parameter, dReal value); + +/** + * @brief get a Transmission joint parameter + * @ingroup joints + */ +ODE_API dReal dJointGetTransmissionParam(dJointID, int parameter); + +/** + * @brief set the Transmission joint mode + * @remarks The mode can be one of dTransmissionParallelAxes, + * dTransmissionIntersectingAxes and dTransmissionChainDrive simulating a + * set of parallel-axes gears, intersecting-axes beveled gears or + * chain and sprockets respectively. + * @ingroup joints + */ +ODE_API void dJointSetTransmissionMode( dJointID j, int mode ); + +/** + * @brief get the Transmission joint mode + * @ingroup joints + */ +ODE_API int dJointGetTransmissionMode( dJointID j ); + +/** + * @brief set the Transmission ratio + * @remarks This is the ratio of the angular speed of the first gear + * to that of the second gear. It can only be set explicitly in + * parallel-axes mode. In intersecting-axes mode the ratio is defined + * implicitly by the initial configuration of the wheels and in chain + * mode it is defined implicitly be the wheel radii. + * @ingroup joints + */ +ODE_API void dJointSetTransmissionRatio( dJointID j, dReal ratio ); + +/** + * @brief get the Transmission joint ratio + * @ingroup joints + */ +ODE_API dReal dJointGetTransmissionRatio( dJointID j ); + +/** + * @brief set the common axis for both wheels of the Transmission joint + * @remarks This sets the common axis of revolution for both wheels + * and should only be used in parallel-axes or chain mode. For + * intersecting-axes mode where each wheel axis needs to be specified + * individually dJointSetTransmissionAxis1 and + * dJointSetTransmissionAxis2 should be used. The axis is given in + * global coordinates + * @ingroup joints + */ +ODE_API void dJointSetTransmissionAxis( dJointID j, dReal x, dReal y, dReal z ); + +/** + * @brief get the common axis for both wheels of the Transmission joint + * @ingroup joints + */ +ODE_API void dJointGetTransmissionAxis( dJointID j, dVector3 result ); + +/** + * @brief get the phase, that is the traversed angle for the first + * wheel of the Transmission joint + * @ingroup joints + */ +ODE_API dReal dJointGetTransmissionAngle1( dJointID j ); + +/** + * @brief get the phase, that is the traversed angle for the second + * wheel of the Transmission joint + * @ingroup joints + */ +ODE_API dReal dJointGetTransmissionAngle2( dJointID j ); + +/** + * @brief get the radius of the first wheel of the Transmission joint + * @ingroup joints + */ +ODE_API dReal dJointGetTransmissionRadius1( dJointID j ); + +/** + * @brief get the radius of the second wheel of the Transmission joint + * @ingroup joints + */ +ODE_API dReal dJointGetTransmissionRadius2( dJointID j ); + +/** + * @brief set the radius of the first wheel of the Transmission joint + * @remarks The wheel radii can only be set explicitly in chain mode. + * In the other modes they're defined implicitly by the initial + * configuration and ratio of the wheels. + * @ingroup joints + */ +ODE_API void dJointSetTransmissionRadius1( dJointID j, dReal radius ); + +/** + * @brief set the radius of the second wheel of the Transmission joint + * @remarks The wheel radii can only be set explicitly in chain mode. + * In the other modes they're defined implicitly by the initial + * configuration and ratio of the wheels. + * @ingroup joints + */ +ODE_API void dJointSetTransmissionRadius2( dJointID j, dReal radius ); + +/** + * @brief get the backlash of the Transmission joint + * @ingroup joints + */ +ODE_API dReal dJointGetTransmissionBacklash( dJointID j ); + +/** + * @brief set the backlash of the Transmission joint + * @remarks Backlash is the clearance in the mesh of the wheels of the + * transmission and is defined as the maximum distance that the + * geometric contact point can travel without any actual contact or + * transfer of power between the wheels. This can be converted in + * degrees of revolution for each wheel by dividing by the wheel's + * radius. To further illustrate this consider the situation where a + * wheel of radius r_1 is driving another wheel of radius r_2 and + * there is an amount of backlash equal to b in their mesh. If the + * driving wheel were to instantaneously stop there would be no + * contact and hence the driven wheel would continue to turn for + * another b / r_2 radians until all the backlash in the mesh was take + * up and contact restored with the relationship of driving and driven + * wheel reversed. The backlash is therefore given in untis of + * length. + * @ingroup joints + */ +ODE_API void dJointSetTransmissionBacklash( dJointID j, dReal backlash ); + +/** + * @brief set anchor1 for double ball joint + * @ingroup joints + */ +ODE_API void dJointSetDBallAnchor1(dJointID, dReal x, dReal y, dReal z); + +/** + * @brief set anchor2 for double ball joint + * @ingroup joints + */ +ODE_API void dJointSetDBallAnchor2(dJointID, dReal x, dReal y, dReal z); + +/** + * @brief get anchor1 from double ball joint + * @ingroup joints + */ +ODE_API void dJointGetDBallAnchor1(dJointID, dVector3 result); + +/** + * @brief get anchor2 from double ball joint + * @ingroup joints + */ +ODE_API void dJointGetDBallAnchor2(dJointID, dVector3 result); + +/** + * @brief get the target distance from double ball joint + * @ingroup joints + */ +ODE_API dReal dJointGetDBallDistance(dJointID); + +/** + * @brief set the target distance for the double ball joint + * @ingroup joints + */ +ODE_API void dJointSetDBallDistance(dJointID, dReal dist); + +/** + * @brief set double ball joint parameter + * @ingroup joints + */ +ODE_API void dJointSetDBallParam(dJointID, int parameter, dReal value); + +/** + * @brief get double ball joint parameter + * @ingroup joints + */ +ODE_API dReal dJointGetDBallParam(dJointID, int parameter); + +/** + * @brief set axis for double hinge joint + * @ingroup joints + */ +ODE_API void dJointSetDHingeAxis(dJointID, dReal x, dReal y, dReal z); + +/** + * @brief get axis for double hinge joint + * @ingroup joints + */ +ODE_API void dJointGetDHingeAxis(dJointID, dVector3 result); + +/** + * @brief set anchor1 for double hinge joint + * @ingroup joints + */ +ODE_API void dJointSetDHingeAnchor1(dJointID, dReal x, dReal y, dReal z); + +/** + * @brief set anchor2 for double hinge joint + * @ingroup joints + */ +ODE_API void dJointSetDHingeAnchor2(dJointID, dReal x, dReal y, dReal z); + +/** + * @brief get anchor1 from double hinge joint + * @ingroup joints + */ +ODE_API void dJointGetDHingeAnchor1(dJointID, dVector3 result); + +/** + * @brief get anchor2 from double hinge joint + * @ingroup joints + */ +ODE_API void dJointGetDHingeAnchor2(dJointID, dVector3 result); + +/** + * @brief get the set distance from double hinge joint + * @ingroup joints + */ +ODE_API dReal dJointGetDHingeDistance(dJointID); + +/** + * @brief set double hinge joint parameter + * @ingroup joints + */ +ODE_API void dJointSetDHingeParam(dJointID, int parameter, dReal value); + +/** + * @brief get double hinge joint parameter + * @ingroup joints + */ +ODE_API dReal dJointGetDHingeParam(dJointID, int parameter); + + + + +/** + * @ingroup joints + */ +ODE_API dJointID dConnectingJoint (dBodyID, dBodyID); + +/** + * @ingroup joints + */ +ODE_API int dConnectingJointList (dBodyID, dBodyID, dJointID*); + +/** + * @brief Utility function + * @return 1 if the two bodies are connected together by + * a joint, otherwise return 0. + * @ingroup joints + */ +ODE_API int dAreConnected (dBodyID, dBodyID); + +/** + * @brief Utility function + * @return 1 if the two bodies are connected together by + * a joint that does not have type @arg{joint_type}, otherwise return 0. + * @param body1 A body to check. + * @param body2 A body to check. + * @param joint_type is a dJointTypeXXX constant. + * This is useful for deciding whether to add contact joints between two bodies: + * if they are already connected by non-contact joints then it may not be + * appropriate to add contacts, however it is okay to add more contact between- + * bodies that already have contacts. + * @ingroup joints + */ +ODE_API int dAreConnectedExcluding (dBodyID body1, dBodyID body2, int joint_type); + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/libs/ode-0.16.1/include/ode/ode.h b/libs/ode-0.16.1/include/ode/ode.h new file mode 100644 index 0000000..a69f46a --- /dev/null +++ b/libs/ode-0.16.1/include/ode/ode.h @@ -0,0 +1,56 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#ifndef _ODE_ODE_H_ +#define _ODE_ODE_H_ + +/* include *everything* here */ + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#ifdef __cplusplus +# include +# include +#endif + +#endif diff --git a/libs/ode-0.16.1/include/ode/odeconfig.h b/libs/ode-0.16.1/include/ode/odeconfig.h new file mode 100644 index 0000000..1a0c747 --- /dev/null +++ b/libs/ode-0.16.1/include/ode/odeconfig.h @@ -0,0 +1,218 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#ifndef _ODE_ODECONFIG_H_ +#define _ODE_ODECONFIG_H_ + +/* Pull in the standard headers */ +#include +#include +#include +#include +#include +#include +#include +#include + + +#include + + +#if defined(ODE_DLL) || defined(ODE_LIB) +#define __ODE__ +#endif + +/* Define a DLL export symbol for those platforms that need it */ +#if defined(_MSC_VER) || (defined(__GNUC__) && defined(_WIN32)) + #if defined(ODE_DLL) + #define ODE_API __declspec(dllexport) + #else + #define ODE_API + #endif +#endif + +#if !defined(ODE_API) + #define ODE_API +#endif + +#if defined(_MSC_VER) +# define ODE_API_DEPRECATED __declspec(deprecated) +#elif defined (__GNUC__) && ( (__GNUC__ > 3) || ((__GNUC__ == 3) && (__GNUC_MINOR__ >= 1)) ) +# define ODE_API_DEPRECATED __attribute__((__deprecated__)) +#else +# define ODE_API_DEPRECATED +#endif + +#define ODE_PURE_INLINE static __inline +#define ODE_INLINE __inline + +#if defined(__cplusplus) + #define ODE_EXTERN_C extern "C" +#else + #define ODE_EXTERN_C +#endif + +#if defined(__GNUC__) +#define ODE_NORETURN __attribute__((noreturn)) +#elif defined(_MSC_VER) +#define ODE_NORETURN __declspec(noreturn) +#else // #if !defined(_MSC_VER) +#define ODE_NORETURN +#endif // #if !defined(__GNUC__) + + +/* Well-defined common data types...need to be defined for 64 bit systems */ +#if defined(__aarch64__) || defined(__alpha__) || defined(__ppc64__) \ + || defined(__s390__) || defined(__s390x__) || defined(__zarch__) \ + || defined(__mips__) || defined(__powerpc64__) || defined(__riscv) \ + || (defined(__sparc__) && defined(__arch64__)) + #include + typedef int64_t dint64; + typedef uint64_t duint64; + typedef int32_t dint32; + typedef uint32_t duint32; + typedef int16_t dint16; + typedef uint16_t duint16; + typedef int8_t dint8; + typedef uint8_t duint8; + + typedef intptr_t dintptr; + typedef uintptr_t duintptr; + typedef ptrdiff_t ddiffint; + typedef size_t dsizeint; + +#elif (defined(_M_IA64) || defined(__ia64__) || defined(_M_AMD64) || defined(__x86_64__)) && !defined(__ILP32__) && !defined(_ILP32) + #define X86_64_SYSTEM 1 +#if defined(_MSC_VER) + typedef __int64 dint64; + typedef unsigned __int64 duint64; +#else +#if defined(_LP64) || defined(__LP64__) +typedef long dint64; +typedef unsigned long duint64; +#else + typedef long long dint64; + typedef unsigned long long duint64; +#endif +#endif + typedef int dint32; + typedef unsigned int duint32; + typedef short dint16; + typedef unsigned short duint16; + typedef signed char dint8; + typedef unsigned char duint8; + + typedef dint64 dintptr; + typedef duint64 duintptr; + typedef dint64 ddiffint; + typedef duint64 dsizeint; + +#else +#if defined(_MSC_VER) + typedef __int64 dint64; + typedef unsigned __int64 duint64; +#else + typedef long long dint64; + typedef unsigned long long duint64; +#endif + typedef int dint32; + typedef unsigned int duint32; + typedef short dint16; + typedef unsigned short duint16; + typedef signed char dint8; + typedef unsigned char duint8; + + typedef dint32 dintptr; + typedef duint32 duintptr; + typedef dint32 ddiffint; + typedef duint32 dsizeint; + +#endif + + +/* Define the dInfinity macro */ +#ifdef INFINITY + #ifdef dSINGLE + #define dInfinity ((float)INFINITY) + #else + #define dInfinity ((double)INFINITY) + #endif +#elif defined(HUGE_VAL) + #ifdef dSINGLE + #ifdef HUGE_VALF + #define dInfinity HUGE_VALF + #else + #define dInfinity ((float)HUGE_VAL) + #endif + #else + #define dInfinity HUGE_VAL + #endif +#else + #ifdef dSINGLE + #define dInfinity ((float)(1.0/0.0)) + #else + #define dInfinity (1.0/0.0) + #endif +#endif + + +/* Define the dNaN macro */ +#if defined(NAN) + #define dNaN NAN +#elif defined(__GNUC__) + #define dNaN ({ union { duint32 m_ui; float m_f; } un; un.m_ui = 0x7FC00000; un.m_f; }) +#elif defined(__cplusplus) + union _dNaNUnion + { + _dNaNUnion(): m_ui(0x7FC00000) {} + duint32 m_ui; + float m_f; + }; + #define dNaN (_dNaNUnion().m_f) +#else + #ifdef dSINGLE + #define dNaN ((float)(dInfinity - dInfinity)) + #else + #define dNaN (dInfinity - dInfinity) + #endif +#endif + + + /* Visual C does not define these functions */ +#if defined(_MSC_VER) + #define _ode_copysignf(x, y) ((float)_copysign(x, y)) + #define _ode_copysign(x, y) _copysign(x, y) + #define _ode_nextafterf(x, y) _nextafterf(x, y) + #define _ode_nextafter(x, y) _nextafter(x, y) + #if !defined(_WIN64) && defined(dSINGLE) + #define _ODE__NEXTAFTERF_REQUIRED + ODE_EXTERN_C float _nextafterf(float x, float y); + #endif +#else + #define _ode_copysignf(x, y) copysignf(x, y) + #define _ode_copysign(x, y) copysign(x, y) + #define _ode_nextafterf(x, y) nextafterf(x, y) + #define _ode_nextafter(x, y) nextafter(x, y) +#endif + + +#endif diff --git a/libs/ode-0.16.1/include/ode/odecpp.h b/libs/ode-0.16.1/include/ode/odecpp.h new file mode 100644 index 0000000..f604d0d --- /dev/null +++ b/libs/ode-0.16.1/include/ode/odecpp.h @@ -0,0 +1,1355 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +/* C++ interface for non-collision stuff */ + + +#ifndef _ODE_ODECPP_H_ +#define _ODE_ODECPP_H_ +#ifdef __cplusplus + + + + +//namespace ode { + + +class dWorldSimpleIDContainer { +protected: + dWorldID _id; + + dWorldSimpleIDContainer(): _id(0) {} + ~dWorldSimpleIDContainer() { destroy(); } + + void destroy() { + if (_id) { + dWorldDestroy(_id); + _id = 0; + } + } +}; + +class dWorldDynamicIDContainer: public dWorldSimpleIDContainer { +protected: + virtual ~dWorldDynamicIDContainer() {} +}; + +template +class dWorldTemplate: public dWorldTemplateBase { + // intentionally undefined, don't use these + dWorldTemplate (const dWorldTemplate &); + void operator= (const dWorldTemplate &); + +protected: + dWorldID get_id() const { return dWorldTemplateBase::_id; } + void set_id(dWorldID value) { dWorldTemplateBase::_id = value; } + +public: + dWorldTemplate() + { set_id(dWorldCreate()); } + + dWorldID id() const + { return get_id(); } + operator dWorldID() const + { return get_id(); } + + void setGravity (dReal x, dReal y, dReal z) + { dWorldSetGravity (get_id(), x, y, z); } + void setGravity (const dVector3 g) + { setGravity (g[0], g[1], g[2]); } + void getGravity (dVector3 g) const + { dWorldGetGravity (get_id(), g); } + + void setERP (dReal erp) + { dWorldSetERP(get_id(), erp); } + dReal getERP() const + { return dWorldGetERP(get_id()); } + + void setCFM (dReal cfm) + { dWorldSetCFM(get_id(), cfm); } + dReal getCFM() const + { return dWorldGetCFM(get_id()); } + + void step (dReal stepsize) + { dWorldStep (get_id(), stepsize); } + + void quickStep(dReal stepsize) + { dWorldQuickStep (get_id(), stepsize); } + void setQuickStepNumIterations(int num) + { dWorldSetQuickStepNumIterations (get_id(), num); } + int getQuickStepNumIterations() const + { return dWorldGetQuickStepNumIterations (get_id()); } + void setQuickStepW(dReal over_relaxation) + { dWorldSetQuickStepW (get_id(), over_relaxation); } + dReal getQuickStepW() const + { return dWorldGetQuickStepW (get_id()); } + + void setAutoDisableLinearThreshold (dReal threshold) + { dWorldSetAutoDisableLinearThreshold (get_id(), threshold); } + dReal getAutoDisableLinearThreshold() const + { return dWorldGetAutoDisableLinearThreshold (get_id()); } + void setAutoDisableAngularThreshold (dReal threshold) + { dWorldSetAutoDisableAngularThreshold (get_id(), threshold); } + dReal getAutoDisableAngularThreshold() const + { return dWorldGetAutoDisableAngularThreshold (get_id()); } + void setAutoDisableSteps (int steps) + { dWorldSetAutoDisableSteps (get_id(), steps); } + int getAutoDisableSteps() const + { return dWorldGetAutoDisableSteps (get_id()); } + void setAutoDisableTime (dReal time) + { dWorldSetAutoDisableTime (get_id(), time); } + dReal getAutoDisableTime() const + { return dWorldGetAutoDisableTime (get_id()); } + void setAutoDisableFlag (int do_auto_disable) + { dWorldSetAutoDisableFlag (get_id(), do_auto_disable); } + int getAutoDisableFlag() const + { return dWorldGetAutoDisableFlag (get_id()); } + + dReal getLinearDampingThreshold() const + { return dWorldGetLinearDampingThreshold(get_id()); } + void setLinearDampingThreshold(dReal threshold) + { dWorldSetLinearDampingThreshold(get_id(), threshold); } + dReal getAngularDampingThreshold() const + { return dWorldGetAngularDampingThreshold(get_id()); } + void setAngularDampingThreshold(dReal threshold) + { dWorldSetAngularDampingThreshold(get_id(), threshold); } + dReal getLinearDamping() const + { return dWorldGetLinearDamping(get_id()); } + void setLinearDamping(dReal scale) + { dWorldSetLinearDamping(get_id(), scale); } + dReal getAngularDamping() const + { return dWorldGetAngularDamping(get_id()); } + void setAngularDamping(dReal scale) + { dWorldSetAngularDamping(get_id(), scale); } + void setDamping(dReal linear_scale, dReal angular_scale) + { dWorldSetDamping(get_id(), linear_scale, angular_scale); } + + dReal getMaxAngularSpeed() const + { return dWorldGetMaxAngularSpeed(get_id()); } + void setMaxAngularSpeed(dReal max_speed) + { dWorldSetMaxAngularSpeed(get_id(), max_speed); } + + void setContactSurfaceLayer(dReal depth) + { dWorldSetContactSurfaceLayer (get_id(), depth); } + dReal getContactSurfaceLayer() const + { return dWorldGetContactSurfaceLayer (get_id()); } + + void impulseToForce (dReal stepsize, dReal ix, dReal iy, dReal iz, + dVector3 force) + { dWorldImpulseToForce (get_id(), stepsize, ix, iy, iz, force); } +}; + + +class dBodySimpleIDContainer { +protected: + dBodyID _id; + + dBodySimpleIDContainer(): _id(0) {} + ~dBodySimpleIDContainer() { destroy(); } + + void destroy() { + if (_id) { + dBodyDestroy(_id); + _id = 0; + } + } +}; + +class dBodyDynamicIDContainer: public dBodySimpleIDContainer { +protected: + virtual ~dBodyDynamicIDContainer() {} +}; + +template +class dBodyTemplate: public dBodyTemplateBase { + // intentionally undefined, don't use these + dBodyTemplate (const dBodyTemplate &); + void operator= (const dBodyTemplate &); + +protected: + dBodyID get_id() const { return dBodyTemplateBase::_id; } + void set_id(dBodyID value) { dBodyTemplateBase::_id = value; } + + void destroy() { dBodyTemplateBase::destroy(); } + +public: + dBodyTemplate() + { } + dBodyTemplate (dWorldID world) + { set_id(dBodyCreate(world)); } + dBodyTemplate (dWorldTemplate& world) + { set_id(dBodyCreate(world.id())); } + + void create (dWorldID world) { + destroy(); + set_id(dBodyCreate(world)); + } + void create (dWorldTemplate& world) { + create(world.id()); + } + + dBodyID id() const + { return get_id(); } + operator dBodyID() const + { return get_id(); } + + void setData (void *data) + { dBodySetData (get_id(), data); } + void *getData() const + { return dBodyGetData (get_id()); } + + void setPosition (dReal x, dReal y, dReal z) + { dBodySetPosition (get_id(), x, y, z); } + void setPosition (const dVector3 p) + { setPosition(p[0], p[1], p[2]); } + + void setRotation (const dMatrix3 R) + { dBodySetRotation (get_id(), R); } + void setQuaternion (const dQuaternion q) + { dBodySetQuaternion (get_id(), q); } + void setLinearVel (dReal x, dReal y, dReal z) + { dBodySetLinearVel (get_id(), x, y, z); } + void setLinearVel (const dVector3 v) + { setLinearVel(v[0], v[1], v[2]); } + void setAngularVel (dReal x, dReal y, dReal z) + { dBodySetAngularVel (get_id(), x, y, z); } + void setAngularVel (const dVector3 v) + { setAngularVel (v[0], v[1], v[2]); } + + const dReal * getPosition() const + { return dBodyGetPosition (get_id()); } + const dReal * getRotation() const + { return dBodyGetRotation (get_id()); } + const dReal * getQuaternion() const + { return dBodyGetQuaternion (get_id()); } + const dReal * getLinearVel() const + { return dBodyGetLinearVel (get_id()); } + const dReal * getAngularVel() const + { return dBodyGetAngularVel (get_id()); } + + void setMass (const dMass *mass) + { dBodySetMass (get_id(), mass); } + void setMass (const dMass &mass) + { setMass (&mass); } + dMass getMass () const + { dMass mass; dBodyGetMass (get_id(), &mass); return mass; } + + void addForce (dReal fx, dReal fy, dReal fz) + { dBodyAddForce (get_id(), fx, fy, fz); } + void addForce (const dVector3 f) + { addForce (f[0], f[1], f[2]); } + void addTorque (dReal fx, dReal fy, dReal fz) + { dBodyAddTorque (get_id(), fx, fy, fz); } + void addTorque (const dVector3 t) + { addTorque(t[0], t[1], t[2]); } + + void addRelForce (dReal fx, dReal fy, dReal fz) + { dBodyAddRelForce (get_id(), fx, fy, fz); } + void addRelForce (const dVector3 f) + { addRelForce (f[0], f[1], f[2]); } + void addRelTorque (dReal fx, dReal fy, dReal fz) + { dBodyAddRelTorque (get_id(), fx, fy, fz); } + void addRelTorque (const dVector3 t) + { addRelTorque (t[0], t[1], t[2]); } + + void addForceAtPos (dReal fx, dReal fy, dReal fz, + dReal px, dReal py, dReal pz) + { dBodyAddForceAtPos (get_id(), fx, fy, fz, px, py, pz); } + void addForceAtPos (const dVector3 f, const dVector3 p) + { addForceAtPos (f[0], f[1], f[2], p[0], p[1], p[2]); } + + void addForceAtRelPos (dReal fx, dReal fy, dReal fz, + dReal px, dReal py, dReal pz) + { dBodyAddForceAtRelPos (get_id(), fx, fy, fz, px, py, pz); } + void addForceAtRelPos (const dVector3 f, const dVector3 p) + { addForceAtRelPos (f[0], f[1], f[2], p[0], p[1], p[2]); } + + void addRelForceAtPos (dReal fx, dReal fy, dReal fz, + dReal px, dReal py, dReal pz) + { dBodyAddRelForceAtPos (get_id(), fx, fy, fz, px, py, pz); } + void addRelForceAtPos (const dVector3 f, const dVector3 p) + { addRelForceAtPos (f[0], f[1], f[2], p[0], p[1], p[2]); } + + void addRelForceAtRelPos (dReal fx, dReal fy, dReal fz, + dReal px, dReal py, dReal pz) + { dBodyAddRelForceAtRelPos (get_id(), fx, fy, fz, px, py, pz); } + void addRelForceAtRelPos (const dVector3 f, const dVector3 p) + { addRelForceAtRelPos (f[0], f[1], f[2], p[0], p[1], p[2]); } + + const dReal * getForce() const + { return dBodyGetForce(get_id()); } + const dReal * getTorque() const + { return dBodyGetTorque(get_id()); } + void setForce (dReal x, dReal y, dReal z) + { dBodySetForce (get_id(), x, y, z); } + void setForce (const dVector3 f) + { setForce (f[0], f[1], f[2]); } + void setTorque (dReal x, dReal y, dReal z) + { dBodySetTorque (get_id(), x, y, z); } + void setTorque (const dVector3 t) + { setTorque (t[0], t[1], t[2]); } + + void setDynamic() + { dBodySetDynamic (get_id()); } + void setKinematic() + { dBodySetKinematic (get_id()); } + bool isKinematic() const + { return dBodyIsKinematic (get_id()) != 0; } + + void enable() + { dBodyEnable (get_id()); } + void disable() + { dBodyDisable (get_id()); } + bool isEnabled() const + { return dBodyIsEnabled (get_id()) != 0; } + + void getRelPointPos (dReal px, dReal py, dReal pz, dVector3 result) const + { dBodyGetRelPointPos (get_id(), px, py, pz, result); } + void getRelPointPos (const dVector3 p, dVector3 result) const + { getRelPointPos (p[0], p[1], p[2], result); } + + void getRelPointVel (dReal px, dReal py, dReal pz, dVector3 result) const + { dBodyGetRelPointVel (get_id(), px, py, pz, result); } + void getRelPointVel (const dVector3 p, dVector3 result) const + { getRelPointVel (p[0], p[1], p[2], result); } + + void getPointVel (dReal px, dReal py, dReal pz, dVector3 result) const + { dBodyGetPointVel (get_id(), px, py, pz, result); } + void getPointVel (const dVector3 p, dVector3 result) const + { getPointVel (p[0], p[1], p[2], result); } + + void getPosRelPoint (dReal px, dReal py, dReal pz, dVector3 result) const + { dBodyGetPosRelPoint (get_id(), px, py, pz, result); } + void getPosRelPoint (const dVector3 p, dVector3 result) const + { getPosRelPoint (p[0], p[1], p[2], result); } + + void vectorToWorld (dReal px, dReal py, dReal pz, dVector3 result) const + { dBodyVectorToWorld (get_id(), px, py, pz, result); } + void vectorToWorld (const dVector3 p, dVector3 result) const + { vectorToWorld (p[0], p[1], p[2], result); } + + void vectorFromWorld (dReal px, dReal py, dReal pz, dVector3 result) const + { dBodyVectorFromWorld (get_id(), px, py, pz, result); } + void vectorFromWorld (const dVector3 p, dVector3 result) const + { vectorFromWorld (p[0], p[1], p[2], result); } + + void setFiniteRotationMode (bool mode) + { dBodySetFiniteRotationMode (get_id(), mode); } + + void setFiniteRotationAxis (dReal x, dReal y, dReal z) + { dBodySetFiniteRotationAxis (get_id(), x, y, z); } + void setFiniteRotationAxis (const dVector3 a) + { setFiniteRotationAxis (a[0], a[1], a[2]); } + + bool getFiniteRotationMode() const + { return dBodyGetFiniteRotationMode (get_id()) != 0; } + void getFiniteRotationAxis (dVector3 result) const + { dBodyGetFiniteRotationAxis (get_id(), result); } + + int getNumJoints() const + { return dBodyGetNumJoints (get_id()); } + dJointID getJoint (int index) const + { return dBodyGetJoint (get_id(), index); } + + void setGravityMode (bool mode) + { dBodySetGravityMode (get_id(), mode); } + bool getGravityMode() const + { return dBodyGetGravityMode (get_id()) != 0; } + + bool isConnectedTo (dBodyID body) const + { return dAreConnected (get_id(), body) != 0; } + + void setAutoDisableLinearThreshold (dReal threshold) + { dBodySetAutoDisableLinearThreshold (get_id(), threshold); } + dReal getAutoDisableLinearThreshold() const + { return dBodyGetAutoDisableLinearThreshold (get_id()); } + void setAutoDisableAngularThreshold (dReal threshold) + { dBodySetAutoDisableAngularThreshold (get_id(), threshold); } + dReal getAutoDisableAngularThreshold() const + { return dBodyGetAutoDisableAngularThreshold (get_id()); } + void setAutoDisableSteps (int steps) + { dBodySetAutoDisableSteps (get_id(), steps); } + int getAutoDisableSteps() const + { return dBodyGetAutoDisableSteps (get_id()); } + void setAutoDisableTime (dReal time) + { dBodySetAutoDisableTime (get_id(), time); } + dReal getAutoDisableTime() const + { return dBodyGetAutoDisableTime (get_id()); } + void setAutoDisableFlag (bool do_auto_disable) + { dBodySetAutoDisableFlag (get_id(), do_auto_disable); } + bool getAutoDisableFlag() const + { return dBodyGetAutoDisableFlag (get_id()) != 0; } + + dReal getLinearDamping() const + { return dBodyGetLinearDamping(get_id()); } + void setLinearDamping(dReal scale) + { dBodySetLinearDamping(get_id(), scale); } + dReal getAngularDamping() const + { return dBodyGetAngularDamping(get_id()); } + void setAngularDamping(dReal scale) + { dBodySetAngularDamping(get_id(), scale); } + void setDamping(dReal linear_scale, dReal angular_scale) + { dBodySetDamping(get_id(), linear_scale, angular_scale); } + dReal getLinearDampingThreshold() const + { return dBodyGetLinearDampingThreshold(get_id()); } + void setLinearDampingThreshold(dReal threshold) const + { dBodySetLinearDampingThreshold(get_id(), threshold); } + dReal getAngularDampingThreshold() const + { return dBodyGetAngularDampingThreshold(get_id()); } + void setAngularDampingThreshold(dReal threshold) + { dBodySetAngularDampingThreshold(get_id(), threshold); } + void setDampingDefaults() + { dBodySetDampingDefaults(get_id()); } + + dReal getMaxAngularSpeed() const + { return dBodyGetMaxAngularSpeed(get_id()); } + void setMaxAngularSpeed(dReal max_speed) + { dBodySetMaxAngularSpeed(get_id(), max_speed); } + + bool getGyroscopicMode() const + { return dBodyGetGyroscopicMode(get_id()) != 0; } + void setGyroscopicMode(bool mode) + { dBodySetGyroscopicMode(get_id(), mode); } + +}; + + +class dJointGroupSimpleIDContainer { +protected: + dJointGroupID _id; + + dJointGroupSimpleIDContainer(): _id(0) {} + ~dJointGroupSimpleIDContainer() { destroy(); } + + void destroy() { + if (_id) { + dJointGroupDestroy(_id); + _id = 0; + } + } +}; + +class dJointGroupDynamicIDContainer: public dJointGroupSimpleIDContainer { +protected: + virtual ~dJointGroupDynamicIDContainer() {} +}; + +template +class dJointGroupTemplate: public dJointGroupTemplateBase { + // intentionally undefined, don't use these + dJointGroupTemplate (const dJointGroupTemplate &); + void operator= (const dJointGroupTemplate &); + +protected: + dJointGroupID get_id() const { return dJointGroupTemplateBase::_id; } + void set_id(dJointGroupID value) { dJointGroupTemplateBase::_id = value; } + + void destroy() { dJointGroupTemplateBase::destroy(); } + +public: + dJointGroupTemplate () + { set_id(dJointGroupCreate(0)); } + + void create () { + destroy(); + set_id(dJointGroupCreate(0)); + } + + dJointGroupID id() const + { return get_id(); } + operator dJointGroupID() const + { return get_id(); } + + void empty() + { dJointGroupEmpty (get_id()); } + void clear() + { empty(); } +}; + + +class dJointSimpleIDContainer { +protected: + dJointID _id; + + dJointSimpleIDContainer(): _id(0) {} + ~dJointSimpleIDContainer() { destroy(); } + + void destroy() { + if (_id) { + dJointDestroy (_id); + _id = 0; + } + } +}; + +class dJointDynamicIDContainer: public dJointSimpleIDContainer { +protected: + virtual ~dJointDynamicIDContainer() {} +}; + +template +class dJointTemplate: public dJointTemplateBase { +private: + // intentionally undefined, don't use these + dJointTemplate (const dJointTemplate &) ; + void operator= (const dJointTemplate &); + +protected: + dJointID get_id() const { return dJointTemplateBase::_id; } + void set_id(dJointID value) { dJointTemplateBase::_id = value; } + + void destroy() { dJointTemplateBase::destroy(); } + +protected: + dJointTemplate() // don't let user construct pure dJointTemplate objects + { } + +public: + dJointID id() const + { return get_id(); } + operator dJointID() const + { return get_id(); } + + int getNumBodies() const + { return dJointGetNumBodies(get_id()); } + + void attach (dBodyID body1, dBodyID body2) + { dJointAttach (get_id(), body1, body2); } + void attach (dBodyTemplate& body1, dBodyTemplate& body2) + { attach(body1.id(), body2.id()); } + + void enable() + { dJointEnable (get_id()); } + void disable() + { dJointDisable (get_id()); } + bool isEnabled() const + { return dJointIsEnabled (get_id()) != 0; } + + void setData (void *data) + { dJointSetData (get_id(), data); } + void *getData() const + { return dJointGetData (get_id()); } + + dJointType getType() const + { return dJointGetType (get_id()); } + + dBodyID getBody (int index) const + { return dJointGetBody (get_id(), index); } + + void setFeedback(dJointFeedback *fb) + { dJointSetFeedback(get_id(), fb); } + dJointFeedback *getFeedback() const + { return dJointGetFeedback(get_id()); } + + // If not implemented it will do nothing as describe in the doc + virtual void setParam (int, dReal) {}; + virtual dReal getParam (int) const { return 0; } +}; + + +template +class dBallJointTemplate : public dJointTemplate { +private: + // intentionally undefined, don't use these + dBallJointTemplate (const dBallJointTemplate &); + void operator= (const dBallJointTemplate &); + +protected: + typedef dJointTemplate dBaseTemplate; + + dJointID get_id() const { return dBaseTemplate::get_id(); } + void set_id(dJointID value) { dBaseTemplate::set_id(value); } + + void destroy() { dBaseTemplate::destroy(); } + +public: + dBallJointTemplate() { } + dBallJointTemplate (dWorldID world, dJointGroupID group=0) + { set_id(dJointCreateBall(world, group)); } + dBallJointTemplate (dWorldTemplate& world, dJointGroupID group=0) + { set_id(dJointCreateBall(world.id(), group)); } + + void create (dWorldID world, dJointGroupID group=0) { + destroy(); + set_id(dJointCreateBall(world, group)); + } + void create (dWorldTemplate& world, dJointGroupID group=0) + { create(world.id(), group); } + + void setAnchor (dReal x, dReal y, dReal z) + { dJointSetBallAnchor (get_id(), x, y, z); } + void setAnchor (const dVector3 a) + { setAnchor (a[0], a[1], a[2]); } + void getAnchor (dVector3 result) const + { dJointGetBallAnchor (get_id(), result); } + void getAnchor2 (dVector3 result) const + { dJointGetBallAnchor2 (get_id(), result); } + virtual void setParam (int parameter, dReal value) + { dJointSetBallParam (get_id(), parameter, value); } + virtual dReal getParam (int parameter) const + { return dJointGetBallParam (get_id(), parameter); } + // TODO: expose params through methods +} ; + + +template +class dHingeJointTemplate : public dJointTemplate { +private: + // intentionally undefined, don't use these + dHingeJointTemplate (const dHingeJointTemplate &); + void operator = (const dHingeJointTemplate &); + +protected: + typedef dJointTemplate dBaseTemplate; + + dJointID get_id() const { return dBaseTemplate::get_id(); } + void set_id(dJointID value) { dBaseTemplate::set_id(value); } + + void destroy() { dBaseTemplate::destroy(); } + +public: + dHingeJointTemplate() { } + dHingeJointTemplate (dWorldID world, dJointGroupID group=0) + { set_id(dJointCreateHinge(world, group)); } + dHingeJointTemplate (dWorldTemplate& world, dJointGroupID group=0) + { set_id(dJointCreateHinge(world.id(), group)); } + + void create (dWorldID world, dJointGroupID group=0) { + destroy(); + set_id(dJointCreateHinge (world, group)); + } + void create (dWorldTemplate& world, dJointGroupID group=0) + { create(world.id(), group); } + + void setAnchor (dReal x, dReal y, dReal z) + { dJointSetHingeAnchor (get_id(), x, y, z); } + void setAnchor (const dVector3 a) + { setAnchor (a[0], a[1], a[2]); } + void getAnchor (dVector3 result) const + { dJointGetHingeAnchor (get_id(), result); } + void getAnchor2 (dVector3 result) const + { dJointGetHingeAnchor2 (get_id(), result); } + + void setAxis (dReal x, dReal y, dReal z) + { dJointSetHingeAxis (get_id(), x, y, z); } + void setAxis (const dVector3 a) + { setAxis(a[0], a[1], a[2]); } + void getAxis (dVector3 result) const + { dJointGetHingeAxis (get_id(), result); } + + dReal getAngle() const + { return dJointGetHingeAngle (get_id()); } + dReal getAngleRate() const + { return dJointGetHingeAngleRate (get_id()); } + + virtual void setParam (int parameter, dReal value) + { dJointSetHingeParam (get_id(), parameter, value); } + virtual dReal getParam (int parameter) const + { return dJointGetHingeParam (get_id(), parameter); } + // TODO: expose params through methods + + void addTorque (dReal torque) + { dJointAddHingeTorque(get_id(), torque); } +}; + + +template +class dSliderJointTemplate : public dJointTemplate { +private: + // intentionally undefined, don't use these + dSliderJointTemplate (const dSliderJointTemplate &); + void operator = (const dSliderJointTemplate &); + +protected: + typedef dJointTemplate dBaseTemplate; + + dJointID get_id() const { return dBaseTemplate::get_id(); } + void set_id(dJointID value) { dBaseTemplate::set_id(value); } + + void destroy() { dBaseTemplate::destroy(); } + +public: + dSliderJointTemplate() { } + dSliderJointTemplate (dWorldID world, dJointGroupID group=0) + { set_id(dJointCreateSlider(world, group)); } + dSliderJointTemplate (dWorldTemplate& world, dJointGroupID group=0) + { set_id(dJointCreateSlider(world.id(), group)); } + + void create (dWorldID world, dJointGroupID group=0) { + destroy(); + set_id(dJointCreateSlider(world, group)); + } + void create (dWorldTemplate& world, dJointGroupID group=0) + { create(world.id(), group); } + + void setAxis (dReal x, dReal y, dReal z) + { dJointSetSliderAxis (get_id(), x, y, z); } + void setAxis (const dVector3 a) + { setAxis (a[0], a[1], a[2]); } + void getAxis (dVector3 result) const + { dJointGetSliderAxis (get_id(), result); } + + dReal getPosition() const + { return dJointGetSliderPosition (get_id()); } + dReal getPositionRate() const + { return dJointGetSliderPositionRate (get_id()); } + + virtual void setParam (int parameter, dReal value) + { dJointSetSliderParam (get_id(), parameter, value); } + virtual dReal getParam (int parameter) const + { return dJointGetSliderParam (get_id(), parameter); } + // TODO: expose params through methods + + void addForce (dReal force) + { dJointAddSliderForce(get_id(), force); } +}; + + +template +class dUniversalJointTemplate : public dJointTemplate { +private: + // intentionally undefined, don't use these + dUniversalJointTemplate (const dUniversalJointTemplate &); + void operator = (const dUniversalJointTemplate &); + +protected: + typedef dJointTemplate dBaseTemplate; + + dJointID get_id() const { return dBaseTemplate::get_id(); } + void set_id(dJointID value) { dBaseTemplate::set_id(value); } + + void destroy() { dBaseTemplate::destroy(); } + +public: + dUniversalJointTemplate() { } + dUniversalJointTemplate (dWorldID world, dJointGroupID group=0) + { set_id(dJointCreateUniversal(world, group)); } + dUniversalJointTemplate (dWorldTemplate& world, dJointGroupID group=0) + { set_id(dJointCreateUniversal(world.id(), group)); } + + void create (dWorldID world, dJointGroupID group=0) { + destroy(); + set_id(dJointCreateUniversal(world, group)); + } + void create (dWorldTemplate& world, dJointGroupID group=0) + { create(world.id(), group); } + + void setAnchor (dReal x, dReal y, dReal z) + { dJointSetUniversalAnchor (get_id(), x, y, z); } + void setAnchor (const dVector3 a) + { setAnchor(a[0], a[1], a[2]); } + void setAxis1 (dReal x, dReal y, dReal z) + { dJointSetUniversalAxis1 (get_id(), x, y, z); } + void setAxis1 (const dVector3 a) + { setAxis1 (a[0], a[1], a[2]); } + void setAxis2 (dReal x, dReal y, dReal z) + { dJointSetUniversalAxis2 (get_id(), x, y, z); } + void setAxis2 (const dVector3 a) + { setAxis2 (a[0], a[1], a[2]); } + + void getAnchor (dVector3 result) const + { dJointGetUniversalAnchor (get_id(), result); } + void getAnchor2 (dVector3 result) const + { dJointGetUniversalAnchor2 (get_id(), result); } + void getAxis1 (dVector3 result) const + { dJointGetUniversalAxis1 (get_id(), result); } + void getAxis2 (dVector3 result) const + { dJointGetUniversalAxis2 (get_id(), result); } + + virtual void setParam (int parameter, dReal value) + { dJointSetUniversalParam (get_id(), parameter, value); } + virtual dReal getParam (int parameter) const + { return dJointGetUniversalParam (get_id(), parameter); } + // TODO: expose params through methods + + void getAngles(dReal *angle1, dReal *angle2) const + { dJointGetUniversalAngles (get_id(), angle1, angle2); } + + dReal getAngle1() const + { return dJointGetUniversalAngle1 (get_id()); } + dReal getAngle1Rate() const + { return dJointGetUniversalAngle1Rate (get_id()); } + dReal getAngle2() const + { return dJointGetUniversalAngle2 (get_id()); } + dReal getAngle2Rate() const + { return dJointGetUniversalAngle2Rate (get_id()); } + + void addTorques (dReal torque1, dReal torque2) + { dJointAddUniversalTorques(get_id(), torque1, torque2); } +}; + + +template +class dHinge2JointTemplate : public dJointTemplate { +private: + // intentionally undefined, don't use these + dHinge2JointTemplate (const dHinge2JointTemplate &); + void operator = (const dHinge2JointTemplate &); + +protected: + typedef dJointTemplate dBaseTemplate; + + dJointID get_id() const { return dBaseTemplate::get_id(); } + void set_id(dJointID value) { dBaseTemplate::set_id(value); } + + void destroy() { dBaseTemplate::destroy(); } + +public: + dHinge2JointTemplate() { } + dHinge2JointTemplate (dWorldID world, dJointGroupID group=0) + { set_id(dJointCreateHinge2(world, group)); } + dHinge2JointTemplate (dWorldTemplate& world, dJointGroupID group=0) + { set_id(dJointCreateHinge2(world.id(), group)); } + + void create (dWorldID world, dJointGroupID group=0) { + destroy(); + set_id(dJointCreateHinge2(world, group)); + } + void create (dWorldTemplate& world, dJointGroupID group=0) + { create(world.id(), group); } + + void setAnchor (dReal x, dReal y, dReal z) + { dJointSetHinge2Anchor (get_id(), x, y, z); } + void setAnchor (const dVector3 a) + { setAnchor(a[0], a[1], a[2]); } + void setAxes (const dReal *axis1/*=NULL*/, const dReal *axis2/*=NULL*/) + { dJointSetHinge2Axes (get_id(), axis1, axis2); } + ODE_API_DEPRECATED void setAxis1 (dReal x, dReal y, dReal z) + { dVector3 a = { x, y, z }; dJointSetHinge2Axes (get_id(), a, NULL); } + ODE_API_DEPRECATED void setAxis1 (const dVector3 a) + { dJointSetHinge2Axes (get_id(), a, NULL); } + ODE_API_DEPRECATED void setAxis2 (dReal x, dReal y, dReal z) + { dVector3 a = { x, y, z }; dJointSetHinge2Axes (get_id(), NULL, a); } + ODE_API_DEPRECATED void setAxis2 (const dVector3 a) + { dJointSetHinge2Axes (get_id(), NULL, a); } + + void getAnchor (dVector3 result) const + { dJointGetHinge2Anchor (get_id(), result); } + void getAnchor2 (dVector3 result) const + { dJointGetHinge2Anchor2 (get_id(), result); } + void getAxis1 (dVector3 result) const + { dJointGetHinge2Axis1 (get_id(), result); } + void getAxis2 (dVector3 result) const + { dJointGetHinge2Axis2 (get_id(), result); } + + dReal getAngle1() const + { return dJointGetHinge2Angle1 (get_id()); } + dReal getAngle1Rate() const + { return dJointGetHinge2Angle1Rate (get_id()); } + dReal getAngle2Rate() const + { return dJointGetHinge2Angle2Rate (get_id()); } + + virtual void setParam (int parameter, dReal value) + { dJointSetHinge2Param (get_id(), parameter, value); } + virtual dReal getParam (int parameter) const + { return dJointGetHinge2Param (get_id(), parameter); } + // TODO: expose params through methods + + void addTorques(dReal torque1, dReal torque2) + { dJointAddHinge2Torques(get_id(), torque1, torque2); } +}; + + +template +class dPRJointTemplate : public dJointTemplate { +private: + // intentionally undefined, don't use these + dPRJointTemplate (const dPRJointTemplate &); + void operator = (const dPRJointTemplate &); + +protected: + typedef dJointTemplate dBaseTemplate; + + dJointID get_id() const { return dBaseTemplate::get_id(); } + void set_id(dJointID value) { dBaseTemplate::set_id(value); } + + void destroy() { dBaseTemplate::destroy(); } + +public: + dPRJointTemplate() { } + dPRJointTemplate (dWorldID world, dJointGroupID group=0) + { set_id(dJointCreatePR(world, group)); } + dPRJointTemplate (dWorldTemplate& world, dJointGroupID group=0) + { set_id(dJointCreatePR(world.id(), group)); } + + void create (dWorldID world, dJointGroupID group=0) { + destroy(); + set_id(dJointCreatePR(world, group)); + } + void create (dWorldTemplate& world, dJointGroupID group=0) + { create(world.id(), group); } + + void setAnchor (dReal x, dReal y, dReal z) + { dJointSetPRAnchor (get_id(), x, y, z); } + void setAnchor (const dVector3 a) + { setAnchor (a[0], a[1], a[2]); } + void setAxis1 (dReal x, dReal y, dReal z) + { dJointSetPRAxis1 (get_id(), x, y, z); } + void setAxis1 (const dVector3 a) + { setAxis1(a[0], a[1], a[2]); } + void setAxis2 (dReal x, dReal y, dReal z) + { dJointSetPRAxis2 (get_id(), x, y, z); } + void setAxis2 (const dVector3 a) + { setAxis2(a[0], a[1], a[2]); } + + void getAnchor (dVector3 result) const + { dJointGetPRAnchor (get_id(), result); } + void getAxis1 (dVector3 result) const + { dJointGetPRAxis1 (get_id(), result); } + void getAxis2 (dVector3 result) const + { dJointGetPRAxis2 (get_id(), result); } + + dReal getPosition() const + { return dJointGetPRPosition (get_id()); } + dReal getPositionRate() const + { return dJointGetPRPositionRate (get_id()); } + + dReal getAngle() const + { return dJointGetPRAngle (get_id()); } + dReal getAngleRate() const + { return dJointGetPRAngleRate (get_id()); } + + virtual void setParam (int parameter, dReal value) + { dJointSetPRParam (get_id(), parameter, value); } + virtual dReal getParam (int parameter) const + { return dJointGetPRParam (get_id(), parameter); } +}; + + + +template +class dPUJointTemplate : public dJointTemplate +{ +private: + // intentionally undefined, don't use these + dPUJointTemplate (const dPUJointTemplate &); + void operator = (const dPUJointTemplate &); + +protected: + typedef dJointTemplate dBaseTemplate; + + dJointID get_id() const { return dBaseTemplate::get_id(); } + void set_id(dJointID value) { dBaseTemplate::set_id(value); } + + void destroy() { dBaseTemplate::destroy(); } + +public: + dPUJointTemplate() { } + dPUJointTemplate (dWorldID world, dJointGroupID group=0) + { set_id(dJointCreatePU(world, group)); } + dPUJointTemplate (dWorldTemplate& world, dJointGroupID group=0) + { set_id(dJointCreatePU(world.id(), group)); } + + void create (dWorldID world, dJointGroupID group=0) + { + destroy(); + set_id(dJointCreatePU(world, group)); + } + void create (dWorldTemplate& world, dJointGroupID group=0) + { create(world.id(), group); } + + void setAnchor (dReal x, dReal y, dReal z) + { dJointSetPUAnchor (get_id(), x, y, z); } + void setAnchor (const dVector3 a) + { setAnchor (a[0], a[1], a[2]); } + void setAxis1 (dReal x, dReal y, dReal z) + { dJointSetPUAxis1 (get_id(), x, y, z); } + void setAxis1 (const dVector3 a) + { setAxis1(a[0], a[1], a[2]); } + void setAxis2 (dReal x, dReal y, dReal z) + { dJointSetPUAxis2 (get_id(), x, y, z); } + void setAxis3 (dReal x, dReal y, dReal z) + { dJointSetPUAxis3 (get_id(), x, y, z); } + void setAxis3 (const dVector3 a) + { setAxis3(a[0], a[1], a[2]); } + void setAxisP (dReal x, dReal y, dReal z) + { dJointSetPUAxis3 (get_id(), x, y, z); } + void setAxisP (const dVector3 a) + { setAxisP(a[0], a[1], a[2]); } + + virtual void getAnchor (dVector3 result) const + { dJointGetPUAnchor (get_id(), result); } + void getAxis1 (dVector3 result) const + { dJointGetPUAxis1 (get_id(), result); } + void getAxis2 (dVector3 result) const + { dJointGetPUAxis2 (get_id(), result); } + void getAxis3 (dVector3 result) const + { dJointGetPUAxis3 (get_id(), result); } + void getAxisP (dVector3 result) const + { dJointGetPUAxis3 (get_id(), result); } + + dReal getAngle1() const + { return dJointGetPUAngle1 (get_id()); } + dReal getAngle1Rate() const + { return dJointGetPUAngle1Rate (get_id()); } + dReal getAngle2() const + { return dJointGetPUAngle2 (get_id()); } + dReal getAngle2Rate() const + { return dJointGetPUAngle2Rate (get_id()); } + + dReal getPosition() const + { return dJointGetPUPosition (get_id()); } + dReal getPositionRate() const + { return dJointGetPUPositionRate (get_id()); } + + virtual void setParam (int parameter, dReal value) + { dJointSetPUParam (get_id(), parameter, value); } + virtual dReal getParam (int parameter) const + { return dJointGetPUParam (get_id(), parameter); } + // TODO: expose params through methods +}; + + + + + +template +class dPistonJointTemplate : public dJointTemplate +{ +private: + // intentionally undefined, don't use these + dPistonJointTemplate (const dPistonJointTemplate &); + void operator = (const dPistonJointTemplate &); + +protected: + typedef dJointTemplate dBaseTemplate; + + dJointID get_id() const { return dBaseTemplate::get_id(); } + void set_id(dJointID value) { dBaseTemplate::set_id(value); } + + void destroy() { dBaseTemplate::destroy(); } + +public: + dPistonJointTemplate() { } + dPistonJointTemplate (dWorldID world, dJointGroupID group=0) + { set_id(dJointCreatePiston(world, group)); } + dPistonJointTemplate (dWorldTemplate& world, dJointGroupID group=0) + { set_id(dJointCreatePiston(world, group)); } + + void create (dWorldID world, dJointGroupID group=0) + { + destroy(); + set_id(dJointCreatePiston(world, group)); + } + void create (dWorldTemplate& world, dJointGroupID group=0) + { create(world.id(), group); } + + void setAnchor (dReal x, dReal y, dReal z) + { dJointSetPistonAnchor (get_id(), x, y, z); } + void setAnchor (const dVector3 a) + { setAnchor (a[0], a[1], a[2]); } + void getAnchor (dVector3 result) const + { dJointGetPistonAnchor (get_id(), result); } + void getAnchor2 (dVector3 result) const + { dJointGetPistonAnchor2 (get_id(), result); } + + void setAxis (dReal x, dReal y, dReal z) + { dJointSetPistonAxis (get_id(), x, y, z); } + void setAxis (const dVector3 a) + { setAxis(a[0], a[1], a[2]); } + void getAxis (dVector3 result) const + { dJointGetPistonAxis (get_id(), result); } + + dReal getPosition() const + { return dJointGetPistonPosition (get_id()); } + dReal getPositionRate() const + { return dJointGetPistonPositionRate (get_id()); } + + virtual void setParam (int parameter, dReal value) + { dJointSetPistonParam (get_id(), parameter, value); } + virtual dReal getParam (int parameter) const + { return dJointGetPistonParam (get_id(), parameter); } + // TODO: expose params through methods + + void addForce (dReal force) + { dJointAddPistonForce (get_id(), force); } +}; + + + +template +class dFixedJointTemplate : public dJointTemplate +{ +private: + // intentionally undefined, don't use these + dFixedJointTemplate (const dFixedJointTemplate &); + void operator = (const dFixedJointTemplate &); + +protected: + typedef dJointTemplate dBaseTemplate; + + dJointID get_id() const { return dBaseTemplate::get_id(); } + void set_id(dJointID value) { dBaseTemplate::set_id(value); } + + void destroy() { dBaseTemplate::destroy(); } + +public: + dFixedJointTemplate() { } + dFixedJointTemplate (dWorldID world, dJointGroupID group=0) + { set_id(dJointCreateFixed(world, group)); } + dFixedJointTemplate (dWorldTemplate& world, dJointGroupID group=0) + { set_id(dJointCreateFixed(world, group)); } + + void create (dWorldID world, dJointGroupID group=0) { + destroy(); + set_id(dJointCreateFixed(world, group)); + } + void create (dWorldTemplate& world, dJointGroupID group=0) + { create(world.id(), group); } + + void set() + { dJointSetFixed (get_id()); } + + virtual void setParam (int parameter, dReal value) + { dJointSetFixedParam (get_id(), parameter, value); } + + virtual dReal getParam (int parameter) const + { return dJointGetFixedParam (get_id(), parameter); } + // TODO: expose params through methods +}; + + +template +class dContactJointTemplate : public dJointTemplate { +private: + // intentionally undefined, don't use these + dContactJointTemplate (const dContactJointTemplate &); + void operator = (const dContactJointTemplate &); + +protected: + typedef dJointTemplate dBaseTemplate; + + dJointID get_id() const { return dBaseTemplate::get_id(); } + void set_id(dJointID value) { dBaseTemplate::set_id(value); } + + void destroy() { dBaseTemplate::destroy(); } + +public: + dContactJointTemplate() { } + dContactJointTemplate (dWorldID world, dJointGroupID group, dContact *contact) + { set_id(dJointCreateContact(world, group, contact)); } + dContactJointTemplate (dWorldTemplate& world, dJointGroupID group, dContact *contact) + { set_id(dJointCreateContact(world.id(), group, contact)); } + + void create (dWorldID world, dJointGroupID group, dContact *contact) { + destroy(); + set_id(dJointCreateContact(world, group, contact)); + } + + void create (dWorldTemplate& world, dJointGroupID group, dContact *contact) + { create(world.id(), group, contact); } +}; + + +template +class dNullJointTemplate : public dJointTemplate { +private: + // intentionally undefined, don't use these + dNullJointTemplate (const dNullJointTemplate &); + void operator = (const dNullJointTemplate &); + +protected: + typedef dJointTemplate dBaseTemplate; + + dJointID get_id() const { return dBaseTemplate::get_id(); } + void set_id(dJointID value) { dBaseTemplate::set_id(value); } + + void destroy() { dBaseTemplate::destroy(); } + +public: + dNullJointTemplate() { } + dNullJointTemplate (dWorldID world, dJointGroupID group=0) + { set_id(dJointCreateNull(world, group)); } + dNullJointTemplate (dWorldTemplate& world, dJointGroupID group=0) + { set_id(dJointCreateNull (world.id(), group)); } + + void create (dWorldID world, dJointGroupID group=0) { + destroy(); + set_id(dJointCreateNull(world, group)); + } + void create (dWorldTemplate& world, dJointGroupID group=0) + { create(world.id(), group); } +}; + + +template +class dAMotorJointTemplate : public dJointTemplate { +private: + // intentionally undefined, don't use these + dAMotorJointTemplate (const dAMotorJointTemplate &); + void operator = (const dAMotorJointTemplate &); + +protected: + typedef dJointTemplate dBaseTemplate; + + dJointID get_id() const { return dBaseTemplate::get_id(); } + void set_id(dJointID value) { dBaseTemplate::set_id(value); } + + void destroy() { dBaseTemplate::destroy(); } + +public: + dAMotorJointTemplate() { } + dAMotorJointTemplate (dWorldID world, dJointGroupID group=0) + { set_id(dJointCreateAMotor(world, group)); } + dAMotorJointTemplate (dWorldTemplate& world, dJointGroupID group=0) + { set_id(dJointCreateAMotor(world.id(), group)); } + + void create (dWorldID world, dJointGroupID group=0) { + destroy(); + set_id(dJointCreateAMotor(world, group)); + } + void create (dWorldTemplate& world, dJointGroupID group=0) + { create(world.id(), group); } + + void setMode (int mode) + { dJointSetAMotorMode (get_id(), mode); } + int getMode() const + { return dJointGetAMotorMode (get_id()); } + + void setNumAxes (int num) + { dJointSetAMotorNumAxes (get_id(), num); } + int getNumAxes() const + { return dJointGetAMotorNumAxes (get_id()); } + + void setAxis (int anum, int rel, dReal x, dReal y, dReal z) + { dJointSetAMotorAxis (get_id(), anum, rel, x, y, z); } + void setAxis (int anum, int rel, const dVector3 a) + { setAxis(anum, rel, a[0], a[1], a[2]); } + void getAxis (int anum, dVector3 result) const + { dJointGetAMotorAxis (get_id(), anum, result); } + int getAxisRel (int anum) const + { return dJointGetAMotorAxisRel (get_id(), anum); } + + void setAngle (int anum, dReal angle) + { dJointSetAMotorAngle (get_id(), anum, angle); } + dReal getAngle (int anum) const + { return dJointGetAMotorAngle (get_id(), anum); } + dReal getAngleRate (int anum) + { return dJointGetAMotorAngleRate (get_id(), anum); } + + void setParam (int parameter, dReal value) + { dJointSetAMotorParam (get_id(), parameter, value); } + dReal getParam (int parameter) const + { return dJointGetAMotorParam (get_id(), parameter); } + // TODO: expose params through methods + + void addTorques(dReal torque1, dReal torque2, dReal torque3) + { dJointAddAMotorTorques(get_id(), torque1, torque2, torque3); } +}; + + +template +class dLMotorJointTemplate : public dJointTemplate { +private: + // intentionally undefined, don't use these + dLMotorJointTemplate (const dLMotorJointTemplate &); + void operator = (const dLMotorJointTemplate &); + +protected: + typedef dJointTemplate dBaseTemplate; + + dJointID get_id() const { return dBaseTemplate::get_id(); } + void set_id(dJointID value) { dBaseTemplate::set_id(value); } + + void destroy() { dBaseTemplate::destroy(); } + +public: + dLMotorJointTemplate() { } + dLMotorJointTemplate (dWorldID world, dJointGroupID group=0) + { set_id(dJointCreateLMotor(world, group)); } + dLMotorJointTemplate (dWorldTemplate& world, dJointGroupID group=0) + { set_id(dJointCreateLMotor(world.id(), group)); } + + void create (dWorldID world, dJointGroupID group=0) { + destroy(); + set_id(dJointCreateLMotor(world, group)); + } + void create (dWorldTemplate& world, dJointGroupID group=0) + { create(world.id(), group); } + + void setNumAxes (int num) + { dJointSetLMotorNumAxes (get_id(), num); } + int getNumAxes() const + { return dJointGetLMotorNumAxes (get_id()); } + + void setAxis (int anum, int rel, dReal x, dReal y, dReal z) + { dJointSetLMotorAxis (get_id(), anum, rel, x, y, z); } + void setAxis (int anum, int rel, const dVector3 a) + { setAxis(anum, rel, a[0], a[1], a[2]); } + void getAxis (int anum, dVector3 result) const + { dJointGetLMotorAxis (get_id(), anum, result); } + + void setParam (int parameter, dReal value) + { dJointSetLMotorParam (get_id(), parameter, value); } + dReal getParam (int parameter) const + { return dJointGetLMotorParam (get_id(), parameter); } + // TODO: expose params through methods +}; + +//} + +#if !defined(dODECPP_WORLD_TEMPLATE_BASE) + +#if defined(dODECPP_BODY_TEMPLATE_BASE) || defined(dODECPP_JOINTGROUP_TEMPLATE_BASE) || defined(dODECPP_JOINT_TEMPLATE_BASE) +#error All the odecpp template bases must be defined or not defined together +#endif + +#define dODECPP_WORLD_TEMPLATE_BASE dWorldDynamicIDContainer +#define dODECPP_BODY_TEMPLATE_BASE dBodyDynamicIDContainer +#define dODECPP_JOINTGROUP_TEMPLATE_BASE dJointGroupDynamicIDContainer +#define dODECPP_JOINT_TEMPLATE_BASE dJointDynamicIDContainer + +#else // #if defined(dODECPP_WORLD_TEMPLATE_BASE) + +#if !defined(dODECPP_BODY_TEMPLATE_BASE) || !defined(dODECPP_JOINTGROUP_TEMPLATE_BASE) || !defined(dODECPP_JOINT_TEMPLATE_BASE) +#error All the odecpp template bases must be defined or not defined together +#endif + +#endif // #if defined(dODECPP_WORLD_TEMPLATE_BASE) + + +typedef dWorldTemplate dWorld; +typedef dBodyTemplate dBody; +typedef dJointGroupTemplate dJointGroup; +typedef dJointTemplate dJoint; +typedef dBallJointTemplate dBallJoint; +typedef dHingeJointTemplate dHingeJoint; +typedef dSliderJointTemplate dSliderJoint; +typedef dUniversalJointTemplate dUniversalJoint; +typedef dHinge2JointTemplate dHinge2Joint; +typedef dPRJointTemplate dPRJoint; +typedef dPUJointTemplate dPUJoint; +typedef dPistonJointTemplate dPistonJoint; +typedef dFixedJointTemplate dFixedJoint; +typedef dContactJointTemplate dContactJoint; +typedef dNullJointTemplate dNullJoint; +typedef dAMotorJointTemplate dAMotorJoint; +typedef dLMotorJointTemplate dLMotorJoint; + + +#endif +#endif + +// Local variables: +// mode:c++ +// c-basic-offset:2 +// End: diff --git a/libs/ode-0.16.1/include/ode/odecpp_collision.h b/libs/ode-0.16.1/include/ode/odecpp_collision.h new file mode 100644 index 0000000..f2c7725 --- /dev/null +++ b/libs/ode-0.16.1/include/ode/odecpp_collision.h @@ -0,0 +1,467 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +/* C++ interface for new collision API */ + + +#ifndef _ODE_ODECPP_COLLISION_H_ +#define _ODE_ODECPP_COLLISION_H_ +#ifdef __cplusplus + +//#include + +//namespace ode { + +class dGeom { + // intentionally undefined, don't use these + dGeom (dGeom &); + void operator= (dGeom &); + +protected: + dGeomID _id; + + dGeom() + { _id = 0; } +public: + ~dGeom() + { if (_id) dGeomDestroy (_id); } + + dGeomID id() const + { return _id; } + operator dGeomID() const + { return _id; } + + void destroy() { + if (_id) dGeomDestroy (_id); + _id = 0; + } + + int getClass() const + { return dGeomGetClass (_id); } + + dSpaceID getSpace() const + { return dGeomGetSpace (_id); } + + void setData (void *data) + { dGeomSetData (_id,data); } + void *getData() const + { return dGeomGetData (_id); } + + void setBody (dBodyID b) + { dGeomSetBody (_id,b); } + dBodyID getBody() const + { return dGeomGetBody (_id); } + + void setPosition (dReal x, dReal y, dReal z) + { dGeomSetPosition (_id,x,y,z); } + const dReal * getPosition() const + { return dGeomGetPosition (_id); } + + void setRotation (const dMatrix3 R) + { dGeomSetRotation (_id,R); } + const dReal * getRotation() const + { return dGeomGetRotation (_id); } + + void setQuaternion (const dQuaternion quat) + { dGeomSetQuaternion (_id,quat); } + void getQuaternion (dQuaternion quat) const + { dGeomGetQuaternion (_id,quat); } + + void getAABB (dReal aabb[6]) const + { dGeomGetAABB (_id, aabb); } + + int isSpace() + { return dGeomIsSpace (_id); } + + void setCategoryBits (unsigned long bits) + { dGeomSetCategoryBits (_id, bits); } + void setCollideBits (unsigned long bits) + { dGeomSetCollideBits (_id, bits); } + unsigned long getCategoryBits() + { return dGeomGetCategoryBits (_id); } + unsigned long getCollideBits() + { return dGeomGetCollideBits (_id); } + + void enable() + { dGeomEnable (_id); } + void disable() + { dGeomDisable (_id); } + int isEnabled() + { return dGeomIsEnabled (_id); } + + void getRelPointPos (dReal px, dReal py, dReal pz, dVector3 result) const + { dGeomGetRelPointPos (_id, px, py, pz, result); } + void getRelPointPos (const dVector3 p, dVector3 result) const + { getRelPointPos (p[0], p[1], p[2], result); } + + void getPosRelPoint (dReal px, dReal py, dReal pz, dVector3 result) const + { dGeomGetPosRelPoint (_id, px, py, pz, result); } + void getPosRelPoint (const dVector3 p, dVector3 result) const + { getPosRelPoint (p[0], p[1], p[2], result); } + + void vectorToWorld (dReal px, dReal py, dReal pz, dVector3 result) const + { dGeomVectorToWorld (_id, px, py, pz, result); } + void vectorToWorld (const dVector3 p, dVector3 result) const + { vectorToWorld (p[0], p[1], p[2], result); } + + void vectorFromWorld (dReal px, dReal py, dReal pz, dVector3 result) const + { dGeomVectorFromWorld (_id, px, py, pz, result); } + void vectorFromWorld (const dVector3 p, dVector3 result) const + { vectorFromWorld (p[0], p[1], p[2], result); } + + void collide2 (dGeomID g, void *data, dNearCallback *callback) + { dSpaceCollide2 (_id,g,data,callback); } +}; + + +class dSpace : public dGeom { + // intentionally undefined, don't use these + dSpace (dSpace &); + void operator= (dSpace &); + +protected: + // the default constructor is protected so that you + // can't instance this class. you must instance one + // of its subclasses instead. + dSpace () { _id = 0; } + +public: + dSpaceID id() const + { return (dSpaceID) _id; } + operator dSpaceID() const + { return (dSpaceID) _id; } + + void setCleanup (int mode) + { dSpaceSetCleanup (id(), mode); } + int getCleanup() + { return dSpaceGetCleanup (id()); } + + void add (dGeomID x) + { dSpaceAdd (id(), x); } + void remove (dGeomID x) + { dSpaceRemove (id(), x); } + int query (dGeomID x) + { return dSpaceQuery (id(),x); } + + int getNumGeoms() + { return dSpaceGetNumGeoms (id()); } + dGeomID getGeom (int i) + { return dSpaceGetGeom (id(),i); } + + void collide (void *data, dNearCallback *callback) + { dSpaceCollide (id(),data,callback); } +}; + + +class dSimpleSpace : public dSpace { + // intentionally undefined, don't use these + dSimpleSpace (dSimpleSpace &); + void operator= (dSimpleSpace &); + +public: + dSimpleSpace () + { _id = (dGeomID) dSimpleSpaceCreate (0); } + dSimpleSpace (dSpace &space) + { _id = (dGeomID) dSimpleSpaceCreate (space.id()); } + dSimpleSpace (dSpaceID space) + { _id = (dGeomID) dSimpleSpaceCreate (space); } +}; + + +class dHashSpace : public dSpace { + // intentionally undefined, don't use these + dHashSpace (dHashSpace &); + void operator= (dHashSpace &); + +public: + dHashSpace () + { _id = (dGeomID) dHashSpaceCreate (0); } + dHashSpace (dSpace &space) + { _id = (dGeomID) dHashSpaceCreate (space.id()); } + dHashSpace (dSpaceID space) + { _id = (dGeomID) dHashSpaceCreate (space); } + + void setLevels (int minlevel, int maxlevel) + { dHashSpaceSetLevels (id(),minlevel,maxlevel); } +}; + + +class dQuadTreeSpace : public dSpace { + // intentionally undefined, don't use these + dQuadTreeSpace (dQuadTreeSpace &); + void operator= (dQuadTreeSpace &); + +public: + dQuadTreeSpace (const dVector3 center, const dVector3 extents, int depth) + { _id = (dGeomID) dQuadTreeSpaceCreate (0,center,extents,depth); } + dQuadTreeSpace (dSpace &space, const dVector3 center, const dVector3 extents, int depth) + { _id = (dGeomID) dQuadTreeSpaceCreate (space.id(),center,extents,depth); } + dQuadTreeSpace (dSpaceID space, const dVector3 center, const dVector3 extents, int depth) + { _id = (dGeomID) dQuadTreeSpaceCreate (space,center,extents,depth); } +}; + + +class dSphere : public dGeom { + // intentionally undefined, don't use these + dSphere (dSphere &); + void operator= (dSphere &); + +public: + dSphere () { } + dSphere (dReal radius) + { _id = dCreateSphere (0, radius); } + dSphere (dSpace &space, dReal radius) + { _id = dCreateSphere (space.id(), radius); } + dSphere (dSpaceID space, dReal radius) + { _id = dCreateSphere (space, radius); } + + void create (dSpaceID space, dReal radius) { + if (_id) dGeomDestroy (_id); + _id = dCreateSphere (space, radius); + } + + void setRadius (dReal radius) + { dGeomSphereSetRadius (_id, radius); } + dReal getRadius() const + { return dGeomSphereGetRadius (_id); } +}; + + +class dBox : public dGeom { + // intentionally undefined, don't use these + dBox (dBox &); + void operator= (dBox &); + +public: + dBox () { } + dBox (dReal lx, dReal ly, dReal lz) + { _id = dCreateBox (0,lx,ly,lz); } + dBox (dSpace &space, dReal lx, dReal ly, dReal lz) + { _id = dCreateBox (space,lx,ly,lz); } + dBox (dSpaceID space, dReal lx, dReal ly, dReal lz) + { _id = dCreateBox (space,lx,ly,lz); } + + void create (dSpaceID space, dReal lx, dReal ly, dReal lz) { + if (_id) dGeomDestroy (_id); + _id = dCreateBox (space,lx,ly,lz); + } + + void setLengths (dReal lx, dReal ly, dReal lz) + { dGeomBoxSetLengths (_id, lx, ly, lz); } + void getLengths (dVector3 result) const + { dGeomBoxGetLengths (_id,result); } +}; + + +class dPlane : public dGeom { + // intentionally undefined, don't use these + dPlane (dPlane &); + void operator= (dPlane &); + +public: + dPlane() { } + dPlane (dReal a, dReal b, dReal c, dReal d) + { _id = dCreatePlane (0,a,b,c,d); } + dPlane (dSpace &space, dReal a, dReal b, dReal c, dReal d) + { _id = dCreatePlane (space.id(),a,b,c,d); } + dPlane (dSpaceID space, dReal a, dReal b, dReal c, dReal d) + { _id = dCreatePlane (space,a,b,c,d); } + + void create (dSpaceID space, dReal a, dReal b, dReal c, dReal d) { + if (_id) dGeomDestroy (_id); + _id = dCreatePlane (space,a,b,c,d); + } + + void setParams (dReal a, dReal b, dReal c, dReal d) + { dGeomPlaneSetParams (_id, a, b, c, d); } + void getParams (dVector4 result) const + { dGeomPlaneGetParams (_id,result); } +}; + + +class dCapsule : public dGeom { + // intentionally undefined, don't use these + dCapsule (dCapsule &); + void operator= (dCapsule &); + +public: + dCapsule() { } + dCapsule (dReal radius, dReal length) + { _id = dCreateCapsule (0,radius,length); } + dCapsule (dSpace &space, dReal radius, dReal length) + { _id = dCreateCapsule (space.id(),radius,length); } + dCapsule (dSpaceID space, dReal radius, dReal length) + { _id = dCreateCapsule (space,radius,length); } + + void create (dSpaceID space, dReal radius, dReal length) { + if (_id) dGeomDestroy (_id); + _id = dCreateCapsule (space,radius,length); + } + + void setParams (dReal radius, dReal length) + { dGeomCapsuleSetParams (_id, radius, length); } + void getParams (dReal *radius, dReal *length) const + { dGeomCapsuleGetParams (_id,radius,length); } +}; + + +class dCylinder : public dGeom { + // intentionally undefined, don't use these + dCylinder (dCylinder &); + void operator= (dCylinder &); + +public: + dCylinder() { } + dCylinder (dReal radius, dReal length) + { _id = dCreateCylinder (0,radius,length); } + dCylinder (dSpace &space, dReal radius, dReal length) + { _id = dCreateCylinder (space.id(),radius,length); } + dCylinder (dSpaceID space, dReal radius, dReal length) + { _id = dCreateCylinder (space,radius,length); } + + void create (dSpaceID space, dReal radius, dReal length) { + if (_id) dGeomDestroy (_id); + _id = dCreateCylinder (space,radius,length); + } + + void setParams (dReal radius, dReal length) + { dGeomCylinderSetParams (_id, radius, length); } + void getParams (dReal *radius, dReal *length) const + { dGeomCylinderGetParams (_id,radius,length); } +}; + + +class dRay : public dGeom { + // intentionally undefined, don't use these + dRay (dRay &); + void operator= (dRay &); + +public: + dRay() { } + dRay (dReal length) + { _id = dCreateRay (0,length); } + dRay (dSpace &space, dReal length) + { _id = dCreateRay (space.id(),length); } + dRay (dSpaceID space, dReal length) + { _id = dCreateRay (space,length); } + + void create (dSpaceID space, dReal length) { + if (_id) dGeomDestroy (_id); + _id = dCreateRay (space,length); + } + + void setLength (dReal length) + { dGeomRaySetLength (_id, length); } + dReal getLength() + { return dGeomRayGetLength (_id); } + + void set (dReal px, dReal py, dReal pz, dReal dx, dReal dy, dReal dz) + { dGeomRaySet (_id, px, py, pz, dx, dy, dz); } + void get (dVector3 start, dVector3 dir) + { dGeomRayGet (_id, start, dir); } + +#ifdef WIN32 +#pragma warning( push ) +#pragma warning( disable : 4996 ) +#else +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wdeprecated-declarations" +#endif + ODE_API_DEPRECATED + void setParams (int firstContact, int backfaceCull) + { dGeomRaySetParams (_id, firstContact, backfaceCull); } + + ODE_API_DEPRECATED + void getParams (int *firstContact, int *backfaceCull) + { dGeomRayGetParams (_id, firstContact, backfaceCull); } +#ifdef WIN32 +#pragma warning( pop ) +#else +#pragma GCC diagnostic pop +#endif + void setBackfaceCull (int backfaceCull) + { dGeomRaySetBackfaceCull (_id, backfaceCull); } + int getBackfaceCull() + { return dGeomRayGetBackfaceCull (_id); } + + void setFirstContact (int firstContact) + { dGeomRaySetFirstContact (_id, firstContact); } + int getFirstContact() + { return dGeomRayGetFirstContact (_id); } + + void setClosestHit (int closestHit) + { dGeomRaySetClosestHit (_id, closestHit); } + int getClosestHit() + { return dGeomRayGetClosestHit (_id); } +}; + +#ifdef WIN32 +#pragma warning( push ) +#pragma warning( disable : 4996 ) +#else +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wdeprecated-declarations" +#endif + +class ODE_API_DEPRECATED dGeomTransform : public dGeom { + // intentionally undefined, don't use these + dGeomTransform (dGeomTransform &); + void operator= (dGeomTransform &); + +public: + dGeomTransform() { } + dGeomTransform (dSpace &space) + { _id = dCreateGeomTransform (space.id()); } + dGeomTransform (dSpaceID space) + { _id = dCreateGeomTransform (space); } + + void create (dSpaceID space=0) { + if (_id) dGeomDestroy (_id); + _id = dCreateGeomTransform (space); + } + + void setGeom (dGeomID geom) + { dGeomTransformSetGeom (_id, geom); } + dGeomID getGeom() const + { return dGeomTransformGetGeom (_id); } + + void setCleanup (int mode) + { dGeomTransformSetCleanup (_id,mode); } + int getCleanup () + { return dGeomTransformGetCleanup (_id); } + + void setInfo (int mode) + { dGeomTransformSetInfo (_id,mode); } + int getInfo() + { return dGeomTransformGetInfo (_id); } +}; + +#ifdef WIN32 +#pragma warning( pop ) +#else +#pragma GCC diagnostic pop +#endif + +//} + +#endif +#endif diff --git a/libs/ode-0.16.1/include/ode/odeinit.h b/libs/ode-0.16.1/include/ode/odeinit.h new file mode 100644 index 0000000..645ca42 --- /dev/null +++ b/libs/ode-0.16.1/include/ode/odeinit.h @@ -0,0 +1,236 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +/* Library initialization/finalization functions. */ + +#ifndef _ODE_ODEINIT_H_ +#define _ODE_ODEINIT_H_ + +#include + + +#ifdef __cplusplus +extern "C" { +#endif + + +/* ************************************************************************ */ +/* Library initialization */ + +/** + * @defgroup init Library Initialization + * + * Library initialization functions prepare ODE internal data structures for use + * and release allocated resources after ODE is not needed any more. + */ + + +/** + * @brief Library initialization flags. + * + * These flags define ODE library initialization options. + * + * @c dInitFlagManualThreadCleanup indicates that resources allocated in TLS for threads + * using ODE are to be cleared by library client with explicit call to @c dCleanupODEAllDataForThread. + * If this flag is not specified the automatic resource tracking algorithm is used. + * + * With automatic resource tracking, On Windows, memory allocated for a thread may + * remain not freed for some time after the thread exits. The resources may be + * released when one of other threads calls @c dAllocateODEDataForThread. Ultimately, + * the resources are released when library is closed with @c dCloseODE. On other + * operating systems resources are always released by the thread itself on its exit + * or on library closure with @c dCloseODE. + * + * With manual thread data cleanup mode every collision space object must be + * explicitly switched to manual cleanup mode with @c dSpaceSetManualCleanup + * after creation. See description of the function for more details. + * + * If @c dInitFlagManualThreadCleanup was not specified during initialization, + * calls to @c dCleanupODEAllDataForThread are not allowed. + * + * @see dInitODE2 + * @see dAllocateODEDataForThread + * @see dSpaceSetManualCleanup + * @see dCloseODE + * @ingroup init + */ +enum dInitODEFlags { + dInitFlagManualThreadCleanup = 0x00000001 /*@< Thread local data is to be cleared explicitly on @c dCleanupODEAllDataForThread function call*/ +}; + +/** + * @brief Initializes ODE library. + * + * @c dInitODE is obsolete. @c dInitODE2 is to be used for library initialization. + * + * A call to @c dInitODE is equal to the following initialization sequence + * @code + * dInitODE2(0); + * dAllocateODEDataForThread(dAllocateMaskAll); + * @endcode + * + * @see dInitODE2 + * @see dAllocateODEDataForThread + * @ingroup init + */ +ODE_API void dInitODE(void); + +/** + * @brief Initializes ODE library. + * @param uiInitFlags Initialization options bitmask + * @return A nonzero if initialization succeeded and zero otherwise. + * + * This function must be called to initialize ODE library before first use. If + * initialization succeeds the function may not be called again until library is + * closed with a call to @c dCloseODE. + * + * The @a uiInitFlags parameter specifies initialization options to be used. These + * can be combination of zero or more @c dInitODEFlags flags. + * + * @note + * If @c dInitFlagManualThreadCleanup flag is used for initialization, + * @c dSpaceSetManualCleanup must be called to set manual cleanup mode for every + * space object right after creation. Failure to do so may lead to resource leaks. + * + * @see dInitODEFlags + * @see dCloseODE + * @see dSpaceSetManualCleanup + * @ingroup init + */ +ODE_API int dInitODE2(unsigned int uiInitFlags/*=0*/); + + +/** + * @brief ODE data allocation flags. + * + * These flags are used to indicate which data is to be pre-allocated in call to + * @c dAllocateODEDataForThread. + * + * @c dAllocateFlagBasicData tells to allocate the basic data set required for + * normal library operation. This flag is equal to zero and is always implicitly + * included. + * + * @c dAllocateFlagCollisionData tells that collision detection data is to be allocated. + * Collision detection functions may not be called if the data has not be allocated + * in advance. If collision detection is not going to be used, it is not necessary + * to specify this flag. + * + * @c dAllocateMaskAll is a mask that can be used for for allocating all possible + * data in cases when it is not known what exactly features of ODE will be used. + * The mask may not be used in combination with other flags. It is guaranteed to + * include all the current and future legal allocation flags. However, mature + * applications should use explicit flags they need rather than allocating everything. + * + * @see dAllocateODEDataForThread + * @ingroup init + */ +enum dAllocateODEDataFlags { + dAllocateFlagBasicData = 0, /*@< Allocate basic data required for library to operate*/ + + dAllocateFlagCollisionData = 0x00000001, /*@< Allocate data for collision detection*/ + + dAllocateMaskAll = ~0 /*@< Allocate all the possible data that is currently defined or will be defined in the future.*/ +}; + +/** + * @brief Allocate thread local data to allow the thread calling ODE. + * @param uiAllocateFlags Allocation options bitmask. + * @return A nonzero if allocation succeeded and zero otherwise. + * + * The function is required to be called for every thread that is going to use + * ODE. This function allocates the data that is required for accessing ODE from + * current thread along with optional data required for particular ODE subsystems. + * + * @a uiAllocateFlags parameter can contain zero or more flags from @c dAllocateODEDataFlags + * enumerated type. Multiple calls with different allocation flags are allowed. + * The flags that are already allocated are ignored in subsequent calls. If zero + * is passed as the parameter, it means to only allocate the set of most important + * data the library can not operate without. + * + * If the function returns failure status it means that none of the requested + * data has been allocated. The client may retry allocation attempt with the same + * flags when more system resources are available. + * + * @see dAllocateODEDataFlags + * @see dCleanupODEAllDataForThread + * @ingroup init + */ +ODE_API int dAllocateODEDataForThread(unsigned int uiAllocateFlags); + +/** + * @brief Free thread local data that was allocated for current thread. + * + * If library was initialized with @c dInitFlagManualThreadCleanup flag the function + * is required to be called on exit of every thread that was calling @c dAllocateODEDataForThread. + * Failure to call @c dCleanupODEAllDataForThread may result in some resources remaining + * not freed until program exit. The function may also be called when ODE is still + * being used to release resources allocated for all the current subsystems and + * possibly proceed with data pre-allocation for other subsystems. + * + * The function can safely be called several times in a row. The function can be + * called without prior invocation of @c dAllocateODEDataForThread. The function + * may not be called before ODE is initialized with @c dInitODE2 or after library + * has been closed with @c dCloseODE. A call to @c dCloseODE implicitly releases + * all the thread local resources that might be allocated for all the threads that + * were using ODE. + * + * If library was initialized without @c dInitFlagManualThreadCleanup flag + * @c dCleanupODEAllDataForThread must not be called. + * + * @see dAllocateODEDataForThread + * @see dInitODE2 + * @see dCloseODE + * @ingroup init + */ +ODE_API void dCleanupODEAllDataForThread(); + + +/** + * @brief Close ODE after it is not needed any more. + * + * The function is required to be called when program does not need ODE features any more. + * The call to @c dCloseODE releases all the resources allocated for library + * including all the thread local data that might be allocated for all the threads + * that were using ODE. + * + * @c dCloseODE is a paired function for @c dInitODE2 and must only be called + * after successful library initialization. + * + * @note Important! + * Make sure that all the threads that were using ODE have already terminated + * before calling @c dCloseODE. In particular it is not allowed to call + * @c dCleanupODEAllDataForThread after @c dCloseODE. + * + * @see dInitODE2 + * @see dCleanupODEAllDataForThread + * @ingroup init + */ +ODE_API void dCloseODE(void); + + + +#ifdef __cplusplus +} /* extern "C" */ +#endif + + +#endif /* _ODE_ODEINIT_H_ */ diff --git a/libs/ode-0.16.1/include/ode/odemath.h b/libs/ode-0.16.1/include/ode/odemath.h new file mode 100644 index 0000000..d4461b3 --- /dev/null +++ b/libs/ode-0.16.1/include/ode/odemath.h @@ -0,0 +1,545 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#ifndef _ODE_ODEMATH_H_ +#define _ODE_ODEMATH_H_ + +#include + +/* + * macro to access elements i,j in an NxM matrix A, independent of the + * matrix storage convention. + */ +#define dACCESS33(A,i,j) ((A)[(i)*4+(j)]) + +/* + * Macro to test for valid floating point values + */ +#define dVALIDVEC3(v) (!(dIsNan(v[0]) || dIsNan(v[1]) || dIsNan(v[2]))) +#define dVALIDVEC4(v) (!(dIsNan(v[0]) || dIsNan(v[1]) || dIsNan(v[2]) || dIsNan(v[3]))) +#define dVALIDMAT3(m) (!(dIsNan(m[0]) || dIsNan(m[1]) || dIsNan(m[2]) || dIsNan(m[3]) || dIsNan(m[4]) || dIsNan(m[5]) || dIsNan(m[6]) || dIsNan(m[7]) || dIsNan(m[8]) || dIsNan(m[9]) || dIsNan(m[10]) || dIsNan(m[11]))) +#define dVALIDMAT4(m) (!(dIsNan(m[0]) || dIsNan(m[1]) || dIsNan(m[2]) || dIsNan(m[3]) || dIsNan(m[4]) || dIsNan(m[5]) || dIsNan(m[6]) || dIsNan(m[7]) || dIsNan(m[8]) || dIsNan(m[9]) || dIsNan(m[10]) || dIsNan(m[11]) || dIsNan(m[12]) || dIsNan(m[13]) || dIsNan(m[14]) || dIsNan(m[15]) )) + + +ODE_PURE_INLINE void dZeroVector3(dVector3 res) +{ + res[dV3E_X] = REAL(0.0); + res[dV3E_Y] = REAL(0.0); + res[dV3E_Z] = REAL(0.0); +} + +ODE_PURE_INLINE void dAssignVector3(dVector3 res, dReal x, dReal y, dReal z) +{ + res[dV3E_X] = x; + res[dV3E_Y] = y; + res[dV3E_Z] = z; +} + +ODE_PURE_INLINE void dZeroMatrix3(dMatrix3 res) +{ + res[dM3E_XX] = REAL(0.0); res[dM3E_XY] = REAL(0.0); res[dM3E_XZ] = REAL(0.0); + res[dM3E_YX] = REAL(0.0); res[dM3E_YY] = REAL(0.0); res[dM3E_YZ] = REAL(0.0); + res[dM3E_ZX] = REAL(0.0); res[dM3E_ZY] = REAL(0.0); res[dM3E_ZZ] = REAL(0.0); +} + +ODE_PURE_INLINE void dZeroMatrix4(dMatrix4 res) +{ + res[dM4E_XX] = REAL(0.0); res[dM4E_XY] = REAL(0.0); res[dM4E_XZ] = REAL(0.0); res[dM4E_XO] = REAL(0.0); + res[dM4E_YX] = REAL(0.0); res[dM4E_YY] = REAL(0.0); res[dM4E_YZ] = REAL(0.0); res[dM4E_YO] = REAL(0.0); + res[dM4E_ZX] = REAL(0.0); res[dM4E_ZY] = REAL(0.0); res[dM4E_ZZ] = REAL(0.0); res[dM4E_ZO] = REAL(0.0); + res[dM4E_OX] = REAL(0.0); res[dM4E_OY] = REAL(0.0); res[dM4E_OZ] = REAL(0.0); res[dM4E_OO] = REAL(0.0); +} + +/* Some vector math */ +ODE_PURE_INLINE void dAddVectors3(dReal *res, const dReal *a, const dReal *b) +{ + const dReal res_0 = a[0] + b[0]; + const dReal res_1 = a[1] + b[1]; + const dReal res_2 = a[2] + b[2]; + /* Only assign after all the calculations are over to avoid incurring memory aliasing*/ + res[0] = res_0; res[1] = res_1; res[2] = res_2; +} + +ODE_PURE_INLINE void dSubtractVectors3(dReal *res, const dReal *a, const dReal *b) +{ + const dReal res_0 = a[0] - b[0]; + const dReal res_1 = a[1] - b[1]; + const dReal res_2 = a[2] - b[2]; + /* Only assign after all the calculations are over to avoid incurring memory aliasing*/ + res[0] = res_0; res[1] = res_1; res[2] = res_2; +} + +ODE_PURE_INLINE void dAddVectorScaledVector3(dReal *res, const dReal *a, const dReal *b, dReal b_scale) +{ + const dReal res_0 = a[0] + b_scale * b[0]; + const dReal res_1 = a[1] + b_scale * b[1]; + const dReal res_2 = a[2] + b_scale * b[2]; + /* Only assign after all the calculations are over to avoid incurring memory aliasing*/ + res[0] = res_0; res[1] = res_1; res[2] = res_2; +} + +ODE_PURE_INLINE void dAddScaledVectors3(dReal *res, const dReal *a, const dReal *b, dReal a_scale, dReal b_scale) +{ + const dReal res_0 = a_scale * a[0] + b_scale * b[0]; + const dReal res_1 = a_scale * a[1] + b_scale * b[1]; + const dReal res_2 = a_scale * a[2] + b_scale * b[2]; + /* Only assign after all the calculations are over to avoid incurring memory aliasing*/ + res[0] = res_0; res[1] = res_1; res[2] = res_2; +} + +ODE_PURE_INLINE void dAddThreeScaledVectors3(dReal *res, const dReal *a, const dReal *b, const dReal *c, dReal a_scale, dReal b_scale, dReal c_scale) +{ + const dReal res_0 = a_scale * a[0] + b_scale * b[0] + c_scale * c[0]; + const dReal res_1 = a_scale * a[1] + b_scale * b[1] + c_scale * c[1]; + const dReal res_2 = a_scale * a[2] + b_scale * b[2] + c_scale * c[2]; + /* Only assign after all the calculations are over to avoid incurring memory aliasing*/ + res[0] = res_0; res[1] = res_1; res[2] = res_2; +} + +ODE_PURE_INLINE void dScaleVector3(dReal *res, dReal nScale) +{ + res[0] *= nScale ; + res[1] *= nScale ; + res[2] *= nScale ; +} + +ODE_PURE_INLINE void dNegateVector3(dReal *res) +{ + res[0] = -res[0]; + res[1] = -res[1]; + res[2] = -res[2]; +} + +ODE_PURE_INLINE void dCopyVector3(dReal *res, const dReal *a) +{ + const dReal res_0 = a[0]; + const dReal res_1 = a[1]; + const dReal res_2 = a[2]; + /* Only assign after all the calculations are over to avoid incurring memory aliasing*/ + res[0] = res_0; res[1] = res_1; res[2] = res_2; +} + +ODE_PURE_INLINE void dCopyScaledVector3(dReal *res, const dReal *a, dReal nScale) +{ + const dReal res_0 = a[0] * nScale; + const dReal res_1 = a[1] * nScale; + const dReal res_2 = a[2] * nScale; + /* Only assign after all the calculations are over to avoid incurring memory aliasing*/ + res[0] = res_0; res[1] = res_1; res[2] = res_2; +} + +ODE_PURE_INLINE void dCopyNegatedVector3(dReal *res, const dReal *a) +{ + const dReal res_0 = -a[0]; + const dReal res_1 = -a[1]; + const dReal res_2 = -a[2]; + /* Only assign after all the calculations are over to avoid incurring memory aliasing*/ + res[0] = res_0; res[1] = res_1; res[2] = res_2; +} + +ODE_PURE_INLINE void dCopyVector4(dReal *res, const dReal *a) +{ + const dReal res_0 = a[0]; + const dReal res_1 = a[1]; + const dReal res_2 = a[2]; + const dReal res_3 = a[3]; + /* Only assign after all the calculations are over to avoid incurring memory aliasing*/ + res[0] = res_0; res[1] = res_1; res[2] = res_2; res[3] = res_3; +} + +ODE_PURE_INLINE void dCopyMatrix4x4(dReal *res, const dReal *a) +{ + dCopyVector4(res + 0, a + 0); + dCopyVector4(res + 4, a + 4); + dCopyVector4(res + 8, a + 8); +} + +ODE_PURE_INLINE void dCopyMatrix4x3(dReal *res, const dReal *a) +{ + dCopyVector3(res + 0, a + 0); + dCopyVector3(res + 4, a + 4); + dCopyVector3(res + 8, a + 8); +} + +ODE_PURE_INLINE void dGetMatrixColumn3(dReal *res, const dReal *a, unsigned n) +{ + const dReal res_0 = a[n + 0]; + const dReal res_1 = a[n + 4]; + const dReal res_2 = a[n + 8]; + /* Only assign after all the calculations are over to avoid incurring memory aliasing*/ + res[0] = res_0; res[1] = res_1; res[2] = res_2; +} + +ODE_PURE_INLINE dReal dCalcVectorLength3(const dReal *a) +{ + return dSqrt(a[0] * a[0] + a[1] * a[1] + a[2] * a[2]); +} + +ODE_PURE_INLINE dReal dCalcVectorLengthSquare3(const dReal *a) +{ + return (a[0] * a[0] + a[1] * a[1] + a[2] * a[2]); +} + +ODE_PURE_INLINE dReal dCalcPointDepth3(const dReal *test_p, const dReal *plane_p, const dReal *plane_n) +{ + return (plane_p[0] - test_p[0]) * plane_n[0] + (plane_p[1] - test_p[1]) * plane_n[1] + (plane_p[2] - test_p[2]) * plane_n[2]; +} + + +/* +* 3-way dot product. _dCalcVectorDot3 means that elements of `a' and `b' are spaced +* step_a and step_b indexes apart respectively. dCalcVectorDot3() means dDot311. +*/ + +ODE_PURE_INLINE dReal _dCalcVectorDot3(const dReal *a, const dReal *b, unsigned step_a, unsigned step_b) +{ + return a[0] * b[0] + a[step_a] * b[step_b] + a[2 * step_a] * b[2 * step_b]; +} + + +ODE_PURE_INLINE dReal dCalcVectorDot3 (const dReal *a, const dReal *b) { return _dCalcVectorDot3(a,b,1,1); } +ODE_PURE_INLINE dReal dCalcVectorDot3_13 (const dReal *a, const dReal *b) { return _dCalcVectorDot3(a,b,1,3); } +ODE_PURE_INLINE dReal dCalcVectorDot3_31 (const dReal *a, const dReal *b) { return _dCalcVectorDot3(a,b,3,1); } +ODE_PURE_INLINE dReal dCalcVectorDot3_33 (const dReal *a, const dReal *b) { return _dCalcVectorDot3(a,b,3,3); } +ODE_PURE_INLINE dReal dCalcVectorDot3_14 (const dReal *a, const dReal *b) { return _dCalcVectorDot3(a,b,1,4); } +ODE_PURE_INLINE dReal dCalcVectorDot3_41 (const dReal *a, const dReal *b) { return _dCalcVectorDot3(a,b,4,1); } +ODE_PURE_INLINE dReal dCalcVectorDot3_44 (const dReal *a, const dReal *b) { return _dCalcVectorDot3(a,b,4,4); } + + +/* + * cross product, set res = a x b. _dCalcVectorCross3 means that elements of `res', `a' + * and `b' are spaced step_res, step_a and step_b indexes apart respectively. + * dCalcVectorCross3() means dCross3111. + */ + +ODE_PURE_INLINE void _dCalcVectorCross3(dReal *res, const dReal *a, const dReal *b, unsigned step_res, unsigned step_a, unsigned step_b) +{ + const dReal res_0 = a[ step_a]*b[2*step_b] - a[2*step_a]*b[ step_b]; + const dReal res_1 = a[2*step_a]*b[ 0] - a[ 0]*b[2*step_b]; + const dReal res_2 = a[ 0]*b[ step_b] - a[ step_a]*b[ 0]; + /* Only assign after all the calculations are over to avoid incurring memory aliasing*/ + res[ 0] = res_0; + res[ step_res] = res_1; + res[2*step_res] = res_2; +} + +ODE_PURE_INLINE void dCalcVectorCross3 (dReal *res, const dReal *a, const dReal *b) { _dCalcVectorCross3(res, a, b, 1, 1, 1); } +ODE_PURE_INLINE void dCalcVectorCross3_114(dReal *res, const dReal *a, const dReal *b) { _dCalcVectorCross3(res, a, b, 1, 1, 4); } +ODE_PURE_INLINE void dCalcVectorCross3_141(dReal *res, const dReal *a, const dReal *b) { _dCalcVectorCross3(res, a, b, 1, 4, 1); } +ODE_PURE_INLINE void dCalcVectorCross3_144(dReal *res, const dReal *a, const dReal *b) { _dCalcVectorCross3(res, a, b, 1, 4, 4); } +ODE_PURE_INLINE void dCalcVectorCross3_411(dReal *res, const dReal *a, const dReal *b) { _dCalcVectorCross3(res, a, b, 4, 1, 1); } +ODE_PURE_INLINE void dCalcVectorCross3_414(dReal *res, const dReal *a, const dReal *b) { _dCalcVectorCross3(res, a, b, 4, 1, 4); } +ODE_PURE_INLINE void dCalcVectorCross3_441(dReal *res, const dReal *a, const dReal *b) { _dCalcVectorCross3(res, a, b, 4, 4, 1); } +ODE_PURE_INLINE void dCalcVectorCross3_444(dReal *res, const dReal *a, const dReal *b) { _dCalcVectorCross3(res, a, b, 4, 4, 4); } + +ODE_PURE_INLINE void dAddVectorCross3(dReal *res, const dReal *a, const dReal *b) +{ + dReal tmp[3]; + dCalcVectorCross3(tmp, a, b); + dAddVectors3(res, res, tmp); +} + +ODE_PURE_INLINE void dSubtractVectorCross3(dReal *res, const dReal *a, const dReal *b) +{ + dReal tmp[3]; + dCalcVectorCross3(tmp, a, b); + dSubtractVectors3(res, res, tmp); +} + + +/* + * set a 3x3 submatrix of A to a matrix such that submatrix(A)*b = a x b. + * A is stored by rows, and has `skip' elements per row. the matrix is + * assumed to be already zero, so this does not write zero elements! + * if (plus,minus) is (+,-) then a positive version will be written. + * if (plus,minus) is (-,+) then a negative version will be written. + */ + +ODE_PURE_INLINE void dSetCrossMatrixPlus(dReal *res, const dReal *a, unsigned skip) +{ + const dReal a_0 = a[0], a_1 = a[1], a_2 = a[2]; + res[1] = -a_2; + res[2] = +a_1; + res[skip+0] = +a_2; + res[skip+2] = -a_0; + res[2*skip+0] = -a_1; + res[2*skip+1] = +a_0; +} + +ODE_PURE_INLINE void dSetCrossMatrixMinus(dReal *res, const dReal *a, unsigned skip) +{ + const dReal a_0 = a[0], a_1 = a[1], a_2 = a[2]; + res[1] = +a_2; + res[2] = -a_1; + res[skip+0] = -a_2; + res[skip+2] = +a_0; + res[2*skip+0] = +a_1; + res[2*skip+1] = -a_0; +} + + +/* + * compute the distance between two 3D-vectors + */ + +ODE_PURE_INLINE dReal dCalcPointsDistance3(const dReal *a, const dReal *b) +{ + dReal res; + dReal tmp[3]; + dSubtractVectors3(tmp, a, b); + res = dCalcVectorLength3(tmp); + return res; +} + +/* + * special case matrix multiplication, with operator selection + */ + +ODE_PURE_INLINE void dMultiplyHelper0_331(dReal *res, const dReal *a, const dReal *b) +{ + const dReal res_0 = dCalcVectorDot3(a, b); + const dReal res_1 = dCalcVectorDot3(a + 4, b); + const dReal res_2 = dCalcVectorDot3(a + 8, b); + /* Only assign after all the calculations are over to avoid incurring memory aliasing*/ + res[0] = res_0; res[1] = res_1; res[2] = res_2; +} + +ODE_PURE_INLINE void dMultiplyHelper1_331(dReal *res, const dReal *a, const dReal *b) +{ + const dReal res_0 = dCalcVectorDot3_41(a, b); + const dReal res_1 = dCalcVectorDot3_41(a + 1, b); + const dReal res_2 = dCalcVectorDot3_41(a + 2, b); + /* Only assign after all the calculations are over to avoid incurring memory aliasing*/ + res[0] = res_0; res[1] = res_1; res[2] = res_2; +} + +ODE_PURE_INLINE void dMultiplyHelper0_133(dReal *res, const dReal *a, const dReal *b) +{ + dMultiplyHelper1_331(res, b, a); +} + +ODE_PURE_INLINE void dMultiplyHelper1_133(dReal *res, const dReal *a, const dReal *b) +{ + const dReal res_0 = dCalcVectorDot3_44(a, b); + const dReal res_1 = dCalcVectorDot3_44(a + 1, b); + const dReal res_2 = dCalcVectorDot3_44(a + 2, b); + /* Only assign after all the calculations are over to avoid incurring memory aliasing*/ + res[0] = res_0; res[1] = res_1; res[2] = res_2; +} + +/* +Note: NEVER call any of these functions/macros with the same variable for A and C, +it is not equivalent to A*=B. +*/ + +ODE_PURE_INLINE void dMultiply0_331(dReal *res, const dReal *a, const dReal *b) +{ + dMultiplyHelper0_331(res, a, b); +} + +ODE_PURE_INLINE void dMultiply1_331(dReal *res, const dReal *a, const dReal *b) +{ + dMultiplyHelper1_331(res, a, b); +} + +ODE_PURE_INLINE void dMultiply0_133(dReal *res, const dReal *a, const dReal *b) +{ + dMultiplyHelper0_133(res, a, b); +} + +ODE_PURE_INLINE void dMultiply0_333(dReal *res, const dReal *a, const dReal *b) +{ + dMultiplyHelper0_133(res + 0, a + 0, b); + dMultiplyHelper0_133(res + 4, a + 4, b); + dMultiplyHelper0_133(res + 8, a + 8, b); +} + +ODE_PURE_INLINE void dMultiply1_333(dReal *res, const dReal *a, const dReal *b) +{ + dMultiplyHelper1_133(res + 0, b, a + 0); + dMultiplyHelper1_133(res + 4, b, a + 1); + dMultiplyHelper1_133(res + 8, b, a + 2); +} + +ODE_PURE_INLINE void dMultiply2_333(dReal *res, const dReal *a, const dReal *b) +{ + dMultiplyHelper0_331(res + 0, b, a + 0); + dMultiplyHelper0_331(res + 4, b, a + 4); + dMultiplyHelper0_331(res + 8, b, a + 8); +} + +ODE_PURE_INLINE void dMultiplyAdd0_331(dReal *res, const dReal *a, const dReal *b) +{ + dReal tmp[3]; + dMultiplyHelper0_331(tmp, a, b); + dAddVectors3(res, res, tmp); +} + +ODE_PURE_INLINE void dMultiplyAdd1_331(dReal *res, const dReal *a, const dReal *b) +{ + dReal tmp[3]; + dMultiplyHelper1_331(tmp, a, b); + dAddVectors3(res, res, tmp); +} + +ODE_PURE_INLINE void dMultiplyAdd0_133(dReal *res, const dReal *a, const dReal *b) +{ + dReal tmp[3]; + dMultiplyHelper0_133(tmp, a, b); + dAddVectors3(res, res, tmp); +} + +ODE_PURE_INLINE void dMultiplyAdd0_333(dReal *res, const dReal *a, const dReal *b) +{ + dReal tmp[3]; + dMultiplyHelper0_133(tmp, a + 0, b); + dAddVectors3(res+ 0, res + 0, tmp); + dMultiplyHelper0_133(tmp, a + 4, b); + dAddVectors3(res + 4, res + 4, tmp); + dMultiplyHelper0_133(tmp, a + 8, b); + dAddVectors3(res + 8, res + 8, tmp); +} + +ODE_PURE_INLINE void dMultiplyAdd1_333(dReal *res, const dReal *a, const dReal *b) +{ + dReal tmp[3]; + dMultiplyHelper1_133(tmp, b, a + 0); + dAddVectors3(res + 0, res + 0, tmp); + dMultiplyHelper1_133(tmp, b, a + 1); + dAddVectors3(res + 4, res + 4, tmp); + dMultiplyHelper1_133(tmp, b, a + 2); + dAddVectors3(res + 8, res + 8, tmp); +} + +ODE_PURE_INLINE void dMultiplyAdd2_333(dReal *res, const dReal *a, const dReal *b) +{ + dReal tmp[3]; + dMultiplyHelper0_331(tmp, b, a + 0); + dAddVectors3(res + 0, res + 0, tmp); + dMultiplyHelper0_331(tmp, b, a + 4); + dAddVectors3(res + 4, res + 4, tmp); + dMultiplyHelper0_331(tmp, b, a + 8); + dAddVectors3(res + 8, res + 8, tmp); +} + +ODE_PURE_INLINE dReal dCalcMatrix3Det( const dReal* mat ) +{ + dReal det; + + det = mat[0] * ( mat[5]*mat[10] - mat[9]*mat[6] ) + - mat[1] * ( mat[4]*mat[10] - mat[8]*mat[6] ) + + mat[2] * ( mat[4]*mat[9] - mat[8]*mat[5] ); + + return( det ); +} + +/** + Closed form matrix inversion, copied from + collision_util.h for use in the stepper. + + Returns the determinant. + returns 0 and does nothing + if the matrix is singular. +*/ +ODE_PURE_INLINE dReal dInvertMatrix3(dReal *dst, const dReal *ma) +{ + dReal det; + dReal detRecip; + + det = dCalcMatrix3Det( ma ); + + + /* Setting an arbitrary non-zero threshold + for the determinant doesn't do anyone + any favors. The condition number is the + important thing. If all the eigen-values + of the matrix are small, so is the + determinant, but it can still be well + conditioned. + A single extremely large eigen-value could + push the determinant over threshold, but + produce a very unstable result if the other + eigen-values are small. So we just say that + the determinant must be non-zero and trust the + caller to provide well-conditioned matrices. + */ + if ( det == 0 ) + { + return 0; + } + + detRecip = dRecip(det); + + dst[0] = ( ma[5]*ma[10] - ma[6]*ma[9] ) * detRecip; + dst[1] = ( ma[9]*ma[2] - ma[1]*ma[10] ) * detRecip; + dst[2] = ( ma[1]*ma[6] - ma[5]*ma[2] ) * detRecip; + + dst[4] = ( ma[6]*ma[8] - ma[4]*ma[10] ) * detRecip; + dst[5] = ( ma[0]*ma[10] - ma[8]*ma[2] ) * detRecip; + dst[6] = ( ma[4]*ma[2] - ma[0]*ma[6] ) * detRecip; + + dst[8] = ( ma[4]*ma[9] - ma[8]*ma[5] ) * detRecip; + dst[9] = ( ma[8]*ma[1] - ma[0]*ma[9] ) * detRecip; + dst[10] = ( ma[0]*ma[5] - ma[1]*ma[4] ) * detRecip; + + return det; +} + + +/* Include legacy macros here */ +#include + + +#ifdef __cplusplus +extern "C" { +#endif + +/* + * normalize 3x1 and 4x1 vectors (i.e. scale them to unit length) + */ + +/* For DLL export*/ +ODE_API int dSafeNormalize3 (dVector3 a); +ODE_API int dSafeNormalize4 (dVector4 a); +ODE_API void dNormalize3 (dVector3 a); /* Potentially asserts on zero vec*/ +ODE_API void dNormalize4 (dVector4 a); /* Potentially asserts on zero vec*/ + +/* + * given a unit length "normal" vector n, generate vectors p and q vectors + * that are an orthonormal basis for the plane space perpendicular to n. + * i.e. this makes p,q such that n,p,q are all perpendicular to each other. + * q will equal n x p. if n is not unit length then p will be unit length but + * q wont be. + */ + +ODE_API void dPlaneSpace (const dVector3 n, dVector3 p, dVector3 q); +/* Makes sure the matrix is a proper rotation, returns a boolean status */ +ODE_API int dOrthogonalizeR(dMatrix3 m); + + + +#ifdef __cplusplus +} +#endif + + +#endif diff --git a/libs/ode-0.16.1/include/ode/odemath_legacy.h b/libs/ode-0.16.1/include/ode/odemath_legacy.h new file mode 100644 index 0000000..a389588 --- /dev/null +++ b/libs/ode-0.16.1/include/ode/odemath_legacy.h @@ -0,0 +1,162 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#ifndef _ODE_ODEMATH_LEGACY_H_ +#define _ODE_ODEMATH_LEGACY_H_ + + +/* + * These macros are not used any more inside of ODE + * They are kept for backward compatibility with external code that + * might still be using them. + */ + +/* + * General purpose vector operations with other vectors or constants. + */ + +#define dOP(a,op,b,c) do { \ + (a)[0] = ((b)[0]) op ((c)[0]); \ + (a)[1] = ((b)[1]) op ((c)[1]); \ + (a)[2] = ((b)[2]) op ((c)[2]); \ +} while (0) +#define dOPC(a,op,b,c) do { \ + (a)[0] = ((b)[0]) op (c); \ + (a)[1] = ((b)[1]) op (c); \ + (a)[2] = ((b)[2]) op (c); \ +} while (0) +#define dOPE(a,op,b) do {\ + (a)[0] op ((b)[0]); \ + (a)[1] op ((b)[1]); \ + (a)[2] op ((b)[2]); \ +} while (0) +#define dOPEC(a,op,c) do { \ + (a)[0] op (c); \ + (a)[1] op (c); \ + (a)[2] op (c); \ +} while (0) + +/* Define an equation with operators + * For example this function can be used to replace + *
    + * for (int i=0; i<3; ++i)
    + *   a[i] += b[i] + c[i];
    + * 
    + */ +#define dOPE2(a,op1,b,op2,c) do { \ + (a)[0] op1 ((b)[0]) op2 ((c)[0]); \ + (a)[1] op1 ((b)[1]) op2 ((c)[1]); \ + (a)[2] op1 ((b)[2]) op2 ((c)[2]); \ +} while (0) + + +#define dLENGTHSQUARED(a) dCalcVectorLengthSquare3(a) +#define dLENGTH(a) dCalcVectorLength3(a) +#define dDISTANCE(a, b) dCalcPointsDistance3(a, b) + + +#define dDOT(a, b) dCalcVectorDot3(a, b) +#define dDOT13(a, b) dCalcVectorDot3_13(a, b) +#define dDOT31(a, b) dCalcVectorDot3_31(a, b) +#define dDOT33(a, b) dCalcVectorDot3_33(a, b) +#define dDOT14(a, b) dCalcVectorDot3_14(a, b) +#define dDOT41(a, b) dCalcVectorDot3_41(a, b) +#define dDOT44(a, b) dCalcVectorDot3_44(a, b) + + +/* + * cross product, set a = b x c. dCROSSpqr means that elements of `a', `b' + * and `c' are spaced p, q and r indexes apart respectively. + * dCROSS() means dCROSS111. `op' is normally `=', but you can set it to + * +=, -= etc to get other effects. + */ + +#define dCROSS(a,op,b,c) \ + do { \ + (a)[0] op ((b)[1]*(c)[2] - (b)[2]*(c)[1]); \ + (a)[1] op ((b)[2]*(c)[0] - (b)[0]*(c)[2]); \ + (a)[2] op ((b)[0]*(c)[1] - (b)[1]*(c)[0]); \ + } while(0) +#define dCROSSpqr(a,op,b,c,p,q,r) \ + do { \ + (a)[ 0] op ((b)[ q]*(c)[2*r] - (b)[2*q]*(c)[ r]); \ + (a)[ p] op ((b)[2*q]*(c)[ 0] - (b)[ 0]*(c)[2*r]); \ + (a)[2*p] op ((b)[ 0]*(c)[ r] - (b)[ q]*(c)[ 0]); \ + } while(0) +#define dCROSS114(a,op,b,c) dCROSSpqr(a,op,b,c,1,1,4) +#define dCROSS141(a,op,b,c) dCROSSpqr(a,op,b,c,1,4,1) +#define dCROSS144(a,op,b,c) dCROSSpqr(a,op,b,c,1,4,4) +#define dCROSS411(a,op,b,c) dCROSSpqr(a,op,b,c,4,1,1) +#define dCROSS414(a,op,b,c) dCROSSpqr(a,op,b,c,4,1,4) +#define dCROSS441(a,op,b,c) dCROSSpqr(a,op,b,c,4,4,1) +#define dCROSS444(a,op,b,c) dCROSSpqr(a,op,b,c,4,4,4) + + +/* +* set a 3x3 submatrix of A to a matrix such that submatrix(A)*b = a x b. +* A is stored by rows, and has `skip' elements per row. the matrix is +* assumed to be already zero, so this does not write zero elements! +* if (plus,minus) is (+,-) then a positive version will be written. +* if (plus,minus) is (-,+) then a negative version will be written. +*/ + +#define dCROSSMAT(A,a,skip,plus,minus) \ + do { \ + (A)[1] = minus (a)[2]; \ + (A)[2] = plus (a)[1]; \ + (A)[(skip)+0] = plus (a)[2]; \ + (A)[(skip)+2] = minus (a)[0]; \ + (A)[2*(skip)+0] = minus (a)[1]; \ + (A)[2*(skip)+1] = plus (a)[0]; \ + } while(0) + + + + +/* +Note: NEVER call any of these functions/macros with the same variable for A and C, +it is not equivalent to A*=B. +*/ + +#define dMULTIPLY0_331(A, B, C) dMultiply0_331(A, B, C) +#define dMULTIPLY1_331(A, B, C) dMultiply1_331(A, B, C) +#define dMULTIPLY0_133(A, B, C) dMultiply0_133(A, B, C) +#define dMULTIPLY0_333(A, B, C) dMultiply0_333(A, B, C) +#define dMULTIPLY1_333(A, B, C) dMultiply1_333(A, B, C) +#define dMULTIPLY2_333(A, B, C) dMultiply2_333(A, B, C) + +#define dMULTIPLYADD0_331(A, B, C) dMultiplyAdd0_331(A, B, C) +#define dMULTIPLYADD1_331(A, B, C) dMultiplyAdd1_331(A, B, C) +#define dMULTIPLYADD0_133(A, B, C) dMultiplyAdd0_133(A, B, C) +#define dMULTIPLYADD0_333(A, B, C) dMultiplyAdd0_333(A, B, C) +#define dMULTIPLYADD1_333(A, B, C) dMultiplyAdd1_333(A, B, C) +#define dMULTIPLYADD2_333(A, B, C) dMultiplyAdd2_333(A, B, C) + + +/* + * These macros are not used any more inside of ODE + * They are kept for backward compatibility with external code that + * might still be using them. + */ + + +#endif /* #ifndef _ODE_ODEMATH_LEGACY_H_ */ diff --git a/libs/ode-0.16.1/include/ode/precision.h b/libs/ode-0.16.1/include/ode/precision.h new file mode 100644 index 0000000..456fc36 --- /dev/null +++ b/libs/ode-0.16.1/include/ode/precision.h @@ -0,0 +1,16 @@ +#ifndef _ODE_PRECISION_H_ +#define _ODE_PRECISION_H_ + +/* Define dSINGLE for single precision, dDOUBLE for double precision, + * but never both! + */ + +#if defined(dIDESINGLE) +#define dSINGLE +#elif defined(dIDEDOUBLE) +#define dDOUBLE +#else +#define dSINGLE +#endif + +#endif diff --git a/libs/ode-0.16.1/include/ode/precision.h.in b/libs/ode-0.16.1/include/ode/precision.h.in new file mode 100644 index 0000000..47f3c95 --- /dev/null +++ b/libs/ode-0.16.1/include/ode/precision.h.in @@ -0,0 +1,16 @@ +#ifndef _ODE_PRECISION_H_ +#define _ODE_PRECISION_H_ + +/* Define dSINGLE for single precision, dDOUBLE for double precision, + * but never both! + */ + +#if defined(dIDESINGLE) +#define dSINGLE +#elif defined(dIDEDOUBLE) +#define dDOUBLE +#else +#define @ODE_PRECISION@ +#endif + +#endif diff --git a/libs/ode-0.16.1/include/ode/rotation.h b/libs/ode-0.16.1/include/ode/rotation.h new file mode 100644 index 0000000..a72be27 --- /dev/null +++ b/libs/ode-0.16.1/include/ode/rotation.h @@ -0,0 +1,70 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#ifndef _ODE_ROTATION_H_ +#define _ODE_ROTATION_H_ + +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + + +ODE_API void dRSetIdentity (dMatrix3 R); + +ODE_API void dRFromAxisAndAngle (dMatrix3 R, dReal ax, dReal ay, dReal az, + dReal angle); + +ODE_API void dRFromEulerAngles (dMatrix3 R, dReal phi, dReal theta, dReal psi); + +ODE_API void dRFrom2Axes (dMatrix3 R, dReal ax, dReal ay, dReal az, + dReal bx, dReal by, dReal bz); + +ODE_API void dRFromZAxis (dMatrix3 R, dReal ax, dReal ay, dReal az); + +ODE_API void dQSetIdentity (dQuaternion q); + +ODE_API void dQFromAxisAndAngle (dQuaternion q, dReal ax, dReal ay, dReal az, + dReal angle); + +/* Quaternion multiplication, analogous to the matrix multiplication routines. */ +/* qa = rotate by qc, then qb */ +ODE_API void dQMultiply0 (dQuaternion qa, const dQuaternion qb, const dQuaternion qc); +/* qa = rotate by qc, then by inverse of qb */ +ODE_API void dQMultiply1 (dQuaternion qa, const dQuaternion qb, const dQuaternion qc); +/* qa = rotate by inverse of qc, then by qb */ +ODE_API void dQMultiply2 (dQuaternion qa, const dQuaternion qb, const dQuaternion qc); +/* qa = rotate by inverse of qc, then by inverse of qb */ +ODE_API void dQMultiply3 (dQuaternion qa, const dQuaternion qb, const dQuaternion qc); + +ODE_API void dRfromQ (dMatrix3 R, const dQuaternion q); +ODE_API void dQfromR (dQuaternion q, const dMatrix3 R); +ODE_API void dDQfromW (dReal dq[4], const dVector3 w, const dQuaternion q); + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/libs/ode-0.16.1/include/ode/threading.h b/libs/ode-0.16.1/include/ode/threading.h new file mode 100644 index 0000000..9602b8f --- /dev/null +++ b/libs/ode-0.16.1/include/ode/threading.h @@ -0,0 +1,412 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * Threading support header file. * + * Copyright (C) 2011-2019 Oleh Derevenko. All rights reserved. * + * e-mail: odar@eleks.com (change all "a" to "e") * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +/* + * ODE threading support interfaces + */ + + +#ifndef _ODE_THREADING_H_ +#define _ODE_THREADING_H_ + +#include +// Include since time_t is used and it is not available by default in some OSes +#include + + +#ifdef __cplusplus +extern "C" { +#endif + + +struct dxThreadingImplementation; +typedef struct dxThreadingImplementation *dThreadingImplementationID; + +typedef unsigned dmutexindex_t; +struct dxMutexGroup; +typedef struct dxMutexGroup *dMutexGroupID; + + +#define dTHREADING_THREAD_COUNT_UNLIMITED 0U + + + +/** + * @brief Allocates a group of muteces. + * + * The Mutex allocated do not need to support recursive locking. + * + * The Mutex names are provided to aid in debugging and thread state tracking. + * + * @param impl Threading implementation ID + * @param Mutex_count Number of Mutex to create + * @Mutex_names_ptr Pointer to optional Mutex names array to be associated with individual Mutex + * @returns MutexGroup ID or NULL if error occurred. + * + * @ingroup threading + * @see dMutexGroupFreeFunction + * @see dMutexGroupMutexLockFunction + * @see dMutexGroupMutexUnlockFunction + */ +typedef dMutexGroupID dMutexGroupAllocFunction (dThreadingImplementationID impl, dmutexindex_t Mutex_count, const char *const *Mutex_names_ptr/*=NULL*/); + +/** + * @brief Deletes a group of muteces. + * + * @param impl Threading implementation ID + * @param mutex_group Mutex group to deallocate + * + * @ingroup threading + * @see dMutexGroupAllocFunction + * @see dMutexGroupMutexLockFunction + * @see dMutexGroupMutexUnlockFunction + */ +typedef void dMutexGroupFreeFunction (dThreadingImplementationID impl, dMutexGroupID mutex_group); + +/** + * @brief Locks a mutex in a group of muteces. + * + * The function is to block execution until requested mutex can be locked. + * + * Note: Mutex provided may not support recursive locking. Calling this function + * while mutex is already locked by current thread will result in unpredictable behavior. + * + * @param impl Threading implementation ID + * @param mutex_group Mutex group to use for locking + * @param mutex_index The index of mutex to be locked (0..Mutex_count - 1) + * + * @ingroup threading + * @see dMutexGroupAllocFunction + * @see dMutexGroupFreeFunction + * @see dMutexGroupMutexUnlockFunction + */ +typedef void dMutexGroupMutexLockFunction (dThreadingImplementationID impl, dMutexGroupID mutex_group, dmutexindex_t mutex_index); + +/** + * @brief Attempts to lock a mutex in a group of muteces. + * + * The function is to lock the requested mutex if it is unoccupied or + * immediately return failure if mutex is already locked by other thread. + * + * Note: Mutex provided may not support recursive locking. Calling this function + * while mutex is already locked by current thread will result in unpredictable behavior. + * + * @param impl Threading implementation ID + * @param mutex_group Mutex group to use for locking + * @param mutex_index The index of mutex to be locked (0..Mutex_count - 1) + * @returns 1 for success (mutex is locked) and 0 for failure (mutex is not locked) + * + * @ingroup threading + * @see dMutexGroupAllocFunction + * @see dMutexGroupFreeFunction + * @see dMutexGroupMutexLockFunction + * @see dMutexGroupMutexUnlockFunction + */ +/* typedef int dMutexGroupMutexTryLockFunction (dThreadingImplementationID impl, dMutexGroupID mutex_group, dmutexindex_t mutex_index);*/ + +/** + * @brief Unlocks a mutex in a group of muteces. + * + * The function is to unlock the given mutex provided it had been locked before. + * + * @param impl Threading implementation ID + * @param mutex_group Mutex group to use for unlocking + * @param mutex_index The index of mutex to be unlocked (0..Mutex_count - 1) + * + * @ingroup threading + * @see dMutexGroupAllocFunction + * @see dMutexGroupFreeFunction + * @see dMutexGroupMutexLockFunction + */ +typedef void dMutexGroupMutexUnlockFunction (dThreadingImplementationID impl, dMutexGroupID mutex_group, dmutexindex_t mutex_index); + + +struct dxCallReleasee; +typedef struct dxCallReleasee *dCallReleaseeID; + +struct dxCallWait; +typedef struct dxCallWait *dCallWaitID; + +typedef dsizeint ddependencycount_t; +typedef ddiffint ddependencychange_t; +typedef dsizeint dcallindex_t; +typedef int dThreadedCallFunction(void *call_context, dcallindex_t instance_index, + dCallReleaseeID this_releasee); + +typedef struct dxThreadedWaitTime +{ + time_t wait_sec; + unsigned long wait_nsec; + +} dThreadedWaitTime; + + +/** + * @brief Allocates a Wait ID that can be used to wait for a call. + * + * @param impl Threading implementation ID + * @returns Wait ID or NULL if error occurred + * + * @ingroup threading + * @see dThreadedCallWaitResetFunction + * @see dThreadedCallWaitFreeFunction + * @see dThreadedCallPostFunction + * @see dThreadedCallWaitFunction + */ +typedef dCallWaitID dThreadedCallWaitAllocFunction(dThreadingImplementationID impl); + +/** + * @brief Resets a Wait ID so that it could be used to wait for another call. + * + * @param impl Threading implementation ID + * @param call_wait Wait ID to reset + * + * @ingroup threading + * @see dThreadedCallWaitAllocFunction + * @see dThreadedCallWaitFreeFunction + * @see dThreadedCallPostFunction + * @see dThreadedCallWaitFunction + */ +typedef void dThreadedCallWaitResetFunction(dThreadingImplementationID impl, dCallWaitID call_wait); + +/** + * @brief Frees a Wait ID. + * + * @param impl Threading implementation ID + * @param call_wait Wait ID to delete + * + * @ingroup threading + * @see dThreadedCallWaitAllocFunction + * @see dThreadedCallPostFunction + * @see dThreadedCallWaitFunction + */ +typedef void dThreadedCallWaitFreeFunction(dThreadingImplementationID impl, dCallWaitID call_wait); + + +/** + * @brief Post a function to be called in another thread. + * + * A call is scheduled to be executed asynchronously. + * + * A @a out_summary_fault variable can be provided for call to accumulate any + * possible faults from its execution and execution of any possible sub-calls. + * This variable gets result that @a call_func returns. Also, if dependent calls + * are executed after the call already exits, the variable is also going to be + * updated with results of all those calls before control is released to master. + * + * @a out_post_releasee parameter receives a value of @c dCallReleaseeID that can + * later be used for @a dependent_releasee while scheduling sub-calls to make + * current call depend on them. The value is only returned if @a dependencies_count + * is not zero (i.e. if any dependencies are expected at all). The call is not going + * to start until all its dependencies complete. + * + * In case if number of dependencies is unknown in advance 1 can be passed on call + * scheduling. Then @c dThreadedCallDependenciesCountAlterFunction can be used to + * add one more extra dependencies before scheduling each subcall. And then, after + * all sub-calls had been scheduled, @c dThreadedCallDependenciesCountAlterFunction + * can be used again to subtract initial extra dependency from total number. + * Adding one dependency in advance is necessary to obtain releasee ID and to make + * sure the call will not start and will not terminate before all sub-calls are scheduled. + * + * Extra dependencies can also be added from the call itself after it has already + * been started (with parameter received in @c dThreadedCallFunction). + * In that case those dependencies will start immediately or after call returns + * but the call's master will not be released/notified until all additional + * dependencies complete. This can be used to schedule sub-calls from a call and + * then pass own job to another sub-call dependent on those initial sub-calls. + * + * By using @ call_wait it is possible to assign a Wait ID that can later + * be passed into @c dThreadedCallWaitFunction to wait for call completion. + * + * If @a call_name is available (and it should!) the string must remain valid until + * after call completion. In most cases this should be a static string literal. + * + * Since the function is an analogue of normal method call it is not supposed to fail. + * Any complications with resource allocation on call scheduling should be + * anticipated, avoided and worked around by implementation. + * + * @param impl Threading implementation ID + * @param out_summary_fault Optional pointer to variable to be set to 1 if function + * call (or any sub-call) fails internally, or 0 if all calls return success + * @param out_post_releasee Optional pointer to variable to receive releasee ID + * associated with the call + * @param dependencies_count Number of dependencies that are going to reference + * this call as dependent releasee + * @param dependent_releasee Optional releasee ID to reference with this call + * @param call_wait Optional Wait ID that can later be used to wait for the call + * @param call_func Pointer to function to be called + * @param call_context Context parameter to be passed into the call + * @param instance_index Index parameter to be passed into the call + * @param call_name Optional name to be associated with the call (for debugging and state tracking) + * + * @ingroup threading + * @see dThreadedCallWaitFunction + * @see dThreadedCallDependenciesCountAlterFunction + * @see dThreadingImplResourcesForCallsPreallocateFunction + */ +typedef void dThreadedCallPostFunction(dThreadingImplementationID impl, int *out_summary_fault/*=NULL*/, + dCallReleaseeID *out_post_releasee/*=NULL*/, ddependencycount_t dependencies_count, dCallReleaseeID dependent_releasee/*=NULL*/, + dCallWaitID call_wait/*=NULL*/, + dThreadedCallFunction *call_func, void *call_context, dcallindex_t instance_index, + const char *call_name/*=NULL*/); + +/** + * @brief Add or remove extra dependencies from call that has been scheduled + * or is in process of execution. + * + * Extra dependencies can be added to a call if exact number of sub-calls is + * not known in advance at the moment the call is scheduled. Also, some dependencies + * can be removed if sub-calls were planned but then dropped. + * + * In case if total dependency count of a call reaches zero by result of invoking + * this function, the call is free to start executing immediately. + * + * After the call execution had been started, any additional dependencies can only + * be added from the call function itself! + * + * @param impl Threading implementation ID + * @param target_releasee ID of releasee to apply dependencies count change to + * @param dependencies_count_change Number of dependencies to add or remove + * + * @ingroup threading + * @see dThreadedCallPostFunction + */ +typedef void dThreadedCallDependenciesCountAlterFunction(dThreadingImplementationID impl, dCallReleaseeID target_releasee, + ddependencychange_t dependencies_count_change); + +/** + * @brief Wait for a posted call to complete. + * + * Function blocks until a call identified by @a call_wait completes or + * timeout elapses. + * + * IT IS ILLEGAL TO INVOKE THIS FUNCTION FROM WITHIN A THREADED CALL! + * This is because doing so will block a physical thread and will require + * increasing worker thread count to avoid starvation. Use call dependencies + * if it is necessary make sure sub-calls have been completed instead! + * + * If @a timeout_time_ptr is NULL, the function waits without time limit. If @a timeout_time_ptr + * points to zero value, the function only checks status and does not block. + * + * If @a wait_name is available (and it should!) the string must remain valid for + * the duration of wait. In most cases this should be a static string literal. + * + * Function is not expected to return failures caused by system call faults as + * those are hardly ever possible to be handled in this case anyway. In event of + * system call fault the function is supposed to terminate application. + * + * @param impl Threading implementation ID + * @param out_wait_status Optional pointer to variable to receive 1 if waiting succeeded + * or 0 in case of timeout + * @param call_wait Wait ID that had been passed to scheduling a call that needs to be waited for + * @param timeout_time_ptr Optional pointer to time specification the wait must not + * last longer than (pass NULL for infinite timeout) + * @param wait_name Optional name to be associated with the wait (for debugging and state tracking) + * + * @ingroup threading + * @see dThreadedCallPostFunction + */ +typedef void dThreadedCallWaitFunction(dThreadingImplementationID impl, int *out_wait_status/*=NULL*/, + dCallWaitID call_wait, const dThreadedWaitTime *timeout_time_ptr/*=NULL*/, + const char *wait_name/*=NULL*/); + +/** + * @brief Retrieve number of active threads that serve the implementation. + * + * @param impl Threading implementation ID + * @returns Number of active threads + * + * @ingroup threading + */ +typedef unsigned dThreadingImplThreadCountRetrieveFunction(dThreadingImplementationID impl); + +/** + * @brief Preallocate resources to handle posted calls. + * + * The function is intended to make sure enough resources is preallocated for the + * implementation to be able to handle posted calls. Then @c max_simultaneous_calls_estimate + * is an estimate of how many posted calls can potentially be active or scheduled + * at the same time. The value is usually derived from the way the calls are posted + * in library code and dependencies between them. + * + * @warning While working on an implementation be prepared that the estimate provided + * yet rarely but theoretically can be exceeded due to unpredictability of thread execution. + * + * This function is normally going to be invoked by library each time it is entered + * from outside to do the job but before any threaded calls are going to be posted. + * + * @param impl Threading implementation ID + * @param max_simultaneous_calls_estimate An estimated number of calls that can be posted simultaneously + * @returns 1 or 0 to indicate success or failure + * + * @ingroup threading + * @see dThreadedCallPostFunction + */ +typedef int dThreadingImplResourcesForCallsPreallocateFunction(dThreadingImplementationID impl, + ddependencycount_t max_simultaneous_calls_estimate); + + +/** + * @brief An interface structure with function pointers to be provided by threading implementation. + */ +typedef struct dxThreadingFunctionsInfo +{ + unsigned struct_size; + + dMutexGroupAllocFunction *alloc_mutex_group; + dMutexGroupFreeFunction *free_mutex_group; + dMutexGroupMutexLockFunction *lock_group_mutex; + dMutexGroupMutexUnlockFunction *unlock_group_mutex; + + dThreadedCallWaitAllocFunction *alloc_call_wait; + dThreadedCallWaitResetFunction *reset_call_wait; + dThreadedCallWaitFreeFunction *free_call_wait; + + dThreadedCallPostFunction *post_call; + dThreadedCallDependenciesCountAlterFunction *alter_call_dependencies_count; + dThreadedCallWaitFunction *wait_call; + + dThreadingImplThreadCountRetrieveFunction *retrieve_thread_count; + dThreadingImplResourcesForCallsPreallocateFunction *preallocate_resources_for_calls; + + /* + * Beware of Jon Watte's anger if you dare to uncomment this! + * May cryptic text below be you a warning! + * Стародавні легенди розказують, що кожного ÑміливцÑ, хто наважитьÑÑ Ð¿Ð¾Ñ€ÑƒÑˆÐ¸Ñ‚Ð¸ табу + * Ñ– відкрити заборонений код, Ñпіткає Ñтрашне проклÑÑ‚Ñ‚Ñ Ñ– він відразу почне робити + * одні лиш помилки. + * + * dMutexGroupMutexTryLockFunction *trylock_group_mutex; + */ + +} dThreadingFunctionsInfo; + + +#ifdef __cplusplus +} +#endif + +#endif /* #ifndef _ODE_THREADING_H_ */ diff --git a/libs/ode-0.16.1/include/ode/threading_impl.h b/libs/ode-0.16.1/include/ode/threading_impl.h new file mode 100644 index 0000000..0781d6a --- /dev/null +++ b/libs/ode-0.16.1/include/ode/threading_impl.h @@ -0,0 +1,292 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * Builtin ODE threading implementation header. * + * Copyright (C) 2011-2019 Oleh Derevenko. All rights reserved. * + * e-mail: odar@eleks.com (change all "a" to "e") * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +/* + * A threading implementation built into ODE for those who does not care to + * or can't implement an own one. + */ + +#ifndef _ODE_THREADING_IMPL_H_ +#define _ODE_THREADING_IMPL_H_ + + +#include +#include + + +#ifdef __cplusplus +extern "C" { +#endif + + +struct dxThreadingThreadPool; +typedef struct dxThreadingThreadPool *dThreadingThreadPoolID; + + +/** + * @brief Allocates built-in self-threaded threading implementation object. + * + * A self-threaded implementation is a type of implementation that performs + * processing of posted calls by means of caller thread itself. This type of + * implementation does not need thread pool to serve it. + * + * Note that since May 9th, 2017 (rev. #2066) the Self-Threaded implementation + * returns 0 rather than 1 as available thread count to distinguish from + * thread pools with just one thread in them. + * + * The processing is arranged in a way to prevent call stack depth growth + * as more and more nested calls are posted. + * + * Note that it is not necessary to create and assign a self-threaded + * implementation to a world, as there is a global one used by default + * if no implementation is explicitly assigned. You should only assign + * each world an individual threading implementation instance if simulations + * need to be run in parallel in multiple threads for the worlds. + * + * @returns ID of object allocated or NULL on failure + * + * @ingroup threading + * @see dThreadingAllocateMultiThreadedImplementation + * @see dThreadingFreeImplementation + */ +ODE_API dThreadingImplementationID dThreadingAllocateSelfThreadedImplementation(); + +/** + * @brief Allocates built-in multi-threaded threading implementation object. + * + * A multi-threaded implementation is a type of implementation that has to be + * served with a thread pool. The thread pool can be either the built-in ODE object + * or set of external threads that dedicate themselves to this purpose and stay + * in ODE until implementation releases them. + * + * @returns ID of object allocated or NULL on failure + * + * @ingroup threading + * @see dThreadingThreadPoolServeMultiThreadedImplementation + * @see dExternalThreadingServeMultiThreadedImplementation + * @see dThreadingFreeImplementation + */ +ODE_API dThreadingImplementationID dThreadingAllocateMultiThreadedImplementation(); + +/** + * @brief Retrieves the functions record of a built-in threading implementation. + * + * The implementation can be the one allocated by ODE (from @c dThreadingAllocateMultiThreadedImplementation). + * Do not use this function with self-made custom implementations - + * they should be bundled with their own set of functions. + * + * @param impl Threading implementation ID + * @returns Pointer to associated functions structure + * + * @ingroup threading + * @see dThreadingAllocateMultiThreadedImplementation + */ +ODE_API const dThreadingFunctionsInfo *dThreadingImplementationGetFunctions(dThreadingImplementationID impl); + +/** + * @brief Requests a built-in implementation to release threads serving it. + * + * The function unblocks threads employed in implementation serving and lets them + * return to from where they originate. It's the responsibility of external code + * to make sure all the calls to ODE that might be dependent on given threading + * implementation object had already returned before this call is made. If threading + * implementation is still processing some posted calls while this function is + * invoked the behavior is implementation dependent. + * + * This call is to be used to request the threads to be released before waiting + * for them in host pool or before waiting for them to exit. Implementation object + * must not be destroyed before it is known that all the serving threads have already + * returned from it. If implementation needs to be reused after this function is called + * and all the threads have exited from it a call to @c dThreadingImplementationCleanupForRestart + * must be made to restore internal state of the object. + * + * If this function is called for self-threaded built-in threading implementation + * the call has no effect. + * + * @param impl Threading implementation ID + * + * @ingroup threading + * @see dThreadingAllocateMultiThreadedImplementation + * @see dThreadingImplementationCleanupForRestart + */ +ODE_API void dThreadingImplementationShutdownProcessing(dThreadingImplementationID impl); + +/** + * @brief Restores built-in implementation's state to let it be reused after shutdown. + * + * If a multi-threaded built-in implementation needs to be reused after a call + * to @c dThreadingImplementationShutdownProcessing this call is to be made to + * restore object's internal state. After that the implementation can be served again. + * + * If this function is called for self-threaded built-in threading implementation + * the call has no effect. + * + * @param impl Threading implementation ID + * + * @ingroup threading + * @see dThreadingAllocateMultiThreadedImplementation + * @see dThreadingImplementationShutdownProcessing + */ +ODE_API void dThreadingImplementationCleanupForRestart(dThreadingImplementationID impl); + +/** + * @brief Deletes an instance of built-in threading implementation. + * + * @warning A care must be taken to make sure the implementation is unassigned + * from all the objects it was assigned to and that there are no more threads + * serving it before attempting to call this function. + * + * @param impl Threading implementation ID + * + * @ingroup threading + * @see dThreadingAllocateMultiThreadedImplementation + */ +ODE_API void dThreadingFreeImplementation(dThreadingImplementationID impl); + + +typedef void (dThreadReadyToServeCallback)(void *callback_context); + +/** + * @brief An entry point for external threads that would like to serve a built-in + * threading implementation object. + * + * A thread that calls this function remains blocked in ODE and serves implementation + * object @p impl until being released with @c dThreadingImplementationShutdownProcessing call. + * This function can be used to provide external threads instead of ODE's built-in + * thread pools. + * + * The optional callback @readiness_callback is called after the thread has reached + * and has registered within the implementation. The implementation should not + * be used until all dedicated threads register within it as otherwise it will not + * have accurate view of the execution resources available. + * + * @param impl Threading implementation ID + * @param readiness_callback Optional readiness callback to be called after thread enters the implementation + * @param callback_context A value to be passed as parameter to readiness callback + * + * @ingroup threading + * @see dThreadingAllocateMultiThreadedImplementation + * @see dThreadingImplementationShutdownProcessing + */ +ODE_API void dExternalThreadingServeMultiThreadedImplementation(dThreadingImplementationID impl, + dThreadReadyToServeCallback *readiness_callback/*=NULL*/, void *callback_context/*=NULL*/); + + +/** + * @brief Creates an instance of built-in thread pool object that can be used to serve + * multi-threaded threading implementations. + * + * The threads allocated inherit priority of caller thread. Their affinity is not + * explicitly adjusted and gets the value the system assigns by default. Threads + * have their stack memory fully committed immediately on start. On POSIX platforms + * threads are started with all the possible signals blocked. Threads execute + * calls to @c dAllocateODEDataForThread with @p ode_data_allocate_flags + * on initialization. + * + * On POSIX platforms this function must be called with signals masked + * or other measures must be taken to prevent reception of signals by calling thread + * for the duration of the call. + * + * @param thread_count Number of threads to start in pool + * @param stack_size Size of stack to be used for every thread or 0 for system default value + * @param ode_data_allocate_flags Flags to be passed to @c dAllocateODEDataForThread on behalf of each thread + * @returns ID of object allocated or NULL on failure + * + * @ingroup threading + * @see dThreadingAllocateMultiThreadedImplementation + * @see dThreadingImplementationShutdownProcessing + * @see dThreadingFreeThreadPool + */ +ODE_API dThreadingThreadPoolID dThreadingAllocateThreadPool(unsigned thread_count, + dsizeint stack_size, unsigned int ode_data_allocate_flags, void *reserved/*=NULL*/); + +/** + * @brief Commands an instance of built-in thread pool to serve a built-in multi-threaded + * threading implementation. + * + * A pool can only serve one threading implementation at a time. + * Call @c dThreadingImplementationShutdownProcessing to release pool threads + * from implementation serving and make them idle. Pool threads must be released + * from any implementations before pool is attempted to be deleted. + * + * This function waits for threads to register within implementation before returning. + * So, after the function call exits the implementation can be used immediately. + * + * @param pool Thread pool ID to serve the implementation + * @param impl Implementation ID of implementation to be served + * + * @ingroup threading + * @see dThreadingAllocateThreadPool + * @see dThreadingAllocateMultiThreadedImplementation + * @see dThreadingImplementationShutdownProcessing + */ +ODE_API void dThreadingThreadPoolServeMultiThreadedImplementation(dThreadingThreadPoolID pool, dThreadingImplementationID impl); + +/** + * @brief Waits until all pool threads are released from threading implementation + * they might be serving. + * + * The function can be used after a call to @c dThreadingImplementationShutdownProcessing + * to make sure all the threads have already been released by threading implementation + * and it can be deleted or it can be cleaned up for restart and served by another pool + * or this pool's threads can be used to serve another threading implementation. + * + * Note that is it not necessary to call this function before pool destruction + * since @c dThreadingFreeThreadPool performs similar wait operation implicitly on its own. + * + * It is OK to call this function even if pool was not serving any threading implementation + * in which case the call exits immediately with minimal delay. + * + * @param pool Thread pool ID to wait for + * + * @ingroup threading + * @see dThreadingAllocateThreadPool + * @see dThreadingImplementationShutdownProcessing + * @see dThreadingFreeThreadPool + */ +ODE_API void dThreadingThreadPoolWaitIdleState(dThreadingThreadPoolID pool); + +/** + * @brief Deletes a built-in thread pool instance. + * + * The pool threads must be released from any implementations they might be serving + * before this function is called. Otherwise the call is going to block + * and wait until pool's threads return. + * + * @param pool Thread pool ID to delete + * + * @ingroup threading + * @see dThreadingAllocateThreadPool + * @see dThreadingImplementationShutdownProcessing + */ +ODE_API void dThreadingFreeThreadPool(dThreadingThreadPoolID pool); + + +#ifdef __cplusplus +} +#endif + +#endif /* #ifndef _ODE_THREADING_IMPL_H_ */ diff --git a/libs/ode-0.16.1/include/ode/timer.h b/libs/ode-0.16.1/include/ode/timer.h new file mode 100644 index 0000000..fe1483f --- /dev/null +++ b/libs/ode-0.16.1/include/ode/timer.h @@ -0,0 +1,76 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#ifndef _ODE_TIMER_H_ +#define _ODE_TIMER_H_ + +#include + +#ifdef __cplusplus +extern "C" { +#endif + + +/* stop watch objects */ + +typedef struct dStopwatch { + double time; /* total clock count */ + unsigned long cc[2]; /* clock count since last `start' */ +} dStopwatch; + +ODE_API void dStopwatchReset (dStopwatch *); +ODE_API void dStopwatchStart (dStopwatch *); +ODE_API void dStopwatchStop (dStopwatch *); +ODE_API double dStopwatchTime (dStopwatch *); /* returns total time in secs */ + + +/* code timers */ + +ODE_API void dTimerStart (const char *description); /* pass a static string here */ +ODE_API void dTimerNow (const char *description); /* pass a static string here */ +ODE_API void dTimerEnd(void); + +/* print out a timer report. if `average' is nonzero, print out the average + * time for each slot (this is only meaningful if the same start-now-end + * calls are being made repeatedly. + */ +ODE_API void dTimerReport (FILE *fout, int average); + + +/* resolution */ + +/* returns the timer ticks per second implied by the timing hardware or API. + * the actual timer resolution may not be this great. + */ +ODE_API double dTimerTicksPerSecond(void); + +/* returns an estimate of the actual timer resolution, in seconds. this may + * be greater than 1/ticks_per_second. + */ +ODE_API double dTimerResolution(void); + + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/libs/ode-0.16.1/include/ode/version.h b/libs/ode-0.16.1/include/ode/version.h new file mode 100644 index 0000000..980217e --- /dev/null +++ b/libs/ode-0.16.1/include/ode/version.h @@ -0,0 +1,6 @@ +#ifndef _ODE_VERSION_H_ +#define _ODE_VERSION_H_ + +#define dODE_VERSION "0.16.1" + +#endif diff --git a/libs/ode-0.16.1/include/ode/version.h.in b/libs/ode-0.16.1/include/ode/version.h.in new file mode 100644 index 0000000..b5d3c81 --- /dev/null +++ b/libs/ode-0.16.1/include/ode/version.h.in @@ -0,0 +1,6 @@ +#ifndef _ODE_VERSION_H_ +#define _ODE_VERSION_H_ + +#define dODE_VERSION "@ODE_VERSION@" + +#endif diff --git a/libs/ode-0.16.1/install-sh b/libs/ode-0.16.1/install-sh new file mode 100755 index 0000000..0b0fdcb --- /dev/null +++ b/libs/ode-0.16.1/install-sh @@ -0,0 +1,501 @@ +#!/bin/sh +# install - install a program, script, or datafile + +scriptversion=2013-12-25.23; # UTC + +# This originates from X11R5 (mit/util/scripts/install.sh), which was +# later released in X11R6 (xc/config/util/install.sh) with the +# following copyright and license. +# +# Copyright (C) 1994 X Consortium +# +# Permission is hereby granted, free of charge, to any person obtaining a copy +# of this software and associated documentation files (the "Software"), to +# deal in the Software without restriction, including without limitation the +# rights to use, copy, modify, merge, publish, distribute, sublicense, and/or +# sell copies of the Software, and to permit persons to whom the Software is +# furnished to do so, subject to the following conditions: +# +# The above copyright notice and this permission notice shall be included in +# all copies or substantial portions of the Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +# X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN +# AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC- +# TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +# +# Except as contained in this notice, the name of the X Consortium shall not +# be used in advertising or otherwise to promote the sale, use or other deal- +# ings in this Software without prior written authorization from the X Consor- +# tium. +# +# +# FSF changes to this file are in the public domain. +# +# Calling this script install-sh is preferred over install.sh, to prevent +# 'make' implicit rules from creating a file called install from it +# when there is no Makefile. +# +# This script is compatible with the BSD install script, but was written +# from scratch. + +tab=' ' +nl=' +' +IFS=" $tab$nl" + +# Set DOITPROG to "echo" to test this script. + +doit=${DOITPROG-} +doit_exec=${doit:-exec} + +# Put in absolute file names if you don't have them in your path; +# or use environment vars. + +chgrpprog=${CHGRPPROG-chgrp} +chmodprog=${CHMODPROG-chmod} +chownprog=${CHOWNPROG-chown} +cmpprog=${CMPPROG-cmp} +cpprog=${CPPROG-cp} +mkdirprog=${MKDIRPROG-mkdir} +mvprog=${MVPROG-mv} +rmprog=${RMPROG-rm} +stripprog=${STRIPPROG-strip} + +posix_mkdir= + +# Desired mode of installed file. +mode=0755 + +chgrpcmd= +chmodcmd=$chmodprog +chowncmd= +mvcmd=$mvprog +rmcmd="$rmprog -f" +stripcmd= + +src= +dst= +dir_arg= +dst_arg= + +copy_on_change=false +is_target_a_directory=possibly + +usage="\ +Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE + or: $0 [OPTION]... SRCFILES... DIRECTORY + or: $0 [OPTION]... -t DIRECTORY SRCFILES... + or: $0 [OPTION]... -d DIRECTORIES... + +In the 1st form, copy SRCFILE to DSTFILE. +In the 2nd and 3rd, copy all SRCFILES to DIRECTORY. +In the 4th, create DIRECTORIES. + +Options: + --help display this help and exit. + --version display version info and exit. + + -c (ignored) + -C install only if different (preserve the last data modification time) + -d create directories instead of installing files. + -g GROUP $chgrpprog installed files to GROUP. + -m MODE $chmodprog installed files to MODE. + -o USER $chownprog installed files to USER. + -s $stripprog installed files. + -t DIRECTORY install into DIRECTORY. + -T report an error if DSTFILE is a directory. + +Environment variables override the default commands: + CHGRPPROG CHMODPROG CHOWNPROG CMPPROG CPPROG MKDIRPROG MVPROG + RMPROG STRIPPROG +" + +while test $# -ne 0; do + case $1 in + -c) ;; + + -C) copy_on_change=true;; + + -d) dir_arg=true;; + + -g) chgrpcmd="$chgrpprog $2" + shift;; + + --help) echo "$usage"; exit $?;; + + -m) mode=$2 + case $mode in + *' '* | *"$tab"* | *"$nl"* | *'*'* | *'?'* | *'['*) + echo "$0: invalid mode: $mode" >&2 + exit 1;; + esac + shift;; + + -o) chowncmd="$chownprog $2" + shift;; + + -s) stripcmd=$stripprog;; + + -t) + is_target_a_directory=always + dst_arg=$2 + # Protect names problematic for 'test' and other utilities. + case $dst_arg in + -* | [=\(\)!]) dst_arg=./$dst_arg;; + esac + shift;; + + -T) is_target_a_directory=never;; + + --version) echo "$0 $scriptversion"; exit $?;; + + --) shift + break;; + + -*) echo "$0: invalid option: $1" >&2 + exit 1;; + + *) break;; + esac + shift +done + +# We allow the use of options -d and -T together, by making -d +# take the precedence; this is for compatibility with GNU install. + +if test -n "$dir_arg"; then + if test -n "$dst_arg"; then + echo "$0: target directory not allowed when installing a directory." >&2 + exit 1 + fi +fi + +if test $# -ne 0 && test -z "$dir_arg$dst_arg"; then + # When -d is used, all remaining arguments are directories to create. + # When -t is used, the destination is already specified. + # Otherwise, the last argument is the destination. Remove it from $@. + for arg + do + if test -n "$dst_arg"; then + # $@ is not empty: it contains at least $arg. + set fnord "$@" "$dst_arg" + shift # fnord + fi + shift # arg + dst_arg=$arg + # Protect names problematic for 'test' and other utilities. + case $dst_arg in + -* | [=\(\)!]) dst_arg=./$dst_arg;; + esac + done +fi + +if test $# -eq 0; then + if test -z "$dir_arg"; then + echo "$0: no input file specified." >&2 + exit 1 + fi + # It's OK to call 'install-sh -d' without argument. + # This can happen when creating conditional directories. + exit 0 +fi + +if test -z "$dir_arg"; then + if test $# -gt 1 || test "$is_target_a_directory" = always; then + if test ! -d "$dst_arg"; then + echo "$0: $dst_arg: Is not a directory." >&2 + exit 1 + fi + fi +fi + +if test -z "$dir_arg"; then + do_exit='(exit $ret); exit $ret' + trap "ret=129; $do_exit" 1 + trap "ret=130; $do_exit" 2 + trap "ret=141; $do_exit" 13 + trap "ret=143; $do_exit" 15 + + # Set umask so as not to create temps with too-generous modes. + # However, 'strip' requires both read and write access to temps. + case $mode in + # Optimize common cases. + *644) cp_umask=133;; + *755) cp_umask=22;; + + *[0-7]) + if test -z "$stripcmd"; then + u_plus_rw= + else + u_plus_rw='% 200' + fi + cp_umask=`expr '(' 777 - $mode % 1000 ')' $u_plus_rw`;; + *) + if test -z "$stripcmd"; then + u_plus_rw= + else + u_plus_rw=,u+rw + fi + cp_umask=$mode$u_plus_rw;; + esac +fi + +for src +do + # Protect names problematic for 'test' and other utilities. + case $src in + -* | [=\(\)!]) src=./$src;; + esac + + if test -n "$dir_arg"; then + dst=$src + dstdir=$dst + test -d "$dstdir" + dstdir_status=$? + else + + # Waiting for this to be detected by the "$cpprog $src $dsttmp" command + # might cause directories to be created, which would be especially bad + # if $src (and thus $dsttmp) contains '*'. + if test ! -f "$src" && test ! -d "$src"; then + echo "$0: $src does not exist." >&2 + exit 1 + fi + + if test -z "$dst_arg"; then + echo "$0: no destination specified." >&2 + exit 1 + fi + dst=$dst_arg + + # If destination is a directory, append the input filename; won't work + # if double slashes aren't ignored. + if test -d "$dst"; then + if test "$is_target_a_directory" = never; then + echo "$0: $dst_arg: Is a directory" >&2 + exit 1 + fi + dstdir=$dst + dst=$dstdir/`basename "$src"` + dstdir_status=0 + else + dstdir=`dirname "$dst"` + test -d "$dstdir" + dstdir_status=$? + fi + fi + + obsolete_mkdir_used=false + + if test $dstdir_status != 0; then + case $posix_mkdir in + '') + # Create intermediate dirs using mode 755 as modified by the umask. + # This is like FreeBSD 'install' as of 1997-10-28. + umask=`umask` + case $stripcmd.$umask in + # Optimize common cases. + *[2367][2367]) mkdir_umask=$umask;; + .*0[02][02] | .[02][02] | .[02]) mkdir_umask=22;; + + *[0-7]) + mkdir_umask=`expr $umask + 22 \ + - $umask % 100 % 40 + $umask % 20 \ + - $umask % 10 % 4 + $umask % 2 + `;; + *) mkdir_umask=$umask,go-w;; + esac + + # With -d, create the new directory with the user-specified mode. + # Otherwise, rely on $mkdir_umask. + if test -n "$dir_arg"; then + mkdir_mode=-m$mode + else + mkdir_mode= + fi + + posix_mkdir=false + case $umask in + *[123567][0-7][0-7]) + # POSIX mkdir -p sets u+wx bits regardless of umask, which + # is incompatible with FreeBSD 'install' when (umask & 300) != 0. + ;; + *) + tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$ + trap 'ret=$?; rmdir "$tmpdir/d" "$tmpdir" 2>/dev/null; exit $ret' 0 + + if (umask $mkdir_umask && + exec $mkdirprog $mkdir_mode -p -- "$tmpdir/d") >/dev/null 2>&1 + then + if test -z "$dir_arg" || { + # Check for POSIX incompatibilities with -m. + # HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or + # other-writable bit of parent directory when it shouldn't. + # FreeBSD 6.1 mkdir -m -p sets mode of existing directory. + ls_ld_tmpdir=`ls -ld "$tmpdir"` + case $ls_ld_tmpdir in + d????-?r-*) different_mode=700;; + d????-?--*) different_mode=755;; + *) false;; + esac && + $mkdirprog -m$different_mode -p -- "$tmpdir" && { + ls_ld_tmpdir_1=`ls -ld "$tmpdir"` + test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1" + } + } + then posix_mkdir=: + fi + rmdir "$tmpdir/d" "$tmpdir" + else + # Remove any dirs left behind by ancient mkdir implementations. + rmdir ./$mkdir_mode ./-p ./-- 2>/dev/null + fi + trap '' 0;; + esac;; + esac + + if + $posix_mkdir && ( + umask $mkdir_umask && + $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir" + ) + then : + else + + # The umask is ridiculous, or mkdir does not conform to POSIX, + # or it failed possibly due to a race condition. Create the + # directory the slow way, step by step, checking for races as we go. + + case $dstdir in + /*) prefix='/';; + [-=\(\)!]*) prefix='./';; + *) prefix='';; + esac + + oIFS=$IFS + IFS=/ + set -f + set fnord $dstdir + shift + set +f + IFS=$oIFS + + prefixes= + + for d + do + test X"$d" = X && continue + + prefix=$prefix$d + if test -d "$prefix"; then + prefixes= + else + if $posix_mkdir; then + (umask=$mkdir_umask && + $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir") && break + # Don't fail if two instances are running concurrently. + test -d "$prefix" || exit 1 + else + case $prefix in + *\'*) qprefix=`echo "$prefix" | sed "s/'/'\\\\\\\\''/g"`;; + *) qprefix=$prefix;; + esac + prefixes="$prefixes '$qprefix'" + fi + fi + prefix=$prefix/ + done + + if test -n "$prefixes"; then + # Don't fail if two instances are running concurrently. + (umask $mkdir_umask && + eval "\$doit_exec \$mkdirprog $prefixes") || + test -d "$dstdir" || exit 1 + obsolete_mkdir_used=true + fi + fi + fi + + if test -n "$dir_arg"; then + { test -z "$chowncmd" || $doit $chowncmd "$dst"; } && + { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } && + { test "$obsolete_mkdir_used$chowncmd$chgrpcmd" = false || + test -z "$chmodcmd" || $doit $chmodcmd $mode "$dst"; } || exit 1 + else + + # Make a couple of temp file names in the proper directory. + dsttmp=$dstdir/_inst.$$_ + rmtmp=$dstdir/_rm.$$_ + + # Trap to clean up those temp files at exit. + trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0 + + # Copy the file name to the temp name. + (umask $cp_umask && $doit_exec $cpprog "$src" "$dsttmp") && + + # and set any options; do chmod last to preserve setuid bits. + # + # If any of these fail, we abort the whole thing. If we want to + # ignore errors from any of these, just make sure not to ignore + # errors from the above "$doit $cpprog $src $dsttmp" command. + # + { test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } && + { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } && + { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } && + { test -z "$chmodcmd" || $doit $chmodcmd $mode "$dsttmp"; } && + + # If -C, don't bother to copy if it wouldn't change the file. + if $copy_on_change && + old=`LC_ALL=C ls -dlL "$dst" 2>/dev/null` && + new=`LC_ALL=C ls -dlL "$dsttmp" 2>/dev/null` && + set -f && + set X $old && old=:$2:$4:$5:$6 && + set X $new && new=:$2:$4:$5:$6 && + set +f && + test "$old" = "$new" && + $cmpprog "$dst" "$dsttmp" >/dev/null 2>&1 + then + rm -f "$dsttmp" + else + # Rename the file to the real destination. + $doit $mvcmd -f "$dsttmp" "$dst" 2>/dev/null || + + # The rename failed, perhaps because mv can't rename something else + # to itself, or perhaps because mv is so ancient that it does not + # support -f. + { + # Now remove or move aside any old file at destination location. + # We try this two ways since rm can't unlink itself on some + # systems and the destination file might be busy for other + # reasons. In this case, the final cleanup might fail but the new + # file should still install successfully. + { + test ! -f "$dst" || + $doit $rmcmd -f "$dst" 2>/dev/null || + { $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null && + { $doit $rmcmd -f "$rmtmp" 2>/dev/null; :; } + } || + { echo "$0: cannot unlink or rename $dst" >&2 + (exit 1); exit 1 + } + } && + + # Now rename the file to the real destination. + $doit $mvcmd "$dsttmp" "$dst" + } + fi || exit 1 + + trap '' 0 + fi +done + +# Local variables: +# eval: (add-hook 'write-file-hooks 'time-stamp) +# time-stamp-start: "scriptversion=" +# time-stamp-format: "%:y-%02m-%02d.%02H" +# time-stamp-time-zone: "UTC" +# time-stamp-end: "; # UTC" +# End: diff --git a/libs/ode-0.16.1/libccd/BSD-LICENSE b/libs/ode-0.16.1/libccd/BSD-LICENSE new file mode 100644 index 0000000..6d7fa23 --- /dev/null +++ b/libs/ode-0.16.1/libccd/BSD-LICENSE @@ -0,0 +1,44 @@ +libccd +------- + +Copyright (c)2010 Daniel Fiser , +Intelligent and Mobile Robotics Group, Department of Cybernetics, +Faculty of Electrical Engineering, Czech Technical University in Prague. +All rights reserved. + + +This work was supported by SYMBRION and REPLICATOR projects. +The SYMBRION project is funded by European Commission within the work +"Future and Emergent Technologies Proactive" under grant agreement no. +216342. +The REPLICATOR project is funded within the work programme "Cognitive +Systems, Interaction, Robotics" under grant agreement no. 216240. +http://www.symbrion.eu/ +http://www.replicators.eu/ + + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + + - Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. + + - Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + - Neither the name of the University nor the names of its contributors + may be used to endorse or promote products derived from this software + without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE +LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN +CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +POSSIBILITY OF SUCH DAMAGE. diff --git a/libs/ode-0.16.1/libccd/Makefile.am b/libs/ode-0.16.1/libccd/Makefile.am new file mode 100644 index 0000000..c08c4b3 --- /dev/null +++ b/libs/ode-0.16.1/libccd/Makefile.am @@ -0,0 +1,6 @@ +SUBDIRS = src + +EXTRA_DIST = \ + bootstrap \ + BSD-LICENSE \ + README diff --git a/libs/ode-0.16.1/libccd/Makefile.in b/libs/ode-0.16.1/libccd/Makefile.in new file mode 100644 index 0000000..0973929 --- /dev/null +++ b/libs/ode-0.16.1/libccd/Makefile.in @@ -0,0 +1,804 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = . +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(top_srcdir)/configure \ + $(am__configure_deps) $(am__DIST_COMMON) +am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ + configure.lineno config.status.lineno +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/src/config.h +CONFIG_CLEAN_FILES = src/ccd/precision.h +CONFIG_CLEAN_VPATH_FILES = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +SOURCES = +DIST_SOURCES = +RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ + ctags-recursive dvi-recursive html-recursive info-recursive \ + install-data-recursive install-dvi-recursive \ + install-exec-recursive install-html-recursive \ + install-info-recursive install-pdf-recursive \ + install-ps-recursive install-recursive installcheck-recursive \ + installdirs-recursive pdf-recursive ps-recursive \ + tags-recursive uninstall-recursive +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ + distclean-recursive maintainer-clean-recursive +am__recursive_targets = \ + $(RECURSIVE_TARGETS) \ + $(RECURSIVE_CLEAN_TARGETS) \ + $(am__extra_recursive_targets) +AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ + cscope distdir dist dist-all distcheck +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +CSCOPE = cscope +DIST_SUBDIRS = $(SUBDIRS) +am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/../compile \ + $(top_srcdir)/../config.guess $(top_srcdir)/../config.sub \ + $(top_srcdir)/../install-sh $(top_srcdir)/../ltmain.sh \ + $(top_srcdir)/../missing $(top_srcdir)/src/ccd/precision.h.in \ + README +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +distdir = $(PACKAGE)-$(VERSION) +top_distdir = $(distdir) +am__remove_distdir = \ + if test -d "$(distdir)"; then \ + find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \ + && rm -rf "$(distdir)" \ + || { sleep 5 && rm -rf "$(distdir)"; }; \ + else :; fi +am__post_remove_distdir = $(am__remove_distdir) +am__relativize = \ + dir0=`pwd`; \ + sed_first='s,^\([^/]*\)/.*$$,\1,'; \ + sed_rest='s,^[^/]*/*,,'; \ + sed_last='s,^.*/\([^/]*\)$$,\1,'; \ + sed_butlast='s,/*[^/]*$$,,'; \ + while test -n "$$dir1"; do \ + first=`echo "$$dir1" | sed -e "$$sed_first"`; \ + if test "$$first" != "."; then \ + if test "$$first" = ".."; then \ + dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ + dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ + else \ + first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ + if test "$$first2" = "$$first"; then \ + dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ + else \ + dir2="../$$dir2"; \ + fi; \ + dir0="$$dir0"/"$$first"; \ + fi; \ + fi; \ + dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ + done; \ + reldir="$$dir2" +DIST_ARCHIVES = $(distdir).tar.gz +GZIP_ENV = --best +DIST_TARGETS = dist-gzip +distuninstallcheck_listfiles = find . -type f -print +am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \ + | sed 's|^\./|$(prefix)/|' | grep -v '$(infodir)/dir$$' +distcleancheck_listfiles = find . -type f -print +ACLOCAL = @ACLOCAL@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CCD_PRECISION = @CCD_PRECISION@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +FGREP = @FGREP@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +runstatedir = @runstatedir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +SUBDIRS = src +EXTRA_DIST = \ + bootstrap \ + BSD-LICENSE \ + README + +all: all-recursive + +.SUFFIXES: +am--refresh: Makefile + @: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + echo ' cd $(srcdir) && $(AUTOMAKE) --foreign'; \ + $(am__cd) $(srcdir) && $(AUTOMAKE) --foreign \ + && exit 0; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + echo ' $(SHELL) ./config.status'; \ + $(SHELL) ./config.status;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + $(SHELL) ./config.status --recheck + +$(top_srcdir)/configure: $(am__configure_deps) + $(am__cd) $(srcdir) && $(AUTOCONF) +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + $(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) +$(am__aclocal_m4_deps): +src/ccd/precision.h: $(top_builddir)/config.status $(top_srcdir)/src/ccd/precision.h.in + cd $(top_builddir) && $(SHELL) ./config.status $@ + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +distclean-libtool: + -rm -f libtool config.lt + +# This directory's subdirectories are mostly independent; you can cd +# into them and run 'make' without going through this Makefile. +# To change the values of 'make' variables: instead of editing Makefiles, +# (1) if the variable is set in 'config.status', edit 'config.status' +# (which will cause the Makefiles to be regenerated when you run 'make'); +# (2) otherwise, pass the desired values on the 'make' command line. +$(am__recursive_targets): + @fail=; \ + if $(am__make_keepgoing); then \ + failcom='fail=yes'; \ + else \ + failcom='exit 1'; \ + fi; \ + dot_seen=no; \ + target=`echo $@ | sed s/-recursive//`; \ + case "$@" in \ + distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ + *) list='$(SUBDIRS)' ;; \ + esac; \ + for subdir in $$list; do \ + echo "Making $$target in $$subdir"; \ + if test "$$subdir" = "."; then \ + dot_seen=yes; \ + local_target="$$target-am"; \ + else \ + local_target="$$target"; \ + fi; \ + ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ + || eval $$failcom; \ + done; \ + if test "$$dot_seen" = "no"; then \ + $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ + fi; test -z "$$fail" + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-recursive +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ + include_option=--etags-include; \ + empty_fix=.; \ + else \ + include_option=--include; \ + empty_fix=; \ + fi; \ + list='$(SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + test ! -f $$subdir/TAGS || \ + set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ + fi; \ + done; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-recursive + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscope: cscope.files + test ! -s cscope.files \ + || $(CSCOPE) -b -q $(AM_CSCOPEFLAGS) $(CSCOPEFLAGS) -i cscope.files $(CSCOPE_ARGS) +clean-cscope: + -rm -f cscope.files +cscope.files: clean-cscope cscopelist +cscopelist: cscopelist-recursive + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + -rm -f cscope.out cscope.in.out cscope.po.out cscope.files + +distdir: $(DISTFILES) + $(am__remove_distdir) + test -d "$(distdir)" || mkdir "$(distdir)" + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done + @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + $(am__make_dryrun) \ + || test -d "$(distdir)/$$subdir" \ + || $(MKDIR_P) "$(distdir)/$$subdir" \ + || exit 1; \ + dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ + $(am__relativize); \ + new_distdir=$$reldir; \ + dir1=$$subdir; dir2="$(top_distdir)"; \ + $(am__relativize); \ + new_top_distdir=$$reldir; \ + echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ + echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ + ($(am__cd) $$subdir && \ + $(MAKE) $(AM_MAKEFLAGS) \ + top_distdir="$$new_top_distdir" \ + distdir="$$new_distdir" \ + am__remove_distdir=: \ + am__skip_length_check=: \ + am__skip_mode_fix=: \ + distdir) \ + || exit 1; \ + fi; \ + done + -test -n "$(am__skip_mode_fix)" \ + || find "$(distdir)" -type d ! -perm -755 \ + -exec chmod u+rwx,go+rx {} \; -o \ + ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ + ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ + ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \ + || chmod -R a+r "$(distdir)" +dist-gzip: distdir + tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz + $(am__post_remove_distdir) + +dist-bzip2: distdir + tardir=$(distdir) && $(am__tar) | BZIP2=$${BZIP2--9} bzip2 -c >$(distdir).tar.bz2 + $(am__post_remove_distdir) + +dist-lzip: distdir + tardir=$(distdir) && $(am__tar) | lzip -c $${LZIP_OPT--9} >$(distdir).tar.lz + $(am__post_remove_distdir) + +dist-xz: distdir + tardir=$(distdir) && $(am__tar) | XZ_OPT=$${XZ_OPT--e} xz -c >$(distdir).tar.xz + $(am__post_remove_distdir) + +dist-tarZ: distdir + @echo WARNING: "Support for distribution archives compressed with" \ + "legacy program 'compress' is deprecated." >&2 + @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 + tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z + $(am__post_remove_distdir) + +dist-shar: distdir + @echo WARNING: "Support for shar distribution archives is" \ + "deprecated." >&2 + @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 + shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz + $(am__post_remove_distdir) + +dist-zip: distdir + -rm -f $(distdir).zip + zip -rq $(distdir).zip $(distdir) + $(am__post_remove_distdir) + +dist dist-all: + $(MAKE) $(AM_MAKEFLAGS) $(DIST_TARGETS) am__post_remove_distdir='@:' + $(am__post_remove_distdir) + +# This target untars the dist file and tries a VPATH configuration. Then +# it guarantees that the distribution is self-contained by making another +# tarfile. +distcheck: dist + case '$(DIST_ARCHIVES)' in \ + *.tar.gz*) \ + GZIP=$(GZIP_ENV) gzip -dc $(distdir).tar.gz | $(am__untar) ;;\ + *.tar.bz2*) \ + bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\ + *.tar.lz*) \ + lzip -dc $(distdir).tar.lz | $(am__untar) ;;\ + *.tar.xz*) \ + xz -dc $(distdir).tar.xz | $(am__untar) ;;\ + *.tar.Z*) \ + uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ + *.shar.gz*) \ + GZIP=$(GZIP_ENV) gzip -dc $(distdir).shar.gz | unshar ;;\ + *.zip*) \ + unzip $(distdir).zip ;;\ + esac + chmod -R a-w $(distdir) + chmod u+w $(distdir) + mkdir $(distdir)/_build $(distdir)/_build/sub $(distdir)/_inst + chmod a-w $(distdir) + test -d $(distdir)/_build || exit 0; \ + dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \ + && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ + && am__cwd=`pwd` \ + && $(am__cd) $(distdir)/_build/sub \ + && ../../configure \ + $(AM_DISTCHECK_CONFIGURE_FLAGS) \ + $(DISTCHECK_CONFIGURE_FLAGS) \ + --srcdir=../.. --prefix="$$dc_install_base" \ + && $(MAKE) $(AM_MAKEFLAGS) \ + && $(MAKE) $(AM_MAKEFLAGS) dvi \ + && $(MAKE) $(AM_MAKEFLAGS) check \ + && $(MAKE) $(AM_MAKEFLAGS) install \ + && $(MAKE) $(AM_MAKEFLAGS) installcheck \ + && $(MAKE) $(AM_MAKEFLAGS) uninstall \ + && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \ + distuninstallcheck \ + && chmod -R a-w "$$dc_install_base" \ + && ({ \ + (cd ../.. && umask 077 && mkdir "$$dc_destdir") \ + && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \ + && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \ + && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \ + distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \ + } || { rm -rf "$$dc_destdir"; exit 1; }) \ + && rm -rf "$$dc_destdir" \ + && $(MAKE) $(AM_MAKEFLAGS) dist \ + && rm -rf $(DIST_ARCHIVES) \ + && $(MAKE) $(AM_MAKEFLAGS) distcleancheck \ + && cd "$$am__cwd" \ + || exit 1 + $(am__post_remove_distdir) + @(echo "$(distdir) archives ready for distribution: "; \ + list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \ + sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x' +distuninstallcheck: + @test -n '$(distuninstallcheck_dir)' || { \ + echo 'ERROR: trying to run $@ with an empty' \ + '$$(distuninstallcheck_dir)' >&2; \ + exit 1; \ + }; \ + $(am__cd) '$(distuninstallcheck_dir)' || { \ + echo 'ERROR: cannot chdir into $(distuninstallcheck_dir)' >&2; \ + exit 1; \ + }; \ + test `$(am__distuninstallcheck_listfiles) | wc -l` -eq 0 \ + || { echo "ERROR: files left after uninstall:" ; \ + if test -n "$(DESTDIR)"; then \ + echo " (check DESTDIR support)"; \ + fi ; \ + $(distuninstallcheck_listfiles) ; \ + exit 1; } >&2 +distcleancheck: distclean + @if test '$(srcdir)' = . ; then \ + echo "ERROR: distcleancheck can only run from a VPATH build" ; \ + exit 1 ; \ + fi + @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ + || { echo "ERROR: files left in build directory after distclean:" ; \ + $(distcleancheck_listfiles) ; \ + exit 1; } >&2 +check-am: all-am +check: check-recursive +all-am: Makefile +installdirs: installdirs-recursive +installdirs-am: +install: install-recursive +install-exec: install-exec-recursive +install-data: install-data-recursive +uninstall: uninstall-recursive + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-recursive +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-recursive + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-recursive + -rm -f $(am__CONFIG_DISTCLEAN_FILES) + -rm -f Makefile +distclean-am: clean-am distclean-generic distclean-libtool \ + distclean-tags + +dvi: dvi-recursive + +dvi-am: + +html: html-recursive + +html-am: + +info: info-recursive + +info-am: + +install-data-am: + +install-dvi: install-dvi-recursive + +install-dvi-am: + +install-exec-am: + +install-html: install-html-recursive + +install-html-am: + +install-info: install-info-recursive + +install-info-am: + +install-man: + +install-pdf: install-pdf-recursive + +install-pdf-am: + +install-ps: install-ps-recursive + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-recursive + -rm -f $(am__CONFIG_DISTCLEAN_FILES) + -rm -rf $(top_srcdir)/autom4te.cache + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-recursive + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-recursive + +pdf-am: + +ps: ps-recursive + +ps-am: + +uninstall-am: + +.MAKE: $(am__recursive_targets) install-am install-strip + +.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \ + am--refresh check check-am clean clean-cscope clean-generic \ + clean-libtool cscope cscopelist-am ctags ctags-am dist \ + dist-all dist-bzip2 dist-gzip dist-lzip dist-shar dist-tarZ \ + dist-xz dist-zip distcheck distclean distclean-generic \ + distclean-libtool distclean-tags distcleancheck distdir \ + distuninstallcheck dvi dvi-am html html-am info info-am \ + install install-am install-data install-data-am install-dvi \ + install-dvi-am install-exec install-exec-am install-html \ + install-html-am install-info install-info-am install-man \ + install-pdf install-pdf-am install-ps install-ps-am \ + install-strip installcheck installcheck-am installdirs \ + installdirs-am maintainer-clean maintainer-clean-generic \ + mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ + ps ps-am tags tags-am uninstall uninstall-am + +.PRECIOUS: Makefile + + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/libs/ode-0.16.1/libccd/README b/libs/ode-0.16.1/libccd/README new file mode 100644 index 0000000..f363d6c --- /dev/null +++ b/libs/ode-0.16.1/libccd/README @@ -0,0 +1,72 @@ +libccd is library for a collision detection between two convex shapes. +libccd implements variation on Gilbert–Johnson–Keerthi algorithm plus Expand +Polytope Algorithm (EPA) and also implements algorithm Minkowski Portal +Refinement (MPR, a.k.a. XenoCollide) as described in Game Programming Gems 7. + +For more info see home of libccd: http://libccd.danfis.cz. + + +Dependencies +------------- +This library is currently based only on standard libraries. +The only exception are testsuites that are built on top of CU +(cu.danfis.cz) library licensed under LGPL, however only testing depends on +it and libccd library itself can be distributed without it. + + +License +-------- +libccd is licensed under OSI-approved 3-clause BSD License, text of license +is distributed along with source code in BSD-LICENSE file. +Each file should include license notice, the rest should be considered as +licensed under 3-clause BSD License. + + +Compile And Install +-------------------- +Simply type 'make' and 'make install' in src/ directory. + +Library libccd is by default compiled in double precision of floating point +numbers - you can controll this by options USE_SINGLE/USE_DOUBLE, i.e.: + $ make USE_SINGLE=yes +will compile library in single precision. + +Installation directory can be changed by options PREFIX, INCLUDEDIR and +LIBDIR. + +For more info type 'make help'. + + +Compile And Install Using Autotools +------------------------------------ +libccd also contains support for autotools: +1) Generate configure script etc.: $ ./bootstrap +2) Create new build/ directory: $ mkdir build && cd build +3) Run configure script: $ ../configure +4) Run make and make install: $ make && make install + +configure script can change the way libccd is compiled and installed, most +significant option is --enable-double-precision which enables double +precision (single is default in this case). + + +Usage +------ +See ccd.h for public API. +In your application include , setup ccd_t structure and run some +of functions (all functions are reentrant). Then link with libccd.a. + + +Directories +------------ +src/ + - contains source files of libccd. +src/testsuites + - testsuites - libccd must be compiled before compiling this. +src/testsuites/cu + - CU unit testing framework +src/testsuites/regressions + - files ready for regression tests + +doc/ + - some documentation. diff --git a/libs/ode-0.16.1/libccd/aclocal.m4 b/libs/ode-0.16.1/libccd/aclocal.m4 new file mode 100644 index 0000000..f7ad092 --- /dev/null +++ b/libs/ode-0.16.1/libccd/aclocal.m4 @@ -0,0 +1,10200 @@ +# generated automatically by aclocal 1.15 -*- Autoconf -*- + +# Copyright (C) 1996-2014 Free Software Foundation, Inc. + +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])]) +m4_ifndef([AC_AUTOCONF_VERSION], + [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl +m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],, +[m4_warning([this file was generated for autoconf 2.69. +You have another version of autoconf. It may work, but is not guaranteed to. +If you have problems, you may need to regenerate the build system entirely. +To do so, use the procedure documented by the package, typically 'autoreconf'.])]) + +# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- +# +# Copyright (C) 1996-2001, 2003-2015 Free Software Foundation, Inc. +# Written by Gordon Matzigkeit, 1996 +# +# This file is free software; the Free Software Foundation gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. + +m4_define([_LT_COPYING], [dnl +# Copyright (C) 2014 Free Software Foundation, Inc. +# This is free software; see the source for copying conditions. There is NO +# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + +# GNU Libtool is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of of the License, or +# (at your option) any later version. +# +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program or library that is built +# using GNU Libtool, you may include this file under the same +# distribution terms that you use for the rest of that program. +# +# GNU Libtool is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . +]) + +# serial 58 LT_INIT + + +# LT_PREREQ(VERSION) +# ------------------ +# Complain and exit if this libtool version is less that VERSION. +m4_defun([LT_PREREQ], +[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1, + [m4_default([$3], + [m4_fatal([Libtool version $1 or higher is required], + 63)])], + [$2])]) + + +# _LT_CHECK_BUILDDIR +# ------------------ +# Complain if the absolute build directory name contains unusual characters +m4_defun([_LT_CHECK_BUILDDIR], +[case `pwd` in + *\ * | *\ *) + AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;; +esac +]) + + +# LT_INIT([OPTIONS]) +# ------------------ +AC_DEFUN([LT_INIT], +[AC_PREREQ([2.62])dnl We use AC_PATH_PROGS_FEATURE_CHECK +AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl +AC_BEFORE([$0], [LT_LANG])dnl +AC_BEFORE([$0], [LT_OUTPUT])dnl +AC_BEFORE([$0], [LTDL_INIT])dnl +m4_require([_LT_CHECK_BUILDDIR])dnl + +dnl Autoconf doesn't catch unexpanded LT_ macros by default: +m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl +m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl +dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4 +dnl unless we require an AC_DEFUNed macro: +AC_REQUIRE([LTOPTIONS_VERSION])dnl +AC_REQUIRE([LTSUGAR_VERSION])dnl +AC_REQUIRE([LTVERSION_VERSION])dnl +AC_REQUIRE([LTOBSOLETE_VERSION])dnl +m4_require([_LT_PROG_LTMAIN])dnl + +_LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}]) + +dnl Parse OPTIONS +_LT_SET_OPTIONS([$0], [$1]) + +# This can be used to rebuild libtool when needed +LIBTOOL_DEPS=$ltmain + +# Always use our own libtool. +LIBTOOL='$(SHELL) $(top_builddir)/libtool' +AC_SUBST(LIBTOOL)dnl + +_LT_SETUP + +# Only expand once: +m4_define([LT_INIT]) +])# LT_INIT + +# Old names: +AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT]) +AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_PROG_LIBTOOL], []) +dnl AC_DEFUN([AM_PROG_LIBTOOL], []) + + +# _LT_PREPARE_CC_BASENAME +# ----------------------- +m4_defun([_LT_PREPARE_CC_BASENAME], [ +# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. +func_cc_basename () +{ + for cc_temp in @S|@*""; do + case $cc_temp in + compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; + distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; + \-*) ;; + *) break;; + esac + done + func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` +} +])# _LT_PREPARE_CC_BASENAME + + +# _LT_CC_BASENAME(CC) +# ------------------- +# It would be clearer to call AC_REQUIREs from _LT_PREPARE_CC_BASENAME, +# but that macro is also expanded into generated libtool script, which +# arranges for $SED and $ECHO to be set by different means. +m4_defun([_LT_CC_BASENAME], +[m4_require([_LT_PREPARE_CC_BASENAME])dnl +AC_REQUIRE([_LT_DECL_SED])dnl +AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl +func_cc_basename $1 +cc_basename=$func_cc_basename_result +]) + + +# _LT_FILEUTILS_DEFAULTS +# ---------------------- +# It is okay to use these file commands and assume they have been set +# sensibly after 'm4_require([_LT_FILEUTILS_DEFAULTS])'. +m4_defun([_LT_FILEUTILS_DEFAULTS], +[: ${CP="cp -f"} +: ${MV="mv -f"} +: ${RM="rm -f"} +])# _LT_FILEUTILS_DEFAULTS + + +# _LT_SETUP +# --------- +m4_defun([_LT_SETUP], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +AC_REQUIRE([AC_CANONICAL_BUILD])dnl +AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl +AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl + +_LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl +dnl +_LT_DECL([], [host_alias], [0], [The host system])dnl +_LT_DECL([], [host], [0])dnl +_LT_DECL([], [host_os], [0])dnl +dnl +_LT_DECL([], [build_alias], [0], [The build system])dnl +_LT_DECL([], [build], [0])dnl +_LT_DECL([], [build_os], [0])dnl +dnl +AC_REQUIRE([AC_PROG_CC])dnl +AC_REQUIRE([LT_PATH_LD])dnl +AC_REQUIRE([LT_PATH_NM])dnl +dnl +AC_REQUIRE([AC_PROG_LN_S])dnl +test -z "$LN_S" && LN_S="ln -s" +_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl +dnl +AC_REQUIRE([LT_CMD_MAX_LEN])dnl +_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl +_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl +dnl +m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_CHECK_SHELL_FEATURES])dnl +m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl +m4_require([_LT_CMD_RELOAD])dnl +m4_require([_LT_CHECK_MAGIC_METHOD])dnl +m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl +m4_require([_LT_CMD_OLD_ARCHIVE])dnl +m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl +m4_require([_LT_WITH_SYSROOT])dnl +m4_require([_LT_CMD_TRUNCATE])dnl + +_LT_CONFIG_LIBTOOL_INIT([ +# See if we are running on zsh, and set the options that allow our +# commands through without removal of \ escapes INIT. +if test -n "\${ZSH_VERSION+set}"; then + setopt NO_GLOB_SUBST +fi +]) +if test -n "${ZSH_VERSION+set}"; then + setopt NO_GLOB_SUBST +fi + +_LT_CHECK_OBJDIR + +m4_require([_LT_TAG_COMPILER])dnl + +case $host_os in +aix3*) + # AIX sometimes has problems with the GCC collect2 program. For some + # reason, if we set the COLLECT_NAMES environment variable, the problems + # vanish in a puff of smoke. + if test set != "${COLLECT_NAMES+set}"; then + COLLECT_NAMES= + export COLLECT_NAMES + fi + ;; +esac + +# Global variables: +ofile=libtool +can_build_shared=yes + +# All known linkers require a '.a' archive for static linking (except MSVC, +# which needs '.lib'). +libext=a + +with_gnu_ld=$lt_cv_prog_gnu_ld + +old_CC=$CC +old_CFLAGS=$CFLAGS + +# Set sane defaults for various variables +test -z "$CC" && CC=cc +test -z "$LTCC" && LTCC=$CC +test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS +test -z "$LD" && LD=ld +test -z "$ac_objext" && ac_objext=o + +_LT_CC_BASENAME([$compiler]) + +# Only perform the check for file, if the check method requires it +test -z "$MAGIC_CMD" && MAGIC_CMD=file +case $deplibs_check_method in +file_magic*) + if test "$file_magic_cmd" = '$MAGIC_CMD'; then + _LT_PATH_MAGIC + fi + ;; +esac + +# Use C for the default configuration in the libtool script +LT_SUPPORTED_TAG([CC]) +_LT_LANG_C_CONFIG +_LT_LANG_DEFAULT_CONFIG +_LT_CONFIG_COMMANDS +])# _LT_SETUP + + +# _LT_PREPARE_SED_QUOTE_VARS +# -------------------------- +# Define a few sed substitution that help us do robust quoting. +m4_defun([_LT_PREPARE_SED_QUOTE_VARS], +[# Backslashify metacharacters that are still active within +# double-quoted strings. +sed_quote_subst='s/\([["`$\\]]\)/\\\1/g' + +# Same as above, but do not quote variable references. +double_quote_subst='s/\([["`\\]]\)/\\\1/g' + +# Sed substitution to delay expansion of an escaped shell variable in a +# double_quote_subst'ed string. +delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' + +# Sed substitution to delay expansion of an escaped single quote. +delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' + +# Sed substitution to avoid accidental globbing in evaled expressions +no_glob_subst='s/\*/\\\*/g' +]) + +# _LT_PROG_LTMAIN +# --------------- +# Note that this code is called both from 'configure', and 'config.status' +# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, +# 'config.status' has no value for ac_aux_dir unless we are using Automake, +# so we pass a copy along to make sure it has a sensible value anyway. +m4_defun([_LT_PROG_LTMAIN], +[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl +_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) +ltmain=$ac_aux_dir/ltmain.sh +])# _LT_PROG_LTMAIN + + + +# So that we can recreate a full libtool script including additional +# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS +# in macros and then make a single call at the end using the 'libtool' +# label. + + +# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS]) +# ---------------------------------------- +# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later. +m4_define([_LT_CONFIG_LIBTOOL_INIT], +[m4_ifval([$1], + [m4_append([_LT_OUTPUT_LIBTOOL_INIT], + [$1 +])])]) + +# Initialize. +m4_define([_LT_OUTPUT_LIBTOOL_INIT]) + + +# _LT_CONFIG_LIBTOOL([COMMANDS]) +# ------------------------------ +# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later. +m4_define([_LT_CONFIG_LIBTOOL], +[m4_ifval([$1], + [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS], + [$1 +])])]) + +# Initialize. +m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS]) + + +# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS]) +# ----------------------------------------------------- +m4_defun([_LT_CONFIG_SAVE_COMMANDS], +[_LT_CONFIG_LIBTOOL([$1]) +_LT_CONFIG_LIBTOOL_INIT([$2]) +]) + + +# _LT_FORMAT_COMMENT([COMMENT]) +# ----------------------------- +# Add leading comment marks to the start of each line, and a trailing +# full-stop to the whole comment if one is not present already. +m4_define([_LT_FORMAT_COMMENT], +[m4_ifval([$1], [ +m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])], + [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.]) +)]) + + + + + +# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?]) +# ------------------------------------------------------------------- +# CONFIGNAME is the name given to the value in the libtool script. +# VARNAME is the (base) name used in the configure script. +# VALUE may be 0, 1 or 2 for a computed quote escaped value based on +# VARNAME. Any other value will be used directly. +m4_define([_LT_DECL], +[lt_if_append_uniq([lt_decl_varnames], [$2], [, ], + [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name], + [m4_ifval([$1], [$1], [$2])]) + lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3]) + m4_ifval([$4], + [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])]) + lt_dict_add_subkey([lt_decl_dict], [$2], + [tagged?], [m4_ifval([$5], [yes], [no])])]) +]) + + +# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION]) +# -------------------------------------------------------- +m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])]) + + +# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...]) +# ------------------------------------------------ +m4_define([lt_decl_tag_varnames], +[_lt_decl_filter([tagged?], [yes], $@)]) + + +# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..]) +# --------------------------------------------------------- +m4_define([_lt_decl_filter], +[m4_case([$#], + [0], [m4_fatal([$0: too few arguments: $#])], + [1], [m4_fatal([$0: too few arguments: $#: $1])], + [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)], + [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)], + [lt_dict_filter([lt_decl_dict], $@)])[]dnl +]) + + +# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...]) +# -------------------------------------------------- +m4_define([lt_decl_quote_varnames], +[_lt_decl_filter([value], [1], $@)]) + + +# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...]) +# --------------------------------------------------- +m4_define([lt_decl_dquote_varnames], +[_lt_decl_filter([value], [2], $@)]) + + +# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) +# --------------------------------------------------- +m4_define([lt_decl_varnames_tagged], +[m4_assert([$# <= 2])dnl +_$0(m4_quote(m4_default([$1], [[, ]])), + m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]), + m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))]) +m4_define([_lt_decl_varnames_tagged], +[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])]) + + +# lt_decl_all_varnames([SEPARATOR], [VARNAME1...]) +# ------------------------------------------------ +m4_define([lt_decl_all_varnames], +[_$0(m4_quote(m4_default([$1], [[, ]])), + m4_if([$2], [], + m4_quote(lt_decl_varnames), + m4_quote(m4_shift($@))))[]dnl +]) +m4_define([_lt_decl_all_varnames], +[lt_join($@, lt_decl_varnames_tagged([$1], + lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl +]) + + +# _LT_CONFIG_STATUS_DECLARE([VARNAME]) +# ------------------------------------ +# Quote a variable value, and forward it to 'config.status' so that its +# declaration there will have the same value as in 'configure'. VARNAME +# must have a single quote delimited value for this to work. +m4_define([_LT_CONFIG_STATUS_DECLARE], +[$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`']) + + +# _LT_CONFIG_STATUS_DECLARATIONS +# ------------------------------ +# We delimit libtool config variables with single quotes, so when +# we write them to config.status, we have to be sure to quote all +# embedded single quotes properly. In configure, this macro expands +# each variable declared with _LT_DECL (and _LT_TAGDECL) into: +# +# ='`$ECHO "$" | $SED "$delay_single_quote_subst"`' +m4_defun([_LT_CONFIG_STATUS_DECLARATIONS], +[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames), + [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])]) + + +# _LT_LIBTOOL_TAGS +# ---------------- +# Output comment and list of tags supported by the script +m4_defun([_LT_LIBTOOL_TAGS], +[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl +available_tags='_LT_TAGS'dnl +]) + + +# _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) +# ----------------------------------- +# Extract the dictionary values for VARNAME (optionally with TAG) and +# expand to a commented shell variable setting: +# +# # Some comment about what VAR is for. +# visible_name=$lt_internal_name +m4_define([_LT_LIBTOOL_DECLARE], +[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], + [description])))[]dnl +m4_pushdef([_libtool_name], + m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl +m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])), + [0], [_libtool_name=[$]$1], + [1], [_libtool_name=$lt_[]$1], + [2], [_libtool_name=$lt_[]$1], + [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl +m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl +]) + + +# _LT_LIBTOOL_CONFIG_VARS +# ----------------------- +# Produce commented declarations of non-tagged libtool config variables +# suitable for insertion in the LIBTOOL CONFIG section of the 'libtool' +# script. Tagged libtool config variables (even for the LIBTOOL CONFIG +# section) are produced by _LT_LIBTOOL_TAG_VARS. +m4_defun([_LT_LIBTOOL_CONFIG_VARS], +[m4_foreach([_lt_var], + m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)), + [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])]) + + +# _LT_LIBTOOL_TAG_VARS(TAG) +# ------------------------- +m4_define([_LT_LIBTOOL_TAG_VARS], +[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames), + [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])]) + + +# _LT_TAGVAR(VARNAME, [TAGNAME]) +# ------------------------------ +m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) + + +# _LT_CONFIG_COMMANDS +# ------------------- +# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of +# variables for single and double quote escaping we saved from calls +# to _LT_DECL, we can put quote escaped variables declarations +# into 'config.status', and then the shell code to quote escape them in +# for loops in 'config.status'. Finally, any additional code accumulated +# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. +m4_defun([_LT_CONFIG_COMMANDS], +[AC_PROVIDE_IFELSE([LT_OUTPUT], + dnl If the libtool generation code has been placed in $CONFIG_LT, + dnl instead of duplicating it all over again into config.status, + dnl then we will have config.status run $CONFIG_LT later, so it + dnl needs to know what name is stored there: + [AC_CONFIG_COMMANDS([libtool], + [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])], + dnl If the libtool generation code is destined for config.status, + dnl expand the accumulated commands and init code now: + [AC_CONFIG_COMMANDS([libtool], + [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])]) +])#_LT_CONFIG_COMMANDS + + +# Initialize. +m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT], +[ + +# The HP-UX ksh and POSIX shell print the target directory to stdout +# if CDPATH is set. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + +sed_quote_subst='$sed_quote_subst' +double_quote_subst='$double_quote_subst' +delay_variable_subst='$delay_variable_subst' +_LT_CONFIG_STATUS_DECLARATIONS +LTCC='$LTCC' +LTCFLAGS='$LTCFLAGS' +compiler='$compiler_DEFAULT' + +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +\$[]1 +_LTECHO_EOF' +} + +# Quote evaled strings. +for var in lt_decl_all_varnames([[ \ +]], lt_decl_quote_varnames); do + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in + *[[\\\\\\\`\\"\\\$]]*) + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes + ;; + *) + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" + ;; + esac +done + +# Double-quote double-evaled strings. +for var in lt_decl_all_varnames([[ \ +]], lt_decl_dquote_varnames); do + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in + *[[\\\\\\\`\\"\\\$]]*) + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes + ;; + *) + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" + ;; + esac +done + +_LT_OUTPUT_LIBTOOL_INIT +]) + +# _LT_GENERATED_FILE_INIT(FILE, [COMMENT]) +# ------------------------------------ +# Generate a child script FILE with all initialization necessary to +# reuse the environment learned by the parent script, and make the +# file executable. If COMMENT is supplied, it is inserted after the +# '#!' sequence but before initialization text begins. After this +# macro, additional text can be appended to FILE to form the body of +# the child script. The macro ends with non-zero status if the +# file could not be fully written (such as if the disk is full). +m4_ifdef([AS_INIT_GENERATED], +[m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])], +[m4_defun([_LT_GENERATED_FILE_INIT], +[m4_require([AS_PREPARE])]dnl +[m4_pushdef([AS_MESSAGE_LOG_FD])]dnl +[lt_write_fail=0 +cat >$1 <<_ASEOF || lt_write_fail=1 +#! $SHELL +# Generated by $as_me. +$2 +SHELL=\${CONFIG_SHELL-$SHELL} +export SHELL +_ASEOF +cat >>$1 <<\_ASEOF || lt_write_fail=1 +AS_SHELL_SANITIZE +_AS_PREPARE +exec AS_MESSAGE_FD>&1 +_ASEOF +test 0 = "$lt_write_fail" && chmod +x $1[]dnl +m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT + +# LT_OUTPUT +# --------- +# This macro allows early generation of the libtool script (before +# AC_OUTPUT is called), incase it is used in configure for compilation +# tests. +AC_DEFUN([LT_OUTPUT], +[: ${CONFIG_LT=./config.lt} +AC_MSG_NOTICE([creating $CONFIG_LT]) +_LT_GENERATED_FILE_INIT(["$CONFIG_LT"], +[# Run this file to recreate a libtool stub with the current configuration.]) + +cat >>"$CONFIG_LT" <<\_LTEOF +lt_cl_silent=false +exec AS_MESSAGE_LOG_FD>>config.log +{ + echo + AS_BOX([Running $as_me.]) +} >&AS_MESSAGE_LOG_FD + +lt_cl_help="\ +'$as_me' creates a local libtool stub from the current configuration, +for use in further configure time tests before the real libtool is +generated. + +Usage: $[0] [[OPTIONS]] + + -h, --help print this help, then exit + -V, --version print version number, then exit + -q, --quiet do not print progress messages + -d, --debug don't remove temporary files + +Report bugs to ." + +lt_cl_version="\ +m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl +m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) +configured by $[0], generated by m4_PACKAGE_STRING. + +Copyright (C) 2011 Free Software Foundation, Inc. +This config.lt script is free software; the Free Software Foundation +gives unlimited permision to copy, distribute and modify it." + +while test 0 != $[#] +do + case $[1] in + --version | --v* | -V ) + echo "$lt_cl_version"; exit 0 ;; + --help | --h* | -h ) + echo "$lt_cl_help"; exit 0 ;; + --debug | --d* | -d ) + debug=: ;; + --quiet | --q* | --silent | --s* | -q ) + lt_cl_silent=: ;; + + -*) AC_MSG_ERROR([unrecognized option: $[1] +Try '$[0] --help' for more information.]) ;; + + *) AC_MSG_ERROR([unrecognized argument: $[1] +Try '$[0] --help' for more information.]) ;; + esac + shift +done + +if $lt_cl_silent; then + exec AS_MESSAGE_FD>/dev/null +fi +_LTEOF + +cat >>"$CONFIG_LT" <<_LTEOF +_LT_OUTPUT_LIBTOOL_COMMANDS_INIT +_LTEOF + +cat >>"$CONFIG_LT" <<\_LTEOF +AC_MSG_NOTICE([creating $ofile]) +_LT_OUTPUT_LIBTOOL_COMMANDS +AS_EXIT(0) +_LTEOF +chmod +x "$CONFIG_LT" + +# configure is writing to config.log, but config.lt does its own redirection, +# appending to config.log, which fails on DOS, as config.log is still kept +# open by configure. Here we exec the FD to /dev/null, effectively closing +# config.log, so it can be properly (re)opened and appended to by config.lt. +lt_cl_success=: +test yes = "$silent" && + lt_config_lt_args="$lt_config_lt_args --quiet" +exec AS_MESSAGE_LOG_FD>/dev/null +$SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false +exec AS_MESSAGE_LOG_FD>>config.log +$lt_cl_success || AS_EXIT(1) +])# LT_OUTPUT + + +# _LT_CONFIG(TAG) +# --------------- +# If TAG is the built-in tag, create an initial libtool script with a +# default configuration from the untagged config vars. Otherwise add code +# to config.status for appending the configuration named by TAG from the +# matching tagged config vars. +m4_defun([_LT_CONFIG], +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl +_LT_CONFIG_SAVE_COMMANDS([ + m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl + m4_if(_LT_TAG, [C], [ + # See if we are running on zsh, and set the options that allow our + # commands through without removal of \ escapes. + if test -n "${ZSH_VERSION+set}"; then + setopt NO_GLOB_SUBST + fi + + cfgfile=${ofile}T + trap "$RM \"$cfgfile\"; exit 1" 1 2 15 + $RM "$cfgfile" + + cat <<_LT_EOF >> "$cfgfile" +#! $SHELL +# Generated automatically by $as_me ($PACKAGE) $VERSION +# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +# NOTE: Changes made to this file will be lost: look at ltmain.sh. + +# Provide generalized library-building support services. +# Written by Gordon Matzigkeit, 1996 + +_LT_COPYING +_LT_LIBTOOL_TAGS + +# Configured defaults for sys_lib_dlsearch_path munging. +: \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"} + +# ### BEGIN LIBTOOL CONFIG +_LT_LIBTOOL_CONFIG_VARS +_LT_LIBTOOL_TAG_VARS +# ### END LIBTOOL CONFIG + +_LT_EOF + + cat <<'_LT_EOF' >> "$cfgfile" + +# ### BEGIN FUNCTIONS SHARED WITH CONFIGURE + +_LT_PREPARE_MUNGE_PATH_LIST +_LT_PREPARE_CC_BASENAME + +# ### END FUNCTIONS SHARED WITH CONFIGURE + +_LT_EOF + + case $host_os in + aix3*) + cat <<\_LT_EOF >> "$cfgfile" +# AIX sometimes has problems with the GCC collect2 program. For some +# reason, if we set the COLLECT_NAMES environment variable, the problems +# vanish in a puff of smoke. +if test set != "${COLLECT_NAMES+set}"; then + COLLECT_NAMES= + export COLLECT_NAMES +fi +_LT_EOF + ;; + esac + + _LT_PROG_LTMAIN + + # We use sed instead of cat because bash on DJGPP gets confused if + # if finds mixed CR/LF and LF-only lines. Since sed operates in + # text mode, it properly converts lines to CR/LF. This bash problem + # is reportedly fixed, but why not run on old versions too? + sed '$q' "$ltmain" >> "$cfgfile" \ + || (rm -f "$cfgfile"; exit 1) + + mv -f "$cfgfile" "$ofile" || + (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") + chmod +x "$ofile" +], +[cat <<_LT_EOF >> "$ofile" + +dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded +dnl in a comment (ie after a #). +# ### BEGIN LIBTOOL TAG CONFIG: $1 +_LT_LIBTOOL_TAG_VARS(_LT_TAG) +# ### END LIBTOOL TAG CONFIG: $1 +_LT_EOF +])dnl /m4_if +], +[m4_if([$1], [], [ + PACKAGE='$PACKAGE' + VERSION='$VERSION' + RM='$RM' + ofile='$ofile'], []) +])dnl /_LT_CONFIG_SAVE_COMMANDS +])# _LT_CONFIG + + +# LT_SUPPORTED_TAG(TAG) +# --------------------- +# Trace this macro to discover what tags are supported by the libtool +# --tag option, using: +# autoconf --trace 'LT_SUPPORTED_TAG:$1' +AC_DEFUN([LT_SUPPORTED_TAG], []) + + +# C support is built-in for now +m4_define([_LT_LANG_C_enabled], []) +m4_define([_LT_TAGS], []) + + +# LT_LANG(LANG) +# ------------- +# Enable libtool support for the given language if not already enabled. +AC_DEFUN([LT_LANG], +[AC_BEFORE([$0], [LT_OUTPUT])dnl +m4_case([$1], + [C], [_LT_LANG(C)], + [C++], [_LT_LANG(CXX)], + [Go], [_LT_LANG(GO)], + [Java], [_LT_LANG(GCJ)], + [Fortran 77], [_LT_LANG(F77)], + [Fortran], [_LT_LANG(FC)], + [Windows Resource], [_LT_LANG(RC)], + [m4_ifdef([_LT_LANG_]$1[_CONFIG], + [_LT_LANG($1)], + [m4_fatal([$0: unsupported language: "$1"])])])dnl +])# LT_LANG + + +# _LT_LANG(LANGNAME) +# ------------------ +m4_defun([_LT_LANG], +[m4_ifdef([_LT_LANG_]$1[_enabled], [], + [LT_SUPPORTED_TAG([$1])dnl + m4_append([_LT_TAGS], [$1 ])dnl + m4_define([_LT_LANG_]$1[_enabled], [])dnl + _LT_LANG_$1_CONFIG($1)])dnl +])# _LT_LANG + + +m4_ifndef([AC_PROG_GO], [ +# NOTE: This macro has been submitted for inclusion into # +# GNU Autoconf as AC_PROG_GO. When it is available in # +# a released version of Autoconf we should remove this # +# macro and use it instead. # +m4_defun([AC_PROG_GO], +[AC_LANG_PUSH(Go)dnl +AC_ARG_VAR([GOC], [Go compiler command])dnl +AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl +_AC_ARG_VAR_LDFLAGS()dnl +AC_CHECK_TOOL(GOC, gccgo) +if test -z "$GOC"; then + if test -n "$ac_tool_prefix"; then + AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo]) + fi +fi +if test -z "$GOC"; then + AC_CHECK_PROG(GOC, gccgo, gccgo, false) +fi +])#m4_defun +])#m4_ifndef + + +# _LT_LANG_DEFAULT_CONFIG +# ----------------------- +m4_defun([_LT_LANG_DEFAULT_CONFIG], +[AC_PROVIDE_IFELSE([AC_PROG_CXX], + [LT_LANG(CXX)], + [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])]) + +AC_PROVIDE_IFELSE([AC_PROG_F77], + [LT_LANG(F77)], + [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])]) + +AC_PROVIDE_IFELSE([AC_PROG_FC], + [LT_LANG(FC)], + [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])]) + +dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal +dnl pulling things in needlessly. +AC_PROVIDE_IFELSE([AC_PROG_GCJ], + [LT_LANG(GCJ)], + [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], + [LT_LANG(GCJ)], + [AC_PROVIDE_IFELSE([LT_PROG_GCJ], + [LT_LANG(GCJ)], + [m4_ifdef([AC_PROG_GCJ], + [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])]) + m4_ifdef([A][M_PROG_GCJ], + [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])]) + m4_ifdef([LT_PROG_GCJ], + [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])]) + +AC_PROVIDE_IFELSE([AC_PROG_GO], + [LT_LANG(GO)], + [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])]) + +AC_PROVIDE_IFELSE([LT_PROG_RC], + [LT_LANG(RC)], + [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])]) +])# _LT_LANG_DEFAULT_CONFIG + +# Obsolete macros: +AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)]) +AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)]) +AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)]) +AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)]) +AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_CXX], []) +dnl AC_DEFUN([AC_LIBTOOL_F77], []) +dnl AC_DEFUN([AC_LIBTOOL_FC], []) +dnl AC_DEFUN([AC_LIBTOOL_GCJ], []) +dnl AC_DEFUN([AC_LIBTOOL_RC], []) + + +# _LT_TAG_COMPILER +# ---------------- +m4_defun([_LT_TAG_COMPILER], +[AC_REQUIRE([AC_PROG_CC])dnl + +_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl +_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl +_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl +_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl + +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} + +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC +])# _LT_TAG_COMPILER + + +# _LT_COMPILER_BOILERPLATE +# ------------------------ +# Check for compiler boilerplate output or warnings with +# the simple compiler test code. +m4_defun([_LT_COMPILER_BOILERPLATE], +[m4_require([_LT_DECL_SED])dnl +ac_outfile=conftest.$ac_objext +echo "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$RM conftest* +])# _LT_COMPILER_BOILERPLATE + + +# _LT_LINKER_BOILERPLATE +# ---------------------- +# Check for linker boilerplate output or warnings with +# the simple link test code. +m4_defun([_LT_LINKER_BOILERPLATE], +[m4_require([_LT_DECL_SED])dnl +ac_outfile=conftest.$ac_objext +echo "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$RM -r conftest* +])# _LT_LINKER_BOILERPLATE + +# _LT_REQUIRED_DARWIN_CHECKS +# ------------------------- +m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ + case $host_os in + rhapsody* | darwin*) + AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) + AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) + AC_CHECK_TOOL([LIPO], [lipo], [:]) + AC_CHECK_TOOL([OTOOL], [otool], [:]) + AC_CHECK_TOOL([OTOOL64], [otool64], [:]) + _LT_DECL([], [DSYMUTIL], [1], + [Tool to manipulate archived DWARF debug symbol files on Mac OS X]) + _LT_DECL([], [NMEDIT], [1], + [Tool to change global to local symbols on Mac OS X]) + _LT_DECL([], [LIPO], [1], + [Tool to manipulate fat objects and archives on Mac OS X]) + _LT_DECL([], [OTOOL], [1], + [ldd/readelf like tool for Mach-O binaries on Mac OS X]) + _LT_DECL([], [OTOOL64], [1], + [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4]) + + AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], + [lt_cv_apple_cc_single_mod=no + if test -z "$LT_MULTI_MODULE"; then + # By default we will add the -single_module flag. You can override + # by either setting the environment variable LT_MULTI_MODULE + # non-empty at configure time, or by adding -multi_module to the + # link flags. + rm -rf libconftest.dylib* + echo "int foo(void){return 1;}" > conftest.c + echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ +-dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD + $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ + -dynamiclib -Wl,-single_module conftest.c 2>conftest.err + _lt_result=$? + # If there is a non-empty error log, and "single_module" + # appears in it, assume the flag caused a linker warning + if test -s conftest.err && $GREP single_module conftest.err; then + cat conftest.err >&AS_MESSAGE_LOG_FD + # Otherwise, if the output was created with a 0 exit code from + # the compiler, it worked. + elif test -f libconftest.dylib && test 0 = "$_lt_result"; then + lt_cv_apple_cc_single_mod=yes + else + cat conftest.err >&AS_MESSAGE_LOG_FD + fi + rm -rf libconftest.dylib* + rm -f conftest.* + fi]) + + AC_CACHE_CHECK([for -exported_symbols_list linker flag], + [lt_cv_ld_exported_symbols_list], + [lt_cv_ld_exported_symbols_list=no + save_LDFLAGS=$LDFLAGS + echo "_main" > conftest.sym + LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" + AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], + [lt_cv_ld_exported_symbols_list=yes], + [lt_cv_ld_exported_symbols_list=no]) + LDFLAGS=$save_LDFLAGS + ]) + + AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], + [lt_cv_ld_force_load=no + cat > conftest.c << _LT_EOF +int forced_loaded() { return 2;} +_LT_EOF + echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD + $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD + echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD + $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD + echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD + $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD + cat > conftest.c << _LT_EOF +int main() { return 0;} +_LT_EOF + echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD + $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err + _lt_result=$? + if test -s conftest.err && $GREP force_load conftest.err; then + cat conftest.err >&AS_MESSAGE_LOG_FD + elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then + lt_cv_ld_force_load=yes + else + cat conftest.err >&AS_MESSAGE_LOG_FD + fi + rm -f conftest.err libconftest.a conftest conftest.c + rm -rf conftest.dSYM + ]) + case $host_os in + rhapsody* | darwin1.[[012]]) + _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; + darwin1.*) + _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; + darwin*) # darwin 5.x on + # if running on 10.5 or later, the deployment target defaults + # to the OS version, if on x86, and 10.4, the deployment + # target defaults to 10.4. Don't you love it? + case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in + 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) + _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; + 10.[[012]][[,.]]*) + _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; + 10.*) + _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; + esac + ;; + esac + if test yes = "$lt_cv_apple_cc_single_mod"; then + _lt_dar_single_mod='$single_module' + fi + if test yes = "$lt_cv_ld_exported_symbols_list"; then + _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym' + else + _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib' + fi + if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then + _lt_dsymutil='~$DSYMUTIL $lib || :' + else + _lt_dsymutil= + fi + ;; + esac +]) + + +# _LT_DARWIN_LINKER_FEATURES([TAG]) +# --------------------------------- +# Checks for linker and compiler features on darwin +m4_defun([_LT_DARWIN_LINKER_FEATURES], +[ + m4_require([_LT_REQUIRED_DARWIN_CHECKS]) + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_automatic, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported + if test yes = "$lt_cv_ld_force_load"; then + _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' + m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes], + [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes]) + else + _LT_TAGVAR(whole_archive_flag_spec, $1)='' + fi + _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(allow_undefined_flag, $1)=$_lt_dar_allow_undefined + case $cc_basename in + ifort*|nagfor*) _lt_dar_can_shared=yes ;; + *) _lt_dar_can_shared=$GCC ;; + esac + if test yes = "$_lt_dar_can_shared"; then + output_verbose_link_cmd=func_echo_all + _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" + _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" + _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" + _LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" + m4_if([$1], [CXX], +[ if test yes != "$lt_cv_apple_cc_single_mod"; then + _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dsymutil" + _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil" + fi +],[]) + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi +]) + +# _LT_SYS_MODULE_PATH_AIX([TAGNAME]) +# ---------------------------------- +# Links a minimal program and checks the executable +# for the system default hardcoded library path. In most cases, +# this is /usr/lib:/lib, but when the MPI compilers are used +# the location of the communication and MPI libs are included too. +# If we don't find anything, use the default library path according +# to the aix ld manual. +# Store the results from the different compilers for each TAGNAME. +# Allow to override them for all tags through lt_cv_aix_libpath. +m4_defun([_LT_SYS_MODULE_PATH_AIX], +[m4_require([_LT_DECL_SED])dnl +if test set = "${lt_cv_aix_libpath+set}"; then + aix_libpath=$lt_cv_aix_libpath +else + AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])], + [AC_LINK_IFELSE([AC_LANG_PROGRAM],[ + lt_aix_libpath_sed='[ + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }]' + _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then + _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi],[]) + if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then + _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=/usr/lib:/lib + fi + ]) + aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1]) +fi +])# _LT_SYS_MODULE_PATH_AIX + + +# _LT_SHELL_INIT(ARG) +# ------------------- +m4_define([_LT_SHELL_INIT], +[m4_divert_text([M4SH-INIT], [$1 +])])# _LT_SHELL_INIT + + + +# _LT_PROG_ECHO_BACKSLASH +# ----------------------- +# Find how we can fake an echo command that does not interpret backslash. +# In particular, with Autoconf 2.60 or later we add some code to the start +# of the generated configure script that will find a shell with a builtin +# printf (that we can use as an echo command). +m4_defun([_LT_PROG_ECHO_BACKSLASH], +[ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO + +AC_MSG_CHECKING([how to print strings]) +# Test print first, because it will be a builtin if present. +if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ + test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='print -r --' +elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='printf %s\n' +else + # Use this function as a fallback that always works. + func_fallback_echo () + { + eval 'cat <<_LTECHO_EOF +$[]1 +_LTECHO_EOF' + } + ECHO='func_fallback_echo' +fi + +# func_echo_all arg... +# Invoke $ECHO with all args, space-separated. +func_echo_all () +{ + $ECHO "$*" +} + +case $ECHO in + printf*) AC_MSG_RESULT([printf]) ;; + print*) AC_MSG_RESULT([print -r]) ;; + *) AC_MSG_RESULT([cat]) ;; +esac + +m4_ifdef([_AS_DETECT_SUGGESTED], +[_AS_DETECT_SUGGESTED([ + test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || ( + ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' + ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO + ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO + PATH=/empty FPATH=/empty; export PATH FPATH + test "X`printf %s $ECHO`" = "X$ECHO" \ + || test "X`print -r -- $ECHO`" = "X$ECHO" )])]) + +_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts]) +_LT_DECL([], [ECHO], [1], [An echo program that protects backslashes]) +])# _LT_PROG_ECHO_BACKSLASH + + +# _LT_WITH_SYSROOT +# ---------------- +AC_DEFUN([_LT_WITH_SYSROOT], +[AC_MSG_CHECKING([for sysroot]) +AC_ARG_WITH([sysroot], +[AS_HELP_STRING([--with-sysroot@<:@=DIR@:>@], + [Search for dependent libraries within DIR (or the compiler's sysroot + if not specified).])], +[], [with_sysroot=no]) + +dnl lt_sysroot will always be passed unquoted. We quote it here +dnl in case the user passed a directory name. +lt_sysroot= +case $with_sysroot in #( + yes) + if test yes = "$GCC"; then + lt_sysroot=`$CC --print-sysroot 2>/dev/null` + fi + ;; #( + /*) + lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` + ;; #( + no|'') + ;; #( + *) + AC_MSG_RESULT([$with_sysroot]) + AC_MSG_ERROR([The sysroot must be an absolute path.]) + ;; +esac + + AC_MSG_RESULT([${lt_sysroot:-no}]) +_LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl +[dependent libraries, and where our libraries should be installed.])]) + +# _LT_ENABLE_LOCK +# --------------- +m4_defun([_LT_ENABLE_LOCK], +[AC_ARG_ENABLE([libtool-lock], + [AS_HELP_STRING([--disable-libtool-lock], + [avoid locking (might break parallel builds)])]) +test no = "$enable_libtool_lock" || enable_libtool_lock=yes + +# Some flags need to be propagated to the compiler or linker for good +# libtool support. +case $host in +ia64-*-hpux*) + # Find out what ABI is being produced by ac_compile, and set mode + # options accordingly. + echo 'int i;' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + case `/usr/bin/file conftest.$ac_objext` in + *ELF-32*) + HPUX_IA64_MODE=32 + ;; + *ELF-64*) + HPUX_IA64_MODE=64 + ;; + esac + fi + rm -rf conftest* + ;; +*-*-irix6*) + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. + echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + if test yes = "$lt_cv_prog_gnu_ld"; then + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -melf32bsmip" + ;; + *N32*) + LD="${LD-ld} -melf32bmipn32" + ;; + *64-bit*) + LD="${LD-ld} -melf64bmip" + ;; + esac + else + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -32" + ;; + *N32*) + LD="${LD-ld} -n32" + ;; + *64-bit*) + LD="${LD-ld} -64" + ;; + esac + fi + fi + rm -rf conftest* + ;; + +mips64*-*linux*) + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. + echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + emul=elf + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + emul="${emul}32" + ;; + *64-bit*) + emul="${emul}64" + ;; + esac + case `/usr/bin/file conftest.$ac_objext` in + *MSB*) + emul="${emul}btsmip" + ;; + *LSB*) + emul="${emul}ltsmip" + ;; + esac + case `/usr/bin/file conftest.$ac_objext` in + *N32*) + emul="${emul}n32" + ;; + esac + LD="${LD-ld} -m $emul" + fi + rm -rf conftest* + ;; + +x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ +s390*-*linux*|s390*-*tpf*|sparc*-*linux*) + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. Note that the listed cases only cover the + # situations where additional linker options are needed (such as when + # doing 32-bit compilation for a host where ld defaults to 64-bit, or + # vice versa); the common cases where no linker options are needed do + # not appear in the list. + echo 'int i;' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + case `/usr/bin/file conftest.o` in + *32-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_i386_fbsd" + ;; + x86_64-*linux*) + case `/usr/bin/file conftest.o` in + *x86-64*) + LD="${LD-ld} -m elf32_x86_64" + ;; + *) + LD="${LD-ld} -m elf_i386" + ;; + esac + ;; + powerpc64le-*linux*) + LD="${LD-ld} -m elf32lppclinux" + ;; + powerpc64-*linux*) + LD="${LD-ld} -m elf32ppclinux" + ;; + s390x-*linux*) + LD="${LD-ld} -m elf_s390" + ;; + sparc64-*linux*) + LD="${LD-ld} -m elf32_sparc" + ;; + esac + ;; + *64-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_x86_64_fbsd" + ;; + x86_64-*linux*) + LD="${LD-ld} -m elf_x86_64" + ;; + powerpcle-*linux*) + LD="${LD-ld} -m elf64lppc" + ;; + powerpc-*linux*) + LD="${LD-ld} -m elf64ppc" + ;; + s390*-*linux*|s390*-*tpf*) + LD="${LD-ld} -m elf64_s390" + ;; + sparc*-*linux*) + LD="${LD-ld} -m elf64_sparc" + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; + +*-*-sco3.2v5*) + # On SCO OpenServer 5, we need -belf to get full-featured binaries. + SAVE_CFLAGS=$CFLAGS + CFLAGS="$CFLAGS -belf" + AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, + [AC_LANG_PUSH(C) + AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) + AC_LANG_POP]) + if test yes != "$lt_cv_cc_needs_belf"; then + # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf + CFLAGS=$SAVE_CFLAGS + fi + ;; +*-*solaris*) + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. + echo 'int i;' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + case `/usr/bin/file conftest.o` in + *64-bit*) + case $lt_cv_prog_gnu_ld in + yes*) + case $host in + i?86-*-solaris*|x86_64-*-solaris*) + LD="${LD-ld} -m elf_x86_64" + ;; + sparc*-*-solaris*) + LD="${LD-ld} -m elf64_sparc" + ;; + esac + # GNU ld 2.21 introduced _sol2 emulations. Use them if available. + if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then + LD=${LD-ld}_sol2 + fi + ;; + *) + if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then + LD="${LD-ld} -64" + fi + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; +esac + +need_locks=$enable_libtool_lock +])# _LT_ENABLE_LOCK + + +# _LT_PROG_AR +# ----------- +m4_defun([_LT_PROG_AR], +[AC_CHECK_TOOLS(AR, [ar], false) +: ${AR=ar} +: ${AR_FLAGS=cru} +_LT_DECL([], [AR], [1], [The archiver]) +_LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive]) + +AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], + [lt_cv_ar_at_file=no + AC_COMPILE_IFELSE([AC_LANG_PROGRAM], + [echo conftest.$ac_objext > conftest.lst + lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD' + AC_TRY_EVAL([lt_ar_try]) + if test 0 -eq "$ac_status"; then + # Ensure the archiver fails upon bogus file names. + rm -f conftest.$ac_objext libconftest.a + AC_TRY_EVAL([lt_ar_try]) + if test 0 -ne "$ac_status"; then + lt_cv_ar_at_file=@ + fi + fi + rm -f conftest.* libconftest.a + ]) + ]) + +if test no = "$lt_cv_ar_at_file"; then + archiver_list_spec= +else + archiver_list_spec=$lt_cv_ar_at_file +fi +_LT_DECL([], [archiver_list_spec], [1], + [How to feed a file listing to the archiver]) +])# _LT_PROG_AR + + +# _LT_CMD_OLD_ARCHIVE +# ------------------- +m4_defun([_LT_CMD_OLD_ARCHIVE], +[_LT_PROG_AR + +AC_CHECK_TOOL(STRIP, strip, :) +test -z "$STRIP" && STRIP=: +_LT_DECL([], [STRIP], [1], [A symbol stripping program]) + +AC_CHECK_TOOL(RANLIB, ranlib, :) +test -z "$RANLIB" && RANLIB=: +_LT_DECL([], [RANLIB], [1], + [Commands used to install an old-style archive]) + +# Determine commands to create old-style static archives. +old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' +old_postinstall_cmds='chmod 644 $oldlib' +old_postuninstall_cmds= + +if test -n "$RANLIB"; then + case $host_os in + bitrig* | openbsd*) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" + ;; + *) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" + ;; + esac + old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" +fi + +case $host_os in + darwin*) + lock_old_archive_extraction=yes ;; + *) + lock_old_archive_extraction=no ;; +esac +_LT_DECL([], [old_postinstall_cmds], [2]) +_LT_DECL([], [old_postuninstall_cmds], [2]) +_LT_TAGDECL([], [old_archive_cmds], [2], + [Commands used to build an old-style archive]) +_LT_DECL([], [lock_old_archive_extraction], [0], + [Whether to use a lock for old archive extraction]) +])# _LT_CMD_OLD_ARCHIVE + + +# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, +# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) +# ---------------------------------------------------------------- +# Check whether the given compiler option works +AC_DEFUN([_LT_COMPILER_OPTION], +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_DECL_SED])dnl +AC_CACHE_CHECK([$1], [$2], + [$2=no + m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$3" ## exclude from sc_useless_quotes_in_assignment + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&AS_MESSAGE_LOG_FD + echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + $2=yes + fi + fi + $RM conftest* +]) + +if test yes = "[$]$2"; then + m4_if([$5], , :, [$5]) +else + m4_if([$6], , :, [$6]) +fi +])# _LT_COMPILER_OPTION + +# Old name: +AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) + + +# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, +# [ACTION-SUCCESS], [ACTION-FAILURE]) +# ---------------------------------------------------- +# Check whether the given linker option works +AC_DEFUN([_LT_LINKER_OPTION], +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_DECL_SED])dnl +AC_CACHE_CHECK([$1], [$2], + [$2=no + save_LDFLAGS=$LDFLAGS + LDFLAGS="$LDFLAGS $3" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&AS_MESSAGE_LOG_FD + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + $2=yes + fi + else + $2=yes + fi + fi + $RM -r conftest* + LDFLAGS=$save_LDFLAGS +]) + +if test yes = "[$]$2"; then + m4_if([$4], , :, [$4]) +else + m4_if([$5], , :, [$5]) +fi +])# _LT_LINKER_OPTION + +# Old name: +AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) + + +# LT_CMD_MAX_LEN +#--------------- +AC_DEFUN([LT_CMD_MAX_LEN], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +# find the maximum length of command line arguments +AC_MSG_CHECKING([the maximum length of command line arguments]) +AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl + i=0 + teststring=ABCD + + case $build_os in + msdosdjgpp*) + # On DJGPP, this test can blow up pretty badly due to problems in libc + # (any single argument exceeding 2000 bytes causes a buffer overrun + # during glob expansion). Even if it were fixed, the result of this + # check would be larger than it should be. + lt_cv_sys_max_cmd_len=12288; # 12K is about right + ;; + + gnu*) + # Under GNU Hurd, this test is not required because there is + # no limit to the length of command line arguments. + # Libtool will interpret -1 as no limit whatsoever + lt_cv_sys_max_cmd_len=-1; + ;; + + cygwin* | mingw* | cegcc*) + # On Win9x/ME, this test blows up -- it succeeds, but takes + # about 5 minutes as the teststring grows exponentially. + # Worse, since 9x/ME are not pre-emptively multitasking, + # you end up with a "frozen" computer, even though with patience + # the test eventually succeeds (with a max line length of 256k). + # Instead, let's just punt: use the minimum linelength reported by + # all of the supported platforms: 8192 (on NT/2K/XP). + lt_cv_sys_max_cmd_len=8192; + ;; + + mint*) + # On MiNT this can take a long time and run out of memory. + lt_cv_sys_max_cmd_len=8192; + ;; + + amigaos*) + # On AmigaOS with pdksh, this test takes hours, literally. + # So we just punt and use a minimum line length of 8192. + lt_cv_sys_max_cmd_len=8192; + ;; + + bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*) + # This has been around since 386BSD, at least. Likely further. + if test -x /sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` + elif test -x /usr/sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` + else + lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs + fi + # And add a safety zone + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + ;; + + interix*) + # We know the value 262144 and hardcode it with a safety zone (like BSD) + lt_cv_sys_max_cmd_len=196608 + ;; + + os2*) + # The test takes a long time on OS/2. + lt_cv_sys_max_cmd_len=8192 + ;; + + osf*) + # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure + # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not + # nice to cause kernel panics so lets avoid the loop below. + # First set a reasonable default. + lt_cv_sys_max_cmd_len=16384 + # + if test -x /sbin/sysconfig; then + case `/sbin/sysconfig -q proc exec_disable_arg_limit` in + *1*) lt_cv_sys_max_cmd_len=-1 ;; + esac + fi + ;; + sco3.2v5*) + lt_cv_sys_max_cmd_len=102400 + ;; + sysv5* | sco5v6* | sysv4.2uw2*) + kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` + if test -n "$kargmax"; then + lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` + else + lt_cv_sys_max_cmd_len=32768 + fi + ;; + *) + lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` + if test -n "$lt_cv_sys_max_cmd_len" && \ + test undefined != "$lt_cv_sys_max_cmd_len"; then + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + else + # Make teststring a little bigger before we do anything with it. + # a 1K string should be a reasonable start. + for i in 1 2 3 4 5 6 7 8; do + teststring=$teststring$teststring + done + SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} + # If test is not a shell built-in, we'll probably end up computing a + # maximum length that is only half of the actual maximum length, but + # we can't tell. + while { test X`env echo "$teststring$teststring" 2>/dev/null` \ + = "X$teststring$teststring"; } >/dev/null 2>&1 && + test 17 != "$i" # 1/2 MB should be enough + do + i=`expr $i + 1` + teststring=$teststring$teststring + done + # Only check the string length outside the loop. + lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` + teststring= + # Add a significant safety factor because C++ compilers can tack on + # massive amounts of additional arguments before passing them to the + # linker. It appears as though 1/2 is a usable value. + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` + fi + ;; + esac +]) +if test -n "$lt_cv_sys_max_cmd_len"; then + AC_MSG_RESULT($lt_cv_sys_max_cmd_len) +else + AC_MSG_RESULT(none) +fi +max_cmd_len=$lt_cv_sys_max_cmd_len +_LT_DECL([], [max_cmd_len], [0], + [What is the maximum length of a command?]) +])# LT_CMD_MAX_LEN + +# Old name: +AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], []) + + +# _LT_HEADER_DLFCN +# ---------------- +m4_defun([_LT_HEADER_DLFCN], +[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl +])# _LT_HEADER_DLFCN + + +# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, +# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) +# ---------------------------------------------------------------- +m4_defun([_LT_TRY_DLOPEN_SELF], +[m4_require([_LT_HEADER_DLFCN])dnl +if test yes = "$cross_compiling"; then : + [$4] +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext <<_LT_EOF +[#line $LINENO "configure" +#include "confdefs.h" + +#if HAVE_DLFCN_H +#include +#endif + +#include + +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif + +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif + +/* When -fvisibility=hidden is used, assume the code has been annotated + correspondingly for the symbols needed. */ +#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) +int fnord () __attribute__((visibility("default"))); +#endif + +int fnord () { return 42; } +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; + + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else + { + if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + else puts (dlerror ()); + } + /* dlclose (self); */ + } + else + puts (dlerror ()); + + return status; +}] +_LT_EOF + if AC_TRY_EVAL(ac_link) && test -s "conftest$ac_exeext" 2>/dev/null; then + (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) $1 ;; + x$lt_dlneed_uscore) $2 ;; + x$lt_dlunknown|x*) $3 ;; + esac + else : + # compilation failed + $3 + fi +fi +rm -fr conftest* +])# _LT_TRY_DLOPEN_SELF + + +# LT_SYS_DLOPEN_SELF +# ------------------ +AC_DEFUN([LT_SYS_DLOPEN_SELF], +[m4_require([_LT_HEADER_DLFCN])dnl +if test yes != "$enable_dlopen"; then + enable_dlopen=unknown + enable_dlopen_self=unknown + enable_dlopen_self_static=unknown +else + lt_cv_dlopen=no + lt_cv_dlopen_libs= + + case $host_os in + beos*) + lt_cv_dlopen=load_add_on + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + ;; + + mingw* | pw32* | cegcc*) + lt_cv_dlopen=LoadLibrary + lt_cv_dlopen_libs= + ;; + + cygwin*) + lt_cv_dlopen=dlopen + lt_cv_dlopen_libs= + ;; + + darwin*) + # if libdl is installed we need to link against it + AC_CHECK_LIB([dl], [dlopen], + [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl],[ + lt_cv_dlopen=dyld + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + ]) + ;; + + tpf*) + # Don't try to run any link tests for TPF. We know it's impossible + # because TPF is a cross-compiler, and we know how we open DSOs. + lt_cv_dlopen=dlopen + lt_cv_dlopen_libs= + lt_cv_dlopen_self=no + ;; + + *) + AC_CHECK_FUNC([shl_load], + [lt_cv_dlopen=shl_load], + [AC_CHECK_LIB([dld], [shl_load], + [lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld], + [AC_CHECK_FUNC([dlopen], + [lt_cv_dlopen=dlopen], + [AC_CHECK_LIB([dl], [dlopen], + [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl], + [AC_CHECK_LIB([svld], [dlopen], + [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld], + [AC_CHECK_LIB([dld], [dld_link], + [lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld]) + ]) + ]) + ]) + ]) + ]) + ;; + esac + + if test no = "$lt_cv_dlopen"; then + enable_dlopen=no + else + enable_dlopen=yes + fi + + case $lt_cv_dlopen in + dlopen) + save_CPPFLAGS=$CPPFLAGS + test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" + + save_LDFLAGS=$LDFLAGS + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" + + save_LIBS=$LIBS + LIBS="$lt_cv_dlopen_libs $LIBS" + + AC_CACHE_CHECK([whether a program can dlopen itself], + lt_cv_dlopen_self, [dnl + _LT_TRY_DLOPEN_SELF( + lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, + lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) + ]) + + if test yes = "$lt_cv_dlopen_self"; then + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" + AC_CACHE_CHECK([whether a statically linked program can dlopen itself], + lt_cv_dlopen_self_static, [dnl + _LT_TRY_DLOPEN_SELF( + lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, + lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) + ]) + fi + + CPPFLAGS=$save_CPPFLAGS + LDFLAGS=$save_LDFLAGS + LIBS=$save_LIBS + ;; + esac + + case $lt_cv_dlopen_self in + yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; + *) enable_dlopen_self=unknown ;; + esac + + case $lt_cv_dlopen_self_static in + yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; + *) enable_dlopen_self_static=unknown ;; + esac +fi +_LT_DECL([dlopen_support], [enable_dlopen], [0], + [Whether dlopen is supported]) +_LT_DECL([dlopen_self], [enable_dlopen_self], [0], + [Whether dlopen of programs is supported]) +_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0], + [Whether dlopen of statically linked programs is supported]) +])# LT_SYS_DLOPEN_SELF + +# Old name: +AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], []) + + +# _LT_COMPILER_C_O([TAGNAME]) +# --------------------------- +# Check to see if options -c and -o are simultaneously supported by compiler. +# This macro does not hard code the compiler like AC_PROG_CC_C_O. +m4_defun([_LT_COMPILER_C_O], +[m4_require([_LT_DECL_SED])dnl +m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_TAG_COMPILER])dnl +AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], + [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)], + [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&AS_MESSAGE_LOG_FD + echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes + fi + fi + chmod u+w . 2>&AS_MESSAGE_LOG_FD + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* +]) +_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1], + [Does compiler simultaneously support -c and -o options?]) +])# _LT_COMPILER_C_O + + +# _LT_COMPILER_FILE_LOCKS([TAGNAME]) +# ---------------------------------- +# Check to see if we can do hard links to lock some files if needed +m4_defun([_LT_COMPILER_FILE_LOCKS], +[m4_require([_LT_ENABLE_LOCK])dnl +m4_require([_LT_FILEUTILS_DEFAULTS])dnl +_LT_COMPILER_C_O([$1]) + +hard_links=nottested +if test no = "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" && test no != "$need_locks"; then + # do not overwrite the value of need_locks provided by the user + AC_MSG_CHECKING([if we can lock with hard links]) + hard_links=yes + $RM conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + AC_MSG_RESULT([$hard_links]) + if test no = "$hard_links"; then + AC_MSG_WARN(['$CC' does not support '-c -o', so 'make -j' may be unsafe]) + need_locks=warn + fi +else + need_locks=no +fi +_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) +])# _LT_COMPILER_FILE_LOCKS + + +# _LT_CHECK_OBJDIR +# ---------------- +m4_defun([_LT_CHECK_OBJDIR], +[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], +[rm -f .libs 2>/dev/null +mkdir .libs 2>/dev/null +if test -d .libs; then + lt_cv_objdir=.libs +else + # MS-DOS does not allow filenames that begin with a dot. + lt_cv_objdir=_libs +fi +rmdir .libs 2>/dev/null]) +objdir=$lt_cv_objdir +_LT_DECL([], [objdir], [0], + [The name of the directory that contains temporary libtool files])dnl +m4_pattern_allow([LT_OBJDIR])dnl +AC_DEFINE_UNQUOTED([LT_OBJDIR], "$lt_cv_objdir/", + [Define to the sub-directory where libtool stores uninstalled libraries.]) +])# _LT_CHECK_OBJDIR + + +# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME]) +# -------------------------------------- +# Check hardcoding attributes. +m4_defun([_LT_LINKER_HARDCODE_LIBPATH], +[AC_MSG_CHECKING([how to hardcode library paths into programs]) +_LT_TAGVAR(hardcode_action, $1)= +if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || + test -n "$_LT_TAGVAR(runpath_var, $1)" || + test yes = "$_LT_TAGVAR(hardcode_automatic, $1)"; then + + # We can hardcode non-existent directories. + if test no != "$_LT_TAGVAR(hardcode_direct, $1)" && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" && + test no != "$_LT_TAGVAR(hardcode_minus_L, $1)"; then + # Linking always hardcodes the temporary library directory. + _LT_TAGVAR(hardcode_action, $1)=relink + else + # We can link without hardcoding, and we can hardcode nonexisting dirs. + _LT_TAGVAR(hardcode_action, $1)=immediate + fi +else + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + _LT_TAGVAR(hardcode_action, $1)=unsupported +fi +AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) + +if test relink = "$_LT_TAGVAR(hardcode_action, $1)" || + test yes = "$_LT_TAGVAR(inherit_rpath, $1)"; then + # Fast installation is not supported + enable_fast_install=no +elif test yes = "$shlibpath_overrides_runpath" || + test no = "$enable_shared"; then + # Fast installation is not necessary + enable_fast_install=needless +fi +_LT_TAGDECL([], [hardcode_action], [0], + [How to hardcode a shared library path into an executable]) +])# _LT_LINKER_HARDCODE_LIBPATH + + +# _LT_CMD_STRIPLIB +# ---------------- +m4_defun([_LT_CMD_STRIPLIB], +[m4_require([_LT_DECL_EGREP]) +striplib= +old_striplib= +AC_MSG_CHECKING([whether stripping libraries is possible]) +if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then + test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" + test -z "$striplib" && striplib="$STRIP --strip-unneeded" + AC_MSG_RESULT([yes]) +else +# FIXME - insert some real tests, host_os isn't really good enough + case $host_os in + darwin*) + if test -n "$STRIP"; then + striplib="$STRIP -x" + old_striplib="$STRIP -S" + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + fi + ;; + *) + AC_MSG_RESULT([no]) + ;; + esac +fi +_LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) +_LT_DECL([], [striplib], [1]) +])# _LT_CMD_STRIPLIB + + +# _LT_PREPARE_MUNGE_PATH_LIST +# --------------------------- +# Make sure func_munge_path_list() is defined correctly. +m4_defun([_LT_PREPARE_MUNGE_PATH_LIST], +[[# func_munge_path_list VARIABLE PATH +# ----------------------------------- +# VARIABLE is name of variable containing _space_ separated list of +# directories to be munged by the contents of PATH, which is string +# having a format: +# "DIR[:DIR]:" +# string "DIR[ DIR]" will be prepended to VARIABLE +# ":DIR[:DIR]" +# string "DIR[ DIR]" will be appended to VARIABLE +# "DIRP[:DIRP]::[DIRA:]DIRA" +# string "DIRP[ DIRP]" will be prepended to VARIABLE and string +# "DIRA[ DIRA]" will be appended to VARIABLE +# "DIR[:DIR]" +# VARIABLE will be replaced by "DIR[ DIR]" +func_munge_path_list () +{ + case x@S|@2 in + x) + ;; + *:) + eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'` \@S|@@S|@1\" + ;; + x:*) + eval @S|@1=\"\@S|@@S|@1 `$ECHO @S|@2 | $SED 's/:/ /g'`\" + ;; + *::*) + eval @S|@1=\"\@S|@@S|@1\ `$ECHO @S|@2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" + eval @S|@1=\"`$ECHO @S|@2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \@S|@@S|@1\" + ;; + *) + eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'`\" + ;; + esac +} +]])# _LT_PREPARE_PATH_LIST + + +# _LT_SYS_DYNAMIC_LINKER([TAG]) +# ----------------------------- +# PORTME Fill in your ld.so characteristics +m4_defun([_LT_SYS_DYNAMIC_LINKER], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_DECL_OBJDUMP])dnl +m4_require([_LT_DECL_SED])dnl +m4_require([_LT_CHECK_SHELL_FEATURES])dnl +m4_require([_LT_PREPARE_MUNGE_PATH_LIST])dnl +AC_MSG_CHECKING([dynamic linker characteristics]) +m4_if([$1], + [], [ +if test yes = "$GCC"; then + case $host_os in + darwin*) lt_awk_arg='/^libraries:/,/LR/' ;; + *) lt_awk_arg='/^libraries:/' ;; + esac + case $host_os in + mingw* | cegcc*) lt_sed_strip_eq='s|=\([[A-Za-z]]:\)|\1|g' ;; + *) lt_sed_strip_eq='s|=/|/|g' ;; + esac + lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` + case $lt_search_path_spec in + *\;*) + # if the path contains ";" then we assume it to be the separator + # otherwise default to the standard path separator (i.e. ":") - it is + # assumed that no part of a normal pathname contains ";" but that should + # okay in the real world where ";" in dirpaths is itself problematic. + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` + ;; + *) + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` + ;; + esac + # Ok, now we have the path, separated by spaces, we can step through it + # and add multilib dir if necessary... + lt_tmp_lt_search_path_spec= + lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` + # ...but if some path component already ends with the multilib dir we assume + # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer). + case "$lt_multi_os_dir; $lt_search_path_spec " in + "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*) + lt_multi_os_dir= + ;; + esac + for lt_sys_path in $lt_search_path_spec; do + if test -d "$lt_sys_path$lt_multi_os_dir"; then + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir" + elif test -n "$lt_multi_os_dir"; then + test -d "$lt_sys_path" && \ + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" + fi + done + lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' +BEGIN {RS = " "; FS = "/|\n";} { + lt_foo = ""; + lt_count = 0; + for (lt_i = NF; lt_i > 0; lt_i--) { + if ($lt_i != "" && $lt_i != ".") { + if ($lt_i == "..") { + lt_count++; + } else { + if (lt_count == 0) { + lt_foo = "/" $lt_i lt_foo; + } else { + lt_count--; + } + } + } + } + if (lt_foo != "") { lt_freq[[lt_foo]]++; } + if (lt_freq[[lt_foo]] == 1) { print lt_foo; } +}'` + # AWK program above erroneously prepends '/' to C:/dos/paths + # for these hosts. + case $host_os in + mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ + $SED 's|/\([[A-Za-z]]:\)|\1|g'` ;; + esac + sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` +else + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" +fi]) +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=.so +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" +need_lib_prefix=unknown +hardcode_into_libs=no + +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown + +AC_ARG_VAR([LT_SYS_LIBRARY_PATH], +[User-defined run-time library search path.]) + +case $host_os in +aix3*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname.a' + shlibpath_var=LIBPATH + + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='$libname$release$shared_ext$major' + ;; + +aix[[4-9]]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test ia64 = "$host_cpu"; then + # AIX 5 supports IA64 + library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line '#! .'. This would cause the generated library to + # depend on '.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[[01]] | aix4.[[01]].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then + : + else + can_build_shared=no + fi + ;; + esac + # Using Import Files as archive members, it is possible to support + # filename-based versioning of shared library archives on AIX. While + # this would work for both with and without runtime linking, it will + # prevent static linking of such archives. So we do filename-based + # shared library versioning with .so extension only, which is used + # when both runtime linking and shared linking is enabled. + # Unfortunately, runtime linking may impact performance, so we do + # not want this to be the default eventually. Also, we use the + # versioned .so libs for executables only if there is the -brtl + # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. + # To allow for filename-based versioning support, we need to create + # libNAME.so.V as an archive file, containing: + # *) an Import File, referring to the versioned filename of the + # archive as well as the shared archive member, telling the + # bitwidth (32 or 64) of that shared object, and providing the + # list of exported symbols of that shared object, eventually + # decorated with the 'weak' keyword + # *) the shared object with the F_LOADONLY flag set, to really avoid + # it being seen by the linker. + # At run time we better use the real file rather than another symlink, + # but for link time we create the symlink libNAME.so -> libNAME.so.V + + case $with_aix_soname,$aix_use_runtimelinking in + # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + aix,yes) # traditional libtool + dynamic_linker='AIX unversionable lib.so' + # If using run time linking (on AIX 4.2 or later) use lib.so + # instead of lib.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + ;; + aix,no) # traditional AIX only + dynamic_linker='AIX lib.a[(]lib.so.V[)]' + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='$libname$release.a $libname.a' + soname_spec='$libname$release$shared_ext$major' + ;; + svr4,*) # full svr4 only + dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)]" + library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' + # We do not specify a path in Import Files, so LIBPATH fires. + shlibpath_overrides_runpath=yes + ;; + *,yes) # both, prefer svr4 + dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)], lib.a[(]lib.so.V[)]" + library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' + # unpreferred sharedlib libNAME.a needs extra handling + postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' + postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' + # We do not specify a path in Import Files, so LIBPATH fires. + shlibpath_overrides_runpath=yes + ;; + *,no) # both, prefer aix + dynamic_linker="AIX lib.a[(]lib.so.V[)], lib.so.V[(]$shared_archive_member_spec.o[)]" + library_names_spec='$libname$release.a $libname.a' + soname_spec='$libname$release$shared_ext$major' + # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling + postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' + postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' + ;; + esac + shlibpath_var=LIBPATH + fi + ;; + +amigaos*) + case $host_cpu in + powerpc) + # Since July 2007 AmigaOS4 officially supports .so libraries. + # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + ;; + m68k) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; $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' + ;; + esac + ;; + +beos*) + library_names_spec='$libname$shared_ext' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; + +bsdi[[45]]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; + +cygwin* | mingw* | pw32* | cegcc*) + version_type=windows + shrext_cmds=.dll + need_version=no + need_lib_prefix=no + + case $GCC,$cc_basename in + yes,*) + # gcc + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + + case $host_os in + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' +m4_if([$1], [],[ + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) + ;; + mingw* | cegcc*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' + ;; + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' + ;; + esac + dynamic_linker='Win32 ld.exe' + ;; + + *,cl*) + # Native MSVC + libname_spec='$name' + soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' + library_names_spec='$libname.dll.lib' + + case $build_os in + mingw*) + sys_lib_search_path_spec= + lt_save_ifs=$IFS + IFS=';' + for lt_path in $LIB + do + IFS=$lt_save_ifs + # Let DOS variable expansion print the short 8.3 style file name. + lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` + sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" + done + IFS=$lt_save_ifs + # Convert to MSYS style. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'` + ;; + cygwin*) + # Convert to unix form, then to dos form, then back to unix form + # but this time dos style (no spaces!) so that the unix form looks + # like /cygdrive/c/PROGRA~1:/cygdr... + sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` + sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` + sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + ;; + *) + sys_lib_search_path_spec=$LIB + if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then + # It is most probably a Windows format PATH. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + # FIXME: find the short name or the path components, as spaces are + # common. (e.g. "Program Files" -> "PROGRA~1") + ;; + esac + + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + dynamic_linker='Win32 link.exe' + ;; + + *) + # Assume MSVC wrapper + library_names_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext $libname.lib' + dynamic_linker='Win32 ld.exe' + ;; + esac + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; + +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' + soname_spec='$libname$release$major$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' +m4_if([$1], [],[ + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; + +dgux*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` + else + case $host_os in + freebsd[[23]].*) objformat=aout ;; + *) objformat=elf ;; + esac + fi + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + need_version=no + need_lib_prefix=no + ;; + freebsd-*) + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + need_version=yes + ;; + esac + shlibpath_var=LD_LIBRARY_PATH + case $host_os in + freebsd2.*) + shlibpath_overrides_runpath=yes + ;; + freebsd3.[[01]]* | freebsdelf3.[[01]]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ + freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + *) # from 4.6 on, and DragonFly + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + esac + ;; + +haiku*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + dynamic_linker="$host_os runtime_loader" + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LIBRARY_PATH + shlibpath_overrides_runpath=no + sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' + hardcode_into_libs=yes + ;; + +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + if test 32 = "$HPUX_IA64_MODE"; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + sys_lib_dlsearch_path_spec=/usr/lib/hpux32 + else + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + sys_lib_dlsearch_path_spec=/usr/lib/hpux64 + fi + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555, ... + postinstall_cmds='chmod 555 $lib' + # or fails outright, so override atomically: + install_override_mode=555 + ;; + +interix[[3-9]]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; + *) + if test yes = "$lt_cv_prog_gnu_ld"; then + version_type=linux # correct to gnu/linux during the next big refactor + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='$libname$release$shared_ext$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; + esac + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" + sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" + hardcode_into_libs=yes + ;; + +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; + +linux*android*) + version_type=none # Android doesn't support versioned libraries. + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext' + soname_spec='$libname$release$shared_ext' + finish_cmds= + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + dynamic_linker='Android linker' + # Don't embed -rpath directories since the linker doesn't support them. + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + ;; + +# This must be glibc/ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + + # Some binutils ld are patched to set DT_RUNPATH + AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath], + [lt_cv_shlibpath_overrides_runpath=no + save_LDFLAGS=$LDFLAGS + save_libdir=$libdir + eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \ + LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\"" + AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], + [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null], + [lt_cv_shlibpath_overrides_runpath=yes])]) + LDFLAGS=$save_LDFLAGS + libdir=$save_libdir + ]) + shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + # Ideally, we could use ldconfig to report *all* directores which are + # searched for libraries, however this is still not possible. Aside from not + # being certain /sbin/ldconfig is available, command + # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, + # even though it is searched at run-time. Try to do the best guess by + # appending ld.so.conf contents (and includes) to the search path. + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi + + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; + +netbsdelf*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='NetBSD ld.elf_so' + ;; + +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + +newsos6) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +*nto* | *qnx*) + version_type=qnx + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='ldqnx.so' + ;; + +openbsd* | bitrig*) + version_type=sunos + sys_lib_dlsearch_path_spec=/usr/lib + need_lib_prefix=no + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then + need_version=no + else + need_version=yes + fi + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +os2*) + libname_spec='$name' + version_type=windows + shrext_cmds=.dll + need_version=no + need_lib_prefix=no + # OS/2 can only load a DLL with a base name of 8 characters or less. + soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; + v=$($ECHO $release$versuffix | tr -d .-); + n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); + $ECHO $n$v`$shared_ext' + library_names_spec='${libname}_dll.$libext' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=BEGINLIBPATH + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + ;; + +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='$libname$release$shared_ext$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + +rdos*) + dynamic_linker=no + ;; + +solaris*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; + +sunos4*) + version_type=sunos + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test yes = "$with_gnu_ld"; then + need_lib_prefix=no + fi + need_version=yes + ;; + +sysv4 | sysv4.3*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + runpath_var=LD_RUN_PATH + ;; + siemens) + need_lib_prefix=no + ;; + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + ;; + esac + ;; + +sysv4*MP*) + if test -d /usr/nec; then + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' + soname_spec='$libname$shared_ext.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + version_type=sco + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + if test yes = "$with_gnu_ld"; then + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' + else + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' + case $host_os in + sco3.2v5*) + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" + ;; + esac + fi + sys_lib_dlsearch_path_spec='/usr/lib' + ;; + +tpf*) + # TPF is a cross-target only. Preferred cross-host = GNU/Linux. + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +uts4*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +*) + dynamic_linker=no + ;; +esac +AC_MSG_RESULT([$dynamic_linker]) +test no = "$dynamic_linker" && can_build_shared=no + +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test yes = "$GCC"; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +fi + +if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then + sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec +fi + +if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then + sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec +fi + +# remember unaugmented sys_lib_dlsearch_path content for libtool script decls... +configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec + +# ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code +func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" + +# to be used as default LT_SYS_LIBRARY_PATH value in generated libtool +configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH + +_LT_DECL([], [variables_saved_for_relink], [1], + [Variables whose values should be saved in libtool wrapper scripts and + restored at link time]) +_LT_DECL([], [need_lib_prefix], [0], + [Do we need the "lib" prefix for modules?]) +_LT_DECL([], [need_version], [0], [Do we need a version for libraries?]) +_LT_DECL([], [version_type], [0], [Library versioning type]) +_LT_DECL([], [runpath_var], [0], [Shared library runtime path variable]) +_LT_DECL([], [shlibpath_var], [0],[Shared library path variable]) +_LT_DECL([], [shlibpath_overrides_runpath], [0], + [Is shlibpath searched before the hard-coded library search path?]) +_LT_DECL([], [libname_spec], [1], [Format of library name prefix]) +_LT_DECL([], [library_names_spec], [1], + [[List of archive names. First name is the real one, the rest are links. + The last name is the one that the linker finds with -lNAME]]) +_LT_DECL([], [soname_spec], [1], + [[The coded name of the library, if different from the real name]]) +_LT_DECL([], [install_override_mode], [1], + [Permission mode override for installation of shared libraries]) +_LT_DECL([], [postinstall_cmds], [2], + [Command to use after installation of a shared archive]) +_LT_DECL([], [postuninstall_cmds], [2], + [Command to use after uninstallation of a shared archive]) +_LT_DECL([], [finish_cmds], [2], + [Commands used to finish a libtool library installation in a directory]) +_LT_DECL([], [finish_eval], [1], + [[As "finish_cmds", except a single script fragment to be evaled but + not shown]]) +_LT_DECL([], [hardcode_into_libs], [0], + [Whether we should hardcode library paths into libraries]) +_LT_DECL([], [sys_lib_search_path_spec], [2], + [Compile-time system search path for libraries]) +_LT_DECL([sys_lib_dlsearch_path_spec], [configure_time_dlsearch_path], [2], + [Detected run-time system search path for libraries]) +_LT_DECL([], [configure_time_lt_sys_library_path], [2], + [Explicit LT_SYS_LIBRARY_PATH set during ./configure time]) +])# _LT_SYS_DYNAMIC_LINKER + + +# _LT_PATH_TOOL_PREFIX(TOOL) +# -------------------------- +# find a file program that can recognize shared library +AC_DEFUN([_LT_PATH_TOOL_PREFIX], +[m4_require([_LT_DECL_EGREP])dnl +AC_MSG_CHECKING([for $1]) +AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, +[case $MAGIC_CMD in +[[\\/*] | ?:[\\/]*]) + lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. + ;; +*) + lt_save_MAGIC_CMD=$MAGIC_CMD + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR +dnl $ac_dummy forces splitting on constant user-supplied paths. +dnl POSIX.2 word splitting is done only on the output of word expansions, +dnl not every word. This closes a longstanding sh security hole. + ac_dummy="m4_if([$2], , $PATH, [$2])" + for ac_dir in $ac_dummy; do + IFS=$lt_save_ifs + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/$1"; then + lt_cv_path_MAGIC_CMD=$ac_dir/"$1" + if test -n "$file_magic_test_file"; then + case $deplibs_check_method in + "file_magic "*) + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` + MAGIC_CMD=$lt_cv_path_MAGIC_CMD + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | + $EGREP "$file_magic_regex" > /dev/null; then + : + else + cat <<_LT_EOF 1>&2 + +*** Warning: the command libtool uses to detect shared libraries, +*** $file_magic_cmd, produces output that libtool cannot recognize. +*** The result is that libtool may fail to recognize shared libraries +*** as such. This will affect the creation of libtool libraries that +*** depend on shared libraries, but programs linked with such libtool +*** libraries will work regardless of this problem. Nevertheless, you +*** may want to report the problem to your system manager and/or to +*** bug-libtool@gnu.org + +_LT_EOF + fi ;; + esac + fi + break + fi + done + IFS=$lt_save_ifs + MAGIC_CMD=$lt_save_MAGIC_CMD + ;; +esac]) +MAGIC_CMD=$lt_cv_path_MAGIC_CMD +if test -n "$MAGIC_CMD"; then + AC_MSG_RESULT($MAGIC_CMD) +else + AC_MSG_RESULT(no) +fi +_LT_DECL([], [MAGIC_CMD], [0], + [Used to examine libraries when file_magic_cmd begins with "file"])dnl +])# _LT_PATH_TOOL_PREFIX + +# Old name: +AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) + + +# _LT_PATH_MAGIC +# -------------- +# find a file program that can recognize a shared library +m4_defun([_LT_PATH_MAGIC], +[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) +if test -z "$lt_cv_path_MAGIC_CMD"; then + if test -n "$ac_tool_prefix"; then + _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) + else + MAGIC_CMD=: + fi +fi +])# _LT_PATH_MAGIC + + +# LT_PATH_LD +# ---------- +# find the pathname to the GNU or non-GNU linker +AC_DEFUN([LT_PATH_LD], +[AC_REQUIRE([AC_PROG_CC])dnl +AC_REQUIRE([AC_CANONICAL_HOST])dnl +AC_REQUIRE([AC_CANONICAL_BUILD])dnl +m4_require([_LT_DECL_SED])dnl +m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_PROG_ECHO_BACKSLASH])dnl + +AC_ARG_WITH([gnu-ld], + [AS_HELP_STRING([--with-gnu-ld], + [assume the C compiler uses GNU ld @<:@default=no@:>@])], + [test no = "$withval" || with_gnu_ld=yes], + [with_gnu_ld=no])dnl + +ac_prog=ld +if test yes = "$GCC"; then + # Check if gcc -print-prog-name=ld gives a path. + AC_MSG_CHECKING([for ld used by $CC]) + case $host in + *-*-mingw*) + # gcc leaves a trailing carriage return, which upsets mingw + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; + *) + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; + esac + case $ac_prog in + # Accept absolute paths. + [[\\/]]* | ?:[[\\/]]*) + re_direlt='/[[^/]][[^/]]*/\.\./' + # Canonicalize the pathname of ld + ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` + while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do + ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` + done + test -z "$LD" && LD=$ac_prog + ;; + "") + # If it fails, then pretend we aren't using GCC. + ac_prog=ld + ;; + *) + # If it is relative, then search for the first ld in PATH. + with_gnu_ld=unknown + ;; + esac +elif test yes = "$with_gnu_ld"; then + AC_MSG_CHECKING([for GNU ld]) +else + AC_MSG_CHECKING([for non-GNU ld]) +fi +AC_CACHE_VAL(lt_cv_path_LD, +[if test -z "$LD"; then + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS=$lt_save_ifs + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then + lt_cv_path_LD=$ac_dir/$ac_prog + # Check to see if the program is GNU ld. I'd rather use --version, + # but apparently some variants of GNU ld only accept -v. + # Break only if it was the GNU/non-GNU ld that we prefer. + case `"$lt_cv_path_LD" -v 2>&1 &1 conftest.i +cat conftest.i conftest.i >conftest2.i +: ${lt_DD:=$DD} +AC_PATH_PROGS_FEATURE_CHECK([lt_DD], [dd], +[if "$ac_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then + cmp -s conftest.i conftest.out \ + && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=: +fi]) +rm -f conftest.i conftest2.i conftest.out]) +])# _LT_PATH_DD + + +# _LT_CMD_TRUNCATE +# ---------------- +# find command to truncate a binary pipe +m4_defun([_LT_CMD_TRUNCATE], +[m4_require([_LT_PATH_DD]) +AC_CACHE_CHECK([how to truncate binary pipes], [lt_cv_truncate_bin], +[printf 0123456789abcdef0123456789abcdef >conftest.i +cat conftest.i conftest.i >conftest2.i +lt_cv_truncate_bin= +if "$ac_cv_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then + cmp -s conftest.i conftest.out \ + && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1" +fi +rm -f conftest.i conftest2.i conftest.out +test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"]) +_LT_DECL([lt_truncate_bin], [lt_cv_truncate_bin], [1], + [Command to truncate a binary pipe]) +])# _LT_CMD_TRUNCATE + + +# _LT_CHECK_MAGIC_METHOD +# ---------------------- +# how to check for library dependencies +# -- PORTME fill in with the dynamic library characteristics +m4_defun([_LT_CHECK_MAGIC_METHOD], +[m4_require([_LT_DECL_EGREP]) +m4_require([_LT_DECL_OBJDUMP]) +AC_CACHE_CHECK([how to recognize dependent libraries], +lt_cv_deplibs_check_method, +[lt_cv_file_magic_cmd='$MAGIC_CMD' +lt_cv_file_magic_test_file= +lt_cv_deplibs_check_method='unknown' +# Need to set the preceding variable on all platforms that support +# interlibrary dependencies. +# 'none' -- dependencies not supported. +# 'unknown' -- same as none, but documents that we really don't know. +# 'pass_all' -- all dependencies passed with no checks. +# 'test_compile' -- check by making test program. +# 'file_magic [[regex]]' -- check by looking for files in library path +# that responds to the $file_magic_cmd with a given extended regex. +# If you have 'file' or equivalent on your system and you're not sure +# whether 'pass_all' will *always* work, you probably want this one. + +case $host_os in +aix[[4-9]]*) + lt_cv_deplibs_check_method=pass_all + ;; + +beos*) + lt_cv_deplibs_check_method=pass_all + ;; + +bsdi[[45]]*) + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' + lt_cv_file_magic_cmd='/usr/bin/file -L' + lt_cv_file_magic_test_file=/shlib/libc.so + ;; + +cygwin*) + # func_win32_libid is a shell function defined in ltmain.sh + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + ;; + +mingw* | pw32*) + # Base MSYS/MinGW do not provide the 'file' command needed by + # func_win32_libid shell function, so use a weaker test based on 'objdump', + # unless we find 'file', for example because we are cross-compiling. + if ( file / ) >/dev/null 2>&1; then + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + else + # Keep this pattern in sync with the one in func_win32_libid. + lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' + lt_cv_file_magic_cmd='$OBJDUMP -f' + fi + ;; + +cegcc*) + # use the weaker test based on 'objdump'. See mingw*. + lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' + lt_cv_file_magic_cmd='$OBJDUMP -f' + ;; + +darwin* | rhapsody*) + lt_cv_deplibs_check_method=pass_all + ;; + +freebsd* | dragonfly*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then + case $host_cpu in + i*86 ) + # Not sure whether the presence of OpenBSD here was a mistake. + # Let's accept both of them until this is cleared up. + lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` + ;; + esac + else + lt_cv_deplibs_check_method=pass_all + fi + ;; + +haiku*) + lt_cv_deplibs_check_method=pass_all + ;; + +hpux10.20* | hpux11*) + lt_cv_file_magic_cmd=/usr/bin/file + case $host_cpu in + ia64*) + lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' + lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so + ;; + hppa*64*) + [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'] + lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl + ;; + *) + lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library' + lt_cv_file_magic_test_file=/usr/lib/libc.sl + ;; + esac + ;; + +interix[[3-9]]*) + # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' + ;; + +irix5* | irix6* | nonstopux*) + case $LD in + *-32|*"-32 ") libmagic=32-bit;; + *-n32|*"-n32 ") libmagic=N32;; + *-64|*"-64 ") libmagic=64-bit;; + *) libmagic=never-match;; + esac + lt_cv_deplibs_check_method=pass_all + ;; + +# This must be glibc/ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + lt_cv_deplibs_check_method=pass_all + ;; + +netbsd* | netbsdelf*-gnu) + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' + fi + ;; + +newos6*) + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=/usr/lib/libnls.so + ;; + +*nto* | *qnx*) + lt_cv_deplibs_check_method=pass_all + ;; + +openbsd* | bitrig*) + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' + fi + ;; + +osf3* | osf4* | osf5*) + lt_cv_deplibs_check_method=pass_all + ;; + +rdos*) + lt_cv_deplibs_check_method=pass_all + ;; + +solaris*) + lt_cv_deplibs_check_method=pass_all + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + lt_cv_deplibs_check_method=pass_all + ;; + +sysv4 | sysv4.3*) + case $host_vendor in + motorola) + 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]]' + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` + ;; + ncr) + lt_cv_deplibs_check_method=pass_all + ;; + sequent) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' + ;; + sni) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" + lt_cv_file_magic_test_file=/lib/libc.so + ;; + siemens) + lt_cv_deplibs_check_method=pass_all + ;; + pc) + lt_cv_deplibs_check_method=pass_all + ;; + esac + ;; + +tpf*) + lt_cv_deplibs_check_method=pass_all + ;; +os2*) + lt_cv_deplibs_check_method=pass_all + ;; +esac +]) + +file_magic_glob= +want_nocaseglob=no +if test "$build" = "$host"; then + case $host_os in + mingw* | pw32*) + if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then + want_nocaseglob=yes + else + file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"` + fi + ;; + esac +fi + +file_magic_cmd=$lt_cv_file_magic_cmd +deplibs_check_method=$lt_cv_deplibs_check_method +test -z "$deplibs_check_method" && deplibs_check_method=unknown + +_LT_DECL([], [deplibs_check_method], [1], + [Method to check whether dependent libraries are shared objects]) +_LT_DECL([], [file_magic_cmd], [1], + [Command to use when deplibs_check_method = "file_magic"]) +_LT_DECL([], [file_magic_glob], [1], + [How to find potential files when deplibs_check_method = "file_magic"]) +_LT_DECL([], [want_nocaseglob], [1], + [Find potential files using nocaseglob when deplibs_check_method = "file_magic"]) +])# _LT_CHECK_MAGIC_METHOD + + +# LT_PATH_NM +# ---------- +# find the pathname to a BSD- or MS-compatible name lister +AC_DEFUN([LT_PATH_NM], +[AC_REQUIRE([AC_PROG_CC])dnl +AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, +[if test -n "$NM"; then + # Let the user override the test. + lt_cv_path_NM=$NM +else + lt_nm_to_check=${ac_tool_prefix}nm + if test -n "$ac_tool_prefix" && test "$build" = "$host"; then + lt_nm_to_check="$lt_nm_to_check nm" + fi + for lt_tmp_nm in $lt_nm_to_check; do + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR + for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do + IFS=$lt_save_ifs + test -z "$ac_dir" && ac_dir=. + tmp_nm=$ac_dir/$lt_tmp_nm + if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then + # Check to see if the nm accepts a BSD-compat flag. + # Adding the 'sed 1q' prevents false positives on HP-UX, which says: + # nm: unknown option "B" ignored + # Tru64's nm complains that /dev/null is an invalid object file + # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty + case $build_os in + mingw*) lt_bad_file=conftest.nm/nofile ;; + *) lt_bad_file=/dev/null ;; + esac + case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in + *$lt_bad_file* | *'Invalid file or object type'*) + lt_cv_path_NM="$tmp_nm -B" + break 2 + ;; + *) + case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in + */dev/null*) + lt_cv_path_NM="$tmp_nm -p" + break 2 + ;; + *) + lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but + continue # so that we can try to find one that supports BSD flags + ;; + esac + ;; + esac + fi + done + IFS=$lt_save_ifs + done + : ${lt_cv_path_NM=no} +fi]) +if test no != "$lt_cv_path_NM"; then + NM=$lt_cv_path_NM +else + # Didn't find any BSD compatible name lister, look for dumpbin. + if test -n "$DUMPBIN"; then : + # Let the user override the test. + else + AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) + case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in + *COFF*) + DUMPBIN="$DUMPBIN -symbols -headers" + ;; + *) + DUMPBIN=: + ;; + esac + fi + AC_SUBST([DUMPBIN]) + if test : != "$DUMPBIN"; then + NM=$DUMPBIN + fi +fi +test -z "$NM" && NM=nm +AC_SUBST([NM]) +_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl + +AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface], + [lt_cv_nm_interface="BSD nm" + echo "int some_variable = 0;" > conftest.$ac_ext + (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD) + (eval "$ac_compile" 2>conftest.err) + cat conftest.err >&AS_MESSAGE_LOG_FD + (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD) + (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) + cat conftest.err >&AS_MESSAGE_LOG_FD + (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD) + cat conftest.out >&AS_MESSAGE_LOG_FD + if $GREP 'External.*some_variable' conftest.out > /dev/null; then + lt_cv_nm_interface="MS dumpbin" + fi + rm -f conftest*]) +])# LT_PATH_NM + +# Old names: +AU_ALIAS([AM_PROG_NM], [LT_PATH_NM]) +AU_ALIAS([AC_PROG_NM], [LT_PATH_NM]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AM_PROG_NM], []) +dnl AC_DEFUN([AC_PROG_NM], []) + +# _LT_CHECK_SHAREDLIB_FROM_LINKLIB +# -------------------------------- +# how to determine the name of the shared library +# associated with a specific link library. +# -- PORTME fill in with the dynamic library characteristics +m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB], +[m4_require([_LT_DECL_EGREP]) +m4_require([_LT_DECL_OBJDUMP]) +m4_require([_LT_DECL_DLLTOOL]) +AC_CACHE_CHECK([how to associate runtime and link libraries], +lt_cv_sharedlib_from_linklib_cmd, +[lt_cv_sharedlib_from_linklib_cmd='unknown' + +case $host_os in +cygwin* | mingw* | pw32* | cegcc*) + # two different shell functions defined in ltmain.sh; + # decide which one to use based on capabilities of $DLLTOOL + case `$DLLTOOL --help 2>&1` in + *--identify-strict*) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib + ;; + *) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback + ;; + esac + ;; +*) + # fallback: assume linklib IS sharedlib + lt_cv_sharedlib_from_linklib_cmd=$ECHO + ;; +esac +]) +sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd +test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO + +_LT_DECL([], [sharedlib_from_linklib_cmd], [1], + [Command to associate shared and link libraries]) +])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB + + +# _LT_PATH_MANIFEST_TOOL +# ---------------------- +# locate the manifest tool +m4_defun([_LT_PATH_MANIFEST_TOOL], +[AC_CHECK_TOOL(MANIFEST_TOOL, mt, :) +test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt +AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool], + [lt_cv_path_mainfest_tool=no + echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD + $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out + cat conftest.err >&AS_MESSAGE_LOG_FD + if $GREP 'Manifest Tool' conftest.out > /dev/null; then + lt_cv_path_mainfest_tool=yes + fi + rm -f conftest*]) +if test yes != "$lt_cv_path_mainfest_tool"; then + MANIFEST_TOOL=: +fi +_LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl +])# _LT_PATH_MANIFEST_TOOL + + +# _LT_DLL_DEF_P([FILE]) +# --------------------- +# True iff FILE is a Windows DLL '.def' file. +# Keep in sync with func_dll_def_p in the libtool script +AC_DEFUN([_LT_DLL_DEF_P], +[dnl + test DEF = "`$SED -n dnl + -e '\''s/^[[ ]]*//'\'' dnl Strip leading whitespace + -e '\''/^\(;.*\)*$/d'\'' dnl Delete empty lines and comments + -e '\''s/^\(EXPORTS\|LIBRARY\)\([[ ]].*\)*$/DEF/p'\'' dnl + -e q dnl Only consider the first "real" line + $1`" dnl +])# _LT_DLL_DEF_P + + +# LT_LIB_M +# -------- +# check for math library +AC_DEFUN([LT_LIB_M], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +LIBM= +case $host in +*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*) + # These system don't have libm, or don't need it + ;; +*-ncr-sysv4.3*) + AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM=-lmw) + AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") + ;; +*) + AC_CHECK_LIB(m, cos, LIBM=-lm) + ;; +esac +AC_SUBST([LIBM]) +])# LT_LIB_M + +# Old name: +AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_CHECK_LIBM], []) + + +# _LT_COMPILER_NO_RTTI([TAGNAME]) +# ------------------------------- +m4_defun([_LT_COMPILER_NO_RTTI], +[m4_require([_LT_TAG_COMPILER])dnl + +_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= + +if test yes = "$GCC"; then + case $cc_basename in + nvcc*) + _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;; + *) + _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;; + esac + + _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], + lt_cv_prog_compiler_rtti_exceptions, + [-fno-rtti -fno-exceptions], [], + [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) +fi +_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], + [Compiler flag to turn off builtin functions]) +])# _LT_COMPILER_NO_RTTI + + +# _LT_CMD_GLOBAL_SYMBOLS +# ---------------------- +m4_defun([_LT_CMD_GLOBAL_SYMBOLS], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +AC_REQUIRE([AC_PROG_CC])dnl +AC_REQUIRE([AC_PROG_AWK])dnl +AC_REQUIRE([LT_PATH_NM])dnl +AC_REQUIRE([LT_PATH_LD])dnl +m4_require([_LT_DECL_SED])dnl +m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_TAG_COMPILER])dnl + +# Check for command to grab the raw symbol name followed by C symbol from nm. +AC_MSG_CHECKING([command to parse $NM output from $compiler object]) +AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], +[ +# These are sane defaults that work on at least a few old systems. +# [They come from Ultrix. What could be older than Ultrix?!! ;)] + +# Character class describing NM global symbol codes. +symcode='[[BCDEGRST]]' + +# Regexp to match symbols that can be accessed directly from C. +sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' + +# Define system-specific variables. +case $host_os in +aix*) + symcode='[[BCDT]]' + ;; +cygwin* | mingw* | pw32* | cegcc*) + symcode='[[ABCDGISTW]]' + ;; +hpux*) + if test ia64 = "$host_cpu"; then + symcode='[[ABCDEGRST]]' + fi + ;; +irix* | nonstopux*) + symcode='[[BCDEGRST]]' + ;; +osf*) + symcode='[[BCDEGQRST]]' + ;; +solaris*) + symcode='[[BDRT]]' + ;; +sco3.2v5*) + symcode='[[DT]]' + ;; +sysv4.2uw2*) + symcode='[[DT]]' + ;; +sysv5* | sco5v6* | unixware* | OpenUNIX*) + symcode='[[ABDT]]' + ;; +sysv4) + symcode='[[DFNSTU]]' + ;; +esac + +# If we're using GNU nm, then use its standard symbol codes. +case `$NM -V 2>&1` in +*GNU* | *'with BFD'*) + symcode='[[ABCDGIRSTW]]' ;; +esac + +if test "$lt_cv_nm_interface" = "MS dumpbin"; then + # Gets list of data symbols to import. + lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'" + # Adjust the below global symbol transforms to fixup imported variables. + lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'" + lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'" + lt_c_name_lib_hook="\ + -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\ + -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'" +else + # Disable hooks by default. + lt_cv_sys_global_symbol_to_import= + lt_cdecl_hook= + lt_c_name_hook= + lt_c_name_lib_hook= +fi + +# Transform an extracted symbol line into a proper C declaration. +# Some systems (esp. on ia64) link data and code symbols differently, +# so use this general approach. +lt_cv_sys_global_symbol_to_cdecl="sed -n"\ +$lt_cdecl_hook\ +" -e 's/^T .* \(.*\)$/extern int \1();/p'"\ +" -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'" + +# Transform an extracted symbol line into symbol name and symbol address +lt_cv_sys_global_symbol_to_c_name_address="sed -n"\ +$lt_c_name_hook\ +" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ +" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'" + +# Transform an extracted symbol line into symbol name with lib prefix and +# symbol address. +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\ +$lt_c_name_lib_hook\ +" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ +" -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\ +" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'" + +# Handle CRLF in mingw tool chain +opt_cr= +case $build_os in +mingw*) + opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp + ;; +esac + +# Try without a prefix underscore, then with it. +for ac_symprfx in "" "_"; do + + # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. + symxfrm="\\1 $ac_symprfx\\2 \\2" + + # Write the raw and C identifiers. + if test "$lt_cv_nm_interface" = "MS dumpbin"; then + # Fake it for dumpbin and say T for any non-static function, + # D for any global variable and I for any imported variable. + # Also find C++ and __fastcall symbols from MSVC++, + # which start with @ or ?. + lt_cv_sys_global_symbol_pipe="$AWK ['"\ +" {last_section=section; section=\$ 3};"\ +" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ +" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ +" /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\ +" /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\ +" /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\ +" \$ 0!~/External *\|/{next};"\ +" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ +" {if(hide[section]) next};"\ +" {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\ +" {split(\$ 0,a,/\||\r/); split(a[2],s)};"\ +" s[1]~/^[@?]/{print f,s[1],s[1]; next};"\ +" s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\ +" ' prfx=^$ac_symprfx]" + else + lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" + fi + lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" + + # Check to see that the pipe works correctly. + pipe_works=no + + rm -f conftest* + cat > conftest.$ac_ext <<_LT_EOF +#ifdef __cplusplus +extern "C" { +#endif +char nm_test_var; +void nm_test_func(void); +void nm_test_func(void){} +#ifdef __cplusplus +} +#endif +int main(){nm_test_var='a';nm_test_func();return(0);} +_LT_EOF + + if AC_TRY_EVAL(ac_compile); then + # Now try to grab the symbols. + nlist=conftest.nm + if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then + # Try sorting and uniquifying the output. + if sort "$nlist" | uniq > "$nlist"T; then + mv -f "$nlist"T "$nlist" + else + rm -f "$nlist"T + fi + + # Make sure that we snagged all the symbols we need. + if $GREP ' nm_test_var$' "$nlist" >/dev/null; then + if $GREP ' nm_test_func$' "$nlist" >/dev/null; then + cat <<_LT_EOF > conftest.$ac_ext +/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ +#if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE +/* DATA imports from DLLs on WIN32 can't be const, because runtime + relocations are performed -- see ld's documentation on pseudo-relocs. */ +# define LT@&t@_DLSYM_CONST +#elif defined __osf__ +/* This system does not cope well with relocations in const data. */ +# define LT@&t@_DLSYM_CONST +#else +# define LT@&t@_DLSYM_CONST const +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +_LT_EOF + # Now generate the symbol file. + eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' + + cat <<_LT_EOF >> conftest.$ac_ext + +/* The mapping between symbol names and symbols. */ +LT@&t@_DLSYM_CONST struct { + const char *name; + void *address; +} +lt__PROGRAM__LTX_preloaded_symbols[[]] = +{ + { "@PROGRAM@", (void *) 0 }, +_LT_EOF + $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext + cat <<\_LT_EOF >> conftest.$ac_ext + {0, (void *) 0} +}; + +/* This works around a problem in FreeBSD linker */ +#ifdef FREEBSD_WORKAROUND +static const void *lt_preloaded_setup() { + return lt__PROGRAM__LTX_preloaded_symbols; +} +#endif + +#ifdef __cplusplus +} +#endif +_LT_EOF + # Now try linking the two files. + mv conftest.$ac_objext conftstm.$ac_objext + lt_globsym_save_LIBS=$LIBS + lt_globsym_save_CFLAGS=$CFLAGS + LIBS=conftstm.$ac_objext + CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" + if AC_TRY_EVAL(ac_link) && test -s conftest$ac_exeext; then + pipe_works=yes + fi + LIBS=$lt_globsym_save_LIBS + CFLAGS=$lt_globsym_save_CFLAGS + else + echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD + fi + else + echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD + fi + else + echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD + fi + else + echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD + cat conftest.$ac_ext >&5 + fi + rm -rf conftest* conftst* + + # Do not use the global_symbol_pipe unless it works. + if test yes = "$pipe_works"; then + break + else + lt_cv_sys_global_symbol_pipe= + fi +done +]) +if test -z "$lt_cv_sys_global_symbol_pipe"; then + lt_cv_sys_global_symbol_to_cdecl= +fi +if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then + AC_MSG_RESULT(failed) +else + AC_MSG_RESULT(ok) +fi + +# Response file support. +if test "$lt_cv_nm_interface" = "MS dumpbin"; then + nm_file_list_spec='@' +elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then + nm_file_list_spec='@' +fi + +_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], + [Take the output of nm and produce a listing of raw symbols and C names]) +_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], + [Transform the output of nm in a proper C declaration]) +_LT_DECL([global_symbol_to_import], [lt_cv_sys_global_symbol_to_import], [1], + [Transform the output of nm into a list of symbols to manually relocate]) +_LT_DECL([global_symbol_to_c_name_address], + [lt_cv_sys_global_symbol_to_c_name_address], [1], + [Transform the output of nm in a C name address pair]) +_LT_DECL([global_symbol_to_c_name_address_lib_prefix], + [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], + [Transform the output of nm in a C name address pair when lib prefix is needed]) +_LT_DECL([nm_interface], [lt_cv_nm_interface], [1], + [The name lister interface]) +_LT_DECL([], [nm_file_list_spec], [1], + [Specify filename containing input files for $NM]) +]) # _LT_CMD_GLOBAL_SYMBOLS + + +# _LT_COMPILER_PIC([TAGNAME]) +# --------------------------- +m4_defun([_LT_COMPILER_PIC], +[m4_require([_LT_TAG_COMPILER])dnl +_LT_TAGVAR(lt_prog_compiler_wl, $1)= +_LT_TAGVAR(lt_prog_compiler_pic, $1)= +_LT_TAGVAR(lt_prog_compiler_static, $1)= + +m4_if([$1], [CXX], [ + # C++ specific cases for pic, static, wl, etc. + if test yes = "$GXX"; then + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + + case $host_os in + aix*) + # All AIX code is PIC. + if test ia64 = "$host_cpu"; then + # AIX 5 now supports IA64 processor + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + fi + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + m68k) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the '-m68020' flag to GCC prevents building anything better, + # like '-m68040'. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' + ;; + esac + ;; + + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + mingw* | cygwin* | os2* | pw32* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + m4_if([$1], [GCJ], [], + [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + case $host_os in + os2*) + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' + ;; + esac + ;; + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' + ;; + *djgpp*) + # DJGPP does not support shared libraries at all + _LT_TAGVAR(lt_prog_compiler_pic, $1)= + ;; + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + _LT_TAGVAR(lt_prog_compiler_static, $1)= + ;; + interix[[3-9]]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + sysv4*MP*) + if test -d /usr/nec; then + _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic + fi + ;; + hpux*) + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag + # sets the default TLS model and affects inlining. + case $host_cpu in + hppa*64*) + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + esac + ;; + *qnx* | *nto*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + esac + else + case $host_os in + aix[[4-9]]*) + # All AIX code is PIC. + if test ia64 = "$host_cpu"; then + # AIX 5 now supports IA64 processor + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + else + _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' + fi + ;; + chorus*) + case $cc_basename in + cxch68*) + # Green Hills C++ Compiler + # _LT_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" + ;; + esac + ;; + mingw* | cygwin* | os2* | pw32* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + m4_if([$1], [GCJ], [], + [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + ;; + dgux*) + case $cc_basename in + ec++*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + ;; + ghcx*) + # Green Hills C++ Compiler + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + ;; + *) + ;; + esac + ;; + freebsd* | dragonfly*) + # FreeBSD uses GNU C++ + ;; + hpux9* | hpux10* | hpux11*) + case $cc_basename in + CC*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' + if test ia64 != "$host_cpu"; then + _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' + fi + ;; + aCC*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' + ;; + esac + ;; + *) + ;; + esac + ;; + interix*) + # This is c89, which is MS Visual C++ (no shared libs) + # Anyone wants to do a port? + ;; + irix5* | irix6* | nonstopux*) + case $cc_basename in + CC*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + # CC pic flag -KPIC is the default. + ;; + *) + ;; + esac + ;; + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + case $cc_basename in + KCC*) + # KAI C++ Compiler + _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + ecpc* ) + # old Intel C++ for x86_64, which still supported -KPIC. + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + icpc* ) + # Intel C++, used to be incompatible with GCC. + # ICC 10 doesn't accept -KPIC any more. + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + cxx*) + # Compaq C++ + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + _LT_TAGVAR(lt_prog_compiler_pic, $1)= + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*) + # IBM XL 8.0, 9.0 on PPC and BlueGene + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' + ;; + esac + ;; + esac + ;; + lynxos*) + ;; + m88k*) + ;; + mvs*) + case $cc_basename in + cxx*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' + ;; + *) + ;; + esac + ;; + netbsd* | netbsdelf*-gnu) + ;; + *qnx* | *nto*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' + ;; + osf3* | osf4* | osf5*) + case $cc_basename in + KCC*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' + ;; + RCC*) + # Rational C++ 2.4.1 + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + ;; + cxx*) + # Digital/Compaq C++ + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + _LT_TAGVAR(lt_prog_compiler_pic, $1)= + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + *) + ;; + esac + ;; + psos*) + ;; + solaris*) + case $cc_basename in + CC* | sunCC*) + # Sun C++ 4.2, 5.x and Centerline C++ + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' + ;; + gcx*) + # Green Hills C++ Compiler + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' + ;; + *) + ;; + esac + ;; + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + lcc*) + # Lucid + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + ;; + *) + ;; + esac + ;; + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + case $cc_basename in + CC*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + esac + ;; + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + ;; + *) + ;; + esac + ;; + vxworks*) + ;; + *) + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no + ;; + esac + fi +], +[ + if test yes = "$GCC"; then + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + + case $host_os in + aix*) + # All AIX code is PIC. + if test ia64 = "$host_cpu"; then + # AIX 5 now supports IA64 processor + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + fi + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + m68k) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the '-m68020' flag to GCC prevents building anything better, + # like '-m68040'. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' + ;; + esac + ;; + + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + + mingw* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + m4_if([$1], [GCJ], [], + [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + case $host_os in + os2*) + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' + ;; + esac + ;; + + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' + ;; + + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + _LT_TAGVAR(lt_prog_compiler_static, $1)= + ;; + + hpux*) + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag + # sets the default TLS model and affects inlining. + case $host_cpu in + hppa*64*) + # +Z the default + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + esac + ;; + + interix[[3-9]]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + + msdosdjgpp*) + # Just because we use GCC doesn't mean we suddenly get shared libraries + # on systems that don't support them. + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no + enable_shared=no + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic + fi + ;; + + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + esac + + case $cc_basename in + nvcc*) # Cuda Compiler Driver 2.2 + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker ' + if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then + _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)" + fi + ;; + esac + else + # PORTME Check for flag to pass linker flags through the system compiler. + case $host_os in + aix*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + if test ia64 = "$host_cpu"; then + # AIX 5 now supports IA64 processor + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + else + _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' + fi + ;; + + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' + case $cc_basename in + nagfor*) + # NAG Fortran compiler + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + esac + ;; + + mingw* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + m4_if([$1], [GCJ], [], + [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + case $host_os in + os2*) + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' + ;; + esac + ;; + + hpux9* | hpux10* | hpux11*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' + ;; + esac + # Is there a better lt_prog_compiler_static that works with the bundled CC? + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' + ;; + + irix5* | irix6* | nonstopux*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # PIC (with -KPIC) is the default. + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + case $cc_basename in + # old Intel for x86_64, which still supported -KPIC. + ecc*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + # icc used to be incompatible with GCC. + # ICC 10 doesn't accept -KPIC any more. + icc* | ifort*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + # Lahey Fortran 8.1. + lf95*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' + _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' + ;; + nagfor*) + # NAG Fortran compiler + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + tcc*) + # Fabrice Bellard et al's Tiny C Compiler + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) + # Portland Group compilers (*not* the Pentium gcc compiler, + # which looks to be a dead project) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + ccc*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # All Alpha code is PIC. + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + xl* | bgxl* | bgf* | mpixl*) + # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*) + # Sun Fortran 8.3 passes all unrecognized flags to the linker + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_TAGVAR(lt_prog_compiler_wl, $1)='' + ;; + *Sun\ F* | *Sun*Fortran*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' + ;; + *Sun\ C*) + # Sun C 5.9 + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + ;; + *Intel*\ [[CF]]*Compiler*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + *Portland\ Group*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + esac + ;; + esac + ;; + + newsos6) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' + ;; + + osf3* | osf4* | osf5*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # All OSF/1 code is PIC. + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + + rdos*) + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + + solaris*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + case $cc_basename in + f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; + *) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; + esac + ;; + + sunos4*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + + sysv4 | sysv4.2uw2* | sysv4.3*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + fi + ;; + + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + + unicos*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no + ;; + + uts4*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + + *) + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no + ;; + esac + fi +]) +case $host_os in + # For platforms that do not support PIC, -DPIC is meaningless: + *djgpp*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)= + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" + ;; +esac + +AC_CACHE_CHECK([for $compiler option to produce PIC], + [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)], + [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) +_LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1) + +# +# Check to make sure the PIC flag actually works. +# +if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then + _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works], + [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)], + [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [], + [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in + "" | " "*) ;; + *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;; + esac], + [_LT_TAGVAR(lt_prog_compiler_pic, $1)= + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) +fi +_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], + [Additional compiler flags for building library objects]) + +_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], + [How to pass a linker flag through the compiler]) +# +# Check to make sure the static flag actually works. +# +wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\" +_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], + _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1), + $lt_tmp_static_flag, + [], + [_LT_TAGVAR(lt_prog_compiler_static, $1)=]) +_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], + [Compiler flag to prevent dynamic linking]) +])# _LT_COMPILER_PIC + + +# _LT_LINKER_SHLIBS([TAGNAME]) +# ---------------------------- +# See if the linker supports building shared libraries. +m4_defun([_LT_LINKER_SHLIBS], +[AC_REQUIRE([LT_PATH_LD])dnl +AC_REQUIRE([LT_PATH_NM])dnl +m4_require([_LT_PATH_MANIFEST_TOOL])dnl +m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_DECL_SED])dnl +m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl +m4_require([_LT_TAG_COMPILER])dnl +AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) +m4_if([$1], [CXX], [ + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] + case $host_os in + aix[[4-9]]*) + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to GNU nm, but means don't demangle to AIX nm. + # Without the "-l" option, or with the "-B" option, AIX nm treats + # weak defined symbols like other global defined symbols, whereas + # GNU nm marks them as "W". + # While the 'weak' keyword is ignored in the Export File, we need + # it in the Import File for the 'aix-soname' feature, so we have + # to replace the "-B" option with "-P" for AIX nm. + if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then + _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' + else + _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' + fi + ;; + pw32*) + _LT_TAGVAR(export_symbols_cmds, $1)=$ltdll_cmds + ;; + cygwin* | mingw* | cegcc*) + case $cc_basename in + cl*) + _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' + ;; + *) + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' + _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] + ;; + esac + ;; + linux* | k*bsd*-gnu | gnu*) + _LT_TAGVAR(link_all_deplibs, $1)=no + ;; + *) + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + ;; + esac +], [ + runpath_var= + _LT_TAGVAR(allow_undefined_flag, $1)= + _LT_TAGVAR(always_export_symbols, $1)=no + _LT_TAGVAR(archive_cmds, $1)= + _LT_TAGVAR(archive_expsym_cmds, $1)= + _LT_TAGVAR(compiler_needs_object, $1)=no + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no + _LT_TAGVAR(export_dynamic_flag_spec, $1)= + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + _LT_TAGVAR(hardcode_automatic, $1)=no + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_direct_absolute, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= + _LT_TAGVAR(hardcode_libdir_separator, $1)= + _LT_TAGVAR(hardcode_minus_L, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported + _LT_TAGVAR(inherit_rpath, $1)=no + _LT_TAGVAR(link_all_deplibs, $1)=unknown + _LT_TAGVAR(module_cmds, $1)= + _LT_TAGVAR(module_expsym_cmds, $1)= + _LT_TAGVAR(old_archive_from_new_cmds, $1)= + _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)= + _LT_TAGVAR(thread_safe_flag_spec, $1)= + _LT_TAGVAR(whole_archive_flag_spec, $1)= + # include_expsyms should be a list of space-separated symbols to be *always* + # included in the symbol list + _LT_TAGVAR(include_expsyms, $1)= + # exclude_expsyms can be an extended regexp of symbols to exclude + # it will be wrapped by ' (' and ')$', so one must not match beginning or + # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc', + # as well as any symbol that contains 'd'. + _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] + # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out + # platforms (ab)use it in PIC code, but their linkers get confused if + # the symbol is explicitly referenced. Since portable code cannot + # rely on this symbol name, it's probably fine to never include it in + # preloaded symbol tables. + # Exclude shared library initialization/finalization symbols. +dnl Note also adjust exclude_expsyms for C++ above. + extract_expsyms_cmds= + + case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + # FIXME: the MSVC++ port hasn't been tested in a loooong time + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + if test yes != "$GCC"; then + with_gnu_ld=no + fi + ;; + interix*) + # we just hope/assume this is gcc and not c89 (= MSVC++) + with_gnu_ld=yes + ;; + openbsd* | bitrig*) + with_gnu_ld=no + ;; + linux* | k*bsd*-gnu | gnu*) + _LT_TAGVAR(link_all_deplibs, $1)=no + ;; + esac + + _LT_TAGVAR(ld_shlibs, $1)=yes + + # On some targets, GNU ld is compatible enough with the native linker + # that we're better off using the native interface for both. + lt_use_gnu_ld_interface=no + if test yes = "$with_gnu_ld"; then + case $host_os in + aix*) + # The AIX port of GNU ld has always aspired to compatibility + # with the native linker. However, as the warning in the GNU ld + # block says, versions before 2.19.5* couldn't really create working + # shared libraries, regardless of the interface used. + case `$LD -v 2>&1` in + *\ \(GNU\ Binutils\)\ 2.19.5*) ;; + *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;; + *\ \(GNU\ Binutils\)\ [[3-9]]*) ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + fi + + if test yes = "$lt_use_gnu_ld_interface"; then + # If archive_cmds runs LD, not CC, wlarc should be empty + wlarc='$wl' + + # Set some defaults for GNU ld with shared library support. These + # are reset later if shared libraries are not supported. Putting them + # here allows them to be overridden if necessary. + runpath_var=LD_RUN_PATH + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' + # ancient GNU ld didn't support --whole-archive et. al. + if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then + _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' + else + _LT_TAGVAR(whole_archive_flag_spec, $1)= + fi + supports_anon_versioning=no + case `$LD -v | $SED -e 's/([^)]\+)\s\+//' 2>&1` in + *GNU\ gold*) supports_anon_versioning=yes ;; + *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 + *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... + *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... + *\ 2.11.*) ;; # other 2.11 versions + *) supports_anon_versioning=yes ;; + esac + + # See if GNU ld supports shared libraries. + case $host_os in + aix[[3-9]]*) + # On AIX/PPC, the GNU linker is very broken + if test ia64 != "$host_cpu"; then + _LT_TAGVAR(ld_shlibs, $1)=no + cat <<_LT_EOF 1>&2 + +*** Warning: the GNU linker, at least up to release 2.19, is reported +*** to be unable to reliably create shared libraries on AIX. +*** Therefore, libtool is disabling shared libraries support. If you +*** really care for shared libraries, you may want to install binutils +*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. +*** You will then need to restart the configuration process. + +_LT_EOF + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='' + ;; + m68k) + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_minus_L, $1)=yes + ;; + esac + ;; + + beos*) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + cygwin* | mingw* | pw32* | cegcc*) + # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, + # as there is no search path for DLLs. + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(always_export_symbols, $1)=no + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' + _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] + + if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file, use it as + # is; otherwise, prepend EXPORTS... + _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + haiku*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + + os2*) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + shrext_cmds=.dll + _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + prefix_cmds="$SED"~ + if test EXPORTS = "`$SED 1q $export_symbols`"; then + prefix_cmds="$prefix_cmds -e 1d"; + fi~ + prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ + cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + ;; + + interix[[3-9]]*) + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + + gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) + tmp_diet=no + if test linux-dietlibc = "$host_os"; then + case $cc_basename in + diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) + esac + fi + if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ + && test no = "$tmp_diet" + then + tmp_addflag=' $pic_flag' + tmp_sharedflag='-shared' + case $cc_basename,$host_cpu in + pgcc*) # Portland Group C compiler + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + tmp_addflag=' $pic_flag' + ;; + pgf77* | pgf90* | pgf95* | pgfortran*) + # Portland Group f77 and f90 compilers + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + tmp_addflag=' $pic_flag -Mnomain' ;; + ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 + tmp_addflag=' -i_dynamic' ;; + efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 + tmp_addflag=' -i_dynamic -nofor_main' ;; + ifc* | ifort*) # Intel Fortran compiler + tmp_addflag=' -nofor_main' ;; + lf95*) # Lahey Fortran 8.1 + _LT_TAGVAR(whole_archive_flag_spec, $1)= + tmp_sharedflag='--shared' ;; + nagfor*) # NAGFOR 5.3 + tmp_sharedflag='-Wl,-shared' ;; + xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) + tmp_sharedflag='-qmkshrobj' + tmp_addflag= ;; + nvcc*) # Cuda Compiler Driver 2.2 + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + _LT_TAGVAR(compiler_needs_object, $1)=yes + ;; + esac + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) # Sun C 5.9 + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + _LT_TAGVAR(compiler_needs_object, $1)=yes + tmp_sharedflag='-G' ;; + *Sun\ F*) # Sun Fortran 8.3 + tmp_sharedflag='-G' ;; + esac + _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + + if test yes = "$supports_anon_versioning"; then + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' + fi + + case $cc_basename in + tcc*) + _LT_TAGVAR(export_dynamic_flag_spec, $1)='-rdynamic' + ;; + xlf* | bgf* | bgxlf* | mpixlf*) + # IBM XL Fortran 10.1 on PPC cannot create shared libs itself + _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' + if test yes = "$supports_anon_versioning"; then + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' + fi + ;; + esac + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + netbsd* | netbsdelf*-gnu) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' + wlarc= + else + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + fi + ;; + + solaris*) + if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then + _LT_TAGVAR(ld_shlibs, $1)=no + cat <<_LT_EOF 1>&2 + +*** Warning: The releases 2.8.* of the GNU linker cannot reliably +*** create shared libraries on Solaris systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.9.1 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +_LT_EOF + elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) + case `$LD -v 2>&1` in + *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) + _LT_TAGVAR(ld_shlibs, $1)=no + cat <<_LT_EOF 1>&2 + +*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot +*** reliably create shared libraries on SCO systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.16.91.0.3 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +_LT_EOF + ;; + *) + # For security reasons, it is highly recommended that you always + # use absolute paths for naming shared libraries, and exclude the + # DT_RUNPATH tag from executables and libraries. But doing so + # requires that you compile everything twice, which is a pain. + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + + sunos4*) + _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' + wlarc= + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + *) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + + if test no = "$_LT_TAGVAR(ld_shlibs, $1)"; then + runpath_var= + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= + _LT_TAGVAR(export_dynamic_flag_spec, $1)= + _LT_TAGVAR(whole_archive_flag_spec, $1)= + fi + else + # PORTME fill in a description of your system's linker (not GNU ld) + case $host_os in + aix3*) + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(always_export_symbols, $1)=yes + _LT_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' + # Note: this linker hardcodes the directories in LIBPATH if there + # are no directories specified by -L. + _LT_TAGVAR(hardcode_minus_L, $1)=yes + if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then + # Neither direct hardcoding nor static linking is supported with a + # broken collect2. + _LT_TAGVAR(hardcode_direct, $1)=unsupported + fi + ;; + + aix[[4-9]]*) + if test ia64 = "$host_cpu"; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag= + else + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to GNU nm, but means don't demangle to AIX nm. + # Without the "-l" option, or with the "-B" option, AIX nm treats + # weak defined symbols like other global defined symbols, whereas + # GNU nm marks them as "W". + # While the 'weak' keyword is ignored in the Export File, we need + # it in the Import File for the 'aix-soname' feature, so we have + # to replace the "-B" option with "-P" for AIX nm. + if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then + _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' + else + _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' + fi + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # have runtime linking enabled, and use it for executables. + # For shared libraries, we enable/disable runtime linking + # depending on the kind of the shared library created - + # when "with_aix_soname,aix_use_runtimelinking" is: + # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables + # "aix,yes" lib.so shared, rtl:yes, for executables + # lib.a static archive + # "both,no" lib.so.V(shr.o) shared, rtl:yes + # lib.a(lib.so.V) shared, rtl:no, for executables + # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a(lib.so.V) shared, rtl:no + # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a static archive + case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) + for ld_flag in $LDFLAGS; do + if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then + aix_use_runtimelinking=yes + break + fi + done + if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then + # With aix-soname=svr4, we create the lib.so.V shared archives only, + # so we don't have lib.a shared libs to link our executables. + # We have to force runtime linking in this case. + aix_use_runtimelinking=yes + LDFLAGS="$LDFLAGS -Wl,-brtl" + fi + ;; + esac + + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + _LT_TAGVAR(archive_cmds, $1)='' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(hardcode_libdir_separator, $1)=':' + _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='$wl-f,' + case $with_aix_soname,$aix_use_runtimelinking in + aix,*) ;; # traditional, no import file + svr4,* | *,yes) # use import file + # The Import File defines what to hardcode. + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_direct_absolute, $1)=no + ;; + esac + + if test yes = "$GCC"; then + case $host_os in aix4.[[012]]|aix4.[[012]].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`$CC -print-prog-name=collect2` + if test -f "$collect2name" && + strings "$collect2name" | $GREP resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + _LT_TAGVAR(hardcode_direct, $1)=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)= + fi + ;; + esac + shared_flag='-shared' + if test yes = "$aix_use_runtimelinking"; then + shared_flag="$shared_flag "'$wl-G' + fi + # Need to ensure runtime linking is disabled for the traditional + # shared library, or the linker may eventually find shared libraries + # /with/ Import File - we do not want to mix them. + shared_flag_aix='-shared' + shared_flag_svr4='-shared $wl-G' + else + # not using gcc + if test ia64 = "$host_cpu"; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test yes = "$aix_use_runtimelinking"; then + shared_flag='$wl-G' + else + shared_flag='$wl-bM:SRE' + fi + shared_flag_aix='$wl-bM:SRE' + shared_flag_svr4='$wl-G' + fi + fi + + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to export. + _LT_TAGVAR(always_export_symbols, $1)=yes + if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + _LT_TAGVAR(allow_undefined_flag, $1)='-berok' + # Determine the default libpath from the value encoded in an + # empty executable. + _LT_SYS_MODULE_PATH_AIX([$1]) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag + else + if test ia64 = "$host_cpu"; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' + _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" + _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an + # empty executable. + _LT_SYS_MODULE_PATH_AIX([$1]) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' + if test yes = "$with_gnu_ld"; then + # We only use this code for GNU lds that support --whole-archive. + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' + fi + _LT_TAGVAR(archive_cmds_need_lc, $1)=yes + _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' + # -brtl affects multiple linker settings, -berok does not and is overridden later + compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' + if test svr4 != "$with_aix_soname"; then + # This is similar to how AIX traditionally builds its shared libraries. + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' + fi + if test aix != "$with_aix_soname"; then + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' + else + # used by -dlpreopen to get the symbols + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' + fi + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' + fi + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='' + ;; + m68k) + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_minus_L, $1)=yes + ;; + esac + ;; + + bsdi[[45]]*) + _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic + ;; + + cygwin* | mingw* | pw32* | cegcc*) + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + case $cc_basename in + cl*) + # Native MSVC + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(always_export_symbols, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='@' + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=.dll + # FIXME: Setting linknames here is a bad hack. + _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' + _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then + cp "$export_symbols" "$output_objdir/$soname.def"; + echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; + else + $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1,DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' + # Don't use ranlib + _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' + _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile=$lt_outputfile.exe + lt_tool_outputfile=$lt_tool_outputfile.exe + ;; + esac~ + if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # Assume MSVC wrapper + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=.dll + # FIXME: Setting linknames here is a bad hack. + _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' + # The linker will automatically build a .lib file if we build a DLL. + _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' + # FIXME: Should let the user specify the lib program. + _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + ;; + esac + ;; + + darwin* | rhapsody*) + _LT_DARWIN_LINKER_FEATURES($1) + ;; + + dgux*) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor + # support. Future versions do this automatically, but an explicit c++rt0.o + # does not break anything, and helps significantly (at the cost of a little + # extra space). + freebsd2.2*) + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + # Unfortunately, older versions of FreeBSD 2 do not have this feature. + freebsd2.*) + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + # FreeBSD 3 and greater uses gcc -shared to do shared libraries. + freebsd* | dragonfly*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + hpux9*) + if test yes = "$GCC"; then + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' + else + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' + fi + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(hardcode_direct, $1)=yes + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' + ;; + + hpux10*) + if test yes,no = "$GCC,$with_gnu_ld"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + else + _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' + fi + if test no = "$with_gnu_ld"; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + _LT_TAGVAR(hardcode_minus_L, $1)=yes + fi + ;; + + hpux11*) + if test yes,no = "$GCC,$with_gnu_ld"; then + case $host_cpu in + hppa*64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + else + case $host_cpu in + hppa*64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + m4_if($1, [], [ + # Older versions of the 11.00 compiler do not understand -b yet + # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) + _LT_LINKER_OPTION([if $CC understands -b], + _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b], + [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], + [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])], + [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags']) + ;; + esac + fi + if test no = "$with_gnu_ld"; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + case $host_cpu in + hppa*64*|ia64*) + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + *) + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + _LT_TAGVAR(hardcode_minus_L, $1)=yes + ;; + esac + fi + ;; + + irix5* | irix6* | nonstopux*) + if test yes = "$GCC"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + # Try to use the -exported_symbol ld option, if it does not + # work, assume that -exports_file does not work either and + # implicitly export all symbols. + # This should be the same for all languages, so no per-tag cache variable. + AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol], + [lt_cv_irix_exported_symbol], + [save_LDFLAGS=$LDFLAGS + LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null" + AC_LINK_IFELSE( + [AC_LANG_SOURCE( + [AC_LANG_CASE([C], [[int foo (void) { return 0; }]], + [C++], [[int foo (void) { return 0; }]], + [Fortran 77], [[ + subroutine foo + end]], + [Fortran], [[ + subroutine foo + end]])])], + [lt_cv_irix_exported_symbol=yes], + [lt_cv_irix_exported_symbol=no]) + LDFLAGS=$save_LDFLAGS]) + if test yes = "$lt_cv_irix_exported_symbol"; then + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib' + fi + _LT_TAGVAR(link_all_deplibs, $1)=no + else + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib' + fi + _LT_TAGVAR(archive_cmds_need_lc, $1)='no' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(inherit_rpath, $1)=yes + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + + linux*) + case $cc_basename in + tcc*) + # Fabrice Bellard et al's Tiny C Compiler + _LT_TAGVAR(ld_shlibs, $1)=yes + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + netbsd* | netbsdelf*-gnu) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out + else + _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF + fi + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + newsos6) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + *nto* | *qnx*) + ;; + + openbsd* | bitrig*) + if test -f /usr/libexec/ld.so; then + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' + else + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + fi + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + os2*) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + shrext_cmds=.dll + _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + prefix_cmds="$SED"~ + if test EXPORTS = "`$SED 1q $export_symbols`"; then + prefix_cmds="$prefix_cmds -e 1d"; + fi~ + prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ + cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + ;; + + osf3*) + if test yes = "$GCC"; then + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + else + _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + fi + _LT_TAGVAR(archive_cmds_need_lc, $1)='no' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + ;; + + osf4* | osf5*) # as osf3* with the addition of -msym flag + if test yes = "$GCC"; then + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + else + _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ + $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp' + + # Both c and cxx compiler support -rpath directly + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' + fi + _LT_TAGVAR(archive_cmds_need_lc, $1)='no' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + ;; + + solaris*) + _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' + if test yes = "$GCC"; then + wlarc='$wl' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + else + case `$CC -V 2>&1` in + *"Compilers 5.0"*) + wlarc='' + _LT_TAGVAR(archive_cmds, $1)='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' + ;; + *) + wlarc='$wl' + _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + ;; + esac + fi + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + case $host_os in + solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands '-z linker_flag'. GCC discards it without '$wl', + # but is careful enough not to reorder. + # Supported since Solaris 2.6 (maybe 2.5.1?) + if test yes = "$GCC"; then + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' + else + _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' + fi + ;; + esac + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + + sunos4*) + if test sequent = "$host_vendor"; then + # Use $CC to link under sequent, because it throws in some extra .o + # files that make .init and .fini sections work. + _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags' + else + _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' + fi + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + sysv4) + case $host_vendor in + sni) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true??? + ;; + siemens) + ## LD is ld it makes a PLAMLIB + ## CC just makes a GrossModule. + _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' + _LT_TAGVAR(hardcode_direct, $1)=no + ;; + motorola) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie + ;; + esac + runpath_var='LD_RUN_PATH' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + sysv4.3*) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + runpath_var=LD_RUN_PATH + hardcode_runpath_var=yes + _LT_TAGVAR(ld_shlibs, $1)=yes + fi + ;; + + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) + _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + runpath_var='LD_RUN_PATH' + + if test yes = "$GCC"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + + sysv5* | sco3.2v5* | sco5v6*) + # Note: We CANNOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' + _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=':' + _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' + runpath_var='LD_RUN_PATH' + + if test yes = "$GCC"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + + uts4*) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + *) + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + + if test sni = "$host_vendor"; then + case $host in + sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Blargedynsym' + ;; + esac + fi + fi +]) +AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) +test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no + +_LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld + +_LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl +_LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl +_LT_DECL([], [extract_expsyms_cmds], [2], + [The commands to extract the exported symbol list from a shared archive]) + +# +# Do we need to explicitly link libc? +# +case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in +x|xyes) + # Assume -lc should be added + _LT_TAGVAR(archive_cmds_need_lc, $1)=yes + + if test yes,yes = "$GCC,$enable_shared"; then + case $_LT_TAGVAR(archive_cmds, $1) in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + AC_CACHE_CHECK([whether -lc should be explicitly linked in], + [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1), + [$RM conftest* + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + if AC_TRY_EVAL(ac_compile) 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) + pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1) + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1) + _LT_TAGVAR(allow_undefined_flag, $1)= + if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) + then + lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no + else + lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes + fi + _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $RM conftest* + ]) + _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1) + ;; + esac + fi + ;; +esac + +_LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0], + [Whether or not to add -lc for building shared libraries]) +_LT_TAGDECL([allow_libtool_libs_with_static_runtimes], + [enable_shared_with_static_runtimes], [0], + [Whether or not to disallow shared libs when runtime libs are static]) +_LT_TAGDECL([], [export_dynamic_flag_spec], [1], + [Compiler flag to allow reflexive dlopens]) +_LT_TAGDECL([], [whole_archive_flag_spec], [1], + [Compiler flag to generate shared objects directly from archives]) +_LT_TAGDECL([], [compiler_needs_object], [1], + [Whether the compiler copes with passing no objects directly]) +_LT_TAGDECL([], [old_archive_from_new_cmds], [2], + [Create an old-style archive from a shared archive]) +_LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2], + [Create a temporary old-style archive to link instead of a shared archive]) +_LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive]) +_LT_TAGDECL([], [archive_expsym_cmds], [2]) +_LT_TAGDECL([], [module_cmds], [2], + [Commands used to build a loadable module if different from building + a shared archive.]) +_LT_TAGDECL([], [module_expsym_cmds], [2]) +_LT_TAGDECL([], [with_gnu_ld], [1], + [Whether we are building with GNU ld or not]) +_LT_TAGDECL([], [allow_undefined_flag], [1], + [Flag that allows shared libraries with undefined symbols to be built]) +_LT_TAGDECL([], [no_undefined_flag], [1], + [Flag that enforces no undefined symbols]) +_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], + [Flag to hardcode $libdir into a binary during linking. + This must work even if $libdir does not exist]) +_LT_TAGDECL([], [hardcode_libdir_separator], [1], + [Whether we need a single "-rpath" flag with a separated argument]) +_LT_TAGDECL([], [hardcode_direct], [0], + [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes + DIR into the resulting binary]) +_LT_TAGDECL([], [hardcode_direct_absolute], [0], + [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes + DIR into the resulting binary and the resulting library dependency is + "absolute", i.e impossible to change by setting $shlibpath_var if the + library is relocated]) +_LT_TAGDECL([], [hardcode_minus_L], [0], + [Set to "yes" if using the -LDIR flag during linking hardcodes DIR + into the resulting binary]) +_LT_TAGDECL([], [hardcode_shlibpath_var], [0], + [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR + into the resulting binary]) +_LT_TAGDECL([], [hardcode_automatic], [0], + [Set to "yes" if building a shared library automatically hardcodes DIR + into the library and all subsequent libraries and executables linked + against it]) +_LT_TAGDECL([], [inherit_rpath], [0], + [Set to yes if linker adds runtime paths of dependent libraries + to runtime path list]) +_LT_TAGDECL([], [link_all_deplibs], [0], + [Whether libtool must link a program against all its dependency libraries]) +_LT_TAGDECL([], [always_export_symbols], [0], + [Set to "yes" if exported symbols are required]) +_LT_TAGDECL([], [export_symbols_cmds], [2], + [The commands to list exported symbols]) +_LT_TAGDECL([], [exclude_expsyms], [1], + [Symbols that should not be listed in the preloaded symbols]) +_LT_TAGDECL([], [include_expsyms], [1], + [Symbols that must always be exported]) +_LT_TAGDECL([], [prelink_cmds], [2], + [Commands necessary for linking programs (against libraries) with templates]) +_LT_TAGDECL([], [postlink_cmds], [2], + [Commands necessary for finishing linking programs]) +_LT_TAGDECL([], [file_list_spec], [1], + [Specify filename containing input files]) +dnl FIXME: Not yet implemented +dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1], +dnl [Compiler flag to generate thread safe objects]) +])# _LT_LINKER_SHLIBS + + +# _LT_LANG_C_CONFIG([TAG]) +# ------------------------ +# Ensure that the configuration variables for a C compiler are suitably +# defined. These variables are subsequently used by _LT_CONFIG to write +# the compiler configuration to 'libtool'. +m4_defun([_LT_LANG_C_CONFIG], +[m4_require([_LT_DECL_EGREP])dnl +lt_save_CC=$CC +AC_LANG_PUSH(C) + +# Source file extension for C test sources. +ac_ext=c + +# Object file extension for compiled C test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code="int some_variable = 0;" + +# Code to be used in simple link tests +lt_simple_link_test_code='int main(){return(0);}' + +_LT_TAG_COMPILER +# Save the default compiler, since it gets overwritten when the other +# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. +compiler_DEFAULT=$CC + +# save warnings/boilerplate of simple test code +_LT_COMPILER_BOILERPLATE +_LT_LINKER_BOILERPLATE + +if test -n "$compiler"; then + _LT_COMPILER_NO_RTTI($1) + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_SYS_DYNAMIC_LINKER($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + LT_SYS_DLOPEN_SELF + _LT_CMD_STRIPLIB + + # Report what library types will actually be built + AC_MSG_CHECKING([if libtool supports shared libraries]) + AC_MSG_RESULT([$can_build_shared]) + + AC_MSG_CHECKING([whether to build shared libraries]) + test no = "$can_build_shared" && enable_shared=no + + # On AIX, shared libraries and static libraries use the same namespace, and + # are all built from PIC. + case $host_os in + aix3*) + test yes = "$enable_shared" && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; + + aix[[4-9]]*) + if test ia64 != "$host_cpu"; then + case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in + yes,aix,yes) ;; # shared object as lib.so file only + yes,svr4,*) ;; # shared object as lib.so archive member only + yes,*) enable_static=no ;; # shared object in lib.a archive as well + esac + fi + ;; + esac + AC_MSG_RESULT([$enable_shared]) + + AC_MSG_CHECKING([whether to build static libraries]) + # Make sure either enable_shared or enable_static is yes. + test yes = "$enable_shared" || enable_static=yes + AC_MSG_RESULT([$enable_static]) + + _LT_CONFIG($1) +fi +AC_LANG_POP +CC=$lt_save_CC +])# _LT_LANG_C_CONFIG + + +# _LT_LANG_CXX_CONFIG([TAG]) +# -------------------------- +# Ensure that the configuration variables for a C++ compiler are suitably +# defined. These variables are subsequently used by _LT_CONFIG to write +# the compiler configuration to 'libtool'. +m4_defun([_LT_LANG_CXX_CONFIG], +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_PATH_MANIFEST_TOOL])dnl +if test -n "$CXX" && ( test no != "$CXX" && + ( (test g++ = "$CXX" && `g++ -v >/dev/null 2>&1` ) || + (test g++ != "$CXX"))); then + AC_PROG_CXXCPP +else + _lt_caught_CXX_error=yes +fi + +AC_LANG_PUSH(C++) +_LT_TAGVAR(archive_cmds_need_lc, $1)=no +_LT_TAGVAR(allow_undefined_flag, $1)= +_LT_TAGVAR(always_export_symbols, $1)=no +_LT_TAGVAR(archive_expsym_cmds, $1)= +_LT_TAGVAR(compiler_needs_object, $1)=no +_LT_TAGVAR(export_dynamic_flag_spec, $1)= +_LT_TAGVAR(hardcode_direct, $1)=no +_LT_TAGVAR(hardcode_direct_absolute, $1)=no +_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= +_LT_TAGVAR(hardcode_libdir_separator, $1)= +_LT_TAGVAR(hardcode_minus_L, $1)=no +_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported +_LT_TAGVAR(hardcode_automatic, $1)=no +_LT_TAGVAR(inherit_rpath, $1)=no +_LT_TAGVAR(module_cmds, $1)= +_LT_TAGVAR(module_expsym_cmds, $1)= +_LT_TAGVAR(link_all_deplibs, $1)=unknown +_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_TAGVAR(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds +_LT_TAGVAR(no_undefined_flag, $1)= +_LT_TAGVAR(whole_archive_flag_spec, $1)= +_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no + +# Source file extension for C++ test sources. +ac_ext=cpp + +# Object file extension for compiled C++ test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# No sense in running all these tests if we already determined that +# the CXX compiler isn't working. Some variables (like enable_shared) +# are currently assumed to apply to all compilers on this platform, +# and will be corrupted by setting them based on a non-working compiler. +if test yes != "$_lt_caught_CXX_error"; then + # Code to be used in simple compile tests + lt_simple_compile_test_code="int some_variable = 0;" + + # Code to be used in simple link tests + lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' + + # ltmain only uses $CC for tagged configurations so make sure $CC is set. + _LT_TAG_COMPILER + + # save warnings/boilerplate of simple test code + _LT_COMPILER_BOILERPLATE + _LT_LINKER_BOILERPLATE + + # Allow CC to be a program name with arguments. + lt_save_CC=$CC + lt_save_CFLAGS=$CFLAGS + lt_save_LD=$LD + lt_save_GCC=$GCC + GCC=$GXX + lt_save_with_gnu_ld=$with_gnu_ld + lt_save_path_LD=$lt_cv_path_LD + if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then + lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx + else + $as_unset lt_cv_prog_gnu_ld + fi + if test -n "${lt_cv_path_LDCXX+set}"; then + lt_cv_path_LD=$lt_cv_path_LDCXX + else + $as_unset lt_cv_path_LD + fi + test -z "${LDCXX+set}" || LD=$LDCXX + CC=${CXX-"c++"} + CFLAGS=$CXXFLAGS + compiler=$CC + _LT_TAGVAR(compiler, $1)=$CC + _LT_CC_BASENAME([$compiler]) + + if test -n "$compiler"; then + # We don't want -fno-exception when compiling C++ code, so set the + # no_builtin_flag separately + if test yes = "$GXX"; then + _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' + else + _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= + fi + + if test yes = "$GXX"; then + # Set up default GNU C++ configuration + + LT_PATH_LD + + # Check if GNU C++ uses GNU ld as the underlying linker, since the + # archiving commands below assume that GNU ld is being used. + if test yes = "$with_gnu_ld"; then + _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' + + # If archive_cmds runs LD, not CC, wlarc should be empty + # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to + # investigate it a little bit more. (MM) + wlarc='$wl' + + # ancient GNU ld didn't support --whole-archive et. al. + if eval "`$CC -print-prog-name=ld` --help 2>&1" | + $GREP 'no-whole-archive' > /dev/null; then + _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' + else + _LT_TAGVAR(whole_archive_flag_spec, $1)= + fi + else + with_gnu_ld=no + wlarc= + + # A generic and very simple default shared library creation + # command for GNU C++ for the case where it uses the native + # linker, instead of GNU ld. If possible, this setting should + # overridden to take advantage of the native linker features on + # the platform it is being used on. + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' + fi + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + + else + GXX=no + with_gnu_ld=no + wlarc= + fi + + # PORTME: fill in a description of your system's C++ link characteristics + AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) + _LT_TAGVAR(ld_shlibs, $1)=yes + case $host_os in + aix3*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + aix[[4-9]]*) + if test ia64 = "$host_cpu"; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag= + else + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # have runtime linking enabled, and use it for executables. + # For shared libraries, we enable/disable runtime linking + # depending on the kind of the shared library created - + # when "with_aix_soname,aix_use_runtimelinking" is: + # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables + # "aix,yes" lib.so shared, rtl:yes, for executables + # lib.a static archive + # "both,no" lib.so.V(shr.o) shared, rtl:yes + # lib.a(lib.so.V) shared, rtl:no, for executables + # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a(lib.so.V) shared, rtl:no + # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a static archive + case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) + for ld_flag in $LDFLAGS; do + case $ld_flag in + *-brtl*) + aix_use_runtimelinking=yes + break + ;; + esac + done + if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then + # With aix-soname=svr4, we create the lib.so.V shared archives only, + # so we don't have lib.a shared libs to link our executables. + # We have to force runtime linking in this case. + aix_use_runtimelinking=yes + LDFLAGS="$LDFLAGS -Wl,-brtl" + fi + ;; + esac + + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + _LT_TAGVAR(archive_cmds, $1)='' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(hardcode_libdir_separator, $1)=':' + _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='$wl-f,' + case $with_aix_soname,$aix_use_runtimelinking in + aix,*) ;; # no import file + svr4,* | *,yes) # use import file + # The Import File defines what to hardcode. + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_direct_absolute, $1)=no + ;; + esac + + if test yes = "$GXX"; then + case $host_os in aix4.[[012]]|aix4.[[012]].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`$CC -print-prog-name=collect2` + if test -f "$collect2name" && + strings "$collect2name" | $GREP resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + _LT_TAGVAR(hardcode_direct, $1)=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)= + fi + esac + shared_flag='-shared' + if test yes = "$aix_use_runtimelinking"; then + shared_flag=$shared_flag' $wl-G' + fi + # Need to ensure runtime linking is disabled for the traditional + # shared library, or the linker may eventually find shared libraries + # /with/ Import File - we do not want to mix them. + shared_flag_aix='-shared' + shared_flag_svr4='-shared $wl-G' + else + # not using gcc + if test ia64 = "$host_cpu"; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test yes = "$aix_use_runtimelinking"; then + shared_flag='$wl-G' + else + shared_flag='$wl-bM:SRE' + fi + shared_flag_aix='$wl-bM:SRE' + shared_flag_svr4='$wl-G' + fi + fi + + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to + # export. + _LT_TAGVAR(always_export_symbols, $1)=yes + if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + # The "-G" linker flag allows undefined symbols. + _LT_TAGVAR(no_undefined_flag, $1)='-bernotok' + # Determine the default libpath from the value encoded in an empty + # executable. + _LT_SYS_MODULE_PATH_AIX([$1]) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" + + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag + else + if test ia64 = "$host_cpu"; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' + _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" + _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an + # empty executable. + _LT_SYS_MODULE_PATH_AIX([$1]) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' + if test yes = "$with_gnu_ld"; then + # We only use this code for GNU lds that support --whole-archive. + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' + fi + _LT_TAGVAR(archive_cmds_need_lc, $1)=yes + _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' + # -brtl affects multiple linker settings, -berok does not and is overridden later + compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' + if test svr4 != "$with_aix_soname"; then + # This is similar to how AIX traditionally builds its shared + # libraries. Need -bnortl late, we may have -brtl in LDFLAGS. + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' + fi + if test aix != "$with_aix_soname"; then + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' + else + # used by -dlpreopen to get the symbols + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' + fi + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' + fi + fi + ;; + + beos*) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + chorus*) + case $cc_basename in + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + + cygwin* | mingw* | pw32* | cegcc*) + case $GXX,$cc_basename in + ,cl* | no,cl*) + # Native MSVC + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(always_export_symbols, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='@' + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=.dll + # FIXME: Setting linknames here is a bad hack. + _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' + _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then + cp "$export_symbols" "$output_objdir/$soname.def"; + echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; + else + $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + # Don't use ranlib + _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' + _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile=$lt_outputfile.exe + lt_tool_outputfile=$lt_tool_outputfile.exe + ;; + esac~ + func_to_tool_file "$lt_outputfile"~ + if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # g++ + # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, + # as there is no search path for DLLs. + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(always_export_symbols, $1)=no + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + + if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file, use it as + # is; otherwise, prepend EXPORTS... + _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + darwin* | rhapsody*) + _LT_DARWIN_LINKER_FEATURES($1) + ;; + + os2*) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + shrext_cmds=.dll + _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + prefix_cmds="$SED"~ + if test EXPORTS = "`$SED 1q $export_symbols`"; then + prefix_cmds="$prefix_cmds -e 1d"; + fi~ + prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ + cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + ;; + + dgux*) + case $cc_basename in + ec++*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + ghcx*) + # Green Hills C++ Compiler + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + + freebsd2.*) + # C++ shared libraries reported to be fairly broken before + # switch to ELF + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + freebsd-elf*) + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + ;; + + freebsd* | dragonfly*) + # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF + # conventions + _LT_TAGVAR(ld_shlibs, $1)=yes + ;; + + haiku*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + + hpux9*) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, + # but as the default + # location of the library. + + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + aCC*) + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test yes = "$GXX"; then + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' + else + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + + hpux10*|hpux11*) + if test no = "$with_gnu_ld"; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + case $host_cpu in + hppa*64*|ia64*) + ;; + *) + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' + ;; + esac + fi + case $host_cpu in + hppa*64*|ia64*) + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + *) + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, + # but as the default + # location of the library. + ;; + esac + + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + aCC*) + case $host_cpu in + hppa*64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + ia64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + esac + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test yes = "$GXX"; then + if test no = "$with_gnu_ld"; then + case $host_cpu in + hppa*64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + ia64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + esac + fi + else + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + + interix[[3-9]]*) + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + irix5* | irix6*) + case $cc_basename in + CC*) + # SGI C++ + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + + # Archives containing C++ object files must be created using + # "CC -ar", where "CC" is the IRIX C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' + ;; + *) + if test yes = "$GXX"; then + if test no = "$with_gnu_ld"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + else + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` -o $lib' + fi + fi + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + esac + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(inherit_rpath, $1)=yes + ;; + + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib $wl-retain-symbols-file,$export_symbols; mv \$templib $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' + + # Archives containing C++ object files must be created using + # "CC -Bstatic", where "CC" is the KAI C++ compiler. + _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' + ;; + icpc* | ecpc* ) + # Intel C++ + with_gnu_ld=yes + # version 8.0 and above of icpc choke on multiply defined symbols + # if we add $predep_objects and $postdep_objects, however 7.1 and + # earlier do not add the objects themselves. + case `$CC -V 2>&1` in + *"Version 7."*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + ;; + *) # Version 8.0 or newer + tmp_idyn= + case $host_cpu in + ia64*) tmp_idyn=' -i_dynamic';; + esac + _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + ;; + esac + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' + ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler + case `$CC -V` in + *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*) + _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ + compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' + _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ + $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ + $RANLIB $oldlib' + _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + ;; + *) # Version 6 and above use weak symbols + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + ;; + esac + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl--rpath $wl$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + ;; + cxx*) + # Compaq C++ + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib $wl-retain-symbols-file $wl$export_symbols' + + runpath_var=LD_RUN_PATH + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' + ;; + xl* | mpixl* | bgxl*) + # IBM XL 8.0 on PPC, with GNU ld + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' + _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + if test yes = "$supports_anon_versioning"; then + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' + fi + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' + _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file $wl$export_symbols' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + _LT_TAGVAR(compiler_needs_object, $1)=yes + + # Not sure whether something based on + # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 + # would be better. + output_verbose_link_cmd='func_echo_all' + + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' + ;; + esac + ;; + esac + ;; + + lynxos*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + m88k*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + mvs*) + case $cc_basename in + cxx*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + + netbsd*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' + wlarc= + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + fi + # Workaround some broken pre-1.5 toolchains + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' + ;; + + *nto* | *qnx*) + _LT_TAGVAR(ld_shlibs, $1)=yes + ;; + + openbsd* | bitrig*) + if test -f /usr/libexec/ld.so; then + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`"; then + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file,$export_symbols -o $lib' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' + _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' + fi + output_verbose_link_cmd=func_echo_all + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + osf3* | osf4* | osf5*) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + # Archives containing C++ object files must be created using + # the KAI C++ compiler. + case $host in + osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; + *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;; + esac + ;; + RCC*) + # Rational C++ 2.4.1 + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + cxx*) + case $host in + osf3*) + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $soname `test -n "$verstring" && func_echo_all "$wl-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + ;; + *) + _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ + echo "-hidden">> $lib.exp~ + $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname $wl-input $wl$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~ + $RM $lib.exp' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' + ;; + esac + + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test yes,no = "$GXX,$with_gnu_ld"; then + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' + case $host in + osf3*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + ;; + esac + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + + else + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + + psos*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + lcc*) + # Lucid + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + + solaris*) + case $cc_basename in + CC* | sunCC*) + # Sun C++ 4.2, 5.x and Centerline C++ + _LT_TAGVAR(archive_cmds_need_lc,$1)=yes + _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' + _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G$allow_undefined_flag $wl-M $wl$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + case $host_os in + solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands '-z linker_flag'. + # Supported since Solaris 2.6 (maybe 2.5.1?) + _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' + ;; + esac + _LT_TAGVAR(link_all_deplibs, $1)=yes + + output_verbose_link_cmd='func_echo_all' + + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' + ;; + gcx*) + # Green Hills C++ Compiler + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' + + # The C++ compiler must be used to create the archive. + _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' + ;; + *) + # GNU C++ compiler with Solaris linker + if test yes,no = "$GXX,$with_gnu_ld"; then + _LT_TAGVAR(no_undefined_flag, $1)=' $wl-z ${wl}defs' + if $CC --version | $GREP -v '^2\.7' > /dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -shared $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + else + # g++ 2.7 appears to require '-G' NOT '-shared' on this + # platform. + _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + fi + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $wl$libdir' + case $host_os in + solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; + *) + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' + ;; + esac + fi + ;; + esac + ;; + + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) + _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + sysv5* | sco3.2v5* | sco5v6*) + # Note: We CANNOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' + _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=':' + _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~ + '"$_LT_TAGVAR(old_archive_cmds, $1)" + _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~ + '"$_LT_TAGVAR(reload_cmds, $1)" + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + + vxworks*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + + AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) + test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no + + _LT_TAGVAR(GCC, $1)=$GXX + _LT_TAGVAR(LD, $1)=$LD + + ## CAVEAT EMPTOR: + ## There is no encapsulation within the following macros, do not change + ## the running order or otherwise move them around unless you know exactly + ## what you are doing... + _LT_SYS_HIDDEN_LIBDEPS($1) + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_SYS_DYNAMIC_LINKER($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + + _LT_CONFIG($1) + fi # test -n "$compiler" + + CC=$lt_save_CC + CFLAGS=$lt_save_CFLAGS + LDCXX=$LD + LD=$lt_save_LD + GCC=$lt_save_GCC + with_gnu_ld=$lt_save_with_gnu_ld + lt_cv_path_LDCXX=$lt_cv_path_LD + lt_cv_path_LD=$lt_save_path_LD + lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld + lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld +fi # test yes != "$_lt_caught_CXX_error" + +AC_LANG_POP +])# _LT_LANG_CXX_CONFIG + + +# _LT_FUNC_STRIPNAME_CNF +# ---------------------- +# func_stripname_cnf prefix suffix name +# strip PREFIX and SUFFIX off of NAME. +# PREFIX and SUFFIX must not contain globbing or regex special +# characters, hashes, percent signs, but SUFFIX may contain a leading +# dot (in which case that matches only a dot). +# +# This function is identical to the (non-XSI) version of func_stripname, +# except this one can be used by m4 code that may be executed by configure, +# rather than the libtool script. +m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl +AC_REQUIRE([_LT_DECL_SED]) +AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH]) +func_stripname_cnf () +{ + case @S|@2 in + .*) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%\\\\@S|@2\$%%"`;; + *) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%@S|@2\$%%"`;; + esac +} # func_stripname_cnf +])# _LT_FUNC_STRIPNAME_CNF + + +# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) +# --------------------------------- +# Figure out "hidden" library dependencies from verbose +# compiler output when linking a shared library. +# Parse the compiler output and extract the necessary +# objects, libraries and library flags. +m4_defun([_LT_SYS_HIDDEN_LIBDEPS], +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl +AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl +# Dependencies to place before and after the object being linked: +_LT_TAGVAR(predep_objects, $1)= +_LT_TAGVAR(postdep_objects, $1)= +_LT_TAGVAR(predeps, $1)= +_LT_TAGVAR(postdeps, $1)= +_LT_TAGVAR(compiler_lib_search_path, $1)= + +dnl we can't use the lt_simple_compile_test_code here, +dnl because it contains code intended for an executable, +dnl not a library. It's possible we should let each +dnl tag define a new lt_????_link_test_code variable, +dnl but it's only used here... +m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF +int a; +void foo (void) { a = 0; } +_LT_EOF +], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF +class Foo +{ +public: + Foo (void) { a = 0; } +private: + int a; +}; +_LT_EOF +], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF + subroutine foo + implicit none + integer*4 a + a=0 + return + end +_LT_EOF +], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF + subroutine foo + implicit none + integer a + a=0 + return + end +_LT_EOF +], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF +public class foo { + private int a; + public void bar (void) { + a = 0; + } +}; +_LT_EOF +], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF +package foo +func foo() { +} +_LT_EOF +]) + +_lt_libdeps_save_CFLAGS=$CFLAGS +case "$CC $CFLAGS " in #( +*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; +*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; +*\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;; +esac + +dnl Parse the compiler output and extract the necessary +dnl objects, libraries and library flags. +if AC_TRY_EVAL(ac_compile); then + # Parse the compiler output and extract the necessary + # objects, libraries and library flags. + + # Sentinel used to keep track of whether or not we are before + # the conftest object file. + pre_test_object_deps_done=no + + for p in `eval "$output_verbose_link_cmd"`; do + case $prev$p in + + -L* | -R* | -l*) + # Some compilers place space between "-{L,R}" and the path. + # Remove the space. + if test x-L = "$p" || + test x-R = "$p"; then + prev=$p + continue + fi + + # Expand the sysroot to ease extracting the directories later. + if test -z "$prev"; then + case $p in + -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; + -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; + -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; + esac + fi + case $p in + =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; + esac + if test no = "$pre_test_object_deps_done"; then + case $prev in + -L | -R) + # Internal compiler library paths should come after those + # provided the user. The postdeps already come after the + # user supplied libs so there is no need to process them. + if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then + _LT_TAGVAR(compiler_lib_search_path, $1)=$prev$p + else + _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} $prev$p" + fi + ;; + # The "-l" case would never come before the object being + # linked, so don't bother handling this case. + esac + else + if test -z "$_LT_TAGVAR(postdeps, $1)"; then + _LT_TAGVAR(postdeps, $1)=$prev$p + else + _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} $prev$p" + fi + fi + prev= + ;; + + *.lto.$objext) ;; # Ignore GCC LTO objects + *.$objext) + # This assumes that the test object file only shows up + # once in the compiler output. + if test "$p" = "conftest.$objext"; then + pre_test_object_deps_done=yes + continue + fi + + if test no = "$pre_test_object_deps_done"; then + if test -z "$_LT_TAGVAR(predep_objects, $1)"; then + _LT_TAGVAR(predep_objects, $1)=$p + else + _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" + fi + else + if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then + _LT_TAGVAR(postdep_objects, $1)=$p + else + _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" + fi + fi + ;; + + *) ;; # Ignore the rest. + + esac + done + + # Clean up. + rm -f a.out a.exe +else + echo "libtool.m4: error: problem compiling $1 test program" +fi + +$RM -f confest.$objext +CFLAGS=$_lt_libdeps_save_CFLAGS + +# PORTME: override above test on systems where it is broken +m4_if([$1], [CXX], +[case $host_os in +interix[[3-9]]*) + # Interix 3.5 installs completely hosed .la files for C++, so rather than + # hack all around it, let's just trust "g++" to DTRT. + _LT_TAGVAR(predep_objects,$1)= + _LT_TAGVAR(postdep_objects,$1)= + _LT_TAGVAR(postdeps,$1)= + ;; +esac +]) + +case " $_LT_TAGVAR(postdeps, $1) " in +*" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; +esac + _LT_TAGVAR(compiler_lib_search_dirs, $1)= +if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then + _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | $SED -e 's! -L! !g' -e 's!^ !!'` +fi +_LT_TAGDECL([], [compiler_lib_search_dirs], [1], + [The directories searched by this compiler when creating a shared library]) +_LT_TAGDECL([], [predep_objects], [1], + [Dependencies to place before and after the objects being linked to + create a shared library]) +_LT_TAGDECL([], [postdep_objects], [1]) +_LT_TAGDECL([], [predeps], [1]) +_LT_TAGDECL([], [postdeps], [1]) +_LT_TAGDECL([], [compiler_lib_search_path], [1], + [The library search path used internally by the compiler when linking + a shared library]) +])# _LT_SYS_HIDDEN_LIBDEPS + + +# _LT_LANG_F77_CONFIG([TAG]) +# -------------------------- +# Ensure that the configuration variables for a Fortran 77 compiler are +# suitably defined. These variables are subsequently used by _LT_CONFIG +# to write the compiler configuration to 'libtool'. +m4_defun([_LT_LANG_F77_CONFIG], +[AC_LANG_PUSH(Fortran 77) +if test -z "$F77" || test no = "$F77"; then + _lt_disable_F77=yes +fi + +_LT_TAGVAR(archive_cmds_need_lc, $1)=no +_LT_TAGVAR(allow_undefined_flag, $1)= +_LT_TAGVAR(always_export_symbols, $1)=no +_LT_TAGVAR(archive_expsym_cmds, $1)= +_LT_TAGVAR(export_dynamic_flag_spec, $1)= +_LT_TAGVAR(hardcode_direct, $1)=no +_LT_TAGVAR(hardcode_direct_absolute, $1)=no +_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= +_LT_TAGVAR(hardcode_libdir_separator, $1)= +_LT_TAGVAR(hardcode_minus_L, $1)=no +_LT_TAGVAR(hardcode_automatic, $1)=no +_LT_TAGVAR(inherit_rpath, $1)=no +_LT_TAGVAR(module_cmds, $1)= +_LT_TAGVAR(module_expsym_cmds, $1)= +_LT_TAGVAR(link_all_deplibs, $1)=unknown +_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_TAGVAR(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds +_LT_TAGVAR(no_undefined_flag, $1)= +_LT_TAGVAR(whole_archive_flag_spec, $1)= +_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no + +# Source file extension for f77 test sources. +ac_ext=f + +# Object file extension for compiled f77 test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# No sense in running all these tests if we already determined that +# the F77 compiler isn't working. Some variables (like enable_shared) +# are currently assumed to apply to all compilers on this platform, +# and will be corrupted by setting them based on a non-working compiler. +if test yes != "$_lt_disable_F77"; then + # Code to be used in simple compile tests + lt_simple_compile_test_code="\ + subroutine t + return + end +" + + # Code to be used in simple link tests + lt_simple_link_test_code="\ + program t + end +" + + # ltmain only uses $CC for tagged configurations so make sure $CC is set. + _LT_TAG_COMPILER + + # save warnings/boilerplate of simple test code + _LT_COMPILER_BOILERPLATE + _LT_LINKER_BOILERPLATE + + # Allow CC to be a program name with arguments. + lt_save_CC=$CC + lt_save_GCC=$GCC + lt_save_CFLAGS=$CFLAGS + CC=${F77-"f77"} + CFLAGS=$FFLAGS + compiler=$CC + _LT_TAGVAR(compiler, $1)=$CC + _LT_CC_BASENAME([$compiler]) + GCC=$G77 + if test -n "$compiler"; then + AC_MSG_CHECKING([if libtool supports shared libraries]) + AC_MSG_RESULT([$can_build_shared]) + + AC_MSG_CHECKING([whether to build shared libraries]) + test no = "$can_build_shared" && enable_shared=no + + # On AIX, shared libraries and static libraries use the same namespace, and + # are all built from PIC. + case $host_os in + aix3*) + test yes = "$enable_shared" && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; + aix[[4-9]]*) + if test ia64 != "$host_cpu"; then + case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in + yes,aix,yes) ;; # shared object as lib.so file only + yes,svr4,*) ;; # shared object as lib.so archive member only + yes,*) enable_static=no ;; # shared object in lib.a archive as well + esac + fi + ;; + esac + AC_MSG_RESULT([$enable_shared]) + + AC_MSG_CHECKING([whether to build static libraries]) + # Make sure either enable_shared or enable_static is yes. + test yes = "$enable_shared" || enable_static=yes + AC_MSG_RESULT([$enable_static]) + + _LT_TAGVAR(GCC, $1)=$G77 + _LT_TAGVAR(LD, $1)=$LD + + ## CAVEAT EMPTOR: + ## There is no encapsulation within the following macros, do not change + ## the running order or otherwise move them around unless you know exactly + ## what you are doing... + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_SYS_DYNAMIC_LINKER($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + + _LT_CONFIG($1) + fi # test -n "$compiler" + + GCC=$lt_save_GCC + CC=$lt_save_CC + CFLAGS=$lt_save_CFLAGS +fi # test yes != "$_lt_disable_F77" + +AC_LANG_POP +])# _LT_LANG_F77_CONFIG + + +# _LT_LANG_FC_CONFIG([TAG]) +# ------------------------- +# Ensure that the configuration variables for a Fortran compiler are +# suitably defined. These variables are subsequently used by _LT_CONFIG +# to write the compiler configuration to 'libtool'. +m4_defun([_LT_LANG_FC_CONFIG], +[AC_LANG_PUSH(Fortran) + +if test -z "$FC" || test no = "$FC"; then + _lt_disable_FC=yes +fi + +_LT_TAGVAR(archive_cmds_need_lc, $1)=no +_LT_TAGVAR(allow_undefined_flag, $1)= +_LT_TAGVAR(always_export_symbols, $1)=no +_LT_TAGVAR(archive_expsym_cmds, $1)= +_LT_TAGVAR(export_dynamic_flag_spec, $1)= +_LT_TAGVAR(hardcode_direct, $1)=no +_LT_TAGVAR(hardcode_direct_absolute, $1)=no +_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= +_LT_TAGVAR(hardcode_libdir_separator, $1)= +_LT_TAGVAR(hardcode_minus_L, $1)=no +_LT_TAGVAR(hardcode_automatic, $1)=no +_LT_TAGVAR(inherit_rpath, $1)=no +_LT_TAGVAR(module_cmds, $1)= +_LT_TAGVAR(module_expsym_cmds, $1)= +_LT_TAGVAR(link_all_deplibs, $1)=unknown +_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_TAGVAR(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds +_LT_TAGVAR(no_undefined_flag, $1)= +_LT_TAGVAR(whole_archive_flag_spec, $1)= +_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no + +# Source file extension for fc test sources. +ac_ext=${ac_fc_srcext-f} + +# Object file extension for compiled fc test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# No sense in running all these tests if we already determined that +# the FC compiler isn't working. Some variables (like enable_shared) +# are currently assumed to apply to all compilers on this platform, +# and will be corrupted by setting them based on a non-working compiler. +if test yes != "$_lt_disable_FC"; then + # Code to be used in simple compile tests + lt_simple_compile_test_code="\ + subroutine t + return + end +" + + # Code to be used in simple link tests + lt_simple_link_test_code="\ + program t + end +" + + # ltmain only uses $CC for tagged configurations so make sure $CC is set. + _LT_TAG_COMPILER + + # save warnings/boilerplate of simple test code + _LT_COMPILER_BOILERPLATE + _LT_LINKER_BOILERPLATE + + # Allow CC to be a program name with arguments. + lt_save_CC=$CC + lt_save_GCC=$GCC + lt_save_CFLAGS=$CFLAGS + CC=${FC-"f95"} + CFLAGS=$FCFLAGS + compiler=$CC + GCC=$ac_cv_fc_compiler_gnu + + _LT_TAGVAR(compiler, $1)=$CC + _LT_CC_BASENAME([$compiler]) + + if test -n "$compiler"; then + AC_MSG_CHECKING([if libtool supports shared libraries]) + AC_MSG_RESULT([$can_build_shared]) + + AC_MSG_CHECKING([whether to build shared libraries]) + test no = "$can_build_shared" && enable_shared=no + + # On AIX, shared libraries and static libraries use the same namespace, and + # are all built from PIC. + case $host_os in + aix3*) + test yes = "$enable_shared" && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; + aix[[4-9]]*) + if test ia64 != "$host_cpu"; then + case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in + yes,aix,yes) ;; # shared object as lib.so file only + yes,svr4,*) ;; # shared object as lib.so archive member only + yes,*) enable_static=no ;; # shared object in lib.a archive as well + esac + fi + ;; + esac + AC_MSG_RESULT([$enable_shared]) + + AC_MSG_CHECKING([whether to build static libraries]) + # Make sure either enable_shared or enable_static is yes. + test yes = "$enable_shared" || enable_static=yes + AC_MSG_RESULT([$enable_static]) + + _LT_TAGVAR(GCC, $1)=$ac_cv_fc_compiler_gnu + _LT_TAGVAR(LD, $1)=$LD + + ## CAVEAT EMPTOR: + ## There is no encapsulation within the following macros, do not change + ## the running order or otherwise move them around unless you know exactly + ## what you are doing... + _LT_SYS_HIDDEN_LIBDEPS($1) + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_SYS_DYNAMIC_LINKER($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + + _LT_CONFIG($1) + fi # test -n "$compiler" + + GCC=$lt_save_GCC + CC=$lt_save_CC + CFLAGS=$lt_save_CFLAGS +fi # test yes != "$_lt_disable_FC" + +AC_LANG_POP +])# _LT_LANG_FC_CONFIG + + +# _LT_LANG_GCJ_CONFIG([TAG]) +# -------------------------- +# Ensure that the configuration variables for the GNU Java Compiler compiler +# are suitably defined. These variables are subsequently used by _LT_CONFIG +# to write the compiler configuration to 'libtool'. +m4_defun([_LT_LANG_GCJ_CONFIG], +[AC_REQUIRE([LT_PROG_GCJ])dnl +AC_LANG_SAVE + +# Source file extension for Java test sources. +ac_ext=java + +# Object file extension for compiled Java test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code="class foo {}" + +# Code to be used in simple link tests +lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' + +# ltmain only uses $CC for tagged configurations so make sure $CC is set. +_LT_TAG_COMPILER + +# save warnings/boilerplate of simple test code +_LT_COMPILER_BOILERPLATE +_LT_LINKER_BOILERPLATE + +# Allow CC to be a program name with arguments. +lt_save_CC=$CC +lt_save_CFLAGS=$CFLAGS +lt_save_GCC=$GCC +GCC=yes +CC=${GCJ-"gcj"} +CFLAGS=$GCJFLAGS +compiler=$CC +_LT_TAGVAR(compiler, $1)=$CC +_LT_TAGVAR(LD, $1)=$LD +_LT_CC_BASENAME([$compiler]) + +# GCJ did not exist at the time GCC didn't implicitly link libc in. +_LT_TAGVAR(archive_cmds_need_lc, $1)=no + +_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_TAGVAR(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds + +if test -n "$compiler"; then + _LT_COMPILER_NO_RTTI($1) + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + + _LT_CONFIG($1) +fi + +AC_LANG_RESTORE + +GCC=$lt_save_GCC +CC=$lt_save_CC +CFLAGS=$lt_save_CFLAGS +])# _LT_LANG_GCJ_CONFIG + + +# _LT_LANG_GO_CONFIG([TAG]) +# -------------------------- +# Ensure that the configuration variables for the GNU Go compiler +# are suitably defined. These variables are subsequently used by _LT_CONFIG +# to write the compiler configuration to 'libtool'. +m4_defun([_LT_LANG_GO_CONFIG], +[AC_REQUIRE([LT_PROG_GO])dnl +AC_LANG_SAVE + +# Source file extension for Go test sources. +ac_ext=go + +# Object file extension for compiled Go test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code="package main; func main() { }" + +# Code to be used in simple link tests +lt_simple_link_test_code='package main; func main() { }' + +# ltmain only uses $CC for tagged configurations so make sure $CC is set. +_LT_TAG_COMPILER + +# save warnings/boilerplate of simple test code +_LT_COMPILER_BOILERPLATE +_LT_LINKER_BOILERPLATE + +# Allow CC to be a program name with arguments. +lt_save_CC=$CC +lt_save_CFLAGS=$CFLAGS +lt_save_GCC=$GCC +GCC=yes +CC=${GOC-"gccgo"} +CFLAGS=$GOFLAGS +compiler=$CC +_LT_TAGVAR(compiler, $1)=$CC +_LT_TAGVAR(LD, $1)=$LD +_LT_CC_BASENAME([$compiler]) + +# Go did not exist at the time GCC didn't implicitly link libc in. +_LT_TAGVAR(archive_cmds_need_lc, $1)=no + +_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_TAGVAR(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds + +if test -n "$compiler"; then + _LT_COMPILER_NO_RTTI($1) + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + + _LT_CONFIG($1) +fi + +AC_LANG_RESTORE + +GCC=$lt_save_GCC +CC=$lt_save_CC +CFLAGS=$lt_save_CFLAGS +])# _LT_LANG_GO_CONFIG + + +# _LT_LANG_RC_CONFIG([TAG]) +# ------------------------- +# Ensure that the configuration variables for the Windows resource compiler +# are suitably defined. These variables are subsequently used by _LT_CONFIG +# to write the compiler configuration to 'libtool'. +m4_defun([_LT_LANG_RC_CONFIG], +[AC_REQUIRE([LT_PROG_RC])dnl +AC_LANG_SAVE + +# Source file extension for RC test sources. +ac_ext=rc + +# Object file extension for compiled RC test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' + +# Code to be used in simple link tests +lt_simple_link_test_code=$lt_simple_compile_test_code + +# ltmain only uses $CC for tagged configurations so make sure $CC is set. +_LT_TAG_COMPILER + +# save warnings/boilerplate of simple test code +_LT_COMPILER_BOILERPLATE +_LT_LINKER_BOILERPLATE + +# Allow CC to be a program name with arguments. +lt_save_CC=$CC +lt_save_CFLAGS=$CFLAGS +lt_save_GCC=$GCC +GCC= +CC=${RC-"windres"} +CFLAGS= +compiler=$CC +_LT_TAGVAR(compiler, $1)=$CC +_LT_CC_BASENAME([$compiler]) +_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes + +if test -n "$compiler"; then + : + _LT_CONFIG($1) +fi + +GCC=$lt_save_GCC +AC_LANG_RESTORE +CC=$lt_save_CC +CFLAGS=$lt_save_CFLAGS +])# _LT_LANG_RC_CONFIG + + +# LT_PROG_GCJ +# ----------- +AC_DEFUN([LT_PROG_GCJ], +[m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], + [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], + [AC_CHECK_TOOL(GCJ, gcj,) + test set = "${GCJFLAGS+set}" || GCJFLAGS="-g -O2" + AC_SUBST(GCJFLAGS)])])[]dnl +]) + +# Old name: +AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([LT_AC_PROG_GCJ], []) + + +# LT_PROG_GO +# ---------- +AC_DEFUN([LT_PROG_GO], +[AC_CHECK_TOOL(GOC, gccgo,) +]) + + +# LT_PROG_RC +# ---------- +AC_DEFUN([LT_PROG_RC], +[AC_CHECK_TOOL(RC, windres,) +]) + +# Old name: +AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([LT_AC_PROG_RC], []) + + +# _LT_DECL_EGREP +# -------------- +# If we don't have a new enough Autoconf to choose the best grep +# available, choose the one first in the user's PATH. +m4_defun([_LT_DECL_EGREP], +[AC_REQUIRE([AC_PROG_EGREP])dnl +AC_REQUIRE([AC_PROG_FGREP])dnl +test -z "$GREP" && GREP=grep +_LT_DECL([], [GREP], [1], [A grep program that handles long lines]) +_LT_DECL([], [EGREP], [1], [An ERE matcher]) +_LT_DECL([], [FGREP], [1], [A literal string matcher]) +dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too +AC_SUBST([GREP]) +]) + + +# _LT_DECL_OBJDUMP +# -------------- +# If we don't have a new enough Autoconf to choose the best objdump +# available, choose the one first in the user's PATH. +m4_defun([_LT_DECL_OBJDUMP], +[AC_CHECK_TOOL(OBJDUMP, objdump, false) +test -z "$OBJDUMP" && OBJDUMP=objdump +_LT_DECL([], [OBJDUMP], [1], [An object symbol dumper]) +AC_SUBST([OBJDUMP]) +]) + +# _LT_DECL_DLLTOOL +# ---------------- +# Ensure DLLTOOL variable is set. +m4_defun([_LT_DECL_DLLTOOL], +[AC_CHECK_TOOL(DLLTOOL, dlltool, false) +test -z "$DLLTOOL" && DLLTOOL=dlltool +_LT_DECL([], [DLLTOOL], [1], [DLL creation program]) +AC_SUBST([DLLTOOL]) +]) + +# _LT_DECL_SED +# ------------ +# Check for a fully-functional sed program, that truncates +# as few characters as possible. Prefer GNU sed if found. +m4_defun([_LT_DECL_SED], +[AC_PROG_SED +test -z "$SED" && SED=sed +Xsed="$SED -e 1s/^X//" +_LT_DECL([], [SED], [1], [A sed program that does not truncate output]) +_LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"], + [Sed that helps us avoid accidentally triggering echo(1) options like -n]) +])# _LT_DECL_SED + +m4_ifndef([AC_PROG_SED], [ +# NOTE: This macro has been submitted for inclusion into # +# GNU Autoconf as AC_PROG_SED. When it is available in # +# a released version of Autoconf we should remove this # +# macro and use it instead. # + +m4_defun([AC_PROG_SED], +[AC_MSG_CHECKING([for a sed that does not truncate output]) +AC_CACHE_VAL(lt_cv_path_SED, +[# Loop through the user's path and test for sed and gsed. +# Then use that list of sed's as ones to test for truncation. +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for lt_ac_prog in sed gsed; do + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then + lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" + fi + done + done +done +IFS=$as_save_IFS +lt_ac_max=0 +lt_ac_count=0 +# Add /usr/xpg4/bin/sed as it is typically found on Solaris +# along with /bin/sed that truncates output. +for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do + test ! -f "$lt_ac_sed" && continue + cat /dev/null > conftest.in + lt_ac_count=0 + echo $ECHO_N "0123456789$ECHO_C" >conftest.in + # Check for GNU sed and select it if it is found. + if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then + lt_cv_path_SED=$lt_ac_sed + break + fi + while true; do + cat conftest.in conftest.in >conftest.tmp + mv conftest.tmp conftest.in + cp conftest.in conftest.nl + echo >>conftest.nl + $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break + cmp -s conftest.out conftest.nl || break + # 10000 chars as input seems more than enough + test 10 -lt "$lt_ac_count" && break + lt_ac_count=`expr $lt_ac_count + 1` + if test "$lt_ac_count" -gt "$lt_ac_max"; then + lt_ac_max=$lt_ac_count + lt_cv_path_SED=$lt_ac_sed + fi + done +done +]) +SED=$lt_cv_path_SED +AC_SUBST([SED]) +AC_MSG_RESULT([$SED]) +])#AC_PROG_SED +])#m4_ifndef + +# Old name: +AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([LT_AC_PROG_SED], []) + + +# _LT_CHECK_SHELL_FEATURES +# ------------------------ +# Find out whether the shell is Bourne or XSI compatible, +# or has some other useful features. +m4_defun([_LT_CHECK_SHELL_FEATURES], +[if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then + lt_unset=unset +else + lt_unset=false +fi +_LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl + +# test EBCDIC or ASCII +case `echo X|tr X '\101'` in + A) # ASCII based system + # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr + lt_SP2NL='tr \040 \012' + lt_NL2SP='tr \015\012 \040\040' + ;; + *) # EBCDIC based system + lt_SP2NL='tr \100 \n' + lt_NL2SP='tr \r\n \100\100' + ;; +esac +_LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl +_LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl +])# _LT_CHECK_SHELL_FEATURES + + +# _LT_PATH_CONVERSION_FUNCTIONS +# ----------------------------- +# Determine what file name conversion functions should be used by +# func_to_host_file (and, implicitly, by func_to_host_path). These are needed +# for certain cross-compile configurations and native mingw. +m4_defun([_LT_PATH_CONVERSION_FUNCTIONS], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +AC_REQUIRE([AC_CANONICAL_BUILD])dnl +AC_MSG_CHECKING([how to convert $build file names to $host format]) +AC_CACHE_VAL(lt_cv_to_host_file_cmd, +[case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 + ;; + esac + ;; + *-*-cygwin* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin + ;; + esac + ;; + * ) # unhandled hosts (and "normal" native builds) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; +esac +]) +to_host_file_cmd=$lt_cv_to_host_file_cmd +AC_MSG_RESULT([$lt_cv_to_host_file_cmd]) +_LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd], + [0], [convert $build file names to $host format])dnl + +AC_MSG_CHECKING([how to convert $build file names to toolchain format]) +AC_CACHE_VAL(lt_cv_to_tool_file_cmd, +[#assume ordinary cross tools, or native build. +lt_cv_to_tool_file_cmd=func_convert_file_noop +case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 + ;; + esac + ;; +esac +]) +to_tool_file_cmd=$lt_cv_to_tool_file_cmd +AC_MSG_RESULT([$lt_cv_to_tool_file_cmd]) +_LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd], + [0], [convert $build files to toolchain format])dnl +])# _LT_PATH_CONVERSION_FUNCTIONS + +# Helper functions for option handling. -*- Autoconf -*- +# +# Copyright (C) 2004-2005, 2007-2009, 2011-2015 Free Software +# Foundation, Inc. +# Written by Gary V. Vaughan, 2004 +# +# This file is free software; the Free Software Foundation gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. + +# serial 8 ltoptions.m4 + +# This is to help aclocal find these macros, as it can't see m4_define. +AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) + + +# _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME) +# ------------------------------------------ +m4_define([_LT_MANGLE_OPTION], +[[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])]) + + +# _LT_SET_OPTION(MACRO-NAME, OPTION-NAME) +# --------------------------------------- +# Set option OPTION-NAME for macro MACRO-NAME, and if there is a +# matching handler defined, dispatch to it. Other OPTION-NAMEs are +# saved as a flag. +m4_define([_LT_SET_OPTION], +[m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl +m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), + _LT_MANGLE_DEFUN([$1], [$2]), + [m4_warning([Unknown $1 option '$2'])])[]dnl +]) + + +# _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET]) +# ------------------------------------------------------------ +# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. +m4_define([_LT_IF_OPTION], +[m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])]) + + +# _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET) +# ------------------------------------------------------- +# Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME +# are set. +m4_define([_LT_UNLESS_OPTIONS], +[m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), + [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option), + [m4_define([$0_found])])])[]dnl +m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3 +])[]dnl +]) + + +# _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST) +# ---------------------------------------- +# OPTION-LIST is a space-separated list of Libtool options associated +# with MACRO-NAME. If any OPTION has a matching handler declared with +# LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about +# the unknown option and exit. +m4_defun([_LT_SET_OPTIONS], +[# Set options +m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), + [_LT_SET_OPTION([$1], _LT_Option)]) + +m4_if([$1],[LT_INIT],[ + dnl + dnl Simply set some default values (i.e off) if boolean options were not + dnl specified: + _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no + ]) + _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no + ]) + dnl + dnl If no reference was made to various pairs of opposing options, then + dnl we run the default mode handler for the pair. For example, if neither + dnl 'shared' nor 'disable-shared' was passed, we enable building of shared + dnl archives by default: + _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) + _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) + _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) + _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], + [_LT_ENABLE_FAST_INSTALL]) + _LT_UNLESS_OPTIONS([LT_INIT], [aix-soname=aix aix-soname=both aix-soname=svr4], + [_LT_WITH_AIX_SONAME([aix])]) + ]) +])# _LT_SET_OPTIONS + + + +# _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME) +# ----------------------------------------- +m4_define([_LT_MANGLE_DEFUN], +[[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])]) + + +# LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE) +# ----------------------------------------------- +m4_define([LT_OPTION_DEFINE], +[m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl +])# LT_OPTION_DEFINE + + +# dlopen +# ------ +LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes +]) + +AU_DEFUN([AC_LIBTOOL_DLOPEN], +[_LT_SET_OPTION([LT_INIT], [dlopen]) +AC_DIAGNOSE([obsolete], +[$0: Remove this warning and the call to _LT_SET_OPTION when you +put the 'dlopen' option into LT_INIT's first parameter.]) +]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], []) + + +# win32-dll +# --------- +# Declare package support for building win32 dll's. +LT_OPTION_DEFINE([LT_INIT], [win32-dll], +[enable_win32_dll=yes + +case $host in +*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) + AC_CHECK_TOOL(AS, as, false) + AC_CHECK_TOOL(DLLTOOL, dlltool, false) + AC_CHECK_TOOL(OBJDUMP, objdump, false) + ;; +esac + +test -z "$AS" && AS=as +_LT_DECL([], [AS], [1], [Assembler program])dnl + +test -z "$DLLTOOL" && DLLTOOL=dlltool +_LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl + +test -z "$OBJDUMP" && OBJDUMP=objdump +_LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl +])# win32-dll + +AU_DEFUN([AC_LIBTOOL_WIN32_DLL], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +_LT_SET_OPTION([LT_INIT], [win32-dll]) +AC_DIAGNOSE([obsolete], +[$0: Remove this warning and the call to _LT_SET_OPTION when you +put the 'win32-dll' option into LT_INIT's first parameter.]) +]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) + + +# _LT_ENABLE_SHARED([DEFAULT]) +# ---------------------------- +# implement the --enable-shared flag, and supports the 'shared' and +# 'disable-shared' LT_INIT options. +# DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. +m4_define([_LT_ENABLE_SHARED], +[m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl +AC_ARG_ENABLE([shared], + [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@], + [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])], + [p=${PACKAGE-default} + case $enableval in + yes) enable_shared=yes ;; + no) enable_shared=no ;; + *) + enable_shared=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, + for pkg in $enableval; do + IFS=$lt_save_ifs + if test "X$pkg" = "X$p"; then + enable_shared=yes + fi + done + IFS=$lt_save_ifs + ;; + esac], + [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) + + _LT_DECL([build_libtool_libs], [enable_shared], [0], + [Whether or not to build shared libraries]) +])# _LT_ENABLE_SHARED + +LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])]) +LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])]) + +# Old names: +AC_DEFUN([AC_ENABLE_SHARED], +[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared]) +]) + +AC_DEFUN([AC_DISABLE_SHARED], +[_LT_SET_OPTION([LT_INIT], [disable-shared]) +]) + +AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) +AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AM_ENABLE_SHARED], []) +dnl AC_DEFUN([AM_DISABLE_SHARED], []) + + + +# _LT_ENABLE_STATIC([DEFAULT]) +# ---------------------------- +# implement the --enable-static flag, and support the 'static' and +# 'disable-static' LT_INIT options. +# DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. +m4_define([_LT_ENABLE_STATIC], +[m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl +AC_ARG_ENABLE([static], + [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@], + [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])], + [p=${PACKAGE-default} + case $enableval in + yes) enable_static=yes ;; + no) enable_static=no ;; + *) + enable_static=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, + for pkg in $enableval; do + IFS=$lt_save_ifs + if test "X$pkg" = "X$p"; then + enable_static=yes + fi + done + IFS=$lt_save_ifs + ;; + esac], + [enable_static=]_LT_ENABLE_STATIC_DEFAULT) + + _LT_DECL([build_old_libs], [enable_static], [0], + [Whether or not to build static libraries]) +])# _LT_ENABLE_STATIC + +LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])]) +LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])]) + +# Old names: +AC_DEFUN([AC_ENABLE_STATIC], +[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static]) +]) + +AC_DEFUN([AC_DISABLE_STATIC], +[_LT_SET_OPTION([LT_INIT], [disable-static]) +]) + +AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) +AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AM_ENABLE_STATIC], []) +dnl AC_DEFUN([AM_DISABLE_STATIC], []) + + + +# _LT_ENABLE_FAST_INSTALL([DEFAULT]) +# ---------------------------------- +# implement the --enable-fast-install flag, and support the 'fast-install' +# and 'disable-fast-install' LT_INIT options. +# DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. +m4_define([_LT_ENABLE_FAST_INSTALL], +[m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl +AC_ARG_ENABLE([fast-install], + [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], + [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], + [p=${PACKAGE-default} + case $enableval in + yes) enable_fast_install=yes ;; + no) enable_fast_install=no ;; + *) + enable_fast_install=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, + for pkg in $enableval; do + IFS=$lt_save_ifs + if test "X$pkg" = "X$p"; then + enable_fast_install=yes + fi + done + IFS=$lt_save_ifs + ;; + esac], + [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) + +_LT_DECL([fast_install], [enable_fast_install], [0], + [Whether or not to optimize for fast installation])dnl +])# _LT_ENABLE_FAST_INSTALL + +LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])]) +LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])]) + +# Old names: +AU_DEFUN([AC_ENABLE_FAST_INSTALL], +[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) +AC_DIAGNOSE([obsolete], +[$0: Remove this warning and the call to _LT_SET_OPTION when you put +the 'fast-install' option into LT_INIT's first parameter.]) +]) + +AU_DEFUN([AC_DISABLE_FAST_INSTALL], +[_LT_SET_OPTION([LT_INIT], [disable-fast-install]) +AC_DIAGNOSE([obsolete], +[$0: Remove this warning and the call to _LT_SET_OPTION when you put +the 'disable-fast-install' option into LT_INIT's first parameter.]) +]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) +dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) + + +# _LT_WITH_AIX_SONAME([DEFAULT]) +# ---------------------------------- +# implement the --with-aix-soname flag, and support the `aix-soname=aix' +# and `aix-soname=both' and `aix-soname=svr4' LT_INIT options. DEFAULT +# is either `aix', `both' or `svr4'. If omitted, it defaults to `aix'. +m4_define([_LT_WITH_AIX_SONAME], +[m4_define([_LT_WITH_AIX_SONAME_DEFAULT], [m4_if($1, svr4, svr4, m4_if($1, both, both, aix))])dnl +shared_archive_member_spec= +case $host,$enable_shared in +power*-*-aix[[5-9]]*,yes) + AC_MSG_CHECKING([which variant of shared library versioning to provide]) + AC_ARG_WITH([aix-soname], + [AS_HELP_STRING([--with-aix-soname=aix|svr4|both], + [shared library versioning (aka "SONAME") variant to provide on AIX, @<:@default=]_LT_WITH_AIX_SONAME_DEFAULT[@:>@.])], + [case $withval in + aix|svr4|both) + ;; + *) + AC_MSG_ERROR([Unknown argument to --with-aix-soname]) + ;; + esac + lt_cv_with_aix_soname=$with_aix_soname], + [AC_CACHE_VAL([lt_cv_with_aix_soname], + [lt_cv_with_aix_soname=]_LT_WITH_AIX_SONAME_DEFAULT) + with_aix_soname=$lt_cv_with_aix_soname]) + AC_MSG_RESULT([$with_aix_soname]) + if test aix != "$with_aix_soname"; then + # For the AIX way of multilib, we name the shared archive member + # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o', + # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File. + # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag, + # the AIX toolchain works better with OBJECT_MODE set (default 32). + if test 64 = "${OBJECT_MODE-32}"; then + shared_archive_member_spec=shr_64 + else + shared_archive_member_spec=shr + fi + fi + ;; +*) + with_aix_soname=aix + ;; +esac + +_LT_DECL([], [shared_archive_member_spec], [0], + [Shared archive member basename, for filename based shared library versioning on AIX])dnl +])# _LT_WITH_AIX_SONAME + +LT_OPTION_DEFINE([LT_INIT], [aix-soname=aix], [_LT_WITH_AIX_SONAME([aix])]) +LT_OPTION_DEFINE([LT_INIT], [aix-soname=both], [_LT_WITH_AIX_SONAME([both])]) +LT_OPTION_DEFINE([LT_INIT], [aix-soname=svr4], [_LT_WITH_AIX_SONAME([svr4])]) + + +# _LT_WITH_PIC([MODE]) +# -------------------- +# implement the --with-pic flag, and support the 'pic-only' and 'no-pic' +# LT_INIT options. +# MODE is either 'yes' or 'no'. If omitted, it defaults to 'both'. +m4_define([_LT_WITH_PIC], +[AC_ARG_WITH([pic], + [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@], + [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], + [lt_p=${PACKAGE-default} + case $withval in + yes|no) pic_mode=$withval ;; + *) + pic_mode=default + # Look at the argument we got. We use all the common list separators. + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, + for lt_pkg in $withval; do + IFS=$lt_save_ifs + if test "X$lt_pkg" = "X$lt_p"; then + pic_mode=yes + fi + done + IFS=$lt_save_ifs + ;; + esac], + [pic_mode=m4_default([$1], [default])]) + +_LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl +])# _LT_WITH_PIC + +LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])]) +LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])]) + +# Old name: +AU_DEFUN([AC_LIBTOOL_PICMODE], +[_LT_SET_OPTION([LT_INIT], [pic-only]) +AC_DIAGNOSE([obsolete], +[$0: Remove this warning and the call to _LT_SET_OPTION when you +put the 'pic-only' option into LT_INIT's first parameter.]) +]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_PICMODE], []) + + +m4_define([_LTDL_MODE], []) +LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive], + [m4_define([_LTDL_MODE], [nonrecursive])]) +LT_OPTION_DEFINE([LTDL_INIT], [recursive], + [m4_define([_LTDL_MODE], [recursive])]) +LT_OPTION_DEFINE([LTDL_INIT], [subproject], + [m4_define([_LTDL_MODE], [subproject])]) + +m4_define([_LTDL_TYPE], []) +LT_OPTION_DEFINE([LTDL_INIT], [installable], + [m4_define([_LTDL_TYPE], [installable])]) +LT_OPTION_DEFINE([LTDL_INIT], [convenience], + [m4_define([_LTDL_TYPE], [convenience])]) + +# ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*- +# +# Copyright (C) 2004-2005, 2007-2008, 2011-2015 Free Software +# Foundation, Inc. +# Written by Gary V. Vaughan, 2004 +# +# This file is free software; the Free Software Foundation gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. + +# serial 6 ltsugar.m4 + +# This is to help aclocal find these macros, as it can't see m4_define. +AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])]) + + +# lt_join(SEP, ARG1, [ARG2...]) +# ----------------------------- +# Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their +# associated separator. +# Needed until we can rely on m4_join from Autoconf 2.62, since all earlier +# versions in m4sugar had bugs. +m4_define([lt_join], +[m4_if([$#], [1], [], + [$#], [2], [[$2]], + [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])]) +m4_define([_lt_join], +[m4_if([$#$2], [2], [], + [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])]) + + +# lt_car(LIST) +# lt_cdr(LIST) +# ------------ +# Manipulate m4 lists. +# These macros are necessary as long as will still need to support +# Autoconf-2.59, which quotes differently. +m4_define([lt_car], [[$1]]) +m4_define([lt_cdr], +[m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])], + [$#], 1, [], + [m4_dquote(m4_shift($@))])]) +m4_define([lt_unquote], $1) + + +# lt_append(MACRO-NAME, STRING, [SEPARATOR]) +# ------------------------------------------ +# Redefine MACRO-NAME to hold its former content plus 'SEPARATOR''STRING'. +# Note that neither SEPARATOR nor STRING are expanded; they are appended +# to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked). +# No SEPARATOR is output if MACRO-NAME was previously undefined (different +# than defined and empty). +# +# This macro is needed until we can rely on Autoconf 2.62, since earlier +# versions of m4sugar mistakenly expanded SEPARATOR but not STRING. +m4_define([lt_append], +[m4_define([$1], + m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])]) + + + +# lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...]) +# ---------------------------------------------------------- +# Produce a SEP delimited list of all paired combinations of elements of +# PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list +# has the form PREFIXmINFIXSUFFIXn. +# Needed until we can rely on m4_combine added in Autoconf 2.62. +m4_define([lt_combine], +[m4_if(m4_eval([$# > 3]), [1], + [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl +[[m4_foreach([_Lt_prefix], [$2], + [m4_foreach([_Lt_suffix], + ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[, + [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])]) + + +# lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ]) +# ----------------------------------------------------------------------- +# Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited +# by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ. +m4_define([lt_if_append_uniq], +[m4_ifdef([$1], + [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1], + [lt_append([$1], [$2], [$3])$4], + [$5])], + [lt_append([$1], [$2], [$3])$4])]) + + +# lt_dict_add(DICT, KEY, VALUE) +# ----------------------------- +m4_define([lt_dict_add], +[m4_define([$1($2)], [$3])]) + + +# lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE) +# -------------------------------------------- +m4_define([lt_dict_add_subkey], +[m4_define([$1($2:$3)], [$4])]) + + +# lt_dict_fetch(DICT, KEY, [SUBKEY]) +# ---------------------------------- +m4_define([lt_dict_fetch], +[m4_ifval([$3], + m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]), + m4_ifdef([$1($2)], [m4_defn([$1($2)])]))]) + + +# lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE]) +# ----------------------------------------------------------------- +m4_define([lt_if_dict_fetch], +[m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4], + [$5], + [$6])]) + + +# lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...]) +# -------------------------------------------------------------- +m4_define([lt_dict_filter], +[m4_if([$5], [], [], + [lt_join(m4_quote(m4_default([$4], [[, ]])), + lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]), + [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl +]) + +# ltversion.m4 -- version numbers -*- Autoconf -*- +# +# Copyright (C) 2004, 2011-2015 Free Software Foundation, Inc. +# Written by Scott James Remnant, 2004 +# +# This file is free software; the Free Software Foundation gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. + +# @configure_input@ + +# serial 4179 ltversion.m4 +# This file is part of GNU Libtool + +m4_define([LT_PACKAGE_VERSION], [2.4.6]) +m4_define([LT_PACKAGE_REVISION], [2.4.6]) + +AC_DEFUN([LTVERSION_VERSION], +[macro_version='2.4.6' +macro_revision='2.4.6' +_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) +_LT_DECL(, macro_revision, 0) +]) + +# lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*- +# +# Copyright (C) 2004-2005, 2007, 2009, 2011-2015 Free Software +# Foundation, Inc. +# Written by Scott James Remnant, 2004. +# +# This file is free software; the Free Software Foundation gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. + +# serial 5 lt~obsolete.m4 + +# These exist entirely to fool aclocal when bootstrapping libtool. +# +# In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN), +# which have later been changed to m4_define as they aren't part of the +# exported API, or moved to Autoconf or Automake where they belong. +# +# The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN +# in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us +# using a macro with the same name in our local m4/libtool.m4 it'll +# pull the old libtool.m4 in (it doesn't see our shiny new m4_define +# and doesn't know about Autoconf macros at all.) +# +# So we provide this file, which has a silly filename so it's always +# included after everything else. This provides aclocal with the +# AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything +# because those macros already exist, or will be overwritten later. +# We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. +# +# Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here. +# Yes, that means every name once taken will need to remain here until +# we give up compatibility with versions before 1.7, at which point +# we need to keep only those names which we still refer to. + +# This is to help aclocal find these macros, as it can't see m4_define. +AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])]) + +m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])]) +m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])]) +m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])]) +m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])]) +m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])]) +m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])]) +m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])]) +m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])]) +m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])]) +m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])]) +m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])]) +m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])]) +m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])]) +m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])]) +m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])]) +m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])]) +m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])]) +m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])]) +m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])]) +m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])]) +m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])]) +m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])]) +m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])]) +m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])]) +m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])]) +m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])]) +m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])]) +m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])]) +m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])]) +m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])]) +m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])]) +m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])]) +m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])]) +m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])]) +m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])]) +m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])]) +m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])]) +m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])]) +m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])]) +m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])]) +m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])]) +m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])]) +m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])]) +m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])]) +m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])]) +m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])]) +m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])]) +m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])]) +m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])]) +m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])]) +m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])]) +m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])]) +m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])]) +m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])]) +m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])]) +m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])]) +m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])]) +m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])]) +m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])]) +m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])]) +m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])]) + +# Copyright (C) 2002-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_AUTOMAKE_VERSION(VERSION) +# ---------------------------- +# Automake X.Y traces this macro to ensure aclocal.m4 has been +# generated from the m4 files accompanying Automake X.Y. +# (This private macro should not be called outside this file.) +AC_DEFUN([AM_AUTOMAKE_VERSION], +[am__api_version='1.15' +dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to +dnl require some minimum version. Point them to the right macro. +m4_if([$1], [1.15], [], + [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl +]) + +# _AM_AUTOCONF_VERSION(VERSION) +# ----------------------------- +# aclocal traces this macro to find the Autoconf version. +# This is a private macro too. Using m4_define simplifies +# the logic in aclocal, which can simply ignore this definition. +m4_define([_AM_AUTOCONF_VERSION], []) + +# AM_SET_CURRENT_AUTOMAKE_VERSION +# ------------------------------- +# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. +# This function is AC_REQUIREd by AM_INIT_AUTOMAKE. +AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], +[AM_AUTOMAKE_VERSION([1.15])dnl +m4_ifndef([AC_AUTOCONF_VERSION], + [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl +_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) + +# AM_AUX_DIR_EXPAND -*- Autoconf -*- + +# Copyright (C) 2001-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets +# $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to +# '$srcdir', '$srcdir/..', or '$srcdir/../..'. +# +# Of course, Automake must honor this variable whenever it calls a +# tool from the auxiliary directory. The problem is that $srcdir (and +# therefore $ac_aux_dir as well) can be either absolute or relative, +# depending on how configure is run. This is pretty annoying, since +# it makes $ac_aux_dir quite unusable in subdirectories: in the top +# source directory, any form will work fine, but in subdirectories a +# relative path needs to be adjusted first. +# +# $ac_aux_dir/missing +# fails when called from a subdirectory if $ac_aux_dir is relative +# $top_srcdir/$ac_aux_dir/missing +# fails if $ac_aux_dir is absolute, +# fails when called from a subdirectory in a VPATH build with +# a relative $ac_aux_dir +# +# The reason of the latter failure is that $top_srcdir and $ac_aux_dir +# are both prefixed by $srcdir. In an in-source build this is usually +# harmless because $srcdir is '.', but things will broke when you +# start a VPATH build or use an absolute $srcdir. +# +# So we could use something similar to $top_srcdir/$ac_aux_dir/missing, +# iff we strip the leading $srcdir from $ac_aux_dir. That would be: +# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` +# and then we would define $MISSING as +# MISSING="\${SHELL} $am_aux_dir/missing" +# This will work as long as MISSING is not called from configure, because +# unfortunately $(top_srcdir) has no meaning in configure. +# However there are other variables, like CC, which are often used in +# configure, and could therefore not use this "fixed" $ac_aux_dir. +# +# Another solution, used here, is to always expand $ac_aux_dir to an +# absolute PATH. The drawback is that using absolute paths prevent a +# configured tree to be moved without reconfiguration. + +AC_DEFUN([AM_AUX_DIR_EXPAND], +[AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl +# Expand $ac_aux_dir to an absolute path. +am_aux_dir=`cd "$ac_aux_dir" && pwd` +]) + +# AM_CONDITIONAL -*- Autoconf -*- + +# Copyright (C) 1997-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_CONDITIONAL(NAME, SHELL-CONDITION) +# ------------------------------------- +# Define a conditional. +AC_DEFUN([AM_CONDITIONAL], +[AC_PREREQ([2.52])dnl + m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], + [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl +AC_SUBST([$1_TRUE])dnl +AC_SUBST([$1_FALSE])dnl +_AM_SUBST_NOTMAKE([$1_TRUE])dnl +_AM_SUBST_NOTMAKE([$1_FALSE])dnl +m4_define([_AM_COND_VALUE_$1], [$2])dnl +if $2; then + $1_TRUE= + $1_FALSE='#' +else + $1_TRUE='#' + $1_FALSE= +fi +AC_CONFIG_COMMANDS_PRE( +[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then + AC_MSG_ERROR([[conditional "$1" was never defined. +Usually this means the macro was only invoked conditionally.]]) +fi])]) + +# Copyright (C) 1999-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + + +# There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be +# written in clear, in which case automake, when reading aclocal.m4, +# will think it sees a *use*, and therefore will trigger all it's +# C support machinery. Also note that it means that autoscan, seeing +# CC etc. in the Makefile, will ask for an AC_PROG_CC use... + + +# _AM_DEPENDENCIES(NAME) +# ---------------------- +# See how the compiler implements dependency checking. +# NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC". +# We try a few techniques and use that to set a single cache variable. +# +# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was +# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular +# dependency, and given that the user is not expected to run this macro, +# just rely on AC_PROG_CC. +AC_DEFUN([_AM_DEPENDENCIES], +[AC_REQUIRE([AM_SET_DEPDIR])dnl +AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl +AC_REQUIRE([AM_MAKE_INCLUDE])dnl +AC_REQUIRE([AM_DEP_TRACK])dnl + +m4_if([$1], [CC], [depcc="$CC" am_compiler_list=], + [$1], [CXX], [depcc="$CXX" am_compiler_list=], + [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'], + [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'], + [$1], [UPC], [depcc="$UPC" am_compiler_list=], + [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'], + [depcc="$$1" am_compiler_list=]) + +AC_CACHE_CHECK([dependency style of $depcc], + [am_cv_$1_dependencies_compiler_type], +[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then + # We make a subdir and do the tests there. Otherwise we can end up + # making bogus files that we don't know about and never remove. For + # instance it was reported that on HP-UX the gcc test will end up + # making a dummy file named 'D' -- because '-MD' means "put the output + # in D". + rm -rf conftest.dir + mkdir conftest.dir + # Copy depcomp to subdir because otherwise we won't find it if we're + # using a relative directory. + cp "$am_depcomp" conftest.dir + cd conftest.dir + # We will build objects and dependencies in a subdirectory because + # it helps to detect inapplicable dependency modes. For instance + # both Tru64's cc and ICC support -MD to output dependencies as a + # side effect of compilation, but ICC will put the dependencies in + # the current directory while Tru64 will put them in the object + # directory. + mkdir sub + + am_cv_$1_dependencies_compiler_type=none + if test "$am_compiler_list" = ""; then + am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` + fi + am__universal=false + m4_case([$1], [CC], + [case " $depcc " in #( + *\ -arch\ *\ -arch\ *) am__universal=true ;; + esac], + [CXX], + [case " $depcc " in #( + *\ -arch\ *\ -arch\ *) am__universal=true ;; + esac]) + + for depmode in $am_compiler_list; do + # Setup a source with many dependencies, because some compilers + # like to wrap large dependency lists on column 80 (with \), and + # we should not choose a depcomp mode which is confused by this. + # + # We need to recreate these files for each test, as the compiler may + # overwrite some of them when testing with obscure command lines. + # This happens at least with the AIX C compiler. + : > sub/conftest.c + for i in 1 2 3 4 5 6; do + echo '#include "conftst'$i'.h"' >> sub/conftest.c + # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with + # Solaris 10 /bin/sh. + echo '/* dummy */' > sub/conftst$i.h + done + echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf + + # We check with '-c' and '-o' for the sake of the "dashmstdout" + # mode. It turns out that the SunPro C++ compiler does not properly + # handle '-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs. + am__obj=sub/conftest.${OBJEXT-o} + am__minus_obj="-o $am__obj" + case $depmode in + gcc) + # This depmode causes a compiler race in universal mode. + test "$am__universal" = false || continue + ;; + nosideeffect) + # After this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested. + if test "x$enable_dependency_tracking" = xyes; then + continue + else + break + fi + ;; + msvc7 | msvc7msys | msvisualcpp | msvcmsys) + # This compiler won't grok '-c -o', but also, the minuso test has + # not run yet. These depmodes are late enough in the game, and + # so weak that their functioning should not be impacted. + am__obj=conftest.${OBJEXT-o} + am__minus_obj= + ;; + none) break ;; + esac + if depmode=$depmode \ + source=sub/conftest.c object=$am__obj \ + depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ + $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ + >/dev/null 2>conftest.err && + grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && + grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && + grep $am__obj sub/conftest.Po > /dev/null 2>&1 && + ${MAKE-make} -s -f confmf > /dev/null 2>&1; then + # icc doesn't choke on unknown options, it will just issue warnings + # or remarks (even with -Werror). So we grep stderr for any message + # that says an option was ignored or not supported. + # When given -MP, icc 7.0 and 7.1 complain thusly: + # icc: Command line warning: ignoring option '-M'; no argument required + # The diagnosis changed in icc 8.0: + # icc: Command line remark: option '-MP' not supported + if (grep 'ignoring option' conftest.err || + grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else + am_cv_$1_dependencies_compiler_type=$depmode + break + fi + fi + done + + cd .. + rm -rf conftest.dir +else + am_cv_$1_dependencies_compiler_type=none +fi +]) +AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) +AM_CONDITIONAL([am__fastdep$1], [ + test "x$enable_dependency_tracking" != xno \ + && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) +]) + + +# AM_SET_DEPDIR +# ------------- +# Choose a directory name for dependency files. +# This macro is AC_REQUIREd in _AM_DEPENDENCIES. +AC_DEFUN([AM_SET_DEPDIR], +[AC_REQUIRE([AM_SET_LEADING_DOT])dnl +AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl +]) + + +# AM_DEP_TRACK +# ------------ +AC_DEFUN([AM_DEP_TRACK], +[AC_ARG_ENABLE([dependency-tracking], [dnl +AS_HELP_STRING( + [--enable-dependency-tracking], + [do not reject slow dependency extractors]) +AS_HELP_STRING( + [--disable-dependency-tracking], + [speeds up one-time build])]) +if test "x$enable_dependency_tracking" != xno; then + am_depcomp="$ac_aux_dir/depcomp" + AMDEPBACKSLASH='\' + am__nodep='_no' +fi +AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) +AC_SUBST([AMDEPBACKSLASH])dnl +_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl +AC_SUBST([am__nodep])dnl +_AM_SUBST_NOTMAKE([am__nodep])dnl +]) + +# Generate code to set up dependency tracking. -*- Autoconf -*- + +# Copyright (C) 1999-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + + +# _AM_OUTPUT_DEPENDENCY_COMMANDS +# ------------------------------ +AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], +[{ + # Older Autoconf quotes --file arguments for eval, but not when files + # are listed without --file. Let's play safe and only enable the eval + # if we detect the quoting. + case $CONFIG_FILES in + *\'*) eval set x "$CONFIG_FILES" ;; + *) set x $CONFIG_FILES ;; + esac + shift + for mf + do + # Strip MF so we end up with the name of the file. + mf=`echo "$mf" | sed -e 's/:.*$//'` + # Check whether this is an Automake generated Makefile or not. + # We used to match only the files named 'Makefile.in', but + # some people rename them; so instead we look at the file content. + # Grep'ing the first line is not enough: some people post-process + # each Makefile.in and add a new line on top of each file to say so. + # Grep'ing the whole file is not good either: AIX grep has a line + # limit of 2048, but all sed's we know have understand at least 4000. + if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then + dirpart=`AS_DIRNAME("$mf")` + else + continue + fi + # Extract the definition of DEPDIR, am__include, and am__quote + # from the Makefile without running 'make'. + DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` + test -z "$DEPDIR" && continue + am__include=`sed -n 's/^am__include = //p' < "$mf"` + test -z "$am__include" && continue + am__quote=`sed -n 's/^am__quote = //p' < "$mf"` + # Find all dependency output files, they are included files with + # $(DEPDIR) in their names. We invoke sed twice because it is the + # simplest approach to changing $(DEPDIR) to its actual value in the + # expansion. + for file in `sed -n " + s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ + sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do + # Make sure the directory exists. + test -f "$dirpart/$file" && continue + fdir=`AS_DIRNAME(["$file"])` + AS_MKDIR_P([$dirpart/$fdir]) + # echo "creating $dirpart/$file" + echo '# dummy' > "$dirpart/$file" + done + done +} +])# _AM_OUTPUT_DEPENDENCY_COMMANDS + + +# AM_OUTPUT_DEPENDENCY_COMMANDS +# ----------------------------- +# This macro should only be invoked once -- use via AC_REQUIRE. +# +# This code is only required when automatic dependency tracking +# is enabled. FIXME. This creates each '.P' file that we will +# need in order to bootstrap the dependency handling code. +AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], +[AC_CONFIG_COMMANDS([depfiles], + [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], + [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) +]) + +# Do all the work for Automake. -*- Autoconf -*- + +# Copyright (C) 1996-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This macro actually does too much. Some checks are only needed if +# your package does certain things. But this isn't really a big deal. + +dnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O. +m4_define([AC_PROG_CC], +m4_defn([AC_PROG_CC]) +[_AM_PROG_CC_C_O +]) + +# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) +# AM_INIT_AUTOMAKE([OPTIONS]) +# ----------------------------------------------- +# The call with PACKAGE and VERSION arguments is the old style +# call (pre autoconf-2.50), which is being phased out. PACKAGE +# and VERSION should now be passed to AC_INIT and removed from +# the call to AM_INIT_AUTOMAKE. +# We support both call styles for the transition. After +# the next Automake release, Autoconf can make the AC_INIT +# arguments mandatory, and then we can depend on a new Autoconf +# release and drop the old call support. +AC_DEFUN([AM_INIT_AUTOMAKE], +[AC_PREREQ([2.65])dnl +dnl Autoconf wants to disallow AM_ names. We explicitly allow +dnl the ones we care about. +m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl +AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl +AC_REQUIRE([AC_PROG_INSTALL])dnl +if test "`cd $srcdir && pwd`" != "`pwd`"; then + # Use -I$(srcdir) only when $(srcdir) != ., so that make's output + # is not polluted with repeated "-I." + AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl + # test to see if srcdir already configured + if test -f $srcdir/config.status; then + AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) + fi +fi + +# test whether we have cygpath +if test -z "$CYGPATH_W"; then + if (cygpath --version) >/dev/null 2>/dev/null; then + CYGPATH_W='cygpath -w' + else + CYGPATH_W=echo + fi +fi +AC_SUBST([CYGPATH_W]) + +# Define the identity of the package. +dnl Distinguish between old-style and new-style calls. +m4_ifval([$2], +[AC_DIAGNOSE([obsolete], + [$0: two- and three-arguments forms are deprecated.]) +m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl + AC_SUBST([PACKAGE], [$1])dnl + AC_SUBST([VERSION], [$2])], +[_AM_SET_OPTIONS([$1])dnl +dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. +m4_if( + m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]), + [ok:ok],, + [m4_fatal([AC_INIT should be called with package and version arguments])])dnl + AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl + AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl + +_AM_IF_OPTION([no-define],, +[AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package]) + AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl + +# Some tools Automake needs. +AC_REQUIRE([AM_SANITY_CHECK])dnl +AC_REQUIRE([AC_ARG_PROGRAM])dnl +AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}]) +AM_MISSING_PROG([AUTOCONF], [autoconf]) +AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}]) +AM_MISSING_PROG([AUTOHEADER], [autoheader]) +AM_MISSING_PROG([MAKEINFO], [makeinfo]) +AC_REQUIRE([AM_PROG_INSTALL_SH])dnl +AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl +AC_REQUIRE([AC_PROG_MKDIR_P])dnl +# For better backward compatibility. To be removed once Automake 1.9.x +# dies out for good. For more background, see: +# +# +AC_SUBST([mkdir_p], ['$(MKDIR_P)']) +# We need awk for the "check" target (and possibly the TAP driver). The +# system "awk" is bad on some platforms. +AC_REQUIRE([AC_PROG_AWK])dnl +AC_REQUIRE([AC_PROG_MAKE_SET])dnl +AC_REQUIRE([AM_SET_LEADING_DOT])dnl +_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], + [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], + [_AM_PROG_TAR([v7])])]) +_AM_IF_OPTION([no-dependencies],, +[AC_PROVIDE_IFELSE([AC_PROG_CC], + [_AM_DEPENDENCIES([CC])], + [m4_define([AC_PROG_CC], + m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl +AC_PROVIDE_IFELSE([AC_PROG_CXX], + [_AM_DEPENDENCIES([CXX])], + [m4_define([AC_PROG_CXX], + m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl +AC_PROVIDE_IFELSE([AC_PROG_OBJC], + [_AM_DEPENDENCIES([OBJC])], + [m4_define([AC_PROG_OBJC], + m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl +AC_PROVIDE_IFELSE([AC_PROG_OBJCXX], + [_AM_DEPENDENCIES([OBJCXX])], + [m4_define([AC_PROG_OBJCXX], + m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl +]) +AC_REQUIRE([AM_SILENT_RULES])dnl +dnl The testsuite driver may need to know about EXEEXT, so add the +dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This +dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below. +AC_CONFIG_COMMANDS_PRE(dnl +[m4_provide_if([_AM_COMPILER_EXEEXT], + [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl + +# POSIX will say in a future version that running "rm -f" with no argument +# is OK; and we want to be able to make that assumption in our Makefile +# recipes. So use an aggressive probe to check that the usage we want is +# actually supported "in the wild" to an acceptable degree. +# See automake bug#10828. +# To make any issue more visible, cause the running configure to be aborted +# by default if the 'rm' program in use doesn't match our expectations; the +# user can still override this though. +if rm -f && rm -fr && rm -rf; then : OK; else + cat >&2 <<'END' +Oops! + +Your 'rm' program seems unable to run without file operands specified +on the command line, even when the '-f' option is present. This is contrary +to the behaviour of most rm programs out there, and not conforming with +the upcoming POSIX standard: + +Please tell bug-automake@gnu.org about your system, including the value +of your $PATH and any error possibly output before this message. This +can help us improve future automake versions. + +END + if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then + echo 'Configuration will proceed anyway, since you have set the' >&2 + echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 + echo >&2 + else + cat >&2 <<'END' +Aborting the configuration process, to ensure you take notice of the issue. + +You can download and install GNU coreutils to get an 'rm' implementation +that behaves properly: . + +If you want to complete the configuration process using your problematic +'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM +to "yes", and re-run configure. + +END + AC_MSG_ERROR([Your 'rm' program is bad, sorry.]) + fi +fi +dnl The trailing newline in this macro's definition is deliberate, for +dnl backward compatibility and to allow trailing 'dnl'-style comments +dnl after the AM_INIT_AUTOMAKE invocation. See automake bug#16841. +]) + +dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not +dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further +dnl mangled by Autoconf and run in a shell conditional statement. +m4_define([_AC_COMPILER_EXEEXT], +m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])]) + +# When config.status generates a header, we must update the stamp-h file. +# This file resides in the same directory as the config header +# that is generated. The stamp files are numbered to have different names. + +# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the +# loop where config.status creates the headers, so we can generate +# our stamp files there. +AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], +[# Compute $1's index in $config_headers. +_am_arg=$1 +_am_stamp_count=1 +for _am_header in $config_headers :; do + case $_am_header in + $_am_arg | $_am_arg:* ) + break ;; + * ) + _am_stamp_count=`expr $_am_stamp_count + 1` ;; + esac +done +echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) + +# Copyright (C) 2001-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_PROG_INSTALL_SH +# ------------------ +# Define $install_sh. +AC_DEFUN([AM_PROG_INSTALL_SH], +[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl +if test x"${install_sh+set}" != xset; then + case $am_aux_dir in + *\ * | *\ *) + install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; + *) + install_sh="\${SHELL} $am_aux_dir/install-sh" + esac +fi +AC_SUBST([install_sh])]) + +# Copyright (C) 2003-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# Check whether the underlying file-system supports filenames +# with a leading dot. For instance MS-DOS doesn't. +AC_DEFUN([AM_SET_LEADING_DOT], +[rm -rf .tst 2>/dev/null +mkdir .tst 2>/dev/null +if test -d .tst; then + am__leading_dot=. +else + am__leading_dot=_ +fi +rmdir .tst 2>/dev/null +AC_SUBST([am__leading_dot])]) + +# Check to see how 'make' treats includes. -*- Autoconf -*- + +# Copyright (C) 2001-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_MAKE_INCLUDE() +# ----------------- +# Check to see how make treats includes. +AC_DEFUN([AM_MAKE_INCLUDE], +[am_make=${MAKE-make} +cat > confinc << 'END' +am__doit: + @echo this is the am__doit target +.PHONY: am__doit +END +# If we don't find an include directive, just comment out the code. +AC_MSG_CHECKING([for style of include used by $am_make]) +am__include="#" +am__quote= +_am_result=none +# First try GNU make style include. +echo "include confinc" > confmf +# Ignore all kinds of additional output from 'make'. +case `$am_make -s -f confmf 2> /dev/null` in #( +*the\ am__doit\ target*) + am__include=include + am__quote= + _am_result=GNU + ;; +esac +# Now try BSD make style include. +if test "$am__include" = "#"; then + echo '.include "confinc"' > confmf + case `$am_make -s -f confmf 2> /dev/null` in #( + *the\ am__doit\ target*) + am__include=.include + am__quote="\"" + _am_result=BSD + ;; + esac +fi +AC_SUBST([am__include]) +AC_SUBST([am__quote]) +AC_MSG_RESULT([$_am_result]) +rm -f confinc confmf +]) + +# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- + +# Copyright (C) 1997-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_MISSING_PROG(NAME, PROGRAM) +# ------------------------------ +AC_DEFUN([AM_MISSING_PROG], +[AC_REQUIRE([AM_MISSING_HAS_RUN]) +$1=${$1-"${am_missing_run}$2"} +AC_SUBST($1)]) + +# AM_MISSING_HAS_RUN +# ------------------ +# Define MISSING if not defined so far and test if it is modern enough. +# If it is, set am_missing_run to use it, otherwise, to nothing. +AC_DEFUN([AM_MISSING_HAS_RUN], +[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl +AC_REQUIRE_AUX_FILE([missing])dnl +if test x"${MISSING+set}" != xset; then + case $am_aux_dir in + *\ * | *\ *) + MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; + *) + MISSING="\${SHELL} $am_aux_dir/missing" ;; + esac +fi +# Use eval to expand $SHELL +if eval "$MISSING --is-lightweight"; then + am_missing_run="$MISSING " +else + am_missing_run= + AC_MSG_WARN(['missing' script is too old or missing]) +fi +]) + +# Helper functions for option handling. -*- Autoconf -*- + +# Copyright (C) 2001-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# _AM_MANGLE_OPTION(NAME) +# ----------------------- +AC_DEFUN([_AM_MANGLE_OPTION], +[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) + +# _AM_SET_OPTION(NAME) +# -------------------- +# Set option NAME. Presently that only means defining a flag for this option. +AC_DEFUN([_AM_SET_OPTION], +[m4_define(_AM_MANGLE_OPTION([$1]), [1])]) + +# _AM_SET_OPTIONS(OPTIONS) +# ------------------------ +# OPTIONS is a space-separated list of Automake options. +AC_DEFUN([_AM_SET_OPTIONS], +[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) + +# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) +# ------------------------------------------- +# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. +AC_DEFUN([_AM_IF_OPTION], +[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) + +# Copyright (C) 1999-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# _AM_PROG_CC_C_O +# --------------- +# Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC +# to automatically call this. +AC_DEFUN([_AM_PROG_CC_C_O], +[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl +AC_REQUIRE_AUX_FILE([compile])dnl +AC_LANG_PUSH([C])dnl +AC_CACHE_CHECK( + [whether $CC understands -c and -o together], + [am_cv_prog_cc_c_o], + [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])]) + # Make sure it works both with $CC and with simple cc. + # Following AC_PROG_CC_C_O, we do the test twice because some + # compilers refuse to overwrite an existing .o file with -o, + # though they will create one. + am_cv_prog_cc_c_o=yes + for am_i in 1 2; do + if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \ + && test -f conftest2.$ac_objext; then + : OK + else + am_cv_prog_cc_c_o=no + break + fi + done + rm -f core conftest* + unset am_i]) +if test "$am_cv_prog_cc_c_o" != yes; then + # Losing compiler, so override with the script. + # FIXME: It is wrong to rewrite CC. + # But if we don't then we get into trouble of one sort or another. + # A longer-term fix would be to have automake use am__CC in this case, + # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" + CC="$am_aux_dir/compile $CC" +fi +AC_LANG_POP([C])]) + +# For backward compatibility. +AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])]) + +# Copyright (C) 2001-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_RUN_LOG(COMMAND) +# ------------------- +# Run COMMAND, save the exit status in ac_status, and log it. +# (This has been adapted from Autoconf's _AC_RUN_LOG macro.) +AC_DEFUN([AM_RUN_LOG], +[{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD + ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD + (exit $ac_status); }]) + +# Check to make sure that the build environment is sane. -*- Autoconf -*- + +# Copyright (C) 1996-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_SANITY_CHECK +# --------------- +AC_DEFUN([AM_SANITY_CHECK], +[AC_MSG_CHECKING([whether build environment is sane]) +# Reject unsafe characters in $srcdir or the absolute working directory +# name. Accept space and tab only in the latter. +am_lf=' +' +case `pwd` in + *[[\\\"\#\$\&\'\`$am_lf]]*) + AC_MSG_ERROR([unsafe absolute working directory name]);; +esac +case $srcdir in + *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) + AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);; +esac + +# Do 'set' in a subshell so we don't clobber the current shell's +# arguments. Must try -L first in case configure is actually a +# symlink; some systems play weird games with the mod time of symlinks +# (eg FreeBSD returns the mod time of the symlink's containing +# directory). +if ( + am_has_slept=no + for am_try in 1 2; do + echo "timestamp, slept: $am_has_slept" > conftest.file + set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` + if test "$[*]" = "X"; then + # -L didn't work. + set X `ls -t "$srcdir/configure" conftest.file` + fi + if test "$[*]" != "X $srcdir/configure conftest.file" \ + && test "$[*]" != "X conftest.file $srcdir/configure"; then + + # If neither matched, then we have a broken ls. This can happen + # if, for instance, CONFIG_SHELL is bash and it inherits a + # broken ls alias from the environment. This has actually + # happened. Such a system could not be considered "sane". + AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken + alias in your environment]) + fi + if test "$[2]" = conftest.file || test $am_try -eq 2; then + break + fi + # Just in case. + sleep 1 + am_has_slept=yes + done + test "$[2]" = conftest.file + ) +then + # Ok. + : +else + AC_MSG_ERROR([newly created file is older than distributed files! +Check your system clock]) +fi +AC_MSG_RESULT([yes]) +# If we didn't sleep, we still need to ensure time stamps of config.status and +# generated files are strictly newer. +am_sleep_pid= +if grep 'slept: no' conftest.file >/dev/null 2>&1; then + ( sleep 1 ) & + am_sleep_pid=$! +fi +AC_CONFIG_COMMANDS_PRE( + [AC_MSG_CHECKING([that generated files are newer than configure]) + if test -n "$am_sleep_pid"; then + # Hide warnings about reused PIDs. + wait $am_sleep_pid 2>/dev/null + fi + AC_MSG_RESULT([done])]) +rm -f conftest.file +]) + +# Copyright (C) 2009-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_SILENT_RULES([DEFAULT]) +# -------------------------- +# Enable less verbose build rules; with the default set to DEFAULT +# ("yes" being less verbose, "no" or empty being verbose). +AC_DEFUN([AM_SILENT_RULES], +[AC_ARG_ENABLE([silent-rules], [dnl +AS_HELP_STRING( + [--enable-silent-rules], + [less verbose build output (undo: "make V=1")]) +AS_HELP_STRING( + [--disable-silent-rules], + [verbose build output (undo: "make V=0")])dnl +]) +case $enable_silent_rules in @%:@ ((( + yes) AM_DEFAULT_VERBOSITY=0;; + no) AM_DEFAULT_VERBOSITY=1;; + *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);; +esac +dnl +dnl A few 'make' implementations (e.g., NonStop OS and NextStep) +dnl do not support nested variable expansions. +dnl See automake bug#9928 and bug#10237. +am_make=${MAKE-make} +AC_CACHE_CHECK([whether $am_make supports nested variables], + [am_cv_make_support_nested_variables], + [if AS_ECHO([['TRUE=$(BAR$(V)) +BAR0=false +BAR1=true +V=1 +am__doit: + @$(TRUE) +.PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then + am_cv_make_support_nested_variables=yes +else + am_cv_make_support_nested_variables=no +fi]) +if test $am_cv_make_support_nested_variables = yes; then + dnl Using '$V' instead of '$(V)' breaks IRIX make. + AM_V='$(V)' + AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' +else + AM_V=$AM_DEFAULT_VERBOSITY + AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY +fi +AC_SUBST([AM_V])dnl +AM_SUBST_NOTMAKE([AM_V])dnl +AC_SUBST([AM_DEFAULT_V])dnl +AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl +AC_SUBST([AM_DEFAULT_VERBOSITY])dnl +AM_BACKSLASH='\' +AC_SUBST([AM_BACKSLASH])dnl +_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl +]) + +# Copyright (C) 2001-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_PROG_INSTALL_STRIP +# --------------------- +# One issue with vendor 'install' (even GNU) is that you can't +# specify the program used to strip binaries. This is especially +# annoying in cross-compiling environments, where the build's strip +# is unlikely to handle the host's binaries. +# Fortunately install-sh will honor a STRIPPROG variable, so we +# always use install-sh in "make install-strip", and initialize +# STRIPPROG with the value of the STRIP variable (set by the user). +AC_DEFUN([AM_PROG_INSTALL_STRIP], +[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl +# Installed binaries are usually stripped using 'strip' when the user +# run "make install-strip". However 'strip' might not be the right +# tool to use in cross-compilation environments, therefore Automake +# will honor the 'STRIP' environment variable to overrule this program. +dnl Don't test for $cross_compiling = yes, because it might be 'maybe'. +if test "$cross_compiling" != no; then + AC_CHECK_TOOL([STRIP], [strip], :) +fi +INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" +AC_SUBST([INSTALL_STRIP_PROGRAM])]) + +# Copyright (C) 2006-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# _AM_SUBST_NOTMAKE(VARIABLE) +# --------------------------- +# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. +# This macro is traced by Automake. +AC_DEFUN([_AM_SUBST_NOTMAKE]) + +# AM_SUBST_NOTMAKE(VARIABLE) +# -------------------------- +# Public sister of _AM_SUBST_NOTMAKE. +AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) + +# Check how to create a tarball. -*- Autoconf -*- + +# Copyright (C) 2004-2014 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# _AM_PROG_TAR(FORMAT) +# -------------------- +# Check how to create a tarball in format FORMAT. +# FORMAT should be one of 'v7', 'ustar', or 'pax'. +# +# Substitute a variable $(am__tar) that is a command +# writing to stdout a FORMAT-tarball containing the directory +# $tardir. +# tardir=directory && $(am__tar) > result.tar +# +# Substitute a variable $(am__untar) that extract such +# a tarball read from stdin. +# $(am__untar) < result.tar +# +AC_DEFUN([_AM_PROG_TAR], +[# Always define AMTAR for backward compatibility. Yes, it's still used +# in the wild :-( We should find a proper way to deprecate it ... +AC_SUBST([AMTAR], ['$${TAR-tar}']) + +# We'll loop over all known methods to create a tar archive until one works. +_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' + +m4_if([$1], [v7], + [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'], + + [m4_case([$1], + [ustar], + [# The POSIX 1988 'ustar' format is defined with fixed-size fields. + # There is notably a 21 bits limit for the UID and the GID. In fact, + # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343 + # and bug#13588). + am_max_uid=2097151 # 2^21 - 1 + am_max_gid=$am_max_uid + # The $UID and $GID variables are not portable, so we need to resort + # to the POSIX-mandated id(1) utility. Errors in the 'id' calls + # below are definitely unexpected, so allow the users to see them + # (that is, avoid stderr redirection). + am_uid=`id -u || echo unknown` + am_gid=`id -g || echo unknown` + AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format]) + if test $am_uid -le $am_max_uid; then + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + _am_tools=none + fi + AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format]) + if test $am_gid -le $am_max_gid; then + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + _am_tools=none + fi], + + [pax], + [], + + [m4_fatal([Unknown tar format])]) + + AC_MSG_CHECKING([how to create a $1 tar archive]) + + # Go ahead even if we have the value already cached. We do so because we + # need to set the values for the 'am__tar' and 'am__untar' variables. + _am_tools=${am_cv_prog_tar_$1-$_am_tools} + + for _am_tool in $_am_tools; do + case $_am_tool in + gnutar) + for _am_tar in tar gnutar gtar; do + AM_RUN_LOG([$_am_tar --version]) && break + done + am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' + am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' + am__untar="$_am_tar -xf -" + ;; + plaintar) + # Must skip GNU tar: if it does not support --format= it doesn't create + # ustar tarball either. + (tar --version) >/dev/null 2>&1 && continue + am__tar='tar chf - "$$tardir"' + am__tar_='tar chf - "$tardir"' + am__untar='tar xf -' + ;; + pax) + am__tar='pax -L -x $1 -w "$$tardir"' + am__tar_='pax -L -x $1 -w "$tardir"' + am__untar='pax -r' + ;; + cpio) + am__tar='find "$$tardir" -print | cpio -o -H $1 -L' + am__tar_='find "$tardir" -print | cpio -o -H $1 -L' + am__untar='cpio -i -H $1 -d' + ;; + none) + am__tar=false + am__tar_=false + am__untar=false + ;; + esac + + # If the value was cached, stop now. We just wanted to have am__tar + # and am__untar set. + test -n "${am_cv_prog_tar_$1}" && break + + # tar/untar a dummy directory, and stop if the command works. + rm -rf conftest.dir + mkdir conftest.dir + echo GrepMe > conftest.dir/file + AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) + rm -rf conftest.dir + if test -s conftest.tar; then + AM_RUN_LOG([$am__untar /dev/null 2>&1 && break + fi + done + rm -rf conftest.dir + + AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) + AC_MSG_RESULT([$am_cv_prog_tar_$1])]) + +AC_SUBST([am__tar]) +AC_SUBST([am__untar]) +]) # _AM_PROG_TAR + diff --git a/libs/ode-0.16.1/libccd/bootstrap b/libs/ode-0.16.1/libccd/bootstrap new file mode 100755 index 0000000..33795bf --- /dev/null +++ b/libs/ode-0.16.1/libccd/bootstrap @@ -0,0 +1,12 @@ +#!/bin/sh + +# on Mac libtoolize is called glibtoolize +LIBTOOLIZE=libtoolize +if [ `uname -s` = Darwin ]; then + LIBTOOLIZE=glibtoolize +fi +$LIBTOOLIZE -c --automake +aclocal +autoheader +autoconf +automake -a --foreign -c diff --git a/libs/ode-0.16.1/libccd/configure b/libs/ode-0.16.1/libccd/configure new file mode 100755 index 0000000..839345d --- /dev/null +++ b/libs/ode-0.16.1/libccd/configure @@ -0,0 +1,18785 @@ +#! /bin/sh +# Guess values for system-dependent variables and create Makefiles. +# Generated by GNU Autoconf 2.69 for libccd 1.0. +# +# Report bugs to . +# +# +# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. +# +# +# This configure script is free software; the Free Software Foundation +# gives unlimited permission to copy, distribute and modify it. +## -------------------- ## +## M4sh Initialization. ## +## -------------------- ## + +# Be more Bourne compatible +DUALCASE=1; export DUALCASE # for MKS sh +if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : + emulate sh + NULLCMD=: + # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which + # is contrary to our usage. Disable this feature. + alias -g '${1+"$@"}'='"$@"' + setopt NO_GLOB_SUBST +else + case `(set -o) 2>/dev/null` in #( + *posix*) : + set -o posix ;; #( + *) : + ;; +esac +fi + + +as_nl=' +' +export as_nl +# Printing a long string crashes Solaris 7 /usr/bin/printf. +as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo +# Prefer a ksh shell builtin over an external printf program on Solaris, +# but without wasting forks for bash or zsh. +if test -z "$BASH_VERSION$ZSH_VERSION" \ + && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='print -r --' + as_echo_n='print -rn --' +elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='printf %s\n' + as_echo_n='printf %s' +else + if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then + as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' + as_echo_n='/usr/ucb/echo -n' + else + as_echo_body='eval expr "X$1" : "X\\(.*\\)"' + as_echo_n_body='eval + arg=$1; + case $arg in #( + *"$as_nl"*) + expr "X$arg" : "X\\(.*\\)$as_nl"; + arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; + esac; + expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" + ' + export as_echo_n_body + as_echo_n='sh -c $as_echo_n_body as_echo' + fi + export as_echo_body + as_echo='sh -c $as_echo_body as_echo' +fi + +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + PATH_SEPARATOR=: + (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { + (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || + PATH_SEPARATOR=';' + } +fi + + +# IFS +# We need space, tab and new line, in precisely that order. Quoting is +# there to prevent editors from complaining about space-tab. +# (If _AS_PATH_WALK were called with IFS unset, it would disable word +# splitting by setting IFS to empty value.) +IFS=" "" $as_nl" + +# Find who we are. Look in the path if we contain no directory separator. +as_myself= +case $0 in #(( + *[\\/]* ) as_myself=$0 ;; + *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break + done +IFS=$as_save_IFS + + ;; +esac +# We did not find ourselves, most probably we were run as `sh COMMAND' +# in which case we are not to be found in the path. +if test "x$as_myself" = x; then + as_myself=$0 +fi +if test ! -f "$as_myself"; then + $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 + exit 1 +fi + +# Unset variables that we do not need and which cause bugs (e.g. in +# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" +# suppresses any "Segmentation fault" message there. '((' could +# trigger a bug in pdksh 5.2.14. +for as_var in BASH_ENV ENV MAIL MAILPATH +do eval test x\${$as_var+set} = xset \ + && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : +done +PS1='$ ' +PS2='> ' +PS4='+ ' + +# NLS nuisances. +LC_ALL=C +export LC_ALL +LANGUAGE=C +export LANGUAGE + +# CDPATH. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + +# Use a proper internal environment variable to ensure we don't fall + # into an infinite loop, continuously re-executing ourselves. + if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then + _as_can_reexec=no; export _as_can_reexec; + # We cannot yet assume a decent shell, so we have to provide a +# neutralization value for shells without unset; and this also +# works around shells that cannot unset nonexistent variables. +# Preserve -v and -x to the replacement shell. +BASH_ENV=/dev/null +ENV=/dev/null +(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV +case $- in # (((( + *v*x* | *x*v* ) as_opts=-vx ;; + *v* ) as_opts=-v ;; + *x* ) as_opts=-x ;; + * ) as_opts= ;; +esac +exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} +# Admittedly, this is quite paranoid, since all the known shells bail +# out after a failed `exec'. +$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 +as_fn_exit 255 + fi + # We don't want this to propagate to other subprocesses. + { _as_can_reexec=; unset _as_can_reexec;} +if test "x$CONFIG_SHELL" = x; then + as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : + emulate sh + NULLCMD=: + # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which + # is contrary to our usage. Disable this feature. + alias -g '\${1+\"\$@\"}'='\"\$@\"' + setopt NO_GLOB_SUBST +else + case \`(set -o) 2>/dev/null\` in #( + *posix*) : + set -o posix ;; #( + *) : + ;; +esac +fi +" + as_required="as_fn_return () { (exit \$1); } +as_fn_success () { as_fn_return 0; } +as_fn_failure () { as_fn_return 1; } +as_fn_ret_success () { return 0; } +as_fn_ret_failure () { return 1; } + +exitcode=0 +as_fn_success || { exitcode=1; echo as_fn_success failed.; } +as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } +as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } +as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } +if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : + +else + exitcode=1; echo positional parameters were not saved. +fi +test x\$exitcode = x0 || exit 1 +test -x / || exit 1" + as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO + as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO + eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && + test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 + + test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || ( + ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' + ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO + ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO + PATH=/empty FPATH=/empty; export PATH FPATH + test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\ + || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1 +test \$(( 1 + 1 )) = 2 || exit 1" + if (eval "$as_required") 2>/dev/null; then : + as_have_required=yes +else + as_have_required=no +fi + if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : + +else + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +as_found=false +for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + as_found=: + case $as_dir in #( + /*) + for as_base in sh bash ksh sh5; do + # Try only shells that exist, to save several forks. + as_shell=$as_dir/$as_base + if { test -f "$as_shell" || test -f "$as_shell.exe"; } && + { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : + CONFIG_SHELL=$as_shell as_have_required=yes + if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : + break 2 +fi +fi + done;; + esac + as_found=false +done +$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && + { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : + CONFIG_SHELL=$SHELL as_have_required=yes +fi; } +IFS=$as_save_IFS + + + if test "x$CONFIG_SHELL" != x; then : + export CONFIG_SHELL + # We cannot yet assume a decent shell, so we have to provide a +# neutralization value for shells without unset; and this also +# works around shells that cannot unset nonexistent variables. +# Preserve -v and -x to the replacement shell. +BASH_ENV=/dev/null +ENV=/dev/null +(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV +case $- in # (((( + *v*x* | *x*v* ) as_opts=-vx ;; + *v* ) as_opts=-v ;; + *x* ) as_opts=-x ;; + * ) as_opts= ;; +esac +exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} +# Admittedly, this is quite paranoid, since all the known shells bail +# out after a failed `exec'. +$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 +exit 255 +fi + + if test x$as_have_required = xno; then : + $as_echo "$0: This script requires a shell more modern than all" + $as_echo "$0: the shells that I found on your system." + if test x${ZSH_VERSION+set} = xset ; then + $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" + $as_echo "$0: be upgraded to zsh 4.3.4 or later." + else + $as_echo "$0: Please tell bug-autoconf@gnu.org and danfis@danfis.cz +$0: about your system, including any error possibly output +$0: before this message. Then install a modern shell, or +$0: manually run the script under such a shell if you do +$0: have one." + fi + exit 1 +fi +fi +fi +SHELL=${CONFIG_SHELL-/bin/sh} +export SHELL +# Unset more variables known to interfere with behavior of common tools. +CLICOLOR_FORCE= GREP_OPTIONS= +unset CLICOLOR_FORCE GREP_OPTIONS + +## --------------------- ## +## M4sh Shell Functions. ## +## --------------------- ## +# as_fn_unset VAR +# --------------- +# Portably unset VAR. +as_fn_unset () +{ + { eval $1=; unset $1;} +} +as_unset=as_fn_unset + +# as_fn_set_status STATUS +# ----------------------- +# Set $? to STATUS, without forking. +as_fn_set_status () +{ + return $1 +} # as_fn_set_status + +# as_fn_exit STATUS +# ----------------- +# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. +as_fn_exit () +{ + set +e + as_fn_set_status $1 + exit $1 +} # as_fn_exit + +# as_fn_mkdir_p +# ------------- +# Create "$as_dir" as a directory, including parents if necessary. +as_fn_mkdir_p () +{ + + case $as_dir in #( + -*) as_dir=./$as_dir;; + esac + test -d "$as_dir" || eval $as_mkdir_p || { + as_dirs= + while :; do + case $as_dir in #( + *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( + *) as_qdir=$as_dir;; + esac + as_dirs="'$as_qdir' $as_dirs" + as_dir=`$as_dirname -- "$as_dir" || +$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$as_dir" : 'X\(//\)[^/]' \| \ + X"$as_dir" : 'X\(//\)$' \| \ + X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$as_dir" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + test -d "$as_dir" && break + done + test -z "$as_dirs" || eval "mkdir $as_dirs" + } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" + + +} # as_fn_mkdir_p + +# as_fn_executable_p FILE +# ----------------------- +# Test if FILE is an executable regular file. +as_fn_executable_p () +{ + test -f "$1" && test -x "$1" +} # as_fn_executable_p +# as_fn_append VAR VALUE +# ---------------------- +# Append the text in VALUE to the end of the definition contained in VAR. Take +# advantage of any shell optimizations that allow amortized linear growth over +# repeated appends, instead of the typical quadratic growth present in naive +# implementations. +if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : + eval 'as_fn_append () + { + eval $1+=\$2 + }' +else + as_fn_append () + { + eval $1=\$$1\$2 + } +fi # as_fn_append + +# as_fn_arith ARG... +# ------------------ +# Perform arithmetic evaluation on the ARGs, and store the result in the +# global $as_val. Take advantage of shells that can avoid forks. The arguments +# must be portable across $(()) and expr. +if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : + eval 'as_fn_arith () + { + as_val=$(( $* )) + }' +else + as_fn_arith () + { + as_val=`expr "$@" || test $? -eq 1` + } +fi # as_fn_arith + + +# as_fn_error STATUS ERROR [LINENO LOG_FD] +# ---------------------------------------- +# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are +# provided, also output the error to LOG_FD, referencing LINENO. Then exit the +# script with STATUS, using 1 if that was 0. +as_fn_error () +{ + as_status=$1; test $as_status -eq 0 && as_status=1 + if test "$4"; then + as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 + fi + $as_echo "$as_me: error: $2" >&2 + as_fn_exit $as_status +} # as_fn_error + +if expr a : '\(a\)' >/dev/null 2>&1 && + test "X`expr 00001 : '.*\(...\)'`" = X001; then + as_expr=expr +else + as_expr=false +fi + +if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then + as_basename=basename +else + as_basename=false +fi + +if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then + as_dirname=dirname +else + as_dirname=false +fi + +as_me=`$as_basename -- "$0" || +$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ + X"$0" : 'X\(//\)$' \| \ + X"$0" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X/"$0" | + sed '/^.*\/\([^/][^/]*\)\/*$/{ + s//\1/ + q + } + /^X\/\(\/\/\)$/{ + s//\1/ + q + } + /^X\/\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + +# Avoid depending upon Character Ranges. +as_cr_letters='abcdefghijklmnopqrstuvwxyz' +as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' +as_cr_Letters=$as_cr_letters$as_cr_LETTERS +as_cr_digits='0123456789' +as_cr_alnum=$as_cr_Letters$as_cr_digits + + + as_lineno_1=$LINENO as_lineno_1a=$LINENO + as_lineno_2=$LINENO as_lineno_2a=$LINENO + eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && + test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { + # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) + sed -n ' + p + /[$]LINENO/= + ' <$as_myself | + sed ' + s/[$]LINENO.*/&-/ + t lineno + b + :lineno + N + :loop + s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ + t loop + s/-\n.*// + ' >$as_me.lineno && + chmod +x "$as_me.lineno" || + { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } + + # If we had to re-execute with $CONFIG_SHELL, we're ensured to have + # already done that, so ensure we don't try to do so again and fall + # in an infinite loop. This has already happened in practice. + _as_can_reexec=no; export _as_can_reexec + # Don't try to exec as it changes $[0], causing all sort of problems + # (the dirname of $[0] is not the place where we might find the + # original and so on. Autoconf is especially sensitive to this). + . "./$as_me.lineno" + # Exit status is that of the last command. + exit +} + +ECHO_C= ECHO_N= ECHO_T= +case `echo -n x` in #((((( +-n*) + case `echo 'xy\c'` in + *c*) ECHO_T=' ';; # ECHO_T is single tab character. + xy) ECHO_C='\c';; + *) echo `echo ksh88 bug on AIX 6.1` > /dev/null + ECHO_T=' ';; + esac;; +*) + ECHO_N='-n';; +esac + +rm -f conf$$ conf$$.exe conf$$.file +if test -d conf$$.dir; then + rm -f conf$$.dir/conf$$.file +else + rm -f conf$$.dir + mkdir conf$$.dir 2>/dev/null +fi +if (echo >conf$$.file) 2>/dev/null; then + if ln -s conf$$.file conf$$ 2>/dev/null; then + as_ln_s='ln -s' + # ... but there are two gotchas: + # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. + # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. + # In both cases, we have to default to `cp -pR'. + ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || + as_ln_s='cp -pR' + elif ln conf$$.file conf$$ 2>/dev/null; then + as_ln_s=ln + else + as_ln_s='cp -pR' + fi +else + as_ln_s='cp -pR' +fi +rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file +rmdir conf$$.dir 2>/dev/null + +if mkdir -p . 2>/dev/null; then + as_mkdir_p='mkdir -p "$as_dir"' +else + test -d ./-p && rmdir ./-p + as_mkdir_p=false +fi + +as_test_x='test -x' +as_executable_p=as_fn_executable_p + +# Sed expression to map a string onto a valid CPP name. +as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" + +# Sed expression to map a string onto a valid variable name. +as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" + +SHELL=${CONFIG_SHELL-/bin/sh} + + +test -n "$DJDIR" || exec 7<&0 &1 + +# Name of the host. +# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, +# so uname gets run too. +ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` + +# +# Initializations. +# +ac_default_prefix=/usr/local +ac_clean_files= +ac_config_libobj_dir=. +LIBOBJS= +cross_compiling=no +subdirs= +MFLAGS= +MAKEFLAGS= + +# Identity of this package. +PACKAGE_NAME='libccd' +PACKAGE_TARNAME='libccd' +PACKAGE_VERSION='1.0' +PACKAGE_STRING='libccd 1.0' +PACKAGE_BUGREPORT='danfis@danfis.cz' +PACKAGE_URL='' + +ac_unique_file="src/ccd.c" +# Factoring default headers for most tests. +ac_includes_default="\ +#include +#ifdef HAVE_SYS_TYPES_H +# include +#endif +#ifdef HAVE_SYS_STAT_H +# include +#endif +#ifdef STDC_HEADERS +# include +# include +#else +# ifdef HAVE_STDLIB_H +# include +# endif +#endif +#ifdef HAVE_STRING_H +# if !defined STDC_HEADERS && defined HAVE_MEMORY_H +# include +# endif +# include +#endif +#ifdef HAVE_STRINGS_H +# include +#endif +#ifdef HAVE_INTTYPES_H +# include +#endif +#ifdef HAVE_STDINT_H +# include +#endif +#ifdef HAVE_UNISTD_H +# include +#endif" + +ac_subst_vars='am__EXEEXT_FALSE +am__EXEEXT_TRUE +LTLIBOBJS +LIBOBJS +CCD_PRECISION +CXXCPP +CPP +LT_SYS_LIBRARY_PATH +OTOOL64 +OTOOL +LIPO +NMEDIT +DSYMUTIL +MANIFEST_TOOL +RANLIB +ac_ct_AR +AR +DLLTOOL +OBJDUMP +LN_S +NM +ac_ct_DUMPBIN +DUMPBIN +LD +FGREP +EGREP +GREP +SED +host_os +host_vendor +host_cpu +host +build_os +build_vendor +build_cpu +build +LIBTOOL +am__fastdepCC_FALSE +am__fastdepCC_TRUE +CCDEPMODE +ac_ct_CC +CFLAGS +CC +am__fastdepCXX_FALSE +am__fastdepCXX_TRUE +CXXDEPMODE +am__nodep +AMDEPBACKSLASH +AMDEP_FALSE +AMDEP_TRUE +am__quote +am__include +DEPDIR +OBJEXT +EXEEXT +ac_ct_CXX +CPPFLAGS +LDFLAGS +CXXFLAGS +CXX +AM_BACKSLASH +AM_DEFAULT_VERBOSITY +AM_DEFAULT_V +AM_V +am__untar +am__tar +AMTAR +am__leading_dot +SET_MAKE +AWK +mkdir_p +MKDIR_P +INSTALL_STRIP_PROGRAM +STRIP +install_sh +MAKEINFO +AUTOHEADER +AUTOMAKE +AUTOCONF +ACLOCAL +VERSION +PACKAGE +CYGPATH_W +am__isrc +INSTALL_DATA +INSTALL_SCRIPT +INSTALL_PROGRAM +target_alias +host_alias +build_alias +LIBS +ECHO_T +ECHO_N +ECHO_C +DEFS +mandir +localedir +libdir +psdir +pdfdir +dvidir +htmldir +infodir +docdir +oldincludedir +includedir +runstatedir +localstatedir +sharedstatedir +sysconfdir +datadir +datarootdir +libexecdir +sbindir +bindir +program_transform_name +prefix +exec_prefix +PACKAGE_URL +PACKAGE_BUGREPORT +PACKAGE_STRING +PACKAGE_VERSION +PACKAGE_TARNAME +PACKAGE_NAME +PATH_SEPARATOR +SHELL' +ac_subst_files='' +ac_user_opts=' +enable_option_checking +enable_silent_rules +enable_dependency_tracking +enable_shared +enable_static +with_pic +enable_fast_install +with_aix_soname +with_gnu_ld +with_sysroot +enable_libtool_lock +enable_double_precision +' + ac_precious_vars='build_alias +host_alias +target_alias +CXX +CXXFLAGS +LDFLAGS +LIBS +CPPFLAGS +CCC +CC +CFLAGS +LT_SYS_LIBRARY_PATH +CPP +CXXCPP' + + +# Initialize some variables set by options. +ac_init_help= +ac_init_version=false +ac_unrecognized_opts= +ac_unrecognized_sep= +# The variables have the same names as the options, with +# dashes changed to underlines. +cache_file=/dev/null +exec_prefix=NONE +no_create= +no_recursion= +prefix=NONE +program_prefix=NONE +program_suffix=NONE +program_transform_name=s,x,x, +silent= +site= +srcdir= +verbose= +x_includes=NONE +x_libraries=NONE + +# Installation directory options. +# These are left unexpanded so users can "make install exec_prefix=/foo" +# and all the variables that are supposed to be based on exec_prefix +# by default will actually change. +# Use braces instead of parens because sh, perl, etc. also accept them. +# (The list follows the same order as the GNU Coding Standards.) +bindir='${exec_prefix}/bin' +sbindir='${exec_prefix}/sbin' +libexecdir='${exec_prefix}/libexec' +datarootdir='${prefix}/share' +datadir='${datarootdir}' +sysconfdir='${prefix}/etc' +sharedstatedir='${prefix}/com' +localstatedir='${prefix}/var' +runstatedir='${localstatedir}/run' +includedir='${prefix}/include' +oldincludedir='/usr/include' +docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' +infodir='${datarootdir}/info' +htmldir='${docdir}' +dvidir='${docdir}' +pdfdir='${docdir}' +psdir='${docdir}' +libdir='${exec_prefix}/lib' +localedir='${datarootdir}/locale' +mandir='${datarootdir}/man' + +ac_prev= +ac_dashdash= +for ac_option +do + # If the previous option needs an argument, assign it. + if test -n "$ac_prev"; then + eval $ac_prev=\$ac_option + ac_prev= + continue + fi + + case $ac_option in + *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; + *=) ac_optarg= ;; + *) ac_optarg=yes ;; + esac + + # Accept the important Cygnus configure options, so we can diagnose typos. + + case $ac_dashdash$ac_option in + --) + ac_dashdash=yes ;; + + -bindir | --bindir | --bindi | --bind | --bin | --bi) + ac_prev=bindir ;; + -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) + bindir=$ac_optarg ;; + + -build | --build | --buil | --bui | --bu) + ac_prev=build_alias ;; + -build=* | --build=* | --buil=* | --bui=* | --bu=*) + build_alias=$ac_optarg ;; + + -cache-file | --cache-file | --cache-fil | --cache-fi \ + | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) + ac_prev=cache_file ;; + -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ + | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) + cache_file=$ac_optarg ;; + + --config-cache | -C) + cache_file=config.cache ;; + + -datadir | --datadir | --datadi | --datad) + ac_prev=datadir ;; + -datadir=* | --datadir=* | --datadi=* | --datad=*) + datadir=$ac_optarg ;; + + -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ + | --dataroo | --dataro | --datar) + ac_prev=datarootdir ;; + -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ + | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) + datarootdir=$ac_optarg ;; + + -disable-* | --disable-*) + ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` + # Reject names that are not valid shell variable names. + expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && + as_fn_error $? "invalid feature name: $ac_useropt" + ac_useropt_orig=$ac_useropt + ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + case $ac_user_opts in + *" +"enable_$ac_useropt" +"*) ;; + *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" + ac_unrecognized_sep=', ';; + esac + eval enable_$ac_useropt=no ;; + + -docdir | --docdir | --docdi | --doc | --do) + ac_prev=docdir ;; + -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) + docdir=$ac_optarg ;; + + -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) + ac_prev=dvidir ;; + -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) + dvidir=$ac_optarg ;; + + -enable-* | --enable-*) + ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` + # Reject names that are not valid shell variable names. + expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && + as_fn_error $? "invalid feature name: $ac_useropt" + ac_useropt_orig=$ac_useropt + ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + case $ac_user_opts in + *" +"enable_$ac_useropt" +"*) ;; + *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" + ac_unrecognized_sep=', ';; + esac + eval enable_$ac_useropt=\$ac_optarg ;; + + -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ + | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ + | --exec | --exe | --ex) + ac_prev=exec_prefix ;; + -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ + | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ + | --exec=* | --exe=* | --ex=*) + exec_prefix=$ac_optarg ;; + + -gas | --gas | --ga | --g) + # Obsolete; use --with-gas. + with_gas=yes ;; + + -help | --help | --hel | --he | -h) + ac_init_help=long ;; + -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) + ac_init_help=recursive ;; + -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) + ac_init_help=short ;; + + -host | --host | --hos | --ho) + ac_prev=host_alias ;; + -host=* | --host=* | --hos=* | --ho=*) + host_alias=$ac_optarg ;; + + -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) + ac_prev=htmldir ;; + -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ + | --ht=*) + htmldir=$ac_optarg ;; + + -includedir | --includedir | --includedi | --included | --include \ + | --includ | --inclu | --incl | --inc) + ac_prev=includedir ;; + -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ + | --includ=* | --inclu=* | --incl=* | --inc=*) + includedir=$ac_optarg ;; + + -infodir | --infodir | --infodi | --infod | --info | --inf) + ac_prev=infodir ;; + -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) + infodir=$ac_optarg ;; + + -libdir | --libdir | --libdi | --libd) + ac_prev=libdir ;; + -libdir=* | --libdir=* | --libdi=* | --libd=*) + libdir=$ac_optarg ;; + + -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ + | --libexe | --libex | --libe) + ac_prev=libexecdir ;; + -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ + | --libexe=* | --libex=* | --libe=*) + libexecdir=$ac_optarg ;; + + -localedir | --localedir | --localedi | --localed | --locale) + ac_prev=localedir ;; + -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) + localedir=$ac_optarg ;; + + -localstatedir | --localstatedir | --localstatedi | --localstated \ + | --localstate | --localstat | --localsta | --localst | --locals) + ac_prev=localstatedir ;; + -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ + | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) + localstatedir=$ac_optarg ;; + + -mandir | --mandir | --mandi | --mand | --man | --ma | --m) + ac_prev=mandir ;; + -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) + mandir=$ac_optarg ;; + + -nfp | --nfp | --nf) + # Obsolete; use --without-fp. + with_fp=no ;; + + -no-create | --no-create | --no-creat | --no-crea | --no-cre \ + | --no-cr | --no-c | -n) + no_create=yes ;; + + -no-recursion | --no-recursion | --no-recursio | --no-recursi \ + | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) + no_recursion=yes ;; + + -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ + | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ + | --oldin | --oldi | --old | --ol | --o) + ac_prev=oldincludedir ;; + -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ + | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ + | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) + oldincludedir=$ac_optarg ;; + + -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) + ac_prev=prefix ;; + -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) + prefix=$ac_optarg ;; + + -program-prefix | --program-prefix | --program-prefi | --program-pref \ + | --program-pre | --program-pr | --program-p) + ac_prev=program_prefix ;; + -program-prefix=* | --program-prefix=* | --program-prefi=* \ + | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) + program_prefix=$ac_optarg ;; + + -program-suffix | --program-suffix | --program-suffi | --program-suff \ + | --program-suf | --program-su | --program-s) + ac_prev=program_suffix ;; + -program-suffix=* | --program-suffix=* | --program-suffi=* \ + | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) + program_suffix=$ac_optarg ;; + + -program-transform-name | --program-transform-name \ + | --program-transform-nam | --program-transform-na \ + | --program-transform-n | --program-transform- \ + | --program-transform | --program-transfor \ + | --program-transfo | --program-transf \ + | --program-trans | --program-tran \ + | --progr-tra | --program-tr | --program-t) + ac_prev=program_transform_name ;; + -program-transform-name=* | --program-transform-name=* \ + | --program-transform-nam=* | --program-transform-na=* \ + | --program-transform-n=* | --program-transform-=* \ + | --program-transform=* | --program-transfor=* \ + | --program-transfo=* | --program-transf=* \ + | --program-trans=* | --program-tran=* \ + | --progr-tra=* | --program-tr=* | --program-t=*) + program_transform_name=$ac_optarg ;; + + -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) + ac_prev=pdfdir ;; + -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) + pdfdir=$ac_optarg ;; + + -psdir | --psdir | --psdi | --psd | --ps) + ac_prev=psdir ;; + -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) + psdir=$ac_optarg ;; + + -q | -quiet | --quiet | --quie | --qui | --qu | --q \ + | -silent | --silent | --silen | --sile | --sil) + silent=yes ;; + + -runstatedir | --runstatedir | --runstatedi | --runstated \ + | --runstate | --runstat | --runsta | --runst | --runs \ + | --run | --ru | --r) + ac_prev=runstatedir ;; + -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \ + | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \ + | --run=* | --ru=* | --r=*) + runstatedir=$ac_optarg ;; + + -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) + ac_prev=sbindir ;; + -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ + | --sbi=* | --sb=*) + sbindir=$ac_optarg ;; + + -sharedstatedir | --sharedstatedir | --sharedstatedi \ + | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ + | --sharedst | --shareds | --shared | --share | --shar \ + | --sha | --sh) + ac_prev=sharedstatedir ;; + -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ + | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ + | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ + | --sha=* | --sh=*) + sharedstatedir=$ac_optarg ;; + + -site | --site | --sit) + ac_prev=site ;; + -site=* | --site=* | --sit=*) + site=$ac_optarg ;; + + -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) + ac_prev=srcdir ;; + -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) + srcdir=$ac_optarg ;; + + -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ + | --syscon | --sysco | --sysc | --sys | --sy) + ac_prev=sysconfdir ;; + -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ + | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) + sysconfdir=$ac_optarg ;; + + -target | --target | --targe | --targ | --tar | --ta | --t) + ac_prev=target_alias ;; + -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) + target_alias=$ac_optarg ;; + + -v | -verbose | --verbose | --verbos | --verbo | --verb) + verbose=yes ;; + + -version | --version | --versio | --versi | --vers | -V) + ac_init_version=: ;; + + -with-* | --with-*) + ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` + # Reject names that are not valid shell variable names. + expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && + as_fn_error $? "invalid package name: $ac_useropt" + ac_useropt_orig=$ac_useropt + ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + case $ac_user_opts in + *" +"with_$ac_useropt" +"*) ;; + *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" + ac_unrecognized_sep=', ';; + esac + eval with_$ac_useropt=\$ac_optarg ;; + + -without-* | --without-*) + ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` + # Reject names that are not valid shell variable names. + expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && + as_fn_error $? "invalid package name: $ac_useropt" + ac_useropt_orig=$ac_useropt + ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + case $ac_user_opts in + *" +"with_$ac_useropt" +"*) ;; + *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" + ac_unrecognized_sep=', ';; + esac + eval with_$ac_useropt=no ;; + + --x) + # Obsolete; use --with-x. + with_x=yes ;; + + -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ + | --x-incl | --x-inc | --x-in | --x-i) + ac_prev=x_includes ;; + -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ + | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) + x_includes=$ac_optarg ;; + + -x-libraries | --x-libraries | --x-librarie | --x-librari \ + | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) + ac_prev=x_libraries ;; + -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ + | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) + x_libraries=$ac_optarg ;; + + -*) as_fn_error $? "unrecognized option: \`$ac_option' +Try \`$0 --help' for more information" + ;; + + *=*) + ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` + # Reject names that are not valid shell variable names. + case $ac_envvar in #( + '' | [0-9]* | *[!_$as_cr_alnum]* ) + as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; + esac + eval $ac_envvar=\$ac_optarg + export $ac_envvar ;; + + *) + # FIXME: should be removed in autoconf 3.0. + $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 + expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && + $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 + : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" + ;; + + esac +done + +if test -n "$ac_prev"; then + ac_option=--`echo $ac_prev | sed 's/_/-/g'` + as_fn_error $? "missing argument to $ac_option" +fi + +if test -n "$ac_unrecognized_opts"; then + case $enable_option_checking in + no) ;; + fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; + *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; + esac +fi + +# Check all directory arguments for consistency. +for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ + datadir sysconfdir sharedstatedir localstatedir includedir \ + oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ + libdir localedir mandir runstatedir +do + eval ac_val=\$$ac_var + # Remove trailing slashes. + case $ac_val in + */ ) + ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` + eval $ac_var=\$ac_val;; + esac + # Be sure to have absolute directory names. + case $ac_val in + [\\/$]* | ?:[\\/]* ) continue;; + NONE | '' ) case $ac_var in *prefix ) continue;; esac;; + esac + as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" +done + +# There might be people who depend on the old broken behavior: `$host' +# used to hold the argument of --host etc. +# FIXME: To remove some day. +build=$build_alias +host=$host_alias +target=$target_alias + +# FIXME: To remove some day. +if test "x$host_alias" != x; then + if test "x$build_alias" = x; then + cross_compiling=maybe + elif test "x$build_alias" != "x$host_alias"; then + cross_compiling=yes + fi +fi + +ac_tool_prefix= +test -n "$host_alias" && ac_tool_prefix=$host_alias- + +test "$silent" = yes && exec 6>/dev/null + + +ac_pwd=`pwd` && test -n "$ac_pwd" && +ac_ls_di=`ls -di .` && +ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || + as_fn_error $? "working directory cannot be determined" +test "X$ac_ls_di" = "X$ac_pwd_ls_di" || + as_fn_error $? "pwd does not report name of working directory" + + +# Find the source files, if location was not specified. +if test -z "$srcdir"; then + ac_srcdir_defaulted=yes + # Try the directory containing this script, then the parent directory. + ac_confdir=`$as_dirname -- "$as_myself" || +$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$as_myself" : 'X\(//\)[^/]' \| \ + X"$as_myself" : 'X\(//\)$' \| \ + X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$as_myself" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + srcdir=$ac_confdir + if test ! -r "$srcdir/$ac_unique_file"; then + srcdir=.. + fi +else + ac_srcdir_defaulted=no +fi +if test ! -r "$srcdir/$ac_unique_file"; then + test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." + as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" +fi +ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" +ac_abs_confdir=`( + cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" + pwd)` +# When building in place, set srcdir=. +if test "$ac_abs_confdir" = "$ac_pwd"; then + srcdir=. +fi +# Remove unnecessary trailing slashes from srcdir. +# Double slashes in file names in object file debugging info +# mess up M-x gdb in Emacs. +case $srcdir in +*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; +esac +for ac_var in $ac_precious_vars; do + eval ac_env_${ac_var}_set=\${${ac_var}+set} + eval ac_env_${ac_var}_value=\$${ac_var} + eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} + eval ac_cv_env_${ac_var}_value=\$${ac_var} +done + +# +# Report the --help message. +# +if test "$ac_init_help" = "long"; then + # Omit some internal or obsolete options to make the list less imposing. + # This message is too long to be a string in the A/UX 3.1 sh. + cat <<_ACEOF +\`configure' configures libccd 1.0 to adapt to many kinds of systems. + +Usage: $0 [OPTION]... [VAR=VALUE]... + +To assign environment variables (e.g., CC, CFLAGS...), specify them as +VAR=VALUE. See below for descriptions of some of the useful variables. + +Defaults for the options are specified in brackets. + +Configuration: + -h, --help display this help and exit + --help=short display options specific to this package + --help=recursive display the short help of all the included packages + -V, --version display version information and exit + -q, --quiet, --silent do not print \`checking ...' messages + --cache-file=FILE cache test results in FILE [disabled] + -C, --config-cache alias for \`--cache-file=config.cache' + -n, --no-create do not create output files + --srcdir=DIR find the sources in DIR [configure dir or \`..'] + +Installation directories: + --prefix=PREFIX install architecture-independent files in PREFIX + [$ac_default_prefix] + --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX + [PREFIX] + +By default, \`make install' will install all the files in +\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify +an installation prefix other than \`$ac_default_prefix' using \`--prefix', +for instance \`--prefix=\$HOME'. + +For better control, use the options below. + +Fine tuning of the installation directories: + --bindir=DIR user executables [EPREFIX/bin] + --sbindir=DIR system admin executables [EPREFIX/sbin] + --libexecdir=DIR program executables [EPREFIX/libexec] + --sysconfdir=DIR read-only single-machine data [PREFIX/etc] + --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] + --localstatedir=DIR modifiable single-machine data [PREFIX/var] + --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run] + --libdir=DIR object code libraries [EPREFIX/lib] + --includedir=DIR C header files [PREFIX/include] + --oldincludedir=DIR C header files for non-gcc [/usr/include] + --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] + --datadir=DIR read-only architecture-independent data [DATAROOTDIR] + --infodir=DIR info documentation [DATAROOTDIR/info] + --localedir=DIR locale-dependent data [DATAROOTDIR/locale] + --mandir=DIR man documentation [DATAROOTDIR/man] + --docdir=DIR documentation root [DATAROOTDIR/doc/libccd] + --htmldir=DIR html documentation [DOCDIR] + --dvidir=DIR dvi documentation [DOCDIR] + --pdfdir=DIR pdf documentation [DOCDIR] + --psdir=DIR ps documentation [DOCDIR] +_ACEOF + + cat <<\_ACEOF + +Program names: + --program-prefix=PREFIX prepend PREFIX to installed program names + --program-suffix=SUFFIX append SUFFIX to installed program names + --program-transform-name=PROGRAM run sed PROGRAM on installed program names + +System types: + --build=BUILD configure for building on BUILD [guessed] + --host=HOST cross-compile to build programs to run on HOST [BUILD] +_ACEOF +fi + +if test -n "$ac_init_help"; then + case $ac_init_help in + short | recursive ) echo "Configuration of libccd 1.0:";; + esac + cat <<\_ACEOF + +Optional Features: + --disable-option-checking ignore unrecognized --enable/--with options + --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) + --enable-FEATURE[=ARG] include FEATURE [ARG=yes] + --enable-silent-rules less verbose build output (undo: "make V=1") + --disable-silent-rules verbose build output (undo: "make V=0") + --enable-dependency-tracking + do not reject slow dependency extractors + --disable-dependency-tracking + speeds up one-time build + --enable-shared[=PKGS] build shared libraries [default=no] + --enable-static[=PKGS] build static libraries [default=yes] + --enable-fast-install[=PKGS] + optimize for fast installation [default=yes] + --disable-libtool-lock avoid locking (might break parallel builds) + --enable-double-precision + enable double precision computations instead of + single precision + +Optional Packages: + --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] + --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) + --with-pic[=PKGS] try to use only PIC/non-PIC objects [default=use + both] + --with-aix-soname=aix|svr4|both + shared library versioning (aka "SONAME") variant to + provide on AIX, [default=aix]. + --with-gnu-ld assume the C compiler uses GNU ld [default=no] + --with-sysroot[=DIR] Search for dependent libraries within DIR (or the + compiler's sysroot if not specified). + +Some influential environment variables: + CXX C++ compiler command + CXXFLAGS C++ compiler flags + LDFLAGS linker flags, e.g. -L if you have libraries in a + nonstandard directory + LIBS libraries to pass to the linker, e.g. -l + CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if + you have headers in a nonstandard directory + CC C compiler command + CFLAGS C compiler flags + LT_SYS_LIBRARY_PATH + User-defined run-time library search path. + CPP C preprocessor + CXXCPP C++ preprocessor + +Use these variables to override the choices made by `configure' or to help +it to find libraries and programs with nonstandard names/locations. + +Report bugs to . +_ACEOF +ac_status=$? +fi + +if test "$ac_init_help" = "recursive"; then + # If there are subdirs, report their specific --help. + for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue + test -d "$ac_dir" || + { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || + continue + ac_builddir=. + +case "$ac_dir" in +.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; +*) + ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` + # A ".." for each directory in $ac_dir_suffix. + ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` + case $ac_top_builddir_sub in + "") ac_top_builddir_sub=. ac_top_build_prefix= ;; + *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; + esac ;; +esac +ac_abs_top_builddir=$ac_pwd +ac_abs_builddir=$ac_pwd$ac_dir_suffix +# for backward compatibility: +ac_top_builddir=$ac_top_build_prefix + +case $srcdir in + .) # We are building in place. + ac_srcdir=. + ac_top_srcdir=$ac_top_builddir_sub + ac_abs_top_srcdir=$ac_pwd ;; + [\\/]* | ?:[\\/]* ) # Absolute name. + ac_srcdir=$srcdir$ac_dir_suffix; + ac_top_srcdir=$srcdir + ac_abs_top_srcdir=$srcdir ;; + *) # Relative name. + ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix + ac_top_srcdir=$ac_top_build_prefix$srcdir + ac_abs_top_srcdir=$ac_pwd/$srcdir ;; +esac +ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix + + cd "$ac_dir" || { ac_status=$?; continue; } + # Check for guested configure. + if test -f "$ac_srcdir/configure.gnu"; then + echo && + $SHELL "$ac_srcdir/configure.gnu" --help=recursive + elif test -f "$ac_srcdir/configure"; then + echo && + $SHELL "$ac_srcdir/configure" --help=recursive + else + $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 + fi || ac_status=$? + cd "$ac_pwd" || { ac_status=$?; break; } + done +fi + +test -n "$ac_init_help" && exit $ac_status +if $ac_init_version; then + cat <<\_ACEOF +libccd configure 1.0 +generated by GNU Autoconf 2.69 + +Copyright (C) 2012 Free Software Foundation, Inc. +This configure script is free software; the Free Software Foundation +gives unlimited permission to copy, distribute and modify it. +_ACEOF + exit +fi + +## ------------------------ ## +## Autoconf initialization. ## +## ------------------------ ## + +# ac_fn_cxx_try_compile LINENO +# ---------------------------- +# Try to compile conftest.$ac_ext, and return whether this succeeded. +ac_fn_cxx_try_compile () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + rm -f conftest.$ac_objext + if { { ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compile") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + test -z "$ac_cxx_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_cxx_try_compile + +# ac_fn_c_try_compile LINENO +# -------------------------- +# Try to compile conftest.$ac_ext, and return whether this succeeded. +ac_fn_c_try_compile () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + rm -f conftest.$ac_objext + if { { ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compile") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_try_compile + +# ac_fn_c_try_link LINENO +# ----------------------- +# Try to link conftest.$ac_ext, and return whether this succeeded. +ac_fn_c_try_link () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + rm -f conftest.$ac_objext conftest$ac_exeext + if { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest$ac_exeext && { + test "$cross_compiling" = yes || + test -x conftest$ac_exeext + }; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information + # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would + # interfere with the next link command; also delete a directory that is + # left behind by Apple's compiler. We do this before executing the actions. + rm -rf conftest.dSYM conftest_ipa8_conftest.oo + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_try_link + +# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES +# ------------------------------------------------------- +# Tests whether HEADER exists and can be compiled using the include files in +# INCLUDES, setting the cache variable VAR accordingly. +ac_fn_c_check_header_compile () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +#include <$2> +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + eval "$3=yes" +else + eval "$3=no" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_header_compile + +# ac_fn_c_try_cpp LINENO +# ---------------------- +# Try to preprocess conftest.$ac_ext, and return whether this succeeded. +ac_fn_c_try_cpp () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + if { { ac_try="$ac_cpp conftest.$ac_ext" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } > conftest.i && { + test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || + test ! -s conftest.err + }; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_try_cpp + +# ac_fn_c_try_run LINENO +# ---------------------- +# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes +# that executables *can* be run. +ac_fn_c_try_run () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + if { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' + { { case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_try") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; }; then : + ac_retval=0 +else + $as_echo "$as_me: program exited with status $ac_status" >&5 + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=$ac_status +fi + rm -rf conftest.dSYM conftest_ipa8_conftest.oo + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_try_run + +# ac_fn_c_check_func LINENO FUNC VAR +# ---------------------------------- +# Tests whether FUNC exists, setting the cache variable VAR accordingly +ac_fn_c_check_func () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Define $2 to an innocuous variant, in case declares $2. + For example, HP-UX 11i declares gettimeofday. */ +#define $2 innocuous_$2 + +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char $2 (); below. + Prefer to if __STDC__ is defined, since + exists even on freestanding compilers. */ + +#ifdef __STDC__ +# include +#else +# include +#endif + +#undef $2 + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char $2 (); +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined __stub_$2 || defined __stub___$2 +choke me +#endif + +int +main () +{ +return $2 (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + eval "$3=yes" +else + eval "$3=no" +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_func + +# ac_fn_cxx_try_cpp LINENO +# ------------------------ +# Try to preprocess conftest.$ac_ext, and return whether this succeeded. +ac_fn_cxx_try_cpp () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + if { { ac_try="$ac_cpp conftest.$ac_ext" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } > conftest.i && { + test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || + test ! -s conftest.err + }; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_cxx_try_cpp + +# ac_fn_cxx_try_link LINENO +# ------------------------- +# Try to link conftest.$ac_ext, and return whether this succeeded. +ac_fn_cxx_try_link () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + rm -f conftest.$ac_objext conftest$ac_exeext + if { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + test -z "$ac_cxx_werror_flag" || + test ! -s conftest.err + } && test -s conftest$ac_exeext && { + test "$cross_compiling" = yes || + test -x conftest$ac_exeext + }; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information + # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would + # interfere with the next link command; also delete a directory that is + # left behind by Apple's compiler. We do this before executing the actions. + rm -rf conftest.dSYM conftest_ipa8_conftest.oo + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_cxx_try_link + +# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES +# ------------------------------------------------------- +# Tests whether HEADER exists, giving a warning if it cannot be compiled using +# the include files in INCLUDES and setting the cache variable VAR +# accordingly. +ac_fn_c_check_header_mongrel () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + if eval \${$3+:} false; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } +else + # Is the header compilable? +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 +$as_echo_n "checking $2 usability... " >&6; } +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +#include <$2> +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_header_compiler=yes +else + ac_header_compiler=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 +$as_echo "$ac_header_compiler" >&6; } + +# Is the header present? +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 +$as_echo_n "checking $2 presence... " >&6; } +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <$2> +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + ac_header_preproc=yes +else + ac_header_preproc=no +fi +rm -f conftest.err conftest.i conftest.$ac_ext +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 +$as_echo "$ac_header_preproc" >&6; } + +# So? What about this header? +case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( + yes:no: ) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 +$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 +$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} + ;; + no:yes:* ) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 +$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 +$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 +$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 +$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 +$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} +( $as_echo "## ------------------------------- ## +## Report this to danfis@danfis.cz ## +## ------------------------------- ##" + ) | sed "s/^/$as_me: WARNING: /" >&2 + ;; +esac + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + eval "$3=\$ac_header_compiler" +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_header_mongrel + +# ac_fn_c_check_type LINENO TYPE VAR INCLUDES +# ------------------------------------------- +# Tests whether TYPE exists after having included INCLUDES, setting cache +# variable VAR accordingly. +ac_fn_c_check_type () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + eval "$3=no" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +if (sizeof ($2)) + return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +if (sizeof (($2))) + return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + +else + eval "$3=yes" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_type +cat >config.log <<_ACEOF +This file contains any messages produced by compilers while +running configure, to aid debugging if configure makes a mistake. + +It was created by libccd $as_me 1.0, which was +generated by GNU Autoconf 2.69. Invocation command line was + + $ $0 $@ + +_ACEOF +exec 5>>config.log +{ +cat <<_ASUNAME +## --------- ## +## Platform. ## +## --------- ## + +hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` +uname -m = `(uname -m) 2>/dev/null || echo unknown` +uname -r = `(uname -r) 2>/dev/null || echo unknown` +uname -s = `(uname -s) 2>/dev/null || echo unknown` +uname -v = `(uname -v) 2>/dev/null || echo unknown` + +/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` +/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` + +/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` +/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` +/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` +/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` +/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` +/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` +/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` + +_ASUNAME + +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + $as_echo "PATH: $as_dir" + done +IFS=$as_save_IFS + +} >&5 + +cat >&5 <<_ACEOF + + +## ----------- ## +## Core tests. ## +## ----------- ## + +_ACEOF + + +# Keep a trace of the command line. +# Strip out --no-create and --no-recursion so they do not pile up. +# Strip out --silent because we don't want to record it for future runs. +# Also quote any args containing shell meta-characters. +# Make two passes to allow for proper duplicate-argument suppression. +ac_configure_args= +ac_configure_args0= +ac_configure_args1= +ac_must_keep_next=false +for ac_pass in 1 2 +do + for ac_arg + do + case $ac_arg in + -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; + -q | -quiet | --quiet | --quie | --qui | --qu | --q \ + | -silent | --silent | --silen | --sile | --sil) + continue ;; + *\'*) + ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; + esac + case $ac_pass in + 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; + 2) + as_fn_append ac_configure_args1 " '$ac_arg'" + if test $ac_must_keep_next = true; then + ac_must_keep_next=false # Got value, back to normal. + else + case $ac_arg in + *=* | --config-cache | -C | -disable-* | --disable-* \ + | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ + | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ + | -with-* | --with-* | -without-* | --without-* | --x) + case "$ac_configure_args0 " in + "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; + esac + ;; + -* ) ac_must_keep_next=true ;; + esac + fi + as_fn_append ac_configure_args " '$ac_arg'" + ;; + esac + done +done +{ ac_configure_args0=; unset ac_configure_args0;} +{ ac_configure_args1=; unset ac_configure_args1;} + +# When interrupted or exit'd, cleanup temporary files, and complete +# config.log. We remove comments because anyway the quotes in there +# would cause problems or look ugly. +# WARNING: Use '\'' to represent an apostrophe within the trap. +# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. +trap 'exit_status=$? + # Save into config.log some information that might help in debugging. + { + echo + + $as_echo "## ---------------- ## +## Cache variables. ## +## ---------------- ##" + echo + # The following way of writing the cache mishandles newlines in values, +( + for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do + eval ac_val=\$$ac_var + case $ac_val in #( + *${as_nl}*) + case $ac_var in #( + *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 +$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; + esac + case $ac_var in #( + _ | IFS | as_nl) ;; #( + BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( + *) { eval $ac_var=; unset $ac_var;} ;; + esac ;; + esac + done + (set) 2>&1 | + case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( + *${as_nl}ac_space=\ *) + sed -n \ + "s/'\''/'\''\\\\'\'''\''/g; + s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" + ;; #( + *) + sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" + ;; + esac | + sort +) + echo + + $as_echo "## ----------------- ## +## Output variables. ## +## ----------------- ##" + echo + for ac_var in $ac_subst_vars + do + eval ac_val=\$$ac_var + case $ac_val in + *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; + esac + $as_echo "$ac_var='\''$ac_val'\''" + done | sort + echo + + if test -n "$ac_subst_files"; then + $as_echo "## ------------------- ## +## File substitutions. ## +## ------------------- ##" + echo + for ac_var in $ac_subst_files + do + eval ac_val=\$$ac_var + case $ac_val in + *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; + esac + $as_echo "$ac_var='\''$ac_val'\''" + done | sort + echo + fi + + if test -s confdefs.h; then + $as_echo "## ----------- ## +## confdefs.h. ## +## ----------- ##" + echo + cat confdefs.h + echo + fi + test "$ac_signal" != 0 && + $as_echo "$as_me: caught signal $ac_signal" + $as_echo "$as_me: exit $exit_status" + } >&5 + rm -f core *.core core.conftest.* && + rm -f -r conftest* confdefs* conf$$* $ac_clean_files && + exit $exit_status +' 0 +for ac_signal in 1 2 13 15; do + trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal +done +ac_signal=0 + +# confdefs.h avoids OS command line length limits that DEFS can exceed. +rm -f -r conftest* confdefs.h + +$as_echo "/* confdefs.h */" > confdefs.h + +# Predefined preprocessor variables. + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_NAME "$PACKAGE_NAME" +_ACEOF + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_TARNAME "$PACKAGE_TARNAME" +_ACEOF + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_VERSION "$PACKAGE_VERSION" +_ACEOF + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_STRING "$PACKAGE_STRING" +_ACEOF + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" +_ACEOF + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_URL "$PACKAGE_URL" +_ACEOF + + +# Let the site file select an alternate cache file if it wants to. +# Prefer an explicitly selected file to automatically selected ones. +ac_site_file1=NONE +ac_site_file2=NONE +if test -n "$CONFIG_SITE"; then + # We do not want a PATH search for config.site. + case $CONFIG_SITE in #(( + -*) ac_site_file1=./$CONFIG_SITE;; + */*) ac_site_file1=$CONFIG_SITE;; + *) ac_site_file1=./$CONFIG_SITE;; + esac +elif test "x$prefix" != xNONE; then + ac_site_file1=$prefix/share/config.site + ac_site_file2=$prefix/etc/config.site +else + ac_site_file1=$ac_default_prefix/share/config.site + ac_site_file2=$ac_default_prefix/etc/config.site +fi +for ac_site_file in "$ac_site_file1" "$ac_site_file2" +do + test "x$ac_site_file" = xNONE && continue + if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 +$as_echo "$as_me: loading site script $ac_site_file" >&6;} + sed 's/^/| /' "$ac_site_file" >&5 + . "$ac_site_file" \ + || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "failed to load site script $ac_site_file +See \`config.log' for more details" "$LINENO" 5; } + fi +done + +if test -r "$cache_file"; then + # Some versions of bash will fail to source /dev/null (special files + # actually), so we avoid doing that. DJGPP emulates it as a regular file. + if test /dev/null != "$cache_file" && test -f "$cache_file"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 +$as_echo "$as_me: loading cache $cache_file" >&6;} + case $cache_file in + [\\/]* | ?:[\\/]* ) . "$cache_file";; + *) . "./$cache_file";; + esac + fi +else + { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 +$as_echo "$as_me: creating cache $cache_file" >&6;} + >$cache_file +fi + +# Check that the precious variables saved in the cache have kept the same +# value. +ac_cache_corrupted=false +for ac_var in $ac_precious_vars; do + eval ac_old_set=\$ac_cv_env_${ac_var}_set + eval ac_new_set=\$ac_env_${ac_var}_set + eval ac_old_val=\$ac_cv_env_${ac_var}_value + eval ac_new_val=\$ac_env_${ac_var}_value + case $ac_old_set,$ac_new_set in + set,) + { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 +$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} + ac_cache_corrupted=: ;; + ,set) + { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 +$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} + ac_cache_corrupted=: ;; + ,);; + *) + if test "x$ac_old_val" != "x$ac_new_val"; then + # differences in whitespace do not lead to failure. + ac_old_val_w=`echo x $ac_old_val` + ac_new_val_w=`echo x $ac_new_val` + if test "$ac_old_val_w" != "$ac_new_val_w"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 +$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} + ac_cache_corrupted=: + else + { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 +$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} + eval $ac_var=\$ac_old_val + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 +$as_echo "$as_me: former value: \`$ac_old_val'" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 +$as_echo "$as_me: current value: \`$ac_new_val'" >&2;} + fi;; + esac + # Pass precious variables to config.status. + if test "$ac_new_set" = set; then + case $ac_new_val in + *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; + *) ac_arg=$ac_var=$ac_new_val ;; + esac + case " $ac_configure_args " in + *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. + *) as_fn_append ac_configure_args " '$ac_arg'" ;; + esac + fi +done +if $ac_cache_corrupted; then + { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 +$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} + as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 +fi +## -------------------- ## +## Main body of script. ## +## -------------------- ## + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + + +ac_config_headers="$ac_config_headers src/config.h" + +am__api_version='1.15' + +ac_aux_dir= +for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do + if test -f "$ac_dir/install-sh"; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/install-sh -c" + break + elif test -f "$ac_dir/install.sh"; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/install.sh -c" + break + elif test -f "$ac_dir/shtool"; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/shtool install -c" + break + fi +done +if test -z "$ac_aux_dir"; then + as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 +fi + +# These three variables are undocumented and unsupported, +# and are intended to be withdrawn in a future Autoconf release. +# They can cause serious problems if a builder's source tree is in a directory +# whose full name contains unusual characters. +ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. +ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. +ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. + + +# Find a good install program. We prefer a C program (faster), +# so one script is as good as another. But avoid the broken or +# incompatible versions: +# SysV /etc/install, /usr/sbin/install +# SunOS /usr/etc/install +# IRIX /sbin/install +# AIX /bin/install +# AmigaOS /C/install, which installs bootblocks on floppy discs +# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag +# AFS /usr/afsws/bin/install, which mishandles nonexistent args +# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" +# OS/2's system install, which has a completely different semantic +# ./install, which can be erroneously created by make from ./install.sh. +# Reject install programs that cannot install multiple files. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 +$as_echo_n "checking for a BSD-compatible install... " >&6; } +if test -z "$INSTALL"; then +if ${ac_cv_path_install+:} false; then : + $as_echo_n "(cached) " >&6 +else + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + # Account for people who put trailing slashes in PATH elements. +case $as_dir/ in #(( + ./ | .// | /[cC]/* | \ + /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ + ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ + /usr/ucb/* ) ;; + *) + # OSF1 and SCO ODT 3.0 have their own names for install. + # Don't use installbsd from OSF since it installs stuff as root + # by default. + for ac_prog in ginstall scoinst install; do + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then + if test $ac_prog = install && + grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then + # AIX install. It has an incompatible calling convention. + : + elif test $ac_prog = install && + grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then + # program-specific install script used by HP pwplus--don't use. + : + else + rm -rf conftest.one conftest.two conftest.dir + echo one > conftest.one + echo two > conftest.two + mkdir conftest.dir + if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && + test -s conftest.one && test -s conftest.two && + test -s conftest.dir/conftest.one && + test -s conftest.dir/conftest.two + then + ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" + break 3 + fi + fi + fi + done + done + ;; +esac + + done +IFS=$as_save_IFS + +rm -rf conftest.one conftest.two conftest.dir + +fi + if test "${ac_cv_path_install+set}" = set; then + INSTALL=$ac_cv_path_install + else + # As a last resort, use the slow shell script. Don't cache a + # value for INSTALL within a source directory, because that will + # break other packages using the cache if that directory is + # removed, or if the value is a relative name. + INSTALL=$ac_install_sh + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 +$as_echo "$INSTALL" >&6; } + +# Use test -z because SunOS4 sh mishandles braces in ${var-val}. +# It thinks the first close brace ends the variable substitution. +test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' + +test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' + +test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 +$as_echo_n "checking whether build environment is sane... " >&6; } +# Reject unsafe characters in $srcdir or the absolute working directory +# name. Accept space and tab only in the latter. +am_lf=' +' +case `pwd` in + *[\\\"\#\$\&\'\`$am_lf]*) + as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;; +esac +case $srcdir in + *[\\\"\#\$\&\'\`$am_lf\ \ ]*) + as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;; +esac + +# Do 'set' in a subshell so we don't clobber the current shell's +# arguments. Must try -L first in case configure is actually a +# symlink; some systems play weird games with the mod time of symlinks +# (eg FreeBSD returns the mod time of the symlink's containing +# directory). +if ( + am_has_slept=no + for am_try in 1 2; do + echo "timestamp, slept: $am_has_slept" > conftest.file + set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` + if test "$*" = "X"; then + # -L didn't work. + set X `ls -t "$srcdir/configure" conftest.file` + fi + if test "$*" != "X $srcdir/configure conftest.file" \ + && test "$*" != "X conftest.file $srcdir/configure"; then + + # If neither matched, then we have a broken ls. This can happen + # if, for instance, CONFIG_SHELL is bash and it inherits a + # broken ls alias from the environment. This has actually + # happened. Such a system could not be considered "sane". + as_fn_error $? "ls -t appears to fail. Make sure there is not a broken + alias in your environment" "$LINENO" 5 + fi + if test "$2" = conftest.file || test $am_try -eq 2; then + break + fi + # Just in case. + sleep 1 + am_has_slept=yes + done + test "$2" = conftest.file + ) +then + # Ok. + : +else + as_fn_error $? "newly created file is older than distributed files! +Check your system clock" "$LINENO" 5 +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +# If we didn't sleep, we still need to ensure time stamps of config.status and +# generated files are strictly newer. +am_sleep_pid= +if grep 'slept: no' conftest.file >/dev/null 2>&1; then + ( sleep 1 ) & + am_sleep_pid=$! +fi + +rm -f conftest.file + +test "$program_prefix" != NONE && + program_transform_name="s&^&$program_prefix&;$program_transform_name" +# Use a double $ so make ignores it. +test "$program_suffix" != NONE && + program_transform_name="s&\$&$program_suffix&;$program_transform_name" +# Double any \ or $. +# By default was `s,x,x', remove it if useless. +ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' +program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"` + +# Expand $ac_aux_dir to an absolute path. +am_aux_dir=`cd "$ac_aux_dir" && pwd` + +if test x"${MISSING+set}" != xset; then + case $am_aux_dir in + *\ * | *\ *) + MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; + *) + MISSING="\${SHELL} $am_aux_dir/missing" ;; + esac +fi +# Use eval to expand $SHELL +if eval "$MISSING --is-lightweight"; then + am_missing_run="$MISSING " +else + am_missing_run= + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5 +$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;} +fi + +if test x"${install_sh+set}" != xset; then + case $am_aux_dir in + *\ * | *\ *) + install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; + *) + install_sh="\${SHELL} $am_aux_dir/install-sh" + esac +fi + +# Installed binaries are usually stripped using 'strip' when the user +# run "make install-strip". However 'strip' might not be the right +# tool to use in cross-compilation environments, therefore Automake +# will honor the 'STRIP' environment variable to overrule this program. +if test "$cross_compiling" != no; then + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. +set dummy ${ac_tool_prefix}strip; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_STRIP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$STRIP"; then + ac_cv_prog_STRIP="$STRIP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_STRIP="${ac_tool_prefix}strip" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +STRIP=$ac_cv_prog_STRIP +if test -n "$STRIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 +$as_echo "$STRIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_STRIP"; then + ac_ct_STRIP=$STRIP + # Extract the first word of "strip", so it can be a program name with args. +set dummy strip; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_STRIP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_STRIP"; then + ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_STRIP="strip" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP +if test -n "$ac_ct_STRIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 +$as_echo "$ac_ct_STRIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_STRIP" = x; then + STRIP=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + STRIP=$ac_ct_STRIP + fi +else + STRIP="$ac_cv_prog_STRIP" +fi + +fi +INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5 +$as_echo_n "checking for a thread-safe mkdir -p... " >&6; } +if test -z "$MKDIR_P"; then + if ${ac_cv_path_mkdir+:} false; then : + $as_echo_n "(cached) " >&6 +else + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in mkdir gmkdir; do + for ac_exec_ext in '' $ac_executable_extensions; do + as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue + case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #( + 'mkdir (GNU coreutils) '* | \ + 'mkdir (coreutils) '* | \ + 'mkdir (fileutils) '4.1*) + ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext + break 3;; + esac + done + done + done +IFS=$as_save_IFS + +fi + + test -d ./--version && rmdir ./--version + if test "${ac_cv_path_mkdir+set}" = set; then + MKDIR_P="$ac_cv_path_mkdir -p" + else + # As a last resort, use the slow shell script. Don't cache a + # value for MKDIR_P within a source directory, because that will + # break other packages using the cache if that directory is + # removed, or if the value is a relative name. + MKDIR_P="$ac_install_sh -d" + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 +$as_echo "$MKDIR_P" >&6; } + +for ac_prog in gawk mawk nawk awk +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_AWK+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$AWK"; then + ac_cv_prog_AWK="$AWK" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_AWK="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +AWK=$ac_cv_prog_AWK +if test -n "$AWK"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 +$as_echo "$AWK" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$AWK" && break +done + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 +$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } +set x ${MAKE-make} +ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` +if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat >conftest.make <<\_ACEOF +SHELL = /bin/sh +all: + @echo '@@@%%%=$(MAKE)=@@@%%%' +_ACEOF +# GNU make sometimes prints "make[1]: Entering ...", which would confuse us. +case `${MAKE-make} -f conftest.make 2>/dev/null` in + *@@@%%%=?*=@@@%%%*) + eval ac_cv_prog_make_${ac_make}_set=yes;; + *) + eval ac_cv_prog_make_${ac_make}_set=no;; +esac +rm -f conftest.make +fi +if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + SET_MAKE= +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + SET_MAKE="MAKE=${MAKE-make}" +fi + +rm -rf .tst 2>/dev/null +mkdir .tst 2>/dev/null +if test -d .tst; then + am__leading_dot=. +else + am__leading_dot=_ +fi +rmdir .tst 2>/dev/null + +# Check whether --enable-silent-rules was given. +if test "${enable_silent_rules+set}" = set; then : + enableval=$enable_silent_rules; +fi + +case $enable_silent_rules in # ((( + yes) AM_DEFAULT_VERBOSITY=0;; + no) AM_DEFAULT_VERBOSITY=1;; + *) AM_DEFAULT_VERBOSITY=1;; +esac +am_make=${MAKE-make} +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 +$as_echo_n "checking whether $am_make supports nested variables... " >&6; } +if ${am_cv_make_support_nested_variables+:} false; then : + $as_echo_n "(cached) " >&6 +else + if $as_echo 'TRUE=$(BAR$(V)) +BAR0=false +BAR1=true +V=1 +am__doit: + @$(TRUE) +.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then + am_cv_make_support_nested_variables=yes +else + am_cv_make_support_nested_variables=no +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5 +$as_echo "$am_cv_make_support_nested_variables" >&6; } +if test $am_cv_make_support_nested_variables = yes; then + AM_V='$(V)' + AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' +else + AM_V=$AM_DEFAULT_VERBOSITY + AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY +fi +AM_BACKSLASH='\' + +if test "`cd $srcdir && pwd`" != "`pwd`"; then + # Use -I$(srcdir) only when $(srcdir) != ., so that make's output + # is not polluted with repeated "-I." + am__isrc=' -I$(srcdir)' + # test to see if srcdir already configured + if test -f $srcdir/config.status; then + as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 + fi +fi + +# test whether we have cygpath +if test -z "$CYGPATH_W"; then + if (cygpath --version) >/dev/null 2>/dev/null; then + CYGPATH_W='cygpath -w' + else + CYGPATH_W=echo + fi +fi + + +# Define the identity of the package. + PACKAGE='libccd' + VERSION='1.0' + + +cat >>confdefs.h <<_ACEOF +#define PACKAGE "$PACKAGE" +_ACEOF + + +cat >>confdefs.h <<_ACEOF +#define VERSION "$VERSION" +_ACEOF + +# Some tools Automake needs. + +ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} + + +AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} + + +AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} + + +AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} + + +MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} + +# For better backward compatibility. To be removed once Automake 1.9.x +# dies out for good. For more background, see: +# +# +mkdir_p='$(MKDIR_P)' + +# We need awk for the "check" target (and possibly the TAP driver). The +# system "awk" is bad on some platforms. +# Always define AMTAR for backward compatibility. Yes, it's still used +# in the wild :-( We should find a proper way to deprecate it ... +AMTAR='$${TAR-tar}' + + +# We'll loop over all known methods to create a tar archive until one works. +_am_tools='gnutar pax cpio none' + +am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -' + + + + + + +# POSIX will say in a future version that running "rm -f" with no argument +# is OK; and we want to be able to make that assumption in our Makefile +# recipes. So use an aggressive probe to check that the usage we want is +# actually supported "in the wild" to an acceptable degree. +# See automake bug#10828. +# To make any issue more visible, cause the running configure to be aborted +# by default if the 'rm' program in use doesn't match our expectations; the +# user can still override this though. +if rm -f && rm -fr && rm -rf; then : OK; else + cat >&2 <<'END' +Oops! + +Your 'rm' program seems unable to run without file operands specified +on the command line, even when the '-f' option is present. This is contrary +to the behaviour of most rm programs out there, and not conforming with +the upcoming POSIX standard: + +Please tell bug-automake@gnu.org about your system, including the value +of your $PATH and any error possibly output before this message. This +can help us improve future automake versions. + +END + if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then + echo 'Configuration will proceed anyway, since you have set the' >&2 + echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 + echo >&2 + else + cat >&2 <<'END' +Aborting the configuration process, to ensure you take notice of the issue. + +You can download and install GNU coreutils to get an 'rm' implementation +that behaves properly: . + +If you want to complete the configuration process using your problematic +'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM +to "yes", and re-run configure. + +END + as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5 + fi +fi + + +# Checks for programs. +ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu +if test -z "$CXX"; then + if test -n "$CCC"; then + CXX=$CCC + else + if test -n "$ac_tool_prefix"; then + for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CXX"; then + ac_cv_prog_CXX="$CXX" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +CXX=$ac_cv_prog_CXX +if test -n "$CXX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 +$as_echo "$CXX" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$CXX" && break + done +fi +if test -z "$CXX"; then + ac_ct_CXX=$CXX + for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_CXX"; then + ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_CXX="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_CXX=$ac_cv_prog_ac_ct_CXX +if test -n "$ac_ct_CXX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 +$as_echo "$ac_ct_CXX" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$ac_ct_CXX" && break +done + + if test "x$ac_ct_CXX" = x; then + CXX="g++" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + CXX=$ac_ct_CXX + fi +fi + + fi +fi +# Provide some information about the compiler. +$as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5 +set X $ac_compile +ac_compiler=$2 +for ac_option in --version -v -V -qversion; do + { { ac_try="$ac_compiler $ac_option >&5" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compiler $ac_option >&5") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + sed '10a\ +... rest of stderr output deleted ... + 10q' conftest.err >conftest.er1 + cat conftest.er1 >&5 + fi + rm -f conftest.er1 conftest.err + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } +done + +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +ac_clean_files_save=$ac_clean_files +ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" +# Try to create an executable without -o first, disregard a.out. +# It will help us diagnose broken compilers, and finding out an intuition +# of exeext. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C++ compiler works" >&5 +$as_echo_n "checking whether the C++ compiler works... " >&6; } +ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` + +# The possible output files: +ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" + +ac_rmfiles= +for ac_file in $ac_files +do + case $ac_file in + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; + * ) ac_rmfiles="$ac_rmfiles $ac_file";; + esac +done +rm -f $ac_rmfiles + +if { { ac_try="$ac_link_default" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link_default") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then : + # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. +# So ignore a value of `no', otherwise this would lead to `EXEEXT = no' +# in a Makefile. We should not override ac_cv_exeext if it was cached, +# so that the user can short-circuit this test for compilers unknown to +# Autoconf. +for ac_file in $ac_files '' +do + test -f "$ac_file" || continue + case $ac_file in + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) + ;; + [ab].out ) + # We found the default executable, but exeext='' is most + # certainly right. + break;; + *.* ) + if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; + then :; else + ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` + fi + # We set ac_cv_exeext here because the later test for it is not + # safe: cross compilers may not add the suffix if given an `-o' + # argument, so we may need to know it at that point already. + # Even if this section looks crufty: it has the advantage of + # actually working. + break;; + * ) + break;; + esac +done +test "$ac_cv_exeext" = no && ac_cv_exeext= + +else + ac_file='' +fi +if test -z "$ac_file"; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +$as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "C++ compiler cannot create executables +See \`config.log' for more details" "$LINENO" 5; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler default output file name" >&5 +$as_echo_n "checking for C++ compiler default output file name... " >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 +$as_echo "$ac_file" >&6; } +ac_exeext=$ac_cv_exeext + +rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out +ac_clean_files=$ac_clean_files_save +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 +$as_echo_n "checking for suffix of executables... " >&6; } +if { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then : + # If both `conftest.exe' and `conftest' are `present' (well, observable) +# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will +# work properly (i.e., refer to `conftest.exe'), while it won't with +# `rm'. +for ac_file in conftest.exe conftest conftest.*; do + test -f "$ac_file" || continue + case $ac_file in + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; + *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` + break;; + * ) break;; + esac +done +else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "cannot compute suffix of executables: cannot compile and link +See \`config.log' for more details" "$LINENO" 5; } +fi +rm -f conftest conftest$ac_cv_exeext +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 +$as_echo "$ac_cv_exeext" >&6; } + +rm -f conftest.$ac_ext +EXEEXT=$ac_cv_exeext +ac_exeext=$EXEEXT +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main () +{ +FILE *f = fopen ("conftest.out", "w"); + return ferror (f) || fclose (f) != 0; + + ; + return 0; +} +_ACEOF +ac_clean_files="$ac_clean_files conftest.out" +# Check that the compiler produces executables we can run. If not, either +# the compiler is broken, or we cross compile. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 +$as_echo_n "checking whether we are cross compiling... " >&6; } +if test "$cross_compiling" != yes; then + { { ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if { ac_try='./conftest$ac_cv_exeext' + { { case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_try") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; }; then + cross_compiling=no + else + if test "$cross_compiling" = maybe; then + cross_compiling=yes + else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "cannot run C++ compiled programs. +If you meant to cross compile, use \`--host'. +See \`config.log' for more details" "$LINENO" 5; } + fi + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 +$as_echo "$cross_compiling" >&6; } + +rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out +ac_clean_files=$ac_clean_files_save +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 +$as_echo_n "checking for suffix of object files... " >&6; } +if ${ac_cv_objext+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +rm -f conftest.o conftest.obj +if { { ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compile") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then : + for ac_file in conftest.o conftest.obj conftest.*; do + test -f "$ac_file" || continue; + case $ac_file in + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; + *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` + break;; + esac +done +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "cannot compute suffix of object files: cannot compile +See \`config.log' for more details" "$LINENO" 5; } +fi +rm -f conftest.$ac_cv_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 +$as_echo "$ac_cv_objext" >&6; } +OBJEXT=$ac_cv_objext +ac_objext=$OBJEXT +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5 +$as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } +if ${ac_cv_cxx_compiler_gnu+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ +#ifndef __GNUC__ + choke me +#endif + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + ac_compiler_gnu=yes +else + ac_compiler_gnu=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_cv_cxx_compiler_gnu=$ac_compiler_gnu + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 +$as_echo "$ac_cv_cxx_compiler_gnu" >&6; } +if test $ac_compiler_gnu = yes; then + GXX=yes +else + GXX= +fi +ac_test_CXXFLAGS=${CXXFLAGS+set} +ac_save_CXXFLAGS=$CXXFLAGS +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 +$as_echo_n "checking whether $CXX accepts -g... " >&6; } +if ${ac_cv_prog_cxx_g+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_save_cxx_werror_flag=$ac_cxx_werror_flag + ac_cxx_werror_flag=yes + ac_cv_prog_cxx_g=no + CXXFLAGS="-g" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + ac_cv_prog_cxx_g=yes +else + CXXFLAGS="" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + +else + ac_cxx_werror_flag=$ac_save_cxx_werror_flag + CXXFLAGS="-g" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + ac_cv_prog_cxx_g=yes +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_cxx_werror_flag=$ac_save_cxx_werror_flag +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 +$as_echo "$ac_cv_prog_cxx_g" >&6; } +if test "$ac_test_CXXFLAGS" = set; then + CXXFLAGS=$ac_save_CXXFLAGS +elif test $ac_cv_prog_cxx_g = yes; then + if test "$GXX" = yes; then + CXXFLAGS="-g -O2" + else + CXXFLAGS="-g" + fi +else + if test "$GXX" = yes; then + CXXFLAGS="-O2" + else + CXXFLAGS= + fi +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +DEPDIR="${am__leading_dot}deps" + +ac_config_commands="$ac_config_commands depfiles" + + +am_make=${MAKE-make} +cat > confinc << 'END' +am__doit: + @echo this is the am__doit target +.PHONY: am__doit +END +# If we don't find an include directive, just comment out the code. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5 +$as_echo_n "checking for style of include used by $am_make... " >&6; } +am__include="#" +am__quote= +_am_result=none +# First try GNU make style include. +echo "include confinc" > confmf +# Ignore all kinds of additional output from 'make'. +case `$am_make -s -f confmf 2> /dev/null` in #( +*the\ am__doit\ target*) + am__include=include + am__quote= + _am_result=GNU + ;; +esac +# Now try BSD make style include. +if test "$am__include" = "#"; then + echo '.include "confinc"' > confmf + case `$am_make -s -f confmf 2> /dev/null` in #( + *the\ am__doit\ target*) + am__include=.include + am__quote="\"" + _am_result=BSD + ;; + esac +fi + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5 +$as_echo "$_am_result" >&6; } +rm -f confinc confmf + +# Check whether --enable-dependency-tracking was given. +if test "${enable_dependency_tracking+set}" = set; then : + enableval=$enable_dependency_tracking; +fi + +if test "x$enable_dependency_tracking" != xno; then + am_depcomp="$ac_aux_dir/depcomp" + AMDEPBACKSLASH='\' + am__nodep='_no' +fi + if test "x$enable_dependency_tracking" != xno; then + AMDEP_TRUE= + AMDEP_FALSE='#' +else + AMDEP_TRUE='#' + AMDEP_FALSE= +fi + + + +depcc="$CXX" am_compiler_list= + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 +$as_echo_n "checking dependency style of $depcc... " >&6; } +if ${am_cv_CXX_dependencies_compiler_type+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then + # We make a subdir and do the tests there. Otherwise we can end up + # making bogus files that we don't know about and never remove. For + # instance it was reported that on HP-UX the gcc test will end up + # making a dummy file named 'D' -- because '-MD' means "put the output + # in D". + rm -rf conftest.dir + mkdir conftest.dir + # Copy depcomp to subdir because otherwise we won't find it if we're + # using a relative directory. + cp "$am_depcomp" conftest.dir + cd conftest.dir + # We will build objects and dependencies in a subdirectory because + # it helps to detect inapplicable dependency modes. For instance + # both Tru64's cc and ICC support -MD to output dependencies as a + # side effect of compilation, but ICC will put the dependencies in + # the current directory while Tru64 will put them in the object + # directory. + mkdir sub + + am_cv_CXX_dependencies_compiler_type=none + if test "$am_compiler_list" = ""; then + am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` + fi + am__universal=false + case " $depcc " in #( + *\ -arch\ *\ -arch\ *) am__universal=true ;; + esac + + for depmode in $am_compiler_list; do + # Setup a source with many dependencies, because some compilers + # like to wrap large dependency lists on column 80 (with \), and + # we should not choose a depcomp mode which is confused by this. + # + # We need to recreate these files for each test, as the compiler may + # overwrite some of them when testing with obscure command lines. + # This happens at least with the AIX C compiler. + : > sub/conftest.c + for i in 1 2 3 4 5 6; do + echo '#include "conftst'$i'.h"' >> sub/conftest.c + # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with + # Solaris 10 /bin/sh. + echo '/* dummy */' > sub/conftst$i.h + done + echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf + + # We check with '-c' and '-o' for the sake of the "dashmstdout" + # mode. It turns out that the SunPro C++ compiler does not properly + # handle '-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs. + am__obj=sub/conftest.${OBJEXT-o} + am__minus_obj="-o $am__obj" + case $depmode in + gcc) + # This depmode causes a compiler race in universal mode. + test "$am__universal" = false || continue + ;; + nosideeffect) + # After this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested. + if test "x$enable_dependency_tracking" = xyes; then + continue + else + break + fi + ;; + msvc7 | msvc7msys | msvisualcpp | msvcmsys) + # This compiler won't grok '-c -o', but also, the minuso test has + # not run yet. These depmodes are late enough in the game, and + # so weak that their functioning should not be impacted. + am__obj=conftest.${OBJEXT-o} + am__minus_obj= + ;; + none) break ;; + esac + if depmode=$depmode \ + source=sub/conftest.c object=$am__obj \ + depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ + $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ + >/dev/null 2>conftest.err && + grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && + grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && + grep $am__obj sub/conftest.Po > /dev/null 2>&1 && + ${MAKE-make} -s -f confmf > /dev/null 2>&1; then + # icc doesn't choke on unknown options, it will just issue warnings + # or remarks (even with -Werror). So we grep stderr for any message + # that says an option was ignored or not supported. + # When given -MP, icc 7.0 and 7.1 complain thusly: + # icc: Command line warning: ignoring option '-M'; no argument required + # The diagnosis changed in icc 8.0: + # icc: Command line remark: option '-MP' not supported + if (grep 'ignoring option' conftest.err || + grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else + am_cv_CXX_dependencies_compiler_type=$depmode + break + fi + fi + done + + cd .. + rm -rf conftest.dir +else + am_cv_CXX_dependencies_compiler_type=none +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CXX_dependencies_compiler_type" >&5 +$as_echo "$am_cv_CXX_dependencies_compiler_type" >&6; } +CXXDEPMODE=depmode=$am_cv_CXX_dependencies_compiler_type + + if + test "x$enable_dependency_tracking" != xno \ + && test "$am_cv_CXX_dependencies_compiler_type" = gcc3; then + am__fastdepCXX_TRUE= + am__fastdepCXX_FALSE='#' +else + am__fastdepCXX_TRUE='#' + am__fastdepCXX_FALSE= +fi + + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. +set dummy ${ac_tool_prefix}gcc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CC="${ac_tool_prefix}gcc" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_CC"; then + ac_ct_CC=$CC + # Extract the first word of "gcc", so it can be a program name with args. +set dummy gcc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_CC"; then + ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_CC="gcc" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_CC=$ac_cv_prog_ac_ct_CC +if test -n "$ac_ct_CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 +$as_echo "$ac_ct_CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_CC" = x; then + CC="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + CC=$ac_ct_CC + fi +else + CC="$ac_cv_prog_CC" +fi + +if test -z "$CC"; then + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. +set dummy ${ac_tool_prefix}cc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CC="${ac_tool_prefix}cc" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + fi +fi +if test -z "$CC"; then + # Extract the first word of "cc", so it can be a program name with args. +set dummy cc; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else + ac_prog_rejected=no +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then + ac_prog_rejected=yes + continue + fi + ac_cv_prog_CC="cc" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +if test $ac_prog_rejected = yes; then + # We found a bogon in the path, so make sure we never use it. + set dummy $ac_cv_prog_CC + shift + if test $# != 0; then + # We chose a different compiler from the bogus one. + # However, it has the same basename, so the bogon will be chosen + # first if we set CC to just the basename; use the full file name. + shift + ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" + fi +fi +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$CC"; then + if test -n "$ac_tool_prefix"; then + for ac_prog in cl.exe + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_CC="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$CC" && break + done +fi +if test -z "$CC"; then + ac_ct_CC=$CC + for ac_prog in cl.exe +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_CC+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_CC"; then + ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_CC="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_CC=$ac_cv_prog_ac_ct_CC +if test -n "$ac_ct_CC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 +$as_echo "$ac_ct_CC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$ac_ct_CC" && break +done + + if test "x$ac_ct_CC" = x; then + CC="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + CC=$ac_ct_CC + fi +fi + +fi + + +test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "no acceptable C compiler found in \$PATH +See \`config.log' for more details" "$LINENO" 5; } + +# Provide some information about the compiler. +$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 +set X $ac_compile +ac_compiler=$2 +for ac_option in --version -v -V -qversion; do + { { ac_try="$ac_compiler $ac_option >&5" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compiler $ac_option >&5") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + sed '10a\ +... rest of stderr output deleted ... + 10q' conftest.err >conftest.er1 + cat conftest.er1 >&5 + fi + rm -f conftest.er1 conftest.err + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } +done + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 +$as_echo_n "checking whether we are using the GNU C compiler... " >&6; } +if ${ac_cv_c_compiler_gnu+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ +#ifndef __GNUC__ + choke me +#endif + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_compiler_gnu=yes +else + ac_compiler_gnu=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_cv_c_compiler_gnu=$ac_compiler_gnu + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 +$as_echo "$ac_cv_c_compiler_gnu" >&6; } +if test $ac_compiler_gnu = yes; then + GCC=yes +else + GCC= +fi +ac_test_CFLAGS=${CFLAGS+set} +ac_save_CFLAGS=$CFLAGS +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 +$as_echo_n "checking whether $CC accepts -g... " >&6; } +if ${ac_cv_prog_cc_g+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_save_c_werror_flag=$ac_c_werror_flag + ac_c_werror_flag=yes + ac_cv_prog_cc_g=no + CFLAGS="-g" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_prog_cc_g=yes +else + CFLAGS="" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + +else + ac_c_werror_flag=$ac_save_c_werror_flag + CFLAGS="-g" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_prog_cc_g=yes +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_c_werror_flag=$ac_save_c_werror_flag +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 +$as_echo "$ac_cv_prog_cc_g" >&6; } +if test "$ac_test_CFLAGS" = set; then + CFLAGS=$ac_save_CFLAGS +elif test $ac_cv_prog_cc_g = yes; then + if test "$GCC" = yes; then + CFLAGS="-g -O2" + else + CFLAGS="-g" + fi +else + if test "$GCC" = yes; then + CFLAGS="-O2" + else + CFLAGS= + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 +$as_echo_n "checking for $CC option to accept ISO C89... " >&6; } +if ${ac_cv_prog_cc_c89+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_cv_prog_cc_c89=no +ac_save_CC=$CC +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +struct stat; +/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ +struct buf { int x; }; +FILE * (*rcsopen) (struct buf *, struct stat *, int); +static char *e (p, i) + char **p; + int i; +{ + return p[i]; +} +static char *f (char * (*g) (char **, int), char **p, ...) +{ + char *s; + va_list v; + va_start (v,p); + s = g (p, va_arg (v,int)); + va_end (v); + return s; +} + +/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has + function prototypes and stuff, but not '\xHH' hex character constants. + These don't provoke an error unfortunately, instead are silently treated + as 'x'. The following induces an error, until -std is added to get + proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an + array size at least. It's necessary to write '\x00'==0 to get something + that's true only with -std. */ +int osf4_cc_array ['\x00' == 0 ? 1 : -1]; + +/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters + inside strings and character constants. */ +#define FOO(x) 'x' +int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; + +int test (int i, double x); +struct s1 {int (*f) (int a);}; +struct s2 {int (*f) (double a);}; +int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); +int argc; +char **argv; +int +main () +{ +return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; + ; + return 0; +} +_ACEOF +for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ + -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" +do + CC="$ac_save_CC $ac_arg" + if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_prog_cc_c89=$ac_arg +fi +rm -f core conftest.err conftest.$ac_objext + test "x$ac_cv_prog_cc_c89" != "xno" && break +done +rm -f conftest.$ac_ext +CC=$ac_save_CC + +fi +# AC_CACHE_VAL +case "x$ac_cv_prog_cc_c89" in + x) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 +$as_echo "none needed" >&6; } ;; + xno) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 +$as_echo "unsupported" >&6; } ;; + *) + CC="$CC $ac_cv_prog_cc_c89" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 +$as_echo "$ac_cv_prog_cc_c89" >&6; } ;; +esac +if test "x$ac_cv_prog_cc_c89" != xno; then : + +fi + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5 +$as_echo_n "checking whether $CC understands -c and -o together... " >&6; } +if ${am_cv_prog_cc_c_o+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF + # Make sure it works both with $CC and with simple cc. + # Following AC_PROG_CC_C_O, we do the test twice because some + # compilers refuse to overwrite an existing .o file with -o, + # though they will create one. + am_cv_prog_cc_c_o=yes + for am_i in 1 2; do + if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5 + ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } \ + && test -f conftest2.$ac_objext; then + : OK + else + am_cv_prog_cc_c_o=no + break + fi + done + rm -f core conftest* + unset am_i +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5 +$as_echo "$am_cv_prog_cc_c_o" >&6; } +if test "$am_cv_prog_cc_c_o" != yes; then + # Losing compiler, so override with the script. + # FIXME: It is wrong to rewrite CC. + # But if we don't then we get into trouble of one sort or another. + # A longer-term fix would be to have automake use am__CC in this case, + # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" + CC="$am_aux_dir/compile $CC" +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + +depcc="$CC" am_compiler_list= + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 +$as_echo_n "checking dependency style of $depcc... " >&6; } +if ${am_cv_CC_dependencies_compiler_type+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then + # We make a subdir and do the tests there. Otherwise we can end up + # making bogus files that we don't know about and never remove. For + # instance it was reported that on HP-UX the gcc test will end up + # making a dummy file named 'D' -- because '-MD' means "put the output + # in D". + rm -rf conftest.dir + mkdir conftest.dir + # Copy depcomp to subdir because otherwise we won't find it if we're + # using a relative directory. + cp "$am_depcomp" conftest.dir + cd conftest.dir + # We will build objects and dependencies in a subdirectory because + # it helps to detect inapplicable dependency modes. For instance + # both Tru64's cc and ICC support -MD to output dependencies as a + # side effect of compilation, but ICC will put the dependencies in + # the current directory while Tru64 will put them in the object + # directory. + mkdir sub + + am_cv_CC_dependencies_compiler_type=none + if test "$am_compiler_list" = ""; then + am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` + fi + am__universal=false + case " $depcc " in #( + *\ -arch\ *\ -arch\ *) am__universal=true ;; + esac + + for depmode in $am_compiler_list; do + # Setup a source with many dependencies, because some compilers + # like to wrap large dependency lists on column 80 (with \), and + # we should not choose a depcomp mode which is confused by this. + # + # We need to recreate these files for each test, as the compiler may + # overwrite some of them when testing with obscure command lines. + # This happens at least with the AIX C compiler. + : > sub/conftest.c + for i in 1 2 3 4 5 6; do + echo '#include "conftst'$i'.h"' >> sub/conftest.c + # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with + # Solaris 10 /bin/sh. + echo '/* dummy */' > sub/conftst$i.h + done + echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf + + # We check with '-c' and '-o' for the sake of the "dashmstdout" + # mode. It turns out that the SunPro C++ compiler does not properly + # handle '-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs. + am__obj=sub/conftest.${OBJEXT-o} + am__minus_obj="-o $am__obj" + case $depmode in + gcc) + # This depmode causes a compiler race in universal mode. + test "$am__universal" = false || continue + ;; + nosideeffect) + # After this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested. + if test "x$enable_dependency_tracking" = xyes; then + continue + else + break + fi + ;; + msvc7 | msvc7msys | msvisualcpp | msvcmsys) + # This compiler won't grok '-c -o', but also, the minuso test has + # not run yet. These depmodes are late enough in the game, and + # so weak that their functioning should not be impacted. + am__obj=conftest.${OBJEXT-o} + am__minus_obj= + ;; + none) break ;; + esac + if depmode=$depmode \ + source=sub/conftest.c object=$am__obj \ + depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ + $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ + >/dev/null 2>conftest.err && + grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && + grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && + grep $am__obj sub/conftest.Po > /dev/null 2>&1 && + ${MAKE-make} -s -f confmf > /dev/null 2>&1; then + # icc doesn't choke on unknown options, it will just issue warnings + # or remarks (even with -Werror). So we grep stderr for any message + # that says an option was ignored or not supported. + # When given -MP, icc 7.0 and 7.1 complain thusly: + # icc: Command line warning: ignoring option '-M'; no argument required + # The diagnosis changed in icc 8.0: + # icc: Command line remark: option '-MP' not supported + if (grep 'ignoring option' conftest.err || + grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else + am_cv_CC_dependencies_compiler_type=$depmode + break + fi + fi + done + + cd .. + rm -rf conftest.dir +else + am_cv_CC_dependencies_compiler_type=none +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 +$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } +CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type + + if + test "x$enable_dependency_tracking" != xno \ + && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then + am__fastdepCC_TRUE= + am__fastdepCC_FALSE='#' +else + am__fastdepCC_TRUE='#' + am__fastdepCC_FALSE= +fi + + + +# Check whether --enable-shared was given. +if test "${enable_shared+set}" = set; then : + enableval=$enable_shared; p=${PACKAGE-default} + case $enableval in + yes) enable_shared=yes ;; + no) enable_shared=no ;; + *) + enable_shared=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, + for pkg in $enableval; do + IFS=$lt_save_ifs + if test "X$pkg" = "X$p"; then + enable_shared=yes + fi + done + IFS=$lt_save_ifs + ;; + esac +else + enable_shared=no +fi + + + + + + + + + +case `pwd` in + *\ * | *\ *) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5 +$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;; +esac + + + +macro_version='2.4.6' +macro_revision='2.4.6' + + + + + + + + + + + + + +ltmain=$ac_aux_dir/ltmain.sh + +# Make sure we can run config.sub. +$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || + as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 +$as_echo_n "checking build system type... " >&6; } +if ${ac_cv_build+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_build_alias=$build_alias +test "x$ac_build_alias" = x && + ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` +test "x$ac_build_alias" = x && + as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 +ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || + as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 +$as_echo "$ac_cv_build" >&6; } +case $ac_cv_build in +*-*-*) ;; +*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; +esac +build=$ac_cv_build +ac_save_IFS=$IFS; IFS='-' +set x $ac_cv_build +shift +build_cpu=$1 +build_vendor=$2 +shift; shift +# Remember, the first character of IFS is used to create $*, +# except with old shells: +build_os=$* +IFS=$ac_save_IFS +case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 +$as_echo_n "checking host system type... " >&6; } +if ${ac_cv_host+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "x$host_alias" = x; then + ac_cv_host=$ac_cv_build +else + ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || + as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 +$as_echo "$ac_cv_host" >&6; } +case $ac_cv_host in +*-*-*) ;; +*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; +esac +host=$ac_cv_host +ac_save_IFS=$IFS; IFS='-' +set x $ac_cv_host +shift +host_cpu=$1 +host_vendor=$2 +shift; shift +# Remember, the first character of IFS is used to create $*, +# except with old shells: +host_os=$* +IFS=$ac_save_IFS +case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac + + +# Backslashify metacharacters that are still active within +# double-quoted strings. +sed_quote_subst='s/\(["`$\\]\)/\\\1/g' + +# Same as above, but do not quote variable references. +double_quote_subst='s/\(["`\\]\)/\\\1/g' + +# Sed substitution to delay expansion of an escaped shell variable in a +# double_quote_subst'ed string. +delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' + +# Sed substitution to delay expansion of an escaped single quote. +delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' + +# Sed substitution to avoid accidental globbing in evaled expressions +no_glob_subst='s/\*/\\\*/g' + +ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5 +$as_echo_n "checking how to print strings... " >&6; } +# Test print first, because it will be a builtin if present. +if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ + test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='print -r --' +elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='printf %s\n' +else + # Use this function as a fallback that always works. + func_fallback_echo () + { + eval 'cat <<_LTECHO_EOF +$1 +_LTECHO_EOF' + } + ECHO='func_fallback_echo' +fi + +# func_echo_all arg... +# Invoke $ECHO with all args, space-separated. +func_echo_all () +{ + $ECHO "" +} + +case $ECHO in + printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5 +$as_echo "printf" >&6; } ;; + print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5 +$as_echo "print -r" >&6; } ;; + *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5 +$as_echo "cat" >&6; } ;; +esac + + + + + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 +$as_echo_n "checking for a sed that does not truncate output... " >&6; } +if ${ac_cv_path_SED+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ + for ac_i in 1 2 3 4 5 6 7; do + ac_script="$ac_script$as_nl$ac_script" + done + echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed + { ac_script=; unset ac_script;} + if test -z "$SED"; then + ac_path_SED_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in sed gsed; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_SED" || continue +# Check for GNU ac_path_SED and select it if it is found. + # Check for GNU $ac_path_SED +case `"$ac_path_SED" --version 2>&1` in +*GNU*) + ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo '' >> "conftest.nl" + "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_SED_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_SED="$ac_path_SED" + ac_path_SED_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_SED_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_SED"; then + as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 + fi +else + ac_cv_path_SED=$SED +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 +$as_echo "$ac_cv_path_SED" >&6; } + SED="$ac_cv_path_SED" + rm -f conftest.sed + +test -z "$SED" && SED=sed +Xsed="$SED -e 1s/^X//" + + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 +$as_echo_n "checking for grep that handles long lines and -e... " >&6; } +if ${ac_cv_path_GREP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$GREP"; then + ac_path_GREP_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in grep ggrep; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_GREP" || continue +# Check for GNU ac_path_GREP and select it if it is found. + # Check for GNU $ac_path_GREP +case `"$ac_path_GREP" --version 2>&1` in +*GNU*) + ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo 'GREP' >> "conftest.nl" + "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_GREP_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_GREP="$ac_path_GREP" + ac_path_GREP_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_GREP_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_GREP"; then + as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + fi +else + ac_cv_path_GREP=$GREP +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 +$as_echo "$ac_cv_path_GREP" >&6; } + GREP="$ac_cv_path_GREP" + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 +$as_echo_n "checking for egrep... " >&6; } +if ${ac_cv_path_EGREP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 + then ac_cv_path_EGREP="$GREP -E" + else + if test -z "$EGREP"; then + ac_path_EGREP_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in egrep; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_EGREP" || continue +# Check for GNU ac_path_EGREP and select it if it is found. + # Check for GNU $ac_path_EGREP +case `"$ac_path_EGREP" --version 2>&1` in +*GNU*) + ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo 'EGREP' >> "conftest.nl" + "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_EGREP_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_EGREP="$ac_path_EGREP" + ac_path_EGREP_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_EGREP_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_EGREP"; then + as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + fi +else + ac_cv_path_EGREP=$EGREP +fi + + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 +$as_echo "$ac_cv_path_EGREP" >&6; } + EGREP="$ac_cv_path_EGREP" + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 +$as_echo_n "checking for fgrep... " >&6; } +if ${ac_cv_path_FGREP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 + then ac_cv_path_FGREP="$GREP -F" + else + if test -z "$FGREP"; then + ac_path_FGREP_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in fgrep; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_FGREP" || continue +# Check for GNU ac_path_FGREP and select it if it is found. + # Check for GNU $ac_path_FGREP +case `"$ac_path_FGREP" --version 2>&1` in +*GNU*) + ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo 'FGREP' >> "conftest.nl" + "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_FGREP_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_FGREP="$ac_path_FGREP" + ac_path_FGREP_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_FGREP_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_FGREP"; then + as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + fi +else + ac_cv_path_FGREP=$FGREP +fi + + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 +$as_echo "$ac_cv_path_FGREP" >&6; } + FGREP="$ac_cv_path_FGREP" + + +test -z "$GREP" && GREP=grep + + + + + + + + + + + + + + + + + + + +# Check whether --with-gnu-ld was given. +if test "${with_gnu_ld+set}" = set; then : + withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes +else + with_gnu_ld=no +fi + +ac_prog=ld +if test yes = "$GCC"; then + # Check if gcc -print-prog-name=ld gives a path. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 +$as_echo_n "checking for ld used by $CC... " >&6; } + case $host in + *-*-mingw*) + # gcc leaves a trailing carriage return, which upsets mingw + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; + *) + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; + esac + case $ac_prog in + # Accept absolute paths. + [\\/]* | ?:[\\/]*) + re_direlt='/[^/][^/]*/\.\./' + # Canonicalize the pathname of ld + ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` + while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do + ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` + done + test -z "$LD" && LD=$ac_prog + ;; + "") + # If it fails, then pretend we aren't using GCC. + ac_prog=ld + ;; + *) + # If it is relative, then search for the first ld in PATH. + with_gnu_ld=unknown + ;; + esac +elif test yes = "$with_gnu_ld"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 +$as_echo_n "checking for GNU ld... " >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 +$as_echo_n "checking for non-GNU ld... " >&6; } +fi +if ${lt_cv_path_LD+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$LD"; then + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS=$lt_save_ifs + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then + lt_cv_path_LD=$ac_dir/$ac_prog + # Check to see if the program is GNU ld. I'd rather use --version, + # but apparently some variants of GNU ld only accept -v. + # Break only if it was the GNU/non-GNU ld that we prefer. + case `"$lt_cv_path_LD" -v 2>&1 &5 +$as_echo "$LD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi +test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 +$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } +if ${lt_cv_prog_gnu_ld+:} false; then : + $as_echo_n "(cached) " >&6 +else + # I'd rather use --version here, but apparently some GNU lds only accept -v. +case `$LD -v 2>&1 &5 +$as_echo "$lt_cv_prog_gnu_ld" >&6; } +with_gnu_ld=$lt_cv_prog_gnu_ld + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5 +$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; } +if ${lt_cv_path_NM+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$NM"; then + # Let the user override the test. + lt_cv_path_NM=$NM +else + lt_nm_to_check=${ac_tool_prefix}nm + if test -n "$ac_tool_prefix" && test "$build" = "$host"; then + lt_nm_to_check="$lt_nm_to_check nm" + fi + for lt_tmp_nm in $lt_nm_to_check; do + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR + for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do + IFS=$lt_save_ifs + test -z "$ac_dir" && ac_dir=. + tmp_nm=$ac_dir/$lt_tmp_nm + if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then + # Check to see if the nm accepts a BSD-compat flag. + # Adding the 'sed 1q' prevents false positives on HP-UX, which says: + # nm: unknown option "B" ignored + # Tru64's nm complains that /dev/null is an invalid object file + # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty + case $build_os in + mingw*) lt_bad_file=conftest.nm/nofile ;; + *) lt_bad_file=/dev/null ;; + esac + case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in + *$lt_bad_file* | *'Invalid file or object type'*) + lt_cv_path_NM="$tmp_nm -B" + break 2 + ;; + *) + case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in + */dev/null*) + lt_cv_path_NM="$tmp_nm -p" + break 2 + ;; + *) + lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but + continue # so that we can try to find one that supports BSD flags + ;; + esac + ;; + esac + fi + done + IFS=$lt_save_ifs + done + : ${lt_cv_path_NM=no} +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5 +$as_echo "$lt_cv_path_NM" >&6; } +if test no != "$lt_cv_path_NM"; then + NM=$lt_cv_path_NM +else + # Didn't find any BSD compatible name lister, look for dumpbin. + if test -n "$DUMPBIN"; then : + # Let the user override the test. + else + if test -n "$ac_tool_prefix"; then + for ac_prog in dumpbin "link -dump" + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DUMPBIN+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$DUMPBIN"; then + ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +DUMPBIN=$ac_cv_prog_DUMPBIN +if test -n "$DUMPBIN"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 +$as_echo "$DUMPBIN" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$DUMPBIN" && break + done +fi +if test -z "$DUMPBIN"; then + ac_ct_DUMPBIN=$DUMPBIN + for ac_prog in dumpbin "link -dump" +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_DUMPBIN"; then + ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_DUMPBIN="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN +if test -n "$ac_ct_DUMPBIN"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5 +$as_echo "$ac_ct_DUMPBIN" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$ac_ct_DUMPBIN" && break +done + + if test "x$ac_ct_DUMPBIN" = x; then + DUMPBIN=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + DUMPBIN=$ac_ct_DUMPBIN + fi +fi + + case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in + *COFF*) + DUMPBIN="$DUMPBIN -symbols -headers" + ;; + *) + DUMPBIN=: + ;; + esac + fi + + if test : != "$DUMPBIN"; then + NM=$DUMPBIN + fi +fi +test -z "$NM" && NM=nm + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5 +$as_echo_n "checking the name lister ($NM) interface... " >&6; } +if ${lt_cv_nm_interface+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_nm_interface="BSD nm" + echo "int some_variable = 0;" > conftest.$ac_ext + (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5) + (eval "$ac_compile" 2>conftest.err) + cat conftest.err >&5 + (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5) + (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) + cat conftest.err >&5 + (eval echo "\"\$as_me:$LINENO: output\"" >&5) + cat conftest.out >&5 + if $GREP 'External.*some_variable' conftest.out > /dev/null; then + lt_cv_nm_interface="MS dumpbin" + fi + rm -f conftest* +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5 +$as_echo "$lt_cv_nm_interface" >&6; } + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 +$as_echo_n "checking whether ln -s works... " >&6; } +LN_S=$as_ln_s +if test "$LN_S" = "ln -s"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 +$as_echo "no, using $LN_S" >&6; } +fi + +# find the maximum length of command line arguments +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 +$as_echo_n "checking the maximum length of command line arguments... " >&6; } +if ${lt_cv_sys_max_cmd_len+:} false; then : + $as_echo_n "(cached) " >&6 +else + i=0 + teststring=ABCD + + case $build_os in + msdosdjgpp*) + # On DJGPP, this test can blow up pretty badly due to problems in libc + # (any single argument exceeding 2000 bytes causes a buffer overrun + # during glob expansion). Even if it were fixed, the result of this + # check would be larger than it should be. + lt_cv_sys_max_cmd_len=12288; # 12K is about right + ;; + + gnu*) + # Under GNU Hurd, this test is not required because there is + # no limit to the length of command line arguments. + # Libtool will interpret -1 as no limit whatsoever + lt_cv_sys_max_cmd_len=-1; + ;; + + cygwin* | mingw* | cegcc*) + # On Win9x/ME, this test blows up -- it succeeds, but takes + # about 5 minutes as the teststring grows exponentially. + # Worse, since 9x/ME are not pre-emptively multitasking, + # you end up with a "frozen" computer, even though with patience + # the test eventually succeeds (with a max line length of 256k). + # Instead, let's just punt: use the minimum linelength reported by + # all of the supported platforms: 8192 (on NT/2K/XP). + lt_cv_sys_max_cmd_len=8192; + ;; + + mint*) + # On MiNT this can take a long time and run out of memory. + lt_cv_sys_max_cmd_len=8192; + ;; + + amigaos*) + # On AmigaOS with pdksh, this test takes hours, literally. + # So we just punt and use a minimum line length of 8192. + lt_cv_sys_max_cmd_len=8192; + ;; + + bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*) + # This has been around since 386BSD, at least. Likely further. + if test -x /sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` + elif test -x /usr/sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` + else + lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs + fi + # And add a safety zone + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + ;; + + interix*) + # We know the value 262144 and hardcode it with a safety zone (like BSD) + lt_cv_sys_max_cmd_len=196608 + ;; + + os2*) + # The test takes a long time on OS/2. + lt_cv_sys_max_cmd_len=8192 + ;; + + osf*) + # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure + # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not + # nice to cause kernel panics so lets avoid the loop below. + # First set a reasonable default. + lt_cv_sys_max_cmd_len=16384 + # + if test -x /sbin/sysconfig; then + case `/sbin/sysconfig -q proc exec_disable_arg_limit` in + *1*) lt_cv_sys_max_cmd_len=-1 ;; + esac + fi + ;; + sco3.2v5*) + lt_cv_sys_max_cmd_len=102400 + ;; + sysv5* | sco5v6* | sysv4.2uw2*) + kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` + if test -n "$kargmax"; then + lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'` + else + lt_cv_sys_max_cmd_len=32768 + fi + ;; + *) + lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` + if test -n "$lt_cv_sys_max_cmd_len" && \ + test undefined != "$lt_cv_sys_max_cmd_len"; then + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + else + # Make teststring a little bigger before we do anything with it. + # a 1K string should be a reasonable start. + for i in 1 2 3 4 5 6 7 8; do + teststring=$teststring$teststring + done + SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} + # If test is not a shell built-in, we'll probably end up computing a + # maximum length that is only half of the actual maximum length, but + # we can't tell. + while { test X`env echo "$teststring$teststring" 2>/dev/null` \ + = "X$teststring$teststring"; } >/dev/null 2>&1 && + test 17 != "$i" # 1/2 MB should be enough + do + i=`expr $i + 1` + teststring=$teststring$teststring + done + # Only check the string length outside the loop. + lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` + teststring= + # Add a significant safety factor because C++ compilers can tack on + # massive amounts of additional arguments before passing them to the + # linker. It appears as though 1/2 is a usable value. + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` + fi + ;; + esac + +fi + +if test -n "$lt_cv_sys_max_cmd_len"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 +$as_echo "$lt_cv_sys_max_cmd_len" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 +$as_echo "none" >&6; } +fi +max_cmd_len=$lt_cv_sys_max_cmd_len + + + + + + +: ${CP="cp -f"} +: ${MV="mv -f"} +: ${RM="rm -f"} + +if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then + lt_unset=unset +else + lt_unset=false +fi + + + + + +# test EBCDIC or ASCII +case `echo X|tr X '\101'` in + A) # ASCII based system + # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr + lt_SP2NL='tr \040 \012' + lt_NL2SP='tr \015\012 \040\040' + ;; + *) # EBCDIC based system + lt_SP2NL='tr \100 \n' + lt_NL2SP='tr \r\n \100\100' + ;; +esac + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5 +$as_echo_n "checking how to convert $build file names to $host format... " >&6; } +if ${lt_cv_to_host_file_cmd+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 + ;; + esac + ;; + *-*-cygwin* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin + ;; + esac + ;; + * ) # unhandled hosts (and "normal" native builds) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; +esac + +fi + +to_host_file_cmd=$lt_cv_to_host_file_cmd +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5 +$as_echo "$lt_cv_to_host_file_cmd" >&6; } + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5 +$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; } +if ${lt_cv_to_tool_file_cmd+:} false; then : + $as_echo_n "(cached) " >&6 +else + #assume ordinary cross tools, or native build. +lt_cv_to_tool_file_cmd=func_convert_file_noop +case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 + ;; + esac + ;; +esac + +fi + +to_tool_file_cmd=$lt_cv_to_tool_file_cmd +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5 +$as_echo "$lt_cv_to_tool_file_cmd" >&6; } + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 +$as_echo_n "checking for $LD option to reload object files... " >&6; } +if ${lt_cv_ld_reload_flag+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ld_reload_flag='-r' +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5 +$as_echo "$lt_cv_ld_reload_flag" >&6; } +reload_flag=$lt_cv_ld_reload_flag +case $reload_flag in +"" | " "*) ;; +*) reload_flag=" $reload_flag" ;; +esac +reload_cmds='$LD$reload_flag -o $output$reload_objs' +case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + if test yes != "$GCC"; then + reload_cmds=false + fi + ;; + darwin*) + if test yes = "$GCC"; then + reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs' + else + reload_cmds='$LD$reload_flag -o $output$reload_objs' + fi + ;; +esac + + + + + + + + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. +set dummy ${ac_tool_prefix}objdump; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_OBJDUMP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$OBJDUMP"; then + ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +OBJDUMP=$ac_cv_prog_OBJDUMP +if test -n "$OBJDUMP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 +$as_echo "$OBJDUMP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_OBJDUMP"; then + ac_ct_OBJDUMP=$OBJDUMP + # Extract the first word of "objdump", so it can be a program name with args. +set dummy objdump; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_OBJDUMP"; then + ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_OBJDUMP="objdump" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP +if test -n "$ac_ct_OBJDUMP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 +$as_echo "$ac_ct_OBJDUMP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_OBJDUMP" = x; then + OBJDUMP="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + OBJDUMP=$ac_ct_OBJDUMP + fi +else + OBJDUMP="$ac_cv_prog_OBJDUMP" +fi + +test -z "$OBJDUMP" && OBJDUMP=objdump + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5 +$as_echo_n "checking how to recognize dependent libraries... " >&6; } +if ${lt_cv_deplibs_check_method+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_file_magic_cmd='$MAGIC_CMD' +lt_cv_file_magic_test_file= +lt_cv_deplibs_check_method='unknown' +# Need to set the preceding variable on all platforms that support +# interlibrary dependencies. +# 'none' -- dependencies not supported. +# 'unknown' -- same as none, but documents that we really don't know. +# 'pass_all' -- all dependencies passed with no checks. +# 'test_compile' -- check by making test program. +# 'file_magic [[regex]]' -- check by looking for files in library path +# that responds to the $file_magic_cmd with a given extended regex. +# If you have 'file' or equivalent on your system and you're not sure +# whether 'pass_all' will *always* work, you probably want this one. + +case $host_os in +aix[4-9]*) + lt_cv_deplibs_check_method=pass_all + ;; + +beos*) + lt_cv_deplibs_check_method=pass_all + ;; + +bsdi[45]*) + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' + lt_cv_file_magic_cmd='/usr/bin/file -L' + lt_cv_file_magic_test_file=/shlib/libc.so + ;; + +cygwin*) + # func_win32_libid is a shell function defined in ltmain.sh + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + ;; + +mingw* | pw32*) + # Base MSYS/MinGW do not provide the 'file' command needed by + # func_win32_libid shell function, so use a weaker test based on 'objdump', + # unless we find 'file', for example because we are cross-compiling. + if ( file / ) >/dev/null 2>&1; then + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + else + # Keep this pattern in sync with the one in func_win32_libid. + lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' + lt_cv_file_magic_cmd='$OBJDUMP -f' + fi + ;; + +cegcc*) + # use the weaker test based on 'objdump'. See mingw*. + lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' + lt_cv_file_magic_cmd='$OBJDUMP -f' + ;; + +darwin* | rhapsody*) + lt_cv_deplibs_check_method=pass_all + ;; + +freebsd* | dragonfly*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then + case $host_cpu in + i*86 ) + # Not sure whether the presence of OpenBSD here was a mistake. + # Let's accept both of them until this is cleared up. + lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` + ;; + esac + else + lt_cv_deplibs_check_method=pass_all + fi + ;; + +haiku*) + lt_cv_deplibs_check_method=pass_all + ;; + +hpux10.20* | hpux11*) + lt_cv_file_magic_cmd=/usr/bin/file + case $host_cpu in + ia64*) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' + lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so + ;; + hppa*64*) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]' + lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl + ;; + *) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library' + lt_cv_file_magic_test_file=/usr/lib/libc.sl + ;; + esac + ;; + +interix[3-9]*) + # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$' + ;; + +irix5* | irix6* | nonstopux*) + case $LD in + *-32|*"-32 ") libmagic=32-bit;; + *-n32|*"-n32 ") libmagic=N32;; + *-64|*"-64 ") libmagic=64-bit;; + *) libmagic=never-match;; + esac + lt_cv_deplibs_check_method=pass_all + ;; + +# This must be glibc/ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + lt_cv_deplibs_check_method=pass_all + ;; + +netbsd* | netbsdelf*-gnu) + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' + fi + ;; + +newos6*) + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=/usr/lib/libnls.so + ;; + +*nto* | *qnx*) + lt_cv_deplibs_check_method=pass_all + ;; + +openbsd* | bitrig*) + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' + fi + ;; + +osf3* | osf4* | osf5*) + lt_cv_deplibs_check_method=pass_all + ;; + +rdos*) + lt_cv_deplibs_check_method=pass_all + ;; + +solaris*) + lt_cv_deplibs_check_method=pass_all + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + lt_cv_deplibs_check_method=pass_all + ;; + +sysv4 | sysv4.3*) + case $host_vendor in + motorola) + 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]' + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` + ;; + ncr) + lt_cv_deplibs_check_method=pass_all + ;; + sequent) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' + ;; + sni) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib" + lt_cv_file_magic_test_file=/lib/libc.so + ;; + siemens) + lt_cv_deplibs_check_method=pass_all + ;; + pc) + lt_cv_deplibs_check_method=pass_all + ;; + esac + ;; + +tpf*) + lt_cv_deplibs_check_method=pass_all + ;; +os2*) + lt_cv_deplibs_check_method=pass_all + ;; +esac + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 +$as_echo "$lt_cv_deplibs_check_method" >&6; } + +file_magic_glob= +want_nocaseglob=no +if test "$build" = "$host"; then + case $host_os in + mingw* | pw32*) + if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then + want_nocaseglob=yes + else + file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"` + fi + ;; + esac +fi + +file_magic_cmd=$lt_cv_file_magic_cmd +deplibs_check_method=$lt_cv_deplibs_check_method +test -z "$deplibs_check_method" && deplibs_check_method=unknown + + + + + + + + + + + + + + + + + + + + + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. +set dummy ${ac_tool_prefix}dlltool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DLLTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$DLLTOOL"; then + ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +DLLTOOL=$ac_cv_prog_DLLTOOL +if test -n "$DLLTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 +$as_echo "$DLLTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_DLLTOOL"; then + ac_ct_DLLTOOL=$DLLTOOL + # Extract the first word of "dlltool", so it can be a program name with args. +set dummy dlltool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_DLLTOOL"; then + ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_DLLTOOL="dlltool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL +if test -n "$ac_ct_DLLTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 +$as_echo "$ac_ct_DLLTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_DLLTOOL" = x; then + DLLTOOL="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + DLLTOOL=$ac_ct_DLLTOOL + fi +else + DLLTOOL="$ac_cv_prog_DLLTOOL" +fi + +test -z "$DLLTOOL" && DLLTOOL=dlltool + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5 +$as_echo_n "checking how to associate runtime and link libraries... " >&6; } +if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_sharedlib_from_linklib_cmd='unknown' + +case $host_os in +cygwin* | mingw* | pw32* | cegcc*) + # two different shell functions defined in ltmain.sh; + # decide which one to use based on capabilities of $DLLTOOL + case `$DLLTOOL --help 2>&1` in + *--identify-strict*) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib + ;; + *) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback + ;; + esac + ;; +*) + # fallback: assume linklib IS sharedlib + lt_cv_sharedlib_from_linklib_cmd=$ECHO + ;; +esac + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5 +$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; } +sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd +test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO + + + + + + + + +if test -n "$ac_tool_prefix"; then + for ac_prog in ar + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_AR+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$AR"; then + ac_cv_prog_AR="$AR" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_AR="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +AR=$ac_cv_prog_AR +if test -n "$AR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 +$as_echo "$AR" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$AR" && break + done +fi +if test -z "$AR"; then + ac_ct_AR=$AR + for ac_prog in ar +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_AR+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_AR"; then + ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_AR="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_AR=$ac_cv_prog_ac_ct_AR +if test -n "$ac_ct_AR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 +$as_echo "$ac_ct_AR" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$ac_ct_AR" && break +done + + if test "x$ac_ct_AR" = x; then + AR="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + AR=$ac_ct_AR + fi +fi + +: ${AR=ar} +: ${AR_FLAGS=cru} + + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5 +$as_echo_n "checking for archiver @FILE support... " >&6; } +if ${lt_cv_ar_at_file+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ar_at_file=no + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + echo conftest.$ac_objext > conftest.lst + lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 + (eval $lt_ar_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if test 0 -eq "$ac_status"; then + # Ensure the archiver fails upon bogus file names. + rm -f conftest.$ac_objext libconftest.a + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 + (eval $lt_ar_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if test 0 -ne "$ac_status"; then + lt_cv_ar_at_file=@ + fi + fi + rm -f conftest.* libconftest.a + +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5 +$as_echo "$lt_cv_ar_at_file" >&6; } + +if test no = "$lt_cv_ar_at_file"; then + archiver_list_spec= +else + archiver_list_spec=$lt_cv_ar_at_file +fi + + + + + + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. +set dummy ${ac_tool_prefix}strip; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_STRIP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$STRIP"; then + ac_cv_prog_STRIP="$STRIP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_STRIP="${ac_tool_prefix}strip" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +STRIP=$ac_cv_prog_STRIP +if test -n "$STRIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 +$as_echo "$STRIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_STRIP"; then + ac_ct_STRIP=$STRIP + # Extract the first word of "strip", so it can be a program name with args. +set dummy strip; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_STRIP+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_STRIP"; then + ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_STRIP="strip" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP +if test -n "$ac_ct_STRIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 +$as_echo "$ac_ct_STRIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_STRIP" = x; then + STRIP=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + STRIP=$ac_ct_STRIP + fi +else + STRIP="$ac_cv_prog_STRIP" +fi + +test -z "$STRIP" && STRIP=: + + + + + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. +set dummy ${ac_tool_prefix}ranlib; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_RANLIB+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$RANLIB"; then + ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +RANLIB=$ac_cv_prog_RANLIB +if test -n "$RANLIB"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 +$as_echo "$RANLIB" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_RANLIB"; then + ac_ct_RANLIB=$RANLIB + # Extract the first word of "ranlib", so it can be a program name with args. +set dummy ranlib; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_RANLIB"; then + ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_RANLIB="ranlib" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB +if test -n "$ac_ct_RANLIB"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 +$as_echo "$ac_ct_RANLIB" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_RANLIB" = x; then + RANLIB=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + RANLIB=$ac_ct_RANLIB + fi +else + RANLIB="$ac_cv_prog_RANLIB" +fi + +test -z "$RANLIB" && RANLIB=: + + + + + + +# Determine commands to create old-style static archives. +old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' +old_postinstall_cmds='chmod 644 $oldlib' +old_postuninstall_cmds= + +if test -n "$RANLIB"; then + case $host_os in + bitrig* | openbsd*) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" + ;; + *) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" + ;; + esac + old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" +fi + +case $host_os in + darwin*) + lock_old_archive_extraction=yes ;; + *) + lock_old_archive_extraction=no ;; +esac + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} + +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC + + +# Check for command to grab the raw symbol name followed by C symbol from nm. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5 +$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; } +if ${lt_cv_sys_global_symbol_pipe+:} false; then : + $as_echo_n "(cached) " >&6 +else + +# These are sane defaults that work on at least a few old systems. +# [They come from Ultrix. What could be older than Ultrix?!! ;)] + +# Character class describing NM global symbol codes. +symcode='[BCDEGRST]' + +# Regexp to match symbols that can be accessed directly from C. +sympat='\([_A-Za-z][_A-Za-z0-9]*\)' + +# Define system-specific variables. +case $host_os in +aix*) + symcode='[BCDT]' + ;; +cygwin* | mingw* | pw32* | cegcc*) + symcode='[ABCDGISTW]' + ;; +hpux*) + if test ia64 = "$host_cpu"; then + symcode='[ABCDEGRST]' + fi + ;; +irix* | nonstopux*) + symcode='[BCDEGRST]' + ;; +osf*) + symcode='[BCDEGQRST]' + ;; +solaris*) + symcode='[BDRT]' + ;; +sco3.2v5*) + symcode='[DT]' + ;; +sysv4.2uw2*) + symcode='[DT]' + ;; +sysv5* | sco5v6* | unixware* | OpenUNIX*) + symcode='[ABDT]' + ;; +sysv4) + symcode='[DFNSTU]' + ;; +esac + +# If we're using GNU nm, then use its standard symbol codes. +case `$NM -V 2>&1` in +*GNU* | *'with BFD'*) + symcode='[ABCDGIRSTW]' ;; +esac + +if test "$lt_cv_nm_interface" = "MS dumpbin"; then + # Gets list of data symbols to import. + lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'" + # Adjust the below global symbol transforms to fixup imported variables. + lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'" + lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'" + lt_c_name_lib_hook="\ + -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\ + -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'" +else + # Disable hooks by default. + lt_cv_sys_global_symbol_to_import= + lt_cdecl_hook= + lt_c_name_hook= + lt_c_name_lib_hook= +fi + +# Transform an extracted symbol line into a proper C declaration. +# Some systems (esp. on ia64) link data and code symbols differently, +# so use this general approach. +lt_cv_sys_global_symbol_to_cdecl="sed -n"\ +$lt_cdecl_hook\ +" -e 's/^T .* \(.*\)$/extern int \1();/p'"\ +" -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'" + +# Transform an extracted symbol line into symbol name and symbol address +lt_cv_sys_global_symbol_to_c_name_address="sed -n"\ +$lt_c_name_hook\ +" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ +" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'" + +# Transform an extracted symbol line into symbol name with lib prefix and +# symbol address. +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\ +$lt_c_name_lib_hook\ +" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ +" -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\ +" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'" + +# Handle CRLF in mingw tool chain +opt_cr= +case $build_os in +mingw*) + opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp + ;; +esac + +# Try without a prefix underscore, then with it. +for ac_symprfx in "" "_"; do + + # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. + symxfrm="\\1 $ac_symprfx\\2 \\2" + + # Write the raw and C identifiers. + if test "$lt_cv_nm_interface" = "MS dumpbin"; then + # Fake it for dumpbin and say T for any non-static function, + # D for any global variable and I for any imported variable. + # Also find C++ and __fastcall symbols from MSVC++, + # which start with @ or ?. + lt_cv_sys_global_symbol_pipe="$AWK '"\ +" {last_section=section; section=\$ 3};"\ +" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ +" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ +" /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\ +" /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\ +" /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\ +" \$ 0!~/External *\|/{next};"\ +" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ +" {if(hide[section]) next};"\ +" {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\ +" {split(\$ 0,a,/\||\r/); split(a[2],s)};"\ +" s[1]~/^[@?]/{print f,s[1],s[1]; next};"\ +" s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\ +" ' prfx=^$ac_symprfx" + else + lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" + fi + lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" + + # Check to see that the pipe works correctly. + pipe_works=no + + rm -f conftest* + cat > conftest.$ac_ext <<_LT_EOF +#ifdef __cplusplus +extern "C" { +#endif +char nm_test_var; +void nm_test_func(void); +void nm_test_func(void){} +#ifdef __cplusplus +} +#endif +int main(){nm_test_var='a';nm_test_func();return(0);} +_LT_EOF + + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + # Now try to grab the symbols. + nlist=conftest.nm + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5 + (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s "$nlist"; then + # Try sorting and uniquifying the output. + if sort "$nlist" | uniq > "$nlist"T; then + mv -f "$nlist"T "$nlist" + else + rm -f "$nlist"T + fi + + # Make sure that we snagged all the symbols we need. + if $GREP ' nm_test_var$' "$nlist" >/dev/null; then + if $GREP ' nm_test_func$' "$nlist" >/dev/null; then + cat <<_LT_EOF > conftest.$ac_ext +/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ +#if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE +/* DATA imports from DLLs on WIN32 can't be const, because runtime + relocations are performed -- see ld's documentation on pseudo-relocs. */ +# define LT_DLSYM_CONST +#elif defined __osf__ +/* This system does not cope well with relocations in const data. */ +# define LT_DLSYM_CONST +#else +# define LT_DLSYM_CONST const +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +_LT_EOF + # Now generate the symbol file. + eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' + + cat <<_LT_EOF >> conftest.$ac_ext + +/* The mapping between symbol names and symbols. */ +LT_DLSYM_CONST struct { + const char *name; + void *address; +} +lt__PROGRAM__LTX_preloaded_symbols[] = +{ + { "@PROGRAM@", (void *) 0 }, +_LT_EOF + $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext + cat <<\_LT_EOF >> conftest.$ac_ext + {0, (void *) 0} +}; + +/* This works around a problem in FreeBSD linker */ +#ifdef FREEBSD_WORKAROUND +static const void *lt_preloaded_setup() { + return lt__PROGRAM__LTX_preloaded_symbols; +} +#endif + +#ifdef __cplusplus +} +#endif +_LT_EOF + # Now try linking the two files. + mv conftest.$ac_objext conftstm.$ac_objext + lt_globsym_save_LIBS=$LIBS + lt_globsym_save_CFLAGS=$CFLAGS + LIBS=conftstm.$ac_objext + CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest$ac_exeext; then + pipe_works=yes + fi + LIBS=$lt_globsym_save_LIBS + CFLAGS=$lt_globsym_save_CFLAGS + else + echo "cannot find nm_test_func in $nlist" >&5 + fi + else + echo "cannot find nm_test_var in $nlist" >&5 + fi + else + echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 + fi + else + echo "$progname: failed program was:" >&5 + cat conftest.$ac_ext >&5 + fi + rm -rf conftest* conftst* + + # Do not use the global_symbol_pipe unless it works. + if test yes = "$pipe_works"; then + break + else + lt_cv_sys_global_symbol_pipe= + fi +done + +fi + +if test -z "$lt_cv_sys_global_symbol_pipe"; then + lt_cv_sys_global_symbol_to_cdecl= +fi +if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5 +$as_echo "failed" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 +$as_echo "ok" >&6; } +fi + +# Response file support. +if test "$lt_cv_nm_interface" = "MS dumpbin"; then + nm_file_list_spec='@' +elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then + nm_file_list_spec='@' +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 +$as_echo_n "checking for sysroot... " >&6; } + +# Check whether --with-sysroot was given. +if test "${with_sysroot+set}" = set; then : + withval=$with_sysroot; +else + with_sysroot=no +fi + + +lt_sysroot= +case $with_sysroot in #( + yes) + if test yes = "$GCC"; then + lt_sysroot=`$CC --print-sysroot 2>/dev/null` + fi + ;; #( + /*) + lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` + ;; #( + no|'') + ;; #( + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sysroot" >&5 +$as_echo "$with_sysroot" >&6; } + as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5 + ;; +esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5 +$as_echo "${lt_sysroot:-no}" >&6; } + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a working dd" >&5 +$as_echo_n "checking for a working dd... " >&6; } +if ${ac_cv_path_lt_DD+:} false; then : + $as_echo_n "(cached) " >&6 +else + printf 0123456789abcdef0123456789abcdef >conftest.i +cat conftest.i conftest.i >conftest2.i +: ${lt_DD:=$DD} +if test -z "$lt_DD"; then + ac_path_lt_DD_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in dd; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_lt_DD="$as_dir/$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_lt_DD" || continue +if "$ac_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then + cmp -s conftest.i conftest.out \ + && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=: +fi + $ac_path_lt_DD_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_lt_DD"; then + : + fi +else + ac_cv_path_lt_DD=$lt_DD +fi + +rm -f conftest.i conftest2.i conftest.out +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_lt_DD" >&5 +$as_echo "$ac_cv_path_lt_DD" >&6; } + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to truncate binary pipes" >&5 +$as_echo_n "checking how to truncate binary pipes... " >&6; } +if ${lt_cv_truncate_bin+:} false; then : + $as_echo_n "(cached) " >&6 +else + printf 0123456789abcdef0123456789abcdef >conftest.i +cat conftest.i conftest.i >conftest2.i +lt_cv_truncate_bin= +if "$ac_cv_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then + cmp -s conftest.i conftest.out \ + && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1" +fi +rm -f conftest.i conftest2.i conftest.out +test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q" +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_truncate_bin" >&5 +$as_echo "$lt_cv_truncate_bin" >&6; } + + + + + + + +# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. +func_cc_basename () +{ + for cc_temp in $*""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac + done + func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` +} + +# Check whether --enable-libtool-lock was given. +if test "${enable_libtool_lock+set}" = set; then : + enableval=$enable_libtool_lock; +fi + +test no = "$enable_libtool_lock" || enable_libtool_lock=yes + +# Some flags need to be propagated to the compiler or linker for good +# libtool support. +case $host in +ia64-*-hpux*) + # Find out what ABI is being produced by ac_compile, and set mode + # options accordingly. + echo 'int i;' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + case `/usr/bin/file conftest.$ac_objext` in + *ELF-32*) + HPUX_IA64_MODE=32 + ;; + *ELF-64*) + HPUX_IA64_MODE=64 + ;; + esac + fi + rm -rf conftest* + ;; +*-*-irix6*) + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. + echo '#line '$LINENO' "configure"' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + if test yes = "$lt_cv_prog_gnu_ld"; then + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -melf32bsmip" + ;; + *N32*) + LD="${LD-ld} -melf32bmipn32" + ;; + *64-bit*) + LD="${LD-ld} -melf64bmip" + ;; + esac + else + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -32" + ;; + *N32*) + LD="${LD-ld} -n32" + ;; + *64-bit*) + LD="${LD-ld} -64" + ;; + esac + fi + fi + rm -rf conftest* + ;; + +mips64*-*linux*) + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. + echo '#line '$LINENO' "configure"' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + emul=elf + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + emul="${emul}32" + ;; + *64-bit*) + emul="${emul}64" + ;; + esac + case `/usr/bin/file conftest.$ac_objext` in + *MSB*) + emul="${emul}btsmip" + ;; + *LSB*) + emul="${emul}ltsmip" + ;; + esac + case `/usr/bin/file conftest.$ac_objext` in + *N32*) + emul="${emul}n32" + ;; + esac + LD="${LD-ld} -m $emul" + fi + rm -rf conftest* + ;; + +x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ +s390*-*linux*|s390*-*tpf*|sparc*-*linux*) + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. Note that the listed cases only cover the + # situations where additional linker options are needed (such as when + # doing 32-bit compilation for a host where ld defaults to 64-bit, or + # vice versa); the common cases where no linker options are needed do + # not appear in the list. + echo 'int i;' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + case `/usr/bin/file conftest.o` in + *32-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_i386_fbsd" + ;; + x86_64-*linux*) + case `/usr/bin/file conftest.o` in + *x86-64*) + LD="${LD-ld} -m elf32_x86_64" + ;; + *) + LD="${LD-ld} -m elf_i386" + ;; + esac + ;; + powerpc64le-*linux*) + LD="${LD-ld} -m elf32lppclinux" + ;; + powerpc64-*linux*) + LD="${LD-ld} -m elf32ppclinux" + ;; + s390x-*linux*) + LD="${LD-ld} -m elf_s390" + ;; + sparc64-*linux*) + LD="${LD-ld} -m elf32_sparc" + ;; + esac + ;; + *64-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_x86_64_fbsd" + ;; + x86_64-*linux*) + LD="${LD-ld} -m elf_x86_64" + ;; + powerpcle-*linux*) + LD="${LD-ld} -m elf64lppc" + ;; + powerpc-*linux*) + LD="${LD-ld} -m elf64ppc" + ;; + s390*-*linux*|s390*-*tpf*) + LD="${LD-ld} -m elf64_s390" + ;; + sparc*-*linux*) + LD="${LD-ld} -m elf64_sparc" + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; + +*-*-sco3.2v5*) + # On SCO OpenServer 5, we need -belf to get full-featured binaries. + SAVE_CFLAGS=$CFLAGS + CFLAGS="$CFLAGS -belf" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5 +$as_echo_n "checking whether the C compiler needs -belf... " >&6; } +if ${lt_cv_cc_needs_belf+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + lt_cv_cc_needs_belf=yes +else + lt_cv_cc_needs_belf=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5 +$as_echo "$lt_cv_cc_needs_belf" >&6; } + if test yes != "$lt_cv_cc_needs_belf"; then + # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf + CFLAGS=$SAVE_CFLAGS + fi + ;; +*-*solaris*) + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. + echo 'int i;' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + case `/usr/bin/file conftest.o` in + *64-bit*) + case $lt_cv_prog_gnu_ld in + yes*) + case $host in + i?86-*-solaris*|x86_64-*-solaris*) + LD="${LD-ld} -m elf_x86_64" + ;; + sparc*-*-solaris*) + LD="${LD-ld} -m elf64_sparc" + ;; + esac + # GNU ld 2.21 introduced _sol2 emulations. Use them if available. + if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then + LD=${LD-ld}_sol2 + fi + ;; + *) + if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then + LD="${LD-ld} -64" + fi + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; +esac + +need_locks=$enable_libtool_lock + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args. +set dummy ${ac_tool_prefix}mt; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_MANIFEST_TOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$MANIFEST_TOOL"; then + ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL +if test -n "$MANIFEST_TOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5 +$as_echo "$MANIFEST_TOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_MANIFEST_TOOL"; then + ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL + # Extract the first word of "mt", so it can be a program name with args. +set dummy mt; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_MANIFEST_TOOL"; then + ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_MANIFEST_TOOL="mt" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL +if test -n "$ac_ct_MANIFEST_TOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5 +$as_echo "$ac_ct_MANIFEST_TOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_MANIFEST_TOOL" = x; then + MANIFEST_TOOL=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL + fi +else + MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL" +fi + +test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5 +$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; } +if ${lt_cv_path_mainfest_tool+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_path_mainfest_tool=no + echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5 + $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out + cat conftest.err >&5 + if $GREP 'Manifest Tool' conftest.out > /dev/null; then + lt_cv_path_mainfest_tool=yes + fi + rm -f conftest* +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5 +$as_echo "$lt_cv_path_mainfest_tool" >&6; } +if test yes != "$lt_cv_path_mainfest_tool"; then + MANIFEST_TOOL=: +fi + + + + + + + case $host_os in + rhapsody* | darwin*) + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args. +set dummy ${ac_tool_prefix}dsymutil; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DSYMUTIL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$DSYMUTIL"; then + ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +DSYMUTIL=$ac_cv_prog_DSYMUTIL +if test -n "$DSYMUTIL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 +$as_echo "$DSYMUTIL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_DSYMUTIL"; then + ac_ct_DSYMUTIL=$DSYMUTIL + # Extract the first word of "dsymutil", so it can be a program name with args. +set dummy dsymutil; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_DSYMUTIL"; then + ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_DSYMUTIL="dsymutil" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL +if test -n "$ac_ct_DSYMUTIL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5 +$as_echo "$ac_ct_DSYMUTIL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_DSYMUTIL" = x; then + DSYMUTIL=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + DSYMUTIL=$ac_ct_DSYMUTIL + fi +else + DSYMUTIL="$ac_cv_prog_DSYMUTIL" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args. +set dummy ${ac_tool_prefix}nmedit; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_NMEDIT+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$NMEDIT"; then + ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +NMEDIT=$ac_cv_prog_NMEDIT +if test -n "$NMEDIT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5 +$as_echo "$NMEDIT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_NMEDIT"; then + ac_ct_NMEDIT=$NMEDIT + # Extract the first word of "nmedit", so it can be a program name with args. +set dummy nmedit; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_NMEDIT"; then + ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_NMEDIT="nmedit" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT +if test -n "$ac_ct_NMEDIT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5 +$as_echo "$ac_ct_NMEDIT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_NMEDIT" = x; then + NMEDIT=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + NMEDIT=$ac_ct_NMEDIT + fi +else + NMEDIT="$ac_cv_prog_NMEDIT" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args. +set dummy ${ac_tool_prefix}lipo; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_LIPO+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$LIPO"; then + ac_cv_prog_LIPO="$LIPO" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_LIPO="${ac_tool_prefix}lipo" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +LIPO=$ac_cv_prog_LIPO +if test -n "$LIPO"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 +$as_echo "$LIPO" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_LIPO"; then + ac_ct_LIPO=$LIPO + # Extract the first word of "lipo", so it can be a program name with args. +set dummy lipo; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_LIPO+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_LIPO"; then + ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_LIPO="lipo" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO +if test -n "$ac_ct_LIPO"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5 +$as_echo "$ac_ct_LIPO" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_LIPO" = x; then + LIPO=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + LIPO=$ac_ct_LIPO + fi +else + LIPO="$ac_cv_prog_LIPO" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args. +set dummy ${ac_tool_prefix}otool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_OTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$OTOOL"; then + ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_OTOOL="${ac_tool_prefix}otool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +OTOOL=$ac_cv_prog_OTOOL +if test -n "$OTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 +$as_echo "$OTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_OTOOL"; then + ac_ct_OTOOL=$OTOOL + # Extract the first word of "otool", so it can be a program name with args. +set dummy otool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_OTOOL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_OTOOL"; then + ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_OTOOL="otool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL +if test -n "$ac_ct_OTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5 +$as_echo "$ac_ct_OTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_OTOOL" = x; then + OTOOL=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + OTOOL=$ac_ct_OTOOL + fi +else + OTOOL="$ac_cv_prog_OTOOL" +fi + + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args. +set dummy ${ac_tool_prefix}otool64; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_OTOOL64+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$OTOOL64"; then + ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +OTOOL64=$ac_cv_prog_OTOOL64 +if test -n "$OTOOL64"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5 +$as_echo "$OTOOL64" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_OTOOL64"; then + ac_ct_OTOOL64=$OTOOL64 + # Extract the first word of "otool64", so it can be a program name with args. +set dummy otool64; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_OTOOL64"; then + ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_OTOOL64="otool64" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi +fi +ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64 +if test -n "$ac_ct_OTOOL64"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5 +$as_echo "$ac_ct_OTOOL64" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + if test "x$ac_ct_OTOOL64" = x; then + OTOOL64=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + OTOOL64=$ac_ct_OTOOL64 + fi +else + OTOOL64="$ac_cv_prog_OTOOL64" +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5 +$as_echo_n "checking for -single_module linker flag... " >&6; } +if ${lt_cv_apple_cc_single_mod+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_apple_cc_single_mod=no + if test -z "$LT_MULTI_MODULE"; then + # By default we will add the -single_module flag. You can override + # by either setting the environment variable LT_MULTI_MODULE + # non-empty at configure time, or by adding -multi_module to the + # link flags. + rm -rf libconftest.dylib* + echo "int foo(void){return 1;}" > conftest.c + echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ +-dynamiclib -Wl,-single_module conftest.c" >&5 + $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ + -dynamiclib -Wl,-single_module conftest.c 2>conftest.err + _lt_result=$? + # If there is a non-empty error log, and "single_module" + # appears in it, assume the flag caused a linker warning + if test -s conftest.err && $GREP single_module conftest.err; then + cat conftest.err >&5 + # Otherwise, if the output was created with a 0 exit code from + # the compiler, it worked. + elif test -f libconftest.dylib && test 0 = "$_lt_result"; then + lt_cv_apple_cc_single_mod=yes + else + cat conftest.err >&5 + fi + rm -rf libconftest.dylib* + rm -f conftest.* + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5 +$as_echo "$lt_cv_apple_cc_single_mod" >&6; } + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5 +$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; } +if ${lt_cv_ld_exported_symbols_list+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ld_exported_symbols_list=no + save_LDFLAGS=$LDFLAGS + echo "_main" > conftest.sym + LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + lt_cv_ld_exported_symbols_list=yes +else + lt_cv_ld_exported_symbols_list=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS=$save_LDFLAGS + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5 +$as_echo "$lt_cv_ld_exported_symbols_list" >&6; } + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5 +$as_echo_n "checking for -force_load linker flag... " >&6; } +if ${lt_cv_ld_force_load+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ld_force_load=no + cat > conftest.c << _LT_EOF +int forced_loaded() { return 2;} +_LT_EOF + echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5 + $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5 + echo "$AR cru libconftest.a conftest.o" >&5 + $AR cru libconftest.a conftest.o 2>&5 + echo "$RANLIB libconftest.a" >&5 + $RANLIB libconftest.a 2>&5 + cat > conftest.c << _LT_EOF +int main() { return 0;} +_LT_EOF + echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5 + $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err + _lt_result=$? + if test -s conftest.err && $GREP force_load conftest.err; then + cat conftest.err >&5 + elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then + lt_cv_ld_force_load=yes + else + cat conftest.err >&5 + fi + rm -f conftest.err libconftest.a conftest conftest.c + rm -rf conftest.dSYM + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5 +$as_echo "$lt_cv_ld_force_load" >&6; } + case $host_os in + rhapsody* | darwin1.[012]) + _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; + darwin1.*) + _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; + darwin*) # darwin 5.x on + # if running on 10.5 or later, the deployment target defaults + # to the OS version, if on x86, and 10.4, the deployment + # target defaults to 10.4. Don't you love it? + case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in + 10.0,*86*-darwin8*|10.0,*-darwin[91]*) + _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; + 10.[012][,.]*) + _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; + 10.*) + _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; + esac + ;; + esac + if test yes = "$lt_cv_apple_cc_single_mod"; then + _lt_dar_single_mod='$single_module' + fi + if test yes = "$lt_cv_ld_exported_symbols_list"; then + _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym' + else + _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib' + fi + if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then + _lt_dsymutil='~$DSYMUTIL $lib || :' + else + _lt_dsymutil= + fi + ;; + esac + +# func_munge_path_list VARIABLE PATH +# ----------------------------------- +# VARIABLE is name of variable containing _space_ separated list of +# directories to be munged by the contents of PATH, which is string +# having a format: +# "DIR[:DIR]:" +# string "DIR[ DIR]" will be prepended to VARIABLE +# ":DIR[:DIR]" +# string "DIR[ DIR]" will be appended to VARIABLE +# "DIRP[:DIRP]::[DIRA:]DIRA" +# string "DIRP[ DIRP]" will be prepended to VARIABLE and string +# "DIRA[ DIRA]" will be appended to VARIABLE +# "DIR[:DIR]" +# VARIABLE will be replaced by "DIR[ DIR]" +func_munge_path_list () +{ + case x$2 in + x) + ;; + *:) + eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\" + ;; + x:*) + eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\" + ;; + *::*) + eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" + eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\" + ;; + *) + eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\" + ;; + esac +} + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 +$as_echo_n "checking how to run the C preprocessor... " >&6; } +# On Suns, sometimes $CPP names a directory. +if test -n "$CPP" && test -d "$CPP"; then + CPP= +fi +if test -z "$CPP"; then + if ${ac_cv_prog_CPP+:} false; then : + $as_echo_n "(cached) " >&6 +else + # Double quotes because CPP needs to be expanded + for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" + do + ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + break +fi + + done + ac_cv_prog_CPP=$CPP + +fi + CPP=$ac_cv_prog_CPP +else + ac_cv_prog_CPP=$CPP +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 +$as_echo "$CPP" >&6; } +ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + +else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "C preprocessor \"$CPP\" fails sanity check +See \`config.log' for more details" "$LINENO" 5; } +fi + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 +$as_echo_n "checking for ANSI C header files... " >&6; } +if ${ac_cv_header_stdc+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#include +#include + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_header_stdc=yes +else + ac_cv_header_stdc=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +if test $ac_cv_header_stdc = yes; then + # SunOS 4.x string.h does not declare mem*, contrary to ANSI. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "memchr" >/dev/null 2>&1; then : + +else + ac_cv_header_stdc=no +fi +rm -f conftest* + +fi + +if test $ac_cv_header_stdc = yes; then + # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "free" >/dev/null 2>&1; then : + +else + ac_cv_header_stdc=no +fi +rm -f conftest* + +fi + +if test $ac_cv_header_stdc = yes; then + # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. + if test "$cross_compiling" = yes; then : + : +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include +#if ((' ' & 0x0FF) == 0x020) +# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') +# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) +#else +# define ISLOWER(c) \ + (('a' <= (c) && (c) <= 'i') \ + || ('j' <= (c) && (c) <= 'r') \ + || ('s' <= (c) && (c) <= 'z')) +# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) +#endif + +#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) +int +main () +{ + int i; + for (i = 0; i < 256; i++) + if (XOR (islower (i), ISLOWER (i)) + || toupper (i) != TOUPPER (i)) + return 2; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + +else + ac_cv_header_stdc=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 +$as_echo "$ac_cv_header_stdc" >&6; } +if test $ac_cv_header_stdc = yes; then + +$as_echo "#define STDC_HEADERS 1" >>confdefs.h + +fi + +# On IRIX 5.3, sys/types and inttypes.h are conflicting. +for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ + inttypes.h stdint.h unistd.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default +" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + +for ac_header in dlfcn.h +do : + ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default +" +if test "x$ac_cv_header_dlfcn_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_DLFCN_H 1 +_ACEOF + +fi + +done + + + + +func_stripname_cnf () +{ + case $2 in + .*) func_stripname_result=`$ECHO "$3" | $SED "s%^$1%%; s%\\\\$2\$%%"`;; + *) func_stripname_result=`$ECHO "$3" | $SED "s%^$1%%; s%$2\$%%"`;; + esac +} # func_stripname_cnf + + + + + +# Set options + + + + enable_dlopen=no + + + enable_win32_dll=no + + + + # Check whether --enable-static was given. +if test "${enable_static+set}" = set; then : + enableval=$enable_static; p=${PACKAGE-default} + case $enableval in + yes) enable_static=yes ;; + no) enable_static=no ;; + *) + enable_static=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, + for pkg in $enableval; do + IFS=$lt_save_ifs + if test "X$pkg" = "X$p"; then + enable_static=yes + fi + done + IFS=$lt_save_ifs + ;; + esac +else + enable_static=yes +fi + + + + + + + + + + +# Check whether --with-pic was given. +if test "${with_pic+set}" = set; then : + withval=$with_pic; lt_p=${PACKAGE-default} + case $withval in + yes|no) pic_mode=$withval ;; + *) + pic_mode=default + # Look at the argument we got. We use all the common list separators. + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, + for lt_pkg in $withval; do + IFS=$lt_save_ifs + if test "X$lt_pkg" = "X$lt_p"; then + pic_mode=yes + fi + done + IFS=$lt_save_ifs + ;; + esac +else + pic_mode=default +fi + + + + + + + + + # Check whether --enable-fast-install was given. +if test "${enable_fast_install+set}" = set; then : + enableval=$enable_fast_install; p=${PACKAGE-default} + case $enableval in + yes) enable_fast_install=yes ;; + no) enable_fast_install=no ;; + *) + enable_fast_install=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, + for pkg in $enableval; do + IFS=$lt_save_ifs + if test "X$pkg" = "X$p"; then + enable_fast_install=yes + fi + done + IFS=$lt_save_ifs + ;; + esac +else + enable_fast_install=yes +fi + + + + + + + + + shared_archive_member_spec= +case $host,$enable_shared in +power*-*-aix[5-9]*,yes) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of shared library versioning to provide" >&5 +$as_echo_n "checking which variant of shared library versioning to provide... " >&6; } + +# Check whether --with-aix-soname was given. +if test "${with_aix_soname+set}" = set; then : + withval=$with_aix_soname; case $withval in + aix|svr4|both) + ;; + *) + as_fn_error $? "Unknown argument to --with-aix-soname" "$LINENO" 5 + ;; + esac + lt_cv_with_aix_soname=$with_aix_soname +else + if ${lt_cv_with_aix_soname+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_with_aix_soname=aix +fi + + with_aix_soname=$lt_cv_with_aix_soname +fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_aix_soname" >&5 +$as_echo "$with_aix_soname" >&6; } + if test aix != "$with_aix_soname"; then + # For the AIX way of multilib, we name the shared archive member + # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o', + # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File. + # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag, + # the AIX toolchain works better with OBJECT_MODE set (default 32). + if test 64 = "${OBJECT_MODE-32}"; then + shared_archive_member_spec=shr_64 + else + shared_archive_member_spec=shr + fi + fi + ;; +*) + with_aix_soname=aix + ;; +esac + + + + + + + + + + +# This can be used to rebuild libtool when needed +LIBTOOL_DEPS=$ltmain + +# Always use our own libtool. +LIBTOOL='$(SHELL) $(top_builddir)/libtool' + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +test -z "$LN_S" && LN_S="ln -s" + + + + + + + + + + + + + + +if test -n "${ZSH_VERSION+set}"; then + setopt NO_GLOB_SUBST +fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 +$as_echo_n "checking for objdir... " >&6; } +if ${lt_cv_objdir+:} false; then : + $as_echo_n "(cached) " >&6 +else + rm -f .libs 2>/dev/null +mkdir .libs 2>/dev/null +if test -d .libs; then + lt_cv_objdir=.libs +else + # MS-DOS does not allow filenames that begin with a dot. + lt_cv_objdir=_libs +fi +rmdir .libs 2>/dev/null +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 +$as_echo "$lt_cv_objdir" >&6; } +objdir=$lt_cv_objdir + + + + + +cat >>confdefs.h <<_ACEOF +#define LT_OBJDIR "$lt_cv_objdir/" +_ACEOF + + + + +case $host_os in +aix3*) + # AIX sometimes has problems with the GCC collect2 program. For some + # reason, if we set the COLLECT_NAMES environment variable, the problems + # vanish in a puff of smoke. + if test set != "${COLLECT_NAMES+set}"; then + COLLECT_NAMES= + export COLLECT_NAMES + fi + ;; +esac + +# Global variables: +ofile=libtool +can_build_shared=yes + +# All known linkers require a '.a' archive for static linking (except MSVC, +# which needs '.lib'). +libext=a + +with_gnu_ld=$lt_cv_prog_gnu_ld + +old_CC=$CC +old_CFLAGS=$CFLAGS + +# Set sane defaults for various variables +test -z "$CC" && CC=cc +test -z "$LTCC" && LTCC=$CC +test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS +test -z "$LD" && LD=ld +test -z "$ac_objext" && ac_objext=o + +func_cc_basename $compiler +cc_basename=$func_cc_basename_result + + +# Only perform the check for file, if the check method requires it +test -z "$MAGIC_CMD" && MAGIC_CMD=file +case $deplibs_check_method in +file_magic*) + if test "$file_magic_cmd" = '$MAGIC_CMD'; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5 +$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; } +if ${lt_cv_path_MAGIC_CMD+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $MAGIC_CMD in +[\\/*] | ?:[\\/]*) + lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. + ;; +*) + lt_save_MAGIC_CMD=$MAGIC_CMD + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR + ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" + for ac_dir in $ac_dummy; do + IFS=$lt_save_ifs + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/${ac_tool_prefix}file"; then + lt_cv_path_MAGIC_CMD=$ac_dir/"${ac_tool_prefix}file" + if test -n "$file_magic_test_file"; then + case $deplibs_check_method in + "file_magic "*) + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` + MAGIC_CMD=$lt_cv_path_MAGIC_CMD + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | + $EGREP "$file_magic_regex" > /dev/null; then + : + else + cat <<_LT_EOF 1>&2 + +*** Warning: the command libtool uses to detect shared libraries, +*** $file_magic_cmd, produces output that libtool cannot recognize. +*** The result is that libtool may fail to recognize shared libraries +*** as such. This will affect the creation of libtool libraries that +*** depend on shared libraries, but programs linked with such libtool +*** libraries will work regardless of this problem. Nevertheless, you +*** may want to report the problem to your system manager and/or to +*** bug-libtool@gnu.org + +_LT_EOF + fi ;; + esac + fi + break + fi + done + IFS=$lt_save_ifs + MAGIC_CMD=$lt_save_MAGIC_CMD + ;; +esac +fi + +MAGIC_CMD=$lt_cv_path_MAGIC_CMD +if test -n "$MAGIC_CMD"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 +$as_echo "$MAGIC_CMD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + + + +if test -z "$lt_cv_path_MAGIC_CMD"; then + if test -n "$ac_tool_prefix"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5 +$as_echo_n "checking for file... " >&6; } +if ${lt_cv_path_MAGIC_CMD+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $MAGIC_CMD in +[\\/*] | ?:[\\/]*) + lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. + ;; +*) + lt_save_MAGIC_CMD=$MAGIC_CMD + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR + ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" + for ac_dir in $ac_dummy; do + IFS=$lt_save_ifs + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/file"; then + lt_cv_path_MAGIC_CMD=$ac_dir/"file" + if test -n "$file_magic_test_file"; then + case $deplibs_check_method in + "file_magic "*) + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` + MAGIC_CMD=$lt_cv_path_MAGIC_CMD + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | + $EGREP "$file_magic_regex" > /dev/null; then + : + else + cat <<_LT_EOF 1>&2 + +*** Warning: the command libtool uses to detect shared libraries, +*** $file_magic_cmd, produces output that libtool cannot recognize. +*** The result is that libtool may fail to recognize shared libraries +*** as such. This will affect the creation of libtool libraries that +*** depend on shared libraries, but programs linked with such libtool +*** libraries will work regardless of this problem. Nevertheless, you +*** may want to report the problem to your system manager and/or to +*** bug-libtool@gnu.org + +_LT_EOF + fi ;; + esac + fi + break + fi + done + IFS=$lt_save_ifs + MAGIC_CMD=$lt_save_MAGIC_CMD + ;; +esac +fi + +MAGIC_CMD=$lt_cv_path_MAGIC_CMD +if test -n "$MAGIC_CMD"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 +$as_echo "$MAGIC_CMD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + else + MAGIC_CMD=: + fi +fi + + fi + ;; +esac + +# Use C for the default configuration in the libtool script + +lt_save_CC=$CC +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + +# Source file extension for C test sources. +ac_ext=c + +# Object file extension for compiled C test sources. +objext=o +objext=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code="int some_variable = 0;" + +# Code to be used in simple link tests +lt_simple_link_test_code='int main(){return(0);}' + + + + + + + +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} + +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC + +# Save the default compiler, since it gets overwritten when the other +# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. +compiler_DEFAULT=$CC + +# save warnings/boilerplate of simple test code +ac_outfile=conftest.$ac_objext +echo "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$RM conftest* + +ac_outfile=conftest.$ac_objext +echo "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$RM -r conftest* + + +if test -n "$compiler"; then + +lt_prog_compiler_no_builtin_flag= + +if test yes = "$GCC"; then + case $cc_basename in + nvcc*) + lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;; + *) + lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;; + esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 +$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } +if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_rtti_exceptions=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="-fno-rtti -fno-exceptions" ## exclude from sc_useless_quotes_in_assignment + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_rtti_exceptions=yes + fi + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 +$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } + +if test yes = "$lt_cv_prog_compiler_rtti_exceptions"; then + lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" +else + : +fi + +fi + + + + + + + lt_prog_compiler_wl= +lt_prog_compiler_pic= +lt_prog_compiler_static= + + + if test yes = "$GCC"; then + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_static='-static' + + case $host_os in + aix*) + # All AIX code is PIC. + if test ia64 = "$host_cpu"; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static='-Bstatic' + fi + lt_prog_compiler_pic='-fPIC' + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + lt_prog_compiler_pic='-fPIC' + ;; + m68k) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the '-m68020' flag to GCC prevents building anything better, + # like '-m68040'. + lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' + ;; + esac + ;; + + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + + mingw* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + lt_prog_compiler_pic='-DDLL_EXPORT' + case $host_os in + os2*) + lt_prog_compiler_static='$wl-static' + ;; + esac + ;; + + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + lt_prog_compiler_pic='-fno-common' + ;; + + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + lt_prog_compiler_static= + ;; + + hpux*) + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag + # sets the default TLS model and affects inlining. + case $host_cpu in + hppa*64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic='-fPIC' + ;; + esac + ;; + + interix[3-9]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + + msdosdjgpp*) + # Just because we use GCC doesn't mean we suddenly get shared libraries + # on systems that don't support them. + lt_prog_compiler_can_build_shared=no + enable_shared=no + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic='-fPIC -shared' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + lt_prog_compiler_pic=-Kconform_pic + fi + ;; + + *) + lt_prog_compiler_pic='-fPIC' + ;; + esac + + case $cc_basename in + nvcc*) # Cuda Compiler Driver 2.2 + lt_prog_compiler_wl='-Xlinker ' + if test -n "$lt_prog_compiler_pic"; then + lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic" + fi + ;; + esac + else + # PORTME Check for flag to pass linker flags through the system compiler. + case $host_os in + aix*) + lt_prog_compiler_wl='-Wl,' + if test ia64 = "$host_cpu"; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static='-Bstatic' + else + lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' + fi + ;; + + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + lt_prog_compiler_pic='-fno-common' + case $cc_basename in + nagfor*) + # NAG Fortran compiler + lt_prog_compiler_wl='-Wl,-Wl,,' + lt_prog_compiler_pic='-PIC' + lt_prog_compiler_static='-Bstatic' + ;; + esac + ;; + + mingw* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + lt_prog_compiler_pic='-DDLL_EXPORT' + case $host_os in + os2*) + lt_prog_compiler_static='$wl-static' + ;; + esac + ;; + + hpux9* | hpux10* | hpux11*) + lt_prog_compiler_wl='-Wl,' + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic='+Z' + ;; + esac + # Is there a better lt_prog_compiler_static that works with the bundled CC? + lt_prog_compiler_static='$wl-a ${wl}archive' + ;; + + irix5* | irix6* | nonstopux*) + lt_prog_compiler_wl='-Wl,' + # PIC (with -KPIC) is the default. + lt_prog_compiler_static='-non_shared' + ;; + + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + case $cc_basename in + # old Intel for x86_64, which still supported -KPIC. + ecc*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-static' + ;; + # icc used to be incompatible with GCC. + # ICC 10 doesn't accept -KPIC any more. + icc* | ifort*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fPIC' + lt_prog_compiler_static='-static' + ;; + # Lahey Fortran 8.1. + lf95*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='--shared' + lt_prog_compiler_static='--static' + ;; + nagfor*) + # NAG Fortran compiler + lt_prog_compiler_wl='-Wl,-Wl,,' + lt_prog_compiler_pic='-PIC' + lt_prog_compiler_static='-Bstatic' + ;; + tcc*) + # Fabrice Bellard et al's Tiny C Compiler + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fPIC' + lt_prog_compiler_static='-static' + ;; + pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) + # Portland Group compilers (*not* the Pentium gcc compiler, + # which looks to be a dead project) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fpic' + lt_prog_compiler_static='-Bstatic' + ;; + ccc*) + lt_prog_compiler_wl='-Wl,' + # All Alpha code is PIC. + lt_prog_compiler_static='-non_shared' + ;; + xl* | bgxl* | bgf* | mpixl*) + # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-qpic' + lt_prog_compiler_static='-qstaticlink' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*) + # Sun Fortran 8.3 passes all unrecognized flags to the linker + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + lt_prog_compiler_wl='' + ;; + *Sun\ F* | *Sun*Fortran*) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + lt_prog_compiler_wl='-Qoption ld ' + ;; + *Sun\ C*) + # Sun C 5.9 + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + lt_prog_compiler_wl='-Wl,' + ;; + *Intel*\ [CF]*Compiler*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fPIC' + lt_prog_compiler_static='-static' + ;; + *Portland\ Group*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fpic' + lt_prog_compiler_static='-Bstatic' + ;; + esac + ;; + esac + ;; + + newsos6) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic='-fPIC -shared' + ;; + + osf3* | osf4* | osf5*) + lt_prog_compiler_wl='-Wl,' + # All OSF/1 code is PIC. + lt_prog_compiler_static='-non_shared' + ;; + + rdos*) + lt_prog_compiler_static='-non_shared' + ;; + + solaris*) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + case $cc_basename in + f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) + lt_prog_compiler_wl='-Qoption ld ';; + *) + lt_prog_compiler_wl='-Wl,';; + esac + ;; + + sunos4*) + lt_prog_compiler_wl='-Qoption ld ' + lt_prog_compiler_pic='-PIC' + lt_prog_compiler_static='-Bstatic' + ;; + + sysv4 | sysv4.2uw2* | sysv4.3*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + lt_prog_compiler_pic='-Kconform_pic' + lt_prog_compiler_static='-Bstatic' + fi + ;; + + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + unicos*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_can_build_shared=no + ;; + + uts4*) + lt_prog_compiler_pic='-pic' + lt_prog_compiler_static='-Bstatic' + ;; + + *) + lt_prog_compiler_can_build_shared=no + ;; + esac + fi + +case $host_os in + # For platforms that do not support PIC, -DPIC is meaningless: + *djgpp*) + lt_prog_compiler_pic= + ;; + *) + lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" + ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; } +if ${lt_cv_prog_compiler_pic+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic=$lt_prog_compiler_pic +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5 +$as_echo "$lt_cv_prog_compiler_pic" >&6; } +lt_prog_compiler_pic=$lt_cv_prog_compiler_pic + +# +# Check to make sure the PIC flag actually works. +# +if test -n "$lt_prog_compiler_pic"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 +$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } +if ${lt_cv_prog_compiler_pic_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic_works=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$lt_prog_compiler_pic -DPIC" ## exclude from sc_useless_quotes_in_assignment + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_pic_works=yes + fi + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5 +$as_echo "$lt_cv_prog_compiler_pic_works" >&6; } + +if test yes = "$lt_cv_prog_compiler_pic_works"; then + case $lt_prog_compiler_pic in + "" | " "*) ;; + *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; + esac +else + lt_prog_compiler_pic= + lt_prog_compiler_can_build_shared=no +fi + +fi + + + + + + + + + + + +# +# Check to make sure the static flag actually works. +# +wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\" +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 +$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } +if ${lt_cv_prog_compiler_static_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_static_works=no + save_LDFLAGS=$LDFLAGS + LDFLAGS="$LDFLAGS $lt_tmp_static_flag" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_static_works=yes + fi + else + lt_cv_prog_compiler_static_works=yes + fi + fi + $RM -r conftest* + LDFLAGS=$save_LDFLAGS + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5 +$as_echo "$lt_cv_prog_compiler_static_works" >&6; } + +if test yes = "$lt_cv_prog_compiler_static_works"; then + : +else + lt_prog_compiler_static= +fi + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 +$as_echo "$lt_cv_prog_compiler_c_o" >&6; } + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 +$as_echo "$lt_cv_prog_compiler_c_o" >&6; } + + + + +hard_links=nottested +if test no = "$lt_cv_prog_compiler_c_o" && test no != "$need_locks"; then + # do not overwrite the value of need_locks provided by the user + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 +$as_echo_n "checking if we can lock with hard links... " >&6; } + hard_links=yes + $RM conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 +$as_echo "$hard_links" >&6; } + if test no = "$hard_links"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5 +$as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;} + need_locks=warn + fi +else + need_locks=no +fi + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } + + runpath_var= + allow_undefined_flag= + always_export_symbols=no + archive_cmds= + archive_expsym_cmds= + compiler_needs_object=no + enable_shared_with_static_runtimes=no + export_dynamic_flag_spec= + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + hardcode_automatic=no + hardcode_direct=no + hardcode_direct_absolute=no + hardcode_libdir_flag_spec= + hardcode_libdir_separator= + hardcode_minus_L=no + hardcode_shlibpath_var=unsupported + inherit_rpath=no + link_all_deplibs=unknown + module_cmds= + module_expsym_cmds= + old_archive_from_new_cmds= + old_archive_from_expsyms_cmds= + thread_safe_flag_spec= + whole_archive_flag_spec= + # include_expsyms should be a list of space-separated symbols to be *always* + # included in the symbol list + include_expsyms= + # exclude_expsyms can be an extended regexp of symbols to exclude + # it will be wrapped by ' (' and ')$', so one must not match beginning or + # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc', + # as well as any symbol that contains 'd'. + exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' + # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out + # platforms (ab)use it in PIC code, but their linkers get confused if + # the symbol is explicitly referenced. Since portable code cannot + # rely on this symbol name, it's probably fine to never include it in + # preloaded symbol tables. + # Exclude shared library initialization/finalization symbols. + extract_expsyms_cmds= + + case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + # FIXME: the MSVC++ port hasn't been tested in a loooong time + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + if test yes != "$GCC"; then + with_gnu_ld=no + fi + ;; + interix*) + # we just hope/assume this is gcc and not c89 (= MSVC++) + with_gnu_ld=yes + ;; + openbsd* | bitrig*) + with_gnu_ld=no + ;; + linux* | k*bsd*-gnu | gnu*) + link_all_deplibs=no + ;; + esac + + ld_shlibs=yes + + # On some targets, GNU ld is compatible enough with the native linker + # that we're better off using the native interface for both. + lt_use_gnu_ld_interface=no + if test yes = "$with_gnu_ld"; then + case $host_os in + aix*) + # The AIX port of GNU ld has always aspired to compatibility + # with the native linker. However, as the warning in the GNU ld + # block says, versions before 2.19.5* couldn't really create working + # shared libraries, regardless of the interface used. + case `$LD -v 2>&1` in + *\ \(GNU\ Binutils\)\ 2.19.5*) ;; + *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;; + *\ \(GNU\ Binutils\)\ [3-9]*) ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + fi + + if test yes = "$lt_use_gnu_ld_interface"; then + # If archive_cmds runs LD, not CC, wlarc should be empty + wlarc='$wl' + + # Set some defaults for GNU ld with shared library support. These + # are reset later if shared libraries are not supported. Putting them + # here allows them to be overridden if necessary. + runpath_var=LD_RUN_PATH + hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' + export_dynamic_flag_spec='$wl--export-dynamic' + # ancient GNU ld didn't support --whole-archive et. al. + if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then + whole_archive_flag_spec=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' + else + whole_archive_flag_spec= + fi + supports_anon_versioning=no + case `$LD -v | $SED -e 's/(^)\+)\s\+//' 2>&1` in + *GNU\ gold*) supports_anon_versioning=yes ;; + *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 + *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... + *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... + *\ 2.11.*) ;; # other 2.11 versions + *) supports_anon_versioning=yes ;; + esac + + # See if GNU ld supports shared libraries. + case $host_os in + aix[3-9]*) + # On AIX/PPC, the GNU linker is very broken + if test ia64 != "$host_cpu"; then + ld_shlibs=no + cat <<_LT_EOF 1>&2 + +*** Warning: the GNU linker, at least up to release 2.19, is reported +*** to be unable to reliably create shared libraries on AIX. +*** Therefore, libtool is disabling shared libraries support. If you +*** really care for shared libraries, you may want to install binutils +*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. +*** You will then need to restart the configuration process. + +_LT_EOF + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds='' + ;; + m68k) + 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)' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + ;; + esac + ;; + + beos*) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + allow_undefined_flag=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + else + ld_shlibs=no + fi + ;; + + cygwin* | mingw* | pw32* | cegcc*) + # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, + # as there is no search path for DLLs. + hardcode_libdir_flag_spec='-L$libdir' + export_dynamic_flag_spec='$wl--export-all-symbols' + allow_undefined_flag=unsupported + always_export_symbols=no + enable_shared_with_static_runtimes=yes + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' + exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' + + if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file, use it as + # is; otherwise, prepend EXPORTS... + archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + ld_shlibs=no + fi + ;; + + haiku*) + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + link_all_deplibs=yes + ;; + + os2*) + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + allow_undefined_flag=unsupported + shrext_cmds=.dll + archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + prefix_cmds="$SED"~ + if test EXPORTS = "`$SED 1q $export_symbols`"; then + prefix_cmds="$prefix_cmds -e 1d"; + fi~ + prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ + cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + enable_shared_with_static_runtimes=yes + ;; + + interix[3-9]*) + hardcode_direct=no + hardcode_shlibpath_var=no + hardcode_libdir_flag_spec='$wl-rpath,$libdir' + export_dynamic_flag_spec='$wl-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + archive_expsym_cmds='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + + gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) + tmp_diet=no + if test linux-dietlibc = "$host_os"; then + case $cc_basename in + diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) + esac + fi + if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ + && test no = "$tmp_diet" + then + tmp_addflag=' $pic_flag' + tmp_sharedflag='-shared' + case $cc_basename,$host_cpu in + pgcc*) # Portland Group C compiler + whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + tmp_addflag=' $pic_flag' + ;; + pgf77* | pgf90* | pgf95* | pgfortran*) + # Portland Group f77 and f90 compilers + whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + tmp_addflag=' $pic_flag -Mnomain' ;; + ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 + tmp_addflag=' -i_dynamic' ;; + efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 + tmp_addflag=' -i_dynamic -nofor_main' ;; + ifc* | ifort*) # Intel Fortran compiler + tmp_addflag=' -nofor_main' ;; + lf95*) # Lahey Fortran 8.1 + whole_archive_flag_spec= + tmp_sharedflag='--shared' ;; + nagfor*) # NAGFOR 5.3 + tmp_sharedflag='-Wl,-shared' ;; + xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below) + tmp_sharedflag='-qmkshrobj' + tmp_addflag= ;; + nvcc*) # Cuda Compiler Driver 2.2 + whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + compiler_needs_object=yes + ;; + esac + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) # Sun C 5.9 + whole_archive_flag_spec='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + compiler_needs_object=yes + tmp_sharedflag='-G' ;; + *Sun\ F*) # Sun Fortran 8.3 + tmp_sharedflag='-G' ;; + esac + archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + + if test yes = "$supports_anon_versioning"; then + archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' + fi + + case $cc_basename in + tcc*) + export_dynamic_flag_spec='-rdynamic' + ;; + xlf* | bgf* | bgxlf* | mpixlf*) + # IBM XL Fortran 10.1 on PPC cannot create shared libs itself + whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive' + hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' + archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' + if test yes = "$supports_anon_versioning"; then + archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' + fi + ;; + esac + else + ld_shlibs=no + fi + ;; + + netbsd* | netbsdelf*-gnu) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' + wlarc= + else + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + fi + ;; + + solaris*) + if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then + ld_shlibs=no + cat <<_LT_EOF 1>&2 + +*** Warning: The releases 2.8.* of the GNU linker cannot reliably +*** create shared libraries on Solaris systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.9.1 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +_LT_EOF + elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs=no + fi + ;; + + sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) + case `$LD -v 2>&1` in + *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) + ld_shlibs=no + cat <<_LT_EOF 1>&2 + +*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot +*** reliably create shared libraries on SCO systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.16.91.0.3 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +_LT_EOF + ;; + *) + # For security reasons, it is highly recommended that you always + # use absolute paths for naming shared libraries, and exclude the + # DT_RUNPATH tag from executables and libraries. But doing so + # requires that you compile everything twice, which is a pain. + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs=no + fi + ;; + esac + ;; + + sunos4*) + archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' + wlarc= + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + *) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs=no + fi + ;; + esac + + if test no = "$ld_shlibs"; then + runpath_var= + hardcode_libdir_flag_spec= + export_dynamic_flag_spec= + whole_archive_flag_spec= + fi + else + # PORTME fill in a description of your system's linker (not GNU ld) + case $host_os in + aix3*) + allow_undefined_flag=unsupported + always_export_symbols=yes + 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' + # Note: this linker hardcodes the directories in LIBPATH if there + # are no directories specified by -L. + hardcode_minus_L=yes + if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then + # Neither direct hardcoding nor static linking is supported with a + # broken collect2. + hardcode_direct=unsupported + fi + ;; + + aix[4-9]*) + if test ia64 = "$host_cpu"; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag= + else + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to GNU nm, but means don't demangle to AIX nm. + # Without the "-l" option, or with the "-B" option, AIX nm treats + # weak defined symbols like other global defined symbols, whereas + # GNU nm marks them as "W". + # While the 'weak' keyword is ignored in the Export File, we need + # it in the Import File for the 'aix-soname' feature, so we have + # to replace the "-B" option with "-P" for AIX nm. + if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then + export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' + else + export_symbols_cmds='`func_echo_all $NM | $SED -e '\''s/B\([^B]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && (substr(\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' + fi + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # have runtime linking enabled, and use it for executables. + # For shared libraries, we enable/disable runtime linking + # depending on the kind of the shared library created - + # when "with_aix_soname,aix_use_runtimelinking" is: + # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables + # "aix,yes" lib.so shared, rtl:yes, for executables + # lib.a static archive + # "both,no" lib.so.V(shr.o) shared, rtl:yes + # lib.a(lib.so.V) shared, rtl:no, for executables + # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a(lib.so.V) shared, rtl:no + # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a static archive + case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) + for ld_flag in $LDFLAGS; do + if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then + aix_use_runtimelinking=yes + break + fi + done + if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then + # With aix-soname=svr4, we create the lib.so.V shared archives only, + # so we don't have lib.a shared libs to link our executables. + # We have to force runtime linking in this case. + aix_use_runtimelinking=yes + LDFLAGS="$LDFLAGS -Wl,-brtl" + fi + ;; + esac + + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + archive_cmds='' + hardcode_direct=yes + hardcode_direct_absolute=yes + hardcode_libdir_separator=':' + link_all_deplibs=yes + file_list_spec='$wl-f,' + case $with_aix_soname,$aix_use_runtimelinking in + aix,*) ;; # traditional, no import file + svr4,* | *,yes) # use import file + # The Import File defines what to hardcode. + hardcode_direct=no + hardcode_direct_absolute=no + ;; + esac + + if test yes = "$GCC"; then + case $host_os in aix4.[012]|aix4.[012].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`$CC -print-prog-name=collect2` + if test -f "$collect2name" && + strings "$collect2name" | $GREP resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + hardcode_direct=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + hardcode_minus_L=yes + hardcode_libdir_flag_spec='-L$libdir' + hardcode_libdir_separator= + fi + ;; + esac + shared_flag='-shared' + if test yes = "$aix_use_runtimelinking"; then + shared_flag="$shared_flag "'$wl-G' + fi + # Need to ensure runtime linking is disabled for the traditional + # shared library, or the linker may eventually find shared libraries + # /with/ Import File - we do not want to mix them. + shared_flag_aix='-shared' + shared_flag_svr4='-shared $wl-G' + else + # not using gcc + if test ia64 = "$host_cpu"; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test yes = "$aix_use_runtimelinking"; then + shared_flag='$wl-G' + else + shared_flag='$wl-bM:SRE' + fi + shared_flag_aix='$wl-bM:SRE' + shared_flag_svr4='$wl-G' + fi + fi + + export_dynamic_flag_spec='$wl-bexpall' + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to export. + always_export_symbols=yes + if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + allow_undefined_flag='-berok' + # Determine the default libpath from the value encoded in an + # empty executable. + if test set = "${lt_cv_aix_libpath+set}"; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath_+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_=/usr/lib:/lib + fi + +fi + + aix_libpath=$lt_cv_aix_libpath_ +fi + + hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath" + archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag + else + if test ia64 = "$host_cpu"; then + hardcode_libdir_flag_spec='$wl-R $libdir:/usr/lib:/lib' + allow_undefined_flag="-z nodefs" + archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an + # empty executable. + if test set = "${lt_cv_aix_libpath+set}"; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath_+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_=/usr/lib:/lib + fi + +fi + + aix_libpath=$lt_cv_aix_libpath_ +fi + + hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + no_undefined_flag=' $wl-bernotok' + allow_undefined_flag=' $wl-berok' + if test yes = "$with_gnu_ld"; then + # We only use this code for GNU lds that support --whole-archive. + whole_archive_flag_spec='$wl--whole-archive$convenience $wl--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + whole_archive_flag_spec='$convenience' + fi + archive_cmds_need_lc=yes + archive_expsym_cmds='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' + # -brtl affects multiple linker settings, -berok does not and is overridden later + compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`' + if test svr4 != "$with_aix_soname"; then + # This is similar to how AIX traditionally builds its shared libraries. + archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' + fi + if test aix != "$with_aix_soname"; then + archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' + else + # used by -dlpreopen to get the symbols + archive_expsym_cmds="$archive_expsym_cmds"'~$MV $output_objdir/$realname.d/$soname $output_objdir' + fi + archive_expsym_cmds="$archive_expsym_cmds"'~$RM -r $output_objdir/$realname.d' + fi + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds='' + ;; + m68k) + 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)' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + ;; + esac + ;; + + bsdi[45]*) + export_dynamic_flag_spec=-rdynamic + ;; + + cygwin* | mingw* | pw32* | cegcc*) + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + case $cc_basename in + cl*) + # Native MSVC + hardcode_libdir_flag_spec=' ' + allow_undefined_flag=unsupported + always_export_symbols=yes + file_list_spec='@' + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=.dll + # FIXME: Setting linknames here is a bad hack. + archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' + archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then + cp "$export_symbols" "$output_objdir/$soname.def"; + echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; + else + $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, )='true' + enable_shared_with_static_runtimes=yes + exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' + # Don't use ranlib + old_postinstall_cmds='chmod 644 $oldlib' + postlink_cmds='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile=$lt_outputfile.exe + lt_tool_outputfile=$lt_tool_outputfile.exe + ;; + esac~ + if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # Assume MSVC wrapper + hardcode_libdir_flag_spec=' ' + allow_undefined_flag=unsupported + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=.dll + # FIXME: Setting linknames here is a bad hack. + archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' + # The linker will automatically build a .lib file if we build a DLL. + old_archive_from_new_cmds='true' + # FIXME: Should let the user specify the lib program. + old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs' + enable_shared_with_static_runtimes=yes + ;; + esac + ;; + + darwin* | rhapsody*) + + + archive_cmds_need_lc=no + hardcode_direct=no + hardcode_automatic=yes + hardcode_shlibpath_var=unsupported + if test yes = "$lt_cv_ld_force_load"; then + whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' + + else + whole_archive_flag_spec='' + fi + link_all_deplibs=yes + allow_undefined_flag=$_lt_dar_allow_undefined + case $cc_basename in + ifort*|nagfor*) _lt_dar_can_shared=yes ;; + *) _lt_dar_can_shared=$GCC ;; + esac + if test yes = "$_lt_dar_can_shared"; then + output_verbose_link_cmd=func_echo_all + archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" + module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" + archive_expsym_cmds="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" + module_expsym_cmds="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" + + else + ld_shlibs=no + fi + + ;; + + dgux*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_shlibpath_var=no + ;; + + # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor + # support. Future versions do this automatically, but an explicit c++rt0.o + # does not break anything, and helps significantly (at the cost of a little + # extra space). + freebsd2.2*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + # Unfortunately, older versions of FreeBSD 2 do not have this feature. + freebsd2.*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes + hardcode_minus_L=yes + hardcode_shlibpath_var=no + ;; + + # FreeBSD 3 and greater uses gcc -shared to do shared libraries. + freebsd* | dragonfly*) + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + hpux9*) + if test yes = "$GCC"; then + archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' + else + archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' + fi + hardcode_libdir_flag_spec='$wl+b $wl$libdir' + hardcode_libdir_separator=: + hardcode_direct=yes + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + export_dynamic_flag_spec='$wl-E' + ;; + + hpux10*) + if test yes,no = "$GCC,$with_gnu_ld"; then + archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' + fi + if test no = "$with_gnu_ld"; then + hardcode_libdir_flag_spec='$wl+b $wl$libdir' + hardcode_libdir_separator=: + hardcode_direct=yes + hardcode_direct_absolute=yes + export_dynamic_flag_spec='$wl-E' + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + fi + ;; + + hpux11*) + if test yes,no = "$GCC,$with_gnu_ld"; then + case $host_cpu in + hppa*64*) + archive_cmds='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + else + case $host_cpu in + hppa*64*) + archive_cmds='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + archive_cmds='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + + # Older versions of the 11.00 compiler do not understand -b yet + # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5 +$as_echo_n "checking if $CC understands -b... " >&6; } +if ${lt_cv_prog_compiler__b+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler__b=no + save_LDFLAGS=$LDFLAGS + LDFLAGS="$LDFLAGS -b" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler__b=yes + fi + else + lt_cv_prog_compiler__b=yes + fi + fi + $RM -r conftest* + LDFLAGS=$save_LDFLAGS + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5 +$as_echo "$lt_cv_prog_compiler__b" >&6; } + +if test yes = "$lt_cv_prog_compiler__b"; then + archive_cmds='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' +else + archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' +fi + + ;; + esac + fi + if test no = "$with_gnu_ld"; then + hardcode_libdir_flag_spec='$wl+b $wl$libdir' + hardcode_libdir_separator=: + + case $host_cpu in + hppa*64*|ia64*) + hardcode_direct=no + hardcode_shlibpath_var=no + ;; + *) + hardcode_direct=yes + hardcode_direct_absolute=yes + export_dynamic_flag_spec='$wl-E' + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + ;; + esac + fi + ;; + + irix5* | irix6* | nonstopux*) + if test yes = "$GCC"; then + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + # Try to use the -exported_symbol ld option, if it does not + # work, assume that -exports_file does not work either and + # implicitly export all symbols. + # This should be the same for all languages, so no per-tag cache variable. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5 +$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; } +if ${lt_cv_irix_exported_symbol+:} false; then : + $as_echo_n "(cached) " >&6 +else + save_LDFLAGS=$LDFLAGS + LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +int foo (void) { return 0; } +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + lt_cv_irix_exported_symbol=yes +else + lt_cv_irix_exported_symbol=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS=$save_LDFLAGS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5 +$as_echo "$lt_cv_irix_exported_symbol" >&6; } + if test yes = "$lt_cv_irix_exported_symbol"; then + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib' + fi + link_all_deplibs=no + else + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib' + fi + archive_cmds_need_lc='no' + hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' + hardcode_libdir_separator=: + inherit_rpath=yes + link_all_deplibs=yes + ;; + + linux*) + case $cc_basename in + tcc*) + # Fabrice Bellard et al's Tiny C Compiler + ld_shlibs=yes + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + netbsd* | netbsdelf*-gnu) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out + else + archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF + fi + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; + + newsos6) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes + hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' + hardcode_libdir_separator=: + hardcode_shlibpath_var=no + ;; + + *nto* | *qnx*) + ;; + + openbsd* | bitrig*) + if test -f /usr/libexec/ld.so; then + hardcode_direct=yes + hardcode_shlibpath_var=no + hardcode_direct_absolute=yes + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols' + hardcode_libdir_flag_spec='$wl-rpath,$libdir' + export_dynamic_flag_spec='$wl-E' + else + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec='$wl-rpath,$libdir' + fi + else + ld_shlibs=no + fi + ;; + + os2*) + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + allow_undefined_flag=unsupported + shrext_cmds=.dll + archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + prefix_cmds="$SED"~ + if test EXPORTS = "`$SED 1q $export_symbols`"; then + prefix_cmds="$prefix_cmds -e 1d"; + fi~ + prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ + cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + enable_shared_with_static_runtimes=yes + ;; + + osf3*) + if test yes = "$GCC"; then + allow_undefined_flag=' $wl-expect_unresolved $wl\*' + archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + else + allow_undefined_flag=' -expect_unresolved \*' + archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + fi + archive_cmds_need_lc='no' + hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' + hardcode_libdir_separator=: + ;; + + osf4* | osf5*) # as osf3* with the addition of -msym flag + if test yes = "$GCC"; then + allow_undefined_flag=' $wl-expect_unresolved $wl\*' + archive_cmds='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' + else + allow_undefined_flag=' -expect_unresolved \*' + archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ + $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp' + + # Both c and cxx compiler support -rpath directly + hardcode_libdir_flag_spec='-rpath $libdir' + fi + archive_cmds_need_lc='no' + hardcode_libdir_separator=: + ;; + + solaris*) + no_undefined_flag=' -z defs' + if test yes = "$GCC"; then + wlarc='$wl' + archive_cmds='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + else + case `$CC -V 2>&1` in + *"Compilers 5.0"*) + wlarc='' + archive_cmds='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags' + archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' + ;; + *) + wlarc='$wl' + archive_cmds='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + ;; + esac + fi + hardcode_libdir_flag_spec='-R$libdir' + hardcode_shlibpath_var=no + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands '-z linker_flag'. GCC discards it without '$wl', + # but is careful enough not to reorder. + # Supported since Solaris 2.6 (maybe 2.5.1?) + if test yes = "$GCC"; then + whole_archive_flag_spec='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' + else + whole_archive_flag_spec='-z allextract$convenience -z defaultextract' + fi + ;; + esac + link_all_deplibs=yes + ;; + + sunos4*) + if test sequent = "$host_vendor"; then + # Use $CC to link under sequent, because it throws in some extra .o + # files that make .init and .fini sections work. + archive_cmds='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' + fi + hardcode_libdir_flag_spec='-L$libdir' + hardcode_direct=yes + hardcode_minus_L=yes + hardcode_shlibpath_var=no + ;; + + sysv4) + case $host_vendor in + sni) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes # is this really true??? + ;; + siemens) + ## LD is ld it makes a PLAMLIB + ## CC just makes a GrossModule. + archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' + reload_cmds='$CC -r -o $output$reload_objs' + hardcode_direct=no + ;; + motorola) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=no #Motorola manual says yes, but my tests say they lie + ;; + esac + runpath_var='LD_RUN_PATH' + hardcode_shlibpath_var=no + ;; + + sysv4.3*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var=no + export_dynamic_flag_spec='-Bexport' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var=no + runpath_var=LD_RUN_PATH + hardcode_runpath_var=yes + ld_shlibs=yes + fi + ;; + + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) + no_undefined_flag='$wl-z,text' + archive_cmds_need_lc=no + hardcode_shlibpath_var=no + runpath_var='LD_RUN_PATH' + + if test yes = "$GCC"; then + archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + + sysv5* | sco3.2v5* | sco5v6*) + # Note: We CANNOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + no_undefined_flag='$wl-z,text' + allow_undefined_flag='$wl-z,nodefs' + archive_cmds_need_lc=no + hardcode_shlibpath_var=no + hardcode_libdir_flag_spec='$wl-R,$libdir' + hardcode_libdir_separator=':' + link_all_deplibs=yes + export_dynamic_flag_spec='$wl-Bexport' + runpath_var='LD_RUN_PATH' + + if test yes = "$GCC"; then + archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + + uts4*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_shlibpath_var=no + ;; + + *) + ld_shlibs=no + ;; + esac + + if test sni = "$host_vendor"; then + case $host in + sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) + export_dynamic_flag_spec='$wl-Blargedynsym' + ;; + esac + fi + fi + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 +$as_echo "$ld_shlibs" >&6; } +test no = "$ld_shlibs" && can_build_shared=no + +with_gnu_ld=$with_gnu_ld + + + + + + + + + + + + + + + +# +# Do we need to explicitly link libc? +# +case "x$archive_cmds_need_lc" in +x|xyes) + # Assume -lc should be added + archive_cmds_need_lc=yes + + if test yes,yes = "$GCC,$enable_shared"; then + case $archive_cmds in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 +$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } +if ${lt_cv_archive_cmds_need_lc+:} false; then : + $as_echo_n "(cached) " >&6 +else + $RM conftest* + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$lt_prog_compiler_wl + pic_flag=$lt_prog_compiler_pic + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$allow_undefined_flag + allow_undefined_flag= + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 + (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + then + lt_cv_archive_cmds_need_lc=no + else + lt_cv_archive_cmds_need_lc=yes + fi + allow_undefined_flag=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5 +$as_echo "$lt_cv_archive_cmds_need_lc" >&6; } + archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc + ;; + esac + fi + ;; +esac + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 +$as_echo_n "checking dynamic linker characteristics... " >&6; } + +if test yes = "$GCC"; then + case $host_os in + darwin*) lt_awk_arg='/^libraries:/,/LR/' ;; + *) lt_awk_arg='/^libraries:/' ;; + esac + case $host_os in + mingw* | cegcc*) lt_sed_strip_eq='s|=\([A-Za-z]:\)|\1|g' ;; + *) lt_sed_strip_eq='s|=/|/|g' ;; + esac + lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` + case $lt_search_path_spec in + *\;*) + # if the path contains ";" then we assume it to be the separator + # otherwise default to the standard path separator (i.e. ":") - it is + # assumed that no part of a normal pathname contains ";" but that should + # okay in the real world where ";" in dirpaths is itself problematic. + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` + ;; + *) + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` + ;; + esac + # Ok, now we have the path, separated by spaces, we can step through it + # and add multilib dir if necessary... + lt_tmp_lt_search_path_spec= + lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` + # ...but if some path component already ends with the multilib dir we assume + # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer). + case "$lt_multi_os_dir; $lt_search_path_spec " in + "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*) + lt_multi_os_dir= + ;; + esac + for lt_sys_path in $lt_search_path_spec; do + if test -d "$lt_sys_path$lt_multi_os_dir"; then + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir" + elif test -n "$lt_multi_os_dir"; then + test -d "$lt_sys_path" && \ + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" + fi + done + lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' +BEGIN {RS = " "; FS = "/|\n";} { + lt_foo = ""; + lt_count = 0; + for (lt_i = NF; lt_i > 0; lt_i--) { + if ($lt_i != "" && $lt_i != ".") { + if ($lt_i == "..") { + lt_count++; + } else { + if (lt_count == 0) { + lt_foo = "/" $lt_i lt_foo; + } else { + lt_count--; + } + } + } + } + if (lt_foo != "") { lt_freq[lt_foo]++; } + if (lt_freq[lt_foo] == 1) { print lt_foo; } +}'` + # AWK program above erroneously prepends '/' to C:/dos/paths + # for these hosts. + case $host_os in + mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ + $SED 's|/\([A-Za-z]:\)|\1|g'` ;; + esac + sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` +else + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" +fi +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=.so +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" +need_lib_prefix=unknown +hardcode_into_libs=no + +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown + + + +case $host_os in +aix3*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname.a' + shlibpath_var=LIBPATH + + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='$libname$release$shared_ext$major' + ;; + +aix[4-9]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test ia64 = "$host_cpu"; then + # AIX 5 supports IA64 + library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line '#! .'. This would cause the generated library to + # depend on '.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[01] | aix4.[01].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then + : + else + can_build_shared=no + fi + ;; + esac + # Using Import Files as archive members, it is possible to support + # filename-based versioning of shared library archives on AIX. While + # this would work for both with and without runtime linking, it will + # prevent static linking of such archives. So we do filename-based + # shared library versioning with .so extension only, which is used + # when both runtime linking and shared linking is enabled. + # Unfortunately, runtime linking may impact performance, so we do + # not want this to be the default eventually. Also, we use the + # versioned .so libs for executables only if there is the -brtl + # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. + # To allow for filename-based versioning support, we need to create + # libNAME.so.V as an archive file, containing: + # *) an Import File, referring to the versioned filename of the + # archive as well as the shared archive member, telling the + # bitwidth (32 or 64) of that shared object, and providing the + # list of exported symbols of that shared object, eventually + # decorated with the 'weak' keyword + # *) the shared object with the F_LOADONLY flag set, to really avoid + # it being seen by the linker. + # At run time we better use the real file rather than another symlink, + # but for link time we create the symlink libNAME.so -> libNAME.so.V + + case $with_aix_soname,$aix_use_runtimelinking in + # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + aix,yes) # traditional libtool + dynamic_linker='AIX unversionable lib.so' + # If using run time linking (on AIX 4.2 or later) use lib.so + # instead of lib.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + ;; + aix,no) # traditional AIX only + dynamic_linker='AIX lib.a(lib.so.V)' + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='$libname$release.a $libname.a' + soname_spec='$libname$release$shared_ext$major' + ;; + svr4,*) # full svr4 only + dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)" + library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' + # We do not specify a path in Import Files, so LIBPATH fires. + shlibpath_overrides_runpath=yes + ;; + *,yes) # both, prefer svr4 + dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)" + library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' + # unpreferred sharedlib libNAME.a needs extra handling + postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' + postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' + # We do not specify a path in Import Files, so LIBPATH fires. + shlibpath_overrides_runpath=yes + ;; + *,no) # both, prefer aix + dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)" + library_names_spec='$libname$release.a $libname.a' + soname_spec='$libname$release$shared_ext$major' + # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling + postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' + postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' + ;; + esac + shlibpath_var=LIBPATH + fi + ;; + +amigaos*) + case $host_cpu in + powerpc) + # Since July 2007 AmigaOS4 officially supports .so libraries. + # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + ;; + m68k) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; $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' + ;; + esac + ;; + +beos*) + library_names_spec='$libname$shared_ext' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; + +bsdi[45]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; + +cygwin* | mingw* | pw32* | cegcc*) + version_type=windows + shrext_cmds=.dll + need_version=no + need_lib_prefix=no + + case $GCC,$cc_basename in + yes,*) + # gcc + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + + case $host_os in + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' + + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api" + ;; + mingw* | cegcc*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' + ;; + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' + ;; + esac + dynamic_linker='Win32 ld.exe' + ;; + + *,cl*) + # Native MSVC + libname_spec='$name' + soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' + library_names_spec='$libname.dll.lib' + + case $build_os in + mingw*) + sys_lib_search_path_spec= + lt_save_ifs=$IFS + IFS=';' + for lt_path in $LIB + do + IFS=$lt_save_ifs + # Let DOS variable expansion print the short 8.3 style file name. + lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` + sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" + done + IFS=$lt_save_ifs + # Convert to MSYS style. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` + ;; + cygwin*) + # Convert to unix form, then to dos form, then back to unix form + # but this time dos style (no spaces!) so that the unix form looks + # like /cygdrive/c/PROGRA~1:/cygdr... + sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` + sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` + sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + ;; + *) + sys_lib_search_path_spec=$LIB + if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then + # It is most probably a Windows format PATH. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + # FIXME: find the short name or the path components, as spaces are + # common. (e.g. "Program Files" -> "PROGRA~1") + ;; + esac + + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + dynamic_linker='Win32 link.exe' + ;; + + *) + # Assume MSVC wrapper + library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib' + dynamic_linker='Win32 ld.exe' + ;; + esac + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; + +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' + soname_spec='$libname$release$major$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' + + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib" + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; + +dgux*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` + else + case $host_os in + freebsd[23].*) objformat=aout ;; + *) objformat=elf ;; + esac + fi + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + need_version=no + need_lib_prefix=no + ;; + freebsd-*) + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + need_version=yes + ;; + esac + shlibpath_var=LD_LIBRARY_PATH + case $host_os in + freebsd2.*) + shlibpath_overrides_runpath=yes + ;; + freebsd3.[01]* | freebsdelf3.[01]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ + freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + *) # from 4.6 on, and DragonFly + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + esac + ;; + +haiku*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + dynamic_linker="$host_os runtime_loader" + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LIBRARY_PATH + shlibpath_overrides_runpath=no + sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' + hardcode_into_libs=yes + ;; + +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + if test 32 = "$HPUX_IA64_MODE"; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + sys_lib_dlsearch_path_spec=/usr/lib/hpux32 + else + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + sys_lib_dlsearch_path_spec=/usr/lib/hpux64 + fi + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555, ... + postinstall_cmds='chmod 555 $lib' + # or fails outright, so override atomically: + install_override_mode=555 + ;; + +interix[3-9]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; + *) + if test yes = "$lt_cv_prog_gnu_ld"; then + version_type=linux # correct to gnu/linux during the next big refactor + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='$libname$release$shared_ext$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; + esac + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" + sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" + hardcode_into_libs=yes + ;; + +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; + +linux*android*) + version_type=none # Android doesn't support versioned libraries. + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext' + soname_spec='$libname$release$shared_ext' + finish_cmds= + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + dynamic_linker='Android linker' + # Don't embed -rpath directories since the linker doesn't support them. + hardcode_libdir_flag_spec='-L$libdir' + ;; + +# This must be glibc/ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + + # Some binutils ld are patched to set DT_RUNPATH + if ${lt_cv_shlibpath_overrides_runpath+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_shlibpath_overrides_runpath=no + save_LDFLAGS=$LDFLAGS + save_libdir=$libdir + eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \ + LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\"" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : + lt_cv_shlibpath_overrides_runpath=yes +fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS=$save_LDFLAGS + libdir=$save_libdir + +fi + + shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + # Ideally, we could use ldconfig to report *all* directores which are + # searched for libraries, however this is still not possible. Aside from not + # being certain /sbin/ldconfig is available, command + # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, + # even though it is searched at run-time. Try to do the best guess by + # appending ld.so.conf contents (and includes) to the search path. + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi + + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; + +netbsdelf*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='NetBSD ld.elf_so' + ;; + +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + +newsos6) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +*nto* | *qnx*) + version_type=qnx + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='ldqnx.so' + ;; + +openbsd* | bitrig*) + version_type=sunos + sys_lib_dlsearch_path_spec=/usr/lib + need_lib_prefix=no + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then + need_version=no + else + need_version=yes + fi + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +os2*) + libname_spec='$name' + version_type=windows + shrext_cmds=.dll + need_version=no + need_lib_prefix=no + # OS/2 can only load a DLL with a base name of 8 characters or less. + soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; + v=$($ECHO $release$versuffix | tr -d .-); + n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); + $ECHO $n$v`$shared_ext' + library_names_spec='${libname}_dll.$libext' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=BEGINLIBPATH + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + ;; + +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='$libname$release$shared_ext$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + +rdos*) + dynamic_linker=no + ;; + +solaris*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; + +sunos4*) + version_type=sunos + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test yes = "$with_gnu_ld"; then + need_lib_prefix=no + fi + need_version=yes + ;; + +sysv4 | sysv4.3*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + runpath_var=LD_RUN_PATH + ;; + siemens) + need_lib_prefix=no + ;; + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + ;; + esac + ;; + +sysv4*MP*) + if test -d /usr/nec; then + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' + soname_spec='$libname$shared_ext.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + version_type=sco + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + if test yes = "$with_gnu_ld"; then + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' + else + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' + case $host_os in + sco3.2v5*) + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" + ;; + esac + fi + sys_lib_dlsearch_path_spec='/usr/lib' + ;; + +tpf*) + # TPF is a cross-target only. Preferred cross-host = GNU/Linux. + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +uts4*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +*) + dynamic_linker=no + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 +$as_echo "$dynamic_linker" >&6; } +test no = "$dynamic_linker" && can_build_shared=no + +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test yes = "$GCC"; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +fi + +if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then + sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec +fi + +if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then + sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec +fi + +# remember unaugmented sys_lib_dlsearch_path content for libtool script decls... +configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec + +# ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code +func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" + +# to be used as default LT_SYS_LIBRARY_PATH value in generated libtool +configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 +$as_echo_n "checking how to hardcode library paths into programs... " >&6; } +hardcode_action= +if test -n "$hardcode_libdir_flag_spec" || + test -n "$runpath_var" || + test yes = "$hardcode_automatic"; then + + # We can hardcode non-existent directories. + if test no != "$hardcode_direct" && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, )" && + test no != "$hardcode_minus_L"; then + # Linking always hardcodes the temporary library directory. + hardcode_action=relink + else + # We can link without hardcoding, and we can hardcode nonexisting dirs. + hardcode_action=immediate + fi +else + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + hardcode_action=unsupported +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5 +$as_echo "$hardcode_action" >&6; } + +if test relink = "$hardcode_action" || + test yes = "$inherit_rpath"; then + # Fast installation is not supported + enable_fast_install=no +elif test yes = "$shlibpath_overrides_runpath" || + test no = "$enable_shared"; then + # Fast installation is not necessary + enable_fast_install=needless +fi + + + + + + + if test yes != "$enable_dlopen"; then + enable_dlopen=unknown + enable_dlopen_self=unknown + enable_dlopen_self_static=unknown +else + lt_cv_dlopen=no + lt_cv_dlopen_libs= + + case $host_os in + beos*) + lt_cv_dlopen=load_add_on + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + ;; + + mingw* | pw32* | cegcc*) + lt_cv_dlopen=LoadLibrary + lt_cv_dlopen_libs= + ;; + + cygwin*) + lt_cv_dlopen=dlopen + lt_cv_dlopen_libs= + ;; + + darwin*) + # if libdl is installed we need to link against it + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 +$as_echo_n "checking for dlopen in -ldl... " >&6; } +if ${ac_cv_lib_dl_dlopen+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldl $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dl_dlopen=yes +else + ac_cv_lib_dl_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 +$as_echo "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = xyes; then : + lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl +else + + lt_cv_dlopen=dyld + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + +fi + + ;; + + tpf*) + # Don't try to run any link tests for TPF. We know it's impossible + # because TPF is a cross-compiler, and we know how we open DSOs. + lt_cv_dlopen=dlopen + lt_cv_dlopen_libs= + lt_cv_dlopen_self=no + ;; + + *) + ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" +if test "x$ac_cv_func_shl_load" = xyes; then : + lt_cv_dlopen=shl_load +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 +$as_echo_n "checking for shl_load in -ldld... " >&6; } +if ${ac_cv_lib_dld_shl_load+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char shl_load (); +int +main () +{ +return shl_load (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dld_shl_load=yes +else + ac_cv_lib_dld_shl_load=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 +$as_echo "$ac_cv_lib_dld_shl_load" >&6; } +if test "x$ac_cv_lib_dld_shl_load" = xyes; then : + lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld +else + ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" +if test "x$ac_cv_func_dlopen" = xyes; then : + lt_cv_dlopen=dlopen +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 +$as_echo_n "checking for dlopen in -ldl... " >&6; } +if ${ac_cv_lib_dl_dlopen+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldl $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dl_dlopen=yes +else + ac_cv_lib_dl_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 +$as_echo "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = xyes; then : + lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 +$as_echo_n "checking for dlopen in -lsvld... " >&6; } +if ${ac_cv_lib_svld_dlopen+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lsvld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_svld_dlopen=yes +else + ac_cv_lib_svld_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 +$as_echo "$ac_cv_lib_svld_dlopen" >&6; } +if test "x$ac_cv_lib_svld_dlopen" = xyes; then : + lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 +$as_echo_n "checking for dld_link in -ldld... " >&6; } +if ${ac_cv_lib_dld_dld_link+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dld_link (); +int +main () +{ +return dld_link (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dld_dld_link=yes +else + ac_cv_lib_dld_dld_link=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 +$as_echo "$ac_cv_lib_dld_dld_link" >&6; } +if test "x$ac_cv_lib_dld_dld_link" = xyes; then : + lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld +fi + + +fi + + +fi + + +fi + + +fi + + +fi + + ;; + esac + + if test no = "$lt_cv_dlopen"; then + enable_dlopen=no + else + enable_dlopen=yes + fi + + case $lt_cv_dlopen in + dlopen) + save_CPPFLAGS=$CPPFLAGS + test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" + + save_LDFLAGS=$LDFLAGS + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" + + save_LIBS=$LIBS + LIBS="$lt_cv_dlopen_libs $LIBS" + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 +$as_echo_n "checking whether a program can dlopen itself... " >&6; } +if ${lt_cv_dlopen_self+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test yes = "$cross_compiling"; then : + lt_cv_dlopen_self=cross +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext <<_LT_EOF +#line $LINENO "configure" +#include "confdefs.h" + +#if HAVE_DLFCN_H +#include +#endif + +#include + +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif + +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif + +/* When -fvisibility=hidden is used, assume the code has been annotated + correspondingly for the symbols needed. */ +#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) +int fnord () __attribute__((visibility("default"))); +#endif + +int fnord () { return 42; } +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; + + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else + { + if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + else puts (dlerror ()); + } + /* dlclose (self); */ + } + else + puts (dlerror ()); + + return status; +} +_LT_EOF + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then + (./conftest; exit; ) >&5 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; + x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; + x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;; + esac + else : + # compilation failed + lt_cv_dlopen_self=no + fi +fi +rm -fr conftest* + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 +$as_echo "$lt_cv_dlopen_self" >&6; } + + if test yes = "$lt_cv_dlopen_self"; then + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 +$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } +if ${lt_cv_dlopen_self_static+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test yes = "$cross_compiling"; then : + lt_cv_dlopen_self_static=cross +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext <<_LT_EOF +#line $LINENO "configure" +#include "confdefs.h" + +#if HAVE_DLFCN_H +#include +#endif + +#include + +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif + +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif + +/* When -fvisibility=hidden is used, assume the code has been annotated + correspondingly for the symbols needed. */ +#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) +int fnord () __attribute__((visibility("default"))); +#endif + +int fnord () { return 42; } +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; + + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else + { + if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + else puts (dlerror ()); + } + /* dlclose (self); */ + } + else + puts (dlerror ()); + + return status; +} +_LT_EOF + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then + (./conftest; exit; ) >&5 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; + x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; + x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;; + esac + else : + # compilation failed + lt_cv_dlopen_self_static=no + fi +fi +rm -fr conftest* + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 +$as_echo "$lt_cv_dlopen_self_static" >&6; } + fi + + CPPFLAGS=$save_CPPFLAGS + LDFLAGS=$save_LDFLAGS + LIBS=$save_LIBS + ;; + esac + + case $lt_cv_dlopen_self in + yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; + *) enable_dlopen_self=unknown ;; + esac + + case $lt_cv_dlopen_self_static in + yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; + *) enable_dlopen_self_static=unknown ;; + esac +fi + + + + + + + + + + + + + + + + + +striplib= +old_striplib= +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 +$as_echo_n "checking whether stripping libraries is possible... " >&6; } +if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then + test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" + test -z "$striplib" && striplib="$STRIP --strip-unneeded" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +else +# FIXME - insert some real tests, host_os isn't really good enough + case $host_os in + darwin*) + if test -n "$STRIP"; then + striplib="$STRIP -x" + old_striplib="$STRIP -S" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + ;; + esac +fi + + + + + + + + + + + + + # Report what library types will actually be built + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 +$as_echo_n "checking if libtool supports shared libraries... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 +$as_echo "$can_build_shared" >&6; } + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5 +$as_echo_n "checking whether to build shared libraries... " >&6; } + test no = "$can_build_shared" && enable_shared=no + + # On AIX, shared libraries and static libraries use the same namespace, and + # are all built from PIC. + case $host_os in + aix3*) + test yes = "$enable_shared" && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; + + aix[4-9]*) + if test ia64 != "$host_cpu"; then + case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in + yes,aix,yes) ;; # shared object as lib.so file only + yes,svr4,*) ;; # shared object as lib.so archive member only + yes,*) enable_static=no ;; # shared object in lib.a archive as well + esac + fi + ;; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 +$as_echo "$enable_shared" >&6; } + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5 +$as_echo_n "checking whether to build static libraries... " >&6; } + # Make sure either enable_shared or enable_static is yes. + test yes = "$enable_shared" || enable_static=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5 +$as_echo "$enable_static" >&6; } + + + + +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +CC=$lt_save_CC + + if test -n "$CXX" && ( test no != "$CXX" && + ( (test g++ = "$CXX" && `g++ -v >/dev/null 2>&1` ) || + (test g++ != "$CXX"))); then + ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5 +$as_echo_n "checking how to run the C++ preprocessor... " >&6; } +if test -z "$CXXCPP"; then + if ${ac_cv_prog_CXXCPP+:} false; then : + $as_echo_n "(cached) " >&6 +else + # Double quotes because CXXCPP needs to be expanded + for CXXCPP in "$CXX -E" "/lib/cpp" + do + ac_preproc_ok=false +for ac_cxx_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_cxx_try_cpp "$LINENO"; then : + +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_cxx_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + break +fi + + done + ac_cv_prog_CXXCPP=$CXXCPP + +fi + CXXCPP=$ac_cv_prog_CXXCPP +else + ac_cv_prog_CXXCPP=$CXXCPP +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 +$as_echo "$CXXCPP" >&6; } +ac_preproc_ok=false +for ac_cxx_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifdef __STDC__ +# include +#else +# include +#endif + Syntax error +_ACEOF +if ac_fn_cxx_try_cpp "$LINENO"; then : + +else + # Broken: fails on valid input. +continue +fi +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF +if ac_fn_cxx_try_cpp "$LINENO"; then : + # Broken: success on invalid input. +continue +else + # Passes both tests. +ac_preproc_ok=: +break +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : + +else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check +See \`config.log' for more details" "$LINENO" 5; } +fi + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +else + _lt_caught_CXX_error=yes +fi + +ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + +archive_cmds_need_lc_CXX=no +allow_undefined_flag_CXX= +always_export_symbols_CXX=no +archive_expsym_cmds_CXX= +compiler_needs_object_CXX=no +export_dynamic_flag_spec_CXX= +hardcode_direct_CXX=no +hardcode_direct_absolute_CXX=no +hardcode_libdir_flag_spec_CXX= +hardcode_libdir_separator_CXX= +hardcode_minus_L_CXX=no +hardcode_shlibpath_var_CXX=unsupported +hardcode_automatic_CXX=no +inherit_rpath_CXX=no +module_cmds_CXX= +module_expsym_cmds_CXX= +link_all_deplibs_CXX=unknown +old_archive_cmds_CXX=$old_archive_cmds +reload_flag_CXX=$reload_flag +reload_cmds_CXX=$reload_cmds +no_undefined_flag_CXX= +whole_archive_flag_spec_CXX= +enable_shared_with_static_runtimes_CXX=no + +# Source file extension for C++ test sources. +ac_ext=cpp + +# Object file extension for compiled C++ test sources. +objext=o +objext_CXX=$objext + +# No sense in running all these tests if we already determined that +# the CXX compiler isn't working. Some variables (like enable_shared) +# are currently assumed to apply to all compilers on this platform, +# and will be corrupted by setting them based on a non-working compiler. +if test yes != "$_lt_caught_CXX_error"; then + # Code to be used in simple compile tests + lt_simple_compile_test_code="int some_variable = 0;" + + # Code to be used in simple link tests + lt_simple_link_test_code='int main(int, char *[]) { return(0); }' + + # ltmain only uses $CC for tagged configurations so make sure $CC is set. + + + + + + +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} + +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC + + + # save warnings/boilerplate of simple test code + ac_outfile=conftest.$ac_objext +echo "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$RM conftest* + + ac_outfile=conftest.$ac_objext +echo "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$RM -r conftest* + + + # Allow CC to be a program name with arguments. + lt_save_CC=$CC + lt_save_CFLAGS=$CFLAGS + lt_save_LD=$LD + lt_save_GCC=$GCC + GCC=$GXX + lt_save_with_gnu_ld=$with_gnu_ld + lt_save_path_LD=$lt_cv_path_LD + if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then + lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx + else + $as_unset lt_cv_prog_gnu_ld + fi + if test -n "${lt_cv_path_LDCXX+set}"; then + lt_cv_path_LD=$lt_cv_path_LDCXX + else + $as_unset lt_cv_path_LD + fi + test -z "${LDCXX+set}" || LD=$LDCXX + CC=${CXX-"c++"} + CFLAGS=$CXXFLAGS + compiler=$CC + compiler_CXX=$CC + func_cc_basename $compiler +cc_basename=$func_cc_basename_result + + + if test -n "$compiler"; then + # We don't want -fno-exception when compiling C++ code, so set the + # no_builtin_flag separately + if test yes = "$GXX"; then + lt_prog_compiler_no_builtin_flag_CXX=' -fno-builtin' + else + lt_prog_compiler_no_builtin_flag_CXX= + fi + + if test yes = "$GXX"; then + # Set up default GNU C++ configuration + + + +# Check whether --with-gnu-ld was given. +if test "${with_gnu_ld+set}" = set; then : + withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes +else + with_gnu_ld=no +fi + +ac_prog=ld +if test yes = "$GCC"; then + # Check if gcc -print-prog-name=ld gives a path. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 +$as_echo_n "checking for ld used by $CC... " >&6; } + case $host in + *-*-mingw*) + # gcc leaves a trailing carriage return, which upsets mingw + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; + *) + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; + esac + case $ac_prog in + # Accept absolute paths. + [\\/]* | ?:[\\/]*) + re_direlt='/[^/][^/]*/\.\./' + # Canonicalize the pathname of ld + ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` + while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do + ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` + done + test -z "$LD" && LD=$ac_prog + ;; + "") + # If it fails, then pretend we aren't using GCC. + ac_prog=ld + ;; + *) + # If it is relative, then search for the first ld in PATH. + with_gnu_ld=unknown + ;; + esac +elif test yes = "$with_gnu_ld"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 +$as_echo_n "checking for GNU ld... " >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 +$as_echo_n "checking for non-GNU ld... " >&6; } +fi +if ${lt_cv_path_LD+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -z "$LD"; then + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS=$lt_save_ifs + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then + lt_cv_path_LD=$ac_dir/$ac_prog + # Check to see if the program is GNU ld. I'd rather use --version, + # but apparently some variants of GNU ld only accept -v. + # Break only if it was the GNU/non-GNU ld that we prefer. + case `"$lt_cv_path_LD" -v 2>&1 &5 +$as_echo "$LD" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi +test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 +$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } +if ${lt_cv_prog_gnu_ld+:} false; then : + $as_echo_n "(cached) " >&6 +else + # I'd rather use --version here, but apparently some GNU lds only accept -v. +case `$LD -v 2>&1 &5 +$as_echo "$lt_cv_prog_gnu_ld" >&6; } +with_gnu_ld=$lt_cv_prog_gnu_ld + + + + + + + + # Check if GNU C++ uses GNU ld as the underlying linker, since the + # archiving commands below assume that GNU ld is being used. + if test yes = "$with_gnu_ld"; then + archive_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + + hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' + export_dynamic_flag_spec_CXX='$wl--export-dynamic' + + # If archive_cmds runs LD, not CC, wlarc should be empty + # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to + # investigate it a little bit more. (MM) + wlarc='$wl' + + # ancient GNU ld didn't support --whole-archive et. al. + if eval "`$CC -print-prog-name=ld` --help 2>&1" | + $GREP 'no-whole-archive' > /dev/null; then + whole_archive_flag_spec_CXX=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' + else + whole_archive_flag_spec_CXX= + fi + else + with_gnu_ld=no + wlarc= + + # A generic and very simple default shared library creation + # command for GNU C++ for the case where it uses the native + # linker, instead of GNU ld. If possible, this setting should + # overridden to take advantage of the native linker features on + # the platform it is being used on. + archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' + fi + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + + else + GXX=no + with_gnu_ld=no + wlarc= + fi + + # PORTME: fill in a description of your system's C++ link characteristics + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } + ld_shlibs_CXX=yes + case $host_os in + aix3*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + aix[4-9]*) + if test ia64 = "$host_cpu"; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag= + else + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # have runtime linking enabled, and use it for executables. + # For shared libraries, we enable/disable runtime linking + # depending on the kind of the shared library created - + # when "with_aix_soname,aix_use_runtimelinking" is: + # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables + # "aix,yes" lib.so shared, rtl:yes, for executables + # lib.a static archive + # "both,no" lib.so.V(shr.o) shared, rtl:yes + # lib.a(lib.so.V) shared, rtl:no, for executables + # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a(lib.so.V) shared, rtl:no + # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a static archive + case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) + for ld_flag in $LDFLAGS; do + case $ld_flag in + *-brtl*) + aix_use_runtimelinking=yes + break + ;; + esac + done + if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then + # With aix-soname=svr4, we create the lib.so.V shared archives only, + # so we don't have lib.a shared libs to link our executables. + # We have to force runtime linking in this case. + aix_use_runtimelinking=yes + LDFLAGS="$LDFLAGS -Wl,-brtl" + fi + ;; + esac + + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + archive_cmds_CXX='' + hardcode_direct_CXX=yes + hardcode_direct_absolute_CXX=yes + hardcode_libdir_separator_CXX=':' + link_all_deplibs_CXX=yes + file_list_spec_CXX='$wl-f,' + case $with_aix_soname,$aix_use_runtimelinking in + aix,*) ;; # no import file + svr4,* | *,yes) # use import file + # The Import File defines what to hardcode. + hardcode_direct_CXX=no + hardcode_direct_absolute_CXX=no + ;; + esac + + if test yes = "$GXX"; then + case $host_os in aix4.[012]|aix4.[012].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`$CC -print-prog-name=collect2` + if test -f "$collect2name" && + strings "$collect2name" | $GREP resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + hardcode_direct_CXX=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + hardcode_minus_L_CXX=yes + hardcode_libdir_flag_spec_CXX='-L$libdir' + hardcode_libdir_separator_CXX= + fi + esac + shared_flag='-shared' + if test yes = "$aix_use_runtimelinking"; then + shared_flag=$shared_flag' $wl-G' + fi + # Need to ensure runtime linking is disabled for the traditional + # shared library, or the linker may eventually find shared libraries + # /with/ Import File - we do not want to mix them. + shared_flag_aix='-shared' + shared_flag_svr4='-shared $wl-G' + else + # not using gcc + if test ia64 = "$host_cpu"; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test yes = "$aix_use_runtimelinking"; then + shared_flag='$wl-G' + else + shared_flag='$wl-bM:SRE' + fi + shared_flag_aix='$wl-bM:SRE' + shared_flag_svr4='$wl-G' + fi + fi + + export_dynamic_flag_spec_CXX='$wl-bexpall' + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to + # export. + always_export_symbols_CXX=yes + if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + # The "-G" linker flag allows undefined symbols. + no_undefined_flag_CXX='-bernotok' + # Determine the default libpath from the value encoded in an empty + # executable. + if test set = "${lt_cv_aix_libpath+set}"; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath__CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath__CXX"; then + lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath__CXX"; then + lt_cv_aix_libpath__CXX=/usr/lib:/lib + fi + +fi + + aix_libpath=$lt_cv_aix_libpath__CXX +fi + + hardcode_libdir_flag_spec_CXX='$wl-blibpath:$libdir:'"$aix_libpath" + + archive_expsym_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag + else + if test ia64 = "$host_cpu"; then + hardcode_libdir_flag_spec_CXX='$wl-R $libdir:/usr/lib:/lib' + allow_undefined_flag_CXX="-z nodefs" + archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an + # empty executable. + if test set = "${lt_cv_aix_libpath+set}"; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath__CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_link "$LINENO"; then : + + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$lt_cv_aix_libpath__CXX"; then + lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath__CXX"; then + lt_cv_aix_libpath__CXX=/usr/lib:/lib + fi + +fi + + aix_libpath=$lt_cv_aix_libpath__CXX +fi + + hardcode_libdir_flag_spec_CXX='$wl-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + no_undefined_flag_CXX=' $wl-bernotok' + allow_undefined_flag_CXX=' $wl-berok' + if test yes = "$with_gnu_ld"; then + # We only use this code for GNU lds that support --whole-archive. + whole_archive_flag_spec_CXX='$wl--whole-archive$convenience $wl--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + whole_archive_flag_spec_CXX='$convenience' + fi + archive_cmds_need_lc_CXX=yes + archive_expsym_cmds_CXX='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' + # -brtl affects multiple linker settings, -berok does not and is overridden later + compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`' + if test svr4 != "$with_aix_soname"; then + # This is similar to how AIX traditionally builds its shared + # libraries. Need -bnortl late, we may have -brtl in LDFLAGS. + archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' + fi + if test aix != "$with_aix_soname"; then + archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' + else + # used by -dlpreopen to get the symbols + archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$MV $output_objdir/$realname.d/$soname $output_objdir' + fi + archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$RM -r $output_objdir/$realname.d' + fi + fi + ;; + + beos*) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + allow_undefined_flag_CXX=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + else + ld_shlibs_CXX=no + fi + ;; + + chorus*) + case $cc_basename in + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + cygwin* | mingw* | pw32* | cegcc*) + case $GXX,$cc_basename in + ,cl* | no,cl*) + # Native MSVC + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + hardcode_libdir_flag_spec_CXX=' ' + allow_undefined_flag_CXX=unsupported + always_export_symbols_CXX=yes + file_list_spec_CXX='@' + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=.dll + # FIXME: Setting linknames here is a bad hack. + archive_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' + archive_expsym_cmds_CXX='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then + cp "$export_symbols" "$output_objdir/$soname.def"; + echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; + else + $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, CXX)='true' + enable_shared_with_static_runtimes_CXX=yes + # Don't use ranlib + old_postinstall_cmds_CXX='chmod 644 $oldlib' + postlink_cmds_CXX='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile=$lt_outputfile.exe + lt_tool_outputfile=$lt_tool_outputfile.exe + ;; + esac~ + func_to_tool_file "$lt_outputfile"~ + if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # g++ + # _LT_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless, + # as there is no search path for DLLs. + hardcode_libdir_flag_spec_CXX='-L$libdir' + export_dynamic_flag_spec_CXX='$wl--export-all-symbols' + allow_undefined_flag_CXX=unsupported + always_export_symbols_CXX=no + enable_shared_with_static_runtimes_CXX=yes + + if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then + archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file, use it as + # is; otherwise, prepend EXPORTS... + archive_expsym_cmds_CXX='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + ld_shlibs_CXX=no + fi + ;; + esac + ;; + darwin* | rhapsody*) + + + archive_cmds_need_lc_CXX=no + hardcode_direct_CXX=no + hardcode_automatic_CXX=yes + hardcode_shlibpath_var_CXX=unsupported + if test yes = "$lt_cv_ld_force_load"; then + whole_archive_flag_spec_CXX='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' + + else + whole_archive_flag_spec_CXX='' + fi + link_all_deplibs_CXX=yes + allow_undefined_flag_CXX=$_lt_dar_allow_undefined + case $cc_basename in + ifort*|nagfor*) _lt_dar_can_shared=yes ;; + *) _lt_dar_can_shared=$GCC ;; + esac + if test yes = "$_lt_dar_can_shared"; then + output_verbose_link_cmd=func_echo_all + archive_cmds_CXX="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" + module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" + archive_expsym_cmds_CXX="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" + module_expsym_cmds_CXX="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" + if test yes != "$lt_cv_apple_cc_single_mod"; then + archive_cmds_CXX="\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dsymutil" + archive_expsym_cmds_CXX="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil" + fi + + else + ld_shlibs_CXX=no + fi + + ;; + + os2*) + hardcode_libdir_flag_spec_CXX='-L$libdir' + hardcode_minus_L_CXX=yes + allow_undefined_flag_CXX=unsupported + shrext_cmds=.dll + archive_cmds_CXX='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + archive_expsym_cmds_CXX='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + prefix_cmds="$SED"~ + if test EXPORTS = "`$SED 1q $export_symbols`"; then + prefix_cmds="$prefix_cmds -e 1d"; + fi~ + prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ + cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + old_archive_From_new_cmds_CXX='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + enable_shared_with_static_runtimes_CXX=yes + ;; + + dgux*) + case $cc_basename in + ec++*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + ghcx*) + # Green Hills C++ Compiler + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + freebsd2.*) + # C++ shared libraries reported to be fairly broken before + # switch to ELF + ld_shlibs_CXX=no + ;; + + freebsd-elf*) + archive_cmds_need_lc_CXX=no + ;; + + freebsd* | dragonfly*) + # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF + # conventions + ld_shlibs_CXX=yes + ;; + + haiku*) + archive_cmds_CXX='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + link_all_deplibs_CXX=yes + ;; + + hpux9*) + hardcode_libdir_flag_spec_CXX='$wl+b $wl$libdir' + hardcode_libdir_separator_CXX=: + export_dynamic_flag_spec_CXX='$wl-E' + hardcode_direct_CXX=yes + hardcode_minus_L_CXX=yes # Not in the search PATH, + # but as the default + # location of the library. + + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + aCC*) + archive_cmds_CXX='$RM $output_objdir/$soname~$CC -b $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test yes = "$GXX"; then + archive_cmds_CXX='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' + else + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + fi + ;; + esac + ;; + + hpux10*|hpux11*) + if test no = "$with_gnu_ld"; then + hardcode_libdir_flag_spec_CXX='$wl+b $wl$libdir' + hardcode_libdir_separator_CXX=: + + case $host_cpu in + hppa*64*|ia64*) + ;; + *) + export_dynamic_flag_spec_CXX='$wl-E' + ;; + esac + fi + case $host_cpu in + hppa*64*|ia64*) + hardcode_direct_CXX=no + hardcode_shlibpath_var_CXX=no + ;; + *) + hardcode_direct_CXX=yes + hardcode_direct_absolute_CXX=yes + hardcode_minus_L_CXX=yes # Not in the search PATH, + # but as the default + # location of the library. + ;; + esac + + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + aCC*) + case $host_cpu in + hppa*64*) + archive_cmds_CXX='$CC -b $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + ia64*) + archive_cmds_CXX='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + *) + archive_cmds_CXX='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + esac + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test yes = "$GXX"; then + if test no = "$with_gnu_ld"; then + case $host_cpu in + hppa*64*) + archive_cmds_CXX='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + ia64*) + archive_cmds_CXX='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + *) + archive_cmds_CXX='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + esac + fi + else + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + fi + ;; + esac + ;; + + interix[3-9]*) + hardcode_direct_CXX=no + hardcode_shlibpath_var_CXX=no + hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' + export_dynamic_flag_spec_CXX='$wl-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + archive_cmds_CXX='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + archive_expsym_cmds_CXX='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + irix5* | irix6*) + case $cc_basename in + CC*) + # SGI C++ + archive_cmds_CXX='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + + # Archives containing C++ object files must be created using + # "CC -ar", where "CC" is the IRIX C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + old_archive_cmds_CXX='$CC -ar -WR,-u -o $oldlib $oldobjs' + ;; + *) + if test yes = "$GXX"; then + if test no = "$with_gnu_ld"; then + archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + else + archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` -o $lib' + fi + fi + link_all_deplibs_CXX=yes + ;; + esac + hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' + hardcode_libdir_separator_CXX=: + inherit_rpath_CXX=yes + ;; + + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + archive_expsym_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib $wl-retain-symbols-file,$export_symbols; mv \$templib $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + + hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' + export_dynamic_flag_spec_CXX='$wl--export-dynamic' + + # Archives containing C++ object files must be created using + # "CC -Bstatic", where "CC" is the KAI C++ compiler. + old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' + ;; + icpc* | ecpc* ) + # Intel C++ + with_gnu_ld=yes + # version 8.0 and above of icpc choke on multiply defined symbols + # if we add $predep_objects and $postdep_objects, however 7.1 and + # earlier do not add the objects themselves. + case `$CC -V 2>&1` in + *"Version 7."*) + archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + ;; + *) # Version 8.0 or newer + tmp_idyn= + case $host_cpu in + ia64*) tmp_idyn=' -i_dynamic';; + esac + archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + ;; + esac + archive_cmds_need_lc_CXX=no + hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' + export_dynamic_flag_spec_CXX='$wl--export-dynamic' + whole_archive_flag_spec_CXX='$wl--whole-archive$convenience $wl--no-whole-archive' + ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler + case `$CC -V` in + *pgCC\ [1-5].* | *pgcpp\ [1-5].*) + prelink_cmds_CXX='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ + compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' + old_archive_cmds_CXX='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ + $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ + $RANLIB $oldlib' + archive_cmds_CXX='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + ;; + *) # Version 6 and above use weak symbols + archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + ;; + esac + + hardcode_libdir_flag_spec_CXX='$wl--rpath $wl$libdir' + export_dynamic_flag_spec_CXX='$wl--export-dynamic' + whole_archive_flag_spec_CXX='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + ;; + cxx*) + # Compaq C++ + archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib $wl-retain-symbols-file $wl$export_symbols' + + runpath_var=LD_RUN_PATH + hardcode_libdir_flag_spec_CXX='-rpath $libdir' + hardcode_libdir_separator_CXX=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' + ;; + xl* | mpixl* | bgxl*) + # IBM XL 8.0 on PPC, with GNU ld + hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' + export_dynamic_flag_spec_CXX='$wl--export-dynamic' + archive_cmds_CXX='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + if test yes = "$supports_anon_versioning"; then + archive_expsym_cmds_CXX='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' + fi + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + no_undefined_flag_CXX=' -zdefs' + archive_cmds_CXX='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + archive_expsym_cmds_CXX='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file $wl$export_symbols' + hardcode_libdir_flag_spec_CXX='-R$libdir' + whole_archive_flag_spec_CXX='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + compiler_needs_object_CXX=yes + + # Not sure whether something based on + # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 + # would be better. + output_verbose_link_cmd='func_echo_all' + + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' + ;; + esac + ;; + esac + ;; + + lynxos*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + + m88k*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + + mvs*) + case $cc_basename in + cxx*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + netbsd*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + archive_cmds_CXX='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' + wlarc= + hardcode_libdir_flag_spec_CXX='-R$libdir' + hardcode_direct_CXX=yes + hardcode_shlibpath_var_CXX=no + fi + # Workaround some broken pre-1.5 toolchains + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' + ;; + + *nto* | *qnx*) + ld_shlibs_CXX=yes + ;; + + openbsd* | bitrig*) + if test -f /usr/libexec/ld.so; then + hardcode_direct_CXX=yes + hardcode_shlibpath_var_CXX=no + hardcode_direct_absolute_CXX=yes + archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' + hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`"; then + archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file,$export_symbols -o $lib' + export_dynamic_flag_spec_CXX='$wl-E' + whole_archive_flag_spec_CXX=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' + fi + output_verbose_link_cmd=func_echo_all + else + ld_shlibs_CXX=no + fi + ;; + + osf3* | osf4* | osf5*) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + + hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' + hardcode_libdir_separator_CXX=: + + # Archives containing C++ object files must be created using + # the KAI C++ compiler. + case $host in + osf3*) old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' ;; + *) old_archive_cmds_CXX='$CC -o $oldlib $oldobjs' ;; + esac + ;; + RCC*) + # Rational C++ 2.4.1 + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + cxx*) + case $host in + osf3*) + allow_undefined_flag_CXX=' $wl-expect_unresolved $wl\*' + archive_cmds_CXX='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $soname `test -n "$verstring" && func_echo_all "$wl-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' + ;; + *) + allow_undefined_flag_CXX=' -expect_unresolved \*' + archive_cmds_CXX='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + archive_expsym_cmds_CXX='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ + echo "-hidden">> $lib.exp~ + $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname $wl-input $wl$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~ + $RM $lib.exp' + hardcode_libdir_flag_spec_CXX='-rpath $libdir' + ;; + esac + + hardcode_libdir_separator_CXX=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test yes,no = "$GXX,$with_gnu_ld"; then + allow_undefined_flag_CXX=' $wl-expect_unresolved $wl\*' + case $host in + osf3*) + archive_cmds_CXX='$CC -shared -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + ;; + *) + archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + ;; + esac + + hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' + hardcode_libdir_separator_CXX=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + + else + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + fi + ;; + esac + ;; + + psos*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + lcc*) + # Lucid + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + solaris*) + case $cc_basename in + CC* | sunCC*) + # Sun C++ 4.2, 5.x and Centerline C++ + archive_cmds_need_lc_CXX=yes + no_undefined_flag_CXX=' -zdefs' + archive_cmds_CXX='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G$allow_undefined_flag $wl-M $wl$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + hardcode_libdir_flag_spec_CXX='-R$libdir' + hardcode_shlibpath_var_CXX=no + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands '-z linker_flag'. + # Supported since Solaris 2.6 (maybe 2.5.1?) + whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract' + ;; + esac + link_all_deplibs_CXX=yes + + output_verbose_link_cmd='func_echo_all' + + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' + ;; + gcx*) + # Green Hills C++ Compiler + archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' + + # The C++ compiler must be used to create the archive. + old_archive_cmds_CXX='$CC $LDFLAGS -archive -o $oldlib $oldobjs' + ;; + *) + # GNU C++ compiler with Solaris linker + if test yes,no = "$GXX,$with_gnu_ld"; then + no_undefined_flag_CXX=' $wl-z ${wl}defs' + if $CC --version | $GREP -v '^2\.7' > /dev/null; then + archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' + archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -shared $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + else + # g++ 2.7 appears to require '-G' NOT '-shared' on this + # platform. + archive_cmds_CXX='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' + archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + fi + + hardcode_libdir_flag_spec_CXX='$wl-R $wl$libdir' + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + whole_archive_flag_spec_CXX='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' + ;; + esac + fi + ;; + esac + ;; + + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) + no_undefined_flag_CXX='$wl-z,text' + archive_cmds_need_lc_CXX=no + hardcode_shlibpath_var_CXX=no + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + archive_cmds_CXX='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + archive_cmds_CXX='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + sysv5* | sco3.2v5* | sco5v6*) + # Note: We CANNOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + no_undefined_flag_CXX='$wl-z,text' + allow_undefined_flag_CXX='$wl-z,nodefs' + archive_cmds_need_lc_CXX=no + hardcode_shlibpath_var_CXX=no + hardcode_libdir_flag_spec_CXX='$wl-R,$libdir' + hardcode_libdir_separator_CXX=':' + link_all_deplibs_CXX=yes + export_dynamic_flag_spec_CXX='$wl-Bexport' + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + archive_cmds_CXX='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + old_archive_cmds_CXX='$CC -Tprelink_objects $oldobjs~ + '"$old_archive_cmds_CXX" + reload_cmds_CXX='$CC -Tprelink_objects $reload_objs~ + '"$reload_cmds_CXX" + ;; + *) + archive_cmds_CXX='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + + vxworks*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5 +$as_echo "$ld_shlibs_CXX" >&6; } + test no = "$ld_shlibs_CXX" && can_build_shared=no + + GCC_CXX=$GXX + LD_CXX=$LD + + ## CAVEAT EMPTOR: + ## There is no encapsulation within the following macros, do not change + ## the running order or otherwise move them around unless you know exactly + ## what you are doing... + # Dependencies to place before and after the object being linked: +predep_objects_CXX= +postdep_objects_CXX= +predeps_CXX= +postdeps_CXX= +compiler_lib_search_path_CXX= + +cat > conftest.$ac_ext <<_LT_EOF +class Foo +{ +public: + Foo (void) { a = 0; } +private: + int a; +}; +_LT_EOF + + +_lt_libdeps_save_CFLAGS=$CFLAGS +case "$CC $CFLAGS " in #( +*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; +*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; +*\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;; +esac + +if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + # Parse the compiler output and extract the necessary + # objects, libraries and library flags. + + # Sentinel used to keep track of whether or not we are before + # the conftest object file. + pre_test_object_deps_done=no + + for p in `eval "$output_verbose_link_cmd"`; do + case $prev$p in + + -L* | -R* | -l*) + # Some compilers place space between "-{L,R}" and the path. + # Remove the space. + if test x-L = "$p" || + test x-R = "$p"; then + prev=$p + continue + fi + + # Expand the sysroot to ease extracting the directories later. + if test -z "$prev"; then + case $p in + -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; + -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; + -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; + esac + fi + case $p in + =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; + esac + if test no = "$pre_test_object_deps_done"; then + case $prev in + -L | -R) + # Internal compiler library paths should come after those + # provided the user. The postdeps already come after the + # user supplied libs so there is no need to process them. + if test -z "$compiler_lib_search_path_CXX"; then + compiler_lib_search_path_CXX=$prev$p + else + compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} $prev$p" + fi + ;; + # The "-l" case would never come before the object being + # linked, so don't bother handling this case. + esac + else + if test -z "$postdeps_CXX"; then + postdeps_CXX=$prev$p + else + postdeps_CXX="${postdeps_CXX} $prev$p" + fi + fi + prev= + ;; + + *.lto.$objext) ;; # Ignore GCC LTO objects + *.$objext) + # This assumes that the test object file only shows up + # once in the compiler output. + if test "$p" = "conftest.$objext"; then + pre_test_object_deps_done=yes + continue + fi + + if test no = "$pre_test_object_deps_done"; then + if test -z "$predep_objects_CXX"; then + predep_objects_CXX=$p + else + predep_objects_CXX="$predep_objects_CXX $p" + fi + else + if test -z "$postdep_objects_CXX"; then + postdep_objects_CXX=$p + else + postdep_objects_CXX="$postdep_objects_CXX $p" + fi + fi + ;; + + *) ;; # Ignore the rest. + + esac + done + + # Clean up. + rm -f a.out a.exe +else + echo "libtool.m4: error: problem compiling CXX test program" +fi + +$RM -f confest.$objext +CFLAGS=$_lt_libdeps_save_CFLAGS + +# PORTME: override above test on systems where it is broken +case $host_os in +interix[3-9]*) + # Interix 3.5 installs completely hosed .la files for C++, so rather than + # hack all around it, let's just trust "g++" to DTRT. + predep_objects_CXX= + postdep_objects_CXX= + postdeps_CXX= + ;; +esac + + +case " $postdeps_CXX " in +*" -lc "*) archive_cmds_need_lc_CXX=no ;; +esac + compiler_lib_search_dirs_CXX= +if test -n "${compiler_lib_search_path_CXX}"; then + compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | $SED -e 's! -L! !g' -e 's!^ !!'` +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + lt_prog_compiler_wl_CXX= +lt_prog_compiler_pic_CXX= +lt_prog_compiler_static_CXX= + + + # C++ specific cases for pic, static, wl, etc. + if test yes = "$GXX"; then + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='-static' + + case $host_os in + aix*) + # All AIX code is PIC. + if test ia64 = "$host_cpu"; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static_CXX='-Bstatic' + fi + lt_prog_compiler_pic_CXX='-fPIC' + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + lt_prog_compiler_pic_CXX='-fPIC' + ;; + m68k) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the '-m68020' flag to GCC prevents building anything better, + # like '-m68040'. + lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4' + ;; + esac + ;; + + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + mingw* | cygwin* | os2* | pw32* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + lt_prog_compiler_pic_CXX='-DDLL_EXPORT' + case $host_os in + os2*) + lt_prog_compiler_static_CXX='$wl-static' + ;; + esac + ;; + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + lt_prog_compiler_pic_CXX='-fno-common' + ;; + *djgpp*) + # DJGPP does not support shared libraries at all + lt_prog_compiler_pic_CXX= + ;; + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + lt_prog_compiler_static_CXX= + ;; + interix[3-9]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + sysv4*MP*) + if test -d /usr/nec; then + lt_prog_compiler_pic_CXX=-Kconform_pic + fi + ;; + hpux*) + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag + # sets the default TLS model and affects inlining. + case $host_cpu in + hppa*64*) + ;; + *) + lt_prog_compiler_pic_CXX='-fPIC' + ;; + esac + ;; + *qnx* | *nto*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic_CXX='-fPIC -shared' + ;; + *) + lt_prog_compiler_pic_CXX='-fPIC' + ;; + esac + else + case $host_os in + aix[4-9]*) + # All AIX code is PIC. + if test ia64 = "$host_cpu"; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static_CXX='-Bstatic' + else + lt_prog_compiler_static_CXX='-bnso -bI:/lib/syscalls.exp' + fi + ;; + chorus*) + case $cc_basename in + cxch68*) + # Green Hills C++ Compiler + # _LT_TAGVAR(lt_prog_compiler_static, CXX)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" + ;; + esac + ;; + mingw* | cygwin* | os2* | pw32* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + lt_prog_compiler_pic_CXX='-DDLL_EXPORT' + ;; + dgux*) + case $cc_basename in + ec++*) + lt_prog_compiler_pic_CXX='-KPIC' + ;; + ghcx*) + # Green Hills C++ Compiler + lt_prog_compiler_pic_CXX='-pic' + ;; + *) + ;; + esac + ;; + freebsd* | dragonfly*) + # FreeBSD uses GNU C++ + ;; + hpux9* | hpux10* | hpux11*) + case $cc_basename in + CC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='$wl-a ${wl}archive' + if test ia64 != "$host_cpu"; then + lt_prog_compiler_pic_CXX='+Z' + fi + ;; + aCC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='$wl-a ${wl}archive' + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic_CXX='+Z' + ;; + esac + ;; + *) + ;; + esac + ;; + interix*) + # This is c89, which is MS Visual C++ (no shared libs) + # Anyone wants to do a port? + ;; + irix5* | irix6* | nonstopux*) + case $cc_basename in + CC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='-non_shared' + # CC pic flag -KPIC is the default. + ;; + *) + ;; + esac + ;; + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + case $cc_basename in + KCC*) + # KAI C++ Compiler + lt_prog_compiler_wl_CXX='--backend -Wl,' + lt_prog_compiler_pic_CXX='-fPIC' + ;; + ecpc* ) + # old Intel C++ for x86_64, which still supported -KPIC. + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-static' + ;; + icpc* ) + # Intel C++, used to be incompatible with GCC. + # ICC 10 doesn't accept -KPIC any more. + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-fPIC' + lt_prog_compiler_static_CXX='-static' + ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-fpic' + lt_prog_compiler_static_CXX='-Bstatic' + ;; + cxx*) + # Compaq C++ + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + lt_prog_compiler_pic_CXX= + lt_prog_compiler_static_CXX='-non_shared' + ;; + xlc* | xlC* | bgxl[cC]* | mpixl[cC]*) + # IBM XL 8.0, 9.0 on PPC and BlueGene + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-qpic' + lt_prog_compiler_static_CXX='-qstaticlink' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-Bstatic' + lt_prog_compiler_wl_CXX='-Qoption ld ' + ;; + esac + ;; + esac + ;; + lynxos*) + ;; + m88k*) + ;; + mvs*) + case $cc_basename in + cxx*) + lt_prog_compiler_pic_CXX='-W c,exportall' + ;; + *) + ;; + esac + ;; + netbsd* | netbsdelf*-gnu) + ;; + *qnx* | *nto*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic_CXX='-fPIC -shared' + ;; + osf3* | osf4* | osf5*) + case $cc_basename in + KCC*) + lt_prog_compiler_wl_CXX='--backend -Wl,' + ;; + RCC*) + # Rational C++ 2.4.1 + lt_prog_compiler_pic_CXX='-pic' + ;; + cxx*) + # Digital/Compaq C++ + lt_prog_compiler_wl_CXX='-Wl,' + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + lt_prog_compiler_pic_CXX= + lt_prog_compiler_static_CXX='-non_shared' + ;; + *) + ;; + esac + ;; + psos*) + ;; + solaris*) + case $cc_basename in + CC* | sunCC*) + # Sun C++ 4.2, 5.x and Centerline C++ + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-Bstatic' + lt_prog_compiler_wl_CXX='-Qoption ld ' + ;; + gcx*) + # Green Hills C++ Compiler + lt_prog_compiler_pic_CXX='-PIC' + ;; + *) + ;; + esac + ;; + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + lt_prog_compiler_pic_CXX='-pic' + lt_prog_compiler_static_CXX='-Bstatic' + ;; + lcc*) + # Lucid + lt_prog_compiler_pic_CXX='-pic' + ;; + *) + ;; + esac + ;; + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + case $cc_basename in + CC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-Bstatic' + ;; + esac + ;; + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + lt_prog_compiler_pic_CXX='-KPIC' + ;; + *) + ;; + esac + ;; + vxworks*) + ;; + *) + lt_prog_compiler_can_build_shared_CXX=no + ;; + esac + fi + +case $host_os in + # For platforms that do not support PIC, -DPIC is meaningless: + *djgpp*) + lt_prog_compiler_pic_CXX= + ;; + *) + lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC" + ;; +esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; } +if ${lt_cv_prog_compiler_pic_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic_CXX=$lt_prog_compiler_pic_CXX +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_pic_CXX" >&6; } +lt_prog_compiler_pic_CXX=$lt_cv_prog_compiler_pic_CXX + +# +# Check to make sure the PIC flag actually works. +# +if test -n "$lt_prog_compiler_pic_CXX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5 +$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... " >&6; } +if ${lt_cv_prog_compiler_pic_works_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic_works_CXX=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC" ## exclude from sc_useless_quotes_in_assignment + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_pic_works_CXX=yes + fi + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_pic_works_CXX" >&6; } + +if test yes = "$lt_cv_prog_compiler_pic_works_CXX"; then + case $lt_prog_compiler_pic_CXX in + "" | " "*) ;; + *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;; + esac +else + lt_prog_compiler_pic_CXX= + lt_prog_compiler_can_build_shared_CXX=no +fi + +fi + + + + + +# +# Check to make sure the static flag actually works. +# +wl=$lt_prog_compiler_wl_CXX eval lt_tmp_static_flag=\"$lt_prog_compiler_static_CXX\" +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 +$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } +if ${lt_cv_prog_compiler_static_works_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_static_works_CXX=no + save_LDFLAGS=$LDFLAGS + LDFLAGS="$LDFLAGS $lt_tmp_static_flag" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_static_works_CXX=yes + fi + else + lt_cv_prog_compiler_static_works_CXX=yes + fi + fi + $RM -r conftest* + LDFLAGS=$save_LDFLAGS + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_static_works_CXX" >&6; } + +if test yes = "$lt_cv_prog_compiler_static_works_CXX"; then + : +else + lt_prog_compiler_static_CXX= +fi + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o_CXX=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o_CXX=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; } + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if ${lt_cv_prog_compiler_c_o_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o_CXX=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o_CXX=yes + fi + fi + chmod u+w . 2>&5 + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; } + + + + +hard_links=nottested +if test no = "$lt_cv_prog_compiler_c_o_CXX" && test no != "$need_locks"; then + # do not overwrite the value of need_locks provided by the user + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 +$as_echo_n "checking if we can lock with hard links... " >&6; } + hard_links=yes + $RM conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 +$as_echo "$hard_links" >&6; } + if test no = "$hard_links"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5 +$as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;} + need_locks=warn + fi +else + need_locks=no +fi + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } + + export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' + case $host_os in + aix[4-9]*) + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to GNU nm, but means don't demangle to AIX nm. + # Without the "-l" option, or with the "-B" option, AIX nm treats + # weak defined symbols like other global defined symbols, whereas + # GNU nm marks them as "W". + # While the 'weak' keyword is ignored in the Export File, we need + # it in the Import File for the 'aix-soname' feature, so we have + # to replace the "-B" option with "-P" for AIX nm. + if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then + export_symbols_cmds_CXX='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' + else + export_symbols_cmds_CXX='`func_echo_all $NM | $SED -e '\''s/B\([^B]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && (substr(\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' + fi + ;; + pw32*) + export_symbols_cmds_CXX=$ltdll_cmds + ;; + cygwin* | mingw* | cegcc*) + case $cc_basename in + cl*) + exclude_expsyms_CXX='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' + ;; + *) + export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' + exclude_expsyms_CXX='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' + ;; + esac + ;; + linux* | k*bsd*-gnu | gnu*) + link_all_deplibs_CXX=no + ;; + *) + export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + ;; + esac + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5 +$as_echo "$ld_shlibs_CXX" >&6; } +test no = "$ld_shlibs_CXX" && can_build_shared=no + +with_gnu_ld_CXX=$with_gnu_ld + + + + + + +# +# Do we need to explicitly link libc? +# +case "x$archive_cmds_need_lc_CXX" in +x|xyes) + # Assume -lc should be added + archive_cmds_need_lc_CXX=yes + + if test yes,yes = "$GCC,$enable_shared"; then + case $archive_cmds_CXX in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 +$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } +if ${lt_cv_archive_cmds_need_lc_CXX+:} false; then : + $as_echo_n "(cached) " >&6 +else + $RM conftest* + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$lt_prog_compiler_wl_CXX + pic_flag=$lt_prog_compiler_pic_CXX + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$allow_undefined_flag_CXX + allow_undefined_flag_CXX= + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 + (eval $archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + then + lt_cv_archive_cmds_need_lc_CXX=no + else + lt_cv_archive_cmds_need_lc_CXX=yes + fi + allow_undefined_flag_CXX=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc_CXX" >&5 +$as_echo "$lt_cv_archive_cmds_need_lc_CXX" >&6; } + archive_cmds_need_lc_CXX=$lt_cv_archive_cmds_need_lc_CXX + ;; + esac + fi + ;; +esac + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 +$as_echo_n "checking dynamic linker characteristics... " >&6; } + +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=.so +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" +need_lib_prefix=unknown +hardcode_into_libs=no + +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown + + + +case $host_os in +aix3*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname.a' + shlibpath_var=LIBPATH + + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='$libname$release$shared_ext$major' + ;; + +aix[4-9]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test ia64 = "$host_cpu"; then + # AIX 5 supports IA64 + library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line '#! .'. This would cause the generated library to + # depend on '.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[01] | aix4.[01].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then + : + else + can_build_shared=no + fi + ;; + esac + # Using Import Files as archive members, it is possible to support + # filename-based versioning of shared library archives on AIX. While + # this would work for both with and without runtime linking, it will + # prevent static linking of such archives. So we do filename-based + # shared library versioning with .so extension only, which is used + # when both runtime linking and shared linking is enabled. + # Unfortunately, runtime linking may impact performance, so we do + # not want this to be the default eventually. Also, we use the + # versioned .so libs for executables only if there is the -brtl + # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. + # To allow for filename-based versioning support, we need to create + # libNAME.so.V as an archive file, containing: + # *) an Import File, referring to the versioned filename of the + # archive as well as the shared archive member, telling the + # bitwidth (32 or 64) of that shared object, and providing the + # list of exported symbols of that shared object, eventually + # decorated with the 'weak' keyword + # *) the shared object with the F_LOADONLY flag set, to really avoid + # it being seen by the linker. + # At run time we better use the real file rather than another symlink, + # but for link time we create the symlink libNAME.so -> libNAME.so.V + + case $with_aix_soname,$aix_use_runtimelinking in + # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + aix,yes) # traditional libtool + dynamic_linker='AIX unversionable lib.so' + # If using run time linking (on AIX 4.2 or later) use lib.so + # instead of lib.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + ;; + aix,no) # traditional AIX only + dynamic_linker='AIX lib.a(lib.so.V)' + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='$libname$release.a $libname.a' + soname_spec='$libname$release$shared_ext$major' + ;; + svr4,*) # full svr4 only + dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)" + library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' + # We do not specify a path in Import Files, so LIBPATH fires. + shlibpath_overrides_runpath=yes + ;; + *,yes) # both, prefer svr4 + dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)" + library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' + # unpreferred sharedlib libNAME.a needs extra handling + postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' + postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' + # We do not specify a path in Import Files, so LIBPATH fires. + shlibpath_overrides_runpath=yes + ;; + *,no) # both, prefer aix + dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)" + library_names_spec='$libname$release.a $libname.a' + soname_spec='$libname$release$shared_ext$major' + # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling + postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' + postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' + ;; + esac + shlibpath_var=LIBPATH + fi + ;; + +amigaos*) + case $host_cpu in + powerpc) + # Since July 2007 AmigaOS4 officially supports .so libraries. + # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + ;; + m68k) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; $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' + ;; + esac + ;; + +beos*) + library_names_spec='$libname$shared_ext' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; + +bsdi[45]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; + +cygwin* | mingw* | pw32* | cegcc*) + version_type=windows + shrext_cmds=.dll + need_version=no + need_lib_prefix=no + + case $GCC,$cc_basename in + yes,*) + # gcc + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + + case $host_os in + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' + + ;; + mingw* | cegcc*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' + ;; + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' + ;; + esac + dynamic_linker='Win32 ld.exe' + ;; + + *,cl*) + # Native MSVC + libname_spec='$name' + soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' + library_names_spec='$libname.dll.lib' + + case $build_os in + mingw*) + sys_lib_search_path_spec= + lt_save_ifs=$IFS + IFS=';' + for lt_path in $LIB + do + IFS=$lt_save_ifs + # Let DOS variable expansion print the short 8.3 style file name. + lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` + sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" + done + IFS=$lt_save_ifs + # Convert to MSYS style. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` + ;; + cygwin*) + # Convert to unix form, then to dos form, then back to unix form + # but this time dos style (no spaces!) so that the unix form looks + # like /cygdrive/c/PROGRA~1:/cygdr... + sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` + sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` + sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + ;; + *) + sys_lib_search_path_spec=$LIB + if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then + # It is most probably a Windows format PATH. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + # FIXME: find the short name or the path components, as spaces are + # common. (e.g. "Program Files" -> "PROGRA~1") + ;; + esac + + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + dynamic_linker='Win32 link.exe' + ;; + + *) + # Assume MSVC wrapper + library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib' + dynamic_linker='Win32 ld.exe' + ;; + esac + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; + +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' + soname_spec='$libname$release$major$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' + + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; + +dgux*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` + else + case $host_os in + freebsd[23].*) objformat=aout ;; + *) objformat=elf ;; + esac + fi + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + need_version=no + need_lib_prefix=no + ;; + freebsd-*) + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + need_version=yes + ;; + esac + shlibpath_var=LD_LIBRARY_PATH + case $host_os in + freebsd2.*) + shlibpath_overrides_runpath=yes + ;; + freebsd3.[01]* | freebsdelf3.[01]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ + freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + *) # from 4.6 on, and DragonFly + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + esac + ;; + +haiku*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + dynamic_linker="$host_os runtime_loader" + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LIBRARY_PATH + shlibpath_overrides_runpath=no + sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' + hardcode_into_libs=yes + ;; + +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + if test 32 = "$HPUX_IA64_MODE"; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + sys_lib_dlsearch_path_spec=/usr/lib/hpux32 + else + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + sys_lib_dlsearch_path_spec=/usr/lib/hpux64 + fi + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555, ... + postinstall_cmds='chmod 555 $lib' + # or fails outright, so override atomically: + install_override_mode=555 + ;; + +interix[3-9]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; + *) + if test yes = "$lt_cv_prog_gnu_ld"; then + version_type=linux # correct to gnu/linux during the next big refactor + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='$libname$release$shared_ext$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; + esac + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" + sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" + hardcode_into_libs=yes + ;; + +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; + +linux*android*) + version_type=none # Android doesn't support versioned libraries. + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext' + soname_spec='$libname$release$shared_ext' + finish_cmds= + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + dynamic_linker='Android linker' + # Don't embed -rpath directories since the linker doesn't support them. + hardcode_libdir_flag_spec_CXX='-L$libdir' + ;; + +# This must be glibc/ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + + # Some binutils ld are patched to set DT_RUNPATH + if ${lt_cv_shlibpath_overrides_runpath+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_shlibpath_overrides_runpath=no + save_LDFLAGS=$LDFLAGS + save_libdir=$libdir + eval "libdir=/foo; wl=\"$lt_prog_compiler_wl_CXX\"; \ + LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec_CXX\"" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_link "$LINENO"; then : + if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : + lt_cv_shlibpath_overrides_runpath=yes +fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS=$save_LDFLAGS + libdir=$save_libdir + +fi + + shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + # Ideally, we could use ldconfig to report *all* directores which are + # searched for libraries, however this is still not possible. Aside from not + # being certain /sbin/ldconfig is available, command + # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, + # even though it is searched at run-time. Try to do the best guess by + # appending ld.so.conf contents (and includes) to the search path. + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi + + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; + +netbsdelf*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='NetBSD ld.elf_so' + ;; + +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + +newsos6) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +*nto* | *qnx*) + version_type=qnx + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='ldqnx.so' + ;; + +openbsd* | bitrig*) + version_type=sunos + sys_lib_dlsearch_path_spec=/usr/lib + need_lib_prefix=no + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then + need_version=no + else + need_version=yes + fi + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +os2*) + libname_spec='$name' + version_type=windows + shrext_cmds=.dll + need_version=no + need_lib_prefix=no + # OS/2 can only load a DLL with a base name of 8 characters or less. + soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; + v=$($ECHO $release$versuffix | tr -d .-); + n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); + $ECHO $n$v`$shared_ext' + library_names_spec='${libname}_dll.$libext' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=BEGINLIBPATH + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + ;; + +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='$libname$release$shared_ext$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + +rdos*) + dynamic_linker=no + ;; + +solaris*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; + +sunos4*) + version_type=sunos + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test yes = "$with_gnu_ld"; then + need_lib_prefix=no + fi + need_version=yes + ;; + +sysv4 | sysv4.3*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + runpath_var=LD_RUN_PATH + ;; + siemens) + need_lib_prefix=no + ;; + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + ;; + esac + ;; + +sysv4*MP*) + if test -d /usr/nec; then + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' + soname_spec='$libname$shared_ext.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + version_type=sco + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + if test yes = "$with_gnu_ld"; then + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' + else + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' + case $host_os in + sco3.2v5*) + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" + ;; + esac + fi + sys_lib_dlsearch_path_spec='/usr/lib' + ;; + +tpf*) + # TPF is a cross-target only. Preferred cross-host = GNU/Linux. + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +uts4*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +*) + dynamic_linker=no + ;; +esac +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 +$as_echo "$dynamic_linker" >&6; } +test no = "$dynamic_linker" && can_build_shared=no + +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test yes = "$GCC"; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +fi + +if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then + sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec +fi + +if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then + sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec +fi + +# remember unaugmented sys_lib_dlsearch_path content for libtool script decls... +configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec + +# ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code +func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" + +# to be used as default LT_SYS_LIBRARY_PATH value in generated libtool +configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 +$as_echo_n "checking how to hardcode library paths into programs... " >&6; } +hardcode_action_CXX= +if test -n "$hardcode_libdir_flag_spec_CXX" || + test -n "$runpath_var_CXX" || + test yes = "$hardcode_automatic_CXX"; then + + # We can hardcode non-existent directories. + if test no != "$hardcode_direct_CXX" && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, CXX)" && + test no != "$hardcode_minus_L_CXX"; then + # Linking always hardcodes the temporary library directory. + hardcode_action_CXX=relink + else + # We can link without hardcoding, and we can hardcode nonexisting dirs. + hardcode_action_CXX=immediate + fi +else + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + hardcode_action_CXX=unsupported +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_CXX" >&5 +$as_echo "$hardcode_action_CXX" >&6; } + +if test relink = "$hardcode_action_CXX" || + test yes = "$inherit_rpath_CXX"; then + # Fast installation is not supported + enable_fast_install=no +elif test yes = "$shlibpath_overrides_runpath" || + test no = "$enable_shared"; then + # Fast installation is not necessary + enable_fast_install=needless +fi + + + + + + + + fi # test -n "$compiler" + + CC=$lt_save_CC + CFLAGS=$lt_save_CFLAGS + LDCXX=$LD + LD=$lt_save_LD + GCC=$lt_save_GCC + with_gnu_ld=$lt_save_with_gnu_ld + lt_cv_path_LDCXX=$lt_cv_path_LD + lt_cv_path_LD=$lt_save_path_LD + lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld + lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld +fi # test yes != "$_lt_caught_CXX_error" + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + + + + + + + + + + + + + + + ac_config_commands="$ac_config_commands libtool" + + + + +# Only expand once: + + + +# Checks for libraries. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lm" >&5 +$as_echo_n "checking for main in -lm... " >&6; } +if ${ac_cv_lib_m_main+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lm $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + +int +main () +{ +return main (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_m_main=yes +else + ac_cv_lib_m_main=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_main" >&5 +$as_echo "$ac_cv_lib_m_main" >&6; } +if test "x$ac_cv_lib_m_main" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_LIBM 1 +_ACEOF + + LIBS="-lm $LIBS" + +fi + +# FIXME: Replace `main' with a function in `-lrt': +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lrt" >&5 +$as_echo_n "checking for main in -lrt... " >&6; } +if ${ac_cv_lib_rt_main+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lrt $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + +int +main () +{ +return main (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_rt_main=yes +else + ac_cv_lib_rt_main=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_main" >&5 +$as_echo "$ac_cv_lib_rt_main" >&6; } +if test "x$ac_cv_lib_rt_main" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_LIBRT 1 +_ACEOF + + LIBS="-lrt $LIBS" + +fi + + +# Checks for header files. +for ac_header in float.h stdlib.h string.h unistd.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + +# Checks for typedefs, structures, and compiler characteristics. +ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" +if test "x$ac_cv_type_size_t" = xyes; then : + +else + +cat >>confdefs.h <<_ACEOF +#define size_t unsigned int +_ACEOF + +fi + + +# Checks for library functions. +ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" +if test "x$ac_cv_type_pid_t" = xyes; then : + +else + +cat >>confdefs.h <<_ACEOF +#define pid_t int +_ACEOF + +fi + +for ac_header in vfork.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default" +if test "x$ac_cv_header_vfork_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_VFORK_H 1 +_ACEOF + +fi + +done + +for ac_func in fork vfork +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +fi +done + +if test "x$ac_cv_func_fork" = xyes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5 +$as_echo_n "checking for working fork... " >&6; } +if ${ac_cv_func_fork_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ac_cv_func_fork_works=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ + + /* By Ruediger Kuhlmann. */ + return fork () < 0; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_fork_works=yes +else + ac_cv_func_fork_works=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5 +$as_echo "$ac_cv_func_fork_works" >&6; } + +else + ac_cv_func_fork_works=$ac_cv_func_fork +fi +if test "x$ac_cv_func_fork_works" = xcross; then + case $host in + *-*-amigaos* | *-*-msdosdjgpp*) + # Override, as these systems have only a dummy fork() stub + ac_cv_func_fork_works=no + ;; + *) + ac_cv_func_fork_works=yes + ;; + esac + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5 +$as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;} +fi +ac_cv_func_vfork_works=$ac_cv_func_vfork +if test "x$ac_cv_func_vfork" = xyes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5 +$as_echo_n "checking for working vfork... " >&6; } +if ${ac_cv_func_vfork_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + ac_cv_func_vfork_works=cross +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Thanks to Paul Eggert for this test. */ +$ac_includes_default +#include +#ifdef HAVE_VFORK_H +# include +#endif +/* On some sparc systems, changes by the child to local and incoming + argument registers are propagated back to the parent. The compiler + is told about this with #include , but some compilers + (e.g. gcc -O) don't grok . Test for this by using a + static variable whose address is put into a register that is + clobbered by the vfork. */ +static void +#ifdef __cplusplus +sparc_address_test (int arg) +# else +sparc_address_test (arg) int arg; +#endif +{ + static pid_t child; + if (!child) { + child = vfork (); + if (child < 0) { + perror ("vfork"); + _exit(2); + } + if (!child) { + arg = getpid(); + write(-1, "", 0); + _exit (arg); + } + } +} + +int +main () +{ + pid_t parent = getpid (); + pid_t child; + + sparc_address_test (0); + + child = vfork (); + + if (child == 0) { + /* Here is another test for sparc vfork register problems. This + test uses lots of local variables, at least as many local + variables as main has allocated so far including compiler + temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris + 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should + reuse the register of parent for one of the local variables, + since it will think that parent can't possibly be used any more + in this routine. Assigning to the local variable will thus + munge parent in the parent process. */ + pid_t + p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(), + p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid(); + /* Convince the compiler that p..p7 are live; otherwise, it might + use the same hardware register for all 8 local variables. */ + if (p != p1 || p != p2 || p != p3 || p != p4 + || p != p5 || p != p6 || p != p7) + _exit(1); + + /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent + from child file descriptors. If the child closes a descriptor + before it execs or exits, this munges the parent's descriptor + as well. Test for this by closing stdout in the child. */ + _exit(close(fileno(stdout)) != 0); + } else { + int status; + struct stat st; + + while (wait(&status) != child) + ; + return ( + /* Was there some problem with vforking? */ + child < 0 + + /* Did the child fail? (This shouldn't happen.) */ + || status + + /* Did the vfork/compiler bug occur? */ + || parent != getpid() + + /* Did the file descriptor bug occur? */ + || fstat(fileno(stdout), &st) != 0 + ); + } +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_func_vfork_works=yes +else + ac_cv_func_vfork_works=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5 +$as_echo "$ac_cv_func_vfork_works" >&6; } + +fi; +if test "x$ac_cv_func_fork_works" = xcross; then + ac_cv_func_vfork_works=$ac_cv_func_vfork + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5 +$as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;} +fi + +if test "x$ac_cv_func_vfork_works" = xyes; then + +$as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h + +else + +$as_echo "#define vfork fork" >>confdefs.h + +fi +if test "x$ac_cv_func_fork_works" = xyes; then + +$as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h + +fi + +for ac_func in clock_gettime +do : + ac_fn_c_check_func "$LINENO" "clock_gettime" "ac_cv_func_clock_gettime" +if test "x$ac_cv_func_clock_gettime" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_CLOCK_GETTIME 1 +_ACEOF + +fi +done + + +use_double=no +# Check whether --enable-double-precision was given. +if test "${enable_double_precision+set}" = set; then : + enableval=$enable_double_precision; use_double=$enableval +fi + +if test x$use_double = xno +then + CCD_PRECISION=CCD_SINGLE +else + CCD_PRECISION=CCD_DOUBLE +fi + + +ac_config_files="$ac_config_files Makefile src/Makefile src/ccd/precision.h src/testsuites/Makefile src/testsuites/cu/Makefile" + +cat >confcache <<\_ACEOF +# This file is a shell script that caches the results of configure +# tests run on this system so they can be shared between configure +# scripts and configure runs, see configure's option --config-cache. +# It is not useful on other systems. If it contains results you don't +# want to keep, you may remove or edit it. +# +# config.status only pays attention to the cache file if you give it +# the --recheck option to rerun configure. +# +# `ac_cv_env_foo' variables (set or unset) will be overridden when +# loading this file, other *unset* `ac_cv_foo' will be assigned the +# following values. + +_ACEOF + +# The following way of writing the cache mishandles newlines in values, +# but we know of no workaround that is simple, portable, and efficient. +# So, we kill variables containing newlines. +# Ultrix sh set writes to stderr and can't be redirected directly, +# and sets the high bit in the cache file unless we assign to the vars. +( + for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do + eval ac_val=\$$ac_var + case $ac_val in #( + *${as_nl}*) + case $ac_var in #( + *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 +$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; + esac + case $ac_var in #( + _ | IFS | as_nl) ;; #( + BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( + *) { eval $ac_var=; unset $ac_var;} ;; + esac ;; + esac + done + + (set) 2>&1 | + case $as_nl`(ac_space=' '; set) 2>&1` in #( + *${as_nl}ac_space=\ *) + # `set' does not quote correctly, so add quotes: double-quote + # substitution turns \\\\ into \\, and sed turns \\ into \. + sed -n \ + "s/'/'\\\\''/g; + s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" + ;; #( + *) + # `set' quotes correctly as required by POSIX, so do not add quotes. + sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" + ;; + esac | + sort +) | + sed ' + /^ac_cv_env_/b end + t clear + :clear + s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ + t end + s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ + :end' >>confcache +if diff "$cache_file" confcache >/dev/null 2>&1; then :; else + if test -w "$cache_file"; then + if test "x$cache_file" != "x/dev/null"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 +$as_echo "$as_me: updating cache $cache_file" >&6;} + if test ! -f "$cache_file" || test -h "$cache_file"; then + cat confcache >"$cache_file" + else + case $cache_file in #( + */* | ?:*) + mv -f confcache "$cache_file"$$ && + mv -f "$cache_file"$$ "$cache_file" ;; #( + *) + mv -f confcache "$cache_file" ;; + esac + fi + fi + else + { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 +$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} + fi +fi +rm -f confcache + +test "x$prefix" = xNONE && prefix=$ac_default_prefix +# Let make expand exec_prefix. +test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' + +DEFS=-DHAVE_CONFIG_H + +ac_libobjs= +ac_ltlibobjs= +U= +for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue + # 1. Remove the extension, and $U if already installed. + ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' + ac_i=`$as_echo "$ac_i" | sed "$ac_script"` + # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR + # will be set to the directory where LIBOBJS objects are built. + as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" + as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' +done +LIBOBJS=$ac_libobjs + +LTLIBOBJS=$ac_ltlibobjs + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5 +$as_echo_n "checking that generated files are newer than configure... " >&6; } + if test -n "$am_sleep_pid"; then + # Hide warnings about reused PIDs. + wait $am_sleep_pid 2>/dev/null + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5 +$as_echo "done" >&6; } + if test -n "$EXEEXT"; then + am__EXEEXT_TRUE= + am__EXEEXT_FALSE='#' +else + am__EXEEXT_TRUE='#' + am__EXEEXT_FALSE= +fi + +if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then + as_fn_error $? "conditional \"AMDEP\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${am__fastdepCXX_TRUE}" && test -z "${am__fastdepCXX_FALSE}"; then + as_fn_error $? "conditional \"am__fastdepCXX\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then + as_fn_error $? "conditional \"am__fastdepCC\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi + +: "${CONFIG_STATUS=./config.status}" +ac_write_fail=0 +ac_clean_files_save=$ac_clean_files +ac_clean_files="$ac_clean_files $CONFIG_STATUS" +{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 +$as_echo "$as_me: creating $CONFIG_STATUS" >&6;} +as_write_fail=0 +cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 +#! $SHELL +# Generated by $as_me. +# Run this file to recreate the current configuration. +# Compiler output produced by configure, useful for debugging +# configure, is in config.log if it exists. + +debug=false +ac_cs_recheck=false +ac_cs_silent=false + +SHELL=\${CONFIG_SHELL-$SHELL} +export SHELL +_ASEOF +cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 +## -------------------- ## +## M4sh Initialization. ## +## -------------------- ## + +# Be more Bourne compatible +DUALCASE=1; export DUALCASE # for MKS sh +if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : + emulate sh + NULLCMD=: + # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which + # is contrary to our usage. Disable this feature. + alias -g '${1+"$@"}'='"$@"' + setopt NO_GLOB_SUBST +else + case `(set -o) 2>/dev/null` in #( + *posix*) : + set -o posix ;; #( + *) : + ;; +esac +fi + + +as_nl=' +' +export as_nl +# Printing a long string crashes Solaris 7 /usr/bin/printf. +as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo +# Prefer a ksh shell builtin over an external printf program on Solaris, +# but without wasting forks for bash or zsh. +if test -z "$BASH_VERSION$ZSH_VERSION" \ + && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='print -r --' + as_echo_n='print -rn --' +elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='printf %s\n' + as_echo_n='printf %s' +else + if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then + as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' + as_echo_n='/usr/ucb/echo -n' + else + as_echo_body='eval expr "X$1" : "X\\(.*\\)"' + as_echo_n_body='eval + arg=$1; + case $arg in #( + *"$as_nl"*) + expr "X$arg" : "X\\(.*\\)$as_nl"; + arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; + esac; + expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" + ' + export as_echo_n_body + as_echo_n='sh -c $as_echo_n_body as_echo' + fi + export as_echo_body + as_echo='sh -c $as_echo_body as_echo' +fi + +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + PATH_SEPARATOR=: + (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { + (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || + PATH_SEPARATOR=';' + } +fi + + +# IFS +# We need space, tab and new line, in precisely that order. Quoting is +# there to prevent editors from complaining about space-tab. +# (If _AS_PATH_WALK were called with IFS unset, it would disable word +# splitting by setting IFS to empty value.) +IFS=" "" $as_nl" + +# Find who we are. Look in the path if we contain no directory separator. +as_myself= +case $0 in #(( + *[\\/]* ) as_myself=$0 ;; + *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break + done +IFS=$as_save_IFS + + ;; +esac +# We did not find ourselves, most probably we were run as `sh COMMAND' +# in which case we are not to be found in the path. +if test "x$as_myself" = x; then + as_myself=$0 +fi +if test ! -f "$as_myself"; then + $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 + exit 1 +fi + +# Unset variables that we do not need and which cause bugs (e.g. in +# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" +# suppresses any "Segmentation fault" message there. '((' could +# trigger a bug in pdksh 5.2.14. +for as_var in BASH_ENV ENV MAIL MAILPATH +do eval test x\${$as_var+set} = xset \ + && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : +done +PS1='$ ' +PS2='> ' +PS4='+ ' + +# NLS nuisances. +LC_ALL=C +export LC_ALL +LANGUAGE=C +export LANGUAGE + +# CDPATH. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + + +# as_fn_error STATUS ERROR [LINENO LOG_FD] +# ---------------------------------------- +# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are +# provided, also output the error to LOG_FD, referencing LINENO. Then exit the +# script with STATUS, using 1 if that was 0. +as_fn_error () +{ + as_status=$1; test $as_status -eq 0 && as_status=1 + if test "$4"; then + as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 + fi + $as_echo "$as_me: error: $2" >&2 + as_fn_exit $as_status +} # as_fn_error + + +# as_fn_set_status STATUS +# ----------------------- +# Set $? to STATUS, without forking. +as_fn_set_status () +{ + return $1 +} # as_fn_set_status + +# as_fn_exit STATUS +# ----------------- +# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. +as_fn_exit () +{ + set +e + as_fn_set_status $1 + exit $1 +} # as_fn_exit + +# as_fn_unset VAR +# --------------- +# Portably unset VAR. +as_fn_unset () +{ + { eval $1=; unset $1;} +} +as_unset=as_fn_unset +# as_fn_append VAR VALUE +# ---------------------- +# Append the text in VALUE to the end of the definition contained in VAR. Take +# advantage of any shell optimizations that allow amortized linear growth over +# repeated appends, instead of the typical quadratic growth present in naive +# implementations. +if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : + eval 'as_fn_append () + { + eval $1+=\$2 + }' +else + as_fn_append () + { + eval $1=\$$1\$2 + } +fi # as_fn_append + +# as_fn_arith ARG... +# ------------------ +# Perform arithmetic evaluation on the ARGs, and store the result in the +# global $as_val. Take advantage of shells that can avoid forks. The arguments +# must be portable across $(()) and expr. +if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : + eval 'as_fn_arith () + { + as_val=$(( $* )) + }' +else + as_fn_arith () + { + as_val=`expr "$@" || test $? -eq 1` + } +fi # as_fn_arith + + +if expr a : '\(a\)' >/dev/null 2>&1 && + test "X`expr 00001 : '.*\(...\)'`" = X001; then + as_expr=expr +else + as_expr=false +fi + +if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then + as_basename=basename +else + as_basename=false +fi + +if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then + as_dirname=dirname +else + as_dirname=false +fi + +as_me=`$as_basename -- "$0" || +$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ + X"$0" : 'X\(//\)$' \| \ + X"$0" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X/"$0" | + sed '/^.*\/\([^/][^/]*\)\/*$/{ + s//\1/ + q + } + /^X\/\(\/\/\)$/{ + s//\1/ + q + } + /^X\/\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + +# Avoid depending upon Character Ranges. +as_cr_letters='abcdefghijklmnopqrstuvwxyz' +as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' +as_cr_Letters=$as_cr_letters$as_cr_LETTERS +as_cr_digits='0123456789' +as_cr_alnum=$as_cr_Letters$as_cr_digits + +ECHO_C= ECHO_N= ECHO_T= +case `echo -n x` in #((((( +-n*) + case `echo 'xy\c'` in + *c*) ECHO_T=' ';; # ECHO_T is single tab character. + xy) ECHO_C='\c';; + *) echo `echo ksh88 bug on AIX 6.1` > /dev/null + ECHO_T=' ';; + esac;; +*) + ECHO_N='-n';; +esac + +rm -f conf$$ conf$$.exe conf$$.file +if test -d conf$$.dir; then + rm -f conf$$.dir/conf$$.file +else + rm -f conf$$.dir + mkdir conf$$.dir 2>/dev/null +fi +if (echo >conf$$.file) 2>/dev/null; then + if ln -s conf$$.file conf$$ 2>/dev/null; then + as_ln_s='ln -s' + # ... but there are two gotchas: + # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. + # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. + # In both cases, we have to default to `cp -pR'. + ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || + as_ln_s='cp -pR' + elif ln conf$$.file conf$$ 2>/dev/null; then + as_ln_s=ln + else + as_ln_s='cp -pR' + fi +else + as_ln_s='cp -pR' +fi +rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file +rmdir conf$$.dir 2>/dev/null + + +# as_fn_mkdir_p +# ------------- +# Create "$as_dir" as a directory, including parents if necessary. +as_fn_mkdir_p () +{ + + case $as_dir in #( + -*) as_dir=./$as_dir;; + esac + test -d "$as_dir" || eval $as_mkdir_p || { + as_dirs= + while :; do + case $as_dir in #( + *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( + *) as_qdir=$as_dir;; + esac + as_dirs="'$as_qdir' $as_dirs" + as_dir=`$as_dirname -- "$as_dir" || +$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$as_dir" : 'X\(//\)[^/]' \| \ + X"$as_dir" : 'X\(//\)$' \| \ + X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$as_dir" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + test -d "$as_dir" && break + done + test -z "$as_dirs" || eval "mkdir $as_dirs" + } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" + + +} # as_fn_mkdir_p +if mkdir -p . 2>/dev/null; then + as_mkdir_p='mkdir -p "$as_dir"' +else + test -d ./-p && rmdir ./-p + as_mkdir_p=false +fi + + +# as_fn_executable_p FILE +# ----------------------- +# Test if FILE is an executable regular file. +as_fn_executable_p () +{ + test -f "$1" && test -x "$1" +} # as_fn_executable_p +as_test_x='test -x' +as_executable_p=as_fn_executable_p + +# Sed expression to map a string onto a valid CPP name. +as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" + +# Sed expression to map a string onto a valid variable name. +as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" + + +exec 6>&1 +## ----------------------------------- ## +## Main body of $CONFIG_STATUS script. ## +## ----------------------------------- ## +_ASEOF +test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# Save the log message, to keep $0 and so on meaningful, and to +# report actual input values of CONFIG_FILES etc. instead of their +# values after options handling. +ac_log=" +This file was extended by libccd $as_me 1.0, which was +generated by GNU Autoconf 2.69. Invocation command line was + + CONFIG_FILES = $CONFIG_FILES + CONFIG_HEADERS = $CONFIG_HEADERS + CONFIG_LINKS = $CONFIG_LINKS + CONFIG_COMMANDS = $CONFIG_COMMANDS + $ $0 $@ + +on `(hostname || uname -n) 2>/dev/null | sed 1q` +" + +_ACEOF + +case $ac_config_files in *" +"*) set x $ac_config_files; shift; ac_config_files=$*;; +esac + +case $ac_config_headers in *" +"*) set x $ac_config_headers; shift; ac_config_headers=$*;; +esac + + +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +# Files that config.status was made for. +config_files="$ac_config_files" +config_headers="$ac_config_headers" +config_commands="$ac_config_commands" + +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +ac_cs_usage="\ +\`$as_me' instantiates files and other configuration actions +from templates according to the current configuration. Unless the files +and actions are specified as TAGs, all are instantiated by default. + +Usage: $0 [OPTION]... [TAG]... + + -h, --help print this help, then exit + -V, --version print version number and configuration settings, then exit + --config print configuration, then exit + -q, --quiet, --silent + do not print progress messages + -d, --debug don't remove temporary files + --recheck update $as_me by reconfiguring in the same conditions + --file=FILE[:TEMPLATE] + instantiate the configuration file FILE + --header=FILE[:TEMPLATE] + instantiate the configuration header FILE + +Configuration files: +$config_files + +Configuration headers: +$config_headers + +Configuration commands: +$config_commands + +Report bugs to ." + +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" +ac_cs_version="\\ +libccd config.status 1.0 +configured by $0, generated by GNU Autoconf 2.69, + with options \\"\$ac_cs_config\\" + +Copyright (C) 2012 Free Software Foundation, Inc. +This config.status script is free software; the Free Software Foundation +gives unlimited permission to copy, distribute and modify it." + +ac_pwd='$ac_pwd' +srcdir='$srcdir' +INSTALL='$INSTALL' +MKDIR_P='$MKDIR_P' +AWK='$AWK' +test -n "\$AWK" || AWK=awk +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# The default lists apply if the user does not specify any file. +ac_need_defaults=: +while test $# != 0 +do + case $1 in + --*=?*) + ac_option=`expr "X$1" : 'X\([^=]*\)='` + ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` + ac_shift=: + ;; + --*=) + ac_option=`expr "X$1" : 'X\([^=]*\)='` + ac_optarg= + ac_shift=: + ;; + *) + ac_option=$1 + ac_optarg=$2 + ac_shift=shift + ;; + esac + + case $ac_option in + # Handling of the options. + -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) + ac_cs_recheck=: ;; + --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) + $as_echo "$ac_cs_version"; exit ;; + --config | --confi | --conf | --con | --co | --c ) + $as_echo "$ac_cs_config"; exit ;; + --debug | --debu | --deb | --de | --d | -d ) + debug=: ;; + --file | --fil | --fi | --f ) + $ac_shift + case $ac_optarg in + *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; + '') as_fn_error $? "missing file argument" ;; + esac + as_fn_append CONFIG_FILES " '$ac_optarg'" + ac_need_defaults=false;; + --header | --heade | --head | --hea ) + $ac_shift + case $ac_optarg in + *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; + esac + as_fn_append CONFIG_HEADERS " '$ac_optarg'" + ac_need_defaults=false;; + --he | --h) + # Conflict between --help and --header + as_fn_error $? "ambiguous option: \`$1' +Try \`$0 --help' for more information.";; + --help | --hel | -h ) + $as_echo "$ac_cs_usage"; exit ;; + -q | -quiet | --quiet | --quie | --qui | --qu | --q \ + | -silent | --silent | --silen | --sile | --sil | --si | --s) + ac_cs_silent=: ;; + + # This is an error. + -*) as_fn_error $? "unrecognized option: \`$1' +Try \`$0 --help' for more information." ;; + + *) as_fn_append ac_config_targets " $1" + ac_need_defaults=false ;; + + esac + shift +done + +ac_configure_extra_args= + +if $ac_cs_silent; then + exec 6>/dev/null + ac_configure_extra_args="$ac_configure_extra_args --silent" +fi + +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +if \$ac_cs_recheck; then + set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion + shift + \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 + CONFIG_SHELL='$SHELL' + export CONFIG_SHELL + exec "\$@" +fi + +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +exec 5>>config.log +{ + echo + sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX +## Running $as_me. ## +_ASBOX + $as_echo "$ac_log" +} >&5 + +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +# +# INIT-COMMANDS +# +AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" + + +# The HP-UX ksh and POSIX shell print the target directory to stdout +# if CDPATH is set. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + +sed_quote_subst='$sed_quote_subst' +double_quote_subst='$double_quote_subst' +delay_variable_subst='$delay_variable_subst' +enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`' +macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`' +macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`' +enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`' +pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`' +enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`' +shared_archive_member_spec='`$ECHO "$shared_archive_member_spec" | $SED "$delay_single_quote_subst"`' +SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`' +ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`' +PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`' +host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`' +host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`' +host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`' +build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`' +build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`' +build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`' +SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`' +Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`' +GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`' +EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`' +FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`' +LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`' +NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`' +LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`' +max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`' +ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`' +exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`' +lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`' +lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`' +lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`' +lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`' +lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`' +reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`' +reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`' +OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`' +deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`' +file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`' +file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`' +want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`' +DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`' +sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`' +AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`' +AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`' +archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`' +STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`' +RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`' +old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`' +old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`' +old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`' +lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`' +CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`' +CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`' +compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`' +GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_import='`$ECHO "$lt_cv_sys_global_symbol_to_import" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`' +lt_cv_nm_interface='`$ECHO "$lt_cv_nm_interface" | $SED "$delay_single_quote_subst"`' +nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`' +lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`' +lt_cv_truncate_bin='`$ECHO "$lt_cv_truncate_bin" | $SED "$delay_single_quote_subst"`' +objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`' +MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`' +lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`' +need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`' +MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`' +DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`' +NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`' +LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`' +OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`' +OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`' +libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`' +shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`' +extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`' +archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`' +enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`' +export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`' +whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`' +compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`' +old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`' +old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`' +archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`' +archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`' +module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`' +module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`' +with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`' +allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`' +no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`' +hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`' +hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`' +hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`' +hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`' +hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`' +inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`' +link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`' +always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`' +export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`' +exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`' +include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`' +prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`' +postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`' +file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`' +variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`' +need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`' +need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`' +version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`' +runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`' +shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`' +shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`' +libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`' +library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`' +soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`' +install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`' +postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`' +postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`' +finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`' +finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`' +hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`' +sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`' +configure_time_dlsearch_path='`$ECHO "$configure_time_dlsearch_path" | $SED "$delay_single_quote_subst"`' +configure_time_lt_sys_library_path='`$ECHO "$configure_time_lt_sys_library_path" | $SED "$delay_single_quote_subst"`' +hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`' +enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`' +enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`' +enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`' +old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`' +striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`' +compiler_lib_search_dirs='`$ECHO "$compiler_lib_search_dirs" | $SED "$delay_single_quote_subst"`' +predep_objects='`$ECHO "$predep_objects" | $SED "$delay_single_quote_subst"`' +postdep_objects='`$ECHO "$postdep_objects" | $SED "$delay_single_quote_subst"`' +predeps='`$ECHO "$predeps" | $SED "$delay_single_quote_subst"`' +postdeps='`$ECHO "$postdeps" | $SED "$delay_single_quote_subst"`' +compiler_lib_search_path='`$ECHO "$compiler_lib_search_path" | $SED "$delay_single_quote_subst"`' +LD_CXX='`$ECHO "$LD_CXX" | $SED "$delay_single_quote_subst"`' +reload_flag_CXX='`$ECHO "$reload_flag_CXX" | $SED "$delay_single_quote_subst"`' +reload_cmds_CXX='`$ECHO "$reload_cmds_CXX" | $SED "$delay_single_quote_subst"`' +old_archive_cmds_CXX='`$ECHO "$old_archive_cmds_CXX" | $SED "$delay_single_quote_subst"`' +compiler_CXX='`$ECHO "$compiler_CXX" | $SED "$delay_single_quote_subst"`' +GCC_CXX='`$ECHO "$GCC_CXX" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_no_builtin_flag_CXX='`$ECHO "$lt_prog_compiler_no_builtin_flag_CXX" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_pic_CXX='`$ECHO "$lt_prog_compiler_pic_CXX" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_wl_CXX='`$ECHO "$lt_prog_compiler_wl_CXX" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_static_CXX='`$ECHO "$lt_prog_compiler_static_CXX" | $SED "$delay_single_quote_subst"`' +lt_cv_prog_compiler_c_o_CXX='`$ECHO "$lt_cv_prog_compiler_c_o_CXX" | $SED "$delay_single_quote_subst"`' +archive_cmds_need_lc_CXX='`$ECHO "$archive_cmds_need_lc_CXX" | $SED "$delay_single_quote_subst"`' +enable_shared_with_static_runtimes_CXX='`$ECHO "$enable_shared_with_static_runtimes_CXX" | $SED "$delay_single_quote_subst"`' +export_dynamic_flag_spec_CXX='`$ECHO "$export_dynamic_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' +whole_archive_flag_spec_CXX='`$ECHO "$whole_archive_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' +compiler_needs_object_CXX='`$ECHO "$compiler_needs_object_CXX" | $SED "$delay_single_quote_subst"`' +old_archive_from_new_cmds_CXX='`$ECHO "$old_archive_from_new_cmds_CXX" | $SED "$delay_single_quote_subst"`' +old_archive_from_expsyms_cmds_CXX='`$ECHO "$old_archive_from_expsyms_cmds_CXX" | $SED "$delay_single_quote_subst"`' +archive_cmds_CXX='`$ECHO "$archive_cmds_CXX" | $SED "$delay_single_quote_subst"`' +archive_expsym_cmds_CXX='`$ECHO "$archive_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`' +module_cmds_CXX='`$ECHO "$module_cmds_CXX" | $SED "$delay_single_quote_subst"`' +module_expsym_cmds_CXX='`$ECHO "$module_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`' +with_gnu_ld_CXX='`$ECHO "$with_gnu_ld_CXX" | $SED "$delay_single_quote_subst"`' +allow_undefined_flag_CXX='`$ECHO "$allow_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`' +no_undefined_flag_CXX='`$ECHO "$no_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_flag_spec_CXX='`$ECHO "$hardcode_libdir_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_separator_CXX='`$ECHO "$hardcode_libdir_separator_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_direct_CXX='`$ECHO "$hardcode_direct_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_direct_absolute_CXX='`$ECHO "$hardcode_direct_absolute_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_minus_L_CXX='`$ECHO "$hardcode_minus_L_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_shlibpath_var_CXX='`$ECHO "$hardcode_shlibpath_var_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_automatic_CXX='`$ECHO "$hardcode_automatic_CXX" | $SED "$delay_single_quote_subst"`' +inherit_rpath_CXX='`$ECHO "$inherit_rpath_CXX" | $SED "$delay_single_quote_subst"`' +link_all_deplibs_CXX='`$ECHO "$link_all_deplibs_CXX" | $SED "$delay_single_quote_subst"`' +always_export_symbols_CXX='`$ECHO "$always_export_symbols_CXX" | $SED "$delay_single_quote_subst"`' +export_symbols_cmds_CXX='`$ECHO "$export_symbols_cmds_CXX" | $SED "$delay_single_quote_subst"`' +exclude_expsyms_CXX='`$ECHO "$exclude_expsyms_CXX" | $SED "$delay_single_quote_subst"`' +include_expsyms_CXX='`$ECHO "$include_expsyms_CXX" | $SED "$delay_single_quote_subst"`' +prelink_cmds_CXX='`$ECHO "$prelink_cmds_CXX" | $SED "$delay_single_quote_subst"`' +postlink_cmds_CXX='`$ECHO "$postlink_cmds_CXX" | $SED "$delay_single_quote_subst"`' +file_list_spec_CXX='`$ECHO "$file_list_spec_CXX" | $SED "$delay_single_quote_subst"`' +hardcode_action_CXX='`$ECHO "$hardcode_action_CXX" | $SED "$delay_single_quote_subst"`' +compiler_lib_search_dirs_CXX='`$ECHO "$compiler_lib_search_dirs_CXX" | $SED "$delay_single_quote_subst"`' +predep_objects_CXX='`$ECHO "$predep_objects_CXX" | $SED "$delay_single_quote_subst"`' +postdep_objects_CXX='`$ECHO "$postdep_objects_CXX" | $SED "$delay_single_quote_subst"`' +predeps_CXX='`$ECHO "$predeps_CXX" | $SED "$delay_single_quote_subst"`' +postdeps_CXX='`$ECHO "$postdeps_CXX" | $SED "$delay_single_quote_subst"`' +compiler_lib_search_path_CXX='`$ECHO "$compiler_lib_search_path_CXX" | $SED "$delay_single_quote_subst"`' + +LTCC='$LTCC' +LTCFLAGS='$LTCFLAGS' +compiler='$compiler_DEFAULT' + +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +\$1 +_LTECHO_EOF' +} + +# Quote evaled strings. +for var in SHELL \ +ECHO \ +PATH_SEPARATOR \ +SED \ +GREP \ +EGREP \ +FGREP \ +LD \ +NM \ +LN_S \ +lt_SP2NL \ +lt_NL2SP \ +reload_flag \ +OBJDUMP \ +deplibs_check_method \ +file_magic_cmd \ +file_magic_glob \ +want_nocaseglob \ +DLLTOOL \ +sharedlib_from_linklib_cmd \ +AR \ +AR_FLAGS \ +archiver_list_spec \ +STRIP \ +RANLIB \ +CC \ +CFLAGS \ +compiler \ +lt_cv_sys_global_symbol_pipe \ +lt_cv_sys_global_symbol_to_cdecl \ +lt_cv_sys_global_symbol_to_import \ +lt_cv_sys_global_symbol_to_c_name_address \ +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \ +lt_cv_nm_interface \ +nm_file_list_spec \ +lt_cv_truncate_bin \ +lt_prog_compiler_no_builtin_flag \ +lt_prog_compiler_pic \ +lt_prog_compiler_wl \ +lt_prog_compiler_static \ +lt_cv_prog_compiler_c_o \ +need_locks \ +MANIFEST_TOOL \ +DSYMUTIL \ +NMEDIT \ +LIPO \ +OTOOL \ +OTOOL64 \ +shrext_cmds \ +export_dynamic_flag_spec \ +whole_archive_flag_spec \ +compiler_needs_object \ +with_gnu_ld \ +allow_undefined_flag \ +no_undefined_flag \ +hardcode_libdir_flag_spec \ +hardcode_libdir_separator \ +exclude_expsyms \ +include_expsyms \ +file_list_spec \ +variables_saved_for_relink \ +libname_spec \ +library_names_spec \ +soname_spec \ +install_override_mode \ +finish_eval \ +old_striplib \ +striplib \ +compiler_lib_search_dirs \ +predep_objects \ +postdep_objects \ +predeps \ +postdeps \ +compiler_lib_search_path \ +LD_CXX \ +reload_flag_CXX \ +compiler_CXX \ +lt_prog_compiler_no_builtin_flag_CXX \ +lt_prog_compiler_pic_CXX \ +lt_prog_compiler_wl_CXX \ +lt_prog_compiler_static_CXX \ +lt_cv_prog_compiler_c_o_CXX \ +export_dynamic_flag_spec_CXX \ +whole_archive_flag_spec_CXX \ +compiler_needs_object_CXX \ +with_gnu_ld_CXX \ +allow_undefined_flag_CXX \ +no_undefined_flag_CXX \ +hardcode_libdir_flag_spec_CXX \ +hardcode_libdir_separator_CXX \ +exclude_expsyms_CXX \ +include_expsyms_CXX \ +file_list_spec_CXX \ +compiler_lib_search_dirs_CXX \ +predep_objects_CXX \ +postdep_objects_CXX \ +predeps_CXX \ +postdeps_CXX \ +compiler_lib_search_path_CXX; do + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in + *[\\\\\\\`\\"\\\$]*) + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes + ;; + *) + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" + ;; + esac +done + +# Double-quote double-evaled strings. +for var in reload_cmds \ +old_postinstall_cmds \ +old_postuninstall_cmds \ +old_archive_cmds \ +extract_expsyms_cmds \ +old_archive_from_new_cmds \ +old_archive_from_expsyms_cmds \ +archive_cmds \ +archive_expsym_cmds \ +module_cmds \ +module_expsym_cmds \ +export_symbols_cmds \ +prelink_cmds \ +postlink_cmds \ +postinstall_cmds \ +postuninstall_cmds \ +finish_cmds \ +sys_lib_search_path_spec \ +configure_time_dlsearch_path \ +configure_time_lt_sys_library_path \ +reload_cmds_CXX \ +old_archive_cmds_CXX \ +old_archive_from_new_cmds_CXX \ +old_archive_from_expsyms_cmds_CXX \ +archive_cmds_CXX \ +archive_expsym_cmds_CXX \ +module_cmds_CXX \ +module_expsym_cmds_CXX \ +export_symbols_cmds_CXX \ +prelink_cmds_CXX \ +postlink_cmds_CXX; do + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in + *[\\\\\\\`\\"\\\$]*) + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes + ;; + *) + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" + ;; + esac +done + +ac_aux_dir='$ac_aux_dir' + +# See if we are running on zsh, and set the options that allow our +# commands through without removal of \ escapes INIT. +if test -n "\${ZSH_VERSION+set}"; then + setopt NO_GLOB_SUBST +fi + + + PACKAGE='$PACKAGE' + VERSION='$VERSION' + RM='$RM' + ofile='$ofile' + + + + + + +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 + +# Handling of arguments. +for ac_config_target in $ac_config_targets +do + case $ac_config_target in + "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h" ;; + "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; + "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;; + "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; + "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;; + "src/ccd/precision.h") CONFIG_FILES="$CONFIG_FILES src/ccd/precision.h" ;; + "src/testsuites/Makefile") CONFIG_FILES="$CONFIG_FILES src/testsuites/Makefile" ;; + "src/testsuites/cu/Makefile") CONFIG_FILES="$CONFIG_FILES src/testsuites/cu/Makefile" ;; + + *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; + esac +done + + +# If the user did not use the arguments to specify the items to instantiate, +# then the envvar interface is used. Set only those that are not. +# We use the long form for the default assignment because of an extremely +# bizarre bug on SunOS 4.1.3. +if $ac_need_defaults; then + test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files + test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers + test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands +fi + +# Have a temporary directory for convenience. Make it in the build tree +# simply because there is no reason against having it here, and in addition, +# creating and moving files from /tmp can sometimes cause problems. +# Hook for its removal unless debugging. +# Note that there is a small window in which the directory will not be cleaned: +# after its creation but before its name has been assigned to `$tmp'. +$debug || +{ + tmp= ac_tmp= + trap 'exit_status=$? + : "${ac_tmp:=$tmp}" + { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status +' 0 + trap 'as_fn_exit 1' 1 2 13 15 +} +# Create a (secure) tmp directory for tmp files. + +{ + tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && + test -d "$tmp" +} || +{ + tmp=./conf$$-$RANDOM + (umask 077 && mkdir "$tmp") +} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 +ac_tmp=$tmp + +# Set up the scripts for CONFIG_FILES section. +# No need to generate them if there are no CONFIG_FILES. +# This happens for instance with `./config.status config.h'. +if test -n "$CONFIG_FILES"; then + + +ac_cr=`echo X | tr X '\015'` +# On cygwin, bash can eat \r inside `` if the user requested igncr. +# But we know of no other shell where ac_cr would be empty at this +# point, so we can use a bashism as a fallback. +if test "x$ac_cr" = x; then + eval ac_cr=\$\'\\r\' +fi +ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' /dev/null` +if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then + ac_cs_awk_cr='\\r' +else + ac_cs_awk_cr=$ac_cr +fi + +echo 'BEGIN {' >"$ac_tmp/subs1.awk" && +_ACEOF + + +{ + echo "cat >conf$$subs.awk <<_ACEOF" && + echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && + echo "_ACEOF" +} >conf$$subs.sh || + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 +ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` +ac_delim='%!_!# ' +for ac_last_try in false false false false false :; do + . ./conf$$subs.sh || + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 + + ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` + if test $ac_delim_n = $ac_delim_num; then + break + elif $ac_last_try; then + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 + else + ac_delim="$ac_delim!$ac_delim _$ac_delim!! " + fi +done +rm -f conf$$subs.sh + +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && +_ACEOF +sed -n ' +h +s/^/S["/; s/!.*/"]=/ +p +g +s/^[^!]*!// +:repl +t repl +s/'"$ac_delim"'$// +t delim +:nl +h +s/\(.\{148\}\)..*/\1/ +t more1 +s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ +p +n +b repl +:more1 +s/["\\]/\\&/g; s/^/"/; s/$/"\\/ +p +g +s/.\{148\}// +t nl +:delim +h +s/\(.\{148\}\)..*/\1/ +t more2 +s/["\\]/\\&/g; s/^/"/; s/$/"/ +p +b +:more2 +s/["\\]/\\&/g; s/^/"/; s/$/"\\/ +p +g +s/.\{148\}// +t delim +' >$CONFIG_STATUS || ac_write_fail=1 +rm -f conf$$subs.awk +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +_ACAWK +cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && + for (key in S) S_is_set[key] = 1 + FS = "" + +} +{ + line = $ 0 + nfields = split(line, field, "@") + substed = 0 + len = length(field[1]) + for (i = 2; i < nfields; i++) { + key = field[i] + keylen = length(key) + if (S_is_set[key]) { + value = S[key] + line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) + len += length(value) + length(field[++i]) + substed = 1 + } else + len += 1 + keylen + } + + print line +} + +_ACAWK +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then + sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" +else + cat +fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ + || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 +_ACEOF + +# VPATH may cause trouble with some makes, so we remove sole $(srcdir), +# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and +# trailing colons and then remove the whole line if VPATH becomes empty +# (actually we leave an empty line to preserve line numbers). +if test "x$srcdir" = x.; then + ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ +h +s/// +s/^/:/ +s/[ ]*$/:/ +s/:\$(srcdir):/:/g +s/:\${srcdir}:/:/g +s/:@srcdir@:/:/g +s/^:*// +s/:*$// +x +s/\(=[ ]*\).*/\1/ +G +s/\n// +s/^[^=]*=[ ]*$// +}' +fi + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +fi # test -n "$CONFIG_FILES" + +# Set up the scripts for CONFIG_HEADERS section. +# No need to generate them if there are no CONFIG_HEADERS. +# This happens for instance with `./config.status Makefile'. +if test -n "$CONFIG_HEADERS"; then +cat >"$ac_tmp/defines.awk" <<\_ACAWK || +BEGIN { +_ACEOF + +# Transform confdefs.h into an awk script `defines.awk', embedded as +# here-document in config.status, that substitutes the proper values into +# config.h.in to produce config.h. + +# Create a delimiter string that does not exist in confdefs.h, to ease +# handling of long lines. +ac_delim='%!_!# ' +for ac_last_try in false false :; do + ac_tt=`sed -n "/$ac_delim/p" confdefs.h` + if test -z "$ac_tt"; then + break + elif $ac_last_try; then + as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 + else + ac_delim="$ac_delim!$ac_delim _$ac_delim!! " + fi +done + +# For the awk script, D is an array of macro values keyed by name, +# likewise P contains macro parameters if any. Preserve backslash +# newline sequences. + +ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* +sed -n ' +s/.\{148\}/&'"$ac_delim"'/g +t rset +:rset +s/^[ ]*#[ ]*define[ ][ ]*/ / +t def +d +:def +s/\\$// +t bsnl +s/["\\]/\\&/g +s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ +D["\1"]=" \3"/p +s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p +d +:bsnl +s/["\\]/\\&/g +s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ +D["\1"]=" \3\\\\\\n"\\/p +t cont +s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p +t cont +d +:cont +n +s/.\{148\}/&'"$ac_delim"'/g +t clear +:clear +s/\\$// +t bsnlc +s/["\\]/\\&/g; s/^/"/; s/$/"/p +d +:bsnlc +s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p +b cont +' >$CONFIG_STATUS || ac_write_fail=1 + +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 + for (key in D) D_is_set[key] = 1 + FS = "" +} +/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { + line = \$ 0 + split(line, arg, " ") + if (arg[1] == "#") { + defundef = arg[2] + mac1 = arg[3] + } else { + defundef = substr(arg[1], 2) + mac1 = arg[2] + } + split(mac1, mac2, "(") #) + macro = mac2[1] + prefix = substr(line, 1, index(line, defundef) - 1) + if (D_is_set[macro]) { + # Preserve the white space surrounding the "#". + print prefix "define", macro P[macro] D[macro] + next + } else { + # Replace #undef with comments. This is necessary, for example, + # in the case of _POSIX_SOURCE, which is predefined and required + # on some systems where configure will not decide to define it. + if (defundef == "undef") { + print "/*", prefix defundef, macro, "*/" + next + } + } +} +{ print } +_ACAWK +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 + as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 +fi # test -n "$CONFIG_HEADERS" + + +eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" +shift +for ac_tag +do + case $ac_tag in + :[FHLC]) ac_mode=$ac_tag; continue;; + esac + case $ac_mode$ac_tag in + :[FHL]*:*);; + :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; + :[FH]-) ac_tag=-:-;; + :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; + esac + ac_save_IFS=$IFS + IFS=: + set x $ac_tag + IFS=$ac_save_IFS + shift + ac_file=$1 + shift + + case $ac_mode in + :L) ac_source=$1;; + :[FH]) + ac_file_inputs= + for ac_f + do + case $ac_f in + -) ac_f="$ac_tmp/stdin";; + *) # Look for the file first in the build tree, then in the source tree + # (if the path is not absolute). The absolute path cannot be DOS-style, + # because $ac_f cannot contain `:'. + test -f "$ac_f" || + case $ac_f in + [\\/$]*) false;; + *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; + esac || + as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; + esac + case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac + as_fn_append ac_file_inputs " '$ac_f'" + done + + # Let's still pretend it is `configure' which instantiates (i.e., don't + # use $as_me), people would be surprised to read: + # /* config.h. Generated by config.status. */ + configure_input='Generated from '` + $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' + `' by configure.' + if test x"$ac_file" != x-; then + configure_input="$ac_file. $configure_input" + { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 +$as_echo "$as_me: creating $ac_file" >&6;} + fi + # Neutralize special characters interpreted by sed in replacement strings. + case $configure_input in #( + *\&* | *\|* | *\\* ) + ac_sed_conf_input=`$as_echo "$configure_input" | + sed 's/[\\\\&|]/\\\\&/g'`;; #( + *) ac_sed_conf_input=$configure_input;; + esac + + case $ac_tag in + *:-:* | *:-) cat >"$ac_tmp/stdin" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; + esac + ;; + esac + + ac_dir=`$as_dirname -- "$ac_file" || +$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$ac_file" : 'X\(//\)[^/]' \| \ + X"$ac_file" : 'X\(//\)$' \| \ + X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$ac_file" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + as_dir="$ac_dir"; as_fn_mkdir_p + ac_builddir=. + +case "$ac_dir" in +.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; +*) + ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` + # A ".." for each directory in $ac_dir_suffix. + ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` + case $ac_top_builddir_sub in + "") ac_top_builddir_sub=. ac_top_build_prefix= ;; + *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; + esac ;; +esac +ac_abs_top_builddir=$ac_pwd +ac_abs_builddir=$ac_pwd$ac_dir_suffix +# for backward compatibility: +ac_top_builddir=$ac_top_build_prefix + +case $srcdir in + .) # We are building in place. + ac_srcdir=. + ac_top_srcdir=$ac_top_builddir_sub + ac_abs_top_srcdir=$ac_pwd ;; + [\\/]* | ?:[\\/]* ) # Absolute name. + ac_srcdir=$srcdir$ac_dir_suffix; + ac_top_srcdir=$srcdir + ac_abs_top_srcdir=$srcdir ;; + *) # Relative name. + ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix + ac_top_srcdir=$ac_top_build_prefix$srcdir + ac_abs_top_srcdir=$ac_pwd/$srcdir ;; +esac +ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix + + + case $ac_mode in + :F) + # + # CONFIG_FILE + # + + case $INSTALL in + [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; + *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; + esac + ac_MKDIR_P=$MKDIR_P + case $MKDIR_P in + [\\/$]* | ?:[\\/]* ) ;; + */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; + esac +_ACEOF + +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# If the template does not know about datarootdir, expand it. +# FIXME: This hack should be removed a few years after 2.60. +ac_datarootdir_hack=; ac_datarootdir_seen= +ac_sed_dataroot=' +/datarootdir/ { + p + q +} +/@datadir@/p +/@docdir@/p +/@infodir@/p +/@localedir@/p +/@mandir@/p' +case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in +*datarootdir*) ac_datarootdir_seen=yes;; +*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 +$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 + ac_datarootdir_hack=' + s&@datadir@&$datadir&g + s&@docdir@&$docdir&g + s&@infodir@&$infodir&g + s&@localedir@&$localedir&g + s&@mandir@&$mandir&g + s&\\\${datarootdir}&$datarootdir&g' ;; +esac +_ACEOF + +# Neutralize VPATH when `$srcdir' = `.'. +# Shell code in configure.ac might set extrasub. +# FIXME: do we really want to maintain this feature? +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +ac_sed_extra="$ac_vpsub +$extrasub +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +:t +/@[a-zA-Z_][a-zA-Z_0-9]*@/!b +s|@configure_input@|$ac_sed_conf_input|;t t +s&@top_builddir@&$ac_top_builddir_sub&;t t +s&@top_build_prefix@&$ac_top_build_prefix&;t t +s&@srcdir@&$ac_srcdir&;t t +s&@abs_srcdir@&$ac_abs_srcdir&;t t +s&@top_srcdir@&$ac_top_srcdir&;t t +s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t +s&@builddir@&$ac_builddir&;t t +s&@abs_builddir@&$ac_abs_builddir&;t t +s&@abs_top_builddir@&$ac_abs_top_builddir&;t t +s&@INSTALL@&$ac_INSTALL&;t t +s&@MKDIR_P@&$ac_MKDIR_P&;t t +$ac_datarootdir_hack +" +eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ + >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + +test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && + { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && + { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ + "$ac_tmp/out"`; test -z "$ac_out"; } && + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' +which seems to be undefined. Please make sure it is defined" >&5 +$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' +which seems to be undefined. Please make sure it is defined" >&2;} + + rm -f "$ac_tmp/stdin" + case $ac_file in + -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; + *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; + esac \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + ;; + :H) + # + # CONFIG_HEADER + # + if test x"$ac_file" != x-; then + { + $as_echo "/* $configure_input */" \ + && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" + } >"$ac_tmp/config.h" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then + { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 +$as_echo "$as_me: $ac_file is unchanged" >&6;} + else + rm -f "$ac_file" + mv "$ac_tmp/config.h" "$ac_file" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + fi + else + $as_echo "/* $configure_input */" \ + && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ + || as_fn_error $? "could not create -" "$LINENO" 5 + fi +# Compute "$ac_file"'s index in $config_headers. +_am_arg="$ac_file" +_am_stamp_count=1 +for _am_header in $config_headers :; do + case $_am_header in + $_am_arg | $_am_arg:* ) + break ;; + * ) + _am_stamp_count=`expr $_am_stamp_count + 1` ;; + esac +done +echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" || +$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$_am_arg" : 'X\(//\)[^/]' \| \ + X"$_am_arg" : 'X\(//\)$' \| \ + X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$_am_arg" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'`/stamp-h$_am_stamp_count + ;; + + :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 +$as_echo "$as_me: executing $ac_file commands" >&6;} + ;; + esac + + + case $ac_file$ac_mode in + "depfiles":C) test x"$AMDEP_TRUE" != x"" || { + # Older Autoconf quotes --file arguments for eval, but not when files + # are listed without --file. Let's play safe and only enable the eval + # if we detect the quoting. + case $CONFIG_FILES in + *\'*) eval set x "$CONFIG_FILES" ;; + *) set x $CONFIG_FILES ;; + esac + shift + for mf + do + # Strip MF so we end up with the name of the file. + mf=`echo "$mf" | sed -e 's/:.*$//'` + # Check whether this is an Automake generated Makefile or not. + # We used to match only the files named 'Makefile.in', but + # some people rename them; so instead we look at the file content. + # Grep'ing the first line is not enough: some people post-process + # each Makefile.in and add a new line on top of each file to say so. + # Grep'ing the whole file is not good either: AIX grep has a line + # limit of 2048, but all sed's we know have understand at least 4000. + if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then + dirpart=`$as_dirname -- "$mf" || +$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$mf" : 'X\(//\)[^/]' \| \ + X"$mf" : 'X\(//\)$' \| \ + X"$mf" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$mf" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + else + continue + fi + # Extract the definition of DEPDIR, am__include, and am__quote + # from the Makefile without running 'make'. + DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` + test -z "$DEPDIR" && continue + am__include=`sed -n 's/^am__include = //p' < "$mf"` + test -z "$am__include" && continue + am__quote=`sed -n 's/^am__quote = //p' < "$mf"` + # Find all dependency output files, they are included files with + # $(DEPDIR) in their names. We invoke sed twice because it is the + # simplest approach to changing $(DEPDIR) to its actual value in the + # expansion. + for file in `sed -n " + s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ + sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do + # Make sure the directory exists. + test -f "$dirpart/$file" && continue + fdir=`$as_dirname -- "$file" || +$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$file" : 'X\(//\)[^/]' \| \ + X"$file" : 'X\(//\)$' \| \ + X"$file" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$file" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + as_dir=$dirpart/$fdir; as_fn_mkdir_p + # echo "creating $dirpart/$file" + echo '# dummy' > "$dirpart/$file" + done + done +} + ;; + "libtool":C) + + # See if we are running on zsh, and set the options that allow our + # commands through without removal of \ escapes. + if test -n "${ZSH_VERSION+set}"; then + setopt NO_GLOB_SUBST + fi + + cfgfile=${ofile}T + trap "$RM \"$cfgfile\"; exit 1" 1 2 15 + $RM "$cfgfile" + + cat <<_LT_EOF >> "$cfgfile" +#! $SHELL +# Generated automatically by $as_me ($PACKAGE) $VERSION +# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +# NOTE: Changes made to this file will be lost: look at ltmain.sh. + +# Provide generalized library-building support services. +# Written by Gordon Matzigkeit, 1996 + +# Copyright (C) 2014 Free Software Foundation, Inc. +# This is free software; see the source for copying conditions. There is NO +# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + +# GNU Libtool is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of of the License, or +# (at your option) any later version. +# +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program or library that is built +# using GNU Libtool, you may include this file under the same +# distribution terms that you use for the rest of that program. +# +# GNU Libtool is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + + +# The names of the tagged configurations supported by this script. +available_tags='CXX ' + +# Configured defaults for sys_lib_dlsearch_path munging. +: \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"} + +# ### BEGIN LIBTOOL CONFIG + +# Whether or not to build shared libraries. +build_libtool_libs=$enable_shared + +# Which release of libtool.m4 was used? +macro_version=$macro_version +macro_revision=$macro_revision + +# Whether or not to build static libraries. +build_old_libs=$enable_static + +# What type of objects to build. +pic_mode=$pic_mode + +# Whether or not to optimize for fast installation. +fast_install=$enable_fast_install + +# Shared archive member basename,for filename based shared library versioning on AIX. +shared_archive_member_spec=$shared_archive_member_spec + +# Shell to use when invoking shell scripts. +SHELL=$lt_SHELL + +# An echo program that protects backslashes. +ECHO=$lt_ECHO + +# The PATH separator for the build system. +PATH_SEPARATOR=$lt_PATH_SEPARATOR + +# The host system. +host_alias=$host_alias +host=$host +host_os=$host_os + +# The build system. +build_alias=$build_alias +build=$build +build_os=$build_os + +# A sed program that does not truncate output. +SED=$lt_SED + +# Sed that helps us avoid accidentally triggering echo(1) options like -n. +Xsed="\$SED -e 1s/^X//" + +# A grep program that handles long lines. +GREP=$lt_GREP + +# An ERE matcher. +EGREP=$lt_EGREP + +# A literal string matcher. +FGREP=$lt_FGREP + +# A BSD- or MS-compatible name lister. +NM=$lt_NM + +# Whether we need soft or hard links. +LN_S=$lt_LN_S + +# What is the maximum length of a command? +max_cmd_len=$max_cmd_len + +# Object file suffix (normally "o"). +objext=$ac_objext + +# Executable file suffix (normally ""). +exeext=$exeext + +# whether the shell understands "unset". +lt_unset=$lt_unset + +# turn spaces into newlines. +SP2NL=$lt_lt_SP2NL + +# turn newlines into spaces. +NL2SP=$lt_lt_NL2SP + +# convert \$build file names to \$host format. +to_host_file_cmd=$lt_cv_to_host_file_cmd + +# convert \$build files to toolchain format. +to_tool_file_cmd=$lt_cv_to_tool_file_cmd + +# An object symbol dumper. +OBJDUMP=$lt_OBJDUMP + +# Method to check whether dependent libraries are shared objects. +deplibs_check_method=$lt_deplibs_check_method + +# Command to use when deplibs_check_method = "file_magic". +file_magic_cmd=$lt_file_magic_cmd + +# How to find potential files when deplibs_check_method = "file_magic". +file_magic_glob=$lt_file_magic_glob + +# Find potential files using nocaseglob when deplibs_check_method = "file_magic". +want_nocaseglob=$lt_want_nocaseglob + +# DLL creation program. +DLLTOOL=$lt_DLLTOOL + +# Command to associate shared and link libraries. +sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd + +# The archiver. +AR=$lt_AR + +# Flags to create an archive. +AR_FLAGS=$lt_AR_FLAGS + +# How to feed a file listing to the archiver. +archiver_list_spec=$lt_archiver_list_spec + +# A symbol stripping program. +STRIP=$lt_STRIP + +# Commands used to install an old-style archive. +RANLIB=$lt_RANLIB +old_postinstall_cmds=$lt_old_postinstall_cmds +old_postuninstall_cmds=$lt_old_postuninstall_cmds + +# Whether to use a lock for old archive extraction. +lock_old_archive_extraction=$lock_old_archive_extraction + +# A C compiler. +LTCC=$lt_CC + +# LTCC compiler flags. +LTCFLAGS=$lt_CFLAGS + +# Take the output of nm and produce a listing of raw symbols and C names. +global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe + +# Transform the output of nm in a proper C declaration. +global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl + +# Transform the output of nm into a list of symbols to manually relocate. +global_symbol_to_import=$lt_lt_cv_sys_global_symbol_to_import + +# Transform the output of nm in a C name address pair. +global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address + +# Transform the output of nm in a C name address pair when lib prefix is needed. +global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix + +# The name lister interface. +nm_interface=$lt_lt_cv_nm_interface + +# Specify filename containing input files for \$NM. +nm_file_list_spec=$lt_nm_file_list_spec + +# The root where to search for dependent libraries,and where our libraries should be installed. +lt_sysroot=$lt_sysroot + +# Command to truncate a binary pipe. +lt_truncate_bin=$lt_lt_cv_truncate_bin + +# The name of the directory that contains temporary libtool files. +objdir=$objdir + +# Used to examine libraries when file_magic_cmd begins with "file". +MAGIC_CMD=$MAGIC_CMD + +# Must we lock files when doing compilation? +need_locks=$lt_need_locks + +# Manifest tool. +MANIFEST_TOOL=$lt_MANIFEST_TOOL + +# Tool to manipulate archived DWARF debug symbol files on Mac OS X. +DSYMUTIL=$lt_DSYMUTIL + +# Tool to change global to local symbols on Mac OS X. +NMEDIT=$lt_NMEDIT + +# Tool to manipulate fat objects and archives on Mac OS X. +LIPO=$lt_LIPO + +# ldd/readelf like tool for Mach-O binaries on Mac OS X. +OTOOL=$lt_OTOOL + +# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4. +OTOOL64=$lt_OTOOL64 + +# Old archive suffix (normally "a"). +libext=$libext + +# Shared library suffix (normally ".so"). +shrext_cmds=$lt_shrext_cmds + +# The commands to extract the exported symbol list from a shared archive. +extract_expsyms_cmds=$lt_extract_expsyms_cmds + +# Variables whose values should be saved in libtool wrapper scripts and +# restored at link time. +variables_saved_for_relink=$lt_variables_saved_for_relink + +# Do we need the "lib" prefix for modules? +need_lib_prefix=$need_lib_prefix + +# Do we need a version for libraries? +need_version=$need_version + +# Library versioning type. +version_type=$version_type + +# Shared library runtime path variable. +runpath_var=$runpath_var + +# Shared library path variable. +shlibpath_var=$shlibpath_var + +# Is shlibpath searched before the hard-coded library search path? +shlibpath_overrides_runpath=$shlibpath_overrides_runpath + +# Format of library name prefix. +libname_spec=$lt_libname_spec + +# List of archive names. First name is the real one, the rest are links. +# The last name is the one that the linker finds with -lNAME +library_names_spec=$lt_library_names_spec + +# The coded name of the library, if different from the real name. +soname_spec=$lt_soname_spec + +# Permission mode override for installation of shared libraries. +install_override_mode=$lt_install_override_mode + +# Command to use after installation of a shared archive. +postinstall_cmds=$lt_postinstall_cmds + +# Command to use after uninstallation of a shared archive. +postuninstall_cmds=$lt_postuninstall_cmds + +# Commands used to finish a libtool library installation in a directory. +finish_cmds=$lt_finish_cmds + +# As "finish_cmds", except a single script fragment to be evaled but +# not shown. +finish_eval=$lt_finish_eval + +# Whether we should hardcode library paths into libraries. +hardcode_into_libs=$hardcode_into_libs + +# Compile-time system search path for libraries. +sys_lib_search_path_spec=$lt_sys_lib_search_path_spec + +# Detected run-time system search path for libraries. +sys_lib_dlsearch_path_spec=$lt_configure_time_dlsearch_path + +# Explicit LT_SYS_LIBRARY_PATH set during ./configure time. +configure_time_lt_sys_library_path=$lt_configure_time_lt_sys_library_path + +# Whether dlopen is supported. +dlopen_support=$enable_dlopen + +# Whether dlopen of programs is supported. +dlopen_self=$enable_dlopen_self + +# Whether dlopen of statically linked programs is supported. +dlopen_self_static=$enable_dlopen_self_static + +# Commands to strip libraries. +old_striplib=$lt_old_striplib +striplib=$lt_striplib + + +# The linker used to build libraries. +LD=$lt_LD + +# How to create reloadable object files. +reload_flag=$lt_reload_flag +reload_cmds=$lt_reload_cmds + +# Commands used to build an old-style archive. +old_archive_cmds=$lt_old_archive_cmds + +# A language specific compiler. +CC=$lt_compiler + +# Is the compiler the GNU compiler? +with_gcc=$GCC + +# Compiler flag to turn off builtin functions. +no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag + +# Additional compiler flags for building library objects. +pic_flag=$lt_lt_prog_compiler_pic + +# How to pass a linker flag through the compiler. +wl=$lt_lt_prog_compiler_wl + +# Compiler flag to prevent dynamic linking. +link_static_flag=$lt_lt_prog_compiler_static + +# Does compiler simultaneously support -c and -o options? +compiler_c_o=$lt_lt_cv_prog_compiler_c_o + +# Whether or not to add -lc for building shared libraries. +build_libtool_need_lc=$archive_cmds_need_lc + +# Whether or not to disallow shared libs when runtime libs are static. +allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes + +# Compiler flag to allow reflexive dlopens. +export_dynamic_flag_spec=$lt_export_dynamic_flag_spec + +# Compiler flag to generate shared objects directly from archives. +whole_archive_flag_spec=$lt_whole_archive_flag_spec + +# Whether the compiler copes with passing no objects directly. +compiler_needs_object=$lt_compiler_needs_object + +# Create an old-style archive from a shared archive. +old_archive_from_new_cmds=$lt_old_archive_from_new_cmds + +# Create a temporary old-style archive to link instead of a shared archive. +old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds + +# Commands used to build a shared archive. +archive_cmds=$lt_archive_cmds +archive_expsym_cmds=$lt_archive_expsym_cmds + +# Commands used to build a loadable module if different from building +# a shared archive. +module_cmds=$lt_module_cmds +module_expsym_cmds=$lt_module_expsym_cmds + +# Whether we are building with GNU ld or not. +with_gnu_ld=$lt_with_gnu_ld + +# Flag that allows shared libraries with undefined symbols to be built. +allow_undefined_flag=$lt_allow_undefined_flag + +# Flag that enforces no undefined symbols. +no_undefined_flag=$lt_no_undefined_flag + +# Flag to hardcode \$libdir into a binary during linking. +# This must work even if \$libdir does not exist +hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec + +# Whether we need a single "-rpath" flag with a separated argument. +hardcode_libdir_separator=$lt_hardcode_libdir_separator + +# Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes +# DIR into the resulting binary. +hardcode_direct=$hardcode_direct + +# Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes +# DIR into the resulting binary and the resulting library dependency is +# "absolute",i.e impossible to change by setting \$shlibpath_var if the +# library is relocated. +hardcode_direct_absolute=$hardcode_direct_absolute + +# Set to "yes" if using the -LDIR flag during linking hardcodes DIR +# into the resulting binary. +hardcode_minus_L=$hardcode_minus_L + +# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR +# into the resulting binary. +hardcode_shlibpath_var=$hardcode_shlibpath_var + +# Set to "yes" if building a shared library automatically hardcodes DIR +# into the library and all subsequent libraries and executables linked +# against it. +hardcode_automatic=$hardcode_automatic + +# Set to yes if linker adds runtime paths of dependent libraries +# to runtime path list. +inherit_rpath=$inherit_rpath + +# Whether libtool must link a program against all its dependency libraries. +link_all_deplibs=$link_all_deplibs + +# Set to "yes" if exported symbols are required. +always_export_symbols=$always_export_symbols + +# The commands to list exported symbols. +export_symbols_cmds=$lt_export_symbols_cmds + +# Symbols that should not be listed in the preloaded symbols. +exclude_expsyms=$lt_exclude_expsyms + +# Symbols that must always be exported. +include_expsyms=$lt_include_expsyms + +# Commands necessary for linking programs (against libraries) with templates. +prelink_cmds=$lt_prelink_cmds + +# Commands necessary for finishing linking programs. +postlink_cmds=$lt_postlink_cmds + +# Specify filename containing input files. +file_list_spec=$lt_file_list_spec + +# How to hardcode a shared library path into an executable. +hardcode_action=$hardcode_action + +# The directories searched by this compiler when creating a shared library. +compiler_lib_search_dirs=$lt_compiler_lib_search_dirs + +# Dependencies to place before and after the objects being linked to +# create a shared library. +predep_objects=$lt_predep_objects +postdep_objects=$lt_postdep_objects +predeps=$lt_predeps +postdeps=$lt_postdeps + +# The library search path used internally by the compiler when linking +# a shared library. +compiler_lib_search_path=$lt_compiler_lib_search_path + +# ### END LIBTOOL CONFIG + +_LT_EOF + + cat <<'_LT_EOF' >> "$cfgfile" + +# ### BEGIN FUNCTIONS SHARED WITH CONFIGURE + +# func_munge_path_list VARIABLE PATH +# ----------------------------------- +# VARIABLE is name of variable containing _space_ separated list of +# directories to be munged by the contents of PATH, which is string +# having a format: +# "DIR[:DIR]:" +# string "DIR[ DIR]" will be prepended to VARIABLE +# ":DIR[:DIR]" +# string "DIR[ DIR]" will be appended to VARIABLE +# "DIRP[:DIRP]::[DIRA:]DIRA" +# string "DIRP[ DIRP]" will be prepended to VARIABLE and string +# "DIRA[ DIRA]" will be appended to VARIABLE +# "DIR[:DIR]" +# VARIABLE will be replaced by "DIR[ DIR]" +func_munge_path_list () +{ + case x$2 in + x) + ;; + *:) + eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\" + ;; + x:*) + eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\" + ;; + *::*) + eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" + eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\" + ;; + *) + eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\" + ;; + esac +} + + +# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. +func_cc_basename () +{ + for cc_temp in $*""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac + done + func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` +} + + +# ### END FUNCTIONS SHARED WITH CONFIGURE + +_LT_EOF + + case $host_os in + aix3*) + cat <<\_LT_EOF >> "$cfgfile" +# AIX sometimes has problems with the GCC collect2 program. For some +# reason, if we set the COLLECT_NAMES environment variable, the problems +# vanish in a puff of smoke. +if test set != "${COLLECT_NAMES+set}"; then + COLLECT_NAMES= + export COLLECT_NAMES +fi +_LT_EOF + ;; + esac + + +ltmain=$ac_aux_dir/ltmain.sh + + + # We use sed instead of cat because bash on DJGPP gets confused if + # if finds mixed CR/LF and LF-only lines. Since sed operates in + # text mode, it properly converts lines to CR/LF. This bash problem + # is reportedly fixed, but why not run on old versions too? + sed '$q' "$ltmain" >> "$cfgfile" \ + || (rm -f "$cfgfile"; exit 1) + + mv -f "$cfgfile" "$ofile" || + (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") + chmod +x "$ofile" + + + cat <<_LT_EOF >> "$ofile" + +# ### BEGIN LIBTOOL TAG CONFIG: CXX + +# The linker used to build libraries. +LD=$lt_LD_CXX + +# How to create reloadable object files. +reload_flag=$lt_reload_flag_CXX +reload_cmds=$lt_reload_cmds_CXX + +# Commands used to build an old-style archive. +old_archive_cmds=$lt_old_archive_cmds_CXX + +# A language specific compiler. +CC=$lt_compiler_CXX + +# Is the compiler the GNU compiler? +with_gcc=$GCC_CXX + +# Compiler flag to turn off builtin functions. +no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX + +# Additional compiler flags for building library objects. +pic_flag=$lt_lt_prog_compiler_pic_CXX + +# How to pass a linker flag through the compiler. +wl=$lt_lt_prog_compiler_wl_CXX + +# Compiler flag to prevent dynamic linking. +link_static_flag=$lt_lt_prog_compiler_static_CXX + +# Does compiler simultaneously support -c and -o options? +compiler_c_o=$lt_lt_cv_prog_compiler_c_o_CXX + +# Whether or not to add -lc for building shared libraries. +build_libtool_need_lc=$archive_cmds_need_lc_CXX + +# Whether or not to disallow shared libs when runtime libs are static. +allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_CXX + +# Compiler flag to allow reflexive dlopens. +export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_CXX + +# Compiler flag to generate shared objects directly from archives. +whole_archive_flag_spec=$lt_whole_archive_flag_spec_CXX + +# Whether the compiler copes with passing no objects directly. +compiler_needs_object=$lt_compiler_needs_object_CXX + +# Create an old-style archive from a shared archive. +old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_CXX + +# Create a temporary old-style archive to link instead of a shared archive. +old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_CXX + +# Commands used to build a shared archive. +archive_cmds=$lt_archive_cmds_CXX +archive_expsym_cmds=$lt_archive_expsym_cmds_CXX + +# Commands used to build a loadable module if different from building +# a shared archive. +module_cmds=$lt_module_cmds_CXX +module_expsym_cmds=$lt_module_expsym_cmds_CXX + +# Whether we are building with GNU ld or not. +with_gnu_ld=$lt_with_gnu_ld_CXX + +# Flag that allows shared libraries with undefined symbols to be built. +allow_undefined_flag=$lt_allow_undefined_flag_CXX + +# Flag that enforces no undefined symbols. +no_undefined_flag=$lt_no_undefined_flag_CXX + +# Flag to hardcode \$libdir into a binary during linking. +# This must work even if \$libdir does not exist +hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_CXX + +# Whether we need a single "-rpath" flag with a separated argument. +hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX + +# Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes +# DIR into the resulting binary. +hardcode_direct=$hardcode_direct_CXX + +# Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes +# DIR into the resulting binary and the resulting library dependency is +# "absolute",i.e impossible to change by setting \$shlibpath_var if the +# library is relocated. +hardcode_direct_absolute=$hardcode_direct_absolute_CXX + +# Set to "yes" if using the -LDIR flag during linking hardcodes DIR +# into the resulting binary. +hardcode_minus_L=$hardcode_minus_L_CXX + +# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR +# into the resulting binary. +hardcode_shlibpath_var=$hardcode_shlibpath_var_CXX + +# Set to "yes" if building a shared library automatically hardcodes DIR +# into the library and all subsequent libraries and executables linked +# against it. +hardcode_automatic=$hardcode_automatic_CXX + +# Set to yes if linker adds runtime paths of dependent libraries +# to runtime path list. +inherit_rpath=$inherit_rpath_CXX + +# Whether libtool must link a program against all its dependency libraries. +link_all_deplibs=$link_all_deplibs_CXX + +# Set to "yes" if exported symbols are required. +always_export_symbols=$always_export_symbols_CXX + +# The commands to list exported symbols. +export_symbols_cmds=$lt_export_symbols_cmds_CXX + +# Symbols that should not be listed in the preloaded symbols. +exclude_expsyms=$lt_exclude_expsyms_CXX + +# Symbols that must always be exported. +include_expsyms=$lt_include_expsyms_CXX + +# Commands necessary for linking programs (against libraries) with templates. +prelink_cmds=$lt_prelink_cmds_CXX + +# Commands necessary for finishing linking programs. +postlink_cmds=$lt_postlink_cmds_CXX + +# Specify filename containing input files. +file_list_spec=$lt_file_list_spec_CXX + +# How to hardcode a shared library path into an executable. +hardcode_action=$hardcode_action_CXX + +# The directories searched by this compiler when creating a shared library. +compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_CXX + +# Dependencies to place before and after the objects being linked to +# create a shared library. +predep_objects=$lt_predep_objects_CXX +postdep_objects=$lt_postdep_objects_CXX +predeps=$lt_predeps_CXX +postdeps=$lt_postdeps_CXX + +# The library search path used internally by the compiler when linking +# a shared library. +compiler_lib_search_path=$lt_compiler_lib_search_path_CXX + +# ### END LIBTOOL TAG CONFIG: CXX +_LT_EOF + + ;; + + esac +done # for ac_tag + + +as_fn_exit 0 +_ACEOF +ac_clean_files=$ac_clean_files_save + +test $ac_write_fail = 0 || + as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 + + +# configure is writing to config.log, and then calls config.status. +# config.status does its own redirection, appending to config.log. +# Unfortunately, on DOS this fails, as config.log is still kept open +# by configure, so config.status won't be able to write to it; its +# output is simply discarded. So we exec the FD to /dev/null, +# effectively closing config.log, so it can be properly (re)opened and +# appended to by config.status. When coming back to configure, we +# need to make the FD available again. +if test "$no_create" != yes; then + ac_cs_success=: + ac_config_status_args= + test "$silent" = yes && + ac_config_status_args="$ac_config_status_args --quiet" + exec 5>/dev/null + $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false + exec 5>>config.log + # Use ||, not &&, to avoid exiting from the if with $? = 1, which + # would make configure fail if this is the last instruction. + $ac_cs_success || as_fn_exit 1 +fi +if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 +$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} +fi + diff --git a/libs/ode-0.16.1/libccd/configure.ac b/libs/ode-0.16.1/libccd/configure.ac new file mode 100644 index 0000000..5a12836 --- /dev/null +++ b/libs/ode-0.16.1/libccd/configure.ac @@ -0,0 +1,50 @@ +# -*- Autoconf -*- +# Process this file with autoconf to produce a configure script. + +#AC_PREREQ([2.65]) +AC_INIT([libccd], [1.0], [danfis@danfis.cz]) +AC_CONFIG_SRCDIR([src/ccd.c]) +AC_CONFIG_HEADERS([src/config.h]) +AM_INIT_AUTOMAKE(foreign) + +# Checks for programs. +AC_PROG_CXX +AC_PROG_CC +AC_PROG_INSTALL +AC_DISABLE_SHARED +LT_INIT + +# Checks for libraries. +AC_CHECK_LIB([m], [main]) +# FIXME: Replace `main' with a function in `-lrt': +AC_CHECK_LIB([rt], [main]) + +# Checks for header files. +AC_CHECK_HEADERS([float.h stdlib.h string.h unistd.h]) + +# Checks for typedefs, structures, and compiler characteristics. +AC_TYPE_SIZE_T + +# Checks for library functions. +AC_FUNC_FORK +AC_CHECK_FUNCS([clock_gettime]) + +use_double=no +AC_ARG_ENABLE(double-precision, + AS_HELP_STRING([--enable-double-precision], + [enable double precision computations instead of single precision]), + [use_double=$enableval]) +if test x$use_double = xno +then + CCD_PRECISION=CCD_SINGLE +else + CCD_PRECISION=CCD_DOUBLE +fi +AC_SUBST(CCD_PRECISION) + +AC_CONFIG_FILES([Makefile + src/Makefile + src/ccd/precision.h + src/testsuites/Makefile + src/testsuites/cu/Makefile]) +AC_OUTPUT diff --git a/libs/ode-0.16.1/libccd/src/Makefile.am b/libs/ode-0.16.1/libccd/src/Makefile.am new file mode 100644 index 0000000..e8655ba --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/Makefile.am @@ -0,0 +1,22 @@ +SUBDIRS = testsuites + +AM_CPPFLAGS = -I$(top_srcdir)/src/custom +AM_CFLAGS = -std=c99 + +noinst_LTLIBRARIES = libccd.la + +libccd_la_SOURCES = alloc.c ccd/alloc.h \ + ccd/compiler.h \ + ccd/dbg.h \ + ccd.c ccd/ccd.h \ + ccd/list.h \ + polytope.c ccd/polytope.h \ + ccd/quat.h custom/ccdcustom/quat.h \ + ccd/simplex.h \ + support.c ccd/support.h \ + vec3.c ccd/vec3.h custom/ccdcustom/vec3.h \ + mpr.c + +nodist_libccd_la_SOURCES = ccd/precision.h + +EXTRA_DIST = ccd/precision.h.in diff --git a/libs/ode-0.16.1/libccd/src/Makefile.in b/libs/ode-0.16.1/libccd/src/Makefile.in new file mode 100644 index 0000000..bab323f --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/Makefile.in @@ -0,0 +1,744 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = src +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +LTLIBRARIES = $(noinst_LTLIBRARIES) +libccd_la_LIBADD = +am_libccd_la_OBJECTS = alloc.lo ccd.lo polytope.lo support.lo vec3.lo \ + mpr.lo +nodist_libccd_la_OBJECTS = +libccd_la_OBJECTS = $(am_libccd_la_OBJECTS) \ + $(nodist_libccd_la_OBJECTS) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +DEFAULT_INCLUDES = -I.@am__isrc@ +depcomp = $(SHELL) $(top_srcdir)/../depcomp +am__depfiles_maybe = depfiles +am__mv = mv -f +COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ + $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CFLAGS) $(CFLAGS) +AM_V_CC = $(am__v_CC_@AM_V@) +am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) +am__v_CC_0 = @echo " CC " $@; +am__v_CC_1 = +CCLD = $(CC) +LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CCLD = $(am__v_CCLD_@AM_V@) +am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) +am__v_CCLD_0 = @echo " CCLD " $@; +am__v_CCLD_1 = +SOURCES = $(libccd_la_SOURCES) $(nodist_libccd_la_SOURCES) +DIST_SOURCES = $(libccd_la_SOURCES) +RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ + ctags-recursive dvi-recursive html-recursive info-recursive \ + install-data-recursive install-dvi-recursive \ + install-exec-recursive install-html-recursive \ + install-info-recursive install-pdf-recursive \ + install-ps-recursive install-recursive installcheck-recursive \ + installdirs-recursive pdf-recursive ps-recursive \ + tags-recursive uninstall-recursive +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ + distclean-recursive maintainer-clean-recursive +am__recursive_targets = \ + $(RECURSIVE_TARGETS) \ + $(RECURSIVE_CLEAN_TARGETS) \ + $(am__extra_recursive_targets) +AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ + distdir +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) \ + $(LISP)config.h.in +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +DIST_SUBDIRS = $(SUBDIRS) +am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/config.h.in \ + $(top_srcdir)/../depcomp +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +am__relativize = \ + dir0=`pwd`; \ + sed_first='s,^\([^/]*\)/.*$$,\1,'; \ + sed_rest='s,^[^/]*/*,,'; \ + sed_last='s,^.*/\([^/]*\)$$,\1,'; \ + sed_butlast='s,/*[^/]*$$,,'; \ + while test -n "$$dir1"; do \ + first=`echo "$$dir1" | sed -e "$$sed_first"`; \ + if test "$$first" != "."; then \ + if test "$$first" = ".."; then \ + dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ + dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ + else \ + first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ + if test "$$first2" = "$$first"; then \ + dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ + else \ + dir2="../$$dir2"; \ + fi; \ + dir0="$$dir0"/"$$first"; \ + fi; \ + fi; \ + dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ + done; \ + reldir="$$dir2" +ACLOCAL = @ACLOCAL@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CCD_PRECISION = @CCD_PRECISION@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +FGREP = @FGREP@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +runstatedir = @runstatedir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +SUBDIRS = testsuites +AM_CPPFLAGS = -I$(top_srcdir)/src/custom +AM_CFLAGS = -std=c99 +noinst_LTLIBRARIES = libccd.la +libccd_la_SOURCES = alloc.c ccd/alloc.h \ + ccd/compiler.h \ + ccd/dbg.h \ + ccd.c ccd/ccd.h \ + ccd/list.h \ + polytope.c ccd/polytope.h \ + ccd/quat.h custom/ccdcustom/quat.h \ + ccd/simplex.h \ + support.c ccd/support.h \ + vec3.c ccd/vec3.h custom/ccdcustom/vec3.h \ + mpr.c + +nodist_libccd_la_SOURCES = ccd/precision.h +EXTRA_DIST = ccd/precision.h.in +all: config.h + $(MAKE) $(AM_MAKEFLAGS) all-recursive + +.SUFFIXES: +.SUFFIXES: .c .lo .o .obj +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign src/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): + +config.h: stamp-h1 + @test -f $@ || rm -f stamp-h1 + @test -f $@ || $(MAKE) $(AM_MAKEFLAGS) stamp-h1 + +stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status + @rm -f stamp-h1 + cd $(top_builddir) && $(SHELL) ./config.status src/config.h +$(srcdir)/config.h.in: $(am__configure_deps) + ($(am__cd) $(top_srcdir) && $(AUTOHEADER)) + rm -f stamp-h1 + touch $@ + +distclean-hdr: + -rm -f config.h stamp-h1 + +clean-noinstLTLIBRARIES: + -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES) + @list='$(noinst_LTLIBRARIES)'; \ + locs=`for p in $$list; do echo $$p; done | \ + sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ + sort -u`; \ + test -z "$$locs" || { \ + echo rm -f $${locs}; \ + rm -f $${locs}; \ + } + +libccd.la: $(libccd_la_OBJECTS) $(libccd_la_DEPENDENCIES) $(EXTRA_libccd_la_DEPENDENCIES) + $(AM_V_CCLD)$(LINK) $(libccd_la_OBJECTS) $(libccd_la_LIBADD) $(LIBS) + +mostlyclean-compile: + -rm -f *.$(OBJEXT) + +distclean-compile: + -rm -f *.tab.c + +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/alloc.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ccd.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mpr.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/polytope.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/support.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vec3.Plo@am__quote@ + +.c.o: +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< + +.c.obj: +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` + +.c.lo: +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +# This directory's subdirectories are mostly independent; you can cd +# into them and run 'make' without going through this Makefile. +# To change the values of 'make' variables: instead of editing Makefiles, +# (1) if the variable is set in 'config.status', edit 'config.status' +# (which will cause the Makefiles to be regenerated when you run 'make'); +# (2) otherwise, pass the desired values on the 'make' command line. +$(am__recursive_targets): + @fail=; \ + if $(am__make_keepgoing); then \ + failcom='fail=yes'; \ + else \ + failcom='exit 1'; \ + fi; \ + dot_seen=no; \ + target=`echo $@ | sed s/-recursive//`; \ + case "$@" in \ + distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ + *) list='$(SUBDIRS)' ;; \ + esac; \ + for subdir in $$list; do \ + echo "Making $$target in $$subdir"; \ + if test "$$subdir" = "."; then \ + dot_seen=yes; \ + local_target="$$target-am"; \ + else \ + local_target="$$target"; \ + fi; \ + ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ + || eval $$failcom; \ + done; \ + if test "$$dot_seen" = "no"; then \ + $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ + fi; test -z "$$fail" + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-recursive +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ + include_option=--etags-include; \ + empty_fix=.; \ + else \ + include_option=--include; \ + empty_fix=; \ + fi; \ + list='$(SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + test ! -f $$subdir/TAGS || \ + set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ + fi; \ + done; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-recursive + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-recursive + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done + @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + $(am__make_dryrun) \ + || test -d "$(distdir)/$$subdir" \ + || $(MKDIR_P) "$(distdir)/$$subdir" \ + || exit 1; \ + dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ + $(am__relativize); \ + new_distdir=$$reldir; \ + dir1=$$subdir; dir2="$(top_distdir)"; \ + $(am__relativize); \ + new_top_distdir=$$reldir; \ + echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ + echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ + ($(am__cd) $$subdir && \ + $(MAKE) $(AM_MAKEFLAGS) \ + top_distdir="$$new_top_distdir" \ + distdir="$$new_distdir" \ + am__remove_distdir=: \ + am__skip_length_check=: \ + am__skip_mode_fix=: \ + distdir) \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-recursive +all-am: Makefile $(LTLIBRARIES) config.h +installdirs: installdirs-recursive +installdirs-am: +install: install-recursive +install-exec: install-exec-recursive +install-data: install-data-recursive +uninstall: uninstall-recursive + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-recursive +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-recursive + +clean-am: clean-generic clean-libtool clean-noinstLTLIBRARIES \ + mostlyclean-am + +distclean: distclean-recursive + -rm -rf ./$(DEPDIR) + -rm -f Makefile +distclean-am: clean-am distclean-compile distclean-generic \ + distclean-hdr distclean-tags + +dvi: dvi-recursive + +dvi-am: + +html: html-recursive + +html-am: + +info: info-recursive + +info-am: + +install-data-am: + +install-dvi: install-dvi-recursive + +install-dvi-am: + +install-exec-am: + +install-html: install-html-recursive + +install-html-am: + +install-info: install-info-recursive + +install-info-am: + +install-man: + +install-pdf: install-pdf-recursive + +install-pdf-am: + +install-ps: install-ps-recursive + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-recursive + -rm -rf ./$(DEPDIR) + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-recursive + +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ + mostlyclean-libtool + +pdf: pdf-recursive + +pdf-am: + +ps: ps-recursive + +ps-am: + +uninstall-am: + +.MAKE: $(am__recursive_targets) all install-am install-strip + +.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \ + check-am clean clean-generic clean-libtool \ + clean-noinstLTLIBRARIES cscopelist-am ctags ctags-am distclean \ + distclean-compile distclean-generic distclean-hdr \ + distclean-libtool distclean-tags distdir dvi dvi-am html \ + html-am info info-am install install-am install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am install-info \ + install-info-am install-man install-pdf install-pdf-am \ + install-ps install-ps-am install-strip installcheck \ + installcheck-am installdirs installdirs-am maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-am uninstall uninstall-am + +.PRECIOUS: Makefile + + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/libs/ode-0.16.1/libccd/src/alloc.c b/libs/ode-0.16.1/libccd/src/alloc.c new file mode 100644 index 0000000..d3fb213 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/alloc.c @@ -0,0 +1,38 @@ +/*** + * libccd + * --------------------------------- + * Copyright (c)2010 Daniel Fiser + * + * + * This file is part of libccd. + * + * Distributed under the OSI-approved BSD License (the "License"); + * see accompanying file BDS-LICENSE for details or see + * . + * + * This software is distributed WITHOUT ANY WARRANTY; without even the + * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the License for more information. + */ + +#include +#include + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + + +void *ccdRealloc(void *ptr, size_t size) +{ + void *ret = realloc(ptr, size); + if (ret == NULL && size != 0){ + fprintf(stderr, "Fatal error: Allocation of memory failed!\n"); + fflush(stderr); + exit(-1); + } + + return ret; +} + + diff --git a/libs/ode-0.16.1/libccd/src/ccd.c b/libs/ode-0.16.1/libccd/src/ccd.c new file mode 100644 index 0000000..5221b8f --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/ccd.c @@ -0,0 +1,955 @@ +/*** + * libccd + * --------------------------------- + * Copyright (c)2010 Daniel Fiser + * + * + * This file is part of libccd. + * + * Distributed under the OSI-approved BSD License (the "License"); + * see accompanying file BDS-LICENSE for details or see + * . + * + * This software is distributed WITHOUT ANY WARRANTY; without even the + * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the License for more information. + */ + +#include +#include +#include +#include +#include +#include +#include +#include + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + + +/** Performs GJK algorithm. Returns 0 if intersection was found and simplex + * is filled with resulting polytope. */ +static int __ccdGJK(const void *obj1, const void *obj2, + const ccd_t *ccd, ccd_simplex_t *simplex); + +/** Performs GJK+EPA algorithm. Returns 0 if intersection was found and + * pt is filled with resulting polytope and nearest with pointer to + * nearest element (vertex, edge, face) of polytope to origin. */ +static int __ccdGJKEPA(const void *obj1, const void *obj2, + const ccd_t *ccd, + ccd_pt_t *pt, ccd_pt_el_t **nearest); + + +/** Returns true if simplex contains origin. + * This function also alteres simplex and dir according to further + * processing of GJK algorithm. */ +static int doSimplex(ccd_simplex_t *simplex, ccd_vec3_t *dir); +static int doSimplex2(ccd_simplex_t *simplex, ccd_vec3_t *dir); +static int doSimplex3(ccd_simplex_t *simplex, ccd_vec3_t *dir); +static int doSimplex4(ccd_simplex_t *simplex, ccd_vec3_t *dir); + +/** d = a x b x c */ +_ccd_inline void tripleCross(const ccd_vec3_t *a, const ccd_vec3_t *b, + const ccd_vec3_t *c, ccd_vec3_t *d); + + +/** Transforms simplex to polytope. It is assumed that simplex has 4 + * vertices. */ +static int simplexToPolytope4(const void *obj1, const void *obj2, + const ccd_t *ccd, + ccd_simplex_t *simplex, + ccd_pt_t *pt, ccd_pt_el_t **nearest); + +/** Transforms simplex to polytope, three vertices required */ +static int simplexToPolytope3(const void *obj1, const void *obj2, + const ccd_t *ccd, + const ccd_simplex_t *simplex, + ccd_pt_t *pt, ccd_pt_el_t **nearest); + +/** Transforms simplex to polytope, two vertices required */ +static int simplexToPolytope2(const void *obj1, const void *obj2, + const ccd_t *ccd, + const ccd_simplex_t *simplex, + ccd_pt_t *pt, ccd_pt_el_t **nearest); + +/** Expands polytope using new vertex v. */ +static void expandPolytope(ccd_pt_t *pt, ccd_pt_el_t *el, + const ccd_support_t *newv); + +/** Finds next support point (at stores it in out argument). + * Returns 0 on success, -1 otherwise */ +static int nextSupport(const void *obj1, const void *obj2, const ccd_t *ccd, + const ccd_pt_el_t *el, + ccd_support_t *out); + + + +void ccdFirstDirDefault(const void *o1, const void *o2, ccd_vec3_t *dir) +{ + ccdVec3Set(dir, CCD_ONE, CCD_ZERO, CCD_ZERO); +} + +int ccdGJKIntersect(const void *obj1, const void *obj2, const ccd_t *ccd) +{ + ccd_simplex_t simplex; + return __ccdGJK(obj1, obj2, ccd, &simplex) == 0; +} + +int ccdGJKSeparate(const void *obj1, const void *obj2, const ccd_t *ccd, + ccd_vec3_t *sep) +{ + ccd_pt_t polytope; + ccd_pt_el_t *nearest; + int ret; + + ccdPtInit(&polytope); + + ret = __ccdGJKEPA(obj1, obj2, ccd, &polytope, &nearest); + + // set separation vector + if (nearest) + ccdVec3Copy(sep, &nearest->witness); + + ccdPtDestroy(&polytope); + + return ret; +} + + +static int penEPAPosCmp(const void *a, const void *b) +{ + ccd_pt_vertex_t *v1, *v2; + v1 = *(ccd_pt_vertex_t **)a; + v2 = *(ccd_pt_vertex_t **)b; + + if (ccdEq(v1->dist, v2->dist)){ + return 0; + }else if (v1->dist < v2->dist){ + return -1; + }else{ + return 1; + } +} + +static void penEPAPos(const ccd_pt_t *pt, const ccd_pt_el_t *nearest, + ccd_vec3_t *pos) +{ + ccd_pt_vertex_t *v; + ccd_pt_vertex_t **vs; + size_t i, len; + ccd_real_t scale; + + // compute median + len = 0; + ccdListForEachEntry(&pt->vertices, v, ccd_pt_vertex_t, list){ + len++; + } + + vs = CCD_ALLOC_ARR(ccd_pt_vertex_t *, len); + i = 0; + ccdListForEachEntry(&pt->vertices, v, ccd_pt_vertex_t, list){ + vs[i++] = v; + } + + qsort(vs, len, sizeof(ccd_pt_vertex_t *), penEPAPosCmp); + + ccdVec3Set(pos, CCD_ZERO, CCD_ZERO, CCD_ZERO); + scale = CCD_ZERO; + if (len % 2 == 1) + len++; + + for (i = 0; i < len / 2; i++){ + ccdVec3Add(pos, &vs[i]->v.v1); + ccdVec3Add(pos, &vs[i]->v.v2); + scale += CCD_REAL(2.); + } + ccdVec3Scale(pos, CCD_ONE / scale); + + free(vs); +} + +int ccdGJKPenetration(const void *obj1, const void *obj2, const ccd_t *ccd, + ccd_real_t *depth, ccd_vec3_t *dir, ccd_vec3_t *pos) +{ + ccd_pt_t polytope; + ccd_pt_el_t *nearest; + int ret; + + ccdPtInit(&polytope); + + ret = __ccdGJKEPA(obj1, obj2, ccd, &polytope, &nearest); + + // set separation vector + if (ret == 0 && nearest){ + // store normalized direction vector + ccdVec3Copy(dir, &nearest->witness); + ret = ccdVec3SafeNormalize(dir); + + if (ret == 0) { + // compute depth of penetration + *depth = CCD_SQRT(nearest->dist); + // compute position + penEPAPos(&polytope, nearest, pos); + } + } + + ccdPtDestroy(&polytope); + + return ret; +} + + + + +static int __ccdGJK(const void *obj1, const void *obj2, + const ccd_t *ccd, ccd_simplex_t *simplex) +{ + unsigned long iterations; + ccd_vec3_t dir; // direction vector + ccd_support_t last; // last support point + int do_simplex_res; + + // initialize simplex struct + ccdSimplexInit(simplex); + + // get first direction + ccd->first_dir(obj1, obj2, &dir); + // get first support point + __ccdSupport(obj1, obj2, &dir, ccd, &last); + // and add this point to simplex as last one + ccdSimplexAdd(simplex, &last); + + // set up direction vector to as (O - last) which is exactly -last + ccdVec3Copy(&dir, &last.v); + ccdVec3Scale(&dir, -CCD_ONE); + + // start iterations + for (iterations = 0UL; iterations < ccd->max_iterations; ++iterations) { + // obtain support point + __ccdSupport(obj1, obj2, &dir, ccd, &last); + + // check if farthest point in Minkowski difference in direction dir + // isn't somewhere before origin (the test on negative dot product) + // - because if it is, objects are not intersecting at all. + if (ccdVec3Dot(&last.v, &dir) < CCD_ZERO){ + return -1; // intersection not found + } + + // add last support vector to simplex + ccdSimplexAdd(simplex, &last); + + // if doSimplex returns 1 if objects intersect, -1 if objects don't + // intersect and 0 if algorithm should continue + do_simplex_res = doSimplex(simplex, &dir); + if (do_simplex_res == 1){ + return 0; // intersection found + }else if (do_simplex_res == -1){ + return -1; // intersection not found + } + + if (ccdIsZero(ccdVec3Len2(&dir))){ + return -1; // intersection not found + } + } + + // intersection wasn't found + return -1; +} + +static int __ccdGJKEPA(const void *obj1, const void *obj2, + const ccd_t *ccd, + ccd_pt_t *polytope, ccd_pt_el_t **nearest) +{ + ccd_simplex_t simplex; + ccd_support_t supp; // support point + int ret, size; + + *nearest = NULL; + + // run GJK and obtain terminal simplex + ret = __ccdGJK(obj1, obj2, ccd, &simplex); + if (ret != 0) + return -1; + + // transform simplex to polytope - simplex won't be used anymore + size = ccdSimplexSize(&simplex); + if (size == 4){ + if (simplexToPolytope4(obj1, obj2, ccd, &simplex, polytope, nearest) != 0){ + return 0;// touch contact + } + }else if (size == 3){ + if (simplexToPolytope3(obj1, obj2, ccd, &simplex, polytope, nearest) != 0){ + return 0; // touch contact + } + }else{ // size == 2 + if (simplexToPolytope2(obj1, obj2, ccd, &simplex, polytope, nearest) != 0){ + return 0; // touch contact + } + } + + while (1){ + // get triangle nearest to origin + *nearest = ccdPtNearest(polytope); + + // get next support point + if (nextSupport(obj1, obj2, ccd, *nearest, &supp) != 0) + break; + + // expand nearest triangle using new point - supp + expandPolytope(polytope, *nearest, &supp); + } + + return 0; +} + + + +static int doSimplex2(ccd_simplex_t *simplex, ccd_vec3_t *dir) +{ + const ccd_support_t *A, *B; + ccd_vec3_t AB, AO, tmp; + ccd_real_t dot; + + // get last added as A + A = ccdSimplexLast(simplex); + // get the other point + B = ccdSimplexPoint(simplex, 0); + // compute AB oriented segment + ccdVec3Sub2(&AB, &B->v, &A->v); + // compute AO vector + ccdVec3Copy(&AO, &A->v); + ccdVec3Scale(&AO, -CCD_ONE); + + // dot product AB . AO + dot = ccdVec3Dot(&AB, &AO); + + // check if origin doesn't lie on AB segment + ccdVec3Cross(&tmp, &AB, &AO); + if (ccdIsZero(ccdVec3Len2(&tmp)) && dot > CCD_ZERO){ + return 1; + } + + // check if origin is in area where AB segment is + if (ccdIsZero(dot) || dot < CCD_ZERO){ + // origin is in outside are of A + ccdSimplexSet(simplex, 0, A); + ccdSimplexSetSize(simplex, 1); + ccdVec3Copy(dir, &AO); + }else{ + // origin is in area where AB segment is + + // keep simplex untouched and set direction to + // AB x AO x AB + tripleCross(&AB, &AO, &AB, dir); + } + + return 0; +} + +static int doSimplex3(ccd_simplex_t *simplex, ccd_vec3_t *dir) +{ + const ccd_support_t *A, *B, *C; + ccd_vec3_t AO, AB, AC, ABC, tmp; + ccd_real_t dot, dist; + + // get last added as A + A = ccdSimplexLast(simplex); + // get the other points + B = ccdSimplexPoint(simplex, 1); + C = ccdSimplexPoint(simplex, 0); + + // check touching contact + dist = ccdVec3PointTriDist2(ccd_vec3_origin, &A->v, &B->v, &C->v, NULL); + if (ccdIsZero(dist)){ + return 1; + } + + // check if triangle is really triangle (has area > 0) + // if not simplex can't be expanded and thus no itersection is found + if (ccdVec3Eq(&A->v, &B->v) || ccdVec3Eq(&A->v, &C->v)){ + return -1; + } + + // compute AO vector + ccdVec3Copy(&AO, &A->v); + ccdVec3Scale(&AO, -CCD_ONE); + + // compute AB and AC segments and ABC vector (perpendircular to triangle) + ccdVec3Sub2(&AB, &B->v, &A->v); + ccdVec3Sub2(&AC, &C->v, &A->v); + ccdVec3Cross(&ABC, &AB, &AC); + + ccdVec3Cross(&tmp, &ABC, &AC); + dot = ccdVec3Dot(&tmp, &AO); + if (ccdIsZero(dot) || dot > CCD_ZERO){ + dot = ccdVec3Dot(&AC, &AO); + if (ccdIsZero(dot) || dot > CCD_ZERO){ + // C is already in place + ccdSimplexSet(simplex, 1, A); + ccdSimplexSetSize(simplex, 2); + tripleCross(&AC, &AO, &AC, dir); + }else{ +ccd_do_simplex3_45: + dot = ccdVec3Dot(&AB, &AO); + if (ccdIsZero(dot) || dot > CCD_ZERO){ + ccdSimplexSet(simplex, 0, B); + ccdSimplexSet(simplex, 1, A); + ccdSimplexSetSize(simplex, 2); + tripleCross(&AB, &AO, &AB, dir); + }else{ + ccdSimplexSet(simplex, 0, A); + ccdSimplexSetSize(simplex, 1); + ccdVec3Copy(dir, &AO); + } + } + }else{ + ccdVec3Cross(&tmp, &AB, &ABC); + dot = ccdVec3Dot(&tmp, &AO); + if (ccdIsZero(dot) || dot > CCD_ZERO){ + goto ccd_do_simplex3_45; + }else{ + dot = ccdVec3Dot(&ABC, &AO); + if (ccdIsZero(dot) || dot > CCD_ZERO){ + ccdVec3Copy(dir, &ABC); + }else{ + ccd_support_t Ctmp; + ccdSupportCopy(&Ctmp, C); + ccdSimplexSet(simplex, 0, B); + ccdSimplexSet(simplex, 1, &Ctmp); + + ccdVec3Copy(dir, &ABC); + ccdVec3Scale(dir, -CCD_ONE); + } + } + } + + return 0; +} + +static int doSimplex4(ccd_simplex_t *simplex, ccd_vec3_t *dir) +{ + const ccd_support_t *A, *B, *C, *D; + ccd_vec3_t AO, AB, AC, AD, ABC, ACD, ADB; + int B_on_ACD, C_on_ADB, D_on_ABC; + int AB_O, AC_O, AD_O; + ccd_real_t dist; + + // get last added as A + A = ccdSimplexLast(simplex); + // get the other points + B = ccdSimplexPoint(simplex, 2); + C = ccdSimplexPoint(simplex, 1); + D = ccdSimplexPoint(simplex, 0); + + // check if tetrahedron is really tetrahedron (has volume > 0) + // if it is not simplex can't be expanded and thus no intersection is + // found + dist = ccdVec3PointTriDist2(&A->v, &B->v, &C->v, &D->v, NULL); + if (ccdIsZero(dist)){ + return -1; + } + + // check if origin lies on some of tetrahedron's face - if so objects + // intersect + dist = ccdVec3PointTriDist2(ccd_vec3_origin, &A->v, &B->v, &C->v, NULL); + if (ccdIsZero(dist)) + return 1; + dist = ccdVec3PointTriDist2(ccd_vec3_origin, &A->v, &C->v, &D->v, NULL); + if (ccdIsZero(dist)) + return 1; + dist = ccdVec3PointTriDist2(ccd_vec3_origin, &A->v, &B->v, &D->v, NULL); + if (ccdIsZero(dist)) + return 1; + dist = ccdVec3PointTriDist2(ccd_vec3_origin, &B->v, &C->v, &D->v, NULL); + if (ccdIsZero(dist)) + return 1; + + // compute AO, AB, AC, AD segments and ABC, ACD, ADB normal vectors + ccdVec3Copy(&AO, &A->v); + ccdVec3Scale(&AO, -CCD_ONE); + ccdVec3Sub2(&AB, &B->v, &A->v); + ccdVec3Sub2(&AC, &C->v, &A->v); + ccdVec3Sub2(&AD, &D->v, &A->v); + ccdVec3Cross(&ABC, &AB, &AC); + ccdVec3Cross(&ACD, &AC, &AD); + ccdVec3Cross(&ADB, &AD, &AB); + + // side (positive or negative) of B, C, D relative to planes ACD, ADB + // and ABC respectively + B_on_ACD = ccdSign(ccdVec3Dot(&ACD, &AB)); + C_on_ADB = ccdSign(ccdVec3Dot(&ADB, &AC)); + D_on_ABC = ccdSign(ccdVec3Dot(&ABC, &AD)); + + // whether origin is on same side of ACD, ADB, ABC as B, C, D + // respectively + AB_O = ccdSign(ccdVec3Dot(&ACD, &AO)) == B_on_ACD; + AC_O = ccdSign(ccdVec3Dot(&ADB, &AO)) == C_on_ADB; + AD_O = ccdSign(ccdVec3Dot(&ABC, &AO)) == D_on_ABC; + + if (AB_O && AC_O && AD_O){ + // origin is in tetrahedron + return 1; + + // rearrange simplex to triangle and call doSimplex3() + }else if (!AB_O){ + // B is farthest from the origin among all of the tetrahedron's + // points, so remove it from the list and go on with the triangle + // case + + // D and C are in place + ccdSimplexSet(simplex, 2, A); + ccdSimplexSetSize(simplex, 3); + }else if (!AC_O){ + // C is farthest + ccdSimplexSet(simplex, 1, D); + ccdSimplexSet(simplex, 0, B); + ccdSimplexSet(simplex, 2, A); + ccdSimplexSetSize(simplex, 3); + }else{ // (!AD_O) + ccdSimplexSet(simplex, 0, C); + ccdSimplexSet(simplex, 1, B); + ccdSimplexSet(simplex, 2, A); + ccdSimplexSetSize(simplex, 3); + } + + return doSimplex3(simplex, dir); +} + +static int doSimplex(ccd_simplex_t *simplex, ccd_vec3_t *dir) +{ + if (ccdSimplexSize(simplex) == 2){ + // simplex contains segment only one segment + return doSimplex2(simplex, dir); + }else if (ccdSimplexSize(simplex) == 3){ + // simplex contains triangle + return doSimplex3(simplex, dir); + }else{ // ccdSimplexSize(simplex) == 4 + // tetrahedron - this is the only shape which can encapsule origin + // so doSimplex4() also contains test on it + return doSimplex4(simplex, dir); + } +} + +_ccd_inline void tripleCross(const ccd_vec3_t *a, const ccd_vec3_t *b, + const ccd_vec3_t *c, ccd_vec3_t *d) +{ + ccd_vec3_t e; + ccdVec3Cross(&e, a, b); + ccdVec3Cross(d, &e, c); +} + + + +/** Transforms simplex to polytope. It is assumed that simplex has 4 + * vertices! */ +static int simplexToPolytope4(const void *obj1, const void *obj2, + const ccd_t *ccd, + ccd_simplex_t *simplex, + ccd_pt_t *pt, ccd_pt_el_t **nearest) +{ + const ccd_support_t *a, *b, *c, *d; + int use_polytope3; + ccd_real_t dist; + ccd_pt_vertex_t *v[4]; + ccd_pt_edge_t *e[6]; + size_t i; + + a = ccdSimplexPoint(simplex, 0); + b = ccdSimplexPoint(simplex, 1); + c = ccdSimplexPoint(simplex, 2); + d = ccdSimplexPoint(simplex, 3); + + // check if origin lies on some of tetrahedron's face - if so use + // simplexToPolytope3() + use_polytope3 = 0; + dist = ccdVec3PointTriDist2(ccd_vec3_origin, &a->v, &b->v, &c->v, NULL); + if (ccdIsZero(dist)){ + use_polytope3 = 1; + } + dist = ccdVec3PointTriDist2(ccd_vec3_origin, &a->v, &c->v, &d->v, NULL); + if (ccdIsZero(dist)){ + use_polytope3 = 1; + ccdSimplexSet(simplex, 1, c); + ccdSimplexSet(simplex, 2, d); + } + dist = ccdVec3PointTriDist2(ccd_vec3_origin, &a->v, &b->v, &d->v, NULL); + if (ccdIsZero(dist)){ + use_polytope3 = 1; + ccdSimplexSet(simplex, 2, d); + } + dist = ccdVec3PointTriDist2(ccd_vec3_origin, &b->v, &c->v, &d->v, NULL); + if (ccdIsZero(dist)){ + use_polytope3 = 1; + ccdSimplexSet(simplex, 0, b); + ccdSimplexSet(simplex, 1, c); + ccdSimplexSet(simplex, 2, d); + } + + if (use_polytope3){ + ccdSimplexSetSize(simplex, 3); + return simplexToPolytope3(obj1, obj2, ccd, simplex, pt, nearest); + } + + // no touching contact - simply create tetrahedron + for (i = 0; i < 4; i++){ + v[i] = ccdPtAddVertex(pt, ccdSimplexPoint(simplex, i)); + } + + e[0] = ccdPtAddEdge(pt, v[0], v[1]); + e[1] = ccdPtAddEdge(pt, v[1], v[2]); + e[2] = ccdPtAddEdge(pt, v[2], v[0]); + e[3] = ccdPtAddEdge(pt, v[3], v[0]); + e[4] = ccdPtAddEdge(pt, v[3], v[1]); + e[5] = ccdPtAddEdge(pt, v[3], v[2]); + + ccdPtAddFace(pt, e[0], e[1], e[2]); + ccdPtAddFace(pt, e[3], e[4], e[0]); + ccdPtAddFace(pt, e[4], e[5], e[1]); + ccdPtAddFace(pt, e[5], e[3], e[2]); + + return 0; +} + +/** Transforms simplex to polytope, three vertices required */ +static int simplexToPolytope3(const void *obj1, const void *obj2, + const ccd_t *ccd, + const ccd_simplex_t *simplex, + ccd_pt_t *pt, ccd_pt_el_t **nearest) +{ + const ccd_support_t *a, *b, *c; + ccd_support_t d, d2; + ccd_vec3_t ab, ac, dir; + ccd_pt_vertex_t *v[5]; + ccd_pt_edge_t *e[9]; + ccd_real_t dist, dist2; + + *nearest = NULL; + + a = ccdSimplexPoint(simplex, 0); + b = ccdSimplexPoint(simplex, 1); + c = ccdSimplexPoint(simplex, 2); + + // If only one triangle left from previous GJK run origin lies on this + // triangle. So it is necessary to expand triangle into two + // tetrahedrons connected with base (which is exactly abc triangle). + + // get next support point in direction of normal of triangle + ccdVec3Sub2(&ab, &b->v, &a->v); + ccdVec3Sub2(&ac, &c->v, &a->v); + ccdVec3Cross(&dir, &ab, &ac); + __ccdSupport(obj1, obj2, &dir, ccd, &d); + dist = ccdVec3PointTriDist2(&d.v, &a->v, &b->v, &c->v, NULL); + + // and second one take in opposite direction + ccdVec3Scale(&dir, -CCD_ONE); + __ccdSupport(obj1, obj2, &dir, ccd, &d2); + dist2 = ccdVec3PointTriDist2(&d2.v, &a->v, &b->v, &c->v, NULL); + + // check if face isn't already on edge of minkowski sum and thus we + // have touching contact + if (ccdIsZero(dist) || ccdIsZero(dist2)){ + v[0] = ccdPtAddVertex(pt, a); + v[1] = ccdPtAddVertex(pt, b); + v[2] = ccdPtAddVertex(pt, c); + e[0] = ccdPtAddEdge(pt, v[0], v[1]); + e[1] = ccdPtAddEdge(pt, v[1], v[2]); + e[2] = ccdPtAddEdge(pt, v[2], v[0]); + *nearest = (ccd_pt_el_t *)ccdPtAddFace(pt, e[0], e[1], e[2]); + + return -1; + } + + // form polyhedron + v[0] = ccdPtAddVertex(pt, a); + v[1] = ccdPtAddVertex(pt, b); + v[2] = ccdPtAddVertex(pt, c); + v[3] = ccdPtAddVertex(pt, &d); + v[4] = ccdPtAddVertex(pt, &d2); + + e[0] = ccdPtAddEdge(pt, v[0], v[1]); + e[1] = ccdPtAddEdge(pt, v[1], v[2]); + e[2] = ccdPtAddEdge(pt, v[2], v[0]); + + e[3] = ccdPtAddEdge(pt, v[3], v[0]); + e[4] = ccdPtAddEdge(pt, v[3], v[1]); + e[5] = ccdPtAddEdge(pt, v[3], v[2]); + + e[6] = ccdPtAddEdge(pt, v[4], v[0]); + e[7] = ccdPtAddEdge(pt, v[4], v[1]); + e[8] = ccdPtAddEdge(pt, v[4], v[2]); + + ccdPtAddFace(pt, e[3], e[4], e[0]); + ccdPtAddFace(pt, e[4], e[5], e[1]); + ccdPtAddFace(pt, e[5], e[3], e[2]); + + ccdPtAddFace(pt, e[6], e[7], e[0]); + ccdPtAddFace(pt, e[7], e[8], e[1]); + ccdPtAddFace(pt, e[8], e[6], e[2]); + + return 0; +} + +/** Transforms simplex to polytope, two vertices required */ +static int simplexToPolytope2(const void *obj1, const void *obj2, + const ccd_t *ccd, + const ccd_simplex_t *simplex, + ccd_pt_t *pt, ccd_pt_el_t **nearest) +{ + const ccd_support_t *a, *b; + ccd_vec3_t ab, ac, dir; + ccd_support_t supp[4]; + ccd_pt_vertex_t *v[6]; + ccd_pt_edge_t *e[12]; + size_t i; + int found; + + a = ccdSimplexPoint(simplex, 0); + b = ccdSimplexPoint(simplex, 1); + + // This situation is a bit tricky. If only one segment comes from + // previous run of GJK - it means that either this segment is on + // minkowski edge (and thus we have touch contact) or it it isn't and + // therefore segment is somewhere *inside* minkowski sum and it *must* + // be possible to fully enclose this segment with polyhedron formed by + // at least 8 triangle faces. + + // get first support point (any) + found = 0; + for (i = 0; i < ccd_points_on_sphere_len; i++){ + __ccdSupport(obj1, obj2, &ccd_points_on_sphere[i], ccd, &supp[0]); + if (!ccdVec3Eq(&a->v, &supp[0].v) && !ccdVec3Eq(&b->v, &supp[0].v)){ + found = 1; + break; + } + } + if (!found) + goto simplexToPolytope2_touching_contact; + + // get second support point in opposite direction than supp[0] + ccdVec3Copy(&dir, &supp[0].v); + ccdVec3Scale(&dir, -CCD_ONE); + __ccdSupport(obj1, obj2, &dir, ccd, &supp[1]); + if (ccdVec3Eq(&a->v, &supp[1].v) || ccdVec3Eq(&b->v, &supp[1].v)) + goto simplexToPolytope2_touching_contact; + + // next will be in direction of normal of triangle a,supp[0],supp[1] + ccdVec3Sub2(&ab, &supp[0].v, &a->v); + ccdVec3Sub2(&ac, &supp[1].v, &a->v); + ccdVec3Cross(&dir, &ab, &ac); + __ccdSupport(obj1, obj2, &dir, ccd, &supp[2]); + if (ccdVec3Eq(&a->v, &supp[2].v) || ccdVec3Eq(&b->v, &supp[2].v)) + goto simplexToPolytope2_touching_contact; + + // and last one will be in opposite direction + ccdVec3Scale(&dir, -CCD_ONE); + __ccdSupport(obj1, obj2, &dir, ccd, &supp[3]); + if (ccdVec3Eq(&a->v, &supp[3].v) || ccdVec3Eq(&b->v, &supp[3].v)) + goto simplexToPolytope2_touching_contact; + + goto simplexToPolytope2_not_touching_contact; +simplexToPolytope2_touching_contact: + v[0] = ccdPtAddVertex(pt, a); + v[1] = ccdPtAddVertex(pt, b); + *nearest = (ccd_pt_el_t *)ccdPtAddEdge(pt, v[0], v[1]); + return -1; + +simplexToPolytope2_not_touching_contact: + // form polyhedron + v[0] = ccdPtAddVertex(pt, a); + v[1] = ccdPtAddVertex(pt, &supp[0]); + v[2] = ccdPtAddVertex(pt, b); + v[3] = ccdPtAddVertex(pt, &supp[1]); + v[4] = ccdPtAddVertex(pt, &supp[2]); + v[5] = ccdPtAddVertex(pt, &supp[3]); + + e[0] = ccdPtAddEdge(pt, v[0], v[1]); + e[1] = ccdPtAddEdge(pt, v[1], v[2]); + e[2] = ccdPtAddEdge(pt, v[2], v[3]); + e[3] = ccdPtAddEdge(pt, v[3], v[0]); + + e[4] = ccdPtAddEdge(pt, v[4], v[0]); + e[5] = ccdPtAddEdge(pt, v[4], v[1]); + e[6] = ccdPtAddEdge(pt, v[4], v[2]); + e[7] = ccdPtAddEdge(pt, v[4], v[3]); + + e[8] = ccdPtAddEdge(pt, v[5], v[0]); + e[9] = ccdPtAddEdge(pt, v[5], v[1]); + e[10] = ccdPtAddEdge(pt, v[5], v[2]); + e[11] = ccdPtAddEdge(pt, v[5], v[3]); + + ccdPtAddFace(pt, e[4], e[5], e[0]); + ccdPtAddFace(pt, e[5], e[6], e[1]); + ccdPtAddFace(pt, e[6], e[7], e[2]); + ccdPtAddFace(pt, e[7], e[4], e[3]); + + ccdPtAddFace(pt, e[8], e[9], e[0]); + ccdPtAddFace(pt, e[9], e[10], e[1]); + ccdPtAddFace(pt, e[10], e[11], e[2]); + ccdPtAddFace(pt, e[11], e[8], e[3]); + + return 0; +} + +/** Expands polytope's tri by new vertex v. Triangle tri is replaced by + * three triangles each with one vertex in v. */ +static void expandPolytope(ccd_pt_t *pt, ccd_pt_el_t *el, + const ccd_support_t *newv) +{ + ccd_pt_vertex_t *v[5]; + ccd_pt_edge_t *e[8] = {0}; + ccd_pt_face_t *f[2]; + + + // element can be either segment or triangle + if (el->type == CCD_PT_EDGE){ + // In this case, segment should be replaced by new point. + // Simpliest case is when segment stands alone and in this case + // this segment is replaced by two other segments both connected to + // newv. + // Segment can be also connected to max two faces and in that case + // each face must be replaced by two other faces. To do this + // correctly it is necessary to have correctly ordered edges and + // vertices which is exactly what is done in following code. + // + + ccdPtEdgeVertices((const ccd_pt_edge_t *)el, &v[0], &v[2]); + + ccdPtEdgeFaces((ccd_pt_edge_t *)el, &f[0], &f[1]); + + if (f[0]){ + ccdPtFaceEdges(f[0], &e[0], &e[1], &e[2]); + if (e[0] == (ccd_pt_edge_t *)el){ + e[0] = e[2]; + }else if (e[1] == (ccd_pt_edge_t *)el){ + e[1] = e[2]; + } + ccdPtEdgeVertices(e[0], &v[1], &v[3]); + if (v[1] != v[0] && v[3] != v[0]){ + e[2] = e[0]; + e[0] = e[1]; + e[1] = e[2]; + if (v[1] == v[2]) + v[1] = v[3]; + }else{ + if (v[1] == v[0]) + v[1] = v[3]; + } + + if (f[1]){ + ccdPtFaceEdges(f[1], &e[2], &e[3], &e[4]); + if (e[2] == (ccd_pt_edge_t *)el){ + e[2] = e[4]; + }else if (e[3] == (ccd_pt_edge_t *)el){ + e[3] = e[4]; + } + ccdPtEdgeVertices(e[2], &v[3], &v[4]); + if (v[3] != v[2] && v[4] != v[2]){ + e[4] = e[2]; + e[2] = e[3]; + e[3] = e[4]; + if (v[3] == v[0]) + v[3] = v[4]; + }else{ + if (v[3] == v[2]) + v[3] = v[4]; + } + } + + + v[4] = ccdPtAddVertex(pt, newv); + + ccdPtDelFace(pt, f[0]); + if (f[1]){ + ccdPtDelFace(pt, f[1]); + ccdPtDelEdge(pt, (ccd_pt_edge_t *)el); + } + + e[4] = ccdPtAddEdge(pt, v[4], v[2]); + e[5] = ccdPtAddEdge(pt, v[4], v[0]); + e[6] = ccdPtAddEdge(pt, v[4], v[1]); + if (f[1]) + e[7] = ccdPtAddEdge(pt, v[4], v[3]); + + ccdPtAddFace(pt, e[1], e[4], e[6]); + ccdPtAddFace(pt, e[0], e[6], e[5]); + if (f[1]){ + ccdPtAddFace(pt, e[3], e[5], e[7]); + ccdPtAddFace(pt, e[4], e[7], e[2]); + }else{ + ccdPtAddFace(pt, e[4], e[5], (ccd_pt_edge_t *)el); + } + } + }else{ // el->type == CCD_PT_FACE + // replace triangle by tetrahedron without base (base would be the + // triangle that will be removed) + + // get triplet of surrounding edges and vertices of triangle face + ccdPtFaceEdges((const ccd_pt_face_t *)el, &e[0], &e[1], &e[2]); + ccdPtEdgeVertices(e[0], &v[0], &v[1]); + ccdPtEdgeVertices(e[1], &v[2], &v[3]); + + // following code sorts edges to have e[0] between vertices 0-1, + // e[1] between 1-2 and e[2] between 2-0 + if (v[2] != v[1] && v[3] != v[1]){ + // swap e[1] and e[2] + e[3] = e[1]; + e[1] = e[2]; + e[2] = e[3]; + } + if (v[3] != v[0] && v[3] != v[1]) + v[2] = v[3]; + + // remove triangle face + ccdPtDelFace(pt, (ccd_pt_face_t *)el); + + // expand triangle to tetrahedron + v[3] = ccdPtAddVertex(pt, newv); + e[3] = ccdPtAddEdge(pt, v[3], v[0]); + e[4] = ccdPtAddEdge(pt, v[3], v[1]); + e[5] = ccdPtAddEdge(pt, v[3], v[2]); + + ccdPtAddFace(pt, e[3], e[4], e[0]); + ccdPtAddFace(pt, e[4], e[5], e[1]); + ccdPtAddFace(pt, e[5], e[3], e[2]); + } +} + +/** Finds next support point (at stores it in out argument). + * Returns 0 on success, -1 otherwise */ +static int nextSupport(const void *obj1, const void *obj2, const ccd_t *ccd, + const ccd_pt_el_t *el, + ccd_support_t *out) +{ + ccd_vec3_t *a, *b, *c; + ccd_real_t dist; + + if (el->type == CCD_PT_VERTEX) + return -1; + + // touch contact + if (ccdIsZero(el->dist)) + return -1; + + __ccdSupport(obj1, obj2, &el->witness, ccd, out); + + if (el->type == CCD_PT_EDGE){ + // fetch end points of edge + ccdPtEdgeVec3((ccd_pt_edge_t *)el, &a, &b); + + // get distance from segment + dist = ccdVec3PointSegmentDist2(&out->v, a, b, NULL); + }else{ // el->type == CCD_PT_FACE + // fetch vertices of triangle face + ccdPtFaceVec3((ccd_pt_face_t *)el, &a, &b, &c); + + // check if new point can significantly expand polytope + dist = ccdVec3PointTriDist2(&out->v, a, b, c, NULL); + } + + if (dist < ccd->epa_tolerance) + return -1; + + return 0; +} diff --git a/libs/ode-0.16.1/libccd/src/ccd/alloc.h b/libs/ode-0.16.1/libccd/src/ccd/alloc.h new file mode 100644 index 0000000..7b92e3e --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/ccd/alloc.h @@ -0,0 +1,52 @@ +/*** + * libccd + * --------------------------------- + * Copyright (c)2010 Daniel Fiser + * + * + * This file is part of libccd. + * + * Distributed under the OSI-approved BSD License (the "License"); + * see accompanying file BDS-LICENSE for details or see + * . + * + * This software is distributed WITHOUT ANY WARRANTY; without even the + * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the License for more information. + */ + +#ifndef __CCD_ALLOC_H__ +#define __CCD_ALLOC_H__ + +#include + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +/** + * Functions and macros required for memory allocation. + */ + +/* Memory allocation: */ +#define __CCD_ALLOC_MEMORY(type, ptr_old, size) \ + (type *)ccdRealloc((void *)ptr_old, (size)) + +/** Allocate memory for one element of type. */ +#define CCD_ALLOC(type) \ + __CCD_ALLOC_MEMORY(type, NULL, sizeof(type)) + +/** Allocate memory for array of elements of type type. */ +#define CCD_ALLOC_ARR(type, num_elements) \ + __CCD_ALLOC_MEMORY(type, NULL, sizeof(type) * (num_elements)) + +#define CCD_REALLOC_ARR(ptr, type, num_elements) \ + __CCD_ALLOC_MEMORY(type, ptr, sizeof(type) * (num_elements)) + +void *ccdRealloc(void *ptr, size_t size); + +#ifdef __cplusplus +} /* extern "C" */ +#endif /* __cplusplus */ + +#endif /* __CCD_ALLOC_H__ */ diff --git a/libs/ode-0.16.1/libccd/src/ccd/ccd.h b/libs/ode-0.16.1/libccd/src/ccd/ccd.h new file mode 100644 index 0000000..3aaba8a --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/ccd/ccd.h @@ -0,0 +1,148 @@ +/*** + * libccd + * --------------------------------- + * Copyright (c)2010,2011 Daniel Fiser + * + * + * This file is part of libccd. + * + * Distributed under the OSI-approved BSD License (the "License"); + * see accompanying file BDS-LICENSE for details or see + * . + * + * This software is distributed WITHOUT ANY WARRANTY; without even the + * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the License for more information. + */ + +#ifndef __CCD_H__ +#define __CCD_H__ + +#include + +#include + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +/** + * Type of *support* function that takes pointer to 3D object and direction + * and returns (via vec argument) furthest point from object in specified + * direction. + */ +typedef void (*ccd_support_fn)(const void *obj, const ccd_vec3_t *dir, + ccd_vec3_t *vec); + +/** + * Returns (via dir argument) first direction vector that will be used in + * initialization of algorithm. + */ +typedef void (*ccd_first_dir_fn)(const void *obj1, const void *obj2, + ccd_vec3_t *dir); + + +/** + * Returns (via center argument) geometric center (some point near center) + * of given object. + */ +typedef void (*ccd_center_fn)(const void *obj1, ccd_vec3_t *center); + +/** + * Main structure of CCD algorithm. + */ +struct _ccd_t { + ccd_first_dir_fn first_dir; /*!< Returns initial direction where first + !< support point will be searched*/ + ccd_support_fn support1; /*!< Function that returns support point of + !< first object*/ + ccd_support_fn support2; /*!< Function that returns support point of + !< second object*/ + + ccd_center_fn center1; /*!< Function that returns geometric center of + !< first object*/ + ccd_center_fn center2; /*!< Function that returns geometric center of + !< second object*/ + + unsigned long max_iterations; /*!< Maximal number of iterations*/ + ccd_real_t epa_tolerance; + ccd_real_t mpr_tolerance; /*!< Boundary tolerance for MPR algorithm*/ +}; +typedef struct _ccd_t ccd_t; + +/** + * Default first direction. + */ +void ccdFirstDirDefault(const void *o1, const void *o2, ccd_vec3_t *dir); + +#define CCD_INIT(ccd) \ + do { \ + (ccd)->first_dir = ccdFirstDirDefault; \ + (ccd)->support1 = NULL; \ + (ccd)->support2 = NULL; \ + (ccd)->center1 = NULL; \ + (ccd)->center2 = NULL; \ + \ + (ccd)->max_iterations = (unsigned long)-1; \ + (ccd)->epa_tolerance = CCD_REAL(0.0001); \ + (ccd)->mpr_tolerance = CCD_REAL(0.0001); \ + } while(0) + + +/** + * Returns true if two given objects interest. + */ +int ccdGJKIntersect(const void *obj1, const void *obj2, const ccd_t *ccd); + +/** + * This function computes separation vector of two objects. Separation + * vector is minimal translation of obj2 to get obj1 and obj2 speparated + * (without intersection). + * Returns 0 if obj1 and obj2 intersect and sep is filled with translation + * vector. If obj1 and obj2 don't intersect -1 is returned. + */ +int ccdGJKSeparate(const void *obj1, const void *obj2, const ccd_t *ccd, + ccd_vec3_t *sep); + +/** + * Computes penetration of obj2 into obj1. + * Depth of penetration, direction and position is returned. It means that + * if obj2 is translated by distance depth in direction dir objects will + * have touching contact, pos should be position in global coordinates + * where force should take a place. + * + * CCD+EPA algorithm is used. + * + * Returns 0 if obj1 and obj2 intersect and depth, dir and pos are filled + * if given non-NULL pointers. + * If obj1 and obj2 don't intersect -1 is returned. + */ +int ccdGJKPenetration(const void *obj1, const void *obj2, const ccd_t *ccd, + ccd_real_t *depth, ccd_vec3_t *dir, ccd_vec3_t *pos); + + +/** + * Returns true if two given objects intersect - MPR algorithm is used. + */ +int ccdMPRIntersect(const void *obj1, const void *obj2, const ccd_t *ccd); + +/** + * Computes penetration of obj2 into obj1. + * Depth of penetration, direction and position is returned, i.e. if obj2 + * is translated by computed depth in resulting direction obj1 and obj2 + * would have touching contact. Position is point in global coordinates + * where force should be take a place. + * + * Minkowski Portal Refinement algorithm is used (MPR, a.k.a. XenoCollide, + * see Game Programming Gem 7). + * + * Returns 0 if obj1 and obj2 intersect, otherwise -1 is returned. + */ +int ccdMPRPenetration(const void *obj1, const void *obj2, const ccd_t *ccd, + ccd_real_t *depth, ccd_vec3_t *dir, ccd_vec3_t *pos); + +#ifdef __cplusplus +} /* extern "C" */ +#endif /* __cplusplus */ + +#endif /* __CCD_H__ */ diff --git a/libs/ode-0.16.1/libccd/src/ccd/compiler.h b/libs/ode-0.16.1/libccd/src/ccd/compiler.h new file mode 100644 index 0000000..380878f --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/ccd/compiler.h @@ -0,0 +1,61 @@ +/*** + * libccd + * --------------------------------- + * Copyright (c)2010 Daniel Fiser + * + * + * This file is part of libccd. + * + * Distributed under the OSI-approved BSD License (the "License"); + * see accompanying file BDS-LICENSE for details or see + * . + * + * This software is distributed WITHOUT ANY WARRANTY; without even the + * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the License for more information. + */ + +#ifndef __CCD_COMPILER_H__ +#define __CCD_COMPILER_H__ + +#include + +#define ccd_offsetof(TYPE, MEMBER) offsetof(TYPE, MEMBER) + +#define ccd_container_of(ptr, type, member) \ + (type *)( (char *)ptr - ccd_offsetof(type, member)) + + +/** + * Marks inline function. + */ +#ifdef __GNUC__ +/*# define _ccd_inline static inline __attribute__((always_inline))*/ +# define _ccd_inline static inline +#else /* __GNUC__ */ +# define _ccd_inline static __inline +#endif /* __GNUC__ */ + + +/** + * __prefetch(x) - prefetches the cacheline at "x" for read + * __prefetchw(x) - prefetches the cacheline at "x" for write + */ +#ifdef __GNUC__ +# define _ccd_prefetch(x) __builtin_prefetch(x) +# define _ccd_prefetchw(x) __builtin_prefetch(x,1) +#else /* __GNUC__ */ +# define _ccd_prefetch(x) ((void)0) +# define _ccd_prefetchw(x) ((void)0) +#endif /* __GNUC__ */ + + +#ifdef __ICC +/* disable unused parameter warning */ +# pragma warning(disable:869) +/* disable annoying "operands are evaluated in unspecified order" warning */ +# pragma warning(disable:981) +#endif /* __ICC */ + +#endif /* __CCD_COMPILER_H__ */ + diff --git a/libs/ode-0.16.1/libccd/src/ccd/dbg.h b/libs/ode-0.16.1/libccd/src/ccd/dbg.h new file mode 100644 index 0000000..f4852c1 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/ccd/dbg.h @@ -0,0 +1,65 @@ +/*** + * libccd + * --------------------------------- + * Copyright (c)2010 Daniel Fiser + * + * + * This file is part of libccd. + * + * Distributed under the OSI-approved BSD License (the "License"); + * see accompanying file BDS-LICENSE for details or see + * . + * + * This software is distributed WITHOUT ANY WARRANTY; without even the + * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the License for more information. + */ + +#ifndef __CCD_DBG_H__ +#define __CCD_DBG_H__ + +/** + * Some macros which can be used for printing debug info to stderr if macro + * NDEBUG not defined. + * + * DBG_PROLOGUE can be specified as string and this string will be + * prepended to output text + */ +#ifndef NDEBUG + +#include + +#ifndef DBG_PROLOGUE +# define DBG_PROLOGUE +#endif + +# define DBG(format, ...) do { \ + fprintf(stderr, DBG_PROLOGUE "%s :: " format "\n", __func__, ## __VA_ARGS__); \ + fflush(stderr); \ + } while (0) + +# define DBG2(str) do { \ + fprintf(stderr, DBG_PROLOGUE "%s :: " str "\n", __func__); \ + fflush(stderr); \ + } while (0) + +# define DBG_VEC3(vec, prefix) do {\ + fprintf(stderr, DBG_PROLOGUE "%s :: %s[%lf %lf %lf]\n", \ + __func__, prefix, ccdVec3X(vec), ccdVec3Y(vec), ccdVec3Z(vec)); \ + fflush(stderr); \ + } while (0) +/* +# define DBG_VEC3(vec, prefix) do {\ + fprintf(stderr, DBG_PROLOGUE "%s :: %s[%.20lf %.20lf %.20lf]\n", \ + __func__, prefix, ccdVec3X(vec), ccdVec3Y(vec), ccdVec3Z(vec)); \ + fflush(stderr); \ + } while (0) +*/ + +#else +# define DBG(format, ...) +# define DBG2(str) +# define DBG_VEC3(v, prefix) +#endif + +#endif /* __CCD_DBG_H__ */ diff --git a/libs/ode-0.16.1/libccd/src/ccd/list.h b/libs/ode-0.16.1/libccd/src/ccd/list.h new file mode 100644 index 0000000..54391ed --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/ccd/list.h @@ -0,0 +1,155 @@ +/*** + * libccd + * --------------------------------- + * Copyright (c)2010 Daniel Fiser + * + * + * This file is part of libccd. + * + * Distributed under the OSI-approved BSD License (the "License"); + * see accompanying file BDS-LICENSE for details or see + * . + * + * This software is distributed WITHOUT ANY WARRANTY; without even the + * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the License for more information. + */ + +#ifndef __CCD_LIST_H__ +#define __CCD_LIST_H__ + +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +struct _ccd_list_t { + struct _ccd_list_t *next, *prev; +}; +typedef struct _ccd_list_t ccd_list_t; + + + +/** + * Get the struct for this entry. + * @ptr: the &ccd_list_t pointer. + * @type: the type of the struct this is embedded in. + * @member: the name of the list_struct within the struct. + */ +#define ccdListEntry(ptr, type, member) \ + ccd_container_of(ptr, type, member) + +/** + * Iterates over list. + */ +#define ccdListForEach(list, item) \ + for (item = (list)->next; \ + _ccd_prefetch((item)->next), item != (list); \ + item = (item)->next) + +/** + * Iterates over list safe against remove of list entry + */ +#define ccdListForEachSafe(list, item, tmp) \ + for (item = (list)->next, tmp = (item)->next; \ + item != (list); \ + item = tmp, tmp = (item)->next) + +/** + * Iterates over list of given type. + * @pos: the type * to use as a loop cursor. + * @head: the head for your list. + * @member: the name of the list_struct within the struct. + */ +#define ccdListForEachEntry(head, pos, postype, member) \ + for (pos = ccdListEntry((head)->next, postype, member); \ + _ccd_prefetch(pos->member.next), &pos->member != (head); \ + pos = ccdListEntry(pos->member.next, postype, member)) + +/** + * Iterates over list of given type safe against removal of list entry + * @pos: the type * to use as a loop cursor. + * @n: another type * to use as temporary storage + * @head: the head for your list. + * @member: the name of the list_struct within the struct. + */ +#define ccdListForEachEntrySafe(head, pos, postype, n, ntype, member) \ + for (pos = ccdListEntry((head)->next, postype, member), \ + n = ccdListEntry(pos->member.next, postype, member); \ + &pos->member != (head); \ + pos = n, n = ccdListEntry(n->member.next, ntype, member)) + + +/** + * Initialize list. + */ +_ccd_inline void ccdListInit(ccd_list_t *l); + +_ccd_inline ccd_list_t *ccdListNext(ccd_list_t *l); +_ccd_inline ccd_list_t *ccdListPrev(ccd_list_t *l); + +/** + * Returns true if list is empty. + */ +_ccd_inline int ccdListEmpty(const ccd_list_t *head); + +/** + * Appends item to end of the list l. + */ +_ccd_inline void ccdListAppend(ccd_list_t *l, ccd_list_t *item); + +/** + * Removes item from list. + */ +_ccd_inline void ccdListDel(ccd_list_t *item); + + + +/// +/// INLINES: +/// + +_ccd_inline void ccdListInit(ccd_list_t *l) +{ + l->next = l; + l->prev = l; +} + +_ccd_inline ccd_list_t *ccdListNext(ccd_list_t *l) +{ + return l->next; +} + +_ccd_inline ccd_list_t *ccdListPrev(ccd_list_t *l) +{ + return l->prev; +} + +_ccd_inline int ccdListEmpty(const ccd_list_t *head) +{ + return head->next == head; +} + +_ccd_inline void ccdListAppend(ccd_list_t *l, ccd_list_t *newccd) +{ + newccd->prev = l->prev; + newccd->next = l; + l->prev->next = newccd; + l->prev = newccd; +} + +_ccd_inline void ccdListDel(ccd_list_t *item) +{ + item->next->prev = item->prev; + item->prev->next = item->next; + item->next = item; + item->prev = item; +} + +#ifdef __cplusplus +} /* extern "C" */ +#endif /* __cplusplus */ + +#endif /* __CCD_LIST_H__ */ diff --git a/libs/ode-0.16.1/libccd/src/ccd/polytope.h b/libs/ode-0.16.1/libccd/src/ccd/polytope.h new file mode 100644 index 0000000..c9ee2ab --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/ccd/polytope.h @@ -0,0 +1,322 @@ +/*** + * libccd + * --------------------------------- + * Copyright (c)2010 Daniel Fiser + * + * + * This file is part of libccd. + * + * Distributed under the OSI-approved BSD License (the "License"); + * see accompanying file BDS-LICENSE for details or see + * . + * + * This software is distributed WITHOUT ANY WARRANTY; without even the + * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the License for more information. + */ + +#ifndef __CCD_POLYTOPE_H__ +#define __CCD_POLYTOPE_H__ + +#include +#include +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +#define CCD_PT_VERTEX 1 +#define CCD_PT_EDGE 2 +#define CCD_PT_FACE 3 + + +#define __CCD_PT_EL \ + int type; /*! type of element */ \ + ccd_real_t dist; /*! distance from origin */ \ + ccd_vec3_t witness; /*! witness point of projection of origin */ \ + ccd_list_t list; /*! list of elements of same type */ + +/** + * General polytope element. + * Could be vertex, edge or triangle. + */ +struct _ccd_pt_el_t { + __CCD_PT_EL +}; +typedef struct _ccd_pt_el_t ccd_pt_el_t; + +struct _ccd_pt_edge_t; +struct _ccd_pt_face_t; + +/** + * Polytope's vertex. + */ +struct _ccd_pt_vertex_t { + __CCD_PT_EL + + int id; + ccd_support_t v; + ccd_list_t edges; //!< List of edges +}; +typedef struct _ccd_pt_vertex_t ccd_pt_vertex_t; + +/** + * Polytope's edge. + */ +struct _ccd_pt_edge_t { + __CCD_PT_EL + + ccd_pt_vertex_t *vertex[2]; //!< Reference to vertices + struct _ccd_pt_face_t *faces[2]; //!< Reference to faces + + ccd_list_t vertex_list[2]; //!< List items in vertices' lists +}; +typedef struct _ccd_pt_edge_t ccd_pt_edge_t; + +/** + * Polytope's triangle faces. + */ +struct _ccd_pt_face_t { + __CCD_PT_EL + + ccd_pt_edge_t *edge[3]; //!< Reference to surrounding edges +}; +typedef struct _ccd_pt_face_t ccd_pt_face_t; + + +/** + * Struct containing polytope. + */ +struct _ccd_pt_t { + ccd_list_t vertices; //!< List of vertices + ccd_list_t edges; //!< List of edges + ccd_list_t faces; //!< List of faces + + ccd_pt_el_t *nearest; + ccd_real_t nearest_dist; + int nearest_type; +}; +typedef struct _ccd_pt_t ccd_pt_t; + + +void ccdPtInit(ccd_pt_t *pt); +void ccdPtDestroy(ccd_pt_t *pt); + +/** + * Returns vertices surrounding given triangle face. + */ +_ccd_inline void ccdPtFaceVec3(const ccd_pt_face_t *face, + ccd_vec3_t **a, + ccd_vec3_t **b, + ccd_vec3_t **c); +_ccd_inline void ccdPtFaceVertices(const ccd_pt_face_t *face, + ccd_pt_vertex_t **a, + ccd_pt_vertex_t **b, + ccd_pt_vertex_t **c); +_ccd_inline void ccdPtFaceEdges(const ccd_pt_face_t *f, + ccd_pt_edge_t **a, + ccd_pt_edge_t **b, + ccd_pt_edge_t **c); + +_ccd_inline void ccdPtEdgeVec3(const ccd_pt_edge_t *e, + ccd_vec3_t **a, + ccd_vec3_t **b); +_ccd_inline void ccdPtEdgeVertices(const ccd_pt_edge_t *e, + ccd_pt_vertex_t **a, + ccd_pt_vertex_t **b); +_ccd_inline void ccdPtEdgeFaces(const ccd_pt_edge_t *e, + ccd_pt_face_t **f1, + ccd_pt_face_t **f2); + + +/** + * Adds vertex to polytope and returns pointer to newly created vertex. + */ +ccd_pt_vertex_t *ccdPtAddVertex(ccd_pt_t *pt, const ccd_support_t *v); +_ccd_inline ccd_pt_vertex_t *ccdPtAddVertexCoords(ccd_pt_t *pt, + ccd_real_t x, ccd_real_t y, ccd_real_t z); + +/** + * Adds edge to polytope. + */ +ccd_pt_edge_t *ccdPtAddEdge(ccd_pt_t *pt, ccd_pt_vertex_t *v1, + ccd_pt_vertex_t *v2); + +/** + * Adds face to polytope. + */ +ccd_pt_face_t *ccdPtAddFace(ccd_pt_t *pt, ccd_pt_edge_t *e1, + ccd_pt_edge_t *e2, + ccd_pt_edge_t *e3); + +/** + * Deletes vertex from polytope. + * Returns 0 on success, -1 otherwise. + */ +_ccd_inline int ccdPtDelVertex(ccd_pt_t *pt, ccd_pt_vertex_t *); +_ccd_inline int ccdPtDelEdge(ccd_pt_t *pt, ccd_pt_edge_t *); +_ccd_inline int ccdPtDelFace(ccd_pt_t *pt, ccd_pt_face_t *); + + +/** + * Recompute distances from origin for all elements in pt. + */ +void ccdPtRecomputeDistances(ccd_pt_t *pt); + +/** + * Returns nearest element to origin. + */ +ccd_pt_el_t *ccdPtNearest(ccd_pt_t *pt); + + +void ccdPtDumpSVT(ccd_pt_t *pt, const char *fn); +void ccdPtDumpSVT2(ccd_pt_t *pt, FILE *); + + +/**** INLINES ****/ +_ccd_inline ccd_pt_vertex_t *ccdPtAddVertexCoords(ccd_pt_t *pt, + ccd_real_t x, ccd_real_t y, ccd_real_t z) +{ + ccd_support_t s; + ccdVec3Set(&s.v, x, y, z); + return ccdPtAddVertex(pt, &s); +} + +_ccd_inline int ccdPtDelVertex(ccd_pt_t *pt, ccd_pt_vertex_t *v) +{ + // test if any edge is connected to this vertex + if (!ccdListEmpty(&v->edges)) + return -1; + + // delete vertex from main list + ccdListDel(&v->list); + + if ((void *)pt->nearest == (void *)v){ + pt->nearest = NULL; + } + + free(v); + return 0; +} + +_ccd_inline int ccdPtDelEdge(ccd_pt_t *pt, ccd_pt_edge_t *e) +{ + // text if any face is connected to this edge (faces[] is always + // aligned to lower indices) + if (e->faces[0] != NULL) + return -1; + + // disconnect edge from lists of edges in vertex struct + ccdListDel(&e->vertex_list[0]); + ccdListDel(&e->vertex_list[1]); + + // disconnect edge from main list + ccdListDel(&e->list); + + if ((void *)pt->nearest == (void *)e){ + pt->nearest = NULL; + } + + free(e); + return 0; +} + +_ccd_inline int ccdPtDelFace(ccd_pt_t *pt, ccd_pt_face_t *f) +{ + ccd_pt_edge_t *e; + size_t i; + + // remove face from edges' recerence lists + for (i = 0; i < 3; i++){ + e = f->edge[i]; + if (e->faces[0] == f){ + e->faces[0] = e->faces[1]; + } + e->faces[1] = NULL; + } + + // remove face from list of all faces + ccdListDel(&f->list); + + if ((void *)pt->nearest == (void *)f){ + pt->nearest = NULL; + } + + free(f); + return 0; +} + +_ccd_inline void ccdPtFaceVec3(const ccd_pt_face_t *face, + ccd_vec3_t **a, + ccd_vec3_t **b, + ccd_vec3_t **c) +{ + *a = &face->edge[0]->vertex[0]->v.v; + *b = &face->edge[0]->vertex[1]->v.v; + + if (face->edge[1]->vertex[0] != face->edge[0]->vertex[0] + && face->edge[1]->vertex[0] != face->edge[0]->vertex[1]){ + *c = &face->edge[1]->vertex[0]->v.v; + }else{ + *c = &face->edge[1]->vertex[1]->v.v; + } +} + +_ccd_inline void ccdPtFaceVertices(const ccd_pt_face_t *face, + ccd_pt_vertex_t **a, + ccd_pt_vertex_t **b, + ccd_pt_vertex_t **c) +{ + *a = face->edge[0]->vertex[0]; + *b = face->edge[0]->vertex[1]; + + if (face->edge[1]->vertex[0] != face->edge[0]->vertex[0] + && face->edge[1]->vertex[0] != face->edge[0]->vertex[1]){ + *c = face->edge[1]->vertex[0]; + }else{ + *c = face->edge[1]->vertex[1]; + } +} + +_ccd_inline void ccdPtFaceEdges(const ccd_pt_face_t *f, + ccd_pt_edge_t **a, + ccd_pt_edge_t **b, + ccd_pt_edge_t **c) +{ + *a = f->edge[0]; + *b = f->edge[1]; + *c = f->edge[2]; +} + +_ccd_inline void ccdPtEdgeVec3(const ccd_pt_edge_t *e, + ccd_vec3_t **a, + ccd_vec3_t **b) +{ + *a = &e->vertex[0]->v.v; + *b = &e->vertex[1]->v.v; +} + +_ccd_inline void ccdPtEdgeVertices(const ccd_pt_edge_t *e, + ccd_pt_vertex_t **a, + ccd_pt_vertex_t **b) +{ + *a = e->vertex[0]; + *b = e->vertex[1]; +} + +_ccd_inline void ccdPtEdgeFaces(const ccd_pt_edge_t *e, + ccd_pt_face_t **f1, + ccd_pt_face_t **f2) +{ + *f1 = e->faces[0]; + *f2 = e->faces[1]; +} + + +#ifdef __cplusplus +} /* extern "C" */ +#endif /* __cplusplus */ + +#endif /* __CCD_POLYTOPE_H__ */ diff --git a/libs/ode-0.16.1/libccd/src/ccd/precision.h.in b/libs/ode-0.16.1/libccd/src/ccd/precision.h.in new file mode 100644 index 0000000..4f98509 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/ccd/precision.h.in @@ -0,0 +1,14 @@ +#ifndef __CCD_PRECISION_H__ +#define __CCD_PRECISION_H__ + +/* define either CCD_SINGLE or CCD_DOUBLE */ + +#if defined(CCD_IDESINGLE) +#define CCD_SINGLE +#elif defined(CCD_IDEDOUBLE) +#define CCD_DOUBLE +#else +#define @CCD_PRECISION@ +#endif + +#endif diff --git a/libs/ode-0.16.1/libccd/src/ccd/quat.h b/libs/ode-0.16.1/libccd/src/ccd/quat.h new file mode 100644 index 0000000..3929671 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/ccd/quat.h @@ -0,0 +1,231 @@ +/*** + * libccd + * --------------------------------- + * Copyright (c)2010 Daniel Fiser + * + * + * This file is part of libccd. + * + * Distributed under the OSI-approved BSD License (the "License"); + * see accompanying file BDS-LICENSE for details or see + * . + * + * This software is distributed WITHOUT ANY WARRANTY; without even the + * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the License for more information. + */ + +#ifndef __CCD_QUAT_H__ +#define __CCD_QUAT_H__ + +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +struct _ccd_quat_t { + ccd_real_t q[4]; //!< x, y, z, w +}; +typedef struct _ccd_quat_t ccd_quat_t; + +#define CCD_QUAT(name, x, y, z, w) \ + ccd_quat_t name = { {x, y, z, w} } + +_ccd_inline ccd_real_t ccdQuatLen2(const ccd_quat_t *q); +_ccd_inline ccd_real_t ccdQuatLen(const ccd_quat_t *q); + +_ccd_inline void ccdQuatSet(ccd_quat_t *q, ccd_real_t x, ccd_real_t y, ccd_real_t z, ccd_real_t w); +_ccd_inline void ccdQuatCopy(ccd_quat_t *dest, const ccd_quat_t *src); + +_ccd_inline int ccdQuatNormalize(ccd_quat_t *q); + +_ccd_inline void ccdQuatSetAngleAxis(ccd_quat_t *q, + ccd_real_t angle, const ccd_vec3_t *axis); + +_ccd_inline void ccdQuatScale(ccd_quat_t *q, ccd_real_t k); + +/** + * q = q * q2 + */ +_ccd_inline void ccdQuatMul(ccd_quat_t *q, const ccd_quat_t *q2); + +/** + * q = a * b + */ +_ccd_inline void ccdQuatMul2(ccd_quat_t *q, + const ccd_quat_t *a, const ccd_quat_t *b); + +/** + * Inverts quaternion. + * Returns 0 on success. + */ +_ccd_inline int ccdQuatInvert(ccd_quat_t *q); +_ccd_inline int ccdQuatInvert2(ccd_quat_t *dest, const ccd_quat_t *src); + + +/** + * Rotate vector v by quaternion q. + */ +_ccd_inline void ccdQuatRotVec(ccd_vec3_t *v, const ccd_quat_t *q); + + +/**** INLINES ****/ +_ccd_inline ccd_real_t ccdQuatLen2(const ccd_quat_t *q) +{ + ccd_real_t len; + + len = q->q[0] * q->q[0]; + len += q->q[1] * q->q[1]; + len += q->q[2] * q->q[2]; + len += q->q[3] * q->q[3]; + + return len; +} + +_ccd_inline ccd_real_t ccdQuatLen(const ccd_quat_t *q) +{ + return CCD_SQRT(ccdQuatLen2(q)); +} + +_ccd_inline void ccdQuatSet(ccd_quat_t *q, ccd_real_t x, ccd_real_t y, ccd_real_t z, ccd_real_t w) +{ + q->q[0] = x; + q->q[1] = y; + q->q[2] = z; + q->q[3] = w; +} + +_ccd_inline void ccdQuatCopy(ccd_quat_t *dest, const ccd_quat_t *src) +{ + *dest = *src; +} + + +_ccd_inline int ccdQuatNormalize(ccd_quat_t *q) +{ + ccd_real_t len = ccdQuatLen(q); + if (len < CCD_EPS) + return 0; + + ccdQuatScale(q, CCD_ONE / len); + return 1; +} + +_ccd_inline void ccdQuatSetAngleAxis(ccd_quat_t *q, + ccd_real_t angle, const ccd_vec3_t *axis) +{ + ccd_real_t a, x, y, z, n, s; + + a = angle/2; + x = ccdVec3X(axis); + y = ccdVec3Y(axis); + z = ccdVec3Z(axis); + n = CCD_SQRT(x*x + y*y + z*z); + + // axis==0? (treat this the same as angle==0 with an arbitrary axis) + if (n < CCD_EPS){ + q->q[0] = q->q[1] = q->q[2] = CCD_ZERO; + q->q[3] = CCD_ONE; + }else{ + s = sin(a)/n; + + q->q[3] = cos(a); + q->q[0] = x*s; + q->q[1] = y*s; + q->q[2] = z*s; + + ccdQuatNormalize(q); + } +} + + +_ccd_inline void ccdQuatScale(ccd_quat_t *q, ccd_real_t k) +{ + size_t i; + for (i = 0; i < 4; i++) + q->q[i] *= k; +} + +_ccd_inline void ccdQuatMul(ccd_quat_t *q, const ccd_quat_t *q2) +{ + ccd_quat_t a; + ccdQuatCopy(&a, q); + ccdQuatMul2(q, &a, q2); +} + +_ccd_inline void ccdQuatMul2(ccd_quat_t *q, + const ccd_quat_t *a, const ccd_quat_t *b) +{ + q->q[0] = a->q[3] * b->q[0] + + a->q[0] * b->q[3] + + a->q[1] * b->q[2] + - a->q[2] * b->q[1]; + q->q[1] = a->q[3] * b->q[1] + + a->q[1] * b->q[3] + - a->q[0] * b->q[2] + + a->q[2] * b->q[0]; + q->q[2] = a->q[3] * b->q[2] + + a->q[2] * b->q[3] + + a->q[0] * b->q[1] + - a->q[1] * b->q[0]; + q->q[3] = a->q[3] * b->q[3] + - a->q[0] * b->q[0] + - a->q[1] * b->q[1] + - a->q[2] * b->q[2]; +} + +_ccd_inline int ccdQuatInvert(ccd_quat_t *q) +{ + ccd_real_t len2 = ccdQuatLen2(q); + if (len2 < CCD_EPS) + return -1; + + len2 = CCD_ONE / len2; + + q->q[0] = -q->q[0] * len2; + q->q[1] = -q->q[1] * len2; + q->q[2] = -q->q[2] * len2; + q->q[3] = q->q[3] * len2; + + return 0; +} +_ccd_inline int ccdQuatInvert2(ccd_quat_t *dest, const ccd_quat_t *src) +{ + ccdQuatCopy(dest, src); + return ccdQuatInvert(dest); +} + +_ccd_inline void ccdQuatRotVec(ccd_vec3_t *v, const ccd_quat_t *q) +{ + // original version: 31 mul + 21 add + // optimized version: 18 mul + 12 add + // formula: v = v + 2 * cross(q.xyz, cross(q.xyz, v) + q.w * v) + ccd_real_t cross1_x, cross1_y, cross1_z, cross2_x, cross2_y, cross2_z; + ccd_real_t x, y, z, w; + ccd_real_t vx, vy, vz; + + vx = ccdVec3X(v); + vy = ccdVec3Y(v); + vz = ccdVec3Z(v); + + w = q->q[3]; + x = q->q[0]; + y = q->q[1]; + z = q->q[2]; + + cross1_x = y * vz - z * vy + w * vx; + cross1_y = z * vx - x * vz + w * vy; + cross1_z = x * vy - y * vx + w * vz; + cross2_x = y * cross1_z - z * cross1_y; + cross2_y = z * cross1_x - x * cross1_z; + cross2_z = x * cross1_y - y * cross1_x; + ccdVec3Set(v, vx + 2 * cross2_x, vy + 2 * cross2_y, vz + 2 * cross2_z); +} + +#ifdef __cplusplus +} /* extern "C" */ +#endif /* __cplusplus */ + +#endif /* __CCD_QUAT_H__ */ diff --git a/libs/ode-0.16.1/libccd/src/ccd/simplex.h b/libs/ode-0.16.1/libccd/src/ccd/simplex.h new file mode 100644 index 0000000..1d07e39 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/ccd/simplex.h @@ -0,0 +1,104 @@ +/*** + * libccd + * --------------------------------- + * Copyright (c)2010 Daniel Fiser + * + * + * This file is part of libccd. + * + * Distributed under the OSI-approved BSD License (the "License"); + * see accompanying file BDS-LICENSE for details or see + * . + * + * This software is distributed WITHOUT ANY WARRANTY; without even the + * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the License for more information. + */ + +#ifndef __CCD_SIMPLEX_H__ +#define __CCD_SIMPLEX_H__ + +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +struct _ccd_simplex_t { + ccd_support_t ps[4]; + int last; /*!< index of last added point*/ +}; +typedef struct _ccd_simplex_t ccd_simplex_t; + + +_ccd_inline void ccdSimplexInit(ccd_simplex_t *s); +_ccd_inline int ccdSimplexSize(const ccd_simplex_t *s); +_ccd_inline const ccd_support_t *ccdSimplexLast(const ccd_simplex_t *s); +_ccd_inline const ccd_support_t *ccdSimplexPoint(const ccd_simplex_t *s, int idx); +_ccd_inline ccd_support_t *ccdSimplexPointW(ccd_simplex_t *s, int idx); + +_ccd_inline void ccdSimplexAdd(ccd_simplex_t *s, const ccd_support_t *v); +_ccd_inline void ccdSimplexSet(ccd_simplex_t *s, size_t pos, const ccd_support_t *a); +_ccd_inline void ccdSimplexSetSize(ccd_simplex_t *s, int size); +_ccd_inline void ccdSimplexSwap(ccd_simplex_t *s, size_t pos1, size_t pos2); + + +/**** INLINES ****/ + +_ccd_inline void ccdSimplexInit(ccd_simplex_t *s) +{ + s->last = -1; +} + +_ccd_inline int ccdSimplexSize(const ccd_simplex_t *s) +{ + return s->last + 1; +} + +_ccd_inline const ccd_support_t *ccdSimplexLast(const ccd_simplex_t *s) +{ + return ccdSimplexPoint(s, s->last); +} + +_ccd_inline const ccd_support_t *ccdSimplexPoint(const ccd_simplex_t *s, int idx) +{ + /* here is no check on boundaries */ + return &s->ps[idx]; +} +_ccd_inline ccd_support_t *ccdSimplexPointW(ccd_simplex_t *s, int idx) +{ + return &s->ps[idx]; +} + +_ccd_inline void ccdSimplexAdd(ccd_simplex_t *s, const ccd_support_t *v) +{ + /* here is no check on boundaries in sake of speed */ + ++s->last; + ccdSupportCopy(s->ps + s->last, v); +} + +_ccd_inline void ccdSimplexSet(ccd_simplex_t *s, size_t pos, const ccd_support_t *a) +{ + ccdSupportCopy(s->ps + pos, a); +} + +_ccd_inline void ccdSimplexSetSize(ccd_simplex_t *s, int size) +{ + s->last = size - 1; +} + +_ccd_inline void ccdSimplexSwap(ccd_simplex_t *s, size_t pos1, size_t pos2) +{ + ccd_support_t supp; + + ccdSupportCopy(&supp, &s->ps[pos1]); + ccdSupportCopy(&s->ps[pos1], &s->ps[pos2]); + ccdSupportCopy(&s->ps[pos2], &supp); +} + +#ifdef __cplusplus +} /* extern "C" */ +#endif /* __cplusplus */ + +#endif /* __CCD_SIMPLEX_H__ */ diff --git a/libs/ode-0.16.1/libccd/src/ccd/support.h b/libs/ode-0.16.1/libccd/src/ccd/support.h new file mode 100644 index 0000000..0a21b3e --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/ccd/support.h @@ -0,0 +1,57 @@ +/*** + * libccd + * --------------------------------- + * Copyright (c)2010 Daniel Fiser + * + * + * This file is part of libccd. + * + * Distributed under the OSI-approved BSD License (the "License"); + * see accompanying file BDS-LICENSE for details or see + * . + * + * This software is distributed WITHOUT ANY WARRANTY; without even the + * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the License for more information. + */ + +#ifndef __CCD_SUPPORT_H__ +#define __CCD_SUPPORT_H__ + +#include +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +struct _ccd_support_t { + ccd_vec3_t v; /*!< Support point in minkowski sum*/ + ccd_vec3_t v1; /*!< Support point in obj1*/ + ccd_vec3_t v2; /*!< Support point in obj2*/ +}; +typedef struct _ccd_support_t ccd_support_t; + +_ccd_inline void ccdSupportCopy(ccd_support_t *, const ccd_support_t *s); + +/** + * Computes support point of obj1 and obj2 in direction dir. + * Support point is returned via supp. + */ +void __ccdSupport(const void *obj1, const void *obj2, + const ccd_vec3_t *dir, const ccd_t *ccd, + ccd_support_t *supp); + + +/**** INLINES ****/ +_ccd_inline void ccdSupportCopy(ccd_support_t *d, const ccd_support_t *s) +{ + *d = *s; +} + +#ifdef __cplusplus +} /* extern "C" */ +#endif /* __cplusplus */ + +#endif /* __CCD_SUPPORT_H__ */ diff --git a/libs/ode-0.16.1/libccd/src/ccd/vec3.h b/libs/ode-0.16.1/libccd/src/ccd/vec3.h new file mode 100644 index 0000000..d9175ed --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/ccd/vec3.h @@ -0,0 +1,340 @@ +/*** + * libccd + * --------------------------------- + * Copyright (c)2010,2011 Daniel Fiser + * + * + * This file is part of libccd. + * + * Distributed under the OSI-approved BSD License (the "License"); + * see accompanying file BDS-LICENSE for details or see + * . + * + * This software is distributed WITHOUT ANY WARRANTY; without even the + * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the License for more information. + */ + +#ifndef __CCD_VEC3_H__ +#define __CCD_VEC3_H__ + +#include +#include +#include + +#include +#include + + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + + +#ifndef CCD_SINGLE +# ifndef CCD_DOUBLE +# error You must define CCD_SINGLE or CCD_DOUBLE +# endif /* CCD_DOUBLE */ +#endif /* CCD_SINGLE */ + + +#if defined(_MSC_VER) && _MSC_VER < 1700 +/* Define fmin, fmax, fminf, fmaxf which are missing from MSVC (up to VS2005 at least) */ +static __inline double fmin(double x, double y) { return __min(x, y); } +static __inline double fmax(double x, double y) { return __max(x, y); } +static __inline float fminf(float x, float y) { return __min(x, y); } +static __inline float fmaxf(float x, float y) { return __max(x, y); } + +#endif /* #if defined(_MSC_VER) */ + + +#ifdef CCD_SINGLE +# ifdef CCD_DOUBLE +# error You can define either CCD_SINGLE or CCD_DOUBLE, not both! +# endif /* CCD_DOUBLE */ + +typedef float ccd_real_t; + +/*# define CCD_EPS 1E-6*/ +# define CCD_EPS FLT_EPSILON + +# define CCD_REAL_MAX FLT_MAX + +# define CCD_REAL(x) (x ## f) /*!< form a constant */ +# define CCD_SQRT(x) (sqrtf(x)) /*!< square root */ +# define CCD_FABS(x) (fabsf(x)) /*!< absolute value */ +# define CCD_FMAX(x, y) (fmaxf((x), (y))) /*!< maximum of two floats */ +# define CCD_FMIN(x, y) (fminf((x), (y))) /*!< minimum of two floats */ +#endif /* CCD_SINGLE */ + +#ifdef CCD_DOUBLE +typedef double ccd_real_t; + +/*# define CCD_EPS 1E-10*/ +# define CCD_EPS DBL_EPSILON + +# define CCD_REAL_MAX DBL_MAX + +# define CCD_REAL(x) (x) /*!< form a constant */ +# define CCD_SQRT(x) (sqrt(x)) /*!< square root */ +# define CCD_FABS(x) (fabs(x)) /*!< absolute value */ +# define CCD_FMAX(x, y) (fmax((x), (y))) /*!< maximum of two floats */ +# define CCD_FMIN(x, y) (fmin((x), (y))) /*!< minimum of two floats */ +#endif /* CCD_DOUBLE */ + +#define CCD_ONE CCD_REAL(1.) +#define CCD_ZERO CCD_REAL(0.) + +struct _ccd_vec3_t { + ccd_real_t v[3]; +}; +typedef struct _ccd_vec3_t ccd_vec3_t; + + +/** + * Holds origin (0,0,0) - this variable is meant to be read-only! + */ +extern ccd_vec3_t *ccd_vec3_origin; + +/** + * Array of points uniformly distributed on unit sphere. + */ +extern ccd_vec3_t *ccd_points_on_sphere; +extern size_t ccd_points_on_sphere_len; + +/** Returns sign of value. */ +_ccd_inline int ccdSign(ccd_real_t val); +/** Returns true if val is zero. **/ +_ccd_inline int ccdIsZero(ccd_real_t val); +/** Returns true if a and b equal. **/ +_ccd_inline int ccdEq(ccd_real_t a, ccd_real_t b); + + +#define CCD_VEC3_STATIC(x, y, z) \ + { { (x), (y), (z) } } + +#define CCD_VEC3(name, x, y, z) \ + ccd_vec3_t name = CCD_VEC3_STATIC((x), (y), (z)) + +_ccd_inline ccd_real_t ccdVec3X(const ccd_vec3_t *v); +_ccd_inline ccd_real_t ccdVec3Y(const ccd_vec3_t *v); +_ccd_inline ccd_real_t ccdVec3Z(const ccd_vec3_t *v); + +/** + * Returns true if a and b equal. + */ +_ccd_inline int ccdVec3Eq(const ccd_vec3_t *a, const ccd_vec3_t *b); + +/** + * Returns squared length of vector. + */ +_ccd_inline ccd_real_t ccdVec3Len2(const ccd_vec3_t *v); + +/** + * Returns distance between a and b. + */ +_ccd_inline ccd_real_t ccdVec3Dist2(const ccd_vec3_t *a, const ccd_vec3_t *b); + + +_ccd_inline void ccdVec3Set(ccd_vec3_t *v, ccd_real_t x, ccd_real_t y, ccd_real_t z); + +/** + * v = w + */ +_ccd_inline void ccdVec3Copy(ccd_vec3_t *v, const ccd_vec3_t *w); + +/** + * Subtracts coordinates of vector w from vector v. v = v - w + */ +_ccd_inline void ccdVec3Sub(ccd_vec3_t *v, const ccd_vec3_t *w); + +/** + * Adds coordinates of vector w to vector v. v = v + w + */ +_ccd_inline void ccdVec3Add(ccd_vec3_t *v, const ccd_vec3_t *w); + +/** + * d = v - w + */ +_ccd_inline void ccdVec3Sub2(ccd_vec3_t *d, const ccd_vec3_t *v, const ccd_vec3_t *w); + +/** + * d = d * k; + */ +_ccd_inline void ccdVec3Scale(ccd_vec3_t *d, ccd_real_t k); + + +/** + * Normalizes given vector to unit length. + */ +_ccd_inline void ccdVec3Normalize(ccd_vec3_t *d); + + +/** + * Dot product of two vectors. + */ +_ccd_inline ccd_real_t ccdVec3Dot(const ccd_vec3_t *a, const ccd_vec3_t *b); + +/** + * Cross product: d = a x b. + */ +_ccd_inline void ccdVec3Cross(ccd_vec3_t *d, const ccd_vec3_t *a, const ccd_vec3_t *b); + + +/** + * Returns distance2 of point P to segment ab. + * If witness is non-NULL it is filled with coordinates of point from which + * was computed distance to point P. + */ +ccd_real_t ccdVec3PointSegmentDist2(const ccd_vec3_t *P, + const ccd_vec3_t *a, const ccd_vec3_t *b, + ccd_vec3_t *witness); + +/** + * Returns distance2 of point P from triangle formed by triplet a, b, c. + * If witness vector is provided it is filled with coordinates of point + * from which was computed distance to point P. + */ +ccd_real_t ccdVec3PointTriDist2(const ccd_vec3_t *P, + const ccd_vec3_t *a, const ccd_vec3_t *b, + const ccd_vec3_t *c, + ccd_vec3_t *witness); + + +/**** INLINES ****/ +_ccd_inline int ccdSign(ccd_real_t val) +{ + if (ccdIsZero(val)){ + return 0; + }else if (val < CCD_ZERO){ + return -1; + } + return 1; +} + +_ccd_inline int ccdIsZero(ccd_real_t val) +{ + return CCD_FABS(val) < CCD_EPS; +} + +_ccd_inline int ccdEq(ccd_real_t _a, ccd_real_t _b) +{ + ccd_real_t ab; + ccd_real_t a, b; + + ab = CCD_FABS(_a - _b); + if (CCD_FABS(ab) < CCD_EPS) + return 1; + + a = CCD_FABS(_a); + b = CCD_FABS(_b); + if (b > a){ + return ab < CCD_EPS * b; + }else{ + return ab < CCD_EPS * a; + } +} + + +_ccd_inline ccd_real_t ccdVec3X(const ccd_vec3_t *v) +{ + return v->v[0]; +} + +_ccd_inline ccd_real_t ccdVec3Y(const ccd_vec3_t *v) +{ + return v->v[1]; +} + +_ccd_inline ccd_real_t ccdVec3Z(const ccd_vec3_t *v) +{ + return v->v[2]; +} + +_ccd_inline int ccdVec3Eq(const ccd_vec3_t *a, const ccd_vec3_t *b) +{ + return ccdEq(ccdVec3X(a), ccdVec3X(b)) + && ccdEq(ccdVec3Y(a), ccdVec3Y(b)) + && ccdEq(ccdVec3Z(a), ccdVec3Z(b)); +} + +_ccd_inline ccd_real_t ccdVec3Len2(const ccd_vec3_t *v) +{ + return ccdVec3Dot(v, v); +} + +_ccd_inline ccd_real_t ccdVec3Dist2(const ccd_vec3_t *a, const ccd_vec3_t *b) +{ + ccd_vec3_t ab; + ccdVec3Sub2(&ab, a, b); + return ccdVec3Len2(&ab); +} + +_ccd_inline void ccdVec3Set(ccd_vec3_t *v, ccd_real_t x, ccd_real_t y, ccd_real_t z) +{ + v->v[0] = x; + v->v[1] = y; + v->v[2] = z; +} + +_ccd_inline void ccdVec3Copy(ccd_vec3_t *v, const ccd_vec3_t *w) +{ + *v = *w; +} + +_ccd_inline void ccdVec3Sub(ccd_vec3_t *v, const ccd_vec3_t *w) +{ + v->v[0] -= w->v[0]; + v->v[1] -= w->v[1]; + v->v[2] -= w->v[2]; +} + +_ccd_inline void ccdVec3Sub2(ccd_vec3_t *d, const ccd_vec3_t *v, const ccd_vec3_t *w) +{ + d->v[0] = v->v[0] - w->v[0]; + d->v[1] = v->v[1] - w->v[1]; + d->v[2] = v->v[2] - w->v[2]; +} + +_ccd_inline void ccdVec3Add(ccd_vec3_t *v, const ccd_vec3_t *w) +{ + v->v[0] += w->v[0]; + v->v[1] += w->v[1]; + v->v[2] += w->v[2]; +} + +_ccd_inline void ccdVec3Scale(ccd_vec3_t *d, ccd_real_t k) +{ + d->v[0] *= k; + d->v[1] *= k; + d->v[2] *= k; +} + +_ccd_inline void ccdVec3Normalize(ccd_vec3_t *d) +{ + ccd_real_t k = CCD_ONE / CCD_SQRT(ccdVec3Len2(d)); + ccdVec3Scale(d, k); +} + +_ccd_inline ccd_real_t ccdVec3Dot(const ccd_vec3_t *a, const ccd_vec3_t *b) +{ + ccd_real_t dot; + + dot = a->v[0] * b->v[0]; + dot += a->v[1] * b->v[1]; + dot += a->v[2] * b->v[2]; + return dot; +} + +_ccd_inline void ccdVec3Cross(ccd_vec3_t *d, const ccd_vec3_t *a, const ccd_vec3_t *b) +{ + d->v[0] = (a->v[1] * b->v[2]) - (a->v[2] * b->v[1]); + d->v[1] = (a->v[2] * b->v[0]) - (a->v[0] * b->v[2]); + d->v[2] = (a->v[0] * b->v[1]) - (a->v[1] * b->v[0]); +} + +#ifdef __cplusplus +} /* extern "C" */ +#endif /* __cplusplus */ + +#endif /* __CCD_VEC3_H__ */ diff --git a/libs/ode-0.16.1/libccd/src/config.h.in b/libs/ode-0.16.1/libccd/src/config.h.in new file mode 100644 index 0000000..f928422 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/config.h.in @@ -0,0 +1,97 @@ +/* src/config.h.in. Generated from configure.ac by autoheader. */ + +/* Define to 1 if you have the `clock_gettime' function. */ +#undef HAVE_CLOCK_GETTIME + +/* Define to 1 if you have the header file. */ +#undef HAVE_DLFCN_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_FLOAT_H + +/* Define to 1 if you have the `fork' function. */ +#undef HAVE_FORK + +/* Define to 1 if you have the header file. */ +#undef HAVE_INTTYPES_H + +/* Define to 1 if you have the `m' library (-lm). */ +#undef HAVE_LIBM + +/* Define to 1 if you have the `rt' library (-lrt). */ +#undef HAVE_LIBRT + +/* Define to 1 if you have the header file. */ +#undef HAVE_MEMORY_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_STDINT_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_STDLIB_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_STRINGS_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_STRING_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_STAT_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_TYPES_H + +/* Define to 1 if you have the header file. */ +#undef HAVE_UNISTD_H + +/* Define to 1 if you have the `vfork' function. */ +#undef HAVE_VFORK + +/* Define to 1 if you have the header file. */ +#undef HAVE_VFORK_H + +/* Define to 1 if `fork' works. */ +#undef HAVE_WORKING_FORK + +/* Define to 1 if `vfork' works. */ +#undef HAVE_WORKING_VFORK + +/* Define to the sub-directory where libtool stores uninstalled libraries. */ +#undef LT_OBJDIR + +/* Name of package */ +#undef PACKAGE + +/* Define to the address where bug reports for this package should be sent. */ +#undef PACKAGE_BUGREPORT + +/* Define to the full name of this package. */ +#undef PACKAGE_NAME + +/* Define to the full name and version of this package. */ +#undef PACKAGE_STRING + +/* Define to the one symbol short name of this package. */ +#undef PACKAGE_TARNAME + +/* Define to the home page for this package. */ +#undef PACKAGE_URL + +/* Define to the version of this package. */ +#undef PACKAGE_VERSION + +/* Define to 1 if you have the ANSI C header files. */ +#undef STDC_HEADERS + +/* Version number of package */ +#undef VERSION + +/* Define to `int' if does not define. */ +#undef pid_t + +/* Define to `unsigned int' if does not define. */ +#undef size_t + +/* Define as `fork' if `vfork' does not work. */ +#undef vfork diff --git a/libs/ode-0.16.1/libccd/src/custom/ccdcustom/quat.h b/libs/ode-0.16.1/libccd/src/custom/ccdcustom/quat.h new file mode 100644 index 0000000..157dd85 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/custom/ccdcustom/quat.h @@ -0,0 +1,69 @@ +/*** + * libccd + * --------------------------------- + * Copyright (c)2010 Daniel Fiser + * + * + * This file is part of libccd. + * + * Distributed under the OSI-approved BSD License (the "License"); + * see accompanying file BDS-LICENSE for details or see + * . + * + * This software is distributed WITHOUT ANY WARRANTY; without even the + * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the License for more information. + */ + +#ifndef __CCD_CUSTOM_QUAT_H__ +#define __CCD_CUSTOM_QUAT_H__ + +#include + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +/** + * Rotate vector s by quaternion q and put result into d. + */ +_ccd_inline void ccdQuatRotVec2(ccd_vec3_t *d, const ccd_vec3_t *s, const ccd_quat_t *q); + + +_ccd_inline void ccdQuatRotVec2(ccd_vec3_t *d, const ccd_vec3_t *s, const ccd_quat_t *q) +{ +#ifndef dLIBCCD_USE_SYSTEM + // original version: 31 mul + 21 add + // optimized version: 18 mul + 12 add + // formula: d = s + 2 * cross(q.xyz, cross(q.xyz, v) + q.w * s) + ccd_real_t cross1_x, cross1_y, cross1_z, cross2_x, cross2_y, cross2_z; + ccd_real_t x, y, z, w; + ccd_real_t vx, vy, vz; + + vx = ccdVec3X(s); + vy = ccdVec3Y(s); + vz = ccdVec3Z(s); + + w = q->q[3]; + x = q->q[0]; + y = q->q[1]; + z = q->q[2]; + + cross1_x = y * vz - z * vy + w * vx; + cross1_y = z * vx - x * vz + w * vy; + cross1_z = x * vy - y * vx + w * vz; + cross2_x = y * cross1_z - z * cross1_y; + cross2_y = z * cross1_x - x * cross1_z; + cross2_z = x * cross1_y - y * cross1_x; + ccdVec3Set(d, vx + 2 * cross2_x, vy + 2 * cross2_y, vz + 2 * cross2_z); +#else + ccdVec3Copy(d, s); + ccdQuatRotVec(d, q); +#endif +} + +#ifdef __cplusplus +} /* extern "C" */ +#endif /* __cplusplus */ + +#endif /* __CCD_QUAT_H__ */ diff --git a/libs/ode-0.16.1/libccd/src/custom/ccdcustom/vec3.h b/libs/ode-0.16.1/libccd/src/custom/ccdcustom/vec3.h new file mode 100644 index 0000000..2ac2f22 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/custom/ccdcustom/vec3.h @@ -0,0 +1,114 @@ +/*** + * libccd + * --------------------------------- + * Copyright (c)2010,2011 Daniel Fiser + * + * + * This file is part of libccd. + * + * Distributed under the OSI-approved BSD License (the "License"); + * see accompanying file BDS-LICENSE for details or see + * . + * + * This software is distributed WITHOUT ANY WARRANTY; without even the + * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the License for more information. + */ + +#ifndef __CCD_CUSTOM_VEC3_H__ +#define __CCD_CUSTOM_VEC3_H__ + +#include + + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + + +#ifdef CCD_SINGLE +# define CCD_ATAN2(x, y) (atan2f((x), (y))) /*!< atan2 of two floats */ +#endif /* CCD_SINGLE */ + +#ifdef CCD_DOUBLE +# define CCD_ATAN2(x, y) (atan2((x), (y))) /*!< atan2 of two floats */ +#endif /* CCD_DOUBLE */ + +/** + * d = v + w + */ +_ccd_inline void ccdVec3Add2(ccd_vec3_t *d, const ccd_vec3_t *v, const ccd_vec3_t *w); + +/** + * d = s * k; + */ +_ccd_inline void ccdVec3CopyScaled(ccd_vec3_t *d, const ccd_vec3_t *s, ccd_real_t k); + +/** + * d = v + s * k; + */ +_ccd_inline void ccdVec3AddScaled(ccd_vec3_t *d, const ccd_vec3_t *v, const ccd_vec3_t *s, ccd_real_t k); + + +/** + * Normalizes given vector to unit length. + */ +_ccd_inline int ccdVec3SafeNormalize(ccd_vec3_t *d); + + +_ccd_inline void ccdVec3Add2(ccd_vec3_t *d, const ccd_vec3_t *v, const ccd_vec3_t *w) +{ +#ifndef dLIBCCD_USE_SYSTEM + d->v[0] = v->v[0] + w->v[0]; + d->v[1] = v->v[1] + w->v[1]; + d->v[2] = v->v[2] + w->v[2]; +#else + ccdVec3Copy(d, v); + ccdVec3Add(d, w); +#endif +} + +_ccd_inline void ccdVec3CopyScaled(ccd_vec3_t *d, const ccd_vec3_t *s, ccd_real_t k) +{ +#ifndef dLIBCCD_USE_SYSTEM + d->v[0] = s->v[0] * k; + d->v[1] = s->v[1] * k; + d->v[2] = s->v[2] * k; +#else + ccdVec3Copy(d, s); + ccdVec3Scale(d, k); +#endif +} + +_ccd_inline void ccdVec3AddScaled(ccd_vec3_t *d, const ccd_vec3_t *v, const ccd_vec3_t *s, ccd_real_t k) +{ +#ifndef dLIBCCD_USE_SYSTEM + d->v[0] = v->v[0] + s->v[0] * k; + d->v[1] = v->v[1] + s->v[1] * k; + d->v[2] = v->v[2] + s->v[2] * k; +#else + ccdVec3Copy(d, s); + ccdVec3Scale(d, k); + ccdVec3Add(d, v); +#endif +} + +_ccd_inline int ccdVec3SafeNormalize(ccd_vec3_t *d) +{ + int result = -1; + + ccd_real_t len = CCD_SQRT(ccdVec3Len2(d)); + if (len >= CCD_EPS) { + ccdVec3Scale(d, CCD_ONE / len); + result = 0; + } + + return result; +} + + +#ifdef __cplusplus +} /* extern "C" */ +#endif /* __cplusplus */ + +#endif /* __CCD_CUSTOM_VEC3_H__ */ diff --git a/libs/ode-0.16.1/libccd/src/mpr.c b/libs/ode-0.16.1/libccd/src/mpr.c new file mode 100644 index 0000000..072a99b --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/mpr.c @@ -0,0 +1,572 @@ +/*** + * libccd + * --------------------------------- + * Copyright (c)2010,2011 Daniel Fiser + * + * + * This file is part of libccd. + * + * Distributed under the OSI-approved BSD License (the "License"); + * see accompanying file BDS-LICENSE for details or see + * . + * + * This software is distributed WITHOUT ANY WARRANTY; without even the + * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the License for more information. + */ + +#include +#include +#include +#include +#include + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +/** Finds origin (center) of Minkowski difference (actually it can be any + * interior point of Minkowski difference. */ +_ccd_inline void findOrigin(const void *obj1, const void *obj2, const ccd_t *ccd, + ccd_support_t *center); + +/** Discovers initial portal - that is tetrahedron that intersects with + * origin ray (ray from center of Minkowski diff to (0,0,0). + * + * Returns -1 if already recognized that origin is outside Minkowski + * portal. + * Returns 1 if origin lies on v1 of simplex (only v0 and v1 are present + * in simplex). + * Returns 2 if origin lies on v0-v1 segment. + * Returns 0 if portal was built. + */ +static int discoverPortal(const void *obj1, const void *obj2, + const ccd_t *ccd, ccd_simplex_t *portal); + + +/** Expands portal towards origin and determine if objects intersect. + * Already established portal must be given as argument. + * If intersection is found 0 is returned, -1 otherwise */ +static int refinePortal(const void *obj1, const void *obj2, + const ccd_t *ccd, ccd_simplex_t *portal); + +/** Finds penetration info by expanding provided portal. */ +static int findPenetr(const void *obj1, const void *obj2, const ccd_t *ccd, + ccd_simplex_t *portal, + ccd_real_t *depth, ccd_vec3_t *dir, ccd_vec3_t *pos); + +/** Finds penetration info if origin lies on portal's v1 */ +static void findPenetrTouch(const void *obj1, const void *obj2, const ccd_t *ccd, + ccd_simplex_t *portal, + ccd_real_t *depth, ccd_vec3_t *dir, ccd_vec3_t *pos); + +/** Find penetration info if origin lies on portal's segment v0-v1 */ +static int findPenetrSegment(const void *obj1, const void *obj2, const ccd_t *ccd, + ccd_simplex_t *portal, + ccd_real_t *depth, ccd_vec3_t *dir, ccd_vec3_t *pos); + +/** Finds position vector from fully established portal */ +static int findPos(const void *obj1, const void *obj2, const ccd_t *ccd, + const ccd_simplex_t *portal, ccd_vec3_t *pos); + +/** Extends portal with new support point. + * Portal must have face v1-v2-v3 arranged to face outside portal. */ +_ccd_inline void expandPortal(ccd_simplex_t *portal, + const ccd_support_t *v4); + +/** Fill dir with direction outside portal. Portal's v1-v2-v3 face must be + * arranged in correct order! */ +_ccd_inline int portalDir(const ccd_simplex_t *portal, ccd_vec3_t *dir); + +/** Returns true if portal encapsules origin (0,0,0), dir is direction of + * v1-v2-v3 face. */ +_ccd_inline int portalEncapsulesOrigin(const ccd_simplex_t *portal, + const ccd_vec3_t *dir); + +/** Returns true if portal with new point v4 would reach specified + * tolerance (i.e. returns true if portal can _not_ significantly expand + * within Minkowski difference). + * + * v4 is candidate for new point in portal, dir is direction in which v4 + * was obtained. */ +_ccd_inline int portalReachTolerance(const ccd_simplex_t *portal, + const ccd_support_t *v4, + const ccd_vec3_t *dir, + const ccd_t *ccd); + +/** Returns true if portal expanded by new point v4 could possibly contain + * origin, dir is direction in which v4 was obtained. */ +_ccd_inline int portalCanEncapsuleOrigin(const ccd_simplex_t *portal, + const ccd_support_t *v4, + const ccd_vec3_t *dir); + + +int ccdMPRIntersect(const void *obj1, const void *obj2, const ccd_t *ccd) +{ + ccd_simplex_t portal; + int res; + + // Phase 1: Portal discovery - find portal that intersects with origin + // ray (ray from center of Minkowski diff to origin of coordinates) + res = discoverPortal(obj1, obj2, ccd, &portal); + if (res < 0) + return 0; + if (res > 0) + return 1; + + // Phase 2: Portal refinement + res = refinePortal(obj1, obj2, ccd, &portal); + return (res == 0 ? 1 : 0); +} + +int ccdMPRPenetration(const void *obj1, const void *obj2, const ccd_t *ccd, + ccd_real_t *depth, ccd_vec3_t *dir, ccd_vec3_t *pos) +{ + ccd_simplex_t portal; + int res; + + // Phase 1: Portal discovery + res = discoverPortal(obj1, obj2, ccd, &portal); + if (res < 0){ + // Origin isn't inside portal - no collision. + return -1; + + }else if (res == 1){ + // Touching contact on portal's v1. + findPenetrTouch(obj1, obj2, ccd, &portal, depth, dir, pos); + + }else if (res == 2){ + // Origin lies on v0-v1 segment. + if (findPenetrSegment(obj1, obj2, ccd, &portal, depth, dir, pos) != 0) { + return -1; + } + + }else if (res == 0){ + // Phase 2: Portal refinement + res = refinePortal(obj1, obj2, ccd, &portal); + if (res < 0) { + return -1; + } + + // Phase 3. Penetration info + if (findPenetr(obj1, obj2, ccd, &portal, depth, dir, pos) != 0) { + return -1; + } + } + + return 0; +} + + + +_ccd_inline void findOrigin(const void *obj1, const void *obj2, const ccd_t *ccd, + ccd_support_t *center) +{ + ccd->center1(obj1, ¢er->v1); + ccd->center2(obj2, ¢er->v2); + ccdVec3Sub2(¢er->v, ¢er->v1, ¢er->v2); +} + +static int discoverPortal(const void *obj1, const void *obj2, + const ccd_t *ccd, ccd_simplex_t *portal) +{ + ccd_vec3_t dir, va, vb; + ccd_real_t dot; + int cont; + + // vertex 0 is center of portal + findOrigin(obj1, obj2, ccd, ccdSimplexPointW(portal, 0)); + ccdSimplexSetSize(portal, 1); + + if (ccdVec3Eq(&ccdSimplexPoint(portal, 0)->v, ccd_vec3_origin)){ + // Portal's center lies on origin (0,0,0) => we know that objects + // intersect but we would need to know penetration info. + // So move center little bit... + ccdVec3Set(&va, CCD_EPS * CCD_REAL(10.), CCD_ZERO, CCD_ZERO); + ccdVec3Add(&ccdSimplexPointW(portal, 0)->v, &va); + } + + + // vertex 1 = support in direction of origin + ccdVec3Copy(&dir, &ccdSimplexPoint(portal, 0)->v); + ccdVec3Scale(&dir, CCD_REAL(-1.)); + if (ccdVec3SafeNormalize(&dir) != 0) { + return -1; + } + __ccdSupport(obj1, obj2, &dir, ccd, ccdSimplexPointW(portal, 1)); + ccdSimplexSetSize(portal, 2); + + // test if origin isn't outside of v1 + dot = ccdVec3Dot(&ccdSimplexPoint(portal, 1)->v, &dir); + if (ccdIsZero(dot) || dot < CCD_ZERO) + return -1; + + + // vertex 2 + ccdVec3Cross(&dir, &ccdSimplexPoint(portal, 0)->v, + &ccdSimplexPoint(portal, 1)->v); + if (ccdIsZero(ccdVec3Len2(&dir))){ + if (ccdVec3Eq(&ccdSimplexPoint(portal, 1)->v, ccd_vec3_origin)){ + // origin lies on v1 + return 1; + }else{ + // origin lies on v0-v1 segment + return 2; + } + } + + if (ccdVec3SafeNormalize(&dir) != 0) { + return -1; + } + __ccdSupport(obj1, obj2, &dir, ccd, ccdSimplexPointW(portal, 2)); + dot = ccdVec3Dot(&ccdSimplexPoint(portal, 2)->v, &dir); + if (ccdIsZero(dot) || dot < CCD_ZERO) { + return -1; + } + + ccdSimplexSetSize(portal, 3); + + // vertex 3 direction + ccdVec3Sub2(&va, &ccdSimplexPoint(portal, 1)->v, + &ccdSimplexPoint(portal, 0)->v); + ccdVec3Sub2(&vb, &ccdSimplexPoint(portal, 2)->v, + &ccdSimplexPoint(portal, 0)->v); + ccdVec3Cross(&dir, &va, &vb); + if (ccdVec3SafeNormalize(&dir) != 0) { + return -1; + } + + // it is better to form portal faces to be oriented "outside" origin + dot = ccdVec3Dot(&dir, &ccdSimplexPoint(portal, 0)->v); + if (dot > CCD_ZERO){ + ccdSimplexSwap(portal, 1, 2); + ccdVec3Scale(&dir, CCD_REAL(-1.)); + } + + while (ccdSimplexSize(portal) < 4){ + __ccdSupport(obj1, obj2, &dir, ccd, ccdSimplexPointW(portal, 3)); + dot = ccdVec3Dot(&ccdSimplexPoint(portal, 3)->v, &dir); + if (ccdIsZero(dot) || dot < CCD_ZERO) { + return -1; + } + + cont = 0; + + // test if origin is outside (v1, v0, v3) - set v2 as v3 and + // continue + ccdVec3Cross(&va, &ccdSimplexPoint(portal, 1)->v, + &ccdSimplexPoint(portal, 3)->v); + dot = ccdVec3Dot(&va, &ccdSimplexPoint(portal, 0)->v); + if (dot < CCD_ZERO && !ccdIsZero(dot)){ + ccdSimplexSet(portal, 2, ccdSimplexPoint(portal, 3)); + cont = 1; + } + + if (!cont){ + // test if origin is outside (v3, v0, v2) - set v1 as v3 and + // continue + ccdVec3Cross(&va, &ccdSimplexPoint(portal, 3)->v, + &ccdSimplexPoint(portal, 2)->v); + dot = ccdVec3Dot(&va, &ccdSimplexPoint(portal, 0)->v); + if (dot < CCD_ZERO && !ccdIsZero(dot)){ + ccdSimplexSet(portal, 1, ccdSimplexPoint(portal, 3)); + cont = 1; + } + } + + if (cont){ + ccdVec3Sub2(&va, &ccdSimplexPoint(portal, 1)->v, + &ccdSimplexPoint(portal, 0)->v); + ccdVec3Sub2(&vb, &ccdSimplexPoint(portal, 2)->v, + &ccdSimplexPoint(portal, 0)->v); + ccdVec3Cross(&dir, &va, &vb); + if (ccdVec3SafeNormalize(&dir) != 0) { + return -1; + } + }else{ + ccdSimplexSetSize(portal, 4); + } + } + + return 0; +} + +static int refinePortal(const void *obj1, const void *obj2, + const ccd_t *ccd, ccd_simplex_t *portal) +{ + ccd_vec3_t dir; + ccd_support_t v4; + + while (1){ + // compute direction outside the portal (from v0 throught v1,v2,v3 + // face) + if (portalDir(portal, &dir) != 0) { + return -1; + } + + // test if origin is inside the portal + if (portalEncapsulesOrigin(portal, &dir)) + return 0; + + // get next support point + __ccdSupport(obj1, obj2, &dir, ccd, &v4); + + // test if v4 can expand portal to contain origin and if portal + // expanding doesn't reach given tolerance + if (!portalCanEncapsuleOrigin(portal, &v4, &dir) + || portalReachTolerance(portal, &v4, &dir, ccd)){ + return -1; + } + + // v1-v2-v3 triangle must be rearranged to face outside Minkowski + // difference (direction from v0). + expandPortal(portal, &v4); + } + + return -1; +} + + +static int findPenetr(const void *obj1, const void *obj2, const ccd_t *ccd, + ccd_simplex_t *portal, + ccd_real_t *depth, ccd_vec3_t *pdir, ccd_vec3_t *pos) +{ + ccd_vec3_t dir; + ccd_support_t v4; + unsigned long iterations; + + iterations = 0UL; + while (1){ + // compute portal direction and obtain next support point + if (portalDir(portal, &dir) != 0) { + return -1; + } + + __ccdSupport(obj1, obj2, &dir, ccd, &v4); + + // reached tolerance -> find penetration info + if (portalReachTolerance(portal, &v4, &dir, ccd) + || iterations > ccd->max_iterations){ + *depth = ccdVec3PointTriDist2(ccd_vec3_origin, + &ccdSimplexPoint(portal, 1)->v, + &ccdSimplexPoint(portal, 2)->v, + &ccdSimplexPoint(portal, 3)->v, + pdir); + *depth = CCD_SQRT(*depth); + if (ccdVec3SafeNormalize(pdir) != 0) { + return -1; + } + + // barycentric coordinates: + if (findPos(obj1, obj2, ccd, portal, pos) != 0) { + return -1; + } + + return 0; + } + + expandPortal(portal, &v4); + + iterations++; + } +} + +static void findPenetrTouch(const void *obj1, const void *obj2, const ccd_t *ccd, + ccd_simplex_t *portal, + ccd_real_t *depth, ccd_vec3_t *dir, ccd_vec3_t *pos) +{ + // Touching contact on portal's v1 - so depth is zero and direction + // is unimportant and pos can be guessed + *depth = CCD_REAL(0.); + ccdVec3Copy(dir, ccd_vec3_origin); + + ccdVec3Copy(pos, &ccdSimplexPoint(portal, 1)->v1); + ccdVec3Add(pos, &ccdSimplexPoint(portal, 1)->v2); + ccdVec3Scale(pos, 0.5); +} + +static int findPenetrSegment(const void *obj1, const void *obj2, const ccd_t *ccd, + ccd_simplex_t *portal, + ccd_real_t *depth, ccd_vec3_t *dir, ccd_vec3_t *pos) +{ + /* + ccd_vec3_t vec; + ccd_real_t k; + */ + + // Origin lies on v0-v1 segment. + // Depth is distance to v1, direction also and position must be + // computed + + ccdVec3Copy(pos, &ccdSimplexPoint(portal, 1)->v1); + ccdVec3Add(pos, &ccdSimplexPoint(portal, 1)->v2); + ccdVec3Scale(pos, CCD_REAL(0.5)); + + /* + ccdVec3Sub2(&vec, &ccdSimplexPoint(portal, 1)->v, + &ccdSimplexPoint(portal, 0)->v); + k = CCD_SQRT(ccdVec3Len2(&ccdSimplexPoint(portal, 0)->v)); + k /= CCD_SQRT(ccdVec3Len2(&vec)); + ccdVec3Scale(&vec, -k); + ccdVec3Add(pos, &vec); + */ + + ccdVec3Copy(dir, &ccdSimplexPoint(portal, 1)->v); + *depth = CCD_SQRT(ccdVec3Len2(dir)); + if (ccdVec3SafeNormalize(dir) != 0) { + return -1; + } + return 0; +} + + +static int findPos(const void *obj1, const void *obj2, const ccd_t *ccd, + const ccd_simplex_t *portal, ccd_vec3_t *pos) +{ + ccd_vec3_t dir; + size_t i; + ccd_real_t b[4], sum, inv; + ccd_vec3_t vec, p1, p2; + + if (portalDir(portal, &dir) != 0) { + return -1; + } + + // use barycentric coordinates of tetrahedron to find origin + ccdVec3Cross(&vec, &ccdSimplexPoint(portal, 1)->v, + &ccdSimplexPoint(portal, 2)->v); + b[0] = ccdVec3Dot(&vec, &ccdSimplexPoint(portal, 3)->v); + + ccdVec3Cross(&vec, &ccdSimplexPoint(portal, 3)->v, + &ccdSimplexPoint(portal, 2)->v); + b[1] = ccdVec3Dot(&vec, &ccdSimplexPoint(portal, 0)->v); + + ccdVec3Cross(&vec, &ccdSimplexPoint(portal, 0)->v, + &ccdSimplexPoint(portal, 1)->v); + b[2] = ccdVec3Dot(&vec, &ccdSimplexPoint(portal, 3)->v); + + ccdVec3Cross(&vec, &ccdSimplexPoint(portal, 2)->v, + &ccdSimplexPoint(portal, 1)->v); + b[3] = ccdVec3Dot(&vec, &ccdSimplexPoint(portal, 0)->v); + + sum = b[0] + b[1] + b[2] + b[3]; + + if (ccdIsZero(sum) || sum < CCD_ZERO){ + b[0] = CCD_REAL(0.); + + ccdVec3Cross(&vec, &ccdSimplexPoint(portal, 2)->v, + &ccdSimplexPoint(portal, 3)->v); + b[1] = ccdVec3Dot(&vec, &dir); + ccdVec3Cross(&vec, &ccdSimplexPoint(portal, 3)->v, + &ccdSimplexPoint(portal, 1)->v); + b[2] = ccdVec3Dot(&vec, &dir); + ccdVec3Cross(&vec, &ccdSimplexPoint(portal, 1)->v, + &ccdSimplexPoint(portal, 2)->v); + b[3] = ccdVec3Dot(&vec, &dir); + + sum = b[1] + b[2] + b[3]; + } + + inv = CCD_REAL(1.) / sum; + + ccdVec3Copy(&p1, ccd_vec3_origin); + ccdVec3Copy(&p2, ccd_vec3_origin); + for (i = 0; i < 4; i++){ + ccdVec3Copy(&vec, &ccdSimplexPoint(portal, i)->v1); + ccdVec3Scale(&vec, b[i]); + ccdVec3Add(&p1, &vec); + + ccdVec3Copy(&vec, &ccdSimplexPoint(portal, i)->v2); + ccdVec3Scale(&vec, b[i]); + ccdVec3Add(&p2, &vec); + } + ccdVec3Scale(&p1, inv); + ccdVec3Scale(&p2, inv); + + ccdVec3Copy(pos, &p1); + ccdVec3Add(pos, &p2); + ccdVec3Scale(pos, 0.5); + return 0; +} + +_ccd_inline void expandPortal(ccd_simplex_t *portal, + const ccd_support_t *v4) +{ + ccd_real_t dot; + ccd_vec3_t v4v0; + + ccdVec3Cross(&v4v0, &v4->v, &ccdSimplexPoint(portal, 0)->v); + dot = ccdVec3Dot(&ccdSimplexPoint(portal, 1)->v, &v4v0); + if (dot > CCD_ZERO){ + dot = ccdVec3Dot(&ccdSimplexPoint(portal, 2)->v, &v4v0); + if (dot > CCD_ZERO){ + ccdSimplexSet(portal, 1, v4); + }else{ + ccdSimplexSet(portal, 3, v4); + } + }else{ + dot = ccdVec3Dot(&ccdSimplexPoint(portal, 3)->v, &v4v0); + if (dot > CCD_ZERO){ + ccdSimplexSet(portal, 2, v4); + }else{ + ccdSimplexSet(portal, 1, v4); + } + } +} + +_ccd_inline int portalDir(const ccd_simplex_t *portal, ccd_vec3_t *dir) +{ + ccd_vec3_t v2v1, v3v1; + + ccdVec3Sub2(&v2v1, &ccdSimplexPoint(portal, 2)->v, + &ccdSimplexPoint(portal, 1)->v); + ccdVec3Sub2(&v3v1, &ccdSimplexPoint(portal, 3)->v, + &ccdSimplexPoint(portal, 1)->v); + ccdVec3Cross(dir, &v2v1, &v3v1); + if (ccdVec3SafeNormalize(dir) != 0) { + return -1; + } + return 0; +} + +_ccd_inline int portalEncapsulesOrigin(const ccd_simplex_t *portal, + const ccd_vec3_t *dir) +{ + ccd_real_t dot; + dot = ccdVec3Dot(dir, &ccdSimplexPoint(portal, 1)->v); + return ccdIsZero(dot) || dot > CCD_ZERO; +} + +_ccd_inline int portalReachTolerance(const ccd_simplex_t *portal, + const ccd_support_t *v4, + const ccd_vec3_t *dir, + const ccd_t *ccd) +{ + ccd_real_t dv1, dv2, dv3, dv4; + ccd_real_t dot1, dot2, dot3; + + // find the smallest dot product of dir and {v1-v4, v2-v4, v3-v4} + + dv1 = ccdVec3Dot(&ccdSimplexPoint(portal, 1)->v, dir); + dv2 = ccdVec3Dot(&ccdSimplexPoint(portal, 2)->v, dir); + dv3 = ccdVec3Dot(&ccdSimplexPoint(portal, 3)->v, dir); + dv4 = ccdVec3Dot(&v4->v, dir); + + dot1 = dv4 - dv1; + dot2 = dv4 - dv2; + dot3 = dv4 - dv3; + + dot1 = CCD_FMIN(dot1, dot2); + dot1 = CCD_FMIN(dot1, dot3); + + return ccdEq(dot1, ccd->mpr_tolerance) || dot1 < ccd->mpr_tolerance; +} + +_ccd_inline int portalCanEncapsuleOrigin(const ccd_simplex_t *portal, + const ccd_support_t *v4, + const ccd_vec3_t *dir) +{ + ccd_real_t dot; + dot = ccdVec3Dot(&v4->v, dir); + return ccdIsZero(dot) || dot > CCD_ZERO; +} diff --git a/libs/ode-0.16.1/libccd/src/polytope.c b/libs/ode-0.16.1/libccd/src/polytope.c new file mode 100644 index 0000000..c340b8c --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/polytope.c @@ -0,0 +1,287 @@ +/*** + * libccd + * --------------------------------- + * Copyright (c)2010 Daniel Fiser + * + * + * This file is part of libccd. + * + * Distributed under the OSI-approved BSD License (the "License"); + * see accompanying file BDS-LICENSE for details or see + * . + * + * This software is distributed WITHOUT ANY WARRANTY; without even the + * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the License for more information. + */ + +#include +#include +#include +#include + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +_ccd_inline void _ccdPtNearestUpdate(ccd_pt_t *pt, ccd_pt_el_t *el) +{ + if (ccdEq(pt->nearest_dist, el->dist)){ + if (el->type < pt->nearest_type){ + pt->nearest = el; + pt->nearest_dist = el->dist; + pt->nearest_type = el->type; + } + }else if (el->dist < pt->nearest_dist){ + pt->nearest = el; + pt->nearest_dist = el->dist; + pt->nearest_type = el->type; + } +} + +static void _ccdPtNearestRenew(ccd_pt_t *pt) +{ + ccd_pt_vertex_t *v; + ccd_pt_edge_t *e; + ccd_pt_face_t *f; + + pt->nearest_dist = CCD_REAL_MAX; + pt->nearest_type = 3; + pt->nearest = NULL; + + ccdListForEachEntry(&pt->vertices, v, ccd_pt_vertex_t, list){ + _ccdPtNearestUpdate(pt, (ccd_pt_el_t *)v); + } + + ccdListForEachEntry(&pt->edges, e, ccd_pt_edge_t, list){ + _ccdPtNearestUpdate(pt, (ccd_pt_el_t *)e); + } + + ccdListForEachEntry(&pt->faces, f, ccd_pt_face_t, list){ + _ccdPtNearestUpdate(pt, (ccd_pt_el_t *)f); + } +} + + + +void ccdPtInit(ccd_pt_t *pt) +{ + ccdListInit(&pt->vertices); + ccdListInit(&pt->edges); + ccdListInit(&pt->faces); + + pt->nearest = NULL; + pt->nearest_dist = CCD_REAL_MAX; + pt->nearest_type = 3; +} + +void ccdPtDestroy(ccd_pt_t *pt) +{ + ccd_pt_face_t *f, *f2; + ccd_pt_edge_t *e, *e2; + ccd_pt_vertex_t *v, *v2; + + // first delete all faces + ccdListForEachEntrySafe(&pt->faces, f, ccd_pt_face_t, f2, ccd_pt_face_t, list){ + ccdPtDelFace(pt, f); + } + + // delete all edges + ccdListForEachEntrySafe(&pt->edges, e, ccd_pt_edge_t, e2, ccd_pt_edge_t, list){ + ccdPtDelEdge(pt, e); + } + + // delete all vertices + ccdListForEachEntrySafe(&pt->vertices, v, ccd_pt_vertex_t, v2, ccd_pt_vertex_t, list){ + ccdPtDelVertex(pt, v); + } +} + + +ccd_pt_vertex_t *ccdPtAddVertex(ccd_pt_t *pt, const ccd_support_t *v) +{ + ccd_pt_vertex_t *vert; + + vert = CCD_ALLOC(ccd_pt_vertex_t); + vert->type = CCD_PT_VERTEX; + ccdSupportCopy(&vert->v, v); + + vert->dist = ccdVec3Len2(&vert->v.v); + ccdVec3Copy(&vert->witness, &vert->v.v); + + ccdListInit(&vert->edges); + + // add vertex to list + ccdListAppend(&pt->vertices, &vert->list); + + // update position in .nearest array + _ccdPtNearestUpdate(pt, (ccd_pt_el_t *)vert); + + return vert; +} + +ccd_pt_edge_t *ccdPtAddEdge(ccd_pt_t *pt, ccd_pt_vertex_t *v1, + ccd_pt_vertex_t *v2) +{ + const ccd_vec3_t *a, *b; + ccd_pt_edge_t *edge; + + edge = CCD_ALLOC(ccd_pt_edge_t); + edge->type = CCD_PT_EDGE; + edge->vertex[0] = v1; + edge->vertex[1] = v2; + edge->faces[0] = edge->faces[1] = NULL; + + a = &edge->vertex[0]->v.v; + b = &edge->vertex[1]->v.v; + edge->dist = ccdVec3PointSegmentDist2(ccd_vec3_origin, a, b, &edge->witness); + + ccdListAppend(&edge->vertex[0]->edges, &edge->vertex_list[0]); + ccdListAppend(&edge->vertex[1]->edges, &edge->vertex_list[1]); + + ccdListAppend(&pt->edges, &edge->list); + + // update position in .nearest array + _ccdPtNearestUpdate(pt, (ccd_pt_el_t *)edge); + + return edge; +} + +ccd_pt_face_t *ccdPtAddFace(ccd_pt_t *pt, ccd_pt_edge_t *e1, + ccd_pt_edge_t *e2, + ccd_pt_edge_t *e3) +{ + const ccd_vec3_t *a, *b, *c; + ccd_pt_face_t *face; + ccd_pt_edge_t *e; + size_t i; + + face = CCD_ALLOC(ccd_pt_face_t); + face->type = CCD_PT_FACE; + face->edge[0] = e1; + face->edge[1] = e2; + face->edge[2] = e3; + + // obtain triplet of vertices + a = &face->edge[0]->vertex[0]->v.v; + b = &face->edge[0]->vertex[1]->v.v; + e = face->edge[1]; + if (e->vertex[0] != face->edge[0]->vertex[0] + && e->vertex[0] != face->edge[0]->vertex[1]){ + c = &e->vertex[0]->v.v; + }else{ + c = &e->vertex[1]->v.v; + } + face->dist = ccdVec3PointTriDist2(ccd_vec3_origin, a, b, c, &face->witness); + + + for (i = 0; i < 3; i++){ + if (face->edge[i]->faces[0] == NULL){ + face->edge[i]->faces[0] = face; + }else{ + face->edge[i]->faces[1] = face; + } + } + + ccdListAppend(&pt->faces, &face->list); + + // update position in .nearest array + _ccdPtNearestUpdate(pt, (ccd_pt_el_t *)face); + + return face; +} + + +void ccdPtRecomputeDistances(ccd_pt_t *pt) +{ + ccd_pt_vertex_t *v; + ccd_pt_edge_t *e; + ccd_pt_face_t *f; + const ccd_vec3_t *a, *b, *c; + ccd_real_t dist; + + ccdListForEachEntry(&pt->vertices, v, ccd_pt_vertex_t, list){ + dist = ccdVec3Len2(&v->v.v); + v->dist = dist; + ccdVec3Copy(&v->witness, &v->v.v); + } + + ccdListForEachEntry(&pt->edges, e, ccd_pt_edge_t, list){ + a = &e->vertex[0]->v.v; + b = &e->vertex[1]->v.v; + dist = ccdVec3PointSegmentDist2(ccd_vec3_origin, a, b, &e->witness); + e->dist = dist; + } + + ccdListForEachEntry(&pt->faces, f, ccd_pt_face_t, list){ + // obtain triplet of vertices + a = &f->edge[0]->vertex[0]->v.v; + b = &f->edge[0]->vertex[1]->v.v; + e = f->edge[1]; + if (e->vertex[0] != f->edge[0]->vertex[0] + && e->vertex[0] != f->edge[0]->vertex[1]){ + c = &e->vertex[0]->v.v; + }else{ + c = &e->vertex[1]->v.v; + } + + dist = ccdVec3PointTriDist2(ccd_vec3_origin, a, b, c, &f->witness); + f->dist = dist; + } +} + +ccd_pt_el_t *ccdPtNearest(ccd_pt_t *pt) +{ + if (!pt->nearest){ + _ccdPtNearestRenew(pt); + } + return pt->nearest; +} + + +void ccdPtDumpSVT(ccd_pt_t *pt, const char *fn) +{ + FILE *fout; + + fout = fopen(fn, "a"); + if (fout == NULL) + return; + + ccdPtDumpSVT2(pt, fout); + + fclose(fout); +} + +void ccdPtDumpSVT2(ccd_pt_t *pt, FILE *fout) +{ + ccd_pt_vertex_t *v, *a, *b, *c; + ccd_pt_edge_t *e; + ccd_pt_face_t *f; + size_t i; + + fprintf(fout, "-----\n"); + + fprintf(fout, "Points:\n"); + i = 0; + ccdListForEachEntry(&pt->vertices, v, ccd_pt_vertex_t, list){ + v->id = i++; + fprintf(fout, "%lf %lf %lf\n", + ccdVec3X(&v->v.v), ccdVec3Y(&v->v.v), ccdVec3Z(&v->v.v)); + } + + fprintf(fout, "Edges:\n"); + ccdListForEachEntry(&pt->edges, e, ccd_pt_edge_t, list){ + fprintf(fout, "%d %d\n", e->vertex[0]->id, e->vertex[1]->id); + } + + fprintf(fout, "Faces:\n"); + ccdListForEachEntry(&pt->faces, f, ccd_pt_face_t, list){ + a = f->edge[0]->vertex[0]; + b = f->edge[0]->vertex[1]; + c = f->edge[1]->vertex[0]; + if (c == a || c == b){ + c = f->edge[1]->vertex[1]; + } + fprintf(fout, "%d %d %d\n", a->id, b->id, c->id); + } +} diff --git a/libs/ode-0.16.1/libccd/src/support.c b/libs/ode-0.16.1/libccd/src/support.c new file mode 100644 index 0000000..5ce3586 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/support.c @@ -0,0 +1,39 @@ +/*** + * libccd + * --------------------------------- + * Copyright (c)2010 Daniel Fiser + * + * + * This file is part of libccd. + * + * Distributed under the OSI-approved BSD License (the "License"); + * see accompanying file BDS-LICENSE for details or see + * . + * + * This software is distributed WITHOUT ANY WARRANTY; without even the + * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the License for more information. + */ + +#include + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + + +void __ccdSupport(const void *obj1, const void *obj2, + const ccd_vec3_t *_dir, const ccd_t *ccd, + ccd_support_t *supp) +{ + ccd_vec3_t dir; + + ccdVec3Copy(&dir, _dir); + + ccd->support1(obj1, &dir, &supp->v1); + + ccdVec3Scale(&dir, -CCD_ONE); + ccd->support2(obj2, &dir, &supp->v2); + + ccdVec3Sub2(&supp->v, &supp->v1, &supp->v2); +} diff --git a/libs/ode-0.16.1/libccd/src/testsuites/Makefile.am b/libs/ode-0.16.1/libccd/src/testsuites/Makefile.am new file mode 100644 index 0000000..733fed3 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/Makefile.am @@ -0,0 +1,28 @@ +SUBDIRS = cu + +AM_CPPFLAGS = -I $(srcdir)/.. -I $(builddir)/.. -I $(srcdir)/cu + +LDADD = $(builddir)/cu/libcu.la $(builddir)/../libccd.la + + +check_PROGRAMS = test bench bench2 + +test_SOURCES = main.c \ + common.c common.h \ + support.c support.h \ + vec3.c vec3.h \ + polytope.c polytope.h \ + boxbox.c boxbox.h \ + spheresphere.c spheresphere.h \ + cylcyl.c cylcyl.h \ + boxcyl.c boxcyl.h \ + mpr_boxbox.c mpr_boxbox.h \ + mpr_cylcyl.c mpr_cylcyl.h \ + mpr_boxcyl.c mpr_boxcyl.h + +bench_SOURCES = bench.c \ + support.c support.h + +bench2_SOURCES = bench2.c \ + support.c support.h + diff --git a/libs/ode-0.16.1/libccd/src/testsuites/Makefile.in b/libs/ode-0.16.1/libccd/src/testsuites/Makefile.in new file mode 100644 index 0000000..40ff0ea --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/Makefile.in @@ -0,0 +1,753 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +check_PROGRAMS = test$(EXEEXT) bench$(EXEEXT) bench2$(EXEEXT) +subdir = src/testsuites +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/src/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +am_bench_OBJECTS = bench.$(OBJEXT) support.$(OBJEXT) +bench_OBJECTS = $(am_bench_OBJECTS) +bench_LDADD = $(LDADD) +bench_DEPENDENCIES = $(builddir)/cu/libcu.la $(builddir)/../libccd.la +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = +am_bench2_OBJECTS = bench2.$(OBJEXT) support.$(OBJEXT) +bench2_OBJECTS = $(am_bench2_OBJECTS) +bench2_LDADD = $(LDADD) +bench2_DEPENDENCIES = $(builddir)/cu/libcu.la $(builddir)/../libccd.la +am_test_OBJECTS = main.$(OBJEXT) common.$(OBJEXT) support.$(OBJEXT) \ + vec3.$(OBJEXT) polytope.$(OBJEXT) boxbox.$(OBJEXT) \ + spheresphere.$(OBJEXT) cylcyl.$(OBJEXT) boxcyl.$(OBJEXT) \ + mpr_boxbox.$(OBJEXT) mpr_cylcyl.$(OBJEXT) mpr_boxcyl.$(OBJEXT) +test_OBJECTS = $(am_test_OBJECTS) +test_LDADD = $(LDADD) +test_DEPENDENCIES = $(builddir)/cu/libcu.la $(builddir)/../libccd.la +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/src +depcomp = $(SHELL) $(top_srcdir)/../depcomp +am__depfiles_maybe = depfiles +am__mv = mv -f +COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ + $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CFLAGS) $(CFLAGS) +AM_V_CC = $(am__v_CC_@AM_V@) +am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) +am__v_CC_0 = @echo " CC " $@; +am__v_CC_1 = +CCLD = $(CC) +LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CCLD = $(am__v_CCLD_@AM_V@) +am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) +am__v_CCLD_0 = @echo " CCLD " $@; +am__v_CCLD_1 = +SOURCES = $(bench_SOURCES) $(bench2_SOURCES) $(test_SOURCES) +DIST_SOURCES = $(bench_SOURCES) $(bench2_SOURCES) $(test_SOURCES) +RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ + ctags-recursive dvi-recursive html-recursive info-recursive \ + install-data-recursive install-dvi-recursive \ + install-exec-recursive install-html-recursive \ + install-info-recursive install-pdf-recursive \ + install-ps-recursive install-recursive installcheck-recursive \ + installdirs-recursive pdf-recursive ps-recursive \ + tags-recursive uninstall-recursive +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ + distclean-recursive maintainer-clean-recursive +am__recursive_targets = \ + $(RECURSIVE_TARGETS) \ + $(RECURSIVE_CLEAN_TARGETS) \ + $(am__extra_recursive_targets) +AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ + distdir +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +DIST_SUBDIRS = $(SUBDIRS) +am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/../depcomp +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +am__relativize = \ + dir0=`pwd`; \ + sed_first='s,^\([^/]*\)/.*$$,\1,'; \ + sed_rest='s,^[^/]*/*,,'; \ + sed_last='s,^.*/\([^/]*\)$$,\1,'; \ + sed_butlast='s,/*[^/]*$$,,'; \ + while test -n "$$dir1"; do \ + first=`echo "$$dir1" | sed -e "$$sed_first"`; \ + if test "$$first" != "."; then \ + if test "$$first" = ".."; then \ + dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ + dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ + else \ + first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ + if test "$$first2" = "$$first"; then \ + dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ + else \ + dir2="../$$dir2"; \ + fi; \ + dir0="$$dir0"/"$$first"; \ + fi; \ + fi; \ + dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ + done; \ + reldir="$$dir2" +ACLOCAL = @ACLOCAL@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CCD_PRECISION = @CCD_PRECISION@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +FGREP = @FGREP@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +runstatedir = @runstatedir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +SUBDIRS = cu +AM_CPPFLAGS = -I $(srcdir)/.. -I $(builddir)/.. -I $(srcdir)/cu +LDADD = $(builddir)/cu/libcu.la $(builddir)/../libccd.la +test_SOURCES = main.c \ + common.c common.h \ + support.c support.h \ + vec3.c vec3.h \ + polytope.c polytope.h \ + boxbox.c boxbox.h \ + spheresphere.c spheresphere.h \ + cylcyl.c cylcyl.h \ + boxcyl.c boxcyl.h \ + mpr_boxbox.c mpr_boxbox.h \ + mpr_cylcyl.c mpr_cylcyl.h \ + mpr_boxcyl.c mpr_boxcyl.h + +bench_SOURCES = bench.c \ + support.c support.h + +bench2_SOURCES = bench2.c \ + support.c support.h + +all: all-recursive + +.SUFFIXES: +.SUFFIXES: .c .lo .o .obj +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/testsuites/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign src/testsuites/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): + +clean-checkPROGRAMS: + @list='$(check_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list + +bench$(EXEEXT): $(bench_OBJECTS) $(bench_DEPENDENCIES) $(EXTRA_bench_DEPENDENCIES) + @rm -f bench$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(bench_OBJECTS) $(bench_LDADD) $(LIBS) + +bench2$(EXEEXT): $(bench2_OBJECTS) $(bench2_DEPENDENCIES) $(EXTRA_bench2_DEPENDENCIES) + @rm -f bench2$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(bench2_OBJECTS) $(bench2_LDADD) $(LIBS) + +test$(EXEEXT): $(test_OBJECTS) $(test_DEPENDENCIES) $(EXTRA_test_DEPENDENCIES) + @rm -f test$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(test_OBJECTS) $(test_LDADD) $(LIBS) + +mostlyclean-compile: + -rm -f *.$(OBJEXT) + +distclean-compile: + -rm -f *.tab.c + +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/bench.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/bench2.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/boxbox.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/boxcyl.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/common.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cylcyl.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/main.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mpr_boxbox.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mpr_boxcyl.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mpr_cylcyl.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/polytope.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/spheresphere.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/support.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vec3.Po@am__quote@ + +.c.o: +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< + +.c.obj: +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` + +.c.lo: +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +# This directory's subdirectories are mostly independent; you can cd +# into them and run 'make' without going through this Makefile. +# To change the values of 'make' variables: instead of editing Makefiles, +# (1) if the variable is set in 'config.status', edit 'config.status' +# (which will cause the Makefiles to be regenerated when you run 'make'); +# (2) otherwise, pass the desired values on the 'make' command line. +$(am__recursive_targets): + @fail=; \ + if $(am__make_keepgoing); then \ + failcom='fail=yes'; \ + else \ + failcom='exit 1'; \ + fi; \ + dot_seen=no; \ + target=`echo $@ | sed s/-recursive//`; \ + case "$@" in \ + distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ + *) list='$(SUBDIRS)' ;; \ + esac; \ + for subdir in $$list; do \ + echo "Making $$target in $$subdir"; \ + if test "$$subdir" = "."; then \ + dot_seen=yes; \ + local_target="$$target-am"; \ + else \ + local_target="$$target"; \ + fi; \ + ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ + || eval $$failcom; \ + done; \ + if test "$$dot_seen" = "no"; then \ + $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ + fi; test -z "$$fail" + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-recursive +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ + include_option=--etags-include; \ + empty_fix=.; \ + else \ + include_option=--include; \ + empty_fix=; \ + fi; \ + list='$(SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + test ! -f $$subdir/TAGS || \ + set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ + fi; \ + done; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-recursive + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-recursive + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done + @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + $(am__make_dryrun) \ + || test -d "$(distdir)/$$subdir" \ + || $(MKDIR_P) "$(distdir)/$$subdir" \ + || exit 1; \ + dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ + $(am__relativize); \ + new_distdir=$$reldir; \ + dir1=$$subdir; dir2="$(top_distdir)"; \ + $(am__relativize); \ + new_top_distdir=$$reldir; \ + echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ + echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ + ($(am__cd) $$subdir && \ + $(MAKE) $(AM_MAKEFLAGS) \ + top_distdir="$$new_top_distdir" \ + distdir="$$new_distdir" \ + am__remove_distdir=: \ + am__skip_length_check=: \ + am__skip_mode_fix=: \ + distdir) \ + || exit 1; \ + fi; \ + done +check-am: all-am + $(MAKE) $(AM_MAKEFLAGS) $(check_PROGRAMS) +check: check-recursive +all-am: Makefile +installdirs: installdirs-recursive +installdirs-am: +install: install-recursive +install-exec: install-exec-recursive +install-data: install-data-recursive +uninstall: uninstall-recursive + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-recursive +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-recursive + +clean-am: clean-checkPROGRAMS clean-generic clean-libtool \ + mostlyclean-am + +distclean: distclean-recursive + -rm -rf ./$(DEPDIR) + -rm -f Makefile +distclean-am: clean-am distclean-compile distclean-generic \ + distclean-tags + +dvi: dvi-recursive + +dvi-am: + +html: html-recursive + +html-am: + +info: info-recursive + +info-am: + +install-data-am: + +install-dvi: install-dvi-recursive + +install-dvi-am: + +install-exec-am: + +install-html: install-html-recursive + +install-html-am: + +install-info: install-info-recursive + +install-info-am: + +install-man: + +install-pdf: install-pdf-recursive + +install-pdf-am: + +install-ps: install-ps-recursive + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-recursive + -rm -rf ./$(DEPDIR) + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-recursive + +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ + mostlyclean-libtool + +pdf: pdf-recursive + +pdf-am: + +ps: ps-recursive + +ps-am: + +uninstall-am: + +.MAKE: $(am__recursive_targets) check-am install-am install-strip + +.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \ + check-am clean clean-checkPROGRAMS clean-generic clean-libtool \ + cscopelist-am ctags ctags-am distclean distclean-compile \ + distclean-generic distclean-libtool distclean-tags distdir dvi \ + dvi-am html html-am info info-am install install-am \ + install-data install-data-am install-dvi install-dvi-am \ + install-exec install-exec-am install-html install-html-am \ + install-info install-info-am install-man install-pdf \ + install-pdf-am install-ps install-ps-am install-strip \ + installcheck installcheck-am installdirs installdirs-am \ + maintainer-clean maintainer-clean-generic mostlyclean \ + mostlyclean-compile mostlyclean-generic mostlyclean-libtool \ + pdf pdf-am ps ps-am tags tags-am uninstall uninstall-am + +.PRECIOUS: Makefile + + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/libs/ode-0.16.1/libccd/src/testsuites/bench.c b/libs/ode-0.16.1/libccd/src/testsuites/bench.c new file mode 100644 index 0000000..779a8ac --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/bench.c @@ -0,0 +1,257 @@ +#define CU_ENABLE_TIMER +#include +#include +#include +#include +#include "support.h" + +TEST_SUITES { + TEST_SUITES_CLOSURE +}; + +static int bench_num = 1; +static size_t cycles = 10000; + +static void runBench(const void *o1, const void *o2, const ccd_t *ccd) +{ + ccd_real_t depth; + ccd_vec3_t dir, pos; + int res; + size_t i; + const struct timespec *timer; + + cuTimerStart(); + for (i = 0; i < cycles; i++){ + res = ccdGJKPenetration(o1, o2, ccd, &depth, &dir, &pos); + } + timer = cuTimerStop(); + fprintf(stdout, "%02d: %ld %ld\n", bench_num, + (long)timer->tv_sec, (long)timer->tv_nsec); + fflush(stdout); + + bench_num++; +} + +static void boxbox(void) +{ + fprintf(stdout, "%s:\n", __func__); + + ccd_t ccd; + CCD_BOX(box1); + CCD_BOX(box2); + ccd_vec3_t axis; + ccd_quat_t rot; + + box1.x = box1.y = box1.z = 1.; + box2.x = 0.5; + box2.y = 1.; + box2.z = 1.5; + + bench_num = 1; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + + runBench(&box1, &box2, &ccd); + runBench(&box2, &box1, &ccd); + + ccdVec3Set(&box1.pos, -0.3, 0.5, 1.); + runBench(&box1, &box2, &ccd); + runBench(&box2, &box1, &ccd); + + box1.x = box1.y = box1.z = 1.; + box2.x = box2.y = box2.z = 1.; + ccdVec3Set(&axis, 0., 0., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, 0., 0., 0.); + runBench(&box1, &box2, &ccd); + runBench(&box2, &box1, &ccd); + + box1.x = box1.y = box1.z = 1.; + box2.x = box2.y = box2.z = 1.; + ccdVec3Set(&axis, 0., 0., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, -0.5, 0., 0.); + runBench(&box1, &box2, &ccd); + runBench(&box2, &box1, &ccd); + + box1.x = box1.y = box1.z = 1.; + box2.x = box2.y = box2.z = 1.; + ccdVec3Set(&axis, 0., 0., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, -0.5, 0.5, 0.); + runBench(&box1, &box2, &ccd); + runBench(&box2, &box1, &ccd); + + box1.x = box1.y = box1.z = 1.; + ccdVec3Set(&axis, 0., 1., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, -0.5, 0.1, 0.4); + runBench(&box1, &box2, &ccd); + runBench(&box2, &box1, &ccd); + + box1.x = box1.y = box1.z = 1.; + ccdVec3Set(&axis, 0., 1., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&axis, 1., 1., 1.); + ccdQuatSetAngleAxis(&rot, M_PI / 4., &axis); + ccdQuatMul(&box1.quat, &rot); + ccdVec3Set(&box1.pos, -0.5, 0.1, 0.4); + runBench(&box1, &box2, &ccd); + runBench(&box2, &box1, &ccd); + + + box1.x = box1.y = box1.z = 1.; + box2.x = 0.2; box2.y = 0.5; box2.z = 1.; + box2.x = box2.y = box2.z = 1.; + + ccdVec3Set(&axis, 0., 0., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&axis, 1., 0., 0.); + ccdQuatSetAngleAxis(&rot, M_PI / 4., &axis); + ccdQuatMul(&box1.quat, &rot); + ccdVec3Set(&box1.pos, -1.3, 0., 0.); + + ccdVec3Set(&box2.pos, 0., 0., 0.); + runBench(&box1, &box2, &ccd); + runBench(&box2, &box1, &ccd); + + + fprintf(stdout, "\n----\n\n"); +} + +void cylcyl(void) +{ + fprintf(stdout, "%s:\n", __func__); + + ccd_t ccd; + CCD_CYL(cyl1); + CCD_CYL(cyl2); + ccd_vec3_t axis; + + cyl1.radius = 0.35; + cyl1.height = 0.5; + cyl2.radius = 0.5; + cyl2.height = 1.; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + + runBench(&cyl1, &cyl2, &ccd); + runBench(&cyl2, &cyl1, &ccd); + + ccdVec3Set(&cyl1.pos, 0.3, 0.1, 0.1); + runBench(&cyl1, &cyl2, &ccd); + runBench(&cyl2, &cyl1, &ccd); + + ccdVec3Set(&axis, 0., 1., 1.); + ccdQuatSetAngleAxis(&cyl2.quat, M_PI / 4., &axis); + ccdVec3Set(&cyl2.pos, 0., 0., 0.); + runBench(&cyl1, &cyl2, &ccd); + runBench(&cyl2, &cyl1, &ccd); + + ccdVec3Set(&axis, 0., 1., 1.); + ccdQuatSetAngleAxis(&cyl2.quat, M_PI / 4., &axis); + ccdVec3Set(&cyl2.pos, -0.2, 0.7, 0.2); + runBench(&cyl1, &cyl2, &ccd); + runBench(&cyl2, &cyl1, &ccd); + + ccdVec3Set(&axis, 0.567, 1.2, 1.); + ccdQuatSetAngleAxis(&cyl2.quat, M_PI / 4., &axis); + ccdVec3Set(&cyl2.pos, 0.6, -0.7, 0.2); + runBench(&cyl1, &cyl2, &ccd); + runBench(&cyl2, &cyl1, &ccd); + + ccdVec3Set(&axis, -4.567, 1.2, 0.); + ccdQuatSetAngleAxis(&cyl2.quat, M_PI / 3., &axis); + ccdVec3Set(&cyl2.pos, 0.6, -0.7, 0.2); + runBench(&cyl1, &cyl2, &ccd); + runBench(&cyl2, &cyl1, &ccd); + + fprintf(stdout, "\n----\n\n"); +} + +void boxcyl(void) +{ + fprintf(stdout, "%s:\n", __func__); + + ccd_t ccd; + CCD_BOX(box); + CCD_CYL(cyl); + ccd_vec3_t axis; + + box.x = 0.5; + box.y = 1.; + box.z = 1.5; + cyl.radius = 0.4; + cyl.height = 0.7; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + + runBench(&box, &cyl, &ccd); + runBench(&cyl, &box, &ccd); + + ccdVec3Set(&cyl.pos, .6, 0., 0.); + runBench(&box, &cyl, &ccd); + runBench(&cyl, &box, &ccd); + + ccdVec3Set(&cyl.pos, .6, 0.6, 0.); + runBench(&box, &cyl, &ccd); + runBench(&cyl, &box, &ccd); + + ccdVec3Set(&cyl.pos, .6, 0.6, 0.5); + runBench(&box, &cyl, &ccd); + runBench(&cyl, &box, &ccd); + + ccdVec3Set(&axis, 0., 1., 0.); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 3., &axis); + ccdVec3Set(&cyl.pos, .6, 0.6, 0.5); + runBench(&box, &cyl, &ccd); + runBench(&cyl, &box, &ccd); + + ccdVec3Set(&axis, 0.67, 1.1, 0.12); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 4., &axis); + ccdVec3Set(&cyl.pos, .6, 0., 0.5); + runBench(&box, &cyl, &ccd); + runBench(&cyl, &box, &ccd); + + ccdVec3Set(&axis, -0.1, 2.2, -1.); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 5., &axis); + ccdVec3Set(&cyl.pos, .6, 0., 0.5); + ccdVec3Set(&axis, 1., 1., 0.); + ccdQuatSetAngleAxis(&box.quat, -M_PI / 4., &axis); + ccdVec3Set(&box.pos, .6, 0., 0.5); + runBench(&box, &cyl, &ccd); + runBench(&cyl, &box, &ccd); + + ccdVec3Set(&axis, -0.1, 2.2, -1.); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 5., &axis); + ccdVec3Set(&cyl.pos, .6, 0., 0.5); + ccdVec3Set(&axis, 1., 1., 0.); + ccdQuatSetAngleAxis(&box.quat, -M_PI / 4., &axis); + ccdVec3Set(&box.pos, .9, 0.8, 0.5); + runBench(&box, &cyl, &ccd); + runBench(&cyl, &box, &ccd); + + fprintf(stdout, "\n----\n\n"); +} + +int main(int argc, char *argv[]) +{ + if (argc > 1){ + cycles = atol(argv[1]); + } + + fprintf(stdout, "Cycles: %zu\n", cycles); + fprintf(stdout, "\n"); + + boxbox(); + cylcyl(); + boxcyl(); + + return 0; +} diff --git a/libs/ode-0.16.1/libccd/src/testsuites/bench2.c b/libs/ode-0.16.1/libccd/src/testsuites/bench2.c new file mode 100644 index 0000000..8fb29df --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/bench2.c @@ -0,0 +1,263 @@ +#define CU_ENABLE_TIMER +#include +#include +#include +#include +#include "support.h" + +TEST_SUITES { + TEST_SUITES_CLOSURE +}; + +static int bench_num = 1; +static size_t cycles = 10000; + +static void runBench(const void *o1, const void *o2, const ccd_t *ccd) +{ + ccd_real_t depth; + ccd_vec3_t dir, pos; + int res; + size_t i; + const struct timespec *timer; + + cuTimerStart(); + for (i = 0; i < cycles; i++){ + res = ccdMPRPenetration(o1, o2, ccd, &depth, &dir, &pos); + } + timer = cuTimerStop(); + fprintf(stdout, "%02d: %ld %ld\n", bench_num, + (long)timer->tv_sec, (long)timer->tv_nsec); + fflush(stdout); + + bench_num++; +} + +static void boxbox(void) +{ + fprintf(stdout, "%s:\n", __func__); + + ccd_t ccd; + CCD_BOX(box1); + CCD_BOX(box2); + ccd_vec3_t axis; + ccd_quat_t rot; + + box1.x = box1.y = box1.z = 1.; + box2.x = 0.5; + box2.y = 1.; + box2.z = 1.5; + + bench_num = 1; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + ccd.center1 = ccdObjCenter; + ccd.center2 = ccdObjCenter; + + runBench(&box1, &box2, &ccd); + runBench(&box2, &box1, &ccd); + + ccdVec3Set(&box1.pos, -0.3, 0.5, 1.); + runBench(&box1, &box2, &ccd); + runBench(&box2, &box1, &ccd); + + box1.x = box1.y = box1.z = 1.; + box2.x = box2.y = box2.z = 1.; + ccdVec3Set(&axis, 0., 0., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, 0., 0., 0.); + runBench(&box1, &box2, &ccd); + runBench(&box2, &box1, &ccd); + + box1.x = box1.y = box1.z = 1.; + box2.x = box2.y = box2.z = 1.; + ccdVec3Set(&axis, 0., 0., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, -0.5, 0., 0.); + runBench(&box1, &box2, &ccd); + runBench(&box2, &box1, &ccd); + + box1.x = box1.y = box1.z = 1.; + box2.x = box2.y = box2.z = 1.; + ccdVec3Set(&axis, 0., 0., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, -0.5, 0.5, 0.); + runBench(&box1, &box2, &ccd); + runBench(&box2, &box1, &ccd); + + box1.x = box1.y = box1.z = 1.; + ccdVec3Set(&axis, 0., 1., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, -0.5, 0.1, 0.4); + runBench(&box1, &box2, &ccd); + runBench(&box2, &box1, &ccd); + + box1.x = box1.y = box1.z = 1.; + ccdVec3Set(&axis, 0., 1., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&axis, 1., 1., 1.); + ccdQuatSetAngleAxis(&rot, M_PI / 4., &axis); + ccdQuatMul(&box1.quat, &rot); + ccdVec3Set(&box1.pos, -0.5, 0.1, 0.4); + runBench(&box1, &box2, &ccd); + runBench(&box2, &box1, &ccd); + + + box1.x = box1.y = box1.z = 1.; + box2.x = 0.2; box2.y = 0.5; box2.z = 1.; + box2.x = box2.y = box2.z = 1.; + + ccdVec3Set(&axis, 0., 0., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&axis, 1., 0., 0.); + ccdQuatSetAngleAxis(&rot, M_PI / 4., &axis); + ccdQuatMul(&box1.quat, &rot); + ccdVec3Set(&box1.pos, -1.3, 0., 0.); + + ccdVec3Set(&box2.pos, 0., 0., 0.); + runBench(&box1, &box2, &ccd); + runBench(&box2, &box1, &ccd); + + + fprintf(stdout, "\n----\n\n"); +} + +void cylcyl(void) +{ + fprintf(stdout, "%s:\n", __func__); + + ccd_t ccd; + CCD_CYL(cyl1); + CCD_CYL(cyl2); + ccd_vec3_t axis; + + cyl1.radius = 0.35; + cyl1.height = 0.5; + cyl2.radius = 0.5; + cyl2.height = 1.; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + ccd.center1 = ccdObjCenter; + ccd.center2 = ccdObjCenter; + + runBench(&cyl1, &cyl2, &ccd); + runBench(&cyl2, &cyl1, &ccd); + + ccdVec3Set(&cyl1.pos, 0.3, 0.1, 0.1); + runBench(&cyl1, &cyl2, &ccd); + runBench(&cyl2, &cyl1, &ccd); + + ccdVec3Set(&axis, 0., 1., 1.); + ccdQuatSetAngleAxis(&cyl2.quat, M_PI / 4., &axis); + ccdVec3Set(&cyl2.pos, 0., 0., 0.); + runBench(&cyl1, &cyl2, &ccd); + runBench(&cyl2, &cyl1, &ccd); + + ccdVec3Set(&axis, 0., 1., 1.); + ccdQuatSetAngleAxis(&cyl2.quat, M_PI / 4., &axis); + ccdVec3Set(&cyl2.pos, -0.2, 0.7, 0.2); + runBench(&cyl1, &cyl2, &ccd); + runBench(&cyl2, &cyl1, &ccd); + + ccdVec3Set(&axis, 0.567, 1.2, 1.); + ccdQuatSetAngleAxis(&cyl2.quat, M_PI / 4., &axis); + ccdVec3Set(&cyl2.pos, 0.6, -0.7, 0.2); + runBench(&cyl1, &cyl2, &ccd); + runBench(&cyl2, &cyl1, &ccd); + + ccdVec3Set(&axis, -4.567, 1.2, 0.); + ccdQuatSetAngleAxis(&cyl2.quat, M_PI / 3., &axis); + ccdVec3Set(&cyl2.pos, 0.6, -0.7, 0.2); + runBench(&cyl1, &cyl2, &ccd); + runBench(&cyl2, &cyl1, &ccd); + + fprintf(stdout, "\n----\n\n"); +} + +void boxcyl(void) +{ + fprintf(stdout, "%s:\n", __func__); + + ccd_t ccd; + CCD_BOX(box); + CCD_CYL(cyl); + ccd_vec3_t axis; + + box.x = 0.5; + box.y = 1.; + box.z = 1.5; + cyl.radius = 0.4; + cyl.height = 0.7; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + ccd.center1 = ccdObjCenter; + ccd.center2 = ccdObjCenter; + + runBench(&box, &cyl, &ccd); + runBench(&cyl, &box, &ccd); + + ccdVec3Set(&cyl.pos, .6, 0., 0.); + runBench(&box, &cyl, &ccd); + runBench(&cyl, &box, &ccd); + + ccdVec3Set(&cyl.pos, .6, 0.6, 0.); + runBench(&box, &cyl, &ccd); + runBench(&cyl, &box, &ccd); + + ccdVec3Set(&cyl.pos, .6, 0.6, 0.5); + runBench(&box, &cyl, &ccd); + runBench(&cyl, &box, &ccd); + + ccdVec3Set(&axis, 0., 1., 0.); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 3., &axis); + ccdVec3Set(&cyl.pos, .6, 0.6, 0.5); + runBench(&box, &cyl, &ccd); + runBench(&cyl, &box, &ccd); + + ccdVec3Set(&axis, 0.67, 1.1, 0.12); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 4., &axis); + ccdVec3Set(&cyl.pos, .6, 0., 0.5); + runBench(&box, &cyl, &ccd); + runBench(&cyl, &box, &ccd); + + ccdVec3Set(&axis, -0.1, 2.2, -1.); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 5., &axis); + ccdVec3Set(&cyl.pos, .6, 0., 0.5); + ccdVec3Set(&axis, 1., 1., 0.); + ccdQuatSetAngleAxis(&box.quat, -M_PI / 4., &axis); + ccdVec3Set(&box.pos, .6, 0., 0.5); + runBench(&box, &cyl, &ccd); + runBench(&cyl, &box, &ccd); + + ccdVec3Set(&axis, -0.1, 2.2, -1.); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 5., &axis); + ccdVec3Set(&cyl.pos, .6, 0., 0.5); + ccdVec3Set(&axis, 1., 1., 0.); + ccdQuatSetAngleAxis(&box.quat, -M_PI / 4., &axis); + ccdVec3Set(&box.pos, .9, 0.8, 0.5); + runBench(&box, &cyl, &ccd); + runBench(&cyl, &box, &ccd); + + fprintf(stdout, "\n----\n\n"); +} + +int main(int argc, char *argv[]) +{ + if (argc > 1){ + cycles = atol(argv[1]); + } + + fprintf(stdout, "Cycles: %zu\n", cycles); + fprintf(stdout, "\n"); + + boxbox(); + cylcyl(); + boxcyl(); + + return 0; +} diff --git a/libs/ode-0.16.1/libccd/src/testsuites/boxbox.c b/libs/ode-0.16.1/libccd/src/testsuites/boxbox.c new file mode 100644 index 0000000..3dfc965 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/boxbox.c @@ -0,0 +1,467 @@ +#include +#include + +#include +#include "support.h" +#include +#include +#include "common.h" + + +TEST(boxboxSetUp) +{ +} + +TEST(boxboxTearDown) +{ +} + +TEST(boxboxAlignedX) +{ + size_t i; + ccd_t ccd; + CCD_BOX(box1); + CCD_BOX(box2); + int res; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + //ccd.max_iterations = 20; + + box1.x = 1; + box1.y = 2; + box1.z = 1; + box2.x = 2; + box2.y = 1; + box2.z = 2; + + ccdVec3Set(&box1.pos, -5., 0., 0.); + ccdVec3Set(&box2.pos, 0., 0., 0.); + ccdQuatSet(&box1.quat, 0., 0., 0., 1.); + ccdQuatSet(&box2.quat, 0., 0., 0., 1.); + for (i = 0; i < 100; i++){ + res = ccdGJKIntersect(&box1, &box2, &ccd); + if (i < 35 || i > 65){ + assertFalse(res); + }else if (i != 35 && i != 65){ + assertTrue(res); + } + + box1.pos.v[0] += 0.1; + } + + + box1.x = 0.1; + box1.y = 0.2; + box1.z = 0.1; + box2.x = 0.2; + box2.y = 0.1; + box2.z = 0.2; + + ccdVec3Set(&box1.pos, -0.5, 0., 0.); + ccdVec3Set(&box2.pos, 0., 0., 0.); + ccdQuatSet(&box1.quat, 0., 0., 0., 1.); + ccdQuatSet(&box2.quat, 0., 0., 0., 1.); + for (i = 0; i < 100; i++){ + res = ccdGJKIntersect(&box1, &box2, &ccd); + + if (i < 35 || i > 65){ + assertFalse(res); + }else if (i != 35 && i != 65){ + assertTrue(res); + } + + box1.pos.v[0] += 0.01; + } + + + box1.x = 1; + box1.y = 2; + box1.z = 1; + box2.x = 2; + box2.y = 1; + box2.z = 2; + + ccdVec3Set(&box1.pos, -5., -0.1, 0.); + ccdVec3Set(&box2.pos, 0., 0., 0.); + ccdQuatSet(&box1.quat, 0., 0., 0., 1.); + ccdQuatSet(&box2.quat, 0., 0., 0., 1.); + for (i = 0; i < 100; i++){ + res = ccdGJKIntersect(&box1, &box2, &ccd); + + if (i < 35 || i > 65){ + assertFalse(res); + }else if (i != 35 && i != 65){ + assertTrue(res); + } + + box1.pos.v[0] += 0.1; + } +} + +TEST(boxboxAlignedY) +{ + size_t i; + ccd_t ccd; + CCD_BOX(box1); + CCD_BOX(box2); + int res; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + + box1.x = 1; + box1.y = 2; + box1.z = 1; + box2.x = 2; + box2.y = 1; + box2.z = 2; + + ccdVec3Set(&box1.pos, 0., -5., 0.); + ccdVec3Set(&box2.pos, 0., 0., 0.); + ccdQuatSet(&box1.quat, 0., 0., 0., 1.); + ccdQuatSet(&box2.quat, 0., 0., 0., 1.); + for (i = 0; i < 100; i++){ + res = ccdGJKIntersect(&box1, &box2, &ccd); + + if (i < 35 || i > 65){ + assertFalse(res); + }else if (i != 35 && i != 65){ + assertTrue(res); + } + + box1.pos.v[1] += 0.1; + } +} + +TEST(boxboxAlignedZ) +{ + size_t i; + ccd_t ccd; + CCD_BOX(box1); + CCD_BOX(box2); + int res; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + + box1.x = 1; + box1.y = 2; + box1.z = 1; + box2.x = 2; + box2.y = 1; + box2.z = 2; + + ccdVec3Set(&box1.pos, 0., 0., -5.); + ccdVec3Set(&box2.pos, 0., 0., 0.); + ccdQuatSet(&box1.quat, 0., 0., 0., 1.); + ccdQuatSet(&box2.quat, 0., 0., 0., 1.); + for (i = 0; i < 100; i++){ + res = ccdGJKIntersect(&box1, &box2, &ccd); + + if (i < 35 || i > 65){ + assertFalse(res); + }else if (i != 35 && i != 65){ + assertTrue(res); + } + + box1.pos.v[2] += 0.1; + } +} + + +TEST(boxboxRot) +{ + size_t i; + ccd_t ccd; + CCD_BOX(box1); + CCD_BOX(box2); + int res; + ccd_vec3_t axis; + ccd_real_t angle; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + + box1.x = 1; + box1.y = 2; + box1.z = 1; + box2.x = 2; + box2.y = 1; + box2.z = 2; + + ccdVec3Set(&box1.pos, -5., 0.5, 0.); + ccdVec3Set(&box2.pos, 0., 0., 0.); + ccdQuatSet(&box2.quat, 0., 0., 0., 1.); + ccdVec3Set(&axis, 0., 1., 0.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + + for (i = 0; i < 100; i++){ + res = ccdGJKIntersect(&box1, &box2, &ccd); + + if (i < 33 || i > 67){ + assertFalse(res); + }else if (i != 33 && i != 67){ + assertTrue(res); + } + + box1.pos.v[0] += 0.1; + } + + box1.x = 1; + box1.y = 1; + box1.z = 1; + box2.x = 1; + box2.y = 1; + box2.z = 1; + + ccdVec3Set(&box1.pos, -1.01, 0., 0.); + ccdVec3Set(&box2.pos, 0., 0., 0.); + ccdQuatSet(&box1.quat, 0., 0., 0., 1.); + ccdQuatSet(&box2.quat, 0., 0., 0., 1.); + + ccdVec3Set(&axis, 0., 1., 0.); + angle = 0.; + for (i = 0; i < 30; i++){ + res = ccdGJKIntersect(&box1, &box2, &ccd); + + if (i != 0 && i != 10 && i != 20){ + assertTrue(res); + }else{ + assertFalse(res); + } + + angle += M_PI / 20.; + ccdQuatSetAngleAxis(&box1.quat, angle, &axis); + } + +} + + + +static void pConf(ccd_box_t *box1, ccd_box_t *box2, const ccd_vec3_t *v) +{ + fprintf(stdout, "# box1.pos: [%lf %lf %lf]\n", + ccdVec3X(&box1->pos), ccdVec3Y(&box1->pos), ccdVec3Z(&box1->pos)); + fprintf(stdout, "# box1->quat: [%lf %lf %lf %lf]\n", + box1->quat.q[0], box1->quat.q[1], box1->quat.q[2], box1->quat.q[3]); + fprintf(stdout, "# box2->pos: [%lf %lf %lf]\n", + ccdVec3X(&box2->pos), ccdVec3Y(&box2->pos), ccdVec3Z(&box2->pos)); + fprintf(stdout, "# box2->quat: [%lf %lf %lf %lf]\n", + box2->quat.q[0], box2->quat.q[1], box2->quat.q[2], box2->quat.q[3]); + fprintf(stdout, "# sep: [%lf %lf %lf]\n", + ccdVec3X(v), ccdVec3Y(v), ccdVec3Z(v)); + fprintf(stdout, "#\n"); +} + +TEST(boxboxSeparate) +{ + ccd_t ccd; + CCD_BOX(box1); + CCD_BOX(box2); + int res; + ccd_vec3_t sep, expsep, expsep2, axis; + + fprintf(stderr, "\n\n\n---- boxboxSeparate ----\n\n\n"); + + box1.x = box1.y = box1.z = 1.; + box2.x = 0.5; + box2.y = 1.; + box2.z = 1.5; + + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + + ccdVec3Set(&box1.pos, -0.5, 0.5, 0.2); + res = ccdGJKIntersect(&box1, &box2, &ccd); + assertTrue(res); + + res = ccdGJKSeparate(&box1, &box2, &ccd, &sep); + assertTrue(res == 0); + ccdVec3Set(&expsep, 0.25, 0., 0.); + assertTrue(ccdVec3Eq(&sep, &expsep)); + + ccdVec3Scale(&sep, -1.); + ccdVec3Add(&box1.pos, &sep); + res = ccdGJKSeparate(&box1, &box2, &ccd, &sep); + assertTrue(res == 0); + ccdVec3Set(&expsep, 0., 0., 0.); + assertTrue(ccdVec3Eq(&sep, &expsep)); + + + ccdVec3Set(&box1.pos, -0.3, 0.5, 1.); + res = ccdGJKSeparate(&box1, &box2, &ccd, &sep); + assertTrue(res == 0); + ccdVec3Set(&expsep, 0., 0., -0.25); + assertTrue(ccdVec3Eq(&sep, &expsep)); + + + + box1.x = box1.y = box1.z = 1.; + box2.x = box2.y = box2.z = 1.; + ccdVec3Set(&axis, 0., 0., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, 0., 0., 0.); + + res = ccdGJKSeparate(&box1, &box2, &ccd, &sep); + assertTrue(res == 0); + ccdVec3Set(&expsep, 0., 0., 1.); + ccdVec3Set(&expsep2, 0., 0., -1.); + assertTrue(ccdVec3Eq(&sep, &expsep) || ccdVec3Eq(&sep, &expsep2)); + + + + box1.x = box1.y = box1.z = 1.; + ccdVec3Set(&axis, 0., 0., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, -0.5, 0., 0.); + + res = ccdGJKSeparate(&box1, &box2, &ccd, &sep); + assertTrue(res == 0); + pConf(&box1, &box2, &sep); + + + + box1.x = box1.y = box1.z = 1.; + ccdVec3Set(&axis, 0., 1., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, -0.5, 0.1, 0.4); + + res = ccdGJKSeparate(&box1, &box2, &ccd, &sep); + assertTrue(res == 0); + pConf(&box1, &box2, &sep); +} + + +#define TOSVT() \ + svtObjPen(&box1, &box2, stdout, "Pen 1", depth, &dir, &pos); \ + ccdVec3Scale(&dir, depth); \ + ccdVec3Add(&box2.pos, &dir); \ + svtObjPen(&box1, &box2, stdout, "Pen 1", depth, &dir, &pos) + +TEST(boxboxPenetration) +{ + ccd_t ccd; + CCD_BOX(box1); + CCD_BOX(box2); + int res; + ccd_vec3_t axis; + ccd_quat_t rot; + ccd_real_t depth; + ccd_vec3_t dir, pos; + + fprintf(stderr, "\n\n\n---- boxboxPenetration ----\n\n\n"); + + box1.x = box1.y = box1.z = 1.; + box2.x = 0.5; + box2.y = 1.; + box2.z = 1.5; + + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + + ccdVec3Set(&box2.pos, 0.1, 0., 0.); + res = ccdGJKPenetration(&box1, &box2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 1"); + //TOSVT(); + + + ccdVec3Set(&box1.pos, -0.3, 0.5, 1.); + res = ccdGJKPenetration(&box1, &box2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 2"); + //TOSVT(); <<< + + + box1.x = box1.y = box1.z = 1.; + box2.x = box2.y = box2.z = 1.; + ccdVec3Set(&axis, 0., 0., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, 0.1, 0., 0.1); + + res = ccdGJKPenetration(&box1, &box2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 3"); + //TOSVT(); + + + box1.x = box1.y = box1.z = 1.; + box2.x = box2.y = box2.z = 1.; + ccdVec3Set(&axis, 0., 0., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, -0.5, 0., 0.); + + res = ccdGJKPenetration(&box1, &box2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 4"); + //TOSVT(); + + + box1.x = box1.y = box1.z = 1.; + box2.x = box2.y = box2.z = 1.; + ccdVec3Set(&axis, 0., 0., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, -0.5, 0.5, 0.); + + res = ccdGJKPenetration(&box1, &box2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 5"); + //TOSVT(); + + + box1.x = box1.y = box1.z = 1.; + box2.x = box2.y = box2.z = 1.; + ccdVec3Set(&box2.pos, 0.1, 0., 0.); + + box1.x = box1.y = box1.z = 1.; + ccdVec3Set(&axis, 0., 1., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, -0.5, 0.1, 0.4); + + res = ccdGJKPenetration(&box1, &box2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 6"); + //TOSVT(); + + + box1.x = box1.y = box1.z = 1.; + ccdVec3Set(&axis, 0., 1., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&axis, 1., 1., 1.); + ccdQuatSetAngleAxis(&rot, M_PI / 4., &axis); + ccdQuatMul(&box1.quat, &rot); + ccdVec3Set(&box1.pos, -0.5, 0.1, 0.4); + + res = ccdGJKPenetration(&box1, &box2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 7"); + //TOSVT(); <<< + + + box1.x = box1.y = box1.z = 1.; + box2.x = 0.2; box2.y = 0.5; box2.z = 1.; + box2.x = box2.y = box2.z = 1.; + + ccdVec3Set(&axis, 0., 0., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&axis, 1., 0., 0.); + ccdQuatSetAngleAxis(&rot, M_PI / 4., &axis); + ccdQuatMul(&box1.quat, &rot); + ccdVec3Set(&box1.pos, -1.3, 0., 0.); + + ccdVec3Set(&box2.pos, 0., 0., 0.); + + res = ccdGJKPenetration(&box1, &box2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 8"); + //TOSVT(); +} diff --git a/libs/ode-0.16.1/libccd/src/testsuites/boxbox.h b/libs/ode-0.16.1/libccd/src/testsuites/boxbox.h new file mode 100644 index 0000000..8127c7c --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/boxbox.h @@ -0,0 +1,32 @@ +#ifndef BOX_BOX +#define BOX_BOX + +#include + +TEST(boxboxSetUp); +TEST(boxboxTearDown); + +TEST(boxboxAlignedX); +TEST(boxboxAlignedY); +TEST(boxboxAlignedZ); + +TEST(boxboxRot); + +TEST(boxboxSeparate); +TEST(boxboxPenetration); + +TEST_SUITE(TSBoxBox) { + TEST_ADD(boxboxSetUp), + + TEST_ADD(boxboxAlignedX), + TEST_ADD(boxboxAlignedY), + TEST_ADD(boxboxAlignedZ), + TEST_ADD(boxboxRot), + TEST_ADD(boxboxSeparate), + TEST_ADD(boxboxPenetration), + + TEST_ADD(boxboxTearDown), + TEST_SUITE_CLOSURE +}; + +#endif diff --git a/libs/ode-0.16.1/libccd/src/testsuites/boxcyl.c b/libs/ode-0.16.1/libccd/src/testsuites/boxcyl.c new file mode 100644 index 0000000..4a556cb --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/boxcyl.c @@ -0,0 +1,162 @@ +#include +#include "common.h" +#include +#include "support.h" + + +#define TOSVT() \ + svtObjPen(&box, &cyl, stdout, "Pen 1", depth, &dir, &pos); \ + ccdVec3Scale(&dir, depth); \ + ccdVec3Add(&cyl.pos, &dir); \ + svtObjPen(&box, &cyl, stdout, "Pen 1", depth, &dir, &pos) + + +TEST(boxcylIntersect) +{ + ccd_t ccd; + CCD_BOX(box); + CCD_CYL(cyl); + int res; + ccd_vec3_t axis; + + box.x = 0.5; + box.y = 1.; + box.z = 1.5; + cyl.radius = 0.4; + cyl.height = 0.7; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + + ccdVec3Set(&cyl.pos, 0.1, 0., 0.); + res = ccdGJKIntersect(&box, &cyl, &ccd); + assertTrue(res); + + ccdVec3Set(&cyl.pos, .6, 0., 0.); + res = ccdGJKIntersect(&box, &cyl, &ccd); + assertTrue(res); + + ccdVec3Set(&cyl.pos, .6, 0.6, 0.); + res = ccdGJKIntersect(&box, &cyl, &ccd); + assertTrue(res); + + ccdVec3Set(&cyl.pos, .6, 0.6, 0.5); + res = ccdGJKIntersect(&box, &cyl, &ccd); + assertTrue(res); + + ccdVec3Set(&axis, 0., 1., 0.); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 3., &axis); + ccdVec3Set(&cyl.pos, .6, 0.6, 0.5); + res = ccdGJKIntersect(&box, &cyl, &ccd); + assertTrue(res); + + ccdVec3Set(&axis, 0.67, 1.1, 0.12); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 4., &axis); + ccdVec3Set(&cyl.pos, .6, 0., 0.5); + res = ccdGJKIntersect(&box, &cyl, &ccd); + assertTrue(res); + + ccdVec3Set(&axis, -0.1, 2.2, -1.); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 5., &axis); + ccdVec3Set(&cyl.pos, .6, 0., 0.5); + ccdVec3Set(&axis, 1., 1., 0.); + ccdQuatSetAngleAxis(&box.quat, -M_PI / 4., &axis); + ccdVec3Set(&box.pos, .6, 0., 0.5); + res = ccdGJKIntersect(&box, &cyl, &ccd); + assertTrue(res); + + ccdVec3Set(&axis, -0.1, 2.2, -1.); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 5., &axis); + ccdVec3Set(&cyl.pos, .6, 0., 0.5); + ccdVec3Set(&axis, 1., 1., 0.); + ccdQuatSetAngleAxis(&box.quat, -M_PI / 4., &axis); + ccdVec3Set(&box.pos, .9, 0.8, 0.5); + res = ccdGJKIntersect(&box, &cyl, &ccd); + assertTrue(res); +} + + +TEST(boxcylPenEPA) +{ + ccd_t ccd; + CCD_BOX(box); + CCD_CYL(cyl); + int res; + ccd_vec3_t axis; + ccd_real_t depth; + ccd_vec3_t dir, pos; + + box.x = 0.5; + box.y = 1.; + box.z = 1.5; + cyl.radius = 0.4; + cyl.height = 0.7; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + + ccdVec3Set(&cyl.pos, 0.1, 0., 0.); + res = ccdGJKPenetration(&box, &cyl, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 1"); + //TOSVT(); + + ccdVec3Set(&cyl.pos, .6, 0., 0.); + res = ccdGJKPenetration(&box, &cyl, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 2"); + //TOSVT(); <<< + + ccdVec3Set(&cyl.pos, .6, 0.6, 0.); + res = ccdGJKPenetration(&box, &cyl, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 3"); + //TOSVT(); + + ccdVec3Set(&cyl.pos, .6, 0.6, 0.5); + res = ccdGJKPenetration(&box, &cyl, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 4"); + //TOSVT(); + + ccdVec3Set(&axis, 0., 1., 0.); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 3., &axis); + ccdVec3Set(&cyl.pos, .6, 0.6, 0.5); + res = ccdGJKPenetration(&box, &cyl, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 5"); + //TOSVT(); + + ccdVec3Set(&axis, 0.67, 1.1, 0.12); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 4., &axis); + ccdVec3Set(&cyl.pos, .6, 0., 0.5); + res = ccdGJKPenetration(&box, &cyl, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 6"); + //TOSVT(); + + ccdVec3Set(&axis, -0.1, 2.2, -1.); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 5., &axis); + ccdVec3Set(&cyl.pos, .6, 0., 0.5); + ccdVec3Set(&axis, 1., 1., 0.); + ccdQuatSetAngleAxis(&box.quat, -M_PI / 4., &axis); + ccdVec3Set(&box.pos, .6, 0., 0.5); + res = ccdGJKPenetration(&box, &cyl, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 7"); + //TOSVT(); + + ccdVec3Set(&axis, -0.1, 2.2, -1.); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 5., &axis); + ccdVec3Set(&cyl.pos, .6, 0., 0.5); + ccdVec3Set(&axis, 1., 1., 0.); + ccdQuatSetAngleAxis(&box.quat, -M_PI / 4., &axis); + ccdVec3Set(&box.pos, .9, 0.8, 0.5); + res = ccdGJKPenetration(&box, &cyl, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 8"); + //TOSVT(); +} + diff --git a/libs/ode-0.16.1/libccd/src/testsuites/boxcyl.h b/libs/ode-0.16.1/libccd/src/testsuites/boxcyl.h new file mode 100644 index 0000000..3d348d9 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/boxcyl.h @@ -0,0 +1,16 @@ +#ifndef TEST_BOXCYL_H +#define TEST_BOXCYL_H + +#include + +TEST(boxcylIntersect); +TEST(boxcylPenEPA); + +TEST_SUITE(TSBoxCyl){ + TEST_ADD(boxcylIntersect), + TEST_ADD(boxcylPenEPA), + + TEST_SUITE_CLOSURE +}; + +#endif diff --git a/libs/ode-0.16.1/libccd/src/testsuites/common.c b/libs/ode-0.16.1/libccd/src/testsuites/common.c new file mode 100644 index 0000000..eca7776 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/common.c @@ -0,0 +1,174 @@ +#include "common.h" +#include +#include +#include "support.h" + +static void svtCyl(ccd_cyl_t *c, FILE *out, const char *color, const char *name) +{ + ccd_vec3_t v[32]; + ccd_quat_t rot; + ccd_vec3_t axis, vpos, vpos2; + ccd_real_t angle, x, y; + unsigned int i; + + ccdVec3Set(&axis, 0., 0., 1.); + ccdVec3Set(&vpos, 0., c->radius, 0.); + angle = 0.; + for (i = 0; i < 16; i++){ + angle = (ccd_real_t)i * (2. * M_PI / 16.); + + ccdQuatSetAngleAxis(&rot, angle, &axis); + ccdVec3Copy(&vpos2, &vpos); + ccdQuatRotVec(&vpos2, &rot); + x = ccdVec3X(&vpos2); + y = ccdVec3Y(&vpos2); + + ccdVec3Set(&v[i], x, y, c->height / 2.); + ccdVec3Set(&v[i + 16], x, y, -c->height / 2.); + } + + for (i = 0; i < 32; i++){ + ccdQuatRotVec(&v[i], &c->quat); + ccdVec3Add(&v[i], &c->pos); + } + + fprintf(out, "-----\n"); + if (name) + fprintf(out, "Name: %s\n", name); + + fprintf(out, "Face color: %s\n", color); + fprintf(out, "Edge color: %s\n", color); + fprintf(out, "Point color: %s\n", color); + fprintf(out, "Points:\n"); + for (i = 0; i < 32; i++){ + fprintf(out, "%lf %lf %lf\n", ccdVec3X(&v[i]), ccdVec3Y(&v[i]), ccdVec3Z(&v[i])); + } + + fprintf(out, "Edges:\n"); + fprintf(out, "0 16\n"); + fprintf(out, "0 31\n"); + for (i = 1; i < 16; i++){ + fprintf(out, "0 %d\n", i); + fprintf(out, "16 %d\n", i + 16); + if (i != 0){ + fprintf(out, "%d %d\n", i - 1, i); + fprintf(out, "%d %d\n", i + 16 - 1, i + 16); + } + + fprintf(out, "%d %d\n", i, i + 16); + fprintf(out, "%d %d\n", i, i + 16 - 1); + } + + fprintf(out, "Faces:\n"); + for (i = 2; i < 16; i++){ + fprintf(out, "0 %d %d\n", i, i -1); + fprintf(out, "16 %d %d\n", i + 16, i + 16 -1); + + } + fprintf(out, "0 16 31\n"); + fprintf(out, "0 31 15\n"); + for (i = 1; i < 16; i++){ + fprintf(out, "%d %d %d\n", i, i + 16, i + 16 - 1); + fprintf(out, "%d %d %d\n", i, i + 16 - 1, i - 1); + } + fprintf(out, "-----\n"); +} + +static void svtBox(ccd_box_t *b, FILE *out, const char *color, const char *name) +{ + ccd_vec3_t v[8]; + size_t i; + + ccdVec3Set(&v[0], b->x * 0.5, b->y * 0.5, b->z * 0.5); + ccdVec3Set(&v[1], b->x * 0.5, b->y * -0.5, b->z * 0.5); + ccdVec3Set(&v[2], b->x * 0.5, b->y * 0.5, b->z * -0.5); + ccdVec3Set(&v[3], b->x * 0.5, b->y * -0.5, b->z * -0.5); + ccdVec3Set(&v[4], b->x * -0.5, b->y * 0.5, b->z * 0.5); + ccdVec3Set(&v[5], b->x * -0.5, b->y * -0.5, b->z * 0.5); + ccdVec3Set(&v[6], b->x * -0.5, b->y * 0.5, b->z * -0.5); + ccdVec3Set(&v[7], b->x * -0.5, b->y * -0.5, b->z * -0.5); + + for (i = 0; i < 8; i++){ + ccdQuatRotVec(&v[i], &b->quat); + ccdVec3Add(&v[i], &b->pos); + } + + fprintf(out, "-----\n"); + if (name) + fprintf(out, "Name: %s\n", name); + fprintf(out, "Face color: %s\n", color); + fprintf(out, "Edge color: %s\n", color); + fprintf(out, "Point color: %s\n", color); + fprintf(out, "Points:\n"); + for (i = 0; i < 8; i++){ + fprintf(out, "%lf %lf %lf\n", ccdVec3X(&v[i]), ccdVec3Y(&v[i]), ccdVec3Z(&v[i])); + } + + fprintf(out, "Edges:\n"); + fprintf(out, "0 1\n 0 2\n2 3\n3 1\n1 2\n6 2\n1 7\n1 5\n"); + fprintf(out, "5 0\n0 4\n4 2\n6 4\n6 5\n5 7\n6 7\n7 2\n7 3\n4 5\n"); + + fprintf(out, "Faces:\n"); + fprintf(out, "0 2 1\n1 2 3\n6 2 4\n4 2 0\n4 0 5\n5 0 1\n"); + fprintf(out, "5 1 7\n7 1 3\n6 4 5\n6 5 7\n2 6 7\n2 7 3\n"); + fprintf(out, "-----\n"); +} + + +void svtObj(void *_o, FILE *out, const char *color, const char *name) +{ + ccd_obj_t *o = (ccd_obj_t *)_o; + + if (o->type == CCD_OBJ_CYL){ + svtCyl((ccd_cyl_t *)o, out, color, name); + }else if (o->type == CCD_OBJ_BOX){ + svtBox((ccd_box_t *)o, out, color, name); + } +} + +void svtObjPen(void *o1, void *o2, + FILE *out, const char *name, + ccd_real_t depth, const ccd_vec3_t *dir, const ccd_vec3_t *pos) +{ + ccd_vec3_t sep; + char oname[500]; + + ccdVec3Copy(&sep, dir); + ccdVec3Scale(&sep, depth); + ccdVec3Add(&sep, pos); + + fprintf(out, "------\n"); + if (name) + fprintf(out, "Name: %s\n", name); + fprintf(out, "Point color: 0.1 0.1 0.9\n"); + fprintf(out, "Points:\n%lf %lf %lf\n", ccdVec3X(pos), ccdVec3Y(pos), ccdVec3Z(pos)); + fprintf(out, "------\n"); + fprintf(out, "Point color: 0.1 0.9 0.9\n"); + fprintf(out, "Edge color: 0.1 0.9 0.9\n"); + fprintf(out, "Points:\n%lf %lf %lf\n", ccdVec3X(pos), ccdVec3Y(pos), ccdVec3Z(pos)); + fprintf(out, "%lf %lf %lf\n", ccdVec3X(&sep), ccdVec3Y(&sep), ccdVec3Z(&sep)); + fprintf(out, "Edges: 0 1\n"); + + oname[0] = 0x0; + if (name) + sprintf(oname, "%s o1", name); + svtObj(o1, out, "0.9 0.1 0.1", oname); + + oname[0] = 0x0; + if (name) + sprintf(oname, "%s o1", name); + svtObj(o2, out, "0.1 0.9 0.1", oname); +} + + +void recPen(ccd_real_t depth, const ccd_vec3_t *dir, const ccd_vec3_t *pos, + FILE *out, const char *note) +{ + if (!note) + note = ""; + + fprintf(out, "# %s: depth: %lf\n", note, depth); + fprintf(out, "# %s: dir: [%lf %lf %lf]\n", note, ccdVec3X(dir), ccdVec3Y(dir), ccdVec3Z(dir)); + fprintf(out, "# %s: pos: [%lf %lf %lf]\n", note, ccdVec3X(pos), ccdVec3Y(pos), ccdVec3Z(pos)); + fprintf(out, "#\n"); +} diff --git a/libs/ode-0.16.1/libccd/src/testsuites/common.h b/libs/ode-0.16.1/libccd/src/testsuites/common.h new file mode 100644 index 0000000..a4de4c2 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/common.h @@ -0,0 +1,14 @@ +#ifndef TEST_COMMON +#define TEST_COMMON + +#include +#include + +void svtObj(void *o, FILE *out, const char *color, const char *name); +void svtObjPen(void *o1, void *o2, + FILE *out, const char *name, + ccd_real_t depth, const ccd_vec3_t *dir, const ccd_vec3_t *pos); +void recPen(ccd_real_t depth, const ccd_vec3_t *dir, const ccd_vec3_t *pos, + FILE *out, const char *note); + +#endif diff --git a/libs/ode-0.16.1/libccd/src/testsuites/cu/COPYING b/libs/ode-0.16.1/libccd/src/testsuites/cu/COPYING new file mode 100644 index 0000000..94a9ed0 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/cu/COPYING @@ -0,0 +1,674 @@ + GNU GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 + + Copyright (C) 2007 Free Software Foundation, Inc. + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The GNU General Public License is a free, copyleft license for +software and other kinds of works. + + The licenses for most software and other practical works are designed +to take away your freedom to share and change the works. By contrast, +the GNU General Public License is intended to guarantee your freedom to +share and change all versions of a program--to make sure it remains free +software for all its users. We, the Free Software Foundation, use the +GNU General Public License for most of our software; it applies also to +any other work released this way by its authors. You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +them if you wish), that you receive source code or can get it if you +want it, that you can change the software or use pieces of it in new +free programs, and that you know you can do these things. + + To protect your rights, we need to prevent others from denying you +these rights or asking you to surrender the rights. Therefore, you have +certain responsibilities if you distribute copies of the software, or if +you modify it: responsibilities to respect the freedom of others. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must pass on to the recipients the same +freedoms that you received. You must make sure that they, too, receive +or can get the source code. And you must show them these terms so they +know their rights. + + Developers that use the GNU GPL protect your rights with two steps: +(1) assert copyright on the software, and (2) offer you this License +giving you legal permission to copy, distribute and/or modify it. + + For the developers' and authors' protection, the GPL clearly explains +that there is no warranty for this free software. For both users' and +authors' sake, the GPL requires that modified versions be marked as +changed, so that their problems will not be attributed erroneously to +authors of previous versions. + + Some devices are designed to deny users access to install or run +modified versions of the software inside them, although the manufacturer +can do so. This is fundamentally incompatible with the aim of +protecting users' freedom to change the software. The systematic +pattern of such abuse occurs in the area of products for individuals to +use, which is precisely where it is most unacceptable. Therefore, we +have designed this version of the GPL to prohibit the practice for those +products. If such problems arise substantially in other domains, we +stand ready to extend this provision to those domains in future versions +of the GPL, as needed to protect the freedom of users. + + Finally, every program is threatened constantly by software patents. +States should not allow patents to restrict development and use of +software on general-purpose computers, but in those that do, we wish to +avoid the special danger that patents applied to a free program could +make it effectively proprietary. To prevent this, the GPL assures that +patents cannot be used to render the program non-free. + + The precise terms and conditions for copying, distribution and +modification follow. + + TERMS AND CONDITIONS + + 0. Definitions. + + "This License" refers to version 3 of the GNU General Public License. + + "Copyright" also means copyright-like laws that apply to other kinds of +works, such as semiconductor masks. + + "The Program" refers to any copyrightable work licensed under this +License. Each licensee is addressed as "you". "Licensees" and +"recipients" may be individuals or organizations. + + To "modify" a work means to copy from or adapt all or part of the work +in a fashion requiring copyright permission, other than the making of an +exact copy. The resulting work is called a "modified version" of the +earlier work or a work "based on" the earlier work. + + A "covered work" means either the unmodified Program or a work based +on the Program. + + To "propagate" a work means to do anything with it that, without +permission, would make you directly or secondarily liable for +infringement under applicable copyright law, except executing it on a +computer or modifying a private copy. Propagation includes copying, +distribution (with or without modification), making available to the +public, and in some countries other activities as well. + + To "convey" a work means any kind of propagation that enables other +parties to make or receive copies. Mere interaction with a user through +a computer network, with no transfer of a copy, is not conveying. + + An interactive user interface displays "Appropriate Legal Notices" +to the extent that it includes a convenient and prominently visible +feature that (1) displays an appropriate copyright notice, and (2) +tells the user that there is no warranty for the work (except to the +extent that warranties are provided), that licensees may convey the +work under this License, and how to view a copy of this License. If +the interface presents a list of user commands or options, such as a +menu, a prominent item in the list meets this criterion. + + 1. Source Code. + + The "source code" for a work means the preferred form of the work +for making modifications to it. "Object code" means any non-source +form of a work. + + A "Standard Interface" means an interface that either is an official +standard defined by a recognized standards body, or, in the case of +interfaces specified for a particular programming language, one that +is widely used among developers working in that language. + + The "System Libraries" of an executable work include anything, other +than the work as a whole, that (a) is included in the normal form of +packaging a Major Component, but which is not part of that Major +Component, and (b) serves only to enable use of the work with that +Major Component, or to implement a Standard Interface for which an +implementation is available to the public in source code form. A +"Major Component", in this context, means a major essential component +(kernel, window system, and so on) of the specific operating system +(if any) on which the executable work runs, or a compiler used to +produce the work, or an object code interpreter used to run it. + + The "Corresponding Source" for a work in object code form means all +the source code needed to generate, install, and (for an executable +work) run the object code and to modify the work, including scripts to +control those activities. However, it does not include the work's +System Libraries, or general-purpose tools or generally available free +programs which are used unmodified in performing those activities but +which are not part of the work. For example, Corresponding Source +includes interface definition files associated with source files for +the work, and the source code for shared libraries and dynamically +linked subprograms that the work is specifically designed to require, +such as by intimate data communication or control flow between those +subprograms and other parts of the work. + + The Corresponding Source need not include anything that users +can regenerate automatically from other parts of the Corresponding +Source. + + The Corresponding Source for a work in source code form is that +same work. + + 2. Basic Permissions. + + All rights granted under this License are granted for the term of +copyright on the Program, and are irrevocable provided the stated +conditions are met. This License explicitly affirms your unlimited +permission to run the unmodified Program. The output from running a +covered work is covered by this License only if the output, given its +content, constitutes a covered work. This License acknowledges your +rights of fair use or other equivalent, as provided by copyright law. + + You may make, run and propagate covered works that you do not +convey, without conditions so long as your license otherwise remains +in force. You may convey covered works to others for the sole purpose +of having them make modifications exclusively for you, or provide you +with facilities for running those works, provided that you comply with +the terms of this License in conveying all material for which you do +not control copyright. Those thus making or running the covered works +for you must do so exclusively on your behalf, under your direction +and control, on terms that prohibit them from making any copies of +your copyrighted material outside their relationship with you. + + Conveying under any other circumstances is permitted solely under +the conditions stated below. Sublicensing is not allowed; section 10 +makes it unnecessary. + + 3. Protecting Users' Legal Rights From Anti-Circumvention Law. + + No covered work shall be deemed part of an effective technological +measure under any applicable law fulfilling obligations under article +11 of the WIPO copyright treaty adopted on 20 December 1996, or +similar laws prohibiting or restricting circumvention of such +measures. + + When you convey a covered work, you waive any legal power to forbid +circumvention of technological measures to the extent such circumvention +is effected by exercising rights under this License with respect to +the covered work, and you disclaim any intention to limit operation or +modification of the work as a means of enforcing, against the work's +users, your or third parties' legal rights to forbid circumvention of +technological measures. + + 4. Conveying Verbatim Copies. + + You may convey verbatim copies of the Program's source code as you +receive it, in any medium, provided that you conspicuously and +appropriately publish on each copy an appropriate copyright notice; +keep intact all notices stating that this License and any +non-permissive terms added in accord with section 7 apply to the code; +keep intact all notices of the absence of any warranty; and give all +recipients a copy of this License along with the Program. + + You may charge any price or no price for each copy that you convey, +and you may offer support or warranty protection for a fee. + + 5. Conveying Modified Source Versions. + + You may convey a work based on the Program, or the modifications to +produce it from the Program, in the form of source code under the +terms of section 4, provided that you also meet all of these conditions: + + a) The work must carry prominent notices stating that you modified + it, and giving a relevant date. + + b) The work must carry prominent notices stating that it is + released under this License and any conditions added under section + 7. This requirement modifies the requirement in section 4 to + "keep intact all notices". + + c) You must license the entire work, as a whole, under this + License to anyone who comes into possession of a copy. This + License will therefore apply, along with any applicable section 7 + additional terms, to the whole of the work, and all its parts, + regardless of how they are packaged. This License gives no + permission to license the work in any other way, but it does not + invalidate such permission if you have separately received it. + + d) If the work has interactive user interfaces, each must display + Appropriate Legal Notices; however, if the Program has interactive + interfaces that do not display Appropriate Legal Notices, your + work need not make them do so. + + A compilation of a covered work with other separate and independent +works, which are not by their nature extensions of the covered work, +and which are not combined with it such as to form a larger program, +in or on a volume of a storage or distribution medium, is called an +"aggregate" if the compilation and its resulting copyright are not +used to limit the access or legal rights of the compilation's users +beyond what the individual works permit. Inclusion of a covered work +in an aggregate does not cause this License to apply to the other +parts of the aggregate. + + 6. Conveying Non-Source Forms. + + You may convey a covered work in object code form under the terms +of sections 4 and 5, provided that you also convey the +machine-readable Corresponding Source under the terms of this License, +in one of these ways: + + a) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by the + Corresponding Source fixed on a durable physical medium + customarily used for software interchange. + + b) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by a + written offer, valid for at least three years and valid for as + long as you offer spare parts or customer support for that product + model, to give anyone who possesses the object code either (1) a + copy of the Corresponding Source for all the software in the + product that is covered by this License, on a durable physical + medium customarily used for software interchange, for a price no + more than your reasonable cost of physically performing this + conveying of source, or (2) access to copy the + Corresponding Source from a network server at no charge. + + c) Convey individual copies of the object code with a copy of the + written offer to provide the Corresponding Source. This + alternative is allowed only occasionally and noncommercially, and + only if you received the object code with such an offer, in accord + with subsection 6b. + + d) Convey the object code by offering access from a designated + place (gratis or for a charge), and offer equivalent access to the + Corresponding Source in the same way through the same place at no + further charge. You need not require recipients to copy the + Corresponding Source along with the object code. If the place to + copy the object code is a network server, the Corresponding Source + may be on a different server (operated by you or a third party) + that supports equivalent copying facilities, provided you maintain + clear directions next to the object code saying where to find the + Corresponding Source. Regardless of what server hosts the + Corresponding Source, you remain obligated to ensure that it is + available for as long as needed to satisfy these requirements. + + e) Convey the object code using peer-to-peer transmission, provided + you inform other peers where the object code and Corresponding + Source of the work are being offered to the general public at no + charge under subsection 6d. + + A separable portion of the object code, whose source code is excluded +from the Corresponding Source as a System Library, need not be +included in conveying the object code work. + + A "User Product" is either (1) a "consumer product", which means any +tangible personal property which is normally used for personal, family, +or household purposes, or (2) anything designed or sold for incorporation +into a dwelling. In determining whether a product is a consumer product, +doubtful cases shall be resolved in favor of coverage. For a particular +product received by a particular user, "normally used" refers to a +typical or common use of that class of product, regardless of the status +of the particular user or of the way in which the particular user +actually uses, or expects or is expected to use, the product. A product +is a consumer product regardless of whether the product has substantial +commercial, industrial or non-consumer uses, unless such uses represent +the only significant mode of use of the product. + + "Installation Information" for a User Product means any methods, +procedures, authorization keys, or other information required to install +and execute modified versions of a covered work in that User Product from +a modified version of its Corresponding Source. The information must +suffice to ensure that the continued functioning of the modified object +code is in no case prevented or interfered with solely because +modification has been made. + + If you convey an object code work under this section in, or with, or +specifically for use in, a User Product, and the conveying occurs as +part of a transaction in which the right of possession and use of the +User Product is transferred to the recipient in perpetuity or for a +fixed term (regardless of how the transaction is characterized), the +Corresponding Source conveyed under this section must be accompanied +by the Installation Information. But this requirement does not apply +if neither you nor any third party retains the ability to install +modified object code on the User Product (for example, the work has +been installed in ROM). + + The requirement to provide Installation Information does not include a +requirement to continue to provide support service, warranty, or updates +for a work that has been modified or installed by the recipient, or for +the User Product in which it has been modified or installed. Access to a +network may be denied when the modification itself materially and +adversely affects the operation of the network or violates the rules and +protocols for communication across the network. + + Corresponding Source conveyed, and Installation Information provided, +in accord with this section must be in a format that is publicly +documented (and with an implementation available to the public in +source code form), and must require no special password or key for +unpacking, reading or copying. + + 7. Additional Terms. + + "Additional permissions" are terms that supplement the terms of this +License by making exceptions from one or more of its conditions. +Additional permissions that are applicable to the entire Program shall +be treated as though they were included in this License, to the extent +that they are valid under applicable law. If additional permissions +apply only to part of the Program, that part may be used separately +under those permissions, but the entire Program remains governed by +this License without regard to the additional permissions. + + When you convey a copy of a covered work, you may at your option +remove any additional permissions from that copy, or from any part of +it. (Additional permissions may be written to require their own +removal in certain cases when you modify the work.) You may place +additional permissions on material, added by you to a covered work, +for which you have or can give appropriate copyright permission. + + Notwithstanding any other provision of this License, for material you +add to a covered work, you may (if authorized by the copyright holders of +that material) supplement the terms of this License with terms: + + a) Disclaiming warranty or limiting liability differently from the + terms of sections 15 and 16 of this License; or + + b) Requiring preservation of specified reasonable legal notices or + author attributions in that material or in the Appropriate Legal + Notices displayed by works containing it; or + + c) Prohibiting misrepresentation of the origin of that material, or + requiring that modified versions of such material be marked in + reasonable ways as different from the original version; or + + d) Limiting the use for publicity purposes of names of licensors or + authors of the material; or + + e) Declining to grant rights under trademark law for use of some + trade names, trademarks, or service marks; or + + f) Requiring indemnification of licensors and authors of that + material by anyone who conveys the material (or modified versions of + it) with contractual assumptions of liability to the recipient, for + any liability that these contractual assumptions directly impose on + those licensors and authors. + + All other non-permissive additional terms are considered "further +restrictions" within the meaning of section 10. If the Program as you +received it, or any part of it, contains a notice stating that it is +governed by this License along with a term that is a further +restriction, you may remove that term. If a license document contains +a further restriction but permits relicensing or conveying under this +License, you may add to a covered work material governed by the terms +of that license document, provided that the further restriction does +not survive such relicensing or conveying. + + If you add terms to a covered work in accord with this section, you +must place, in the relevant source files, a statement of the +additional terms that apply to those files, or a notice indicating +where to find the applicable terms. + + Additional terms, permissive or non-permissive, may be stated in the +form of a separately written license, or stated as exceptions; +the above requirements apply either way. + + 8. Termination. + + You may not propagate or modify a covered work except as expressly +provided under this License. Any attempt otherwise to propagate or +modify it is void, and will automatically terminate your rights under +this License (including any patent licenses granted under the third +paragraph of section 11). + + However, if you cease all violation of this License, then your +license from a particular copyright holder is reinstated (a) +provisionally, unless and until the copyright holder explicitly and +finally terminates your license, and (b) permanently, if the copyright +holder fails to notify you of the violation by some reasonable means +prior to 60 days after the cessation. + + Moreover, your license from a particular copyright holder is +reinstated permanently if the copyright holder notifies you of the +violation by some reasonable means, this is the first time you have +received notice of violation of this License (for any work) from that +copyright holder, and you cure the violation prior to 30 days after +your receipt of the notice. + + Termination of your rights under this section does not terminate the +licenses of parties who have received copies or rights from you under +this License. If your rights have been terminated and not permanently +reinstated, you do not qualify to receive new licenses for the same +material under section 10. + + 9. Acceptance Not Required for Having Copies. + + You are not required to accept this License in order to receive or +run a copy of the Program. Ancillary propagation of a covered work +occurring solely as a consequence of using peer-to-peer transmission +to receive a copy likewise does not require acceptance. However, +nothing other than this License grants you permission to propagate or +modify any covered work. These actions infringe copyright if you do +not accept this License. Therefore, by modifying or propagating a +covered work, you indicate your acceptance of this License to do so. + + 10. Automatic Licensing of Downstream Recipients. + + Each time you convey a covered work, the recipient automatically +receives a license from the original licensors, to run, modify and +propagate that work, subject to this License. You are not responsible +for enforcing compliance by third parties with this License. + + An "entity transaction" is a transaction transferring control of an +organization, or substantially all assets of one, or subdividing an +organization, or merging organizations. If propagation of a covered +work results from an entity transaction, each party to that +transaction who receives a copy of the work also receives whatever +licenses to the work the party's predecessor in interest had or could +give under the previous paragraph, plus a right to possession of the +Corresponding Source of the work from the predecessor in interest, if +the predecessor has it or can get it with reasonable efforts. + + You may not impose any further restrictions on the exercise of the +rights granted or affirmed under this License. For example, you may +not impose a license fee, royalty, or other charge for exercise of +rights granted under this License, and you may not initiate litigation +(including a cross-claim or counterclaim in a lawsuit) alleging that +any patent claim is infringed by making, using, selling, offering for +sale, or importing the Program or any portion of it. + + 11. Patents. + + A "contributor" is a copyright holder who authorizes use under this +License of the Program or a work on which the Program is based. The +work thus licensed is called the contributor's "contributor version". + + A contributor's "essential patent claims" are all patent claims +owned or controlled by the contributor, whether already acquired or +hereafter acquired, that would be infringed by some manner, permitted +by this License, of making, using, or selling its contributor version, +but do not include claims that would be infringed only as a +consequence of further modification of the contributor version. For +purposes of this definition, "control" includes the right to grant +patent sublicenses in a manner consistent with the requirements of +this License. + + Each contributor grants you a non-exclusive, worldwide, royalty-free +patent license under the contributor's essential patent claims, to +make, use, sell, offer for sale, import and otherwise run, modify and +propagate the contents of its contributor version. + + In the following three paragraphs, a "patent license" is any express +agreement or commitment, however denominated, not to enforce a patent +(such as an express permission to practice a patent or covenant not to +sue for patent infringement). To "grant" such a patent license to a +party means to make such an agreement or commitment not to enforce a +patent against the party. + + If you convey a covered work, knowingly relying on a patent license, +and the Corresponding Source of the work is not available for anyone +to copy, free of charge and under the terms of this License, through a +publicly available network server or other readily accessible means, +then you must either (1) cause the Corresponding Source to be so +available, or (2) arrange to deprive yourself of the benefit of the +patent license for this particular work, or (3) arrange, in a manner +consistent with the requirements of this License, to extend the patent +license to downstream recipients. "Knowingly relying" means you have +actual knowledge that, but for the patent license, your conveying the +covered work in a country, or your recipient's use of the covered work +in a country, would infringe one or more identifiable patents in that +country that you have reason to believe are valid. + + If, pursuant to or in connection with a single transaction or +arrangement, you convey, or propagate by procuring conveyance of, a +covered work, and grant a patent license to some of the parties +receiving the covered work authorizing them to use, propagate, modify +or convey a specific copy of the covered work, then the patent license +you grant is automatically extended to all recipients of the covered +work and works based on it. + + A patent license is "discriminatory" if it does not include within +the scope of its coverage, prohibits the exercise of, or is +conditioned on the non-exercise of one or more of the rights that are +specifically granted under this License. You may not convey a covered +work if you are a party to an arrangement with a third party that is +in the business of distributing software, under which you make payment +to the third party based on the extent of your activity of conveying +the work, and under which the third party grants, to any of the +parties who would receive the covered work from you, a discriminatory +patent license (a) in connection with copies of the covered work +conveyed by you (or copies made from those copies), or (b) primarily +for and in connection with specific products or compilations that +contain the covered work, unless you entered into that arrangement, +or that patent license was granted, prior to 28 March 2007. + + Nothing in this License shall be construed as excluding or limiting +any implied license or other defenses to infringement that may +otherwise be available to you under applicable patent law. + + 12. No Surrender of Others' Freedom. + + If conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot convey a +covered work so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you may +not convey it at all. For example, if you agree to terms that obligate you +to collect a royalty for further conveying from those to whom you convey +the Program, the only way you could satisfy both those terms and this +License would be to refrain entirely from conveying the Program. + + 13. Use with the GNU Affero General Public License. + + Notwithstanding any other provision of this License, you have +permission to link or combine any covered work with a work licensed +under version 3 of the GNU Affero General Public License into a single +combined work, and to convey the resulting work. The terms of this +License will continue to apply to the part which is the covered work, +but the special requirements of the GNU Affero General Public License, +section 13, concerning interaction through a network will apply to the +combination as such. + + 14. Revised Versions of this License. + + The Free Software Foundation may publish revised and/or new versions of +the GNU General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + + Each version is given a distinguishing version number. If the +Program specifies that a certain numbered version of the GNU General +Public License "or any later version" applies to it, you have the +option of following the terms and conditions either of that numbered +version or of any later version published by the Free Software +Foundation. If the Program does not specify a version number of the +GNU General Public License, you may choose any version ever published +by the Free Software Foundation. + + If the Program specifies that a proxy can decide which future +versions of the GNU General Public License can be used, that proxy's +public statement of acceptance of a version permanently authorizes you +to choose that version for the Program. + + Later license versions may give you additional or different +permissions. However, no additional obligations are imposed on any +author or copyright holder as a result of your choosing to follow a +later version. + + 15. Disclaimer of Warranty. + + THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY +APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT +HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY +OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, +THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM +IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF +ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. Limitation of Liability. + + IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS +THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY +GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE +USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF +DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD +PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), +EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF +SUCH DAMAGES. + + 17. Interpretation of Sections 15 and 16. + + If the disclaimer of warranty and limitation of liability provided +above cannot be given local legal effect according to their terms, +reviewing courts shall apply local law that most closely approximates +an absolute waiver of all civil liability in connection with the +Program, unless a warranty or assumption of liability accompanies a +copy of the Program in return for a fee. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +state the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + +Also add information on how to contact you by electronic and paper mail. + + If the program does terminal interaction, make it output a short +notice like this when it starts in an interactive mode: + + Copyright (C) + This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, your program's commands +might be different; for a GUI interface, you would use an "about box". + + You should also get your employer (if you work as a programmer) or school, +if any, to sign a "copyright disclaimer" for the program, if necessary. +For more information on this, and how to apply and follow the GNU GPL, see +. + + The GNU General Public License does not permit incorporating your program +into proprietary programs. If your program is a subroutine library, you +may consider it more useful to permit linking proprietary applications with +the library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. But first, please read +. diff --git a/libs/ode-0.16.1/libccd/src/testsuites/cu/COPYING.LESSER b/libs/ode-0.16.1/libccd/src/testsuites/cu/COPYING.LESSER new file mode 100644 index 0000000..fc8a5de --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/cu/COPYING.LESSER @@ -0,0 +1,165 @@ + GNU LESSER GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 + + Copyright (C) 2007 Free Software Foundation, Inc. + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + + This version of the GNU Lesser General Public License incorporates +the terms and conditions of version 3 of the GNU General Public +License, supplemented by the additional permissions listed below. + + 0. Additional Definitions. + + As used herein, "this License" refers to version 3 of the GNU Lesser +General Public License, and the "GNU GPL" refers to version 3 of the GNU +General Public License. + + "The Library" refers to a covered work governed by this License, +other than an Application or a Combined Work as defined below. + + An "Application" is any work that makes use of an interface provided +by the Library, but which is not otherwise based on the Library. +Defining a subclass of a class defined by the Library is deemed a mode +of using an interface provided by the Library. + + A "Combined Work" is a work produced by combining or linking an +Application with the Library. The particular version of the Library +with which the Combined Work was made is also called the "Linked +Version". + + The "Minimal Corresponding Source" for a Combined Work means the +Corresponding Source for the Combined Work, excluding any source code +for portions of the Combined Work that, considered in isolation, are +based on the Application, and not on the Linked Version. + + The "Corresponding Application Code" for a Combined Work means the +object code and/or source code for the Application, including any data +and utility programs needed for reproducing the Combined Work from the +Application, but excluding the System Libraries of the Combined Work. + + 1. Exception to Section 3 of the GNU GPL. + + You may convey a covered work under sections 3 and 4 of this License +without being bound by section 3 of the GNU GPL. + + 2. Conveying Modified Versions. + + If you modify a copy of the Library, and, in your modifications, a +facility refers to a function or data to be supplied by an Application +that uses the facility (other than as an argument passed when the +facility is invoked), then you may convey a copy of the modified +version: + + a) under this License, provided that you make a good faith effort to + ensure that, in the event an Application does not supply the + function or data, the facility still operates, and performs + whatever part of its purpose remains meaningful, or + + b) under the GNU GPL, with none of the additional permissions of + this License applicable to that copy. + + 3. Object Code Incorporating Material from Library Header Files. + + The object code form of an Application may incorporate material from +a header file that is part of the Library. You may convey such object +code under terms of your choice, provided that, if the incorporated +material is not limited to numerical parameters, data structure +layouts and accessors, or small macros, inline functions and templates +(ten or fewer lines in length), you do both of the following: + + a) Give prominent notice with each copy of the object code that the + Library is used in it and that the Library and its use are + covered by this License. + + b) Accompany the object code with a copy of the GNU GPL and this license + document. + + 4. Combined Works. + + You may convey a Combined Work under terms of your choice that, +taken together, effectively do not restrict modification of the +portions of the Library contained in the Combined Work and reverse +engineering for debugging such modifications, if you also do each of +the following: + + a) Give prominent notice with each copy of the Combined Work that + the Library is used in it and that the Library and its use are + covered by this License. + + b) Accompany the Combined Work with a copy of the GNU GPL and this license + document. + + c) For a Combined Work that displays copyright notices during + execution, include the copyright notice for the Library among + these notices, as well as a reference directing the user to the + copies of the GNU GPL and this license document. + + d) Do one of the following: + + 0) Convey the Minimal Corresponding Source under the terms of this + License, and the Corresponding Application Code in a form + suitable for, and under terms that permit, the user to + recombine or relink the Application with a modified version of + the Linked Version to produce a modified Combined Work, in the + manner specified by section 6 of the GNU GPL for conveying + Corresponding Source. + + 1) Use a suitable shared library mechanism for linking with the + Library. A suitable mechanism is one that (a) uses at run time + a copy of the Library already present on the user's computer + system, and (b) will operate properly with a modified version + of the Library that is interface-compatible with the Linked + Version. + + e) Provide Installation Information, but only if you would otherwise + be required to provide such information under section 6 of the + GNU GPL, and only to the extent that such information is + necessary to install and execute a modified version of the + Combined Work produced by recombining or relinking the + Application with a modified version of the Linked Version. (If + you use option 4d0, the Installation Information must accompany + the Minimal Corresponding Source and Corresponding Application + Code. If you use option 4d1, you must provide the Installation + Information in the manner specified by section 6 of the GNU GPL + for conveying Corresponding Source.) + + 5. Combined Libraries. + + You may place library facilities that are a work based on the +Library side by side in a single library together with other library +facilities that are not Applications and are not covered by this +License, and convey such a combined library under terms of your +choice, if you do both of the following: + + a) Accompany the combined library with a copy of the same work based + on the Library, uncombined with any other library facilities, + conveyed under the terms of this License. + + b) Give prominent notice with the combined library that part of it + is a work based on the Library, and explaining where to find the + accompanying uncombined form of the same work. + + 6. Revised Versions of the GNU Lesser General Public License. + + The Free Software Foundation may publish revised and/or new versions +of the GNU Lesser General Public License from time to time. Such new +versions will be similar in spirit to the present version, but may +differ in detail to address new problems or concerns. + + Each version is given a distinguishing version number. If the +Library as you received it specifies that a certain numbered version +of the GNU Lesser General Public License "or any later version" +applies to it, you have the option of following the terms and +conditions either of that published version or of any later version +published by the Free Software Foundation. If the Library as you +received it does not specify a version number of the GNU Lesser +General Public License, you may choose any version of the GNU Lesser +General Public License ever published by the Free Software Foundation. + + If the Library as you received it specifies that a proxy can decide +whether future versions of the GNU Lesser General Public License shall +apply, that proxy's public statement of acceptance of any version is +permanent authorization for you to choose that version for the +Library. diff --git a/libs/ode-0.16.1/libccd/src/testsuites/cu/Makefile.am b/libs/ode-0.16.1/libccd/src/testsuites/cu/Makefile.am new file mode 100644 index 0000000..66d6daf --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/cu/Makefile.am @@ -0,0 +1,6 @@ +AM_CPPFLAGS = -DCU_ENABLE_TIMER + +check_LTLIBRARIES = libcu.la + +libcu_la_SOURCES = cu.c cu.h + diff --git a/libs/ode-0.16.1/libccd/src/testsuites/cu/Makefile.in b/libs/ode-0.16.1/libccd/src/testsuites/cu/Makefile.in new file mode 100644 index 0000000..6c6a3a0 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/cu/Makefile.in @@ -0,0 +1,587 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +subdir = src/testsuites/cu +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/src/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +libcu_la_LIBADD = +am_libcu_la_OBJECTS = cu.lo +libcu_la_OBJECTS = $(am_libcu_la_OBJECTS) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/src +depcomp = $(SHELL) $(top_srcdir)/../depcomp +am__depfiles_maybe = depfiles +am__mv = mv -f +COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ + $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CFLAGS) $(CFLAGS) +AM_V_CC = $(am__v_CC_@AM_V@) +am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) +am__v_CC_0 = @echo " CC " $@; +am__v_CC_1 = +CCLD = $(CC) +LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CCLD = $(am__v_CCLD_@AM_V@) +am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) +am__v_CCLD_0 = @echo " CCLD " $@; +am__v_CCLD_1 = +SOURCES = $(libcu_la_SOURCES) +DIST_SOURCES = $(libcu_la_SOURCES) +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/../depcomp \ + COPYING COPYING.LESSER +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CCD_PRECISION = @CCD_PRECISION@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +FGREP = @FGREP@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +runstatedir = @runstatedir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +AM_CPPFLAGS = -DCU_ENABLE_TIMER +check_LTLIBRARIES = libcu.la +libcu_la_SOURCES = cu.c cu.h +all: all-am + +.SUFFIXES: +.SUFFIXES: .c .lo .o .obj +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/testsuites/cu/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign src/testsuites/cu/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): + +clean-checkLTLIBRARIES: + -test -z "$(check_LTLIBRARIES)" || rm -f $(check_LTLIBRARIES) + @list='$(check_LTLIBRARIES)'; \ + locs=`for p in $$list; do echo $$p; done | \ + sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ + sort -u`; \ + test -z "$$locs" || { \ + echo rm -f $${locs}; \ + rm -f $${locs}; \ + } + +libcu.la: $(libcu_la_OBJECTS) $(libcu_la_DEPENDENCIES) $(EXTRA_libcu_la_DEPENDENCIES) + $(AM_V_CCLD)$(LINK) $(libcu_la_OBJECTS) $(libcu_la_LIBADD) $(LIBS) + +mostlyclean-compile: + -rm -f *.$(OBJEXT) + +distclean-compile: + -rm -f *.tab.c + +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cu.Plo@am__quote@ + +.c.o: +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< + +.c.obj: +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` + +.c.lo: +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am + $(MAKE) $(AM_MAKEFLAGS) $(check_LTLIBRARIES) +check: check-am +all-am: Makefile +installdirs: +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-checkLTLIBRARIES clean-generic clean-libtool \ + mostlyclean-am + +distclean: distclean-am + -rm -rf ./$(DEPDIR) + -rm -f Makefile +distclean-am: clean-am distclean-compile distclean-generic \ + distclean-tags + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -rf ./$(DEPDIR) + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ + mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: + +.MAKE: check-am install-am install-strip + +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean \ + clean-checkLTLIBRARIES clean-generic clean-libtool \ + cscopelist-am ctags ctags-am distclean distclean-compile \ + distclean-generic distclean-libtool distclean-tags distdir dvi \ + dvi-am html html-am info info-am install install-am \ + install-data install-data-am install-dvi install-dvi-am \ + install-exec install-exec-am install-html install-html-am \ + install-info install-info-am install-man install-pdf \ + install-pdf-am install-ps install-ps-am install-strip \ + installcheck installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-am uninstall uninstall-am + +.PRECIOUS: Makefile + + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/libs/ode-0.16.1/libccd/src/testsuites/cu/cu.c b/libs/ode-0.16.1/libccd/src/testsuites/cu/cu.c new file mode 100644 index 0000000..7449b4b --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/cu/cu.c @@ -0,0 +1,387 @@ +/*** + * CU - C unit testing framework + * --------------------------------- + * Copyright (c)2007,2008,2009 Daniel Fiser + * + * + * This file is part of CU. + * + * CU is free software; you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation; either version 3 of + * the License, or (at your option) any later version. + * + * CU is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with this program. If not, see . + */ + +#include +#include +#include +#include + +#include "cu.h" + +/** Declared here, because I didn't find header file where it is declared */ +char *strsignal(int sig); + +const char *cu_current_test; +const char *cu_current_test_suite; +int cu_success_test_suites = 0; +int cu_fail_test_suites = 0; +int cu_success_tests = 0; +int cu_fail_tests = 0; +int cu_success_checks = 0; +int cu_fail_checks = 0; + +char cu_out_prefix[CU_OUT_PREFIX_LENGTH+1] = ""; + + +/* globally used file descriptor for reading/writing messages */ +int fd; + +/* indicate if test was failed */ +int test_failed; + +/* codes of messages */ +#define CHECK_FAILED '0' +#define CHECK_SUCCEED '1' +#define TEST_FAILED '2' +#define TEST_SUCCEED '3' +#define TEST_SUITE_FAILED '4' +#define TEST_SUITE_SUCCEED '5' +#define END '6' +#define TEST_NAME '7' + +/* predefined messages */ +#define MSG_CHECK_SUCCEED write(fd, "1\n", 2) +#define MSG_TEST_FAILED write(fd, "2\n", 2) +#define MSG_TEST_SUCCEED write(fd, "3\n", 2) +#define MSG_TEST_SUITE_FAILED write(fd, "4\n", 2) +#define MSG_TEST_SUITE_SUCCEED write(fd, "5\n", 2) +#define MSG_END write(fd, "6\n", 2) + +/* length of buffers */ +#define BUF_LEN 1000 +#define MSGBUF_LEN 300 + + +static void redirect_out_err(const char *testName); +static void close_out_err(void); +static void run_test_suite(const char *ts_name, cu_test_suite_t *ts); +static void receive_messages(void); + +static void cu_run_fork(const char *ts_name, cu_test_suite_t *test_suite); +static void cu_print_results(void); + +void cu_run(int argc, char *argv[]) +{ + cu_test_suites_t *tss; + int i; + char found = 0; + + if (argc > 1){ + for (i=1; i < argc; i++){ + tss = cu_test_suites; + while (tss->name != NULL && tss->test_suite != NULL){ + if (strcmp(argv[i], tss->name) == 0){ + found = 1; + cu_run_fork(tss->name, tss->test_suite); + break; + } + tss++; + } + + if (tss->name == NULL || tss->test_suite == NULL){ + fprintf(stderr, "ERROR: Could not find test suite '%s'\n", argv[i]); + } + } + + if (found == 1) + cu_print_results(); + + }else{ + tss = cu_test_suites; + while (tss->name != NULL && tss->test_suite != NULL){ + cu_run_fork(tss->name, tss->test_suite); + tss++; + } + cu_print_results(); + } + + +} + +static void cu_run_fork(const char *ts_name, cu_test_suite_t *ts) +{ + int pipefd[2]; + int pid; + int status; + + if (pipe(pipefd) == -1){ + perror("Pipe error"); + exit(-1); + } + + fprintf(stdout, " -> %s [IN PROGESS]\n", ts_name); + fflush(stdout); + + pid = fork(); + if (pid < 0){ + perror("Fork error"); + exit(-1); + } + + if (pid == 0){ + /* close read end of pipe */ + close(pipefd[0]); + + fd = pipefd[1]; + + /* run testsuite, messages go to fd */ + run_test_suite(ts_name, ts); + + MSG_END; + close(fd); + + /* stop process where running testsuite */ + exit(0); + }else{ + /* close write end of pipe */ + close(pipefd[1]); + + fd = pipefd[0]; + + /* receive and interpret all messages */ + receive_messages(); + + /* wait for children */ + wait(&status); + if (!WIFEXITED(status)){ /* if child process ends up abnormaly */ + if (WIFSIGNALED(status)){ + fprintf(stdout, "Test suite was terminated by signal %d (%s).\n", + WTERMSIG(status), strsignal(WTERMSIG(status))); + }else{ + fprintf(stdout, "Test suite terminated abnormaly!\n"); + } + + /* mark this test suite as failed, because was terminated + * prematurely */ + cu_fail_test_suites++; + } + + close(fd); + + fprintf(stdout, " -> %s [DONE]\n\n", ts_name); + fflush(stdout); + } + +} + +static void run_test_suite(const char *ts_name, cu_test_suite_t *ts) +{ + int test_suite_failed = 0; + char buffer[MSGBUF_LEN]; + int len; + + /* set up current test suite name for later messaging... */ + cu_current_test_suite = ts_name; + + /* redirect stdout and stderr */ + redirect_out_err(cu_current_test_suite); + + while (ts->name != NULL && ts->func != NULL){ + test_failed = 0; + + /* set up name of test for later messaging */ + cu_current_test = ts->name; + + /* send message what test is currently running */ + len = snprintf(buffer, MSGBUF_LEN, "%c --> Running %s...\n", + TEST_NAME, cu_current_test); + write(fd, buffer, len); + + /* run test */ + (*(ts->func))(); + + if (test_failed){ + MSG_TEST_FAILED; + test_suite_failed = 1; + }else{ + MSG_TEST_SUCCEED; + } + + ts++; /* next test in test suite */ + } + + if (test_suite_failed){ + MSG_TEST_SUITE_FAILED; + }else{ + MSG_TEST_SUITE_SUCCEED; + } + + /* close redirected stdout and stderr */ + close_out_err(); +} + + +static void receive_messages(void) +{ + char buf[BUF_LEN]; /* buffer */ + int buf_len; /* how many chars stored in buf */ + char bufout[MSGBUF_LEN]; /* buffer which can be printed out */ + int bufout_len; + int state = 0; /* 0 - waiting for code, 1 - copy msg to stdout */ + int i; + int end = 0; /* end of messages? */ + + bufout_len = 0; + while((buf_len = read(fd, buf, BUF_LEN)) > 0 && !end){ + for (i=0; i < buf_len; i++){ + + /* Prepare message for printing out */ + if (state == 1 || state == 2){ + if (bufout_len < MSGBUF_LEN) + bufout[bufout_len++] = buf[i]; + } + + /* reset state on '\n' in msg */ + if (buf[i] == '\n'){ + /* copy messages out */ + if (state == 1) + write(1, bufout, bufout_len); + if (state == 2) + write(2, bufout, bufout_len); + + state = 0; + bufout_len = 0; + continue; + } + + if (state == 0){ + if (buf[i] == CHECK_FAILED){ + cu_fail_checks++; + state = 2; + }else if (buf[i] == TEST_NAME){ + state = 1; + }else if (buf[i] == CHECK_SUCCEED){ + cu_success_checks++; + }else if (buf[i] == TEST_FAILED){ + cu_fail_tests++; + }else if (buf[i] == TEST_SUCCEED){ + cu_success_tests++; + }else if (buf[i] == TEST_SUITE_FAILED){ + cu_fail_test_suites++; + }else if (buf[i] == TEST_SUITE_SUCCEED){ + cu_success_test_suites++; + }else if (buf[i] == END){ + end = 1; + break; + } + } + } + } +} + +void cu_success_assertation(void) +{ + MSG_CHECK_SUCCEED; +} + +void cu_fail_assertation(const char *file, int line, const char *msg) +{ + char buf[MSGBUF_LEN]; + int len; + + len = snprintf(buf, MSGBUF_LEN, "%c%s:%d (%s::%s) :: %s\n", + CHECK_FAILED, + file, line, cu_current_test_suite, cu_current_test, msg); + write(fd, buf, len); + + /* enable test_failed flag */ + test_failed = 1; +} + +static void cu_print_results(void) +{ + fprintf(stdout, "\n"); + fprintf(stdout, "==================================================\n"); + fprintf(stdout, "| | failed | succeed | total |\n"); + fprintf(stdout, "|------------------------------------------------|\n"); + fprintf(stdout, "| assertations: | %6d | %7d | %5d |\n", + cu_fail_checks, cu_success_checks, + cu_success_checks+cu_fail_checks); + fprintf(stdout, "| tests: | %6d | %7d | %5d |\n", + cu_fail_tests, cu_success_tests, + cu_success_tests+cu_fail_tests); + fprintf(stdout, "| tests suites: | %6d | %7d | %5d |\n", + cu_fail_test_suites, cu_success_test_suites, + cu_success_test_suites+cu_fail_test_suites); + fprintf(stdout, "==================================================\n"); +} + +void cu_set_out_prefix(const char *str) +{ + strncpy(cu_out_prefix, str, CU_OUT_PREFIX_LENGTH); +} + +static void redirect_out_err(const char *test_name) +{ + char buf[100]; + + snprintf(buf, 99, "%stmp.%s.out", cu_out_prefix, test_name); + if (freopen(buf, "w", stdout) == NULL){ + perror("Redirecting of stdout failed"); + exit(-1); + } + + snprintf(buf, 99, "%stmp.%s.err", cu_out_prefix, test_name); + if (freopen(buf, "w", stderr) == NULL){ + perror("Redirecting of stderr failed"); + exit(-1); + } +} + +static void close_out_err(void) +{ + fclose(stdout); + fclose(stderr); +} + + +#ifdef CU_ENABLE_TIMER +/* global variables for timer functions */ +struct timespec __cu_timer; +static struct timespec __cu_timer_start, __cu_timer_stop; + +const struct timespec *cuTimer(void) +{ + return &__cu_timer; +} + +void cuTimerStart(void) +{ + clock_gettime(CLOCK_MONOTONIC, &__cu_timer_start); +} + +const struct timespec *cuTimerStop(void) +{ + clock_gettime(CLOCK_MONOTONIC, &__cu_timer_stop); + + /* store into t difference between time_start and time_end */ + if (__cu_timer_stop.tv_nsec > __cu_timer_start.tv_nsec){ + __cu_timer.tv_nsec = __cu_timer_stop.tv_nsec - __cu_timer_start.tv_nsec; + __cu_timer.tv_sec = __cu_timer_stop.tv_sec - __cu_timer_start.tv_sec; + }else{ + __cu_timer.tv_nsec = __cu_timer_stop.tv_nsec + 1000000000L - __cu_timer_start.tv_nsec; + __cu_timer.tv_sec = __cu_timer_stop.tv_sec - 1 - __cu_timer_start.tv_sec; + } + + return &__cu_timer; +} +#endif /* CU_ENABLE_TIMER */ diff --git a/libs/ode-0.16.1/libccd/src/testsuites/cu/cu.h b/libs/ode-0.16.1/libccd/src/testsuites/cu/cu.h new file mode 100644 index 0000000..06574cf --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/cu/cu.h @@ -0,0 +1,164 @@ +/*** + * CU - C unit testing framework + * --------------------------------- + * Copyright (c)2007,2008,2009 Daniel Fiser + * + * + * This file is part of CU. + * + * CU is free software; you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation; either version 3 of + * the License, or (at your option) any later version. + * + * CU is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with this program. If not, see . + */ + +#ifndef _CU_H_ +#define _CU_H_ + +#ifdef CU_ENABLE_TIMER +# include +#endif /* CU_ENABLE_TIMER */ + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +/***** PUBLIC API *****/ +/** + * Define test + */ +#define TEST(name) \ + void name(void) + +/** + * Define testsuite + */ +#define TEST_SUITE(name) \ + cu_test_suite_t test_suite_##name[] = +/** + * Must be on the end of list of tests. + */ +#define TEST_SUITE_CLOSURE \ + { NULL, NULL } + +#define TEST_SUITES \ + cu_test_suites_t cu_test_suites[] = +#define TEST_SUITES_CLOSURE \ + { NULL, NULL } +#define TEST_SUITE_ADD(name) \ + { #name, test_suite_##name } + +/** + * Add test to testsuite + */ +#define TEST_ADD(name) \ + { #name, name } + +#define CU_RUN(argc, argv) \ + cu_run(argc, argv) + +/** + * Set prefix for files printed out. Must contain trailing /. + */ +#define CU_SET_OUT_PREFIX(str) \ + cu_set_out_prefix(str) + +/** + * Assertations + * Assertations with suffix 'M' (e.g. assertTrueM) is variation of macro + * where is possible to specify error message. + */ +#define assertTrueM(a, message) \ + if (a){ \ + cu_success_assertation(); \ + }else{ \ + cu_fail_assertation(__FILE__, __LINE__, message); \ + } +#define assertTrue(a) \ + assertTrueM((a), #a " is not true") + +#define assertFalseM(a, message) \ + assertTrueM(!(a), message) +#define assertFalse(a) \ + assertFalseM((a), #a " is not false") + +#define assertEqualsM(a,b,message) \ + assertTrueM((a) == (b), message) +#define assertEquals(a,b) \ + assertEqualsM((a), (b), #a " not equals " #b) + +#define assertNotEqualsM(a,b,message) \ + assertTrueM((a) != (b), message) +#define assertNotEquals(a,b) \ + assertNotEqualsM((a), (b), #a " equals " #b) +/***** PUBLIC API END *****/ + + +#include + +#define CU_MAX_NAME_LENGTH 30 + +typedef void (*cu_test_func_t)(void); +typedef struct _cu_test_suite_t { + const char *name; + cu_test_func_t func; +} cu_test_suite_t; +typedef struct _cu_test_suites_t { + const char *name; + cu_test_suite_t *test_suite; +} cu_test_suites_t; + +extern cu_test_suites_t cu_test_suites[]; + +extern const char *cu_current_test; +extern const char *cu_current_test_suite; + +extern int cu_success_test_suites; +extern int cu_fail_test_suites; +extern int cu_success_tests; +extern int cu_fail_tests; +extern int cu_success_checks; +extern int cu_fail_checks; + +#define CU_OUT_PREFIX_LENGTH 30 +extern char cu_out_prefix[CU_OUT_PREFIX_LENGTH+1]; + +void cu_run(int argc, char *argv[]); +void cu_success_assertation(void); +void cu_fail_assertation(const char *file, int line, const char *msg); +void cu_set_out_prefix(const char *str); + +/** Timer **/ +#ifdef CU_ENABLE_TIMER +extern struct timespec __cu_timer; + +/** + * Returns value of timer. (as timespec struct) + */ +const struct timespec *cuTimer(void); + +/** + * Starts timer. + */ +void cuTimerStart(void); + +/** + * Stops timer and record elapsed time from last call of cuTimerStart(). + * Returns current value of timer. + */ +const struct timespec *cuTimerStop(void); +#endif /* CU_ENABLE_TIMER */ + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + +#endif diff --git a/libs/ode-0.16.1/libccd/src/testsuites/cylcyl.c b/libs/ode-0.16.1/libccd/src/testsuites/cylcyl.c new file mode 100644 index 0000000..6cd2124 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/cylcyl.c @@ -0,0 +1,180 @@ +#include +#include +#include +#include "support.h" +#include "common.h" + + +TEST(cylcylSetUp) +{ +} + +TEST(cylcylTearDown) +{ +} + + +TEST(cylcylAlignedX) +{ + ccd_t ccd; + CCD_CYL(c1); + CCD_CYL(c2); + size_t i; + int res; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + + c1.radius = 0.35; + c1.height = 0.5; + c2.radius = 0.5; + c2.height = 1.; + + ccdVec3Set(&c1.pos, -5., 0., 0.); + for (i = 0; i < 100; i++){ + res = ccdGJKIntersect(&c1, &c2, &ccd); + + if (i < 42 || i > 58){ + assertFalse(res); + }else{ + assertTrue(res); + } + + c1.pos.v[0] += 0.1; + } +} + +TEST(cylcylAlignedY) +{ + ccd_t ccd; + CCD_CYL(c1); + CCD_CYL(c2); + size_t i; + int res; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + + c1.radius = 0.35; + c1.height = 0.5; + c2.radius = 0.5; + c2.height = 1.; + + ccdVec3Set(&c1.pos, 0., -5., 0.); + for (i = 0; i < 100; i++){ + res = ccdGJKIntersect(&c1, &c2, &ccd); + + if (i < 42 || i > 58){ + assertFalse(res); + }else{ + assertTrue(res); + } + + c1.pos.v[1] += 0.1; + } +} + +TEST(cylcylAlignedZ) +{ + ccd_t ccd; + CCD_CYL(c1); + CCD_CYL(c2); + size_t i; + int res; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + + c1.radius = 0.35; + c1.height = 0.5; + c2.radius = 0.5; + c2.height = 1.; + + ccdVec3Set(&c1.pos, 0., 0., -5.); + for (i = 0; i < 100; i++){ + res = ccdGJKIntersect(&c1, &c2, &ccd); + + if (i < 43 || i > 57){ + assertFalse(res); + }else{ + assertTrue(res); + } + + c1.pos.v[2] += 0.1; + } +} + +#define TOSVT() \ + svtObjPen(&cyl1, &cyl2, stdout, "Pen 1", depth, &dir, &pos); \ + ccdVec3Scale(&dir, depth); \ + ccdVec3Add(&cyl2.pos, &dir); \ + svtObjPen(&cyl1, &cyl2, stdout, "Pen 1", depth, &dir, &pos) + +TEST(cylcylPenetrationEPA) +{ + ccd_t ccd; + CCD_CYL(cyl1); + CCD_CYL(cyl2); + int res; + ccd_vec3_t axis; + ccd_real_t depth; + ccd_vec3_t dir, pos; + + fprintf(stderr, "\n\n\n---- cylcylPenetration ----\n\n\n"); + + cyl1.radius = 0.35; + cyl1.height = 0.5; + cyl2.radius = 0.5; + cyl2.height = 1.; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + + ccdVec3Set(&cyl2.pos, 0., 0., 0.3); + res = ccdGJKPenetration(&cyl1, &cyl2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 1"); + //TOSVT(); + + ccdVec3Set(&cyl1.pos, 0.3, 0.1, 0.1); + res = ccdGJKPenetration(&cyl1, &cyl2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 2"); + //TOSVT(); <<< + + ccdVec3Set(&axis, 0., 1., 1.); + ccdQuatSetAngleAxis(&cyl2.quat, M_PI / 4., &axis); + ccdVec3Set(&cyl2.pos, 0., 0., 0.); + res = ccdGJKPenetration(&cyl1, &cyl2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 3"); + //TOSVT(); + + ccdVec3Set(&axis, 0., 1., 1.); + ccdQuatSetAngleAxis(&cyl2.quat, M_PI / 4., &axis); + ccdVec3Set(&cyl2.pos, -0.2, 0.7, 0.2); + res = ccdGJKPenetration(&cyl1, &cyl2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 4"); + //TOSVT(); + + ccdVec3Set(&axis, 0.567, 1.2, 1.); + ccdQuatSetAngleAxis(&cyl2.quat, M_PI / 4., &axis); + ccdVec3Set(&cyl2.pos, 0.6, -0.7, 0.2); + res = ccdGJKPenetration(&cyl1, &cyl2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 5"); + //TOSVT(); + + ccdVec3Set(&axis, -4.567, 1.2, 0.); + ccdQuatSetAngleAxis(&cyl2.quat, M_PI / 3., &axis); + ccdVec3Set(&cyl2.pos, 0.6, -0.7, 0.2); + res = ccdGJKPenetration(&cyl1, &cyl2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 6"); + //TOSVT(); +} diff --git a/libs/ode-0.16.1/libccd/src/testsuites/cylcyl.h b/libs/ode-0.16.1/libccd/src/testsuites/cylcyl.h new file mode 100644 index 0000000..8cbbe07 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/cylcyl.h @@ -0,0 +1,29 @@ +#ifndef CYL_CYL +#define CYL_CYL + +#include + +TEST(cylcylSetUp); +TEST(cylcylTearDown); + +TEST(cylcylAlignedX); +TEST(cylcylAlignedY); +TEST(cylcylAlignedZ); + +TEST(cylcylPenetrationEPA); + +TEST_SUITE(TSCylCyl) { + TEST_ADD(cylcylSetUp), + + TEST_ADD(cylcylAlignedX), + TEST_ADD(cylcylAlignedY), + TEST_ADD(cylcylAlignedZ), + + TEST_ADD(cylcylPenetrationEPA), + + TEST_ADD(cylcylTearDown), + TEST_SUITE_CLOSURE +}; + +#endif + diff --git a/libs/ode-0.16.1/libccd/src/testsuites/main.c b/libs/ode-0.16.1/libccd/src/testsuites/main.c new file mode 100644 index 0000000..a4585b0 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/main.c @@ -0,0 +1,32 @@ +#include "vec3.h" +#include "polytope.h" +#include "boxbox.h" +#include "spheresphere.h" +#include "cylcyl.h" +#include "boxcyl.h" + +#include "mpr_boxbox.h" +#include "mpr_cylcyl.h" +#include "mpr_boxcyl.h" + +TEST_SUITES { + TEST_SUITE_ADD(TSVec3), + TEST_SUITE_ADD(TSPt), + TEST_SUITE_ADD(TSBoxBox), + TEST_SUITE_ADD(TSSphereSphere), + TEST_SUITE_ADD(TSCylCyl), + TEST_SUITE_ADD(TSBoxCyl), + + TEST_SUITE_ADD(TSMPRBoxBox), + TEST_SUITE_ADD(TSMPRCylCyl), + TEST_SUITE_ADD(TSMPRBoxCyl), + + TEST_SUITES_CLOSURE +}; +int main(int argc, char *argv[]) +{ + CU_SET_OUT_PREFIX("regressions/"); + CU_RUN(argc, argv); + + return 0; +} diff --git a/libs/ode-0.16.1/libccd/src/testsuites/mpr_boxbox.c b/libs/ode-0.16.1/libccd/src/testsuites/mpr_boxbox.c new file mode 100644 index 0000000..2342850 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/mpr_boxbox.c @@ -0,0 +1,500 @@ +#include +#include + +#include +#include "support.h" +#include +#include +#include "common.h" + + +TEST(mprBoxboxAlignedX) +{ + size_t i; + ccd_t ccd; + CCD_BOX(box1); + CCD_BOX(box2); + int res; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + ccd.center1 = ccdObjCenter; + ccd.center2 = ccdObjCenter; + + box1.x = 1; + box1.y = 2; + box1.z = 1; + box2.x = 2; + box2.y = 1; + box2.z = 2; + + ccdVec3Set(&box1.pos, -5., 0., 0.); + ccdVec3Set(&box2.pos, 0., 0., 0.); + ccdQuatSet(&box1.quat, 0., 0., 0., 1.); + ccdQuatSet(&box2.quat, 0., 0., 0., 1.); + for (i = 0; i < 100; i++){ + res = ccdMPRIntersect(&box1, &box2, &ccd); + if (i < 35 || i > 65){ + assertFalse(res); + }else if (i != 35 && i != 65){ + assertTrue(res); + } + + box1.pos.v[0] += 0.1; + } + + box1.x = 0.1; + box1.y = 0.2; + box1.z = 0.1; + box2.x = 0.2; + box2.y = 0.1; + box2.z = 0.2; + + ccdVec3Set(&box1.pos, -0.5, 0., 0.); + ccdVec3Set(&box2.pos, 0., 0., 0.); + ccdQuatSet(&box1.quat, 0., 0., 0., 1.); + ccdQuatSet(&box2.quat, 0., 0., 0., 1.); + for (i = 0; i < 100; i++){ + res = ccdMPRIntersect(&box1, &box2, &ccd); + + if (i < 35 || i > 65){ + assertFalse(res); + }else if (i != 35 && i != 65){ + assertTrue(res); + } + + box1.pos.v[0] += 0.01; + } + + + box1.x = 1; + box1.y = 2; + box1.z = 1; + box2.x = 2; + box2.y = 1; + box2.z = 2; + + ccdVec3Set(&box1.pos, -5., -0.1, 0.); + ccdVec3Set(&box2.pos, 0., 0., 0.); + ccdQuatSet(&box1.quat, 0., 0., 0., 1.); + ccdQuatSet(&box2.quat, 0., 0., 0., 1.); + for (i = 0; i < 100; i++){ + res = ccdMPRIntersect(&box1, &box2, &ccd); + + if (i < 35 || i > 65){ + assertFalse(res); + }else if (i != 35 && i != 65){ + assertTrue(res); + } + + box1.pos.v[0] += 0.1; + } +} + +TEST(mprBoxboxAlignedY) +{ + size_t i; + ccd_t ccd; + CCD_BOX(box1); + CCD_BOX(box2); + int res; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + ccd.center1 = ccdObjCenter; + ccd.center2 = ccdObjCenter; + + box1.x = 1; + box1.y = 2; + box1.z = 1; + box2.x = 2; + box2.y = 1; + box2.z = 2; + + ccdVec3Set(&box1.pos, 0., -5., 0.); + ccdVec3Set(&box2.pos, 0., 0., 0.); + ccdQuatSet(&box1.quat, 0., 0., 0., 1.); + ccdQuatSet(&box2.quat, 0., 0., 0., 1.); + for (i = 0; i < 100; i++){ + res = ccdMPRIntersect(&box1, &box2, &ccd); + + if (i < 35 || i > 65){ + assertFalse(res); + }else if (i != 35 && i != 65){ + assertTrue(res); + } + + box1.pos.v[1] += 0.1; + } +} + +TEST(mprBoxboxAlignedZ) +{ + size_t i; + ccd_t ccd; + CCD_BOX(box1); + CCD_BOX(box2); + int res; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + ccd.center1 = ccdObjCenter; + ccd.center2 = ccdObjCenter; + + box1.x = 1; + box1.y = 2; + box1.z = 1; + box2.x = 2; + box2.y = 1; + box2.z = 2; + + ccdVec3Set(&box1.pos, 0., 0., -5.); + ccdVec3Set(&box2.pos, 0., 0., 0.); + ccdQuatSet(&box1.quat, 0., 0., 0., 1.); + ccdQuatSet(&box2.quat, 0., 0., 0., 1.); + for (i = 0; i < 100; i++){ + res = ccdMPRIntersect(&box1, &box2, &ccd); + + if (i < 35 || i > 65){ + assertFalse(res); + }else if (i != 35 && i != 65){ + assertTrue(res); + } + + box1.pos.v[2] += 0.1; + } +} + + +TEST(mprBoxboxRot) +{ + size_t i; + ccd_t ccd; + CCD_BOX(box1); + CCD_BOX(box2); + int res; + ccd_vec3_t axis; + ccd_real_t angle; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + ccd.center1 = ccdObjCenter; + ccd.center2 = ccdObjCenter; + + box1.x = 1; + box1.y = 2; + box1.z = 1; + box2.x = 2; + box2.y = 1; + box2.z = 2; + + ccdVec3Set(&box1.pos, -5., 0.5, 0.); + ccdVec3Set(&box2.pos, 0., 0., 0.); + ccdQuatSet(&box2.quat, 0., 0., 0., 1.); + ccdVec3Set(&axis, 0., 1., 0.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + + for (i = 0; i < 100; i++){ + res = ccdMPRIntersect(&box1, &box2, &ccd); + + if (i < 33 || i > 67){ + assertFalse(res); + }else if (i != 33 && i != 67){ + assertTrue(res); + } + + box1.pos.v[0] += 0.1; + } + + box1.x = 1; + box1.y = 1; + box1.z = 1; + box2.x = 1; + box2.y = 1; + box2.z = 1; + + ccdVec3Set(&box1.pos, -1.01, 0., 0.); + ccdVec3Set(&box2.pos, 0., 0., 0.); + ccdQuatSet(&box1.quat, 0., 0., 0., 1.); + ccdQuatSet(&box2.quat, 0., 0., 0., 1.); + + ccdVec3Set(&axis, 0., 1., 0.); + angle = 0.; + for (i = 0; i < 30; i++){ + res = ccdMPRIntersect(&box1, &box2, &ccd); + + if (i != 0 && i != 10 && i != 20){ + assertTrue(res); + }else{ + assertFalse(res); + } + + angle += M_PI / 20.; + ccdQuatSetAngleAxis(&box1.quat, angle, &axis); + } + +} + + + +static void pConf(ccd_box_t *box1, ccd_box_t *box2, const ccd_vec3_t *v) +{ + fprintf(stdout, "# box1.pos: [%lf %lf %lf]\n", + ccdVec3X(&box1->pos), ccdVec3Y(&box1->pos), ccdVec3Z(&box1->pos)); + fprintf(stdout, "# box1->quat: [%lf %lf %lf %lf]\n", + box1->quat.q[0], box1->quat.q[1], box1->quat.q[2], box1->quat.q[3]); + fprintf(stdout, "# box2->pos: [%lf %lf %lf]\n", + ccdVec3X(&box2->pos), ccdVec3Y(&box2->pos), ccdVec3Z(&box2->pos)); + fprintf(stdout, "# box2->quat: [%lf %lf %lf %lf]\n", + box2->quat.q[0], box2->quat.q[1], box2->quat.q[2], box2->quat.q[3]); + fprintf(stdout, "# sep: [%lf %lf %lf]\n", + ccdVec3X(v), ccdVec3Y(v), ccdVec3Z(v)); + fprintf(stdout, "#\n"); +} + +TEST(mprBoxboxSeparate) +{ + ccd_t ccd; + CCD_BOX(box1); + CCD_BOX(box2); + int res; + ccd_vec3_t sep, expsep, expsep2, axis; + + fprintf(stderr, "\n\n\n---- boxboxSeparate ----\n\n\n"); + + box1.x = box1.y = box1.z = 1.; + box2.x = 0.5; + box2.y = 1.; + box2.z = 1.5; + + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + + ccdVec3Set(&box1.pos, -0.5, 0.5, 0.2); + res = ccdMPRIntersect(&box1, &box2, &ccd); + assertTrue(res); + + res = ccdGJKSeparate(&box1, &box2, &ccd, &sep); + assertTrue(res == 0); + ccdVec3Set(&expsep, 0.25, 0., 0.); + assertTrue(ccdVec3Eq(&sep, &expsep)); + + ccdVec3Scale(&sep, -1.); + ccdVec3Add(&box1.pos, &sep); + res = ccdGJKSeparate(&box1, &box2, &ccd, &sep); + assertTrue(res == 0); + ccdVec3Set(&expsep, 0., 0., 0.); + assertTrue(ccdVec3Eq(&sep, &expsep)); + + + ccdVec3Set(&box1.pos, -0.3, 0.5, 1.); + res = ccdGJKSeparate(&box1, &box2, &ccd, &sep); + assertTrue(res == 0); + ccdVec3Set(&expsep, 0., 0., -0.25); + assertTrue(ccdVec3Eq(&sep, &expsep)); + + + + box1.x = box1.y = box1.z = 1.; + box2.x = box2.y = box2.z = 1.; + ccdVec3Set(&axis, 0., 0., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, 0., 0., 0.); + + res = ccdGJKSeparate(&box1, &box2, &ccd, &sep); + assertTrue(res == 0); + ccdVec3Set(&expsep, 0., 0., 1.); + ccdVec3Set(&expsep2, 0., 0., -1.); + assertTrue(ccdVec3Eq(&sep, &expsep) || ccdVec3Eq(&sep, &expsep2)); + + + + box1.x = box1.y = box1.z = 1.; + ccdVec3Set(&axis, 0., 0., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, -0.5, 0., 0.); + + res = ccdGJKSeparate(&box1, &box2, &ccd, &sep); + assertTrue(res == 0); + pConf(&box1, &box2, &sep); + + + + box1.x = box1.y = box1.z = 1.; + ccdVec3Set(&axis, 0., 1., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, -0.5, 0.1, 0.4); + + res = ccdGJKSeparate(&box1, &box2, &ccd, &sep); + assertTrue(res == 0); + pConf(&box1, &box2, &sep); +} + + +#define TOSVT() \ + svtObjPen(&box1, &box2, stdout, "Pen 1", depth, &dir, &pos); \ + ccdVec3Scale(&dir, depth); \ + ccdVec3Add(&box2.pos, &dir); \ + svtObjPen(&box1, &box2, stdout, "Pen 1", depth, &dir, &pos) + +TEST(mprBoxboxPenetration) +{ + ccd_t ccd; + CCD_BOX(box1); + CCD_BOX(box2); + int res; + ccd_vec3_t axis; + ccd_quat_t rot; + ccd_real_t depth; + ccd_vec3_t dir, pos; + + fprintf(stderr, "\n\n\n---- boxboxPenetration ----\n\n\n"); + + box1.x = box1.y = box1.z = 1.; + box2.x = 0.5; + box2.y = 1.; + box2.z = 1.5; + + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + ccd.center1 = ccdObjCenter; + ccd.center2 = ccdObjCenter; + + /* + ccdVec3Set(&box2.pos, 0., 0., 0.); + res = ccdMPRPenetration(&box1, &box2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 1"); + TOSVT(); + */ + + ccdVec3Set(&box2.pos, 0.1, 0., 0.); + res = ccdMPRPenetration(&box1, &box2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 1"); + //TOSVT(); + + + ccdVec3Set(&box1.pos, -0.3, 0.5, 1.); + res = ccdMPRPenetration(&box1, &box2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 2"); + //TOSVT(); + + + box1.x = box1.y = box1.z = 1.; + box2.x = box2.y = box2.z = 1.; + ccdVec3Set(&axis, 0., 0., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, 0.1, 0., 0.1); + + res = ccdMPRPenetration(&box1, &box2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 3"); + //TOSVT(); + + + box1.x = box1.y = box1.z = 1.; + box2.x = box2.y = box2.z = 1.; + ccdVec3Set(&axis, 0., 0., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, -0.5, 0., 0.); + + res = ccdMPRPenetration(&box1, &box2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 4"); + //TOSVT(); + + + box1.x = box1.y = box1.z = 1.; + box2.x = box2.y = box2.z = 1.; + ccdVec3Set(&axis, 0., 0., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, -0.5, 0.5, 0.); + + res = ccdMPRPenetration(&box1, &box2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 5"); + //TOSVT(); + + + box1.x = box1.y = box1.z = 1.; + box2.x = box2.y = box2.z = 1.; + ccdVec3Set(&box2.pos, 0.1, 0., 0.); + + box1.x = box1.y = box1.z = 1.; + ccdVec3Set(&axis, 0., 1., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&box1.pos, -0.5, 0.1, 0.4); + + res = ccdMPRPenetration(&box1, &box2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 6"); + //TOSVT(); + + + box1.x = box1.y = box1.z = 1.; + ccdVec3Set(&axis, 0., 1., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&axis, 1., 1., 1.); + ccdQuatSetAngleAxis(&rot, M_PI / 4., &axis); + ccdQuatMul(&box1.quat, &rot); + ccdVec3Set(&box1.pos, -0.5, 0.1, 0.4); + + res = ccdMPRPenetration(&box1, &box2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 7"); + //TOSVT(); + + + box1.x = box1.y = box1.z = 1.; + box2.x = 0.2; box2.y = 0.5; box2.z = 1.; + box2.x = box2.y = box2.z = 1.; + + ccdVec3Set(&axis, 0., 0., 1.); + ccdQuatSetAngleAxis(&box1.quat, M_PI / 4., &axis); + ccdVec3Set(&axis, 1., 0., 0.); + ccdQuatSetAngleAxis(&rot, M_PI / 4., &axis); + ccdQuatMul(&box1.quat, &rot); + ccdVec3Set(&box1.pos, -1.3, 0., 0.); + + ccdVec3Set(&box2.pos, 0., 0., 0.); + + res = ccdMPRPenetration(&box1, &box2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 8"); + //TOSVT(); + + + box1.x = box1.y = box1.z = 1.; + box2.x = 0.5; box2.y = 0.5; box2.z = .5; + ccdVec3Set(&box1.pos, 0., 0., 0.); + ccdQuatSet(&box1.quat, 0., 0., 0., 1.); + ccdVec3Set(&box2.pos, 0., 0.73, 0.); + ccdQuatSet(&box2.quat, 0., 0., 0., 1.); + + res = ccdMPRPenetration(&box1, &box2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 9"); + //TOSVT(); + + box1.x = box1.y = box1.z = 1.; + box2.x = 0.5; box2.y = 0.5; box2.z = .5; + ccdVec3Set(&box1.pos, 0., 0., 0.); + ccdQuatSet(&box1.quat, 0., 0., 0., 1.); + ccdVec3Set(&box2.pos, 0.3, 0.738, 0.); + ccdQuatSet(&box2.quat, 0., 0., 0., 1.); + + res = ccdMPRPenetration(&box1, &box2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 10"); + //TOSVT(); +} diff --git a/libs/ode-0.16.1/libccd/src/testsuites/mpr_boxbox.h b/libs/ode-0.16.1/libccd/src/testsuites/mpr_boxbox.h new file mode 100644 index 0000000..e6922aa --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/mpr_boxbox.h @@ -0,0 +1,26 @@ +#ifndef MPR_BOX_BOX +#define MPR_BOX_BOX + +#include + +TEST(mprBoxboxAlignedX); +TEST(mprBoxboxAlignedY); +TEST(mprBoxboxAlignedZ); + +TEST(mprBoxboxRot); + +TEST(mprBoxboxSeparate); +TEST(mprBoxboxPenetration); + +TEST_SUITE(TSMPRBoxBox) { + TEST_ADD(mprBoxboxAlignedX), + TEST_ADD(mprBoxboxAlignedY), + TEST_ADD(mprBoxboxAlignedZ), + TEST_ADD(mprBoxboxRot), + //TEST_ADD(mprBoxboxSeparate), + TEST_ADD(mprBoxboxPenetration), + + TEST_SUITE_CLOSURE +}; + +#endif diff --git a/libs/ode-0.16.1/libccd/src/testsuites/mpr_boxcyl.c b/libs/ode-0.16.1/libccd/src/testsuites/mpr_boxcyl.c new file mode 100644 index 0000000..7a1b7fa --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/mpr_boxcyl.c @@ -0,0 +1,165 @@ +#include +#include "common.h" +#include +#include "support.h" + +#define TOSVT() \ + svtObjPen(&box, &cyl, stdout, "Pen 1", depth, &dir, &pos); \ + ccdVec3Scale(&dir, depth); \ + ccdVec3Add(&cyl.pos, &dir); \ + svtObjPen(&box, &cyl, stdout, "Pen 1", depth, &dir, &pos) + +TEST(mprBoxcylIntersect) +{ + ccd_t ccd; + CCD_BOX(box); + CCD_CYL(cyl); + int res; + ccd_vec3_t axis; + + box.x = 0.5; + box.y = 1.; + box.z = 1.5; + cyl.radius = 0.4; + cyl.height = 0.7; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + ccd.center1 = ccdObjCenter; + ccd.center2 = ccdObjCenter; + + ccdVec3Set(&cyl.pos, 0.1, 0., 0.); + res = ccdMPRIntersect(&box, &cyl, &ccd); + assertTrue(res); + + ccdVec3Set(&cyl.pos, .6, 0., 0.); + res = ccdMPRIntersect(&box, &cyl, &ccd); + assertTrue(res); + + ccdVec3Set(&cyl.pos, .6, 0.6, 0.); + res = ccdMPRIntersect(&box, &cyl, &ccd); + assertTrue(res); + + ccdVec3Set(&cyl.pos, .6, 0.6, 0.5); + res = ccdMPRIntersect(&box, &cyl, &ccd); + assertTrue(res); + + ccdVec3Set(&axis, 0., 1., 0.); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 3., &axis); + ccdVec3Set(&cyl.pos, .6, 0.6, 0.5); + res = ccdMPRIntersect(&box, &cyl, &ccd); + assertTrue(res); + + ccdVec3Set(&axis, 0.67, 1.1, 0.12); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 4., &axis); + ccdVec3Set(&cyl.pos, .6, 0., 0.5); + res = ccdMPRIntersect(&box, &cyl, &ccd); + assertTrue(res); + + ccdVec3Set(&axis, -0.1, 2.2, -1.); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 5., &axis); + ccdVec3Set(&cyl.pos, .6, 0., 0.5); + ccdVec3Set(&axis, 1., 1., 0.); + ccdQuatSetAngleAxis(&box.quat, -M_PI / 4., &axis); + ccdVec3Set(&box.pos, .6, 0., 0.5); + res = ccdMPRIntersect(&box, &cyl, &ccd); + assertTrue(res); + + ccdVec3Set(&axis, -0.1, 2.2, -1.); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 5., &axis); + ccdVec3Set(&cyl.pos, .6, 0., 0.5); + ccdVec3Set(&axis, 1., 1., 0.); + ccdQuatSetAngleAxis(&box.quat, -M_PI / 4., &axis); + ccdVec3Set(&box.pos, .9, 0.8, 0.5); + res = ccdMPRIntersect(&box, &cyl, &ccd); + assertTrue(res); +} + + + +TEST(mprBoxcylPen) +{ + ccd_t ccd; + CCD_BOX(box); + CCD_CYL(cyl); + int res; + ccd_vec3_t axis; + ccd_real_t depth; + ccd_vec3_t dir, pos; + + box.x = 0.5; + box.y = 1.; + box.z = 1.5; + cyl.radius = 0.4; + cyl.height = 0.7; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + ccd.center1 = ccdObjCenter; + ccd.center2 = ccdObjCenter; + + ccdVec3Set(&cyl.pos, 0.1, 0., 0.); + res = ccdMPRPenetration(&box, &cyl, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 1"); + //TOSVT(); + + ccdVec3Set(&cyl.pos, .6, 0., 0.); + res = ccdMPRPenetration(&box, &cyl, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 2"); + //TOSVT(); + + ccdVec3Set(&cyl.pos, .6, 0.6, 0.); + res = ccdMPRPenetration(&box, &cyl, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 3"); + //TOSVT(); + + ccdVec3Set(&cyl.pos, .6, 0.6, 0.5); + res = ccdMPRPenetration(&box, &cyl, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 4"); + //TOSVT(); + + ccdVec3Set(&axis, 0., 1., 0.); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 3., &axis); + ccdVec3Set(&cyl.pos, .6, 0.6, 0.5); + res = ccdMPRPenetration(&box, &cyl, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 5"); + //TOSVT(); + + ccdVec3Set(&axis, 0.67, 1.1, 0.12); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 4., &axis); + ccdVec3Set(&cyl.pos, .6, 0., 0.5); + res = ccdMPRPenetration(&box, &cyl, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 6"); + //TOSVT(); + + ccdVec3Set(&axis, -0.1, 2.2, -1.); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 5., &axis); + ccdVec3Set(&cyl.pos, .6, 0., 0.5); + ccdVec3Set(&axis, 1., 1., 0.); + ccdQuatSetAngleAxis(&box.quat, -M_PI / 4., &axis); + ccdVec3Set(&box.pos, .6, 0., 0.5); + res = ccdMPRPenetration(&box, &cyl, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 7"); + //TOSVT(); + + ccdVec3Set(&axis, -0.1, 2.2, -1.); + ccdQuatSetAngleAxis(&cyl.quat, M_PI / 5., &axis); + ccdVec3Set(&cyl.pos, .6, 0., 0.5); + ccdVec3Set(&axis, 1., 1., 0.); + ccdQuatSetAngleAxis(&box.quat, -M_PI / 4., &axis); + ccdVec3Set(&box.pos, .9, 0.8, 0.5); + res = ccdMPRPenetration(&box, &cyl, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 8"); + //TOSVT(); +} + diff --git a/libs/ode-0.16.1/libccd/src/testsuites/mpr_boxcyl.h b/libs/ode-0.16.1/libccd/src/testsuites/mpr_boxcyl.h new file mode 100644 index 0000000..86f14e6 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/mpr_boxcyl.h @@ -0,0 +1,16 @@ +#ifndef MPR_TEST_BOXCYL_H +#define MPR_TEST_BOXCYL_H + +#include + +TEST(mprBoxcylIntersect); +TEST(mprBoxcylPen); + +TEST_SUITE(TSMPRBoxCyl){ + TEST_ADD(mprBoxcylIntersect), + TEST_ADD(mprBoxcylPen), + + TEST_SUITE_CLOSURE +}; + +#endif diff --git a/libs/ode-0.16.1/libccd/src/testsuites/mpr_cylcyl.c b/libs/ode-0.16.1/libccd/src/testsuites/mpr_cylcyl.c new file mode 100644 index 0000000..ec0a3bc --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/mpr_cylcyl.c @@ -0,0 +1,179 @@ +#include +#include +#include +#include "support.h" +#include "common.h" + + +TEST(mprCylcylAlignedX) +{ + ccd_t ccd; + CCD_CYL(c1); + CCD_CYL(c2); + size_t i; + int res; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + ccd.center1 = ccdObjCenter; + ccd.center2 = ccdObjCenter; + + c1.radius = 0.35; + c1.height = 0.5; + c2.radius = 0.5; + c2.height = 1.; + + ccdVec3Set(&c1.pos, -5., 0., 0.); + for (i = 0; i < 100; i++){ + res = ccdMPRIntersect(&c1, &c2, &ccd); + + if (i < 42 || i > 58){ + assertFalse(res); + }else{ + assertTrue(res); + } + + c1.pos.v[0] += 0.1; + } +} + +TEST(mprCylcylAlignedY) +{ + ccd_t ccd; + CCD_CYL(c1); + CCD_CYL(c2); + size_t i; + int res; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + ccd.center1 = ccdObjCenter; + ccd.center2 = ccdObjCenter; + + c1.radius = 0.35; + c1.height = 0.5; + c2.radius = 0.5; + c2.height = 1.; + + ccdVec3Set(&c1.pos, 0., -5., 0.); + for (i = 0; i < 100; i++){ + res = ccdMPRIntersect(&c1, &c2, &ccd); + + if (i < 42 || i > 58){ + assertFalse(res); + }else{ + assertTrue(res); + } + + c1.pos.v[1] += 0.1; + } +} + +TEST(mprCylcylAlignedZ) +{ + ccd_t ccd; + CCD_CYL(c1); + CCD_CYL(c2); + size_t i; + int res; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + ccd.center1 = ccdObjCenter; + ccd.center2 = ccdObjCenter; + + c1.radius = 0.35; + c1.height = 0.5; + c2.radius = 0.5; + c2.height = 1.; + + ccdVec3Set(&c1.pos, 0., 0., -5.); + for (i = 0; i < 100; i++){ + res = ccdMPRIntersect(&c1, &c2, &ccd); + + if (i < 43 || i > 57){ + assertFalse(res); + }else{ + assertTrue(res); + } + + c1.pos.v[2] += 0.1; + } +} + +#define TOSVT() \ + svtObjPen(&cyl1, &cyl2, stdout, "Pen 1", depth, &dir, &pos); \ + ccdVec3Scale(&dir, depth); \ + ccdVec3Add(&cyl2.pos, &dir); \ + svtObjPen(&cyl1, &cyl2, stdout, "Pen 1", depth, &dir, &pos) + +TEST(mprCylcylPenetration) +{ + ccd_t ccd; + CCD_CYL(cyl1); + CCD_CYL(cyl2); + int res; + ccd_vec3_t axis; + ccd_real_t depth; + ccd_vec3_t dir, pos; + + fprintf(stderr, "\n\n\n---- mprCylcylPenetration ----\n\n\n"); + + cyl1.radius = 0.35; + cyl1.height = 0.5; + cyl2.radius = 0.5; + cyl2.height = 1.; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + ccd.center1 = ccdObjCenter; + ccd.center2 = ccdObjCenter; + + ccdVec3Set(&cyl2.pos, 0., 0., 0.3); + res = ccdMPRPenetration(&cyl1, &cyl2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 1"); + //TOSVT(); + + ccdVec3Set(&cyl1.pos, 0.3, 0.1, 0.1); + res = ccdMPRPenetration(&cyl1, &cyl2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 2"); + //TOSVT(); + + ccdVec3Set(&axis, 0., 1., 1.); + ccdQuatSetAngleAxis(&cyl2.quat, M_PI / 4., &axis); + ccdVec3Set(&cyl2.pos, 0., 0., 0.); + res = ccdMPRPenetration(&cyl1, &cyl2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 3"); + //TOSVT(); + + ccdVec3Set(&axis, 0., 1., 1.); + ccdQuatSetAngleAxis(&cyl2.quat, M_PI / 4., &axis); + ccdVec3Set(&cyl2.pos, -0.2, 0.7, 0.2); + res = ccdMPRPenetration(&cyl1, &cyl2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 4"); + //TOSVT(); + + ccdVec3Set(&axis, 0.567, 1.2, 1.); + ccdQuatSetAngleAxis(&cyl2.quat, M_PI / 4., &axis); + ccdVec3Set(&cyl2.pos, 0.6, -0.7, 0.2); + res = ccdMPRPenetration(&cyl1, &cyl2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 5"); + //TOSVT(); + + ccdVec3Set(&axis, -4.567, 1.2, 0.); + ccdQuatSetAngleAxis(&cyl2.quat, M_PI / 3., &axis); + ccdVec3Set(&cyl2.pos, 0.6, -0.7, 0.2); + res = ccdMPRPenetration(&cyl1, &cyl2, &ccd, &depth, &dir, &pos); + assertTrue(res == 0); + recPen(depth, &dir, &pos, stdout, "Pen 6"); + //TOSVT(); +} diff --git a/libs/ode-0.16.1/libccd/src/testsuites/mpr_cylcyl.h b/libs/ode-0.16.1/libccd/src/testsuites/mpr_cylcyl.h new file mode 100644 index 0000000..2d2162b --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/mpr_cylcyl.h @@ -0,0 +1,23 @@ +#ifndef MPR_CYL_CYL +#define MPR_CYL_CYL + +#include + +TEST(mprCylcylAlignedX); +TEST(mprCylcylAlignedY); +TEST(mprCylcylAlignedZ); + +TEST(mprCylcylPenetration); + +TEST_SUITE(TSMPRCylCyl) { + TEST_ADD(mprCylcylAlignedX), + TEST_ADD(mprCylcylAlignedY), + TEST_ADD(mprCylcylAlignedZ), + + TEST_ADD(mprCylcylPenetration), + + TEST_SUITE_CLOSURE +}; + +#endif + diff --git a/libs/ode-0.16.1/libccd/src/testsuites/polytope.c b/libs/ode-0.16.1/libccd/src/testsuites/polytope.c new file mode 100644 index 0000000..65686fb --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/polytope.c @@ -0,0 +1,398 @@ +//#undef NDEBUG +#include +#include +#include + +TEST(ptSetUp) +{ +} + +TEST(ptTearDown) +{ +} + + +TEST(ptCreate1) +{ + ccd_pt_t pt; + ccd_pt_vertex_t *v[3]; + ccd_pt_edge_t *e[3]; + ccd_pt_face_t *f; + ccd_vec3_t u; + int res; + size_t i; + + DBG2("------"); + + ccdPtInit(&pt); + ccdPtDestroy(&pt); + + + ccdPtInit(&pt); + + ccdVec3Set(&u, -1., -1., 0.); + v[0] = ccdPtAddVertexCoords(&pt, -1., -1., 0.); + assertTrue(ccdVec3Eq(&u, &v[0]->v.v)); + + ccdVec3Set(&u, 1., 0., 0.); + v[1] = ccdPtAddVertexCoords(&pt, 1., 0., 0.); + assertTrue(ccdVec3Eq(&u, &v[1]->v.v)); + + ccdVec3Set(&u, 0., 0., 1.); + v[2] = ccdPtAddVertexCoords(&pt, 0., 0., 1.); + assertTrue(ccdVec3Eq(&u, &v[2]->v.v)); + + for (i = 0; i < 3; i++){ + assertTrue(ccdEq(v[i]->dist, ccdVec3Len2(&v[i]->v.v))); + } + + + e[0] = ccdPtAddEdge(&pt, v[0], v[1]); + e[1] = ccdPtAddEdge(&pt, v[1], v[2]); + e[2] = ccdPtAddEdge(&pt, v[2], v[0]); + for (i = 0; i < 3; i++){ + DBG("e[%d]->dist: %lf", i, e[i]->dist); + DBG_VEC3(&e[i]->witness, " ->witness: "); + } + + f = ccdPtAddFace(&pt, e[0], e[1], e[2]); + DBG("f->dist: %lf", f->dist); + DBG_VEC3(&f->witness, " ->witness: "); + + for (i = 0; i < 3; i++){ + res = ccdPtDelVertex(&pt, v[i]); + assertFalse(res == 0); + res = ccdPtDelEdge(&pt, e[i]); + assertFalse(res == 0); + } + + ccdPtDelFace(&pt, f); + for (i = 0; i < 3; i++){ + res = ccdPtDelVertex(&pt, v[i]); + assertFalse(res == 0); + } + for (i = 0; i < 3; i++){ + res = ccdPtDelEdge(&pt, e[i]); + assertTrue(res == 0); + } + for (i = 0; i < 3; i++){ + res = ccdPtDelVertex(&pt, v[i]); + assertTrue(res == 0); + } + + v[0] = ccdPtAddVertexCoords(&pt, -1., -1., 0.); + v[1] = ccdPtAddVertexCoords(&pt, 1., 0., 0.); + v[2] = ccdPtAddVertexCoords(&pt, 0., 0., 1.); + + e[0] = ccdPtAddEdge(&pt, v[0], v[1]); + e[1] = ccdPtAddEdge(&pt, v[1], v[2]); + e[2] = ccdPtAddEdge(&pt, v[2], v[0]); + + f = ccdPtAddFace(&pt, e[0], e[1], e[2]); + + ccdPtDestroy(&pt); +} + +TEST(ptCreate2) +{ + ccd_pt_t pt; + ccd_pt_vertex_t *v[4]; + ccd_pt_edge_t *e[6]; + ccd_pt_face_t *f[4]; + ccd_vec3_t u; + int res; + unsigned int i; + + DBG2("------"); + + ccdPtInit(&pt); + + ccdVec3Set(&u, -1., -1., 0.); + v[0] = ccdPtAddVertexCoords(&pt, -1., -1., 0.); + assertTrue(ccdVec3Eq(&u, &v[0]->v.v)); + + ccdVec3Set(&u, 1., 0., 0.); + v[1] = ccdPtAddVertexCoords(&pt, 1., 0., 0.); + assertTrue(ccdVec3Eq(&u, &v[1]->v.v)); + + ccdVec3Set(&u, 0., 0., 1.); + v[2] = ccdPtAddVertexCoords(&pt, 0., 0., 1.); + assertTrue(ccdVec3Eq(&u, &v[2]->v.v)); + + ccdVec3Set(&u, 0., 1., 0.); + v[3] = ccdPtAddVertexCoords(&pt, 0., 1., 0.); + assertTrue(ccdVec3Eq(&u, &v[3]->v.v)); + + for (i = 0; i < 4; i++){ + assertTrue(ccdEq(v[i]->dist, ccdVec3Len2(&v[i]->v.v))); + } + for (i = 0; i < 4; i++){ + DBG("v[%d]->dist: %lf", i, v[i]->dist); + DBG_VEC3(&v[i]->witness, " ->witness: "); + } + + e[0] = ccdPtAddEdge(&pt, v[0], v[1]); + e[1] = ccdPtAddEdge(&pt, v[1], v[2]); + e[2] = ccdPtAddEdge(&pt, v[2], v[0]); + e[3] = ccdPtAddEdge(&pt, v[3], v[0]); + e[4] = ccdPtAddEdge(&pt, v[3], v[1]); + e[5] = ccdPtAddEdge(&pt, v[3], v[2]); + for (i = 0; i < 6; i++){ + DBG("e[%d]->dist: %lf", i, e[i]->dist); + DBG_VEC3(&e[i]->witness, " ->witness: "); + } + + f[0] = ccdPtAddFace(&pt, e[0], e[1], e[2]); + f[1] = ccdPtAddFace(&pt, e[3], e[4], e[0]); + f[2] = ccdPtAddFace(&pt, e[4], e[5], e[1]); + f[3] = ccdPtAddFace(&pt, e[5], e[3], e[2]); + for (i = 0; i < 4; i++){ + DBG("f[%d]->dist: %lf", i, f[i]->dist); + DBG_VEC3(&f[i]->witness, " ->witness: "); + } + + for (i = 0; i < 4; i++){ + res = ccdPtDelVertex(&pt, v[i]); + assertFalse(res == 0); + } + for (i = 0; i < 6; i++){ + res = ccdPtDelEdge(&pt, e[i]); + assertFalse(res == 0); + } + + res = ccdPtDelFace(&pt, f[0]); + for (i = 0; i < 6; i++){ + res = ccdPtDelEdge(&pt, e[i]); + assertFalse(res == 0); + } + + res = ccdPtDelFace(&pt, f[1]); + assertTrue(ccdPtDelEdge(&pt, e[0]) == 0); + assertFalse(ccdPtDelEdge(&pt, e[1]) == 0); + assertFalse(ccdPtDelEdge(&pt, e[2]) == 0); + assertFalse(ccdPtDelEdge(&pt, e[3]) == 0); + assertFalse(ccdPtDelEdge(&pt, e[4]) == 0); + assertFalse(ccdPtDelEdge(&pt, e[5]) == 0); + for (i = 0; i < 4; i++){ + res = ccdPtDelVertex(&pt, v[i]); + assertFalse(res == 0); + } + + res = ccdPtDelFace(&pt, f[2]); + assertTrue(ccdPtDelEdge(&pt, e[1]) == 0); + assertTrue(ccdPtDelEdge(&pt, e[4]) == 0); + assertFalse(ccdPtDelEdge(&pt, e[2]) == 0); + assertFalse(ccdPtDelEdge(&pt, e[3]) == 0); + assertFalse(ccdPtDelEdge(&pt, e[5]) == 0); + + assertTrue(ccdPtDelVertex(&pt, v[1]) == 0); + assertFalse(ccdPtDelVertex(&pt, v[0]) == 0); + assertFalse(ccdPtDelVertex(&pt, v[2]) == 0); + assertFalse(ccdPtDelVertex(&pt, v[3]) == 0); + + res = ccdPtDelFace(&pt, f[3]); + assertTrue(ccdPtDelEdge(&pt, e[2]) == 0); + assertTrue(ccdPtDelEdge(&pt, e[3]) == 0); + assertTrue(ccdPtDelEdge(&pt, e[5]) == 0); + + assertTrue(ccdPtDelVertex(&pt, v[0]) == 0); + assertTrue(ccdPtDelVertex(&pt, v[2]) == 0); + assertTrue(ccdPtDelVertex(&pt, v[3]) == 0); + + + v[0] = ccdPtAddVertexCoords(&pt, -1., -1., 0.); + v[1] = ccdPtAddVertexCoords(&pt, 1., 0., 0.); + v[2] = ccdPtAddVertexCoords(&pt, 0., 0., 1.); + v[3] = ccdPtAddVertexCoords(&pt, 0., 1., 0.); + + e[0] = ccdPtAddEdge(&pt, v[0], v[1]); + e[1] = ccdPtAddEdge(&pt, v[1], v[2]); + e[2] = ccdPtAddEdge(&pt, v[2], v[0]); + e[3] = ccdPtAddEdge(&pt, v[3], v[0]); + e[4] = ccdPtAddEdge(&pt, v[3], v[1]); + e[5] = ccdPtAddEdge(&pt, v[3], v[2]); + + f[0] = ccdPtAddFace(&pt, e[0], e[1], e[2]); + f[1] = ccdPtAddFace(&pt, e[3], e[4], e[0]); + f[2] = ccdPtAddFace(&pt, e[4], e[5], e[1]); + f[3] = ccdPtAddFace(&pt, e[5], e[3], e[2]); + + ccdPtDestroy(&pt); +} + +TEST(ptNearest) +{ + ccd_pt_t pt; + ccd_pt_vertex_t *v[4]; + ccd_pt_edge_t *e[6]; + ccd_pt_face_t *f[4]; + ccd_pt_el_t *nearest; + + DBG2("------"); + + ccdPtInit(&pt); + + v[0] = ccdPtAddVertexCoords(&pt, -1., -1., 0.); + v[1] = ccdPtAddVertexCoords(&pt, 1., 0., 0.); + v[2] = ccdPtAddVertexCoords(&pt, 0., 0., 1.); + v[3] = ccdPtAddVertexCoords(&pt, 0., 1., 0.); + + e[0] = ccdPtAddEdge(&pt, v[0], v[1]); + e[1] = ccdPtAddEdge(&pt, v[1], v[2]); + e[2] = ccdPtAddEdge(&pt, v[2], v[0]); + e[3] = ccdPtAddEdge(&pt, v[3], v[0]); + e[4] = ccdPtAddEdge(&pt, v[3], v[1]); + e[5] = ccdPtAddEdge(&pt, v[3], v[2]); + + f[0] = ccdPtAddFace(&pt, e[0], e[1], e[2]); + f[1] = ccdPtAddFace(&pt, e[3], e[4], e[0]); + f[2] = ccdPtAddFace(&pt, e[4], e[5], e[1]); + f[3] = ccdPtAddFace(&pt, e[5], e[3], e[2]); + + nearest = ccdPtNearest(&pt); + //DBG("nearest->type: %d", nearest->type); + //DBG(" ->dist: %lf", nearest->dist); + //DBG_VEC3(&nearest->witness, " ->witness: "); + assertEquals(nearest->type, CCD_PT_FACE); + assertEquals(nearest, (ccd_pt_el_t *)f[1]); + assertTrue(ccdPtDelFace(&pt, f[1]) == 0); + + + nearest = ccdPtNearest(&pt); + //DBG("nearest->type: %d", nearest->type); + //DBG(" ->dist: %lf", nearest->dist); + //DBG_VEC3(&nearest->witness, " ->witness: "); + assertEquals(nearest->type, CCD_PT_FACE); + assertTrue(nearest == (ccd_pt_el_t *)f[0] + || nearest == (ccd_pt_el_t *)f[3]); + assertTrue(ccdPtDelFace(&pt, (ccd_pt_face_t *)nearest) == 0); + + + nearest = ccdPtNearest(&pt); + //DBG("nearest->type: %d", nearest->type); + //DBG(" ->dist: %lf", nearest->dist); + //DBG_VEC3(&nearest->witness, " ->witness: "); + assertEquals(nearest->type, CCD_PT_FACE); + assertTrue(nearest == (ccd_pt_el_t *)f[0] + || nearest == (ccd_pt_el_t *)f[3]); + assertTrue(ccdPtDelFace(&pt, (ccd_pt_face_t *)nearest) == 0); + + + nearest = ccdPtNearest(&pt); + //DBG("nearest->type: %d", nearest->type); + //DBG(" ->dist: %lf", nearest->dist); + //DBG_VEC3(&nearest->witness, " ->witness: "); + assertEquals(nearest->type, CCD_PT_EDGE); + assertTrue(nearest == (ccd_pt_el_t *)e[0] + || nearest == (ccd_pt_el_t *)e[3]); + assertTrue(ccdPtDelEdge(&pt, (ccd_pt_edge_t *)nearest) == 0); + + + nearest = ccdPtNearest(&pt); + //DBG("nearest->type: %d", nearest->type); + //DBG(" ->dist: %lf", nearest->dist); + //DBG_VEC3(&nearest->witness, " ->witness: "); + assertEquals(nearest->type, CCD_PT_EDGE); + assertTrue(nearest == (ccd_pt_el_t *)e[0] + || nearest == (ccd_pt_el_t *)e[3]); + assertTrue(ccdPtDelEdge(&pt, (ccd_pt_edge_t *)nearest) == 0); + + + nearest = ccdPtNearest(&pt); + //DBG("nearest->type: %d", nearest->type); + //DBG(" ->dist: %lf", nearest->dist); + //DBG_VEC3(&nearest->witness, " ->witness: "); + assertEquals(nearest->type, CCD_PT_FACE); + assertEquals(nearest, (ccd_pt_el_t *)f[2]); + assertTrue(ccdPtDelFace(&pt, f[2]) == 0); + + + nearest = ccdPtNearest(&pt); + //DBG("nearest->type: %d", nearest->type); + //DBG(" ->dist: %lf", nearest->dist); + //DBG_VEC3(&nearest->witness, " ->witness: "); + assertEquals(nearest->type, CCD_PT_EDGE); + assertTrue(nearest == (ccd_pt_el_t *)e[1] + || nearest == (ccd_pt_el_t *)e[4] + || nearest == (ccd_pt_el_t *)e[5]); + assertTrue(ccdPtDelEdge(&pt, (ccd_pt_edge_t *)nearest) == 0); + + + nearest = ccdPtNearest(&pt); + //DBG("nearest->type: %d", nearest->type); + //DBG(" ->dist: %lf", nearest->dist); + //DBG_VEC3(&nearest->witness, " ->witness: "); + assertEquals(nearest->type, CCD_PT_EDGE); + assertTrue(nearest == (ccd_pt_el_t *)e[1] + || nearest == (ccd_pt_el_t *)e[4] + || nearest == (ccd_pt_el_t *)e[5]); + assertTrue(ccdPtDelEdge(&pt, (ccd_pt_edge_t *)nearest) == 0); + + + nearest = ccdPtNearest(&pt); + //DBG("nearest->type: %d", nearest->type); + //DBG(" ->dist: %lf", nearest->dist); + //DBG_VEC3(&nearest->witness, " ->witness: "); + assertEquals(nearest->type, CCD_PT_EDGE); + assertTrue(nearest == (ccd_pt_el_t *)e[1] + || nearest == (ccd_pt_el_t *)e[4] + || nearest == (ccd_pt_el_t *)e[5]); + assertTrue(ccdPtDelEdge(&pt, (ccd_pt_edge_t *)nearest) == 0); + + + nearest = ccdPtNearest(&pt); + //DBG("nearest->type: %d", nearest->type); + //DBG(" ->dist: %lf", nearest->dist); + //DBG_VEC3(&nearest->witness, " ->witness: "); + assertEquals(nearest->type, CCD_PT_EDGE); + assertTrue(nearest == (ccd_pt_el_t *)e[2]); + assertTrue(ccdPtDelEdge(&pt, (ccd_pt_edge_t *)nearest) == 0); + + + nearest = ccdPtNearest(&pt); + //DBG("nearest->type: %d", nearest->type); + //DBG(" ->dist: %lf", nearest->dist); + //DBG_VEC3(&nearest->witness, " ->witness: "); + assertEquals(nearest->type, CCD_PT_VERTEX); + assertTrue(nearest == (ccd_pt_el_t *)v[1] + || nearest == (ccd_pt_el_t *)v[2] + || nearest == (ccd_pt_el_t *)v[3]); + assertTrue(ccdPtDelVertex(&pt, (ccd_pt_vertex_t *)nearest) == 0); + + + nearest = ccdPtNearest(&pt); + //DBG("nearest->type: %d", nearest->type); + //DBG(" ->dist: %lf", nearest->dist); + //DBG_VEC3(&nearest->witness, " ->witness: "); + assertEquals(nearest->type, CCD_PT_VERTEX); + assertTrue(nearest == (ccd_pt_el_t *)v[1] + || nearest == (ccd_pt_el_t *)v[2] + || nearest == (ccd_pt_el_t *)v[3]); + assertTrue(ccdPtDelVertex(&pt, (ccd_pt_vertex_t *)nearest) == 0); + + + nearest = ccdPtNearest(&pt); + //DBG("nearest->type: %d", nearest->type); + //DBG(" ->dist: %lf", nearest->dist); + //DBG_VEC3(&nearest->witness, " ->witness: "); + assertEquals(nearest->type, CCD_PT_VERTEX); + assertTrue(nearest == (ccd_pt_el_t *)v[1] + || nearest == (ccd_pt_el_t *)v[2] + || nearest == (ccd_pt_el_t *)v[3]); + assertTrue(ccdPtDelVertex(&pt, (ccd_pt_vertex_t *)nearest) == 0); + + + nearest = ccdPtNearest(&pt); + //DBG("nearest->type: %d", nearest->type); + //DBG(" ->dist: %lf", nearest->dist); + //DBG_VEC3(&nearest->witness, " ->witness: "); + assertEquals(nearest->type, CCD_PT_VERTEX); + assertTrue(nearest == (ccd_pt_el_t *)v[0]); + assertTrue(ccdPtDelVertex(&pt, (ccd_pt_vertex_t *)nearest) == 0); + + + nearest = ccdPtNearest(&pt); + assertTrue(nearest == NULL); + + ccdPtDestroy(&pt); +} diff --git a/libs/ode-0.16.1/libccd/src/testsuites/polytope.h b/libs/ode-0.16.1/libccd/src/testsuites/polytope.h new file mode 100644 index 0000000..cf31546 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/polytope.h @@ -0,0 +1,24 @@ +#ifndef TEST_POLYTOPE_H +#define TEST_POLYTOPE_H + +#include + +TEST(ptSetUp); +TEST(ptTearDown); + +TEST(ptCreate1); +TEST(ptCreate2); +TEST(ptNearest); + +TEST_SUITE(TSPt) { + TEST_ADD(ptSetUp), + + TEST_ADD(ptCreate1), + TEST_ADD(ptCreate2), + TEST_ADD(ptNearest), + + TEST_ADD(ptTearDown), + TEST_SUITE_CLOSURE +}; + +#endif diff --git a/libs/ode-0.16.1/libccd/src/testsuites/spheresphere.c b/libs/ode-0.16.1/libccd/src/testsuites/spheresphere.c new file mode 100644 index 0000000..36628f6 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/spheresphere.c @@ -0,0 +1,99 @@ +#include +#include +#include "support.h" +#include + +TEST(spheresphereSetUp) +{ +} + +TEST(spheresphereTearDown) +{ +} + +TEST(spheresphereAlignedX) +{ + ccd_t ccd; + CCD_SPHERE(s1); + CCD_SPHERE(s2); + size_t i; + int res; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + + s1.radius = 0.35; + s2.radius = .5; + + ccdVec3Set(&s1.pos, -5., 0., 0.); + for (i = 0; i < 100; i++){ + res = ccdGJKIntersect(&s1, &s2, &ccd); + + if (i < 42 || i > 58){ + assertFalse(res); + }else{ + assertTrue(res); + } + + s1.pos.v[0] += 0.1; + } +} + +TEST(spheresphereAlignedY) +{ + ccd_t ccd; + CCD_SPHERE(s1); + CCD_SPHERE(s2); + size_t i; + int res; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + + s1.radius = 0.35; + s2.radius = .5; + + ccdVec3Set(&s1.pos, 0., -5., 0.); + for (i = 0; i < 100; i++){ + res = ccdGJKIntersect(&s1, &s2, &ccd); + + if (i < 42 || i > 58){ + assertFalse(res); + }else{ + assertTrue(res); + } + + s1.pos.v[1] += 0.1; + } +} + +TEST(spheresphereAlignedZ) +{ + ccd_t ccd; + CCD_SPHERE(s1); + CCD_SPHERE(s2); + size_t i; + int res; + + CCD_INIT(&ccd); + ccd.support1 = ccdSupport; + ccd.support2 = ccdSupport; + + s1.radius = 0.35; + s2.radius = .5; + + ccdVec3Set(&s1.pos, 0., 0., -5.); + for (i = 0; i < 100; i++){ + res = ccdGJKIntersect(&s1, &s2, &ccd); + + if (i < 42 || i > 58){ + assertFalse(res); + }else{ + assertTrue(res); + } + + s1.pos.v[2] += 0.1; + } +} diff --git a/libs/ode-0.16.1/libccd/src/testsuites/spheresphere.h b/libs/ode-0.16.1/libccd/src/testsuites/spheresphere.h new file mode 100644 index 0000000..b032215 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/spheresphere.h @@ -0,0 +1,24 @@ +#ifndef SPHERE_SPHERE +#define SPHERE_SPHERE + +#include + +TEST(spheresphereSetUp); +TEST(spheresphereTearDown); + +TEST(spheresphereAlignedX); +TEST(spheresphereAlignedY); +TEST(spheresphereAlignedZ); + +TEST_SUITE(TSSphereSphere) { + TEST_ADD(spheresphereSetUp), + + TEST_ADD(spheresphereAlignedX), + TEST_ADD(spheresphereAlignedY), + TEST_ADD(spheresphereAlignedZ), + + TEST_ADD(spheresphereTearDown), + TEST_SUITE_CLOSURE +}; + +#endif diff --git a/libs/ode-0.16.1/libccd/src/testsuites/support.c b/libs/ode-0.16.1/libccd/src/testsuites/support.c new file mode 100644 index 0000000..5f2b4c7 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/support.c @@ -0,0 +1,85 @@ +/*** + * libccd + * --------------------------------- + * Copyright (c)2010 Daniel Fiser + * + * + * This file is part of libccd. + * + * Distributed under the OSI-approved BSD License (the "License"); + * see accompanying file BDS-LICENSE for details or see + * . + * + * This software is distributed WITHOUT ANY WARRANTY; without even the + * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the License for more information. + */ + +#include +#include +#include +#include "support.h" + +void ccdSupport(const void *_obj, const ccd_vec3_t *_dir, + ccd_vec3_t *v) +{ + // Support function is made according to Gino van den Bergen's paper + // A Fast and Robust CCD Implementation for Collision Detection of + // Convex Objects + + ccd_obj_t *obj = (ccd_obj_t *)_obj; + ccd_vec3_t dir; + ccd_quat_t qinv; + + ccdVec3Copy(&dir, _dir); + ccdQuatInvert2(&qinv, &obj->quat); + + ccdQuatRotVec(&dir, &qinv); + + if (obj->type == CCD_OBJ_BOX){ + ccd_box_t *box = (ccd_box_t *)obj; + ccdVec3Set(v, ccdSign(ccdVec3X(&dir)) * box->x * CCD_REAL(0.5), + ccdSign(ccdVec3Y(&dir)) * box->y * CCD_REAL(0.5), + ccdSign(ccdVec3Z(&dir)) * box->z * CCD_REAL(0.5)); + }else if (obj->type == CCD_OBJ_SPHERE){ + ccd_sphere_t *sphere = (ccd_sphere_t *)obj; + ccd_real_t len; + + len = ccdVec3Len2(&dir); + if (len - CCD_EPS > CCD_ZERO){ + ccdVec3Copy(v, &dir); + ccdVec3Scale(v, sphere->radius / CCD_SQRT(len)); + }else{ + ccdVec3Set(v, CCD_ZERO, CCD_ZERO, CCD_ZERO); + } + }else if (obj->type == CCD_OBJ_CYL){ + ccd_cyl_t *cyl = (ccd_cyl_t *)obj; + ccd_real_t zdist, rad; + + zdist = dir.v[0] * dir.v[0] + dir.v[1] * dir.v[1]; + zdist = CCD_SQRT(zdist); + if (ccdIsZero(zdist)){ + ccdVec3Set(v, CCD_ZERO, CCD_ZERO, + ccdSign(ccdVec3Z(&dir)) * cyl->height * CCD_REAL(0.5)); + }else{ + rad = cyl->radius / zdist; + + ccdVec3Set(v, rad * ccdVec3X(&dir), + rad * ccdVec3Y(&dir), + ccdSign(ccdVec3Z(&dir)) * cyl->height * CCD_REAL(0.5)); + } + } + + // transform support vertex + ccdQuatRotVec(v, &obj->quat); + ccdVec3Add(v, &obj->pos); +} + +void ccdObjCenter(const void *_obj, ccd_vec3_t *center) +{ + ccd_obj_t *obj = (ccd_obj_t *)_obj; + + ccdVec3Set(center, CCD_ZERO, CCD_ZERO, CCD_ZERO); + // rotation is not needed + ccdVec3Add(center, &obj->pos); +} diff --git a/libs/ode-0.16.1/libccd/src/testsuites/support.h b/libs/ode-0.16.1/libccd/src/testsuites/support.h new file mode 100644 index 0000000..e444296 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/support.h @@ -0,0 +1,102 @@ +/*** + * libccd + * --------------------------------- + * Copyright (c)2010 Daniel Fiser + * + * + * This file is part of libccd. + * + * Distributed under the OSI-approved BSD License (the "License"); + * see accompanying file BDS-LICENSE for details or see + * . + * + * This software is distributed WITHOUT ANY WARRANTY; without even the + * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the License for more information. + */ + +/*** + * Some support() functions for some convex shapes. + */ + +#ifndef __CCD_SUPPORT_H__ +#define __CCD_SUPPORT_H__ + +#include + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +#define CCD_OBJ_BOX 1 +#define CCD_OBJ_SPHERE 2 +#define CCD_OBJ_CYL 3 + +#define __CCD_OBJ__ \ + int type; \ + ccd_vec3_t pos; \ + ccd_quat_t quat; + +struct _ccd_obj_t { + __CCD_OBJ__ +}; +typedef struct _ccd_obj_t ccd_obj_t; + +struct _ccd_box_t { + __CCD_OBJ__ + ccd_real_t x, y, z; //!< Lengths of box's edges +}; +typedef struct _ccd_box_t ccd_box_t; + +struct _ccd_sphere_t { + __CCD_OBJ__ + ccd_real_t radius; +}; +typedef struct _ccd_sphere_t ccd_sphere_t; + +struct _ccd_cyl_t { + __CCD_OBJ__ + ccd_real_t radius; + ccd_real_t height; +}; +typedef struct _ccd_cyl_t ccd_cyl_t; + + +#define CCD_BOX(name) \ + ccd_box_t name = { .type = CCD_OBJ_BOX, \ + .pos = { .v = { 0., 0., 0. } }, \ + .quat = { .q = { 0., 0., 0., 1. } }, \ + .x = 0., \ + .y = 0., \ + .z = 0. } + +#define CCD_SPHERE(name) \ + ccd_sphere_t name = { .type = CCD_OBJ_SPHERE, \ + .pos = { .v = { 0., 0., 0. } }, \ + .quat = { .q = { 0., 0., 0., 1. } }, \ + .radius = 0. } + +#define CCD_CYL(name) \ + ccd_cyl_t name = { .type = CCD_OBJ_CYL, \ + .pos = { .v = { 0., 0., 0. } }, \ + .quat = { .q = { 0., 0., 0., 1. } }, \ + .radius = 0., \ + .height = 0. } + +/** + * Returns supporting vertex via v. + * Supporting vertex is fathest vertex from object in direction dir. + */ +void ccdSupport(const void *obj, const ccd_vec3_t *dir, + ccd_vec3_t *v); + +/** + * Returns center of object. + */ +void ccdObjCenter(const void *obj, ccd_vec3_t *center); + +#ifdef __cplusplus +} /* extern "C" */ +#endif /* __cplusplus */ + +#endif /* __CCD_SUPPORT_H__ */ diff --git a/libs/ode-0.16.1/libccd/src/testsuites/vec3.c b/libs/ode-0.16.1/libccd/src/testsuites/vec3.c new file mode 100644 index 0000000..007f310 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/vec3.c @@ -0,0 +1,273 @@ +#include +#include +#include + +TEST(vec3SetUp) +{ +} + +TEST(vec3TearDown) +{ +} + + +TEST(vec3PointSegmentDist) +{ + ccd_vec3_t P, a, b, w, ew; + ccd_real_t dist; + + ccdVec3Set(&a, 0., 0., 0.); + ccdVec3Set(&b, 1., 0., 0.); + + // extereme w == a + ccdVec3Set(&P, -1., 0., 0.); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, 1.)); + assertTrue(ccdVec3Eq(&w, &a)); + + ccdVec3Set(&P, -0.5, 0., 0.); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, 0.5 * 0.5)); + assertTrue(ccdVec3Eq(&w, &a)); + + ccdVec3Set(&P, -0.1, 0., 0.); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, .1 * .1)); + assertTrue(ccdVec3Eq(&w, &a)); + + ccdVec3Set(&P, 0., 0., 0.); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, 0.)); + assertTrue(ccdVec3Eq(&w, &a)); + + ccdVec3Set(&P, -1., 1., 0.); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, 2.)); + assertTrue(ccdVec3Eq(&w, &a)); + + ccdVec3Set(&P, -0.5, 0.5, 0.); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, 0.5)); + assertTrue(ccdVec3Eq(&w, &a)); + + ccdVec3Set(&P, -0.1, -1., 2.); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, 5.01)); + assertTrue(ccdVec3Eq(&w, &a)); + + + // extereme w == b + ccdVec3Set(&P, 2., 0., 0.); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, 1.)); + assertTrue(ccdVec3Eq(&w, &b)); + + ccdVec3Set(&P, 1.5, 0., 0.); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, 0.5 * 0.5)); + assertTrue(ccdVec3Eq(&w, &b)); + + ccdVec3Set(&P, 1.1, 0., 0.); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, .1 * .1)); + assertTrue(ccdVec3Eq(&w, &b)); + + ccdVec3Set(&P, 1., 0., 0.); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, 0.)); + assertTrue(ccdVec3Eq(&w, &b)); + + ccdVec3Set(&P, 2., 1., 0.); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, 2.)); + assertTrue(ccdVec3Eq(&w, &b)); + + ccdVec3Set(&P, 1.5, 0.5, 0.); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, 0.5)); + assertTrue(ccdVec3Eq(&w, &b)); + + ccdVec3Set(&P, 1.1, -1., 2.); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, 5.01)); + assertTrue(ccdVec3Eq(&w, &b)); + + // inside segment + ccdVec3Set(&P, .5, 0., 0.); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, 0.)); + assertTrue(ccdVec3Eq(&w, &P)); + + ccdVec3Set(&P, .9, 0., 0.); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, 0.)); + assertTrue(ccdVec3Eq(&w, &P)); + + ccdVec3Set(&P, .5, 1., 0.); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, 1.)); + ccdVec3Set(&ew, 0.5, 0., 0.); + assertTrue(ccdVec3Eq(&w, &ew)); + + ccdVec3Set(&P, .5, 1., 1.); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, 2.)); + ccdVec3Set(&ew, 0.5, 0., 0.); + assertTrue(ccdVec3Eq(&w, &ew)); + + + + ccdVec3Set(&a, -.5, 2., 1.); + ccdVec3Set(&b, 1., 1.5, 0.5); + + // extereme w == a + ccdVec3Set(&P, -10., 0., 0.); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, 9.5 * 9.5 + 2. * 2. + 1.)); + assertTrue(ccdVec3Eq(&w, &a)); + + ccdVec3Set(&P, -10., 9.2, 3.4); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, 9.5 * 9.5 + 7.2 * 7.2 + 2.4 * 2.4)); + assertTrue(ccdVec3Eq(&w, &a)); + + // extereme w == b + ccdVec3Set(&P, 10., 0., 0.); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, 9. * 9. + 1.5 * 1.5 + 0.5 * 0.5)); + assertTrue(ccdVec3Eq(&w, &b)); + + ccdVec3Set(&P, 10., 9.2, 3.4); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, 9. * 9. + 7.7 * 7.7 + 2.9 * 2.9)); + assertTrue(ccdVec3Eq(&w, &b)); + + // inside ab + ccdVec3Set(&a, -.1, 1., 1.); + ccdVec3Set(&b, 1., 1., 1.); + ccdVec3Set(&P, 0., 0., 0.); + dist = ccdVec3PointSegmentDist2(&P, &a, &b, &w); + assertTrue(ccdEq(dist, 2.)); + ccdVec3Set(&ew, 0., 1., 1.); + assertTrue(ccdVec3Eq(&w, &ew)); +} + + +TEST(vec3PointTriDist) +{ + ccd_vec3_t P, a, b, c, w, P0; + ccd_real_t dist; + + ccdVec3Set(&a, -1., 0., 0.); + ccdVec3Set(&b, 0., 1., 1.); + ccdVec3Set(&c, -1., 0., 1.); + + ccdVec3Set(&P, -1., 0., 0.); + dist = ccdVec3PointTriDist2(&P, &a, &b, &c, &w); + assertTrue(ccdEq(dist, 0.)); + assertTrue(ccdVec3Eq(&w, &a)); + + ccdVec3Set(&P, 0., 1., 1.); + dist = ccdVec3PointTriDist2(&P, &a, &b, &c, &w); + assertTrue(ccdEq(dist, 0.)); + assertTrue(ccdVec3Eq(&w, &b)); + + ccdVec3Set(&P, -1., 0., 1.); + dist = ccdVec3PointTriDist2(&P, &a, &b, &c, &w); + assertTrue(ccdEq(dist, 0.)); + assertTrue(ccdVec3Eq(&w, &c)); + + ccdVec3Set(&P, 0., 0., 0.); + dist = ccdVec3PointTriDist2(&P, &a, &b, &c, NULL); + assertTrue(ccdEq(dist, 2./3.)); + + + // region 4 + ccdVec3Set(&P, -2., 0., 0.); + dist = ccdVec3PointTriDist2(&P, &a, &b, &c, &w); + assertTrue(ccdEq(dist, ccdVec3Dist2(&P, &a))); + assertTrue(ccdVec3Eq(&w, &a)); + ccdVec3Set(&P, -2., 0.2, -1.); + dist = ccdVec3PointTriDist2(&P, &a, &b, &c, &w); + assertTrue(ccdEq(dist, ccdVec3Dist2(&P, &a))); + assertTrue(ccdVec3Eq(&w, &a)); + + // region 2 + ccdVec3Set(&P, -1.3, 0., 1.2); + dist = ccdVec3PointTriDist2(&P, &a, &b, &c, &w); + assertTrue(ccdEq(dist, ccdVec3Dist2(&P, &c))); + assertTrue(ccdVec3Eq(&w, &c)); + ccdVec3Set(&P, -1.2, 0.2, 1.1); + dist = ccdVec3PointTriDist2(&P, &a, &b, &c, &w); + assertTrue(ccdEq(dist, ccdVec3Dist2(&P, &c))); + assertTrue(ccdVec3Eq(&w, &c)); + + // region 6 + ccdVec3Set(&P, 0.3, 1., 1.); + dist = ccdVec3PointTriDist2(&P, &a, &b, &c, &w); + assertTrue(ccdEq(dist, ccdVec3Dist2(&P, &b))); + assertTrue(ccdVec3Eq(&w, &b)); + ccdVec3Set(&P, .1, 1., 1.); + dist = ccdVec3PointTriDist2(&P, &a, &b, &c, &w); + assertTrue(ccdEq(dist, ccdVec3Dist2(&P, &b))); + assertTrue(ccdVec3Eq(&w, &b)); + + // region 1 + ccdVec3Set(&P, 0., 1., 2.); + dist = ccdVec3PointTriDist2(&P, &a, &b, &c, &w); + assertTrue(ccdEq(dist, 1.)); + assertTrue(ccdVec3Eq(&w, &b)); + ccdVec3Set(&P, -1., 0., 2.); + dist = ccdVec3PointTriDist2(&P, &a, &b, &c, &w); + assertTrue(ccdEq(dist, 1.)); + assertTrue(ccdVec3Eq(&w, &c)); + ccdVec3Set(&P, -0.5, 0.5, 2.); + dist = ccdVec3PointTriDist2(&P, &a, &b, &c, &w); + assertTrue(ccdEq(dist, 1.)); + ccdVec3Set(&P0, -0.5, 0.5, 1.); + assertTrue(ccdVec3Eq(&w, &P0)); + + // region 3 + ccdVec3Set(&P, -2., -1., 0.7); + dist = ccdVec3PointTriDist2(&P, &a, &b, &c, &w); + assertTrue(ccdEq(dist, 2.)); + ccdVec3Set(&P0, -1., 0., 0.7); + assertTrue(ccdVec3Eq(&w, &P0)); + + // region 5 + ccdVec3Set(&P, 0., 0., 0.); + dist = ccdVec3PointTriDist2(&P, &a, &b, &c, &w); + assertTrue(ccdEq(dist, 2./3.)); + ccdVec3Set(&P0, -2./3., 1./3., 1./3.); + assertTrue(ccdVec3Eq(&w, &P0)); + + // region 0 + ccdVec3Set(&P, -0.5, 0.5, 0.5); + dist = ccdVec3PointTriDist2(&P, &a, &b, &c, &w); + assertTrue(ccdEq(dist, 0.)); + assertTrue(ccdVec3Eq(&w, &P)); + ccdVec3Set(&P, -0.5, 0.5, 0.7); + dist = ccdVec3PointTriDist2(&P, &a, &b, &c, &w); + assertTrue(ccdEq(dist, 0.)); + assertTrue(ccdVec3Eq(&w, &P)); + ccdVec3Set(&P, -0.5, 0.5, 0.9); + dist = ccdVec3PointTriDist2(&P, &a, &b, &c, &w); + assertTrue(ccdEq(dist, 0.)); + assertTrue(ccdVec3Eq(&w, &P)); + + ccdVec3Set(&P, 0., 0., 0.5); + dist = ccdVec3PointTriDist2(&P, &a, &b, &c, &w); + assertTrue(ccdEq(dist, 0.5)); + ccdVec3Set(&P0, -.5, .5, .5); + assertTrue(ccdVec3Eq(&w, &P0)); + + ccdVec3Set(&a, -1., 0., 0.); + ccdVec3Set(&b, 0., 1., -1.); + ccdVec3Set(&c, 0., 1., 1.); + ccdVec3Set(&P, 0., 0., 0.); + dist = ccdVec3PointTriDist2(&P, &a, &b, &c, &w); + assertTrue(ccdEq(dist, 0.5)); + ccdVec3Set(&P0, -.5, .5, 0.); + assertTrue(ccdVec3Eq(&w, &P0)); + //fprintf(stderr, "dist: %lf\n", dist); +} diff --git a/libs/ode-0.16.1/libccd/src/testsuites/vec3.h b/libs/ode-0.16.1/libccd/src/testsuites/vec3.h new file mode 100644 index 0000000..2055947 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/testsuites/vec3.h @@ -0,0 +1,20 @@ +#ifndef TEST_VEC3_H +#define TEST_VEC3_H + +#include + +TEST(vec3SetUp); +TEST(vec3TearDown); +TEST(vec3PointSegmentDist); +TEST(vec3PointTriDist); + +TEST_SUITE(TSVec3) { + TEST_ADD(vec3SetUp), + + TEST_ADD(vec3PointSegmentDist), + TEST_ADD(vec3PointTriDist), + + TEST_ADD(vec3TearDown), + TEST_SUITE_CLOSURE +}; +#endif diff --git a/libs/ode-0.16.1/libccd/src/vec3.c b/libs/ode-0.16.1/libccd/src/vec3.c new file mode 100644 index 0000000..f1a0804 --- /dev/null +++ b/libs/ode-0.16.1/libccd/src/vec3.c @@ -0,0 +1,215 @@ +/*** + * libccd + * --------------------------------- + * Copyright (c)2010 Daniel Fiser + * + * + * This file is part of libccd. + * + * Distributed under the OSI-approved BSD License (the "License"); + * see accompanying file BDS-LICENSE for details or see + * . + * + * This software is distributed WITHOUT ANY WARRANTY; without even the + * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * See the License for more information. + */ + +#include +#include +#include + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +static CCD_VEC3(__ccd_vec3_origin, CCD_ZERO, CCD_ZERO, CCD_ZERO); +ccd_vec3_t *ccd_vec3_origin = &__ccd_vec3_origin; + +static ccd_vec3_t points_on_sphere[] = { + CCD_VEC3_STATIC(CCD_REAL( 0.000000), CCD_REAL(-0.000000), CCD_REAL(-1.000000)), + CCD_VEC3_STATIC(CCD_REAL( 0.723608), CCD_REAL(-0.525725), CCD_REAL(-0.447219)), + CCD_VEC3_STATIC(CCD_REAL(-0.276388), CCD_REAL(-0.850649), CCD_REAL(-0.447219)), + CCD_VEC3_STATIC(CCD_REAL(-0.894426), CCD_REAL(-0.000000), CCD_REAL(-0.447216)), + CCD_VEC3_STATIC(CCD_REAL(-0.276388), CCD_REAL( 0.850649), CCD_REAL(-0.447220)), + CCD_VEC3_STATIC(CCD_REAL( 0.723608), CCD_REAL( 0.525725), CCD_REAL(-0.447219)), + CCD_VEC3_STATIC(CCD_REAL( 0.276388), CCD_REAL(-0.850649), CCD_REAL( 0.447220)), + CCD_VEC3_STATIC(CCD_REAL(-0.723608), CCD_REAL(-0.525725), CCD_REAL( 0.447219)), + CCD_VEC3_STATIC(CCD_REAL(-0.723608), CCD_REAL( 0.525725), CCD_REAL( 0.447219)), + CCD_VEC3_STATIC(CCD_REAL( 0.276388), CCD_REAL( 0.850649), CCD_REAL( 0.447219)), + CCD_VEC3_STATIC(CCD_REAL( 0.894426), CCD_REAL( 0.000000), CCD_REAL( 0.447216)), + CCD_VEC3_STATIC(CCD_REAL(-0.000000), CCD_REAL( 0.000000), CCD_REAL( 1.000000)), + CCD_VEC3_STATIC(CCD_REAL( 0.425323), CCD_REAL(-0.309011), CCD_REAL(-0.850654)), + CCD_VEC3_STATIC(CCD_REAL(-0.162456), CCD_REAL(-0.499995), CCD_REAL(-0.850654)), + CCD_VEC3_STATIC(CCD_REAL( 0.262869), CCD_REAL(-0.809012), CCD_REAL(-0.525738)), + CCD_VEC3_STATIC(CCD_REAL( 0.425323), CCD_REAL( 0.309011), CCD_REAL(-0.850654)), + CCD_VEC3_STATIC(CCD_REAL( 0.850648), CCD_REAL(-0.000000), CCD_REAL(-0.525736)), + CCD_VEC3_STATIC(CCD_REAL(-0.525730), CCD_REAL(-0.000000), CCD_REAL(-0.850652)), + CCD_VEC3_STATIC(CCD_REAL(-0.688190), CCD_REAL(-0.499997), CCD_REAL(-0.525736)), + CCD_VEC3_STATIC(CCD_REAL(-0.162456), CCD_REAL( 0.499995), CCD_REAL(-0.850654)), + CCD_VEC3_STATIC(CCD_REAL(-0.688190), CCD_REAL( 0.499997), CCD_REAL(-0.525736)), + CCD_VEC3_STATIC(CCD_REAL( 0.262869), CCD_REAL( 0.809012), CCD_REAL(-0.525738)), + CCD_VEC3_STATIC(CCD_REAL( 0.951058), CCD_REAL( 0.309013), CCD_REAL( 0.000000)), + CCD_VEC3_STATIC(CCD_REAL( 0.951058), CCD_REAL(-0.309013), CCD_REAL( 0.000000)), + CCD_VEC3_STATIC(CCD_REAL( 0.587786), CCD_REAL(-0.809017), CCD_REAL( 0.000000)), + CCD_VEC3_STATIC(CCD_REAL( 0.000000), CCD_REAL(-1.000000), CCD_REAL( 0.000000)), + CCD_VEC3_STATIC(CCD_REAL(-0.587786), CCD_REAL(-0.809017), CCD_REAL( 0.000000)), + CCD_VEC3_STATIC(CCD_REAL(-0.951058), CCD_REAL(-0.309013), CCD_REAL(-0.000000)), + CCD_VEC3_STATIC(CCD_REAL(-0.951058), CCD_REAL( 0.309013), CCD_REAL(-0.000000)), + CCD_VEC3_STATIC(CCD_REAL(-0.587786), CCD_REAL( 0.809017), CCD_REAL(-0.000000)), + CCD_VEC3_STATIC(CCD_REAL(-0.000000), CCD_REAL( 1.000000), CCD_REAL(-0.000000)), + CCD_VEC3_STATIC(CCD_REAL( 0.587786), CCD_REAL( 0.809017), CCD_REAL(-0.000000)), + CCD_VEC3_STATIC(CCD_REAL( 0.688190), CCD_REAL(-0.499997), CCD_REAL( 0.525736)), + CCD_VEC3_STATIC(CCD_REAL(-0.262869), CCD_REAL(-0.809012), CCD_REAL( 0.525738)), + CCD_VEC3_STATIC(CCD_REAL(-0.850648), CCD_REAL( 0.000000), CCD_REAL( 0.525736)), + CCD_VEC3_STATIC(CCD_REAL(-0.262869), CCD_REAL( 0.809012), CCD_REAL( 0.525738)), + CCD_VEC3_STATIC(CCD_REAL( 0.688190), CCD_REAL( 0.499997), CCD_REAL( 0.525736)), + CCD_VEC3_STATIC(CCD_REAL( 0.525730), CCD_REAL( 0.000000), CCD_REAL( 0.850652)), + CCD_VEC3_STATIC(CCD_REAL( 0.162456), CCD_REAL(-0.499995), CCD_REAL( 0.850654)), + CCD_VEC3_STATIC(CCD_REAL(-0.425323), CCD_REAL(-0.309011), CCD_REAL( 0.850654)), + CCD_VEC3_STATIC(CCD_REAL(-0.425323), CCD_REAL( 0.309011), CCD_REAL( 0.850654)), + CCD_VEC3_STATIC(CCD_REAL( 0.162456), CCD_REAL( 0.499995), CCD_REAL( 0.850654)) +}; +ccd_vec3_t *ccd_points_on_sphere = points_on_sphere; +size_t ccd_points_on_sphere_len = sizeof(points_on_sphere) / sizeof(ccd_vec3_t); + + +_ccd_inline ccd_real_t __ccdVec3PointSegmentDist2(const ccd_vec3_t *P, + const ccd_vec3_t *x0, + const ccd_vec3_t *b, + ccd_vec3_t *witness) +{ + // The computation comes from solving equation of segment: + // S(t) = x0 + t.d + // where - x0 is initial point of segment + // - d is direction of segment from x0 (|d| > 0) + // - t belongs to <0, 1> interval + // + // Than, distance from a segment to some point P can be expressed: + // D(t) = |x0 + t.d - P|^2 + // which is distance from any point on segment. Minimization + // of this function brings distance from P to segment. + // Minimization of D(t) leads to simple quadratic equation that's + // solving is straightforward. + // + // Bonus of this method is witness point for free. + + ccd_real_t dist, t; + ccd_vec3_t d, a; + + // direction of segment + ccdVec3Sub2(&d, b, x0); + + // precompute vector from P to x0 + ccdVec3Sub2(&a, x0, P); + + t = -CCD_REAL(1.) * ccdVec3Dot(&a, &d); + t /= ccdVec3Len2(&d); + + if (t < CCD_ZERO || ccdIsZero(t)){ + dist = ccdVec3Dist2(x0, P); + if (witness) + ccdVec3Copy(witness, x0); + }else if (t > CCD_ONE || ccdEq(t, CCD_ONE)){ + dist = ccdVec3Dist2(b, P); + if (witness) + ccdVec3Copy(witness, b); + }else{ + if (witness){ + ccdVec3Copy(witness, &d); + ccdVec3Scale(witness, t); + ccdVec3Add(witness, x0); + dist = ccdVec3Dist2(witness, P); + }else{ + // recycling variables + ccdVec3Scale(&d, t); + ccdVec3Add(&d, &a); + dist = ccdVec3Len2(&d); + } + } + + return dist; +} + +ccd_real_t ccdVec3PointSegmentDist2(const ccd_vec3_t *P, + const ccd_vec3_t *x0, const ccd_vec3_t *b, + ccd_vec3_t *witness) +{ + return __ccdVec3PointSegmentDist2(P, x0, b, witness); +} + +ccd_real_t ccdVec3PointTriDist2(const ccd_vec3_t *P, + const ccd_vec3_t *x0, const ccd_vec3_t *B, + const ccd_vec3_t *C, + ccd_vec3_t *witness) +{ + // Computation comes from analytic expression for triangle (x0, B, C) + // T(s, t) = x0 + s.d1 + t.d2, where d1 = B - x0 and d2 = C - x0 and + // Then equation for distance is: + // D(s, t) = | T(s, t) - P |^2 + // This leads to minimization of quadratic function of two variables. + // The solution from is taken only if s is between 0 and 1, t is + // between 0 and 1 and t + s < 1, otherwise distance from segment is + // computed. + + ccd_vec3_t d1, d2, a; + ccd_real_t u, v, w, p, q, r; + ccd_real_t s, t, dist, dist2; + ccd_vec3_t witness2; + + ccdVec3Sub2(&d1, B, x0); + ccdVec3Sub2(&d2, C, x0); + ccdVec3Sub2(&a, x0, P); + + u = ccdVec3Dot(&a, &a); + v = ccdVec3Dot(&d1, &d1); + w = ccdVec3Dot(&d2, &d2); + p = ccdVec3Dot(&a, &d1); + q = ccdVec3Dot(&a, &d2); + r = ccdVec3Dot(&d1, &d2); + + s = (q * r - w * p) / (w * v - r * r); + t = (-s * r - q) / w; + + if ((ccdIsZero(s) || s > CCD_ZERO) + && (ccdEq(s, CCD_ONE) || s < CCD_ONE) + && (ccdIsZero(t) || t > CCD_ZERO) + && (ccdEq(t, CCD_ONE) || t < CCD_ONE) + && (ccdEq(t + s, CCD_ONE) || t + s < CCD_ONE)){ + + if (witness){ + ccdVec3Scale(&d1, s); + ccdVec3Scale(&d2, t); + ccdVec3Copy(witness, x0); + ccdVec3Add(witness, &d1); + ccdVec3Add(witness, &d2); + + dist = ccdVec3Dist2(witness, P); + }else{ + dist = s * s * v; + dist += t * t * w; + dist += CCD_REAL(2.) * s * t * r; + dist += CCD_REAL(2.) * s * p; + dist += CCD_REAL(2.) * t * q; + dist += u; + } + }else{ + dist = __ccdVec3PointSegmentDist2(P, x0, B, witness); + + dist2 = __ccdVec3PointSegmentDist2(P, x0, C, &witness2); + if (dist2 < dist){ + dist = dist2; + if (witness) + ccdVec3Copy(witness, &witness2); + } + + dist2 = __ccdVec3PointSegmentDist2(P, B, C, &witness2); + if (dist2 < dist){ + dist = dist2; + if (witness) + ccdVec3Copy(witness, &witness2); + } + } + + return dist; +} diff --git a/libs/ode-0.16.1/ltmain.sh b/libs/ode-0.16.1/ltmain.sh new file mode 100644 index 0000000..147d758 --- /dev/null +++ b/libs/ode-0.16.1/ltmain.sh @@ -0,0 +1,11156 @@ +#! /bin/sh +## DO NOT EDIT - This file generated from ./build-aux/ltmain.in +## by inline-source v2014-01-03.01 + +# libtool (GNU libtool) 2.4.6 +# Provide generalized library-building support services. +# Written by Gordon Matzigkeit , 1996 + +# Copyright (C) 1996-2015 Free Software Foundation, Inc. +# This is free software; see the source for copying conditions. There is NO +# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + +# GNU Libtool is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# As a special exception to the GNU General Public License, +# if you distribute this file as part of a program or library that +# is built using GNU Libtool, you may include this file under the +# same distribution terms that you use for the rest of that program. +# +# GNU Libtool is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + + +PROGRAM=libtool +PACKAGE=libtool +VERSION="2.4.6 Debian-2.4.6-0.1" +package_revision=2.4.6 + + +## ------ ## +## Usage. ## +## ------ ## + +# Run './libtool --help' for help with using this script from the +# command line. + + +## ------------------------------- ## +## User overridable command paths. ## +## ------------------------------- ## + +# After configure completes, it has a better idea of some of the +# shell tools we need than the defaults used by the functions shared +# with bootstrap, so set those here where they can still be over- +# ridden by the user, but otherwise take precedence. + +: ${AUTOCONF="autoconf"} +: ${AUTOMAKE="automake"} + + +## -------------------------- ## +## Source external libraries. ## +## -------------------------- ## + +# Much of our low-level functionality needs to be sourced from external +# libraries, which are installed to $pkgauxdir. + +# Set a version string for this script. +scriptversion=2015-01-20.17; # UTC + +# General shell script boiler plate, and helper functions. +# Written by Gary V. Vaughan, 2004 + +# Copyright (C) 2004-2015 Free Software Foundation, Inc. +# This is free software; see the source for copying conditions. There is NO +# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 3 of the License, or +# (at your option) any later version. + +# As a special exception to the GNU General Public License, if you distribute +# this file as part of a program or library that is built using GNU Libtool, +# you may include this file under the same distribution terms that you use +# for the rest of that program. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNES FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. + +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + +# Please report bugs or propose patches to gary@gnu.org. + + +## ------ ## +## Usage. ## +## ------ ## + +# Evaluate this file near the top of your script to gain access to +# the functions and variables defined here: +# +# . `echo "$0" | ${SED-sed} 's|[^/]*$||'`/build-aux/funclib.sh +# +# If you need to override any of the default environment variable +# settings, do that before evaluating this file. + + +## -------------------- ## +## Shell normalisation. ## +## -------------------- ## + +# Some shells need a little help to be as Bourne compatible as possible. +# Before doing anything else, make sure all that help has been provided! + +DUALCASE=1; export DUALCASE # for MKS sh +if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : + emulate sh + NULLCMD=: + # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which + # is contrary to our usage. Disable this feature. + alias -g '${1+"$@"}'='"$@"' + setopt NO_GLOB_SUBST +else + case `(set -o) 2>/dev/null` in *posix*) set -o posix ;; esac +fi + +# NLS nuisances: We save the old values in case they are required later. +_G_user_locale= +_G_safe_locale= +for _G_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES +do + eval "if test set = \"\${$_G_var+set}\"; then + save_$_G_var=\$$_G_var + $_G_var=C + export $_G_var + _G_user_locale=\"$_G_var=\\\$save_\$_G_var; \$_G_user_locale\" + _G_safe_locale=\"$_G_var=C; \$_G_safe_locale\" + fi" +done + +# CDPATH. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + +# Make sure IFS has a sensible default +sp=' ' +nl=' +' +IFS="$sp $nl" + +# There are apparently some retarded systems that use ';' as a PATH separator! +if test "${PATH_SEPARATOR+set}" != set; then + PATH_SEPARATOR=: + (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { + (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || + PATH_SEPARATOR=';' + } +fi + + + +## ------------------------- ## +## Locate command utilities. ## +## ------------------------- ## + + +# func_executable_p FILE +# ---------------------- +# Check that FILE is an executable regular file. +func_executable_p () +{ + test -f "$1" && test -x "$1" +} + + +# func_path_progs PROGS_LIST CHECK_FUNC [PATH] +# -------------------------------------------- +# Search for either a program that responds to --version with output +# containing "GNU", or else returned by CHECK_FUNC otherwise, by +# trying all the directories in PATH with each of the elements of +# PROGS_LIST. +# +# CHECK_FUNC should accept the path to a candidate program, and +# set $func_check_prog_result if it truncates its output less than +# $_G_path_prog_max characters. +func_path_progs () +{ + _G_progs_list=$1 + _G_check_func=$2 + _G_PATH=${3-"$PATH"} + + _G_path_prog_max=0 + _G_path_prog_found=false + _G_save_IFS=$IFS; IFS=${PATH_SEPARATOR-:} + for _G_dir in $_G_PATH; do + IFS=$_G_save_IFS + test -z "$_G_dir" && _G_dir=. + for _G_prog_name in $_G_progs_list; do + for _exeext in '' .EXE; do + _G_path_prog=$_G_dir/$_G_prog_name$_exeext + func_executable_p "$_G_path_prog" || continue + case `"$_G_path_prog" --version 2>&1` in + *GNU*) func_path_progs_result=$_G_path_prog _G_path_prog_found=: ;; + *) $_G_check_func $_G_path_prog + func_path_progs_result=$func_check_prog_result + ;; + esac + $_G_path_prog_found && break 3 + done + done + done + IFS=$_G_save_IFS + test -z "$func_path_progs_result" && { + echo "no acceptable sed could be found in \$PATH" >&2 + exit 1 + } +} + + +# We want to be able to use the functions in this file before configure +# has figured out where the best binaries are kept, which means we have +# to search for them ourselves - except when the results are already set +# where we skip the searches. + +# Unless the user overrides by setting SED, search the path for either GNU +# sed, or the sed that truncates its output the least. +test -z "$SED" && { + _G_sed_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ + for _G_i in 1 2 3 4 5 6 7; do + _G_sed_script=$_G_sed_script$nl$_G_sed_script + done + echo "$_G_sed_script" 2>/dev/null | sed 99q >conftest.sed + _G_sed_script= + + func_check_prog_sed () + { + _G_path_prog=$1 + + _G_count=0 + printf 0123456789 >conftest.in + while : + do + cat conftest.in conftest.in >conftest.tmp + mv conftest.tmp conftest.in + cp conftest.in conftest.nl + echo '' >> conftest.nl + "$_G_path_prog" -f conftest.sed conftest.out 2>/dev/null || break + diff conftest.out conftest.nl >/dev/null 2>&1 || break + _G_count=`expr $_G_count + 1` + if test "$_G_count" -gt "$_G_path_prog_max"; then + # Best one so far, save it but keep looking for a better one + func_check_prog_result=$_G_path_prog + _G_path_prog_max=$_G_count + fi + # 10*(2^10) chars as input seems more than enough + test 10 -lt "$_G_count" && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out + } + + func_path_progs "sed gsed" func_check_prog_sed $PATH:/usr/xpg4/bin + rm -f conftest.sed + SED=$func_path_progs_result +} + + +# Unless the user overrides by setting GREP, search the path for either GNU +# grep, or the grep that truncates its output the least. +test -z "$GREP" && { + func_check_prog_grep () + { + _G_path_prog=$1 + + _G_count=0 + _G_path_prog_max=0 + printf 0123456789 >conftest.in + while : + do + cat conftest.in conftest.in >conftest.tmp + mv conftest.tmp conftest.in + cp conftest.in conftest.nl + echo 'GREP' >> conftest.nl + "$_G_path_prog" -e 'GREP$' -e '-(cannot match)-' conftest.out 2>/dev/null || break + diff conftest.out conftest.nl >/dev/null 2>&1 || break + _G_count=`expr $_G_count + 1` + if test "$_G_count" -gt "$_G_path_prog_max"; then + # Best one so far, save it but keep looking for a better one + func_check_prog_result=$_G_path_prog + _G_path_prog_max=$_G_count + fi + # 10*(2^10) chars as input seems more than enough + test 10 -lt "$_G_count" && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out + } + + func_path_progs "grep ggrep" func_check_prog_grep $PATH:/usr/xpg4/bin + GREP=$func_path_progs_result +} + + +## ------------------------------- ## +## User overridable command paths. ## +## ------------------------------- ## + +# All uppercase variable names are used for environment variables. These +# variables can be overridden by the user before calling a script that +# uses them if a suitable command of that name is not already available +# in the command search PATH. + +: ${CP="cp -f"} +: ${ECHO="printf %s\n"} +: ${EGREP="$GREP -E"} +: ${FGREP="$GREP -F"} +: ${LN_S="ln -s"} +: ${MAKE="make"} +: ${MKDIR="mkdir"} +: ${MV="mv -f"} +: ${RM="rm -f"} +: ${SHELL="${CONFIG_SHELL-/bin/sh}"} + + +## -------------------- ## +## Useful sed snippets. ## +## -------------------- ## + +sed_dirname='s|/[^/]*$||' +sed_basename='s|^.*/||' + +# Sed substitution that helps us do robust quoting. It backslashifies +# metacharacters that are still active within double-quoted strings. +sed_quote_subst='s|\([`"$\\]\)|\\\1|g' + +# Same as above, but do not quote variable references. +sed_double_quote_subst='s/\(["`\\]\)/\\\1/g' + +# Sed substitution that turns a string into a regex matching for the +# string literally. +sed_make_literal_regex='s|[].[^$\\*\/]|\\&|g' + +# Sed substitution that converts a w32 file name or path +# that contains forward slashes, into one that contains +# (escaped) backslashes. A very naive implementation. +sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g' + +# Re-'\' parameter expansions in output of sed_double_quote_subst that +# were '\'-ed in input to the same. If an odd number of '\' preceded a +# '$' in input to sed_double_quote_subst, that '$' was protected from +# expansion. Since each input '\' is now two '\'s, look for any number +# of runs of four '\'s followed by two '\'s and then a '$'. '\' that '$'. +_G_bs='\\' +_G_bs2='\\\\' +_G_bs4='\\\\\\\\' +_G_dollar='\$' +sed_double_backslash="\ + s/$_G_bs4/&\\ +/g + s/^$_G_bs2$_G_dollar/$_G_bs&/ + s/\\([^$_G_bs]\\)$_G_bs2$_G_dollar/\\1$_G_bs2$_G_bs$_G_dollar/g + s/\n//g" + + +## ----------------- ## +## Global variables. ## +## ----------------- ## + +# Except for the global variables explicitly listed below, the following +# functions in the '^func_' namespace, and the '^require_' namespace +# variables initialised in the 'Resource management' section, sourcing +# this file will not pollute your global namespace with anything +# else. There's no portable way to scope variables in Bourne shell +# though, so actually running these functions will sometimes place +# results into a variable named after the function, and often use +# temporary variables in the '^_G_' namespace. If you are careful to +# avoid using those namespaces casually in your sourcing script, things +# should continue to work as you expect. And, of course, you can freely +# overwrite any of the functions or variables defined here before +# calling anything to customize them. + +EXIT_SUCCESS=0 +EXIT_FAILURE=1 +EXIT_MISMATCH=63 # $? = 63 is used to indicate version mismatch to missing. +EXIT_SKIP=77 # $? = 77 is used to indicate a skipped test to automake. + +# Allow overriding, eg assuming that you follow the convention of +# putting '$debug_cmd' at the start of all your functions, you can get +# bash to show function call trace with: +# +# debug_cmd='eval echo "${FUNCNAME[0]} $*" >&2' bash your-script-name +debug_cmd=${debug_cmd-":"} +exit_cmd=: + +# By convention, finish your script with: +# +# exit $exit_status +# +# so that you can set exit_status to non-zero if you want to indicate +# something went wrong during execution without actually bailing out at +# the point of failure. +exit_status=$EXIT_SUCCESS + +# Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh +# is ksh but when the shell is invoked as "sh" and the current value of +# the _XPG environment variable is not equal to 1 (one), the special +# positional parameter $0, within a function call, is the name of the +# function. +progpath=$0 + +# The name of this program. +progname=`$ECHO "$progpath" |$SED "$sed_basename"` + +# Make sure we have an absolute progpath for reexecution: +case $progpath in + [\\/]*|[A-Za-z]:\\*) ;; + *[\\/]*) + progdir=`$ECHO "$progpath" |$SED "$sed_dirname"` + progdir=`cd "$progdir" && pwd` + progpath=$progdir/$progname + ;; + *) + _G_IFS=$IFS + IFS=${PATH_SEPARATOR-:} + for progdir in $PATH; do + IFS=$_G_IFS + test -x "$progdir/$progname" && break + done + IFS=$_G_IFS + test -n "$progdir" || progdir=`pwd` + progpath=$progdir/$progname + ;; +esac + + +## ----------------- ## +## Standard options. ## +## ----------------- ## + +# The following options affect the operation of the functions defined +# below, and should be set appropriately depending on run-time para- +# meters passed on the command line. + +opt_dry_run=false +opt_quiet=false +opt_verbose=false + +# Categories 'all' and 'none' are always available. Append any others +# you will pass as the first argument to func_warning from your own +# code. +warning_categories= + +# By default, display warnings according to 'opt_warning_types'. Set +# 'warning_func' to ':' to elide all warnings, or func_fatal_error to +# treat the next displayed warning as a fatal error. +warning_func=func_warn_and_continue + +# Set to 'all' to display all warnings, 'none' to suppress all +# warnings, or a space delimited list of some subset of +# 'warning_categories' to display only the listed warnings. +opt_warning_types=all + + +## -------------------- ## +## Resource management. ## +## -------------------- ## + +# This section contains definitions for functions that each ensure a +# particular resource (a file, or a non-empty configuration variable for +# example) is available, and if appropriate to extract default values +# from pertinent package files. Call them using their associated +# 'require_*' variable to ensure that they are executed, at most, once. +# +# It's entirely deliberate that calling these functions can set +# variables that don't obey the namespace limitations obeyed by the rest +# of this file, in order that that they be as useful as possible to +# callers. + + +# require_term_colors +# ------------------- +# Allow display of bold text on terminals that support it. +require_term_colors=func_require_term_colors +func_require_term_colors () +{ + $debug_cmd + + test -t 1 && { + # COLORTERM and USE_ANSI_COLORS environment variables take + # precedence, because most terminfo databases neglect to describe + # whether color sequences are supported. + test -n "${COLORTERM+set}" && : ${USE_ANSI_COLORS="1"} + + if test 1 = "$USE_ANSI_COLORS"; then + # Standard ANSI escape sequences + tc_reset='' + tc_bold=''; tc_standout='' + tc_red=''; tc_green='' + tc_blue=''; tc_cyan='' + else + # Otherwise trust the terminfo database after all. + test -n "`tput sgr0 2>/dev/null`" && { + tc_reset=`tput sgr0` + test -n "`tput bold 2>/dev/null`" && tc_bold=`tput bold` + tc_standout=$tc_bold + test -n "`tput smso 2>/dev/null`" && tc_standout=`tput smso` + test -n "`tput setaf 1 2>/dev/null`" && tc_red=`tput setaf 1` + test -n "`tput setaf 2 2>/dev/null`" && tc_green=`tput setaf 2` + test -n "`tput setaf 4 2>/dev/null`" && tc_blue=`tput setaf 4` + test -n "`tput setaf 5 2>/dev/null`" && tc_cyan=`tput setaf 5` + } + fi + } + + require_term_colors=: +} + + +## ----------------- ## +## Function library. ## +## ----------------- ## + +# This section contains a variety of useful functions to call in your +# scripts. Take note of the portable wrappers for features provided by +# some modern shells, which will fall back to slower equivalents on +# less featureful shells. + + +# func_append VAR VALUE +# --------------------- +# Append VALUE onto the existing contents of VAR. + + # We should try to minimise forks, especially on Windows where they are + # unreasonably slow, so skip the feature probes when bash or zsh are + # being used: + if test set = "${BASH_VERSION+set}${ZSH_VERSION+set}"; then + : ${_G_HAVE_ARITH_OP="yes"} + : ${_G_HAVE_XSI_OPS="yes"} + # The += operator was introduced in bash 3.1 + case $BASH_VERSION in + [12].* | 3.0 | 3.0*) ;; + *) + : ${_G_HAVE_PLUSEQ_OP="yes"} + ;; + esac + fi + + # _G_HAVE_PLUSEQ_OP + # Can be empty, in which case the shell is probed, "yes" if += is + # useable or anything else if it does not work. + test -z "$_G_HAVE_PLUSEQ_OP" \ + && (eval 'x=a; x+=" b"; test "a b" = "$x"') 2>/dev/null \ + && _G_HAVE_PLUSEQ_OP=yes + +if test yes = "$_G_HAVE_PLUSEQ_OP" +then + # This is an XSI compatible shell, allowing a faster implementation... + eval 'func_append () + { + $debug_cmd + + eval "$1+=\$2" + }' +else + # ...otherwise fall back to using expr, which is often a shell builtin. + func_append () + { + $debug_cmd + + eval "$1=\$$1\$2" + } +fi + + +# func_append_quoted VAR VALUE +# ---------------------------- +# Quote VALUE and append to the end of shell variable VAR, separated +# by a space. +if test yes = "$_G_HAVE_PLUSEQ_OP"; then + eval 'func_append_quoted () + { + $debug_cmd + + func_quote_for_eval "$2" + eval "$1+=\\ \$func_quote_for_eval_result" + }' +else + func_append_quoted () + { + $debug_cmd + + func_quote_for_eval "$2" + eval "$1=\$$1\\ \$func_quote_for_eval_result" + } +fi + + +# func_append_uniq VAR VALUE +# -------------------------- +# Append unique VALUE onto the existing contents of VAR, assuming +# entries are delimited by the first character of VALUE. For example: +# +# func_append_uniq options " --another-option option-argument" +# +# will only append to $options if " --another-option option-argument " +# is not already present somewhere in $options already (note spaces at +# each end implied by leading space in second argument). +func_append_uniq () +{ + $debug_cmd + + eval _G_current_value='`$ECHO $'$1'`' + _G_delim=`expr "$2" : '\(.\)'` + + case $_G_delim$_G_current_value$_G_delim in + *"$2$_G_delim"*) ;; + *) func_append "$@" ;; + esac +} + + +# func_arith TERM... +# ------------------ +# Set func_arith_result to the result of evaluating TERMs. + test -z "$_G_HAVE_ARITH_OP" \ + && (eval 'test 2 = $(( 1 + 1 ))') 2>/dev/null \ + && _G_HAVE_ARITH_OP=yes + +if test yes = "$_G_HAVE_ARITH_OP"; then + eval 'func_arith () + { + $debug_cmd + + func_arith_result=$(( $* )) + }' +else + func_arith () + { + $debug_cmd + + func_arith_result=`expr "$@"` + } +fi + + +# func_basename FILE +# ------------------ +# Set func_basename_result to FILE with everything up to and including +# the last / stripped. +if test yes = "$_G_HAVE_XSI_OPS"; then + # If this shell supports suffix pattern removal, then use it to avoid + # forking. Hide the definitions single quotes in case the shell chokes + # on unsupported syntax... + _b='func_basename_result=${1##*/}' + _d='case $1 in + */*) func_dirname_result=${1%/*}$2 ;; + * ) func_dirname_result=$3 ;; + esac' + +else + # ...otherwise fall back to using sed. + _b='func_basename_result=`$ECHO "$1" |$SED "$sed_basename"`' + _d='func_dirname_result=`$ECHO "$1" |$SED "$sed_dirname"` + if test "X$func_dirname_result" = "X$1"; then + func_dirname_result=$3 + else + func_append func_dirname_result "$2" + fi' +fi + +eval 'func_basename () +{ + $debug_cmd + + '"$_b"' +}' + + +# func_dirname FILE APPEND NONDIR_REPLACEMENT +# ------------------------------------------- +# Compute the dirname of FILE. If nonempty, add APPEND to the result, +# otherwise set result to NONDIR_REPLACEMENT. +eval 'func_dirname () +{ + $debug_cmd + + '"$_d"' +}' + + +# func_dirname_and_basename FILE APPEND NONDIR_REPLACEMENT +# -------------------------------------------------------- +# Perform func_basename and func_dirname in a single function +# call: +# dirname: Compute the dirname of FILE. If nonempty, +# add APPEND to the result, otherwise set result +# to NONDIR_REPLACEMENT. +# value returned in "$func_dirname_result" +# basename: Compute filename of FILE. +# value retuned in "$func_basename_result" +# For efficiency, we do not delegate to the functions above but instead +# duplicate the functionality here. +eval 'func_dirname_and_basename () +{ + $debug_cmd + + '"$_b"' + '"$_d"' +}' + + +# func_echo ARG... +# ---------------- +# Echo program name prefixed message. +func_echo () +{ + $debug_cmd + + _G_message=$* + + func_echo_IFS=$IFS + IFS=$nl + for _G_line in $_G_message; do + IFS=$func_echo_IFS + $ECHO "$progname: $_G_line" + done + IFS=$func_echo_IFS +} + + +# func_echo_all ARG... +# -------------------- +# Invoke $ECHO with all args, space-separated. +func_echo_all () +{ + $ECHO "$*" +} + + +# func_echo_infix_1 INFIX ARG... +# ------------------------------ +# Echo program name, followed by INFIX on the first line, with any +# additional lines not showing INFIX. +func_echo_infix_1 () +{ + $debug_cmd + + $require_term_colors + + _G_infix=$1; shift + _G_indent=$_G_infix + _G_prefix="$progname: $_G_infix: " + _G_message=$* + + # Strip color escape sequences before counting printable length + for _G_tc in "$tc_reset" "$tc_bold" "$tc_standout" "$tc_red" "$tc_green" "$tc_blue" "$tc_cyan" + do + test -n "$_G_tc" && { + _G_esc_tc=`$ECHO "$_G_tc" | $SED "$sed_make_literal_regex"` + _G_indent=`$ECHO "$_G_indent" | $SED "s|$_G_esc_tc||g"` + } + done + _G_indent="$progname: "`echo "$_G_indent" | $SED 's|.| |g'`" " ## exclude from sc_prohibit_nested_quotes + + func_echo_infix_1_IFS=$IFS + IFS=$nl + for _G_line in $_G_message; do + IFS=$func_echo_infix_1_IFS + $ECHO "$_G_prefix$tc_bold$_G_line$tc_reset" >&2 + _G_prefix=$_G_indent + done + IFS=$func_echo_infix_1_IFS +} + + +# func_error ARG... +# ----------------- +# Echo program name prefixed message to standard error. +func_error () +{ + $debug_cmd + + $require_term_colors + + func_echo_infix_1 " $tc_standout${tc_red}error$tc_reset" "$*" >&2 +} + + +# func_fatal_error ARG... +# ----------------------- +# Echo program name prefixed message to standard error, and exit. +func_fatal_error () +{ + $debug_cmd + + func_error "$*" + exit $EXIT_FAILURE +} + + +# func_grep EXPRESSION FILENAME +# ----------------------------- +# Check whether EXPRESSION matches any line of FILENAME, without output. +func_grep () +{ + $debug_cmd + + $GREP "$1" "$2" >/dev/null 2>&1 +} + + +# func_len STRING +# --------------- +# Set func_len_result to the length of STRING. STRING may not +# start with a hyphen. + test -z "$_G_HAVE_XSI_OPS" \ + && (eval 'x=a/b/c; + test 5aa/bb/cc = "${#x}${x%%/*}${x%/*}${x#*/}${x##*/}"') 2>/dev/null \ + && _G_HAVE_XSI_OPS=yes + +if test yes = "$_G_HAVE_XSI_OPS"; then + eval 'func_len () + { + $debug_cmd + + func_len_result=${#1} + }' +else + func_len () + { + $debug_cmd + + func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len` + } +fi + + +# func_mkdir_p DIRECTORY-PATH +# --------------------------- +# Make sure the entire path to DIRECTORY-PATH is available. +func_mkdir_p () +{ + $debug_cmd + + _G_directory_path=$1 + _G_dir_list= + + if test -n "$_G_directory_path" && test : != "$opt_dry_run"; then + + # Protect directory names starting with '-' + case $_G_directory_path in + -*) _G_directory_path=./$_G_directory_path ;; + esac + + # While some portion of DIR does not yet exist... + while test ! -d "$_G_directory_path"; do + # ...make a list in topmost first order. Use a colon delimited + # list incase some portion of path contains whitespace. + _G_dir_list=$_G_directory_path:$_G_dir_list + + # If the last portion added has no slash in it, the list is done + case $_G_directory_path in */*) ;; *) break ;; esac + + # ...otherwise throw away the child directory and loop + _G_directory_path=`$ECHO "$_G_directory_path" | $SED -e "$sed_dirname"` + done + _G_dir_list=`$ECHO "$_G_dir_list" | $SED 's|:*$||'` + + func_mkdir_p_IFS=$IFS; IFS=: + for _G_dir in $_G_dir_list; do + IFS=$func_mkdir_p_IFS + # mkdir can fail with a 'File exist' error if two processes + # try to create one of the directories concurrently. Don't + # stop in that case! + $MKDIR "$_G_dir" 2>/dev/null || : + done + IFS=$func_mkdir_p_IFS + + # Bail out if we (or some other process) failed to create a directory. + test -d "$_G_directory_path" || \ + func_fatal_error "Failed to create '$1'" + fi +} + + +# func_mktempdir [BASENAME] +# ------------------------- +# Make a temporary directory that won't clash with other running +# libtool processes, and avoids race conditions if possible. If +# given, BASENAME is the basename for that directory. +func_mktempdir () +{ + $debug_cmd + + _G_template=${TMPDIR-/tmp}/${1-$progname} + + if test : = "$opt_dry_run"; then + # Return a directory name, but don't create it in dry-run mode + _G_tmpdir=$_G_template-$$ + else + + # If mktemp works, use that first and foremost + _G_tmpdir=`mktemp -d "$_G_template-XXXXXXXX" 2>/dev/null` + + if test ! -d "$_G_tmpdir"; then + # Failing that, at least try and use $RANDOM to avoid a race + _G_tmpdir=$_G_template-${RANDOM-0}$$ + + func_mktempdir_umask=`umask` + umask 0077 + $MKDIR "$_G_tmpdir" + umask $func_mktempdir_umask + fi + + # If we're not in dry-run mode, bomb out on failure + test -d "$_G_tmpdir" || \ + func_fatal_error "cannot create temporary directory '$_G_tmpdir'" + fi + + $ECHO "$_G_tmpdir" +} + + +# func_normal_abspath PATH +# ------------------------ +# Remove doubled-up and trailing slashes, "." path components, +# and cancel out any ".." path components in PATH after making +# it an absolute path. +func_normal_abspath () +{ + $debug_cmd + + # These SED scripts presuppose an absolute path with a trailing slash. + _G_pathcar='s|^/\([^/]*\).*$|\1|' + _G_pathcdr='s|^/[^/]*||' + _G_removedotparts=':dotsl + s|/\./|/|g + t dotsl + s|/\.$|/|' + _G_collapseslashes='s|/\{1,\}|/|g' + _G_finalslash='s|/*$|/|' + + # Start from root dir and reassemble the path. + func_normal_abspath_result= + func_normal_abspath_tpath=$1 + func_normal_abspath_altnamespace= + case $func_normal_abspath_tpath in + "") + # Empty path, that just means $cwd. + func_stripname '' '/' "`pwd`" + func_normal_abspath_result=$func_stripname_result + return + ;; + # The next three entries are used to spot a run of precisely + # two leading slashes without using negated character classes; + # we take advantage of case's first-match behaviour. + ///*) + # Unusual form of absolute path, do nothing. + ;; + //*) + # Not necessarily an ordinary path; POSIX reserves leading '//' + # and for example Cygwin uses it to access remote file shares + # over CIFS/SMB, so we conserve a leading double slash if found. + func_normal_abspath_altnamespace=/ + ;; + /*) + # Absolute path, do nothing. + ;; + *) + # Relative path, prepend $cwd. + func_normal_abspath_tpath=`pwd`/$func_normal_abspath_tpath + ;; + esac + + # Cancel out all the simple stuff to save iterations. We also want + # the path to end with a slash for ease of parsing, so make sure + # there is one (and only one) here. + func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ + -e "$_G_removedotparts" -e "$_G_collapseslashes" -e "$_G_finalslash"` + while :; do + # Processed it all yet? + if test / = "$func_normal_abspath_tpath"; then + # If we ascended to the root using ".." the result may be empty now. + if test -z "$func_normal_abspath_result"; then + func_normal_abspath_result=/ + fi + break + fi + func_normal_abspath_tcomponent=`$ECHO "$func_normal_abspath_tpath" | $SED \ + -e "$_G_pathcar"` + func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ + -e "$_G_pathcdr"` + # Figure out what to do with it + case $func_normal_abspath_tcomponent in + "") + # Trailing empty path component, ignore it. + ;; + ..) + # Parent dir; strip last assembled component from result. + func_dirname "$func_normal_abspath_result" + func_normal_abspath_result=$func_dirname_result + ;; + *) + # Actual path component, append it. + func_append func_normal_abspath_result "/$func_normal_abspath_tcomponent" + ;; + esac + done + # Restore leading double-slash if one was found on entry. + func_normal_abspath_result=$func_normal_abspath_altnamespace$func_normal_abspath_result +} + + +# func_notquiet ARG... +# -------------------- +# Echo program name prefixed message only when not in quiet mode. +func_notquiet () +{ + $debug_cmd + + $opt_quiet || func_echo ${1+"$@"} + + # A bug in bash halts the script if the last line of a function + # fails when set -e is in force, so we need another command to + # work around that: + : +} + + +# func_relative_path SRCDIR DSTDIR +# -------------------------------- +# Set func_relative_path_result to the relative path from SRCDIR to DSTDIR. +func_relative_path () +{ + $debug_cmd + + func_relative_path_result= + func_normal_abspath "$1" + func_relative_path_tlibdir=$func_normal_abspath_result + func_normal_abspath "$2" + func_relative_path_tbindir=$func_normal_abspath_result + + # Ascend the tree starting from libdir + while :; do + # check if we have found a prefix of bindir + case $func_relative_path_tbindir in + $func_relative_path_tlibdir) + # found an exact match + func_relative_path_tcancelled= + break + ;; + $func_relative_path_tlibdir*) + # found a matching prefix + func_stripname "$func_relative_path_tlibdir" '' "$func_relative_path_tbindir" + func_relative_path_tcancelled=$func_stripname_result + if test -z "$func_relative_path_result"; then + func_relative_path_result=. + fi + break + ;; + *) + func_dirname $func_relative_path_tlibdir + func_relative_path_tlibdir=$func_dirname_result + if test -z "$func_relative_path_tlibdir"; then + # Have to descend all the way to the root! + func_relative_path_result=../$func_relative_path_result + func_relative_path_tcancelled=$func_relative_path_tbindir + break + fi + func_relative_path_result=../$func_relative_path_result + ;; + esac + done + + # Now calculate path; take care to avoid doubling-up slashes. + func_stripname '' '/' "$func_relative_path_result" + func_relative_path_result=$func_stripname_result + func_stripname '/' '/' "$func_relative_path_tcancelled" + if test -n "$func_stripname_result"; then + func_append func_relative_path_result "/$func_stripname_result" + fi + + # Normalisation. If bindir is libdir, return '.' else relative path. + if test -n "$func_relative_path_result"; then + func_stripname './' '' "$func_relative_path_result" + func_relative_path_result=$func_stripname_result + fi + + test -n "$func_relative_path_result" || func_relative_path_result=. + + : +} + + +# func_quote_for_eval ARG... +# -------------------------- +# Aesthetically quote ARGs to be evaled later. +# This function returns two values: +# i) func_quote_for_eval_result +# double-quoted, suitable for a subsequent eval +# ii) func_quote_for_eval_unquoted_result +# has all characters that are still active within double +# quotes backslashified. +func_quote_for_eval () +{ + $debug_cmd + + func_quote_for_eval_unquoted_result= + func_quote_for_eval_result= + while test 0 -lt $#; do + case $1 in + *[\\\`\"\$]*) + _G_unquoted_arg=`printf '%s\n' "$1" |$SED "$sed_quote_subst"` ;; + *) + _G_unquoted_arg=$1 ;; + esac + if test -n "$func_quote_for_eval_unquoted_result"; then + func_append func_quote_for_eval_unquoted_result " $_G_unquoted_arg" + else + func_append func_quote_for_eval_unquoted_result "$_G_unquoted_arg" + fi + + case $_G_unquoted_arg in + # Double-quote args containing shell metacharacters to delay + # word splitting, command substitution and variable expansion + # for a subsequent eval. + # Many Bourne shells cannot handle close brackets correctly + # in scan sets, so we specify it separately. + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + _G_quoted_arg=\"$_G_unquoted_arg\" + ;; + *) + _G_quoted_arg=$_G_unquoted_arg + ;; + esac + + if test -n "$func_quote_for_eval_result"; then + func_append func_quote_for_eval_result " $_G_quoted_arg" + else + func_append func_quote_for_eval_result "$_G_quoted_arg" + fi + shift + done +} + + +# func_quote_for_expand ARG +# ------------------------- +# Aesthetically quote ARG to be evaled later; same as above, +# but do not quote variable references. +func_quote_for_expand () +{ + $debug_cmd + + case $1 in + *[\\\`\"]*) + _G_arg=`$ECHO "$1" | $SED \ + -e "$sed_double_quote_subst" -e "$sed_double_backslash"` ;; + *) + _G_arg=$1 ;; + esac + + case $_G_arg in + # Double-quote args containing shell metacharacters to delay + # word splitting and command substitution for a subsequent eval. + # Many Bourne shells cannot handle close brackets correctly + # in scan sets, so we specify it separately. + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + _G_arg=\"$_G_arg\" + ;; + esac + + func_quote_for_expand_result=$_G_arg +} + + +# func_stripname PREFIX SUFFIX NAME +# --------------------------------- +# strip PREFIX and SUFFIX from NAME, and store in func_stripname_result. +# PREFIX and SUFFIX must not contain globbing or regex special +# characters, hashes, percent signs, but SUFFIX may contain a leading +# dot (in which case that matches only a dot). +if test yes = "$_G_HAVE_XSI_OPS"; then + eval 'func_stripname () + { + $debug_cmd + + # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are + # positional parameters, so assign one to ordinary variable first. + func_stripname_result=$3 + func_stripname_result=${func_stripname_result#"$1"} + func_stripname_result=${func_stripname_result%"$2"} + }' +else + func_stripname () + { + $debug_cmd + + case $2 in + .*) func_stripname_result=`$ECHO "$3" | $SED -e "s%^$1%%" -e "s%\\\\$2\$%%"`;; + *) func_stripname_result=`$ECHO "$3" | $SED -e "s%^$1%%" -e "s%$2\$%%"`;; + esac + } +fi + + +# func_show_eval CMD [FAIL_EXP] +# ----------------------------- +# Unless opt_quiet is true, then output CMD. Then, if opt_dryrun is +# not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP +# is given, then evaluate it. +func_show_eval () +{ + $debug_cmd + + _G_cmd=$1 + _G_fail_exp=${2-':'} + + func_quote_for_expand "$_G_cmd" + eval "func_notquiet $func_quote_for_expand_result" + + $opt_dry_run || { + eval "$_G_cmd" + _G_status=$? + if test 0 -ne "$_G_status"; then + eval "(exit $_G_status); $_G_fail_exp" + fi + } +} + + +# func_show_eval_locale CMD [FAIL_EXP] +# ------------------------------------ +# Unless opt_quiet is true, then output CMD. Then, if opt_dryrun is +# not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP +# is given, then evaluate it. Use the saved locale for evaluation. +func_show_eval_locale () +{ + $debug_cmd + + _G_cmd=$1 + _G_fail_exp=${2-':'} + + $opt_quiet || { + func_quote_for_expand "$_G_cmd" + eval "func_echo $func_quote_for_expand_result" + } + + $opt_dry_run || { + eval "$_G_user_locale + $_G_cmd" + _G_status=$? + eval "$_G_safe_locale" + if test 0 -ne "$_G_status"; then + eval "(exit $_G_status); $_G_fail_exp" + fi + } +} + + +# func_tr_sh +# ---------- +# Turn $1 into a string suitable for a shell variable name. +# Result is stored in $func_tr_sh_result. All characters +# not in the set a-zA-Z0-9_ are replaced with '_'. Further, +# if $1 begins with a digit, a '_' is prepended as well. +func_tr_sh () +{ + $debug_cmd + + case $1 in + [0-9]* | *[!a-zA-Z0-9_]*) + func_tr_sh_result=`$ECHO "$1" | $SED -e 's/^\([0-9]\)/_\1/' -e 's/[^a-zA-Z0-9_]/_/g'` + ;; + * ) + func_tr_sh_result=$1 + ;; + esac +} + + +# func_verbose ARG... +# ------------------- +# Echo program name prefixed message in verbose mode only. +func_verbose () +{ + $debug_cmd + + $opt_verbose && func_echo "$*" + + : +} + + +# func_warn_and_continue ARG... +# ----------------------------- +# Echo program name prefixed warning message to standard error. +func_warn_and_continue () +{ + $debug_cmd + + $require_term_colors + + func_echo_infix_1 "${tc_red}warning$tc_reset" "$*" >&2 +} + + +# func_warning CATEGORY ARG... +# ---------------------------- +# Echo program name prefixed warning message to standard error. Warning +# messages can be filtered according to CATEGORY, where this function +# elides messages where CATEGORY is not listed in the global variable +# 'opt_warning_types'. +func_warning () +{ + $debug_cmd + + # CATEGORY must be in the warning_categories list! + case " $warning_categories " in + *" $1 "*) ;; + *) func_internal_error "invalid warning category '$1'" ;; + esac + + _G_category=$1 + shift + + case " $opt_warning_types " in + *" $_G_category "*) $warning_func ${1+"$@"} ;; + esac +} + + +# func_sort_ver VER1 VER2 +# ----------------------- +# 'sort -V' is not generally available. +# Note this deviates from the version comparison in automake +# in that it treats 1.5 < 1.5.0, and treats 1.4.4a < 1.4-p3a +# but this should suffice as we won't be specifying old +# version formats or redundant trailing .0 in bootstrap.conf. +# If we did want full compatibility then we should probably +# use m4_version_compare from autoconf. +func_sort_ver () +{ + $debug_cmd + + printf '%s\n%s\n' "$1" "$2" \ + | sort -t. -k 1,1n -k 2,2n -k 3,3n -k 4,4n -k 5,5n -k 6,6n -k 7,7n -k 8,8n -k 9,9n +} + +# func_lt_ver PREV CURR +# --------------------- +# Return true if PREV and CURR are in the correct order according to +# func_sort_ver, otherwise false. Use it like this: +# +# func_lt_ver "$prev_ver" "$proposed_ver" || func_fatal_error "..." +func_lt_ver () +{ + $debug_cmd + + test "x$1" = x`func_sort_ver "$1" "$2" | $SED 1q` +} + + +# Local variables: +# mode: shell-script +# sh-indentation: 2 +# eval: (add-hook 'before-save-hook 'time-stamp) +# time-stamp-pattern: "10/scriptversion=%:y-%02m-%02d.%02H; # UTC" +# time-stamp-time-zone: "UTC" +# End: +#! /bin/sh + +# Set a version string for this script. +scriptversion=2014-01-07.03; # UTC + +# A portable, pluggable option parser for Bourne shell. +# Written by Gary V. Vaughan, 2010 + +# Copyright (C) 2010-2015 Free Software Foundation, Inc. +# This is free software; see the source for copying conditions. There is NO +# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. + +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + +# Please report bugs or propose patches to gary@gnu.org. + + +## ------ ## +## Usage. ## +## ------ ## + +# This file is a library for parsing options in your shell scripts along +# with assorted other useful supporting features that you can make use +# of too. +# +# For the simplest scripts you might need only: +# +# #!/bin/sh +# . relative/path/to/funclib.sh +# . relative/path/to/options-parser +# scriptversion=1.0 +# func_options ${1+"$@"} +# eval set dummy "$func_options_result"; shift +# ...rest of your script... +# +# In order for the '--version' option to work, you will need to have a +# suitably formatted comment like the one at the top of this file +# starting with '# Written by ' and ending with '# warranty; '. +# +# For '-h' and '--help' to work, you will also need a one line +# description of your script's purpose in a comment directly above the +# '# Written by ' line, like the one at the top of this file. +# +# The default options also support '--debug', which will turn on shell +# execution tracing (see the comment above debug_cmd below for another +# use), and '--verbose' and the func_verbose function to allow your script +# to display verbose messages only when your user has specified +# '--verbose'. +# +# After sourcing this file, you can plug processing for additional +# options by amending the variables from the 'Configuration' section +# below, and following the instructions in the 'Option parsing' +# section further down. + +## -------------- ## +## Configuration. ## +## -------------- ## + +# You should override these variables in your script after sourcing this +# file so that they reflect the customisations you have added to the +# option parser. + +# The usage line for option parsing errors and the start of '-h' and +# '--help' output messages. You can embed shell variables for delayed +# expansion at the time the message is displayed, but you will need to +# quote other shell meta-characters carefully to prevent them being +# expanded when the contents are evaled. +usage='$progpath [OPTION]...' + +# Short help message in response to '-h' and '--help'. Add to this or +# override it after sourcing this library to reflect the full set of +# options your script accepts. +usage_message="\ + --debug enable verbose shell tracing + -W, --warnings=CATEGORY + report the warnings falling in CATEGORY [all] + -v, --verbose verbosely report processing + --version print version information and exit + -h, --help print short or long help message and exit +" + +# Additional text appended to 'usage_message' in response to '--help'. +long_help_message=" +Warning categories include: + 'all' show all warnings + 'none' turn off all the warnings + 'error' warnings are treated as fatal errors" + +# Help message printed before fatal option parsing errors. +fatal_help="Try '\$progname --help' for more information." + + + +## ------------------------- ## +## Hook function management. ## +## ------------------------- ## + +# This section contains functions for adding, removing, and running hooks +# to the main code. A hook is just a named list of of function, that can +# be run in order later on. + +# func_hookable FUNC_NAME +# ----------------------- +# Declare that FUNC_NAME will run hooks added with +# 'func_add_hook FUNC_NAME ...'. +func_hookable () +{ + $debug_cmd + + func_append hookable_fns " $1" +} + + +# func_add_hook FUNC_NAME HOOK_FUNC +# --------------------------------- +# Request that FUNC_NAME call HOOK_FUNC before it returns. FUNC_NAME must +# first have been declared "hookable" by a call to 'func_hookable'. +func_add_hook () +{ + $debug_cmd + + case " $hookable_fns " in + *" $1 "*) ;; + *) func_fatal_error "'$1' does not accept hook functions." ;; + esac + + eval func_append ${1}_hooks '" $2"' +} + + +# func_remove_hook FUNC_NAME HOOK_FUNC +# ------------------------------------ +# Remove HOOK_FUNC from the list of functions called by FUNC_NAME. +func_remove_hook () +{ + $debug_cmd + + eval ${1}_hooks='`$ECHO "\$'$1'_hooks" |$SED "s| '$2'||"`' +} + + +# func_run_hooks FUNC_NAME [ARG]... +# --------------------------------- +# Run all hook functions registered to FUNC_NAME. +# It is assumed that the list of hook functions contains nothing more +# than a whitespace-delimited list of legal shell function names, and +# no effort is wasted trying to catch shell meta-characters or preserve +# whitespace. +func_run_hooks () +{ + $debug_cmd + + case " $hookable_fns " in + *" $1 "*) ;; + *) func_fatal_error "'$1' does not support hook funcions.n" ;; + esac + + eval _G_hook_fns=\$$1_hooks; shift + + for _G_hook in $_G_hook_fns; do + eval $_G_hook '"$@"' + + # store returned options list back into positional + # parameters for next 'cmd' execution. + eval _G_hook_result=\$${_G_hook}_result + eval set dummy "$_G_hook_result"; shift + done + + func_quote_for_eval ${1+"$@"} + func_run_hooks_result=$func_quote_for_eval_result +} + + + +## --------------- ## +## Option parsing. ## +## --------------- ## + +# In order to add your own option parsing hooks, you must accept the +# full positional parameter list in your hook function, remove any +# options that you action, and then pass back the remaining unprocessed +# options in '_result', escaped suitably for +# 'eval'. Like this: +# +# my_options_prep () +# { +# $debug_cmd +# +# # Extend the existing usage message. +# usage_message=$usage_message' +# -s, --silent don'\''t print informational messages +# ' +# +# func_quote_for_eval ${1+"$@"} +# my_options_prep_result=$func_quote_for_eval_result +# } +# func_add_hook func_options_prep my_options_prep +# +# +# my_silent_option () +# { +# $debug_cmd +# +# # Note that for efficiency, we parse as many options as we can +# # recognise in a loop before passing the remainder back to the +# # caller on the first unrecognised argument we encounter. +# while test $# -gt 0; do +# opt=$1; shift +# case $opt in +# --silent|-s) opt_silent=: ;; +# # Separate non-argument short options: +# -s*) func_split_short_opt "$_G_opt" +# set dummy "$func_split_short_opt_name" \ +# "-$func_split_short_opt_arg" ${1+"$@"} +# shift +# ;; +# *) set dummy "$_G_opt" "$*"; shift; break ;; +# esac +# done +# +# func_quote_for_eval ${1+"$@"} +# my_silent_option_result=$func_quote_for_eval_result +# } +# func_add_hook func_parse_options my_silent_option +# +# +# my_option_validation () +# { +# $debug_cmd +# +# $opt_silent && $opt_verbose && func_fatal_help "\ +# '--silent' and '--verbose' options are mutually exclusive." +# +# func_quote_for_eval ${1+"$@"} +# my_option_validation_result=$func_quote_for_eval_result +# } +# func_add_hook func_validate_options my_option_validation +# +# You'll alse need to manually amend $usage_message to reflect the extra +# options you parse. It's preferable to append if you can, so that +# multiple option parsing hooks can be added safely. + + +# func_options [ARG]... +# --------------------- +# All the functions called inside func_options are hookable. See the +# individual implementations for details. +func_hookable func_options +func_options () +{ + $debug_cmd + + func_options_prep ${1+"$@"} + eval func_parse_options \ + ${func_options_prep_result+"$func_options_prep_result"} + eval func_validate_options \ + ${func_parse_options_result+"$func_parse_options_result"} + + eval func_run_hooks func_options \ + ${func_validate_options_result+"$func_validate_options_result"} + + # save modified positional parameters for caller + func_options_result=$func_run_hooks_result +} + + +# func_options_prep [ARG]... +# -------------------------- +# All initialisations required before starting the option parse loop. +# Note that when calling hook functions, we pass through the list of +# positional parameters. If a hook function modifies that list, and +# needs to propogate that back to rest of this script, then the complete +# modified list must be put in 'func_run_hooks_result' before +# returning. +func_hookable func_options_prep +func_options_prep () +{ + $debug_cmd + + # Option defaults: + opt_verbose=false + opt_warning_types= + + func_run_hooks func_options_prep ${1+"$@"} + + # save modified positional parameters for caller + func_options_prep_result=$func_run_hooks_result +} + + +# func_parse_options [ARG]... +# --------------------------- +# The main option parsing loop. +func_hookable func_parse_options +func_parse_options () +{ + $debug_cmd + + func_parse_options_result= + + # this just eases exit handling + while test $# -gt 0; do + # Defer to hook functions for initial option parsing, so they + # get priority in the event of reusing an option name. + func_run_hooks func_parse_options ${1+"$@"} + + # Adjust func_parse_options positional parameters to match + eval set dummy "$func_run_hooks_result"; shift + + # Break out of the loop if we already parsed every option. + test $# -gt 0 || break + + _G_opt=$1 + shift + case $_G_opt in + --debug|-x) debug_cmd='set -x' + func_echo "enabling shell trace mode" + $debug_cmd + ;; + + --no-warnings|--no-warning|--no-warn) + set dummy --warnings none ${1+"$@"} + shift + ;; + + --warnings|--warning|-W) + test $# = 0 && func_missing_arg $_G_opt && break + case " $warning_categories $1" in + *" $1 "*) + # trailing space prevents matching last $1 above + func_append_uniq opt_warning_types " $1" + ;; + *all) + opt_warning_types=$warning_categories + ;; + *none) + opt_warning_types=none + warning_func=: + ;; + *error) + opt_warning_types=$warning_categories + warning_func=func_fatal_error + ;; + *) + func_fatal_error \ + "unsupported warning category: '$1'" + ;; + esac + shift + ;; + + --verbose|-v) opt_verbose=: ;; + --version) func_version ;; + -\?|-h) func_usage ;; + --help) func_help ;; + + # Separate optargs to long options (plugins may need this): + --*=*) func_split_equals "$_G_opt" + set dummy "$func_split_equals_lhs" \ + "$func_split_equals_rhs" ${1+"$@"} + shift + ;; + + # Separate optargs to short options: + -W*) + func_split_short_opt "$_G_opt" + set dummy "$func_split_short_opt_name" \ + "$func_split_short_opt_arg" ${1+"$@"} + shift + ;; + + # Separate non-argument short options: + -\?*|-h*|-v*|-x*) + func_split_short_opt "$_G_opt" + set dummy "$func_split_short_opt_name" \ + "-$func_split_short_opt_arg" ${1+"$@"} + shift + ;; + + --) break ;; + -*) func_fatal_help "unrecognised option: '$_G_opt'" ;; + *) set dummy "$_G_opt" ${1+"$@"}; shift; break ;; + esac + done + + # save modified positional parameters for caller + func_quote_for_eval ${1+"$@"} + func_parse_options_result=$func_quote_for_eval_result +} + + +# func_validate_options [ARG]... +# ------------------------------ +# Perform any sanity checks on option settings and/or unconsumed +# arguments. +func_hookable func_validate_options +func_validate_options () +{ + $debug_cmd + + # Display all warnings if -W was not given. + test -n "$opt_warning_types" || opt_warning_types=" $warning_categories" + + func_run_hooks func_validate_options ${1+"$@"} + + # Bail if the options were screwed! + $exit_cmd $EXIT_FAILURE + + # save modified positional parameters for caller + func_validate_options_result=$func_run_hooks_result +} + + + +## ----------------- ## +## Helper functions. ## +## ----------------- ## + +# This section contains the helper functions used by the rest of the +# hookable option parser framework in ascii-betical order. + + +# func_fatal_help ARG... +# ---------------------- +# Echo program name prefixed message to standard error, followed by +# a help hint, and exit. +func_fatal_help () +{ + $debug_cmd + + eval \$ECHO \""Usage: $usage"\" + eval \$ECHO \""$fatal_help"\" + func_error ${1+"$@"} + exit $EXIT_FAILURE +} + + +# func_help +# --------- +# Echo long help message to standard output and exit. +func_help () +{ + $debug_cmd + + func_usage_message + $ECHO "$long_help_message" + exit 0 +} + + +# func_missing_arg ARGNAME +# ------------------------ +# Echo program name prefixed message to standard error and set global +# exit_cmd. +func_missing_arg () +{ + $debug_cmd + + func_error "Missing argument for '$1'." + exit_cmd=exit +} + + +# func_split_equals STRING +# ------------------------ +# Set func_split_equals_lhs and func_split_equals_rhs shell variables after +# splitting STRING at the '=' sign. +test -z "$_G_HAVE_XSI_OPS" \ + && (eval 'x=a/b/c; + test 5aa/bb/cc = "${#x}${x%%/*}${x%/*}${x#*/}${x##*/}"') 2>/dev/null \ + && _G_HAVE_XSI_OPS=yes + +if test yes = "$_G_HAVE_XSI_OPS" +then + # This is an XSI compatible shell, allowing a faster implementation... + eval 'func_split_equals () + { + $debug_cmd + + func_split_equals_lhs=${1%%=*} + func_split_equals_rhs=${1#*=} + test "x$func_split_equals_lhs" = "x$1" \ + && func_split_equals_rhs= + }' +else + # ...otherwise fall back to using expr, which is often a shell builtin. + func_split_equals () + { + $debug_cmd + + func_split_equals_lhs=`expr "x$1" : 'x\([^=]*\)'` + func_split_equals_rhs= + test "x$func_split_equals_lhs" = "x$1" \ + || func_split_equals_rhs=`expr "x$1" : 'x[^=]*=\(.*\)$'` + } +fi #func_split_equals + + +# func_split_short_opt SHORTOPT +# ----------------------------- +# Set func_split_short_opt_name and func_split_short_opt_arg shell +# variables after splitting SHORTOPT after the 2nd character. +if test yes = "$_G_HAVE_XSI_OPS" +then + # This is an XSI compatible shell, allowing a faster implementation... + eval 'func_split_short_opt () + { + $debug_cmd + + func_split_short_opt_arg=${1#??} + func_split_short_opt_name=${1%"$func_split_short_opt_arg"} + }' +else + # ...otherwise fall back to using expr, which is often a shell builtin. + func_split_short_opt () + { + $debug_cmd + + func_split_short_opt_name=`expr "x$1" : 'x-\(.\)'` + func_split_short_opt_arg=`expr "x$1" : 'x-.\(.*\)$'` + } +fi #func_split_short_opt + + +# func_usage +# ---------- +# Echo short help message to standard output and exit. +func_usage () +{ + $debug_cmd + + func_usage_message + $ECHO "Run '$progname --help |${PAGER-more}' for full usage" + exit 0 +} + + +# func_usage_message +# ------------------ +# Echo short help message to standard output. +func_usage_message () +{ + $debug_cmd + + eval \$ECHO \""Usage: $usage"\" + echo + $SED -n 's|^# || + /^Written by/{ + x;p;x + } + h + /^Written by/q' < "$progpath" + echo + eval \$ECHO \""$usage_message"\" +} + + +# func_version +# ------------ +# Echo version message to standard output and exit. +func_version () +{ + $debug_cmd + + printf '%s\n' "$progname $scriptversion" + $SED -n ' + /(C)/!b go + :more + /\./!{ + N + s|\n# | | + b more + } + :go + /^# Written by /,/# warranty; / { + s|^# || + s|^# *$|| + s|\((C)\)[ 0-9,-]*[ ,-]\([1-9][0-9]* \)|\1 \2| + p + } + /^# Written by / { + s|^# || + p + } + /^warranty; /q' < "$progpath" + + exit $? +} + + +# Local variables: +# mode: shell-script +# sh-indentation: 2 +# eval: (add-hook 'before-save-hook 'time-stamp) +# time-stamp-pattern: "10/scriptversion=%:y-%02m-%02d.%02H; # UTC" +# time-stamp-time-zone: "UTC" +# End: + +# Set a version string. +scriptversion='(GNU libtool) 2.4.6' + + +# func_echo ARG... +# ---------------- +# Libtool also displays the current mode in messages, so override +# funclib.sh func_echo with this custom definition. +func_echo () +{ + $debug_cmd + + _G_message=$* + + func_echo_IFS=$IFS + IFS=$nl + for _G_line in $_G_message; do + IFS=$func_echo_IFS + $ECHO "$progname${opt_mode+: $opt_mode}: $_G_line" + done + IFS=$func_echo_IFS +} + + +# func_warning ARG... +# ------------------- +# Libtool warnings are not categorized, so override funclib.sh +# func_warning with this simpler definition. +func_warning () +{ + $debug_cmd + + $warning_func ${1+"$@"} +} + + +## ---------------- ## +## Options parsing. ## +## ---------------- ## + +# Hook in the functions to make sure our own options are parsed during +# the option parsing loop. + +usage='$progpath [OPTION]... [MODE-ARG]...' + +# Short help message in response to '-h'. +usage_message="Options: + --config show all configuration variables + --debug enable verbose shell tracing + -n, --dry-run display commands without modifying any files + --features display basic configuration information and exit + --mode=MODE use operation mode MODE + --no-warnings equivalent to '-Wnone' + --preserve-dup-deps don't remove duplicate dependency libraries + --quiet, --silent don't print informational messages + --tag=TAG use configuration variables from tag TAG + -v, --verbose print more informational messages than default + --version print version information + -W, --warnings=CATEGORY report the warnings falling in CATEGORY [all] + -h, --help, --help-all print short, long, or detailed help message +" + +# Additional text appended to 'usage_message' in response to '--help'. +func_help () +{ + $debug_cmd + + func_usage_message + $ECHO "$long_help_message + +MODE must be one of the following: + + clean remove files from the build directory + compile compile a source file into a libtool object + execute automatically set library path, then run a program + finish complete the installation of libtool libraries + install install libraries or executables + link create a library or an executable + uninstall remove libraries from an installed directory + +MODE-ARGS vary depending on the MODE. When passed as first option, +'--mode=MODE' may be abbreviated as 'MODE' or a unique abbreviation of that. +Try '$progname --help --mode=MODE' for a more detailed description of MODE. + +When reporting a bug, please describe a test case to reproduce it and +include the following information: + + host-triplet: $host + shell: $SHELL + compiler: $LTCC + compiler flags: $LTCFLAGS + linker: $LD (gnu? $with_gnu_ld) + version: $progname (GNU libtool) 2.4.6 + automake: `($AUTOMAKE --version) 2>/dev/null |$SED 1q` + autoconf: `($AUTOCONF --version) 2>/dev/null |$SED 1q` + +Report bugs to . +GNU libtool home page: . +General help using GNU software: ." + exit 0 +} + + +# func_lo2o OBJECT-NAME +# --------------------- +# Transform OBJECT-NAME from a '.lo' suffix to the platform specific +# object suffix. + +lo2o=s/\\.lo\$/.$objext/ +o2lo=s/\\.$objext\$/.lo/ + +if test yes = "$_G_HAVE_XSI_OPS"; then + eval 'func_lo2o () + { + case $1 in + *.lo) func_lo2o_result=${1%.lo}.$objext ;; + * ) func_lo2o_result=$1 ;; + esac + }' + + # func_xform LIBOBJ-OR-SOURCE + # --------------------------- + # Transform LIBOBJ-OR-SOURCE from a '.o' or '.c' (or otherwise) + # suffix to a '.lo' libtool-object suffix. + eval 'func_xform () + { + func_xform_result=${1%.*}.lo + }' +else + # ...otherwise fall back to using sed. + func_lo2o () + { + func_lo2o_result=`$ECHO "$1" | $SED "$lo2o"` + } + + func_xform () + { + func_xform_result=`$ECHO "$1" | $SED 's|\.[^.]*$|.lo|'` + } +fi + + +# func_fatal_configuration ARG... +# ------------------------------- +# Echo program name prefixed message to standard error, followed by +# a configuration failure hint, and exit. +func_fatal_configuration () +{ + func__fatal_error ${1+"$@"} \ + "See the $PACKAGE documentation for more information." \ + "Fatal configuration error." +} + + +# func_config +# ----------- +# Display the configuration for all the tags in this script. +func_config () +{ + re_begincf='^# ### BEGIN LIBTOOL' + re_endcf='^# ### END LIBTOOL' + + # Default configuration. + $SED "1,/$re_begincf CONFIG/d;/$re_endcf CONFIG/,\$d" < "$progpath" + + # Now print the configurations for the tags. + for tagname in $taglist; do + $SED -n "/$re_begincf TAG CONFIG: $tagname\$/,/$re_endcf TAG CONFIG: $tagname\$/p" < "$progpath" + done + + exit $? +} + + +# func_features +# ------------- +# Display the features supported by this script. +func_features () +{ + echo "host: $host" + if test yes = "$build_libtool_libs"; then + echo "enable shared libraries" + else + echo "disable shared libraries" + fi + if test yes = "$build_old_libs"; then + echo "enable static libraries" + else + echo "disable static libraries" + fi + + exit $? +} + + +# func_enable_tag TAGNAME +# ----------------------- +# Verify that TAGNAME is valid, and either flag an error and exit, or +# enable the TAGNAME tag. We also add TAGNAME to the global $taglist +# variable here. +func_enable_tag () +{ + # Global variable: + tagname=$1 + + re_begincf="^# ### BEGIN LIBTOOL TAG CONFIG: $tagname\$" + re_endcf="^# ### END LIBTOOL TAG CONFIG: $tagname\$" + sed_extractcf=/$re_begincf/,/$re_endcf/p + + # Validate tagname. + case $tagname in + *[!-_A-Za-z0-9,/]*) + func_fatal_error "invalid tag name: $tagname" + ;; + esac + + # Don't test for the "default" C tag, as we know it's + # there but not specially marked. + case $tagname in + CC) ;; + *) + if $GREP "$re_begincf" "$progpath" >/dev/null 2>&1; then + taglist="$taglist $tagname" + + # Evaluate the configuration. Be careful to quote the path + # and the sed script, to avoid splitting on whitespace, but + # also don't use non-portable quotes within backquotes within + # quotes we have to do it in 2 steps: + extractedcf=`$SED -n -e "$sed_extractcf" < "$progpath"` + eval "$extractedcf" + else + func_error "ignoring unknown tag $tagname" + fi + ;; + esac +} + + +# func_check_version_match +# ------------------------ +# Ensure that we are using m4 macros, and libtool script from the same +# release of libtool. +func_check_version_match () +{ + if test "$package_revision" != "$macro_revision"; then + if test "$VERSION" != "$macro_version"; then + if test -z "$macro_version"; then + cat >&2 <<_LT_EOF +$progname: Version mismatch error. This is $PACKAGE $VERSION, but the +$progname: definition of this LT_INIT comes from an older release. +$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION +$progname: and run autoconf again. +_LT_EOF + else + cat >&2 <<_LT_EOF +$progname: Version mismatch error. This is $PACKAGE $VERSION, but the +$progname: definition of this LT_INIT comes from $PACKAGE $macro_version. +$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION +$progname: and run autoconf again. +_LT_EOF + fi + else + cat >&2 <<_LT_EOF +$progname: Version mismatch error. This is $PACKAGE $VERSION, revision $package_revision, +$progname: but the definition of this LT_INIT comes from revision $macro_revision. +$progname: You should recreate aclocal.m4 with macros from revision $package_revision +$progname: of $PACKAGE $VERSION and run autoconf again. +_LT_EOF + fi + + exit $EXIT_MISMATCH + fi +} + + +# libtool_options_prep [ARG]... +# ----------------------------- +# Preparation for options parsed by libtool. +libtool_options_prep () +{ + $debug_mode + + # Option defaults: + opt_config=false + opt_dlopen= + opt_dry_run=false + opt_help=false + opt_mode= + opt_preserve_dup_deps=false + opt_quiet=false + + nonopt= + preserve_args= + + # Shorthand for --mode=foo, only valid as the first argument + case $1 in + clean|clea|cle|cl) + shift; set dummy --mode clean ${1+"$@"}; shift + ;; + compile|compil|compi|comp|com|co|c) + shift; set dummy --mode compile ${1+"$@"}; shift + ;; + execute|execut|execu|exec|exe|ex|e) + shift; set dummy --mode execute ${1+"$@"}; shift + ;; + finish|finis|fini|fin|fi|f) + shift; set dummy --mode finish ${1+"$@"}; shift + ;; + install|instal|insta|inst|ins|in|i) + shift; set dummy --mode install ${1+"$@"}; shift + ;; + link|lin|li|l) + shift; set dummy --mode link ${1+"$@"}; shift + ;; + uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u) + shift; set dummy --mode uninstall ${1+"$@"}; shift + ;; + esac + + # Pass back the list of options. + func_quote_for_eval ${1+"$@"} + libtool_options_prep_result=$func_quote_for_eval_result +} +func_add_hook func_options_prep libtool_options_prep + + +# libtool_parse_options [ARG]... +# --------------------------------- +# Provide handling for libtool specific options. +libtool_parse_options () +{ + $debug_cmd + + # Perform our own loop to consume as many options as possible in + # each iteration. + while test $# -gt 0; do + _G_opt=$1 + shift + case $_G_opt in + --dry-run|--dryrun|-n) + opt_dry_run=: + ;; + + --config) func_config ;; + + --dlopen|-dlopen) + opt_dlopen="${opt_dlopen+$opt_dlopen +}$1" + shift + ;; + + --preserve-dup-deps) + opt_preserve_dup_deps=: ;; + + --features) func_features ;; + + --finish) set dummy --mode finish ${1+"$@"}; shift ;; + + --help) opt_help=: ;; + + --help-all) opt_help=': help-all' ;; + + --mode) test $# = 0 && func_missing_arg $_G_opt && break + opt_mode=$1 + case $1 in + # Valid mode arguments: + clean|compile|execute|finish|install|link|relink|uninstall) ;; + + # Catch anything else as an error + *) func_error "invalid argument for $_G_opt" + exit_cmd=exit + break + ;; + esac + shift + ;; + + --no-silent|--no-quiet) + opt_quiet=false + func_append preserve_args " $_G_opt" + ;; + + --no-warnings|--no-warning|--no-warn) + opt_warning=false + func_append preserve_args " $_G_opt" + ;; + + --no-verbose) + opt_verbose=false + func_append preserve_args " $_G_opt" + ;; + + --silent|--quiet) + opt_quiet=: + opt_verbose=false + func_append preserve_args " $_G_opt" + ;; + + --tag) test $# = 0 && func_missing_arg $_G_opt && break + opt_tag=$1 + func_append preserve_args " $_G_opt $1" + func_enable_tag "$1" + shift + ;; + + --verbose|-v) opt_quiet=false + opt_verbose=: + func_append preserve_args " $_G_opt" + ;; + + # An option not handled by this hook function: + *) set dummy "$_G_opt" ${1+"$@"}; shift; break ;; + esac + done + + + # save modified positional parameters for caller + func_quote_for_eval ${1+"$@"} + libtool_parse_options_result=$func_quote_for_eval_result +} +func_add_hook func_parse_options libtool_parse_options + + + +# libtool_validate_options [ARG]... +# --------------------------------- +# Perform any sanity checks on option settings and/or unconsumed +# arguments. +libtool_validate_options () +{ + # save first non-option argument + if test 0 -lt $#; then + nonopt=$1 + shift + fi + + # preserve --debug + test : = "$debug_cmd" || func_append preserve_args " --debug" + + case $host in + # Solaris2 added to fix http://debbugs.gnu.org/cgi/bugreport.cgi?bug=16452 + # see also: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59788 + *cygwin* | *mingw* | *pw32* | *cegcc* | *solaris2* | *os2*) + # don't eliminate duplications in $postdeps and $predeps + opt_duplicate_compiler_generated_deps=: + ;; + *) + opt_duplicate_compiler_generated_deps=$opt_preserve_dup_deps + ;; + esac + + $opt_help || { + # Sanity checks first: + func_check_version_match + + test yes != "$build_libtool_libs" \ + && test yes != "$build_old_libs" \ + && func_fatal_configuration "not configured to build any kind of library" + + # Darwin sucks + eval std_shrext=\"$shrext_cmds\" + + # Only execute mode is allowed to have -dlopen flags. + if test -n "$opt_dlopen" && test execute != "$opt_mode"; then + func_error "unrecognized option '-dlopen'" + $ECHO "$help" 1>&2 + exit $EXIT_FAILURE + fi + + # Change the help message to a mode-specific one. + generic_help=$help + help="Try '$progname --help --mode=$opt_mode' for more information." + } + + # Pass back the unparsed argument list + func_quote_for_eval ${1+"$@"} + libtool_validate_options_result=$func_quote_for_eval_result +} +func_add_hook func_validate_options libtool_validate_options + + +# Process options as early as possible so that --help and --version +# can return quickly. +func_options ${1+"$@"} +eval set dummy "$func_options_result"; shift + + + +## ----------- ## +## Main. ## +## ----------- ## + +magic='%%%MAGIC variable%%%' +magic_exe='%%%MAGIC EXE variable%%%' + +# Global variables. +extracted_archives= +extracted_serial=0 + +# If this variable is set in any of the actions, the command in it +# will be execed at the end. This prevents here-documents from being +# left over by shells. +exec_cmd= + + +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +$1 +_LTECHO_EOF' +} + +# func_generated_by_libtool +# True iff stdin has been generated by Libtool. This function is only +# a basic sanity check; it will hardly flush out determined imposters. +func_generated_by_libtool_p () +{ + $GREP "^# Generated by .*$PACKAGE" > /dev/null 2>&1 +} + +# func_lalib_p file +# True iff FILE is a libtool '.la' library or '.lo' object file. +# This function is only a basic sanity check; it will hardly flush out +# determined imposters. +func_lalib_p () +{ + test -f "$1" && + $SED -e 4q "$1" 2>/dev/null | func_generated_by_libtool_p +} + +# func_lalib_unsafe_p file +# True iff FILE is a libtool '.la' library or '.lo' object file. +# This function implements the same check as func_lalib_p without +# resorting to external programs. To this end, it redirects stdin and +# closes it afterwards, without saving the original file descriptor. +# As a safety measure, use it only where a negative result would be +# fatal anyway. Works if 'file' does not exist. +func_lalib_unsafe_p () +{ + lalib_p=no + if test -f "$1" && test -r "$1" && exec 5<&0 <"$1"; then + for lalib_p_l in 1 2 3 4 + do + read lalib_p_line + case $lalib_p_line in + \#\ Generated\ by\ *$PACKAGE* ) lalib_p=yes; break;; + esac + done + exec 0<&5 5<&- + fi + test yes = "$lalib_p" +} + +# func_ltwrapper_script_p file +# True iff FILE is a libtool wrapper script +# This function is only a basic sanity check; it will hardly flush out +# determined imposters. +func_ltwrapper_script_p () +{ + test -f "$1" && + $lt_truncate_bin < "$1" 2>/dev/null | func_generated_by_libtool_p +} + +# func_ltwrapper_executable_p file +# True iff FILE is a libtool wrapper executable +# This function is only a basic sanity check; it will hardly flush out +# determined imposters. +func_ltwrapper_executable_p () +{ + func_ltwrapper_exec_suffix= + case $1 in + *.exe) ;; + *) func_ltwrapper_exec_suffix=.exe ;; + esac + $GREP "$magic_exe" "$1$func_ltwrapper_exec_suffix" >/dev/null 2>&1 +} + +# func_ltwrapper_scriptname file +# Assumes file is an ltwrapper_executable +# uses $file to determine the appropriate filename for a +# temporary ltwrapper_script. +func_ltwrapper_scriptname () +{ + func_dirname_and_basename "$1" "" "." + func_stripname '' '.exe' "$func_basename_result" + func_ltwrapper_scriptname_result=$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper +} + +# func_ltwrapper_p file +# True iff FILE is a libtool wrapper script or wrapper executable +# This function is only a basic sanity check; it will hardly flush out +# determined imposters. +func_ltwrapper_p () +{ + func_ltwrapper_script_p "$1" || func_ltwrapper_executable_p "$1" +} + + +# func_execute_cmds commands fail_cmd +# Execute tilde-delimited COMMANDS. +# If FAIL_CMD is given, eval that upon failure. +# FAIL_CMD may read-access the current command in variable CMD! +func_execute_cmds () +{ + $debug_cmd + + save_ifs=$IFS; IFS='~' + for cmd in $1; do + IFS=$sp$nl + eval cmd=\"$cmd\" + IFS=$save_ifs + func_show_eval "$cmd" "${2-:}" + done + IFS=$save_ifs +} + + +# func_source file +# Source FILE, adding directory component if necessary. +# Note that it is not necessary on cygwin/mingw to append a dot to +# FILE even if both FILE and FILE.exe exist: automatic-append-.exe +# behavior happens only for exec(3), not for open(2)! Also, sourcing +# 'FILE.' does not work on cygwin managed mounts. +func_source () +{ + $debug_cmd + + case $1 in + */* | *\\*) . "$1" ;; + *) . "./$1" ;; + esac +} + + +# func_resolve_sysroot PATH +# Replace a leading = in PATH with a sysroot. Store the result into +# func_resolve_sysroot_result +func_resolve_sysroot () +{ + func_resolve_sysroot_result=$1 + case $func_resolve_sysroot_result in + =*) + func_stripname '=' '' "$func_resolve_sysroot_result" + func_resolve_sysroot_result=$lt_sysroot$func_stripname_result + ;; + esac +} + +# func_replace_sysroot PATH +# If PATH begins with the sysroot, replace it with = and +# store the result into func_replace_sysroot_result. +func_replace_sysroot () +{ + case $lt_sysroot:$1 in + ?*:"$lt_sysroot"*) + func_stripname "$lt_sysroot" '' "$1" + func_replace_sysroot_result='='$func_stripname_result + ;; + *) + # Including no sysroot. + func_replace_sysroot_result=$1 + ;; + esac +} + +# func_infer_tag arg +# Infer tagged configuration to use if any are available and +# if one wasn't chosen via the "--tag" command line option. +# Only attempt this if the compiler in the base compile +# command doesn't match the default compiler. +# arg is usually of the form 'gcc ...' +func_infer_tag () +{ + $debug_cmd + + if test -n "$available_tags" && test -z "$tagname"; then + CC_quoted= + for arg in $CC; do + func_append_quoted CC_quoted "$arg" + done + CC_expanded=`func_echo_all $CC` + CC_quoted_expanded=`func_echo_all $CC_quoted` + case $@ in + # Blanks in the command may have been stripped by the calling shell, + # but not from the CC environment variable when configure was run. + " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ + " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) ;; + # Blanks at the start of $base_compile will cause this to fail + # if we don't check for them as well. + *) + for z in $available_tags; do + if $GREP "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$progpath" > /dev/null; then + # Evaluate the configuration. + eval "`$SED -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`" + CC_quoted= + for arg in $CC; do + # Double-quote args containing other shell metacharacters. + func_append_quoted CC_quoted "$arg" + done + CC_expanded=`func_echo_all $CC` + CC_quoted_expanded=`func_echo_all $CC_quoted` + case "$@ " in + " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ + " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) + # The compiler in the base compile command matches + # the one in the tagged configuration. + # Assume this is the tagged configuration we want. + tagname=$z + break + ;; + esac + fi + done + # If $tagname still isn't set, then no tagged configuration + # was found and let the user know that the "--tag" command + # line option must be used. + if test -z "$tagname"; then + func_echo "unable to infer tagged configuration" + func_fatal_error "specify a tag with '--tag'" +# else +# func_verbose "using $tagname tagged configuration" + fi + ;; + esac + fi +} + + + +# func_write_libtool_object output_name pic_name nonpic_name +# Create a libtool object file (analogous to a ".la" file), +# but don't create it if we're doing a dry run. +func_write_libtool_object () +{ + write_libobj=$1 + if test yes = "$build_libtool_libs"; then + write_lobj=\'$2\' + else + write_lobj=none + fi + + if test yes = "$build_old_libs"; then + write_oldobj=\'$3\' + else + write_oldobj=none + fi + + $opt_dry_run || { + cat >${write_libobj}T </dev/null` + if test "$?" -eq 0 && test -n "$func_convert_core_file_wine_to_w32_tmp"; then + func_convert_core_file_wine_to_w32_result=`$ECHO "$func_convert_core_file_wine_to_w32_tmp" | + $SED -e "$sed_naive_backslashify"` + else + func_convert_core_file_wine_to_w32_result= + fi + fi +} +# end: func_convert_core_file_wine_to_w32 + + +# func_convert_core_path_wine_to_w32 ARG +# Helper function used by path conversion functions when $build is *nix, and +# $host is mingw, cygwin, or some other w32 environment. Relies on a correctly +# configured wine environment available, with the winepath program in $build's +# $PATH. Assumes ARG has no leading or trailing path separator characters. +# +# ARG is path to be converted from $build format to win32. +# Result is available in $func_convert_core_path_wine_to_w32_result. +# Unconvertible file (directory) names in ARG are skipped; if no directory names +# are convertible, then the result may be empty. +func_convert_core_path_wine_to_w32 () +{ + $debug_cmd + + # unfortunately, winepath doesn't convert paths, only file names + func_convert_core_path_wine_to_w32_result= + if test -n "$1"; then + oldIFS=$IFS + IFS=: + for func_convert_core_path_wine_to_w32_f in $1; do + IFS=$oldIFS + func_convert_core_file_wine_to_w32 "$func_convert_core_path_wine_to_w32_f" + if test -n "$func_convert_core_file_wine_to_w32_result"; then + if test -z "$func_convert_core_path_wine_to_w32_result"; then + func_convert_core_path_wine_to_w32_result=$func_convert_core_file_wine_to_w32_result + else + func_append func_convert_core_path_wine_to_w32_result ";$func_convert_core_file_wine_to_w32_result" + fi + fi + done + IFS=$oldIFS + fi +} +# end: func_convert_core_path_wine_to_w32 + + +# func_cygpath ARGS... +# Wrapper around calling the cygpath program via LT_CYGPATH. This is used when +# when (1) $build is *nix and Cygwin is hosted via a wine environment; or (2) +# $build is MSYS and $host is Cygwin, or (3) $build is Cygwin. In case (1) or +# (2), returns the Cygwin file name or path in func_cygpath_result (input +# file name or path is assumed to be in w32 format, as previously converted +# from $build's *nix or MSYS format). In case (3), returns the w32 file name +# or path in func_cygpath_result (input file name or path is assumed to be in +# Cygwin format). Returns an empty string on error. +# +# ARGS are passed to cygpath, with the last one being the file name or path to +# be converted. +# +# Specify the absolute *nix (or w32) name to cygpath in the LT_CYGPATH +# environment variable; do not put it in $PATH. +func_cygpath () +{ + $debug_cmd + + if test -n "$LT_CYGPATH" && test -f "$LT_CYGPATH"; then + func_cygpath_result=`$LT_CYGPATH "$@" 2>/dev/null` + if test "$?" -ne 0; then + # on failure, ensure result is empty + func_cygpath_result= + fi + else + func_cygpath_result= + func_error "LT_CYGPATH is empty or specifies non-existent file: '$LT_CYGPATH'" + fi +} +#end: func_cygpath + + +# func_convert_core_msys_to_w32 ARG +# Convert file name or path ARG from MSYS format to w32 format. Return +# result in func_convert_core_msys_to_w32_result. +func_convert_core_msys_to_w32 () +{ + $debug_cmd + + # awkward: cmd appends spaces to result + func_convert_core_msys_to_w32_result=`( cmd //c echo "$1" ) 2>/dev/null | + $SED -e 's/[ ]*$//' -e "$sed_naive_backslashify"` +} +#end: func_convert_core_msys_to_w32 + + +# func_convert_file_check ARG1 ARG2 +# Verify that ARG1 (a file name in $build format) was converted to $host +# format in ARG2. Otherwise, emit an error message, but continue (resetting +# func_to_host_file_result to ARG1). +func_convert_file_check () +{ + $debug_cmd + + if test -z "$2" && test -n "$1"; then + func_error "Could not determine host file name corresponding to" + func_error " '$1'" + func_error "Continuing, but uninstalled executables may not work." + # Fallback: + func_to_host_file_result=$1 + fi +} +# end func_convert_file_check + + +# func_convert_path_check FROM_PATHSEP TO_PATHSEP FROM_PATH TO_PATH +# Verify that FROM_PATH (a path in $build format) was converted to $host +# format in TO_PATH. Otherwise, emit an error message, but continue, resetting +# func_to_host_file_result to a simplistic fallback value (see below). +func_convert_path_check () +{ + $debug_cmd + + if test -z "$4" && test -n "$3"; then + func_error "Could not determine the host path corresponding to" + func_error " '$3'" + func_error "Continuing, but uninstalled executables may not work." + # Fallback. This is a deliberately simplistic "conversion" and + # should not be "improved". See libtool.info. + if test "x$1" != "x$2"; then + lt_replace_pathsep_chars="s|$1|$2|g" + func_to_host_path_result=`echo "$3" | + $SED -e "$lt_replace_pathsep_chars"` + else + func_to_host_path_result=$3 + fi + fi +} +# end func_convert_path_check + + +# func_convert_path_front_back_pathsep FRONTPAT BACKPAT REPL ORIG +# Modifies func_to_host_path_result by prepending REPL if ORIG matches FRONTPAT +# and appending REPL if ORIG matches BACKPAT. +func_convert_path_front_back_pathsep () +{ + $debug_cmd + + case $4 in + $1 ) func_to_host_path_result=$3$func_to_host_path_result + ;; + esac + case $4 in + $2 ) func_append func_to_host_path_result "$3" + ;; + esac +} +# end func_convert_path_front_back_pathsep + + +################################################## +# $build to $host FILE NAME CONVERSION FUNCTIONS # +################################################## +# invoked via '$to_host_file_cmd ARG' +# +# In each case, ARG is the path to be converted from $build to $host format. +# Result will be available in $func_to_host_file_result. + + +# func_to_host_file ARG +# Converts the file name ARG from $build format to $host format. Return result +# in func_to_host_file_result. +func_to_host_file () +{ + $debug_cmd + + $to_host_file_cmd "$1" +} +# end func_to_host_file + + +# func_to_tool_file ARG LAZY +# converts the file name ARG from $build format to toolchain format. Return +# result in func_to_tool_file_result. If the conversion in use is listed +# in (the comma separated) LAZY, no conversion takes place. +func_to_tool_file () +{ + $debug_cmd + + case ,$2, in + *,"$to_tool_file_cmd",*) + func_to_tool_file_result=$1 + ;; + *) + $to_tool_file_cmd "$1" + func_to_tool_file_result=$func_to_host_file_result + ;; + esac +} +# end func_to_tool_file + + +# func_convert_file_noop ARG +# Copy ARG to func_to_host_file_result. +func_convert_file_noop () +{ + func_to_host_file_result=$1 +} +# end func_convert_file_noop + + +# func_convert_file_msys_to_w32 ARG +# Convert file name ARG from (mingw) MSYS to (mingw) w32 format; automatic +# conversion to w32 is not available inside the cwrapper. Returns result in +# func_to_host_file_result. +func_convert_file_msys_to_w32 () +{ + $debug_cmd + + func_to_host_file_result=$1 + if test -n "$1"; then + func_convert_core_msys_to_w32 "$1" + func_to_host_file_result=$func_convert_core_msys_to_w32_result + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_msys_to_w32 + + +# func_convert_file_cygwin_to_w32 ARG +# Convert file name ARG from Cygwin to w32 format. Returns result in +# func_to_host_file_result. +func_convert_file_cygwin_to_w32 () +{ + $debug_cmd + + func_to_host_file_result=$1 + if test -n "$1"; then + # because $build is cygwin, we call "the" cygpath in $PATH; no need to use + # LT_CYGPATH in this case. + func_to_host_file_result=`cygpath -m "$1"` + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_cygwin_to_w32 + + +# func_convert_file_nix_to_w32 ARG +# Convert file name ARG from *nix to w32 format. Requires a wine environment +# and a working winepath. Returns result in func_to_host_file_result. +func_convert_file_nix_to_w32 () +{ + $debug_cmd + + func_to_host_file_result=$1 + if test -n "$1"; then + func_convert_core_file_wine_to_w32 "$1" + func_to_host_file_result=$func_convert_core_file_wine_to_w32_result + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_nix_to_w32 + + +# func_convert_file_msys_to_cygwin ARG +# Convert file name ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. +# Returns result in func_to_host_file_result. +func_convert_file_msys_to_cygwin () +{ + $debug_cmd + + func_to_host_file_result=$1 + if test -n "$1"; then + func_convert_core_msys_to_w32 "$1" + func_cygpath -u "$func_convert_core_msys_to_w32_result" + func_to_host_file_result=$func_cygpath_result + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_msys_to_cygwin + + +# func_convert_file_nix_to_cygwin ARG +# Convert file name ARG from *nix to Cygwin format. Requires Cygwin installed +# in a wine environment, working winepath, and LT_CYGPATH set. Returns result +# in func_to_host_file_result. +func_convert_file_nix_to_cygwin () +{ + $debug_cmd + + func_to_host_file_result=$1 + if test -n "$1"; then + # convert from *nix to w32, then use cygpath to convert from w32 to cygwin. + func_convert_core_file_wine_to_w32 "$1" + func_cygpath -u "$func_convert_core_file_wine_to_w32_result" + func_to_host_file_result=$func_cygpath_result + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_nix_to_cygwin + + +############################################# +# $build to $host PATH CONVERSION FUNCTIONS # +############################################# +# invoked via '$to_host_path_cmd ARG' +# +# In each case, ARG is the path to be converted from $build to $host format. +# The result will be available in $func_to_host_path_result. +# +# Path separators are also converted from $build format to $host format. If +# ARG begins or ends with a path separator character, it is preserved (but +# converted to $host format) on output. +# +# All path conversion functions are named using the following convention: +# file name conversion function : func_convert_file_X_to_Y () +# path conversion function : func_convert_path_X_to_Y () +# where, for any given $build/$host combination the 'X_to_Y' value is the +# same. If conversion functions are added for new $build/$host combinations, +# the two new functions must follow this pattern, or func_init_to_host_path_cmd +# will break. + + +# func_init_to_host_path_cmd +# Ensures that function "pointer" variable $to_host_path_cmd is set to the +# appropriate value, based on the value of $to_host_file_cmd. +to_host_path_cmd= +func_init_to_host_path_cmd () +{ + $debug_cmd + + if test -z "$to_host_path_cmd"; then + func_stripname 'func_convert_file_' '' "$to_host_file_cmd" + to_host_path_cmd=func_convert_path_$func_stripname_result + fi +} + + +# func_to_host_path ARG +# Converts the path ARG from $build format to $host format. Return result +# in func_to_host_path_result. +func_to_host_path () +{ + $debug_cmd + + func_init_to_host_path_cmd + $to_host_path_cmd "$1" +} +# end func_to_host_path + + +# func_convert_path_noop ARG +# Copy ARG to func_to_host_path_result. +func_convert_path_noop () +{ + func_to_host_path_result=$1 +} +# end func_convert_path_noop + + +# func_convert_path_msys_to_w32 ARG +# Convert path ARG from (mingw) MSYS to (mingw) w32 format; automatic +# conversion to w32 is not available inside the cwrapper. Returns result in +# func_to_host_path_result. +func_convert_path_msys_to_w32 () +{ + $debug_cmd + + func_to_host_path_result=$1 + if test -n "$1"; then + # Remove leading and trailing path separator characters from ARG. MSYS + # behavior is inconsistent here; cygpath turns them into '.;' and ';.'; + # and winepath ignores them completely. + func_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" + func_to_host_path_result=$func_convert_core_msys_to_w32_result + func_convert_path_check : ";" \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" + fi +} +# end func_convert_path_msys_to_w32 + + +# func_convert_path_cygwin_to_w32 ARG +# Convert path ARG from Cygwin to w32 format. Returns result in +# func_to_host_file_result. +func_convert_path_cygwin_to_w32 () +{ + $debug_cmd + + func_to_host_path_result=$1 + if test -n "$1"; then + # See func_convert_path_msys_to_w32: + func_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_to_host_path_result=`cygpath -m -p "$func_to_host_path_tmp1"` + func_convert_path_check : ";" \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" + fi +} +# end func_convert_path_cygwin_to_w32 + + +# func_convert_path_nix_to_w32 ARG +# Convert path ARG from *nix to w32 format. Requires a wine environment and +# a working winepath. Returns result in func_to_host_file_result. +func_convert_path_nix_to_w32 () +{ + $debug_cmd + + func_to_host_path_result=$1 + if test -n "$1"; then + # See func_convert_path_msys_to_w32: + func_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" + func_to_host_path_result=$func_convert_core_path_wine_to_w32_result + func_convert_path_check : ";" \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" + fi +} +# end func_convert_path_nix_to_w32 + + +# func_convert_path_msys_to_cygwin ARG +# Convert path ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. +# Returns result in func_to_host_file_result. +func_convert_path_msys_to_cygwin () +{ + $debug_cmd + + func_to_host_path_result=$1 + if test -n "$1"; then + # See func_convert_path_msys_to_w32: + func_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" + func_cygpath -u -p "$func_convert_core_msys_to_w32_result" + func_to_host_path_result=$func_cygpath_result + func_convert_path_check : : \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" : "$1" + fi +} +# end func_convert_path_msys_to_cygwin + + +# func_convert_path_nix_to_cygwin ARG +# Convert path ARG from *nix to Cygwin format. Requires Cygwin installed in a +# a wine environment, working winepath, and LT_CYGPATH set. Returns result in +# func_to_host_file_result. +func_convert_path_nix_to_cygwin () +{ + $debug_cmd + + func_to_host_path_result=$1 + if test -n "$1"; then + # Remove leading and trailing path separator characters from + # ARG. msys behavior is inconsistent here, cygpath turns them + # into '.;' and ';.', and winepath ignores them completely. + func_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" + func_cygpath -u -p "$func_convert_core_path_wine_to_w32_result" + func_to_host_path_result=$func_cygpath_result + func_convert_path_check : : \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" : "$1" + fi +} +# end func_convert_path_nix_to_cygwin + + +# func_dll_def_p FILE +# True iff FILE is a Windows DLL '.def' file. +# Keep in sync with _LT_DLL_DEF_P in libtool.m4 +func_dll_def_p () +{ + $debug_cmd + + func_dll_def_p_tmp=`$SED -n \ + -e 's/^[ ]*//' \ + -e '/^\(;.*\)*$/d' \ + -e 's/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p' \ + -e q \ + "$1"` + test DEF = "$func_dll_def_p_tmp" +} + + +# func_mode_compile arg... +func_mode_compile () +{ + $debug_cmd + + # Get the compilation command and the source file. + base_compile= + srcfile=$nonopt # always keep a non-empty value in "srcfile" + suppress_opt=yes + suppress_output= + arg_mode=normal + libobj= + later= + pie_flag= + + for arg + do + case $arg_mode in + arg ) + # do not "continue". Instead, add this to base_compile + lastarg=$arg + arg_mode=normal + ;; + + target ) + libobj=$arg + arg_mode=normal + continue + ;; + + normal ) + # Accept any command-line options. + case $arg in + -o) + test -n "$libobj" && \ + func_fatal_error "you cannot specify '-o' more than once" + arg_mode=target + continue + ;; + + -pie | -fpie | -fPIE) + func_append pie_flag " $arg" + continue + ;; + + -shared | -static | -prefer-pic | -prefer-non-pic) + func_append later " $arg" + continue + ;; + + -no-suppress) + suppress_opt=no + continue + ;; + + -Xcompiler) + arg_mode=arg # the next one goes into the "base_compile" arg list + continue # The current "srcfile" will either be retained or + ;; # replaced later. I would guess that would be a bug. + + -Wc,*) + func_stripname '-Wc,' '' "$arg" + args=$func_stripname_result + lastarg= + save_ifs=$IFS; IFS=, + for arg in $args; do + IFS=$save_ifs + func_append_quoted lastarg "$arg" + done + IFS=$save_ifs + func_stripname ' ' '' "$lastarg" + lastarg=$func_stripname_result + + # Add the arguments to base_compile. + func_append base_compile " $lastarg" + continue + ;; + + *) + # Accept the current argument as the source file. + # The previous "srcfile" becomes the current argument. + # + lastarg=$srcfile + srcfile=$arg + ;; + esac # case $arg + ;; + esac # case $arg_mode + + # Aesthetically quote the previous argument. + func_append_quoted base_compile "$lastarg" + done # for arg + + case $arg_mode in + arg) + func_fatal_error "you must specify an argument for -Xcompile" + ;; + target) + func_fatal_error "you must specify a target with '-o'" + ;; + *) + # Get the name of the library object. + test -z "$libobj" && { + func_basename "$srcfile" + libobj=$func_basename_result + } + ;; + esac + + # Recognize several different file suffixes. + # If the user specifies -o file.o, it is replaced with file.lo + case $libobj in + *.[cCFSifmso] | \ + *.ada | *.adb | *.ads | *.asm | \ + *.c++ | *.cc | *.ii | *.class | *.cpp | *.cxx | \ + *.[fF][09]? | *.for | *.java | *.go | *.obj | *.sx | *.cu | *.cup) + func_xform "$libobj" + libobj=$func_xform_result + ;; + esac + + case $libobj in + *.lo) func_lo2o "$libobj"; obj=$func_lo2o_result ;; + *) + func_fatal_error "cannot determine name of library object from '$libobj'" + ;; + esac + + func_infer_tag $base_compile + + for arg in $later; do + case $arg in + -shared) + test yes = "$build_libtool_libs" \ + || func_fatal_configuration "cannot build a shared library" + build_old_libs=no + continue + ;; + + -static) + build_libtool_libs=no + build_old_libs=yes + continue + ;; + + -prefer-pic) + pic_mode=yes + continue + ;; + + -prefer-non-pic) + pic_mode=no + continue + ;; + esac + done + + func_quote_for_eval "$libobj" + test "X$libobj" != "X$func_quote_for_eval_result" \ + && $ECHO "X$libobj" | $GREP '[]~#^*{};<>?"'"'"' &()|`$[]' \ + && func_warning "libobj name '$libobj' may not contain shell special characters." + func_dirname_and_basename "$obj" "/" "" + objname=$func_basename_result + xdir=$func_dirname_result + lobj=$xdir$objdir/$objname + + test -z "$base_compile" && \ + func_fatal_help "you must specify a compilation command" + + # Delete any leftover library objects. + if test yes = "$build_old_libs"; then + removelist="$obj $lobj $libobj ${libobj}T" + else + removelist="$lobj $libobj ${libobj}T" + fi + + # On Cygwin there's no "real" PIC flag so we must build both object types + case $host_os in + cygwin* | mingw* | pw32* | os2* | cegcc*) + pic_mode=default + ;; + esac + if test no = "$pic_mode" && test pass_all != "$deplibs_check_method"; then + # non-PIC code in shared libraries is not supported + pic_mode=default + fi + + # Calculate the filename of the output object if compiler does + # not support -o with -c + if test no = "$compiler_c_o"; then + output_obj=`$ECHO "$srcfile" | $SED 's%^.*/%%; s%\.[^.]*$%%'`.$objext + lockfile=$output_obj.lock + else + output_obj= + need_locks=no + lockfile= + fi + + # Lock this critical section if it is needed + # We use this script file to make the link, it avoids creating a new file + if test yes = "$need_locks"; then + until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do + func_echo "Waiting for $lockfile to be removed" + sleep 2 + done + elif test warn = "$need_locks"; then + if test -f "$lockfile"; then + $ECHO "\ +*** ERROR, $lockfile exists and contains: +`cat $lockfile 2>/dev/null` + +This indicates that another process is trying to use the same +temporary object file, and libtool could not work around it because +your compiler does not support '-c' and '-o' together. If you +repeat this compilation, it may succeed, by chance, but you had better +avoid parallel builds (make -j) in this platform, or get a better +compiler." + + $opt_dry_run || $RM $removelist + exit $EXIT_FAILURE + fi + func_append removelist " $output_obj" + $ECHO "$srcfile" > "$lockfile" + fi + + $opt_dry_run || $RM $removelist + func_append removelist " $lockfile" + trap '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' 1 2 15 + + func_to_tool_file "$srcfile" func_convert_file_msys_to_w32 + srcfile=$func_to_tool_file_result + func_quote_for_eval "$srcfile" + qsrcfile=$func_quote_for_eval_result + + # Only build a PIC object if we are building libtool libraries. + if test yes = "$build_libtool_libs"; then + # Without this assignment, base_compile gets emptied. + fbsd_hideous_sh_bug=$base_compile + + if test no != "$pic_mode"; then + command="$base_compile $qsrcfile $pic_flag" + else + # Don't build PIC code + command="$base_compile $qsrcfile" + fi + + func_mkdir_p "$xdir$objdir" + + if test -z "$output_obj"; then + # Place PIC objects in $objdir + func_append command " -o $lobj" + fi + + func_show_eval_locale "$command" \ + 'test -n "$output_obj" && $RM $removelist; exit $EXIT_FAILURE' + + if test warn = "$need_locks" && + test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then + $ECHO "\ +*** ERROR, $lockfile contains: +`cat $lockfile 2>/dev/null` + +but it should contain: +$srcfile + +This indicates that another process is trying to use the same +temporary object file, and libtool could not work around it because +your compiler does not support '-c' and '-o' together. If you +repeat this compilation, it may succeed, by chance, but you had better +avoid parallel builds (make -j) in this platform, or get a better +compiler." + + $opt_dry_run || $RM $removelist + exit $EXIT_FAILURE + fi + + # Just move the object if needed, then go on to compile the next one + if test -n "$output_obj" && test "X$output_obj" != "X$lobj"; then + func_show_eval '$MV "$output_obj" "$lobj"' \ + 'error=$?; $opt_dry_run || $RM $removelist; exit $error' + fi + + # Allow error messages only from the first compilation. + if test yes = "$suppress_opt"; then + suppress_output=' >/dev/null 2>&1' + fi + fi + + # Only build a position-dependent object if we build old libraries. + if test yes = "$build_old_libs"; then + if test yes != "$pic_mode"; then + # Don't build PIC code + command="$base_compile $qsrcfile$pie_flag" + else + command="$base_compile $qsrcfile $pic_flag" + fi + if test yes = "$compiler_c_o"; then + func_append command " -o $obj" + fi + + # Suppress compiler output if we already did a PIC compilation. + func_append command "$suppress_output" + func_show_eval_locale "$command" \ + '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' + + if test warn = "$need_locks" && + test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then + $ECHO "\ +*** ERROR, $lockfile contains: +`cat $lockfile 2>/dev/null` + +but it should contain: +$srcfile + +This indicates that another process is trying to use the same +temporary object file, and libtool could not work around it because +your compiler does not support '-c' and '-o' together. If you +repeat this compilation, it may succeed, by chance, but you had better +avoid parallel builds (make -j) in this platform, or get a better +compiler." + + $opt_dry_run || $RM $removelist + exit $EXIT_FAILURE + fi + + # Just move the object if needed + if test -n "$output_obj" && test "X$output_obj" != "X$obj"; then + func_show_eval '$MV "$output_obj" "$obj"' \ + 'error=$?; $opt_dry_run || $RM $removelist; exit $error' + fi + fi + + $opt_dry_run || { + func_write_libtool_object "$libobj" "$objdir/$objname" "$objname" + + # Unlock the critical section if it was locked + if test no != "$need_locks"; then + removelist=$lockfile + $RM "$lockfile" + fi + } + + exit $EXIT_SUCCESS +} + +$opt_help || { + test compile = "$opt_mode" && func_mode_compile ${1+"$@"} +} + +func_mode_help () +{ + # We need to display help for each of the modes. + case $opt_mode in + "") + # Generic help is extracted from the usage comments + # at the start of this file. + func_help + ;; + + clean) + $ECHO \ +"Usage: $progname [OPTION]... --mode=clean RM [RM-OPTION]... FILE... + +Remove files from the build directory. + +RM is the name of the program to use to delete files associated with each FILE +(typically '/bin/rm'). RM-OPTIONS are options (such as '-f') to be passed +to RM. + +If FILE is a libtool library, object or program, all the files associated +with it are deleted. Otherwise, only FILE itself is deleted using RM." + ;; + + compile) + $ECHO \ +"Usage: $progname [OPTION]... --mode=compile COMPILE-COMMAND... SOURCEFILE + +Compile a source file into a libtool library object. + +This mode accepts the following additional options: + + -o OUTPUT-FILE set the output file name to OUTPUT-FILE + -no-suppress do not suppress compiler output for multiple passes + -prefer-pic try to build PIC objects only + -prefer-non-pic try to build non-PIC objects only + -shared do not build a '.o' file suitable for static linking + -static only build a '.o' file suitable for static linking + -Wc,FLAG pass FLAG directly to the compiler + +COMPILE-COMMAND is a command to be used in creating a 'standard' object file +from the given SOURCEFILE. + +The output file name is determined by removing the directory component from +SOURCEFILE, then substituting the C source code suffix '.c' with the +library object suffix, '.lo'." + ;; + + execute) + $ECHO \ +"Usage: $progname [OPTION]... --mode=execute COMMAND [ARGS]... + +Automatically set library path, then run a program. + +This mode accepts the following additional options: + + -dlopen FILE add the directory containing FILE to the library path + +This mode sets the library path environment variable according to '-dlopen' +flags. + +If any of the ARGS are libtool executable wrappers, then they are translated +into their corresponding uninstalled binary, and any of their required library +directories are added to the library path. + +Then, COMMAND is executed, with ARGS as arguments." + ;; + + finish) + $ECHO \ +"Usage: $progname [OPTION]... --mode=finish [LIBDIR]... + +Complete the installation of libtool libraries. + +Each LIBDIR is a directory that contains libtool libraries. + +The commands that this mode executes may require superuser privileges. Use +the '--dry-run' option if you just want to see what would be executed." + ;; + + install) + $ECHO \ +"Usage: $progname [OPTION]... --mode=install INSTALL-COMMAND... + +Install executables or libraries. + +INSTALL-COMMAND is the installation command. The first component should be +either the 'install' or 'cp' program. + +The following components of INSTALL-COMMAND are treated specially: + + -inst-prefix-dir PREFIX-DIR Use PREFIX-DIR as a staging area for installation + +The rest of the components are interpreted as arguments to that command (only +BSD-compatible install options are recognized)." + ;; + + link) + $ECHO \ +"Usage: $progname [OPTION]... --mode=link LINK-COMMAND... + +Link object files or libraries together to form another library, or to +create an executable program. + +LINK-COMMAND is a command using the C compiler that you would use to create +a program from several object files. + +The following components of LINK-COMMAND are treated specially: + + -all-static do not do any dynamic linking at all + -avoid-version do not add a version suffix if possible + -bindir BINDIR specify path to binaries directory (for systems where + libraries must be found in the PATH setting at runtime) + -dlopen FILE '-dlpreopen' FILE if it cannot be dlopened at runtime + -dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols + -export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3) + -export-symbols SYMFILE + try to export only the symbols listed in SYMFILE + -export-symbols-regex REGEX + try to export only the symbols matching REGEX + -LLIBDIR search LIBDIR for required installed libraries + -lNAME OUTPUT-FILE requires the installed library libNAME + -module build a library that can dlopened + -no-fast-install disable the fast-install mode + -no-install link a not-installable executable + -no-undefined declare that a library does not refer to external symbols + -o OUTPUT-FILE create OUTPUT-FILE from the specified objects + -objectlist FILE use a list of object files found in FILE to specify objects + -os2dllname NAME force a short DLL name on OS/2 (no effect on other OSes) + -precious-files-regex REGEX + don't remove output files matching REGEX + -release RELEASE specify package release information + -rpath LIBDIR the created library will eventually be installed in LIBDIR + -R[ ]LIBDIR add LIBDIR to the runtime path of programs and libraries + -shared only do dynamic linking of libtool libraries + -shrext SUFFIX override the standard shared library file extension + -static do not do any dynamic linking of uninstalled libtool libraries + -static-libtool-libs + do not do any dynamic linking of libtool libraries + -version-info CURRENT[:REVISION[:AGE]] + specify library version info [each variable defaults to 0] + -weak LIBNAME declare that the target provides the LIBNAME interface + -Wc,FLAG + -Xcompiler FLAG pass linker-specific FLAG directly to the compiler + -Wl,FLAG + -Xlinker FLAG pass linker-specific FLAG directly to the linker + -XCClinker FLAG pass link-specific FLAG to the compiler driver (CC) + +All other options (arguments beginning with '-') are ignored. + +Every other argument is treated as a filename. Files ending in '.la' are +treated as uninstalled libtool libraries, other files are standard or library +object files. + +If the OUTPUT-FILE ends in '.la', then a libtool library is created, +only library objects ('.lo' files) may be specified, and '-rpath' is +required, except when creating a convenience library. + +If OUTPUT-FILE ends in '.a' or '.lib', then a standard library is created +using 'ar' and 'ranlib', or on Windows using 'lib'. + +If OUTPUT-FILE ends in '.lo' or '.$objext', then a reloadable object file +is created, otherwise an executable program is created." + ;; + + uninstall) + $ECHO \ +"Usage: $progname [OPTION]... --mode=uninstall RM [RM-OPTION]... FILE... + +Remove libraries from an installation directory. + +RM is the name of the program to use to delete files associated with each FILE +(typically '/bin/rm'). RM-OPTIONS are options (such as '-f') to be passed +to RM. + +If FILE is a libtool library, all the files associated with it are deleted. +Otherwise, only FILE itself is deleted using RM." + ;; + + *) + func_fatal_help "invalid operation mode '$opt_mode'" + ;; + esac + + echo + $ECHO "Try '$progname --help' for more information about other modes." +} + +# Now that we've collected a possible --mode arg, show help if necessary +if $opt_help; then + if test : = "$opt_help"; then + func_mode_help + else + { + func_help noexit + for opt_mode in compile link execute install finish uninstall clean; do + func_mode_help + done + } | $SED -n '1p; 2,$s/^Usage:/ or: /p' + { + func_help noexit + for opt_mode in compile link execute install finish uninstall clean; do + echo + func_mode_help + done + } | + $SED '1d + /^When reporting/,/^Report/{ + H + d + } + $x + /information about other modes/d + /more detailed .*MODE/d + s/^Usage:.*--mode=\([^ ]*\) .*/Description of \1 mode:/' + fi + exit $? +fi + + +# func_mode_execute arg... +func_mode_execute () +{ + $debug_cmd + + # The first argument is the command name. + cmd=$nonopt + test -z "$cmd" && \ + func_fatal_help "you must specify a COMMAND" + + # Handle -dlopen flags immediately. + for file in $opt_dlopen; do + test -f "$file" \ + || func_fatal_help "'$file' is not a file" + + dir= + case $file in + *.la) + func_resolve_sysroot "$file" + file=$func_resolve_sysroot_result + + # Check to see that this really is a libtool archive. + func_lalib_unsafe_p "$file" \ + || func_fatal_help "'$lib' is not a valid libtool archive" + + # Read the libtool library. + dlname= + library_names= + func_source "$file" + + # Skip this library if it cannot be dlopened. + if test -z "$dlname"; then + # Warn if it was a shared library. + test -n "$library_names" && \ + func_warning "'$file' was not linked with '-export-dynamic'" + continue + fi + + func_dirname "$file" "" "." + dir=$func_dirname_result + + if test -f "$dir/$objdir/$dlname"; then + func_append dir "/$objdir" + else + if test ! -f "$dir/$dlname"; then + func_fatal_error "cannot find '$dlname' in '$dir' or '$dir/$objdir'" + fi + fi + ;; + + *.lo) + # Just add the directory containing the .lo file. + func_dirname "$file" "" "." + dir=$func_dirname_result + ;; + + *) + func_warning "'-dlopen' is ignored for non-libtool libraries and objects" + continue + ;; + esac + + # Get the absolute pathname. + absdir=`cd "$dir" && pwd` + test -n "$absdir" && dir=$absdir + + # Now add the directory to shlibpath_var. + if eval "test -z \"\$$shlibpath_var\""; then + eval "$shlibpath_var=\"\$dir\"" + else + eval "$shlibpath_var=\"\$dir:\$$shlibpath_var\"" + fi + done + + # This variable tells wrapper scripts just to set shlibpath_var + # rather than running their programs. + libtool_execute_magic=$magic + + # Check if any of the arguments is a wrapper script. + args= + for file + do + case $file in + -* | *.la | *.lo ) ;; + *) + # Do a test to see if this is really a libtool program. + if func_ltwrapper_script_p "$file"; then + func_source "$file" + # Transform arg to wrapped name. + file=$progdir/$program + elif func_ltwrapper_executable_p "$file"; then + func_ltwrapper_scriptname "$file" + func_source "$func_ltwrapper_scriptname_result" + # Transform arg to wrapped name. + file=$progdir/$program + fi + ;; + esac + # Quote arguments (to preserve shell metacharacters). + func_append_quoted args "$file" + done + + if $opt_dry_run; then + # Display what would be done. + if test -n "$shlibpath_var"; then + eval "\$ECHO \"\$shlibpath_var=\$$shlibpath_var\"" + echo "export $shlibpath_var" + fi + $ECHO "$cmd$args" + exit $EXIT_SUCCESS + else + if test -n "$shlibpath_var"; then + # Export the shlibpath_var. + eval "export $shlibpath_var" + fi + + # Restore saved environment variables + for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES + do + eval "if test \"\${save_$lt_var+set}\" = set; then + $lt_var=\$save_$lt_var; export $lt_var + else + $lt_unset $lt_var + fi" + done + + # Now prepare to actually exec the command. + exec_cmd=\$cmd$args + fi +} + +test execute = "$opt_mode" && func_mode_execute ${1+"$@"} + + +# func_mode_finish arg... +func_mode_finish () +{ + $debug_cmd + + libs= + libdirs= + admincmds= + + for opt in "$nonopt" ${1+"$@"} + do + if test -d "$opt"; then + func_append libdirs " $opt" + + elif test -f "$opt"; then + if func_lalib_unsafe_p "$opt"; then + func_append libs " $opt" + else + func_warning "'$opt' is not a valid libtool archive" + fi + + else + func_fatal_error "invalid argument '$opt'" + fi + done + + if test -n "$libs"; then + if test -n "$lt_sysroot"; then + sysroot_regex=`$ECHO "$lt_sysroot" | $SED "$sed_make_literal_regex"` + sysroot_cmd="s/\([ ']\)$sysroot_regex/\1/g;" + else + sysroot_cmd= + fi + + # Remove sysroot references + if $opt_dry_run; then + for lib in $libs; do + echo "removing references to $lt_sysroot and '=' prefixes from $lib" + done + else + tmpdir=`func_mktempdir` + for lib in $libs; do + $SED -e "$sysroot_cmd s/\([ ']-[LR]\)=/\1/g; s/\([ ']\)=/\1/g" $lib \ + > $tmpdir/tmp-la + mv -f $tmpdir/tmp-la $lib + done + ${RM}r "$tmpdir" + fi + fi + + if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then + for libdir in $libdirs; do + if test -n "$finish_cmds"; then + # Do each command in the finish commands. + func_execute_cmds "$finish_cmds" 'admincmds="$admincmds +'"$cmd"'"' + fi + if test -n "$finish_eval"; then + # Do the single finish_eval. + eval cmds=\"$finish_eval\" + $opt_dry_run || eval "$cmds" || func_append admincmds " + $cmds" + fi + done + fi + + # Exit here if they wanted silent mode. + $opt_quiet && exit $EXIT_SUCCESS + + if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then + echo "----------------------------------------------------------------------" + echo "Libraries have been installed in:" + for libdir in $libdirs; do + $ECHO " $libdir" + done + echo + echo "If you ever happen to want to link against installed libraries" + echo "in a given directory, LIBDIR, you must either use libtool, and" + echo "specify the full pathname of the library, or use the '-LLIBDIR'" + echo "flag during linking and do at least one of the following:" + if test -n "$shlibpath_var"; then + echo " - add LIBDIR to the '$shlibpath_var' environment variable" + echo " during execution" + fi + if test -n "$runpath_var"; then + echo " - add LIBDIR to the '$runpath_var' environment variable" + echo " during linking" + fi + if test -n "$hardcode_libdir_flag_spec"; then + libdir=LIBDIR + eval flag=\"$hardcode_libdir_flag_spec\" + + $ECHO " - use the '$flag' linker flag" + fi + if test -n "$admincmds"; then + $ECHO " - have your system administrator run these commands:$admincmds" + fi + if test -f /etc/ld.so.conf; then + echo " - have your system administrator add LIBDIR to '/etc/ld.so.conf'" + fi + echo + + echo "See any operating system documentation about shared libraries for" + case $host in + solaris2.[6789]|solaris2.1[0-9]) + echo "more information, such as the ld(1), crle(1) and ld.so(8) manual" + echo "pages." + ;; + *) + echo "more information, such as the ld(1) and ld.so(8) manual pages." + ;; + esac + echo "----------------------------------------------------------------------" + fi + exit $EXIT_SUCCESS +} + +test finish = "$opt_mode" && func_mode_finish ${1+"$@"} + + +# func_mode_install arg... +func_mode_install () +{ + $debug_cmd + + # There may be an optional sh(1) argument at the beginning of + # install_prog (especially on Windows NT). + if test "$SHELL" = "$nonopt" || test /bin/sh = "$nonopt" || + # Allow the use of GNU shtool's install command. + case $nonopt in *shtool*) :;; *) false;; esac + then + # Aesthetically quote it. + func_quote_for_eval "$nonopt" + install_prog="$func_quote_for_eval_result " + arg=$1 + shift + else + install_prog= + arg=$nonopt + fi + + # The real first argument should be the name of the installation program. + # Aesthetically quote it. + func_quote_for_eval "$arg" + func_append install_prog "$func_quote_for_eval_result" + install_shared_prog=$install_prog + case " $install_prog " in + *[\\\ /]cp\ *) install_cp=: ;; + *) install_cp=false ;; + esac + + # We need to accept at least all the BSD install flags. + dest= + files= + opts= + prev= + install_type= + isdir=false + stripme= + no_mode=: + for arg + do + arg2= + if test -n "$dest"; then + func_append files " $dest" + dest=$arg + continue + fi + + case $arg in + -d) isdir=: ;; + -f) + if $install_cp; then :; else + prev=$arg + fi + ;; + -g | -m | -o) + prev=$arg + ;; + -s) + stripme=" -s" + continue + ;; + -*) + ;; + *) + # If the previous option needed an argument, then skip it. + if test -n "$prev"; then + if test X-m = "X$prev" && test -n "$install_override_mode"; then + arg2=$install_override_mode + no_mode=false + fi + prev= + else + dest=$arg + continue + fi + ;; + esac + + # Aesthetically quote the argument. + func_quote_for_eval "$arg" + func_append install_prog " $func_quote_for_eval_result" + if test -n "$arg2"; then + func_quote_for_eval "$arg2" + fi + func_append install_shared_prog " $func_quote_for_eval_result" + done + + test -z "$install_prog" && \ + func_fatal_help "you must specify an install program" + + test -n "$prev" && \ + func_fatal_help "the '$prev' option requires an argument" + + if test -n "$install_override_mode" && $no_mode; then + if $install_cp; then :; else + func_quote_for_eval "$install_override_mode" + func_append install_shared_prog " -m $func_quote_for_eval_result" + fi + fi + + if test -z "$files"; then + if test -z "$dest"; then + func_fatal_help "no file or destination specified" + else + func_fatal_help "you must specify a destination" + fi + fi + + # Strip any trailing slash from the destination. + func_stripname '' '/' "$dest" + dest=$func_stripname_result + + # Check to see that the destination is a directory. + test -d "$dest" && isdir=: + if $isdir; then + destdir=$dest + destname= + else + func_dirname_and_basename "$dest" "" "." + destdir=$func_dirname_result + destname=$func_basename_result + + # Not a directory, so check to see that there is only one file specified. + set dummy $files; shift + test "$#" -gt 1 && \ + func_fatal_help "'$dest' is not a directory" + fi + case $destdir in + [\\/]* | [A-Za-z]:[\\/]*) ;; + *) + for file in $files; do + case $file in + *.lo) ;; + *) + func_fatal_help "'$destdir' must be an absolute directory name" + ;; + esac + done + ;; + esac + + # This variable tells wrapper scripts just to set variables rather + # than running their programs. + libtool_install_magic=$magic + + staticlibs= + future_libdirs= + current_libdirs= + for file in $files; do + + # Do each installation. + case $file in + *.$libext) + # Do the static libraries later. + func_append staticlibs " $file" + ;; + + *.la) + func_resolve_sysroot "$file" + file=$func_resolve_sysroot_result + + # Check to see that this really is a libtool archive. + func_lalib_unsafe_p "$file" \ + || func_fatal_help "'$file' is not a valid libtool archive" + + library_names= + old_library= + relink_command= + func_source "$file" + + # Add the libdir to current_libdirs if it is the destination. + if test "X$destdir" = "X$libdir"; then + case "$current_libdirs " in + *" $libdir "*) ;; + *) func_append current_libdirs " $libdir" ;; + esac + else + # Note the libdir as a future libdir. + case "$future_libdirs " in + *" $libdir "*) ;; + *) func_append future_libdirs " $libdir" ;; + esac + fi + + func_dirname "$file" "/" "" + dir=$func_dirname_result + func_append dir "$objdir" + + if test -n "$relink_command"; then + # Determine the prefix the user has applied to our future dir. + inst_prefix_dir=`$ECHO "$destdir" | $SED -e "s%$libdir\$%%"` + + # Don't allow the user to place us outside of our expected + # location b/c this prevents finding dependent libraries that + # are installed to the same prefix. + # At present, this check doesn't affect windows .dll's that + # are installed into $libdir/../bin (currently, that works fine) + # but it's something to keep an eye on. + test "$inst_prefix_dir" = "$destdir" && \ + func_fatal_error "error: cannot install '$file' to a directory not ending in $libdir" + + if test -n "$inst_prefix_dir"; then + # Stick the inst_prefix_dir data into the link command. + relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"` + else + relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%%"` + fi + + func_warning "relinking '$file'" + func_show_eval "$relink_command" \ + 'func_fatal_error "error: relink '\''$file'\'' with the above command before installing it"' + fi + + # See the names of the shared library. + set dummy $library_names; shift + if test -n "$1"; then + realname=$1 + shift + + srcname=$realname + test -n "$relink_command" && srcname=${realname}T + + # Install the shared library and build the symlinks. + func_show_eval "$install_shared_prog $dir/$srcname $destdir/$realname" \ + 'exit $?' + tstripme=$stripme + case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + case $realname in + *.dll.a) + tstripme= + ;; + esac + ;; + os2*) + case $realname in + *_dll.a) + tstripme= + ;; + esac + ;; + esac + if test -n "$tstripme" && test -n "$striplib"; then + func_show_eval "$striplib $destdir/$realname" 'exit $?' + fi + + if test "$#" -gt 0; then + # Delete the old symlinks, and create new ones. + # Try 'ln -sf' first, because the 'ln' binary might depend on + # the symlink we replace! Solaris /bin/ln does not understand -f, + # so we also need to try rm && ln -s. + for linkname + do + test "$linkname" != "$realname" \ + && func_show_eval "(cd $destdir && { $LN_S -f $realname $linkname || { $RM $linkname && $LN_S $realname $linkname; }; })" + done + fi + + # Do each command in the postinstall commands. + lib=$destdir/$realname + func_execute_cmds "$postinstall_cmds" 'exit $?' + fi + + # Install the pseudo-library for information purposes. + func_basename "$file" + name=$func_basename_result + instname=$dir/${name}i + func_show_eval "$install_prog $instname $destdir/$name" 'exit $?' + + # Maybe install the static library, too. + test -n "$old_library" && func_append staticlibs " $dir/$old_library" + ;; + + *.lo) + # Install (i.e. copy) a libtool object. + + # Figure out destination file name, if it wasn't already specified. + if test -n "$destname"; then + destfile=$destdir/$destname + else + func_basename "$file" + destfile=$func_basename_result + destfile=$destdir/$destfile + fi + + # Deduce the name of the destination old-style object file. + case $destfile in + *.lo) + func_lo2o "$destfile" + staticdest=$func_lo2o_result + ;; + *.$objext) + staticdest=$destfile + destfile= + ;; + *) + func_fatal_help "cannot copy a libtool object to '$destfile'" + ;; + esac + + # Install the libtool object if requested. + test -n "$destfile" && \ + func_show_eval "$install_prog $file $destfile" 'exit $?' + + # Install the old object if enabled. + if test yes = "$build_old_libs"; then + # Deduce the name of the old-style object file. + func_lo2o "$file" + staticobj=$func_lo2o_result + func_show_eval "$install_prog \$staticobj \$staticdest" 'exit $?' + fi + exit $EXIT_SUCCESS + ;; + + *) + # Figure out destination file name, if it wasn't already specified. + if test -n "$destname"; then + destfile=$destdir/$destname + else + func_basename "$file" + destfile=$func_basename_result + destfile=$destdir/$destfile + fi + + # If the file is missing, and there is a .exe on the end, strip it + # because it is most likely a libtool script we actually want to + # install + stripped_ext= + case $file in + *.exe) + if test ! -f "$file"; then + func_stripname '' '.exe' "$file" + file=$func_stripname_result + stripped_ext=.exe + fi + ;; + esac + + # Do a test to see if this is really a libtool program. + case $host in + *cygwin* | *mingw*) + if func_ltwrapper_executable_p "$file"; then + func_ltwrapper_scriptname "$file" + wrapper=$func_ltwrapper_scriptname_result + else + func_stripname '' '.exe' "$file" + wrapper=$func_stripname_result + fi + ;; + *) + wrapper=$file + ;; + esac + if func_ltwrapper_script_p "$wrapper"; then + notinst_deplibs= + relink_command= + + func_source "$wrapper" + + # Check the variables that should have been set. + test -z "$generated_by_libtool_version" && \ + func_fatal_error "invalid libtool wrapper script '$wrapper'" + + finalize=: + for lib in $notinst_deplibs; do + # Check to see that each library is installed. + libdir= + if test -f "$lib"; then + func_source "$lib" + fi + libfile=$libdir/`$ECHO "$lib" | $SED 's%^.*/%%g'` + if test -n "$libdir" && test ! -f "$libfile"; then + func_warning "'$lib' has not been installed in '$libdir'" + finalize=false + fi + done + + relink_command= + func_source "$wrapper" + + outputname= + if test no = "$fast_install" && test -n "$relink_command"; then + $opt_dry_run || { + if $finalize; then + tmpdir=`func_mktempdir` + func_basename "$file$stripped_ext" + file=$func_basename_result + outputname=$tmpdir/$file + # Replace the output file specification. + relink_command=`$ECHO "$relink_command" | $SED 's%@OUTPUT@%'"$outputname"'%g'` + + $opt_quiet || { + func_quote_for_expand "$relink_command" + eval "func_echo $func_quote_for_expand_result" + } + if eval "$relink_command"; then : + else + func_error "error: relink '$file' with the above command before installing it" + $opt_dry_run || ${RM}r "$tmpdir" + continue + fi + file=$outputname + else + func_warning "cannot relink '$file'" + fi + } + else + # Install the binary that we compiled earlier. + file=`$ECHO "$file$stripped_ext" | $SED "s%\([^/]*\)$%$objdir/\1%"` + fi + fi + + # remove .exe since cygwin /usr/bin/install will append another + # one anyway + case $install_prog,$host in + */usr/bin/install*,*cygwin*) + case $file:$destfile in + *.exe:*.exe) + # this is ok + ;; + *.exe:*) + destfile=$destfile.exe + ;; + *:*.exe) + func_stripname '' '.exe' "$destfile" + destfile=$func_stripname_result + ;; + esac + ;; + esac + func_show_eval "$install_prog\$stripme \$file \$destfile" 'exit $?' + $opt_dry_run || if test -n "$outputname"; then + ${RM}r "$tmpdir" + fi + ;; + esac + done + + for file in $staticlibs; do + func_basename "$file" + name=$func_basename_result + + # Set up the ranlib parameters. + oldlib=$destdir/$name + func_to_tool_file "$oldlib" func_convert_file_msys_to_w32 + tool_oldlib=$func_to_tool_file_result + + func_show_eval "$install_prog \$file \$oldlib" 'exit $?' + + if test -n "$stripme" && test -n "$old_striplib"; then + func_show_eval "$old_striplib $tool_oldlib" 'exit $?' + fi + + # Do each command in the postinstall commands. + func_execute_cmds "$old_postinstall_cmds" 'exit $?' + done + + test -n "$future_libdirs" && \ + func_warning "remember to run '$progname --finish$future_libdirs'" + + if test -n "$current_libdirs"; then + # Maybe just do a dry run. + $opt_dry_run && current_libdirs=" -n$current_libdirs" + exec_cmd='$SHELL "$progpath" $preserve_args --finish$current_libdirs' + else + exit $EXIT_SUCCESS + fi +} + +test install = "$opt_mode" && func_mode_install ${1+"$@"} + + +# func_generate_dlsyms outputname originator pic_p +# Extract symbols from dlprefiles and create ${outputname}S.o with +# a dlpreopen symbol table. +func_generate_dlsyms () +{ + $debug_cmd + + my_outputname=$1 + my_originator=$2 + my_pic_p=${3-false} + my_prefix=`$ECHO "$my_originator" | $SED 's%[^a-zA-Z0-9]%_%g'` + my_dlsyms= + + if test -n "$dlfiles$dlprefiles" || test no != "$dlself"; then + if test -n "$NM" && test -n "$global_symbol_pipe"; then + my_dlsyms=${my_outputname}S.c + else + func_error "not configured to extract global symbols from dlpreopened files" + fi + fi + + if test -n "$my_dlsyms"; then + case $my_dlsyms in + "") ;; + *.c) + # Discover the nlist of each of the dlfiles. + nlist=$output_objdir/$my_outputname.nm + + func_show_eval "$RM $nlist ${nlist}S ${nlist}T" + + # Parse the name list into a source file. + func_verbose "creating $output_objdir/$my_dlsyms" + + $opt_dry_run || $ECHO > "$output_objdir/$my_dlsyms" "\ +/* $my_dlsyms - symbol resolution table for '$my_outputname' dlsym emulation. */ +/* Generated by $PROGRAM (GNU $PACKAGE) $VERSION */ + +#ifdef __cplusplus +extern \"C\" { +#endif + +#if defined __GNUC__ && (((__GNUC__ == 4) && (__GNUC_MINOR__ >= 4)) || (__GNUC__ > 4)) +#pragma GCC diagnostic ignored \"-Wstrict-prototypes\" +#endif + +/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ +#if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE +/* DATA imports from DLLs on WIN32 can't be const, because runtime + relocations are performed -- see ld's documentation on pseudo-relocs. */ +# define LT_DLSYM_CONST +#elif defined __osf__ +/* This system does not cope well with relocations in const data. */ +# define LT_DLSYM_CONST +#else +# define LT_DLSYM_CONST const +#endif + +#define STREQ(s1, s2) (strcmp ((s1), (s2)) == 0) + +/* External symbol declarations for the compiler. */\ +" + + if test yes = "$dlself"; then + func_verbose "generating symbol list for '$output'" + + $opt_dry_run || echo ': @PROGRAM@ ' > "$nlist" + + # Add our own program objects to the symbol list. + progfiles=`$ECHO "$objs$old_deplibs" | $SP2NL | $SED "$lo2o" | $NL2SP` + for progfile in $progfiles; do + func_to_tool_file "$progfile" func_convert_file_msys_to_w32 + func_verbose "extracting global C symbols from '$func_to_tool_file_result'" + $opt_dry_run || eval "$NM $func_to_tool_file_result | $global_symbol_pipe >> '$nlist'" + done + + if test -n "$exclude_expsyms"; then + $opt_dry_run || { + eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T' + eval '$MV "$nlist"T "$nlist"' + } + fi + + if test -n "$export_symbols_regex"; then + $opt_dry_run || { + eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T' + eval '$MV "$nlist"T "$nlist"' + } + fi + + # Prepare the list of exported symbols + if test -z "$export_symbols"; then + export_symbols=$output_objdir/$outputname.exp + $opt_dry_run || { + $RM $export_symbols + eval "$SED -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' + case $host in + *cygwin* | *mingw* | *cegcc* ) + eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' + eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"' + ;; + esac + } + else + $opt_dry_run || { + eval "$SED -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"' + eval '$GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T' + eval '$MV "$nlist"T "$nlist"' + case $host in + *cygwin* | *mingw* | *cegcc* ) + eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' + eval 'cat "$nlist" >> "$output_objdir/$outputname.def"' + ;; + esac + } + fi + fi + + for dlprefile in $dlprefiles; do + func_verbose "extracting global C symbols from '$dlprefile'" + func_basename "$dlprefile" + name=$func_basename_result + case $host in + *cygwin* | *mingw* | *cegcc* ) + # if an import library, we need to obtain dlname + if func_win32_import_lib_p "$dlprefile"; then + func_tr_sh "$dlprefile" + eval "curr_lafile=\$libfile_$func_tr_sh_result" + dlprefile_dlbasename= + if test -n "$curr_lafile" && func_lalib_p "$curr_lafile"; then + # Use subshell, to avoid clobbering current variable values + dlprefile_dlname=`source "$curr_lafile" && echo "$dlname"` + if test -n "$dlprefile_dlname"; then + func_basename "$dlprefile_dlname" + dlprefile_dlbasename=$func_basename_result + else + # no lafile. user explicitly requested -dlpreopen . + $sharedlib_from_linklib_cmd "$dlprefile" + dlprefile_dlbasename=$sharedlib_from_linklib_result + fi + fi + $opt_dry_run || { + if test -n "$dlprefile_dlbasename"; then + eval '$ECHO ": $dlprefile_dlbasename" >> "$nlist"' + else + func_warning "Could not compute DLL name from $name" + eval '$ECHO ": $name " >> "$nlist"' + fi + func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 + eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe | + $SED -e '/I __imp/d' -e 's/I __nm_/D /;s/_nm__//' >> '$nlist'" + } + else # not an import lib + $opt_dry_run || { + eval '$ECHO ": $name " >> "$nlist"' + func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 + eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" + } + fi + ;; + *) + $opt_dry_run || { + eval '$ECHO ": $name " >> "$nlist"' + func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 + eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" + } + ;; + esac + done + + $opt_dry_run || { + # Make sure we have at least an empty file. + test -f "$nlist" || : > "$nlist" + + if test -n "$exclude_expsyms"; then + $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T + $MV "$nlist"T "$nlist" + fi + + # Try sorting and uniquifying the output. + if $GREP -v "^: " < "$nlist" | + if sort -k 3 /dev/null 2>&1; then + sort -k 3 + else + sort +2 + fi | + uniq > "$nlist"S; then + : + else + $GREP -v "^: " < "$nlist" > "$nlist"S + fi + + if test -f "$nlist"S; then + eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$my_dlsyms"' + else + echo '/* NONE */' >> "$output_objdir/$my_dlsyms" + fi + + func_show_eval '$RM "${nlist}I"' + if test -n "$global_symbol_to_import"; then + eval "$global_symbol_to_import"' < "$nlist"S > "$nlist"I' + fi + + echo >> "$output_objdir/$my_dlsyms" "\ + +/* The mapping between symbol names and symbols. */ +typedef struct { + const char *name; + void *address; +} lt_dlsymlist; +extern LT_DLSYM_CONST lt_dlsymlist +lt_${my_prefix}_LTX_preloaded_symbols[];\ +" + + if test -s "$nlist"I; then + echo >> "$output_objdir/$my_dlsyms" "\ +static void lt_syminit(void) +{ + LT_DLSYM_CONST lt_dlsymlist *symbol = lt_${my_prefix}_LTX_preloaded_symbols; + for (; symbol->name; ++symbol) + {" + $SED 's/.*/ if (STREQ (symbol->name, \"&\")) symbol->address = (void *) \&&;/' < "$nlist"I >> "$output_objdir/$my_dlsyms" + echo >> "$output_objdir/$my_dlsyms" "\ + } +}" + fi + echo >> "$output_objdir/$my_dlsyms" "\ +LT_DLSYM_CONST lt_dlsymlist +lt_${my_prefix}_LTX_preloaded_symbols[] = +{ {\"$my_originator\", (void *) 0}," + + if test -s "$nlist"I; then + echo >> "$output_objdir/$my_dlsyms" "\ + {\"@INIT@\", (void *) <_syminit}," + fi + + case $need_lib_prefix in + no) + eval "$global_symbol_to_c_name_address" < "$nlist" >> "$output_objdir/$my_dlsyms" + ;; + *) + eval "$global_symbol_to_c_name_address_lib_prefix" < "$nlist" >> "$output_objdir/$my_dlsyms" + ;; + esac + echo >> "$output_objdir/$my_dlsyms" "\ + {0, (void *) 0} +}; + +/* This works around a problem in FreeBSD linker */ +#ifdef FREEBSD_WORKAROUND +static const void *lt_preloaded_setup() { + return lt_${my_prefix}_LTX_preloaded_symbols; +} +#endif + +#ifdef __cplusplus +} +#endif\ +" + } # !$opt_dry_run + + pic_flag_for_symtable= + case "$compile_command " in + *" -static "*) ;; + *) + case $host in + # compiling the symbol table file with pic_flag works around + # a FreeBSD bug that causes programs to crash when -lm is + # linked before any other PIC object. But we must not use + # pic_flag when linking with -static. The problem exists in + # FreeBSD 2.2.6 and is fixed in FreeBSD 3.1. + *-*-freebsd2.*|*-*-freebsd3.0*|*-*-freebsdelf3.0*) + pic_flag_for_symtable=" $pic_flag -DFREEBSD_WORKAROUND" ;; + *-*-hpux*) + pic_flag_for_symtable=" $pic_flag" ;; + *) + $my_pic_p && pic_flag_for_symtable=" $pic_flag" + ;; + esac + ;; + esac + symtab_cflags= + for arg in $LTCFLAGS; do + case $arg in + -pie | -fpie | -fPIE) ;; + *) func_append symtab_cflags " $arg" ;; + esac + done + + # Now compile the dynamic symbol file. + func_show_eval '(cd $output_objdir && $LTCC$symtab_cflags -c$no_builtin_flag$pic_flag_for_symtable "$my_dlsyms")' 'exit $?' + + # Clean up the generated files. + func_show_eval '$RM "$output_objdir/$my_dlsyms" "$nlist" "${nlist}S" "${nlist}T" "${nlist}I"' + + # Transform the symbol file into the correct name. + symfileobj=$output_objdir/${my_outputname}S.$objext + case $host in + *cygwin* | *mingw* | *cegcc* ) + if test -f "$output_objdir/$my_outputname.def"; then + compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` + finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` + else + compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` + finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` + fi + ;; + *) + compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` + finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` + ;; + esac + ;; + *) + func_fatal_error "unknown suffix for '$my_dlsyms'" + ;; + esac + else + # We keep going just in case the user didn't refer to + # lt_preloaded_symbols. The linker will fail if global_symbol_pipe + # really was required. + + # Nullify the symbol file. + compile_command=`$ECHO "$compile_command" | $SED "s% @SYMFILE@%%"` + finalize_command=`$ECHO "$finalize_command" | $SED "s% @SYMFILE@%%"` + fi +} + +# func_cygming_gnu_implib_p ARG +# This predicate returns with zero status (TRUE) if +# ARG is a GNU/binutils-style import library. Returns +# with nonzero status (FALSE) otherwise. +func_cygming_gnu_implib_p () +{ + $debug_cmd + + func_to_tool_file "$1" func_convert_file_msys_to_w32 + func_cygming_gnu_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $EGREP ' (_head_[A-Za-z0-9_]+_[ad]l*|[A-Za-z0-9_]+_[ad]l*_iname)$'` + test -n "$func_cygming_gnu_implib_tmp" +} + +# func_cygming_ms_implib_p ARG +# This predicate returns with zero status (TRUE) if +# ARG is an MS-style import library. Returns +# with nonzero status (FALSE) otherwise. +func_cygming_ms_implib_p () +{ + $debug_cmd + + func_to_tool_file "$1" func_convert_file_msys_to_w32 + func_cygming_ms_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $GREP '_NULL_IMPORT_DESCRIPTOR'` + test -n "$func_cygming_ms_implib_tmp" +} + +# func_win32_libid arg +# return the library type of file 'arg' +# +# Need a lot of goo to handle *both* DLLs and import libs +# Has to be a shell function in order to 'eat' the argument +# that is supplied when $file_magic_command is called. +# Despite the name, also deal with 64 bit binaries. +func_win32_libid () +{ + $debug_cmd + + win32_libid_type=unknown + win32_fileres=`file -L $1 2>/dev/null` + case $win32_fileres in + *ar\ archive\ import\ library*) # definitely import + win32_libid_type="x86 archive import" + ;; + *ar\ archive*) # could be an import, or static + # Keep the egrep pattern in sync with the one in _LT_CHECK_MAGIC_METHOD. + if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | + $EGREP 'file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' >/dev/null; then + case $nm_interface in + "MS dumpbin") + if func_cygming_ms_implib_p "$1" || + func_cygming_gnu_implib_p "$1" + then + win32_nmres=import + else + win32_nmres= + fi + ;; + *) + func_to_tool_file "$1" func_convert_file_msys_to_w32 + win32_nmres=`eval $NM -f posix -A \"$func_to_tool_file_result\" | + $SED -n -e ' + 1,100{ + / I /{ + s|.*|import| + p + q + } + }'` + ;; + esac + case $win32_nmres in + import*) win32_libid_type="x86 archive import";; + *) win32_libid_type="x86 archive static";; + esac + fi + ;; + *DLL*) + win32_libid_type="x86 DLL" + ;; + *executable*) # but shell scripts are "executable" too... + case $win32_fileres in + *MS\ Windows\ PE\ Intel*) + win32_libid_type="x86 DLL" + ;; + esac + ;; + esac + $ECHO "$win32_libid_type" +} + +# func_cygming_dll_for_implib ARG +# +# Platform-specific function to extract the +# name of the DLL associated with the specified +# import library ARG. +# Invoked by eval'ing the libtool variable +# $sharedlib_from_linklib_cmd +# Result is available in the variable +# $sharedlib_from_linklib_result +func_cygming_dll_for_implib () +{ + $debug_cmd + + sharedlib_from_linklib_result=`$DLLTOOL --identify-strict --identify "$1"` +} + +# func_cygming_dll_for_implib_fallback_core SECTION_NAME LIBNAMEs +# +# The is the core of a fallback implementation of a +# platform-specific function to extract the name of the +# DLL associated with the specified import library LIBNAME. +# +# SECTION_NAME is either .idata$6 or .idata$7, depending +# on the platform and compiler that created the implib. +# +# Echos the name of the DLL associated with the +# specified import library. +func_cygming_dll_for_implib_fallback_core () +{ + $debug_cmd + + match_literal=`$ECHO "$1" | $SED "$sed_make_literal_regex"` + $OBJDUMP -s --section "$1" "$2" 2>/dev/null | + $SED '/^Contents of section '"$match_literal"':/{ + # Place marker at beginning of archive member dllname section + s/.*/====MARK====/ + p + d + } + # These lines can sometimes be longer than 43 characters, but + # are always uninteresting + /:[ ]*file format pe[i]\{,1\}-/d + /^In archive [^:]*:/d + # Ensure marker is printed + /^====MARK====/p + # Remove all lines with less than 43 characters + /^.\{43\}/!d + # From remaining lines, remove first 43 characters + s/^.\{43\}//' | + $SED -n ' + # Join marker and all lines until next marker into a single line + /^====MARK====/ b para + H + $ b para + b + :para + x + s/\n//g + # Remove the marker + s/^====MARK====// + # Remove trailing dots and whitespace + s/[\. \t]*$// + # Print + /./p' | + # we now have a list, one entry per line, of the stringified + # contents of the appropriate section of all members of the + # archive that possess that section. Heuristic: eliminate + # all those that have a first or second character that is + # a '.' (that is, objdump's representation of an unprintable + # character.) This should work for all archives with less than + # 0x302f exports -- but will fail for DLLs whose name actually + # begins with a literal '.' or a single character followed by + # a '.'. + # + # Of those that remain, print the first one. + $SED -e '/^\./d;/^.\./d;q' +} + +# func_cygming_dll_for_implib_fallback ARG +# Platform-specific function to extract the +# name of the DLL associated with the specified +# import library ARG. +# +# This fallback implementation is for use when $DLLTOOL +# does not support the --identify-strict option. +# Invoked by eval'ing the libtool variable +# $sharedlib_from_linklib_cmd +# Result is available in the variable +# $sharedlib_from_linklib_result +func_cygming_dll_for_implib_fallback () +{ + $debug_cmd + + if func_cygming_gnu_implib_p "$1"; then + # binutils import library + sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$7' "$1"` + elif func_cygming_ms_implib_p "$1"; then + # ms-generated import library + sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$6' "$1"` + else + # unknown + sharedlib_from_linklib_result= + fi +} + + +# func_extract_an_archive dir oldlib +func_extract_an_archive () +{ + $debug_cmd + + f_ex_an_ar_dir=$1; shift + f_ex_an_ar_oldlib=$1 + if test yes = "$lock_old_archive_extraction"; then + lockfile=$f_ex_an_ar_oldlib.lock + until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do + func_echo "Waiting for $lockfile to be removed" + sleep 2 + done + fi + func_show_eval "(cd \$f_ex_an_ar_dir && $AR x \"\$f_ex_an_ar_oldlib\")" \ + 'stat=$?; rm -f "$lockfile"; exit $stat' + if test yes = "$lock_old_archive_extraction"; then + $opt_dry_run || rm -f "$lockfile" + fi + if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then + : + else + func_fatal_error "object name conflicts in archive: $f_ex_an_ar_dir/$f_ex_an_ar_oldlib" + fi +} + + +# func_extract_archives gentop oldlib ... +func_extract_archives () +{ + $debug_cmd + + my_gentop=$1; shift + my_oldlibs=${1+"$@"} + my_oldobjs= + my_xlib= + my_xabs= + my_xdir= + + for my_xlib in $my_oldlibs; do + # Extract the objects. + case $my_xlib in + [\\/]* | [A-Za-z]:[\\/]*) my_xabs=$my_xlib ;; + *) my_xabs=`pwd`"/$my_xlib" ;; + esac + func_basename "$my_xlib" + my_xlib=$func_basename_result + my_xlib_u=$my_xlib + while :; do + case " $extracted_archives " in + *" $my_xlib_u "*) + func_arith $extracted_serial + 1 + extracted_serial=$func_arith_result + my_xlib_u=lt$extracted_serial-$my_xlib ;; + *) break ;; + esac + done + extracted_archives="$extracted_archives $my_xlib_u" + my_xdir=$my_gentop/$my_xlib_u + + func_mkdir_p "$my_xdir" + + case $host in + *-darwin*) + func_verbose "Extracting $my_xabs" + # Do not bother doing anything if just a dry run + $opt_dry_run || { + darwin_orig_dir=`pwd` + cd $my_xdir || exit $? + darwin_archive=$my_xabs + darwin_curdir=`pwd` + func_basename "$darwin_archive" + darwin_base_archive=$func_basename_result + darwin_arches=`$LIPO -info "$darwin_archive" 2>/dev/null | $GREP Architectures 2>/dev/null || true` + if test -n "$darwin_arches"; then + darwin_arches=`$ECHO "$darwin_arches" | $SED -e 's/.*are://'` + darwin_arch= + func_verbose "$darwin_base_archive has multiple architectures $darwin_arches" + for darwin_arch in $darwin_arches; do + func_mkdir_p "unfat-$$/$darwin_base_archive-$darwin_arch" + $LIPO -thin $darwin_arch -output "unfat-$$/$darwin_base_archive-$darwin_arch/$darwin_base_archive" "$darwin_archive" + cd "unfat-$$/$darwin_base_archive-$darwin_arch" + func_extract_an_archive "`pwd`" "$darwin_base_archive" + cd "$darwin_curdir" + $RM "unfat-$$/$darwin_base_archive-$darwin_arch/$darwin_base_archive" + done # $darwin_arches + ## Okay now we've a bunch of thin objects, gotta fatten them up :) + darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print | $SED -e "$sed_basename" | sort -u` + darwin_file= + darwin_files= + for darwin_file in $darwin_filelist; do + darwin_files=`find unfat-$$ -name $darwin_file -print | sort | $NL2SP` + $LIPO -create -output "$darwin_file" $darwin_files + done # $darwin_filelist + $RM -rf unfat-$$ + cd "$darwin_orig_dir" + else + cd $darwin_orig_dir + func_extract_an_archive "$my_xdir" "$my_xabs" + fi # $darwin_arches + } # !$opt_dry_run + ;; + *) + func_extract_an_archive "$my_xdir" "$my_xabs" + ;; + esac + my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | sort | $NL2SP` + done + + func_extract_archives_result=$my_oldobjs +} + + +# func_emit_wrapper [arg=no] +# +# Emit a libtool wrapper script on stdout. +# Don't directly open a file because we may want to +# incorporate the script contents within a cygwin/mingw +# wrapper executable. Must ONLY be called from within +# func_mode_link because it depends on a number of variables +# set therein. +# +# ARG is the value that the WRAPPER_SCRIPT_BELONGS_IN_OBJDIR +# variable will take. If 'yes', then the emitted script +# will assume that the directory where it is stored is +# the $objdir directory. This is a cygwin/mingw-specific +# behavior. +func_emit_wrapper () +{ + func_emit_wrapper_arg1=${1-no} + + $ECHO "\ +#! $SHELL + +# $output - temporary wrapper script for $objdir/$outputname +# Generated by $PROGRAM (GNU $PACKAGE) $VERSION +# +# The $output program cannot be directly executed until all the libtool +# libraries that it depends on are installed. +# +# This wrapper script should never be moved out of the build directory. +# If it is, it will not operate correctly. + +# Sed substitution that helps us do robust quoting. It backslashifies +# metacharacters that are still active within double-quoted strings. +sed_quote_subst='$sed_quote_subst' + +# Be Bourne compatible +if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then + emulate sh + NULLCMD=: + # Zsh 3.x and 4.x performs word splitting on \${1+\"\$@\"}, which + # is contrary to our usage. Disable this feature. + alias -g '\${1+\"\$@\"}'='\"\$@\"' + setopt NO_GLOB_SUBST +else + case \`(set -o) 2>/dev/null\` in *posix*) set -o posix;; esac +fi +BIN_SH=xpg4; export BIN_SH # for Tru64 +DUALCASE=1; export DUALCASE # for MKS sh + +# The HP-UX ksh and POSIX shell print the target directory to stdout +# if CDPATH is set. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + +relink_command=\"$relink_command\" + +# This environment variable determines our operation mode. +if test \"\$libtool_install_magic\" = \"$magic\"; then + # install mode needs the following variables: + generated_by_libtool_version='$macro_version' + notinst_deplibs='$notinst_deplibs' +else + # When we are sourced in execute mode, \$file and \$ECHO are already set. + if test \"\$libtool_execute_magic\" != \"$magic\"; then + file=\"\$0\"" + + qECHO=`$ECHO "$ECHO" | $SED "$sed_quote_subst"` + $ECHO "\ + +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +\$1 +_LTECHO_EOF' +} + ECHO=\"$qECHO\" + fi + +# Very basic option parsing. These options are (a) specific to +# the libtool wrapper, (b) are identical between the wrapper +# /script/ and the wrapper /executable/ that is used only on +# windows platforms, and (c) all begin with the string "--lt-" +# (application programs are unlikely to have options that match +# this pattern). +# +# There are only two supported options: --lt-debug and +# --lt-dump-script. There is, deliberately, no --lt-help. +# +# The first argument to this parsing function should be the +# script's $0 value, followed by "$@". +lt_option_debug= +func_parse_lt_options () +{ + lt_script_arg0=\$0 + shift + for lt_opt + do + case \"\$lt_opt\" in + --lt-debug) lt_option_debug=1 ;; + --lt-dump-script) + lt_dump_D=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%/[^/]*$%%'\` + test \"X\$lt_dump_D\" = \"X\$lt_script_arg0\" && lt_dump_D=. + lt_dump_F=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%^.*/%%'\` + cat \"\$lt_dump_D/\$lt_dump_F\" + exit 0 + ;; + --lt-*) + \$ECHO \"Unrecognized --lt- option: '\$lt_opt'\" 1>&2 + exit 1 + ;; + esac + done + + # Print the debug banner immediately: + if test -n \"\$lt_option_debug\"; then + echo \"$outputname:$output:\$LINENO: libtool wrapper (GNU $PACKAGE) $VERSION\" 1>&2 + fi +} + +# Used when --lt-debug. Prints its arguments to stdout +# (redirection is the responsibility of the caller) +func_lt_dump_args () +{ + lt_dump_args_N=1; + for lt_arg + do + \$ECHO \"$outputname:$output:\$LINENO: newargv[\$lt_dump_args_N]: \$lt_arg\" + lt_dump_args_N=\`expr \$lt_dump_args_N + 1\` + done +} + +# Core function for launching the target application +func_exec_program_core () +{ +" + case $host in + # Backslashes separate directories on plain windows + *-*-mingw | *-*-os2* | *-cegcc*) + $ECHO "\ + if test -n \"\$lt_option_debug\"; then + \$ECHO \"$outputname:$output:\$LINENO: newargv[0]: \$progdir\\\\\$program\" 1>&2 + func_lt_dump_args \${1+\"\$@\"} 1>&2 + fi + exec \"\$progdir\\\\\$program\" \${1+\"\$@\"} +" + ;; + + *) + $ECHO "\ + if test -n \"\$lt_option_debug\"; then + \$ECHO \"$outputname:$output:\$LINENO: newargv[0]: \$progdir/\$program\" 1>&2 + func_lt_dump_args \${1+\"\$@\"} 1>&2 + fi + exec \"\$progdir/\$program\" \${1+\"\$@\"} +" + ;; + esac + $ECHO "\ + \$ECHO \"\$0: cannot exec \$program \$*\" 1>&2 + exit 1 +} + +# A function to encapsulate launching the target application +# Strips options in the --lt-* namespace from \$@ and +# launches target application with the remaining arguments. +func_exec_program () +{ + case \" \$* \" in + *\\ --lt-*) + for lt_wr_arg + do + case \$lt_wr_arg in + --lt-*) ;; + *) set x \"\$@\" \"\$lt_wr_arg\"; shift;; + esac + shift + done ;; + esac + func_exec_program_core \${1+\"\$@\"} +} + + # Parse options + func_parse_lt_options \"\$0\" \${1+\"\$@\"} + + # Find the directory that this script lives in. + thisdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*$%%'\` + test \"x\$thisdir\" = \"x\$file\" && thisdir=. + + # Follow symbolic links until we get to the real thisdir. + file=\`ls -ld \"\$file\" | $SED -n 's/.*-> //p'\` + while test -n \"\$file\"; do + destdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*\$%%'\` + + # If there was a directory component, then change thisdir. + if test \"x\$destdir\" != \"x\$file\"; then + case \"\$destdir\" in + [\\\\/]* | [A-Za-z]:[\\\\/]*) thisdir=\"\$destdir\" ;; + *) thisdir=\"\$thisdir/\$destdir\" ;; + esac + fi + + file=\`\$ECHO \"\$file\" | $SED 's%^.*/%%'\` + file=\`ls -ld \"\$thisdir/\$file\" | $SED -n 's/.*-> //p'\` + done + + # Usually 'no', except on cygwin/mingw when embedded into + # the cwrapper. + WRAPPER_SCRIPT_BELONGS_IN_OBJDIR=$func_emit_wrapper_arg1 + if test \"\$WRAPPER_SCRIPT_BELONGS_IN_OBJDIR\" = \"yes\"; then + # special case for '.' + if test \"\$thisdir\" = \".\"; then + thisdir=\`pwd\` + fi + # remove .libs from thisdir + case \"\$thisdir\" in + *[\\\\/]$objdir ) thisdir=\`\$ECHO \"\$thisdir\" | $SED 's%[\\\\/][^\\\\/]*$%%'\` ;; + $objdir ) thisdir=. ;; + esac + fi + + # Try to get the absolute directory name. + absdir=\`cd \"\$thisdir\" && pwd\` + test -n \"\$absdir\" && thisdir=\"\$absdir\" +" + + if test yes = "$fast_install"; then + $ECHO "\ + program=lt-'$outputname'$exeext + progdir=\"\$thisdir/$objdir\" + + if test ! -f \"\$progdir/\$program\" || + { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | $SED 1q\`; \\ + test \"X\$file\" != \"X\$progdir/\$program\"; }; then + + file=\"\$\$-\$program\" + + if test ! -d \"\$progdir\"; then + $MKDIR \"\$progdir\" + else + $RM \"\$progdir/\$file\" + fi" + + $ECHO "\ + + # relink executable if necessary + if test -n \"\$relink_command\"; then + if relink_command_output=\`eval \$relink_command 2>&1\`; then : + else + \$ECHO \"\$relink_command_output\" >&2 + $RM \"\$progdir/\$file\" + exit 1 + fi + fi + + $MV \"\$progdir/\$file\" \"\$progdir/\$program\" 2>/dev/null || + { $RM \"\$progdir/\$program\"; + $MV \"\$progdir/\$file\" \"\$progdir/\$program\"; } + $RM \"\$progdir/\$file\" + fi" + else + $ECHO "\ + program='$outputname' + progdir=\"\$thisdir/$objdir\" +" + fi + + $ECHO "\ + + if test -f \"\$progdir/\$program\"; then" + + # fixup the dll searchpath if we need to. + # + # Fix the DLL searchpath if we need to. Do this before prepending + # to shlibpath, because on Windows, both are PATH and uninstalled + # libraries must come first. + if test -n "$dllsearchpath"; then + $ECHO "\ + # Add the dll search path components to the executable PATH + PATH=$dllsearchpath:\$PATH +" + fi + + # Export our shlibpath_var if we have one. + if test yes = "$shlibpath_overrides_runpath" && test -n "$shlibpath_var" && test -n "$temp_rpath"; then + $ECHO "\ + # Add our own library path to $shlibpath_var + $shlibpath_var=\"$temp_rpath\$$shlibpath_var\" + + # Some systems cannot cope with colon-terminated $shlibpath_var + # The second colon is a workaround for a bug in BeOS R4 sed + $shlibpath_var=\`\$ECHO \"\$$shlibpath_var\" | $SED 's/::*\$//'\` + + export $shlibpath_var +" + fi + + $ECHO "\ + if test \"\$libtool_execute_magic\" != \"$magic\"; then + # Run the actual program with our arguments. + func_exec_program \${1+\"\$@\"} + fi + else + # The program doesn't exist. + \$ECHO \"\$0: error: '\$progdir/\$program' does not exist\" 1>&2 + \$ECHO \"This script is just a wrapper for \$program.\" 1>&2 + \$ECHO \"See the $PACKAGE documentation for more information.\" 1>&2 + exit 1 + fi +fi\ +" +} + + +# func_emit_cwrapperexe_src +# emit the source code for a wrapper executable on stdout +# Must ONLY be called from within func_mode_link because +# it depends on a number of variable set therein. +func_emit_cwrapperexe_src () +{ + cat < +#include +#ifdef _MSC_VER +# include +# include +# include +#else +# include +# include +# ifdef __CYGWIN__ +# include +# endif +#endif +#include +#include +#include +#include +#include +#include +#include +#include + +#define STREQ(s1, s2) (strcmp ((s1), (s2)) == 0) + +/* declarations of non-ANSI functions */ +#if defined __MINGW32__ +# ifdef __STRICT_ANSI__ +int _putenv (const char *); +# endif +#elif defined __CYGWIN__ +# ifdef __STRICT_ANSI__ +char *realpath (const char *, char *); +int putenv (char *); +int setenv (const char *, const char *, int); +# endif +/* #elif defined other_platform || defined ... */ +#endif + +/* portability defines, excluding path handling macros */ +#if defined _MSC_VER +# define setmode _setmode +# define stat _stat +# define chmod _chmod +# define getcwd _getcwd +# define putenv _putenv +# define S_IXUSR _S_IEXEC +#elif defined __MINGW32__ +# define setmode _setmode +# define stat _stat +# define chmod _chmod +# define getcwd _getcwd +# define putenv _putenv +#elif defined __CYGWIN__ +# define HAVE_SETENV +# define FOPEN_WB "wb" +/* #elif defined other platforms ... */ +#endif + +#if defined PATH_MAX +# define LT_PATHMAX PATH_MAX +#elif defined MAXPATHLEN +# define LT_PATHMAX MAXPATHLEN +#else +# define LT_PATHMAX 1024 +#endif + +#ifndef S_IXOTH +# define S_IXOTH 0 +#endif +#ifndef S_IXGRP +# define S_IXGRP 0 +#endif + +/* path handling portability macros */ +#ifndef DIR_SEPARATOR +# define DIR_SEPARATOR '/' +# define PATH_SEPARATOR ':' +#endif + +#if defined _WIN32 || defined __MSDOS__ || defined __DJGPP__ || \ + defined __OS2__ +# define HAVE_DOS_BASED_FILE_SYSTEM +# define FOPEN_WB "wb" +# ifndef DIR_SEPARATOR_2 +# define DIR_SEPARATOR_2 '\\' +# endif +# ifndef PATH_SEPARATOR_2 +# define PATH_SEPARATOR_2 ';' +# endif +#endif + +#ifndef DIR_SEPARATOR_2 +# define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR) +#else /* DIR_SEPARATOR_2 */ +# define IS_DIR_SEPARATOR(ch) \ + (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2)) +#endif /* DIR_SEPARATOR_2 */ + +#ifndef PATH_SEPARATOR_2 +# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR) +#else /* PATH_SEPARATOR_2 */ +# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2) +#endif /* PATH_SEPARATOR_2 */ + +#ifndef FOPEN_WB +# define FOPEN_WB "w" +#endif +#ifndef _O_BINARY +# define _O_BINARY 0 +#endif + +#define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type))) +#define XFREE(stale) do { \ + if (stale) { free (stale); stale = 0; } \ +} while (0) + +#if defined LT_DEBUGWRAPPER +static int lt_debug = 1; +#else +static int lt_debug = 0; +#endif + +const char *program_name = "libtool-wrapper"; /* in case xstrdup fails */ + +void *xmalloc (size_t num); +char *xstrdup (const char *string); +const char *base_name (const char *name); +char *find_executable (const char *wrapper); +char *chase_symlinks (const char *pathspec); +int make_executable (const char *path); +int check_executable (const char *path); +char *strendzap (char *str, const char *pat); +void lt_debugprintf (const char *file, int line, const char *fmt, ...); +void lt_fatal (const char *file, int line, const char *message, ...); +static const char *nonnull (const char *s); +static const char *nonempty (const char *s); +void lt_setenv (const char *name, const char *value); +char *lt_extend_str (const char *orig_value, const char *add, int to_end); +void lt_update_exe_path (const char *name, const char *value); +void lt_update_lib_path (const char *name, const char *value); +char **prepare_spawn (char **argv); +void lt_dump_script (FILE *f); +EOF + + cat <= 0) + && (st.st_mode & (S_IXUSR | S_IXGRP | S_IXOTH))) + return 1; + else + return 0; +} + +int +make_executable (const char *path) +{ + int rval = 0; + struct stat st; + + lt_debugprintf (__FILE__, __LINE__, "(make_executable): %s\n", + nonempty (path)); + if ((!path) || (!*path)) + return 0; + + if (stat (path, &st) >= 0) + { + rval = chmod (path, st.st_mode | S_IXOTH | S_IXGRP | S_IXUSR); + } + return rval; +} + +/* Searches for the full path of the wrapper. Returns + newly allocated full path name if found, NULL otherwise + Does not chase symlinks, even on platforms that support them. +*/ +char * +find_executable (const char *wrapper) +{ + int has_slash = 0; + const char *p; + const char *p_next; + /* static buffer for getcwd */ + char tmp[LT_PATHMAX + 1]; + size_t tmp_len; + char *concat_name; + + lt_debugprintf (__FILE__, __LINE__, "(find_executable): %s\n", + nonempty (wrapper)); + + if ((wrapper == NULL) || (*wrapper == '\0')) + return NULL; + + /* Absolute path? */ +#if defined HAVE_DOS_BASED_FILE_SYSTEM + if (isalpha ((unsigned char) wrapper[0]) && wrapper[1] == ':') + { + concat_name = xstrdup (wrapper); + if (check_executable (concat_name)) + return concat_name; + XFREE (concat_name); + } + else + { +#endif + if (IS_DIR_SEPARATOR (wrapper[0])) + { + concat_name = xstrdup (wrapper); + if (check_executable (concat_name)) + return concat_name; + XFREE (concat_name); + } +#if defined HAVE_DOS_BASED_FILE_SYSTEM + } +#endif + + for (p = wrapper; *p; p++) + if (*p == '/') + { + has_slash = 1; + break; + } + if (!has_slash) + { + /* no slashes; search PATH */ + const char *path = getenv ("PATH"); + if (path != NULL) + { + for (p = path; *p; p = p_next) + { + const char *q; + size_t p_len; + for (q = p; *q; q++) + if (IS_PATH_SEPARATOR (*q)) + break; + p_len = (size_t) (q - p); + p_next = (*q == '\0' ? q : q + 1); + if (p_len == 0) + { + /* empty path: current directory */ + if (getcwd (tmp, LT_PATHMAX) == NULL) + lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", + nonnull (strerror (errno))); + tmp_len = strlen (tmp); + concat_name = + XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); + memcpy (concat_name, tmp, tmp_len); + concat_name[tmp_len] = '/'; + strcpy (concat_name + tmp_len + 1, wrapper); + } + else + { + concat_name = + XMALLOC (char, p_len + 1 + strlen (wrapper) + 1); + memcpy (concat_name, p, p_len); + concat_name[p_len] = '/'; + strcpy (concat_name + p_len + 1, wrapper); + } + if (check_executable (concat_name)) + return concat_name; + XFREE (concat_name); + } + } + /* not found in PATH; assume curdir */ + } + /* Relative path | not found in path: prepend cwd */ + if (getcwd (tmp, LT_PATHMAX) == NULL) + lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", + nonnull (strerror (errno))); + tmp_len = strlen (tmp); + concat_name = XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); + memcpy (concat_name, tmp, tmp_len); + concat_name[tmp_len] = '/'; + strcpy (concat_name + tmp_len + 1, wrapper); + + if (check_executable (concat_name)) + return concat_name; + XFREE (concat_name); + return NULL; +} + +char * +chase_symlinks (const char *pathspec) +{ +#ifndef S_ISLNK + return xstrdup (pathspec); +#else + char buf[LT_PATHMAX]; + struct stat s; + char *tmp_pathspec = xstrdup (pathspec); + char *p; + int has_symlinks = 0; + while (strlen (tmp_pathspec) && !has_symlinks) + { + lt_debugprintf (__FILE__, __LINE__, + "checking path component for symlinks: %s\n", + tmp_pathspec); + if (lstat (tmp_pathspec, &s) == 0) + { + if (S_ISLNK (s.st_mode) != 0) + { + has_symlinks = 1; + break; + } + + /* search backwards for last DIR_SEPARATOR */ + p = tmp_pathspec + strlen (tmp_pathspec) - 1; + while ((p > tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) + p--; + if ((p == tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) + { + /* no more DIR_SEPARATORS left */ + break; + } + *p = '\0'; + } + else + { + lt_fatal (__FILE__, __LINE__, + "error accessing file \"%s\": %s", + tmp_pathspec, nonnull (strerror (errno))); + } + } + XFREE (tmp_pathspec); + + if (!has_symlinks) + { + return xstrdup (pathspec); + } + + tmp_pathspec = realpath (pathspec, buf); + if (tmp_pathspec == 0) + { + lt_fatal (__FILE__, __LINE__, + "could not follow symlinks for %s", pathspec); + } + return xstrdup (tmp_pathspec); +#endif +} + +char * +strendzap (char *str, const char *pat) +{ + size_t len, patlen; + + assert (str != NULL); + assert (pat != NULL); + + len = strlen (str); + patlen = strlen (pat); + + if (patlen <= len) + { + str += len - patlen; + if (STREQ (str, pat)) + *str = '\0'; + } + return str; +} + +void +lt_debugprintf (const char *file, int line, const char *fmt, ...) +{ + va_list args; + if (lt_debug) + { + (void) fprintf (stderr, "%s:%s:%d: ", program_name, file, line); + va_start (args, fmt); + (void) vfprintf (stderr, fmt, args); + va_end (args); + } +} + +static void +lt_error_core (int exit_status, const char *file, + int line, const char *mode, + const char *message, va_list ap) +{ + fprintf (stderr, "%s:%s:%d: %s: ", program_name, file, line, mode); + vfprintf (stderr, message, ap); + fprintf (stderr, ".\n"); + + if (exit_status >= 0) + exit (exit_status); +} + +void +lt_fatal (const char *file, int line, const char *message, ...) +{ + va_list ap; + va_start (ap, message); + lt_error_core (EXIT_FAILURE, file, line, "FATAL", message, ap); + va_end (ap); +} + +static const char * +nonnull (const char *s) +{ + return s ? s : "(null)"; +} + +static const char * +nonempty (const char *s) +{ + return (s && !*s) ? "(empty)" : nonnull (s); +} + +void +lt_setenv (const char *name, const char *value) +{ + lt_debugprintf (__FILE__, __LINE__, + "(lt_setenv) setting '%s' to '%s'\n", + nonnull (name), nonnull (value)); + { +#ifdef HAVE_SETENV + /* always make a copy, for consistency with !HAVE_SETENV */ + char *str = xstrdup (value); + setenv (name, str, 1); +#else + size_t len = strlen (name) + 1 + strlen (value) + 1; + char *str = XMALLOC (char, len); + sprintf (str, "%s=%s", name, value); + if (putenv (str) != EXIT_SUCCESS) + { + XFREE (str); + } +#endif + } +} + +char * +lt_extend_str (const char *orig_value, const char *add, int to_end) +{ + char *new_value; + if (orig_value && *orig_value) + { + size_t orig_value_len = strlen (orig_value); + size_t add_len = strlen (add); + new_value = XMALLOC (char, add_len + orig_value_len + 1); + if (to_end) + { + strcpy (new_value, orig_value); + strcpy (new_value + orig_value_len, add); + } + else + { + strcpy (new_value, add); + strcpy (new_value + add_len, orig_value); + } + } + else + { + new_value = xstrdup (add); + } + return new_value; +} + +void +lt_update_exe_path (const char *name, const char *value) +{ + lt_debugprintf (__FILE__, __LINE__, + "(lt_update_exe_path) modifying '%s' by prepending '%s'\n", + nonnull (name), nonnull (value)); + + if (name && *name && value && *value) + { + char *new_value = lt_extend_str (getenv (name), value, 0); + /* some systems can't cope with a ':'-terminated path #' */ + size_t len = strlen (new_value); + while ((len > 0) && IS_PATH_SEPARATOR (new_value[len-1])) + { + new_value[--len] = '\0'; + } + lt_setenv (name, new_value); + XFREE (new_value); + } +} + +void +lt_update_lib_path (const char *name, const char *value) +{ + lt_debugprintf (__FILE__, __LINE__, + "(lt_update_lib_path) modifying '%s' by prepending '%s'\n", + nonnull (name), nonnull (value)); + + if (name && *name && value && *value) + { + char *new_value = lt_extend_str (getenv (name), value, 0); + lt_setenv (name, new_value); + XFREE (new_value); + } +} + +EOF + case $host_os in + mingw*) + cat <<"EOF" + +/* Prepares an argument vector before calling spawn(). + Note that spawn() does not by itself call the command interpreter + (getenv ("COMSPEC") != NULL ? getenv ("COMSPEC") : + ({ OSVERSIONINFO v; v.dwOSVersionInfoSize = sizeof(OSVERSIONINFO); + GetVersionEx(&v); + v.dwPlatformId == VER_PLATFORM_WIN32_NT; + }) ? "cmd.exe" : "command.com"). + Instead it simply concatenates the arguments, separated by ' ', and calls + CreateProcess(). We must quote the arguments since Win32 CreateProcess() + interprets characters like ' ', '\t', '\\', '"' (but not '<' and '>') in a + special way: + - Space and tab are interpreted as delimiters. They are not treated as + delimiters if they are surrounded by double quotes: "...". + - Unescaped double quotes are removed from the input. Their only effect is + that within double quotes, space and tab are treated like normal + characters. + - Backslashes not followed by double quotes are not special. + - But 2*n+1 backslashes followed by a double quote become + n backslashes followed by a double quote (n >= 0): + \" -> " + \\\" -> \" + \\\\\" -> \\" + */ +#define SHELL_SPECIAL_CHARS "\"\\ \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037" +#define SHELL_SPACE_CHARS " \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037" +char ** +prepare_spawn (char **argv) +{ + size_t argc; + char **new_argv; + size_t i; + + /* Count number of arguments. */ + for (argc = 0; argv[argc] != NULL; argc++) + ; + + /* Allocate new argument vector. */ + new_argv = XMALLOC (char *, argc + 1); + + /* Put quoted arguments into the new argument vector. */ + for (i = 0; i < argc; i++) + { + const char *string = argv[i]; + + if (string[0] == '\0') + new_argv[i] = xstrdup ("\"\""); + else if (strpbrk (string, SHELL_SPECIAL_CHARS) != NULL) + { + int quote_around = (strpbrk (string, SHELL_SPACE_CHARS) != NULL); + size_t length; + unsigned int backslashes; + const char *s; + char *quoted_string; + char *p; + + length = 0; + backslashes = 0; + if (quote_around) + length++; + for (s = string; *s != '\0'; s++) + { + char c = *s; + if (c == '"') + length += backslashes + 1; + length++; + if (c == '\\') + backslashes++; + else + backslashes = 0; + } + if (quote_around) + length += backslashes + 1; + + quoted_string = XMALLOC (char, length + 1); + + p = quoted_string; + backslashes = 0; + if (quote_around) + *p++ = '"'; + for (s = string; *s != '\0'; s++) + { + char c = *s; + if (c == '"') + { + unsigned int j; + for (j = backslashes + 1; j > 0; j--) + *p++ = '\\'; + } + *p++ = c; + if (c == '\\') + backslashes++; + else + backslashes = 0; + } + if (quote_around) + { + unsigned int j; + for (j = backslashes; j > 0; j--) + *p++ = '\\'; + *p++ = '"'; + } + *p = '\0'; + + new_argv[i] = quoted_string; + } + else + new_argv[i] = (char *) string; + } + new_argv[argc] = NULL; + + return new_argv; +} +EOF + ;; + esac + + cat <<"EOF" +void lt_dump_script (FILE* f) +{ +EOF + func_emit_wrapper yes | + $SED -n -e ' +s/^\(.\{79\}\)\(..*\)/\1\ +\2/ +h +s/\([\\"]\)/\\\1/g +s/$/\\n/ +s/\([^\n]*\).*/ fputs ("\1", f);/p +g +D' + cat <<"EOF" +} +EOF +} +# end: func_emit_cwrapperexe_src + +# func_win32_import_lib_p ARG +# True if ARG is an import lib, as indicated by $file_magic_cmd +func_win32_import_lib_p () +{ + $debug_cmd + + case `eval $file_magic_cmd \"\$1\" 2>/dev/null | $SED -e 10q` in + *import*) : ;; + *) false ;; + esac +} + +# func_suncc_cstd_abi +# !!ONLY CALL THIS FOR SUN CC AFTER $compile_command IS FULLY EXPANDED!! +# Several compiler flags select an ABI that is incompatible with the +# Cstd library. Avoid specifying it if any are in CXXFLAGS. +func_suncc_cstd_abi () +{ + $debug_cmd + + case " $compile_command " in + *" -compat=g "*|*\ -std=c++[0-9][0-9]\ *|*" -library=stdcxx4 "*|*" -library=stlport4 "*) + suncc_use_cstd_abi=no + ;; + *) + suncc_use_cstd_abi=yes + ;; + esac +} + +# func_mode_link arg... +func_mode_link () +{ + $debug_cmd + + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) + # It is impossible to link a dll without this setting, and + # we shouldn't force the makefile maintainer to figure out + # what system we are compiling for in order to pass an extra + # flag for every libtool invocation. + # allow_undefined=no + + # FIXME: Unfortunately, there are problems with the above when trying + # to make a dll that has undefined symbols, in which case not + # even a static library is built. For now, we need to specify + # -no-undefined on the libtool link line when we can be certain + # that all symbols are satisfied, otherwise we get a static library. + allow_undefined=yes + ;; + *) + allow_undefined=yes + ;; + esac + libtool_args=$nonopt + base_compile="$nonopt $@" + compile_command=$nonopt + finalize_command=$nonopt + + compile_rpath= + finalize_rpath= + compile_shlibpath= + finalize_shlibpath= + convenience= + old_convenience= + deplibs= + old_deplibs= + compiler_flags= + linker_flags= + dllsearchpath= + lib_search_path=`pwd` + inst_prefix_dir= + new_inherited_linker_flags= + + avoid_version=no + bindir= + dlfiles= + dlprefiles= + dlself=no + export_dynamic=no + export_symbols= + export_symbols_regex= + generated= + libobjs= + ltlibs= + module=no + no_install=no + objs= + os2dllname= + non_pic_objects= + precious_files_regex= + prefer_static_libs=no + preload=false + prev= + prevarg= + release= + rpath= + xrpath= + perm_rpath= + temp_rpath= + thread_safe=no + vinfo= + vinfo_number=no + weak_libs= + single_module=$wl-single_module + func_infer_tag $base_compile + + # We need to know -static, to get the right output filenames. + for arg + do + case $arg in + -shared) + test yes != "$build_libtool_libs" \ + && func_fatal_configuration "cannot build a shared library" + build_old_libs=no + break + ;; + -all-static | -static | -static-libtool-libs) + case $arg in + -all-static) + if test yes = "$build_libtool_libs" && test -z "$link_static_flag"; then + func_warning "complete static linking is impossible in this configuration" + fi + if test -n "$link_static_flag"; then + dlopen_self=$dlopen_self_static + fi + prefer_static_libs=yes + ;; + -static) + if test -z "$pic_flag" && test -n "$link_static_flag"; then + dlopen_self=$dlopen_self_static + fi + prefer_static_libs=built + ;; + -static-libtool-libs) + if test -z "$pic_flag" && test -n "$link_static_flag"; then + dlopen_self=$dlopen_self_static + fi + prefer_static_libs=yes + ;; + esac + build_libtool_libs=no + build_old_libs=yes + break + ;; + esac + done + + # See if our shared archives depend on static archives. + test -n "$old_archive_from_new_cmds" && build_old_libs=yes + + # Go through the arguments, transforming them on the way. + while test "$#" -gt 0; do + arg=$1 + shift + func_quote_for_eval "$arg" + qarg=$func_quote_for_eval_unquoted_result + func_append libtool_args " $func_quote_for_eval_result" + + # If the previous option needs an argument, assign it. + if test -n "$prev"; then + case $prev in + output) + func_append compile_command " @OUTPUT@" + func_append finalize_command " @OUTPUT@" + ;; + esac + + case $prev in + bindir) + bindir=$arg + prev= + continue + ;; + dlfiles|dlprefiles) + $preload || { + # Add the symbol object into the linking commands. + func_append compile_command " @SYMFILE@" + func_append finalize_command " @SYMFILE@" + preload=: + } + case $arg in + *.la | *.lo) ;; # We handle these cases below. + force) + if test no = "$dlself"; then + dlself=needless + export_dynamic=yes + fi + prev= + continue + ;; + self) + if test dlprefiles = "$prev"; then + dlself=yes + elif test dlfiles = "$prev" && test yes != "$dlopen_self"; then + dlself=yes + else + dlself=needless + export_dynamic=yes + fi + prev= + continue + ;; + *) + if test dlfiles = "$prev"; then + func_append dlfiles " $arg" + else + func_append dlprefiles " $arg" + fi + prev= + continue + ;; + esac + ;; + expsyms) + export_symbols=$arg + test -f "$arg" \ + || func_fatal_error "symbol file '$arg' does not exist" + prev= + continue + ;; + expsyms_regex) + export_symbols_regex=$arg + prev= + continue + ;; + framework) + case $host in + *-*-darwin*) + case "$deplibs " in + *" $qarg.ltframework "*) ;; + *) func_append deplibs " $qarg.ltframework" # this is fixed later + ;; + esac + ;; + esac + prev= + continue + ;; + inst_prefix) + inst_prefix_dir=$arg + prev= + continue + ;; + mllvm) + # Clang does not use LLVM to link, so we can simply discard any + # '-mllvm $arg' options when doing the link step. + prev= + continue + ;; + objectlist) + if test -f "$arg"; then + save_arg=$arg + moreargs= + for fil in `cat "$save_arg"` + do +# func_append moreargs " $fil" + arg=$fil + # A libtool-controlled object. + + # Check to see that this really is a libtool object. + if func_lalib_unsafe_p "$arg"; then + pic_object= + non_pic_object= + + # Read the .lo file + func_source "$arg" + + if test -z "$pic_object" || + test -z "$non_pic_object" || + test none = "$pic_object" && + test none = "$non_pic_object"; then + func_fatal_error "cannot find name of object for '$arg'" + fi + + # Extract subdirectory from the argument. + func_dirname "$arg" "/" "" + xdir=$func_dirname_result + + if test none != "$pic_object"; then + # Prepend the subdirectory the object is found in. + pic_object=$xdir$pic_object + + if test dlfiles = "$prev"; then + if test yes = "$build_libtool_libs" && test yes = "$dlopen_support"; then + func_append dlfiles " $pic_object" + prev= + continue + else + # If libtool objects are unsupported, then we need to preload. + prev=dlprefiles + fi + fi + + # CHECK ME: I think I busted this. -Ossama + if test dlprefiles = "$prev"; then + # Preload the old-style object. + func_append dlprefiles " $pic_object" + prev= + fi + + # A PIC object. + func_append libobjs " $pic_object" + arg=$pic_object + fi + + # Non-PIC object. + if test none != "$non_pic_object"; then + # Prepend the subdirectory the object is found in. + non_pic_object=$xdir$non_pic_object + + # A standard non-PIC object + func_append non_pic_objects " $non_pic_object" + if test -z "$pic_object" || test none = "$pic_object"; then + arg=$non_pic_object + fi + else + # If the PIC object exists, use it instead. + # $xdir was prepended to $pic_object above. + non_pic_object=$pic_object + func_append non_pic_objects " $non_pic_object" + fi + else + # Only an error if not doing a dry-run. + if $opt_dry_run; then + # Extract subdirectory from the argument. + func_dirname "$arg" "/" "" + xdir=$func_dirname_result + + func_lo2o "$arg" + pic_object=$xdir$objdir/$func_lo2o_result + non_pic_object=$xdir$func_lo2o_result + func_append libobjs " $pic_object" + func_append non_pic_objects " $non_pic_object" + else + func_fatal_error "'$arg' is not a valid libtool object" + fi + fi + done + else + func_fatal_error "link input file '$arg' does not exist" + fi + arg=$save_arg + prev= + continue + ;; + os2dllname) + os2dllname=$arg + prev= + continue + ;; + precious_regex) + precious_files_regex=$arg + prev= + continue + ;; + release) + release=-$arg + prev= + continue + ;; + rpath | xrpath) + # We need an absolute path. + case $arg in + [\\/]* | [A-Za-z]:[\\/]*) ;; + *) + func_fatal_error "only absolute run-paths are allowed" + ;; + esac + if test rpath = "$prev"; then + case "$rpath " in + *" $arg "*) ;; + *) func_append rpath " $arg" ;; + esac + else + case "$xrpath " in + *" $arg "*) ;; + *) func_append xrpath " $arg" ;; + esac + fi + prev= + continue + ;; + shrext) + shrext_cmds=$arg + prev= + continue + ;; + weak) + func_append weak_libs " $arg" + prev= + continue + ;; + xcclinker) + func_append linker_flags " $qarg" + func_append compiler_flags " $qarg" + prev= + func_append compile_command " $qarg" + func_append finalize_command " $qarg" + continue + ;; + xcompiler) + func_append compiler_flags " $qarg" + prev= + func_append compile_command " $qarg" + func_append finalize_command " $qarg" + continue + ;; + xlinker) + func_append linker_flags " $qarg" + func_append compiler_flags " $wl$qarg" + prev= + func_append compile_command " $wl$qarg" + func_append finalize_command " $wl$qarg" + continue + ;; + *) + eval "$prev=\"\$arg\"" + prev= + continue + ;; + esac + fi # test -n "$prev" + + prevarg=$arg + + case $arg in + -all-static) + if test -n "$link_static_flag"; then + # See comment for -static flag below, for more details. + func_append compile_command " $link_static_flag" + func_append finalize_command " $link_static_flag" + fi + continue + ;; + + -allow-undefined) + # FIXME: remove this flag sometime in the future. + func_fatal_error "'-allow-undefined' must not be used because it is the default" + ;; + + -avoid-version) + avoid_version=yes + continue + ;; + + -bindir) + prev=bindir + continue + ;; + + -dlopen) + prev=dlfiles + continue + ;; + + -dlpreopen) + prev=dlprefiles + continue + ;; + + -export-dynamic) + export_dynamic=yes + continue + ;; + + -export-symbols | -export-symbols-regex) + if test -n "$export_symbols" || test -n "$export_symbols_regex"; then + func_fatal_error "more than one -exported-symbols argument is not allowed" + fi + if test X-export-symbols = "X$arg"; then + prev=expsyms + else + prev=expsyms_regex + fi + continue + ;; + + -framework) + prev=framework + continue + ;; + + -inst-prefix-dir) + prev=inst_prefix + continue + ;; + + # The native IRIX linker understands -LANG:*, -LIST:* and -LNO:* + # so, if we see these flags be careful not to treat them like -L + -L[A-Z][A-Z]*:*) + case $with_gcc/$host in + no/*-*-irix* | /*-*-irix*) + func_append compile_command " $arg" + func_append finalize_command " $arg" + ;; + esac + continue + ;; + + -L*) + func_stripname "-L" '' "$arg" + if test -z "$func_stripname_result"; then + if test "$#" -gt 0; then + func_fatal_error "require no space between '-L' and '$1'" + else + func_fatal_error "need path for '-L' option" + fi + fi + func_resolve_sysroot "$func_stripname_result" + dir=$func_resolve_sysroot_result + # We need an absolute path. + case $dir in + [\\/]* | [A-Za-z]:[\\/]*) ;; + *) + absdir=`cd "$dir" && pwd` + test -z "$absdir" && \ + func_fatal_error "cannot determine absolute directory name of '$dir'" + dir=$absdir + ;; + esac + case "$deplibs " in + *" -L$dir "* | *" $arg "*) + # Will only happen for absolute or sysroot arguments + ;; + *) + # Preserve sysroot, but never include relative directories + case $dir in + [\\/]* | [A-Za-z]:[\\/]* | =*) func_append deplibs " $arg" ;; + *) func_append deplibs " -L$dir" ;; + esac + func_append lib_search_path " $dir" + ;; + esac + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) + testbindir=`$ECHO "$dir" | $SED 's*/lib$*/bin*'` + case :$dllsearchpath: in + *":$dir:"*) ;; + ::) dllsearchpath=$dir;; + *) func_append dllsearchpath ":$dir";; + esac + case :$dllsearchpath: in + *":$testbindir:"*) ;; + ::) dllsearchpath=$testbindir;; + *) func_append dllsearchpath ":$testbindir";; + esac + ;; + esac + continue + ;; + + -l*) + if test X-lc = "X$arg" || test X-lm = "X$arg"; then + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-cegcc* | *-*-haiku*) + # These systems don't actually have a C or math library (as such) + continue + ;; + *-*-os2*) + # These systems don't actually have a C library (as such) + test X-lc = "X$arg" && continue + ;; + *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* | *-*-bitrig*) + # Do not include libc due to us having libc/libc_r. + test X-lc = "X$arg" && continue + ;; + *-*-rhapsody* | *-*-darwin1.[012]) + # Rhapsody C and math libraries are in the System framework + func_append deplibs " System.ltframework" + continue + ;; + *-*-sco3.2v5* | *-*-sco5v6*) + # Causes problems with __ctype + test X-lc = "X$arg" && continue + ;; + *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) + # Compiler inserts libc in the correct place for threads to work + test X-lc = "X$arg" && continue + ;; + esac + elif test X-lc_r = "X$arg"; then + case $host in + *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* | *-*-bitrig*) + # Do not include libc_r directly, use -pthread flag. + continue + ;; + esac + fi + func_append deplibs " $arg" + continue + ;; + + -mllvm) + prev=mllvm + continue + ;; + + -module) + module=yes + continue + ;; + + # Tru64 UNIX uses -model [arg] to determine the layout of C++ + # classes, name mangling, and exception handling. + # Darwin uses the -arch flag to determine output architecture. + -model|-arch|-isysroot|--sysroot) + func_append compiler_flags " $arg" + func_append compile_command " $arg" + func_append finalize_command " $arg" + prev=xcompiler + continue + ;; + + -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \ + |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) + func_append compiler_flags " $arg" + func_append compile_command " $arg" + func_append finalize_command " $arg" + case "$new_inherited_linker_flags " in + *" $arg "*) ;; + * ) func_append new_inherited_linker_flags " $arg" ;; + esac + continue + ;; + + -multi_module) + single_module=$wl-multi_module + continue + ;; + + -no-fast-install) + fast_install=no + continue + ;; + + -no-install) + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin* | *-cegcc*) + # The PATH hackery in wrapper scripts is required on Windows + # and Darwin in order for the loader to find any dlls it needs. + func_warning "'-no-install' is ignored for $host" + func_warning "assuming '-no-fast-install' instead" + fast_install=no + ;; + *) no_install=yes ;; + esac + continue + ;; + + -no-undefined) + allow_undefined=no + continue + ;; + + -objectlist) + prev=objectlist + continue + ;; + + -os2dllname) + prev=os2dllname + continue + ;; + + -o) prev=output ;; + + -precious-files-regex) + prev=precious_regex + continue + ;; + + -release) + prev=release + continue + ;; + + -rpath) + prev=rpath + continue + ;; + + -R) + prev=xrpath + continue + ;; + + -R*) + func_stripname '-R' '' "$arg" + dir=$func_stripname_result + # We need an absolute path. + case $dir in + [\\/]* | [A-Za-z]:[\\/]*) ;; + =*) + func_stripname '=' '' "$dir" + dir=$lt_sysroot$func_stripname_result + ;; + *) + func_fatal_error "only absolute run-paths are allowed" + ;; + esac + case "$xrpath " in + *" $dir "*) ;; + *) func_append xrpath " $dir" ;; + esac + continue + ;; + + -shared) + # The effects of -shared are defined in a previous loop. + continue + ;; + + -shrext) + prev=shrext + continue + ;; + + -static | -static-libtool-libs) + # The effects of -static are defined in a previous loop. + # We used to do the same as -all-static on platforms that + # didn't have a PIC flag, but the assumption that the effects + # would be equivalent was wrong. It would break on at least + # Digital Unix and AIX. + continue + ;; + + -thread-safe) + thread_safe=yes + continue + ;; + + -version-info) + prev=vinfo + continue + ;; + + -version-number) + prev=vinfo + vinfo_number=yes + continue + ;; + + -weak) + prev=weak + continue + ;; + + -Wc,*) + func_stripname '-Wc,' '' "$arg" + args=$func_stripname_result + arg= + save_ifs=$IFS; IFS=, + for flag in $args; do + IFS=$save_ifs + func_quote_for_eval "$flag" + func_append arg " $func_quote_for_eval_result" + func_append compiler_flags " $func_quote_for_eval_result" + done + IFS=$save_ifs + func_stripname ' ' '' "$arg" + arg=$func_stripname_result + ;; + + -Wl,*) + func_stripname '-Wl,' '' "$arg" + args=$func_stripname_result + arg= + save_ifs=$IFS; IFS=, + for flag in $args; do + IFS=$save_ifs + func_quote_for_eval "$flag" + func_append arg " $wl$func_quote_for_eval_result" + func_append compiler_flags " $wl$func_quote_for_eval_result" + func_append linker_flags " $func_quote_for_eval_result" + done + IFS=$save_ifs + func_stripname ' ' '' "$arg" + arg=$func_stripname_result + ;; + + -Xcompiler) + prev=xcompiler + continue + ;; + + -Xlinker) + prev=xlinker + continue + ;; + + -XCClinker) + prev=xcclinker + continue + ;; + + # -msg_* for osf cc + -msg_*) + func_quote_for_eval "$arg" + arg=$func_quote_for_eval_result + ;; + + # Flags to be passed through unchanged, with rationale: + # -64, -mips[0-9] enable 64-bit mode for the SGI compiler + # -r[0-9][0-9]* specify processor for the SGI compiler + # -xarch=*, -xtarget=* enable 64-bit mode for the Sun compiler + # +DA*, +DD* enable 64-bit mode for the HP compiler + # -q* compiler args for the IBM compiler + # -m*, -t[45]*, -txscale* architecture-specific flags for GCC + # -F/path path to uninstalled frameworks, gcc on darwin + # -p, -pg, --coverage, -fprofile-* profiling flags for GCC + # -fstack-protector* stack protector flags for GCC + # @file GCC response files + # -tp=* Portland pgcc target processor selection + # --sysroot=* for sysroot support + # -O*, -g*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization + # -specs=* GCC specs files + # -stdlib=* select c++ std lib with clang + # -fsanitize=* Clang/GCC memory and address sanitizer + -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \ + -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \ + -O*|-g*|-flto*|-fwhopr*|-fuse-linker-plugin|-fstack-protector*|-stdlib=*| \ + -specs=*|-fsanitize=*) + func_quote_for_eval "$arg" + arg=$func_quote_for_eval_result + func_append compile_command " $arg" + func_append finalize_command " $arg" + func_append compiler_flags " $arg" + continue + ;; + + -Z*) + if test os2 = "`expr $host : '.*\(os2\)'`"; then + # OS/2 uses -Zxxx to specify OS/2-specific options + compiler_flags="$compiler_flags $arg" + func_append compile_command " $arg" + func_append finalize_command " $arg" + case $arg in + -Zlinker | -Zstack) + prev=xcompiler + ;; + esac + continue + else + # Otherwise treat like 'Some other compiler flag' below + func_quote_for_eval "$arg" + arg=$func_quote_for_eval_result + fi + ;; + + # Some other compiler flag. + -* | +*) + func_quote_for_eval "$arg" + arg=$func_quote_for_eval_result + ;; + + *.$objext) + # A standard object. + func_append objs " $arg" + ;; + + *.lo) + # A libtool-controlled object. + + # Check to see that this really is a libtool object. + if func_lalib_unsafe_p "$arg"; then + pic_object= + non_pic_object= + + # Read the .lo file + func_source "$arg" + + if test -z "$pic_object" || + test -z "$non_pic_object" || + test none = "$pic_object" && + test none = "$non_pic_object"; then + func_fatal_error "cannot find name of object for '$arg'" + fi + + # Extract subdirectory from the argument. + func_dirname "$arg" "/" "" + xdir=$func_dirname_result + + test none = "$pic_object" || { + # Prepend the subdirectory the object is found in. + pic_object=$xdir$pic_object + + if test dlfiles = "$prev"; then + if test yes = "$build_libtool_libs" && test yes = "$dlopen_support"; then + func_append dlfiles " $pic_object" + prev= + continue + else + # If libtool objects are unsupported, then we need to preload. + prev=dlprefiles + fi + fi + + # CHECK ME: I think I busted this. -Ossama + if test dlprefiles = "$prev"; then + # Preload the old-style object. + func_append dlprefiles " $pic_object" + prev= + fi + + # A PIC object. + func_append libobjs " $pic_object" + arg=$pic_object + } + + # Non-PIC object. + if test none != "$non_pic_object"; then + # Prepend the subdirectory the object is found in. + non_pic_object=$xdir$non_pic_object + + # A standard non-PIC object + func_append non_pic_objects " $non_pic_object" + if test -z "$pic_object" || test none = "$pic_object"; then + arg=$non_pic_object + fi + else + # If the PIC object exists, use it instead. + # $xdir was prepended to $pic_object above. + non_pic_object=$pic_object + func_append non_pic_objects " $non_pic_object" + fi + else + # Only an error if not doing a dry-run. + if $opt_dry_run; then + # Extract subdirectory from the argument. + func_dirname "$arg" "/" "" + xdir=$func_dirname_result + + func_lo2o "$arg" + pic_object=$xdir$objdir/$func_lo2o_result + non_pic_object=$xdir$func_lo2o_result + func_append libobjs " $pic_object" + func_append non_pic_objects " $non_pic_object" + else + func_fatal_error "'$arg' is not a valid libtool object" + fi + fi + ;; + + *.$libext) + # An archive. + func_append deplibs " $arg" + func_append old_deplibs " $arg" + continue + ;; + + *.la) + # A libtool-controlled library. + + func_resolve_sysroot "$arg" + if test dlfiles = "$prev"; then + # This library was specified with -dlopen. + func_append dlfiles " $func_resolve_sysroot_result" + prev= + elif test dlprefiles = "$prev"; then + # The library was specified with -dlpreopen. + func_append dlprefiles " $func_resolve_sysroot_result" + prev= + else + func_append deplibs " $func_resolve_sysroot_result" + fi + continue + ;; + + # Some other compiler argument. + *) + # Unknown arguments in both finalize_command and compile_command need + # to be aesthetically quoted because they are evaled later. + func_quote_for_eval "$arg" + arg=$func_quote_for_eval_result + ;; + esac # arg + + # Now actually substitute the argument into the commands. + if test -n "$arg"; then + func_append compile_command " $arg" + func_append finalize_command " $arg" + fi + done # argument parsing loop + + test -n "$prev" && \ + func_fatal_help "the '$prevarg' option requires an argument" + + if test yes = "$export_dynamic" && test -n "$export_dynamic_flag_spec"; then + eval arg=\"$export_dynamic_flag_spec\" + func_append compile_command " $arg" + func_append finalize_command " $arg" + fi + + oldlibs= + # calculate the name of the file, without its directory + func_basename "$output" + outputname=$func_basename_result + libobjs_save=$libobjs + + if test -n "$shlibpath_var"; then + # get the directories listed in $shlibpath_var + eval shlib_search_path=\`\$ECHO \"\$$shlibpath_var\" \| \$SED \'s/:/ /g\'\` + else + shlib_search_path= + fi + eval sys_lib_search_path=\"$sys_lib_search_path_spec\" + eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\" + + # Definition is injected by LT_CONFIG during libtool generation. + func_munge_path_list sys_lib_dlsearch_path "$LT_SYS_LIBRARY_PATH" + + func_dirname "$output" "/" "" + output_objdir=$func_dirname_result$objdir + func_to_tool_file "$output_objdir/" + tool_output_objdir=$func_to_tool_file_result + # Create the object directory. + func_mkdir_p "$output_objdir" + + # Determine the type of output + case $output in + "") + func_fatal_help "you must specify an output file" + ;; + *.$libext) linkmode=oldlib ;; + *.lo | *.$objext) linkmode=obj ;; + *.la) linkmode=lib ;; + *) linkmode=prog ;; # Anything else should be a program. + esac + + specialdeplibs= + + libs= + # Find all interdependent deplibs by searching for libraries + # that are linked more than once (e.g. -la -lb -la) + for deplib in $deplibs; do + if $opt_preserve_dup_deps; then + case "$libs " in + *" $deplib "*) func_append specialdeplibs " $deplib" ;; + esac + fi + func_append libs " $deplib" + done + + if test lib = "$linkmode"; then + libs="$predeps $libs $compiler_lib_search_path $postdeps" + + # Compute libraries that are listed more than once in $predeps + # $postdeps and mark them as special (i.e., whose duplicates are + # not to be eliminated). + pre_post_deps= + if $opt_duplicate_compiler_generated_deps; then + for pre_post_dep in $predeps $postdeps; do + case "$pre_post_deps " in + *" $pre_post_dep "*) func_append specialdeplibs " $pre_post_deps" ;; + esac + func_append pre_post_deps " $pre_post_dep" + done + fi + pre_post_deps= + fi + + deplibs= + newdependency_libs= + newlib_search_path= + need_relink=no # whether we're linking any uninstalled libtool libraries + notinst_deplibs= # not-installed libtool libraries + notinst_path= # paths that contain not-installed libtool libraries + + case $linkmode in + lib) + passes="conv dlpreopen link" + for file in $dlfiles $dlprefiles; do + case $file in + *.la) ;; + *) + func_fatal_help "libraries can '-dlopen' only libtool libraries: $file" + ;; + esac + done + ;; + prog) + compile_deplibs= + finalize_deplibs= + alldeplibs=false + newdlfiles= + newdlprefiles= + passes="conv scan dlopen dlpreopen link" + ;; + *) passes="conv" + ;; + esac + + for pass in $passes; do + # The preopen pass in lib mode reverses $deplibs; put it back here + # so that -L comes before libs that need it for instance... + if test lib,link = "$linkmode,$pass"; then + ## FIXME: Find the place where the list is rebuilt in the wrong + ## order, and fix it there properly + tmp_deplibs= + for deplib in $deplibs; do + tmp_deplibs="$deplib $tmp_deplibs" + done + deplibs=$tmp_deplibs + fi + + if test lib,link = "$linkmode,$pass" || + test prog,scan = "$linkmode,$pass"; then + libs=$deplibs + deplibs= + fi + if test prog = "$linkmode"; then + case $pass in + dlopen) libs=$dlfiles ;; + dlpreopen) libs=$dlprefiles ;; + link) + libs="$deplibs %DEPLIBS%" + test "X$link_all_deplibs" != Xno && libs="$libs $dependency_libs" + ;; + esac + fi + if test lib,dlpreopen = "$linkmode,$pass"; then + # Collect and forward deplibs of preopened libtool libs + for lib in $dlprefiles; do + # Ignore non-libtool-libs + dependency_libs= + func_resolve_sysroot "$lib" + case $lib in + *.la) func_source "$func_resolve_sysroot_result" ;; + esac + + # Collect preopened libtool deplibs, except any this library + # has declared as weak libs + for deplib in $dependency_libs; do + func_basename "$deplib" + deplib_base=$func_basename_result + case " $weak_libs " in + *" $deplib_base "*) ;; + *) func_append deplibs " $deplib" ;; + esac + done + done + libs=$dlprefiles + fi + if test dlopen = "$pass"; then + # Collect dlpreopened libraries + save_deplibs=$deplibs + deplibs= + fi + + for deplib in $libs; do + lib= + found=false + case $deplib in + -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \ + |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) + if test prog,link = "$linkmode,$pass"; then + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + func_append compiler_flags " $deplib" + if test lib = "$linkmode"; then + case "$new_inherited_linker_flags " in + *" $deplib "*) ;; + * ) func_append new_inherited_linker_flags " $deplib" ;; + esac + fi + fi + continue + ;; + -l*) + if test lib != "$linkmode" && test prog != "$linkmode"; then + func_warning "'-l' is ignored for archives/objects" + continue + fi + func_stripname '-l' '' "$deplib" + name=$func_stripname_result + if test lib = "$linkmode"; then + searchdirs="$newlib_search_path $lib_search_path $compiler_lib_search_dirs $sys_lib_search_path $shlib_search_path" + else + searchdirs="$newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path" + fi + for searchdir in $searchdirs; do + for search_ext in .la $std_shrext .so .a; do + # Search the libtool library + lib=$searchdir/lib$name$search_ext + if test -f "$lib"; then + if test .la = "$search_ext"; then + found=: + else + found=false + fi + break 2 + fi + done + done + if $found; then + # deplib is a libtool library + # If $allow_libtool_libs_with_static_runtimes && $deplib is a stdlib, + # We need to do some special things here, and not later. + if test yes = "$allow_libtool_libs_with_static_runtimes"; then + case " $predeps $postdeps " in + *" $deplib "*) + if func_lalib_p "$lib"; then + library_names= + old_library= + func_source "$lib" + for l in $old_library $library_names; do + ll=$l + done + if test "X$ll" = "X$old_library"; then # only static version available + found=false + func_dirname "$lib" "" "." + ladir=$func_dirname_result + lib=$ladir/$old_library + if test prog,link = "$linkmode,$pass"; then + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + deplibs="$deplib $deplibs" + test lib = "$linkmode" && newdependency_libs="$deplib $newdependency_libs" + fi + continue + fi + fi + ;; + *) ;; + esac + fi + else + # deplib doesn't seem to be a libtool library + if test prog,link = "$linkmode,$pass"; then + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + deplibs="$deplib $deplibs" + test lib = "$linkmode" && newdependency_libs="$deplib $newdependency_libs" + fi + continue + fi + ;; # -l + *.ltframework) + if test prog,link = "$linkmode,$pass"; then + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + deplibs="$deplib $deplibs" + if test lib = "$linkmode"; then + case "$new_inherited_linker_flags " in + *" $deplib "*) ;; + * ) func_append new_inherited_linker_flags " $deplib" ;; + esac + fi + fi + continue + ;; + -L*) + case $linkmode in + lib) + deplibs="$deplib $deplibs" + test conv = "$pass" && continue + newdependency_libs="$deplib $newdependency_libs" + func_stripname '-L' '' "$deplib" + func_resolve_sysroot "$func_stripname_result" + func_append newlib_search_path " $func_resolve_sysroot_result" + ;; + prog) + if test conv = "$pass"; then + deplibs="$deplib $deplibs" + continue + fi + if test scan = "$pass"; then + deplibs="$deplib $deplibs" + else + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + fi + func_stripname '-L' '' "$deplib" + func_resolve_sysroot "$func_stripname_result" + func_append newlib_search_path " $func_resolve_sysroot_result" + ;; + *) + func_warning "'-L' is ignored for archives/objects" + ;; + esac # linkmode + continue + ;; # -L + -R*) + if test link = "$pass"; then + func_stripname '-R' '' "$deplib" + func_resolve_sysroot "$func_stripname_result" + dir=$func_resolve_sysroot_result + # Make sure the xrpath contains only unique directories. + case "$xrpath " in + *" $dir "*) ;; + *) func_append xrpath " $dir" ;; + esac + fi + deplibs="$deplib $deplibs" + continue + ;; + *.la) + func_resolve_sysroot "$deplib" + lib=$func_resolve_sysroot_result + ;; + *.$libext) + if test conv = "$pass"; then + deplibs="$deplib $deplibs" + continue + fi + case $linkmode in + lib) + # Linking convenience modules into shared libraries is allowed, + # but linking other static libraries is non-portable. + case " $dlpreconveniencelibs " in + *" $deplib "*) ;; + *) + valid_a_lib=false + case $deplibs_check_method in + match_pattern*) + set dummy $deplibs_check_method; shift + match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` + if eval "\$ECHO \"$deplib\"" 2>/dev/null | $SED 10q \ + | $EGREP "$match_pattern_regex" > /dev/null; then + valid_a_lib=: + fi + ;; + pass_all) + valid_a_lib=: + ;; + esac + if $valid_a_lib; then + echo + $ECHO "*** Warning: Linking the shared library $output against the" + $ECHO "*** static library $deplib is not portable!" + deplibs="$deplib $deplibs" + else + echo + $ECHO "*** Warning: Trying to link with static lib archive $deplib." + echo "*** I have the capability to make that library automatically link in when" + echo "*** you link to this library. But I can only do this if you have a" + echo "*** shared version of the library, which you do not appear to have" + echo "*** because the file extensions .$libext of this argument makes me believe" + echo "*** that it is just a static archive that I should not use here." + fi + ;; + esac + continue + ;; + prog) + if test link != "$pass"; then + deplibs="$deplib $deplibs" + else + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + fi + continue + ;; + esac # linkmode + ;; # *.$libext + *.lo | *.$objext) + if test conv = "$pass"; then + deplibs="$deplib $deplibs" + elif test prog = "$linkmode"; then + if test dlpreopen = "$pass" || test yes != "$dlopen_support" || test no = "$build_libtool_libs"; then + # If there is no dlopen support or we're linking statically, + # we need to preload. + func_append newdlprefiles " $deplib" + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + func_append newdlfiles " $deplib" + fi + fi + continue + ;; + %DEPLIBS%) + alldeplibs=: + continue + ;; + esac # case $deplib + + $found || test -f "$lib" \ + || func_fatal_error "cannot find the library '$lib' or unhandled argument '$deplib'" + + # Check to see that this really is a libtool archive. + func_lalib_unsafe_p "$lib" \ + || func_fatal_error "'$lib' is not a valid libtool archive" + + func_dirname "$lib" "" "." + ladir=$func_dirname_result + + dlname= + dlopen= + dlpreopen= + libdir= + library_names= + old_library= + inherited_linker_flags= + # If the library was installed with an old release of libtool, + # it will not redefine variables installed, or shouldnotlink + installed=yes + shouldnotlink=no + avoidtemprpath= + + + # Read the .la file + func_source "$lib" + + # Convert "-framework foo" to "foo.ltframework" + if test -n "$inherited_linker_flags"; then + tmp_inherited_linker_flags=`$ECHO "$inherited_linker_flags" | $SED 's/-framework \([^ $]*\)/\1.ltframework/g'` + for tmp_inherited_linker_flag in $tmp_inherited_linker_flags; do + case " $new_inherited_linker_flags " in + *" $tmp_inherited_linker_flag "*) ;; + *) func_append new_inherited_linker_flags " $tmp_inherited_linker_flag";; + esac + done + fi + dependency_libs=`$ECHO " $dependency_libs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + if test lib,link = "$linkmode,$pass" || + test prog,scan = "$linkmode,$pass" || + { test prog != "$linkmode" && test lib != "$linkmode"; }; then + test -n "$dlopen" && func_append dlfiles " $dlopen" + test -n "$dlpreopen" && func_append dlprefiles " $dlpreopen" + fi + + if test conv = "$pass"; then + # Only check for convenience libraries + deplibs="$lib $deplibs" + if test -z "$libdir"; then + if test -z "$old_library"; then + func_fatal_error "cannot find name of link library for '$lib'" + fi + # It is a libtool convenience library, so add in its objects. + func_append convenience " $ladir/$objdir/$old_library" + func_append old_convenience " $ladir/$objdir/$old_library" + tmp_libs= + for deplib in $dependency_libs; do + deplibs="$deplib $deplibs" + if $opt_preserve_dup_deps; then + case "$tmp_libs " in + *" $deplib "*) func_append specialdeplibs " $deplib" ;; + esac + fi + func_append tmp_libs " $deplib" + done + elif test prog != "$linkmode" && test lib != "$linkmode"; then + func_fatal_error "'$lib' is not a convenience library" + fi + continue + fi # $pass = conv + + + # Get the name of the library we link against. + linklib= + if test -n "$old_library" && + { test yes = "$prefer_static_libs" || + test built,no = "$prefer_static_libs,$installed"; }; then + linklib=$old_library + else + for l in $old_library $library_names; do + linklib=$l + done + fi + if test -z "$linklib"; then + func_fatal_error "cannot find name of link library for '$lib'" + fi + + # This library was specified with -dlopen. + if test dlopen = "$pass"; then + test -z "$libdir" \ + && func_fatal_error "cannot -dlopen a convenience library: '$lib'" + if test -z "$dlname" || + test yes != "$dlopen_support" || + test no = "$build_libtool_libs" + then + # If there is no dlname, no dlopen support or we're linking + # statically, we need to preload. We also need to preload any + # dependent libraries so libltdl's deplib preloader doesn't + # bomb out in the load deplibs phase. + func_append dlprefiles " $lib $dependency_libs" + else + func_append newdlfiles " $lib" + fi + continue + fi # $pass = dlopen + + # We need an absolute path. + case $ladir in + [\\/]* | [A-Za-z]:[\\/]*) abs_ladir=$ladir ;; + *) + abs_ladir=`cd "$ladir" && pwd` + if test -z "$abs_ladir"; then + func_warning "cannot determine absolute directory name of '$ladir'" + func_warning "passing it literally to the linker, although it might fail" + abs_ladir=$ladir + fi + ;; + esac + func_basename "$lib" + laname=$func_basename_result + + # Find the relevant object directory and library name. + if test yes = "$installed"; then + if test ! -f "$lt_sysroot$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then + func_warning "library '$lib' was moved." + dir=$ladir + absdir=$abs_ladir + libdir=$abs_ladir + else + dir=$lt_sysroot$libdir + absdir=$lt_sysroot$libdir + fi + test yes = "$hardcode_automatic" && avoidtemprpath=yes + else + if test ! -f "$ladir/$objdir/$linklib" && test -f "$abs_ladir/$linklib"; then + dir=$ladir + absdir=$abs_ladir + # Remove this search path later + func_append notinst_path " $abs_ladir" + else + dir=$ladir/$objdir + absdir=$abs_ladir/$objdir + # Remove this search path later + func_append notinst_path " $abs_ladir" + fi + fi # $installed = yes + func_stripname 'lib' '.la' "$laname" + name=$func_stripname_result + + # This library was specified with -dlpreopen. + if test dlpreopen = "$pass"; then + if test -z "$libdir" && test prog = "$linkmode"; then + func_fatal_error "only libraries may -dlpreopen a convenience library: '$lib'" + fi + case $host in + # special handling for platforms with PE-DLLs. + *cygwin* | *mingw* | *cegcc* ) + # Linker will automatically link against shared library if both + # static and shared are present. Therefore, ensure we extract + # symbols from the import library if a shared library is present + # (otherwise, the dlopen module name will be incorrect). We do + # this by putting the import library name into $newdlprefiles. + # We recover the dlopen module name by 'saving' the la file + # name in a special purpose variable, and (later) extracting the + # dlname from the la file. + if test -n "$dlname"; then + func_tr_sh "$dir/$linklib" + eval "libfile_$func_tr_sh_result=\$abs_ladir/\$laname" + func_append newdlprefiles " $dir/$linklib" + else + func_append newdlprefiles " $dir/$old_library" + # Keep a list of preopened convenience libraries to check + # that they are being used correctly in the link pass. + test -z "$libdir" && \ + func_append dlpreconveniencelibs " $dir/$old_library" + fi + ;; + * ) + # Prefer using a static library (so that no silly _DYNAMIC symbols + # are required to link). + if test -n "$old_library"; then + func_append newdlprefiles " $dir/$old_library" + # Keep a list of preopened convenience libraries to check + # that they are being used correctly in the link pass. + test -z "$libdir" && \ + func_append dlpreconveniencelibs " $dir/$old_library" + # Otherwise, use the dlname, so that lt_dlopen finds it. + elif test -n "$dlname"; then + func_append newdlprefiles " $dir/$dlname" + else + func_append newdlprefiles " $dir/$linklib" + fi + ;; + esac + fi # $pass = dlpreopen + + if test -z "$libdir"; then + # Link the convenience library + if test lib = "$linkmode"; then + deplibs="$dir/$old_library $deplibs" + elif test prog,link = "$linkmode,$pass"; then + compile_deplibs="$dir/$old_library $compile_deplibs" + finalize_deplibs="$dir/$old_library $finalize_deplibs" + else + deplibs="$lib $deplibs" # used for prog,scan pass + fi + continue + fi + + + if test prog = "$linkmode" && test link != "$pass"; then + func_append newlib_search_path " $ladir" + deplibs="$lib $deplibs" + + linkalldeplibs=false + if test no != "$link_all_deplibs" || test -z "$library_names" || + test no = "$build_libtool_libs"; then + linkalldeplibs=: + fi + + tmp_libs= + for deplib in $dependency_libs; do + case $deplib in + -L*) func_stripname '-L' '' "$deplib" + func_resolve_sysroot "$func_stripname_result" + func_append newlib_search_path " $func_resolve_sysroot_result" + ;; + esac + # Need to link against all dependency_libs? + if $linkalldeplibs; then + deplibs="$deplib $deplibs" + else + # Need to hardcode shared library paths + # or/and link against static libraries + newdependency_libs="$deplib $newdependency_libs" + fi + if $opt_preserve_dup_deps; then + case "$tmp_libs " in + *" $deplib "*) func_append specialdeplibs " $deplib" ;; + esac + fi + func_append tmp_libs " $deplib" + done # for deplib + continue + fi # $linkmode = prog... + + if test prog,link = "$linkmode,$pass"; then + if test -n "$library_names" && + { { test no = "$prefer_static_libs" || + test built,yes = "$prefer_static_libs,$installed"; } || + test -z "$old_library"; }; then + # We need to hardcode the library path + if test -n "$shlibpath_var" && test -z "$avoidtemprpath"; then + # Make sure the rpath contains only unique directories. + case $temp_rpath: in + *"$absdir:"*) ;; + *) func_append temp_rpath "$absdir:" ;; + esac + fi + + # Hardcode the library path. + # Skip directories that are in the system default run-time + # search path. + case " $sys_lib_dlsearch_path " in + *" $absdir "*) ;; + *) + case "$compile_rpath " in + *" $absdir "*) ;; + *) func_append compile_rpath " $absdir" ;; + esac + ;; + esac + case " $sys_lib_dlsearch_path " in + *" $libdir "*) ;; + *) + case "$finalize_rpath " in + *" $libdir "*) ;; + *) func_append finalize_rpath " $libdir" ;; + esac + ;; + esac + fi # $linkmode,$pass = prog,link... + + if $alldeplibs && + { test pass_all = "$deplibs_check_method" || + { test yes = "$build_libtool_libs" && + test -n "$library_names"; }; }; then + # We only need to search for static libraries + continue + fi + fi + + link_static=no # Whether the deplib will be linked statically + use_static_libs=$prefer_static_libs + if test built = "$use_static_libs" && test yes = "$installed"; then + use_static_libs=no + fi + if test -n "$library_names" && + { test no = "$use_static_libs" || test -z "$old_library"; }; then + case $host in + *cygwin* | *mingw* | *cegcc* | *os2*) + # No point in relinking DLLs because paths are not encoded + func_append notinst_deplibs " $lib" + need_relink=no + ;; + *) + if test no = "$installed"; then + func_append notinst_deplibs " $lib" + need_relink=yes + fi + ;; + esac + # This is a shared library + + # Warn about portability, can't link against -module's on some + # systems (darwin). Don't bleat about dlopened modules though! + dlopenmodule= + for dlpremoduletest in $dlprefiles; do + if test "X$dlpremoduletest" = "X$lib"; then + dlopenmodule=$dlpremoduletest + break + fi + done + if test -z "$dlopenmodule" && test yes = "$shouldnotlink" && test link = "$pass"; then + echo + if test prog = "$linkmode"; then + $ECHO "*** Warning: Linking the executable $output against the loadable module" + else + $ECHO "*** Warning: Linking the shared library $output against the loadable module" + fi + $ECHO "*** $linklib is not portable!" + fi + if test lib = "$linkmode" && + test yes = "$hardcode_into_libs"; then + # Hardcode the library path. + # Skip directories that are in the system default run-time + # search path. + case " $sys_lib_dlsearch_path " in + *" $absdir "*) ;; + *) + case "$compile_rpath " in + *" $absdir "*) ;; + *) func_append compile_rpath " $absdir" ;; + esac + ;; + esac + case " $sys_lib_dlsearch_path " in + *" $libdir "*) ;; + *) + case "$finalize_rpath " in + *" $libdir "*) ;; + *) func_append finalize_rpath " $libdir" ;; + esac + ;; + esac + fi + + if test -n "$old_archive_from_expsyms_cmds"; then + # figure out the soname + set dummy $library_names + shift + realname=$1 + shift + libname=`eval "\\$ECHO \"$libname_spec\""` + # use dlname if we got it. it's perfectly good, no? + if test -n "$dlname"; then + soname=$dlname + elif test -n "$soname_spec"; then + # bleh windows + case $host in + *cygwin* | mingw* | *cegcc* | *os2*) + func_arith $current - $age + major=$func_arith_result + versuffix=-$major + ;; + esac + eval soname=\"$soname_spec\" + else + soname=$realname + fi + + # Make a new name for the extract_expsyms_cmds to use + soroot=$soname + func_basename "$soroot" + soname=$func_basename_result + func_stripname 'lib' '.dll' "$soname" + newlib=libimp-$func_stripname_result.a + + # If the library has no export list, then create one now + if test -f "$output_objdir/$soname-def"; then : + else + func_verbose "extracting exported symbol list from '$soname'" + func_execute_cmds "$extract_expsyms_cmds" 'exit $?' + fi + + # Create $newlib + if test -f "$output_objdir/$newlib"; then :; else + func_verbose "generating import library for '$soname'" + func_execute_cmds "$old_archive_from_expsyms_cmds" 'exit $?' + fi + # make sure the library variables are pointing to the new library + dir=$output_objdir + linklib=$newlib + fi # test -n "$old_archive_from_expsyms_cmds" + + if test prog = "$linkmode" || test relink != "$opt_mode"; then + add_shlibpath= + add_dir= + add= + lib_linked=yes + case $hardcode_action in + immediate | unsupported) + if test no = "$hardcode_direct"; then + add=$dir/$linklib + case $host in + *-*-sco3.2v5.0.[024]*) add_dir=-L$dir ;; + *-*-sysv4*uw2*) add_dir=-L$dir ;; + *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \ + *-*-unixware7*) add_dir=-L$dir ;; + *-*-darwin* ) + # if the lib is a (non-dlopened) module then we cannot + # link against it, someone is ignoring the earlier warnings + if /usr/bin/file -L $add 2> /dev/null | + $GREP ": [^:]* bundle" >/dev/null; then + if test "X$dlopenmodule" != "X$lib"; then + $ECHO "*** Warning: lib $linklib is a module, not a shared library" + if test -z "$old_library"; then + echo + echo "*** And there doesn't seem to be a static archive available" + echo "*** The link will probably fail, sorry" + else + add=$dir/$old_library + fi + elif test -n "$old_library"; then + add=$dir/$old_library + fi + fi + esac + elif test no = "$hardcode_minus_L"; then + case $host in + *-*-sunos*) add_shlibpath=$dir ;; + esac + add_dir=-L$dir + add=-l$name + elif test no = "$hardcode_shlibpath_var"; then + add_shlibpath=$dir + add=-l$name + else + lib_linked=no + fi + ;; + relink) + if test yes = "$hardcode_direct" && + test no = "$hardcode_direct_absolute"; then + add=$dir/$linklib + elif test yes = "$hardcode_minus_L"; then + add_dir=-L$absdir + # Try looking first in the location we're being installed to. + if test -n "$inst_prefix_dir"; then + case $libdir in + [\\/]*) + func_append add_dir " -L$inst_prefix_dir$libdir" + ;; + esac + fi + add=-l$name + elif test yes = "$hardcode_shlibpath_var"; then + add_shlibpath=$dir + add=-l$name + else + lib_linked=no + fi + ;; + *) lib_linked=no ;; + esac + + if test yes != "$lib_linked"; then + func_fatal_configuration "unsupported hardcode properties" + fi + + if test -n "$add_shlibpath"; then + case :$compile_shlibpath: in + *":$add_shlibpath:"*) ;; + *) func_append compile_shlibpath "$add_shlibpath:" ;; + esac + fi + if test prog = "$linkmode"; then + test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs" + test -n "$add" && compile_deplibs="$add $compile_deplibs" + else + test -n "$add_dir" && deplibs="$add_dir $deplibs" + test -n "$add" && deplibs="$add $deplibs" + if test yes != "$hardcode_direct" && + test yes != "$hardcode_minus_L" && + test yes = "$hardcode_shlibpath_var"; then + case :$finalize_shlibpath: in + *":$libdir:"*) ;; + *) func_append finalize_shlibpath "$libdir:" ;; + esac + fi + fi + fi + + if test prog = "$linkmode" || test relink = "$opt_mode"; then + add_shlibpath= + add_dir= + add= + # Finalize command for both is simple: just hardcode it. + if test yes = "$hardcode_direct" && + test no = "$hardcode_direct_absolute"; then + add=$libdir/$linklib + elif test yes = "$hardcode_minus_L"; then + add_dir=-L$libdir + add=-l$name + elif test yes = "$hardcode_shlibpath_var"; then + case :$finalize_shlibpath: in + *":$libdir:"*) ;; + *) func_append finalize_shlibpath "$libdir:" ;; + esac + add=-l$name + elif test yes = "$hardcode_automatic"; then + if test -n "$inst_prefix_dir" && + test -f "$inst_prefix_dir$libdir/$linklib"; then + add=$inst_prefix_dir$libdir/$linklib + else + add=$libdir/$linklib + fi + else + # We cannot seem to hardcode it, guess we'll fake it. + add_dir=-L$libdir + # Try looking first in the location we're being installed to. + if test -n "$inst_prefix_dir"; then + case $libdir in + [\\/]*) + func_append add_dir " -L$inst_prefix_dir$libdir" + ;; + esac + fi + add=-l$name + fi + + if test prog = "$linkmode"; then + test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs" + test -n "$add" && finalize_deplibs="$add $finalize_deplibs" + else + test -n "$add_dir" && deplibs="$add_dir $deplibs" + test -n "$add" && deplibs="$add $deplibs" + fi + fi + elif test prog = "$linkmode"; then + # Here we assume that one of hardcode_direct or hardcode_minus_L + # is not unsupported. This is valid on all known static and + # shared platforms. + if test unsupported != "$hardcode_direct"; then + test -n "$old_library" && linklib=$old_library + compile_deplibs="$dir/$linklib $compile_deplibs" + finalize_deplibs="$dir/$linklib $finalize_deplibs" + else + compile_deplibs="-l$name -L$dir $compile_deplibs" + finalize_deplibs="-l$name -L$dir $finalize_deplibs" + fi + elif test yes = "$build_libtool_libs"; then + # Not a shared library + if test pass_all != "$deplibs_check_method"; then + # We're trying link a shared library against a static one + # but the system doesn't support it. + + # Just print a warning and add the library to dependency_libs so + # that the program can be linked against the static library. + echo + $ECHO "*** Warning: This system cannot link to static lib archive $lib." + echo "*** I have the capability to make that library automatically link in when" + echo "*** you link to this library. But I can only do this if you have a" + echo "*** shared version of the library, which you do not appear to have." + if test yes = "$module"; then + echo "*** But as you try to build a module library, libtool will still create " + echo "*** a static module, that should work as long as the dlopening application" + echo "*** is linked with the -dlopen flag to resolve symbols at runtime." + if test -z "$global_symbol_pipe"; then + echo + echo "*** However, this would only work if libtool was able to extract symbol" + echo "*** lists from a program, using 'nm' or equivalent, but libtool could" + echo "*** not find such a program. So, this module is probably useless." + echo "*** 'nm' from GNU binutils and a full rebuild may help." + fi + if test no = "$build_old_libs"; then + build_libtool_libs=module + build_old_libs=yes + else + build_libtool_libs=no + fi + fi + else + deplibs="$dir/$old_library $deplibs" + link_static=yes + fi + fi # link shared/static library? + + if test lib = "$linkmode"; then + if test -n "$dependency_libs" && + { test yes != "$hardcode_into_libs" || + test yes = "$build_old_libs" || + test yes = "$link_static"; }; then + # Extract -R from dependency_libs + temp_deplibs= + for libdir in $dependency_libs; do + case $libdir in + -R*) func_stripname '-R' '' "$libdir" + temp_xrpath=$func_stripname_result + case " $xrpath " in + *" $temp_xrpath "*) ;; + *) func_append xrpath " $temp_xrpath";; + esac;; + *) func_append temp_deplibs " $libdir";; + esac + done + dependency_libs=$temp_deplibs + fi + + func_append newlib_search_path " $absdir" + # Link against this library + test no = "$link_static" && newdependency_libs="$abs_ladir/$laname $newdependency_libs" + # ... and its dependency_libs + tmp_libs= + for deplib in $dependency_libs; do + newdependency_libs="$deplib $newdependency_libs" + case $deplib in + -L*) func_stripname '-L' '' "$deplib" + func_resolve_sysroot "$func_stripname_result";; + *) func_resolve_sysroot "$deplib" ;; + esac + if $opt_preserve_dup_deps; then + case "$tmp_libs " in + *" $func_resolve_sysroot_result "*) + func_append specialdeplibs " $func_resolve_sysroot_result" ;; + esac + fi + func_append tmp_libs " $func_resolve_sysroot_result" + done + + if test no != "$link_all_deplibs"; then + # Add the search paths of all dependency libraries + for deplib in $dependency_libs; do + path= + case $deplib in + -L*) path=$deplib ;; + *.la) + func_resolve_sysroot "$deplib" + deplib=$func_resolve_sysroot_result + func_dirname "$deplib" "" "." + dir=$func_dirname_result + # We need an absolute path. + case $dir in + [\\/]* | [A-Za-z]:[\\/]*) absdir=$dir ;; + *) + absdir=`cd "$dir" && pwd` + if test -z "$absdir"; then + func_warning "cannot determine absolute directory name of '$dir'" + absdir=$dir + fi + ;; + esac + if $GREP "^installed=no" $deplib > /dev/null; then + case $host in + *-*-darwin*) + depdepl= + eval deplibrary_names=`$SED -n -e 's/^library_names=\(.*\)$/\1/p' $deplib` + if test -n "$deplibrary_names"; then + for tmp in $deplibrary_names; do + depdepl=$tmp + done + if test -f "$absdir/$objdir/$depdepl"; then + depdepl=$absdir/$objdir/$depdepl + darwin_install_name=`$OTOOL -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` + if test -z "$darwin_install_name"; then + darwin_install_name=`$OTOOL64 -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` + fi + func_append compiler_flags " $wl-dylib_file $wl$darwin_install_name:$depdepl" + func_append linker_flags " -dylib_file $darwin_install_name:$depdepl" + path= + fi + fi + ;; + *) + path=-L$absdir/$objdir + ;; + esac + else + eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` + test -z "$libdir" && \ + func_fatal_error "'$deplib' is not a valid libtool archive" + test "$absdir" != "$libdir" && \ + func_warning "'$deplib' seems to be moved" + + path=-L$absdir + fi + ;; + esac + case " $deplibs " in + *" $path "*) ;; + *) deplibs="$path $deplibs" ;; + esac + done + fi # link_all_deplibs != no + fi # linkmode = lib + done # for deplib in $libs + if test link = "$pass"; then + if test prog = "$linkmode"; then + compile_deplibs="$new_inherited_linker_flags $compile_deplibs" + finalize_deplibs="$new_inherited_linker_flags $finalize_deplibs" + else + compiler_flags="$compiler_flags "`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + fi + fi + dependency_libs=$newdependency_libs + if test dlpreopen = "$pass"; then + # Link the dlpreopened libraries before other libraries + for deplib in $save_deplibs; do + deplibs="$deplib $deplibs" + done + fi + if test dlopen != "$pass"; then + test conv = "$pass" || { + # Make sure lib_search_path contains only unique directories. + lib_search_path= + for dir in $newlib_search_path; do + case "$lib_search_path " in + *" $dir "*) ;; + *) func_append lib_search_path " $dir" ;; + esac + done + newlib_search_path= + } + + if test prog,link = "$linkmode,$pass"; then + vars="compile_deplibs finalize_deplibs" + else + vars=deplibs + fi + for var in $vars dependency_libs; do + # Add libraries to $var in reverse order + eval tmp_libs=\"\$$var\" + new_libs= + for deplib in $tmp_libs; do + # FIXME: Pedantically, this is the right thing to do, so + # that some nasty dependency loop isn't accidentally + # broken: + #new_libs="$deplib $new_libs" + # Pragmatically, this seems to cause very few problems in + # practice: + case $deplib in + -L*) new_libs="$deplib $new_libs" ;; + -R*) ;; + *) + # And here is the reason: when a library appears more + # than once as an explicit dependence of a library, or + # is implicitly linked in more than once by the + # compiler, it is considered special, and multiple + # occurrences thereof are not removed. Compare this + # with having the same library being listed as a + # dependency of multiple other libraries: in this case, + # we know (pedantically, we assume) the library does not + # need to be listed more than once, so we keep only the + # last copy. This is not always right, but it is rare + # enough that we require users that really mean to play + # such unportable linking tricks to link the library + # using -Wl,-lname, so that libtool does not consider it + # for duplicate removal. + case " $specialdeplibs " in + *" $deplib "*) new_libs="$deplib $new_libs" ;; + *) + case " $new_libs " in + *" $deplib "*) ;; + *) new_libs="$deplib $new_libs" ;; + esac + ;; + esac + ;; + esac + done + tmp_libs= + for deplib in $new_libs; do + case $deplib in + -L*) + case " $tmp_libs " in + *" $deplib "*) ;; + *) func_append tmp_libs " $deplib" ;; + esac + ;; + *) func_append tmp_libs " $deplib" ;; + esac + done + eval $var=\"$tmp_libs\" + done # for var + fi + + # Add Sun CC postdeps if required: + test CXX = "$tagname" && { + case $host_os in + linux*) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) # Sun C++ 5.9 + func_suncc_cstd_abi + + if test no != "$suncc_use_cstd_abi"; then + func_append postdeps ' -library=Cstd -library=Crun' + fi + ;; + esac + ;; + + solaris*) + func_cc_basename "$CC" + case $func_cc_basename_result in + CC* | sunCC*) + func_suncc_cstd_abi + + if test no != "$suncc_use_cstd_abi"; then + func_append postdeps ' -library=Cstd -library=Crun' + fi + ;; + esac + ;; + esac + } + + # Last step: remove runtime libs from dependency_libs + # (they stay in deplibs) + tmp_libs= + for i in $dependency_libs; do + case " $predeps $postdeps $compiler_lib_search_path " in + *" $i "*) + i= + ;; + esac + if test -n "$i"; then + func_append tmp_libs " $i" + fi + done + dependency_libs=$tmp_libs + done # for pass + if test prog = "$linkmode"; then + dlfiles=$newdlfiles + fi + if test prog = "$linkmode" || test lib = "$linkmode"; then + dlprefiles=$newdlprefiles + fi + + case $linkmode in + oldlib) + if test -n "$dlfiles$dlprefiles" || test no != "$dlself"; then + func_warning "'-dlopen' is ignored for archives" + fi + + case " $deplibs" in + *\ -l* | *\ -L*) + func_warning "'-l' and '-L' are ignored for archives" ;; + esac + + test -n "$rpath" && \ + func_warning "'-rpath' is ignored for archives" + + test -n "$xrpath" && \ + func_warning "'-R' is ignored for archives" + + test -n "$vinfo" && \ + func_warning "'-version-info/-version-number' is ignored for archives" + + test -n "$release" && \ + func_warning "'-release' is ignored for archives" + + test -n "$export_symbols$export_symbols_regex" && \ + func_warning "'-export-symbols' is ignored for archives" + + # Now set the variables for building old libraries. + build_libtool_libs=no + oldlibs=$output + func_append objs "$old_deplibs" + ;; + + lib) + # Make sure we only generate libraries of the form 'libNAME.la'. + case $outputname in + lib*) + func_stripname 'lib' '.la' "$outputname" + name=$func_stripname_result + eval shared_ext=\"$shrext_cmds\" + eval libname=\"$libname_spec\" + ;; + *) + test no = "$module" \ + && func_fatal_help "libtool library '$output' must begin with 'lib'" + + if test no != "$need_lib_prefix"; then + # Add the "lib" prefix for modules if required + func_stripname '' '.la' "$outputname" + name=$func_stripname_result + eval shared_ext=\"$shrext_cmds\" + eval libname=\"$libname_spec\" + else + func_stripname '' '.la' "$outputname" + libname=$func_stripname_result + fi + ;; + esac + + if test -n "$objs"; then + if test pass_all != "$deplibs_check_method"; then + func_fatal_error "cannot build libtool library '$output' from non-libtool objects on this host:$objs" + else + echo + $ECHO "*** Warning: Linking the shared library $output against the non-libtool" + $ECHO "*** objects $objs is not portable!" + func_append libobjs " $objs" + fi + fi + + test no = "$dlself" \ + || func_warning "'-dlopen self' is ignored for libtool libraries" + + set dummy $rpath + shift + test 1 -lt "$#" \ + && func_warning "ignoring multiple '-rpath's for a libtool library" + + install_libdir=$1 + + oldlibs= + if test -z "$rpath"; then + if test yes = "$build_libtool_libs"; then + # Building a libtool convenience library. + # Some compilers have problems with a '.al' extension so + # convenience libraries should have the same extension an + # archive normally would. + oldlibs="$output_objdir/$libname.$libext $oldlibs" + build_libtool_libs=convenience + build_old_libs=yes + fi + + test -n "$vinfo" && \ + func_warning "'-version-info/-version-number' is ignored for convenience libraries" + + test -n "$release" && \ + func_warning "'-release' is ignored for convenience libraries" + else + + # Parse the version information argument. + save_ifs=$IFS; IFS=: + set dummy $vinfo 0 0 0 + shift + IFS=$save_ifs + + test -n "$7" && \ + func_fatal_help "too many parameters to '-version-info'" + + # convert absolute version numbers to libtool ages + # this retains compatibility with .la files and attempts + # to make the code below a bit more comprehensible + + case $vinfo_number in + yes) + number_major=$1 + number_minor=$2 + number_revision=$3 + # + # There are really only two kinds -- those that + # use the current revision as the major version + # and those that subtract age and use age as + # a minor version. But, then there is irix + # that has an extra 1 added just for fun + # + case $version_type in + # correct linux to gnu/linux during the next big refactor + darwin|freebsd-elf|linux|osf|windows|none) + func_arith $number_major + $number_minor + current=$func_arith_result + age=$number_minor + revision=$number_revision + ;; + freebsd-aout|qnx|sunos) + current=$number_major + revision=$number_minor + age=0 + ;; + irix|nonstopux) + func_arith $number_major + $number_minor + current=$func_arith_result + age=$number_minor + revision=$number_minor + lt_irix_increment=no + ;; + *) + func_fatal_configuration "$modename: unknown library version type '$version_type'" + ;; + esac + ;; + no) + current=$1 + revision=$2 + age=$3 + ;; + esac + + # Check that each of the things are valid numbers. + case $current in + 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; + *) + func_error "CURRENT '$current' must be a nonnegative integer" + func_fatal_error "'$vinfo' is not valid version information" + ;; + esac + + case $revision in + 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; + *) + func_error "REVISION '$revision' must be a nonnegative integer" + func_fatal_error "'$vinfo' is not valid version information" + ;; + esac + + case $age in + 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; + *) + func_error "AGE '$age' must be a nonnegative integer" + func_fatal_error "'$vinfo' is not valid version information" + ;; + esac + + if test "$age" -gt "$current"; then + func_error "AGE '$age' is greater than the current interface number '$current'" + func_fatal_error "'$vinfo' is not valid version information" + fi + + # Calculate the version variables. + major= + versuffix= + verstring= + case $version_type in + none) ;; + + darwin) + # Like Linux, but with the current version available in + # verstring for coding it into the library header + func_arith $current - $age + major=.$func_arith_result + versuffix=$major.$age.$revision + # Darwin ld doesn't like 0 for these options... + func_arith $current + 1 + minor_current=$func_arith_result + xlcverstring="$wl-compatibility_version $wl$minor_current $wl-current_version $wl$minor_current.$revision" + verstring="-compatibility_version $minor_current -current_version $minor_current.$revision" + # On Darwin other compilers + case $CC in + nagfor*) + verstring="$wl-compatibility_version $wl$minor_current $wl-current_version $wl$minor_current.$revision" + ;; + *) + verstring="-compatibility_version $minor_current -current_version $minor_current.$revision" + ;; + esac + ;; + + freebsd-aout) + major=.$current + versuffix=.$current.$revision + ;; + + freebsd-elf) + func_arith $current - $age + major=.$func_arith_result + versuffix=$major.$age.$revision + ;; + + irix | nonstopux) + if test no = "$lt_irix_increment"; then + func_arith $current - $age + else + func_arith $current - $age + 1 + fi + major=$func_arith_result + + case $version_type in + nonstopux) verstring_prefix=nonstopux ;; + *) verstring_prefix=sgi ;; + esac + verstring=$verstring_prefix$major.$revision + + # Add in all the interfaces that we are compatible with. + loop=$revision + while test 0 -ne "$loop"; do + func_arith $revision - $loop + iface=$func_arith_result + func_arith $loop - 1 + loop=$func_arith_result + verstring=$verstring_prefix$major.$iface:$verstring + done + + # Before this point, $major must not contain '.'. + major=.$major + versuffix=$major.$revision + ;; + + linux) # correct to gnu/linux during the next big refactor + func_arith $current - $age + major=.$func_arith_result + versuffix=$major.$age.$revision + ;; + + osf) + func_arith $current - $age + major=.$func_arith_result + versuffix=.$current.$age.$revision + verstring=$current.$age.$revision + + # Add in all the interfaces that we are compatible with. + loop=$age + while test 0 -ne "$loop"; do + func_arith $current - $loop + iface=$func_arith_result + func_arith $loop - 1 + loop=$func_arith_result + verstring=$verstring:$iface.0 + done + + # Make executables depend on our current version. + func_append verstring ":$current.0" + ;; + + qnx) + major=.$current + versuffix=.$current + ;; + + sco) + major=.$current + versuffix=.$current + ;; + + sunos) + major=.$current + versuffix=.$current.$revision + ;; + + windows) + # Use '-' rather than '.', since we only want one + # extension on DOS 8.3 file systems. + func_arith $current - $age + major=$func_arith_result + versuffix=-$major + ;; + + *) + func_fatal_configuration "unknown library version type '$version_type'" + ;; + esac + + # Clear the version info if we defaulted, and they specified a release. + if test -z "$vinfo" && test -n "$release"; then + major= + case $version_type in + darwin) + # we can't check for "0.0" in archive_cmds due to quoting + # problems, so we reset it completely + verstring= + ;; + *) + verstring=0.0 + ;; + esac + if test no = "$need_version"; then + versuffix= + else + versuffix=.0.0 + fi + fi + + # Remove version info from name if versioning should be avoided + if test yes,no = "$avoid_version,$need_version"; then + major= + versuffix= + verstring= + fi + + # Check to see if the archive will have undefined symbols. + if test yes = "$allow_undefined"; then + if test unsupported = "$allow_undefined_flag"; then + if test yes = "$build_old_libs"; then + func_warning "undefined symbols not allowed in $host shared libraries; building static only" + build_libtool_libs=no + else + func_fatal_error "can't build $host shared library unless -no-undefined is specified" + fi + fi + else + # Don't allow undefined symbols. + allow_undefined_flag=$no_undefined_flag + fi + + fi + + func_generate_dlsyms "$libname" "$libname" : + func_append libobjs " $symfileobj" + test " " = "$libobjs" && libobjs= + + if test relink != "$opt_mode"; then + # Remove our outputs, but don't remove object files since they + # may have been created when compiling PIC objects. + removelist= + tempremovelist=`$ECHO "$output_objdir/*"` + for p in $tempremovelist; do + case $p in + *.$objext | *.gcno) + ;; + $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/$libname$release.*) + if test -n "$precious_files_regex"; then + if $ECHO "$p" | $EGREP -e "$precious_files_regex" >/dev/null 2>&1 + then + continue + fi + fi + func_append removelist " $p" + ;; + *) ;; + esac + done + test -n "$removelist" && \ + func_show_eval "${RM}r \$removelist" + fi + + # Now set the variables for building old libraries. + if test yes = "$build_old_libs" && test convenience != "$build_libtool_libs"; then + func_append oldlibs " $output_objdir/$libname.$libext" + + # Transform .lo files to .o files. + oldobjs="$objs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.$libext$/d; $lo2o" | $NL2SP` + fi + + # Eliminate all temporary directories. + #for path in $notinst_path; do + # lib_search_path=`$ECHO "$lib_search_path " | $SED "s% $path % %g"` + # deplibs=`$ECHO "$deplibs " | $SED "s% -L$path % %g"` + # dependency_libs=`$ECHO "$dependency_libs " | $SED "s% -L$path % %g"` + #done + + if test -n "$xrpath"; then + # If the user specified any rpath flags, then add them. + temp_xrpath= + for libdir in $xrpath; do + func_replace_sysroot "$libdir" + func_append temp_xrpath " -R$func_replace_sysroot_result" + case "$finalize_rpath " in + *" $libdir "*) ;; + *) func_append finalize_rpath " $libdir" ;; + esac + done + if test yes != "$hardcode_into_libs" || test yes = "$build_old_libs"; then + dependency_libs="$temp_xrpath $dependency_libs" + fi + fi + + # Make sure dlfiles contains only unique files that won't be dlpreopened + old_dlfiles=$dlfiles + dlfiles= + for lib in $old_dlfiles; do + case " $dlprefiles $dlfiles " in + *" $lib "*) ;; + *) func_append dlfiles " $lib" ;; + esac + done + + # Make sure dlprefiles contains only unique files + old_dlprefiles=$dlprefiles + dlprefiles= + for lib in $old_dlprefiles; do + case "$dlprefiles " in + *" $lib "*) ;; + *) func_append dlprefiles " $lib" ;; + esac + done + + if test yes = "$build_libtool_libs"; then + if test -n "$rpath"; then + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc* | *-*-haiku*) + # these systems don't actually have a c library (as such)! + ;; + *-*-rhapsody* | *-*-darwin1.[012]) + # Rhapsody C library is in the System framework + func_append deplibs " System.ltframework" + ;; + *-*-netbsd*) + # Don't link with libc until the a.out ld.so is fixed. + ;; + *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) + # Do not include libc due to us having libc/libc_r. + ;; + *-*-sco3.2v5* | *-*-sco5v6*) + # Causes problems with __ctype + ;; + *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) + # Compiler inserts libc in the correct place for threads to work + ;; + *) + # Add libc to deplibs on all other systems if necessary. + if test yes = "$build_libtool_need_lc"; then + func_append deplibs " -lc" + fi + ;; + esac + fi + + # Transform deplibs into only deplibs that can be linked in shared. + name_save=$name + libname_save=$libname + release_save=$release + versuffix_save=$versuffix + major_save=$major + # I'm not sure if I'm treating the release correctly. I think + # release should show up in the -l (ie -lgmp5) so we don't want to + # add it in twice. Is that correct? + release= + versuffix= + major= + newdeplibs= + droppeddeps=no + case $deplibs_check_method in + pass_all) + # Don't check for shared/static. Everything works. + # This might be a little naive. We might want to check + # whether the library exists or not. But this is on + # osf3 & osf4 and I'm not really sure... Just + # implementing what was already the behavior. + newdeplibs=$deplibs + ;; + test_compile) + # This code stresses the "libraries are programs" paradigm to its + # limits. Maybe even breaks it. We compile a program, linking it + # against the deplibs as a proxy for the library. Then we can check + # whether they linked in statically or dynamically with ldd. + $opt_dry_run || $RM conftest.c + cat > conftest.c </dev/null` + $nocaseglob + else + potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null` + fi + for potent_lib in $potential_libs; do + # Follow soft links. + if ls -lLd "$potent_lib" 2>/dev/null | + $GREP " -> " >/dev/null; then + continue + fi + # The statement above tries to avoid entering an + # endless loop below, in case of cyclic links. + # We might still enter an endless loop, since a link + # loop can be closed while we follow links, + # but so what? + potlib=$potent_lib + while test -h "$potlib" 2>/dev/null; do + potliblink=`ls -ld $potlib | $SED 's/.* -> //'` + case $potliblink in + [\\/]* | [A-Za-z]:[\\/]*) potlib=$potliblink;; + *) potlib=`$ECHO "$potlib" | $SED 's|[^/]*$||'`"$potliblink";; + esac + done + if eval $file_magic_cmd \"\$potlib\" 2>/dev/null | + $SED -e 10q | + $EGREP "$file_magic_regex" > /dev/null; then + func_append newdeplibs " $a_deplib" + a_deplib= + break 2 + fi + done + done + fi + if test -n "$a_deplib"; then + droppeddeps=yes + echo + $ECHO "*** Warning: linker path does not have real file for library $a_deplib." + echo "*** I have the capability to make that library automatically link in when" + echo "*** you link to this library. But I can only do this if you have a" + echo "*** shared version of the library, which you do not appear to have" + echo "*** because I did check the linker path looking for a file starting" + if test -z "$potlib"; then + $ECHO "*** with $libname but no candidates were found. (...for file magic test)" + else + $ECHO "*** with $libname and none of the candidates passed a file format test" + $ECHO "*** using a file magic. Last file checked: $potlib" + fi + fi + ;; + *) + # Add a -L argument. + func_append newdeplibs " $a_deplib" + ;; + esac + done # Gone through all deplibs. + ;; + match_pattern*) + set dummy $deplibs_check_method; shift + match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` + for a_deplib in $deplibs; do + case $a_deplib in + -l*) + func_stripname -l '' "$a_deplib" + name=$func_stripname_result + if test yes = "$allow_libtool_libs_with_static_runtimes"; then + case " $predeps $postdeps " in + *" $a_deplib "*) + func_append newdeplibs " $a_deplib" + a_deplib= + ;; + esac + fi + if test -n "$a_deplib"; then + libname=`eval "\\$ECHO \"$libname_spec\""` + for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do + potential_libs=`ls $i/$libname[.-]* 2>/dev/null` + for potent_lib in $potential_libs; do + potlib=$potent_lib # see symlink-check above in file_magic test + if eval "\$ECHO \"$potent_lib\"" 2>/dev/null | $SED 10q | \ + $EGREP "$match_pattern_regex" > /dev/null; then + func_append newdeplibs " $a_deplib" + a_deplib= + break 2 + fi + done + done + fi + if test -n "$a_deplib"; then + droppeddeps=yes + echo + $ECHO "*** Warning: linker path does not have real file for library $a_deplib." + echo "*** I have the capability to make that library automatically link in when" + echo "*** you link to this library. But I can only do this if you have a" + echo "*** shared version of the library, which you do not appear to have" + echo "*** because I did check the linker path looking for a file starting" + if test -z "$potlib"; then + $ECHO "*** with $libname but no candidates were found. (...for regex pattern test)" + else + $ECHO "*** with $libname and none of the candidates passed a file format test" + $ECHO "*** using a regex pattern. Last file checked: $potlib" + fi + fi + ;; + *) + # Add a -L argument. + func_append newdeplibs " $a_deplib" + ;; + esac + done # Gone through all deplibs. + ;; + none | unknown | *) + newdeplibs= + tmp_deplibs=`$ECHO " $deplibs" | $SED 's/ -lc$//; s/ -[LR][^ ]*//g'` + if test yes = "$allow_libtool_libs_with_static_runtimes"; then + for i in $predeps $postdeps; do + # can't use Xsed below, because $i might contain '/' + tmp_deplibs=`$ECHO " $tmp_deplibs" | $SED "s|$i||"` + done + fi + case $tmp_deplibs in + *[!\ \ ]*) + echo + if test none = "$deplibs_check_method"; then + echo "*** Warning: inter-library dependencies are not supported in this platform." + else + echo "*** Warning: inter-library dependencies are not known to be supported." + fi + echo "*** All declared inter-library dependencies are being dropped." + droppeddeps=yes + ;; + esac + ;; + esac + versuffix=$versuffix_save + major=$major_save + release=$release_save + libname=$libname_save + name=$name_save + + case $host in + *-*-rhapsody* | *-*-darwin1.[012]) + # On Rhapsody replace the C library with the System framework + newdeplibs=`$ECHO " $newdeplibs" | $SED 's/ -lc / System.ltframework /'` + ;; + esac + + if test yes = "$droppeddeps"; then + if test yes = "$module"; then + echo + echo "*** Warning: libtool could not satisfy all declared inter-library" + $ECHO "*** dependencies of module $libname. Therefore, libtool will create" + echo "*** a static module, that should work as long as the dlopening" + echo "*** application is linked with the -dlopen flag." + if test -z "$global_symbol_pipe"; then + echo + echo "*** However, this would only work if libtool was able to extract symbol" + echo "*** lists from a program, using 'nm' or equivalent, but libtool could" + echo "*** not find such a program. So, this module is probably useless." + echo "*** 'nm' from GNU binutils and a full rebuild may help." + fi + if test no = "$build_old_libs"; then + oldlibs=$output_objdir/$libname.$libext + build_libtool_libs=module + build_old_libs=yes + else + build_libtool_libs=no + fi + else + echo "*** The inter-library dependencies that have been dropped here will be" + echo "*** automatically added whenever a program is linked with this library" + echo "*** or is declared to -dlopen it." + + if test no = "$allow_undefined"; then + echo + echo "*** Since this library must not contain undefined symbols," + echo "*** because either the platform does not support them or" + echo "*** it was explicitly requested with -no-undefined," + echo "*** libtool will only create a static version of it." + if test no = "$build_old_libs"; then + oldlibs=$output_objdir/$libname.$libext + build_libtool_libs=module + build_old_libs=yes + else + build_libtool_libs=no + fi + fi + fi + fi + # Done checking deplibs! + deplibs=$newdeplibs + fi + # Time to change all our "foo.ltframework" stuff back to "-framework foo" + case $host in + *-*-darwin*) + newdeplibs=`$ECHO " $newdeplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + new_inherited_linker_flags=`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + deplibs=`$ECHO " $deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + ;; + esac + + # move library search paths that coincide with paths to not yet + # installed libraries to the beginning of the library search list + new_libs= + for path in $notinst_path; do + case " $new_libs " in + *" -L$path/$objdir "*) ;; + *) + case " $deplibs " in + *" -L$path/$objdir "*) + func_append new_libs " -L$path/$objdir" ;; + esac + ;; + esac + done + for deplib in $deplibs; do + case $deplib in + -L*) + case " $new_libs " in + *" $deplib "*) ;; + *) func_append new_libs " $deplib" ;; + esac + ;; + *) func_append new_libs " $deplib" ;; + esac + done + deplibs=$new_libs + + # All the library-specific variables (install_libdir is set above). + library_names= + old_library= + dlname= + + # Test again, we may have decided not to build it any more + if test yes = "$build_libtool_libs"; then + # Remove $wl instances when linking with ld. + # FIXME: should test the right _cmds variable. + case $archive_cmds in + *\$LD\ *) wl= ;; + esac + if test yes = "$hardcode_into_libs"; then + # Hardcode the library paths + hardcode_libdirs= + dep_rpath= + rpath=$finalize_rpath + test relink = "$opt_mode" || rpath=$compile_rpath$rpath + for libdir in $rpath; do + if test -n "$hardcode_libdir_flag_spec"; then + if test -n "$hardcode_libdir_separator"; then + func_replace_sysroot "$libdir" + libdir=$func_replace_sysroot_result + if test -z "$hardcode_libdirs"; then + hardcode_libdirs=$libdir + else + # Just accumulate the unique libdirs. + case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in + *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) + ;; + *) + func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" + ;; + esac + fi + else + eval flag=\"$hardcode_libdir_flag_spec\" + func_append dep_rpath " $flag" + fi + elif test -n "$runpath_var"; then + case "$perm_rpath " in + *" $libdir "*) ;; + *) func_append perm_rpath " $libdir" ;; + esac + fi + done + # Substitute the hardcoded libdirs into the rpath. + if test -n "$hardcode_libdir_separator" && + test -n "$hardcode_libdirs"; then + libdir=$hardcode_libdirs + eval "dep_rpath=\"$hardcode_libdir_flag_spec\"" + fi + if test -n "$runpath_var" && test -n "$perm_rpath"; then + # We should set the runpath_var. + rpath= + for dir in $perm_rpath; do + func_append rpath "$dir:" + done + eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var" + fi + test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs" + fi + + shlibpath=$finalize_shlibpath + test relink = "$opt_mode" || shlibpath=$compile_shlibpath$shlibpath + if test -n "$shlibpath"; then + eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var" + fi + + # Get the real and link names of the library. + eval shared_ext=\"$shrext_cmds\" + eval library_names=\"$library_names_spec\" + set dummy $library_names + shift + realname=$1 + shift + + if test -n "$soname_spec"; then + eval soname=\"$soname_spec\" + else + soname=$realname + fi + if test -z "$dlname"; then + dlname=$soname + fi + + lib=$output_objdir/$realname + linknames= + for link + do + func_append linknames " $link" + done + + # Use standard objects if they are pic + test -z "$pic_flag" && libobjs=`$ECHO "$libobjs" | $SP2NL | $SED "$lo2o" | $NL2SP` + test "X$libobjs" = "X " && libobjs= + + delfiles= + if test -n "$export_symbols" && test -n "$include_expsyms"; then + $opt_dry_run || cp "$export_symbols" "$output_objdir/$libname.uexp" + export_symbols=$output_objdir/$libname.uexp + func_append delfiles " $export_symbols" + fi + + orig_export_symbols= + case $host_os in + cygwin* | mingw* | cegcc*) + if test -n "$export_symbols" && test -z "$export_symbols_regex"; then + # exporting using user supplied symfile + func_dll_def_p "$export_symbols" || { + # and it's NOT already a .def file. Must figure out + # which of the given symbols are data symbols and tag + # them as such. So, trigger use of export_symbols_cmds. + # export_symbols gets reassigned inside the "prepare + # the list of exported symbols" if statement, so the + # include_expsyms logic still works. + orig_export_symbols=$export_symbols + export_symbols= + always_export_symbols=yes + } + fi + ;; + esac + + # Prepare the list of exported symbols + if test -z "$export_symbols"; then + if test yes = "$always_export_symbols" || test -n "$export_symbols_regex"; then + func_verbose "generating symbol list for '$libname.la'" + export_symbols=$output_objdir/$libname.exp + $opt_dry_run || $RM $export_symbols + cmds=$export_symbols_cmds + save_ifs=$IFS; IFS='~' + for cmd1 in $cmds; do + IFS=$save_ifs + # Take the normal branch if the nm_file_list_spec branch + # doesn't work or if tool conversion is not needed. + case $nm_file_list_spec~$to_tool_file_cmd in + *~func_convert_file_noop | *~func_convert_file_msys_to_w32 | ~*) + try_normal_branch=yes + eval cmd=\"$cmd1\" + func_len " $cmd" + len=$func_len_result + ;; + *) + try_normal_branch=no + ;; + esac + if test yes = "$try_normal_branch" \ + && { test "$len" -lt "$max_cmd_len" \ + || test "$max_cmd_len" -le -1; } + then + func_show_eval "$cmd" 'exit $?' + skipped_export=false + elif test -n "$nm_file_list_spec"; then + func_basename "$output" + output_la=$func_basename_result + save_libobjs=$libobjs + save_output=$output + output=$output_objdir/$output_la.nm + func_to_tool_file "$output" + libobjs=$nm_file_list_spec$func_to_tool_file_result + func_append delfiles " $output" + func_verbose "creating $NM input file list: $output" + for obj in $save_libobjs; do + func_to_tool_file "$obj" + $ECHO "$func_to_tool_file_result" + done > "$output" + eval cmd=\"$cmd1\" + func_show_eval "$cmd" 'exit $?' + output=$save_output + libobjs=$save_libobjs + skipped_export=false + else + # The command line is too long to execute in one step. + func_verbose "using reloadable object file for export list..." + skipped_export=: + # Break out early, otherwise skipped_export may be + # set to false by a later but shorter cmd. + break + fi + done + IFS=$save_ifs + if test -n "$export_symbols_regex" && test : != "$skipped_export"; then + func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' + func_show_eval '$MV "${export_symbols}T" "$export_symbols"' + fi + fi + fi + + if test -n "$export_symbols" && test -n "$include_expsyms"; then + tmp_export_symbols=$export_symbols + test -n "$orig_export_symbols" && tmp_export_symbols=$orig_export_symbols + $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' + fi + + if test : != "$skipped_export" && test -n "$orig_export_symbols"; then + # The given exports_symbols file has to be filtered, so filter it. + func_verbose "filter symbol list for '$libname.la' to tag DATA exports" + # FIXME: $output_objdir/$libname.filter potentially contains lots of + # 's' commands, which not all seds can handle. GNU sed should be fine + # though. Also, the filter scales superlinearly with the number of + # global variables. join(1) would be nice here, but unfortunately + # isn't a blessed tool. + $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter + func_append delfiles " $export_symbols $output_objdir/$libname.filter" + export_symbols=$output_objdir/$libname.def + $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols + fi + + tmp_deplibs= + for test_deplib in $deplibs; do + case " $convenience " in + *" $test_deplib "*) ;; + *) + func_append tmp_deplibs " $test_deplib" + ;; + esac + done + deplibs=$tmp_deplibs + + if test -n "$convenience"; then + if test -n "$whole_archive_flag_spec" && + test yes = "$compiler_needs_object" && + test -z "$libobjs"; then + # extract the archives, so we have objects to list. + # TODO: could optimize this to just extract one archive. + whole_archive_flag_spec= + fi + if test -n "$whole_archive_flag_spec"; then + save_libobjs=$libobjs + eval libobjs=\"\$libobjs $whole_archive_flag_spec\" + test "X$libobjs" = "X " && libobjs= + else + gentop=$output_objdir/${outputname}x + func_append generated " $gentop" + + func_extract_archives $gentop $convenience + func_append libobjs " $func_extract_archives_result" + test "X$libobjs" = "X " && libobjs= + fi + fi + + if test yes = "$thread_safe" && test -n "$thread_safe_flag_spec"; then + eval flag=\"$thread_safe_flag_spec\" + func_append linker_flags " $flag" + fi + + # Make a backup of the uninstalled library when relinking + if test relink = "$opt_mode"; then + $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}U && $MV $realname ${realname}U)' || exit $? + fi + + # Do each of the archive commands. + if test yes = "$module" && test -n "$module_cmds"; then + if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then + eval test_cmds=\"$module_expsym_cmds\" + cmds=$module_expsym_cmds + else + eval test_cmds=\"$module_cmds\" + cmds=$module_cmds + fi + else + if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then + eval test_cmds=\"$archive_expsym_cmds\" + cmds=$archive_expsym_cmds + else + eval test_cmds=\"$archive_cmds\" + cmds=$archive_cmds + fi + fi + + if test : != "$skipped_export" && + func_len " $test_cmds" && + len=$func_len_result && + test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then + : + else + # The command line is too long to link in one step, link piecewise + # or, if using GNU ld and skipped_export is not :, use a linker + # script. + + # Save the value of $output and $libobjs because we want to + # use them later. If we have whole_archive_flag_spec, we + # want to use save_libobjs as it was before + # whole_archive_flag_spec was expanded, because we can't + # assume the linker understands whole_archive_flag_spec. + # This may have to be revisited, in case too many + # convenience libraries get linked in and end up exceeding + # the spec. + if test -z "$convenience" || test -z "$whole_archive_flag_spec"; then + save_libobjs=$libobjs + fi + save_output=$output + func_basename "$output" + output_la=$func_basename_result + + # Clear the reloadable object creation command queue and + # initialize k to one. + test_cmds= + concat_cmds= + objlist= + last_robj= + k=1 + + if test -n "$save_libobjs" && test : != "$skipped_export" && test yes = "$with_gnu_ld"; then + output=$output_objdir/$output_la.lnkscript + func_verbose "creating GNU ld script: $output" + echo 'INPUT (' > $output + for obj in $save_libobjs + do + func_to_tool_file "$obj" + $ECHO "$func_to_tool_file_result" >> $output + done + echo ')' >> $output + func_append delfiles " $output" + func_to_tool_file "$output" + output=$func_to_tool_file_result + elif test -n "$save_libobjs" && test : != "$skipped_export" && test -n "$file_list_spec"; then + output=$output_objdir/$output_la.lnk + func_verbose "creating linker input file list: $output" + : > $output + set x $save_libobjs + shift + firstobj= + if test yes = "$compiler_needs_object"; then + firstobj="$1 " + shift + fi + for obj + do + func_to_tool_file "$obj" + $ECHO "$func_to_tool_file_result" >> $output + done + func_append delfiles " $output" + func_to_tool_file "$output" + output=$firstobj\"$file_list_spec$func_to_tool_file_result\" + else + if test -n "$save_libobjs"; then + func_verbose "creating reloadable object files..." + output=$output_objdir/$output_la-$k.$objext + eval test_cmds=\"$reload_cmds\" + func_len " $test_cmds" + len0=$func_len_result + len=$len0 + + # Loop over the list of objects to be linked. + for obj in $save_libobjs + do + func_len " $obj" + func_arith $len + $func_len_result + len=$func_arith_result + if test -z "$objlist" || + test "$len" -lt "$max_cmd_len"; then + func_append objlist " $obj" + else + # The command $test_cmds is almost too long, add a + # command to the queue. + if test 1 -eq "$k"; then + # The first file doesn't have a previous command to add. + reload_objs=$objlist + eval concat_cmds=\"$reload_cmds\" + else + # All subsequent reloadable object files will link in + # the last one created. + reload_objs="$objlist $last_robj" + eval concat_cmds=\"\$concat_cmds~$reload_cmds~\$RM $last_robj\" + fi + last_robj=$output_objdir/$output_la-$k.$objext + func_arith $k + 1 + k=$func_arith_result + output=$output_objdir/$output_la-$k.$objext + objlist=" $obj" + func_len " $last_robj" + func_arith $len0 + $func_len_result + len=$func_arith_result + fi + done + # Handle the remaining objects by creating one last + # reloadable object file. All subsequent reloadable object + # files will link in the last one created. + test -z "$concat_cmds" || concat_cmds=$concat_cmds~ + reload_objs="$objlist $last_robj" + eval concat_cmds=\"\$concat_cmds$reload_cmds\" + if test -n "$last_robj"; then + eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\" + fi + func_append delfiles " $output" + + else + output= + fi + + ${skipped_export-false} && { + func_verbose "generating symbol list for '$libname.la'" + export_symbols=$output_objdir/$libname.exp + $opt_dry_run || $RM $export_symbols + libobjs=$output + # Append the command to create the export file. + test -z "$concat_cmds" || concat_cmds=$concat_cmds~ + eval concat_cmds=\"\$concat_cmds$export_symbols_cmds\" + if test -n "$last_robj"; then + eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\" + fi + } + + test -n "$save_libobjs" && + func_verbose "creating a temporary reloadable object file: $output" + + # Loop through the commands generated above and execute them. + save_ifs=$IFS; IFS='~' + for cmd in $concat_cmds; do + IFS=$save_ifs + $opt_quiet || { + func_quote_for_expand "$cmd" + eval "func_echo $func_quote_for_expand_result" + } + $opt_dry_run || eval "$cmd" || { + lt_exit=$? + + # Restore the uninstalled library and exit + if test relink = "$opt_mode"; then + ( cd "$output_objdir" && \ + $RM "${realname}T" && \ + $MV "${realname}U" "$realname" ) + fi + + exit $lt_exit + } + done + IFS=$save_ifs + + if test -n "$export_symbols_regex" && ${skipped_export-false}; then + func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' + func_show_eval '$MV "${export_symbols}T" "$export_symbols"' + fi + fi + + ${skipped_export-false} && { + if test -n "$export_symbols" && test -n "$include_expsyms"; then + tmp_export_symbols=$export_symbols + test -n "$orig_export_symbols" && tmp_export_symbols=$orig_export_symbols + $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' + fi + + if test -n "$orig_export_symbols"; then + # The given exports_symbols file has to be filtered, so filter it. + func_verbose "filter symbol list for '$libname.la' to tag DATA exports" + # FIXME: $output_objdir/$libname.filter potentially contains lots of + # 's' commands, which not all seds can handle. GNU sed should be fine + # though. Also, the filter scales superlinearly with the number of + # global variables. join(1) would be nice here, but unfortunately + # isn't a blessed tool. + $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter + func_append delfiles " $export_symbols $output_objdir/$libname.filter" + export_symbols=$output_objdir/$libname.def + $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols + fi + } + + libobjs=$output + # Restore the value of output. + output=$save_output + + if test -n "$convenience" && test -n "$whole_archive_flag_spec"; then + eval libobjs=\"\$libobjs $whole_archive_flag_spec\" + test "X$libobjs" = "X " && libobjs= + fi + # Expand the library linking commands again to reset the + # value of $libobjs for piecewise linking. + + # Do each of the archive commands. + if test yes = "$module" && test -n "$module_cmds"; then + if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then + cmds=$module_expsym_cmds + else + cmds=$module_cmds + fi + else + if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then + cmds=$archive_expsym_cmds + else + cmds=$archive_cmds + fi + fi + fi + + if test -n "$delfiles"; then + # Append the command to remove temporary files to $cmds. + eval cmds=\"\$cmds~\$RM $delfiles\" + fi + + # Add any objects from preloaded convenience libraries + if test -n "$dlprefiles"; then + gentop=$output_objdir/${outputname}x + func_append generated " $gentop" + + func_extract_archives $gentop $dlprefiles + func_append libobjs " $func_extract_archives_result" + test "X$libobjs" = "X " && libobjs= + fi + + save_ifs=$IFS; IFS='~' + for cmd in $cmds; do + IFS=$sp$nl + eval cmd=\"$cmd\" + IFS=$save_ifs + $opt_quiet || { + func_quote_for_expand "$cmd" + eval "func_echo $func_quote_for_expand_result" + } + $opt_dry_run || eval "$cmd" || { + lt_exit=$? + + # Restore the uninstalled library and exit + if test relink = "$opt_mode"; then + ( cd "$output_objdir" && \ + $RM "${realname}T" && \ + $MV "${realname}U" "$realname" ) + fi + + exit $lt_exit + } + done + IFS=$save_ifs + + # Restore the uninstalled library and exit + if test relink = "$opt_mode"; then + $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}T && $MV $realname ${realname}T && $MV ${realname}U $realname)' || exit $? + + if test -n "$convenience"; then + if test -z "$whole_archive_flag_spec"; then + func_show_eval '${RM}r "$gentop"' + fi + fi + + exit $EXIT_SUCCESS + fi + + # Create links to the real library. + for linkname in $linknames; do + if test "$realname" != "$linkname"; then + func_show_eval '(cd "$output_objdir" && $RM "$linkname" && $LN_S "$realname" "$linkname")' 'exit $?' + fi + done + + # If -module or -export-dynamic was specified, set the dlname. + if test yes = "$module" || test yes = "$export_dynamic"; then + # On all known operating systems, these are identical. + dlname=$soname + fi + fi + ;; + + obj) + if test -n "$dlfiles$dlprefiles" || test no != "$dlself"; then + func_warning "'-dlopen' is ignored for objects" + fi + + case " $deplibs" in + *\ -l* | *\ -L*) + func_warning "'-l' and '-L' are ignored for objects" ;; + esac + + test -n "$rpath" && \ + func_warning "'-rpath' is ignored for objects" + + test -n "$xrpath" && \ + func_warning "'-R' is ignored for objects" + + test -n "$vinfo" && \ + func_warning "'-version-info' is ignored for objects" + + test -n "$release" && \ + func_warning "'-release' is ignored for objects" + + case $output in + *.lo) + test -n "$objs$old_deplibs" && \ + func_fatal_error "cannot build library object '$output' from non-libtool objects" + + libobj=$output + func_lo2o "$libobj" + obj=$func_lo2o_result + ;; + *) + libobj= + obj=$output + ;; + esac + + # Delete the old objects. + $opt_dry_run || $RM $obj $libobj + + # Objects from convenience libraries. This assumes + # single-version convenience libraries. Whenever we create + # different ones for PIC/non-PIC, this we'll have to duplicate + # the extraction. + reload_conv_objs= + gentop= + # if reload_cmds runs $LD directly, get rid of -Wl from + # whole_archive_flag_spec and hope we can get by with turning comma + # into space. + case $reload_cmds in + *\$LD[\ \$]*) wl= ;; + esac + if test -n "$convenience"; then + if test -n "$whole_archive_flag_spec"; then + eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\" + test -n "$wl" || tmp_whole_archive_flags=`$ECHO "$tmp_whole_archive_flags" | $SED 's|,| |g'` + reload_conv_objs=$reload_objs\ $tmp_whole_archive_flags + else + gentop=$output_objdir/${obj}x + func_append generated " $gentop" + + func_extract_archives $gentop $convenience + reload_conv_objs="$reload_objs $func_extract_archives_result" + fi + fi + + # If we're not building shared, we need to use non_pic_objs + test yes = "$build_libtool_libs" || libobjs=$non_pic_objects + + # Create the old-style object. + reload_objs=$objs$old_deplibs' '`$ECHO "$libobjs" | $SP2NL | $SED "/\.$libext$/d; /\.lib$/d; $lo2o" | $NL2SP`' '$reload_conv_objs + + output=$obj + func_execute_cmds "$reload_cmds" 'exit $?' + + # Exit if we aren't doing a library object file. + if test -z "$libobj"; then + if test -n "$gentop"; then + func_show_eval '${RM}r "$gentop"' + fi + + exit $EXIT_SUCCESS + fi + + test yes = "$build_libtool_libs" || { + if test -n "$gentop"; then + func_show_eval '${RM}r "$gentop"' + fi + + # Create an invalid libtool object if no PIC, so that we don't + # accidentally link it into a program. + # $show "echo timestamp > $libobj" + # $opt_dry_run || eval "echo timestamp > $libobj" || exit $? + exit $EXIT_SUCCESS + } + + if test -n "$pic_flag" || test default != "$pic_mode"; then + # Only do commands if we really have different PIC objects. + reload_objs="$libobjs $reload_conv_objs" + output=$libobj + func_execute_cmds "$reload_cmds" 'exit $?' + fi + + if test -n "$gentop"; then + func_show_eval '${RM}r "$gentop"' + fi + + exit $EXIT_SUCCESS + ;; + + prog) + case $host in + *cygwin*) func_stripname '' '.exe' "$output" + output=$func_stripname_result.exe;; + esac + test -n "$vinfo" && \ + func_warning "'-version-info' is ignored for programs" + + test -n "$release" && \ + func_warning "'-release' is ignored for programs" + + $preload \ + && test unknown,unknown,unknown = "$dlopen_support,$dlopen_self,$dlopen_self_static" \ + && func_warning "'LT_INIT([dlopen])' not used. Assuming no dlopen support." + + case $host in + *-*-rhapsody* | *-*-darwin1.[012]) + # On Rhapsody replace the C library is the System framework + compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's/ -lc / System.ltframework /'` + finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's/ -lc / System.ltframework /'` + ;; + esac + + case $host in + *-*-darwin*) + # Don't allow lazy linking, it breaks C++ global constructors + # But is supposedly fixed on 10.4 or later (yay!). + if test CXX = "$tagname"; then + case ${MACOSX_DEPLOYMENT_TARGET-10.0} in + 10.[0123]) + func_append compile_command " $wl-bind_at_load" + func_append finalize_command " $wl-bind_at_load" + ;; + esac + fi + # Time to change all our "foo.ltframework" stuff back to "-framework foo" + compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + ;; + esac + + + # move library search paths that coincide with paths to not yet + # installed libraries to the beginning of the library search list + new_libs= + for path in $notinst_path; do + case " $new_libs " in + *" -L$path/$objdir "*) ;; + *) + case " $compile_deplibs " in + *" -L$path/$objdir "*) + func_append new_libs " -L$path/$objdir" ;; + esac + ;; + esac + done + for deplib in $compile_deplibs; do + case $deplib in + -L*) + case " $new_libs " in + *" $deplib "*) ;; + *) func_append new_libs " $deplib" ;; + esac + ;; + *) func_append new_libs " $deplib" ;; + esac + done + compile_deplibs=$new_libs + + + func_append compile_command " $compile_deplibs" + func_append finalize_command " $finalize_deplibs" + + if test -n "$rpath$xrpath"; then + # If the user specified any rpath flags, then add them. + for libdir in $rpath $xrpath; do + # This is the magic to use -rpath. + case "$finalize_rpath " in + *" $libdir "*) ;; + *) func_append finalize_rpath " $libdir" ;; + esac + done + fi + + # Now hardcode the library paths + rpath= + hardcode_libdirs= + for libdir in $compile_rpath $finalize_rpath; do + if test -n "$hardcode_libdir_flag_spec"; then + if test -n "$hardcode_libdir_separator"; then + if test -z "$hardcode_libdirs"; then + hardcode_libdirs=$libdir + else + # Just accumulate the unique libdirs. + case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in + *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) + ;; + *) + func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" + ;; + esac + fi + else + eval flag=\"$hardcode_libdir_flag_spec\" + func_append rpath " $flag" + fi + elif test -n "$runpath_var"; then + case "$perm_rpath " in + *" $libdir "*) ;; + *) func_append perm_rpath " $libdir" ;; + esac + fi + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) + testbindir=`$ECHO "$libdir" | $SED -e 's*/lib$*/bin*'` + case :$dllsearchpath: in + *":$libdir:"*) ;; + ::) dllsearchpath=$libdir;; + *) func_append dllsearchpath ":$libdir";; + esac + case :$dllsearchpath: in + *":$testbindir:"*) ;; + ::) dllsearchpath=$testbindir;; + *) func_append dllsearchpath ":$testbindir";; + esac + ;; + esac + done + # Substitute the hardcoded libdirs into the rpath. + if test -n "$hardcode_libdir_separator" && + test -n "$hardcode_libdirs"; then + libdir=$hardcode_libdirs + eval rpath=\" $hardcode_libdir_flag_spec\" + fi + compile_rpath=$rpath + + rpath= + hardcode_libdirs= + for libdir in $finalize_rpath; do + if test -n "$hardcode_libdir_flag_spec"; then + if test -n "$hardcode_libdir_separator"; then + if test -z "$hardcode_libdirs"; then + hardcode_libdirs=$libdir + else + # Just accumulate the unique libdirs. + case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in + *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) + ;; + *) + func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" + ;; + esac + fi + else + eval flag=\"$hardcode_libdir_flag_spec\" + func_append rpath " $flag" + fi + elif test -n "$runpath_var"; then + case "$finalize_perm_rpath " in + *" $libdir "*) ;; + *) func_append finalize_perm_rpath " $libdir" ;; + esac + fi + done + # Substitute the hardcoded libdirs into the rpath. + if test -n "$hardcode_libdir_separator" && + test -n "$hardcode_libdirs"; then + libdir=$hardcode_libdirs + eval rpath=\" $hardcode_libdir_flag_spec\" + fi + finalize_rpath=$rpath + + if test -n "$libobjs" && test yes = "$build_old_libs"; then + # Transform all the library objects into standard objects. + compile_command=`$ECHO "$compile_command" | $SP2NL | $SED "$lo2o" | $NL2SP` + finalize_command=`$ECHO "$finalize_command" | $SP2NL | $SED "$lo2o" | $NL2SP` + fi + + func_generate_dlsyms "$outputname" "@PROGRAM@" false + + # template prelinking step + if test -n "$prelink_cmds"; then + func_execute_cmds "$prelink_cmds" 'exit $?' + fi + + wrappers_required=: + case $host in + *cegcc* | *mingw32ce*) + # Disable wrappers for cegcc and mingw32ce hosts, we are cross compiling anyway. + wrappers_required=false + ;; + *cygwin* | *mingw* ) + test yes = "$build_libtool_libs" || wrappers_required=false + ;; + *) + if test no = "$need_relink" || test yes != "$build_libtool_libs"; then + wrappers_required=false + fi + ;; + esac + $wrappers_required || { + # Replace the output file specification. + compile_command=`$ECHO "$compile_command" | $SED 's%@OUTPUT@%'"$output"'%g'` + link_command=$compile_command$compile_rpath + + # We have no uninstalled library dependencies, so finalize right now. + exit_status=0 + func_show_eval "$link_command" 'exit_status=$?' + + if test -n "$postlink_cmds"; then + func_to_tool_file "$output" + postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` + func_execute_cmds "$postlink_cmds" 'exit $?' + fi + + # Delete the generated files. + if test -f "$output_objdir/${outputname}S.$objext"; then + func_show_eval '$RM "$output_objdir/${outputname}S.$objext"' + fi + + exit $exit_status + } + + if test -n "$compile_shlibpath$finalize_shlibpath"; then + compile_command="$shlibpath_var=\"$compile_shlibpath$finalize_shlibpath\$$shlibpath_var\" $compile_command" + fi + if test -n "$finalize_shlibpath"; then + finalize_command="$shlibpath_var=\"$finalize_shlibpath\$$shlibpath_var\" $finalize_command" + fi + + compile_var= + finalize_var= + if test -n "$runpath_var"; then + if test -n "$perm_rpath"; then + # We should set the runpath_var. + rpath= + for dir in $perm_rpath; do + func_append rpath "$dir:" + done + compile_var="$runpath_var=\"$rpath\$$runpath_var\" " + fi + if test -n "$finalize_perm_rpath"; then + # We should set the runpath_var. + rpath= + for dir in $finalize_perm_rpath; do + func_append rpath "$dir:" + done + finalize_var="$runpath_var=\"$rpath\$$runpath_var\" " + fi + fi + + if test yes = "$no_install"; then + # We don't need to create a wrapper script. + link_command=$compile_var$compile_command$compile_rpath + # Replace the output file specification. + link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output"'%g'` + # Delete the old output file. + $opt_dry_run || $RM $output + # Link the executable and exit + func_show_eval "$link_command" 'exit $?' + + if test -n "$postlink_cmds"; then + func_to_tool_file "$output" + postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` + func_execute_cmds "$postlink_cmds" 'exit $?' + fi + + exit $EXIT_SUCCESS + fi + + case $hardcode_action,$fast_install in + relink,*) + # Fast installation is not supported + link_command=$compile_var$compile_command$compile_rpath + relink_command=$finalize_var$finalize_command$finalize_rpath + + func_warning "this platform does not like uninstalled shared libraries" + func_warning "'$output' will be relinked during installation" + ;; + *,yes) + link_command=$finalize_var$compile_command$finalize_rpath + relink_command=`$ECHO "$compile_var$compile_command$compile_rpath" | $SED 's%@OUTPUT@%\$progdir/\$file%g'` + ;; + *,no) + link_command=$compile_var$compile_command$compile_rpath + relink_command=$finalize_var$finalize_command$finalize_rpath + ;; + *,needless) + link_command=$finalize_var$compile_command$finalize_rpath + relink_command= + ;; + esac + + # Replace the output file specification. + link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'` + + # Delete the old output files. + $opt_dry_run || $RM $output $output_objdir/$outputname $output_objdir/lt-$outputname + + func_show_eval "$link_command" 'exit $?' + + if test -n "$postlink_cmds"; then + func_to_tool_file "$output_objdir/$outputname" + postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` + func_execute_cmds "$postlink_cmds" 'exit $?' + fi + + # Now create the wrapper script. + func_verbose "creating $output" + + # Quote the relink command for shipping. + if test -n "$relink_command"; then + # Preserve any variables that may affect compiler behavior + for var in $variables_saved_for_relink; do + if eval test -z \"\${$var+set}\"; then + relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" + elif eval var_value=\$$var; test -z "$var_value"; then + relink_command="$var=; export $var; $relink_command" + else + func_quote_for_eval "$var_value" + relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command" + fi + done + relink_command="(cd `pwd`; $relink_command)" + relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"` + fi + + # Only actually do things if not in dry run mode. + $opt_dry_run || { + # win32 will think the script is a binary if it has + # a .exe suffix, so we strip it off here. + case $output in + *.exe) func_stripname '' '.exe' "$output" + output=$func_stripname_result ;; + esac + # test for cygwin because mv fails w/o .exe extensions + case $host in + *cygwin*) + exeext=.exe + func_stripname '' '.exe' "$outputname" + outputname=$func_stripname_result ;; + *) exeext= ;; + esac + case $host in + *cygwin* | *mingw* ) + func_dirname_and_basename "$output" "" "." + output_name=$func_basename_result + output_path=$func_dirname_result + cwrappersource=$output_path/$objdir/lt-$output_name.c + cwrapper=$output_path/$output_name.exe + $RM $cwrappersource $cwrapper + trap "$RM $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 + + func_emit_cwrapperexe_src > $cwrappersource + + # The wrapper executable is built using the $host compiler, + # because it contains $host paths and files. If cross- + # compiling, it, like the target executable, must be + # executed on the $host or under an emulation environment. + $opt_dry_run || { + $LTCC $LTCFLAGS -o $cwrapper $cwrappersource + $STRIP $cwrapper + } + + # Now, create the wrapper script for func_source use: + func_ltwrapper_scriptname $cwrapper + $RM $func_ltwrapper_scriptname_result + trap "$RM $func_ltwrapper_scriptname_result; exit $EXIT_FAILURE" 1 2 15 + $opt_dry_run || { + # note: this script will not be executed, so do not chmod. + if test "x$build" = "x$host"; then + $cwrapper --lt-dump-script > $func_ltwrapper_scriptname_result + else + func_emit_wrapper no > $func_ltwrapper_scriptname_result + fi + } + ;; + * ) + $RM $output + trap "$RM $output; exit $EXIT_FAILURE" 1 2 15 + + func_emit_wrapper no > $output + chmod +x $output + ;; + esac + } + exit $EXIT_SUCCESS + ;; + esac + + # See if we need to build an old-fashioned archive. + for oldlib in $oldlibs; do + + case $build_libtool_libs in + convenience) + oldobjs="$libobjs_save $symfileobj" + addlibs=$convenience + build_libtool_libs=no + ;; + module) + oldobjs=$libobjs_save + addlibs=$old_convenience + build_libtool_libs=no + ;; + *) + oldobjs="$old_deplibs $non_pic_objects" + $preload && test -f "$symfileobj" \ + && func_append oldobjs " $symfileobj" + addlibs=$old_convenience + ;; + esac + + if test -n "$addlibs"; then + gentop=$output_objdir/${outputname}x + func_append generated " $gentop" + + func_extract_archives $gentop $addlibs + func_append oldobjs " $func_extract_archives_result" + fi + + # Do each command in the archive commands. + if test -n "$old_archive_from_new_cmds" && test yes = "$build_libtool_libs"; then + cmds=$old_archive_from_new_cmds + else + + # Add any objects from preloaded convenience libraries + if test -n "$dlprefiles"; then + gentop=$output_objdir/${outputname}x + func_append generated " $gentop" + + func_extract_archives $gentop $dlprefiles + func_append oldobjs " $func_extract_archives_result" + fi + + # POSIX demands no paths to be encoded in archives. We have + # to avoid creating archives with duplicate basenames if we + # might have to extract them afterwards, e.g., when creating a + # static archive out of a convenience library, or when linking + # the entirety of a libtool archive into another (currently + # not supported by libtool). + if (for obj in $oldobjs + do + func_basename "$obj" + $ECHO "$func_basename_result" + done | sort | sort -uc >/dev/null 2>&1); then + : + else + echo "copying selected object files to avoid basename conflicts..." + gentop=$output_objdir/${outputname}x + func_append generated " $gentop" + func_mkdir_p "$gentop" + save_oldobjs=$oldobjs + oldobjs= + counter=1 + for obj in $save_oldobjs + do + func_basename "$obj" + objbase=$func_basename_result + case " $oldobjs " in + " ") oldobjs=$obj ;; + *[\ /]"$objbase "*) + while :; do + # Make sure we don't pick an alternate name that also + # overlaps. + newobj=lt$counter-$objbase + func_arith $counter + 1 + counter=$func_arith_result + case " $oldobjs " in + *[\ /]"$newobj "*) ;; + *) if test ! -f "$gentop/$newobj"; then break; fi ;; + esac + done + func_show_eval "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj" + func_append oldobjs " $gentop/$newobj" + ;; + *) func_append oldobjs " $obj" ;; + esac + done + fi + func_to_tool_file "$oldlib" func_convert_file_msys_to_w32 + tool_oldlib=$func_to_tool_file_result + eval cmds=\"$old_archive_cmds\" + + func_len " $cmds" + len=$func_len_result + if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then + cmds=$old_archive_cmds + elif test -n "$archiver_list_spec"; then + func_verbose "using command file archive linking..." + for obj in $oldobjs + do + func_to_tool_file "$obj" + $ECHO "$func_to_tool_file_result" + done > $output_objdir/$libname.libcmd + func_to_tool_file "$output_objdir/$libname.libcmd" + oldobjs=" $archiver_list_spec$func_to_tool_file_result" + cmds=$old_archive_cmds + else + # the command line is too long to link in one step, link in parts + func_verbose "using piecewise archive linking..." + save_RANLIB=$RANLIB + RANLIB=: + objlist= + concat_cmds= + save_oldobjs=$oldobjs + oldobjs= + # Is there a better way of finding the last object in the list? + for obj in $save_oldobjs + do + last_oldobj=$obj + done + eval test_cmds=\"$old_archive_cmds\" + func_len " $test_cmds" + len0=$func_len_result + len=$len0 + for obj in $save_oldobjs + do + func_len " $obj" + func_arith $len + $func_len_result + len=$func_arith_result + func_append objlist " $obj" + if test "$len" -lt "$max_cmd_len"; then + : + else + # the above command should be used before it gets too long + oldobjs=$objlist + if test "$obj" = "$last_oldobj"; then + RANLIB=$save_RANLIB + fi + test -z "$concat_cmds" || concat_cmds=$concat_cmds~ + eval concat_cmds=\"\$concat_cmds$old_archive_cmds\" + objlist= + len=$len0 + fi + done + RANLIB=$save_RANLIB + oldobjs=$objlist + if test -z "$oldobjs"; then + eval cmds=\"\$concat_cmds\" + else + eval cmds=\"\$concat_cmds~\$old_archive_cmds\" + fi + fi + fi + func_execute_cmds "$cmds" 'exit $?' + done + + test -n "$generated" && \ + func_show_eval "${RM}r$generated" + + # Now create the libtool archive. + case $output in + *.la) + old_library= + test yes = "$build_old_libs" && old_library=$libname.$libext + func_verbose "creating $output" + + # Preserve any variables that may affect compiler behavior + for var in $variables_saved_for_relink; do + if eval test -z \"\${$var+set}\"; then + relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" + elif eval var_value=\$$var; test -z "$var_value"; then + relink_command="$var=; export $var; $relink_command" + else + func_quote_for_eval "$var_value" + relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command" + fi + done + # Quote the link command for shipping. + relink_command="(cd `pwd`; $SHELL \"$progpath\" $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)" + relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"` + if test yes = "$hardcode_automatic"; then + relink_command= + fi + + # Only create the output if not a dry run. + $opt_dry_run || { + for installed in no yes; do + if test yes = "$installed"; then + if test -z "$install_libdir"; then + break + fi + output=$output_objdir/${outputname}i + # Replace all uninstalled libtool libraries with the installed ones + newdependency_libs= + for deplib in $dependency_libs; do + case $deplib in + *.la) + func_basename "$deplib" + name=$func_basename_result + func_resolve_sysroot "$deplib" + eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $func_resolve_sysroot_result` + test -z "$libdir" && \ + func_fatal_error "'$deplib' is not a valid libtool archive" + func_append newdependency_libs " ${lt_sysroot:+=}$libdir/$name" + ;; + -L*) + func_stripname -L '' "$deplib" + func_replace_sysroot "$func_stripname_result" + func_append newdependency_libs " -L$func_replace_sysroot_result" + ;; + -R*) + func_stripname -R '' "$deplib" + func_replace_sysroot "$func_stripname_result" + func_append newdependency_libs " -R$func_replace_sysroot_result" + ;; + *) func_append newdependency_libs " $deplib" ;; + esac + done + dependency_libs=$newdependency_libs + newdlfiles= + + for lib in $dlfiles; do + case $lib in + *.la) + func_basename "$lib" + name=$func_basename_result + eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $lib` + test -z "$libdir" && \ + func_fatal_error "'$lib' is not a valid libtool archive" + func_append newdlfiles " ${lt_sysroot:+=}$libdir/$name" + ;; + *) func_append newdlfiles " $lib" ;; + esac + done + dlfiles=$newdlfiles + newdlprefiles= + for lib in $dlprefiles; do + case $lib in + *.la) + # Only pass preopened files to the pseudo-archive (for + # eventual linking with the app. that links it) if we + # didn't already link the preopened objects directly into + # the library: + func_basename "$lib" + name=$func_basename_result + eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $lib` + test -z "$libdir" && \ + func_fatal_error "'$lib' is not a valid libtool archive" + func_append newdlprefiles " ${lt_sysroot:+=}$libdir/$name" + ;; + esac + done + dlprefiles=$newdlprefiles + else + newdlfiles= + for lib in $dlfiles; do + case $lib in + [\\/]* | [A-Za-z]:[\\/]*) abs=$lib ;; + *) abs=`pwd`"/$lib" ;; + esac + func_append newdlfiles " $abs" + done + dlfiles=$newdlfiles + newdlprefiles= + for lib in $dlprefiles; do + case $lib in + [\\/]* | [A-Za-z]:[\\/]*) abs=$lib ;; + *) abs=`pwd`"/$lib" ;; + esac + func_append newdlprefiles " $abs" + done + dlprefiles=$newdlprefiles + fi + $RM $output + # place dlname in correct position for cygwin + # In fact, it would be nice if we could use this code for all target + # systems that can't hard-code library paths into their executables + # and that have no shared library path variable independent of PATH, + # but it turns out we can't easily determine that from inspecting + # libtool variables, so we have to hard-code the OSs to which it + # applies here; at the moment, that means platforms that use the PE + # object format with DLL files. See the long comment at the top of + # tests/bindir.at for full details. + tdlname=$dlname + case $host,$output,$installed,$module,$dlname in + *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll) + # If a -bindir argument was supplied, place the dll there. + if test -n "$bindir"; then + func_relative_path "$install_libdir" "$bindir" + tdlname=$func_relative_path_result/$dlname + else + # Otherwise fall back on heuristic. + tdlname=../bin/$dlname + fi + ;; + esac + $ECHO > $output "\ +# $outputname - a libtool library file +# Generated by $PROGRAM (GNU $PACKAGE) $VERSION +# +# Please DO NOT delete this file! +# It is necessary for linking the library. + +# The name that we can dlopen(3). +dlname='$tdlname' + +# Names of this library. +library_names='$library_names' + +# The name of the static archive. +old_library='$old_library' + +# Linker flags that cannot go in dependency_libs. +inherited_linker_flags='$new_inherited_linker_flags' + +# Libraries that this one depends upon. +dependency_libs='$dependency_libs' + +# Names of additional weak libraries provided by this library +weak_library_names='$weak_libs' + +# Version information for $libname. +current=$current +age=$age +revision=$revision + +# Is this an already installed library? +installed=$installed + +# Should we warn about portability when linking against -modules? +shouldnotlink=$module + +# Files to dlopen/dlpreopen +dlopen='$dlfiles' +dlpreopen='$dlprefiles' + +# Directory that this library needs to be installed in: +libdir='$install_libdir'" + if test no,yes = "$installed,$need_relink"; then + $ECHO >> $output "\ +relink_command=\"$relink_command\"" + fi + done + } + + # Do a symbolic link so that the libtool archive can be found in + # LD_LIBRARY_PATH before the program is installed. + func_show_eval '( cd "$output_objdir" && $RM "$outputname" && $LN_S "../$outputname" "$outputname" )' 'exit $?' + ;; + esac + exit $EXIT_SUCCESS +} + +if test link = "$opt_mode" || test relink = "$opt_mode"; then + func_mode_link ${1+"$@"} +fi + + +# func_mode_uninstall arg... +func_mode_uninstall () +{ + $debug_cmd + + RM=$nonopt + files= + rmforce=false + exit_status=0 + + # This variable tells wrapper scripts just to set variables rather + # than running their programs. + libtool_install_magic=$magic + + for arg + do + case $arg in + -f) func_append RM " $arg"; rmforce=: ;; + -*) func_append RM " $arg" ;; + *) func_append files " $arg" ;; + esac + done + + test -z "$RM" && \ + func_fatal_help "you must specify an RM program" + + rmdirs= + + for file in $files; do + func_dirname "$file" "" "." + dir=$func_dirname_result + if test . = "$dir"; then + odir=$objdir + else + odir=$dir/$objdir + fi + func_basename "$file" + name=$func_basename_result + test uninstall = "$opt_mode" && odir=$dir + + # Remember odir for removal later, being careful to avoid duplicates + if test clean = "$opt_mode"; then + case " $rmdirs " in + *" $odir "*) ;; + *) func_append rmdirs " $odir" ;; + esac + fi + + # Don't error if the file doesn't exist and rm -f was used. + if { test -L "$file"; } >/dev/null 2>&1 || + { test -h "$file"; } >/dev/null 2>&1 || + test -f "$file"; then + : + elif test -d "$file"; then + exit_status=1 + continue + elif $rmforce; then + continue + fi + + rmfiles=$file + + case $name in + *.la) + # Possibly a libtool archive, so verify it. + if func_lalib_p "$file"; then + func_source $dir/$name + + # Delete the libtool libraries and symlinks. + for n in $library_names; do + func_append rmfiles " $odir/$n" + done + test -n "$old_library" && func_append rmfiles " $odir/$old_library" + + case $opt_mode in + clean) + case " $library_names " in + *" $dlname "*) ;; + *) test -n "$dlname" && func_append rmfiles " $odir/$dlname" ;; + esac + test -n "$libdir" && func_append rmfiles " $odir/$name $odir/${name}i" + ;; + uninstall) + if test -n "$library_names"; then + # Do each command in the postuninstall commands. + func_execute_cmds "$postuninstall_cmds" '$rmforce || exit_status=1' + fi + + if test -n "$old_library"; then + # Do each command in the old_postuninstall commands. + func_execute_cmds "$old_postuninstall_cmds" '$rmforce || exit_status=1' + fi + # FIXME: should reinstall the best remaining shared library. + ;; + esac + fi + ;; + + *.lo) + # Possibly a libtool object, so verify it. + if func_lalib_p "$file"; then + + # Read the .lo file + func_source $dir/$name + + # Add PIC object to the list of files to remove. + if test -n "$pic_object" && test none != "$pic_object"; then + func_append rmfiles " $dir/$pic_object" + fi + + # Add non-PIC object to the list of files to remove. + if test -n "$non_pic_object" && test none != "$non_pic_object"; then + func_append rmfiles " $dir/$non_pic_object" + fi + fi + ;; + + *) + if test clean = "$opt_mode"; then + noexename=$name + case $file in + *.exe) + func_stripname '' '.exe' "$file" + file=$func_stripname_result + func_stripname '' '.exe' "$name" + noexename=$func_stripname_result + # $file with .exe has already been added to rmfiles, + # add $file without .exe + func_append rmfiles " $file" + ;; + esac + # Do a test to see if this is a libtool program. + if func_ltwrapper_p "$file"; then + if func_ltwrapper_executable_p "$file"; then + func_ltwrapper_scriptname "$file" + relink_command= + func_source $func_ltwrapper_scriptname_result + func_append rmfiles " $func_ltwrapper_scriptname_result" + else + relink_command= + func_source $dir/$noexename + fi + + # note $name still contains .exe if it was in $file originally + # as does the version of $file that was added into $rmfiles + func_append rmfiles " $odir/$name $odir/${name}S.$objext" + if test yes = "$fast_install" && test -n "$relink_command"; then + func_append rmfiles " $odir/lt-$name" + fi + if test "X$noexename" != "X$name"; then + func_append rmfiles " $odir/lt-$noexename.c" + fi + fi + fi + ;; + esac + func_show_eval "$RM $rmfiles" 'exit_status=1' + done + + # Try to remove the $objdir's in the directories where we deleted files + for dir in $rmdirs; do + if test -d "$dir"; then + func_show_eval "rmdir $dir >/dev/null 2>&1" + fi + done + + exit $exit_status +} + +if test uninstall = "$opt_mode" || test clean = "$opt_mode"; then + func_mode_uninstall ${1+"$@"} +fi + +test -z "$opt_mode" && { + help=$generic_help + func_fatal_help "you must specify a MODE" +} + +test -z "$exec_cmd" && \ + func_fatal_help "invalid operation mode '$opt_mode'" + +if test -n "$exec_cmd"; then + eval exec "$exec_cmd" + exit $EXIT_FAILURE +fi + +exit $exit_status + + +# The TAGs below are defined such that we never get into a situation +# where we disable both kinds of libraries. Given conflicting +# choices, we go for a static library, that is the most portable, +# since we can't tell whether shared libraries were disabled because +# the user asked for that or because the platform doesn't support +# them. This is particularly important on AIX, because we don't +# support having both static and shared libraries enabled at the same +# time on that platform, so we default to a shared-only configuration. +# If a disable-shared tag is given, we'll fallback to a static-only +# configuration. But we'll never go from static-only to shared-only. + +# ### BEGIN LIBTOOL TAG CONFIG: disable-shared +build_libtool_libs=no +build_old_libs=yes +# ### END LIBTOOL TAG CONFIG: disable-shared + +# ### BEGIN LIBTOOL TAG CONFIG: disable-static +build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac` +# ### END LIBTOOL TAG CONFIG: disable-static + +# Local Variables: +# mode:shell-script +# sh-indentation:2 +# End: diff --git a/libs/ode-0.16.1/m4/libtool.m4 b/libs/ode-0.16.1/m4/libtool.m4 new file mode 100644 index 0000000..10ab284 --- /dev/null +++ b/libs/ode-0.16.1/m4/libtool.m4 @@ -0,0 +1,8388 @@ +# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- +# +# Copyright (C) 1996-2001, 2003-2015 Free Software Foundation, Inc. +# Written by Gordon Matzigkeit, 1996 +# +# This file is free software; the Free Software Foundation gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. + +m4_define([_LT_COPYING], [dnl +# Copyright (C) 2014 Free Software Foundation, Inc. +# This is free software; see the source for copying conditions. There is NO +# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + +# GNU Libtool is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of of the License, or +# (at your option) any later version. +# +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program or library that is built +# using GNU Libtool, you may include this file under the same +# distribution terms that you use for the rest of that program. +# +# GNU Libtool is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . +]) + +# serial 58 LT_INIT + + +# LT_PREREQ(VERSION) +# ------------------ +# Complain and exit if this libtool version is less that VERSION. +m4_defun([LT_PREREQ], +[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1, + [m4_default([$3], + [m4_fatal([Libtool version $1 or higher is required], + 63)])], + [$2])]) + + +# _LT_CHECK_BUILDDIR +# ------------------ +# Complain if the absolute build directory name contains unusual characters +m4_defun([_LT_CHECK_BUILDDIR], +[case `pwd` in + *\ * | *\ *) + AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;; +esac +]) + + +# LT_INIT([OPTIONS]) +# ------------------ +AC_DEFUN([LT_INIT], +[AC_PREREQ([2.62])dnl We use AC_PATH_PROGS_FEATURE_CHECK +AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl +AC_BEFORE([$0], [LT_LANG])dnl +AC_BEFORE([$0], [LT_OUTPUT])dnl +AC_BEFORE([$0], [LTDL_INIT])dnl +m4_require([_LT_CHECK_BUILDDIR])dnl + +dnl Autoconf doesn't catch unexpanded LT_ macros by default: +m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl +m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl +dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4 +dnl unless we require an AC_DEFUNed macro: +AC_REQUIRE([LTOPTIONS_VERSION])dnl +AC_REQUIRE([LTSUGAR_VERSION])dnl +AC_REQUIRE([LTVERSION_VERSION])dnl +AC_REQUIRE([LTOBSOLETE_VERSION])dnl +m4_require([_LT_PROG_LTMAIN])dnl + +_LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}]) + +dnl Parse OPTIONS +_LT_SET_OPTIONS([$0], [$1]) + +# This can be used to rebuild libtool when needed +LIBTOOL_DEPS=$ltmain + +# Always use our own libtool. +LIBTOOL='$(SHELL) $(top_builddir)/libtool' +AC_SUBST(LIBTOOL)dnl + +_LT_SETUP + +# Only expand once: +m4_define([LT_INIT]) +])# LT_INIT + +# Old names: +AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT]) +AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_PROG_LIBTOOL], []) +dnl AC_DEFUN([AM_PROG_LIBTOOL], []) + + +# _LT_PREPARE_CC_BASENAME +# ----------------------- +m4_defun([_LT_PREPARE_CC_BASENAME], [ +# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. +func_cc_basename () +{ + for cc_temp in @S|@*""; do + case $cc_temp in + compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; + distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; + \-*) ;; + *) break;; + esac + done + func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` +} +])# _LT_PREPARE_CC_BASENAME + + +# _LT_CC_BASENAME(CC) +# ------------------- +# It would be clearer to call AC_REQUIREs from _LT_PREPARE_CC_BASENAME, +# but that macro is also expanded into generated libtool script, which +# arranges for $SED and $ECHO to be set by different means. +m4_defun([_LT_CC_BASENAME], +[m4_require([_LT_PREPARE_CC_BASENAME])dnl +AC_REQUIRE([_LT_DECL_SED])dnl +AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl +func_cc_basename $1 +cc_basename=$func_cc_basename_result +]) + + +# _LT_FILEUTILS_DEFAULTS +# ---------------------- +# It is okay to use these file commands and assume they have been set +# sensibly after 'm4_require([_LT_FILEUTILS_DEFAULTS])'. +m4_defun([_LT_FILEUTILS_DEFAULTS], +[: ${CP="cp -f"} +: ${MV="mv -f"} +: ${RM="rm -f"} +])# _LT_FILEUTILS_DEFAULTS + + +# _LT_SETUP +# --------- +m4_defun([_LT_SETUP], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +AC_REQUIRE([AC_CANONICAL_BUILD])dnl +AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl +AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl + +_LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl +dnl +_LT_DECL([], [host_alias], [0], [The host system])dnl +_LT_DECL([], [host], [0])dnl +_LT_DECL([], [host_os], [0])dnl +dnl +_LT_DECL([], [build_alias], [0], [The build system])dnl +_LT_DECL([], [build], [0])dnl +_LT_DECL([], [build_os], [0])dnl +dnl +AC_REQUIRE([AC_PROG_CC])dnl +AC_REQUIRE([LT_PATH_LD])dnl +AC_REQUIRE([LT_PATH_NM])dnl +dnl +AC_REQUIRE([AC_PROG_LN_S])dnl +test -z "$LN_S" && LN_S="ln -s" +_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl +dnl +AC_REQUIRE([LT_CMD_MAX_LEN])dnl +_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl +_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl +dnl +m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_CHECK_SHELL_FEATURES])dnl +m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl +m4_require([_LT_CMD_RELOAD])dnl +m4_require([_LT_CHECK_MAGIC_METHOD])dnl +m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl +m4_require([_LT_CMD_OLD_ARCHIVE])dnl +m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl +m4_require([_LT_WITH_SYSROOT])dnl +m4_require([_LT_CMD_TRUNCATE])dnl + +_LT_CONFIG_LIBTOOL_INIT([ +# See if we are running on zsh, and set the options that allow our +# commands through without removal of \ escapes INIT. +if test -n "\${ZSH_VERSION+set}"; then + setopt NO_GLOB_SUBST +fi +]) +if test -n "${ZSH_VERSION+set}"; then + setopt NO_GLOB_SUBST +fi + +_LT_CHECK_OBJDIR + +m4_require([_LT_TAG_COMPILER])dnl + +case $host_os in +aix3*) + # AIX sometimes has problems with the GCC collect2 program. For some + # reason, if we set the COLLECT_NAMES environment variable, the problems + # vanish in a puff of smoke. + if test set != "${COLLECT_NAMES+set}"; then + COLLECT_NAMES= + export COLLECT_NAMES + fi + ;; +esac + +# Global variables: +ofile=libtool +can_build_shared=yes + +# All known linkers require a '.a' archive for static linking (except MSVC, +# which needs '.lib'). +libext=a + +with_gnu_ld=$lt_cv_prog_gnu_ld + +old_CC=$CC +old_CFLAGS=$CFLAGS + +# Set sane defaults for various variables +test -z "$CC" && CC=cc +test -z "$LTCC" && LTCC=$CC +test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS +test -z "$LD" && LD=ld +test -z "$ac_objext" && ac_objext=o + +_LT_CC_BASENAME([$compiler]) + +# Only perform the check for file, if the check method requires it +test -z "$MAGIC_CMD" && MAGIC_CMD=file +case $deplibs_check_method in +file_magic*) + if test "$file_magic_cmd" = '$MAGIC_CMD'; then + _LT_PATH_MAGIC + fi + ;; +esac + +# Use C for the default configuration in the libtool script +LT_SUPPORTED_TAG([CC]) +_LT_LANG_C_CONFIG +_LT_LANG_DEFAULT_CONFIG +_LT_CONFIG_COMMANDS +])# _LT_SETUP + + +# _LT_PREPARE_SED_QUOTE_VARS +# -------------------------- +# Define a few sed substitution that help us do robust quoting. +m4_defun([_LT_PREPARE_SED_QUOTE_VARS], +[# Backslashify metacharacters that are still active within +# double-quoted strings. +sed_quote_subst='s/\([["`$\\]]\)/\\\1/g' + +# Same as above, but do not quote variable references. +double_quote_subst='s/\([["`\\]]\)/\\\1/g' + +# Sed substitution to delay expansion of an escaped shell variable in a +# double_quote_subst'ed string. +delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' + +# Sed substitution to delay expansion of an escaped single quote. +delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' + +# Sed substitution to avoid accidental globbing in evaled expressions +no_glob_subst='s/\*/\\\*/g' +]) + +# _LT_PROG_LTMAIN +# --------------- +# Note that this code is called both from 'configure', and 'config.status' +# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, +# 'config.status' has no value for ac_aux_dir unless we are using Automake, +# so we pass a copy along to make sure it has a sensible value anyway. +m4_defun([_LT_PROG_LTMAIN], +[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl +_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) +ltmain=$ac_aux_dir/ltmain.sh +])# _LT_PROG_LTMAIN + + +## ------------------------------------- ## +## Accumulate code for creating libtool. ## +## ------------------------------------- ## + +# So that we can recreate a full libtool script including additional +# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS +# in macros and then make a single call at the end using the 'libtool' +# label. + + +# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS]) +# ---------------------------------------- +# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later. +m4_define([_LT_CONFIG_LIBTOOL_INIT], +[m4_ifval([$1], + [m4_append([_LT_OUTPUT_LIBTOOL_INIT], + [$1 +])])]) + +# Initialize. +m4_define([_LT_OUTPUT_LIBTOOL_INIT]) + + +# _LT_CONFIG_LIBTOOL([COMMANDS]) +# ------------------------------ +# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later. +m4_define([_LT_CONFIG_LIBTOOL], +[m4_ifval([$1], + [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS], + [$1 +])])]) + +# Initialize. +m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS]) + + +# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS]) +# ----------------------------------------------------- +m4_defun([_LT_CONFIG_SAVE_COMMANDS], +[_LT_CONFIG_LIBTOOL([$1]) +_LT_CONFIG_LIBTOOL_INIT([$2]) +]) + + +# _LT_FORMAT_COMMENT([COMMENT]) +# ----------------------------- +# Add leading comment marks to the start of each line, and a trailing +# full-stop to the whole comment if one is not present already. +m4_define([_LT_FORMAT_COMMENT], +[m4_ifval([$1], [ +m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])], + [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.]) +)]) + + + +## ------------------------ ## +## FIXME: Eliminate VARNAME ## +## ------------------------ ## + + +# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?]) +# ------------------------------------------------------------------- +# CONFIGNAME is the name given to the value in the libtool script. +# VARNAME is the (base) name used in the configure script. +# VALUE may be 0, 1 or 2 for a computed quote escaped value based on +# VARNAME. Any other value will be used directly. +m4_define([_LT_DECL], +[lt_if_append_uniq([lt_decl_varnames], [$2], [, ], + [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name], + [m4_ifval([$1], [$1], [$2])]) + lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3]) + m4_ifval([$4], + [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])]) + lt_dict_add_subkey([lt_decl_dict], [$2], + [tagged?], [m4_ifval([$5], [yes], [no])])]) +]) + + +# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION]) +# -------------------------------------------------------- +m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])]) + + +# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...]) +# ------------------------------------------------ +m4_define([lt_decl_tag_varnames], +[_lt_decl_filter([tagged?], [yes], $@)]) + + +# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..]) +# --------------------------------------------------------- +m4_define([_lt_decl_filter], +[m4_case([$#], + [0], [m4_fatal([$0: too few arguments: $#])], + [1], [m4_fatal([$0: too few arguments: $#: $1])], + [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)], + [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)], + [lt_dict_filter([lt_decl_dict], $@)])[]dnl +]) + + +# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...]) +# -------------------------------------------------- +m4_define([lt_decl_quote_varnames], +[_lt_decl_filter([value], [1], $@)]) + + +# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...]) +# --------------------------------------------------- +m4_define([lt_decl_dquote_varnames], +[_lt_decl_filter([value], [2], $@)]) + + +# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) +# --------------------------------------------------- +m4_define([lt_decl_varnames_tagged], +[m4_assert([$# <= 2])dnl +_$0(m4_quote(m4_default([$1], [[, ]])), + m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]), + m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))]) +m4_define([_lt_decl_varnames_tagged], +[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])]) + + +# lt_decl_all_varnames([SEPARATOR], [VARNAME1...]) +# ------------------------------------------------ +m4_define([lt_decl_all_varnames], +[_$0(m4_quote(m4_default([$1], [[, ]])), + m4_if([$2], [], + m4_quote(lt_decl_varnames), + m4_quote(m4_shift($@))))[]dnl +]) +m4_define([_lt_decl_all_varnames], +[lt_join($@, lt_decl_varnames_tagged([$1], + lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl +]) + + +# _LT_CONFIG_STATUS_DECLARE([VARNAME]) +# ------------------------------------ +# Quote a variable value, and forward it to 'config.status' so that its +# declaration there will have the same value as in 'configure'. VARNAME +# must have a single quote delimited value for this to work. +m4_define([_LT_CONFIG_STATUS_DECLARE], +[$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`']) + + +# _LT_CONFIG_STATUS_DECLARATIONS +# ------------------------------ +# We delimit libtool config variables with single quotes, so when +# we write them to config.status, we have to be sure to quote all +# embedded single quotes properly. In configure, this macro expands +# each variable declared with _LT_DECL (and _LT_TAGDECL) into: +# +# ='`$ECHO "$" | $SED "$delay_single_quote_subst"`' +m4_defun([_LT_CONFIG_STATUS_DECLARATIONS], +[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames), + [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])]) + + +# _LT_LIBTOOL_TAGS +# ---------------- +# Output comment and list of tags supported by the script +m4_defun([_LT_LIBTOOL_TAGS], +[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl +available_tags='_LT_TAGS'dnl +]) + + +# _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) +# ----------------------------------- +# Extract the dictionary values for VARNAME (optionally with TAG) and +# expand to a commented shell variable setting: +# +# # Some comment about what VAR is for. +# visible_name=$lt_internal_name +m4_define([_LT_LIBTOOL_DECLARE], +[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], + [description])))[]dnl +m4_pushdef([_libtool_name], + m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl +m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])), + [0], [_libtool_name=[$]$1], + [1], [_libtool_name=$lt_[]$1], + [2], [_libtool_name=$lt_[]$1], + [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl +m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl +]) + + +# _LT_LIBTOOL_CONFIG_VARS +# ----------------------- +# Produce commented declarations of non-tagged libtool config variables +# suitable for insertion in the LIBTOOL CONFIG section of the 'libtool' +# script. Tagged libtool config variables (even for the LIBTOOL CONFIG +# section) are produced by _LT_LIBTOOL_TAG_VARS. +m4_defun([_LT_LIBTOOL_CONFIG_VARS], +[m4_foreach([_lt_var], + m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)), + [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])]) + + +# _LT_LIBTOOL_TAG_VARS(TAG) +# ------------------------- +m4_define([_LT_LIBTOOL_TAG_VARS], +[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames), + [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])]) + + +# _LT_TAGVAR(VARNAME, [TAGNAME]) +# ------------------------------ +m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) + + +# _LT_CONFIG_COMMANDS +# ------------------- +# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of +# variables for single and double quote escaping we saved from calls +# to _LT_DECL, we can put quote escaped variables declarations +# into 'config.status', and then the shell code to quote escape them in +# for loops in 'config.status'. Finally, any additional code accumulated +# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. +m4_defun([_LT_CONFIG_COMMANDS], +[AC_PROVIDE_IFELSE([LT_OUTPUT], + dnl If the libtool generation code has been placed in $CONFIG_LT, + dnl instead of duplicating it all over again into config.status, + dnl then we will have config.status run $CONFIG_LT later, so it + dnl needs to know what name is stored there: + [AC_CONFIG_COMMANDS([libtool], + [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])], + dnl If the libtool generation code is destined for config.status, + dnl expand the accumulated commands and init code now: + [AC_CONFIG_COMMANDS([libtool], + [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])]) +])#_LT_CONFIG_COMMANDS + + +# Initialize. +m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT], +[ + +# The HP-UX ksh and POSIX shell print the target directory to stdout +# if CDPATH is set. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + +sed_quote_subst='$sed_quote_subst' +double_quote_subst='$double_quote_subst' +delay_variable_subst='$delay_variable_subst' +_LT_CONFIG_STATUS_DECLARATIONS +LTCC='$LTCC' +LTCFLAGS='$LTCFLAGS' +compiler='$compiler_DEFAULT' + +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +\$[]1 +_LTECHO_EOF' +} + +# Quote evaled strings. +for var in lt_decl_all_varnames([[ \ +]], lt_decl_quote_varnames); do + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in + *[[\\\\\\\`\\"\\\$]]*) + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes + ;; + *) + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" + ;; + esac +done + +# Double-quote double-evaled strings. +for var in lt_decl_all_varnames([[ \ +]], lt_decl_dquote_varnames); do + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in + *[[\\\\\\\`\\"\\\$]]*) + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes + ;; + *) + eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" + ;; + esac +done + +_LT_OUTPUT_LIBTOOL_INIT +]) + +# _LT_GENERATED_FILE_INIT(FILE, [COMMENT]) +# ------------------------------------ +# Generate a child script FILE with all initialization necessary to +# reuse the environment learned by the parent script, and make the +# file executable. If COMMENT is supplied, it is inserted after the +# '#!' sequence but before initialization text begins. After this +# macro, additional text can be appended to FILE to form the body of +# the child script. The macro ends with non-zero status if the +# file could not be fully written (such as if the disk is full). +m4_ifdef([AS_INIT_GENERATED], +[m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])], +[m4_defun([_LT_GENERATED_FILE_INIT], +[m4_require([AS_PREPARE])]dnl +[m4_pushdef([AS_MESSAGE_LOG_FD])]dnl +[lt_write_fail=0 +cat >$1 <<_ASEOF || lt_write_fail=1 +#! $SHELL +# Generated by $as_me. +$2 +SHELL=\${CONFIG_SHELL-$SHELL} +export SHELL +_ASEOF +cat >>$1 <<\_ASEOF || lt_write_fail=1 +AS_SHELL_SANITIZE +_AS_PREPARE +exec AS_MESSAGE_FD>&1 +_ASEOF +test 0 = "$lt_write_fail" && chmod +x $1[]dnl +m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT + +# LT_OUTPUT +# --------- +# This macro allows early generation of the libtool script (before +# AC_OUTPUT is called), incase it is used in configure for compilation +# tests. +AC_DEFUN([LT_OUTPUT], +[: ${CONFIG_LT=./config.lt} +AC_MSG_NOTICE([creating $CONFIG_LT]) +_LT_GENERATED_FILE_INIT(["$CONFIG_LT"], +[# Run this file to recreate a libtool stub with the current configuration.]) + +cat >>"$CONFIG_LT" <<\_LTEOF +lt_cl_silent=false +exec AS_MESSAGE_LOG_FD>>config.log +{ + echo + AS_BOX([Running $as_me.]) +} >&AS_MESSAGE_LOG_FD + +lt_cl_help="\ +'$as_me' creates a local libtool stub from the current configuration, +for use in further configure time tests before the real libtool is +generated. + +Usage: $[0] [[OPTIONS]] + + -h, --help print this help, then exit + -V, --version print version number, then exit + -q, --quiet do not print progress messages + -d, --debug don't remove temporary files + +Report bugs to ." + +lt_cl_version="\ +m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl +m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) +configured by $[0], generated by m4_PACKAGE_STRING. + +Copyright (C) 2011 Free Software Foundation, Inc. +This config.lt script is free software; the Free Software Foundation +gives unlimited permision to copy, distribute and modify it." + +while test 0 != $[#] +do + case $[1] in + --version | --v* | -V ) + echo "$lt_cl_version"; exit 0 ;; + --help | --h* | -h ) + echo "$lt_cl_help"; exit 0 ;; + --debug | --d* | -d ) + debug=: ;; + --quiet | --q* | --silent | --s* | -q ) + lt_cl_silent=: ;; + + -*) AC_MSG_ERROR([unrecognized option: $[1] +Try '$[0] --help' for more information.]) ;; + + *) AC_MSG_ERROR([unrecognized argument: $[1] +Try '$[0] --help' for more information.]) ;; + esac + shift +done + +if $lt_cl_silent; then + exec AS_MESSAGE_FD>/dev/null +fi +_LTEOF + +cat >>"$CONFIG_LT" <<_LTEOF +_LT_OUTPUT_LIBTOOL_COMMANDS_INIT +_LTEOF + +cat >>"$CONFIG_LT" <<\_LTEOF +AC_MSG_NOTICE([creating $ofile]) +_LT_OUTPUT_LIBTOOL_COMMANDS +AS_EXIT(0) +_LTEOF +chmod +x "$CONFIG_LT" + +# configure is writing to config.log, but config.lt does its own redirection, +# appending to config.log, which fails on DOS, as config.log is still kept +# open by configure. Here we exec the FD to /dev/null, effectively closing +# config.log, so it can be properly (re)opened and appended to by config.lt. +lt_cl_success=: +test yes = "$silent" && + lt_config_lt_args="$lt_config_lt_args --quiet" +exec AS_MESSAGE_LOG_FD>/dev/null +$SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false +exec AS_MESSAGE_LOG_FD>>config.log +$lt_cl_success || AS_EXIT(1) +])# LT_OUTPUT + + +# _LT_CONFIG(TAG) +# --------------- +# If TAG is the built-in tag, create an initial libtool script with a +# default configuration from the untagged config vars. Otherwise add code +# to config.status for appending the configuration named by TAG from the +# matching tagged config vars. +m4_defun([_LT_CONFIG], +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl +_LT_CONFIG_SAVE_COMMANDS([ + m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl + m4_if(_LT_TAG, [C], [ + # See if we are running on zsh, and set the options that allow our + # commands through without removal of \ escapes. + if test -n "${ZSH_VERSION+set}"; then + setopt NO_GLOB_SUBST + fi + + cfgfile=${ofile}T + trap "$RM \"$cfgfile\"; exit 1" 1 2 15 + $RM "$cfgfile" + + cat <<_LT_EOF >> "$cfgfile" +#! $SHELL +# Generated automatically by $as_me ($PACKAGE) $VERSION +# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +# NOTE: Changes made to this file will be lost: look at ltmain.sh. + +# Provide generalized library-building support services. +# Written by Gordon Matzigkeit, 1996 + +_LT_COPYING +_LT_LIBTOOL_TAGS + +# Configured defaults for sys_lib_dlsearch_path munging. +: \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"} + +# ### BEGIN LIBTOOL CONFIG +_LT_LIBTOOL_CONFIG_VARS +_LT_LIBTOOL_TAG_VARS +# ### END LIBTOOL CONFIG + +_LT_EOF + + cat <<'_LT_EOF' >> "$cfgfile" + +# ### BEGIN FUNCTIONS SHARED WITH CONFIGURE + +_LT_PREPARE_MUNGE_PATH_LIST +_LT_PREPARE_CC_BASENAME + +# ### END FUNCTIONS SHARED WITH CONFIGURE + +_LT_EOF + + case $host_os in + aix3*) + cat <<\_LT_EOF >> "$cfgfile" +# AIX sometimes has problems with the GCC collect2 program. For some +# reason, if we set the COLLECT_NAMES environment variable, the problems +# vanish in a puff of smoke. +if test set != "${COLLECT_NAMES+set}"; then + COLLECT_NAMES= + export COLLECT_NAMES +fi +_LT_EOF + ;; + esac + + _LT_PROG_LTMAIN + + # We use sed instead of cat because bash on DJGPP gets confused if + # if finds mixed CR/LF and LF-only lines. Since sed operates in + # text mode, it properly converts lines to CR/LF. This bash problem + # is reportedly fixed, but why not run on old versions too? + sed '$q' "$ltmain" >> "$cfgfile" \ + || (rm -f "$cfgfile"; exit 1) + + mv -f "$cfgfile" "$ofile" || + (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") + chmod +x "$ofile" +], +[cat <<_LT_EOF >> "$ofile" + +dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded +dnl in a comment (ie after a #). +# ### BEGIN LIBTOOL TAG CONFIG: $1 +_LT_LIBTOOL_TAG_VARS(_LT_TAG) +# ### END LIBTOOL TAG CONFIG: $1 +_LT_EOF +])dnl /m4_if +], +[m4_if([$1], [], [ + PACKAGE='$PACKAGE' + VERSION='$VERSION' + RM='$RM' + ofile='$ofile'], []) +])dnl /_LT_CONFIG_SAVE_COMMANDS +])# _LT_CONFIG + + +# LT_SUPPORTED_TAG(TAG) +# --------------------- +# Trace this macro to discover what tags are supported by the libtool +# --tag option, using: +# autoconf --trace 'LT_SUPPORTED_TAG:$1' +AC_DEFUN([LT_SUPPORTED_TAG], []) + + +# C support is built-in for now +m4_define([_LT_LANG_C_enabled], []) +m4_define([_LT_TAGS], []) + + +# LT_LANG(LANG) +# ------------- +# Enable libtool support for the given language if not already enabled. +AC_DEFUN([LT_LANG], +[AC_BEFORE([$0], [LT_OUTPUT])dnl +m4_case([$1], + [C], [_LT_LANG(C)], + [C++], [_LT_LANG(CXX)], + [Go], [_LT_LANG(GO)], + [Java], [_LT_LANG(GCJ)], + [Fortran 77], [_LT_LANG(F77)], + [Fortran], [_LT_LANG(FC)], + [Windows Resource], [_LT_LANG(RC)], + [m4_ifdef([_LT_LANG_]$1[_CONFIG], + [_LT_LANG($1)], + [m4_fatal([$0: unsupported language: "$1"])])])dnl +])# LT_LANG + + +# _LT_LANG(LANGNAME) +# ------------------ +m4_defun([_LT_LANG], +[m4_ifdef([_LT_LANG_]$1[_enabled], [], + [LT_SUPPORTED_TAG([$1])dnl + m4_append([_LT_TAGS], [$1 ])dnl + m4_define([_LT_LANG_]$1[_enabled], [])dnl + _LT_LANG_$1_CONFIG($1)])dnl +])# _LT_LANG + + +m4_ifndef([AC_PROG_GO], [ +############################################################ +# NOTE: This macro has been submitted for inclusion into # +# GNU Autoconf as AC_PROG_GO. When it is available in # +# a released version of Autoconf we should remove this # +# macro and use it instead. # +############################################################ +m4_defun([AC_PROG_GO], +[AC_LANG_PUSH(Go)dnl +AC_ARG_VAR([GOC], [Go compiler command])dnl +AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl +_AC_ARG_VAR_LDFLAGS()dnl +AC_CHECK_TOOL(GOC, gccgo) +if test -z "$GOC"; then + if test -n "$ac_tool_prefix"; then + AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo]) + fi +fi +if test -z "$GOC"; then + AC_CHECK_PROG(GOC, gccgo, gccgo, false) +fi +])#m4_defun +])#m4_ifndef + + +# _LT_LANG_DEFAULT_CONFIG +# ----------------------- +m4_defun([_LT_LANG_DEFAULT_CONFIG], +[AC_PROVIDE_IFELSE([AC_PROG_CXX], + [LT_LANG(CXX)], + [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])]) + +AC_PROVIDE_IFELSE([AC_PROG_F77], + [LT_LANG(F77)], + [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])]) + +AC_PROVIDE_IFELSE([AC_PROG_FC], + [LT_LANG(FC)], + [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])]) + +dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal +dnl pulling things in needlessly. +AC_PROVIDE_IFELSE([AC_PROG_GCJ], + [LT_LANG(GCJ)], + [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], + [LT_LANG(GCJ)], + [AC_PROVIDE_IFELSE([LT_PROG_GCJ], + [LT_LANG(GCJ)], + [m4_ifdef([AC_PROG_GCJ], + [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])]) + m4_ifdef([A][M_PROG_GCJ], + [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])]) + m4_ifdef([LT_PROG_GCJ], + [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])]) + +AC_PROVIDE_IFELSE([AC_PROG_GO], + [LT_LANG(GO)], + [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])]) + +AC_PROVIDE_IFELSE([LT_PROG_RC], + [LT_LANG(RC)], + [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])]) +])# _LT_LANG_DEFAULT_CONFIG + +# Obsolete macros: +AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)]) +AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)]) +AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)]) +AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)]) +AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_CXX], []) +dnl AC_DEFUN([AC_LIBTOOL_F77], []) +dnl AC_DEFUN([AC_LIBTOOL_FC], []) +dnl AC_DEFUN([AC_LIBTOOL_GCJ], []) +dnl AC_DEFUN([AC_LIBTOOL_RC], []) + + +# _LT_TAG_COMPILER +# ---------------- +m4_defun([_LT_TAG_COMPILER], +[AC_REQUIRE([AC_PROG_CC])dnl + +_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl +_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl +_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl +_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl + +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} + +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC +])# _LT_TAG_COMPILER + + +# _LT_COMPILER_BOILERPLATE +# ------------------------ +# Check for compiler boilerplate output or warnings with +# the simple compiler test code. +m4_defun([_LT_COMPILER_BOILERPLATE], +[m4_require([_LT_DECL_SED])dnl +ac_outfile=conftest.$ac_objext +echo "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$RM conftest* +])# _LT_COMPILER_BOILERPLATE + + +# _LT_LINKER_BOILERPLATE +# ---------------------- +# Check for linker boilerplate output or warnings with +# the simple link test code. +m4_defun([_LT_LINKER_BOILERPLATE], +[m4_require([_LT_DECL_SED])dnl +ac_outfile=conftest.$ac_objext +echo "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$RM -r conftest* +])# _LT_LINKER_BOILERPLATE + +# _LT_REQUIRED_DARWIN_CHECKS +# ------------------------- +m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ + case $host_os in + rhapsody* | darwin*) + AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) + AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) + AC_CHECK_TOOL([LIPO], [lipo], [:]) + AC_CHECK_TOOL([OTOOL], [otool], [:]) + AC_CHECK_TOOL([OTOOL64], [otool64], [:]) + _LT_DECL([], [DSYMUTIL], [1], + [Tool to manipulate archived DWARF debug symbol files on Mac OS X]) + _LT_DECL([], [NMEDIT], [1], + [Tool to change global to local symbols on Mac OS X]) + _LT_DECL([], [LIPO], [1], + [Tool to manipulate fat objects and archives on Mac OS X]) + _LT_DECL([], [OTOOL], [1], + [ldd/readelf like tool for Mach-O binaries on Mac OS X]) + _LT_DECL([], [OTOOL64], [1], + [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4]) + + AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], + [lt_cv_apple_cc_single_mod=no + if test -z "$LT_MULTI_MODULE"; then + # By default we will add the -single_module flag. You can override + # by either setting the environment variable LT_MULTI_MODULE + # non-empty at configure time, or by adding -multi_module to the + # link flags. + rm -rf libconftest.dylib* + echo "int foo(void){return 1;}" > conftest.c + echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ +-dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD + $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ + -dynamiclib -Wl,-single_module conftest.c 2>conftest.err + _lt_result=$? + # If there is a non-empty error log, and "single_module" + # appears in it, assume the flag caused a linker warning + if test -s conftest.err && $GREP single_module conftest.err; then + cat conftest.err >&AS_MESSAGE_LOG_FD + # Otherwise, if the output was created with a 0 exit code from + # the compiler, it worked. + elif test -f libconftest.dylib && test 0 = "$_lt_result"; then + lt_cv_apple_cc_single_mod=yes + else + cat conftest.err >&AS_MESSAGE_LOG_FD + fi + rm -rf libconftest.dylib* + rm -f conftest.* + fi]) + + AC_CACHE_CHECK([for -exported_symbols_list linker flag], + [lt_cv_ld_exported_symbols_list], + [lt_cv_ld_exported_symbols_list=no + save_LDFLAGS=$LDFLAGS + echo "_main" > conftest.sym + LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" + AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], + [lt_cv_ld_exported_symbols_list=yes], + [lt_cv_ld_exported_symbols_list=no]) + LDFLAGS=$save_LDFLAGS + ]) + + AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], + [lt_cv_ld_force_load=no + cat > conftest.c << _LT_EOF +int forced_loaded() { return 2;} +_LT_EOF + echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD + $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD + echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD + $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD + echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD + $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD + cat > conftest.c << _LT_EOF +int main() { return 0;} +_LT_EOF + echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD + $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err + _lt_result=$? + if test -s conftest.err && $GREP force_load conftest.err; then + cat conftest.err >&AS_MESSAGE_LOG_FD + elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then + lt_cv_ld_force_load=yes + else + cat conftest.err >&AS_MESSAGE_LOG_FD + fi + rm -f conftest.err libconftest.a conftest conftest.c + rm -rf conftest.dSYM + ]) + case $host_os in + rhapsody* | darwin1.[[012]]) + _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; + darwin1.*) + _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; + darwin*) # darwin 5.x on + # if running on 10.5 or later, the deployment target defaults + # to the OS version, if on x86, and 10.4, the deployment + # target defaults to 10.4. Don't you love it? + case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in + 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) + _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; + 10.[[012]][[,.]]*) + _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; + 10.*) + _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; + esac + ;; + esac + if test yes = "$lt_cv_apple_cc_single_mod"; then + _lt_dar_single_mod='$single_module' + fi + if test yes = "$lt_cv_ld_exported_symbols_list"; then + _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym' + else + _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib' + fi + if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then + _lt_dsymutil='~$DSYMUTIL $lib || :' + else + _lt_dsymutil= + fi + ;; + esac +]) + + +# _LT_DARWIN_LINKER_FEATURES([TAG]) +# --------------------------------- +# Checks for linker and compiler features on darwin +m4_defun([_LT_DARWIN_LINKER_FEATURES], +[ + m4_require([_LT_REQUIRED_DARWIN_CHECKS]) + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_automatic, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported + if test yes = "$lt_cv_ld_force_load"; then + _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' + m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes], + [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes]) + else + _LT_TAGVAR(whole_archive_flag_spec, $1)='' + fi + _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(allow_undefined_flag, $1)=$_lt_dar_allow_undefined + case $cc_basename in + ifort*|nagfor*) _lt_dar_can_shared=yes ;; + *) _lt_dar_can_shared=$GCC ;; + esac + if test yes = "$_lt_dar_can_shared"; then + output_verbose_link_cmd=func_echo_all + _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" + _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" + _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" + _LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" + m4_if([$1], [CXX], +[ if test yes != "$lt_cv_apple_cc_single_mod"; then + _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dsymutil" + _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil" + fi +],[]) + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi +]) + +# _LT_SYS_MODULE_PATH_AIX([TAGNAME]) +# ---------------------------------- +# Links a minimal program and checks the executable +# for the system default hardcoded library path. In most cases, +# this is /usr/lib:/lib, but when the MPI compilers are used +# the location of the communication and MPI libs are included too. +# If we don't find anything, use the default library path according +# to the aix ld manual. +# Store the results from the different compilers for each TAGNAME. +# Allow to override them for all tags through lt_cv_aix_libpath. +m4_defun([_LT_SYS_MODULE_PATH_AIX], +[m4_require([_LT_DECL_SED])dnl +if test set = "${lt_cv_aix_libpath+set}"; then + aix_libpath=$lt_cv_aix_libpath +else + AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])], + [AC_LINK_IFELSE([AC_LANG_PROGRAM],[ + lt_aix_libpath_sed='[ + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }]' + _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + # Check for a 64-bit object if we didn't find anything. + if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then + _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi],[]) + if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then + _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=/usr/lib:/lib + fi + ]) + aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1]) +fi +])# _LT_SYS_MODULE_PATH_AIX + + +# _LT_SHELL_INIT(ARG) +# ------------------- +m4_define([_LT_SHELL_INIT], +[m4_divert_text([M4SH-INIT], [$1 +])])# _LT_SHELL_INIT + + + +# _LT_PROG_ECHO_BACKSLASH +# ----------------------- +# Find how we can fake an echo command that does not interpret backslash. +# In particular, with Autoconf 2.60 or later we add some code to the start +# of the generated configure script that will find a shell with a builtin +# printf (that we can use as an echo command). +m4_defun([_LT_PROG_ECHO_BACKSLASH], +[ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO + +AC_MSG_CHECKING([how to print strings]) +# Test print first, because it will be a builtin if present. +if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ + test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='print -r --' +elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='printf %s\n' +else + # Use this function as a fallback that always works. + func_fallback_echo () + { + eval 'cat <<_LTECHO_EOF +$[]1 +_LTECHO_EOF' + } + ECHO='func_fallback_echo' +fi + +# func_echo_all arg... +# Invoke $ECHO with all args, space-separated. +func_echo_all () +{ + $ECHO "$*" +} + +case $ECHO in + printf*) AC_MSG_RESULT([printf]) ;; + print*) AC_MSG_RESULT([print -r]) ;; + *) AC_MSG_RESULT([cat]) ;; +esac + +m4_ifdef([_AS_DETECT_SUGGESTED], +[_AS_DETECT_SUGGESTED([ + test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || ( + ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' + ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO + ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO + PATH=/empty FPATH=/empty; export PATH FPATH + test "X`printf %s $ECHO`" = "X$ECHO" \ + || test "X`print -r -- $ECHO`" = "X$ECHO" )])]) + +_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts]) +_LT_DECL([], [ECHO], [1], [An echo program that protects backslashes]) +])# _LT_PROG_ECHO_BACKSLASH + + +# _LT_WITH_SYSROOT +# ---------------- +AC_DEFUN([_LT_WITH_SYSROOT], +[AC_MSG_CHECKING([for sysroot]) +AC_ARG_WITH([sysroot], +[AS_HELP_STRING([--with-sysroot@<:@=DIR@:>@], + [Search for dependent libraries within DIR (or the compiler's sysroot + if not specified).])], +[], [with_sysroot=no]) + +dnl lt_sysroot will always be passed unquoted. We quote it here +dnl in case the user passed a directory name. +lt_sysroot= +case $with_sysroot in #( + yes) + if test yes = "$GCC"; then + lt_sysroot=`$CC --print-sysroot 2>/dev/null` + fi + ;; #( + /*) + lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` + ;; #( + no|'') + ;; #( + *) + AC_MSG_RESULT([$with_sysroot]) + AC_MSG_ERROR([The sysroot must be an absolute path.]) + ;; +esac + + AC_MSG_RESULT([${lt_sysroot:-no}]) +_LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl +[dependent libraries, and where our libraries should be installed.])]) + +# _LT_ENABLE_LOCK +# --------------- +m4_defun([_LT_ENABLE_LOCK], +[AC_ARG_ENABLE([libtool-lock], + [AS_HELP_STRING([--disable-libtool-lock], + [avoid locking (might break parallel builds)])]) +test no = "$enable_libtool_lock" || enable_libtool_lock=yes + +# Some flags need to be propagated to the compiler or linker for good +# libtool support. +case $host in +ia64-*-hpux*) + # Find out what ABI is being produced by ac_compile, and set mode + # options accordingly. + echo 'int i;' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + case `/usr/bin/file conftest.$ac_objext` in + *ELF-32*) + HPUX_IA64_MODE=32 + ;; + *ELF-64*) + HPUX_IA64_MODE=64 + ;; + esac + fi + rm -rf conftest* + ;; +*-*-irix6*) + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. + echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + if test yes = "$lt_cv_prog_gnu_ld"; then + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -melf32bsmip" + ;; + *N32*) + LD="${LD-ld} -melf32bmipn32" + ;; + *64-bit*) + LD="${LD-ld} -melf64bmip" + ;; + esac + else + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -32" + ;; + *N32*) + LD="${LD-ld} -n32" + ;; + *64-bit*) + LD="${LD-ld} -64" + ;; + esac + fi + fi + rm -rf conftest* + ;; + +mips64*-*linux*) + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. + echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + emul=elf + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + emul="${emul}32" + ;; + *64-bit*) + emul="${emul}64" + ;; + esac + case `/usr/bin/file conftest.$ac_objext` in + *MSB*) + emul="${emul}btsmip" + ;; + *LSB*) + emul="${emul}ltsmip" + ;; + esac + case `/usr/bin/file conftest.$ac_objext` in + *N32*) + emul="${emul}n32" + ;; + esac + LD="${LD-ld} -m $emul" + fi + rm -rf conftest* + ;; + +x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ +s390*-*linux*|s390*-*tpf*|sparc*-*linux*) + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. Note that the listed cases only cover the + # situations where additional linker options are needed (such as when + # doing 32-bit compilation for a host where ld defaults to 64-bit, or + # vice versa); the common cases where no linker options are needed do + # not appear in the list. + echo 'int i;' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + case `/usr/bin/file conftest.o` in + *32-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_i386_fbsd" + ;; + x86_64-*linux*) + case `/usr/bin/file conftest.o` in + *x86-64*) + LD="${LD-ld} -m elf32_x86_64" + ;; + *) + LD="${LD-ld} -m elf_i386" + ;; + esac + ;; + powerpc64le-*linux*) + LD="${LD-ld} -m elf32lppclinux" + ;; + powerpc64-*linux*) + LD="${LD-ld} -m elf32ppclinux" + ;; + s390x-*linux*) + LD="${LD-ld} -m elf_s390" + ;; + sparc64-*linux*) + LD="${LD-ld} -m elf32_sparc" + ;; + esac + ;; + *64-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_x86_64_fbsd" + ;; + x86_64-*linux*) + LD="${LD-ld} -m elf_x86_64" + ;; + powerpcle-*linux*) + LD="${LD-ld} -m elf64lppc" + ;; + powerpc-*linux*) + LD="${LD-ld} -m elf64ppc" + ;; + s390*-*linux*|s390*-*tpf*) + LD="${LD-ld} -m elf64_s390" + ;; + sparc*-*linux*) + LD="${LD-ld} -m elf64_sparc" + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; + +*-*-sco3.2v5*) + # On SCO OpenServer 5, we need -belf to get full-featured binaries. + SAVE_CFLAGS=$CFLAGS + CFLAGS="$CFLAGS -belf" + AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, + [AC_LANG_PUSH(C) + AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) + AC_LANG_POP]) + if test yes != "$lt_cv_cc_needs_belf"; then + # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf + CFLAGS=$SAVE_CFLAGS + fi + ;; +*-*solaris*) + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. + echo 'int i;' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + case `/usr/bin/file conftest.o` in + *64-bit*) + case $lt_cv_prog_gnu_ld in + yes*) + case $host in + i?86-*-solaris*|x86_64-*-solaris*) + LD="${LD-ld} -m elf_x86_64" + ;; + sparc*-*-solaris*) + LD="${LD-ld} -m elf64_sparc" + ;; + esac + # GNU ld 2.21 introduced _sol2 emulations. Use them if available. + if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then + LD=${LD-ld}_sol2 + fi + ;; + *) + if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then + LD="${LD-ld} -64" + fi + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; +esac + +need_locks=$enable_libtool_lock +])# _LT_ENABLE_LOCK + + +# _LT_PROG_AR +# ----------- +m4_defun([_LT_PROG_AR], +[AC_CHECK_TOOLS(AR, [ar], false) +: ${AR=ar} +: ${AR_FLAGS=cru} +_LT_DECL([], [AR], [1], [The archiver]) +_LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive]) + +AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], + [lt_cv_ar_at_file=no + AC_COMPILE_IFELSE([AC_LANG_PROGRAM], + [echo conftest.$ac_objext > conftest.lst + lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD' + AC_TRY_EVAL([lt_ar_try]) + if test 0 -eq "$ac_status"; then + # Ensure the archiver fails upon bogus file names. + rm -f conftest.$ac_objext libconftest.a + AC_TRY_EVAL([lt_ar_try]) + if test 0 -ne "$ac_status"; then + lt_cv_ar_at_file=@ + fi + fi + rm -f conftest.* libconftest.a + ]) + ]) + +if test no = "$lt_cv_ar_at_file"; then + archiver_list_spec= +else + archiver_list_spec=$lt_cv_ar_at_file +fi +_LT_DECL([], [archiver_list_spec], [1], + [How to feed a file listing to the archiver]) +])# _LT_PROG_AR + + +# _LT_CMD_OLD_ARCHIVE +# ------------------- +m4_defun([_LT_CMD_OLD_ARCHIVE], +[_LT_PROG_AR + +AC_CHECK_TOOL(STRIP, strip, :) +test -z "$STRIP" && STRIP=: +_LT_DECL([], [STRIP], [1], [A symbol stripping program]) + +AC_CHECK_TOOL(RANLIB, ranlib, :) +test -z "$RANLIB" && RANLIB=: +_LT_DECL([], [RANLIB], [1], + [Commands used to install an old-style archive]) + +# Determine commands to create old-style static archives. +old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' +old_postinstall_cmds='chmod 644 $oldlib' +old_postuninstall_cmds= + +if test -n "$RANLIB"; then + case $host_os in + bitrig* | openbsd*) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" + ;; + *) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" + ;; + esac + old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" +fi + +case $host_os in + darwin*) + lock_old_archive_extraction=yes ;; + *) + lock_old_archive_extraction=no ;; +esac +_LT_DECL([], [old_postinstall_cmds], [2]) +_LT_DECL([], [old_postuninstall_cmds], [2]) +_LT_TAGDECL([], [old_archive_cmds], [2], + [Commands used to build an old-style archive]) +_LT_DECL([], [lock_old_archive_extraction], [0], + [Whether to use a lock for old archive extraction]) +])# _LT_CMD_OLD_ARCHIVE + + +# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, +# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) +# ---------------------------------------------------------------- +# Check whether the given compiler option works +AC_DEFUN([_LT_COMPILER_OPTION], +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_DECL_SED])dnl +AC_CACHE_CHECK([$1], [$2], + [$2=no + m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$3" ## exclude from sc_useless_quotes_in_assignment + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&AS_MESSAGE_LOG_FD + echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + $2=yes + fi + fi + $RM conftest* +]) + +if test yes = "[$]$2"; then + m4_if([$5], , :, [$5]) +else + m4_if([$6], , :, [$6]) +fi +])# _LT_COMPILER_OPTION + +# Old name: +AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) + + +# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, +# [ACTION-SUCCESS], [ACTION-FAILURE]) +# ---------------------------------------------------- +# Check whether the given linker option works +AC_DEFUN([_LT_LINKER_OPTION], +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_DECL_SED])dnl +AC_CACHE_CHECK([$1], [$2], + [$2=no + save_LDFLAGS=$LDFLAGS + LDFLAGS="$LDFLAGS $3" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&AS_MESSAGE_LOG_FD + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + $2=yes + fi + else + $2=yes + fi + fi + $RM -r conftest* + LDFLAGS=$save_LDFLAGS +]) + +if test yes = "[$]$2"; then + m4_if([$4], , :, [$4]) +else + m4_if([$5], , :, [$5]) +fi +])# _LT_LINKER_OPTION + +# Old name: +AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) + + +# LT_CMD_MAX_LEN +#--------------- +AC_DEFUN([LT_CMD_MAX_LEN], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +# find the maximum length of command line arguments +AC_MSG_CHECKING([the maximum length of command line arguments]) +AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl + i=0 + teststring=ABCD + + case $build_os in + msdosdjgpp*) + # On DJGPP, this test can blow up pretty badly due to problems in libc + # (any single argument exceeding 2000 bytes causes a buffer overrun + # during glob expansion). Even if it were fixed, the result of this + # check would be larger than it should be. + lt_cv_sys_max_cmd_len=12288; # 12K is about right + ;; + + gnu*) + # Under GNU Hurd, this test is not required because there is + # no limit to the length of command line arguments. + # Libtool will interpret -1 as no limit whatsoever + lt_cv_sys_max_cmd_len=-1; + ;; + + cygwin* | mingw* | cegcc*) + # On Win9x/ME, this test blows up -- it succeeds, but takes + # about 5 minutes as the teststring grows exponentially. + # Worse, since 9x/ME are not pre-emptively multitasking, + # you end up with a "frozen" computer, even though with patience + # the test eventually succeeds (with a max line length of 256k). + # Instead, let's just punt: use the minimum linelength reported by + # all of the supported platforms: 8192 (on NT/2K/XP). + lt_cv_sys_max_cmd_len=8192; + ;; + + mint*) + # On MiNT this can take a long time and run out of memory. + lt_cv_sys_max_cmd_len=8192; + ;; + + amigaos*) + # On AmigaOS with pdksh, this test takes hours, literally. + # So we just punt and use a minimum line length of 8192. + lt_cv_sys_max_cmd_len=8192; + ;; + + bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*) + # This has been around since 386BSD, at least. Likely further. + if test -x /sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` + elif test -x /usr/sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` + else + lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs + fi + # And add a safety zone + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + ;; + + interix*) + # We know the value 262144 and hardcode it with a safety zone (like BSD) + lt_cv_sys_max_cmd_len=196608 + ;; + + os2*) + # The test takes a long time on OS/2. + lt_cv_sys_max_cmd_len=8192 + ;; + + osf*) + # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure + # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not + # nice to cause kernel panics so lets avoid the loop below. + # First set a reasonable default. + lt_cv_sys_max_cmd_len=16384 + # + if test -x /sbin/sysconfig; then + case `/sbin/sysconfig -q proc exec_disable_arg_limit` in + *1*) lt_cv_sys_max_cmd_len=-1 ;; + esac + fi + ;; + sco3.2v5*) + lt_cv_sys_max_cmd_len=102400 + ;; + sysv5* | sco5v6* | sysv4.2uw2*) + kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` + if test -n "$kargmax"; then + lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` + else + lt_cv_sys_max_cmd_len=32768 + fi + ;; + *) + lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` + if test -n "$lt_cv_sys_max_cmd_len" && \ + test undefined != "$lt_cv_sys_max_cmd_len"; then + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + else + # Make teststring a little bigger before we do anything with it. + # a 1K string should be a reasonable start. + for i in 1 2 3 4 5 6 7 8; do + teststring=$teststring$teststring + done + SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} + # If test is not a shell built-in, we'll probably end up computing a + # maximum length that is only half of the actual maximum length, but + # we can't tell. + while { test X`env echo "$teststring$teststring" 2>/dev/null` \ + = "X$teststring$teststring"; } >/dev/null 2>&1 && + test 17 != "$i" # 1/2 MB should be enough + do + i=`expr $i + 1` + teststring=$teststring$teststring + done + # Only check the string length outside the loop. + lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` + teststring= + # Add a significant safety factor because C++ compilers can tack on + # massive amounts of additional arguments before passing them to the + # linker. It appears as though 1/2 is a usable value. + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` + fi + ;; + esac +]) +if test -n "$lt_cv_sys_max_cmd_len"; then + AC_MSG_RESULT($lt_cv_sys_max_cmd_len) +else + AC_MSG_RESULT(none) +fi +max_cmd_len=$lt_cv_sys_max_cmd_len +_LT_DECL([], [max_cmd_len], [0], + [What is the maximum length of a command?]) +])# LT_CMD_MAX_LEN + +# Old name: +AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], []) + + +# _LT_HEADER_DLFCN +# ---------------- +m4_defun([_LT_HEADER_DLFCN], +[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl +])# _LT_HEADER_DLFCN + + +# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, +# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) +# ---------------------------------------------------------------- +m4_defun([_LT_TRY_DLOPEN_SELF], +[m4_require([_LT_HEADER_DLFCN])dnl +if test yes = "$cross_compiling"; then : + [$4] +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext <<_LT_EOF +[#line $LINENO "configure" +#include "confdefs.h" + +#if HAVE_DLFCN_H +#include +#endif + +#include + +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif + +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif + +/* When -fvisibility=hidden is used, assume the code has been annotated + correspondingly for the symbols needed. */ +#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) +int fnord () __attribute__((visibility("default"))); +#endif + +int fnord () { return 42; } +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; + + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else + { + if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + else puts (dlerror ()); + } + /* dlclose (self); */ + } + else + puts (dlerror ()); + + return status; +}] +_LT_EOF + if AC_TRY_EVAL(ac_link) && test -s "conftest$ac_exeext" 2>/dev/null; then + (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) $1 ;; + x$lt_dlneed_uscore) $2 ;; + x$lt_dlunknown|x*) $3 ;; + esac + else : + # compilation failed + $3 + fi +fi +rm -fr conftest* +])# _LT_TRY_DLOPEN_SELF + + +# LT_SYS_DLOPEN_SELF +# ------------------ +AC_DEFUN([LT_SYS_DLOPEN_SELF], +[m4_require([_LT_HEADER_DLFCN])dnl +if test yes != "$enable_dlopen"; then + enable_dlopen=unknown + enable_dlopen_self=unknown + enable_dlopen_self_static=unknown +else + lt_cv_dlopen=no + lt_cv_dlopen_libs= + + case $host_os in + beos*) + lt_cv_dlopen=load_add_on + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + ;; + + mingw* | pw32* | cegcc*) + lt_cv_dlopen=LoadLibrary + lt_cv_dlopen_libs= + ;; + + cygwin*) + lt_cv_dlopen=dlopen + lt_cv_dlopen_libs= + ;; + + darwin*) + # if libdl is installed we need to link against it + AC_CHECK_LIB([dl], [dlopen], + [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl],[ + lt_cv_dlopen=dyld + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + ]) + ;; + + tpf*) + # Don't try to run any link tests for TPF. We know it's impossible + # because TPF is a cross-compiler, and we know how we open DSOs. + lt_cv_dlopen=dlopen + lt_cv_dlopen_libs= + lt_cv_dlopen_self=no + ;; + + *) + AC_CHECK_FUNC([shl_load], + [lt_cv_dlopen=shl_load], + [AC_CHECK_LIB([dld], [shl_load], + [lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld], + [AC_CHECK_FUNC([dlopen], + [lt_cv_dlopen=dlopen], + [AC_CHECK_LIB([dl], [dlopen], + [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl], + [AC_CHECK_LIB([svld], [dlopen], + [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld], + [AC_CHECK_LIB([dld], [dld_link], + [lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld]) + ]) + ]) + ]) + ]) + ]) + ;; + esac + + if test no = "$lt_cv_dlopen"; then + enable_dlopen=no + else + enable_dlopen=yes + fi + + case $lt_cv_dlopen in + dlopen) + save_CPPFLAGS=$CPPFLAGS + test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" + + save_LDFLAGS=$LDFLAGS + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" + + save_LIBS=$LIBS + LIBS="$lt_cv_dlopen_libs $LIBS" + + AC_CACHE_CHECK([whether a program can dlopen itself], + lt_cv_dlopen_self, [dnl + _LT_TRY_DLOPEN_SELF( + lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, + lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) + ]) + + if test yes = "$lt_cv_dlopen_self"; then + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" + AC_CACHE_CHECK([whether a statically linked program can dlopen itself], + lt_cv_dlopen_self_static, [dnl + _LT_TRY_DLOPEN_SELF( + lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, + lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) + ]) + fi + + CPPFLAGS=$save_CPPFLAGS + LDFLAGS=$save_LDFLAGS + LIBS=$save_LIBS + ;; + esac + + case $lt_cv_dlopen_self in + yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; + *) enable_dlopen_self=unknown ;; + esac + + case $lt_cv_dlopen_self_static in + yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; + *) enable_dlopen_self_static=unknown ;; + esac +fi +_LT_DECL([dlopen_support], [enable_dlopen], [0], + [Whether dlopen is supported]) +_LT_DECL([dlopen_self], [enable_dlopen_self], [0], + [Whether dlopen of programs is supported]) +_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0], + [Whether dlopen of statically linked programs is supported]) +])# LT_SYS_DLOPEN_SELF + +# Old name: +AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], []) + + +# _LT_COMPILER_C_O([TAGNAME]) +# --------------------------- +# Check to see if options -c and -o are simultaneously supported by compiler. +# This macro does not hard code the compiler like AC_PROG_CC_C_O. +m4_defun([_LT_COMPILER_C_O], +[m4_require([_LT_DECL_SED])dnl +m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_TAG_COMPILER])dnl +AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], + [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)], + [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no + $RM -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&AS_MESSAGE_LOG_FD + echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes + fi + fi + chmod u+w . 2>&AS_MESSAGE_LOG_FD + $RM conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files + $RM out/* && rmdir out + cd .. + $RM -r conftest + $RM conftest* +]) +_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1], + [Does compiler simultaneously support -c and -o options?]) +])# _LT_COMPILER_C_O + + +# _LT_COMPILER_FILE_LOCKS([TAGNAME]) +# ---------------------------------- +# Check to see if we can do hard links to lock some files if needed +m4_defun([_LT_COMPILER_FILE_LOCKS], +[m4_require([_LT_ENABLE_LOCK])dnl +m4_require([_LT_FILEUTILS_DEFAULTS])dnl +_LT_COMPILER_C_O([$1]) + +hard_links=nottested +if test no = "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" && test no != "$need_locks"; then + # do not overwrite the value of need_locks provided by the user + AC_MSG_CHECKING([if we can lock with hard links]) + hard_links=yes + $RM conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + AC_MSG_RESULT([$hard_links]) + if test no = "$hard_links"; then + AC_MSG_WARN(['$CC' does not support '-c -o', so 'make -j' may be unsafe]) + need_locks=warn + fi +else + need_locks=no +fi +_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) +])# _LT_COMPILER_FILE_LOCKS + + +# _LT_CHECK_OBJDIR +# ---------------- +m4_defun([_LT_CHECK_OBJDIR], +[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], +[rm -f .libs 2>/dev/null +mkdir .libs 2>/dev/null +if test -d .libs; then + lt_cv_objdir=.libs +else + # MS-DOS does not allow filenames that begin with a dot. + lt_cv_objdir=_libs +fi +rmdir .libs 2>/dev/null]) +objdir=$lt_cv_objdir +_LT_DECL([], [objdir], [0], + [The name of the directory that contains temporary libtool files])dnl +m4_pattern_allow([LT_OBJDIR])dnl +AC_DEFINE_UNQUOTED([LT_OBJDIR], "$lt_cv_objdir/", + [Define to the sub-directory where libtool stores uninstalled libraries.]) +])# _LT_CHECK_OBJDIR + + +# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME]) +# -------------------------------------- +# Check hardcoding attributes. +m4_defun([_LT_LINKER_HARDCODE_LIBPATH], +[AC_MSG_CHECKING([how to hardcode library paths into programs]) +_LT_TAGVAR(hardcode_action, $1)= +if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || + test -n "$_LT_TAGVAR(runpath_var, $1)" || + test yes = "$_LT_TAGVAR(hardcode_automatic, $1)"; then + + # We can hardcode non-existent directories. + if test no != "$_LT_TAGVAR(hardcode_direct, $1)" && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" && + test no != "$_LT_TAGVAR(hardcode_minus_L, $1)"; then + # Linking always hardcodes the temporary library directory. + _LT_TAGVAR(hardcode_action, $1)=relink + else + # We can link without hardcoding, and we can hardcode nonexisting dirs. + _LT_TAGVAR(hardcode_action, $1)=immediate + fi +else + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + _LT_TAGVAR(hardcode_action, $1)=unsupported +fi +AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) + +if test relink = "$_LT_TAGVAR(hardcode_action, $1)" || + test yes = "$_LT_TAGVAR(inherit_rpath, $1)"; then + # Fast installation is not supported + enable_fast_install=no +elif test yes = "$shlibpath_overrides_runpath" || + test no = "$enable_shared"; then + # Fast installation is not necessary + enable_fast_install=needless +fi +_LT_TAGDECL([], [hardcode_action], [0], + [How to hardcode a shared library path into an executable]) +])# _LT_LINKER_HARDCODE_LIBPATH + + +# _LT_CMD_STRIPLIB +# ---------------- +m4_defun([_LT_CMD_STRIPLIB], +[m4_require([_LT_DECL_EGREP]) +striplib= +old_striplib= +AC_MSG_CHECKING([whether stripping libraries is possible]) +if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then + test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" + test -z "$striplib" && striplib="$STRIP --strip-unneeded" + AC_MSG_RESULT([yes]) +else +# FIXME - insert some real tests, host_os isn't really good enough + case $host_os in + darwin*) + if test -n "$STRIP"; then + striplib="$STRIP -x" + old_striplib="$STRIP -S" + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + fi + ;; + *) + AC_MSG_RESULT([no]) + ;; + esac +fi +_LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) +_LT_DECL([], [striplib], [1]) +])# _LT_CMD_STRIPLIB + + +# _LT_PREPARE_MUNGE_PATH_LIST +# --------------------------- +# Make sure func_munge_path_list() is defined correctly. +m4_defun([_LT_PREPARE_MUNGE_PATH_LIST], +[[# func_munge_path_list VARIABLE PATH +# ----------------------------------- +# VARIABLE is name of variable containing _space_ separated list of +# directories to be munged by the contents of PATH, which is string +# having a format: +# "DIR[:DIR]:" +# string "DIR[ DIR]" will be prepended to VARIABLE +# ":DIR[:DIR]" +# string "DIR[ DIR]" will be appended to VARIABLE +# "DIRP[:DIRP]::[DIRA:]DIRA" +# string "DIRP[ DIRP]" will be prepended to VARIABLE and string +# "DIRA[ DIRA]" will be appended to VARIABLE +# "DIR[:DIR]" +# VARIABLE will be replaced by "DIR[ DIR]" +func_munge_path_list () +{ + case x@S|@2 in + x) + ;; + *:) + eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'` \@S|@@S|@1\" + ;; + x:*) + eval @S|@1=\"\@S|@@S|@1 `$ECHO @S|@2 | $SED 's/:/ /g'`\" + ;; + *::*) + eval @S|@1=\"\@S|@@S|@1\ `$ECHO @S|@2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" + eval @S|@1=\"`$ECHO @S|@2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \@S|@@S|@1\" + ;; + *) + eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'`\" + ;; + esac +} +]])# _LT_PREPARE_PATH_LIST + + +# _LT_SYS_DYNAMIC_LINKER([TAG]) +# ----------------------------- +# PORTME Fill in your ld.so characteristics +m4_defun([_LT_SYS_DYNAMIC_LINKER], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_DECL_OBJDUMP])dnl +m4_require([_LT_DECL_SED])dnl +m4_require([_LT_CHECK_SHELL_FEATURES])dnl +m4_require([_LT_PREPARE_MUNGE_PATH_LIST])dnl +AC_MSG_CHECKING([dynamic linker characteristics]) +m4_if([$1], + [], [ +if test yes = "$GCC"; then + case $host_os in + darwin*) lt_awk_arg='/^libraries:/,/LR/' ;; + *) lt_awk_arg='/^libraries:/' ;; + esac + case $host_os in + mingw* | cegcc*) lt_sed_strip_eq='s|=\([[A-Za-z]]:\)|\1|g' ;; + *) lt_sed_strip_eq='s|=/|/|g' ;; + esac + lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` + case $lt_search_path_spec in + *\;*) + # if the path contains ";" then we assume it to be the separator + # otherwise default to the standard path separator (i.e. ":") - it is + # assumed that no part of a normal pathname contains ";" but that should + # okay in the real world where ";" in dirpaths is itself problematic. + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` + ;; + *) + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` + ;; + esac + # Ok, now we have the path, separated by spaces, we can step through it + # and add multilib dir if necessary... + lt_tmp_lt_search_path_spec= + lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` + # ...but if some path component already ends with the multilib dir we assume + # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer). + case "$lt_multi_os_dir; $lt_search_path_spec " in + "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*) + lt_multi_os_dir= + ;; + esac + for lt_sys_path in $lt_search_path_spec; do + if test -d "$lt_sys_path$lt_multi_os_dir"; then + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir" + elif test -n "$lt_multi_os_dir"; then + test -d "$lt_sys_path" && \ + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" + fi + done + lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' +BEGIN {RS = " "; FS = "/|\n";} { + lt_foo = ""; + lt_count = 0; + for (lt_i = NF; lt_i > 0; lt_i--) { + if ($lt_i != "" && $lt_i != ".") { + if ($lt_i == "..") { + lt_count++; + } else { + if (lt_count == 0) { + lt_foo = "/" $lt_i lt_foo; + } else { + lt_count--; + } + } + } + } + if (lt_foo != "") { lt_freq[[lt_foo]]++; } + if (lt_freq[[lt_foo]] == 1) { print lt_foo; } +}'` + # AWK program above erroneously prepends '/' to C:/dos/paths + # for these hosts. + case $host_os in + mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ + $SED 's|/\([[A-Za-z]]:\)|\1|g'` ;; + esac + sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` +else + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" +fi]) +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=.so +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" +need_lib_prefix=unknown +hardcode_into_libs=no + +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown + +AC_ARG_VAR([LT_SYS_LIBRARY_PATH], +[User-defined run-time library search path.]) + +case $host_os in +aix3*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname.a' + shlibpath_var=LIBPATH + + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='$libname$release$shared_ext$major' + ;; + +aix[[4-9]]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test ia64 = "$host_cpu"; then + # AIX 5 supports IA64 + library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line '#! .'. This would cause the generated library to + # depend on '.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[[01]] | aix4.[[01]].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then + : + else + can_build_shared=no + fi + ;; + esac + # Using Import Files as archive members, it is possible to support + # filename-based versioning of shared library archives on AIX. While + # this would work for both with and without runtime linking, it will + # prevent static linking of such archives. So we do filename-based + # shared library versioning with .so extension only, which is used + # when both runtime linking and shared linking is enabled. + # Unfortunately, runtime linking may impact performance, so we do + # not want this to be the default eventually. Also, we use the + # versioned .so libs for executables only if there is the -brtl + # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. + # To allow for filename-based versioning support, we need to create + # libNAME.so.V as an archive file, containing: + # *) an Import File, referring to the versioned filename of the + # archive as well as the shared archive member, telling the + # bitwidth (32 or 64) of that shared object, and providing the + # list of exported symbols of that shared object, eventually + # decorated with the 'weak' keyword + # *) the shared object with the F_LOADONLY flag set, to really avoid + # it being seen by the linker. + # At run time we better use the real file rather than another symlink, + # but for link time we create the symlink libNAME.so -> libNAME.so.V + + case $with_aix_soname,$aix_use_runtimelinking in + # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + aix,yes) # traditional libtool + dynamic_linker='AIX unversionable lib.so' + # If using run time linking (on AIX 4.2 or later) use lib.so + # instead of lib.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + ;; + aix,no) # traditional AIX only + dynamic_linker='AIX lib.a[(]lib.so.V[)]' + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='$libname$release.a $libname.a' + soname_spec='$libname$release$shared_ext$major' + ;; + svr4,*) # full svr4 only + dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)]" + library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' + # We do not specify a path in Import Files, so LIBPATH fires. + shlibpath_overrides_runpath=yes + ;; + *,yes) # both, prefer svr4 + dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)], lib.a[(]lib.so.V[)]" + library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' + # unpreferred sharedlib libNAME.a needs extra handling + postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' + postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' + # We do not specify a path in Import Files, so LIBPATH fires. + shlibpath_overrides_runpath=yes + ;; + *,no) # both, prefer aix + dynamic_linker="AIX lib.a[(]lib.so.V[)], lib.so.V[(]$shared_archive_member_spec.o[)]" + library_names_spec='$libname$release.a $libname.a' + soname_spec='$libname$release$shared_ext$major' + # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling + postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' + postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' + ;; + esac + shlibpath_var=LIBPATH + fi + ;; + +amigaos*) + case $host_cpu in + powerpc) + # Since July 2007 AmigaOS4 officially supports .so libraries. + # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + ;; + m68k) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; $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' + ;; + esac + ;; + +beos*) + library_names_spec='$libname$shared_ext' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; + +bsdi[[45]]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; + +cygwin* | mingw* | pw32* | cegcc*) + version_type=windows + shrext_cmds=.dll + need_version=no + need_lib_prefix=no + + case $GCC,$cc_basename in + yes,*) + # gcc + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + + case $host_os in + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' +m4_if([$1], [],[ + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) + ;; + mingw* | cegcc*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' + ;; + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' + ;; + esac + dynamic_linker='Win32 ld.exe' + ;; + + *,cl*) + # Native MSVC + libname_spec='$name' + soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' + library_names_spec='$libname.dll.lib' + + case $build_os in + mingw*) + sys_lib_search_path_spec= + lt_save_ifs=$IFS + IFS=';' + for lt_path in $LIB + do + IFS=$lt_save_ifs + # Let DOS variable expansion print the short 8.3 style file name. + lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` + sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" + done + IFS=$lt_save_ifs + # Convert to MSYS style. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'` + ;; + cygwin*) + # Convert to unix form, then to dos form, then back to unix form + # but this time dos style (no spaces!) so that the unix form looks + # like /cygdrive/c/PROGRA~1:/cygdr... + sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` + sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` + sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + ;; + *) + sys_lib_search_path_spec=$LIB + if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then + # It is most probably a Windows format PATH. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + # FIXME: find the short name or the path components, as spaces are + # common. (e.g. "Program Files" -> "PROGRA~1") + ;; + esac + + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + shlibpath_overrides_runpath=yes + dynamic_linker='Win32 link.exe' + ;; + + *) + # Assume MSVC wrapper + library_names_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext $libname.lib' + dynamic_linker='Win32 ld.exe' + ;; + esac + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; + +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' + soname_spec='$libname$release$major$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' +m4_if([$1], [],[ + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; + +dgux*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` + else + case $host_os in + freebsd[[23]].*) objformat=aout ;; + *) objformat=elf ;; + esac + fi + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + need_version=no + need_lib_prefix=no + ;; + freebsd-*) + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + need_version=yes + ;; + esac + shlibpath_var=LD_LIBRARY_PATH + case $host_os in + freebsd2.*) + shlibpath_overrides_runpath=yes + ;; + freebsd3.[[01]]* | freebsdelf3.[[01]]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ + freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + *) # from 4.6 on, and DragonFly + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + esac + ;; + +haiku*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + dynamic_linker="$host_os runtime_loader" + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LIBRARY_PATH + shlibpath_overrides_runpath=no + sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' + hardcode_into_libs=yes + ;; + +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + if test 32 = "$HPUX_IA64_MODE"; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + sys_lib_dlsearch_path_spec=/usr/lib/hpux32 + else + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + sys_lib_dlsearch_path_spec=/usr/lib/hpux64 + fi + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555, ... + postinstall_cmds='chmod 555 $lib' + # or fails outright, so override atomically: + install_override_mode=555 + ;; + +interix[[3-9]]*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; + *) + if test yes = "$lt_cv_prog_gnu_ld"; then + version_type=linux # correct to gnu/linux during the next big refactor + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='$libname$release$shared_ext$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; + esac + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" + sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" + hardcode_into_libs=yes + ;; + +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; + +linux*android*) + version_type=none # Android doesn't support versioned libraries. + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext' + soname_spec='$libname$release$shared_ext' + finish_cmds= + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + dynamic_linker='Android linker' + # Don't embed -rpath directories since the linker doesn't support them. + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + ;; + +# This must be glibc/ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + + # Some binutils ld are patched to set DT_RUNPATH + AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath], + [lt_cv_shlibpath_overrides_runpath=no + save_LDFLAGS=$LDFLAGS + save_libdir=$libdir + eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \ + LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\"" + AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], + [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null], + [lt_cv_shlibpath_overrides_runpath=yes])]) + LDFLAGS=$save_LDFLAGS + libdir=$save_libdir + ]) + shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + # Ideally, we could use ldconfig to report *all* directores which are + # searched for libraries, however this is still not possible. Aside from not + # being certain /sbin/ldconfig is available, command + # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, + # even though it is searched at run-time. Try to do the best guess by + # appending ld.so.conf contents (and includes) to the search path. + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi + + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; + +netbsdelf*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='NetBSD ld.elf_so' + ;; + +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + +newsos6) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +*nto* | *qnx*) + version_type=qnx + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='ldqnx.so' + ;; + +openbsd* | bitrig*) + version_type=sunos + sys_lib_dlsearch_path_spec=/usr/lib + need_lib_prefix=no + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then + need_version=no + else + need_version=yes + fi + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +os2*) + libname_spec='$name' + version_type=windows + shrext_cmds=.dll + need_version=no + need_lib_prefix=no + # OS/2 can only load a DLL with a base name of 8 characters or less. + soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; + v=$($ECHO $release$versuffix | tr -d .-); + n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); + $ECHO $n$v`$shared_ext' + library_names_spec='${libname}_dll.$libext' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=BEGINLIBPATH + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' + ;; + +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='$libname$release$shared_ext$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + +rdos*) + dynamic_linker=no + ;; + +solaris*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; + +sunos4*) + version_type=sunos + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test yes = "$with_gnu_ld"; then + need_lib_prefix=no + fi + need_version=yes + ;; + +sysv4 | sysv4.3*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + runpath_var=LD_RUN_PATH + ;; + siemens) + need_lib_prefix=no + ;; + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + ;; + esac + ;; + +sysv4*MP*) + if test -d /usr/nec; then + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' + soname_spec='$libname$shared_ext.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + version_type=sco + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + if test yes = "$with_gnu_ld"; then + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' + else + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' + case $host_os in + sco3.2v5*) + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" + ;; + esac + fi + sys_lib_dlsearch_path_spec='/usr/lib' + ;; + +tpf*) + # TPF is a cross-target only. Preferred cross-host = GNU/Linux. + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +uts4*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +*) + dynamic_linker=no + ;; +esac +AC_MSG_RESULT([$dynamic_linker]) +test no = "$dynamic_linker" && can_build_shared=no + +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test yes = "$GCC"; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +fi + +if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then + sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec +fi + +if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then + sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec +fi + +# remember unaugmented sys_lib_dlsearch_path content for libtool script decls... +configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec + +# ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code +func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" + +# to be used as default LT_SYS_LIBRARY_PATH value in generated libtool +configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH + +_LT_DECL([], [variables_saved_for_relink], [1], + [Variables whose values should be saved in libtool wrapper scripts and + restored at link time]) +_LT_DECL([], [need_lib_prefix], [0], + [Do we need the "lib" prefix for modules?]) +_LT_DECL([], [need_version], [0], [Do we need a version for libraries?]) +_LT_DECL([], [version_type], [0], [Library versioning type]) +_LT_DECL([], [runpath_var], [0], [Shared library runtime path variable]) +_LT_DECL([], [shlibpath_var], [0],[Shared library path variable]) +_LT_DECL([], [shlibpath_overrides_runpath], [0], + [Is shlibpath searched before the hard-coded library search path?]) +_LT_DECL([], [libname_spec], [1], [Format of library name prefix]) +_LT_DECL([], [library_names_spec], [1], + [[List of archive names. First name is the real one, the rest are links. + The last name is the one that the linker finds with -lNAME]]) +_LT_DECL([], [soname_spec], [1], + [[The coded name of the library, if different from the real name]]) +_LT_DECL([], [install_override_mode], [1], + [Permission mode override for installation of shared libraries]) +_LT_DECL([], [postinstall_cmds], [2], + [Command to use after installation of a shared archive]) +_LT_DECL([], [postuninstall_cmds], [2], + [Command to use after uninstallation of a shared archive]) +_LT_DECL([], [finish_cmds], [2], + [Commands used to finish a libtool library installation in a directory]) +_LT_DECL([], [finish_eval], [1], + [[As "finish_cmds", except a single script fragment to be evaled but + not shown]]) +_LT_DECL([], [hardcode_into_libs], [0], + [Whether we should hardcode library paths into libraries]) +_LT_DECL([], [sys_lib_search_path_spec], [2], + [Compile-time system search path for libraries]) +_LT_DECL([sys_lib_dlsearch_path_spec], [configure_time_dlsearch_path], [2], + [Detected run-time system search path for libraries]) +_LT_DECL([], [configure_time_lt_sys_library_path], [2], + [Explicit LT_SYS_LIBRARY_PATH set during ./configure time]) +])# _LT_SYS_DYNAMIC_LINKER + + +# _LT_PATH_TOOL_PREFIX(TOOL) +# -------------------------- +# find a file program that can recognize shared library +AC_DEFUN([_LT_PATH_TOOL_PREFIX], +[m4_require([_LT_DECL_EGREP])dnl +AC_MSG_CHECKING([for $1]) +AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, +[case $MAGIC_CMD in +[[\\/*] | ?:[\\/]*]) + lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. + ;; +*) + lt_save_MAGIC_CMD=$MAGIC_CMD + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR +dnl $ac_dummy forces splitting on constant user-supplied paths. +dnl POSIX.2 word splitting is done only on the output of word expansions, +dnl not every word. This closes a longstanding sh security hole. + ac_dummy="m4_if([$2], , $PATH, [$2])" + for ac_dir in $ac_dummy; do + IFS=$lt_save_ifs + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/$1"; then + lt_cv_path_MAGIC_CMD=$ac_dir/"$1" + if test -n "$file_magic_test_file"; then + case $deplibs_check_method in + "file_magic "*) + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` + MAGIC_CMD=$lt_cv_path_MAGIC_CMD + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | + $EGREP "$file_magic_regex" > /dev/null; then + : + else + cat <<_LT_EOF 1>&2 + +*** Warning: the command libtool uses to detect shared libraries, +*** $file_magic_cmd, produces output that libtool cannot recognize. +*** The result is that libtool may fail to recognize shared libraries +*** as such. This will affect the creation of libtool libraries that +*** depend on shared libraries, but programs linked with such libtool +*** libraries will work regardless of this problem. Nevertheless, you +*** may want to report the problem to your system manager and/or to +*** bug-libtool@gnu.org + +_LT_EOF + fi ;; + esac + fi + break + fi + done + IFS=$lt_save_ifs + MAGIC_CMD=$lt_save_MAGIC_CMD + ;; +esac]) +MAGIC_CMD=$lt_cv_path_MAGIC_CMD +if test -n "$MAGIC_CMD"; then + AC_MSG_RESULT($MAGIC_CMD) +else + AC_MSG_RESULT(no) +fi +_LT_DECL([], [MAGIC_CMD], [0], + [Used to examine libraries when file_magic_cmd begins with "file"])dnl +])# _LT_PATH_TOOL_PREFIX + +# Old name: +AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) + + +# _LT_PATH_MAGIC +# -------------- +# find a file program that can recognize a shared library +m4_defun([_LT_PATH_MAGIC], +[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) +if test -z "$lt_cv_path_MAGIC_CMD"; then + if test -n "$ac_tool_prefix"; then + _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) + else + MAGIC_CMD=: + fi +fi +])# _LT_PATH_MAGIC + + +# LT_PATH_LD +# ---------- +# find the pathname to the GNU or non-GNU linker +AC_DEFUN([LT_PATH_LD], +[AC_REQUIRE([AC_PROG_CC])dnl +AC_REQUIRE([AC_CANONICAL_HOST])dnl +AC_REQUIRE([AC_CANONICAL_BUILD])dnl +m4_require([_LT_DECL_SED])dnl +m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_PROG_ECHO_BACKSLASH])dnl + +AC_ARG_WITH([gnu-ld], + [AS_HELP_STRING([--with-gnu-ld], + [assume the C compiler uses GNU ld @<:@default=no@:>@])], + [test no = "$withval" || with_gnu_ld=yes], + [with_gnu_ld=no])dnl + +ac_prog=ld +if test yes = "$GCC"; then + # Check if gcc -print-prog-name=ld gives a path. + AC_MSG_CHECKING([for ld used by $CC]) + case $host in + *-*-mingw*) + # gcc leaves a trailing carriage return, which upsets mingw + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; + *) + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; + esac + case $ac_prog in + # Accept absolute paths. + [[\\/]]* | ?:[[\\/]]*) + re_direlt='/[[^/]][[^/]]*/\.\./' + # Canonicalize the pathname of ld + ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` + while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do + ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` + done + test -z "$LD" && LD=$ac_prog + ;; + "") + # If it fails, then pretend we aren't using GCC. + ac_prog=ld + ;; + *) + # If it is relative, then search for the first ld in PATH. + with_gnu_ld=unknown + ;; + esac +elif test yes = "$with_gnu_ld"; then + AC_MSG_CHECKING([for GNU ld]) +else + AC_MSG_CHECKING([for non-GNU ld]) +fi +AC_CACHE_VAL(lt_cv_path_LD, +[if test -z "$LD"; then + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS=$lt_save_ifs + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then + lt_cv_path_LD=$ac_dir/$ac_prog + # Check to see if the program is GNU ld. I'd rather use --version, + # but apparently some variants of GNU ld only accept -v. + # Break only if it was the GNU/non-GNU ld that we prefer. + case `"$lt_cv_path_LD" -v 2>&1 &1 conftest.i +cat conftest.i conftest.i >conftest2.i +: ${lt_DD:=$DD} +AC_PATH_PROGS_FEATURE_CHECK([lt_DD], [dd], +[if "$ac_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then + cmp -s conftest.i conftest.out \ + && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=: +fi]) +rm -f conftest.i conftest2.i conftest.out]) +])# _LT_PATH_DD + + +# _LT_CMD_TRUNCATE +# ---------------- +# find command to truncate a binary pipe +m4_defun([_LT_CMD_TRUNCATE], +[m4_require([_LT_PATH_DD]) +AC_CACHE_CHECK([how to truncate binary pipes], [lt_cv_truncate_bin], +[printf 0123456789abcdef0123456789abcdef >conftest.i +cat conftest.i conftest.i >conftest2.i +lt_cv_truncate_bin= +if "$ac_cv_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then + cmp -s conftest.i conftest.out \ + && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1" +fi +rm -f conftest.i conftest2.i conftest.out +test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"]) +_LT_DECL([lt_truncate_bin], [lt_cv_truncate_bin], [1], + [Command to truncate a binary pipe]) +])# _LT_CMD_TRUNCATE + + +# _LT_CHECK_MAGIC_METHOD +# ---------------------- +# how to check for library dependencies +# -- PORTME fill in with the dynamic library characteristics +m4_defun([_LT_CHECK_MAGIC_METHOD], +[m4_require([_LT_DECL_EGREP]) +m4_require([_LT_DECL_OBJDUMP]) +AC_CACHE_CHECK([how to recognize dependent libraries], +lt_cv_deplibs_check_method, +[lt_cv_file_magic_cmd='$MAGIC_CMD' +lt_cv_file_magic_test_file= +lt_cv_deplibs_check_method='unknown' +# Need to set the preceding variable on all platforms that support +# interlibrary dependencies. +# 'none' -- dependencies not supported. +# 'unknown' -- same as none, but documents that we really don't know. +# 'pass_all' -- all dependencies passed with no checks. +# 'test_compile' -- check by making test program. +# 'file_magic [[regex]]' -- check by looking for files in library path +# that responds to the $file_magic_cmd with a given extended regex. +# If you have 'file' or equivalent on your system and you're not sure +# whether 'pass_all' will *always* work, you probably want this one. + +case $host_os in +aix[[4-9]]*) + lt_cv_deplibs_check_method=pass_all + ;; + +beos*) + lt_cv_deplibs_check_method=pass_all + ;; + +bsdi[[45]]*) + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' + lt_cv_file_magic_cmd='/usr/bin/file -L' + lt_cv_file_magic_test_file=/shlib/libc.so + ;; + +cygwin*) + # func_win32_libid is a shell function defined in ltmain.sh + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + ;; + +mingw* | pw32*) + # Base MSYS/MinGW do not provide the 'file' command needed by + # func_win32_libid shell function, so use a weaker test based on 'objdump', + # unless we find 'file', for example because we are cross-compiling. + if ( file / ) >/dev/null 2>&1; then + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + else + # Keep this pattern in sync with the one in func_win32_libid. + lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' + lt_cv_file_magic_cmd='$OBJDUMP -f' + fi + ;; + +cegcc*) + # use the weaker test based on 'objdump'. See mingw*. + lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' + lt_cv_file_magic_cmd='$OBJDUMP -f' + ;; + +darwin* | rhapsody*) + lt_cv_deplibs_check_method=pass_all + ;; + +freebsd* | dragonfly*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then + case $host_cpu in + i*86 ) + # Not sure whether the presence of OpenBSD here was a mistake. + # Let's accept both of them until this is cleared up. + lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` + ;; + esac + else + lt_cv_deplibs_check_method=pass_all + fi + ;; + +haiku*) + lt_cv_deplibs_check_method=pass_all + ;; + +hpux10.20* | hpux11*) + lt_cv_file_magic_cmd=/usr/bin/file + case $host_cpu in + ia64*) + lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' + lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so + ;; + hppa*64*) + [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'] + lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl + ;; + *) + lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library' + lt_cv_file_magic_test_file=/usr/lib/libc.sl + ;; + esac + ;; + +interix[[3-9]]*) + # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' + ;; + +irix5* | irix6* | nonstopux*) + case $LD in + *-32|*"-32 ") libmagic=32-bit;; + *-n32|*"-n32 ") libmagic=N32;; + *-64|*"-64 ") libmagic=64-bit;; + *) libmagic=never-match;; + esac + lt_cv_deplibs_check_method=pass_all + ;; + +# This must be glibc/ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + lt_cv_deplibs_check_method=pass_all + ;; + +netbsd* | netbsdelf*-gnu) + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' + fi + ;; + +newos6*) + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=/usr/lib/libnls.so + ;; + +*nto* | *qnx*) + lt_cv_deplibs_check_method=pass_all + ;; + +openbsd* | bitrig*) + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' + fi + ;; + +osf3* | osf4* | osf5*) + lt_cv_deplibs_check_method=pass_all + ;; + +rdos*) + lt_cv_deplibs_check_method=pass_all + ;; + +solaris*) + lt_cv_deplibs_check_method=pass_all + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + lt_cv_deplibs_check_method=pass_all + ;; + +sysv4 | sysv4.3*) + case $host_vendor in + motorola) + 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]]' + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` + ;; + ncr) + lt_cv_deplibs_check_method=pass_all + ;; + sequent) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' + ;; + sni) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" + lt_cv_file_magic_test_file=/lib/libc.so + ;; + siemens) + lt_cv_deplibs_check_method=pass_all + ;; + pc) + lt_cv_deplibs_check_method=pass_all + ;; + esac + ;; + +tpf*) + lt_cv_deplibs_check_method=pass_all + ;; +os2*) + lt_cv_deplibs_check_method=pass_all + ;; +esac +]) + +file_magic_glob= +want_nocaseglob=no +if test "$build" = "$host"; then + case $host_os in + mingw* | pw32*) + if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then + want_nocaseglob=yes + else + file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"` + fi + ;; + esac +fi + +file_magic_cmd=$lt_cv_file_magic_cmd +deplibs_check_method=$lt_cv_deplibs_check_method +test -z "$deplibs_check_method" && deplibs_check_method=unknown + +_LT_DECL([], [deplibs_check_method], [1], + [Method to check whether dependent libraries are shared objects]) +_LT_DECL([], [file_magic_cmd], [1], + [Command to use when deplibs_check_method = "file_magic"]) +_LT_DECL([], [file_magic_glob], [1], + [How to find potential files when deplibs_check_method = "file_magic"]) +_LT_DECL([], [want_nocaseglob], [1], + [Find potential files using nocaseglob when deplibs_check_method = "file_magic"]) +])# _LT_CHECK_MAGIC_METHOD + + +# LT_PATH_NM +# ---------- +# find the pathname to a BSD- or MS-compatible name lister +AC_DEFUN([LT_PATH_NM], +[AC_REQUIRE([AC_PROG_CC])dnl +AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, +[if test -n "$NM"; then + # Let the user override the test. + lt_cv_path_NM=$NM +else + lt_nm_to_check=${ac_tool_prefix}nm + if test -n "$ac_tool_prefix" && test "$build" = "$host"; then + lt_nm_to_check="$lt_nm_to_check nm" + fi + for lt_tmp_nm in $lt_nm_to_check; do + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR + for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do + IFS=$lt_save_ifs + test -z "$ac_dir" && ac_dir=. + tmp_nm=$ac_dir/$lt_tmp_nm + if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then + # Check to see if the nm accepts a BSD-compat flag. + # Adding the 'sed 1q' prevents false positives on HP-UX, which says: + # nm: unknown option "B" ignored + # Tru64's nm complains that /dev/null is an invalid object file + # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty + case $build_os in + mingw*) lt_bad_file=conftest.nm/nofile ;; + *) lt_bad_file=/dev/null ;; + esac + case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in + *$lt_bad_file* | *'Invalid file or object type'*) + lt_cv_path_NM="$tmp_nm -B" + break 2 + ;; + *) + case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in + */dev/null*) + lt_cv_path_NM="$tmp_nm -p" + break 2 + ;; + *) + lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but + continue # so that we can try to find one that supports BSD flags + ;; + esac + ;; + esac + fi + done + IFS=$lt_save_ifs + done + : ${lt_cv_path_NM=no} +fi]) +if test no != "$lt_cv_path_NM"; then + NM=$lt_cv_path_NM +else + # Didn't find any BSD compatible name lister, look for dumpbin. + if test -n "$DUMPBIN"; then : + # Let the user override the test. + else + AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) + case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in + *COFF*) + DUMPBIN="$DUMPBIN -symbols -headers" + ;; + *) + DUMPBIN=: + ;; + esac + fi + AC_SUBST([DUMPBIN]) + if test : != "$DUMPBIN"; then + NM=$DUMPBIN + fi +fi +test -z "$NM" && NM=nm +AC_SUBST([NM]) +_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl + +AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface], + [lt_cv_nm_interface="BSD nm" + echo "int some_variable = 0;" > conftest.$ac_ext + (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD) + (eval "$ac_compile" 2>conftest.err) + cat conftest.err >&AS_MESSAGE_LOG_FD + (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD) + (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) + cat conftest.err >&AS_MESSAGE_LOG_FD + (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD) + cat conftest.out >&AS_MESSAGE_LOG_FD + if $GREP 'External.*some_variable' conftest.out > /dev/null; then + lt_cv_nm_interface="MS dumpbin" + fi + rm -f conftest*]) +])# LT_PATH_NM + +# Old names: +AU_ALIAS([AM_PROG_NM], [LT_PATH_NM]) +AU_ALIAS([AC_PROG_NM], [LT_PATH_NM]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AM_PROG_NM], []) +dnl AC_DEFUN([AC_PROG_NM], []) + +# _LT_CHECK_SHAREDLIB_FROM_LINKLIB +# -------------------------------- +# how to determine the name of the shared library +# associated with a specific link library. +# -- PORTME fill in with the dynamic library characteristics +m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB], +[m4_require([_LT_DECL_EGREP]) +m4_require([_LT_DECL_OBJDUMP]) +m4_require([_LT_DECL_DLLTOOL]) +AC_CACHE_CHECK([how to associate runtime and link libraries], +lt_cv_sharedlib_from_linklib_cmd, +[lt_cv_sharedlib_from_linklib_cmd='unknown' + +case $host_os in +cygwin* | mingw* | pw32* | cegcc*) + # two different shell functions defined in ltmain.sh; + # decide which one to use based on capabilities of $DLLTOOL + case `$DLLTOOL --help 2>&1` in + *--identify-strict*) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib + ;; + *) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback + ;; + esac + ;; +*) + # fallback: assume linklib IS sharedlib + lt_cv_sharedlib_from_linklib_cmd=$ECHO + ;; +esac +]) +sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd +test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO + +_LT_DECL([], [sharedlib_from_linklib_cmd], [1], + [Command to associate shared and link libraries]) +])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB + + +# _LT_PATH_MANIFEST_TOOL +# ---------------------- +# locate the manifest tool +m4_defun([_LT_PATH_MANIFEST_TOOL], +[AC_CHECK_TOOL(MANIFEST_TOOL, mt, :) +test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt +AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool], + [lt_cv_path_mainfest_tool=no + echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD + $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out + cat conftest.err >&AS_MESSAGE_LOG_FD + if $GREP 'Manifest Tool' conftest.out > /dev/null; then + lt_cv_path_mainfest_tool=yes + fi + rm -f conftest*]) +if test yes != "$lt_cv_path_mainfest_tool"; then + MANIFEST_TOOL=: +fi +_LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl +])# _LT_PATH_MANIFEST_TOOL + + +# _LT_DLL_DEF_P([FILE]) +# --------------------- +# True iff FILE is a Windows DLL '.def' file. +# Keep in sync with func_dll_def_p in the libtool script +AC_DEFUN([_LT_DLL_DEF_P], +[dnl + test DEF = "`$SED -n dnl + -e '\''s/^[[ ]]*//'\'' dnl Strip leading whitespace + -e '\''/^\(;.*\)*$/d'\'' dnl Delete empty lines and comments + -e '\''s/^\(EXPORTS\|LIBRARY\)\([[ ]].*\)*$/DEF/p'\'' dnl + -e q dnl Only consider the first "real" line + $1`" dnl +])# _LT_DLL_DEF_P + + +# LT_LIB_M +# -------- +# check for math library +AC_DEFUN([LT_LIB_M], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +LIBM= +case $host in +*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*) + # These system don't have libm, or don't need it + ;; +*-ncr-sysv4.3*) + AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM=-lmw) + AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") + ;; +*) + AC_CHECK_LIB(m, cos, LIBM=-lm) + ;; +esac +AC_SUBST([LIBM]) +])# LT_LIB_M + +# Old name: +AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_CHECK_LIBM], []) + + +# _LT_COMPILER_NO_RTTI([TAGNAME]) +# ------------------------------- +m4_defun([_LT_COMPILER_NO_RTTI], +[m4_require([_LT_TAG_COMPILER])dnl + +_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= + +if test yes = "$GCC"; then + case $cc_basename in + nvcc*) + _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;; + *) + _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;; + esac + + _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], + lt_cv_prog_compiler_rtti_exceptions, + [-fno-rtti -fno-exceptions], [], + [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) +fi +_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], + [Compiler flag to turn off builtin functions]) +])# _LT_COMPILER_NO_RTTI + + +# _LT_CMD_GLOBAL_SYMBOLS +# ---------------------- +m4_defun([_LT_CMD_GLOBAL_SYMBOLS], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +AC_REQUIRE([AC_PROG_CC])dnl +AC_REQUIRE([AC_PROG_AWK])dnl +AC_REQUIRE([LT_PATH_NM])dnl +AC_REQUIRE([LT_PATH_LD])dnl +m4_require([_LT_DECL_SED])dnl +m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_TAG_COMPILER])dnl + +# Check for command to grab the raw symbol name followed by C symbol from nm. +AC_MSG_CHECKING([command to parse $NM output from $compiler object]) +AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], +[ +# These are sane defaults that work on at least a few old systems. +# [They come from Ultrix. What could be older than Ultrix?!! ;)] + +# Character class describing NM global symbol codes. +symcode='[[BCDEGRST]]' + +# Regexp to match symbols that can be accessed directly from C. +sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' + +# Define system-specific variables. +case $host_os in +aix*) + symcode='[[BCDT]]' + ;; +cygwin* | mingw* | pw32* | cegcc*) + symcode='[[ABCDGISTW]]' + ;; +hpux*) + if test ia64 = "$host_cpu"; then + symcode='[[ABCDEGRST]]' + fi + ;; +irix* | nonstopux*) + symcode='[[BCDEGRST]]' + ;; +osf*) + symcode='[[BCDEGQRST]]' + ;; +solaris*) + symcode='[[BDRT]]' + ;; +sco3.2v5*) + symcode='[[DT]]' + ;; +sysv4.2uw2*) + symcode='[[DT]]' + ;; +sysv5* | sco5v6* | unixware* | OpenUNIX*) + symcode='[[ABDT]]' + ;; +sysv4) + symcode='[[DFNSTU]]' + ;; +esac + +# If we're using GNU nm, then use its standard symbol codes. +case `$NM -V 2>&1` in +*GNU* | *'with BFD'*) + symcode='[[ABCDGIRSTW]]' ;; +esac + +if test "$lt_cv_nm_interface" = "MS dumpbin"; then + # Gets list of data symbols to import. + lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'" + # Adjust the below global symbol transforms to fixup imported variables. + lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'" + lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'" + lt_c_name_lib_hook="\ + -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\ + -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'" +else + # Disable hooks by default. + lt_cv_sys_global_symbol_to_import= + lt_cdecl_hook= + lt_c_name_hook= + lt_c_name_lib_hook= +fi + +# Transform an extracted symbol line into a proper C declaration. +# Some systems (esp. on ia64) link data and code symbols differently, +# so use this general approach. +lt_cv_sys_global_symbol_to_cdecl="sed -n"\ +$lt_cdecl_hook\ +" -e 's/^T .* \(.*\)$/extern int \1();/p'"\ +" -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'" + +# Transform an extracted symbol line into symbol name and symbol address +lt_cv_sys_global_symbol_to_c_name_address="sed -n"\ +$lt_c_name_hook\ +" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ +" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'" + +# Transform an extracted symbol line into symbol name with lib prefix and +# symbol address. +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\ +$lt_c_name_lib_hook\ +" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ +" -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\ +" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'" + +# Handle CRLF in mingw tool chain +opt_cr= +case $build_os in +mingw*) + opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp + ;; +esac + +# Try without a prefix underscore, then with it. +for ac_symprfx in "" "_"; do + + # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. + symxfrm="\\1 $ac_symprfx\\2 \\2" + + # Write the raw and C identifiers. + if test "$lt_cv_nm_interface" = "MS dumpbin"; then + # Fake it for dumpbin and say T for any non-static function, + # D for any global variable and I for any imported variable. + # Also find C++ and __fastcall symbols from MSVC++, + # which start with @ or ?. + lt_cv_sys_global_symbol_pipe="$AWK ['"\ +" {last_section=section; section=\$ 3};"\ +" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ +" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ +" /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\ +" /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\ +" /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\ +" \$ 0!~/External *\|/{next};"\ +" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ +" {if(hide[section]) next};"\ +" {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\ +" {split(\$ 0,a,/\||\r/); split(a[2],s)};"\ +" s[1]~/^[@?]/{print f,s[1],s[1]; next};"\ +" s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\ +" ' prfx=^$ac_symprfx]" + else + lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" + fi + lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" + + # Check to see that the pipe works correctly. + pipe_works=no + + rm -f conftest* + cat > conftest.$ac_ext <<_LT_EOF +#ifdef __cplusplus +extern "C" { +#endif +char nm_test_var; +void nm_test_func(void); +void nm_test_func(void){} +#ifdef __cplusplus +} +#endif +int main(){nm_test_var='a';nm_test_func();return(0);} +_LT_EOF + + if AC_TRY_EVAL(ac_compile); then + # Now try to grab the symbols. + nlist=conftest.nm + if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then + # Try sorting and uniquifying the output. + if sort "$nlist" | uniq > "$nlist"T; then + mv -f "$nlist"T "$nlist" + else + rm -f "$nlist"T + fi + + # Make sure that we snagged all the symbols we need. + if $GREP ' nm_test_var$' "$nlist" >/dev/null; then + if $GREP ' nm_test_func$' "$nlist" >/dev/null; then + cat <<_LT_EOF > conftest.$ac_ext +/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ +#if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE +/* DATA imports from DLLs on WIN32 can't be const, because runtime + relocations are performed -- see ld's documentation on pseudo-relocs. */ +# define LT@&t@_DLSYM_CONST +#elif defined __osf__ +/* This system does not cope well with relocations in const data. */ +# define LT@&t@_DLSYM_CONST +#else +# define LT@&t@_DLSYM_CONST const +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +_LT_EOF + # Now generate the symbol file. + eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' + + cat <<_LT_EOF >> conftest.$ac_ext + +/* The mapping between symbol names and symbols. */ +LT@&t@_DLSYM_CONST struct { + const char *name; + void *address; +} +lt__PROGRAM__LTX_preloaded_symbols[[]] = +{ + { "@PROGRAM@", (void *) 0 }, +_LT_EOF + $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext + cat <<\_LT_EOF >> conftest.$ac_ext + {0, (void *) 0} +}; + +/* This works around a problem in FreeBSD linker */ +#ifdef FREEBSD_WORKAROUND +static const void *lt_preloaded_setup() { + return lt__PROGRAM__LTX_preloaded_symbols; +} +#endif + +#ifdef __cplusplus +} +#endif +_LT_EOF + # Now try linking the two files. + mv conftest.$ac_objext conftstm.$ac_objext + lt_globsym_save_LIBS=$LIBS + lt_globsym_save_CFLAGS=$CFLAGS + LIBS=conftstm.$ac_objext + CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" + if AC_TRY_EVAL(ac_link) && test -s conftest$ac_exeext; then + pipe_works=yes + fi + LIBS=$lt_globsym_save_LIBS + CFLAGS=$lt_globsym_save_CFLAGS + else + echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD + fi + else + echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD + fi + else + echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD + fi + else + echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD + cat conftest.$ac_ext >&5 + fi + rm -rf conftest* conftst* + + # Do not use the global_symbol_pipe unless it works. + if test yes = "$pipe_works"; then + break + else + lt_cv_sys_global_symbol_pipe= + fi +done +]) +if test -z "$lt_cv_sys_global_symbol_pipe"; then + lt_cv_sys_global_symbol_to_cdecl= +fi +if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then + AC_MSG_RESULT(failed) +else + AC_MSG_RESULT(ok) +fi + +# Response file support. +if test "$lt_cv_nm_interface" = "MS dumpbin"; then + nm_file_list_spec='@' +elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then + nm_file_list_spec='@' +fi + +_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], + [Take the output of nm and produce a listing of raw symbols and C names]) +_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], + [Transform the output of nm in a proper C declaration]) +_LT_DECL([global_symbol_to_import], [lt_cv_sys_global_symbol_to_import], [1], + [Transform the output of nm into a list of symbols to manually relocate]) +_LT_DECL([global_symbol_to_c_name_address], + [lt_cv_sys_global_symbol_to_c_name_address], [1], + [Transform the output of nm in a C name address pair]) +_LT_DECL([global_symbol_to_c_name_address_lib_prefix], + [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], + [Transform the output of nm in a C name address pair when lib prefix is needed]) +_LT_DECL([nm_interface], [lt_cv_nm_interface], [1], + [The name lister interface]) +_LT_DECL([], [nm_file_list_spec], [1], + [Specify filename containing input files for $NM]) +]) # _LT_CMD_GLOBAL_SYMBOLS + + +# _LT_COMPILER_PIC([TAGNAME]) +# --------------------------- +m4_defun([_LT_COMPILER_PIC], +[m4_require([_LT_TAG_COMPILER])dnl +_LT_TAGVAR(lt_prog_compiler_wl, $1)= +_LT_TAGVAR(lt_prog_compiler_pic, $1)= +_LT_TAGVAR(lt_prog_compiler_static, $1)= + +m4_if([$1], [CXX], [ + # C++ specific cases for pic, static, wl, etc. + if test yes = "$GXX"; then + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + + case $host_os in + aix*) + # All AIX code is PIC. + if test ia64 = "$host_cpu"; then + # AIX 5 now supports IA64 processor + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + fi + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + m68k) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the '-m68020' flag to GCC prevents building anything better, + # like '-m68040'. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' + ;; + esac + ;; + + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + mingw* | cygwin* | os2* | pw32* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + m4_if([$1], [GCJ], [], + [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + case $host_os in + os2*) + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' + ;; + esac + ;; + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' + ;; + *djgpp*) + # DJGPP does not support shared libraries at all + _LT_TAGVAR(lt_prog_compiler_pic, $1)= + ;; + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + _LT_TAGVAR(lt_prog_compiler_static, $1)= + ;; + interix[[3-9]]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + sysv4*MP*) + if test -d /usr/nec; then + _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic + fi + ;; + hpux*) + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag + # sets the default TLS model and affects inlining. + case $host_cpu in + hppa*64*) + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + esac + ;; + *qnx* | *nto*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + esac + else + case $host_os in + aix[[4-9]]*) + # All AIX code is PIC. + if test ia64 = "$host_cpu"; then + # AIX 5 now supports IA64 processor + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + else + _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' + fi + ;; + chorus*) + case $cc_basename in + cxch68*) + # Green Hills C++ Compiler + # _LT_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" + ;; + esac + ;; + mingw* | cygwin* | os2* | pw32* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + m4_if([$1], [GCJ], [], + [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + ;; + dgux*) + case $cc_basename in + ec++*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + ;; + ghcx*) + # Green Hills C++ Compiler + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + ;; + *) + ;; + esac + ;; + freebsd* | dragonfly*) + # FreeBSD uses GNU C++ + ;; + hpux9* | hpux10* | hpux11*) + case $cc_basename in + CC*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' + if test ia64 != "$host_cpu"; then + _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' + fi + ;; + aCC*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' + ;; + esac + ;; + *) + ;; + esac + ;; + interix*) + # This is c89, which is MS Visual C++ (no shared libs) + # Anyone wants to do a port? + ;; + irix5* | irix6* | nonstopux*) + case $cc_basename in + CC*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + # CC pic flag -KPIC is the default. + ;; + *) + ;; + esac + ;; + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + case $cc_basename in + KCC*) + # KAI C++ Compiler + _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + ecpc* ) + # old Intel C++ for x86_64, which still supported -KPIC. + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + icpc* ) + # Intel C++, used to be incompatible with GCC. + # ICC 10 doesn't accept -KPIC any more. + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + cxx*) + # Compaq C++ + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + _LT_TAGVAR(lt_prog_compiler_pic, $1)= + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*) + # IBM XL 8.0, 9.0 on PPC and BlueGene + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' + ;; + esac + ;; + esac + ;; + lynxos*) + ;; + m88k*) + ;; + mvs*) + case $cc_basename in + cxx*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' + ;; + *) + ;; + esac + ;; + netbsd* | netbsdelf*-gnu) + ;; + *qnx* | *nto*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' + ;; + osf3* | osf4* | osf5*) + case $cc_basename in + KCC*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' + ;; + RCC*) + # Rational C++ 2.4.1 + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + ;; + cxx*) + # Digital/Compaq C++ + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + _LT_TAGVAR(lt_prog_compiler_pic, $1)= + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + *) + ;; + esac + ;; + psos*) + ;; + solaris*) + case $cc_basename in + CC* | sunCC*) + # Sun C++ 4.2, 5.x and Centerline C++ + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' + ;; + gcx*) + # Green Hills C++ Compiler + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' + ;; + *) + ;; + esac + ;; + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + lcc*) + # Lucid + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + ;; + *) + ;; + esac + ;; + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + case $cc_basename in + CC*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + esac + ;; + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + ;; + *) + ;; + esac + ;; + vxworks*) + ;; + *) + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no + ;; + esac + fi +], +[ + if test yes = "$GCC"; then + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + + case $host_os in + aix*) + # All AIX code is PIC. + if test ia64 = "$host_cpu"; then + # AIX 5 now supports IA64 processor + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + fi + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + m68k) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the '-m68020' flag to GCC prevents building anything better, + # like '-m68040'. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' + ;; + esac + ;; + + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + + mingw* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + m4_if([$1], [GCJ], [], + [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + case $host_os in + os2*) + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' + ;; + esac + ;; + + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' + ;; + + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + _LT_TAGVAR(lt_prog_compiler_static, $1)= + ;; + + hpux*) + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag + # sets the default TLS model and affects inlining. + case $host_cpu in + hppa*64*) + # +Z the default + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + esac + ;; + + interix[[3-9]]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + + msdosdjgpp*) + # Just because we use GCC doesn't mean we suddenly get shared libraries + # on systems that don't support them. + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no + enable_shared=no + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic + fi + ;; + + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + esac + + case $cc_basename in + nvcc*) # Cuda Compiler Driver 2.2 + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker ' + if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then + _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)" + fi + ;; + esac + else + # PORTME Check for flag to pass linker flags through the system compiler. + case $host_os in + aix*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + if test ia64 = "$host_cpu"; then + # AIX 5 now supports IA64 processor + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + else + _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' + fi + ;; + + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' + case $cc_basename in + nagfor*) + # NAG Fortran compiler + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + esac + ;; + + mingw* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + m4_if([$1], [GCJ], [], + [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + case $host_os in + os2*) + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' + ;; + esac + ;; + + hpux9* | hpux10* | hpux11*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' + ;; + esac + # Is there a better lt_prog_compiler_static that works with the bundled CC? + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' + ;; + + irix5* | irix6* | nonstopux*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # PIC (with -KPIC) is the default. + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + case $cc_basename in + # old Intel for x86_64, which still supported -KPIC. + ecc*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + # icc used to be incompatible with GCC. + # ICC 10 doesn't accept -KPIC any more. + icc* | ifort*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + # Lahey Fortran 8.1. + lf95*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' + _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' + ;; + nagfor*) + # NAG Fortran compiler + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + tcc*) + # Fabrice Bellard et al's Tiny C Compiler + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) + # Portland Group compilers (*not* the Pentium gcc compiler, + # which looks to be a dead project) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + ccc*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # All Alpha code is PIC. + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + xl* | bgxl* | bgf* | mpixl*) + # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*) + # Sun Fortran 8.3 passes all unrecognized flags to the linker + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_TAGVAR(lt_prog_compiler_wl, $1)='' + ;; + *Sun\ F* | *Sun*Fortran*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' + ;; + *Sun\ C*) + # Sun C 5.9 + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + ;; + *Intel*\ [[CF]]*Compiler*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + *Portland\ Group*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + esac + ;; + esac + ;; + + newsos6) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' + ;; + + osf3* | osf4* | osf5*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # All OSF/1 code is PIC. + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + + rdos*) + _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + + solaris*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + case $cc_basename in + f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; + *) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; + esac + ;; + + sunos4*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + + sysv4 | sysv4.2uw2* | sysv4.3*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + fi + ;; + + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + + unicos*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no + ;; + + uts4*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + + *) + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no + ;; + esac + fi +]) +case $host_os in + # For platforms that do not support PIC, -DPIC is meaningless: + *djgpp*) + _LT_TAGVAR(lt_prog_compiler_pic, $1)= + ;; + *) + _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" + ;; +esac + +AC_CACHE_CHECK([for $compiler option to produce PIC], + [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)], + [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) +_LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1) + +# +# Check to make sure the PIC flag actually works. +# +if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then + _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works], + [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)], + [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [], + [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in + "" | " "*) ;; + *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;; + esac], + [_LT_TAGVAR(lt_prog_compiler_pic, $1)= + _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) +fi +_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], + [Additional compiler flags for building library objects]) + +_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], + [How to pass a linker flag through the compiler]) +# +# Check to make sure the static flag actually works. +# +wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\" +_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], + _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1), + $lt_tmp_static_flag, + [], + [_LT_TAGVAR(lt_prog_compiler_static, $1)=]) +_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], + [Compiler flag to prevent dynamic linking]) +])# _LT_COMPILER_PIC + + +# _LT_LINKER_SHLIBS([TAGNAME]) +# ---------------------------- +# See if the linker supports building shared libraries. +m4_defun([_LT_LINKER_SHLIBS], +[AC_REQUIRE([LT_PATH_LD])dnl +AC_REQUIRE([LT_PATH_NM])dnl +m4_require([_LT_PATH_MANIFEST_TOOL])dnl +m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_DECL_SED])dnl +m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl +m4_require([_LT_TAG_COMPILER])dnl +AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) +m4_if([$1], [CXX], [ + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] + case $host_os in + aix[[4-9]]*) + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to GNU nm, but means don't demangle to AIX nm. + # Without the "-l" option, or with the "-B" option, AIX nm treats + # weak defined symbols like other global defined symbols, whereas + # GNU nm marks them as "W". + # While the 'weak' keyword is ignored in the Export File, we need + # it in the Import File for the 'aix-soname' feature, so we have + # to replace the "-B" option with "-P" for AIX nm. + if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then + _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' + else + _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' + fi + ;; + pw32*) + _LT_TAGVAR(export_symbols_cmds, $1)=$ltdll_cmds + ;; + cygwin* | mingw* | cegcc*) + case $cc_basename in + cl*) + _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' + ;; + *) + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' + _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] + ;; + esac + ;; + linux* | k*bsd*-gnu | gnu*) + _LT_TAGVAR(link_all_deplibs, $1)=no + ;; + *) + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + ;; + esac +], [ + runpath_var= + _LT_TAGVAR(allow_undefined_flag, $1)= + _LT_TAGVAR(always_export_symbols, $1)=no + _LT_TAGVAR(archive_cmds, $1)= + _LT_TAGVAR(archive_expsym_cmds, $1)= + _LT_TAGVAR(compiler_needs_object, $1)=no + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no + _LT_TAGVAR(export_dynamic_flag_spec, $1)= + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + _LT_TAGVAR(hardcode_automatic, $1)=no + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_direct_absolute, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= + _LT_TAGVAR(hardcode_libdir_separator, $1)= + _LT_TAGVAR(hardcode_minus_L, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported + _LT_TAGVAR(inherit_rpath, $1)=no + _LT_TAGVAR(link_all_deplibs, $1)=unknown + _LT_TAGVAR(module_cmds, $1)= + _LT_TAGVAR(module_expsym_cmds, $1)= + _LT_TAGVAR(old_archive_from_new_cmds, $1)= + _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)= + _LT_TAGVAR(thread_safe_flag_spec, $1)= + _LT_TAGVAR(whole_archive_flag_spec, $1)= + # include_expsyms should be a list of space-separated symbols to be *always* + # included in the symbol list + _LT_TAGVAR(include_expsyms, $1)= + # exclude_expsyms can be an extended regexp of symbols to exclude + # it will be wrapped by ' (' and ')$', so one must not match beginning or + # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc', + # as well as any symbol that contains 'd'. + _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] + # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out + # platforms (ab)use it in PIC code, but their linkers get confused if + # the symbol is explicitly referenced. Since portable code cannot + # rely on this symbol name, it's probably fine to never include it in + # preloaded symbol tables. + # Exclude shared library initialization/finalization symbols. +dnl Note also adjust exclude_expsyms for C++ above. + extract_expsyms_cmds= + + case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + # FIXME: the MSVC++ port hasn't been tested in a loooong time + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + if test yes != "$GCC"; then + with_gnu_ld=no + fi + ;; + interix*) + # we just hope/assume this is gcc and not c89 (= MSVC++) + with_gnu_ld=yes + ;; + openbsd* | bitrig*) + with_gnu_ld=no + ;; + linux* | k*bsd*-gnu | gnu*) + _LT_TAGVAR(link_all_deplibs, $1)=no + ;; + esac + + _LT_TAGVAR(ld_shlibs, $1)=yes + + # On some targets, GNU ld is compatible enough with the native linker + # that we're better off using the native interface for both. + lt_use_gnu_ld_interface=no + if test yes = "$with_gnu_ld"; then + case $host_os in + aix*) + # The AIX port of GNU ld has always aspired to compatibility + # with the native linker. However, as the warning in the GNU ld + # block says, versions before 2.19.5* couldn't really create working + # shared libraries, regardless of the interface used. + case `$LD -v 2>&1` in + *\ \(GNU\ Binutils\)\ 2.19.5*) ;; + *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;; + *\ \(GNU\ Binutils\)\ [[3-9]]*) ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + fi + + if test yes = "$lt_use_gnu_ld_interface"; then + # If archive_cmds runs LD, not CC, wlarc should be empty + wlarc='$wl' + + # Set some defaults for GNU ld with shared library support. These + # are reset later if shared libraries are not supported. Putting them + # here allows them to be overridden if necessary. + runpath_var=LD_RUN_PATH + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' + # ancient GNU ld didn't support --whole-archive et. al. + if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then + _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' + else + _LT_TAGVAR(whole_archive_flag_spec, $1)= + fi + supports_anon_versioning=no + case `$LD -v | $SED -e 's/([^)]\+)\s\+//' 2>&1` in + *GNU\ gold*) supports_anon_versioning=yes ;; + *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 + *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... + *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... + *\ 2.11.*) ;; # other 2.11 versions + *) supports_anon_versioning=yes ;; + esac + + # See if GNU ld supports shared libraries. + case $host_os in + aix[[3-9]]*) + # On AIX/PPC, the GNU linker is very broken + if test ia64 != "$host_cpu"; then + _LT_TAGVAR(ld_shlibs, $1)=no + cat <<_LT_EOF 1>&2 + +*** Warning: the GNU linker, at least up to release 2.19, is reported +*** to be unable to reliably create shared libraries on AIX. +*** Therefore, libtool is disabling shared libraries support. If you +*** really care for shared libraries, you may want to install binutils +*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. +*** You will then need to restart the configuration process. + +_LT_EOF + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='' + ;; + m68k) + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_minus_L, $1)=yes + ;; + esac + ;; + + beos*) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + cygwin* | mingw* | pw32* | cegcc*) + # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, + # as there is no search path for DLLs. + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(always_export_symbols, $1)=no + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' + _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] + + if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file, use it as + # is; otherwise, prepend EXPORTS... + _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + haiku*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + + os2*) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + shrext_cmds=.dll + _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + prefix_cmds="$SED"~ + if test EXPORTS = "`$SED 1q $export_symbols`"; then + prefix_cmds="$prefix_cmds -e 1d"; + fi~ + prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ + cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + ;; + + interix[[3-9]]*) + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + + gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) + tmp_diet=no + if test linux-dietlibc = "$host_os"; then + case $cc_basename in + diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) + esac + fi + if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ + && test no = "$tmp_diet" + then + tmp_addflag=' $pic_flag' + tmp_sharedflag='-shared' + case $cc_basename,$host_cpu in + pgcc*) # Portland Group C compiler + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + tmp_addflag=' $pic_flag' + ;; + pgf77* | pgf90* | pgf95* | pgfortran*) + # Portland Group f77 and f90 compilers + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + tmp_addflag=' $pic_flag -Mnomain' ;; + ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 + tmp_addflag=' -i_dynamic' ;; + efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 + tmp_addflag=' -i_dynamic -nofor_main' ;; + ifc* | ifort*) # Intel Fortran compiler + tmp_addflag=' -nofor_main' ;; + lf95*) # Lahey Fortran 8.1 + _LT_TAGVAR(whole_archive_flag_spec, $1)= + tmp_sharedflag='--shared' ;; + nagfor*) # NAGFOR 5.3 + tmp_sharedflag='-Wl,-shared' ;; + xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) + tmp_sharedflag='-qmkshrobj' + tmp_addflag= ;; + nvcc*) # Cuda Compiler Driver 2.2 + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + _LT_TAGVAR(compiler_needs_object, $1)=yes + ;; + esac + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) # Sun C 5.9 + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + _LT_TAGVAR(compiler_needs_object, $1)=yes + tmp_sharedflag='-G' ;; + *Sun\ F*) # Sun Fortran 8.3 + tmp_sharedflag='-G' ;; + esac + _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + + if test yes = "$supports_anon_versioning"; then + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' + fi + + case $cc_basename in + tcc*) + _LT_TAGVAR(export_dynamic_flag_spec, $1)='-rdynamic' + ;; + xlf* | bgf* | bgxlf* | mpixlf*) + # IBM XL Fortran 10.1 on PPC cannot create shared libs itself + _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' + if test yes = "$supports_anon_versioning"; then + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' + fi + ;; + esac + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + netbsd* | netbsdelf*-gnu) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' + wlarc= + else + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + fi + ;; + + solaris*) + if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then + _LT_TAGVAR(ld_shlibs, $1)=no + cat <<_LT_EOF 1>&2 + +*** Warning: The releases 2.8.* of the GNU linker cannot reliably +*** create shared libraries on Solaris systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.9.1 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +_LT_EOF + elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) + case `$LD -v 2>&1` in + *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) + _LT_TAGVAR(ld_shlibs, $1)=no + cat <<_LT_EOF 1>&2 + +*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot +*** reliably create shared libraries on SCO systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.16.91.0.3 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +_LT_EOF + ;; + *) + # For security reasons, it is highly recommended that you always + # use absolute paths for naming shared libraries, and exclude the + # DT_RUNPATH tag from executables and libraries. But doing so + # requires that you compile everything twice, which is a pain. + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + + sunos4*) + _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' + wlarc= + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + *) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + + if test no = "$_LT_TAGVAR(ld_shlibs, $1)"; then + runpath_var= + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= + _LT_TAGVAR(export_dynamic_flag_spec, $1)= + _LT_TAGVAR(whole_archive_flag_spec, $1)= + fi + else + # PORTME fill in a description of your system's linker (not GNU ld) + case $host_os in + aix3*) + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(always_export_symbols, $1)=yes + _LT_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' + # Note: this linker hardcodes the directories in LIBPATH if there + # are no directories specified by -L. + _LT_TAGVAR(hardcode_minus_L, $1)=yes + if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then + # Neither direct hardcoding nor static linking is supported with a + # broken collect2. + _LT_TAGVAR(hardcode_direct, $1)=unsupported + fi + ;; + + aix[[4-9]]*) + if test ia64 = "$host_cpu"; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag= + else + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to GNU nm, but means don't demangle to AIX nm. + # Without the "-l" option, or with the "-B" option, AIX nm treats + # weak defined symbols like other global defined symbols, whereas + # GNU nm marks them as "W". + # While the 'weak' keyword is ignored in the Export File, we need + # it in the Import File for the 'aix-soname' feature, so we have + # to replace the "-B" option with "-P" for AIX nm. + if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then + _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' + else + _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' + fi + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # have runtime linking enabled, and use it for executables. + # For shared libraries, we enable/disable runtime linking + # depending on the kind of the shared library created - + # when "with_aix_soname,aix_use_runtimelinking" is: + # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables + # "aix,yes" lib.so shared, rtl:yes, for executables + # lib.a static archive + # "both,no" lib.so.V(shr.o) shared, rtl:yes + # lib.a(lib.so.V) shared, rtl:no, for executables + # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a(lib.so.V) shared, rtl:no + # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a static archive + case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) + for ld_flag in $LDFLAGS; do + if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then + aix_use_runtimelinking=yes + break + fi + done + if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then + # With aix-soname=svr4, we create the lib.so.V shared archives only, + # so we don't have lib.a shared libs to link our executables. + # We have to force runtime linking in this case. + aix_use_runtimelinking=yes + LDFLAGS="$LDFLAGS -Wl,-brtl" + fi + ;; + esac + + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + _LT_TAGVAR(archive_cmds, $1)='' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(hardcode_libdir_separator, $1)=':' + _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='$wl-f,' + case $with_aix_soname,$aix_use_runtimelinking in + aix,*) ;; # traditional, no import file + svr4,* | *,yes) # use import file + # The Import File defines what to hardcode. + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_direct_absolute, $1)=no + ;; + esac + + if test yes = "$GCC"; then + case $host_os in aix4.[[012]]|aix4.[[012]].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`$CC -print-prog-name=collect2` + if test -f "$collect2name" && + strings "$collect2name" | $GREP resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + _LT_TAGVAR(hardcode_direct, $1)=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)= + fi + ;; + esac + shared_flag='-shared' + if test yes = "$aix_use_runtimelinking"; then + shared_flag="$shared_flag "'$wl-G' + fi + # Need to ensure runtime linking is disabled for the traditional + # shared library, or the linker may eventually find shared libraries + # /with/ Import File - we do not want to mix them. + shared_flag_aix='-shared' + shared_flag_svr4='-shared $wl-G' + else + # not using gcc + if test ia64 = "$host_cpu"; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test yes = "$aix_use_runtimelinking"; then + shared_flag='$wl-G' + else + shared_flag='$wl-bM:SRE' + fi + shared_flag_aix='$wl-bM:SRE' + shared_flag_svr4='$wl-G' + fi + fi + + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to export. + _LT_TAGVAR(always_export_symbols, $1)=yes + if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + _LT_TAGVAR(allow_undefined_flag, $1)='-berok' + # Determine the default libpath from the value encoded in an + # empty executable. + _LT_SYS_MODULE_PATH_AIX([$1]) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag + else + if test ia64 = "$host_cpu"; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' + _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" + _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an + # empty executable. + _LT_SYS_MODULE_PATH_AIX([$1]) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' + if test yes = "$with_gnu_ld"; then + # We only use this code for GNU lds that support --whole-archive. + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' + fi + _LT_TAGVAR(archive_cmds_need_lc, $1)=yes + _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' + # -brtl affects multiple linker settings, -berok does not and is overridden later + compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' + if test svr4 != "$with_aix_soname"; then + # This is similar to how AIX traditionally builds its shared libraries. + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' + fi + if test aix != "$with_aix_soname"; then + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' + else + # used by -dlpreopen to get the symbols + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' + fi + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' + fi + fi + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='' + ;; + m68k) + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_minus_L, $1)=yes + ;; + esac + ;; + + bsdi[[45]]*) + _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic + ;; + + cygwin* | mingw* | pw32* | cegcc*) + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + case $cc_basename in + cl*) + # Native MSVC + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(always_export_symbols, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='@' + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=.dll + # FIXME: Setting linknames here is a bad hack. + _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' + _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then + cp "$export_symbols" "$output_objdir/$soname.def"; + echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; + else + $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1,DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' + # Don't use ranlib + _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' + _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile=$lt_outputfile.exe + lt_tool_outputfile=$lt_tool_outputfile.exe + ;; + esac~ + if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # Assume MSVC wrapper + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=.dll + # FIXME: Setting linknames here is a bad hack. + _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' + # The linker will automatically build a .lib file if we build a DLL. + _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' + # FIXME: Should let the user specify the lib program. + _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + ;; + esac + ;; + + darwin* | rhapsody*) + _LT_DARWIN_LINKER_FEATURES($1) + ;; + + dgux*) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor + # support. Future versions do this automatically, but an explicit c++rt0.o + # does not break anything, and helps significantly (at the cost of a little + # extra space). + freebsd2.2*) + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + # Unfortunately, older versions of FreeBSD 2 do not have this feature. + freebsd2.*) + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + # FreeBSD 3 and greater uses gcc -shared to do shared libraries. + freebsd* | dragonfly*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + hpux9*) + if test yes = "$GCC"; then + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' + else + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' + fi + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(hardcode_direct, $1)=yes + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' + ;; + + hpux10*) + if test yes,no = "$GCC,$with_gnu_ld"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + else + _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' + fi + if test no = "$with_gnu_ld"; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + _LT_TAGVAR(hardcode_minus_L, $1)=yes + fi + ;; + + hpux11*) + if test yes,no = "$GCC,$with_gnu_ld"; then + case $host_cpu in + hppa*64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + else + case $host_cpu in + hppa*64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + m4_if($1, [], [ + # Older versions of the 11.00 compiler do not understand -b yet + # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) + _LT_LINKER_OPTION([if $CC understands -b], + _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b], + [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], + [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])], + [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags']) + ;; + esac + fi + if test no = "$with_gnu_ld"; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + case $host_cpu in + hppa*64*|ia64*) + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + *) + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + _LT_TAGVAR(hardcode_minus_L, $1)=yes + ;; + esac + fi + ;; + + irix5* | irix6* | nonstopux*) + if test yes = "$GCC"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + # Try to use the -exported_symbol ld option, if it does not + # work, assume that -exports_file does not work either and + # implicitly export all symbols. + # This should be the same for all languages, so no per-tag cache variable. + AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol], + [lt_cv_irix_exported_symbol], + [save_LDFLAGS=$LDFLAGS + LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null" + AC_LINK_IFELSE( + [AC_LANG_SOURCE( + [AC_LANG_CASE([C], [[int foo (void) { return 0; }]], + [C++], [[int foo (void) { return 0; }]], + [Fortran 77], [[ + subroutine foo + end]], + [Fortran], [[ + subroutine foo + end]])])], + [lt_cv_irix_exported_symbol=yes], + [lt_cv_irix_exported_symbol=no]) + LDFLAGS=$save_LDFLAGS]) + if test yes = "$lt_cv_irix_exported_symbol"; then + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib' + fi + _LT_TAGVAR(link_all_deplibs, $1)=no + else + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib' + fi + _LT_TAGVAR(archive_cmds_need_lc, $1)='no' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(inherit_rpath, $1)=yes + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + + linux*) + case $cc_basename in + tcc*) + # Fabrice Bellard et al's Tiny C Compiler + _LT_TAGVAR(ld_shlibs, $1)=yes + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + netbsd* | netbsdelf*-gnu) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out + else + _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF + fi + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + newsos6) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + *nto* | *qnx*) + ;; + + openbsd* | bitrig*) + if test -f /usr/libexec/ld.so; then + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' + else + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + fi + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + os2*) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + shrext_cmds=.dll + _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + prefix_cmds="$SED"~ + if test EXPORTS = "`$SED 1q $export_symbols`"; then + prefix_cmds="$prefix_cmds -e 1d"; + fi~ + prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ + cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + ;; + + osf3*) + if test yes = "$GCC"; then + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + else + _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + fi + _LT_TAGVAR(archive_cmds_need_lc, $1)='no' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + ;; + + osf4* | osf5*) # as osf3* with the addition of -msym flag + if test yes = "$GCC"; then + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + else + _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ + $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp' + + # Both c and cxx compiler support -rpath directly + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' + fi + _LT_TAGVAR(archive_cmds_need_lc, $1)='no' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + ;; + + solaris*) + _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' + if test yes = "$GCC"; then + wlarc='$wl' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + else + case `$CC -V 2>&1` in + *"Compilers 5.0"*) + wlarc='' + _LT_TAGVAR(archive_cmds, $1)='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' + ;; + *) + wlarc='$wl' + _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + ;; + esac + fi + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + case $host_os in + solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands '-z linker_flag'. GCC discards it without '$wl', + # but is careful enough not to reorder. + # Supported since Solaris 2.6 (maybe 2.5.1?) + if test yes = "$GCC"; then + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' + else + _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' + fi + ;; + esac + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + + sunos4*) + if test sequent = "$host_vendor"; then + # Use $CC to link under sequent, because it throws in some extra .o + # files that make .init and .fini sections work. + _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags' + else + _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' + fi + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + sysv4) + case $host_vendor in + sni) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true??? + ;; + siemens) + ## LD is ld it makes a PLAMLIB + ## CC just makes a GrossModule. + _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' + _LT_TAGVAR(hardcode_direct, $1)=no + ;; + motorola) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie + ;; + esac + runpath_var='LD_RUN_PATH' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + sysv4.3*) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + runpath_var=LD_RUN_PATH + hardcode_runpath_var=yes + _LT_TAGVAR(ld_shlibs, $1)=yes + fi + ;; + + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) + _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + runpath_var='LD_RUN_PATH' + + if test yes = "$GCC"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + + sysv5* | sco3.2v5* | sco5v6*) + # Note: We CANNOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' + _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=':' + _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' + runpath_var='LD_RUN_PATH' + + if test yes = "$GCC"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + + uts4*) + _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + + *) + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + + if test sni = "$host_vendor"; then + case $host in + sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Blargedynsym' + ;; + esac + fi + fi +]) +AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) +test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no + +_LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld + +_LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl +_LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl +_LT_DECL([], [extract_expsyms_cmds], [2], + [The commands to extract the exported symbol list from a shared archive]) + +# +# Do we need to explicitly link libc? +# +case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in +x|xyes) + # Assume -lc should be added + _LT_TAGVAR(archive_cmds_need_lc, $1)=yes + + if test yes,yes = "$GCC,$enable_shared"; then + case $_LT_TAGVAR(archive_cmds, $1) in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + AC_CACHE_CHECK([whether -lc should be explicitly linked in], + [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1), + [$RM conftest* + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + if AC_TRY_EVAL(ac_compile) 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) + pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1) + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1) + _LT_TAGVAR(allow_undefined_flag, $1)= + if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) + then + lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no + else + lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes + fi + _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $RM conftest* + ]) + _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1) + ;; + esac + fi + ;; +esac + +_LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0], + [Whether or not to add -lc for building shared libraries]) +_LT_TAGDECL([allow_libtool_libs_with_static_runtimes], + [enable_shared_with_static_runtimes], [0], + [Whether or not to disallow shared libs when runtime libs are static]) +_LT_TAGDECL([], [export_dynamic_flag_spec], [1], + [Compiler flag to allow reflexive dlopens]) +_LT_TAGDECL([], [whole_archive_flag_spec], [1], + [Compiler flag to generate shared objects directly from archives]) +_LT_TAGDECL([], [compiler_needs_object], [1], + [Whether the compiler copes with passing no objects directly]) +_LT_TAGDECL([], [old_archive_from_new_cmds], [2], + [Create an old-style archive from a shared archive]) +_LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2], + [Create a temporary old-style archive to link instead of a shared archive]) +_LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive]) +_LT_TAGDECL([], [archive_expsym_cmds], [2]) +_LT_TAGDECL([], [module_cmds], [2], + [Commands used to build a loadable module if different from building + a shared archive.]) +_LT_TAGDECL([], [module_expsym_cmds], [2]) +_LT_TAGDECL([], [with_gnu_ld], [1], + [Whether we are building with GNU ld or not]) +_LT_TAGDECL([], [allow_undefined_flag], [1], + [Flag that allows shared libraries with undefined symbols to be built]) +_LT_TAGDECL([], [no_undefined_flag], [1], + [Flag that enforces no undefined symbols]) +_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], + [Flag to hardcode $libdir into a binary during linking. + This must work even if $libdir does not exist]) +_LT_TAGDECL([], [hardcode_libdir_separator], [1], + [Whether we need a single "-rpath" flag with a separated argument]) +_LT_TAGDECL([], [hardcode_direct], [0], + [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes + DIR into the resulting binary]) +_LT_TAGDECL([], [hardcode_direct_absolute], [0], + [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes + DIR into the resulting binary and the resulting library dependency is + "absolute", i.e impossible to change by setting $shlibpath_var if the + library is relocated]) +_LT_TAGDECL([], [hardcode_minus_L], [0], + [Set to "yes" if using the -LDIR flag during linking hardcodes DIR + into the resulting binary]) +_LT_TAGDECL([], [hardcode_shlibpath_var], [0], + [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR + into the resulting binary]) +_LT_TAGDECL([], [hardcode_automatic], [0], + [Set to "yes" if building a shared library automatically hardcodes DIR + into the library and all subsequent libraries and executables linked + against it]) +_LT_TAGDECL([], [inherit_rpath], [0], + [Set to yes if linker adds runtime paths of dependent libraries + to runtime path list]) +_LT_TAGDECL([], [link_all_deplibs], [0], + [Whether libtool must link a program against all its dependency libraries]) +_LT_TAGDECL([], [always_export_symbols], [0], + [Set to "yes" if exported symbols are required]) +_LT_TAGDECL([], [export_symbols_cmds], [2], + [The commands to list exported symbols]) +_LT_TAGDECL([], [exclude_expsyms], [1], + [Symbols that should not be listed in the preloaded symbols]) +_LT_TAGDECL([], [include_expsyms], [1], + [Symbols that must always be exported]) +_LT_TAGDECL([], [prelink_cmds], [2], + [Commands necessary for linking programs (against libraries) with templates]) +_LT_TAGDECL([], [postlink_cmds], [2], + [Commands necessary for finishing linking programs]) +_LT_TAGDECL([], [file_list_spec], [1], + [Specify filename containing input files]) +dnl FIXME: Not yet implemented +dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1], +dnl [Compiler flag to generate thread safe objects]) +])# _LT_LINKER_SHLIBS + + +# _LT_LANG_C_CONFIG([TAG]) +# ------------------------ +# Ensure that the configuration variables for a C compiler are suitably +# defined. These variables are subsequently used by _LT_CONFIG to write +# the compiler configuration to 'libtool'. +m4_defun([_LT_LANG_C_CONFIG], +[m4_require([_LT_DECL_EGREP])dnl +lt_save_CC=$CC +AC_LANG_PUSH(C) + +# Source file extension for C test sources. +ac_ext=c + +# Object file extension for compiled C test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code="int some_variable = 0;" + +# Code to be used in simple link tests +lt_simple_link_test_code='int main(){return(0);}' + +_LT_TAG_COMPILER +# Save the default compiler, since it gets overwritten when the other +# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. +compiler_DEFAULT=$CC + +# save warnings/boilerplate of simple test code +_LT_COMPILER_BOILERPLATE +_LT_LINKER_BOILERPLATE + +## CAVEAT EMPTOR: +## There is no encapsulation within the following macros, do not change +## the running order or otherwise move them around unless you know exactly +## what you are doing... +if test -n "$compiler"; then + _LT_COMPILER_NO_RTTI($1) + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_SYS_DYNAMIC_LINKER($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + LT_SYS_DLOPEN_SELF + _LT_CMD_STRIPLIB + + # Report what library types will actually be built + AC_MSG_CHECKING([if libtool supports shared libraries]) + AC_MSG_RESULT([$can_build_shared]) + + AC_MSG_CHECKING([whether to build shared libraries]) + test no = "$can_build_shared" && enable_shared=no + + # On AIX, shared libraries and static libraries use the same namespace, and + # are all built from PIC. + case $host_os in + aix3*) + test yes = "$enable_shared" && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; + + aix[[4-9]]*) + if test ia64 != "$host_cpu"; then + case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in + yes,aix,yes) ;; # shared object as lib.so file only + yes,svr4,*) ;; # shared object as lib.so archive member only + yes,*) enable_static=no ;; # shared object in lib.a archive as well + esac + fi + ;; + esac + AC_MSG_RESULT([$enable_shared]) + + AC_MSG_CHECKING([whether to build static libraries]) + # Make sure either enable_shared or enable_static is yes. + test yes = "$enable_shared" || enable_static=yes + AC_MSG_RESULT([$enable_static]) + + _LT_CONFIG($1) +fi +AC_LANG_POP +CC=$lt_save_CC +])# _LT_LANG_C_CONFIG + + +# _LT_LANG_CXX_CONFIG([TAG]) +# -------------------------- +# Ensure that the configuration variables for a C++ compiler are suitably +# defined. These variables are subsequently used by _LT_CONFIG to write +# the compiler configuration to 'libtool'. +m4_defun([_LT_LANG_CXX_CONFIG], +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl +m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_PATH_MANIFEST_TOOL])dnl +if test -n "$CXX" && ( test no != "$CXX" && + ( (test g++ = "$CXX" && `g++ -v >/dev/null 2>&1` ) || + (test g++ != "$CXX"))); then + AC_PROG_CXXCPP +else + _lt_caught_CXX_error=yes +fi + +AC_LANG_PUSH(C++) +_LT_TAGVAR(archive_cmds_need_lc, $1)=no +_LT_TAGVAR(allow_undefined_flag, $1)= +_LT_TAGVAR(always_export_symbols, $1)=no +_LT_TAGVAR(archive_expsym_cmds, $1)= +_LT_TAGVAR(compiler_needs_object, $1)=no +_LT_TAGVAR(export_dynamic_flag_spec, $1)= +_LT_TAGVAR(hardcode_direct, $1)=no +_LT_TAGVAR(hardcode_direct_absolute, $1)=no +_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= +_LT_TAGVAR(hardcode_libdir_separator, $1)= +_LT_TAGVAR(hardcode_minus_L, $1)=no +_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported +_LT_TAGVAR(hardcode_automatic, $1)=no +_LT_TAGVAR(inherit_rpath, $1)=no +_LT_TAGVAR(module_cmds, $1)= +_LT_TAGVAR(module_expsym_cmds, $1)= +_LT_TAGVAR(link_all_deplibs, $1)=unknown +_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_TAGVAR(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds +_LT_TAGVAR(no_undefined_flag, $1)= +_LT_TAGVAR(whole_archive_flag_spec, $1)= +_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no + +# Source file extension for C++ test sources. +ac_ext=cpp + +# Object file extension for compiled C++ test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# No sense in running all these tests if we already determined that +# the CXX compiler isn't working. Some variables (like enable_shared) +# are currently assumed to apply to all compilers on this platform, +# and will be corrupted by setting them based on a non-working compiler. +if test yes != "$_lt_caught_CXX_error"; then + # Code to be used in simple compile tests + lt_simple_compile_test_code="int some_variable = 0;" + + # Code to be used in simple link tests + lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' + + # ltmain only uses $CC for tagged configurations so make sure $CC is set. + _LT_TAG_COMPILER + + # save warnings/boilerplate of simple test code + _LT_COMPILER_BOILERPLATE + _LT_LINKER_BOILERPLATE + + # Allow CC to be a program name with arguments. + lt_save_CC=$CC + lt_save_CFLAGS=$CFLAGS + lt_save_LD=$LD + lt_save_GCC=$GCC + GCC=$GXX + lt_save_with_gnu_ld=$with_gnu_ld + lt_save_path_LD=$lt_cv_path_LD + if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then + lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx + else + $as_unset lt_cv_prog_gnu_ld + fi + if test -n "${lt_cv_path_LDCXX+set}"; then + lt_cv_path_LD=$lt_cv_path_LDCXX + else + $as_unset lt_cv_path_LD + fi + test -z "${LDCXX+set}" || LD=$LDCXX + CC=${CXX-"c++"} + CFLAGS=$CXXFLAGS + compiler=$CC + _LT_TAGVAR(compiler, $1)=$CC + _LT_CC_BASENAME([$compiler]) + + if test -n "$compiler"; then + # We don't want -fno-exception when compiling C++ code, so set the + # no_builtin_flag separately + if test yes = "$GXX"; then + _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' + else + _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= + fi + + if test yes = "$GXX"; then + # Set up default GNU C++ configuration + + LT_PATH_LD + + # Check if GNU C++ uses GNU ld as the underlying linker, since the + # archiving commands below assume that GNU ld is being used. + if test yes = "$with_gnu_ld"; then + _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' + + # If archive_cmds runs LD, not CC, wlarc should be empty + # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to + # investigate it a little bit more. (MM) + wlarc='$wl' + + # ancient GNU ld didn't support --whole-archive et. al. + if eval "`$CC -print-prog-name=ld` --help 2>&1" | + $GREP 'no-whole-archive' > /dev/null; then + _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' + else + _LT_TAGVAR(whole_archive_flag_spec, $1)= + fi + else + with_gnu_ld=no + wlarc= + + # A generic and very simple default shared library creation + # command for GNU C++ for the case where it uses the native + # linker, instead of GNU ld. If possible, this setting should + # overridden to take advantage of the native linker features on + # the platform it is being used on. + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' + fi + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + + else + GXX=no + with_gnu_ld=no + wlarc= + fi + + # PORTME: fill in a description of your system's C++ link characteristics + AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) + _LT_TAGVAR(ld_shlibs, $1)=yes + case $host_os in + aix3*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + aix[[4-9]]*) + if test ia64 = "$host_cpu"; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag= + else + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # have runtime linking enabled, and use it for executables. + # For shared libraries, we enable/disable runtime linking + # depending on the kind of the shared library created - + # when "with_aix_soname,aix_use_runtimelinking" is: + # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables + # "aix,yes" lib.so shared, rtl:yes, for executables + # lib.a static archive + # "both,no" lib.so.V(shr.o) shared, rtl:yes + # lib.a(lib.so.V) shared, rtl:no, for executables + # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a(lib.so.V) shared, rtl:no + # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a static archive + case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) + for ld_flag in $LDFLAGS; do + case $ld_flag in + *-brtl*) + aix_use_runtimelinking=yes + break + ;; + esac + done + if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then + # With aix-soname=svr4, we create the lib.so.V shared archives only, + # so we don't have lib.a shared libs to link our executables. + # We have to force runtime linking in this case. + aix_use_runtimelinking=yes + LDFLAGS="$LDFLAGS -Wl,-brtl" + fi + ;; + esac + + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + _LT_TAGVAR(archive_cmds, $1)='' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(hardcode_libdir_separator, $1)=':' + _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='$wl-f,' + case $with_aix_soname,$aix_use_runtimelinking in + aix,*) ;; # no import file + svr4,* | *,yes) # use import file + # The Import File defines what to hardcode. + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_direct_absolute, $1)=no + ;; + esac + + if test yes = "$GXX"; then + case $host_os in aix4.[[012]]|aix4.[[012]].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`$CC -print-prog-name=collect2` + if test -f "$collect2name" && + strings "$collect2name" | $GREP resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + _LT_TAGVAR(hardcode_direct, $1)=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)= + fi + esac + shared_flag='-shared' + if test yes = "$aix_use_runtimelinking"; then + shared_flag=$shared_flag' $wl-G' + fi + # Need to ensure runtime linking is disabled for the traditional + # shared library, or the linker may eventually find shared libraries + # /with/ Import File - we do not want to mix them. + shared_flag_aix='-shared' + shared_flag_svr4='-shared $wl-G' + else + # not using gcc + if test ia64 = "$host_cpu"; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test yes = "$aix_use_runtimelinking"; then + shared_flag='$wl-G' + else + shared_flag='$wl-bM:SRE' + fi + shared_flag_aix='$wl-bM:SRE' + shared_flag_svr4='$wl-G' + fi + fi + + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to + # export. + _LT_TAGVAR(always_export_symbols, $1)=yes + if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + # The "-G" linker flag allows undefined symbols. + _LT_TAGVAR(no_undefined_flag, $1)='-bernotok' + # Determine the default libpath from the value encoded in an empty + # executable. + _LT_SYS_MODULE_PATH_AIX([$1]) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" + + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag + else + if test ia64 = "$host_cpu"; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' + _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" + _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an + # empty executable. + _LT_SYS_MODULE_PATH_AIX([$1]) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' + if test yes = "$with_gnu_ld"; then + # We only use this code for GNU lds that support --whole-archive. + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' + fi + _LT_TAGVAR(archive_cmds_need_lc, $1)=yes + _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' + # -brtl affects multiple linker settings, -berok does not and is overridden later + compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' + if test svr4 != "$with_aix_soname"; then + # This is similar to how AIX traditionally builds its shared + # libraries. Need -bnortl late, we may have -brtl in LDFLAGS. + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' + fi + if test aix != "$with_aix_soname"; then + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' + else + # used by -dlpreopen to get the symbols + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' + fi + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' + fi + fi + ;; + + beos*) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + chorus*) + case $cc_basename in + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + + cygwin* | mingw* | pw32* | cegcc*) + case $GXX,$cc_basename in + ,cl* | no,cl*) + # Native MSVC + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(always_export_symbols, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='@' + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=.dll + # FIXME: Setting linknames here is a bad hack. + _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' + _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then + cp "$export_symbols" "$output_objdir/$soname.def"; + echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; + else + $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + # Don't use ranlib + _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' + _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile=$lt_outputfile.exe + lt_tool_outputfile=$lt_tool_outputfile.exe + ;; + esac~ + func_to_tool_file "$lt_outputfile"~ + if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # g++ + # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, + # as there is no search path for DLLs. + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(always_export_symbols, $1)=no + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + + if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file, use it as + # is; otherwise, prepend EXPORTS... + _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + darwin* | rhapsody*) + _LT_DARWIN_LINKER_FEATURES($1) + ;; + + os2*) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + shrext_cmds=.dll + _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + prefix_cmds="$SED"~ + if test EXPORTS = "`$SED 1q $export_symbols`"; then + prefix_cmds="$prefix_cmds -e 1d"; + fi~ + prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ + cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + ;; + + dgux*) + case $cc_basename in + ec++*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + ghcx*) + # Green Hills C++ Compiler + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + + freebsd2.*) + # C++ shared libraries reported to be fairly broken before + # switch to ELF + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + freebsd-elf*) + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + ;; + + freebsd* | dragonfly*) + # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF + # conventions + _LT_TAGVAR(ld_shlibs, $1)=yes + ;; + + haiku*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + + hpux9*) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, + # but as the default + # location of the library. + + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + aCC*) + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test yes = "$GXX"; then + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' + else + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + + hpux10*|hpux11*) + if test no = "$with_gnu_ld"; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + case $host_cpu in + hppa*64*|ia64*) + ;; + *) + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' + ;; + esac + fi + case $host_cpu in + hppa*64*|ia64*) + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + *) + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, + # but as the default + # location of the library. + ;; + esac + + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + aCC*) + case $host_cpu in + hppa*64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + ia64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + esac + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test yes = "$GXX"; then + if test no = "$with_gnu_ld"; then + case $host_cpu in + hppa*64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + ia64*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + esac + fi + else + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + + interix[[3-9]]*) + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + irix5* | irix6*) + case $cc_basename in + CC*) + # SGI C++ + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + + # Archives containing C++ object files must be created using + # "CC -ar", where "CC" is the IRIX C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' + ;; + *) + if test yes = "$GXX"; then + if test no = "$with_gnu_ld"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + else + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` -o $lib' + fi + fi + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + esac + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_TAGVAR(inherit_rpath, $1)=yes + ;; + + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib $wl-retain-symbols-file,$export_symbols; mv \$templib $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' + + # Archives containing C++ object files must be created using + # "CC -Bstatic", where "CC" is the KAI C++ compiler. + _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' + ;; + icpc* | ecpc* ) + # Intel C++ + with_gnu_ld=yes + # version 8.0 and above of icpc choke on multiply defined symbols + # if we add $predep_objects and $postdep_objects, however 7.1 and + # earlier do not add the objects themselves. + case `$CC -V 2>&1` in + *"Version 7."*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + ;; + *) # Version 8.0 or newer + tmp_idyn= + case $host_cpu in + ia64*) tmp_idyn=' -i_dynamic';; + esac + _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + ;; + esac + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' + ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler + case `$CC -V` in + *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*) + _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ + compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' + _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ + $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ + $RANLIB $oldlib' + _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + ;; + *) # Version 6 and above use weak symbols + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + ;; + esac + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl--rpath $wl$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + ;; + cxx*) + # Compaq C++ + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib $wl-retain-symbols-file $wl$export_symbols' + + runpath_var=LD_RUN_PATH + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' + ;; + xl* | mpixl* | bgxl*) + # IBM XL 8.0 on PPC, with GNU ld + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' + _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + if test yes = "$supports_anon_versioning"; then + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' + fi + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' + _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file $wl$export_symbols' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' + _LT_TAGVAR(compiler_needs_object, $1)=yes + + # Not sure whether something based on + # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 + # would be better. + output_verbose_link_cmd='func_echo_all' + + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' + ;; + esac + ;; + esac + ;; + + lynxos*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + m88k*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + mvs*) + case $cc_basename in + cxx*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + + netbsd*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' + wlarc= + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + fi + # Workaround some broken pre-1.5 toolchains + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' + ;; + + *nto* | *qnx*) + _LT_TAGVAR(ld_shlibs, $1)=yes + ;; + + openbsd* | bitrig*) + if test -f /usr/libexec/ld.so; then + _LT_TAGVAR(hardcode_direct, $1)=yes + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_direct_absolute, $1)=yes + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`"; then + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file,$export_symbols -o $lib' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' + _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' + fi + output_verbose_link_cmd=func_echo_all + else + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + + osf3* | osf4* | osf5*) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + # Archives containing C++ object files must be created using + # the KAI C++ compiler. + case $host in + osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; + *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;; + esac + ;; + RCC*) + # Rational C++ 2.4.1 + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + cxx*) + case $host in + osf3*) + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $soname `test -n "$verstring" && func_echo_all "$wl-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + ;; + *) + _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ + echo "-hidden">> $lib.exp~ + $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname $wl-input $wl$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~ + $RM $lib.exp' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' + ;; + esac + + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + ;; + *) + if test yes,no = "$GXX,$with_gnu_ld"; then + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' + case $host in + osf3*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + ;; + esac + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + + else + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + + psos*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + lcc*) + # Lucid + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + + solaris*) + case $cc_basename in + CC* | sunCC*) + # Sun C++ 4.2, 5.x and Centerline C++ + _LT_TAGVAR(archive_cmds_need_lc,$1)=yes + _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' + _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G$allow_undefined_flag $wl-M $wl$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + case $host_os in + solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands '-z linker_flag'. + # Supported since Solaris 2.6 (maybe 2.5.1?) + _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' + ;; + esac + _LT_TAGVAR(link_all_deplibs, $1)=yes + + output_verbose_link_cmd='func_echo_all' + + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' + ;; + gcx*) + # Green Hills C++ Compiler + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' + + # The C++ compiler must be used to create the archive. + _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' + ;; + *) + # GNU C++ compiler with Solaris linker + if test yes,no = "$GXX,$with_gnu_ld"; then + _LT_TAGVAR(no_undefined_flag, $1)=' $wl-z ${wl}defs' + if $CC --version | $GREP -v '^2\.7' > /dev/null; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -shared $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + else + # g++ 2.7 appears to require '-G' NOT '-shared' on this + # platform. + _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ + $CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + fi + + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $wl$libdir' + case $host_os in + solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; + *) + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' + ;; + esac + fi + ;; + esac + ;; + + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) + _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + sysv5* | sco3.2v5* | sco5v6*) + # Note: We CANNOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' + _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' + _LT_TAGVAR(hardcode_libdir_separator, $1)=':' + _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~ + '"$_LT_TAGVAR(old_archive_cmds, $1)" + _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~ + '"$_LT_TAGVAR(reload_cmds, $1)" + ;; + *) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + + vxworks*) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + + *) + # FIXME: insert proper C++ library support + _LT_TAGVAR(ld_shlibs, $1)=no + ;; + esac + + AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) + test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no + + _LT_TAGVAR(GCC, $1)=$GXX + _LT_TAGVAR(LD, $1)=$LD + + ## CAVEAT EMPTOR: + ## There is no encapsulation within the following macros, do not change + ## the running order or otherwise move them around unless you know exactly + ## what you are doing... + _LT_SYS_HIDDEN_LIBDEPS($1) + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_SYS_DYNAMIC_LINKER($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + + _LT_CONFIG($1) + fi # test -n "$compiler" + + CC=$lt_save_CC + CFLAGS=$lt_save_CFLAGS + LDCXX=$LD + LD=$lt_save_LD + GCC=$lt_save_GCC + with_gnu_ld=$lt_save_with_gnu_ld + lt_cv_path_LDCXX=$lt_cv_path_LD + lt_cv_path_LD=$lt_save_path_LD + lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld + lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld +fi # test yes != "$_lt_caught_CXX_error" + +AC_LANG_POP +])# _LT_LANG_CXX_CONFIG + + +# _LT_FUNC_STRIPNAME_CNF +# ---------------------- +# func_stripname_cnf prefix suffix name +# strip PREFIX and SUFFIX off of NAME. +# PREFIX and SUFFIX must not contain globbing or regex special +# characters, hashes, percent signs, but SUFFIX may contain a leading +# dot (in which case that matches only a dot). +# +# This function is identical to the (non-XSI) version of func_stripname, +# except this one can be used by m4 code that may be executed by configure, +# rather than the libtool script. +m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl +AC_REQUIRE([_LT_DECL_SED]) +AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH]) +func_stripname_cnf () +{ + case @S|@2 in + .*) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%\\\\@S|@2\$%%"`;; + *) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%@S|@2\$%%"`;; + esac +} # func_stripname_cnf +])# _LT_FUNC_STRIPNAME_CNF + + +# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) +# --------------------------------- +# Figure out "hidden" library dependencies from verbose +# compiler output when linking a shared library. +# Parse the compiler output and extract the necessary +# objects, libraries and library flags. +m4_defun([_LT_SYS_HIDDEN_LIBDEPS], +[m4_require([_LT_FILEUTILS_DEFAULTS])dnl +AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl +# Dependencies to place before and after the object being linked: +_LT_TAGVAR(predep_objects, $1)= +_LT_TAGVAR(postdep_objects, $1)= +_LT_TAGVAR(predeps, $1)= +_LT_TAGVAR(postdeps, $1)= +_LT_TAGVAR(compiler_lib_search_path, $1)= + +dnl we can't use the lt_simple_compile_test_code here, +dnl because it contains code intended for an executable, +dnl not a library. It's possible we should let each +dnl tag define a new lt_????_link_test_code variable, +dnl but it's only used here... +m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF +int a; +void foo (void) { a = 0; } +_LT_EOF +], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF +class Foo +{ +public: + Foo (void) { a = 0; } +private: + int a; +}; +_LT_EOF +], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF + subroutine foo + implicit none + integer*4 a + a=0 + return + end +_LT_EOF +], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF + subroutine foo + implicit none + integer a + a=0 + return + end +_LT_EOF +], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF +public class foo { + private int a; + public void bar (void) { + a = 0; + } +}; +_LT_EOF +], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF +package foo +func foo() { +} +_LT_EOF +]) + +_lt_libdeps_save_CFLAGS=$CFLAGS +case "$CC $CFLAGS " in #( +*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; +*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; +*\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;; +esac + +dnl Parse the compiler output and extract the necessary +dnl objects, libraries and library flags. +if AC_TRY_EVAL(ac_compile); then + # Parse the compiler output and extract the necessary + # objects, libraries and library flags. + + # Sentinel used to keep track of whether or not we are before + # the conftest object file. + pre_test_object_deps_done=no + + for p in `eval "$output_verbose_link_cmd"`; do + case $prev$p in + + -L* | -R* | -l*) + # Some compilers place space between "-{L,R}" and the path. + # Remove the space. + if test x-L = "$p" || + test x-R = "$p"; then + prev=$p + continue + fi + + # Expand the sysroot to ease extracting the directories later. + if test -z "$prev"; then + case $p in + -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; + -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; + -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; + esac + fi + case $p in + =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; + esac + if test no = "$pre_test_object_deps_done"; then + case $prev in + -L | -R) + # Internal compiler library paths should come after those + # provided the user. The postdeps already come after the + # user supplied libs so there is no need to process them. + if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then + _LT_TAGVAR(compiler_lib_search_path, $1)=$prev$p + else + _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} $prev$p" + fi + ;; + # The "-l" case would never come before the object being + # linked, so don't bother handling this case. + esac + else + if test -z "$_LT_TAGVAR(postdeps, $1)"; then + _LT_TAGVAR(postdeps, $1)=$prev$p + else + _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} $prev$p" + fi + fi + prev= + ;; + + *.lto.$objext) ;; # Ignore GCC LTO objects + *.$objext) + # This assumes that the test object file only shows up + # once in the compiler output. + if test "$p" = "conftest.$objext"; then + pre_test_object_deps_done=yes + continue + fi + + if test no = "$pre_test_object_deps_done"; then + if test -z "$_LT_TAGVAR(predep_objects, $1)"; then + _LT_TAGVAR(predep_objects, $1)=$p + else + _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" + fi + else + if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then + _LT_TAGVAR(postdep_objects, $1)=$p + else + _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" + fi + fi + ;; + + *) ;; # Ignore the rest. + + esac + done + + # Clean up. + rm -f a.out a.exe +else + echo "libtool.m4: error: problem compiling $1 test program" +fi + +$RM -f confest.$objext +CFLAGS=$_lt_libdeps_save_CFLAGS + +# PORTME: override above test on systems where it is broken +m4_if([$1], [CXX], +[case $host_os in +interix[[3-9]]*) + # Interix 3.5 installs completely hosed .la files for C++, so rather than + # hack all around it, let's just trust "g++" to DTRT. + _LT_TAGVAR(predep_objects,$1)= + _LT_TAGVAR(postdep_objects,$1)= + _LT_TAGVAR(postdeps,$1)= + ;; +esac +]) + +case " $_LT_TAGVAR(postdeps, $1) " in +*" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; +esac + _LT_TAGVAR(compiler_lib_search_dirs, $1)= +if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then + _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | $SED -e 's! -L! !g' -e 's!^ !!'` +fi +_LT_TAGDECL([], [compiler_lib_search_dirs], [1], + [The directories searched by this compiler when creating a shared library]) +_LT_TAGDECL([], [predep_objects], [1], + [Dependencies to place before and after the objects being linked to + create a shared library]) +_LT_TAGDECL([], [postdep_objects], [1]) +_LT_TAGDECL([], [predeps], [1]) +_LT_TAGDECL([], [postdeps], [1]) +_LT_TAGDECL([], [compiler_lib_search_path], [1], + [The library search path used internally by the compiler when linking + a shared library]) +])# _LT_SYS_HIDDEN_LIBDEPS + + +# _LT_LANG_F77_CONFIG([TAG]) +# -------------------------- +# Ensure that the configuration variables for a Fortran 77 compiler are +# suitably defined. These variables are subsequently used by _LT_CONFIG +# to write the compiler configuration to 'libtool'. +m4_defun([_LT_LANG_F77_CONFIG], +[AC_LANG_PUSH(Fortran 77) +if test -z "$F77" || test no = "$F77"; then + _lt_disable_F77=yes +fi + +_LT_TAGVAR(archive_cmds_need_lc, $1)=no +_LT_TAGVAR(allow_undefined_flag, $1)= +_LT_TAGVAR(always_export_symbols, $1)=no +_LT_TAGVAR(archive_expsym_cmds, $1)= +_LT_TAGVAR(export_dynamic_flag_spec, $1)= +_LT_TAGVAR(hardcode_direct, $1)=no +_LT_TAGVAR(hardcode_direct_absolute, $1)=no +_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= +_LT_TAGVAR(hardcode_libdir_separator, $1)= +_LT_TAGVAR(hardcode_minus_L, $1)=no +_LT_TAGVAR(hardcode_automatic, $1)=no +_LT_TAGVAR(inherit_rpath, $1)=no +_LT_TAGVAR(module_cmds, $1)= +_LT_TAGVAR(module_expsym_cmds, $1)= +_LT_TAGVAR(link_all_deplibs, $1)=unknown +_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_TAGVAR(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds +_LT_TAGVAR(no_undefined_flag, $1)= +_LT_TAGVAR(whole_archive_flag_spec, $1)= +_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no + +# Source file extension for f77 test sources. +ac_ext=f + +# Object file extension for compiled f77 test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# No sense in running all these tests if we already determined that +# the F77 compiler isn't working. Some variables (like enable_shared) +# are currently assumed to apply to all compilers on this platform, +# and will be corrupted by setting them based on a non-working compiler. +if test yes != "$_lt_disable_F77"; then + # Code to be used in simple compile tests + lt_simple_compile_test_code="\ + subroutine t + return + end +" + + # Code to be used in simple link tests + lt_simple_link_test_code="\ + program t + end +" + + # ltmain only uses $CC for tagged configurations so make sure $CC is set. + _LT_TAG_COMPILER + + # save warnings/boilerplate of simple test code + _LT_COMPILER_BOILERPLATE + _LT_LINKER_BOILERPLATE + + # Allow CC to be a program name with arguments. + lt_save_CC=$CC + lt_save_GCC=$GCC + lt_save_CFLAGS=$CFLAGS + CC=${F77-"f77"} + CFLAGS=$FFLAGS + compiler=$CC + _LT_TAGVAR(compiler, $1)=$CC + _LT_CC_BASENAME([$compiler]) + GCC=$G77 + if test -n "$compiler"; then + AC_MSG_CHECKING([if libtool supports shared libraries]) + AC_MSG_RESULT([$can_build_shared]) + + AC_MSG_CHECKING([whether to build shared libraries]) + test no = "$can_build_shared" && enable_shared=no + + # On AIX, shared libraries and static libraries use the same namespace, and + # are all built from PIC. + case $host_os in + aix3*) + test yes = "$enable_shared" && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; + aix[[4-9]]*) + if test ia64 != "$host_cpu"; then + case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in + yes,aix,yes) ;; # shared object as lib.so file only + yes,svr4,*) ;; # shared object as lib.so archive member only + yes,*) enable_static=no ;; # shared object in lib.a archive as well + esac + fi + ;; + esac + AC_MSG_RESULT([$enable_shared]) + + AC_MSG_CHECKING([whether to build static libraries]) + # Make sure either enable_shared or enable_static is yes. + test yes = "$enable_shared" || enable_static=yes + AC_MSG_RESULT([$enable_static]) + + _LT_TAGVAR(GCC, $1)=$G77 + _LT_TAGVAR(LD, $1)=$LD + + ## CAVEAT EMPTOR: + ## There is no encapsulation within the following macros, do not change + ## the running order or otherwise move them around unless you know exactly + ## what you are doing... + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_SYS_DYNAMIC_LINKER($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + + _LT_CONFIG($1) + fi # test -n "$compiler" + + GCC=$lt_save_GCC + CC=$lt_save_CC + CFLAGS=$lt_save_CFLAGS +fi # test yes != "$_lt_disable_F77" + +AC_LANG_POP +])# _LT_LANG_F77_CONFIG + + +# _LT_LANG_FC_CONFIG([TAG]) +# ------------------------- +# Ensure that the configuration variables for a Fortran compiler are +# suitably defined. These variables are subsequently used by _LT_CONFIG +# to write the compiler configuration to 'libtool'. +m4_defun([_LT_LANG_FC_CONFIG], +[AC_LANG_PUSH(Fortran) + +if test -z "$FC" || test no = "$FC"; then + _lt_disable_FC=yes +fi + +_LT_TAGVAR(archive_cmds_need_lc, $1)=no +_LT_TAGVAR(allow_undefined_flag, $1)= +_LT_TAGVAR(always_export_symbols, $1)=no +_LT_TAGVAR(archive_expsym_cmds, $1)= +_LT_TAGVAR(export_dynamic_flag_spec, $1)= +_LT_TAGVAR(hardcode_direct, $1)=no +_LT_TAGVAR(hardcode_direct_absolute, $1)=no +_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= +_LT_TAGVAR(hardcode_libdir_separator, $1)= +_LT_TAGVAR(hardcode_minus_L, $1)=no +_LT_TAGVAR(hardcode_automatic, $1)=no +_LT_TAGVAR(inherit_rpath, $1)=no +_LT_TAGVAR(module_cmds, $1)= +_LT_TAGVAR(module_expsym_cmds, $1)= +_LT_TAGVAR(link_all_deplibs, $1)=unknown +_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_TAGVAR(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds +_LT_TAGVAR(no_undefined_flag, $1)= +_LT_TAGVAR(whole_archive_flag_spec, $1)= +_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no + +# Source file extension for fc test sources. +ac_ext=${ac_fc_srcext-f} + +# Object file extension for compiled fc test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# No sense in running all these tests if we already determined that +# the FC compiler isn't working. Some variables (like enable_shared) +# are currently assumed to apply to all compilers on this platform, +# and will be corrupted by setting them based on a non-working compiler. +if test yes != "$_lt_disable_FC"; then + # Code to be used in simple compile tests + lt_simple_compile_test_code="\ + subroutine t + return + end +" + + # Code to be used in simple link tests + lt_simple_link_test_code="\ + program t + end +" + + # ltmain only uses $CC for tagged configurations so make sure $CC is set. + _LT_TAG_COMPILER + + # save warnings/boilerplate of simple test code + _LT_COMPILER_BOILERPLATE + _LT_LINKER_BOILERPLATE + + # Allow CC to be a program name with arguments. + lt_save_CC=$CC + lt_save_GCC=$GCC + lt_save_CFLAGS=$CFLAGS + CC=${FC-"f95"} + CFLAGS=$FCFLAGS + compiler=$CC + GCC=$ac_cv_fc_compiler_gnu + + _LT_TAGVAR(compiler, $1)=$CC + _LT_CC_BASENAME([$compiler]) + + if test -n "$compiler"; then + AC_MSG_CHECKING([if libtool supports shared libraries]) + AC_MSG_RESULT([$can_build_shared]) + + AC_MSG_CHECKING([whether to build shared libraries]) + test no = "$can_build_shared" && enable_shared=no + + # On AIX, shared libraries and static libraries use the same namespace, and + # are all built from PIC. + case $host_os in + aix3*) + test yes = "$enable_shared" && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; + aix[[4-9]]*) + if test ia64 != "$host_cpu"; then + case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in + yes,aix,yes) ;; # shared object as lib.so file only + yes,svr4,*) ;; # shared object as lib.so archive member only + yes,*) enable_static=no ;; # shared object in lib.a archive as well + esac + fi + ;; + esac + AC_MSG_RESULT([$enable_shared]) + + AC_MSG_CHECKING([whether to build static libraries]) + # Make sure either enable_shared or enable_static is yes. + test yes = "$enable_shared" || enable_static=yes + AC_MSG_RESULT([$enable_static]) + + _LT_TAGVAR(GCC, $1)=$ac_cv_fc_compiler_gnu + _LT_TAGVAR(LD, $1)=$LD + + ## CAVEAT EMPTOR: + ## There is no encapsulation within the following macros, do not change + ## the running order or otherwise move them around unless you know exactly + ## what you are doing... + _LT_SYS_HIDDEN_LIBDEPS($1) + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_SYS_DYNAMIC_LINKER($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + + _LT_CONFIG($1) + fi # test -n "$compiler" + + GCC=$lt_save_GCC + CC=$lt_save_CC + CFLAGS=$lt_save_CFLAGS +fi # test yes != "$_lt_disable_FC" + +AC_LANG_POP +])# _LT_LANG_FC_CONFIG + + +# _LT_LANG_GCJ_CONFIG([TAG]) +# -------------------------- +# Ensure that the configuration variables for the GNU Java Compiler compiler +# are suitably defined. These variables are subsequently used by _LT_CONFIG +# to write the compiler configuration to 'libtool'. +m4_defun([_LT_LANG_GCJ_CONFIG], +[AC_REQUIRE([LT_PROG_GCJ])dnl +AC_LANG_SAVE + +# Source file extension for Java test sources. +ac_ext=java + +# Object file extension for compiled Java test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code="class foo {}" + +# Code to be used in simple link tests +lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' + +# ltmain only uses $CC for tagged configurations so make sure $CC is set. +_LT_TAG_COMPILER + +# save warnings/boilerplate of simple test code +_LT_COMPILER_BOILERPLATE +_LT_LINKER_BOILERPLATE + +# Allow CC to be a program name with arguments. +lt_save_CC=$CC +lt_save_CFLAGS=$CFLAGS +lt_save_GCC=$GCC +GCC=yes +CC=${GCJ-"gcj"} +CFLAGS=$GCJFLAGS +compiler=$CC +_LT_TAGVAR(compiler, $1)=$CC +_LT_TAGVAR(LD, $1)=$LD +_LT_CC_BASENAME([$compiler]) + +# GCJ did not exist at the time GCC didn't implicitly link libc in. +_LT_TAGVAR(archive_cmds_need_lc, $1)=no + +_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_TAGVAR(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds + +## CAVEAT EMPTOR: +## There is no encapsulation within the following macros, do not change +## the running order or otherwise move them around unless you know exactly +## what you are doing... +if test -n "$compiler"; then + _LT_COMPILER_NO_RTTI($1) + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + + _LT_CONFIG($1) +fi + +AC_LANG_RESTORE + +GCC=$lt_save_GCC +CC=$lt_save_CC +CFLAGS=$lt_save_CFLAGS +])# _LT_LANG_GCJ_CONFIG + + +# _LT_LANG_GO_CONFIG([TAG]) +# -------------------------- +# Ensure that the configuration variables for the GNU Go compiler +# are suitably defined. These variables are subsequently used by _LT_CONFIG +# to write the compiler configuration to 'libtool'. +m4_defun([_LT_LANG_GO_CONFIG], +[AC_REQUIRE([LT_PROG_GO])dnl +AC_LANG_SAVE + +# Source file extension for Go test sources. +ac_ext=go + +# Object file extension for compiled Go test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code="package main; func main() { }" + +# Code to be used in simple link tests +lt_simple_link_test_code='package main; func main() { }' + +# ltmain only uses $CC for tagged configurations so make sure $CC is set. +_LT_TAG_COMPILER + +# save warnings/boilerplate of simple test code +_LT_COMPILER_BOILERPLATE +_LT_LINKER_BOILERPLATE + +# Allow CC to be a program name with arguments. +lt_save_CC=$CC +lt_save_CFLAGS=$CFLAGS +lt_save_GCC=$GCC +GCC=yes +CC=${GOC-"gccgo"} +CFLAGS=$GOFLAGS +compiler=$CC +_LT_TAGVAR(compiler, $1)=$CC +_LT_TAGVAR(LD, $1)=$LD +_LT_CC_BASENAME([$compiler]) + +# Go did not exist at the time GCC didn't implicitly link libc in. +_LT_TAGVAR(archive_cmds_need_lc, $1)=no + +_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_TAGVAR(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds + +## CAVEAT EMPTOR: +## There is no encapsulation within the following macros, do not change +## the running order or otherwise move them around unless you know exactly +## what you are doing... +if test -n "$compiler"; then + _LT_COMPILER_NO_RTTI($1) + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + + _LT_CONFIG($1) +fi + +AC_LANG_RESTORE + +GCC=$lt_save_GCC +CC=$lt_save_CC +CFLAGS=$lt_save_CFLAGS +])# _LT_LANG_GO_CONFIG + + +# _LT_LANG_RC_CONFIG([TAG]) +# ------------------------- +# Ensure that the configuration variables for the Windows resource compiler +# are suitably defined. These variables are subsequently used by _LT_CONFIG +# to write the compiler configuration to 'libtool'. +m4_defun([_LT_LANG_RC_CONFIG], +[AC_REQUIRE([LT_PROG_RC])dnl +AC_LANG_SAVE + +# Source file extension for RC test sources. +ac_ext=rc + +# Object file extension for compiled RC test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' + +# Code to be used in simple link tests +lt_simple_link_test_code=$lt_simple_compile_test_code + +# ltmain only uses $CC for tagged configurations so make sure $CC is set. +_LT_TAG_COMPILER + +# save warnings/boilerplate of simple test code +_LT_COMPILER_BOILERPLATE +_LT_LINKER_BOILERPLATE + +# Allow CC to be a program name with arguments. +lt_save_CC=$CC +lt_save_CFLAGS=$CFLAGS +lt_save_GCC=$GCC +GCC= +CC=${RC-"windres"} +CFLAGS= +compiler=$CC +_LT_TAGVAR(compiler, $1)=$CC +_LT_CC_BASENAME([$compiler]) +_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes + +if test -n "$compiler"; then + : + _LT_CONFIG($1) +fi + +GCC=$lt_save_GCC +AC_LANG_RESTORE +CC=$lt_save_CC +CFLAGS=$lt_save_CFLAGS +])# _LT_LANG_RC_CONFIG + + +# LT_PROG_GCJ +# ----------- +AC_DEFUN([LT_PROG_GCJ], +[m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], + [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], + [AC_CHECK_TOOL(GCJ, gcj,) + test set = "${GCJFLAGS+set}" || GCJFLAGS="-g -O2" + AC_SUBST(GCJFLAGS)])])[]dnl +]) + +# Old name: +AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([LT_AC_PROG_GCJ], []) + + +# LT_PROG_GO +# ---------- +AC_DEFUN([LT_PROG_GO], +[AC_CHECK_TOOL(GOC, gccgo,) +]) + + +# LT_PROG_RC +# ---------- +AC_DEFUN([LT_PROG_RC], +[AC_CHECK_TOOL(RC, windres,) +]) + +# Old name: +AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([LT_AC_PROG_RC], []) + + +# _LT_DECL_EGREP +# -------------- +# If we don't have a new enough Autoconf to choose the best grep +# available, choose the one first in the user's PATH. +m4_defun([_LT_DECL_EGREP], +[AC_REQUIRE([AC_PROG_EGREP])dnl +AC_REQUIRE([AC_PROG_FGREP])dnl +test -z "$GREP" && GREP=grep +_LT_DECL([], [GREP], [1], [A grep program that handles long lines]) +_LT_DECL([], [EGREP], [1], [An ERE matcher]) +_LT_DECL([], [FGREP], [1], [A literal string matcher]) +dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too +AC_SUBST([GREP]) +]) + + +# _LT_DECL_OBJDUMP +# -------------- +# If we don't have a new enough Autoconf to choose the best objdump +# available, choose the one first in the user's PATH. +m4_defun([_LT_DECL_OBJDUMP], +[AC_CHECK_TOOL(OBJDUMP, objdump, false) +test -z "$OBJDUMP" && OBJDUMP=objdump +_LT_DECL([], [OBJDUMP], [1], [An object symbol dumper]) +AC_SUBST([OBJDUMP]) +]) + +# _LT_DECL_DLLTOOL +# ---------------- +# Ensure DLLTOOL variable is set. +m4_defun([_LT_DECL_DLLTOOL], +[AC_CHECK_TOOL(DLLTOOL, dlltool, false) +test -z "$DLLTOOL" && DLLTOOL=dlltool +_LT_DECL([], [DLLTOOL], [1], [DLL creation program]) +AC_SUBST([DLLTOOL]) +]) + +# _LT_DECL_SED +# ------------ +# Check for a fully-functional sed program, that truncates +# as few characters as possible. Prefer GNU sed if found. +m4_defun([_LT_DECL_SED], +[AC_PROG_SED +test -z "$SED" && SED=sed +Xsed="$SED -e 1s/^X//" +_LT_DECL([], [SED], [1], [A sed program that does not truncate output]) +_LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"], + [Sed that helps us avoid accidentally triggering echo(1) options like -n]) +])# _LT_DECL_SED + +m4_ifndef([AC_PROG_SED], [ +############################################################ +# NOTE: This macro has been submitted for inclusion into # +# GNU Autoconf as AC_PROG_SED. When it is available in # +# a released version of Autoconf we should remove this # +# macro and use it instead. # +############################################################ + +m4_defun([AC_PROG_SED], +[AC_MSG_CHECKING([for a sed that does not truncate output]) +AC_CACHE_VAL(lt_cv_path_SED, +[# Loop through the user's path and test for sed and gsed. +# Then use that list of sed's as ones to test for truncation. +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for lt_ac_prog in sed gsed; do + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then + lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" + fi + done + done +done +IFS=$as_save_IFS +lt_ac_max=0 +lt_ac_count=0 +# Add /usr/xpg4/bin/sed as it is typically found on Solaris +# along with /bin/sed that truncates output. +for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do + test ! -f "$lt_ac_sed" && continue + cat /dev/null > conftest.in + lt_ac_count=0 + echo $ECHO_N "0123456789$ECHO_C" >conftest.in + # Check for GNU sed and select it if it is found. + if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then + lt_cv_path_SED=$lt_ac_sed + break + fi + while true; do + cat conftest.in conftest.in >conftest.tmp + mv conftest.tmp conftest.in + cp conftest.in conftest.nl + echo >>conftest.nl + $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break + cmp -s conftest.out conftest.nl || break + # 10000 chars as input seems more than enough + test 10 -lt "$lt_ac_count" && break + lt_ac_count=`expr $lt_ac_count + 1` + if test "$lt_ac_count" -gt "$lt_ac_max"; then + lt_ac_max=$lt_ac_count + lt_cv_path_SED=$lt_ac_sed + fi + done +done +]) +SED=$lt_cv_path_SED +AC_SUBST([SED]) +AC_MSG_RESULT([$SED]) +])#AC_PROG_SED +])#m4_ifndef + +# Old name: +AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([LT_AC_PROG_SED], []) + + +# _LT_CHECK_SHELL_FEATURES +# ------------------------ +# Find out whether the shell is Bourne or XSI compatible, +# or has some other useful features. +m4_defun([_LT_CHECK_SHELL_FEATURES], +[if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then + lt_unset=unset +else + lt_unset=false +fi +_LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl + +# test EBCDIC or ASCII +case `echo X|tr X '\101'` in + A) # ASCII based system + # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr + lt_SP2NL='tr \040 \012' + lt_NL2SP='tr \015\012 \040\040' + ;; + *) # EBCDIC based system + lt_SP2NL='tr \100 \n' + lt_NL2SP='tr \r\n \100\100' + ;; +esac +_LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl +_LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl +])# _LT_CHECK_SHELL_FEATURES + + +# _LT_PATH_CONVERSION_FUNCTIONS +# ----------------------------- +# Determine what file name conversion functions should be used by +# func_to_host_file (and, implicitly, by func_to_host_path). These are needed +# for certain cross-compile configurations and native mingw. +m4_defun([_LT_PATH_CONVERSION_FUNCTIONS], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +AC_REQUIRE([AC_CANONICAL_BUILD])dnl +AC_MSG_CHECKING([how to convert $build file names to $host format]) +AC_CACHE_VAL(lt_cv_to_host_file_cmd, +[case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 + ;; + esac + ;; + *-*-cygwin* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin + ;; + esac + ;; + * ) # unhandled hosts (and "normal" native builds) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; +esac +]) +to_host_file_cmd=$lt_cv_to_host_file_cmd +AC_MSG_RESULT([$lt_cv_to_host_file_cmd]) +_LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd], + [0], [convert $build file names to $host format])dnl + +AC_MSG_CHECKING([how to convert $build file names to toolchain format]) +AC_CACHE_VAL(lt_cv_to_tool_file_cmd, +[#assume ordinary cross tools, or native build. +lt_cv_to_tool_file_cmd=func_convert_file_noop +case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 + ;; + esac + ;; +esac +]) +to_tool_file_cmd=$lt_cv_to_tool_file_cmd +AC_MSG_RESULT([$lt_cv_to_tool_file_cmd]) +_LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd], + [0], [convert $build files to toolchain format])dnl +])# _LT_PATH_CONVERSION_FUNCTIONS diff --git a/libs/ode-0.16.1/m4/ltoptions.m4 b/libs/ode-0.16.1/m4/ltoptions.m4 new file mode 100644 index 0000000..94b0829 --- /dev/null +++ b/libs/ode-0.16.1/m4/ltoptions.m4 @@ -0,0 +1,437 @@ +# Helper functions for option handling. -*- Autoconf -*- +# +# Copyright (C) 2004-2005, 2007-2009, 2011-2015 Free Software +# Foundation, Inc. +# Written by Gary V. Vaughan, 2004 +# +# This file is free software; the Free Software Foundation gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. + +# serial 8 ltoptions.m4 + +# This is to help aclocal find these macros, as it can't see m4_define. +AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) + + +# _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME) +# ------------------------------------------ +m4_define([_LT_MANGLE_OPTION], +[[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])]) + + +# _LT_SET_OPTION(MACRO-NAME, OPTION-NAME) +# --------------------------------------- +# Set option OPTION-NAME for macro MACRO-NAME, and if there is a +# matching handler defined, dispatch to it. Other OPTION-NAMEs are +# saved as a flag. +m4_define([_LT_SET_OPTION], +[m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl +m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), + _LT_MANGLE_DEFUN([$1], [$2]), + [m4_warning([Unknown $1 option '$2'])])[]dnl +]) + + +# _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET]) +# ------------------------------------------------------------ +# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. +m4_define([_LT_IF_OPTION], +[m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])]) + + +# _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET) +# ------------------------------------------------------- +# Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME +# are set. +m4_define([_LT_UNLESS_OPTIONS], +[m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), + [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option), + [m4_define([$0_found])])])[]dnl +m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3 +])[]dnl +]) + + +# _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST) +# ---------------------------------------- +# OPTION-LIST is a space-separated list of Libtool options associated +# with MACRO-NAME. If any OPTION has a matching handler declared with +# LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about +# the unknown option and exit. +m4_defun([_LT_SET_OPTIONS], +[# Set options +m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), + [_LT_SET_OPTION([$1], _LT_Option)]) + +m4_if([$1],[LT_INIT],[ + dnl + dnl Simply set some default values (i.e off) if boolean options were not + dnl specified: + _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no + ]) + _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no + ]) + dnl + dnl If no reference was made to various pairs of opposing options, then + dnl we run the default mode handler for the pair. For example, if neither + dnl 'shared' nor 'disable-shared' was passed, we enable building of shared + dnl archives by default: + _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) + _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) + _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) + _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], + [_LT_ENABLE_FAST_INSTALL]) + _LT_UNLESS_OPTIONS([LT_INIT], [aix-soname=aix aix-soname=both aix-soname=svr4], + [_LT_WITH_AIX_SONAME([aix])]) + ]) +])# _LT_SET_OPTIONS + + +## --------------------------------- ## +## Macros to handle LT_INIT options. ## +## --------------------------------- ## + +# _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME) +# ----------------------------------------- +m4_define([_LT_MANGLE_DEFUN], +[[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])]) + + +# LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE) +# ----------------------------------------------- +m4_define([LT_OPTION_DEFINE], +[m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl +])# LT_OPTION_DEFINE + + +# dlopen +# ------ +LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes +]) + +AU_DEFUN([AC_LIBTOOL_DLOPEN], +[_LT_SET_OPTION([LT_INIT], [dlopen]) +AC_DIAGNOSE([obsolete], +[$0: Remove this warning and the call to _LT_SET_OPTION when you +put the 'dlopen' option into LT_INIT's first parameter.]) +]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], []) + + +# win32-dll +# --------- +# Declare package support for building win32 dll's. +LT_OPTION_DEFINE([LT_INIT], [win32-dll], +[enable_win32_dll=yes + +case $host in +*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) + AC_CHECK_TOOL(AS, as, false) + AC_CHECK_TOOL(DLLTOOL, dlltool, false) + AC_CHECK_TOOL(OBJDUMP, objdump, false) + ;; +esac + +test -z "$AS" && AS=as +_LT_DECL([], [AS], [1], [Assembler program])dnl + +test -z "$DLLTOOL" && DLLTOOL=dlltool +_LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl + +test -z "$OBJDUMP" && OBJDUMP=objdump +_LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl +])# win32-dll + +AU_DEFUN([AC_LIBTOOL_WIN32_DLL], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +_LT_SET_OPTION([LT_INIT], [win32-dll]) +AC_DIAGNOSE([obsolete], +[$0: Remove this warning and the call to _LT_SET_OPTION when you +put the 'win32-dll' option into LT_INIT's first parameter.]) +]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) + + +# _LT_ENABLE_SHARED([DEFAULT]) +# ---------------------------- +# implement the --enable-shared flag, and supports the 'shared' and +# 'disable-shared' LT_INIT options. +# DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. +m4_define([_LT_ENABLE_SHARED], +[m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl +AC_ARG_ENABLE([shared], + [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@], + [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])], + [p=${PACKAGE-default} + case $enableval in + yes) enable_shared=yes ;; + no) enable_shared=no ;; + *) + enable_shared=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, + for pkg in $enableval; do + IFS=$lt_save_ifs + if test "X$pkg" = "X$p"; then + enable_shared=yes + fi + done + IFS=$lt_save_ifs + ;; + esac], + [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) + + _LT_DECL([build_libtool_libs], [enable_shared], [0], + [Whether or not to build shared libraries]) +])# _LT_ENABLE_SHARED + +LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])]) +LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])]) + +# Old names: +AC_DEFUN([AC_ENABLE_SHARED], +[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared]) +]) + +AC_DEFUN([AC_DISABLE_SHARED], +[_LT_SET_OPTION([LT_INIT], [disable-shared]) +]) + +AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) +AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AM_ENABLE_SHARED], []) +dnl AC_DEFUN([AM_DISABLE_SHARED], []) + + + +# _LT_ENABLE_STATIC([DEFAULT]) +# ---------------------------- +# implement the --enable-static flag, and support the 'static' and +# 'disable-static' LT_INIT options. +# DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. +m4_define([_LT_ENABLE_STATIC], +[m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl +AC_ARG_ENABLE([static], + [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@], + [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])], + [p=${PACKAGE-default} + case $enableval in + yes) enable_static=yes ;; + no) enable_static=no ;; + *) + enable_static=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, + for pkg in $enableval; do + IFS=$lt_save_ifs + if test "X$pkg" = "X$p"; then + enable_static=yes + fi + done + IFS=$lt_save_ifs + ;; + esac], + [enable_static=]_LT_ENABLE_STATIC_DEFAULT) + + _LT_DECL([build_old_libs], [enable_static], [0], + [Whether or not to build static libraries]) +])# _LT_ENABLE_STATIC + +LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])]) +LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])]) + +# Old names: +AC_DEFUN([AC_ENABLE_STATIC], +[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static]) +]) + +AC_DEFUN([AC_DISABLE_STATIC], +[_LT_SET_OPTION([LT_INIT], [disable-static]) +]) + +AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) +AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AM_ENABLE_STATIC], []) +dnl AC_DEFUN([AM_DISABLE_STATIC], []) + + + +# _LT_ENABLE_FAST_INSTALL([DEFAULT]) +# ---------------------------------- +# implement the --enable-fast-install flag, and support the 'fast-install' +# and 'disable-fast-install' LT_INIT options. +# DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. +m4_define([_LT_ENABLE_FAST_INSTALL], +[m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl +AC_ARG_ENABLE([fast-install], + [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], + [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], + [p=${PACKAGE-default} + case $enableval in + yes) enable_fast_install=yes ;; + no) enable_fast_install=no ;; + *) + enable_fast_install=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, + for pkg in $enableval; do + IFS=$lt_save_ifs + if test "X$pkg" = "X$p"; then + enable_fast_install=yes + fi + done + IFS=$lt_save_ifs + ;; + esac], + [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) + +_LT_DECL([fast_install], [enable_fast_install], [0], + [Whether or not to optimize for fast installation])dnl +])# _LT_ENABLE_FAST_INSTALL + +LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])]) +LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])]) + +# Old names: +AU_DEFUN([AC_ENABLE_FAST_INSTALL], +[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) +AC_DIAGNOSE([obsolete], +[$0: Remove this warning and the call to _LT_SET_OPTION when you put +the 'fast-install' option into LT_INIT's first parameter.]) +]) + +AU_DEFUN([AC_DISABLE_FAST_INSTALL], +[_LT_SET_OPTION([LT_INIT], [disable-fast-install]) +AC_DIAGNOSE([obsolete], +[$0: Remove this warning and the call to _LT_SET_OPTION when you put +the 'disable-fast-install' option into LT_INIT's first parameter.]) +]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) +dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) + + +# _LT_WITH_AIX_SONAME([DEFAULT]) +# ---------------------------------- +# implement the --with-aix-soname flag, and support the `aix-soname=aix' +# and `aix-soname=both' and `aix-soname=svr4' LT_INIT options. DEFAULT +# is either `aix', `both' or `svr4'. If omitted, it defaults to `aix'. +m4_define([_LT_WITH_AIX_SONAME], +[m4_define([_LT_WITH_AIX_SONAME_DEFAULT], [m4_if($1, svr4, svr4, m4_if($1, both, both, aix))])dnl +shared_archive_member_spec= +case $host,$enable_shared in +power*-*-aix[[5-9]]*,yes) + AC_MSG_CHECKING([which variant of shared library versioning to provide]) + AC_ARG_WITH([aix-soname], + [AS_HELP_STRING([--with-aix-soname=aix|svr4|both], + [shared library versioning (aka "SONAME") variant to provide on AIX, @<:@default=]_LT_WITH_AIX_SONAME_DEFAULT[@:>@.])], + [case $withval in + aix|svr4|both) + ;; + *) + AC_MSG_ERROR([Unknown argument to --with-aix-soname]) + ;; + esac + lt_cv_with_aix_soname=$with_aix_soname], + [AC_CACHE_VAL([lt_cv_with_aix_soname], + [lt_cv_with_aix_soname=]_LT_WITH_AIX_SONAME_DEFAULT) + with_aix_soname=$lt_cv_with_aix_soname]) + AC_MSG_RESULT([$with_aix_soname]) + if test aix != "$with_aix_soname"; then + # For the AIX way of multilib, we name the shared archive member + # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o', + # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File. + # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag, + # the AIX toolchain works better with OBJECT_MODE set (default 32). + if test 64 = "${OBJECT_MODE-32}"; then + shared_archive_member_spec=shr_64 + else + shared_archive_member_spec=shr + fi + fi + ;; +*) + with_aix_soname=aix + ;; +esac + +_LT_DECL([], [shared_archive_member_spec], [0], + [Shared archive member basename, for filename based shared library versioning on AIX])dnl +])# _LT_WITH_AIX_SONAME + +LT_OPTION_DEFINE([LT_INIT], [aix-soname=aix], [_LT_WITH_AIX_SONAME([aix])]) +LT_OPTION_DEFINE([LT_INIT], [aix-soname=both], [_LT_WITH_AIX_SONAME([both])]) +LT_OPTION_DEFINE([LT_INIT], [aix-soname=svr4], [_LT_WITH_AIX_SONAME([svr4])]) + + +# _LT_WITH_PIC([MODE]) +# -------------------- +# implement the --with-pic flag, and support the 'pic-only' and 'no-pic' +# LT_INIT options. +# MODE is either 'yes' or 'no'. If omitted, it defaults to 'both'. +m4_define([_LT_WITH_PIC], +[AC_ARG_WITH([pic], + [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@], + [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], + [lt_p=${PACKAGE-default} + case $withval in + yes|no) pic_mode=$withval ;; + *) + pic_mode=default + # Look at the argument we got. We use all the common list separators. + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, + for lt_pkg in $withval; do + IFS=$lt_save_ifs + if test "X$lt_pkg" = "X$lt_p"; then + pic_mode=yes + fi + done + IFS=$lt_save_ifs + ;; + esac], + [pic_mode=m4_default([$1], [default])]) + +_LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl +])# _LT_WITH_PIC + +LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])]) +LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])]) + +# Old name: +AU_DEFUN([AC_LIBTOOL_PICMODE], +[_LT_SET_OPTION([LT_INIT], [pic-only]) +AC_DIAGNOSE([obsolete], +[$0: Remove this warning and the call to _LT_SET_OPTION when you +put the 'pic-only' option into LT_INIT's first parameter.]) +]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBTOOL_PICMODE], []) + +## ----------------- ## +## LTDL_INIT Options ## +## ----------------- ## + +m4_define([_LTDL_MODE], []) +LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive], + [m4_define([_LTDL_MODE], [nonrecursive])]) +LT_OPTION_DEFINE([LTDL_INIT], [recursive], + [m4_define([_LTDL_MODE], [recursive])]) +LT_OPTION_DEFINE([LTDL_INIT], [subproject], + [m4_define([_LTDL_MODE], [subproject])]) + +m4_define([_LTDL_TYPE], []) +LT_OPTION_DEFINE([LTDL_INIT], [installable], + [m4_define([_LTDL_TYPE], [installable])]) +LT_OPTION_DEFINE([LTDL_INIT], [convenience], + [m4_define([_LTDL_TYPE], [convenience])]) diff --git a/libs/ode-0.16.1/m4/ltsugar.m4 b/libs/ode-0.16.1/m4/ltsugar.m4 new file mode 100644 index 0000000..48bc934 --- /dev/null +++ b/libs/ode-0.16.1/m4/ltsugar.m4 @@ -0,0 +1,124 @@ +# ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*- +# +# Copyright (C) 2004-2005, 2007-2008, 2011-2015 Free Software +# Foundation, Inc. +# Written by Gary V. Vaughan, 2004 +# +# This file is free software; the Free Software Foundation gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. + +# serial 6 ltsugar.m4 + +# This is to help aclocal find these macros, as it can't see m4_define. +AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])]) + + +# lt_join(SEP, ARG1, [ARG2...]) +# ----------------------------- +# Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their +# associated separator. +# Needed until we can rely on m4_join from Autoconf 2.62, since all earlier +# versions in m4sugar had bugs. +m4_define([lt_join], +[m4_if([$#], [1], [], + [$#], [2], [[$2]], + [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])]) +m4_define([_lt_join], +[m4_if([$#$2], [2], [], + [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])]) + + +# lt_car(LIST) +# lt_cdr(LIST) +# ------------ +# Manipulate m4 lists. +# These macros are necessary as long as will still need to support +# Autoconf-2.59, which quotes differently. +m4_define([lt_car], [[$1]]) +m4_define([lt_cdr], +[m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])], + [$#], 1, [], + [m4_dquote(m4_shift($@))])]) +m4_define([lt_unquote], $1) + + +# lt_append(MACRO-NAME, STRING, [SEPARATOR]) +# ------------------------------------------ +# Redefine MACRO-NAME to hold its former content plus 'SEPARATOR''STRING'. +# Note that neither SEPARATOR nor STRING are expanded; they are appended +# to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked). +# No SEPARATOR is output if MACRO-NAME was previously undefined (different +# than defined and empty). +# +# This macro is needed until we can rely on Autoconf 2.62, since earlier +# versions of m4sugar mistakenly expanded SEPARATOR but not STRING. +m4_define([lt_append], +[m4_define([$1], + m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])]) + + + +# lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...]) +# ---------------------------------------------------------- +# Produce a SEP delimited list of all paired combinations of elements of +# PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list +# has the form PREFIXmINFIXSUFFIXn. +# Needed until we can rely on m4_combine added in Autoconf 2.62. +m4_define([lt_combine], +[m4_if(m4_eval([$# > 3]), [1], + [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl +[[m4_foreach([_Lt_prefix], [$2], + [m4_foreach([_Lt_suffix], + ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[, + [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])]) + + +# lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ]) +# ----------------------------------------------------------------------- +# Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited +# by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ. +m4_define([lt_if_append_uniq], +[m4_ifdef([$1], + [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1], + [lt_append([$1], [$2], [$3])$4], + [$5])], + [lt_append([$1], [$2], [$3])$4])]) + + +# lt_dict_add(DICT, KEY, VALUE) +# ----------------------------- +m4_define([lt_dict_add], +[m4_define([$1($2)], [$3])]) + + +# lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE) +# -------------------------------------------- +m4_define([lt_dict_add_subkey], +[m4_define([$1($2:$3)], [$4])]) + + +# lt_dict_fetch(DICT, KEY, [SUBKEY]) +# ---------------------------------- +m4_define([lt_dict_fetch], +[m4_ifval([$3], + m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]), + m4_ifdef([$1($2)], [m4_defn([$1($2)])]))]) + + +# lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE]) +# ----------------------------------------------------------------- +m4_define([lt_if_dict_fetch], +[m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4], + [$5], + [$6])]) + + +# lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...]) +# -------------------------------------------------------------- +m4_define([lt_dict_filter], +[m4_if([$5], [], [], + [lt_join(m4_quote(m4_default([$4], [[, ]])), + lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]), + [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl +]) diff --git a/libs/ode-0.16.1/m4/ltversion.m4 b/libs/ode-0.16.1/m4/ltversion.m4 new file mode 100644 index 0000000..fa04b52 --- /dev/null +++ b/libs/ode-0.16.1/m4/ltversion.m4 @@ -0,0 +1,23 @@ +# ltversion.m4 -- version numbers -*- Autoconf -*- +# +# Copyright (C) 2004, 2011-2015 Free Software Foundation, Inc. +# Written by Scott James Remnant, 2004 +# +# This file is free software; the Free Software Foundation gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. + +# @configure_input@ + +# serial 4179 ltversion.m4 +# This file is part of GNU Libtool + +m4_define([LT_PACKAGE_VERSION], [2.4.6]) +m4_define([LT_PACKAGE_REVISION], [2.4.6]) + +AC_DEFUN([LTVERSION_VERSION], +[macro_version='2.4.6' +macro_revision='2.4.6' +_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) +_LT_DECL(, macro_revision, 0) +]) diff --git a/libs/ode-0.16.1/m4/lt~obsolete.m4 b/libs/ode-0.16.1/m4/lt~obsolete.m4 new file mode 100644 index 0000000..c6b26f8 --- /dev/null +++ b/libs/ode-0.16.1/m4/lt~obsolete.m4 @@ -0,0 +1,99 @@ +# lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*- +# +# Copyright (C) 2004-2005, 2007, 2009, 2011-2015 Free Software +# Foundation, Inc. +# Written by Scott James Remnant, 2004. +# +# This file is free software; the Free Software Foundation gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. + +# serial 5 lt~obsolete.m4 + +# These exist entirely to fool aclocal when bootstrapping libtool. +# +# In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN), +# which have later been changed to m4_define as they aren't part of the +# exported API, or moved to Autoconf or Automake where they belong. +# +# The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN +# in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us +# using a macro with the same name in our local m4/libtool.m4 it'll +# pull the old libtool.m4 in (it doesn't see our shiny new m4_define +# and doesn't know about Autoconf macros at all.) +# +# So we provide this file, which has a silly filename so it's always +# included after everything else. This provides aclocal with the +# AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything +# because those macros already exist, or will be overwritten later. +# We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. +# +# Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here. +# Yes, that means every name once taken will need to remain here until +# we give up compatibility with versions before 1.7, at which point +# we need to keep only those names which we still refer to. + +# This is to help aclocal find these macros, as it can't see m4_define. +AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])]) + +m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])]) +m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])]) +m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])]) +m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])]) +m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])]) +m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])]) +m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])]) +m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])]) +m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])]) +m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])]) +m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])]) +m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])]) +m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])]) +m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])]) +m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])]) +m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])]) +m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])]) +m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])]) +m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])]) +m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])]) +m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])]) +m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])]) +m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])]) +m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])]) +m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])]) +m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])]) +m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])]) +m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])]) +m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])]) +m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])]) +m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])]) +m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])]) +m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])]) +m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])]) +m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])]) +m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])]) +m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])]) +m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])]) +m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])]) +m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])]) +m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])]) +m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])]) +m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])]) +m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])]) +m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])]) +m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])]) +m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])]) +m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])]) +m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])]) +m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])]) +m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])]) +m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])]) +m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])]) +m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])]) +m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])]) +m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])]) +m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])]) +m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])]) +m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])]) +m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])]) +m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])]) diff --git a/libs/ode-0.16.1/m4/pkg.m4 b/libs/ode-0.16.1/m4/pkg.m4 new file mode 100644 index 0000000..73973f7 --- /dev/null +++ b/libs/ode-0.16.1/m4/pkg.m4 @@ -0,0 +1,157 @@ +# pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- +# serial 1 (pkg-config-0.24) +# +# Copyright © 2004 Scott James Remnant . +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +# +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. + +# PKG_PROG_PKG_CONFIG([MIN-VERSION]) +# ---------------------------------- +AC_DEFUN([PKG_PROG_PKG_CONFIG], +[m4_pattern_forbid([^_?PKG_[A-Z_]+$]) +m4_pattern_allow([^PKG_CONFIG(_PATH)?$]) +AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility]) +AC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path]) +AC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path]) + +if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then + AC_PATH_TOOL([PKG_CONFIG], [pkg-config]) +fi +if test -n "$PKG_CONFIG"; then + _pkg_min_version=m4_default([$1], [0.9.0]) + AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version]) + if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + PKG_CONFIG="" + fi +fi[]dnl +])# PKG_PROG_PKG_CONFIG + +# PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) +# +# Check to see whether a particular set of modules exists. Similar +# to PKG_CHECK_MODULES(), but does not set variables or print errors. +# +# Please remember that m4 expands AC_REQUIRE([PKG_PROG_PKG_CONFIG]) +# only at the first occurence in configure.ac, so if the first place +# it's called might be skipped (such as if it is within an "if", you +# have to call PKG_CHECK_EXISTS manually +# -------------------------------------------------------------- +AC_DEFUN([PKG_CHECK_EXISTS], +[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl +if test -n "$PKG_CONFIG" && \ + AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then + m4_default([$2], [:]) +m4_ifvaln([$3], [else + $3])dnl +fi]) + +# _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) +# --------------------------------------------- +m4_define([_PKG_CONFIG], +[if test -n "$$1"; then + pkg_cv_[]$1="$$1" + elif test -n "$PKG_CONFIG"; then + PKG_CHECK_EXISTS([$3], + [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`], + [pkg_failed=yes]) + else + pkg_failed=untried +fi[]dnl +])# _PKG_CONFIG + +# _PKG_SHORT_ERRORS_SUPPORTED +# ----------------------------- +AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED], +[AC_REQUIRE([PKG_PROG_PKG_CONFIG]) +if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then + _pkg_short_errors_supported=yes +else + _pkg_short_errors_supported=no +fi[]dnl +])# _PKG_SHORT_ERRORS_SUPPORTED + + +# PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], +# [ACTION-IF-NOT-FOUND]) +# +# +# Note that if there is a possibility the first call to +# PKG_CHECK_MODULES might not happen, you should be sure to include an +# explicit call to PKG_PROG_PKG_CONFIG in your configure.ac +# +# +# -------------------------------------------------------------- +AC_DEFUN([PKG_CHECK_MODULES], +[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl +AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl +AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl + +pkg_failed=no +AC_MSG_CHECKING([for $1]) + +_PKG_CONFIG([$1][_CFLAGS], [cflags], [$2]) +_PKG_CONFIG([$1][_LIBS], [libs], [$2]) + +m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS +and $1[]_LIBS to avoid the need to call pkg-config. +See the pkg-config man page for more details.]) + +if test $pkg_failed = yes; then + AC_MSG_RESULT([no]) + _PKG_SHORT_ERRORS_SUPPORTED + if test $_pkg_short_errors_supported = yes; then + $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "$2" 2>&1` + else + $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors "$2" 2>&1` + fi + # Put the nasty error message in config.log where it belongs + echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD + + m4_default([$4], [AC_MSG_ERROR( +[Package requirements ($2) were not met: + +$$1_PKG_ERRORS + +Consider adjusting the PKG_CONFIG_PATH environment variable if you +installed software in a non-standard prefix. + +_PKG_TEXT]) + ]) +elif test $pkg_failed = untried; then + AC_MSG_RESULT([no]) + m4_default([$4], [AC_MSG_FAILURE( +[The pkg-config script could not be found or is too old. Make sure it +is in your PATH or set the PKG_CONFIG environment variable to the full +path to pkg-config. + +_PKG_TEXT + +To get pkg-config, see .]) + ]) +else + $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS + $1[]_LIBS=$pkg_cv_[]$1[]_LIBS + AC_MSG_RESULT([yes]) + $3 +fi[]dnl +])# PKG_CHECK_MODULES diff --git a/libs/ode-0.16.1/missing b/libs/ode-0.16.1/missing new file mode 100755 index 0000000..f62bbae --- /dev/null +++ b/libs/ode-0.16.1/missing @@ -0,0 +1,215 @@ +#! /bin/sh +# Common wrapper for a few potentially missing GNU programs. + +scriptversion=2013-10-28.13; # UTC + +# Copyright (C) 1996-2014 Free Software Foundation, Inc. +# Originally written by Fran,cois Pinard , 1996. + +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. + +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. + +if test $# -eq 0; then + echo 1>&2 "Try '$0 --help' for more information" + exit 1 +fi + +case $1 in + + --is-lightweight) + # Used by our autoconf macros to check whether the available missing + # script is modern enough. + exit 0 + ;; + + --run) + # Back-compat with the calling convention used by older automake. + shift + ;; + + -h|--h|--he|--hel|--help) + echo "\ +$0 [OPTION]... PROGRAM [ARGUMENT]... + +Run 'PROGRAM [ARGUMENT]...', returning a proper advice when this fails due +to PROGRAM being missing or too old. + +Options: + -h, --help display this help and exit + -v, --version output version information and exit + +Supported PROGRAM values: + aclocal autoconf autoheader autom4te automake makeinfo + bison yacc flex lex help2man + +Version suffixes to PROGRAM as well as the prefixes 'gnu-', 'gnu', and +'g' are ignored when checking the name. + +Send bug reports to ." + exit $? + ;; + + -v|--v|--ve|--ver|--vers|--versi|--versio|--version) + echo "missing $scriptversion (GNU Automake)" + exit $? + ;; + + -*) + echo 1>&2 "$0: unknown '$1' option" + echo 1>&2 "Try '$0 --help' for more information" + exit 1 + ;; + +esac + +# Run the given program, remember its exit status. +"$@"; st=$? + +# If it succeeded, we are done. +test $st -eq 0 && exit 0 + +# Also exit now if we it failed (or wasn't found), and '--version' was +# passed; such an option is passed most likely to detect whether the +# program is present and works. +case $2 in --version|--help) exit $st;; esac + +# Exit code 63 means version mismatch. This often happens when the user +# tries to use an ancient version of a tool on a file that requires a +# minimum version. +if test $st -eq 63; then + msg="probably too old" +elif test $st -eq 127; then + # Program was missing. + msg="missing on your system" +else + # Program was found and executed, but failed. Give up. + exit $st +fi + +perl_URL=http://www.perl.org/ +flex_URL=http://flex.sourceforge.net/ +gnu_software_URL=http://www.gnu.org/software + +program_details () +{ + case $1 in + aclocal|automake) + echo "The '$1' program is part of the GNU Automake package:" + echo "<$gnu_software_URL/automake>" + echo "It also requires GNU Autoconf, GNU m4 and Perl in order to run:" + echo "<$gnu_software_URL/autoconf>" + echo "<$gnu_software_URL/m4/>" + echo "<$perl_URL>" + ;; + autoconf|autom4te|autoheader) + echo "The '$1' program is part of the GNU Autoconf package:" + echo "<$gnu_software_URL/autoconf/>" + echo "It also requires GNU m4 and Perl in order to run:" + echo "<$gnu_software_URL/m4/>" + echo "<$perl_URL>" + ;; + esac +} + +give_advice () +{ + # Normalize program name to check for. + normalized_program=`echo "$1" | sed ' + s/^gnu-//; t + s/^gnu//; t + s/^g//; t'` + + printf '%s\n' "'$1' is $msg." + + configure_deps="'configure.ac' or m4 files included by 'configure.ac'" + case $normalized_program in + autoconf*) + echo "You should only need it if you modified 'configure.ac'," + echo "or m4 files included by it." + program_details 'autoconf' + ;; + autoheader*) + echo "You should only need it if you modified 'acconfig.h' or" + echo "$configure_deps." + program_details 'autoheader' + ;; + automake*) + echo "You should only need it if you modified 'Makefile.am' or" + echo "$configure_deps." + program_details 'automake' + ;; + aclocal*) + echo "You should only need it if you modified 'acinclude.m4' or" + echo "$configure_deps." + program_details 'aclocal' + ;; + autom4te*) + echo "You might have modified some maintainer files that require" + echo "the 'autom4te' program to be rebuilt." + program_details 'autom4te' + ;; + bison*|yacc*) + echo "You should only need it if you modified a '.y' file." + echo "You may want to install the GNU Bison package:" + echo "<$gnu_software_URL/bison/>" + ;; + lex*|flex*) + echo "You should only need it if you modified a '.l' file." + echo "You may want to install the Fast Lexical Analyzer package:" + echo "<$flex_URL>" + ;; + help2man*) + echo "You should only need it if you modified a dependency" \ + "of a man page." + echo "You may want to install the GNU Help2man package:" + echo "<$gnu_software_URL/help2man/>" + ;; + makeinfo*) + echo "You should only need it if you modified a '.texi' file, or" + echo "any other file indirectly affecting the aspect of the manual." + echo "You might want to install the Texinfo package:" + echo "<$gnu_software_URL/texinfo/>" + echo "The spurious makeinfo call might also be the consequence of" + echo "using a buggy 'make' (AIX, DU, IRIX), in which case you might" + echo "want to install GNU make:" + echo "<$gnu_software_URL/make/>" + ;; + *) + echo "You might have modified some files without having the proper" + echo "tools for further handling them. Check the 'README' file, it" + echo "often tells you about the needed prerequisites for installing" + echo "this package. You may also peek at any GNU archive site, in" + echo "case some other package contains this missing '$1' program." + ;; + esac +} + +give_advice "$1" | sed -e '1s/^/WARNING: /' \ + -e '2,$s/^/ /' >&2 + +# Propagate the correct exit status (expected to be 127 for a program +# not found, 63 for a program that failed due to version mismatch). +exit $st + +# Local variables: +# eval: (add-hook 'write-file-hooks 'time-stamp) +# time-stamp-start: "scriptversion=" +# time-stamp-format: "%:y-%02m-%02d.%02H" +# time-stamp-time-zone: "UTC" +# time-stamp-end: "; # UTC" +# End: diff --git a/libs/ode-0.16.1/ode-config.cmake.in b/libs/ode-0.16.1/ode-config.cmake.in new file mode 100644 index 0000000..210b558 --- /dev/null +++ b/libs/ode-0.16.1/ode-config.cmake.in @@ -0,0 +1,13 @@ +set(ODE_VERSION "@VERSION@") +set(ODE_VERSION_MAJOR "@VERSION_MAJOR@") +set(ODE_VERSION_MINOR "@VERSION_MINOR@") +set(ODE_VERSION_PATCH "@VERSION_PATCH@") + +@PACKAGE_INIT@ + +include("${CMAKE_CURRENT_LIST_DIR}/ode-export.cmake") + +set(ODE_DEFINITIONS "") +set(ODE_INCLUDE_DIRS "${PACKAGE_PREFIX_DIR}/include") +set(ODE_LIBRARY_DIRS "${PACKAGE_PREFIX_DIR}/lib") +set(ODE_LIBRARIES "ODE::ODE") diff --git a/libs/ode-0.16.1/ode-config.in b/libs/ode-0.16.1/ode-config.in new file mode 100644 index 0000000..78fa45e --- /dev/null +++ b/libs/ode-0.16.1/ode-config.in @@ -0,0 +1,53 @@ +#!/bin/sh + +prefix=@prefix@ +exec_prefix=@exec_prefix@ +exec_prefix_set=no + +usage="\ +Usage: ode-config [--prefix[=DIR]] [--exec-prefix[=DIR]] [--version] [--cflags] [--libs]" + +if test $# -eq 0; then + echo "${usage}" 1>&2 + exit 1 +fi + +while test $# -gt 0; do + case "$1" in + -*=*) optarg=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'` ;; + *) optarg= ;; + esac + + case $1 in + --prefix=*) + prefix=$optarg + if test $exec_prefix_set = no ; then + exec_prefix=$optarg + fi + ;; + --prefix) + echo $prefix + ;; + --exec-prefix=*) + exec_prefix=$optarg + exec_prefix_set=yes + ;; + --exec-prefix) + echo $exec_prefix + ;; + --version) + echo @ODE_VERSION@ + ;; + --cflags) + echo -I@includedir@ + ;; + --libs) + echo -L@libdir@ -lode + ;; + *) + echo "${usage}" 1>&2 + exit 1 + ;; + esac + shift +done diff --git a/libs/ode-0.16.1/ode.pc.in b/libs/ode-0.16.1/ode.pc.in new file mode 100644 index 0000000..9fa106a --- /dev/null +++ b/libs/ode-0.16.1/ode.pc.in @@ -0,0 +1,12 @@ +prefix=@prefix@ +exec_prefix=@exec_prefix@ +libdir=@libdir@ +includedir=@includedir@ +precision=@ODE_PRECISION@ + +Name: ode +Description: Open Dynamics Engine +Version: @ODE_VERSION@ +Libs: -L${libdir} -lode +Libs.private: -lstdc++ -lm +Cflags: -I${includedir} diff --git a/libs/ode-0.16.1/ode/Makefile.am b/libs/ode-0.16.1/ode/Makefile.am new file mode 100644 index 0000000..656e7a4 --- /dev/null +++ b/libs/ode-0.16.1/ode/Makefile.am @@ -0,0 +1,6 @@ +SUBDIRS = src doc +if ENABLE_DEMOS + SUBDIRS += demo +endif + +#EXTRA_DIST = doc diff --git a/libs/ode-0.16.1/ode/Makefile.in b/libs/ode-0.16.1/ode/Makefile.in new file mode 100644 index 0000000..eae84a5 --- /dev/null +++ b/libs/ode-0.16.1/ode/Makefile.in @@ -0,0 +1,643 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +@ENABLE_DEMOS_TRUE@am__append_1 = demo +subdir = ode +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ + $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ + $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/ode/src/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +SOURCES = +DIST_SOURCES = +RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ + ctags-recursive dvi-recursive html-recursive info-recursive \ + install-data-recursive install-dvi-recursive \ + install-exec-recursive install-html-recursive \ + install-info-recursive install-pdf-recursive \ + install-ps-recursive install-recursive installcheck-recursive \ + installdirs-recursive pdf-recursive ps-recursive \ + tags-recursive uninstall-recursive +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ + distclean-recursive maintainer-clean-recursive +am__recursive_targets = \ + $(RECURSIVE_TARGETS) \ + $(RECURSIVE_CLEAN_TARGETS) \ + $(am__extra_recursive_targets) +AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ + distdir +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +DIST_SUBDIRS = src doc demo +am__DIST_COMMON = $(srcdir)/Makefile.in README TODO +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +am__relativize = \ + dir0=`pwd`; \ + sed_first='s,^\([^/]*\)/.*$$,\1,'; \ + sed_rest='s,^[^/]*/*,,'; \ + sed_last='s,^.*/\([^/]*\)$$,\1,'; \ + sed_butlast='s,/*[^/]*$$,,'; \ + while test -n "$$dir1"; do \ + first=`echo "$$dir1" | sed -e "$$sed_first"`; \ + if test "$$first" != "."; then \ + if test "$$first" = ".."; then \ + dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ + dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ + else \ + first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ + if test "$$first2" = "$$first"; then \ + dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ + else \ + dir2="../$$dir2"; \ + fi; \ + dir0="$$dir0"/"$$first"; \ + fi; \ + fi; \ + dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ + done; \ + reldir="$$dir2" +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AS = @AS@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CCD_CFLAGS = @CCD_CFLAGS@ +CCD_LIBS = @CCD_LIBS@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DOXYGEN = @DOXYGEN@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +EXTRA_LIBTOOL_LDFLAGS = @EXTRA_LIBTOOL_LDFLAGS@ +FGREP = @FGREP@ +GL_LIBS = @GL_LIBS@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBSTDCXX = @LIBSTDCXX@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +ODE_PRECISION = @ODE_PRECISION@ +ODE_VERSION = @ODE_VERSION@ +ODE_VERSION_INFO = @ODE_VERSION_INFO@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +WINDRES = @WINDRES@ +X11_CFLAGS = @X11_CFLAGS@ +X11_LIBS = @X11_LIBS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_WINDRES = @ac_ct_WINDRES@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +runstatedir = @runstatedir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +SUBDIRS = src doc $(am__append_1) +all: all-recursive + +.SUFFIXES: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign ode/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign ode/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +# This directory's subdirectories are mostly independent; you can cd +# into them and run 'make' without going through this Makefile. +# To change the values of 'make' variables: instead of editing Makefiles, +# (1) if the variable is set in 'config.status', edit 'config.status' +# (which will cause the Makefiles to be regenerated when you run 'make'); +# (2) otherwise, pass the desired values on the 'make' command line. +$(am__recursive_targets): + @fail=; \ + if $(am__make_keepgoing); then \ + failcom='fail=yes'; \ + else \ + failcom='exit 1'; \ + fi; \ + dot_seen=no; \ + target=`echo $@ | sed s/-recursive//`; \ + case "$@" in \ + distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ + *) list='$(SUBDIRS)' ;; \ + esac; \ + for subdir in $$list; do \ + echo "Making $$target in $$subdir"; \ + if test "$$subdir" = "."; then \ + dot_seen=yes; \ + local_target="$$target-am"; \ + else \ + local_target="$$target"; \ + fi; \ + ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ + || eval $$failcom; \ + done; \ + if test "$$dot_seen" = "no"; then \ + $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ + fi; test -z "$$fail" + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-recursive +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ + include_option=--etags-include; \ + empty_fix=.; \ + else \ + include_option=--include; \ + empty_fix=; \ + fi; \ + list='$(SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + test ! -f $$subdir/TAGS || \ + set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ + fi; \ + done; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-recursive + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-recursive + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done + @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + $(am__make_dryrun) \ + || test -d "$(distdir)/$$subdir" \ + || $(MKDIR_P) "$(distdir)/$$subdir" \ + || exit 1; \ + dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ + $(am__relativize); \ + new_distdir=$$reldir; \ + dir1=$$subdir; dir2="$(top_distdir)"; \ + $(am__relativize); \ + new_top_distdir=$$reldir; \ + echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ + echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ + ($(am__cd) $$subdir && \ + $(MAKE) $(AM_MAKEFLAGS) \ + top_distdir="$$new_top_distdir" \ + distdir="$$new_distdir" \ + am__remove_distdir=: \ + am__skip_length_check=: \ + am__skip_mode_fix=: \ + distdir) \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-recursive +all-am: Makefile +installdirs: installdirs-recursive +installdirs-am: +install: install-recursive +install-exec: install-exec-recursive +install-data: install-data-recursive +uninstall: uninstall-recursive + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-recursive +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-recursive + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-recursive + -rm -f Makefile +distclean-am: clean-am distclean-generic distclean-tags + +dvi: dvi-recursive + +dvi-am: + +html: html-recursive + +html-am: + +info: info-recursive + +info-am: + +install-data-am: + +install-dvi: install-dvi-recursive + +install-dvi-am: + +install-exec-am: + +install-html: install-html-recursive + +install-html-am: + +install-info: install-info-recursive + +install-info-am: + +install-man: + +install-pdf: install-pdf-recursive + +install-pdf-am: + +install-ps: install-ps-recursive + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-recursive + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-recursive + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-recursive + +pdf-am: + +ps: ps-recursive + +ps-am: + +uninstall-am: + +.MAKE: $(am__recursive_targets) install-am install-strip + +.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \ + check-am clean clean-generic clean-libtool cscopelist-am ctags \ + ctags-am distclean distclean-generic distclean-libtool \ + distclean-tags distdir dvi dvi-am html html-am info info-am \ + install install-am install-data install-data-am install-dvi \ + install-dvi-am install-exec install-exec-am install-html \ + install-html-am install-info install-info-am install-man \ + install-pdf install-pdf-am install-ps install-ps-am \ + install-strip installcheck installcheck-am installdirs \ + installdirs-am maintainer-clean maintainer-clean-generic \ + mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ + ps ps-am tags tags-am uninstall uninstall-am + +.PRECIOUS: Makefile + + +#EXTRA_DIST = doc + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/libs/ode-0.16.1/ode/README b/libs/ode-0.16.1/ode/README new file mode 100644 index 0000000..dd4596f --- /dev/null +++ b/libs/ode-0.16.1/ode/README @@ -0,0 +1,158 @@ +Dynamics Library. +================= + +CONVENTIONS +----------- + +matrix storage +-------------- + +matrix operations like factorization are expensive, so we must store the data +in a way that is most useful to the matrix code. we want the ability to update +the dynamics library without recompiling applications, e.g. so users can take +advantage of new floating point hardware. so we must settle on a single +format. because of the prevalence of 4-way SIMD, the format is this: store +the matrix by rows or columns, and each column is rounded up to a multiple of +4 elements. the extra "padding" elements at the end of each row/column are set +to 0. this is called the "standard format". to indicate if the data is stored +by rows or columns, we will say "standard row format" or "standard column +format". hopefully this decision will remain good in the future, as more and +more processors have 4-way SIMD, and 3D graphics always needs fast 4x4 +matrices. + +exception: matrices that have only one column or row (vectors), are always +stored as consecutive elements in standard row format, i.e. there is no +interior padding, only padding at the end. + +thus: all 3x1 floating point vectors are stored as 4x1 vectors: (x,x,x,0). +also: all 6x1 spatial velocities and accelerations are split into 3x1 position + and angular components, which are stored as contiguous 4x1 vectors. + +ALL matrices are stored by in standard row format. + + +arguments +--------- + +3x1 vector arguments to set() functions are supplied as x,y,z. +3x1 vector result arguments to get() function are pointers to arrays. +larger vectors are always supplied and returned as pointers. +all coordinates are in the global frame except where otherwise specified. +output-only arguments are usually supplied at the end. + + +memory allocation +----------------- + +with many C/C++ libraries memory allocation is a difficult problem to solve. +who allocates the memory? who frees it? must objects go on the heap or can +they go on the stack or in static storage? to provide the maximum flexibility, +the dynamics and collision libraries do not do their own memory allocation. +you must pass in pointers to externally allocated chunks of the right sizes. +the body, joint and colllision object structures are all exported, so you +can make instances of those structure and pass pointers to them. + +there are helper functions which allocate objects out of areans, in case you +need loots of dynamic creation and deletion. + +BUT!!! this ties us down to the body/joint/collision representation. + +a better approach is to supply custom memory allocation functions +(e.g. dlAlloc() etc). + + +C versus C++ ... ? +------------------ + +everything should be C linkable, and there should be C header files for +everything. but we want to develop in C++. so do this: + * all comments are "//". automatically convert to /**/ for distribution. + * structures derived from other structures --> automatically convert? + + +WORLDS +------ + +might want better terminology here. + +the dynamics world (DWorld) is a list of systems. each system corresponds to +one or more bodies, or perhaps some other kinds of physical object. +each system corresponds to one or more objects in the collision world +(there does not have to be a one-to-one correspondence between bodies and +collision objects). + +systems are simulated separately, perhaps using completely different +techniques. we must do something special when systems collide. +systems collide when collision objects belonging to system A touch +collision objects belonging to system B. + +for each collision point, the system must provide matrix equation data +that is used to compute collision forces. once those forces are computed, +the system must incorporate the forces into its timestep. +PROBLEM: what if we intertwine the LCP problems of the two systems - then +this simple approach wont work. + +the dynamics world contains two kinds of objects: bodies and joints. +joints connect two bodies together. + +the world contains one of more partitions. each partition is a collection of +bodies and joints such that each body is attached (through one or more joints) +to every other body. + +Joints +------ + +a joint can be connected to one or two bodies. +if the joint is only connected to one body, joint.node[1].body == 0. +joint.node[0].body is always valid. + + +Linkage +------- + +this library will always be statically linked with the app, for these reasons: + * collision space is selected at compile time, it adds data to the geom + objects. + + +Optimization +------------ + +doubles must be aligned on 8 byte boundaries! + + +MinGW on Windows issues +----------------------- + +* the .rc file for drawstuff needs a different include, try winresrc.h. + +* it seems we can't have both main() and WinMain() without the entry point + defaulting to main() and having resource loading problems. this screws up + what i was trying to do in the drawstuff library. perhaps main2() ? + +* remember to compile resources to COFF format RES files. + + + +Collision +--------- + +to plug in your own collision handling, replace (some of?) these functions +with your own. collision should be a separate library that you can link in +or not. your own library can call components in this collision library, e.g. +if you want polymorphic spaces instead of a single statically called space. + +creating an object will automatically register the appropriate +class (if necessary). how can we ensure that the minimum amount of code is +linked in? e.g. only one space handler, and sphere-sphere and sphere-box and +box-box collision code (if spheres and boxes instanced). + +the user creates a collision space, and for each dynamics object that is +created a collision object is inserted into the space. the collision +object's pos and R pointers are set to the corresponding dynamics +variables. + +there should be utility functions which create the dynamics and collision +objects at the same time, e.g. dMakeSphere(). + +collision objects and dynamics objects keep pointers to each other. diff --git a/libs/ode-0.16.1/ode/TODO b/libs/ode-0.16.1/ode/TODO new file mode 100644 index 0000000..cf6cdaa --- /dev/null +++ b/libs/ode-0.16.1/ode/TODO @@ -0,0 +1,698 @@ + +@@@'s + + +TODO for COLLISION +------------------ + +box-box collision: adjust generated face-face contact points by depth/2 to +be more fair. + +what happens when a GeomTransform's encapsulated object is manipulated, +e.g. position changed. should this be disallowed? should a GeomTransform +behave like a space and propagate dirtyness upwards? + +make sure that when we are using a large space for static environmental geoms, +that there is not excessive AABB computation when geoms are added/removed from +the space. the space AABB is pretty much guaranteed to cover everything, so +there's no need to compute/test the AABB in this case. + +hash space: implement collide2() efficiently instead of the current +simple-space-like brute-force approach. + +hash space: incremental scheme, so we dont have to rebuild the data structures +for geoms that don't move. + +disabled geoms (remove from all collision considerations) ... isn't this the +same as just taking it out of its enclosing group/space? + +integrate: + dRay + triangle collider - get latest tri collider code from erwin + erwin's quadtree space + +tests: + all aspects of collision API + + dGeomSetBody(0) maintains body-geom linked list properly. + + simple space: instantiate lots of non-moving geoms (i.e. environmental + geoms and make sure that we're still able to collide efficiently. + make sure AABB computation is efficient, or can be made efficient + through proper use of the API. + + test C interface support for making new classes. + make sure the dxGeom::aabbTest() function behaves as advertised. + + testing for contact point consistency: test for things that + would cause the dynamics to fail or become unstable + + test for: small adjustment in geom position causes a big jump in the + contact point set (bad for dynamics). + + test for: if contact constraints observed then it's impossible + (or hard) to move the objects so that the penetration is + increased. relax this when only a subset of the contact points are + returned. + + test for consistency, e.g. the boundary of geoms X and Y can + be defined by intersecting with a point, so test the intersection of X + and Y by comparing with the point tests. + + check that contact points are in the collision volume + + all existing space tests, and more. + +demos: + test_buggy: make a terrain out of non-moving geoms. use heirarchical + groups to get efficient collision, even with the simple space. + +go though the new collision docs and make sure the behavior that is described +there is actually implemented. + +multi-resolution hash table: + the current implementation rebuilds a new hash table each time + collide() is called. we don't keep any state between calls. this is + wasteful if there are unmoving objects in the space. + + make sure we prevent multiple collision callbacks for the same pair + + better virtual address function. + + the collision search can perhaps be optimized - as we search + chains we can come across other candidate intersections at + other levels, perhaps we should do the intersection check + straight away? --> save on list searching time only, which is + not too significant. + +collision docs: + optimization guide: whenever a single geom changes in a simple space, + the space AABB has to be recomputed by examining EVERY geom. + document this, or find a better behavior. + + + +TODO BEFORE NEXT RELEASE +------------------------ + +g++ needed for compiling tests using gcc 3.2 ? what is the problem? + +add joint feedback info from lambda, so that we can get motor forces etc. +need a way to map constraint indexes to what they mean. + +track down and fix the occasional popping/jumping problem in test_boxstack, +especially when boxes are piled on top of each other. find out if this is +caused by a configuration singularity or whether there is a bug in LCP. +i need to add some kind of diagnostic tool to help resolve these kinds of +problems. + +fixup ground plane jitter and shadow jumping in drawstuff. + +the inertias/COMs don't appear to be totally correct for the boxstack demo. +fix up, and add a mode that shows the effective mass box (for a given density). + +Improve box-box collision, especially for face-face contact (3 contact points). +Improve cylinder-box collision (2 contact points). + +windows DLL building and unix shared libs. libtool? +also MSVC project files. + +dBodyGetPointVel() + +contrib directory - all stuff in ~/3/ode + +functions to allow systems to be copied/cloned + dBodyTransplant (b, world) + dTransplantIsland (b, world) + dBodyCopy (bdest, bsrc) + dJointCopy (jdest, jsrc) -- what about body connections? + dCloneBody() + dCloneJoint() + dCloseBodyAndJointList() + dCloneIsland() + +this collision rule: + // no contacts if both geoms on the same body, and the body is not 0 + if (g1->body == g2->body && g1->body) return 0; +needs to be replaced. sometimes we want no collision when both bodies are 0, +but this wont work for geomgroup-to-environment. avoid stupid stuff like + dGeomSetBody (geom_group, (dBodyID) 1); +this also causes "failed-to-report" errors in the space test. + +Expose type-specific collision functions? + +Automatic code optimization process. + +joint limit spongyness: interacts with powered joints badly, because when the +limit is reached full power is applied. fix or doc. + +various hinge2 functions may not function correctly if axis1 and axis2 are not +perpendicular. in particular the getAngle() and getAngleRate() functions +probably will give bogus answers. + +slow step function will not respect the joint getinfo2 functions calling +addTorque() because it reads the force/torque accumulators before the +getinfo2 functions are called. + +spaces need multiple lists of objects that can never overlap. objects in these +lists are never tested against each other. + +deleting a body a joint is attached to should adjust the joint to only have +one body attached. currently the connected joints have *both* their body +attachments removed. BUT, dont do this if the dJOINT_TWOBODIES flag is set +on the joint. + +document error, mem and math functions. + +Web pages + credits section + projects using ODE + +update C++ interface? use SWIG? + +collision exclusion groups - exclude if obj1.n == obj2.n ? + +make sure the amotor joint can be used with just one body. at the moment it +only allows two-body attachments. + +implement dJointGetAMotorAngleRate() + +erwin says: Should the GeomGroup have a cleanupmode as the GeomTransform has? + +erwin says: http://q12.org/pipermail/ode/2002-January/000766.html + and http://q12.org/pipermail/ode/2001-December/000753.html + +rename duplicate filenames (object.h?) - some environments can't handle this. + +naming inconsistency: dCreateSphere() should be dSphereCreate() (etc...) to +match the rest of the API. + + +TODO +---- + +joint allocation in joint groups. allocation size should be rounded up using +dEFFICIENT_SIZE, to properly align all the data members. + +all dAlloc() allocations should be aligned using dEFFICIENT_SIZE() ??? + +automatic body & joint disabling / enabling. + +sometimes getting LCP infinite loops. + +function to get the entire island of bodies/joints + +joints: + hinge2 joint - implement trail, i.e. non-convergent steering and wheel + axes. + + erp individually settable for each joint? + + more joints: + angular3 (constrian full angle not position) + fixed path 1 (point must follow fixed path, etc etc) + - other fixed path joints. + linear a (point in 1 body fixed to plane of other) + linear b (point in 1 body fixed to line on other) + linear c (line in 1 body fixed to plane on other) + linear d (line in 1 body fixed to line on other) - like + prismatic but orientation along line can change + Relative-Path-Relative-Oriention Joint (set all dofs of 2 + bodies relative to each other) + spring (with natural length) + universal (2 kinds) + various angular relationships + + when attaching joints to static env, provision to move attachment + point (e.g. give it a linear/angular velocity). this can be used + instead of a FPFO joint on a body in many cases. + also do this with contacts to static env, to allow for contacts to + *moving* objects in the static env. + + interpretation of erp: is it (1) the error reduction per timestep, + (2) or a time constant independent of timestep?? if it's (2) then + perhaps this should be universal - this is already the meaning for + the suspension. + + hinge2 suspension: + suspension limits + suspension limit restitution and spongyness?? + +use autoconf? set paths in makefile? + +no-arg init functions, for andy + +explore: do joint parameters need to be set for the joint to be setup +correctly, or should set some proper body-dependent params when it is +attached? this is only really an issue for joints that have no parameters to +set, such as the fixed joint. + +dAlloc() should take an arena parameters which is stored in dWorld. + +debugging mode should use dASSERT2 that prints a descriptive error message +on error, not just the file:line or function. use dASSERT for internal +consistency checking. + +when vectors and matrices are initialized, we must ensure that the padding +elements are set to 0. this is going to be a problem everywhere! + +don't use 3-vectors anywhere. use SIMD friendly 4-vectors. + +make sure all data in body/joint etc objects is aligned well for single +precision SIMD (i.e. all vectors start on a 16 byte boundary). + +think about more complicated uses of collision, e.g. a single geom representing +an articulated structure. + +bodyGroup? (like joint group but for bodies). systemGroup? + +check the overhead of resizing Array<>s as elements are pushed on to them. + +replace alloca() with dPushFrame(), dPopFrame(), and dAlloca() ? allow for +the possibility of allocating in non-stack memory ? + +make sure that we can set mass parameters with non-zero center of mass. +if this is done after the body position is set, the position is adjusted. +if this is done before the body position is set, what do we do when the +pos is set? does the pos always refer to the center of mass from the user's +point of view? + +consider splitting solver into functions, which can be optimized separately. +might make things go faster. + +faster code for islands with a single body? faster code for dynamically +symmetric bodies? + +rotation.cpp functions that set matrices should also set padding elements. + +lcp solver must return (L,d) and some other information, so we can re-solve +for other right hand sides later on, but using the same complimentarity +solution so there are no integrator discontinuities. + +dSetZero() - make fast inline functions for fixed n e.g. (1-4). + +need proper `sticky' friction, i.e. compensation for numerical slip. + +on windows, make sure gcc-compiles libs can be linked with VC++ apps. need +to make sure some C++ runtime bits are present? + +kill all references to dArray<> (in geom.cpp). + +need testing code to test all joints with body-to-static-env + +copy stack.cpp, memory.cpp stuff to reuse + +dFactorLDLT() is not so efficient for matrix sizes < block size, e.g. +redundant calls, zero loads, adds etc + +contacts: cheaper friction: viscous friction? one step delay friction force. + +in geom.cpp, for objects that are never meant to collide, dCollide() will +always try to find the collider functions, which wastes a bit of time. + +geom.cpp:dCollideG() - handle special case of colliding 2 groups more +efficiently. + +timer reporting function: + void timerReport (void (*printFunction)(char *, ...)); + +disabled bodies stored in a separate list, so they are never traversed at all, +for speed when there are many disabled bodies. + + +MAYBE +----- + +new implementation for joint groups that is not so system dependent. +maybe individual contacts are reusable? in this case contact information +should be settable in the contact joints. max_size arg is really annoying. + +consider making anchor,axis, (everything) into a joint parameter and setting +them with a consistent interface. also consider overload the joint functions +so they are not distinguished by joint type?? + +collision memory optimizations? + +collision: support for persistent contact information? + +multiply reference tri list data so that it can be cloned + if the tri-list geoms could support rot/pos + transformations then we could have several tri-lists pointing to the + same vertex information. + +height fields + +pre-converted collision data -- Creating a hash space and associated +opcode tree structures may take significant amounts of time for a +large world with many 10s of thousands of triangles. Any chance of +pre-building that off-line and passing a memory block pointer to the +collision system? + +putting objects in multiple spaces -- If it was possible to add +objects to more than one space, you could do collision queries other +than 1vsN and NvsN. That flexibility might be useful when you want to +only collide against a subset of the space. For example, a camera +system may want to collide some rays with occlusion walls but the +occlusion walls may also need to be in the game-level space to bounce +against. + + +ALWAYS +------ + +make sure functions check their arguments in debug mode (e.g. using dASSERT). +make sure joint/geom functions check for the specific object type. + +vectors alloca()ed on the stack must have the correct alignment, use ALLOCA16. + +library should have no global constructors, as it might be used with C linkage. + +use `const' in function arguments. blah. + + + +DON'T BOTHER +------------ + +warning if user tries to set mass params with nonzero center of mass. + + + +DONE +---- + +check: when contact attached with (body1,0) and (0,body1), check that polarity +on depth and error info is okay for the two cases. + +set a better convention for which is the 1st and 2nd body in a joint, because +sometimes we get things swapped (because of the way the joint nodes are used). + +hinge and prismatic, attachment to static environment. + +turn macros into C++ inline functions? what about C users? + +remove `space' argument to geom creation functions? make user add it? +or just remove it from dCreateGeom() ? <-- did this one. + +test_chain should be in C, not C++. but first must remove global constructors. + +add more functionality to C++ interface - dMass, dSpace, dGeom + +there should be functions to delete groups of bodies/joints in one go - this +will be more efficient than deleting them one at a time, because less +partitioning tests will be needed. + +should we expose body and joint object structures so that the user can +explicitly allocate them locally, or e.g. on the stack? makes allocating +temporary contact constraints easier. NO --> helps data hiding and therefore +library binary compatability. + +joints: + hinge & slider - DONE + measure angle, rate - DONE + power - DONE + joint limits - DONE + mixed powered+limited joints, powering away from limit - DONE + + hinge2 - DONE + steering angle and rate measurement - DONE + steering limits - DONE + steering motor - DONE + wheel motor - DONE + wheel angle rate measurement - DONE + + optional hinge2 suspension: - DONE + alignment of B&S part to given axis - DONE + global framework for giving epsilon and gamma - DONE + + toss away r-motor, make power & stuff specific to joint - DONE + it's just easier that way + + joint code reuse: - DONE + use standard functions to set velocity (c), limits (lo,hi), + spongyness (epsilon) etc, this prevents these functions from + proliferating + + implicit spring framework - actually allow joints to return a value `k' + such that J*vnew = c + k*f, where f = force needed to achieve + vnew - DONE + + contact slip - DONE + contact erp & cfm parameters (not just "softness") - DONE + + hinge2: when we lock back wheels along the steering axis, there is no + error correction if they get out of alignment - DONE, just use high + and low limits. + + joint limit spongyness: erp and cfm for joint set from world (global) + values when joint created. - DONE + + joint limit restitution - DONE + +check inertia transformations, e.g. by applying steering torque to a thin +wheel --> actually, i made test_I + +more comprehensive random number comparisons between slow and fast methods. + - random PD inertia (not just diagonal). + - random velocity + - random joint error (make joints then move bodies a bit) + +check that J*vnew=c (slow step already does this, but it doesn't equal zero +for some reason! - actually, when LCP constraint limits are reached, it wont!) + +tons of things in lcp.cpp (@@@), especially speed optimizations. also, we +wanted to do index block switching and index block updates to take advantage +of the outer product trick ... but this is not worth the effort i think. + +lcp.cpp: if lo=hi=0, check operation. can we switch from NL <-> NH without +going through C? --> done. + +andy says: still having trouble with those resource files.. +drawstuff.res doesn't seem to build or be found under cygwin gcc. + +DOC how bodies and geoms associated then resolved in contact callback ... not +really necessary. + +fix the "memory leak" in geom.cpp + +library should have no global constructors, as it might be used with C linkage. + --> as long as test_chain1 works, there are none. + +DOC cfm, the derivation and what it means. + --> partially done, could be better + +joint "get type" function + +andy says: in ode/src/error.cpp _snprintf() and _vsnprintf() are missing +in testode: finite and isnan are missing. copysign is missing + russ: okay here's the problem: i have Makefile.platform files for + VC++, MinGW, but not Cygwin. Cygwin uses the unix-like functions + for everything, but the VC++/MinGW configs assumes the MS C-runtime + functions. this is easy to fix, except i need to install Cygwin + which is a pain to do over MinGW. argh. + +build on linux - assumptions made about location of X11 lib, opengl etc. + +implement: dBodyAddForceAtPos,dBodyAddRelForceAtPos,dBodyAddRelForceAtRelPos, + dBodyGetPointPos,dBodyGetPointVel,dBodyGetPointRelVel + +dJointAttach(), allow both bodies to be 0 to put the joint into limbo. + +space near-callback should be given potentially intersecting objects 100 at a +time instead of 1 at a time, to save on calling costs ... which are trivial, +so we don't bother to do this. + +doccer: @func{} also refs second etc function in function *list*. + +make sure joints can return 0 from GetInfo1, i.e. no constraints or "inactive" +joint, and the step functions will handle it. + +when attaching contact with (0,body), instead of setting the reverse flag +on the joint and checking it in getInfo2(), we should just reverse the normal +straight away ... ? + --> trouble is, dJointAttach() knows nothing about what kind of joint + it is attaching. + +hinge2 needs to be attached to two bodies for it to work, make sure this is +always the case. --> assertion added in dJointAttach(). + +if two joints connect to the same two bodies, check that the fast solver +works! -> it should. + +functions to get all the joints/bodies a body/joint is connected to. + +If I don't have the GCC libraries installed, HUGE_VALF is undefined. + +fix capped cylinder - capped cylinder collision so that two contacts can +be generated. + +transformation geometry object. + +joint groups should also be destroyed by destroying the world --> naaahhh. + +DONT DO THIS: body/joint creators with world = 0 --> not inserted into any +world. allow bodies/joints to be detached from a world (this is what happens +to grouped joints when a world is destroyed). + can bodies and joints be linked together when not attached to world?? + what happens when we have an island of b/j, some of which are not in + world? soln: dont keep lists of b/j in the world, just infer it from + the islands? + +body & joint disabling / enabling + +start a change log. + +collision flags - 0xffff mask. + +dBodyGetFiniteRotationMode() / ...Axis() + +dBodyAddForceAtRelPos() + +ball & socket joint limits and motors. + +auto-build env on windows: 3 compilers, debug/release, short/double = +12 combinations --> auto logs. + +handle infinities better: HUGE_VALF is not commanly defined, it seems. +get rid of the __USE_ISOC9X macro in common.h +perhaps just use a "big" number instead of the actual IEEE infinity, it's +more portable anyway. + --> new config system + +dCloseODE() - tidy up *all* allocated memory, esp in geom.cpp. used to keep +leak detectors happy. + +extra API to get lambda and J'*lambda from last timestep. + +better stack implementation that is not so system dependent. but how will +we do dynamic page allocation? do we even need to? + + +all collision files will now be collision_*, not geom_* + +check exported global symbols - no C++ mangling. + +rename dSphere etc to dxSphere etc. + +C interface support for making new classes. + +make sure DLL-ized stuff preserved ... but class numbers should no longer be +exported. + +point geom ( = sphere of radius 0 ) + +geoms stored in doubly linked lists in space (fast removal). + +bodies need to keep geoms pointers and call dGeomMoved() in dBodySetPosition() +etc and world step. PROBLEM: links dynamics and collision together too much, +makes it hard to extract ODE collision ... unless we say: dGeomMoved() and +dGeomID must be supplied by the new collision library! + +dCollide() should take spaces as arguments - it should call dSpaceCollide2() +with its own callback that puts all found contacts in the array, stopping +when there is no more space left in the array. + +dxSpace::getGeom() - the geom numbers will change as geoms are dirtied - find +some other numbering scheme, or document this behavior. + +the 'placeable' property - objects that should not ever be attached to bodies +should flag an error when setBody etc are called. + +dGeomSetBody(0) - DOC: the position and orientation of the body will be +preserved. in this case the geom should NOT be dirtied (dGeomMoved() should +not be called). + +DOC: dGeomGetBodyNext() as part of dynamics/collision interface + +groups/spaces are subclasses of geom. + +groups/spaces can contain other groups/spaces. geom can be owned by a +group/space. collision handling: + geom-geom : standard collision function + geom-group : special space code + group-group : n^2 tests (or n space tests) - hard to optimize because + of disjoint space representations. + group internal : normal space internal-collision code + +groups/spaces can be told that some objects never move, i.e. that the objects +are locked. should we lock the whole space? + locking: the AABB for the object is not recalculated + +groups/spaces can be told that the internal contents self-intersect or not. +actually an old ODE group is the equivalent of an old ODE simple space. + - just call dCollide() or not. + +the group doesn't get passed to the space callback any more ... only the +intersecting geoms get passed? maybe the callback can initiate the extra +intersection tests itself? (because we want programmable flexibility to +determine what gets intersected and what doesn't) + - NO + +infrastructure to indicate when an object has moved (and thus its AABB needs +to be recalculated) + +space enumeration functions. make sure that there are no additions or deletions +while enumeration is taking place. + - documented the behavior, didn't disallow it + +cache the AABB in the dxGeom? (for non-moving objects) - perhaps keep a +pointer to separately allocated space? ... no + +DOC: dGeomGetClass() is a first-class geom function, not in the "User +defined classes" section. it returns a constant that can be checked +against dSphereClass etc. + +remove dxGeom dependence on dBodyID? ... not yet + +dBase -> dxBase + +allow a geom to be inserted into multiple spaces? need this to optimize some +kinds of tests ... no + +update docs. + +make CHECK_NOT_LOCKED an assert. + +DOC: "Calling these functions on a non-placeable geom results in a +runtime error." ...in the debug build only? + +non-placeable geoms should not allocate dxPosR. perhaps pass a dGeom +constructor arg that says 'placeable' or not - this also sets the +GEOM_PLACEABLE flag. + +GeomTransform: + final_pos and final_R valid if no GEOM_AABB_BAD flag!!! + fix up this code, esp use of ComputeTX(). + +Space incompatibilities: no dSpaceDestroy(), dGeomDestroy() does not +take a dSpaceID ... dSpaceDestroy() added. + +GeomGroup incompatibilities: + dCollide() used to take a GeomGroup and would return all the contact + points for all the intersecting objects. now you have to call + dSpaceCollide2() and get a callback for each one. + need to provide old behavior. + +simple space optimization: we should keep the precomputed AABB for the +non-moving geoms around, so that when the other geoms move we can just +compute the AABBs for those geoms and then combine it with the non-moving AABB. + --> too hard! + +collision build options: old and new + +tidyups for collision: + * rationalize what stuff goes in what source files, and file names + * minimize set of header files that all collision* sources use - after + all changes. + * update ode-cpp stuff (C++ interface header files). + +porting guide: + ODE list email + + dGeomGetSpaceAABB() deleted + + dGeomGetClass (geom_group); used to return a unique type for + GeomGroups, but now it returns dSimpleSpaceID. + +tidyups: update DLL declarations. + diff --git a/libs/ode-0.16.1/ode/demo/Makefile.am b/libs/ode-0.16.1/ode/demo/Makefile.am new file mode 100644 index 0000000..5d02b87 --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/Makefile.am @@ -0,0 +1,75 @@ +AM_CPPFLAGS = -I$(top_srcdir)/include \ + -I$(top_builddir)/include \ + -DDRAWSTUFF_TEXTURE_PATH="\"$(abs_top_srcdir)/drawstuff/textures\"" + +if X11 +AM_LDFLAGS = $(X_PRE_LIBS) $(X_LIBS) $(X_EXTRA_LIBS) +endif + +# On Windows, GL_LIBS must go after libdrawstuff.la. +LDADD = $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la @GL_LIBS@ + +noinst_HEADERS = basket_geom.h bunny_geom.h convex_bunny_geom.h convex_prism.h \ + icosahedron_geom.h halton235_geom.h texturepath.h world_geom3.h + +AM_DEFAULT_SOURCE_EXT = .cpp + +noinst_PROGRAMS = \ + demo_boxstack \ + demo_buggy \ + demo_cards \ + demo_chain1 \ + demo_chain2 \ + demo_collision \ + demo_convex \ + demo_crash \ + demo_cylvssphere \ + demo_dball \ + demo_dhinge \ + demo_transmission \ + demo_feedback \ + demo_friction \ + demo_gyroscopic \ + demo_gyro2 \ + demo_heightfield \ + demo_hinge \ + demo_I \ + demo_jointPR \ + demo_joints \ + demo_jointPU \ + demo_kinematic \ + demo_motion \ + demo_motor \ + demo_ode \ + demo_piston \ + demo_plane2d \ + demo_rfriction \ + demo_slider \ + demo_space \ + demo_space_stress \ + demo_step \ + demo_tracks + +demo_chain1_SOURCES = demo_chain1.c +demo_chain1_LDADD = $(LDADD) -lstdc++ + + +if TRIMESH +noinst_PROGRAMS += \ + demo_basket \ + demo_cyl \ + demo_moving_trimesh \ + demo_moving_convex \ + demo_trimesh + +AM_CPPFLAGS += -DdTRIMESH_ENABLED +endif + + + +if WIN32 +resources.o: $(top_srcdir)/drawstuff/src/resources.rc $(top_srcdir)/drawstuff/src/resource.h + @WINDRES@ $(top_srcdir)/drawstuff/src/resources.rc -o resources.o +LDADD += resources.o +endif diff --git a/libs/ode-0.16.1/ode/demo/Makefile.in b/libs/ode-0.16.1/ode/demo/Makefile.in new file mode 100644 index 0000000..368a5d1 --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/Makefile.in @@ -0,0 +1,1133 @@ +# Makefile.in generated by automake 1.15 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994-2014 Free Software Foundation, Inc. + +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + + +VPATH = @srcdir@ +am__is_gnu_make = { \ + if test -z '$(MAKELEVEL)'; then \ + false; \ + elif test -n '$(MAKE_HOST)'; then \ + true; \ + elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ + true; \ + else \ + false; \ + fi; \ +} +am__make_running_with_option = \ + case $${target_option-} in \ + ?) ;; \ + *) echo "am__make_running_with_option: internal error: invalid" \ + "target option '$${target_option-}' specified" >&2; \ + exit 1;; \ + esac; \ + has_opt=no; \ + sane_makeflags=$$MAKEFLAGS; \ + if $(am__is_gnu_make); then \ + sane_makeflags=$$MFLAGS; \ + else \ + case $$MAKEFLAGS in \ + *\\[\ \ ]*) \ + bs=\\; \ + sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ + | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ + esac; \ + fi; \ + skip_next=no; \ + strip_trailopt () \ + { \ + flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ + }; \ + for flg in $$sane_makeflags; do \ + test $$skip_next = yes && { skip_next=no; continue; }; \ + case $$flg in \ + *=*|--*) continue;; \ + -*I) strip_trailopt 'I'; skip_next=yes;; \ + -*I?*) strip_trailopt 'I';; \ + -*O) strip_trailopt 'O'; skip_next=yes;; \ + -*O?*) strip_trailopt 'O';; \ + -*l) strip_trailopt 'l'; skip_next=yes;; \ + -*l?*) strip_trailopt 'l';; \ + -[dEDm]) skip_next=yes;; \ + -[JT]) skip_next=yes;; \ + esac; \ + case $$flg in \ + *$$target_option*) has_opt=yes; break;; \ + esac; \ + done; \ + test $$has_opt = yes +am__make_dryrun = (target_option=n; $(am__make_running_with_option)) +am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +noinst_PROGRAMS = demo_boxstack$(EXEEXT) demo_buggy$(EXEEXT) \ + demo_cards$(EXEEXT) demo_chain1$(EXEEXT) demo_chain2$(EXEEXT) \ + demo_collision$(EXEEXT) demo_convex$(EXEEXT) \ + demo_crash$(EXEEXT) demo_cylvssphere$(EXEEXT) \ + demo_dball$(EXEEXT) demo_dhinge$(EXEEXT) \ + demo_transmission$(EXEEXT) demo_feedback$(EXEEXT) \ + demo_friction$(EXEEXT) demo_gyroscopic$(EXEEXT) \ + demo_gyro2$(EXEEXT) demo_heightfield$(EXEEXT) \ + demo_hinge$(EXEEXT) demo_I$(EXEEXT) demo_jointPR$(EXEEXT) \ + demo_joints$(EXEEXT) demo_jointPU$(EXEEXT) \ + demo_kinematic$(EXEEXT) demo_motion$(EXEEXT) \ + demo_motor$(EXEEXT) demo_ode$(EXEEXT) demo_piston$(EXEEXT) \ + demo_plane2d$(EXEEXT) demo_rfriction$(EXEEXT) \ + demo_slider$(EXEEXT) demo_space$(EXEEXT) \ + demo_space_stress$(EXEEXT) demo_step$(EXEEXT) \ + demo_tracks$(EXEEXT) $(am__EXEEXT_1) +@TRIMESH_TRUE@am__append_1 = \ +@TRIMESH_TRUE@ demo_basket \ +@TRIMESH_TRUE@ demo_cyl \ +@TRIMESH_TRUE@ demo_moving_trimesh \ +@TRIMESH_TRUE@ demo_moving_convex \ +@TRIMESH_TRUE@ demo_trimesh + +@TRIMESH_TRUE@am__append_2 = -DdTRIMESH_ENABLED +@WIN32_TRUE@am__append_3 = resources.o +subdir = ode/demo +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ + $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ + $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ + $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +DIST_COMMON = $(srcdir)/Makefile.am $(noinst_HEADERS) \ + $(am__DIST_COMMON) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/ode/src/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +@TRIMESH_TRUE@am__EXEEXT_1 = demo_basket$(EXEEXT) demo_cyl$(EXEEXT) \ +@TRIMESH_TRUE@ demo_moving_trimesh$(EXEEXT) \ +@TRIMESH_TRUE@ demo_moving_convex$(EXEEXT) \ +@TRIMESH_TRUE@ demo_trimesh$(EXEEXT) +PROGRAMS = $(noinst_PROGRAMS) +demo_I_SOURCES = demo_I.cpp +demo_I_OBJECTS = demo_I.$(OBJEXT) +demo_I_LDADD = $(LDADD) +demo_I_DEPENDENCIES = $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = +demo_basket_SOURCES = demo_basket.cpp +demo_basket_OBJECTS = demo_basket.$(OBJEXT) +demo_basket_LDADD = $(LDADD) +demo_basket_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_boxstack_SOURCES = demo_boxstack.cpp +demo_boxstack_OBJECTS = demo_boxstack.$(OBJEXT) +demo_boxstack_LDADD = $(LDADD) +demo_boxstack_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_buggy_SOURCES = demo_buggy.cpp +demo_buggy_OBJECTS = demo_buggy.$(OBJEXT) +demo_buggy_LDADD = $(LDADD) +demo_buggy_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_cards_SOURCES = demo_cards.cpp +demo_cards_OBJECTS = demo_cards.$(OBJEXT) +demo_cards_LDADD = $(LDADD) +demo_cards_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +am_demo_chain1_OBJECTS = demo_chain1.$(OBJEXT) +demo_chain1_OBJECTS = $(am_demo_chain1_OBJECTS) +am__DEPENDENCIES_1 = $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_chain1_DEPENDENCIES = $(am__DEPENDENCIES_1) +demo_chain2_SOURCES = demo_chain2.cpp +demo_chain2_OBJECTS = demo_chain2.$(OBJEXT) +demo_chain2_LDADD = $(LDADD) +demo_chain2_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_collision_SOURCES = demo_collision.cpp +demo_collision_OBJECTS = demo_collision.$(OBJEXT) +demo_collision_LDADD = $(LDADD) +demo_collision_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_convex_SOURCES = demo_convex.cpp +demo_convex_OBJECTS = demo_convex.$(OBJEXT) +demo_convex_LDADD = $(LDADD) +demo_convex_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_crash_SOURCES = demo_crash.cpp +demo_crash_OBJECTS = demo_crash.$(OBJEXT) +demo_crash_LDADD = $(LDADD) +demo_crash_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_cyl_SOURCES = demo_cyl.cpp +demo_cyl_OBJECTS = demo_cyl.$(OBJEXT) +demo_cyl_LDADD = $(LDADD) +demo_cyl_DEPENDENCIES = $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_cylvssphere_SOURCES = demo_cylvssphere.cpp +demo_cylvssphere_OBJECTS = demo_cylvssphere.$(OBJEXT) +demo_cylvssphere_LDADD = $(LDADD) +demo_cylvssphere_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_dball_SOURCES = demo_dball.cpp +demo_dball_OBJECTS = demo_dball.$(OBJEXT) +demo_dball_LDADD = $(LDADD) +demo_dball_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_dhinge_SOURCES = demo_dhinge.cpp +demo_dhinge_OBJECTS = demo_dhinge.$(OBJEXT) +demo_dhinge_LDADD = $(LDADD) +demo_dhinge_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_feedback_SOURCES = demo_feedback.cpp +demo_feedback_OBJECTS = demo_feedback.$(OBJEXT) +demo_feedback_LDADD = $(LDADD) +demo_feedback_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_friction_SOURCES = demo_friction.cpp +demo_friction_OBJECTS = demo_friction.$(OBJEXT) +demo_friction_LDADD = $(LDADD) +demo_friction_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_gyro2_SOURCES = demo_gyro2.cpp +demo_gyro2_OBJECTS = demo_gyro2.$(OBJEXT) +demo_gyro2_LDADD = $(LDADD) +demo_gyro2_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_gyroscopic_SOURCES = demo_gyroscopic.cpp +demo_gyroscopic_OBJECTS = demo_gyroscopic.$(OBJEXT) +demo_gyroscopic_LDADD = $(LDADD) +demo_gyroscopic_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_heightfield_SOURCES = demo_heightfield.cpp +demo_heightfield_OBJECTS = demo_heightfield.$(OBJEXT) +demo_heightfield_LDADD = $(LDADD) +demo_heightfield_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_hinge_SOURCES = demo_hinge.cpp +demo_hinge_OBJECTS = demo_hinge.$(OBJEXT) +demo_hinge_LDADD = $(LDADD) +demo_hinge_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_jointPR_SOURCES = demo_jointPR.cpp +demo_jointPR_OBJECTS = demo_jointPR.$(OBJEXT) +demo_jointPR_LDADD = $(LDADD) +demo_jointPR_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_jointPU_SOURCES = demo_jointPU.cpp +demo_jointPU_OBJECTS = demo_jointPU.$(OBJEXT) +demo_jointPU_LDADD = $(LDADD) +demo_jointPU_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_joints_SOURCES = demo_joints.cpp +demo_joints_OBJECTS = demo_joints.$(OBJEXT) +demo_joints_LDADD = $(LDADD) +demo_joints_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_kinematic_SOURCES = demo_kinematic.cpp +demo_kinematic_OBJECTS = demo_kinematic.$(OBJEXT) +demo_kinematic_LDADD = $(LDADD) +demo_kinematic_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_motion_SOURCES = demo_motion.cpp +demo_motion_OBJECTS = demo_motion.$(OBJEXT) +demo_motion_LDADD = $(LDADD) +demo_motion_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_motor_SOURCES = demo_motor.cpp +demo_motor_OBJECTS = demo_motor.$(OBJEXT) +demo_motor_LDADD = $(LDADD) +demo_motor_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_moving_convex_SOURCES = demo_moving_convex.cpp +demo_moving_convex_OBJECTS = demo_moving_convex.$(OBJEXT) +demo_moving_convex_LDADD = $(LDADD) +demo_moving_convex_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_moving_trimesh_SOURCES = demo_moving_trimesh.cpp +demo_moving_trimesh_OBJECTS = demo_moving_trimesh.$(OBJEXT) +demo_moving_trimesh_LDADD = $(LDADD) +demo_moving_trimesh_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_ode_SOURCES = demo_ode.cpp +demo_ode_OBJECTS = demo_ode.$(OBJEXT) +demo_ode_LDADD = $(LDADD) +demo_ode_DEPENDENCIES = $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_piston_SOURCES = demo_piston.cpp +demo_piston_OBJECTS = demo_piston.$(OBJEXT) +demo_piston_LDADD = $(LDADD) +demo_piston_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_plane2d_SOURCES = demo_plane2d.cpp +demo_plane2d_OBJECTS = demo_plane2d.$(OBJEXT) +demo_plane2d_LDADD = $(LDADD) +demo_plane2d_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_rfriction_SOURCES = demo_rfriction.cpp +demo_rfriction_OBJECTS = demo_rfriction.$(OBJEXT) +demo_rfriction_LDADD = $(LDADD) +demo_rfriction_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_slider_SOURCES = demo_slider.cpp +demo_slider_OBJECTS = demo_slider.$(OBJEXT) +demo_slider_LDADD = $(LDADD) +demo_slider_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_space_SOURCES = demo_space.cpp +demo_space_OBJECTS = demo_space.$(OBJEXT) +demo_space_LDADD = $(LDADD) +demo_space_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_space_stress_SOURCES = demo_space_stress.cpp +demo_space_stress_OBJECTS = demo_space_stress.$(OBJEXT) +demo_space_stress_LDADD = $(LDADD) +demo_space_stress_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_step_SOURCES = demo_step.cpp +demo_step_OBJECTS = demo_step.$(OBJEXT) +demo_step_LDADD = $(LDADD) +demo_step_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_tracks_SOURCES = demo_tracks.cpp +demo_tracks_OBJECTS = demo_tracks.$(OBJEXT) +demo_tracks_LDADD = $(LDADD) +demo_tracks_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_transmission_SOURCES = demo_transmission.cpp +demo_transmission_OBJECTS = demo_transmission.$(OBJEXT) +demo_transmission_LDADD = $(LDADD) +demo_transmission_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +demo_trimesh_SOURCES = demo_trimesh.cpp +demo_trimesh_OBJECTS = demo_trimesh.$(OBJEXT) +demo_trimesh_LDADD = $(LDADD) +demo_trimesh_DEPENDENCIES = \ + $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la $(am__append_3) +AM_V_P = $(am__v_P_@AM_V@) +am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) +am__v_P_0 = false +am__v_P_1 = : +AM_V_GEN = $(am__v_GEN_@AM_V@) +am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) +am__v_GEN_0 = @echo " GEN " $@; +am__v_GEN_1 = +AM_V_at = $(am__v_at_@AM_V@) +am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) +am__v_at_0 = @ +am__v_at_1 = +DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/ode/src +depcomp = $(SHELL) $(top_srcdir)/depcomp +am__depfiles_maybe = depfiles +am__mv = mv -f +COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ + $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) +LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CFLAGS) $(CFLAGS) +AM_V_CC = $(am__v_CC_@AM_V@) +am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) +am__v_CC_0 = @echo " CC " $@; +am__v_CC_1 = +CCLD = $(CC) +LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CCLD = $(am__v_CCLD_@AM_V@) +am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) +am__v_CCLD_0 = @echo " CCLD " $@; +am__v_CCLD_1 = +CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ + $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) +LTCXXCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) \ + $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ + $(AM_CXXFLAGS) $(CXXFLAGS) +AM_V_CXX = $(am__v_CXX_@AM_V@) +am__v_CXX_ = $(am__v_CXX_@AM_DEFAULT_V@) +am__v_CXX_0 = @echo " CXX " $@; +am__v_CXX_1 = +CXXLD = $(CXX) +CXXLINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \ + $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ +AM_V_CXXLD = $(am__v_CXXLD_@AM_V@) +am__v_CXXLD_ = $(am__v_CXXLD_@AM_DEFAULT_V@) +am__v_CXXLD_0 = @echo " CXXLD " $@; +am__v_CXXLD_1 = +SOURCES = demo_I.cpp demo_basket.cpp demo_boxstack.cpp demo_buggy.cpp \ + demo_cards.cpp $(demo_chain1_SOURCES) demo_chain2.cpp \ + demo_collision.cpp demo_convex.cpp demo_crash.cpp demo_cyl.cpp \ + demo_cylvssphere.cpp demo_dball.cpp demo_dhinge.cpp \ + demo_feedback.cpp demo_friction.cpp demo_gyro2.cpp \ + demo_gyroscopic.cpp demo_heightfield.cpp demo_hinge.cpp \ + demo_jointPR.cpp demo_jointPU.cpp demo_joints.cpp \ + demo_kinematic.cpp demo_motion.cpp demo_motor.cpp \ + demo_moving_convex.cpp demo_moving_trimesh.cpp demo_ode.cpp \ + demo_piston.cpp demo_plane2d.cpp demo_rfriction.cpp \ + demo_slider.cpp demo_space.cpp demo_space_stress.cpp \ + demo_step.cpp demo_tracks.cpp demo_transmission.cpp \ + demo_trimesh.cpp +DIST_SOURCES = demo_I.cpp demo_basket.cpp demo_boxstack.cpp \ + demo_buggy.cpp demo_cards.cpp $(demo_chain1_SOURCES) \ + demo_chain2.cpp demo_collision.cpp demo_convex.cpp \ + demo_crash.cpp demo_cyl.cpp demo_cylvssphere.cpp \ + demo_dball.cpp demo_dhinge.cpp demo_feedback.cpp \ + demo_friction.cpp demo_gyro2.cpp demo_gyroscopic.cpp \ + demo_heightfield.cpp demo_hinge.cpp demo_jointPR.cpp \ + demo_jointPU.cpp demo_joints.cpp demo_kinematic.cpp \ + demo_motion.cpp demo_motor.cpp demo_moving_convex.cpp \ + demo_moving_trimesh.cpp demo_ode.cpp demo_piston.cpp \ + demo_plane2d.cpp demo_rfriction.cpp demo_slider.cpp \ + demo_space.cpp demo_space_stress.cpp demo_step.cpp \ + demo_tracks.cpp demo_transmission.cpp demo_trimesh.cpp +am__can_run_installinfo = \ + case $$AM_UPDATE_INFO_DIR in \ + n|no|NO) false;; \ + *) (install-info --version) >/dev/null 2>&1;; \ + esac +HEADERS = $(noinst_HEADERS) +am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) +# Read a list of newline-separated strings from the standard input, +# and print each of them once, without duplicates. Input order is +# *not* preserved. +am__uniquify_input = $(AWK) '\ + BEGIN { nonempty = 0; } \ + { items[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in items) print i; }; } \ +' +# Make sure the list of sources is unique. This is necessary because, +# e.g., the same source file might be shared among _SOURCES variables +# for different programs/libraries. +am__define_uniq_tagged_files = \ + list='$(am__tagged_files)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | $(am__uniquify_input)` +ETAGS = etags +CTAGS = ctags +am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +ALLOCA = @ALLOCA@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +AR = @AR@ +AS = @AS@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CCD_CFLAGS = @CCD_CFLAGS@ +CCD_LIBS = @CCD_LIBS@ +CFLAGS = @CFLAGS@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DOXYGEN = @DOXYGEN@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +EXEEXT = @EXEEXT@ +EXTRA_LIBTOOL_LDFLAGS = @EXTRA_LIBTOOL_LDFLAGS@ +FGREP = @FGREP@ +GL_LIBS = @GL_LIBS@ +GREP = @GREP@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBSTDCXX = @LIBSTDCXX@ +LIBTOOL = @LIBTOOL@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ +MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ +MKDIR_P = @MKDIR_P@ +NM = @NM@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +ODE_PRECISION = @ODE_PRECISION@ +ODE_VERSION = @ODE_VERSION@ +ODE_VERSION_INFO = @ODE_VERSION_INFO@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +WINDRES = @WINDRES@ +X11_CFLAGS = @X11_CFLAGS@ +X11_LIBS = @X11_LIBS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_WINDRES = @ac_ct_WINDRES@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +runstatedir = @runstatedir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +subdirs = @subdirs@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +AM_CPPFLAGS = -I$(top_srcdir)/include -I$(top_builddir)/include \ + -DDRAWSTUFF_TEXTURE_PATH="\"$(abs_top_srcdir)/drawstuff/textures\"" \ + $(am__append_2) +@X11_TRUE@AM_LDFLAGS = $(X_PRE_LIBS) $(X_LIBS) $(X_EXTRA_LIBS) + +# On Windows, GL_LIBS must go after libdrawstuff.la. +LDADD = $(top_builddir)/drawstuff/src/libdrawstuff.la \ + $(top_builddir)/ode/src/libode.la @GL_LIBS@ $(am__append_3) +noinst_HEADERS = basket_geom.h bunny_geom.h convex_bunny_geom.h convex_prism.h \ + icosahedron_geom.h halton235_geom.h texturepath.h world_geom3.h + +AM_DEFAULT_SOURCE_EXT = .cpp +demo_chain1_SOURCES = demo_chain1.c +demo_chain1_LDADD = $(LDADD) -lstdc++ +all: all-am + +.SUFFIXES: +.SUFFIXES: .c .cpp .lo .o .obj +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign ode/demo/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign ode/demo/Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): + +clean-noinstPROGRAMS: + @list='$(noinst_PROGRAMS)'; test -n "$$list" || exit 0; \ + echo " rm -f" $$list; \ + rm -f $$list || exit $$?; \ + test -n "$(EXEEXT)" || exit 0; \ + list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ + echo " rm -f" $$list; \ + rm -f $$list + +demo_I$(EXEEXT): $(demo_I_OBJECTS) $(demo_I_DEPENDENCIES) $(EXTRA_demo_I_DEPENDENCIES) + @rm -f demo_I$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_I_OBJECTS) $(demo_I_LDADD) $(LIBS) + +demo_basket$(EXEEXT): $(demo_basket_OBJECTS) $(demo_basket_DEPENDENCIES) $(EXTRA_demo_basket_DEPENDENCIES) + @rm -f demo_basket$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_basket_OBJECTS) $(demo_basket_LDADD) $(LIBS) + +demo_boxstack$(EXEEXT): $(demo_boxstack_OBJECTS) $(demo_boxstack_DEPENDENCIES) $(EXTRA_demo_boxstack_DEPENDENCIES) + @rm -f demo_boxstack$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_boxstack_OBJECTS) $(demo_boxstack_LDADD) $(LIBS) + +demo_buggy$(EXEEXT): $(demo_buggy_OBJECTS) $(demo_buggy_DEPENDENCIES) $(EXTRA_demo_buggy_DEPENDENCIES) + @rm -f demo_buggy$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_buggy_OBJECTS) $(demo_buggy_LDADD) $(LIBS) + +demo_cards$(EXEEXT): $(demo_cards_OBJECTS) $(demo_cards_DEPENDENCIES) $(EXTRA_demo_cards_DEPENDENCIES) + @rm -f demo_cards$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_cards_OBJECTS) $(demo_cards_LDADD) $(LIBS) + +demo_chain1$(EXEEXT): $(demo_chain1_OBJECTS) $(demo_chain1_DEPENDENCIES) $(EXTRA_demo_chain1_DEPENDENCIES) + @rm -f demo_chain1$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(demo_chain1_OBJECTS) $(demo_chain1_LDADD) $(LIBS) + +demo_chain2$(EXEEXT): $(demo_chain2_OBJECTS) $(demo_chain2_DEPENDENCIES) $(EXTRA_demo_chain2_DEPENDENCIES) + @rm -f demo_chain2$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_chain2_OBJECTS) $(demo_chain2_LDADD) $(LIBS) + +demo_collision$(EXEEXT): $(demo_collision_OBJECTS) $(demo_collision_DEPENDENCIES) $(EXTRA_demo_collision_DEPENDENCIES) + @rm -f demo_collision$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_collision_OBJECTS) $(demo_collision_LDADD) $(LIBS) + +demo_convex$(EXEEXT): $(demo_convex_OBJECTS) $(demo_convex_DEPENDENCIES) $(EXTRA_demo_convex_DEPENDENCIES) + @rm -f demo_convex$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_convex_OBJECTS) $(demo_convex_LDADD) $(LIBS) + +demo_crash$(EXEEXT): $(demo_crash_OBJECTS) $(demo_crash_DEPENDENCIES) $(EXTRA_demo_crash_DEPENDENCIES) + @rm -f demo_crash$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_crash_OBJECTS) $(demo_crash_LDADD) $(LIBS) + +demo_cyl$(EXEEXT): $(demo_cyl_OBJECTS) $(demo_cyl_DEPENDENCIES) $(EXTRA_demo_cyl_DEPENDENCIES) + @rm -f demo_cyl$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_cyl_OBJECTS) $(demo_cyl_LDADD) $(LIBS) + +demo_cylvssphere$(EXEEXT): $(demo_cylvssphere_OBJECTS) $(demo_cylvssphere_DEPENDENCIES) $(EXTRA_demo_cylvssphere_DEPENDENCIES) + @rm -f demo_cylvssphere$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_cylvssphere_OBJECTS) $(demo_cylvssphere_LDADD) $(LIBS) + +demo_dball$(EXEEXT): $(demo_dball_OBJECTS) $(demo_dball_DEPENDENCIES) $(EXTRA_demo_dball_DEPENDENCIES) + @rm -f demo_dball$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_dball_OBJECTS) $(demo_dball_LDADD) $(LIBS) + +demo_dhinge$(EXEEXT): $(demo_dhinge_OBJECTS) $(demo_dhinge_DEPENDENCIES) $(EXTRA_demo_dhinge_DEPENDENCIES) + @rm -f demo_dhinge$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_dhinge_OBJECTS) $(demo_dhinge_LDADD) $(LIBS) + +demo_feedback$(EXEEXT): $(demo_feedback_OBJECTS) $(demo_feedback_DEPENDENCIES) $(EXTRA_demo_feedback_DEPENDENCIES) + @rm -f demo_feedback$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_feedback_OBJECTS) $(demo_feedback_LDADD) $(LIBS) + +demo_friction$(EXEEXT): $(demo_friction_OBJECTS) $(demo_friction_DEPENDENCIES) $(EXTRA_demo_friction_DEPENDENCIES) + @rm -f demo_friction$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_friction_OBJECTS) $(demo_friction_LDADD) $(LIBS) + +demo_gyro2$(EXEEXT): $(demo_gyro2_OBJECTS) $(demo_gyro2_DEPENDENCIES) $(EXTRA_demo_gyro2_DEPENDENCIES) + @rm -f demo_gyro2$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_gyro2_OBJECTS) $(demo_gyro2_LDADD) $(LIBS) + +demo_gyroscopic$(EXEEXT): $(demo_gyroscopic_OBJECTS) $(demo_gyroscopic_DEPENDENCIES) $(EXTRA_demo_gyroscopic_DEPENDENCIES) + @rm -f demo_gyroscopic$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_gyroscopic_OBJECTS) $(demo_gyroscopic_LDADD) $(LIBS) + +demo_heightfield$(EXEEXT): $(demo_heightfield_OBJECTS) $(demo_heightfield_DEPENDENCIES) $(EXTRA_demo_heightfield_DEPENDENCIES) + @rm -f demo_heightfield$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_heightfield_OBJECTS) $(demo_heightfield_LDADD) $(LIBS) + +demo_hinge$(EXEEXT): $(demo_hinge_OBJECTS) $(demo_hinge_DEPENDENCIES) $(EXTRA_demo_hinge_DEPENDENCIES) + @rm -f demo_hinge$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_hinge_OBJECTS) $(demo_hinge_LDADD) $(LIBS) + +demo_jointPR$(EXEEXT): $(demo_jointPR_OBJECTS) $(demo_jointPR_DEPENDENCIES) $(EXTRA_demo_jointPR_DEPENDENCIES) + @rm -f demo_jointPR$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_jointPR_OBJECTS) $(demo_jointPR_LDADD) $(LIBS) + +demo_jointPU$(EXEEXT): $(demo_jointPU_OBJECTS) $(demo_jointPU_DEPENDENCIES) $(EXTRA_demo_jointPU_DEPENDENCIES) + @rm -f demo_jointPU$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_jointPU_OBJECTS) $(demo_jointPU_LDADD) $(LIBS) + +demo_joints$(EXEEXT): $(demo_joints_OBJECTS) $(demo_joints_DEPENDENCIES) $(EXTRA_demo_joints_DEPENDENCIES) + @rm -f demo_joints$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_joints_OBJECTS) $(demo_joints_LDADD) $(LIBS) + +demo_kinematic$(EXEEXT): $(demo_kinematic_OBJECTS) $(demo_kinematic_DEPENDENCIES) $(EXTRA_demo_kinematic_DEPENDENCIES) + @rm -f demo_kinematic$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_kinematic_OBJECTS) $(demo_kinematic_LDADD) $(LIBS) + +demo_motion$(EXEEXT): $(demo_motion_OBJECTS) $(demo_motion_DEPENDENCIES) $(EXTRA_demo_motion_DEPENDENCIES) + @rm -f demo_motion$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_motion_OBJECTS) $(demo_motion_LDADD) $(LIBS) + +demo_motor$(EXEEXT): $(demo_motor_OBJECTS) $(demo_motor_DEPENDENCIES) $(EXTRA_demo_motor_DEPENDENCIES) + @rm -f demo_motor$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_motor_OBJECTS) $(demo_motor_LDADD) $(LIBS) + +demo_moving_convex$(EXEEXT): $(demo_moving_convex_OBJECTS) $(demo_moving_convex_DEPENDENCIES) $(EXTRA_demo_moving_convex_DEPENDENCIES) + @rm -f demo_moving_convex$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_moving_convex_OBJECTS) $(demo_moving_convex_LDADD) $(LIBS) + +demo_moving_trimesh$(EXEEXT): $(demo_moving_trimesh_OBJECTS) $(demo_moving_trimesh_DEPENDENCIES) $(EXTRA_demo_moving_trimesh_DEPENDENCIES) + @rm -f demo_moving_trimesh$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_moving_trimesh_OBJECTS) $(demo_moving_trimesh_LDADD) $(LIBS) + +demo_ode$(EXEEXT): $(demo_ode_OBJECTS) $(demo_ode_DEPENDENCIES) $(EXTRA_demo_ode_DEPENDENCIES) + @rm -f demo_ode$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_ode_OBJECTS) $(demo_ode_LDADD) $(LIBS) + +demo_piston$(EXEEXT): $(demo_piston_OBJECTS) $(demo_piston_DEPENDENCIES) $(EXTRA_demo_piston_DEPENDENCIES) + @rm -f demo_piston$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_piston_OBJECTS) $(demo_piston_LDADD) $(LIBS) + +demo_plane2d$(EXEEXT): $(demo_plane2d_OBJECTS) $(demo_plane2d_DEPENDENCIES) $(EXTRA_demo_plane2d_DEPENDENCIES) + @rm -f demo_plane2d$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_plane2d_OBJECTS) $(demo_plane2d_LDADD) $(LIBS) + +demo_rfriction$(EXEEXT): $(demo_rfriction_OBJECTS) $(demo_rfriction_DEPENDENCIES) $(EXTRA_demo_rfriction_DEPENDENCIES) + @rm -f demo_rfriction$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_rfriction_OBJECTS) $(demo_rfriction_LDADD) $(LIBS) + +demo_slider$(EXEEXT): $(demo_slider_OBJECTS) $(demo_slider_DEPENDENCIES) $(EXTRA_demo_slider_DEPENDENCIES) + @rm -f demo_slider$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_slider_OBJECTS) $(demo_slider_LDADD) $(LIBS) + +demo_space$(EXEEXT): $(demo_space_OBJECTS) $(demo_space_DEPENDENCIES) $(EXTRA_demo_space_DEPENDENCIES) + @rm -f demo_space$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_space_OBJECTS) $(demo_space_LDADD) $(LIBS) + +demo_space_stress$(EXEEXT): $(demo_space_stress_OBJECTS) $(demo_space_stress_DEPENDENCIES) $(EXTRA_demo_space_stress_DEPENDENCIES) + @rm -f demo_space_stress$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_space_stress_OBJECTS) $(demo_space_stress_LDADD) $(LIBS) + +demo_step$(EXEEXT): $(demo_step_OBJECTS) $(demo_step_DEPENDENCIES) $(EXTRA_demo_step_DEPENDENCIES) + @rm -f demo_step$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_step_OBJECTS) $(demo_step_LDADD) $(LIBS) + +demo_tracks$(EXEEXT): $(demo_tracks_OBJECTS) $(demo_tracks_DEPENDENCIES) $(EXTRA_demo_tracks_DEPENDENCIES) + @rm -f demo_tracks$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_tracks_OBJECTS) $(demo_tracks_LDADD) $(LIBS) + +demo_transmission$(EXEEXT): $(demo_transmission_OBJECTS) $(demo_transmission_DEPENDENCIES) $(EXTRA_demo_transmission_DEPENDENCIES) + @rm -f demo_transmission$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_transmission_OBJECTS) $(demo_transmission_LDADD) $(LIBS) + +demo_trimesh$(EXEEXT): $(demo_trimesh_OBJECTS) $(demo_trimesh_DEPENDENCIES) $(EXTRA_demo_trimesh_DEPENDENCIES) + @rm -f demo_trimesh$(EXEEXT) + $(AM_V_CXXLD)$(CXXLINK) $(demo_trimesh_OBJECTS) $(demo_trimesh_LDADD) $(LIBS) + +mostlyclean-compile: + -rm -f *.$(OBJEXT) + +distclean-compile: + -rm -f *.tab.c + +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_I.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_basket.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_boxstack.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_buggy.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_cards.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_chain1.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_chain2.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_collision.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_convex.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_crash.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_cyl.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_cylvssphere.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_dball.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_dhinge.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_feedback.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_friction.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_gyro2.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_gyroscopic.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_heightfield.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_hinge.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_jointPR.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_jointPU.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_joints.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_kinematic.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_motion.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_motor.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_moving_convex.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_moving_trimesh.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_ode.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_piston.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_plane2d.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_rfriction.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_slider.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_space.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_space_stress.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_step.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_tracks.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_transmission.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/demo_trimesh.Po@am__quote@ + +.c.o: +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< + +.c.obj: +@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` + +.c.lo: +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< + +.cpp.o: +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ $< + +.cpp.obj: +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'` + +.cpp.lo: +@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LTCXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< +@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LTCXXCOMPILE) -c -o $@ $< + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +ID: $(am__tagged_files) + $(am__define_uniq_tagged_files); mkid -fID $$unique +tags: tags-am +TAGS: tags + +tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + set x; \ + here=`pwd`; \ + $(am__define_uniq_tagged_files); \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: ctags-am + +CTAGS: ctags +ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) + $(am__define_uniq_tagged_files); \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" +cscopelist: cscopelist-am + +cscopelist-am: $(am__tagged_files) + list='$(am__tagged_files)'; \ + case "$(srcdir)" in \ + [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ + *) sdir=$(subdir)/$(srcdir) ;; \ + esac; \ + for i in $$list; do \ + if test -f "$$i"; then \ + echo "$(subdir)/$$i"; \ + else \ + echo "$$sdir/$$i"; \ + fi; \ + done >> $(top_builddir)/cscope.files + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(PROGRAMS) $(HEADERS) +installdirs: +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + if test -z '$(STRIP)'; then \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + install; \ + else \ + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ + fi +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-generic clean-libtool clean-noinstPROGRAMS \ + mostlyclean-am + +distclean: distclean-am + -rm -rf ./$(DEPDIR) + -rm -f Makefile +distclean-am: clean-am distclean-compile distclean-generic \ + distclean-tags + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -rf ./$(DEPDIR) + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-compile mostlyclean-generic \ + mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: + +.MAKE: install-am install-strip + +.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ + clean-libtool clean-noinstPROGRAMS cscopelist-am ctags \ + ctags-am distclean distclean-compile distclean-generic \ + distclean-libtool distclean-tags distdir dvi dvi-am html \ + html-am info info-am install install-am install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am install-info \ + install-info-am install-man install-pdf install-pdf-am \ + install-ps install-ps-am install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-am uninstall uninstall-am + +.PRECIOUS: Makefile + + +@WIN32_TRUE@resources.o: $(top_srcdir)/drawstuff/src/resources.rc $(top_srcdir)/drawstuff/src/resource.h +@WIN32_TRUE@ @WINDRES@ $(top_srcdir)/drawstuff/src/resources.rc -o resources.o + +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/libs/ode-0.16.1/ode/demo/basket_geom.h b/libs/ode-0.16.1/ode/demo/basket_geom.h new file mode 100644 index 0000000..ec88327 --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/basket_geom.h @@ -0,0 +1,599 @@ + +static float world_normals[] = { + 0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,-0,0,1,0,0,1,0,0,1,0,0,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,-0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,1,0,-0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,0,-0.948064f,0.318080f,0,-0.989482f,0.144655f,0,-0.983494f,0.180939f,0,-0.983494f,0.180939f,0,-0.908999f,0.416798f,0,-0.948064f,0.318080f,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,-1,0,-0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,-0.132460f,0.991188f,0,0.264920f,0.964270f,0,0.132460f,0.991188f,0,0.132460f,0.991188f,0,-0.264920f,0.964270f,0,-0.132460f,0.991188f,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,-0.687592f,-0.726097f,-0,-0.881727f,-0.471761f,0,-0.687592f,-0.726097f,-0,-0.881727f,-0.471761f,0,-0.881727f,-0.471761f,0,-0.687592f,-0.726097f,-0,0.687592f,-0.726097f,0,0.928375f,-0.371644f,0,0.824321f,-0.566123f,0,0.687592f,-0.726097f,0,0.824321f,-0.566123f,0,0.687592f,-0.726097f,0,-0.881727f,-0.471761f,0,-0.985594f,-0.169128f,0,-0.985594f,-0.169128f,0,-0.985594f,-0.169128f,0,-0.881727f,-0.471761f,0,-0.881727f,-0.471761f,0,0.928375f,-0.371644f,0,0.985594f,-0.169128f,0,0.985594f,-0.169128f,0,0.928375f,-0.371644f,0,0.985594f,-0.169128f,0,0.824321f,-0.566123f,0,-0.870167f,0.492758f,0,-0.870167f,0.492758f,0,-0.870167f,0.492758f,0,-0.870167f,0.492758f,0,-0.870167f,0.492758f,0,-0.870167f,0.492758f,0,0.870167f,0.492758f,0,0.870167f,0.492758f,0,0.870167f,0.492758f,0,0.870167f,0.492758f,0,0.870167f,0.492758f,0,0.870167f,0.492758f,-0,-0.390313f,0.920682f,0,-0.132460f,0.991188f,0,-0.264920f,0.964270f,0,-0.264920f,0.964270f,0,-0.390313f,0.920682f,0,-0.390313f,0.920682f,0,0.390313f,0.920682f,0,0.132460f,0.991188f,0,0.264920f,0.964270f,0,0.390313f,0.920682f,0,0.264920f,0.964270f,0,0.390313f,0.920682f,-0,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0.985594f,0.169128f,0,0.824321f,0.566123f,0,0.928375f,0.371644f,0,0.928375f,0.371644f,0,0.985594f,0.169128f,0,0.985594f,0.169128f,0,0.824321f,0.566123f,0,0.687592f,0.726097f,0,0.687592f,0.726097f,0,0.687592f,0.726097f,0,0.928375f,0.371644f,0,0.824321f,0.566123f,0,0,1,0,-0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,-0.687592f,0.726097f,0,-0.687592f,0.726097f,0,-0.881727f,0.471761f,0,-0.881727f,0.471761f,0,-0.881727f,0.471761f,0,-0.687592f,0.726097f,0,-0.881727f,0.471761f,0,-0.985594f,0.169128f,0,-0.985594f,0.169128f,0,-0.985594f,0.169128f,0,-0.881727f,0.471761f,0,-0.881727f,0.471761f,0,-0.870166f,-0.492758f,0,-0.870166f,-0.492758f,0,-0.870166f,-0.492758f,0,-0.870166f,-0.492758f,0,-0.870166f,-0.492758f,0,-0.870166f,-0.492758f,0,-0.390314f,-0.920682f,0,-0.132460f,-0.991188f,0,-0.264921f,-0.964270f,0,-0.264921f,-0.964270f,0,-0.390314f,-0.920682f,0,-0.390314f,-0.920682f,0,-0.132460f,-0.991188f,0,0.264921f,-0.964270f,0,0.132460f,-0.991188f,0,0.132460f,-0.991188f,0,-0.264921f,-0.964270f,0,-0.132460f,-0.991188f,0,0.264921f,-0.964270f,0,0.390314f,-0.920682f,0,0.390314f,-0.920682f,0,0.390314f,-0.920682f,0,0.132460f,-0.991188f,0,0.264921f,-0.964270f,0,0.870166f,-0.492758f,0,0.870166f,-0.492758f,0,0.870166f,-0.492758f,0,0.870166f,-0.492758f,0,0.870166f,-0.492758f,0,0.870166f,-0.492758f,0,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,-0.527606f,0.849489f,0,-0.793893f,0.608057f,0,-0.715135f,0.698986f,0,-0.715135f,0.698986f,0,-0.418249f,0.908332f,0,-0.527606f,0.849489f,0,-0.075284f,0.997162f,0,-0.253577f,0.967315f,0,-0.202069f,0.979371f,0,-0.202069f,0.979371f,0,-0.075284f,0.997162f,0,-0.075284f,0.997162f,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0.160137f,0.987095f,0,0.049305f,0.998784f,0,0.049305f,0.998784f,0,0.049305f,0.998784f,0,0.221401f,0.975183f,0,0.160137f,0.987095f,0,0.696124f,0.717921f,0,0.696124f,0.717921f,0,0.433340f,0.901230f,0,0.433340f,0.901230f,0,0.433340f,0.901230f,0,0.696124f,0.717921f,0,0.696124f,0.717921f,0,0.696124f,0.717921f,0,0.838308f,0.545197f,0,0.696124f,0.717921f,0,0.872167f,0.489208f,0,0.838308f,0.545197f,0,-0.994126f,0.108225f,0,-0.983494f,0.180939f,0,-0.989482f,0.144655f,0,-0.994126f,0.108225f,0,-0.989482f,0.144655f,0,-0.994126f,0.108225f,0,-0.948064f,0.318080f,0,-0.908999f,0.416798f,0,-0.793893f,0.608057f,0,-0.908999f,0.416798f,0,-0.715135f,0.698986f,0,-0.793893f,0.608057f,0,-0.527606f,0.849489f,0,-0.418249f,0.908332f,0,-0.253577f,0.967315f,0,-0.418249f,0.908332f,0,-0.202069f,0.979371f,0,-0.253577f,0.967315f,0,-0.075284f,0.997162f,0,-0.075284f,0.997162f,0,0,1,0,-0.075284f,0.997162f,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0.049305f,0.998784f,0,0,1,0,0.049305f,0.998784f,0,0.049305f,0.998784f,0,0.160137f,0.987095f,0,0.221401f,0.975183f,0,0.433340f,0.901230f,0,0.221401f,0.975183f,0,0.433340f,0.901230f,0,0.433340f,0.901230f,0,0.902172f,0.431376f,0,0.838308f,0.545197f,0,0.872167f,0.489208f,0,0.872167f,0.489208f,0,0.902172f,0.431376f,0,0.902172f,0.431376f, +}; + +static float world_vertices[] = { + -4,-4,-0.100000f, + 4,-4,-0.100000f, + 4,-4,0.100000f, + -4,-4,0.100000f, + 4,0,0.100000f, + 4,4,-0.100000f, + 4,4,0.100000f, + -4,4,-0.100000f, + 0.066000f,-2.060000f,2, + 0.066000f,-1.940000f,2, + -0.066000f,-2.060000f,2, + -0.066000f,-1.940000f,2, + -4,4,0.100000f, + -4,0,0.100000f, + 0.360000f,3.244444f,1.466974f, + 0.360000f,3.422222f,2.266974f, + -0.360000f,3.422222f,2.266974f, + -0.360000f,3.244444f,1.466974f, + 0.066000f,-2.060000f,0.100000f, + -0.066000f,-2.060000f,0.100000f, + 0.066000f,-1.940000f,0.100000f, + -0.066000f,-1.940000f,0.100000f, + 0.066000f,-1.940000f,1.950000f, + -0.052853f,-1.506390f,2, + 0.052853f,-1.506390f,2, + 0.052853f,-1.506390f,1.950000f, + -0.052853f,-1.506390f,1.950000f, + -0.066000f,-1.940000f,1.950000f, + -0.066000f,-1.840000f,1.950000f, + 0.066000f,-1.840000f,1.950000f, + -0.066000f,-1.840000f,2, + 0.066000f,-1.840000f,2, + -0.171600f,-1.740000f,2, + -0.171600f,-1.740000f,1.950000f, + 0.171600f,-1.740000f,1.950000f, + 0.171600f,-1.740000f,2, + -0.188760f,-1.640000f,2, + -0.188760f,-1.640000f,1.950000f, + 0.188760f,-1.640000f,1.950000f, + 0.188760f,-1.640000f,2, + -0.132132f,-1.540000f,2, + -0.132132f,-1.540000f,1.950000f, + 0.132132f,-1.540000f,1.950000f, + 0.132132f,-1.540000f,2, + 0.173397f,-1.642679f,1.950000f, + 0.121808f,-1.551577f,1.950000f, + 0.157950f,-1.732697f,1.950000f, + 0.060149f,-1.825311f,1.950000f, + -0.060149f,-1.825311f,1.950000f, + -0.157950f,-1.732697f,1.950000f, + -0.173397f,-1.642679f,1.950000f, + -0.121808f,-1.551577f,1.950000f, + -0.049868f,-1.521079f,1.950000f, + 0.049868f,-1.521079f,1.950000f, + -0.173397f,-1.642679f,2, + -0.121808f,-1.551577f,2, + -0.157950f,-1.732697f,2, + -0.060149f,-1.825311f,2, + 0.060149f,-1.825311f,2, + 0.157950f,-1.732697f,2, + 0.173397f,-1.642679f,2, + 0.121808f,-1.551577f,2, + 0.049868f,-1.521079f,2, + -0.049868f,-1.521079f,2, + -0.360000f,3.600000f,0.100000f, + 0.360000f,3.600000f,0.100000f, + -0.360000f,0.400000f,0.100000f, + 0.360000f,0.400000f,0.100000f, + 0.360000f,2.888889f,1.023752f, + 0.360000f,3.066667f,1.166974f, + -0.360000f,3.066667f,1.166974f, + -0.360000f,2.888889f,1.023752f, + 0.360000f,2.533333f,0.939976f, + 0.360000f,2.711111f,0.966974f, + -0.360000f,2.711111f,0.966974f, + -0.360000f,2.533333f,0.939976f, + -0.360000f,2.177778f,0.939976f, + 0.360000f,2.177778f,0.939976f, + 0.360000f,2.355556f,0.939976f, + -0.360000f,2.355556f,0.939976f, + -0.360000f,1.822222f,0.939976f, + 0.360000f,1.822222f,0.939976f, + 0.360000f,2,0.939976f, + -0.360000f,2,0.939976f, + -0.360000f,1.466667f,0.939976f, + 0.360000f,1.466667f,0.939976f, + 0.360000f,1.644444f,0.939976f, + -0.360000f,1.644444f,0.939976f, + 0.360000f,1.111111f,0.957571f, + 0.360000f,1.288889f,0.939976f, + -0.360000f,1.288889f,0.939976f, + -0.360000f,1.111111f,0.957571f, + -0.360000f,0.755556f,1.134246f, + 0.360000f,0.755556f,1.134246f, + 0.360000f,0.933333f,1.009739f, + -0.360000f,0.933333f,1.009739f, + 0.360000f,0.577778f,1.372130f, + -0.360000f,0.577778f,1.372130f, + -0.360000f,3.600000f,3.900000f, + 0.360000f,3.600000f,3.900000f, + 0.360000f,0.400000f,1.743932f, + -0.360000f,0.400000f,1.743932f, +}; + +static dTriIndex world_indices[] = { + 0, + 1, + 2, + 0, + 2, + 3, + 4, + 1, + 5, + 4, + 5, + 6, + 4, + 2, + 1, + 0, + 7, + 5, + 0, + 5, + 1, + 8, + 9, + 10, + 9, + 11, + 10, + 12, + 6, + 5, + 5, + 7, + 12, + 3, + 13, + 0, + 13, + 12, + 7, + 13, + 7, + 0, + 14, + 15, + 16, + 16, + 17, + 14, + 2, + 18, + 19, + 19, + 3, + 2, + 4, + 20, + 2, + 20, + 18, + 2, + 21, + 20, + 4, + 4, + 13, + 21, + 19, + 21, + 13, + 13, + 3, + 19, + 8, + 10, + 19, + 19, + 18, + 8, + 22, + 9, + 8, + 8, + 18, + 22, + 18, + 20, + 22, + 23, + 24, + 25, + 25, + 26, + 23, + 19, + 10, + 27, + 19, + 27, + 21, + 10, + 11, + 27, + 21, + 27, + 22, + 21, + 22, + 20, + 27, + 28, + 22, + 28, + 29, + 22, + 11, + 30, + 28, + 28, + 27, + 11, + 9, + 31, + 11, + 31, + 30, + 11, + 22, + 29, + 31, + 22, + 31, + 9, + 30, + 32, + 28, + 32, + 33, + 28, + 29, + 34, + 35, + 29, + 35, + 31, + 32, + 36, + 37, + 37, + 33, + 32, + 34, + 38, + 39, + 34, + 39, + 35, + 36, + 40, + 41, + 41, + 37, + 36, + 38, + 42, + 43, + 38, + 43, + 39, + 40, + 23, + 26, + 26, + 41, + 40, + 42, + 25, + 24, + 42, + 24, + 43, + 38, + 44, + 45, + 45, + 42, + 38, + 34, + 46, + 44, + 34, + 44, + 38, + 34, + 29, + 47, + 34, + 47, + 46, + 28, + 48, + 29, + 48, + 47, + 29, + 33, + 49, + 48, + 33, + 48, + 28, + 50, + 49, + 33, + 33, + 37, + 50, + 51, + 50, + 37, + 37, + 41, + 51, + 26, + 52, + 51, + 26, + 51, + 41, + 53, + 52, + 26, + 26, + 25, + 53, + 25, + 42, + 45, + 25, + 45, + 53, + 36, + 54, + 55, + 55, + 40, + 36, + 32, + 56, + 54, + 54, + 36, + 32, + 30, + 57, + 32, + 57, + 56, + 32, + 31, + 58, + 30, + 58, + 57, + 30, + 35, + 59, + 58, + 35, + 58, + 31, + 60, + 59, + 35, + 35, + 39, + 60, + 61, + 60, + 39, + 39, + 43, + 61, + 24, + 62, + 61, + 24, + 61, + 43, + 63, + 62, + 24, + 24, + 23, + 63, + 55, + 63, + 23, + 23, + 40, + 55, + 54, + 56, + 49, + 49, + 50, + 54, + 56, + 57, + 48, + 48, + 49, + 56, + 57, + 58, + 47, + 47, + 48, + 57, + 47, + 58, + 59, + 59, + 46, + 47, + 59, + 60, + 44, + 44, + 46, + 59, + 60, + 61, + 45, + 45, + 44, + 60, + 61, + 62, + 53, + 53, + 45, + 61, + 62, + 63, + 52, + 52, + 53, + 62, + 63, + 55, + 51, + 51, + 52, + 63, + 55, + 54, + 50, + 50, + 51, + 55, + 64, + 65, + 6, + 6, + 12, + 64, + 66, + 64, + 12, + 12, + 13, + 66, + 4, + 67, + 66, + 66, + 13, + 4, + 6, + 65, + 4, + 65, + 67, + 4, + 68, + 69, + 70, + 70, + 71, + 68, + 72, + 73, + 74, + 74, + 75, + 72, + 76, + 77, + 78, + 78, + 79, + 76, + 80, + 81, + 82, + 82, + 83, + 80, + 84, + 85, + 86, + 86, + 87, + 84, + 88, + 89, + 90, + 90, + 91, + 88, + 92, + 93, + 94, + 94, + 95, + 92, + 93, + 92, + 96, + 92, + 97, + 96, + 98, + 16, + 15, + 98, + 15, + 99, + 14, + 17, + 69, + 17, + 70, + 69, + 68, + 71, + 73, + 71, + 74, + 73, + 72, + 75, + 79, + 72, + 79, + 78, + 77, + 76, + 83, + 77, + 83, + 82, + 81, + 80, + 87, + 81, + 87, + 86, + 85, + 84, + 90, + 85, + 90, + 89, + 88, + 91, + 94, + 91, + 95, + 94, + 100, + 96, + 97, + 97, + 101, + 100, +}; + diff --git a/libs/ode-0.16.1/ode/demo/bunny_geom.h b/libs/ode-0.16.1/ode/demo/bunny_geom.h new file mode 100644 index 0000000..78f8eb0 --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/bunny_geom.h @@ -0,0 +1,1366 @@ +// Bunny mesh ripped from Opcode +const int VertexCount = 453; +const int IndexCount = 902 * 3; + + +float Vertices[VertexCount * 3] = { + -0.334392f, 0.133007f, 0.062259f, + -0.350189f, 0.150354f, -0.147769f, + -0.234201f, 0.343811f, -0.174307f, + -0.200259f, 0.285207f, 0.093749f, + 0.003520f, 0.475208f, -0.159365f, + 0.001856f, 0.419203f, 0.098582f, + -0.252802f, 0.093666f, 0.237538f, + -0.162901f, 0.237984f, 0.206905f, + 0.000865f, 0.318141f, 0.235370f, + -0.414624f, 0.164083f, -0.278254f, + -0.262213f, 0.357334f, -0.293246f, + 0.004628f, 0.482694f, -0.338626f, + -0.402162f, 0.133528f, -0.443247f, + -0.243781f, 0.324275f, -0.436763f, + 0.005293f, 0.437592f, -0.458332f, + -0.339884f, -0.041150f, -0.668211f, + -0.248382f, 0.255825f, -0.627493f, + 0.006261f, 0.376103f, -0.631506f, + -0.216201f, -0.126776f, -0.886936f, + -0.171075f, 0.011544f, -0.881386f, + -0.181074f, 0.098223f, -0.814779f, + -0.119891f, 0.218786f, -0.760153f, + -0.078895f, 0.276780f, -0.739281f, + 0.006801f, 0.310959f, -0.735661f, + -0.168842f, 0.102387f, -0.920381f, + -0.104072f, 0.177278f, -0.952530f, + -0.129704f, 0.211848f, -0.836678f, + -0.099875f, 0.310931f, -0.799381f, + 0.007237f, 0.361687f, -0.794439f, + -0.077913f, 0.258753f, -0.921640f, + 0.007957f, 0.282241f, -0.931680f, + -0.252222f, -0.550401f, -0.557810f, + -0.267633f, -0.603419f, -0.655209f, + -0.446838f, -0.118517f, -0.466159f, + -0.459488f, -0.093017f, -0.311341f, + -0.370645f, -0.100108f, -0.159454f, + -0.371984f, -0.091991f, -0.011044f, + -0.328945f, -0.098269f, 0.088659f, + -0.282452f, -0.018862f, 0.311501f, + -0.352403f, -0.131341f, 0.144902f, + -0.364126f, -0.200299f, 0.202388f, + -0.283965f, -0.231869f, 0.023668f, + -0.298943f, -0.155218f, 0.369716f, + -0.293787f, -0.121856f, 0.419097f, + -0.290163f, -0.290797f, 0.107824f, + -0.264165f, -0.272849f, 0.036347f, + -0.228567f, -0.372573f, 0.290309f, + -0.190431f, -0.286997f, 0.421917f, + -0.191039f, -0.240973f, 0.507118f, + -0.287272f, -0.276431f, -0.065444f, + -0.295675f, -0.280818f, -0.174200f, + -0.399537f, -0.313131f, -0.376167f, + -0.392666f, -0.488581f, -0.427494f, + -0.331669f, -0.570185f, -0.466054f, + -0.282290f, -0.618140f, -0.589220f, + -0.374238f, -0.594882f, -0.323298f, + -0.381071f, -0.629723f, -0.350777f, + -0.382112f, -0.624060f, -0.221577f, + -0.272701f, -0.566522f, 0.259157f, + -0.256702f, -0.663406f, 0.286079f, + -0.280948f, -0.428359f, 0.055790f, + -0.184974f, -0.508894f, 0.326265f, + -0.279971f, -0.526918f, 0.395319f, + -0.282599f, -0.663393f, 0.412411f, + -0.188329f, -0.475093f, 0.417954f, + -0.263384f, -0.663396f, 0.466604f, + -0.209063f, -0.663393f, 0.509344f, + -0.002044f, -0.319624f, 0.553078f, + -0.001266f, -0.371260f, 0.413296f, + -0.219753f, -0.339762f, -0.040921f, + -0.256986f, -0.282511f, -0.006349f, + -0.271706f, -0.260881f, 0.001764f, + -0.091191f, -0.419184f, -0.045912f, + -0.114944f, -0.429752f, -0.124739f, + -0.113970f, -0.382987f, -0.188540f, + -0.243012f, -0.464942f, -0.242850f, + -0.314815f, -0.505402f, -0.324768f, + 0.002774f, -0.437526f, -0.262766f, + -0.072625f, -0.417748f, -0.221440f, + -0.160112f, -0.476932f, -0.293450f, + 0.003859f, -0.453425f, -0.443916f, + -0.120363f, -0.581567f, -0.438689f, + -0.091499f, -0.584191f, -0.294511f, + -0.116469f, -0.599861f, -0.188308f, + -0.208032f, -0.513640f, -0.134649f, + -0.235749f, -0.610017f, -0.040939f, + -0.344916f, -0.622487f, -0.085380f, + -0.336401f, -0.531864f, -0.212298f, + 0.001961f, -0.459550f, -0.135547f, + -0.058296f, -0.430536f, -0.043440f, + 0.001378f, -0.449511f, -0.037762f, + -0.130135f, -0.510222f, 0.079144f, + 0.000142f, -0.477549f, 0.157064f, + -0.114284f, -0.453206f, 0.304397f, + -0.000592f, -0.443558f, 0.285401f, + -0.056215f, -0.663402f, 0.326073f, + -0.026248f, -0.568010f, 0.273318f, + -0.049261f, -0.531064f, 0.389854f, + -0.127096f, -0.663398f, 0.479316f, + -0.058384f, -0.663401f, 0.372891f, + -0.303961f, 0.054199f, 0.625921f, + -0.268594f, 0.193403f, 0.502766f, + -0.277159f, 0.126123f, 0.443289f, + -0.287605f, -0.005722f, 0.531844f, + -0.231396f, -0.121289f, 0.587387f, + -0.253475f, -0.081797f, 0.756541f, + -0.195164f, -0.137969f, 0.728011f, + -0.167673f, -0.156573f, 0.609388f, + -0.145917f, -0.169029f, 0.697600f, + -0.077776f, -0.214247f, 0.622586f, + -0.076873f, -0.214971f, 0.696301f, + -0.002341f, -0.233135f, 0.622859f, + -0.002730f, -0.213526f, 0.691267f, + -0.003136f, -0.192628f, 0.762731f, + -0.056136f, -0.201222f, 0.763806f, + -0.114589f, -0.166192f, 0.770723f, + -0.155145f, -0.129632f, 0.791738f, + -0.183611f, -0.058705f, 0.847012f, + -0.165562f, 0.001980f, 0.833386f, + -0.220084f, 0.019914f, 0.768935f, + -0.255730f, 0.090306f, 0.670782f, + -0.255594f, 0.113833f, 0.663389f, + -0.226380f, 0.212655f, 0.617740f, + -0.003367f, -0.195342f, 0.799680f, + -0.029743f, -0.210508f, 0.827180f, + -0.003818f, -0.194783f, 0.873636f, + -0.004116f, -0.157907f, 0.931268f, + -0.031280f, -0.184555f, 0.889476f, + -0.059885f, -0.184448f, 0.841330f, + -0.135333f, -0.164332f, 0.878200f, + -0.085574f, -0.170948f, 0.925547f, + -0.163833f, -0.094170f, 0.897114f, + -0.138444f, -0.104250f, 0.945975f, + -0.083497f, -0.084934f, 0.979607f, + -0.004433f, -0.146642f, 0.985872f, + -0.150715f, 0.032650f, 0.884111f, + -0.135892f, -0.035520f, 0.945455f, + -0.070612f, 0.036849f, 0.975733f, + -0.004458f, -0.042526f, 1.015670f, + -0.004249f, 0.046042f, 1.003240f, + -0.086969f, 0.133224f, 0.947633f, + -0.003873f, 0.161605f, 0.970499f, + -0.125544f, 0.140012f, 0.917678f, + -0.125651f, 0.250246f, 0.857602f, + -0.003127f, 0.284070f, 0.878870f, + -0.159174f, 0.125726f, 0.888878f, + -0.183807f, 0.196970f, 0.844480f, + -0.159890f, 0.291736f, 0.732480f, + -0.199495f, 0.207230f, 0.779864f, + -0.206182f, 0.164608f, 0.693257f, + -0.186315f, 0.160689f, 0.817193f, + -0.192827f, 0.166706f, 0.782271f, + -0.175112f, 0.110008f, 0.860621f, + -0.161022f, 0.057420f, 0.855111f, + -0.172319f, 0.036155f, 0.816189f, + -0.190318f, 0.064083f, 0.760605f, + -0.195072f, 0.129179f, 0.731104f, + -0.203126f, 0.410287f, 0.680536f, + -0.216677f, 0.309274f, 0.642272f, + -0.241515f, 0.311485f, 0.587832f, + -0.002209f, 0.366663f, 0.749413f, + -0.088230f, 0.396265f, 0.678635f, + -0.170147f, 0.109517f, 0.840784f, + -0.160521f, 0.067766f, 0.830650f, + -0.181546f, 0.139805f, 0.812146f, + -0.180495f, 0.148568f, 0.776087f, + -0.180255f, 0.129125f, 0.744192f, + -0.186298f, 0.078308f, 0.769352f, + -0.167622f, 0.060539f, 0.806675f, + -0.189876f, 0.102760f, 0.802582f, + -0.108340f, 0.455446f, 0.657174f, + -0.241585f, 0.527592f, 0.669296f, + -0.265676f, 0.513366f, 0.634594f, + -0.203073f, 0.478550f, 0.581526f, + -0.266772f, 0.642330f, 0.602061f, + -0.216961f, 0.564846f, 0.535435f, + -0.202210f, 0.525495f, 0.475944f, + -0.193888f, 0.467925f, 0.520606f, + -0.265837f, 0.757267f, 0.500933f, + -0.240306f, 0.653440f, 0.463215f, + -0.309239f, 0.776868f, 0.304726f, + -0.271009f, 0.683094f, 0.382018f, + -0.312111f, 0.671099f, 0.286687f, + -0.268791f, 0.624342f, 0.377231f, + -0.302457f, 0.533996f, 0.360289f, + -0.263656f, 0.529310f, 0.412564f, + -0.282311f, 0.415167f, 0.447666f, + -0.239201f, 0.442096f, 0.495604f, + -0.220043f, 0.569026f, 0.445877f, + -0.001263f, 0.395631f, 0.602029f, + -0.057345f, 0.442535f, 0.572224f, + -0.088927f, 0.506333f, 0.529106f, + -0.125738f, 0.535076f, 0.612913f, + -0.126251f, 0.577170f, 0.483159f, + -0.149594f, 0.611520f, 0.557731f, + -0.163188f, 0.660791f, 0.491080f, + -0.172482f, 0.663387f, 0.415416f, + -0.160464f, 0.591710f, 0.370659f, + -0.156445f, 0.536396f, 0.378302f, + -0.136496f, 0.444358f, 0.425226f, + -0.095564f, 0.373768f, 0.473659f, + -0.104146f, 0.315912f, 0.498104f, + -0.000496f, 0.384194f, 0.473817f, + -0.000183f, 0.297770f, 0.401486f, + -0.129042f, 0.270145f, 0.434495f, + 0.000100f, 0.272963f, 0.349138f, + -0.113060f, 0.236984f, 0.385554f, + 0.007260f, 0.016311f, -0.883396f, + 0.007865f, 0.122104f, -0.956137f, + -0.032842f, 0.115282f, -0.953252f, + -0.089115f, 0.108449f, -0.950317f, + -0.047440f, 0.014729f, -0.882756f, + -0.104458f, 0.013137f, -0.882070f, + -0.086439f, -0.584866f, -0.608343f, + -0.115026f, -0.662605f, -0.436732f, + -0.071683f, -0.665372f, -0.606385f, + -0.257884f, -0.665381f, -0.658052f, + -0.272542f, -0.665381f, -0.592063f, + -0.371322f, -0.665382f, -0.353620f, + -0.372362f, -0.665381f, -0.224420f, + -0.335166f, -0.665380f, -0.078623f, + -0.225999f, -0.665375f, -0.038981f, + -0.106719f, -0.665374f, -0.186351f, + -0.081749f, -0.665372f, -0.292554f, + 0.006943f, -0.091505f, -0.858354f, + 0.006117f, -0.280985f, -0.769967f, + 0.004495f, -0.502360f, -0.559799f, + -0.198638f, -0.302135f, -0.845816f, + -0.237395f, -0.542544f, -0.587188f, + -0.270001f, -0.279489f, -0.669861f, + -0.134547f, -0.119852f, -0.959004f, + -0.052088f, -0.122463f, -0.944549f, + -0.124463f, -0.293508f, -0.899566f, + -0.047616f, -0.289643f, -0.879292f, + -0.168595f, -0.529132f, -0.654931f, + -0.099793f, -0.515719f, -0.645873f, + -0.186168f, -0.605282f, -0.724690f, + -0.112970f, -0.583097f, -0.707469f, + -0.108152f, -0.665375f, -0.700408f, + -0.183019f, -0.665378f, -0.717630f, + -0.349529f, -0.334459f, -0.511985f, + -0.141182f, -0.437705f, -0.798194f, + -0.212670f, -0.448725f, -0.737447f, + -0.261111f, -0.414945f, -0.613835f, + -0.077364f, -0.431480f, -0.778113f, + 0.005174f, -0.425277f, -0.651592f, + 0.089236f, -0.431732f, -0.777093f, + 0.271006f, -0.415749f, -0.610577f, + 0.223981f, -0.449384f, -0.734774f, + 0.153275f, -0.438150f, -0.796391f, + 0.358414f, -0.335529f, -0.507649f, + 0.193434f, -0.665946f, -0.715325f, + 0.118363f, -0.665717f, -0.699021f, + 0.123515f, -0.583454f, -0.706020f, + 0.196851f, -0.605860f, -0.722345f, + 0.109788f, -0.516035f, -0.644590f, + 0.178656f, -0.529656f, -0.652804f, + 0.061157f, -0.289807f, -0.878626f, + 0.138234f, -0.293905f, -0.897958f, + 0.066933f, -0.122643f, -0.943820f, + 0.149571f, -0.120281f, -0.957264f, + 0.280989f, -0.280321f, -0.666487f, + 0.246581f, -0.543275f, -0.584224f, + 0.211720f, -0.302754f, -0.843303f, + 0.086966f, -0.665627f, -0.291520f, + 0.110634f, -0.665702f, -0.185021f, + 0.228099f, -0.666061f, -0.036201f, + 0.337743f, -0.666396f, -0.074503f, + 0.376722f, -0.666513f, -0.219833f, + 0.377265f, -0.666513f, -0.349036f, + 0.281411f, -0.666217f, -0.588670f, + 0.267564f, -0.666174f, -0.654834f, + 0.080745f, -0.665602f, -0.605452f, + 0.122016f, -0.662963f, -0.435280f, + 0.095767f, -0.585141f, -0.607228f, + 0.118944f, 0.012799f, -0.880702f, + 0.061944f, 0.014564f, -0.882086f, + 0.104725f, 0.108156f, -0.949130f, + 0.048513f, 0.115159f, -0.952753f, + 0.112696f, 0.236643f, 0.386937f, + 0.128177f, 0.269757f, 0.436071f, + 0.102643f, 0.315600f, 0.499370f, + 0.094535f, 0.373481f, 0.474824f, + 0.136270f, 0.443946f, 0.426895f, + 0.157071f, 0.535923f, 0.380222f, + 0.161350f, 0.591224f, 0.372630f, + 0.173035f, 0.662865f, 0.417531f, + 0.162808f, 0.660299f, 0.493077f, + 0.148250f, 0.611070f, 0.559555f, + 0.125719f, 0.576790f, 0.484702f, + 0.123489f, 0.534699f, 0.614440f, + 0.087621f, 0.506066f, 0.530188f, + 0.055321f, 0.442365f, 0.572915f, + 0.219936f, 0.568361f, 0.448571f, + 0.238099f, 0.441375f, 0.498528f, + 0.281711f, 0.414315f, 0.451121f, + 0.263833f, 0.528513f, 0.415794f, + 0.303284f, 0.533081f, 0.363998f, + 0.269687f, 0.623528f, 0.380528f, + 0.314255f, 0.670153f, 0.290524f, + 0.272023f, 0.682273f, 0.385343f, + 0.311480f, 0.775931f, 0.308527f, + 0.240239f, 0.652714f, 0.466159f, + 0.265619f, 0.756464f, 0.504187f, + 0.192562f, 0.467341f, 0.522972f, + 0.201605f, 0.524885f, 0.478417f, + 0.215743f, 0.564193f, 0.538084f, + 0.264969f, 0.641527f, 0.605317f, + 0.201031f, 0.477940f, 0.584002f, + 0.263086f, 0.512567f, 0.637832f, + 0.238615f, 0.526867f, 0.672237f, + 0.105309f, 0.455123f, 0.658482f, + 0.183993f, 0.102195f, 0.804872f, + 0.161563f, 0.060042f, 0.808692f, + 0.180748f, 0.077754f, 0.771600f, + 0.175168f, 0.128588f, 0.746368f, + 0.175075f, 0.148030f, 0.778264f, + 0.175658f, 0.139265f, 0.814333f, + 0.154191f, 0.067291f, 0.832578f, + 0.163818f, 0.109013f, 0.842830f, + 0.084760f, 0.396004f, 0.679695f, + 0.238888f, 0.310760f, 0.590775f, + 0.213380f, 0.308625f, 0.644905f, + 0.199666f, 0.409678f, 0.683003f, + 0.190143f, 0.128597f, 0.733463f, + 0.184833f, 0.063516f, 0.762902f, + 0.166070f, 0.035644f, 0.818261f, + 0.154361f, 0.056943f, 0.857042f, + 0.168542f, 0.109489f, 0.862725f, + 0.187387f, 0.166131f, 0.784599f, + 0.180428f, 0.160135f, 0.819438f, + 0.201823f, 0.163991f, 0.695756f, + 0.194206f, 0.206635f, 0.782275f, + 0.155438f, 0.291260f, 0.734412f, + 0.177696f, 0.196424f, 0.846693f, + 0.152305f, 0.125256f, 0.890786f, + 0.119546f, 0.249876f, 0.859104f, + 0.118369f, 0.139643f, 0.919173f, + 0.079410f, 0.132973f, 0.948652f, + 0.062419f, 0.036648f, 0.976547f, + 0.127847f, -0.035919f, 0.947070f, + 0.143624f, 0.032206f, 0.885913f, + 0.074888f, -0.085173f, 0.980577f, + 0.130184f, -0.104656f, 0.947620f, + 0.156201f, -0.094653f, 0.899074f, + 0.077366f, -0.171194f, 0.926545f, + 0.127722f, -0.164729f, 0.879810f, + 0.052670f, -0.184618f, 0.842019f, + 0.023477f, -0.184638f, 0.889811f, + 0.022626f, -0.210587f, 0.827500f, + 0.223089f, 0.211976f, 0.620493f, + 0.251444f, 0.113067f, 0.666494f, + 0.251419f, 0.089540f, 0.673887f, + 0.214360f, 0.019258f, 0.771595f, + 0.158999f, 0.001490f, 0.835374f, + 0.176696f, -0.059249f, 0.849218f, + 0.148696f, -0.130091f, 0.793599f, + 0.108290f, -0.166528f, 0.772088f, + 0.049820f, -0.201382f, 0.764454f, + 0.071341f, -0.215195f, 0.697209f, + 0.073148f, -0.214475f, 0.623510f, + 0.140502f, -0.169461f, 0.699354f, + 0.163374f, -0.157073f, 0.611416f, + 0.189466f, -0.138550f, 0.730366f, + 0.247593f, -0.082554f, 0.759610f, + 0.227468f, -0.121982f, 0.590197f, + 0.284702f, -0.006586f, 0.535347f, + 0.275741f, 0.125287f, 0.446676f, + 0.266650f, 0.192594f, 0.506044f, + 0.300086f, 0.053287f, 0.629620f, + 0.055450f, -0.663935f, 0.375065f, + 0.122854f, -0.664138f, 0.482323f, + 0.046520f, -0.531571f, 0.391918f, + 0.024824f, -0.568450f, 0.275106f, + 0.053855f, -0.663931f, 0.328224f, + 0.112829f, -0.453549f, 0.305788f, + 0.131265f, -0.510617f, 0.080746f, + 0.061174f, -0.430716f, -0.042710f, + 0.341019f, -0.532887f, -0.208150f, + 0.347705f, -0.623533f, -0.081139f, + 0.238040f, -0.610732f, -0.038037f, + 0.211764f, -0.514274f, -0.132078f, + 0.120605f, -0.600219f, -0.186856f, + 0.096985f, -0.584476f, -0.293357f, + 0.127621f, -0.581941f, -0.437170f, + 0.165902f, -0.477425f, -0.291453f, + 0.077720f, -0.417975f, -0.220519f, + 0.320892f, -0.506363f, -0.320874f, + 0.248214f, -0.465684f, -0.239842f, + 0.118764f, -0.383338f, -0.187114f, + 0.118816f, -0.430106f, -0.123307f, + 0.094131f, -0.419464f, -0.044777f, + 0.274526f, -0.261706f, 0.005110f, + 0.259842f, -0.283292f, -0.003185f, + 0.222861f, -0.340431f, -0.038210f, + 0.204445f, -0.664380f, 0.513353f, + 0.259286f, -0.664547f, 0.471281f, + 0.185402f, -0.476020f, 0.421718f, + 0.279163f, -0.664604f, 0.417328f, + 0.277157f, -0.528122f, 0.400208f, + 0.183069f, -0.509812f, 0.329995f, + 0.282599f, -0.429210f, 0.059242f, + 0.254816f, -0.664541f, 0.290687f, + 0.271436f, -0.567707f, 0.263966f, + 0.386561f, -0.625221f, -0.216870f, + 0.387086f, -0.630883f, -0.346073f, + 0.380021f, -0.596021f, -0.318679f, + 0.291269f, -0.619007f, -0.585707f, + 0.339280f, -0.571198f, -0.461946f, + 0.400045f, -0.489778f, -0.422640f, + 0.406817f, -0.314349f, -0.371230f, + 0.300588f, -0.281718f, -0.170549f, + 0.290866f, -0.277304f, -0.061905f, + 0.187735f, -0.241545f, 0.509437f, + 0.188032f, -0.287569f, 0.424234f, + 0.227520f, -0.373262f, 0.293102f, + 0.266526f, -0.273650f, 0.039597f, + 0.291592f, -0.291676f, 0.111386f, + 0.291914f, -0.122741f, 0.422683f, + 0.297574f, -0.156119f, 0.373368f, + 0.286603f, -0.232731f, 0.027162f, + 0.364663f, -0.201399f, 0.206850f, + 0.353855f, -0.132408f, 0.149228f, + 0.282208f, -0.019715f, 0.314960f, + 0.331187f, -0.099266f, 0.092701f, + 0.375463f, -0.093120f, -0.006467f, + 0.375917f, -0.101236f, -0.154882f, + 0.466635f, -0.094416f, -0.305669f, + 0.455805f, -0.119881f, -0.460632f, + 0.277465f, -0.604242f, -0.651871f, + 0.261022f, -0.551176f, -0.554667f, + 0.093627f, 0.258494f, -0.920589f, + 0.114248f, 0.310608f, -0.798070f, + 0.144232f, 0.211434f, -0.835001f, + 0.119916f, 0.176940f, -0.951159f, + 0.184061f, 0.101854f, -0.918220f, + 0.092431f, 0.276521f, -0.738231f, + 0.133504f, 0.218403f, -0.758602f, + 0.194987f, 0.097655f, -0.812476f, + 0.185542f, 0.011005f, -0.879202f, + 0.230315f, -0.127450f, -0.884202f, + 0.260471f, 0.255056f, -0.624378f, + 0.351567f, -0.042194f, -0.663976f, + 0.253742f, 0.323524f, -0.433716f, + 0.411612f, 0.132299f, -0.438264f, + 0.270513f, 0.356530f, -0.289984f, + 0.422146f, 0.162819f, -0.273130f, + 0.164724f, 0.237490f, 0.208912f, + 0.253806f, 0.092900f, 0.240640f, + 0.203608f, 0.284597f, 0.096223f, + 0.241006f, 0.343093f, -0.171396f, + 0.356076f, 0.149288f, -0.143443f, + 0.337656f, 0.131992f, 0.066374f +}; + +dTriIndex Indices[IndexCount / 3][3] = { + {126,134,133}, + {342,138,134}, + {133,134,138}, + {126,342,134}, + {312,316,317}, + {169,163,162}, + {312,317,319}, + {312,319,318}, + {169,162,164}, + {169,168,163}, + {312,314,315}, + {169,164,165}, + {169,167,168}, + {312,315,316}, + {312,313,314}, + {169,165,166}, + {169,166,167}, + {312,318,313}, + {308,304,305}, + {308,305,306}, + {179,181,188}, + {177,173,175}, + {177,175,176}, + {302,293,300}, + {322,294,304}, + {188,176,175}, + {188,175,179}, + {158,177,187}, + {305,293,302}, + {305,302,306}, + {322,304,308}, + {188,181,183}, + {158,173,177}, + {293,298,300}, + {304,294,296}, + {304,296,305}, + {185,176,188}, + {185,188,183}, + {187,177,176}, + {187,176,185}, + {305,296,298}, + {305,298,293}, + {436,432, 28}, + {436, 28, 23}, + {434,278,431}, + { 30,208,209}, + { 30,209, 29}, + { 19, 20, 24}, + {208,207,211}, + {208,211,209}, + { 19,210,212}, + {433,434,431}, + {433,431,432}, + {433,432,436}, + {436,437,433}, + {277,275,276}, + {277,276,278}, + {209,210, 25}, + { 21, 26, 24}, + { 21, 24, 20}, + { 25, 26, 27}, + { 25, 27, 29}, + {435,439,277}, + {439,275,277}, + {432,431, 30}, + {432, 30, 28}, + {433,437,438}, + {433,438,435}, + {434,277,278}, + { 24, 25,210}, + { 24, 26, 25}, + { 29, 27, 28}, + { 29, 28, 30}, + { 19, 24,210}, + {208, 30,431}, + {208,431,278}, + {435,434,433}, + {435,277,434}, + { 25, 29,209}, + { 27, 22, 23}, + { 27, 23, 28}, + { 26, 22, 27}, + { 26, 21, 22}, + {212,210,209}, + {212,209,211}, + {207,208,278}, + {207,278,276}, + {439,435,438}, + { 12, 9, 10}, + { 12, 10, 13}, + { 2, 3, 5}, + { 2, 5, 4}, + { 16, 13, 14}, + { 16, 14, 17}, + { 22, 21, 16}, + { 13, 10, 11}, + { 13, 11, 14}, + { 1, 0, 3}, + { 1, 3, 2}, + { 15, 12, 16}, + { 19, 18, 15}, + { 19, 15, 16}, + { 19, 16, 20}, + { 9, 1, 2}, + { 9, 2, 10}, + { 3, 7, 8}, + { 3, 8, 5}, + { 16, 17, 23}, + { 16, 23, 22}, + { 21, 20, 16}, + { 10, 2, 4}, + { 10, 4, 11}, + { 0, 6, 7}, + { 0, 7, 3}, + { 12, 13, 16}, + {451,446,445}, + {451,445,450}, + {442,440,439}, + {442,439,438}, + {442,438,441}, + {421,420,422}, + {412,411,426}, + {412,426,425}, + {408,405,407}, + {413, 67, 68}, + {413, 68,414}, + {391,390,412}, + { 80,384,386}, + {404,406,378}, + {390,391,377}, + {390,377, 88}, + {400,415,375}, + {398,396,395}, + {398,395,371}, + {398,371,370}, + {112,359,358}, + {112,358,113}, + {351,352,369}, + {125,349,348}, + {345,343,342}, + {342,340,339}, + {341,335,337}, + {328,341,327}, + {331,323,333}, + {331,322,323}, + {327,318,319}, + {327,319,328}, + {315,314,324}, + {302,300,301}, + {302,301,303}, + {320,311,292}, + {285,284,289}, + {310,307,288}, + {310,288,290}, + {321,350,281}, + {321,281,282}, + {423,448,367}, + {272,273,384}, + {272,384,274}, + {264,265,382}, + {264,382,383}, + {440,442,261}, + {440,261,263}, + {252,253,254}, + {252,254,251}, + {262,256,249}, + {262,249,248}, + {228,243,242}, + {228, 31,243}, + {213,215,238}, + {213,238,237}, + { 19,212,230}, + {224,225,233}, + {224,233,231}, + {217,218, 56}, + {217, 56, 54}, + {217,216,239}, + {217,239,238}, + {217,238,215}, + {218,217,215}, + {218,215,214}, + { 6,102,206}, + {186,199,200}, + {197,182,180}, + {170,171,157}, + {201,200,189}, + {170,190,191}, + {170,191,192}, + {175,174,178}, + {175,178,179}, + {168,167,155}, + {122,149,158}, + {122,158,159}, + {135,153,154}, + {135,154,118}, + {143,140,141}, + {143,141,144}, + {132,133,136}, + {130,126,133}, + {124,125,127}, + {122,101,100}, + {122,100,121}, + {110,108,107}, + {110,107,109}, + { 98, 99, 97}, + { 98, 97, 64}, + { 98, 64, 66}, + { 87, 55, 57}, + { 83, 82, 79}, + { 83, 79, 84}, + { 78, 74, 50}, + { 49, 71, 41}, + { 49, 41, 37}, + { 49, 37, 36}, + { 58, 44, 60}, + { 60, 59, 58}, + { 51, 34, 33}, + { 39, 40, 42}, + { 39, 42, 38}, + {243,240, 33}, + {243, 33,229}, + { 39, 38, 6}, + { 44, 46, 40}, + { 55, 56, 57}, + { 64, 62, 65}, + { 64, 65, 66}, + { 41, 71, 45}, + { 75, 50, 51}, + { 81, 79, 82}, + { 77, 88, 73}, + { 93, 92, 94}, + { 68, 47, 46}, + { 96, 97, 99}, + { 96, 99, 95}, + {110,109,111}, + {111,112,110}, + {114,113,123}, + {114,123,124}, + {132,131,129}, + {133,137,136}, + {135,142,145}, + {145,152,135}, + {149,147,157}, + {157,158,149}, + {164,150,151}, + {153,163,168}, + {153,168,154}, + {185,183,182}, + {185,182,184}, + {161,189,190}, + {200,199,191}, + {200,191,190}, + {180,178,195}, + {180,195,196}, + {102,101,204}, + {102,204,206}, + { 43, 48,104}, + { 43,104,103}, + {216,217, 54}, + {216, 54, 32}, + {207,224,231}, + {230,212,211}, + {230,211,231}, + {227,232,241}, + {227,241,242}, + {235,234,241}, + {235,241,244}, + {430,248,247}, + {272,274,253}, + {272,253,252}, + {439,260,275}, + {225,224,259}, + {225,259,257}, + {269,270,407}, + {269,407,405}, + {270,269,273}, + {270,273,272}, + {273,269,268}, + {273,268,267}, + {273,267,266}, + {273,266,265}, + {273,265,264}, + {448,279,367}, + {281,350,368}, + {285,286,301}, + {290,323,310}, + {290,311,323}, + {282,281,189}, + {292,311,290}, + {292,290,291}, + {307,306,302}, + {307,302,303}, + {316,315,324}, + {316,324,329}, + {331,351,350}, + {330,334,335}, + {330,335,328}, + {341,337,338}, + {344,355,354}, + {346,345,348}, + {346,348,347}, + {364,369,352}, + {364,352,353}, + {365,363,361}, + {365,361,362}, + {376,401,402}, + {373,372,397}, + {373,397,400}, + {376, 92,377}, + {381,378,387}, + {381,387,385}, + {386, 77, 80}, + {390,389,412}, + {416,417,401}, + {403,417,415}, + {408,429,430}, + {419,423,418}, + {427,428,444}, + {427,444,446}, + {437,436,441}, + {450,445, 11}, + {450, 11, 4}, + {447,449, 5}, + {447, 5, 8}, + {441,438,437}, + {425,426,451}, + {425,451,452}, + {417,421,415}, + {408,407,429}, + {399,403,400}, + {399,400,397}, + {394,393,416}, + {389,411,412}, + {386,383,385}, + {408,387,378}, + {408,378,406}, + {377,391,376}, + { 94,375,415}, + {372,373,374}, + {372,374,370}, + {359,111,360}, + {359,112,111}, + {113,358,349}, + {113,349,123}, + {346,343,345}, + {343,340,342}, + {338,336,144}, + {338,144,141}, + {327,341,354}, + {327,354,326}, + {331,350,321}, + {331,321,322}, + {314,313,326}, + {314,326,325}, + {300,298,299}, + {300,299,301}, + {288,287,289}, + {189,292,282}, + {287,288,303}, + {284,285,297}, + {368,280,281}, + {448,447,279}, + {274,226,255}, + {267,268,404}, + {267,404,379}, + {429,262,430}, + {439,440,260}, + {257,258,249}, + {257,249,246}, + {430,262,248}, + {234,228,242}, + {234,242,241}, + {237,238,239}, + {237,239,236}, + { 15, 18,227}, + { 15,227,229}, + {222,223, 82}, + {222, 82, 83}, + {214,215,213}, + {214,213, 81}, + { 38,102, 6}, + {122,159,200}, + {122,200,201}, + {174,171,192}, + {174,192,194}, + {197,193,198}, + {190,170,161}, + {181,179,178}, + {181,178,180}, + {166,156,155}, + {163,153,152}, + {163,152,162}, + {120,156,149}, + {120,149,121}, + {152,153,135}, + {140,143,142}, + {135,131,132}, + {135,132,136}, + {130,129,128}, + {130,128,127}, + {100,105,119}, + {100,119,120}, + {106,104,107}, + {106,107,108}, + { 91, 95, 59}, + { 93, 94, 68}, + { 91, 89, 92}, + { 76, 53, 55}, + { 76, 55, 87}, + { 81, 78, 79}, + { 74, 73, 49}, + { 69, 60, 45}, + { 58, 62, 64}, + { 58, 64, 61}, + { 53, 31, 32}, + { 32, 54, 53}, + { 42, 43, 38}, + { 35, 36, 0}, + { 35, 0, 1}, + { 34, 35, 1}, + { 34, 1, 9}, + { 44, 40, 41}, + { 44, 41, 45}, + { 33,240, 51}, + { 63, 62, 58}, + { 63, 58, 59}, + { 45, 71, 70}, + { 76, 75, 51}, + { 76, 51, 52}, + { 86, 85, 84}, + { 86, 84, 87}, + { 89, 72, 73}, + { 89, 73, 88}, + { 91, 92, 96}, + { 91, 96, 95}, + { 72, 91, 60}, + { 72, 60, 69}, + {104,106,105}, + {119,105,117}, + {119,117,118}, + {124,127,128}, + {117,116,129}, + {117,129,131}, + {118,117,131}, + {135,140,142}, + {146,150,152}, + {146,152,145}, + {149,122,121}, + {166,165,151}, + {166,151,156}, + {158,172,173}, + {161,160,189}, + {199,198,193}, + {199,193,191}, + {204,201,202}, + {178,174,194}, + {200,159,186}, + {109, 48, 67}, + { 48,107,104}, + {216, 32,236}, + {216,236,239}, + {223,214, 81}, + {223, 81, 82}, + { 33, 12, 15}, + { 32,228,234}, + { 32,234,236}, + {240, 31, 52}, + {256,255,246}, + {256,246,249}, + {258,263,248}, + {258,248,249}, + {275,260,259}, + {275,259,276}, + {207,276,259}, + {270,271,429}, + {270,429,407}, + {413,418,366}, + {413,366,365}, + {368,367,279}, + {368,279,280}, + {303,301,286}, + {303,286,287}, + {283,282,292}, + {283,292,291}, + {320,292,189}, + {298,296,297}, + {298,297,299}, + {318,327,326}, + {318,326,313}, + {329,330,317}, + {336,333,320}, + {326,354,353}, + {334,332,333}, + {334,333,336}, + {342,339,139}, + {342,139,138}, + {345,342,126}, + {347,357,356}, + {369,368,351}, + {363,356,357}, + {363,357,361}, + {366,367,368}, + {366,368,369}, + {375,373,400}, + { 92, 90,377}, + {409,387,408}, + {386,385,387}, + {386,387,388}, + {412,394,391}, + {396,398,399}, + {408,406,405}, + {415,421,419}, + {415,419,414}, + {425,452,448}, + {425,448,424}, + {444,441,443}, + {448,452,449}, + {448,449,447}, + {446,444,443}, + {446,443,445}, + {250,247,261}, + {250,261,428}, + {421,422,423}, + {421,423,419}, + {427,410,250}, + {417,403,401}, + {403,402,401}, + {420,392,412}, + {420,412,425}, + {420,425,424}, + {386,411,389}, + {383,382,381}, + {383,381,385}, + {378,379,404}, + {372,371,395}, + {372,395,397}, + {371,372,370}, + {361,359,360}, + {361,360,362}, + {368,350,351}, + {349,347,348}, + {356,355,344}, + {356,344,346}, + {344,341,340}, + {344,340,343}, + {338,337,336}, + {328,335,341}, + {324,352,351}, + {324,351,331}, + {320,144,336}, + {314,325,324}, + {322,308,309}, + {310,309,307}, + {287,286,289}, + {203,280,279}, + {203,279,205}, + {297,295,283}, + {297,283,284}, + {447,205,279}, + {274,384, 80}, + {274, 80,226}, + {266,267,379}, + {266,379,380}, + {225,257,246}, + {225,246,245}, + {256,254,253}, + {256,253,255}, + {430,247,250}, + {226,235,244}, + {226,244,245}, + {232,233,244}, + {232,244,241}, + {230, 18, 19}, + { 32, 31,228}, + {219,220, 86}, + {219, 86, 57}, + {226,213,235}, + {206, 7, 6}, + {122,201,101}, + {201,204,101}, + {180,196,197}, + {170,192,171}, + {200,190,189}, + {194,193,195}, + {183,181,180}, + {183,180,182}, + {155,154,168}, + {149,156,151}, + {149,151,148}, + {155,156,120}, + {145,142,143}, + {145,143,146}, + {136,137,140}, + {133,132,130}, + {128,129,116}, + {100,120,121}, + {110,112,113}, + {110,113,114}, + { 66, 65, 63}, + { 66, 63, 99}, + { 66, 99, 98}, + { 96, 46, 61}, + { 89, 88, 90}, + { 86, 87, 57}, + { 80, 78, 81}, + { 72, 69, 49}, + { 67, 48, 47}, + { 67, 47, 68}, + { 56, 55, 53}, + { 50, 49, 36}, + { 50, 36, 35}, + { 40, 39, 41}, + {242,243,229}, + {242,229,227}, + { 6, 37, 39}, + { 42, 47, 48}, + { 42, 48, 43}, + { 61, 46, 44}, + { 45, 70, 69}, + { 69, 70, 71}, + { 69, 71, 49}, + { 74, 78, 77}, + { 83, 84, 85}, + { 73, 74, 77}, + { 93, 96, 92}, + { 68, 46, 93}, + { 95, 99, 63}, + { 95, 63, 59}, + {115,108,110}, + {115,110,114}, + {125,126,127}, + {129,130,132}, + {137,133,138}, + {137,138,139}, + {148,146,143}, + {148,143,147}, + {119,118,154}, + {161,147,143}, + {165,164,151}, + {158,157,171}, + {158,171,172}, + {159,158,187}, + {159,187,186}, + {194,192,191}, + {194,191,193}, + {189,202,201}, + {182,197,184}, + {205, 8, 7}, + { 48,109,107}, + {218,219, 57}, + {218, 57, 56}, + {207,231,211}, + {232,230,231}, + {232,231,233}, + { 53, 52, 31}, + {388,411,386}, + {409,430,250}, + {262,429,254}, + {262,254,256}, + {442,444,428}, + {273,264,383}, + {273,383,384}, + {429,271,251}, + {429,251,254}, + {413,365,362}, + { 67,413,360}, + {282,283,295}, + {285,301,299}, + {202,281,280}, + {284,283,291}, + {284,291,289}, + {320,189,160}, + {308,306,307}, + {307,309,308}, + {319,317,330}, + {319,330,328}, + {353,352,324}, + {332,331,333}, + {340,341,338}, + {354,341,344}, + {349,358,357}, + {349,357,347}, + {364,355,356}, + {364,356,363}, + {364,365,366}, + {364,366,369}, + {374,376,402}, + {375, 92,373}, + { 77,389,390}, + {382,380,381}, + {389, 77,386}, + {393,394,412}, + {393,412,392}, + {401,394,416}, + {415,400,403}, + {411,410,427}, + {411,427,426}, + {422,420,424}, + {247,248,263}, + {247,263,261}, + {445,443, 14}, + {445, 14, 11}, + {449,450, 4}, + {449, 4, 5}, + {443,441, 17}, + {443, 17, 14}, + {436, 23, 17}, + {436, 17,441}, + {424,448,422}, + {448,423,422}, + {414,419,418}, + {414,418,413}, + {406,404,405}, + {399,397,395}, + {399,395,396}, + {420,416,392}, + {388,410,411}, + {386,384,383}, + {390, 88, 77}, + {375, 94, 92}, + {415,414, 68}, + {415, 68, 94}, + {370,374,402}, + {370,402,398}, + {361,357,358}, + {361,358,359}, + {125,348,126}, + {346,344,343}, + {340,338,339}, + {337,335,334}, + {337,334,336}, + {325,353,324}, + {324,331,332}, + {324,332,329}, + {323,322,309}, + {323,309,310}, + {294,295,297}, + {294,297,296}, + {289,286,285}, + {202,280,203}, + {288,307,303}, + {282,295,321}, + { 67,360,111}, + {418,423,367}, + {418,367,366}, + {272,252,251}, + {272,251,271}, + {272,271,270}, + {255,253,274}, + {265,266,380}, + {265,380,382}, + {442,428,261}, + {440,263,258}, + {440,258,260}, + {409,250,410}, + {255,226,245}, + {255,245,246}, + { 31,240,243}, + {236,234,235}, + {236,235,237}, + {233,225,245}, + {233,245,244}, + {220,221, 85}, + {220, 85, 86}, + { 81,213,226}, + { 81,226, 80}, + { 7,206,205}, + {186,184,198}, + {186,198,199}, + {204,203,205}, + {204,205,206}, + {195,193,196}, + {171,174,172}, + {173,174,175}, + {173,172,174}, + {155,167,166}, + {160,161,143}, + {160,143,144}, + {119,154,155}, + {148,151,150}, + {148,150,146}, + {140,137,139}, + {140,139,141}, + {127,126,130}, + {114,124,128}, + {114,128,115}, + {117,105,106}, + {117,106,116}, + {104,105,100}, + {104,100,103}, + { 59, 60, 91}, + { 97, 96, 61}, + { 97, 61, 64}, + { 91, 72, 89}, + { 87, 84, 79}, + { 87, 79, 76}, + { 78, 80, 77}, + { 49, 50, 74}, + { 60, 44, 45}, + { 61, 44, 58}, + { 51, 50, 35}, + { 51, 35, 34}, + { 39, 37, 41}, + { 33, 34, 9}, + { 33, 9, 12}, + { 0, 36, 37}, + { 0, 37, 6}, + { 40, 46, 47}, + { 40, 47, 42}, + { 53, 54, 56}, + { 65, 62, 63}, + { 72, 49, 73}, + { 79, 78, 75}, + { 79, 75, 76}, + { 52, 53, 76}, + { 92, 89, 90}, + { 96, 93, 46}, + {102,103,100}, + {102,100,101}, + {116,106,108}, + {116,108,115}, + {123,125,124}, + {116,115,128}, + {118,131,135}, + {140,135,136}, + {148,147,149}, + {120,119,155}, + {164,162,152}, + {164,152,150}, + {157,147,161}, + {157,161,170}, + {186,187,185}, + {186,185,184}, + {193,197,196}, + {202,203,204}, + {194,195,178}, + {198,184,197}, + { 67,111,109}, + { 38, 43,103}, + { 38,103,102}, + {214,223,222}, + {214,222,221}, + {214,221,220}, + {214,220,219}, + {214,219,218}, + {213,237,235}, + {221,222, 83}, + {221, 83, 85}, + { 15,229, 33}, + {227, 18,230}, + {227,230,232}, + { 52, 51,240}, + { 75, 78, 50}, + {408,430,409}, + {260,258,257}, + {260,257,259}, + {224,207,259}, + {268,269,405}, + {268,405,404}, + {413,362,360}, + {447, 8,205}, + {299,297,285}, + {189,281,202}, + {290,288,289}, + {290,289,291}, + {322,321,295}, + {322,295,294}, + {333,323,311}, + {333,311,320}, + {317,316,329}, + {320,160,144}, + {353,325,326}, + {329,332,334}, + {329,334,330}, + {339,338,141}, + {339,141,139}, + {348,345,126}, + {347,356,346}, + {123,349,125}, + {364,353,354}, + {364,354,355}, + {365,364,363}, + {376,391,394}, + {376,394,401}, + { 92,376,374}, + { 92,374,373}, + {377, 90, 88}, + {380,379,378}, + {380,378,381}, + {388,387,409}, + {388,409,410}, + {416,393,392}, + {399,398,402}, + {399,402,403}, + {250,428,427}, + {421,417,416}, + {421,416,420}, + {426,427,446}, + {426,446,451}, + {444,442,441}, + {452,451,450}, + {452,450,449} +}; + diff --git a/libs/ode-0.16.1/ode/demo/convex_bunny_geom.h b/libs/ode-0.16.1/ode/demo/convex_bunny_geom.h new file mode 100644 index 0000000..09fe6de --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/convex_bunny_geom.h @@ -0,0 +1,468 @@ +const unsigned int convexBunnyPlaneCount = 176; +dReal convexBunnyPlanes[] = +{ + 0.986167, -0.0612533, -0.154021, 0.399481, + 0.982735, -0.0691036, -0.171628, 0.409884, + -0.984387, -0.0582774, -0.166089, 0.403079, + 0.985044, -0.172279, 0.00302105, 0.437531, + 0.976915, -0.184361, 0.107929, 0.465334, + 0.951478, -0.281619, 0.124019, 0.475223, + 0.798136, -0.502214, 0.332805, 0.535555, + 0.949728, -0.211128, -0.231176, 0.528156, + -0.000894561, -0.995066, -0.0992088, 0.80299, + -0.000896015, -0.995066, -0.0992131, 0.802991, + -0.0035709, -0.935822, 0.352454, 0.618504, + -0.291551, -0.828515, 0.478081, 0.681579, + -0.978715, -0.181408, 0.0959605, 0.468907, + -0.985523, -0.169302, -0.00904739, 0.441129, + -0.953768, -0.278749, 0.11236, 0.478704, + 0.372745, -0.827499, 0.419888, 0.630174, + 0.976911, -0.18316, 0.109991, 0.466086, + 0.817827, -0.387738, 0.425227, 0.569153, + -0.978732, -0.180211, 0.0980152, 0.469656, + 0.662794, -0.0277654, 0.748287, 0.803459, + 0.00359857, -0.660581, -0.750746, 0.877267, + 0.00359952, -0.660579, -0.750748, 0.877266, + -0.947456, -0.208272, -0.242797, 0.531628, + -0.980764, -0.0661375, -0.18365, 0.413468, + -0.940835, -0.0698657, -0.331585, 0.494827, + 0.983751, 0.0529367, -0.171556, 0.403533, + 0.981839, 0.0996302, -0.16145, 0.410144, + 0.977938, 0.0857834, -0.190468, 0.411823, + 0.959636, 0.106068, -0.260476, 0.44898, + 0.85334, -0.0495414, -0.518996, 0.60489, + -0.803667, -0.499793, 0.322995, 0.538478, + -0.689742, -0.615484, 0.381361, 0.574754, + -0.380353, -0.826364, 0.415277, 0.63155, + -0.39985, -0.817283, 0.414933, 0.630682, + -0.380309, -0.826285, 0.415473, 0.631677, + -0.981411, 0.0559147, -0.183592, 0.407121, + -0.979526, 0.101914, -0.173615, 0.413635, + -0.975381, 0.0881975, -0.202119, 0.415257, + 0.988445, 0.140182, 0.0576755, 0.485174, + 0.876515, 0.0408992, 0.479634, 0.620093, + 0.848907, -0.0996824, 0.519057, 0.631268, + 0.895754, -0.195088, 0.399457, 0.563346, + 0.861448, -0.256989, 0.438023, 0.574909, + 0.775672, -0.447481, 0.445076, 0.586422, + 0.683157, -0.617557, 0.389768, 0.572247, + 0.391755, -0.818722, 0.419789, 0.629264, + 0.28317, -0.829384, 0.481599, 0.680529, + 0.3727, -0.827422, 0.420079, 0.630298, + -0.824143, -0.385255, 0.415171, 0.57215, + -0.782413, -0.445128, 0.435536, 0.589267, + 0.00152876, 0.999994, -0.00308275, 0.665646, + 0.00242466, 0.999989, -0.0038994, 0.665879, + -0.979892, 0.121321, -0.158406, 0.420287, + 0.767537, -0.190214, -0.612132, 0.695479, + 0.372649, -0.42747, -0.823652, 0.869878, + 0.537245, -0.335515, -0.77382, 0.82472, + 0.0263648, -0.598975, -0.800334, 0.873623, + 0.00393345, -0.60959, -0.792707, 0.869865, + -0.0183706, -0.598907, -0.800608, 0.873704, + 0.00875728, 0.676014, -0.736836, 0.825597, + 0.852333, -0.0355955, -0.521786, 0.607886, + 0.392036, 0.534934, -0.748434, 0.818042, + 0.847696, -0.122973, -0.516033, 0.615814, + 0.884763, -0.0760716, -0.45979, 0.565893, + 0.9446, -0.0727144, -0.320069, 0.491401, + 0.904971, -0.0675211, -0.420081, 0.541673, + -0.899959, -0.0647928, -0.431134, 0.544968, + -0.955972, 0.108494, -0.272667, 0.452769, + -0.363823, -0.426358, -0.828161, 0.871222, + -0.528689, -0.333936, -0.780368, 0.826685, + 0.982068, 0.118277, -0.146811, 0.416542, + 0.98951, 0.144455, 0.00164104, 0.468616, + 0.50797, -0.0708041, 0.85846, 0.883126, + 0.748614, -0.431275, 0.503565, 0.634026, + 0.214863, -0.405791, 0.888351, 0.94048, + -0.901162, -0.192379, 0.388455, 0.566627, + -0.867521, -0.254376, 0.427435, 0.578065, + -0.226957, -0.405135, 0.885639, 0.941284, + -0.756029, -0.429007, 0.494341, 0.636765, + -0.00629553, -0.188362, 0.982079, 0.968197, + 0.0165684, 0.999846, -0.00581961, 0.670373, + 0.00313267, 0.999987, -0.00405124, 0.666103, + 0.545069, 0.472158, -0.692796, 0.780052, + 0.932011, 0.148856, -0.330451, 0.498417, + 0.844043, 0.227673, -0.485547, 0.599903, + -0.019033, 0.999801, -0.00590978, 0.672252, + -0.959662, 0.239262, -0.147656, 0.488538, + 0.00151234, 0.999999, -0.000399466, 0.665855, + -0.988649, 0.143168, 0.0455675, 0.488784, + -0.989015, 0.147444, -0.01048, 0.472227, + -0.972439, 0.232727, -0.01415, 0.518344, + 0.587681, -0.160147, -0.793085, 0.823999, + 0.640479, -0.269179, -0.719256, 0.778142, + 0.541109, -0.332896, -0.772257, 0.823226, + 0.546185, -0.14771, -0.824538, 0.84854, + 0.528519, -0.026044, -0.848522, 0.873136, + 0.447231, -0.0756684, -0.891212, 0.903953, + 0.490619, -0.0795123, -0.867739, 0.884255, + 0.279393, 0.264257, -0.923097, 0.950045, + 0.374653, 0.39486, -0.83888, 0.886593, + 0.00050174, 0.999994, -0.00331563, 0.665976, + -0.0103777, 0.999934, -0.00487936, 0.669494, + -0.927571, 0.150741, -0.341889, 0.501807, + -0.267268, 0.265084, -0.926444, 0.951043, + -0.845984, -0.0330207, -0.532184, 0.610986, + -0.518165, -0.0244575, -0.854931, 0.875047, + -0.83753, 0.228953, -0.496108, 0.603116, + -0.535666, 0.472122, -0.700116, 0.78259, + -0.381083, 0.534649, -0.754272, 0.820328, + -0.363157, 0.395975, -0.843398, 0.88794, + -0.326829, -0.256634, -0.909572, 0.922946, + 0.394875, -0.128601, -0.90969, 0.920236, + 0.337169, -0.257642, -0.905504, 0.921733, + 0.398433, -0.193767, -0.896496, 0.910015, + -0.536477, -0.146072, -0.831177, 0.850523, + -0.436512, -0.0743406, -0.896622, 0.905564, + -0.480187, -0.0780522, -0.873687, 0.886029, + -0.384093, -0.127432, -0.914458, 0.921656, + -0.388009, -0.192572, -0.901313, 0.911451, + 0.977045, 0.15796, 0.14294, 0.521934, + 0.930035, 0.231515, 0.28537, 0.600301, + -0.855499, -0.0971121, 0.508616, 0.634376, + -0.875419, 0.136849, 0.463589, 0.62897, + -0.882196, 0.0435387, 0.468864, 0.623303, + 0.0204398, -0.0238739, 0.999506, 0.958419, + -0.0062197, -0.0777937, 0.99695, 0.962769, + 0.907123, 0.250746, 0.338015, 0.623205, + 0.902358, 0.173321, 0.394601, 0.607696, + 0.870085, 0.134211, 0.474278, 0.625782, + 0.0015108, 0.999999, 6.34978e-06, 0.665945, + 0.00150567, 0.999999, 0.000568537, 0.666143, + 0.00150738, 0.999999, 0.000565012, 0.666141, + -0.963954, 0.266039, -0.00405118, 0.539571, + 0.0015136, 0.999999, -0.000393102, 0.665856, + 0.00151117, 0.999999, 4.32104e-06, 0.665944, + 0.0272711, 0.999604, -0.00696439, 0.673709, + 0.962047, 0.236383, -0.136341, 0.484917, + 0.973236, 0.229796, -0.00223071, 0.514797, + 0.964728, 0.263133, 0.00776342, 0.536054, + -0.906596, 0.176056, 0.383521, 0.610999, + -0.978237, 0.160918, 0.130987, 0.525513, + -0.910434, 0.253486, 0.326887, 0.626522, + -0.932759, 0.234321, 0.27396, 0.603697, + 0.800621, -0.0921333, -0.592045, 0.665278, + 0.679569, -0.15358, -0.717356, 0.765121, + 0.684928, -0.199829, -0.700672, 0.756959, + -0.532604, -0.33128, -0.778837, 0.82519, + -0.578395, -0.158384, -0.800234, 0.826134, + -0.671209, -0.151537, -0.725613, 0.767576, + -0.00530287, 0.323551, 0.946196, 0.94547, + -0.719766, 0.229227, 0.655281, 0.774388, + -0.604194, 0.29171, 0.741522, 0.841564, + -0.544989, 0.302925, 0.781808, 0.866398, + -0.518662, -0.0692529, 0.85217, 0.884999, + -0.671987, -0.0257512, 0.740115, 0.805898, + -0.00613626, -0.00823685, 0.999947, 0.957141, + -0.032747, -0.0237908, 0.99918, 0.958516, + -0.00530611, 0.323546, 0.946198, 0.945471, + -0.545061, 0.302657, 0.781861, 0.866377, + -0.639902, 0.23832, 0.730568, 0.823722, + 0.00149706, 0.999997, 0.00193434, 0.667038, + 0.00149731, 0.999997, 0.00193252, 0.667037, + -0.0048341, 0.44008, 0.897946, 0.936327, + -0.00483143, 0.440078, 0.897947, 0.936327, + -0.632454, -0.267241, -0.727039, 0.780455, + -0.67691, -0.197765, -0.709, 0.759436, + -0.841667, -0.120432, -0.526396, 0.618913, + -0.760706, -0.187792, -0.621337, 0.698143, + -0.87929, -0.0734062, -0.470597, 0.569116, + -0.847068, -0.0469762, -0.529405, 0.607991, + -0.793572, -0.0897399, -0.601823, 0.668201, + 0.536355, 0.301024, 0.788485, 0.864403, + 0.536284, 0.301291, 0.788431, 0.864424, + 0.595945, 0.289897, 0.748872, 0.839373, + 0.631626, 0.236397, 0.738353, 0.8214, + 0.712378, 0.227061, 0.664049, 0.771772, +}; +const unsigned int convexBunnyPointCount = 105; +dReal convexBunnyPoints[] = +{ + -0.459488, -0.093017, -0.311341, + 0.466635, -0.094416, -0.305669, + -0.309239, 0.776868, 0.304726, + -0.004458, -0.042526, 1.01567, + 8.40779e-45, 3.00321e-39, 2.8026e-44, + 0.007957, 0.282241, -0.93168, + 0.204445, -0.66438, 0.513353, + -0.303961, 0.054199, 0.625921, + 0.265619, 0.756464, 0.504187, + -0.402162, 0.133528, -0.443247, + 8.40779e-45, 3.00321e-39, 2.8026e-44, + -0.266772, 0.64233, 0.602061, + 8.40779e-45, 3.00321e-39, 2.8026e-44, + 8.40779e-45, 3.00321e-39, 2.8026e-44, + 0.411612, 0.132299, -0.438264, + 0.31148, 0.775931, 0.308527, + 0.300086, 0.053287, 0.62962, + -0.414624, 0.164083, -0.278254, + -0.248382, 0.255825, -0.627493, + -0.216201, -0.126776, -0.886936, + 0.267564, -0.666174, -0.654834, + -0.135892, -0.03552, 0.945455, + -0.265837, 0.757267, 0.500933, + -0.003873, 0.161605, 0.970499, + 8.40779e-45, 3.00321e-39, 2.8026e-44, + -0.282599, -0.663393, 0.412411, + 0.007237, 0.361687, -0.794439, + 0.093627, 0.258494, -0.920589, + 0.422146, 0.162819, -0.27313, + 0.279163, -0.664604, 0.417328, + 0.263086, 0.512567, 0.637832, + -0.099875, 0.310931, -0.799381, + -0.446838, -0.118517, -0.466159, + -0.168842, 0.102387, -0.920381, + 0.455805, -0.119881, -0.460632, + 0.337743, -0.666396, -0.074503, + -0.134547, -0.119852, -0.959004, + -0.183807, 0.19697, 0.84448, + 0.264969, 0.641527, 0.605317, + -0.209063, -0.663393, 0.509344, + -0.364126, -0.200299, 0.202388, + -0.253475, -0.081797, 0.756541, + 0.260471, 0.255056, -0.624378, + 0.114248, 0.310608, -0.79807, + 0.364663, -0.201399, 0.20685, + 0.127847, -0.035919, 0.94707, + 8.40779e-45, 3.00321e-39, 2.8026e-44, + -0.381071, -0.629723, -0.350777, + -0.339884, -0.04115, -0.668211, + -0.077913, 0.258753, -0.92164, + 0.184061, 0.101854, -0.91822, + -0.335166, -0.66538, -0.078623, + 0.386561, -0.625221, -0.21687, + 8.40779e-45, 3.00321e-39, 2.8026e-44, + -0.241585, 0.527592, 0.669296, + -0.086969, 0.133224, 0.947633, + -0.003127, 0.28407, 0.87887, + -0.004433, -0.146642, 0.985872, + 8.40779e-45, 3.00321e-39, 2.8026e-44, + -0.138444, -0.10425, 0.945975, + -0.265676, 0.513366, 0.634594, + 8.40779e-45, 3.00321e-39, 2.8026e-44, + 0.247593, -0.082554, 0.75961, + 0.07941, 0.132973, 0.948652, + 0.238615, 0.526867, 0.672237, + 8.40779e-45, 3.00321e-39, 2.8026e-44, + 8.40779e-45, 3.00321e-39, 2.8026e-44, + -0.382112, -0.62406, -0.221577, + -0.104072, 0.177278, -0.95253, + 0.351567, -0.042194, -0.663976, + 0.138234, -0.293905, -0.897958, + 0.119916, 0.17694, -0.951159, + -0.371322, -0.665382, -0.35362, + -0.263384, -0.663396, 0.466604, + 0.376722, -0.666513, -0.219833, + 0.387086, -0.630883, -0.346073, + -0.125544, 0.140012, 0.917678, + -0.070612, 0.036849, 0.975733, + -0.083497, -0.084934, 0.979607, + 0.259286, -0.664547, 0.471281, + 8.40779e-45, 3.00321e-39, 2.8026e-44, + 0.074888, -0.085173, 0.980577, + 0.152305, 0.125256, 0.890786, + 0.130184, -0.104656, 0.94762, + -0.004249, 0.046042, 1.00324, + 0.062419, 0.036648, 0.976547, + 8.40779e-45, 3.00321e-39, 2.8026e-44, + -0.392666, -0.488581, -0.427494, + 0.230315, -0.12745, -0.884202, + 8.40779e-45, 3.00321e-39, 2.8026e-44, + 0.193434, -0.665946, -0.715325, + 0.007865, 0.122104, -0.956137, + 8.40779e-45, 3.00321e-39, 2.8026e-44, + -0.257884, -0.665381, -0.658052, + 0.377265, -0.666513, -0.349036, + -0.372362, -0.665381, -0.22442, + 0.400045, -0.489778, -0.42264, + -0.159174, 0.125726, 0.888878, + 0.118369, 0.139643, 0.919173, + -0.124463, -0.293508, -0.899566, + 0.21172, -0.302754, -0.843303, + 0.149571, -0.120281, -0.957264, + -0.183019, -0.665378, -0.71763, + 0.177696, 0.196424, 0.846693, + -0.198638, -0.302135, -0.845816, +}; +unsigned int convexBunnyPolygons[] = +{ + 3, 7, 2, 0, + 3, 2, 7, 11, + 3, 1, 15, 16, + 3, 0, 2, 17, + 3, 17, 9, 0, + 3, 2, 9, 17, + 3, 18, 9, 2, + 3, 2, 11, 22, + 3, 22, 15, 2, + 3, 8, 15, 22, + 3, 2, 15, 26, + 3, 5, 26, 27, + 3, 1, 14, 28, + 3, 28, 15, 1, + 3, 14, 15, 28, + 3, 2, 26, 31, + 3, 0, 9, 32, + 3, 9, 18, 33, + 3, 34, 14, 1, + 3, 19, 33, 36, + 3, 8, 22, 38, + 3, 38, 22, 11, + 3, 38, 15, 8, + 3, 38, 16, 15, + 3, 38, 30, 16, + 3, 40, 7, 0, + 3, 0, 25, 40, + 3, 40, 25, 7, + 3, 7, 25, 41, + 3, 21, 37, 41, + 3, 42, 15, 14, + 3, 42, 27, 15, + 3, 43, 26, 15, + 3, 15, 27, 43, + 3, 43, 27, 26, + 3, 1, 16, 44, + 3, 44, 29, 1, + 3, 16, 29, 44, + 3, 0, 32, 47, + 3, 19, 32, 48, + 3, 48, 33, 19, + 3, 48, 32, 9, + 3, 9, 33, 48, + 3, 49, 33, 18, + 3, 49, 18, 2, + 3, 2, 31, 49, + 3, 49, 26, 5, + 3, 49, 31, 26, + 3, 50, 42, 14, + 3, 27, 42, 50, + 3, 51, 35, 6, + 3, 6, 39, 51, + 3, 1, 29, 52, + 3, 11, 37, 54, + 3, 55, 23, 11, + 3, 11, 54, 55, + 3, 11, 23, 56, + 3, 56, 38, 11, + 3, 23, 38, 56, + 3, 57, 39, 6, + 3, 21, 41, 59, + 3, 39, 57, 59, + 3, 60, 37, 11, + 3, 60, 41, 37, + 3, 60, 11, 7, + 3, 7, 41, 60, + 3, 16, 30, 62, + 3, 62, 29, 16, + 3, 63, 38, 23, + 3, 38, 63, 64, + 3, 67, 25, 0, + 3, 0, 47, 67, + 3, 68, 36, 33, + 3, 33, 49, 68, + 3, 68, 49, 5, + 3, 14, 34, 69, + 3, 69, 50, 14, + 3, 5, 27, 71, + 3, 27, 50, 71, + 3, 71, 68, 5, + 3, 25, 51, 73, + 3, 73, 51, 39, + 3, 39, 59, 73, + 3, 73, 41, 25, + 3, 73, 59, 41, + 3, 29, 35, 74, + 3, 74, 52, 29, + 3, 35, 51, 74, + 3, 75, 34, 1, + 3, 1, 52, 75, + 3, 52, 74, 75, + 3, 21, 55, 76, + 3, 76, 54, 37, + 3, 76, 55, 54, + 3, 77, 55, 21, + 3, 21, 59, 78, + 3, 3, 77, 78, + 3, 78, 77, 21, + 3, 78, 57, 3, + 3, 78, 59, 57, + 3, 6, 35, 79, + 3, 79, 35, 29, + 3, 29, 62, 79, + 3, 3, 57, 81, + 3, 83, 62, 45, + 3, 45, 81, 83, + 3, 83, 79, 62, + 3, 6, 79, 83, + 3, 83, 57, 6, + 3, 83, 81, 57, + 3, 84, 63, 23, + 3, 84, 77, 3, + 3, 23, 55, 84, + 3, 55, 77, 84, + 3, 45, 63, 85, + 3, 3, 81, 85, + 3, 85, 81, 45, + 3, 85, 84, 3, + 3, 63, 84, 85, + 3, 87, 47, 32, + 3, 87, 72, 47, + 3, 50, 69, 88, + 3, 88, 34, 20, + 3, 88, 69, 34, + 3, 36, 68, 91, + 3, 68, 71, 91, + 3, 72, 87, 93, + 3, 93, 87, 32, + 3, 93, 32, 19, + 3, 94, 74, 72, + 3, 94, 93, 20, + 3, 72, 93, 94, + 3, 94, 75, 74, + 3, 95, 74, 51, + 3, 72, 74, 95, + 3, 95, 51, 25, + 3, 25, 67, 95, + 3, 95, 67, 47, + 3, 47, 72, 95, + 3, 20, 34, 96, + 3, 34, 75, 96, + 3, 96, 94, 20, + 3, 75, 94, 96, + 3, 97, 37, 21, + 3, 21, 76, 97, + 3, 97, 76, 37, + 3, 98, 64, 63, + 3, 98, 63, 45, + 3, 45, 82, 98, + 3, 36, 70, 99, + 3, 100, 88, 20, + 3, 20, 90, 100, + 3, 100, 90, 70, + 3, 101, 71, 50, + 3, 50, 88, 101, + 3, 36, 91, 101, + 3, 101, 91, 71, + 3, 101, 70, 36, + 3, 101, 100, 70, + 3, 88, 100, 101, + 3, 102, 90, 20, + 3, 20, 93, 102, + 3, 70, 90, 102, + 3, 102, 99, 70, + 3, 64, 98, 103, + 3, 103, 98, 82, + 3, 30, 38, 103, + 3, 38, 64, 103, + 3, 103, 62, 30, + 3, 45, 62, 103, + 3, 103, 82, 45, + 3, 36, 99, 104, + 3, 99, 102, 104, + 3, 104, 102, 93, + 3, 19, 36, 104, + 3, 104, 93, 19, +}; diff --git a/libs/ode-0.16.1/ode/demo/convex_prism.h b/libs/ode-0.16.1/ode/demo/convex_prism.h new file mode 100644 index 0000000..1ee7fcb --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/convex_prism.h @@ -0,0 +1,28 @@ +unsigned int prism_pointcount = 8; +unsigned int prism_planecount = 6; +dReal prism_points[24]={ + 10.0, 1.0,-1.0, + 10.0,-1.0,-1.0, +-10.0,-1.0,-1.0, +-10.0, 1.0,-1.0, + 10.0, 1.0, 1.0, + 10.0,-1.0, 1.0, +-10.0,-1.0, 1.0, +-10.0, 1.0, 1.0 +}; +unsigned int prism_polygons[]={ +4,0,1,2,3, +4,4,7,6,5, +4,0,4,5,1, +4,1,5,6,2, +4,2,6,7,3, +4,4,0,3,7, +}; +dReal prism_planes[]={ +0.0,0.0,-1.0,1.0, +0.0,0.0,1.0,1.0, +1.0,0.0,0.0,10.0, +0.0,-1.0,0.0,1.0, +-1.0,0.0,-0.0,10.0, +0.0,1.0,0.0,1.0, +}; diff --git a/libs/ode-0.16.1/ode/demo/demo_I.cpp b/libs/ode-0.16.1/ode/demo/demo_I.cpp new file mode 100644 index 0000000..156a4ad --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/demo_I.cpp @@ -0,0 +1,253 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +/* + +test that the rotational physics is correct. + +an "anchor body" has a number of other randomly positioned bodies +("particles") attached to it by ball-and-socket joints, giving it some +random effective inertia tensor. the effective inertia matrix is calculated, +and then this inertia is assigned to another "test" body. a random torque is +applied to both bodies and the difference in angular velocity and orientation +is observed after a number of iterations. + +typical errors for each test cycle are about 1e-5 ... 1e-4. + +*/ + + +#include +#include +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +// select correct drawing functions + +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawSphere dsDrawSphereD +#define dsDrawCylinder dsDrawCylinderD +#define dsDrawCapsule dsDrawCapsuleD +#endif + + +// some constants + +#define NUM 10 // number of particles +#define SIDE 0.1 // visual size of the particles + + +// dynamics objects an globals + +static dWorldID world=0; +static dBodyID anchor_body,particle[NUM],test_body; +static dJointID particle_joint[NUM]; +static dReal torque[3]; +static int iteration; + + +// start simulation - set viewpoint + +static void start() +{ + dAllocateODEDataForThread(dAllocateMaskAll); + + static float xyz[3] = {1.5572f,-1.8886f,1.5700f}; + static float hpr[3] = {118.5000f,-17.0000f,0.0000f}; + dsSetViewpoint (xyz,hpr); +} + + +// compute the mass parameters of a particle set. q = particle positions, +// pm = particle masses + +#define _I(i,j) I[(i)*4+(j)] + +void computeMassParams (dMass *m, dReal q[NUM][3], dReal pm[NUM]) +{ + int i,j; + dMassSetZero (m); + for (i=0; imass += pm[i]; + for (j=0; j<3; j++) m->c[j] += pm[i]*q[i][j]; + m->_I(0,0) += pm[i]*(q[i][1]*q[i][1] + q[i][2]*q[i][2]); + m->_I(1,1) += pm[i]*(q[i][0]*q[i][0] + q[i][2]*q[i][2]); + m->_I(2,2) += pm[i]*(q[i][0]*q[i][0] + q[i][1]*q[i][1]); + m->_I(0,1) -= pm[i]*(q[i][0]*q[i][1]); + m->_I(0,2) -= pm[i]*(q[i][0]*q[i][2]); + m->_I(1,2) -= pm[i]*(q[i][1]*q[i][2]); + } + for (j=0; j<3; j++) m->c[j] /= m->mass; + m->_I(1,0) = m->_I(0,1); + m->_I(2,0) = m->_I(0,2); + m->_I(2,1) = m->_I(1,2); +} + + +void reset_test() +{ + int i; + dMass m,anchor_m; + dReal q[NUM][3], pm[NUM]; // particle positions and masses + dReal pos1[3] = {1,0,1}; // point of reference (POR) + dReal pos2[3] = {-1,0,1}; // point of reference (POR) + + // make random particle positions (relative to POR) and masses + for (i=0; i= 100) { + // measure the difference between the anchor and test bodies + const dReal *w1 = dBodyGetAngularVel (anchor_body); + const dReal *w2 = dBodyGetAngularVel (test_body); + const dReal *q1 = dBodyGetQuaternion (anchor_body); + const dReal *q2 = dBodyGetQuaternion (test_body); + dReal maxdiff = dMaxDifference (w1,w2,1,3); + printf ("w-error = %.4e (%.2f,%.2f,%.2f) and (%.2f,%.2f,%.2f)\n", + maxdiff,w1[0],w1[1],w1[2],w2[0],w2[1],w2[2]); + maxdiff = dMaxDifference (q1,q2,1,4); + printf ("q-error = %.4e\n",maxdiff); + reset_test(); + } + } + + dReal sides[3] = {SIDE,SIDE,SIDE}; + dReal sides2[3] = {6*SIDE,6*SIDE,6*SIDE}; + dReal sides3[3] = {3*SIDE,3*SIDE,3*SIDE}; + dsSetColor (1,1,1); + dsDrawBox (dBodyGetPosition(anchor_body), dBodyGetRotation(anchor_body), + sides3); + dsSetColor (1,0,0); + dsDrawBox (dBodyGetPosition(test_body), dBodyGetRotation(test_body), sides2); + dsSetColor (1,1,0); + for (int i=0; i +#ifdef HAVE_UNISTD_H +#include +#endif +#include +#include +#include "texturepath.h" +#include "basket_geom.h" // this is our world mesh + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +// some constants + +#define RADIUS 0.14 + +// dynamics and collision objects (chassis, 3 wheels, environment) + +static dWorldID world; +static dSpaceID space; + +static dBodyID sphbody; +static dGeomID sphgeom; + +static dJointGroupID contactgroup; +static dGeomID world_mesh; + + +// this is called by dSpaceCollide when two objects in space are +// potentially colliding. + +static void nearCallback (void *data, dGeomID o1, dGeomID o2) +{ + assert(o1); + assert(o2); + + if (dGeomIsSpace(o1) || dGeomIsSpace(o2)) + { + fprintf(stderr,"testing space %p %p\n", (void*)o1, (void*)o2); + // colliding a space with something + dSpaceCollide2(o1,o2,data,&nearCallback); + // Note we do not want to test intersections within a space, + // only between spaces. + return; + } + +// fprintf(stderr,"testing geoms %p %p\n", o1, o2); + + const int N = 32; + dContact contact[N]; + int n = dCollide (o1,o2,N,&(contact[0].geom),sizeof(dContact)); + if (n > 0) + { + for (int i=0; i +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +#include "icosahedron_geom.h" + + +//<---- Convex Object +dReal planes[]= // planes for a cube, these should coincide with the face array + { + 1.0f ,0.0f ,0.0f ,0.25f, + 0.0f ,1.0f ,0.0f ,0.25f, + 0.0f ,0.0f ,1.0f ,0.25f, + -1.0f,0.0f ,0.0f ,0.25f, + 0.0f ,-1.0f,0.0f ,0.25f, + 0.0f ,0.0f ,-1.0f,0.25f + /* + 1.0f ,0.0f ,0.0f ,2.0f, + 0.0f ,1.0f ,0.0f ,1.0f, + 0.0f ,0.0f ,1.0f ,1.0f, + 0.0f ,0.0f ,-1.0f,1.0f, + 0.0f ,-1.0f,0.0f ,1.0f, + -1.0f,0.0f ,0.0f ,0.0f + */ + }; +const unsigned int planecount=6; + +dReal points[]= // points for a cube + { + 0.25f,0.25f,0.25f, // point 0 + -0.25f,0.25f,0.25f, // point 1 + + 0.25f,-0.25f,0.25f, // point 2 + -0.25f,-0.25f,0.25f,// point 3 + + 0.25f,0.25f,-0.25f, // point 4 + -0.25f,0.25f,-0.25f,// point 5 + + 0.25f,-0.25f,-0.25f,// point 6 + -0.25f,-0.25f,-0.25f,// point 7 + }; +const unsigned int pointcount=8; +unsigned int polygons[] = //Polygons for a cube (6 squares) + { + 4,0,2,6,4, // positive X + 4,1,0,4,5, // positive Y + 4,0,1,3,2, // positive Z + 4,3,1,5,7, // negative X + 4,2,3,7,6, // negative Y + 4,5,4,6,7, // negative Z + }; +//----> Convex Object + +// select correct drawing functions + +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawSphere dsDrawSphereD +#define dsDrawCylinder dsDrawCylinderD +#define dsDrawCapsule dsDrawCapsuleD +#define dsDrawConvex dsDrawConvexD +#endif + + +// some constants + +#define NUM 100 // max number of objects +#define DENSITY (5.0) // density of all objects +#define GPB 3 // maximum number of geometries per body +#define MAX_CONTACTS 8 // maximum number of contact points per body +#define MAX_FEEDBACKNUM 20 +#define GRAVITY REAL(0.5) + +// dynamics and collision objects + +struct MyObject { + dBodyID body; // the body + dGeomID geom[GPB]; // geometries representing this body +}; + +static int num=0; // number of objects in simulation +static int nextobj=0; // next object to recycle if num==NUM +static dWorldID world; +static dSpaceID space; +static MyObject obj[NUM]; +static dJointGroupID contactgroup; +static int selected = -1; // selected object +static int show_aabb = 0; // show geom AABBs? +static int show_contacts = 0; // show contact points? +static int random_pos = 1; // drop objects from random position? +static int write_world = 0; +static int show_body = 0; + +struct MyFeedback { + dJointFeedback fb; + bool first; +}; +static int doFeedback=0; +static MyFeedback feedbacks[MAX_FEEDBACKNUM]; +static int fbnum=0; + +// this is called by dSpaceCollide when two objects in space are +// potentially colliding. + +static void nearCallback (void *, dGeomID o1, dGeomID o2) +{ + int i; + // if (o1->body && o2->body) return; + + // exit without doing anything if the two bodies are connected by a joint + dBodyID b1 = dGeomGetBody(o1); + dBodyID b2 = dGeomGetBody(o2); + + if (b1 && b2 && dAreConnectedExcluding(b1,b2,dJointTypeContact)) + return; + + dContact contact[MAX_CONTACTS]; // up to MAX_CONTACTS contacts per box-box + for (i=0; i= 'A' && c <= 'Z') return c - ('a'-'A'); + else return c; +} + + +// called when a key pressed + +static void command(int cmd) +{ + dsizeint i; + int j,k; + dReal sides[3]; + dMass m; + bool setBody = false; + + cmd = locase(cmd); + if (cmd == 'b' || cmd == 's' || cmd == 'c' || cmd == 'x' || cmd == 'y' || cmd == 'v') { + if (num < NUM) { + // new object to be created + i = num; + num++; + } else { + // recycle existing object + i = nextobj++; + nextobj %= num; // wrap-around if needed + + // destroy the body and geoms for slot i + dBodyDestroy (obj[i].body); + obj[i].body = 0; + + for (k=0; k < GPB; k++) + if (obj[i].geom[k]) { + dGeomDestroy(obj[i].geom[k]); + obj[i].geom[k] = 0; + } + } + + obj[i].body = dBodyCreate(world); + + for (k=0; k<3; k++) + sides[k] = dRandReal()*0.5+0.1; + + dMatrix3 R; + if (random_pos) { + dBodySetPosition(obj[i].body, + dRandReal()*2-1,dRandReal()*2-1,dRandReal()+2); + dRFromAxisAndAngle(R,dRandReal()*2.0-1.0,dRandReal()*2.0-1.0, + dRandReal()*2.0-1.0,dRandReal()*10.0-5.0); + } else { + // higher than highest body position + dReal maxheight = 0; + for (k=0; k maxheight) + maxheight = pos[2]; + } + dBodySetPosition(obj[i].body, 0,0,maxheight+1); + dRSetIdentity(R); + //dRFromAxisAndAngle (R,0,0,1,/*dRandReal()*10.0-5.0*/0); + } + + dBodySetRotation(obj[i].body,R); + + if (cmd == 'b') { + + dMassSetBox(&m,DENSITY,sides[0],sides[1],sides[2]); + obj[i].geom[0] = dCreateBox(space,sides[0],sides[1],sides[2]); + + } else if (cmd == 'c') { + + sides[0] *= 0.5; + dMassSetCapsule(&m,DENSITY,3,sides[0],sides[1]); + obj[i].geom[0] = dCreateCapsule (space,sides[0],sides[1]); + + } else if (cmd == 'v') { + + dMassSetBox(&m,DENSITY,0.25,0.25,0.25); +#if 0 + obj[i].geom[0] = dCreateConvex(space, + planes, + planecount, + points, + pointcount, + polygons); +#else + obj[i].geom[0] = dCreateConvex(space, + Sphere_planes, + Sphere_planecount, + Sphere_points, + Sphere_pointcount, + Sphere_polygons); +#endif + + } else if (cmd == 'y') { + + dMassSetCylinder(&m,DENSITY,3,sides[0],sides[1]); + obj[i].geom[0] = dCreateCylinder(space,sides[0],sides[1]); + + } else if (cmd == 's') { + + sides[0] *= 0.5; + dMassSetSphere (&m,DENSITY,sides[0]); + obj[i].geom[0] = dCreateSphere (space,sides[0]); + + } else if (cmd == 'x') { + + setBody = true; + // start accumulating masses for the composite geometries + dMass m2; + dMassSetZero (&m); + + dReal dpos[GPB][3]; // delta-positions for composite geometries + dMatrix3 drot[GPB]; + + // set random delta positions + for (j=0; j= num) + selected = 0; + if (selected == -1) + selected = 0; + + } else if (cmd == 'd' && selected >= 0 && selected < num) { + + dBodyDisable(obj[selected].body); + + } else if (cmd == 'e' && selected >= 0 && selected < num) { + + dBodyEnable(obj[selected].body); + + } else if (cmd == 'a') { + + show_aabb = !show_aabb; + + } else if (cmd == 't') { + + show_contacts = !show_contacts; + + } else if (cmd == 'r') { + + random_pos = !random_pos; + } else if (cmd == '1') { + + write_world = 1; + + } else if (cmd == 'p'&& selected >= 0) { + + const dReal* pos = dGeomGetPosition(obj[selected].geom[0]); + const dReal* rot = dGeomGetRotation(obj[selected].geom[0]); + printf("POSITION:\n\t[%f,%f,%f]\n\n",pos[0],pos[1],pos[2]); + printf("ROTATION:\n\t[%f,%f,%f,%f]\n\t[%f,%f,%f,%f]\n\t[%f,%f,%f,%f]\n\n", + rot[0],rot[1],rot[2],rot[3], + rot[4],rot[5],rot[6],rot[7], + rot[8],rot[9],rot[10],rot[11]); + + } else if (cmd == 'f' && selected >= 0 && selected < num) { + + if (dBodyIsEnabled(obj[selected].body)) + doFeedback = 1; + + } +} + + +// draw a geom + +void drawGeom(dGeomID g, const dReal *pos, const dReal *R, int show_aabb) +{ + int i; + + if (!g) + return; + if (!pos) + pos = dGeomGetPosition(g); + if (!R) + R = dGeomGetRotation(g); + + int type = dGeomGetClass(g); + if (type == dBoxClass) { + + dVector3 sides; + dGeomBoxGetLengths (g,sides); + dsDrawBox(pos,R,sides); + + } else if (type == dSphereClass) { + + dsDrawSphere(pos,R,dGeomSphereGetRadius(g)); + + } else if (type == dCapsuleClass) { + + dReal radius,length; + dGeomCapsuleGetParams(g,&radius,&length); + dsDrawCapsule(pos,R,length,radius); + + } else if (type == dConvexClass) { + +#if 0 + dsDrawConvex(pos,R,planes, + planecount, + points, + pointcount, + polygons); +#else + dsDrawConvex(pos,R, + Sphere_planes, + Sphere_planecount, + Sphere_points, + Sphere_pointcount, + Sphere_polygons); +#endif + + } else if (type == dCylinderClass) { + + dReal radius,length; + dGeomCylinderGetParams(g,&radius,&length); + dsDrawCylinder(pos,R,length,radius); + + } + + if (show_body) { + dBodyID body = dGeomGetBody(g); + if (body) { + const dReal *bodypos = dBodyGetPosition(body); + const dReal *bodyr = dBodyGetRotation(body); + dReal bodySides[3] = { 0.1, 0.1, 0.1 }; + dsSetColorAlpha(0,1,0,1); + dsDrawBox(bodypos,bodyr,bodySides); + } + } + + if (show_aabb) { + // draw the bounding box for this geom + dReal aabb[6]; + dGeomGetAABB(g,aabb); + dVector3 bbpos; + for (i=0; i<3; i++) + bbpos[i] = 0.5*(aabb[i*2] + aabb[i*2+1]); + dVector3 bbsides; + for (i=0; i<3; i++) + bbsides[i] = aabb[i*2+1] - aabb[i*2]; + dMatrix3 RI; + dRSetIdentity (RI); + dsSetColorAlpha(1,0,0,0.5); + dsDrawBox(bbpos,RI,bbsides); + } +} + + +// simulation loop + +static void simLoop(int pause) +{ + dSpaceCollide(space, 0, &nearCallback); + + if (!pause) + dWorldQuickStep(world, 0.02); + + if (write_world) { + FILE *f = fopen("state.dif","wt"); + if (f) { + dWorldExportDIF(world,f,"X"); + fclose (f); + } + write_world = 0; + } + + + if (doFeedback) { + if (fbnum>MAX_FEEDBACKNUM) + printf("joint feedback buffer overflow!\n"); + else { + dVector3 sum = {0, 0, 0}; + printf("\n"); + for (int i=0; i +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +// select correct drawing functions + +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawSphere dsDrawSphereD +#define dsDrawCylinder dsDrawCylinderD +#define dsDrawCapsule dsDrawCapsuleD +#endif + + +// some constants + +#define LENGTH 0.7 // chassis length +#define WIDTH 0.5 // chassis width +#define HEIGHT 0.2 // chassis height +#define RADIUS 0.18 // wheel radius +#define STARTZ 0.5 // starting height of chassis +#define CMASS 1 // chassis mass +#define WMASS 0.2 // wheel mass + +static const dVector3 yunit = { 0, 1, 0 }, zunit = { 0, 0, 1 }; + + +// dynamics and collision objects (chassis, 3 wheels, environment) + +static dWorldID world; +static dSpaceID space; +static dBodyID body[4]; +static dJointID joint[3]; // joint[0] is the front wheel +static dJointGroupID contactgroup; +static dGeomID ground; +static dSpaceID car_space; +static dGeomID box[1]; +static dGeomID sphere[3]; +static dGeomID ground_box; + + +// things that the user controls + +static dReal speed=0,steer=0; // user commands + + +// this is called by dSpaceCollide when two objects in space are +// potentially colliding. + +static void nearCallback (void *, dGeomID o1, dGeomID o2) +{ + int i,n; + + // only collide things with the ground + int g1 = (o1 == ground || o1 == ground_box); + int g2 = (o2 == ground || o2 == ground_box); + if (!(g1 ^ g2)) return; + + const int N = 10; + dContact contact[N]; + n = dCollide (o1,o2,N,&contact[0].geom,sizeof(dContact)); + if (n > 0) { + for (i=0; i 0.1) v = 0.1; + if (v < -0.1) v = -0.1; + v *= 10.0; + dJointSetHinge2Param (joint[0],dParamVel,v); + dJointSetHinge2Param (joint[0],dParamFMax,0.2); + dJointSetHinge2Param (joint[0],dParamLoStop,-0.75); + dJointSetHinge2Param (joint[0],dParamHiStop,0.75); + dJointSetHinge2Param (joint[0],dParamFudgeFactor,0.1); + + dSpaceCollide (space,0,&nearCallback); + dWorldStep (world,0.05); + + // remove all contact joints + dJointGroupEmpty (contactgroup); + + } + + dsSetColor (0,1,1); + dsSetTexture (DS_WOOD); + dReal sides[3] = {LENGTH,WIDTH,HEIGHT}; + dsDrawBox (dBodyGetPosition(body[0]),dBodyGetRotation(body[0]),sides); + dsSetColor (1,1,1); + for (i=1; i<=3; i++) dsDrawCylinder (dBodyGetPosition(body[i]), + dBodyGetRotation(body[i]),0.02f,RADIUS); + + dVector3 ss; + dGeomBoxGetLengths (ground_box,ss); + dsDrawBox (dGeomGetPosition(ground_box),dGeomGetRotation(ground_box),ss); + +} + + +int main (int argc, char **argv) +{ + int i; + dMass m; + + // setup pointers to drawstuff callback functions + dsFunctions fn; + fn.version = DS_VERSION; + fn.start = &start; + fn.step = &simLoop; + fn.command = &command; + fn.stop = 0; + fn.path_to_textures = DRAWSTUFF_TEXTURE_PATH; + + // create world + dInitODE2(0); + world = dWorldCreate(); + space = dHashSpaceCreate (0); + contactgroup = dJointGroupCreate (0); + dWorldSetGravity (world,0,0,-0.5); + ground = dCreatePlane (space,0,0,1,0); + + // chassis body + body[0] = dBodyCreate (world); + dBodySetPosition (body[0],0,0,STARTZ); + dMassSetBox (&m,1,LENGTH,WIDTH,HEIGHT); + dMassAdjust (&m,CMASS); + dBodySetMass (body[0],&m); + box[0] = dCreateBox (0,LENGTH,WIDTH,HEIGHT); + dGeomSetBody (box[0],body[0]); + + // wheel bodies + for (i=1; i<=3; i++) { + body[i] = dBodyCreate (world); + dQuaternion q; + dQFromAxisAndAngle (q,1,0,0,M_PI*0.5); + dBodySetQuaternion (body[i],q); + dMassSetSphere (&m,1,RADIUS); + dMassAdjust (&m,WMASS); + dBodySetMass (body[i],&m); + sphere[i-1] = dCreateSphere (0,RADIUS); + dGeomSetBody (sphere[i-1],body[i]); + } + dBodySetPosition (body[1],0.5*LENGTH,0,STARTZ-HEIGHT*0.5); + dBodySetPosition (body[2],-0.5*LENGTH, WIDTH*0.5,STARTZ-HEIGHT*0.5); + dBodySetPosition (body[3],-0.5*LENGTH,-WIDTH*0.5,STARTZ-HEIGHT*0.5); + + // front and back wheel hinges + for (i=0; i<3; i++) { + joint[i] = dJointCreateHinge2 (world,0); + dJointAttach (joint[i],body[0],body[i+1]); + const dReal *a = dBodyGetPosition (body[i+1]); + dJointSetHinge2Anchor (joint[i],a[0],a[1],a[2]); + dJointSetHinge2Axes (joint[i], zunit, yunit); + } + + // set joint suspension + for (i=0; i<3; i++) { + dJointSetHinge2Param (joint[i],dParamSuspensionERP,0.4); + dJointSetHinge2Param (joint[i],dParamSuspensionCFM,0.8); + } + + // lock back wheels along the steering axis + for (i=1; i<3; i++) { + // set stops to make sure wheels always stay in alignment + dJointSetHinge2Param (joint[i],dParamLoStop,0); + dJointSetHinge2Param (joint[i],dParamHiStop,0); + // the following alternative method is no good as the wheels may get out + // of alignment: + // dJointSetHinge2Param (joint[i],dParamVel,0); + // dJointSetHinge2Param (joint[i],dParamFMax,dInfinity); + } + + // create car space and add it to the top level space + car_space = dSimpleSpaceCreate (space); + dSpaceSetCleanup (car_space,0); + dSpaceAdd (car_space,box[0]); + dSpaceAdd (car_space,sphere[0]); + dSpaceAdd (car_space,sphere[1]); + dSpaceAdd (car_space,sphere[2]); + + // environment + ground_box = dCreateBox (space,2,1.5,1); + dMatrix3 R; + dRFromAxisAndAngle (R,0,1,0,-0.15); + dGeomSetPosition (ground_box,2,0,-0.34); + dGeomSetRotation (ground_box,R); + + // run simulation + dsSimulationLoop (argc,argv,352,288,&fn); + + dGeomDestroy (box[0]); + dGeomDestroy (sphere[0]); + dGeomDestroy (sphere[1]); + dGeomDestroy (sphere[2]); + dJointGroupDestroy (contactgroup); + dSpaceDestroy (space); + dWorldDestroy (world); + dCloseODE(); + return 0; +} diff --git a/libs/ode-0.16.1/ode/demo/demo_cards.cpp b/libs/ode-0.16.1/ode/demo/demo_cards.cpp new file mode 100644 index 0000000..17284ba --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/demo_cards.cpp @@ -0,0 +1,237 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#include +#include +#include +#include "texturepath.h" + +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#endif + +static int levels = 5; +static int ncards = 0; + +static dSpaceID space; +static dWorldID world; +static dJointGroupID contactgroup; + +struct Card { + dBodyID body; + dGeomID geom; + static const dReal sides[3]; + + Card() + { + body = dBodyCreate(world); + geom = dCreateBox(space, sides[0], sides[1], sides[2]); + dGeomSetBody(geom, body); + dGeomSetData(geom, this); + dMass mass; + mass.setBox(1, sides[0], sides[1], sides[2]); + dBodySetMass(body, &mass); + } + + ~Card() + { + dBodyDestroy(body); + dGeomDestroy(geom); + } + + void draw() const + { + dsDrawBox(dBodyGetPosition(body), + dBodyGetRotation(body), sides); + } +}; +static const dReal cwidth=.5, cthikness=.02, clength=1; +const dReal Card::sides[3] = { cwidth, cthikness, clength }; + + +std::vector cards; + +int getncards(int levels) +{ + return (3*levels*levels + levels) / 2; +} + +void place_cards() +{ + ncards = getncards(levels); + // destroy removed cards (if any) + int oldcards = cards.size(); + for (int i=ncards; ibody, + 0, + -n*hstep + hstep*i, + height + ); + if (i%2) + dBodySetRotation(cards[c]->body, left); + else + dBodySetRotation(cards[c]->body, right); + } + + if (n==1) // top of the house + break; + + // horizontal cards + for (int i=0; ibody, + 0, + -(n-1 - (clength-hstep)/2)*hstep + 2*hstep*i, + height + vstep/2); + dBodySetRotation(cards[c]->body, hrot); + } + } + +} + + +void start() +{ + puts("Controls:"); + puts(" SPACE - reposition cards"); + puts(" - - one less level"); + puts(" = - one more level"); +} + +static void nearCallback (void *, dGeomID o1, dGeomID o2) +{ + // exit without doing anything if the two bodies are connected by a joint + dBodyID b1 = dGeomGetBody(o1); + dBodyID b2 = dGeomGetBody(o2); + + const int MAX_CONTACTS = 8; + dContact contact[MAX_CONTACTS]; + + int numc = dCollide (o1, o2, MAX_CONTACTS, + &contact[0].geom, + sizeof(dContact)); + + for (int i=0; idraw(); + } + +} + +void command(int c) +{ + switch (c) { + case '=': + levels++; + place_cards(); + break; + case '-': + levels--; + if (levels <= 0) + levels++; + place_cards(); + break; + case ' ': + place_cards(); + break; + } +} + +int main(int argc, char **argv) +{ + dInitODE(); + + // setup pointers to drawstuff callback functions + dsFunctions fn; + fn.version = DS_VERSION; + fn.start = &start; + fn.step = &simLoop; + fn.command = &command; + fn.stop = 0; + fn.path_to_textures = DRAWSTUFF_TEXTURE_PATH; + + + world = dWorldCreate(); + dWorldSetGravity(world, 0, 0, -0.5); + dWorldSetQuickStepNumIterations(world, 50); // <-- increase for more stability + + space = dSimpleSpaceCreate(0); + contactgroup = dJointGroupCreate(0); + dGeomID ground = dCreatePlane(space, 0, 0, 1, 0); + + place_cards(); + + // run simulation + dsSimulationLoop (argc, argv, 640, 480, &fn); + + levels = 0; + place_cards(); + + dJointGroupDestroy(contactgroup); + dWorldDestroy(world); + dGeomDestroy(ground); + dSpaceDestroy(space); + + dCloseODE(); +} diff --git a/libs/ode-0.16.1/ode/demo/demo_chain1.c b/libs/ode-0.16.1/ode/demo/demo_chain1.c new file mode 100644 index 0000000..a6d7b38 --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/demo_chain1.c @@ -0,0 +1,171 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +/* exercise the C interface */ + +#include +#include "ode/ode.h" +#include "drawstuff/drawstuff.h" +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) /* for VC++, no precision loss complaints */ +#endif + +/* select correct drawing functions */ + +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawSphere dsDrawSphereD +#define dsDrawCylinder dsDrawCylinderD +#define dsDrawCapsule dsDrawCapsuleD +#endif + + +/* some constants */ + +#define NUM 10 /* number of boxes */ +#define SIDE (0.2) /* side length of a box */ +#define MASS (1.0) /* mass of a box */ +#define RADIUS (0.1732f) /* sphere radius */ + + +/* dynamics and collision objects */ + +static dWorldID world; +static dSpaceID space; +static dBodyID body[NUM]; +static dJointID joint[NUM-1]; +static dJointGroupID contactgroup; +static dGeomID sphere[NUM]; + + +/* this is called by dSpaceCollide when two objects in space are + * potentially colliding. + */ + +static void nearCallback (void *data, dGeomID o1, dGeomID o2) +{ + /* exit without doing anything if the two bodies are connected by a joint */ + dBodyID b1,b2; + dContact contact; + (void)data; + + b1 = dGeomGetBody(o1); + b2 = dGeomGetBody(o2); + if (b1 && b2 && dAreConnected (b1,b2)) return; + + contact.surface.mode = 0; + contact.surface.mu = 0.1; + contact.surface.mu2 = 0; + if (dCollide (o1,o2,1,&contact.geom,sizeof(dContactGeom))) { + dJointID c = dJointCreateContact (world,contactgroup,&contact); + dJointAttach (c,b1,b2); + } +} + + +/* start simulation - set viewpoint */ + +static void start() +{ + static float xyz[3] = {2.1640f,-1.3079f,1.7600f}; + static float hpr[3] = {125.5000f,-17.0000f,0.0000f}; + + dAllocateODEDataForThread(dAllocateMaskAll); + dsSetViewpoint (xyz,hpr); +} + + +/* simulation loop */ + +static void simLoop (int pause) +{ + int i; + if (!pause) { + static double angle = 0; + angle += 0.05; + dBodyAddForce (body[NUM-1],0,0,1.5*(sin(angle)+1.0)); + + dSpaceCollide (space,0,&nearCallback); + dWorldStep (world,0.05); + + /* remove all contact joints */ + dJointGroupEmpty (contactgroup); + } + + dsSetColor (1,1,0); + dsSetTexture (DS_WOOD); + for (i=0; i +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +// select correct drawing functions + +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawSphere dsDrawSphereD +#define dsDrawCylinder dsDrawCylinderD +#define dsDrawCapsule dsDrawCapsuleD +#endif + + +// some constants + +#define NUM 10 // number of boxes +#define SIDE (0.2) // side length of a box +#define MASS (1.0) // mass of a box +#define RADIUS (0.1732f) // sphere radius + +//using namespace ode; + +// dynamics and collision objects + +static dWorld world; +static dSimpleSpace space (0); +static dBody body[NUM]; +static dBallJoint joint[NUM-1]; +static dJointGroup contactgroup; +static dBox box[NUM]; + + +// this is called by space.collide when two objects in space are +// potentially colliding. + +static void nearCallback (void *, dGeomID o1, dGeomID o2) +{ + // exit without doing anything if the two bodies are connected by a joint + dBodyID b1 = dGeomGetBody(o1); + dBodyID b2 = dGeomGetBody(o2); + if (b1 && b2 && dAreConnected (b1,b2)) return; + + // @@@ it's still more convenient to use the C interface here. + + dContact contact; + contact.surface.mode = 0; + contact.surface.mu = dInfinity; + if (dCollide (o1,o2,1,&contact.geom,sizeof(dContactGeom))) { + dJointID c = dJointCreateContact (world.id(),contactgroup.id(),&contact); + dJointAttach (c,b1,b2); + } +} + + +// start simulation - set viewpoint + +static void start() +{ + dAllocateODEDataForThread(dAllocateMaskAll); + + static float xyz[3] = {2.1640f,-1.3079f,1.7600f}; + static float hpr[3] = {125.5000f,-17.0000f,0.0000f}; + dsSetViewpoint (xyz,hpr); +} + + +// simulation loop + +static void simLoop (int pause) +{ + if (!pause) { + static double angle = 0; + angle += 0.05; + body[NUM-1].addForce (0,0,1.5*(sin(angle)+1.0)); + + space.collide (0,&nearCallback); + world.step (0.05); + + // remove all contact joints + contactgroup.empty(); + } + + dReal sides[3] = {SIDE,SIDE,SIDE}; + dsSetColor (1,1,0); + dsSetTexture (DS_WOOD); + for (int i=0; i +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif +// select correct drawing functions +#ifdef dDOUBLE +#define dsDrawSphere dsDrawSphereD +#define dsDrawBox dsDrawBoxD +#define dsDrawLine dsDrawLineD +#define dsDrawCapsule dsDrawCapsuleD +#define dsDrawCylinder dsDrawCylinderD +#endif + +//**************************************************************************** +// test infrastructure, including constants and macros + +#define TEST_REPS1 1000 // run each test this many times (first batch) +#define TEST_REPS2 10000 // run each test this many times (second batch) +const dReal tol = 1e-8; // tolerance used for numerical checks +#define MAX_TESTS 1000 // maximum number of test slots +#define Z_OFFSET 2 // z offset for drawing (to get above ground) + +//using namespace ode; + +// test function. returns 1 if the test passed or 0 if it failed +typedef int test_function_t(); + +struct TestSlot { + int number; // number of test + const char *name; // name of test + int failcount; + test_function_t *test_fn; + int last_failed_line; +}; +TestSlot testslot[MAX_TESTS]; + + +// globals used by the test functions +int graphical_test=0; // show graphical results of this test, 0=none +int current_test; // currently execiting test +int draw_all_objects_called; + + +#define MAKE_TEST(number,function) \ + if (testslot[number].name) dDebug (0,"test number already used"); \ + if (number <= 0 || number >= MAX_TESTS) dDebug (0,"bad test number"); \ + testslot[number].name = # function; \ + testslot[number].test_fn = function; + +#define FAILED() { if (graphical_test==0) { \ + testslot[current_test].last_failed_line=__LINE__; return 0; } } +#define PASSED() { return 1; } + +//**************************************************************************** +// globals + +/* int dBoxBox (const dVector3 p1, const dMatrix3 R1, + const dVector3 side1, const dVector3 p2, + const dMatrix3 R2, const dVector3 side2, + dVector3 normal, dReal *depth, int *code, + int maxc, dContactGeom *contact, int skip); */ + +void dLineClosestApproach (const dVector3 pa, const dVector3 ua, + const dVector3 pb, const dVector3 ub, + dReal *alpha, dReal *beta); + +//**************************************************************************** +// draw all objects in a space, and draw all the collision contact points + +void nearCallback (void *, dGeomID o1, dGeomID o2) +{ + int i,j,n; + const int N = 100; + dContactGeom contact[N]; + + if (dGeomGetClass (o2) == dRayClass) { + n = dCollide (o2,o1,N,&contact[0],sizeof(dContactGeom)); + } + else { + n = dCollide (o1,o2,N,&contact[0],sizeof(dContactGeom)); + } + if (n > 0) { + dMatrix3 RI; + dRSetIdentity (RI); + const dReal ss[3] = {0.01,0.01,0.01}; + for (i=0; i tol) FAILED(); + + // ********** test point on surface has depth 0 + + for (j=0; j<3; j++) q[j] = dRandReal()-0.5; + dNormalize3 (q); + for (j=0; j<3; j++) q[j] = q[j]*r + p[j]; + if (dFabs(dGeomSpherePointDepth (sphere,q[0],q[1],q[2])) > tol) FAILED(); + + // ********** test point at random depth + + d = (dRandReal()*2-1) * r; + for (j=0; j<3; j++) q[j] = dRandReal()-0.5; + dNormalize3 (q); + for (j=0; j<3; j++) q[j] = q[j]*(r-d) + p[j]; + if (dFabs(dGeomSpherePointDepth (sphere,q[0],q[1],q[2])-d) > tol) FAILED(); + + PASSED(); +} + + +int test_box_point_depth() +{ + int i,j; + dVector3 s,p,q,q2; // s = box sides + dMatrix3 R; + dReal ss,d; // ss = smallest side + + dSimpleSpace space(0); + dGeomID box = dCreateBox (0,1,1,1); + dSpaceAdd (space,box); + + // ********** make a random box + + for (j=0; j<3; j++) s[j] = dRandReal() + 0.1; + dGeomBoxSetLengths (box,s[0],s[1],s[2]); + dMakeRandomVector (p,3,1.0); + dGeomSetPosition (box,p[0],p[1],p[2]); + dRFromAxisAndAngle (R,dRandReal()*2-1,dRandReal()*2-1, + dRandReal()*2-1,dRandReal()*10-5); + dGeomSetRotation (box,R); + + // ********** test center point has depth of smallest side + + ss = 1e9; + for (j=0; j<3; j++) if (s[j] < ss) ss = s[j]; + if (dFabs(dGeomBoxPointDepth (box,p[0],p[1],p[2]) - 0.5*ss) > tol) + FAILED(); + + // ********** test point on surface has depth 0 + + for (j=0; j<3; j++) q[j] = (dRandReal()-0.5)*s[j]; + i = dRandInt (3); + if (dRandReal() > 0.5) q[i] = 0.5*s[i]; else q[i] = -0.5*s[i]; + dMultiply0 (q2,dGeomGetRotation(box),q,3,3,1); + for (j=0; j<3; j++) q2[j] += p[j]; + if (dFabs(dGeomBoxPointDepth (box,q2[0],q2[1],q2[2])) > tol) FAILED(); + + // ********** test points outside box have -ve depth + + for (j=0; j<3; j++) { + q[j] = 0.5*s[j] + dRandReal() + 0.01; + if (dRandReal() > 0.5) q[j] = -q[j]; + } + dMultiply0 (q2,dGeomGetRotation(box),q,3,3,1); + for (j=0; j<3; j++) q2[j] += p[j]; + if (dGeomBoxPointDepth (box,q2[0],q2[1],q2[2]) >= 0) FAILED(); + + // ********** test points inside box have +ve depth + + for (j=0; j<3; j++) q[j] = s[j] * 0.99 * (dRandReal()-0.5); + dMultiply0 (q2,dGeomGetRotation(box),q,3,3,1); + for (j=0; j<3; j++) q2[j] += p[j]; + if (dGeomBoxPointDepth (box,q2[0],q2[1],q2[2]) <= 0) FAILED(); + + // ********** test random depth of point aligned along axis (up to ss deep) + + i = dRandInt (3); + for (j=0; j<3; j++) q[j] = 0; + d = (dRandReal()*(ss*0.5+1)-1); + q[i] = s[i]*0.5 - d; + if (dRandReal() > 0.5) q[i] = -q[i]; + dMultiply0 (q2,dGeomGetRotation(box),q,3,3,1); + for (j=0; j<3; j++) q2[j] += p[j]; + if (dFabs(dGeomBoxPointDepth (box,q2[0],q2[1],q2[2]) - d) >= tol) FAILED(); + + PASSED(); +} + + +int test_ccylinder_point_depth() +{ + int j; + dVector3 p,a; + dMatrix3 R; + dReal r,l,beta,x,y,d; + + dSimpleSpace space(0); + dGeomID ccyl = dCreateCapsule (0,1,1); + dSpaceAdd (space,ccyl); + + // ********** make a random ccyl + + r = dRandReal()*0.5 + 0.01; + l = dRandReal()*1 + 0.01; + dGeomCapsuleSetParams (ccyl,r,l); + dMakeRandomVector (p,3,1.0); + dGeomSetPosition (ccyl,p[0],p[1],p[2]); + dRFromAxisAndAngle (R,dRandReal()*2-1,dRandReal()*2-1, + dRandReal()*2-1,dRandReal()*10-5); + dGeomSetRotation (ccyl,R); + + // ********** test point on axis has depth of 'radius' + + beta = dRandReal()-0.5; + for (j=0; j<3; j++) a[j] = p[j] + l*beta*R[j*4+2]; + if (dFabs(dGeomCapsulePointDepth (ccyl,a[0],a[1],a[2]) - r) >= tol) + FAILED(); + + // ********** test point on surface (excluding caps) has depth 0 + + beta = dRandReal()*2*M_PI; + x = r*sin(beta); + y = r*cos(beta); + beta = dRandReal()-0.5; + for (j=0; j<3; j++) a[j] = p[j] + x*R[j*4+0] + y*R[j*4+1] + l*beta*R[j*4+2]; + if (dFabs(dGeomCapsulePointDepth (ccyl,a[0],a[1],a[2])) >= tol) FAILED(); + + // ********** test point on surface of caps has depth 0 + + for (j=0; j<3; j++) a[j] = dRandReal()-0.5; + dNormalize3 (a); + if (dCalcVectorDot3_14(a,R+2) > 0) { + for (j=0; j<3; j++) a[j] = p[j] + a[j]*r + l*0.5*R[j*4+2]; + } + else { + for (j=0; j<3; j++) a[j] = p[j] + a[j]*r - l*0.5*R[j*4+2]; + } + if (dFabs(dGeomCapsulePointDepth (ccyl,a[0],a[1],a[2])) >= tol) FAILED(); + + // ********** test point inside ccyl has positive depth + + for (j=0; j<3; j++) a[j] = dRandReal()-0.5; + dNormalize3 (a); + beta = dRandReal()-0.5; + for (j=0; j<3; j++) a[j] = p[j] + a[j]*r*0.99 + l*beta*R[j*4+2]; + if (dGeomCapsulePointDepth (ccyl,a[0],a[1],a[2]) < 0) FAILED(); + + // ********** test point depth (1) + + d = (dRandReal()*2-1) * r; + beta = dRandReal()*2*M_PI; + x = (r-d)*sin(beta); + y = (r-d)*cos(beta); + beta = dRandReal()-0.5; + for (j=0; j<3; j++) a[j] = p[j] + x*R[j*4+0] + y*R[j*4+1] + l*beta*R[j*4+2]; + if (dFabs(dGeomCapsulePointDepth (ccyl,a[0],a[1],a[2]) - d) >= tol) + FAILED(); + + // ********** test point depth (2) + + d = (dRandReal()*2-1) * r; + for (j=0; j<3; j++) a[j] = dRandReal()-0.5; + dNormalize3 (a); + if (dCalcVectorDot3_14(a,R+2) > 0) { + for (j=0; j<3; j++) a[j] = p[j] + a[j]*(r-d) + l*0.5*R[j*4+2]; + } + else { + for (j=0; j<3; j++) a[j] = p[j] + a[j]*(r-d) - l*0.5*R[j*4+2]; + } + if (dFabs(dGeomCapsulePointDepth (ccyl,a[0],a[1],a[2]) - d) >= tol) + FAILED(); + + PASSED(); +} + + +int test_plane_point_depth() +{ + int j; + dVector3 n,p,q,a,b; // n = plane normal + dReal d; + + dSimpleSpace space(0); + dGeomID plane = dCreatePlane (0,0,0,1,0); + dSpaceAdd (space,plane); + + // ********** make a random plane + + for (j=0; j<3; j++) n[j] = dRandReal() - 0.5; + dNormalize3 (n); + d = dRandReal() - 0.5; + dGeomPlaneSetParams (plane,n[0],n[1],n[2],d); + dPlaneSpace (n,p,q); + + // ********** test point on plane has depth 0 + + a[0] = dRandReal() - 0.5; + a[1] = dRandReal() - 0.5; + a[2] = 0; + for (j=0; j<3; j++) b[j] = a[0]*p[j] + a[1]*q[j] + (a[2]+d)*n[j]; + if (dFabs(dGeomPlanePointDepth (plane,b[0],b[1],b[2])) >= tol) FAILED(); + + // ********** test arbitrary depth point + + a[0] = dRandReal() - 0.5; + a[1] = dRandReal() - 0.5; + a[2] = dRandReal() - 0.5; + for (j=0; j<3; j++) b[j] = a[0]*p[j] + a[1]*q[j] + (a[2]+d)*n[j]; + if (dFabs(dGeomPlanePointDepth (plane,b[0],b[1],b[2]) + a[2]) >= tol) + FAILED(); + + // ********** test depth-1 point + + a[0] = dRandReal() - 0.5; + a[1] = dRandReal() - 0.5; + a[2] = -1; + for (j=0; j<3; j++) b[j] = a[0]*p[j] + a[1]*q[j] + (a[2]+d)*n[j]; + if (dFabs(dGeomPlanePointDepth (plane,b[0],b[1],b[2]) - 1) >= tol) FAILED(); + + PASSED(); +} + +//**************************************************************************** +// ray tests + +int test_ray_and_sphere() +{ + int j; + dContactGeom contact; + dVector3 p,q,q2,n,v1; + dMatrix3 R; + dReal r,k; + + dSimpleSpace space(0); + dGeomID ray = dCreateRay (0,0); + dGeomID sphere = dCreateSphere (0,1); + dSpaceAdd (space,ray); + dSpaceAdd (space,sphere); + + // ********** make a random sphere of radius r at position p + + r = dRandReal()+0.1; + dGeomSphereSetRadius (sphere,r); + dMakeRandomVector (p,3,1.0); + dGeomSetPosition (sphere,p[0],p[1],p[2]); + dRFromAxisAndAngle (R,dRandReal()*2-1,dRandReal()*2-1, + dRandReal()*2-1,dRandReal()*10-5); + dGeomSetRotation (sphere,R); + + // ********** test zero length ray just inside sphere + + dGeomRaySetLength (ray,0); + dMakeRandomVector (q,3,1.0); + dNormalize3 (q); + for (j=0; j<3; j++) q[j] = 0.99*r * q[j] + p[j]; + dGeomSetPosition (ray,q[0],q[1],q[2]); + dRFromAxisAndAngle (R,dRandReal()*2-1,dRandReal()*2-1, + dRandReal()*2-1,dRandReal()*10-5); + dGeomSetRotation (ray,R); + if (dCollide (ray,sphere,1,&contact,sizeof(dContactGeom)) != 0) FAILED(); + + // ********** test zero length ray just outside that sphere + + dGeomRaySetLength (ray,0); + dMakeRandomVector (q,3,1.0); + dNormalize3 (q); + for (j=0; j<3; j++) q[j] = 1.01*r * q[j] + p[j]; + dGeomSetPosition (ray,q[0],q[1],q[2]); + dRFromAxisAndAngle (R,dRandReal()*2-1,dRandReal()*2-1, + dRandReal()*2-1,dRandReal()*10-5); + dGeomSetRotation (ray,R); + if (dCollide (ray,sphere,1,&contact,sizeof(dContactGeom)) != 0) FAILED(); + + // ********** test finite length ray totally contained inside the sphere + + dMakeRandomVector (q,3,1.0); + dNormalize3 (q); + k = dRandReal(); + for (j=0; j<3; j++) q[j] = k*r*0.99 * q[j] + p[j]; + dMakeRandomVector (q2,3,1.0); + dNormalize3 (q2); + k = dRandReal(); + for (j=0; j<3; j++) q2[j] = k*r*0.99 * q2[j] + p[j]; + for (j=0; j<3; j++) n[j] = q2[j] - q[j]; + dNormalize3 (n); + dGeomRaySet (ray,q[0],q[1],q[2],n[0],n[1],n[2]); + dGeomRaySetLength (ray,dCalcPointsDistance3(q,q2)); + if (dCollide (ray,sphere,1,&contact,sizeof(dContactGeom)) != 0) FAILED(); + + // ********** test finite length ray totally outside the sphere + + dMakeRandomVector (q,3,1.0); + dNormalize3 (q); + do { + dMakeRandomVector (n,3,1.0); + dNormalize3 (n); + } + while (dCalcVectorDot3(n,q) < 0); // make sure normal goes away from sphere + for (j=0; j<3; j++) q[j] = 1.01*r * q[j] + p[j]; + dGeomRaySet (ray,q[0],q[1],q[2],n[0],n[1],n[2]); + dGeomRaySetLength (ray,100); + if (dCollide (ray,sphere,1,&contact,sizeof(dContactGeom)) != 0) FAILED(); + + // ********** test ray from outside to just above surface + + dMakeRandomVector (q,3,1.0); + dNormalize3 (q); + for (j=0; j<3; j++) n[j] = -q[j]; + for (j=0; j<3; j++) q2[j] = 2*r * q[j] + p[j]; + dGeomRaySet (ray,q2[0],q2[1],q2[2],n[0],n[1],n[2]); + dGeomRaySetLength (ray,0.99*r); + if (dCollide (ray,sphere,1,&contact,sizeof(dContactGeom)) != 0) FAILED(); + + // ********** test ray from outside to just below surface + + dGeomRaySetLength (ray,1.01*r); + if (dCollide (ray,sphere,1,&contact,sizeof(dContactGeom)) != 1) FAILED(); + for (j=0; j<3; j++) q2[j] = r * q[j] + p[j]; + if (dCalcPointsDistance3 (contact.pos,q2) > tol) FAILED(); + + // ********** test contact point distance for random rays + + dMakeRandomVector (q,3,1.0); + dNormalize3 (q); + k = dRandReal()+0.5; + for (j=0; j<3; j++) q[j] = k*r * q[j] + p[j]; + dMakeRandomVector (n,3,1.0); + dNormalize3 (n); + dGeomRaySet (ray,q[0],q[1],q[2],n[0],n[1],n[2]); + dGeomRaySetLength (ray,100); + if (dCollide (ray,sphere,1,&contact,sizeof(dContactGeom))) { + k = dCalcPointsDistance3 (contact.pos,dGeomGetPosition(sphere)); + if (dFabs(k - r) > tol) FAILED(); + // also check normal signs + if (dCalcVectorDot3 (n,contact.normal) > 0) FAILED(); + // also check depth of contact point + if (dFabs (dGeomSpherePointDepth + (sphere,contact.pos[0],contact.pos[1],contact.pos[2])) > tol) + FAILED(); + + draw_all_objects (space); + } + + // ********** test tangential grazing - miss + + dMakeRandomVector (q,3,1.0); + dNormalize3 (q); + dPlaneSpace (q,n,v1); + for (j=0; j<3; j++) q[j] = 1.01*r * q[j] + p[j]; + for (j=0; j<3; j++) q[j] -= n[j]; + dGeomRaySet (ray,q[0],q[1],q[2],n[0],n[1],n[2]); + dGeomRaySetLength (ray,2); + if (dCollide (ray,sphere,1,&contact,sizeof(dContactGeom)) != 0) FAILED(); + + // ********** test tangential grazing - hit + + dMakeRandomVector (q,3,1.0); + dNormalize3 (q); + dPlaneSpace (q,n,v1); + for (j=0; j<3; j++) q[j] = 0.99*r * q[j] + p[j]; + for (j=0; j<3; j++) q[j] -= n[j]; + dGeomRaySet (ray,q[0],q[1],q[2],n[0],n[1],n[2]); + dGeomRaySetLength (ray,2); + if (dCollide (ray,sphere,1,&contact,sizeof(dContactGeom)) != 1) FAILED(); + + PASSED(); +} + + +int test_ray_and_box() +{ + int i,j; + dContactGeom contact; + dVector3 s,p,q,n,q2,q3,q4; // s = box sides + dMatrix3 R; + dReal k; + + dSimpleSpace space(0); + dGeomID ray = dCreateRay (0,0); + dGeomID box = dCreateBox (0,1,1,1); + dSpaceAdd (space,ray); + dSpaceAdd (space,box); + + // ********** make a random box + + for (j=0; j<3; j++) s[j] = dRandReal() + 0.1; + dGeomBoxSetLengths (box,s[0],s[1],s[2]); + dMakeRandomVector (p,3,1.0); + dGeomSetPosition (box,p[0],p[1],p[2]); + dRFromAxisAndAngle (R,dRandReal()*2-1,dRandReal()*2-1, + dRandReal()*2-1,dRandReal()*10-5); + dGeomSetRotation (box,R); + + // ********** test zero length ray just inside box + + dGeomRaySetLength (ray,0); + for (j=0; j<3; j++) q[j] = (dRandReal()-0.5)*s[j]; + i = dRandInt (3); + if (dRandReal() > 0.5) q[i] = 0.99*0.5*s[i]; else q[i] = -0.99*0.5*s[i]; + dMultiply0 (q2,dGeomGetRotation(box),q,3,3,1); + for (j=0; j<3; j++) q2[j] += p[j]; + dGeomSetPosition (ray,q2[0],q2[1],q2[2]); + dRFromAxisAndAngle (R,dRandReal()*2-1,dRandReal()*2-1, + dRandReal()*2-1,dRandReal()*10-5); + dGeomSetRotation (ray,R); + if (dCollide (ray,box,1,&contact,sizeof(dContactGeom)) != 0) FAILED(); + + // ********** test zero length ray just outside box + + dGeomRaySetLength (ray,0); + for (j=0; j<3; j++) q[j] = (dRandReal()-0.5)*s[j]; + i = dRandInt (3); + if (dRandReal() > 0.5) q[i] = 1.01*0.5*s[i]; else q[i] = -1.01*0.5*s[i]; + dMultiply0 (q2,dGeomGetRotation(box),q,3,3,1); + for (j=0; j<3; j++) q2[j] += p[j]; + dGeomSetPosition (ray,q2[0],q2[1],q2[2]); + dRFromAxisAndAngle (R,dRandReal()*2-1,dRandReal()*2-1, + dRandReal()*2-1,dRandReal()*10-5); + dGeomSetRotation (ray,R); + if (dCollide (ray,box,1,&contact,sizeof(dContactGeom)) != 0) FAILED(); + + // ********** test finite length ray totally contained inside the box + + for (j=0; j<3; j++) q[j] = (dRandReal()-0.5)*0.99*s[j]; + dMultiply0 (q2,dGeomGetRotation(box),q,3,3,1); + for (j=0; j<3; j++) q2[j] += p[j]; + for (j=0; j<3; j++) q3[j] = (dRandReal()-0.5)*0.99*s[j]; + dMultiply0 (q4,dGeomGetRotation(box),q3,3,3,1); + for (j=0; j<3; j++) q4[j] += p[j]; + for (j=0; j<3; j++) n[j] = q4[j] - q2[j]; + dNormalize3 (n); + dGeomRaySet (ray,q2[0],q2[1],q2[2],n[0],n[1],n[2]); + dGeomRaySetLength (ray,dCalcPointsDistance3(q2,q4)); + if (dCollide (ray,box,1,&contact,sizeof(dContactGeom)) != 0) FAILED(); + + // ********** test finite length ray totally outside the box + + for (j=0; j<3; j++) q[j] = (dRandReal()-0.5)*s[j]; + i = dRandInt (3); + if (dRandReal() > 0.5) q[i] = 1.01*0.5*s[i]; else q[i] = -1.01*0.5*s[i]; + dMultiply0 (q2,dGeomGetRotation(box),q,3,3,1); + for (j=0; j<3; j++) q3[j] = q2[j] + p[j]; + dNormalize3 (q2); + dGeomRaySet (ray,q3[0],q3[1],q3[2],q2[0],q2[1],q2[2]); + dGeomRaySetLength (ray,10); + if (dCollide (ray,box,1,&contact,sizeof(dContactGeom)) != 0) FAILED(); + + // ********** test ray from outside to just above surface + + for (j=0; j<3; j++) q[j] = (dRandReal()-0.5)*s[j]; + i = dRandInt (3); + if (dRandReal() > 0.5) q[i] = 1.01*0.5*s[i]; else q[i] = -1.01*0.5*s[i]; + dMultiply0 (q2,dGeomGetRotation(box),q,3,3,1); + for (j=0; j<3; j++) q3[j] = 2*q2[j] + p[j]; + k = dSqrt(q2[0]*q2[0] + q2[1]*q2[1] + q2[2]*q2[2]); + for (j=0; j<3; j++) q2[j] = -q2[j]; + dGeomRaySet (ray,q3[0],q3[1],q3[2],q2[0],q2[1],q2[2]); + dGeomRaySetLength (ray,k*0.99); + if (dCollide (ray,box,1,&contact,sizeof(dContactGeom)) != 0) FAILED(); + + // ********** test ray from outside to just below surface + + dGeomRaySetLength (ray,k*1.01); + if (dCollide (ray,box,1,&contact,sizeof(dContactGeom)) != 1) FAILED(); + + // ********** test contact point position for random rays + + for (j=0; j<3; j++) q[j] = dRandReal()*s[j]; + dMultiply0 (q2,dGeomGetRotation(box),q,3,3,1); + for (j=0; j<3; j++) q2[j] += p[j]; + for (j=0; j<3; j++) q3[j] = dRandReal()-0.5; + dNormalize3 (q3); + dGeomRaySet (ray,q2[0],q2[1],q2[2],q3[0],q3[1],q3[2]); + dGeomRaySetLength (ray,10); + if (dCollide (ray,box,1,&contact,sizeof(dContactGeom))) { + // check depth of contact point + if (dFabs (dGeomBoxPointDepth + (box,contact.pos[0],contact.pos[1],contact.pos[2])) > tol) + FAILED(); + // check position of contact point + for (j=0; j<3; j++) contact.pos[j] -= p[j]; + dMultiply1 (q,dGeomGetRotation(box),contact.pos,3,3,1); + if ( dFabs(dFabs (q[0]) - 0.5*s[0]) > tol && + dFabs(dFabs (q[1]) - 0.5*s[1]) > tol && + dFabs(dFabs (q[2]) - 0.5*s[2]) > tol) { + FAILED(); + } + // also check normal signs + if (dCalcVectorDot3 (q3,contact.normal) > 0) FAILED(); + + draw_all_objects (space); + } + + PASSED(); +} + + +int test_ray_and_ccylinder() +{ + int j; + dContactGeom contact; + dVector3 p,a,b,n; + dMatrix3 R; + dReal r,l,k,x,y; + + dSimpleSpace space(0); + dGeomID ray = dCreateRay (0,0); + dGeomID ccyl = dCreateCapsule (0,1,1); + dSpaceAdd (space,ray); + dSpaceAdd (space,ccyl); + + // ********** make a random capped cylinder + + r = dRandReal()*0.5 + 0.01; + l = dRandReal()*1 + 0.01; + dGeomCapsuleSetParams (ccyl,r,l); + dMakeRandomVector (p,3,1.0); + dGeomSetPosition (ccyl,p[0],p[1],p[2]); + dRFromAxisAndAngle (R,dRandReal()*2-1,dRandReal()*2-1, + dRandReal()*2-1,dRandReal()*10-5); + dGeomSetRotation (ccyl,R); + + // ********** test ray completely within ccyl + + for (j=0; j<3; j++) a[j] = dRandReal()-0.5; + dNormalize3 (a); + k = (dRandReal()-0.5)*l; + for (j=0; j<3; j++) a[j] = p[j] + r*0.99*a[j] + k*0.99*R[j*4+2]; + for (j=0; j<3; j++) b[j] = dRandReal()-0.5; + dNormalize3 (b); + k = (dRandReal()-0.5)*l; + for (j=0; j<3; j++) b[j] = p[j] + r*0.99*b[j] + k*0.99*R[j*4+2]; + dGeomRaySetLength (ray,dCalcPointsDistance3(a,b)); + for (j=0; j<3; j++) b[j] -= a[j]; + dNormalize3 (b); + dGeomRaySet (ray,a[0],a[1],a[2],b[0],b[1],b[2]); + if (dCollide (ray,ccyl,1,&contact,sizeof(dContactGeom)) != 0) FAILED(); + + // ********** test ray outside ccyl that just misses (between caps) + + k = dRandReal()*2*M_PI; + x = sin(k); + y = cos(k); + for (j=0; j<3; j++) a[j] = x*R[j*4+0] + y*R[j*4+1]; + k = (dRandReal()-0.5)*l; + for (j=0; j<3; j++) b[j] = -a[j]*r*2 + k*R[j*4+2] + p[j]; + dGeomRaySet (ray,b[0],b[1],b[2],a[0],a[1],a[2]); + dGeomRaySetLength (ray,r*0.99); + if (dCollide (ray,ccyl,1,&contact,sizeof(dContactGeom)) != 0) FAILED(); + + // ********** test ray outside ccyl that just hits (between caps) + + dGeomRaySetLength (ray,r*1.01); + if (dCollide (ray,ccyl,1,&contact,sizeof(dContactGeom)) != 1) FAILED(); + // check depth of contact point + if (dFabs (dGeomCapsulePointDepth + (ccyl,contact.pos[0],contact.pos[1],contact.pos[2])) > tol) + FAILED(); + + // ********** test ray outside ccyl that just misses (caps) + + for (j=0; j<3; j++) a[j] = dRandReal()-0.5; + dNormalize3 (a); + if (dCalcVectorDot3_14(a,R+2) < 0) { + for (j=0; j<3; j++) b[j] = p[j] - a[j]*2*r + l*0.5*R[j*4+2]; + } + else { + for (j=0; j<3; j++) b[j] = p[j] - a[j]*2*r - l*0.5*R[j*4+2]; + } + dGeomRaySet (ray,b[0],b[1],b[2],a[0],a[1],a[2]); + dGeomRaySetLength (ray,r*0.99); + if (dCollide (ray,ccyl,1,&contact,sizeof(dContactGeom)) != 0) FAILED(); + + // ********** test ray outside ccyl that just hits (caps) + + dGeomRaySetLength (ray,r*1.01); + if (dCollide (ray,ccyl,1,&contact,sizeof(dContactGeom)) != 1) FAILED(); + // check depth of contact point + if (dFabs (dGeomCapsulePointDepth + (ccyl,contact.pos[0],contact.pos[1],contact.pos[2])) > tol) + FAILED(); + + // ********** test random rays + + for (j=0; j<3; j++) a[j] = dRandReal()-0.5; + for (j=0; j<3; j++) n[j] = dRandReal()-0.5; + dNormalize3 (n); + dGeomRaySet (ray,a[0],a[1],a[2],n[0],n[1],n[2]); + dGeomRaySetLength (ray,10); + + if (dCollide (ray,ccyl,1,&contact,sizeof(dContactGeom))) { + // check depth of contact point + if (dFabs (dGeomCapsulePointDepth + (ccyl,contact.pos[0],contact.pos[1],contact.pos[2])) > tol) + FAILED(); + + // check normal signs + if (dCalcVectorDot3 (n,contact.normal) > 0) FAILED(); + + draw_all_objects (space); + } + + PASSED(); +} + +/* + Test rays within the cylinder + -completely inside + -exiting through side + -exiting through cap + -exiting through corner + Test rays outside the cylinder +*/ +int test_ray_and_cylinder() +{ + dVector3 a,b; + + dSimpleSpace space(0); + dGeomID ray = dCreateRay(space,4); + + // The first thing that happens is the ray is + // rotated into cylinder coordinates. We'll trust that's + // done right. The major axis is in the z-dir. + + + // Random tests + /*b[0]=4*dRandReal()-2; + b[1]=4*dRandReal()-2; + b[2]=4*dRandReal()-2; + a[0]=2*dRandReal()-1; + a[1]=2*dRandReal()-1; + a[2]=2*dRandReal()-1;*/ + + // Inside out + b[0]=dRandReal()-0.5; + b[1]=dRandReal()-0.5; + b[2]=dRandReal()-0.5; + a[0]=2*dRandReal()-1; + a[1]=2*dRandReal()-1; + a[2]=2*dRandReal()-1; + + // Outside in + /*b[0]=4*dRandReal()-2; + b[1]=4*dRandReal()-2; + b[2]=4*dRandReal()-2; + a[0]=-b[0]; + a[1]=-b[1]; + a[2]=-b[2];*/ + + + dGeomRaySet (ray,b[0],b[1],b[2],a[0],a[1],a[2]); + // This is just for visual inspection right now. + //if (dCollide (ray,cyl,1,&contact,sizeof(dContactGeom)) != 1) FAILED(); + + draw_all_objects (space); + + PASSED(); +} + + +int test_ray_and_plane() +{ + int j; + dContactGeom contact; + dVector3 n,p,q,a,b,g,h; // n,d = plane parameters + dMatrix3 R; + dReal d; + + dSimpleSpace space(0); + dGeomID ray = dCreateRay (0,0); + dGeomID plane = dCreatePlane (0,0,0,1,0); + dSpaceAdd (space,ray); + dSpaceAdd (space,plane); + + // ********** make a random plane + + for (j=0; j<3; j++) n[j] = dRandReal() - 0.5; + dNormalize3 (n); + d = dRandReal() - 0.5; + dGeomPlaneSetParams (plane,n[0],n[1],n[2],d); + dPlaneSpace (n,p,q); + + // ********** test finite length ray below plane + + dGeomRaySetLength (ray,0.09); + a[0] = dRandReal()-0.5; + a[1] = dRandReal()-0.5; + a[2] = -dRandReal()*0.5 - 0.1; + for (j=0; j<3; j++) b[j] = a[0]*p[j] + a[1]*q[j] + (a[2]+d)*n[j]; + dGeomSetPosition (ray,b[0],b[1],b[2]); + dRFromAxisAndAngle (R,dRandReal()*2-1,dRandReal()*2-1, + dRandReal()*2-1,dRandReal()*10-5); + dGeomSetRotation (ray,R); + if (dCollide (ray,plane,1,&contact,sizeof(dContactGeom)) != 0) FAILED(); + + // ********** test finite length ray above plane + + a[0] = dRandReal()-0.5; + a[1] = dRandReal()-0.5; + a[2] = dRandReal()*0.5 + 0.01; + for (j=0; j<3; j++) b[j] = a[0]*p[j] + a[1]*q[j] + (a[2]+d)*n[j]; + g[0] = dRandReal()-0.5; + g[1] = dRandReal()-0.5; + g[2] = dRandReal() + 0.01; + for (j=0; j<3; j++) h[j] = g[0]*p[j] + g[1]*q[j] + g[2]*n[j]; + dNormalize3 (h); + dGeomRaySet (ray,b[0],b[1],b[2],h[0],h[1],h[2]); + dGeomRaySetLength (ray,10); + if (dCollide (ray,plane,1,&contact,sizeof(dContactGeom)) != 0) FAILED(); + + // ********** test finite length ray that intersects plane + + a[0] = dRandReal()-0.5; + a[1] = dRandReal()-0.5; + a[2] = dRandReal()-0.5; + for (j=0; j<3; j++) b[j] = a[0]*p[j] + a[1]*q[j] + (a[2]+d)*n[j]; + g[0] = dRandReal()-0.5; + g[1] = dRandReal()-0.5; + g[2] = dRandReal()-0.5; + for (j=0; j<3; j++) h[j] = g[0]*p[j] + g[1]*q[j] + g[2]*n[j]; + dNormalize3 (h); + dGeomRaySet (ray,b[0],b[1],b[2],h[0],h[1],h[2]); + dGeomRaySetLength (ray,10); + if (dCollide (ray,plane,1,&contact,sizeof(dContactGeom))) { + // test that contact is on plane surface + if (dFabs (dCalcVectorDot3(contact.pos,n) - d) > tol) FAILED(); + // also check normal signs + if (dCalcVectorDot3 (h,contact.normal) > 0) FAILED(); + // also check contact point depth + if (dFabs (dGeomPlanePointDepth + (plane,contact.pos[0],contact.pos[1],contact.pos[2])) > tol) + FAILED(); + + draw_all_objects (space); + } + + // ********** test ray that just misses + + for (j=0; j<3; j++) b[j] = (1+d)*n[j]; + for (j=0; j<3; j++) h[j] = -n[j]; + dGeomRaySet (ray,b[0],b[1],b[2],h[0],h[1],h[2]); + dGeomRaySetLength (ray,0.99); + if (dCollide (ray,plane,1,&contact,sizeof(dContactGeom)) != 0) FAILED(); + + // ********** test ray that just hits + + dGeomRaySetLength (ray,1.01); + if (dCollide (ray,plane,1,&contact,sizeof(dContactGeom)) != 1) FAILED(); + + // ********** test polarity with typical ground plane + + dGeomPlaneSetParams (plane,0,0,1,0); + for (j=0; j<3; j++) a[j] = 0.1; + for (j=0; j<3; j++) b[j] = 0; + a[2] = 1; + b[2] = -1; + dGeomRaySet (ray,a[0],a[1],a[2],b[0],b[1],b[2]); + dGeomRaySetLength (ray,2); + if (dCollide (ray,plane,1,&contact,sizeof(dContactGeom)) != 1) FAILED(); + if (dFabs (contact.depth - 1) > tol) FAILED(); + a[2] = -1; + b[2] = 1; + dGeomRaySet (ray,a[0],a[1],a[2],b[0],b[1],b[2]); + if (dCollide (ray,plane,1,&contact,sizeof(dContactGeom)) != 1) FAILED(); + if (dFabs (contact.depth - 1) > tol) FAILED(); + + PASSED(); +} + +//**************************************************************************** +// a really inefficient, but hopefully correct implementation of +// dBoxTouchesBox(), that does 144 edge-face tests. + +// return 1 if edge v1 -> v2 hits the rectangle described by p1,p2,p3 + +static int edgeIntersectsRect (dVector3 v1, dVector3 v2, + dVector3 p1, dVector3 p2, dVector3 p3) +{ + int k; + dVector3 u1, u2, n, tmp; + + for (k=0; k < 3; k++) u1[k] = p3[k] - p1[k]; + for (k=0; k < 3; k++) u2[k] = p2[k] - p1[k]; + + dReal d1 = dSqrt(dCalcVectorDot3(u1, u1)); + dReal d2 = dSqrt(dCalcVectorDot3(u2, u2)); + dNormalize3(u1); + dNormalize3(u2); + + dReal error; +#ifdef dSINGLE + const dReal uEpsilon = 1e-5, pEpsilon = 1e-6, tmpEpsilon = 1.5e-4; +#else + const dReal uEpsilon = 1e-6, pEpsilon = 1e-8, tmpEpsilon = 1e-6; +#endif + + error = dFabs(dCalcVectorDot3(u1, u2)); + if (error > uEpsilon) dDebug(0, "bad u1/u2"); + + dCalcVectorCross3(n, u1, u2); + + for (k=0; k < 3; k++) tmp[k] = v2[k] - v1[k]; + + dReal d = -dCalcVectorDot3(n, p1); + + error = dFabs(dCalcVectorDot3(n, p1) + d); + if (error > pEpsilon) dDebug(0, "bad n wrt p1"); + + error = dFabs(dCalcVectorDot3(n, p2) + d); + if (error > pEpsilon) dDebug(0, "bad n wrt p2"); + + error = dFabs(dCalcVectorDot3(n, p3) + d); + if (error > pEpsilon) dDebug(0, "bad n wrt p3"); + + dReal alpha = -(d + dCalcVectorDot3(n, v1)) / dCalcVectorDot3(n, tmp); + for (k=0; k < 3; k++) tmp[k] = v1[k] + alpha * (v2[k] - v1[k]); + + error = dFabs(dCalcVectorDot3(n, tmp) + d); + if (error > tmpEpsilon) dDebug(0, "bad tmp"); + + if (alpha < 0) return 0; + if (alpha > 1) return 0; + + for (k=0; k < 3; k++) tmp[k] -= p1[k]; + dReal a1 = dCalcVectorDot3(u1, tmp); + dReal a2 = dCalcVectorDot3(u2, tmp); + if (a1 < 0 || a2 < 0 || a1 > d1 || a2 > d2) return 0; + + return 1; +} + + +// return 1 if box 1 is completely inside box 2 + +static int box1inside2 (const dVector3 p1, const dMatrix3 R1, + const dVector3 side1, const dVector3 p2, + const dMatrix3 R2, const dVector3 side2) +{ + for (int i=-1; i<=1; i+=2) { + for (int j=-1; j<=1; j+=2) { + for (int k=-1; k<=1; k+=2) { + dVector3 v,vv; + v[0] = i*0.5*side1[0]; + v[1] = j*0.5*side1[1]; + v[2] = k*0.5*side1[2]; + dMultiply0_331 (vv,R1,v); + vv[0] += p1[0] - p2[0]; + vv[1] += p1[1] - p2[1]; + vv[2] += p1[2] - p2[2]; + for (int axis=0; axis < 3; axis++) { + dReal z = dCalcVectorDot3_14(vv,R2+axis); + if (z < (-side2[axis]*0.5) || z > (side2[axis]*0.5)) return 0; + } + } + } + } + return 1; +} + + +// test if any edge from box 1 hits a face from box 2 + +static int testBoxesTouch2 (const dVector3 p1, const dMatrix3 R1, + const dVector3 side1, const dVector3 p2, + const dMatrix3 R2, const dVector3 side2) +{ + int j,k,j1,j2; + + // for 6 faces from box 2 + for (int fd=0; fd<3; fd++) { // direction for face + + for (int fo=0; fo<2; fo++) { // offset of face + // get four points on the face. first get 2 indexes that are not fd + int k1=0,k2=0; + if (fd==0) { k1 = 1; k2 = 2; } + if (fd==1) { k1 = 0; k2 = 2; } + if (fd==2) { k1 = 0; k2 = 1; } + dVector3 fp[4],tmp; + k=0; + for (j1=-1; j1<=1; j1+=2) { + for (j2=-1; j2<=1; j2+=2) { + fp[k][k1] = j1; + fp[k][k2] = j2; + fp[k][fd] = fo*2-1; + k++; + } + } + for (j=0; j<4; j++) { + for (k=0; k<3; k++) fp[j][k] *= 0.5*side2[k]; + dMultiply0_331 (tmp,R2,fp[j]); + for (k=0; k<3; k++) fp[j][k] = tmp[k] + p2[k]; + } + + // for 8 vertices + dReal v1[3]; + for (v1[0]=-1; v1[0] <= 1; v1[0] += 2) { + for (v1[1]=-1; v1[1] <= 1; v1[1] += 2) { + for (v1[2]=-1; v1[2] <= 1; v1[2] += 2) { + // for all possible +ve leading edges from those vertices + for (int ei=0; ei < 3; ei ++) { + if (v1[ei] < 0) { + // get vertex1 -> vertex2 = an edge from box 1 + dVector3 vv1,vv2; + for (k=0; k<3; k++) vv1[k] = v1[k] * 0.5*side1[k]; + for (k=0; k<3; k++) vv2[k] = (v1[k] + (k==ei)*2)*0.5*side1[k]; + dVector3 vertex1,vertex2; + dMultiply0_331 (vertex1,R1,vv1); + dMultiply0_331 (vertex2,R1,vv2); + for (k=0; k<3; k++) vertex1[k] += p1[k]; + for (k=0; k<3; k++) vertex2[k] += p1[k]; + + // see if vertex1 -> vertex2 interesects face + if (edgeIntersectsRect (vertex1,vertex2,fp[0],fp[1],fp[2])) + return 1; + } + } + } + } + } + } + } + + if (box1inside2 (p1,R1,side1,p2,R2,side2)) return 1; + if (box1inside2 (p2,R2,side2,p1,R1,side1)) return 1; + + return 0; +} + +//**************************************************************************** +// dBoxTouchesBox() test + +int test_dBoxTouchesBox() +{ + int k,bt1,bt2; + dVector3 p1,p2,side1,side2; + dMatrix3 R1,R2; + + dSimpleSpace space(0); + dGeomID box1 = dCreateBox (0,1,1,1); + dSpaceAdd (space,box1); + dGeomID box2 = dCreateBox (0,1,1,1); + dSpaceAdd (space,box2); + + dMakeRandomVector (p1,3,0.5); + dMakeRandomVector (p2,3,0.5); + for (k=0; k<3; k++) side1[k] = dRandReal() + 0.01; + for (k=0; k<3; k++) side2[k] = dRandReal() + 0.01; + dRFromAxisAndAngle (R1,dRandReal()*2.0-1.0,dRandReal()*2.0-1.0, + dRandReal()*2.0-1.0,dRandReal()*10.0-5.0); + dRFromAxisAndAngle (R2,dRandReal()*2.0-1.0,dRandReal()*2.0-1.0, + dRandReal()*2.0-1.0,dRandReal()*10.0-5.0); + + dGeomBoxSetLengths (box1,side1[0],side1[1],side1[2]); + dGeomBoxSetLengths (box2,side2[0],side2[1],side2[2]); + dGeomSetPosition (box1,p1[0],p1[1],p1[2]); + dGeomSetRotation (box1,R1); + dGeomSetPosition (box2,p2[0],p2[1],p2[2]); + dGeomSetRotation (box2,R2); + draw_all_objects (space); + + int t1 = testBoxesTouch2 (p1,R1,side1,p2,R2,side2); + int t2 = testBoxesTouch2 (p2,R2,side2,p1,R1,side1); + bt1 = t1 || t2; + bt2 = dBoxTouchesBox (p1,R1,side1,p2,R2,side2); + + if (bt1 != bt2) FAILED(); + + /* + // some more debugging info if necessary + if (bt1 && bt2) printf ("agree - boxes touch\n"); + if (!bt1 && !bt2) printf ("agree - boxes don't touch\n"); + if (bt1 && !bt2) printf ("disagree - boxes touch but dBoxTouchesBox " + "says no\n"); + if (!bt1 && bt2) printf ("disagree - boxes don't touch but dBoxTouchesBox " + "says yes\n"); + */ + + PASSED(); +} + +//**************************************************************************** +// test box-box collision + +int test_dBoxBox() +{ + int k,bt; + dVector3 p1,p2,side1,side2,normal,normal2; + dMatrix3 R1,R2; + dReal depth,depth2; + int code; + dContactGeom contact[48]; + + dSimpleSpace space(0); + dGeomID box1 = dCreateBox (0,1,1,1); + dSpaceAdd (space,box1); + dGeomID box2 = dCreateBox (0,1,1,1); + dSpaceAdd (space,box2); + + dMakeRandomVector (p1,3,0.5); + dMakeRandomVector (p2,3,0.5); + for (k=0; k<3; k++) side1[k] = dRandReal() + 0.01; + for (k=0; k<3; k++) side2[k] = dRandReal() + 0.01; + + dRFromAxisAndAngle (R1,dRandReal()*2.0-1.0,dRandReal()*2.0-1.0, + dRandReal()*2.0-1.0,dRandReal()*10.0-5.0); + dRFromAxisAndAngle (R2,dRandReal()*2.0-1.0,dRandReal()*2.0-1.0, + dRandReal()*2.0-1.0,dRandReal()*10.0-5.0); + + // dRSetIdentity (R1); // we can also try this + // dRSetIdentity (R2); + + dGeomBoxSetLengths (box1,side1[0],side1[1],side1[2]); + dGeomBoxSetLengths (box2,side2[0],side2[1],side2[2]); + dGeomSetPosition (box1,p1[0],p1[1],p1[2]); + dGeomSetRotation (box1,R1); + dGeomSetPosition (box2,p2[0],p2[1],p2[2]); + dGeomSetRotation (box2,R2); + + code = 0; + depth = 0; + bt = dBoxBox (p1,R1,side1,p2,R2,side2,normal,&depth,&code,8,contact, + sizeof(dContactGeom)); + if (bt==1) { + p2[0] += normal[0] * 0.96 * depth; + p2[1] += normal[1] * 0.96 * depth; + p2[2] += normal[2] * 0.96 * depth; + bt = dBoxBox (p1,R1,side1,p2,R2,side2,normal2,&depth2,&code,8,contact, + sizeof(dContactGeom)); + + /* + dGeomSetPosition (box2,p2[0],p2[1],p2[2]); + draw_all_objects (space); + */ + + if (bt != 1) { + FAILED(); + dGeomSetPosition (box2,p2[0],p2[1],p2[2]); + draw_all_objects (space); + } + + p2[0] += normal[0] * 0.08 * depth; + p2[1] += normal[1] * 0.08 * depth; + p2[2] += normal[2] * 0.08 * depth; + bt = dBoxBox (p1,R1,side1,p2,R2,side2,normal2,&depth2,&code,8,contact, + sizeof(dContactGeom)); + if (bt != 0) FAILED(); + + // dGeomSetPosition (box2,p2[0],p2[1],p2[2]); + // draw_all_objects (space); + } + + // printf ("code=%2d depth=%.4f ",code,depth); + + PASSED(); +} + +//**************************************************************************** +// graphics + +int space_pressed = 0; + + +// start simulation - set viewpoint + +static void start() +{ + dAllocateODEDataForThread(dAllocateMaskAll); + + static float xyz[3] = {2.4807,-1.8023,2.7600}; + static float hpr[3] = {141.5000,-18.5000,0.0000}; + dsSetViewpoint (xyz,hpr); +} + + +// called when a key pressed + +static void command (int cmd) +{ + if (cmd == ' ') space_pressed = 1; +} + + +// simulation loop + +static void simLoop (int) +{ + do { + draw_all_objects_called = 0; + unsigned long seed = dRandGetSeed(); + testslot[graphical_test].test_fn(); + if (draw_all_objects_called) { + if (space_pressed) space_pressed = 0; else dRandSetSeed (seed); + } + } + while (!draw_all_objects_called); +} + +//**************************************************************************** +// do all the tests + +void do_tests (int argc, char **argv) +{ + int i,j; + + // process command line arguments + if (argc >= 2) { + graphical_test = atoi (argv[1]); + } + + if (graphical_test) { + // do one test gaphically and interactively + + if (graphical_test < 1 || graphical_test >= MAX_TESTS || + !testslot[graphical_test].name) { + dError (0,"invalid test number"); + } + + printf ("performing test: %s\n",testslot[graphical_test].name); + + // setup pointers to drawstuff callback functions + dsFunctions fn; + fn.version = DS_VERSION; + fn.start = &start; + fn.step = &simLoop; + fn.command = &command; + fn.stop = 0; + fn.path_to_textures = DRAWSTUFF_TEXTURE_PATH; + + dsSetSphereQuality (3); + dsSetCapsuleQuality (8); + dsSimulationLoop (argc,argv,1280,900,&fn); + } + else { + // do all tests noninteractively + + for (i=0; ifailcount = 0; + int total_reps=0; + for (int batch=0; batch<2; batch++) { + int reps = (batch==0) ? TEST_REPS1 : TEST_REPS2; + total_reps += reps; + printf ("testing batch %d (%d reps)...\n",batch+1,reps); + + // run tests + for (j=0; jnumber; + if (ts[i]->test_fn() != 1) ts[i]->failcount++; + } + } + + // check for failures + int total_fail_count=0; + for (i=0; ifailcount; + if (total_fail_count) break; + } + + // print results + for (i=0; inumber,ts[i]->name); + if (ts[i]->failcount) { + printf ("FAILED (%.2f%%) at line %d\n", + double(ts[i]->failcount)/double(total_reps)*100.0, + ts[i]->last_failed_line); + } + else { + printf ("ok\n"); + } + } + } +} + +//**************************************************************************** + +int main (int argc, char **argv) +{ + // setup all tests + + memset (testslot,0,sizeof(testslot)); + dInitODE2(0); + + MAKE_TEST(1,test_sphere_point_depth); + MAKE_TEST(2,test_box_point_depth); + MAKE_TEST(3,test_ccylinder_point_depth); + MAKE_TEST(4,test_plane_point_depth); + + MAKE_TEST(10,test_ray_and_sphere); + MAKE_TEST(11,test_ray_and_box); + MAKE_TEST(12,test_ray_and_ccylinder); + MAKE_TEST(13,test_ray_and_plane); + MAKE_TEST(14,test_ray_and_cylinder); + + MAKE_TEST(100,test_dBoxTouchesBox); + MAKE_TEST(101,test_dBoxBox); + + do_tests (argc,argv); + dCloseODE(); + return 0; +} diff --git a/libs/ode-0.16.1/ode/demo/demo_convex.cpp b/libs/ode-0.16.1/ode/demo/demo_convex.cpp new file mode 100644 index 0000000..eea5c6e --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/demo_convex.cpp @@ -0,0 +1,307 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +// Convex demo. +// Serves as a test for the convex geometry. +// By Bram Stolk. + +#include +#ifdef HAVE_UNISTD_H +# include +#endif +#include +#include +#include "texturepath.h" + +#include "halton235_geom.h" + +#ifdef dDOUBLE +# define dsDrawConvex dsDrawConvexD +# define dsDrawLine dsDrawLineD +#endif + + +#ifdef _MSC_VER +# pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + + +// Height at which we drop the composite block. +const dReal H=4.20; + +static dWorldID world; +static dSpaceID space; + +static dBodyID mbody; + +static dBodyID hbody[ halton_numc ]; +static dGeomID hgeom[ halton_numc ]; + +static dJointGroupID contactgroup; + +static bool drawpos=false; +static bool solidkernel=false; + + +// this is called by dSpaceCollide when two objects in space are +// potentially colliding. + +static void nearCallback(void *data, dGeomID o1, dGeomID o2) +{ + assert(o1); + assert(o2); + if (dGeomIsSpace(o1) || dGeomIsSpace(o2)) + { + // colliding a space with something + dSpaceCollide2(o1,o2,data,&nearCallback); + // Note we do not want to test intersections within a space, + // only between spaces. + return; + } + + const int N = 32; + dContact contact[N]; + int n = dCollide (o1,o2,N,&(contact[0].geom),sizeof(dContact)); + if (n > 0) + { + for (int i=0; i 8 ? 8 : nrofsteps; + + for (int i=0; i +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +// select correct drawing functions + +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawSphere dsDrawSphereD +#define dsDrawCylinder dsDrawCylinderD +#define dsDrawCapsule dsDrawCapsuleD +#endif + + +// some constants + +#define LENGTH 3.5 // chassis length +#define WIDTH 2.5 // chassis width +#define HEIGHT 1.0 // chassis height +#define RADIUS 0.5 // wheel radius +#define STARTZ 1.0 // starting height of chassis +#define CMASS 1 // chassis mass +#define WMASS 1 // wheel mass +#define COMOFFSET -5 // center of mass offset +#define WALLMASS 1 // wall box mass +#define BALLMASS 1 // ball mass +#define FMAX 25 // car engine fmax +#define ROWS 1 // rows of cars +#define COLS 1 // columns of cars +#define ITERS 20 // number of iterations +#define WBOXSIZE 1.0 // size of wall boxes +#define WALLWIDTH 12 // width of wall +#define WALLHEIGHT 10 // height of wall +#define DISABLE_THRESHOLD 0.008 // maximum velocity (squared) a body can have and be disabled +#define DISABLE_STEPS 10 // number of steps a box has to have been disable-able before it will be disabled +#define CANNON_X -10 // x position of cannon +#define CANNON_Y 5 // y position of cannon +#define CANNON_BALL_MASS 10 // mass of the cannon ball +#define CANNON_BALL_RADIUS 0.5 + +static const dVector3 xunit = { 1, 0, 0 }, yunit = { 0, 1, 0 }, zpunit = { 0, 0, 1 }, zmunit = { 0, 0, -1 }; + +//#define BOX +#define CARS +#define WALL +//#define BALLS +//#define BALLSTACK +//#define ONEBALL +//#define CENTIPEDE +#define CANNON + +// dynamics and collision objects (chassis, 3 wheels, environment) + +static dWorldID world; +static dSpaceID space; +static dThreadingImplementationID threading; +static dThreadingThreadPoolID pool; +static dBodyID body[10000]; +static int bodies; +static dJointID joint[100000]; +static int joints; +static dJointGroupID contactgroup; +static dGeomID ground; +static dGeomID box[10000]; +static int boxes; +static dGeomID sphere[10000]; +static int spheres; +static dGeomID wall_boxes[10000]; +static dBodyID wall_bodies[10000]; +static dGeomID cannon_ball_geom; +static dBodyID cannon_ball_body; +static int wb_stepsdis[10000]; +static int wb; +static bool doFast; +static dBodyID b; +static dMass m; + + +// things that the user controls + +static dReal turn = 0, speed = 0; // user commands +static dReal cannon_angle=0,cannon_elevation=-1.2; + + + +// this is called by dSpaceCollide when two objects in space are +// potentially colliding. + +static void nearCallback (void *, dGeomID o1, dGeomID o2) +{ + int i,n; + + dBodyID b1 = dGeomGetBody(o1); + dBodyID b2 = dGeomGetBody(o2); + if (b1 && b2 && dAreConnected(b1, b2)) + return; + + const int N = 4; + dContact contact[N]; + n = dCollide (o1,o2,N,&contact[0].geom,sizeof(dContact)); + if (n > 0) { + for (i=0; i -20; x-=RADIUS*2) + { + body[bodies] = dBodyCreate (world); + dBodySetPosition(body[bodies], x, y, STARTZ); + dMassSetSphere(&m, 1, RADIUS); + dMassAdjust(&m, WMASS); + dBodySetMass(body[bodies], &m); + sphere[spheres] = dCreateSphere (space, RADIUS); + dGeomSetBody (sphere[spheres++], body[bodies]); + + joint[joints] = dJointCreateHinge2 (world,0); + if (x == -17) + dJointAttach (joint[joints],b,body[bodies]); + else + dJointAttach (joint[joints],body[bodies-2],body[bodies]); + const dReal *a = dBodyGetPosition (body[bodies++]); + dJointSetHinge2Anchor (joint[joints],a[0],a[1],a[2]); + dJointSetHinge2Axes (joint[joints], zpunit, xunit); + dJointSetHinge2Param (joint[joints],dParamSuspensionERP,1.0); + dJointSetHinge2Param (joint[joints],dParamSuspensionCFM,1e-5); + dJointSetHinge2Param (joint[joints],dParamLoStop,0); + dJointSetHinge2Param (joint[joints],dParamHiStop,0); + dJointSetHinge2Param (joint[joints],dParamVel2,-10.0); + dJointSetHinge2Param (joint[joints++],dParamFMax2,FMAX); + + body[bodies] = dBodyCreate (world); + dBodySetPosition(body[bodies], -30 - x, y, STARTZ); + dMassSetSphere(&m, 1, RADIUS); + dMassAdjust(&m, WMASS); + dBodySetMass(body[bodies], &m); + sphere[spheres] = dCreateSphere (space, RADIUS); + dGeomSetBody (sphere[spheres++], body[bodies]); + + joint[joints] = dJointCreateHinge2 (world,0); + if (x == -17) + dJointAttach (joint[joints],b,body[bodies]); + else + dJointAttach (joint[joints],body[bodies-2],body[bodies]); + const dReal *b = dBodyGetPosition (body[bodies++]); + dJointSetHinge2Anchor (joint[joints],b[0],b[1],b[2]); + dJointSetHinge2Axes (joint[joints], zpunit, xunit); + dJointSetHinge2Param (joint[joints],dParamSuspensionERP,1.0); + dJointSetHinge2Param (joint[joints],dParamSuspensionCFM,1e-5); + dJointSetHinge2Param (joint[joints],dParamLoStop,0); + dJointSetHinge2Param (joint[joints],dParamHiStop,0); + dJointSetHinge2Param (joint[joints],dParamVel2,10.0); + dJointSetHinge2Param (joint[joints++],dParamFMax2,FMAX); + } + if (lastb) + { + dJointID j = dJointCreateFixed(world,0); + dJointAttach (j, b, lastb); + dJointSetFixed(j); + } + lastb = b; + } +#endif +#ifdef BOX + body[bodies] = dBodyCreate (world); + dBodySetPosition (body[bodies],0,0,HEIGHT/2); + dMassSetBox (&m,1,LENGTH,WIDTH,HEIGHT); + dMassAdjust (&m, 1); + dBodySetMass (body[bodies],&m); + box[boxes] = dCreateBox (space,LENGTH,WIDTH,HEIGHT); + dGeomSetBody (box[boxes++],body[bodies++]); +#endif +#ifdef CANNON + cannon_ball_body = dBodyCreate (world); + cannon_ball_geom = dCreateSphere (space,CANNON_BALL_RADIUS); + dMassSetSphereTotal (&m,CANNON_BALL_MASS,CANNON_BALL_RADIUS); + dBodySetMass (cannon_ball_body,&m); + dGeomSetBody (cannon_ball_geom,cannon_ball_body); + dBodySetPosition (cannon_ball_body,CANNON_X,CANNON_Y,CANNON_BALL_RADIUS); +#endif +} + +// called when a key pressed + +static void command (int cmd) +{ + switch (cmd) { + case 'a': case 'A': + speed += 0.3; + break; + case 'z': case 'Z': + speed -= 0.3; + break; + case ',': + turn += 0.1; + if (turn > 0.3) + turn = 0.3; + break; + case '.': + turn -= 0.1; + if (turn < -0.3) + turn = -0.3; + break; + case ' ': + speed = 0; + turn = 0; + break; + case 'f': case 'F': + doFast = !doFast; + break; + case 'r': case 'R': + shutdownSimulation(); + setupSimulation(); + break; + case '[': + cannon_angle += 0.1; + break; + case ']': + cannon_angle -= 0.1; + break; + case '1': + cannon_elevation += 0.1; + break; + case '2': + cannon_elevation -= 0.1; + break; + case 'x': case 'X': { + dMatrix3 R2,R3,R4; + dRFromAxisAndAngle (R2,0,0,1,cannon_angle); + dRFromAxisAndAngle (R3,0,1,0,cannon_elevation); + dMultiply0 (R4,R2,R3,3,3,3); + dReal cpos[3] = {CANNON_X,CANNON_Y,1}; + for (int i=0; i<3; i++) cpos[i] += 3*R4[i*4+2]; + dBodySetPosition (cannon_ball_body,cpos[0],cpos[1],cpos[2]); + dReal force = 10; + dBodySetLinearVel (cannon_ball_body,force*R4[2],force*R4[6],force*R4[10]); + dBodySetAngularVel (cannon_ball_body,0,0,0); + break; + } + } +} + + +// simulation loop + +static void simLoop (int pause) +{ + int i, j; + + dsSetTexture (DS_WOOD); + + if (!pause) { +#ifdef BOX + dBodyAddForce(body[bodies-1],lspeed,0,0); +#endif + for (j = 0; j < joints; j++) + { + dReal curturn = dJointGetHinge2Angle1 (joint[j]); + //dMessage (0,"curturn %e, turn %e, vel %e", curturn, turn, (turn-curturn)*1.0); + dJointSetHinge2Param(joint[j],dParamVel,(turn-curturn)*1.0); + dJointSetHinge2Param(joint[j],dParamFMax,dInfinity); + dJointSetHinge2Param(joint[j],dParamVel2,speed); + dJointSetHinge2Param(joint[j],dParamFMax2,FMAX); + dBodyEnable(dJointGetBody(joint[j],0)); + dBodyEnable(dJointGetBody(joint[j],1)); + } + if (doFast) + { + dSpaceCollide (space,0,&nearCallback); + dWorldQuickStep (world,0.05); + dJointGroupEmpty (contactgroup); + } + else + { + dSpaceCollide (space,0,&nearCallback); + dWorldStep (world,0.05); + dJointGroupEmpty (contactgroup); + } + + for (i = 0; i < wb; i++) + { + b = dGeomGetBody(wall_boxes[i]); + if (dBodyIsEnabled(b)) + { + bool disable = true; + const dReal *lvel = dBodyGetLinearVel(b); + dReal lspeed = lvel[0]*lvel[0]+lvel[1]*lvel[1]+lvel[2]*lvel[2]; + if (lspeed > DISABLE_THRESHOLD) + disable = false; + const dReal *avel = dBodyGetAngularVel(b); + dReal aspeed = avel[0]*avel[0]+avel[1]*avel[1]+avel[2]*avel[2]; + if (aspeed > DISABLE_THRESHOLD) + disable = false; + + if (disable) + wb_stepsdis[i]++; + else + wb_stepsdis[i] = 0; + + if (wb_stepsdis[i] > DISABLE_STEPS) + { + dBodyDisable(b); + dsSetColor(0.5,0.5,1); + } + else + dsSetColor(1,1,1); + + } + else + dsSetColor(0.4,0.4,0.4); + dVector3 ss; + dGeomBoxGetLengths (wall_boxes[i], ss); + dsDrawBox(dGeomGetPosition(wall_boxes[i]), dGeomGetRotation(wall_boxes[i]), ss); + } + } + else + { + for (i = 0; i < wb; i++) + { + b = dGeomGetBody(wall_boxes[i]); + if (dBodyIsEnabled(b)) + dsSetColor(1,1,1); + else + dsSetColor(0.4,0.4,0.4); + dVector3 ss; + dGeomBoxGetLengths (wall_boxes[i], ss); + dsDrawBox(dGeomGetPosition(wall_boxes[i]), dGeomGetRotation(wall_boxes[i]), ss); + } + } + + dsSetColor (0,1,1); + dReal sides[3] = {LENGTH,WIDTH,HEIGHT}; + for (i = 0; i < boxes; i++) + dsDrawBox (dGeomGetPosition(box[i]),dGeomGetRotation(box[i]),sides); + dsSetColor (1,1,1); + for (i=0; i< spheres; i++) dsDrawSphere (dGeomGetPosition(sphere[i]), + dGeomGetRotation(sphere[i]),RADIUS); + + // draw the cannon + dsSetColor (1,1,0); + dMatrix3 R2,R3,R4; + dRFromAxisAndAngle (R2,0,0,1,cannon_angle); + dRFromAxisAndAngle (R3,0,1,0,cannon_elevation); + dMultiply0 (R4,R2,R3,3,3,3); + dReal cpos[3] = {CANNON_X,CANNON_Y,1}; + dReal csides[3] = {2,2,2}; + dsDrawBox (cpos,R2,csides); + for (i=0; i<3; i++) cpos[i] += 1.5*R4[i*4+2]; + dsDrawCylinder (cpos,R4,3,0.5); + + // draw the cannon ball + dsDrawSphere (dBodyGetPosition(cannon_ball_body),dBodyGetRotation(cannon_ball_body), + CANNON_BALL_RADIUS); +} + +int main (int argc, char **argv) +{ + doFast = true; + + // setup pointers to drawstuff callback functions + dsFunctions fn; + fn.version = DS_VERSION; + fn.start = &start; + fn.step = &simLoop; + fn.command = &command; + fn.stop = 0; + fn.path_to_textures = DRAWSTUFF_TEXTURE_PATH; + + dInitODE2(0); + + bodies = 0; + joints = 0; + boxes = 0; + spheres = 0; + + setupSimulation(); + + dThreadingImplementationID threading = dThreadingAllocateMultiThreadedImplementation(); + dThreadingThreadPoolID pool = dThreadingAllocateThreadPool(8, 0, dAllocateFlagBasicData, NULL); + dThreadingThreadPoolServeMultiThreadedImplementation(pool, threading); + // dWorldSetStepIslandsProcessingMaxThreadCount(world, 1); + dWorldSetStepThreadingImplementation(world, dThreadingImplementationGetFunctions(threading), threading); + + // run simulation + dsSimulationLoop (argc,argv,352,288,&fn); + + dThreadingImplementationShutdownProcessing(threading); + dThreadingFreeThreadPool(pool); + dWorldSetStepThreadingImplementation(world, NULL, NULL); + dThreadingFreeImplementation(threading); + + shutdownSimulation(); + dCloseODE(); + return 0; +} diff --git a/libs/ode-0.16.1/ode/demo/demo_cyl.cpp b/libs/ode-0.16.1/ode/demo/demo_cyl.cpp new file mode 100644 index 0000000..368a0c1 --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/demo_cyl.cpp @@ -0,0 +1,321 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +// Test for non-capped cylinder, by Bram Stolk +#include +#include +#ifdef HAVE_UNISTD_H +#include +#endif +#include +#include +#include "texturepath.h" + +#include "world_geom3.h" // this is our world mesh + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + + +#define BOX +#define CYL + +// some constants + +#define RADIUS 0.22 // wheel radius +#define WMASS 0.2 // wheel mass +#define WHEELW 0.2 // wheel width +#define BOXSZ 0.4 // box size +//#define CYL_GEOM_OFFSET // rotate cylinder using geom offset + +// dynamics and collision objects (chassis, 3 wheels, environment) + +static dWorldID world; +static dSpaceID space; +#ifdef BOX +static dBodyID boxbody; +static dGeomID boxgeom; +#endif +#ifdef CYL +static dBodyID cylbody; +static dGeomID cylgeom; +#endif +static dJointGroupID contactgroup; +static dGeomID world_mesh; + + +// this is called by dSpaceCollide when two objects in space are +// potentially colliding. + +static void nearCallback (void *data, dGeomID o1, dGeomID o2) +{ + assert(o1); + assert(o2); + + if (dGeomIsSpace(o1) || dGeomIsSpace(o2)) + { + fprintf(stderr,"testing space %p %p\n", (void*)o1, (void*)o2); + // colliding a space with something + dSpaceCollide2(o1,o2,data,&nearCallback); + // Note we do not want to test intersections within a space, + // only between spaces. + return; + } + +// fprintf(stderr,"testing geoms %p %p\n", o1, o2); + + const int N = 32; + dContact contact[N]; + int n = dCollide (o1,o2,N,&(contact[0].geom),sizeof(dContact)); + if (n > 0) + { + for (int i=0; i +#include +#ifdef HAVE_UNISTD_H +#include +#endif +#include +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + + +// dynamics and collision objects (chassis, 3 wheels, environment) + +static dWorldID world; +static dSpaceID space; + +static dBodyID cylbody; +static dGeomID cylgeom; + +static dBodyID sphbody; +static dGeomID sphgeom; + +static dJointGroupID contactgroup; + +static bool show_contacts = true; + +#define CYLRADIUS 0.6 +#define CYLLENGTH 2.0 +#define SPHERERADIUS 0.5 + + +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawLine dsDrawLineD +#endif + + + +// this is called by dSpaceCollide when two objects in space are +// potentially colliding. + +static void nearCallback (void *data, dGeomID o1, dGeomID o2) +{ + assert(o1); + assert(o2); + + if (dGeomIsSpace(o1) || dGeomIsSpace(o2)) + { + fprintf(stderr,"testing space %p %p\n", (void*)o1, (void*)o2); + // colliding a space with something + dSpaceCollide2(o1,o2,data,&nearCallback); + // Note we do not want to test intersections within a space, + // only between spaces. + return; + } + + const int N = 32; + dContact contact[N]; + int n = dCollide (o1,o2,N,&(contact[0].geom),sizeof(dContact)); + if (n > 0) + { + for (int i=0; i +#include +#include "texturepath.h" + +#ifdef dDOUBLE +#define dsDrawSphere dsDrawSphereD +#define dsDrawBox dsDrawBoxD +#define dsDrawLine dsDrawLineD +#endif + + +dWorldID world; +dSpaceID space; +dBodyID body1; +dBodyID body2; +dJointID joint1, joint2; + +void start() +{ + world = dWorldCreate(); + dWorldSetGravity (world,0,0,-9.8); + + dWorldSetDamping(world, 1e-4, 1e-5); +// dWorldSetERP(world, 1); + + space = dSimpleSpaceCreate (0); + + body1 = dBodyCreate(world); + body2 = dBodyCreate(world); + + dBodySetPosition(body1, 0, 0, 3); + dBodySetPosition(body2, 0, 0, 1); + + + dGeomID g; + dMass mass; + + g = dCreateBox(space, 0.2, 0.2, 1); + dGeomSetBody(g, body1); + dMassSetBox(&mass, 1, 0.2, 0.2, 1); + dBodySetMass(body1, &mass); + + g = dCreateBox(space, 0.2, 0.2, 1); + dGeomSetBody(g, body2); + dMassSetBox(&mass, 1, 0.2, 0.2, 1); + dBodySetMass(body2, &mass); + + joint1 = dJointCreateDBall(world, 0); + dJointAttach(joint1, body1, 0); + dJointSetDBallAnchor1(joint1, 0, 0, 3.5); + dJointSetDBallAnchor2(joint1, 0, 0, 4.5); + + joint2 = dJointCreateDBall(world, 0); + dJointAttach(joint2, body1, body2); + dJointSetDBallAnchor1(joint2, 0, 0, 2.5); + dJointSetDBallAnchor2(joint2, 0, 0, 1.5); + + + // initial camera position + static float xyz[3] = {3.8966, -2.0614, 4.0300}; + static float hpr[3] = {153.5, -16.5, 0}; + dsSetViewpoint (xyz,hpr); +} + +void stop() +{ + dSpaceDestroy(space); + + dWorldDestroy(world); +} + + +void drawGeom(dGeomID g) +{ + int gclass = dGeomGetClass(g); + const dReal *pos = dGeomGetPosition(g); + const dReal *rot = dGeomGetRotation(g); + + switch (gclass) { + case dSphereClass: + dsSetColorAlpha(0, 0.75, 0.5, 1); + dsSetTexture (DS_CHECKERED); + dsDrawSphere(pos, rot, dGeomSphereGetRadius(g)); + break; + case dBoxClass: + { + dVector3 lengths; + dsSetColorAlpha(1, 1, 0, 1); + dsSetTexture (DS_WOOD); + dGeomBoxGetLengths(g, lengths); + dsDrawBox(pos, rot, lengths); + break; + } + + default: + {} + } +} + +void simLoop(int pause) +{ + if (!pause) { + + static dReal t = 0; + + const dReal step = 0.005; + const unsigned nsteps = 4; + + for (unsigned i=0; i +#include +#include "texturepath.h" + +#ifdef dDOUBLE +#define dsDrawSphere dsDrawSphereD +#define dsDrawBox dsDrawBoxD +#define dsDrawLine dsDrawLineD +#endif + + +dWorldID world; +dSpaceID space; +dBodyID body1; +dBodyID body2; +dJointID joint1, joint2; +bool applyForce = false; + +void start() +{ + world = dWorldCreate(); + dWorldSetGravity (world,0,0,-9.8); + + dWorldSetDamping(world, 1e-4, 1e-5); +// dWorldSetERP(world, 1); + + space = dSimpleSpaceCreate (0); + + body1 = dBodyCreate(world); + body2 = dBodyCreate(world); + + dBodySetPosition(body1, 0, 0, 3); + dBodySetPosition(body2, 0, 0, 1); + + + dGeomID g; + dMass mass; + + g = dCreateBox(space, 0.2, 0.2, 1); + dGeomSetBody(g, body1); + dMassSetBox(&mass, 1, 0.2, 0.2, 1); + dBodySetMass(body1, &mass); + + g = dCreateBox(space, 0.2, 0.2, 1); + dGeomSetBody(g, body2); + dMassSetBox(&mass, 1, 0.2, 0.2, 1); + dBodySetMass(body2, &mass); + +#if 1 + joint1 = dJointCreateDHinge(world, 0); + dJointAttach(joint1, body1, 0); + dJointSetDHingeAxis(joint1, 0, 1, 0); + dJointSetDHingeAnchor1(joint1, 0, 0, 3.5); + dJointSetDHingeAnchor2(joint1, 0, 0, 4.5); +#endif + +#if 1 + joint2 = dJointCreateDHinge(world, 0); + dJointAttach(joint2, body1, body2); + dJointSetDHingeAxis(joint2, 1, 0, 0); + dJointSetDHingeAnchor1(joint2, 0, 0, 2.5); + dJointSetDHingeAnchor2(joint2, 0, 0, 1.5); +#else + joint2 = dJointCreateDBall(world, 0); + dJointAttach(joint2, body1, body2); + dJointSetDBallAnchor1(joint2, 0, 0, 2.5); + dJointSetDBallAnchor2(joint2, 0, 0, 1.5); +#endif + + //dBodyAddForce(body1, 20, 0, 0); + + + // initial camera position + static float xyz[3] = {3.8966, -2.0614, 4.0300}; + static float hpr[3] = {153.5, -16.5, 0}; + dsSetViewpoint (xyz,hpr); +} + +void stop() +{ + dSpaceDestroy(space); + + dWorldDestroy(world); +} + + +void drawGeom(dGeomID g) +{ + int gclass = dGeomGetClass(g); + const dReal *pos = dGeomGetPosition(g); + const dReal *rot = dGeomGetRotation(g); + + switch (gclass) { + case dBoxClass: + { + dVector3 lengths; + if (applyForce) + dsSetColor(1, .5, 0); + else + dsSetColor(1, 1, 0); + dsSetTexture (DS_WOOD); + dGeomBoxGetLengths(g, lengths); + dsDrawBox(pos, rot, lengths); + break; + } + + default: + {} + } +} + + +void simLoop(int pause) +{ + if (!pause) { + + static dReal t = 0; + + const dReal step = 0.005; + const unsigned nsteps = 2; + + for (unsigned i=0; i 2.; + + if (applyForce) { + dReal f = 0.3 * sin(t*1.2); + dBodyAddForceAtRelPos(body1, + f, 0, 0, + 0, 0, -0.5); // at the lower end + + dReal g = 0.3 * sin(t*0.7); + dBodyAddForceAtRelPos(body2, + 0, g, 0, + 0, 0, -0.5); // at the lower end + } + + t += step; + if (t > 20.) + t = 0.; + + dWorldQuickStep(world, step); + } + } + + // now we draw everything + unsigned ngeoms = dSpaceGetNumGeoms(space); + for (unsigned i=0; i +#include +#ifdef HAVE_UNISTD_H +#include +#endif +#include +#include +#include "texturepath.h" + + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawCylinder dsDrawCylinderD +#endif + + +// dynamics and collision objects (chassis, 3 wheels, environment) + +static dWorldID world; +static dSpaceID space; + +static const int STACKCNT=10; // nr of weights on bridge +static const int SEGMCNT=16; // nr of segments in bridge +static const float SEGMDIM[3] = { 0.9, 4, 0.1 }; + +static dGeomID groundgeom; +static dBodyID segbodies[SEGMCNT]; +static dGeomID seggeoms[SEGMCNT]; +static dBodyID stackbodies[STACKCNT]; +static dGeomID stackgeoms[STACKCNT]; +static dJointID hinges[SEGMCNT-1]; +static dJointID sliders[2]; +static dJointFeedback jfeedbacks[SEGMCNT-1]; +static dReal colours[SEGMCNT]; +static int stress[SEGMCNT-1]; + +static dJointGroupID contactgroup; + + +// this is called by dSpaceCollide when two objects in space are +// potentially colliding. + +static void nearCallback (void *data, dGeomID o1, dGeomID o2) +{ + assert(o1); + assert(o2); + + if (dGeomIsSpace(o1) || dGeomIsSpace(o2)) + { + fprintf(stderr,"testing space %p %p\n", (void*)o1, (void*)o2); + // colliding a space with something + dSpaceCollide2(o1,o2,data,&nearCallback); + // Note we do not want to test intersections within a space, + // only between spaces. + return; + } + + const int N = 32; + dContact contact[N]; + int n = dCollide (o1,o2,N,&(contact[0].geom),sizeof(dContact)); + if (n > 0) + { + for (int i=0; i forcelimit || l1 > forcelimit) + stress[i]++; + else + stress[i]=0; + if (stress[i]>4) + { + // Low-pass filter the noisy feedback data. + // Only after 4 consecutive timesteps with excessive load, snap. + fprintf(stderr,"SNAP! (that was the sound of joint %d breaking)\n", i); + dJointAttach (hinges[i], 0, 0); + } + } + } +} + + +// simulation loop + +static void simLoop (int pause) +{ + int i; + + double simstep = 0.002; // 2ms simulation steps + double dt = dsElapsedTime(); + int nrofsteps = (int) ceilf(dt/simstep); + for (i=0; i1.0) v=1.0; + if (v<0.5) + { + r=2*v; + g=1.0; + } + else + { + r=1.0; + g=2*(1.0-v); + } + dsSetColor (r,g,b); + drawGeom(seggeoms[i]); + } + dsSetColor (1,1,1); + for (i=0; i MU * body_mass * GRAVITY + (j+1)*FORCE > MU * (i+1)*MASS * GRAVITY + (j+1) > (i+1) * (MU*MASS*GRAVITY/FORCE) + (j+1) > (i+1) * k + +this should be independent of the number of contact points, as N contact +points will each have 1/N'th the normal force but the pushing force will +have to overcome N contacts. the constants are chosen so that k=1. +thus you should see a triangle made of half the bodies in the array start to +slide. + +*/ + + +#include +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +// select correct drawing functions + +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawSphere dsDrawSphereD +#define dsDrawCylinder dsDrawCylinderD +#define dsDrawCapsule dsDrawCapsuleD +#endif + + +// some constants + +#define LENGTH 0.2 // box length & width +#define HEIGHT 0.05 // box height +#define MASS 0.2 // mass of box[i][j] = (i+1) * MASS +#define FORCE 0.05 // force applied to box[i][j] = (j+1) * FORCE +#define MU 0.5 // the global mu to use +#define GRAVITY 0.5 // the global gravity to use +#define N1 10 // number of different forces to try +#define N2 10 // number of different masses to try + + +// dynamics and collision objects + +static dWorldID world; +static dSpaceID space; +static dBodyID body[N1][N2]; +static dJointGroupID contactgroup; +static dGeomID ground; +static dGeomID box[N1][N2]; + + + +// this is called by dSpaceCollide when two objects in space are +// potentially colliding. + +static void nearCallback (void *, dGeomID o1, dGeomID o2) +{ + int i; + + // only collide things with the ground + int g1 = (o1 == ground); + int g2 = (o2 == ground); + if (!(g1 ^ g2)) return; + + dBodyID b1 = dGeomGetBody(o1); + dBodyID b2 = dGeomGetBody(o2); + + dContact contact[3]; // up to 3 contacts per box + for (i=0; i<3; i++) { + contact[i].surface.mode = dContactSoftCFM | dContactApprox1; + contact[i].surface.mu = MU; + contact[i].surface.soft_cfm = 0.01; + } + if (int numc = dCollide (o1,o2,3,&contact[0].geom,sizeof(dContact))) { + for (i=0; i +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +// select correct drawing functions +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawSphere dsDrawSphereD +#define dsDrawCylinder dsDrawCylinderD +#define dsDrawCapsule dsDrawCapsuleD +#endif + +// dynamics and collision objects +static dWorldID world = 0; + +static const dReal dt = 1/REAL(60.0); // 60 fps +// Water density if units are meters and kg +static const dReal density = 1000; + +// A long skinny thing +static dVector3 sides = {2,.5,.25}; +// Initial angular velocity +static dVector3 omega = {5,1,2}; +static dVector3 torque = {0,10,0}; +static dBodyID noGyroBody; +static dBodyID expGyroBody; +static dBodyID impGyroBody; + +// start simulation - set viewpoint + +static void start() +{ + dAllocateODEDataForThread(dAllocateMaskAll); + + static float xyz[3] = {0,-4.0f,3.0f}; + static float hpr[3] = {90.0000,-15.0000,0.0000}; + dsSetViewpoint (xyz,hpr); + printf ("Press:\n" + "\t'a' to apply a torque\n" + "\t'r' to reset simulation.\n"); +} + +/** + Delete the bodies, etc. +*/ +static void clear() +{ + if (world) dWorldDestroy (world); + world = 0; +} + + + +/** + Cleanup if necessary and rebuild the + world. +*/ +static void reset() +{ + clear(); + + // create world + world = dWorldCreate(); + + // Calculate mass for a box; + dMass boxMass; + dMassSetBox(&boxMass,density,sides[0],sides[1],sides[2]); + + noGyroBody = dBodyCreate(world);// Conservation of ang-velocity + expGyroBody = dBodyCreate(world);// Explicit conservation of ang-momentum + impGyroBody = dBodyCreate(world);// Implicit conservation of ang-momentum + + dBodySetMass( noGyroBody , &boxMass ); + dBodySetMass( expGyroBody, &boxMass ); + dBodySetMass( impGyroBody, &boxMass ); + + // Try to avoid collisions. + dReal sep = dCalcVectorLength3(sides); + dBodySetPosition( noGyroBody , -sep, 0, sep); + dBodySetPosition( expGyroBody, 0, 0, sep); + dBodySetPosition( impGyroBody, sep, 0, sep); + + // Set the initial angular velocity + dBodySetAngularVel( noGyroBody , omega[0], omega[1], omega[2]); + dBodySetAngularVel( expGyroBody, omega[0], omega[1], omega[2]); + dBodySetAngularVel( impGyroBody, omega[0], omega[1], omega[2]); + + dBodySetGyroscopicMode( noGyroBody, 0); + // We compute this ourselves using the math + // that was in the old stepper. + dBodySetGyroscopicMode(expGyroBody, 0); + // Keep things from crashing by limiting + // the angular speed of the explicit body. + // Note that this isn't necessary for + // the other two bodies. + dBodySetMaxAngularSpeed( expGyroBody, 40 ); +} + +static void command (int cmd) +{ + switch (cmd) { + case 'a': case 'A': + dBodyAddTorque( noGyroBody, torque[0], torque[1], torque[2]); + dBodyAddTorque(expGyroBody, torque[0], torque[1], torque[2]); + dBodyAddTorque(impGyroBody, torque[0], torque[1], torque[2]); + break; + case 'r': case 'R': + reset(); + break; + } + +} + +/** + This is the explicit computation of + gyroscopic forces. +*/ +static void expStep(dBodyID body) +{ + // Explicit computation + dMatrix3 I,tmp; + dMass m; + dBodyGetMass(body,&m); + const dReal* R = dBodyGetRotation(body); + // compute inertia tensor in global frame + dMultiply2_333 (tmp,m.I,R); + dMultiply0_333 (I,R,tmp); + // compute explicit rotational force + // we treat 'tmp'like a vector, but that's okay. + const dReal* w = dBodyGetAngularVel(body); + dMultiply0_331 (tmp,I,w); + dVector3 tau; + dCalcVectorCross3(tau,tmp,w); + dBodyAddTorque(body,tau[0],tau[1],tau[2]); +} + + +// simulation loop +static void simLoop (int pause) +{ + if (!pause) { + expStep(expGyroBody); + dWorldStep (world,dt); + } + + dsSetTexture (DS_WOOD); + dsSetColor(1,0,0); + dsDrawBox(dBodyGetPosition(noGyroBody ),dBodyGetRotation(noGyroBody ),sides); + dsSetColor(1,1,0); + dsDrawBox(dBodyGetPosition(expGyroBody),dBodyGetRotation(expGyroBody),sides); + dsSetColor(0,1,0); + dsDrawBox(dBodyGetPosition(impGyroBody),dBodyGetRotation(impGyroBody),sides); +} + + +int main (int argc, char **argv) +{ + // setup pointers to drawstuff callback functions + dsFunctions fn; + fn.version = DS_VERSION; + fn.start = &start; + fn.step = &simLoop; + fn.command = &command; + fn.stop = 0; + fn.path_to_textures = DRAWSTUFF_TEXTURE_PATH; + + dInitODE2(0); + reset(); + + // run simulation + dsSimulationLoop (argc,argv,352,288,&fn); + + clear(); + dCloseODE(); + return 0; +} diff --git a/libs/ode-0.16.1/ode/demo/demo_gyroscopic.cpp b/libs/ode-0.16.1/ode/demo/demo_gyroscopic.cpp new file mode 100644 index 0000000..5b6a532 --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/demo_gyroscopic.cpp @@ -0,0 +1,258 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#include +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +// select correct drawing functions + +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawSphere dsDrawSphereD +#define dsDrawCylinder dsDrawCylinderD +#define dsDrawCapsule dsDrawCapsuleD +#define dsDrawConvex dsDrawConvexD +#endif + +bool write_world = false; +bool show_contacts = false; +dWorld * world; +dBody *top1, *top2; +dSpace *space; +dJointGroup contactgroup; + +const dReal pinradius = 0.05f; +const dReal pinlength = 1.5f; +const dReal topradius = 1.0f; +const dReal toplength = 0.25f; +const dReal topmass = 1.0f; + +#define MAX_CONTACTS 4 + +static void nearCallback (void *, dGeomID o1, dGeomID o2) +{ + // for drawing the contact points + dMatrix3 RI; + dRSetIdentity (RI); + const dReal ss[3] = {0.02,0.02,0.02}; + + int i; + dBodyID b1 = dGeomGetBody(o1); + dBodyID b2 = dGeomGetBody(o2); + + dContact contact[MAX_CONTACTS]; + int numc = dCollide (o1,o2,MAX_CONTACTS,&contact[0].geom, + sizeof(dContact)); + + for (i=0; i= 'A' && c <= 'Z') return c - ('a'-'A'); + else return c; +} + + +// called when a key pressed +static void reset(); +static void tilt(); + +static void command (int cmd) +{ + cmd = locase (cmd); + if (cmd == ' ') + { + reset(); + } + else if (cmd == 'a') { + tilt(); + } + else if (cmd == 't') { + show_contacts = !show_contacts; + } + else if (cmd == '1') { + write_world = true; + } +} + +// simulation loop + +static void simLoop (int pause) +{ + dsSetColor (0,0,2); + space->collide(0,&nearCallback); + if (!pause) + //world->quickStep(0.02); + world->step(0.02); + + if (write_world) { + FILE *f = fopen ("state.dif","wt"); + if (f) { + dWorldExportDIF (*world,f,"X"); + fclose (f); + } + write_world = false; + } + + // remove all contact joints + dJointGroupEmpty (contactgroup); + + dsSetTexture (DS_WOOD); + + dsSetColor (1,0.5f,0); + dsDrawCylinder(top1->getPosition(), + top1->getRotation(), + toplength, topradius); + dsDrawCapsule(top1->getPosition(), + top1->getRotation(), + pinlength, pinradius); + + dsSetColor (0.5f,1,0); + dsDrawCylinder(top2->getPosition(), + top2->getRotation(), + toplength, topradius); + dsDrawCapsule(top2->getPosition(), + top2->getRotation(), + pinlength, pinradius); + +} + + +static void reset() +{ + dMatrix3 R; + dRSetIdentity(R); + + top1->setRotation(R); + top2->setRotation(R); + + top1->setPosition(0.8f, -2, 2); + top2->setPosition(0.8f, 2, 2); + + top1->setAngularVel(1,0,7); + top2->setAngularVel(1,0,7); + + top1->setLinearVel(0,0.2f,0); + top2->setLinearVel(0,0.2f,0); +} + +static void tilt() +{ + top1->addTorque(0, 10, 0); + top2->addTorque(0, 10, 0); +} + +int main (int argc, char **argv) +{ + // setup pointers to drawstuff callback functions + dsFunctions fn; + fn.version = DS_VERSION; + fn.start = &start; + fn.step = &simLoop; + fn.command = &command; + fn.stop = 0; + fn.path_to_textures = DRAWSTUFF_TEXTURE_PATH; + + + // create world + dInitODE(); + world = new dWorld(); + world->setGravity(0,0,-0.5f); + world->setCFM(1e-5f); + world->setLinearDamping(0.00001f); + world->setAngularDamping(0.0001f); + + space = new dSimpleSpace(0); + + dPlane *floor = new dPlane(*space, 0,0,1,0); + + top1 = new dBody(*world); + top2 = new dBody(*world); + + dMass m; + m.setCylinderTotal(1, 3, topradius, toplength); + top1->setMass(m); + top2->setMass(m); + + dGeom *g1, *g2, *pin1, *pin2; + g1 = new dCylinder(*space, topradius, toplength); + g1->setBody(*top1); + g2 = new dCylinder(*space, topradius, toplength); + g2->setBody(*top2); + + pin1 = new dCapsule(*space, pinradius, pinlength); + pin1->setBody(*top1); + pin2 = new dCapsule(*space, pinradius, pinlength); + pin2->setBody(*top2); + + top2->setGyroscopicMode(false); + + reset(); + + // run simulation + dsSimulationLoop (argc,argv,512,384,&fn); + + delete g1; + delete g2; + delete pin1; + delete pin2; + delete floor; + contactgroup.empty(); + delete top1; + delete top2; + delete space; + delete world; + dCloseODE(); +} diff --git a/libs/ode-0.16.1/ode/demo/demo_heightfield.cpp b/libs/ode-0.16.1/ode/demo/demo_heightfield.cpp new file mode 100644 index 0000000..d68cb6a --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/demo_heightfield.cpp @@ -0,0 +1,714 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#include +#include +#include "texturepath.h" +#include "bunny_geom.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + + +#define DEGTORAD 0.01745329251994329577f //!< PI / 180.0, convert degrees to radians + +int g_allow_trimesh; + +// Our heightfield geom +dGeomID gheight; + + + +// Heightfield dimensions + +#define HFIELD_WSTEP 15 // Vertex count along edge >= 2 +#define HFIELD_DSTEP 31 + +#define HFIELD_WIDTH REAL( 4.0 ) +#define HFIELD_DEPTH REAL( 8.0 ) + +#define HFIELD_WSAMP ( HFIELD_WIDTH / ( HFIELD_WSTEP-1 ) ) +#define HFIELD_DSAMP ( HFIELD_DEPTH / ( HFIELD_DSTEP-1 ) ) + + + +//<---- Convex Object +dReal planes[]= // planes for a cube + { + 1.0f ,0.0f ,0.0f ,0.25f, + 0.0f ,1.0f ,0.0f ,0.25f, + 0.0f ,0.0f ,1.0f ,0.25f, + 0.0f ,0.0f ,-1.0f,0.25f, + 0.0f ,-1.0f,0.0f ,0.25f, + -1.0f,0.0f ,0.0f ,0.25f + /* + 1.0f ,0.0f ,0.0f ,2.0f, + 0.0f ,1.0f ,0.0f ,1.0f, + 0.0f ,0.0f ,1.0f ,1.0f, + 0.0f ,0.0f ,-1.0f,1.0f, + 0.0f ,-1.0f,0.0f ,1.0f, + -1.0f,0.0f ,0.0f ,0.0f + */ + }; +const unsigned int planecount=6; + +dReal points[]= // points for a cube + { + 0.25f,0.25f,0.25f, // point 0 + -0.25f,0.25f,0.25f, // point 1 + + 0.25f,-0.25f,0.25f, // point 2 + -0.25f,-0.25f,0.25f,// point 3 + + 0.25f,0.25f,-0.25f, // point 4 + -0.25f,0.25f,-0.25f,// point 5 + + 0.25f,-0.25f,-0.25f,// point 6 + -0.25f,-0.25f,-0.25f,// point 7 + }; +const unsigned int pointcount=8; +unsigned int polygons[] = //Polygons for a cube (6 squares) + { + 4,0,2,6,4, // positive X + 4,1,0,4,5, // positive Y + 4,0,1,3,2, // positive Z + 4,3,1,5,7, // negative X + 4,2,3,7,6, // negative Y + 4,5,4,6,7, // negative Z + }; +//----> Convex Object + +// select correct drawing functions + +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawSphere dsDrawSphereD +#define dsDrawCylinder dsDrawCylinderD +#define dsDrawCapsule dsDrawCapsuleD +#define dsDrawConvex dsDrawConvexD +#define dsDrawTriangle dsDrawTriangleD +#endif + + +// some constants + +#define NUM 100 // max number of objects +#define DENSITY (5.0) // density of all objects +#define GPB 3 // maximum number of geometries per body +#define MAX_CONTACTS 64 // maximum number of contact points per body + + +// dynamics and collision objects + +struct MyObject { + dBodyID body; // the body + dGeomID geom[GPB]; // geometries representing this body + + // Trimesh only - double buffered matrices for 'last transform' setup + dReal matrix_dblbuff[ 16 * 2 ]; + int last_matrix_index; +}; + +static int num=0; // number of objects in simulation +static int nextobj=0; // next object to recycle if num==NUM +static dWorldID world; +static dSpaceID space; +static MyObject obj[NUM]; +static dJointGroupID contactgroup; +static int selected = -1; // selected object +static int show_aabb = 0; // show geom AABBs? +static int show_contacts = 0; // show contact points? +static int random_pos = 1; // drop objects from random position? +static int write_world = 0; + + + + +//============================ + +dGeomID TriMesh1; +dGeomID TriMesh2; +//static dTriMeshDataID TriData1, TriData2; // reusable static trimesh data + +//============================ + + +dReal heightfield_callback( void*, int x, int z ) +{ + dReal fx = ( ((dReal)x) - ( HFIELD_WSTEP-1 )/2 ) / (dReal)( HFIELD_WSTEP-1 ); + dReal fz = ( ((dReal)z) - ( HFIELD_DSTEP-1 )/2 ) / (dReal)( HFIELD_DSTEP-1 ); + + // Create an interesting 'hump' shape + dReal h = REAL( 1.0 ) + ( REAL( -16.0 ) * ( fx*fx*fx + fz*fz*fz ) ); + + return h; +} + + + + +// this is called by dSpaceCollide when two objects in space are +// potentially colliding. + +static void nearCallback (void *, dGeomID o1, dGeomID o2) +{ + int i; + // if (o1->body && o2->body) return; + + // exit without doing anything if the two bodies are connected by a joint + dBodyID b1 = dGeomGetBody(o1); + dBodyID b2 = dGeomGetBody(o2); + if (b1 && b2 && dAreConnectedExcluding(b1,b2,dJointTypeContact)) + return; + + dContact contact[MAX_CONTACTS]; // up to MAX_CONTACTS contacts per box-box + for (i=0; i= 'A' && c <= 'Z') return c - ('a'-'A'); + else return c; +} + + +// called when a key pressed + +static void command(int cmd) +{ + dsizeint i; + int j,k; + dReal sides[3]; + dMass m; + bool setBody = false; + + cmd = locase (cmd); + + + // + // Geom Creation + // + + if ( cmd == 'b' || cmd == 's' || cmd == 'c' || ( cmd == 'm' && g_allow_trimesh ) || + cmd == 'x' || cmd == 'y' || cmd == 'v' ) { + + if ( num < NUM ) { + i = num; + num++; + } else { + i = nextobj++; + nextobj %= num; + + // destroy the body and geoms for slot i + dBodyDestroy(obj[i].body); + obj[i].body = 0; + + for (k=0; k < GPB; k++) + if (obj[i].geom[k]) { + dGeomDestroy(obj[i].geom[k]); + obj[i].geom[k] = 0; + } + } + + obj[i].body = dBodyCreate(world); + for (k=0; k<3; k++) + sides[k] = dRandReal()*0.5+0.1; + + dMatrix3 R; + if (random_pos) { + dBodySetPosition(obj[i].body, + (dRandReal()-0.5)*HFIELD_WIDTH*0.75, + (dRandReal()-0.5)*HFIELD_DEPTH*0.75, + dRandReal() + 2 ); + dRFromAxisAndAngle(R,dRandReal()*2.0-1.0,dRandReal()*2.0-1.0, + dRandReal()*2.0-1.0,dRandReal()*10.0-5.0); + } else { + dReal maxheight = 0; + for (k=0; k maxheight) + maxheight = pos[2]; + } + dBodySetPosition(obj[i].body, 0,maxheight+1,0); + dRFromAxisAndAngle(R,0,0,1,dRandReal()*10.0-5.0); + } + + dBodySetRotation(obj[i].body,R); + + if (cmd == 'b') { + + dMassSetBox(&m,DENSITY,sides[0],sides[1],sides[2]); + obj[i].geom[0] = dCreateBox(space,sides[0],sides[1],sides[2]); + + } else if (cmd == 'c') { + + sides[0] *= 0.5; + dMassSetCapsule(&m,DENSITY,3,sides[0],sides[1]); + obj[i].geom[0] = dCreateCapsule(space,sides[0],sides[1]); + + } else if (cmd == 'v') { + + dMassSetBox (&m,DENSITY,0.25,0.25,0.25); + obj[i].geom[0] = dCreateConvex(space, + planes, + planecount, + points, + pointcount, + polygons); + + } else if (cmd == 'y') { + + dMassSetCylinder(&m,DENSITY,3,sides[0],sides[1]); + obj[i].geom[0] = dCreateCylinder(space,sides[0],sides[1]); + + } else if (cmd == 's') { + + sides[0] *= 0.5; + dMassSetSphere(&m,DENSITY,sides[0]); + obj[i].geom[0] = dCreateSphere(space,sides[0]); + + } else if (cmd == 'm' && g_allow_trimesh) { + + dTriMeshDataID new_tmdata = dGeomTriMeshDataCreate(); + dGeomTriMeshDataBuildSingle(new_tmdata, &Vertices[0], 3 * sizeof(float), VertexCount, + &Indices[0], IndexCount, 3 * sizeof(dTriIndex)); + dGeomTriMeshDataPreprocess2(new_tmdata, (1U << dTRIDATAPREPROCESS_BUILD_FACE_ANGLES), NULL); + + obj[i].geom[0] = dCreateTriMesh(space, new_tmdata, 0, 0, 0); + + dMassSetTrimesh( &m, DENSITY, obj[i].geom[0] ); + printf("mass at %f %f %f\n", m.c[0], m.c[1], m.c[2]); + dGeomSetPosition(obj[i].geom[0], -m.c[0], -m.c[1], -m.c[2]); + dMassTranslate(&m, -m.c[0], -m.c[1], -m.c[2]); + + } else if (cmd == 'x') { + + setBody = 1; + // start accumulating masses for the composite geometries + dMass m2; + dMassSetZero (&m); + + dReal dpos[GPB][3]; // delta-positions for composite geometries + dMatrix3 drot[GPB]; + + // set random delta positions + for (j=0; j= num) + selected = 0; + if (selected < -1) + selected = 0; + + } else if (cmd == 'd' && selected >= 0 && selected < num) { + + dBodyDisable(obj[selected].body); + + } else if (cmd == 'e' && selected >= 0 && selected < num) { + + dBodyEnable(obj[selected].body); + + } else if (cmd == 'a') { + + show_aabb = !show_aabb; + + } else if (cmd == 't') { + + show_contacts = !show_contacts; + + } else if (cmd == 'r') { + + random_pos = !random_pos; + + } else if (cmd == '1') { + + write_world = 1; + + } +} + + +// draw a geom + +void drawGeom (dGeomID g, const dReal *pos, const dReal *R, int show_aabb) +{ + if (!g) + return; + if (!pos) + pos = dGeomGetPosition(g); + if (!R) + R = dGeomGetRotation(g); + + int type = dGeomGetClass(g); + if (type == dBoxClass) { + + dVector3 sides; + dGeomBoxGetLengths(g,sides); + dsDrawBox(pos,R,sides); + + } else if (type == dSphereClass) { + + dsDrawSphere(pos,R,dGeomSphereGetRadius(g)); + + } else if (type == dCapsuleClass) { + + dReal radius,length; + dGeomCapsuleGetParams(g,&radius,&length); + dsDrawCapsule(pos,R,length,radius); + + } else if (type == dConvexClass) { + + //dVector3 sides={0.50,0.50,0.50}; + dsDrawConvex(pos,R,planes, + planecount, + points, + pointcount, + polygons); + + } else if (type == dCylinderClass) { + + dReal radius,length; + dGeomCylinderGetParams(g,&radius,&length); + dsDrawCylinder(pos,R,length,radius); + + } else if (type == dTriMeshClass) { + + dTriIndex* Indices = (dTriIndex*)::Indices; + + // assume all trimeshes are drawn as bunnies + for (int ii = 0; ii < IndexCount / 3; ii++) { + const dReal v[9] = { // explicit conversion from float to dReal + Vertices[Indices[ii * 3 + 0] * 3 + 0], + Vertices[Indices[ii * 3 + 0] * 3 + 1], + Vertices[Indices[ii * 3 + 0] * 3 + 2], + Vertices[Indices[ii * 3 + 1] * 3 + 0], + Vertices[Indices[ii * 3 + 1] * 3 + 1], + Vertices[Indices[ii * 3 + 1] * 3 + 2], + Vertices[Indices[ii * 3 + 2] * 3 + 0], + Vertices[Indices[ii * 3 + 2] * 3 + 1], + Vertices[Indices[ii * 3 + 2] * 3 + 2] + }; + dsDrawTriangle(pos, R, &v[0], &v[3], &v[6], 1); + } + + } else if (type == dHeightfieldClass) { + + // Set ox and oz to zero for DHEIGHTFIELD_CORNER_ORIGIN mode. + int ox = (int) ( -HFIELD_WIDTH/2 ); + int oz = (int) ( -HFIELD_DEPTH/2 ); + + // for ( int tx = -1; tx < 2; ++tx ) + // for ( int tz = -1; tz < 2; ++tz ) + dsSetColorAlpha (0.5,1,0.5,0.5); + dsSetTexture( DS_WOOD ); + + for ( int i = 0; i < HFIELD_WSTEP - 1; ++i ) + for ( int j = 0; j < HFIELD_DSTEP - 1; ++j ) { + dReal a[3], b[3], c[3], d[3]; + + a[ 0 ] = ox + ( i ) * HFIELD_WSAMP; + a[ 1 ] = heightfield_callback( NULL, i, j ); + a[ 2 ] = oz + ( j ) * HFIELD_DSAMP; + + b[ 0 ] = ox + ( i + 1 ) * HFIELD_WSAMP; + b[ 1 ] = heightfield_callback( NULL, i + 1, j ); + b[ 2 ] = oz + ( j ) * HFIELD_DSAMP; + + c[ 0 ] = ox + ( i ) * HFIELD_WSAMP; + c[ 1 ] = heightfield_callback( NULL, i, j + 1 ); + c[ 2 ] = oz + ( j + 1 ) * HFIELD_DSAMP; + + d[ 0 ] = ox + ( i + 1 ) * HFIELD_WSAMP; + d[ 1 ] = heightfield_callback( NULL, i + 1, j + 1 ); + d[ 2 ] = oz + ( j + 1 ) * HFIELD_DSAMP; + + dsDrawTriangle( pos, R, a, c, b, 1 ); + dsDrawTriangle( pos, R, b, c, d, 1 ); + } + + } + + if (show_aabb) { + // draw the bounding box for this geom + dReal aabb[6]; + dGeomGetAABB(g,aabb); + dVector3 bbpos; + for (int i=0; i<3; i++) + bbpos[i] = 0.5*(aabb[i*2] + aabb[i*2+1]); + dVector3 bbsides; + for (int i=0; i<3; i++) + bbsides[i] = aabb[i*2+1] - aabb[i*2]; + dMatrix3 RI; + dRSetIdentity(RI); + dsSetColorAlpha(1,0,0,0.5); + dsDrawBox(bbpos,RI,bbsides); + } + +} + +// simulation loop + +static void simLoop (int pause) +{ + int i,j; + + dSpaceCollide(space,0,&nearCallback); + + if (!pause) + dWorldQuickStep(world,0.05); + + + if (write_world) { + FILE *f = fopen ("state.dif","wt"); + if (f) { + dWorldExportDIF(world,f,"X"); + fclose (f); + } + write_world = 0; + } + + // remove all contact joints + dJointGroupEmpty(contactgroup); + + + + // + // Draw Heightfield + // + + drawGeom(gheight, 0, 0, 0); + + + + dsSetColor (1,1,0); + dsSetTexture (DS_WOOD); + for (i=0; i +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +// select correct drawing functions +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#endif + + +// some constants +#define SIDE (0.5f) // side length of a box +#define MASS (1.0) // mass of a box + + +// dynamics and collision objects +static dWorldID world; +static dBodyID body[2]; +static dJointID hinge; + + +// state set by keyboard commands +static int occasional_error = 0; + + +// start simulation - set viewpoint + +static void start() +{ + dAllocateODEDataForThread(dAllocateMaskAll); + + static float xyz[3] = {1.0382f,-1.0811f,1.4700f}; + static float hpr[3] = {135.0000f,-19.5000f,0.0000f}; + dsSetViewpoint (xyz,hpr); + printf ("Press 'e' to start/stop occasional error.\n"); +} + + +// called when a key pressed + +static void command (int cmd) +{ + if (cmd == 'e' || cmd == 'E') { + occasional_error ^= 1; + } +} + + +// simulation loop + +static void simLoop (int pause) +{ + const dReal kd = -0.3; // angular damping constant + if (!pause) { + // add an oscillating torque to body 0, and also damp its rotational motion + static dReal a=0; + const dReal *w = dBodyGetAngularVel (body[0]); + dBodyAddTorque (body[0],kd*w[0],kd*w[1]+0.1*cos(a),kd*w[2]+0.1*sin(a)); + dWorldStep (world,0.05); + a += 0.01; + + // occasionally re-orient one of the bodies to create a deliberate error. + if (occasional_error) { + static int count = 0; + if ((count % 20)==0) { + // randomly adjust orientation of body[0] + const dReal *R1; + dMatrix3 R2,R3; + R1 = dBodyGetRotation (body[0]); + dRFromAxisAndAngle (R2,dRandReal()-0.5,dRandReal()-0.5, + dRandReal()-0.5,dRandReal()-0.5); + dMultiply0 (R3,R1,R2,3,3,3); + dBodySetRotation (body[0],R3); + + // randomly adjust position of body[0] + const dReal *pos = dBodyGetPosition (body[0]); + dBodySetPosition (body[0], + pos[0]+0.2*(dRandReal()-0.5), + pos[1]+0.2*(dRandReal()-0.5), + pos[2]+0.2*(dRandReal()-0.5)); + } + count++; + } + } + + dReal sides1[3] = {SIDE,SIDE,SIDE}; + dReal sides2[3] = {SIDE,SIDE,SIDE*0.8f}; + dsSetTexture (DS_WOOD); + dsSetColor (1,1,0); + dsDrawBox (dBodyGetPosition(body[0]),dBodyGetRotation(body[0]),sides1); + dsSetColor (0,1,1); + dsDrawBox (dBodyGetPosition(body[1]),dBodyGetRotation(body[1]),sides2); +} + + +int main (int argc, char **argv) +{ + // setup pointers to drawstuff callback functions + dsFunctions fn; + fn.version = DS_VERSION; + fn.start = &start; + fn.step = &simLoop; + fn.command = &command; + fn.stop = 0; + fn.path_to_textures = DRAWSTUFF_TEXTURE_PATH; + + // create world + dInitODE2(0); + world = dWorldCreate(); + + dMass m; + dMassSetBox (&m,1,SIDE,SIDE,SIDE); + dMassAdjust (&m,MASS); + + dQuaternion q; + dQFromAxisAndAngle (q,1,1,0,0.25*M_PI); + + body[0] = dBodyCreate (world); + dBodySetMass (body[0],&m); + dBodySetPosition (body[0],0.5*SIDE,0.5*SIDE,1); + dBodySetQuaternion (body[0],q); + + body[1] = dBodyCreate (world); + dBodySetMass (body[1],&m); + dBodySetPosition (body[1],-0.5*SIDE,-0.5*SIDE,1); + dBodySetQuaternion (body[1],q); + + hinge = dJointCreateHinge (world,0); + dJointAttach (hinge,body[0],body[1]); + dJointSetHingeAnchor (hinge,0,0,1); + dJointSetHingeAxis (hinge,1,-1,1.41421356); + + // run simulation + dsSimulationLoop (argc,argv,352,288,&fn); + + dWorldDestroy (world); + dCloseODE(); + return 0; +} diff --git a/libs/ode-0.16.1/ode/demo/demo_jointPR.cpp b/libs/ode-0.16.1/ode/demo/demo_jointPR.cpp new file mode 100644 index 0000000..b760af1 --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/demo_jointPR.cpp @@ -0,0 +1,434 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +/* + +This file try to demonstrate how the PR joint is working. + +The axisP is draw in red and the axisR is in green + +*/ + + +#include +#include +#include +#include +#include "texturepath.h" + + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif +// select correct drawing functions +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#endif + + +// physics parameters +#define BOX1_LENGTH 2 // Size along the X axis +#define BOX1_WIDTH 1 // Size along the Y axis +#define BOX1_HEIGHT 0.4 // Size along the Z axis (up) since gravity is (0,0,-10) +#define BOX2_LENGTH 0.2 +#define BOX2_WIDTH 0.1 +#define BOX2_HEIGHT 0.4 +#define Mass1 10 +#define Mass2 0.1 + + +#define PRISMATIC_ONLY 1 +#define ROTOIDE_ONLY 2 +int flag = 0; + + +//camera view +static float xyz[3] = {2.0f,-3.5f,2.0000f}; +static float hpr[3] = {90.000f,-25.5000f,0.0000f}; +//world,space,body & geom +static dWorldID world; +static dSpaceID space; +static dSpaceID box1_space; +static dBodyID box1_body[1]; +static dBodyID box2_body[1]; +static dJointID joint[1]; +static dJointGroupID contactgroup; +static dGeomID ground; +static dGeomID box1[1]; +static dGeomID box2[1]; + + +//collision detection +static void nearCallback (void *, dGeomID o1, dGeomID o2) +{ + int i,n; + + dBodyID b1 = dGeomGetBody(o1); + dBodyID b2 = dGeomGetBody(o2); + if (b1 && b2 && dAreConnectedExcluding (b1,b2,dJointTypeContact)) return; + const int N = 10; + dContact contact[N]; + n = dCollide (o1,o2,N,&contact[0].geom,sizeof(dContact)); + if (n > 0) + { + for (i=0; i= 2 ) + { + for (int i=1; i < argc; ++i) + { + if ( 0 == strcmp("-h", argv[i]) || 0 == strcmp("--help", argv[i]) ) + Help(argv); + + if (!flag && (0 == strcmp("-p", argv[i]) ||0 == strcmp("--prismatic-only", argv[i])) ) + flag = PRISMATIC_ONLY; + + if (!flag && (0 == strcmp("-r", argv[i]) || 0 == strcmp("--rotoide-only", argv[i])) ) + flag = ROTOIDE_ONLY; + + if (0 == strcmp("-t", argv[i]) || 0 == strcmp("--texture-path", argv[i])) + { + int j = i+1; + if ( j >= argc || // Check if we have enough arguments + argv[j][0] == '\0' || // We should have a path here + argv[j][0] == '-' ) // We should have a path not a command line + Help(argv); + else + fn.path_to_textures = argv[++i]; // Increase i since we use this argument + } + } + } + + dInitODE2(0); + + // create world + world = dWorldCreate(); + space = dHashSpaceCreate (0); + contactgroup = dJointGroupCreate (0); + dWorldSetGravity (world,0,0,-10); + ground = dCreatePlane (space,0,0,1,0); + + //create two boxes + dMass m; + box1_body[0] = dBodyCreate (world); + dMassSetBox (&m,1,BOX1_LENGTH,BOX1_WIDTH,BOX1_HEIGHT); + dMassAdjust (&m,Mass1); + dBodySetMass (box1_body[0],&m); + box1[0] = dCreateBox (0,BOX1_LENGTH,BOX1_WIDTH,BOX1_HEIGHT); + dGeomSetBody (box1[0],box1_body[0]); + + box2_body[0] = dBodyCreate (world); + dMassSetBox (&m,10,BOX2_LENGTH,BOX2_WIDTH,BOX2_HEIGHT); + dMassAdjust (&m,Mass2); + dBodySetMass (box2_body[0],&m); + box2[0] = dCreateBox (0,BOX2_LENGTH,BOX2_WIDTH,BOX2_HEIGHT); + dGeomSetBody (box2[0],box2_body[0]); + + //set the initial positions of body1 and body2 + dMatrix3 R; + dRSetIdentity(R); + dBodySetPosition (box1_body[0],0,0,BOX1_HEIGHT/2.0); + dBodySetRotation (box1_body[0], R); + + dBodySetPosition (box2_body[0], + 2.1, + 0.0, + BOX2_HEIGHT/2.0); + dBodySetRotation (box2_body[0], R); + + + //set PR joint + joint[0] = dJointCreatePR(world,0); + dJointAttach (joint[0],box1_body[0],box2_body[0]); + switch (flag) + { + case PRISMATIC_ONLY: + dJointSetPRAnchor (joint[0], + 2.1, + 0.0, + BOX2_HEIGHT/2.0); + dJointSetPRParam (joint[0],dParamLoStop, -0.5); + dJointSetPRParam (joint[0],dParamHiStop, 1.5); + break; + + case ROTOIDE_ONLY: + dJointSetPRAnchor (joint[0], + 0.0, + 0.0, + BOX2_HEIGHT/2.0); + dJointSetPRParam (joint[0],dParamLoStop, 0.0); + dJointSetPRParam (joint[0],dParamHiStop, 0.0); + break; + + default: + dJointSetPRAnchor (joint[0], + 1.1, + 0.0, + BOX2_HEIGHT/2.0); + dJointSetPRParam (joint[0],dParamLoStop, -0.5); + dJointSetPRParam (joint[0],dParamHiStop, 1.5); + break; + } + + dJointSetPRAxis1(joint[0],1,0,0); + dJointSetPRAxis2(joint[0],0,0,1); +// We position the 2 body +// The position of the rotoide joint is on the second body so it can rotate on itself +// and move along the X axis. +// With this anchor +// - A force in X will move only the body 2 inside the low and hi limit +// of the prismatic +// - A force in Y will make the 2 bodies to rotate around on the plane + + box1_space = dSimpleSpaceCreate (space); + dSpaceSetCleanup (box1_space,0); + dSpaceAdd(box1_space,box1[0]); + + // run simulation + dsSimulationLoop (argc,argv,400,300,&fn); + dJointGroupDestroy (contactgroup); + dSpaceDestroy (space); + dWorldDestroy (world); + dCloseODE(); + return 0; +} + diff --git a/libs/ode-0.16.1/ode/demo/demo_jointPU.cpp b/libs/ode-0.16.1/ode/demo/demo_jointPU.cpp new file mode 100644 index 0000000..6ec3093 --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/demo_jointPU.cpp @@ -0,0 +1,735 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +/* + This program demonstrates how the PU joint works. + A PU joint is a combination of a Universal joint and a Slider joint. + It is a universal joint with a slider between the anchor point and + body 1. + + + The upper yellow body is fixed to the world + The lower yellow body is attached to the upper body by a PU joint + The green object is one aprt of the slider. + The purple object is the second part of the slider. + The red object represent the axis1 of the universal part. + The blue object represent the axis2 of the universal part. + The gray object represent the anchor2 of the PU joint. +*/ + + +#include +#include +#include +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif +// select correct drawing functions +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawCylinder dsDrawCylinderD +#define dsDrawCapsule dsDrawCapsuleD +#endif + +enum IDX_CYL_DIM +{ + RADIUS, + LENGTH, + NUM_CYL_DIM +}; + + +const dVector3 boxDim = {1,1,1}; +const dVector3 extDim = {0.2,0.2,1.2}; +const dVector3 ancDim = {0.2,0.2,0.5}; +const dReal axDim[NUM_CYL_DIM] = {0.1,1.0}; + + +int type = dJointTypePU; + + +const dReal VEL_INC = 0.01; // Velocity increment + +// physics parameters +const dReal PI = 3.14159265358979323846264338327950288419716939937510; + + +const dReal INT_EXT_RATIO = 0.8; + +#define X 0 +#define Y 1 +#define Z 2 + +enum INDEX +{ + W = 0, + D, + EXT, + INT, + AXIS1, + AXIS2, + ANCHOR, + GROUND, + NUM_PARTS, + ALL = NUM_PARTS, + // INDEX for catBits + JOINT, + LAST_INDEX_CNT +}; + +const int catBits[LAST_INDEX_CNT] = + { + 0x0001, ///< W Cylinder category + 0x0002, ///< D Cylinder category + 0x0004, ///< EXT sliderr category + 0x0008, ///< INT slider category + 0x0010, ///< AXIS1 universal category + 0x0020, ///< AXIS2 universal category + 0x0040, ///< ANCHOR category + 0x0080, ///< Ground category + ~0L, ///< All categories + 0x0004 | 0x0008 | 0x0010 | 0x0020 ///< JOINT category + }; + +#define Mass1 10 +#define Mass2 8 + + +//camera view +static float xyz[3] = {6.0f,0.0f,6.0000f}; +static float hpr[3] = {-180.000f,-25.5000f,0.0000f}; + + +//world,space,body & geom +static dWorldID world; +static dSpaceID space; +static dJointGroupID contactgroup; +static dBodyID body[NUM_PARTS]; +static dGeomID geom[NUM_PARTS]; + +static dJoint *joint; + + + +const dReal BOX_SIDES[3] = {1.0,1.0,1.0}; +const dReal OBS_SIDES[3] = {0.4,0.4,0.4}; +const dReal RECT_SIDES[3] = {0.3, 0.1, 0.2}; + + +//collision detection +static void nearCallback (void *, dGeomID o1, dGeomID o2) +{ + int i,n; + + const int N = 10; + dContact contact[N]; + n = dCollide (o1,o2,N,&contact[0].geom,sizeof (dContact) ); + if (n > 0) { + for (i=0; igetParam (dParamVel3) - VEL_INC; + joint->setParam (dParamVel3, vel); + joint->setParam (dParamFMax3, 2); + std::cout<<"Velocity = "<' : { + dReal vel = joint->getParam (dParamVel3) + VEL_INC; + joint->setParam (dParamVel3, vel); + joint->setParam (dParamFMax3, 2); + std::cout<<"Velocity = "<getParam (dParamFMax) ) { + aLimit = dInfinity; + lLimit = dInfinity; + fmax = 0; + } + else { + aLimit = 0.25*PI; + lLimit = 0.5*axDim[LENGTH]; + fmax = 0.02; + } + + joint->setParam (dParamFMax1, fmax); + joint->setParam (dParamFMax2, fmax); + joint->setParam (dParamFMax3, fmax); + + switch (joint->getType() ) { + case dJointTypePR : { + dPRJoint *pr = reinterpret_cast (joint); + pr->setParam (dParamLoStop, -lLimit); + pr->setParam (dParamHiStop, -lLimit); + pr->setParam (dParamLoStop2, aLimit); + pr->setParam (dParamHiStop2, -aLimit); + } + break; + case dJointTypePU : { + dPUJoint *pu = reinterpret_cast (joint); + pu->setParam (dParamLoStop1, -aLimit); + pu->setParam (dParamHiStop1, aLimit); + pu->setParam (dParamLoStop2, -aLimit); + pu->setParam (dParamHiStop2, aLimit); + pu->setParam (dParamLoStop3, -lLimit); + pu->setParam (dParamHiStop3, lLimit); + } + break; + default: {} // keep the compiler happy + } + } + + break; + + case 'g': case 'G' : { + dVector3 g; + dWorldGetGravity(world, g); + if ( g[2]< -0.1 ) + dWorldSetGravity(world, 0, 0, 0); + else + dWorldSetGravity(world, 0, 0, -0.5); + + } + +case 'p' :case 'P' : { + switch (joint->getType() ) { + case dJointTypeSlider : { + dSliderJoint *sj = reinterpret_cast (joint); + std::cout<<"Position ="<getPosition() <<"\n"; + } + break; + case dJointTypePU : { + dPUJoint *pu = reinterpret_cast (joint); + std::cout<<"Position ="<getPosition() <<"\n"; + std::cout<<"Position Rate="<getPositionRate() <<"\n"; + std::cout<<"Angle1 ="<getAngle1() <<"\n"; + std::cout<<"Angle1 Rate="<getAngle1Rate() <<"\n"; + std::cout<<"Angle2 ="<getAngle2() <<"\n"; + std::cout<<"Angle2 Rate="<getAngle2Rate() <<"\n"; + } + break; + default: {} // keep the compiler happy + } + } + break; + } +} + +static void drawBox (dGeomID id, int R, int G, int B) +{ + if (!id) + return; + + const dReal *pos = dGeomGetPosition (id); + const dReal *rot = dGeomGetRotation (id); + dsSetColor (R,G,B); + + dVector3 l; + dGeomBoxGetLengths (id, l); + dsDrawBox (pos, rot, l); +} + + +// simulation loop +static void simLoop (int pause) +{ + static bool todo = false; + if ( todo ) { // DEBUG + static int cnt = 0; + ++cnt; + + if (cnt == 5) + command ( 'q' ); + if (cnt == 10) + dsStop(); + } + + + + + if (!pause) { + double simstep = 0.01; // 10ms simulation steps + double dt = dsElapsedTime(); + + int nrofsteps = (int) ceilf (dt/simstep); + if (!nrofsteps) + nrofsteps = 1; + + for (int i=0; i (joint); + ang1 = pu->getAngle1(); + ang2 = pu->getAngle2(); + pu->getAxis1 (axisR1); + pu->getAxis2 (axisR2); + pu->getAxisP (axisP); + + dJointGetPUAnchor (pu->id(), anchorPos); + } + else if ( dJointTypePR == type ) { + dPRJoint *pr = dynamic_cast (joint); + pr->getAxis1 (axisP); + pr->getAxis2 (axisR1); + + dJointGetPRAnchor (pr->id(), anchorPos); + } + + + // Draw the axisR + if ( geom[INT] ) { + dsSetColor (1,0,1); + dVector3 l; + dGeomBoxGetLengths (geom[INT], l); + + const dReal *rotBox = dGeomGetRotation (geom[W]); + + dVector3 pos; + for (int i=0; i<3; ++i) + pos[i] = anchorPos[i] - 0.5*extDim[Z]*axisP[i]; + dsDrawBox (pos, rotBox, l); + } + + dsSetTexture (DS_CHECKERED); + if ( geom[AXIS1] ) { + dQuaternion q, qAng; + dQFromAxisAndAngle (qAng,axisR1[X], axisR1[Y], axisR1[Z], ang1); + dGeomGetQuaternion (geom[AXIS1], q); + + dQuaternion qq; + dQMultiply1 (qq, qAng, q); + dMatrix3 R; + dQtoR (qq,R); + + + dGeomCylinderGetParams (geom[AXIS1], &radius, &length); + dsSetColor (1,0,0); + dsDrawCylinder (anchorPos, R, length, radius); + } + + if ( dJointTypePU == type && geom[AXIS2] ) { + //dPUJoint *pu = dynamic_cast (joint); + + dQuaternion q, qAng, qq, qq1; + dGeomGetQuaternion (geom[AXIS2], q); + + dQFromAxisAndAngle (qAng, 0, 1, 0, ang2); + dQMultiply1 (qq, qAng, q); + + + dQFromAxisAndAngle (qAng,axisR1[X], axisR1[Y], axisR1[Z], ang1); + + dQMultiply1 (qq1, qAng, qq); + + + dMatrix3 R; + dQtoR (qq1,R); + + + dGeomCylinderGetParams (geom[AXIS2], &radius, &length); + dsSetColor (0,0,1); + dsDrawCylinder (anchorPos, R, length, radius); + } + + dsSetTexture (DS_WOOD); + + // Draw the anchor + if ( geom[ANCHOR] ) { + dsSetColor (1,1,1); + dVector3 l; + dGeomBoxGetLengths (geom[ANCHOR], l); + + const dReal *rotBox = dGeomGetRotation (geom[D]); + const dReal *posBox = dGeomGetPosition (geom[D]); + + dVector3 e; + for (int i=0; i<3; ++i) + e[i] = posBox[i] - anchorPos[i]; + dNormalize3 (e); + + dVector3 pos; + for (int i=0; i<3; ++i) + pos[i] = anchorPos[i] + 0.5 * l[Z]*e[i]; + dsDrawBox (pos, rotBox, l); + } + + drawBox (geom[D], 1,1,0); + } +} + + +void Help (char **argv) +{ + printf ("%s ", argv[0]); + printf (" -h | --help : print this help\n"); + printf (" -p | --PRJoint : Use a PR joint instead of PU joint\n"); + printf (" -t | --texture-path path : Path to the texture.\n"); + printf (" Default = %s\n", DRAWSTUFF_TEXTURE_PATH); + printf ("--------------------------------------------------\n"); + printf ("Hit any key to continue:"); + getchar(); + + exit (0); +} + +int main (int argc, char **argv) +{ + // setup pointers to drawstuff callback functions + dsFunctions fn; + fn.version = DS_VERSION; + fn.start = &start; + fn.step = &simLoop; + fn.command = &command; + fn.stop = 0; + fn.path_to_textures = DRAWSTUFF_TEXTURE_PATH; + + if (argc >= 2 ) { + for (int i=1; i < argc; ++i) { + if ( 0 == strcmp ("-h", argv[i]) || 0 == strcmp ("--help", argv[i]) ) + Help (argv); + + if ( 0 == strcmp ("-p", argv[i]) || 0 == strcmp ("--PRJoint", argv[i]) ) + type = dJointTypePR; + + if (0 == strcmp ("-t", argv[i]) || 0 == strcmp ("--texture-path", argv[i]) ) { + int j = i+1; + if ( j >= argc || // Check if we have enough arguments + argv[j][0] == '\0' || // We should have a path here + argv[j][0] == '-' ) // We should have a path not a command line + Help (argv); + else + fn.path_to_textures = argv[++i]; // Increase i since we use this argument + } + } + } + + dInitODE2(0); + + world = dWorldCreate(); + dWorldSetERP (world, 0.8); + + space = dSimpleSpaceCreate (0); + contactgroup = dJointGroupCreate (0); + geom[GROUND] = dCreatePlane (space, 0,0,1,0); + dGeomSetCategoryBits (geom[GROUND], catBits[GROUND]); + dGeomSetCollideBits (geom[GROUND], catBits[ALL]); + + dMass m; + + // Create the body attached to the World + body[W] = dBodyCreate (world); + // Main axis of cylinder is along X=1 + m.setBox (1, boxDim[X], boxDim[Y], boxDim[Z]); + m.adjust (Mass1); + geom[W] = dCreateBox (space, boxDim[X], boxDim[Y], boxDim[Z]); + dGeomSetBody (geom[W], body[W]); + dGeomSetCategoryBits (geom[W], catBits[W]); + dGeomSetCollideBits (geom[W], catBits[ALL] & (~catBits[W]) & (~catBits[JOINT]) ); + dBodySetMass (body[W], &m); + + + + + + // Create the dandling body + body[D] = dBodyCreate (world); + // Main axis of capsule is along X=1 + m.setBox (1, boxDim[X], boxDim[Y], boxDim[Z]); + m.adjust (Mass1); + geom[D] = dCreateBox (space, boxDim[X], boxDim[Y], boxDim[Z]); + dGeomSetBody (geom[D], body[D]); + dGeomSetCategoryBits (geom[D], catBits[D]); + dGeomSetCollideBits (geom[D], catBits[ALL] & (~catBits[D]) & (~catBits[JOINT]) ); + dBodySetMass (body[D], &m); + + + // Create the external part of the slider joint + geom[EXT] = dCreateBox (0, extDim[X], extDim[Y], extDim[Z]); + dGeomSetCategoryBits (geom[EXT], catBits[EXT]); + dGeomSetCollideBits (geom[EXT], + catBits[ALL] & (~catBits[JOINT]) & (~catBits[W]) & (~catBits[D]) ); + + // Create the internal part of the slider joint + geom[INT] = dCreateBox (0, INT_EXT_RATIO*extDim[X], + INT_EXT_RATIO*extDim[Y], + INT_EXT_RATIO*extDim[Z]); + dGeomSetCategoryBits (geom[INT], catBits[INT]); + dGeomSetCollideBits (geom[INT], + catBits[ALL] & (~catBits[JOINT]) & (~catBits[W]) & (~catBits[D]) ); + + + dMatrix3 R; + // Create the first axis of the universal joi9nt + //Rotation of 90deg around y + geom[AXIS1] = dCreateCylinder(0, axDim[RADIUS], axDim[LENGTH]); + dRFromAxisAndAngle(R, 0,1,0, 0.5*PI); + dGeomSetRotation(geom[AXIS1], R); + dGeomSetCategoryBits(geom[AXIS1], catBits[AXIS1]); + dGeomSetCollideBits(geom[AXIS1], + catBits[ALL] & ~catBits[JOINT] & ~catBits[W] & ~catBits[D]); + + + // Create the second axis of the universal joint + geom[AXIS2] = dCreateCylinder(0, axDim[RADIUS], axDim[LENGTH]); + //Rotation of 90deg around y + dRFromAxisAndAngle(R, 1,0,0, 0.5*PI); + dGeomSetRotation(geom[AXIS2], R); + dGeomSetCategoryBits(geom[AXIS2], catBits[AXIS2]); + dGeomSetCollideBits(geom[AXIS2], + catBits[ALL] & ~catBits[JOINT] & ~catBits[W] & ~catBits[D]); + + // Create the anchor + geom[ANCHOR] = dCreateBox (0, ancDim[X], ancDim[Y], ancDim[Z]); + dGeomSetCategoryBits(geom[ANCHOR], catBits[ANCHOR]); + dGeomSetCollideBits(geom[ANCHOR], + catBits[ALL] & (~catBits[JOINT]) & (~catBits[W]) & (~catBits[D]) ); + + + + if (body[W]) { + dBodySetPosition(body[W], 0, 0, 5); + } + + + if (geom[EXT]) { + dGeomSetPosition(geom[EXT], 0,0,3.8); + } + if (geom[INT]) { + dGeomSetPosition(geom[INT], 0,0,2.6); + } + if (geom[AXIS1]) { + dGeomSetPosition(geom[AXIS1], 0,0,2.5); + } + if (geom[AXIS2]) { + dGeomSetPosition(geom[AXIS2], 0,0,2.5); + } + + if (geom[ANCHOR]) { + dGeomSetPosition(geom[ANCHOR], 0,0,2.25); + } + + if (body[D]) { + dBodySetPosition(body[D], 0,0,1.5); + } + + + + // Attache the upper box to the world + dJointID fixed = dJointCreateFixed (world,0); + dJointAttach (fixed , NULL, body[W]); + dJointSetFixed (fixed ); + + if (type == dJointTypePR) { + dPRJoint *pr = new dPRJoint (world, 0); + pr->attach (body[W], body[D]); + pr->setAxis1 (0, 0, -1); + pr->setAxis2 (1, 0, 0); + joint = pr; + + dJointSetPRAnchor (pr->id(), 0, 0, 2.5); + } + else { + dPUJoint *pu = new dPUJoint (world, 0); + pu->attach (body[W], body[D]); + pu->setAxis1 (1, 0, 0); + pu->setAxis2 (0, 1, 0); + pu->setAxisP (0, 0, -1); + joint = pu; + + dJointSetPUAnchor (pu->id(), 0, 0, 2.5); + } + + + // run simulation + dsSimulationLoop (argc,argv,400,300,&fn); + + delete joint; + dJointGroupDestroy (contactgroup); + dSpaceDestroy (space); + dWorldDestroy (world); + dCloseODE(); + return 0; +} + diff --git a/libs/ode-0.16.1/ode/demo/demo_joints.cpp b/libs/ode-0.16.1/ode/demo/demo_joints.cpp new file mode 100644 index 0000000..d545369 --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/demo_joints.cpp @@ -0,0 +1,1090 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +/* + +perform tests on all the joint types. +this should be done using the double precision version of the library. + +usage: + test_joints [-nXXX] [-g] [-i] [-e] [path_to_textures] + +if a test number is given then that specific test is performed, otherwise +all the tests are performed. the tests are numbered `xxyy', where xx +corresponds to the joint type and yy is the sub-test number. not every +number maps to an actual test. + +flags: + i: the test is interactive. + g: turn off graphical display (can't use this with `i'). + e: turn on occasional error perturbations + n: performe test XXX +some tests compute and display error values. these values are scaled so +<1 is good and >1 is bad. other tests just show graphical results which +you must verify visually. + +*/ + +#include +#include +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +// select correct drawing functions +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#endif + + +// some constants +#define NUM_JOINTS 10 // number of joints to test (the `xx' value) +#define SIDE (0.5f) // side length of a box - don't change this +#define MASS (1.0) // mass of a box +#define STEPSIZE 0.05 + +static const dVector3 xunit = { 1, 0, 0 }, zunit = { 0, 0, 1 }; + + +// dynamics objects +static dWorldID world; +static dBodyID body[2]; +static dJointID joint; + + +// data from the command line arguments +static int cmd_test_num = -1; +static int cmd_interactive = 0; +static int cmd_graphics = 1; +static char *cmd_path_to_textures = NULL; +static int cmd_occasional_error = 0; // perturb occasionally + + +// info about the current test +struct TestInfo; +static int test_num = 0; // number of the current test +static int iteration = 0; +static int max_iterations = 0; +static dReal max_error = 0; + +//**************************************************************************** +// utility stuff + +static dReal length (dVector3 a) +{ + return dSqrt (a[0]*a[0] + a[1]*a[1] + a[2]*a[2]); +} + + +// get the max difference between a 3x3 matrix and the identity + +dReal cmpIdentity (const dMatrix3 A) +{ + dMatrix3 I; + dSetZero (I,12); + I[0] = 1; + I[5] = 1; + I[10] = 1; + return dMaxDifference (A,I,3,3); +} + +//**************************************************************************** +// test world construction and utilities + +void constructWorldForTest (dReal gravity, int bodycount, + /* body 1 pos */ dReal pos1x, dReal pos1y, dReal pos1z, + /* body 2 pos */ dReal pos2x, dReal pos2y, dReal pos2z, + /* body 1 rotation axis */ dReal ax1x, dReal ax1y, dReal ax1z, + /* body 1 rotation axis */ dReal ax2x, dReal ax2y, dReal ax2z, + /* rotation angles */ dReal a1, dReal a2) +{ + // create world + world = dWorldCreate(); + dWorldSetERP (world,0.2); + dWorldSetCFM (world,1e-6); + dWorldSetGravity (world,0,0,gravity); + + dMass m; + dMassSetBox (&m,1,SIDE,SIDE,SIDE); + dMassAdjust (&m,MASS); + + body[0] = dBodyCreate (world); + dBodySetMass (body[0],&m); + dBodySetPosition (body[0], pos1x, pos1y, pos1z); + dQuaternion q; + dQFromAxisAndAngle (q,ax1x,ax1y,ax1z,a1); + dBodySetQuaternion (body[0],q); + + if (bodycount==2) { + body[1] = dBodyCreate (world); + dBodySetMass (body[1],&m); + dBodySetPosition (body[1], pos2x, pos2y, pos2z); + dQFromAxisAndAngle (q,ax2x,ax2y,ax2z,a2); + dBodySetQuaternion (body[1],q); + } + else body[1] = 0; +} + + +// add an oscillating torque to body 0 + +void addOscillatingTorque (dReal tscale) +{ + static dReal a=0; + dBodyAddTorque (body[0],tscale*cos(2*a),tscale*cos(2.7183*a), + tscale*cos(1.5708*a)); + a += 0.01; +} + + +void addOscillatingTorqueAbout(dReal tscale, dReal x, dReal y, dReal z) +{ + static dReal a=0; + dBodyAddTorque (body[0], tscale*cos(a) * x, tscale*cos(a) * y, + tscale * cos(a) * z); + a += 0.02; +} + + +// damp the rotational motion of body 0 a bit + +void dampRotationalMotion (dReal kd) +{ + const dReal *w = dBodyGetAngularVel (body[0]); + dBodyAddTorque (body[0],-kd*w[0],-kd*w[1],-kd*w[2]); +} + + +// add a spring force to keep the bodies together, otherwise they may fly +// apart with some joints. + +void addSpringForce (dReal ks) +{ + const dReal *p1 = dBodyGetPosition (body[0]); + const dReal *p2 = dBodyGetPosition (body[1]); + dBodyAddForce (body[0],ks*(p2[0]-p1[0]),ks*(p2[1]-p1[1]),ks*(p2[2]-p1[2])); + dBodyAddForce (body[1],ks*(p1[0]-p2[0]),ks*(p1[1]-p2[1]),ks*(p1[2]-p2[2])); +} + + +// add an oscillating Force to body 0 + +void addOscillatingForce (dReal fscale) +{ + static dReal a=0; + dBodyAddForce (body[0],fscale*cos(2*a),fscale*cos(2.7183*a), + fscale*cos(1.5708*a)); + a += 0.01; +} + +//**************************************************************************** +// stuff specific to the tests +// +// 0xx : fixed +// 1xx : ball and socket +// 2xx : hinge +// 3xx : slider +// 4xx : hinge 2 +// 5xx : contact +// 6xx : amotor +// 7xx : universal joint +// 8xx : PR joint (Prismatic and Rotoide) + +// setup for the given test. return 0 if there is no such test + +int setupTest (int n) +{ + switch (n) { + + // ********** fixed joint + + case 0: { // 2 body + constructWorldForTest (0,2, + 0.5*SIDE,0.5*SIDE,1, -0.5*SIDE,-0.5*SIDE,1, + 1,1,0, 1,1,0, + 0.25*M_PI,0.25*M_PI); + joint = dJointCreateFixed (world,0); + dJointAttach (joint,body[0],body[1]); + dJointSetFixed (joint); + return 1; + } + + case 1: { // 1 body to static env + constructWorldForTest (0,1, + 0.5*SIDE,0.5*SIDE,1, 0,0,0, + 1,0,0, 1,0,0, + 0,0); + joint = dJointCreateFixed (world,0); + dJointAttach (joint,body[0],0); + dJointSetFixed (joint); + return 1; + } + + case 2: { // 2 body with relative rotation + constructWorldForTest (0,2, + 0.5*SIDE,0.5*SIDE,1, -0.5*SIDE,-0.5*SIDE,1, + 1,1,0, 1,1,0, + 0.25*M_PI,-0.25*M_PI); + joint = dJointCreateFixed (world,0); + dJointAttach (joint,body[0],body[1]); + dJointSetFixed (joint); + return 1; + } + + case 3: { // 1 body to static env with relative rotation + constructWorldForTest (0,1, + 0.5*SIDE,0.5*SIDE,1, 0,0,0, + 1,0,0, 1,0,0, + 0.25*M_PI,0); + joint = dJointCreateFixed (world,0); + dJointAttach (joint,body[0],0); + dJointSetFixed (joint); + return 1; + } + + // ********** hinge joint + + case 200: // 2 body + constructWorldForTest (0,2, + 0.5*SIDE,0.5*SIDE,1, -0.5*SIDE,-0.5*SIDE,1, + 1,1,0, 1,1,0, 0.25*M_PI,0.25*M_PI); + joint = dJointCreateHinge (world,0); + dJointAttach (joint,body[0],body[1]); + dJointSetHingeAnchor (joint,0,0,1); + dJointSetHingeAxis (joint,1,-1,1.41421356); + return 1; + + case 220: // hinge angle polarity test + case 221: // hinge angle rate test + constructWorldForTest (0,2, + 0.5*SIDE,0.5*SIDE,1, -0.5*SIDE,-0.5*SIDE,1, + 1,0,0, 1,0,0, 0,0); + joint = dJointCreateHinge (world,0); + dJointAttach (joint,body[0],body[1]); + dJointSetHingeAnchor (joint,0,0,1); + dJointSetHingeAxis (joint,0,0,1); + max_iterations = 50; + return 1; + + case 230: // hinge motor rate (and polarity) test + case 231: // ...with stops + constructWorldForTest (0,2, + 0.5*SIDE,0.5*SIDE,1, -0.5*SIDE,-0.5*SIDE,1, + 1,0,0, 1,0,0, 0,0); + joint = dJointCreateHinge (world,0); + dJointAttach (joint,body[0],body[1]); + dJointSetHingeAnchor (joint,0,0,1); + dJointSetHingeAxis (joint,0,0,1); + dJointSetHingeParam (joint,dParamFMax,1); + if (n==231) { + dJointSetHingeParam (joint,dParamLoStop,-0.5); + dJointSetHingeParam (joint,dParamHiStop,0.5); + } + return 1; + + case 250: // limit bounce test (gravity down) + case 251: { // ...gravity up + constructWorldForTest ((n==251) ? 0.1 : -0.1, 2, + 0.5*SIDE,0,1+0.5*SIDE, -0.5*SIDE,0,1-0.5*SIDE, + 1,0,0, 1,0,0, 0,0); + joint = dJointCreateHinge (world,0); + dJointAttach (joint,body[0],body[1]); + dJointSetHingeAnchor (joint,0,0,1); + dJointSetHingeAxis (joint,0,1,0); + dJointSetHingeParam (joint,dParamLoStop,-0.9); + dJointSetHingeParam (joint,dParamHiStop,0.7854); + dJointSetHingeParam (joint,dParamBounce,0.5); + // anchor 2nd body with a fixed joint + dJointID j = dJointCreateFixed (world,0); + dJointAttach (j,body[1],0); + dJointSetFixed (j); + return 1; + } + + // ********** slider + + case 300: // 2 body + constructWorldForTest (0,2, + 0,0,1, 0.2,0.2,1.2, + 0,0,1, -1,1,0, 0,0.25*M_PI); + joint = dJointCreateSlider (world,0); + dJointAttach (joint,body[0],body[1]); + dJointSetSliderAxis (joint,1,1,1); + return 1; + + case 320: // slider angle polarity test + case 321: // slider angle rate test + constructWorldForTest (0,2, + 0,0,1, 0,0,1.2, + 1,0,0, 1,0,0, 0,0); + joint = dJointCreateSlider (world,0); + dJointAttach (joint,body[0],body[1]); + dJointSetSliderAxis (joint,0,0,1); + max_iterations = 50; + return 1; + + case 330: // slider motor rate (and polarity) test + case 331: // ...with stops + constructWorldForTest (0, 2, + 0,0,1, 0,0,1.2, + 1,0,0, 1,0,0, 0,0); + joint = dJointCreateSlider (world,0); + dJointAttach (joint,body[0],body[1]); + dJointSetSliderAxis (joint,0,0,1); + dJointSetSliderParam (joint,dParamFMax,100); + if (n==331) { + dJointSetSliderParam (joint,dParamLoStop,-0.4); + dJointSetSliderParam (joint,dParamHiStop,0.4); + } + return 1; + + case 350: // limit bounce tests + case 351: { + constructWorldForTest ((n==351) ? 0.1 : -0.1, 2, + 0,0,1, 0,0,1.2, + 1,0,0, 1,0,0, 0,0); + joint = dJointCreateSlider (world,0); + dJointAttach (joint,body[0],body[1]); + dJointSetSliderAxis (joint,0,0,1); + dJointSetSliderParam (joint,dParamLoStop,-0.5); + dJointSetSliderParam (joint,dParamHiStop,0.5); + dJointSetSliderParam (joint,dParamBounce,0.5); + // anchor 2nd body with a fixed joint + dJointID j = dJointCreateFixed (world,0); + dJointAttach (j,body[1],0); + dJointSetFixed (j); + return 1; + } + + // ********** hinge-2 joint + + case 420: // hinge-2 steering angle polarity test + case 421: // hinge-2 steering angle rate test + constructWorldForTest (0,2, + 0.5*SIDE,0,1, -0.5*SIDE,0,1, + 1,0,0, 1,0,0, 0,0); + joint = dJointCreateHinge2 (world,0); + dJointAttach (joint,body[0],body[1]); + dJointSetHinge2Anchor (joint,-0.5*SIDE,0,1); + dJointSetHinge2Axes (joint, zunit, xunit); + max_iterations = 50; + return 1; + + case 430: // hinge 2 steering motor rate (+polarity) test + case 431: // ...with stops + case 432: // hinge 2 wheel motor rate (+polarity) test + constructWorldForTest (0,2, + 0.5*SIDE,0,1, -0.5*SIDE,0,1, + 1,0,0, 1,0,0, 0,0); + joint = dJointCreateHinge2 (world,0); + dJointAttach (joint,body[0],body[1]); + dJointSetHinge2Anchor (joint,-0.5*SIDE,0,1); + dJointSetHinge2Axes (joint, zunit, xunit); + dJointSetHinge2Param (joint,dParamFMax,1); + dJointSetHinge2Param (joint,dParamFMax2,1); + if (n==431) { + dJointSetHinge2Param (joint,dParamLoStop,-0.5); + dJointSetHinge2Param (joint,dParamHiStop,0.5); + } + return 1; + + // ********** angular motor joint + + case 600: // test euler angle calculations + constructWorldForTest (0,2, + -SIDE*0.5,0,1, SIDE*0.5,0,1, + 0,0,1, 0,0,1, 0,0); + joint = dJointCreateAMotor (world,0); + dJointAttach (joint,body[0],body[1]); + + dJointSetAMotorNumAxes (joint,3); + dJointSetAMotorAxis (joint,0,1, 0,0,1); + dJointSetAMotorAxis (joint,2,2, 1,0,0); + dJointSetAMotorMode (joint,dAMotorEuler); + max_iterations = 200; + return 1; + + // ********** universal joint + + case 700: // 2 body + case 701: + case 702: + constructWorldForTest (0,2, + 0.5*SIDE,0.5*SIDE,1, -0.5*SIDE,-0.5*SIDE,1, + 1,1,0, 1,1,0, 0.25*M_PI,0.25*M_PI); + joint = dJointCreateUniversal (world,0); + dJointAttach (joint,body[0],body[1]); + dJointSetUniversalAnchor (joint,0,0,1); + dJointSetUniversalAxis1 (joint, 1, -1, 1.41421356); + dJointSetUniversalAxis2 (joint, 1, -1, -1.41421356); + return 1; + + case 720: // universal transmit torque test + case 721: + case 722: + case 730: // universal torque about axis 1 + case 731: + case 732: + case 740: // universal torque about axis 2 + case 741: + case 742: + constructWorldForTest (0,2, + 0.5*SIDE,0.5*SIDE,1, -0.5*SIDE,-0.5*SIDE,1, + 1,0,0, 1,0,0, 0,0); + joint = dJointCreateUniversal (world,0); + dJointAttach (joint,body[0],body[1]); + dJointSetUniversalAnchor (joint,0,0,1); + dJointSetUniversalAxis1 (joint,0,0,1); + dJointSetUniversalAxis2 (joint, 1, -1,0); + max_iterations = 100; + return 1; + + // Joint PR (Prismatic and Rotoide) + case 800: // 2 body + case 801: // 2 bodies with spring force and prismatic fixed + case 802: // 2 bodies with torque on body1 and prismatic fixed + constructWorldForTest (0, 2, + -1.0, 0.0, 1.0, + 1.0, 0.0, 1.0, + 1,0,0, 1,0,0, + 0, 0); + joint = dJointCreatePR (world, 0); + dJointAttach (joint, body[0], body[1]); + dJointSetPRAnchor (joint,-0.5, 0.0, 1.0); + dJointSetPRAxis1 (joint, 0, 1, 0); + dJointSetPRAxis2 (joint, 1, 0, 0); + dJointSetPRParam (joint,dParamLoStop,-0.5); + dJointSetPRParam (joint,dParamHiStop,0.5); + dJointSetPRParam (joint,dParamLoStop2,0); + dJointSetPRParam (joint,dParamHiStop2,0); + return 1; + case 803: // 2 bodies with spring force and prismatic NOT fixed + case 804: // 2 bodies with torque force and prismatic NOT fixed + case 805: // 2 bodies with force only on first body + constructWorldForTest (0, 2, + -1.0, 0.0, 1.0, + 1.0, 0.0, 1.0, + 1,0,0, 1,0,0, + 0, 0); + joint = dJointCreatePR (world, 0); + dJointAttach (joint, body[0], body[1]); + dJointSetPRAnchor (joint,-0.5, 0.0, 1.0); + dJointSetPRAxis1 (joint, 0, 1, 0); + dJointSetPRAxis2 (joint, 1, 0, 0); + dJointSetPRParam (joint,dParamLoStop,-0.5); + dJointSetPRParam (joint,dParamHiStop,0.5); + dJointSetPRParam (joint,dParamLoStop2,-0.5); + dJointSetPRParam (joint,dParamHiStop2,0.5); + return 1; + } + return 0; +} + + +// do stuff specific to this test each iteration. you can check some +// invariants for the test -- the return value is some scaled error measurement +// that must be less than 1. +// return a dInfinity if error is not measured for this n. + +dReal doStuffAndGetError (int n) +{ + switch (n) { + + // ********** fixed joint + + case 0: { // 2 body + addOscillatingTorque (0.1); + dampRotationalMotion (0.1); + // check the orientations are the same + const dReal *R1 = dBodyGetRotation (body[0]); + const dReal *R2 = dBodyGetRotation (body[1]); + dReal err1 = dMaxDifference (R1,R2,3,3); + // check the body offset is correct + dVector3 p,pp; + const dReal *p1 = dBodyGetPosition (body[0]); + const dReal *p2 = dBodyGetPosition (body[1]); + for (int i=0; i<3; i++) p[i] = p2[i] - p1[i]; + dMultiply1_331 (pp,R1,p); + pp[0] += 0.5; + pp[1] += 0.5; + return (err1 + length (pp)) * 300; + } + + case 1: { // 1 body to static env + addOscillatingTorque (0.1); + + // check the orientation is the identity + dReal err1 = cmpIdentity (dBodyGetRotation (body[0])); + + // check the body offset is correct + dVector3 p; + const dReal *p1 = dBodyGetPosition (body[0]); + for (int i=0; i<3; i++) p[i] = p1[i]; + p[0] -= 0.25; + p[1] -= 0.25; + p[2] -= 1; + return (err1 + length (p)) * 1e6; + } + + case 2: { // 2 body + addOscillatingTorque (0.1); + dampRotationalMotion (0.1); + // check the body offset is correct + // Should really check body rotation too. Oh well. + const dReal *R1 = dBodyGetRotation (body[0]); + dVector3 p,pp; + const dReal *p1 = dBodyGetPosition (body[0]); + const dReal *p2 = dBodyGetPosition (body[1]); + for (int i=0; i<3; i++) p[i] = p2[i] - p1[i]; + dMultiply1_331 (pp,R1,p); + pp[0] += 0.5; + pp[1] += 0.5; + return length(pp) * 300; + } + + case 3: { // 1 body to static env with relative rotation + addOscillatingTorque (0.1); + + // check the body offset is correct + dVector3 p; + const dReal *p1 = dBodyGetPosition (body[0]); + for (int i=0; i<3; i++) p[i] = p1[i]; + p[0] -= 0.25; + p[1] -= 0.25; + p[2] -= 1; + return length (p) * 1e6; + } + + + // ********** hinge joint + + case 200: // 2 body + addOscillatingTorque (0.1); + dampRotationalMotion (0.1); + return dInfinity; + + case 220: // hinge angle polarity test + dBodyAddTorque (body[0],0,0,0.01); + dBodyAddTorque (body[1],0,0,-0.01); + if (iteration == 40) { + dReal a = dJointGetHingeAngle (joint); + if (a > 0.5 && a < 1) return 0; else return 10; + } + return 0; + + case 221: { // hinge angle rate test + static dReal last_angle = 0; + dBodyAddTorque (body[0],0,0,0.01); + dBodyAddTorque (body[1],0,0,-0.01); + dReal a = dJointGetHingeAngle (joint); + dReal r = dJointGetHingeAngleRate (joint); + dReal er = (a-last_angle)/STEPSIZE; // estimated rate + last_angle = a; + return fabs(r-er) * 4e4; + } + + case 230: // hinge motor rate (and polarity) test + case 231: { // ...with stops + static dReal a = 0; + dReal r = dJointGetHingeAngleRate (joint); + dReal err = fabs (cos(a) - r); + if (a==0) err = 0; + a += 0.03; + dJointSetHingeParam (joint,dParamVel,cos(a)); + if (n==231) return dInfinity; + return err * 1e6; + } + + // ********** slider joint + + case 300: // 2 body + addOscillatingTorque (0.05); + dampRotationalMotion (0.1); + addSpringForce (0.5); + return dInfinity; + + case 320: // slider angle polarity test + dBodyAddForce (body[0],0,0,0.1); + dBodyAddForce (body[1],0,0,-0.1); + if (iteration == 40) { + dReal a = dJointGetSliderPosition (joint); + if (a > 0.2 && a < 0.5) + return 0; + else + return 10; // Failed + } + return 0; + + case 321: { // slider angle rate test + static dReal last_pos = 0; + dBodyAddForce (body[0],0,0,0.1); + dBodyAddForce (body[1],0,0,-0.1); + dReal p = dJointGetSliderPosition (joint); + dReal r = dJointGetSliderPositionRate (joint); + dReal er = (p-last_pos)/STEPSIZE; // estimated rate (almost exact) + last_pos = p; + return fabs(r-er) * 1e9; + } + + case 330: // slider motor rate (and polarity) test + case 331: { // ...with stops + static dReal a = 0; + dReal r = dJointGetSliderPositionRate (joint); + dReal err = fabs (0.7*cos(a) - r); + if (a < 0.04) err = 0; + a += 0.03; + dJointSetSliderParam (joint,dParamVel,0.7*cos(a)); + if (n==331) return dInfinity; + return err * 1e6; + } + + // ********** hinge-2 joint + + case 420: // hinge-2 steering angle polarity test + dBodyAddTorque (body[0],0,0,0.01); + dBodyAddTorque (body[1],0,0,-0.01); + if (iteration == 40) { + dReal a = dJointGetHinge2Angle1 (joint); + if (a > 0.5 && a < 0.6) return 0; else return 10; + } + return 0; + + case 421: { // hinge-2 steering angle rate test + static dReal last_angle = 0; + dBodyAddTorque (body[0],0,0,0.01); + dBodyAddTorque (body[1],0,0,-0.01); + dReal a = dJointGetHinge2Angle1 (joint); + dReal r = dJointGetHinge2Angle1Rate (joint); + dReal er = (a-last_angle)/STEPSIZE; // estimated rate + last_angle = a; + return fabs(r-er)*2e4; + } + + case 430: // hinge 2 steering motor rate (+polarity) test + case 431: { // ...with stops + static dReal a = 0; + dReal r = dJointGetHinge2Angle1Rate (joint); + dReal err = fabs (cos(a) - r); + if (a==0) err = 0; + a += 0.03; + dJointSetHinge2Param (joint,dParamVel,cos(a)); + if (n==431) return dInfinity; + return err * 1e6; + } + + case 432: { // hinge 2 wheel motor rate (+polarity) test + static dReal a = 0; + dReal r = dJointGetHinge2Angle2Rate (joint); + dReal err = fabs (cos(a) - r); + if (a==0) err = 0; + a += 0.03; + dJointSetHinge2Param (joint,dParamVel2,cos(a)); + return err * 1e6; + } + + // ********** angular motor joint + + case 600: { // test euler angle calculations + // desired euler angles from last iteration + static dReal a1,a2,a3; + + // find actual euler angles + dReal aa1 = dJointGetAMotorAngle (joint,0); + dReal aa2 = dJointGetAMotorAngle (joint,1); + dReal aa3 = dJointGetAMotorAngle (joint,2); + // printf ("actual = %.4f %.4f %.4f\n\n",aa1,aa2,aa3); + + dReal err = dInfinity; + if (iteration > 0) { + err = dFabs(aa1-a1) + dFabs(aa2-a2) + dFabs(aa3-a3); + err *= 1e10; + } + + // get random base rotation for both bodies + dMatrix3 Rbase; + dRFromAxisAndAngle (Rbase, 3*(dRandReal()-0.5), 3*(dRandReal()-0.5), + 3*(dRandReal()-0.5), 3*(dRandReal()-0.5)); + dBodySetRotation (body[0],Rbase); + + // rotate body 2 by random euler angles w.r.t. body 1 + a1 = 3.14 * 2 * (dRandReal()-0.5); + a2 = 1.57 * 2 * (dRandReal()-0.5); + a3 = 3.14 * 2 * (dRandReal()-0.5); + dMatrix3 R1,R2,R3,Rtmp1,Rtmp2; + dRFromAxisAndAngle (R1,0,0,1,-a1); + dRFromAxisAndAngle (R2,0,1,0,a2); + dRFromAxisAndAngle (R3,1,0,0,-a3); + dMultiply0 (Rtmp1,R2,R3,3,3,3); + dMultiply0 (Rtmp2,R1,Rtmp1,3,3,3); + dMultiply0 (Rtmp1,Rbase,Rtmp2,3,3,3); + dBodySetRotation (body[1],Rtmp1); + // printf ("desired = %.4f %.4f %.4f\n",a1,a2,a3); + + return err; + } + + // ********** universal joint + + case 700: { // 2 body: joint constraint + dVector3 ax1, ax2; + + addOscillatingTorque (0.1); + dampRotationalMotion (0.1); + dJointGetUniversalAxis1(joint, ax1); + dJointGetUniversalAxis2(joint, ax2); + return fabs(10*dCalcVectorDot3(ax1, ax2)); + } + + case 701: { // 2 body: angle 1 rate + static dReal last_angle = 0; + addOscillatingTorque (0.1); + dampRotationalMotion (0.1); + dReal a = dJointGetUniversalAngle1(joint); + dReal r = dJointGetUniversalAngle1Rate(joint); + dReal diff = a - last_angle; + if (diff > M_PI) diff -= 2*M_PI; + if (diff < -M_PI) diff += 2*M_PI; + dReal er = diff / STEPSIZE; // estimated rate + last_angle = a; + // I'm not sure why the error is so large here. + return fabs(r - er) * 1e1; + } + + case 702: { // 2 body: angle 2 rate + static dReal last_angle = 0; + addOscillatingTorque (0.1); + dampRotationalMotion (0.1); + dReal a = dJointGetUniversalAngle2(joint); + dReal r = dJointGetUniversalAngle2Rate(joint); + dReal diff = a - last_angle; + if (diff > M_PI) diff -= 2*M_PI; + if (diff < -M_PI) diff += 2*M_PI; + dReal er = diff / STEPSIZE; // estimated rate + last_angle = a; + // I'm not sure why the error is so large here. + return fabs(r - er) * 1e1; + } + + case 720: { // universal transmit torque test: constraint error + dVector3 ax1, ax2; + addOscillatingTorqueAbout (0.1, 1, 1, 0); + dampRotationalMotion (0.1); + dJointGetUniversalAxis1(joint, ax1); + dJointGetUniversalAxis2(joint, ax2); + return fabs(10*dCalcVectorDot3(ax1, ax2)); + } + + case 721: { // universal transmit torque test: angle1 rate + static dReal last_angle = 0; + addOscillatingTorqueAbout (0.1, 1, 1, 0); + dampRotationalMotion (0.1); + dReal a = dJointGetUniversalAngle1(joint); + dReal r = dJointGetUniversalAngle1Rate(joint); + dReal diff = a - last_angle; + if (diff > M_PI) diff -= 2*M_PI; + if (diff < -M_PI) diff += 2*M_PI; + dReal er = diff / STEPSIZE; // estimated rate + last_angle = a; + return fabs(r - er) * 1e10; + } + + case 722: { // universal transmit torque test: angle2 rate + static dReal last_angle = 0; + addOscillatingTorqueAbout (0.1, 1, 1, 0); + dampRotationalMotion (0.1); + dReal a = dJointGetUniversalAngle2(joint); + dReal r = dJointGetUniversalAngle2Rate(joint); + dReal diff = a - last_angle; + if (diff > M_PI) diff -= 2*M_PI; + if (diff < -M_PI) diff += 2*M_PI; + dReal er = diff / STEPSIZE; // estimated rate + last_angle = a; + return fabs(r - er) * 1e10; + } + + case 730:{ + dVector3 ax1, ax2; + dJointGetUniversalAxis1(joint, ax1); + dJointGetUniversalAxis2(joint, ax2); + addOscillatingTorqueAbout (0.1, ax1[0], ax1[1], ax1[2]); + dampRotationalMotion (0.1); + return fabs(10*dCalcVectorDot3(ax1, ax2)); + } + + case 731:{ + dVector3 ax1; + static dReal last_angle = 0; + dJointGetUniversalAxis1(joint, ax1); + addOscillatingTorqueAbout (0.1, ax1[0], ax1[1], ax1[2]); + dampRotationalMotion (0.1); + dReal a = dJointGetUniversalAngle1(joint); + dReal r = dJointGetUniversalAngle1Rate(joint); + dReal diff = a - last_angle; + if (diff > M_PI) diff -= 2*M_PI; + if (diff < -M_PI) diff += 2*M_PI; + dReal er = diff / STEPSIZE; // estimated rate + last_angle = a; + return fabs(r - er) * 2e3; + } + + case 732:{ + dVector3 ax1; + static dReal last_angle = 0; + dJointGetUniversalAxis1(joint, ax1); + addOscillatingTorqueAbout (0.1, ax1[0], ax1[1], ax1[2]); + dampRotationalMotion (0.1); + dReal a = dJointGetUniversalAngle2(joint); + dReal r = dJointGetUniversalAngle2Rate(joint); + dReal diff = a - last_angle; + if (diff > M_PI) diff -= 2*M_PI; + if (diff < -M_PI) diff += 2*M_PI; + dReal er = diff / STEPSIZE; // estimated rate + last_angle = a; + return fabs(r - er) * 1e10; + } + + case 740:{ + dVector3 ax1, ax2; + dJointGetUniversalAxis1(joint, ax1); + dJointGetUniversalAxis2(joint, ax2); + addOscillatingTorqueAbout (0.1, ax2[0], ax2[1], ax2[2]); + dampRotationalMotion (0.1); + return fabs(10*dCalcVectorDot3(ax1, ax2)); + } + + case 741:{ + dVector3 ax2; + static dReal last_angle = 0; + dJointGetUniversalAxis2(joint, ax2); + addOscillatingTorqueAbout (0.1, ax2[0], ax2[1], ax2[2]); + dampRotationalMotion (0.1); + dReal a = dJointGetUniversalAngle1(joint); + dReal r = dJointGetUniversalAngle1Rate(joint); + dReal diff = a - last_angle; + if (diff > M_PI) diff -= 2*M_PI; + if (diff < -M_PI) diff += 2*M_PI; + dReal er = diff / STEPSIZE; // estimated rate + last_angle = a; + return fabs(r - er) * 1e10; + } + + case 742:{ + dVector3 ax2; + static dReal last_angle = 0; + dJointGetUniversalAxis2(joint, ax2); + addOscillatingTorqueAbout (0.1, ax2[0], ax2[1], ax2[2]); + dampRotationalMotion (0.1); + dReal a = dJointGetUniversalAngle2(joint); + dReal r = dJointGetUniversalAngle2Rate(joint); + dReal diff = a - last_angle; + if (diff > M_PI) diff -= 2*M_PI; + if (diff < -M_PI) diff += 2*M_PI; + dReal er = diff / STEPSIZE; // estimated rate + last_angle = a; + return fabs(r - er) * 1e4; + } + + // ********** slider joint + case 801: + case 803: + addSpringForce (0.25); + return dInfinity; + + case 802: + case 804: { + static dReal a = 0; + dBodyAddTorque (body[0], 0, 0.01*cos(1.5708*a), 0); + a += 0.01; + return dInfinity; + } + + case 805: + addOscillatingForce (0.1); + return dInfinity; + } + + + return dInfinity; +} + +//**************************************************************************** +// simulation stuff common to all the tests + +// start simulation - set viewpoint + +static void start() +{ + dAllocateODEDataForThread(dAllocateMaskAll); + + static float xyz[3] = {1.0382f,-1.0811f,1.4700f}; + static float hpr[3] = {135.0000f,-19.5000f,0.0000f}; + dsSetViewpoint (xyz,hpr); +} + + +// simulation loop + +static void simLoop (int pause) +{ + // stop after a given number of iterations, as long as we are not in + // interactive mode + if (cmd_graphics && !cmd_interactive && + (iteration >= max_iterations)) { + dsStop(); + return; + } + iteration++; + + if (!pause) { + // do stuff for this test and check to see if the joint is behaving well + dReal error = doStuffAndGetError (test_num); + if (error > max_error) max_error = error; + if (cmd_interactive && error < dInfinity) { + printf ("scaled error = %.4e\n",error); + } + + // take a step + dWorldStep (world,STEPSIZE); + + // occasionally re-orient the first body to create a deliberate error. + if (cmd_occasional_error) { + static int count = 0; + if ((count % 20)==0) { + // randomly adjust orientation of body[0] + const dReal *R1; + dMatrix3 R2,R3; + R1 = dBodyGetRotation (body[0]); + dRFromAxisAndAngle (R2,dRandReal()-0.5,dRandReal()-0.5, + dRandReal()-0.5,dRandReal()-0.5); + dMultiply0 (R3,R1,R2,3,3,3); + dBodySetRotation (body[0],R3); + + // randomly adjust position of body[0] + const dReal *pos = dBodyGetPosition (body[0]); + dBodySetPosition (body[0], + pos[0]+0.2*(dRandReal()-0.5), + pos[1]+0.2*(dRandReal()-0.5), + pos[2]+0.2*(dRandReal()-0.5)); + } + count++; + } + } + + if (cmd_graphics) { + dReal sides1[3] = {SIDE,SIDE,SIDE}; + dReal sides2[3] = {SIDE*0.99f,SIDE*0.99f,SIDE*0.99f}; + dsSetTexture (DS_WOOD); + dsSetColor (1,1,0); + dsDrawBox (dBodyGetPosition(body[0]),dBodyGetRotation(body[0]),sides1); + if (body[1]) { + dsSetColor (0,1,1); + dsDrawBox (dBodyGetPosition(body[1]),dBodyGetRotation(body[1]),sides2); + } + } +} + +//**************************************************************************** +// conduct a specific test, and report the results + +void doTest (int argc, char **argv, int n, int fatal_if_bad_n) +{ + test_num = n; + iteration = 0; + max_iterations = 300; + max_error = 0; + + if (! setupTest (n)) { + if (fatal_if_bad_n) dError (0,"bad test number"); + return; + } + + // setup pointers to drawstuff callback functions + dsFunctions fn; + fn.version = DS_VERSION; + fn.start = &start; + fn.step = &simLoop; + fn.command = 0; + fn.stop = 0; + if (cmd_path_to_textures) + fn.path_to_textures = cmd_path_to_textures; + else + fn.path_to_textures = DRAWSTUFF_TEXTURE_PATH; + + // run simulation + if (cmd_graphics) { + dsSimulationLoop (argc,argv,352,288,&fn); + } + else { + for (int i=0; i < max_iterations; i++) simLoop (0); + } + dWorldDestroy (world); + body[0] = 0; + body[1] = 0; + joint = 0; + + // print results + printf ("test %d: ",n); + if (max_error == dInfinity) printf ("error not computed\n"); + else { + printf ("max scaled error = %.4e",max_error); + if (max_error < 1) printf (" - passed\n"); + else printf (" - FAILED\n"); + } +} + +//**************************************************************************** +// main + +int main (int argc, char **argv) +{ + int i; + dInitODE2(0); + + // process the command line args. anything that starts with `-' is assumed + // to be a drawstuff argument. + for (i=1; i +#include +#include +#include +#include +#include +#include "texturepath.h" + +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawCylinder dsDrawCylinderD +#endif + + +using namespace std; + +dWorld *world; +dSpace *space; +dPlane *ground; +dBody *kbody; +dBox *kbox; +dJointGroup joints; +dCylinder *kpole; +dBody *matraca; +dBox *matraca_geom; +dHingeJoint *hinge; + +struct Box { + dBody body; + dBox geom; + Box() : + body(*world), + geom(*space, 0.2, 0.2, 0.2) + { + dMass mass; + mass.setBox(10, 0.2, 0.2, 0.2); + body.setMass(mass); + geom.setData(this); + geom.setBody(body); + } + void draw() const + { + dVector3 lengths; + geom.getLengths(lengths); + dsSetTexture(DS_WOOD); + dsSetColor(0,1,0); + dsDrawBox(geom.getPosition(), geom.getRotation(), lengths); + } +}; + +set boxes; +set to_remove; + +void dropBox() +{ + Box *box = new Box(); + + dReal px = (rand() / float(RAND_MAX)) * 2 - 1; + dReal py = (rand() / float(RAND_MAX)) * 2 - 1; + dReal pz = 2.5; + box->body.setPosition(px, py, pz); + + boxes.insert(box); +} + +void queueRemoval(dGeomID g) +{ + Box *b = (Box*)dGeomGetData(g); + to_remove.insert(b); +} + +void removeQueued() +{ + while (!to_remove.empty()) { + Box *b = *to_remove.begin(); + to_remove.erase(b); + boxes.erase(b); + delete b; + } +} + + +void nearCallback(void *, dGeomID g1, dGeomID g2) +{ + if (g1 == ground->id()) { + queueRemoval(g2); + return; + } + if (g2 == ground->id()) { + queueRemoval(g1); + return; + } + + dBodyID b1 = dGeomGetBody(g1); + dBodyID b2 = dGeomGetBody(g2); + + if (b1 && b2 && dAreConnectedExcluding(b1, b2, dJointTypeContact)) + return; + + const int MAX_CONTACTS = 10; + dContact contact[MAX_CONTACTS]; + int n = dCollide(g1, g2, MAX_CONTACTS, &contact[0].geom, sizeof(dContact)); + for (int i=0; i 2*M_PI) + t = 0; + dVector3 next_pos = { dCos(t), dSin(t), REAL(0.5)}; + dVector3 vel; + // vel = (next_pos - cur_pos) / timestep + dSubtractVectors3(vel, next_pos, kbody->getPosition()); + dScaleVector3(vel, 1/timestep); + kbody->setLinearVel(vel); + // end of hard-coded animation + + space->collide(0, nearCallback); + removeQueued(); + + world->quickStep(timestep); + joints.clear(); + } + + dVector3 lengths; + + // the moving platform + kbox->getLengths(lengths); + dsSetTexture(DS_WOOD); + dsSetColor(.3, .3, 1); + dsDrawBox(kbox->getPosition(), kbox->getRotation(), lengths); + dReal length, radius; + kpole->getParams(&radius, &length); + dsSetTexture(DS_CHECKERED); + dsSetColor(1, 1, 0); + dsDrawCylinder(kpole->getPosition(), kpole->getRotation(), length, radius); + + // the matraca + matraca_geom->getLengths(lengths); + dsSetColor(1,0,0); + dsSetTexture(DS_WOOD); + dsDrawBox(matraca_geom->getPosition(), matraca_geom->getRotation(), lengths); + + // and the boxes + for_each(boxes.begin(), boxes.end(), mem_fun(&Box::draw)); +} + +void command(int c) +{ + switch (c) { + case ' ': + dropBox(); + break; + } +} + +int main(int argc, char **argv) +{ + dInitODE(); + + // setup pointers to drawstuff callback functions + dsFunctions fn; + fn.version = DS_VERSION; + fn.start = 0; + fn.step = &simLoop; + fn.command = &command; + fn.stop = 0; + fn.path_to_textures = DRAWSTUFF_TEXTURE_PATH; + + cout << endl << "*** Press SPACE to drop boxes **" << endl; + + space = new dSimpleSpace(); + ground = new dPlane(*space, 0, 0, 1, 0); + + world = new dWorld; + world->setGravity(0, 0, -.5); + + kbody = new dBody(*world); + kbody->setKinematic(); + const dReal kx = 1, ky = 0, kz = .5; + kbody->setPosition(kx, ky, kz); + kbox = new dBox(*space, 3, 3, .5); + kbox->setBody(*kbody); + kpole = new dCylinder(*space, .125, 1.5); + kpole->setBody(*kbody); + dGeomSetOffsetPosition(kpole->id(), 0, 0, 0.8); + + matraca = new dBody(*world); + matraca->setPosition(kx+0, ky+1, kz+1); + matraca_geom = new dBox(*space, 0.5, 2, 0.75); + matraca_geom->setBody(*matraca); + dMass mass; + mass.setBox(1, 0.5, 2, 0.75); + matraca->setMass(mass); + + hinge = new dHingeJoint(*world); + hinge->attach(*kbody, *matraca); + hinge->setAnchor(kx, ky, kz+1); + hinge->setAxis(0, 0, 1); + + dsSimulationLoop (argc, argv, 640, 480, &fn); + + dCloseODE(); +} diff --git a/libs/ode-0.16.1/ode/demo/demo_motion.cpp b/libs/ode-0.16.1/ode/demo/demo_motion.cpp new file mode 100644 index 0000000..a83887d --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/demo_motion.cpp @@ -0,0 +1,527 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +/* + This demo shows how to use dContactMotionN in a lifting platform. +*/ +//#include // for usleep() +#include +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + + +// select correct drawing functions + +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawSphere dsDrawSphereD +#define dsDrawCylinder dsDrawCylinderD +#define dsDrawCapsule dsDrawCapsuleD +#define dsDrawConvex dsDrawConvexD +#endif + + +// some constants + +#define NUM 100 // max number of objects +#define DENSITY (5.0) // density of all objects +#define GPB 3 // maximum number of geometries per body +#define MAX_CONTACTS 8 // maximum number of contact points per body +#define USE_GEOM_OFFSET 1 + +// dynamics and collision objects + +struct MyObject { + dBodyID body; // the body + dGeomID geom[GPB]; // geometries representing this body +}; + +static int num=0; // number of objects in simulation +static int nextobj=0; // next object to recycle if num==NUM +static dWorldID world; +static dSpaceID space; +static MyObject obj[NUM]; +static dJointGroupID contactgroup; +static int show_aabb = 0; // show geom AABBs? +static int show_contacts = 0; // show contact points? +static int random_pos = 1; // drop objects from random position? +static int write_world = 0; +static int show_body = 0; + +static dGeomID platform, ground; + +dVector3 platpos = {0, 0, 0}; +int mov_type = 2; +dReal mov_time = 0; + + +const dReal mov1_speed = 0.2; + +dVector3 mov2_vel = { 0.2, 0.1, 0.25}; + + + + +/**************************************************************** + * Movement 1: move platform up, reset every 80 units of time. * + * This is the simplest case * + ****************************************************************/ +static void moveplat_1(dReal stepsize) +{ + mov_time += stepsize; + if (mov_time > 80) + mov_time = 0; + + platpos[0] = platpos[1] = 0; + // the platform moves up (Z) at constant speed: mov1_speed + platpos[2] = mov1_speed * mov_time; +} + +// Generate contact info for movement 1 +static void contactplat_1(dContact &contact) +{ + contact.surface.mode |= dContactMotionN; + contact.surface.motionN = mov1_speed; +} + + + +/**************************************************************** + * Movement 2: move platform along direction mov2_vel, reset * + * every 80 units of time. * + * This is the most general case: the geom moves along * + * an arbitrary direction. * + ****************************************************************/ +static void moveplat_2(dReal stepsize) +{ + mov_time += stepsize; + if (mov_time > 80) + mov_time = 0; + + // the platform moves at constant speed: mov2_speed + platpos[0] = mov2_vel[0] * mov_time; + platpos[1] = mov2_vel[1] * mov_time; + platpos[2] = mov2_vel[2] * mov_time; +} + +// Generate contact info for movement 1 +static void contactplat_2(dContact &contact) +{ + /* + For arbitrary contact directions we need to project the moving + geom's velocity against the contact normal and fdir1, fdir2 + (obtained with dPlaneSpace()). Assuming moving geom=g2 + (so the contact joint is in the moving geom's reference frame): + motion1 = dCalcVectorDot3(fdir1, vel); + motion2 = dCalcVectorDot3(fdir2, vel); + motionN = dCalcVectorDot3(normal, vel); + + For geom=g1 just negate motionN and motion2. fdir1 is an arbitrary + vector, so there's no need to negate motion1. + + */ + contact.surface.mode |= + dContactMotionN | // velocity along normal + dContactMotion1 | dContactMotion2 | // and along the contact plane + dContactFDir1; // don't forget to set the direction 1 + + + // This is a convenience function: given a vector, it finds other 2 perpendicular vectors + dVector3 motiondir1, motiondir2; + dPlaneSpace(contact.geom.normal, motiondir1, motiondir2); + for (int i=0; i<3; ++i) + contact.fdir1[i] = motiondir1[i]; + + + dReal inv = 1; + if (contact.geom.g1 == platform) + inv = -1; + + contact.surface.motion1 = dCalcVectorDot3(mov2_vel, motiondir1); + contact.surface.motion2 = inv * dCalcVectorDot3(mov2_vel, motiondir2); + contact.surface.motionN = inv * dCalcVectorDot3(mov2_vel, contact.geom.normal); + +} + + + + + +static void nearCallback (void *, dGeomID o1, dGeomID o2) +{ + dMatrix3 RI; + static const dReal ss[3] = {0.02,0.02,0.02}; + + dContact contact[MAX_CONTACTS]; + int numc = dCollide (o1, o2, MAX_CONTACTS, + &contact[0].geom, sizeof(dContact)); + + if (numc) + dRSetIdentity(RI); + + bool isplatform = (o1 == platform) || (o2 == platform); + + for (int i=0; i< numc; i++) { + contact[i].surface.mode = dContactBounce; + contact[i].surface.mu = 1; + contact[i].surface.bounce = 0.25; + contact[i].surface.bounce_vel = 0.01; + + if (isplatform) { + switch (mov_type) { + case 1: + contactplat_1(contact[i]); + break; + case 2: + contactplat_2(contact[i]); + break; + } + } + + dJointID c = dJointCreateContact (world,contactgroup,contact+i); + dJointAttach (c, dGeomGetBody(o1), dGeomGetBody(o2)); + if (show_contacts) + dsDrawBox (contact[i].geom.pos, RI, ss); + } +} + + +// start simulation - set viewpoint + +static float xyz[3] = {2.1106f,-1.3007,2.f}; +static float hpr[3] = {150.f,-13.5000f,0.0000f}; + +static void start() +{ + //dAllocateODEDataForThread(dAllocateMaskAll); + dsSetViewpoint (xyz,hpr); + printf ("To drop another object, press:\n"); + printf (" b for box.\n"); + printf (" s for sphere.\n"); + printf (" c for capsule.\n"); + printf (" y for cylinder.\n"); + printf ("Press m to change the movement type\n"); + printf ("Press space to reset the platform\n"); + printf ("To toggle showing the geom AABBs, press a.\n"); + printf ("To toggle showing the contact points, press t.\n"); + printf ("To toggle dropping from random position/orientation, press r.\n"); + printf ("To save the current state to 'state.dif', press 1.\n"); +} + + +char locase (char c) +{ + if (c >= 'A' && c <= 'Z') return c - ('a'-'A'); + else return c; +} + + +// called when a key pressed + +static void command (int cmd) +{ + dsizeint i; + int k; + dReal sides[3]; + dMass m; + int setBody; + + cmd = locase (cmd); + if (cmd == 'b' || cmd == 's' || cmd == 'c' || cmd == 'y') + { + setBody = 0; + if (num < NUM) { + i = num; + num++; + } + else { + i = nextobj; + nextobj++; + if (nextobj >= num) nextobj = 0; + + // destroy the body and geoms for slot i + if (obj[i].body) { + dBodyDestroy (obj[i].body); + } + for (k=0; k < GPB; k++) { + if (obj[i].geom[k]) { + dGeomDestroy (obj[i].geom[k]); + } + } + memset (&obj[i],0,sizeof(obj[i])); + } + + obj[i].body = dBodyCreate (world); + for (k=0; k<3; k++) sides[k] = dRandReal()*0.5+0.1; + + dMatrix3 R; + if (random_pos) + { + dBodySetPosition (obj[i].body, + dRandReal()*2-1 + platpos[0], + dRandReal()*2-1 + platpos[1], + dRandReal()+2 + platpos[2]); + dRFromAxisAndAngle (R,dRandReal()*2.0-1.0,dRandReal()*2.0-1.0, + dRandReal()*2.0-1.0,dRandReal()*10.0-5.0); + } + else + { + dBodySetPosition (obj[i].body, + platpos[0], + platpos[1], + platpos[2]+2); + dRSetIdentity (R); + } + dBodySetRotation (obj[i].body,R); + dBodySetData (obj[i].body,(void*) i); + + if (cmd == 'b') { + dMassSetBox (&m,DENSITY,sides[0],sides[1],sides[2]); + obj[i].geom[0] = dCreateBox (space,sides[0],sides[1],sides[2]); + } + else if (cmd == 'c') { + sides[0] *= 0.5; + dMassSetCapsule (&m,DENSITY,3,sides[0],sides[1]); + obj[i].geom[0] = dCreateCapsule (space,sides[0],sides[1]); + } + else if (cmd == 'y') { + dMassSetCylinder (&m,DENSITY,3,sides[0],sides[1]); + obj[i].geom[0] = dCreateCylinder (space,sides[0],sides[1]); + } + else if (cmd == 's') { + sides[0] *= 0.5; + dMassSetSphere (&m,DENSITY,sides[0]); + obj[i].geom[0] = dCreateSphere (space,sides[0]); + } + + if (!setBody) + for (k=0; k < GPB; k++) { + if (obj[i].geom[k]) { + dGeomSetBody (obj[i].geom[k],obj[i].body); + } + } + + dBodySetMass (obj[i].body,&m); + } + else if (cmd == 'a') { + show_aabb ^= 1; + } + else if (cmd == 't') { + show_contacts ^= 1; + } + else if (cmd == 'r') { + random_pos ^= 1; + } + else if (cmd == '1') { + write_world = 1; + } + else if (cmd == ' ') { + mov_time = 0; + } + else if (cmd == 'm') { + mov_type = mov_type==1 ? 2 : 1; + mov_time = 0; + } +} + + +// draw a geom + +void drawGeom (dGeomID g, const dReal *pos, const dReal *R, int show_aabb) +{ + int i; + + if (!g) return; + if (!pos) pos = dGeomGetPosition (g); + if (!R) R = dGeomGetRotation (g); + + int type = dGeomGetClass (g); + if (type == dBoxClass) { + dVector3 sides; + dGeomBoxGetLengths (g,sides); + dsDrawBox (pos,R,sides); + } + else if (type == dSphereClass) { + dsDrawSphere (pos,R,dGeomSphereGetRadius (g)); + } + else if (type == dCapsuleClass) { + dReal radius,length; + dGeomCapsuleGetParams (g,&radius,&length); + dsDrawCapsule (pos,R,length,radius); + } + else if (type == dCylinderClass) { + dReal radius,length; + dGeomCylinderGetParams (g,&radius,&length); + dsDrawCylinder (pos,R,length,radius); + } + + if (show_body) { + dBodyID body = dGeomGetBody(g); + if (body) { + const dReal *bodypos = dBodyGetPosition (body); + const dReal *bodyr = dBodyGetRotation (body); + dReal bodySides[3] = { 0.1, 0.1, 0.1 }; + dsSetColorAlpha(0,1,0,1); + dsDrawBox(bodypos,bodyr,bodySides); + } + } + if (show_aabb) { + // draw the bounding box for this geom + dReal aabb[6]; + dGeomGetAABB (g,aabb); + dVector3 bbpos; + for (i=0; i<3; i++) bbpos[i] = 0.5*(aabb[i*2] + aabb[i*2+1]); + dVector3 bbsides; + for (i=0; i<3; i++) bbsides[i] = aabb[i*2+1] - aabb[i*2]; + dMatrix3 RI; + dRSetIdentity (RI); + dsSetColorAlpha (1,0,0,0.5); + dsDrawBox (bbpos,RI,bbsides); + } +} + + +// simulation loop + +static void updatecam() +{ + xyz[0] = platpos[0] + 3.3; + xyz[1] = platpos[1] - 1.8; + xyz[2] = platpos[2] + 2; + dsSetViewpoint (xyz, hpr); +} + +static void simLoop (int pause) +{ + const dReal stepsize = 0.02; + + dsSetColor (0,0,2); + dSpaceCollide (space,0,&nearCallback); + if (!pause) { + + if (mov_type == 1) + moveplat_1(stepsize); + else + moveplat_2(stepsize); + + dGeomSetPosition(platform, platpos[0], platpos[1], platpos[2]); + updatecam(); + dWorldQuickStep (world,stepsize); + //dWorldStep (world,stepsize); + } + + if (write_world) { + FILE *f = fopen ("state.dif","wt"); + if (f) { + dWorldExportDIF (world,f,"X"); + fclose (f); + } + write_world = 0; + } + + // remove all contact joints + dJointGroupEmpty (contactgroup); + + dsSetColor (1,1,0); + dsSetTexture (DS_WOOD); + for (int i=0; i +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +// select correct drawing functions +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#endif + + +// some constants +#define SIDE (0.5f) // side length of a box +#define MASS (1.0) // mass of a box + + +// dynamics and collision objects +static dWorldID world; +static dBodyID body[2]; +static dGeomID geom[2]; +static dJointID lmotor[2]; +static dJointID amotor[2]; +static dSpaceID space; +static dJointGroupID contactgroup; + + +// start simulation - set viewpoint + +static void start() +{ + dAllocateODEDataForThread(dAllocateMaskAll); + + static float xyz[3] = {1.0382f,-1.0811f,1.4700f}; + static float hpr[3] = {135.0000f,-19.5000f,0.0000f}; + dsSetViewpoint (xyz,hpr); + printf ("Press 'q,a,z' to control one axis of lmotor connectiong two bodies. (q is +,a is 0, z is -)\n"); + printf ("Press 'w,e,r' to control one axis of lmotor connectiong first body with world. (w is +,e is 0, r is -)\n"); +} + + +// called when a key pressed + +static void command (int cmd) +{ + if (cmd == 'q' || cmd == 'Q') { + dJointSetLMotorParam(lmotor[0],dParamVel,0); + dJointSetLMotorParam(lmotor[0],dParamVel2,0); + dJointSetLMotorParam(lmotor[0],dParamVel3,0.1); + } else if (cmd == 'a' || cmd == 'A') { + dJointSetLMotorParam(lmotor[0],dParamVel,0); + dJointSetLMotorParam(lmotor[0],dParamVel2,0); + dJointSetLMotorParam(lmotor[0],dParamVel3,0); + } else if (cmd == 'z' || cmd == 'Z') { + dJointSetLMotorParam(lmotor[0],dParamVel,0); + dJointSetLMotorParam(lmotor[0],dParamVel2,0); + dJointSetLMotorParam(lmotor[0],dParamVel3,-0.1); + } else if (cmd == 'w' || cmd == 'W') { + dJointSetLMotorParam(lmotor[1],dParamVel,0.1); + dJointSetLMotorParam(lmotor[1],dParamVel2,0); + dJointSetLMotorParam(lmotor[1],dParamVel3,0); + } else if (cmd == 'e' || cmd == 'E') { + dJointSetLMotorParam(lmotor[1],dParamVel,0); + dJointSetLMotorParam(lmotor[1],dParamVel2,0); + dJointSetLMotorParam(lmotor[1],dParamVel3,0); + } else if (cmd == 'r' || cmd == 'R') { + dJointSetLMotorParam(lmotor[1],dParamVel,-0.1); + dJointSetLMotorParam(lmotor[1],dParamVel2,0); + dJointSetLMotorParam(lmotor[1],dParamVel3,0); + } + +} + + + +static void nearCallback (void *, dGeomID o1, dGeomID o2) +{ + // exit without doing anything if the two bodies are connected by a joint + dBodyID b1 = dGeomGetBody(o1); + dBodyID b2 = dGeomGetBody(o2); + + dContact contact; + contact.surface.mode = 0; + contact.surface.mu = dInfinity; + if (dCollide (o1,o2,1,&contact.geom,sizeof(dContactGeom))) { + dJointID c = dJointCreateContact (world,contactgroup,&contact); + dJointAttach (c,b1,b2); + } +} + +// simulation loop + +static void simLoop (int pause) +{ + if (!pause) { + dSpaceCollide(space,0,&nearCallback); + dWorldQuickStep (world,0.05); + dJointGroupEmpty(contactgroup); + } + + dReal sides1[3]; + dGeomBoxGetLengths(geom[0], sides1); + dReal sides2[3]; + dGeomBoxGetLengths(geom[1], sides2); + dsSetTexture (DS_WOOD); + dsSetColor (1,1,0); + dsDrawBox (dBodyGetPosition(body[0]),dBodyGetRotation(body[0]),sides1); + dsSetColor (0,1,1); + dsDrawBox (dBodyGetPosition(body[1]),dBodyGetRotation(body[1]),sides2); +} + + +int main (int argc, char **argv) +{ + // setup pointers to drawstuff callback functions + dsFunctions fn; + fn.version = DS_VERSION; + fn.start = &start; + fn.step = &simLoop; + fn.command = &command; + fn.stop = 0; + fn.path_to_textures = DRAWSTUFF_TEXTURE_PATH; + + // create world + dInitODE2(0); + contactgroup = dJointGroupCreate(0); + world = dWorldCreate(); + space = dSimpleSpaceCreate(0); + dMass m; + dMassSetBox (&m,1,SIDE,SIDE,SIDE); + dMassAdjust (&m,MASS); + + body[0] = dBodyCreate (world); + dBodySetMass (body[0],&m); + dBodySetPosition (body[0],0,0,1); + geom[0] = dCreateBox(space,SIDE,SIDE,SIDE); + body[1] = dBodyCreate (world); + dBodySetMass (body[1],&m); + dBodySetPosition (body[1],0,0,2); + geom[1] = dCreateBox(space,SIDE,SIDE,SIDE); + + dGeomSetBody(geom[0],body[0]); + dGeomSetBody(geom[1],body[1]); + + lmotor[0] = dJointCreateLMotor (world,0); + dJointAttach (lmotor[0],body[0],body[1]); + lmotor[1] = dJointCreateLMotor (world,0); + dJointAttach (lmotor[1],body[0],0); + amotor[0] = dJointCreateAMotor(world,0); + dJointAttach(amotor[0], body[0],body[1]); + amotor[1] = dJointCreateAMotor(world,0); + dJointAttach(amotor[1], body[0], 0); + + for (int i=0; i<2; i++) { + dJointSetAMotorNumAxes(amotor[i], 3); + dJointSetAMotorAxis(amotor[i],0,1,1,0,0); + dJointSetAMotorAxis(amotor[i],1,1,0,1,0); + dJointSetAMotorAxis(amotor[i],2,1,0,0,1); + dJointSetAMotorParam(amotor[i],dParamFMax,0.00001); + dJointSetAMotorParam(amotor[i],dParamFMax2,0.00001); + dJointSetAMotorParam(amotor[i],dParamFMax3,0.00001); + + dJointSetAMotorParam(amotor[i],dParamVel,0); + dJointSetAMotorParam(amotor[i],dParamVel2,0); + dJointSetAMotorParam(amotor[i],dParamVel3,0); + + dJointSetLMotorNumAxes(lmotor[i],3); + dJointSetLMotorAxis(lmotor[i],0,1,1,0,0); + dJointSetLMotorAxis(lmotor[i],1,1,0,1,0); + dJointSetLMotorAxis(lmotor[i],2,1,0,0,1); + + dJointSetLMotorParam(lmotor[i],dParamFMax,0.0001); + dJointSetLMotorParam(lmotor[i],dParamFMax2,0.0001); + dJointSetLMotorParam(lmotor[i],dParamFMax3,0.0001); + } + + // run simulation + dsSimulationLoop (argc,argv,352,288,&fn); + + dJointGroupDestroy(contactgroup); + dSpaceDestroy (space); + dWorldDestroy (world); + dCloseODE(); + return 0; +} diff --git a/libs/ode-0.16.1/ode/demo/demo_moving_convex.cpp b/libs/ode-0.16.1/ode/demo/demo_moving_convex.cpp new file mode 100644 index 0000000..2f03900 --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/demo_moving_convex.cpp @@ -0,0 +1,415 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001-2003 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#include +#include +#include "texturepath.h" +#include "bunny_geom.h" +#include "convex_bunny_geom.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +// select correct drawing functions + +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawSphere dsDrawSphereD +#define dsDrawCylinder dsDrawCylinderD +#define dsDrawCapsule dsDrawCapsuleD +#define dsDrawLine dsDrawLineD +#define dsDrawTriangle dsDrawTriangleD +#define dsDrawConvex dsDrawConvexD +#endif + + +// some constants + +#define NUM 200 // max number of objects +#define DENSITY (5.0) // density of all objects +#define GPB 3 // maximum number of geometries per body +#define MAX_CONTACTS 64 // maximum number of contact points per body + + +// dynamics and collision objects + +struct MyObject +{ + dBodyID body; // the body + dGeomID geom[GPB]; // geometries representing this body +}; + +static int num=0; // number of objects in simulation +static int nextobj=0; // next object to recycle if num==NUM +static dWorldID world; +static dSpaceID space; +static MyObject obj[NUM]; +static dJointGroupID contactgroup; +static int selected = -1; // selected object +static int show_aabb = 0; // show geom AABBs? +static int show_contacts = 0; // show contact points? +static int random_pos = 1; // drop objects from random position? + +typedef dReal dVector3R[3]; + +// this is called by dSpaceCollide when two objects in space are +// potentially colliding. + +static void nearCallback( void *, dGeomID o1, dGeomID o2 ) +{ + int i; + // if (o1->body && o2->body) return; + + // exit without doing anything if the two bodies are connected by a joint + dBodyID b1 = dGeomGetBody( o1 ); + dBodyID b2 = dGeomGetBody( o2 ); + if ( b1 && b2 && dAreConnectedExcluding( b1,b2,dJointTypeContact ) ) return; + + dContact contact[MAX_CONTACTS]; // up to MAX_CONTACTS contacts per box-box + for ( i=0; i= 'A' && c <= 'Z' ) return c - ( 'a'-'A' ); + else return c; +} + + +// called when a key pressed +static void command( int cmd ) +{ + int i,k; + dReal sides[3]; + dMass m; + + cmd = locase( cmd ); + if ( cmd == 'v' || cmd == 'b' || cmd == 'c' || cmd == 's' || cmd == 'y') + { + if ( num < NUM ) + { + i = num; + num++; + } + else + { + i = nextobj; + nextobj++; + if ( nextobj >= num ) nextobj = 0; + + // destroy the body and geoms for slot i + dBodyDestroy( obj[i].body ); + for ( k=0; k < GPB; k++ ) + { + if ( obj[i].geom[k] ) dGeomDestroy( obj[i].geom[k] ); + } + memset( &obj[i],0,sizeof( obj[i] ) ); + } + + obj[i].body = dBodyCreate( world ); + for ( k=0; k<3; k++ ) sides[k] = dRandReal()*0.5+0.1; + + dMatrix3 R; + if ( random_pos ) + { + dBodySetPosition( obj[i].body, + dRandReal()*2-1,dRandReal()*2-1,dRandReal()+3 ); + dRFromAxisAndAngle( R,dRandReal()*2.0-1.0,dRandReal()*2.0-1.0, + dRandReal()*2.0-1.0,dRandReal()*10.0-5.0 ); + } + else + { + dReal maxheight = 0; + for ( k=0; k maxheight ) maxheight = pos[2]; + } + dBodySetPosition( obj[i].body, 0,0,maxheight+1 ); + dRFromAxisAndAngle( R,0,0,1,dRandReal()*10.0-5.0 ); + } + dBodySetRotation( obj[i].body,R ); + dBodySetData( obj[i].body,( void* )( dsizeint )i ); + + if ( cmd == 'b' ) + { + dMassSetBox( &m,DENSITY,sides[0],sides[1],sides[2] ); + obj[i].geom[0] = dCreateBox( space,sides[0],sides[1],sides[2] ); + } + else if ( cmd == 'c' ) + { + sides[0] *= 0.5; + dMassSetCapsule( &m,DENSITY,3,sides[0],sides[1] ); + obj[i].geom[0] = dCreateCapsule( space,sides[0],sides[1] ); + } + else if (cmd == 'y') { + dMassSetCylinder (&m,DENSITY,3,sides[0],sides[1]); + obj[i].geom[0] = dCreateCylinder (space,sides[0],sides[1]); + } + else if ( cmd == 's' ) + { + sides[0] *= 0.5; + dMassSetSphere( &m,DENSITY,sides[0] ); + obj[i].geom[0] = dCreateSphere( space,sides[0] ); + } + else if ( cmd == 'v' ) + { + obj[i].geom[0] = dCreateConvex( space, + convexBunnyPlanes, + convexBunnyPlaneCount, + convexBunnyPoints, + convexBunnyPointCount, + convexBunnyPolygons ); + + /// Use equivalent TriMesh to set mass + dTriMeshDataID new_tmdata = dGeomTriMeshDataCreate(); + dGeomTriMeshDataBuildSingle( new_tmdata, &Vertices[0], 3 * sizeof( float ), VertexCount, + ( dTriIndex* )&Indices[0], IndexCount, 3 * sizeof( dTriIndex ) ); + dGeomTriMeshDataPreprocess2( new_tmdata, (1U << dTRIDATAPREPROCESS_BUILD_FACE_ANGLES), NULL ); + + dGeomID triMesh = dCreateTriMesh( 0, new_tmdata, 0, 0, 0 ); + + dMassSetTrimesh( &m, DENSITY, triMesh ); + + dGeomDestroy( triMesh ); + dGeomTriMeshDataDestroy( new_tmdata ); + + printf( "mass at %f %f %f\n", m.c[0], m.c[1], m.c[2] ); + dGeomSetPosition( obj[i].geom[0], -m.c[0], -m.c[1], -m.c[2] ); + dMassTranslate( &m, -m.c[0], -m.c[1], -m.c[2] ); + } + + for ( k=0; k < GPB; k++ ) + { + if ( obj[i].geom[k] ) dGeomSetBody( obj[i].geom[k],obj[i].body ); + } + + dBodySetMass( obj[i].body,&m ); + } + + if ( cmd == ' ' ) + { + selected++; + if ( selected >= num ) selected = 0; + if ( selected < 0 ) selected = 0; + } + else if ( cmd == 'd' && selected >= 0 && selected < num ) + { + dBodyDisable( obj[selected].body ); + } + else if ( cmd == 'e' && selected >= 0 && selected < num ) + { + dBodyEnable( obj[selected].body ); + } + else if ( cmd == 'a' ) + { + show_aabb ^= 1; + } + else if ( cmd == 't' ) + { + show_contacts ^= 1; + } + else if ( cmd == 'r' ) + { + random_pos ^= 1; + } +} + +// draw a geom +void drawGeom( dGeomID g, const dReal *pos, const dReal *R, int show_aabb ) +{ + if ( !g ) return; + if ( !pos ) pos = dGeomGetPosition( g ); + if ( !R ) R = dGeomGetRotation( g ); + + int type = dGeomGetClass( g ); + if ( type == dBoxClass ) + { + dVector3 sides; + dGeomBoxGetLengths( g,sides ); + dsDrawBox( pos,R,sides ); + } + else if ( type == dSphereClass ) + { + dsDrawSphere( pos,R,dGeomSphereGetRadius( g ) ); + } + else if (type == dCylinderClass) { + dReal radius,length; + dGeomCylinderGetParams (g,&radius,&length); + dsDrawCylinder (pos,R,length,radius); + } + else if ( type == dCapsuleClass ) + { + dReal radius,length; + dGeomCapsuleGetParams( g,&radius,&length ); + dsDrawCapsule( pos,R,length,radius ); + } + else if ( type == dConvexClass ) + { + dsDrawConvex( pos,R, + convexBunnyPlanes, + convexBunnyPlaneCount, + convexBunnyPoints, + convexBunnyPointCount, + convexBunnyPolygons ); + } + + if ( show_aabb ) + { + // draw the bounding box for this geom + dReal aabb[6]; + dGeomGetAABB( g,aabb ); + dVector3 bbpos; + for ( int i=0; i<3; i++ ) bbpos[i] = 0.5*( aabb[i*2] + aabb[i*2+1] ); + dVector3 bbsides; + for ( int j=0; j<3; j++ ) bbsides[j] = aabb[j*2+1] - aabb[j*2]; + dMatrix3 RI; + dRSetIdentity( RI ); + dsSetColorAlpha( 1,0,0,0.5 ); + dsDrawBox( bbpos,RI,bbsides ); + } +} + +// simulation loop + +static void simLoop( int pause ) +{ + dsSetColor( 0,0,2 ); + dSpaceCollide( space,0,&nearCallback ); + + if ( !pause ) dWorldQuickStep( world,0.05 ); + + for ( int j = 0; j < dSpaceGetNumGeoms( space ); j++ ) + { + dSpaceGetGeom( space, j ); + } + + // remove all contact joints + dJointGroupEmpty( contactgroup ); + + dsSetColor( 1,1,0 ); + dsSetTexture( DS_WOOD ); + for ( int i=0; i +#include +#include "texturepath.h" +#include "bunny_geom.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +//<---- Convex Object +static const dReal planes[] = // planes for a cube +{ + 1.0f ,0.0f ,0.0f ,0.25f, + 0.0f ,1.0f ,0.0f ,0.25f, + 0.0f ,0.0f ,1.0f ,0.25f, + 0.0f ,0.0f ,-1.0f,0.25f, + 0.0f ,-1.0f,0.0f ,0.25f, + -1.0f,0.0f ,0.0f ,0.25f + /* + 1.0f ,0.0f ,0.0f ,2.0f, + 0.0f ,1.0f ,0.0f ,1.0f, + 0.0f ,0.0f ,1.0f ,1.0f, + 0.0f ,0.0f ,-1.0f,1.0f, + 0.0f ,-1.0f,0.0f ,1.0f, + -1.0f,0.0f ,0.0f ,0.0f + */ +}; +static const unsigned int planecount=6; + +static const dReal points[] = // points for a cube +{ + 0.25f,0.25f,0.25f, + -0.25f,0.25f,0.25f, + + 0.25f,-0.25f,0.25f, + -0.25f,-0.25f,0.25f, + + 0.25f,0.25f,-0.25f, + -0.25f,0.25f,-0.25f, + + 0.25f,-0.25f,-0.25f, + -0.25f,-0.25f,-0.25f, +}; +static const unsigned int pointcount=8; + +static const unsigned int polygons[] = //Polygons for a cube (6 squares) + { + 4,0,2,6,4, // positive X + 4,1,0,4,5, // positive Y + 4,0,1,3,2, // positive Z + 4,3,1,5,7, // negative X + 4,2,3,7,6, // negative Y + 4,5,4,6,7, // negative Z + }; +//----> Convex Object + +int tmTriangles[] = +{ + 0,2,6, + 0,6,4, + 1,0,4, + 1,4,5, + 0,1,3, + 0,3,2, + 3,1,5, + 3,5,7, + 2,3,7, + 2,7,6, + 5,4,6, + 5,6,7 +}; + +float tmVertices[] = +{ + 0.25f,0.25f,0.25f, // point 0 + -0.25f,0.25f,0.25f, // point 1 + + 0.25f,-0.25f,0.25f, // point 2 + -0.25f,-0.25f,0.25f,// point 3 + + 0.25f,0.25f,-0.25f, // point 4 + -0.25f,0.25f,-0.25f,// point 5 + + 0.25f,-0.25f,-0.25f,// point 6 + -0.25f,-0.25f,-0.25f,// point 7 +}; + +// select correct drawing functions + +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawSphere dsDrawSphereD +#define dsDrawCylinder dsDrawCylinderD +#define dsDrawCapsule dsDrawCapsuleD +#define dsDrawLine dsDrawLineD +#define dsDrawTriangle dsDrawTriangleD +#define dsDrawConvex dsDrawConvexD +#endif + + +// some constants + +#define NUM 200 // max number of objects +#define DENSITY (5.0) // density of all objects +#define GPB 3 // maximum number of geometries per body +#define MAX_CONTACTS 64 // maximum number of contact points per body + + +// dynamics and collision objects + +struct MyObject { + dBodyID body; // the body + dGeomID geom[GPB]; // geometries representing this body + + // Trimesh only - double buffered matrices for 'last transform' setup + dReal matrix_dblbuff[ 16 * 2 ]; + int last_matrix_index; +}; + +static int num=0; // number of objects in simulation +static int nextobj=0; // next object to recycle if num==NUM +static dWorldID world; +static dSpaceID space; +static MyObject obj[NUM]; +static dJointGroupID contactgroup; +static int selected = -1; // selected object +static int show_aabb = 0; // show geom AABBs? +static int show_contacts = 0; // show contact points? +static int random_pos = 1; // drop objects from random position? + +typedef dReal dVector3R[3]; + +dGeomID TriMesh1; +dGeomID TriMesh2; +static dTriMeshDataID TriData1, TriData2; // reusable static trimesh data + +// this is called by dSpaceCollide when two objects in space are +// potentially colliding. + +static void nearCallback (void *, dGeomID o1, dGeomID o2) +{ + int i; + // if (o1->body && o2->body) return; + + // exit without doing anything if the two bodies are connected by a joint + dBodyID b1 = dGeomGetBody(o1); + dBodyID b2 = dGeomGetBody(o2); + if (b1 && b2 && dAreConnectedExcluding (b1,b2,dJointTypeContact)) return; + + dContact contact[MAX_CONTACTS]; // up to MAX_CONTACTS contacts per box-box + for (i=0; i= 'A' && c <= 'Z') return c - ('a'-'A'); + else return c; +} + + +// called when a key pressed + +static void command (int cmd) +{ + int i,j,k; + dReal sides[3]; + dMass m; + bool setBody = false; + + cmd = locase (cmd); + if (cmd == 'b' || cmd == 's' || cmd == 'c' || cmd == 'x' || cmd == 'm' || cmd == 'y' || cmd == 'v') { + if (num < NUM) { + i = num; + num++; + } + else { + i = nextobj; + nextobj++; + if (nextobj >= num) nextobj = 0; + + // destroy the body and geoms for slot i + dBodyDestroy (obj[i].body); + for (k=0; k < GPB; k++) { + if (obj[i].geom[k]) dGeomDestroy (obj[i].geom[k]); + } + memset (&obj[i],0,sizeof(obj[i])); + } + + obj[i].body = dBodyCreate (world); + for (k=0; k<3; k++) sides[k] = dRandReal()*0.5+0.1; + + dMatrix3 R; + if (random_pos) { + dBodySetPosition (obj[i].body, + dRandReal()*2-1,dRandReal()*2-1,dRandReal()+3); + dRFromAxisAndAngle (R,dRandReal()*2.0-1.0,dRandReal()*2.0-1.0, + dRandReal()*2.0-1.0,dRandReal()*10.0-5.0); + } + else { + dReal maxheight = 0; + for (k=0; k maxheight) maxheight = pos[2]; + } + dBodySetPosition (obj[i].body, 0,0,maxheight+1); + dRFromAxisAndAngle (R,0,0,1,dRandReal()*10.0-5.0); + } + dBodySetRotation (obj[i].body,R); + dBodySetData (obj[i].body,(void*)(dsizeint)i); + + if (cmd == 'b') { + dMassSetBox (&m,DENSITY,sides[0],sides[1],sides[2]); + obj[i].geom[0] = dCreateBox (space,sides[0],sides[1],sides[2]); + } + else if (cmd == 'c') { + sides[0] *= 0.5; + dMassSetCapsule (&m,DENSITY,3,sides[0],sides[1]); + obj[i].geom[0] = dCreateCapsule (space,sides[0],sides[1]); + } else if (cmd == 'v') { + + dMassSetBox (&m,DENSITY,0.25,0.25,0.25); + obj[i].geom[0] = dCreateConvex(space, + planes, + planecount, + points, + pointcount, + polygons); + } + else if (cmd == 'y') { + sides[1] *= 0.5; + dMassSetCylinder (&m,DENSITY,3,sides[0],sides[1]); + obj[i].geom[0] = dCreateCylinder (space,sides[0],sides[1]); + } + else if (cmd == 's') { + sides[0] *= 0.5; + dMassSetSphere (&m,DENSITY,sides[0]); + obj[i].geom[0] = dCreateSphere (space,sides[0]); + } + else if (cmd == 'm') { + dTriMeshDataID new_tmdata = dGeomTriMeshDataCreate(); + dGeomTriMeshDataBuildSingle(new_tmdata, &Vertices[0], 3 * sizeof(float), VertexCount, + (dTriIndex*)&Indices[0], IndexCount, 3 * sizeof(dTriIndex)); + dGeomTriMeshDataPreprocess2(new_tmdata, (1U << dTRIDATAPREPROCESS_BUILD_FACE_ANGLES), NULL); + + + obj[i].geom[0] = dCreateTriMesh(space, new_tmdata, 0, 0, 0); + + // remember the mesh's dTriMeshDataID on its userdata for convenience. + dGeomSetData(obj[i].geom[0], new_tmdata); + + dMassSetTrimesh( &m, DENSITY, obj[i].geom[0] ); + printf("mass at %f %f %f\n", m.c[0], m.c[1], m.c[2]); + dGeomSetPosition(obj[i].geom[0], -m.c[0], -m.c[1], -m.c[2]); + dMassTranslate(&m, -m.c[0], -m.c[1], -m.c[2]); + } + else if (cmd == 'x') { + + setBody = true; + // start accumulating masses for the composite geometries + dMass m2; + dMassSetZero (&m); + + dReal dpos[GPB][3]; // delta-positions for composite geometries + dMatrix3 drot[GPB]; + + // set random delta positions + for (j=0; j= num) selected = 0; + if (selected < 0) selected = 0; + } + else if (cmd == 'd' && selected >= 0 && selected < num) { + dBodyDisable (obj[selected].body); + } + else if (cmd == 'e' && selected >= 0 && selected < num) { + dBodyEnable (obj[selected].body); + } + else if (cmd == 'a') { + show_aabb ^= 1; + } + else if (cmd == 't') { + show_contacts ^= 1; + } + else if (cmd == 'r') { + random_pos ^= 1; + } +} + + +// draw a geom + +void drawGeom (dGeomID g, const dReal *pos, const dReal *R, int show_aabb) +{ + if (!g) return; + if (!pos) pos = dGeomGetPosition (g); + if (!R) R = dGeomGetRotation (g); + + int type = dGeomGetClass (g); + if (type == dBoxClass) { + dVector3 sides; + dGeomBoxGetLengths (g,sides); + dsDrawBox (pos,R,sides); + } + else if (type == dSphereClass) { + dsDrawSphere (pos,R,dGeomSphereGetRadius (g)); + } + else if (type == dCapsuleClass) { + dReal radius,length; + dGeomCapsuleGetParams (g,&radius,&length); + dsDrawCapsule (pos,R,length,radius); + } + else if (type == dCylinderClass) { + dReal radius,length; + dGeomCylinderGetParams (g,&radius,&length); + dsDrawCylinder (pos,R,length,radius); + } else if (type == dConvexClass) { + //dVector3 sides={0.50,0.50,0.50}; + dsDrawConvex(pos,R,planes, + planecount, + points, + pointcount, + polygons); + } + + if (show_aabb) { + // draw the bounding box for this geom + dReal aabb[6]; + dGeomGetAABB (g,aabb); + dVector3 bbpos; + for (int i=0; i<3; i++) bbpos[i] = 0.5*(aabb[i*2] + aabb[i*2+1]); + dVector3 bbsides; + for (int j=0; j<3; j++) bbsides[j] = aabb[j*2+1] - aabb[j*2]; + dMatrix3 RI; + dRSetIdentity (RI); + dsSetColorAlpha (1,0,0,0.5); + dsDrawBox (bbpos,RI,bbsides); + } +} + + +// set previous transformation matrix for trimesh +void setCurrentTransform(dGeomID geom) +{ + const dReal* Pos = dGeomGetPosition(geom); + const dReal* Rot = dGeomGetRotation(geom); + + const dReal Transform[16] = + { + Rot[0], Rot[4], Rot[8], 0, + Rot[1], Rot[5], Rot[9], 0, + Rot[2], Rot[6], Rot[10], 0, + Pos[0], Pos[1], Pos[2], 1 + }; + + dGeomTriMeshSetLastTransform( geom, *(dMatrix4*)(&Transform) ); + +} + + +// simulation loop + +static void simLoop (int pause) +{ + dsSetColor (0,0,2); + dSpaceCollide (space,0,&nearCallback); + + +#if 1 + // What is this for??? - Bram + if (!pause) + { + for (int i=0; i +#include + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +//**************************************************************************** +// matrix sizes + +#define dALIGN_SIZE(buf_size, alignment) (((buf_size) + (alignment - 1)) & (int)(~(alignment - 1))) // Casting the mask to int ensures sign-extension to larger integer sizes +#define dALIGN_PTR(buf_ptr, alignment) ((void *)(((duintptr)(buf_ptr) + ((alignment) - 1)) & (int)(~(alignment - 1)))) // Casting the mask to int ensures sign-extension to larger integer sizes + +#define MSIZE 21 +#define MSIZE4 dALIGN_SIZE(MSIZE, 4) // MSIZE rounded up to 4 + + + +//**************************************************************************** +// matrix accessors + +#define _A(i,j) A[(i)*4+(j)] +#define _I(i,j) I[(i)*4+(j)] +#define _R(i,j) R[(i)*4+(j)] + +//**************************************************************************** +// tolerances + +#ifdef dDOUBLE +const double tol = 1e-10; +#endif + +#ifdef dSINGLE +const double tol = 1e-5; +#endif + +//**************************************************************************** +// misc messages and error handling + +#ifdef __GNUC__ +#define HEADER printf ("%s()\n", __FUNCTION__); +#else +#define HEADER printf ("%s:%d\n",__FILE__,__LINE__); +#endif + +static jmp_buf jump_buffer; + + +void myMessageFunction (int num, const char *msg, va_list ap) +{ + printf ("(Message %d: ",num); + vprintf (msg,ap); + printf (")"); + dSetMessageHandler (0); + longjmp (jump_buffer,1); +} + + +#define TRAP_MESSAGE(do,ifnomsg,ifmsg) \ + dSetMessageHandler (&myMessageFunction); \ + if (setjmp (jump_buffer)) { \ + dSetMessageHandler (0); \ + ifmsg ; \ + } \ + else { \ + dSetMessageHandler (&myMessageFunction); \ + do ; \ + ifnomsg ; \ + } \ + dSetMessageHandler (0); + +//**************************************************************************** +// utility stuff + +// compare two numbers, within a threshhold, return 1 if approx equal + +int cmp (dReal a, dReal b) +{ + return (fabs(a-b) < tol); +} + +//**************************************************************************** +// matrix utility stuff + +// compare a 3x3 matrix with the identity + +int cmpIdentityMat3 (dMatrix3 A) +{ + return + (cmp(_A(0,0),1.0) && cmp(_A(0,1),0.0) && cmp(_A(0,2),0.0) && + cmp(_A(1,0),0.0) && cmp(_A(1,1),1.0) && cmp(_A(1,2),0.0) && + cmp(_A(2,0),0.0) && cmp(_A(2,1),0.0) && cmp(_A(2,2),1.0)); +} + + +// transpose a 3x3 matrix in-line + +void transpose3x3 (dMatrix3 A) +{ + dReal tmp; + tmp=A[4]; A[4]=A[1]; A[1]=tmp; + tmp=A[8]; A[8]=A[2]; A[2]=tmp; + tmp=A[9]; A[9]=A[6]; A[6]=tmp; +} + +//**************************************************************************** +// test miscellaneous math functions + +void testRandomNumberGenerator() +{ + HEADER; + if (dTestRand()) printf ("\tpassed\n"); + else printf ("\tFAILED\n"); +} + + +void testInfinity() +{ + HEADER; + if (1e10 < dInfinity && -1e10 > -dInfinity && -dInfinity < dInfinity) + printf ("\tpassed\n"); + else printf ("\tFAILED\n"); +} + + +void testPad() +{ + HEADER; + char s[100]; + s[0]=0; + for (int i=0; i<=16; i++) sprintf (s+strlen(s),"%d ",dPAD(i)); + printf ("\t%s\n", strcmp(s,"0 1 4 4 4 8 8 8 8 12 12 12 12 16 16 16 16 ") ? + "FAILED" : "passed"); +} + + +void testCrossProduct() +{ + HEADER; + + dVector3 a1,a2,b,c; + dMatrix3 B; + dMakeRandomVector (b,3,1.0); + dMakeRandomVector (c,3,1.0); + + dCalcVectorCross3(a1,b,c); + + dSetZero (B,12); + dSetCrossMatrixPlus(B,b,4); + dMultiply0 (a2,B,c,3,3,1); + + dReal diff = dMaxDifference(a1,a2,3,1); + printf ("\t%s\n", diff > tol ? "FAILED" : "passed"); +} + + +void testSetZero() +{ + HEADER; + dReal a[100]; + dMakeRandomVector (a,100,1.0); + dSetZero (a,100); + for (int i=0; i<100; i++) if (a[i] != 0.0) { + printf ("\tFAILED\n"); + return; + } + printf ("\tpassed\n"); +} + + +void testNormalize3() +{ + HEADER; + int i,j,bad=0; + dVector3 n1,n2; + for (i=0; i<1000; i++) { + dMakeRandomVector (n1,3,1.0); + for (j=0; j<3; j++) n2[j]=n1[j]; + dNormalize3 (n2); + if (dFabs(dCalcVectorDot3(n2,n2) - 1.0) > tol) bad |= 1; + if (dFabs(n2[0]/n1[0] - n2[1]/n1[1]) > tol) bad |= 2; + if (dFabs(n2[0]/n1[0] - n2[2]/n1[2]) > tol) bad |= 4; + if (dFabs(n2[1]/n1[1] - n2[2]/n1[2]) > tol) bad |= 8; + if (dFabs(dCalcVectorDot3(n2,n1) - dSqrt(dCalcVectorDot3(n1,n1))) > tol) bad |= 16; + if (bad) { + printf ("\tFAILED (code=%x)\n",bad); + return; + } + } + printf ("\tpassed\n"); +} + + +/* +void testReorthonormalize() +{ +HEADER; +dMatrix3 R,I; +dMakeRandomMatrix (R,3,3,1.0); +for (int i=0; i<30; i++) dReorthonormalize (R); +dMultiply2 (I,R,R,3,3,3); +printf ("\t%s\n",cmpIdentityMat3 (I) ? "passed" : "FAILED"); +} +*/ + + +void testPlaneSpace() +{ + HEADER; + dVector3 n,p,q; + int bad = 0; + for (int i=0; i<1000; i++) { + dMakeRandomVector (n,3,1.0); + dNormalize3 (n); + dPlaneSpace (n,p,q); + if (fabs(dCalcVectorDot3(n,p)) > tol) bad = 1; + if (fabs(dCalcVectorDot3(n,q)) > tol) bad = 1; + if (fabs(dCalcVectorDot3(p,q)) > tol) bad = 1; + if (fabs(dCalcVectorDot3(p,p)-1) > tol) bad = 1; + if (fabs(dCalcVectorDot3(q,q)-1) > tol) bad = 1; + } + printf ("\t%s\n", bad ? "FAILED" : "passed"); +} + +//**************************************************************************** +// test matrix functions + +void testMatrixMultiply() +{ + // A is 2x3, B is 3x4, B2 is B except stored columnwise, C is 2x4 + dReal A[8],B[12],A2[12],B2[16],C[8]; + int i; + + HEADER; + dSetZero (A,8); + for (i=0; i<3; i++) A[i] = i+2; + for (i=0; i<3; i++) A[i+4] = i+3+2; + for (i=0; i<12; i++) B[i] = i+8; + dSetZero (A2,12); + for (i=0; i<6; i++) A2[i+2*(i/2)] = A[i+i/3]; + dSetZero (B2,16); + for (i=0; i<12; i++) B2[i+i/3] = B[i]; + + dMultiply0 (C,A,B,2,3,4); + if (C[0] != 116 || C[1] != 125 || C[2] != 134 || C[3] != 143 || + C[4] != 224 || C[5] != 242 || C[6] != 260 || C[7] != 278) + printf ("\tFAILED (1)\n"); else printf ("\tpassed (1)\n"); + + dMultiply1 (C,A2,B,2,3,4); + if (C[0] != 160 || C[1] != 172 || C[2] != 184 || C[3] != 196 || + C[4] != 196 || C[5] != 211 || C[6] != 226 || C[7] != 241) + printf ("\tFAILED (2)\n"); else printf ("\tpassed (2)\n"); + + dMultiply2 (C,A,B2,2,3,4); + if (C[0] != 83 || C[1] != 110 || C[2] != 137 || C[3] != 164 || + C[4] != 164 || C[5] != 218 || C[6] != 272 || C[7] != 326) + printf ("\tFAILED (3)\n"); else printf ("\tpassed (3)\n"); +} + + +void testSmallMatrixMultiply() +{ + dMatrix3 A,B,C,A2; + dVector3 a,a2,x; + + HEADER; + dMakeRandomMatrix (A,3,3,1.0); + dMakeRandomMatrix (B,3,3,1.0); + dMakeRandomMatrix (C,3,3,1.0); + dMakeRandomMatrix (x,3,1,1.0); + + // dMultiply0_331() + dMultiply0_331 (a,B,x); + dMultiply0 (a2,B,x,3,3,1); + printf ("\t%s (1)\n",(dMaxDifference (a,a2,3,1) > tol) ? "FAILED" : + "passed"); + + // dMultiply1_331() + dMultiply1_331 (a,B,x); + dMultiply1 (a2,B,x,3,3,1); + printf ("\t%s (2)\n",(dMaxDifference (a,a2,3,1) > tol) ? "FAILED" : + "passed"); + + // dMultiply0_133 + dMultiply0_133 (a,x,B); + dMultiply0 (a2,x,B,1,3,3); + printf ("\t%s (3)\n",(dMaxDifference (a,a2,1,3) > tol) ? "FAILED" : + "passed"); + + // dMultiply0_333() + dMultiply0_333 (A,B,C); + dMultiply0 (A2,B,C,3,3,3); + printf ("\t%s (4)\n",(dMaxDifference (A,A2,3,3) > tol) ? "FAILED" : + "passed"); + + // dMultiply1_333() + dMultiply1_333 (A,B,C); + dMultiply1 (A2,B,C,3,3,3); + printf ("\t%s (5)\n",(dMaxDifference (A,A2,3,3) > tol) ? "FAILED" : + "passed"); + + // dMultiply2_333() + dMultiply2_333 (A,B,C); + dMultiply2 (A2,B,C,3,3,3); + printf ("\t%s (6)\n",(dMaxDifference (A,A2,3,3) > tol) ? "FAILED" : + "passed"); +} + + +void testCholeskyFactorization() +{ + dsizeint matrixSize = sizeof(dReal) * MSIZE4 * MSIZE; + dReal *A = (dReal *)dAlloc(matrixSize), *B = (dReal *)dAlloc(matrixSize), *C = (dReal *)dAlloc(matrixSize), diff; + + HEADER; + dMakeRandomMatrix (A,MSIZE,MSIZE,1.0); + dMultiply2 (B,A,A,MSIZE,MSIZE,MSIZE); + memcpy (A,B,MSIZE4*MSIZE*sizeof(dReal)); + if (dFactorCholesky (B,MSIZE)) printf ("\tpassed (1)\n"); + else printf ("\tFAILED (1)\n"); + dClearUpperTriangle (B,MSIZE); + dMultiply2 (C,B,B,MSIZE,MSIZE,MSIZE); + diff = dMaxDifference(A,C,MSIZE,MSIZE); + printf ("\tmaximum difference = %.6e - %s (2)\n",diff, + diff > tol ? "FAILED" : "passed"); + + dFree(C, matrixSize); + dFree(B, matrixSize); + dFree(A, matrixSize); +} + + +void testCholeskySolve() +{ + dsizeint matrixSize = sizeof(dReal) * MSIZE4 * MSIZE, vectorSize = sizeof(dReal) * MSIZE; + dReal *A = (dReal *)dAlloc(matrixSize), *L = (dReal *)dAlloc(matrixSize); + dReal *b = (dReal *)dAlloc(vectorSize), *x = (dReal *)dAlloc(vectorSize), *btest = (dReal *)dAlloc(vectorSize), diff; + + HEADER; + + // get A,L = PD matrix + dMakeRandomMatrix (A,MSIZE,MSIZE,1.0); + dMultiply2 (L,A,A,MSIZE,MSIZE,MSIZE); + memcpy (A,L,MSIZE4*MSIZE*sizeof(dReal)); + + // get b,x = right hand side + dMakeRandomMatrix (b,MSIZE,1,1.0); + memcpy (x,b,MSIZE*sizeof(dReal)); + + // factor L + if (dFactorCholesky (L,MSIZE)) printf ("\tpassed (1)\n"); + else printf ("\tFAILED (1)\n"); + dClearUpperTriangle (L,MSIZE); + + // solve A*x = b + dSolveCholesky (L,x,MSIZE); + + // compute A*x and compare it with b + dMultiply2 (btest,A,x,MSIZE,MSIZE,1); + diff = dMaxDifference(b,btest,MSIZE,1); + printf ("\tmaximum difference = %.6e - %s (2)\n",diff, + diff > tol ? "FAILED" : "passed"); + + dFree(btest, vectorSize); + dFree(x, vectorSize); + dFree(b, vectorSize); + dFree(L, matrixSize); + dFree(A, matrixSize); +} + + +void testInvertPDMatrix() +{ + int i,j,ok; + dsizeint matrixSize = sizeof(dReal) * MSIZE4 * MSIZE; + dReal *A = (dReal *)dAlloc(matrixSize), *Ainv = (dReal *)dAlloc(matrixSize), *I = (dReal *)dAlloc(matrixSize); + + HEADER; + + dMakeRandomMatrix (A,MSIZE,MSIZE,1.0); + dMultiply2 (Ainv,A,A,MSIZE,MSIZE,MSIZE); + memcpy (A,Ainv,MSIZE4*MSIZE*sizeof(dReal)); + dSetZero (Ainv,MSIZE4*MSIZE); + + if (dInvertPDMatrix (A,Ainv,MSIZE)) + printf ("\tpassed (1)\n"); else printf ("\tFAILED (1)\n"); + dMultiply0 (I,A,Ainv,MSIZE,MSIZE,MSIZE); + + // compare with identity + ok = 1; + for (i=0; i tol ? "FAILED" : "passed"); + + dFree(d, vectorSize); + dFree(ATEST, matrixSize); + dFree(DL, matrixSize); + dFree(L, matrixSize); + dFree(A, matrixSize); +} + + +void testCoopLDLTFactorization() +{ + int i,j; + + const dsizeint COOP_MSIZE = MSIZE * 51, COOP_MSIZE4 = dALIGN_SIZE(COOP_MSIZE, 4); + + dsizeint matrixSize = sizeof(dReal) * COOP_MSIZE4 * COOP_MSIZE, vectorSize = sizeof(dReal) * COOP_MSIZE; + dReal *A = (dReal *)dAlloc(matrixSize), *L = (dReal *)dAlloc(matrixSize), *DL = (dReal *)dAlloc(matrixSize), + *ATEST = (dReal *)dAlloc(matrixSize), *d = (dReal *)dAlloc(vectorSize), diff; + + const unsigned threadCountMaximum = 8; + dThreadingImplementationID threading = dThreadingAllocateMultiThreadedImplementation(); + dCooperativeID cooperative = dCooperativeCreate(dThreadingImplementationGetFunctions(threading), threading); + dThreadingThreadPoolID pool = dThreadingAllocateThreadPool(threadCountMaximum, 0, dAllocateFlagBasicData, NULL); + dThreadingThreadPoolServeMultiThreadedImplementation(pool, threading); + + dResourceRequirementsID requirements = dResourceRequirementsCreate(cooperative); + dEstimateCooperativelyFactorLDLTResourceRequirements(requirements, threadCountMaximum, COOP_MSIZE); + dResourceContainerID resources = dResourceContainerAcquire(requirements); + + HEADER; + + for (int pass = 0; pass != 4; ++pass) + { + dTimerStart ("Factoring LDLT"); + + const unsigned allowedThreads = 4; + const unsigned PASS_MSIZE = COOP_MSIZE - pass, PASS_MSIZE4 = dALIGN_SIZE(PASS_MSIZE, 4); + + dTimerNow ("Preparing data"); + dMakeRandomMatrix (L, PASS_MSIZE, PASS_MSIZE, 1.0); + dMultiply2 (A, L, L, PASS_MSIZE, PASS_MSIZE, PASS_MSIZE); + memcpy (L, A, sizeof(dReal) * PASS_MSIZE4 * PASS_MSIZE); + + dTimerNow ("Factoring multi threaded"); + dCooperativelyFactorLDLT (resources, allowedThreads, L, d, PASS_MSIZE, PASS_MSIZE4); + + dTimerNow ("Verifying"); + dClearUpperTriangle (L, PASS_MSIZE); + for (i = 0; i < PASS_MSIZE; i++) L[i * PASS_MSIZE4 + i] = 1.0; + + dSetZero (DL, PASS_MSIZE4 * PASS_MSIZE); + for (i = 0; i < PASS_MSIZE; i++) { + for (j = 0; j < PASS_MSIZE; j++) DL[i * PASS_MSIZE4 + j] = L[i * PASS_MSIZE4 + j] / d[j]; + } + + dMultiply2 (ATEST, L, DL, PASS_MSIZE, PASS_MSIZE, PASS_MSIZE); + diff = dMaxDifference(A, ATEST, PASS_MSIZE, PASS_MSIZE); + printf ("\tN=%u: maximum difference = %.6e - %s\n", PASS_MSIZE, diff, diff > 1e2 * tol ? "FAILED" : "passed"); + + dTimerEnd(); + dTimerReport(stdout, 0); + } + + dResourceContainerDestroy(resources); + dResourceRequirementsDestroy(requirements); + + dThreadingImplementationShutdownProcessing(threading); + dThreadingFreeThreadPool(pool); + dCooperativeDestroy(cooperative); + dThreadingFreeImplementation(threading); + + dFree(d, vectorSize); + dFree(ATEST, matrixSize); + dFree(DL, matrixSize); + dFree(L, matrixSize); + dFree(A, matrixSize); +} + + +void testSolveLDLT() +{ + dsizeint matrixSize = sizeof(dReal) * MSIZE4 * MSIZE, vectorSize = sizeof(dReal) * MSIZE; + dReal *A = (dReal *)dAlloc(matrixSize), *L = (dReal *)dAlloc(matrixSize), + *d = (dReal *)dAlloc(vectorSize), *x = (dReal *)dAlloc(vectorSize), + *b = (dReal *)dAlloc(vectorSize), *btest = (dReal *)dAlloc(vectorSize), diff; + + HEADER; + + dMakeRandomMatrix (A,MSIZE,MSIZE,1.0); + dMultiply2 (L,A,A,MSIZE,MSIZE,MSIZE); + memcpy (A,L,MSIZE4*MSIZE*sizeof(dReal)); + + dMakeRandomMatrix (b,MSIZE,1,1.0); + memcpy (x,b,MSIZE*sizeof(dReal)); + + dFactorLDLT (L,d,MSIZE,MSIZE4); + dSolveLDLT (L,d,x,MSIZE,MSIZE4); + + dMultiply2 (btest,A,x,MSIZE,MSIZE,1); + diff = dMaxDifference(b,btest,MSIZE,1); + printf ("\tmaximum difference = %.6e - %s\n",diff, + diff > tol ? "FAILED" : "passed"); + + dFree(btest, vectorSize); + dFree(b, vectorSize); + dFree(x, vectorSize); + dFree(d, vectorSize); + dFree(L, matrixSize); + dFree(A, matrixSize); +} + +void testCoopSolveLDLT() +{ + const dsizeint COOP_MSIZE = MSIZE * 51, COOP_MSIZE4 = dALIGN_SIZE(COOP_MSIZE, 4); + + dsizeint matrixSize = sizeof(dReal) * COOP_MSIZE4 * COOP_MSIZE, vectorSize = sizeof(dReal) * COOP_MSIZE; + dReal *A = (dReal *)dAlloc(matrixSize), *L = (dReal *)dAlloc(matrixSize), + *d = (dReal *)dAlloc(vectorSize), *x = (dReal *)dAlloc(vectorSize), + *b = (dReal *)dAlloc(vectorSize), *btest = (dReal *)dAlloc(vectorSize), diff; + + const unsigned threadCountMaximum = 8; + dThreadingImplementationID threading = dThreadingAllocateMultiThreadedImplementation(); + dCooperativeID cooperative = dCooperativeCreate(dThreadingImplementationGetFunctions(threading), threading); + dThreadingThreadPoolID pool = dThreadingAllocateThreadPool(threadCountMaximum, 0, dAllocateFlagBasicData, NULL); + dThreadingThreadPoolServeMultiThreadedImplementation(pool, threading); + + dResourceRequirementsID requirements = dResourceRequirementsCreate(cooperative); + dEstimateCooperativelySolveLDLTResourceRequirements(requirements, threadCountMaximum, COOP_MSIZE); + dResourceContainerID resources = dResourceContainerAcquire(requirements); + + HEADER; + + for (int pass = 0; pass != 4; ++pass) + { + dTimerStart ("Solving LDLT"); + + const unsigned allowedThreads = 4; + const unsigned PASS_MSIZE = COOP_MSIZE - pass, PASS_MSIZE4 = dALIGN_SIZE(PASS_MSIZE, 4); + + dTimerNow ("Preparing data"); + dMakeRandomMatrix (b, PASS_MSIZE, 1, 1.0); + + dMakeRandomMatrix (L, PASS_MSIZE, PASS_MSIZE, 1.0); + dMultiply2 (A, L, L, PASS_MSIZE, PASS_MSIZE, PASS_MSIZE); + + memcpy (x, b, PASS_MSIZE * sizeof(dReal)); + memcpy (L, A, sizeof(dReal) * PASS_MSIZE4 * PASS_MSIZE); + + dTimerNow ("Factoring"); + dFactorLDLT (L, d, PASS_MSIZE, PASS_MSIZE4); + + dTimerNow ("Solving multi-threaded"); + dCooperativelySolveLDLT(resources, allowedThreads, L, d, x, PASS_MSIZE, PASS_MSIZE4); + + dTimerNow ("Verifying solution"); + dMultiply2 (btest, A, x, PASS_MSIZE, PASS_MSIZE, 1); + diff = dMaxDifference(b, btest, PASS_MSIZE, 1); + printf ("\tN=%u: maximum difference = %.6e - %s\n", PASS_MSIZE, diff, diff > 1e2 * tol ? "FAILED" : "passed"); + + dTimerEnd(); + dTimerReport(stdout, 0); + } + + dResourceContainerDestroy(resources); + dResourceRequirementsDestroy(requirements); + + dThreadingImplementationShutdownProcessing(threading); + dThreadingFreeThreadPool(pool); + dCooperativeDestroy(cooperative); + dThreadingFreeImplementation(threading); + + dFree(btest, vectorSize); + dFree(b, vectorSize); + dFree(x, vectorSize); + dFree(d, vectorSize); + dFree(L, matrixSize); + dFree(A, matrixSize); +} + + +void testLDLTAddTL() +{ + int i,j; + dsizeint matrixSize = sizeof(dReal) * MSIZE4 * MSIZE, vectorSize = sizeof(dReal) * MSIZE; + dReal *A = (dReal *)dAlloc(matrixSize), *L = (dReal *)dAlloc(matrixSize), + *DL = (dReal *)dAlloc(matrixSize), *ATEST = (dReal *)dAlloc(matrixSize), + *d = (dReal *)dAlloc(vectorSize), *a = (dReal *)dAlloc(vectorSize), diff; + + HEADER; + + dMakeRandomMatrix (A,MSIZE,MSIZE,1.0); + dMultiply2 (L,A,A,MSIZE,MSIZE,MSIZE); + memcpy (A,L,MSIZE4*MSIZE*sizeof(dReal)); + dFactorLDLT (L,d,MSIZE,MSIZE4); + + // delete first row and column of factorization + for (i=0; i tol ? "FAILED" : "passed"); + + dFree(a, vectorSize); + dFree(d, vectorSize); + dFree(ATEST, matrixSize); + dFree(DL, matrixSize); + dFree(L, matrixSize); + dFree(A, matrixSize); +} + + +void testLDLTRemove() +{ + int i,j,r; + dsizeint intVectorSize = sizeof(int) * MSIZE, matrixSize = sizeof(dReal) * MSIZE4 * MSIZE, vectorSize = sizeof(dReal) * MSIZE; + int *p = (int *)dAlloc(intVectorSize); + dReal *A = (dReal *)dAlloc(matrixSize), *L = (dReal *)dAlloc(matrixSize), + *L2 = (dReal *)dAlloc(matrixSize), *DL2 = (dReal *)dAlloc(matrixSize), + *Atest1 = (dReal *)dAlloc(matrixSize), *Atest2 = (dReal *)dAlloc(matrixSize), + *d = (dReal *)dAlloc(vectorSize), *d2 = (dReal *)dAlloc(vectorSize), diff, maxdiff; + + HEADER; + + // make array of A row pointers + dReal *Arows[MSIZE]; + for (i=0; i= r) ii--; + if (jj >= r) jj--; + if (A[i*MSIZE4+j] != Atest1[ii*MSIZE4+jj]) bad = 1; + } + } + } + if (bad) printf ("\trow/col removal FAILED for row %d\n",r); + + // zero out last row/column of Atest1 + for (i=0; i tol ? "FAILED" : "passed"); + + dFree(d2, vectorSize); + dFree(d, vectorSize); + dFree(Atest2, matrixSize); + dFree(Atest1, matrixSize); + dFree(DL2, matrixSize); + dFree(L2, matrixSize); + dFree(L, matrixSize); + dFree(A, matrixSize); +} + +//**************************************************************************** +// test mass stuff + +#define NUMP 10 // number of particles + + +void printMassParams (dMass *m) +{ + printf ("mass = %.4f\n",m->mass); + printf ("com = (%.4f,%.4f,%.4f)\n",m->c[0],m->c[1],m->c[2]); + printf ("I = [ %10.4f %10.4f %10.4f ]\n" + " [ %10.4f %10.4f %10.4f ]\n" + " [ %10.4f %10.4f %10.4f ]\n", + m->_I(0,0),m->_I(0,1),m->_I(0,2), + m->_I(1,0),m->_I(1,1),m->_I(1,2), + m->_I(2,0),m->_I(2,1),m->_I(2,2)); +} + + +void compareMassParams (dMass *m1, dMass *m2, const char *msg) +{ + int i,j,ok = 1; + if (!(cmp(m1->mass,m2->mass) && cmp(m1->c[0],m2->c[0]) && + cmp(m1->c[1],m2->c[1]) && cmp(m1->c[2],m2->c[2]))) + ok = 0; + for (i=0; i<3; i++) for (j=0; j<3; j++) + if (cmp (m1->_I(i,j),m2->_I(i,j))==0) ok = 0; + if (ok) printf ("\tpassed (%s)\n",msg); else printf ("\tFAILED (%s)\n",msg); +} + + +// compute the mass parameters of a particle set + +void computeMassParams (dMass *m, dReal q[NUMP][3], dReal pm[NUMP]) +{ + int i,j; + dMassSetZero (m); + for (i=0; imass += pm[i]; + for (j=0; j<3; j++) m->c[j] += pm[i]*q[i][j]; + m->_I(0,0) += pm[i]*(q[i][1]*q[i][1] + q[i][2]*q[i][2]); + m->_I(1,1) += pm[i]*(q[i][0]*q[i][0] + q[i][2]*q[i][2]); + m->_I(2,2) += pm[i]*(q[i][0]*q[i][0] + q[i][1]*q[i][1]); + m->_I(0,1) -= pm[i]*(q[i][0]*q[i][1]); + m->_I(0,2) -= pm[i]*(q[i][0]*q[i][2]); + m->_I(1,2) -= pm[i]*(q[i][1]*q[i][2]); + } + for (j=0; j<3; j++) m->c[j] /= m->mass; + m->_I(1,0) = m->_I(0,1); + m->_I(2,0) = m->_I(0,2); + m->_I(2,1) = m->_I(1,2); +} + + +void testMassFunctions() +{ + dMass m; + int i,j; + dReal q[NUMP][3]; // particle positions + dReal pm[NUMP]; // particle masses + dMass m1,m2; + dMatrix3 R; + + HEADER; + + printf ("\t"); + dMassSetZero (&m); + TRAP_MESSAGE (dMassSetParameters (&m,10, 0,0,0, 1,2,3, 4,5,6), + printf (" FAILED (1)\n"), printf (" passed (1)\n")); + + printf ("\t"); + dMassSetZero (&m); + TRAP_MESSAGE (dMassSetParameters (&m,10, 0.1,0.2,0.15, 3,5,14, 3.1,3.2,4), + printf ("passed (2)\n") , printf (" FAILED (2)\n")); + if (m.mass==10 && m.c[0]==REAL(0.1) && m.c[1]==REAL(0.2) && + m.c[2]==REAL(0.15) && m._I(0,0)==3 && m._I(1,1)==5 && m._I(2,2)==14 && + m._I(0,1)==REAL(3.1) && m._I(0,2)==REAL(3.2) && m._I(1,2)==4 && + m._I(1,0)==REAL(3.1) && m._I(2,0)==REAL(3.2) && m._I(2,1)==4) + printf ("\tpassed (3)\n"); else printf ("\tFAILED (3)\n"); + + dMassSetZero (&m); + dMassSetSphere (&m,1.4, 0.86); + if (cmp(m.mass,3.73002719949386) && m.c[0]==0 && m.c[1]==0 && m.c[2]==0 && + cmp(m._I(0,0),1.10349124669826) && + cmp(m._I(1,1),1.10349124669826) && + cmp(m._I(2,2),1.10349124669826) && + m._I(0,1)==0 && m._I(0,2)==0 && m._I(1,2)==0 && + m._I(1,0)==0 && m._I(2,0)==0 && m._I(2,1)==0) + printf ("\tpassed (4)\n"); else printf ("\tFAILED (4)\n"); + + dMassSetZero (&m); + dMassSetCapsule (&m,1.3,1,0.76,1.53); + if (cmp(m.mass,5.99961928996029) && m.c[0]==0 && m.c[1]==0 && m.c[2]==0 && + cmp(m._I(0,0),1.59461986077384) && + cmp(m._I(1,1),4.21878433864904) && + cmp(m._I(2,2),4.21878433864904) && + m._I(0,1)==0 && m._I(0,2)==0 && m._I(1,2)==0 && + m._I(1,0)==0 && m._I(2,0)==0 && m._I(2,1)==0) + printf ("\tpassed (5)\n"); else printf ("\tFAILED (5)\n"); + + dMassSetZero (&m); + dMassSetBox (&m,0.27,3,4,5); + if (cmp(m.mass,16.2) && m.c[0]==0 && m.c[1]==0 && m.c[2]==0 && + cmp(m._I(0,0),55.35) && cmp(m._I(1,1),45.9) && cmp(m._I(2,2),33.75) && + m._I(0,1)==0 && m._I(0,2)==0 && m._I(1,2)==0 && + m._I(1,0)==0 && m._I(2,0)==0 && m._I(2,1)==0) + printf ("\tpassed (6)\n"); else printf ("\tFAILED (6)\n"); + + // test dMassAdjust? + + // make random particles and compute the mass, COM and inertia, then + // translate and repeat. + for (i=0; i Q -> R works + dReal maxdiff=0; + for (i=0; i<100; i++) { + makeRandomRotation (R); + dRtoQ (R,q); + dQtoR (q,R2); + dReal diff = dMaxDifference (R,R2,3,3); + if (diff > maxdiff) maxdiff = diff; + } + printf ("\tmaximum difference = %e - %s (3)\n",maxdiff, + (maxdiff > tol) ? "FAILED" : "passed"); +} + + +void testQuaternionMultiply() +{ + HEADER; + dMatrix3 RA,RB,RC,Rtest; + dQuaternion qa,qb,qc; + dReal diff,maxdiff=0; + + for (int i=0; i<100; i++) { + makeRandomRotation (RB); + makeRandomRotation (RC); + dRtoQ (RB,qb); + dRtoQ (RC,qc); + + dMultiply0 (RA,RB,RC,3,3,3); + dQMultiply0 (qa,qb,qc); + dQtoR (qa,Rtest); + diff = dMaxDifference (Rtest,RA,3,3); + if (diff > maxdiff) maxdiff = diff; + + dMultiply1 (RA,RB,RC,3,3,3); + dQMultiply1 (qa,qb,qc); + dQtoR (qa,Rtest); + diff = dMaxDifference (Rtest,RA,3,3); + if (diff > maxdiff) maxdiff = diff; + + dMultiply2 (RA,RB,RC,3,3,3); + dQMultiply2 (qa,qb,qc); + dQtoR (qa,Rtest); + diff = dMaxDifference (Rtest,RA,3,3); + if (diff > maxdiff) maxdiff = diff; + + dMultiply0 (RA,RC,RB,3,3,3); + transpose3x3 (RA); + dQMultiply3 (qa,qb,qc); + dQtoR (qa,Rtest); + diff = dMaxDifference (Rtest,RA,3,3); + if (diff > maxdiff) maxdiff = diff; + } + printf ("\tmaximum difference = %e - %s\n",maxdiff, + (maxdiff > tol) ? "FAILED" : "passed"); +} + + +void testRotationFunctions() +{ + dMatrix3 R1; + HEADER; + + printf ("\tdRSetIdentity - "); + dMakeRandomMatrix (R1,3,3,1.0); + dRSetIdentity (R1); + if (cmpIdentityMat3(R1)) printf ("passed\n"); else printf ("FAILED\n"); + + printf ("\tdRFromAxisAndAngle - "); + + printf ("\n"); + printf ("\tdRFromEulerAngles - "); + + printf ("\n"); + printf ("\tdRFrom2Axes - "); + + printf ("\n"); +} + +//**************************************************************************** + +#include + +template +class simplevector +{ +private: + int n; + int max; + T* data; + +public: + simplevector() { initialize(); } + ~simplevector() { finalize(); } + T& operator[](int i) { assert(i>=0 && i=0 && i mat; + int afterfirst,index; + +public: + dMatrixComparison(); + ~dMatrixComparison(); + + dReal nextMatrix (dReal *A, int n, int m, int lower_tri, const char *name, ...); + // add a new n*m matrix A to the sequence. the name of the matrix is given + // by the printf-style arguments (name,...). if this is the first sequence + // then this object will simply record the matrices and return 0. + // if this the second or subsequent sequence then this object will compare + // the matrices with the first sequence, and report any differences. + // the matrix error will be returned. if `lower_tri' is 1 then only the + // lower triangle of the matrix (including the diagonal) will be compared + // (the matrix must be square). + + void end(); + // end a sequence. + + void reset(); + // restarts the object, so the next sequence will be the first sequence. + + void dump(); + // print out info about all the matrices in the sequence +}; + +struct dMatrixComparison::dMatInfo { + int n,m; // size of matrix + char name[128]; // name of the matrix + dReal *data; // matrix data + int size; // size of `data' +}; + + + +dMatrixComparison::dMatrixComparison() +{ + afterfirst = 0; + index = 0; +} + + +dMatrixComparison::~dMatrixComparison() +{ + reset(); +} + + +dReal dMatrixComparison::nextMatrix (dReal *A, int n, int m, int lower_tri, + const char *name, ...) +{ + if (A==0 || n < 1 || m < 1 || name==0) dDebug (0,"bad args to nextMatrix"); + int num = n*dPAD(m); + + if (afterfirst==0) { + dMatInfo *mi = (dMatInfo*) dAlloc (sizeof(dMatInfo)); + mi->n = n; + mi->m = m; + mi->size = num * sizeof(dReal); + mi->data = (dReal*) dAlloc (mi->size); + memcpy (mi->data,A,mi->size); + + va_list ap; + va_start (ap,name); + vsprintf (mi->name,name,ap); + va_end (ap); + if (strlen(mi->name) >= sizeof (mi->name)) dDebug (0,"name too long"); + + mat.push_back(mi); + return 0; + } + else { + if (lower_tri && n != m) + dDebug (0,"dMatrixComparison, lower triangular matrix must be square"); + if (index >= mat.size()) dDebug (0,"dMatrixComparison, too many matrices"); + dMatInfo *mp = mat[index]; + index++; + + dMatInfo mi; + va_list ap; + va_start (ap,name); + vsprintf (mi.name,name,ap); + va_end (ap); + if (strlen(mi.name) >= sizeof (mi.name)) dDebug (0,"name too long"); + + if (strcmp(mp->name,mi.name) != 0) + dDebug (0,"dMatrixComparison, name mismatch (\"%s\" and \"%s\")", + mp->name,mi.name); + if (mp->n != n || mp->m != m) + dDebug (0,"dMatrixComparison, size mismatch (%dx%d and %dx%d)", + mp->n,mp->m,n,m); + + dReal maxdiff; + if (lower_tri) { + maxdiff = dMaxDifferenceLowerTriangle (A,mp->data,n); + } + else { + maxdiff = dMaxDifference (A,mp->data,n,m); + } + if (maxdiff > tol) + dDebug (0,"dMatrixComparison, matrix error (size=%dx%d, name=\"%s\", " + "error=%.4e)",n,m,mi.name,maxdiff); + return maxdiff; + } +} + + +void dMatrixComparison::end() +{ + if (mat.size() <= 0) dDebug (0,"no matrices in sequence"); + afterfirst = 1; + index = 0; +} + + +void dMatrixComparison::reset() +{ + for (int i=0; idata,mat[i]->size); + dFree (mat[i],sizeof(dMatInfo)); + } + mat.clear(); + afterfirst = 0; + index = 0; +} + + +void dMatrixComparison::dump() +{ + for (int i=0; iname,mat[i]->n,mat[i]->m); +} + +//**************************************************************************** +// unit test + +#include + +// static jmp_buf jump_buffer; + +static void myDebug (int /*num*/, const char* /*msg*/, va_list /*ap*/) +{ + // printf ("(Error %d: ",num); + // vprintf (msg,ap); + // printf (")\n"); + longjmp (jump_buffer,1); +} + + +extern "C" void dTestMatrixComparison() +{ + volatile int i; + printf ("dTestMatrixComparison()\n"); + dMessageFunction *orig_debug = dGetDebugHandler(); + + dMatrixComparison mc; + dReal A[50*50]; + + // make first sequence + unsigned long seed = dRandGetSeed(); + for (i=1; i<49; i++) { + dMakeRandomMatrix (A,i,i+1,1.0); + mc.nextMatrix (A,i,i+1,0,"A%d",i); + } + mc.end(); + + //mc.dump(); + + // test identical sequence + dSetDebugHandler (&myDebug); + dRandSetSeed (seed); + if (setjmp (jump_buffer)) { + printf ("\tFAILED (1)\n"); + } + else { + for (i=1; i<49; i++) { + dMakeRandomMatrix (A,i,i+1,1.0); + mc.nextMatrix (A,i,i+1,0,"A%d",i); + } + mc.end(); + printf ("\tpassed (1)\n"); + } + dSetDebugHandler (orig_debug); + + // test broken sequences (with matrix error) + dRandSetSeed (seed); + volatile int passcount = 0; + for (i=1; i<49; i++) { + if (setjmp (jump_buffer)) { + passcount++; + } + else { + dSetDebugHandler (&myDebug); + dMakeRandomMatrix (A,i,i+1,1.0); + A[(i-1)*dPAD(i+1)+i] += REAL(0.01); + mc.nextMatrix (A,i,i+1,0,"A%d",i); + dSetDebugHandler (orig_debug); + } + } + mc.end(); + printf ("\t%s (2)\n",(passcount == 48) ? "passed" : "FAILED"); + + // test broken sequences (with name error) + dRandSetSeed (seed); + passcount = 0; + for (i=1; i<49; i++) { + if (setjmp (jump_buffer)) { + passcount++; + } + else { + dSetDebugHandler (&myDebug); + dMakeRandomMatrix (A,i,i+1,1.0); + mc.nextMatrix (A,i,i+1,0,"B%d",i); + dSetDebugHandler (orig_debug); + } + } + mc.end(); + printf ("\t%s (3)\n",(passcount == 48) ? "passed" : "FAILED"); + + // test identical sequence again + dSetDebugHandler (&myDebug); + dRandSetSeed (seed); + if (setjmp (jump_buffer)) { + printf ("\tFAILED (4)\n"); + } + else { + for (i=1; i<49; i++) { + dMakeRandomMatrix (A,i,i+1,1.0); + mc.nextMatrix (A,i,i+1,0,"A%d",i); + } + mc.end(); + printf ("\tpassed (4)\n"); + } + dSetDebugHandler (orig_debug); +} + +//**************************************************************************** + +// internal unit tests +extern "C" void dTestDataStructures(); +extern "C" void dTestMatrixComparison(); +extern "C" int dTestSolveLCP(); + + +int main() +{ + dInitODE(); + testRandomNumberGenerator(); + testInfinity(); + testPad(); + testCrossProduct(); + testSetZero(); + testNormalize3(); + //testReorthonormalize(); ... not any more + testPlaneSpace(); + testMatrixMultiply(); + testSmallMatrixMultiply(); + testCholeskyFactorization(); + testCholeskySolve(); + testInvertPDMatrix(); + testIsPositiveDefinite(); + testFastLDLTFactorization(); + testCoopLDLTFactorization(); + testSolveLDLT(); + testCoopSolveLDLT(); + testLDLTAddTL(); + testLDLTRemove(); + testMassFunctions(); + testRtoQandQtoR(); + testQuaternionMultiply(); + testRotationFunctions(); + dTestMatrixComparison(); + dTestSolveLCP(); + // dTestDataStructures(); + dCloseODE(); + return 0; +} diff --git a/libs/ode-0.16.1/ode/demo/demo_piston.cpp b/libs/ode-0.16.1/ode/demo/demo_piston.cpp new file mode 100644 index 0000000..8a0453a --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/demo_piston.cpp @@ -0,0 +1,813 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + * Created by: Remi Ricard * + * (remi.ricard@simlog.com or papaDoc@videotron.ca) * + * Creation date: 2007/05/04 * + *************************************************************************/ + +/* + This program demonstrates how the Piston joint works. + + A Piston joint enables the sliding of a body with respect to another body + and the 2 bodies are free to rotate about the sliding axis. + + - The yellow body is fixed to the world. + - The yellow body and the blue body are attached by a Piston joint with + the axis along the x direction. + - The purple object is a geometry obstacle. + - The red line is the representation of the prismatic axis + - The orange line is the representation of the rotoide axis + - The light blue ball is the anchor position + + N.B. Many command options are available type -h to print them. +*/ + +#include +#include +#include +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif +// select correct drawing functions +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawCylinder dsDrawCylinderD +#define dsDrawCapsule dsDrawCapsuleD +#define dsDrawSphere dsDrawSphereD +#endif + + +const dReal VEL_INC = 0.01; // Velocity increment + +// physics parameters +const dReal PI = 3.14159265358979323846264338327950288419716939937510; +const dReal BODY1_LENGTH = 1.5; // Size along the X axis + +const dReal RADIUS = 0.2; +const dReal AXIS_RADIUS = 0.01; + + +#define X 0 +#define Y 1 +#define Z 2 + +enum INDEX +{ + BODY1 = 0, + BODY2, + RECT, + BOX, + OBS, + GROUND, + NUM_PARTS, + ALL = NUM_PARTS +}; + +const int catBits[NUM_PARTS+1] = +{ + 0x0001, ///< Ext Cylinder category + 0x0002, ///< Int Cylinder category + 0x0004, ///< Int_Rect Cylinder category + 0x0008, ///< Box category + 0x0010, ///< Obstacle category + 0x0020, ///< Ground category + ~0L ///< All categories +}; + +#define Mass1 10 +#define Mass2 8 + + +//camera view +static float xyz[3] = {2.0f,-3.5f,2.0000f}; +static float hpr[3] = {90.000f,-25.5000f,0.0000f}; + + +//world,space,body & geom +static dWorldID world; +static dSpaceID space; +static dJointGroupID contactgroup; +static dBodyID body[NUM_PARTS]; +static dGeomID geom[NUM_PARTS]; + +// Default Positions and anchor of the 2 bodies +dVector3 pos1; +dVector3 pos2; +dVector3 anchor; + +static dJoint *joint; + + +const dReal BODY2_SIDES[3] = {0.4, 0.4, 0.4}; +const dReal OBS_SIDES[3] = {1,1,1}; +const dReal RECT_SIDES[3] = {0.3, 0.1, 0.2}; + + +int type = dJointTypePiston; + +//#pragma message("tc to be changed to 0") + +int tc = 0; // The test case choice; + + +//collision detection +static void nearCallback (void *, dGeomID o1, dGeomID o2) +{ + int i,n; + + dBodyID b1 = dGeomGetBody (o1); + dBodyID b2 = dGeomGetBody (o2); + if (b1 && b2 && dAreConnectedExcluding (b1,b2,dJointTypeContact) ) return; + const int N = 10; + dContact contact[N]; + n = dCollide (o1,o2,N,&contact[0].geom,sizeof (dContact) ); + if (n > 0) + { + for (i=0; iattach (body[BODY1], body[BODY2]); + if (joint->getType() == dJointTypePiston) + dJointSetPistonAnchor(joint->id(), anchor[X], anchor[Y], anchor[Z]); + } + +} + + +// function to update camera position at each step. +void update() +{ +// static FILE *file = fopen("x:/sim/src/libode/tstsrcSF/export.dat", "w"); + +// static int cnt = 0; +// char str[24]; +// sprintf(str, "%06d",cnt++); + +// dWorldExportDIF(world, file, str); +} + + +// called when a key pressed +static void command (int cmd) +{ + switch (cmd) + { + case 'h' : + case 'H' : + case '?' : + printKeyBoardShortCut(); + break; + + // Force + case 'q' : + case 'Q' : + dBodyAddForce (body[BODY1],4,0,0); + break; + case 'w' : + case 'W' : + dBodyAddForce (body[BODY1],-4,0,0); + break; + + case 'a' : + case 'A' : + dBodyAddForce (body[BODY1],0,40,0); + break; + case 's' : + case 'S' : + dBodyAddForce (body[BODY1],0,-40,0); + break; + + case 'z' : + case 'Z' : + dBodyAddForce (body[BODY1],0,0,4); + break; + case 'x' : + case 'X' : + dBodyAddForce (body[BODY1],0,0,-4); + break; + + // Torque + case 'e': + case 'E': + dBodyAddTorque (body[BODY1],0.1,0,0); + break; + case 'r': + case 'R': + dBodyAddTorque (body[BODY1],-0.1,0,0); + break; + + case 'd': + case 'D': + dBodyAddTorque (body[BODY1],0, 0.1,0); + break; + case 'f': + case 'F': + dBodyAddTorque (body[BODY1],0,-0.1,0); + break; + + case 'c': + case 'C': + dBodyAddTorque (body[BODY1],0.1,0,0); + break; + case 'v': + case 'V': + dBodyAddTorque (body[BODY1],-0.1,0,0); + break; + + case 't': + case 'T': + if (joint->getType() == dJointTypePiston) + dJointAddPistonForce (joint->id(),1); + else + dJointAddSliderForce (joint->id(),1); + break; + case 'y': + case 'Y': + if (joint->getType() == dJointTypePiston) + dJointAddPistonForce (joint->id(),-1); + else + dJointAddSliderForce (joint->id(),-1); + break; + + + case '8' : + dJointAttach(joint->id(), body[0], 0); + break; + case '9' : + dJointAttach(joint->id(), 0, body[0]); + break; + + case 'i': + case 'I' : + joint->setParam (dParamLoStop, 0); + joint->setParam (dParamHiStop, 0); + break; + + case 'o': + case 'O' : + joint->setParam (dParamLoStop2, 0); + joint->setParam (dParamHiStop2, 0); + break; + + case 'k': + case 'K': + joint->setParam (dParamLoStop2, -45.0*3.14159267/180.0); + joint->setParam (dParamHiStop2, 45.0*3.14159267/180.0); + break; + case 'l': + case 'L': + joint->setParam (dParamLoStop2, -dInfinity); + joint->setParam (dParamHiStop2, dInfinity); + break; + + // Velocity of joint + case ',': + case '<' : + { + dReal vel = joint->getParam (dParamVel) - VEL_INC; + joint->setParam (dParamVel, vel); + std::cout<<"Velocity = "<' : + { + dReal vel = joint->getParam (dParamVel) + VEL_INC; + joint->setParam (dParamVel, vel); + std::cout<<"Velocity = "<getType() ) + { + case dJointTypeSlider : + { + dSliderJoint *sj = reinterpret_cast (joint); + std::cout<<"Position ="<getPosition() <<"\n"; + } + break; + case dJointTypePiston : + { + dPistonJoint *rj = reinterpret_cast (joint); + std::cout<<"Position ="<getPosition() <<"\n"; + } + break; + default: + {} // keep the compiler happy + } + } + break; + + case '+' : + (++tc) %= 4; + setPositionBodies (tc); + break; + case '-' : + (--tc) %= 4; + setPositionBodies (tc); + break; + + + } +} + +static void drawBox (dGeomID id, int R, int G, int B) +{ + if (!id) + return; + + const dReal *pos = dGeomGetPosition (id); + const dReal *rot = dGeomGetRotation (id); + dsSetColor (R,G,B); + + dVector3 l; + dGeomBoxGetLengths (id, l); + dsDrawBox (pos, rot, l); +} + + +// simulation loop +static void simLoop (int pause) +{ + const dReal *rot; + dVector3 ax; + dReal l=0; + + switch (joint->getType() ) + { + case dJointTypeSlider : + ( (dSliderJoint *) joint)->getAxis (ax); + l = ( (dSliderJoint *) joint)->getPosition(); + break; + case dJointTypePiston : + ( (dPistonJoint *) joint)->getAxis (ax); + l = ( (dPistonJoint *) joint)->getPosition(); + break; + default: + {} // keep the compiler happy + } + + + if (!pause) + { + double simstep = 0.01; // 1ms simulation steps + double dt = dsElapsedTime(); + + int nrofsteps = (int) ceilf (dt/simstep); + if (!nrofsteps) + nrofsteps = 1; + + for (int i=0; igetType() == dJointTypePiston ) + { + dVector3 anchor; + dJointGetPistonAnchor(joint->id(), anchor); + + // Draw the rotoide axis + rot = dGeomGetRotation (geom[BODY2]); + dsSetColor (1,0.5,0); + dsDrawCylinder (anchor, rot, 4, AXIS_RADIUS); + + + dsSetColor (0,1,1); + rot = dGeomGetRotation (geom[BODY1]); + dsDrawSphere (anchor, rot, 1.5*RADIUS); + } + + } +} + + +void Help (char **argv) +{ + printf ("%s ", argv[0]); + printf (" -h | --help : print this help\n"); + printf (" -s | --slider : Set the joint as a slider\n"); + printf (" -p | --piston : Set the joint as a Piston. (Default joint)\n"); + printf (" -1 | --offset1 : Create an offset between the 2 bodies\n"); + printf (" Offset one of the body by z=-0.5 and keep the anchor\n"); + printf (" point in the middle of the fixed body\n"); + printf (" -2 | --offset2 : Create an offset between the 2 bodies\n"); + printf (" Offset one of the body by z=-0.5 and set the anchor\n"); + printf (" point in the middle of the movable body\n"); + printf (" -3 | --offset3 : Create an offset between the 2 bodies\n"); + printf (" Offset one of the body by z=-0.5 and set the anchor\n"); + printf (" point in the middle of the 2 bodies\n"); + printf (" -t | --texture-path path : Path to the texture.\n"); + printf (" Default = %s\n", DRAWSTUFF_TEXTURE_PATH); + printf (" -n | --notFixed : In free space with no gravity mode"); + printf ("-notex : Don't use texture\n"); + printf ("-noshadow : No shadow\n"); + printf ("-noshadows : No shadows\n"); + printf ("-pause : Initial pause\n"); + printf ("--------------------------------------------------\n"); + printf ("Hit any key to continue:"); + getchar(); + + exit (0); +} + +int main (int argc, char **argv) +{ + dInitODE2(0); + bool fixed = true; + + // setup pointers to drawstuff callback functions + dsFunctions fn; + fn.version = DS_VERSION; + fn.start = &start; + fn.step = &simLoop; + fn.command = &command; + fn.stop = 0; + fn.path_to_textures = DRAWSTUFF_TEXTURE_PATH; + + dVector3 offset; + dSetZero (offset, 4); + + // Default test case + + if (argc >= 2 ) + { + for (int i=1; i < argc; ++i) + { + //static int tata = 0; + + if (1) + { + if ( 0 == strcmp ("-h", argv[i]) || 0 == strcmp ("--help", argv[i]) ) + Help (argv); + + if ( 0 == strcmp ("-s", argv[i]) || 0 == strcmp ("--slider", argv[i]) ) + type = dJointTypeSlider; + + if ( 0 == strcmp ("-t", argv[i]) || 0 == strcmp ("--texture-path", argv[i]) ) + { + int j = i+1; + if ( j >= argc || // Check if we have enough arguments + argv[j][0] == '\0' || // We should have a path here + argv[j][0] == '-' ) // We should have a path not a command line + Help (argv); + else + fn.path_to_textures = argv[++i]; // Increase i since we use this argument + } + } + + + if ( 0 == strcmp ("-1", argv[i]) || 0 == strcmp ("--offset1", argv[i]) ) + tc = 1; + + if ( 0 == strcmp ("-2", argv[i]) || 0 == strcmp ("--offset2", argv[i]) ) + tc = 2; + + if ( 0 == strcmp ("-3", argv[i]) || 0 == strcmp ("--offset3", argv[i]) ) + tc = 3; + + if (0 == strcmp ("-n", argv[i]) || 0 == strcmp ("--notFixed", argv[i]) ) + fixed = false; + } + } + + world = dWorldCreate(); + dWorldSetERP (world, 0.8); + + space = dSimpleSpaceCreate (0); + contactgroup = dJointGroupCreate (0); + geom[GROUND] = dCreatePlane (space, 0,0,1,0); + dGeomSetCategoryBits (geom[GROUND], catBits[GROUND]); + dGeomSetCollideBits (geom[GROUND], catBits[ALL]); + + dMass m; + dMatrix3 R; + + + // Create the Obstacle + geom[OBS] = dCreateBox (space, OBS_SIDES[0], OBS_SIDES[1], OBS_SIDES[2]); + dGeomSetCategoryBits (geom[OBS], catBits[OBS]); + dGeomSetCollideBits (geom[OBS], catBits[ALL]); + //Rotation of 45deg around y + dRFromAxisAndAngle (R, 1,1,0, -0.25*PI); + dGeomSetRotation (geom[OBS], R); + dGeomSetPosition (geom[OBS], 1.95, -0.2, 0.5); + + + //Rotation of 90deg around y + // Will orient the Z axis along X + dRFromAxisAndAngle (R, 0,1,0, -0.5*PI); + + + // Create Body2 (Wiil be attached to the world) + body[BODY2] = dBodyCreate (world); + // Main axis of cylinder is along X=1 + dMassSetBox (&m, 1, BODY2_SIDES[0], BODY2_SIDES[1], BODY2_SIDES[2]); + dMassAdjust (&m, Mass1); + geom[BODY2] = dCreateBox (space, BODY2_SIDES[0], BODY2_SIDES[1], BODY2_SIDES[2]); + dGeomSetBody (geom[BODY2], body[BODY2]); + dGeomSetOffsetRotation (geom[BODY2], R); + dGeomSetCategoryBits (geom[BODY2], catBits[BODY2]); + dGeomSetCollideBits (geom[BODY2], catBits[ALL] & (~catBits[BODY1]) ); + dBodySetMass (body[BODY2], &m); + + + // Create Body 1 (Slider on the prismatic axis) + body[BODY1] = dBodyCreate (world); + // Main axis of capsule is along X=1 + dMassSetCapsule (&m, 1, 1, RADIUS, BODY1_LENGTH); + dMassAdjust (&m, Mass1); + geom[BODY1] = dCreateCapsule (space, RADIUS, BODY1_LENGTH); + dGeomSetBody (geom[BODY1], body[BODY1]); + dGeomSetOffsetRotation (geom[BODY1], R); + dGeomSetCategoryBits (geom[BODY1], catBits[BODY1]); + dGeomSetCollideBits (geom[BODY1], catBits[ALL] & ~catBits[BODY2] & ~catBits[RECT]); + + dMass mRect; + dMassSetBox (&mRect, 1, RECT_SIDES[0], RECT_SIDES[1], RECT_SIDES[2]); + dMassAdd (&m, &mRect); + // TODO: translate m? + geom[RECT] = dCreateBox (space, RECT_SIDES[0], RECT_SIDES[1], RECT_SIDES[2]); + dGeomSetBody (geom[RECT], body[BODY1]); + dGeomSetOffsetPosition (geom[RECT], + (BODY1_LENGTH-RECT_SIDES[0]) /2.0, + 0.0, + -RADIUS -RECT_SIDES[2]/2.0); + dGeomSetCategoryBits (geom[RECT], catBits[RECT]); + dGeomSetCollideBits (geom[RECT], catBits[ALL] & (~catBits[BODY1]) ); + + dBodySetMass (body[BODY1], &m); + + + + setPositionBodies (tc); + + + if ( fixed ) + { + // Attache external cylinder to the world + dJointID fixed = dJointCreateFixed (world,0); + dJointAttach (fixed , NULL, body[BODY2]); + dJointSetFixed (fixed ); + dWorldSetGravity (world,0,0,-0.8); + } + else + { + dWorldSetGravity (world,0,0,0); + } + + + + + // The static is here only to help debugging + switch (type) + { + case dJointTypeSlider : + { + dSliderJoint *sj = new dSliderJoint (world, 0); + sj->attach (body[BODY1], body[BODY2]); + sj->setAxis (1, 0, 0); + joint = sj; + } + break; + + case dJointTypePiston : // fall through default + default: + { + dPistonJoint *pj = new dPistonJoint (world, 0); + pj->attach (body[BODY1], body[BODY2]); + pj->setAxis (1, 0, 0); + + dJointSetPistonAnchor(pj->id(), anchor[X], anchor[Y], anchor[Z]); + + joint = pj; + } + break; + }; + + + // run simulation + dsSimulationLoop (argc,argv,400,300,&fn); + + delete joint; + dJointGroupDestroy (contactgroup); + dSpaceDestroy (space); + dWorldDestroy (world); + dCloseODE(); + return 0; +} + + + + diff --git a/libs/ode-0.16.1/ode/demo/demo_plane2d.cpp b/libs/ode-0.16.1/ode/demo/demo_plane2d.cpp new file mode 100644 index 0000000..559f9ae --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/demo_plane2d.cpp @@ -0,0 +1,304 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +// Test my Plane2D constraint. +// Uses ode-0.35 collision API. + +# include +# include +# include +# include +# include +#include "texturepath.h" + + +# define drand48() ((double) (((double) rand()) / ((double) RAND_MAX))) + +# define N_BODIES 40 +# define STAGE_SIZE 8.0 // in m + +# define TIME_STEP 0.01 +# define K_SPRING 10.0 +# define K_DAMP 10.0 + +//using namespace ode; + +struct GlobalVars +{ + dWorld dyn_world; + dBody dyn_bodies[N_BODIES]; + dReal bodies_sides[N_BODIES][3]; + + dSpaceID coll_space_id; + dJointID plane2d_joint_ids[N_BODIES]; + dJointGroup coll_contacts; +}; + +static GlobalVars *g_globals_ptr = NULL; + + + +static void cb_start () +/*************************/ +{ + dAllocateODEDataForThread(dAllocateMaskAll); + + static float xyz[3] = { 0.5f*STAGE_SIZE, 0.5f*STAGE_SIZE, 0.65f*STAGE_SIZE}; + static float hpr[3] = { 90.0f, -90.0f, 0 }; + + dsSetViewpoint (xyz, hpr); +} + + + +static void cb_near_collision (void *, dGeomID o1, dGeomID o2) +/********************************************************************/ +{ + dBodyID b1 = dGeomGetBody (o1); + dBodyID b2 = dGeomGetBody (o2); + dContact contact; + + + // exit without doing anything if the two bodies are static + if (b1 == 0 && b2 == 0) + return; + + // exit without doing anything if the two bodies are connected by a joint + if (b1 && b2 && dAreConnected (b1, b2)) + { + /* MTRAP; */ + return; + } + + contact.surface.mode = 0; + contact.surface.mu = 0; // frictionless + + if (dCollide (o1, o2, 1, &contact.geom, sizeof (dContactGeom))) + { + dJointID c = dJointCreateContact (g_globals_ptr->dyn_world.id(), + g_globals_ptr->coll_contacts.id (), &contact); + dJointAttach (c, b1, b2); + } +} + + +static void track_to_pos (dBody &body, dJointID joint_id, + dReal target_x, dReal target_y) +/************************************************************************/ +{ + dReal curr_x = body.getPosition()[0]; + dReal curr_y = body.getPosition()[1]; + + dJointSetPlane2DXParam (joint_id, dParamVel, 1 * (target_x - curr_x)); + dJointSetPlane2DYParam (joint_id, dParamVel, 1 * (target_y - curr_y)); +} + + + +static void cb_sim_step (int pause) +/*************************************/ +{ + if (! pause) + { + static dReal angle = 0; + + angle += REAL( 0.01 ); + + track_to_pos (g_globals_ptr->dyn_bodies[0], g_globals_ptr->plane2d_joint_ids[0], + dReal( STAGE_SIZE/2 + STAGE_SIZE/2.0 * cos (angle) ), + dReal( STAGE_SIZE/2 + STAGE_SIZE/2.0 * sin (angle) )); + + /* double f0 = 0.001; */ + /* for (int b = 0; b < N_BODIES; b ++) */ + /* { */ + /* double p = 1 + b / (double) N_BODIES; */ + /* double q = 2 - b / (double) N_BODIES; */ + /* g_globals_ptr->dyn_bodies[b].addForce (f0 * cos (p*angle), f0 * sin (q*angle), 0); */ + /* } */ + /* g_globals_ptr->dyn_bodies[0].addTorque (0, 0, 0.1); */ + + const int n = 10; + for (int i = 0; i < n; i ++) + { + dSpaceCollide (g_globals_ptr->coll_space_id, 0, &cb_near_collision); + g_globals_ptr->dyn_world.step (dReal(TIME_STEP/n)); + g_globals_ptr->coll_contacts.empty (); + } + } + +# if 1 /* [ */ + { + // @@@ hack Plane2D constraint error reduction here: + for (int b = 0; b < N_BODIES; b ++) + { + const dReal *rot = dBodyGetAngularVel (g_globals_ptr->dyn_bodies[b].id()); + const dReal *quat_ptr; + dReal quat[4], + quat_len; + + + quat_ptr = dBodyGetQuaternion (g_globals_ptr->dyn_bodies[b].id()); + quat[0] = quat_ptr[0]; + quat[1] = 0; + quat[2] = 0; + quat[3] = quat_ptr[3]; + quat_len = sqrt (quat[0] * quat[0] + quat[3] * quat[3]); + quat[0] /= quat_len; + quat[3] /= quat_len; + dBodySetQuaternion (g_globals_ptr->dyn_bodies[b].id(), quat); + dBodySetAngularVel (g_globals_ptr->dyn_bodies[b].id(), 0, 0, rot[2]); + } + } +# endif /* ] */ + + +# if 0 /* [ */ + { + // @@@ friction + for (int b = 0; b < N_BODIES; b ++) + { + const dReal *vel = dBodyGetLinearVel (g_globals_ptr->dyn_bodies[b].id()), + *rot = dBodyGetAngularVel (g_globals_ptr->dyn_bodies[b].id()); + dReal s = 1.00; + dReal t = 0.99; + + dBodySetLinearVel (g_globals_ptr->dyn_bodies[b].id(), s*vel[0],s*vel[1],s*vel[2]); + dBodySetAngularVel (g_globals_ptr->dyn_bodies[b].id(),t*rot[0],t*rot[1],t*rot[2]); + } + } +# endif /* ] */ + + + { + // ode drawstuff + + dsSetTexture (DS_WOOD); + for (int b = 0; b < N_BODIES; b ++) + { + if (b == 0) + dsSetColor (1.0, 0.5, 1.0); + else + dsSetColor (0, 0.5, 1.0); +#ifdef dDOUBLE + dsDrawBoxD (g_globals_ptr->dyn_bodies[b].getPosition(), g_globals_ptr->dyn_bodies[b].getRotation(), g_globals_ptr->bodies_sides[b]); +#else + dsDrawBox (g_globals_ptr->dyn_bodies[b].getPosition(), g_globals_ptr->dyn_bodies[b].getRotation(), g_globals_ptr->bodies_sides[b]); +#endif + } + } +} + + + +extern int main +/******************/ +( + int argc, + char **argv +) +{ + int b; + dsFunctions drawstuff_functions; + + + dInitODE2(0); + + g_globals_ptr = new GlobalVars(); + + // dynamic world + + dReal cf_mixing;// = 1 / TIME_STEP * K_SPRING + K_DAMP; + dReal err_reduct;// = TIME_STEP * K_SPRING * cf_mixing; + err_reduct = REAL( 0.5 ); + cf_mixing = REAL( 0.001 ); + dWorldSetERP (g_globals_ptr->dyn_world.id (), err_reduct); + dWorldSetCFM (g_globals_ptr->dyn_world.id (), cf_mixing); + g_globals_ptr->dyn_world.setGravity (0, 0.0, -1.0); + + g_globals_ptr->coll_space_id = dSimpleSpaceCreate (0); + + // dynamic bodies + for (b = 0; b < N_BODIES; b ++) + { + int l = (int) (1 + sqrt ((double) N_BODIES)); + dReal x = dReal( (0.5 + (b / l)) / l * STAGE_SIZE ); + dReal y = dReal( (0.5 + (b % l)) / l * STAGE_SIZE ); + dReal z = REAL( 1.0 ) + REAL( 0.1 ) * (dReal)drand48(); + + g_globals_ptr->bodies_sides[b][0] = dReal( 5 * (0.2 + 0.7*drand48()) / sqrt((double)N_BODIES) ); + g_globals_ptr->bodies_sides[b][1] = dReal( 5 * (0.2 + 0.7*drand48()) / sqrt((double)N_BODIES) ); + g_globals_ptr->bodies_sides[b][2] = z; + + g_globals_ptr->dyn_bodies[b].create (g_globals_ptr->dyn_world); + g_globals_ptr->dyn_bodies[b].setPosition (x, y, z/2); + g_globals_ptr->dyn_bodies[b].setData ((void*) (dsizeint)b); + dBodySetLinearVel (g_globals_ptr->dyn_bodies[b].id (), + dReal( 3 * (drand48 () - 0.5) ), + dReal( 3 * (drand48 () - 0.5) ), 0); + + dMass m; + m.setBox (1, g_globals_ptr->bodies_sides[b][0],g_globals_ptr->bodies_sides[b][1],g_globals_ptr->bodies_sides[b][2]); + m.adjust (REAL(0.1) * g_globals_ptr->bodies_sides[b][0] * g_globals_ptr->bodies_sides[b][1]); + g_globals_ptr->dyn_bodies[b].setMass (&m); + + g_globals_ptr->plane2d_joint_ids[b] = dJointCreatePlane2D (g_globals_ptr->dyn_world.id (), 0); + dJointAttach (g_globals_ptr->plane2d_joint_ids[b], g_globals_ptr->dyn_bodies[b].id (), 0); + } + + dJointSetPlane2DXParam (g_globals_ptr->plane2d_joint_ids[0], dParamFMax, 10); + dJointSetPlane2DYParam (g_globals_ptr->plane2d_joint_ids[0], dParamFMax, 10); + + + // collision geoms and joints + dCreatePlane (g_globals_ptr->coll_space_id, 1, 0, 0, 0); + dCreatePlane (g_globals_ptr->coll_space_id, -1, 0, 0, -STAGE_SIZE); + dCreatePlane (g_globals_ptr->coll_space_id, 0, 1, 0, 0); + dCreatePlane (g_globals_ptr->coll_space_id, 0, -1, 0, -STAGE_SIZE); + + for (b = 0; b < N_BODIES; b ++) + { + dGeomID coll_box_id; + coll_box_id = dCreateBox (g_globals_ptr->coll_space_id, + g_globals_ptr->bodies_sides[b][0], g_globals_ptr->bodies_sides[b][1], g_globals_ptr->bodies_sides[b][2]); + dGeomSetBody (coll_box_id, g_globals_ptr->dyn_bodies[b].id ()); + } + + g_globals_ptr->coll_contacts.create (); + + { + // simulation loop (by drawstuff lib) + drawstuff_functions.version = DS_VERSION; + drawstuff_functions.start = &cb_start; + drawstuff_functions.step = &cb_sim_step; + drawstuff_functions.command = 0; + drawstuff_functions.stop = 0; + drawstuff_functions.path_to_textures = DRAWSTUFF_TEXTURE_PATH; + + dsSimulationLoop (argc, argv, 352,288,&drawstuff_functions); + } + + delete g_globals_ptr; + g_globals_ptr = NULL; + + dCloseODE(); + return 0; +} diff --git a/libs/ode-0.16.1/ode/demo/demo_rfriction.cpp b/libs/ode-0.16.1/ode/demo/demo_rfriction.cpp new file mode 100644 index 0000000..61d1115 --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/demo_rfriction.cpp @@ -0,0 +1,258 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +/* +Angular friction demo: + +A bunch of ramps of different pitch. +A bunch of spheres with rolling friction. +*/ + + +#include +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +// select correct drawing functions +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawSphere dsDrawSphereD +#define dsDrawCylinder dsDrawCylinderD +#define dsDrawCapsule dsDrawCapsuleD +#endif + + +// some constants +#define GRAVITY 10 // the global gravity to use +#define RAMP_COUNT 8 + +static const dReal rampX = 6.0f; +static const dReal rampY = 0.5f; +static const dReal rampZ = 0.25f; +static const dReal sphereRadius = 0.25f; +static const dReal maxRamp = M_PI/4.0f; // Needs to be less than pi/2 +static const dReal rampInc = maxRamp/RAMP_COUNT; + +// dynamics and collision objects +static dWorldID world = 0; +static dSpaceID space = 0; +static dJointGroupID contactgroup = 0; +static dGeomID ground; + +static dReal mu = REAL(0.37); // the global mu to use +static dReal rho = REAL(0.1); // the global rho to use +static dReal omega = REAL(25.0); + +static dGeomID rampGeom[RAMP_COUNT]; +static dBodyID sphereBody[RAMP_COUNT]; +static dGeomID sphereGeom[RAMP_COUNT]; + + +// this is called by dSpaceCollide when two objects in space are +// potentially colliding. + +static void nearCallback (void *, dGeomID o1, dGeomID o2) +{ + int i; + + dBodyID b1 = dGeomGetBody(o1); + dBodyID b2 = dGeomGetBody(o2); + + if (b1==0 && b2==0) return; + + dContact contact[3]; + for (int ii=0; ii<3; ii++) { + contact[ii].surface.mode = dContactApprox1 | dContactRolling; + contact[ii].surface.mu = mu; + contact[ii].surface.rho = rho; + } + if (int numc = dCollide (o1,o2,3,&contact[0].geom,sizeof(dContact))) { + for (i=0; i1) rho=1; + break; + case 'n': case 'N': + mu-=0.02; + if (mu<0) mu=0; + break; + case 'm': case 'M': + mu+=0.02; + if (mu>1) mu=1; + break; + case 'r': case 'R': + reset(); + break; + case ']': + omega+=1; + break; + case '[': + omega-=1; + break; + } +} + +// simulation loop + +static void simLoop (int pause) +{ + if (!pause) { + dSpaceCollide (space,0,&nearCallback); + dWorldStep (world,0.017); // 60 fps + // remove all contact joints + dJointGroupEmpty (contactgroup); + } + + // Render ramps and spheres + dsSetTexture (DS_WOOD); + for (int ii=0;ii +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +// select correct drawing functions +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#endif + + +// some constants +#define SIDE (0.5f) // side length of a box +#define MASS (1.0) // mass of a box + + +// dynamics and collision objects +static dWorldID world; +static dBodyID body[2]; +static dJointID slider; + + +// state set by keyboard commands +static int occasional_error = 0; + + +// start simulation - set viewpoint + +static void start() +{ + dAllocateODEDataForThread(dAllocateMaskAll); + + static float xyz[3] = {1.0382f,-1.0811f,1.4700f}; + static float hpr[3] = {135.0000f,-19.5000f,0.0000f}; + dsSetViewpoint (xyz,hpr); + printf ("Press 'e' to start/stop occasional error.\n"); +} + + +// called when a key pressed + +static void command (int cmd) +{ + if (cmd == 'e' || cmd == 'E') { + occasional_error ^= 1; + } +} + + +// simulation loop + +static void simLoop (int pause) +{ + const dReal kd = -0.3; // angular damping constant + const dReal ks = 0.5; // spring constant + if (!pause) { + // add an oscillating torque to body 0, and also damp its rotational motion + static dReal a=0; + const dReal *w = dBodyGetAngularVel (body[0]); + dBodyAddTorque (body[0],kd*w[0],kd*w[1]+0.1*cos(a),kd*w[2]+0.1*sin(a)); + a += 0.01; + + // add a spring force to keep the bodies together, otherwise they will + // fly apart along the slider axis. + const dReal *p1 = dBodyGetPosition (body[0]); + const dReal *p2 = dBodyGetPosition (body[1]); + dBodyAddForce (body[0],ks*(p2[0]-p1[0]),ks*(p2[1]-p1[1]), + ks*(p2[2]-p1[2])); + dBodyAddForce (body[1],ks*(p1[0]-p2[0]),ks*(p1[1]-p2[1]), + ks*(p1[2]-p2[2])); + + // occasionally re-orient one of the bodies to create a deliberate error. + if (occasional_error) { + static int count = 0; + if ((count % 20)==0) { + // randomly adjust orientation of body[0] + const dReal *R1; + dMatrix3 R2,R3; + R1 = dBodyGetRotation (body[0]); + dRFromAxisAndAngle (R2,dRandReal()-0.5,dRandReal()-0.5, + dRandReal()-0.5,dRandReal()-0.5); + dMultiply0 (R3,R1,R2,3,3,3); + dBodySetRotation (body[0],R3); + + // randomly adjust position of body[0] + const dReal *pos = dBodyGetPosition (body[0]); + dBodySetPosition (body[0], + pos[0]+0.2*(dRandReal()-0.5), + pos[1]+0.2*(dRandReal()-0.5), + pos[2]+0.2*(dRandReal()-0.5)); + } + count++; + } + + dWorldStep (world,0.05); + } + + dReal sides1[3] = {SIDE,SIDE,SIDE}; + dReal sides2[3] = {SIDE*0.8f,SIDE*0.8f,SIDE*2.0f}; + dsSetTexture (DS_WOOD); + dsSetColor (1,1,0); + dsDrawBox (dBodyGetPosition(body[0]),dBodyGetRotation(body[0]),sides1); + dsSetColor (0,1,1); + dsDrawBox (dBodyGetPosition(body[1]),dBodyGetRotation(body[1]),sides2); +} + + +int main (int argc, char **argv) +{ + // setup pointers to drawstuff callback functions + dsFunctions fn; + fn.version = DS_VERSION; + fn.start = &start; + fn.step = &simLoop; + fn.command = &command; + fn.stop = 0; + fn.path_to_textures = DRAWSTUFF_TEXTURE_PATH; + + // create world + dInitODE2(0); + world = dWorldCreate(); + dMass m; + dMassSetBox (&m,1,SIDE,SIDE,SIDE); + dMassAdjust (&m,MASS); + + body[0] = dBodyCreate (world); + dBodySetMass (body[0],&m); + dBodySetPosition (body[0],0,0,1); + body[1] = dBodyCreate (world); + dBodySetMass (body[1],&m); + dQuaternion q; + dQFromAxisAndAngle (q,-1,1,0,0.25*M_PI); + dBodySetPosition (body[1],0.2,0.2,1.2); + dBodySetQuaternion (body[1],q); + + slider = dJointCreateSlider (world,0); + dJointAttach (slider,body[0],body[1]); + dJointSetSliderAxis (slider,1,1,1); + + // run simulation + dsSimulationLoop (argc,argv,352,288,&fn); + + dWorldDestroy (world); + dCloseODE(); + return 0; +} diff --git a/libs/ode-0.16.1/ode/demo/demo_space.cpp b/libs/ode-0.16.1/ode/demo/demo_space.cpp new file mode 100644 index 0000000..6f871f6 --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/demo_space.cpp @@ -0,0 +1,232 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001-2003 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +/* + +testing procedure: + * create a bunch of random boxes + * test for intersections directly, put results in n^2 array + * get space to report collisions: + - all correct collisions reported + - no pair reported more than once + - no incorrect collisions reported + +*/ + + +#include +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +// select correct drawing functions + +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawSphere dsDrawSphereD +#define dsDrawCylinder dsDrawCylinderD +#define dsDrawCapsule dsDrawCapsuleD +#endif + + +// some constants + +#define NUM 20 // number of boxes to test + + +// collision objects and globals + +static dSpaceID space; +static dGeomID geom[NUM]; +static dReal bounds[NUM][6]; +static dsizeint good_matrix[NUM][NUM]; // correct collision matrix +static dsizeint test_matrix[NUM][NUM]; // testing collision matrix +static dsizeint hits[NUM]; // number of collisions a box has +static unsigned long seed=37; + + +static void init_test() +{ + int i,j; + const dReal scale = 0.5; + + // set random boxes + dRandSetSeed (seed); + for (i=0; i < NUM; i++) { + bounds[i][0] = dRandReal()*2-1; + bounds[i][1] = bounds[i][0] + dRandReal()*scale; + bounds[i][2] = dRandReal()*2-1; + bounds[i][3] = bounds[i][2] + dRandReal()*scale; + bounds[i][4] = dRandReal()*2; + bounds[i][5] = bounds[i][4] + dRandReal()*scale; + + if (geom[i]) dGeomDestroy (geom[i]); + geom[i] = dCreateBox (space, + bounds[i][1] - bounds[i][0], + bounds[i][3] - bounds[i][2], + bounds[i][5] - bounds[i][4]); + dGeomSetPosition (geom[i], + (bounds[i][0] + bounds[i][1])*0.5, + (bounds[i][2] + bounds[i][3])*0.5, + (bounds[i][4] + bounds[i][5])*0.5); + dGeomSetData (geom[i],(void*)(dsizeint)(i)); + } + + // compute all intersections and put the results in "good_matrix" + for (i=0; i < NUM; i++) { + for (j=0; j < NUM; j++) good_matrix[i][j] = 0; + } + for (i=0; i < NUM; i++) hits[i] = 0; + + for (i=0; i < NUM; i++) { + for (j=i+1; j < NUM; j++) { + dReal *bounds1 = &bounds[i][0]; + dReal *bounds2 = &bounds[j][0]; + if (bounds1[0] > bounds2[1] || + bounds1[1] < bounds2[0] || + bounds1[2] > bounds2[3] || + bounds1[3] < bounds2[2] || + bounds1[4] > bounds2[5] || + bounds1[5] < bounds2[4]) continue; + good_matrix[i][j] = 1; + good_matrix[j][i] = 1; + hits[i]++; + hits[j]++; + } + } +} + + +// this is called by dSpaceCollide when two objects in space are +// potentially colliding. + +static void nearCallback (void *, dGeomID o1, dGeomID o2) +{ + dsizeint i,j; + i = (dsizeint) dGeomGetData (o1); + j = (dsizeint) dGeomGetData (o2); + if (i==j) + printf ("collision (%d,%d) is between the same object\n",(int)i,(int)j); + if (!good_matrix[i][j] || !good_matrix[j][i]) + printf ("collision (%d,%d) is incorrect\n",(int)i,(int)j); + if (test_matrix[i][j] || test_matrix[j][i]) + printf ("collision (%d,%d) reported more than once\n",(int)i,(int)j); + test_matrix[i][j] = 1; + test_matrix[j][i] = 1; +} + + +// start simulation - set viewpoint + +static void start() +{ + dAllocateODEDataForThread(dAllocateMaskAll); + + static float xyz[3] = {2.1640f,-1.3079f,1.7600f}; + static float hpr[3] = {125.5000f,-17.0000f,0.0000f}; + dsSetViewpoint (xyz,hpr); +} + + +static void command (int cmd) +{ + if (cmd == ' ') { + seed++; + init_test(); + } +} + + +// simulation loop + +static void simLoop (int) +{ + int i,j; + + for (i=0; i < NUM; i++) { + for (j=0; j < NUM; j++) test_matrix[i][j] = 0; + } + dSpaceCollide (space,0,&nearCallback); + for (i=0; i < NUM; i++) { + for (j=i+1; j < NUM; j++) { + if (good_matrix[i][j] && !test_matrix[i][j]) { + printf ("failed to report collision (%d,%d) (seed=%ld)\n",i,j,seed); + } + } + } + + seed++; + init_test(); + + for (i=0; i 0) dsSetColor (1,0,0); + else dsSetColor (1,1,0); + dsDrawBox (pos,R,side); + } +} + + +int main (int argc, char **argv) +{ + int i; + + // setup pointers to drawstuff callback functions + dsFunctions fn; + fn.version = DS_VERSION; + fn.start = &start; + fn.step = &simLoop; + fn.command = &command; + fn.stop = 0; + fn.path_to_textures = DRAWSTUFF_TEXTURE_PATH; + + dInitODE2(0); + + // test the simple space: + // space = dSimpleSpaceCreate(); + + // test the hash space: + // space = dHashSpaceCreate (0); + // dHashSpaceSetLevels (space,-10,10); + + // test the quadtree space + dVector3 Center = {0, 0, 0, 0}; + dVector3 Extents = {10, 0, 10, 0}; + space = dQuadTreeSpaceCreate(0, Center, Extents, 7); + + for (i=0; i < NUM; i++) geom[i] = 0; + init_test(); + + // run simulation + dsSimulationLoop (argc,argv,352,288,&fn); + + dSpaceDestroy (space); + dCloseODE(); + return 0; +} diff --git a/libs/ode-0.16.1/ode/demo/demo_space_stress.cpp b/libs/ode-0.16.1/ode/demo/demo_space_stress.cpp new file mode 100644 index 0000000..dcbd9d7 --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/demo_space_stress.cpp @@ -0,0 +1,449 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001-2003 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#include + +#include +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +// select correct drawing functions + +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawSphere dsDrawSphereD +#define dsDrawCylinder dsDrawCylinderD +#define dsDrawCapsule dsDrawCapsuleD +#endif + + +// some constants + +#define NUM 10000 // max number of objects +#define DENSITY (5.0) // density of all objects +#define GPB 3 // maximum number of geometries per body +#define MAX_CONTACTS 4 // maximum number of contact points per body +#define WORLD_SIZE 20 +#define WORLD_HEIGHT 20 + + +// dynamics and collision objects + +struct MyObject { + dBodyID body; // the body + dGeomID geom[GPB]; // geometries representing this body +}; + +static int num=0; // number of objects in simulation +static int nextobj=0; // next object to recycle if num==NUM +static dWorldID world; +static dSpaceID space = NULL; +static MyObject obj[NUM]; +static dJointGroupID contactgroup; +static int selected = -1; // selected object +static int show_aabb = 0; // show geom AABBs? +static int show_contacts = 0; // show contact points? +static int random_pos = 1; // drop objects from random position? +static int draw_geom = 1; + + +// this is called by dSpaceCollide when two objects in space are +// potentially colliding. + +static void nearCallback (void *, dGeomID o1, dGeomID o2) +{ + int i; + // if (o1->body && o2->body) return; + + // exit without doing anything if the two bodies are connected by a joint + dBodyID b1 = dGeomGetBody(o1); + dBodyID b2 = dGeomGetBody(o2); + if (b1 && b2 && dAreConnectedExcluding (b1,b2,dJointTypeContact)) return; + + dContact contact[MAX_CONTACTS]; // up to MAX_CONTACTS contacts per box-box + for (i=0; i= 'A' && c <= 'Z') return c - ('a'-'A'); + else return c; +} + + +// called when a key pressed + +static void command (int cmd) +{ + int i,j,k; + dReal sides[3]; + dMass m; + bool setBody = false; + + cmd = locase(cmd); + if (cmd == 'b' || cmd == 's' || cmd == 'c' || cmd == 'x' || cmd == 'y') { + if (num < NUM) { + // new object to be created + i = num; + num++; + } else { + // recycle existing object + i = nextobj++; + nextobj %= num; // wrap-around if needed + + // destroy the body and geoms for slot i + dBodyDestroy (obj[i].body); + obj[i].body = 0; + + for (k=0; k < GPB; k++) + if (obj[i].geom[k]) { + dGeomDestroy(obj[i].geom[k]); + obj[i].geom[k] = 0; + } + } + + obj[i].body = dBodyCreate(world); + + for (k=0; k<3; k++) + sides[k] = dRandReal()*0.5+0.1; + + dMatrix3 R; + if (random_pos) { + dBodySetPosition(obj[i].body, + dRandReal()*2-1,dRandReal()*2-1,dRandReal()+2); + dRFromAxisAndAngle(R,dRandReal()*2.0-1.0,dRandReal()*2.0-1.0, + dRandReal()*2.0-1.0,dRandReal()*10.0-5.0); + } else { + // higher than highest body position + dReal maxheight = 0; + for (k=0; k maxheight) + maxheight = pos[2]; + } + dBodySetPosition(obj[i].body, 0,0,maxheight+1); + dRSetIdentity(R); + //dRFromAxisAndAngle (R,0,0,1,/*dRandReal()*10.0-5.0*/0); + } + + dBodySetRotation(obj[i].body,R); + + if (cmd == 'b') { + + dMassSetBox(&m,DENSITY,sides[0],sides[1],sides[2]); + obj[i].geom[0] = dCreateBox(space,sides[0],sides[1],sides[2]); + + } else if (cmd == 'c') { + + sides[0] *= 0.5; + dMassSetCapsule(&m,DENSITY,3,sides[0],sides[1]); + obj[i].geom[0] = dCreateCapsule (space,sides[0],sides[1]); + + } else if (cmd == 'y') { + + dMassSetCylinder(&m,DENSITY,3,sides[0],sides[1]); + obj[i].geom[0] = dCreateCylinder(space,sides[0],sides[1]); + + } else if (cmd == 's') { + + sides[0] *= 0.5; + dMassSetSphere (&m,DENSITY,sides[0]); + obj[i].geom[0] = dCreateSphere (space,sides[0]); + + } else if (cmd == 'x') { + + setBody = true; + // start accumulating masses for the composite geometries + dMass m2; + dMassSetZero (&m); + + dReal dpos[GPB][3]; // delta-positions for composite geometries + dMatrix3 drot[GPB]; + + // set random delta positions + for (j=0; j= num) selected = 0; + if (selected < 0) selected = 0; + } + else if (cmd == 'd' && selected >= 0 && selected < num) { + dBodyDisable (obj[selected].body); + } + else if (cmd == 'e' && selected >= 0 && selected < num) { + dBodyEnable (obj[selected].body); + } + else if (cmd == 'a') { + show_aabb ^= 1; + } + else if (cmd == 't') { + show_contacts ^= 1; + } + else if (cmd == 'r') { + random_pos ^= 1; + } + else if (cmd == 'o') { + draw_geom ^= 1; + } +} + + +// draw a geom + +void drawGeom (dGeomID g, const dReal *pos, const dReal *R, int show_aabb) +{ + if (!draw_geom){ + return; + } + + if (!g) return; + if (!pos) pos = dGeomGetPosition(g); + if (!R) R = dGeomGetRotation(g); + + int type = dGeomGetClass (g); + if (type == dBoxClass) { + dVector3 sides; + dGeomBoxGetLengths(g,sides); + dsDrawBox(pos,R,sides); + } + else if (type == dSphereClass) { + dsDrawSphere(pos,R,dGeomSphereGetRadius (g)); + } + else if (type == dCapsuleClass) { + dReal radius,length; + dGeomCapsuleGetParams(g,&radius,&length); + dsDrawCapsule (pos,R,length,radius); + } else if (type == dCylinderClass) { + dReal radius,length; + dGeomCylinderGetParams(g,&radius,&length); + dsDrawCylinder(pos,R,length,radius); + } + + if (show_aabb) { + // draw the bounding box for this geom + dReal aabb[6]; + dGeomGetAABB(g,aabb); + dVector3 bbpos; + for (int i=0; i<3; i++) + bbpos[i] = 0.5*(aabb[i*2] + aabb[i*2+1]); + dVector3 bbsides; + for (int j=0; j<3; j++) + bbsides[j] = aabb[j*2+1] - aabb[j*2]; + dMatrix3 RI; + dRSetIdentity(RI); + dsSetColorAlpha(1,0,0,0.5); + dsDrawBox(bbpos,RI,bbsides); + } +} + + +// simulation loop + +static void simLoop (int pause) +{ + dsSetColor (0,0,2); + dSpaceCollide (space,0,&nearCallback); + //if (!pause) dWorldStep (world,0.05); + if (!pause) dWorldQuickStep (world,0.05); + //if (!pause) dWorldStepFast (world,0.05, 1); + + // remove all contact joints + dJointGroupEmpty (contactgroup); + + dsSetColor (1,1,0); + dsSetTexture (DS_WOOD); + for (int i=0; i +#include +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +// select correct drawing functions + +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawSphere dsDrawSphereD +#define dsDrawCylinder dsDrawCylinderD +#define dsDrawCapsule dsDrawCapsuleD +#endif + + +// some constants + +#define NUM 10 // number of bodies +#define NUMJ 9 // number of joints +#define SIDE (0.2) // side length of a box +#define MASS (1.0) // mass of a box +#define RADIUS (0.1732f) // sphere radius + + + +// dynamics and collision objects + +static dWorldID world=0; +static dBodyID body[NUM]; +static dJointID joint[NUMJ]; + + +// create the test system + +void createTest() +{ + int i,j; + if (world) dWorldDestroy (world); + + world = dWorldCreate(); + + // create random bodies + for (i=0; i +#include +#include +#include "texturepath.h" + +#ifdef dDOUBLE +#define dsDrawSphere dsDrawSphereD +#define dsDrawBox dsDrawBoxD +#define dsDrawTriangle dsDrawTriangleD +#define dsDrawLine dsDrawLineD +#endif + + + +const dReal ball_radius = 0.4; +const dReal balls_sep = 2; // separation between the balls + +/* Choose one test case + */ +#define TEST_CASE 0 + +#if TEST_CASE == 0 +const dReal track_len = 10; +const dReal track_height = 1; +const dReal track_width = 0.1; +const dReal track_gauge = 1; +const dReal track_elevation = 2; +const dReal track_angle = 80 * M_PI/180.; +const dReal track_incl = 10 * M_PI/180.; +#elif TEST_CASE == 1 +const dReal track_len = 10; +const dReal track_height = 1; +const dReal track_width = 0.1; +const dReal track_gauge = 1.9*ball_radius; +const dReal track_elevation = 2; +const dReal track_angle = 0 * M_PI/180.; +const dReal track_incl = 10 * M_PI/180.; +#elif TEST_CASE == 2 +const dReal track_len = 10; +const dReal track_height = 1; +const dReal track_width = 0.1; +const dReal track_gauge = 1.9*ball_radius; +const dReal track_elevation = 2; +const dReal track_angle = 15 * M_PI/180.; +const dReal track_incl = 10 * M_PI/180.; +#elif TEST_CASE == 3 +const dReal track_len = 10; +const dReal track_height = .7; +const dReal track_width = 0.1; +const dReal track_gauge = track_height*1.1; +const dReal track_elevation = 2; +const dReal track_angle = 90 * M_PI/180.; +const dReal track_incl = 10 * M_PI/180.; +#else +#error "TEST_CAST to a valid value!" +#endif + + + +dWorldID world; +dSpaceID space; +dJointGroupID contact_group; +dGeomID ground; +dGeomID ball1_geom, ball2_geom; +dTriMeshDataID mesh_data; +dGeomID mesh_geom; + +dBodyID ball1_body, ball2_body; + +const unsigned n_box_verts = 8; +dVector3 box_verts[n_box_verts] = { + {-track_len/2, -track_width/2, track_height/2}, // 0 + { track_len/2, -track_width/2, track_height/2}, // 1 + { track_len/2, track_width/2, track_height/2}, // 2 + {-track_len/2, track_width/2, track_height/2}, // 3 + { track_len/2, -track_width/2, -track_height/2}, // 4 + {-track_len/2, -track_width/2, -track_height/2}, // 5 + {-track_len/2, track_width/2, -track_height/2}, // 6 + { track_len/2, track_width/2, -track_height/2} // 7 +}; + +const unsigned n_box_faces = 12; +dTriIndex box_faces[n_box_faces * 3] = { + 0, 1, 2, + 0, 2, 3, + 1, 4, 7, + 1, 7, 2, + 4, 5, 6, + 4, 6, 7, + 5, 0, 3, + 5, 3, 6, + 3, 2, 7, + 3, 7, 6, + 0, 5, 4, + 0, 4, 1 +}; + + +const unsigned n_track_verts = n_box_verts * 2; +const unsigned n_track_faces = n_box_faces * 2; + +dVector3 track_verts[n_track_verts]; +dTriIndex track_faces[n_track_faces * 3]; + + + +void resetBall(dBodyID b, unsigned idx) +{ + dBodySetPosition(b, + 0.5*track_len*cos(track_incl) // Z + - 0.5*track_height*sin(track_incl) + - ball_radius, // X + balls_sep*idx, // Y + track_elevation + ball_radius// Z + + 0.5*track_len*sin(track_incl) + + 0.5*track_height*cos(track_incl)); + dMatrix3 r = {1, 0, 0, 0, + 0, 1, 0, 0, + 0, 0, 1, 0}; + dBodySetRotation(b, r); + dBodySetLinearVel(b, 0, 0, 0); + dBodySetAngularVel(b, 0, 0, 0); + +} + + +void resetSim() +{ + resetBall(ball1_body, 0); + resetBall(ball2_body, 1); +} + + +void start() +{ + dAllocateODEDataForThread(dAllocateMaskAll); + + world = dWorldCreate(); + dWorldSetGravity (world,0,0,-9.8); + + contact_group = dJointGroupCreate(0); + + space = dSimpleSpaceCreate (0); + + + // first, the ground plane + // it has to coincide with the plane we have in drawstuff + ground = dCreatePlane(space, 0, 0, 1, 0); + + + // now a ball + dMass m; + dMassSetSphere(&m, 0.1, ball_radius); + + ball1_geom = dCreateSphere(space, ball_radius); + ball1_body = dBodyCreate(world); + dGeomSetBody(ball1_geom, ball1_body); + dBodySetMass(ball1_body, &m); + + ball2_geom = dCreateSphere(space, ball_radius); + ball2_body = dBodyCreate(world); + dGeomSetBody(ball2_geom, ball2_body); + dBodySetMass(ball2_body, &m); + + + + + // tracks made out of boxes + dGeomID trk; + dMatrix3 r1, r2, r3; + dVector3 ro = {0, -(0.5*track_gauge + 0.5*track_width), track_elevation}; + dMatrix3 s1, s2, s3; + dVector3 so = {0, 0.5*track_gauge + 0.5*track_width, track_elevation}; + + dRFromAxisAndAngle(r1, 1, 0, 0, track_angle); + dRFromAxisAndAngle(r2, 0, 1, 0, -track_incl); + dMultiply0_333(r3, r2, r1); + + dRFromAxisAndAngle(s1, 1, 0, 0, -track_angle); + dRFromAxisAndAngle(s2, 0, 1, 0, -track_incl); + dMultiply0_333(s3, s2, s1); + + trk = dCreateBox(space, track_len, track_width, track_height); + dGeomSetPosition(trk, ro[0], ro[1] + balls_sep, ro[2]); + dGeomSetRotation(trk, r3); + + trk = dCreateBox(space, track_len, track_width, track_height); + dGeomSetPosition(trk, so[0], so[1] + balls_sep, so[2]); + dGeomSetRotation(trk, s3); + + + + + + // tracks made out of trimesh + for (unsigned i=0; i 0.99 // about 8 degrees of difference + && + dCalcPointsDistance3(contacts[i].geom.pos, contacts[j].geom.pos) < epsilon) { + // they are too close + closest_point = j; + //clog << "found close points: " << j << " and " << i << endl; + break; + } + } + + if (closest_point != i) { + // we discard one of the points + if (contacts[i].geom.depth > contacts[closest_point].geom.depth) + // the new point is deeper, copy it over closest_point + contacts[closest_point] = contacts[i]; + } else + contacts[new_n++] = contacts[i]; // the point is preserved + } + //clog << "reduced from " << n << " to " << new_n << endl; + n = new_n; + + for (int i=0; i +#include +#include "texturepath.h" + +#ifdef dDOUBLE +#define dsDrawCylinder dsDrawCylinderD +#define dsDrawLine dsDrawLineD +#define dsDrawSphere dsDrawSphereD +#endif + +dReal theta = M_PI / 4; +dReal ratio = 1, speed = 5, rho_1 = 1, rho_2 = 1, backlash = 0.1; +int mode = 0; + +dWorldID world; +dSpaceID space; +dBodyID body1, body2; +dGeomID geom1, geom2; +dJointID hinge1, hinge2, transmission; +dJointFeedback feedback; + +void setup() { + dMatrix3 R; + + switch (mode) { + case 0: + // Parallel axes. + + dBodySetPosition(body1, 1, 0, 1); + dBodySetPosition(body2, -1, 0, 1); + + dRSetIdentity (R); + dBodySetRotation (body1, R); + dBodySetRotation (body2, R); + + dJointSetHingeAnchor(hinge2, -1, 0, 1); + dJointSetHingeAxis(hinge2, 0, 0, 1); + + dJointSetHingeAnchor(hinge1, 1, 0, 1); + dJointSetHingeAxis(hinge1, 0, 0, 1); + + dJointSetTransmissionMode(transmission, dTransmissionParallelAxes); + dJointSetTransmissionRatio(transmission, ratio); + dJointSetTransmissionAnchor1(transmission, 1, 0, 1); + dJointSetTransmissionAnchor2(transmission, -1, 0, 1); + dJointSetTransmissionAxis(transmission, 0, 0, 1); + + break; + case 1: + // Intersecting axes. + + dBodySetPosition(body1, 1, 0, 1); + dBodySetPosition(body2, -1, 0, 2); + + dRSetIdentity (R); + dBodySetRotation (body1, R); + + dRFromZAxis (R, cos(theta), 0, sin(theta)); + dBodySetRotation (body2, R); + + dJointSetHingeAnchor(hinge2, -1, 0, 2); + dJointSetHingeAxis(hinge2, cos(theta), 0, sin(theta)); + + dJointSetHingeAnchor(hinge1, 1, 0, 1); + dJointSetHingeAxis(hinge1, 0, 0, 1); + + dJointSetTransmissionMode(transmission, dTransmissionIntersectingAxes); + dJointSetTransmissionAnchor1(transmission, 1, 0, 1); + dJointSetTransmissionAnchor2(transmission, -1, 0, 2); + dJointSetTransmissionAxis1(transmission, 0, 0, -1); + dJointSetTransmissionAxis2(transmission, cos(theta), 0, sin(theta)); + + break; + case 2: + // Chain. + + dBodySetPosition(body1, 2, 0, 1); + dBodySetPosition(body2, -2, 0, 1); + + dRSetIdentity (R); + dBodySetRotation (body1, R); + dBodySetRotation (body2, R); + + dJointSetHingeAnchor(hinge2, -2, 0, 1); + dJointSetHingeAxis(hinge2, 0, 0, 1); + + dJointSetHingeAnchor(hinge1, 2, 0, 1); + dJointSetHingeAxis(hinge1, 0, 0, 1); + + dJointSetTransmissionMode(transmission, dTransmissionChainDrive); + dJointSetTransmissionAnchor1(transmission, 2, 0, 1); + dJointSetTransmissionAnchor2(transmission, -2, 0, 1); + dJointSetTransmissionRadius1(transmission, rho_1); + dJointSetTransmissionRadius2(transmission, rho_2); + dJointSetTransmissionAxis(transmission, 0, 0, 1); + + break; + } + + dJointSetTransmissionBacklash(transmission, backlash); + + dJointSetHingeParam(hinge2, dParamVel, speed); + dJointSetHingeParam(hinge2, dParamFMax, 50); + + dJointSetHingeParam(hinge1, dParamVel, 0); + dJointSetHingeParam(hinge1, dParamFMax, 2); + + dBodySetLinearVel(body1, 0, 0, 0); + dBodySetLinearVel(body2, 0, 0, 0); + dBodySetAngularVel(body1, 0, 0, 0); + dBodySetAngularVel(body2, 0, 0, 0); +} + +void start() +{ + dMass mass; + + world = dWorldCreate(); + dWorldSetGravity (world,0,0,-9.8); + + dWorldSetERP(world, 0.2); + + space = dSimpleSpaceCreate (0); + + body1 = dBodyCreate(world); + body2 = dBodyCreate(world); + + dBodySetFiniteRotationMode(body1, 1); + dBodySetFiniteRotationMode(body2, 1); + + geom1 = dCreateCylinder(space, 0.2, 0.5); + dGeomSetBody(geom1, body1); + dMassSetCylinder(&mass, 100, 3, 0.2, 0.5); + dBodySetMass(body1, &mass); + + geom2 = dCreateCylinder(space, 0.2, 0.5); + dGeomSetBody(geom2, body2); + dMassSetCylinder(&mass, 100, 3, 0.2, 0.5); + dBodySetMass(body2, &mass); + + hinge1 = dJointCreateHinge(world, 0); + dJointAttach(hinge1, body1, 0); + + hinge2 = dJointCreateHinge(world, 0); + dJointAttach(hinge2, body2, 0); + + transmission = dJointCreateTransmission(world, 0); + dJointAttach(transmission, body1, body2); + dJointSetFeedback(transmission, &feedback); + + setup(); + + // initial camera position + static float xyz[3] = {1.15,-2.78,4.1}; + static float hpr[3] = {105,-45.5,0}; + dsSetViewpoint (xyz,hpr); + + fprintf (stderr, + "The green wheel is driving the red one. To control it use the following:\n" + " '[' : decrease wheel ratio\n" + " ']' : increase wheel ratio\n" + " ',' : decrease driving wheel speed\n" + " '.' : increase driving wheel speed\n" + " '-' : decrease backlash\n" + " '=' : increase backlash\n" + " '1' : switch to parallel axes gears mode\n" + " '2' : switch to intersecting axes gears mode\n" + " '3' : switch to chain (or belt) mode\n" +); +} + +void stop() +{ + dSpaceDestroy(space); + + dWorldDestroy(world); +} + +void drawGeom(dGeomID g) +{ + int gclass = dGeomGetClass(g); + const dReal *pos = dGeomGetPosition(g); + const dReal *rot = dGeomGetRotation(g); + + switch (gclass) { + case dCylinderClass: + { + dReal length, radius; + + if (g == geom1) { + dsSetColorAlpha(1, 0, 0, 1); + } else { + dsSetColorAlpha(0, 1, 0, 1); + } + + dsSetTexture (DS_WOOD); + dGeomCylinderGetParams(g, &radius, &length); + dsDrawCylinder(pos, rot, length, radius); + break; + } + + default: + { + abort(); + } + } +} + +void simLoop(int pause) +{ + if (!pause) { + + const dReal step = 0.003; + const unsigned nsteps = 4; + + for (unsigned i=0; i 0.125) { + ratio *= 0.5; + + fprintf (stderr, "Gear ratio set to %.3f.\n", ratio); + } + break; + case dTransmissionIntersectingAxes: + if (theta > 0.1) { + theta -= 0.1; + + fprintf (stderr, "Gear angle set to %.3f deg.\n", + theta / M_PI * 180); + } + break; + case dTransmissionChainDrive: + if (rho_2 > 0.125) { + rho_2 /= 2; + + fprintf (stderr, "Sprocket ratio set to %.3f.\n", rho_2 / rho_1); + } + break; + } + + setup(); + } else if (cmd == ']') { + switch(mode) { + case dTransmissionParallelAxes: + if (ratio < 8) { + ratio *= 2; + + fprintf (stderr, "Gear ratio set to %.3f.\n", ratio); + } + break; + case dTransmissionIntersectingAxes: + if (theta < 0.9) { + theta += 0.1; + + fprintf (stderr, "Gear angle set to %.3f deg.\n", + theta / M_PI * 180); + } + break; + case dTransmissionChainDrive: + if (rho_2 < 2) { + rho_2 *= 2; + + fprintf (stderr, "Sprocket ratio set to %.3f.\n", rho_2 / rho_1); + } + break; + } + + setup(); + } else if (cmd == '.') { + speed += 5; + + fprintf (stderr, "Driving wheel speed set to %g rad/s.\n", speed); + + dJointSetHingeParam(hinge2, dParamVel, speed); + } else if (cmd == ',') { + speed -= 5; + + fprintf (stderr, "Driving wheel speed set to %g rad/s.\n", speed); + + dJointSetHingeParam(hinge2, dParamVel, speed); + } else if (cmd == '/') { + if (dJointGetHingeParam(hinge2, dParamFMax) > 0) { + dJointSetHingeParam(hinge2, dParamFMax, 0); + } else { + dJointSetHingeParam(hinge2, dParamFMax, 50); + } + + } else if (cmd == '-') { + backlash -= 0.1; + + fprintf (stderr, "Backlash set to %g m.\n", backlash); + + dJointSetTransmissionBacklash(transmission, backlash); + } else if (cmd == '=') { + backlash += 0.1; + + fprintf (stderr, "Backlash set to %g m.\n", backlash); + + dJointSetTransmissionBacklash(transmission, backlash); + } else if (cmd == '1') { + mode = dTransmissionParallelAxes; + setup(); + } else if (cmd == '2') { + mode = dTransmissionIntersectingAxes; + setup(); + } else if (cmd == '3') { + mode = dTransmissionChainDrive; + setup(); + } +} + +int main(int argc, char **argv) +{ + // setup pointers to drawstuff callback functions + dsFunctions fn; + fn.version = DS_VERSION; + fn.start = &start; + fn.step = &simLoop; + fn.command = &command; + fn.stop = stop; + fn.path_to_textures = DRAWSTUFF_TEXTURE_PATH; + + // create world + dInitODE(); + + // run demo + dsSimulationLoop (argc, argv, 800, 600, &fn); + + dCloseODE(); + return 0; +} diff --git a/libs/ode-0.16.1/ode/demo/demo_trimesh.cpp b/libs/ode-0.16.1/ode/demo/demo_trimesh.cpp new file mode 100644 index 0000000..1c53334 --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/demo_trimesh.cpp @@ -0,0 +1,605 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001-2003 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +// TriMesh test by Erwin de Vries + +#include +#include +#include "texturepath.h" + +#ifdef _MSC_VER +#pragma warning(disable:4244 4305) // for VC++, no precision loss complaints +#endif + +//<---- Convex Object +static const dReal planes[] = // planes for a cube +{ + 1.0f ,0.0f ,0.0f ,0.25f, + 0.0f ,1.0f ,0.0f ,0.25f, + 0.0f ,0.0f ,1.0f ,0.25f, + 0.0f ,0.0f ,-1.0f,0.25f, + 0.0f ,-1.0f,0.0f ,0.25f, + -1.0f,0.0f ,0.0f ,0.25f + /* + 1.0f ,0.0f ,0.0f ,2.0f, + 0.0f ,1.0f ,0.0f ,1.0f, + 0.0f ,0.0f ,1.0f ,1.0f, + 0.0f ,0.0f ,-1.0f,1.0f, + 0.0f ,-1.0f,0.0f ,1.0f, + -1.0f,0.0f ,0.0f ,0.0f + */ +}; +static const unsigned int planecount=6; + +static const dReal points[] = // points for a cube +{ + 0.25f,0.25f,0.25f, + -0.25f,0.25f,0.25f, + + 0.25f,-0.25f,0.25f, + -0.25f,-0.25f,0.25f, + + 0.25f,0.25f,-0.25f, + -0.25f,0.25f,-0.25f, + + 0.25f,-0.25f,-0.25f, + -0.25f,-0.25f,-0.25f, +}; +static const unsigned int pointcount=8; + +static const unsigned int polygons[] = //Polygons for a cube (6 squares) + { + 4,0,2,6,4, // positive X + 4,1,0,4,5, // positive Y + 4,0,1,3,2, // positive Z + 4,3,1,5,7, // negative X + 4,2,3,7,6, // negative Y + 4,5,4,6,7, // negative Z + }; +//----> Convex Object + +// select correct drawing functions + +#ifdef dDOUBLE +#define dsDrawBox dsDrawBoxD +#define dsDrawSphere dsDrawSphereD +#define dsDrawCylinder dsDrawCylinderD +#define dsDrawCapsule dsDrawCapsuleD +#define dsDrawLine dsDrawLineD +#define dsDrawTriangle dsDrawTriangleD +#define dsDrawConvex dsDrawConvexD +#endif + + +// some constants + +#define NUM 200 // max number of objects +#define DENSITY (5.0) // density of all objects +#define GPB 3 // maximum number of geometries per body +#define MAX_CONTACTS 40 // maximum number of contact points per body + + +// dynamics and collision objects + +struct MyObject { + dBodyID body; // the body + dGeomID geom[GPB]; // geometries representing this body +}; + +static int num=0; // number of objects in simulation +static int nextobj=0; // next object to recycle if num==NUM +static dWorldID world; +static dSpaceID space; +static MyObject obj[NUM]; +static dJointGroupID contactgroup; +static int selected = -1; // selected object +static int show_aabb = 0; // show geom AABBs? +static int show_contacts = 0; // show contact points? +static int random_pos = 1; // drop objects from random position? + +#define VertexCount 5 +#define IndexCount 12 + +static dVector3 Size; +static float Vertices[VertexCount][3]; +static dTriIndex Indices[IndexCount]; + +static dGeomID TriMesh; +static dGeomID Ray; + + +// this is called by dSpaceCollide when two objects in space are +// potentially colliding. + +static void nearCallback (void *, dGeomID o1, dGeomID o2) +{ + int i; + // if (o1->body && o2->body) return; + + // exit without doing anything if the two bodies are connected by a joint + dBodyID b1 = dGeomGetBody(o1); + dBodyID b2 = dGeomGetBody(o2); + if (b1 && b2 && dAreConnectedExcluding (b1,b2,dJointTypeContact)) return; + + dContact contact[MAX_CONTACTS]; // up to MAX_CONTACTS contacts per box-box + for (i=0; i= 'A' && c <= 'Z') return c - ('a'-'A'); + else return c; +} + + +// called when a key pressed + +static void command (int cmd) +{ + int i,j,k; + dReal sides[3]; + dMass m; + bool setBody = false; + + cmd = locase (cmd); + if (cmd == 'b' || cmd == 's' || cmd == 'c' || cmd == 'x' || cmd == 'v' + /* || cmd == 'l' */) { + if (num < NUM) { + i = num; + num++; + } + else { + i = nextobj; + nextobj++; + if (nextobj >= num) nextobj = 0; + + // destroy the body and geoms for slot i + dBodyDestroy (obj[i].body); + for (k=0; k < GPB; k++) { + if (obj[i].geom[k]) dGeomDestroy (obj[i].geom[k]); + } + memset (&obj[i],0,sizeof(obj[i])); + } + + obj[i].body = dBodyCreate (world); + for (k=0; k<3; k++) sides[k] = dRandReal()*0.5+0.1; + + dMatrix3 R; + if (random_pos) { + dBodySetPosition (obj[i].body, + dRandReal()*2-1,dRandReal()*2-1,dRandReal()+1); + dRFromAxisAndAngle (R,dRandReal()*2.0-1.0,dRandReal()*2.0-1.0, + dRandReal()*2.0-1.0,dRandReal()*10.0-5.0); + } + else { + dReal maxheight = 0; + for (k=0; k maxheight) maxheight = pos[2]; + } + dBodySetPosition (obj[i].body, 0,0,maxheight+1); + dRFromAxisAndAngle (R,0,0,1,dRandReal()*10.0-5.0); + } + dBodySetRotation (obj[i].body,R); + dBodySetData (obj[i].body,(void*)(dsizeint)i); + + if (cmd == 'b') { + dMassSetBox (&m,DENSITY,sides[0],sides[1],sides[2]); + obj[i].geom[0] = dCreateBox (space,sides[0],sides[1],sides[2]); + } + else if (cmd == 'c') { + sides[0] *= 0.5; + dMassSetCapsule (&m,DENSITY,3,sides[0],sides[1]); + obj[i].geom[0] = dCreateCapsule (space,sides[0],sides[1]); + } +/* + // cylinder option not yet implemented + else if (cmd == 'l') { + sides[1] *= 0.5; + dMassSetCapsule (&m,DENSITY,3,sides[0],sides[1]); + obj[i].geom[0] = dCreateCylinder (space,sides[0],sides[1]); + } +*/ + else if (cmd == 's') { + sides[0] *= 0.5; + dMassSetSphere (&m,DENSITY,sides[0]); + obj[i].geom[0] = dCreateSphere (space,sides[0]); + } + else if (cmd == 'x') { + + setBody = true; + // start accumulating masses for the composite geometries + dMass m2; + dMassSetZero (&m); + + dReal dpos[GPB][3]; // delta-positions for composite geometries + dMatrix3 drot[GPB]; + + // set random delta positions + for (j=0; j= num) selected = 0; + if (selected < 0) selected = 0; + } + else if (cmd == 'd' && selected >= 0 && selected < num) { + dBodyDisable (obj[selected].body); + } + else if (cmd == 'e' && selected >= 0 && selected < num) { + dBodyEnable (obj[selected].body); + } + else if (cmd == 'a') { + show_aabb ^= 1; + } + else if (cmd == 't') { + show_contacts ^= 1; + } + else if (cmd == 'r') { + random_pos ^= 1; + } +} + + +// draw a geom + +void drawGeom (dGeomID g, const dReal *pos, const dReal *R, int show_aabb) +{ + if (!g) return; + if (!pos) pos = dGeomGetPosition (g); + if (!R) R = dGeomGetRotation (g); + + int type = dGeomGetClass (g); + if (type == dBoxClass) { + dVector3 sides; + dGeomBoxGetLengths (g,sides); + dsDrawBox (pos,R,sides); + } + else if (type == dSphereClass) { + dsDrawSphere (pos,R,dGeomSphereGetRadius (g)); + } + else if (type == dCapsuleClass) { + dReal radius,length; + dGeomCapsuleGetParams (g,&radius,&length); + dsDrawCapsule (pos,R,length,radius); + } else if (type == dConvexClass) { + //dVector3 sides={0.50,0.50,0.50}; + dsDrawConvex(pos,R,planes, + planecount, + points, + pointcount, + polygons); + } +/* + // cylinder option not yet implemented + else if (type == dCylinderClass) { + dReal radius,length; + dGeomCylinderGetParams (g,&radius,&length); + dsDrawCylinder (pos,R,length,radius); + } +*/ + + if (show_aabb) { + // draw the bounding box for this geom + dReal aabb[6]; + dGeomGetAABB (g,aabb); + dVector3 bbpos; + for (int i=0; i<3; i++) bbpos[i] = 0.5*(aabb[i*2] + aabb[i*2+1]); + dVector3 bbsides; + for (int j=0; j<3; j++) bbsides[j] = aabb[j*2+1] - aabb[j*2]; + dMatrix3 RI; + dRSetIdentity (RI); + dsSetColorAlpha (1,0,0,0.5); + dsDrawBox (bbpos,RI,bbsides); + } +} + + +// simulation loop + +static void simLoop (int pause) +{ + dsSetColor (0,0,2); + dSpaceCollide (space,0,&nearCallback); + if (!pause) dWorldStep (world,0.05); + //if (!pause) dWorldStepFast (world,0.05, 1); + + // remove all contact joints + dJointGroupEmpty (contactgroup); + + dsSetColor (1,1,0); + dsSetTexture (DS_WOOD); + for (int i=0; i +/* + This is a description of a convex icosahedron, to test + the convex collision detection. +*/ +unsigned int Sphere_pointcount = 42; +unsigned int Sphere_planecount = 80; +dReal Sphere_points[126]={ +0.000000,0.000000,-0.300000, +0.217080,-0.157716,-0.134164, +-0.082915,-0.255192,-0.134164, +-0.268327,0.000000,-0.134164, +-0.082915,0.255192,-0.134164, +0.217080,0.157716,-0.134164, +0.082915,-0.255192,0.134164, +-0.217080,-0.157716,0.134164, +-0.217080,0.157716,0.134164, +0.082915,0.255192,0.134164, +0.268327,0.000000,0.134164, +0.000000,0.000000,0.300000, +0.127597,-0.092703,-0.255196, +-0.048737,-0.149999,-0.255196, +0.078861,-0.242703,-0.157721, +0.127597,0.092703,-0.255196, +0.255194,0.000000,-0.157721, +-0.157719,0.000000,-0.255195, +-0.206457,-0.149999,-0.157721, +-0.048737,0.149999,-0.255196, +-0.206457,0.149999,-0.157721, +0.078861,0.242703,-0.157721, +0.285317,0.092704,0.000000, +0.285317,-0.092704,0.000000, +0.176336,-0.242705,0.000000, +0.000000,-0.300000,0.000000, +-0.176336,-0.242705,0.000000, +-0.285317,-0.092704,0.000000, +-0.285317,0.092704,0.000000, +-0.176336,0.242705,0.000000, +0.000000,0.300000,0.000000, +0.176336,0.242705,0.000000, +0.206457,-0.149999,0.157721, +-0.078861,-0.242703,0.157721, +-0.255194,0.000000,0.157721, +-0.078861,0.242703,0.157721, +0.206457,0.149999,0.157721, +0.157719,0.000000,0.255195, +0.048737,-0.149999,0.255196, +-0.127597,-0.092703,0.255196, +-0.127597,0.092703,0.255196, +0.048737,0.149999,0.255196 +}; +unsigned int Sphere_polygons[]={ +3,14,12,1, +3,12,14,13, +3,2,13,14, +3,13,0,12, +3,16,1,12, +3,12,15,16, +3,5,16,15, +3,12,0,15, +3,18,13,2, +3,13,18,17, +3,3,17,18, +3,17,0,13, +3,20,17,3, +3,17,20,19, +3,4,19,20, +3,19,0,17, +3,21,19,4, +3,19,21,15, +3,5,15,21, +3,15,0,19, +3,23,1,16, +3,16,22,23, +3,10,23,22, +3,22,16,5, +3,25,2,14, +3,14,24,25, +3,6,25,24, +3,24,14,1, +3,27,3,18, +3,18,26,27, +3,7,27,26, +3,26,18,2, +3,29,4,20, +3,20,28,29, +3,8,29,28, +3,28,20,3, +3,31,5,21, +3,21,30,31, +3,9,31,30, +3,30,21,4, +3,32,23,10, +3,23,32,24, +3,6,24,32, +3,24,1,23, +3,33,25,6, +3,25,33,26, +3,7,26,33, +3,26,2,25, +3,34,27,7, +3,27,34,28, +3,8,28,34, +3,28,3,27, +3,35,29,8, +3,29,35,30, +3,9,30,35, +3,30,4,29, +3,36,31,9, +3,31,36,22, +3,10,22,36, +3,22,5,31, +3,38,6,32, +3,32,37,38, +3,11,38,37, +3,37,32,10, +3,39,7,33, +3,33,38,39, +3,11,39,38, +3,38,33,6, +3,40,8,34, +3,34,39,40, +3,11,40,39, +3,39,34,7, +3,41,9,35, +3,35,40,41, +3,11,41,40, +3,40,35,8, +3,37,10,36, +3,36,41,37, +3,11,37,41, +3,41,36,9, +}; +dReal Sphere_planes[]={ +0.471317,-0.583121,-0.661687,0.283056, +0.187594,-0.577345,-0.794658,0.280252, +-0.038547,-0.748789,-0.661687,0.283056, +0.102381,-0.315090,-0.943523,0.283057, +0.700228,-0.268049,-0.661688,0.283056, +0.607060,0.000000,-0.794656,0.280252, +0.700228,0.268049,-0.661688,0.283056, +0.331305,0.000000,-0.943524,0.283057, +-0.408939,-0.628443,-0.661686,0.283056, +-0.491119,-0.356821,-0.794657,0.280252, +-0.724044,-0.194735,-0.661694,0.283057, +-0.268034,-0.194737,-0.943523,0.283057, +-0.724044,0.194735,-0.661694,0.283057, +-0.491119,0.356821,-0.794657,0.280252, +-0.408939,0.628443,-0.661686,0.283056, +-0.268034,0.194737,-0.943523,0.283057, +-0.038547,0.748789,-0.661687,0.283056, +0.187594,0.577345,-0.794658,0.280252, +0.471317,0.583121,-0.661687,0.283056, +0.102381,0.315090,-0.943523,0.283057, +0.904981,-0.268049,-0.330393,0.283056, +0.982246,0.000000,-0.187599,0.280252, +0.992077,0.000000,0.125631,0.283057, +0.904981,0.268049,-0.330393,0.283056, +0.024726,-0.943519,-0.330396,0.283056, +0.303531,-0.934171,-0.187598,0.280251, +0.306568,-0.943519,0.125651,0.283056, +0.534590,-0.777851,-0.330395,0.283056, +-0.889698,-0.315092,-0.330386,0.283056, +-0.794656,-0.577348,-0.187595,0.280251, +-0.802607,-0.583125,0.125648,0.283055, +-0.574584,-0.748793,-0.330397,0.283055, +-0.574584,0.748793,-0.330397,0.283055, +-0.794656,0.577348,-0.187595,0.280251, +-0.802607,0.583125,0.125648,0.283055, +-0.889698,0.315092,-0.330386,0.283056, +0.534590,0.777851,-0.330395,0.283056, +0.303531,0.934171,-0.187598,0.280251, +0.306568,0.943519,0.125651,0.283056, +0.024726,0.943519,-0.330396,0.283056, +0.889698,-0.315092,0.330386,0.283056, +0.794656,-0.577348,0.187595,0.280251, +0.574584,-0.748793,0.330397,0.283055, +0.802607,-0.583125,-0.125648,0.283055, +-0.024726,-0.943519,0.330396,0.283055, +-0.303531,-0.934171,0.187598,0.280251, +-0.534590,-0.777851,0.330395,0.283056, +-0.306568,-0.943519,-0.125651,0.283056, +-0.904981,-0.268049,0.330393,0.283056, +-0.982246,0.000000,0.187599,0.280252, +-0.904981,0.268049,0.330393,0.283056, +-0.992077,0.000000,-0.125631,0.283057, +-0.534590,0.777851,0.330395,0.283056, +-0.303531,0.934171,0.187598,0.280251, +-0.024726,0.943519,0.330396,0.283055, +-0.306568,0.943519,-0.125651,0.283056, +0.574584,0.748793,0.330397,0.283055, +0.794656,0.577348,0.187595,0.280251, +0.889698,0.315092,0.330386,0.283056, +0.802607,0.583125,-0.125648,0.283055, +0.408939,-0.628443,0.661686,0.283056, +0.491119,-0.356821,0.794657,0.280252, +0.268034,-0.194737,0.943523,0.283057, +0.724044,-0.194735,0.661694,0.283057, +-0.471317,-0.583121,0.661687,0.283056, +-0.187594,-0.577345,0.794658,0.280252, +-0.102381,-0.315090,0.943523,0.283057, +0.038547,-0.748789,0.661687,0.283056, +-0.700228,0.268049,0.661688,0.283056, +-0.607060,0.000000,0.794656,0.280252, +-0.331305,0.000000,0.943524,0.283057, +-0.700228,-0.268049,0.661688,0.283056, +0.038547,0.748789,0.661687,0.283056, +-0.187594,0.577345,0.794658,0.280252, +-0.102381,0.315090,0.943523,0.283057, +-0.471317,0.583121,0.661687,0.283056, +0.724044,0.194735,0.661694,0.283057, +0.491119,0.356821,0.794657,0.280252, +0.268034,0.194737,0.943523,0.283057, +0.408939,0.628443,0.661686,0.283056, +}; + diff --git a/libs/ode-0.16.1/ode/demo/texturepath.h b/libs/ode-0.16.1/ode/demo/texturepath.h new file mode 100644 index 0000000..5815138 --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/texturepath.h @@ -0,0 +1,26 @@ +/************************************************************************* + * * + * Open Dynamics Engine, Copyright (C) 2001,2002 Russell L. Smith. * + * All rights reserved. Email: russ@q12.org Web: www.q12.org * + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of EITHER: * + * (1) The GNU Lesser General Public License as published by the Free * + * Software Foundation; either version 2.1 of the License, or (at * + * your option) any later version. The text of the GNU Lesser * + * General Public License is included with this library in the * + * file LICENSE.TXT. * + * (2) The BSD-style license that is included with this library in * + * the file LICENSE-BSD.TXT. * + * * + * This library is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files * + * LICENSE.TXT and LICENSE-BSD.TXT for more details. * + * * + *************************************************************************/ + +#ifndef DRAWSTUFF_TEXTURE_PATH +#define DRAWSTUFF_TEXTURE_PATH "../../drawstuff/textures" +#endif + diff --git a/libs/ode-0.16.1/ode/demo/world_geom3.h b/libs/ode-0.16.1/ode/demo/world_geom3.h new file mode 100644 index 0000000..27cd69e --- /dev/null +++ b/libs/ode-0.16.1/ode/demo/world_geom3.h @@ -0,0 +1,9 @@ +// mesh for a world model, to be used with test_cyl.cpp + +static float world_vertices[] = {10.000000f,-10.000000f,1.000000f,-10.000000f,-10.000000f,1.000000f,-10.000000f,-10.000000f,-1.000000f,-10.000000f,-10.000000f,-1.000000f,10.000000f,-10.000000f,-1.000000f,10.000000f,-10.000000f,1.000000f,10.000000f,10.000000f,1.000000f,10.000000f,-10.000000f,1.000000f,10.000000f,-10.000000f,-1.000000f,10.000000f,-10.000000f,-1.000000f,10.000000f,10.000000f,-1.000000f,10.000000f,10.000000f,1.000000f,10.000000f,10.000000f,-1.000000f,10.000000f,-10.000000f,-1.000000f,-10.000000f,-10.000000f,-1.000000f,-10.000000f,-10.000000f,-1.000000f,-10.000000f,10.000000f,-1.000000f,10.000000f,10.000000f,-1.000000f,0.000000f,9.000000f,-0.000000f,0.000000f,-9.000000f,0.000000f,9.000000f,-9.000000f,0.000000f,0.000000f,9.000000f,-0.000000f,9.000000f,-9.000000f,0.000000f,9.000000f,9.000000f,-0.000000f,10.000000f,10.000000f,-1.000000f,-10.000000f,10.000000f,-1.000000f,-10.000000f,10.000000f,1.000000f,10.000000f,10.000000f,-1.000000f,-10.000000f,10.000000f,1.000000f,10.000000f,10.000000f,1.000000f,-10.000000f,-10.000000f,-1.000000f,-10.000000f,-10.000000f,1.000000f,-10.000000f,10.000000f,1.000000f,-10.000000f,10.000000f,1.000000f,-10.000000f,10.000000f,-1.000000f,-10.000000f,-10.000000f,-1.000000f,9.000000f,-9.000000f,1.000000f,-9.000000f,-9.000000f,1.000000f,10.000000f,-10.000000f,1.000000f,-9.000000f,-9.000000f,1.000000f,-10.000000f,-10.000000f,1.000000f,10.000000f,-10.000000f,1.000000f,9.000000f,9.000000f,1.000000f,9.000000f,-9.000000f,1.000000f,10.000000f,-10.000000f,1.000000f,10.000000f,-10.000000f,1.000000f,10.000000f,10.000000f,1.000000f,9.000000f,9.000000f,1.000000f,-9.000000f,9.000000f,1.000000f,9.000000f,9.000000f,1.000000f,10.000000f,10.000000f,1.000000f,10.000000f,10.000000f,1.000000f,-10.000000f,10.000000f,1.000000f,-9.000000f,9.000000f,1.000000f,-9.000000f,9.000000f,1.000000f,-10.000000f,10.000000f,1.000000f,-9.000000f,-9.000000f,1.000000f,-10.000000f,10.000000f,1.000000f,-10.000000f,-10.000000f,1.000000f,-9.000000f,-9.000000f,1.000000f,0.000000f,-9.000000f,0.000000f,-9.000000f,-9.000000f,0.000000f,-9.000000f,-9.000000f,1.000000f,0.000000f,-9.000000f,0.000000f,-9.000000f,-9.000000f,1.000000f,9.000000f,-9.000000f,1.000000f,0.000000f,-9.000000f,0.000000f,9.000000f,-9.000000f,1.000000f,9.000000f,-9.000000f,0.000000f,9.000000f,-9.000000f,0.000000f,9.000000f,-9.000000f,1.000000f,9.000000f,9.000000f,1.000000f,9.000000f,9.000000f,1.000000f,9.000000f,9.000000f,-0.000000f,9.000000f,-9.000000f,0.000000f,0.000000f,9.000000f,-0.000000f,9.000000f,9.000000f,-0.000000f,9.000000f,9.000000f,1.000000f,0.000000f,9.000000f,-0.000000f,9.000000f,9.000000f,1.000000f,-9.000000f,9.000000f,1.000000f,0.000000f,9.000000f,-0.000000f,-9.000000f,9.000000f,1.000000f,-9.000000f,9.000000f,-0.000000f,-9.000000f,9.000000f,1.000000f,-9.000000f,-9.000000f,1.000000f,-9.000000f,-9.000000f,0.000000f,-9.000000f,-9.000000f,0.000000f,-9.000000f,9.000000f,-0.000000f,-9.000000f,9.000000f,1.000000f,-2.997000f,-1.748874f,0.000000f,-2.997000f,-2.001000f,0.000000f,0.000000f,-9.000000f,0.000000f,-2.997000f,-1.748874f,0.000000f,0.000000f,-9.000000f,0.000000f,-2.997000f,1.748874f,-0.000000f,-2.997000f,-2.001000f,0.000000f,-2.997000f,-6.003000f,0.002697f,0.000000f,-9.000000f,0.000000f,0.000000f,9.000000f,-0.000000f,-2.997000f,2.001000f,-0.000000f,-2.997000f,1.748874f,-0.000000f,0.000000f,9.000000f,-0.000000f,-2.997000f,1.748874f,-0.000000f,0.000000f,-9.000000f,0.000000f,-2.997000f,2.001000f,-0.000000f,0.000000f,9.000000f,-0.000000f,-2.997000f,6.003000f,0.002697f,-6.003000f,6.003000f,0.002697f,-2.997000f,6.003000f,0.002697f,0.000000f,9.000000f,-0.000000f,0.000000f,9.000000f,-0.000000f,-9.000000f,9.000000f,-0.000000f,-6.003000f,6.003000f,0.002697f,-6.003000f,1.748874f,-0.000000f,-9.000000f,-9.000000f,0.000000f,-6.003000f,-1.748874f,0.000000f,-6.003000f,2.001000f,-0.000000f,-6.003000f,6.003000f,0.002697f,-9.000000f,9.000000f,-0.000000f,-9.000000f,9.000000f,-0.000000f,-6.003000f,1.748874f,-0.000000f,-6.003000f,2.001000f,-0.000000f,-9.000000f,9.000000f,-0.000000f,-9.000000f,-9.000000f,0.000000f,-6.003000f,1.748874f,-0.000000f,-9.000000f,-9.000000f,0.000000f,-6.003000f,-6.003000f,0.002697f,-6.003000f,-2.001000f,0.000000f,-9.000000f,-9.000000f,0.000000f,-6.003000f,-2.001000f,0.000000f,-6.003000f,-1.748874f,0.000000f,-6.003000f,-6.003000f,0.002697f,-9.000000f,-9.000000f,0.000000f,0.000000f,-9.000000f,0.000000f,-6.003000f,-6.003000f,0.002697f,0.000000f,-9.000000f,0.000000f,-2.997000f,-6.003000f,0.002697f,-2.997000f,1.748874f,1.237951f,-2.997000f,1.748874f,-0.000000f,-2.997000f,2.001000f,-0.000000f,-2.997000f,1.748874f,1.237951f,-2.997000f,2.001000f,-0.000000f,-2.997000f,2.001000f,1.515748f,-6.003000f,-2.001000f,1.515748f,-6.003000f,-6.003000f,0.002697f,-2.997000f,-6.003000f,0.002697f,-6.003000f,-2.001000f,1.515748f,-2.997000f,-6.003000f,0.002697f,-2.997000f,-2.001000f,1.515748f,-2.997000f,2.001000f,1.515748f,-2.997000f,6.003000f,0.002697f,-6.003000f,6.003000f,0.002697f,-6.003000f,6.003000f,0.002697f,-6.003000f,2.001000f,1.515748f,-2.997000f,2.001000f,1.515748f,-6.003000f,-2.001000f,0.000000f,-6.003000f,-6.003000f,0.002697f,-6.003000f,-2.001000f,1.515748f,-6.003000f,2.001000f,1.515748f,-6.003000f,6.003000f,0.002697f,-6.003000f,2.001000f,-0.000000f,-2.997000f,-2.001000f,1.515748f,-2.997000f,-6.003000f,0.002697f,-2.997000f,-2.001000f,0.000000f,-2.997000f,2.001000f,-0.000000f,-2.997000f,6.003000f,0.002697f,-2.997000f,2.001000f,1.515748f,-2.997000f,-2.001000f,1.515748f,-2.997000f,2.001000f,1.515748f,-6.003000f,2.001000f,1.515748f,-6.003000f,2.001000f,1.515748f,-6.003000f,-2.001000f,1.515748f,-2.997000f,-2.001000f,1.515748f,-2.997000f,-1.748874f,1.237951f,-2.997000f,1.748874f,1.237951f,-2.997000f,2.001000f,1.515748f,-2.997000f,-1.748874f,1.237951f,-2.997000f,2.001000f,1.515748f,-2.997000f,-2.001000f,1.515748f,-6.003000f,-1.748874f,1.237951f,-6.003000f,-1.748874f,0.000000f,-6.003000f,-2.001000f,0.000000f,-6.003000f,-1.748874f,1.237951f,-6.003000f,-2.001000f,0.000000f,-6.003000f,-2.001000f,1.515748f,-2.997000f,-2.001000f,1.515748f,-2.997000f,-2.001000f,0.000000f,-2.997000f,-1.748874f,1.237951f,-2.997000f,-2.001000f,0.000000f,-2.997000f,-1.748874f,0.000000f,-2.997000f,-1.748874f,1.237951f,-6.003000f,1.748874f,1.237951f,-6.003000f,2.001000f,1.515748f,-6.003000f,2.001000f,-0.000000f,-6.003000f,1.748874f,1.237951f,-6.003000f,2.001000f,-0.000000f,-6.003000f,1.748874f,-0.000000f,-6.003000f,1.748874f,1.237951f,-6.003000f,-1.748874f,1.237951f,-6.003000f,-2.001000f,1.515748f,-6.003000f,1.748874f,1.237951f,-6.003000f,-2.001000f,1.515748f,-6.003000f,2.001000f,1.515748f,-6.003000f,1.748874f,1.237951f,-6.003000f,1.748874f,-0.000000f,-2.997000f,1.748874f,1.237951f,-6.003000f,1.748874f,-0.000000f,-2.997000f,1.748874f,-0.000000f,-2.997000f,1.748874f,1.237951f,-6.003000f,1.748874f,-0.000000f,-6.003000f,-1.748874f,0.000000f,-2.997000f,-1.748874f,0.000000f,-6.003000f,1.748874f,-0.000000f,-2.997000f,-1.748874f,0.000000f,-2.997000f,1.748874f,-0.000000f,-6.003000f,-1.748874f,0.000000f,-6.003000f,-1.748874f,1.237951f,-2.997000f,-1.748874f,1.237951f,-2.997000f,-1.748874f,1.237951f,-2.997000f,-1.748874f,0.000000f,-6.003000f,-1.748874f,0.000000f,-6.003000f,-1.748874f,1.237951f,-6.003000f,1.748874f,1.237951f,-2.997000f,-1.748874f,1.237951f,-6.003000f,1.748874f,1.237951f,-2.997000f,1.748874f,1.237951f,-2.997000f,-1.748874f,1.237951f}; + +static float world_normals[] = {0.000000f,-1.000000f,0.000000f,-0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,-0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000225f,0.000161f,1.000000f,0.000225f,-0.000161f,1.000000f,0.000000f,0.000000f,1.000000f,0.000225f,0.000161f,1.000000f,0.000000f,0.000000f,1.000000f,-0.000000f,0.000000f,1.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,-0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,-0.000000f,-1.000000f,0.000000f,0.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,-0.000000f,-1.000000f,0.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,-0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,-0.000000f,0.000000f,1.000000f,0.000787f,0.000337f,1.000000f,0.000225f,-0.000161f,1.000000f,-0.000000f,0.000000f,1.000000f,0.000225f,-0.000161f,1.000000f,0.000000f,0.000000f,1.000000f,0.000787f,0.000337f,1.000000f,0.000400f,-0.179805f,0.983702f,0.000225f,-0.000161f,1.000000f,0.000225f,0.000161f,1.000000f,0.000787f,-0.000337f,1.000000f,0.000000f,0.000000f,1.000000f,0.000225f,0.000161f,1.000000f,0.000000f,0.000000f,1.000000f,0.000225f,-0.000161f,1.000000f,0.000787f,-0.000337f,1.000000f,0.000225f,0.000161f,1.000000f,0.000532f,0.119686f,0.992812f,-0.000320f,0.143927f,0.989588f,0.000532f,0.119686f,0.992812f,0.000225f,0.000161f,1.000000f,0.000225f,0.000161f,1.000000f,-0.000393f,0.000056f,1.000000f,-0.000320f,0.143927f,0.989588f,-0.000000f,0.000000f,1.000000f,-0.000315f,-0.000045f,1.000000f,0.000000f,0.000000f,1.000000f,-0.000787f,-0.000337f,1.000000f,-0.000320f,0.143927f,0.989588f,-0.000393f,0.000056f,1.000000f,-0.000393f,0.000056f,1.000000f,-0.000000f,0.000000f,1.000000f,-0.000787f,-0.000337f,1.000000f,-0.000393f,0.000056f,1.000000f,-0.000315f,-0.000045f,1.000000f,-0.000000f,0.000000f,1.000000f,-0.000315f,-0.000045f,1.000000f,-0.000398f,-0.089784f,0.995961f,-0.000787f,0.000337f,1.000000f,-0.000315f,-0.000045f,1.000000f,-0.000787f,0.000337f,1.000000f,0.000000f,0.000000f,1.000000f,-0.000398f,-0.089784f,0.995961f,-0.000315f,-0.000045f,1.000000f,0.000225f,-0.000161f,1.000000f,-0.000398f,-0.089784f,0.995961f,0.000225f,-0.000161f,1.000000f,0.000400f,-0.179805f,0.983702f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,0.000000f,-0.239222f,0.970965f,-0.000398f,-0.089784f,0.995961f,0.000400f,-0.179805f,0.983702f,0.000000f,-0.239222f,0.970965f,0.000400f,-0.179805f,0.983702f,0.000000f,-0.119611f,0.992821f,0.000000f,0.239222f,0.970965f,0.000532f,0.119686f,0.992812f,-0.000320f,0.143927f,0.989588f,-0.000320f,0.143927f,0.989588f,0.000000f,0.119611f,0.992821f,0.000000f,0.239222f,0.970965f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,0.000000f,-0.119611f,0.992821f,0.000000f,0.239222f,0.970965f,0.000000f,0.119611f,0.992821f,0.000000f,0.119611f,0.992821f,0.000000f,-0.239222f,0.970965f,0.000000f,-0.119611f,0.992821f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,-0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,-0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,-0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,-0.000000f,0.000000f,1.000000f,-0.000000f,0.000000f,1.000000f,-0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,1.000000f,0.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f,0.000000f,0.000000f,-1.000000f}; + + +static dTriIndex world_indices[] = {0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227}; + diff --git a/libs/ode-0.16.1/ode/doc/Doxyfile.in b/libs/ode-0.16.1/ode/doc/Doxyfile.in new file mode 100644 index 0000000..bfb9412 --- /dev/null +++ b/libs/ode-0.16.1/ode/doc/Doxyfile.in @@ -0,0 +1,2331 @@ +# Doxyfile 1.8.5 + +# This file describes the settings to be used by the documentation system +# doxygen (www.doxygen.org) for a project. +# +# All text after a double hash (##) is considered a comment and is placed in +# front of the TAG it is preceding. +# +# All text after a single hash (#) is considered a comment and will be ignored. +# The format is: +# TAG = value [value, ...] +# For lists, items can also be appended using: +# TAG += value [value, ...] +# Values that contain spaces should be placed between quotes (\" \"). + +#--------------------------------------------------------------------------- +# Project related configuration options +#--------------------------------------------------------------------------- + +# This tag specifies the encoding used for all characters in the config file +# that follow. The default is UTF-8 which is also the encoding used for all text +# before the first occurrence of this tag. Doxygen uses libiconv (or the iconv +# built into libc) for the transcoding. See http://www.gnu.org/software/libiconv +# for the list of possible encodings. +# The default value is: UTF-8. + +DOXYFILE_ENCODING = UTF-8 + +# The PROJECT_NAME tag is a single word (or a sequence of words surrounded by +# double-quotes, unless you are using Doxywizard) that should identify the +# project for which the documentation is generated. This name is used in the +# title of most generated pages and in a few other places. +# The default value is: My Project. + +PROJECT_NAME = ODE + +# The PROJECT_NUMBER tag can be used to enter a project or revision number. This +# could be handy for archiving the generated documentation or if some version +# control system is used. + +PROJECT_NUMBER = @ODE_VERSION@ + +# Using the PROJECT_BRIEF tag one can provide an optional one line description +# for a project that appears at the top of each page and should give viewer a +# quick idea about the purpose of the project. Keep the description short. + +PROJECT_BRIEF = + +# With the PROJECT_LOGO tag one can specify an logo or icon that is included in +# the documentation. The maximum height of the logo should not exceed 55 pixels +# and the maximum width should not exceed 200 pixels. Doxygen will copy the logo +# to the output directory. + +PROJECT_LOGO = @top_srcdir@/web/ODElogo.png + +# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) path +# into which the generated documentation will be written. If a relative path is +# entered, it will be relative to the location where doxygen was started. If +# left blank the current directory will be used. + +OUTPUT_DIRECTORY = + +# If the CREATE_SUBDIRS tag is set to YES, then doxygen will create 4096 sub- +# directories (in 2 levels) under the output directory of each output format and +# will distribute the generated files over these directories. Enabling this +# option can be useful when feeding doxygen a huge amount of source files, where +# putting all generated files in the same directory would otherwise causes +# performance problems for the file system. +# The default value is: NO. + +CREATE_SUBDIRS = NO + +# The OUTPUT_LANGUAGE tag is used to specify the language in which all +# documentation generated by doxygen is written. Doxygen will use this +# information to generate all constant output in the proper language. +# Possible values are: Afrikaans, Arabic, Brazilian, Catalan, Chinese, Chinese- +# Traditional, Croatian, Czech, Danish, Dutch, English, Esperanto, Farsi, +# Finnish, French, German, Greek, Hungarian, Italian, Japanese, Japanese-en, +# Korean, Korean-en, Latvian, Norwegian, Macedonian, Persian, Polish, +# Portuguese, Romanian, Russian, Serbian, Slovak, Slovene, Spanish, Swedish, +# Turkish, Ukrainian and Vietnamese. +# The default value is: English. + +OUTPUT_LANGUAGE = English + +# If the BRIEF_MEMBER_DESC tag is set to YES doxygen will include brief member +# descriptions after the members that are listed in the file and class +# documentation (similar to Javadoc). Set to NO to disable this. +# The default value is: YES. + +BRIEF_MEMBER_DESC = YES + +# If the REPEAT_BRIEF tag is set to YES doxygen will prepend the brief +# description of a member or function before the detailed description +# +# Note: If both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the +# brief descriptions will be completely suppressed. +# The default value is: YES. + +REPEAT_BRIEF = YES + +# This tag implements a quasi-intelligent brief description abbreviator that is +# used to form the text in various listings. Each string in this list, if found +# as the leading text of the brief description, will be stripped from the text +# and the result, after processing the whole list, is used as the annotated +# text. Otherwise, the brief description is used as-is. If left blank, the +# following values are used ($name is automatically replaced with the name of +# the entity):The $name class, The $name widget, The $name file, is, provides, +# specifies, contains, represents, a, an and the. + +ABBREVIATE_BRIEF = "The $name class" \ + "The $name widget" \ + "The $name file" \ + is \ + provides \ + specifies \ + contains \ + represents \ + a \ + an \ + the + +# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then +# doxygen will generate a detailed section even if there is only a brief +# description. +# The default value is: NO. + +ALWAYS_DETAILED_SEC = NO + +# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all +# inherited members of a class in the documentation of that class as if those +# members were ordinary class members. Constructors, destructors and assignment +# operators of the base classes will not be shown. +# The default value is: NO. + +INLINE_INHERITED_MEMB = NO + +# If the FULL_PATH_NAMES tag is set to YES doxygen will prepend the full path +# before files name in the file list and in the header files. If set to NO the +# shortest path that makes the file name unique will be used +# The default value is: YES. + +FULL_PATH_NAMES = YES + +# The STRIP_FROM_PATH tag can be used to strip a user-defined part of the path. +# Stripping is only done if one of the specified strings matches the left-hand +# part of the path. The tag can be used to show relative paths in the file list. +# If left blank the directory from which doxygen is run is used as the path to +# strip. +# +# Note that you can specify absolute paths here, but also relative paths, which +# will be relative from the directory where doxygen is started. +# This tag requires that the tag FULL_PATH_NAMES is set to YES. + +STRIP_FROM_PATH = + +# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of the +# path mentioned in the documentation of a class, which tells the reader which +# header file to include in order to use a class. If left blank only the name of +# the header file containing the class definition is used. Otherwise one should +# specify the list of include paths that are normally passed to the compiler +# using the -I flag. + +STRIP_FROM_INC_PATH = + +# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter (but +# less readable) file names. This can be useful is your file systems doesn't +# support long names like on DOS, Mac, or CD-ROM. +# The default value is: NO. + +SHORT_NAMES = NO + +# If the JAVADOC_AUTOBRIEF tag is set to YES then doxygen will interpret the +# first line (until the first dot) of a Javadoc-style comment as the brief +# description. If set to NO, the Javadoc-style will behave just like regular Qt- +# style comments (thus requiring an explicit @brief command for a brief +# description.) +# The default value is: NO. + +JAVADOC_AUTOBRIEF = NO + +# If the QT_AUTOBRIEF tag is set to YES then doxygen will interpret the first +# line (until the first dot) of a Qt-style comment as the brief description. If +# set to NO, the Qt-style will behave just like regular Qt-style comments (thus +# requiring an explicit \brief command for a brief description.) +# The default value is: NO. + +QT_AUTOBRIEF = NO + +# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make doxygen treat a +# multi-line C++ special comment block (i.e. a block of //! or /// comments) as +# a brief description. This used to be the default behavior. The new default is +# to treat a multi-line C++ comment block as a detailed description. Set this +# tag to YES if you prefer the old behavior instead. +# +# Note that setting this tag to YES also means that rational rose comments are +# not recognized any more. +# The default value is: NO. + +MULTILINE_CPP_IS_BRIEF = NO + +# If the INHERIT_DOCS tag is set to YES then an undocumented member inherits the +# documentation from any documented member that it re-implements. +# The default value is: YES. + +INHERIT_DOCS = YES + +# If the SEPARATE_MEMBER_PAGES tag is set to YES, then doxygen will produce a +# new page for each member. If set to NO, the documentation of a member will be +# part of the file/class/namespace that contains it. +# The default value is: NO. + +SEPARATE_MEMBER_PAGES = NO + +# The TAB_SIZE tag can be used to set the number of spaces in a tab. Doxygen +# uses this value to replace tabs by spaces in code fragments. +# Minimum value: 1, maximum value: 16, default value: 4. + +TAB_SIZE = 4 + +# This tag can be used to specify a number of aliases that act as commands in +# the documentation. An alias has the form: +# name=value +# For example adding +# "sideeffect=@par Side Effects:\n" +# will allow you to put the command \sideeffect (or @sideeffect) in the +# documentation, which will result in a user-defined paragraph with heading +# "Side Effects:". You can put \n's in the value part of an alias to insert +# newlines. + +ALIASES = + +# This tag can be used to specify a number of word-keyword mappings (TCL only). +# A mapping has the form "name=value". For example adding "class=itcl::class" +# will allow you to use the command class in the itcl::class meaning. + +TCL_SUBST = + +# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C sources +# only. Doxygen will then generate output that is more tailored for C. For +# instance, some of the names that are used will be different. The list of all +# members will be omitted, etc. +# The default value is: NO. + +OPTIMIZE_OUTPUT_FOR_C = YES + +# Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java or +# Python sources only. Doxygen will then generate output that is more tailored +# for that language. For instance, namespaces will be presented as packages, +# qualified scopes will look different, etc. +# The default value is: NO. + +OPTIMIZE_OUTPUT_JAVA = NO + +# Set the OPTIMIZE_FOR_FORTRAN tag to YES if your project consists of Fortran +# sources. Doxygen will then generate output that is tailored for Fortran. +# The default value is: NO. + +OPTIMIZE_FOR_FORTRAN = NO + +# Set the OPTIMIZE_OUTPUT_VHDL tag to YES if your project consists of VHDL +# sources. Doxygen will then generate output that is tailored for VHDL. +# The default value is: NO. + +OPTIMIZE_OUTPUT_VHDL = NO + +# Doxygen selects the parser to use depending on the extension of the files it +# parses. With this tag you can assign which parser to use for a given +# extension. Doxygen has a built-in mapping, but you can override or extend it +# using this tag. The format is ext=language, where ext is a file extension, and +# language is one of the parsers supported by doxygen: IDL, Java, Javascript, +# C#, C, C++, D, PHP, Objective-C, Python, Fortran, VHDL. For instance to make +# doxygen treat .inc files as Fortran files (default is PHP), and .f files as C +# (default is Fortran), use: inc=Fortran f=C. +# +# Note For files without extension you can use no_extension as a placeholder. +# +# Note that for custom extensions you also need to set FILE_PATTERNS otherwise +# the files are not read by doxygen. + +EXTENSION_MAPPING = + +# If the MARKDOWN_SUPPORT tag is enabled then doxygen pre-processes all comments +# according to the Markdown format, which allows for more readable +# documentation. See http://daringfireball.net/projects/markdown/ for details. +# The output of markdown processing is further processed by doxygen, so you can +# mix doxygen, HTML, and XML commands with Markdown formatting. Disable only in +# case of backward compatibilities issues. +# The default value is: YES. + +MARKDOWN_SUPPORT = YES + +# When enabled doxygen tries to link words that correspond to documented +# classes, or namespaces to their corresponding documentation. Such a link can +# be prevented in individual cases by by putting a % sign in front of the word +# or globally by setting AUTOLINK_SUPPORT to NO. +# The default value is: YES. + +AUTOLINK_SUPPORT = YES + +# If you use STL classes (i.e. std::string, std::vector, etc.) but do not want +# to include (a tag file for) the STL sources as input, then you should set this +# tag to YES in order to let doxygen match functions declarations and +# definitions whose arguments contain STL classes (e.g. func(std::string); +# versus func(std::string) {}). This also make the inheritance and collaboration +# diagrams that involve STL classes more complete and accurate. +# The default value is: NO. + +BUILTIN_STL_SUPPORT = NO + +# If you use Microsoft's C++/CLI language, you should set this option to YES to +# enable parsing support. +# The default value is: NO. + +CPP_CLI_SUPPORT = NO + +# Set the SIP_SUPPORT tag to YES if your project consists of sip (see: +# http://www.riverbankcomputing.co.uk/software/sip/intro) sources only. Doxygen +# will parse them like normal C++ but will assume all classes use public instead +# of private inheritance when no explicit protection keyword is present. +# The default value is: NO. + +SIP_SUPPORT = NO + +# For Microsoft's IDL there are propget and propput attributes to indicate +# getter and setter methods for a property. Setting this option to YES will make +# doxygen to replace the get and set methods by a property in the documentation. +# This will only work if the methods are indeed getting or setting a simple +# type. If this is not the case, or you want to show the methods anyway, you +# should set this option to NO. +# The default value is: YES. + +IDL_PROPERTY_SUPPORT = YES + +# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC +# tag is set to YES, then doxygen will reuse the documentation of the first +# member in the group (if any) for the other members of the group. By default +# all members of a group must be documented explicitly. +# The default value is: NO. + +DISTRIBUTE_GROUP_DOC = NO + +# Set the SUBGROUPING tag to YES to allow class member groups of the same type +# (for instance a group of public functions) to be put as a subgroup of that +# type (e.g. under the Public Functions section). Set it to NO to prevent +# subgrouping. Alternatively, this can be done per class using the +# \nosubgrouping command. +# The default value is: YES. + +SUBGROUPING = YES + +# When the INLINE_GROUPED_CLASSES tag is set to YES, classes, structs and unions +# are shown inside the group in which they are included (e.g. using \ingroup) +# instead of on a separate page (for HTML and Man pages) or section (for LaTeX +# and RTF). +# +# Note that this feature does not work in combination with +# SEPARATE_MEMBER_PAGES. +# The default value is: NO. + +INLINE_GROUPED_CLASSES = NO + +# When the INLINE_SIMPLE_STRUCTS tag is set to YES, structs, classes, and unions +# with only public data fields or simple typedef fields will be shown inline in +# the documentation of the scope in which they are defined (i.e. file, +# namespace, or group documentation), provided this scope is documented. If set +# to NO, structs, classes, and unions are shown on a separate page (for HTML and +# Man pages) or section (for LaTeX and RTF). +# The default value is: NO. + +INLINE_SIMPLE_STRUCTS = NO + +# When TYPEDEF_HIDES_STRUCT tag is enabled, a typedef of a struct, union, or +# enum is documented as struct, union, or enum with the name of the typedef. So +# typedef struct TypeS {} TypeT, will appear in the documentation as a struct +# with name TypeT. When disabled the typedef will appear as a member of a file, +# namespace, or class. And the struct will be named TypeS. This can typically be +# useful for C code in case the coding convention dictates that all compound +# types are typedef'ed and only the typedef is referenced, never the tag name. +# The default value is: NO. + +TYPEDEF_HIDES_STRUCT = NO + +# The size of the symbol lookup cache can be set using LOOKUP_CACHE_SIZE. This +# cache is used to resolve symbols given their name and scope. Since this can be +# an expensive process and often the same symbol appears multiple times in the +# code, doxygen keeps a cache of pre-resolved symbols. If the cache is too small +# doxygen will become slower. If the cache is too large, memory is wasted. The +# cache size is given by this formula: 2^(16+LOOKUP_CACHE_SIZE). The valid range +# is 0..9, the default is 0, corresponding to a cache size of 2^16=65536 +# symbols. At the end of a run doxygen will report the cache usage and suggest +# the optimal cache size from a speed point of view. +# Minimum value: 0, maximum value: 9, default value: 0. + +LOOKUP_CACHE_SIZE = 0 + +#--------------------------------------------------------------------------- +# Build related configuration options +#--------------------------------------------------------------------------- + +# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in +# documentation are documented, even if no documentation was available. Private +# class members and static file members will be hidden unless the +# EXTRACT_PRIVATE respectively EXTRACT_STATIC tags are set to YES. +# Note: This will also disable the warnings about undocumented members that are +# normally produced when WARNINGS is set to YES. +# The default value is: NO. + +EXTRACT_ALL = NO + +# If the EXTRACT_PRIVATE tag is set to YES all private members of a class will +# be included in the documentation. +# The default value is: NO. + +EXTRACT_PRIVATE = NO + +# If the EXTRACT_PACKAGE tag is set to YES all members with package or internal +# scope will be included in the documentation. +# The default value is: NO. + +EXTRACT_PACKAGE = NO + +# If the EXTRACT_STATIC tag is set to YES all static members of a file will be +# included in the documentation. +# The default value is: NO. + +EXTRACT_STATIC = NO + +# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) defined +# locally in source files will be included in the documentation. If set to NO +# only classes defined in header files are included. Does not have any effect +# for Java sources. +# The default value is: YES. + +EXTRACT_LOCAL_CLASSES = YES + +# This flag is only useful for Objective-C code. When set to YES local methods, +# which are defined in the implementation section but not in the interface are +# included in the documentation. If set to NO only methods in the interface are +# included. +# The default value is: NO. + +EXTRACT_LOCAL_METHODS = NO + +# If this flag is set to YES, the members of anonymous namespaces will be +# extracted and appear in the documentation as a namespace called +# 'anonymous_namespace{file}', where file will be replaced with the base name of +# the file that contains the anonymous namespace. By default anonymous namespace +# are hidden. +# The default value is: NO. + +EXTRACT_ANON_NSPACES = NO + +# If the HIDE_UNDOC_MEMBERS tag is set to YES, doxygen will hide all +# undocumented members inside documented classes or files. If set to NO these +# members will be included in the various overviews, but no documentation +# section is generated. This option has no effect if EXTRACT_ALL is enabled. +# The default value is: NO. + +HIDE_UNDOC_MEMBERS = NO + +# If the HIDE_UNDOC_CLASSES tag is set to YES, doxygen will hide all +# undocumented classes that are normally visible in the class hierarchy. If set +# to NO these classes will be included in the various overviews. This option has +# no effect if EXTRACT_ALL is enabled. +# The default value is: NO. + +HIDE_UNDOC_CLASSES = NO + +# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, doxygen will hide all friend +# (class|struct|union) declarations. If set to NO these declarations will be +# included in the documentation. +# The default value is: NO. + +HIDE_FRIEND_COMPOUNDS = NO + +# If the HIDE_IN_BODY_DOCS tag is set to YES, doxygen will hide any +# documentation blocks found inside the body of a function. If set to NO these +# blocks will be appended to the function's detailed documentation block. +# The default value is: NO. + +HIDE_IN_BODY_DOCS = NO + +# The INTERNAL_DOCS tag determines if documentation that is typed after a +# \internal command is included. If the tag is set to NO then the documentation +# will be excluded. Set it to YES to include the internal documentation. +# The default value is: NO. + +INTERNAL_DOCS = NO + +# If the CASE_SENSE_NAMES tag is set to NO then doxygen will only generate file +# names in lower-case letters. If set to YES upper-case letters are also +# allowed. This is useful if you have classes or files whose names only differ +# in case and if your file system supports case sensitive file names. Windows +# and Mac users are advised to set this option to NO. +# The default value is: system dependent. + +CASE_SENSE_NAMES = NO + +# If the HIDE_SCOPE_NAMES tag is set to NO then doxygen will show members with +# their full class and namespace scopes in the documentation. If set to YES the +# scope will be hidden. +# The default value is: NO. + +HIDE_SCOPE_NAMES = YES + +# If the SHOW_INCLUDE_FILES tag is set to YES then doxygen will put a list of +# the files that are included by a file in the documentation of that file. +# The default value is: YES. + +SHOW_INCLUDE_FILES = YES + +# If the FORCE_LOCAL_INCLUDES tag is set to YES then doxygen will list include +# files with double quotes in the documentation rather than with sharp brackets. +# The default value is: NO. + +FORCE_LOCAL_INCLUDES = NO + +# If the INLINE_INFO tag is set to YES then a tag [inline] is inserted in the +# documentation for inline members. +# The default value is: YES. + +INLINE_INFO = YES + +# If the SORT_MEMBER_DOCS tag is set to YES then doxygen will sort the +# (detailed) documentation of file and class members alphabetically by member +# name. If set to NO the members will appear in declaration order. +# The default value is: YES. + +SORT_MEMBER_DOCS = YES + +# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the brief +# descriptions of file, namespace and class members alphabetically by member +# name. If set to NO the members will appear in declaration order. +# The default value is: NO. + +SORT_BRIEF_DOCS = NO + +# If the SORT_MEMBERS_CTORS_1ST tag is set to YES then doxygen will sort the +# (brief and detailed) documentation of class members so that constructors and +# destructors are listed first. If set to NO the constructors will appear in the +# respective orders defined by SORT_BRIEF_DOCS and SORT_MEMBER_DOCS. +# Note: If SORT_BRIEF_DOCS is set to NO this option is ignored for sorting brief +# member documentation. +# Note: If SORT_MEMBER_DOCS is set to NO this option is ignored for sorting +# detailed member documentation. +# The default value is: NO. + +SORT_MEMBERS_CTORS_1ST = NO + +# If the SORT_GROUP_NAMES tag is set to YES then doxygen will sort the hierarchy +# of group names into alphabetical order. If set to NO the group names will +# appear in their defined order. +# The default value is: NO. + +SORT_GROUP_NAMES = NO + +# If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be sorted by +# fully-qualified names, including namespaces. If set to NO, the class list will +# be sorted only by class name, not including the namespace part. +# Note: This option is not very useful if HIDE_SCOPE_NAMES is set to YES. +# Note: This option applies only to the class list, not to the alphabetical +# list. +# The default value is: NO. + +SORT_BY_SCOPE_NAME = NO + +# If the STRICT_PROTO_MATCHING option is enabled and doxygen fails to do proper +# type resolution of all parameters of a function it will reject a match between +# the prototype and the implementation of a member function even if there is +# only one candidate or it is obvious which candidate to choose by doing a +# simple string match. By disabling STRICT_PROTO_MATCHING doxygen will still +# accept a match between prototype and implementation in such cases. +# The default value is: NO. + +STRICT_PROTO_MATCHING = NO + +# The GENERATE_TODOLIST tag can be used to enable ( YES) or disable ( NO) the +# todo list. This list is created by putting \todo commands in the +# documentation. +# The default value is: YES. + +GENERATE_TODOLIST = YES + +# The GENERATE_TESTLIST tag can be used to enable ( YES) or disable ( NO) the +# test list. This list is created by putting \test commands in the +# documentation. +# The default value is: YES. + +GENERATE_TESTLIST = YES + +# The GENERATE_BUGLIST tag can be used to enable ( YES) or disable ( NO) the bug +# list. This list is created by putting \bug commands in the documentation. +# The default value is: YES. + +GENERATE_BUGLIST = YES + +# The GENERATE_DEPRECATEDLIST tag can be used to enable ( YES) or disable ( NO) +# the deprecated list. This list is created by putting \deprecated commands in +# the documentation. +# The default value is: YES. + +GENERATE_DEPRECATEDLIST= YES + +# The ENABLED_SECTIONS tag can be used to enable conditional documentation +# sections, marked by \if ... \endif and \cond +# ... \endcond blocks. + +ENABLED_SECTIONS = + +# The MAX_INITIALIZER_LINES tag determines the maximum number of lines that the +# initial value of a variable or macro / define can have for it to appear in the +# documentation. If the initializer consists of more lines than specified here +# it will be hidden. Use a value of 0 to hide initializers completely. The +# appearance of the value of individual variables and macros / defines can be +# controlled using \showinitializer or \hideinitializer command in the +# documentation regardless of this setting. +# Minimum value: 0, maximum value: 10000, default value: 30. + +MAX_INITIALIZER_LINES = 30 + +# Set the SHOW_USED_FILES tag to NO to disable the list of files generated at +# the bottom of the documentation of classes and structs. If set to YES the list +# will mention the files that were used to generate the documentation. +# The default value is: YES. + +SHOW_USED_FILES = YES + +# Set the SHOW_FILES tag to NO to disable the generation of the Files page. This +# will remove the Files entry from the Quick Index and from the Folder Tree View +# (if specified). +# The default value is: YES. + +SHOW_FILES = YES + +# Set the SHOW_NAMESPACES tag to NO to disable the generation of the Namespaces +# page. This will remove the Namespaces entry from the Quick Index and from the +# Folder Tree View (if specified). +# The default value is: YES. + +SHOW_NAMESPACES = YES + +# The FILE_VERSION_FILTER tag can be used to specify a program or script that +# doxygen should invoke to get the current version for each file (typically from +# the version control system). Doxygen will invoke the program by executing (via +# popen()) the command command input-file, where command is the value of the +# FILE_VERSION_FILTER tag, and input-file is the name of an input file provided +# by doxygen. Whatever the program writes to standard output is used as the file +# version. For an example see the documentation. + +FILE_VERSION_FILTER = + +# The LAYOUT_FILE tag can be used to specify a layout file which will be parsed +# by doxygen. The layout file controls the global structure of the generated +# output files in an output format independent way. To create the layout file +# that represents doxygen's defaults, run doxygen with the -l option. You can +# optionally specify a file name after the option, if omitted DoxygenLayout.xml +# will be used as the name of the layout file. +# +# Note that if you run doxygen from a directory containing a file called +# DoxygenLayout.xml, doxygen will parse it automatically even if the LAYOUT_FILE +# tag is left empty. + +LAYOUT_FILE = + +# The CITE_BIB_FILES tag can be used to specify one or more bib files containing +# the reference definitions. This must be a list of .bib files. The .bib +# extension is automatically appended if omitted. This requires the bibtex tool +# to be installed. See also http://en.wikipedia.org/wiki/BibTeX for more info. +# For LaTeX the style of the bibliography can be controlled using +# LATEX_BIB_STYLE. To use this feature you need bibtex and perl available in the +# search path. Do not use file names with spaces, bibtex cannot handle them. See +# also \cite for info how to create references. + +CITE_BIB_FILES = + +#--------------------------------------------------------------------------- +# Configuration options related to warning and progress messages +#--------------------------------------------------------------------------- + +# The QUIET tag can be used to turn on/off the messages that are generated to +# standard output by doxygen. If QUIET is set to YES this implies that the +# messages are off. +# The default value is: NO. + +QUIET = NO + +# The WARNINGS tag can be used to turn on/off the warning messages that are +# generated to standard error ( stderr) by doxygen. If WARNINGS is set to YES +# this implies that the warnings are on. +# +# Tip: Turn warnings on while writing the documentation. +# The default value is: YES. + +WARNINGS = YES + +# If the WARN_IF_UNDOCUMENTED tag is set to YES, then doxygen will generate +# warnings for undocumented members. If EXTRACT_ALL is set to YES then this flag +# will automatically be disabled. +# The default value is: YES. + +WARN_IF_UNDOCUMENTED = YES + +# If the WARN_IF_DOC_ERROR tag is set to YES, doxygen will generate warnings for +# potential errors in the documentation, such as not documenting some parameters +# in a documented function, or documenting parameters that don't exist or using +# markup commands wrongly. +# The default value is: YES. + +WARN_IF_DOC_ERROR = YES + +# This WARN_NO_PARAMDOC option can be enabled to get warnings for functions that +# are documented, but have no documentation for their parameters or return +# value. If set to NO doxygen will only warn about wrong or incomplete parameter +# documentation, but not about the absence of documentation. +# The default value is: NO. + +WARN_NO_PARAMDOC = NO + +# The WARN_FORMAT tag determines the format of the warning messages that doxygen +# can produce. The string should contain the $file, $line, and $text tags, which +# will be replaced by the file and line number from which the warning originated +# and the warning text. Optionally the format may contain $version, which will +# be replaced by the version of the file (if it could be obtained via +# FILE_VERSION_FILTER) +# The default value is: $file:$line: $text. + +WARN_FORMAT = "$file:$line: $text" + +# The WARN_LOGFILE tag can be used to specify a file to which warning and error +# messages should be written. If left blank the output is written to standard +# error (stderr). + +WARN_LOGFILE = + +#--------------------------------------------------------------------------- +# Configuration options related to the input files +#--------------------------------------------------------------------------- + +# The INPUT tag is used to specify the files and/or directories that contain +# documented source files. You may enter file names like myfile.cpp or +# directories like /usr/src/myproject. Separate the files or directories with +# spaces. +# Note: If this tag is empty the current directory is searched. + +INPUT = @top_srcdir@/include/ode @top_builddir@/include/ode + +# This tag can be used to specify the character encoding of the source files +# that doxygen parses. Internally doxygen uses the UTF-8 encoding. Doxygen uses +# libiconv (or the iconv built into libc) for the transcoding. See the libiconv +# documentation (see: http://www.gnu.org/software/libiconv) for the list of +# possible encodings. +# The default value is: UTF-8. + +INPUT_ENCODING = UTF-8 + +# If the value of the INPUT tag contains directories, you can use the +# FILE_PATTERNS tag to specify one or more wildcard patterns (like *.cpp and +# *.h) to filter out the source-files in the directories. If left blank the +# following patterns are tested:*.c, *.cc, *.cxx, *.cpp, *.c++, *.java, *.ii, +# *.ixx, *.ipp, *.i++, *.inl, *.idl, *.ddl, *.odl, *.h, *.hh, *.hxx, *.hpp, +# *.h++, *.cs, *.d, *.php, *.php4, *.php5, *.phtml, *.inc, *.m, *.markdown, +# *.md, *.mm, *.dox, *.py, *.f90, *.f, *.for, *.tcl, *.vhd, *.vhdl, *.ucf, +# *.qsf, *.as and *.js. + +FILE_PATTERNS = *.c \ + *.cc \ + *.cxx \ + *.cpp \ + *.c++ \ + *.java \ + *.ii \ + *.ixx \ + *.ipp \ + *.i++ \ + *.inl \ + *.idl \ + *.ddl \ + *.odl \ + *.h \ + *.hh \ + *.hxx \ + *.hpp \ + *.h++ \ + *.cs \ + *.d \ + *.php \ + *.php4 \ + *.php5 \ + *.phtml \ + *.inc \ + *.m \ + *.markdown \ + *.md \ + *.mm \ + *.dox \ + *.py \ + *.f90 \ + *.f \ + *.for \ + *.tcl \ + *.vhd \ + *.vhdl \ + *.ucf \ + *.qsf \ + *.as \ + *.js + +# The RECURSIVE tag can be used to specify whether or not subdirectories should +# be searched for input files as well. +# The default value is: NO. + +RECURSIVE = NO + +# The EXCLUDE tag can be used to specify files and/or directories that should be +# excluded from the INPUT source files. This way you can easily exclude a +# subdirectory from a directory tree whose root is specified with the INPUT tag. +# +# Note that relative paths are relative to the directory from which doxygen is +# run. + +EXCLUDE = + +# The EXCLUDE_SYMLINKS tag can be used to select whether or not files or +# directories that are symbolic links (a Unix file system feature) are excluded +# from the input. +# The default value is: NO. + +EXCLUDE_SYMLINKS = NO + +# If the value of the INPUT tag contains directories, you can use the +# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude +# certain files from those directories. +# +# Note that the wildcards are matched against the file with absolute path, so to +# exclude all test directories for example use the pattern */test/* + +EXCLUDE_PATTERNS = + +# The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names +# (namespaces, classes, functions, etc.) that should be excluded from the +# output. The symbol name can be a fully qualified name, a word, or if the +# wildcard * is used, a substring. Examples: ANamespace, AClass, +# AClass::ANamespace, ANamespace::*Test +# +# Note that the wildcards are matched against the file with absolute path, so to +# exclude all test directories use the pattern */test/* + +EXCLUDE_SYMBOLS = ODE_API + +# The EXAMPLE_PATH tag can be used to specify one or more files or directories +# that contain example code fragments that are included (see the \include +# command). + +EXAMPLE_PATH = + +# If the value of the EXAMPLE_PATH tag contains directories, you can use the +# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp and +# *.h) to filter out the source-files in the directories. If left blank all +# files are included. + +EXAMPLE_PATTERNS = * + +# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be +# searched for input files to be used with the \include or \dontinclude commands +# irrespective of the value of the RECURSIVE tag. +# The default value is: NO. + +EXAMPLE_RECURSIVE = NO + +# The IMAGE_PATH tag can be used to specify one or more files or directories +# that contain images that are to be included in the documentation (see the +# \image command). + +IMAGE_PATH = + +# The INPUT_FILTER tag can be used to specify a program that doxygen should +# invoke to filter for each input file. Doxygen will invoke the filter program +# by executing (via popen()) the command: +# +# +# +# where is the value of the INPUT_FILTER tag, and is the +# name of an input file. Doxygen will then use the output that the filter +# program writes to standard output. If FILTER_PATTERNS is specified, this tag +# will be ignored. +# +# Note that the filter must not add or remove lines; it is applied before the +# code is scanned, but not when the output code is generated. If lines are added +# or removed, the anchors will not be placed correctly. + +INPUT_FILTER = + +# The FILTER_PATTERNS tag can be used to specify filters on a per file pattern +# basis. Doxygen will compare the file name with each pattern and apply the +# filter if there is a match. The filters are a list of the form: pattern=filter +# (like *.cpp=my_cpp_filter). See INPUT_FILTER for further information on how +# filters are used. If the FILTER_PATTERNS tag is empty or if none of the +# patterns match the file name, INPUT_FILTER is applied. + +FILTER_PATTERNS = + +# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using +# INPUT_FILTER ) will also be used to filter the input files that are used for +# producing the source files to browse (i.e. when SOURCE_BROWSER is set to YES). +# The default value is: NO. + +FILTER_SOURCE_FILES = NO + +# The FILTER_SOURCE_PATTERNS tag can be used to specify source filters per file +# pattern. A pattern will override the setting for FILTER_PATTERN (if any) and +# it is also possible to disable source filtering for a specific pattern using +# *.ext= (so without naming a filter). +# This tag requires that the tag FILTER_SOURCE_FILES is set to YES. + +FILTER_SOURCE_PATTERNS = + +# If the USE_MDFILE_AS_MAINPAGE tag refers to the name of a markdown file that +# is part of the input, its contents will be placed on the main page +# (index.html). This can be useful if you have a project on for instance GitHub +# and want to reuse the introduction page also for the doxygen output. + +USE_MDFILE_AS_MAINPAGE = + +#--------------------------------------------------------------------------- +# Configuration options related to source browsing +#--------------------------------------------------------------------------- + +# If the SOURCE_BROWSER tag is set to YES then a list of source files will be +# generated. Documented entities will be cross-referenced with these sources. +# +# Note: To get rid of all source code in the generated output, make sure that +# also VERBATIM_HEADERS is set to NO. +# The default value is: NO. + +SOURCE_BROWSER = NO + +# Setting the INLINE_SOURCES tag to YES will include the body of functions, +# classes and enums directly into the documentation. +# The default value is: NO. + +INLINE_SOURCES = NO + +# Setting the STRIP_CODE_COMMENTS tag to YES will instruct doxygen to hide any +# special comment blocks from generated source code fragments. Normal C, C++ and +# Fortran comments will always remain visible. +# The default value is: YES. + +STRIP_CODE_COMMENTS = YES + +# If the REFERENCED_BY_RELATION tag is set to YES then for each documented +# function all documented functions referencing it will be listed. +# The default value is: NO. + +REFERENCED_BY_RELATION = NO + +# If the REFERENCES_RELATION tag is set to YES then for each documented function +# all documented entities called/used by that function will be listed. +# The default value is: NO. + +REFERENCES_RELATION = NO + +# If the REFERENCES_LINK_SOURCE tag is set to YES and SOURCE_BROWSER tag is set +# to YES, then the hyperlinks from functions in REFERENCES_RELATION and +# REFERENCED_BY_RELATION lists will link to the source code. Otherwise they will +# link to the documentation. +# The default value is: YES. + +REFERENCES_LINK_SOURCE = YES + +# If SOURCE_TOOLTIPS is enabled (the default) then hovering a hyperlink in the +# source code will show a tooltip with additional information such as prototype, +# brief description and links to the definition and documentation. Since this +# will make the HTML file larger and loading of large files a bit slower, you +# can opt to disable this feature. +# The default value is: YES. +# This tag requires that the tag SOURCE_BROWSER is set to YES. + +SOURCE_TOOLTIPS = YES + +# If the USE_HTAGS tag is set to YES then the references to source code will +# point to the HTML generated by the htags(1) tool instead of doxygen built-in +# source browser. The htags tool is part of GNU's global source tagging system +# (see http://www.gnu.org/software/global/global.html). You will need version +# 4.8.6 or higher. +# +# To use it do the following: +# - Install the latest version of global +# - Enable SOURCE_BROWSER and USE_HTAGS in the config file +# - Make sure the INPUT points to the root of the source tree +# - Run doxygen as normal +# +# Doxygen will invoke htags (and that will in turn invoke gtags), so these +# tools must be available from the command line (i.e. in the search path). +# +# The result: instead of the source browser generated by doxygen, the links to +# source code will now point to the output of htags. +# The default value is: NO. +# This tag requires that the tag SOURCE_BROWSER is set to YES. + +USE_HTAGS = NO + +# If the VERBATIM_HEADERS tag is set the YES then doxygen will generate a +# verbatim copy of the header file for each class for which an include is +# specified. Set to NO to disable this. +# See also: Section \class. +# The default value is: YES. + +VERBATIM_HEADERS = YES + +#--------------------------------------------------------------------------- +# Configuration options related to the alphabetical class index +#--------------------------------------------------------------------------- + +# If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index of all +# compounds will be generated. Enable this if the project contains a lot of +# classes, structs, unions or interfaces. +# The default value is: YES. + +ALPHABETICAL_INDEX = YES + +# The COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns in +# which the alphabetical index list will be split. +# Minimum value: 1, maximum value: 20, default value: 5. +# This tag requires that the tag ALPHABETICAL_INDEX is set to YES. + +COLS_IN_ALPHA_INDEX = 5 + +# In case all classes in a project start with a common prefix, all classes will +# be put under the same header in the alphabetical index. The IGNORE_PREFIX tag +# can be used to specify a prefix (or a list of prefixes) that should be ignored +# while generating the index headers. +# This tag requires that the tag ALPHABETICAL_INDEX is set to YES. + +IGNORE_PREFIX = d + +#--------------------------------------------------------------------------- +# Configuration options related to the HTML output +#--------------------------------------------------------------------------- + +# If the GENERATE_HTML tag is set to YES doxygen will generate HTML output +# The default value is: YES. + +GENERATE_HTML = YES + +# The HTML_OUTPUT tag is used to specify where the HTML docs will be put. If a +# relative path is entered the value of OUTPUT_DIRECTORY will be put in front of +# it. +# The default directory is: html. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_OUTPUT = html + +# The HTML_FILE_EXTENSION tag can be used to specify the file extension for each +# generated HTML page (for example: .htm, .php, .asp). +# The default value is: .html. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_FILE_EXTENSION = .html + +# The HTML_HEADER tag can be used to specify a user-defined HTML header file for +# each generated HTML page. If the tag is left blank doxygen will generate a +# standard header. +# +# To get valid HTML the header file that includes any scripts and style sheets +# that doxygen needs, which is dependent on the configuration options used (e.g. +# the setting GENERATE_TREEVIEW). It is highly recommended to start with a +# default header using +# doxygen -w html new_header.html new_footer.html new_stylesheet.css +# YourConfigFile +# and then modify the file new_header.html. See also section "Doxygen usage" +# for information on how to generate the default header that doxygen normally +# uses. +# Note: The header is subject to change so you typically have to regenerate the +# default header when upgrading to a newer version of doxygen. For a description +# of the possible markers and block names see the documentation. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_HEADER = + +# The HTML_FOOTER tag can be used to specify a user-defined HTML footer for each +# generated HTML page. If the tag is left blank doxygen will generate a standard +# footer. See HTML_HEADER for more information on how to generate a default +# footer and what special commands can be used inside the footer. See also +# section "Doxygen usage" for information on how to generate the default footer +# that doxygen normally uses. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_FOOTER = + +# The HTML_STYLESHEET tag can be used to specify a user-defined cascading style +# sheet that is used by each HTML page. It can be used to fine-tune the look of +# the HTML output. If left blank doxygen will generate a default style sheet. +# See also section "Doxygen usage" for information on how to generate the style +# sheet that doxygen normally uses. +# Note: It is recommended to use HTML_EXTRA_STYLESHEET instead of this tag, as +# it is more robust and this tag (HTML_STYLESHEET) will in the future become +# obsolete. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_STYLESHEET = + +# The HTML_EXTRA_STYLESHEET tag can be used to specify an additional user- +# defined cascading style sheet that is included after the standard style sheets +# created by doxygen. Using this option one can overrule certain style aspects. +# This is preferred over using HTML_STYLESHEET since it does not replace the +# standard style sheet and is therefor more robust against future updates. +# Doxygen will copy the style sheet file to the output directory. For an example +# see the documentation. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_EXTRA_STYLESHEET = + +# The HTML_EXTRA_FILES tag can be used to specify one or more extra images or +# other source files which should be copied to the HTML output directory. Note +# that these files will be copied to the base HTML output directory. Use the +# $relpath^ marker in the HTML_HEADER and/or HTML_FOOTER files to load these +# files. In the HTML_STYLESHEET file, use the file name only. Also note that the +# files will be copied as-is; there are no commands or markers available. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_EXTRA_FILES = + +# The HTML_COLORSTYLE_HUE tag controls the color of the HTML output. Doxygen +# will adjust the colors in the stylesheet and background images according to +# this color. Hue is specified as an angle on a colorwheel, see +# http://en.wikipedia.org/wiki/Hue for more information. For instance the value +# 0 represents red, 60 is yellow, 120 is green, 180 is cyan, 240 is blue, 300 +# purple, and 360 is red again. +# Minimum value: 0, maximum value: 359, default value: 220. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_COLORSTYLE_HUE = 243 + +# The HTML_COLORSTYLE_SAT tag controls the purity (or saturation) of the colors +# in the HTML output. For a value of 0 the output will use grayscales only. A +# value of 255 will produce the most vivid colors. +# Minimum value: 0, maximum value: 255, default value: 100. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_COLORSTYLE_SAT = 187 + +# The HTML_COLORSTYLE_GAMMA tag controls the gamma correction applied to the +# luminance component of the colors in the HTML output. Values below 100 +# gradually make the output lighter, whereas values above 100 make the output +# darker. The value divided by 100 is the actual gamma applied, so 80 represents +# a gamma of 0.8, The value 220 represents a gamma of 2.2, and 100 does not +# change the gamma. +# Minimum value: 40, maximum value: 240, default value: 80. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_COLORSTYLE_GAMMA = 92 + +# If the HTML_TIMESTAMP tag is set to YES then the footer of each generated HTML +# page will contain the date and time when the page was generated. Setting this +# to NO can help when comparing the output of multiple runs. +# The default value is: YES. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_TIMESTAMP = YES + +# If the HTML_DYNAMIC_SECTIONS tag is set to YES then the generated HTML +# documentation will contain sections that can be hidden and shown after the +# page has loaded. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_DYNAMIC_SECTIONS = NO + +# With HTML_INDEX_NUM_ENTRIES one can control the preferred number of entries +# shown in the various tree structured indices initially; the user can expand +# and collapse entries dynamically later on. Doxygen will expand the tree to +# such a level that at most the specified number of entries are visible (unless +# a fully collapsed tree already exceeds this amount). So setting the number of +# entries 1 will produce a full collapsed tree by default. 0 is a special value +# representing an infinite number of entries and will result in a full expanded +# tree by default. +# Minimum value: 0, maximum value: 9999, default value: 100. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_INDEX_NUM_ENTRIES = 100 + +# If the GENERATE_DOCSET tag is set to YES, additional index files will be +# generated that can be used as input for Apple's Xcode 3 integrated development +# environment (see: http://developer.apple.com/tools/xcode/), introduced with +# OSX 10.5 (Leopard). To create a documentation set, doxygen will generate a +# Makefile in the HTML output directory. Running make will produce the docset in +# that directory and running make install will install the docset in +# ~/Library/Developer/Shared/Documentation/DocSets so that Xcode will find it at +# startup. See http://developer.apple.com/tools/creatingdocsetswithdoxygen.html +# for more information. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +GENERATE_DOCSET = NO + +# This tag determines the name of the docset feed. A documentation feed provides +# an umbrella under which multiple documentation sets from a single provider +# (such as a company or product suite) can be grouped. +# The default value is: Doxygen generated docs. +# This tag requires that the tag GENERATE_DOCSET is set to YES. + +DOCSET_FEEDNAME = "Doxygen generated docs" + +# This tag specifies a string that should uniquely identify the documentation +# set bundle. This should be a reverse domain-name style string, e.g. +# com.mycompany.MyDocSet. Doxygen will append .docset to the name. +# The default value is: org.doxygen.Project. +# This tag requires that the tag GENERATE_DOCSET is set to YES. + +DOCSET_BUNDLE_ID = org.doxygen.Project + +# The DOCSET_PUBLISHER_ID tag specifies a string that should uniquely identify +# the documentation publisher. This should be a reverse domain-name style +# string, e.g. com.mycompany.MyDocSet.documentation. +# The default value is: org.doxygen.Publisher. +# This tag requires that the tag GENERATE_DOCSET is set to YES. + +DOCSET_PUBLISHER_ID = org.doxygen.Publisher + +# The DOCSET_PUBLISHER_NAME tag identifies the documentation publisher. +# The default value is: Publisher. +# This tag requires that the tag GENERATE_DOCSET is set to YES. + +DOCSET_PUBLISHER_NAME = Publisher + +# If the GENERATE_HTMLHELP tag is set to YES then doxygen generates three +# additional HTML index files: index.hhp, index.hhc, and index.hhk. The +# index.hhp is a project file that can be read by Microsoft's HTML Help Workshop +# (see: http://www.microsoft.com/en-us/download/details.aspx?id=21138) on +# Windows. +# +# The HTML Help Workshop contains a compiler that can convert all HTML output +# generated by doxygen into a single compiled HTML file (.chm). Compiled HTML +# files are now used as the Windows 98 help format, and will replace the old +# Windows help format (.hlp) on all Windows platforms in the future. Compressed +# HTML files also contain an index, a table of contents, and you can search for +# words in the documentation. The HTML workshop also contains a viewer for +# compressed HTML files. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +GENERATE_HTMLHELP = NO + +# The CHM_FILE tag can be used to specify the file name of the resulting .chm +# file. You can add a path in front of the file if the result should not be +# written to the html output directory. +# This tag requires that the tag GENERATE_HTMLHELP is set to YES. + +CHM_FILE = + +# The HHC_LOCATION tag can be used to specify the location (absolute path +# including file name) of the HTML help compiler ( hhc.exe). If non-empty +# doxygen will try to run the HTML help compiler on the generated index.hhp. +# The file has to be specified with full path. +# This tag requires that the tag GENERATE_HTMLHELP is set to YES. + +HHC_LOCATION = + +# The GENERATE_CHI flag controls if a separate .chi index file is generated ( +# YES) or that it should be included in the master .chm file ( NO). +# The default value is: NO. +# This tag requires that the tag GENERATE_HTMLHELP is set to YES. + +GENERATE_CHI = NO + +# The CHM_INDEX_ENCODING is used to encode HtmlHelp index ( hhk), content ( hhc) +# and project file content. +# This tag requires that the tag GENERATE_HTMLHELP is set to YES. + +CHM_INDEX_ENCODING = + +# The BINARY_TOC flag controls whether a binary table of contents is generated ( +# YES) or a normal table of contents ( NO) in the .chm file. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTMLHELP is set to YES. + +BINARY_TOC = NO + +# The TOC_EXPAND flag can be set to YES to add extra items for group members to +# the table of contents of the HTML help documentation and to the tree view. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTMLHELP is set to YES. + +TOC_EXPAND = NO + +# If the GENERATE_QHP tag is set to YES and both QHP_NAMESPACE and +# QHP_VIRTUAL_FOLDER are set, an additional index file will be generated that +# can be used as input for Qt's qhelpgenerator to generate a Qt Compressed Help +# (.qch) of the generated HTML documentation. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +GENERATE_QHP = NO + +# If the QHG_LOCATION tag is specified, the QCH_FILE tag can be used to specify +# the file name of the resulting .qch file. The path specified is relative to +# the HTML output folder. +# This tag requires that the tag GENERATE_QHP is set to YES. + +QCH_FILE = + +# The QHP_NAMESPACE tag specifies the namespace to use when generating Qt Help +# Project output. For more information please see Qt Help Project / Namespace +# (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#namespace). +# The default value is: org.doxygen.Project. +# This tag requires that the tag GENERATE_QHP is set to YES. + +QHP_NAMESPACE = org.doxygen.Project + +# The QHP_VIRTUAL_FOLDER tag specifies the namespace to use when generating Qt +# Help Project output. For more information please see Qt Help Project / Virtual +# Folders (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#virtual- +# folders). +# The default value is: doc. +# This tag requires that the tag GENERATE_QHP is set to YES. + +QHP_VIRTUAL_FOLDER = doc + +# If the QHP_CUST_FILTER_NAME tag is set, it specifies the name of a custom +# filter to add. For more information please see Qt Help Project / Custom +# Filters (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#custom- +# filters). +# This tag requires that the tag GENERATE_QHP is set to YES. + +QHP_CUST_FILTER_NAME = + +# The QHP_CUST_FILTER_ATTRS tag specifies the list of the attributes of the +# custom filter to add. For more information please see Qt Help Project / Custom +# Filters (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#custom- +# filters). +# This tag requires that the tag GENERATE_QHP is set to YES. + +QHP_CUST_FILTER_ATTRS = + +# The QHP_SECT_FILTER_ATTRS tag specifies the list of the attributes this +# project's filter section matches. Qt Help Project / Filter Attributes (see: +# http://qt-project.org/doc/qt-4.8/qthelpproject.html#filter-attributes). +# This tag requires that the tag GENERATE_QHP is set to YES. + +QHP_SECT_FILTER_ATTRS = + +# The QHG_LOCATION tag can be used to specify the location of Qt's +# qhelpgenerator. If non-empty doxygen will try to run qhelpgenerator on the +# generated .qhp file. +# This tag requires that the tag GENERATE_QHP is set to YES. + +QHG_LOCATION = + +# If the GENERATE_ECLIPSEHELP tag is set to YES, additional index files will be +# generated, together with the HTML files, they form an Eclipse help plugin. To +# install this plugin and make it available under the help contents menu in +# Eclipse, the contents of the directory containing the HTML and XML files needs +# to be copied into the plugins directory of eclipse. The name of the directory +# within the plugins directory should be the same as the ECLIPSE_DOC_ID value. +# After copying Eclipse needs to be restarted before the help appears. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +GENERATE_ECLIPSEHELP = NO + +# A unique identifier for the Eclipse help plugin. When installing the plugin +# the directory name containing the HTML and XML files should also have this +# name. Each documentation set should have its own identifier. +# The default value is: org.doxygen.Project. +# This tag requires that the tag GENERATE_ECLIPSEHELP is set to YES. + +ECLIPSE_DOC_ID = org.doxygen.Project + +# If you want full control over the layout of the generated HTML pages it might +# be necessary to disable the index and replace it with your own. The +# DISABLE_INDEX tag can be used to turn on/off the condensed index (tabs) at top +# of each HTML page. A value of NO enables the index and the value YES disables +# it. Since the tabs in the index contain the same information as the navigation +# tree, you can set this option to YES if you also set GENERATE_TREEVIEW to YES. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +DISABLE_INDEX = NO + +# The GENERATE_TREEVIEW tag is used to specify whether a tree-like index +# structure should be generated to display hierarchical information. If the tag +# value is set to YES, a side panel will be generated containing a tree-like +# index structure (just like the one that is generated for HTML Help). For this +# to work a browser that supports JavaScript, DHTML, CSS and frames is required +# (i.e. any modern browser). Windows users are probably better off using the +# HTML help feature. Via custom stylesheets (see HTML_EXTRA_STYLESHEET) one can +# further fine-tune the look of the index. As an example, the default style +# sheet generated by doxygen has an example that shows how to put an image at +# the root of the tree instead of the PROJECT_NAME. Since the tree basically has +# the same information as the tab index, you could consider setting +# DISABLE_INDEX to YES when enabling this option. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +GENERATE_TREEVIEW = YES + +# The ENUM_VALUES_PER_LINE tag can be used to set the number of enum values that +# doxygen will group on one line in the generated HTML documentation. +# +# Note that a value of 0 will completely suppress the enum values from appearing +# in the overview section. +# Minimum value: 0, maximum value: 20, default value: 4. +# This tag requires that the tag GENERATE_HTML is set to YES. + +ENUM_VALUES_PER_LINE = 4 + +# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be used +# to set the initial width (in pixels) of the frame in which the tree is shown. +# Minimum value: 0, maximum value: 1500, default value: 250. +# This tag requires that the tag GENERATE_HTML is set to YES. + +TREEVIEW_WIDTH = 250 + +# When the EXT_LINKS_IN_WINDOW option is set to YES doxygen will open links to +# external symbols imported via tag files in a separate window. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +EXT_LINKS_IN_WINDOW = NO + +# Use this tag to change the font size of LaTeX formulas included as images in +# the HTML documentation. When you change the font size after a successful +# doxygen run you need to manually remove any form_*.png images from the HTML +# output directory to force them to be regenerated. +# Minimum value: 8, maximum value: 50, default value: 10. +# This tag requires that the tag GENERATE_HTML is set to YES. + +FORMULA_FONTSIZE = 10 + +# Use the FORMULA_TRANPARENT tag to determine whether or not the images +# generated for formulas are transparent PNGs. Transparent PNGs are not +# supported properly for IE 6.0, but are supported on all modern browsers. +# +# Note that when changing this option you need to delete any form_*.png files in +# the HTML output directory before the changes have effect. +# The default value is: YES. +# This tag requires that the tag GENERATE_HTML is set to YES. + +FORMULA_TRANSPARENT = YES + +# Enable the USE_MATHJAX option to render LaTeX formulas using MathJax (see +# http://www.mathjax.org) which uses client side Javascript for the rendering +# instead of using prerendered bitmaps. Use this if you do not have LaTeX +# installed or if you want to formulas look prettier in the HTML output. When +# enabled you may also need to install MathJax separately and configure the path +# to it using the MATHJAX_RELPATH option. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +USE_MATHJAX = YES + +# When MathJax is enabled you can set the default output format to be used for +# the MathJax output. See the MathJax site (see: +# http://docs.mathjax.org/en/latest/output.html) for more details. +# Possible values are: HTML-CSS (which is slower, but has the best +# compatibility), NativeMML (i.e. MathML) and SVG. +# The default value is: HTML-CSS. +# This tag requires that the tag USE_MATHJAX is set to YES. + +MATHJAX_FORMAT = NativeMML + +# When MathJax is enabled you need to specify the location relative to the HTML +# output directory using the MATHJAX_RELPATH option. The destination directory +# should contain the MathJax.js script. For instance, if the mathjax directory +# is located at the same level as the HTML output directory, then +# MATHJAX_RELPATH should be ../mathjax. The default value points to the MathJax +# Content Delivery Network so you can quickly see the result without installing +# MathJax. However, it is strongly recommended to install a local copy of +# MathJax from http://www.mathjax.org before deployment. +# The default value is: http://cdn.mathjax.org/mathjax/latest. +# This tag requires that the tag USE_MATHJAX is set to YES. + +MATHJAX_RELPATH = http://cdn.mathjax.org/mathjax/latest + +# The MATHJAX_EXTENSIONS tag can be used to specify one or more MathJax +# extension names that should be enabled during MathJax rendering. For example +# MATHJAX_EXTENSIONS = TeX/AMSmath TeX/AMSsymbols +# This tag requires that the tag USE_MATHJAX is set to YES. + +MATHJAX_EXTENSIONS = + +# The MATHJAX_CODEFILE tag can be used to specify a file with javascript pieces +# of code that will be used on startup of the MathJax code. See the MathJax site +# (see: http://docs.mathjax.org/en/latest/output.html) for more details. For an +# example see the documentation. +# This tag requires that the tag USE_MATHJAX is set to YES. + +MATHJAX_CODEFILE = + +# When the SEARCHENGINE tag is enabled doxygen will generate a search box for +# the HTML output. The underlying search engine uses javascript and DHTML and +# should work on any modern browser. Note that when using HTML help +# (GENERATE_HTMLHELP), Qt help (GENERATE_QHP), or docsets (GENERATE_DOCSET) +# there is already a search function so this one should typically be disabled. +# For large projects the javascript based search engine can be slow, then +# enabling SERVER_BASED_SEARCH may provide a better solution. It is possible to +# search using the keyboard; to jump to the search box use + S +# (what the is depends on the OS and browser, but it is typically +# , /