Message ID | 20250522144605.2876771-6-dmitry.baryshkov@oss.qualcomm.com |
---|---|
State | New |
Headers | show |
Series | [v2,01/12] mesa: remove OSMesa support | expand |
On 5/22/25 16:45, Dmitry Baryshkov via lists.openembedded.org wrote: > The libopencl-mesa package provides OpenCL ICDs (Installable Client > Drivers). As such, there is no conflict between several packages > providing ICDs for different vendors. Split the loop that modifies > package metadata and stop adding extra RPROVIDES / RCONFLICTS / > RREPLACES tags to the libopencl-mesa package. > > Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> > --- > meta/recipes-graphics/mesa/mesa.inc | 15 +++++++++------ > 1 file changed, 9 insertions(+), 6 deletions(-) > > diff --git a/meta/recipes-graphics/mesa/mesa.inc b/meta/recipes-graphics/mesa/mesa.inc > index a309c8023bd2..98860a0d7d15 100644 > --- a/meta/recipes-graphics/mesa/mesa.inc > +++ b/meta/recipes-graphics/mesa/mesa.inc > @@ -264,28 +264,31 @@ do_install:append () { > # RPROVIDEs/RCONFLICTs on the generic libgl name. > python __anonymous() { > pkgconfig = (d.getVar('PACKAGECONFIG') or "").split() > + mlprefix = d.getVar("MLPREFIX") > suffix = "" > if "-native" in d.getVar("PN"): > suffix = "-native" > + > + for p in ("libegl", "libgl", "libglx", "libgles1", "libgles2", "libgles3", "libopencl"): > + fullp = mlprefix + p[1] + "-mesa" + suffix Is it supposed to be "fullp = mlprefix + p...", instead of p[1]? Otherwise it's the same letter "i" over and over again. > + d.appendVar("RRECOMMENDS:" + fullp, " ${MLPREFIX}mesa-megadriver" + suffix) > + > + d.setVar("DEBIAN_NOAUTONAME:%slibopencl-mesa%s" % (mlprefix, suffix), "1") > + > for p in (("egl", "libegl", "libegl1"), > ("opengl", "libgl", "libgl1"), > ("glvnd", "libglx",), > ("gles", "libgles1", "libglesv1-cm1"), > - ("gles", "libgles2", "libglesv2-2", "libgles3"), > - ("opencl", "libopencl",)): > + ("gles", "libgles2", "libglesv2-2", "libgles3")): > if not p[0] in pkgconfig: > continue > - mlprefix = d.getVar("MLPREFIX") > fullp = mlprefix + p[1] + "-mesa" + suffix > - mlprefix = d.getVar("MLPREFIX") > pkgs = " " + " ".join(mlprefix + x + suffix for x in p[1:]) > d.setVar("DEBIAN_NOAUTONAME:" + fullp, "1") > d.appendVar("RREPLACES:" + fullp, pkgs) > d.appendVar("RPROVIDES:" + fullp, pkgs) > d.appendVar("RCONFLICTS:" + fullp, pkgs) > > - d.appendVar("RRECOMMENDS:" + fullp, " ${MLPREFIX}mesa-megadriver" + suffix) > - > # For -dev, the first element is both the Debian and original name > fullp = mlprefix + p[1] + "-mesa-dev" + suffix > pkgs = " " + mlprefix + p[1] + "-dev" + suffix > > -=-=-=-=-=-=-=-=-=-=-=- > Links: You receive all messages sent to this group. > View/Reply Online (#217117): https://lists.openembedded.org/g/openembedded-core/message/217117 > Mute This Topic: https://lists.openembedded.org/mt/113248268/6084445 > Group Owner: openembedded-core+owner@lists.openembedded.org > Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [skandigraun@gmail.com] > -=-=-=-=-=-=-=-=-=-=-=- >
On 22/05/2025 18:01, Gyorgy Sarvari wrote: > > > On 5/22/25 16:45, Dmitry Baryshkov via lists.openembedded.org wrote: >> The libopencl-mesa package provides OpenCL ICDs (Installable Client >> Drivers). As such, there is no conflict between several packages >> providing ICDs for different vendors. Split the loop that modifies >> package metadata and stop adding extra RPROVIDES / RCONFLICTS / >> RREPLACES tags to the libopencl-mesa package. >> >> Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> >> --- >> meta/recipes-graphics/mesa/mesa.inc | 15 +++++++++------ >> 1 file changed, 9 insertions(+), 6 deletions(-) >> >> diff --git a/meta/recipes-graphics/mesa/mesa.inc b/meta/recipes-graphics/mesa/mesa.inc >> index a309c8023bd2..98860a0d7d15 100644 >> --- a/meta/recipes-graphics/mesa/mesa.inc >> +++ b/meta/recipes-graphics/mesa/mesa.inc >> @@ -264,28 +264,31 @@ do_install:append () { >> # RPROVIDEs/RCONFLICTs on the generic libgl name. >> python __anonymous() { >> pkgconfig = (d.getVar('PACKAGECONFIG') or "").split() >> + mlprefix = d.getVar("MLPREFIX") >> suffix = "" >> if "-native" in d.getVar("PN"): >> suffix = "-native" >> + >> + for p in ("libegl", "libgl", "libglx", "libgles1", "libgles2", "libgles3", "libopencl"): >> + fullp = mlprefix + p[1] + "-mesa" + suffix > Is it supposed to be "fullp = mlprefix + p...", instead of p[1]? > Otherwise it's the same letter "i" over and over again. Good catch. Too much refactoring here. >> + d.appendVar("RRECOMMENDS:" + fullp, " ${MLPREFIX}mesa-megadriver" + suffix) >> + >> + d.setVar("DEBIAN_NOAUTONAME:%slibopencl-mesa%s" % (mlprefix, suffix), "1") >> + >> for p in (("egl", "libegl", "libegl1"), >> ("opengl", "libgl", "libgl1"), >> ("glvnd", "libglx",), >> ("gles", "libgles1", "libglesv1-cm1"), >> - ("gles", "libgles2", "libglesv2-2", "libgles3"), >> - ("opencl", "libopencl",)): >> + ("gles", "libgles2", "libglesv2-2", "libgles3")): >> if not p[0] in pkgconfig: >> continue >> - mlprefix = d.getVar("MLPREFIX") >> fullp = mlprefix + p[1] + "-mesa" + suffix >> - mlprefix = d.getVar("MLPREFIX") >> pkgs = " " + " ".join(mlprefix + x + suffix for x in p[1:]) >> d.setVar("DEBIAN_NOAUTONAME:" + fullp, "1") >> d.appendVar("RREPLACES:" + fullp, pkgs) >> d.appendVar("RPROVIDES:" + fullp, pkgs) >> d.appendVar("RCONFLICTS:" + fullp, pkgs) >> >> - d.appendVar("RRECOMMENDS:" + fullp, " ${MLPREFIX}mesa-megadriver" + suffix) >> - >> # For -dev, the first element is both the Debian and original name >> fullp = mlprefix + p[1] + "-mesa-dev" + suffix >> pkgs = " " + mlprefix + p[1] + "-dev" + suffix >> >> -=-=-=-=-=-=-=-=-=-=-=- >> Links: You receive all messages sent to this group. >> View/Reply Online (#217117): https://lists.openembedded.org/g/openembedded-core/message/217117 >> Mute This Topic: https://lists.openembedded.org/mt/113248268/6084445 >> Group Owner: openembedded-core+owner@lists.openembedded.org >> Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [skandigraun@gmail.com] >> -=-=-=-=-=-=-=-=-=-=-=- >> >
diff --git a/meta/recipes-graphics/mesa/mesa.inc b/meta/recipes-graphics/mesa/mesa.inc index a309c8023bd2..98860a0d7d15 100644 --- a/meta/recipes-graphics/mesa/mesa.inc +++ b/meta/recipes-graphics/mesa/mesa.inc @@ -264,28 +264,31 @@ do_install:append () { # RPROVIDEs/RCONFLICTs on the generic libgl name. python __anonymous() { pkgconfig = (d.getVar('PACKAGECONFIG') or "").split() + mlprefix = d.getVar("MLPREFIX") suffix = "" if "-native" in d.getVar("PN"): suffix = "-native" + + for p in ("libegl", "libgl", "libglx", "libgles1", "libgles2", "libgles3", "libopencl"): + fullp = mlprefix + p[1] + "-mesa" + suffix + d.appendVar("RRECOMMENDS:" + fullp, " ${MLPREFIX}mesa-megadriver" + suffix) + + d.setVar("DEBIAN_NOAUTONAME:%slibopencl-mesa%s" % (mlprefix, suffix), "1") + for p in (("egl", "libegl", "libegl1"), ("opengl", "libgl", "libgl1"), ("glvnd", "libglx",), ("gles", "libgles1", "libglesv1-cm1"), - ("gles", "libgles2", "libglesv2-2", "libgles3"), - ("opencl", "libopencl",)): + ("gles", "libgles2", "libglesv2-2", "libgles3")): if not p[0] in pkgconfig: continue - mlprefix = d.getVar("MLPREFIX") fullp = mlprefix + p[1] + "-mesa" + suffix - mlprefix = d.getVar("MLPREFIX") pkgs = " " + " ".join(mlprefix + x + suffix for x in p[1:]) d.setVar("DEBIAN_NOAUTONAME:" + fullp, "1") d.appendVar("RREPLACES:" + fullp, pkgs) d.appendVar("RPROVIDES:" + fullp, pkgs) d.appendVar("RCONFLICTS:" + fullp, pkgs) - d.appendVar("RRECOMMENDS:" + fullp, " ${MLPREFIX}mesa-megadriver" + suffix) - # For -dev, the first element is both the Debian and original name fullp = mlprefix + p[1] + "-mesa-dev" + suffix pkgs = " " + mlprefix + p[1] + "-dev" + suffix
The libopencl-mesa package provides OpenCL ICDs (Installable Client Drivers). As such, there is no conflict between several packages providing ICDs for different vendors. Split the loop that modifies package metadata and stop adding extra RPROVIDES / RCONFLICTS / RREPLACES tags to the libopencl-mesa package. Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> --- meta/recipes-graphics/mesa/mesa.inc | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-)