summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLuciano Dittgen <luciano.dittgen@ossystems.com.br>2026-09-08 14:02:39 -0300
committerLuciano Dittgen <luciano.dittgen@ossystems.com.br>2026-09-10 14:12:25 -0300
commit03fd74d1a1fa5ced07f1ffc9be767224080a5423 (patch)
tree33ddf0ab698efa3ad0ed48b82b847ddc045ab785
parent4fa9dbf1984f71adc6f5e8991b516eb0aaa8ce99 (diff)
downloadmeta-freescale-03fd74d1a1fa5ced07f1ffc9be767224080a5423.tar.gz
imx-gpu-viv: Replace the packaging python with static assignments
Both loops ran over a fixed set, so parse-time code was never needed. insane.bbclass unions INSANE_SKIP with INSANE_SKIP:<pkg>, so one global "ldflags" replaces the per-package appends exactly. Dropped the libgles3-imx names: only libgles3-imx-dev is a package, so they were never read; grouped by variable, not by package. Tested with bitbake imx-gpu-viv on imx8mp-lpddr4-evk; buildhistory reports no change. Signed-off-by: Luciano Dittgen <luciano.dittgen@ossystems.com.br>
-rw-r--r--recipes-graphics/imx-gpu-viv/imx-gpu-viv-6.inc75
1 files changed, 47 insertions, 28 deletions
diff --git a/recipes-graphics/imx-gpu-viv/imx-gpu-viv-6.inc b/recipes-graphics/imx-gpu-viv/imx-gpu-viv-6.inc
index 5827a9db3..05caa0901 100644
--- a/recipes-graphics/imx-gpu-viv/imx-gpu-viv-6.inc
+++ b/recipes-graphics/imx-gpu-viv/imx-gpu-viv-6.inc
@@ -75,7 +75,8 @@ PACKAGECONFIG ?= ""
75# Enables valgrind annotations for libgal-imx 75# Enables valgrind annotations for libgal-imx
76PACKAGECONFIG[valgrind] = "" 76PACKAGECONFIG[valgrind] = ""
77 77
78# Note : If you add a package here, to prevent a naming conflict see the python_anonymous() futher below 78# Note: if you add a package here, see the Debian-rename block at the end of
79# this file to prevent a naming conflict.
79PACKAGES =+ "\ 80PACKAGES =+ "\
80 libgles1-imx libgles1-imx-dev \ 81 libgles1-imx libgles1-imx-dev \
81 libgles2-imx libgles2-imx-dev \ 82 libgles2-imx libgles2-imx-dev \
@@ -136,33 +137,10 @@ INHIBIT_SYSROOT_STRIP = "1"
136REALSOLIBS := "${SOLIBS}" 137REALSOLIBS := "${SOLIBS}"
137SOLIBS = "${SOLIBSDEV}" 138SOLIBS = "${SOLIBSDEV}"
138 139
139python __anonymous() { 140# FIXME: All binaries lack GNU_HASH in elf binary but as we don't have
140 # FIXME: All binaries lack GNU_HASH in elf binary but as we don't have 141# the source we cannot fix it. Disable the insane check for now.
141 # the source we cannot fix it. Disable the insane check for now. 142# nooelint: oelint.vars.insaneskip
142 packages = d.getVar('PACKAGES').split() 143INSANE_SKIP += "ldflags"
143 for p in packages:
144 d.appendVar("INSANE_SKIP:%s" % p, " ldflags")
145
146 # For the packages that make up the OpenGL interfaces, inject variables so that
147 # they don't get Debian-renamed (which would remove the -imx suffix).
148 for p in (("libegl", "libegl1"),
149 ("libgles1", "libglesv1-cm1"), ("libgles2", "libglesv2-2"),
150 ("libgles3",), ("libgbm",)):
151 fullp = p[0] + "-imx"
152 pkgs = "".join(' %s' % i for i in p)
153 d.setVar("DEBIAN_NOAUTONAME:" + fullp, "1")
154 d.appendVar("RREPLACES:" + fullp, pkgs)
155 d.appendVar("RPROVIDES:" + fullp, pkgs)
156 d.appendVar("RCONFLICTS:" + fullp, pkgs)
157
158 # For -dev, the first element is both the Debian and original name
159 fullp += "-dev"
160 pkgs = " " + p[0] + "-dev"
161 d.setVar("DEBIAN_NOAUTONAME:" + fullp, "1")
162 d.appendVar("RREPLACES:" + fullp, pkgs)
163 d.appendVar("RPROVIDES:" + fullp, pkgs)
164 d.appendVar("RCONFLICTS:" + fullp, pkgs)
165}
166 144
167IS_MX6SL = "0" 145IS_MX6SL = "0"
168IS_MX6SL:mx6sl-nxp-bsp = "1" 146IS_MX6SL:mx6sl-nxp-bsp = "1"
@@ -432,3 +410,44 @@ FILES:libnn-imx += "${libdir}/libNN*${SOLIBS}"
432# nooelint: oelint.vars.insaneskip 410# nooelint: oelint.vars.insaneskip
433INSANE_SKIP:append:libc-musl = " file-rdeps" 411INSANE_SKIP:append:libc-musl = " file-rdeps"
434 412
413# The OpenGL interface packages keep their -imx suffix: Debian renaming would
414# drop it and collide with the generic mesa package names.
415DEBIAN_NOAUTONAME:libegl-imx = "1"
416DEBIAN_NOAUTONAME:libegl-imx-dev = "1"
417DEBIAN_NOAUTONAME:libgles1-imx = "1"
418DEBIAN_NOAUTONAME:libgles1-imx-dev = "1"
419DEBIAN_NOAUTONAME:libgles2-imx = "1"
420DEBIAN_NOAUTONAME:libgles2-imx-dev = "1"
421DEBIAN_NOAUTONAME:libgles3-imx-dev = "1"
422DEBIAN_NOAUTONAME:libgbm-imx = "1"
423DEBIAN_NOAUTONAME:libgbm-imx-dev = "1"
424
425RREPLACES:libegl-imx += "libegl libegl1"
426RREPLACES:libegl-imx-dev += "libegl-dev"
427RREPLACES:libgles1-imx += "libgles1 libglesv1-cm1"
428RREPLACES:libgles1-imx-dev += "libgles1-dev"
429RREPLACES:libgles2-imx += "libgles2 libglesv2-2"
430RREPLACES:libgles2-imx-dev += "libgles2-dev"
431RREPLACES:libgles3-imx-dev += "libgles3-dev"
432RREPLACES:libgbm-imx += "libgbm"
433RREPLACES:libgbm-imx-dev += "libgbm-dev"
434
435RPROVIDES:libegl-imx += "libegl libegl1"
436RPROVIDES:libegl-imx-dev += "libegl-dev"
437RPROVIDES:libgles1-imx += "libgles1 libglesv1-cm1"
438RPROVIDES:libgles1-imx-dev += "libgles1-dev"
439RPROVIDES:libgles2-imx += "libgles2 libglesv2-2"
440RPROVIDES:libgles2-imx-dev += "libgles2-dev"
441RPROVIDES:libgles3-imx-dev += "libgles3-dev"
442RPROVIDES:libgbm-imx += "libgbm"
443RPROVIDES:libgbm-imx-dev += "libgbm-dev"
444
445RCONFLICTS:libegl-imx += "libegl libegl1"
446RCONFLICTS:libegl-imx-dev += "libegl-dev"
447RCONFLICTS:libgles1-imx += "libgles1 libglesv1-cm1"
448RCONFLICTS:libgles1-imx-dev += "libgles1-dev"
449RCONFLICTS:libgles2-imx += "libgles2 libglesv2-2"
450RCONFLICTS:libgles2-imx-dev += "libgles2-dev"
451RCONFLICTS:libgles3-imx-dev += "libgles3-dev"
452RCONFLICTS:libgbm-imx += "libgbm"
453RCONFLICTS:libgbm-imx-dev += "libgbm-dev"