Only define NO_POSIX_MEMALIGN for arm
authoryujieqin <yujieqin@google.com>
Mon, 1 Feb 2016 10:56:40 +0000 (02:56 -0800)
committerCommit bot <commit-bot@chromium.org>
Mon, 1 Feb 2016 10:56:40 +0000 (02:56 -0800)
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1647893003

Review URL: https://codereview.chromium.org/1647893003

gyp/dng_sdk.gyp

index 1cc254f..d57c730 100644 (file)
@@ -18,9 +18,6 @@
     '-w',
     '-Wframe-larger-than=20000',
     '-DUNIX_ENV=1',
-    
-    # FIXME: only disable ::posix_memalign() when needed.
-    '-DNO_POSIX_MEMALIGN',
   ],
   'headers': [
     '../third_party/externals/dng_sdk/source/RawEnvironment.h',
   'cflags_cc!': [ '-fno-rtti' ],
   'cflags': [ '<@(other_cflags)' ],
   'conditions': [
+    ['skia_os == "android"', {
+      'cflags': [
+        # FIXME: only disable ::posix_memalign() when needed.
+        '-DNO_POSIX_MEMALIGN',
+      ],
+    }],
     ['skia_os == "ios" or skia_os == "mac"', {
       'xcode_settings': {
         'OTHER_CFLAGS': [ '<@(other_cflags)' ],
         'OTHER_CPLUSPLUSFLAGS': [ '<@(other_cflags)' ],
       },
     }],
+    ['skia_os == "win"', {
+      'msvs_settings': {
+        'VCCLCompilerTool': {
+          'WarningLevel': '0',
+          'AdditionalOptions': ['/wd4189', ],
+        },
+      },
+    }],
     ['skia_os != "linux"', {
       'sources': ['<@(headers)'],
     }],
   ],
-  'msvs_settings': {
-    'VCCLCompilerTool': {
-      'WarningLevel': '0',
-      'AdditionalOptions': ['/wd4189', ],
-    },
-  },
   'dependencies': [
     'libjpeg-turbo-selector.gyp:libjpeg-turbo-selector',
     'zlib.gyp:zlib',