PR 6048
[binutils-gdb.git] / gold / yyscript.y
index 36051580923f45949317dadc280e2258c81bb7ea..ec2e8c0da2d8a5d9a4fceebd60290b2ab86a21da 100644 (file)
@@ -1,4 +1,4 @@
-/* yyscript.y -- linker script grammer for gold.  */
+/* yyscript.y -- linker script grammar for gold.  */
 
 /* Copyright 2006, 2007, 2008 Free Software Foundation, Inc.
    Written by Ian Lance Taylor <iant@google.com>.
@@ -232,10 +232,14 @@ linker_script:
 
 /* A command which may appear at top level of a linker script.  */
 file_cmd:
-         GROUP
+         FORCE_COMMON_ALLOCATION
+           { script_set_common_allocation(closure, 1); }
+       | GROUP
            { script_start_group(closure); }
          '(' input_list ')'
            { script_end_group(closure); }
+       | INHIBIT_COMMON_ALLOCATION
+           { script_set_common_allocation(closure, 0); }
         | OPTION '(' string ')'
            { script_parse_option(closure, $3.value, $3.length); }
        | PHDRS '{' phdrs_defs '}'