package/gtest: add and install a .pc file

Signed-off-by: "Yann E. MORIN" <yann.morin@orange.com>
Signed-off-by: Cedric Chedaleux <cedric.chedaleux@orange.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
This commit is contained in:
Yann E. MORIN 2016-06-23 09:09:35 +02:00 committed by Thomas Petazzoni
parent 4dd576b563
commit e9c4497c92
2 changed files with 13 additions and 0 deletions

View File

@ -31,6 +31,8 @@ define GTEST_INSTALL_STAGING_CMDS
$(INSTALL) -D -m 0755 $(@D)/libgtest_main.a $(STAGING_DIR)/usr/lib/libgtest_main.a
$(INSTALL) -d -m 0755 $(STAGING_DIR)/usr/include/gtest/
cp -rp $(@D)/include/gtest/* $(STAGING_DIR)/usr/include/gtest/
$(INSTALL) -D -m 0644 packages/gtest/gtest.pc \
$(STAGING_DIR)/usr/lib/pkgconfig/gtest.pc
# Generate the gtest-config script manually, since the CMake
# build system is not doing it.
sed 's%@PACKAGE_TARNAME@%gtest%;\

11
package/gtest/gtest.pc Normal file
View File

@ -0,0 +1,11 @@
prefix=/usr
exec_prefix=${prefix}
libdir=${prefix}/lib/
includedir=${prefix}/include
Name: gtest
Description: Google C++ Testing Framework
Version: 1.7.0
Libs: -L${libdir} -lgtest
Libs.private: -lpthread
Cflags: -I${includedir}