]> git.sesse.net Git - ffmpeg/blobdiff - configure
Merge commit '62be1caf161c1241a9e148f347850cfe092588dc'
[ffmpeg] / configure
index f1edf815cf1f21c47cb55613dfbaeab2bde530b5..ffe5278f9c92dd4115f2358307b802dd0fc52e62 100755 (executable)
--- a/configure
+++ b/configure
@@ -1922,6 +1922,7 @@ HEADERS_LIST="
     dxgidebug_h
     dxva_h
     ES2_gl_h
+    gsm_h
     io_h
     machine_ioctl_bt848_h
     machine_ioctl_meteor_h
@@ -3723,6 +3724,17 @@ enable_weak $HWACCEL_AUTODETECT_LIBRARY_LIST
 
 disabled logging && logfile=/dev/null
 
+# we need to build at least one lib type
+if ! enabled_any static shared; then
+    cat <<EOF
+At least one library type must be built.
+Specify --enable-static to build the static libraries or --enable-shared to
+build the shared libraries as well. To only build the shared libraries specify
+--disable-static in addition to --enable-shared.
+EOF
+    exit 1
+fi
+
 die_license_disabled() {
     enabled $1 || { enabled $v && die "$v is $1 and --enable-$1 is not specified."; }
 }
@@ -3821,6 +3833,9 @@ case "$toolchain" in
         nm_default="dumpbin -symbols"
         ar_default="lib"
         case "$arch" in
+        aarch64|arm64)
+            as_default="armasm64"
+            ;;
         arm*)
             as_default="armasm"
             ;;
@@ -5262,12 +5277,11 @@ test "$?" != 0 && check_${pfx}cc -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 <<
 void *v = localtime_r;
 EOF
 
+    eval test -n "\${${pfx}libc_type}" && enable ${pfx}libc_${libc_type}
 }
 
 probe_libc
-test -n "$libc_type" && enable libc_$libc_type
 probe_libc host_
-test -n "$host_libc_type" && enable host_libc_$host_libc_type
 
 # hacks for compiler/libc/os combinations
 
@@ -5304,17 +5318,6 @@ set_default libdir
 set_default $PATHS_LIST
 set_default nm
 
-# we need to build at least one lib type
-if ! enabled_any static shared; then
-    cat <<EOF
-At least one library type must be built.
-Specify --enable-static to build the static libraries or --enable-shared to
-build the shared libraries as well. To only build the shared libraries specify
---disable-static in addition to --enable-shared.
-EOF
-    exit 1
-fi
-
 disabled optimizations || enabled ossfuzz || check_cflags -fomit-frame-pointer
 
 enable_weak_pic() {
@@ -5326,9 +5329,9 @@ enable_weak_pic() {
         ;;
     *)
         add_cflags -fPIC
+        add_asflags -fPIC
         ;;
     esac
-    add_asflags  -fPIC
 }
 
 enabled pic && enable_weak_pic
@@ -5481,6 +5484,7 @@ EOF
 .object_arch armv4
 EOF
 
+    # MS armasm fails to assemble our PIC constructs
     [ $target_os != win32 ] && enabled_all armv6t2 shared !pic && enable_weak_pic
 
 elif enabled mips; then
@@ -5917,7 +5921,9 @@ enabled libfreetype       && require_pkg_config libfreetype freetype2 "ft2build.
 enabled libfribidi        && require_pkg_config libfribidi fribidi fribidi.h fribidi_version_info
 enabled libgme            && { check_pkg_config libgme libgme gme/gme.h gme_new_emu ||
                                require libgme gme/gme.h gme_new_emu -lgme -lstdc++; }
-enabled libgsm            && require libgsm gsm.h gsm_create -lgsm
+enabled libgsm            && { for gsm_hdr in "gsm.h" "gsm/gsm.h"; do
+                                   check_lib libgsm "${gsm_hdr}" gsm_create -lgsm && break;
+                               done || die "ERROR: libgsm not found"; }
 enabled libilbc           && require libilbc ilbc.h WebRtcIlbcfix_InitDecode -lilbc $pthreads_extralibs
 enabled libkvazaar        && require_pkg_config libkvazaar "kvazaar >= 0.8.1" kvazaar.h kvz_api_get
 # While it may appear that require is being used as a pkg-config