OSDN Git Service

daily update
[pf3gnuchains/pf3gnuchains3x.git] / gold / yyscript.y
index 34b8b55..81c136a 100644 (file)
@@ -266,6 +266,8 @@ file_cmd:
            { script_start_sections(closure); }
          sections_block '}'
            { script_finish_sections(closure); }
+       | TARGET_K '(' string ')'
+           { script_set_target(closure, $3.value, $3.length); }
         | VERSIONK '{'
             { script_push_lex_into_version_mode(closure); }
           version_script '}'
@@ -859,6 +861,10 @@ exp:
        | SEGMENT_START '(' string ',' exp ')'
            {
              $$ = script_exp_function_segment_start($3.value, $3.length, $5);
+             /* We need to take note of any SEGMENT_START expressions
+                because they change the behaviour of -Ttext, -Tdata and
+                -Tbss options.  */
+             script_saw_segment_start_expression(closure);
            }
        | ASSERT_K '(' exp ',' string ')'
            { $$ = script_exp_function_assert($3, $5.value, $5.length); }