Index: gyp/zlib.gyp |
diff --git a/gyp/zlib.gyp b/gyp/zlib.gyp |
index a573dc7498d970d83f7e35848ba709aa823cb976..e2424db38999ddf0c1182eb8e216565a5afd4956 100644 |
--- a/gyp/zlib.gyp |
+++ b/gyp/zlib.gyp |
@@ -7,10 +7,15 @@ |
'targets': [{ |
'target_name': 'zlib', |
'type': 'none', |
- 'link_settings': { 'libraries': [ '-lz' ] }, |
'direct_dependent_settings': { |
'conditions': [ |
- [ 'skia_android_framework', { 'include_dirs': [ 'external/zlib' ] }] |
+ [ 'skia_android_framework', { 'include_dirs': [ 'external/zlib' ] }], |
+ [ 'skia_os == "mac" or skia_os == "ios"', { |
+ # XCode needs and explicit file path, not a logical name like -lz. |
+ 'link_settings': { 'libraries': [ '$(SDKROOT)/usr/lib/libz.dylib' ] }, |
+ },{ |
+ 'link_settings': { 'libraries': [ '-lz' ] }, |
+ }] |
], |
}, |
}], |