Skip to contentSkip to conversation

gcc: Enable mips plt extentions if DISTRO_FEATURE has mplt.

PATCH In review Khem Raj 3 participants 12 messages Dec 19, 2009 – Dec 21, 2009

lore
Share & tools
lore

Khem Raj

author
#0 lore raw

PATCH 2/3 gcc: Enable mips plt extentions if DISTRO_FEATURE has mplt.

* Newer gcc (4.4+) has implemented -mplt option to enable PLT and copy relocation extentions of MIPS ABI which makes shared code run a lot faster. This feature is however controlled by DISTRO_FEATURES which should add 'mplt' to DISTRO_FEATURES to enable it.

---
 recipes/gcc/gcc-3.3.4.inc              |    2 +-
 recipes/gcc/gcc-3.4.3.inc              |    2 +-
 recipes/gcc/gcc-3.4.4.inc              |    2 +-
 recipes/gcc/gcc-4.1.0.inc              |    2 +-
 recipes/gcc/gcc-4.1.1.inc              |    2 +-
 recipes/gcc/gcc-4.1.2.inc              |    2 +-
 recipes/gcc/gcc-4.2.2.inc              |    2 +-
 recipes/gcc/gcc-4.2.3.inc              |    2 +-
 recipes/gcc/gcc-4.2.4.inc              |    2 +-
 recipes/gcc/gcc-4.3.1.inc              |    2 +-
 recipes/gcc/gcc-4.3.2.inc              |    2 +-
 recipes/gcc/gcc-4.3.3.inc              |    2 +-
 recipes/gcc/gcc-4.3.4.inc              |    2 +-
 recipes/gcc/gcc-4.4.1.inc              |    2 +-
 recipes/gcc/gcc-4.4.2.inc              |    2 +-
 recipes/gcc/gcc-common.inc             |    5 +++++
 recipes/gcc/gcc-configure-common.inc   |    5 ++++-
 recipes/gcc/gcc-cross-initial.inc      |    3 ++-
 recipes/gcc/gcc-cross-intermediate.inc |    3 ++-
 19 files changed, 28 insertions(+), 18 deletions(-)
recipes/gcc/gcc-3.3.4.inc +1 -1
index 635e617..a3fbdde 100644
@@ -1,6 +1,6 @@
 require gcc-common.inc
 
-INC_PR = "r10"
+INC_PR = "r11"
 
 SRC_URI = "${GNU_MIRROR}/gcc/releases/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	   file://arm-gotoff.dpatch;patch=1;pnum=0 \
recipes/gcc/gcc-3.4.3.inc +1 -1
index 72f9042..febe0fc 100644
@@ -1,6 +1,6 @@
 require gcc-common.inc
 
-INC_PR = "r18"
+INC_PR = "r19"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	   file://gcc34-reverse-compare.patch;patch=1 \
recipes/gcc/gcc-3.4.4.inc +1 -1
index 9a02c5d..b87e1e3 100644
@@ -1,6 +1,6 @@
 require gcc-common.inc
 
-INC_PR = "r14"
+INC_PR = "r15"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	   file://gcc34-reverse-compare.patch;patch=1 \
recipes/gcc/gcc-4.1.0.inc +1 -1
index 7bb1a34..df0ae3f 100644
@@ -1,6 +1,6 @@
 require gcc-common.inc
 
-INC_PR = "r9"
+INC_PR = "r10"
 
 DEFAULT_PREFERENCE = "-1"
 
recipes/gcc/gcc-4.1.1.inc +1 -1
index 68323ac..a960b41 100644
@@ -2,7 +2,7 @@ require gcc-common.inc
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r0"
+INC_PR = "r1"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	file://100-uclibc-conf.patch;patch=1 \
recipes/gcc/gcc-4.1.2.inc +1 -1
index 911d2d9..21bf486 100644
@@ -2,7 +2,7 @@ require gcc-common.inc
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r21"
+INC_PR = "r22"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	file://100-uclibc-conf.patch;patch=1 \
recipes/gcc/gcc-4.2.2.inc +1 -1
index 0eb1223..931de9a 100644
@@ -3,7 +3,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r15"
+INC_PR = "r16"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	file://100-uclibc-conf.patch;patch=1 \
recipes/gcc/gcc-4.2.3.inc +1 -1
index 1501c7e..b2fb029 100644
@@ -3,7 +3,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r12"
+INC_PR = "r17"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	file://100-uclibc-conf.patch;patch=1 \
recipes/gcc/gcc-4.2.4.inc +1 -1
index 3249c09..e96122a 100644
@@ -3,7 +3,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r9"
+INC_PR = "r10"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	file://100-uclibc-conf.patch;patch=1 \
recipes/gcc/gcc-4.3.1.inc +1 -1
index 0b05f0a..3eaff45 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r19"
+INC_PR = "r20"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	file://fedora/gcc43-c++-builtin-redecl.patch;patch=1;pnum=0 \
recipes/gcc/gcc-4.3.2.inc +1 -1
index 5483b8f..8d40d72 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r9"
+INC_PR = "r10"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	file://fedora/gcc43-c++-builtin-redecl.patch;patch=1;pnum=0 \
recipes/gcc/gcc-4.3.3.inc +1 -1
index 46d5e35..47bfbc6 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r10"
+INC_PR = "r11"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	file://fedora/gcc43-c++-builtin-redecl.patch;patch=1;pnum=0 \
recipes/gcc/gcc-4.3.4.inc +1 -1
index 2b1054c..ff02ac5 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r7"
+INC_PR = "r8"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	file://fedora/gcc43-c++-builtin-redecl.patch;patch=1;pnum=0 \
recipes/gcc/gcc-4.4.1.inc +1 -1
index 9daff95..cbf28dd 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r7"
+INC_PR = "r8"
 
 FILESPATHPKG .= ":gcc-$PV"
 
recipes/gcc/gcc-4.4.2.inc +1 -1
index 514cc9f..1ef1359 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r0"
+INC_PR = "r1"
 
 FILESPATHPKG .= ":gcc-$PV"
 
recipes/gcc/gcc-common.inc +5 -0
index 6e777e6..97b140c 100644
@@ -15,6 +15,11 @@ def get_gcc_fpu_setting(bb, d):
         return "--with-float=soft"
     return ""
 
+def get_gcc_mips_plt_setting(bb, d):
+    if bb.data.getVar('TARGET_ARCH', d, 1) in [ 'mips', 'mipsel' ] and 'mplt' in bb.data.getVar('DISTRO_FEATURES',d,1).split() :
+        return "--with-mips-plt"
+    return ""
+
 # We really need HOST_SYS here for some packages and TARGET_SYS for others.
 # For now, libgcc is most important so we fix for that - RP.
 SHLIBSDIR = "${STAGING_DIR_TARGET}/shlibs"
recipes/gcc/gcc-configure-common.inc +4 -1
index 8a96326..ee6c0e7 100644
@@ -13,6 +13,8 @@ OBJC_linux-uclibceabi ?= ""
 OBJC_linux-uclibc ?= ""
 OBJC_avr ?= ""
 OBJC_nylon ?= ""
+OBJC_mips ?= ""
+OBJC_mipsel ?= ""
 OBJC ?= ",objc"
 
 # gcc 3.x expects 'f77', 4.0 expects 'f95', 4.1 and 4.2 expect 'fortran'
@@ -36,7 +38,8 @@ EXTRA_OECONF = "${@['--enable-clocale=generic', ''][bb.data.getVar('USE_NLS', d,
                 --program-prefix=${TARGET_PREFIX} \
                 ${EXTRA_OECONF_BASE} \
                 ${EXTRA_OECONF_FPU} \
-                ${EXTRA_OECONF_PATHS}"
+                ${EXTRA_OECONF_PATHS} \
+		${@get_gcc_mips_plt_setting(bb, d)}"
 
 # Build uclibc compilers without cxa_atexit support
 EXTRA_OECONF_append_linux               = " --enable-__cxa_atexit"
recipes/gcc/gcc-cross-initial.inc +2 -1
index a2c4445..2ab1d7f 100644
@@ -16,7 +16,8 @@ EXTRA_OECONF = "--with-local-prefix=${STAGING_DIR_TARGET}${target_prefix} \
 		--program-prefix=${TARGET_PREFIX} \
 		--with-sysroot=${STAGING_DIR_TARGET} \
 		--with-build-sysroot=${STAGING_DIR_TARGET} \
-		${@get_gcc_fpu_setting(bb, d)}"
+		${@get_gcc_fpu_setting(bb, d)} \
+		${@get_gcc_mips_plt_setting(bb, d)}"
 
 do_install () {
 	:
recipes/gcc/gcc-cross-intermediate.inc +2 -1
index ccfa2b4..50792b6 100644
@@ -14,7 +14,8 @@ EXTRA_OECONF = "--with-local-prefix=${STAGING_DIR_TARGET}${target_prefix} \
 		--program-prefix=${TARGET_PREFIX} \
 		--with-sysroot=${STAGING_DIR_TARGET} \
 		--with-build-sysroot=${STAGING_DIR_TARGET} \
-		${@get_gcc_fpu_setting(bb, d)}"
+		${@get_gcc_fpu_setting(bb, d)} \
+		${@get_gcc_mips_plt_setting(bb, d)}"
 
 do_stage_append () {
 	# get rid of dummy libc.so
Signature · 1 line
1.6.3.3
author
#1 lore raw

PATCH 3/3 minimal: Add 'mplt' to DISTRO_FEATURES.

* As minimal-uclibc includes minimal conf the
distro features get inherited. mplt is not
supported on uclibc yet. So we should disable
it for uclibc/mips based distros.

---
 conf/distro/minimal-uclibc.conf |    8 ++++++++
 conf/distro/minimal.conf        |    6 ++++++
 2 files changed, 14 insertions(+), 0 deletions(-)
conf/distro/minimal-uclibc.conf +8 -0
index 9594622..62855ee 100644
@@ -19,3 +19,11 @@ TARGET_FPU_armeb = "soft"
 LIBC = "uclibc"
 
 require conf/distro/minimal.conf
+
+# FEATURE SELECTION
+#############################################################################
+# We want images supporting the following features (for task-base)
+DISTRO_FEATURES = "nfs smbfs wifi ppp alsa ext2 vfat pcmcia usbgadget usbhost pci"
+# Following features are for ARM and E500 based machines
+DISTRO_FEATURES += "eabi"
+
conf/distro/minimal.conf +6 -0
index 1e9eec2..00397db 100644
@@ -28,6 +28,12 @@ DISTRO_FEATURES = "nfs smbfs wifi ppp alsa ext2 vfat pcmcia usbgadget usbhost pc
 # Following features are for ARM and E500 based machines
 DISTRO_FEATURES += "eabi"
 
+# The following feature enables the MIPS ABI PLT extensions
+# This feature needs GCC 4.4 binutils 2.19 or glibc/eglibc 2.9
+# or higher
+
+DISTRO_FEATURES += "mplt"
+
 #############################################################################
 # LIBRARY NAMES
 #############################################################################
Signature · 1 line
1.6.3.3
#2 lore raw

Re: [PATCH 3/3] minimal: Add 'mplt' to DISTRO_FEATURES.

Quoted 9 lines · On Saturday 19 December 2009 23:26:36 Khem Raj wrote:

* As minimal-uclibc includes minimal conf the
distro features get inherited. mplt is not
supported on uclibc yet. So we should disable
it for uclibc/mips based distros.

require conf/distro/minimal.conf

conf/distro/minimal-uclibc.conf +3 -0
+
+# FEATURE SELECTION
+##########################################################################
Quoted 4 lines

### +# We want images supporting the following features (for task-base)
+DISTRO_FEATURES = "nfs smbfs wifi ppp alsa ext2 vfat pcmcia usbgadget usbhost pci" +# Following features are for ARM and E500 based machines
+DISTRO_FEATURES += "eabi"

maybe you want to use the oe filterout thing?

author
#3 lore raw

Re: [PATCH 3/3] minimal: Add 'mplt' to DISTRO_FEATURES.

Quoted 6 lines · Holger Hans Peter Freyther
Quoted 4 lines · On Saturday 19 December 2009 23:26:36 Khem Raj wrote:

* As minimal-uclibc includes minimal conf the
  distro features get inherited. mplt is not
  supported on uclibc yet. So we should disable
  it for uclibc/mips based distros.

Quoted 10 lines
Quoted 8 lines

 require conf/distro/minimal.conf

conf/distro/minimal-uclibc.conf +3 -0
+
+# FEATURE SELECTION
+##########################################################################

### +# We want images supporting the following features (for task-base) +DISTRO_FEATURES = "nfs smbfs wifi ppp alsa ext2 vfat pcmcia usbgadget usbhost pci" +# Following features are for ARM and E500 based machines +DISTRO_FEATURES += "eabi"

maybe you want to use the oe filterout thing?

I tried to use oe_filter_out but I did not succeed, I guess distro conf files are too early for in place evaluation
and if I had to do lazy evaluation then it has to be done somewhere later which I did not know what it could be

any ideas ?

Thanks

-Khem

#4 lore raw

Re: [PATCH 3/3] minimal: Add 'mplt' to DISTRO_FEATURES.

Quoted 4 lines · On Sunday 20 December 2009 10:01:40 Khem Raj wrote:

I tried to use oe_filter_out but I did not succeed, I guess distro conf files are too early for in place evaluation
and if I had to do lazy evaluation then it has to be done somewhere later which I did not know what it could be

did you try with := ?

author
#5 lore raw

Re: [PATCH 3/3] minimal: Add 'mplt' to DISTRO_FEATURES.

Quoted 8 lines · Holger Hans Peter Freyther
Quoted 4 lines · On Sunday 20 December 2009 10:01:40 Khem Raj wrote:

I tried to use oe_filter_out but I did not succeed, I guess distro conf files are too early for in place evaluation
and if I had to do lazy evaluation then it has to be done somewhere later which I did not know what it could be

did you try with := ?

DISTRO_FEATURES := "${@oe_filter_out('mplt',
bb.data.getVar('DISTRO_FEATURES', d, 1), d))}"

If I use := I get this

NameError: name 'oe_filter_out' is not defined

and if I use something like this
DISTRO_FEATURES = "${@bb.data.setVar('DISTRO_FEATURES', oe_filter_out('mplt', bb.data.getVar('DISTRO_FEATURES', d, 1), d))}" that ends up in same error too

-Khem

Quoted 7 lines

_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel

#6 lore raw

Re: [PATCH 3/3] minimal: Add 'mplt' to DISTRO_FEATURES.

Quoted 9 lines · On Sunday 20 December 2009 18:52:59 Khem Raj wrote:

On Sun, Dec 20, 2009 at 1:21 AM, Holger Hans Peter Freyther

Quoted 6 lines · <[email protected]> wrote:
Quoted 4 lines · On Sunday 20 December 2009 10:01:40 Khem Raj wrote:

I tried to use oe_filter_out but I did not succeed, I guess distro conf files are too early for in place evaluation
and if I had to do lazy evaluation then it has to be done somewhere later which I did not know what it could be

Quoted 8 lines
Quoted 1 line

did you try with := ?

DISTRO_FEATURES := "${@oe_filter_out('mplt',
bb.data.getVar('DISTRO_FEATURES', d, 1), d))}"

If I use := I get this

NameError: name 'oe_filter_out' is not defined

Ah right.... base.bbclass might or might not be parsed by then and oe_filter_out not being known at this state. So we really have no other way than copying the definition. Could you add a comment to the place where we copied the stuff from hinting that -uclibc.conf needs to be updated too?

z.

#8 lore raw
In reply to Khem Raj

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Why am I getting these errors:

NOTE: <type 'exceptions.NameError'>:name 'get_gcc_mips_plt_setting' is not defined while evaluating:

when building kernel modules for an arm machine?

Quoted 278 lines · Khem Raj

* Newer gcc (4.4+) has implemented -mplt option to enable PLT and copy relocation extentions of MIPS ABI which makes shared code run a lot faster. This feature is however controlled by DISTRO_FEATURES which should add 'mplt' to DISTRO_FEATURES to enable it.

---
 recipes/gcc/gcc-3.3.4.inc              |    2 +-
 recipes/gcc/gcc-3.4.3.inc              |    2 +-
 recipes/gcc/gcc-3.4.4.inc              |    2 +-
 recipes/gcc/gcc-4.1.0.inc              |    2 +-
 recipes/gcc/gcc-4.1.1.inc              |    2 +-
 recipes/gcc/gcc-4.1.2.inc              |    2 +-
 recipes/gcc/gcc-4.2.2.inc              |    2 +-
 recipes/gcc/gcc-4.2.3.inc              |    2 +-
 recipes/gcc/gcc-4.2.4.inc              |    2 +-
 recipes/gcc/gcc-4.3.1.inc              |    2 +-
 recipes/gcc/gcc-4.3.2.inc              |    2 +-
 recipes/gcc/gcc-4.3.3.inc              |    2 +-
 recipes/gcc/gcc-4.3.4.inc              |    2 +-
 recipes/gcc/gcc-4.4.1.inc              |    2 +-
 recipes/gcc/gcc-4.4.2.inc              |    2 +-
 recipes/gcc/gcc-common.inc             |    5 +++++
 recipes/gcc/gcc-configure-common.inc   |    5 ++++-
 recipes/gcc/gcc-cross-initial.inc      |    3 ++-
 recipes/gcc/gcc-cross-intermediate.inc |    3 ++-
 19 files changed, 28 insertions(+), 18 deletions(-)
recipes/gcc/gcc-3.3.4.inc +1 -1
index 635e617..a3fbdde 100644
@@ -1,6 +1,6 @@
 require gcc-common.inc
 
-INC_PR = "r10"
+INC_PR = "r11"
 
 SRC_URI = "${GNU_MIRROR}/gcc/releases/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	   file://arm-gotoff.dpatch;patch=1;pnum=0 \
recipes/gcc/gcc-3.4.3.inc +1 -1
index 72f9042..febe0fc 100644
@@ -1,6 +1,6 @@
 require gcc-common.inc
 
-INC_PR = "r18"
+INC_PR = "r19"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	   file://gcc34-reverse-compare.patch;patch=1 \
recipes/gcc/gcc-3.4.4.inc +1 -1
index 9a02c5d..b87e1e3 100644
@@ -1,6 +1,6 @@
 require gcc-common.inc
 
-INC_PR = "r14"
+INC_PR = "r15"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	   file://gcc34-reverse-compare.patch;patch=1 \
recipes/gcc/gcc-4.1.0.inc +1 -1
index 7bb1a34..df0ae3f 100644
@@ -1,6 +1,6 @@
 require gcc-common.inc
 
-INC_PR = "r9"
+INC_PR = "r10"
 
 DEFAULT_PREFERENCE = "-1"
 
recipes/gcc/gcc-4.1.1.inc +1 -1
index 68323ac..a960b41 100644
@@ -2,7 +2,7 @@ require gcc-common.inc
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r0"
+INC_PR = "r1"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	file://100-uclibc-conf.patch;patch=1 \
recipes/gcc/gcc-4.1.2.inc +1 -1
index 911d2d9..21bf486 100644
@@ -2,7 +2,7 @@ require gcc-common.inc
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r21"
+INC_PR = "r22"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	file://100-uclibc-conf.patch;patch=1 \
recipes/gcc/gcc-4.2.2.inc +1 -1
index 0eb1223..931de9a 100644
@@ -3,7 +3,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r15"
+INC_PR = "r16"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	file://100-uclibc-conf.patch;patch=1 \
recipes/gcc/gcc-4.2.3.inc +1 -1
index 1501c7e..b2fb029 100644
@@ -3,7 +3,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r12"
+INC_PR = "r17"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	file://100-uclibc-conf.patch;patch=1 \
recipes/gcc/gcc-4.2.4.inc +1 -1
index 3249c09..e96122a 100644
@@ -3,7 +3,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r9"
+INC_PR = "r10"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	file://100-uclibc-conf.patch;patch=1 \
recipes/gcc/gcc-4.3.1.inc +1 -1
index 0b05f0a..3eaff45 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r19"
+INC_PR = "r20"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	file://fedora/gcc43-c++-builtin-redecl.patch;patch=1;pnum=0 \
recipes/gcc/gcc-4.3.2.inc +1 -1
index 5483b8f..8d40d72 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r9"
+INC_PR = "r10"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	file://fedora/gcc43-c++-builtin-redecl.patch;patch=1;pnum=0 \
recipes/gcc/gcc-4.3.3.inc +1 -1
index 46d5e35..47bfbc6 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r10"
+INC_PR = "r11"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	file://fedora/gcc43-c++-builtin-redecl.patch;patch=1;pnum=0 \
recipes/gcc/gcc-4.3.4.inc +1 -1
index 2b1054c..ff02ac5 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r7"
+INC_PR = "r8"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
 	file://fedora/gcc43-c++-builtin-redecl.patch;patch=1;pnum=0 \
recipes/gcc/gcc-4.4.1.inc +1 -1
index 9daff95..cbf28dd 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r7"
+INC_PR = "r8"
 
 FILESPATHPKG .= ":gcc-$PV"
 
recipes/gcc/gcc-4.4.2.inc +1 -1
index 514cc9f..1ef1359 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r0"
+INC_PR = "r1"
 
 FILESPATHPKG .= ":gcc-$PV"
 
recipes/gcc/gcc-common.inc +5 -0
index 6e777e6..97b140c 100644
@@ -15,6 +15,11 @@ def get_gcc_fpu_setting(bb, d):
         return "--with-float=soft"
     return ""
 
+def get_gcc_mips_plt_setting(bb, d):
+    if bb.data.getVar('TARGET_ARCH', d, 1) in [ 'mips', 'mipsel' ] and 'mplt' in bb.data.getVar('DISTRO_FEATURES',d,1).split() :
+        return "--with-mips-plt"
+    return ""
+
 # We really need HOST_SYS here for some packages and TARGET_SYS for others.
 # For now, libgcc is most important so we fix for that - RP.
 SHLIBSDIR = "${STAGING_DIR_TARGET}/shlibs"
recipes/gcc/gcc-configure-common.inc +4 -1
index 8a96326..ee6c0e7 100644
@@ -13,6 +13,8 @@ OBJC_linux-uclibceabi ?= ""
 OBJC_linux-uclibc ?= ""
 OBJC_avr ?= ""
 OBJC_nylon ?= ""
+OBJC_mips ?= ""
+OBJC_mipsel ?= ""
 OBJC ?= ",objc"
 
 # gcc 3.x expects 'f77', 4.0 expects 'f95', 4.1 and 4.2 expect 'fortran'
@@ -36,7 +38,8 @@ EXTRA_OECONF = "${@['--enable-clocale=generic', ''][bb.data.getVar('USE_NLS', d,
                 --program-prefix=${TARGET_PREFIX} \
                 ${EXTRA_OECONF_BASE} \
                 ${EXTRA_OECONF_FPU} \
-                ${EXTRA_OECONF_PATHS}"
+                ${EXTRA_OECONF_PATHS} \
+		${@get_gcc_mips_plt_setting(bb, d)}"
 
 # Build uclibc compilers without cxa_atexit support
 EXTRA_OECONF_append_linux               = " --enable-__cxa_atexit"
recipes/gcc/gcc-cross-initial.inc +2 -1
index a2c4445..2ab1d7f 100644
@@ -16,7 +16,8 @@ EXTRA_OECONF = "--with-local-prefix=${STAGING_DIR_TARGET}${target_prefix} \
 		--program-prefix=${TARGET_PREFIX} \
 		--with-sysroot=${STAGING_DIR_TARGET} \
 		--with-build-sysroot=${STAGING_DIR_TARGET} \
-		${@get_gcc_fpu_setting(bb, d)}"
+		${@get_gcc_fpu_setting(bb, d)} \
+		${@get_gcc_mips_plt_setting(bb, d)}"
 
 do_install () {
 	:
recipes/gcc/gcc-cross-intermediate.inc +0 -0
index ccfa2b4..50792b6 100644

recipes/gcc/gcc-cross-intermediate.inc EXTRA_OECONF = "--with-local-prefix=${STAGING_DIR_TARGET}${target_prefix} \ · line 21

Quoted 9 lines
recipes/gcc/gcc-cross-intermediate.inc +2 -1
@@ -14,7 +14,8 @@ EXTRA_OECONF = "--with-local-prefix=${STAGING_DIR_TARGET}${target_prefix} \
 		--program-prefix=${TARGET_PREFIX} \
 		--with-sysroot=${STAGING_DIR_TARGET} \
 		--with-build-sysroot=${STAGING_DIR_TARGET} \
-		${@get_gcc_fpu_setting(bb, d)}"
+		${@get_gcc_fpu_setting(bb, d)} \
+		${@get_gcc_mips_plt_setting(bb, d)}"
 
 do_stage_append () {
 	# get rid of dummy libc.so

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (Darwin)

iD8DBQFLLz1KMkyGM64RGpERAplFAJ9ob37pjGpL+wgQvDnwrHscz+1/OgCeLBU8 1JNBG1js82rvv8vd0mC9qPk=
=F/BB
-----END PGP SIGNATURE-----

author
#9 lore raw
Quoted 296 lines · Koen Kooi

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Why am I getting these errors:

NOTE: <type 'exceptions.NameError'>:name 'get_gcc_mips_plt_setting' is not defined while evaluating:

when building kernel modules for an arm machine?

Quoted 285 lines · Khem Raj

* Newer gcc (4.4+) has implemented -mplt option to enable PLT and copy relocation extentions of MIPS ABI which makes shared code run a lot faster. This feature is however controlled by DISTRO_FEATURES which should add 'mplt' to DISTRO_FEATURES to enable it.

---

 recipes/gcc/gcc-3.3.4.inc              |    2 +-
 recipes/gcc/gcc-3.4.3.inc              |    2 +-
 recipes/gcc/gcc-3.4.4.inc              |    2 +-
 recipes/gcc/gcc-4.1.0.inc              |    2 +-
 recipes/gcc/gcc-4.1.1.inc              |    2 +-
 recipes/gcc/gcc-4.1.2.inc              |    2 +-
 recipes/gcc/gcc-4.2.2.inc              |    2 +-
 recipes/gcc/gcc-4.2.3.inc              |    2 +-
 recipes/gcc/gcc-4.2.4.inc              |    2 +-
 recipes/gcc/gcc-4.3.1.inc              |    2 +-
 recipes/gcc/gcc-4.3.2.inc              |    2 +-
 recipes/gcc/gcc-4.3.3.inc              |    2 +-
 recipes/gcc/gcc-4.3.4.inc              |    2 +-
 recipes/gcc/gcc-4.4.1.inc              |    2 +-
 recipes/gcc/gcc-4.4.2.inc              |    2 +-

 recipes/gcc/gcc-common.inc             |    5 +++++ recipes/gcc/gcc-configure-common.inc   |    5 ++++- recipes/gcc/gcc-cross-initial.inc      |    3 ++- recipes/gcc/gcc-cross-intermediate.inc |    3 ++-

 19 files changed, 28 insertions(+), 18 deletions(-)
recipes/gcc/gcc-3.3.4.inc +0 -0
index 635e617..a3fbdde 100644
@@ -1,6 +1,6 @@

 require gcc-common.inc

recipes/gcc/gcc-3.3.4.inc +1 -1
-INC_PR = "r10"
+INC_PR = "r11"

 SRC_URI = "${GNU_MIRROR}/gcc/releases/gcc-${PV}/gcc-${PV}.tar.bz2 \
         file://arm-gotoff.dpatch;patch=1;pnum=0 \

recipes/gcc/gcc-3.4.3.inc +0 -0
index 72f9042..febe0fc 100644
@@ -1,6 +1,6 @@

 require gcc-common.inc

recipes/gcc/gcc-3.4.3.inc +1 -1
-INC_PR = "r18"
+INC_PR = "r19"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
         file://gcc34-reverse-compare.patch;patch=1 \

recipes/gcc/gcc-3.4.4.inc +0 -0
index 9a02c5d..b87e1e3 100644
@@ -1,6 +1,6 @@

 require gcc-common.inc

recipes/gcc/gcc-3.4.4.inc +1 -1
-INC_PR = "r14"
+INC_PR = "r15"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
         file://gcc34-reverse-compare.patch;patch=1 \

recipes/gcc/gcc-4.1.0.inc +0 -0
index 7bb1a34..df0ae3f 100644
@@ -1,6 +1,6 @@

 require gcc-common.inc

recipes/gcc/gcc-4.1.0.inc +1 -1
-INC_PR = "r9"
+INC_PR = "r10"

 DEFAULT_PREFERENCE = "-1"

recipes/gcc/gcc-4.1.1.inc +0 -0
index 68323ac..a960b41 100644
@@ -2,7 +2,7 @@ require gcc-common.inc
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.1.1.inc +1 -1
-INC_PR = "r0"
+INC_PR = "r1"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://100-uclibc-conf.patch;patch=1 \

recipes/gcc/gcc-4.1.2.inc +0 -0
index 911d2d9..21bf486 100644
@@ -2,7 +2,7 @@ require gcc-common.inc
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.1.2.inc +1 -1
-INC_PR = "r21"
+INC_PR = "r22"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://100-uclibc-conf.patch;patch=1 \

recipes/gcc/gcc-4.2.2.inc +0 -0
index 0eb1223..931de9a 100644
@@ -3,7 +3,7 @@ LICENSE = "GPLv3"
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.2.2.inc +1 -1
-INC_PR = "r15"
+INC_PR = "r16"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://100-uclibc-conf.patch;patch=1 \

recipes/gcc/gcc-4.2.3.inc +0 -0
index 1501c7e..b2fb029 100644
@@ -3,7 +3,7 @@ LICENSE = "GPLv3"
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.2.3.inc +1 -1
-INC_PR = "r12"
+INC_PR = "r17"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://100-uclibc-conf.patch;patch=1 \

recipes/gcc/gcc-4.2.4.inc +0 -0
index 3249c09..e96122a 100644
@@ -3,7 +3,7 @@ LICENSE = "GPLv3"
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.2.4.inc +1 -1
-INC_PR = "r9"
+INC_PR = "r10"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://100-uclibc-conf.patch;patch=1 \

recipes/gcc/gcc-4.3.1.inc +0 -0
index 0b05f0a..3eaff45 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.3.1.inc +1 -1
-INC_PR = "r19"
+INC_PR = "r20"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://fedora/gcc43-c++-builtin-redecl.patch;patch=1;pnum=0 \

recipes/gcc/gcc-4.3.2.inc +0 -0
index 5483b8f..8d40d72 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.3.2.inc +1 -1
-INC_PR = "r9"
+INC_PR = "r10"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://fedora/gcc43-c++-builtin-redecl.patch;patch=1;pnum=0 \

recipes/gcc/gcc-4.3.3.inc +0 -0
index 46d5e35..47bfbc6 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.3.3.inc +1 -1
-INC_PR = "r10"
+INC_PR = "r11"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://fedora/gcc43-c++-builtin-redecl.patch;patch=1;pnum=0 \

recipes/gcc/gcc-4.3.4.inc +0 -0
index 2b1054c..ff02ac5 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.3.4.inc +1 -1
-INC_PR = "r7"
+INC_PR = "r8"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://fedora/gcc43-c++-builtin-redecl.patch;patch=1;pnum=0 \

recipes/gcc/gcc-4.4.1.inc +0 -0
index 9daff95..cbf28dd 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.4.1.inc +1 -1
-INC_PR = "r7"
+INC_PR = "r8"

 FILESPATHPKG .= ":gcc-$PV"

recipes/gcc/gcc-4.4.2.inc +0 -0
index 514cc9f..1ef1359 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.4.2.inc +1 -1
-INC_PR = "r0"
+INC_PR = "r1"

 FILESPATHPKG .= ":gcc-$PV"

recipes/gcc/gcc-common.inc +0 -0
index 6e777e6..97b140c 100644
@@ -15,6 +15,11 @@ def get_gcc_fpu_setting(bb, d):

         return "--with-float=soft"
     return ""

recipes/gcc/gcc-common.inc +5 -0
+def get_gcc_mips_plt_setting(bb, d):
+    if bb.data.getVar('TARGET_ARCH', d, 1) in [ 'mips', 'mipsel' ] and 'mplt' in bb.data.getVar('DISTRO_FEATURES',d,1).split() :
+        return "--with-mips-plt"
+    return ""
+

 # We really need HOST_SYS here for some packages and TARGET_SYS for others. # For now, libgcc is most important so we fix for that - RP. SHLIBSDIR = "${STAGING_DIR_TARGET}/shlibs"

recipes/gcc/gcc-configure-common.inc +0 -0
index 8a96326..ee6c0e7 100644
@@ -13,6 +13,8 @@ OBJC_linux-uclibceabi ?= ""

 OBJC_linux-uclibc ?= ""
 OBJC_avr ?= ""
 OBJC_nylon ?= ""

recipes/gcc/gcc-configure-common.inc +2 -0
+OBJC_mips ?= ""
+OBJC_mipsel ?= ""

 OBJC ?= ",objc"

 # gcc 3.x expects 'f77', 4.0 expects 'f95', 4.1 and 4.2 expect 'fortran'
recipes/gcc/gcc-configure-common.inc +2 -1
@@ -36,7 +38,8 @@ EXTRA_OECONF = "${@['--enable-clocale=generic', ''][bb.data.getVar('USE_NLS', d,
                  --program-prefix=${TARGET_PREFIX} \
                  ${EXTRA_OECONF_BASE} \
                  ${EXTRA_OECONF_FPU} \
-                ${EXTRA_OECONF_PATHS}"
+                ${EXTRA_OECONF_PATHS} \
+             ${@get_gcc_mips_plt_setting(bb, d)}"
 
  # Build uclibc compilers without cxa_atexit support

 EXTRA_OECONF_append_linux               = " --enable-__cxa_atexit"

recipes/gcc/gcc-cross-initial.inc +2 -1
index a2c4445..2ab1d7f 100644
@@ -16,7 +16,8 @@ EXTRA_OECONF = "--with-local-prefix=${STAGING_DIR_TARGET}${target_prefix} \
               --program-prefix=${TARGET_PREFIX} \
               --with-sysroot=${STAGING_DIR_TARGET} \
               --with-build-sysroot=${STAGING_DIR_TARGET} \
-             ${@get_gcc_fpu_setting(bb, d)}"
+             ${@get_gcc_fpu_setting(bb, d)} \
+             ${@get_gcc_mips_plt_setting(bb, d)}"
 
  do_install () {

      :

recipes/gcc/gcc-cross-intermediate.inc +2 -1
index ccfa2b4..50792b6 100644
@@ -14,7 +14,8 @@ EXTRA_OECONF = "--with-local-prefix=${STAGING_DIR_TARGET}${target_prefix} \
               --program-prefix=${TARGET_PREFIX} \
               --with-sysroot=${STAGING_DIR_TARGET} \
               --with-build-sysroot=${STAGING_DIR_TARGET} \
-             ${@get_gcc_fpu_setting(bb, d)}"
+             ${@get_gcc_fpu_setting(bb, d)} \
+             ${@get_gcc_mips_plt_setting(bb, d)}"
 
Quoted 2 lines

recipes/gcc/gcc-cross-intermediate.inc EXTRA_OECONF = "--with-local-prefix=${STAGING_DIR_TARGET}${target_prefix} \ · line 21

Quoted 2 lines
recipes/gcc/gcc-cross-intermediate.inc +0 -0
  do_stage_append () {
       # get rid of dummy libc.so

I did an arm build earlier and did not see this message at all. which gcc version are you building ? my guess is that some version does not include gcc-common.inc thats one reason it can happen

Thanks

-Khem

#10 lore raw

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 297 lines · Khem Raj
Quoted 296 lines · Koen Kooi

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Why am I getting these errors:

NOTE: <type 'exceptions.NameError'>:name 'get_gcc_mips_plt_setting' is not defined while evaluating:

when building kernel modules for an arm machine?

Quoted 285 lines · Khem Raj

* Newer gcc (4.4+) has implemented -mplt option to enable PLT and copy relocation extentions of MIPS ABI which makes shared code run a lot faster. This feature is however controlled by DISTRO_FEATURES which should add 'mplt' to DISTRO_FEATURES to enable it.

---
 recipes/gcc/gcc-3.3.4.inc              |    2 +-
 recipes/gcc/gcc-3.4.3.inc              |    2 +-
 recipes/gcc/gcc-3.4.4.inc              |    2 +-
 recipes/gcc/gcc-4.1.0.inc              |    2 +-
 recipes/gcc/gcc-4.1.1.inc              |    2 +-
 recipes/gcc/gcc-4.1.2.inc              |    2 +-
 recipes/gcc/gcc-4.2.2.inc              |    2 +-
 recipes/gcc/gcc-4.2.3.inc              |    2 +-
 recipes/gcc/gcc-4.2.4.inc              |    2 +-
 recipes/gcc/gcc-4.3.1.inc              |    2 +-
 recipes/gcc/gcc-4.3.2.inc              |    2 +-
 recipes/gcc/gcc-4.3.3.inc              |    2 +-
 recipes/gcc/gcc-4.3.4.inc              |    2 +-
 recipes/gcc/gcc-4.4.1.inc              |    2 +-
 recipes/gcc/gcc-4.4.2.inc              |    2 +-
 recipes/gcc/gcc-common.inc             |    5 +++++
 recipes/gcc/gcc-configure-common.inc   |    5 ++++-
 recipes/gcc/gcc-cross-initial.inc      |    3 ++-
 recipes/gcc/gcc-cross-intermediate.inc |    3 ++-
 19 files changed, 28 insertions(+), 18 deletions(-)
recipes/gcc/gcc-3.3.4.inc +1 -1
index 635e617..a3fbdde 100644
@@ -1,6 +1,6 @@
 require gcc-common.inc
 
-INC_PR = "r10"
+INC_PR = "r11"
 
 SRC_URI = "${GNU_MIRROR}/gcc/releases/gcc-${PV}/gcc-${PV}.tar.bz2 \
         file://arm-gotoff.dpatch;patch=1;pnum=0 \
recipes/gcc/gcc-3.4.3.inc +1 -1
index 72f9042..febe0fc 100644
@@ -1,6 +1,6 @@
 require gcc-common.inc
 
-INC_PR = "r18"
+INC_PR = "r19"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
         file://gcc34-reverse-compare.patch;patch=1 \
recipes/gcc/gcc-3.4.4.inc +1 -1
index 9a02c5d..b87e1e3 100644
@@ -1,6 +1,6 @@
 require gcc-common.inc
 
-INC_PR = "r14"
+INC_PR = "r15"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
         file://gcc34-reverse-compare.patch;patch=1 \
recipes/gcc/gcc-4.1.0.inc +1 -1
index 7bb1a34..df0ae3f 100644
@@ -1,6 +1,6 @@
 require gcc-common.inc
 
-INC_PR = "r9"
+INC_PR = "r10"
 
 DEFAULT_PREFERENCE = "-1"
 
recipes/gcc/gcc-4.1.1.inc +1 -1
index 68323ac..a960b41 100644
@@ -2,7 +2,7 @@ require gcc-common.inc
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r0"
+INC_PR = "r1"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://100-uclibc-conf.patch;patch=1 \
recipes/gcc/gcc-4.1.2.inc +1 -1
index 911d2d9..21bf486 100644
@@ -2,7 +2,7 @@ require gcc-common.inc
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r21"
+INC_PR = "r22"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://100-uclibc-conf.patch;patch=1 \
recipes/gcc/gcc-4.2.2.inc +1 -1
index 0eb1223..931de9a 100644
@@ -3,7 +3,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r15"
+INC_PR = "r16"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://100-uclibc-conf.patch;patch=1 \
recipes/gcc/gcc-4.2.3.inc +1 -1
index 1501c7e..b2fb029 100644
@@ -3,7 +3,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r12"
+INC_PR = "r17"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://100-uclibc-conf.patch;patch=1 \
recipes/gcc/gcc-4.2.4.inc +1 -1
index 3249c09..e96122a 100644
@@ -3,7 +3,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r9"
+INC_PR = "r10"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://100-uclibc-conf.patch;patch=1 \
recipes/gcc/gcc-4.3.1.inc +1 -1
index 0b05f0a..3eaff45 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r19"
+INC_PR = "r20"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://fedora/gcc43-c++-builtin-redecl.patch;patch=1;pnum=0 \
recipes/gcc/gcc-4.3.2.inc +1 -1
index 5483b8f..8d40d72 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r9"
+INC_PR = "r10"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://fedora/gcc43-c++-builtin-redecl.patch;patch=1;pnum=0 \
recipes/gcc/gcc-4.3.3.inc +1 -1
index 46d5e35..47bfbc6 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r10"
+INC_PR = "r11"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://fedora/gcc43-c++-builtin-redecl.patch;patch=1;pnum=0 \
recipes/gcc/gcc-4.3.4.inc +1 -1
index 2b1054c..ff02ac5 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r7"
+INC_PR = "r8"
 
 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://fedora/gcc43-c++-builtin-redecl.patch;patch=1;pnum=0 \
recipes/gcc/gcc-4.4.1.inc +1 -1
index 9daff95..cbf28dd 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r7"
+INC_PR = "r8"
 
 FILESPATHPKG .= ":gcc-$PV"
 
recipes/gcc/gcc-4.4.2.inc +1 -1
index 514cc9f..1ef1359 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 
 DEPENDS = "mpfr gmp"
 
-INC_PR = "r0"
+INC_PR = "r1"
 
 FILESPATHPKG .= ":gcc-$PV"
 
recipes/gcc/gcc-common.inc +5 -0
index 6e777e6..97b140c 100644
@@ -15,6 +15,11 @@ def get_gcc_fpu_setting(bb, d):
         return "--with-float=soft"
     return ""
 
+def get_gcc_mips_plt_setting(bb, d):
+    if bb.data.getVar('TARGET_ARCH', d, 1) in [ 'mips', 'mipsel' ] and 'mplt' in bb.data.getVar('DISTRO_FEATURES',d,1).split() :
+        return "--with-mips-plt"
+    return ""
+
 # We really need HOST_SYS here for some packages and TARGET_SYS for others.
 # For now, libgcc is most important so we fix for that - RP.
 SHLIBSDIR = "${STAGING_DIR_TARGET}/shlibs"
recipes/gcc/gcc-configure-common.inc +4 -1
index 8a96326..ee6c0e7 100644
@@ -13,6 +13,8 @@ OBJC_linux-uclibceabi ?= ""
 OBJC_linux-uclibc ?= ""
 OBJC_avr ?= ""
 OBJC_nylon ?= ""
+OBJC_mips ?= ""
+OBJC_mipsel ?= ""
 OBJC ?= ",objc"
 
 # gcc 3.x expects 'f77', 4.0 expects 'f95', 4.1 and 4.2 expect 'fortran'
@@ -36,7 +38,8 @@ EXTRA_OECONF = "${@['--enable-clocale=generic', ''][bb.data.getVar('USE_NLS', d,
                 --program-prefix=${TARGET_PREFIX} \
                 ${EXTRA_OECONF_BASE} \
                 ${EXTRA_OECONF_FPU} \
-                ${EXTRA_OECONF_PATHS}"
+                ${EXTRA_OECONF_PATHS} \
+             ${@get_gcc_mips_plt_setting(bb, d)}"
 
 # Build uclibc compilers without cxa_atexit support
 EXTRA_OECONF_append_linux               = " --enable-__cxa_atexit"
recipes/gcc/gcc-cross-initial.inc +2 -1
index a2c4445..2ab1d7f 100644
@@ -16,7 +16,8 @@ EXTRA_OECONF = "--with-local-prefix=${STAGING_DIR_TARGET}${target_prefix} \
              --program-prefix=${TARGET_PREFIX} \
              --with-sysroot=${STAGING_DIR_TARGET} \
              --with-build-sysroot=${STAGING_DIR_TARGET} \
-             ${@get_gcc_fpu_setting(bb, d)}"
+             ${@get_gcc_fpu_setting(bb, d)} \
+             ${@get_gcc_mips_plt_setting(bb, d)}"
 
 do_install () {
      :
recipes/gcc/gcc-cross-intermediate.inc +2 -1
index ccfa2b4..50792b6 100644
@@ -14,7 +14,8 @@ EXTRA_OECONF = "--with-local-prefix=${STAGING_DIR_TARGET}${target_prefix} \
              --program-prefix=${TARGET_PREFIX} \
              --with-sysroot=${STAGING_DIR_TARGET} \
              --with-build-sysroot=${STAGING_DIR_TARGET} \
-             ${@get_gcc_fpu_setting(bb, d)}"
+             ${@get_gcc_fpu_setting(bb, d)} \
+             ${@get_gcc_mips_plt_setting(bb, d)}"
 
Quoted 6 lines
Quoted 2 lines

recipes/gcc/gcc-cross-intermediate.inc EXTRA_OECONF = "--with-local-prefix=${STAGING_DIR_TARGET}${target_prefix} \ · line 21

Quoted 2 lines
recipes/gcc/gcc-cross-intermediate.inc +0 -0
 do_stage_append () {
      # get rid of dummy libc.so

I did an arm build earlier and did not see this message at all. which gcc version are you building ? my guess is that some version does not include gcc-common.inc thats one reason it can happen

So you mean you broke gcc 4.3.3...
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (Darwin)

iD8DBQFLL5cIMkyGM64RGpERAgcMAKC50t+0uY87sloRWJ9azphpuAa0SQCgvDsf JtckYxcIzz9Cz1yr/NUo0j4=
=t3de
-----END PGP SIGNATURE-----

author
#11 lore raw
Quoted 301 lines · Koen Kooi

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 297 lines · Khem Raj
Quoted 296 lines · Koen Kooi

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Why am I getting these errors:

NOTE: <type 'exceptions.NameError'>:name 'get_gcc_mips_plt_setting' is not defined while evaluating:

when building kernel modules for an arm machine?

Quoted 285 lines · Khem Raj

* Newer gcc (4.4+) has implemented -mplt option to enable PLT and copy relocation extentions of MIPS ABI which makes shared code run a lot faster. This feature is however controlled by DISTRO_FEATURES which should add 'mplt' to DISTRO_FEATURES to enable it.

---

 recipes/gcc/gcc-3.3.4.inc              |    2 +-
 recipes/gcc/gcc-3.4.3.inc              |    2 +-
 recipes/gcc/gcc-3.4.4.inc              |    2 +-
 recipes/gcc/gcc-4.1.0.inc              |    2 +-
 recipes/gcc/gcc-4.1.1.inc              |    2 +-
 recipes/gcc/gcc-4.1.2.inc              |    2 +-
 recipes/gcc/gcc-4.2.2.inc              |    2 +-
 recipes/gcc/gcc-4.2.3.inc              |    2 +-
 recipes/gcc/gcc-4.2.4.inc              |    2 +-
 recipes/gcc/gcc-4.3.1.inc              |    2 +-
 recipes/gcc/gcc-4.3.2.inc              |    2 +-
 recipes/gcc/gcc-4.3.3.inc              |    2 +-
 recipes/gcc/gcc-4.3.4.inc              |    2 +-
 recipes/gcc/gcc-4.4.1.inc              |    2 +-
 recipes/gcc/gcc-4.4.2.inc              |    2 +-

 recipes/gcc/gcc-common.inc             |    5 +++++ recipes/gcc/gcc-configure-common.inc   |    5 ++++- recipes/gcc/gcc-cross-initial.inc      |    3 ++- recipes/gcc/gcc-cross-intermediate.inc |    3 ++-

 19 files changed, 28 insertions(+), 18 deletions(-)
recipes/gcc/gcc-3.3.4.inc +0 -0
index 635e617..a3fbdde 100644
@@ -1,6 +1,6 @@

 require gcc-common.inc

recipes/gcc/gcc-3.3.4.inc +1 -1
-INC_PR = "r10"
+INC_PR = "r11"

 SRC_URI = "${GNU_MIRROR}/gcc/releases/gcc-${PV}/gcc-${PV}.tar.bz2 \
         file://arm-gotoff.dpatch;patch=1;pnum=0 \

recipes/gcc/gcc-3.4.3.inc +0 -0
index 72f9042..febe0fc 100644
@@ -1,6 +1,6 @@

 require gcc-common.inc

recipes/gcc/gcc-3.4.3.inc +1 -1
-INC_PR = "r18"
+INC_PR = "r19"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
         file://gcc34-reverse-compare.patch;patch=1 \

recipes/gcc/gcc-3.4.4.inc +0 -0
index 9a02c5d..b87e1e3 100644
@@ -1,6 +1,6 @@

 require gcc-common.inc

recipes/gcc/gcc-3.4.4.inc +1 -1
-INC_PR = "r14"
+INC_PR = "r15"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
         file://gcc34-reverse-compare.patch;patch=1 \

recipes/gcc/gcc-4.1.0.inc +0 -0
index 7bb1a34..df0ae3f 100644
@@ -1,6 +1,6 @@

 require gcc-common.inc

recipes/gcc/gcc-4.1.0.inc +1 -1
-INC_PR = "r9"
+INC_PR = "r10"

 DEFAULT_PREFERENCE = "-1"

recipes/gcc/gcc-4.1.1.inc +0 -0
index 68323ac..a960b41 100644
@@ -2,7 +2,7 @@ require gcc-common.inc
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.1.1.inc +1 -1
-INC_PR = "r0"
+INC_PR = "r1"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://100-uclibc-conf.patch;patch=1 \

recipes/gcc/gcc-4.1.2.inc +0 -0
index 911d2d9..21bf486 100644
@@ -2,7 +2,7 @@ require gcc-common.inc
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.1.2.inc +1 -1
-INC_PR = "r21"
+INC_PR = "r22"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://100-uclibc-conf.patch;patch=1 \

recipes/gcc/gcc-4.2.2.inc +0 -0
index 0eb1223..931de9a 100644
@@ -3,7 +3,7 @@ LICENSE = "GPLv3"
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.2.2.inc +1 -1
-INC_PR = "r15"
+INC_PR = "r16"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://100-uclibc-conf.patch;patch=1 \

recipes/gcc/gcc-4.2.3.inc +0 -0
index 1501c7e..b2fb029 100644
@@ -3,7 +3,7 @@ LICENSE = "GPLv3"
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.2.3.inc +1 -1
-INC_PR = "r12"
+INC_PR = "r17"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://100-uclibc-conf.patch;patch=1 \

recipes/gcc/gcc-4.2.4.inc +0 -0
index 3249c09..e96122a 100644
@@ -3,7 +3,7 @@ LICENSE = "GPLv3"
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.2.4.inc +1 -1
-INC_PR = "r9"
+INC_PR = "r10"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://100-uclibc-conf.patch;patch=1 \

recipes/gcc/gcc-4.3.1.inc +0 -0
index 0b05f0a..3eaff45 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.3.1.inc +1 -1
-INC_PR = "r19"
+INC_PR = "r20"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://fedora/gcc43-c++-builtin-redecl.patch;patch=1;pnum=0 \

recipes/gcc/gcc-4.3.2.inc +0 -0
index 5483b8f..8d40d72 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.3.2.inc +1 -1
-INC_PR = "r9"
+INC_PR = "r10"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://fedora/gcc43-c++-builtin-redecl.patch;patch=1;pnum=0 \

recipes/gcc/gcc-4.3.3.inc +0 -0
index 46d5e35..47bfbc6 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.3.3.inc +1 -1
-INC_PR = "r10"
+INC_PR = "r11"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://fedora/gcc43-c++-builtin-redecl.patch;patch=1;pnum=0 \

recipes/gcc/gcc-4.3.4.inc +0 -0
index 2b1054c..ff02ac5 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.3.4.inc +1 -1
-INC_PR = "r7"
+INC_PR = "r8"

 SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
      file://fedora/gcc43-c++-builtin-redecl.patch;patch=1;pnum=0 \

recipes/gcc/gcc-4.4.1.inc +0 -0
index 9daff95..cbf28dd 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.4.1.inc +1 -1
-INC_PR = "r7"
+INC_PR = "r8"

 FILESPATHPKG .= ":gcc-$PV"

recipes/gcc/gcc-4.4.2.inc +0 -0
index 514cc9f..1ef1359 100644
@@ -7,7 +7,7 @@ LICENSE = "GPLv3"
 

 DEPENDS = "mpfr gmp"

recipes/gcc/gcc-4.4.2.inc +1 -1
-INC_PR = "r0"
+INC_PR = "r1"

 FILESPATHPKG .= ":gcc-$PV"

recipes/gcc/gcc-common.inc +0 -0
index 6e777e6..97b140c 100644
@@ -15,6 +15,11 @@ def get_gcc_fpu_setting(bb, d):

         return "--with-float=soft"
     return ""

recipes/gcc/gcc-common.inc +5 -0
+def get_gcc_mips_plt_setting(bb, d):
+    if bb.data.getVar('TARGET_ARCH', d, 1) in [ 'mips', 'mipsel' ] and 'mplt' in bb.data.getVar('DISTRO_FEATURES',d,1).split() :
+        return "--with-mips-plt"
+    return ""
+

 # We really need HOST_SYS here for some packages and TARGET_SYS for others. # For now, libgcc is most important so we fix for that - RP. SHLIBSDIR = "${STAGING_DIR_TARGET}/shlibs"

recipes/gcc/gcc-configure-common.inc +0 -0
index 8a96326..ee6c0e7 100644
@@ -13,6 +13,8 @@ OBJC_linux-uclibceabi ?= ""

 OBJC_linux-uclibc ?= ""
 OBJC_avr ?= ""
 OBJC_nylon ?= ""

recipes/gcc/gcc-configure-common.inc +2 -0
+OBJC_mips ?= ""
+OBJC_mipsel ?= ""

 OBJC ?= ",objc"

 # gcc 3.x expects 'f77', 4.0 expects 'f95', 4.1 and 4.2 expect 'fortran'
recipes/gcc/gcc-configure-common.inc +2 -1
@@ -36,7 +38,8 @@ EXTRA_OECONF = "${@['--enable-clocale=generic', ''][bb.data.getVar('USE_NLS', d,
                  --program-prefix=${TARGET_PREFIX} \
                  ${EXTRA_OECONF_BASE} \
                  ${EXTRA_OECONF_FPU} \
-                ${EXTRA_OECONF_PATHS}"
+                ${EXTRA_OECONF_PATHS} \
+             ${@get_gcc_mips_plt_setting(bb, d)}"
 
  # Build uclibc compilers without cxa_atexit support

 EXTRA_OECONF_append_linux               = " --enable-__cxa_atexit"

recipes/gcc/gcc-cross-initial.inc +2 -1
index a2c4445..2ab1d7f 100644
@@ -16,7 +16,8 @@ EXTRA_OECONF = "--with-local-prefix=${STAGING_DIR_TARGET}${target_prefix} \
               --program-prefix=${TARGET_PREFIX} \
               --with-sysroot=${STAGING_DIR_TARGET} \
               --with-build-sysroot=${STAGING_DIR_TARGET} \
-             ${@get_gcc_fpu_setting(bb, d)}"
+             ${@get_gcc_fpu_setting(bb, d)} \
+             ${@get_gcc_mips_plt_setting(bb, d)}"
 
  do_install () {

      :

recipes/gcc/gcc-cross-intermediate.inc +2 -1
index ccfa2b4..50792b6 100644
@@ -14,7 +14,8 @@ EXTRA_OECONF = "--with-local-prefix=${STAGING_DIR_TARGET}${target_prefix} \
               --program-prefix=${TARGET_PREFIX} \
               --with-sysroot=${STAGING_DIR_TARGET} \
               --with-build-sysroot=${STAGING_DIR_TARGET} \
-             ${@get_gcc_fpu_setting(bb, d)}"
+             ${@get_gcc_fpu_setting(bb, d)} \
+             ${@get_gcc_mips_plt_setting(bb, d)}"
 
Quoted 8 lines
Quoted 6 lines
Quoted 2 lines

recipes/gcc/gcc-cross-intermediate.inc EXTRA_OECONF = "--with-local-prefix=${STAGING_DIR_TARGET}${target_prefix} \ · line 21

Quoted 2 lines
recipes/gcc/gcc-cross-intermediate.inc +0 -0
  do_stage_append () {
       # get rid of dummy libc.so

I did an arm build earlier and did not see this message at all. which gcc version are you building ? my guess is that some version does not include gcc-common.inc thats one reason it can happen

So you mean you broke gcc 4.3.3...

eh not intentionally if its so... :)

gcc 4.3.3 recipes include gcc-common.inc so it should get the function defined. I did not test it 4.3.3, but only with gcc 4.4 and 4.2 I will give it a shot in the next run and see if I can reproduce it.

Quoted 14 lines

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (Darwin)

iD8DBQFLL5cIMkyGM64RGpERAgcMAKC50t+0uY87sloRWJ9azphpuAa0SQCgvDsf JtckYxcIzz9Cz1yr/NUo0j4=
=t3de
-----END PGP SIGNATURE-----

_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel