Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 687908 - media-video/vlc-3.0.7 fails to compile if USE="libplacebo" (media-libs/libplacebo-1.18.0)
Summary: media-video/vlc-3.0.7 fails to compile if USE="libplacebo" (media-libs/libpla...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Media-video project
URL:
Whiteboard:
Keywords:
: 688406 (view as bug list)
Depends on:
Blocks:
 
Reported: 2019-06-12 09:06 UTC by Attila Tóth
Modified: 2019-06-25 19:28 UTC (History)
2 users (show)

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


Attachments
vlc-libplacebo-desaturate.patch (vlc-libplacebo-desaturate.patch,1.93 KB, patch)
2019-06-12 09:11 UTC, Attila Tóth
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Attila Tóth 2019-06-12 09:06:50 UTC
libtool: link: ( cd ".libs" && rm -f "libopencv_example_plugin.la" && ln -s "../libopencv_example_plugin.la" "libopencv_example_plugin.la" )
../doltlibtool  --tag=CC   --mode=compile x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I..  -DMODULE_STRING=\"$(p="video_output/opengl/libgl_plugin_la-vout_helper.lo"; p="${p##*/}"; p="${p#lib}"; p="${p%_plugin*}"; p=$(echo "$p"|sed 's/-/_/g'); p="${p%.lo}"; echo "$p")\" -D__PLUGIN__  -I./access -I./codec -I../include -I../include   -I/usr/include/libdrm   -O2 -march=native -pipe  -Wall -Wextra -Wsign-compare -Wundef -Wpointer-arith -Wvolatile-register-var -Wformat -Wformat-security -Wbad-function-cast -Wwrite-strings -Wmissing-prototypes -Werror-implicit-function-declaration -Winit-self -Wlogical-op -Wshadow=local -fvisibility=hidden -c -o video_output/opengl/libgl_plugin_la-vout_helper.lo `test -f 'video_output/opengl/vout_helper.c' || echo './'`video_output/opengl/vout_helper.c
../doltlibtool  --tag=CC   --mode=compile x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I..  -DMODULE_STRING=\"$(p="video_output/opengl/libgl_plugin_la-fragment_shaders.lo"; p="${p##*/}"; p="${p#lib}"; p="${p%_plugin*}"; p=$(echo "$p"|sed 's/-/_/g'); p="${p%.lo}"; echo "$p")\" -D__PLUGIN__  -I./access -I./codec -I../include -I../include   -I/usr/include/libdrm   -O2 -march=native -pipe  -Wall -Wextra -Wsign-compare -Wundef -Wpointer-arith -Wvolatile-register-var -Wformat -Wformat-security -Wbad-function-cast -Wwrite-strings -Wmissing-prototypes -Werror-implicit-function-declaration -Winit-self -Wlogical-op -Wshadow=local -fvisibility=hidden -c -o video_output/opengl/libgl_plugin_la-fragment_shaders.lo `test -f 'video_output/opengl/fragment_shaders.c' || echo './'`video_output/opengl/fragment_shaders.c
libtool: link: /usr/bin/x86_64-pc-linux-gnu-nm -B  visualization/.libs/libprojectm_plugin_la-projectm.o   | sed -n -e 's/^.*[    ]\([ABCDGIRSTW][ABCDGIRSTW]*\)[         ][      ]*\([_A-Za-z][_A-Za-z0-9]*\)$/\1 \2 \2/p' | sed '/ __gnu_lto/d' | /bin/sed 's/.* //' | sort | uniq > .libs/libprojectm_plugin.exp
libtool: link: /bin/grep -E -e "^vlc_entry" ".libs/libprojectm_plugin.exp" > ".libs/libprojectm_plugin.expT"
video_output/opengl/fragment_shaders.c: In function ‘opengl_fragment_shader_init_impl’:
video_output/opengl/fragment_shaders.c:619:22: error: ‘struct pl_color_map_params’ has no member named ‘tone_mapping_desaturate’; did you mean ‘tone_mapping_param’?
  619 |         color_params.tone_mapping_desaturate = var_InheritFloat(tc->gl, "tone-mapping-desat");
      |                      ^~~~~~~~~~~~~~~~~~~~~~~
      |                      tone_mapping_param
libtool: link: mv -f ".libs/libprojectm_plugin.expT" ".libs/libprojectm_plugin.exp"
make[4]: *** [Makefile:21852: video_output/opengl/libgl_plugin_la-fragment_shaders.lo] Error 1
make[4]: *** Waiting for unfinished jobs....
libtool: link: x86_64-pc-linux-gnu-g++  -fPIC -DPIC -shared -nostdlib /usr/lib/gcc/x86_64-pc-linux-gnu/9.1.0/../../../../lib64/crti.o /usr/lib/gcc/x86_64-pc-linux-gnu/9.1.0/crtbeginS.o  visualization/.libs/libprojectm_plugin_la-projectm.o   -Wl,-rpath -Wl,/var/tmp/portage/media-video/vlc-3.0.7/work/vlc-3.0.7/src/.libs -Wl,-rpath -Wl,//usr/lib64 ../compat/.libs/libcompat.a -L/usr/lib64/sidplay/builders/ ../src/.libs/libvlccore.so -lidn -ldbus-1 -Wl,--as-needed //usr/lib64/libprojectM.so -lGL -ldl -lpthread -L/usr/lib/gcc/x86_64-pc-linux-gnu/9.1.0 -L/usr/lib/gcc/x86_64-pc-linux-gnu/9.1.0/../../../../lib64 -L/lib/../lib64 -L/usr/lib/../lib64 -L/usr/lib/gcc/x86_64-pc-linux-gnu/9.1.0/../../../../x86_64-pc-linux-gnu/lib -L/usr/lib/gcc/x86_64-pc-linux-gnu/9.1.0/../../.. -lstdc++ -lm -lc -lgcc_s /usr/lib/gcc/x86_64-pc-linux-gnu/9.1.0/crtendS.o /usr/lib/gcc/x86_64-pc-linux-gnu/9.1.0/../../../../lib64/crtn.o  -O2 -march=native -Wl,-O1 -Wl,-z -Wl,defs   -pthread -Wl,-soname -Wl,libprojectm_plugin.so -Wl,-retain-symbols-file -Wl,.libs/libprojectm_plugin.exp -o .libs/libprojectm_plugin.so
libtool: link: ( cd ".libs" && rm -f "libprojectm_plugin.la" && ln -s "../libprojectm_plugin.la" "libprojectm_plugin.la" )
make[4]: Leaving directory '/var/tmp/portage/media-video/vlc-3.0.7/work/vlc-3.0.7/modules'
make[3]: *** [Makefile:27485: all-recursive] Error 1
make[3]: Leaving directory '/var/tmp/portage/media-video/vlc-3.0.7/work/vlc-3.0.7/modules'
make[2]: *** [Makefile:12539: all] Error 2
make[2]: Leaving directory '/var/tmp/portage/media-video/vlc-3.0.7/work/vlc-3.0.7/modules'
make[1]: *** [Makefile:1552: all-recursive] Error 1
make[1]: Leaving directory '/var/tmp/portage/media-video/vlc-3.0.7/work/vlc-3.0.7'
make: *** [Makefile:1437: all] Error 2
 * ERROR: media-video/vlc-3.0.7::gentoo failed (compile phase):
 *   emake failed
 *
 * If you need support, post the output of `emerge --info '=media-video/vlc-3.0.7::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=media-video/vlc-3.0.7::gentoo'`.
 * The complete build log is located at '/var/tmp/portage/media-video/vlc-3.0.7/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/media-video/vlc-3.0.7/temp/environment'.
 * Working directory: '/var/tmp/portage/media-video/vlc-3.0.7/work/vlc-3.0.7'
 * S: '/var/tmp/portage/media-video/vlc-3.0.7/work/vlc-3.0.7'
Comment 1 Attila Tóth 2019-06-12 09:09:19 UTC
pl_color_map_params struct provided by libplacebo indeed does not have a member named tone_mapping_desaturate, but have three desaturation related members - including desaturation_strength - with a reasonably detailed explanation in the header file installed.
Comment 2 Attila Tóth 2019-06-12 09:11:50 UTC
Created attachment 579602 [details, diff]
vlc-libplacebo-desaturate.patch

Proposed patch makes it possible to compile vlc-3.0.7 with USE=libplacebo against libplacebo-1.18.0, replacing tone_mapping_desaturate with desaturation_strength.
Comment 3 Andreas Sturmlechner gentoo-dev 2019-06-12 09:14:17 UTC
Is this patch already upstream? What about vlc git master, does it build?
Comment 4 Attila Tóth 2019-06-12 09:44:29 UTC
(In reply to Andreas Sturmlechner from comment #3)
> Is this patch already upstream? What about vlc git master, does it build?

I haven't checked it upstreams, but I took a look at on it as per your request and I don't see these changes there. I haven't tried to compile git master.
I'm not sure against which version of libplacebo they created the vlc source file?
Either I check libplacebo on github:
https://github.com/haasn/libplacebo/blob/master/src/include/libplacebo/shaders/colorspace.h
or videolan's own repository (authored by the same person):
https://code.videolan.org/videolan/libplacebo/blob/master/src/include/libplacebo/shaders/colorspace.h
The members of the struct in question are the same...
Comment 5 Duncan 2019-06-13 16:11:23 UTC
(In reply to Andreas Sturmlechner from comment #3)
> Is this patch already upstream? What about vlc git master, does it build?

Seeing this too.  Going to try -9999s and etc.
Comment 6 Duncan 2019-06-13 17:00:19 UTC
(In reply to Duncan from comment #5)
> (In reply to Andreas Sturmlechner from comment #3)
> > Is this patch already upstream? What about vlc git master, does it build?
> 
> Seeing this too.  Going to try -9999s and etc.

* vlc-9999 against libplacebo-1.18.0 fails with the same error.

* vlc-9999 against libplacebo-9999 still fails with the same error.

* vlc-3.0.7 with USE=-libplacebo builds fine (as expected given the error).

So it's definitely vlc-3.0.7's new libplacebo code, and it's not fixed in either vlc-master or libplacebo-master, but a gentoo-user-level temp fix (vlc-3.0.7 has security fixes) is simply USE=-libplacebo -- given that's new anyway, you're not losing anything against 3.0.6 having it off, and you'll get 3.0.7's security fixes that way.
Comment 7 Andreas Sturmlechner gentoo-dev 2019-06-21 04:41:45 UTC
*** Bug 688406 has been marked as a duplicate of this bug. ***
Comment 8 Mihai Moldovan 2019-06-25 09:02:56 UTC
Upstream includes a patch for this now (actually for 8 days now): https://github.com/videolan/vlc/commit/b579384a239683232f5558216cc03c6ae5a5dc38

media-video/vlc-9999 should hence compile again.
Comment 9 Larry the Git Cow gentoo-dev 2019-06-25 19:28:09 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=559f017fa7cf7b7220c8a02bcb35b7cc931df0d7

commit 559f017fa7cf7b7220c8a02bcb35b7cc931df0d7
Author:     Andreas Sturmlechner <asturm@gentoo.org>
AuthorDate: 2019-06-25 19:26:42 +0000
Commit:     Andreas Sturmlechner <asturm@gentoo.org>
CommitDate: 2019-06-25 19:27:56 +0000

    media-video/vlc: USE libplacebo is not maintained in 3.0 branch
    
    Closes: https://bugs.gentoo.org/687908
    Package-Manager: Portage-2.3.67, Repoman-2.3.16
    Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>

 media-video/vlc/vlc-3.0.9999.ebuild | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)