From 6a089db385064d26afc0afca7b737fc75ba093c9 Mon Sep 17 00:00:00 2001 From: Sylvestre Ledru Date: Tue, 11 Feb 2014 17:30:18 +0000 Subject: [PATCH] =?utf8?q?Improve=20the=20declaration=20when=20LDPO=5FPIE?= =?utf8?q?=20is=20not=20available.=20Thanks=20to=20=C4=B0smail=20D=C3=B6nm?= =?utf8?q?ez=20for=20the=20better=20declaration.?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@201163 91177308-0d34-0410-b5e6-96231b3b80d8 --- tools/gold/gold-plugin.cpp | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/tools/gold/gold-plugin.cpp b/tools/gold/gold-plugin.cpp index 26f3f42770c..31a1555ebba 100644 --- a/tools/gold/gold-plugin.cpp +++ b/tools/gold/gold-plugin.cpp @@ -38,6 +38,12 @@ # define read _read #endif +#ifndef LDPO_PIE +// FIXME: remove this declaration when we stop maintaining Ubuntu Quantal and +// Precise and Debian Wheezy (binutils 2.23 is required) +# define LDPO_PIE 3 +#endif + using namespace llvm; namespace { @@ -153,14 +159,7 @@ ld_plugin_status onload(ld_plugin_tv *tv) { switch (tv->tv_u.tv_val) { case LDPO_REL: // .o case LDPO_DYN: // .so -#ifdef LDPO_PIE case LDPO_PIE: // position independent executable -#else - // FIXME: remove this declaration when we stop maintaining - // Ubuntu Quantal and Precise and Debian Wheezy (binutils 2.23 is - // required) - case 3: -#endif output_type = LTO_CODEGEN_PIC_MODEL_DYNAMIC; break; case LDPO_EXEC: // .exe -- 2.34.1