D compiler detection enhancements

Detect LLVM D compiler ldmd2 or ldc2.
Show D version. Note that dmd does not have an
explicit command line option to show version.
This commit is contained in:
William S Fulton 2022-04-02 18:57:11 +01:00
commit e8c1bda0b5
2 changed files with 2 additions and 3 deletions

View file

@ -1626,8 +1626,7 @@ d_run:
# -----------------------------------------------------------------
d_version:
# Needs improvement!
echo D version guess - $(D_VERSION)
($(DCOMPILER) --version 2> /dev/null || $(DCOMPILER)) | head -n 3
# -----------------------------------------------------------------
# Clean the D examples

View file

@ -2568,7 +2568,7 @@ _ACEOF
fi
if test -z "$D2COMPILERBIN" ; then
AC_CHECK_PROGS(D2COMPILER, dmd gdmd)
AC_CHECK_PROGS(D2COMPILER, dmd gdmd ldmd2 ldc2)
if test -n "$D2COMPILER" ; then
AC_MSG_CHECKING(whether the D2 compiler works)