summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorandreast <andreast@FreeBSD.org>2011-11-19 19:25:57 +0000
committerandreast <andreast@FreeBSD.org>2011-11-19 19:25:57 +0000
commitcb931ce6939d6d325cdae98a5edf0c0784771bfd (patch)
treefa27801bdff0526227dfcb03ba9fc656872d9d8f
parent8a4f05dc7cef04d12f90ae96a9968ec29062a773 (diff)
downloadFreeBSD-src-cb931ce6939d6d325cdae98a5edf0c0784771bfd.zip
FreeBSD-src-cb931ce6939d6d325cdae98a5edf0c0784771bfd.tar.gz
Rename the linker emulation name for powerpc and powerc64. This is needed that
we can also use the upstream binutils linker where we have to have a unique name for the FreeBSD emulation.
-rw-r--r--Makefile.inc12
-rw-r--r--contrib/binutils/ld/emulparams/elf64ppc_fbsd.sh3
-rw-r--r--contrib/gcc/config/rs6000/freebsd.h2
-rw-r--r--contrib/llvm/tools/clang/lib/Driver/Tools.cpp2
-rw-r--r--gnu/usr.bin/binutils/ld/Makefile.powerpc2
-rw-r--r--gnu/usr.bin/binutils/ld/Makefile.powerpc644
-rw-r--r--sys/boot/ofw/Makefile.inc2
-rw-r--r--sys/boot/powerpc/Makefile.inc2
-rw-r--r--sys/boot/uboot/Makefile.inc2
9 files changed, 12 insertions, 9 deletions
diff --git a/Makefile.inc1 b/Makefile.inc1
index 2f4f84c..ed4ad3c 100644
--- a/Makefile.inc1
+++ b/Makefile.inc1
@@ -291,7 +291,7 @@ LIB32CPUFLAGS= -mcpu=powerpc
LIB32CPUFLAGS= -mcpu=${TARGET_CPUTYPE}
.endif
LIB32WMAKEENV= MACHINE=powerpc MACHINE_ARCH=powerpc \
- LD="${LD} -m elf32ppc"
+ LD="${LD} -m elf32ppc_fbsd"
.endif
diff --git a/contrib/binutils/ld/emulparams/elf64ppc_fbsd.sh b/contrib/binutils/ld/emulparams/elf64ppc_fbsd.sh
new file mode 100644
index 0000000..ec2374f
--- /dev/null
+++ b/contrib/binutils/ld/emulparams/elf64ppc_fbsd.sh
@@ -0,0 +1,3 @@
+. ${srcdir}/emulparams/elf64ppc.sh
+. ${srcdir}/emulparams/elf_fbsd.sh
+
diff --git a/contrib/gcc/config/rs6000/freebsd.h b/contrib/gcc/config/rs6000/freebsd.h
index 3136a85..56907a3 100644
--- a/contrib/gcc/config/rs6000/freebsd.h
+++ b/contrib/gcc/config/rs6000/freebsd.h
@@ -193,7 +193,7 @@ extern int dot_symbols;
#undef LINK_OS_FREEBSD_SPEC
#define ASM_DEFAULT_SPEC "-mppc%{!m32:64}"
#define ASM_SPEC "%{m32:-a32}%{!m32:-a64} " SVR4_ASM_SPEC
-#define LINK_OS_FREEBSD_SPEC "%{m32:-melf32ppc}%{!m32:-melf64ppc} " LINK_OS_FREEBSD_SPEC_DEF
+#define LINK_OS_FREEBSD_SPEC "%{m32:-melf32ppc_fbsd}%{!m32:-melf64ppc_fbsd} " LINK_OS_FREEBSD_SPEC_DEF
#endif
/* _init and _fini functions are built from bits spread across many
diff --git a/contrib/llvm/tools/clang/lib/Driver/Tools.cpp b/contrib/llvm/tools/clang/lib/Driver/Tools.cpp
index 94849a6..75cadc6 100644
--- a/contrib/llvm/tools/clang/lib/Driver/Tools.cpp
+++ b/contrib/llvm/tools/clang/lib/Driver/Tools.cpp
@@ -3926,7 +3926,7 @@ void freebsd::Link::ConstructJob(Compilation &C, const JobAction &JA,
if (getToolChain().getArchName() == "powerpc") {
CmdArgs.push_back("-m");
- CmdArgs.push_back("elf32ppc");
+ CmdArgs.push_back("elf32ppc_fbsd");
}
if (Output.isFilename()) {
diff --git a/gnu/usr.bin/binutils/ld/Makefile.powerpc b/gnu/usr.bin/binutils/ld/Makefile.powerpc
index 921b88c..fed5234 100644
--- a/gnu/usr.bin/binutils/ld/Makefile.powerpc
+++ b/gnu/usr.bin/binutils/ld/Makefile.powerpc
@@ -1,6 +1,6 @@
# $FreeBSD$
-NATIVE_EMULATION= elf32ppc
+NATIVE_EMULATION= elf32ppc_fbsd
SRCS+= e${NATIVE_EMULATION}.c
CLEANFILES+= e${NATIVE_EMULATION}.c
diff --git a/gnu/usr.bin/binutils/ld/Makefile.powerpc64 b/gnu/usr.bin/binutils/ld/Makefile.powerpc64
index 8c607d7..29fba2a 100644
--- a/gnu/usr.bin/binutils/ld/Makefile.powerpc64
+++ b/gnu/usr.bin/binutils/ld/Makefile.powerpc64
@@ -1,6 +1,6 @@
# $FreeBSD$
-NATIVE_EMULATION= elf64ppc
+NATIVE_EMULATION= elf64ppc_fbsd
SRCS+= e${NATIVE_EMULATION}.c
CLEANFILES+= e${NATIVE_EMULATION}.c
@@ -11,7 +11,7 @@ e${NATIVE_EMULATION}.c: emulparams/${NATIVE_EMULATION}.sh emultempl/elf32.em \
${HOST} ${TARGET_TUPLE} ${TARGET_TUPLE} \
${NATIVE_EMULATION} "" no ${NATIVE_EMULATION} ${TARGET_TUPLE}
-PPC32_EMULATION= elf32ppc
+PPC32_EMULATION= elf32ppc_fbsd
_ppc32_path= \"${TOOLS_PREFIX}/usr/lib32\"
EMS+= ${PPC32_EMULATION}
.for ext in ${ELF_SCR_EXT}
diff --git a/sys/boot/ofw/Makefile.inc b/sys/boot/ofw/Makefile.inc
index dab65e5..e67c0dc 100644
--- a/sys/boot/ofw/Makefile.inc
+++ b/sys/boot/ofw/Makefile.inc
@@ -2,7 +2,7 @@
.if ${MACHINE_ARCH} == "powerpc64"
CFLAGS+= -m32 -mcpu=powerpc
-LDFLAGS+= -m elf32ppc
+LDFLAGS+= -m elf32ppc_fbsd
.endif
.include "../Makefile.inc"
diff --git a/sys/boot/powerpc/Makefile.inc b/sys/boot/powerpc/Makefile.inc
index dab65e5..e67c0dc 100644
--- a/sys/boot/powerpc/Makefile.inc
+++ b/sys/boot/powerpc/Makefile.inc
@@ -2,7 +2,7 @@
.if ${MACHINE_ARCH} == "powerpc64"
CFLAGS+= -m32 -mcpu=powerpc
-LDFLAGS+= -m elf32ppc
+LDFLAGS+= -m elf32ppc_fbsd
.endif
.include "../Makefile.inc"
diff --git a/sys/boot/uboot/Makefile.inc b/sys/boot/uboot/Makefile.inc
index dab65e5..e67c0dc 100644
--- a/sys/boot/uboot/Makefile.inc
+++ b/sys/boot/uboot/Makefile.inc
@@ -2,7 +2,7 @@
.if ${MACHINE_ARCH} == "powerpc64"
CFLAGS+= -m32 -mcpu=powerpc
-LDFLAGS+= -m elf32ppc
+LDFLAGS+= -m elf32ppc_fbsd
.endif
.include "../Makefile.inc"
OpenPOWER on IntegriCloud