Skip to contentSkip to conversation

packages/dmraid: mark as broken on nios2, _gp2 issue

PATCH New Brendan Heading 2 participants 3 messages Jul 27, 2015

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 packages/dmraid: mark as broken on nios2, _gp2 issue

Investigation of nios2 config.log shows that this is caused by the "infamous" _gp2 link issue on codesourcery toolchains:

/home/bheading/dev/fix-dmraid/buildroot/output/host/opt/ext-toolchain/bin/../lib/gcc/nios2-linux-gnu/4.8.3/../../../../nios2-linux-gnu/bin/ld: /home/bheading/dev/fix-dmraid/buildroot/output/host/usr/nios2-buildroot-linux-gnu/sysroot/usr/lib/crt1.o: undefined reference to symbol '_gp' /home/bheading/dev/fix-dmraid/buildroot/output/host/usr/nios2-buildroot-linux-gnu/sysroot/usr/lib/libdevmapper.so.1.02: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status

As with other cases, fixed by disabling this package when codesourcery toolchains are in use.

---
 package/dmraid/Config.in | 6 ++++++
 1 file changed, 6 insertions(+)
package/dmraid/Config.in +6 -0
index 4a8cf61..ec50670 100644
@@ -3,6 +3,9 @@ config BR2_PACKAGE_DMRAID
 	depends on BR2_TOOLCHAIN_HAS_THREADS # lvm2
 	depends on BR2_USE_MMU # lvm2
 	depends on !BR2_STATIC_LIBS # lvm2
+	# dmraid triggers the _gp link issue
+	depends on !BR2_TOOLCHAIN_EXTERNAL_CODESOURCERY_NIOSII201305
+	depends on !BR2_TOOLCHAIN_EXTERNAL_CODESOURCERY_NIOSII201405
 	select BR2_PACKAGE_LVM2
 	help
 	  dmraid discovers, activates, deactivates and displays properties
@@ -13,4 +16,7 @@ config BR2_PACKAGE_DMRAID
 
 comment "dmraid needs a toolchain w/ threads, dynamic library"
 	depends on BR2_USE_MMU
+	# dmraid triggers the _gp link issue
+	depends on !BR2_TOOLCHAIN_EXTERNAL_CODESOURCERY_NIOSII201305
+	depends on !BR2_TOOLCHAIN_EXTERNAL_CODESOURCERY_NIOSII201405
 	depends on BR2_STATIC_LIBS || !BR2_TOOLCHAIN_HAS_THREADS
Signature · 1 line
2.4.3
#1 lore raw

PATCH 1/1 packages/dmraid: mark as broken on nios2, _gp2 issue

Dear Brendan Heading,

In the title:

	_gp2 -> _gp

The patch doesn't mark dmraid as broken on NIOS II, it only excludes some toolchains, so I changed the title to:

dmraid: exclude nios2 sourcery toolchains, _gp issue

Quoted 4 lines · Brendan Heading

Investigation of nios2 config.log shows that this is caused by the "infamous" _gp2 link issue on codesourcery toolchains:

	_gp
Quoted 3 lines

/home/bheading/dev/fix-dmraid/buildroot/output/host/opt/ext-toolchain/bin/../lib/gcc/nios2-linux-gnu/4.8.3/../../../../nios2-linux-gnu/bin/ld: /home/bheading/dev/fix-dmraid/buildroot/output/host/usr/nios2-buildroot-linux-gnu/sysroot/usr/lib/crt1.o: undefined reference to symbol '_gp' /home/bheading/dev/fix-dmraid/buildroot/output/host/usr/nios2-buildroot-linux-gnu/sysroot/usr/lib/libdevmapper.so.1.02: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status

Instead of these errors where you reproduced locally, I instead used the error visible in the autobuilders. Maybe you didn't know that, but the config.log is also available in the autobuilders. For this build, it is available at:

http://autobuild.buildroot.net/results/a7e/a7e2631d06634d768faf5c1d02712cc9b38562c6/dmraid-1.0.0.rc16-3/1.0.0.rc16-3/dmraid/config.log

Basically, for every build, all config.log files are saved. You can access them by going into the directory of the build result:

http://autobuild.buildroot.net/results/a7e/a7e2631d06634d768faf5c1d02712cc9b38562c6/

and then the subdirectory named after the package for which the build failed.

Applied with those changes, thanks!

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
#2 lore raw

PATCH 1/1 packages/dmraid: mark as broken on nios2, _gp2 issue

Quoted 6 lines

and then the subdirectory named after the package for which the build failed.

Applied with those changes, thanks!

Thanks for the support and endless patience Thomas :)

regards

Brendan

Quoted 7 lines

Thomas
--
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20150727/8aa14285/attachment.html>