configure: Get the correct ident for clang-cl.exe
authorCarl Eugen Hoyos <ceffmpeg@gmail.com>
Wed, 25 Mar 2020 23:00:10 +0000 (00:00 +0100)
committerCarl Eugen Hoyos <ceffmpeg@gmail.com>
Thu, 26 Mar 2020 22:48:33 +0000 (23:48 +0100)
Instead of "No input file specified"

configure

index 90aaab9..aae9818 100755 (executable)
--- a/configure
+++ b/configure
@@ -4663,7 +4663,11 @@ probe_cc(){
         _ld_path='-libpath:'
     elif $_cc -nologo- 2>&1 | grep -q Microsoft || { $_cc -v 2>&1 | grep -q clang && $_cc -? > /dev/null 2>&1; }; then
         _type=msvc
-        _ident=$($_cc 2>&1 | head -n1 | tr -d '\r')
+        if $_cc -nologo- 2>&1 | grep -q Microsoft; then
+            _ident=$($_cc 2>&1 | head -n1 | tr -d '\r')
+        else
+            _ident=$($_cc --version 2>/dev/null | head -n1 | tr -d '\r')
+        fi
         _DEPCMD='$(DEP$(1)) $(DEP$(1)FLAGS) $($(1)DEP_FLAGS) $< 2>&1 | awk '\''/including/ { sub(/^.*file: */, ""); gsub(/\\/, "/"); if (!match($$0, / /)) print "$@:", $$0 }'\'' > $(@:.o=.d)'
         _DEPFLAGS='$(CPPFLAGS) $(CFLAGS) -showIncludes -Zs'
         _cflags_speed="-O2"