Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 778041 - media-libs/cogl-1.22.8[gles2]: undefined reference to `cogl_gles2_get_current_vtable' with slibtool
Summary: media-libs/cogl-1.22.8[gles2]: undefined reference to `cogl_gles2_get_current...
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Linux Gnome Desktop Team
Depends on:
Blocks: slibtool
  Show dependency tree
Reported: 2021-03-25 01:19 UTC by Alessandro Barbieri
Modified: 2021-04-09 15:29 UTC (History)
2 users (show)

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

emerge_info (emerge_info,17.63 KB, text/plain)
2021-03-25 01:20 UTC, Alessandro Barbieri
cogl-1.22.8:20210325-000909.log (cogl-1.22.8:20210325-000909.log,545.06 KB, text/plain)
2021-03-25 01:20 UTC, Alessandro Barbieri
Details (cogl-gles2.patch,748 bytes, patch)
2021-03-25 14:28 UTC, orbea
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alessandro Barbieri 2021-03-25 01:19:42 UTC
This package fails to compile on an unstable system. Attached relevant logs and emerge --info
Comment 1 Alessandro Barbieri 2021-03-25 01:20:12 UTC
Created attachment 693372 [details]

emerge --info
Comment 2 Alessandro Barbieri 2021-03-25 01:20:19 UTC
Created attachment 693375 [details]

build log
Comment 3 Alessandro Barbieri 2021-03-25 01:29:45 UTC
rlibtool: link: ln -s /dev/null .libs/libcogl-gles2.a.disabled                                                         
rlibtool: link: x86_64-pc-linux-gnu-gcc .libs/cogl-gles2-api.o -pthread -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/libpng16 -I/usr/include/libmount -I/usr/include/blkid -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/includ
e/sysprof-4 -I/usr/include/libdrm -I/usr/lib64/libffi/include -DG_DISABLE_CHECKS -DG_DISABLE_CAST_CHECKS -Os -pipe -march=native -fdiagnostics-color=always -Os -pipe -march=native -fdiagnostics-color=always -Wimplicit-function-declaration
 -Wno-error=implicit-function-declaration -Wl,-O1 -Wl,--as-needed -shared -fPIC -Wl,--no-undefined -Wl,-soname -Wl, -o .libs/ -Wl,--export-dynamic                                                  
/usr/lib/gcc/x86_64-pc-linux-gnu/10.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: .libs/cogl-gles2-api.o: in function `glBindTexture':                                                                                                          
cogl-gles2-api.c:(.text+0xd): undefined reference to `cogl_gles2_get_current_vtable'                                                                                                                                                          
/usr/lib/gcc/x86_64-pc-linux-gnu/10.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: .libs/cogl-gles2-api.o: in function `glBlendFunc':                                                                                                            
cogl-gles2-api.c:(.text+0x2f): undefined reference to `cogl_gles2_get_current_vtable'                                                                                                                                                         
/usr/lib/gcc/x86_64-pc-linux-gnu/10.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: .libs/cogl-gles2-api.o: in function `glClear':                                                                                                                
cogl-gles2-api.c:(.text+0x4e): undefined reference to `cogl_gles2_get_current_vtable'
/usr/lib/gcc/x86_64-pc-linux-gnu/10.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: .libs/cogl-gles2-api.o: in function `glClearColor':
cogl-gles2-api.c:(.text+0x7c): undefined reference to `cogl_gles2_get_current_vtable'
/usr/lib/gcc/x86_64-pc-linux-gnu/10.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: .libs/cogl-gles2-api.o: in function `glClearStencil':
cogl-gles2-api.c:(.text+0xaa): undefined reference to `cogl_gles2_get_current_vtable'
/usr/lib/gcc/x86_64-pc-linux-gnu/10.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: .libs/cogl-gles2-api.o:cogl-gles2-api.c:(.text+0xce): more undefined references to `cogl_gles2_get_current_vtable' follow
collect2: error: ld returned 1 exit status
rlibtool: exec error upon slbt_exec_link_create_library(), line 1446: (see child process error messages).
rlibtool: < returned to > slbt_exec_link(), line 1868.
make[2]: *** [Makefile:602:] Error 2
make[2]: Leaving directory '/var/tmp/portage/media-libs/cogl-1.22.8/work/cogl-1.22.8/cogl-gles2'
make[1]: *** [Makefile:598: all-recursive] Error 1
make[1]: Leaving directory '/var/tmp/portage/media-libs/cogl-1.22.8/work/cogl-1.22.8'
make: *** [Makefile:525: all] Error 2
 * ERROR: media-libs/cogl-1.22.8::gentoo failed (compile phase):
 *   emake failed
Comment 4 orbea 2021-03-25 13:54:56 UTC
This requires the gles2 useflag to reproduce.
Comment 5 Ionen Wolkens gentoo-dev 2021-03-25 14:15:43 UTC
Haven't looked in-depth but if libcogl-gles2 links against libcogl it seems to fix both bugs.
Comment 6 orbea 2021-03-25 14:28:22 UTC
Created attachment 693447 [details, diff]

Another case of GNU libtool ignoring -no-undefined...
Comment 7 Larry the Git Cow gentoo-dev 2021-03-27 02:57:54 UTC
The bug has been closed via the following commit(s):

commit 0098ec8fad775917aeaeddc0fa4d2f7f2ad992e7
Author:     Sam James <>
AuthorDate: 2021-03-27 01:37:14 +0000
Commit:     Sam James <>
CommitDate: 2021-03-27 02:57:37 +0000

    media-libs/cogl: fix build with slibtool
    (Closing the NEEDED bug too which I filed
    in the past as I can't reproduce right now.
    Possibly fixed by this.)
    Thanks-to: orbea <>
    Signed-off-by: Sam James <>

 media-libs/cogl/cogl-1.22.8.ebuild               |  8 ++++++++
 media-libs/cogl/files/cogl-1.22.8-slibtool.patch | 26 ++++++++++++++++++++++++
 2 files changed, 34 insertions(+)