This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[patch] Remove old kludge in gcc.c
- From: Eric Botcazou <ebotcazou at adacore dot com>
- To: gcc-patches at gcc dot gnu dot org
- Date: Mon, 30 Oct 2017 11:30:08 +0100
- Subject: [patch] Remove old kludge in gcc.c
- Authentication-results: sourceware.org; auth=none
Hi,
these lines in gcc.c date back to 2001:
/* By default there is no special suffix for target executables. */
/* FIXME: when autoconf is fixed, remove the host check - dj */
#if defined(TARGET_EXECUTABLE_SUFFIX) && defined(HOST_EXECUTABLE_SUFFIX)
#define HAVE_TARGET_EXECUTABLE_SUFFIX
#endif
HOST_EXECUTABLE_SUFFIX and TARGET_EXECUTABLE_SUFFIX are defined only for VMS
and DOS/Windows. The effect is that ".exe" is forced on executables for these
targets only if they are built as native and not if they are built as cross.
OK for the mainline?
2017-10-30 Eric Botcazou <ebotcazou@adacore.com>
* gcc.c (HAVE_TARGET_EXECUTABLE_SUFFIX): Remove old kludge.
--
Eric Botcazou
Index: gcc.c
===================================================================
--- gcc.c (revision 254193)
+++ gcc.c (working copy)
@@ -170,9 +170,10 @@ env_manager::restore ()
/* By default there is no special suffix for target executables. */
-/* FIXME: when autoconf is fixed, remove the host check - dj */
-#if defined(TARGET_EXECUTABLE_SUFFIX) && defined(HOST_EXECUTABLE_SUFFIX)
+#ifdef TARGET_EXECUTABLE_SUFFIX
#define HAVE_TARGET_EXECUTABLE_SUFFIX
+#else
+#define TARGET_EXECUTABLE_SUFFIX ""
#endif
/* By default there is no special suffix for host executables. */
Index: gcc.c
===================================================================
--- gcc.c (revision 254193)
+++ gcc.c (working copy)
@@ -170,9 +170,10 @@ env_manager::restore ()
/* By default there is no special suffix for target executables. */
-/* FIXME: when autoconf is fixed, remove the host check - dj */
-#if defined(TARGET_EXECUTABLE_SUFFIX) && defined(HOST_EXECUTABLE_SUFFIX)
+#ifdef TARGET_EXECUTABLE_SUFFIX
#define HAVE_TARGET_EXECUTABLE_SUFFIX
+#else
+#define TARGET_EXECUTABLE_SUFFIX ""
#endif
/* By default there is no special suffix for host executables. */