package/xxhash: make sure installed .pc file is correct
PATCH 1/1 package/xxhash: make sure installed .pc file is correct
The libxxhash.pc installed by our xxhash package is incorrect as it contains:
prefix=/usr/local
while the library is installed in /usr. This causes for example a build failure of libplacebo when xxhash is built before:
output/build/libplacebo-v7.360.1/src/meson.build:247:6: ERROR: Include dir /home/thomas/projets/buildroot/output/host/aarch64-buildroot-linux-gnu/sysroot/usr/local/include does not exist.
The problem comes from the fact that the .pc file is generated during the build step from .pc.in template, and we don't pass PREFIX=/usr at the build step. To fix, we pass PREFIX=/usr during the build step, not just during the install step.
The problem has probably existed since we started installing the libxxhash library in commit cc0c90aa83821d817ae2cbe01ad2c8d22ea30ba8 ("package/xxhash: install in staging"), but we tested in 2025.02.x, and the problem exists so this patch should be backported to 2025.02.x.
Fixes:
https://autobuild.buildroot.net/results/344af8504a77ae96e4009d76a77572180cf49b14/
--- package/xxhash/xxhash.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
package/xxhash/xxhash.mk +1 -1
@@ -31,7 +31,7 @@ endif define XXHASH_BUILD_CMDS $(TARGET_MAKE_ENV) $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D) \ - MOREFLAGS=-DXXH_NO_INLINE_HINTS $(XXHASH_TARGETS) + PREFIX=/usr MOREFLAGS=-DXXH_NO_INLINE_HINTS $(XXHASH_TARGETS) endef define XXHASH_INSTALL_STAGING_CMDS
Signature · 6 lines
2.56.0 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Quoted 21 lines · Thomas Petazzoni via buildroot
The libxxhash.pc installed by our xxhash package is incorrect as it contains:
prefix=/usr/local
while the library is installed in /usr. This causes for example a build failure of libplacebo when xxhash is built before:
output/build/libplacebo-v7.360.1/src/meson.build:247:6: ERROR: Include dir
/home/thomas/projets/buildroot/output/host/aarch64-buildroot-linux-gnu/sysroot/usr/local/includedoes not exist.The problem comes from the fact that the .pc file is generated during the build step from .pc.in template, and we don't pass PREFIX=/usr at the build step. To fix, we pass PREFIX=/usr during the build step, not just during the install step.
The problem has probably existed since we started installing the libxxhash library in commit
cc0c90aa83821d817ae2cbe01ad2c8d22ea30ba8("package/xxhash: install in staging"), but we tested in 2025.02.x, and the problem exists so this patch should be backported to 2025.02.x.
Quoted 6 lines
Fixes:
https://autobuild.buildroot.net/results/344af8504a77ae96e4009d76a77572180cf49b14/
Signed-off-by Thomas Petazzoni <[email protected]>
Applied to master, thanks.
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Raphaël Mélotte via buildroot
AppliedIn reply of:
Quoted 21 lines
The libxxhash.pc installed by our xxhash package is incorrect as it contains:
prefix=/usr/local
while the library is installed in /usr. This causes for example a build failure of libplacebo when xxhash is built before:
output/build/libplacebo-v7.360.1/src/meson.build:247:6: ERROR: Include dir
/home/thomas/projets/buildroot/output/host/aarch64-buildroot-linux-gnu/sysroot/usr/local/includedoes not exist.The problem comes from the fact that the .pc file is generated during the build step from .pc.in template, and we don't pass PREFIX=/usr at the build step. To fix, we pass PREFIX=/usr during the build step, not just during the install step.
The problem has probably existed since we started installing the libxxhash library in commit
cc0c90aa83821d817ae2cbe01ad2c8d22ea30ba8("package/xxhash: install in staging"), but we tested in 2025.02.x, and the problem exists so this patch should be backported to 2025.02.x.
Quoted 5 lines
Fixes:
https://autobuild.buildroot.net/results/344af8504a77ae96e4009d76a77572180cf49b14/
Signed-off-by Thomas Petazzoni <[email protected]>
Applied to 2025.02.x, 2026.08.x. Thanks
Quoted 9 lines
--- package/xxhash/xxhash.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)package/xxhash/xxhash.mk +0
-0
package/xxhash/xxhash.mk endif · line 37
Quoted 8 lines
package/xxhash/xxhash.mk +1
-1@@ -31,7 +31,7 @@ endif define XXHASH_BUILD_CMDS $(TARGET_MAKE_ENV) $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D) \ - MOREFLAGS=-DXXH_NO_INLINE_HINTS $(XXHASH_TARGETS) + PREFIX=/usr MOREFLAGS=-DXXH_NO_INLINE_HINTS $(XXHASH_TARGETS) endef define XXHASH_INSTALL_STAGING_CMDS
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot