Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(359)

Unified Diff: build/config/linux/pkg_config.gni

Issue 300973003: Add CC to the GN build, work on GPU more (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « build/config/linux/BUILD.gn ('k') | cc/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/config/linux/pkg_config.gni
diff --git a/build/config/linux/pkg_config.gni b/build/config/linux/pkg_config.gni
index c6a3099f1eb856da7d0e99f43e0b4f066096929c..46f7d7590e6dc0af6583d9958e15a0b803fe0e70 100644
--- a/build/config/linux/pkg_config.gni
+++ b/build/config/linux/pkg_config.gni
@@ -20,6 +20,9 @@ import("//build/config/sysroot.gni")
#
# You can also use "extra args" to filter out results (see pkg-config.py):
# extra_args = [ "-v, "foo" ]
+# To ignore libs and ldflags (only cflags/defines will be set, which is useful
+# when doing manual dynamic linking), set:
+# ignore_libs = true
template("pkg_config") {
assert(defined(invoker.packages),
@@ -40,9 +43,12 @@ template("pkg_config") {
args, "value")
include_dirs = pkgresult[0]
cflags = pkgresult[1]
- libs = pkgresult[2]
- lib_dirs = pkgresult[3]
- ldflags = pkgresult[4]
+
+ if (!defined(invoker.ignore_libs) || !invoker.ignore_libs) {
+ libs = pkgresult[2]
+ lib_dirs = pkgresult[3]
+ ldflags = pkgresult[4]
+ }
if (defined(invoker.defines)) {
defines = invoker.defines
« no previous file with comments | « build/config/linux/BUILD.gn ('k') | cc/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698