OLD | NEW |
---|---|
1 # Copyright 2015 Google Inc. | |
2 # | |
3 # Use of this source code is governed by a BSD-style license that can be | |
4 # found in the LICENSE file. | |
5 | |
1 # This GYP file stores the dependencies necessary to build Skia on the Android | 6 # This GYP file stores the dependencies necessary to build Skia on the Android |
2 # platform. The OS doesn't provide many stable libraries as part of the | 7 # platform. The OS doesn't provide many stable libraries as part of the |
3 # distribution so we have to build a few of them ourselves. | 8 # distribution so we have to build a few of them ourselves. |
4 # | 9 # |
5 # NOTE: We tried adding the gyp file to the android/ directory at the root of | 10 # NOTE: We tried adding the gyp file to the android/ directory at the root of |
6 # the Skia repo, but that resulted in the generated makefiles being created | 11 # the Skia repo, but that resulted in the generated makefiles being created |
7 # outside of the out directory. We may be able to move the bulk of this gyp | 12 # outside of the out directory. We may be able to move the bulk of this gyp |
8 # to the /android directory and put a simple shim here, but that has yet to be | 13 # to the /android directory and put a simple shim here, but that has yet to be |
9 # tested. | 14 # tested. |
10 | 15 |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
48 'defines': [ | 53 'defines': [ |
49 'HAVE_EXPAT_CONFIG_H', | 54 'HAVE_EXPAT_CONFIG_H', |
50 ], | 55 ], |
51 'direct_dependent_settings': { | 56 'direct_dependent_settings': { |
52 'include_dirs': [ | 57 'include_dirs': [ |
53 '../third_party/externals/expat/lib', # For expat.h | 58 '../third_party/externals/expat/lib', # For expat.h |
54 ], | 59 ], |
55 } | 60 } |
56 }, | 61 }, |
57 { | 62 { |
58 'target_name': 'gif', | |
59 'type': 'static_library', | |
60 'sources': [ | |
61 '../third_party/externals/gif/dgif_lib.c', | |
62 '../third_party/externals/gif/gifalloc.c', | |
63 '../third_party/externals/gif/gif_err.c', | |
64 ], | |
65 'include_dirs': [ | |
66 '../third_party/externals/gif', | |
67 ], | |
68 'cflags': [ | |
69 '-w', | |
70 '-DHAVE_CONFIG_H', | |
71 ], | |
72 'direct_dependent_settings': { | |
73 'include_dirs': [ | |
74 '../third_party/externals/gif', | |
75 ], | |
76 } | |
77 }, | |
78 { | |
79 'target_name': 'png', | 63 'target_name': 'png', |
80 'type': 'static_library', | 64 'type': 'static_library', |
65 'conditions': [ | |
djsollen
2015/03/27 14:23:28
as a style note we usually put the conditions afte
msarett
2015/03/27 14:47:29
Done.
| |
66 [ 'arm_neon == 1', | |
djsollen
2015/03/27 14:23:28
need to add -DPNG_ARM_NEON_OPT=2
msarett
2015/03/27 14:47:28
Thanks!
| |
67 { | |
68 'sources' : [ | |
69 '../third_party/externals/png/arm/arm_init.c', | |
70 '../third_party/externals/png/arm/filter_neon.S', | |
71 '../third_party/externals/png/arm/filter_neon_intrinsics.c', | |
72 ] | |
73 }, | |
74 ], | |
75 ], | |
81 'sources': [ | 76 'sources': [ |
82 '../third_party/externals/png/png.c', | 77 '../third_party/externals/png/png.c', |
83 '../third_party/externals/png/pngerror.c', | 78 '../third_party/externals/png/pngerror.c', |
84 '../third_party/externals/png/pnggccrd.c', | |
85 '../third_party/externals/png/pngget.c', | 79 '../third_party/externals/png/pngget.c', |
86 '../third_party/externals/png/pngmem.c', | 80 '../third_party/externals/png/pngmem.c', |
87 '../third_party/externals/png/pngpread.c', | 81 '../third_party/externals/png/pngpread.c', |
88 '../third_party/externals/png/pngread.c', | 82 '../third_party/externals/png/pngread.c', |
89 '../third_party/externals/png/pngrio.c', | 83 '../third_party/externals/png/pngrio.c', |
90 '../third_party/externals/png/pngrtran.c', | 84 '../third_party/externals/png/pngrtran.c', |
91 '../third_party/externals/png/pngrutil.c', | 85 '../third_party/externals/png/pngrutil.c', |
92 '../third_party/externals/png/pngset.c', | 86 '../third_party/externals/png/pngset.c', |
93 '../third_party/externals/png/pngtrans.c', | 87 '../third_party/externals/png/pngtrans.c', |
94 '../third_party/externals/png/pngvcrd.c', | |
95 '../third_party/externals/png/pngwio.c', | 88 '../third_party/externals/png/pngwio.c', |
96 '../third_party/externals/png/pngwrite.c', | 89 '../third_party/externals/png/pngwrite.c', |
97 '../third_party/externals/png/pngwtran.c', | 90 '../third_party/externals/png/pngwtran.c', |
98 '../third_party/externals/png/pngwutil.c', | 91 '../third_party/externals/png/pngwutil.c', |
99 ], | 92 ], |
100 'include_dirs': [ | 93 'include_dirs': [ |
101 '../third_party/externals/png', | 94 '../third_party/externals/png', |
102 ], | 95 ], |
103 'cflags': [ | 96 'cflags': [ |
104 '-w', | 97 '-w', |
105 '-fvisibility=hidden', | 98 '-fvisibility=hidden', |
106 ], | 99 ], |
107 'link_settings': { | 100 'link_settings': { |
108 'libraries': [ | 101 'libraries': [ |
109 '-lz', | 102 '-lz', |
110 ], | 103 ], |
111 }, | 104 }, |
112 'direct_dependent_settings': { | 105 'direct_dependent_settings': { |
113 'include_dirs': [ | 106 'include_dirs': [ |
114 '../third_party/externals/png', | 107 '../third_party/externals/png', |
115 ], | 108 ], |
116 } | 109 } |
117 }, | 110 }, |
118 { | 111 { |
119 'target_name': 'jpeg', | 112 'target_name': 'jpeg', |
120 'type': 'static_library', | 113 'type': 'static_library', |
114 'conditions': [ | |
115 [ 'arm_neon == 1', | |
116 { | |
117 'sources' : [ | |
djsollen
2015/03/27 14:23:28
-DNV_ARM_NEON
msarett
2015/03/27 14:47:29
Done.
| |
118 '../third_party/externals/jpeg/armv6_idct.S', | |
119 '../third_party/externals/jpeg/jsimd_arm_neon.S', | |
120 '../third_party/externals/jpeg/jsimd_neon.c', | |
121 ] | |
122 }, | |
123 ], | |
124 [ 'skia_arch_type == "mips" and mips_dsp == 2', | |
djsollen
2015/03/27 14:23:28
-DANDROID_MIPS_IDCT
msarett
2015/03/27 14:47:29
Done.
| |
125 { | |
126 'sources' : [ | |
127 '../third_party/externals/jpeg/mips_jidctfst.c', | |
128 '../third_party/externals/jpeg/mips_idct_le.S', | |
129 ] | |
130 }, | |
131 ], | |
132 [ '"x86" in skia_arch_type', | |
133 { | |
134 'sources' : [ | |
djsollen
2015/03/27 14:23:28
-DANDROID_INTELSSE2_IDCT
msarett
2015/03/27 14:47:29
Done.
| |
135 '../third_party/externals/jpeg/jidctintelsse.c', | |
136 ] | |
137 }, | |
138 ], | |
139 ], | |
121 'sources': [ | 140 'sources': [ |
122 '../third_party/externals/jpeg/jcapimin.c', | 141 '../third_party/externals/jpeg/jcapimin.c', |
123 '../third_party/externals/jpeg/jcapistd.c', | 142 '../third_party/externals/jpeg/jcapistd.c', |
124 '../third_party/externals/jpeg/jccoefct.c', | 143 '../third_party/externals/jpeg/jccoefct.c', |
125 '../third_party/externals/jpeg/jccolor.c', | 144 '../third_party/externals/jpeg/jccolor.c', |
126 '../third_party/externals/jpeg/jcdctmgr.c', | 145 '../third_party/externals/jpeg/jcdctmgr.c', |
127 '../third_party/externals/jpeg/jchuff.c', | 146 '../third_party/externals/jpeg/jchuff.c', |
128 '../third_party/externals/jpeg/jcinit.c', | 147 '../third_party/externals/jpeg/jcinit.c', |
129 '../third_party/externals/jpeg/jcmainct.c', | 148 '../third_party/externals/jpeg/jcmainct.c', |
130 '../third_party/externals/jpeg/jcmarker.c', | 149 '../third_party/externals/jpeg/jcmarker.c', |
(...skipping 22 matching lines...) Expand all Loading... | |
153 '../third_party/externals/jpeg/jdsample.c', | 172 '../third_party/externals/jpeg/jdsample.c', |
154 '../third_party/externals/jpeg/jdtrans.c', | 173 '../third_party/externals/jpeg/jdtrans.c', |
155 '../third_party/externals/jpeg/jerror.c', | 174 '../third_party/externals/jpeg/jerror.c', |
156 '../third_party/externals/jpeg/jfdctflt.c', | 175 '../third_party/externals/jpeg/jfdctflt.c', |
157 '../third_party/externals/jpeg/jfdctfst.c', | 176 '../third_party/externals/jpeg/jfdctfst.c', |
158 '../third_party/externals/jpeg/jfdctint.c', | 177 '../third_party/externals/jpeg/jfdctint.c', |
159 '../third_party/externals/jpeg/jidctflt.c', | 178 '../third_party/externals/jpeg/jidctflt.c', |
160 '../third_party/externals/jpeg/jidctfst.c', | 179 '../third_party/externals/jpeg/jidctfst.c', |
161 '../third_party/externals/jpeg/jidctint.c', | 180 '../third_party/externals/jpeg/jidctint.c', |
162 '../third_party/externals/jpeg/jidctred.c', | 181 '../third_party/externals/jpeg/jidctred.c', |
182 '../third_party/externals/jpeg/jmem-android.c', | |
183 '../third_party/externals/jpeg/jmemmgr.c', | |
163 '../third_party/externals/jpeg/jquant1.c', | 184 '../third_party/externals/jpeg/jquant1.c', |
164 '../third_party/externals/jpeg/jquant2.c', | 185 '../third_party/externals/jpeg/jquant2.c', |
165 '../third_party/externals/jpeg/jutils.c', | 186 '../third_party/externals/jpeg/jutils.c', |
166 '../third_party/externals/jpeg/jmemmgr.c', | |
167 '../third_party/externals/jpeg/jmem-android.c', # ashmem is also availab le | |
168 ], | 187 ], |
169 'include_dirs': [ | 188 'include_dirs': [ |
170 '../third_party/externals/jpeg', | 189 '../third_party/externals/jpeg', |
171 ], | 190 ], |
172 'cflags': [ | 191 'cflags': [ |
173 '-w', | 192 '-w', |
174 '-fvisibility=hidden', | 193 '-fvisibility=hidden', |
175 '-DAVOID_TABLES', | 194 '-DAVOID_TABLES', |
176 '-O3', | 195 '-O3', |
177 '-fstrict-aliasing', | 196 '-fstrict-aliasing', |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
235 }], | 254 }], |
236 ], | 255 ], |
237 'sources': [ | 256 'sources': [ |
238 '../app/jni/com_skia_SkiaSampleRenderer.cpp', | 257 '../app/jni/com_skia_SkiaSampleRenderer.cpp', |
239 ], | 258 ], |
240 }, | 259 }, |
241 | 260 |
242 }, | 261 }, |
243 ] | 262 ] |
244 } | 263 } |
OLD | NEW |