michael@0: # Copyright (c) 2012 The Chromium Authors. All rights reserved. michael@0: # Use of this source code is governed by a BSD-style license that can be michael@0: # found in the LICENSE file. michael@0: michael@0: # This gypi file defines the patterns used for determining whether a michael@0: # file is excluded from the build on a given platform. It is michael@0: # included by common.gypi for chromium_code. michael@0: michael@0: { michael@0: 'target_conditions': [ michael@0: ['OS!="win" or >(nacl_untrusted_build)==1', { michael@0: 'sources/': [ ['exclude', '_win(_unittest)?\\.(h|cc)$'], michael@0: ['exclude', '(^|/)win/'], michael@0: ['exclude', '(^|/)win_[^/]*\\.(h|cc)$'] ], michael@0: }], michael@0: ['OS!="mac" or >(nacl_untrusted_build)==1', { michael@0: 'sources/': [ ['exclude', '_(cocoa|mac)(_unittest)?\\.(h|cc|mm?)$'], michael@0: ['exclude', '(^|/)(cocoa|mac)/'] ], michael@0: }], michael@0: ['OS!="ios" or >(nacl_untrusted_build)==1', { michael@0: 'sources/': [ ['exclude', '_ios(_unittest)?\\.(h|cc|mm?)$'], michael@0: ['exclude', '(^|/)ios/'] ], michael@0: }], michael@0: ['(OS!="mac" and OS!="ios") or >(nacl_untrusted_build)==1', { michael@0: 'sources/': [ ['exclude', '\\.mm?$' ] ], michael@0: }], michael@0: # Do not exclude the linux files on *BSD since most of them can be michael@0: # shared at this point. michael@0: # In case a file is not needed, it is going to be excluded later on. michael@0: # TODO(evan): the above is not correct; we shouldn't build _linux michael@0: # files on non-linux. michael@0: ['OS!="linux" and OS!="openbsd" and OS!="freebsd" or >(nacl_untrusted_build)==1', { michael@0: 'sources/': [ michael@0: ['exclude', '_linux(_unittest)?\\.(h|cc)$'], michael@0: ['exclude', '(^|/)linux/'], michael@0: ], michael@0: }], michael@0: ['OS!="android"', { michael@0: 'sources/': [ michael@0: ['exclude', '_android(_unittest)?\\.cc$'], michael@0: ['exclude', '(^|/)android/'], michael@0: ], michael@0: }], michael@0: ['OS=="win" and >(nacl_untrusted_build)==0', { michael@0: 'sources/': [ michael@0: ['exclude', '_posix(_unittest)?\\.(h|cc)$'], michael@0: ['exclude', '(^|/)posix/'], michael@0: ], michael@0: }], michael@0: ['<(chromeos)!=1 or >(nacl_untrusted_build)==1', { michael@0: 'sources/': [ ['exclude', '_chromeos(_unittest)?\\.(h|cc)$'] ] michael@0: }], michael@0: ['>(nacl_untrusted_build)==0', { michael@0: 'sources/': [ michael@0: ['exclude', '_nacl(_unittest)?\\.(h|cc)$'], michael@0: ], michael@0: }], michael@0: ['OS!="linux" and OS!="openbsd" and OS!="freebsd" or >(nacl_untrusted_build)==1', { michael@0: 'sources/': [ michael@0: ['exclude', '_xdg(_unittest)?\\.(h|cc)$'], michael@0: ], michael@0: }], michael@0: ['<(use_x11)!=1 or >(nacl_untrusted_build)==1', { michael@0: 'sources/': [ michael@0: ['exclude', '_(x|x11)(_unittest)?\\.(h|cc)$'], michael@0: ['exclude', '(^|/)x11_[^/]*\\.(h|cc)$'], michael@0: ], michael@0: }], michael@0: ['<(toolkit_uses_gtk)!=1 or >(nacl_untrusted_build)==1', { michael@0: 'sources/': [ michael@0: ['exclude', '_gtk(_browsertest|_unittest)?\\.(h|cc)$'], michael@0: ['exclude', '(^|/)gtk/'], michael@0: ['exclude', '(^|/)gtk_[^/]*\\.(h|cc)$'], michael@0: ], michael@0: }], michael@0: ['<(toolkit_views)==0 or >(nacl_untrusted_build)==1', { michael@0: 'sources/': [ ['exclude', '_views\\.(h|cc)$'] ] michael@0: }], michael@0: ['<(use_aura)==0 or >(nacl_untrusted_build)==1', { michael@0: 'sources/': [ ['exclude', '_aura(_unittest)?\\.(h|cc)$'], michael@0: ['exclude', '(^|/)aura/'], michael@0: ] michael@0: }], michael@0: ['<(use_aura)==0 or <(use_x11)==0 or >(nacl_untrusted_build)==1', { michael@0: 'sources/': [ ['exclude', '_aurax11\\.(h|cc)$'] ] michael@0: }], michael@0: ['<(use_aura)==0 or OS!="win" or >(nacl_untrusted_build)==1', { michael@0: 'sources/': [ ['exclude', '_aurawin\\.(h|cc)$'] ] michael@0: }], michael@0: ['<(use_ash)==0 or >(nacl_untrusted_build)==1', { michael@0: 'sources/': [ ['exclude', '_ash(_unittest)?\\.(h|cc)$'], michael@0: ['exclude', '(^|/)ash/'], michael@0: ] michael@0: }], michael@0: ] michael@0: }