| // Copyright 2014 Google Inc. All Rights Reserved. |
| // |
| // Licensed under the Apache License, Version 2.0 (the "License"); |
| // you may not use this file except in compliance with the License. |
| // You may obtain a copy of the License at |
| // |
| // http://www.apache.org/licenses/LICENSE-2.0 |
| // |
| // Unless required by applicable law or agreed to in writing, software |
| // distributed under the License is distributed on an "AS IS" BASIS, |
| // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| // See the License for the specific language governing permissions and |
| // limitations under the License. |
| |
| #ifndef SYZYGY_AR_UNITTEST_UTIL_H_ |
| #define SYZYGY_AR_UNITTEST_UTIL_H_ |
| |
| namespace testing { |
| |
| // A 'src' relative path to a sample .lib file. |
| extern const wchar_t kArchiveFile[]; |
| // The number of files in the .lib archive. |
| const size_t kArchiveFileCount = 15u; |
| // The number of symbols in the .lib archive. |
| const size_t kArchiveSymbolCount = 86u; |
| |
| // A 'src' relative path to a sample .lib file containing weak external |
| // symbols. This archive also contains no filename table, and has inline |
| // file names. The content of the first object file was generated by |
| // compiling the following MASM source: |
| // |
| // .model small |
| // .data |
| // x_weak = 1 |
| // public x_weak |
| // extern x(x_weak):abs |
| // END |
| // |
| // The second object file was generated from the code: |
| // |
| // .model small |
| // .data |
| // x = 1 |
| // public x |
| // extern x:abs |
| // END |
| // |
| // The first object file provides a weak definition of the symbol 'x', and a |
| // non-weak definition for 'x_weak'. The second object file provides a non-weak |
| // definition of 'x', which should override the definition from the first |
| // file. |
| extern const wchar_t kWeakSymbolArchiveFile[]; |
| // The number of files in the weak symbol library. |
| const size_t kWeakSymbolArchiveFileCount = 2u; |
| // The number of symbols in the weak symbol library. |
| const size_t kWeakSymbolArchiveSymbolCount = 2u; |
| |
| // An archive containing multiple files stored with the same name. |
| extern const wchar_t kDuplicatesArchiveFile[]; |
| |
| // An archive containing empty/deleted file indices in the symbol table. |
| extern const wchar_t kEmptyFilesArchiveFile[]; |
| |
| } // namespace testing |
| |
| #endif // SYZYGY_AR_UNITTEST_UTIL_H_ |