Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 468102 - app-emulation/emul-linux-x86-opengl: migrate to multilib eclasses
Summary: app-emulation/emul-linux-x86-opengl: migrate to multilib eclasses
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo X packagers
URL:
Whiteboard:
Keywords:
: 473462 (view as bug list)
Depends on: 434200 480540
Blocks: gx86-multilib
  Show dependency tree
 
Reported: 2013-05-01 09:39 UTC by Pacho Ramos
Modified: 2013-09-21 17:13 UTC (History)
10 users (show)

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


Attachments
Patch for all the involved packages (0001-opengl-multilib.patch,28.02 KB, patch)
2013-08-13 12:49 UTC, Michał Górny
Details | Diff
Updated patch (0001-opengl-multilib.patch,28.09 KB, patch)
2013-08-13 16:52 UTC, Michał Górny
Details | Diff
Rebased & updated patch (opengl-multilib-r1.patch,20.70 KB, patch)
2013-09-16 16:17 UTC, Michał Górny
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Pacho Ramos gentoo-dev 2013-05-01 09:39:42 UTC
Not sure about the plans on this now that xlibs set was migrated, but most people have a lot of problems specially with mesa (due needing USE flags changing, running multiple different versions to test)

Any plans on migrating this set? 

It includes the following:
media-libs/freeglut	2.8.0-r1
media-libs/glew	1.9.0
media-libs/glu	9.0.0
media-libs/mesa	9.0.1
x11-libs/libdrm	2.4.40

Thanks

Reproducible: Always
Comment 1 Matt Turner gentoo-dev 2013-06-23 20:21:25 UTC
Yes, we definitely want to do this to let users get 32-bit Mesa updates quicker. As far as I know, it's all possible except for bug 434200 which blocks multilib Mesa.
Comment 2 Mike Lothian 2013-08-03 16:31:29 UTC
I've rebased mesa-9999-r51 in the FireBurn overlay against the new multilib llvm in portage

Just had to adjust the llvm-config bit as I had llvm-config-amd64 and llvm-config-x86 with a symlink to the amd64 one, whereas the new llvm uses llvm-config.x86 and uses llvm-config for the amd64 - tad annoying but it works
Comment 3 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2013-08-13 12:49:52 UTC
Created attachment 355866 [details, diff]
Patch for all the involved packages
Comment 4 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2013-08-13 12:50:54 UTC
The attached patch takes care of them all. Please let me know if it's OK to commit. I'd prefer to commit it all without p.mask since we can take care of the whole virtual in one commit.
Comment 5 Alexis Ballier gentoo-dev 2013-08-13 13:07:58 UTC
Comment on attachment 355866 [details, diff]
Patch for all the involved packages

very nice

>copy from gx86/dev-libs/libclc/libclc-0.0.1_pre20130524.ebuild
>copy to gx86/dev-libs/libclc/libclc-0.0.1_pre20130524-r1.ebuild
>index 0534a96..1a2dea6 100644
>--- a/gx86/dev-libs/libclc/libclc-0.0.1_pre20130524.ebuild
>+++ b/gx86/dev-libs/libclc/libclc-0.0.1_pre20130524-r1.ebuild
>@@ -45,5 +45,6 @@ src_unpack() {
> src_configure() {
> 	./configure.py \
> 		--with-llvm-config="${EPREFIX}/usr/bin/llvm-config" \
>-		--prefix="${EPREFIX}/usr"
>+		--prefix="${EPREFIX}/usr" \
>+		--pkgconfigdir="${EPREFIX}/usr/share/pkgconfig"
> }


why ? unrelated ? can go before ?

>diff --git a/gx86/dev-libs/wayland/wayland-1.2.0.ebuild b/gx86/dev-libs/wayland/wayland-1.2.0-r1.ebuild
>similarity index 78%
>copy from gx86/dev-libs/wayland/wayland-1.2.0.ebuild
>copy to gx86/dev-libs/wayland/wayland-1.2.0-r1.ebuild
>index b52d119..e0d06b1 100644
>--- a/gx86/dev-libs/wayland/wayland-1.2.0.ebuild
>+++ b/gx86/dev-libs/wayland/wayland-1.2.0-r1.ebuild
>@@ -8,9 +8,10 @@ if [[ ${PV} = 9999* ]]; then
> 	EGIT_REPO_URI="git://anongit.freedesktop.org/git/${PN}/${PN}"
> 	GIT_ECLASS="git-2"
> 	EXPERIMENTAL="true"
>+	AUTOTOOLS_AUTORECONF=1
> fi
> 
>-inherit autotools toolchain-funcs $GIT_ECLASS
>+inherit autotools-multilib toolchain-funcs $GIT_ECLASS
> 
> DESCRIPTION="Wayland protocol libraries"
> HOMEPAGE="http://wayland.freedesktop.org/"
>@@ -33,19 +34,16 @@ DEPEND="${RDEPEND}
> 	doc? ( app-doc/doxygen )
> 	virtual/pkgconfig"
> 
>-src_prepare() {
>-	if [[ ${PV} = 9999* ]]; then
>-		eautoreconf
>-	fi
>-}
>-
> src_configure() {
>-	myconf="$(use_enable static-libs static) \
>-			$(use_enable doc documentation)"
>+	local myeconfargs=(
>+		$(use_enable static-libs static)

isnt that automatic ?

>+		$(use_enable doc documentation)

please disable it on non-native abi, those will be thrown away i believe

>diff --git a/gx86/media-libs/freeglut/freeglut-2.8.1.ebuild b/gx86/media-libs/freeglut/freeglut-2.8.1-r2.ebuild
>similarity index 55%
>copy from gx86/media-libs/freeglut/freeglut-2.8.1.ebuild
>copy to gx86/media-libs/freeglut/freeglut-2.8.1-r2.ebuild
>index c622a32..c87e3bb 100644
[...]
>-	find "${ED}" -name '*.la' -exec rm -f {} +

I'd add a AUTOTOOLS_PRUNE_LIBTOOL_FILES=all to replace this but not my call


>diff --git a/gx86/media-libs/mesa/mesa-9.1.6.ebuild b/gx86/media-libs/mesa/mesa-9.1.6-r1.ebuild
>similarity index 88%
>copy from gx86/media-libs/mesa/mesa-9.1.6.ebuild
>copy to gx86/media-libs/mesa/mesa-9.1.6-r1.ebuild
[...]
> DEPEND="${RDEPEND}
> 	llvm? (
>-		>=sys-devel/llvm-2.9
>+		~sys-devel/llvm-3.3[${MULTILIB_USEDEP}]

why the ~ ?

>-src_configure() {
>+multilib_src_configure() {
> 	local myconf
> 
> 	if use classic; then
>@@ -248,6 +248,11 @@ src_configure() {
> 	# build fails with BSD indent, bug #428112
> 	use userland_GNU || export INDENT=cat
> 
>+	if ! multilib_is_native_abi; then
>+		myconf+="--disable-xorg
>+			LLVM_CONFIG=${EPREFIX}/usr/bin/llvm-config.${ABI}"
>+	fi

is it a TODO or is it just unwanted ?


>diff --git a/gx86/virtual/opencl/opencl-0-r3.ebuild b/gx86/virtual/opencl/opencl-0-r4.ebuild
>similarity index 61%
>copy from gx86/virtual/opencl/opencl-0-r3.ebuild
>copy to gx86/virtual/opencl/opencl-0-r4.ebuild
>index 90c1d62..a2a5116 100644

while at it, please add the MULTILIB_USEDEP to media-libs/x264-9999 or remind me to do it after committing




again, great work!
Comment 6 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2013-08-13 16:51:34 UTC
(In reply to Alexis Ballier from comment #5)
> >copy from gx86/dev-libs/libclc/libclc-0.0.1_pre20130524.ebuild
> >copy to gx86/dev-libs/libclc/libclc-0.0.1_pre20130524-r1.ebuild
> >index 0534a96..1a2dea6 100644
> >--- a/gx86/dev-libs/libclc/libclc-0.0.1_pre20130524.ebuild
> >+++ b/gx86/dev-libs/libclc/libclc-0.0.1_pre20130524-r1.ebuild
> >@@ -45,5 +45,6 @@ src_unpack() {
> > src_configure() {
> > 	./configure.py \
> > 		--with-llvm-config="${EPREFIX}/usr/bin/llvm-config" \
> >-		--prefix="${EPREFIX}/usr"
> >+		--prefix="${EPREFIX}/usr" \
> >+		--pkgconfigdir="${EPREFIX}/usr/share/pkgconfig"
> > }
> 
> why ? unrelated ? can go before ?

Sorry, I don't understand.

We need to add --pkgconfigdir since libclc installs it to /usr/lib/pkgconfig (yep, no $(get_libdir)). I've reported this upstreams and most likely the default will be fixed real soon.

> >diff --git a/gx86/dev-libs/wayland/wayland-1.2.0.ebuild b/gx86/dev-libs/wayland/wayland-1.2.0-r1.ebuild
> >similarity index 78%
> >copy from gx86/dev-libs/wayland/wayland-1.2.0.ebuild
> >copy to gx86/dev-libs/wayland/wayland-1.2.0-r1.ebuild
> >index b52d119..e0d06b1 100644
> >--- a/gx86/dev-libs/wayland/wayland-1.2.0.ebuild
> >+++ b/gx86/dev-libs/wayland/wayland-1.2.0-r1.ebuild
> >@@ -8,9 +8,10 @@ if [[ ${PV} = 9999* ]]; then
> > 	EGIT_REPO_URI="git://anongit.freedesktop.org/git/${PN}/${PN}"
> > 	GIT_ECLASS="git-2"
> > 	EXPERIMENTAL="true"
> >+	AUTOTOOLS_AUTORECONF=1
> > fi
> > 
> >-inherit autotools toolchain-funcs $GIT_ECLASS
> >+inherit autotools-multilib toolchain-funcs $GIT_ECLASS
> > 
> > DESCRIPTION="Wayland protocol libraries"
> > HOMEPAGE="http://wayland.freedesktop.org/"
> >@@ -33,19 +34,16 @@ DEPEND="${RDEPEND}
> > 	doc? ( app-doc/doxygen )
> > 	virtual/pkgconfig"
> > 
> >-src_prepare() {
> >-	if [[ ${PV} = 9999* ]]; then
> >-		eautoreconf
> >-	fi
> >-}
> >-
> > src_configure() {
> >-	myconf="$(use_enable static-libs static) \
> >-			$(use_enable doc documentation)"
> >+	local myeconfargs=(
> >+		$(use_enable static-libs static)
> 
> isnt that automatic ?

You are correct, thanks.

> >+		$(use_enable doc documentation)
> 
> please disable it on non-native abi, those will be thrown away i believe

Fixed.

> >diff --git a/gx86/media-libs/freeglut/freeglut-2.8.1.ebuild b/gx86/media-libs/freeglut/freeglut-2.8.1-r2.ebuild
> >similarity index 55%
> >copy from gx86/media-libs/freeglut/freeglut-2.8.1.ebuild
> >copy to gx86/media-libs/freeglut/freeglut-2.8.1-r2.ebuild
> >index c622a32..c87e3bb 100644
> [...]
> >-	find "${ED}" -name '*.la' -exec rm -f {} +
> 
> I'd add a AUTOTOOLS_PRUNE_LIBTOOL_FILES=all to replace this but not my call

Hmm, but glut doesn't provide a pkg-config file, so removing .la is incorrect. We should either keep it, or drop USE=static-libs.

> >diff --git a/gx86/media-libs/mesa/mesa-9.1.6.ebuild b/gx86/media-libs/mesa/mesa-9.1.6-r1.ebuild
> >similarity index 88%
> >copy from gx86/media-libs/mesa/mesa-9.1.6.ebuild
> >copy to gx86/media-libs/mesa/mesa-9.1.6-r1.ebuild
> [...]
> > DEPEND="${RDEPEND}
> > 	llvm? (
> >-		>=sys-devel/llvm-2.9
> >+		~sys-devel/llvm-3.3[${MULTILIB_USEDEP}]
> 
> why the ~ ?

It doesn't work with llvm-9999 (going to be 3.4). And since older versions don't do multilib, I've decided to just put 3.3.

> >-src_configure() {
> >+multilib_src_configure() {
> > 	local myconf
> > 
> > 	if use classic; then
> >@@ -248,6 +248,11 @@ src_configure() {
> > 	# build fails with BSD indent, bug #428112
> > 	use userland_GNU || export INDENT=cat
> > 
> >+	if ! multilib_is_native_abi; then
> >+		myconf+="--disable-xorg
> >+			LLVM_CONFIG=${EPREFIX}/usr/bin/llvm-config.${ABI}"
> >+	fi
> 
> is it a TODO or is it just unwanted ?

xorg is unwanted. chithead says it's just a driver for xorg-server, and we're not running a 32-bit server :).

> >diff --git a/gx86/virtual/opencl/opencl-0-r3.ebuild b/gx86/virtual/opencl/opencl-0-r4.ebuild
> >similarity index 61%
> >copy from gx86/virtual/opencl/opencl-0-r3.ebuild
> >copy to gx86/virtual/opencl/opencl-0-r4.ebuild
> >index 90c1d62..a2a5116 100644
> 
> while at it, please add the MULTILIB_USEDEP to media-libs/x264-9999 or
> remind me to do it after committing

I'll try to remember ;).

> again, great work!

Thanks.
Comment 7 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2013-08-13 16:52:35 UTC
Created attachment 355888 [details, diff]
Updated patch
Comment 8 Alexis Ballier gentoo-dev 2013-08-13 16:59:39 UTC
(In reply to Michał Górny from comment #6)
> (In reply to Alexis Ballier from comment #5)
> > >copy from gx86/dev-libs/libclc/libclc-0.0.1_pre20130524.ebuild
> > >copy to gx86/dev-libs/libclc/libclc-0.0.1_pre20130524-r1.ebuild
> > >index 0534a96..1a2dea6 100644
> > >--- a/gx86/dev-libs/libclc/libclc-0.0.1_pre20130524.ebuild
> > >+++ b/gx86/dev-libs/libclc/libclc-0.0.1_pre20130524-r1.ebuild
> > >@@ -45,5 +45,6 @@ src_unpack() {
> > > src_configure() {
> > > 	./configure.py \
> > > 		--with-llvm-config="${EPREFIX}/usr/bin/llvm-config" \
> > >-		--prefix="${EPREFIX}/usr"
> > >+		--prefix="${EPREFIX}/usr" \
> > >+		--pkgconfigdir="${EPREFIX}/usr/share/pkgconfig"
> > > }
> > 
> > why ? unrelated ? can go before ?
> 
> Sorry, I don't understand.
> 
> We need to add --pkgconfigdir since libclc installs it to /usr/lib/pkgconfig
> (yep, no $(get_libdir)). I've reported this upstreams and most likely the
> default will be fixed real soon.


yes, then it's "unrelated", should be fixed regardless of multilib and can be committed without the rest :)


> > >diff --git a/gx86/media-libs/freeglut/freeglut-2.8.1.ebuild b/gx86/media-libs/freeglut/freeglut-2.8.1-r2.ebuild
> > >similarity index 55%
> > >copy from gx86/media-libs/freeglut/freeglut-2.8.1.ebuild
> > >copy to gx86/media-libs/freeglut/freeglut-2.8.1-r2.ebuild
> > >index c622a32..c87e3bb 100644
> > [...]
> > >-	find "${ED}" -name '*.la' -exec rm -f {} +
> > 
> > I'd add a AUTOTOOLS_PRUNE_LIBTOOL_FILES=all to replace this but not my call
> 
> Hmm, but glut doesn't provide a pkg-config file, so removing .la is
> incorrect. We should either keep it, or drop USE=static-libs.

this is another debate: .la helps packages built with libtool to do static linking, those that don't use libtool get nothing from it. if the .la is already gone and nobody complained i'd say it's not worth reintroducing it.

btw, it is a bit hacky but I've made libcxx achieve proper static linking without .la nor .pc by using ldscripts :)

> > >diff --git a/gx86/media-libs/mesa/mesa-9.1.6.ebuild b/gx86/media-libs/mesa/mesa-9.1.6-r1.ebuild
> > >similarity index 88%
> > >copy from gx86/media-libs/mesa/mesa-9.1.6.ebuild
> > >copy to gx86/media-libs/mesa/mesa-9.1.6-r1.ebuild
> > [...]
> > > DEPEND="${RDEPEND}
> > > 	llvm? (
> > >-		>=sys-devel/llvm-2.9
> > >+		~sys-devel/llvm-3.3[${MULTILIB_USEDEP}]
> > 
> > why the ~ ?
> 
> It doesn't work with llvm-9999 (going to be 3.4). And since older versions
> don't do multilib, I've decided to just put 3.3.

ok

would it be worth adding a := here too ?
Comment 9 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2013-08-13 17:09:22 UTC
(In reply to Alexis Ballier from comment #8)
> > > >diff --git a/gx86/media-libs/freeglut/freeglut-2.8.1.ebuild b/gx86/media-libs/freeglut/freeglut-2.8.1-r2.ebuild
> > > >similarity index 55%
> > > >copy from gx86/media-libs/freeglut/freeglut-2.8.1.ebuild
> > > >copy to gx86/media-libs/freeglut/freeglut-2.8.1-r2.ebuild
> > > >index c622a32..c87e3bb 100644
> > > [...]
> > > >-	find "${ED}" -name '*.la' -exec rm -f {} +
> > > 
> > > I'd add a AUTOTOOLS_PRUNE_LIBTOOL_FILES=all to replace this but not my call
> > 
> > Hmm, but glut doesn't provide a pkg-config file, so removing .la is
> > incorrect. We should either keep it, or drop USE=static-libs.
> 
> this is another debate: .la helps packages built with libtool to do static
> linking, those that don't use libtool get nothing from it. if the .la is
> already gone and nobody complained i'd say it's not worth reintroducing it.

Well, it just proves that people are introducing USE=static-libs and nobody is using it.

> btw, it is a bit hacky but I've made libcxx achieve proper static linking
> without .la nor .pc by using ldscripts :)

That's just replacing one hack with another. You could also make linker use .la files, net result would be the same.

> > > >diff --git a/gx86/media-libs/mesa/mesa-9.1.6.ebuild b/gx86/media-libs/mesa/mesa-9.1.6-r1.ebuild
> > > >similarity index 88%
> > > >copy from gx86/media-libs/mesa/mesa-9.1.6.ebuild
> > > >copy to gx86/media-libs/mesa/mesa-9.1.6-r1.ebuild
> > > [...]
> > > > DEPEND="${RDEPEND}
> > > > 	llvm? (
> > > >-		>=sys-devel/llvm-2.9
> > > >+		~sys-devel/llvm-3.3[${MULTILIB_USEDEP}]
> > > 
> > > why the ~ ?
> > 
> > It doesn't work with llvm-9999 (going to be 3.4). And since older versions
> > don't do multilib, I've decided to just put 3.3.
> 
> ok
> 
> would it be worth adding a := here too ?

llvm doesn't have subslots at the time. It might be worth adding them, though. But that's another story.
Comment 10 Alexis Ballier gentoo-dev 2013-08-13 17:22:40 UTC
> > > Hmm, but glut doesn't provide a pkg-config file, so removing .la is
> > > incorrect. We should either keep it, or drop USE=static-libs.
> > 
> > this is another debate: .la helps packages built with libtool to do static
> > linking, those that don't use libtool get nothing from it. if the .la is
> > already gone and nobody complained i'd say it's not worth reintroducing it.
> 
> Well, it just proves that people are introducing USE=static-libs and nobody
> is using it.

Or are just manually adding the dependent libs

> > btw, it is a bit hacky but I've made libcxx achieve proper static linking
> > without .la nor .pc by using ldscripts :)
> 
> That's just replacing one hack with another. You could also make linker use
> .la files, net result would be the same.

except it doesn't use .la but groks linker scripts and linker script are not as contagious as .la files :)

linker scripts are more complex to generate and i dont think its something to be done for glut, so it's useless debating it here; i was just pointing out that the .pc argument for .la files does not really stand
Comment 11 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2013-08-16 10:28:54 UTC
@x11: ping. We'd like to set up some deadline for reviewing and committing this. Would you like us to do something specific?

@Pacho: do you have a Prefix setup maybe? I think chithead wanted to have those changes tested on Prefix.
Comment 12 Pacho Ramos gentoo-dev 2013-08-16 11:25:30 UTC
I don't have a prefix setup :(, but usually CCing prefix team work (or pinging grobian)
Comment 13 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2013-08-16 11:30:04 UTC
@Prefix, could you test if these changes don't break anything for you, please?
Comment 14 Jonathan Callen (RETIRED) gentoo-dev 2013-08-18 06:53:38 UTC
I just tested these changes in a new minimal prefix, and everything appears to buld correctly.  Note that prefix does *not* have any sort of multilib support in it (prefix/linux/amd64 inherits from a no-multilib profile).
Comment 15 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2013-08-24 18:24:47 UTC
*** Bug 473462 has been marked as a duplicate of this bug. ***
Comment 16 Johannes Hirte 2013-08-26 17:09:44 UTC
When will app-emulation/emul-linux-x86-opengl updated and don't block x11-libs/libdrm and media-libs/mesa anymore?
Comment 17 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2013-09-16 16:17:11 UTC
Created attachment 358806 [details, diff]
Rebased & updated patch
Comment 18 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2013-09-16 16:18:53 UTC
The same commits can be also found in my weird git repo [1].

[1]:https://bitbucket.org/mgorny/gx86-working-tree/commits/branch/opengl-multilib-r1
Comment 19 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2013-09-16 22:37:17 UTC
If x11 doesn't review this until then, I will commit it on the weekend.
Comment 20 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2013-09-21 17:13:32 UTC
Committed now.