blob: 8920f6ad4d8aeaaf91bfe5f967426e8aaf988a0d [file] [log] [blame]
scroggo3e562272015-03-25 10:22:41 -07001# 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.
msarett6d0e7b22015-03-30 07:52:52 -07005
scroggo@google.com73e4d572013-05-20 22:15:32 +00006# GYP file for images project.
scroggo@google.com4c6adf92013-04-17 21:07:55 +00007{
epoger@google.comae85aea2011-05-31 13:50:51 +00008 'targets': [
9 {
10 'target_name': 'images',
borenet@google.comefb1d772012-10-10 19:45:51 +000011 'product_name': 'skia_images',
epoger@google.comae85aea2011-05-31 13:50:51 +000012 'type': 'static_library',
borenet@google.comefb1d772012-10-10 19:45:51 +000013 'standalone_static_library': 1,
bungeman@google.com9df621d2011-06-23 21:43:52 +000014 'dependencies': [
bungeman@google.comb8f36552013-07-22 14:39:45 +000015 'core.gyp:*',
msarett6d0e7b22015-03-30 07:52:52 -070016 'giflib.gyp:giflib',
msarettb747b902015-11-06 11:15:49 -080017 'libjpeg-turbo-selector.gyp:libjpeg-turbo-selector',
robertphillips@google.com8cf81e02014-05-22 18:40:29 +000018 'etc1.gyp:libetc1',
krajcevski99ffe242014-06-03 13:04:35 -070019 'ktx.gyp:libSkKTX',
commit-bot@chromium.orga936e372013-03-14 14:42:18 +000020 'libwebp.gyp:libwebp',
bungeman@google.com9df621d2011-06-23 21:43:52 +000021 'utils.gyp:utils',
22 ],
epoger@google.comae85aea2011-05-31 13:50:51 +000023 'include_dirs': [
epoger@google.comae85aea2011-05-31 13:50:51 +000024 '../include/images',
mtkleincd1f2da2015-07-28 08:55:14 -070025 '../include/private',
halcanary@google.comad04eb42013-11-21 15:32:08 +000026 '../src/lazy',
scroggo@google.com39edf4c2013-04-25 17:33:51 +000027 # for access to SkErrorInternals.h
28 '../src/core/',
scroggo@google.comf8d7d272013-02-22 21:38:35 +000029 # for access to SkImagePriv.h
30 '../src/image/',
epoger@google.comae85aea2011-05-31 13:50:51 +000031 ],
32 'sources': [
scroggo@google.com7def5e12013-05-31 14:00:10 +000033 '../include/images/SkForceLinking.h',
epoger@google.comae85aea2011-05-31 13:50:51 +000034 '../include/images/SkMovie.h',
epoger@google.comae85aea2011-05-31 13:50:51 +000035
msarett910f7ec2016-03-24 04:45:39 -070036 '../src/images/SkForceLinking.cpp',
msarettc1d03122016-03-25 08:58:55 -070037 '../src/images/SkMovie_FactoryDefault.cpp',
msarett910f7ec2016-03-24 04:45:39 -070038
msarette8597a42016-03-24 10:41:47 -070039 # If encoders are added/removed to/from (all/individual)
scroggo@google.com7def5e12013-05-31 14:00:10 +000040 # platform(s), be sure to update SkForceLinking.cpp
scroggo@google.comc4ebdb02013-05-01 21:17:27 +000041 # so the right decoders will be forced to link.
scroggo@google.comd4adfa32014-02-05 16:35:12 +000042
msarettc1d03122016-03-25 08:58:55 -070043 '../src/images/SkKTXImageEncoder.cpp',
44 '../src/images/SkWEBPImageEncoder.cpp',
45 '../src/images/SkJPEGImageEncoder.cpp',
46 '../src/images/SkPNGImageEncoder.cpp',
scroggo@google.comd4adfa32014-02-05 16:35:12 +000047
epoger@google.comae85aea2011-05-31 13:50:51 +000048 '../src/images/SkImageEncoder.cpp',
49 '../src/images/SkImageEncoder_Factory.cpp',
msarettc1d03122016-03-25 08:58:55 -070050 '../src/images/SkARGBImageEncoder.cpp',
51 '../src/images/SkJPEGWriteUtility.cpp',
epoger@google.comae85aea2011-05-31 13:50:51 +000052 '../src/images/SkMovie.cpp',
msarettc1d03122016-03-25 08:58:55 -070053 '../src/images/SkGIFMovie.cpp',
bungeman@google.com242bb892011-06-22 20:42:34 +000054
msarettc1d03122016-03-25 08:58:55 -070055 '../src/ports/SkImageEncoder_CG.cpp',
56 '../src/ports/SkImageEncoder_WIC.cpp',
epoger@google.comae85aea2011-05-31 13:50:51 +000057 ],
58 'conditions': [
epoger@google.com8846cb22011-07-01 20:20:07 +000059 [ 'skia_os == "win"', {
epoger@google.comae85aea2011-05-31 13:50:51 +000060 'sources!': [
msarettc1d03122016-03-25 08:58:55 -070061 '../src/images/SkPNGImageEncoder.cpp',
62 '../src/images/SkGIFMovie.cpp',
epoger@google.comae85aea2011-05-31 13:50:51 +000063 ],
msarett6d0e7b22015-03-30 07:52:52 -070064 'dependencies!': [
65 'giflib.gyp:giflib'
66 ],
bsalomon@google.com897e66c2011-11-21 21:04:06 +000067 'link_settings': {
68 'libraries': [
bungeman@google.com24339aa2013-12-02 19:54:33 +000069 '-lwindowscodecs.lib',
bsalomon@google.com897e66c2011-11-21 21:04:06 +000070 ],
71 },
epoger@google.com8846cb22011-07-01 20:20:07 +000072 },{ #else if skia_os != win
bungeman@google.com242bb892011-06-22 20:42:34 +000073 'sources!': [
msarettc1d03122016-03-25 08:58:55 -070074 '../src/ports/SkImageEncoder_WIC.cpp',
bungeman@google.com242bb892011-06-22 20:42:34 +000075 ],
epoger@google.comae85aea2011-05-31 13:50:51 +000076 }],
caryclark@google.com35f5ac92012-09-18 15:41:18 +000077 [ 'skia_os in ["mac", "ios"]', {
epoger@google.comae85aea2011-05-31 13:50:51 +000078 'sources!': [
msarettc1d03122016-03-25 08:58:55 -070079 '../src/images/SkPNGImageEncoder.cpp',
80 '../src/images/SkGIFMovie.cpp',
epoger@google.comae85aea2011-05-31 13:50:51 +000081 ],
epoger@google.com8846cb22011-07-01 20:20:07 +000082 },{ #else if skia_os != mac
bungeman@google.com242bb892011-06-22 20:42:34 +000083 'sources!': [
msarettc1d03122016-03-25 08:58:55 -070084 '../src/ports/SkImageEncoder_CG.cpp',
bungeman@google.com242bb892011-06-22 20:42:34 +000085 ],
epoger@google.comae85aea2011-05-31 13:50:51 +000086 }],
scroggo@google.com3f178282013-04-11 22:24:35 +000087 [ 'skia_os in ["linux", "freebsd", "openbsd", "solaris"]', {
commit-bot@chromium.orgf84722e2014-02-24 20:22:34 +000088 'dependencies': [
89 'libpng.gyp:libpng',
commit-bot@chromium.orgf84722e2014-02-24 20:22:34 +000090 ],
msarett6d0e7b22015-03-30 07:52:52 -070091 # end libpng stuff
epoger@google.comae85aea2011-05-31 13:50:51 +000092 }],
djsollen@google.com58629292011-11-03 13:08:29 +000093 [ 'skia_os == "android"', {
djsollen@google.com528a5562013-02-01 15:57:13 +000094 'include_dirs': [
95 '../src/utils',
djsollen@google.com58629292011-11-03 13:08:29 +000096 ],
msarettb747b902015-11-06 11:15:49 -080097 'dependencies': [
98 'libpng.gyp:libpng',
99 ],
scroggo@google.comd4adfa32014-02-05 16:35:12 +0000100 'conditions': [
msarettb747b902015-11-06 11:15:49 -0800101 [ 'skia_android_framework == 1', {
djsollen38e44b02014-08-28 05:41:21 -0700102 # The android framework disables these decoders as they are of little use to
103 # Java applications that can't take advantage of the compressed formats.
104 'sources!': [
msarettc1d03122016-03-25 08:58:55 -0700105 '../src/images/SkKTXImageEncoder.cpp',
scroggo@google.comd4adfa32014-02-05 16:35:12 +0000106 ],
107 }],
djsollen@google.combcc6d7d2013-07-23 15:51:12 +0000108 ],
djsollen@google.com58629292011-11-03 13:08:29 +0000109 }],
caryclark@google.com35f5ac92012-09-18 15:41:18 +0000110 [ 'skia_os == "ios"', {
111 'include_dirs': [
112 '../include/utils/mac',
113 ],
114 }],
epoger@google.comae85aea2011-05-31 13:50:51 +0000115 ],
116 'direct_dependent_settings': {
117 'include_dirs': [
118 '../include/images',
epoger@google.comae85aea2011-05-31 13:50:51 +0000119 ],
120 },
121 },
122 ],
123}