The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1 | #! /bin/sh |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2 | # Guess values for system-dependent variables and create Makefiles. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3 | # Generated by GNU Autoconf 2.69. |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4 | # |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5 | # |
| 6 | # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. |
| 7 | # |
| 8 | # |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9 | # This configure script is free software; the Free Software Foundation |
| 10 | # gives unlimited permission to copy, distribute and modify it. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 11 | ## -------------------- ## |
| 12 | ## M4sh Initialization. ## |
| 13 | ## -------------------- ## |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 14 | |
| 15 | # Be more Bourne compatible |
| 16 | DUALCASE=1; export DUALCASE # for MKS sh |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 17 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 18 | emulate sh |
| 19 | NULLCMD=: |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 20 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 21 | # is contrary to our usage. Disable this feature. |
| 22 | alias -g '${1+"$@"}'='"$@"' |
| 23 | setopt NO_GLOB_SUBST |
| 24 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 25 | case `(set -o) 2>/dev/null` in #( |
| 26 | *posix*) : |
| 27 | set -o posix ;; #( |
| 28 | *) : |
| 29 | ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 30 | esac |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 31 | fi |
| 32 | |
| 33 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 34 | as_nl=' |
| 35 | ' |
| 36 | export as_nl |
| 37 | # Printing a long string crashes Solaris 7 /usr/bin/printf. |
| 38 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' |
| 39 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo |
| 40 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo |
| 41 | # Prefer a ksh shell builtin over an external printf program on Solaris, |
| 42 | # but without wasting forks for bash or zsh. |
| 43 | if test -z "$BASH_VERSION$ZSH_VERSION" \ |
| 44 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 45 | as_echo='print -r --' |
| 46 | as_echo_n='print -rn --' |
| 47 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 48 | as_echo='printf %s\n' |
| 49 | as_echo_n='printf %s' |
| 50 | else |
| 51 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then |
| 52 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' |
| 53 | as_echo_n='/usr/ucb/echo -n' |
| 54 | else |
| 55 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' |
| 56 | as_echo_n_body='eval |
| 57 | arg=$1; |
| 58 | case $arg in #( |
| 59 | *"$as_nl"*) |
| 60 | expr "X$arg" : "X\\(.*\\)$as_nl"; |
| 61 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; |
| 62 | esac; |
| 63 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" |
| 64 | ' |
| 65 | export as_echo_n_body |
| 66 | as_echo_n='sh -c $as_echo_n_body as_echo' |
| 67 | fi |
| 68 | export as_echo_body |
| 69 | as_echo='sh -c $as_echo_body as_echo' |
| 70 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 71 | |
| 72 | # The user is always right. |
| 73 | if test "${PATH_SEPARATOR+set}" != set; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 74 | PATH_SEPARATOR=: |
| 75 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { |
| 76 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || |
| 77 | PATH_SEPARATOR=';' |
| 78 | } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 79 | fi |
| 80 | |
| 81 | |
| 82 | # IFS |
| 83 | # We need space, tab and new line, in precisely that order. Quoting is |
| 84 | # there to prevent editors from complaining about space-tab. |
| 85 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word |
| 86 | # splitting by setting IFS to empty value.) |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 87 | IFS=" "" $as_nl" |
| 88 | |
| 89 | # Find who we are. Look in the path if we contain no directory separator. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 90 | as_myself= |
| 91 | case $0 in #(( |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 92 | *[\\/]* ) as_myself=$0 ;; |
| 93 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 94 | for as_dir in $PATH |
| 95 | do |
| 96 | IFS=$as_save_IFS |
| 97 | test -z "$as_dir" && as_dir=. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 98 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break |
| 99 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 100 | IFS=$as_save_IFS |
| 101 | |
| 102 | ;; |
| 103 | esac |
| 104 | # We did not find ourselves, most probably we were run as `sh COMMAND' |
| 105 | # in which case we are not to be found in the path. |
| 106 | if test "x$as_myself" = x; then |
| 107 | as_myself=$0 |
| 108 | fi |
| 109 | if test ! -f "$as_myself"; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 110 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 |
| 111 | exit 1 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 112 | fi |
| 113 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 114 | # Unset variables that we do not need and which cause bugs (e.g. in |
| 115 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" |
| 116 | # suppresses any "Segmentation fault" message there. '((' could |
| 117 | # trigger a bug in pdksh 5.2.14. |
| 118 | for as_var in BASH_ENV ENV MAIL MAILPATH |
| 119 | do eval test x\${$as_var+set} = xset \ |
| 120 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 121 | done |
| 122 | PS1='$ ' |
| 123 | PS2='> ' |
| 124 | PS4='+ ' |
| 125 | |
| 126 | # NLS nuisances. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 127 | LC_ALL=C |
| 128 | export LC_ALL |
| 129 | LANGUAGE=C |
| 130 | export LANGUAGE |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 131 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 132 | # CDPATH. |
| 133 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH |
| 134 | |
| 135 | # Use a proper internal environment variable to ensure we don't fall |
| 136 | # into an infinite loop, continuously re-executing ourselves. |
| 137 | if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then |
| 138 | _as_can_reexec=no; export _as_can_reexec; |
| 139 | # We cannot yet assume a decent shell, so we have to provide a |
| 140 | # neutralization value for shells without unset; and this also |
| 141 | # works around shells that cannot unset nonexistent variables. |
| 142 | # Preserve -v and -x to the replacement shell. |
| 143 | BASH_ENV=/dev/null |
| 144 | ENV=/dev/null |
| 145 | (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV |
| 146 | case $- in # (((( |
| 147 | *v*x* | *x*v* ) as_opts=-vx ;; |
| 148 | *v* ) as_opts=-v ;; |
| 149 | *x* ) as_opts=-x ;; |
| 150 | * ) as_opts= ;; |
| 151 | esac |
| 152 | exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} |
| 153 | # Admittedly, this is quite paranoid, since all the known shells bail |
| 154 | # out after a failed `exec'. |
| 155 | $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 |
| 156 | as_fn_exit 255 |
| 157 | fi |
| 158 | # We don't want this to propagate to other subprocesses. |
| 159 | { _as_can_reexec=; unset _as_can_reexec;} |
| 160 | if test "x$CONFIG_SHELL" = x; then |
| 161 | as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : |
| 162 | emulate sh |
| 163 | NULLCMD=: |
| 164 | # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which |
| 165 | # is contrary to our usage. Disable this feature. |
| 166 | alias -g '\${1+\"\$@\"}'='\"\$@\"' |
| 167 | setopt NO_GLOB_SUBST |
| 168 | else |
| 169 | case \`(set -o) 2>/dev/null\` in #( |
| 170 | *posix*) : |
| 171 | set -o posix ;; #( |
| 172 | *) : |
| 173 | ;; |
| 174 | esac |
| 175 | fi |
| 176 | " |
| 177 | as_required="as_fn_return () { (exit \$1); } |
| 178 | as_fn_success () { as_fn_return 0; } |
| 179 | as_fn_failure () { as_fn_return 1; } |
| 180 | as_fn_ret_success () { return 0; } |
| 181 | as_fn_ret_failure () { return 1; } |
| 182 | |
| 183 | exitcode=0 |
| 184 | as_fn_success || { exitcode=1; echo as_fn_success failed.; } |
| 185 | as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } |
| 186 | as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } |
| 187 | as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } |
| 188 | if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : |
| 189 | |
| 190 | else |
| 191 | exitcode=1; echo positional parameters were not saved. |
| 192 | fi |
| 193 | test x\$exitcode = x0 || exit 1 |
| 194 | test -x / || exit 1" |
| 195 | as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO |
| 196 | as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO |
| 197 | eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && |
| 198 | test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 |
| 199 | test \$(( 1 + 1 )) = 2 || exit 1" |
| 200 | if (eval "$as_required") 2>/dev/null; then : |
| 201 | as_have_required=yes |
| 202 | else |
| 203 | as_have_required=no |
| 204 | fi |
| 205 | if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : |
| 206 | |
| 207 | else |
| 208 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 209 | as_found=false |
| 210 | for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH |
| 211 | do |
| 212 | IFS=$as_save_IFS |
| 213 | test -z "$as_dir" && as_dir=. |
| 214 | as_found=: |
| 215 | case $as_dir in #( |
| 216 | /*) |
| 217 | for as_base in sh bash ksh sh5; do |
| 218 | # Try only shells that exist, to save several forks. |
| 219 | as_shell=$as_dir/$as_base |
| 220 | if { test -f "$as_shell" || test -f "$as_shell.exe"; } && |
| 221 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : |
| 222 | CONFIG_SHELL=$as_shell as_have_required=yes |
| 223 | if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : |
| 224 | break 2 |
| 225 | fi |
| 226 | fi |
| 227 | done;; |
| 228 | esac |
| 229 | as_found=false |
| 230 | done |
| 231 | $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && |
| 232 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : |
| 233 | CONFIG_SHELL=$SHELL as_have_required=yes |
| 234 | fi; } |
| 235 | IFS=$as_save_IFS |
| 236 | |
| 237 | |
| 238 | if test "x$CONFIG_SHELL" != x; then : |
| 239 | export CONFIG_SHELL |
| 240 | # We cannot yet assume a decent shell, so we have to provide a |
| 241 | # neutralization value for shells without unset; and this also |
| 242 | # works around shells that cannot unset nonexistent variables. |
| 243 | # Preserve -v and -x to the replacement shell. |
| 244 | BASH_ENV=/dev/null |
| 245 | ENV=/dev/null |
| 246 | (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV |
| 247 | case $- in # (((( |
| 248 | *v*x* | *x*v* ) as_opts=-vx ;; |
| 249 | *v* ) as_opts=-v ;; |
| 250 | *x* ) as_opts=-x ;; |
| 251 | * ) as_opts= ;; |
| 252 | esac |
| 253 | exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} |
| 254 | # Admittedly, this is quite paranoid, since all the known shells bail |
| 255 | # out after a failed `exec'. |
| 256 | $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 |
| 257 | exit 255 |
| 258 | fi |
| 259 | |
| 260 | if test x$as_have_required = xno; then : |
| 261 | $as_echo "$0: This script requires a shell more modern than all" |
| 262 | $as_echo "$0: the shells that I found on your system." |
| 263 | if test x${ZSH_VERSION+set} = xset ; then |
| 264 | $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" |
| 265 | $as_echo "$0: be upgraded to zsh 4.3.4 or later." |
| 266 | else |
| 267 | $as_echo "$0: Please tell bug-autoconf@gnu.org about your system, |
| 268 | $0: including any error possibly output before this |
| 269 | $0: message. Then install a modern shell, or manually run |
| 270 | $0: the script under such a shell if you do have one." |
| 271 | fi |
| 272 | exit 1 |
| 273 | fi |
| 274 | fi |
| 275 | fi |
| 276 | SHELL=${CONFIG_SHELL-/bin/sh} |
| 277 | export SHELL |
| 278 | # Unset more variables known to interfere with behavior of common tools. |
| 279 | CLICOLOR_FORCE= GREP_OPTIONS= |
| 280 | unset CLICOLOR_FORCE GREP_OPTIONS |
| 281 | |
| 282 | ## --------------------- ## |
| 283 | ## M4sh Shell Functions. ## |
| 284 | ## --------------------- ## |
| 285 | # as_fn_unset VAR |
| 286 | # --------------- |
| 287 | # Portably unset VAR. |
| 288 | as_fn_unset () |
| 289 | { |
| 290 | { eval $1=; unset $1;} |
| 291 | } |
| 292 | as_unset=as_fn_unset |
| 293 | |
| 294 | # as_fn_set_status STATUS |
| 295 | # ----------------------- |
| 296 | # Set $? to STATUS, without forking. |
| 297 | as_fn_set_status () |
| 298 | { |
| 299 | return $1 |
| 300 | } # as_fn_set_status |
| 301 | |
| 302 | # as_fn_exit STATUS |
| 303 | # ----------------- |
| 304 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. |
| 305 | as_fn_exit () |
| 306 | { |
| 307 | set +e |
| 308 | as_fn_set_status $1 |
| 309 | exit $1 |
| 310 | } # as_fn_exit |
| 311 | |
| 312 | # as_fn_mkdir_p |
| 313 | # ------------- |
| 314 | # Create "$as_dir" as a directory, including parents if necessary. |
| 315 | as_fn_mkdir_p () |
| 316 | { |
| 317 | |
| 318 | case $as_dir in #( |
| 319 | -*) as_dir=./$as_dir;; |
| 320 | esac |
| 321 | test -d "$as_dir" || eval $as_mkdir_p || { |
| 322 | as_dirs= |
| 323 | while :; do |
| 324 | case $as_dir in #( |
| 325 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( |
| 326 | *) as_qdir=$as_dir;; |
| 327 | esac |
| 328 | as_dirs="'$as_qdir' $as_dirs" |
| 329 | as_dir=`$as_dirname -- "$as_dir" || |
| 330 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 331 | X"$as_dir" : 'X\(//\)[^/]' \| \ |
| 332 | X"$as_dir" : 'X\(//\)$' \| \ |
| 333 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || |
| 334 | $as_echo X"$as_dir" | |
| 335 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 336 | s//\1/ |
| 337 | q |
| 338 | } |
| 339 | /^X\(\/\/\)[^/].*/{ |
| 340 | s//\1/ |
| 341 | q |
| 342 | } |
| 343 | /^X\(\/\/\)$/{ |
| 344 | s//\1/ |
| 345 | q |
| 346 | } |
| 347 | /^X\(\/\).*/{ |
| 348 | s//\1/ |
| 349 | q |
| 350 | } |
| 351 | s/.*/./; q'` |
| 352 | test -d "$as_dir" && break |
| 353 | done |
| 354 | test -z "$as_dirs" || eval "mkdir $as_dirs" |
| 355 | } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" |
| 356 | |
| 357 | |
| 358 | } # as_fn_mkdir_p |
| 359 | |
| 360 | # as_fn_executable_p FILE |
| 361 | # ----------------------- |
| 362 | # Test if FILE is an executable regular file. |
| 363 | as_fn_executable_p () |
| 364 | { |
| 365 | test -f "$1" && test -x "$1" |
| 366 | } # as_fn_executable_p |
| 367 | # as_fn_append VAR VALUE |
| 368 | # ---------------------- |
| 369 | # Append the text in VALUE to the end of the definition contained in VAR. Take |
| 370 | # advantage of any shell optimizations that allow amortized linear growth over |
| 371 | # repeated appends, instead of the typical quadratic growth present in naive |
| 372 | # implementations. |
| 373 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : |
| 374 | eval 'as_fn_append () |
| 375 | { |
| 376 | eval $1+=\$2 |
| 377 | }' |
| 378 | else |
| 379 | as_fn_append () |
| 380 | { |
| 381 | eval $1=\$$1\$2 |
| 382 | } |
| 383 | fi # as_fn_append |
| 384 | |
| 385 | # as_fn_arith ARG... |
| 386 | # ------------------ |
| 387 | # Perform arithmetic evaluation on the ARGs, and store the result in the |
| 388 | # global $as_val. Take advantage of shells that can avoid forks. The arguments |
| 389 | # must be portable across $(()) and expr. |
| 390 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : |
| 391 | eval 'as_fn_arith () |
| 392 | { |
| 393 | as_val=$(( $* )) |
| 394 | }' |
| 395 | else |
| 396 | as_fn_arith () |
| 397 | { |
| 398 | as_val=`expr "$@" || test $? -eq 1` |
| 399 | } |
| 400 | fi # as_fn_arith |
| 401 | |
| 402 | |
| 403 | # as_fn_error STATUS ERROR [LINENO LOG_FD] |
| 404 | # ---------------------------------------- |
| 405 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are |
| 406 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the |
| 407 | # script with STATUS, using 1 if that was 0. |
| 408 | as_fn_error () |
| 409 | { |
| 410 | as_status=$1; test $as_status -eq 0 && as_status=1 |
| 411 | if test "$4"; then |
| 412 | as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 413 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 |
| 414 | fi |
| 415 | $as_echo "$as_me: error: $2" >&2 |
| 416 | as_fn_exit $as_status |
| 417 | } # as_fn_error |
| 418 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 419 | if expr a : '\(a\)' >/dev/null 2>&1 && |
| 420 | test "X`expr 00001 : '.*\(...\)'`" = X001; then |
| 421 | as_expr=expr |
| 422 | else |
| 423 | as_expr=false |
| 424 | fi |
| 425 | |
| 426 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
| 427 | as_basename=basename |
| 428 | else |
| 429 | as_basename=false |
| 430 | fi |
| 431 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 432 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
| 433 | as_dirname=dirname |
| 434 | else |
| 435 | as_dirname=false |
| 436 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 437 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 438 | as_me=`$as_basename -- "$0" || |
| 439 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
| 440 | X"$0" : 'X\(//\)$' \| \ |
| 441 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 442 | $as_echo X/"$0" | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 443 | sed '/^.*\/\([^/][^/]*\)\/*$/{ |
| 444 | s//\1/ |
| 445 | q |
| 446 | } |
| 447 | /^X\/\(\/\/\)$/{ |
| 448 | s//\1/ |
| 449 | q |
| 450 | } |
| 451 | /^X\/\(\/\).*/{ |
| 452 | s//\1/ |
| 453 | q |
| 454 | } |
| 455 | s/.*/./; q'` |
| 456 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 457 | # Avoid depending upon Character Ranges. |
| 458 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' |
| 459 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' |
| 460 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS |
| 461 | as_cr_digits='0123456789' |
| 462 | as_cr_alnum=$as_cr_Letters$as_cr_digits |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 463 | |
| 464 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 465 | as_lineno_1=$LINENO as_lineno_1a=$LINENO |
| 466 | as_lineno_2=$LINENO as_lineno_2a=$LINENO |
| 467 | eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && |
| 468 | test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { |
| 469 | # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 470 | sed -n ' |
| 471 | p |
| 472 | /[$]LINENO/= |
| 473 | ' <$as_myself | |
| 474 | sed ' |
| 475 | s/[$]LINENO.*/&-/ |
| 476 | t lineno |
| 477 | b |
| 478 | :lineno |
| 479 | N |
| 480 | :loop |
| 481 | s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ |
| 482 | t loop |
| 483 | s/-\n.*// |
| 484 | ' >$as_me.lineno && |
| 485 | chmod +x "$as_me.lineno" || |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 486 | { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 487 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 488 | # If we had to re-execute with $CONFIG_SHELL, we're ensured to have |
| 489 | # already done that, so ensure we don't try to do so again and fall |
| 490 | # in an infinite loop. This has already happened in practice. |
| 491 | _as_can_reexec=no; export _as_can_reexec |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 492 | # Don't try to exec as it changes $[0], causing all sort of problems |
| 493 | # (the dirname of $[0] is not the place where we might find the |
| 494 | # original and so on. Autoconf is especially sensitive to this). |
| 495 | . "./$as_me.lineno" |
| 496 | # Exit status is that of the last command. |
| 497 | exit |
| 498 | } |
| 499 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 500 | ECHO_C= ECHO_N= ECHO_T= |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 501 | case `echo -n x` in #((((( |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 502 | -n*) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 503 | case `echo 'xy\c'` in |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 504 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 505 | xy) ECHO_C='\c';; |
| 506 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null |
| 507 | ECHO_T=' ';; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 508 | esac;; |
| 509 | *) |
| 510 | ECHO_N='-n';; |
| 511 | esac |
| 512 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 513 | rm -f conf$$ conf$$.exe conf$$.file |
| 514 | if test -d conf$$.dir; then |
| 515 | rm -f conf$$.dir/conf$$.file |
| 516 | else |
| 517 | rm -f conf$$.dir |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 518 | mkdir conf$$.dir 2>/dev/null |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 519 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 520 | if (echo >conf$$.file) 2>/dev/null; then |
| 521 | if ln -s conf$$.file conf$$ 2>/dev/null; then |
| 522 | as_ln_s='ln -s' |
| 523 | # ... but there are two gotchas: |
| 524 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. |
| 525 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. |
| 526 | # In both cases, we have to default to `cp -pR'. |
| 527 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || |
| 528 | as_ln_s='cp -pR' |
| 529 | elif ln conf$$.file conf$$ 2>/dev/null; then |
| 530 | as_ln_s=ln |
| 531 | else |
| 532 | as_ln_s='cp -pR' |
| 533 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 534 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 535 | as_ln_s='cp -pR' |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 536 | fi |
| 537 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
| 538 | rmdir conf$$.dir 2>/dev/null |
| 539 | |
| 540 | if mkdir -p . 2>/dev/null; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 541 | as_mkdir_p='mkdir -p "$as_dir"' |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 542 | else |
| 543 | test -d ./-p && rmdir ./-p |
| 544 | as_mkdir_p=false |
| 545 | fi |
| 546 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 547 | as_test_x='test -x' |
| 548 | as_executable_p=as_fn_executable_p |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 549 | |
| 550 | # Sed expression to map a string onto a valid CPP name. |
| 551 | as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" |
| 552 | |
| 553 | # Sed expression to map a string onto a valid variable name. |
| 554 | as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" |
| 555 | |
| 556 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 557 | test -n "$DJDIR" || exec 7<&0 </dev/null |
| 558 | exec 6>&1 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 559 | |
| 560 | # Name of the host. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 561 | # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 562 | # so uname gets run too. |
| 563 | ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` |
| 564 | |
| 565 | # |
| 566 | # Initializations. |
| 567 | # |
| 568 | ac_default_prefix=/usr/local |
| 569 | ac_clean_files= |
| 570 | ac_config_libobj_dir=. |
| 571 | LIBOBJS= |
| 572 | cross_compiling=no |
| 573 | subdirs= |
| 574 | MFLAGS= |
| 575 | MAKEFLAGS= |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 576 | |
| 577 | # Identity of this package. |
| 578 | PACKAGE_NAME= |
| 579 | PACKAGE_TARNAME= |
| 580 | PACKAGE_VERSION= |
| 581 | PACKAGE_STRING= |
| 582 | PACKAGE_BUGREPORT= |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 583 | PACKAGE_URL= |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 584 | |
| 585 | ac_unique_file="pcap.c" |
| 586 | # Factoring default headers for most tests. |
| 587 | ac_includes_default="\ |
| 588 | #include <stdio.h> |
| 589 | #ifdef HAVE_SYS_TYPES_H |
| 590 | # include <sys/types.h> |
| 591 | #endif |
| 592 | #ifdef HAVE_SYS_STAT_H |
| 593 | # include <sys/stat.h> |
| 594 | #endif |
| 595 | #ifdef STDC_HEADERS |
| 596 | # include <stdlib.h> |
| 597 | # include <stddef.h> |
| 598 | #else |
| 599 | # ifdef HAVE_STDLIB_H |
| 600 | # include <stdlib.h> |
| 601 | # endif |
| 602 | #endif |
| 603 | #ifdef HAVE_STRING_H |
| 604 | # if !defined STDC_HEADERS && defined HAVE_MEMORY_H |
| 605 | # include <memory.h> |
| 606 | # endif |
| 607 | # include <string.h> |
| 608 | #endif |
| 609 | #ifdef HAVE_STRINGS_H |
| 610 | # include <strings.h> |
| 611 | #endif |
| 612 | #ifdef HAVE_INTTYPES_H |
| 613 | # include <inttypes.h> |
| 614 | #endif |
| 615 | #ifdef HAVE_STDINT_H |
| 616 | # include <stdint.h> |
| 617 | #endif |
| 618 | #ifdef HAVE_UNISTD_H |
| 619 | # include <unistd.h> |
| 620 | #endif" |
| 621 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 622 | ac_subst_vars='LTLIBOBJS |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 623 | INSTALL_DATA |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 624 | INSTALL_SCRIPT |
| 625 | INSTALL_PROGRAM |
| 626 | DBUS_SRC |
| 627 | PCAP_SUPPORT_DBUS |
| 628 | PKGCONFIG |
| 629 | CAN_SRC |
| 630 | PCAP_SUPPORT_CAN |
| 631 | CANUSB_SRC |
| 632 | PCAP_SUPPORT_CANUSB |
| 633 | BT_SRC |
| 634 | PCAP_SUPPORT_BT |
| 635 | NETFILTER_SRC |
| 636 | PCAP_SUPPORT_NETFILTER |
| 637 | USB_SRC |
| 638 | PCAP_SUPPORT_USB |
| 639 | MAN_MISC_INFO |
| 640 | MAN_FILE_FORMATS |
| 641 | DYEXT |
| 642 | SSRC |
| 643 | ADDLARCHIVEOBJS |
| 644 | ADDLOBJS |
| 645 | V_RPATH_OPT |
| 646 | V_SONAME_OPT |
| 647 | V_SHLIB_OPT |
| 648 | V_SHLIB_CMD |
| 649 | V_PCAP |
| 650 | V_INCLS |
| 651 | V_FINDALLDEVS |
| 652 | V_DEFS |
| 653 | V_CCOPT |
| 654 | MKDEP |
| 655 | DEPENDENCY_CFLAG |
| 656 | LN_S |
| 657 | AR |
| 658 | RANLIB |
| 659 | V_YACC |
| 660 | V_LEX |
| 661 | HAVE_LINUX_TPACKET_AUXDATA |
| 662 | LIBOBJS |
| 663 | EGREP |
| 664 | GREP |
| 665 | CPP |
| 666 | OBJEXT |
| 667 | EXEEXT |
| 668 | ac_ct_CC |
| 669 | CPPFLAGS |
| 670 | LDFLAGS |
| 671 | CFLAGS |
| 672 | CC |
| 673 | SHLICC2 |
| 674 | target_os |
| 675 | target_vendor |
| 676 | target_cpu |
| 677 | target |
| 678 | host_os |
| 679 | host_vendor |
| 680 | host_cpu |
| 681 | host |
| 682 | build_os |
| 683 | build_vendor |
| 684 | build_cpu |
| 685 | build |
| 686 | target_alias |
| 687 | host_alias |
| 688 | build_alias |
| 689 | LIBS |
| 690 | ECHO_T |
| 691 | ECHO_N |
| 692 | ECHO_C |
| 693 | DEFS |
| 694 | mandir |
| 695 | localedir |
| 696 | libdir |
| 697 | psdir |
| 698 | pdfdir |
| 699 | dvidir |
| 700 | htmldir |
| 701 | infodir |
| 702 | docdir |
| 703 | oldincludedir |
| 704 | includedir |
| 705 | localstatedir |
| 706 | sharedstatedir |
| 707 | sysconfdir |
| 708 | datadir |
| 709 | datarootdir |
| 710 | libexecdir |
| 711 | sbindir |
| 712 | bindir |
| 713 | program_transform_name |
| 714 | prefix |
| 715 | exec_prefix |
| 716 | PACKAGE_URL |
| 717 | PACKAGE_BUGREPORT |
| 718 | PACKAGE_STRING |
| 719 | PACKAGE_VERSION |
| 720 | PACKAGE_TARNAME |
| 721 | PACKAGE_NAME |
| 722 | PATH_SEPARATOR |
| 723 | SHELL' |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 724 | ac_subst_files='' |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 725 | ac_user_opts=' |
| 726 | enable_option_checking |
| 727 | with_gcc |
| 728 | enable_largefile |
| 729 | enable_protochain |
| 730 | with_sita |
| 731 | with_pcap |
| 732 | with_libnl |
| 733 | enable_ipv6 |
| 734 | enable_optimizer_dbg |
| 735 | enable_yydebug |
| 736 | with_dag |
| 737 | with_dag_includes |
| 738 | with_dag_libraries |
| 739 | with_septel |
| 740 | with_snf |
| 741 | with_snf_includes |
| 742 | with_snf_libraries |
| 743 | with_flex |
| 744 | with_bison |
| 745 | enable_universal |
| 746 | enable_shared |
| 747 | enable_bluetooth |
| 748 | enable_canusb |
| 749 | enable_can |
| 750 | enable_dbus |
| 751 | ' |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 752 | ac_precious_vars='build_alias |
| 753 | host_alias |
| 754 | target_alias |
| 755 | CC |
| 756 | CFLAGS |
| 757 | LDFLAGS |
| 758 | LIBS |
| 759 | CPPFLAGS |
| 760 | CPP' |
| 761 | |
| 762 | |
| 763 | # Initialize some variables set by options. |
| 764 | ac_init_help= |
| 765 | ac_init_version=false |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 766 | ac_unrecognized_opts= |
| 767 | ac_unrecognized_sep= |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 768 | # The variables have the same names as the options, with |
| 769 | # dashes changed to underlines. |
| 770 | cache_file=/dev/null |
| 771 | exec_prefix=NONE |
| 772 | no_create= |
| 773 | no_recursion= |
| 774 | prefix=NONE |
| 775 | program_prefix=NONE |
| 776 | program_suffix=NONE |
| 777 | program_transform_name=s,x,x, |
| 778 | silent= |
| 779 | site= |
| 780 | srcdir= |
| 781 | verbose= |
| 782 | x_includes=NONE |
| 783 | x_libraries=NONE |
| 784 | |
| 785 | # Installation directory options. |
| 786 | # These are left unexpanded so users can "make install exec_prefix=/foo" |
| 787 | # and all the variables that are supposed to be based on exec_prefix |
| 788 | # by default will actually change. |
| 789 | # Use braces instead of parens because sh, perl, etc. also accept them. |
| 790 | # (The list follows the same order as the GNU Coding Standards.) |
| 791 | bindir='${exec_prefix}/bin' |
| 792 | sbindir='${exec_prefix}/sbin' |
| 793 | libexecdir='${exec_prefix}/libexec' |
| 794 | datarootdir='${prefix}/share' |
| 795 | datadir='${datarootdir}' |
| 796 | sysconfdir='${prefix}/etc' |
| 797 | sharedstatedir='${prefix}/com' |
| 798 | localstatedir='${prefix}/var' |
| 799 | includedir='${prefix}/include' |
| 800 | oldincludedir='/usr/include' |
| 801 | docdir='${datarootdir}/doc/${PACKAGE}' |
| 802 | infodir='${datarootdir}/info' |
| 803 | htmldir='${docdir}' |
| 804 | dvidir='${docdir}' |
| 805 | pdfdir='${docdir}' |
| 806 | psdir='${docdir}' |
| 807 | libdir='${exec_prefix}/lib' |
| 808 | localedir='${datarootdir}/locale' |
| 809 | mandir='${datarootdir}/man' |
| 810 | |
| 811 | ac_prev= |
| 812 | ac_dashdash= |
| 813 | for ac_option |
| 814 | do |
| 815 | # If the previous option needs an argument, assign it. |
| 816 | if test -n "$ac_prev"; then |
| 817 | eval $ac_prev=\$ac_option |
| 818 | ac_prev= |
| 819 | continue |
| 820 | fi |
| 821 | |
| 822 | case $ac_option in |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 823 | *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; |
| 824 | *=) ac_optarg= ;; |
| 825 | *) ac_optarg=yes ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 826 | esac |
| 827 | |
| 828 | # Accept the important Cygnus configure options, so we can diagnose typos. |
| 829 | |
| 830 | case $ac_dashdash$ac_option in |
| 831 | --) |
| 832 | ac_dashdash=yes ;; |
| 833 | |
| 834 | -bindir | --bindir | --bindi | --bind | --bin | --bi) |
| 835 | ac_prev=bindir ;; |
| 836 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) |
| 837 | bindir=$ac_optarg ;; |
| 838 | |
| 839 | -build | --build | --buil | --bui | --bu) |
| 840 | ac_prev=build_alias ;; |
| 841 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
| 842 | build_alias=$ac_optarg ;; |
| 843 | |
| 844 | -cache-file | --cache-file | --cache-fil | --cache-fi \ |
| 845 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) |
| 846 | ac_prev=cache_file ;; |
| 847 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ |
| 848 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) |
| 849 | cache_file=$ac_optarg ;; |
| 850 | |
| 851 | --config-cache | -C) |
| 852 | cache_file=config.cache ;; |
| 853 | |
| 854 | -datadir | --datadir | --datadi | --datad) |
| 855 | ac_prev=datadir ;; |
| 856 | -datadir=* | --datadir=* | --datadi=* | --datad=*) |
| 857 | datadir=$ac_optarg ;; |
| 858 | |
| 859 | -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ |
| 860 | | --dataroo | --dataro | --datar) |
| 861 | ac_prev=datarootdir ;; |
| 862 | -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ |
| 863 | | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) |
| 864 | datarootdir=$ac_optarg ;; |
| 865 | |
| 866 | -disable-* | --disable-*) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 867 | ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 868 | # Reject names that are not valid shell variable names. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 869 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
| 870 | as_fn_error $? "invalid feature name: $ac_useropt" |
| 871 | ac_useropt_orig=$ac_useropt |
| 872 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 873 | case $ac_user_opts in |
| 874 | *" |
| 875 | "enable_$ac_useropt" |
| 876 | "*) ;; |
| 877 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" |
| 878 | ac_unrecognized_sep=', ';; |
| 879 | esac |
| 880 | eval enable_$ac_useropt=no ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 881 | |
| 882 | -docdir | --docdir | --docdi | --doc | --do) |
| 883 | ac_prev=docdir ;; |
| 884 | -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) |
| 885 | docdir=$ac_optarg ;; |
| 886 | |
| 887 | -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) |
| 888 | ac_prev=dvidir ;; |
| 889 | -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) |
| 890 | dvidir=$ac_optarg ;; |
| 891 | |
| 892 | -enable-* | --enable-*) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 893 | ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 894 | # Reject names that are not valid shell variable names. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 895 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
| 896 | as_fn_error $? "invalid feature name: $ac_useropt" |
| 897 | ac_useropt_orig=$ac_useropt |
| 898 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 899 | case $ac_user_opts in |
| 900 | *" |
| 901 | "enable_$ac_useropt" |
| 902 | "*) ;; |
| 903 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" |
| 904 | ac_unrecognized_sep=', ';; |
| 905 | esac |
| 906 | eval enable_$ac_useropt=\$ac_optarg ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 907 | |
| 908 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ |
| 909 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ |
| 910 | | --exec | --exe | --ex) |
| 911 | ac_prev=exec_prefix ;; |
| 912 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ |
| 913 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ |
| 914 | | --exec=* | --exe=* | --ex=*) |
| 915 | exec_prefix=$ac_optarg ;; |
| 916 | |
| 917 | -gas | --gas | --ga | --g) |
| 918 | # Obsolete; use --with-gas. |
| 919 | with_gas=yes ;; |
| 920 | |
| 921 | -help | --help | --hel | --he | -h) |
| 922 | ac_init_help=long ;; |
| 923 | -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) |
| 924 | ac_init_help=recursive ;; |
| 925 | -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) |
| 926 | ac_init_help=short ;; |
| 927 | |
| 928 | -host | --host | --hos | --ho) |
| 929 | ac_prev=host_alias ;; |
| 930 | -host=* | --host=* | --hos=* | --ho=*) |
| 931 | host_alias=$ac_optarg ;; |
| 932 | |
| 933 | -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) |
| 934 | ac_prev=htmldir ;; |
| 935 | -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ |
| 936 | | --ht=*) |
| 937 | htmldir=$ac_optarg ;; |
| 938 | |
| 939 | -includedir | --includedir | --includedi | --included | --include \ |
| 940 | | --includ | --inclu | --incl | --inc) |
| 941 | ac_prev=includedir ;; |
| 942 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ |
| 943 | | --includ=* | --inclu=* | --incl=* | --inc=*) |
| 944 | includedir=$ac_optarg ;; |
| 945 | |
| 946 | -infodir | --infodir | --infodi | --infod | --info | --inf) |
| 947 | ac_prev=infodir ;; |
| 948 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) |
| 949 | infodir=$ac_optarg ;; |
| 950 | |
| 951 | -libdir | --libdir | --libdi | --libd) |
| 952 | ac_prev=libdir ;; |
| 953 | -libdir=* | --libdir=* | --libdi=* | --libd=*) |
| 954 | libdir=$ac_optarg ;; |
| 955 | |
| 956 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ |
| 957 | | --libexe | --libex | --libe) |
| 958 | ac_prev=libexecdir ;; |
| 959 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ |
| 960 | | --libexe=* | --libex=* | --libe=*) |
| 961 | libexecdir=$ac_optarg ;; |
| 962 | |
| 963 | -localedir | --localedir | --localedi | --localed | --locale) |
| 964 | ac_prev=localedir ;; |
| 965 | -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) |
| 966 | localedir=$ac_optarg ;; |
| 967 | |
| 968 | -localstatedir | --localstatedir | --localstatedi | --localstated \ |
| 969 | | --localstate | --localstat | --localsta | --localst | --locals) |
| 970 | ac_prev=localstatedir ;; |
| 971 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ |
| 972 | | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) |
| 973 | localstatedir=$ac_optarg ;; |
| 974 | |
| 975 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) |
| 976 | ac_prev=mandir ;; |
| 977 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) |
| 978 | mandir=$ac_optarg ;; |
| 979 | |
| 980 | -nfp | --nfp | --nf) |
| 981 | # Obsolete; use --without-fp. |
| 982 | with_fp=no ;; |
| 983 | |
| 984 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
| 985 | | --no-cr | --no-c | -n) |
| 986 | no_create=yes ;; |
| 987 | |
| 988 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 989 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) |
| 990 | no_recursion=yes ;; |
| 991 | |
| 992 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ |
| 993 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ |
| 994 | | --oldin | --oldi | --old | --ol | --o) |
| 995 | ac_prev=oldincludedir ;; |
| 996 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ |
| 997 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ |
| 998 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) |
| 999 | oldincludedir=$ac_optarg ;; |
| 1000 | |
| 1001 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) |
| 1002 | ac_prev=prefix ;; |
| 1003 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) |
| 1004 | prefix=$ac_optarg ;; |
| 1005 | |
| 1006 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ |
| 1007 | | --program-pre | --program-pr | --program-p) |
| 1008 | ac_prev=program_prefix ;; |
| 1009 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ |
| 1010 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) |
| 1011 | program_prefix=$ac_optarg ;; |
| 1012 | |
| 1013 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ |
| 1014 | | --program-suf | --program-su | --program-s) |
| 1015 | ac_prev=program_suffix ;; |
| 1016 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ |
| 1017 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) |
| 1018 | program_suffix=$ac_optarg ;; |
| 1019 | |
| 1020 | -program-transform-name | --program-transform-name \ |
| 1021 | | --program-transform-nam | --program-transform-na \ |
| 1022 | | --program-transform-n | --program-transform- \ |
| 1023 | | --program-transform | --program-transfor \ |
| 1024 | | --program-transfo | --program-transf \ |
| 1025 | | --program-trans | --program-tran \ |
| 1026 | | --progr-tra | --program-tr | --program-t) |
| 1027 | ac_prev=program_transform_name ;; |
| 1028 | -program-transform-name=* | --program-transform-name=* \ |
| 1029 | | --program-transform-nam=* | --program-transform-na=* \ |
| 1030 | | --program-transform-n=* | --program-transform-=* \ |
| 1031 | | --program-transform=* | --program-transfor=* \ |
| 1032 | | --program-transfo=* | --program-transf=* \ |
| 1033 | | --program-trans=* | --program-tran=* \ |
| 1034 | | --progr-tra=* | --program-tr=* | --program-t=*) |
| 1035 | program_transform_name=$ac_optarg ;; |
| 1036 | |
| 1037 | -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) |
| 1038 | ac_prev=pdfdir ;; |
| 1039 | -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) |
| 1040 | pdfdir=$ac_optarg ;; |
| 1041 | |
| 1042 | -psdir | --psdir | --psdi | --psd | --ps) |
| 1043 | ac_prev=psdir ;; |
| 1044 | -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) |
| 1045 | psdir=$ac_optarg ;; |
| 1046 | |
| 1047 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 1048 | | -silent | --silent | --silen | --sile | --sil) |
| 1049 | silent=yes ;; |
| 1050 | |
| 1051 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) |
| 1052 | ac_prev=sbindir ;; |
| 1053 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ |
| 1054 | | --sbi=* | --sb=*) |
| 1055 | sbindir=$ac_optarg ;; |
| 1056 | |
| 1057 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ |
| 1058 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ |
| 1059 | | --sharedst | --shareds | --shared | --share | --shar \ |
| 1060 | | --sha | --sh) |
| 1061 | ac_prev=sharedstatedir ;; |
| 1062 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ |
| 1063 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ |
| 1064 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ |
| 1065 | | --sha=* | --sh=*) |
| 1066 | sharedstatedir=$ac_optarg ;; |
| 1067 | |
| 1068 | -site | --site | --sit) |
| 1069 | ac_prev=site ;; |
| 1070 | -site=* | --site=* | --sit=*) |
| 1071 | site=$ac_optarg ;; |
| 1072 | |
| 1073 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) |
| 1074 | ac_prev=srcdir ;; |
| 1075 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) |
| 1076 | srcdir=$ac_optarg ;; |
| 1077 | |
| 1078 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ |
| 1079 | | --syscon | --sysco | --sysc | --sys | --sy) |
| 1080 | ac_prev=sysconfdir ;; |
| 1081 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ |
| 1082 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) |
| 1083 | sysconfdir=$ac_optarg ;; |
| 1084 | |
| 1085 | -target | --target | --targe | --targ | --tar | --ta | --t) |
| 1086 | ac_prev=target_alias ;; |
| 1087 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
| 1088 | target_alias=$ac_optarg ;; |
| 1089 | |
| 1090 | -v | -verbose | --verbose | --verbos | --verbo | --verb) |
| 1091 | verbose=yes ;; |
| 1092 | |
| 1093 | -version | --version | --versio | --versi | --vers | -V) |
| 1094 | ac_init_version=: ;; |
| 1095 | |
| 1096 | -with-* | --with-*) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1097 | ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1098 | # Reject names that are not valid shell variable names. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1099 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
| 1100 | as_fn_error $? "invalid package name: $ac_useropt" |
| 1101 | ac_useropt_orig=$ac_useropt |
| 1102 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 1103 | case $ac_user_opts in |
| 1104 | *" |
| 1105 | "with_$ac_useropt" |
| 1106 | "*) ;; |
| 1107 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" |
| 1108 | ac_unrecognized_sep=', ';; |
| 1109 | esac |
| 1110 | eval with_$ac_useropt=\$ac_optarg ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1111 | |
| 1112 | -without-* | --without-*) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1113 | ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1114 | # Reject names that are not valid shell variable names. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1115 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
| 1116 | as_fn_error $? "invalid package name: $ac_useropt" |
| 1117 | ac_useropt_orig=$ac_useropt |
| 1118 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 1119 | case $ac_user_opts in |
| 1120 | *" |
| 1121 | "with_$ac_useropt" |
| 1122 | "*) ;; |
| 1123 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" |
| 1124 | ac_unrecognized_sep=', ';; |
| 1125 | esac |
| 1126 | eval with_$ac_useropt=no ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1127 | |
| 1128 | --x) |
| 1129 | # Obsolete; use --with-x. |
| 1130 | with_x=yes ;; |
| 1131 | |
| 1132 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ |
| 1133 | | --x-incl | --x-inc | --x-in | --x-i) |
| 1134 | ac_prev=x_includes ;; |
| 1135 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ |
| 1136 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) |
| 1137 | x_includes=$ac_optarg ;; |
| 1138 | |
| 1139 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ |
| 1140 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) |
| 1141 | ac_prev=x_libraries ;; |
| 1142 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ |
| 1143 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) |
| 1144 | x_libraries=$ac_optarg ;; |
| 1145 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1146 | -*) as_fn_error $? "unrecognized option: \`$ac_option' |
| 1147 | Try \`$0 --help' for more information" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1148 | ;; |
| 1149 | |
| 1150 | *=*) |
| 1151 | ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` |
| 1152 | # Reject names that are not valid shell variable names. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1153 | case $ac_envvar in #( |
| 1154 | '' | [0-9]* | *[!_$as_cr_alnum]* ) |
| 1155 | as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; |
| 1156 | esac |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1157 | eval $ac_envvar=\$ac_optarg |
| 1158 | export $ac_envvar ;; |
| 1159 | |
| 1160 | *) |
| 1161 | # FIXME: should be removed in autoconf 3.0. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1162 | $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1163 | expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1164 | $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 |
| 1165 | : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1166 | ;; |
| 1167 | |
| 1168 | esac |
| 1169 | done |
| 1170 | |
| 1171 | if test -n "$ac_prev"; then |
| 1172 | ac_option=--`echo $ac_prev | sed 's/_/-/g'` |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1173 | as_fn_error $? "missing argument to $ac_option" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1174 | fi |
| 1175 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1176 | if test -n "$ac_unrecognized_opts"; then |
| 1177 | case $enable_option_checking in |
| 1178 | no) ;; |
| 1179 | fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; |
| 1180 | *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; |
| 1181 | esac |
| 1182 | fi |
| 1183 | |
| 1184 | # Check all directory arguments for consistency. |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1185 | for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ |
| 1186 | datadir sysconfdir sharedstatedir localstatedir includedir \ |
| 1187 | oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ |
| 1188 | libdir localedir mandir |
| 1189 | do |
| 1190 | eval ac_val=\$$ac_var |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1191 | # Remove trailing slashes. |
| 1192 | case $ac_val in |
| 1193 | */ ) |
| 1194 | ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` |
| 1195 | eval $ac_var=\$ac_val;; |
| 1196 | esac |
| 1197 | # Be sure to have absolute directory names. |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1198 | case $ac_val in |
| 1199 | [\\/$]* | ?:[\\/]* ) continue;; |
| 1200 | NONE | '' ) case $ac_var in *prefix ) continue;; esac;; |
| 1201 | esac |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1202 | as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1203 | done |
| 1204 | |
| 1205 | # There might be people who depend on the old broken behavior: `$host' |
| 1206 | # used to hold the argument of --host etc. |
| 1207 | # FIXME: To remove some day. |
| 1208 | build=$build_alias |
| 1209 | host=$host_alias |
| 1210 | target=$target_alias |
| 1211 | |
| 1212 | # FIXME: To remove some day. |
| 1213 | if test "x$host_alias" != x; then |
| 1214 | if test "x$build_alias" = x; then |
| 1215 | cross_compiling=maybe |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1216 | elif test "x$build_alias" != "x$host_alias"; then |
| 1217 | cross_compiling=yes |
| 1218 | fi |
| 1219 | fi |
| 1220 | |
| 1221 | ac_tool_prefix= |
| 1222 | test -n "$host_alias" && ac_tool_prefix=$host_alias- |
| 1223 | |
| 1224 | test "$silent" = yes && exec 6>/dev/null |
| 1225 | |
| 1226 | |
| 1227 | ac_pwd=`pwd` && test -n "$ac_pwd" && |
| 1228 | ac_ls_di=`ls -di .` && |
| 1229 | ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1230 | as_fn_error $? "working directory cannot be determined" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1231 | test "X$ac_ls_di" = "X$ac_pwd_ls_di" || |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1232 | as_fn_error $? "pwd does not report name of working directory" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1233 | |
| 1234 | |
| 1235 | # Find the source files, if location was not specified. |
| 1236 | if test -z "$srcdir"; then |
| 1237 | ac_srcdir_defaulted=yes |
| 1238 | # Try the directory containing this script, then the parent directory. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1239 | ac_confdir=`$as_dirname -- "$as_myself" || |
| 1240 | $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 1241 | X"$as_myself" : 'X\(//\)[^/]' \| \ |
| 1242 | X"$as_myself" : 'X\(//\)$' \| \ |
| 1243 | X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || |
| 1244 | $as_echo X"$as_myself" | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1245 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 1246 | s//\1/ |
| 1247 | q |
| 1248 | } |
| 1249 | /^X\(\/\/\)[^/].*/{ |
| 1250 | s//\1/ |
| 1251 | q |
| 1252 | } |
| 1253 | /^X\(\/\/\)$/{ |
| 1254 | s//\1/ |
| 1255 | q |
| 1256 | } |
| 1257 | /^X\(\/\).*/{ |
| 1258 | s//\1/ |
| 1259 | q |
| 1260 | } |
| 1261 | s/.*/./; q'` |
| 1262 | srcdir=$ac_confdir |
| 1263 | if test ! -r "$srcdir/$ac_unique_file"; then |
| 1264 | srcdir=.. |
| 1265 | fi |
| 1266 | else |
| 1267 | ac_srcdir_defaulted=no |
| 1268 | fi |
| 1269 | if test ! -r "$srcdir/$ac_unique_file"; then |
| 1270 | test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1271 | as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1272 | fi |
| 1273 | ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" |
| 1274 | ac_abs_confdir=`( |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1275 | cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1276 | pwd)` |
| 1277 | # When building in place, set srcdir=. |
| 1278 | if test "$ac_abs_confdir" = "$ac_pwd"; then |
| 1279 | srcdir=. |
| 1280 | fi |
| 1281 | # Remove unnecessary trailing slashes from srcdir. |
| 1282 | # Double slashes in file names in object file debugging info |
| 1283 | # mess up M-x gdb in Emacs. |
| 1284 | case $srcdir in |
| 1285 | */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; |
| 1286 | esac |
| 1287 | for ac_var in $ac_precious_vars; do |
| 1288 | eval ac_env_${ac_var}_set=\${${ac_var}+set} |
| 1289 | eval ac_env_${ac_var}_value=\$${ac_var} |
| 1290 | eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} |
| 1291 | eval ac_cv_env_${ac_var}_value=\$${ac_var} |
| 1292 | done |
| 1293 | |
| 1294 | # |
| 1295 | # Report the --help message. |
| 1296 | # |
| 1297 | if test "$ac_init_help" = "long"; then |
| 1298 | # Omit some internal or obsolete options to make the list less imposing. |
| 1299 | # This message is too long to be a string in the A/UX 3.1 sh. |
| 1300 | cat <<_ACEOF |
| 1301 | \`configure' configures this package to adapt to many kinds of systems. |
| 1302 | |
| 1303 | Usage: $0 [OPTION]... [VAR=VALUE]... |
| 1304 | |
| 1305 | To assign environment variables (e.g., CC, CFLAGS...), specify them as |
| 1306 | VAR=VALUE. See below for descriptions of some of the useful variables. |
| 1307 | |
| 1308 | Defaults for the options are specified in brackets. |
| 1309 | |
| 1310 | Configuration: |
| 1311 | -h, --help display this help and exit |
| 1312 | --help=short display options specific to this package |
| 1313 | --help=recursive display the short help of all the included packages |
| 1314 | -V, --version display version information and exit |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1315 | -q, --quiet, --silent do not print \`checking ...' messages |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1316 | --cache-file=FILE cache test results in FILE [disabled] |
| 1317 | -C, --config-cache alias for \`--cache-file=config.cache' |
| 1318 | -n, --no-create do not create output files |
| 1319 | --srcdir=DIR find the sources in DIR [configure dir or \`..'] |
| 1320 | |
| 1321 | Installation directories: |
| 1322 | --prefix=PREFIX install architecture-independent files in PREFIX |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1323 | [$ac_default_prefix] |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1324 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1325 | [PREFIX] |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1326 | |
| 1327 | By default, \`make install' will install all the files in |
| 1328 | \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify |
| 1329 | an installation prefix other than \`$ac_default_prefix' using \`--prefix', |
| 1330 | for instance \`--prefix=\$HOME'. |
| 1331 | |
| 1332 | For better control, use the options below. |
| 1333 | |
| 1334 | Fine tuning of the installation directories: |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1335 | --bindir=DIR user executables [EPREFIX/bin] |
| 1336 | --sbindir=DIR system admin executables [EPREFIX/sbin] |
| 1337 | --libexecdir=DIR program executables [EPREFIX/libexec] |
| 1338 | --sysconfdir=DIR read-only single-machine data [PREFIX/etc] |
| 1339 | --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] |
| 1340 | --localstatedir=DIR modifiable single-machine data [PREFIX/var] |
| 1341 | --libdir=DIR object code libraries [EPREFIX/lib] |
| 1342 | --includedir=DIR C header files [PREFIX/include] |
| 1343 | --oldincludedir=DIR C header files for non-gcc [/usr/include] |
| 1344 | --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] |
| 1345 | --datadir=DIR read-only architecture-independent data [DATAROOTDIR] |
| 1346 | --infodir=DIR info documentation [DATAROOTDIR/info] |
| 1347 | --localedir=DIR locale-dependent data [DATAROOTDIR/locale] |
| 1348 | --mandir=DIR man documentation [DATAROOTDIR/man] |
| 1349 | --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE] |
| 1350 | --htmldir=DIR html documentation [DOCDIR] |
| 1351 | --dvidir=DIR dvi documentation [DOCDIR] |
| 1352 | --pdfdir=DIR pdf documentation [DOCDIR] |
| 1353 | --psdir=DIR ps documentation [DOCDIR] |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1354 | _ACEOF |
| 1355 | |
| 1356 | cat <<\_ACEOF |
| 1357 | |
| 1358 | System types: |
| 1359 | --build=BUILD configure for building on BUILD [guessed] |
| 1360 | --host=HOST cross-compile to build programs to run on HOST [BUILD] |
| 1361 | --target=TARGET configure for building compilers for TARGET [HOST] |
| 1362 | _ACEOF |
| 1363 | fi |
| 1364 | |
| 1365 | if test -n "$ac_init_help"; then |
| 1366 | |
| 1367 | cat <<\_ACEOF |
| 1368 | |
| 1369 | Optional Features: |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1370 | --disable-option-checking ignore unrecognized --enable/--with options |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1371 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
| 1372 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1373 | --disable-largefile omit support for large files |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1374 | --disable-protochain disable \"protochain\" insn |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1375 | --enable-ipv6 build IPv6-capable version [default=yes, if |
| 1376 | getaddrinfo available] |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1377 | --enable-optimizer-dbg build optimizer debugging code |
| 1378 | --enable-yydebug build parser debugging code |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1379 | --disable-universal don't build universal on OS X |
| 1380 | --enable-shared build shared libraries [default=yes, if support |
| 1381 | available] |
| 1382 | --enable-bluetooth enable Bluetooth support [default=yes, if support |
| 1383 | available] |
| 1384 | --enable-canusb enable canusb support [default=yes, if support |
| 1385 | available] |
| 1386 | --enable-can enable CAN support [default=yes, if support |
| 1387 | available] |
| 1388 | --enable-dbus enable D-Bus capture support [default=yes, if |
| 1389 | support available] |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1390 | |
| 1391 | Optional Packages: |
| 1392 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] |
| 1393 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) |
| 1394 | --without-gcc don't use gcc |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1395 | --with-sita include SITA support |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1396 | --with-pcap=TYPE use packet capture TYPE |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1397 | --without-libnl disable libnl support [default=yes, on Linux, if |
| 1398 | present] |
| 1399 | --with-dag[=DIR] include Endace DAG support ["yes", "no" or DIR; |
| 1400 | default="yes" on BSD and Linux if present] |
| 1401 | --with-dag-includes=DIR Endace DAG include directory |
| 1402 | --with-dag-libraries=DIR |
| 1403 | Endace DAG library directory |
| 1404 | --with-septel[=DIR] include Septel support (located in directory DIR, if |
| 1405 | supplied). [default=yes, on Linux, if present] |
| 1406 | --with-snf[=DIR] include Myricom SNF support ["yes", "no" or DIR; |
| 1407 | default="yes" on BSD and Linux if present] |
| 1408 | --with-snf-includes=DIR Myricom SNF include directory |
| 1409 | --with-snf-libraries=DIR |
| 1410 | Myricom SNF library directory |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1411 | --without-flex don't use flex |
| 1412 | --without-bison don't use bison |
| 1413 | |
| 1414 | Some influential environment variables: |
| 1415 | CC C compiler command |
| 1416 | CFLAGS C compiler flags |
| 1417 | LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a |
| 1418 | nonstandard directory <lib dir> |
| 1419 | LIBS libraries to pass to the linker, e.g. -l<library> |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1420 | CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1421 | you have headers in a nonstandard directory <include dir> |
| 1422 | CPP C preprocessor |
| 1423 | |
| 1424 | Use these variables to override the choices made by `configure' or to help |
| 1425 | it to find libraries and programs with nonstandard names/locations. |
| 1426 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1427 | Report bugs to the package provider. |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1428 | _ACEOF |
| 1429 | ac_status=$? |
| 1430 | fi |
| 1431 | |
| 1432 | if test "$ac_init_help" = "recursive"; then |
| 1433 | # If there are subdirs, report their specific --help. |
| 1434 | for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1435 | test -d "$ac_dir" || |
| 1436 | { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || |
| 1437 | continue |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1438 | ac_builddir=. |
| 1439 | |
| 1440 | case "$ac_dir" in |
| 1441 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 1442 | *) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1443 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1444 | # A ".." for each directory in $ac_dir_suffix. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1445 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1446 | case $ac_top_builddir_sub in |
| 1447 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 1448 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; |
| 1449 | esac ;; |
| 1450 | esac |
| 1451 | ac_abs_top_builddir=$ac_pwd |
| 1452 | ac_abs_builddir=$ac_pwd$ac_dir_suffix |
| 1453 | # for backward compatibility: |
| 1454 | ac_top_builddir=$ac_top_build_prefix |
| 1455 | |
| 1456 | case $srcdir in |
| 1457 | .) # We are building in place. |
| 1458 | ac_srcdir=. |
| 1459 | ac_top_srcdir=$ac_top_builddir_sub |
| 1460 | ac_abs_top_srcdir=$ac_pwd ;; |
| 1461 | [\\/]* | ?:[\\/]* ) # Absolute name. |
| 1462 | ac_srcdir=$srcdir$ac_dir_suffix; |
| 1463 | ac_top_srcdir=$srcdir |
| 1464 | ac_abs_top_srcdir=$srcdir ;; |
| 1465 | *) # Relative name. |
| 1466 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix |
| 1467 | ac_top_srcdir=$ac_top_build_prefix$srcdir |
| 1468 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; |
| 1469 | esac |
| 1470 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
| 1471 | |
| 1472 | cd "$ac_dir" || { ac_status=$?; continue; } |
| 1473 | # Check for guested configure. |
| 1474 | if test -f "$ac_srcdir/configure.gnu"; then |
| 1475 | echo && |
| 1476 | $SHELL "$ac_srcdir/configure.gnu" --help=recursive |
| 1477 | elif test -f "$ac_srcdir/configure"; then |
| 1478 | echo && |
| 1479 | $SHELL "$ac_srcdir/configure" --help=recursive |
| 1480 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1481 | $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1482 | fi || ac_status=$? |
| 1483 | cd "$ac_pwd" || { ac_status=$?; break; } |
| 1484 | done |
| 1485 | fi |
| 1486 | |
| 1487 | test -n "$ac_init_help" && exit $ac_status |
| 1488 | if $ac_init_version; then |
| 1489 | cat <<\_ACEOF |
| 1490 | configure |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1491 | generated by GNU Autoconf 2.69 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1492 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1493 | Copyright (C) 2012 Free Software Foundation, Inc. |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1494 | This configure script is free software; the Free Software Foundation |
| 1495 | gives unlimited permission to copy, distribute and modify it. |
| 1496 | _ACEOF |
| 1497 | exit |
| 1498 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1499 | |
| 1500 | ## ------------------------ ## |
| 1501 | ## Autoconf initialization. ## |
| 1502 | ## ------------------------ ## |
| 1503 | |
| 1504 | # ac_fn_c_try_compile LINENO |
| 1505 | # -------------------------- |
| 1506 | # Try to compile conftest.$ac_ext, and return whether this succeeded. |
| 1507 | ac_fn_c_try_compile () |
| 1508 | { |
| 1509 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1510 | rm -f conftest.$ac_objext |
| 1511 | if { { ac_try="$ac_compile" |
| 1512 | case "(($ac_try" in |
| 1513 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1514 | *) ac_try_echo=$ac_try;; |
| 1515 | esac |
| 1516 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1517 | $as_echo "$ac_try_echo"; } >&5 |
| 1518 | (eval "$ac_compile") 2>conftest.err |
| 1519 | ac_status=$? |
| 1520 | if test -s conftest.err; then |
| 1521 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1522 | cat conftest.er1 >&5 |
| 1523 | mv -f conftest.er1 conftest.err |
| 1524 | fi |
| 1525 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1526 | test $ac_status = 0; } && { |
| 1527 | test -z "$ac_c_werror_flag" || |
| 1528 | test ! -s conftest.err |
| 1529 | } && test -s conftest.$ac_objext; then : |
| 1530 | ac_retval=0 |
| 1531 | else |
| 1532 | $as_echo "$as_me: failed program was:" >&5 |
| 1533 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1534 | |
| 1535 | ac_retval=1 |
| 1536 | fi |
| 1537 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
| 1538 | as_fn_set_status $ac_retval |
| 1539 | |
| 1540 | } # ac_fn_c_try_compile |
| 1541 | |
| 1542 | # ac_fn_c_try_cpp LINENO |
| 1543 | # ---------------------- |
| 1544 | # Try to preprocess conftest.$ac_ext, and return whether this succeeded. |
| 1545 | ac_fn_c_try_cpp () |
| 1546 | { |
| 1547 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1548 | if { { ac_try="$ac_cpp conftest.$ac_ext" |
| 1549 | case "(($ac_try" in |
| 1550 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1551 | *) ac_try_echo=$ac_try;; |
| 1552 | esac |
| 1553 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1554 | $as_echo "$ac_try_echo"; } >&5 |
| 1555 | (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err |
| 1556 | ac_status=$? |
| 1557 | if test -s conftest.err; then |
| 1558 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1559 | cat conftest.er1 >&5 |
| 1560 | mv -f conftest.er1 conftest.err |
| 1561 | fi |
| 1562 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1563 | test $ac_status = 0; } > conftest.i && { |
| 1564 | test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || |
| 1565 | test ! -s conftest.err |
| 1566 | }; then : |
| 1567 | ac_retval=0 |
| 1568 | else |
| 1569 | $as_echo "$as_me: failed program was:" >&5 |
| 1570 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1571 | |
| 1572 | ac_retval=1 |
| 1573 | fi |
| 1574 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
| 1575 | as_fn_set_status $ac_retval |
| 1576 | |
| 1577 | } # ac_fn_c_try_cpp |
| 1578 | |
| 1579 | # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES |
| 1580 | # ------------------------------------------------------- |
| 1581 | # Tests whether HEADER exists, giving a warning if it cannot be compiled using |
| 1582 | # the include files in INCLUDES and setting the cache variable VAR |
| 1583 | # accordingly. |
| 1584 | ac_fn_c_check_header_mongrel () |
| 1585 | { |
| 1586 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1587 | if eval \${$3+:} false; then : |
| 1588 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1589 | $as_echo_n "checking for $2... " >&6; } |
| 1590 | if eval \${$3+:} false; then : |
| 1591 | $as_echo_n "(cached) " >&6 |
| 1592 | fi |
| 1593 | eval ac_res=\$$3 |
| 1594 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1595 | $as_echo "$ac_res" >&6; } |
| 1596 | else |
| 1597 | # Is the header compilable? |
| 1598 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 |
| 1599 | $as_echo_n "checking $2 usability... " >&6; } |
| 1600 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1601 | /* end confdefs.h. */ |
| 1602 | $4 |
| 1603 | #include <$2> |
| 1604 | _ACEOF |
| 1605 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1606 | ac_header_compiler=yes |
| 1607 | else |
| 1608 | ac_header_compiler=no |
| 1609 | fi |
| 1610 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1611 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 |
| 1612 | $as_echo "$ac_header_compiler" >&6; } |
| 1613 | |
| 1614 | # Is the header present? |
| 1615 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 |
| 1616 | $as_echo_n "checking $2 presence... " >&6; } |
| 1617 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1618 | /* end confdefs.h. */ |
| 1619 | #include <$2> |
| 1620 | _ACEOF |
| 1621 | if ac_fn_c_try_cpp "$LINENO"; then : |
| 1622 | ac_header_preproc=yes |
| 1623 | else |
| 1624 | ac_header_preproc=no |
| 1625 | fi |
| 1626 | rm -f conftest.err conftest.i conftest.$ac_ext |
| 1627 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 |
| 1628 | $as_echo "$ac_header_preproc" >&6; } |
| 1629 | |
| 1630 | # So? What about this header? |
| 1631 | case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( |
| 1632 | yes:no: ) |
| 1633 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 |
| 1634 | $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} |
| 1635 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 |
| 1636 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} |
| 1637 | ;; |
| 1638 | no:yes:* ) |
| 1639 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 |
| 1640 | $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} |
| 1641 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 |
| 1642 | $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} |
| 1643 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 |
| 1644 | $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} |
| 1645 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 |
| 1646 | $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} |
| 1647 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 |
| 1648 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} |
| 1649 | ;; |
| 1650 | esac |
| 1651 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1652 | $as_echo_n "checking for $2... " >&6; } |
| 1653 | if eval \${$3+:} false; then : |
| 1654 | $as_echo_n "(cached) " >&6 |
| 1655 | else |
| 1656 | eval "$3=\$ac_header_compiler" |
| 1657 | fi |
| 1658 | eval ac_res=\$$3 |
| 1659 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1660 | $as_echo "$ac_res" >&6; } |
| 1661 | fi |
| 1662 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
| 1663 | |
| 1664 | } # ac_fn_c_check_header_mongrel |
| 1665 | |
| 1666 | # ac_fn_c_try_run LINENO |
| 1667 | # ---------------------- |
| 1668 | # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes |
| 1669 | # that executables *can* be run. |
| 1670 | ac_fn_c_try_run () |
| 1671 | { |
| 1672 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1673 | if { { ac_try="$ac_link" |
| 1674 | case "(($ac_try" in |
| 1675 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1676 | *) ac_try_echo=$ac_try;; |
| 1677 | esac |
| 1678 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1679 | $as_echo "$ac_try_echo"; } >&5 |
| 1680 | (eval "$ac_link") 2>&5 |
| 1681 | ac_status=$? |
| 1682 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1683 | test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' |
| 1684 | { { case "(($ac_try" in |
| 1685 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1686 | *) ac_try_echo=$ac_try;; |
| 1687 | esac |
| 1688 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1689 | $as_echo "$ac_try_echo"; } >&5 |
| 1690 | (eval "$ac_try") 2>&5 |
| 1691 | ac_status=$? |
| 1692 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1693 | test $ac_status = 0; }; }; then : |
| 1694 | ac_retval=0 |
| 1695 | else |
| 1696 | $as_echo "$as_me: program exited with status $ac_status" >&5 |
| 1697 | $as_echo "$as_me: failed program was:" >&5 |
| 1698 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1699 | |
| 1700 | ac_retval=$ac_status |
| 1701 | fi |
| 1702 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo |
| 1703 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
| 1704 | as_fn_set_status $ac_retval |
| 1705 | |
| 1706 | } # ac_fn_c_try_run |
| 1707 | |
| 1708 | # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES |
| 1709 | # ------------------------------------------------------- |
| 1710 | # Tests whether HEADER exists and can be compiled using the include files in |
| 1711 | # INCLUDES, setting the cache variable VAR accordingly. |
| 1712 | ac_fn_c_check_header_compile () |
| 1713 | { |
| 1714 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1715 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1716 | $as_echo_n "checking for $2... " >&6; } |
| 1717 | if eval \${$3+:} false; then : |
| 1718 | $as_echo_n "(cached) " >&6 |
| 1719 | else |
| 1720 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1721 | /* end confdefs.h. */ |
| 1722 | $4 |
| 1723 | #include <$2> |
| 1724 | _ACEOF |
| 1725 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1726 | eval "$3=yes" |
| 1727 | else |
| 1728 | eval "$3=no" |
| 1729 | fi |
| 1730 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1731 | fi |
| 1732 | eval ac_res=\$$3 |
| 1733 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1734 | $as_echo "$ac_res" >&6; } |
| 1735 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
| 1736 | |
| 1737 | } # ac_fn_c_check_header_compile |
| 1738 | |
| 1739 | # ac_fn_c_check_type LINENO TYPE VAR INCLUDES |
| 1740 | # ------------------------------------------- |
| 1741 | # Tests whether TYPE exists after having included INCLUDES, setting cache |
| 1742 | # variable VAR accordingly. |
| 1743 | ac_fn_c_check_type () |
| 1744 | { |
| 1745 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1746 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1747 | $as_echo_n "checking for $2... " >&6; } |
| 1748 | if eval \${$3+:} false; then : |
| 1749 | $as_echo_n "(cached) " >&6 |
| 1750 | else |
| 1751 | eval "$3=no" |
| 1752 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1753 | /* end confdefs.h. */ |
| 1754 | $4 |
| 1755 | int |
| 1756 | main () |
| 1757 | { |
| 1758 | if (sizeof ($2)) |
| 1759 | return 0; |
| 1760 | ; |
| 1761 | return 0; |
| 1762 | } |
| 1763 | _ACEOF |
| 1764 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1765 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1766 | /* end confdefs.h. */ |
| 1767 | $4 |
| 1768 | int |
| 1769 | main () |
| 1770 | { |
| 1771 | if (sizeof (($2))) |
| 1772 | return 0; |
| 1773 | ; |
| 1774 | return 0; |
| 1775 | } |
| 1776 | _ACEOF |
| 1777 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1778 | |
| 1779 | else |
| 1780 | eval "$3=yes" |
| 1781 | fi |
| 1782 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1783 | fi |
| 1784 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1785 | fi |
| 1786 | eval ac_res=\$$3 |
| 1787 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1788 | $as_echo "$ac_res" >&6; } |
| 1789 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
| 1790 | |
| 1791 | } # ac_fn_c_check_type |
| 1792 | |
| 1793 | # ac_fn_c_try_link LINENO |
| 1794 | # ----------------------- |
| 1795 | # Try to link conftest.$ac_ext, and return whether this succeeded. |
| 1796 | ac_fn_c_try_link () |
| 1797 | { |
| 1798 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1799 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 1800 | if { { ac_try="$ac_link" |
| 1801 | case "(($ac_try" in |
| 1802 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1803 | *) ac_try_echo=$ac_try;; |
| 1804 | esac |
| 1805 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1806 | $as_echo "$ac_try_echo"; } >&5 |
| 1807 | (eval "$ac_link") 2>conftest.err |
| 1808 | ac_status=$? |
| 1809 | if test -s conftest.err; then |
| 1810 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1811 | cat conftest.er1 >&5 |
| 1812 | mv -f conftest.er1 conftest.err |
| 1813 | fi |
| 1814 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1815 | test $ac_status = 0; } && { |
| 1816 | test -z "$ac_c_werror_flag" || |
| 1817 | test ! -s conftest.err |
| 1818 | } && test -s conftest$ac_exeext && { |
| 1819 | test "$cross_compiling" = yes || |
| 1820 | test -x conftest$ac_exeext |
| 1821 | }; then : |
| 1822 | ac_retval=0 |
| 1823 | else |
| 1824 | $as_echo "$as_me: failed program was:" >&5 |
| 1825 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1826 | |
| 1827 | ac_retval=1 |
| 1828 | fi |
| 1829 | # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information |
| 1830 | # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would |
| 1831 | # interfere with the next link command; also delete a directory that is |
| 1832 | # left behind by Apple's compiler. We do this before executing the actions. |
| 1833 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo |
| 1834 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
| 1835 | as_fn_set_status $ac_retval |
| 1836 | |
| 1837 | } # ac_fn_c_try_link |
| 1838 | |
| 1839 | # ac_fn_c_check_func LINENO FUNC VAR |
| 1840 | # ---------------------------------- |
| 1841 | # Tests whether FUNC exists, setting the cache variable VAR accordingly |
| 1842 | ac_fn_c_check_func () |
| 1843 | { |
| 1844 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1845 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1846 | $as_echo_n "checking for $2... " >&6; } |
| 1847 | if eval \${$3+:} false; then : |
| 1848 | $as_echo_n "(cached) " >&6 |
| 1849 | else |
| 1850 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1851 | /* end confdefs.h. */ |
| 1852 | /* Define $2 to an innocuous variant, in case <limits.h> declares $2. |
| 1853 | For example, HP-UX 11i <limits.h> declares gettimeofday. */ |
| 1854 | #define $2 innocuous_$2 |
| 1855 | |
| 1856 | /* System header to define __stub macros and hopefully few prototypes, |
| 1857 | which can conflict with char $2 (); below. |
| 1858 | Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 1859 | <limits.h> exists even on freestanding compilers. */ |
| 1860 | |
| 1861 | #ifdef __STDC__ |
| 1862 | # include <limits.h> |
| 1863 | #else |
| 1864 | # include <assert.h> |
| 1865 | #endif |
| 1866 | |
| 1867 | #undef $2 |
| 1868 | |
| 1869 | /* Override any GCC internal prototype to avoid an error. |
| 1870 | Use char because int might match the return type of a GCC |
| 1871 | builtin and then its argument prototype would still apply. */ |
| 1872 | #ifdef __cplusplus |
| 1873 | extern "C" |
| 1874 | #endif |
| 1875 | char $2 (); |
| 1876 | /* The GNU C library defines this for functions which it implements |
| 1877 | to always fail with ENOSYS. Some functions are actually named |
| 1878 | something starting with __ and the normal name is an alias. */ |
| 1879 | #if defined __stub_$2 || defined __stub___$2 |
| 1880 | choke me |
| 1881 | #endif |
| 1882 | |
| 1883 | int |
| 1884 | main () |
| 1885 | { |
| 1886 | return $2 (); |
| 1887 | ; |
| 1888 | return 0; |
| 1889 | } |
| 1890 | _ACEOF |
| 1891 | if ac_fn_c_try_link "$LINENO"; then : |
| 1892 | eval "$3=yes" |
| 1893 | else |
| 1894 | eval "$3=no" |
| 1895 | fi |
| 1896 | rm -f core conftest.err conftest.$ac_objext \ |
| 1897 | conftest$ac_exeext conftest.$ac_ext |
| 1898 | fi |
| 1899 | eval ac_res=\$$3 |
| 1900 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1901 | $as_echo "$ac_res" >&6; } |
| 1902 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
| 1903 | |
| 1904 | } # ac_fn_c_check_func |
| 1905 | |
| 1906 | # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES |
| 1907 | # --------------------------------------------- |
| 1908 | # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR |
| 1909 | # accordingly. |
| 1910 | ac_fn_c_check_decl () |
| 1911 | { |
| 1912 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1913 | as_decl_name=`echo $2|sed 's/ *(.*//'` |
| 1914 | as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'` |
| 1915 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5 |
| 1916 | $as_echo_n "checking whether $as_decl_name is declared... " >&6; } |
| 1917 | if eval \${$3+:} false; then : |
| 1918 | $as_echo_n "(cached) " >&6 |
| 1919 | else |
| 1920 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1921 | /* end confdefs.h. */ |
| 1922 | $4 |
| 1923 | int |
| 1924 | main () |
| 1925 | { |
| 1926 | #ifndef $as_decl_name |
| 1927 | #ifdef __cplusplus |
| 1928 | (void) $as_decl_use; |
| 1929 | #else |
| 1930 | (void) $as_decl_name; |
| 1931 | #endif |
| 1932 | #endif |
| 1933 | |
| 1934 | ; |
| 1935 | return 0; |
| 1936 | } |
| 1937 | _ACEOF |
| 1938 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1939 | eval "$3=yes" |
| 1940 | else |
| 1941 | eval "$3=no" |
| 1942 | fi |
| 1943 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1944 | fi |
| 1945 | eval ac_res=\$$3 |
| 1946 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1947 | $as_echo "$ac_res" >&6; } |
| 1948 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
| 1949 | |
| 1950 | } # ac_fn_c_check_decl |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1951 | cat >config.log <<_ACEOF |
| 1952 | This file contains any messages produced by compilers while |
| 1953 | running configure, to aid debugging if configure makes a mistake. |
| 1954 | |
| 1955 | It was created by $as_me, which was |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1956 | generated by GNU Autoconf 2.69. Invocation command line was |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1957 | |
| 1958 | $ $0 $@ |
| 1959 | |
| 1960 | _ACEOF |
| 1961 | exec 5>>config.log |
| 1962 | { |
| 1963 | cat <<_ASUNAME |
| 1964 | ## --------- ## |
| 1965 | ## Platform. ## |
| 1966 | ## --------- ## |
| 1967 | |
| 1968 | hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` |
| 1969 | uname -m = `(uname -m) 2>/dev/null || echo unknown` |
| 1970 | uname -r = `(uname -r) 2>/dev/null || echo unknown` |
| 1971 | uname -s = `(uname -s) 2>/dev/null || echo unknown` |
| 1972 | uname -v = `(uname -v) 2>/dev/null || echo unknown` |
| 1973 | |
| 1974 | /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` |
| 1975 | /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` |
| 1976 | |
| 1977 | /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` |
| 1978 | /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` |
| 1979 | /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` |
| 1980 | /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` |
| 1981 | /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` |
| 1982 | /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` |
| 1983 | /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` |
| 1984 | |
| 1985 | _ASUNAME |
| 1986 | |
| 1987 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 1988 | for as_dir in $PATH |
| 1989 | do |
| 1990 | IFS=$as_save_IFS |
| 1991 | test -z "$as_dir" && as_dir=. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 1992 | $as_echo "PATH: $as_dir" |
| 1993 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 1994 | IFS=$as_save_IFS |
| 1995 | |
| 1996 | } >&5 |
| 1997 | |
| 1998 | cat >&5 <<_ACEOF |
| 1999 | |
| 2000 | |
| 2001 | ## ----------- ## |
| 2002 | ## Core tests. ## |
| 2003 | ## ----------- ## |
| 2004 | |
| 2005 | _ACEOF |
| 2006 | |
| 2007 | |
| 2008 | # Keep a trace of the command line. |
| 2009 | # Strip out --no-create and --no-recursion so they do not pile up. |
| 2010 | # Strip out --silent because we don't want to record it for future runs. |
| 2011 | # Also quote any args containing shell meta-characters. |
| 2012 | # Make two passes to allow for proper duplicate-argument suppression. |
| 2013 | ac_configure_args= |
| 2014 | ac_configure_args0= |
| 2015 | ac_configure_args1= |
| 2016 | ac_must_keep_next=false |
| 2017 | for ac_pass in 1 2 |
| 2018 | do |
| 2019 | for ac_arg |
| 2020 | do |
| 2021 | case $ac_arg in |
| 2022 | -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; |
| 2023 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 2024 | | -silent | --silent | --silen | --sile | --sil) |
| 2025 | continue ;; |
| 2026 | *\'*) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2027 | ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2028 | esac |
| 2029 | case $ac_pass in |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2030 | 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2031 | 2) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2032 | as_fn_append ac_configure_args1 " '$ac_arg'" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2033 | if test $ac_must_keep_next = true; then |
| 2034 | ac_must_keep_next=false # Got value, back to normal. |
| 2035 | else |
| 2036 | case $ac_arg in |
| 2037 | *=* | --config-cache | -C | -disable-* | --disable-* \ |
| 2038 | | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ |
| 2039 | | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ |
| 2040 | | -with-* | --with-* | -without-* | --without-* | --x) |
| 2041 | case "$ac_configure_args0 " in |
| 2042 | "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; |
| 2043 | esac |
| 2044 | ;; |
| 2045 | -* ) ac_must_keep_next=true ;; |
| 2046 | esac |
| 2047 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2048 | as_fn_append ac_configure_args " '$ac_arg'" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2049 | ;; |
| 2050 | esac |
| 2051 | done |
| 2052 | done |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2053 | { ac_configure_args0=; unset ac_configure_args0;} |
| 2054 | { ac_configure_args1=; unset ac_configure_args1;} |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2055 | |
| 2056 | # When interrupted or exit'd, cleanup temporary files, and complete |
| 2057 | # config.log. We remove comments because anyway the quotes in there |
| 2058 | # would cause problems or look ugly. |
| 2059 | # WARNING: Use '\'' to represent an apostrophe within the trap. |
| 2060 | # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. |
| 2061 | trap 'exit_status=$? |
| 2062 | # Save into config.log some information that might help in debugging. |
| 2063 | { |
| 2064 | echo |
| 2065 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2066 | $as_echo "## ---------------- ## |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2067 | ## Cache variables. ## |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2068 | ## ---------------- ##" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2069 | echo |
| 2070 | # The following way of writing the cache mishandles newlines in values, |
| 2071 | ( |
| 2072 | for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do |
| 2073 | eval ac_val=\$$ac_var |
| 2074 | case $ac_val in #( |
| 2075 | *${as_nl}*) |
| 2076 | case $ac_var in #( |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2077 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 |
| 2078 | $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2079 | esac |
| 2080 | case $ac_var in #( |
| 2081 | _ | IFS | as_nl) ;; #( |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2082 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( |
| 2083 | *) { eval $ac_var=; unset $ac_var;} ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2084 | esac ;; |
| 2085 | esac |
| 2086 | done |
| 2087 | (set) 2>&1 | |
| 2088 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( |
| 2089 | *${as_nl}ac_space=\ *) |
| 2090 | sed -n \ |
| 2091 | "s/'\''/'\''\\\\'\'''\''/g; |
| 2092 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" |
| 2093 | ;; #( |
| 2094 | *) |
| 2095 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" |
| 2096 | ;; |
| 2097 | esac | |
| 2098 | sort |
| 2099 | ) |
| 2100 | echo |
| 2101 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2102 | $as_echo "## ----------------- ## |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2103 | ## Output variables. ## |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2104 | ## ----------------- ##" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2105 | echo |
| 2106 | for ac_var in $ac_subst_vars |
| 2107 | do |
| 2108 | eval ac_val=\$$ac_var |
| 2109 | case $ac_val in |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2110 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2111 | esac |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2112 | $as_echo "$ac_var='\''$ac_val'\''" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2113 | done | sort |
| 2114 | echo |
| 2115 | |
| 2116 | if test -n "$ac_subst_files"; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2117 | $as_echo "## ------------------- ## |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2118 | ## File substitutions. ## |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2119 | ## ------------------- ##" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2120 | echo |
| 2121 | for ac_var in $ac_subst_files |
| 2122 | do |
| 2123 | eval ac_val=\$$ac_var |
| 2124 | case $ac_val in |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2125 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2126 | esac |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2127 | $as_echo "$ac_var='\''$ac_val'\''" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2128 | done | sort |
| 2129 | echo |
| 2130 | fi |
| 2131 | |
| 2132 | if test -s confdefs.h; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2133 | $as_echo "## ----------- ## |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2134 | ## confdefs.h. ## |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2135 | ## ----------- ##" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2136 | echo |
| 2137 | cat confdefs.h |
| 2138 | echo |
| 2139 | fi |
| 2140 | test "$ac_signal" != 0 && |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2141 | $as_echo "$as_me: caught signal $ac_signal" |
| 2142 | $as_echo "$as_me: exit $exit_status" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2143 | } >&5 |
| 2144 | rm -f core *.core core.conftest.* && |
| 2145 | rm -f -r conftest* confdefs* conf$$* $ac_clean_files && |
| 2146 | exit $exit_status |
| 2147 | ' 0 |
| 2148 | for ac_signal in 1 2 13 15; do |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2149 | trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2150 | done |
| 2151 | ac_signal=0 |
| 2152 | |
| 2153 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
| 2154 | rm -f -r conftest* confdefs.h |
| 2155 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2156 | $as_echo "/* confdefs.h */" > confdefs.h |
| 2157 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2158 | # Predefined preprocessor variables. |
| 2159 | |
| 2160 | cat >>confdefs.h <<_ACEOF |
| 2161 | #define PACKAGE_NAME "$PACKAGE_NAME" |
| 2162 | _ACEOF |
| 2163 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2164 | cat >>confdefs.h <<_ACEOF |
| 2165 | #define PACKAGE_TARNAME "$PACKAGE_TARNAME" |
| 2166 | _ACEOF |
| 2167 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2168 | cat >>confdefs.h <<_ACEOF |
| 2169 | #define PACKAGE_VERSION "$PACKAGE_VERSION" |
| 2170 | _ACEOF |
| 2171 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2172 | cat >>confdefs.h <<_ACEOF |
| 2173 | #define PACKAGE_STRING "$PACKAGE_STRING" |
| 2174 | _ACEOF |
| 2175 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2176 | cat >>confdefs.h <<_ACEOF |
| 2177 | #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" |
| 2178 | _ACEOF |
| 2179 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2180 | cat >>confdefs.h <<_ACEOF |
| 2181 | #define PACKAGE_URL "$PACKAGE_URL" |
| 2182 | _ACEOF |
| 2183 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2184 | |
| 2185 | # Let the site file select an alternate cache file if it wants to. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2186 | # Prefer an explicitly selected file to automatically selected ones. |
| 2187 | ac_site_file1=NONE |
| 2188 | ac_site_file2=NONE |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2189 | if test -n "$CONFIG_SITE"; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2190 | # We do not want a PATH search for config.site. |
| 2191 | case $CONFIG_SITE in #(( |
| 2192 | -*) ac_site_file1=./$CONFIG_SITE;; |
| 2193 | */*) ac_site_file1=$CONFIG_SITE;; |
| 2194 | *) ac_site_file1=./$CONFIG_SITE;; |
| 2195 | esac |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2196 | elif test "x$prefix" != xNONE; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2197 | ac_site_file1=$prefix/share/config.site |
| 2198 | ac_site_file2=$prefix/etc/config.site |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2199 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2200 | ac_site_file1=$ac_default_prefix/share/config.site |
| 2201 | ac_site_file2=$ac_default_prefix/etc/config.site |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2202 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2203 | for ac_site_file in "$ac_site_file1" "$ac_site_file2" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2204 | do |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2205 | test "x$ac_site_file" = xNONE && continue |
| 2206 | if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then |
| 2207 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 |
| 2208 | $as_echo "$as_me: loading site script $ac_site_file" >&6;} |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2209 | sed 's/^/| /' "$ac_site_file" >&5 |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2210 | . "$ac_site_file" \ |
| 2211 | || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 2212 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 2213 | as_fn_error $? "failed to load site script $ac_site_file |
| 2214 | See \`config.log' for more details" "$LINENO" 5; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2215 | fi |
| 2216 | done |
| 2217 | |
| 2218 | if test -r "$cache_file"; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2219 | # Some versions of bash will fail to source /dev/null (special files |
| 2220 | # actually), so we avoid doing that. DJGPP emulates it as a regular file. |
| 2221 | if test /dev/null != "$cache_file" && test -f "$cache_file"; then |
| 2222 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 |
| 2223 | $as_echo "$as_me: loading cache $cache_file" >&6;} |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2224 | case $cache_file in |
| 2225 | [\\/]* | ?:[\\/]* ) . "$cache_file";; |
| 2226 | *) . "./$cache_file";; |
| 2227 | esac |
| 2228 | fi |
| 2229 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2230 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 |
| 2231 | $as_echo "$as_me: creating cache $cache_file" >&6;} |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2232 | >$cache_file |
| 2233 | fi |
| 2234 | |
| 2235 | # Check that the precious variables saved in the cache have kept the same |
| 2236 | # value. |
| 2237 | ac_cache_corrupted=false |
| 2238 | for ac_var in $ac_precious_vars; do |
| 2239 | eval ac_old_set=\$ac_cv_env_${ac_var}_set |
| 2240 | eval ac_new_set=\$ac_env_${ac_var}_set |
| 2241 | eval ac_old_val=\$ac_cv_env_${ac_var}_value |
| 2242 | eval ac_new_val=\$ac_env_${ac_var}_value |
| 2243 | case $ac_old_set,$ac_new_set in |
| 2244 | set,) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2245 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 |
| 2246 | $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2247 | ac_cache_corrupted=: ;; |
| 2248 | ,set) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2249 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 |
| 2250 | $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2251 | ac_cache_corrupted=: ;; |
| 2252 | ,);; |
| 2253 | *) |
| 2254 | if test "x$ac_old_val" != "x$ac_new_val"; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2255 | # differences in whitespace do not lead to failure. |
| 2256 | ac_old_val_w=`echo x $ac_old_val` |
| 2257 | ac_new_val_w=`echo x $ac_new_val` |
| 2258 | if test "$ac_old_val_w" != "$ac_new_val_w"; then |
| 2259 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 |
| 2260 | $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} |
| 2261 | ac_cache_corrupted=: |
| 2262 | else |
| 2263 | { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 |
| 2264 | $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} |
| 2265 | eval $ac_var=\$ac_old_val |
| 2266 | fi |
| 2267 | { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 |
| 2268 | $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} |
| 2269 | { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 |
| 2270 | $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2271 | fi;; |
| 2272 | esac |
| 2273 | # Pass precious variables to config.status. |
| 2274 | if test "$ac_new_set" = set; then |
| 2275 | case $ac_new_val in |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2276 | *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2277 | *) ac_arg=$ac_var=$ac_new_val ;; |
| 2278 | esac |
| 2279 | case " $ac_configure_args " in |
| 2280 | *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2281 | *) as_fn_append ac_configure_args " '$ac_arg'" ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2282 | esac |
| 2283 | fi |
| 2284 | done |
| 2285 | if $ac_cache_corrupted; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2286 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 2287 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 2288 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 |
| 2289 | $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} |
| 2290 | as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2291 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2292 | ## -------------------- ## |
| 2293 | ## Main body of script. ## |
| 2294 | ## -------------------- ## |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2295 | |
| 2296 | ac_ext=c |
| 2297 | ac_cpp='$CPP $CPPFLAGS' |
| 2298 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 2299 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 2300 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 2301 | |
| 2302 | |
| 2303 | |
| 2304 | ac_aux_dir= |
| 2305 | for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do |
| 2306 | if test -f "$ac_dir/install-sh"; then |
| 2307 | ac_aux_dir=$ac_dir |
| 2308 | ac_install_sh="$ac_aux_dir/install-sh -c" |
| 2309 | break |
| 2310 | elif test -f "$ac_dir/install.sh"; then |
| 2311 | ac_aux_dir=$ac_dir |
| 2312 | ac_install_sh="$ac_aux_dir/install.sh -c" |
| 2313 | break |
| 2314 | elif test -f "$ac_dir/shtool"; then |
| 2315 | ac_aux_dir=$ac_dir |
| 2316 | ac_install_sh="$ac_aux_dir/shtool install -c" |
| 2317 | break |
| 2318 | fi |
| 2319 | done |
| 2320 | if test -z "$ac_aux_dir"; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2321 | as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2322 | fi |
| 2323 | |
| 2324 | # These three variables are undocumented and unsupported, |
| 2325 | # and are intended to be withdrawn in a future Autoconf release. |
| 2326 | # They can cause serious problems if a builder's source tree is in a directory |
| 2327 | # whose full name contains unusual characters. |
| 2328 | ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. |
| 2329 | ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. |
| 2330 | ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. |
| 2331 | |
| 2332 | |
| 2333 | # Make sure we can run config.sub. |
| 2334 | $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2335 | as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2336 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2337 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 |
| 2338 | $as_echo_n "checking build system type... " >&6; } |
| 2339 | if ${ac_cv_build+:} false; then : |
| 2340 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2341 | else |
| 2342 | ac_build_alias=$build_alias |
| 2343 | test "x$ac_build_alias" = x && |
| 2344 | ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` |
| 2345 | test "x$ac_build_alias" = x && |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2346 | as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2347 | ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2348 | as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2349 | |
| 2350 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2351 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 |
| 2352 | $as_echo "$ac_cv_build" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2353 | case $ac_cv_build in |
| 2354 | *-*-*) ;; |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2355 | *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2356 | esac |
| 2357 | build=$ac_cv_build |
| 2358 | ac_save_IFS=$IFS; IFS='-' |
| 2359 | set x $ac_cv_build |
| 2360 | shift |
| 2361 | build_cpu=$1 |
| 2362 | build_vendor=$2 |
| 2363 | shift; shift |
| 2364 | # Remember, the first character of IFS is used to create $*, |
| 2365 | # except with old shells: |
| 2366 | build_os=$* |
| 2367 | IFS=$ac_save_IFS |
| 2368 | case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac |
| 2369 | |
| 2370 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2371 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 |
| 2372 | $as_echo_n "checking host system type... " >&6; } |
| 2373 | if ${ac_cv_host+:} false; then : |
| 2374 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2375 | else |
| 2376 | if test "x$host_alias" = x; then |
| 2377 | ac_cv_host=$ac_cv_build |
| 2378 | else |
| 2379 | ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2380 | as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2381 | fi |
| 2382 | |
| 2383 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2384 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 |
| 2385 | $as_echo "$ac_cv_host" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2386 | case $ac_cv_host in |
| 2387 | *-*-*) ;; |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2388 | *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2389 | esac |
| 2390 | host=$ac_cv_host |
| 2391 | ac_save_IFS=$IFS; IFS='-' |
| 2392 | set x $ac_cv_host |
| 2393 | shift |
| 2394 | host_cpu=$1 |
| 2395 | host_vendor=$2 |
| 2396 | shift; shift |
| 2397 | # Remember, the first character of IFS is used to create $*, |
| 2398 | # except with old shells: |
| 2399 | host_os=$* |
| 2400 | IFS=$ac_save_IFS |
| 2401 | case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac |
| 2402 | |
| 2403 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2404 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5 |
| 2405 | $as_echo_n "checking target system type... " >&6; } |
| 2406 | if ${ac_cv_target+:} false; then : |
| 2407 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2408 | else |
| 2409 | if test "x$target_alias" = x; then |
| 2410 | ac_cv_target=$ac_cv_host |
| 2411 | else |
| 2412 | ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` || |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2413 | as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2414 | fi |
| 2415 | |
| 2416 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2417 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5 |
| 2418 | $as_echo "$ac_cv_target" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2419 | case $ac_cv_target in |
| 2420 | *-*-*) ;; |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2421 | *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2422 | esac |
| 2423 | target=$ac_cv_target |
| 2424 | ac_save_IFS=$IFS; IFS='-' |
| 2425 | set x $ac_cv_target |
| 2426 | shift |
| 2427 | target_cpu=$1 |
| 2428 | target_vendor=$2 |
| 2429 | shift; shift |
| 2430 | # Remember, the first character of IFS is used to create $*, |
| 2431 | # except with old shells: |
| 2432 | target_os=$* |
| 2433 | IFS=$ac_save_IFS |
| 2434 | case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac |
| 2435 | |
| 2436 | |
| 2437 | # The aliases save the names the user supplied, while $host etc. |
| 2438 | # will get canonicalized. |
| 2439 | test -n "$target_alias" && |
| 2440 | test "$program_prefix$program_suffix$program_transform_name" = \ |
| 2441 | NONENONEs,x,x, && |
| 2442 | program_prefix=${target_alias}- |
| 2443 | |
| 2444 | |
| 2445 | |
| 2446 | |
| 2447 | |
| 2448 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2449 | |
| 2450 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2451 | # Check whether --with-gcc was given. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2452 | if test "${with_gcc+set}" = set; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2453 | withval=$with_gcc; |
| 2454 | fi |
| 2455 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2456 | V_CCOPT="" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2457 | if test "${srcdir}" != "." ; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2458 | V_CCOPT="-I\$(srcdir)" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2459 | fi |
| 2460 | if test "${CFLAGS+set}" = set; then |
| 2461 | LBL_CFLAGS="$CFLAGS" |
| 2462 | fi |
| 2463 | if test -z "$CC" ; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2464 | case "$host_os" in |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2465 | |
| 2466 | bsdi*) |
| 2467 | # Extract the first word of "shlicc2", so it can be a program name with args. |
| 2468 | set dummy shlicc2; ac_word=$2 |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2469 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 2470 | $as_echo_n "checking for $ac_word... " >&6; } |
| 2471 | if ${ac_cv_prog_SHLICC2+:} false; then : |
| 2472 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2473 | else |
| 2474 | if test -n "$SHLICC2"; then |
| 2475 | ac_cv_prog_SHLICC2="$SHLICC2" # Let the user override the test. |
| 2476 | else |
| 2477 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 2478 | for as_dir in $PATH |
| 2479 | do |
| 2480 | IFS=$as_save_IFS |
| 2481 | test -z "$as_dir" && as_dir=. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2482 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 2483 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2484 | ac_cv_prog_SHLICC2="yes" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2485 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2486 | break 2 |
| 2487 | fi |
| 2488 | done |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2489 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2490 | IFS=$as_save_IFS |
| 2491 | |
| 2492 | test -z "$ac_cv_prog_SHLICC2" && ac_cv_prog_SHLICC2="no" |
| 2493 | fi |
| 2494 | fi |
| 2495 | SHLICC2=$ac_cv_prog_SHLICC2 |
| 2496 | if test -n "$SHLICC2"; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2497 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SHLICC2" >&5 |
| 2498 | $as_echo "$SHLICC2" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2499 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2500 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 2501 | $as_echo "no" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2502 | fi |
| 2503 | |
| 2504 | |
| 2505 | if test $SHLICC2 = yes ; then |
| 2506 | CC=shlicc2 |
| 2507 | export CC |
| 2508 | fi |
| 2509 | ;; |
| 2510 | esac |
| 2511 | fi |
| 2512 | if test -z "$CC" -a "$with_gcc" = no ; then |
| 2513 | CC=cc |
| 2514 | export CC |
| 2515 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2516 | |
| 2517 | ac_ext=c |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2518 | ac_cpp='$CPP $CPPFLAGS' |
| 2519 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 2520 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 2521 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 2522 | if test -n "$ac_tool_prefix"; then |
| 2523 | # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. |
| 2524 | set dummy ${ac_tool_prefix}gcc; ac_word=$2 |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2525 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 2526 | $as_echo_n "checking for $ac_word... " >&6; } |
| 2527 | if ${ac_cv_prog_CC+:} false; then : |
| 2528 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2529 | else |
| 2530 | if test -n "$CC"; then |
| 2531 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 2532 | else |
| 2533 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 2534 | for as_dir in $PATH |
| 2535 | do |
| 2536 | IFS=$as_save_IFS |
| 2537 | test -z "$as_dir" && as_dir=. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2538 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 2539 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2540 | ac_cv_prog_CC="${ac_tool_prefix}gcc" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2541 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2542 | break 2 |
| 2543 | fi |
| 2544 | done |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2545 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2546 | IFS=$as_save_IFS |
| 2547 | |
| 2548 | fi |
| 2549 | fi |
| 2550 | CC=$ac_cv_prog_CC |
| 2551 | if test -n "$CC"; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2552 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 2553 | $as_echo "$CC" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2554 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2555 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 2556 | $as_echo "no" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2557 | fi |
| 2558 | |
| 2559 | |
| 2560 | fi |
| 2561 | if test -z "$ac_cv_prog_CC"; then |
| 2562 | ac_ct_CC=$CC |
| 2563 | # Extract the first word of "gcc", so it can be a program name with args. |
| 2564 | set dummy gcc; ac_word=$2 |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2565 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 2566 | $as_echo_n "checking for $ac_word... " >&6; } |
| 2567 | if ${ac_cv_prog_ac_ct_CC+:} false; then : |
| 2568 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2569 | else |
| 2570 | if test -n "$ac_ct_CC"; then |
| 2571 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. |
| 2572 | else |
| 2573 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 2574 | for as_dir in $PATH |
| 2575 | do |
| 2576 | IFS=$as_save_IFS |
| 2577 | test -z "$as_dir" && as_dir=. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2578 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 2579 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2580 | ac_cv_prog_ac_ct_CC="gcc" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2581 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2582 | break 2 |
| 2583 | fi |
| 2584 | done |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2585 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2586 | IFS=$as_save_IFS |
| 2587 | |
| 2588 | fi |
| 2589 | fi |
| 2590 | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
| 2591 | if test -n "$ac_ct_CC"; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2592 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
| 2593 | $as_echo "$ac_ct_CC" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2594 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2595 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 2596 | $as_echo "no" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2597 | fi |
| 2598 | |
| 2599 | if test "x$ac_ct_CC" = x; then |
| 2600 | CC="" |
| 2601 | else |
| 2602 | case $cross_compiling:$ac_tool_warned in |
| 2603 | yes:) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2604 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 2605 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2606 | ac_tool_warned=yes ;; |
| 2607 | esac |
| 2608 | CC=$ac_ct_CC |
| 2609 | fi |
| 2610 | else |
| 2611 | CC="$ac_cv_prog_CC" |
| 2612 | fi |
| 2613 | |
| 2614 | if test -z "$CC"; then |
| 2615 | if test -n "$ac_tool_prefix"; then |
| 2616 | # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. |
| 2617 | set dummy ${ac_tool_prefix}cc; ac_word=$2 |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2618 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 2619 | $as_echo_n "checking for $ac_word... " >&6; } |
| 2620 | if ${ac_cv_prog_CC+:} false; then : |
| 2621 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2622 | else |
| 2623 | if test -n "$CC"; then |
| 2624 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 2625 | else |
| 2626 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 2627 | for as_dir in $PATH |
| 2628 | do |
| 2629 | IFS=$as_save_IFS |
| 2630 | test -z "$as_dir" && as_dir=. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2631 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 2632 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2633 | ac_cv_prog_CC="${ac_tool_prefix}cc" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2634 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2635 | break 2 |
| 2636 | fi |
| 2637 | done |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2638 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2639 | IFS=$as_save_IFS |
| 2640 | |
| 2641 | fi |
| 2642 | fi |
| 2643 | CC=$ac_cv_prog_CC |
| 2644 | if test -n "$CC"; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2645 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 2646 | $as_echo "$CC" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2647 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2648 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 2649 | $as_echo "no" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2650 | fi |
| 2651 | |
| 2652 | |
| 2653 | fi |
| 2654 | fi |
| 2655 | if test -z "$CC"; then |
| 2656 | # Extract the first word of "cc", so it can be a program name with args. |
| 2657 | set dummy cc; ac_word=$2 |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2658 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 2659 | $as_echo_n "checking for $ac_word... " >&6; } |
| 2660 | if ${ac_cv_prog_CC+:} false; then : |
| 2661 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2662 | else |
| 2663 | if test -n "$CC"; then |
| 2664 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 2665 | else |
| 2666 | ac_prog_rejected=no |
| 2667 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 2668 | for as_dir in $PATH |
| 2669 | do |
| 2670 | IFS=$as_save_IFS |
| 2671 | test -z "$as_dir" && as_dir=. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2672 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 2673 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2674 | if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then |
| 2675 | ac_prog_rejected=yes |
| 2676 | continue |
| 2677 | fi |
| 2678 | ac_cv_prog_CC="cc" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2679 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2680 | break 2 |
| 2681 | fi |
| 2682 | done |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2683 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2684 | IFS=$as_save_IFS |
| 2685 | |
| 2686 | if test $ac_prog_rejected = yes; then |
| 2687 | # We found a bogon in the path, so make sure we never use it. |
| 2688 | set dummy $ac_cv_prog_CC |
| 2689 | shift |
| 2690 | if test $# != 0; then |
| 2691 | # We chose a different compiler from the bogus one. |
| 2692 | # However, it has the same basename, so the bogon will be chosen |
| 2693 | # first if we set CC to just the basename; use the full file name. |
| 2694 | shift |
| 2695 | ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" |
| 2696 | fi |
| 2697 | fi |
| 2698 | fi |
| 2699 | fi |
| 2700 | CC=$ac_cv_prog_CC |
| 2701 | if test -n "$CC"; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2702 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 2703 | $as_echo "$CC" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2704 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2705 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 2706 | $as_echo "no" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2707 | fi |
| 2708 | |
| 2709 | |
| 2710 | fi |
| 2711 | if test -z "$CC"; then |
| 2712 | if test -n "$ac_tool_prefix"; then |
| 2713 | for ac_prog in cl.exe |
| 2714 | do |
| 2715 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. |
| 2716 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2717 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 2718 | $as_echo_n "checking for $ac_word... " >&6; } |
| 2719 | if ${ac_cv_prog_CC+:} false; then : |
| 2720 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2721 | else |
| 2722 | if test -n "$CC"; then |
| 2723 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 2724 | else |
| 2725 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 2726 | for as_dir in $PATH |
| 2727 | do |
| 2728 | IFS=$as_save_IFS |
| 2729 | test -z "$as_dir" && as_dir=. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2730 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 2731 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2732 | ac_cv_prog_CC="$ac_tool_prefix$ac_prog" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2733 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2734 | break 2 |
| 2735 | fi |
| 2736 | done |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2737 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2738 | IFS=$as_save_IFS |
| 2739 | |
| 2740 | fi |
| 2741 | fi |
| 2742 | CC=$ac_cv_prog_CC |
| 2743 | if test -n "$CC"; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2744 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 2745 | $as_echo "$CC" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2746 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2747 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 2748 | $as_echo "no" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2749 | fi |
| 2750 | |
| 2751 | |
| 2752 | test -n "$CC" && break |
| 2753 | done |
| 2754 | fi |
| 2755 | if test -z "$CC"; then |
| 2756 | ac_ct_CC=$CC |
| 2757 | for ac_prog in cl.exe |
| 2758 | do |
| 2759 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 2760 | set dummy $ac_prog; ac_word=$2 |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2761 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 2762 | $as_echo_n "checking for $ac_word... " >&6; } |
| 2763 | if ${ac_cv_prog_ac_ct_CC+:} false; then : |
| 2764 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2765 | else |
| 2766 | if test -n "$ac_ct_CC"; then |
| 2767 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. |
| 2768 | else |
| 2769 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 2770 | for as_dir in $PATH |
| 2771 | do |
| 2772 | IFS=$as_save_IFS |
| 2773 | test -z "$as_dir" && as_dir=. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2774 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 2775 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2776 | ac_cv_prog_ac_ct_CC="$ac_prog" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2777 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2778 | break 2 |
| 2779 | fi |
| 2780 | done |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2781 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2782 | IFS=$as_save_IFS |
| 2783 | |
| 2784 | fi |
| 2785 | fi |
| 2786 | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
| 2787 | if test -n "$ac_ct_CC"; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2788 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
| 2789 | $as_echo "$ac_ct_CC" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2790 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2791 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 2792 | $as_echo "no" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2793 | fi |
| 2794 | |
| 2795 | |
| 2796 | test -n "$ac_ct_CC" && break |
| 2797 | done |
| 2798 | |
| 2799 | if test "x$ac_ct_CC" = x; then |
| 2800 | CC="" |
| 2801 | else |
| 2802 | case $cross_compiling:$ac_tool_warned in |
| 2803 | yes:) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2804 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 2805 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2806 | ac_tool_warned=yes ;; |
| 2807 | esac |
| 2808 | CC=$ac_ct_CC |
| 2809 | fi |
| 2810 | fi |
| 2811 | |
| 2812 | fi |
| 2813 | |
| 2814 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2815 | test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 2816 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 2817 | as_fn_error $? "no acceptable C compiler found in \$PATH |
| 2818 | See \`config.log' for more details" "$LINENO" 5; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2819 | |
| 2820 | # Provide some information about the compiler. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2821 | $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 |
| 2822 | set X $ac_compile |
| 2823 | ac_compiler=$2 |
| 2824 | for ac_option in --version -v -V -qversion; do |
| 2825 | { { ac_try="$ac_compiler $ac_option >&5" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2826 | case "(($ac_try" in |
| 2827 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 2828 | *) ac_try_echo=$ac_try;; |
| 2829 | esac |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2830 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 2831 | $as_echo "$ac_try_echo"; } >&5 |
| 2832 | (eval "$ac_compiler $ac_option >&5") 2>conftest.err |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2833 | ac_status=$? |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2834 | if test -s conftest.err; then |
| 2835 | sed '10a\ |
| 2836 | ... rest of stderr output deleted ... |
| 2837 | 10q' conftest.err >conftest.er1 |
| 2838 | cat conftest.er1 >&5 |
| 2839 | fi |
| 2840 | rm -f conftest.er1 conftest.err |
| 2841 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 2842 | test $ac_status = 0; } |
| 2843 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2844 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2845 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2846 | /* end confdefs.h. */ |
| 2847 | |
| 2848 | int |
| 2849 | main () |
| 2850 | { |
| 2851 | |
| 2852 | ; |
| 2853 | return 0; |
| 2854 | } |
| 2855 | _ACEOF |
| 2856 | ac_clean_files_save=$ac_clean_files |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2857 | ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2858 | # Try to create an executable without -o first, disregard a.out. |
| 2859 | # It will help us diagnose broken compilers, and finding out an intuition |
| 2860 | # of exeext. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2861 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 |
| 2862 | $as_echo_n "checking whether the C compiler works... " >&6; } |
| 2863 | ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` |
| 2864 | |
| 2865 | # The possible output files: |
| 2866 | ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" |
| 2867 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2868 | ac_rmfiles= |
| 2869 | for ac_file in $ac_files |
| 2870 | do |
| 2871 | case $ac_file in |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2872 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2873 | * ) ac_rmfiles="$ac_rmfiles $ac_file";; |
| 2874 | esac |
| 2875 | done |
| 2876 | rm -f $ac_rmfiles |
| 2877 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2878 | if { { ac_try="$ac_link_default" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2879 | case "(($ac_try" in |
| 2880 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 2881 | *) ac_try_echo=$ac_try;; |
| 2882 | esac |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2883 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 2884 | $as_echo "$ac_try_echo"; } >&5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2885 | (eval "$ac_link_default") 2>&5 |
| 2886 | ac_status=$? |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2887 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 2888 | test $ac_status = 0; }; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2889 | # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. |
| 2890 | # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' |
| 2891 | # in a Makefile. We should not override ac_cv_exeext if it was cached, |
| 2892 | # so that the user can short-circuit this test for compilers unknown to |
| 2893 | # Autoconf. |
| 2894 | for ac_file in $ac_files '' |
| 2895 | do |
| 2896 | test -f "$ac_file" || continue |
| 2897 | case $ac_file in |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2898 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2899 | ;; |
| 2900 | [ab].out ) |
| 2901 | # We found the default executable, but exeext='' is most |
| 2902 | # certainly right. |
| 2903 | break;; |
| 2904 | *.* ) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2905 | if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2906 | then :; else |
| 2907 | ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
| 2908 | fi |
| 2909 | # We set ac_cv_exeext here because the later test for it is not |
| 2910 | # safe: cross compilers may not add the suffix if given an `-o' |
| 2911 | # argument, so we may need to know it at that point already. |
| 2912 | # Even if this section looks crufty: it has the advantage of |
| 2913 | # actually working. |
| 2914 | break;; |
| 2915 | * ) |
| 2916 | break;; |
| 2917 | esac |
| 2918 | done |
| 2919 | test "$ac_cv_exeext" = no && ac_cv_exeext= |
| 2920 | |
| 2921 | else |
| 2922 | ac_file='' |
| 2923 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2924 | if test -z "$ac_file"; then : |
| 2925 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 2926 | $as_echo "no" >&6; } |
| 2927 | $as_echo "$as_me: failed program was:" >&5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2928 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 2929 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2930 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 2931 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 2932 | as_fn_error 77 "C compiler cannot create executables |
| 2933 | See \`config.log' for more details" "$LINENO" 5; } |
| 2934 | else |
| 2935 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 2936 | $as_echo "yes" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2937 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2938 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 |
| 2939 | $as_echo_n "checking for C compiler default output file name... " >&6; } |
| 2940 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 |
| 2941 | $as_echo "$ac_file" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2942 | ac_exeext=$ac_cv_exeext |
| 2943 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2944 | rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2945 | ac_clean_files=$ac_clean_files_save |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2946 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 |
| 2947 | $as_echo_n "checking for suffix of executables... " >&6; } |
| 2948 | if { { ac_try="$ac_link" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2949 | case "(($ac_try" in |
| 2950 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 2951 | *) ac_try_echo=$ac_try;; |
| 2952 | esac |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2953 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 2954 | $as_echo "$ac_try_echo"; } >&5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2955 | (eval "$ac_link") 2>&5 |
| 2956 | ac_status=$? |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2957 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 2958 | test $ac_status = 0; }; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2959 | # If both `conftest.exe' and `conftest' are `present' (well, observable) |
| 2960 | # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will |
| 2961 | # work properly (i.e., refer to `conftest.exe'), while it won't with |
| 2962 | # `rm'. |
| 2963 | for ac_file in conftest.exe conftest conftest.*; do |
| 2964 | test -f "$ac_file" || continue |
| 2965 | case $ac_file in |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2966 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2967 | *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
| 2968 | break;; |
| 2969 | * ) break;; |
| 2970 | esac |
| 2971 | done |
| 2972 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2973 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 2974 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 2975 | as_fn_error $? "cannot compute suffix of executables: cannot compile and link |
| 2976 | See \`config.log' for more details" "$LINENO" 5; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2977 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2978 | rm -f conftest conftest$ac_cv_exeext |
| 2979 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 |
| 2980 | $as_echo "$ac_cv_exeext" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2981 | |
| 2982 | rm -f conftest.$ac_ext |
| 2983 | EXEEXT=$ac_cv_exeext |
| 2984 | ac_exeext=$EXEEXT |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2985 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2986 | /* end confdefs.h. */ |
| 2987 | #include <stdio.h> |
| 2988 | int |
| 2989 | main () |
| 2990 | { |
| 2991 | FILE *f = fopen ("conftest.out", "w"); |
| 2992 | return ferror (f) || fclose (f) != 0; |
| 2993 | |
| 2994 | ; |
| 2995 | return 0; |
| 2996 | } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 2997 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 2998 | ac_clean_files="$ac_clean_files conftest.out" |
| 2999 | # Check that the compiler produces executables we can run. If not, either |
| 3000 | # the compiler is broken, or we cross compile. |
| 3001 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 |
| 3002 | $as_echo_n "checking whether we are cross compiling... " >&6; } |
| 3003 | if test "$cross_compiling" != yes; then |
| 3004 | { { ac_try="$ac_link" |
| 3005 | case "(($ac_try" in |
| 3006 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3007 | *) ac_try_echo=$ac_try;; |
| 3008 | esac |
| 3009 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3010 | $as_echo "$ac_try_echo"; } >&5 |
| 3011 | (eval "$ac_link") 2>&5 |
| 3012 | ac_status=$? |
| 3013 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3014 | test $ac_status = 0; } |
| 3015 | if { ac_try='./conftest$ac_cv_exeext' |
| 3016 | { { case "(($ac_try" in |
| 3017 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3018 | *) ac_try_echo=$ac_try;; |
| 3019 | esac |
| 3020 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3021 | $as_echo "$ac_try_echo"; } >&5 |
| 3022 | (eval "$ac_try") 2>&5 |
| 3023 | ac_status=$? |
| 3024 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3025 | test $ac_status = 0; }; }; then |
| 3026 | cross_compiling=no |
| 3027 | else |
| 3028 | if test "$cross_compiling" = maybe; then |
| 3029 | cross_compiling=yes |
| 3030 | else |
| 3031 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3032 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 3033 | as_fn_error $? "cannot run C compiled programs. |
| 3034 | If you meant to cross compile, use \`--host'. |
| 3035 | See \`config.log' for more details" "$LINENO" 5; } |
| 3036 | fi |
| 3037 | fi |
| 3038 | fi |
| 3039 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 |
| 3040 | $as_echo "$cross_compiling" >&6; } |
| 3041 | |
| 3042 | rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out |
| 3043 | ac_clean_files=$ac_clean_files_save |
| 3044 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 |
| 3045 | $as_echo_n "checking for suffix of object files... " >&6; } |
| 3046 | if ${ac_cv_objext+:} false; then : |
| 3047 | $as_echo_n "(cached) " >&6 |
| 3048 | else |
| 3049 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3050 | /* end confdefs.h. */ |
| 3051 | |
| 3052 | int |
| 3053 | main () |
| 3054 | { |
| 3055 | |
| 3056 | ; |
| 3057 | return 0; |
| 3058 | } |
| 3059 | _ACEOF |
| 3060 | rm -f conftest.o conftest.obj |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3061 | if { { ac_try="$ac_compile" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3062 | case "(($ac_try" in |
| 3063 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3064 | *) ac_try_echo=$ac_try;; |
| 3065 | esac |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3066 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3067 | $as_echo "$ac_try_echo"; } >&5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3068 | (eval "$ac_compile") 2>&5 |
| 3069 | ac_status=$? |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3070 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3071 | test $ac_status = 0; }; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3072 | for ac_file in conftest.o conftest.obj conftest.*; do |
| 3073 | test -f "$ac_file" || continue; |
| 3074 | case $ac_file in |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3075 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3076 | *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` |
| 3077 | break;; |
| 3078 | esac |
| 3079 | done |
| 3080 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3081 | $as_echo "$as_me: failed program was:" >&5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3082 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 3083 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3084 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3085 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 3086 | as_fn_error $? "cannot compute suffix of object files: cannot compile |
| 3087 | See \`config.log' for more details" "$LINENO" 5; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3088 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3089 | rm -f conftest.$ac_cv_objext conftest.$ac_ext |
| 3090 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3091 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 |
| 3092 | $as_echo "$ac_cv_objext" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3093 | OBJEXT=$ac_cv_objext |
| 3094 | ac_objext=$OBJEXT |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3095 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 |
| 3096 | $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } |
| 3097 | if ${ac_cv_c_compiler_gnu+:} false; then : |
| 3098 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3099 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3100 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3101 | /* end confdefs.h. */ |
| 3102 | |
| 3103 | int |
| 3104 | main () |
| 3105 | { |
| 3106 | #ifndef __GNUC__ |
| 3107 | choke me |
| 3108 | #endif |
| 3109 | |
| 3110 | ; |
| 3111 | return 0; |
| 3112 | } |
| 3113 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3114 | if ac_fn_c_try_compile "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3115 | ac_compiler_gnu=yes |
| 3116 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3117 | ac_compiler_gnu=no |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3118 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3119 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 3120 | ac_cv_c_compiler_gnu=$ac_compiler_gnu |
| 3121 | |
| 3122 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3123 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 |
| 3124 | $as_echo "$ac_cv_c_compiler_gnu" >&6; } |
| 3125 | if test $ac_compiler_gnu = yes; then |
| 3126 | GCC=yes |
| 3127 | else |
| 3128 | GCC= |
| 3129 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3130 | ac_test_CFLAGS=${CFLAGS+set} |
| 3131 | ac_save_CFLAGS=$CFLAGS |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3132 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 |
| 3133 | $as_echo_n "checking whether $CC accepts -g... " >&6; } |
| 3134 | if ${ac_cv_prog_cc_g+:} false; then : |
| 3135 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3136 | else |
| 3137 | ac_save_c_werror_flag=$ac_c_werror_flag |
| 3138 | ac_c_werror_flag=yes |
| 3139 | ac_cv_prog_cc_g=no |
| 3140 | CFLAGS="-g" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3141 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3142 | /* end confdefs.h. */ |
| 3143 | |
| 3144 | int |
| 3145 | main () |
| 3146 | { |
| 3147 | |
| 3148 | ; |
| 3149 | return 0; |
| 3150 | } |
| 3151 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3152 | if ac_fn_c_try_compile "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3153 | ac_cv_prog_cc_g=yes |
| 3154 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3155 | CFLAGS="" |
| 3156 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3157 | /* end confdefs.h. */ |
| 3158 | |
| 3159 | int |
| 3160 | main () |
| 3161 | { |
| 3162 | |
| 3163 | ; |
| 3164 | return 0; |
| 3165 | } |
| 3166 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3167 | if ac_fn_c_try_compile "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3168 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3169 | else |
| 3170 | ac_c_werror_flag=$ac_save_c_werror_flag |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3171 | CFLAGS="-g" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3172 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3173 | /* end confdefs.h. */ |
| 3174 | |
| 3175 | int |
| 3176 | main () |
| 3177 | { |
| 3178 | |
| 3179 | ; |
| 3180 | return 0; |
| 3181 | } |
| 3182 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3183 | if ac_fn_c_try_compile "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3184 | ac_cv_prog_cc_g=yes |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3185 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3186 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 3187 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3188 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 3189 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3190 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 3191 | ac_c_werror_flag=$ac_save_c_werror_flag |
| 3192 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3193 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 |
| 3194 | $as_echo "$ac_cv_prog_cc_g" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3195 | if test "$ac_test_CFLAGS" = set; then |
| 3196 | CFLAGS=$ac_save_CFLAGS |
| 3197 | elif test $ac_cv_prog_cc_g = yes; then |
| 3198 | if test "$GCC" = yes; then |
| 3199 | CFLAGS="-g -O2" |
| 3200 | else |
| 3201 | CFLAGS="-g" |
| 3202 | fi |
| 3203 | else |
| 3204 | if test "$GCC" = yes; then |
| 3205 | CFLAGS="-O2" |
| 3206 | else |
| 3207 | CFLAGS= |
| 3208 | fi |
| 3209 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3210 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 |
| 3211 | $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } |
| 3212 | if ${ac_cv_prog_cc_c89+:} false; then : |
| 3213 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3214 | else |
| 3215 | ac_cv_prog_cc_c89=no |
| 3216 | ac_save_CC=$CC |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3217 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3218 | /* end confdefs.h. */ |
| 3219 | #include <stdarg.h> |
| 3220 | #include <stdio.h> |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3221 | struct stat; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3222 | /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ |
| 3223 | struct buf { int x; }; |
| 3224 | FILE * (*rcsopen) (struct buf *, struct stat *, int); |
| 3225 | static char *e (p, i) |
| 3226 | char **p; |
| 3227 | int i; |
| 3228 | { |
| 3229 | return p[i]; |
| 3230 | } |
| 3231 | static char *f (char * (*g) (char **, int), char **p, ...) |
| 3232 | { |
| 3233 | char *s; |
| 3234 | va_list v; |
| 3235 | va_start (v,p); |
| 3236 | s = g (p, va_arg (v,int)); |
| 3237 | va_end (v); |
| 3238 | return s; |
| 3239 | } |
| 3240 | |
| 3241 | /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has |
| 3242 | function prototypes and stuff, but not '\xHH' hex character constants. |
| 3243 | These don't provoke an error unfortunately, instead are silently treated |
| 3244 | as 'x'. The following induces an error, until -std is added to get |
| 3245 | proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an |
| 3246 | array size at least. It's necessary to write '\x00'==0 to get something |
| 3247 | that's true only with -std. */ |
| 3248 | int osf4_cc_array ['\x00' == 0 ? 1 : -1]; |
| 3249 | |
| 3250 | /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters |
| 3251 | inside strings and character constants. */ |
| 3252 | #define FOO(x) 'x' |
| 3253 | int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; |
| 3254 | |
| 3255 | int test (int i, double x); |
| 3256 | struct s1 {int (*f) (int a);}; |
| 3257 | struct s2 {int (*f) (double a);}; |
| 3258 | int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); |
| 3259 | int argc; |
| 3260 | char **argv; |
| 3261 | int |
| 3262 | main () |
| 3263 | { |
| 3264 | return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; |
| 3265 | ; |
| 3266 | return 0; |
| 3267 | } |
| 3268 | _ACEOF |
| 3269 | for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ |
| 3270 | -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" |
| 3271 | do |
| 3272 | CC="$ac_save_CC $ac_arg" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3273 | if ac_fn_c_try_compile "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3274 | ac_cv_prog_cc_c89=$ac_arg |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3275 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3276 | rm -f core conftest.err conftest.$ac_objext |
| 3277 | test "x$ac_cv_prog_cc_c89" != "xno" && break |
| 3278 | done |
| 3279 | rm -f conftest.$ac_ext |
| 3280 | CC=$ac_save_CC |
| 3281 | |
| 3282 | fi |
| 3283 | # AC_CACHE_VAL |
| 3284 | case "x$ac_cv_prog_cc_c89" in |
| 3285 | x) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3286 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 |
| 3287 | $as_echo "none needed" >&6; } ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3288 | xno) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3289 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 |
| 3290 | $as_echo "unsupported" >&6; } ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3291 | *) |
| 3292 | CC="$CC $ac_cv_prog_cc_c89" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3293 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 |
| 3294 | $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3295 | esac |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3296 | if test "x$ac_cv_prog_cc_c89" != xno; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3297 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3298 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3299 | |
| 3300 | ac_ext=c |
| 3301 | ac_cpp='$CPP $CPPFLAGS' |
| 3302 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 3303 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 3304 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 3305 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3306 | |
| 3307 | |
| 3308 | |
| 3309 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3310 | if test "$GCC" = yes ; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3311 | # |
| 3312 | # -Werror forces warnings to be errors. |
| 3313 | # |
| 3314 | ac_lbl_cc_force_warning_errors=-Werror |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3315 | else |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3316 | V_INCLS="$V_INCLS -I/usr/local/include" |
| 3317 | LDFLAGS="$LDFLAGS -L/usr/local/lib" |
| 3318 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3319 | case "$host_os" in |
| 3320 | |
| 3321 | darwin*) |
| 3322 | # |
| 3323 | # This is assumed either to be GCC or clang, both |
| 3324 | # of which use -Werror to force warnings to be errors. |
| 3325 | # |
| 3326 | ac_lbl_cc_force_warning_errors=-Werror |
| 3327 | ;; |
| 3328 | |
| 3329 | hpux*) |
| 3330 | # |
| 3331 | # HP C, which is what we presume we're using, doesn't |
| 3332 | # exit with a non-zero exit status if we hand it an |
| 3333 | # invalid -W flag, can't be forced to do so even with |
| 3334 | # +We, and doesn't handle GCC-style -W flags, so we |
| 3335 | # don't want to try using GCC-style -W flags. |
| 3336 | # |
| 3337 | ac_lbl_cc_dont_try_gcc_dashW=yes |
| 3338 | ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3339 | |
| 3340 | irix*) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3341 | # |
| 3342 | # MIPS C, which is what we presume we're using, doesn't |
| 3343 | # necessarily exit with a non-zero exit status if we |
| 3344 | # hand it an invalid -W flag, can't be forced to do |
| 3345 | # so, and doesn't handle GCC-style -W flags, so we |
| 3346 | # don't want to try using GCC-style -W flags. |
| 3347 | # |
| 3348 | ac_lbl_cc_dont_try_gcc_dashW=yes |
| 3349 | # |
| 3350 | # It also, apparently, defaults to "char" being |
| 3351 | # unsigned, unlike most other C implementations; |
| 3352 | # I suppose we could say "signed char" whenever |
| 3353 | # we want to guarantee a signed "char", but let's |
| 3354 | # just force signed chars. |
| 3355 | # |
| 3356 | # -xansi is normally the default, but the |
| 3357 | # configure script was setting it; perhaps -cckr |
| 3358 | # was the default in the Old Days. (Then again, |
| 3359 | # that would probably be for backwards compatibility |
| 3360 | # in the days when ANSI C was Shiny and New, i.e. |
| 3361 | # 1989 and the early '90's, so maybe we can just |
| 3362 | # drop support for those compilers.) |
| 3363 | # |
| 3364 | # -g is equivalent to -g2, which turns off |
| 3365 | # optimization; we choose -g3, which generates |
| 3366 | # debugging information but doesn't turn off |
| 3367 | # optimization (even if the optimization would |
| 3368 | # cause inaccuracies in debugging). |
| 3369 | # |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3370 | V_CCOPT="$V_CCOPT -xansi -signed -g3" |
| 3371 | ;; |
| 3372 | |
| 3373 | osf*) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3374 | # |
| 3375 | # Presumed to be DEC OSF/1, Digital UNIX, or |
| 3376 | # Tru64 UNIX. |
| 3377 | # |
| 3378 | # The DEC C compiler, which is what we presume we're |
| 3379 | # using, doesn't exit with a non-zero exit status if we |
| 3380 | # hand it an invalid -W flag, can't be forced to do |
| 3381 | # so, and doesn't handle GCC-style -W flags, so we |
| 3382 | # don't want to try using GCC-style -W flags. |
| 3383 | # |
| 3384 | ac_lbl_cc_dont_try_gcc_dashW=yes |
| 3385 | # |
| 3386 | # -g is equivalent to -g2, which turns off |
| 3387 | # optimization; we choose -g3, which generates |
| 3388 | # debugging information but doesn't turn off |
| 3389 | # optimization (even if the optimization would |
| 3390 | # cause inaccuracies in debugging). |
| 3391 | # |
| 3392 | V_CCOPT="$V_CCOPT -g3" |
| 3393 | ;; |
| 3394 | |
| 3395 | solaris*) |
| 3396 | # |
| 3397 | # Assumed to be Sun C, which requires -errwarn to force |
| 3398 | # warnings to be treated as errors. |
| 3399 | # |
| 3400 | ac_lbl_cc_force_warning_errors=-errwarn |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3401 | ;; |
| 3402 | |
| 3403 | ultrix*) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3404 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking that Ultrix $CC hacks const in prototypes" >&5 |
| 3405 | $as_echo_n "checking that Ultrix $CC hacks const in prototypes... " >&6; } |
| 3406 | if ${ac_cv_lbl_cc_const_proto+:} false; then : |
| 3407 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3408 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3409 | |
| 3410 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3411 | /* end confdefs.h. */ |
| 3412 | #include <sys/types.h> |
| 3413 | int |
| 3414 | main () |
| 3415 | { |
| 3416 | struct a { int b; }; |
| 3417 | void c(const struct a *) |
| 3418 | ; |
| 3419 | return 0; |
| 3420 | } |
| 3421 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3422 | if ac_fn_c_try_compile "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3423 | ac_cv_lbl_cc_const_proto=yes |
| 3424 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3425 | ac_cv_lbl_cc_const_proto=no |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3426 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3427 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 3428 | fi |
| 3429 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3430 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_cc_const_proto" >&5 |
| 3431 | $as_echo "$ac_cv_lbl_cc_const_proto" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3432 | if test $ac_cv_lbl_cc_const_proto = no ; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3433 | |
| 3434 | $as_echo "#define const /**/" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3435 | |
| 3436 | fi |
| 3437 | ;; |
| 3438 | esac |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3439 | V_CCOPT="$V_CCOPT -O" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3440 | fi |
| 3441 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3442 | |
| 3443 | if test "$GCC" = yes ; then |
| 3444 | # |
| 3445 | # On platforms where we build a shared library: |
| 3446 | # |
| 3447 | # add options to generate position-independent code, |
| 3448 | # if necessary (it's the default in AIX and Darwin/OS X); |
| 3449 | # |
| 3450 | # define option to set the soname of the shared library, |
| 3451 | # if the OS supports that; |
| 3452 | # |
| 3453 | # add options to specify, at link time, a directory to |
| 3454 | # add to the run-time search path, if that's necessary. |
| 3455 | # |
| 3456 | V_SHLIB_CMD="\$(CC)" |
| 3457 | V_SHLIB_OPT="-shared" |
| 3458 | case "$host_os" in |
| 3459 | |
| 3460 | aix*) |
| 3461 | ;; |
| 3462 | |
| 3463 | freebsd*|netbsd*|openbsd*|dragonfly*|linux*|osf*) |
| 3464 | # |
| 3465 | # Platforms where the linker is the GNU linker |
| 3466 | # or accepts command-line arguments like |
| 3467 | # those the GNU linker accepts. |
| 3468 | # |
| 3469 | # Some instruction sets require -fPIC on some |
| 3470 | # operating systems. Check for them. If you |
| 3471 | # have a combination that requires it, add it |
| 3472 | # here. |
| 3473 | # |
| 3474 | PIC_OPT=-fpic |
| 3475 | case "$host_cpu" in |
| 3476 | |
| 3477 | sparc64*) |
| 3478 | case "$host_os" in |
| 3479 | |
| 3480 | freebsd*|openbsd*) |
| 3481 | PIC_OPT=-fPIC |
| 3482 | ;; |
| 3483 | esac |
| 3484 | ;; |
| 3485 | esac |
| 3486 | V_CCOPT="$V_CCOPT $PIC_OPT" |
| 3487 | V_SONAME_OPT="-Wl,-soname," |
| 3488 | V_RPATH_OPT="-Wl,-rpath," |
| 3489 | ;; |
| 3490 | |
| 3491 | hpux*) |
| 3492 | V_CCOPT="$V_CCOPT -fpic" |
| 3493 | # |
| 3494 | # XXX - this assumes GCC is using the HP linker, |
| 3495 | # rather than the GNU linker, and that the "+h" |
| 3496 | # option is used on all HP-UX platforms, both .sl |
| 3497 | # and .so. |
| 3498 | # |
| 3499 | V_SONAME_OPT="-Wl,+h," |
| 3500 | # |
| 3501 | # By default, directories specifed with -L |
| 3502 | # are added to the run-time search path, so |
| 3503 | # we don't add them in pcap-config. |
| 3504 | # |
| 3505 | ;; |
| 3506 | |
| 3507 | solaris*) |
| 3508 | V_CCOPT="$V_CCOPT -fpic" |
| 3509 | # |
| 3510 | # XXX - this assumes GCC is using the Sun linker, |
| 3511 | # rather than the GNU linker. |
| 3512 | # |
| 3513 | V_SONAME_OPT="-Wl,-h," |
| 3514 | V_RPATH_OPT="-Wl,-R," |
| 3515 | ;; |
| 3516 | esac |
| 3517 | else |
| 3518 | # |
| 3519 | # Set the appropriate compiler flags and, on platforms |
| 3520 | # where we build a shared library: |
| 3521 | # |
| 3522 | # add options to generate position-independent code, |
| 3523 | # if necessary (it's the default in Darwin/OS X); |
| 3524 | # |
| 3525 | # if we generate ".so" shared libraries, define the |
| 3526 | # appropriate options for building the shared library; |
| 3527 | # |
| 3528 | # add options to specify, at link time, a directory to |
| 3529 | # add to the run-time search path, if that's necessary. |
| 3530 | # |
| 3531 | # Note: spaces after V_SONAME_OPT are significant; on |
| 3532 | # some platforms the soname is passed with a GCC-like |
| 3533 | # "-Wl,-soname,{soname}" option, with the soname part |
| 3534 | # of the option, while on other platforms the C compiler |
| 3535 | # driver takes it as a regular option with the soname |
| 3536 | # following the option. The same applies to V_RPATH_OPT. |
| 3537 | # |
| 3538 | case "$host_os" in |
| 3539 | |
| 3540 | aix*) |
| 3541 | V_SHLIB_CMD="\$(CC)" |
| 3542 | V_SHLIB_OPT="-G -bnoentry -bexpall" |
| 3543 | ;; |
| 3544 | |
| 3545 | freebsd*|netbsd*|openbsd*|dragonfly*|linux*) |
| 3546 | # |
| 3547 | # "cc" is GCC. |
| 3548 | # |
| 3549 | V_CCOPT="$V_CCOPT -fpic" |
| 3550 | V_SHLIB_CMD="\$(CC)" |
| 3551 | V_SHLIB_OPT="-shared" |
| 3552 | V_SONAME_OPT="-Wl,-soname," |
| 3553 | V_RPATH_OPT="-Wl,-rpath," |
| 3554 | ;; |
| 3555 | |
| 3556 | hpux*) |
| 3557 | V_CCOPT="$V_CCOPT +z" |
| 3558 | V_SHLIB_CMD="\$(LD)" |
| 3559 | V_SHLIB_OPT="-b" |
| 3560 | V_SONAME_OPT="+h " |
| 3561 | # |
| 3562 | # By default, directories specifed with -L |
| 3563 | # are added to the run-time search path, so |
| 3564 | # we don't add them in pcap-config. |
| 3565 | # |
| 3566 | ;; |
| 3567 | |
| 3568 | osf*) |
| 3569 | # |
| 3570 | # Presumed to be DEC OSF/1, Digital UNIX, or |
| 3571 | # Tru64 UNIX. |
| 3572 | # |
| 3573 | V_SHLIB_CMD="\$(CC)" |
| 3574 | V_SHLIB_OPT="-shared" |
| 3575 | V_SONAME_OPT="-soname " |
| 3576 | V_RPATH_OPT="-rpath " |
| 3577 | ;; |
| 3578 | |
| 3579 | solaris*) |
| 3580 | V_CCOPT="$V_CCOPT -Kpic" |
| 3581 | V_SHLIB_CMD="\$(CC)" |
| 3582 | V_SHLIB_OPT="-G" |
| 3583 | V_SONAME_OPT="-h " |
| 3584 | V_RPATH_OPT="-R" |
| 3585 | ;; |
| 3586 | esac |
| 3587 | fi |
| 3588 | |
| 3589 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 |
| 3590 | $as_echo_n "checking for inline... " >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3591 | save_CFLAGS="$CFLAGS" |
| 3592 | CFLAGS="$V_CCOPT" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3593 | if ${ac_cv_lbl_inline+:} false; then : |
| 3594 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3595 | else |
| 3596 | |
| 3597 | ac_cv_lbl_inline="" |
| 3598 | ac_lbl_cc_inline=no |
| 3599 | for ac_lbl_inline in inline __inline__ __inline |
| 3600 | do |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3601 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3602 | /* end confdefs.h. */ |
| 3603 | #define inline $ac_lbl_inline |
| 3604 | static inline struct iltest *foo(void); |
| 3605 | struct iltest { |
| 3606 | int iltest1; |
| 3607 | int iltest2; |
| 3608 | }; |
| 3609 | |
| 3610 | static inline struct iltest * |
| 3611 | foo() |
| 3612 | { |
| 3613 | static struct iltest xxx; |
| 3614 | |
| 3615 | return &xxx; |
| 3616 | } |
| 3617 | int |
| 3618 | main () |
| 3619 | { |
| 3620 | |
| 3621 | ; |
| 3622 | return 0; |
| 3623 | } |
| 3624 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3625 | if ac_fn_c_try_compile "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3626 | ac_lbl_cc_inline=yes |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3627 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3628 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 3629 | if test "$ac_lbl_cc_inline" = yes ; then |
| 3630 | break; |
| 3631 | fi |
| 3632 | done |
| 3633 | if test "$ac_lbl_cc_inline" = yes ; then |
| 3634 | ac_cv_lbl_inline=$ac_lbl_inline |
| 3635 | fi |
| 3636 | fi |
| 3637 | |
| 3638 | CFLAGS="$save_CFLAGS" |
| 3639 | if test ! -z "$ac_cv_lbl_inline" ; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3640 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_inline" >&5 |
| 3641 | $as_echo "$ac_cv_lbl_inline" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3642 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3643 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3644 | $as_echo "no" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3645 | fi |
| 3646 | |
| 3647 | cat >>confdefs.h <<_ACEOF |
| 3648 | #define inline $ac_cv_lbl_inline |
| 3649 | _ACEOF |
| 3650 | |
| 3651 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3652 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __attribute__" >&5 |
| 3653 | $as_echo_n "checking for __attribute__... " >&6; } |
| 3654 | if ${ac_cv___attribute__+:} false; then : |
| 3655 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3656 | else |
| 3657 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3658 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3659 | /* end confdefs.h. */ |
| 3660 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3661 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3662 | #include <stdlib.h> |
| 3663 | |
| 3664 | static void foo(void) __attribute__ ((noreturn)); |
| 3665 | |
| 3666 | static void |
| 3667 | foo(void) |
| 3668 | { |
| 3669 | exit(1); |
| 3670 | } |
| 3671 | |
| 3672 | int |
| 3673 | main(int argc, char **argv) |
| 3674 | { |
| 3675 | foo(); |
| 3676 | } |
| 3677 | |
| 3678 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3679 | if ac_fn_c_try_compile "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3680 | ac_cv___attribute__=yes |
| 3681 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3682 | ac_cv___attribute__=no |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3683 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3684 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 3685 | fi |
| 3686 | |
| 3687 | if test "$ac_cv___attribute__" = "yes"; then |
| 3688 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3689 | $as_echo "#define HAVE___ATTRIBUTE__ 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3690 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3691 | else |
| 3692 | # |
| 3693 | # We can't use __attribute__, so we can't use __attribute__((unused)), |
| 3694 | # so we define _U_ to an empty string. |
| 3695 | # |
| 3696 | V_DEFS="$V_DEFS -D_U_=\"\"" |
| 3697 | fi |
| 3698 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv___attribute__" >&5 |
| 3699 | $as_echo "$ac_cv___attribute__" >&6; } |
| 3700 | |
| 3701 | if test "$ac_cv___attribute__" = "yes"; then |
| 3702 | |
| 3703 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __attribute__((unused)) can be used without warnings" >&5 |
| 3704 | $as_echo_n "checking whether __attribute__((unused)) can be used without warnings... " >&6; } |
| 3705 | if ${ac_cv___attribute___unused+:} false; then : |
| 3706 | $as_echo_n "(cached) " >&6 |
| 3707 | else |
| 3708 | |
| 3709 | save_CFLAGS="$CFLAGS" |
| 3710 | CFLAGS="$CFLAGS $ac_lbl_cc_force_warning_errors" |
| 3711 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 3712 | /* end confdefs.h. */ |
| 3713 | |
| 3714 | |
| 3715 | #include <stdlib.h> |
| 3716 | #include <stdio.h> |
| 3717 | |
| 3718 | int |
| 3719 | main(int argc __attribute((unused)), char **argv __attribute((unused))) |
| 3720 | { |
| 3721 | printf("Hello, world!\n"); |
| 3722 | return 0; |
| 3723 | } |
| 3724 | |
| 3725 | _ACEOF |
| 3726 | if ac_fn_c_try_compile "$LINENO"; then : |
| 3727 | ac_cv___attribute___unused=yes |
| 3728 | else |
| 3729 | ac_cv___attribute___unused=no |
| 3730 | fi |
| 3731 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 3732 | fi |
| 3733 | |
| 3734 | CFLAGS="$save_CFLAGS" |
| 3735 | if test "$ac_cv___attribute___unused" = "yes"; then |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3736 | V_DEFS="$V_DEFS -D_U_=\"__attribute__((unused))\"" |
| 3737 | else |
| 3738 | V_DEFS="$V_DEFS -D_U_=\"\"" |
| 3739 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3740 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv___attribute___unused" >&5 |
| 3741 | $as_echo "$ac_cv___attribute___unused" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3742 | |
| 3743 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3744 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __attribute__((format)) can be used without warnings" >&5 |
| 3745 | $as_echo_n "checking whether __attribute__((format)) can be used without warnings... " >&6; } |
| 3746 | if ${ac_cv___attribute___format+:} false; then : |
| 3747 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3748 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3749 | |
| 3750 | save_CFLAGS="$CFLAGS" |
| 3751 | CFLAGS="$CFLAGS $ac_lbl_cc_force_warning_errors" |
| 3752 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3753 | /* end confdefs.h. */ |
| 3754 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3755 | |
| 3756 | #include <stdlib.h> |
| 3757 | |
| 3758 | extern int foo(const char *fmt, ...) |
| 3759 | __attribute__ ((format (printf, 1, 2))); |
| 3760 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3761 | int |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3762 | main(int argc, char **argv) |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3763 | { |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3764 | foo("%s", "test"); |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3765 | } |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3766 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3767 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3768 | if ac_fn_c_try_compile "$LINENO"; then : |
| 3769 | ac_cv___attribute___format=yes |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3770 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3771 | ac_cv___attribute___format=no |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3772 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3773 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 3774 | fi |
| 3775 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3776 | CFLAGS="$save_CFLAGS" |
| 3777 | if test "$ac_cv___attribute___format" = "yes"; then |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3778 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3779 | $as_echo "#define __ATTRIBUTE___FORMAT_OK 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3780 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3781 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3782 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv___attribute___format" >&5 |
| 3783 | $as_echo "$ac_cv___attribute___format" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3784 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3785 | fi |
| 3786 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3787 | ac_ext=c |
| 3788 | ac_cpp='$CPP $CPPFLAGS' |
| 3789 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 3790 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 3791 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3792 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 |
| 3793 | $as_echo_n "checking how to run the C preprocessor... " >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3794 | # On Suns, sometimes $CPP names a directory. |
| 3795 | if test -n "$CPP" && test -d "$CPP"; then |
| 3796 | CPP= |
| 3797 | fi |
| 3798 | if test -z "$CPP"; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3799 | if ${ac_cv_prog_CPP+:} false; then : |
| 3800 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3801 | else |
| 3802 | # Double quotes because CPP needs to be expanded |
| 3803 | for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" |
| 3804 | do |
| 3805 | ac_preproc_ok=false |
| 3806 | for ac_c_preproc_warn_flag in '' yes |
| 3807 | do |
| 3808 | # Use a header file that comes with gcc, so configuring glibc |
| 3809 | # with a fresh cross-compiler works. |
| 3810 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 3811 | # <limits.h> exists even on freestanding compilers. |
| 3812 | # On the NeXT, cc -E runs the code through the compiler's parser, |
| 3813 | # not just through cpp. "Syntax error" is here to catch this case. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3814 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3815 | /* end confdefs.h. */ |
| 3816 | #ifdef __STDC__ |
| 3817 | # include <limits.h> |
| 3818 | #else |
| 3819 | # include <assert.h> |
| 3820 | #endif |
| 3821 | Syntax error |
| 3822 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3823 | if ac_fn_c_try_cpp "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3824 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3825 | else |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3826 | # Broken: fails on valid input. |
| 3827 | continue |
| 3828 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3829 | rm -f conftest.err conftest.i conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3830 | |
| 3831 | # OK, works on sane cases. Now check whether nonexistent headers |
| 3832 | # can be detected and how. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3833 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3834 | /* end confdefs.h. */ |
| 3835 | #include <ac_nonexistent.h> |
| 3836 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3837 | if ac_fn_c_try_cpp "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3838 | # Broken: success on invalid input. |
| 3839 | continue |
| 3840 | else |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3841 | # Passes both tests. |
| 3842 | ac_preproc_ok=: |
| 3843 | break |
| 3844 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3845 | rm -f conftest.err conftest.i conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3846 | |
| 3847 | done |
| 3848 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3849 | rm -f conftest.i conftest.err conftest.$ac_ext |
| 3850 | if $ac_preproc_ok; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3851 | break |
| 3852 | fi |
| 3853 | |
| 3854 | done |
| 3855 | ac_cv_prog_CPP=$CPP |
| 3856 | |
| 3857 | fi |
| 3858 | CPP=$ac_cv_prog_CPP |
| 3859 | else |
| 3860 | ac_cv_prog_CPP=$CPP |
| 3861 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3862 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 |
| 3863 | $as_echo "$CPP" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3864 | ac_preproc_ok=false |
| 3865 | for ac_c_preproc_warn_flag in '' yes |
| 3866 | do |
| 3867 | # Use a header file that comes with gcc, so configuring glibc |
| 3868 | # with a fresh cross-compiler works. |
| 3869 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 3870 | # <limits.h> exists even on freestanding compilers. |
| 3871 | # On the NeXT, cc -E runs the code through the compiler's parser, |
| 3872 | # not just through cpp. "Syntax error" is here to catch this case. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3873 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3874 | /* end confdefs.h. */ |
| 3875 | #ifdef __STDC__ |
| 3876 | # include <limits.h> |
| 3877 | #else |
| 3878 | # include <assert.h> |
| 3879 | #endif |
| 3880 | Syntax error |
| 3881 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3882 | if ac_fn_c_try_cpp "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3883 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3884 | else |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3885 | # Broken: fails on valid input. |
| 3886 | continue |
| 3887 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3888 | rm -f conftest.err conftest.i conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3889 | |
| 3890 | # OK, works on sane cases. Now check whether nonexistent headers |
| 3891 | # can be detected and how. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3892 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3893 | /* end confdefs.h. */ |
| 3894 | #include <ac_nonexistent.h> |
| 3895 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3896 | if ac_fn_c_try_cpp "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3897 | # Broken: success on invalid input. |
| 3898 | continue |
| 3899 | else |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3900 | # Passes both tests. |
| 3901 | ac_preproc_ok=: |
| 3902 | break |
| 3903 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3904 | rm -f conftest.err conftest.i conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3905 | |
| 3906 | done |
| 3907 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3908 | rm -f conftest.i conftest.err conftest.$ac_ext |
| 3909 | if $ac_preproc_ok; then : |
| 3910 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3911 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3912 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3913 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 3914 | as_fn_error $? "C preprocessor \"$CPP\" fails sanity check |
| 3915 | See \`config.log' for more details" "$LINENO" 5; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3916 | fi |
| 3917 | |
| 3918 | ac_ext=c |
| 3919 | ac_cpp='$CPP $CPPFLAGS' |
| 3920 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 3921 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 3922 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 3923 | |
| 3924 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3925 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 |
| 3926 | $as_echo_n "checking for grep that handles long lines and -e... " >&6; } |
| 3927 | if ${ac_cv_path_GREP+:} false; then : |
| 3928 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3929 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3930 | if test -z "$GREP"; then |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3931 | ac_path_GREP_found=false |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3932 | # Loop through the user's path and test for each of PROGNAME-LIST |
| 3933 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3934 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin |
| 3935 | do |
| 3936 | IFS=$as_save_IFS |
| 3937 | test -z "$as_dir" && as_dir=. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3938 | for ac_prog in grep ggrep; do |
| 3939 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 3940 | ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" |
| 3941 | as_fn_executable_p "$ac_path_GREP" || continue |
| 3942 | # Check for GNU ac_path_GREP and select it if it is found. |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3943 | # Check for GNU $ac_path_GREP |
| 3944 | case `"$ac_path_GREP" --version 2>&1` in |
| 3945 | *GNU*) |
| 3946 | ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; |
| 3947 | *) |
| 3948 | ac_count=0 |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3949 | $as_echo_n 0123456789 >"conftest.in" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3950 | while : |
| 3951 | do |
| 3952 | cat "conftest.in" "conftest.in" >"conftest.tmp" |
| 3953 | mv "conftest.tmp" "conftest.in" |
| 3954 | cp "conftest.in" "conftest.nl" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3955 | $as_echo 'GREP' >> "conftest.nl" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3956 | "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break |
| 3957 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3958 | as_fn_arith $ac_count + 1 && ac_count=$as_val |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3959 | if test $ac_count -gt ${ac_path_GREP_max-0}; then |
| 3960 | # Best one so far, save it but keep looking for a better one |
| 3961 | ac_cv_path_GREP="$ac_path_GREP" |
| 3962 | ac_path_GREP_max=$ac_count |
| 3963 | fi |
| 3964 | # 10*(2^10) chars as input seems more than enough |
| 3965 | test $ac_count -gt 10 && break |
| 3966 | done |
| 3967 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; |
| 3968 | esac |
| 3969 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3970 | $ac_path_GREP_found && break 3 |
| 3971 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3972 | done |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3973 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3974 | IFS=$as_save_IFS |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3975 | if test -z "$ac_cv_path_GREP"; then |
| 3976 | as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 |
| 3977 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3978 | else |
| 3979 | ac_cv_path_GREP=$GREP |
| 3980 | fi |
| 3981 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3982 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3983 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 |
| 3984 | $as_echo "$ac_cv_path_GREP" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3985 | GREP="$ac_cv_path_GREP" |
| 3986 | |
| 3987 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3988 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 |
| 3989 | $as_echo_n "checking for egrep... " >&6; } |
| 3990 | if ${ac_cv_path_EGREP+:} false; then : |
| 3991 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3992 | else |
| 3993 | if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 |
| 3994 | then ac_cv_path_EGREP="$GREP -E" |
| 3995 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3996 | if test -z "$EGREP"; then |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 3997 | ac_path_EGREP_found=false |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 3998 | # Loop through the user's path and test for each of PROGNAME-LIST |
| 3999 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4000 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin |
| 4001 | do |
| 4002 | IFS=$as_save_IFS |
| 4003 | test -z "$as_dir" && as_dir=. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4004 | for ac_prog in egrep; do |
| 4005 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 4006 | ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" |
| 4007 | as_fn_executable_p "$ac_path_EGREP" || continue |
| 4008 | # Check for GNU ac_path_EGREP and select it if it is found. |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4009 | # Check for GNU $ac_path_EGREP |
| 4010 | case `"$ac_path_EGREP" --version 2>&1` in |
| 4011 | *GNU*) |
| 4012 | ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; |
| 4013 | *) |
| 4014 | ac_count=0 |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4015 | $as_echo_n 0123456789 >"conftest.in" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4016 | while : |
| 4017 | do |
| 4018 | cat "conftest.in" "conftest.in" >"conftest.tmp" |
| 4019 | mv "conftest.tmp" "conftest.in" |
| 4020 | cp "conftest.in" "conftest.nl" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4021 | $as_echo 'EGREP' >> "conftest.nl" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4022 | "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break |
| 4023 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4024 | as_fn_arith $ac_count + 1 && ac_count=$as_val |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4025 | if test $ac_count -gt ${ac_path_EGREP_max-0}; then |
| 4026 | # Best one so far, save it but keep looking for a better one |
| 4027 | ac_cv_path_EGREP="$ac_path_EGREP" |
| 4028 | ac_path_EGREP_max=$ac_count |
| 4029 | fi |
| 4030 | # 10*(2^10) chars as input seems more than enough |
| 4031 | test $ac_count -gt 10 && break |
| 4032 | done |
| 4033 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; |
| 4034 | esac |
| 4035 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4036 | $ac_path_EGREP_found && break 3 |
| 4037 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4038 | done |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4039 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4040 | IFS=$as_save_IFS |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4041 | if test -z "$ac_cv_path_EGREP"; then |
| 4042 | as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 |
| 4043 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4044 | else |
| 4045 | ac_cv_path_EGREP=$EGREP |
| 4046 | fi |
| 4047 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4048 | fi |
| 4049 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4050 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 |
| 4051 | $as_echo "$ac_cv_path_EGREP" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4052 | EGREP="$ac_cv_path_EGREP" |
| 4053 | |
| 4054 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4055 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 |
| 4056 | $as_echo_n "checking for ANSI C header files... " >&6; } |
| 4057 | if ${ac_cv_header_stdc+:} false; then : |
| 4058 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4059 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4060 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4061 | /* end confdefs.h. */ |
| 4062 | #include <stdlib.h> |
| 4063 | #include <stdarg.h> |
| 4064 | #include <string.h> |
| 4065 | #include <float.h> |
| 4066 | |
| 4067 | int |
| 4068 | main () |
| 4069 | { |
| 4070 | |
| 4071 | ; |
| 4072 | return 0; |
| 4073 | } |
| 4074 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4075 | if ac_fn_c_try_compile "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4076 | ac_cv_header_stdc=yes |
| 4077 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4078 | ac_cv_header_stdc=no |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4079 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4080 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4081 | |
| 4082 | if test $ac_cv_header_stdc = yes; then |
| 4083 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4084 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4085 | /* end confdefs.h. */ |
| 4086 | #include <string.h> |
| 4087 | |
| 4088 | _ACEOF |
| 4089 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4090 | $EGREP "memchr" >/dev/null 2>&1; then : |
| 4091 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4092 | else |
| 4093 | ac_cv_header_stdc=no |
| 4094 | fi |
| 4095 | rm -f conftest* |
| 4096 | |
| 4097 | fi |
| 4098 | |
| 4099 | if test $ac_cv_header_stdc = yes; then |
| 4100 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4101 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4102 | /* end confdefs.h. */ |
| 4103 | #include <stdlib.h> |
| 4104 | |
| 4105 | _ACEOF |
| 4106 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4107 | $EGREP "free" >/dev/null 2>&1; then : |
| 4108 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4109 | else |
| 4110 | ac_cv_header_stdc=no |
| 4111 | fi |
| 4112 | rm -f conftest* |
| 4113 | |
| 4114 | fi |
| 4115 | |
| 4116 | if test $ac_cv_header_stdc = yes; then |
| 4117 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4118 | if test "$cross_compiling" = yes; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4119 | : |
| 4120 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4121 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4122 | /* end confdefs.h. */ |
| 4123 | #include <ctype.h> |
| 4124 | #include <stdlib.h> |
| 4125 | #if ((' ' & 0x0FF) == 0x020) |
| 4126 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 4127 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
| 4128 | #else |
| 4129 | # define ISLOWER(c) \ |
| 4130 | (('a' <= (c) && (c) <= 'i') \ |
| 4131 | || ('j' <= (c) && (c) <= 'r') \ |
| 4132 | || ('s' <= (c) && (c) <= 'z')) |
| 4133 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) |
| 4134 | #endif |
| 4135 | |
| 4136 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
| 4137 | int |
| 4138 | main () |
| 4139 | { |
| 4140 | int i; |
| 4141 | for (i = 0; i < 256; i++) |
| 4142 | if (XOR (islower (i), ISLOWER (i)) |
| 4143 | || toupper (i) != TOUPPER (i)) |
| 4144 | return 2; |
| 4145 | return 0; |
| 4146 | } |
| 4147 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4148 | if ac_fn_c_try_run "$LINENO"; then : |
| 4149 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4150 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4151 | ac_cv_header_stdc=no |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4152 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4153 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 4154 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4155 | fi |
| 4156 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4157 | fi |
| 4158 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4159 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 |
| 4160 | $as_echo "$ac_cv_header_stdc" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4161 | if test $ac_cv_header_stdc = yes; then |
| 4162 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4163 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4164 | |
| 4165 | fi |
| 4166 | |
| 4167 | # On IRIX 5.3, sys/types and inttypes.h are conflicting. |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4168 | for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ |
| 4169 | inttypes.h stdint.h unistd.h |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4170 | do : |
| 4171 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 4172 | ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default |
| 4173 | " |
| 4174 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4175 | cat >>confdefs.h <<_ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4176 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4177 | _ACEOF |
| 4178 | |
| 4179 | fi |
| 4180 | |
| 4181 | done |
| 4182 | |
| 4183 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4184 | for ac_header in sys/bitypes.h |
| 4185 | do : |
| 4186 | ac_fn_c_check_header_mongrel "$LINENO" "sys/bitypes.h" "ac_cv_header_sys_bitypes_h" "$ac_includes_default" |
| 4187 | if test "x$ac_cv_header_sys_bitypes_h" = xyes; then : |
| 4188 | cat >>confdefs.h <<_ACEOF |
| 4189 | #define HAVE_SYS_BITYPES_H 1 |
| 4190 | _ACEOF |
| 4191 | |
| 4192 | fi |
| 4193 | |
| 4194 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4195 | |
| 4196 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4197 | ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default |
| 4198 | #ifdef HAVE_SYS_BITYPES_H |
| 4199 | #include <sys/bitypes.h> |
| 4200 | #endif |
| 4201 | " |
| 4202 | if test "x$ac_cv_type_int8_t" = xyes; then : |
| 4203 | |
| 4204 | else |
| 4205 | |
| 4206 | $as_echo "#define int8_t signed char" >>confdefs.h |
| 4207 | |
| 4208 | fi |
| 4209 | |
| 4210 | ac_fn_c_check_type "$LINENO" "u_int8_t" "ac_cv_type_u_int8_t" "$ac_includes_default |
| 4211 | #ifdef HAVE_SYS_BITYPES_H |
| 4212 | #include <sys/bitypes.h> |
| 4213 | #endif |
| 4214 | " |
| 4215 | if test "x$ac_cv_type_u_int8_t" = xyes; then : |
| 4216 | |
| 4217 | else |
| 4218 | |
| 4219 | $as_echo "#define u_int8_t unsigned char" >>confdefs.h |
| 4220 | |
| 4221 | fi |
| 4222 | |
| 4223 | ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default" |
| 4224 | if test "x$ac_cv_type_int16_t" = xyes; then : |
| 4225 | |
| 4226 | else |
| 4227 | |
| 4228 | $as_echo "#define int16_t short" >>confdefs.h |
| 4229 | |
| 4230 | $ac_includes_default |
| 4231 | #ifdef HAVE_SYS_BITYPES_H |
| 4232 | #include <sys/bitypes.h> |
| 4233 | #endif |
| 4234 | fi |
| 4235 | |
| 4236 | ac_fn_c_check_type "$LINENO" "u_int16_t" "ac_cv_type_u_int16_t" "$ac_includes_default |
| 4237 | #ifdef HAVE_SYS_BITYPES_H |
| 4238 | #include <sys/bitypes.h> |
| 4239 | #endif |
| 4240 | " |
| 4241 | if test "x$ac_cv_type_u_int16_t" = xyes; then : |
| 4242 | |
| 4243 | else |
| 4244 | |
| 4245 | $as_echo "#define u_int16_t unsigned short" >>confdefs.h |
| 4246 | |
| 4247 | fi |
| 4248 | |
| 4249 | ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default |
| 4250 | #ifdef HAVE_SYS_BITYPES_H |
| 4251 | #include <sys/bitypes.h> |
| 4252 | #endif |
| 4253 | " |
| 4254 | if test "x$ac_cv_type_int32_t" = xyes; then : |
| 4255 | |
| 4256 | else |
| 4257 | |
| 4258 | $as_echo "#define int32_t int" >>confdefs.h |
| 4259 | |
| 4260 | fi |
| 4261 | |
| 4262 | ac_fn_c_check_type "$LINENO" "u_int32_t" "ac_cv_type_u_int32_t" "$ac_includes_default |
| 4263 | #ifdef HAVE_SYS_BITYPES_H |
| 4264 | #include <sys/bitypes.h> |
| 4265 | #endif |
| 4266 | " |
| 4267 | if test "x$ac_cv_type_u_int32_t" = xyes; then : |
| 4268 | |
| 4269 | else |
| 4270 | |
| 4271 | $as_echo "#define u_int32_t unsigned int" >>confdefs.h |
| 4272 | |
| 4273 | fi |
| 4274 | |
| 4275 | ac_fn_c_check_type "$LINENO" "int64_t" "ac_cv_type_int64_t" "$ac_includes_default |
| 4276 | #ifdef HAVE_SYS_BITYPES_H |
| 4277 | #include <sys/bitypes.h> |
| 4278 | #endif |
| 4279 | " |
| 4280 | if test "x$ac_cv_type_int64_t" = xyes; then : |
| 4281 | |
| 4282 | else |
| 4283 | |
| 4284 | $as_echo "#define int64_t long long" >>confdefs.h |
| 4285 | |
| 4286 | fi |
| 4287 | |
| 4288 | ac_fn_c_check_type "$LINENO" "u_int64_t" "ac_cv_type_u_int64_t" "$ac_includes_default |
| 4289 | #ifdef HAVE_SYS_BITYPES_H |
| 4290 | #include <sys/bitypes.h> |
| 4291 | #endif |
| 4292 | " |
| 4293 | if test "x$ac_cv_type_u_int64_t" = xyes; then : |
| 4294 | |
| 4295 | else |
| 4296 | |
| 4297 | $as_echo "#define u_int64_t unsigned long long" >>confdefs.h |
| 4298 | |
| 4299 | fi |
| 4300 | |
| 4301 | |
| 4302 | # |
| 4303 | # Try to arrange for large file support. |
| 4304 | # |
| 4305 | # Check whether --enable-largefile was given. |
| 4306 | if test "${enable_largefile+set}" = set; then : |
| 4307 | enableval=$enable_largefile; |
| 4308 | fi |
| 4309 | |
| 4310 | if test "$enable_largefile" != no; then |
| 4311 | |
| 4312 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5 |
| 4313 | $as_echo_n "checking for special C compiler options needed for large files... " >&6; } |
| 4314 | if ${ac_cv_sys_largefile_CC+:} false; then : |
| 4315 | $as_echo_n "(cached) " >&6 |
| 4316 | else |
| 4317 | ac_cv_sys_largefile_CC=no |
| 4318 | if test "$GCC" != yes; then |
| 4319 | ac_save_CC=$CC |
| 4320 | while :; do |
| 4321 | # IRIX 6.2 and later do not support large files by default, |
| 4322 | # so use the C compiler's -n32 option if that helps. |
| 4323 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4324 | /* end confdefs.h. */ |
| 4325 | #include <sys/types.h> |
| 4326 | /* Check that off_t can represent 2**63 - 1 correctly. |
| 4327 | We can't simply define LARGE_OFF_T to be 9223372036854775807, |
| 4328 | since some C++ compilers masquerading as C compilers |
| 4329 | incorrectly reject 9223372036854775807. */ |
| 4330 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) |
| 4331 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 |
| 4332 | && LARGE_OFF_T % 2147483647 == 1) |
| 4333 | ? 1 : -1]; |
| 4334 | int |
| 4335 | main () |
| 4336 | { |
| 4337 | |
| 4338 | ; |
| 4339 | return 0; |
| 4340 | } |
| 4341 | _ACEOF |
| 4342 | if ac_fn_c_try_compile "$LINENO"; then : |
| 4343 | break |
| 4344 | fi |
| 4345 | rm -f core conftest.err conftest.$ac_objext |
| 4346 | CC="$CC -n32" |
| 4347 | if ac_fn_c_try_compile "$LINENO"; then : |
| 4348 | ac_cv_sys_largefile_CC=' -n32'; break |
| 4349 | fi |
| 4350 | rm -f core conftest.err conftest.$ac_objext |
| 4351 | break |
| 4352 | done |
| 4353 | CC=$ac_save_CC |
| 4354 | rm -f conftest.$ac_ext |
| 4355 | fi |
| 4356 | fi |
| 4357 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5 |
| 4358 | $as_echo "$ac_cv_sys_largefile_CC" >&6; } |
| 4359 | if test "$ac_cv_sys_largefile_CC" != no; then |
| 4360 | CC=$CC$ac_cv_sys_largefile_CC |
| 4361 | fi |
| 4362 | |
| 4363 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5 |
| 4364 | $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; } |
| 4365 | if ${ac_cv_sys_file_offset_bits+:} false; then : |
| 4366 | $as_echo_n "(cached) " >&6 |
| 4367 | else |
| 4368 | while :; do |
| 4369 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4370 | /* end confdefs.h. */ |
| 4371 | #include <sys/types.h> |
| 4372 | /* Check that off_t can represent 2**63 - 1 correctly. |
| 4373 | We can't simply define LARGE_OFF_T to be 9223372036854775807, |
| 4374 | since some C++ compilers masquerading as C compilers |
| 4375 | incorrectly reject 9223372036854775807. */ |
| 4376 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) |
| 4377 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 |
| 4378 | && LARGE_OFF_T % 2147483647 == 1) |
| 4379 | ? 1 : -1]; |
| 4380 | int |
| 4381 | main () |
| 4382 | { |
| 4383 | |
| 4384 | ; |
| 4385 | return 0; |
| 4386 | } |
| 4387 | _ACEOF |
| 4388 | if ac_fn_c_try_compile "$LINENO"; then : |
| 4389 | ac_cv_sys_file_offset_bits=no; break |
| 4390 | fi |
| 4391 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4392 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4393 | /* end confdefs.h. */ |
| 4394 | #define _FILE_OFFSET_BITS 64 |
| 4395 | #include <sys/types.h> |
| 4396 | /* Check that off_t can represent 2**63 - 1 correctly. |
| 4397 | We can't simply define LARGE_OFF_T to be 9223372036854775807, |
| 4398 | since some C++ compilers masquerading as C compilers |
| 4399 | incorrectly reject 9223372036854775807. */ |
| 4400 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) |
| 4401 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 |
| 4402 | && LARGE_OFF_T % 2147483647 == 1) |
| 4403 | ? 1 : -1]; |
| 4404 | int |
| 4405 | main () |
| 4406 | { |
| 4407 | |
| 4408 | ; |
| 4409 | return 0; |
| 4410 | } |
| 4411 | _ACEOF |
| 4412 | if ac_fn_c_try_compile "$LINENO"; then : |
| 4413 | ac_cv_sys_file_offset_bits=64; break |
| 4414 | fi |
| 4415 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4416 | ac_cv_sys_file_offset_bits=unknown |
| 4417 | break |
| 4418 | done |
| 4419 | fi |
| 4420 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5 |
| 4421 | $as_echo "$ac_cv_sys_file_offset_bits" >&6; } |
| 4422 | case $ac_cv_sys_file_offset_bits in #( |
| 4423 | no | unknown) ;; |
| 4424 | *) |
| 4425 | cat >>confdefs.h <<_ACEOF |
| 4426 | #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits |
| 4427 | _ACEOF |
| 4428 | ;; |
| 4429 | esac |
| 4430 | rm -rf conftest* |
| 4431 | if test $ac_cv_sys_file_offset_bits = unknown; then |
| 4432 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5 |
| 4433 | $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; } |
| 4434 | if ${ac_cv_sys_large_files+:} false; then : |
| 4435 | $as_echo_n "(cached) " >&6 |
| 4436 | else |
| 4437 | while :; do |
| 4438 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4439 | /* end confdefs.h. */ |
| 4440 | #include <sys/types.h> |
| 4441 | /* Check that off_t can represent 2**63 - 1 correctly. |
| 4442 | We can't simply define LARGE_OFF_T to be 9223372036854775807, |
| 4443 | since some C++ compilers masquerading as C compilers |
| 4444 | incorrectly reject 9223372036854775807. */ |
| 4445 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) |
| 4446 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 |
| 4447 | && LARGE_OFF_T % 2147483647 == 1) |
| 4448 | ? 1 : -1]; |
| 4449 | int |
| 4450 | main () |
| 4451 | { |
| 4452 | |
| 4453 | ; |
| 4454 | return 0; |
| 4455 | } |
| 4456 | _ACEOF |
| 4457 | if ac_fn_c_try_compile "$LINENO"; then : |
| 4458 | ac_cv_sys_large_files=no; break |
| 4459 | fi |
| 4460 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4461 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4462 | /* end confdefs.h. */ |
| 4463 | #define _LARGE_FILES 1 |
| 4464 | #include <sys/types.h> |
| 4465 | /* Check that off_t can represent 2**63 - 1 correctly. |
| 4466 | We can't simply define LARGE_OFF_T to be 9223372036854775807, |
| 4467 | since some C++ compilers masquerading as C compilers |
| 4468 | incorrectly reject 9223372036854775807. */ |
| 4469 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) |
| 4470 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 |
| 4471 | && LARGE_OFF_T % 2147483647 == 1) |
| 4472 | ? 1 : -1]; |
| 4473 | int |
| 4474 | main () |
| 4475 | { |
| 4476 | |
| 4477 | ; |
| 4478 | return 0; |
| 4479 | } |
| 4480 | _ACEOF |
| 4481 | if ac_fn_c_try_compile "$LINENO"; then : |
| 4482 | ac_cv_sys_large_files=1; break |
| 4483 | fi |
| 4484 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4485 | ac_cv_sys_large_files=unknown |
| 4486 | break |
| 4487 | done |
| 4488 | fi |
| 4489 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5 |
| 4490 | $as_echo "$ac_cv_sys_large_files" >&6; } |
| 4491 | case $ac_cv_sys_large_files in #( |
| 4492 | no | unknown) ;; |
| 4493 | *) |
| 4494 | cat >>confdefs.h <<_ACEOF |
| 4495 | #define _LARGE_FILES $ac_cv_sys_large_files |
| 4496 | _ACEOF |
| 4497 | ;; |
| 4498 | esac |
| 4499 | rm -rf conftest* |
| 4500 | fi |
| 4501 | |
| 4502 | |
| 4503 | fi |
| 4504 | |
| 4505 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5 |
| 4506 | $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; } |
| 4507 | if ${ac_cv_sys_largefile_source+:} false; then : |
| 4508 | $as_echo_n "(cached) " >&6 |
| 4509 | else |
| 4510 | while :; do |
| 4511 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4512 | /* end confdefs.h. */ |
| 4513 | #include <sys/types.h> /* for off_t */ |
| 4514 | #include <stdio.h> |
| 4515 | int |
| 4516 | main () |
| 4517 | { |
| 4518 | int (*fp) (FILE *, off_t, int) = fseeko; |
| 4519 | return fseeko (stdin, 0, 0) && fp (stdin, 0, 0); |
| 4520 | ; |
| 4521 | return 0; |
| 4522 | } |
| 4523 | _ACEOF |
| 4524 | if ac_fn_c_try_link "$LINENO"; then : |
| 4525 | ac_cv_sys_largefile_source=no; break |
| 4526 | fi |
| 4527 | rm -f core conftest.err conftest.$ac_objext \ |
| 4528 | conftest$ac_exeext conftest.$ac_ext |
| 4529 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4530 | /* end confdefs.h. */ |
| 4531 | #define _LARGEFILE_SOURCE 1 |
| 4532 | #include <sys/types.h> /* for off_t */ |
| 4533 | #include <stdio.h> |
| 4534 | int |
| 4535 | main () |
| 4536 | { |
| 4537 | int (*fp) (FILE *, off_t, int) = fseeko; |
| 4538 | return fseeko (stdin, 0, 0) && fp (stdin, 0, 0); |
| 4539 | ; |
| 4540 | return 0; |
| 4541 | } |
| 4542 | _ACEOF |
| 4543 | if ac_fn_c_try_link "$LINENO"; then : |
| 4544 | ac_cv_sys_largefile_source=1; break |
| 4545 | fi |
| 4546 | rm -f core conftest.err conftest.$ac_objext \ |
| 4547 | conftest$ac_exeext conftest.$ac_ext |
| 4548 | ac_cv_sys_largefile_source=unknown |
| 4549 | break |
| 4550 | done |
| 4551 | fi |
| 4552 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5 |
| 4553 | $as_echo "$ac_cv_sys_largefile_source" >&6; } |
| 4554 | case $ac_cv_sys_largefile_source in #( |
| 4555 | no | unknown) ;; |
| 4556 | *) |
| 4557 | cat >>confdefs.h <<_ACEOF |
| 4558 | #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source |
| 4559 | _ACEOF |
| 4560 | ;; |
| 4561 | esac |
| 4562 | rm -rf conftest* |
| 4563 | |
| 4564 | # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug |
| 4565 | # in glibc 2.1.3, but that breaks too many other things. |
| 4566 | # If you want fseeko and ftello with glibc, upgrade to a fixed glibc. |
| 4567 | if test $ac_cv_sys_largefile_source != unknown; then |
| 4568 | |
| 4569 | $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h |
| 4570 | |
| 4571 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4572 | |
| 4573 | |
| 4574 | for ac_header in sys/ioccom.h sys/sockio.h limits.h paths.h |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4575 | do : |
| 4576 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 4577 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" |
| 4578 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4579 | cat >>confdefs.h <<_ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4580 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4581 | _ACEOF |
| 4582 | |
| 4583 | fi |
| 4584 | |
| 4585 | done |
| 4586 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4587 | for ac_header in linux/types.h |
| 4588 | do : |
| 4589 | ac_fn_c_check_header_mongrel "$LINENO" "linux/types.h" "ac_cv_header_linux_types_h" "$ac_includes_default" |
| 4590 | if test "x$ac_cv_header_linux_types_h" = xyes; then : |
| 4591 | cat >>confdefs.h <<_ACEOF |
| 4592 | #define HAVE_LINUX_TYPES_H 1 |
| 4593 | _ACEOF |
| 4594 | |
| 4595 | fi |
| 4596 | |
| 4597 | done |
| 4598 | |
| 4599 | for ac_header in linux/if_packet.h netpacket/packet.h netpacket/if_packet.h |
| 4600 | do : |
| 4601 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 4602 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" |
| 4603 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
| 4604 | cat >>confdefs.h <<_ACEOF |
| 4605 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 4606 | _ACEOF |
| 4607 | |
| 4608 | fi |
| 4609 | |
| 4610 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4611 | |
| 4612 | for ac_header in net/pfvar.h |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4613 | do : |
| 4614 | ac_fn_c_check_header_compile "$LINENO" "net/pfvar.h" "ac_cv_header_net_pfvar_h" "#include <sys/types.h> |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4615 | #include <sys/socket.h> |
| 4616 | #include <net/if.h> |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4617 | " |
| 4618 | if test "x$ac_cv_header_net_pfvar_h" = xyes; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4619 | cat >>confdefs.h <<_ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4620 | #define HAVE_NET_PFVAR_H 1 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4621 | _ACEOF |
| 4622 | |
| 4623 | fi |
| 4624 | |
| 4625 | done |
| 4626 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4627 | if test "$ac_cv_header_net_pfvar_h" = yes; then |
| 4628 | # |
| 4629 | # Check for various PF actions. |
| 4630 | # |
| 4631 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether net/pfvar.h defines PF_NAT through PF_NORDR" >&5 |
| 4632 | $as_echo_n "checking whether net/pfvar.h defines PF_NAT through PF_NORDR... " >&6; } |
| 4633 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4634 | /* end confdefs.h. */ |
| 4635 | #include <sys/types.h> |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4636 | #include <sys/socket.h> |
| 4637 | #include <net/if.h> |
| 4638 | #include <net/pfvar.h> |
| 4639 | int |
| 4640 | main () |
| 4641 | { |
| 4642 | return PF_NAT+PF_NONAT+PF_BINAT+PF_NOBINAT+PF_RDR+PF_NORDR; |
| 4643 | ; |
| 4644 | return 0; |
| 4645 | } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4646 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4647 | if ac_fn_c_try_compile "$LINENO"; then : |
| 4648 | |
| 4649 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 4650 | $as_echo "yes" >&6; } |
| 4651 | |
| 4652 | $as_echo "#define HAVE_PF_NAT_THROUGH_PF_NORDR 1" >>confdefs.h |
| 4653 | |
| 4654 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4655 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4656 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4657 | $as_echo "no" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4658 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4659 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4660 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4661 | for ac_header in netinet/if_ether.h |
| 4662 | do : |
| 4663 | ac_fn_c_check_header_compile "$LINENO" "netinet/if_ether.h" "ac_cv_header_netinet_if_ether_h" "#include <sys/types.h> |
| 4664 | #include <sys/socket.h> |
| 4665 | " |
| 4666 | if test "x$ac_cv_header_netinet_if_ether_h" = xyes; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4667 | cat >>confdefs.h <<_ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4668 | #define HAVE_NETINET_IF_ETHER_H 1 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4669 | _ACEOF |
| 4670 | |
| 4671 | fi |
| 4672 | |
| 4673 | done |
| 4674 | |
| 4675 | if test "$ac_cv_header_netinet_if_ether_h" != yes; then |
| 4676 | # |
| 4677 | # The simple test didn't work. |
| 4678 | # Do we need to include <net/if.h> first? |
| 4679 | # Unset ac_cv_header_netinet_if_ether_h so we don't |
| 4680 | # treat the previous failure as a cached value and |
| 4681 | # suppress the next test. |
| 4682 | # |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4683 | { $as_echo "$as_me:${as_lineno-$LINENO}: Rechecking with some additional includes" >&5 |
| 4684 | $as_echo "$as_me: Rechecking with some additional includes" >&6;} |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4685 | unset ac_cv_header_netinet_if_ether_h |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4686 | for ac_header in netinet/if_ether.h |
| 4687 | do : |
| 4688 | ac_fn_c_check_header_compile "$LINENO" "netinet/if_ether.h" "ac_cv_header_netinet_if_ether_h" "#include <sys/types.h> |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4689 | #include <sys/socket.h> |
| 4690 | #include <netinet/in.h> |
| 4691 | struct mbuf; |
| 4692 | struct rtentry; |
| 4693 | #include <net/if.h> |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4694 | " |
| 4695 | if test "x$ac_cv_header_netinet_if_ether_h" = xyes; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4696 | cat >>confdefs.h <<_ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4697 | #define HAVE_NETINET_IF_ETHER_H 1 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4698 | _ACEOF |
| 4699 | |
| 4700 | fi |
| 4701 | |
| 4702 | done |
| 4703 | |
| 4704 | fi |
| 4705 | |
| 4706 | if test "$GCC" = yes ; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4707 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI ioctl definitions" >&5 |
| 4708 | $as_echo_n "checking for ANSI ioctl definitions... " >&6; } |
| 4709 | if ${ac_cv_lbl_gcc_fixincludes+:} false; then : |
| 4710 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4711 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4712 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4713 | /* end confdefs.h. */ |
| 4714 | /* |
| 4715 | * This generates a "duplicate case value" when fixincludes |
| 4716 | * has not be run. |
| 4717 | */ |
| 4718 | # include <sys/types.h> |
| 4719 | # include <sys/time.h> |
| 4720 | # include <sys/ioctl.h> |
| 4721 | # ifdef HAVE_SYS_IOCCOM_H |
| 4722 | # include <sys/ioccom.h> |
| 4723 | # endif |
| 4724 | int |
| 4725 | main () |
| 4726 | { |
| 4727 | switch (0) { |
| 4728 | case _IO('A', 1):; |
| 4729 | case _IO('B', 1):; |
| 4730 | } |
| 4731 | ; |
| 4732 | return 0; |
| 4733 | } |
| 4734 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4735 | if ac_fn_c_try_compile "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4736 | ac_cv_lbl_gcc_fixincludes=yes |
| 4737 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4738 | ac_cv_lbl_gcc_fixincludes=no |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4739 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4740 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4741 | fi |
| 4742 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4743 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_gcc_fixincludes" >&5 |
| 4744 | $as_echo "$ac_cv_lbl_gcc_fixincludes" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4745 | if test $ac_cv_lbl_gcc_fixincludes = no ; then |
| 4746 | # Don't cache failure |
| 4747 | unset ac_cv_lbl_gcc_fixincludes |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4748 | as_fn_error $? "see the INSTALL for more info" "$LINENO" 5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4749 | fi |
| 4750 | fi |
| 4751 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4752 | for ac_func in strerror strlcpy |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4753 | do : |
| 4754 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 4755 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
| 4756 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4757 | cat >>confdefs.h <<_ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4758 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4759 | _ACEOF |
| 4760 | |
| 4761 | fi |
| 4762 | done |
| 4763 | |
| 4764 | |
| 4765 | needsnprintf=no |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4766 | for ac_func in vsnprintf snprintf |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4767 | do : |
| 4768 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 4769 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
| 4770 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4771 | cat >>confdefs.h <<_ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4772 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4773 | _ACEOF |
| 4774 | |
| 4775 | else |
| 4776 | needsnprintf=yes |
| 4777 | fi |
| 4778 | done |
| 4779 | |
| 4780 | if test $needsnprintf = yes; then |
| 4781 | case " $LIBOBJS " in |
| 4782 | *" snprintf.$ac_objext "* ) ;; |
| 4783 | *) LIBOBJS="$LIBOBJS snprintf.$ac_objext" |
| 4784 | ;; |
| 4785 | esac |
| 4786 | |
| 4787 | fi |
| 4788 | |
| 4789 | # |
| 4790 | # Do this before checking for ether_hostton(), as it's a |
| 4791 | # "gethostbyname() -ish function". |
| 4792 | # |
| 4793 | |
| 4794 | # Most operating systems have gethostbyname() in the default searched |
| 4795 | # libraries (i.e. libc): |
| 4796 | # Some OSes (eg. Solaris) place it in libnsl |
| 4797 | # Some strange OSes (SINIX) have it in libsocket: |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4798 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostbyname" >&5 |
| 4799 | $as_echo_n "checking for library containing gethostbyname... " >&6; } |
| 4800 | if ${ac_cv_search_gethostbyname+:} false; then : |
| 4801 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4802 | else |
| 4803 | ac_func_search_save_LIBS=$LIBS |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4804 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4805 | /* end confdefs.h. */ |
| 4806 | |
| 4807 | /* Override any GCC internal prototype to avoid an error. |
| 4808 | Use char because int might match the return type of a GCC |
| 4809 | builtin and then its argument prototype would still apply. */ |
| 4810 | #ifdef __cplusplus |
| 4811 | extern "C" |
| 4812 | #endif |
| 4813 | char gethostbyname (); |
| 4814 | int |
| 4815 | main () |
| 4816 | { |
| 4817 | return gethostbyname (); |
| 4818 | ; |
| 4819 | return 0; |
| 4820 | } |
| 4821 | _ACEOF |
| 4822 | for ac_lib in '' nsl socket resolv; do |
| 4823 | if test -z "$ac_lib"; then |
| 4824 | ac_res="none required" |
| 4825 | else |
| 4826 | ac_res=-l$ac_lib |
| 4827 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
| 4828 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4829 | if ac_fn_c_try_link "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4830 | ac_cv_search_gethostbyname=$ac_res |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4831 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4832 | rm -f core conftest.err conftest.$ac_objext \ |
| 4833 | conftest$ac_exeext |
| 4834 | if ${ac_cv_search_gethostbyname+:} false; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4835 | break |
| 4836 | fi |
| 4837 | done |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4838 | if ${ac_cv_search_gethostbyname+:} false; then : |
| 4839 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4840 | else |
| 4841 | ac_cv_search_gethostbyname=no |
| 4842 | fi |
| 4843 | rm conftest.$ac_ext |
| 4844 | LIBS=$ac_func_search_save_LIBS |
| 4845 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4846 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostbyname" >&5 |
| 4847 | $as_echo "$ac_cv_search_gethostbyname" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4848 | ac_res=$ac_cv_search_gethostbyname |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4849 | if test "$ac_res" != no; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4850 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" |
| 4851 | |
| 4852 | fi |
| 4853 | |
| 4854 | # Unfortunately libsocket sometimes depends on libnsl and |
| 4855 | # AC_SEARCH_LIBS isn't up to the task of handling dependencies like this. |
| 4856 | if test "$ac_cv_search_gethostbyname" = "no" |
| 4857 | then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4858 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lsocket" >&5 |
| 4859 | $as_echo_n "checking for gethostbyname in -lsocket... " >&6; } |
| 4860 | if ${ac_cv_lib_socket_gethostbyname+:} false; then : |
| 4861 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4862 | else |
| 4863 | ac_check_lib_save_LIBS=$LIBS |
| 4864 | LIBS="-lsocket -lnsl $LIBS" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4865 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4866 | /* end confdefs.h. */ |
| 4867 | |
| 4868 | /* Override any GCC internal prototype to avoid an error. |
| 4869 | Use char because int might match the return type of a GCC |
| 4870 | builtin and then its argument prototype would still apply. */ |
| 4871 | #ifdef __cplusplus |
| 4872 | extern "C" |
| 4873 | #endif |
| 4874 | char gethostbyname (); |
| 4875 | int |
| 4876 | main () |
| 4877 | { |
| 4878 | return gethostbyname (); |
| 4879 | ; |
| 4880 | return 0; |
| 4881 | } |
| 4882 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4883 | if ac_fn_c_try_link "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4884 | ac_cv_lib_socket_gethostbyname=yes |
| 4885 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4886 | ac_cv_lib_socket_gethostbyname=no |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4887 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4888 | rm -f core conftest.err conftest.$ac_objext \ |
| 4889 | conftest$ac_exeext conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4890 | LIBS=$ac_check_lib_save_LIBS |
| 4891 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4892 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_gethostbyname" >&5 |
| 4893 | $as_echo "$ac_cv_lib_socket_gethostbyname" >&6; } |
| 4894 | if test "x$ac_cv_lib_socket_gethostbyname" = xyes; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4895 | LIBS="-lsocket -lnsl $LIBS" |
| 4896 | fi |
| 4897 | |
| 4898 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4899 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing socket" >&5 |
| 4900 | $as_echo_n "checking for library containing socket... " >&6; } |
| 4901 | if ${ac_cv_search_socket+:} false; then : |
| 4902 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4903 | else |
| 4904 | ac_func_search_save_LIBS=$LIBS |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4905 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4906 | /* end confdefs.h. */ |
| 4907 | |
| 4908 | /* Override any GCC internal prototype to avoid an error. |
| 4909 | Use char because int might match the return type of a GCC |
| 4910 | builtin and then its argument prototype would still apply. */ |
| 4911 | #ifdef __cplusplus |
| 4912 | extern "C" |
| 4913 | #endif |
| 4914 | char socket (); |
| 4915 | int |
| 4916 | main () |
| 4917 | { |
| 4918 | return socket (); |
| 4919 | ; |
| 4920 | return 0; |
| 4921 | } |
| 4922 | _ACEOF |
| 4923 | for ac_lib in '' socket; do |
| 4924 | if test -z "$ac_lib"; then |
| 4925 | ac_res="none required" |
| 4926 | else |
| 4927 | ac_res=-l$ac_lib |
| 4928 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
| 4929 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4930 | if ac_fn_c_try_link "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4931 | ac_cv_search_socket=$ac_res |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4932 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4933 | rm -f core conftest.err conftest.$ac_objext \ |
| 4934 | conftest$ac_exeext |
| 4935 | if ${ac_cv_search_socket+:} false; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4936 | break |
| 4937 | fi |
| 4938 | done |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4939 | if ${ac_cv_search_socket+:} false; then : |
| 4940 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4941 | else |
| 4942 | ac_cv_search_socket=no |
| 4943 | fi |
| 4944 | rm conftest.$ac_ext |
| 4945 | LIBS=$ac_func_search_save_LIBS |
| 4946 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4947 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socket" >&5 |
| 4948 | $as_echo "$ac_cv_search_socket" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4949 | ac_res=$ac_cv_search_socket |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4950 | if test "$ac_res" != no; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4951 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" |
| 4952 | |
| 4953 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4954 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socket in -lsocket" >&5 |
| 4955 | $as_echo_n "checking for socket in -lsocket... " >&6; } |
| 4956 | if ${ac_cv_lib_socket_socket+:} false; then : |
| 4957 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4958 | else |
| 4959 | ac_check_lib_save_LIBS=$LIBS |
| 4960 | LIBS="-lsocket -lnsl $LIBS" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4961 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4962 | /* end confdefs.h. */ |
| 4963 | |
| 4964 | /* Override any GCC internal prototype to avoid an error. |
| 4965 | Use char because int might match the return type of a GCC |
| 4966 | builtin and then its argument prototype would still apply. */ |
| 4967 | #ifdef __cplusplus |
| 4968 | extern "C" |
| 4969 | #endif |
| 4970 | char socket (); |
| 4971 | int |
| 4972 | main () |
| 4973 | { |
| 4974 | return socket (); |
| 4975 | ; |
| 4976 | return 0; |
| 4977 | } |
| 4978 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4979 | if ac_fn_c_try_link "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4980 | ac_cv_lib_socket_socket=yes |
| 4981 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4982 | ac_cv_lib_socket_socket=no |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4983 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4984 | rm -f core conftest.err conftest.$ac_objext \ |
| 4985 | conftest$ac_exeext conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4986 | LIBS=$ac_check_lib_save_LIBS |
| 4987 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4988 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_socket" >&5 |
| 4989 | $as_echo "$ac_cv_lib_socket_socket" >&6; } |
| 4990 | if test "x$ac_cv_lib_socket_socket" = xyes; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 4991 | LIBS="-lsocket -lnsl $LIBS" |
| 4992 | fi |
| 4993 | |
| 4994 | fi |
| 4995 | |
| 4996 | # DLPI needs putmsg under HPUX so test for -lstr while we're at it |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 4997 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing putmsg" >&5 |
| 4998 | $as_echo_n "checking for library containing putmsg... " >&6; } |
| 4999 | if ${ac_cv_search_putmsg+:} false; then : |
| 5000 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5001 | else |
| 5002 | ac_func_search_save_LIBS=$LIBS |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5003 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5004 | /* end confdefs.h. */ |
| 5005 | |
| 5006 | /* Override any GCC internal prototype to avoid an error. |
| 5007 | Use char because int might match the return type of a GCC |
| 5008 | builtin and then its argument prototype would still apply. */ |
| 5009 | #ifdef __cplusplus |
| 5010 | extern "C" |
| 5011 | #endif |
| 5012 | char putmsg (); |
| 5013 | int |
| 5014 | main () |
| 5015 | { |
| 5016 | return putmsg (); |
| 5017 | ; |
| 5018 | return 0; |
| 5019 | } |
| 5020 | _ACEOF |
| 5021 | for ac_lib in '' str; do |
| 5022 | if test -z "$ac_lib"; then |
| 5023 | ac_res="none required" |
| 5024 | else |
| 5025 | ac_res=-l$ac_lib |
| 5026 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
| 5027 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5028 | if ac_fn_c_try_link "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5029 | ac_cv_search_putmsg=$ac_res |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5030 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5031 | rm -f core conftest.err conftest.$ac_objext \ |
| 5032 | conftest$ac_exeext |
| 5033 | if ${ac_cv_search_putmsg+:} false; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5034 | break |
| 5035 | fi |
| 5036 | done |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5037 | if ${ac_cv_search_putmsg+:} false; then : |
| 5038 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5039 | else |
| 5040 | ac_cv_search_putmsg=no |
| 5041 | fi |
| 5042 | rm conftest.$ac_ext |
| 5043 | LIBS=$ac_func_search_save_LIBS |
| 5044 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5045 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_putmsg" >&5 |
| 5046 | $as_echo "$ac_cv_search_putmsg" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5047 | ac_res=$ac_cv_search_putmsg |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5048 | if test "$ac_res" != no; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5049 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" |
| 5050 | |
| 5051 | fi |
| 5052 | |
| 5053 | |
| 5054 | |
| 5055 | # |
| 5056 | # You are in a twisty little maze of UN*Xes, all different. |
| 5057 | # Some might not have ether_hostton(). |
| 5058 | # Some might have it, but not declare it in any header file. |
| 5059 | # Some might have it, but declare it in <netinet/if_ether.h>. |
| 5060 | # Some might have it, but declare it in <netinet/ether.h> |
| 5061 | # (And some might have it but document it as something declared in |
| 5062 | # <netinet/ethernet.h>, although <netinet/if_ether.h> appears to work.) |
| 5063 | # |
| 5064 | # Before you is a C compiler. |
| 5065 | # |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5066 | for ac_func in ether_hostton |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5067 | do : |
| 5068 | ac_fn_c_check_func "$LINENO" "ether_hostton" "ac_cv_func_ether_hostton" |
| 5069 | if test "x$ac_cv_func_ether_hostton" = xyes; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5070 | cat >>confdefs.h <<_ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5071 | #define HAVE_ETHER_HOSTTON 1 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5072 | _ACEOF |
| 5073 | |
| 5074 | fi |
| 5075 | done |
| 5076 | |
| 5077 | if test "$ac_cv_func_ether_hostton" = yes; then |
| 5078 | # |
| 5079 | # OK, we have ether_hostton(). Do we have <netinet/if_ether.h>? |
| 5080 | # |
| 5081 | if test "$ac_cv_header_netinet_if_ether_h" = yes; then |
| 5082 | # |
| 5083 | # Yes. Does it declare ether_hostton()? |
| 5084 | # |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5085 | ac_fn_c_check_decl "$LINENO" "ether_hostton" "ac_cv_have_decl_ether_hostton" " |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5086 | #include <sys/types.h> |
| 5087 | #include <sys/socket.h> |
| 5088 | #include <netinet/in.h> |
| 5089 | #include <arpa/inet.h> |
| 5090 | struct mbuf; |
| 5091 | struct rtentry; |
| 5092 | #include <net/if.h> |
| 5093 | #include <netinet/if_ether.h> |
| 5094 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5095 | " |
| 5096 | if test "x$ac_cv_have_decl_ether_hostton" = xyes; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5097 | |
| 5098 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5099 | $as_echo "#define NETINET_IF_ETHER_H_DECLARES_ETHER_HOSTTON /**/" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5100 | |
| 5101 | |
| 5102 | fi |
| 5103 | |
| 5104 | fi |
| 5105 | # |
| 5106 | # Did that succeed? |
| 5107 | # |
| 5108 | if test "$ac_cv_have_decl_ether_hostton" != yes; then |
| 5109 | # |
| 5110 | # No, how about <netinet/ether.h>, as on Linux? |
| 5111 | # |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5112 | for ac_header in netinet/ether.h |
| 5113 | do : |
| 5114 | ac_fn_c_check_header_mongrel "$LINENO" "netinet/ether.h" "ac_cv_header_netinet_ether_h" "$ac_includes_default" |
| 5115 | if test "x$ac_cv_header_netinet_ether_h" = xyes; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5116 | cat >>confdefs.h <<_ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5117 | #define HAVE_NETINET_ETHER_H 1 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5118 | _ACEOF |
| 5119 | |
| 5120 | fi |
| 5121 | |
| 5122 | done |
| 5123 | |
| 5124 | if test "$ac_cv_header_netinet_ether_h" = yes; then |
| 5125 | # |
| 5126 | # We have it - does it declare ether_hostton()? |
| 5127 | # Unset ac_cv_have_decl_ether_hostton so we don't |
| 5128 | # treat the previous failure as a cached value and |
| 5129 | # suppress the next test. |
| 5130 | # |
| 5131 | unset ac_cv_have_decl_ether_hostton |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5132 | ac_fn_c_check_decl "$LINENO" "ether_hostton" "ac_cv_have_decl_ether_hostton" " |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5133 | #include <netinet/ether.h> |
| 5134 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5135 | " |
| 5136 | if test "x$ac_cv_have_decl_ether_hostton" = xyes; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5137 | |
| 5138 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5139 | $as_echo "#define NETINET_ETHER_H_DECLARES_ETHER_HOSTTON /**/" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5140 | |
| 5141 | |
| 5142 | fi |
| 5143 | |
| 5144 | fi |
| 5145 | fi |
| 5146 | # |
| 5147 | # Is ether_hostton() declared? |
| 5148 | # |
| 5149 | if test "$ac_cv_have_decl_ether_hostton" != yes; then |
| 5150 | # |
| 5151 | # No, we'll have to declare it ourselves. |
| 5152 | # Do we have "struct ether_addr"? |
| 5153 | # |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5154 | ac_fn_c_check_type "$LINENO" "struct ether_addr" "ac_cv_type_struct_ether_addr" " |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5155 | #include <sys/types.h> |
| 5156 | #include <sys/socket.h> |
| 5157 | #include <netinet/in.h> |
| 5158 | #include <arpa/inet.h> |
| 5159 | struct mbuf; |
| 5160 | struct rtentry; |
| 5161 | #include <net/if.h> |
| 5162 | #include <netinet/if_ether.h> |
| 5163 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5164 | " |
| 5165 | if test "x$ac_cv_type_struct_ether_addr" = xyes; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5166 | |
| 5167 | cat >>confdefs.h <<_ACEOF |
| 5168 | #define HAVE_STRUCT_ETHER_ADDR 1 |
| 5169 | _ACEOF |
| 5170 | |
| 5171 | |
| 5172 | fi |
| 5173 | |
| 5174 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5175 | $as_echo "#define HAVE_DECL_ETHER_HOSTTON 0" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5176 | |
| 5177 | else |
| 5178 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5179 | $as_echo "#define HAVE_DECL_ETHER_HOSTTON 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5180 | |
| 5181 | fi |
| 5182 | fi |
| 5183 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5184 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if --disable-protochain option is specified" >&5 |
| 5185 | $as_echo_n "checking if --disable-protochain option is specified... " >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5186 | # Check whether --enable-protochain was given. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5187 | if test "${enable_protochain+set}" = set; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5188 | enableval=$enable_protochain; |
| 5189 | fi |
| 5190 | |
| 5191 | case "x$enable_protochain" in |
| 5192 | xyes) enable_protochain=enabled ;; |
| 5193 | xno) enable_protochain=disabled ;; |
| 5194 | x) enable_protochain=enabled ;; |
| 5195 | esac |
| 5196 | |
| 5197 | if test "$enable_protochain" = "disabled"; then |
| 5198 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5199 | $as_echo "#define NO_PROTOCHAIN 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5200 | |
| 5201 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5202 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${enable_protochain}" >&5 |
| 5203 | $as_echo "${enable_protochain}" >&6; } |
| 5204 | |
| 5205 | # |
| 5206 | # SITA support is mutually exclusive with native capture support; |
| 5207 | # "--with-sita" selects SITA support. |
| 5208 | # |
| 5209 | |
| 5210 | # Check whether --with-sita was given. |
| 5211 | if test "${with_sita+set}" = set; then : |
| 5212 | withval=$with_sita; |
| 5213 | if test ! "x$withval" = "xno" ; then |
| 5214 | |
| 5215 | $as_echo "#define SITA 1" >>confdefs.h |
| 5216 | |
| 5217 | { $as_echo "$as_me:${as_lineno-$LINENO}: Enabling SITA ACN support" >&5 |
| 5218 | $as_echo "$as_me: Enabling SITA ACN support" >&6;} |
| 5219 | V_PCAP=sita |
| 5220 | V_FINDALLDEVS=sita |
| 5221 | fi |
| 5222 | |
| 5223 | else |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5224 | |
| 5225 | if test -z "$with_pcap" && test "$cross_compiling" = yes; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5226 | as_fn_error $? "pcap type not determined when cross-compiling; use --with-pcap=..." "$LINENO" 5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5227 | fi |
| 5228 | |
| 5229 | # Check whether --with-pcap was given. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5230 | if test "${with_pcap+set}" = set; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5231 | withval=$with_pcap; |
| 5232 | fi |
| 5233 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5234 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking packet capture type" >&5 |
| 5235 | $as_echo_n "checking packet capture type... " >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5236 | if test ! -z "$with_pcap" ; then |
| 5237 | V_PCAP="$withval" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5238 | elif test -r /dev/bpf -o -h /dev/bpf ; then |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5239 | # |
| 5240 | # Cloning BPF device. |
| 5241 | # |
| 5242 | V_PCAP=bpf |
| 5243 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5244 | $as_echo "#define HAVE_CLONING_BPF 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5245 | |
| 5246 | elif test -r /dev/bpf0 ; then |
| 5247 | V_PCAP=bpf |
| 5248 | elif test -r /usr/include/net/pfilt.h ; then |
| 5249 | V_PCAP=pf |
| 5250 | elif test -r /dev/enet ; then |
| 5251 | V_PCAP=enet |
| 5252 | elif test -r /dev/nit ; then |
| 5253 | V_PCAP=snit |
| 5254 | elif test -r /usr/include/sys/net/nit.h ; then |
| 5255 | V_PCAP=nit |
| 5256 | elif test -r /usr/include/linux/socket.h ; then |
| 5257 | V_PCAP=linux |
| 5258 | elif test -r /usr/include/net/raw.h ; then |
| 5259 | V_PCAP=snoop |
| 5260 | elif test -r /usr/include/odmi.h ; then |
| 5261 | # |
| 5262 | # On AIX, the BPF devices might not yet be present - they're |
| 5263 | # created the first time libpcap runs after booting. |
| 5264 | # We check for odmi.h instead. |
| 5265 | # |
| 5266 | V_PCAP=bpf |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5267 | elif test -c /dev/bpf0 ; then # check again in case not readable |
| 5268 | V_PCAP=bpf |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5269 | elif test -r /usr/include/sys/dlpi.h ; then |
| 5270 | V_PCAP=dlpi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5271 | elif test -c /dev/enet ; then # check again in case not readable |
| 5272 | V_PCAP=enet |
| 5273 | elif test -c /dev/nit ; then # check again in case not readable |
| 5274 | V_PCAP=snit |
| 5275 | else |
| 5276 | V_PCAP=null |
| 5277 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5278 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $V_PCAP" >&5 |
| 5279 | $as_echo "$V_PCAP" >&6; } |
| 5280 | |
| 5281 | # |
| 5282 | # Do capture-mechanism-dependent tests. |
| 5283 | # |
| 5284 | case "$V_PCAP" in |
| 5285 | dlpi) |
| 5286 | # |
| 5287 | # Needed for common functions used by pcap-[dlpi,libdlpi].c |
| 5288 | # |
| 5289 | SSRC="dlpisubs.c" |
| 5290 | |
| 5291 | # |
| 5292 | # Checks for some header files. |
| 5293 | # |
| 5294 | for ac_header in sys/bufmod.h sys/dlpi_ext.h |
| 5295 | do : |
| 5296 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 5297 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" |
| 5298 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
| 5299 | cat >>confdefs.h <<_ACEOF |
| 5300 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 5301 | _ACEOF |
| 5302 | |
| 5303 | fi |
| 5304 | |
| 5305 | done |
| 5306 | |
| 5307 | |
| 5308 | # |
| 5309 | # Checks to see if Solaris has the public libdlpi(3LIB) library. |
| 5310 | # Note: The existence of /usr/include/libdlpi.h does not mean it is the |
| 5311 | # public libdlpi(3LIB) version. Before libdlpi was made public, a |
| 5312 | # private version also existed, which did not have the same APIs. |
| 5313 | # Due to a gcc bug, the default search path for 32-bit libraries does |
| 5314 | # not include /lib, we add it explicitly here. |
| 5315 | # [http://bugs.opensolaris.org/view_bug.do?bug_id=6619485]. |
| 5316 | # Also, due to the bug above applications that link to libpcap with |
| 5317 | # libdlpi will have to add "-L/lib" option to "configure". |
| 5318 | # |
| 5319 | saved_ldflags=$LDFLAGS |
| 5320 | LDFLAGS="$LIBS -L/lib" |
| 5321 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlpi_walk in -ldlpi" >&5 |
| 5322 | $as_echo_n "checking for dlpi_walk in -ldlpi... " >&6; } |
| 5323 | if ${ac_cv_lib_dlpi_dlpi_walk+:} false; then : |
| 5324 | $as_echo_n "(cached) " >&6 |
| 5325 | else |
| 5326 | ac_check_lib_save_LIBS=$LIBS |
| 5327 | LIBS="-ldlpi $LIBS" |
| 5328 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 5329 | /* end confdefs.h. */ |
| 5330 | |
| 5331 | /* Override any GCC internal prototype to avoid an error. |
| 5332 | Use char because int might match the return type of a GCC |
| 5333 | builtin and then its argument prototype would still apply. */ |
| 5334 | #ifdef __cplusplus |
| 5335 | extern "C" |
| 5336 | #endif |
| 5337 | char dlpi_walk (); |
| 5338 | int |
| 5339 | main () |
| 5340 | { |
| 5341 | return dlpi_walk (); |
| 5342 | ; |
| 5343 | return 0; |
| 5344 | } |
| 5345 | _ACEOF |
| 5346 | if ac_fn_c_try_link "$LINENO"; then : |
| 5347 | ac_cv_lib_dlpi_dlpi_walk=yes |
| 5348 | else |
| 5349 | ac_cv_lib_dlpi_dlpi_walk=no |
| 5350 | fi |
| 5351 | rm -f core conftest.err conftest.$ac_objext \ |
| 5352 | conftest$ac_exeext conftest.$ac_ext |
| 5353 | LIBS=$ac_check_lib_save_LIBS |
| 5354 | fi |
| 5355 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dlpi_dlpi_walk" >&5 |
| 5356 | $as_echo "$ac_cv_lib_dlpi_dlpi_walk" >&6; } |
| 5357 | if test "x$ac_cv_lib_dlpi_dlpi_walk" = xyes; then : |
| 5358 | |
| 5359 | LIBS="-ldlpi $LIBS" |
| 5360 | V_PCAP=libdlpi |
| 5361 | |
| 5362 | $as_echo "#define HAVE_LIBDLPI 1" >>confdefs.h |
| 5363 | |
| 5364 | |
| 5365 | else |
| 5366 | V_PCAP=dlpi |
| 5367 | fi |
| 5368 | |
| 5369 | LDFLAGS=$saved_ldflags |
| 5370 | |
| 5371 | # |
| 5372 | # Checks whether <sys/dlpi.h> is usable, to catch weird SCO |
| 5373 | # versions of DLPI. |
| 5374 | # |
| 5375 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/dlpi.h> is usable" >&5 |
| 5376 | $as_echo_n "checking whether <sys/dlpi.h> is usable... " >&6; } |
| 5377 | if ${ac_cv_sys_dlpi_usable+:} false; then : |
| 5378 | $as_echo_n "(cached) " >&6 |
| 5379 | else |
| 5380 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 5381 | /* end confdefs.h. */ |
| 5382 | |
| 5383 | #include <sys/types.h> |
| 5384 | #include <sys/time.h> |
| 5385 | #include <sys/dlpi.h> |
| 5386 | |
| 5387 | int |
| 5388 | main () |
| 5389 | { |
| 5390 | int i = DL_PROMISC_PHYS; |
| 5391 | ; |
| 5392 | return 0; |
| 5393 | } |
| 5394 | _ACEOF |
| 5395 | if ac_fn_c_try_compile "$LINENO"; then : |
| 5396 | ac_cv_sys_dlpi_usable=yes |
| 5397 | else |
| 5398 | ac_cv_sys_dlpi_usable=no |
| 5399 | fi |
| 5400 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 5401 | fi |
| 5402 | |
| 5403 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_dlpi_usable" >&5 |
| 5404 | $as_echo "$ac_cv_sys_dlpi_usable" >&6; } |
| 5405 | if test $ac_cv_sys_dlpi_usable = no ; then |
| 5406 | as_fn_error $? "<sys/dlpi.h> is not usable on this system; it probably has a non-standard DLPI" "$LINENO" 5 |
| 5407 | fi |
| 5408 | |
| 5409 | # |
| 5410 | # Check whether we have a /dev/dlpi device or have multiple devices. |
| 5411 | # |
| 5412 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/dlpi device" >&5 |
| 5413 | $as_echo_n "checking for /dev/dlpi device... " >&6; } |
| 5414 | if test -c /dev/dlpi ; then |
| 5415 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 5416 | $as_echo "yes" >&6; } |
| 5417 | |
| 5418 | $as_echo "#define HAVE_DEV_DLPI 1" >>confdefs.h |
| 5419 | |
| 5420 | else |
| 5421 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5422 | $as_echo "no" >&6; } |
| 5423 | dir="/dev/dlpi" |
| 5424 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $dir directory" >&5 |
| 5425 | $as_echo_n "checking for $dir directory... " >&6; } |
| 5426 | if test -d $dir ; then |
| 5427 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 5428 | $as_echo "yes" >&6; } |
| 5429 | |
| 5430 | cat >>confdefs.h <<_ACEOF |
| 5431 | #define PCAP_DEV_PREFIX "$dir" |
| 5432 | _ACEOF |
| 5433 | |
| 5434 | else |
| 5435 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5436 | $as_echo "no" >&6; } |
| 5437 | fi |
| 5438 | fi |
| 5439 | |
| 5440 | # |
| 5441 | # This check is for Solaris with DLPI support for passive modes. |
| 5442 | # See dlpi(7P) for more details. |
| 5443 | # |
| 5444 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dl_passive_req_t struct exists" >&5 |
| 5445 | $as_echo_n "checking if dl_passive_req_t struct exists... " >&6; } |
| 5446 | if ${ac_cv_lbl_has_dl_passive_req_t+:} false; then : |
| 5447 | $as_echo_n "(cached) " >&6 |
| 5448 | else |
| 5449 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 5450 | /* end confdefs.h. */ |
| 5451 | |
| 5452 | # include <sys/types.h> |
| 5453 | # include <sys/dlpi.h> |
| 5454 | int |
| 5455 | main () |
| 5456 | { |
| 5457 | u_int i = sizeof(dl_passive_req_t) |
| 5458 | ; |
| 5459 | return 0; |
| 5460 | } |
| 5461 | _ACEOF |
| 5462 | if ac_fn_c_try_compile "$LINENO"; then : |
| 5463 | ac_cv_lbl_has_dl_passive_req_t=yes |
| 5464 | else |
| 5465 | ac_cv_lbl_has_dl_passive_req_t=no |
| 5466 | fi |
| 5467 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 5468 | fi |
| 5469 | |
| 5470 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_has_dl_passive_req_t" >&5 |
| 5471 | $as_echo "$ac_cv_lbl_has_dl_passive_req_t" >&6; } |
| 5472 | if test $ac_cv_lbl_has_dl_passive_req_t = yes ; then |
| 5473 | |
| 5474 | $as_echo "#define HAVE_DLPI_PASSIVE 1" >>confdefs.h |
| 5475 | |
| 5476 | fi |
| 5477 | ;; |
| 5478 | |
| 5479 | linux) |
| 5480 | # |
| 5481 | # Do we have the wireless extensions? |
| 5482 | # |
| 5483 | for ac_header in linux/wireless.h |
| 5484 | do : |
| 5485 | ac_fn_c_check_header_compile "$LINENO" "linux/wireless.h" "ac_cv_header_linux_wireless_h" " |
| 5486 | #include <sys/socket.h> |
| 5487 | #include <linux/if.h> |
| 5488 | #include <linux/types.h> |
| 5489 | |
| 5490 | " |
| 5491 | if test "x$ac_cv_header_linux_wireless_h" = xyes; then : |
| 5492 | cat >>confdefs.h <<_ACEOF |
| 5493 | #define HAVE_LINUX_WIRELESS_H 1 |
| 5494 | _ACEOF |
| 5495 | |
| 5496 | fi |
| 5497 | |
| 5498 | done |
| 5499 | |
| 5500 | |
| 5501 | # |
| 5502 | # Do we have libnl? |
| 5503 | # |
| 5504 | |
| 5505 | # Check whether --with-libnl was given. |
| 5506 | if test "${with_libnl+set}" = set; then : |
| 5507 | withval=$with_libnl; with_libnl=$withval |
| 5508 | fi |
| 5509 | |
| 5510 | |
| 5511 | if test x$with_libnl != xno ; then |
| 5512 | have_any_nl="no" |
| 5513 | |
| 5514 | # |
| 5515 | # Try libnl 3.x first. |
| 5516 | # |
| 5517 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_socket_alloc in -lnl-3" >&5 |
| 5518 | $as_echo_n "checking for nl_socket_alloc in -lnl-3... " >&6; } |
| 5519 | if ${ac_cv_lib_nl_3_nl_socket_alloc+:} false; then : |
| 5520 | $as_echo_n "(cached) " >&6 |
| 5521 | else |
| 5522 | ac_check_lib_save_LIBS=$LIBS |
| 5523 | LIBS="-lnl-3 $LIBS" |
| 5524 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 5525 | /* end confdefs.h. */ |
| 5526 | |
| 5527 | /* Override any GCC internal prototype to avoid an error. |
| 5528 | Use char because int might match the return type of a GCC |
| 5529 | builtin and then its argument prototype would still apply. */ |
| 5530 | #ifdef __cplusplus |
| 5531 | extern "C" |
| 5532 | #endif |
| 5533 | char nl_socket_alloc (); |
| 5534 | int |
| 5535 | main () |
| 5536 | { |
| 5537 | return nl_socket_alloc (); |
| 5538 | ; |
| 5539 | return 0; |
| 5540 | } |
| 5541 | _ACEOF |
| 5542 | if ac_fn_c_try_link "$LINENO"; then : |
| 5543 | ac_cv_lib_nl_3_nl_socket_alloc=yes |
| 5544 | else |
| 5545 | ac_cv_lib_nl_3_nl_socket_alloc=no |
| 5546 | fi |
| 5547 | rm -f core conftest.err conftest.$ac_objext \ |
| 5548 | conftest$ac_exeext conftest.$ac_ext |
| 5549 | LIBS=$ac_check_lib_save_LIBS |
| 5550 | fi |
| 5551 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nl_3_nl_socket_alloc" >&5 |
| 5552 | $as_echo "$ac_cv_lib_nl_3_nl_socket_alloc" >&6; } |
| 5553 | if test "x$ac_cv_lib_nl_3_nl_socket_alloc" = xyes; then : |
| 5554 | |
| 5555 | # |
| 5556 | # Yes, we have libnl 3.x. |
| 5557 | # |
| 5558 | LIBS="-lnl-genl-3 -lnl-3 $LIBS" |
| 5559 | |
| 5560 | $as_echo "#define HAVE_LIBNL 1" >>confdefs.h |
| 5561 | |
| 5562 | |
| 5563 | $as_echo "#define HAVE_LIBNL_3_x 1" >>confdefs.h |
| 5564 | |
| 5565 | |
| 5566 | $as_echo "#define HAVE_LIBNL_NLE 1" >>confdefs.h |
| 5567 | |
| 5568 | |
| 5569 | $as_echo "#define HAVE_LIBNL_SOCKETS 1" >>confdefs.h |
| 5570 | |
| 5571 | V_INCLS="$V_INCLS -I/usr/include/libnl3" |
| 5572 | have_any_nl="yes" |
| 5573 | |
| 5574 | fi |
| 5575 | |
| 5576 | |
| 5577 | if test x$have_any_nl = xno ; then |
| 5578 | # |
| 5579 | # Try libnl 2.x |
| 5580 | # |
| 5581 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_socket_alloc in -lnl" >&5 |
| 5582 | $as_echo_n "checking for nl_socket_alloc in -lnl... " >&6; } |
| 5583 | if ${ac_cv_lib_nl_nl_socket_alloc+:} false; then : |
| 5584 | $as_echo_n "(cached) " >&6 |
| 5585 | else |
| 5586 | ac_check_lib_save_LIBS=$LIBS |
| 5587 | LIBS="-lnl $LIBS" |
| 5588 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 5589 | /* end confdefs.h. */ |
| 5590 | |
| 5591 | /* Override any GCC internal prototype to avoid an error. |
| 5592 | Use char because int might match the return type of a GCC |
| 5593 | builtin and then its argument prototype would still apply. */ |
| 5594 | #ifdef __cplusplus |
| 5595 | extern "C" |
| 5596 | #endif |
| 5597 | char nl_socket_alloc (); |
| 5598 | int |
| 5599 | main () |
| 5600 | { |
| 5601 | return nl_socket_alloc (); |
| 5602 | ; |
| 5603 | return 0; |
| 5604 | } |
| 5605 | _ACEOF |
| 5606 | if ac_fn_c_try_link "$LINENO"; then : |
| 5607 | ac_cv_lib_nl_nl_socket_alloc=yes |
| 5608 | else |
| 5609 | ac_cv_lib_nl_nl_socket_alloc=no |
| 5610 | fi |
| 5611 | rm -f core conftest.err conftest.$ac_objext \ |
| 5612 | conftest$ac_exeext conftest.$ac_ext |
| 5613 | LIBS=$ac_check_lib_save_LIBS |
| 5614 | fi |
| 5615 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nl_nl_socket_alloc" >&5 |
| 5616 | $as_echo "$ac_cv_lib_nl_nl_socket_alloc" >&6; } |
| 5617 | if test "x$ac_cv_lib_nl_nl_socket_alloc" = xyes; then : |
| 5618 | |
| 5619 | # |
| 5620 | # Yes, we have libnl 2.x. |
| 5621 | # |
| 5622 | LIBS="-lnl-genl -lnl $LIBS" |
| 5623 | |
| 5624 | $as_echo "#define HAVE_LIBNL 1" >>confdefs.h |
| 5625 | |
| 5626 | |
| 5627 | $as_echo "#define HAVE_LIBNL_2_x 1" >>confdefs.h |
| 5628 | |
| 5629 | |
| 5630 | $as_echo "#define HAVE_LIBNL_NLE 1" >>confdefs.h |
| 5631 | |
| 5632 | |
| 5633 | $as_echo "#define HAVE_LIBNL_SOCKETS 1" >>confdefs.h |
| 5634 | |
| 5635 | have_any_nl="yes" |
| 5636 | |
| 5637 | fi |
| 5638 | |
| 5639 | fi |
| 5640 | |
| 5641 | if test x$have_any_nl = xno ; then |
| 5642 | # |
| 5643 | # No, we don't; do we have libnl 1.x? |
| 5644 | # |
| 5645 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_handle_alloc in -lnl" >&5 |
| 5646 | $as_echo_n "checking for nl_handle_alloc in -lnl... " >&6; } |
| 5647 | if ${ac_cv_lib_nl_nl_handle_alloc+:} false; then : |
| 5648 | $as_echo_n "(cached) " >&6 |
| 5649 | else |
| 5650 | ac_check_lib_save_LIBS=$LIBS |
| 5651 | LIBS="-lnl $LIBS" |
| 5652 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 5653 | /* end confdefs.h. */ |
| 5654 | |
| 5655 | /* Override any GCC internal prototype to avoid an error. |
| 5656 | Use char because int might match the return type of a GCC |
| 5657 | builtin and then its argument prototype would still apply. */ |
| 5658 | #ifdef __cplusplus |
| 5659 | extern "C" |
| 5660 | #endif |
| 5661 | char nl_handle_alloc (); |
| 5662 | int |
| 5663 | main () |
| 5664 | { |
| 5665 | return nl_handle_alloc (); |
| 5666 | ; |
| 5667 | return 0; |
| 5668 | } |
| 5669 | _ACEOF |
| 5670 | if ac_fn_c_try_link "$LINENO"; then : |
| 5671 | ac_cv_lib_nl_nl_handle_alloc=yes |
| 5672 | else |
| 5673 | ac_cv_lib_nl_nl_handle_alloc=no |
| 5674 | fi |
| 5675 | rm -f core conftest.err conftest.$ac_objext \ |
| 5676 | conftest$ac_exeext conftest.$ac_ext |
| 5677 | LIBS=$ac_check_lib_save_LIBS |
| 5678 | fi |
| 5679 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nl_nl_handle_alloc" >&5 |
| 5680 | $as_echo "$ac_cv_lib_nl_nl_handle_alloc" >&6; } |
| 5681 | if test "x$ac_cv_lib_nl_nl_handle_alloc" = xyes; then : |
| 5682 | |
| 5683 | # |
| 5684 | # Yes. |
| 5685 | # |
| 5686 | LIBS="-lnl $LIBS" |
| 5687 | |
| 5688 | $as_echo "#define HAVE_LIBNL 1" >>confdefs.h |
| 5689 | |
| 5690 | have_any_nl="yes" |
| 5691 | |
| 5692 | fi |
| 5693 | |
| 5694 | fi |
| 5695 | |
| 5696 | if test x$have_any_nl = xno ; then |
| 5697 | # |
| 5698 | # No, we don't have libnl at all. |
| 5699 | # |
| 5700 | if test x$with_libnl = xyes ; then |
| 5701 | as_fn_error $? "libnl support requested but libnl not found" "$LINENO" 5 |
| 5702 | fi |
| 5703 | fi |
| 5704 | fi |
| 5705 | |
| 5706 | for ac_header in linux/ethtool.h |
| 5707 | do : |
| 5708 | ac_fn_c_check_header_compile "$LINENO" "linux/ethtool.h" "ac_cv_header_linux_ethtool_h" " |
| 5709 | $ac_includes_default |
| 5710 | #include <linux/types.h> |
| 5711 | |
| 5712 | " |
| 5713 | if test "x$ac_cv_header_linux_ethtool_h" = xyes; then : |
| 5714 | cat >>confdefs.h <<_ACEOF |
| 5715 | #define HAVE_LINUX_ETHTOOL_H 1 |
| 5716 | _ACEOF |
| 5717 | |
| 5718 | fi |
| 5719 | |
| 5720 | done |
| 5721 | |
| 5722 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if if_packet.h has tpacket_stats defined" >&5 |
| 5723 | $as_echo_n "checking if if_packet.h has tpacket_stats defined... " >&6; } |
| 5724 | if ${ac_cv_lbl_tpacket_stats+:} false; then : |
| 5725 | $as_echo_n "(cached) " >&6 |
| 5726 | else |
| 5727 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 5728 | /* end confdefs.h. */ |
| 5729 | |
| 5730 | # include <linux/if_packet.h> |
| 5731 | int |
| 5732 | main () |
| 5733 | { |
| 5734 | struct tpacket_stats stats |
| 5735 | ; |
| 5736 | return 0; |
| 5737 | } |
| 5738 | _ACEOF |
| 5739 | if ac_fn_c_try_compile "$LINENO"; then : |
| 5740 | ac_cv_lbl_tpacket_stats=yes |
| 5741 | else |
| 5742 | ac_cv_lbl_tpacket_stats=no |
| 5743 | fi |
| 5744 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 5745 | fi |
| 5746 | |
| 5747 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_tpacket_stats" >&5 |
| 5748 | $as_echo "$ac_cv_lbl_tpacket_stats" >&6; } |
| 5749 | if test $ac_cv_lbl_tpacket_stats = yes; then |
| 5750 | |
| 5751 | $as_echo "#define HAVE_TPACKET_STATS 1" >>confdefs.h |
| 5752 | |
| 5753 | fi |
| 5754 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if tpacket_auxdata struct has tp_vlan_tci member" >&5 |
| 5755 | $as_echo_n "checking if tpacket_auxdata struct has tp_vlan_tci member... " >&6; } |
| 5756 | if ${ac_cv_lbl_linux_tpacket_auxdata_tp_vlan_tci+:} false; then : |
| 5757 | $as_echo_n "(cached) " >&6 |
| 5758 | else |
| 5759 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 5760 | /* end confdefs.h. */ |
| 5761 | |
| 5762 | # include <sys/types.h> |
| 5763 | # include <linux/if_packet.h> |
| 5764 | int |
| 5765 | main () |
| 5766 | { |
| 5767 | u_int i = sizeof(((struct tpacket_auxdata *)0)->tp_vlan_tci) |
| 5768 | ; |
| 5769 | return 0; |
| 5770 | } |
| 5771 | _ACEOF |
| 5772 | if ac_fn_c_try_compile "$LINENO"; then : |
| 5773 | ac_cv_lbl_linux_tpacket_auxdata_tp_vlan_tci=yes |
| 5774 | else |
| 5775 | ac_cv_lbl_linux_tpacket_auxdata_tp_vlan_tci=no |
| 5776 | fi |
| 5777 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 5778 | fi |
| 5779 | |
| 5780 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_linux_tpacket_auxdata_tp_vlan_tci" >&5 |
| 5781 | $as_echo "$ac_cv_lbl_linux_tpacket_auxdata_tp_vlan_tci" >&6; } |
| 5782 | if test $ac_cv_lbl_linux_tpacket_auxdata_tp_vlan_tci = yes ; then |
| 5783 | HAVE_LINUX_TPACKET_AUXDATA=tp_vlan_tci |
| 5784 | |
| 5785 | |
| 5786 | $as_echo "#define HAVE_LINUX_TPACKET_AUXDATA_TP_VLAN_TCI 1" >>confdefs.h |
| 5787 | |
| 5788 | fi |
| 5789 | ;; |
| 5790 | |
| 5791 | bpf) |
| 5792 | # |
| 5793 | # Check whether we have the *BSD-style ioctls. |
| 5794 | # |
| 5795 | for ac_header in net/if_media.h |
| 5796 | do : |
| 5797 | ac_fn_c_check_header_mongrel "$LINENO" "net/if_media.h" "ac_cv_header_net_if_media_h" "$ac_includes_default" |
| 5798 | if test "x$ac_cv_header_net_if_media_h" = xyes; then : |
| 5799 | cat >>confdefs.h <<_ACEOF |
| 5800 | #define HAVE_NET_IF_MEDIA_H 1 |
| 5801 | _ACEOF |
| 5802 | |
| 5803 | fi |
| 5804 | |
| 5805 | done |
| 5806 | |
| 5807 | |
| 5808 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the system supports zerocopy BPF" >&5 |
| 5809 | $as_echo_n "checking whether the system supports zerocopy BPF... " >&6; } |
| 5810 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 5811 | /* end confdefs.h. */ |
| 5812 | #include <sys/socket.h> |
| 5813 | #include <sys/ioctl.h> |
| 5814 | #include <net/if.h> |
| 5815 | #include <net/bpf.h> |
| 5816 | int |
| 5817 | main () |
| 5818 | { |
| 5819 | return (BIOCROTZBUF + BPF_BUFMODE_ZBUF); |
| 5820 | ; |
| 5821 | return 0; |
| 5822 | } |
| 5823 | _ACEOF |
| 5824 | if ac_fn_c_try_compile "$LINENO"; then : |
| 5825 | |
| 5826 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 5827 | $as_echo "yes" >&6; } |
| 5828 | |
| 5829 | $as_echo "#define HAVE_ZEROCOPY_BPF 1" >>confdefs.h |
| 5830 | |
| 5831 | |
| 5832 | else |
| 5833 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5834 | $as_echo "no" >&6; } |
| 5835 | fi |
| 5836 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 5837 | |
| 5838 | # |
| 5839 | # Check whether we have struct BPF_TIMEVAL. |
| 5840 | # |
| 5841 | ac_fn_c_check_type "$LINENO" "struct BPF_TIMEVAL" "ac_cv_type_struct_BPF_TIMEVAL" " |
| 5842 | #include <sys/types.h> |
| 5843 | #include <sys/ioctl.h> |
| 5844 | #ifdef HAVE_SYS_IOCCOM_H |
| 5845 | #include <sys/ioccom.h> |
| 5846 | #endif |
| 5847 | #include <net/bpf.h> |
| 5848 | |
| 5849 | " |
| 5850 | if test "x$ac_cv_type_struct_BPF_TIMEVAL" = xyes; then : |
| 5851 | |
| 5852 | cat >>confdefs.h <<_ACEOF |
| 5853 | #define HAVE_STRUCT_BPF_TIMEVAL 1 |
| 5854 | _ACEOF |
| 5855 | |
| 5856 | |
| 5857 | fi |
| 5858 | |
| 5859 | ;; |
| 5860 | |
| 5861 | dag) |
| 5862 | V_DEFS="$V_DEFS -DDAG_ONLY" |
| 5863 | ;; |
| 5864 | |
| 5865 | septel) |
| 5866 | V_DEFS="$V_DEFS -DSEPTEL_ONLY" |
| 5867 | ;; |
| 5868 | |
| 5869 | snf) |
| 5870 | V_DEFS="$V_DEFS -DSNF_ONLY" |
| 5871 | ;; |
| 5872 | |
| 5873 | null) |
| 5874 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot determine packet capture interface" >&5 |
| 5875 | $as_echo "$as_me: WARNING: cannot determine packet capture interface" >&2;} |
| 5876 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: (see the INSTALL doc for more info)" >&5 |
| 5877 | $as_echo "$as_me: WARNING: (see the INSTALL doc for more info)" >&2;} |
| 5878 | ;; |
| 5879 | esac |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5880 | |
| 5881 | if test "$V_PCAP" = null |
| 5882 | then |
| 5883 | # |
| 5884 | # We can't capture, so we can't open any capture |
| 5885 | # devices, so we won't return any interfaces. |
| 5886 | # |
| 5887 | V_FINDALLDEVS=null |
| 5888 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5889 | ac_fn_c_check_func "$LINENO" "getifaddrs" "ac_cv_func_getifaddrs" |
| 5890 | if test "x$ac_cv_func_getifaddrs" = xyes; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5891 | |
| 5892 | # |
| 5893 | # We have "getifaddrs()"; make sure we have <ifaddrs.h> |
| 5894 | # as well, just in case some platform is really weird. |
| 5895 | # |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5896 | ac_fn_c_check_header_mongrel "$LINENO" "ifaddrs.h" "ac_cv_header_ifaddrs_h" "$ac_includes_default" |
| 5897 | if test "x$ac_cv_header_ifaddrs_h" = xyes; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5898 | |
| 5899 | # |
| 5900 | # We have the header, so we use "getifaddrs()" to |
| 5901 | # get the list of interfaces. |
| 5902 | # |
| 5903 | V_FINDALLDEVS=getad |
| 5904 | |
| 5905 | else |
| 5906 | |
| 5907 | # |
| 5908 | # We don't have the header - give up. |
| 5909 | # XXX - we could also fall back on some other |
| 5910 | # mechanism, but, for now, this'll catch this |
| 5911 | # problem so that we can at least try to figure |
| 5912 | # out something to do on systems with "getifaddrs()" |
| 5913 | # but without "ifaddrs.h", if there is something |
| 5914 | # we can do on those systems. |
| 5915 | # |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5916 | as_fn_error $? "Your system has getifaddrs() but doesn't have a usable <ifaddrs.h>." "$LINENO" 5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5917 | |
| 5918 | fi |
| 5919 | |
| 5920 | |
| 5921 | |
| 5922 | else |
| 5923 | |
| 5924 | # |
| 5925 | # Well, we don't have "getifaddrs()", so we have to use |
| 5926 | # some other mechanism; determine what that mechanism is. |
| 5927 | # |
| 5928 | # The first thing we use is the type of capture mechanism, |
| 5929 | # which is somewhat of a proxy for the OS we're using. |
| 5930 | # |
| 5931 | case "$V_PCAP" in |
| 5932 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5933 | dlpi|libdlpi) |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5934 | # |
| 5935 | # This might be Solaris 8 or later, with |
| 5936 | # SIOCGLIFCONF, or it might be some other OS |
| 5937 | # or some older version of Solaris, with |
| 5938 | # just SIOCGIFCONF. |
| 5939 | # |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5940 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we have SIOCGLIFCONF" >&5 |
| 5941 | $as_echo_n "checking whether we have SIOCGLIFCONF... " >&6; } |
| 5942 | if ${ac_cv_lbl_have_siocglifconf+:} false; then : |
| 5943 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5944 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5945 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5946 | /* end confdefs.h. */ |
| 5947 | #include <sys/param.h> |
| 5948 | #include <sys/file.h> |
| 5949 | #include <sys/ioctl.h> |
| 5950 | #include <sys/socket.h> |
| 5951 | #include <sys/sockio.h> |
| 5952 | int |
| 5953 | main () |
| 5954 | { |
| 5955 | ioctl(0, SIOCGLIFCONF, (char *)0); |
| 5956 | ; |
| 5957 | return 0; |
| 5958 | } |
| 5959 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5960 | if ac_fn_c_try_compile "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5961 | ac_cv_lbl_have_siocglifconf=yes |
| 5962 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5963 | ac_cv_lbl_have_siocglifconf=no |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5964 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5965 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 5966 | fi |
| 5967 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5968 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_have_siocglifconf" >&5 |
| 5969 | $as_echo "$ac_cv_lbl_have_siocglifconf" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5970 | if test $ac_cv_lbl_have_siocglifconf = yes ; then |
| 5971 | V_FINDALLDEVS=glifc |
| 5972 | else |
| 5973 | V_FINDALLDEVS=gifc |
| 5974 | fi |
| 5975 | ;; |
| 5976 | |
| 5977 | *) |
| 5978 | # |
| 5979 | # Assume we just have SIOCGIFCONF. |
| 5980 | # (XXX - on at least later Linux kernels, there's |
| 5981 | # another mechanism, and we should be using that |
| 5982 | # instead.) |
| 5983 | # |
| 5984 | V_FINDALLDEVS=gifc |
| 5985 | ;; |
| 5986 | esac |
| 5987 | fi |
| 5988 | |
| 5989 | fi |
| 5990 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5991 | fi |
| 5992 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 5993 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 5994 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t" >&5 |
| 5995 | $as_echo_n "checking for socklen_t... " >&6; } |
| 5996 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 5997 | /* end confdefs.h. */ |
| 5998 | |
| 5999 | #include <sys/types.h> |
| 6000 | #include <sys/socket.h> |
| 6001 | |
| 6002 | int |
| 6003 | main () |
| 6004 | { |
| 6005 | socklen_t x; |
| 6006 | ; |
| 6007 | return 0; |
| 6008 | } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6009 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6010 | if ac_fn_c_try_compile "$LINENO"; then : |
| 6011 | have_socklen_t=yes |
| 6012 | else |
| 6013 | have_socklen_t=no |
| 6014 | fi |
| 6015 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 6016 | if test "x$have_socklen_t" = "xyes"; then |
| 6017 | |
| 6018 | $as_echo "#define HAVE_SOCKLEN_T 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6019 | |
| 6020 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6021 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_socklen_t" >&5 |
| 6022 | $as_echo "$have_socklen_t" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6023 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6024 | # Check whether --enable-ipv6 was given. |
| 6025 | if test "${enable_ipv6+set}" = set; then : |
| 6026 | enableval=$enable_ipv6; |
| 6027 | else |
| 6028 | enable_ipv6=ifavailable |
| 6029 | fi |
| 6030 | |
| 6031 | if test "$enable_ipv6" != "no"; then |
| 6032 | ac_fn_c_check_func "$LINENO" "getaddrinfo" "ac_cv_func_getaddrinfo" |
| 6033 | if test "x$ac_cv_func_getaddrinfo" = xyes; then : |
| 6034 | |
| 6035 | |
| 6036 | $as_echo "#define INET6 1" >>confdefs.h |
| 6037 | |
| 6038 | |
| 6039 | else |
| 6040 | |
| 6041 | if test "$enable_ipv6" != "ifavailable"; then |
| 6042 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6043 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 6044 | as_fn_error $? "--enable-ipv6 was given, but getaddrinfo isn't available |
| 6045 | See \`config.log' for more details" "$LINENO" 5; } |
| 6046 | fi |
| 6047 | |
| 6048 | fi |
| 6049 | |
| 6050 | fi |
| 6051 | |
| 6052 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build optimizer debugging code" >&5 |
| 6053 | $as_echo_n "checking whether to build optimizer debugging code... " >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6054 | # Check whether --enable-optimizer-dbg was given. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6055 | if test "${enable_optimizer_dbg+set}" = set; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6056 | enableval=$enable_optimizer_dbg; |
| 6057 | fi |
| 6058 | |
| 6059 | if test "$enable_optimizer_dbg" = "yes"; then |
| 6060 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6061 | $as_echo "#define BDEBUG 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6062 | |
| 6063 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6064 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${enable_optimizer_dbg-no}" >&5 |
| 6065 | $as_echo "${enable_optimizer_dbg-no}" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6066 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6067 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build parser debugging code" >&5 |
| 6068 | $as_echo_n "checking whether to build parser debugging code... " >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6069 | # Check whether --enable-yydebug was given. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6070 | if test "${enable_yydebug+set}" = set; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6071 | enableval=$enable_yydebug; |
| 6072 | fi |
| 6073 | |
| 6074 | if test "$enable_yydebug" = "yes"; then |
| 6075 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6076 | $as_echo "#define YYDEBUG 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6077 | |
| 6078 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6079 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${enable_yydebug-no}" >&5 |
| 6080 | $as_echo "${enable_yydebug-no}" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6081 | |
| 6082 | # Check for Endace DAG card support. |
| 6083 | |
| 6084 | # Check whether --with-dag was given. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6085 | if test "${with_dag+set}" = set; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6086 | withval=$with_dag; |
| 6087 | if test "$withval" = no |
| 6088 | then |
| 6089 | # User doesn't want DAG support. |
| 6090 | want_dag=no |
| 6091 | elif test "$withval" = yes |
| 6092 | then |
| 6093 | # User wants DAG support but hasn't specified a directory. |
| 6094 | want_dag=yes |
| 6095 | else |
| 6096 | # User wants DAG support and has specified a directory, so use the provided value. |
| 6097 | want_dag=yes |
| 6098 | dag_root=$withval |
| 6099 | fi |
| 6100 | |
| 6101 | else |
| 6102 | |
| 6103 | # |
| 6104 | # Use DAG API if present, otherwise don't |
| 6105 | # |
| 6106 | want_dag=ifpresent |
| 6107 | |
| 6108 | fi |
| 6109 | |
| 6110 | |
| 6111 | |
| 6112 | # Check whether --with-dag-includes was given. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6113 | if test "${with_dag_includes+set}" = set; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6114 | withval=$with_dag_includes; |
| 6115 | # User wants DAG support and has specified a header directory, so use the provided value. |
| 6116 | want_dag=yes |
| 6117 | dag_include_dir=$withval |
| 6118 | |
| 6119 | fi |
| 6120 | |
| 6121 | |
| 6122 | |
| 6123 | # Check whether --with-dag-libraries was given. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6124 | if test "${with_dag_libraries+set}" = set; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6125 | withval=$with_dag_libraries; |
| 6126 | # User wants DAG support and has specified a library directory, so use the provided value. |
| 6127 | want_dag=yes |
| 6128 | dag_lib_dir=$withval |
| 6129 | |
| 6130 | fi |
| 6131 | |
| 6132 | |
| 6133 | case "$V_PCAP" in |
| 6134 | linux|bpf|dag) |
| 6135 | # |
| 6136 | # We support the DAG API if we're on Linux or BSD, or if we're |
| 6137 | # building a DAG-only libpcap. |
| 6138 | # |
| 6139 | ;; |
| 6140 | *) |
| 6141 | # |
| 6142 | # If the user explicitly requested DAG, tell them it's not |
| 6143 | # supported. |
| 6144 | # |
| 6145 | # If they expressed no preference, don't include it. |
| 6146 | # |
| 6147 | if test $want_dag = yes; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6148 | as_fn_error $? "DAG support is only available with 'linux' 'bpf' and 'dag' packet capture types" "$LINENO" 5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6149 | elif test $want_dag = yes; then |
| 6150 | want_dag=no |
| 6151 | fi |
| 6152 | ;; |
| 6153 | esac |
| 6154 | |
| 6155 | ac_cv_lbl_dag_api=no |
| 6156 | if test "$want_dag" != no; then |
| 6157 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6158 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we have DAG API headers" >&5 |
| 6159 | $as_echo_n "checking whether we have DAG API headers... " >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6160 | |
| 6161 | # If necessary, set default paths for DAG API headers and libraries. |
| 6162 | if test -z "$dag_root"; then |
| 6163 | dag_root=/usr/local |
| 6164 | fi |
| 6165 | |
| 6166 | if test -z "$dag_include_dir"; then |
| 6167 | dag_include_dir="$dag_root/include" |
| 6168 | fi |
| 6169 | |
| 6170 | if test -z "$dag_lib_dir"; then |
| 6171 | dag_lib_dir="$dag_root/lib" |
| 6172 | fi |
| 6173 | |
| 6174 | if test -z "$dag_tools_dir"; then |
| 6175 | dag_tools_dir="$dag_root/tools" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6176 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6177 | |
| 6178 | if test -r $dag_include_dir/dagapi.h; then |
| 6179 | ac_cv_lbl_dag_api=yes |
| 6180 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6181 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_dag_api ($dag_include_dir)" >&5 |
| 6182 | $as_echo "$ac_cv_lbl_dag_api ($dag_include_dir)" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6183 | fi |
| 6184 | |
| 6185 | if test $ac_cv_lbl_dag_api = yes; then |
| 6186 | V_INCLS="$V_INCLS -I$dag_include_dir" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6187 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6188 | if test $V_PCAP != dag ; then |
| 6189 | SSRC="pcap-dag.c" |
| 6190 | fi |
| 6191 | |
| 6192 | # See if we can find a general version string. |
| 6193 | # Don't need to save and restore LIBS to prevent -ldag being |
| 6194 | # included if there's a found-action (arg 3). |
| 6195 | saved_ldflags=$LDFLAGS |
| 6196 | LDFLAGS="-L$dag_lib_dir" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6197 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dag_attach_stream in -ldag" >&5 |
| 6198 | $as_echo_n "checking for dag_attach_stream in -ldag... " >&6; } |
| 6199 | if ${ac_cv_lib_dag_dag_attach_stream+:} false; then : |
| 6200 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6201 | else |
| 6202 | ac_check_lib_save_LIBS=$LIBS |
| 6203 | LIBS="-ldag $LIBS" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6204 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6205 | /* end confdefs.h. */ |
| 6206 | |
| 6207 | /* Override any GCC internal prototype to avoid an error. |
| 6208 | Use char because int might match the return type of a GCC |
| 6209 | builtin and then its argument prototype would still apply. */ |
| 6210 | #ifdef __cplusplus |
| 6211 | extern "C" |
| 6212 | #endif |
| 6213 | char dag_attach_stream (); |
| 6214 | int |
| 6215 | main () |
| 6216 | { |
| 6217 | return dag_attach_stream (); |
| 6218 | ; |
| 6219 | return 0; |
| 6220 | } |
| 6221 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6222 | if ac_fn_c_try_link "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6223 | ac_cv_lib_dag_dag_attach_stream=yes |
| 6224 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6225 | ac_cv_lib_dag_dag_attach_stream=no |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6226 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6227 | rm -f core conftest.err conftest.$ac_objext \ |
| 6228 | conftest$ac_exeext conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6229 | LIBS=$ac_check_lib_save_LIBS |
| 6230 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6231 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dag_dag_attach_stream" >&5 |
| 6232 | $as_echo "$ac_cv_lib_dag_dag_attach_stream" >&6; } |
| 6233 | if test "x$ac_cv_lib_dag_dag_attach_stream" = xyes; then : |
| 6234 | dag_streams="1" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6235 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6236 | dag_streams="0" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6237 | fi |
| 6238 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6239 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dag_get_erf_types in -ldag" >&5 |
| 6240 | $as_echo_n "checking for dag_get_erf_types in -ldag... " >&6; } |
| 6241 | if ${ac_cv_lib_dag_dag_get_erf_types+:} false; then : |
| 6242 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6243 | else |
| 6244 | ac_check_lib_save_LIBS=$LIBS |
| 6245 | LIBS="-ldag $LIBS" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6246 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6247 | /* end confdefs.h. */ |
| 6248 | |
| 6249 | /* Override any GCC internal prototype to avoid an error. |
| 6250 | Use char because int might match the return type of a GCC |
| 6251 | builtin and then its argument prototype would still apply. */ |
| 6252 | #ifdef __cplusplus |
| 6253 | extern "C" |
| 6254 | #endif |
| 6255 | char dag_get_erf_types (); |
| 6256 | int |
| 6257 | main () |
| 6258 | { |
| 6259 | return dag_get_erf_types (); |
| 6260 | ; |
| 6261 | return 0; |
| 6262 | } |
| 6263 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6264 | if ac_fn_c_try_link "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6265 | ac_cv_lib_dag_dag_get_erf_types=yes |
| 6266 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6267 | ac_cv_lib_dag_dag_get_erf_types=no |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6268 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6269 | rm -f core conftest.err conftest.$ac_objext \ |
| 6270 | conftest$ac_exeext conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6271 | LIBS=$ac_check_lib_save_LIBS |
| 6272 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6273 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dag_dag_get_erf_types" >&5 |
| 6274 | $as_echo "$ac_cv_lib_dag_dag_get_erf_types" >&6; } |
| 6275 | if test "x$ac_cv_lib_dag_dag_get_erf_types" = xyes; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6276 | |
| 6277 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6278 | $as_echo "#define HAVE_DAG_GET_ERF_TYPES 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6279 | |
| 6280 | fi |
| 6281 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6282 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dag_get_stream_erf_types in -ldag" >&5 |
| 6283 | $as_echo_n "checking for dag_get_stream_erf_types in -ldag... " >&6; } |
| 6284 | if ${ac_cv_lib_dag_dag_get_stream_erf_types+:} false; then : |
| 6285 | $as_echo_n "(cached) " >&6 |
| 6286 | else |
| 6287 | ac_check_lib_save_LIBS=$LIBS |
| 6288 | LIBS="-ldag $LIBS" |
| 6289 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 6290 | /* end confdefs.h. */ |
| 6291 | |
| 6292 | /* Override any GCC internal prototype to avoid an error. |
| 6293 | Use char because int might match the return type of a GCC |
| 6294 | builtin and then its argument prototype would still apply. */ |
| 6295 | #ifdef __cplusplus |
| 6296 | extern "C" |
| 6297 | #endif |
| 6298 | char dag_get_stream_erf_types (); |
| 6299 | int |
| 6300 | main () |
| 6301 | { |
| 6302 | return dag_get_stream_erf_types (); |
| 6303 | ; |
| 6304 | return 0; |
| 6305 | } |
| 6306 | _ACEOF |
| 6307 | if ac_fn_c_try_link "$LINENO"; then : |
| 6308 | ac_cv_lib_dag_dag_get_stream_erf_types=yes |
| 6309 | else |
| 6310 | ac_cv_lib_dag_dag_get_stream_erf_types=no |
| 6311 | fi |
| 6312 | rm -f core conftest.err conftest.$ac_objext \ |
| 6313 | conftest$ac_exeext conftest.$ac_ext |
| 6314 | LIBS=$ac_check_lib_save_LIBS |
| 6315 | fi |
| 6316 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dag_dag_get_stream_erf_types" >&5 |
| 6317 | $as_echo "$ac_cv_lib_dag_dag_get_stream_erf_types" >&6; } |
| 6318 | if test "x$ac_cv_lib_dag_dag_get_stream_erf_types" = xyes; then : |
| 6319 | |
| 6320 | |
| 6321 | $as_echo "#define HAVE_DAG_GET_STREAM_ERF_TYPES 1" >>confdefs.h |
| 6322 | |
| 6323 | fi |
| 6324 | |
| 6325 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6326 | LDFLAGS=$saved_ldflags |
| 6327 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6328 | if test "$dag_streams" = 1; then |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6329 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6330 | $as_echo "#define HAVE_DAG_STREAMS_API 1" >>confdefs.h |
| 6331 | |
| 6332 | LIBS="$LIBS -ldag" |
| 6333 | LDFLAGS="$LDFLAGS -L$dag_lib_dir" |
| 6334 | |
| 6335 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for vdag_set_device_info in -lvdag" >&5 |
| 6336 | $as_echo_n "checking for vdag_set_device_info in -lvdag... " >&6; } |
| 6337 | if ${ac_cv_lib_vdag_vdag_set_device_info+:} false; then : |
| 6338 | $as_echo_n "(cached) " >&6 |
| 6339 | else |
| 6340 | ac_check_lib_save_LIBS=$LIBS |
| 6341 | LIBS="-lvdag $LIBS" |
| 6342 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 6343 | /* end confdefs.h. */ |
| 6344 | |
| 6345 | /* Override any GCC internal prototype to avoid an error. |
| 6346 | Use char because int might match the return type of a GCC |
| 6347 | builtin and then its argument prototype would still apply. */ |
| 6348 | #ifdef __cplusplus |
| 6349 | extern "C" |
| 6350 | #endif |
| 6351 | char vdag_set_device_info (); |
| 6352 | int |
| 6353 | main () |
| 6354 | { |
| 6355 | return vdag_set_device_info (); |
| 6356 | ; |
| 6357 | return 0; |
| 6358 | } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6359 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6360 | if ac_fn_c_try_link "$LINENO"; then : |
| 6361 | ac_cv_lib_vdag_vdag_set_device_info=yes |
| 6362 | else |
| 6363 | ac_cv_lib_vdag_vdag_set_device_info=no |
| 6364 | fi |
| 6365 | rm -f core conftest.err conftest.$ac_objext \ |
| 6366 | conftest$ac_exeext conftest.$ac_ext |
| 6367 | LIBS=$ac_check_lib_save_LIBS |
| 6368 | fi |
| 6369 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_vdag_vdag_set_device_info" >&5 |
| 6370 | $as_echo "$ac_cv_lib_vdag_vdag_set_device_info" >&6; } |
| 6371 | if test "x$ac_cv_lib_vdag_vdag_set_device_info" = xyes; then : |
| 6372 | ac_dag_have_vdag="1" |
| 6373 | else |
| 6374 | ac_dag_have_vdag="0" |
| 6375 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6376 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6377 | if test "$ac_dag_have_vdag" = 1; then |
| 6378 | |
| 6379 | $as_echo "#define HAVE_DAG_VDAG 1" >>confdefs.h |
| 6380 | |
| 6381 | LIBS="$LIBS -lpthread" |
| 6382 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6383 | fi |
| 6384 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6385 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6386 | $as_echo "#define HAVE_DAG_API 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6387 | |
| 6388 | fi |
| 6389 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6390 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we have the DAG API" >&5 |
| 6391 | $as_echo_n "checking whether we have the DAG API... " >&6; } |
| 6392 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6393 | if test $ac_cv_lbl_dag_api = no; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6394 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 6395 | $as_echo "no" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6396 | if test "$want_dag" = yes; then |
| 6397 | # User wanted DAG support but we couldn't find it. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6398 | as_fn_error $? "DAG API requested, but not found at $dag_root: use --without-dag" "$LINENO" 5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6399 | fi |
| 6400 | |
| 6401 | if test "$V_PCAP" = dag; then |
| 6402 | # User requested "dag" capture type but the DAG API wasn't |
| 6403 | # found. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6404 | as_fn_error $? "Specifying the capture type as \"dag\" requires the DAG API to be present; use the --with-dag options to specify the location. (Try \"./configure --help\" for more information.)" "$LINENO" 5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6405 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6406 | else |
| 6407 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 6408 | $as_echo "yes" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6409 | fi |
| 6410 | |
| 6411 | |
| 6412 | # Check whether --with-septel was given. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6413 | if test "${with_septel+set}" = set; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6414 | withval=$with_septel; |
| 6415 | if test "$withval" = no |
| 6416 | then |
| 6417 | want_septel=no |
| 6418 | elif test "$withval" = yes |
| 6419 | then |
| 6420 | want_septel=yes |
| 6421 | septel_root= |
| 6422 | else |
| 6423 | want_septel=yes |
| 6424 | septel_root=$withval |
| 6425 | fi |
| 6426 | |
| 6427 | else |
| 6428 | |
| 6429 | # |
| 6430 | # Use Septel API if present, otherwise don't |
| 6431 | # |
| 6432 | want_septel=ifpresent |
| 6433 | septel_root=./../septel |
| 6434 | |
| 6435 | fi |
| 6436 | |
| 6437 | ac_cv_lbl_septel_api=no |
| 6438 | case "$V_PCAP" in |
| 6439 | linux|septel) |
| 6440 | # |
| 6441 | # We support the Septel API if we're on Linux, or if we're building |
| 6442 | # a Septel-only libpcap. |
| 6443 | # |
| 6444 | ;; |
| 6445 | *) |
| 6446 | # |
| 6447 | # If the user explicitly requested Septel, tell them it's not |
| 6448 | # supported. |
| 6449 | # |
| 6450 | # If they expressed no preference, don't include it. |
| 6451 | # |
| 6452 | if test $want_septel = yes; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6453 | as_fn_error $? "Septel support only available with 'linux' and 'septel' packet capture types" "$LINENO" 5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6454 | elif test $want_septel = yes; then |
| 6455 | want_septel=no |
| 6456 | fi |
| 6457 | ;; |
| 6458 | esac |
| 6459 | |
| 6460 | if test "$with_septel" != no; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6461 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we have Septel API" >&5 |
| 6462 | $as_echo_n "checking whether we have Septel API... " >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6463 | |
| 6464 | if test -z "$septel_root"; then |
| 6465 | septel_root=$srcdir/../septel |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6466 | fi |
| 6467 | |
| 6468 | septel_tools_dir="$septel_root" |
| 6469 | septel_include_dir="$septel_root/INC" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6470 | |
| 6471 | ac_cv_lbl_septel_api=no |
| 6472 | if test -r "$septel_include_dir/msg.h"; then |
| 6473 | V_INCLS="$V_INCLS -I$septel_include_dir" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6474 | ADDLOBJS="$ADDLOBJS $septel_tools_dir/asciibin.o $septel_tools_dir/bit2byte.o $septel_tools_dir/confirm.o $septel_tools_dir/fmtmsg.o $septel_tools_dir/gct_unix.o $septel_tools_dir/hqueue.o $septel_tools_dir/ident.o $septel_tools_dir/mem.o $septel_tools_dir/pack.o $septel_tools_dir/parse.o $septel_tools_dir/pool.o $septel_tools_dir/sdlsig.o $septel_tools_dir/strtonum.o $septel_tools_dir/timer.o $septel_tools_dir/trace.o" |
| 6475 | ADDLARCHIVEOBJS="$ADDLARCHIVEOBJS $septel_tools_dir/asciibin.o $septel_tools_dir/bit2byte.o $septel_tools_dir/confirm.o $septel_tools_dir/fmtmsg.o $septel_tools_dir/gct_unix.o $septel_tools_dir/hqueue.o $septel_tools_dir/ident.o $septel_tools_dir/mem.o $septel_tools_dir/pack.o $septel_tools_dir/parse.o $septel_tools_dir/pool.o $septel_tools_dir/sdlsig.o $septel_tools_dir/strtonum.o $septel_tools_dir/timer.o $septel_tools_dir/trace.o" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6476 | |
| 6477 | if test "$V_PCAP" != septel ; then |
| 6478 | SSRC="pcap-septel.c" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6479 | fi |
| 6480 | ac_cv_lbl_septel_api=yes |
| 6481 | fi |
| 6482 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6483 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_septel_api" >&5 |
| 6484 | $as_echo "$ac_cv_lbl_septel_api" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6485 | if test $ac_cv_lbl_septel_api = no; then |
| 6486 | if test "$want_septel" = yes; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6487 | as_fn_error $? "Septel API not found under directory $septel_root; use --without-septel" "$LINENO" 5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6488 | fi |
| 6489 | else |
| 6490 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6491 | $as_echo "#define HAVE_SEPTEL_API 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6492 | |
| 6493 | fi |
| 6494 | fi |
| 6495 | |
| 6496 | if test "$V_PCAP" = septel -a "$ac_cv_lbl_septel_api" = no; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6497 | as_fn_error $? "Specifying the capture type as 'septel' requires the Septel API to be present; use --with-septel=DIR" "$LINENO" 5 |
| 6498 | fi |
| 6499 | |
| 6500 | # Check for Myricom SNF support. |
| 6501 | |
| 6502 | # Check whether --with-snf was given. |
| 6503 | if test "${with_snf+set}" = set; then : |
| 6504 | withval=$with_snf; |
| 6505 | if test "$withval" = no |
| 6506 | then |
| 6507 | # User explicitly doesn't want SNF |
| 6508 | want_snf=no |
| 6509 | elif test "$withval" = yes |
| 6510 | then |
| 6511 | # User wants SNF support but hasn't specific a directory. |
| 6512 | want_snf=yes |
| 6513 | else |
| 6514 | # User wants SNF support with a specified directory. |
| 6515 | want_snf=yes |
| 6516 | snf_root=$withval |
| 6517 | fi |
| 6518 | |
| 6519 | else |
| 6520 | |
| 6521 | # |
| 6522 | # Use Sniffer API if present, otherwise don't |
| 6523 | # |
| 6524 | want_snf=ifpresent |
| 6525 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6526 | fi |
| 6527 | |
| 6528 | |
| 6529 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6530 | # Check whether --with-snf-includes was given. |
| 6531 | if test "${with_snf_includes+set}" = set; then : |
| 6532 | withval=$with_snf_includes; |
| 6533 | # User wants SNF with specific header directory |
| 6534 | want_snf=yes |
| 6535 | snf_include_dir=$withval |
| 6536 | |
| 6537 | fi |
| 6538 | |
| 6539 | |
| 6540 | |
| 6541 | # Check whether --with-snf-libraries was given. |
| 6542 | if test "${with_snf_libraries+set}" = set; then : |
| 6543 | withval=$with_snf_libraries; |
| 6544 | # User wants SNF with specific lib directory |
| 6545 | want_snf=yes |
| 6546 | snf_lib_dir=$withval |
| 6547 | |
| 6548 | fi |
| 6549 | |
| 6550 | |
| 6551 | case "$V_PCAP" in |
| 6552 | bpf|linux|snf) |
| 6553 | # |
| 6554 | # We support the Sniffer API if we're on BSD, Linux, or if we're |
| 6555 | # building a Sniffer-only libpcap. |
| 6556 | # |
| 6557 | ;; |
| 6558 | *) |
| 6559 | # |
| 6560 | # If the user explicitly requested Sniffer, tell them it's not |
| 6561 | # supported. |
| 6562 | # |
| 6563 | # If they expressed no preference, don't include it. |
| 6564 | # |
| 6565 | if test $want_snf = yes; then |
| 6566 | as_fn_error $? "Myricom SNF support only available with 'bpf' 'linux' and 'snf' packet capture types" "$LINENO" 5 |
| 6567 | elif test $want_snf = yes; then |
| 6568 | want_snf=no |
| 6569 | fi |
| 6570 | ;; |
| 6571 | esac |
| 6572 | |
| 6573 | ac_cv_lbl_snf_api=no |
| 6574 | if test "$with_snf" != no; then |
| 6575 | |
| 6576 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we have Myricom Sniffer API" >&5 |
| 6577 | $as_echo_n "checking whether we have Myricom Sniffer API... " >&6; } |
| 6578 | |
| 6579 | if test -z "$snf_root"; then |
| 6580 | snf_root=/opt/snf |
| 6581 | fi |
| 6582 | |
| 6583 | if test -z "$snf_include_dir"; then |
| 6584 | snf_include_dir="$snf_root/include" |
| 6585 | fi |
| 6586 | |
| 6587 | if test -z "$snf_lib_dir"; then |
| 6588 | snf_lib_dir="$snf_root/lib" |
| 6589 | fi |
| 6590 | |
| 6591 | if test -f "$snf_include_dir/snf.h"; then |
| 6592 | ac_cv_lbl_snf_api=yes |
| 6593 | fi |
| 6594 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_snf_api ($snf_root)" >&5 |
| 6595 | $as_echo "$ac_cv_lbl_snf_api ($snf_root)" >&6; } |
| 6596 | |
| 6597 | if test $ac_cv_lbl_snf_api = no; then |
| 6598 | if test "$want_snf" = yes; then |
| 6599 | as_fn_error $? "SNF API headers not found under $snf_include_dir; use --without-snf" "$LINENO" 5 |
| 6600 | fi |
| 6601 | else |
| 6602 | saved_ldflags=$LDFLAGS |
| 6603 | LDFLAGS="$LDFLAGS -L$snf_lib_dir" |
| 6604 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for snf_init in -lsnf" >&5 |
| 6605 | $as_echo_n "checking for snf_init in -lsnf... " >&6; } |
| 6606 | if ${ac_cv_lib_snf_snf_init+:} false; then : |
| 6607 | $as_echo_n "(cached) " >&6 |
| 6608 | else |
| 6609 | ac_check_lib_save_LIBS=$LIBS |
| 6610 | LIBS="-lsnf $LIBS" |
| 6611 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 6612 | /* end confdefs.h. */ |
| 6613 | |
| 6614 | /* Override any GCC internal prototype to avoid an error. |
| 6615 | Use char because int might match the return type of a GCC |
| 6616 | builtin and then its argument prototype would still apply. */ |
| 6617 | #ifdef __cplusplus |
| 6618 | extern "C" |
| 6619 | #endif |
| 6620 | char snf_init (); |
| 6621 | int |
| 6622 | main () |
| 6623 | { |
| 6624 | return snf_init (); |
| 6625 | ; |
| 6626 | return 0; |
| 6627 | } |
| 6628 | _ACEOF |
| 6629 | if ac_fn_c_try_link "$LINENO"; then : |
| 6630 | ac_cv_lib_snf_snf_init=yes |
| 6631 | else |
| 6632 | ac_cv_lib_snf_snf_init=no |
| 6633 | fi |
| 6634 | rm -f core conftest.err conftest.$ac_objext \ |
| 6635 | conftest$ac_exeext conftest.$ac_ext |
| 6636 | LIBS=$ac_check_lib_save_LIBS |
| 6637 | fi |
| 6638 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_snf_snf_init" >&5 |
| 6639 | $as_echo "$ac_cv_lib_snf_snf_init" >&6; } |
| 6640 | if test "x$ac_cv_lib_snf_snf_init" = xyes; then : |
| 6641 | ac_cv_lbl_snf_api="yes" |
| 6642 | else |
| 6643 | ac_cv_lbl_snf_api="no" |
| 6644 | fi |
| 6645 | |
| 6646 | LDFLAGS="$saved_ldflags" |
| 6647 | |
| 6648 | if test $ac_cv_lbl_snf_api = no; then |
| 6649 | if test "$want_snf" = yes; then |
| 6650 | as_fn_error $? "SNF API cannot correctly be linked check config.log; use --without-snf" "$LINENO" 5 |
| 6651 | fi |
| 6652 | else |
| 6653 | V_INCLS="$V_INCLS -I$snf_include_dir" |
| 6654 | LIBS="$LIBS -lsnf" |
| 6655 | LDFLAGS="$LDFLAGS -L$snf_lib_dir" |
| 6656 | if test "$V_PCAP" != snf ; then |
| 6657 | SSRC="pcap-snf.c" |
| 6658 | fi |
| 6659 | |
| 6660 | $as_echo "#define HAVE_SNF_API 1" >>confdefs.h |
| 6661 | |
| 6662 | fi |
| 6663 | fi |
| 6664 | fi |
| 6665 | |
| 6666 | if test "$V_PCAP" = snf -a "$ac_cv_lbl_snf_api" = no; then |
| 6667 | as_fn_error $? "Specifying the capture type as 'snf' requires the Myricom Sniffer API to be present; use --with-snf=DIR" "$LINENO" 5 |
| 6668 | fi |
| 6669 | |
| 6670 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6671 | # Check whether --with-flex was given. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6672 | if test "${with_flex+set}" = set; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6673 | withval=$with_flex; |
| 6674 | fi |
| 6675 | |
| 6676 | |
| 6677 | # Check whether --with-bison was given. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6678 | if test "${with_bison+set}" = set; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6679 | withval=$with_bison; |
| 6680 | fi |
| 6681 | |
| 6682 | if test "$with_flex" = no ; then |
| 6683 | V_LEX=lex |
| 6684 | else |
| 6685 | for ac_prog in flex |
| 6686 | do |
| 6687 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 6688 | set dummy $ac_prog; ac_word=$2 |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6689 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 6690 | $as_echo_n "checking for $ac_word... " >&6; } |
| 6691 | if ${ac_cv_prog_V_LEX+:} false; then : |
| 6692 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6693 | else |
| 6694 | if test -n "$V_LEX"; then |
| 6695 | ac_cv_prog_V_LEX="$V_LEX" # Let the user override the test. |
| 6696 | else |
| 6697 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 6698 | for as_dir in $PATH |
| 6699 | do |
| 6700 | IFS=$as_save_IFS |
| 6701 | test -z "$as_dir" && as_dir=. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6702 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 6703 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6704 | ac_cv_prog_V_LEX="$ac_prog" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6705 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6706 | break 2 |
| 6707 | fi |
| 6708 | done |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6709 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6710 | IFS=$as_save_IFS |
| 6711 | |
| 6712 | fi |
| 6713 | fi |
| 6714 | V_LEX=$ac_cv_prog_V_LEX |
| 6715 | if test -n "$V_LEX"; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6716 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $V_LEX" >&5 |
| 6717 | $as_echo "$V_LEX" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6718 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6719 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 6720 | $as_echo "no" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6721 | fi |
| 6722 | |
| 6723 | |
| 6724 | test -n "$V_LEX" && break |
| 6725 | done |
| 6726 | test -n "$V_LEX" || V_LEX="lex" |
| 6727 | |
| 6728 | fi |
| 6729 | if test "$V_LEX" = flex ; then |
| 6730 | # The -V flag was added in 2.4 |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6731 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flex 2.4 or higher" >&5 |
| 6732 | $as_echo_n "checking for flex 2.4 or higher... " >&6; } |
| 6733 | if ${ac_cv_lbl_flex_v24+:} false; then : |
| 6734 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6735 | else |
| 6736 | if flex -V >/dev/null 2>&1; then |
| 6737 | ac_cv_lbl_flex_v24=yes |
| 6738 | else |
| 6739 | ac_cv_lbl_flex_v24=no |
| 6740 | fi |
| 6741 | fi |
| 6742 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6743 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_flex_v24" >&5 |
| 6744 | $as_echo "$ac_cv_lbl_flex_v24" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6745 | if test $ac_cv_lbl_flex_v24 = no ; then |
| 6746 | s="2.4 or higher required" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6747 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ignoring obsolete flex executable ($s)" >&5 |
| 6748 | $as_echo "$as_me: WARNING: ignoring obsolete flex executable ($s)" >&2;} |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6749 | V_LEX=lex |
| 6750 | fi |
| 6751 | fi |
| 6752 | if test "$with_bison" = no ; then |
| 6753 | V_YACC=yacc |
| 6754 | else |
| 6755 | for ac_prog in bison |
| 6756 | do |
| 6757 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 6758 | set dummy $ac_prog; ac_word=$2 |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6759 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 6760 | $as_echo_n "checking for $ac_word... " >&6; } |
| 6761 | if ${ac_cv_prog_V_YACC+:} false; then : |
| 6762 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6763 | else |
| 6764 | if test -n "$V_YACC"; then |
| 6765 | ac_cv_prog_V_YACC="$V_YACC" # Let the user override the test. |
| 6766 | else |
| 6767 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 6768 | for as_dir in $PATH |
| 6769 | do |
| 6770 | IFS=$as_save_IFS |
| 6771 | test -z "$as_dir" && as_dir=. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6772 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 6773 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6774 | ac_cv_prog_V_YACC="$ac_prog" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6775 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6776 | break 2 |
| 6777 | fi |
| 6778 | done |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6779 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6780 | IFS=$as_save_IFS |
| 6781 | |
| 6782 | fi |
| 6783 | fi |
| 6784 | V_YACC=$ac_cv_prog_V_YACC |
| 6785 | if test -n "$V_YACC"; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6786 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $V_YACC" >&5 |
| 6787 | $as_echo "$V_YACC" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6788 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6789 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 6790 | $as_echo "no" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6791 | fi |
| 6792 | |
| 6793 | |
| 6794 | test -n "$V_YACC" && break |
| 6795 | done |
| 6796 | test -n "$V_YACC" || V_YACC="yacc" |
| 6797 | |
| 6798 | fi |
| 6799 | if test "$V_YACC" = bison ; then |
| 6800 | V_YACC="$V_YACC -y" |
| 6801 | fi |
| 6802 | if test "$V_LEX" != lex -a "$V_YACC" = yacc -o "$V_LEX" = lex -a "$V_YACC" != yacc ; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6803 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: don't have both flex and bison; reverting to lex/yacc" >&5 |
| 6804 | $as_echo "$as_me: WARNING: don't have both flex and bison; reverting to lex/yacc" >&2;} |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6805 | V_LEX=lex |
| 6806 | V_YACC=yacc |
| 6807 | fi |
| 6808 | if test "$V_LEX" = flex -a -n "pcap_" ; then |
| 6809 | V_LEX="$V_LEX -Ppcap_" |
| 6810 | V_YACC="$V_YACC -p pcap_" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6811 | else |
| 6812 | |
| 6813 | $as_echo "#define NEED_YYPARSE_WRAPPER 1" >>confdefs.h |
| 6814 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6815 | fi |
| 6816 | if test "$V_LEX" = lex ; then |
| 6817 | # Some versions of lex can't handle the definitions section of scanner.l . |
| 6818 | # Try lexing it and complain if it can't deal. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6819 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for capable lex" >&5 |
| 6820 | $as_echo_n "checking for capable lex... " >&6; } |
| 6821 | if ${tcpdump_cv_capable_lex+:} false; then : |
| 6822 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6823 | else |
| 6824 | if lex -t scanner.l > /dev/null 2>&1; then |
| 6825 | tcpdump_cv_capable_lex=yes |
| 6826 | else |
| 6827 | tcpdump_cv_capable_lex=insufficient |
| 6828 | fi |
| 6829 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6830 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tcpdump_cv_capable_lex" >&5 |
| 6831 | $as_echo "$tcpdump_cv_capable_lex" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6832 | if test $tcpdump_cv_capable_lex = insufficient ; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6833 | as_fn_error $? "Your operating system's lex is insufficient to compile |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6834 | libpcap. flex is a lex replacement that has many advantages, including |
| 6835 | being able to compile libpcap. For more information, see |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6836 | http://www.gnu.org/software/flex/flex.html ." "$LINENO" 5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6837 | fi |
| 6838 | fi |
| 6839 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6840 | # |
| 6841 | # Assume, by default, no support for shared libraries and V7/BSD convention |
| 6842 | # for man pages (file formats in section 5, miscellaneous info in section 7). |
| 6843 | # Individual cases can override this. |
| 6844 | # |
| 6845 | DYEXT="none" |
| 6846 | MAN_FILE_FORMATS=5 |
| 6847 | MAN_MISC_INFO=7 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6848 | case "$host_os" in |
| 6849 | |
| 6850 | aix*) |
| 6851 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6852 | $as_echo "#define _SUN 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6853 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6854 | |
| 6855 | # |
| 6856 | # AIX makes it fun to build shared and static libraries, |
| 6857 | # because they're *both* ".a" archive libraries. We |
| 6858 | # build the static library for the benefit of the traditional |
| 6859 | # scheme of building libpcap and tcpdump in subdirectories of |
| 6860 | # the same directory, with tcpdump statically linked with the |
| 6861 | # libpcap in question, but we also build a shared library as |
| 6862 | # "libpcap.shareda" and install *it*, rather than the static |
| 6863 | # library, as "libpcap.a". |
| 6864 | # |
| 6865 | DYEXT="shareda" |
| 6866 | |
| 6867 | case "$V_PCAP" in |
| 6868 | |
| 6869 | dlpi) |
| 6870 | # |
| 6871 | # If we're using DLPI, applications will need to |
| 6872 | # use /lib/pse.exp if present, as we use the |
| 6873 | # STREAMS routines. |
| 6874 | # |
| 6875 | pseexe="/lib/pse.exp" |
| 6876 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $pseexe" >&5 |
| 6877 | $as_echo_n "checking for $pseexe... " >&6; } |
| 6878 | if test -f $pseexe ; then |
| 6879 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 6880 | $as_echo "yes" >&6; } |
| 6881 | LIBS="-I:$pseexe" |
| 6882 | fi |
| 6883 | ;; |
| 6884 | |
| 6885 | bpf) |
| 6886 | # |
| 6887 | # If we're using BPF, we need "-lodm" and "-lcfg", as |
| 6888 | # we use them to load the BPF module. |
| 6889 | # |
| 6890 | LIBS="-lodm -lcfg" |
| 6891 | ;; |
| 6892 | esac |
| 6893 | ;; |
| 6894 | |
| 6895 | darwin*) |
| 6896 | DYEXT="dylib" |
| 6897 | V_CCOPT="$V_CCOPT -fno-common" |
| 6898 | # Check whether --enable-universal was given. |
| 6899 | if test "${enable_universal+set}" = set; then : |
| 6900 | enableval=$enable_universal; |
| 6901 | fi |
| 6902 | |
| 6903 | if test "$enable_universal" != "no"; then |
| 6904 | case "$host_os" in |
| 6905 | |
| 6906 | darwin0-7.*) |
| 6907 | # |
| 6908 | # Pre-Tiger. Build only for 32-bit PowerPC; no |
| 6909 | # need for any special compiler or linker flags. |
| 6910 | # |
| 6911 | ;; |
| 6912 | |
| 6913 | darwin8.0123*) |
| 6914 | # |
| 6915 | # Tiger, prior to Intel support. Build for 32-bit |
| 6916 | # PowerPC and 64-bit PowerPC, with 32-bit PowerPC |
| 6917 | # first. (I'm guessing that's what Apple does.) |
| 6918 | # |
| 6919 | V_CCOPT="$V_CCOPT -arch ppc -arch ppc64" |
| 6920 | LDFLAGS="$LDFLAGS -arch ppc -arch ppc64" |
| 6921 | ;; |
| 6922 | |
| 6923 | darwin8.456*) |
| 6924 | # |
| 6925 | # Tiger, subsequent to Intel support but prior to |
| 6926 | # x86-64 support. Build for 32-bit PowerPC, 64-bit |
| 6927 | # PowerPC, and x86, with 32-bit PowerPC first. |
| 6928 | # (I'm guessing that's what Apple does.) |
| 6929 | # |
| 6930 | V_CCOPT="$V_CCOPT -arch ppc -arch ppc64 -arch i386" |
| 6931 | LDFLAGS="$LDFLAGS -arch ppc -arch ppc64 -arch i386" |
| 6932 | ;; |
| 6933 | |
| 6934 | darwin8.*) |
| 6935 | # |
| 6936 | # All other Tiger, so subsequent to x86-64 |
| 6937 | # support. Build for 32-bit PowerPC, 64-bit |
| 6938 | # PowerPC, x86, and x86-64, and with 32-bit PowerPC |
| 6939 | # first. (I'm guessing that's what Apple does.) |
| 6940 | # |
| 6941 | V_CCOPT="$V_CCOPT -arch ppc -arch ppc64 -arch i386 -arch x86_64" |
| 6942 | LDFLAGS="$LDFLAGS -arch ppc -arch ppc64 -arch i386 -arch x86_64" |
| 6943 | ;; |
| 6944 | |
| 6945 | darwin9.*) |
| 6946 | # |
| 6947 | # Leopard. Build for 32-bit PowerPC, 64-bit |
| 6948 | # PowerPC, x86, and x86-64, with 32-bit PowerPC |
| 6949 | # first. (That's what Apple does.) |
| 6950 | # |
| 6951 | V_CCOPT="$V_CCOPT -arch ppc -arch ppc64 -arch i386 -arch x86_64" |
| 6952 | LDFLAGS="$LDFLAGS -arch ppc -arch ppc64 -arch i386 -arch x86_64" |
| 6953 | ;; |
| 6954 | |
| 6955 | darwin10.*) |
| 6956 | # |
| 6957 | # Snow Leopard. Build for x86-64, x86, and |
| 6958 | # 32-bit PowerPC, with x86-64 first. (That's |
| 6959 | # what Apple does, even though Snow Leopard |
| 6960 | # doesn't run on PPC, so PPC libpcap runs under |
| 6961 | # Rosetta, and Rosetta doesn't support BPF |
| 6962 | # ioctls, so PPC programs can't do live |
| 6963 | # captures.) |
| 6964 | # |
| 6965 | V_CCOPT="$V_CCOPT -arch x86_64 -arch i386 -arch ppc" |
| 6966 | LDFLAGS="$LDFLAGS -arch x86_64 -arch i386 -arch ppc" |
| 6967 | ;; |
| 6968 | |
| 6969 | darwin*) |
| 6970 | # |
| 6971 | # Post-Snow Leopard. Build for x86-64 and |
| 6972 | # x86, with x86-64 first. (That's probably what |
| 6973 | # Apple does, given that Rosetta is gone.) |
| 6974 | # XXX - update if and when Apple drops support |
| 6975 | # for 32-bit x86 code. |
| 6976 | # |
| 6977 | V_CCOPT="$V_CCOPT -arch x86_64 -arch i386" |
| 6978 | LDFLAGS="$LDFLAGS -arch x86_64 -arch i386" |
| 6979 | ;; |
| 6980 | esac |
| 6981 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6982 | ;; |
| 6983 | |
| 6984 | hpux9*) |
| 6985 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6986 | $as_echo "#define HAVE_HPUX9 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6987 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6988 | |
| 6989 | # |
| 6990 | # Use System V conventions for man pages. |
| 6991 | # |
| 6992 | MAN_FILE_FORMATS=4 |
| 6993 | MAN_MISC_INFO=5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 6994 | ;; |
| 6995 | |
| 6996 | hpux10.0*) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 6997 | |
| 6998 | # |
| 6999 | # Use System V conventions for man pages. |
| 7000 | # |
| 7001 | MAN_FILE_FORMATS=4 |
| 7002 | MAN_MISC_INFO=5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7003 | ;; |
| 7004 | |
| 7005 | hpux10.1*) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7006 | |
| 7007 | # |
| 7008 | # Use System V conventions for man pages. |
| 7009 | # |
| 7010 | MAN_FILE_FORMATS=4 |
| 7011 | MAN_MISC_INFO=5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7012 | ;; |
| 7013 | |
| 7014 | hpux*) |
| 7015 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7016 | $as_echo "#define HAVE_HPUX10_20_OR_LATER 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7017 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7018 | if test "`uname -m`" = "ia64"; then |
| 7019 | DYEXT="so" |
| 7020 | else |
| 7021 | DYEXT="sl" |
| 7022 | fi |
| 7023 | |
| 7024 | # |
| 7025 | # "-b" builds a shared library; "+h" sets the soname. |
| 7026 | # |
| 7027 | SHLIB_OPT="-b" |
| 7028 | SONAME_OPT="+h" |
| 7029 | |
| 7030 | # |
| 7031 | # Use System V conventions for man pages. |
| 7032 | # |
| 7033 | MAN_FILE_FORMATS=4 |
| 7034 | MAN_MISC_INFO=5 |
| 7035 | ;; |
| 7036 | |
| 7037 | irix*) |
| 7038 | # |
| 7039 | # Use System V conventions for man pages. |
| 7040 | # |
| 7041 | MAN_FILE_FORMATS=4 |
| 7042 | MAN_MISC_INFO=5 |
| 7043 | ;; |
| 7044 | |
| 7045 | linux*|freebsd*|netbsd*|openbsd*|dragonfly*|kfreebsd*|gnu*) |
| 7046 | DYEXT="so" |
| 7047 | |
| 7048 | # |
| 7049 | # Compiler assumed to be GCC; run-time linker may require a -R |
| 7050 | # flag. |
| 7051 | # |
| 7052 | if test "$libdir" != "/usr/lib"; then |
| 7053 | V_RFLAGS=-Wl,-R$libdir |
| 7054 | fi |
| 7055 | ;; |
| 7056 | |
| 7057 | osf*) |
| 7058 | DYEXT="so" |
| 7059 | |
| 7060 | # |
| 7061 | # Use System V conventions for man pages. |
| 7062 | # |
| 7063 | MAN_FILE_FORMATS=4 |
| 7064 | MAN_MISC_INFO=5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7065 | ;; |
| 7066 | |
| 7067 | sinix*) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7068 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if SINIX compiler defines sinix" >&5 |
| 7069 | $as_echo_n "checking if SINIX compiler defines sinix... " >&6; } |
| 7070 | if ${ac_cv_cc_sinix_defined+:} false; then : |
| 7071 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7072 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7073 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7074 | /* end confdefs.h. */ |
| 7075 | |
| 7076 | int |
| 7077 | main () |
| 7078 | { |
| 7079 | int i = sinix; |
| 7080 | ; |
| 7081 | return 0; |
| 7082 | } |
| 7083 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7084 | if ac_fn_c_try_compile "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7085 | ac_cv_cc_sinix_defined=yes |
| 7086 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7087 | ac_cv_cc_sinix_defined=no |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7088 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7089 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 7090 | fi |
| 7091 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7092 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cc_sinix_defined" >&5 |
| 7093 | $as_echo "$ac_cv_cc_sinix_defined" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7094 | if test $ac_cv_cc_sinix_defined = no ; then |
| 7095 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7096 | $as_echo "#define sinix 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7097 | |
| 7098 | fi |
| 7099 | ;; |
| 7100 | |
| 7101 | solaris*) |
| 7102 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7103 | $as_echo "#define HAVE_SOLARIS 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7104 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7105 | |
| 7106 | DYEXT="so" |
| 7107 | # |
| 7108 | # Use System V conventions for man pages. |
| 7109 | # |
| 7110 | MAN_FILE_FORMATS=4 |
| 7111 | MAN_MISC_INFO=5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7112 | ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7113 | esac |
| 7114 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7115 | # Check whether --enable-shared was given. |
| 7116 | if test "${enable_shared+set}" = set; then : |
| 7117 | enableval=$enable_shared; |
| 7118 | fi |
| 7119 | |
| 7120 | test "x$enable_shared" = "xno" && DYEXT="none" |
| 7121 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7122 | if test -n "$ac_tool_prefix"; then |
| 7123 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. |
| 7124 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7125 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 7126 | $as_echo_n "checking for $ac_word... " >&6; } |
| 7127 | if ${ac_cv_prog_RANLIB+:} false; then : |
| 7128 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7129 | else |
| 7130 | if test -n "$RANLIB"; then |
| 7131 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. |
| 7132 | else |
| 7133 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 7134 | for as_dir in $PATH |
| 7135 | do |
| 7136 | IFS=$as_save_IFS |
| 7137 | test -z "$as_dir" && as_dir=. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7138 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 7139 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7140 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7141 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7142 | break 2 |
| 7143 | fi |
| 7144 | done |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7145 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7146 | IFS=$as_save_IFS |
| 7147 | |
| 7148 | fi |
| 7149 | fi |
| 7150 | RANLIB=$ac_cv_prog_RANLIB |
| 7151 | if test -n "$RANLIB"; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7152 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 |
| 7153 | $as_echo "$RANLIB" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7154 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7155 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7156 | $as_echo "no" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7157 | fi |
| 7158 | |
| 7159 | |
| 7160 | fi |
| 7161 | if test -z "$ac_cv_prog_RANLIB"; then |
| 7162 | ac_ct_RANLIB=$RANLIB |
| 7163 | # Extract the first word of "ranlib", so it can be a program name with args. |
| 7164 | set dummy ranlib; ac_word=$2 |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7165 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 7166 | $as_echo_n "checking for $ac_word... " >&6; } |
| 7167 | if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : |
| 7168 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7169 | else |
| 7170 | if test -n "$ac_ct_RANLIB"; then |
| 7171 | ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. |
| 7172 | else |
| 7173 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 7174 | for as_dir in $PATH |
| 7175 | do |
| 7176 | IFS=$as_save_IFS |
| 7177 | test -z "$as_dir" && as_dir=. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7178 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 7179 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7180 | ac_cv_prog_ac_ct_RANLIB="ranlib" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7181 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7182 | break 2 |
| 7183 | fi |
| 7184 | done |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7185 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7186 | IFS=$as_save_IFS |
| 7187 | |
| 7188 | fi |
| 7189 | fi |
| 7190 | ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB |
| 7191 | if test -n "$ac_ct_RANLIB"; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7192 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 |
| 7193 | $as_echo "$ac_ct_RANLIB" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7194 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7195 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7196 | $as_echo "no" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7197 | fi |
| 7198 | |
| 7199 | if test "x$ac_ct_RANLIB" = x; then |
| 7200 | RANLIB=":" |
| 7201 | else |
| 7202 | case $cross_compiling:$ac_tool_warned in |
| 7203 | yes:) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7204 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 7205 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7206 | ac_tool_warned=yes ;; |
| 7207 | esac |
| 7208 | RANLIB=$ac_ct_RANLIB |
| 7209 | fi |
| 7210 | else |
| 7211 | RANLIB="$ac_cv_prog_RANLIB" |
| 7212 | fi |
| 7213 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7214 | if test -n "$ac_tool_prefix"; then |
| 7215 | # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. |
| 7216 | set dummy ${ac_tool_prefix}ar; ac_word=$2 |
| 7217 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 7218 | $as_echo_n "checking for $ac_word... " >&6; } |
| 7219 | if ${ac_cv_prog_AR+:} false; then : |
| 7220 | $as_echo_n "(cached) " >&6 |
| 7221 | else |
| 7222 | if test -n "$AR"; then |
| 7223 | ac_cv_prog_AR="$AR" # Let the user override the test. |
| 7224 | else |
| 7225 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 7226 | for as_dir in $PATH |
| 7227 | do |
| 7228 | IFS=$as_save_IFS |
| 7229 | test -z "$as_dir" && as_dir=. |
| 7230 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 7231 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
| 7232 | ac_cv_prog_AR="${ac_tool_prefix}ar" |
| 7233 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
| 7234 | break 2 |
| 7235 | fi |
| 7236 | done |
| 7237 | done |
| 7238 | IFS=$as_save_IFS |
| 7239 | |
| 7240 | fi |
| 7241 | fi |
| 7242 | AR=$ac_cv_prog_AR |
| 7243 | if test -n "$AR"; then |
| 7244 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 |
| 7245 | $as_echo "$AR" >&6; } |
| 7246 | else |
| 7247 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7248 | $as_echo "no" >&6; } |
| 7249 | fi |
| 7250 | |
| 7251 | |
| 7252 | fi |
| 7253 | if test -z "$ac_cv_prog_AR"; then |
| 7254 | ac_ct_AR=$AR |
| 7255 | # Extract the first word of "ar", so it can be a program name with args. |
| 7256 | set dummy ar; ac_word=$2 |
| 7257 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 7258 | $as_echo_n "checking for $ac_word... " >&6; } |
| 7259 | if ${ac_cv_prog_ac_ct_AR+:} false; then : |
| 7260 | $as_echo_n "(cached) " >&6 |
| 7261 | else |
| 7262 | if test -n "$ac_ct_AR"; then |
| 7263 | ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. |
| 7264 | else |
| 7265 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 7266 | for as_dir in $PATH |
| 7267 | do |
| 7268 | IFS=$as_save_IFS |
| 7269 | test -z "$as_dir" && as_dir=. |
| 7270 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 7271 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
| 7272 | ac_cv_prog_ac_ct_AR="ar" |
| 7273 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
| 7274 | break 2 |
| 7275 | fi |
| 7276 | done |
| 7277 | done |
| 7278 | IFS=$as_save_IFS |
| 7279 | |
| 7280 | fi |
| 7281 | fi |
| 7282 | ac_ct_AR=$ac_cv_prog_ac_ct_AR |
| 7283 | if test -n "$ac_ct_AR"; then |
| 7284 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 |
| 7285 | $as_echo "$ac_ct_AR" >&6; } |
| 7286 | else |
| 7287 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7288 | $as_echo "no" >&6; } |
| 7289 | fi |
| 7290 | |
| 7291 | if test "x$ac_ct_AR" = x; then |
| 7292 | AR="" |
| 7293 | else |
| 7294 | case $cross_compiling:$ac_tool_warned in |
| 7295 | yes:) |
| 7296 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 7297 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
| 7298 | ac_tool_warned=yes ;; |
| 7299 | esac |
| 7300 | AR=$ac_ct_AR |
| 7301 | fi |
| 7302 | else |
| 7303 | AR="$ac_cv_prog_AR" |
| 7304 | fi |
| 7305 | |
| 7306 | |
| 7307 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 |
| 7308 | $as_echo_n "checking whether ln -s works... " >&6; } |
| 7309 | LN_S=$as_ln_s |
| 7310 | if test "$LN_S" = "ln -s"; then |
| 7311 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 7312 | $as_echo "yes" >&6; } |
| 7313 | else |
| 7314 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 |
| 7315 | $as_echo "no, using $LN_S" >&6; } |
| 7316 | fi |
| 7317 | |
| 7318 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7319 | |
| 7320 | rm -f os-proto.h |
| 7321 | if test "${LBL_CFLAGS+set}" = set; then |
| 7322 | V_CCOPT="$V_CCOPT ${LBL_CFLAGS}" |
| 7323 | fi |
| 7324 | if test -f .devel ; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7325 | # |
| 7326 | # Skip all the warning option stuff on some compilers. |
| 7327 | # |
| 7328 | if test "$ac_lbl_cc_dont_try_gcc_dashW" != yes; then |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7329 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7330 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler fails when given an unknown warning option" >&5 |
| 7331 | $as_echo_n "checking whether the compiler fails when given an unknown warning option... " >&6; } |
| 7332 | save_CFLAGS="$CFLAGS" |
| 7333 | CFLAGS="$CFLAGS -Wxyzzy-this-will-never-succeed-xyzzy" |
| 7334 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 7335 | /* end confdefs.h. */ |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7336 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7337 | int |
| 7338 | main () |
| 7339 | { |
| 7340 | return 0 |
| 7341 | ; |
| 7342 | return 0; |
| 7343 | } |
| 7344 | _ACEOF |
| 7345 | if ac_fn_c_try_compile "$LINENO"; then : |
| 7346 | |
| 7347 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7348 | $as_echo "no" >&6; } |
| 7349 | # |
| 7350 | # We're assuming this is clang, where |
| 7351 | # -Werror=unknown-warning-option is the appropriate |
| 7352 | # option to force the compiler to fail. |
| 7353 | # |
| 7354 | ac_lbl_unknown_warning_option_error="-Werror=unknown-warning-option" |
| 7355 | |
| 7356 | else |
| 7357 | |
| 7358 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 7359 | $as_echo "yes" >&6; } |
| 7360 | |
| 7361 | fi |
| 7362 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 7363 | CFLAGS="$save_CFLAGS" |
| 7364 | |
| 7365 | |
| 7366 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports the -Wall option" >&5 |
| 7367 | $as_echo_n "checking whether the compiler supports the -Wall option... " >&6; } |
| 7368 | save_CFLAGS="$CFLAGS" |
| 7369 | CFLAGS="$CFLAGS $ac_lbl_unknown_warning_option_error -Wall" |
| 7370 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 7371 | /* end confdefs.h. */ |
| 7372 | |
| 7373 | int |
| 7374 | main () |
| 7375 | { |
| 7376 | return 0 |
| 7377 | ; |
| 7378 | return 0; |
| 7379 | } |
| 7380 | _ACEOF |
| 7381 | if ac_fn_c_try_compile "$LINENO"; then : |
| 7382 | |
| 7383 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 7384 | $as_echo "yes" >&6; } |
| 7385 | CFLAGS="$save_CFLAGS" |
| 7386 | V_CCOPT="$V_CCOPT -Wall" |
| 7387 | |
| 7388 | else |
| 7389 | |
| 7390 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7391 | $as_echo "no" >&6; } |
| 7392 | CFLAGS="$save_CFLAGS" |
| 7393 | |
| 7394 | fi |
| 7395 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 7396 | |
| 7397 | |
| 7398 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports the -Wmissing-prototypes option" >&5 |
| 7399 | $as_echo_n "checking whether the compiler supports the -Wmissing-prototypes option... " >&6; } |
| 7400 | save_CFLAGS="$CFLAGS" |
| 7401 | CFLAGS="$CFLAGS $ac_lbl_unknown_warning_option_error -Wmissing-prototypes" |
| 7402 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 7403 | /* end confdefs.h. */ |
| 7404 | |
| 7405 | int |
| 7406 | main () |
| 7407 | { |
| 7408 | return 0 |
| 7409 | ; |
| 7410 | return 0; |
| 7411 | } |
| 7412 | _ACEOF |
| 7413 | if ac_fn_c_try_compile "$LINENO"; then : |
| 7414 | |
| 7415 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 7416 | $as_echo "yes" >&6; } |
| 7417 | CFLAGS="$save_CFLAGS" |
| 7418 | V_CCOPT="$V_CCOPT -Wmissing-prototypes" |
| 7419 | |
| 7420 | else |
| 7421 | |
| 7422 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7423 | $as_echo "no" >&6; } |
| 7424 | CFLAGS="$save_CFLAGS" |
| 7425 | |
| 7426 | fi |
| 7427 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 7428 | |
| 7429 | |
| 7430 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports the -Wstrict-prototypes option" >&5 |
| 7431 | $as_echo_n "checking whether the compiler supports the -Wstrict-prototypes option... " >&6; } |
| 7432 | save_CFLAGS="$CFLAGS" |
| 7433 | CFLAGS="$CFLAGS $ac_lbl_unknown_warning_option_error -Wstrict-prototypes" |
| 7434 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 7435 | /* end confdefs.h. */ |
| 7436 | |
| 7437 | int |
| 7438 | main () |
| 7439 | { |
| 7440 | return 0 |
| 7441 | ; |
| 7442 | return 0; |
| 7443 | } |
| 7444 | _ACEOF |
| 7445 | if ac_fn_c_try_compile "$LINENO"; then : |
| 7446 | |
| 7447 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 7448 | $as_echo "yes" >&6; } |
| 7449 | CFLAGS="$save_CFLAGS" |
| 7450 | V_CCOPT="$V_CCOPT -Wstrict-prototypes" |
| 7451 | |
| 7452 | else |
| 7453 | |
| 7454 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7455 | $as_echo "no" >&6; } |
| 7456 | CFLAGS="$save_CFLAGS" |
| 7457 | |
| 7458 | fi |
| 7459 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 7460 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7461 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7462 | |
| 7463 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports generating dependencies" >&5 |
| 7464 | $as_echo_n "checking whether the compiler supports generating dependencies... " >&6; } |
| 7465 | if test "$GCC" = yes ; then |
| 7466 | # |
| 7467 | # GCC, or a compiler deemed to be GCC by AC_PROG_CC (even |
| 7468 | # though it's not); we assume that, in this case, the flag |
| 7469 | # would be -M. |
| 7470 | # |
| 7471 | ac_lbl_dependency_flag="-M" |
| 7472 | else |
| 7473 | # |
| 7474 | # Not GCC or a compiler deemed to be GCC; what platform is |
| 7475 | # this? (We're assuming that if the compiler isn't GCC |
| 7476 | # it's the compiler from the vendor of the OS; that won't |
| 7477 | # necessarily be true for x86 platforms, where it might be |
| 7478 | # the Intel C compiler.) |
| 7479 | # |
| 7480 | case "$host_os" in |
| 7481 | |
| 7482 | irix*|osf*|darwin*) |
| 7483 | # |
| 7484 | # MIPS C for IRIX, DEC C, and clang all use -M. |
| 7485 | # |
| 7486 | ac_lbl_dependency_flag="-M" |
| 7487 | ;; |
| 7488 | |
| 7489 | solaris*) |
| 7490 | # |
| 7491 | # Sun C uses -xM. |
| 7492 | # |
| 7493 | ac_lbl_dependency_flag="-xM" |
| 7494 | ;; |
| 7495 | |
| 7496 | hpux*) |
| 7497 | # |
| 7498 | # HP's older C compilers don't support this. |
| 7499 | # HP's newer C compilers support this with |
| 7500 | # either +M or +Make; the older compilers |
| 7501 | # interpret +M as something completely |
| 7502 | # different, so we use +Make so we don't |
| 7503 | # think it works with the older compilers. |
| 7504 | # |
| 7505 | ac_lbl_dependency_flag="+Make" |
| 7506 | ;; |
| 7507 | |
| 7508 | *) |
| 7509 | # |
| 7510 | # Not one of the above; assume no support for |
| 7511 | # generating dependencies. |
| 7512 | # |
| 7513 | ac_lbl_dependency_flag="" |
| 7514 | ;; |
| 7515 | esac |
| 7516 | fi |
| 7517 | |
| 7518 | # |
| 7519 | # Is ac_lbl_dependency_flag defined and, if so, does the compiler |
| 7520 | # complain about it? |
| 7521 | # |
| 7522 | # Note: clang doesn't seem to exit with an error status when handed |
| 7523 | # an unknown non-warning error, even if you pass it |
| 7524 | # -Werror=unknown-warning-option. However, it always supports |
| 7525 | # -M, so the fact that this test always succeeds with clang |
| 7526 | # isn't an issue. |
| 7527 | # |
| 7528 | if test ! -z "$ac_lbl_dependency_flag"; then |
| 7529 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 7530 | /* end confdefs.h. */ |
| 7531 | int main(void) { return 0; } |
| 7532 | _ACEOF |
| 7533 | echo "$CC" $ac_lbl_dependency_flag conftest.c >&5 |
| 7534 | if "$CC" $ac_lbl_dependency_flag conftest.c >/dev/null 2>&1; then |
| 7535 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, with $ac_lbl_dependency_flag" >&5 |
| 7536 | $as_echo "yes, with $ac_lbl_dependency_flag" >&6; } |
| 7537 | DEPENDENCY_CFLAG="$ac_lbl_dependency_flag" |
| 7538 | MKDEP='${srcdir}/mkdep' |
| 7539 | else |
| 7540 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7541 | $as_echo "no" >&6; } |
| 7542 | # |
| 7543 | # We can't run mkdep, so have "make depend" do |
| 7544 | # nothing. |
| 7545 | # |
| 7546 | MKDEP=: |
| 7547 | fi |
| 7548 | rm -rf conftest* |
| 7549 | else |
| 7550 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7551 | $as_echo "no" >&6; } |
| 7552 | # |
| 7553 | # We can't run mkdep, so have "make depend" do |
| 7554 | # nothing. |
| 7555 | # |
| 7556 | MKDEP=: |
| 7557 | fi |
| 7558 | |
| 7559 | |
| 7560 | |
| 7561 | # |
| 7562 | # We used to set -n32 for IRIX 6 when not using GCC (presumed |
| 7563 | # to mean that we're using MIPS C or MIPSpro C); it specified |
| 7564 | # the "new" faster 32-bit ABI, introduced in IRIX 6.2. I'm |
| 7565 | # not sure why that would be something to do *only* with a |
| 7566 | # .devel file; why should the ABI for which we produce code |
| 7567 | # depend on .devel? |
| 7568 | # |
| 7569 | os=`echo $host_os | sed -e 's/\([0-9][0-9]*\)[^0-9].*$/\1/'` |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7570 | name="lbl/os-$os.h" |
| 7571 | if test -f $name ; then |
| 7572 | ln -s $name os-proto.h |
| 7573 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7574 | $as_echo "#define HAVE_OS_PROTO_H 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7575 | |
| 7576 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7577 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: can't find $name" >&5 |
| 7578 | $as_echo "$as_me: WARNING: can't find $name" >&2;} |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7579 | fi |
| 7580 | fi |
| 7581 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7582 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sockaddr struct has the sa_len member" >&5 |
| 7583 | $as_echo_n "checking if sockaddr struct has the sa_len member... " >&6; } |
| 7584 | if ${ac_cv_lbl_sockaddr_has_sa_len+:} false; then : |
| 7585 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7586 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7587 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7588 | /* end confdefs.h. */ |
| 7589 | |
| 7590 | # include <sys/types.h> |
| 7591 | # include <sys/socket.h> |
| 7592 | int |
| 7593 | main () |
| 7594 | { |
| 7595 | u_int i = sizeof(((struct sockaddr *)0)->sa_len) |
| 7596 | ; |
| 7597 | return 0; |
| 7598 | } |
| 7599 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7600 | if ac_fn_c_try_compile "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7601 | ac_cv_lbl_sockaddr_has_sa_len=yes |
| 7602 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7603 | ac_cv_lbl_sockaddr_has_sa_len=no |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7604 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7605 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 7606 | fi |
| 7607 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7608 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_sockaddr_has_sa_len" >&5 |
| 7609 | $as_echo "$ac_cv_lbl_sockaddr_has_sa_len" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7610 | if test $ac_cv_lbl_sockaddr_has_sa_len = yes ; then |
| 7611 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7612 | $as_echo "#define HAVE_SOCKADDR_SA_LEN 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7613 | |
| 7614 | fi |
| 7615 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7616 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sockaddr_storage struct exists" >&5 |
| 7617 | $as_echo_n "checking if sockaddr_storage struct exists... " >&6; } |
| 7618 | if ${ac_cv_lbl_has_sockaddr_storage+:} false; then : |
| 7619 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7620 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7621 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7622 | /* end confdefs.h. */ |
| 7623 | |
| 7624 | # include <sys/types.h> |
| 7625 | # include <sys/socket.h> |
| 7626 | int |
| 7627 | main () |
| 7628 | { |
| 7629 | u_int i = sizeof (struct sockaddr_storage) |
| 7630 | ; |
| 7631 | return 0; |
| 7632 | } |
| 7633 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7634 | if ac_fn_c_try_compile "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7635 | ac_cv_lbl_has_sockaddr_storage=yes |
| 7636 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7637 | ac_cv_lbl_has_sockaddr_storage=no |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7638 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7639 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 7640 | fi |
| 7641 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7642 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_has_sockaddr_storage" >&5 |
| 7643 | $as_echo "$ac_cv_lbl_has_sockaddr_storage" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7644 | if test $ac_cv_lbl_has_sockaddr_storage = yes ; then |
| 7645 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7646 | $as_echo "#define HAVE_SOCKADDR_STORAGE 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7647 | |
| 7648 | fi |
| 7649 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7650 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dl_hp_ppa_info_t struct has dl_module_id_1 member" >&5 |
| 7651 | $as_echo_n "checking if dl_hp_ppa_info_t struct has dl_module_id_1 member... " >&6; } |
| 7652 | if ${ac_cv_lbl_dl_hp_ppa_info_t_has_dl_module_id_1+:} false; then : |
| 7653 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7654 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7655 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7656 | /* end confdefs.h. */ |
| 7657 | |
| 7658 | # include <sys/types.h> |
| 7659 | # include <sys/dlpi.h> |
| 7660 | # include <sys/dlpi_ext.h> |
| 7661 | int |
| 7662 | main () |
| 7663 | { |
| 7664 | u_int i = sizeof(((dl_hp_ppa_info_t *)0)->dl_module_id_1) |
| 7665 | ; |
| 7666 | return 0; |
| 7667 | } |
| 7668 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7669 | if ac_fn_c_try_compile "$LINENO"; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7670 | ac_cv_lbl_dl_hp_ppa_info_t_has_dl_module_id_1=yes |
| 7671 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7672 | ac_cv_lbl_dl_hp_ppa_info_t_has_dl_module_id_1=no |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7673 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7674 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 7675 | fi |
| 7676 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7677 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_dl_hp_ppa_info_t_has_dl_module_id_1" >&5 |
| 7678 | $as_echo "$ac_cv_lbl_dl_hp_ppa_info_t_has_dl_module_id_1" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7679 | if test $ac_cv_lbl_dl_hp_ppa_info_t_has_dl_module_id_1 = yes ; then |
| 7680 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7681 | $as_echo "#define HAVE_HP_PPA_INFO_T_DL_MODULE_ID_1 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7682 | |
| 7683 | fi |
| 7684 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7685 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if unaligned accesses fail" >&5 |
| 7686 | $as_echo_n "checking if unaligned accesses fail... " >&6; } |
| 7687 | if ${ac_cv_lbl_unaligned_fail+:} false; then : |
| 7688 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7689 | else |
| 7690 | case "$host_cpu" in |
| 7691 | |
| 7692 | # |
| 7693 | # These are CPU types where: |
| 7694 | # |
| 7695 | # the CPU faults on an unaligned access, but at least some |
| 7696 | # OSes that support that CPU catch the fault and simulate |
| 7697 | # the unaligned access (e.g., Alpha/{Digital,Tru64} UNIX) - |
| 7698 | # the simulation is slow, so we don't want to use it; |
| 7699 | # |
| 7700 | # the CPU, I infer (from the old |
| 7701 | # |
| 7702 | # XXX: should also check that they don't do weird things (like on arm) |
| 7703 | # |
| 7704 | # comment) doesn't fault on unaligned accesses, but doesn't |
| 7705 | # do a normal unaligned fetch, either (e.g., presumably, ARM); |
| 7706 | # |
| 7707 | # for whatever reason, the test program doesn't work |
| 7708 | # (this has been claimed to be the case for several of those |
| 7709 | # CPUs - I don't know what the problem is; the problem |
| 7710 | # was reported as "the test program dumps core" for SuperH, |
| 7711 | # but that's what the test program is *supposed* to do - |
| 7712 | # it dumps core before it writes anything, so the test |
| 7713 | # for an empty output file should find an empty output |
| 7714 | # file and conclude that unaligned accesses don't work). |
| 7715 | # |
| 7716 | # This run-time test won't work if you're cross-compiling, so |
| 7717 | # in order to support cross-compiling for a particular CPU, |
| 7718 | # we have to wire in the list of CPU types anyway, as far as |
| 7719 | # I know, so perhaps we should just have a set of CPUs on |
| 7720 | # which we know it doesn't work, a set of CPUs on which we |
| 7721 | # know it does work, and have the script just fail on other |
| 7722 | # cpu types and update it when such a failure occurs. |
| 7723 | # |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7724 | alpha*|arm*|bfin*|hp*|mips*|sh*|sparc*|ia64|nv1) |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7725 | ac_cv_lbl_unaligned_fail=yes |
| 7726 | ;; |
| 7727 | |
| 7728 | *) |
| 7729 | cat >conftest.c <<EOF |
| 7730 | # include <sys/types.h> |
| 7731 | # include <sys/wait.h> |
| 7732 | # include <stdio.h> |
| 7733 | unsigned char a[5] = { 1, 2, 3, 4, 5 }; |
| 7734 | main() { |
| 7735 | unsigned int i; |
| 7736 | pid_t pid; |
| 7737 | int status; |
| 7738 | /* avoid "core dumped" message */ |
| 7739 | pid = fork(); |
| 7740 | if (pid < 0) |
| 7741 | exit(2); |
| 7742 | if (pid > 0) { |
| 7743 | /* parent */ |
| 7744 | pid = waitpid(pid, &status, 0); |
| 7745 | if (pid < 0) |
| 7746 | exit(3); |
| 7747 | exit(!WIFEXITED(status)); |
| 7748 | } |
| 7749 | /* child */ |
| 7750 | i = *(unsigned int *)&a[1]; |
| 7751 | printf("%d\n", i); |
| 7752 | exit(0); |
| 7753 | } |
| 7754 | EOF |
| 7755 | ${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS \ |
| 7756 | conftest.c $LIBS >/dev/null 2>&1 |
| 7757 | if test ! -x conftest ; then |
| 7758 | ac_cv_lbl_unaligned_fail=yes |
| 7759 | else |
| 7760 | ./conftest >conftest.out |
| 7761 | if test ! -s conftest.out ; then |
| 7762 | ac_cv_lbl_unaligned_fail=yes |
| 7763 | else |
| 7764 | ac_cv_lbl_unaligned_fail=no |
| 7765 | fi |
| 7766 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7767 | rm -f -r conftest* core core.conftest |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7768 | ;; |
| 7769 | esac |
| 7770 | fi |
| 7771 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7772 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_unaligned_fail" >&5 |
| 7773 | $as_echo "$ac_cv_lbl_unaligned_fail" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7774 | if test $ac_cv_lbl_unaligned_fail = yes ; then |
| 7775 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7776 | $as_echo "#define LBL_ALIGN 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7777 | |
| 7778 | fi |
| 7779 | |
| 7780 | # |
| 7781 | # Makefile.in includes rules to generate version.h, so we assume |
| 7782 | # that it will be generated if autoconf is used. |
| 7783 | # |
| 7784 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7785 | $as_echo "#define HAVE_VERSION_H 1" >>confdefs.h |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 7786 | |
| 7787 | |
| 7788 | rm -f net |
| 7789 | ln -s ${srcdir}/bpf/net net |
| 7790 | |
| 7791 | |
| 7792 | |
| 7793 | |
| 7794 | |
| 7795 | |
| 7796 | |
| 7797 | |
| 7798 | |
| 7799 | |
| 7800 | |
| 7801 | |
| 7802 | |
| 7803 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 7804 | |
| 7805 | |
| 7806 | |
| 7807 | |
| 7808 | |
| 7809 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for USB sniffing support" >&5 |
| 7810 | $as_echo_n "checking for USB sniffing support... " >&6; } |
| 7811 | case "$host_os" in |
| 7812 | linux*) |
| 7813 | |
| 7814 | $as_echo "#define PCAP_SUPPORT_USB 1" >>confdefs.h |
| 7815 | |
| 7816 | USB_SRC=pcap-usb-linux.c |
| 7817 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 7818 | $as_echo "yes" >&6; } |
| 7819 | ac_usb_dev_name=`udevinfo -q name -p /sys/class/usb_device/usbmon 2>/dev/null` |
| 7820 | if test $? -ne 0 ; then |
| 7821 | ac_usb_dev_name="usbmon" |
| 7822 | fi |
| 7823 | |
| 7824 | cat >>confdefs.h <<_ACEOF |
| 7825 | #define LINUX_USB_MON_DEV "/dev/$ac_usb_dev_name" |
| 7826 | _ACEOF |
| 7827 | |
| 7828 | { $as_echo "$as_me:${as_lineno-$LINENO}: Device for USB sniffing is /dev/$ac_usb_dev_name" >&5 |
| 7829 | $as_echo "$as_me: Device for USB sniffing is /dev/$ac_usb_dev_name" >&6;} |
| 7830 | # |
| 7831 | # Do we have a version of <linux/compiler.h> available? |
| 7832 | # If so, we might need it for <linux/usbdevice_fs.h>. |
| 7833 | # |
| 7834 | for ac_header in linux/compiler.h |
| 7835 | do : |
| 7836 | ac_fn_c_check_header_mongrel "$LINENO" "linux/compiler.h" "ac_cv_header_linux_compiler_h" "$ac_includes_default" |
| 7837 | if test "x$ac_cv_header_linux_compiler_h" = xyes; then : |
| 7838 | cat >>confdefs.h <<_ACEOF |
| 7839 | #define HAVE_LINUX_COMPILER_H 1 |
| 7840 | _ACEOF |
| 7841 | |
| 7842 | fi |
| 7843 | |
| 7844 | done |
| 7845 | |
| 7846 | if test "$ac_cv_header_linux_compiler_h" = yes; then |
| 7847 | # |
| 7848 | # Yes - include it when testing for <linux/usbdevice_fs.h>. |
| 7849 | # |
| 7850 | for ac_header in linux/usbdevice_fs.h |
| 7851 | do : |
| 7852 | ac_fn_c_check_header_compile "$LINENO" "linux/usbdevice_fs.h" "ac_cv_header_linux_usbdevice_fs_h" "#include <linux/compiler.h> |
| 7853 | " |
| 7854 | if test "x$ac_cv_header_linux_usbdevice_fs_h" = xyes; then : |
| 7855 | cat >>confdefs.h <<_ACEOF |
| 7856 | #define HAVE_LINUX_USBDEVICE_FS_H 1 |
| 7857 | _ACEOF |
| 7858 | |
| 7859 | fi |
| 7860 | |
| 7861 | done |
| 7862 | |
| 7863 | else |
| 7864 | for ac_header in linux/usbdevice_fs.h |
| 7865 | do : |
| 7866 | ac_fn_c_check_header_mongrel "$LINENO" "linux/usbdevice_fs.h" "ac_cv_header_linux_usbdevice_fs_h" "$ac_includes_default" |
| 7867 | if test "x$ac_cv_header_linux_usbdevice_fs_h" = xyes; then : |
| 7868 | cat >>confdefs.h <<_ACEOF |
| 7869 | #define HAVE_LINUX_USBDEVICE_FS_H 1 |
| 7870 | _ACEOF |
| 7871 | |
| 7872 | fi |
| 7873 | |
| 7874 | done |
| 7875 | |
| 7876 | fi |
| 7877 | if test "$ac_cv_header_linux_usbdevice_fs_h" = yes; then |
| 7878 | # |
| 7879 | # OK, does it define bRequestType? Older versions of the kernel |
| 7880 | # define fields with names like "requesttype, "request", and |
| 7881 | # "value", rather than "bRequestType", "bRequest", and |
| 7882 | # "wValue". |
| 7883 | # |
| 7884 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if usbdevfs_ctrltransfer struct has bRequestType member" >&5 |
| 7885 | $as_echo_n "checking if usbdevfs_ctrltransfer struct has bRequestType member... " >&6; } |
| 7886 | if ${ac_cv_usbdevfs_ctrltransfer_has_bRequestType+:} false; then : |
| 7887 | $as_echo_n "(cached) " >&6 |
| 7888 | else |
| 7889 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 7890 | /* end confdefs.h. */ |
| 7891 | |
| 7892 | $ac_includes_default |
| 7893 | #ifdef HAVE_SYS_BITYPES_H |
| 7894 | #include <sys/bitypes.h> |
| 7895 | #endif |
| 7896 | #ifdef HAVE_LINUX_COMPILER_H |
| 7897 | #include <linux/compiler.h> |
| 7898 | #endif |
| 7899 | #include <linux/usbdevice_fs.h> |
| 7900 | int |
| 7901 | main () |
| 7902 | { |
| 7903 | u_int i = sizeof(((struct usbdevfs_ctrltransfer *)0)->bRequestType) |
| 7904 | ; |
| 7905 | return 0; |
| 7906 | } |
| 7907 | _ACEOF |
| 7908 | if ac_fn_c_try_compile "$LINENO"; then : |
| 7909 | ac_cv_usbdevfs_ctrltransfer_has_bRequestType=yes |
| 7910 | else |
| 7911 | ac_cv_usbdevfs_ctrltransfer_has_bRequestType=no |
| 7912 | fi |
| 7913 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 7914 | fi |
| 7915 | |
| 7916 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_usbdevfs_ctrltransfer_has_bRequestType" >&5 |
| 7917 | $as_echo "$ac_cv_usbdevfs_ctrltransfer_has_bRequestType" >&6; } |
| 7918 | if test $ac_cv_usbdevfs_ctrltransfer_has_bRequestType = yes ; then |
| 7919 | |
| 7920 | $as_echo "#define HAVE_USBDEVFS_CTRLTRANSFER_BREQUESTTYPE 1" >>confdefs.h |
| 7921 | |
| 7922 | fi |
| 7923 | fi |
| 7924 | ;; |
| 7925 | *) |
| 7926 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7927 | $as_echo "no" >&6; } |
| 7928 | ;; |
| 7929 | esac |
| 7930 | |
| 7931 | |
| 7932 | |
| 7933 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the platform could support netfilter sniffing" >&5 |
| 7934 | $as_echo_n "checking whether the platform could support netfilter sniffing... " >&6; } |
| 7935 | case "$host_os" in |
| 7936 | linux*) |
| 7937 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 7938 | $as_echo "yes" >&6; } |
| 7939 | # |
| 7940 | # Life's too short to deal with trying to get this to compile |
| 7941 | # if you don't get the right types defined with |
| 7942 | # __KERNEL_STRICT_NAMES getting defined by some other include. |
| 7943 | # |
| 7944 | # Check whether the includes Just Work. If not, don't turn on |
| 7945 | # netfilter support. |
| 7946 | # |
| 7947 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we can compile the netfilter support" >&5 |
| 7948 | $as_echo_n "checking whether we can compile the netfilter support... " >&6; } |
| 7949 | if ${ac_cv_netfilter_can_compile+:} false; then : |
| 7950 | $as_echo_n "(cached) " >&6 |
| 7951 | else |
| 7952 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 7953 | /* end confdefs.h. */ |
| 7954 | |
| 7955 | $ac_includes_default |
| 7956 | #include <sys/socket.h> |
| 7957 | #include <netinet/in.h> |
| 7958 | #include <linux/types.h> |
| 7959 | |
| 7960 | #include <linux/netlink.h> |
| 7961 | #include <linux/netfilter.h> |
| 7962 | #include <linux/netfilter/nfnetlink.h> |
| 7963 | #include <linux/netfilter/nfnetlink_log.h> |
| 7964 | #include <linux/netfilter/nfnetlink_queue.h> |
| 7965 | int |
| 7966 | main () |
| 7967 | { |
| 7968 | |
| 7969 | ; |
| 7970 | return 0; |
| 7971 | } |
| 7972 | _ACEOF |
| 7973 | if ac_fn_c_try_compile "$LINENO"; then : |
| 7974 | ac_cv_netfilter_can_compile=yes |
| 7975 | else |
| 7976 | ac_cv_netfilter_can_compile=no |
| 7977 | fi |
| 7978 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 7979 | fi |
| 7980 | |
| 7981 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_netfilter_can_compile" >&5 |
| 7982 | $as_echo "$ac_cv_netfilter_can_compile" >&6; } |
| 7983 | if test $ac_cv_netfilter_can_compile = yes ; then |
| 7984 | |
| 7985 | $as_echo "#define PCAP_SUPPORT_NETFILTER 1" >>confdefs.h |
| 7986 | |
| 7987 | NETFILTER_SRC=pcap-netfilter-linux.c |
| 7988 | fi |
| 7989 | ;; |
| 7990 | *) |
| 7991 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7992 | $as_echo "no" >&6; } |
| 7993 | ;; |
| 7994 | esac |
| 7995 | |
| 7996 | |
| 7997 | |
| 7998 | # Check whether --enable-bluetooth was given. |
| 7999 | if test "${enable_bluetooth+set}" = set; then : |
| 8000 | enableval=$enable_bluetooth; |
| 8001 | else |
| 8002 | enable_bluetooth=yes |
| 8003 | fi |
| 8004 | |
| 8005 | |
| 8006 | if test "x$enable_bluetooth" != "xno" ; then |
| 8007 | case "$host_os" in |
| 8008 | linux*) |
| 8009 | ac_fn_c_check_header_mongrel "$LINENO" "bluetooth/bluetooth.h" "ac_cv_header_bluetooth_bluetooth_h" "$ac_includes_default" |
| 8010 | if test "x$ac_cv_header_bluetooth_bluetooth_h" = xyes; then : |
| 8011 | |
| 8012 | |
| 8013 | $as_echo "#define PCAP_SUPPORT_BT 1" >>confdefs.h |
| 8014 | |
| 8015 | BT_SRC=pcap-bt-linux.c |
| 8016 | { $as_echo "$as_me:${as_lineno-$LINENO}: Bluetooth sniffing is supported" >&5 |
| 8017 | $as_echo "$as_me: Bluetooth sniffing is supported" >&6;} |
| 8018 | |
| 8019 | # |
| 8020 | # OK, does struct sockaddr_hci have an hci_channel |
| 8021 | # member? |
| 8022 | # |
| 8023 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if struct sockaddr_hci has hci_channel member" >&5 |
| 8024 | $as_echo_n "checking if struct sockaddr_hci has hci_channel member... " >&6; } |
| 8025 | if ${ac_cv_lbl_sockaddr_hci_has_hci_channel+:} false; then : |
| 8026 | $as_echo_n "(cached) " >&6 |
| 8027 | else |
| 8028 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 8029 | /* end confdefs.h. */ |
| 8030 | |
| 8031 | #include <bluetooth/bluetooth.h> |
| 8032 | #include <bluetooth/hci.h> |
| 8033 | |
| 8034 | int |
| 8035 | main () |
| 8036 | { |
| 8037 | u_int i = sizeof(((struct sockaddr_hci *)0)->hci_channel) |
| 8038 | ; |
| 8039 | return 0; |
| 8040 | } |
| 8041 | _ACEOF |
| 8042 | if ac_fn_c_try_compile "$LINENO"; then : |
| 8043 | ac_cv_lbl_sockaddr_hci_has_hci_channel=yes |
| 8044 | else |
| 8045 | ac_cv_lbl_sockaddr_hci_has_hci_channel=no |
| 8046 | fi |
| 8047 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 8048 | fi |
| 8049 | |
| 8050 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_sockaddr_hci_has_hci_channel" >&5 |
| 8051 | $as_echo "$ac_cv_lbl_sockaddr_hci_has_hci_channel" >&6; } |
| 8052 | if test $ac_cv_lbl_sockaddr_hci_has_hci_channel = yes ; then |
| 8053 | |
| 8054 | $as_echo "#define SOCKADDR_HCI_HAS_HCI_CHANNEL /**/" >>confdefs.h |
| 8055 | |
| 8056 | fi |
| 8057 | |
| 8058 | else |
| 8059 | { $as_echo "$as_me:${as_lineno-$LINENO}: Bluetooth sniffing is not supported; install bluez-lib devel to enable it" >&5 |
| 8060 | $as_echo "$as_me: Bluetooth sniffing is not supported; install bluez-lib devel to enable it" >&6;} |
| 8061 | |
| 8062 | fi |
| 8063 | |
| 8064 | |
| 8065 | ;; |
| 8066 | *) |
| 8067 | { $as_echo "$as_me:${as_lineno-$LINENO}: no Bluetooth sniffing support implemented for $host_os" >&5 |
| 8068 | $as_echo "$as_me: no Bluetooth sniffing support implemented for $host_os" >&6;} |
| 8069 | ;; |
| 8070 | esac |
| 8071 | |
| 8072 | |
| 8073 | fi |
| 8074 | |
| 8075 | # Check whether --enable-canusb was given. |
| 8076 | if test "${enable_canusb+set}" = set; then : |
| 8077 | enableval=$enable_canusb; |
| 8078 | else |
| 8079 | enable_canusb=yes |
| 8080 | fi |
| 8081 | |
| 8082 | |
| 8083 | if test "x$enable_canusb" != "xno" ; then |
| 8084 | case "$host_os" in |
| 8085 | linux*) |
| 8086 | ac_fn_c_check_header_mongrel "$LINENO" "libusb-1.0/libusb.h" "ac_cv_header_libusb_1_0_libusb_h" "$ac_includes_default" |
| 8087 | if test "x$ac_cv_header_libusb_1_0_libusb_h" = xyes; then : |
| 8088 | |
| 8089 | |
| 8090 | $as_echo "#define PCAP_SUPPORT_CANUSB 1" >>confdefs.h |
| 8091 | |
| 8092 | CANUSB_SRC=pcap-canusb-linux.c |
| 8093 | LIBS="-lusb-1.0 -lpthread $LIBS" |
| 8094 | { $as_echo "$as_me:${as_lineno-$LINENO}: canusb sniffing is supported" >&5 |
| 8095 | $as_echo "$as_me: canusb sniffing is supported" >&6;} |
| 8096 | |
| 8097 | else |
| 8098 | { $as_echo "$as_me:${as_lineno-$LINENO}: canusb sniffing is not supported; install libusb1.0 lib devel to enable it" >&5 |
| 8099 | $as_echo "$as_me: canusb sniffing is not supported; install libusb1.0 lib devel to enable it" >&6;} |
| 8100 | |
| 8101 | fi |
| 8102 | |
| 8103 | |
| 8104 | ;; |
| 8105 | *) |
| 8106 | { $as_echo "$as_me:${as_lineno-$LINENO}: no canusb support implemented for $host_os" >&5 |
| 8107 | $as_echo "$as_me: no canusb support implemented for $host_os" >&6;} |
| 8108 | ;; |
| 8109 | esac |
| 8110 | |
| 8111 | |
| 8112 | fi |
| 8113 | |
| 8114 | # Check whether --enable-can was given. |
| 8115 | if test "${enable_can+set}" = set; then : |
| 8116 | enableval=$enable_can; |
| 8117 | else |
| 8118 | enable_can=yes |
| 8119 | fi |
| 8120 | |
| 8121 | |
| 8122 | if test "x$enable_can" != "xno" ; then |
| 8123 | case "$host_os" in |
| 8124 | linux*) |
| 8125 | ac_fn_c_check_header_compile "$LINENO" "linux/can.h" "ac_cv_header_linux_can_h" "#include <sys/socket.h> |
| 8126 | |
| 8127 | " |
| 8128 | if test "x$ac_cv_header_linux_can_h" = xyes; then : |
| 8129 | |
| 8130 | $as_echo "#define PCAP_SUPPORT_CAN 1" >>confdefs.h |
| 8131 | |
| 8132 | CAN_SRC=pcap-can-linux.c |
| 8133 | { $as_echo "$as_me:${as_lineno-$LINENO}: CAN sniffing is supported" >&5 |
| 8134 | $as_echo "$as_me: CAN sniffing is supported" >&6;} |
| 8135 | else |
| 8136 | { $as_echo "$as_me:${as_lineno-$LINENO}: CAN sniffing is not supported" >&5 |
| 8137 | $as_echo "$as_me: CAN sniffing is not supported" >&6;} |
| 8138 | fi |
| 8139 | |
| 8140 | |
| 8141 | ;; |
| 8142 | *) |
| 8143 | { $as_echo "$as_me:${as_lineno-$LINENO}: no CAN sniffing support implemented for $host_os" >&5 |
| 8144 | $as_echo "$as_me: no CAN sniffing support implemented for $host_os" >&6;} |
| 8145 | ;; |
| 8146 | esac |
| 8147 | |
| 8148 | |
| 8149 | fi |
| 8150 | |
| 8151 | # Check whether --enable-dbus was given. |
| 8152 | if test "${enable_dbus+set}" = set; then : |
| 8153 | enableval=$enable_dbus; |
| 8154 | else |
| 8155 | enable_dbus=ifavailable |
| 8156 | fi |
| 8157 | |
| 8158 | |
| 8159 | if test "x$enable_dbus" != "xno"; then |
| 8160 | if test "x$enable_dbus" = "xyes"; then |
| 8161 | case "$host_os" in |
| 8162 | |
| 8163 | darwin*) |
| 8164 | # |
| 8165 | # https://bugs.freedesktop.org/show_bug.cgi?id=74029 |
| 8166 | # |
| 8167 | as_fn_error $? "Due to freedesktop.org bug 74029, D-Bus capture support is not available on OS X" "$LINENO" 5 |
| 8168 | ;; |
| 8169 | esac |
| 8170 | else |
| 8171 | case "$host_os" in |
| 8172 | |
| 8173 | darwin*) |
| 8174 | # |
| 8175 | # https://bugs.freedesktop.org/show_bug.cgi?id=74029 |
| 8176 | # |
| 8177 | ;; |
| 8178 | |
| 8179 | *) |
| 8180 | # Extract the first word of "pkg-config", so it can be a program name with args. |
| 8181 | set dummy pkg-config; ac_word=$2 |
| 8182 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 8183 | $as_echo_n "checking for $ac_word... " >&6; } |
| 8184 | if ${ac_cv_prog_PKGCONFIG+:} false; then : |
| 8185 | $as_echo_n "(cached) " >&6 |
| 8186 | else |
| 8187 | if test -n "$PKGCONFIG"; then |
| 8188 | ac_cv_prog_PKGCONFIG="$PKGCONFIG" # Let the user override the test. |
| 8189 | else |
| 8190 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 8191 | for as_dir in $PATH |
| 8192 | do |
| 8193 | IFS=$as_save_IFS |
| 8194 | test -z "$as_dir" && as_dir=. |
| 8195 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 8196 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
| 8197 | ac_cv_prog_PKGCONFIG="pkg-config" |
| 8198 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
| 8199 | break 2 |
| 8200 | fi |
| 8201 | done |
| 8202 | done |
| 8203 | IFS=$as_save_IFS |
| 8204 | |
| 8205 | test -z "$ac_cv_prog_PKGCONFIG" && ac_cv_prog_PKGCONFIG="no" |
| 8206 | fi |
| 8207 | fi |
| 8208 | PKGCONFIG=$ac_cv_prog_PKGCONFIG |
| 8209 | if test -n "$PKGCONFIG"; then |
| 8210 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5 |
| 8211 | $as_echo "$PKGCONFIG" >&6; } |
| 8212 | else |
| 8213 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8214 | $as_echo "no" >&6; } |
| 8215 | fi |
| 8216 | |
| 8217 | |
| 8218 | if test "x$PKGCONFIG" != "xno"; then |
| 8219 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for D-Bus" >&5 |
| 8220 | $as_echo_n "checking for D-Bus... " >&6; } |
| 8221 | if "$PKGCONFIG" dbus-1; then |
| 8222 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 8223 | $as_echo "yes" >&6; } |
| 8224 | DBUS_CFLAGS=`"$PKGCONFIG" --cflags dbus-1` |
| 8225 | DBUS_LIBS=`"$PKGCONFIG" --libs dbus-1` |
| 8226 | save_CFLAGS="$CFLAGS" |
| 8227 | save_LIBS="$LIBS" |
| 8228 | CFLAGS="$CFLAGS $DBUS_CFLAGS" |
| 8229 | LIBS="$LIBS $DBUS_LIBS" |
| 8230 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the D-Bus library defines dbus_connection_read_write" >&5 |
| 8231 | $as_echo_n "checking whether the D-Bus library defines dbus_connection_read_write... " >&6; } |
| 8232 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 8233 | /* end confdefs.h. */ |
| 8234 | #include <string.h> |
| 8235 | |
| 8236 | #include <time.h> |
| 8237 | #include <sys/time.h> |
| 8238 | |
| 8239 | #include <dbus/dbus.h> |
| 8240 | int |
| 8241 | main () |
| 8242 | { |
| 8243 | return dbus_connection_read_write(NULL, 0); |
| 8244 | ; |
| 8245 | return 0; |
| 8246 | } |
| 8247 | _ACEOF |
| 8248 | if ac_fn_c_try_link "$LINENO"; then : |
| 8249 | |
| 8250 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 8251 | $as_echo "yes" >&6; } |
| 8252 | |
| 8253 | $as_echo "#define PCAP_SUPPORT_DBUS 1" >>confdefs.h |
| 8254 | |
| 8255 | DBUS_SRC=pcap-dbus.c |
| 8256 | V_INCLS="$V_INCLS $DBUS_CFLAGS" |
| 8257 | |
| 8258 | else |
| 8259 | |
| 8260 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8261 | $as_echo "no" >&6; } |
| 8262 | if test "x$enable_dbus" = "xyes"; then |
| 8263 | as_fn_error $? "--enable-dbus was given, but the D-Bus library doesn't define dbus_connection_read_write()" "$LINENO" 5 |
| 8264 | fi |
| 8265 | LIBS="$save_LIBS" |
| 8266 | |
| 8267 | fi |
| 8268 | rm -f core conftest.err conftest.$ac_objext \ |
| 8269 | conftest$ac_exeext conftest.$ac_ext |
| 8270 | CFLAGS="$save_CFLAGS" |
| 8271 | else |
| 8272 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8273 | $as_echo "no" >&6; } |
| 8274 | if test "x$enable_dbus" = "xyes"; then |
| 8275 | as_fn_error $? "--enable-dbus was given, but the dbus-1 package is not installed" "$LINENO" 5 |
| 8276 | fi |
| 8277 | fi |
| 8278 | fi |
| 8279 | ;; |
| 8280 | esac |
| 8281 | fi |
| 8282 | |
| 8283 | |
| 8284 | fi |
| 8285 | |
| 8286 | case "$host_os" in |
| 8287 | linux*) |
| 8288 | for ac_header in linux/net_tstamp.h |
| 8289 | do : |
| 8290 | ac_fn_c_check_header_mongrel "$LINENO" "linux/net_tstamp.h" "ac_cv_header_linux_net_tstamp_h" "$ac_includes_default" |
| 8291 | if test "x$ac_cv_header_linux_net_tstamp_h" = xyes; then : |
| 8292 | cat >>confdefs.h <<_ACEOF |
| 8293 | #define HAVE_LINUX_NET_TSTAMP_H 1 |
| 8294 | _ACEOF |
| 8295 | |
| 8296 | fi |
| 8297 | |
| 8298 | done |
| 8299 | |
| 8300 | ;; |
| 8301 | *) |
| 8302 | { $as_echo "$as_me:${as_lineno-$LINENO}: no hardware timestamp support implemented for $host_os" >&5 |
| 8303 | $as_echo "$as_me: no hardware timestamp support implemented for $host_os" >&6;} |
| 8304 | ;; |
| 8305 | esac |
| 8306 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8307 | # Find a good install program. We prefer a C program (faster), |
| 8308 | # so one script is as good as another. But avoid the broken or |
| 8309 | # incompatible versions: |
| 8310 | # SysV /etc/install, /usr/sbin/install |
| 8311 | # SunOS /usr/etc/install |
| 8312 | # IRIX /sbin/install |
| 8313 | # AIX /bin/install |
| 8314 | # AmigaOS /C/install, which installs bootblocks on floppy discs |
| 8315 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag |
| 8316 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args |
| 8317 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" |
| 8318 | # OS/2's system install, which has a completely different semantic |
| 8319 | # ./install, which can be erroneously created by make from ./install.sh. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8320 | # Reject install programs that cannot install multiple files. |
| 8321 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 |
| 8322 | $as_echo_n "checking for a BSD-compatible install... " >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8323 | if test -z "$INSTALL"; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8324 | if ${ac_cv_path_install+:} false; then : |
| 8325 | $as_echo_n "(cached) " >&6 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8326 | else |
| 8327 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 8328 | for as_dir in $PATH |
| 8329 | do |
| 8330 | IFS=$as_save_IFS |
| 8331 | test -z "$as_dir" && as_dir=. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8332 | # Account for people who put trailing slashes in PATH elements. |
| 8333 | case $as_dir/ in #(( |
| 8334 | ./ | .// | /[cC]/* | \ |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8335 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8336 | ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8337 | /usr/ucb/* ) ;; |
| 8338 | *) |
| 8339 | # OSF1 and SCO ODT 3.0 have their own names for install. |
| 8340 | # Don't use installbsd from OSF since it installs stuff as root |
| 8341 | # by default. |
| 8342 | for ac_prog in ginstall scoinst install; do |
| 8343 | for ac_exec_ext in '' $ac_executable_extensions; do |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8344 | if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8345 | if test $ac_prog = install && |
| 8346 | grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then |
| 8347 | # AIX install. It has an incompatible calling convention. |
| 8348 | : |
| 8349 | elif test $ac_prog = install && |
| 8350 | grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then |
| 8351 | # program-specific install script used by HP pwplus--don't use. |
| 8352 | : |
| 8353 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8354 | rm -rf conftest.one conftest.two conftest.dir |
| 8355 | echo one > conftest.one |
| 8356 | echo two > conftest.two |
| 8357 | mkdir conftest.dir |
| 8358 | if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && |
| 8359 | test -s conftest.one && test -s conftest.two && |
| 8360 | test -s conftest.dir/conftest.one && |
| 8361 | test -s conftest.dir/conftest.two |
| 8362 | then |
| 8363 | ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" |
| 8364 | break 3 |
| 8365 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8366 | fi |
| 8367 | fi |
| 8368 | done |
| 8369 | done |
| 8370 | ;; |
| 8371 | esac |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8372 | |
| 8373 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8374 | IFS=$as_save_IFS |
| 8375 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8376 | rm -rf conftest.one conftest.two conftest.dir |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8377 | |
| 8378 | fi |
| 8379 | if test "${ac_cv_path_install+set}" = set; then |
| 8380 | INSTALL=$ac_cv_path_install |
| 8381 | else |
| 8382 | # As a last resort, use the slow shell script. Don't cache a |
| 8383 | # value for INSTALL within a source directory, because that will |
| 8384 | # break other packages using the cache if that directory is |
| 8385 | # removed, or if the value is a relative name. |
| 8386 | INSTALL=$ac_install_sh |
| 8387 | fi |
| 8388 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8389 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 |
| 8390 | $as_echo "$INSTALL" >&6; } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8391 | |
| 8392 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. |
| 8393 | # It thinks the first close brace ends the variable substitution. |
| 8394 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' |
| 8395 | |
| 8396 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' |
| 8397 | |
| 8398 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' |
| 8399 | |
| 8400 | |
| 8401 | ac_config_headers="$ac_config_headers config.h" |
| 8402 | |
| 8403 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8404 | ac_config_commands="$ac_config_commands default-1" |
| 8405 | |
| 8406 | ac_config_files="$ac_config_files Makefile pcap-filter.manmisc pcap-linktype.manmisc pcap-tstamp.manmisc pcap-savefile.manfile pcap.3pcap pcap_compile.3pcap pcap_datalink.3pcap pcap_dump_open.3pcap pcap_get_tstamp_precision.3pcap pcap_list_datalinks.3pcap pcap_list_tstamp_types.3pcap pcap_open_dead.3pcap pcap_open_offline.3pcap pcap_set_tstamp_precision.3pcap pcap_set_tstamp_type.3pcap" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8407 | |
| 8408 | cat >confcache <<\_ACEOF |
| 8409 | # This file is a shell script that caches the results of configure |
| 8410 | # tests run on this system so they can be shared between configure |
| 8411 | # scripts and configure runs, see configure's option --config-cache. |
| 8412 | # It is not useful on other systems. If it contains results you don't |
| 8413 | # want to keep, you may remove or edit it. |
| 8414 | # |
| 8415 | # config.status only pays attention to the cache file if you give it |
| 8416 | # the --recheck option to rerun configure. |
| 8417 | # |
| 8418 | # `ac_cv_env_foo' variables (set or unset) will be overridden when |
| 8419 | # loading this file, other *unset* `ac_cv_foo' will be assigned the |
| 8420 | # following values. |
| 8421 | |
| 8422 | _ACEOF |
| 8423 | |
| 8424 | # The following way of writing the cache mishandles newlines in values, |
| 8425 | # but we know of no workaround that is simple, portable, and efficient. |
| 8426 | # So, we kill variables containing newlines. |
| 8427 | # Ultrix sh set writes to stderr and can't be redirected directly, |
| 8428 | # and sets the high bit in the cache file unless we assign to the vars. |
| 8429 | ( |
| 8430 | for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do |
| 8431 | eval ac_val=\$$ac_var |
| 8432 | case $ac_val in #( |
| 8433 | *${as_nl}*) |
| 8434 | case $ac_var in #( |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8435 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 |
| 8436 | $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8437 | esac |
| 8438 | case $ac_var in #( |
| 8439 | _ | IFS | as_nl) ;; #( |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8440 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( |
| 8441 | *) { eval $ac_var=; unset $ac_var;} ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8442 | esac ;; |
| 8443 | esac |
| 8444 | done |
| 8445 | |
| 8446 | (set) 2>&1 | |
| 8447 | case $as_nl`(ac_space=' '; set) 2>&1` in #( |
| 8448 | *${as_nl}ac_space=\ *) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8449 | # `set' does not quote correctly, so add quotes: double-quote |
| 8450 | # substitution turns \\\\ into \\, and sed turns \\ into \. |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8451 | sed -n \ |
| 8452 | "s/'/'\\\\''/g; |
| 8453 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" |
| 8454 | ;; #( |
| 8455 | *) |
| 8456 | # `set' quotes correctly as required by POSIX, so do not add quotes. |
| 8457 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" |
| 8458 | ;; |
| 8459 | esac | |
| 8460 | sort |
| 8461 | ) | |
| 8462 | sed ' |
| 8463 | /^ac_cv_env_/b end |
| 8464 | t clear |
| 8465 | :clear |
| 8466 | s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ |
| 8467 | t end |
| 8468 | s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ |
| 8469 | :end' >>confcache |
| 8470 | if diff "$cache_file" confcache >/dev/null 2>&1; then :; else |
| 8471 | if test -w "$cache_file"; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8472 | if test "x$cache_file" != "x/dev/null"; then |
| 8473 | { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 |
| 8474 | $as_echo "$as_me: updating cache $cache_file" >&6;} |
| 8475 | if test ! -f "$cache_file" || test -h "$cache_file"; then |
| 8476 | cat confcache >"$cache_file" |
| 8477 | else |
| 8478 | case $cache_file in #( |
| 8479 | */* | ?:*) |
| 8480 | mv -f confcache "$cache_file"$$ && |
| 8481 | mv -f "$cache_file"$$ "$cache_file" ;; #( |
| 8482 | *) |
| 8483 | mv -f confcache "$cache_file" ;; |
| 8484 | esac |
| 8485 | fi |
| 8486 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8487 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8488 | { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 |
| 8489 | $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8490 | fi |
| 8491 | fi |
| 8492 | rm -f confcache |
| 8493 | |
| 8494 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
| 8495 | # Let make expand exec_prefix. |
| 8496 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' |
| 8497 | |
| 8498 | DEFS=-DHAVE_CONFIG_H |
| 8499 | |
| 8500 | ac_libobjs= |
| 8501 | ac_ltlibobjs= |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8502 | U= |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8503 | for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue |
| 8504 | # 1. Remove the extension, and $U if already installed. |
| 8505 | ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8506 | ac_i=`$as_echo "$ac_i" | sed "$ac_script"` |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8507 | # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR |
| 8508 | # will be set to the directory where LIBOBJS objects are built. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8509 | as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" |
| 8510 | as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8511 | done |
| 8512 | LIBOBJS=$ac_libobjs |
| 8513 | |
| 8514 | LTLIBOBJS=$ac_ltlibobjs |
| 8515 | |
| 8516 | |
| 8517 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8518 | : "${CONFIG_STATUS=./config.status}" |
| 8519 | ac_write_fail=0 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8520 | ac_clean_files_save=$ac_clean_files |
| 8521 | ac_clean_files="$ac_clean_files $CONFIG_STATUS" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8522 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 |
| 8523 | $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} |
| 8524 | as_write_fail=0 |
| 8525 | cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8526 | #! $SHELL |
| 8527 | # Generated by $as_me. |
| 8528 | # Run this file to recreate the current configuration. |
| 8529 | # Compiler output produced by configure, useful for debugging |
| 8530 | # configure, is in config.log if it exists. |
| 8531 | |
| 8532 | debug=false |
| 8533 | ac_cs_recheck=false |
| 8534 | ac_cs_silent=false |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8535 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8536 | SHELL=\${CONFIG_SHELL-$SHELL} |
| 8537 | export SHELL |
| 8538 | _ASEOF |
| 8539 | cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 |
| 8540 | ## -------------------- ## |
| 8541 | ## M4sh Initialization. ## |
| 8542 | ## -------------------- ## |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8543 | |
| 8544 | # Be more Bourne compatible |
| 8545 | DUALCASE=1; export DUALCASE # for MKS sh |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8546 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8547 | emulate sh |
| 8548 | NULLCMD=: |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8549 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8550 | # is contrary to our usage. Disable this feature. |
| 8551 | alias -g '${1+"$@"}'='"$@"' |
| 8552 | setopt NO_GLOB_SUBST |
| 8553 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8554 | case `(set -o) 2>/dev/null` in #( |
| 8555 | *posix*) : |
| 8556 | set -o posix ;; #( |
| 8557 | *) : |
| 8558 | ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8559 | esac |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8560 | fi |
| 8561 | |
| 8562 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8563 | as_nl=' |
| 8564 | ' |
| 8565 | export as_nl |
| 8566 | # Printing a long string crashes Solaris 7 /usr/bin/printf. |
| 8567 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' |
| 8568 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo |
| 8569 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo |
| 8570 | # Prefer a ksh shell builtin over an external printf program on Solaris, |
| 8571 | # but without wasting forks for bash or zsh. |
| 8572 | if test -z "$BASH_VERSION$ZSH_VERSION" \ |
| 8573 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 8574 | as_echo='print -r --' |
| 8575 | as_echo_n='print -rn --' |
| 8576 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 8577 | as_echo='printf %s\n' |
| 8578 | as_echo_n='printf %s' |
| 8579 | else |
| 8580 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then |
| 8581 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' |
| 8582 | as_echo_n='/usr/ucb/echo -n' |
| 8583 | else |
| 8584 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' |
| 8585 | as_echo_n_body='eval |
| 8586 | arg=$1; |
| 8587 | case $arg in #( |
| 8588 | *"$as_nl"*) |
| 8589 | expr "X$arg" : "X\\(.*\\)$as_nl"; |
| 8590 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; |
| 8591 | esac; |
| 8592 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" |
| 8593 | ' |
| 8594 | export as_echo_n_body |
| 8595 | as_echo_n='sh -c $as_echo_n_body as_echo' |
| 8596 | fi |
| 8597 | export as_echo_body |
| 8598 | as_echo='sh -c $as_echo_body as_echo' |
| 8599 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8600 | |
| 8601 | # The user is always right. |
| 8602 | if test "${PATH_SEPARATOR+set}" != set; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8603 | PATH_SEPARATOR=: |
| 8604 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { |
| 8605 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || |
| 8606 | PATH_SEPARATOR=';' |
| 8607 | } |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8608 | fi |
| 8609 | |
| 8610 | |
| 8611 | # IFS |
| 8612 | # We need space, tab and new line, in precisely that order. Quoting is |
| 8613 | # there to prevent editors from complaining about space-tab. |
| 8614 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word |
| 8615 | # splitting by setting IFS to empty value.) |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8616 | IFS=" "" $as_nl" |
| 8617 | |
| 8618 | # Find who we are. Look in the path if we contain no directory separator. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8619 | as_myself= |
| 8620 | case $0 in #(( |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8621 | *[\\/]* ) as_myself=$0 ;; |
| 8622 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 8623 | for as_dir in $PATH |
| 8624 | do |
| 8625 | IFS=$as_save_IFS |
| 8626 | test -z "$as_dir" && as_dir=. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8627 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break |
| 8628 | done |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8629 | IFS=$as_save_IFS |
| 8630 | |
| 8631 | ;; |
| 8632 | esac |
| 8633 | # We did not find ourselves, most probably we were run as `sh COMMAND' |
| 8634 | # in which case we are not to be found in the path. |
| 8635 | if test "x$as_myself" = x; then |
| 8636 | as_myself=$0 |
| 8637 | fi |
| 8638 | if test ! -f "$as_myself"; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8639 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 |
| 8640 | exit 1 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8641 | fi |
| 8642 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8643 | # Unset variables that we do not need and which cause bugs (e.g. in |
| 8644 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" |
| 8645 | # suppresses any "Segmentation fault" message there. '((' could |
| 8646 | # trigger a bug in pdksh 5.2.14. |
| 8647 | for as_var in BASH_ENV ENV MAIL MAILPATH |
| 8648 | do eval test x\${$as_var+set} = xset \ |
| 8649 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8650 | done |
| 8651 | PS1='$ ' |
| 8652 | PS2='> ' |
| 8653 | PS4='+ ' |
| 8654 | |
| 8655 | # NLS nuisances. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8656 | LC_ALL=C |
| 8657 | export LC_ALL |
| 8658 | LANGUAGE=C |
| 8659 | export LANGUAGE |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8660 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8661 | # CDPATH. |
| 8662 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH |
| 8663 | |
| 8664 | |
| 8665 | # as_fn_error STATUS ERROR [LINENO LOG_FD] |
| 8666 | # ---------------------------------------- |
| 8667 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are |
| 8668 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the |
| 8669 | # script with STATUS, using 1 if that was 0. |
| 8670 | as_fn_error () |
| 8671 | { |
| 8672 | as_status=$1; test $as_status -eq 0 && as_status=1 |
| 8673 | if test "$4"; then |
| 8674 | as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 8675 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 |
| 8676 | fi |
| 8677 | $as_echo "$as_me: error: $2" >&2 |
| 8678 | as_fn_exit $as_status |
| 8679 | } # as_fn_error |
| 8680 | |
| 8681 | |
| 8682 | # as_fn_set_status STATUS |
| 8683 | # ----------------------- |
| 8684 | # Set $? to STATUS, without forking. |
| 8685 | as_fn_set_status () |
| 8686 | { |
| 8687 | return $1 |
| 8688 | } # as_fn_set_status |
| 8689 | |
| 8690 | # as_fn_exit STATUS |
| 8691 | # ----------------- |
| 8692 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. |
| 8693 | as_fn_exit () |
| 8694 | { |
| 8695 | set +e |
| 8696 | as_fn_set_status $1 |
| 8697 | exit $1 |
| 8698 | } # as_fn_exit |
| 8699 | |
| 8700 | # as_fn_unset VAR |
| 8701 | # --------------- |
| 8702 | # Portably unset VAR. |
| 8703 | as_fn_unset () |
| 8704 | { |
| 8705 | { eval $1=; unset $1;} |
| 8706 | } |
| 8707 | as_unset=as_fn_unset |
| 8708 | # as_fn_append VAR VALUE |
| 8709 | # ---------------------- |
| 8710 | # Append the text in VALUE to the end of the definition contained in VAR. Take |
| 8711 | # advantage of any shell optimizations that allow amortized linear growth over |
| 8712 | # repeated appends, instead of the typical quadratic growth present in naive |
| 8713 | # implementations. |
| 8714 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : |
| 8715 | eval 'as_fn_append () |
| 8716 | { |
| 8717 | eval $1+=\$2 |
| 8718 | }' |
| 8719 | else |
| 8720 | as_fn_append () |
| 8721 | { |
| 8722 | eval $1=\$$1\$2 |
| 8723 | } |
| 8724 | fi # as_fn_append |
| 8725 | |
| 8726 | # as_fn_arith ARG... |
| 8727 | # ------------------ |
| 8728 | # Perform arithmetic evaluation on the ARGs, and store the result in the |
| 8729 | # global $as_val. Take advantage of shells that can avoid forks. The arguments |
| 8730 | # must be portable across $(()) and expr. |
| 8731 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : |
| 8732 | eval 'as_fn_arith () |
| 8733 | { |
| 8734 | as_val=$(( $* )) |
| 8735 | }' |
| 8736 | else |
| 8737 | as_fn_arith () |
| 8738 | { |
| 8739 | as_val=`expr "$@" || test $? -eq 1` |
| 8740 | } |
| 8741 | fi # as_fn_arith |
| 8742 | |
| 8743 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8744 | if expr a : '\(a\)' >/dev/null 2>&1 && |
| 8745 | test "X`expr 00001 : '.*\(...\)'`" = X001; then |
| 8746 | as_expr=expr |
| 8747 | else |
| 8748 | as_expr=false |
| 8749 | fi |
| 8750 | |
| 8751 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
| 8752 | as_basename=basename |
| 8753 | else |
| 8754 | as_basename=false |
| 8755 | fi |
| 8756 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8757 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
| 8758 | as_dirname=dirname |
| 8759 | else |
| 8760 | as_dirname=false |
| 8761 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8762 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8763 | as_me=`$as_basename -- "$0" || |
| 8764 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
| 8765 | X"$0" : 'X\(//\)$' \| \ |
| 8766 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8767 | $as_echo X/"$0" | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8768 | sed '/^.*\/\([^/][^/]*\)\/*$/{ |
| 8769 | s//\1/ |
| 8770 | q |
| 8771 | } |
| 8772 | /^X\/\(\/\/\)$/{ |
| 8773 | s//\1/ |
| 8774 | q |
| 8775 | } |
| 8776 | /^X\/\(\/\).*/{ |
| 8777 | s//\1/ |
| 8778 | q |
| 8779 | } |
| 8780 | s/.*/./; q'` |
| 8781 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8782 | # Avoid depending upon Character Ranges. |
| 8783 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' |
| 8784 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' |
| 8785 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS |
| 8786 | as_cr_digits='0123456789' |
| 8787 | as_cr_alnum=$as_cr_Letters$as_cr_digits |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8788 | |
| 8789 | ECHO_C= ECHO_N= ECHO_T= |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8790 | case `echo -n x` in #((((( |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8791 | -n*) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8792 | case `echo 'xy\c'` in |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8793 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8794 | xy) ECHO_C='\c';; |
| 8795 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null |
| 8796 | ECHO_T=' ';; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8797 | esac;; |
| 8798 | *) |
| 8799 | ECHO_N='-n';; |
| 8800 | esac |
| 8801 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8802 | rm -f conf$$ conf$$.exe conf$$.file |
| 8803 | if test -d conf$$.dir; then |
| 8804 | rm -f conf$$.dir/conf$$.file |
| 8805 | else |
| 8806 | rm -f conf$$.dir |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8807 | mkdir conf$$.dir 2>/dev/null |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8808 | fi |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8809 | if (echo >conf$$.file) 2>/dev/null; then |
| 8810 | if ln -s conf$$.file conf$$ 2>/dev/null; then |
| 8811 | as_ln_s='ln -s' |
| 8812 | # ... but there are two gotchas: |
| 8813 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. |
| 8814 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. |
| 8815 | # In both cases, we have to default to `cp -pR'. |
| 8816 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || |
| 8817 | as_ln_s='cp -pR' |
| 8818 | elif ln conf$$.file conf$$ 2>/dev/null; then |
| 8819 | as_ln_s=ln |
| 8820 | else |
| 8821 | as_ln_s='cp -pR' |
| 8822 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8823 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8824 | as_ln_s='cp -pR' |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8825 | fi |
| 8826 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
| 8827 | rmdir conf$$.dir 2>/dev/null |
| 8828 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8829 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8830 | # as_fn_mkdir_p |
| 8831 | # ------------- |
| 8832 | # Create "$as_dir" as a directory, including parents if necessary. |
| 8833 | as_fn_mkdir_p () |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8834 | { |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8835 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8836 | case $as_dir in #( |
| 8837 | -*) as_dir=./$as_dir;; |
| 8838 | esac |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8839 | test -d "$as_dir" || eval $as_mkdir_p || { |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8840 | as_dirs= |
| 8841 | while :; do |
| 8842 | case $as_dir in #( |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8843 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8844 | *) as_qdir=$as_dir;; |
| 8845 | esac |
| 8846 | as_dirs="'$as_qdir' $as_dirs" |
| 8847 | as_dir=`$as_dirname -- "$as_dir" || |
| 8848 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 8849 | X"$as_dir" : 'X\(//\)[^/]' \| \ |
| 8850 | X"$as_dir" : 'X\(//\)$' \| \ |
| 8851 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8852 | $as_echo X"$as_dir" | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 8853 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 8854 | s//\1/ |
| 8855 | q |
| 8856 | } |
| 8857 | /^X\(\/\/\)[^/].*/{ |
| 8858 | s//\1/ |
| 8859 | q |
| 8860 | } |
| 8861 | /^X\(\/\/\)$/{ |
| 8862 | s//\1/ |
| 8863 | q |
| 8864 | } |
| 8865 | /^X\(\/\).*/{ |
| 8866 | s//\1/ |
| 8867 | q |
| 8868 | } |
| 8869 | s/.*/./; q'` |
| 8870 | test -d "$as_dir" && break |
| 8871 | done |
| 8872 | test -z "$as_dirs" || eval "mkdir $as_dirs" |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 8873 | } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" |
| 8874 | |
| 8875 | |
| 8876 | } # as_fn_mkdir_p |
| 8877 | if mkdir -p . 2>/dev/null; then |
| 8878 | as_mkdir_p='mkdir -p "$as_dir"' |
| 8879 | else |
| 8880 | test -d ./-p && rmdir ./-p |
| 8881 | as_mkdir_p=false |
| 8882 | fi |
| 8883 | |
| 8884 | |
| 8885 | # as_fn_executable_p FILE |
| 8886 | # ----------------------- |
| 8887 | # Test if FILE is an executable regular file. |
| 8888 | as_fn_executable_p () |
| 8889 | { |
| 8890 | test -f "$1" && test -x "$1" |
| 8891 | } # as_fn_executable_p |
| 8892 | as_test_x='test -x' |
| 8893 | as_executable_p=as_fn_executable_p |
| 8894 | |
| 8895 | # Sed expression to map a string onto a valid CPP name. |
| 8896 | as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" |
| 8897 | |
| 8898 | # Sed expression to map a string onto a valid variable name. |
| 8899 | as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" |
| 8900 | |
| 8901 | |
| 8902 | exec 6>&1 |
| 8903 | ## ----------------------------------- ## |
| 8904 | ## Main body of $CONFIG_STATUS script. ## |
| 8905 | ## ----------------------------------- ## |
| 8906 | _ASEOF |
| 8907 | test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 |
| 8908 | |
| 8909 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 8910 | # Save the log message, to keep $0 and so on meaningful, and to |
| 8911 | # report actual input values of CONFIG_FILES etc. instead of their |
| 8912 | # values after options handling. |
| 8913 | ac_log=" |
| 8914 | This file was extended by $as_me, which was |
| 8915 | generated by GNU Autoconf 2.69. Invocation command line was |
| 8916 | |
| 8917 | CONFIG_FILES = $CONFIG_FILES |
| 8918 | CONFIG_HEADERS = $CONFIG_HEADERS |
| 8919 | CONFIG_LINKS = $CONFIG_LINKS |
| 8920 | CONFIG_COMMANDS = $CONFIG_COMMANDS |
| 8921 | $ $0 $@ |
| 8922 | |
| 8923 | on `(hostname || uname -n) 2>/dev/null | sed 1q` |
| 8924 | " |
| 8925 | |
| 8926 | _ACEOF |
| 8927 | |
| 8928 | case $ac_config_files in *" |
| 8929 | "*) set x $ac_config_files; shift; ac_config_files=$*;; |
| 8930 | esac |
| 8931 | |
| 8932 | case $ac_config_headers in *" |
| 8933 | "*) set x $ac_config_headers; shift; ac_config_headers=$*;; |
| 8934 | esac |
| 8935 | |
| 8936 | |
| 8937 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 8938 | # Files that config.status was made for. |
| 8939 | config_files="$ac_config_files" |
| 8940 | config_headers="$ac_config_headers" |
| 8941 | config_commands="$ac_config_commands" |
| 8942 | |
| 8943 | _ACEOF |
| 8944 | |
| 8945 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 8946 | ac_cs_usage="\ |
| 8947 | \`$as_me' instantiates files and other configuration actions |
| 8948 | from templates according to the current configuration. Unless the files |
| 8949 | and actions are specified as TAGs, all are instantiated by default. |
| 8950 | |
| 8951 | Usage: $0 [OPTION]... [TAG]... |
| 8952 | |
| 8953 | -h, --help print this help, then exit |
| 8954 | -V, --version print version number and configuration settings, then exit |
| 8955 | --config print configuration, then exit |
| 8956 | -q, --quiet, --silent |
| 8957 | do not print progress messages |
| 8958 | -d, --debug don't remove temporary files |
| 8959 | --recheck update $as_me by reconfiguring in the same conditions |
| 8960 | --file=FILE[:TEMPLATE] |
| 8961 | instantiate the configuration file FILE |
| 8962 | --header=FILE[:TEMPLATE] |
| 8963 | instantiate the configuration header FILE |
| 8964 | |
| 8965 | Configuration files: |
| 8966 | $config_files |
| 8967 | |
| 8968 | Configuration headers: |
| 8969 | $config_headers |
| 8970 | |
| 8971 | Configuration commands: |
| 8972 | $config_commands |
| 8973 | |
| 8974 | Report bugs to the package provider." |
| 8975 | |
| 8976 | _ACEOF |
| 8977 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 8978 | ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" |
| 8979 | ac_cs_version="\\ |
| 8980 | config.status |
| 8981 | configured by $0, generated by GNU Autoconf 2.69, |
| 8982 | with options \\"\$ac_cs_config\\" |
| 8983 | |
| 8984 | Copyright (C) 2012 Free Software Foundation, Inc. |
| 8985 | This config.status script is free software; the Free Software Foundation |
| 8986 | gives unlimited permission to copy, distribute and modify it." |
| 8987 | |
| 8988 | ac_pwd='$ac_pwd' |
| 8989 | srcdir='$srcdir' |
| 8990 | INSTALL='$INSTALL' |
| 8991 | test -n "\$AWK" || AWK=awk |
| 8992 | _ACEOF |
| 8993 | |
| 8994 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 8995 | # The default lists apply if the user does not specify any file. |
| 8996 | ac_need_defaults=: |
| 8997 | while test $# != 0 |
| 8998 | do |
| 8999 | case $1 in |
| 9000 | --*=?*) |
| 9001 | ac_option=`expr "X$1" : 'X\([^=]*\)='` |
| 9002 | ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` |
| 9003 | ac_shift=: |
| 9004 | ;; |
| 9005 | --*=) |
| 9006 | ac_option=`expr "X$1" : 'X\([^=]*\)='` |
| 9007 | ac_optarg= |
| 9008 | ac_shift=: |
| 9009 | ;; |
| 9010 | *) |
| 9011 | ac_option=$1 |
| 9012 | ac_optarg=$2 |
| 9013 | ac_shift=shift |
| 9014 | ;; |
| 9015 | esac |
| 9016 | |
| 9017 | case $ac_option in |
| 9018 | # Handling of the options. |
| 9019 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
| 9020 | ac_cs_recheck=: ;; |
| 9021 | --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) |
| 9022 | $as_echo "$ac_cs_version"; exit ;; |
| 9023 | --config | --confi | --conf | --con | --co | --c ) |
| 9024 | $as_echo "$ac_cs_config"; exit ;; |
| 9025 | --debug | --debu | --deb | --de | --d | -d ) |
| 9026 | debug=: ;; |
| 9027 | --file | --fil | --fi | --f ) |
| 9028 | $ac_shift |
| 9029 | case $ac_optarg in |
| 9030 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; |
| 9031 | '') as_fn_error $? "missing file argument" ;; |
| 9032 | esac |
| 9033 | as_fn_append CONFIG_FILES " '$ac_optarg'" |
| 9034 | ac_need_defaults=false;; |
| 9035 | --header | --heade | --head | --hea ) |
| 9036 | $ac_shift |
| 9037 | case $ac_optarg in |
| 9038 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; |
| 9039 | esac |
| 9040 | as_fn_append CONFIG_HEADERS " '$ac_optarg'" |
| 9041 | ac_need_defaults=false;; |
| 9042 | --he | --h) |
| 9043 | # Conflict between --help and --header |
| 9044 | as_fn_error $? "ambiguous option: \`$1' |
| 9045 | Try \`$0 --help' for more information.";; |
| 9046 | --help | --hel | -h ) |
| 9047 | $as_echo "$ac_cs_usage"; exit ;; |
| 9048 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 9049 | | -silent | --silent | --silen | --sile | --sil | --si | --s) |
| 9050 | ac_cs_silent=: ;; |
| 9051 | |
| 9052 | # This is an error. |
| 9053 | -*) as_fn_error $? "unrecognized option: \`$1' |
| 9054 | Try \`$0 --help' for more information." ;; |
| 9055 | |
| 9056 | *) as_fn_append ac_config_targets " $1" |
| 9057 | ac_need_defaults=false ;; |
| 9058 | |
| 9059 | esac |
| 9060 | shift |
| 9061 | done |
| 9062 | |
| 9063 | ac_configure_extra_args= |
| 9064 | |
| 9065 | if $ac_cs_silent; then |
| 9066 | exec 6>/dev/null |
| 9067 | ac_configure_extra_args="$ac_configure_extra_args --silent" |
| 9068 | fi |
| 9069 | |
| 9070 | _ACEOF |
| 9071 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 9072 | if \$ac_cs_recheck; then |
| 9073 | set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion |
| 9074 | shift |
| 9075 | \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 |
| 9076 | CONFIG_SHELL='$SHELL' |
| 9077 | export CONFIG_SHELL |
| 9078 | exec "\$@" |
| 9079 | fi |
| 9080 | |
| 9081 | _ACEOF |
| 9082 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 9083 | exec 5>>config.log |
| 9084 | { |
| 9085 | echo |
| 9086 | sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX |
| 9087 | ## Running $as_me. ## |
| 9088 | _ASBOX |
| 9089 | $as_echo "$ac_log" |
| 9090 | } >&5 |
| 9091 | |
| 9092 | _ACEOF |
| 9093 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 9094 | # |
| 9095 | # INIT-COMMANDS |
| 9096 | # |
| 9097 | |
| 9098 | |
| 9099 | _ACEOF |
| 9100 | |
| 9101 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 9102 | |
| 9103 | # Handling of arguments. |
| 9104 | for ac_config_target in $ac_config_targets |
| 9105 | do |
| 9106 | case $ac_config_target in |
| 9107 | "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; |
| 9108 | "default-1") CONFIG_COMMANDS="$CONFIG_COMMANDS default-1" ;; |
| 9109 | "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; |
| 9110 | "pcap-filter.manmisc") CONFIG_FILES="$CONFIG_FILES pcap-filter.manmisc" ;; |
| 9111 | "pcap-linktype.manmisc") CONFIG_FILES="$CONFIG_FILES pcap-linktype.manmisc" ;; |
| 9112 | "pcap-tstamp.manmisc") CONFIG_FILES="$CONFIG_FILES pcap-tstamp.manmisc" ;; |
| 9113 | "pcap-savefile.manfile") CONFIG_FILES="$CONFIG_FILES pcap-savefile.manfile" ;; |
| 9114 | "pcap.3pcap") CONFIG_FILES="$CONFIG_FILES pcap.3pcap" ;; |
| 9115 | "pcap_compile.3pcap") CONFIG_FILES="$CONFIG_FILES pcap_compile.3pcap" ;; |
| 9116 | "pcap_datalink.3pcap") CONFIG_FILES="$CONFIG_FILES pcap_datalink.3pcap" ;; |
| 9117 | "pcap_dump_open.3pcap") CONFIG_FILES="$CONFIG_FILES pcap_dump_open.3pcap" ;; |
| 9118 | "pcap_get_tstamp_precision.3pcap") CONFIG_FILES="$CONFIG_FILES pcap_get_tstamp_precision.3pcap" ;; |
| 9119 | "pcap_list_datalinks.3pcap") CONFIG_FILES="$CONFIG_FILES pcap_list_datalinks.3pcap" ;; |
| 9120 | "pcap_list_tstamp_types.3pcap") CONFIG_FILES="$CONFIG_FILES pcap_list_tstamp_types.3pcap" ;; |
| 9121 | "pcap_open_dead.3pcap") CONFIG_FILES="$CONFIG_FILES pcap_open_dead.3pcap" ;; |
| 9122 | "pcap_open_offline.3pcap") CONFIG_FILES="$CONFIG_FILES pcap_open_offline.3pcap" ;; |
| 9123 | "pcap_set_tstamp_precision.3pcap") CONFIG_FILES="$CONFIG_FILES pcap_set_tstamp_precision.3pcap" ;; |
| 9124 | "pcap_set_tstamp_type.3pcap") CONFIG_FILES="$CONFIG_FILES pcap_set_tstamp_type.3pcap" ;; |
| 9125 | |
| 9126 | *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; |
| 9127 | esac |
| 9128 | done |
| 9129 | |
| 9130 | |
| 9131 | # If the user did not use the arguments to specify the items to instantiate, |
| 9132 | # then the envvar interface is used. Set only those that are not. |
| 9133 | # We use the long form for the default assignment because of an extremely |
| 9134 | # bizarre bug on SunOS 4.1.3. |
| 9135 | if $ac_need_defaults; then |
| 9136 | test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files |
| 9137 | test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers |
| 9138 | test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands |
| 9139 | fi |
| 9140 | |
| 9141 | # Have a temporary directory for convenience. Make it in the build tree |
| 9142 | # simply because there is no reason against having it here, and in addition, |
| 9143 | # creating and moving files from /tmp can sometimes cause problems. |
| 9144 | # Hook for its removal unless debugging. |
| 9145 | # Note that there is a small window in which the directory will not be cleaned: |
| 9146 | # after its creation but before its name has been assigned to `$tmp'. |
| 9147 | $debug || |
| 9148 | { |
| 9149 | tmp= ac_tmp= |
| 9150 | trap 'exit_status=$? |
| 9151 | : "${ac_tmp:=$tmp}" |
| 9152 | { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status |
| 9153 | ' 0 |
| 9154 | trap 'as_fn_exit 1' 1 2 13 15 |
| 9155 | } |
| 9156 | # Create a (secure) tmp directory for tmp files. |
| 9157 | |
| 9158 | { |
| 9159 | tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && |
| 9160 | test -d "$tmp" |
| 9161 | } || |
| 9162 | { |
| 9163 | tmp=./conf$$-$RANDOM |
| 9164 | (umask 077 && mkdir "$tmp") |
| 9165 | } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 |
| 9166 | ac_tmp=$tmp |
| 9167 | |
| 9168 | # Set up the scripts for CONFIG_FILES section. |
| 9169 | # No need to generate them if there are no CONFIG_FILES. |
| 9170 | # This happens for instance with `./config.status config.h'. |
| 9171 | if test -n "$CONFIG_FILES"; then |
| 9172 | |
| 9173 | |
| 9174 | ac_cr=`echo X | tr X '\015'` |
| 9175 | # On cygwin, bash can eat \r inside `` if the user requested igncr. |
| 9176 | # But we know of no other shell where ac_cr would be empty at this |
| 9177 | # point, so we can use a bashism as a fallback. |
| 9178 | if test "x$ac_cr" = x; then |
| 9179 | eval ac_cr=\$\'\\r\' |
| 9180 | fi |
| 9181 | ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` |
| 9182 | if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then |
| 9183 | ac_cs_awk_cr='\\r' |
| 9184 | else |
| 9185 | ac_cs_awk_cr=$ac_cr |
| 9186 | fi |
| 9187 | |
| 9188 | echo 'BEGIN {' >"$ac_tmp/subs1.awk" && |
| 9189 | _ACEOF |
| 9190 | |
| 9191 | |
| 9192 | { |
| 9193 | echo "cat >conf$$subs.awk <<_ACEOF" && |
| 9194 | echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && |
| 9195 | echo "_ACEOF" |
| 9196 | } >conf$$subs.sh || |
| 9197 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
| 9198 | ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` |
| 9199 | ac_delim='%!_!# ' |
| 9200 | for ac_last_try in false false false false false :; do |
| 9201 | . ./conf$$subs.sh || |
| 9202 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
| 9203 | |
| 9204 | ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` |
| 9205 | if test $ac_delim_n = $ac_delim_num; then |
| 9206 | break |
| 9207 | elif $ac_last_try; then |
| 9208 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
| 9209 | else |
| 9210 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " |
| 9211 | fi |
| 9212 | done |
| 9213 | rm -f conf$$subs.sh |
| 9214 | |
| 9215 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 9216 | cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && |
| 9217 | _ACEOF |
| 9218 | sed -n ' |
| 9219 | h |
| 9220 | s/^/S["/; s/!.*/"]=/ |
| 9221 | p |
| 9222 | g |
| 9223 | s/^[^!]*!// |
| 9224 | :repl |
| 9225 | t repl |
| 9226 | s/'"$ac_delim"'$// |
| 9227 | t delim |
| 9228 | :nl |
| 9229 | h |
| 9230 | s/\(.\{148\}\)..*/\1/ |
| 9231 | t more1 |
| 9232 | s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ |
| 9233 | p |
| 9234 | n |
| 9235 | b repl |
| 9236 | :more1 |
| 9237 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ |
| 9238 | p |
| 9239 | g |
| 9240 | s/.\{148\}// |
| 9241 | t nl |
| 9242 | :delim |
| 9243 | h |
| 9244 | s/\(.\{148\}\)..*/\1/ |
| 9245 | t more2 |
| 9246 | s/["\\]/\\&/g; s/^/"/; s/$/"/ |
| 9247 | p |
| 9248 | b |
| 9249 | :more2 |
| 9250 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ |
| 9251 | p |
| 9252 | g |
| 9253 | s/.\{148\}// |
| 9254 | t delim |
| 9255 | ' <conf$$subs.awk | sed ' |
| 9256 | /^[^""]/{ |
| 9257 | N |
| 9258 | s/\n// |
| 9259 | } |
| 9260 | ' >>$CONFIG_STATUS || ac_write_fail=1 |
| 9261 | rm -f conf$$subs.awk |
| 9262 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 9263 | _ACAWK |
| 9264 | cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && |
| 9265 | for (key in S) S_is_set[key] = 1 |
| 9266 | FS = "" |
| 9267 | |
| 9268 | } |
| 9269 | { |
| 9270 | line = $ 0 |
| 9271 | nfields = split(line, field, "@") |
| 9272 | substed = 0 |
| 9273 | len = length(field[1]) |
| 9274 | for (i = 2; i < nfields; i++) { |
| 9275 | key = field[i] |
| 9276 | keylen = length(key) |
| 9277 | if (S_is_set[key]) { |
| 9278 | value = S[key] |
| 9279 | line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) |
| 9280 | len += length(value) + length(field[++i]) |
| 9281 | substed = 1 |
| 9282 | } else |
| 9283 | len += 1 + keylen |
| 9284 | } |
| 9285 | |
| 9286 | print line |
| 9287 | } |
| 9288 | |
| 9289 | _ACAWK |
| 9290 | _ACEOF |
| 9291 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 9292 | if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then |
| 9293 | sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" |
| 9294 | else |
| 9295 | cat |
| 9296 | fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ |
| 9297 | || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 |
| 9298 | _ACEOF |
| 9299 | |
| 9300 | # VPATH may cause trouble with some makes, so we remove sole $(srcdir), |
| 9301 | # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and |
| 9302 | # trailing colons and then remove the whole line if VPATH becomes empty |
| 9303 | # (actually we leave an empty line to preserve line numbers). |
| 9304 | if test "x$srcdir" = x.; then |
| 9305 | ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ |
| 9306 | h |
| 9307 | s/// |
| 9308 | s/^/:/ |
| 9309 | s/[ ]*$/:/ |
| 9310 | s/:\$(srcdir):/:/g |
| 9311 | s/:\${srcdir}:/:/g |
| 9312 | s/:@srcdir@:/:/g |
| 9313 | s/^:*// |
| 9314 | s/:*$// |
| 9315 | x |
| 9316 | s/\(=[ ]*\).*/\1/ |
| 9317 | G |
| 9318 | s/\n// |
| 9319 | s/^[^=]*=[ ]*$// |
| 9320 | }' |
| 9321 | fi |
| 9322 | |
| 9323 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 9324 | fi # test -n "$CONFIG_FILES" |
| 9325 | |
| 9326 | # Set up the scripts for CONFIG_HEADERS section. |
| 9327 | # No need to generate them if there are no CONFIG_HEADERS. |
| 9328 | # This happens for instance with `./config.status Makefile'. |
| 9329 | if test -n "$CONFIG_HEADERS"; then |
| 9330 | cat >"$ac_tmp/defines.awk" <<\_ACAWK || |
| 9331 | BEGIN { |
| 9332 | _ACEOF |
| 9333 | |
| 9334 | # Transform confdefs.h into an awk script `defines.awk', embedded as |
| 9335 | # here-document in config.status, that substitutes the proper values into |
| 9336 | # config.h.in to produce config.h. |
| 9337 | |
| 9338 | # Create a delimiter string that does not exist in confdefs.h, to ease |
| 9339 | # handling of long lines. |
| 9340 | ac_delim='%!_!# ' |
| 9341 | for ac_last_try in false false :; do |
| 9342 | ac_tt=`sed -n "/$ac_delim/p" confdefs.h` |
| 9343 | if test -z "$ac_tt"; then |
| 9344 | break |
| 9345 | elif $ac_last_try; then |
| 9346 | as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 |
| 9347 | else |
| 9348 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " |
| 9349 | fi |
| 9350 | done |
| 9351 | |
| 9352 | # For the awk script, D is an array of macro values keyed by name, |
| 9353 | # likewise P contains macro parameters if any. Preserve backslash |
| 9354 | # newline sequences. |
| 9355 | |
| 9356 | ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* |
| 9357 | sed -n ' |
| 9358 | s/.\{148\}/&'"$ac_delim"'/g |
| 9359 | t rset |
| 9360 | :rset |
| 9361 | s/^[ ]*#[ ]*define[ ][ ]*/ / |
| 9362 | t def |
| 9363 | d |
| 9364 | :def |
| 9365 | s/\\$// |
| 9366 | t bsnl |
| 9367 | s/["\\]/\\&/g |
| 9368 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ |
| 9369 | D["\1"]=" \3"/p |
| 9370 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p |
| 9371 | d |
| 9372 | :bsnl |
| 9373 | s/["\\]/\\&/g |
| 9374 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ |
| 9375 | D["\1"]=" \3\\\\\\n"\\/p |
| 9376 | t cont |
| 9377 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p |
| 9378 | t cont |
| 9379 | d |
| 9380 | :cont |
| 9381 | n |
| 9382 | s/.\{148\}/&'"$ac_delim"'/g |
| 9383 | t clear |
| 9384 | :clear |
| 9385 | s/\\$// |
| 9386 | t bsnlc |
| 9387 | s/["\\]/\\&/g; s/^/"/; s/$/"/p |
| 9388 | d |
| 9389 | :bsnlc |
| 9390 | s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p |
| 9391 | b cont |
| 9392 | ' <confdefs.h | sed ' |
| 9393 | s/'"$ac_delim"'/"\\\ |
| 9394 | "/g' >>$CONFIG_STATUS || ac_write_fail=1 |
| 9395 | |
| 9396 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 9397 | for (key in D) D_is_set[key] = 1 |
| 9398 | FS = "" |
| 9399 | } |
| 9400 | /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { |
| 9401 | line = \$ 0 |
| 9402 | split(line, arg, " ") |
| 9403 | if (arg[1] == "#") { |
| 9404 | defundef = arg[2] |
| 9405 | mac1 = arg[3] |
| 9406 | } else { |
| 9407 | defundef = substr(arg[1], 2) |
| 9408 | mac1 = arg[2] |
| 9409 | } |
| 9410 | split(mac1, mac2, "(") #) |
| 9411 | macro = mac2[1] |
| 9412 | prefix = substr(line, 1, index(line, defundef) - 1) |
| 9413 | if (D_is_set[macro]) { |
| 9414 | # Preserve the white space surrounding the "#". |
| 9415 | print prefix "define", macro P[macro] D[macro] |
| 9416 | next |
| 9417 | } else { |
| 9418 | # Replace #undef with comments. This is necessary, for example, |
| 9419 | # in the case of _POSIX_SOURCE, which is predefined and required |
| 9420 | # on some systems where configure will not decide to define it. |
| 9421 | if (defundef == "undef") { |
| 9422 | print "/*", prefix defundef, macro, "*/" |
| 9423 | next |
| 9424 | } |
| 9425 | } |
| 9426 | } |
| 9427 | { print } |
| 9428 | _ACAWK |
| 9429 | _ACEOF |
| 9430 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 9431 | as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 |
| 9432 | fi # test -n "$CONFIG_HEADERS" |
| 9433 | |
| 9434 | |
| 9435 | eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" |
| 9436 | shift |
| 9437 | for ac_tag |
| 9438 | do |
| 9439 | case $ac_tag in |
| 9440 | :[FHLC]) ac_mode=$ac_tag; continue;; |
| 9441 | esac |
| 9442 | case $ac_mode$ac_tag in |
| 9443 | :[FHL]*:*);; |
| 9444 | :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; |
| 9445 | :[FH]-) ac_tag=-:-;; |
| 9446 | :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; |
| 9447 | esac |
| 9448 | ac_save_IFS=$IFS |
| 9449 | IFS=: |
| 9450 | set x $ac_tag |
| 9451 | IFS=$ac_save_IFS |
| 9452 | shift |
| 9453 | ac_file=$1 |
| 9454 | shift |
| 9455 | |
| 9456 | case $ac_mode in |
| 9457 | :L) ac_source=$1;; |
| 9458 | :[FH]) |
| 9459 | ac_file_inputs= |
| 9460 | for ac_f |
| 9461 | do |
| 9462 | case $ac_f in |
| 9463 | -) ac_f="$ac_tmp/stdin";; |
| 9464 | *) # Look for the file first in the build tree, then in the source tree |
| 9465 | # (if the path is not absolute). The absolute path cannot be DOS-style, |
| 9466 | # because $ac_f cannot contain `:'. |
| 9467 | test -f "$ac_f" || |
| 9468 | case $ac_f in |
| 9469 | [\\/$]*) false;; |
| 9470 | *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; |
| 9471 | esac || |
| 9472 | as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; |
| 9473 | esac |
| 9474 | case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac |
| 9475 | as_fn_append ac_file_inputs " '$ac_f'" |
| 9476 | done |
| 9477 | |
| 9478 | # Let's still pretend it is `configure' which instantiates (i.e., don't |
| 9479 | # use $as_me), people would be surprised to read: |
| 9480 | # /* config.h. Generated by config.status. */ |
| 9481 | configure_input='Generated from '` |
| 9482 | $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' |
| 9483 | `' by configure.' |
| 9484 | if test x"$ac_file" != x-; then |
| 9485 | configure_input="$ac_file. $configure_input" |
| 9486 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 |
| 9487 | $as_echo "$as_me: creating $ac_file" >&6;} |
| 9488 | fi |
| 9489 | # Neutralize special characters interpreted by sed in replacement strings. |
| 9490 | case $configure_input in #( |
| 9491 | *\&* | *\|* | *\\* ) |
| 9492 | ac_sed_conf_input=`$as_echo "$configure_input" | |
| 9493 | sed 's/[\\\\&|]/\\\\&/g'`;; #( |
| 9494 | *) ac_sed_conf_input=$configure_input;; |
| 9495 | esac |
| 9496 | |
| 9497 | case $ac_tag in |
| 9498 | *:-:* | *:-) cat >"$ac_tmp/stdin" \ |
| 9499 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; |
| 9500 | esac |
| 9501 | ;; |
| 9502 | esac |
| 9503 | |
| 9504 | ac_dir=`$as_dirname -- "$ac_file" || |
| 9505 | $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 9506 | X"$ac_file" : 'X\(//\)[^/]' \| \ |
| 9507 | X"$ac_file" : 'X\(//\)$' \| \ |
| 9508 | X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || |
| 9509 | $as_echo X"$ac_file" | |
| 9510 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 9511 | s//\1/ |
| 9512 | q |
| 9513 | } |
| 9514 | /^X\(\/\/\)[^/].*/{ |
| 9515 | s//\1/ |
| 9516 | q |
| 9517 | } |
| 9518 | /^X\(\/\/\)$/{ |
| 9519 | s//\1/ |
| 9520 | q |
| 9521 | } |
| 9522 | /^X\(\/\).*/{ |
| 9523 | s//\1/ |
| 9524 | q |
| 9525 | } |
| 9526 | s/.*/./; q'` |
| 9527 | as_dir="$ac_dir"; as_fn_mkdir_p |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9528 | ac_builddir=. |
| 9529 | |
| 9530 | case "$ac_dir" in |
| 9531 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 9532 | *) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9533 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9534 | # A ".." for each directory in $ac_dir_suffix. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9535 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9536 | case $ac_top_builddir_sub in |
| 9537 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 9538 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; |
| 9539 | esac ;; |
| 9540 | esac |
| 9541 | ac_abs_top_builddir=$ac_pwd |
| 9542 | ac_abs_builddir=$ac_pwd$ac_dir_suffix |
| 9543 | # for backward compatibility: |
| 9544 | ac_top_builddir=$ac_top_build_prefix |
| 9545 | |
| 9546 | case $srcdir in |
| 9547 | .) # We are building in place. |
| 9548 | ac_srcdir=. |
| 9549 | ac_top_srcdir=$ac_top_builddir_sub |
| 9550 | ac_abs_top_srcdir=$ac_pwd ;; |
| 9551 | [\\/]* | ?:[\\/]* ) # Absolute name. |
| 9552 | ac_srcdir=$srcdir$ac_dir_suffix; |
| 9553 | ac_top_srcdir=$srcdir |
| 9554 | ac_abs_top_srcdir=$srcdir ;; |
| 9555 | *) # Relative name. |
| 9556 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix |
| 9557 | ac_top_srcdir=$ac_top_build_prefix$srcdir |
| 9558 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; |
| 9559 | esac |
| 9560 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
| 9561 | |
| 9562 | |
| 9563 | case $ac_mode in |
| 9564 | :F) |
| 9565 | # |
| 9566 | # CONFIG_FILE |
| 9567 | # |
| 9568 | |
| 9569 | case $INSTALL in |
| 9570 | [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; |
| 9571 | *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; |
| 9572 | esac |
| 9573 | _ACEOF |
| 9574 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9575 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9576 | # If the template does not know about datarootdir, expand it. |
| 9577 | # FIXME: This hack should be removed a few years after 2.60. |
| 9578 | ac_datarootdir_hack=; ac_datarootdir_seen= |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9579 | ac_sed_dataroot=' |
| 9580 | /datarootdir/ { |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9581 | p |
| 9582 | q |
| 9583 | } |
| 9584 | /@datadir@/p |
| 9585 | /@docdir@/p |
| 9586 | /@infodir@/p |
| 9587 | /@localedir@/p |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9588 | /@mandir@/p' |
| 9589 | case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9590 | *datarootdir*) ac_datarootdir_seen=yes;; |
| 9591 | *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9592 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 |
| 9593 | $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9594 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9595 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9596 | ac_datarootdir_hack=' |
| 9597 | s&@datadir@&$datadir&g |
| 9598 | s&@docdir@&$docdir&g |
| 9599 | s&@infodir@&$infodir&g |
| 9600 | s&@localedir@&$localedir&g |
| 9601 | s&@mandir@&$mandir&g |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9602 | s&\\\${datarootdir}&$datarootdir&g' ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9603 | esac |
| 9604 | _ACEOF |
| 9605 | |
| 9606 | # Neutralize VPATH when `$srcdir' = `.'. |
| 9607 | # Shell code in configure.ac might set extrasub. |
| 9608 | # FIXME: do we really want to maintain this feature? |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9609 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 9610 | ac_sed_extra="$ac_vpsub |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9611 | $extrasub |
| 9612 | _ACEOF |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9613 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9614 | :t |
| 9615 | /@[a-zA-Z_][a-zA-Z_0-9]*@/!b |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9616 | s|@configure_input@|$ac_sed_conf_input|;t t |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9617 | s&@top_builddir@&$ac_top_builddir_sub&;t t |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9618 | s&@top_build_prefix@&$ac_top_build_prefix&;t t |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9619 | s&@srcdir@&$ac_srcdir&;t t |
| 9620 | s&@abs_srcdir@&$ac_abs_srcdir&;t t |
| 9621 | s&@top_srcdir@&$ac_top_srcdir&;t t |
| 9622 | s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t |
| 9623 | s&@builddir@&$ac_builddir&;t t |
| 9624 | s&@abs_builddir@&$ac_abs_builddir&;t t |
| 9625 | s&@abs_top_builddir@&$ac_abs_top_builddir&;t t |
| 9626 | s&@INSTALL@&$ac_INSTALL&;t t |
| 9627 | $ac_datarootdir_hack |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9628 | " |
| 9629 | eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ |
| 9630 | >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9631 | |
| 9632 | test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9633 | { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && |
| 9634 | { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ |
| 9635 | "$ac_tmp/out"`; test -z "$ac_out"; } && |
| 9636 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' |
| 9637 | which seems to be undefined. Please make sure it is defined" >&5 |
| 9638 | $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' |
| 9639 | which seems to be undefined. Please make sure it is defined" >&2;} |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9640 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9641 | rm -f "$ac_tmp/stdin" |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9642 | case $ac_file in |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9643 | -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; |
| 9644 | *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; |
| 9645 | esac \ |
| 9646 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9647 | ;; |
| 9648 | :H) |
| 9649 | # |
| 9650 | # CONFIG_HEADER |
| 9651 | # |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9652 | if test x"$ac_file" != x-; then |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9653 | { |
| 9654 | $as_echo "/* $configure_input */" \ |
| 9655 | && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" |
| 9656 | } >"$ac_tmp/config.h" \ |
| 9657 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
| 9658 | if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then |
| 9659 | { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 |
| 9660 | $as_echo "$as_me: $ac_file is unchanged" >&6;} |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9661 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9662 | rm -f "$ac_file" |
| 9663 | mv "$ac_tmp/config.h" "$ac_file" \ |
| 9664 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9665 | fi |
| 9666 | else |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9667 | $as_echo "/* $configure_input */" \ |
| 9668 | && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ |
| 9669 | || as_fn_error $? "could not create -" "$LINENO" 5 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9670 | fi |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9671 | ;; |
| 9672 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9673 | :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 |
| 9674 | $as_echo "$as_me: executing $ac_file commands" >&6;} |
| 9675 | ;; |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9676 | esac |
| 9677 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9678 | |
| 9679 | case $ac_file$ac_mode in |
| 9680 | "default-1":C) if test -f .devel; then |
| 9681 | echo timestamp > stamp-h |
| 9682 | cat Makefile-devel-adds >> Makefile |
| 9683 | make depend |
| 9684 | fi ;; |
| 9685 | |
| 9686 | esac |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9687 | done # for ac_tag |
| 9688 | |
| 9689 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9690 | as_fn_exit 0 |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9691 | _ACEOF |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9692 | ac_clean_files=$ac_clean_files_save |
| 9693 | |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9694 | test $ac_write_fail = 0 || |
| 9695 | as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 |
| 9696 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9697 | |
| 9698 | # configure is writing to config.log, and then calls config.status. |
| 9699 | # config.status does its own redirection, appending to config.log. |
| 9700 | # Unfortunately, on DOS this fails, as config.log is still kept open |
| 9701 | # by configure, so config.status won't be able to write to it; its |
| 9702 | # output is simply discarded. So we exec the FD to /dev/null, |
| 9703 | # effectively closing config.log, so it can be properly (re)opened and |
| 9704 | # appended to by config.status. When coming back to configure, we |
| 9705 | # need to make the FD available again. |
| 9706 | if test "$no_create" != yes; then |
| 9707 | ac_cs_success=: |
| 9708 | ac_config_status_args= |
| 9709 | test "$silent" = yes && |
| 9710 | ac_config_status_args="$ac_config_status_args --quiet" |
| 9711 | exec 5>/dev/null |
| 9712 | $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false |
| 9713 | exec 5>>config.log |
| 9714 | # Use ||, not &&, to avoid exiting from the if with $? = 1, which |
| 9715 | # would make configure fail if this is the last instruction. |
JP Abgrall | 511eca3 | 2014-02-12 13:46:45 -0800 | [diff] [blame] | 9716 | $ac_cs_success || as_fn_exit 1 |
| 9717 | fi |
| 9718 | if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then |
| 9719 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 |
| 9720 | $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9721 | fi |
| 9722 | |
The Android Open Source Project | 478ab6c | 2009-03-03 19:30:05 -0800 | [diff] [blame] | 9723 | exit 0 |