From 51a2b0fde9bf635482fd2463b901139c82ed0dc4 Mon Sep 17 00:00:00 2001 From: Mark Brand Date: Thu, 19 Apr 2012 14:48:34 +0200 Subject: fix static library names when generating .pc files for pkgconfig c354d16cc64cf516a0b5149cdc9ef74de096a998 added the version extension which only occurs on the DLL import library. cherry-picked from qt5/qtbase 8e053a5dfc9b4c8f100b1e77335439774f52fc61 Change-Id: Ie913adf039d7f3a9aadf43f4af014289a8aeacbe Reviewed-by: Mark Brand Reviewed-by: Girish Ramakrishnan --- qmake/generators/makefile.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/qmake/generators/makefile.cpp b/qmake/generators/makefile.cpp index 66c6d49..447943a 100644 --- a/qmake/generators/makefile.cpp +++ b/qmake/generators/makefile.cpp @@ -3258,7 +3258,8 @@ MakefileGenerator::writePkgConfigFile() } else { pkgConfiglibDir = "-L${libdir}"; pkgConfiglibName = "-l" + lname.left(lname.length()-Option::libtool_ext.length()); - pkgConfiglibName += project->first("TARGET_VERSION_EXT"); + if (project->isActiveConfig("shared")) + pkgConfiglibName += project->first("TARGET_VERSION_EXT"); } t << pkgConfiglibDir << " " << pkgConfiglibName << " " << endl; -- cgit v0.12