| 1483 | |
| 1484 | ## ------------------------ ## |
| 1485 | ## Autoconf initialization. ## |
| 1486 | ## ------------------------ ## |
| 1487 | |
| 1488 | # ac_fn_c_try_compile LINENO |
| 1489 | # -------------------------- |
| 1490 | # Try to compile conftest.$ac_ext, and return whether this succeeded. |
| 1491 | ac_fn_c_try_compile () |
| 1492 | { |
| 1493 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1494 | rm -f conftest.$ac_objext |
| 1495 | if { { ac_try="$ac_compile" |
| 1496 | case "(($ac_try" in |
| 1497 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1498 | *) ac_try_echo=$ac_try;; |
| 1499 | esac |
| 1500 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1501 | $as_echo "$ac_try_echo"; } >&5 |
| 1502 | (eval "$ac_compile") 2>conftest.err |
| 1503 | ac_status=$? |
| 1504 | if test -s conftest.err; then |
| 1505 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1506 | cat conftest.er1 >&5 |
| 1507 | mv -f conftest.er1 conftest.err |
| 1508 | fi |
| 1509 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1510 | test $ac_status = 0; } && { |
| 1511 | test -z "$ac_c_werror_flag" || |
| 1512 | test ! -s conftest.err |
| 1513 | } && test -s conftest.$ac_objext; then : |
| 1514 | ac_retval=0 |
| 1515 | else |
| 1516 | $as_echo "$as_me: failed program was:" >&5 |
| 1517 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1518 | |
| 1519 | ac_retval=1 |
| 1520 | fi |
| 1521 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
| 1522 | as_fn_set_status $ac_retval |
| 1523 | |
| 1524 | } # ac_fn_c_try_compile |
| 1525 | |
| 1526 | # ac_fn_cxx_try_compile LINENO |
| 1527 | # ---------------------------- |
| 1528 | # Try to compile conftest.$ac_ext, and return whether this succeeded. |
| 1529 | ac_fn_cxx_try_compile () |
| 1530 | { |
| 1531 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1532 | rm -f conftest.$ac_objext |
| 1533 | if { { ac_try="$ac_compile" |
| 1534 | case "(($ac_try" in |
| 1535 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1536 | *) ac_try_echo=$ac_try;; |
| 1537 | esac |
| 1538 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1539 | $as_echo "$ac_try_echo"; } >&5 |
| 1540 | (eval "$ac_compile") 2>conftest.err |
| 1541 | ac_status=$? |
| 1542 | if test -s conftest.err; then |
| 1543 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1544 | cat conftest.er1 >&5 |
| 1545 | mv -f conftest.er1 conftest.err |
| 1546 | fi |
| 1547 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1548 | test $ac_status = 0; } && { |
| 1549 | test -z "$ac_cxx_werror_flag" || |
| 1550 | test ! -s conftest.err |
| 1551 | } && test -s conftest.$ac_objext; then : |
| 1552 | ac_retval=0 |
| 1553 | else |
| 1554 | $as_echo "$as_me: failed program was:" >&5 |
| 1555 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1556 | |
| 1557 | ac_retval=1 |
| 1558 | fi |
| 1559 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
| 1560 | as_fn_set_status $ac_retval |
| 1561 | |
| 1562 | } # ac_fn_cxx_try_compile |
| 1563 | |
| 1564 | # ac_fn_c_try_cpp LINENO |
| 1565 | # ---------------------- |
| 1566 | # Try to preprocess conftest.$ac_ext, and return whether this succeeded. |
| 1567 | ac_fn_c_try_cpp () |
| 1568 | { |
| 1569 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1570 | if { { ac_try="$ac_cpp conftest.$ac_ext" |
| 1571 | case "(($ac_try" in |
| 1572 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1573 | *) ac_try_echo=$ac_try;; |
| 1574 | esac |
| 1575 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1576 | $as_echo "$ac_try_echo"; } >&5 |
| 1577 | (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err |
| 1578 | ac_status=$? |
| 1579 | if test -s conftest.err; then |
| 1580 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1581 | cat conftest.er1 >&5 |
| 1582 | mv -f conftest.er1 conftest.err |
| 1583 | fi |
| 1584 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1585 | test $ac_status = 0; } > conftest.i && { |
| 1586 | test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || |
| 1587 | test ! -s conftest.err |
| 1588 | }; then : |
| 1589 | ac_retval=0 |
| 1590 | else |
| 1591 | $as_echo "$as_me: failed program was:" >&5 |
| 1592 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1593 | |
| 1594 | ac_retval=1 |
| 1595 | fi |
| 1596 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
| 1597 | as_fn_set_status $ac_retval |
| 1598 | |
| 1599 | } # ac_fn_c_try_cpp |
| 1600 | |
| 1601 | # ac_fn_c_try_run LINENO |
| 1602 | # ---------------------- |
| 1603 | # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes |
| 1604 | # that executables *can* be run. |
| 1605 | ac_fn_c_try_run () |
| 1606 | { |
| 1607 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1608 | if { { ac_try="$ac_link" |
| 1609 | case "(($ac_try" in |
| 1610 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1611 | *) ac_try_echo=$ac_try;; |
| 1612 | esac |
| 1613 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1614 | $as_echo "$ac_try_echo"; } >&5 |
| 1615 | (eval "$ac_link") 2>&5 |
| 1616 | ac_status=$? |
| 1617 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1618 | test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' |
| 1619 | { { case "(($ac_try" in |
| 1620 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1621 | *) ac_try_echo=$ac_try;; |
| 1622 | esac |
| 1623 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1624 | $as_echo "$ac_try_echo"; } >&5 |
| 1625 | (eval "$ac_try") 2>&5 |
| 1626 | ac_status=$? |
| 1627 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1628 | test $ac_status = 0; }; }; then : |
| 1629 | ac_retval=0 |
| 1630 | else |
| 1631 | $as_echo "$as_me: program exited with status $ac_status" >&5 |
| 1632 | $as_echo "$as_me: failed program was:" >&5 |
| 1633 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1634 | |
| 1635 | ac_retval=$ac_status |
| 1636 | fi |
| 1637 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo |
| 1638 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
| 1639 | as_fn_set_status $ac_retval |
| 1640 | |
| 1641 | } # ac_fn_c_try_run |
| 1642 | |
| 1643 | # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES |
| 1644 | # ------------------------------------------------------- |
| 1645 | # Tests whether HEADER exists and can be compiled using the include files in |
| 1646 | # INCLUDES, setting the cache variable VAR accordingly. |
| 1647 | ac_fn_c_check_header_compile () |
| 1648 | { |
| 1649 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1650 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1651 | $as_echo_n "checking for $2... " >&6; } |
| 1652 | if eval \${$3+:} false; then : |
| 1653 | $as_echo_n "(cached) " >&6 |
| 1654 | else |
| 1655 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1656 | /* end confdefs.h. */ |
| 1657 | $4 |
| 1658 | #include <$2> |
| 1659 | _ACEOF |
| 1660 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1661 | eval "$3=yes" |
| 1662 | else |
| 1663 | eval "$3=no" |
| 1664 | fi |
| 1665 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1666 | fi |
| 1667 | eval ac_res=\$$3 |
| 1668 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1669 | $as_echo "$ac_res" >&6; } |
| 1670 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
| 1671 | |
| 1672 | } # ac_fn_c_check_header_compile |
| 1673 | |
| 1674 | # ac_fn_c_try_link LINENO |
| 1675 | # ----------------------- |
| 1676 | # Try to link conftest.$ac_ext, and return whether this succeeded. |
| 1677 | ac_fn_c_try_link () |
| 1678 | { |
| 1679 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1680 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 1681 | if { { ac_try="$ac_link" |
| 1682 | case "(($ac_try" in |
| 1683 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1684 | *) ac_try_echo=$ac_try;; |
| 1685 | esac |
| 1686 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1687 | $as_echo "$ac_try_echo"; } >&5 |
| 1688 | (eval "$ac_link") 2>conftest.err |
| 1689 | ac_status=$? |
| 1690 | if test -s conftest.err; then |
| 1691 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1692 | cat conftest.er1 >&5 |
| 1693 | mv -f conftest.er1 conftest.err |
| 1694 | fi |
| 1695 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1696 | test $ac_status = 0; } && { |
| 1697 | test -z "$ac_c_werror_flag" || |
| 1698 | test ! -s conftest.err |
| 1699 | } && test -s conftest$ac_exeext && { |
| 1700 | test "$cross_compiling" = yes || |
| 1701 | test -x conftest$ac_exeext |
| 1702 | }; then : |
| 1703 | ac_retval=0 |
| 1704 | else |
| 1705 | $as_echo "$as_me: failed program was:" >&5 |
| 1706 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1707 | |
| 1708 | ac_retval=1 |
| 1709 | fi |
| 1710 | # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information |
| 1711 | # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would |
| 1712 | # interfere with the next link command; also delete a directory that is |
| 1713 | # left behind by Apple's compiler. We do this before executing the actions. |
| 1714 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo |
| 1715 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
| 1716 | as_fn_set_status $ac_retval |
| 1717 | |
| 1718 | } # ac_fn_c_try_link |
| 1719 | |
| 1720 | # ac_fn_c_check_func LINENO FUNC VAR |
| 1721 | # ---------------------------------- |
| 1722 | # Tests whether FUNC exists, setting the cache variable VAR accordingly |
| 1723 | ac_fn_c_check_func () |
| 1724 | { |
| 1725 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1726 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1727 | $as_echo_n "checking for $2... " >&6; } |
| 1728 | if eval \${$3+:} false; then : |
| 1729 | $as_echo_n "(cached) " >&6 |
| 1730 | else |
| 1731 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1732 | /* end confdefs.h. */ |
| 1733 | /* Define $2 to an innocuous variant, in case <limits.h> declares $2. |
| 1734 | For example, HP-UX 11i <limits.h> declares gettimeofday. */ |
| 1735 | #define $2 innocuous_$2 |
| 1736 | |
| 1737 | /* System header to define __stub macros and hopefully few prototypes, |
| 1738 | which can conflict with char $2 (); below. |
| 1739 | Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 1740 | <limits.h> exists even on freestanding compilers. */ |
| 1741 | |
| 1742 | #ifdef __STDC__ |
| 1743 | # include <limits.h> |
| 1744 | #else |
| 1745 | # include <assert.h> |
| 1746 | #endif |
| 1747 | |
| 1748 | #undef $2 |
| 1749 | |
| 1750 | /* Override any GCC internal prototype to avoid an error. |
| 1751 | Use char because int might match the return type of a GCC |
| 1752 | builtin and then its argument prototype would still apply. */ |
| 1753 | #ifdef __cplusplus |
| 1754 | extern "C" |
| 1755 | #endif |
| 1756 | char $2 (); |
| 1757 | /* The GNU C library defines this for functions which it implements |
| 1758 | to always fail with ENOSYS. Some functions are actually named |
| 1759 | something starting with __ and the normal name is an alias. */ |
| 1760 | #if defined __stub_$2 || defined __stub___$2 |
| 1761 | choke me |
| 1762 | #endif |
| 1763 | |
| 1764 | int |
| 1765 | main () |
| 1766 | { |
| 1767 | return $2 (); |
| 1768 | ; |
| 1769 | return 0; |
| 1770 | } |
| 1771 | _ACEOF |
| 1772 | if ac_fn_c_try_link "$LINENO"; then : |
| 1773 | eval "$3=yes" |
| 1774 | else |
| 1775 | eval "$3=no" |
| 1776 | fi |
| 1777 | rm -f core conftest.err conftest.$ac_objext \ |
| 1778 | conftest$ac_exeext conftest.$ac_ext |
| 1779 | fi |
| 1780 | eval ac_res=\$$3 |
| 1781 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1782 | $as_echo "$ac_res" >&6; } |
| 1783 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
| 1784 | |
| 1785 | } # ac_fn_c_check_func |
| 1786 | |
| 1787 | # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES |
| 1788 | # ------------------------------------------------------- |
| 1789 | # Tests whether HEADER exists, giving a warning if it cannot be compiled using |
| 1790 | # the include files in INCLUDES and setting the cache variable VAR |
| 1791 | # accordingly. |
| 1792 | ac_fn_c_check_header_mongrel () |
| 1793 | { |
| 1794 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1795 | if eval \${$3+:} false; then : |
| 1796 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1797 | $as_echo_n "checking for $2... " >&6; } |
| 1798 | if eval \${$3+:} false; then : |
| 1799 | $as_echo_n "(cached) " >&6 |
| 1800 | fi |
| 1801 | eval ac_res=\$$3 |
| 1802 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1803 | $as_echo "$ac_res" >&6; } |
| 1804 | else |
| 1805 | # Is the header compilable? |
| 1806 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 |
| 1807 | $as_echo_n "checking $2 usability... " >&6; } |
| 1808 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1809 | /* end confdefs.h. */ |
| 1810 | $4 |
| 1811 | #include <$2> |
| 1812 | _ACEOF |
| 1813 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1814 | ac_header_compiler=yes |
| 1815 | else |
| 1816 | ac_header_compiler=no |
| 1817 | fi |
| 1818 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1819 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 |
| 1820 | $as_echo "$ac_header_compiler" >&6; } |
| 1821 | |
| 1822 | # Is the header present? |
| 1823 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 |
| 1824 | $as_echo_n "checking $2 presence... " >&6; } |
| 1825 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1826 | /* end confdefs.h. */ |
| 1827 | #include <$2> |
| 1828 | _ACEOF |
| 1829 | if ac_fn_c_try_cpp "$LINENO"; then : |
| 1830 | ac_header_preproc=yes |
| 1831 | else |
| 1832 | ac_header_preproc=no |
| 1833 | fi |
| 1834 | rm -f conftest.err conftest.i conftest.$ac_ext |
| 1835 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 |
| 1836 | $as_echo "$ac_header_preproc" >&6; } |
| 1837 | |
| 1838 | # So? What about this header? |
| 1839 | case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( |
| 1840 | yes:no: ) |
| 1841 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 |
| 1842 | $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} |
| 1843 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 |
| 1844 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} |
| 1845 | ;; |
| 1846 | no:yes:* ) |
| 1847 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 |
| 1848 | $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} |
| 1849 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 |
| 1850 | $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} |
| 1851 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 |
| 1852 | $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} |
| 1853 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 |
| 1854 | $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} |
| 1855 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 |
| 1856 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} |
| 1857 | ;; |
| 1858 | esac |
| 1859 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1860 | $as_echo_n "checking for $2... " >&6; } |
| 1861 | if eval \${$3+:} false; then : |
| 1862 | $as_echo_n "(cached) " >&6 |
| 1863 | else |
| 1864 | eval "$3=\$ac_header_compiler" |
| 1865 | fi |
| 1866 | eval ac_res=\$$3 |
| 1867 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1868 | $as_echo "$ac_res" >&6; } |
| 1869 | fi |
| 1870 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
| 1871 | |
| 1872 | } # ac_fn_c_check_header_mongrel |
| 1873 | |
| 1874 | # ac_fn_f77_try_compile LINENO |
| 1875 | # ---------------------------- |
| 1876 | # Try to compile conftest.$ac_ext, and return whether this succeeded. |
| 1877 | ac_fn_f77_try_compile () |
| 1878 | { |
| 1879 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1880 | rm -f conftest.$ac_objext |
| 1881 | if { { ac_try="$ac_compile" |
| 1882 | case "(($ac_try" in |
| 1883 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1884 | *) ac_try_echo=$ac_try;; |
| 1885 | esac |
| 1886 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1887 | $as_echo "$ac_try_echo"; } >&5 |
| 1888 | (eval "$ac_compile") 2>conftest.err |
| 1889 | ac_status=$? |
| 1890 | if test -s conftest.err; then |
| 1891 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1892 | cat conftest.er1 >&5 |
| 1893 | mv -f conftest.er1 conftest.err |
| 1894 | fi |
| 1895 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1896 | test $ac_status = 0; } && { |
| 1897 | test -z "$ac_f77_werror_flag" || |
| 1898 | test ! -s conftest.err |
| 1899 | } && test -s conftest.$ac_objext; then : |
| 1900 | ac_retval=0 |
| 1901 | else |
| 1902 | $as_echo "$as_me: failed program was:" >&5 |
| 1903 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1904 | |
| 1905 | ac_retval=1 |
| 1906 | fi |
| 1907 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
| 1908 | as_fn_set_status $ac_retval |
| 1909 | |
| 1910 | } # ac_fn_f77_try_compile |
2286 | | |
2287 | | # Don't put any macros that use the compiler (e.g. AC_TRY_COMPILE) |
2288 | | # in this macro, they need to go into TEA_SETUP_COMPILER instead. |
2289 | | |
2290 | | # If the user did not set CFLAGS, set it now to keep |
2291 | | # the AC_PROG_CC macro from adding "-g -O2". |
2292 | | if test "${CFLAGS+set}" != "set" ; then |
2293 | | CFLAGS="" |
2294 | | fi |
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 | | if test -n "$ac_tool_prefix"; then |
2302 | | # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. |
2303 | | set dummy ${ac_tool_prefix}gcc; ac_word=$2 |
2304 | | { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 |
2305 | | $as_echo_n "checking for $ac_word... " >&6; } |
2306 | | if test "${ac_cv_prog_CC+set}" = set; then |
2307 | | $as_echo_n "(cached) " >&6 |
2308 | | else |
2309 | | if test -n "$CC"; then |
2310 | | ac_cv_prog_CC="$CC" # Let the user override the test. |
2311 | | else |
2312 | | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
2313 | | for as_dir in $PATH |
2314 | | do |
2315 | | IFS=$as_save_IFS |
2316 | | test -z "$as_dir" && as_dir=. |
2317 | | for ac_exec_ext in '' $ac_executable_extensions; do |
2318 | | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
2319 | | ac_cv_prog_CC="${ac_tool_prefix}gcc" |
2320 | | $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 |
2321 | | break 2 |
2322 | | fi |
2323 | | done |
2324 | | done |
2325 | | IFS=$as_save_IFS |
2326 | | |
2327 | | fi |
2328 | | fi |
2329 | | CC=$ac_cv_prog_CC |
2330 | | if test -n "$CC"; then |
2331 | | { $as_echo "$as_me:$LINENO: result: $CC" >&5 |
2332 | | $as_echo "$CC" >&6; } |
2333 | | else |
2334 | | { $as_echo "$as_me:$LINENO: result: no" >&5 |
2335 | | $as_echo "no" >&6; } |
2336 | | fi |
2337 | | |
2338 | | |
2339 | | fi |
2340 | | if test -z "$ac_cv_prog_CC"; then |
2341 | | ac_ct_CC=$CC |
2342 | | # Extract the first word of "gcc", so it can be a program name with args. |
2343 | | set dummy gcc; ac_word=$2 |
2344 | | { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 |
2345 | | $as_echo_n "checking for $ac_word... " >&6; } |
2346 | | if test "${ac_cv_prog_ac_ct_CC+set}" = set; then |
2347 | | $as_echo_n "(cached) " >&6 |
2348 | | else |
2349 | | if test -n "$ac_ct_CC"; then |
2350 | | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. |
2351 | | else |
2352 | | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
2353 | | for as_dir in $PATH |
2354 | | do |
2355 | | IFS=$as_save_IFS |
2356 | | test -z "$as_dir" && as_dir=. |
2357 | | for ac_exec_ext in '' $ac_executable_extensions; do |
2358 | | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
2359 | | ac_cv_prog_ac_ct_CC="gcc" |
2360 | | $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 |
2361 | | break 2 |
2362 | | fi |
2363 | | done |
2364 | | done |
2365 | | IFS=$as_save_IFS |
2366 | | |
2367 | | fi |
2368 | | fi |
2369 | | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
2370 | | if test -n "$ac_ct_CC"; then |
2371 | | { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 |
2372 | | $as_echo "$ac_ct_CC" >&6; } |
2373 | | else |
2374 | | { $as_echo "$as_me:$LINENO: result: no" >&5 |
2375 | | $as_echo "no" >&6; } |
2376 | | fi |
2377 | | |
2378 | | if test "x$ac_ct_CC" = x; then |
2379 | | CC="" |
2380 | | else |
2381 | | case $cross_compiling:$ac_tool_warned in |
2382 | | yes:) |
2383 | | { $as_echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools |
2384 | | whose name does not start with the host triplet. If you think this |
2385 | | configuration is useful to you, please write to autoconf@gnu.org." >&5 |
2386 | | $as_echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools |
2387 | | whose name does not start with the host triplet. If you think this |
2388 | | configuration is useful to you, please write to autoconf@gnu.org." >&2;} |
2389 | | ac_tool_warned=yes ;; |
2390 | | esac |
2391 | | CC=$ac_ct_CC |
2392 | | fi |
2393 | | else |
2394 | | CC="$ac_cv_prog_CC" |
2395 | | fi |
2396 | | |
2397 | | if test -z "$CC"; then |
2398 | | if test -n "$ac_tool_prefix"; then |
2399 | | # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. |
2400 | | set dummy ${ac_tool_prefix}cc; ac_word=$2 |
2401 | | { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 |
2402 | | $as_echo_n "checking for $ac_word... " >&6; } |
2403 | | if test "${ac_cv_prog_CC+set}" = set; then |
2404 | | $as_echo_n "(cached) " >&6 |
2405 | | else |
2406 | | if test -n "$CC"; then |
2407 | | ac_cv_prog_CC="$CC" # Let the user override the test. |
2408 | | else |
2409 | | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
2410 | | for as_dir in $PATH |
2411 | | do |
2412 | | IFS=$as_save_IFS |
2413 | | test -z "$as_dir" && as_dir=. |
2414 | | for ac_exec_ext in '' $ac_executable_extensions; do |
2415 | | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
2416 | | ac_cv_prog_CC="${ac_tool_prefix}cc" |
2417 | | $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 |
2418 | | break 2 |
2419 | | fi |
2420 | | done |
2421 | | done |
2422 | | IFS=$as_save_IFS |
2423 | | |
2424 | | fi |
2425 | | fi |
2426 | | CC=$ac_cv_prog_CC |
2427 | | if test -n "$CC"; then |
2428 | | { $as_echo "$as_me:$LINENO: result: $CC" >&5 |
2429 | | $as_echo "$CC" >&6; } |
2430 | | else |
2431 | | { $as_echo "$as_me:$LINENO: result: no" >&5 |
2432 | | $as_echo "no" >&6; } |
2433 | | fi |
2434 | | |
2435 | | |
2436 | | fi |
2437 | | fi |
2438 | | if test -z "$CC"; then |
2439 | | # Extract the first word of "cc", so it can be a program name with args. |
2440 | | set dummy cc; ac_word=$2 |
2441 | | { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 |
2442 | | $as_echo_n "checking for $ac_word... " >&6; } |
2443 | | if test "${ac_cv_prog_CC+set}" = set; then |
2444 | | $as_echo_n "(cached) " >&6 |
2445 | | else |
2446 | | if test -n "$CC"; then |
2447 | | ac_cv_prog_CC="$CC" # Let the user override the test. |
2448 | | else |
2449 | | ac_prog_rejected=no |
2450 | | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
2451 | | for as_dir in $PATH |
2452 | | do |
2453 | | IFS=$as_save_IFS |
2454 | | test -z "$as_dir" && as_dir=. |
2455 | | for ac_exec_ext in '' $ac_executable_extensions; do |
2456 | | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
2457 | | if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then |
2458 | | ac_prog_rejected=yes |
2459 | | continue |
2460 | | fi |
2461 | | ac_cv_prog_CC="cc" |
2462 | | $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 |
2463 | | break 2 |
2464 | | fi |
2465 | | done |
2466 | | done |
2467 | | IFS=$as_save_IFS |
2468 | | |
2469 | | if test $ac_prog_rejected = yes; then |
2470 | | # We found a bogon in the path, so make sure we never use it. |
2471 | | set dummy $ac_cv_prog_CC |
2472 | | shift |
2473 | | if test $# != 0; then |
2474 | | # We chose a different compiler from the bogus one. |
2475 | | # However, it has the same basename, so the bogon will be chosen |
2476 | | # first if we set CC to just the basename; use the full file name. |
2477 | | shift |
2478 | | ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" |
2479 | | fi |
2480 | | fi |
2481 | | fi |
2482 | | fi |
2483 | | CC=$ac_cv_prog_CC |
2484 | | if test -n "$CC"; then |
2485 | | { $as_echo "$as_me:$LINENO: result: $CC" >&5 |
2486 | | $as_echo "$CC" >&6; } |
2487 | | else |
2488 | | { $as_echo "$as_me:$LINENO: result: no" >&5 |
2489 | | $as_echo "no" >&6; } |
2490 | | fi |
2491 | | |
2492 | | |
2493 | | fi |
2494 | | if test -z "$CC"; then |
2495 | | if test -n "$ac_tool_prefix"; then |
2496 | | for ac_prog in cl.exe |
2497 | | do |
2498 | | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. |
2499 | | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 |
2500 | | { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 |
2501 | | $as_echo_n "checking for $ac_word... " >&6; } |
2502 | | if test "${ac_cv_prog_CC+set}" = set; then |
2503 | | $as_echo_n "(cached) " >&6 |
2504 | | else |
2505 | | if test -n "$CC"; then |
2506 | | ac_cv_prog_CC="$CC" # Let the user override the test. |
2507 | | else |
2508 | | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
2509 | | for as_dir in $PATH |
2510 | | do |
2511 | | IFS=$as_save_IFS |
2512 | | test -z "$as_dir" && as_dir=. |
2513 | | for ac_exec_ext in '' $ac_executable_extensions; do |
2514 | | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
2515 | | ac_cv_prog_CC="$ac_tool_prefix$ac_prog" |
2516 | | $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 |
2517 | | break 2 |
2518 | | fi |
2519 | | done |
2520 | | done |
2521 | | IFS=$as_save_IFS |
2522 | | |
2523 | | fi |
2524 | | fi |
2525 | | CC=$ac_cv_prog_CC |
2526 | | if test -n "$CC"; then |
2527 | | { $as_echo "$as_me:$LINENO: result: $CC" >&5 |
2528 | | $as_echo "$CC" >&6; } |
2529 | | else |
2530 | | { $as_echo "$as_me:$LINENO: result: no" >&5 |
2531 | | $as_echo "no" >&6; } |
2532 | | fi |
2533 | | |
2534 | | |
2535 | | test -n "$CC" && break |
2536 | | done |
2537 | | fi |
2538 | | if test -z "$CC"; then |
2539 | | ac_ct_CC=$CC |
2540 | | for ac_prog in cl.exe |
2541 | | do |
2542 | | # Extract the first word of "$ac_prog", so it can be a program name with args. |
2543 | | set dummy $ac_prog; ac_word=$2 |
2544 | | { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 |
2545 | | $as_echo_n "checking for $ac_word... " >&6; } |
2546 | | if test "${ac_cv_prog_ac_ct_CC+set}" = set; then |
2547 | | $as_echo_n "(cached) " >&6 |
2548 | | else |
2549 | | if test -n "$ac_ct_CC"; then |
2550 | | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. |
2551 | | else |
2552 | | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
2553 | | for as_dir in $PATH |
2554 | | do |
2555 | | IFS=$as_save_IFS |
2556 | | test -z "$as_dir" && as_dir=. |
2557 | | for ac_exec_ext in '' $ac_executable_extensions; do |
2558 | | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
2559 | | ac_cv_prog_ac_ct_CC="$ac_prog" |
2560 | | $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 |
2561 | | break 2 |
2562 | | fi |
2563 | | done |
2564 | | done |
2565 | | IFS=$as_save_IFS |
2566 | | |
2567 | | fi |
2568 | | fi |
2569 | | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
2570 | | if test -n "$ac_ct_CC"; then |
2571 | | { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 |
2572 | | $as_echo "$ac_ct_CC" >&6; } |
2573 | | else |
2574 | | { $as_echo "$as_me:$LINENO: result: no" >&5 |
2575 | | $as_echo "no" >&6; } |
2576 | | fi |
2577 | | |
2578 | | |
2579 | | test -n "$ac_ct_CC" && break |
2580 | | done |
2581 | | |
2582 | | if test "x$ac_ct_CC" = x; then |
2583 | | CC="" |
2584 | | else |
2585 | | case $cross_compiling:$ac_tool_warned in |
2586 | | yes:) |
2587 | | { $as_echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools |
2588 | | whose name does not start with the host triplet. If you think this |
2589 | | configuration is useful to you, please write to autoconf@gnu.org." >&5 |
2590 | | $as_echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools |
2591 | | whose name does not start with the host triplet. If you think this |
2592 | | configuration is useful to you, please write to autoconf@gnu.org." >&2;} |
2593 | | ac_tool_warned=yes ;; |
2594 | | esac |
2595 | | CC=$ac_ct_CC |
2596 | | fi |
2597 | | fi |
2598 | | |
2599 | | fi |
2600 | | |
2601 | | |
2602 | | test -z "$CC" && { { $as_echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH |
2603 | | See \`config.log' for more details." >&5 |
2604 | | $as_echo "$as_me: error: no acceptable C compiler found in \$PATH |
2605 | | See \`config.log' for more details." >&2;} |
2606 | | { (exit 1); exit 1; }; } |
2607 | | |
2608 | | # Provide some information about the compiler. |
2609 | | $as_echo "$as_me:$LINENO: checking for C compiler version" >&5 |
2610 | | set X $ac_compile |
2611 | | ac_compiler=$2 |
2612 | | { (ac_try="$ac_compiler --version >&5" |
2613 | | case "(($ac_try" in |
2614 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
2615 | | *) ac_try_echo=$ac_try;; |
2616 | | esac |
2617 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
2618 | | $as_echo "$ac_try_echo") >&5 |
2619 | | (eval "$ac_compiler --version >&5") 2>&5 |
2620 | | ac_status=$? |
2621 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
2622 | | (exit $ac_status); } |
2623 | | { (ac_try="$ac_compiler -v >&5" |
2624 | | case "(($ac_try" in |
2625 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
2626 | | *) ac_try_echo=$ac_try;; |
2627 | | esac |
2628 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
2629 | | $as_echo "$ac_try_echo") >&5 |
2630 | | (eval "$ac_compiler -v >&5") 2>&5 |
2631 | | ac_status=$? |
2632 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
2633 | | (exit $ac_status); } |
2634 | | { (ac_try="$ac_compiler -V >&5" |
2635 | | case "(($ac_try" in |
2636 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
2637 | | *) ac_try_echo=$ac_try;; |
2638 | | esac |
2639 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
2640 | | $as_echo "$ac_try_echo") >&5 |
2641 | | (eval "$ac_compiler -V >&5") 2>&5 |
2642 | | ac_status=$? |
2643 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
2644 | | (exit $ac_status); } |
2645 | | |
2646 | | cat >conftest.$ac_ext <<_ACEOF |
2647 | | /* confdefs.h. */ |
2648 | | _ACEOF |
2649 | | cat confdefs.h >>conftest.$ac_ext |
2650 | | cat >>conftest.$ac_ext <<_ACEOF |
2651 | | /* end confdefs.h. */ |
2652 | | |
2653 | | int |
2654 | | main () |
2655 | | { |
2656 | | |
2657 | | ; |
2658 | | return 0; |
2659 | | } |
2660 | | _ACEOF |
2661 | | ac_clean_files_save=$ac_clean_files |
2662 | | ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" |
2663 | | # Try to create an executable without -o first, disregard a.out. |
2664 | | # It will help us diagnose broken compilers, and finding out an intuition |
2665 | | # of exeext. |
2666 | | { $as_echo "$as_me:$LINENO: checking for C compiler default output file name" >&5 |
2667 | | $as_echo_n "checking for C compiler default output file name... " >&6; } |
2668 | | ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` |
2669 | | |
2670 | | # The possible output files: |
2671 | | ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" |
2672 | | |
2673 | | ac_rmfiles= |
2674 | | for ac_file in $ac_files |
2675 | | do |
2676 | | case $ac_file in |
2677 | | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; |
2678 | | * ) ac_rmfiles="$ac_rmfiles $ac_file";; |
2679 | | esac |
2680 | | done |
2681 | | rm -f $ac_rmfiles |
2682 | | |
2683 | | if { (ac_try="$ac_link_default" |
2684 | | case "(($ac_try" in |
2685 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
2686 | | *) ac_try_echo=$ac_try;; |
2687 | | esac |
2688 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
2689 | | $as_echo "$ac_try_echo") >&5 |
2690 | | (eval "$ac_link_default") 2>&5 |
2691 | | ac_status=$? |
2692 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
2693 | | (exit $ac_status); }; then |
2694 | | # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. |
2695 | | # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' |
2696 | | # in a Makefile. We should not override ac_cv_exeext if it was cached, |
2697 | | # so that the user can short-circuit this test for compilers unknown to |
2698 | | # Autoconf. |
2699 | | for ac_file in $ac_files '' |
2700 | | do |
2701 | | test -f "$ac_file" || continue |
2702 | | case $ac_file in |
2703 | | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) |
2704 | | ;; |
2705 | | [ab].out ) |
2706 | | # We found the default executable, but exeext='' is most |
2707 | | # certainly right. |
2708 | | break;; |
2709 | | *.* ) |
2710 | | if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; |
2711 | | then :; else |
2712 | | ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
2713 | | fi |
2714 | | # We set ac_cv_exeext here because the later test for it is not |
2715 | | # safe: cross compilers may not add the suffix if given an `-o' |
2716 | | # argument, so we may need to know it at that point already. |
2717 | | # Even if this section looks crufty: it has the advantage of |
2718 | | # actually working. |
2719 | | break;; |
2720 | | * ) |
2721 | | break;; |
2722 | | esac |
2723 | | done |
2724 | | test "$ac_cv_exeext" = no && ac_cv_exeext= |
2725 | | |
2726 | | else |
2727 | | ac_file='' |
2728 | | fi |
2729 | | |
2730 | | { $as_echo "$as_me:$LINENO: result: $ac_file" >&5 |
2731 | | $as_echo "$ac_file" >&6; } |
2732 | | if test -z "$ac_file"; then |
2733 | | $as_echo "$as_me: failed program was:" >&5 |
2734 | | sed 's/^/| /' conftest.$ac_ext >&5 |
2735 | | |
2736 | | { { $as_echo "$as_me:$LINENO: error: C compiler cannot create executables |
2737 | | See \`config.log' for more details." >&5 |
2738 | | $as_echo "$as_me: error: C compiler cannot create executables |
2739 | | See \`config.log' for more details." >&2;} |
2740 | | { (exit 77); exit 77; }; } |
2741 | | fi |
2742 | | |
2743 | | ac_exeext=$ac_cv_exeext |
2744 | | |
2745 | | # Check that the compiler produces executables we can run. If not, either |
2746 | | # the compiler is broken, or we cross compile. |
2747 | | { $as_echo "$as_me:$LINENO: checking whether the C compiler works" >&5 |
2748 | | $as_echo_n "checking whether the C compiler works... " >&6; } |
2749 | | # FIXME: These cross compiler hacks should be removed for Autoconf 3.0 |
2750 | | # If not cross compiling, check that we can run a simple program. |
2751 | | if test "$cross_compiling" != yes; then |
2752 | | if { ac_try='./$ac_file' |
2753 | | { (case "(($ac_try" in |
2754 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
2755 | | *) ac_try_echo=$ac_try;; |
2756 | | esac |
2757 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
2758 | | $as_echo "$ac_try_echo") >&5 |
2759 | | (eval "$ac_try") 2>&5 |
2760 | | ac_status=$? |
2761 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
2762 | | (exit $ac_status); }; }; then |
2763 | | cross_compiling=no |
2764 | | else |
2765 | | if test "$cross_compiling" = maybe; then |
2766 | | cross_compiling=yes |
2767 | | else |
2768 | | { { $as_echo "$as_me:$LINENO: error: cannot run C compiled programs. |
2769 | | If you meant to cross compile, use \`--host'. |
2770 | | See \`config.log' for more details." >&5 |
2771 | | $as_echo "$as_me: error: cannot run C compiled programs. |
2772 | | If you meant to cross compile, use \`--host'. |
2773 | | See \`config.log' for more details." >&2;} |
2774 | | { (exit 1); exit 1; }; } |
2775 | | fi |
2776 | | fi |
2777 | | fi |
2778 | | { $as_echo "$as_me:$LINENO: result: yes" >&5 |
2779 | | $as_echo "yes" >&6; } |
2780 | | |
2781 | | rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out |
2782 | | ac_clean_files=$ac_clean_files_save |
2783 | | # Check that the compiler produces executables we can run. If not, either |
2784 | | # the compiler is broken, or we cross compile. |
2785 | | { $as_echo "$as_me:$LINENO: checking whether we are cross compiling" >&5 |
2786 | | $as_echo_n "checking whether we are cross compiling... " >&6; } |
2787 | | { $as_echo "$as_me:$LINENO: result: $cross_compiling" >&5 |
2788 | | $as_echo "$cross_compiling" >&6; } |
2789 | | |
2790 | | { $as_echo "$as_me:$LINENO: checking for suffix of executables" >&5 |
2791 | | $as_echo_n "checking for suffix of executables... " >&6; } |
2792 | | if { (ac_try="$ac_link" |
2793 | | case "(($ac_try" in |
2794 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
2795 | | *) ac_try_echo=$ac_try;; |
2796 | | esac |
2797 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
2798 | | $as_echo "$ac_try_echo") >&5 |
2799 | | (eval "$ac_link") 2>&5 |
2800 | | ac_status=$? |
2801 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
2802 | | (exit $ac_status); }; then |
2803 | | # If both `conftest.exe' and `conftest' are `present' (well, observable) |
2804 | | # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will |
2805 | | # work properly (i.e., refer to `conftest.exe'), while it won't with |
2806 | | # `rm'. |
2807 | | for ac_file in conftest.exe conftest conftest.*; do |
2808 | | test -f "$ac_file" || continue |
2809 | | case $ac_file in |
2810 | | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; |
2811 | | *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
2812 | | break;; |
2813 | | * ) break;; |
2814 | | esac |
2815 | | done |
2816 | | else |
2817 | | { { $as_echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link |
2818 | | See \`config.log' for more details." >&5 |
2819 | | $as_echo "$as_me: error: cannot compute suffix of executables: cannot compile and link |
2820 | | See \`config.log' for more details." >&2;} |
2821 | | { (exit 1); exit 1; }; } |
2822 | | fi |
2823 | | |
2824 | | rm -f conftest$ac_cv_exeext |
2825 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5 |
2826 | | $as_echo "$ac_cv_exeext" >&6; } |
2827 | | |
2828 | | rm -f conftest.$ac_ext |
2829 | | EXEEXT=$ac_cv_exeext |
2830 | | ac_exeext=$EXEEXT |
2831 | | { $as_echo "$as_me:$LINENO: checking for suffix of object files" >&5 |
2832 | | $as_echo_n "checking for suffix of object files... " >&6; } |
2833 | | if test "${ac_cv_objext+set}" = set; then |
2834 | | $as_echo_n "(cached) " >&6 |
2835 | | else |
2836 | | cat >conftest.$ac_ext <<_ACEOF |
2837 | | /* confdefs.h. */ |
2838 | | _ACEOF |
2839 | | cat confdefs.h >>conftest.$ac_ext |
2840 | | cat >>conftest.$ac_ext <<_ACEOF |
2841 | | /* end confdefs.h. */ |
2842 | | |
2843 | | int |
2844 | | main () |
2845 | | { |
2846 | | |
2847 | | ; |
2848 | | return 0; |
2849 | | } |
2850 | | _ACEOF |
2851 | | rm -f conftest.o conftest.obj |
2852 | | if { (ac_try="$ac_compile" |
2853 | | case "(($ac_try" in |
2854 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
2855 | | *) ac_try_echo=$ac_try;; |
2856 | | esac |
2857 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
2858 | | $as_echo "$ac_try_echo") >&5 |
2859 | | (eval "$ac_compile") 2>&5 |
2860 | | ac_status=$? |
2861 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
2862 | | (exit $ac_status); }; then |
2863 | | for ac_file in conftest.o conftest.obj conftest.*; do |
2864 | | test -f "$ac_file" || continue; |
2865 | | case $ac_file in |
2866 | | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; |
2867 | | *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` |
2868 | | break;; |
2869 | | esac |
2870 | | done |
2871 | | else |
2872 | | $as_echo "$as_me: failed program was:" >&5 |
2873 | | sed 's/^/| /' conftest.$ac_ext >&5 |
2874 | | |
2875 | | { { $as_echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile |
2876 | | See \`config.log' for more details." >&5 |
2877 | | $as_echo "$as_me: error: cannot compute suffix of object files: cannot compile |
2878 | | See \`config.log' for more details." >&2;} |
2879 | | { (exit 1); exit 1; }; } |
2880 | | fi |
2881 | | |
2882 | | rm -f conftest.$ac_cv_objext conftest.$ac_ext |
2883 | | fi |
2884 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_objext" >&5 |
2885 | | $as_echo "$ac_cv_objext" >&6; } |
2886 | | OBJEXT=$ac_cv_objext |
2887 | | ac_objext=$OBJEXT |
2888 | | { $as_echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5 |
2889 | | $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } |
2890 | | if test "${ac_cv_c_compiler_gnu+set}" = set; then |
2891 | | $as_echo_n "(cached) " >&6 |
2892 | | else |
2893 | | cat >conftest.$ac_ext <<_ACEOF |
2894 | | /* confdefs.h. */ |
2895 | | _ACEOF |
2896 | | cat confdefs.h >>conftest.$ac_ext |
2897 | | cat >>conftest.$ac_ext <<_ACEOF |
2898 | | /* end confdefs.h. */ |
2899 | | |
2900 | | int |
2901 | | main () |
2902 | | { |
2903 | | #ifndef __GNUC__ |
2904 | | choke me |
2905 | | #endif |
2906 | | |
2907 | | ; |
2908 | | return 0; |
2909 | | } |
2910 | | _ACEOF |
2911 | | rm -f conftest.$ac_objext |
2912 | | if { (ac_try="$ac_compile" |
2913 | | case "(($ac_try" in |
2914 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
2915 | | *) ac_try_echo=$ac_try;; |
2916 | | esac |
2917 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
2918 | | $as_echo "$ac_try_echo") >&5 |
2919 | | (eval "$ac_compile") 2>conftest.er1 |
2920 | | ac_status=$? |
2921 | | grep -v '^ *+' conftest.er1 >conftest.err |
2922 | | rm -f conftest.er1 |
2923 | | cat conftest.err >&5 |
2924 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
2925 | | (exit $ac_status); } && { |
2926 | | test -z "$ac_c_werror_flag" || |
2927 | | test ! -s conftest.err |
2928 | | } && test -s conftest.$ac_objext; then |
2929 | | ac_compiler_gnu=yes |
2930 | | else |
2931 | | $as_echo "$as_me: failed program was:" >&5 |
2932 | | sed 's/^/| /' conftest.$ac_ext >&5 |
2933 | | |
2934 | | ac_compiler_gnu=no |
2935 | | fi |
2936 | | |
2937 | | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
2938 | | ac_cv_c_compiler_gnu=$ac_compiler_gnu |
2939 | | |
2940 | | fi |
2941 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5 |
2942 | | $as_echo "$ac_cv_c_compiler_gnu" >&6; } |
2943 | | if test $ac_compiler_gnu = yes; then |
2944 | | GCC=yes |
2945 | | else |
2946 | | GCC= |
2947 | | fi |
2948 | | ac_test_CFLAGS=${CFLAGS+set} |
2949 | | ac_save_CFLAGS=$CFLAGS |
2950 | | { $as_echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5 |
2951 | | $as_echo_n "checking whether $CC accepts -g... " >&6; } |
2952 | | if test "${ac_cv_prog_cc_g+set}" = set; then |
2953 | | $as_echo_n "(cached) " >&6 |
2954 | | else |
2955 | | ac_save_c_werror_flag=$ac_c_werror_flag |
2956 | | ac_c_werror_flag=yes |
2957 | | ac_cv_prog_cc_g=no |
2958 | | CFLAGS="-g" |
2959 | | cat >conftest.$ac_ext <<_ACEOF |
2960 | | /* confdefs.h. */ |
2961 | | _ACEOF |
2962 | | cat confdefs.h >>conftest.$ac_ext |
2963 | | cat >>conftest.$ac_ext <<_ACEOF |
2964 | | /* end confdefs.h. */ |
2965 | | |
2966 | | int |
2967 | | main () |
2968 | | { |
2969 | | |
2970 | | ; |
2971 | | return 0; |
2972 | | } |
2973 | | _ACEOF |
2974 | | rm -f conftest.$ac_objext |
2975 | | if { (ac_try="$ac_compile" |
2976 | | case "(($ac_try" in |
2977 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
2978 | | *) ac_try_echo=$ac_try;; |
2979 | | esac |
2980 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
2981 | | $as_echo "$ac_try_echo") >&5 |
2982 | | (eval "$ac_compile") 2>conftest.er1 |
2983 | | ac_status=$? |
2984 | | grep -v '^ *+' conftest.er1 >conftest.err |
2985 | | rm -f conftest.er1 |
2986 | | cat conftest.err >&5 |
2987 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
2988 | | (exit $ac_status); } && { |
2989 | | test -z "$ac_c_werror_flag" || |
2990 | | test ! -s conftest.err |
2991 | | } && test -s conftest.$ac_objext; then |
2992 | | ac_cv_prog_cc_g=yes |
2993 | | else |
2994 | | $as_echo "$as_me: failed program was:" >&5 |
2995 | | sed 's/^/| /' conftest.$ac_ext >&5 |
2996 | | |
2997 | | CFLAGS="" |
2998 | | cat >conftest.$ac_ext <<_ACEOF |
2999 | | /* confdefs.h. */ |
3000 | | _ACEOF |
3001 | | cat confdefs.h >>conftest.$ac_ext |
3002 | | cat >>conftest.$ac_ext <<_ACEOF |
3003 | | /* end confdefs.h. */ |
3004 | | |
3005 | | int |
3006 | | main () |
3007 | | { |
3008 | | |
3009 | | ; |
3010 | | return 0; |
3011 | | } |
3012 | | _ACEOF |
3013 | | rm -f conftest.$ac_objext |
3014 | | if { (ac_try="$ac_compile" |
3015 | | case "(($ac_try" in |
3016 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
3017 | | *) ac_try_echo=$ac_try;; |
3018 | | esac |
3019 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
3020 | | $as_echo "$ac_try_echo") >&5 |
3021 | | (eval "$ac_compile") 2>conftest.er1 |
3022 | | ac_status=$? |
3023 | | grep -v '^ *+' conftest.er1 >conftest.err |
3024 | | rm -f conftest.er1 |
3025 | | cat conftest.err >&5 |
3026 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
3027 | | (exit $ac_status); } && { |
3028 | | test -z "$ac_c_werror_flag" || |
3029 | | test ! -s conftest.err |
3030 | | } && test -s conftest.$ac_objext; then |
3031 | | : |
3032 | | else |
3033 | | $as_echo "$as_me: failed program was:" >&5 |
3034 | | sed 's/^/| /' conftest.$ac_ext >&5 |
3035 | | |
3036 | | ac_c_werror_flag=$ac_save_c_werror_flag |
3037 | | CFLAGS="-g" |
3038 | | cat >conftest.$ac_ext <<_ACEOF |
3039 | | /* confdefs.h. */ |
3040 | | _ACEOF |
3041 | | cat confdefs.h >>conftest.$ac_ext |
3042 | | cat >>conftest.$ac_ext <<_ACEOF |
3043 | | /* end confdefs.h. */ |
3044 | | |
3045 | | int |
3046 | | main () |
3047 | | { |
3048 | | |
3049 | | ; |
3050 | | return 0; |
3051 | | } |
3052 | | _ACEOF |
3053 | | rm -f conftest.$ac_objext |
3054 | | if { (ac_try="$ac_compile" |
3055 | | case "(($ac_try" in |
3056 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
3057 | | *) ac_try_echo=$ac_try;; |
3058 | | esac |
3059 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
3060 | | $as_echo "$ac_try_echo") >&5 |
3061 | | (eval "$ac_compile") 2>conftest.er1 |
3062 | | ac_status=$? |
3063 | | grep -v '^ *+' conftest.er1 >conftest.err |
3064 | | rm -f conftest.er1 |
3065 | | cat conftest.err >&5 |
3066 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
3067 | | (exit $ac_status); } && { |
3068 | | test -z "$ac_c_werror_flag" || |
3069 | | test ! -s conftest.err |
3070 | | } && test -s conftest.$ac_objext; then |
3071 | | ac_cv_prog_cc_g=yes |
3072 | | else |
3073 | | $as_echo "$as_me: failed program was:" >&5 |
3074 | | sed 's/^/| /' conftest.$ac_ext >&5 |
3075 | | |
3076 | | |
3077 | | fi |
3078 | | |
3079 | | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
3080 | | fi |
3081 | | |
3082 | | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
3083 | | fi |
3084 | | |
3085 | | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
3086 | | ac_c_werror_flag=$ac_save_c_werror_flag |
3087 | | fi |
3088 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5 |
3089 | | $as_echo "$ac_cv_prog_cc_g" >&6; } |
3090 | | if test "$ac_test_CFLAGS" = set; then |
3091 | | CFLAGS=$ac_save_CFLAGS |
3092 | | elif test $ac_cv_prog_cc_g = yes; then |
3093 | | if test "$GCC" = yes; then |
3094 | | CFLAGS="-g -O2" |
3095 | | else |
3096 | | CFLAGS="-g" |
3097 | | fi |
3098 | | else |
3099 | | if test "$GCC" = yes; then |
3100 | | CFLAGS="-O2" |
3101 | | else |
3102 | | CFLAGS= |
3103 | | fi |
3104 | | fi |
3105 | | { $as_echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5 |
3106 | | $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } |
3107 | | if test "${ac_cv_prog_cc_c89+set}" = set; then |
3108 | | $as_echo_n "(cached) " >&6 |
3109 | | else |
3110 | | ac_cv_prog_cc_c89=no |
3111 | | ac_save_CC=$CC |
3112 | | cat >conftest.$ac_ext <<_ACEOF |
3113 | | /* confdefs.h. */ |
3114 | | _ACEOF |
3115 | | cat confdefs.h >>conftest.$ac_ext |
3116 | | cat >>conftest.$ac_ext <<_ACEOF |
3117 | | /* end confdefs.h. */ |
3118 | | #include <stdarg.h> |
3119 | | #include <stdio.h> |
3120 | | #include <sys/types.h> |
3121 | | #include <sys/stat.h> |
3122 | | /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ |
3123 | | struct buf { int x; }; |
3124 | | FILE * (*rcsopen) (struct buf *, struct stat *, int); |
3125 | | static char *e (p, i) |
3126 | | char **p; |
3127 | | int i; |
3128 | | { |
3129 | | return p[i]; |
3130 | | } |
3131 | | static char *f (char * (*g) (char **, int), char **p, ...) |
3132 | | { |
3133 | | char *s; |
3134 | | va_list v; |
3135 | | va_start (v,p); |
3136 | | s = g (p, va_arg (v,int)); |
3137 | | va_end (v); |
3138 | | return s; |
3139 | | } |
3140 | | |
3141 | | /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has |
3142 | | function prototypes and stuff, but not '\xHH' hex character constants. |
3143 | | These don't provoke an error unfortunately, instead are silently treated |
3144 | | as 'x'. The following induces an error, until -std is added to get |
3145 | | proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an |
3146 | | array size at least. It's necessary to write '\x00'==0 to get something |
3147 | | that's true only with -std. */ |
3148 | | int osf4_cc_array ['\x00' == 0 ? 1 : -1]; |
3149 | | |
3150 | | /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters |
3151 | | inside strings and character constants. */ |
3152 | | #define FOO(x) 'x' |
3153 | | int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; |
3154 | | |
3155 | | int test (int i, double x); |
3156 | | struct s1 {int (*f) (int a);}; |
3157 | | struct s2 {int (*f) (double a);}; |
3158 | | int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); |
3159 | | int argc; |
3160 | | char **argv; |
3161 | | int |
3162 | | main () |
3163 | | { |
3164 | | return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; |
3165 | | ; |
3166 | | return 0; |
3167 | | } |
3168 | | _ACEOF |
3169 | | for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ |
3170 | | -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" |
3171 | | do |
3172 | | CC="$ac_save_CC $ac_arg" |
3173 | | rm -f conftest.$ac_objext |
3174 | | if { (ac_try="$ac_compile" |
3175 | | case "(($ac_try" in |
3176 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
3177 | | *) ac_try_echo=$ac_try;; |
3178 | | esac |
3179 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
3180 | | $as_echo "$ac_try_echo") >&5 |
3181 | | (eval "$ac_compile") 2>conftest.er1 |
3182 | | ac_status=$? |
3183 | | grep -v '^ *+' conftest.er1 >conftest.err |
3184 | | rm -f conftest.er1 |
3185 | | cat conftest.err >&5 |
3186 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
3187 | | (exit $ac_status); } && { |
3188 | | test -z "$ac_c_werror_flag" || |
3189 | | test ! -s conftest.err |
3190 | | } && test -s conftest.$ac_objext; then |
3191 | | ac_cv_prog_cc_c89=$ac_arg |
3192 | | else |
3193 | | $as_echo "$as_me: failed program was:" >&5 |
3194 | | sed 's/^/| /' conftest.$ac_ext >&5 |
3195 | | |
3196 | | |
3197 | | fi |
3198 | | |
3199 | | rm -f core conftest.err conftest.$ac_objext |
3200 | | test "x$ac_cv_prog_cc_c89" != "xno" && break |
3201 | | done |
3202 | | rm -f conftest.$ac_ext |
3203 | | CC=$ac_save_CC |
3204 | | |
3205 | | fi |
3206 | | # AC_CACHE_VAL |
3207 | | case "x$ac_cv_prog_cc_c89" in |
3208 | | x) |
3209 | | { $as_echo "$as_me:$LINENO: result: none needed" >&5 |
3210 | | $as_echo "none needed" >&6; } ;; |
3211 | | xno) |
3212 | | { $as_echo "$as_me:$LINENO: result: unsupported" >&5 |
3213 | | $as_echo "unsupported" >&6; } ;; |
3214 | | *) |
3215 | | CC="$CC $ac_cv_prog_cc_c89" |
3216 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5 |
3217 | | $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; |
3218 | | esac |
3219 | | |
3220 | | |
3221 | | ac_ext=c |
3222 | | ac_cpp='$CPP $CPPFLAGS' |
3223 | | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
3224 | | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
3225 | | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
3226 | | |
3227 | | ac_ext=cpp |
3228 | | ac_cpp='$CXXCPP $CPPFLAGS' |
3229 | | ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
3230 | | ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
3231 | | ac_compiler_gnu=$ac_cv_cxx_compiler_gnu |
3232 | | if test -z "$CXX"; then |
3233 | | if test -n "$CCC"; then |
3234 | | CXX=$CCC |
3235 | | else |
3236 | | if test -n "$ac_tool_prefix"; then |
3237 | | for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC |
3238 | | do |
3239 | | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. |
3240 | | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 |
3241 | | { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 |
3242 | | $as_echo_n "checking for $ac_word... " >&6; } |
3243 | | if test "${ac_cv_prog_CXX+set}" = set; then |
3244 | | $as_echo_n "(cached) " >&6 |
3245 | | else |
3246 | | if test -n "$CXX"; then |
3247 | | ac_cv_prog_CXX="$CXX" # Let the user override the test. |
3248 | | else |
3249 | | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
3250 | | for as_dir in $PATH |
3251 | | do |
3252 | | IFS=$as_save_IFS |
3253 | | test -z "$as_dir" && as_dir=. |
3254 | | for ac_exec_ext in '' $ac_executable_extensions; do |
3255 | | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
3256 | | ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" |
3257 | | $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 |
3258 | | break 2 |
3259 | | fi |
3260 | | done |
3261 | | done |
3262 | | IFS=$as_save_IFS |
3263 | | |
3264 | | fi |
3265 | | fi |
3266 | | CXX=$ac_cv_prog_CXX |
3267 | | if test -n "$CXX"; then |
3268 | | { $as_echo "$as_me:$LINENO: result: $CXX" >&5 |
3269 | | $as_echo "$CXX" >&6; } |
3270 | | else |
3271 | | { $as_echo "$as_me:$LINENO: result: no" >&5 |
3272 | | $as_echo "no" >&6; } |
3273 | | fi |
3274 | | |
3275 | | |
3276 | | test -n "$CXX" && break |
3277 | | done |
3278 | | fi |
3279 | | if test -z "$CXX"; then |
3280 | | ac_ct_CXX=$CXX |
3281 | | for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC |
3282 | | do |
3283 | | # Extract the first word of "$ac_prog", so it can be a program name with args. |
3284 | | set dummy $ac_prog; ac_word=$2 |
3285 | | { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 |
3286 | | $as_echo_n "checking for $ac_word... " >&6; } |
3287 | | if test "${ac_cv_prog_ac_ct_CXX+set}" = set; then |
3288 | | $as_echo_n "(cached) " >&6 |
3289 | | else |
3290 | | if test -n "$ac_ct_CXX"; then |
3291 | | ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. |
3292 | | else |
3293 | | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
3294 | | for as_dir in $PATH |
3295 | | do |
3296 | | IFS=$as_save_IFS |
3297 | | test -z "$as_dir" && as_dir=. |
3298 | | for ac_exec_ext in '' $ac_executable_extensions; do |
3299 | | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
3300 | | ac_cv_prog_ac_ct_CXX="$ac_prog" |
3301 | | $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 |
3302 | | break 2 |
3303 | | fi |
3304 | | done |
3305 | | done |
3306 | | IFS=$as_save_IFS |
3307 | | |
3308 | | fi |
3309 | | fi |
3310 | | ac_ct_CXX=$ac_cv_prog_ac_ct_CXX |
3311 | | if test -n "$ac_ct_CXX"; then |
3312 | | { $as_echo "$as_me:$LINENO: result: $ac_ct_CXX" >&5 |
3313 | | $as_echo "$ac_ct_CXX" >&6; } |
3314 | | else |
3315 | | { $as_echo "$as_me:$LINENO: result: no" >&5 |
3316 | | $as_echo "no" >&6; } |
3317 | | fi |
3318 | | |
3319 | | |
3320 | | test -n "$ac_ct_CXX" && break |
3321 | | done |
3322 | | |
3323 | | if test "x$ac_ct_CXX" = x; then |
3324 | | CXX="g++" |
3325 | | else |
3326 | | case $cross_compiling:$ac_tool_warned in |
3327 | | yes:) |
3328 | | { $as_echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools |
3329 | | whose name does not start with the host triplet. If you think this |
3330 | | configuration is useful to you, please write to autoconf@gnu.org." >&5 |
3331 | | $as_echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools |
3332 | | whose name does not start with the host triplet. If you think this |
3333 | | configuration is useful to you, please write to autoconf@gnu.org." >&2;} |
3334 | | ac_tool_warned=yes ;; |
3335 | | esac |
3336 | | CXX=$ac_ct_CXX |
3337 | | fi |
3338 | | fi |
3339 | | |
3340 | | fi |
3341 | | fi |
3342 | | # Provide some information about the compiler. |
3343 | | $as_echo "$as_me:$LINENO: checking for C++ compiler version" >&5 |
3344 | | set X $ac_compile |
3345 | | ac_compiler=$2 |
3346 | | { (ac_try="$ac_compiler --version >&5" |
3347 | | case "(($ac_try" in |
3348 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
3349 | | *) ac_try_echo=$ac_try;; |
3350 | | esac |
3351 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
3352 | | $as_echo "$ac_try_echo") >&5 |
3353 | | (eval "$ac_compiler --version >&5") 2>&5 |
3354 | | ac_status=$? |
3355 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
3356 | | (exit $ac_status); } |
3357 | | { (ac_try="$ac_compiler -v >&5" |
3358 | | case "(($ac_try" in |
3359 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
3360 | | *) ac_try_echo=$ac_try;; |
3361 | | esac |
3362 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
3363 | | $as_echo "$ac_try_echo") >&5 |
3364 | | (eval "$ac_compiler -v >&5") 2>&5 |
3365 | | ac_status=$? |
3366 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
3367 | | (exit $ac_status); } |
3368 | | { (ac_try="$ac_compiler -V >&5" |
3369 | | case "(($ac_try" in |
3370 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
3371 | | *) ac_try_echo=$ac_try;; |
3372 | | esac |
3373 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
3374 | | $as_echo "$ac_try_echo") >&5 |
3375 | | (eval "$ac_compiler -V >&5") 2>&5 |
3376 | | ac_status=$? |
3377 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
3378 | | (exit $ac_status); } |
3379 | | |
3380 | | { $as_echo "$as_me:$LINENO: checking whether we are using the GNU C++ compiler" >&5 |
3381 | | $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } |
3382 | | if test "${ac_cv_cxx_compiler_gnu+set}" = set; then |
3383 | | $as_echo_n "(cached) " >&6 |
3384 | | else |
3385 | | cat >conftest.$ac_ext <<_ACEOF |
3386 | | /* confdefs.h. */ |
3387 | | _ACEOF |
3388 | | cat confdefs.h >>conftest.$ac_ext |
3389 | | cat >>conftest.$ac_ext <<_ACEOF |
3390 | | /* end confdefs.h. */ |
3391 | | |
3392 | | int |
3393 | | main () |
3394 | | { |
3395 | | #ifndef __GNUC__ |
3396 | | choke me |
3397 | | #endif |
3398 | | |
3399 | | ; |
3400 | | return 0; |
3401 | | } |
3402 | | _ACEOF |
3403 | | rm -f conftest.$ac_objext |
3404 | | if { (ac_try="$ac_compile" |
3405 | | case "(($ac_try" in |
3406 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
3407 | | *) ac_try_echo=$ac_try;; |
3408 | | esac |
3409 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
3410 | | $as_echo "$ac_try_echo") >&5 |
3411 | | (eval "$ac_compile") 2>conftest.er1 |
3412 | | ac_status=$? |
3413 | | grep -v '^ *+' conftest.er1 >conftest.err |
3414 | | rm -f conftest.er1 |
3415 | | cat conftest.err >&5 |
3416 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
3417 | | (exit $ac_status); } && { |
3418 | | test -z "$ac_cxx_werror_flag" || |
3419 | | test ! -s conftest.err |
3420 | | } && test -s conftest.$ac_objext; then |
3421 | | ac_compiler_gnu=yes |
3422 | | else |
3423 | | $as_echo "$as_me: failed program was:" >&5 |
3424 | | sed 's/^/| /' conftest.$ac_ext >&5 |
3425 | | |
3426 | | ac_compiler_gnu=no |
3427 | | fi |
3428 | | |
3429 | | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
3430 | | ac_cv_cxx_compiler_gnu=$ac_compiler_gnu |
3431 | | |
3432 | | fi |
3433 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_cxx_compiler_gnu" >&5 |
3434 | | $as_echo "$ac_cv_cxx_compiler_gnu" >&6; } |
3435 | | if test $ac_compiler_gnu = yes; then |
3436 | | GXX=yes |
3437 | | else |
3438 | | GXX= |
3439 | | fi |
3440 | | ac_test_CXXFLAGS=${CXXFLAGS+set} |
3441 | | ac_save_CXXFLAGS=$CXXFLAGS |
3442 | | { $as_echo "$as_me:$LINENO: checking whether $CXX accepts -g" >&5 |
3443 | | $as_echo_n "checking whether $CXX accepts -g... " >&6; } |
3444 | | if test "${ac_cv_prog_cxx_g+set}" = set; then |
3445 | | $as_echo_n "(cached) " >&6 |
3446 | | else |
3447 | | ac_save_cxx_werror_flag=$ac_cxx_werror_flag |
3448 | | ac_cxx_werror_flag=yes |
3449 | | ac_cv_prog_cxx_g=no |
3450 | | CXXFLAGS="-g" |
3451 | | cat >conftest.$ac_ext <<_ACEOF |
3452 | | /* confdefs.h. */ |
3453 | | _ACEOF |
3454 | | cat confdefs.h >>conftest.$ac_ext |
3455 | | cat >>conftest.$ac_ext <<_ACEOF |
3456 | | /* end confdefs.h. */ |
3457 | | |
3458 | | int |
3459 | | main () |
3460 | | { |
3461 | | |
3462 | | ; |
3463 | | return 0; |
3464 | | } |
3465 | | _ACEOF |
3466 | | rm -f conftest.$ac_objext |
3467 | | if { (ac_try="$ac_compile" |
3468 | | case "(($ac_try" in |
3469 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
3470 | | *) ac_try_echo=$ac_try;; |
3471 | | esac |
3472 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
3473 | | $as_echo "$ac_try_echo") >&5 |
3474 | | (eval "$ac_compile") 2>conftest.er1 |
3475 | | ac_status=$? |
3476 | | grep -v '^ *+' conftest.er1 >conftest.err |
3477 | | rm -f conftest.er1 |
3478 | | cat conftest.err >&5 |
3479 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
3480 | | (exit $ac_status); } && { |
3481 | | test -z "$ac_cxx_werror_flag" || |
3482 | | test ! -s conftest.err |
3483 | | } && test -s conftest.$ac_objext; then |
3484 | | ac_cv_prog_cxx_g=yes |
3485 | | else |
3486 | | $as_echo "$as_me: failed program was:" >&5 |
3487 | | sed 's/^/| /' conftest.$ac_ext >&5 |
3488 | | |
3489 | | CXXFLAGS="" |
3490 | | cat >conftest.$ac_ext <<_ACEOF |
3491 | | /* confdefs.h. */ |
3492 | | _ACEOF |
3493 | | cat confdefs.h >>conftest.$ac_ext |
3494 | | cat >>conftest.$ac_ext <<_ACEOF |
3495 | | /* end confdefs.h. */ |
3496 | | |
3497 | | int |
3498 | | main () |
3499 | | { |
3500 | | |
3501 | | ; |
3502 | | return 0; |
3503 | | } |
3504 | | _ACEOF |
3505 | | rm -f conftest.$ac_objext |
3506 | | if { (ac_try="$ac_compile" |
3507 | | case "(($ac_try" in |
3508 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
3509 | | *) ac_try_echo=$ac_try;; |
3510 | | esac |
3511 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
3512 | | $as_echo "$ac_try_echo") >&5 |
3513 | | (eval "$ac_compile") 2>conftest.er1 |
3514 | | ac_status=$? |
3515 | | grep -v '^ *+' conftest.er1 >conftest.err |
3516 | | rm -f conftest.er1 |
3517 | | cat conftest.err >&5 |
3518 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
3519 | | (exit $ac_status); } && { |
3520 | | test -z "$ac_cxx_werror_flag" || |
3521 | | test ! -s conftest.err |
3522 | | } && test -s conftest.$ac_objext; then |
3523 | | : |
3524 | | else |
3525 | | $as_echo "$as_me: failed program was:" >&5 |
3526 | | sed 's/^/| /' conftest.$ac_ext >&5 |
3527 | | |
3528 | | ac_cxx_werror_flag=$ac_save_cxx_werror_flag |
3529 | | CXXFLAGS="-g" |
3530 | | cat >conftest.$ac_ext <<_ACEOF |
3531 | | /* confdefs.h. */ |
3532 | | _ACEOF |
3533 | | cat confdefs.h >>conftest.$ac_ext |
3534 | | cat >>conftest.$ac_ext <<_ACEOF |
3535 | | /* end confdefs.h. */ |
3536 | | |
3537 | | int |
3538 | | main () |
3539 | | { |
3540 | | |
3541 | | ; |
3542 | | return 0; |
3543 | | } |
3544 | | _ACEOF |
3545 | | rm -f conftest.$ac_objext |
3546 | | if { (ac_try="$ac_compile" |
3547 | | case "(($ac_try" in |
3548 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
3549 | | *) ac_try_echo=$ac_try;; |
3550 | | esac |
3551 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
3552 | | $as_echo "$ac_try_echo") >&5 |
3553 | | (eval "$ac_compile") 2>conftest.er1 |
3554 | | ac_status=$? |
3555 | | grep -v '^ *+' conftest.er1 >conftest.err |
3556 | | rm -f conftest.er1 |
3557 | | cat conftest.err >&5 |
3558 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
3559 | | (exit $ac_status); } && { |
3560 | | test -z "$ac_cxx_werror_flag" || |
3561 | | test ! -s conftest.err |
3562 | | } && test -s conftest.$ac_objext; then |
3563 | | ac_cv_prog_cxx_g=yes |
3564 | | else |
3565 | | $as_echo "$as_me: failed program was:" >&5 |
3566 | | sed 's/^/| /' conftest.$ac_ext >&5 |
3567 | | |
3568 | | |
3569 | | fi |
3570 | | |
3571 | | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
3572 | | fi |
3573 | | |
3574 | | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
3575 | | fi |
3576 | | |
3577 | | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
3578 | | ac_cxx_werror_flag=$ac_save_cxx_werror_flag |
3579 | | fi |
3580 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cxx_g" >&5 |
3581 | | $as_echo "$ac_cv_prog_cxx_g" >&6; } |
3582 | | if test "$ac_test_CXXFLAGS" = set; then |
3583 | | CXXFLAGS=$ac_save_CXXFLAGS |
3584 | | elif test $ac_cv_prog_cxx_g = yes; then |
3585 | | if test "$GXX" = yes; then |
3586 | | CXXFLAGS="-g -O2" |
3587 | | else |
3588 | | CXXFLAGS="-g" |
3589 | | fi |
3590 | | else |
3591 | | if test "$GXX" = yes; then |
3592 | | CXXFLAGS="-O2" |
3593 | | else |
3594 | | CXXFLAGS= |
3595 | | fi |
3596 | | fi |
3597 | | ac_ext=c |
3598 | | ac_cpp='$CPP $CPPFLAGS' |
3599 | | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
3600 | | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
3601 | | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
3602 | | |
3603 | | ac_ext=c |
3604 | | ac_cpp='$CPP $CPPFLAGS' |
3605 | | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
3606 | | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
3607 | | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
3608 | | { $as_echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5 |
3609 | | $as_echo_n "checking how to run the C preprocessor... " >&6; } |
3610 | | # On Suns, sometimes $CPP names a directory. |
3611 | | if test -n "$CPP" && test -d "$CPP"; then |
3612 | | CPP= |
3613 | | fi |
3614 | | if test -z "$CPP"; then |
3615 | | if test "${ac_cv_prog_CPP+set}" = set; then |
3616 | | $as_echo_n "(cached) " >&6 |
3617 | | else |
3618 | | # Double quotes because CPP needs to be expanded |
3619 | | for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" |
3620 | | do |
3621 | | ac_preproc_ok=false |
3622 | | for ac_c_preproc_warn_flag in '' yes |
3623 | | do |
3624 | | # Use a header file that comes with gcc, so configuring glibc |
3625 | | # with a fresh cross-compiler works. |
3626 | | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
3627 | | # <limits.h> exists even on freestanding compilers. |
3628 | | # On the NeXT, cc -E runs the code through the compiler's parser, |
3629 | | # not just through cpp. "Syntax error" is here to catch this case. |
3630 | | cat >conftest.$ac_ext <<_ACEOF |
3631 | | /* confdefs.h. */ |
3632 | | _ACEOF |
3633 | | cat confdefs.h >>conftest.$ac_ext |
3634 | | cat >>conftest.$ac_ext <<_ACEOF |
3635 | | /* end confdefs.h. */ |
3636 | | #ifdef __STDC__ |
3637 | | # include <limits.h> |
3638 | | #else |
3639 | | # include <assert.h> |
3640 | | #endif |
3641 | | Syntax error |
3642 | | _ACEOF |
3643 | | if { (ac_try="$ac_cpp conftest.$ac_ext" |
3644 | | case "(($ac_try" in |
3645 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
3646 | | *) ac_try_echo=$ac_try;; |
3647 | | esac |
3648 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
3649 | | $as_echo "$ac_try_echo") >&5 |
3650 | | (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 |
3651 | | ac_status=$? |
3652 | | grep -v '^ *+' conftest.er1 >conftest.err |
3653 | | rm -f conftest.er1 |
3654 | | cat conftest.err >&5 |
3655 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
3656 | | (exit $ac_status); } >/dev/null && { |
3657 | | test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || |
3658 | | test ! -s conftest.err |
3659 | | }; then |
3660 | | : |
3661 | | else |
3662 | | $as_echo "$as_me: failed program was:" >&5 |
3663 | | sed 's/^/| /' conftest.$ac_ext >&5 |
3664 | | |
3665 | | # Broken: fails on valid input. |
3666 | | continue |
3667 | | fi |
3668 | | |
3669 | | rm -f conftest.err conftest.$ac_ext |
3670 | | |
3671 | | # OK, works on sane cases. Now check whether nonexistent headers |
3672 | | # can be detected and how. |
3673 | | cat >conftest.$ac_ext <<_ACEOF |
3674 | | /* confdefs.h. */ |
3675 | | _ACEOF |
3676 | | cat confdefs.h >>conftest.$ac_ext |
3677 | | cat >>conftest.$ac_ext <<_ACEOF |
3678 | | /* end confdefs.h. */ |
3679 | | #include <ac_nonexistent.h> |
3680 | | _ACEOF |
3681 | | if { (ac_try="$ac_cpp conftest.$ac_ext" |
3682 | | case "(($ac_try" in |
3683 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
3684 | | *) ac_try_echo=$ac_try;; |
3685 | | esac |
3686 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
3687 | | $as_echo "$ac_try_echo") >&5 |
3688 | | (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 |
3689 | | ac_status=$? |
3690 | | grep -v '^ *+' conftest.er1 >conftest.err |
3691 | | rm -f conftest.er1 |
3692 | | cat conftest.err >&5 |
3693 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
3694 | | (exit $ac_status); } >/dev/null && { |
3695 | | test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || |
3696 | | test ! -s conftest.err |
3697 | | }; then |
3698 | | # Broken: success on invalid input. |
3699 | | continue |
3700 | | else |
3701 | | $as_echo "$as_me: failed program was:" >&5 |
3702 | | sed 's/^/| /' conftest.$ac_ext >&5 |
3703 | | |
3704 | | # Passes both tests. |
3705 | | ac_preproc_ok=: |
3706 | | break |
3707 | | fi |
3708 | | |
3709 | | rm -f conftest.err conftest.$ac_ext |
3710 | | |
3711 | | done |
3712 | | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
3713 | | rm -f conftest.err conftest.$ac_ext |
3714 | | if $ac_preproc_ok; then |
3715 | | break |
3716 | | fi |
3717 | | |
3718 | | done |
3719 | | ac_cv_prog_CPP=$CPP |
3720 | | |
3721 | | fi |
3722 | | CPP=$ac_cv_prog_CPP |
3723 | | else |
3724 | | ac_cv_prog_CPP=$CPP |
3725 | | fi |
3726 | | { $as_echo "$as_me:$LINENO: result: $CPP" >&5 |
3727 | | $as_echo "$CPP" >&6; } |
3728 | | ac_preproc_ok=false |
3729 | | for ac_c_preproc_warn_flag in '' yes |
3730 | | do |
3731 | | # Use a header file that comes with gcc, so configuring glibc |
3732 | | # with a fresh cross-compiler works. |
3733 | | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
3734 | | # <limits.h> exists even on freestanding compilers. |
3735 | | # On the NeXT, cc -E runs the code through the compiler's parser, |
3736 | | # not just through cpp. "Syntax error" is here to catch this case. |
3737 | | cat >conftest.$ac_ext <<_ACEOF |
3738 | | /* confdefs.h. */ |
3739 | | _ACEOF |
3740 | | cat confdefs.h >>conftest.$ac_ext |
3741 | | cat >>conftest.$ac_ext <<_ACEOF |
3742 | | /* end confdefs.h. */ |
3743 | | #ifdef __STDC__ |
3744 | | # include <limits.h> |
3745 | | #else |
3746 | | # include <assert.h> |
3747 | | #endif |
3748 | | Syntax error |
3749 | | _ACEOF |
3750 | | if { (ac_try="$ac_cpp conftest.$ac_ext" |
3751 | | case "(($ac_try" in |
3752 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
3753 | | *) ac_try_echo=$ac_try;; |
3754 | | esac |
3755 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
3756 | | $as_echo "$ac_try_echo") >&5 |
3757 | | (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 |
3758 | | ac_status=$? |
3759 | | grep -v '^ *+' conftest.er1 >conftest.err |
3760 | | rm -f conftest.er1 |
3761 | | cat conftest.err >&5 |
3762 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
3763 | | (exit $ac_status); } >/dev/null && { |
3764 | | test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || |
3765 | | test ! -s conftest.err |
3766 | | }; then |
3767 | | : |
3768 | | else |
3769 | | $as_echo "$as_me: failed program was:" >&5 |
3770 | | sed 's/^/| /' conftest.$ac_ext >&5 |
3771 | | |
3772 | | # Broken: fails on valid input. |
3773 | | continue |
3774 | | fi |
3775 | | |
3776 | | rm -f conftest.err conftest.$ac_ext |
3777 | | |
3778 | | # OK, works on sane cases. Now check whether nonexistent headers |
3779 | | # can be detected and how. |
3780 | | cat >conftest.$ac_ext <<_ACEOF |
3781 | | /* confdefs.h. */ |
3782 | | _ACEOF |
3783 | | cat confdefs.h >>conftest.$ac_ext |
3784 | | cat >>conftest.$ac_ext <<_ACEOF |
3785 | | /* end confdefs.h. */ |
3786 | | #include <ac_nonexistent.h> |
3787 | | _ACEOF |
3788 | | if { (ac_try="$ac_cpp conftest.$ac_ext" |
3789 | | case "(($ac_try" in |
3790 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
3791 | | *) ac_try_echo=$ac_try;; |
3792 | | esac |
3793 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
3794 | | $as_echo "$ac_try_echo") >&5 |
3795 | | (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 |
3796 | | ac_status=$? |
3797 | | grep -v '^ *+' conftest.er1 >conftest.err |
3798 | | rm -f conftest.er1 |
3799 | | cat conftest.err >&5 |
3800 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
3801 | | (exit $ac_status); } >/dev/null && { |
3802 | | test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || |
3803 | | test ! -s conftest.err |
3804 | | }; then |
3805 | | # Broken: success on invalid input. |
3806 | | continue |
3807 | | else |
3808 | | $as_echo "$as_me: failed program was:" >&5 |
3809 | | sed 's/^/| /' conftest.$ac_ext >&5 |
3810 | | |
3811 | | # Passes both tests. |
3812 | | ac_preproc_ok=: |
3813 | | break |
3814 | | fi |
3815 | | |
3816 | | rm -f conftest.err conftest.$ac_ext |
3817 | | |
3818 | | done |
3819 | | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
3820 | | rm -f conftest.err conftest.$ac_ext |
3821 | | if $ac_preproc_ok; then |
3822 | | : |
3823 | | else |
3824 | | { { $as_echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check |
3825 | | See \`config.log' for more details." >&5 |
3826 | | $as_echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check |
3827 | | See \`config.log' for more details." >&2;} |
3828 | | { (exit 1); exit 1; }; } |
3829 | | fi |
3830 | | |
3831 | | ac_ext=c |
3832 | | ac_cpp='$CPP $CPPFLAGS' |
3833 | | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
3834 | | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
3835 | | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
3836 | | |
3837 | | |
3838 | | # Find a good install program. We prefer a C program (faster), |
| 2664 | # Find a good install program. We prefer a C program (faster), |
4117 | | # 10*(2^10) chars as input seems more than enough |
4118 | | test $ac_count -gt 10 && break |
4119 | | done |
4120 | | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; |
4121 | | esac |
4122 | | |
4123 | | $ac_path_GREP_found && break 3 |
4124 | | done |
4125 | | done |
4126 | | done |
4127 | | IFS=$as_save_IFS |
4128 | | if test -z "$ac_cv_path_GREP"; then |
4129 | | { { $as_echo "$as_me:$LINENO: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5 |
4130 | | $as_echo "$as_me: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;} |
4131 | | { (exit 1); exit 1; }; } |
4132 | | fi |
4133 | | else |
4134 | | ac_cv_path_GREP=$GREP |
4135 | | fi |
4136 | | |
4137 | | fi |
4138 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5 |
4139 | | $as_echo "$ac_cv_path_GREP" >&6; } |
4140 | | GREP="$ac_cv_path_GREP" |
4141 | | |
4142 | | |
4143 | | { $as_echo "$as_me:$LINENO: checking for egrep" >&5 |
4144 | | $as_echo_n "checking for egrep... " >&6; } |
4145 | | if test "${ac_cv_path_EGREP+set}" = set; then |
4146 | | $as_echo_n "(cached) " >&6 |
4147 | | else |
4148 | | if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 |
4149 | | then ac_cv_path_EGREP="$GREP -E" |
4150 | | else |
4151 | | if test -z "$EGREP"; then |
4152 | | ac_path_EGREP_found=false |
4153 | | # Loop through the user's path and test for each of PROGNAME-LIST |
4154 | | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
4155 | | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin |
4156 | | do |
4157 | | IFS=$as_save_IFS |
4158 | | test -z "$as_dir" && as_dir=. |
4159 | | for ac_prog in egrep; do |
4160 | | for ac_exec_ext in '' $ac_executable_extensions; do |
4161 | | ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" |
4162 | | { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue |
4163 | | # Check for GNU ac_path_EGREP and select it if it is found. |
4164 | | # Check for GNU $ac_path_EGREP |
4165 | | case `"$ac_path_EGREP" --version 2>&1` in |
4166 | | *GNU*) |
4167 | | ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; |
4168 | | *) |
4169 | | ac_count=0 |
4170 | | $as_echo_n 0123456789 >"conftest.in" |
4171 | | while : |
4172 | | do |
4173 | | cat "conftest.in" "conftest.in" >"conftest.tmp" |
4174 | | mv "conftest.tmp" "conftest.in" |
4175 | | cp "conftest.in" "conftest.nl" |
4176 | | $as_echo 'EGREP' >> "conftest.nl" |
4177 | | "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break |
4178 | | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break |
4179 | | ac_count=`expr $ac_count + 1` |
4180 | | if test $ac_count -gt ${ac_path_EGREP_max-0}; then |
4181 | | # Best one so far, save it but keep looking for a better one |
4182 | | ac_cv_path_EGREP="$ac_path_EGREP" |
4183 | | ac_path_EGREP_max=$ac_count |
4184 | | fi |
4185 | | # 10*(2^10) chars as input seems more than enough |
4186 | | test $ac_count -gt 10 && break |
4187 | | done |
4188 | | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; |
4189 | | esac |
4190 | | |
4191 | | $ac_path_EGREP_found && break 3 |
4192 | | done |
4193 | | done |
4194 | | done |
4195 | | IFS=$as_save_IFS |
4196 | | if test -z "$ac_cv_path_EGREP"; then |
4197 | | { { $as_echo "$as_me:$LINENO: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5 |
4198 | | $as_echo "$as_me: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;} |
4199 | | { (exit 1); exit 1; }; } |
4200 | | fi |
4201 | | else |
4202 | | ac_cv_path_EGREP=$EGREP |
4203 | | fi |
4204 | | |
4205 | | fi |
4206 | | fi |
4207 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5 |
4208 | | $as_echo "$ac_cv_path_EGREP" >&6; } |
4209 | | EGREP="$ac_cv_path_EGREP" |
4210 | | |
4211 | | |
4212 | | { $as_echo "$as_me:$LINENO: checking for ANSI C header files" >&5 |
4213 | | $as_echo_n "checking for ANSI C header files... " >&6; } |
4214 | | if test "${ac_cv_header_stdc+set}" = set; then |
4215 | | $as_echo_n "(cached) " >&6 |
4216 | | else |
4217 | | cat >conftest.$ac_ext <<_ACEOF |
4218 | | /* confdefs.h. */ |
4219 | | _ACEOF |
4220 | | cat confdefs.h >>conftest.$ac_ext |
4221 | | cat >>conftest.$ac_ext <<_ACEOF |
4222 | | /* end confdefs.h. */ |
4223 | | #include <stdlib.h> |
4224 | | #include <stdarg.h> |
4225 | | #include <string.h> |
4226 | | #include <float.h> |
4227 | | |
4228 | | int |
4229 | | main () |
4230 | | { |
4231 | | |
4232 | | ; |
4233 | | return 0; |
4234 | | } |
4235 | | _ACEOF |
4236 | | rm -f conftest.$ac_objext |
4237 | | if { (ac_try="$ac_compile" |
4238 | | case "(($ac_try" in |
4239 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
4240 | | *) ac_try_echo=$ac_try;; |
4241 | | esac |
4242 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
4243 | | $as_echo "$ac_try_echo") >&5 |
4244 | | (eval "$ac_compile") 2>conftest.er1 |
4245 | | ac_status=$? |
4246 | | grep -v '^ *+' conftest.er1 >conftest.err |
4247 | | rm -f conftest.er1 |
4248 | | cat conftest.err >&5 |
4249 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
4250 | | (exit $ac_status); } && { |
4251 | | test -z "$ac_c_werror_flag" || |
4252 | | test ! -s conftest.err |
4253 | | } && test -s conftest.$ac_objext; then |
4254 | | ac_cv_header_stdc=yes |
4255 | | else |
4256 | | $as_echo "$as_me: failed program was:" >&5 |
4257 | | sed 's/^/| /' conftest.$ac_ext >&5 |
4258 | | |
4259 | | ac_cv_header_stdc=no |
4260 | | fi |
4261 | | |
4262 | | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4263 | | |
4264 | | if test $ac_cv_header_stdc = yes; then |
4265 | | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
4266 | | cat >conftest.$ac_ext <<_ACEOF |
4267 | | /* confdefs.h. */ |
4268 | | _ACEOF |
4269 | | cat confdefs.h >>conftest.$ac_ext |
4270 | | cat >>conftest.$ac_ext <<_ACEOF |
4271 | | /* end confdefs.h. */ |
4272 | | #include <string.h> |
4273 | | |
4274 | | _ACEOF |
4275 | | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
4276 | | $EGREP "memchr" >/dev/null 2>&1; then |
4277 | | : |
4278 | | else |
4279 | | ac_cv_header_stdc=no |
4280 | | fi |
4281 | | rm -f conftest* |
4282 | | |
4283 | | fi |
4284 | | |
4285 | | if test $ac_cv_header_stdc = yes; then |
4286 | | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
4287 | | cat >conftest.$ac_ext <<_ACEOF |
4288 | | /* confdefs.h. */ |
4289 | | _ACEOF |
4290 | | cat confdefs.h >>conftest.$ac_ext |
4291 | | cat >>conftest.$ac_ext <<_ACEOF |
4292 | | /* end confdefs.h. */ |
4293 | | #include <stdlib.h> |
4294 | | |
4295 | | _ACEOF |
4296 | | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
4297 | | $EGREP "free" >/dev/null 2>&1; then |
4298 | | : |
4299 | | else |
4300 | | ac_cv_header_stdc=no |
4301 | | fi |
4302 | | rm -f conftest* |
4303 | | |
4304 | | fi |
4305 | | |
4306 | | if test $ac_cv_header_stdc = yes; then |
4307 | | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
4308 | | if test "$cross_compiling" = yes; then |
4309 | | : |
4310 | | else |
4311 | | cat >conftest.$ac_ext <<_ACEOF |
4312 | | /* confdefs.h. */ |
4313 | | _ACEOF |
4314 | | cat confdefs.h >>conftest.$ac_ext |
4315 | | cat >>conftest.$ac_ext <<_ACEOF |
4316 | | /* end confdefs.h. */ |
4317 | | #include <ctype.h> |
4318 | | #include <stdlib.h> |
4319 | | #if ((' ' & 0x0FF) == 0x020) |
4320 | | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
4321 | | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
4322 | | #else |
4323 | | # define ISLOWER(c) \ |
4324 | | (('a' <= (c) && (c) <= 'i') \ |
4325 | | || ('j' <= (c) && (c) <= 'r') \ |
4326 | | || ('s' <= (c) && (c) <= 'z')) |
4327 | | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) |
4328 | | #endif |
4329 | | |
4330 | | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
4331 | | int |
4332 | | main () |
4333 | | { |
4334 | | int i; |
4335 | | for (i = 0; i < 256; i++) |
4336 | | if (XOR (islower (i), ISLOWER (i)) |
4337 | | || toupper (i) != TOUPPER (i)) |
4338 | | return 2; |
4339 | | return 0; |
4340 | | } |
4341 | | _ACEOF |
4342 | | rm -f conftest$ac_exeext |
4343 | | if { (ac_try="$ac_link" |
4344 | | case "(($ac_try" in |
4345 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
4346 | | *) ac_try_echo=$ac_try;; |
4347 | | esac |
4348 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
4349 | | $as_echo "$ac_try_echo") >&5 |
4350 | | (eval "$ac_link") 2>&5 |
4351 | | ac_status=$? |
4352 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
4353 | | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
4354 | | { (case "(($ac_try" in |
4355 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
4356 | | *) ac_try_echo=$ac_try;; |
4357 | | esac |
4358 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
4359 | | $as_echo "$ac_try_echo") >&5 |
4360 | | (eval "$ac_try") 2>&5 |
4361 | | ac_status=$? |
4362 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
4363 | | (exit $ac_status); }; }; then |
4364 | | : |
4365 | | else |
4366 | | $as_echo "$as_me: program exited with status $ac_status" >&5 |
4367 | | $as_echo "$as_me: failed program was:" >&5 |
4368 | | sed 's/^/| /' conftest.$ac_ext >&5 |
4369 | | |
4370 | | ( exit $ac_status ) |
4371 | | ac_cv_header_stdc=no |
4372 | | fi |
4373 | | rm -rf conftest.dSYM |
4374 | | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
4375 | | fi |
4376 | | |
4377 | | |
4378 | | fi |
4379 | | fi |
4380 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5 |
4381 | | $as_echo "$ac_cv_header_stdc" >&6; } |
4382 | | if test $ac_cv_header_stdc = yes; then |
4383 | | |
4384 | | cat >>confdefs.h <<\_ACEOF |
4385 | | #define STDC_HEADERS 1 |
4386 | | _ACEOF |
4387 | | |
4388 | | fi |
4389 | | |
4390 | | # On IRIX 5.3, sys/types and inttypes.h are conflicting. |
4391 | | |
4392 | | |
4393 | | |
4394 | | |
4395 | | |
4396 | | |
4397 | | |
4398 | | |
4399 | | |
4400 | | for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ |
4401 | | inttypes.h stdint.h unistd.h |
4402 | | do |
4403 | | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` |
4404 | | { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5 |
4405 | | $as_echo_n "checking for $ac_header... " >&6; } |
4406 | | if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then |
4407 | | $as_echo_n "(cached) " >&6 |
4408 | | else |
4409 | | cat >conftest.$ac_ext <<_ACEOF |
4410 | | /* confdefs.h. */ |
4411 | | _ACEOF |
4412 | | cat confdefs.h >>conftest.$ac_ext |
4413 | | cat >>conftest.$ac_ext <<_ACEOF |
4414 | | /* end confdefs.h. */ |
4415 | | $ac_includes_default |
4416 | | |
4417 | | #include <$ac_header> |
4418 | | _ACEOF |
4419 | | rm -f conftest.$ac_objext |
4420 | | if { (ac_try="$ac_compile" |
4421 | | case "(($ac_try" in |
4422 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
4423 | | *) ac_try_echo=$ac_try;; |
4424 | | esac |
4425 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
4426 | | $as_echo "$ac_try_echo") >&5 |
4427 | | (eval "$ac_compile") 2>conftest.er1 |
4428 | | ac_status=$? |
4429 | | grep -v '^ *+' conftest.er1 >conftest.err |
4430 | | rm -f conftest.er1 |
4431 | | cat conftest.err >&5 |
4432 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
4433 | | (exit $ac_status); } && { |
4434 | | test -z "$ac_c_werror_flag" || |
4435 | | test ! -s conftest.err |
4436 | | } && test -s conftest.$ac_objext; then |
4437 | | eval "$as_ac_Header=yes" |
4438 | | else |
4439 | | $as_echo "$as_me: failed program was:" >&5 |
4440 | | sed 's/^/| /' conftest.$ac_ext >&5 |
4441 | | |
4442 | | eval "$as_ac_Header=no" |
4443 | | fi |
4444 | | |
4445 | | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4446 | | fi |
4447 | | ac_res=`eval 'as_val=${'$as_ac_Header'} |
4448 | | $as_echo "$as_val"'` |
4449 | | { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 |
4450 | | $as_echo "$ac_res" >&6; } |
4451 | | if test `eval 'as_val=${'$as_ac_Header'} |
4452 | | $as_echo "$as_val"'` = yes; then |
4453 | | cat >>confdefs.h <<_ACEOF |
4454 | | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
4455 | | _ACEOF |
4456 | | |
4457 | | fi |
4458 | | |
4459 | | done |
4460 | | |
4461 | | |
4462 | | |
4463 | | # Any macros that use the compiler (e.g. AC_TRY_COMPILE) have to go here. |
4464 | | |
4465 | | |
4466 | | #------------------------------------------------------------------------ |
4467 | | # If we're using GCC, see if the compiler understands -pipe. If so, use it. |
4468 | | # It makes compiling go faster. (This is only a performance feature.) |
4469 | | #------------------------------------------------------------------------ |
4470 | | |
4471 | | if test -z "$no_pipe" -a -n "$GCC"; then |
4472 | | { $as_echo "$as_me:$LINENO: checking if the compiler understands -pipe" >&5 |
4473 | | $as_echo_n "checking if the compiler understands -pipe... " >&6; } |
4474 | | OLDCC="$CC" |
4475 | | CC="$CC -pipe" |
4476 | | cat >conftest.$ac_ext <<_ACEOF |
4477 | | /* confdefs.h. */ |
4478 | | _ACEOF |
4479 | | cat confdefs.h >>conftest.$ac_ext |
4480 | | cat >>conftest.$ac_ext <<_ACEOF |
4481 | | /* end confdefs.h. */ |
4482 | | |
4483 | | int |
4484 | | main () |
4485 | | { |
4486 | | |
4487 | | ; |
4488 | | return 0; |
4489 | | } |
4490 | | _ACEOF |
4491 | | rm -f conftest.$ac_objext |
4492 | | if { (ac_try="$ac_compile" |
4493 | | case "(($ac_try" in |
4494 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
4495 | | *) ac_try_echo=$ac_try;; |
4496 | | esac |
4497 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
4498 | | $as_echo "$ac_try_echo") >&5 |
4499 | | (eval "$ac_compile") 2>conftest.er1 |
4500 | | ac_status=$? |
4501 | | grep -v '^ *+' conftest.er1 >conftest.err |
4502 | | rm -f conftest.er1 |
4503 | | cat conftest.err >&5 |
4504 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
4505 | | (exit $ac_status); } && { |
4506 | | test -z "$ac_c_werror_flag" || |
4507 | | test ! -s conftest.err |
4508 | | } && test -s conftest.$ac_objext; then |
4509 | | { $as_echo "$as_me:$LINENO: result: yes" >&5 |
4510 | | $as_echo "yes" >&6; } |
4511 | | else |
4512 | | $as_echo "$as_me: failed program was:" >&5 |
4513 | | sed 's/^/| /' conftest.$ac_ext >&5 |
4514 | | |
4515 | | CC="$OLDCC" |
4516 | | { $as_echo "$as_me:$LINENO: result: no" >&5 |
4517 | | $as_echo "no" >&6; } |
4518 | | fi |
4519 | | |
4520 | | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4521 | | fi |
4522 | | |
4523 | | #-------------------------------------------------------------------- |
4524 | | # Common compiler flag setup |
4525 | | #-------------------------------------------------------------------- |
4526 | | |
4527 | | |
4528 | | { $as_echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5 |
4529 | | $as_echo_n "checking whether byte ordering is bigendian... " >&6; } |
4530 | | if test "${ac_cv_c_bigendian+set}" = set; then |
4531 | | $as_echo_n "(cached) " >&6 |
4532 | | else |
4533 | | ac_cv_c_bigendian=unknown |
4534 | | |
4535 | | if test $ac_cv_c_bigendian = unknown; then |
4536 | | # See if sys/param.h defines the BYTE_ORDER macro. |
4537 | | cat >conftest.$ac_ext <<_ACEOF |
4538 | | /* confdefs.h. */ |
4539 | | _ACEOF |
4540 | | cat confdefs.h >>conftest.$ac_ext |
4541 | | cat >>conftest.$ac_ext <<_ACEOF |
4542 | | /* end confdefs.h. */ |
4543 | | #include <sys/types.h> |
4544 | | #include <sys/param.h> |
4545 | | |
4546 | | int |
4547 | | main () |
4548 | | { |
4549 | | #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ |
4550 | | && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ |
4551 | | && LITTLE_ENDIAN) |
4552 | | bogus endian macros |
4553 | | #endif |
4554 | | |
4555 | | ; |
4556 | | return 0; |
4557 | | } |
4558 | | _ACEOF |
4559 | | rm -f conftest.$ac_objext |
4560 | | if { (ac_try="$ac_compile" |
4561 | | case "(($ac_try" in |
4562 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
4563 | | *) ac_try_echo=$ac_try;; |
4564 | | esac |
4565 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
4566 | | $as_echo "$ac_try_echo") >&5 |
4567 | | (eval "$ac_compile") 2>conftest.er1 |
4568 | | ac_status=$? |
4569 | | grep -v '^ *+' conftest.er1 >conftest.err |
4570 | | rm -f conftest.er1 |
4571 | | cat conftest.err >&5 |
4572 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
4573 | | (exit $ac_status); } && { |
4574 | | test -z "$ac_c_werror_flag" || |
4575 | | test ! -s conftest.err |
4576 | | } && test -s conftest.$ac_objext; then |
4577 | | # It does; now see whether it defined to BIG_ENDIAN or not. |
4578 | | cat >conftest.$ac_ext <<_ACEOF |
4579 | | /* confdefs.h. */ |
4580 | | _ACEOF |
4581 | | cat confdefs.h >>conftest.$ac_ext |
4582 | | cat >>conftest.$ac_ext <<_ACEOF |
4583 | | /* end confdefs.h. */ |
4584 | | #include <sys/types.h> |
4585 | | #include <sys/param.h> |
4586 | | |
4587 | | int |
4588 | | main () |
4589 | | { |
4590 | | #if BYTE_ORDER != BIG_ENDIAN |
4591 | | not big endian |
4592 | | #endif |
4593 | | |
4594 | | ; |
4595 | | return 0; |
4596 | | } |
4597 | | _ACEOF |
4598 | | rm -f conftest.$ac_objext |
4599 | | if { (ac_try="$ac_compile" |
4600 | | case "(($ac_try" in |
4601 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
4602 | | *) ac_try_echo=$ac_try;; |
4603 | | esac |
4604 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
4605 | | $as_echo "$ac_try_echo") >&5 |
4606 | | (eval "$ac_compile") 2>conftest.er1 |
4607 | | ac_status=$? |
4608 | | grep -v '^ *+' conftest.er1 >conftest.err |
4609 | | rm -f conftest.er1 |
4610 | | cat conftest.err >&5 |
4611 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
4612 | | (exit $ac_status); } && { |
4613 | | test -z "$ac_c_werror_flag" || |
4614 | | test ! -s conftest.err |
4615 | | } && test -s conftest.$ac_objext; then |
4616 | | ac_cv_c_bigendian=yes |
4617 | | else |
4618 | | $as_echo "$as_me: failed program was:" >&5 |
4619 | | sed 's/^/| /' conftest.$ac_ext >&5 |
4620 | | |
4621 | | ac_cv_c_bigendian=no |
4622 | | fi |
4623 | | |
4624 | | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4625 | | else |
4626 | | $as_echo "$as_me: failed program was:" >&5 |
4627 | | sed 's/^/| /' conftest.$ac_ext >&5 |
4628 | | |
4629 | | |
4630 | | fi |
4631 | | |
4632 | | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4633 | | fi |
4634 | | if test $ac_cv_c_bigendian = unknown; then |
4635 | | # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). |
4636 | | cat >conftest.$ac_ext <<_ACEOF |
4637 | | /* confdefs.h. */ |
4638 | | _ACEOF |
4639 | | cat confdefs.h >>conftest.$ac_ext |
4640 | | cat >>conftest.$ac_ext <<_ACEOF |
4641 | | /* end confdefs.h. */ |
4642 | | #include <limits.h> |
4643 | | |
4644 | | int |
4645 | | main () |
4646 | | { |
4647 | | #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) |
4648 | | bogus endian macros |
4649 | | #endif |
4650 | | |
4651 | | ; |
4652 | | return 0; |
4653 | | } |
4654 | | _ACEOF |
4655 | | rm -f conftest.$ac_objext |
4656 | | if { (ac_try="$ac_compile" |
4657 | | case "(($ac_try" in |
4658 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
4659 | | *) ac_try_echo=$ac_try;; |
4660 | | esac |
4661 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
4662 | | $as_echo "$ac_try_echo") >&5 |
4663 | | (eval "$ac_compile") 2>conftest.er1 |
4664 | | ac_status=$? |
4665 | | grep -v '^ *+' conftest.er1 >conftest.err |
4666 | | rm -f conftest.er1 |
4667 | | cat conftest.err >&5 |
4668 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
4669 | | (exit $ac_status); } && { |
4670 | | test -z "$ac_c_werror_flag" || |
4671 | | test ! -s conftest.err |
4672 | | } && test -s conftest.$ac_objext; then |
4673 | | # It does; now see whether it defined to _BIG_ENDIAN or not. |
4674 | | cat >conftest.$ac_ext <<_ACEOF |
4675 | | /* confdefs.h. */ |
4676 | | _ACEOF |
4677 | | cat confdefs.h >>conftest.$ac_ext |
4678 | | cat >>conftest.$ac_ext <<_ACEOF |
4679 | | /* end confdefs.h. */ |
4680 | | #include <limits.h> |
4681 | | |
4682 | | int |
4683 | | main () |
4684 | | { |
4685 | | #ifndef _BIG_ENDIAN |
4686 | | not big endian |
4687 | | #endif |
4688 | | |
4689 | | ; |
4690 | | return 0; |
4691 | | } |
4692 | | _ACEOF |
4693 | | rm -f conftest.$ac_objext |
4694 | | if { (ac_try="$ac_compile" |
4695 | | case "(($ac_try" in |
4696 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
4697 | | *) ac_try_echo=$ac_try;; |
4698 | | esac |
4699 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
4700 | | $as_echo "$ac_try_echo") >&5 |
4701 | | (eval "$ac_compile") 2>conftest.er1 |
4702 | | ac_status=$? |
4703 | | grep -v '^ *+' conftest.er1 >conftest.err |
4704 | | rm -f conftest.er1 |
4705 | | cat conftest.err >&5 |
4706 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
4707 | | (exit $ac_status); } && { |
4708 | | test -z "$ac_c_werror_flag" || |
4709 | | test ! -s conftest.err |
4710 | | } && test -s conftest.$ac_objext; then |
4711 | | ac_cv_c_bigendian=yes |
4712 | | else |
4713 | | $as_echo "$as_me: failed program was:" >&5 |
4714 | | sed 's/^/| /' conftest.$ac_ext >&5 |
4715 | | |
4716 | | ac_cv_c_bigendian=no |
4717 | | fi |
4718 | | |
4719 | | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4720 | | else |
4721 | | $as_echo "$as_me: failed program was:" >&5 |
4722 | | sed 's/^/| /' conftest.$ac_ext >&5 |
4723 | | |
4724 | | |
4725 | | fi |
4726 | | |
4727 | | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4728 | | fi |
4729 | | if test $ac_cv_c_bigendian = unknown; then |
4730 | | # Compile a test program. |
4731 | | if test "$cross_compiling" = yes; then |
4732 | | # Try to guess by grepping values from an object file. |
4733 | | cat >conftest.$ac_ext <<_ACEOF |
4734 | | /* confdefs.h. */ |
4735 | | _ACEOF |
4736 | | cat confdefs.h >>conftest.$ac_ext |
4737 | | cat >>conftest.$ac_ext <<_ACEOF |
4738 | | /* end confdefs.h. */ |
4739 | | short int ascii_mm[] = |
4740 | | { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; |
4741 | | short int ascii_ii[] = |
4742 | | { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; |
4743 | | int use_ascii (int i) { |
4744 | | return ascii_mm[i] + ascii_ii[i]; |
4745 | | } |
4746 | | short int ebcdic_ii[] = |
4747 | | { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; |
4748 | | short int ebcdic_mm[] = |
4749 | | { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; |
4750 | | int use_ebcdic (int i) { |
4751 | | return ebcdic_mm[i] + ebcdic_ii[i]; |
4752 | | } |
4753 | | extern int foo; |
4754 | | |
4755 | | int |
4756 | | main () |
4757 | | { |
4758 | | return use_ascii (foo) == use_ebcdic (foo); |
4759 | | ; |
4760 | | return 0; |
4761 | | } |
4762 | | _ACEOF |
4763 | | rm -f conftest.$ac_objext |
4764 | | if { (ac_try="$ac_compile" |
4765 | | case "(($ac_try" in |
4766 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
4767 | | *) ac_try_echo=$ac_try;; |
4768 | | esac |
4769 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
4770 | | $as_echo "$ac_try_echo") >&5 |
4771 | | (eval "$ac_compile") 2>conftest.er1 |
4772 | | ac_status=$? |
4773 | | grep -v '^ *+' conftest.er1 >conftest.err |
4774 | | rm -f conftest.er1 |
4775 | | cat conftest.err >&5 |
4776 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
4777 | | (exit $ac_status); } && { |
4778 | | test -z "$ac_c_werror_flag" || |
4779 | | test ! -s conftest.err |
4780 | | } && test -s conftest.$ac_objext; then |
4781 | | if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then |
4782 | | ac_cv_c_bigendian=yes |
4783 | | fi |
4784 | | if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then |
4785 | | if test "$ac_cv_c_bigendian" = unknown; then |
4786 | | ac_cv_c_bigendian=no |
4787 | | else |
4788 | | # finding both strings is unlikely to happen, but who knows? |
4789 | | ac_cv_c_bigendian=unknown |
4790 | | fi |
4791 | | fi |
4792 | | else |
4793 | | $as_echo "$as_me: failed program was:" >&5 |
4794 | | sed 's/^/| /' conftest.$ac_ext >&5 |
4795 | | |
4796 | | |
4797 | | fi |
4798 | | |
4799 | | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4800 | | else |
4801 | | cat >conftest.$ac_ext <<_ACEOF |
4802 | | /* confdefs.h. */ |
4803 | | _ACEOF |
4804 | | cat confdefs.h >>conftest.$ac_ext |
4805 | | cat >>conftest.$ac_ext <<_ACEOF |
4806 | | /* end confdefs.h. */ |
4807 | | $ac_includes_default |
4808 | | int |
4809 | | main () |
4810 | | { |
4811 | | |
4812 | | /* Are we little or big endian? From Harbison&Steele. */ |
4813 | | union |
4814 | | { |
4815 | | long int l; |
4816 | | char c[sizeof (long int)]; |
4817 | | } u; |
4818 | | u.l = 1; |
4819 | | return u.c[sizeof (long int) - 1] == 1; |
4820 | | |
4821 | | ; |
4822 | | return 0; |
4823 | | } |
4824 | | _ACEOF |
4825 | | rm -f conftest$ac_exeext |
4826 | | if { (ac_try="$ac_link" |
4827 | | case "(($ac_try" in |
4828 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
4829 | | *) ac_try_echo=$ac_try;; |
4830 | | esac |
4831 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
4832 | | $as_echo "$ac_try_echo") >&5 |
4833 | | (eval "$ac_link") 2>&5 |
4834 | | ac_status=$? |
4835 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
4836 | | (exit $ac_status); } && { ac_try='./conftest$ac_exeext' |
4837 | | { (case "(($ac_try" in |
4838 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
4839 | | *) ac_try_echo=$ac_try;; |
4840 | | esac |
4841 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
4842 | | $as_echo "$ac_try_echo") >&5 |
4843 | | (eval "$ac_try") 2>&5 |
4844 | | ac_status=$? |
4845 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
4846 | | (exit $ac_status); }; }; then |
4847 | | ac_cv_c_bigendian=no |
4848 | | else |
4849 | | $as_echo "$as_me: program exited with status $ac_status" >&5 |
4850 | | $as_echo "$as_me: failed program was:" >&5 |
4851 | | sed 's/^/| /' conftest.$ac_ext >&5 |
4852 | | |
4853 | | ( exit $ac_status ) |
4854 | | ac_cv_c_bigendian=yes |
4855 | | fi |
4856 | | rm -rf conftest.dSYM |
4857 | | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext |
4858 | | fi |
4859 | | |
4860 | | |
4861 | | fi |
4862 | | fi |
4863 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5 |
4864 | | $as_echo "$ac_cv_c_bigendian" >&6; } |
4865 | | case $ac_cv_c_bigendian in #( |
4866 | | yes) |
4867 | | cat >>confdefs.h <<\_ACEOF |
4868 | | #define WORDS_BIGENDIAN 1 |
4869 | | _ACEOF |
4870 | | ;; #( |
4871 | | no) |
4872 | | ;; #( |
4873 | | universal) |
4874 | | ;; #( |
4875 | | *) |
4876 | | { { $as_echo "$as_me:$LINENO: error: unknown endianness |
4877 | | presetting ac_cv_c_bigendian=no (or yes) will help" >&5 |
4878 | | $as_echo "$as_me: error: unknown endianness |
4879 | | presetting ac_cv_c_bigendian=no (or yes) will help" >&2;} |
4880 | | { (exit 1); exit 1; }; } ;; |
4881 | | esac |
4882 | | |
4883 | | if test "${TEA_PLATFORM}" = "unix" ; then |
4884 | | |
4885 | | #-------------------------------------------------------------------- |
4886 | | # On a few very rare systems, all of the libm.a stuff is |
4887 | | # already in libc.a. Set compiler flags accordingly. |
4888 | | # Also, Linux requires the "ieee" library for math to work |
4889 | | # right (and it must appear before "-lm"). |
4890 | | #-------------------------------------------------------------------- |
4891 | | |
4892 | | { $as_echo "$as_me:$LINENO: checking for sin" >&5 |
4893 | | $as_echo_n "checking for sin... " >&6; } |
4894 | | if test "${ac_cv_func_sin+set}" = set; then |
4895 | | $as_echo_n "(cached) " >&6 |
4896 | | else |
4897 | | cat >conftest.$ac_ext <<_ACEOF |
4898 | | /* confdefs.h. */ |
4899 | | _ACEOF |
4900 | | cat confdefs.h >>conftest.$ac_ext |
4901 | | cat >>conftest.$ac_ext <<_ACEOF |
4902 | | /* end confdefs.h. */ |
4903 | | /* Define sin to an innocuous variant, in case <limits.h> declares sin. |
4904 | | For example, HP-UX 11i <limits.h> declares gettimeofday. */ |
4905 | | #define sin innocuous_sin |
4906 | | |
4907 | | /* System header to define __stub macros and hopefully few prototypes, |
4908 | | which can conflict with char sin (); below. |
4909 | | Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
4910 | | <limits.h> exists even on freestanding compilers. */ |
4911 | | |
4912 | | #ifdef __STDC__ |
4913 | | # include <limits.h> |
4914 | | #else |
4915 | | # include <assert.h> |
4916 | | #endif |
4917 | | |
4918 | | #undef sin |
4919 | | |
4920 | | /* Override any GCC internal prototype to avoid an error. |
4921 | | Use char because int might match the return type of a GCC |
4922 | | builtin and then its argument prototype would still apply. */ |
4923 | | #ifdef __cplusplus |
4924 | | extern "C" |
4925 | | #endif |
4926 | | char sin (); |
4927 | | /* The GNU C library defines this for functions which it implements |
4928 | | to always fail with ENOSYS. Some functions are actually named |
4929 | | something starting with __ and the normal name is an alias. */ |
4930 | | #if defined __stub_sin || defined __stub___sin |
4931 | | choke me |
4932 | | #endif |
4933 | | |
4934 | | int |
4935 | | main () |
4936 | | { |
4937 | | return sin (); |
4938 | | ; |
4939 | | return 0; |
4940 | | } |
4941 | | _ACEOF |
4942 | | rm -f conftest.$ac_objext conftest$ac_exeext |
4943 | | if { (ac_try="$ac_link" |
4944 | | case "(($ac_try" in |
4945 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
4946 | | *) ac_try_echo=$ac_try;; |
4947 | | esac |
4948 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
4949 | | $as_echo "$ac_try_echo") >&5 |
4950 | | (eval "$ac_link") 2>conftest.er1 |
4951 | | ac_status=$? |
4952 | | grep -v '^ *+' conftest.er1 >conftest.err |
4953 | | rm -f conftest.er1 |
4954 | | cat conftest.err >&5 |
4955 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
4956 | | (exit $ac_status); } && { |
4957 | | test -z "$ac_c_werror_flag" || |
4958 | | test ! -s conftest.err |
4959 | | } && test -s conftest$ac_exeext && { |
4960 | | test "$cross_compiling" = yes || |
4961 | | $as_test_x conftest$ac_exeext |
4962 | | }; then |
4963 | | ac_cv_func_sin=yes |
4964 | | else |
4965 | | $as_echo "$as_me: failed program was:" >&5 |
4966 | | sed 's/^/| /' conftest.$ac_ext >&5 |
4967 | | |
4968 | | ac_cv_func_sin=no |
4969 | | fi |
4970 | | |
4971 | | rm -rf conftest.dSYM |
4972 | | rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ |
4973 | | conftest$ac_exeext conftest.$ac_ext |
4974 | | fi |
4975 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_func_sin" >&5 |
4976 | | $as_echo "$ac_cv_func_sin" >&6; } |
4977 | | if test $ac_cv_func_sin = yes; then |
4978 | | MATH_LIBS="" |
4979 | | else |
4980 | | MATH_LIBS="-lm" |
4981 | | fi |
4982 | | |
4983 | | { $as_echo "$as_me:$LINENO: checking for main in -lieee" >&5 |
4984 | | $as_echo_n "checking for main in -lieee... " >&6; } |
4985 | | if test "${ac_cv_lib_ieee_main+set}" = set; then |
4986 | | $as_echo_n "(cached) " >&6 |
4987 | | else |
4988 | | ac_check_lib_save_LIBS=$LIBS |
4989 | | LIBS="-lieee $LIBS" |
4990 | | cat >conftest.$ac_ext <<_ACEOF |
4991 | | /* confdefs.h. */ |
4992 | | _ACEOF |
4993 | | cat confdefs.h >>conftest.$ac_ext |
4994 | | cat >>conftest.$ac_ext <<_ACEOF |
4995 | | /* end confdefs.h. */ |
4996 | | |
4997 | | |
4998 | | int |
4999 | | main () |
5000 | | { |
5001 | | return main (); |
5002 | | ; |
5003 | | return 0; |
5004 | | } |
5005 | | _ACEOF |
5006 | | rm -f conftest.$ac_objext conftest$ac_exeext |
5007 | | if { (ac_try="$ac_link" |
5008 | | case "(($ac_try" in |
5009 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
5010 | | *) ac_try_echo=$ac_try;; |
5011 | | esac |
5012 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
5013 | | $as_echo "$ac_try_echo") >&5 |
5014 | | (eval "$ac_link") 2>conftest.er1 |
5015 | | ac_status=$? |
5016 | | grep -v '^ *+' conftest.er1 >conftest.err |
5017 | | rm -f conftest.er1 |
5018 | | cat conftest.err >&5 |
5019 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
5020 | | (exit $ac_status); } && { |
5021 | | test -z "$ac_c_werror_flag" || |
5022 | | test ! -s conftest.err |
5023 | | } && test -s conftest$ac_exeext && { |
5024 | | test "$cross_compiling" = yes || |
5025 | | $as_test_x conftest$ac_exeext |
5026 | | }; then |
5027 | | ac_cv_lib_ieee_main=yes |
5028 | | else |
5029 | | $as_echo "$as_me: failed program was:" >&5 |
5030 | | sed 's/^/| /' conftest.$ac_ext >&5 |
5031 | | |
5032 | | ac_cv_lib_ieee_main=no |
5033 | | fi |
5034 | | |
5035 | | rm -rf conftest.dSYM |
5036 | | rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ |
5037 | | conftest$ac_exeext conftest.$ac_ext |
5038 | | LIBS=$ac_check_lib_save_LIBS |
5039 | | fi |
5040 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ieee_main" >&5 |
5041 | | $as_echo "$ac_cv_lib_ieee_main" >&6; } |
5042 | | if test $ac_cv_lib_ieee_main = yes; then |
5043 | | MATH_LIBS="-lieee $MATH_LIBS" |
5044 | | fi |
5045 | | |
5046 | | |
5047 | | #-------------------------------------------------------------------- |
5048 | | # Interactive UNIX requires -linet instead of -lsocket, plus it |
5049 | | # needs net/errno.h to define the socket-related error codes. |
5050 | | #-------------------------------------------------------------------- |
5051 | | |
5052 | | { $as_echo "$as_me:$LINENO: checking for main in -linet" >&5 |
5053 | | $as_echo_n "checking for main in -linet... " >&6; } |
5054 | | if test "${ac_cv_lib_inet_main+set}" = set; then |
5055 | | $as_echo_n "(cached) " >&6 |
5056 | | else |
5057 | | ac_check_lib_save_LIBS=$LIBS |
5058 | | LIBS="-linet $LIBS" |
5059 | | cat >conftest.$ac_ext <<_ACEOF |
5060 | | /* confdefs.h. */ |
5061 | | _ACEOF |
5062 | | cat confdefs.h >>conftest.$ac_ext |
5063 | | cat >>conftest.$ac_ext <<_ACEOF |
5064 | | /* end confdefs.h. */ |
5065 | | |
5066 | | |
5067 | | int |
5068 | | main () |
5069 | | { |
5070 | | return main (); |
5071 | | ; |
5072 | | return 0; |
5073 | | } |
5074 | | _ACEOF |
5075 | | rm -f conftest.$ac_objext conftest$ac_exeext |
5076 | | if { (ac_try="$ac_link" |
5077 | | case "(($ac_try" in |
5078 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
5079 | | *) ac_try_echo=$ac_try;; |
5080 | | esac |
5081 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
5082 | | $as_echo "$ac_try_echo") >&5 |
5083 | | (eval "$ac_link") 2>conftest.er1 |
5084 | | ac_status=$? |
5085 | | grep -v '^ *+' conftest.er1 >conftest.err |
5086 | | rm -f conftest.er1 |
5087 | | cat conftest.err >&5 |
5088 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
5089 | | (exit $ac_status); } && { |
5090 | | test -z "$ac_c_werror_flag" || |
5091 | | test ! -s conftest.err |
5092 | | } && test -s conftest$ac_exeext && { |
5093 | | test "$cross_compiling" = yes || |
5094 | | $as_test_x conftest$ac_exeext |
5095 | | }; then |
5096 | | ac_cv_lib_inet_main=yes |
5097 | | else |
5098 | | $as_echo "$as_me: failed program was:" >&5 |
5099 | | sed 's/^/| /' conftest.$ac_ext >&5 |
5100 | | |
5101 | | ac_cv_lib_inet_main=no |
5102 | | fi |
5103 | | |
5104 | | rm -rf conftest.dSYM |
5105 | | rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ |
5106 | | conftest$ac_exeext conftest.$ac_ext |
5107 | | LIBS=$ac_check_lib_save_LIBS |
5108 | | fi |
5109 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_inet_main" >&5 |
5110 | | $as_echo "$ac_cv_lib_inet_main" >&6; } |
5111 | | if test $ac_cv_lib_inet_main = yes; then |
5112 | | LIBS="$LIBS -linet" |
5113 | | fi |
5114 | | |
5115 | | if test "${ac_cv_header_net_errno_h+set}" = set; then |
5116 | | { $as_echo "$as_me:$LINENO: checking for net/errno.h" >&5 |
5117 | | $as_echo_n "checking for net/errno.h... " >&6; } |
5118 | | if test "${ac_cv_header_net_errno_h+set}" = set; then |
5119 | | $as_echo_n "(cached) " >&6 |
5120 | | fi |
5121 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_header_net_errno_h" >&5 |
5122 | | $as_echo "$ac_cv_header_net_errno_h" >&6; } |
5123 | | else |
5124 | | # Is the header compilable? |
5125 | | { $as_echo "$as_me:$LINENO: checking net/errno.h usability" >&5 |
5126 | | $as_echo_n "checking net/errno.h usability... " >&6; } |
5127 | | cat >conftest.$ac_ext <<_ACEOF |
5128 | | /* confdefs.h. */ |
5129 | | _ACEOF |
5130 | | cat confdefs.h >>conftest.$ac_ext |
5131 | | cat >>conftest.$ac_ext <<_ACEOF |
5132 | | /* end confdefs.h. */ |
5133 | | $ac_includes_default |
5134 | | #include <net/errno.h> |
5135 | | _ACEOF |
5136 | | rm -f conftest.$ac_objext |
5137 | | if { (ac_try="$ac_compile" |
5138 | | case "(($ac_try" in |
5139 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
5140 | | *) ac_try_echo=$ac_try;; |
5141 | | esac |
5142 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
5143 | | $as_echo "$ac_try_echo") >&5 |
5144 | | (eval "$ac_compile") 2>conftest.er1 |
5145 | | ac_status=$? |
5146 | | grep -v '^ *+' conftest.er1 >conftest.err |
5147 | | rm -f conftest.er1 |
5148 | | cat conftest.err >&5 |
5149 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
5150 | | (exit $ac_status); } && { |
5151 | | test -z "$ac_c_werror_flag" || |
5152 | | test ! -s conftest.err |
5153 | | } && test -s conftest.$ac_objext; then |
5154 | | ac_header_compiler=yes |
5155 | | else |
5156 | | $as_echo "$as_me: failed program was:" >&5 |
5157 | | sed 's/^/| /' conftest.$ac_ext >&5 |
5158 | | |
5159 | | ac_header_compiler=no |
5160 | | fi |
5161 | | |
5162 | | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
5163 | | { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 |
5164 | | $as_echo "$ac_header_compiler" >&6; } |
5165 | | |
5166 | | # Is the header present? |
5167 | | { $as_echo "$as_me:$LINENO: checking net/errno.h presence" >&5 |
5168 | | $as_echo_n "checking net/errno.h presence... " >&6; } |
5169 | | cat >conftest.$ac_ext <<_ACEOF |
5170 | | /* confdefs.h. */ |
5171 | | _ACEOF |
5172 | | cat confdefs.h >>conftest.$ac_ext |
5173 | | cat >>conftest.$ac_ext <<_ACEOF |
5174 | | /* end confdefs.h. */ |
5175 | | #include <net/errno.h> |
5176 | | _ACEOF |
5177 | | if { (ac_try="$ac_cpp conftest.$ac_ext" |
5178 | | case "(($ac_try" in |
5179 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
5180 | | *) ac_try_echo=$ac_try;; |
5181 | | esac |
5182 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
5183 | | $as_echo "$ac_try_echo") >&5 |
5184 | | (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 |
5185 | | ac_status=$? |
5186 | | grep -v '^ *+' conftest.er1 >conftest.err |
5187 | | rm -f conftest.er1 |
5188 | | cat conftest.err >&5 |
5189 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
5190 | | (exit $ac_status); } >/dev/null && { |
5191 | | test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || |
5192 | | test ! -s conftest.err |
5193 | | }; then |
5194 | | ac_header_preproc=yes |
5195 | | else |
5196 | | $as_echo "$as_me: failed program was:" >&5 |
5197 | | sed 's/^/| /' conftest.$ac_ext >&5 |
5198 | | |
5199 | | ac_header_preproc=no |
5200 | | fi |
5201 | | |
5202 | | rm -f conftest.err conftest.$ac_ext |
5203 | | { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 |
5204 | | $as_echo "$ac_header_preproc" >&6; } |
5205 | | |
5206 | | # So? What about this header? |
5207 | | case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in |
5208 | | yes:no: ) |
5209 | | { $as_echo "$as_me:$LINENO: WARNING: net/errno.h: accepted by the compiler, rejected by the preprocessor!" >&5 |
5210 | | $as_echo "$as_me: WARNING: net/errno.h: accepted by the compiler, rejected by the preprocessor!" >&2;} |
5211 | | { $as_echo "$as_me:$LINENO: WARNING: net/errno.h: proceeding with the compiler's result" >&5 |
5212 | | $as_echo "$as_me: WARNING: net/errno.h: proceeding with the compiler's result" >&2;} |
5213 | | ac_header_preproc=yes |
5214 | | ;; |
5215 | | no:yes:* ) |
5216 | | { $as_echo "$as_me:$LINENO: WARNING: net/errno.h: present but cannot be compiled" >&5 |
5217 | | $as_echo "$as_me: WARNING: net/errno.h: present but cannot be compiled" >&2;} |
5218 | | { $as_echo "$as_me:$LINENO: WARNING: net/errno.h: check for missing prerequisite headers?" >&5 |
5219 | | $as_echo "$as_me: WARNING: net/errno.h: check for missing prerequisite headers?" >&2;} |
5220 | | { $as_echo "$as_me:$LINENO: WARNING: net/errno.h: see the Autoconf documentation" >&5 |
5221 | | $as_echo "$as_me: WARNING: net/errno.h: see the Autoconf documentation" >&2;} |
5222 | | { $as_echo "$as_me:$LINENO: WARNING: net/errno.h: section \"Present But Cannot Be Compiled\"" >&5 |
5223 | | $as_echo "$as_me: WARNING: net/errno.h: section \"Present But Cannot Be Compiled\"" >&2;} |
5224 | | { $as_echo "$as_me:$LINENO: WARNING: net/errno.h: proceeding with the preprocessor's result" >&5 |
5225 | | $as_echo "$as_me: WARNING: net/errno.h: proceeding with the preprocessor's result" >&2;} |
5226 | | { $as_echo "$as_me:$LINENO: WARNING: net/errno.h: in the future, the compiler will take precedence" >&5 |
5227 | | $as_echo "$as_me: WARNING: net/errno.h: in the future, the compiler will take precedence" >&2;} |
5228 | | |
5229 | | ;; |
5230 | | esac |
5231 | | { $as_echo "$as_me:$LINENO: checking for net/errno.h" >&5 |
5232 | | $as_echo_n "checking for net/errno.h... " >&6; } |
5233 | | if test "${ac_cv_header_net_errno_h+set}" = set; then |
5234 | | $as_echo_n "(cached) " >&6 |
5235 | | else |
5236 | | ac_cv_header_net_errno_h=$ac_header_preproc |
5237 | | fi |
5238 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_header_net_errno_h" >&5 |
5239 | | $as_echo "$ac_cv_header_net_errno_h" >&6; } |
5240 | | |
5241 | | fi |
5242 | | if test $ac_cv_header_net_errno_h = yes; then |
5243 | | |
5244 | | |
5245 | | cat >>confdefs.h <<\_ACEOF |
5246 | | #define HAVE_NET_ERRNO_H 1 |
5247 | | _ACEOF |
5248 | | |
5249 | | fi |
5250 | | |
5251 | | |
5252 | | |
5253 | | #-------------------------------------------------------------------- |
5254 | | # Check for the existence of the -lsocket and -lnsl libraries. |
5255 | | # The order here is important, so that they end up in the right |
5256 | | # order in the command line generated by make. Here are some |
5257 | | # special considerations: |
5258 | | # 1. Use "connect" and "accept" to check for -lsocket, and |
5259 | | # "gethostbyname" to check for -lnsl. |
5260 | | # 2. Use each function name only once: can't redo a check because |
5261 | | # autoconf caches the results of the last check and won't redo it. |
5262 | | # 3. Use -lnsl and -lsocket only if they supply procedures that |
5263 | | # aren't already present in the normal libraries. This is because |
5264 | | # IRIX 5.2 has libraries, but they aren't needed and they're |
5265 | | # bogus: they goof up name resolution if used. |
5266 | | # 4. On some SVR4 systems, can't use -lsocket without -lnsl too. |
5267 | | # To get around this problem, check for both libraries together |
5268 | | # if -lsocket doesn't work by itself. |
5269 | | #-------------------------------------------------------------------- |
5270 | | |
5271 | | tcl_checkBoth=0 |
5272 | | { $as_echo "$as_me:$LINENO: checking for connect" >&5 |
5273 | | $as_echo_n "checking for connect... " >&6; } |
5274 | | if test "${ac_cv_func_connect+set}" = set; then |
5275 | | $as_echo_n "(cached) " >&6 |
5276 | | else |
5277 | | cat >conftest.$ac_ext <<_ACEOF |
5278 | | /* confdefs.h. */ |
5279 | | _ACEOF |
5280 | | cat confdefs.h >>conftest.$ac_ext |
5281 | | cat >>conftest.$ac_ext <<_ACEOF |
5282 | | /* end confdefs.h. */ |
5283 | | /* Define connect to an innocuous variant, in case <limits.h> declares connect. |
5284 | | For example, HP-UX 11i <limits.h> declares gettimeofday. */ |
5285 | | #define connect innocuous_connect |
5286 | | |
5287 | | /* System header to define __stub macros and hopefully few prototypes, |
5288 | | which can conflict with char connect (); below. |
5289 | | Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
5290 | | <limits.h> exists even on freestanding compilers. */ |
5291 | | |
5292 | | #ifdef __STDC__ |
5293 | | # include <limits.h> |
5294 | | #else |
5295 | | # include <assert.h> |
5296 | | #endif |
5297 | | |
5298 | | #undef connect |
5299 | | |
5300 | | /* Override any GCC internal prototype to avoid an error. |
5301 | | Use char because int might match the return type of a GCC |
5302 | | builtin and then its argument prototype would still apply. */ |
5303 | | #ifdef __cplusplus |
5304 | | extern "C" |
5305 | | #endif |
5306 | | char connect (); |
5307 | | /* The GNU C library defines this for functions which it implements |
5308 | | to always fail with ENOSYS. Some functions are actually named |
5309 | | something starting with __ and the normal name is an alias. */ |
5310 | | #if defined __stub_connect || defined __stub___connect |
5311 | | choke me |
5312 | | #endif |
5313 | | |
5314 | | int |
5315 | | main () |
5316 | | { |
5317 | | return connect (); |
5318 | | ; |
5319 | | return 0; |
5320 | | } |
5321 | | _ACEOF |
5322 | | rm -f conftest.$ac_objext conftest$ac_exeext |
5323 | | if { (ac_try="$ac_link" |
5324 | | case "(($ac_try" in |
5325 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
5326 | | *) ac_try_echo=$ac_try;; |
5327 | | esac |
5328 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
5329 | | $as_echo "$ac_try_echo") >&5 |
5330 | | (eval "$ac_link") 2>conftest.er1 |
5331 | | ac_status=$? |
5332 | | grep -v '^ *+' conftest.er1 >conftest.err |
5333 | | rm -f conftest.er1 |
5334 | | cat conftest.err >&5 |
5335 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
5336 | | (exit $ac_status); } && { |
5337 | | test -z "$ac_c_werror_flag" || |
5338 | | test ! -s conftest.err |
5339 | | } && test -s conftest$ac_exeext && { |
5340 | | test "$cross_compiling" = yes || |
5341 | | $as_test_x conftest$ac_exeext |
5342 | | }; then |
5343 | | ac_cv_func_connect=yes |
5344 | | else |
5345 | | $as_echo "$as_me: failed program was:" >&5 |
5346 | | sed 's/^/| /' conftest.$ac_ext >&5 |
5347 | | |
5348 | | ac_cv_func_connect=no |
5349 | | fi |
5350 | | |
5351 | | rm -rf conftest.dSYM |
5352 | | rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ |
5353 | | conftest$ac_exeext conftest.$ac_ext |
5354 | | fi |
5355 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_func_connect" >&5 |
5356 | | $as_echo "$ac_cv_func_connect" >&6; } |
5357 | | if test $ac_cv_func_connect = yes; then |
5358 | | tcl_checkSocket=0 |
5359 | | else |
5360 | | tcl_checkSocket=1 |
5361 | | fi |
5362 | | |
5363 | | if test "$tcl_checkSocket" = 1; then |
5364 | | { $as_echo "$as_me:$LINENO: checking for setsockopt" >&5 |
5365 | | $as_echo_n "checking for setsockopt... " >&6; } |
5366 | | if test "${ac_cv_func_setsockopt+set}" = set; then |
5367 | | $as_echo_n "(cached) " >&6 |
5368 | | else |
5369 | | cat >conftest.$ac_ext <<_ACEOF |
5370 | | /* confdefs.h. */ |
5371 | | _ACEOF |
5372 | | cat confdefs.h >>conftest.$ac_ext |
5373 | | cat >>conftest.$ac_ext <<_ACEOF |
5374 | | /* end confdefs.h. */ |
5375 | | /* Define setsockopt to an innocuous variant, in case <limits.h> declares setsockopt. |
5376 | | For example, HP-UX 11i <limits.h> declares gettimeofday. */ |
5377 | | #define setsockopt innocuous_setsockopt |
5378 | | |
5379 | | /* System header to define __stub macros and hopefully few prototypes, |
5380 | | which can conflict with char setsockopt (); below. |
5381 | | Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
5382 | | <limits.h> exists even on freestanding compilers. */ |
5383 | | |
5384 | | #ifdef __STDC__ |
5385 | | # include <limits.h> |
5386 | | #else |
5387 | | # include <assert.h> |
5388 | | #endif |
5389 | | |
5390 | | #undef setsockopt |
5391 | | |
5392 | | /* Override any GCC internal prototype to avoid an error. |
5393 | | Use char because int might match the return type of a GCC |
5394 | | builtin and then its argument prototype would still apply. */ |
5395 | | #ifdef __cplusplus |
5396 | | extern "C" |
5397 | | #endif |
5398 | | char setsockopt (); |
5399 | | /* The GNU C library defines this for functions which it implements |
5400 | | to always fail with ENOSYS. Some functions are actually named |
5401 | | something starting with __ and the normal name is an alias. */ |
5402 | | #if defined __stub_setsockopt || defined __stub___setsockopt |
5403 | | choke me |
5404 | | #endif |
5405 | | |
5406 | | int |
5407 | | main () |
5408 | | { |
5409 | | return setsockopt (); |
5410 | | ; |
5411 | | return 0; |
5412 | | } |
5413 | | _ACEOF |
5414 | | rm -f conftest.$ac_objext conftest$ac_exeext |
5415 | | if { (ac_try="$ac_link" |
5416 | | case "(($ac_try" in |
5417 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
5418 | | *) ac_try_echo=$ac_try;; |
5419 | | esac |
5420 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
5421 | | $as_echo "$ac_try_echo") >&5 |
5422 | | (eval "$ac_link") 2>conftest.er1 |
5423 | | ac_status=$? |
5424 | | grep -v '^ *+' conftest.er1 >conftest.err |
5425 | | rm -f conftest.er1 |
5426 | | cat conftest.err >&5 |
5427 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
5428 | | (exit $ac_status); } && { |
5429 | | test -z "$ac_c_werror_flag" || |
5430 | | test ! -s conftest.err |
5431 | | } && test -s conftest$ac_exeext && { |
5432 | | test "$cross_compiling" = yes || |
5433 | | $as_test_x conftest$ac_exeext |
5434 | | }; then |
5435 | | ac_cv_func_setsockopt=yes |
5436 | | else |
5437 | | $as_echo "$as_me: failed program was:" >&5 |
5438 | | sed 's/^/| /' conftest.$ac_ext >&5 |
5439 | | |
5440 | | ac_cv_func_setsockopt=no |
5441 | | fi |
5442 | | |
5443 | | rm -rf conftest.dSYM |
5444 | | rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ |
5445 | | conftest$ac_exeext conftest.$ac_ext |
5446 | | fi |
5447 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_func_setsockopt" >&5 |
5448 | | $as_echo "$ac_cv_func_setsockopt" >&6; } |
5449 | | if test $ac_cv_func_setsockopt = yes; then |
5450 | | : |
5451 | | else |
5452 | | { $as_echo "$as_me:$LINENO: checking for setsockopt in -lsocket" >&5 |
5453 | | $as_echo_n "checking for setsockopt in -lsocket... " >&6; } |
5454 | | if test "${ac_cv_lib_socket_setsockopt+set}" = set; then |
5455 | | $as_echo_n "(cached) " >&6 |
5456 | | else |
5457 | | ac_check_lib_save_LIBS=$LIBS |
5458 | | LIBS="-lsocket $LIBS" |
5459 | | cat >conftest.$ac_ext <<_ACEOF |
5460 | | /* confdefs.h. */ |
5461 | | _ACEOF |
5462 | | cat confdefs.h >>conftest.$ac_ext |
5463 | | cat >>conftest.$ac_ext <<_ACEOF |
5464 | | /* end confdefs.h. */ |
5465 | | |
5466 | | /* Override any GCC internal prototype to avoid an error. |
5467 | | Use char because int might match the return type of a GCC |
5468 | | builtin and then its argument prototype would still apply. */ |
5469 | | #ifdef __cplusplus |
5470 | | extern "C" |
5471 | | #endif |
5472 | | char setsockopt (); |
5473 | | int |
5474 | | main () |
5475 | | { |
5476 | | return setsockopt (); |
5477 | | ; |
5478 | | return 0; |
5479 | | } |
5480 | | _ACEOF |
5481 | | rm -f conftest.$ac_objext conftest$ac_exeext |
5482 | | if { (ac_try="$ac_link" |
5483 | | case "(($ac_try" in |
5484 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
5485 | | *) ac_try_echo=$ac_try;; |
5486 | | esac |
5487 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
5488 | | $as_echo "$ac_try_echo") >&5 |
5489 | | (eval "$ac_link") 2>conftest.er1 |
5490 | | ac_status=$? |
5491 | | grep -v '^ *+' conftest.er1 >conftest.err |
5492 | | rm -f conftest.er1 |
5493 | | cat conftest.err >&5 |
5494 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
5495 | | (exit $ac_status); } && { |
5496 | | test -z "$ac_c_werror_flag" || |
5497 | | test ! -s conftest.err |
5498 | | } && test -s conftest$ac_exeext && { |
5499 | | test "$cross_compiling" = yes || |
5500 | | $as_test_x conftest$ac_exeext |
5501 | | }; then |
5502 | | ac_cv_lib_socket_setsockopt=yes |
5503 | | else |
5504 | | $as_echo "$as_me: failed program was:" >&5 |
5505 | | sed 's/^/| /' conftest.$ac_ext >&5 |
5506 | | |
5507 | | ac_cv_lib_socket_setsockopt=no |
5508 | | fi |
5509 | | |
5510 | | rm -rf conftest.dSYM |
5511 | | rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ |
5512 | | conftest$ac_exeext conftest.$ac_ext |
5513 | | LIBS=$ac_check_lib_save_LIBS |
5514 | | fi |
5515 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_socket_setsockopt" >&5 |
5516 | | $as_echo "$ac_cv_lib_socket_setsockopt" >&6; } |
5517 | | if test $ac_cv_lib_socket_setsockopt = yes; then |
5518 | | LIBS="$LIBS -lsocket" |
5519 | | else |
5520 | | tcl_checkBoth=1 |
5521 | | fi |
5522 | | |
5523 | | fi |
5524 | | |
5525 | | fi |
5526 | | if test "$tcl_checkBoth" = 1; then |
5527 | | tk_oldLibs=$LIBS |
5528 | | LIBS="$LIBS -lsocket -lnsl" |
5529 | | { $as_echo "$as_me:$LINENO: checking for accept" >&5 |
5530 | | $as_echo_n "checking for accept... " >&6; } |
5531 | | if test "${ac_cv_func_accept+set}" = set; then |
5532 | | $as_echo_n "(cached) " >&6 |
5533 | | else |
5534 | | cat >conftest.$ac_ext <<_ACEOF |
5535 | | /* confdefs.h. */ |
5536 | | _ACEOF |
5537 | | cat confdefs.h >>conftest.$ac_ext |
5538 | | cat >>conftest.$ac_ext <<_ACEOF |
5539 | | /* end confdefs.h. */ |
5540 | | /* Define accept to an innocuous variant, in case <limits.h> declares accept. |
5541 | | For example, HP-UX 11i <limits.h> declares gettimeofday. */ |
5542 | | #define accept innocuous_accept |
5543 | | |
5544 | | /* System header to define __stub macros and hopefully few prototypes, |
5545 | | which can conflict with char accept (); below. |
5546 | | Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
5547 | | <limits.h> exists even on freestanding compilers. */ |
5548 | | |
5549 | | #ifdef __STDC__ |
5550 | | # include <limits.h> |
5551 | | #else |
5552 | | # include <assert.h> |
5553 | | #endif |
5554 | | |
5555 | | #undef accept |
5556 | | |
5557 | | /* Override any GCC internal prototype to avoid an error. |
5558 | | Use char because int might match the return type of a GCC |
5559 | | builtin and then its argument prototype would still apply. */ |
5560 | | #ifdef __cplusplus |
5561 | | extern "C" |
5562 | | #endif |
5563 | | char accept (); |
5564 | | /* The GNU C library defines this for functions which it implements |
5565 | | to always fail with ENOSYS. Some functions are actually named |
5566 | | something starting with __ and the normal name is an alias. */ |
5567 | | #if defined __stub_accept || defined __stub___accept |
5568 | | choke me |
5569 | | #endif |
5570 | | |
5571 | | int |
5572 | | main () |
5573 | | { |
5574 | | return accept (); |
5575 | | ; |
5576 | | return 0; |
5577 | | } |
5578 | | _ACEOF |
5579 | | rm -f conftest.$ac_objext conftest$ac_exeext |
5580 | | if { (ac_try="$ac_link" |
5581 | | case "(($ac_try" in |
5582 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
5583 | | *) ac_try_echo=$ac_try;; |
5584 | | esac |
5585 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
5586 | | $as_echo "$ac_try_echo") >&5 |
5587 | | (eval "$ac_link") 2>conftest.er1 |
5588 | | ac_status=$? |
5589 | | grep -v '^ *+' conftest.er1 >conftest.err |
5590 | | rm -f conftest.er1 |
5591 | | cat conftest.err >&5 |
5592 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
5593 | | (exit $ac_status); } && { |
5594 | | test -z "$ac_c_werror_flag" || |
5595 | | test ! -s conftest.err |
5596 | | } && test -s conftest$ac_exeext && { |
5597 | | test "$cross_compiling" = yes || |
5598 | | $as_test_x conftest$ac_exeext |
5599 | | }; then |
5600 | | ac_cv_func_accept=yes |
5601 | | else |
5602 | | $as_echo "$as_me: failed program was:" >&5 |
5603 | | sed 's/^/| /' conftest.$ac_ext >&5 |
5604 | | |
5605 | | ac_cv_func_accept=no |
5606 | | fi |
5607 | | |
5608 | | rm -rf conftest.dSYM |
5609 | | rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ |
5610 | | conftest$ac_exeext conftest.$ac_ext |
5611 | | fi |
5612 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_func_accept" >&5 |
5613 | | $as_echo "$ac_cv_func_accept" >&6; } |
5614 | | if test $ac_cv_func_accept = yes; then |
5615 | | tcl_checkNsl=0 |
5616 | | else |
5617 | | LIBS=$tk_oldLibs |
5618 | | fi |
5619 | | |
5620 | | fi |
5621 | | { $as_echo "$as_me:$LINENO: checking for gethostbyname" >&5 |
5622 | | $as_echo_n "checking for gethostbyname... " >&6; } |
5623 | | if test "${ac_cv_func_gethostbyname+set}" = set; then |
5624 | | $as_echo_n "(cached) " >&6 |
5625 | | else |
5626 | | cat >conftest.$ac_ext <<_ACEOF |
5627 | | /* confdefs.h. */ |
5628 | | _ACEOF |
5629 | | cat confdefs.h >>conftest.$ac_ext |
5630 | | cat >>conftest.$ac_ext <<_ACEOF |
5631 | | /* end confdefs.h. */ |
5632 | | /* Define gethostbyname to an innocuous variant, in case <limits.h> declares gethostbyname. |
5633 | | For example, HP-UX 11i <limits.h> declares gettimeofday. */ |
5634 | | #define gethostbyname innocuous_gethostbyname |
5635 | | |
5636 | | /* System header to define __stub macros and hopefully few prototypes, |
5637 | | which can conflict with char gethostbyname (); below. |
5638 | | Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
5639 | | <limits.h> exists even on freestanding compilers. */ |
5640 | | |
5641 | | #ifdef __STDC__ |
5642 | | # include <limits.h> |
5643 | | #else |
5644 | | # include <assert.h> |
5645 | | #endif |
5646 | | |
5647 | | #undef gethostbyname |
5648 | | |
5649 | | /* Override any GCC internal prototype to avoid an error. |
5650 | | Use char because int might match the return type of a GCC |
5651 | | builtin and then its argument prototype would still apply. */ |
5652 | | #ifdef __cplusplus |
5653 | | extern "C" |
5654 | | #endif |
5655 | | char gethostbyname (); |
5656 | | /* The GNU C library defines this for functions which it implements |
5657 | | to always fail with ENOSYS. Some functions are actually named |
5658 | | something starting with __ and the normal name is an alias. */ |
5659 | | #if defined __stub_gethostbyname || defined __stub___gethostbyname |
5660 | | choke me |
5661 | | #endif |
5662 | | |
5663 | | int |
5664 | | main () |
5665 | | { |
5666 | | return gethostbyname (); |
5667 | | ; |
5668 | | return 0; |
5669 | | } |
5670 | | _ACEOF |
5671 | | rm -f conftest.$ac_objext conftest$ac_exeext |
5672 | | if { (ac_try="$ac_link" |
5673 | | case "(($ac_try" in |
5674 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
5675 | | *) ac_try_echo=$ac_try;; |
5676 | | esac |
5677 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
5678 | | $as_echo "$ac_try_echo") >&5 |
5679 | | (eval "$ac_link") 2>conftest.er1 |
5680 | | ac_status=$? |
5681 | | grep -v '^ *+' conftest.er1 >conftest.err |
5682 | | rm -f conftest.er1 |
5683 | | cat conftest.err >&5 |
5684 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
5685 | | (exit $ac_status); } && { |
5686 | | test -z "$ac_c_werror_flag" || |
5687 | | test ! -s conftest.err |
5688 | | } && test -s conftest$ac_exeext && { |
5689 | | test "$cross_compiling" = yes || |
5690 | | $as_test_x conftest$ac_exeext |
5691 | | }; then |
5692 | | ac_cv_func_gethostbyname=yes |
5693 | | else |
5694 | | $as_echo "$as_me: failed program was:" >&5 |
5695 | | sed 's/^/| /' conftest.$ac_ext >&5 |
5696 | | |
5697 | | ac_cv_func_gethostbyname=no |
5698 | | fi |
5699 | | |
5700 | | rm -rf conftest.dSYM |
5701 | | rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ |
5702 | | conftest$ac_exeext conftest.$ac_ext |
5703 | | fi |
5704 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_func_gethostbyname" >&5 |
5705 | | $as_echo "$ac_cv_func_gethostbyname" >&6; } |
5706 | | if test $ac_cv_func_gethostbyname = yes; then |
5707 | | : |
5708 | | else |
5709 | | { $as_echo "$as_me:$LINENO: checking for gethostbyname in -lnsl" >&5 |
5710 | | $as_echo_n "checking for gethostbyname in -lnsl... " >&6; } |
5711 | | if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then |
5712 | | $as_echo_n "(cached) " >&6 |
5713 | | else |
5714 | | ac_check_lib_save_LIBS=$LIBS |
5715 | | LIBS="-lnsl $LIBS" |
5716 | | cat >conftest.$ac_ext <<_ACEOF |
5717 | | /* confdefs.h. */ |
5718 | | _ACEOF |
5719 | | cat confdefs.h >>conftest.$ac_ext |
5720 | | cat >>conftest.$ac_ext <<_ACEOF |
5721 | | /* end confdefs.h. */ |
5722 | | |
5723 | | /* Override any GCC internal prototype to avoid an error. |
5724 | | Use char because int might match the return type of a GCC |
5725 | | builtin and then its argument prototype would still apply. */ |
5726 | | #ifdef __cplusplus |
5727 | | extern "C" |
5728 | | #endif |
5729 | | char gethostbyname (); |
5730 | | int |
5731 | | main () |
5732 | | { |
5733 | | return gethostbyname (); |
5734 | | ; |
5735 | | return 0; |
5736 | | } |
5737 | | _ACEOF |
5738 | | rm -f conftest.$ac_objext conftest$ac_exeext |
5739 | | if { (ac_try="$ac_link" |
5740 | | case "(($ac_try" in |
5741 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
5742 | | *) ac_try_echo=$ac_try;; |
5743 | | esac |
5744 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
5745 | | $as_echo "$ac_try_echo") >&5 |
5746 | | (eval "$ac_link") 2>conftest.er1 |
5747 | | ac_status=$? |
5748 | | grep -v '^ *+' conftest.er1 >conftest.err |
5749 | | rm -f conftest.er1 |
5750 | | cat conftest.err >&5 |
5751 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
5752 | | (exit $ac_status); } && { |
5753 | | test -z "$ac_c_werror_flag" || |
5754 | | test ! -s conftest.err |
5755 | | } && test -s conftest$ac_exeext && { |
5756 | | test "$cross_compiling" = yes || |
5757 | | $as_test_x conftest$ac_exeext |
5758 | | }; then |
5759 | | ac_cv_lib_nsl_gethostbyname=yes |
5760 | | else |
5761 | | $as_echo "$as_me: failed program was:" >&5 |
5762 | | sed 's/^/| /' conftest.$ac_ext >&5 |
5763 | | |
5764 | | ac_cv_lib_nsl_gethostbyname=no |
5765 | | fi |
5766 | | |
5767 | | rm -rf conftest.dSYM |
5768 | | rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ |
5769 | | conftest$ac_exeext conftest.$ac_ext |
5770 | | LIBS=$ac_check_lib_save_LIBS |
5771 | | fi |
5772 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_gethostbyname" >&5 |
5773 | | $as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; } |
5774 | | if test $ac_cv_lib_nsl_gethostbyname = yes; then |
5775 | | LIBS="$LIBS -lnsl" |
5776 | | fi |
5777 | | |
5778 | | fi |
5779 | | |
5780 | | |
5781 | | # Don't perform the eval of the libraries here because DL_LIBS |
5782 | | # won't be set until we call TEA_CONFIG_CFLAGS |
5783 | | |
5784 | | TCL_LIBS='${DL_LIBS} ${LIBS} ${MATH_LIBS}' |
5785 | | |
5786 | | |
5787 | | |
5788 | | |
5789 | | { $as_echo "$as_me:$LINENO: checking dirent.h" >&5 |
5790 | | $as_echo_n "checking dirent.h... " >&6; } |
5791 | | if test "${tcl_cv_dirent_h+set}" = set; then |
5792 | | $as_echo_n "(cached) " >&6 |
5793 | | else |
5794 | | cat >conftest.$ac_ext <<_ACEOF |
5795 | | /* confdefs.h. */ |
5796 | | _ACEOF |
5797 | | cat confdefs.h >>conftest.$ac_ext |
5798 | | cat >>conftest.$ac_ext <<_ACEOF |
5799 | | /* end confdefs.h. */ |
5800 | | #include <sys/types.h> |
5801 | | #include <dirent.h> |
5802 | | int |
5803 | | main () |
5804 | | { |
5805 | | |
5806 | | #ifndef _POSIX_SOURCE |
5807 | | # ifdef __Lynx__ |
5808 | | /* |
5809 | | * Generate compilation error to make the test fail: Lynx headers |
5810 | | * are only valid if really in the POSIX environment. |
5811 | | */ |
5812 | | |
5813 | | missing_procedure(); |
5814 | | # endif |
5815 | | #endif |
5816 | | DIR *d; |
5817 | | struct dirent *entryPtr; |
5818 | | char *p; |
5819 | | d = opendir("foobar"); |
5820 | | entryPtr = readdir(d); |
5821 | | p = entryPtr->d_name; |
5822 | | closedir(d); |
5823 | | |
5824 | | ; |
5825 | | return 0; |
5826 | | } |
5827 | | _ACEOF |
5828 | | rm -f conftest.$ac_objext conftest$ac_exeext |
5829 | | if { (ac_try="$ac_link" |
5830 | | case "(($ac_try" in |
5831 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
5832 | | *) ac_try_echo=$ac_try;; |
5833 | | esac |
5834 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
5835 | | $as_echo "$ac_try_echo") >&5 |
5836 | | (eval "$ac_link") 2>conftest.er1 |
5837 | | ac_status=$? |
5838 | | grep -v '^ *+' conftest.er1 >conftest.err |
5839 | | rm -f conftest.er1 |
5840 | | cat conftest.err >&5 |
5841 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
5842 | | (exit $ac_status); } && { |
5843 | | test -z "$ac_c_werror_flag" || |
5844 | | test ! -s conftest.err |
5845 | | } && test -s conftest$ac_exeext && { |
5846 | | test "$cross_compiling" = yes || |
5847 | | $as_test_x conftest$ac_exeext |
5848 | | }; then |
5849 | | tcl_cv_dirent_h=yes |
5850 | | else |
5851 | | $as_echo "$as_me: failed program was:" >&5 |
5852 | | sed 's/^/| /' conftest.$ac_ext >&5 |
5853 | | |
5854 | | tcl_cv_dirent_h=no |
5855 | | fi |
5856 | | |
5857 | | rm -rf conftest.dSYM |
5858 | | rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ |
5859 | | conftest$ac_exeext conftest.$ac_ext |
5860 | | fi |
5861 | | { $as_echo "$as_me:$LINENO: result: $tcl_cv_dirent_h" >&5 |
5862 | | $as_echo "$tcl_cv_dirent_h" >&6; } |
5863 | | |
5864 | | if test $tcl_cv_dirent_h = no; then |
5865 | | |
5866 | | cat >>confdefs.h <<\_ACEOF |
5867 | | #define NO_DIRENT_H 1 |
5868 | | _ACEOF |
5869 | | |
5870 | | fi |
5871 | | |
5872 | | if test "${ac_cv_header_errno_h+set}" = set; then |
5873 | | { $as_echo "$as_me:$LINENO: checking for errno.h" >&5 |
5874 | | $as_echo_n "checking for errno.h... " >&6; } |
5875 | | if test "${ac_cv_header_errno_h+set}" = set; then |
5876 | | $as_echo_n "(cached) " >&6 |
5877 | | fi |
5878 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_header_errno_h" >&5 |
5879 | | $as_echo "$ac_cv_header_errno_h" >&6; } |
5880 | | else |
5881 | | # Is the header compilable? |
5882 | | { $as_echo "$as_me:$LINENO: checking errno.h usability" >&5 |
5883 | | $as_echo_n "checking errno.h usability... " >&6; } |
5884 | | cat >conftest.$ac_ext <<_ACEOF |
5885 | | /* confdefs.h. */ |
5886 | | _ACEOF |
5887 | | cat confdefs.h >>conftest.$ac_ext |
5888 | | cat >>conftest.$ac_ext <<_ACEOF |
5889 | | /* end confdefs.h. */ |
5890 | | $ac_includes_default |
5891 | | #include <errno.h> |
5892 | | _ACEOF |
5893 | | rm -f conftest.$ac_objext |
5894 | | if { (ac_try="$ac_compile" |
5895 | | case "(($ac_try" in |
5896 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
5897 | | *) ac_try_echo=$ac_try;; |
5898 | | esac |
5899 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
5900 | | $as_echo "$ac_try_echo") >&5 |
5901 | | (eval "$ac_compile") 2>conftest.er1 |
5902 | | ac_status=$? |
5903 | | grep -v '^ *+' conftest.er1 >conftest.err |
5904 | | rm -f conftest.er1 |
5905 | | cat conftest.err >&5 |
5906 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
5907 | | (exit $ac_status); } && { |
5908 | | test -z "$ac_c_werror_flag" || |
5909 | | test ! -s conftest.err |
5910 | | } && test -s conftest.$ac_objext; then |
5911 | | ac_header_compiler=yes |
5912 | | else |
5913 | | $as_echo "$as_me: failed program was:" >&5 |
5914 | | sed 's/^/| /' conftest.$ac_ext >&5 |
5915 | | |
5916 | | ac_header_compiler=no |
5917 | | fi |
5918 | | |
5919 | | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
5920 | | { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 |
5921 | | $as_echo "$ac_header_compiler" >&6; } |
5922 | | |
5923 | | # Is the header present? |
5924 | | { $as_echo "$as_me:$LINENO: checking errno.h presence" >&5 |
5925 | | $as_echo_n "checking errno.h presence... " >&6; } |
5926 | | cat >conftest.$ac_ext <<_ACEOF |
5927 | | /* confdefs.h. */ |
5928 | | _ACEOF |
5929 | | cat confdefs.h >>conftest.$ac_ext |
5930 | | cat >>conftest.$ac_ext <<_ACEOF |
5931 | | /* end confdefs.h. */ |
5932 | | #include <errno.h> |
5933 | | _ACEOF |
5934 | | if { (ac_try="$ac_cpp conftest.$ac_ext" |
5935 | | case "(($ac_try" in |
5936 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
5937 | | *) ac_try_echo=$ac_try;; |
5938 | | esac |
5939 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
5940 | | $as_echo "$ac_try_echo") >&5 |
5941 | | (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 |
5942 | | ac_status=$? |
5943 | | grep -v '^ *+' conftest.er1 >conftest.err |
5944 | | rm -f conftest.er1 |
5945 | | cat conftest.err >&5 |
5946 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
5947 | | (exit $ac_status); } >/dev/null && { |
5948 | | test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || |
5949 | | test ! -s conftest.err |
5950 | | }; then |
5951 | | ac_header_preproc=yes |
5952 | | else |
5953 | | $as_echo "$as_me: failed program was:" >&5 |
5954 | | sed 's/^/| /' conftest.$ac_ext >&5 |
5955 | | |
5956 | | ac_header_preproc=no |
5957 | | fi |
5958 | | |
5959 | | rm -f conftest.err conftest.$ac_ext |
5960 | | { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 |
5961 | | $as_echo "$ac_header_preproc" >&6; } |
5962 | | |
5963 | | # So? What about this header? |
5964 | | case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in |
5965 | | yes:no: ) |
5966 | | { $as_echo "$as_me:$LINENO: WARNING: errno.h: accepted by the compiler, rejected by the preprocessor!" >&5 |
5967 | | $as_echo "$as_me: WARNING: errno.h: accepted by the compiler, rejected by the preprocessor!" >&2;} |
5968 | | { $as_echo "$as_me:$LINENO: WARNING: errno.h: proceeding with the compiler's result" >&5 |
5969 | | $as_echo "$as_me: WARNING: errno.h: proceeding with the compiler's result" >&2;} |
5970 | | ac_header_preproc=yes |
5971 | | ;; |
5972 | | no:yes:* ) |
5973 | | { $as_echo "$as_me:$LINENO: WARNING: errno.h: present but cannot be compiled" >&5 |
5974 | | $as_echo "$as_me: WARNING: errno.h: present but cannot be compiled" >&2;} |
5975 | | { $as_echo "$as_me:$LINENO: WARNING: errno.h: check for missing prerequisite headers?" >&5 |
5976 | | $as_echo "$as_me: WARNING: errno.h: check for missing prerequisite headers?" >&2;} |
5977 | | { $as_echo "$as_me:$LINENO: WARNING: errno.h: see the Autoconf documentation" >&5 |
5978 | | $as_echo "$as_me: WARNING: errno.h: see the Autoconf documentation" >&2;} |
5979 | | { $as_echo "$as_me:$LINENO: WARNING: errno.h: section \"Present But Cannot Be Compiled\"" >&5 |
5980 | | $as_echo "$as_me: WARNING: errno.h: section \"Present But Cannot Be Compiled\"" >&2;} |
5981 | | { $as_echo "$as_me:$LINENO: WARNING: errno.h: proceeding with the preprocessor's result" >&5 |
5982 | | $as_echo "$as_me: WARNING: errno.h: proceeding with the preprocessor's result" >&2;} |
5983 | | { $as_echo "$as_me:$LINENO: WARNING: errno.h: in the future, the compiler will take precedence" >&5 |
5984 | | $as_echo "$as_me: WARNING: errno.h: in the future, the compiler will take precedence" >&2;} |
5985 | | |
5986 | | ;; |
5987 | | esac |
5988 | | { $as_echo "$as_me:$LINENO: checking for errno.h" >&5 |
5989 | | $as_echo_n "checking for errno.h... " >&6; } |
5990 | | if test "${ac_cv_header_errno_h+set}" = set; then |
5991 | | $as_echo_n "(cached) " >&6 |
5992 | | else |
5993 | | ac_cv_header_errno_h=$ac_header_preproc |
5994 | | fi |
5995 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_header_errno_h" >&5 |
5996 | | $as_echo "$ac_cv_header_errno_h" >&6; } |
5997 | | |
5998 | | fi |
5999 | | if test $ac_cv_header_errno_h = yes; then |
6000 | | : |
6001 | | else |
6002 | | |
6003 | | cat >>confdefs.h <<\_ACEOF |
6004 | | #define NO_ERRNO_H 1 |
6005 | | _ACEOF |
6006 | | |
6007 | | fi |
6008 | | |
6009 | | |
6010 | | if test "${ac_cv_header_float_h+set}" = set; then |
6011 | | { $as_echo "$as_me:$LINENO: checking for float.h" >&5 |
6012 | | $as_echo_n "checking for float.h... " >&6; } |
6013 | | if test "${ac_cv_header_float_h+set}" = set; then |
6014 | | $as_echo_n "(cached) " >&6 |
6015 | | fi |
6016 | | { $as_echo "$as_me:$LINENO: result: $ac_cv_header_float_h" >&5 |
6017 | | $as_echo "$ac_cv_header_float_h" >&6; } |
6018 | | else |
6019 | | # Is the header compilable? |
6020 | | { $as_echo "$as_me:$LINENO: checking float.h usability" >&5 |
6021 | | $as_echo_n "checking float.h usability... " >&6; } |
6022 | | cat >conftest.$ac_ext <<_ACEOF |
6023 | | /* confdefs.h. */ |
6024 | | _ACEOF |
6025 | | cat confdefs.h >>conftest.$ac_ext |
6026 | | cat >>conftest.$ac_ext <<_ACEOF |
6027 | | /* end confdefs.h. */ |
6028 | | $ac_includes_default |
6029 | | #include <float.h> |
6030 | | _ACEOF |
6031 | | rm -f conftest.$ac_objext |
6032 | | if { (ac_try="$ac_compile" |
6033 | | case "(($ac_try" in |
6034 | | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
6035 | | *) ac_try_echo=$ac_try;; |
6036 | | esac |
6037 | | eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" |
6038 | | $as_echo "$ac_try_echo") >&5 |
6039 | | (eval "$ac_compile") 2>conftest.er1 |
6040 | | ac_status=$? |
6041 | | grep -v '^ *+' conftest.er1 >conftest.err |
6042 | | rm -f conftest.er1 |
6043 | | cat conftest.err >&5 |
6044 | | $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
6045 | | (exit $ac_status); } && { |
6046 | | test -z "$ac_c_werror_flag" || |
6047 | | test ! -s conftest.err |
6048 | | } && test -s conftest.$ac_objext; then |
6049 | | ac_header_compiler=yes |
6050 | | else |
6051 | | $as_echo "$as_me: failed program was:" >&5 |
6052 | | sed 's/^/| /' conftest.$ac_ext >&5 |
6053 | | |
6054 | | ac_header_compiler=no |
6055 | | fi |
6056 | | |
6057 | | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
6058 | | { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 |
6059 | | $as_echo "$ac_header_compiler" >&6; } |