Torne (Richard Coles) | 2a99a7e | 2013-03-28 15:31:22 +0000 | [diff] [blame] | 1 | # This file is generated by gyp; do not edit. |
| 2 | |
| 3 | include $(CLEAR_VARS) |
| 4 | |
| 5 | LOCAL_MODULE_CLASS := STATIC_LIBRARIES |
| 6 | LOCAL_MODULE := third_party_libwebp_libwebp_enc_gyp |
| 7 | LOCAL_MODULE_SUFFIX := .a |
| 8 | LOCAL_MODULE_TAGS := optional |
| 9 | gyp_intermediate_dir := $(call local-intermediates-dir) |
| 10 | gyp_shared_intermediate_dir := $(call intermediates-dir-for,GYP,shared) |
| 11 | |
| 12 | # Make sure our deps are built first. |
| 13 | GYP_TARGET_DEPENDENCIES := |
| 14 | |
| 15 | GYP_GENERATED_OUTPUTS := |
| 16 | |
| 17 | # Make sure our deps and generated files are built first. |
| 18 | LOCAL_ADDITIONAL_DEPENDENCIES := $(GYP_TARGET_DEPENDENCIES) $(GYP_GENERATED_OUTPUTS) |
| 19 | |
| 20 | LOCAL_GENERATED_SOURCES := |
| 21 | |
| 22 | GYP_COPIED_SOURCE_ORIGIN_DIRS := |
| 23 | |
| 24 | LOCAL_SRC_FILES := \ |
| 25 | third_party/libwebp/enc/alpha.c \ |
| 26 | third_party/libwebp/enc/analysis.c \ |
| 27 | third_party/libwebp/enc/backward_references.c \ |
| 28 | third_party/libwebp/enc/config.c \ |
| 29 | third_party/libwebp/enc/cost.c \ |
| 30 | third_party/libwebp/enc/filter.c \ |
| 31 | third_party/libwebp/enc/frame.c \ |
| 32 | third_party/libwebp/enc/histogram.c \ |
| 33 | third_party/libwebp/enc/iterator.c \ |
| 34 | third_party/libwebp/enc/layer.c \ |
| 35 | third_party/libwebp/enc/picture.c \ |
| 36 | third_party/libwebp/enc/quant.c \ |
| 37 | third_party/libwebp/enc/syntax.c \ |
| 38 | third_party/libwebp/enc/token.c \ |
| 39 | third_party/libwebp/enc/tree.c \ |
| 40 | third_party/libwebp/enc/vp8l.c \ |
| 41 | third_party/libwebp/enc/webpenc.c |
| 42 | |
| 43 | |
| 44 | # Flags passed to both C and C++ files. |
Ben Murdoch | eb525c5 | 2013-07-10 11:40:50 +0100 | [diff] [blame] | 45 | MY_CFLAGS_Debug := \ |
Torne (Richard Coles) | 2a99a7e | 2013-03-28 15:31:22 +0000 | [diff] [blame] | 46 | --param=ssp-buffer-size=4 \ |
| 47 | -fno-exceptions \ |
| 48 | -fno-strict-aliasing \ |
| 49 | -Wno-unused-parameter \ |
| 50 | -Wno-missing-field-initializers \ |
| 51 | -fvisibility=hidden \ |
| 52 | -pipe \ |
| 53 | -fPIC \ |
| 54 | -Wno-format \ |
| 55 | -m32 \ |
| 56 | -mmmx \ |
| 57 | -march=pentium4 \ |
| 58 | -msse2 \ |
| 59 | -mfpmath=sse \ |
Torne (Richard Coles) | c2e0dbd | 2013-05-09 18:35:53 +0100 | [diff] [blame] | 60 | -fuse-ld=gold \ |
Torne (Richard Coles) | 2a99a7e | 2013-03-28 15:31:22 +0000 | [diff] [blame] | 61 | -ffunction-sections \ |
| 62 | -funwind-tables \ |
| 63 | -g \ |
| 64 | -fno-short-enums \ |
| 65 | -finline-limit=64 \ |
| 66 | -Wa,--noexecstack \ |
| 67 | -U_FORTIFY_SOURCE \ |
| 68 | -Wno-extra \ |
| 69 | -Wno-ignored-qualifiers \ |
| 70 | -Wno-type-limits \ |
| 71 | -Wno-address \ |
| 72 | -Wno-format-security \ |
| 73 | -Wno-return-type \ |
| 74 | -Wno-sequence-point \ |
| 75 | -fno-stack-protector \ |
| 76 | -Os \ |
| 77 | -g \ |
| 78 | -fomit-frame-pointer \ |
| 79 | -fdata-sections \ |
| 80 | -ffunction-sections |
| 81 | |
Ben Murdoch | eb525c5 | 2013-07-10 11:40:50 +0100 | [diff] [blame] | 82 | MY_DEFS_Debug := \ |
Torne (Richard Coles) | 7d4cd47 | 2013-06-19 11:58:07 +0100 | [diff] [blame] | 83 | '-DANGLE_DX11' \ |
Torne (Richard Coles) | 2a99a7e | 2013-03-28 15:31:22 +0000 | [diff] [blame] | 84 | '-D_FILE_OFFSET_BITS=64' \ |
Torne (Richard Coles) | 2a99a7e | 2013-03-28 15:31:22 +0000 | [diff] [blame] | 85 | '-DNO_TCMALLOC' \ |
| 86 | '-DDISABLE_NACL' \ |
| 87 | '-DCHROMIUM_BUILD' \ |
| 88 | '-DUSE_LIBJPEG_TURBO=1' \ |
| 89 | '-DUSE_PROPRIETARY_CODECS' \ |
Ben Murdoch | a3f7b4e | 2013-07-24 10:36:34 +0100 | [diff] [blame] | 90 | '-DENABLE_CONFIGURATION_POLICY' \ |
Torne (Richard Coles) | 1e9bf3e | 2013-10-31 11:16:26 +0000 | [diff] [blame] | 91 | '-DDISCARDABLE_MEMORY_ALWAYS_SUPPORTED_NATIVELY' \ |
| 92 | '-DSYSTEM_NATIVELY_SIGNALS_MEMORY_PRESSURE' \ |
Torne (Richard Coles) | 2a99a7e | 2013-03-28 15:31:22 +0000 | [diff] [blame] | 93 | '-DUSE_OPENSSL=1' \ |
| 94 | '-DENABLE_EGLIMAGE=1' \ |
Torne (Richard Coles) | 58537e2 | 2013-09-12 12:10:22 +0100 | [diff] [blame] | 95 | '-DCLD_VERSION=1' \ |
Torne (Richard Coles) | 2a99a7e | 2013-03-28 15:31:22 +0000 | [diff] [blame] | 96 | '-DANDROID' \ |
| 97 | '-D__GNU_SOURCE=1' \ |
| 98 | '-DUSE_STLPORT=1' \ |
| 99 | '-D_STLP_USE_PTR_SPECIALIZATIONS=1' \ |
| 100 | '-DCHROME_BUILD_ID=""' \ |
| 101 | '-DDYNAMIC_ANNOTATIONS_ENABLED=1' \ |
| 102 | '-DWTF_USE_DYNAMIC_ANNOTATIONS=1' \ |
| 103 | '-D_DEBUG' |
| 104 | |
Torne (Richard Coles) | 2a99a7e | 2013-03-28 15:31:22 +0000 | [diff] [blame] | 105 | |
| 106 | # Include paths placed before CFLAGS/CPPFLAGS |
Ben Murdoch | eb525c5 | 2013-07-10 11:40:50 +0100 | [diff] [blame] | 107 | LOCAL_C_INCLUDES_Debug := \ |
Torne (Richard Coles) | 2a99a7e | 2013-03-28 15:31:22 +0000 | [diff] [blame] | 108 | $(LOCAL_PATH)/third_party/libwebp \ |
Torne (Richard Coles) | 90dce4d | 2013-05-29 14:40:03 +0100 | [diff] [blame] | 109 | $(PWD)/frameworks/wilhelm/include \ |
| 110 | $(PWD)/bionic \ |
| 111 | $(PWD)/external/stlport/stlport |
Torne (Richard Coles) | 2a99a7e | 2013-03-28 15:31:22 +0000 | [diff] [blame] | 112 | |
Torne (Richard Coles) | 2a99a7e | 2013-03-28 15:31:22 +0000 | [diff] [blame] | 113 | |
| 114 | # Flags passed to only C++ (and not C) files. |
Ben Murdoch | eb525c5 | 2013-07-10 11:40:50 +0100 | [diff] [blame] | 115 | LOCAL_CPPFLAGS_Debug := \ |
Torne (Richard Coles) | 2a99a7e | 2013-03-28 15:31:22 +0000 | [diff] [blame] | 116 | -fno-rtti \ |
| 117 | -fno-threadsafe-statics \ |
| 118 | -fvisibility-inlines-hidden \ |
| 119 | -Wno-deprecated \ |
| 120 | -Wno-error=c++0x-compat \ |
| 121 | -Wno-non-virtual-dtor \ |
| 122 | -Wno-sign-promo \ |
| 123 | -Wno-non-virtual-dtor |
| 124 | |
Ben Murdoch | eb525c5 | 2013-07-10 11:40:50 +0100 | [diff] [blame] | 125 | |
| 126 | # Flags passed to both C and C++ files. |
| 127 | MY_CFLAGS_Release := \ |
| 128 | --param=ssp-buffer-size=4 \ |
| 129 | -fno-exceptions \ |
| 130 | -fno-strict-aliasing \ |
| 131 | -Wno-unused-parameter \ |
| 132 | -Wno-missing-field-initializers \ |
| 133 | -fvisibility=hidden \ |
| 134 | -pipe \ |
| 135 | -fPIC \ |
| 136 | -Wno-format \ |
| 137 | -m32 \ |
| 138 | -mmmx \ |
| 139 | -march=pentium4 \ |
| 140 | -msse2 \ |
| 141 | -mfpmath=sse \ |
| 142 | -fuse-ld=gold \ |
| 143 | -ffunction-sections \ |
| 144 | -funwind-tables \ |
| 145 | -g \ |
| 146 | -fno-short-enums \ |
| 147 | -finline-limit=64 \ |
| 148 | -Wa,--noexecstack \ |
| 149 | -U_FORTIFY_SOURCE \ |
| 150 | -Wno-extra \ |
| 151 | -Wno-ignored-qualifiers \ |
| 152 | -Wno-type-limits \ |
| 153 | -Wno-address \ |
| 154 | -Wno-format-security \ |
| 155 | -Wno-return-type \ |
| 156 | -Wno-sequence-point \ |
| 157 | -fno-stack-protector \ |
| 158 | -Os \ |
| 159 | -fno-ident \ |
| 160 | -fdata-sections \ |
| 161 | -ffunction-sections \ |
| 162 | -fomit-frame-pointer \ |
| 163 | -fno-unwind-tables \ |
| 164 | -fno-asynchronous-unwind-tables |
| 165 | |
| 166 | MY_DEFS_Release := \ |
| 167 | '-DANGLE_DX11' \ |
| 168 | '-D_FILE_OFFSET_BITS=64' \ |
Ben Murdoch | eb525c5 | 2013-07-10 11:40:50 +0100 | [diff] [blame] | 169 | '-DNO_TCMALLOC' \ |
| 170 | '-DDISABLE_NACL' \ |
| 171 | '-DCHROMIUM_BUILD' \ |
| 172 | '-DUSE_LIBJPEG_TURBO=1' \ |
| 173 | '-DUSE_PROPRIETARY_CODECS' \ |
Ben Murdoch | a3f7b4e | 2013-07-24 10:36:34 +0100 | [diff] [blame] | 174 | '-DENABLE_CONFIGURATION_POLICY' \ |
Torne (Richard Coles) | 1e9bf3e | 2013-10-31 11:16:26 +0000 | [diff] [blame] | 175 | '-DDISCARDABLE_MEMORY_ALWAYS_SUPPORTED_NATIVELY' \ |
| 176 | '-DSYSTEM_NATIVELY_SIGNALS_MEMORY_PRESSURE' \ |
Ben Murdoch | eb525c5 | 2013-07-10 11:40:50 +0100 | [diff] [blame] | 177 | '-DUSE_OPENSSL=1' \ |
| 178 | '-DENABLE_EGLIMAGE=1' \ |
Torne (Richard Coles) | 58537e2 | 2013-09-12 12:10:22 +0100 | [diff] [blame] | 179 | '-DCLD_VERSION=1' \ |
Ben Murdoch | eb525c5 | 2013-07-10 11:40:50 +0100 | [diff] [blame] | 180 | '-DANDROID' \ |
| 181 | '-D__GNU_SOURCE=1' \ |
| 182 | '-DUSE_STLPORT=1' \ |
| 183 | '-D_STLP_USE_PTR_SPECIALIZATIONS=1' \ |
| 184 | '-DCHROME_BUILD_ID=""' \ |
| 185 | '-DNDEBUG' \ |
| 186 | '-DNVALGRIND' \ |
| 187 | '-DDYNAMIC_ANNOTATIONS_ENABLED=0' |
| 188 | |
| 189 | |
| 190 | # Include paths placed before CFLAGS/CPPFLAGS |
| 191 | LOCAL_C_INCLUDES_Release := \ |
| 192 | $(LOCAL_PATH)/third_party/libwebp \ |
| 193 | $(PWD)/frameworks/wilhelm/include \ |
| 194 | $(PWD)/bionic \ |
| 195 | $(PWD)/external/stlport/stlport |
| 196 | |
| 197 | |
| 198 | # Flags passed to only C++ (and not C) files. |
| 199 | LOCAL_CPPFLAGS_Release := \ |
| 200 | -fno-rtti \ |
| 201 | -fno-threadsafe-statics \ |
| 202 | -fvisibility-inlines-hidden \ |
| 203 | -Wno-deprecated \ |
| 204 | -Wno-error=c++0x-compat \ |
| 205 | -Wno-non-virtual-dtor \ |
| 206 | -Wno-sign-promo \ |
| 207 | -Wno-non-virtual-dtor |
| 208 | |
| 209 | |
| 210 | LOCAL_CFLAGS := $(MY_CFLAGS_$(GYP_CONFIGURATION)) $(MY_DEFS_$(GYP_CONFIGURATION)) |
| 211 | LOCAL_C_INCLUDES := $(GYP_COPIED_SOURCE_ORIGIN_DIRS) $(LOCAL_C_INCLUDES_$(GYP_CONFIGURATION)) |
| 212 | LOCAL_CPPFLAGS := $(LOCAL_CPPFLAGS_$(GYP_CONFIGURATION)) |
Torne (Richard Coles) | 2a99a7e | 2013-03-28 15:31:22 +0000 | [diff] [blame] | 213 | ### Rules for final target. |
| 214 | |
Ben Murdoch | eb525c5 | 2013-07-10 11:40:50 +0100 | [diff] [blame] | 215 | LOCAL_LDFLAGS_Debug := \ |
Torne (Richard Coles) | 2a99a7e | 2013-03-28 15:31:22 +0000 | [diff] [blame] | 216 | -Wl,-z,now \ |
| 217 | -Wl,-z,relro \ |
| 218 | -Wl,-z,noexecstack \ |
| 219 | -fPIC \ |
| 220 | -m32 \ |
Torne (Richard Coles) | c2e0dbd | 2013-05-09 18:35:53 +0100 | [diff] [blame] | 221 | -fuse-ld=gold \ |
Torne (Richard Coles) | 2a99a7e | 2013-03-28 15:31:22 +0000 | [diff] [blame] | 222 | -nostdlib \ |
| 223 | -Wl,--no-undefined \ |
| 224 | -Wl,--exclude-libs=ALL \ |
Torne (Richard Coles) | 58537e2 | 2013-09-12 12:10:22 +0100 | [diff] [blame] | 225 | -Wl,--fatal-warnings \ |
Torne (Richard Coles) | c2e0dbd | 2013-05-09 18:35:53 +0100 | [diff] [blame] | 226 | -Wl,--gc-sections \ |
Torne (Richard Coles) | 58537e2 | 2013-09-12 12:10:22 +0100 | [diff] [blame] | 227 | -Wl,--warn-shared-textrel \ |
Torne (Richard Coles) | 2a99a7e | 2013-03-28 15:31:22 +0000 | [diff] [blame] | 228 | -Wl,-O1 \ |
Torne (Richard Coles) | c2e0dbd | 2013-05-09 18:35:53 +0100 | [diff] [blame] | 229 | -Wl,--as-needed |
Torne (Richard Coles) | 2a99a7e | 2013-03-28 15:31:22 +0000 | [diff] [blame] | 230 | |
| 231 | |
Ben Murdoch | eb525c5 | 2013-07-10 11:40:50 +0100 | [diff] [blame] | 232 | LOCAL_LDFLAGS_Release := \ |
| 233 | -Wl,-z,now \ |
| 234 | -Wl,-z,relro \ |
| 235 | -Wl,-z,noexecstack \ |
| 236 | -fPIC \ |
| 237 | -m32 \ |
| 238 | -fuse-ld=gold \ |
| 239 | -nostdlib \ |
| 240 | -Wl,--no-undefined \ |
| 241 | -Wl,--exclude-libs=ALL \ |
| 242 | -Wl,-O1 \ |
| 243 | -Wl,--as-needed \ |
Torne (Richard Coles) | 58537e2 | 2013-09-12 12:10:22 +0100 | [diff] [blame] | 244 | -Wl,--gc-sections \ |
| 245 | -Wl,--fatal-warnings \ |
| 246 | -Wl,--warn-shared-textrel |
Ben Murdoch | eb525c5 | 2013-07-10 11:40:50 +0100 | [diff] [blame] | 247 | |
| 248 | |
| 249 | LOCAL_LDFLAGS := $(LOCAL_LDFLAGS_$(GYP_CONFIGURATION)) |
| 250 | |
Torne (Richard Coles) | 2a99a7e | 2013-03-28 15:31:22 +0000 | [diff] [blame] | 251 | LOCAL_STATIC_LIBRARIES := |
| 252 | |
| 253 | # Enable grouping to fix circular references |
| 254 | LOCAL_GROUP_STATIC_LIBRARIES := true |
| 255 | |
| 256 | LOCAL_SHARED_LIBRARIES := \ |
| 257 | libstlport \ |
| 258 | libdl |
| 259 | |
| 260 | # Add target alias to "gyp_all_modules" target. |
| 261 | .PHONY: gyp_all_modules |
| 262 | gyp_all_modules: third_party_libwebp_libwebp_enc_gyp |
| 263 | |
| 264 | # Alias gyp target name. |
| 265 | .PHONY: libwebp_enc |
| 266 | libwebp_enc: third_party_libwebp_libwebp_enc_gyp |
| 267 | |
| 268 | include $(BUILD_STATIC_LIBRARY) |