Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] install-to-staging OK but install-to-target fails
@ 2012-02-02 20:04 Endejan, Edward
  2012-02-02 20:36 ` Peter Korsgaard
  0 siblings, 1 reply; 5+ messages in thread
From: Endejan, Edward @ 2012-02-02 20:04 UTC (permalink / raw)
  To: buildroot

Hi,

I'm attempting to build gstreamer and gst-plugins-base from git 
repositories with buildroot, cross-compiling for ARM. The build 
and install-to-staging phases complete without error, but then 
install-to-target fails as follows:

libtool: install: warning: relinking `libgstbase-0.10.la'
libtool: install: (cd /home/ee/prj/buildroot/output/build/gstreamer-b64067f96110edccc73110a4ef4e6a7c6fac195d/libs/gst/base; /bin/bash /home/ee/prj/buildroot/output/build/gstreamer-b64067f96110edccc73110a4ef4e6a7c6fac195d/libtool  --silent --tag CC --mode=relink /home/ee/prj/buildroot/output/host/usr/bin/ccache /home/ee/prj/buildroot/output/host/usr/bin/arm-unknown-linux-uclibcgnueabi-gcc -std=gnu99 -I../../../libs -I../../.. -I../../../libs -I../../.. -pthread -I/home/ee/prj/buildroot/output/host/usr/arm-unknown-linux-uclibcgnueabi/sysroot/usr/include/glib-2.0 -I/home/ee/prj/buildroot/output/host/usr/arm-unknown-linux-uclibcgnueabi/sysroot/usr/lib/glib-2.0/include -DG_THREADS_MANDATORY -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT -Wall -Wdeclaration-after-statement -Wvla -Wpointer-arith -Wmissing-declarations -Wmissing-prototypes -Wredundant-decls -Wundef -Wwrite-strings -Wformat-nonliteral -Wformat-security -Wold-style-definition -Winit-self -Wmissing-include-dirs -Waddress -Waggregate-return -Wno-multichar -Wnested-externs -g -Os -pipe -march=armv7-a -mtune=cortex-a8 -mfpu=neon -ftree-vectorize -mfloat-abi=softfp -Os -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -export-symbols-regex "^_*(gst_|Gst|GST_).*" -no-undefined -Wl,-Bsymbolic-functions -version-info 30:0:30 -o libgstbase-0.10.la -rpath /usr/lib libgstbase_0.10_la-gstadapter.lo libgstbase_0.10_la-gstbaseparse.lo libgstbase_0.10_la-gstbasesink.lo libgstbase_0.10_la-gstbasesrc.lo libgstbase_0.10_la-gstbasetransform.lo libgstbase_0.10_la-gstbitreader.lo libgstbase_0.10_la-gstbytereader.lo libgstbase_0.10_la-gstbytewriter.lo libgstbase_0.10_la-gstcollectpads.lo libgstbase_0.10_la-gstcollectpads2.lo libgstbase_0.10_la-gstpushsrc.lo libgstbase_0.10_la-gsttypefindhelper.lo libgstbase_0.10_la-gstdataqueue.lo ../../../gst/libgstreamer-0.10.la -pthread -lgobject-2.0 -lgthread-2.0 -lgmodule-2.0 -lglib-2.0 -lintl -ldl -inst-prefix-dir /home/ee/prj/buildroot/output/target)
/usr/lib/libdl.so: file not recognized: File format not recognized
collect2: ld returned 1 exit status
libtool: install: error: relink `libgstbase-0.10.la' with the above command before installing it
make[5]: *** [install-libLTLIBRARIES] Error 1

The error is due to an attempted re-link against libraries upon 
which this library depends, but the library format is invalid 
since in this phase the host machine libraries (x86) are being 
found rather than the target machine libraries (ARM). The 
command lines for the install-to-staging and install-to-target 
phases are almost identical with the exception of this path 
argument:

-inst-prefix-dir for install-to-staging:
/home/ee/prj/buildroot/output/host/usr/arm-unknown-linux-uclibcgnueabi/sysroot

-inst-prefix-dir install-to-target:
/home/ee/prj/buildroot/output/target

But these paths _should_ be different.

All I can figure is that one or more *.la files are different 
between the two phases, but I'm not sure why.

Can someone give me a hint as to what I am doing wrong and why 
install-to-staging succeeds while install-to-target fails?

Thanks for any hints or help you can provide.

Best Regards,
Ed

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Buildroot] install-to-staging OK but install-to-target fails
  2012-02-02 20:04 [Buildroot] install-to-staging OK but install-to-target fails Endejan, Edward
@ 2012-02-02 20:36 ` Peter Korsgaard
  2012-02-03  2:38   ` Endejan, Edward
  0 siblings, 1 reply; 5+ messages in thread
From: Peter Korsgaard @ 2012-02-02 20:36 UTC (permalink / raw)
  To: buildroot

>>>>> "Edward" == Endejan, Edward <Edward.Endejan@dmh-global.com> writes:

 Edward> Hi,
 Edward> I'm attempting to build gstreamer and gst-plugins-base from git 
 Edward> repositories with buildroot, cross-compiling for ARM. The build 
 Edward> and install-to-staging phases complete without error, but then 
 Edward> install-to-target fails as follows:

It works here. Care to post your buildroot defconfig (run make
savedefconfig to create it).

-- 
Bye, Peter Korsgaard

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Buildroot] install-to-staging OK but install-to-target fails
  2012-02-02 20:36 ` Peter Korsgaard
@ 2012-02-03  2:38   ` Endejan, Edward
  2012-02-03  7:00     ` Peter Korsgaard
  0 siblings, 1 reply; 5+ messages in thread
From: Endejan, Edward @ 2012-02-03  2:38 UTC (permalink / raw)
  To: buildroot

Hi Peter,

Thanks for the quick response. Our corporate internet connection went down this afternoon so we were pretty much dead in the water for the rest of the workday. Luckily we have a web interface to our cloud-hosted email so I saw your response tonight from home.

Assuming our connection is restored by tomorrow, I'll get the defconfig to you. Is doing a 'make savedefconfig' any different than just sending the .config file from the base directory of buildroot?

A couple of other details in case they are relevant ...

We were able to successfully build these GStreamer libraries with the original .mk files included with buildroot, but they were using .tar.gz snapshots rather than fetching the source using git. We want to convert to using the git approach so that we can easily push modifications to their source code back to that project.

We have cloned the GStreamer git repositories that we are using to a local git server so that we have them local and for faster, uninterrupted access. We have modified these .mk files to use git instead and to fetch from our local repository of clones. As another side-effect of this we added a pre-configure hook to run their autogen.sh script because the GStreamer project uses this approach rather than the standard buildroot autotools configuration approach. The .tar.gz snapshots include pre-built .configure files - the git clone versions do not. I'll send you the modified .mk files so that you have the whole picture, but they will have to be modified to point to the cgit.freedesktop.org git repositories before they will work for you.

If there are other methods or tips you can offer to help me debug this myself, that would be appreciated.

I thought the symptoms of this problem might sound familiar to someone on the list that could point me in the right direction.

Thanks,
Ed

P.S. A colleague of mine thought this might be related/caused by a missing --sysroot parameter somewhere on the command line. I'll ask him for more specifics and investigate that angle myself as well.

________________________________________
From: Peter Korsgaard [jacmet at gmail.com] On Behalf Of Peter Korsgaard [jacmet at uclibc.org]
Sent: Thursday, February 02, 2012 3:36 PM
To: Endejan, Edward
Cc: buildroot at busybox.net
Subject: Re: install-to-staging OK but install-to-target fails

>>>>> "Edward" == Endejan, Edward <Edward.Endejan@dmh-global.com> writes:

 Edward> Hi,
 Edward> I'm attempting to build gstreamer and gst-plugins-base from git
 Edward> repositories with buildroot, cross-compiling for ARM. The build
 Edward> and install-to-staging phases complete without error, but then
 Edward> install-to-target fails as follows:

It works here. Care to post your buildroot defconfig (run make
savedefconfig to create it).

--
Bye, Peter Korsgaard

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Buildroot] install-to-staging OK but install-to-target fails
  2012-02-03  2:38   ` Endejan, Edward
@ 2012-02-03  7:00     ` Peter Korsgaard
  2012-02-03 22:27       ` Endejan, Edward
  0 siblings, 1 reply; 5+ messages in thread
From: Peter Korsgaard @ 2012-02-03  7:00 UTC (permalink / raw)
  To: buildroot

>>>>> "Edward" == Endejan, Edward <Edward.Endejan@dmh-global.com> writes:

Hi,


 Edward> Thanks for the quick response. Our corporate internet
 Edward> connection went down this afternoon so we were pretty much dead
 Edward> in the water for the rest of the workday. Luckily we have a web
 Edward> interface to our cloud-hosted email so I saw your response
 Edward> tonight from home.

 Edward> Assuming our connection is restored by tomorrow, I'll get the
 Edward> defconfig to you. Is doing a 'make savedefconfig' any different
 Edward> than just sending the .config file from the base directory of
 Edward> buildroot?

Great. It contains the same info, but it's easier to look at as it only
shows the options you have changed from the details.

 Edward> A couple of other details in case they are relevant ...

 Edward> We were able to successfully build these GStreamer libraries
 Edward> with the original .mk files included with buildroot, but they
 Edward> were using .tar.gz snapshots rather than fetching the source
 Edward> using git. We want to convert to using the git approach so that
 Edward> we can easily push modifications to their source code back to
 Edward> that project.

Ok.

 Edward> We have cloned the GStreamer git repositories that we are using
 Edward> to a local git server so that we have them local and for
 Edward> faster, uninterrupted access. We have modified these .mk files
 Edward> to use git instead and to fetch from our local repository of
 Edward> clones. As another side-effect of this we added a pre-configure
 Edward> hook to run their autogen.sh script because the GStreamer
 Edward> project uses this approach rather than the standard buildroot
 Edward> autotools configuration approach. The .tar.gz snapshots include
 Edward> pre-built .configure files - the git clone versions do
 Edward> not. I'll send you the modified .mk files so that you have the
 Edward> whole picture, but they will have to be modified to point to
 Edward> the cgit.freedesktop.org git repositories before they will work
 Edward> for you.

It should be enough to just add a <foo>_AUTORECONF = YES line in the
affected packages. See connman for an example. If you ./autogen.sh with
your normal host libtool then that could explain the problem (we patch
up libtool output to work around cross compile issues). Could you try a
fresh rebuild with the AUTORECONF = YES lines added.


-- 
Bye, Peter Korsgaard

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Buildroot] install-to-staging OK but install-to-target fails
  2012-02-03  7:00     ` Peter Korsgaard
@ 2012-02-03 22:27       ` Endejan, Edward
  0 siblings, 0 replies; 5+ messages in thread
From: Endejan, Edward @ 2012-02-03 22:27 UTC (permalink / raw)
  To: buildroot

Hi Peter,

Peter> It should be enough to just add a <foo>_AUTORECONF = YES line in the
Peter> affected packages. See connman for an example. If you ./autogen.sh with
Peter> your normal host libtool then that could explain the problem (we patch
Peter> up libtool output to work around cross compile issues). Could you try a
Peter> fresh rebuild with the AUTORECONF = YES lines added.

First, the <foo>_AUTORECONF = YES appears to have worked (almost). 
Some step of the reconfigure seems to process AC_SUBST of the 
GETTEXT_MACRO_VERSION macro improperly and the resulting Makefile 
is incorrect. As long as I do the substitution manually, the subsequent 
make gstreamer-install-target completes normally.

I've spent most of the day trying to track this down. I'm sure that I'm close.
Thanks for pointing me in the right direction.

Peter> Great. It contains the same info, but it's easier to look at as it only
Peter> shows the options you have changed from the details.

Just in case it still is useful, here is the result of 'make savedefconfig':

BR2_arm=y
BR2_cortex_a8=y
BR2_WGET="wget --passive-ftp -nd"
BR2_PRIMARY_SITE="http://git.escient.com/dl"
BR2_BACKUP_SITE="http://buildroot.net/downloads/sources/"
BR2_SOURCEFORGE_MIRROR="superb-sea2"
BR2_JLEVEL=16
BR2_CCACHE=y
BR2_KERNEL_HEADERS_3_1=y
BR2_BINUTILS_VERSION_2_20_1=y
BR2_GCC_VERSION_4_4_X=y
BR2_TARGET_OPTIMIZATION="-Os -pipe -march=armv7-a -mtune=cortex-a8 -mfpu=neon -ftree-vectorize -mfloat-abi=softfp"
BR2_TOOLCHAIN_BUILDROOT_LARGEFILE=y
BR2_TOOLCHAIN_BUILDROOT_INET_IPV6=y
BR2_TOOLCHAIN_BUILDROOT_WCHAR=y
BR2_TOOLCHAIN_BUILDROOT_CXX=y
BR2_PTHREADS_OLD=y
BR2_TARGET_GENERIC_HOSTNAME="beaglebone"
BR2_TARGET_GENERIC_ISSUE="Welcome to ADS"
BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_MDEV=y
BR2_ROOTFS_DEVICE_TABLE="board/denon/ads/device_table.txt"
BR2_ROOTFS_SKELETON_CUSTOM=y
BR2_ROOTFS_SKELETON_CUSTOM_PATH="board/denon/ads/skeleton"
BR2_PACKAGE_BUSYBOX_CONFIG="package/busybox/busybox-1.16.x.config"
BR2_PACKAGE_BUSYBOX_SHOW_OTHERS=y
BR2_PACKAGE_ALSA_UTILS=y
BR2_PACKAGE_ALSA_UTILS_ALSACONF=y
BR2_PACKAGE_ALSA_UTILS_AMIXER=y
BR2_PACKAGE_ALSA_UTILS_APLAY=y
BR2_PACKAGE_ALSA_UTILS_SPEAKER_TEST=y
BR2_PACKAGE_FAAD2=y
BR2_PACKAGE_GSTREAMER=y
BR2_PACKAGE_GST_FFMPEG=y
BR2_PACKAGE_GST_PLUGINS_BASE_PLUGIN_AUDIORATE=y
BR2_PACKAGE_GST_PLUGINS_BASE_PLUGIN_AUDIOTESTSRC=y
BR2_PACKAGE_GST_PLUGINS_BASE_PLUGIN_ENCODING=y
BR2_PACKAGE_GST_PLUGINS_BASE_PLUGIN_OGG=y
BR2_PACKAGE_GST_PLUGINS_BASE_PLUGI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R2_TARGET_UBOOT_CUSTOM_PATCH_DIR="board/ti/beaglebone/u-boot"
BR2_TARGET_UBOOT_CUSTOM_GIT_REPO_URL="git://git.escient.com/boot/u-boot"
BR2_TARGET_UBOOT_CUSTOM_GIT_VERSION="256415d8499bb76a094a179292c82c321a20192a"
BR2_TARGET_UBOOT_FORMAT_IMG=y
BR2_TARGET_UBOOT_MLO=y
BR2_LINUX_KERNEL=y
BR2_LINUX_KERNEL_CUSTOM_GIT=y
BR2_LINUX_KERNEL_CUSTOM_GIT_REPO_URL="git://git.escient.com/kernel/linux"
BR2_LINUX_KERNEL_CUSTOM_GIT_VERSION="c9c405dd9e2df8818b37a9f6b87c3b171fd47211"
BR2_LINUX_KERNEL_PATCH="board/ti/beaglebone/linux"
BR2_LINUX_KERNEL_USE_CUSTOM_CONFIG=y
BR2_LINUX_KERNEL_CUSTOM_CONFIG_FILE="board/ti/beaglebone/kernel_defconfig"


-----Original Message-----
From: Peter Korsgaard [mailto:jacmet at gmail.com] On Behalf Of Peter Korsgaard
Sent: Friday, February 03, 2012 2:00 AM
To: Endejan, Edward
Cc: Peter Korsgaard; buildroot at busybox.net
Subject: Re: install-to-staging OK but install-to-target fails

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2012-02-03 22:27 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-02-02 20:04 [Buildroot] install-to-staging OK but install-to-target fails Endejan, Edward
2012-02-02 20:36 ` Peter Korsgaard
2012-02-03  2:38   ` Endejan, Edward
2012-02-03  7:00     ` Peter Korsgaard
2012-02-03 22:27       ` Endejan, Edward

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox