Index: third_party/libpng/libpng.gyp |
diff --git a/third_party/libpng/libpng.gyp b/third_party/libpng/libpng.gyp |
index 48209b5e40a48b632177d31961af40aab5c57638..321571fb02b096c1ec4ada3d859ab1d82ea48442 100644 |
--- a/third_party/libpng/libpng.gyp |
+++ b/third_party/libpng/libpng.gyp |
@@ -11,18 +11,13 @@ |
], |
'variables': { |
# Upstream uses self-assignment to avoid warnings. |
- 'clang_warning_flags': [ '-Wno-self-assign' ] |
+ 'clang_warning_flags': [ |
+ '-Wno-self-assign', |
Nico
2016/06/03 20:27:45
why does the gn file have that tautological-compar
msarett
2016/06/03 21:26:01
Possibly because we don't have a Windows/clang/gyp
Nico
2016/06/03 21:36:49
Ah, maybe that's the reason. You can send a try jo
msarett
2016/06/06 14:18:15
Sent a tryjob, will follow up on this.
msarett
2016/06/07 20:06:43
The flag is not needed on win_clang_x64_rel. Mayb
|
+ ], |
}, |
- 'defines': [ |
- 'CHROME_PNG_WRITE_SUPPORT', |
- 'PNG_USER_CONFIG', |
- ], |
'sources': [ |
'png.c', |
- 'png.h', |
- 'pngconf.h', |
'pngerror.c', |
- 'pnggccrd.c', |
'pngget.c', |
'pngmem.c', |
'pngpread.c', |
@@ -32,8 +27,6 @@ |
'pngrutil.c', |
'pngset.c', |
'pngtrans.c', |
- 'pngusr.h', |
- 'pngvcrd.c', |
'pngwio.c', |
'pngwrite.c', |
'pngwtran.c', |
@@ -43,10 +36,6 @@ |
'include_dirs': [ |
'.', |
], |
- 'defines': [ |
- 'CHROME_PNG_WRITE_SUPPORT', |
- 'PNG_USER_CONFIG', |
- ], |
}, |
'export_dependent_settings': [ |
'../zlib/zlib.gyp:zlib', |
@@ -54,6 +43,37 @@ |
# TODO(jschuh): http://crbug.com/167187 |
'msvs_disabled_warnings': [ 4267 ], |
'conditions': [ |
+ # Disable ARM optimizations on IOS. Can't find a way to get gyp to even try |
+ # to compile the optimization files. This works fine on GN. |
Nico
2016/06/03 20:27:45
what's the error if you don't do this?
msarett
2016/06/03 21:26:01
Seeing a lot of this on ios_device:
Undefined symb
Nico
2016/06/03 21:36:49
Hm, that sounds like maybe the prefix header isn't
msarett
2016/06/06 14:18:15
What makes you think it's the prefix header? FWIW
msarett
2016/06/07 20:06:43
Filed https://bugs.chromium.org/p/chromium/issues/
|
+ [ 'OS=="ios"', { |
+ 'defines': [ |
+ 'PNG_ARM_NEON_OPT=0', |
+ ], |
+ }], |
+ |
+ # SSE optimizations |
+ [ 'target_arch=="ia32" or target_arch=="x64"', { |
+ 'defines': [ |
+ 'PNG_INTEL_SSE_OPT=1', |
+ ], |
+ 'sources': [ |
+ 'contrib/intel/intel_init.c', |
+ 'contrib/intel/filter_sse2_intrinsics.c', |
+ ], |
+ }], |
+ |
+ # ARM optimizations |
+ [ 'target_arch=="arm" or target_arch=="arm64" and OS!="ios"', { |
+ 'defines': [ |
+ 'PNG_ARM_NEON_OPT=2', |
+ 'PNG_ARM_NEON_IMPLEMENTATION=1', |
+ ], |
+ 'sources': [ |
+ 'arm/arm_init.c', |
+ 'arm/filter_neon_intrinsics.c', |
Nico
2016/06/03 21:36:49
btw, don't you have to add the .S file here?
msarett
2016/06/06 14:18:16
filter_neon_intrinsics.c and filter_neon.S impleme
|
+ ], |
+ }], |
+ |
['OS!="win"', {'product_name': 'png'}], |
['OS=="win"', { |
'type': '<(component)', |
@@ -73,20 +93,8 @@ |
], |
}, |
}], |
- ['OS=="android" or chromecast==1', { |
- 'conditions': [ |
- ['OS=="android"', { |
- 'toolsets': ['target', 'host'], |
- }], |
- ], |
- 'defines': [ |
- 'CHROME_PNG_READ_PACK_SUPPORT', # Required by freetype. |
- ], |
- 'direct_dependent_settings': { |
- 'defines': [ |
- 'CHROME_PNG_READ_PACK_SUPPORT', |
- ], |
- }, |
+ ['OS=="android"', { |
+ 'toolsets': ['target', 'host'], |
Nico
2016/06/03 20:27:45
why is this no longer needed for chromecast==1?
msarett
2016/06/03 21:26:01
If you look closely at the base, these were only e
Nico
2016/06/03 21:36:49
Ah, thanks.
|
}], |
], |
}, |