| Message ID | 20250421090611.3862686-2-yi.zhao@windriver.com |
|---|---|
| State | New |
| Headers | show |
| Series | [1/2] libsass: fix runtime version | expand |
On Mon, 21 Apr 2025 at 11:06, Yi Zhao via lists.openembedded.org <yi.zhao=eng.windriver.com@lists.openembedded.org> wrote: > +do_configure:append() { > + sed -i -e 's/\[NA\]/${PV}/g' ${S}/sassc_version.h > +} This is a generated file (from sassc_version.h.in), so why is it not generated correctly? Should we rather do that? Alex
On 4/22/25 23:44, Alexander Kanavin via lists.openembedded.org wrote: > On Mon, 21 Apr 2025 at 11:06, Yi Zhao via lists.openembedded.org > <yi.zhao=eng.windriver.com@lists.openembedded.org> wrote: > >> +do_configure:append() { >> + sed -i -e 's/\[NA\]/${PV}/g' ${S}/sassc_version.h >> +} > This is a generated file (from sassc_version.h.in), so why is it not > generated correctly? Should we rather do that? There is already a sassc_version.h file with version number [NA] in the source directory. When ${S} != ${B}, the generated sassc_version.h is located in the build directory, and the same file in the source directory is not overwritten. However, the latter is used during build, resulting in version [NA]. Can it be fixed by inheriting autotools-brokensep? Or copy the generated sassc_version.h from ${B} to ${S}after do_configure? //Yi > > Alex > > -=-=-=-=-=-=-=-=-=-=-=- > Links: You receive all messages sent to this group. > View/Reply Online (#215234): https://lists.openembedded.org/g/openembedded-core/message/215234 > Mute This Topic: https://lists.openembedded.org/mt/112372256/7283133 > Group Owner: openembedded-core+owner@lists.openembedded.org > Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [yi.zhao@eng.windriver.com] > -=-=-=-=-=-=-=-=-=-=-=- >
On Wed, 23 Apr 2025 at 14:50, Yi Zhao <yi.zhao@windriver.com> wrote: > There is already a sassc_version.h file with version number [NA] in the > source directory. When ${S} != ${B}, the generated sassc_version.h is > located in the build directory, and the same file in the source > directory is not overwritten. However, the latter is used during build, > resulting in version [NA]. Can it be fixed by inheriting > autotools-brokensep? Or copy the generated sassc_version.h from ${B} to > ${S}after do_configure? I think a better fix is to make a patch that deletes the bogus generated sassc_version.h from the source tree. Normally this patch would be offered upstream, but it looks like this upstream is inactive, so you can mark the patch as Inactive-Upstream [last commit X years ago]. Alex
On 4/23/25 22:59, Alexander Kanavin wrote: > On Wed, 23 Apr 2025 at 14:50, Yi Zhao <yi.zhao@windriver.com> wrote: >> There is already a sassc_version.h file with version number [NA] in the >> source directory. When ${S} != ${B}, the generated sassc_version.h is >> located in the build directory, and the same file in the source >> directory is not overwritten. However, the latter is used during build, >> resulting in version [NA]. Can it be fixed by inheriting >> autotools-brokensep? Or copy the generated sassc_version.h from ${B} to >> ${S}after do_configure? > I think a better fix is to make a patch that deletes the bogus > generated sassc_version.h from the source tree. Normally this patch > would be offered upstream, but it looks like this upstream is > inactive, so you can mark the patch as Inactive-Upstream [last commit > X years ago]. Thanks. I will send v2. //Yi > > Alex
diff --git a/meta/recipes-support/sass/sassc_git.bb b/meta/recipes-support/sass/sassc_git.bb index b7f57ca244..dfc5ee5857 100644 --- a/meta/recipes-support/sass/sassc_git.bb +++ b/meta/recipes-support/sass/sassc_git.bb @@ -12,6 +12,10 @@ SRCREV = "66f0ef37e7f0ad3a65d2f481eff09d09408f42d0" S = "${WORKDIR}/git" PV = "3.6.2" +do_configure:append() { + sed -i -e 's/\[NA\]/${PV}/g' ${S}/sassc_version.h +} + CVE_STATUS[CVE-2022-43357] = "cpe-incorrect: this is CVE for libsass, not sassc wrapper" BBCLASSEXTEND = "native"
Fix sassc runtime version shown in 'sassc --version'. Before the fix: $ sassc --version sassc: [NA] libsass: [NA] sass2scss: 1.1.1 sass: 3.5 After the fix: $ sassc --version sassc: 3.6.2 libsass: 3.6.6 sass2scss: 1.1.1 sass: 3.5 Signed-off-by: Yi Zhao <yi.zhao@windriver.com> --- meta/recipes-support/sass/sassc_git.bb | 4 ++++ 1 file changed, 4 insertions(+)