X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=gas%2Fas.c;h=200a4d10e375ee71623f86eb9db6a8c5feb48711;hb=732f54cd823f3f6e5f2218879f89d882afe87c77;hp=5abdbf46cf64b3864ea44f49bbb3d5d8398c58bb;hpb=fd546a3587a4d61531711831c2a911a7bc95fb5d;p=external%2Fbinutils.git diff --git a/gas/as.c b/gas/as.c index 5abdbf4..200a4d1 100644 --- a/gas/as.c +++ b/gas/as.c @@ -45,7 +45,6 @@ #ifdef HAVE_ITBL_CPU #include "itbl-ops.h" #else -#define itbl_parse(itbl_file) 1 #define itbl_init() #endif @@ -60,13 +59,6 @@ extern PTR sbrk (); extern void gas_cgen_begin (void); #endif -/* Keep a record of the itbl files we read in. */ -struct itbl_file_list -{ - struct itbl_file_list *next; - char *name; -}; - /* We build a list of defsyms as we read the options, and then define them after we have initialized everything. */ struct defsym_list @@ -117,7 +109,15 @@ static char *listing_filename = NULL; static struct defsym_list *defsyms; +#ifdef HAVE_ITBL_CPU +/* Keep a record of the itbl files we read in. */ +struct itbl_file_list +{ + struct itbl_file_list *next; + char *name; +}; static struct itbl_file_list *itbl_files; +#endif static long start_time; @@ -323,9 +323,11 @@ Options:\n\ --warn don't suppress warnings\n")); fprintf (stream, _("\ --fatal-warnings treat warnings as errors\n")); +#ifdef HAVE_ITBL_CPU fprintf (stream, _("\ --itbl INSTTBL extend instruction set to include instructions\n\ matching the specifications defined in file INSTTBL\n")); +#endif fprintf (stream, _("\ -w ignored\n")); fprintf (stream, _("\ @@ -392,8 +394,10 @@ parse_args (int * pargc, char *** pargv) 'v', #endif 'w', 'X', +#ifdef HAVE_ITBL_CPU /* New option for extending instruction set (see also --itbl below). */ 't', ':', +#endif '\0' }; struct option *longopts; @@ -411,7 +415,6 @@ parse_args (int * pargc, char *** pargv) OPTION_EMULATION, OPTION_DEBUG_PREFIX_MAP, OPTION_DEFSYM, - OPTION_INSTTBL, OPTION_LISTING_LHS_WIDTH, OPTION_LISTING_LHS_WIDTH2, OPTION_LISTING_RHS_WIDTH, @@ -466,13 +469,15 @@ parse_args (int * pargc, char *** pargv) ,{"gstabs+", no_argument, NULL, OPTION_GSTABS_PLUS} ,{"hash-size", required_argument, NULL, OPTION_HASH_TABLE_SIZE} ,{"help", no_argument, NULL, OPTION_HELP} +#ifdef HAVE_ITBL_CPU /* New option for extending instruction set (see also -t above). The "-t file" or "--itbl file" option extends the basic set of valid instructions by reading "file", a text file containing a list of instruction formats. The additional opcodes and their formats are added to the built-in set of instructions, and mnemonics for new registers may also be defined. */ - ,{"itbl", required_argument, NULL, OPTION_INSTTBL} + ,{"itbl", required_argument, NULL, 't'} +#endif /* getopt allows abbreviations, so we do this to stop it from treating -k as an abbreviation for --keep-locals. Some ports use -k to enable PIC assembly. */ @@ -648,7 +653,7 @@ This program has absolutely no warranty.\n")); } break; - case OPTION_INSTTBL: +#ifdef HAVE_ITBL_CPU case 't': { /* optarg is the name of the file containing the instruction @@ -676,6 +681,7 @@ This program has absolutely no warranty.\n")); itbl_files->name); } break; +#endif case OPTION_DEPFILE: start_dependencies (optarg);