(ASM_OUTPUT_SOURCE_FILENAME): Quote special characters in file names.

From-SVN: r5493
This commit is contained in:
Paul Eggert 1993-09-28 00:23:58 +00:00
parent a1c3672f12
commit f40176b103
7 changed files with 27 additions and 7 deletions

View File

@ -727,7 +727,10 @@ enum reg_class { NO_REGS, GENERAL_REGS, ALL_REGS, LIM_REG_CLASSES };
/* Output the name of the file we are compiling. */
#define ASM_OUTPUT_SOURCE_FILENAME(STREAM, NAME) \
fprintf(STREAM, "\t.file\t\"%s\"\n", NAME);
do { fprintf (STREAM, "\t.file\t"); \
output_quoted_string (STREAM, NAME); \
fprintf (STREAM, "\n"); \
} while (0)
/* Output at beginning of assembler file. */
#define ASM_FILE_START(FILE) fprintf (FILE, "");

View File

@ -181,7 +181,10 @@ do { long l; \
/* The beginnings of sdb support... */
#define ASM_OUTPUT_SOURCE_FILENAME(FILE, FILENAME) \
fprintf (FILE, "\tfile\t\"%s\"\n", FILENAME)
do { fprintf (FILE, "\tfile\t"); \
output_quoted_string (FILE, FILENAME); \
fprintf (FILE, "\n"); \
} while (0)
#define ASM_OUTPUT_SOURCE_LINE(FILE, LINENO) \
fprintf (FILE, "\tln\t%d\n", \

View File

@ -460,7 +460,10 @@ do { long l[2]; \
}}
#define ASM_OUTPUT_SOURCE_FILENAME(FILE, FILENAME) \
fprintf (FILE, "\t; file\t\"%s\"\n", FILENAME)
do { fprintf (FILE, "\t; file\t"); \
output_quoted_string (FILE, FILENAME); \
fprintf (FILE, "\n"); \
} while (0)
#define ASM_OUTPUT_SOURCE_LINE(FILE, LINENO) \
fprintf (FILE, "\t; ln\t%d\n", \

View File

@ -386,7 +386,10 @@ do { long l; \
#undef ASM_OUTPUT_SOURCE_FILENAME
#define ASM_OUTPUT_SOURCE_FILENAME(FILE, FILENAME) \
fprintf (FILE, "\tfile\t\"%s\"\n", FILENAME)
do { fprintf (FILE, "\tfile\t"); \
output_quoted_string (FILE, FILENAME); \
fprintf (FILE, "\n"); \
} while (0)
#undef ASM_OUTPUT_SOURCE_LINE
#define ASM_OUTPUT_SOURCE_LINE(FILE, LINENO) \

View File

@ -71,7 +71,9 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
#define ASM_OUTPUT_SOURCE_FILENAME(FILE, FILENAME) \
do { \
fprintf (FILE, "\tfile\t\"%s\"\n", FILENAME); \
fprintf (FILE, "\tfile\t"); \
output_quoted_string (FILE, FILENAME); \
fprintf (FILE, "\n"); \
fprintf (FILE, "section ~init,\"x\"\n"); \
fprintf (FILE, "section ~fini,\"x\"\n"); \
fprintf (FILE, "section ~rodata,\"x\"\n"); \

View File

@ -1819,7 +1819,10 @@ enum reg_class { NO_REGS, AP_REG, XRF_REGS, GENERAL_REGS, AGRF_REGS,
#undef ASM_FILE_END
#define ASM_OUTPUT_SOURCE_FILENAME(FILE, NAME) \
fprintf (FILE, "\t%s\t \"%s\"\n", FILE_ASM_OP, NAME)
do { fprintf (FILE, "\t%s\t ", FILE_ASM_OP); \
output_quoted_string (FILE, NAME); \
fprintf (FILE, "\n"); \
} while (0)
#ifdef SDB_DEBUGGING_INFO
#define ASM_OUTPUT_SOURCE_LINE(FILE, LINE) \

View File

@ -578,7 +578,10 @@ static unsigned lookup_filename ();
#ifndef ASM_OUTPUT_SOURCE_FILENAME
#define ASM_OUTPUT_SOURCE_FILENAME(FILE,NAME) \
fprintf ((FILE), "\t%s\t\"%s\"\n", FILE_ASM_OP, NAME)
do { fprintf (FILE, "\t%s\t", FILE_ASM_OP); \
output_quoted_string (FILE, NAME); \
fputc ('\n', FILE); \
} while (0)
#endif
#ifndef ASM_OUTPUT_DEF