From 39865a7f420ab4ca4dec6ed27339618a5d5dc366 Mon Sep 17 00:00:00 2001 From: Nick Clifton Date: Wed, 11 Oct 2017 16:48:16 +0100 Subject: Disable the inclusion of logical input files in the assembler listing output unless high level source listing has been enabled. PR 21977 * listing.c (listing_newline): Use the name of the current physical input file, rather than the current logical input file, unless including high level source in the listing. * input-scrub.c (as_where_physical): New function. Returns the name of the current physical input file. * as.h: Add prototype for as_where_physical. --- gas/listing.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'gas/listing.c') diff --git a/gas/listing.c b/gas/listing.c index 18c6e3b..31eae98 100644 --- a/gas/listing.c +++ b/gas/listing.c @@ -324,7 +324,13 @@ listing_newline (char *ps) } #endif - file = as_where (&line); + /* PR 21977 - use the physical file name not the logical one unless high + level source files are being included in the listing. */ + if (listing & LISTING_HLL) + file = as_where (&line); + else + file = as_where_physical (&line); + if (ps == NULL) { if (line == last_line -- cgit v1.1