X-Git-Url: http://drtracing.org/?a=blobdiff_plain;f=gold%2Fyyscript.y;h=dfb5e4e702b635682cac9d249146623fc22ffd65;hb=401e101e0274d401e90e50cd8280a9ff36006477;hp=b519f5470c90544807eca222c7ee04824ba5ffad;hpb=410da591ba7814912e11be826b20dfba9abed9f7;p=deliverable%2Fbinutils-gdb.git diff --git a/gold/yyscript.y b/gold/yyscript.y index b519f5470c..dfb5e4e702 100644 --- a/gold/yyscript.y +++ b/gold/yyscript.y @@ -1,6 +1,6 @@ /* yyscript.y -- linker script grammar for gold. */ -/* Copyright (C) 2006-2015 Free Software Foundation, Inc. +/* Copyright (C) 2006-2019 Free Software Foundation, Inc. Written by Ian Lance Taylor . This file is part of gold. @@ -137,6 +137,7 @@ %token FORCE_COMMON_ALLOCATION %token GLOBAL /* global */ %token GROUP +%token HIDDEN %token HLL %token INCLUDE %token INHIBIT_COMMON_ALLOCATION @@ -175,6 +176,7 @@ %token SIZEOF %token SIZEOF_HEADERS /* SIZEOF_HEADERS, sizeof_headers */ %token SORT_BY_ALIGNMENT +%token SORT_BY_INIT_PRIORITY %token SORT_BY_NAME %token SPECIAL %token SQUAD @@ -677,6 +679,11 @@ wildcard_section: abort(); } } + | SORT_BY_INIT_PRIORITY '(' wildcard_name ')' + { + $$.name = $3; + $$.sort = SORT_WILDCARD_BY_INIT_PRIORITY; + } ; /* A list of file names to exclude. */ @@ -858,6 +865,8 @@ assignment: Expression_ptr e = script_exp_binary_bitwise_or(s, $3); script_set_symbol(closure, $1.value, $1.length, e, 0, 0); } + | HIDDEN '(' string '=' parse_exp ')' + { script_set_symbol(closure, $3.value, $3.length, $5, 0, 1); } | PROVIDE '(' string '=' parse_exp ')' { script_set_symbol(closure, $3.value, $3.length, $5, 1, 0); } | PROVIDE_HIDDEN '(' string '=' parse_exp ')'