# Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. Import(['env', 'env_res']) AddTargetGroup('all_languages', 'resource dlls for languages can be built') env_res = env_res.Clone() env.Append( LINKFLAGS = [ '/INCREMENTAL:NO', '/DELAYLOAD:"dwmapi.dll"', '/DELAYLOAD:"uxtheme.dll"', '/NOENTRY', '/BASE:"0x3CF00000"', '/MACHINE:X86', '/FIXED:No', '/safeseh', '/dynamicbase', '/ignore:4199', '/nxcompat', ], PDB = '${TARGET}.pdb', no_import_lib = True, # We don't need the .lib and .exp. ) env_res.Append( CPPPATH = [ '.', '$CHROME_SRC_DIR/chrome/Debug/obj/chrome_dll', '$CHROME_SRC_DIR', '$CHROME_SRC_DIR/chrome/Debug/obj', ], RCFLAGS = [ ['/l', '0x409'], ['/I', '$TARGET_ROOT/grit_derived_sources'], ], ) env_dll = env.Clone(COMPONENT_LIBRARY_GROUPS = ['all_languages']) locale_list = [ 'ar', 'bg', 'bn', 'ca', 'cs', 'da', 'de', 'el', 'en-GB', 'en-US', 'es-419', 'es', 'et', 'fi', 'fil', 'fr', 'gu', 'he', 'hi', 'hr', 'hu', 'id', 'it', 'ja', 'kn', 'ko', 'lt', 'lv', 'ml', 'mr', 'nb', 'nl', 'or', 'pl', 'pt-BR', 'pt-PT', 'ro', 'ru', 'sk', 'sl', 'sr', 'sv', 'ta', 'te', 'th', 'tr', 'uk', 'vi', 'zh-CN', 'zh-TW', ] gcs_rc = '$TARGET_ROOT/grit_derived_sources/google_chrome_strings_%s.rc' cs_rc = '$TARGET_ROOT/grit_derived_sources/chromium_strings_%s.rc' gr_res = '$TARGET_ROOT/grit_derived_sources/generated_resources_%s.res' ws_res = '$TARGET_ROOT/grit_derived_sources/webkit_strings_%s.res' locale_dlls = [] for locale in locale_list: res = env_res.RES('locale_settings_%s.rc' % locale) # TODO(sgk): find out why this implicit dependency isn't discovered env.Depends(res, gcs_rc % locale) env.Depends(res, cs_rc % locale) dll = env_dll.ChromeSharedLibrary(locale, [ gr_res % locale, ws_res % locale, res ]) locale_dlls.append(dll) i = env.Install('$DESTINATION_ROOT/locales/', locale_dlls) env.Alias('chrome_locales', i)