From patchwork Tue Oct 30 19:25:16 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Iain Buclaw X-Patchwork-Id: 991047 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-488653-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=gdcproject.org Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="QagFeg4f"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 42l1dw3znRz9sBq for ; Wed, 31 Oct 2018 06:25:40 +1100 (AEDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender :mime-version:from:date:message-id:subject:to:cc:content-type; q=dns; s=default; b=ugcwK7aQEVV0j/gAPJYgdgus9LNEi+2gT40Rqu7DyyI PlcdWc/ENw+1XpDsf1PgxEgPf5dajh2DdltocwRzxB7u+r3kEJO79XA9X0iNjgUJ lQdkmP85ha4s5I0LH8uy+EUbBhscejN+JnNoqqICItOuelop3b203B036xvfLmBI = DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender :mime-version:from:date:message-id:subject:to:cc:content-type; s=default; bh=UZtxKI+KXNnoMfoIiWLjB/w1m3Q=; b=QagFeg4fqQEIk3AO4 pRUn0oNF5mzwWp31g+RF02c99J9nsto4dthBd0KLV2J5vVz//EqW4E6FnVKOXHra b9m5arsJNq4zIHPEzeFw+FU0TbLbb3ySqXgVK7DBzVS0ZX3V048nyHpvOu2HcrHE xf8H/YosfdYR4r/u1Eok5lOWW8= Received: (qmail 70114 invoked by alias); 30 Oct 2018 19:25:33 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 70102 invoked by uid 89); 30 Oct 2018 19:25:32 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-25.0 required=5.0 tests=AWL, BAYES_00, FREEMAIL_FROM, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, KAM_SHORT, RCVD_IN_DNSWL_NONE, SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: mail-qt1-f174.google.com Received: from mail-qt1-f174.google.com (HELO mail-qt1-f174.google.com) (209.85.160.174) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 30 Oct 2018 19:25:30 +0000 Received: by mail-qt1-f174.google.com with SMTP id k12so9049893qtf.7 for ; Tue, 30 Oct 2018 12:25:30 -0700 (PDT) MIME-Version: 1.0 From: Iain Buclaw Date: Tue, 30 Oct 2018 20:25:16 +0100 Message-ID: Subject: [PATCH, d] Disable D on systems where it is known not to work. To: gcc-patches Cc: iain@sandoe.co.uk X-IsSubscribed: yes Hi, This turns off D front-end where there's been reported bootstrap problems that need further investigation. Also added a configure.tgt for libphobos to allow enabling for targets where there's known good runtime support backed by existing continuous integration. For both, this can be overridden if either D or libphobos was explicitly requested by configure. The guards will be loosened as I go through each target configuration. diff --git a/configure b/configure index 77e7e1869ba..20741aef7e3 100755 --- a/configure +++ b/configure @@ -3345,6 +3345,40 @@ if test "${ENABLE_LIBSTDCXX}" = "default" ; then esac fi +# Disable D on systems where it is known to not work. +# For testing, you can override this with --enable-languages=d. +case ,${enable_languages}, in + *,d,*) + ;; + *) + case "${target}" in + *-*-darwin* | *-*-cygwin* | *-*-mingw*) + unsupported_languages="$unsupported_languages d" + ;; + esac + ;; +esac + +# Disable libphobos on unsupported systems. +# For testing, you can override this with --enable-libphobos. +if test -d ${srcdir}/libphobos; then + if test x$enable_libphobos = x; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libphobos support" >&5 +$as_echo_n "checking for libphobos support... " >&6; } + if (srcdir=${srcdir}/libphobos; \ + . ${srcdir}/configure.tgt; \ + test -n "$UNSUPPORTED") + then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + noconfigdirs="$noconfigdirs target-libphobos" + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + fi + fi +fi + # Disable Fortran for some systems. case "${target}" in mmix-*-*) diff --git a/configure.ac b/configure.ac index 1e5979dc043..b10212b3be5 100644 --- a/configure.ac +++ b/configure.ac @@ -674,6 +674,37 @@ if test "${ENABLE_LIBSTDCXX}" = "default" ; then esac fi +# Disable D on systems where it is known to not work. +# For testing, you can override this with --enable-languages=d. +case ,${enable_languages}, in + *,d,*) + ;; + *) + case "${target}" in + *-*-darwin* | *-*-cygwin* | *-*-mingw*) + unsupported_languages="$unsupported_languages d" + ;; + esac + ;; +esac + +# Disable libphobos on unsupported systems. +# For testing, you can override this with --enable-libphobos. +if test -d ${srcdir}/libphobos; then + if test x$enable_libphobos = x; then + AC_MSG_CHECKING([for libphobos support]) + if (srcdir=${srcdir}/libphobos; \ + . ${srcdir}/configure.tgt; \ + test -n "$UNSUPPORTED") + then + AC_MSG_RESULT([no]) + noconfigdirs="$noconfigdirs target-libphobos" + else + AC_MSG_RESULT([yes]) + fi + fi +fi + # Disable Fortran for some systems. case "${target}" in mmix-*-*) diff --git a/libphobos/configure.tgt b/libphobos/configure.tgt new file mode 100644 index 00000000000..8afd350c755 --- /dev/null +++ b/libphobos/configure.tgt @@ -0,0 +1,36 @@ +# -*- shell-script -*- +# Copyright (C) 2018 Free Software Foundation, Inc. +# +# GCC is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 3, or (at your option) +# any later version. +# +# GCC is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with GCC; see the file COPYING3. If not see +# . + +# This is the target specific configuration file. This is invoked by the +# autoconf generated configure script. Putting it in a separate shell file +# lets us skip running autoconf when modifying target specific information. + +# Disable the libphobos or libdruntime components on untested or known +# broken systems. More targets shall be added after testing. +case "${target}" in + arm*-*-linux*) + ;; + mips*-*-linux*) + ;; + x86_64-*-kfreebsd*-gnu | i?86-*-kfreebsd*-gnu) + ;; + x86_64-*-linux* | i?86-*-linux*) + ;; + *) + UNSUPPORTED=1 + ;; +esac