Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 698898 - media-libs/gst-plugins-base-1.14.5-r1 - ld: .libs/libgstgl_1.0_la-gstglcontext.o: in function `gst_gl_context_new': gstglcontext.c:(.text+0xb5c): undefined reference to `gst_gl_context_glx_new'
Summary: media-libs/gst-plugins-base-1.14.5-r1 - ld: .libs/libgstgl_1.0_la-gstglcontex...
Status: UNCONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: ARM64 Linux
: Normal normal (vote)
Assignee: GStreamer package maintainers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-10-30 08:43 UTC by ykla
Modified: 2022-02-03 10:52 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge output (build-.arm64.log,636.40 KB, text/plain)
2019-10-30 08:43 UTC, ykla
Details
build.log (build.log,642.05 KB, text/plain)
2019-10-30 08:44 UTC, ykla
Details
eclass-debug.log (eclass-debug.log,5.50 KB, text/plain)
2019-10-30 08:45 UTC, ykla
Details
environment (environment,132.82 KB, text/plain)
2019-10-30 08:46 UTC, ykla
Details
gst-plugins-base-1.14.5-r1 genrpi64 ebuild patch (file_698898.txt,1.33 KB, patch)
2020-02-22 01:29 UTC, Erik Fjeldstrom
Details | Diff
build.log of media-libs/gst-plugins-base-1.16.3 on ARM (build.log,641.61 KB, text/plain)
2021-03-17 19:43 UTC, lebkoungcity
Details

Note You need to log in before you can comment on or make changes to this bug.
Description ykla 2019-10-30 08:43:16 UTC
Created attachment 594516 [details]
emerge output

ON raspberry pi4 aarch64 Gentoo


media-libs/gst-plugins-base-1.14.5-r1::gentoo failed (compile phase)

logs:
----------------------------------------------------------------------
ld: .libs/libgstgl_1.0_la-gstglcontext.o: in function `gst_gl_context_new':
gstglcontext.c:(.text+0xb5c): undefined reference to `gst_gl_context_glx_new'
/usr/lib/gcc/aarch64-unknown-linux-gnu/8.3.0/../../../../aarch64-unknown-linux-gnu/bin/ld: gstglcontext.c:(.text+0xc2c): undefined reference to `gst_gl_context_glx_new'
/usr/lib/gcc/aarch64-unknown-linux-gnu/8.3.0/../../../../aarch64-unknown-linux-gnu/bin/ld: .libs/libgstgl_1.0_la-gstglcontext.o: in function `gst_gl_context_new_wrapped':
gstglcontext.c:(.text+0xda0): undefined reference to `gst_gl_context_glx_get_current_context'
/usr/lib/gcc/aarch64-unknown-linux-gnu/8.3.0/../../../../aarch64-unknown-linux-gnu/bin/ld: gstglcontext.c:(.text+0xda4): undefined reference to `gst_gl_context_glx_get_current_context'
/usr/lib/gcc/aarch64-unknown-linux-gnu/8.3.0/../../../../aarch64-unknown-linux-gnu/bin/ld: gstglcontext.c:(.text+0xda8): undefined reference to `gst_gl_context_glx_get_proc_address'
/usr/lib/gcc/aarch64-unknown-linux-gnu/8.3.0/../../../../aarch64-unknown-linux-gnu/bin/ld: gstglcontext.c:(.text+0xdac): undefined reference to `gst_gl_context_glx_get_proc_address'
/usr/lib/gcc/aarch64-unknown-linux-gnu/8.3.0/../../../../aarch64-unknown-linux-gnu/bin/ld: .libs/libgstgl_1.0_la-gstglcontext.o: in function `gst_gl_context_get_current_gl_context':
gstglcontext.c:(.text+0xe94): undefined reference to `gst_gl_context_glx_get_current_context'
/usr/lib/gcc/aarch64-unknown-linux-gnu/8.3.0/../../../../aarch64-unknown-linux-gnu/bin/ld: .libs/libgstgl_1.0_la-gstglcontext.o: in function `gst_gl_context_get_proc_address_with_platform':
gstglcontext.c:(.text+0xefc): undefined reference to `gst_gl_context_glx_get_proc_address'
/usr/lib/gcc/aarch64-unknown-linux-gnu/8.3.0/../../../../aarch64-unknown-linux-gnu/bin/ld: .libs/libgstgl-1.0.so.0.1405.0: hidden symbol `gst_gl_context_glx_new' isn't defined
/usr/lib/gcc/aarch64-unknown-linux-gnu/8.3.0/../../../../aarch64-unknown-linux-gnu/bin/ld: final link failed: bad value
collect2: error: ld returned 1 exit status
make[5]: *** [Makefile:927: libgstgl-1.0.la] Error 1
make[5]: Leaving directory '/var/tmp/portage/media-libs/gst-plugins-base-1.14.5-r1/work/gst-plugins-base-1.14.5-.arm64/gst-libs/gst/gl'
make[4]: *** [Makefile:1279: all-recursive] Error 1
make[4]: Leaving directory '/var/tmp/portage/media-libs/gst-plugins-base-1.14.5-r1/work/gst-plugins-base-1.14.5-.arm64/gst-libs/gst/gl'
make[3]: *** [Makefile:659: all-recursive] Error 1
make[3]: Leaving directory '/var/tmp/portage/media-libs/gst-plugins-base-1.14.5-r1/work/gst-plugins-base-1.14.5-.arm64/gst-libs/gst'
make[2]: *** [Makefile:624: all-recursive] Error 1
make[2]: Leaving directory '/var/tmp/portage/media-libs/gst-plugins-base-1.14.5-r1/work/gst-plugins-base-1.14.5-.arm64/gst-libs'
make[1]: *** [Makefile:748: all-recursive] Error 1
make[1]: Leaving directory '/var/tmp/portage/media-libs/gst-plugins-base-1.14.5-r1/work/gst-plugins-base-1.14.5-.arm64'
make: *** [Makefile:679: all] Error 2
 * ERROR: media-libs/gst-plugins-base-1.14.5-r1::gentoo failed (compile phase):
 *   emake failed
 * 
 * If you need support, post the output of `emerge --info '=media-libs/gst-plugins-base-1.14.5-r1::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=media-libs/gst-plugins-base-1.14.5-r1::gentoo'`.
 * The complete build log is located at '/var/tmp/portage/media-libs/gst-plugins-base-1.14.5-r1/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/media-libs/gst-plugins-base-1.14.5-r1/temp/environment'.
 * Working directory: '/var/tmp/portage/media-libs/gst-plugins-base-1.14.5-r1/work/gst-plugins-base-1.14.5-.arm64'
 * S: '/var/tmp/portage/media-libs/gst-plugins-base-1.14.5-r1/work/gst-plugins-base-1.14.5'





------------------------------------------------------------
gentoo ~ # cat /etc/portage/make.conf 
# These settings were set by the catalyst build script that automatically
# built this stage.
# Please consult /usr/share/portage/config/make.conf.example for a more
# detailed example.
COMMON_FLAGS="-march=armv8-a+crc -mtune=cortex-a72 -O2 -pipe"
CFLAGS="${COMMON_FLAGS}"
CXXFLAGS="${COMMON_FLAGS}"
FCFLAGS="${COMMON_FLAGS}"
FFLAGS="${COMMON_FLAGS}"
# WARNING: Changing your CHOST is not something that should be done lightly.
# Please consult https://wiki.gentoo.org/wiki/Changing_the_CHOST_variable before changing.
CHOST="aarch64-unknown-linux-gnu"

# NOTE: This stage was built with the bindist Use flag enabled
#PORTDIR="/var/db/repos/gentoo"
#DISTDIR="/var/cache/distfiles"
#PKGDIR="/var/cache/binpkgs"

# This sets the language of build output to English.
# Please keep this setting intact when reporting bugs.
LC_MESSAGES=C

L10N="zh zh-CN zh_CN"
MAKEOPTS="-j5"
GENTOO_MIRRORS="https://mirrors.163.com/gentoo/"
VIDEO_CARDS="vc4"
#USE="egl gles1 gles2"
USE="user-session"
----------------------------------------------------------------------
Comment 1 ykla 2019-10-30 08:44:22 UTC
Created attachment 594518 [details]
build.log
Comment 2 ykla 2019-10-30 08:45:09 UTC
Created attachment 594520 [details]
eclass-debug.log
Comment 3 ykla 2019-10-30 08:46:00 UTC
Created attachment 594522 [details]
environment
Comment 4 Erik Fjeldstrom 2020-02-22 01:29:43 UTC
Created attachment 615000 [details, diff]
gst-plugins-base-1.14.5-r1 genrpi64 ebuild patch

I encountered the same issue when compiling for the Raspberry Pi 4 (arm64) with the Gentoo repository version. Switching to the genpi64 overlay version (https://github.com/sakaki-/genpi64-overlay) solved the issue: The genpi64 patch disables Raspberry Pi detection for arm64.

The patch is attached.
Comment 5 Gary E. Miller 2021-02-15 21:25:07 UTC
media-libs/gst-plugins-base-1.16.3::gentoo has the same problem.
Comment 6 Gary E. Miller 2021-02-15 21:35:28 UTC
I can emerge this way:

USE="-egl -gles2"  emerge -a media-libs/gst-plugins-base

That leaves these flags on for me:

(X alsa introspection ogg opengl pango theora vorbis)
Comment 7 Gary E. Miller 2021-02-21 21:49:01 UTC
I can confirm that patch also fixes media-libs/gst-plugins-base-1.16.3.

I had to repair the manifest after the patch, before emerging:

```
cd /var/db/repos/gentoo/media-libs/gst-plugins-base
repoman manifest
```
Comment 8 Sven E. 2021-03-11 00:47:05 UTC
This is not limited to aarch64, seeing this on aarch32 aswell.
Comment 9 lebkoungcity 2021-03-17 19:35:53 UTC
I have installed a 32-bit gentoo on my Raspberry Pi 4.
media-libs/gst-plugins-base-1.16.3 fails with:

/usr/lib/gcc/armv7a-unknown-linux-gnueabihf/9.3.0/../../../../armv7a-unknown-linux-gnueabihf/bin/ld: .libs/libgstgl_1.0_la-gstglcontext.o: in function `gst_gl_context_new':
gstglcontext.c:(.text+0xdec): undefined reference to `gst_gl_context_glx_new'

I add the build log.
Just drop a line if more info is needed/wanted.
Comment 10 lebkoungcity 2021-03-17 19:43:47 UTC
Created attachment 692157 [details]
build.log of media-libs/gst-plugins-base-1.16.3 on ARM
Comment 11 Kyle Elbert 2022-02-03 10:51:10 UTC
still a bug with PIs on both arm archs involving how this build deals with bcm_host from media-libs/raspberrypi-userland.. Just got bit by it on 1.16.3-r1 on arm (32) on my pi 4. Too tired to poke further in on how it actually breaks/why it suddenly decides a symbol defined IN THAT C file is undefined.

Simply exporting ac_cv_lib_bcm_host_bcm_host_init=no (as the genpi64 ebuild hints, ie, via make.conf or a package.env setup) works around it