OLD | NEW |
1 # Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2009 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 { | 5 { |
6 'variables': { | 6 # This file handles building both with our local libjpeg and with the system |
7 'conditions': [ | 7 # libjpeg. |
8 [ 'os_posix == 1 and OS != "mac"', { | |
9 # Link to system .so since we already use it due to GTK. | |
10 'use_system_libjpeg%': 1, | |
11 }, { # os_posix != 1 or OS == "mac" | |
12 'use_system_libjpeg%': 0, | |
13 }], | |
14 ], | |
15 }, | |
16 'conditions': [ | 8 'conditions': [ |
17 ['use_system_libjpeg==0', { | 9 ['use_system_libjpeg==0', { |
18 'targets': [ | 10 'targets': [ |
19 { | 11 { |
20 'target_name': 'libjpeg', | 12 'target_name': 'libjpeg', |
21 'type': 'static_library', | 13 'type': 'static_library', |
22 'sources': [ | 14 'sources': [ |
23 'jcapimin.c', | 15 'jcapimin.c', |
24 'jcapistd.c', | 16 'jcapistd.c', |
25 'jccoefct.c', | 17 'jccoefct.c', |
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
87 ], | 79 ], |
88 }, { | 80 }, { |
89 'targets': [ | 81 'targets': [ |
90 { | 82 { |
91 'target_name': 'libjpeg', | 83 'target_name': 'libjpeg', |
92 'type': 'none', | 84 'type': 'none', |
93 'direct_dependent_settings': { | 85 'direct_dependent_settings': { |
94 'defines': [ | 86 'defines': [ |
95 'USE_SYSTEM_LIBJPEG', | 87 'USE_SYSTEM_LIBJPEG', |
96 ], | 88 ], |
| 89 'conditions': [ |
| 90 ['os_bsd==1', { |
| 91 'include_dirs': [ |
| 92 '/usr/local/include', |
| 93 ], |
| 94 }], |
| 95 ], |
97 }, | 96 }, |
98 'link_settings': { | 97 'link_settings': { |
99 'libraries': [ | 98 'libraries': [ |
100 '-ljpeg', | 99 '-ljpeg', |
101 ], | 100 ], |
102 }, | 101 }, |
103 } | 102 } |
104 ], | 103 ], |
105 }], | 104 }], |
106 ], | 105 ], |
107 } | 106 } |
OLD | NEW |