michael@0: # -*- Mode: python; c-basic-offset: 4; indent-tabs-mode: nil; tab-width: 40 -*- michael@0: # vim: set filetype=python: michael@0: # This Source Code Form is subject to the terms of the Mozilla Public michael@0: # License, v. 2.0. If a copy of the MPL was not distributed with this michael@0: # file, You can obtain one at http://mozilla.org/MPL/2.0/. michael@0: michael@0: EXPORTS += [ michael@0: 'chromium_types.h', michael@0: 'ycbcr_to_rgb565.h', michael@0: 'YCbCrUtils.h', michael@0: 'yuv_convert.h', michael@0: 'yuv_row.h', michael@0: ] michael@0: michael@0: UNIFIED_SOURCES += [ michael@0: 'ycbcr_to_rgb565.cpp', michael@0: 'YCbCrUtils.cpp', michael@0: 'yuv_convert.cpp', michael@0: 'yuv_row_c.cpp', michael@0: 'yuv_row_table.cpp', michael@0: ] michael@0: michael@0: if CONFIG['INTEL_ARCHITECTURE']: michael@0: # These files use MMX and SSE2 intrinsics, so they need special compile flags michael@0: # on some compilers. michael@0: SOURCES += ['yuv_convert_sse2.cpp'] michael@0: SOURCES['yuv_convert_sse2.cpp'].flags += CONFIG['SSE2_FLAGS'] michael@0: michael@0: # MSVC doesn't support MMX when targeting AMD64. michael@0: if CONFIG['_MSC_VER']: michael@0: if CONFIG['OS_TEST'] != 'x86_64': michael@0: SOURCES += [ michael@0: 'yuv_convert_mmx.cpp', michael@0: ] michael@0: else: michael@0: SOURCES += ['yuv_convert_mmx.cpp'] michael@0: SOURCES['yuv_convert_mmx.cpp'].flags += CONFIG['MMX_FLAGS'] michael@0: michael@0: if CONFIG['_MSC_VER']: michael@0: if CONFIG['OS_TEST'] == 'x86_64': michael@0: if CONFIG['_MSC_VER'] == '1400': michael@0: # VC8 doesn't support some SSE2 built-in functions michael@0: SOURCES += [ michael@0: 'yuv_row_win.cpp', michael@0: ] michael@0: else: michael@0: SOURCES += [ michael@0: 'yuv_row_win64.cpp', michael@0: ] michael@0: else: michael@0: SOURCES += [ michael@0: 'yuv_row_win.cpp', michael@0: ] michael@0: elif CONFIG['OS_ARCH'] in ('Linux', 'SunOS', 'Darwin', 'DragonFly', michael@0: 'FreeBSD', 'NetBSD', 'OpenBSD'): michael@0: SOURCES += [ michael@0: 'yuv_row_posix.cpp', michael@0: ] michael@0: else: michael@0: SOURCES += [ michael@0: 'yuv_row_other.cpp', michael@0: ] michael@0: michael@0: if CONFIG['CPU_ARCH'] == 'arm' and CONFIG['HAVE_ARM_NEON']: michael@0: SOURCES += [ michael@0: 'yuv_row_arm.s', michael@0: ] michael@0: SOURCES += [ michael@0: 'yuv_convert_arm.cpp', michael@0: ] michael@0: michael@0: FINAL_LIBRARY = 'xul'