annotate src/libsamplerate-0.1.9/M4/ltoptions.m4 @ 70:9e21af8f0420

Opus for Windows (MSVC)
author Chris Cannam
date Fri, 25 Jan 2019 12:15:58 +0000
parents 481f5f8c5634
children
rev   line source
Chris@41 1 # Helper functions for option handling. -*- Autoconf -*-
Chris@41 2 #
Chris@41 3 # Copyright (C) 2004-2005, 2007-2009, 2011-2015 Free Software
Chris@41 4 # Foundation, Inc.
Chris@41 5 # Written by Gary V. Vaughan, 2004
Chris@41 6 #
Chris@41 7 # This file is free software; the Free Software Foundation gives
Chris@41 8 # unlimited permission to copy and/or distribute it, with or without
Chris@41 9 # modifications, as long as this notice is preserved.
Chris@41 10
Chris@41 11 # serial 8 ltoptions.m4
Chris@41 12
Chris@41 13 # This is to help aclocal find these macros, as it can't see m4_define.
Chris@41 14 AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])])
Chris@41 15
Chris@41 16
Chris@41 17 # _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME)
Chris@41 18 # ------------------------------------------
Chris@41 19 m4_define([_LT_MANGLE_OPTION],
Chris@41 20 [[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])])
Chris@41 21
Chris@41 22
Chris@41 23 # _LT_SET_OPTION(MACRO-NAME, OPTION-NAME)
Chris@41 24 # ---------------------------------------
Chris@41 25 # Set option OPTION-NAME for macro MACRO-NAME, and if there is a
Chris@41 26 # matching handler defined, dispatch to it. Other OPTION-NAMEs are
Chris@41 27 # saved as a flag.
Chris@41 28 m4_define([_LT_SET_OPTION],
Chris@41 29 [m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl
Chris@41 30 m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]),
Chris@41 31 _LT_MANGLE_DEFUN([$1], [$2]),
Chris@41 32 [m4_warning([Unknown $1 option '$2'])])[]dnl
Chris@41 33 ])
Chris@41 34
Chris@41 35
Chris@41 36 # _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET])
Chris@41 37 # ------------------------------------------------------------
Chris@41 38 # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
Chris@41 39 m4_define([_LT_IF_OPTION],
Chris@41 40 [m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])])
Chris@41 41
Chris@41 42
Chris@41 43 # _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET)
Chris@41 44 # -------------------------------------------------------
Chris@41 45 # Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME
Chris@41 46 # are set.
Chris@41 47 m4_define([_LT_UNLESS_OPTIONS],
Chris@41 48 [m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
Chris@41 49 [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option),
Chris@41 50 [m4_define([$0_found])])])[]dnl
Chris@41 51 m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3
Chris@41 52 ])[]dnl
Chris@41 53 ])
Chris@41 54
Chris@41 55
Chris@41 56 # _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST)
Chris@41 57 # ----------------------------------------
Chris@41 58 # OPTION-LIST is a space-separated list of Libtool options associated
Chris@41 59 # with MACRO-NAME. If any OPTION has a matching handler declared with
Chris@41 60 # LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about
Chris@41 61 # the unknown option and exit.
Chris@41 62 m4_defun([_LT_SET_OPTIONS],
Chris@41 63 [# Set options
Chris@41 64 m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
Chris@41 65 [_LT_SET_OPTION([$1], _LT_Option)])
Chris@41 66
Chris@41 67 m4_if([$1],[LT_INIT],[
Chris@41 68 dnl
Chris@41 69 dnl Simply set some default values (i.e off) if boolean options were not
Chris@41 70 dnl specified:
Chris@41 71 _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no
Chris@41 72 ])
Chris@41 73 _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no
Chris@41 74 ])
Chris@41 75 dnl
Chris@41 76 dnl If no reference was made to various pairs of opposing options, then
Chris@41 77 dnl we run the default mode handler for the pair. For example, if neither
Chris@41 78 dnl 'shared' nor 'disable-shared' was passed, we enable building of shared
Chris@41 79 dnl archives by default:
Chris@41 80 _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED])
Chris@41 81 _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC])
Chris@41 82 _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC])
Chris@41 83 _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install],
Chris@41 84 [_LT_ENABLE_FAST_INSTALL])
Chris@41 85 _LT_UNLESS_OPTIONS([LT_INIT], [aix-soname=aix aix-soname=both aix-soname=svr4],
Chris@41 86 [_LT_WITH_AIX_SONAME([aix])])
Chris@41 87 ])
Chris@41 88 ])# _LT_SET_OPTIONS
Chris@41 89
Chris@41 90
Chris@41 91 ## --------------------------------- ##
Chris@41 92 ## Macros to handle LT_INIT options. ##
Chris@41 93 ## --------------------------------- ##
Chris@41 94
Chris@41 95 # _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME)
Chris@41 96 # -----------------------------------------
Chris@41 97 m4_define([_LT_MANGLE_DEFUN],
Chris@41 98 [[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])])
Chris@41 99
Chris@41 100
Chris@41 101 # LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE)
Chris@41 102 # -----------------------------------------------
Chris@41 103 m4_define([LT_OPTION_DEFINE],
Chris@41 104 [m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl
Chris@41 105 ])# LT_OPTION_DEFINE
Chris@41 106
Chris@41 107
Chris@41 108 # dlopen
Chris@41 109 # ------
Chris@41 110 LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes
Chris@41 111 ])
Chris@41 112
Chris@41 113 AU_DEFUN([AC_LIBTOOL_DLOPEN],
Chris@41 114 [_LT_SET_OPTION([LT_INIT], [dlopen])
Chris@41 115 AC_DIAGNOSE([obsolete],
Chris@41 116 [$0: Remove this warning and the call to _LT_SET_OPTION when you
Chris@41 117 put the 'dlopen' option into LT_INIT's first parameter.])
Chris@41 118 ])
Chris@41 119
Chris@41 120 dnl aclocal-1.4 backwards compatibility:
Chris@41 121 dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], [])
Chris@41 122
Chris@41 123
Chris@41 124 # win32-dll
Chris@41 125 # ---------
Chris@41 126 # Declare package support for building win32 dll's.
Chris@41 127 LT_OPTION_DEFINE([LT_INIT], [win32-dll],
Chris@41 128 [enable_win32_dll=yes
Chris@41 129
Chris@41 130 case $host in
Chris@41 131 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*)
Chris@41 132 AC_CHECK_TOOL(AS, as, false)
Chris@41 133 AC_CHECK_TOOL(DLLTOOL, dlltool, false)
Chris@41 134 AC_CHECK_TOOL(OBJDUMP, objdump, false)
Chris@41 135 ;;
Chris@41 136 esac
Chris@41 137
Chris@41 138 test -z "$AS" && AS=as
Chris@41 139 _LT_DECL([], [AS], [1], [Assembler program])dnl
Chris@41 140
Chris@41 141 test -z "$DLLTOOL" && DLLTOOL=dlltool
Chris@41 142 _LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl
Chris@41 143
Chris@41 144 test -z "$OBJDUMP" && OBJDUMP=objdump
Chris@41 145 _LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl
Chris@41 146 ])# win32-dll
Chris@41 147
Chris@41 148 AU_DEFUN([AC_LIBTOOL_WIN32_DLL],
Chris@41 149 [AC_REQUIRE([AC_CANONICAL_HOST])dnl
Chris@41 150 _LT_SET_OPTION([LT_INIT], [win32-dll])
Chris@41 151 AC_DIAGNOSE([obsolete],
Chris@41 152 [$0: Remove this warning and the call to _LT_SET_OPTION when you
Chris@41 153 put the 'win32-dll' option into LT_INIT's first parameter.])
Chris@41 154 ])
Chris@41 155
Chris@41 156 dnl aclocal-1.4 backwards compatibility:
Chris@41 157 dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], [])
Chris@41 158
Chris@41 159
Chris@41 160 # _LT_ENABLE_SHARED([DEFAULT])
Chris@41 161 # ----------------------------
Chris@41 162 # implement the --enable-shared flag, and supports the 'shared' and
Chris@41 163 # 'disable-shared' LT_INIT options.
Chris@41 164 # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'.
Chris@41 165 m4_define([_LT_ENABLE_SHARED],
Chris@41 166 [m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl
Chris@41 167 AC_ARG_ENABLE([shared],
Chris@41 168 [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
Chris@41 169 [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])],
Chris@41 170 [p=${PACKAGE-default}
Chris@41 171 case $enableval in
Chris@41 172 yes) enable_shared=yes ;;
Chris@41 173 no) enable_shared=no ;;
Chris@41 174 *)
Chris@41 175 enable_shared=no
Chris@41 176 # Look at the argument we got. We use all the common list separators.
Chris@41 177 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
Chris@41 178 for pkg in $enableval; do
Chris@41 179 IFS=$lt_save_ifs
Chris@41 180 if test "X$pkg" = "X$p"; then
Chris@41 181 enable_shared=yes
Chris@41 182 fi
Chris@41 183 done
Chris@41 184 IFS=$lt_save_ifs
Chris@41 185 ;;
Chris@41 186 esac],
Chris@41 187 [enable_shared=]_LT_ENABLE_SHARED_DEFAULT)
Chris@41 188
Chris@41 189 _LT_DECL([build_libtool_libs], [enable_shared], [0],
Chris@41 190 [Whether or not to build shared libraries])
Chris@41 191 ])# _LT_ENABLE_SHARED
Chris@41 192
Chris@41 193 LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])])
Chris@41 194 LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])])
Chris@41 195
Chris@41 196 # Old names:
Chris@41 197 AC_DEFUN([AC_ENABLE_SHARED],
Chris@41 198 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared])
Chris@41 199 ])
Chris@41 200
Chris@41 201 AC_DEFUN([AC_DISABLE_SHARED],
Chris@41 202 [_LT_SET_OPTION([LT_INIT], [disable-shared])
Chris@41 203 ])
Chris@41 204
Chris@41 205 AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
Chris@41 206 AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
Chris@41 207
Chris@41 208 dnl aclocal-1.4 backwards compatibility:
Chris@41 209 dnl AC_DEFUN([AM_ENABLE_SHARED], [])
Chris@41 210 dnl AC_DEFUN([AM_DISABLE_SHARED], [])
Chris@41 211
Chris@41 212
Chris@41 213
Chris@41 214 # _LT_ENABLE_STATIC([DEFAULT])
Chris@41 215 # ----------------------------
Chris@41 216 # implement the --enable-static flag, and support the 'static' and
Chris@41 217 # 'disable-static' LT_INIT options.
Chris@41 218 # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'.
Chris@41 219 m4_define([_LT_ENABLE_STATIC],
Chris@41 220 [m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl
Chris@41 221 AC_ARG_ENABLE([static],
Chris@41 222 [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@],
Chris@41 223 [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])],
Chris@41 224 [p=${PACKAGE-default}
Chris@41 225 case $enableval in
Chris@41 226 yes) enable_static=yes ;;
Chris@41 227 no) enable_static=no ;;
Chris@41 228 *)
Chris@41 229 enable_static=no
Chris@41 230 # Look at the argument we got. We use all the common list separators.
Chris@41 231 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
Chris@41 232 for pkg in $enableval; do
Chris@41 233 IFS=$lt_save_ifs
Chris@41 234 if test "X$pkg" = "X$p"; then
Chris@41 235 enable_static=yes
Chris@41 236 fi
Chris@41 237 done
Chris@41 238 IFS=$lt_save_ifs
Chris@41 239 ;;
Chris@41 240 esac],
Chris@41 241 [enable_static=]_LT_ENABLE_STATIC_DEFAULT)
Chris@41 242
Chris@41 243 _LT_DECL([build_old_libs], [enable_static], [0],
Chris@41 244 [Whether or not to build static libraries])
Chris@41 245 ])# _LT_ENABLE_STATIC
Chris@41 246
Chris@41 247 LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])])
Chris@41 248 LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])])
Chris@41 249
Chris@41 250 # Old names:
Chris@41 251 AC_DEFUN([AC_ENABLE_STATIC],
Chris@41 252 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static])
Chris@41 253 ])
Chris@41 254
Chris@41 255 AC_DEFUN([AC_DISABLE_STATIC],
Chris@41 256 [_LT_SET_OPTION([LT_INIT], [disable-static])
Chris@41 257 ])
Chris@41 258
Chris@41 259 AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
Chris@41 260 AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
Chris@41 261
Chris@41 262 dnl aclocal-1.4 backwards compatibility:
Chris@41 263 dnl AC_DEFUN([AM_ENABLE_STATIC], [])
Chris@41 264 dnl AC_DEFUN([AM_DISABLE_STATIC], [])
Chris@41 265
Chris@41 266
Chris@41 267
Chris@41 268 # _LT_ENABLE_FAST_INSTALL([DEFAULT])
Chris@41 269 # ----------------------------------
Chris@41 270 # implement the --enable-fast-install flag, and support the 'fast-install'
Chris@41 271 # and 'disable-fast-install' LT_INIT options.
Chris@41 272 # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'.
Chris@41 273 m4_define([_LT_ENABLE_FAST_INSTALL],
Chris@41 274 [m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl
Chris@41 275 AC_ARG_ENABLE([fast-install],
Chris@41 276 [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
Chris@41 277 [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
Chris@41 278 [p=${PACKAGE-default}
Chris@41 279 case $enableval in
Chris@41 280 yes) enable_fast_install=yes ;;
Chris@41 281 no) enable_fast_install=no ;;
Chris@41 282 *)
Chris@41 283 enable_fast_install=no
Chris@41 284 # Look at the argument we got. We use all the common list separators.
Chris@41 285 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
Chris@41 286 for pkg in $enableval; do
Chris@41 287 IFS=$lt_save_ifs
Chris@41 288 if test "X$pkg" = "X$p"; then
Chris@41 289 enable_fast_install=yes
Chris@41 290 fi
Chris@41 291 done
Chris@41 292 IFS=$lt_save_ifs
Chris@41 293 ;;
Chris@41 294 esac],
Chris@41 295 [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT)
Chris@41 296
Chris@41 297 _LT_DECL([fast_install], [enable_fast_install], [0],
Chris@41 298 [Whether or not to optimize for fast installation])dnl
Chris@41 299 ])# _LT_ENABLE_FAST_INSTALL
Chris@41 300
Chris@41 301 LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])])
Chris@41 302 LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])])
Chris@41 303
Chris@41 304 # Old names:
Chris@41 305 AU_DEFUN([AC_ENABLE_FAST_INSTALL],
Chris@41 306 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install])
Chris@41 307 AC_DIAGNOSE([obsolete],
Chris@41 308 [$0: Remove this warning and the call to _LT_SET_OPTION when you put
Chris@41 309 the 'fast-install' option into LT_INIT's first parameter.])
Chris@41 310 ])
Chris@41 311
Chris@41 312 AU_DEFUN([AC_DISABLE_FAST_INSTALL],
Chris@41 313 [_LT_SET_OPTION([LT_INIT], [disable-fast-install])
Chris@41 314 AC_DIAGNOSE([obsolete],
Chris@41 315 [$0: Remove this warning and the call to _LT_SET_OPTION when you put
Chris@41 316 the 'disable-fast-install' option into LT_INIT's first parameter.])
Chris@41 317 ])
Chris@41 318
Chris@41 319 dnl aclocal-1.4 backwards compatibility:
Chris@41 320 dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], [])
Chris@41 321 dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], [])
Chris@41 322
Chris@41 323
Chris@41 324 # _LT_WITH_AIX_SONAME([DEFAULT])
Chris@41 325 # ----------------------------------
Chris@41 326 # implement the --with-aix-soname flag, and support the `aix-soname=aix'
Chris@41 327 # and `aix-soname=both' and `aix-soname=svr4' LT_INIT options. DEFAULT
Chris@41 328 # is either `aix', `both' or `svr4'. If omitted, it defaults to `aix'.
Chris@41 329 m4_define([_LT_WITH_AIX_SONAME],
Chris@41 330 [m4_define([_LT_WITH_AIX_SONAME_DEFAULT], [m4_if($1, svr4, svr4, m4_if($1, both, both, aix))])dnl
Chris@41 331 shared_archive_member_spec=
Chris@41 332 case $host,$enable_shared in
Chris@41 333 power*-*-aix[[5-9]]*,yes)
Chris@41 334 AC_MSG_CHECKING([which variant of shared library versioning to provide])
Chris@41 335 AC_ARG_WITH([aix-soname],
Chris@41 336 [AS_HELP_STRING([--with-aix-soname=aix|svr4|both],
Chris@41 337 [shared library versioning (aka "SONAME") variant to provide on AIX, @<:@default=]_LT_WITH_AIX_SONAME_DEFAULT[@:>@.])],
Chris@41 338 [case $withval in
Chris@41 339 aix|svr4|both)
Chris@41 340 ;;
Chris@41 341 *)
Chris@41 342 AC_MSG_ERROR([Unknown argument to --with-aix-soname])
Chris@41 343 ;;
Chris@41 344 esac
Chris@41 345 lt_cv_with_aix_soname=$with_aix_soname],
Chris@41 346 [AC_CACHE_VAL([lt_cv_with_aix_soname],
Chris@41 347 [lt_cv_with_aix_soname=]_LT_WITH_AIX_SONAME_DEFAULT)
Chris@41 348 with_aix_soname=$lt_cv_with_aix_soname])
Chris@41 349 AC_MSG_RESULT([$with_aix_soname])
Chris@41 350 if test aix != "$with_aix_soname"; then
Chris@41 351 # For the AIX way of multilib, we name the shared archive member
Chris@41 352 # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o',
Chris@41 353 # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File.
Chris@41 354 # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag,
Chris@41 355 # the AIX toolchain works better with OBJECT_MODE set (default 32).
Chris@41 356 if test 64 = "${OBJECT_MODE-32}"; then
Chris@41 357 shared_archive_member_spec=shr_64
Chris@41 358 else
Chris@41 359 shared_archive_member_spec=shr
Chris@41 360 fi
Chris@41 361 fi
Chris@41 362 ;;
Chris@41 363 *)
Chris@41 364 with_aix_soname=aix
Chris@41 365 ;;
Chris@41 366 esac
Chris@41 367
Chris@41 368 _LT_DECL([], [shared_archive_member_spec], [0],
Chris@41 369 [Shared archive member basename, for filename based shared library versioning on AIX])dnl
Chris@41 370 ])# _LT_WITH_AIX_SONAME
Chris@41 371
Chris@41 372 LT_OPTION_DEFINE([LT_INIT], [aix-soname=aix], [_LT_WITH_AIX_SONAME([aix])])
Chris@41 373 LT_OPTION_DEFINE([LT_INIT], [aix-soname=both], [_LT_WITH_AIX_SONAME([both])])
Chris@41 374 LT_OPTION_DEFINE([LT_INIT], [aix-soname=svr4], [_LT_WITH_AIX_SONAME([svr4])])
Chris@41 375
Chris@41 376
Chris@41 377 # _LT_WITH_PIC([MODE])
Chris@41 378 # --------------------
Chris@41 379 # implement the --with-pic flag, and support the 'pic-only' and 'no-pic'
Chris@41 380 # LT_INIT options.
Chris@41 381 # MODE is either 'yes' or 'no'. If omitted, it defaults to 'both'.
Chris@41 382 m4_define([_LT_WITH_PIC],
Chris@41 383 [AC_ARG_WITH([pic],
Chris@41 384 [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@],
Chris@41 385 [try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
Chris@41 386 [lt_p=${PACKAGE-default}
Chris@41 387 case $withval in
Chris@41 388 yes|no) pic_mode=$withval ;;
Chris@41 389 *)
Chris@41 390 pic_mode=default
Chris@41 391 # Look at the argument we got. We use all the common list separators.
Chris@41 392 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
Chris@41 393 for lt_pkg in $withval; do
Chris@41 394 IFS=$lt_save_ifs
Chris@41 395 if test "X$lt_pkg" = "X$lt_p"; then
Chris@41 396 pic_mode=yes
Chris@41 397 fi
Chris@41 398 done
Chris@41 399 IFS=$lt_save_ifs
Chris@41 400 ;;
Chris@41 401 esac],
Chris@41 402 [pic_mode=m4_default([$1], [default])])
Chris@41 403
Chris@41 404 _LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl
Chris@41 405 ])# _LT_WITH_PIC
Chris@41 406
Chris@41 407 LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])])
Chris@41 408 LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])])
Chris@41 409
Chris@41 410 # Old name:
Chris@41 411 AU_DEFUN([AC_LIBTOOL_PICMODE],
Chris@41 412 [_LT_SET_OPTION([LT_INIT], [pic-only])
Chris@41 413 AC_DIAGNOSE([obsolete],
Chris@41 414 [$0: Remove this warning and the call to _LT_SET_OPTION when you
Chris@41 415 put the 'pic-only' option into LT_INIT's first parameter.])
Chris@41 416 ])
Chris@41 417
Chris@41 418 dnl aclocal-1.4 backwards compatibility:
Chris@41 419 dnl AC_DEFUN([AC_LIBTOOL_PICMODE], [])
Chris@41 420
Chris@41 421 ## ----------------- ##
Chris@41 422 ## LTDL_INIT Options ##
Chris@41 423 ## ----------------- ##
Chris@41 424
Chris@41 425 m4_define([_LTDL_MODE], [])
Chris@41 426 LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive],
Chris@41 427 [m4_define([_LTDL_MODE], [nonrecursive])])
Chris@41 428 LT_OPTION_DEFINE([LTDL_INIT], [recursive],
Chris@41 429 [m4_define([_LTDL_MODE], [recursive])])
Chris@41 430 LT_OPTION_DEFINE([LTDL_INIT], [subproject],
Chris@41 431 [m4_define([_LTDL_MODE], [subproject])])
Chris@41 432
Chris@41 433 m4_define([_LTDL_TYPE], [])
Chris@41 434 LT_OPTION_DEFINE([LTDL_INIT], [installable],
Chris@41 435 [m4_define([_LTDL_TYPE], [installable])])
Chris@41 436 LT_OPTION_DEFINE([LTDL_INIT], [convenience],
Chris@41 437 [m4_define([_LTDL_TYPE], [convenience])])