bloomberg / bde

Basic Development Environment - a set of foundational C++ libraries used at Bloomberg.
Apache License 2.0
1.67k stars 316 forks source link

The installed pkg-config meta-data is wrong when installing anywhere other than /opt/bb #290

Open mattrm456 opened 1 year ago

mattrm456 commented 1 year ago

When I build and install using:

eval $(bde_build_env.py --cpp-std=17 --build-type=Release --build-dir=/tmp/bde --install-dir=/home/my/bde)
cmake_build.py configure
cmake_build.py build
cmake_build.py --install_dir=/home/my/bde --prefix=/ install

The headers and libraries are correctly installed to /home/my/bde but the installed pkg-config meta-data, e.g. /home/my/bde/lib/pkg-config/bdl.pc contains:

prefix=/opt/bb
libdir=${prefix}/lib
includedir=${prefix}/include

Name: bdl
Description: The bdl package.
Version: 3.109.0
Requires:
Requires.private: bsl inteldfp pcre2
Cflags: -I${includedir}
Libs: -L${libdir} -lbdl

That is the prefix is /opt/bb even though that's not what I specified and that's not where the files have been installed.