| OLD | NEW |
| 1 #!/bin/sh | 1 #!/bin/sh |
| 2 ## | 2 ## |
| 3 ## configure.sh | 3 ## configure.sh |
| 4 ## | 4 ## |
| 5 ## This script is sourced by the main configure script and contains | 5 ## This script is sourced by the main configure script and contains |
| 6 ## utility functions and other common bits that aren't strictly libvpx | 6 ## utility functions and other common bits that aren't strictly libvpx |
| 7 ## related. | 7 ## related. |
| 8 ## | 8 ## |
| 9 ## This build system is based in part on the FFmpeg configure script. | 9 ## This build system is based in part on the FFmpeg configure script. |
| 10 ## | 10 ## |
| (...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 194 eval test "x\$$1" = "xyes" | 194 eval test "x\$$1" = "xyes" |
| 195 } | 195 } |
| 196 | 196 |
| 197 disabled(){ | 197 disabled(){ |
| 198 eval test "x\$$1" = "xno" | 198 eval test "x\$$1" = "xno" |
| 199 } | 199 } |
| 200 | 200 |
| 201 soft_enable() { | 201 soft_enable() { |
| 202 for var in $*; do | 202 for var in $*; do |
| 203 if ! disabled $var; then | 203 if ! disabled $var; then |
| 204 enabled $var || log_echo " enabling $var" | 204 log_echo " enabling $var" |
| 205 enable_feature $var | 205 enable_feature $var |
| 206 fi | 206 fi |
| 207 done | 207 done |
| 208 } | 208 } |
| 209 | 209 |
| 210 soft_disable() { | 210 soft_disable() { |
| 211 for var in $*; do | 211 for var in $*; do |
| 212 if ! enabled $var; then | 212 if ! enabled $var; then |
| 213 disabled $var || log_echo " disabling $var" | 213 log_echo " disabling $var" |
| 214 disable_feature $var | 214 disable_feature $var |
| 215 fi | 215 fi |
| 216 done | 216 done |
| 217 } | 217 } |
| 218 | 218 |
| 219 # | 219 # |
| 220 # Text Processing Functions | 220 # Text Processing Functions |
| 221 # | 221 # |
| 222 toupper(){ | 222 toupper(){ |
| 223 echo "$@" | tr abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ | 223 echo "$@" | tr abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ |
| (...skipping 277 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 501 --extra-cflags=*) | 501 --extra-cflags=*) |
| 502 extra_cflags="${optval}" | 502 extra_cflags="${optval}" |
| 503 ;; | 503 ;; |
| 504 --enable-?*|--disable-?*) | 504 --enable-?*|--disable-?*) |
| 505 eval `echo "$opt" | sed 's/--/action=/;s/-/ option=/;s/-/_/g'` | 505 eval `echo "$opt" | sed 's/--/action=/;s/-/ option=/;s/-/_/g'` |
| 506 if echo "${ARCH_EXT_LIST}" | grep "^ *$option\$" >/dev/null; then | 506 if echo "${ARCH_EXT_LIST}" | grep "^ *$option\$" >/dev/null; then |
| 507 [ $action = "disable" ] && RTCD_OPTIONS="${RTCD_OPTIONS}--disable-${op
tion} " | 507 [ $action = "disable" ] && RTCD_OPTIONS="${RTCD_OPTIONS}--disable-${op
tion} " |
| 508 elif [ $action = "disable" ] && ! disabled $option ; then | 508 elif [ $action = "disable" ] && ! disabled $option ; then |
| 509 echo "${CMDLINE_SELECT}" | grep "^ *$option\$" >/dev/null || | 509 echo "${CMDLINE_SELECT}" | grep "^ *$option\$" >/dev/null || |
| 510 die_unknown $opt | 510 die_unknown $opt |
| 511 log_echo " disabling $option" | |
| 512 elif [ $action = "enable" ] && ! enabled $option ; then | 511 elif [ $action = "enable" ] && ! enabled $option ; then |
| 513 echo "${CMDLINE_SELECT}" | grep "^ *$option\$" >/dev/null || | 512 echo "${CMDLINE_SELECT}" | grep "^ *$option\$" >/dev/null || |
| 514 die_unknown $opt | 513 die_unknown $opt |
| 515 log_echo " enabling $option" | |
| 516 fi | 514 fi |
| 517 ${action}_feature $option | 515 ${action}_feature $option |
| 518 ;; | 516 ;; |
| 519 --require-?*) | 517 --require-?*) |
| 520 eval `echo "$opt" | sed 's/--/action=/;s/-/ option=/;s/-/_/g'` | 518 eval `echo "$opt" | sed 's/--/action=/;s/-/ option=/;s/-/_/g'` |
| 521 if echo "${ARCH_EXT_LIST}" none | grep "^ *$option\$" >/dev/null; then | 519 if echo "${ARCH_EXT_LIST}" none | grep "^ *$option\$" >/dev/null; then |
| 522 RTCD_OPTIONS="${RTCD_OPTIONS}${opt} " | 520 RTCD_OPTIONS="${RTCD_OPTIONS}${opt} " |
| 523 else | 521 else |
| 524 die_unknown $opt | 522 die_unknown $opt |
| 525 fi | 523 fi |
| (...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 601 CXX=${CXX:-${CROSS}g++} | 599 CXX=${CXX:-${CROSS}g++} |
| 602 AR=${AR:-${CROSS}ar} | 600 AR=${AR:-${CROSS}ar} |
| 603 LD=${LD:-${CROSS}${link_with_cc:-ld}} | 601 LD=${LD:-${CROSS}${link_with_cc:-ld}} |
| 604 AS=${AS:-${CROSS}as} | 602 AS=${AS:-${CROSS}as} |
| 605 STRIP=${STRIP:-${CROSS}strip} | 603 STRIP=${STRIP:-${CROSS}strip} |
| 606 NM=${NM:-${CROSS}nm} | 604 NM=${NM:-${CROSS}nm} |
| 607 AS_SFX=.s | 605 AS_SFX=.s |
| 608 EXE_SFX= | 606 EXE_SFX= |
| 609 } | 607 } |
| 610 | 608 |
| 611 # Reliably find the newest available Darwin SDKs. (Older versions of | |
| 612 # xcrun don't support --show-sdk-path.) | |
| 613 show_darwin_sdk_path() { | |
| 614 xcrun --sdk $1 --show-sdk-path 2>/dev/null || | |
| 615 xcodebuild -sdk $1 -version Path 2>/dev/null | |
| 616 } | |
| 617 | |
| 618 process_common_toolchain() { | 609 process_common_toolchain() { |
| 619 if [ -z "$toolchain" ]; then | 610 if [ -z "$toolchain" ]; then |
| 620 gcctarget="${CHOST:-$(gcc -dumpmachine 2> /dev/null)}" | 611 gcctarget="${CHOST:-$(gcc -dumpmachine 2> /dev/null)}" |
| 621 | 612 |
| 622 # detect tgt_isa | 613 # detect tgt_isa |
| 623 case "$gcctarget" in | 614 case "$gcctarget" in |
| 624 armv6*) | 615 armv6*) |
| 625 tgt_isa=armv6 | 616 tgt_isa=armv6 |
| 626 ;; | 617 ;; |
| 627 armv7*-hardfloat*) | 618 armv7*-hardfloat*) |
| (...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 668 tgt_os=darwin11 | 659 tgt_os=darwin11 |
| 669 ;; | 660 ;; |
| 670 *darwin12*) | 661 *darwin12*) |
| 671 tgt_isa=x86_64 | 662 tgt_isa=x86_64 |
| 672 tgt_os=darwin12 | 663 tgt_os=darwin12 |
| 673 ;; | 664 ;; |
| 674 *darwin13*) | 665 *darwin13*) |
| 675 tgt_isa=x86_64 | 666 tgt_isa=x86_64 |
| 676 tgt_os=darwin13 | 667 tgt_os=darwin13 |
| 677 ;; | 668 ;; |
| 678 *darwin14*) | |
| 679 tgt_isa=x86_64 | |
| 680 tgt_os=darwin14 | |
| 681 ;; | |
| 682 x86_64*mingw32*) | 669 x86_64*mingw32*) |
| 683 tgt_os=win64 | 670 tgt_os=win64 |
| 684 ;; | 671 ;; |
| 685 *mingw32*|*cygwin*) | 672 *mingw32*|*cygwin*) |
| 686 [ -z "$tgt_isa" ] && tgt_isa=x86 | 673 [ -z "$tgt_isa" ] && tgt_isa=x86 |
| 687 tgt_os=win32 | 674 tgt_os=win32 |
| 688 ;; | 675 ;; |
| 689 *linux*|*bsd*) | 676 *linux*|*bsd*) |
| 690 tgt_os=linux | 677 tgt_os=linux |
| 691 ;; | 678 ;; |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 731 ;; | 718 ;; |
| 732 esac | 719 esac |
| 733 | 720 |
| 734 # PIC is probably what we want when building shared libs | 721 # PIC is probably what we want when building shared libs |
| 735 enabled shared && soft_enable pic | 722 enabled shared && soft_enable pic |
| 736 | 723 |
| 737 # Minimum iOS version for all target platforms (darwin and iphonesimulator). | 724 # Minimum iOS version for all target platforms (darwin and iphonesimulator). |
| 738 IOS_VERSION_MIN="6.0" | 725 IOS_VERSION_MIN="6.0" |
| 739 | 726 |
| 740 # Handle darwin variants. Newer SDKs allow targeting older | 727 # Handle darwin variants. Newer SDKs allow targeting older |
| 741 # platforms, so use the newest one available. | 728 # platforms, so find the newest SDK available. |
| 742 case ${toolchain} in | 729 case ${toolchain} in |
| 743 *-darwin*) | 730 *-darwin*) |
| 744 osx_sdk_dir="$(show_darwin_sdk_path macosx)" | 731 if [ -z "${DEVELOPER_DIR}" ]; then |
| 745 if [ -d "${osx_sdk_dir}" ]; then | 732 DEVELOPER_DIR=`xcode-select -print-path 2> /dev/null` |
| 746 add_cflags "-isysroot ${osx_sdk_dir}" | 733 [ $? -ne 0 ] && OSX_SKIP_DIR_CHECK=1 |
| 747 add_ldflags "-isysroot ${osx_sdk_dir}" | 734 fi |
| 735 if [ -z "${OSX_SKIP_DIR_CHECK}" ]; then |
| 736 OSX_SDK_ROOTS="${DEVELOPER_DIR}/SDKs" |
| 737 OSX_SDK_VERSIONS="MacOSX10.4u.sdk MacOSX10.5.sdk MacOSX10.6.sdk" |
| 738 OSX_SDK_VERSIONS="${OSX_SDK_VERSIONS} MacOSX10.7.sdk" |
| 739 for v in ${OSX_SDK_VERSIONS}; do |
| 740 if [ -d "${OSX_SDK_ROOTS}/${v}" ]; then |
| 741 osx_sdk_dir="${OSX_SDK_ROOTS}/${v}" |
| 742 fi |
| 743 done |
| 748 fi | 744 fi |
| 749 ;; | 745 ;; |
| 750 esac | 746 esac |
| 751 | 747 |
| 748 if [ -d "${osx_sdk_dir}" ]; then |
| 749 add_cflags "-isysroot ${osx_sdk_dir}" |
| 750 add_ldflags "-isysroot ${osx_sdk_dir}" |
| 751 fi |
| 752 |
| 752 case ${toolchain} in | 753 case ${toolchain} in |
| 753 *-darwin8-*) | 754 *-darwin8-*) |
| 754 add_cflags "-mmacosx-version-min=10.4" | 755 add_cflags "-mmacosx-version-min=10.4" |
| 755 add_ldflags "-mmacosx-version-min=10.4" | 756 add_ldflags "-mmacosx-version-min=10.4" |
| 756 ;; | 757 ;; |
| 757 *-darwin9-*) | 758 *-darwin9-*) |
| 758 add_cflags "-mmacosx-version-min=10.5" | 759 add_cflags "-mmacosx-version-min=10.5" |
| 759 add_ldflags "-mmacosx-version-min=10.5" | 760 add_ldflags "-mmacosx-version-min=10.5" |
| 760 ;; | 761 ;; |
| 761 *-darwin10-*) | 762 *-darwin10-*) |
| 762 add_cflags "-mmacosx-version-min=10.6" | 763 add_cflags "-mmacosx-version-min=10.6" |
| 763 add_ldflags "-mmacosx-version-min=10.6" | 764 add_ldflags "-mmacosx-version-min=10.6" |
| 764 ;; | 765 ;; |
| 765 *-darwin11-*) | 766 *-darwin11-*) |
| 766 add_cflags "-mmacosx-version-min=10.7" | 767 add_cflags "-mmacosx-version-min=10.7" |
| 767 add_ldflags "-mmacosx-version-min=10.7" | 768 add_ldflags "-mmacosx-version-min=10.7" |
| 768 ;; | 769 ;; |
| 769 *-darwin12-*) | 770 *-darwin12-*) |
| 770 add_cflags "-mmacosx-version-min=10.8" | 771 add_cflags "-mmacosx-version-min=10.8" |
| 771 add_ldflags "-mmacosx-version-min=10.8" | 772 add_ldflags "-mmacosx-version-min=10.8" |
| 772 ;; | 773 ;; |
| 773 *-darwin13-*) | 774 *-darwin13-*) |
| 774 add_cflags "-mmacosx-version-min=10.9" | 775 add_cflags "-mmacosx-version-min=10.9" |
| 775 add_ldflags "-mmacosx-version-min=10.9" | 776 add_ldflags "-mmacosx-version-min=10.9" |
| 776 ;; | 777 ;; |
| 777 *-darwin14-*) | |
| 778 add_cflags "-mmacosx-version-min=10.10" | |
| 779 add_ldflags "-mmacosx-version-min=10.10" | |
| 780 ;; | |
| 781 *-iphonesimulator-*) | 778 *-iphonesimulator-*) |
| 782 add_cflags "-miphoneos-version-min=${IOS_VERSION_MIN}" | 779 add_cflags "-miphoneos-version-min=${IOS_VERSION_MIN}" |
| 783 add_ldflags "-miphoneos-version-min=${IOS_VERSION_MIN}" | 780 add_ldflags "-miphoneos-version-min=${IOS_VERSION_MIN}" |
| 784 iossim_sdk_dir="$(show_darwin_sdk_path iphonesimulator)" | 781 osx_sdk_dir="$(xcrun --sdk iphonesimulator --show-sdk-path)" |
| 785 if [ -d "${iossim_sdk_dir}" ]; then | 782 add_cflags "-isysroot ${osx_sdk_dir}" |
| 786 add_cflags "-isysroot ${iossim_sdk_dir}" | 783 add_ldflags "-isysroot ${osx_sdk_dir}" |
| 787 add_ldflags "-isysroot ${iossim_sdk_dir}" | |
| 788 fi | |
| 789 ;; | 784 ;; |
| 790 esac | 785 esac |
| 791 | 786 |
| 792 # Handle Solaris variants. Solaris 10 needs -lposix4 | 787 # Handle Solaris variants. Solaris 10 needs -lposix4 |
| 793 case ${toolchain} in | 788 case ${toolchain} in |
| 794 sparc-solaris-*) | 789 sparc-solaris-*) |
| 795 add_extralibs -lposix4 | 790 add_extralibs -lposix4 |
| 796 disable_feature fast_unaligned | 791 disable_feature fast_unaligned |
| 797 ;; | 792 ;; |
| 798 *-solaris-*) | 793 *-solaris-*) |
| (...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 950 soft_enable realtime_only | 945 soft_enable realtime_only |
| 951 if [ ${tgt_isa} = "armv7" ]; then | 946 if [ ${tgt_isa} = "armv7" ]; then |
| 952 soft_enable runtime_cpu_detect | 947 soft_enable runtime_cpu_detect |
| 953 fi | 948 fi |
| 954 if enabled runtime_cpu_detect; then | 949 if enabled runtime_cpu_detect; then |
| 955 add_cflags "-I${SDK_PATH}/sources/android/cpufeatures" | 950 add_cflags "-I${SDK_PATH}/sources/android/cpufeatures" |
| 956 fi | 951 fi |
| 957 ;; | 952 ;; |
| 958 | 953 |
| 959 darwin*) | 954 darwin*) |
| 960 XCRUN_FIND="xcrun --sdk iphoneos --find" | 955 XCRUN_FIND="xcrun --sdk iphoneos -find" |
| 961 CXX="$(${XCRUN_FIND} clang++)" | 956 CXX="$(${XCRUN_FIND} clang++)" |
| 962 CC="$(${XCRUN_FIND} clang)" | 957 CC="$(${XCRUN_FIND} clang)" |
| 963 AR="$(${XCRUN_FIND} ar)" | 958 AR="$(${XCRUN_FIND} ar)" |
| 964 AS="$(${XCRUN_FIND} as)" | 959 AS="$(${XCRUN_FIND} as)" |
| 965 STRIP="$(${XCRUN_FIND} strip)" | 960 STRIP="$(${XCRUN_FIND} strip)" |
| 966 NM="$(${XCRUN_FIND} nm)" | 961 NM="$(${XCRUN_FIND} nm)" |
| 967 RANLIB="$(${XCRUN_FIND} ranlib)" | 962 RANLIB="$(${XCRUN_FIND} ranlib)" |
| 968 AS_SFX=.s | 963 AS_SFX=.s |
| 969 | 964 |
| 970 # Special handling of ld for armv6 because libclang_rt.ios.a does | 965 # Special handling of ld for armv6 because libclang_rt.ios.a does |
| 971 # not contain armv6 support in Apple's clang package: | 966 # not contain armv6 support in Apple's clang package: |
| 972 # Apple LLVM version 5.1 (clang-503.0.40) (based on LLVM 3.4svn). | 967 # Apple LLVM version 5.1 (clang-503.0.40) (based on LLVM 3.4svn). |
| 973 # TODO(tomfinegan): Remove this. Our minimum iOS version (6.0) | 968 # TODO(tomfinegan): Remove this. Our minimum iOS version (6.0) |
| 974 # renders support for armv6 unnecessary because the 3GS and up | 969 # renders support for armv6 unnecessary because the 3GS and up |
| 975 # support neon. | 970 # support neon. |
| 976 if [ "${tgt_isa}" = "armv6" ]; then | 971 if [ "${tgt_isa}" = "armv6" ]; then |
| 977 LD="$(${XCRUN_FIND} ld)" | 972 LD="$(${XCRUN_FIND} ld)" |
| 978 else | 973 else |
| 979 LD="${CXX:-$(${XCRUN_FIND} ld)}" | 974 LD="${CXX:-$(${XCRUN_FIND} ld)}" |
| 980 fi | 975 fi |
| 981 | 976 |
| 982 # ASFLAGS is written here instead of using check_add_asflags | 977 # ASFLAGS is written here instead of using check_add_asflags |
| 983 # because we need to overwrite all of ASFLAGS and purge the | 978 # because we need to overwrite all of ASFLAGS and purge the |
| 984 # options that were put in above | 979 # options that were put in above |
| 985 ASFLAGS="-arch ${tgt_isa} -g" | 980 ASFLAGS="-arch ${tgt_isa} -g" |
| 986 | 981 |
| 987 add_cflags -arch ${tgt_isa} | 982 alt_libc="$(xcrun --sdk iphoneos --show-sdk-path)" |
| 983 add_cflags -arch ${tgt_isa} -isysroot ${alt_libc} |
| 988 add_ldflags -arch ${tgt_isa} | 984 add_ldflags -arch ${tgt_isa} |
| 989 | 985 |
| 990 alt_libc="$(show_darwin_sdk_path iphoneos)" | |
| 991 if [ -d "${alt_libc}" ]; then | |
| 992 add_cflags -isysroot ${alt_libc} | |
| 993 fi | |
| 994 | |
| 995 if [ "${LD}" = "${CXX}" ]; then | 986 if [ "${LD}" = "${CXX}" ]; then |
| 996 add_ldflags -miphoneos-version-min="${IOS_VERSION_MIN}" | 987 add_ldflags -miphoneos-version-min="${IOS_VERSION_MIN}" |
| 997 else | 988 else |
| 998 add_ldflags -ios_version_min "${IOS_VERSION_MIN}" | 989 add_ldflags -ios_version_min "${IOS_VERSION_MIN}" |
| 999 fi | 990 fi |
| 1000 | 991 |
| 1001 for d in lib usr/lib usr/lib/system; do | 992 for d in lib usr/lib usr/lib/system; do |
| 1002 try_dir="${alt_libc}/${d}" | 993 try_dir="${alt_libc}/${d}" |
| 1003 [ -d "${try_dir}" ] && add_ldflags -L"${try_dir}" | 994 [ -d "${try_dir}" ] && add_ldflags -L"${try_dir}" |
| 1004 done | 995 done |
| (...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1152 check_gcc_machine_option sse3 | 1143 check_gcc_machine_option sse3 |
| 1153 check_gcc_machine_option ssse3 | 1144 check_gcc_machine_option ssse3 |
| 1154 check_gcc_machine_option sse4 sse4_1 | 1145 check_gcc_machine_option sse4 sse4_1 |
| 1155 check_gcc_machine_option avx | 1146 check_gcc_machine_option avx |
| 1156 check_gcc_machine_option avx2 | 1147 check_gcc_machine_option avx2 |
| 1157 | 1148 |
| 1158 case "${AS}" in | 1149 case "${AS}" in |
| 1159 auto|"") | 1150 auto|"") |
| 1160 which nasm >/dev/null 2>&1 && AS=nasm | 1151 which nasm >/dev/null 2>&1 && AS=nasm |
| 1161 which yasm >/dev/null 2>&1 && AS=yasm | 1152 which yasm >/dev/null 2>&1 && AS=yasm |
| 1162 if [ "${AS}" = nasm ] ; then | |
| 1163 # Apple ships version 0.98 of nasm through at least Xcode 6. Revisit | |
| 1164 # this check if they start shipping a compatible version. | |
| 1165 apple=`nasm -v | grep "Apple"` | |
| 1166 [ -n "${apple}" ] \ | |
| 1167 && echo "Unsupported version of nasm: ${apple}" \ | |
| 1168 && AS="" | |
| 1169 fi | |
| 1170 [ "${AS}" = auto ] || [ -z "${AS}" ] \ | 1153 [ "${AS}" = auto ] || [ -z "${AS}" ] \ |
| 1171 && die "Neither yasm nor nasm have been found" | 1154 && die "Neither yasm nor nasm have been found" |
| 1172 ;; | 1155 ;; |
| 1173 esac | 1156 esac |
| 1174 log_echo " using $AS" | 1157 log_echo " using $AS" |
| 1175 [ "${AS##*/}" = nasm ] && add_asflags -Ox | 1158 [ "${AS##*/}" = nasm ] && add_asflags -Ox |
| 1176 AS_SFX=.asm | 1159 AS_SFX=.asm |
| 1177 case ${tgt_os} in | 1160 case ${tgt_os} in |
| 1178 win32) | 1161 win32) |
| 1179 add_asflags -f win32 | 1162 add_asflags -f win32 |
| (...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1253 | 1236 |
| 1254 if enabled optimizations; then | 1237 if enabled optimizations; then |
| 1255 if enabled rvct; then | 1238 if enabled rvct; then |
| 1256 enabled small && check_add_cflags -Ospace || check_add_cflags -Otime | 1239 enabled small && check_add_cflags -Ospace || check_add_cflags -Otime |
| 1257 else | 1240 else |
| 1258 enabled small && check_add_cflags -O2 || check_add_cflags -O3 | 1241 enabled small && check_add_cflags -O2 || check_add_cflags -O3 |
| 1259 fi | 1242 fi |
| 1260 fi | 1243 fi |
| 1261 | 1244 |
| 1262 tgt_os_no_version=$(echo "${tgt_os}" | tr -d "[0-9]") | 1245 tgt_os_no_version=$(echo "${tgt_os}" | tr -d "[0-9]") |
| 1263 if [ "${tgt_os_no_version}" = "openbsd" ] || [ "`uname`" = "OpenBSD" ]; then | |
| 1264 openbsd_like=yes | |
| 1265 fi | |
| 1266 # Default use_x86inc to yes when we are 64 bit, non-pic, or on any | 1246 # Default use_x86inc to yes when we are 64 bit, non-pic, or on any |
| 1267 # non-Darwin target. | 1247 # non-Darwin target. |
| 1268 if [ "${tgt_isa}" = "x86_64" ] || [ "${pic}" != "yes" ] || \ | 1248 if [ "${tgt_isa}" = "x86_64" ] || [ "${pic}" != "yes" ] || \ |
| 1269 [ "${openbsd_like}" != "yes" ]; then | 1249 [ "${tgt_os_no_version}" != "darwin" ]; then |
| 1270 soft_enable use_x86inc | 1250 soft_enable use_x86inc |
| 1271 fi | 1251 fi |
| 1272 | 1252 |
| 1273 # Position Independent Code (PIC) support, for building relocatable | 1253 # Position Independent Code (PIC) support, for building relocatable |
| 1274 # shared objects | 1254 # shared objects |
| 1275 enabled gcc && enabled pic && check_add_cflags -fPIC | 1255 enabled gcc && enabled pic && check_add_cflags -fPIC |
| 1276 | 1256 |
| 1277 # Work around longjmp interception on glibc >= 2.11, to improve binary | 1257 # Work around longjmp interception on glibc >= 2.11, to improve binary |
| 1278 # compatibility. See http://code.google.com/p/webm/issues/detail?id=166 | 1258 # compatibility. See http://code.google.com/p/webm/issues/detail?id=166 |
| 1279 enabled linux && check_add_cflags -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=0 | 1259 enabled linux && check_add_cflags -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=0 |
| (...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1423 # Prepare the PWD for building. | 1403 # Prepare the PWD for building. |
| 1424 for f in ${OOT_INSTALLS}; do | 1404 for f in ${OOT_INSTALLS}; do |
| 1425 install -D "${source_path}/$f" "$f" | 1405 install -D "${source_path}/$f" "$f" |
| 1426 done | 1406 done |
| 1427 fi | 1407 fi |
| 1428 cp "${source_path}/build/make/Makefile" . | 1408 cp "${source_path}/build/make/Makefile" . |
| 1429 | 1409 |
| 1430 clean_temp_files | 1410 clean_temp_files |
| 1431 true | 1411 true |
| 1432 } | 1412 } |
| OLD | NEW |