Chromium Code Reviews| Index: media/base/simd/media_export.inc |
| diff --git a/media/base/simd/media_export.inc b/media/base/simd/media_export.inc |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..063058dfd1111796d945f4ced6561f0f2526c438 |
| --- /dev/null |
| +++ b/media/base/simd/media_export.inc |
| @@ -0,0 +1,48 @@ |
| +; Copyright 2013 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. |
| +; |
| +; A set of helper macros for controlling symbol visibility. |
| +; |
| + |
| +%ifndef MEDIA_BASE_SIMD_MEDIA_EXPORT_INC_ |
|
Ami GONE FROM CHROMIUM
2013/05/24 02:22:38
Is .inc a standard extension for this stuff?
(why
DaleCurtis
2013/05/24 18:15:33
Done.
|
| +%define MEDIA_BASE_SIMD_MEDIA_EXPORT_INC_ |
| + |
| +; Necessary for the mangle() macro. |
| +%include "third_party/x86inc/x86inc.asm" |
| + |
| +; |
| +; PRIVATE |
| +; A flag representing the specified symbol is a private symbol. This define adds |
| +; a hidden flag on Linux and a private_extern flag on Mac. (We can use this |
| +; private_extern flag only on the latest yasm.) |
| +; |
| +%ifdef MACHO |
| +%define PRIVATE :private_extern |
| +%elifdef ELF |
| +%define PRIVATE :hidden |
| +%else |
| +%define PRIVATE |
| +%endif |
| + |
| +; |
| +; EXPORT %1 |
| +; Designates a symbol as PRIVATE if EXPORT_SYMBOLS is not set. |
| +; |
| +%macro EXPORT 1 |
| +%ifdef EXPORT_SYMBOLS |
| +global mangle(%1) |
| + |
| +; Windows needs an additional export declaration. |
| +%ifidn __OUTPUT_FORMAT__,win32 |
| +export mangle(%1) |
| +%elifidn __OUTPUT_FORMAT__,win64 |
| +export mangle(%1) |
| +%endif |
| + |
| +%else |
| +global mangle(%1) PRIVATE |
| +%endif |
| +%endmacro |
| + |
| +%endif ; MEDIA_BASE_SIMD_MEDIA_EXPORT_INC_ |