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

Unified Diff: build/linux/system.gyp

Issue 1293073006: Make gtk2/gtk3 compile time switchable. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove deprecation warning. Created 5 years, 4 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/ui.gni ('k') | chrome/browser/ui/libgtk2ui/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/linux/system.gyp
diff --git a/build/linux/system.gyp b/build/linux/system.gyp
index df651fbd7ec16c392d1062f2f9dfebdbf408d29e..9d9ab32e3800551f868ca51de0a0f2f89f6c32c7 100644
--- a/build/linux/system.gyp
+++ b/build/linux/system.gyp
@@ -128,7 +128,7 @@
],
},
{
- 'target_name': 'gtk',
+ 'target_name': 'gtk2',
'type': 'none',
'toolsets': ['host', 'target'],
'variables': {
@@ -169,7 +169,7 @@
],
},
{
- 'target_name': 'gtkprint',
+ 'target_name': 'gtkprint2',
'type': 'none',
'conditions': [
['_toolset=="target"', {
@@ -423,6 +423,74 @@
}
], # targets
}],
+ ['use_gtk3==1', {
+ # Hide GTK3 and related dependencies when use_gtk3==0 because the user
+ # might not have the GTK3 headers yet.
+ 'targets': [
+ {
+ 'target_name': 'gtk3',
+ 'type': 'none',
+ 'toolsets': ['host', 'target'],
+ 'variables': {
+ # gtk requires gmodule, but it does not list it as a dependency
+ # in some misconfigured systems.
+ 'gtk_packages': 'gmodule-2.0 gtk+-3.0 gthread-2.0',
+ },
+ 'conditions': [
+ ['_toolset=="target"', {
+ 'all_dependent_settings': {
+ 'cflags': [
+ '<!@(<(pkg-config) --cflags <(gtk_packages))',
+ ],
+ },
+ 'link_settings': {
+ 'ldflags': [
+ '<!@(<(pkg-config) --libs-only-L --libs-only-other <(gtk_packages))',
+ ],
+ 'libraries': [
+ '<!@(<(pkg-config) --libs-only-l <(gtk_packages))',
+ ],
+ },
+ }, {
+ 'all_dependent_settings': {
+ 'cflags': [
+ '<!@(pkg-config --cflags <(gtk_packages))',
+ ],
+ },
+ 'link_settings': {
+ 'ldflags': [
+ '<!@(pkg-config --libs-only-L --libs-only-other <(gtk_packages))',
+ ],
+ 'libraries': [
+ '<!@(pkg-config --libs-only-l <(gtk_packages))',
+ ],
+ },
+ }],
+ ],
+ },
+ {
+ 'target_name': 'gtkprint3',
+ 'type': 'none',
+ 'conditions': [
+ ['_toolset=="target"', {
+ 'direct_dependent_settings': {
+ 'cflags': [
+ '<!@(<(pkg-config) --cflags gtk+-unix-print-3.0)',
+ ],
+ },
+ 'link_settings': {
+ 'ldflags': [
+ '<!@(<(pkg-config) --libs-only-L --libs-only-other gtk+-unix-print-3.0)',
+ ],
+ 'libraries': [
+ '<!@(<(pkg-config) --libs-only-l gtk+-unix-print-3.0)',
+ ],
+ },
+ }],
+ ],
+ },
+ ],
+ }],
['use_x11==1 and chromeos==0', {
'targets': [
{
« no previous file with comments | « build/config/ui.gni ('k') | chrome/browser/ui/libgtk2ui/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698