110f94802Smrg# Helper functions for option handling. -*- Autoconf -*- 210f94802Smrg# 310f94802Smrg# Copyright (C) 2004-2005, 2007-2009, 2011-2019, 2021-2022 Free 410f94802Smrg# Software Foundation, Inc. 510f94802Smrg# Written by Gary V. Vaughan, 2004 610f94802Smrg# 710f94802Smrg# This file is free software; the Free Software Foundation gives 810f94802Smrg# unlimited permission to copy and/or distribute it, with or without 910f94802Smrg# modifications, as long as this notice is preserved. 1010f94802Smrg 1110f94802Smrg# serial 8 ltoptions.m4 1210f94802Smrg 1310f94802Smrg# This is to help aclocal find these macros, as it can't see m4_define. 1410f94802SmrgAC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) 1510f94802Smrg 1610f94802Smrg 1710f94802Smrg# _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME) 1810f94802Smrg# ------------------------------------------ 1910f94802Smrgm4_define([_LT_MANGLE_OPTION], 2010f94802Smrg[[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])]) 2110f94802Smrg 2210f94802Smrg 2310f94802Smrg# _LT_SET_OPTION(MACRO-NAME, OPTION-NAME) 2410f94802Smrg# --------------------------------------- 2510f94802Smrg# Set option OPTION-NAME for macro MACRO-NAME, and if there is a 2610f94802Smrg# matching handler defined, dispatch to it. Other OPTION-NAMEs are 2710f94802Smrg# saved as a flag. 2810f94802Smrgm4_define([_LT_SET_OPTION], 2910f94802Smrg[m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl 3010f94802Smrgm4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), 3110f94802Smrg _LT_MANGLE_DEFUN([$1], [$2]), 3210f94802Smrg [m4_warning([Unknown $1 option '$2'])])[]dnl 3310f94802Smrg]) 3410f94802Smrg 3510f94802Smrg 3610f94802Smrg# _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET]) 3710f94802Smrg# ------------------------------------------------------------ 3810f94802Smrg# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. 3910f94802Smrgm4_define([_LT_IF_OPTION], 4010f94802Smrg[m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])]) 4110f94802Smrg 4210f94802Smrg 4310f94802Smrg# _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET) 4410f94802Smrg# ------------------------------------------------------- 4510f94802Smrg# Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME 4610f94802Smrg# are set. 4710f94802Smrgm4_define([_LT_UNLESS_OPTIONS], 4810f94802Smrg[m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), 4910f94802Smrg [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option), 5010f94802Smrg [m4_define([$0_found])])])[]dnl 5110f94802Smrgm4_ifdef([$0_found], [m4_undefine([$0_found])], [$3 5210f94802Smrg])[]dnl 5310f94802Smrg]) 5410f94802Smrg 5510f94802Smrg 5610f94802Smrg# _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST) 5710f94802Smrg# ---------------------------------------- 5810f94802Smrg# OPTION-LIST is a space-separated list of Libtool options associated 5910f94802Smrg# with MACRO-NAME. If any OPTION has a matching handler declared with 6010f94802Smrg# LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about 6110f94802Smrg# the unknown option and exit. 6210f94802Smrgm4_defun([_LT_SET_OPTIONS], 6310f94802Smrg[# Set options 6410f94802Smrgm4_foreach([_LT_Option], m4_split(m4_normalize([$2])), 6510f94802Smrg [_LT_SET_OPTION([$1], _LT_Option)]) 6610f94802Smrg 6710f94802Smrgm4_if([$1],[LT_INIT],[ 6810f94802Smrg dnl 6910f94802Smrg dnl Simply set some default values (i.e off) if boolean options were not 7010f94802Smrg dnl specified: 7110f94802Smrg _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no 7210f94802Smrg ]) 7310f94802Smrg _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no 7410f94802Smrg ]) 7510f94802Smrg dnl 7610f94802Smrg dnl If no reference was made to various pairs of opposing options, then 7710f94802Smrg dnl we run the default mode handler for the pair. For example, if neither 7810f94802Smrg dnl 'shared' nor 'disable-shared' was passed, we enable building of shared 7910f94802Smrg dnl archives by default: 8010f94802Smrg _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) 8110f94802Smrg _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) 8210f94802Smrg _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) 8310f94802Smrg _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], 8410f94802Smrg [_LT_ENABLE_FAST_INSTALL]) 8510f94802Smrg _LT_UNLESS_OPTIONS([LT_INIT], [aix-soname=aix aix-soname=both aix-soname=svr4], 8610f94802Smrg [_LT_WITH_AIX_SONAME([aix])]) 8710f94802Smrg ]) 8810f94802Smrg])# _LT_SET_OPTIONS 8910f94802Smrg 9010f94802Smrg 9110f94802Smrg## --------------------------------- ## 9210f94802Smrg## Macros to handle LT_INIT options. ## 9310f94802Smrg## --------------------------------- ## 9410f94802Smrg 9510f94802Smrg# _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME) 9610f94802Smrg# ----------------------------------------- 9710f94802Smrgm4_define([_LT_MANGLE_DEFUN], 9810f94802Smrg[[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])]) 9910f94802Smrg 10010f94802Smrg 10110f94802Smrg# LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE) 10210f94802Smrg# ----------------------------------------------- 10310f94802Smrgm4_define([LT_OPTION_DEFINE], 10410f94802Smrg[m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl 10510f94802Smrg])# LT_OPTION_DEFINE 10610f94802Smrg 10710f94802Smrg 10810f94802Smrg# dlopen 10910f94802Smrg# ------ 11010f94802SmrgLT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes 11110f94802Smrg]) 11210f94802Smrg 11310f94802SmrgAU_DEFUN([AC_LIBTOOL_DLOPEN], 11410f94802Smrg[_LT_SET_OPTION([LT_INIT], [dlopen]) 11510f94802SmrgAC_DIAGNOSE([obsolete], 11610f94802Smrg[$0: Remove this warning and the call to _LT_SET_OPTION when you 11710f94802Smrgput the 'dlopen' option into LT_INIT's first parameter.]) 11810f94802Smrg]) 11910f94802Smrg 12010f94802Smrgdnl aclocal-1.4 backwards compatibility: 12110f94802Smrgdnl AC_DEFUN([AC_LIBTOOL_DLOPEN], []) 12210f94802Smrg 12310f94802Smrg 12410f94802Smrg# win32-dll 12510f94802Smrg# --------- 12610f94802Smrg# Declare package support for building win32 dll's. 12710f94802SmrgLT_OPTION_DEFINE([LT_INIT], [win32-dll], 12810f94802Smrg[enable_win32_dll=yes 12910f94802Smrg 13010f94802Smrgcase $host in 13110f94802Smrg*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) 13210f94802Smrg AC_CHECK_TOOL(AS, as, false) 13310f94802Smrg AC_CHECK_TOOL(DLLTOOL, dlltool, false) 13410f94802Smrg AC_CHECK_TOOL(OBJDUMP, objdump, false) 13510f94802Smrg ;; 13610f94802Smrgesac 13710f94802Smrg 13810f94802Smrgtest -z "$AS" && AS=as 13910f94802Smrg_LT_DECL([], [AS], [1], [Assembler program])dnl 14010f94802Smrg 14110f94802Smrgtest -z "$DLLTOOL" && DLLTOOL=dlltool 14210f94802Smrg_LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl 14310f94802Smrg 14410f94802Smrgtest -z "$OBJDUMP" && OBJDUMP=objdump 14510f94802Smrg_LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl 14610f94802Smrg])# win32-dll 14710f94802Smrg 14810f94802SmrgAU_DEFUN([AC_LIBTOOL_WIN32_DLL], 14910f94802Smrg[AC_REQUIRE([AC_CANONICAL_HOST])dnl 15010f94802Smrg_LT_SET_OPTION([LT_INIT], [win32-dll]) 15110f94802SmrgAC_DIAGNOSE([obsolete], 15210f94802Smrg[$0: Remove this warning and the call to _LT_SET_OPTION when you 15310f94802Smrgput the 'win32-dll' option into LT_INIT's first parameter.]) 15410f94802Smrg]) 15510f94802Smrg 15610f94802Smrgdnl aclocal-1.4 backwards compatibility: 15710f94802Smrgdnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) 15810f94802Smrg 15910f94802Smrg 16010f94802Smrg# _LT_ENABLE_SHARED([DEFAULT]) 16110f94802Smrg# ---------------------------- 16210f94802Smrg# implement the --enable-shared flag, and supports the 'shared' and 16310f94802Smrg# 'disable-shared' LT_INIT options. 16410f94802Smrg# DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. 16510f94802Smrgm4_define([_LT_ENABLE_SHARED], 16610f94802Smrg[m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl 16710f94802SmrgAC_ARG_ENABLE([shared], 16810f94802Smrg [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@], 16910f94802Smrg [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])], 17010f94802Smrg [p=${PACKAGE-default} 17110f94802Smrg case $enableval in 17210f94802Smrg yes) enable_shared=yes ;; 17310f94802Smrg no) enable_shared=no ;; 17410f94802Smrg *) 17510f94802Smrg enable_shared=no 17610f94802Smrg # Look at the argument we got. We use all the common list separators. 17710f94802Smrg lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, 17810f94802Smrg for pkg in $enableval; do 17910f94802Smrg IFS=$lt_save_ifs 18010f94802Smrg if test "X$pkg" = "X$p"; then 18110f94802Smrg enable_shared=yes 18210f94802Smrg fi 18310f94802Smrg done 18410f94802Smrg IFS=$lt_save_ifs 18510f94802Smrg ;; 18610f94802Smrg esac], 18710f94802Smrg [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) 18810f94802Smrg 18910f94802Smrg _LT_DECL([build_libtool_libs], [enable_shared], [0], 19010f94802Smrg [Whether or not to build shared libraries]) 19110f94802Smrg])# _LT_ENABLE_SHARED 19210f94802Smrg 19310f94802SmrgLT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])]) 19410f94802SmrgLT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])]) 19510f94802Smrg 19610f94802Smrg# Old names: 19710f94802SmrgAC_DEFUN([AC_ENABLE_SHARED], 19810f94802Smrg[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared]) 19910f94802Smrg]) 20010f94802Smrg 20110f94802SmrgAC_DEFUN([AC_DISABLE_SHARED], 20210f94802Smrg[_LT_SET_OPTION([LT_INIT], [disable-shared]) 20310f94802Smrg]) 20410f94802Smrg 20510f94802SmrgAU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) 20610f94802SmrgAU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) 20710f94802Smrg 20810f94802Smrgdnl aclocal-1.4 backwards compatibility: 20910f94802Smrgdnl AC_DEFUN([AM_ENABLE_SHARED], []) 21010f94802Smrgdnl AC_DEFUN([AM_DISABLE_SHARED], []) 21110f94802Smrg 21210f94802Smrg 21310f94802Smrg 21410f94802Smrg# _LT_ENABLE_STATIC([DEFAULT]) 21510f94802Smrg# ---------------------------- 21610f94802Smrg# implement the --enable-static flag, and support the 'static' and 21710f94802Smrg# 'disable-static' LT_INIT options. 21810f94802Smrg# DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. 21910f94802Smrgm4_define([_LT_ENABLE_STATIC], 22010f94802Smrg[m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl 22110f94802SmrgAC_ARG_ENABLE([static], 22210f94802Smrg [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@], 22310f94802Smrg [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])], 22410f94802Smrg [p=${PACKAGE-default} 22510f94802Smrg case $enableval in 22610f94802Smrg yes) enable_static=yes ;; 22710f94802Smrg no) enable_static=no ;; 22810f94802Smrg *) 22910f94802Smrg enable_static=no 23010f94802Smrg # Look at the argument we got. We use all the common list separators. 23110f94802Smrg lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, 23210f94802Smrg for pkg in $enableval; do 23310f94802Smrg IFS=$lt_save_ifs 23410f94802Smrg if test "X$pkg" = "X$p"; then 23510f94802Smrg enable_static=yes 23610f94802Smrg fi 23710f94802Smrg done 23810f94802Smrg IFS=$lt_save_ifs 23910f94802Smrg ;; 24010f94802Smrg esac], 24110f94802Smrg [enable_static=]_LT_ENABLE_STATIC_DEFAULT) 24210f94802Smrg 24310f94802Smrg _LT_DECL([build_old_libs], [enable_static], [0], 24410f94802Smrg [Whether or not to build static libraries]) 24510f94802Smrg])# _LT_ENABLE_STATIC 24610f94802Smrg 24710f94802SmrgLT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])]) 24810f94802SmrgLT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])]) 24910f94802Smrg 25010f94802Smrg# Old names: 25110f94802SmrgAC_DEFUN([AC_ENABLE_STATIC], 25210f94802Smrg[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static]) 25310f94802Smrg]) 25410f94802Smrg 25510f94802SmrgAC_DEFUN([AC_DISABLE_STATIC], 25610f94802Smrg[_LT_SET_OPTION([LT_INIT], [disable-static]) 25710f94802Smrg]) 25810f94802Smrg 25910f94802SmrgAU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) 26010f94802SmrgAU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) 26110f94802Smrg 26210f94802Smrgdnl aclocal-1.4 backwards compatibility: 26310f94802Smrgdnl AC_DEFUN([AM_ENABLE_STATIC], []) 26410f94802Smrgdnl AC_DEFUN([AM_DISABLE_STATIC], []) 26510f94802Smrg 26610f94802Smrg 26710f94802Smrg 26810f94802Smrg# _LT_ENABLE_FAST_INSTALL([DEFAULT]) 26910f94802Smrg# ---------------------------------- 27010f94802Smrg# implement the --enable-fast-install flag, and support the 'fast-install' 27110f94802Smrg# and 'disable-fast-install' LT_INIT options. 27210f94802Smrg# DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. 27310f94802Smrgm4_define([_LT_ENABLE_FAST_INSTALL], 27410f94802Smrg[m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl 27510f94802SmrgAC_ARG_ENABLE([fast-install], 27610f94802Smrg [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], 27710f94802Smrg [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], 27810f94802Smrg [p=${PACKAGE-default} 27910f94802Smrg case $enableval in 28010f94802Smrg yes) enable_fast_install=yes ;; 28110f94802Smrg no) enable_fast_install=no ;; 28210f94802Smrg *) 28310f94802Smrg enable_fast_install=no 28410f94802Smrg # Look at the argument we got. We use all the common list separators. 28510f94802Smrg lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, 28610f94802Smrg for pkg in $enableval; do 28710f94802Smrg IFS=$lt_save_ifs 28810f94802Smrg if test "X$pkg" = "X$p"; then 28910f94802Smrg enable_fast_install=yes 29010f94802Smrg fi 29110f94802Smrg done 29210f94802Smrg IFS=$lt_save_ifs 29310f94802Smrg ;; 29410f94802Smrg esac], 29510f94802Smrg [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) 29610f94802Smrg 29710f94802Smrg_LT_DECL([fast_install], [enable_fast_install], [0], 29810f94802Smrg [Whether or not to optimize for fast installation])dnl 29910f94802Smrg])# _LT_ENABLE_FAST_INSTALL 30010f94802Smrg 30110f94802SmrgLT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])]) 30210f94802SmrgLT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])]) 30310f94802Smrg 30410f94802Smrg# Old names: 30510f94802SmrgAU_DEFUN([AC_ENABLE_FAST_INSTALL], 30610f94802Smrg[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) 30710f94802SmrgAC_DIAGNOSE([obsolete], 30810f94802Smrg[$0: Remove this warning and the call to _LT_SET_OPTION when you put 30910f94802Smrgthe 'fast-install' option into LT_INIT's first parameter.]) 31010f94802Smrg]) 31110f94802Smrg 31210f94802SmrgAU_DEFUN([AC_DISABLE_FAST_INSTALL], 31310f94802Smrg[_LT_SET_OPTION([LT_INIT], [disable-fast-install]) 31410f94802SmrgAC_DIAGNOSE([obsolete], 31510f94802Smrg[$0: Remove this warning and the call to _LT_SET_OPTION when you put 31610f94802Smrgthe 'disable-fast-install' option into LT_INIT's first parameter.]) 31710f94802Smrg]) 31810f94802Smrg 31910f94802Smrgdnl aclocal-1.4 backwards compatibility: 32010f94802Smrgdnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) 32110f94802Smrgdnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) 32210f94802Smrg 32310f94802Smrg 32410f94802Smrg# _LT_WITH_AIX_SONAME([DEFAULT]) 32510f94802Smrg# ---------------------------------- 32610f94802Smrg# implement the --with-aix-soname flag, and support the `aix-soname=aix' 32710f94802Smrg# and `aix-soname=both' and `aix-soname=svr4' LT_INIT options. DEFAULT 32810f94802Smrg# is either `aix', `both' or `svr4'. If omitted, it defaults to `aix'. 32910f94802Smrgm4_define([_LT_WITH_AIX_SONAME], 33010f94802Smrg[m4_define([_LT_WITH_AIX_SONAME_DEFAULT], [m4_if($1, svr4, svr4, m4_if($1, both, both, aix))])dnl 33110f94802Smrgshared_archive_member_spec= 33210f94802Smrgcase $host,$enable_shared in 33310f94802Smrgpower*-*-aix[[5-9]]*,yes) 33410f94802Smrg AC_MSG_CHECKING([which variant of shared library versioning to provide]) 33510f94802Smrg AC_ARG_WITH([aix-soname], 33610f94802Smrg [AS_HELP_STRING([--with-aix-soname=aix|svr4|both], 33710f94802Smrg [shared library versioning (aka "SONAME") variant to provide on AIX, @<:@default=]_LT_WITH_AIX_SONAME_DEFAULT[@:>@.])], 33810f94802Smrg [case $withval in 33910f94802Smrg aix|svr4|both) 34010f94802Smrg ;; 34110f94802Smrg *) 34210f94802Smrg AC_MSG_ERROR([Unknown argument to --with-aix-soname]) 34310f94802Smrg ;; 34410f94802Smrg esac 34510f94802Smrg lt_cv_with_aix_soname=$with_aix_soname], 34610f94802Smrg [AC_CACHE_VAL([lt_cv_with_aix_soname], 34710f94802Smrg [lt_cv_with_aix_soname=]_LT_WITH_AIX_SONAME_DEFAULT) 34810f94802Smrg with_aix_soname=$lt_cv_with_aix_soname]) 34910f94802Smrg AC_MSG_RESULT([$with_aix_soname]) 35010f94802Smrg if test aix != "$with_aix_soname"; then 35110f94802Smrg # For the AIX way of multilib, we name the shared archive member 35210f94802Smrg # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o', 35310f94802Smrg # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File. 35410f94802Smrg # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag, 35510f94802Smrg # the AIX toolchain works better with OBJECT_MODE set (default 32). 35610f94802Smrg if test 64 = "${OBJECT_MODE-32}"; then 35710f94802Smrg shared_archive_member_spec=shr_64 35810f94802Smrg else 35910f94802Smrg shared_archive_member_spec=shr 36010f94802Smrg fi 36110f94802Smrg fi 36210f94802Smrg ;; 36310f94802Smrg*) 36410f94802Smrg with_aix_soname=aix 36510f94802Smrg ;; 36610f94802Smrgesac 36710f94802Smrg 36810f94802Smrg_LT_DECL([], [shared_archive_member_spec], [0], 36910f94802Smrg [Shared archive member basename, for filename based shared library versioning on AIX])dnl 37010f94802Smrg])# _LT_WITH_AIX_SONAME 37110f94802Smrg 37210f94802SmrgLT_OPTION_DEFINE([LT_INIT], [aix-soname=aix], [_LT_WITH_AIX_SONAME([aix])]) 37310f94802SmrgLT_OPTION_DEFINE([LT_INIT], [aix-soname=both], [_LT_WITH_AIX_SONAME([both])]) 37410f94802SmrgLT_OPTION_DEFINE([LT_INIT], [aix-soname=svr4], [_LT_WITH_AIX_SONAME([svr4])]) 37510f94802Smrg 37610f94802Smrg 37710f94802Smrg# _LT_WITH_PIC([MODE]) 37810f94802Smrg# -------------------- 37910f94802Smrg# implement the --with-pic flag, and support the 'pic-only' and 'no-pic' 38010f94802Smrg# LT_INIT options. 38110f94802Smrg# MODE is either 'yes' or 'no'. If omitted, it defaults to 'both'. 38210f94802Smrgm4_define([_LT_WITH_PIC], 38310f94802Smrg[AC_ARG_WITH([pic], 38410f94802Smrg [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@], 38510f94802Smrg [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], 38610f94802Smrg [lt_p=${PACKAGE-default} 38710f94802Smrg case $withval in 38810f94802Smrg yes|no) pic_mode=$withval ;; 38910f94802Smrg *) 39010f94802Smrg pic_mode=default 39110f94802Smrg # Look at the argument we got. We use all the common list separators. 39210f94802Smrg lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, 39310f94802Smrg for lt_pkg in $withval; do 39410f94802Smrg IFS=$lt_save_ifs 39510f94802Smrg if test "X$lt_pkg" = "X$lt_p"; then 39610f94802Smrg pic_mode=yes 39710f94802Smrg fi 39810f94802Smrg done 39910f94802Smrg IFS=$lt_save_ifs 40010f94802Smrg ;; 40110f94802Smrg esac], 40210f94802Smrg [pic_mode=m4_default([$1], [default])]) 40310f94802Smrg 40410f94802Smrg_LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl 40510f94802Smrg])# _LT_WITH_PIC 40610f94802Smrg 40710f94802SmrgLT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])]) 40810f94802SmrgLT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])]) 40910f94802Smrg 41010f94802Smrg# Old name: 41110f94802SmrgAU_DEFUN([AC_LIBTOOL_PICMODE], 41210f94802Smrg[_LT_SET_OPTION([LT_INIT], [pic-only]) 41310f94802SmrgAC_DIAGNOSE([obsolete], 41410f94802Smrg[$0: Remove this warning and the call to _LT_SET_OPTION when you 41510f94802Smrgput the 'pic-only' option into LT_INIT's first parameter.]) 41610f94802Smrg]) 41710f94802Smrg 41810f94802Smrgdnl aclocal-1.4 backwards compatibility: 41910f94802Smrgdnl AC_DEFUN([AC_LIBTOOL_PICMODE], []) 42010f94802Smrg 42110f94802Smrg## ----------------- ## 42210f94802Smrg## LTDL_INIT Options ## 42310f94802Smrg## ----------------- ## 42410f94802Smrg 42510f94802Smrgm4_define([_LTDL_MODE], []) 42610f94802SmrgLT_OPTION_DEFINE([LTDL_INIT], [nonrecursive], 42710f94802Smrg [m4_define([_LTDL_MODE], [nonrecursive])]) 42810f94802SmrgLT_OPTION_DEFINE([LTDL_INIT], [recursive], 42910f94802Smrg [m4_define([_LTDL_MODE], [recursive])]) 43010f94802SmrgLT_OPTION_DEFINE([LTDL_INIT], [subproject], 43110f94802Smrg [m4_define([_LTDL_MODE], [subproject])]) 43210f94802Smrg 43310f94802Smrgm4_define([_LTDL_TYPE], []) 43410f94802SmrgLT_OPTION_DEFINE([LTDL_INIT], [installable], 43510f94802Smrg [m4_define([_LTDL_TYPE], [installable])]) 43610f94802SmrgLT_OPTION_DEFINE([LTDL_INIT], [convenience], 43710f94802Smrg [m4_define([_LTDL_TYPE], [convenience])]) 438