OpenCores
URL https://opencores.org/ocsvn/open8_urisc/open8_urisc/trunk

Subversion Repositories open8_urisc

Compare Revisions

  • This comparison shows the changes necessary to convert path
    /open8_urisc/trunk/gnu/binutils/ld/emultempl
    from Rev 148 to Rev 157
    Reverse comparison

Rev 148 → Rev 157

/elf32.em
2106,8 → 2106,6
fi
fi
 
if test -n "$PARSE_AND_LIST_ARGS_CASES" -o x"$GENERATE_SHLIB_SCRIPT" = xyes; then
 
if test -n "$PARSE_AND_LIST_PROLOGUE" ; then
fragment <<EOF
$PARSE_AND_LIST_PROLOGUE
2130,30 → 2128,43
(int ns, char **shortopts, int nl, struct option **longopts,
int nrl ATTRIBUTE_UNUSED, struct option **really_longopts ATTRIBUTE_UNUSED)
{
EOF
if test x"$GENERATE_SHLIB_SCRIPT" = xyes; then
fragment <<EOF
static const char xtra_short[] = "${PARSE_AND_LIST_SHORTOPTS}z:P:";
EOF
else
fragment <<EOF
static const char xtra_short[] = "${PARSE_AND_LIST_SHORTOPTS}z:";
EOF
fi
fragment <<EOF
static const struct option xtra_long[] = {
{"build-id", optional_argument, NULL, OPTION_BUILD_ID},
EOF
if test x"$GENERATE_SHLIB_SCRIPT" = xyes; then
fragment <<EOF
{"audit", required_argument, NULL, OPTION_AUDIT},
{"depaudit", required_argument, NULL, 'P'},
{"Bgroup", no_argument, NULL, OPTION_GROUP},
EOF
 
fi
fragment <<EOF
{"build-id", optional_argument, NULL, OPTION_BUILD_ID},
EOF
if test x"$GENERATE_SHLIB_SCRIPT" = xyes; then
fragment <<EOF
{"depaudit", required_argument, NULL, 'P'},
{"disable-new-dtags", no_argument, NULL, OPTION_DISABLE_NEW_DTAGS},
{"enable-new-dtags", no_argument, NULL, OPTION_ENABLE_NEW_DTAGS},
{"eh-frame-hdr", no_argument, NULL, OPTION_EH_FRAME_HDR},
{"exclude-libs", required_argument, NULL, OPTION_EXCLUDE_LIBS},
{"hash-style", required_argument, NULL, OPTION_HASH_STYLE},
{"Bgroup", no_argument, NULL, OPTION_GROUP},
EOF
fi
 
if test -n "$PARSE_AND_LIST_LONGOPTS" ; then
fragment <<EOF
$PARSE_AND_LIST_LONGOPTS
EOF
fi
 
fragment <<EOF
{NULL, no_argument, NULL, 0}
};
2186,17 → 2197,19
if (strcmp (optarg, "none"))
link_info.emit_note_gnu_build_id = xstrdup (optarg);
break;
 
EOF
 
if test x"$GENERATE_SHLIB_SCRIPT" = xyes; then
fragment <<EOF
case OPTION_AUDIT:
gld${EMULATION_NAME}_append_to_separated_string (&audit, optarg);
break;
 
case 'P':
gld${EMULATION_NAME}_append_to_separated_string (&depaudit, optarg);
break;
 
EOF
 
if test x"$GENERATE_SHLIB_SCRIPT" = xyes; then
fragment <<EOF
case OPTION_DISABLE_NEW_DTAGS:
link_info.new_dtags = FALSE;
break;
2236,8 → 2249,46
einfo (_("%P%F: invalid hash style \`%s'\n"), optarg);
break;
 
EOF
fi
fragment <<EOF
case 'z':
if (strcmp (optarg, "initfirst") == 0)
if (strcmp (optarg, "defs") == 0)
link_info.unresolved_syms_in_objects = RM_GENERATE_ERROR;
else if (strcmp (optarg, "muldefs") == 0)
link_info.allow_multiple_definition = TRUE;
else if (CONST_STRNEQ (optarg, "max-page-size="))
{
char *end;
 
config.maxpagesize = strtoul (optarg + 14, &end, 0);
if (*end || (config.maxpagesize & (config.maxpagesize - 1)) != 0)
einfo (_("%P%F: invalid maxium page size \`%s'\n"),
optarg + 14);
}
else if (CONST_STRNEQ (optarg, "common-page-size="))
{
char *end;
config.commonpagesize = strtoul (optarg + 17, &end, 0);
if (*end
|| (config.commonpagesize & (config.commonpagesize - 1)) != 0)
einfo (_("%P%F: invalid common page size \`%s'\n"),
optarg + 17);
}
else if (strcmp (optarg, "execstack") == 0)
{
link_info.execstack = TRUE;
link_info.noexecstack = FALSE;
}
else if (strcmp (optarg, "noexecstack") == 0)
{
link_info.noexecstack = TRUE;
link_info.execstack = FALSE;
}
EOF
if test x"$GENERATE_SHLIB_SCRIPT" = xyes; then
fragment <<EOF
else if (strcmp (optarg, "initfirst") == 0)
link_info.flags_1 |= (bfd_vma) DF_1_INITFIRST;
else if (strcmp (optarg, "interpose") == 0)
link_info.flags_1 |= (bfd_vma) DF_1_INTERPOSE;
2266,10 → 2317,6
link_info.flags |= (bfd_vma) DF_ORIGIN;
link_info.flags_1 |= (bfd_vma) DF_1_ORIGIN;
}
else if (strcmp (optarg, "defs") == 0)
link_info.unresolved_syms_in_objects = RM_GENERATE_ERROR;
else if (strcmp (optarg, "muldefs") == 0)
link_info.allow_multiple_definition = TRUE;
else if (strcmp (optarg, "combreloc") == 0)
link_info.combreloc = TRUE;
else if (strcmp (optarg, "nocombreloc") == 0)
2276,50 → 2323,18
link_info.combreloc = FALSE;
else if (strcmp (optarg, "nocopyreloc") == 0)
link_info.nocopyreloc = TRUE;
else if (strcmp (optarg, "execstack") == 0)
{
link_info.execstack = TRUE;
link_info.noexecstack = FALSE;
}
else if (strcmp (optarg, "noexecstack") == 0)
{
link_info.noexecstack = TRUE;
link_info.execstack = FALSE;
}
EOF
 
if test -n "$COMMONPAGESIZE"; then
fragment <<EOF
else if (strcmp (optarg, "relro") == 0)
link_info.relro = TRUE;
else if (strcmp (optarg, "norelro") == 0)
link_info.relro = FALSE;
EOF
fi
fi
 
fragment <<EOF
else if (CONST_STRNEQ (optarg, "max-page-size="))
{
char *end;
 
config.maxpagesize = strtoul (optarg + 14, &end, 0);
if (*end || (config.maxpagesize & (config.maxpagesize - 1)) != 0)
einfo (_("%P%F: invalid maxium page size \`%s'\n"),
optarg + 14);
}
else if (CONST_STRNEQ (optarg, "common-page-size="))
{
char *end;
config.commonpagesize = strtoul (optarg + 17, &end, 0);
if (*end
|| (config.commonpagesize & (config.commonpagesize - 1)) != 0)
einfo (_("%P%F: invalid common page size \`%s'\n"),
optarg + 17);
}
/* What about the other Solaris -z options? FIXME. */
else
einfo (_("%P: warning: -z %s ignored.\n"), optarg);
break;
EOF
fi
 
if test -n "$PARSE_AND_LIST_ARGS_CASES" ; then
fragment <<EOF
2341,19 → 2356,24
static void
gld${EMULATION_NAME}_list_options (FILE * file)
{
EOF
if test x"$GENERATE_SHLIB_SCRIPT" = xyes; then
fragment <<EOF
fprintf (file, _("\
--build-id[=STYLE] Generate build ID note\n"));
fprintf (file, _("\
--audit=AUDITLIB Specify a library to use for auditing\n"));
fprintf (file, _("\
-P AUDITLIB, --depaudit=AUDITLIB\n" "\
Specify a library to use for auditing dependencies\n"));
-Bgroup Selects group name lookup rules for DSO\n"));
EOF
 
fi
fragment <<EOF
fprintf (file, _("\
--build-id[=STYLE] Generate build ID note\n"));
EOF
if test x"$GENERATE_SHLIB_SCRIPT" = xyes; then
fragment <<EOF
fprintf (file, _("\
-Bgroup Selects group name lookup rules for DSO\n"));
-P AUDITLIB, --depaudit=AUDITLIB\n" "\
Specify a library to use for auditing dependencies\n"));
fprintf (file, _("\
--disable-new-dtags Disable new dynamic tags\n"));
fprintf (file, _("\
2361,13 → 2381,25
fprintf (file, _("\
--eh-frame-hdr Create .eh_frame_hdr section\n"));
fprintf (file, _("\
--exclude-libs=LIBS Make all symbols in LIBS hidden\n"));
fprintf (file, _("\
--hash-style=STYLE Set hash style to sysv, gnu or both\n"));
fprintf (file, _("\
-z combreloc Merge dynamic relocs into one section and sort\n"));
EOF
fi
 
fragment <<EOF
fprintf (file, _("\
-z common-page-size=SIZE Set common page size to SIZE\n"));
fprintf (file, _("\
-z defs Report unresolved symbols in object files.\n"));
fprintf (file, _("\
-z execstack Mark executable as requiring executable stack\n"));
EOF
 
if test x"$GENERATE_SHLIB_SCRIPT" = xyes; then
fragment <<EOF
fprintf (file, _("\
-z initfirst Mark DSO to be initialized first at runtime\n"));
fprintf (file, _("\
2376,8 → 2408,18
-z lazy Mark object lazy runtime binding (default)\n"));
fprintf (file, _("\
-z loadfltr Mark object requiring immediate process\n"));
EOF
fi
 
fragment <<EOF
fprintf (file, _("\
-z max-page-size=SIZE Set maximum page size to SIZE\n"));
fprintf (file, _("\
-z muldefs Allow multiple definitions\n"));
EOF
 
if test x"$GENERATE_SHLIB_SCRIPT" = xyes; then
fragment <<EOF
fprintf (file, _("\
-z nocombreloc Don't merge dynamic relocs into one section\n"));
fprintf (file, _("\
2390,40 → 2432,24
-z nodlopen Mark DSO not available to dlopen\n"));
fprintf (file, _("\
-z nodump Mark DSO not available to dldump\n"));
EOF
fi
fragment <<EOF
fprintf (file, _("\
-z noexecstack Mark executable as not requiring executable stack\n"));
EOF
 
if test -n "$COMMONPAGESIZE"; then
if test x"$GENERATE_SHLIB_SCRIPT" = xyes; then
fragment <<EOF
fprintf (file, _("\
-z norelro Don't create RELRO program header\n"));
EOF
fi
 
fragment <<EOF
fprintf (file, _("\
-z now Mark object non-lazy runtime binding\n"));
fprintf (file, _("\
-z origin Mark object requiring immediate \$ORIGIN\n\
processing at runtime\n"));
EOF
 
if test -n "$COMMONPAGESIZE"; then
fragment <<EOF
fprintf (file, _("\
-z relro Create RELRO program header\n"));
EOF
fi
 
fragment <<EOF
fprintf (file, _("\
-z max-page-size=SIZE Set maximum page size to SIZE\n"));
fprintf (file, _("\
-z common-page-size=SIZE Set common page size to SIZE\n"));
fprintf (file, _("\
-z KEYWORD Ignored for Solaris compatibility\n"));
EOF
fi
 
if test -n "$PARSE_AND_LIST_OPTIONS" ; then
2442,17 → 2468,6
EOF
fi
fi
else
fragment <<EOF
#define gld${EMULATION_NAME}_add_options NULL
#define gld${EMULATION_NAME}_handle_option NULL
EOF
if test x"$LDEMUL_LIST_OPTIONS" != xgld"$EMULATION_NAME"_list_options; then
fragment <<EOF
#define gld${EMULATION_NAME}_list_options NULL
EOF
fi
fi
 
fragment <<EOF
 
/ppc64elf.em
61,6 → 61,9
/* Whether to sort input toc and got sections. */
static int no_toc_sort = 0;
 
/* Set if PLT call stubs should load r11. */
static int plt_static_chain = 0;
 
/* Whether to emit symbols for stubs. */
static int emit_stub_syms = -1;
 
500,7 → 503,7
einfo ("%P: .init/.fini fragments use differing TOC pointers\n");
 
/* Call into the BFD backend to do the real work. */
if (!ppc64_elf_size_stubs (&link_info, group_size))
if (!ppc64_elf_size_stubs (&link_info, group_size, plt_static_chain))
einfo ("%X%P: can not size stub section: %E\n");
}
}
649,9 → 652,11
# Define some shell vars to insert bits of code into the standard elf
# parse_args and list_options functions.
#
PARSE_AND_LIST_PROLOGUE='
#define OPTION_STUBGROUP_SIZE 301
#define OPTION_STUBSYMS (OPTION_STUBGROUP_SIZE + 1)
PARSE_AND_LIST_PROLOGUE=${PARSE_AND_LIST_PROLOGUE}'
#define OPTION_STUBGROUP_SIZE 321
#define OPTION_PLT_STATIC_CHAIN (OPTION_STUBGROUP_SIZE + 1)
#define OPTION_NO_PLT_STATIC_CHAIN (OPTION_PLT_STATIC_CHAIN + 1)
#define OPTION_STUBSYMS (OPTION_NO_PLT_STATIC_CHAIN + 1)
#define OPTION_NO_STUBSYMS (OPTION_STUBSYMS + 1)
#define OPTION_DOTSYMS (OPTION_NO_STUBSYMS + 1)
#define OPTION_NO_DOTSYMS (OPTION_DOTSYMS + 1)
664,8 → 669,10
#define OPTION_NON_OVERLAPPING_OPD (OPTION_NO_TOC_SORT + 1)
'
 
PARSE_AND_LIST_LONGOPTS='
PARSE_AND_LIST_LONGOPTS=${PARSE_AND_LIST_LONGOPTS}'
{ "stub-group-size", required_argument, NULL, OPTION_STUBGROUP_SIZE },
{ "plt-static-chain", no_argument, NULL, OPTION_PLT_STATIC_CHAIN },
{ "no-plt-static-chain", no_argument, NULL, OPTION_NO_PLT_STATIC_CHAIN },
{ "emit-stub-syms", no_argument, NULL, OPTION_STUBSYMS },
{ "no-emit-stub-syms", no_argument, NULL, OPTION_NO_STUBSYMS },
{ "dotsyms", no_argument, NULL, OPTION_DOTSYMS },
679,7 → 686,7
{ "non-overlapping-opd", no_argument, NULL, OPTION_NON_OVERLAPPING_OPD },
'
 
PARSE_AND_LIST_OPTIONS='
PARSE_AND_LIST_OPTIONS=${PARSE_AND_LIST_OPTIONS}'
fprintf (file, _("\
--stub-group-size=N Maximum size of a group of input sections that\n\
can be handled by one stub section. A negative\n\
691,6 → 698,12
choose suitable defaults.\n"
));
fprintf (file, _("\
--plt-static-chain PLT call stubs should load r11.\n"
));
fprintf (file, _("\
--no-plt-static-chain PLT call stubs should not load r11. (default)\n"
));
fprintf (file, _("\
--emit-stub-syms Label linker stubs with a symbol.\n"
));
fprintf (file, _("\
729,7 → 742,7
));
'
 
PARSE_AND_LIST_ARGS_CASES='
PARSE_AND_LIST_ARGS_CASES=${PARSE_AND_LIST_ARGS_CASES}'
case OPTION_STUBGROUP_SIZE:
{
const char *end;
739,6 → 752,14
}
break;
 
case OPTION_PLT_STATIC_CHAIN:
plt_static_chain = 1;
break;
 
case OPTION_NO_PLT_STATIC_CHAIN:
plt_static_chain = 0;
break;
 
case OPTION_STUBSYMS:
emit_stub_syms = 1;
break;
/armelf.em
42,6 → 42,7
static int no_wchar_size_warning = 0;
static int pic_veneer = 0;
static int merge_exidx_entries = -1;
static int fix_arm1176 = 1;
 
static void
gld${EMULATION_NAME}_before_parse (void)
464,7 → 465,8
target2_type, fix_v4bx, use_blx,
vfp11_denorm_fix, no_enum_size_warning,
no_wchar_size_warning,
pic_veneer, fix_cortex_a8);
pic_veneer, fix_cortex_a8,
fix_arm1176);
 
stub_file = lang_add_input_file ("linker stubs",
lang_input_file_is_fake_enum,
529,6 → 531,8
#define OPTION_FIX_CORTEX_A8 314
#define OPTION_NO_FIX_CORTEX_A8 315
#define OPTION_NO_MERGE_EXIDX_ENTRIES 316
#define OPTION_FIX_ARM1176 317
#define OPTION_NO_FIX_ARM1176 318
'
 
PARSE_AND_LIST_SHORTOPTS=p
551,6 → 555,8
{ "fix-cortex-a8", no_argument, NULL, OPTION_FIX_CORTEX_A8 },
{ "no-fix-cortex-a8", no_argument, NULL, OPTION_NO_FIX_CORTEX_A8 },
{ "no-merge-exidx-entries", no_argument, NULL, OPTION_NO_MERGE_EXIDX_ENTRIES },
{ "fix-arm1176", no_argument, NULL, OPTION_FIX_ARM1176 },
{ "no-fix-arm1176", no_argument, NULL, OPTION_NO_FIX_ARM1176 },
'
 
PARSE_AND_LIST_OPTIONS='
579,7 → 585,7
));
fprintf (file, _(" --[no-]fix-cortex-a8 Disable/enable Cortex-A8 Thumb-2 branch erratum fix\n"));
fprintf (file, _(" --no-merge-exidx-entries Disable merging exidx entries\n"));
fprintf (file, _(" --[no-]fix-arm1176 Disable/enable ARM1176 BLX immediate erratum fix\n"));
'
 
PARSE_AND_LIST_ARGS_CASES='
662,7 → 668,15
 
case OPTION_NO_MERGE_EXIDX_ENTRIES:
merge_exidx_entries = 0;
break;
 
case OPTION_FIX_ARM1176:
fix_arm1176 = 1;
break;
 
case OPTION_NO_FIX_ARM1176:
fix_arm1176 = 0;
break;
'
 
# We have our own before_allocation etc. functions, but they call
/ppc32elf.em
1,5 → 1,6
# This shell script emits a C file. -*- C -*-
# Copyright 2003, 2005, 2007, 2008, 2009 Free Software Foundation, Inc.
# Copyright 2003, 2005, 2007, 2008, 2009, 2010, 2011
# Free Software Foundation, Inc.
#
# This file is part of the GNU Binutils.
#
176,8 → 177,8
# Define some shell vars to insert bits of code into the standard elf
# parse_args and list_options functions.
#
PARSE_AND_LIST_PROLOGUE='
#define OPTION_NO_TLS_OPT 301
PARSE_AND_LIST_PROLOGUE=${PARSE_AND_LIST_PROLOGUE}'
#define OPTION_NO_TLS_OPT 321
#define OPTION_NO_TLS_GET_ADDR_OPT (OPTION_NO_TLS_OPT + 1)
#define OPTION_NEW_PLT (OPTION_NO_TLS_GET_ADDR_OPT + 1)
#define OPTION_OLD_PLT (OPTION_NEW_PLT + 1)
186,7 → 187,7
#define OPTION_NO_STUBSYMS (OPTION_STUBSYMS + 1)
'
 
PARSE_AND_LIST_LONGOPTS='
PARSE_AND_LIST_LONGOPTS=${PARSE_AND_LIST_LONGOPTS}'
{ "emit-stub-syms", no_argument, NULL, OPTION_STUBSYMS },
{ "no-emit-stub-syms", no_argument, NULL, OPTION_NO_STUBSYMS },
{ "no-tls-optimize", no_argument, NULL, OPTION_NO_TLS_OPT },
196,7 → 197,7
{ "sdata-got", no_argument, NULL, OPTION_OLD_GOT },
'
 
PARSE_AND_LIST_OPTIONS='
PARSE_AND_LIST_OPTIONS=${PARSE_AND_LIST_OPTIONS}'
fprintf (file, _("\
--emit-stub-syms Label linker stubs with a symbol.\n\
--no-emit-stub-syms Don'\''t label linker stubs with a symbol.\n\
208,7 → 209,7
));
'
 
PARSE_AND_LIST_ARGS_CASES='
PARSE_AND_LIST_ARGS_CASES=${PARSE_AND_LIST_ARGS_CASES}'
case OPTION_STUBSYMS:
emit_stub_syms = 1;
break;

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.