1 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
8 ['OS == "linux" and chromeos==0', {
9 'use_system_libexif%': 1,
10 }, { # OS != "linux" and chromeos==0
11 'use_system_libexif%': 0,
16 ['use_system_libexif==0', {
19 'target_name': 'libexif',
20 'type': 'loadable_module',
22 'sources/libexif/exif-byte-order.c',
23 'sources/libexif/exif-content.c',
24 'sources/libexif/exif-data.c',
25 'sources/libexif/exif-entry.c',
26 'sources/libexif/exif-format.c',
27 'sources/libexif/exif-ifd.c',
28 'sources/libexif/exif-loader.c',
29 'sources/libexif/exif-log.c',
30 'sources/libexif/exif-mem.c',
31 'sources/libexif/exif-mnote-data.c',
32 'sources/libexif/exif-tag.c',
33 'sources/libexif/exif-utils.c',
34 'sources/libexif/canon/exif-mnote-data-canon.c',
35 'sources/libexif/canon/mnote-canon-entry.c',
36 'sources/libexif/canon/mnote-canon-tag.c',
37 'sources/libexif/fuji/exif-mnote-data-fuji.c',
38 'sources/libexif/fuji/mnote-fuji-entry.c',
39 'sources/libexif/fuji/mnote-fuji-tag.c',
40 'sources/libexif/olympus/exif-mnote-data-olympus.c',
41 'sources/libexif/olympus/mnote-olympus-entry.c',
42 'sources/libexif/olympus/mnote-olympus-tag.c',
43 'sources/libexif/pentax/exif-mnote-data-pentax.c',
44 'sources/libexif/pentax/mnote-pentax-entry.c',
45 'sources/libexif/pentax/mnote-pentax-tag.c',
50 'direct_dependent_settings': {
56 'clang_warning_flags': [
57 '-Wno-enum-conversion',
60 # libexif uses fabs(int) to cast to float.
61 '-Wno-absolute-value',
65 ['os_posix==1 and OS!="mac"', {
66 'cflags!': ['-fvisibility=hidden'],
78 'GCC_SYMBOLS_PRIVATE_EXTERN': 'NO', # no -fvisibility=hidden
82 'product_name': 'libexif',
87 ['MSVS_VERSION < "2015"', {
89 # This seems like a hack, but this is what Safari Win does.
90 # Luckily it is no longer needed/allowed with VS 2015.
98 'msvs_disabled_warnings': [
99 4018, # size/unsigned mismatch
100 4267, # size_t -> ExifLong truncation on amd64
102 # As of VS 2013 Update 3, building this project with /analyze hits
103 # an internal compiler error on exif-entry.c. This halts the build
104 # and prevents subsequent analysis. Therefore, /analyze is
105 # disabled for this project. See this bug for details:
106 # https://connect.microsoft.com/VisualStudio/feedback/details/1014689/internal-compiler-error
108 'VCCLCompilerTool': {
109 'AdditionalOptions!': [ '/analyze:WX-' ]
116 }, { # 'use_system_libexif!=0
119 'target_name': 'libexif',
121 'direct_dependent_settings': {
123 '<!@(<(pkg-config) --cflags libexif)',
126 'USE_SYSTEM_LIBEXIF',