From: Matt Flax Date: Thu, 16 Aug 2018 22:16:20 +0000 (+1000) Subject: eigen: Fix pkg-config file prefix error X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=e477dc19b5264c8fd01ff235dded4f148fde7a65;p=buildroot.git eigen: Fix pkg-config file prefix error eigen generates a pkg-config file which has a broken prefix (@CMAKE_INSTALL_PREFIX@). This broken prefix causes an incorrect path when other packages call pkg-config --cflags eigen. This patch fixes the prefix in the generated eigen pc file, so projects which depend on this pc file can now correctly find the eigen include directory at build time. Also correct the Cflags output to use the runtime prefix instead of the build time STAGING_DIR, like we do elsewhere. [Peter: drop backslashes, tweak commit message] Signed-off-by: Matt Flax Signed-off-by: Peter Korsgaard --- diff --git a/package/eigen/eigen.mk b/package/eigen/eigen.mk index 89f54fb948..27c4e212a9 100644 --- a/package/eigen/eigen.mk +++ b/package/eigen/eigen.mk @@ -23,7 +23,8 @@ endif # Generate the .pc file at build time define EIGEN_BUILD_CMDS sed -r -e 's,^Version: .*,Version: $(EIGEN_VERSION),' \ - -e 's,^Cflags: .*,Cflags: -I$(EIGEN_DEST_DIR),' \ + -e 's,^Cflags: .*,Cflags: -I$$\{prefix\}/include/eigen3,' \ + -e 's,^prefix.*,prefix=/usr,' \ $(@D)/eigen3.pc.in >$(@D)/eigen3.pc endef