diff options
author | tommycli <tommycli@chromium.org> | 2016-03-14 16:56:56 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-03-14 23:58:38 +0000 |
commit | cd96b6f874573d7089bf2eb9d54ed53d7469bb56 (patch) | |
tree | 73d81793ff74c6a72f4b8d1ef7e288d941575fea | |
parent | c0f081b58265457d0f434445cd084662951388f6 (diff) | |
download | chromium_src-cd96b6f874573d7089bf2eb9d54ed53d7469bb56.zip chromium_src-cd96b6f874573d7089bf2eb9d54ed53d7469bb56.tar.gz chromium_src-cd96b6f874573d7089bf2eb9d54ed53d7469bb56.tar.bz2 |
Reland: Media Galleries Partial Deprecation: Remove image metadata & libexif.
This relands https://codereview.chromium.org/1773233002/.
Original description:
Media Galleries Partial Deprecation: Remove image metadata & libexif.
Removing libexif is a great thing.
It will remove a ~200KB DLL from Windows, Mac, and ChromeOS. It will remove bugs and security issues.
BUG=542912,577272
TBR=
Review URL: https://codereview.chromium.org/1803883002
Cr-Commit-Position: refs/heads/master@{#381121}
50 files changed, 24 insertions, 1893 deletions
@@ -133,9 +133,6 @@ deps = { 'src/third_party/icu': Var('chromium_git') + '/chromium/deps/icu.git' + '@' + '6d3b55dfa17d9a597c064eeef7ceac18c73184b7', - 'src/third_party/libexif/sources': - Var('chromium_git') + '/chromium/deps/libexif/sources.git' + '@' + '9d467f7d21e4749ee22ee7520e561ac7b38484b9', - 'src/third_party/hunspell_dictionaries': Var('chromium_git') + '/chromium/deps/hunspell_dictionaries.git' + '@' + 'c106afdcec5d3de2622e19f1b3294c47bbd8bd72', diff --git a/build/experimental/install-build-deps.py b/build/experimental/install-build-deps.py index 25da84e..52c04f8 100755 --- a/build/experimental/install-build-deps.py +++ b/build/experimental/install-build-deps.py @@ -59,7 +59,6 @@ _packages_dev = ( 'libcurl4-gnutls-dev', 'libdrm-dev', 'libelf-dev', - 'libexif-dev', 'libgconf2-dev', 'libglib2.0-dev', 'libglu1-mesa-dev', @@ -122,7 +121,6 @@ _packages_lib = ( 'libcairo2', 'libcap2', 'libcups2', - 'libexif12', 'libexpat1', 'libfontconfig1', 'libfreetype6', @@ -218,7 +216,6 @@ _packages_nacl = ( 'libasound2:i386', 'libcap2:i386', 'libelf-dev:i386', - 'libexif12:i386', 'libfontconfig1:i386', 'libgconf-2-4:i386', 'libglib2.0-0:i386', diff --git a/build/install-build-deps.sh b/build/install-build-deps.sh index 04f6e59..2b825d7 100755 --- a/build/install-build-deps.sh +++ b/build/install-build-deps.sh @@ -102,16 +102,15 @@ dev_list="bison cdbs curl dpkg-dev elfutils devscripts fakeroot language-pack-fr language-pack-he language-pack-zh-hant libapache2-mod-php5 libasound2-dev libbrlapi-dev libav-tools libbz2-dev libcairo2-dev libcap-dev libcups2-dev libcurl4-gnutls-dev - libdrm-dev libelf-dev libexif-dev libffi-dev libgconf2-dev - libglib2.0-dev libglu1-mesa-dev libgnome-keyring-dev libgtk2.0-dev - libkrb5-dev libnspr4-dev libnss3-dev libpam0g-dev libpci-dev - libpulse-dev libsctp-dev libspeechd-dev libsqlite3-dev libssl-dev - libudev-dev libwww-perl libxslt1-dev libxss-dev libxt-dev libxtst-dev - openbox patch perl php5-cgi pkg-config python python-cherrypy3 - python-crypto python-dev python-numpy python-opencv python-openssl - python-psutil python-yaml rpm ruby subversion ttf-dejavu-core - ttf-indic-fonts ttf-kochi-gothic ttf-kochi-mincho wdiff - zip $chromeos_dev_list" + libdrm-dev libelf-dev libffi-dev libgconf2-dev libglib2.0-dev + libglu1-mesa-dev libgnome-keyring-dev libgtk2.0-dev libkrb5-dev + libnspr4-dev libnss3-dev libpam0g-dev libpci-dev libpulse-dev + libsctp-dev libspeechd-dev libsqlite3-dev libssl-dev libudev-dev + libwww-perl libxslt1-dev libxss-dev libxt-dev libxtst-dev openbox + patch perl php5-cgi pkg-config python python-cherrypy3 python-crypto + python-dev python-numpy python-opencv python-openssl python-psutil + python-yaml rpm ruby subversion ttf-dejavu-core ttf-indic-fonts + ttf-kochi-gothic ttf-kochi-mincho wdiff zip $chromeos_dev_list" # 64-bit systems need a minimum set of 32-bit compat packages for the pre-built # NaCl binaries. @@ -124,12 +123,12 @@ chromeos_lib_list="libpulse0 libbz2-1.0" # Full list of required run-time libraries lib_list="libatk1.0-0 libc6 libasound2 libcairo2 libcap2 libcups2 libexpat1 - libexif12 libffi6 libfontconfig1 libfreetype6 libglib2.0-0 - libgnome-keyring0 libgtk2.0-0 libpam0g libpango1.0-0 libpci3 libpcre3 - libpixman-1-0 libpng12-0 libspeechd2 libstdc++6 libsqlite3-0 libx11-6 - libxau6 libxcb1 libxcomposite1 libxcursor1 libxdamage1 libxdmcp6 - libxext6 libxfixes3 libxi6 libxinerama1 libxrandr2 libxrender1 - libxtst6 zlib1g $chromeos_lib_list" + libffi6 libfontconfig1 libfreetype6 libglib2.0-0 libgnome-keyring0 + libgtk2.0-0 libpam0g libpango1.0-0 libpci3 libpcre3 libpixman-1-0 + libpng12-0 libspeechd2 libstdc++6 libsqlite3-0 libx11-6 libxau6 + libxcb1 libxcomposite1 libxcursor1 libxdamage1 libxdmcp6 libxext6 + libxfixes3 libxi6 libxinerama1 libxrandr2 libxrender1 libxtst6 + zlib1g $chromeos_lib_list" # Debugging symbols for all of the run-time libraries dbg_list="libatk1.0-dbg libc6-dbg libcairo2-dbg libffi6-dbg libfontconfig1-dbg @@ -165,10 +164,9 @@ fi # Packages to build NaCl, its toolchains, and its ports. naclports_list="ant autoconf bison cmake gawk intltool xutils-dev xsltproc" nacl_list="g++-mingw-w64-i686 lib32z1-dev - libasound2:i386 libcap2:i386 libelf-dev:i386 libexif12:i386 - libfontconfig1:i386 libgconf-2-4:i386 libglib2.0-0:i386 libgpm2:i386 - libgtk2.0-0:i386 libncurses5:i386 lib32ncurses5-dev - libnss3:i386 libpango1.0-0:i386 + libasound2:i386 libcap2:i386 libelf-dev:i386 libfontconfig1:i386 + libgconf-2-4:i386 libglib2.0-0:i386 libgpm2:i386 libgtk2.0-0:i386 + libncurses5:i386 lib32ncurses5-dev libnss3:i386 libpango1.0-0:i386 libssl1.0.0:i386 libtinfo-dev libtinfo-dev:i386 libtool libxcomposite1:i386 libxcursor1:i386 libxdamage1:i386 libxi6:i386 libxrandr2:i386 libxss1:i386 libxtst6:i386 texinfo xvfb diff --git a/build/linux/sysroot_scripts/packagelist.jessie.amd64 b/build/linux/sysroot_scripts/packagelist.jessie.amd64 index 928f5de..06ba64b 100644 --- a/build/linux/sysroot_scripts/packagelist.jessie.amd64 +++ b/build/linux/sysroot_scripts/packagelist.jessie.amd64 @@ -76,8 +76,6 @@ main/libd/libdrm/libdrm-dev_2.4.58-2_amd64.deb main/libd/libdrm/libdrm-intel1_2.4.58-2_amd64.deb main/libd/libdrm/libdrm-nouveau2_2.4.58-2_amd64.deb main/libd/libdrm/libdrm-radeon1_2.4.58-2_amd64.deb -main/libe/libexif/libexif12_0.6.21-2_amd64.deb -main/libe/libexif/libexif-dev_0.6.21-2_amd64.deb main/libf/libffi/libffi6_3.1-2+b2_amd64.deb main/libf/libffi/libffi-dev_3.1-2+b2_amd64.deb main/libg/libgcrypt20/libgcrypt20_1.6.3-2_amd64.deb diff --git a/build/linux/sysroot_scripts/packagelist.jessie.arm b/build/linux/sysroot_scripts/packagelist.jessie.arm index 1f21a06..c7daed4 100644 --- a/build/linux/sysroot_scripts/packagelist.jessie.arm +++ b/build/linux/sysroot_scripts/packagelist.jessie.arm @@ -73,8 +73,6 @@ main/libd/libdrm/libdrm-freedreno1_2.4.58-2_armhf.deb main/libd/libdrm/libdrm-nouveau2_2.4.58-2_armhf.deb main/libd/libdrm/libdrm-omap1_2.4.58-2_armhf.deb main/libd/libdrm/libdrm-radeon1_2.4.58-2_armhf.deb -main/libe/libexif/libexif12_0.6.21-2_armhf.deb -main/libe/libexif/libexif-dev_0.6.21-2_armhf.deb main/libf/libffi/libffi6_3.1-2+b2_armhf.deb main/libf/libffi/libffi-dev_3.1-2+b2_armhf.deb main/libg/libgcrypt20/libgcrypt20_1.6.3-2_armhf.deb diff --git a/build/linux/sysroot_scripts/packagelist.jessie.i386 b/build/linux/sysroot_scripts/packagelist.jessie.i386 index 0bf51e7..c826a85 100644 --- a/build/linux/sysroot_scripts/packagelist.jessie.i386 +++ b/build/linux/sysroot_scripts/packagelist.jessie.i386 @@ -74,8 +74,6 @@ main/libd/libdrm/libdrm-dev_2.4.58-2_i386.deb main/libd/libdrm/libdrm-intel1_2.4.58-2_i386.deb main/libd/libdrm/libdrm-nouveau2_2.4.58-2_i386.deb main/libd/libdrm/libdrm-radeon1_2.4.58-2_i386.deb -main/libe/libexif/libexif12_0.6.21-2_i386.deb -main/libe/libexif/libexif-dev_0.6.21-2_i386.deb main/libf/libffi/libffi6_3.1-2+b2_i386.deb main/libf/libffi/libffi-dev_3.1-2+b2_i386.deb main/libg/libgcrypt20/libgcrypt20_1.6.3-2_i386.deb diff --git a/build/linux/sysroot_scripts/packagelist.jessie.mipsel b/build/linux/sysroot_scripts/packagelist.jessie.mipsel index 62203d5..76585af 100644 --- a/build/linux/sysroot_scripts/packagelist.jessie.mipsel +++ b/build/linux/sysroot_scripts/packagelist.jessie.mipsel @@ -68,8 +68,6 @@ main/libd/libdrm/libdrm2_2.4.58-2_mipsel.deb main/libd/libdrm/libdrm-dev_2.4.58-2_mipsel.deb main/libd/libdrm/libdrm-nouveau2_2.4.58-2_mipsel.deb main/libd/libdrm/libdrm-radeon1_2.4.58-2_mipsel.deb -main/libe/libexif/libexif12_0.6.21-2_mipsel.deb -main/libe/libexif/libexif-dev_0.6.21-2_mipsel.deb main/libf/libffi/libffi6_3.1-2+b2_mipsel.deb main/libf/libffi/libffi-dev_3.1-2+b2_mipsel.deb main/libg/libgcrypt20/libgcrypt20_1.6.3-2_mipsel.deb diff --git a/build/linux/sysroot_scripts/packagelist.trusty.arm b/build/linux/sysroot_scripts/packagelist.trusty.arm index cd4b671..9ae07da 100644 --- a/build/linux/sysroot_scripts/packagelist.trusty.arm +++ b/build/linux/sysroot_scripts/packagelist.trusty.arm @@ -57,8 +57,6 @@ main/k/krb5/libkrb5support0_1.12+dfsg-2ubuntu4_armhf.deb main/libc/libcap2/libcap2_2.24-0ubuntu2_armhf.deb main/libc/libcap2/libcap-dev_2.24-0ubuntu2_armhf.deb main/libd/libdrm/libdrm2_2.4.52-1_armhf.deb -main/libe/libexif/libexif12_0.6.21-1ubuntu1_armhf.deb -main/libe/libexif/libexif-dev_0.6.21-1ubuntu1_armhf.deb main/libf/libffi/libffi6_3.1~rc1+r3.0.13-12_armhf.deb main/libg/libgcrypt11/libgcrypt11_1.5.3-2ubuntu4_armhf.deb main/libg/libgcrypt11/libgcrypt11-dev_1.5.3-2ubuntu4_armhf.deb diff --git a/build/linux/sysroot_scripts/packagelist.wheezy.amd64 b/build/linux/sysroot_scripts/packagelist.wheezy.amd64 index e6a0f53..9504e1c 100644 --- a/build/linux/sysroot_scripts/packagelist.wheezy.amd64 +++ b/build/linux/sysroot_scripts/packagelist.wheezy.amd64 @@ -66,8 +66,6 @@ main/libd/libdrm/libdrm-intel1_2.4.40-1~deb7u2_amd64.deb main/libd/libdrm/libdrm-nouveau1a_2.4.40-1~deb7u2_amd64.deb main/libd/libdrm/libdrm-radeon1_2.4.40-1~deb7u2_amd64.deb main/libd/libdrm/libkms1_2.4.40-1~deb7u2_amd64.deb -main/libe/libexif/libexif12_0.6.20-3_amd64.deb -main/libe/libexif/libexif-dev_0.6.20-3_amd64.deb main/libf/libffi/libffi5_3.0.10-3_amd64.deb main/libf/libffi/libffi-dev_3.0.10-3_amd64.deb main/libg/libgcrypt11/libgcrypt11_1.5.0-5+deb7u3_amd64.deb diff --git a/build/linux/sysroot_scripts/packagelist.wheezy.arm b/build/linux/sysroot_scripts/packagelist.wheezy.arm index 12de0ea..41a4ba1 100644 --- a/build/linux/sysroot_scripts/packagelist.wheezy.arm +++ b/build/linux/sysroot_scripts/packagelist.wheezy.arm @@ -65,8 +65,6 @@ main/libd/libdrm/libdrm-nouveau1a_2.4.40-1~deb7u2_armhf.deb main/libd/libdrm/libdrm-omap1_2.4.40-1~deb7u2_armhf.deb main/libd/libdrm/libdrm-radeon1_2.4.40-1~deb7u2_armhf.deb main/libd/libdrm/libkms1_2.4.40-1~deb7u2_armhf.deb -main/libe/libexif/libexif12_0.6.20-3_armhf.deb -main/libe/libexif/libexif-dev_0.6.20-3_armhf.deb main/libf/libffi/libffi5_3.0.10-3+b1_armhf.deb main/libf/libffi/libffi-dev_3.0.10-3+b1_armhf.deb main/libg/libgcrypt11/libgcrypt11_1.5.0-5+deb7u3_armhf.deb diff --git a/build/linux/sysroot_scripts/packagelist.wheezy.i386 b/build/linux/sysroot_scripts/packagelist.wheezy.i386 index 4979134..66cae99 100644 --- a/build/linux/sysroot_scripts/packagelist.wheezy.i386 +++ b/build/linux/sysroot_scripts/packagelist.wheezy.i386 @@ -66,8 +66,6 @@ main/libd/libdrm/libdrm-intel1_2.4.40-1~deb7u2_i386.deb main/libd/libdrm/libdrm-nouveau1a_2.4.40-1~deb7u2_i386.deb main/libd/libdrm/libdrm-radeon1_2.4.40-1~deb7u2_i386.deb main/libd/libdrm/libkms1_2.4.40-1~deb7u2_i386.deb -main/libe/libexif/libexif12_0.6.20-3_i386.deb -main/libe/libexif/libexif-dev_0.6.20-3_i386.deb main/libf/libffi/libffi5_3.0.10-3_i386.deb main/libf/libffi/libffi-dev_3.0.10-3_i386.deb main/libg/libgcrypt11/libgcrypt11_1.5.0-5+deb7u3_i386.deb diff --git a/build/linux/sysroot_scripts/packagelist.wheezy.mipsel b/build/linux/sysroot_scripts/packagelist.wheezy.mipsel index 2d1a274..85c57da 100644 --- a/build/linux/sysroot_scripts/packagelist.wheezy.mipsel +++ b/build/linux/sysroot_scripts/packagelist.wheezy.mipsel @@ -64,8 +64,6 @@ main/libd/libdrm/libdrm-dev_2.4.40-1~deb7u2_mipsel.deb main/libd/libdrm/libdrm-nouveau1a_2.4.40-1~deb7u2_mipsel.deb main/libd/libdrm/libdrm-radeon1_2.4.40-1~deb7u2_mipsel.deb main/libd/libdrm/libkms1_2.4.40-1~deb7u2_mipsel.deb -main/libe/libexif/libexif12_0.6.20-3_mipsel.deb -main/libe/libexif/libexif-dev_0.6.20-3_mipsel.deb main/libf/libffi/libffi5_3.0.10-3_mipsel.deb main/libf/libffi/libffi-dev_3.0.10-3_mipsel.deb main/libg/libgcrypt11/libgcrypt11_1.5.0-5+deb7u3_mipsel.deb diff --git a/build/linux/sysroot_scripts/sysroot-creator-jessie.sh b/build/linux/sysroot_scripts/sysroot-creator-jessie.sh index a684fb06..0c6bdb7 100755 --- a/build/linux/sysroot_scripts/sysroot-creator-jessie.sh +++ b/build/linux/sysroot_scripts/sysroot-creator-jessie.sh @@ -51,8 +51,6 @@ DEBIAN_PACKAGES="\ libdrm-radeon1 libelf1 libelf-dev - libexif12 - libexif-dev libexpat1 libexpat1-dev libffi6 diff --git a/build/linux/sysroot_scripts/sysroot-creator-trusty.sh b/build/linux/sysroot_scripts/sysroot-creator-trusty.sh index 7c5e346..5230e40 100755 --- a/build/linux/sysroot_scripts/sysroot-creator-trusty.sh +++ b/build/linux/sysroot_scripts/sysroot-creator-trusty.sh @@ -44,8 +44,6 @@ DEBIAN_PACKAGES="\ libdrm2 libelf1 libelf-dev - libexif12 - libexif-dev libexpat1 libexpat1-dev libffi6 diff --git a/build/linux/sysroot_scripts/sysroot-creator-wheezy.sh b/build/linux/sysroot_scripts/sysroot-creator-wheezy.sh index 5006b954..59c0b72 100755 --- a/build/linux/sysroot_scripts/sysroot-creator-wheezy.sh +++ b/build/linux/sysroot_scripts/sysroot-creator-wheezy.sh @@ -48,8 +48,6 @@ DEBIAN_PACKAGES="\ libdrm-radeon1 libelf1 libelf-dev - libexif12 - libexif-dev libexpat1 libexpat1-dev libffi5 diff --git a/chrome/browser/extensions/api/media_galleries/media_galleries_apitest.cc b/chrome/browser/extensions/api/media_galleries/media_galleries_apitest.cc index 1a59f99..9016860 100644 --- a/chrome/browser/extensions/api/media_galleries/media_galleries_apitest.cc +++ b/chrome/browser/extensions/api/media_galleries/media_galleries_apitest.cc @@ -340,11 +340,6 @@ class MediaGalleriesPlatformAppBrowserTest : public PlatformAppBrowserTest { .AppendASCII("common"); } - base::FilePath GetWallpaperTestDataDir() const { - return test_data_dir_.AppendASCII("api_test") - .AppendASCII("wallpaper"); - } - int num_galleries() const { return ensure_media_directories_exists_->num_galleries(); } @@ -572,7 +567,6 @@ IN_PROC_BROWSER_TEST_F(MediaGalleriesPlatformAppBrowserTest, GetMetadata) { AddFileToSingleFakeGallery(media::GetTestDataFilePath("90rotation.mp4")); AddFileToSingleFakeGallery(media::GetTestDataFilePath("id3_png_test.mp3")); - AddFileToSingleFakeGallery(GetWallpaperTestDataDir().AppendASCII("test.jpg")); base::ListValue custom_args; #if defined(USE_PROPRIETARY_CODECS) diff --git a/chrome/browser_tests.isolate b/chrome/browser_tests.isolate index 4b6e6c3..107a0903 100644 --- a/chrome/browser_tests.isolate +++ b/chrome/browser_tests.isolate @@ -259,7 +259,6 @@ '<(PRODUCT_DIR)/chromevox_test_data/', '<(PRODUCT_DIR)/content_shell.pak', '<(PRODUCT_DIR)/keyboard_resources.pak', - '<(PRODUCT_DIR)/libexif.so', '<(PRODUCT_DIR)/locales/', '<(PRODUCT_DIR)/nacl_helper', '<(PRODUCT_DIR)/nacl_irt_x86_64.nexe', diff --git a/chrome/chrome.isolate b/chrome/chrome.isolate index 90b3c48..796e53d 100644 --- a/chrome/chrome.isolate +++ b/chrome/chrome.isolate @@ -69,7 +69,6 @@ '<(PRODUCT_DIR)/<(mac_product_name) Framework.framework/', '<(PRODUCT_DIR)/<(mac_product_name) Helper.app/', '<(PRODUCT_DIR)/<(mac_product_name).app/', - '<(PRODUCT_DIR)/exif.so', ], }, }], @@ -79,7 +78,6 @@ '<(PRODUCT_DIR)/<(mac_product_name) Framework.framework.dSYM/', '<(PRODUCT_DIR)/<(mac_product_name) Helper.app.dSYM/', '<(PRODUCT_DIR)/<(mac_product_name).app.dSYM/', - '<(PRODUCT_DIR)/exif.so.dSYM/', ], }, }], @@ -90,7 +88,6 @@ '<(PRODUCT_DIR)/chrome_200_percent.pak', '<(PRODUCT_DIR)/chrome.dll', '<(PRODUCT_DIR)/chrome_elf.dll', - '<(PRODUCT_DIR)/libexif.dll', '<(PRODUCT_DIR)/osmesa.dll', ], }, diff --git a/chrome/chrome_dll_bundle.gypi b/chrome/chrome_dll_bundle.gypi index bb43d17..b2e152d 100644 --- a/chrome/chrome_dll_bundle.gypi +++ b/chrome/chrome_dll_bundle.gypi @@ -120,24 +120,9 @@ '--scm=1', '--branding=<(branding)'], }, - { - 'postbuild_name': 'Symlink Libraries', - 'action': [ - 'ln', - '-fns', - 'Versions/Current/Libraries', - '${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/Libraries' - ], - }, ], 'copies': [ { - 'destination': '<(PRODUCT_DIR)/$(CONTENTS_FOLDER_PATH)/Libraries', - 'files': [ - '<(PRODUCT_DIR)/exif.so', - ], - }, - { 'destination': '<(PRODUCT_DIR)/$(CONTENTS_FOLDER_PATH)/Helpers', 'files': [ '<(PRODUCT_DIR)/crashpad_handler', diff --git a/chrome/chrome_tests_unit.gypi b/chrome/chrome_tests_unit.gypi index 8f9169f..17a8741 100644 --- a/chrome/chrome_tests_unit.gypi +++ b/chrome/chrome_tests_unit.gypi @@ -658,7 +658,6 @@ 'renderer/extensions/renderer_permissions_policy_delegate_unittest.cc', 'renderer/media/cast_ipc_dispatcher_unittest.cc', 'utility/image_writer/image_writer_unittest.cc', - 'utility/media_galleries/image_metadata_extractor_unittest.cc', ], 'chrome_unit_tests_extensions_service_discovery_sources': [ 'browser/extensions/api/gcd_private/privet_v3_context_getter_unittest.cc', diff --git a/chrome/chrome_utility.gypi b/chrome/chrome_utility.gypi index 8ed5511..0ed6bdf 100644 --- a/chrome/chrome_utility.gypi +++ b/chrome/chrome_utility.gypi @@ -83,8 +83,6 @@ 'utility/safe_browsing/mac/udif.h', ], 'chrome_utility_shared_media_sources': [ - 'utility/media_galleries/image_metadata_extractor.cc', - 'utility/media_galleries/image_metadata_extractor.h', 'utility/media_galleries/ipc_data_source.cc', 'utility/media_galleries/ipc_data_source.h', 'utility/media_galleries/itunes_pref_parser_win.cc', @@ -177,7 +175,6 @@ ['enable_extensions==1', { 'dependencies': [ '../extensions/extensions.gyp:extensions_utility', - '../third_party/libexif/libexif.gyp:libexif', 'common/extensions/api/api.gyp:chrome_api', ], 'export_dependent_settings': [ diff --git a/chrome/common/extensions/api/media_galleries.idl b/chrome/common/extensions/api/media_galleries.idl index 7ef6727..4c21ef7 100644 --- a/chrome/common/extensions/api/media_galleries.idl +++ b/chrome/common/extensions/api/media_galleries.idl @@ -128,30 +128,17 @@ namespace mediaGalleries { // The browser sniffed mime type. DOMString mimeType; - // Defined for images and video. In pixels. + // Defined for video. In pixels. long? height; long? width; - // Defined for images only. - double? xResolution; - double? yResolution; - // Defined for audio and video. In seconds. double? duration; - // Defined for images and video. In degrees. + // Defined for video. In degrees. long? rotation; - // Defined for images only. - DOMString? cameraMake; - DOMString? cameraModel; - double? exposureTimeSeconds; - boolean? flashFired; - double? fNumber; - double? focalLengthMm; - double? isoEquivalent; - - // Defined for audio and video only. + // Defined for audio and video. DOMString? album; DOMString? artist; DOMString? comment; diff --git a/chrome/installer/linux/sysroot_scripts/packagelist.wheezy.mipsel b/chrome/installer/linux/sysroot_scripts/packagelist.wheezy.mipsel index 9531805..0c5278c 100644 --- a/chrome/installer/linux/sysroot_scripts/packagelist.wheezy.mipsel +++ b/chrome/installer/linux/sysroot_scripts/packagelist.wheezy.mipsel @@ -58,8 +58,6 @@ main/k/krb5/libkrb5support0_1.10.1+dfsg-5+deb7u2_mipsel.deb main/libc/libcap2/libcap2_2.22-1.2_mipsel.deb main/libc/libcap2/libcap-dev_2.22-1.2_mipsel.deb main/libd/libdrm/libdrm2_2.4.40-1~deb7u2_mipsel.deb -main/libe/libexif/libexif12_0.6.20-3_mipsel.deb -main/libe/libexif/libexif-dev_0.6.20-3_mipsel.deb main/libf/libffi/libffi5_3.0.10-3_mipsel.deb main/libg/libgcrypt11/libgcrypt11_1.5.0-5+deb7u2_mipsel.deb main/libg/libgcrypt11/libgcrypt11-dev_1.5.0-5+deb7u2_mipsel.deb diff --git a/chrome/installer/mini_installer/chrome.release b/chrome/installer/mini_installer/chrome.release index e554c16..fcbc531 100644 --- a/chrome/installer/mini_installer/chrome.release +++ b/chrome/installer/mini_installer/chrome.release @@ -30,7 +30,6 @@ kasko.dll: %(VersionDir)s\ icudt.dll: %(VersionDir)s\ icudtl.dat: %(VersionDir)s\ libEGL.dll: %(VersionDir)s\ -libexif.dll: %(VersionDir)s\ libGLESv2.dll: %(VersionDir)s\ nacl64.exe: %(VersionDir)s\ nacl_irt_x86_32.nexe: %(VersionDir)s\ diff --git a/chrome/interactive_ui_tests.isolate b/chrome/interactive_ui_tests.isolate index 5aa6cb5..1e8c9b3 100644 --- a/chrome/interactive_ui_tests.isolate +++ b/chrome/interactive_ui_tests.isolate @@ -130,7 +130,6 @@ 'files': [ '../google_apis/test/', '<(PRODUCT_DIR)/keyboard_resources.pak', - '<(PRODUCT_DIR)/libexif.so', '<(PRODUCT_DIR)/nacl_helper', '<(PRODUCT_DIR)/nacl_irt_x86_64.nexe', '<(PRODUCT_DIR)/resources/chromeos/', diff --git a/chrome/sync_integration_tests.isolate b/chrome/sync_integration_tests.isolate index 4bb4ad6..25a2012 100644 --- a/chrome/sync_integration_tests.isolate +++ b/chrome/sync_integration_tests.isolate @@ -101,13 +101,6 @@ ], }, }], - ['chromeos==1', { - 'variables': { - 'files': [ - '<(PRODUCT_DIR)/libexif.so', - ], - }, - }], ], 'includes': [ '../base/base.isolate', diff --git a/chrome/test/data/extensions/api_test/media_galleries/media_metadata/test.js b/chrome/test/data/extensions/api_test/media_galleries/media_metadata/test.js index f4010e0..96ad361 100644 --- a/chrome/test/data/extensions/api_test/media_galleries/media_metadata/test.js +++ b/chrome/test/data/extensions/api_test/media_galleries/media_metadata/test.js @@ -35,30 +35,6 @@ function ImageMIMETypeOnlyTest() { RunMetadataTest("test.jpg", {metadataType: 'mimeTypeOnly'}, verifyMetadata); } -function ImageTagsTest() { - function verifyMetadata(metadata) { - chrome.test.assertEq("image/jpeg", metadata.mimeType); - chrome.test.assertEq(5616, metadata.width); - chrome.test.assertEq(3744, metadata.height); - chrome.test.assertEq(0, metadata.rotation); - chrome.test.assertEq(300.0, metadata.xResolution); - chrome.test.assertEq(300.0, metadata.yResolution); - chrome.test.assertEq("Canon", metadata.cameraMake); - chrome.test.assertEq("Canon EOS 5D Mark II", metadata.cameraModel); - chrome.test.assertEq(0.01, metadata.exposureTimeSeconds); - chrome.test.assertFalse(metadata.flashFired); - chrome.test.assertEq(3.2, metadata.fNumber); - chrome.test.assertEq(100, metadata.focalLengthMm); - chrome.test.assertEq(1600, metadata.isoEquivalent); - - chrome.test.assertEq(0, metadata.attachedImages.length); - - chrome.test.succeed(); - } - - RunMetadataTest("test.jpg", {}, verifyMetadata); -} - function InvalidMultimediaFileTest() { function verifyMetadata(metadata) { chrome.test.assertEq(null, metadata); @@ -193,7 +169,6 @@ chrome.test.getConfig(function(config) { // Should still be able to sniff MP3 MIME type without proprietary codecs. var testsToRun = [ ImageMIMETypeOnlyTest, - ImageTagsTest, InvalidMultimediaFileTest ]; diff --git a/chrome/test/data/extensions/api_test/media_galleries/read_access/test.js b/chrome/test/data/extensions/api_test/media_galleries/read_access/test.js index 561677a..9e5909d 100644 --- a/chrome/test/data/extensions/api_test/media_galleries/read_access/test.js +++ b/chrome/test/data/extensions/api_test/media_galleries/read_access/test.js @@ -42,28 +42,6 @@ function ReadFileToBytesTest() { TestFirstFilesystem(verifyFilesystem); } -function GetMetadataTest() { - function verifyFilesystem(filesystem) { - filesystem.root.getFile("test.jpg", {create: false}, verifyFileEntry, - chrome.test.fail); - } - - function verifyFileEntry(fileEntry) { - fileEntry.file(verifyFile, chrome.test.fail) - } - - function verifyFile(file) { - mediaGalleries.getMetadata(file, {}, verifyMetadata); - } - - function verifyMetadata(metadata) { - chrome.test.assertEq("image/jpeg", metadata.mimeType); - chrome.test.succeed(); - } - - TestFirstFilesystem(verifyFilesystem); -} - function GetMediaFileSystemMetadataTest() { function verifyFilesystem(filesystem) { var metadata = mediaGalleries.getMediaFileSystemMetadata(filesystem); @@ -83,7 +61,6 @@ chrome.test.getConfig(function(config) { chrome.test.runTests([ ReadDirectoryTest, ReadFileToBytesTest, - GetMetadataTest, GetMediaFileSystemMetadataTest, ]); }) diff --git a/chrome/tools/build/chromeos/FILES.cfg b/chrome/tools/build/chromeos/FILES.cfg index cfe7217..855caba 100644 --- a/chrome/tools/build/chromeos/FILES.cfg +++ b/chrome/tools/build/chromeos/FILES.cfg @@ -73,10 +73,6 @@ FILES = [ 'buildtype': ['dev', 'official'], }, { - 'filename': 'lib/libexif.so', - 'buildtype': ['dev', 'official'], - }, - { 'filename': 'locales', 'buildtype': ['dev', 'official'], }, diff --git a/chrome/tools/build/mac/TESTS b/chrome/tools/build/mac/TESTS index d77adcf..75986ce 100644 --- a/chrome/tools/build/mac/TESTS +++ b/chrome/tools/build/mac/TESTS @@ -1,2 +1 @@ sync_integration_tests -exif.so diff --git a/chrome/tools/build/mac/dump_product_syms b/chrome/tools/build/mac/dump_product_syms index 6abe513..d42f0f6 100755 --- a/chrome/tools/build/mac/dump_product_syms +++ b/chrome/tools/build/mac/dump_product_syms @@ -80,7 +80,6 @@ SRC_NAMES=( "${SRC_APP_NAME} Framework.framework" "${SRC_APP_NAME} Helper.app" "crashpad_handler" - "exif.so" ) # PDF.plugin is optional. Only include it if present. diff --git a/chrome/tools/build/win/FILES.cfg b/chrome/tools/build/win/FILES.cfg index d245f97..ef62aa1 100644 --- a/chrome/tools/build/win/FILES.cfg +++ b/chrome/tools/build/win/FILES.cfg @@ -129,11 +129,6 @@ FILES = [ 'optional': ['dev', 'official'], }, { - 'filename': 'libexif.dll', - 'buildtype': ['dev', 'official'], - 'filegroup': ['default', 'symsrc'], - }, - { 'filename': 'locales/ar.pak', 'buildtype': ['dev', 'official'], }, diff --git a/chrome/unit_tests.isolate b/chrome/unit_tests.isolate index b76c4e1..7639374 100644 --- a/chrome/unit_tests.isolate +++ b/chrome/unit_tests.isolate @@ -96,7 +96,6 @@ 'variables': { 'files': [ '<(PRODUCT_DIR)/<(mac_product_name) Framework.framework/', - '<(PRODUCT_DIR)/exif.so', '<(PRODUCT_DIR)/osmesa.so', '<(PRODUCT_DIR)/test_data/chrome/safe_browsing_dmg/', ], @@ -106,7 +105,6 @@ 'variables': { 'files': [ '<(PRODUCT_DIR)/<(mac_product_name) Framework.framework.dSYM/', - '<(PRODUCT_DIR)/exif.so.dSYM/', '<(PRODUCT_DIR)/osmesa.so.dSYM/', '<(PRODUCT_DIR)/unit_tests.dSYM/', ], @@ -120,7 +118,6 @@ '../ui/base/glib/', '<(PRODUCT_DIR)/blacklist_test_dll_1.dll', '<(PRODUCT_DIR)/chrome_elf.dll', - '<(PRODUCT_DIR)/libexif.dll', '<(PRODUCT_DIR)/osmesa.dll', '<(PRODUCT_DIR)/verifier_test_dll_1.dll', '<(PRODUCT_DIR)/verifier_test_dll_2.dll', @@ -149,7 +146,6 @@ 'files': [ '../chromeos/test/data/network/', '<(PRODUCT_DIR)/keyboard_resources.pak', - '<(PRODUCT_DIR)/libexif.so', '<(PRODUCT_DIR)/test_data/chrome/browser/resources/chromeos/', ], }, diff --git a/chrome/utility/BUILD.gn b/chrome/utility/BUILD.gn index 22435b7..f7c0d0e 100644 --- a/chrome/utility/BUILD.gn +++ b/chrome/utility/BUILD.gn @@ -92,12 +92,6 @@ static_library("utility") { ".", "..") } - - # Linux should use system libexif - if (!is_linux || is_chromeos) { - # TODO(thestig): Properly support building on Linux and ChromeOS. - deps += [ "//third_party/libexif" ] - } } if (use_nss_certs) { diff --git a/chrome/utility/extensions/extensions_handler.cc b/chrome/utility/extensions/extensions_handler.cc index fdd6dfd..9518d9d 100644 --- a/chrome/utility/extensions/extensions_handler.cc +++ b/chrome/utility/extensions/extensions_handler.cc @@ -14,7 +14,6 @@ #include "chrome/common/extensions/chrome_utility_extensions_messages.h" #include "chrome/common/media_galleries/metadata_types.h" #include "chrome/utility/chrome_content_utility_client.h" -#include "chrome/utility/media_galleries/image_metadata_extractor.h" #include "chrome/utility/media_galleries/ipc_data_source.h" #include "chrome/utility/media_galleries/media_metadata_parser.h" #include "content/public/common/content_paths.h" @@ -80,9 +79,6 @@ ExtensionsHandler::~ExtensionsHandler() { // static void ExtensionsHandler::PreSandboxStartup() { - // Initialize libexif for image metadata parsing. - metadata::ImageMetadataExtractor::InitializeLibrary(); - // Initialize media libraries for media file validation. media::InitializeMediaLibrary(); } diff --git a/chrome/utility/media_galleries/image_metadata_extractor.cc b/chrome/utility/media_galleries/image_metadata_extractor.cc deleted file mode 100644 index 471d481a..0000000 --- a/chrome/utility/media_galleries/image_metadata_extractor.cc +++ /dev/null @@ -1,465 +0,0 @@ -// Copyright 2014 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. - -#include "chrome/utility/media_galleries/image_metadata_extractor.h" - -extern "C" { -#include <libexif/exif-data.h> -#include <libexif/exif-loader.h> -} // extern "C" -#include <stddef.h> -#include <stdint.h> - -#include "base/bind.h" -#include "base/callback.h" -#include "base/files/file_path.h" -#include "base/lazy_instance.h" -#include "base/macros.h" -#include "base/memory/ref_counted.h" -#include "base/numerics/safe_conversions.h" -#include "base/path_service.h" -#include "base/scoped_native_library.h" -#include "base/strings/string_number_conversions.h" -#include "build/build_config.h" -#include "content/public/common/content_paths.h" -#include "media/base/data_source.h" -#include "net/base/io_buffer.h" - -namespace metadata { - -namespace { - -const size_t kMaxBufferSize = 50 * 1024 * 1024; // Arbitrary maximum of 50MB. - -typedef base::Callback<void(const scoped_refptr<net::DrainableIOBuffer>&)> - GotImageCallback; - -void FinishGetImageBytes( - const scoped_refptr<net::DrainableIOBuffer>& buffer, - media::DataSource* source, - const GotImageCallback& callback, - int bytes_read) { - if (bytes_read == media::DataSource::kReadError) { - callback.Run(NULL); - return; - } - - buffer->DidConsume(bytes_read); - // Didn't get the whole file. Continue reading to get the rest. - if (buffer->BytesRemaining() > 0) { - source->Read(0, buffer->BytesRemaining(), - reinterpret_cast<uint8_t*>(buffer->data()), - base::Bind(&FinishGetImageBytes, buffer, - base::Unretained(source), callback)); - return; - } - - buffer->SetOffset(0); - callback.Run(buffer); -} - -void GetImageBytes( - media::DataSource* source, - const GotImageCallback& callback) { - int64_t size64 = 0; - if (!source->GetSize(&size64) || - base::saturated_cast<size_t>(size64) > kMaxBufferSize) { - return callback.Run(NULL); - } - int size = base::checked_cast<int>(size64); - - scoped_refptr<net::DrainableIOBuffer> buffer( - new net::DrainableIOBuffer(new net::IOBuffer(size), size)); - source->Read(0, buffer->BytesRemaining(), - reinterpret_cast<uint8_t*>(buffer->data()), - base::Bind(&FinishGetImageBytes, buffer, - base::Unretained(source), callback)); -} - -class ExifFunctions { - public: - ExifFunctions() : exif_loader_write_func_(NULL), - exif_loader_new_func_(NULL), - exif_loader_unref_func_(NULL), - exif_loader_get_data_func_(NULL), - exif_data_free_func_(NULL), - exif_data_get_byte_order_func_(NULL), - exif_get_short_func_(NULL), - exif_get_long_func_(NULL), - exif_get_rational_func_(NULL), - exif_entry_get_value_func_(NULL), - exif_content_get_entry_func_(NULL) { - } - - bool Initialize(const base::FilePath& module_dir) { - if (exif_lib_.is_valid()) - return true; - -#if defined(OS_WIN) - base::FilePath module_path = module_dir.AppendASCII("libexif.dll"); -#elif defined(OS_MACOSX) - base::FilePath module_path = module_dir.AppendASCII("exif.so"); -#elif defined(OS_CHROMEOS) - // On ChromeOS, we build and distribute our own version of libexif. - base::FilePath module_path = module_dir.AppendASCII("libexif.so"); -#else - // On Linux-like systems, we use the system libexif. - base::FilePath module_path = base::FilePath().AppendASCII("libexif.so.12"); -#endif - - base::NativeLibraryLoadError error; - base::ScopedNativeLibrary lib(base::LoadNativeLibrary(module_path, &error)); - if (!lib.is_valid()) { - LOG(ERROR) << "Couldn't load libexif. " << error.ToString(); - return false; - } - - if (!GetFunctionPointer(lib, &exif_loader_write_func_, - "exif_loader_write") || - !GetFunctionPointer(lib, &exif_loader_new_func_, "exif_loader_new") || - !GetFunctionPointer(lib, &exif_loader_unref_func_, - "exif_loader_unref") || - !GetFunctionPointer(lib, &exif_loader_get_data_func_, - "exif_loader_get_data") || - !GetFunctionPointer(lib, &exif_data_free_func_, "exif_data_free") || - !GetFunctionPointer(lib, &exif_data_get_byte_order_func_, - "exif_data_get_byte_order") || - !GetFunctionPointer(lib, &exif_get_short_func_, "exif_get_short") || - !GetFunctionPointer(lib, &exif_get_long_func_, "exif_get_long") || - !GetFunctionPointer(lib, &exif_get_rational_func_, - "exif_get_rational") || - !GetFunctionPointer(lib, &exif_entry_get_value_func_, - "exif_entry_get_value") || - !GetFunctionPointer(lib, &exif_content_get_entry_func_, - "exif_content_get_entry")) { - return false; - } - - exif_lib_.Reset(lib.Release()); - return true; - } - - ExifData* ParseExifFromBuffer(unsigned char* buffer, unsigned int size) { - DCHECK(exif_lib_.is_valid()); - ExifLoader* loader = exif_loader_new_func_(); - exif_loader_write_func_(loader, buffer, size); - - ExifData* data = exif_loader_get_data_func_(loader); - - exif_loader_unref_func_(loader); - loader = NULL; - - return data; - } - - void ExifDataFree(ExifData* data) { - DCHECK(exif_lib_.is_valid()); - return exif_data_free_func_(data); - } - - void ExtractInt(ExifData* data, ExifTag tag, int* result) { - DCHECK(exif_lib_.is_valid()); - DCHECK(result); - - ExifEntry* entry = ExifContentGetEntry(data, tag); - if (!entry) - return; - - ExifByteOrder order = exif_data_get_byte_order_func_(data); - switch (entry->format) { - case EXIF_FORMAT_SHORT: { - ExifShort v = exif_get_short_func_(entry->data, order); - *result = base::checked_cast<int>(v); - break; - } - case EXIF_FORMAT_LONG: { - ExifLong v = exif_get_long_func_(entry->data, order); - // Ignore values that don't fit in a signed int - likely invalid data. - if (base::IsValueInRangeForNumericType<int>(v)) - *result = base::checked_cast<int>(v); - break; - } - default: { - // Ignore all other entry formats. - } - } - } - - void ExtractDouble(ExifData* data, ExifTag tag, double* result) { - DCHECK(exif_lib_.is_valid()); - DCHECK(result); - - ExifEntry* entry = ExifContentGetEntry(data, tag); - if (!entry) - return; - - ExifByteOrder order = exif_data_get_byte_order_func_(data); - - if (entry->format == EXIF_FORMAT_RATIONAL) { - ExifRational v = exif_get_rational_func_(entry->data, order); - *result = base::checked_cast<double>(v.numerator) / - base::checked_cast<double>(v.denominator); - } - } - - void ExtractString(ExifData* data, ExifTag tag, std::string* result) { - DCHECK(exif_lib_.is_valid()); - DCHECK(result); - - ExifEntry* entry = ExifContentGetEntry(data, tag); - if (!entry) - return; - - char buf[1024]; - exif_entry_get_value_func_(entry, buf, sizeof(buf)); - *result = buf; - } - - private: - // Exported by libexif. - typedef unsigned char (*ExifLoaderWriteFunc)(ExifLoader* eld, - unsigned char* buf, - unsigned int len); - typedef ExifLoader* (*ExifLoaderNewFunc)(); - typedef void (*ExifLoaderUnrefFunc)(ExifLoader* loader); - typedef ExifData* (*ExifLoaderGetDataFunc)(ExifLoader* loader); - typedef void (*ExifDataFreeFunc)(ExifData* data); - typedef ExifByteOrder (*ExifDataGetByteOrderFunc)(ExifData* data); - typedef ExifShort (*ExifGetShortFunc)(const unsigned char *buf, - ExifByteOrder order); - typedef ExifLong (*ExifGetLongFunc)(const unsigned char *buf, - ExifByteOrder order); - typedef ExifRational (*ExifGetRationalFunc)(const unsigned char *buf, - ExifByteOrder order); - typedef const char* (*ExifEntryGetValueFunc)(ExifEntry *e, char *val, - unsigned int maxlen); - typedef ExifEntry* (*ExifContentGetEntryFunc)(ExifContent* content, - ExifTag tag); - - template<typename FunctionType> - bool GetFunctionPointer(const base::ScopedNativeLibrary& lib, - FunctionType* function, const char* name) { - DCHECK(lib.is_valid()); - DCHECK(function); - DCHECK(!(*function)); - *function = reinterpret_cast<FunctionType>( - lib.GetFunctionPointer(name)); - DLOG_IF(WARNING, !(*function)) << "Missing " << name; - return *function != NULL; - } - - // Redefines exif_content_get_entry macro in terms of function pointer. - ExifEntry* ExifContentGetEntry(ExifData* data, ExifTag tag) { - DCHECK(exif_lib_.is_valid()); - const ExifIfd ifds[] = - { EXIF_IFD_0, EXIF_IFD_1, EXIF_IFD_EXIF, EXIF_IFD_GPS }; - - for (size_t i = 0; i < arraysize(ifds); ++i) { - ExifEntry* entry = exif_content_get_entry_func_(data->ifd[ifds[i]], tag); - if (entry) - return entry; - } - - return NULL; - } - - ExifLoaderWriteFunc exif_loader_write_func_; - ExifLoaderNewFunc exif_loader_new_func_; - ExifLoaderUnrefFunc exif_loader_unref_func_; - ExifLoaderGetDataFunc exif_loader_get_data_func_; - ExifDataFreeFunc exif_data_free_func_; - ExifDataGetByteOrderFunc exif_data_get_byte_order_func_; - ExifGetShortFunc exif_get_short_func_; - ExifGetLongFunc exif_get_long_func_; - ExifGetRationalFunc exif_get_rational_func_; - ExifEntryGetValueFunc exif_entry_get_value_func_; - ExifContentGetEntryFunc exif_content_get_entry_func_; - - base::ScopedNativeLibrary exif_lib_; - DISALLOW_COPY_AND_ASSIGN(ExifFunctions); -}; - -static base::LazyInstance<ExifFunctions> g_exif_lib = LAZY_INSTANCE_INITIALIZER; - -} // namespace - -// static -bool ImageMetadataExtractor::InitializeLibrary() { - base::FilePath media_path; - if (!PathService::Get(content::DIR_MEDIA_LIBS, &media_path)) - return false; - return g_exif_lib.Get().Initialize(media_path); -} - -// static -bool ImageMetadataExtractor::InitializeLibraryForTesting() { - base::FilePath module_dir; - if (!PathService::Get(base::DIR_EXE, &module_dir)) - return false; - return g_exif_lib.Get().Initialize(module_dir); -} - -ImageMetadataExtractor::ImageMetadataExtractor() - : extracted_(false), - width_(-1), - height_(-1), - rotation_(-1), - x_resolution_(-1), - y_resolution_(-1), - exposure_time_sec_(-1), - flash_fired_(false), - f_number_(-1), - focal_length_mm_(-1), - iso_equivalent_(-1) { -} - -ImageMetadataExtractor::~ImageMetadataExtractor() { -} - -void ImageMetadataExtractor::Extract(media::DataSource* source, - const DoneCallback& callback) { - DCHECK(!extracted_); - - GetImageBytes(source, base::Bind(&ImageMetadataExtractor::FinishExtraction, - base::Unretained(this), callback)); -} - -int ImageMetadataExtractor::width() const { - DCHECK(extracted_); - return width_; -} - -int ImageMetadataExtractor::height() const { - DCHECK(extracted_); - return height_; -} - -int ImageMetadataExtractor::rotation() const { - DCHECK(extracted_); - return rotation_; -} - -double ImageMetadataExtractor::x_resolution() const { - DCHECK(extracted_); - return x_resolution_; -} - -double ImageMetadataExtractor::y_resolution() const { - DCHECK(extracted_); - return y_resolution_; -} - -const std::string& ImageMetadataExtractor::date() const { - DCHECK(extracted_); - return date_; -} - -const std::string& ImageMetadataExtractor::camera_make() const { - DCHECK(extracted_); - return camera_make_; -} - -const std::string& ImageMetadataExtractor::camera_model() const { - DCHECK(extracted_); - return camera_model_; -} - -double ImageMetadataExtractor::exposure_time_sec() const { - DCHECK(extracted_); - return exposure_time_sec_; -} - -bool ImageMetadataExtractor::flash_fired() const { - DCHECK(extracted_); - return flash_fired_; -} - -double ImageMetadataExtractor::f_number() const { - DCHECK(extracted_); - return f_number_; -} - -double ImageMetadataExtractor::focal_length_mm() const { - DCHECK(extracted_); - return focal_length_mm_; -} - -int ImageMetadataExtractor::iso_equivalent() const { - DCHECK(extracted_); - return iso_equivalent_; -} - -void ImageMetadataExtractor::FinishExtraction( - const DoneCallback& callback, - const scoped_refptr<net::DrainableIOBuffer>& buffer) { - if (!buffer.get()) { - callback.Run(false); - return; - } - - ExifData* data = g_exif_lib.Get().ParseExifFromBuffer( - reinterpret_cast<unsigned char*>(buffer->data()), - buffer->BytesRemaining()); - - if (!data) { - callback.Run(false); - return; - } - - g_exif_lib.Get().ExtractInt(data, EXIF_TAG_IMAGE_WIDTH, &width_); - g_exif_lib.Get().ExtractInt(data, EXIF_TAG_IMAGE_LENGTH, &height_); - - // We ignore the mirrored-aspect of the mirrored-orientations and just - // indicate the rotation. Mirrored-orientations are very rare. - int orientation = 0; - g_exif_lib.Get().ExtractInt(data, EXIF_TAG_ORIENTATION, &orientation); - switch (orientation) { - case 1: - case 2: - rotation_ = 0; - break; - case 3: - case 4: - rotation_ = 180; - break; - case 5: - case 6: - rotation_ = 90; - break; - case 7: - case 8: - rotation_ = 270; - break; - } - - g_exif_lib.Get().ExtractDouble(data, EXIF_TAG_X_RESOLUTION, &x_resolution_); - g_exif_lib.Get().ExtractDouble(data, EXIF_TAG_Y_RESOLUTION, &y_resolution_); - - g_exif_lib.Get().ExtractString(data, EXIF_TAG_DATE_TIME, &date_); - - g_exif_lib.Get().ExtractString(data, EXIF_TAG_MAKE, &camera_make_); - g_exif_lib.Get().ExtractString(data, EXIF_TAG_MODEL, &camera_model_); - g_exif_lib.Get().ExtractDouble(data, EXIF_TAG_EXPOSURE_TIME, - &exposure_time_sec_); - - int flash_value = -1; - g_exif_lib.Get().ExtractInt(data, EXIF_TAG_FLASH, &flash_value); - if (flash_value >= 0) { - flash_fired_ = (flash_value & 0x1) != 0; - } - - g_exif_lib.Get().ExtractDouble(data, EXIF_TAG_FNUMBER, &f_number_); - g_exif_lib.Get().ExtractDouble(data, EXIF_TAG_FOCAL_LENGTH, - &focal_length_mm_); - g_exif_lib.Get().ExtractInt(data, EXIF_TAG_ISO_SPEED_RATINGS, - &iso_equivalent_); - - g_exif_lib.Get().ExifDataFree(data); - - extracted_ = true; - - callback.Run(true); -} - -} // namespace metadata diff --git a/chrome/utility/media_galleries/image_metadata_extractor.h b/chrome/utility/media_galleries/image_metadata_extractor.h deleted file mode 100644 index 5a5e9b0..0000000 --- a/chrome/utility/media_galleries/image_metadata_extractor.h +++ /dev/null @@ -1,95 +0,0 @@ -// Copyright 2014 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. - -#ifndef CHROME_UTILITY_MEDIA_GALLERIES_IMAGE_METADATA_EXTRACTOR_H_ -#define CHROME_UTILITY_MEDIA_GALLERIES_IMAGE_METADATA_EXTRACTOR_H_ - -#include <string> - -#include "base/callback_forward.h" -#include "base/macros.h" -#include "base/memory/ref_counted.h" - -namespace media { -class DataSource; -} - -namespace net { -class DrainableIOBuffer; -} - -namespace metadata { - -// Extracts a basic set of image metadata tags. Users must initialize the -// library before use. Each class instance is 'one-time-use', and cannot be used -// to extract metadata from multiple images. -class ImageMetadataExtractor { - public: - typedef base::Callback<void(bool)> DoneCallback; - - // One of these two is required before use of this class. - static bool InitializeLibrary(); - static bool InitializeLibraryForTesting(); - - ImageMetadataExtractor(); - ~ImageMetadataExtractor(); - - // |callback| called with whether or not the extraction succeeded. Should - // only be called once. - void Extract(media::DataSource* source, const DoneCallback& callback); - - // All below methods require Extract to have already succeeded. - // Returns -1 if file does not define a width or height. - int width() const; - int height() const; - - // In degrees. - int rotation() const; - - // In pixels per inch. - double x_resolution() const; - double y_resolution() const; - - // In the same string form as the original file. - const std::string& date() const; - - const std::string& camera_make() const; - const std::string& camera_model() const; - double exposure_time_sec() const; - bool flash_fired() const; - double f_number() const; - double focal_length_mm() const; - int iso_equivalent() const; - - private: - // Second half of the Extract method. - void FinishExtraction(const DoneCallback& callback, - const scoped_refptr<net::DrainableIOBuffer>& buffer); - - bool extracted_; - - int width_; - int height_; - - int rotation_; - - double x_resolution_; - double y_resolution_; - - std::string date_; - - std::string camera_make_; - std::string camera_model_; - double exposure_time_sec_; - bool flash_fired_; - double f_number_; - double focal_length_mm_; - int iso_equivalent_; - - DISALLOW_COPY_AND_ASSIGN(ImageMetadataExtractor); -}; - -} // namespace metadata - -#endif // CHROME_UTILITY_MEDIA_GALLERIES_IMAGE_METADATA_EXTRACTOR_H_ diff --git a/chrome/utility/media_galleries/image_metadata_extractor_unittest.cc b/chrome/utility/media_galleries/image_metadata_extractor_unittest.cc deleted file mode 100644 index 06206bb..0000000 --- a/chrome/utility/media_galleries/image_metadata_extractor_unittest.cc +++ /dev/null @@ -1,76 +0,0 @@ -// Copyright 2014 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. - -#include "base/bind.h" -#include "base/files/file_path.h" -#include "base/path_service.h" -#include "base/run_loop.h" -#include "chrome/common/chrome_paths.h" -#include "chrome/utility/media_galleries/image_metadata_extractor.h" -#include "media/filters/file_data_source.h" -#include "testing/gtest/include/gtest/gtest.h" - -namespace metadata { - -void QuitLoop(base::RunLoop* loop, bool* output, bool success) { - loop->Quit(); - *output = success; -} - -base::FilePath GetTestDataFilePath(const std::string& filename) { - base::FilePath path; - EXPECT_TRUE(PathService::Get(chrome::DIR_TEST_DATA, &path)); - path = path.AppendASCII("extensions").AppendASCII("api_test") - .AppendASCII("wallpaper").AppendASCII(filename); - return path; -} - -scoped_ptr<ImageMetadataExtractor> GetExtractor( - const std::string& filename, - bool expected_result) { - EXPECT_TRUE(ImageMetadataExtractor::InitializeLibraryForTesting()); - - media::FileDataSource source; - base::FilePath test_path; - - EXPECT_TRUE(source.Initialize(GetTestDataFilePath(filename))); - - scoped_ptr<ImageMetadataExtractor> extractor(new ImageMetadataExtractor); - - base::RunLoop loop; - bool extracted = false; - extractor->Extract(&source, base::Bind(&QuitLoop, &loop, &extracted)); - EXPECT_EQ(expected_result, extracted); - - return extractor; -} - -TEST(ImageMetadataExtractorTest, JPGFile) { - scoped_ptr<ImageMetadataExtractor> extractor = - GetExtractor("test.jpg", true); - - EXPECT_EQ(5616, extractor->width()); - EXPECT_EQ(3744, extractor->height()); - EXPECT_EQ(0, extractor->rotation()); - EXPECT_EQ(300.0, extractor->x_resolution()); - EXPECT_EQ(300.0, extractor->y_resolution()); - EXPECT_EQ("2012:03:01 17:06:07", extractor->date()); - EXPECT_EQ("Canon", extractor->camera_make()); - EXPECT_EQ("Canon EOS 5D Mark II", extractor->camera_model()); - EXPECT_EQ(0.01, extractor->exposure_time_sec()); - EXPECT_FALSE(extractor->flash_fired()); - EXPECT_EQ(3.2, extractor->f_number()); - EXPECT_EQ(100, extractor->focal_length_mm()); - EXPECT_EQ(1600, extractor->iso_equivalent()); -} - -TEST(ImageMetadataExtractorTest, PNGFile) { - GetExtractor("test.png", false); -} - -TEST(ImageMetadataExtractorTest, NonImageFile) { - GetExtractor("test.js", false); -} - -} // namespace metadata diff --git a/chrome/utility/media_galleries/media_metadata_parser.cc b/chrome/utility/media_galleries/media_metadata_parser.cc index 3d6e733..d5df856 100644 --- a/chrome/utility/media_galleries/media_metadata_parser.cc +++ b/chrome/utility/media_galleries/media_metadata_parser.cc @@ -12,7 +12,6 @@ #include "base/strings/string_util.h" #include "base/task_runner_util.h" #include "base/threading/thread.h" -#include "chrome/utility/media_galleries/image_metadata_extractor.h" #include "media/base/audio_video_metadata_extractor.h" #include "media/base/data_source.h" #include "net/base/mime_sniffer.h" @@ -36,17 +35,6 @@ void SetIntScopedPtr(int value, scoped_ptr<int>* destination) { destination->reset(new int(value)); } -void SetDoubleScopedPtr(double value, scoped_ptr<double>* destination) { - DCHECK(destination); - if (value >= 0) - destination->reset(new double(value)); -} - -void SetBoolScopedPtr(bool value, scoped_ptr<bool>* destination) { - DCHECK(destination); - destination->reset(new bool(value)); -} - // This runs on |media_thread_|, as the underlying FFmpeg operation is // blocking, and the utility thread must not be blocked, so the media file // bytes can be sent from the browser process to the utility process. @@ -124,38 +112,6 @@ void FinishParseAudioVideoMetadata( callback.Run(*metadata, *attached_images); } -void FinishParseImageMetadata( - ImageMetadataExtractor* extractor, const std::string& mime_type, - MediaMetadataParser::MetadataCallback callback, bool extract_success) { - DCHECK(extractor); - MediaMetadataParser::MediaMetadata metadata; - metadata.mime_type = mime_type; - - if (!extract_success) { - callback.Run(metadata, std::vector<AttachedImage>()); - return; - } - - SetIntScopedPtr(extractor->height(), &metadata.height); - SetIntScopedPtr(extractor->width(), &metadata.width); - - SetIntScopedPtr(extractor->rotation(), &metadata.rotation); - - SetDoubleScopedPtr(extractor->x_resolution(), &metadata.x_resolution); - SetDoubleScopedPtr(extractor->y_resolution(), &metadata.y_resolution); - SetBoolScopedPtr(extractor->flash_fired(), &metadata.flash_fired); - SetStringScopedPtr(extractor->camera_make(), &metadata.camera_make); - SetStringScopedPtr(extractor->camera_model(), &metadata.camera_model); - SetDoubleScopedPtr(extractor->exposure_time_sec(), - &metadata.exposure_time_seconds); - - SetDoubleScopedPtr(extractor->f_number(), &metadata.f_number); - SetDoubleScopedPtr(extractor->focal_length_mm(), &metadata.focal_length_mm); - SetDoubleScopedPtr(extractor->iso_equivalent(), &metadata.iso_equivalent); - - callback.Run(metadata, std::vector<AttachedImage>()); -} - } // namespace MediaMetadataParser::MediaMetadataParser(media::DataSource* source, @@ -186,15 +142,6 @@ void MediaMetadataParser::Start(const MetadataCallback& callback) { return; } - if (base::StartsWith(mime_type_, "image/", base::CompareCase::SENSITIVE)) { - ImageMetadataExtractor* extractor = new ImageMetadataExtractor; - extractor->Extract( - source_, - base::Bind(&FinishParseImageMetadata, base::Owned(extractor), - mime_type_, callback)); - return; - } - callback.Run(MediaMetadata(), std::vector<AttachedImage>()); } diff --git a/chrome/utility/media_galleries/media_metadata_parser.h b/chrome/utility/media_galleries/media_metadata_parser.h index 44c44ac..aee7a7f 100644 --- a/chrome/utility/media_galleries/media_metadata_parser.h +++ b/chrome/utility/media_galleries/media_metadata_parser.h @@ -25,10 +25,9 @@ class DataSource; namespace metadata { // This class takes a MIME type and data source and parses its metadata. It -// handles audio, video, and images. It delegates its operations to FFMPEG, -// libexif, etc. This class lives and operates on the utility thread of the -// utility process, as we wish to sandbox potentially dangerous operations -// on user-provided data. +// handles audio, video, and images. It delegates its operations to FFMPEG. +// This class lives and operates on the utility thread of the utility process, +// as we wish to sandbox potentially dangerous operations on user-provided data. class MediaMetadataParser { public: typedef extensions::api::media_galleries::MediaMetadata MediaMetadata; diff --git a/testing/chromoting/chromoting_browser_tests.isolate b/testing/chromoting/chromoting_browser_tests.isolate index 1c81b5a..2263b08 100644 --- a/testing/chromoting/chromoting_browser_tests.isolate +++ b/testing/chromoting/chromoting_browser_tests.isolate @@ -80,7 +80,6 @@ 'variables': { 'files': [ '<(PRODUCT_DIR)/<(mac_product_name).app/', - '<(PRODUCT_DIR)/exif.so', ], }, }], diff --git a/testing/libfuzzer/fuzzers/BUILD.gn b/testing/libfuzzer/fuzzers/BUILD.gn index 56a4257..95e4046 100644 --- a/testing/libfuzzer/fuzzers/BUILD.gn +++ b/testing/libfuzzer/fuzzers/BUILD.gn @@ -233,18 +233,6 @@ fuzzer_test("unicode_string_codepage_create_fuzzer") { ] } -if (is_linux) { - # libexif_fuzzer is linux only atm - fuzzer_test("libexif_parser_fuzzer") { - sources = [ - "libexif_parser_fuzzer.cc", - ] - deps = [ - "//third_party/libexif:libexif_fuzzers", - ] - } -} - fuzzer_test("libpng_read_fuzzer") { sources = [ "libpng_read_fuzzer.cc", diff --git a/testing/libfuzzer/fuzzers/libexif_parser_fuzzer.cc b/testing/libfuzzer/fuzzers/libexif_parser_fuzzer.cc deleted file mode 100644 index 3e15edb..0000000 --- a/testing/libfuzzer/fuzzers/libexif_parser_fuzzer.cc +++ /dev/null @@ -1,15 +0,0 @@ -// Copyright 2015 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. - -#include <stddef.h> -#include <stdint.h> - -#include "libexif/exif-data.h" -#include "libexif/exif-system.h" - -extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) { - ExifData* exif_data = exif_data_new_from_data(data, size); - exif_data_unref(exif_data); - return 0; -} diff --git a/third_party/libexif/BUILD.gn b/third_party/libexif/BUILD.gn deleted file mode 100644 index 43f3274..0000000 --- a/third_party/libexif/BUILD.gn +++ /dev/null @@ -1,115 +0,0 @@ -# Copyright 2015 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. - -# Linux should use system libexif - -config("libexif_public_config") { - include_dirs = [ "sources" ] -} - -config("libexif_warnings") { - if (is_clang) { - cflags = [ - "-Wno-enum-conversion", - "-Wno-switch", - "-Wno-format", - - # libexif uses fabs(int) to cast to float. - "-Wno-absolute-value", - ] - } -} - -libexif_sources = [ - "sources/libexif/canon/exif-mnote-data-canon.c", - "sources/libexif/canon/mnote-canon-entry.c", - "sources/libexif/canon/mnote-canon-tag.c", - "sources/libexif/exif-byte-order.c", - "sources/libexif/exif-content.c", - "sources/libexif/exif-data.c", - "sources/libexif/exif-entry.c", - "sources/libexif/exif-format.c", - "sources/libexif/exif-ifd.c", - "sources/libexif/exif-loader.c", - "sources/libexif/exif-log.c", - "sources/libexif/exif-mem.c", - "sources/libexif/exif-mnote-data.c", - "sources/libexif/exif-tag.c", - "sources/libexif/exif-utils.c", - "sources/libexif/fuji/exif-mnote-data-fuji.c", - "sources/libexif/fuji/mnote-fuji-entry.c", - "sources/libexif/fuji/mnote-fuji-tag.c", - "sources/libexif/olympus/exif-mnote-data-olympus.c", - "sources/libexif/olympus/mnote-olympus-entry.c", - "sources/libexif/olympus/mnote-olympus-tag.c", - "sources/libexif/pentax/exif-mnote-data-pentax.c", - "sources/libexif/pentax/mnote-pentax-entry.c", - "sources/libexif/pentax/mnote-pentax-tag.c", -] - -if (!is_linux || is_chromeos) { - loadable_module("libexif") { - if (is_mac) { - # Matches the output from GYP. - output_name = "exif" - } - sources = libexif_sources - - include_dirs = [ "sources" ] - - # TODO(GYP): Additional options for non-Windows platforms. - - if (is_win) { - import("//build/config/win/visual_studio_version.gni") - - if (visual_studio_version == "2013" || visual_studio_version == "2013e") { - defines = [ - # This seems like a hack, but this is what WebKit Win does. - # VS 2015 supports these natively so they cannot be #defines. - "snprintf=_snprintf", - "inline=__inline", - ] - } - - ldflags = [ "/DEF:" + rebase_path("libexif.def") ] - - cflags = [ "/wd4018" ] # Signed/unsigned mismatch in comparison. - - # TODO(GYP): Handle /analyze switch, when it will be used in GN. - } else if (is_linux) { - libs = [ "m" ] - } - - configs -= [ "//build/config/compiler:chromium_code" ] - configs += [ - "//build/config/compiler:no_chromium_code", - - # Must be after no_chromium_code for warning flags to be ordered properly. - ":libexif_warnings", - ] - - public_configs = [ ":libexif_public_config" ] - } -} - -if (is_linux) { - # used by libfuzzer fuzzers only atm. - source_set("libexif_fuzzers") { - sources = libexif_sources - - include_dirs = [ "sources" ] - - libs = [ "m" ] - - configs -= [ "//build/config/compiler:chromium_code" ] - configs += [ - "//build/config/compiler:no_chromium_code", - - # Must be after no_chromium_code for warning flags to be ordered properly. - ":libexif_warnings", - ] - - public_configs = [ ":libexif_public_config" ] - } -} diff --git a/third_party/libexif/OWNERS b/third_party/libexif/OWNERS deleted file mode 100644 index e424ab1..0000000 --- a/third_party/libexif/OWNERS +++ /dev/null @@ -1,2 +0,0 @@ -thestig@chromium.org -vandebo@chromium.org diff --git a/third_party/libexif/README.chromium b/third_party/libexif/README.chromium deleted file mode 100644 index 60facdc..0000000 --- a/third_party/libexif/README.chromium +++ /dev/null @@ -1,26 +0,0 @@ -Name: libexif -URL: http://libexif.sourceforge.net/ -Version: 0.6.21 -License: LGPL 2.1 -License File: sources/COPYING -Date: 2012-06-04 -Security Critical: yes - -Description: -libexif is a library for parsing, editing, and saving EXIF data. Many maker -notes from Canon, Casio, Epson, Fuji, Nikon, Olympus, Pentax and Sanyo cameras -are also supported. - -Local Modifications: -- Added license header to exif-mem.c. Please refer to chromium.patch. -- config.h and _stdint.h has been modified to build on all platforms. Please - refer to chromium.patch. -- Added BIND_TEXTDOMAIN macro to conditionally bind the text domain to locale - directory. Please refer to chromium.patch. -- Removed ABOUT-NLS, *.m4, *-m4, binary, ChangeLog, config*, contrib, depcomp, - INSTALL, install-sh, Makefile-files, *.sym, *.am, *.in, *.pc.in, *.spec, *.sh - and *.txt files. -- Removed "doc", "po", "NEWS", "mkinstalldirs", "missing", "nls" folders. -- Removed inline from exif_tag_table_count function in exif-tag.c, to build - cleanly with MSVC's non-standard inline rules. -- https://codereview.chromium.org/1585593002 diff --git a/third_party/libexif/README.security b/third_party/libexif/README.security deleted file mode 100644 index d194b90..0000000 --- a/third_party/libexif/README.security +++ /dev/null @@ -1 +0,0 @@ -This library has NOT been approved for unsandboxed usage. Contact security@chromium.org for any questions. diff --git a/third_party/libexif/chromium.patch b/third_party/libexif/chromium.patch deleted file mode 100644 index 79e6a77..0000000 --- a/third_party/libexif/chromium.patch +++ /dev/null @@ -1,571 +0,0 @@ -diff -urN libexif-0.6.21/config.h libexif-0.6.21.modified/config.h ---- libexif-0.6.21/config.h 1969-12-31 16:00:00.000000000 -0800 -+++ libexif-0.6.21.modified/config.h 1969-12-31 16:00:00.000000000 -0800 -@@ -0,0 +1,360 @@ -+#if defined(_WIN32) -+/* config.h. Generated by configure. */ -+/* config.h.in. Generated from configure.ac by autoheader. */ -+ -+/* Define to 1 if translation of program messages to the user's native -+ language is requested. */ -+/* #undef ENABLE_NLS 1 */ -+ -+/* The gettext domain we're using */ -+/* #undef GETTEXT_PACKAGE "libexif-12" */ -+ -+/* Define locale directory. */ -+/* #undef LOCALEDIR "UTF-8" */ -+ -+/* Define to 1 if we want to bind text domain and enable GETTEXT_PACKAGE and -+ * LOCALE_DIR */ -+/* #undef BIND_TEXTDOMAIN 1 */ -+ -+/* Define if the GNU dcgettext() function is already present or preinstalled. -+ */ -+/* #undef HAVE_DCGETTEXT 1 */ -+ -+/* Define to 1 if you have the <dlfcn.h> header file. */ -+#define HAVE_DLFCN_H 1 -+ -+/* Define if the GNU gettext() function is already present or preinstalled. */ -+#define HAVE_GETTEXT 1 -+ -+/* Define if you have the iconv() function. */ -+#define HAVE_ICONV 1 -+ -+/* Define to 1 if you have the <inttypes.h> header file. */ -+#define HAVE_INTTYPES_H 1 -+ -+/* Define to 1 if you have the <memory.h> header file. */ -+#define HAVE_MEMORY_H 1 -+ -+/* Define to 1 if you have the <stdint.h> header file. */ -+/* #undef HAVE_STDINT_H 1 */ -+ -+/* Define to 1 if you have the <stdlib.h> header file. */ -+#define HAVE_STDLIB_H 1 -+ -+/* Define to 1 if you have the <strings.h> header file. */ -+#define HAVE_STRINGS_H 1 -+ -+/* Define to 1 if you have the <string.h> header file. */ -+#define HAVE_STRING_H 1 -+ -+/* Define to 1 if you have the <sys/stat.h> header file. */ -+#define HAVE_SYS_STAT_H 1 -+ -+/* Define to 1 if you have the <sys/types.h> header file. */ -+#define HAVE_SYS_TYPES_H 1 -+ -+/* Define to 1 if you have the <unistd.h> header file. */ -+#define HAVE_UNISTD_H 1 -+ -+/* Define as const if the declaration of iconv() needs const. */ -+#define ICONV_CONST -+ -+/* Name of package */ -+#define PACKAGE "libexif" -+ -+/* Define to the address where bug reports for this package should be sent. */ -+#define PACKAGE_BUGREPORT "libexif-devel@lists.sourceforge.net" -+ -+/* Define to the full name of this package. */ -+#define PACKAGE_NAME "EXIF library" -+ -+/* Define to the full name and version of this package. */ -+#define PACKAGE_STRING "EXIF library 0.6.21" -+ -+/* Define to the one symbol short name of this package. */ -+#define PACKAGE_TARNAME "libexif" -+ -+/* Define to the version of this package. */ -+#define PACKAGE_VERSION "0.6.21" -+ -+/* Define to 1 if you have the ANSI C header files. */ -+#define STDC_HEADERS 1 -+ -+/* Version number of package */ -+#define VERSION "0.6.21" -+ -+#elif !defined(__APPLE__) -+/* config.h. Generated by configure. */ -+/* config.h.in. Generated from configure.ac by autoheader. */ -+ -+/* #define __cplusplus 1 */ -+#define LOCALEDIR "UTF-8" -+ -+/* Define to 1 if translation of program messages to the user's native -+ language is requested. */ -+/* #undef ENABLE_NLS */ -+ -+/* The gettext domain we're using */ -+/* #undef GETTEXT_PACKAGE "libexif-12" */ -+ -+/* Define locale directory. */ -+/* #undef LOCALEDIR "UTF-8" */ -+ -+/* Define to 1 if we want to bind text domain and enable GETTEXT_PACKAGE and -+ * LOCALE_DIR */ -+/* #undef BIND_TEXTDOMAIN 1 */ -+ -+/* Define if the GNU dcgettext() function is already present or preinstalled. -+ */ -+#define HAVE_DCGETTEXT 1 -+ -+/* Define to 1 if you have the <dlfcn.h> header file. */ -+#define HAVE_DLFCN_H 1 -+ -+/* Define if the GNU gettext() function is already present or preinstalled. */ -+#define HAVE_GETTEXT 1 -+ -+/* Define if you have the iconv() function. */ -+#define HAVE_ICONV 1 -+ -+/* Define to 1 if you have the <inttypes.h> header file. */ -+#define HAVE_INTTYPES_H 1 -+ -+/* Define to 1 if you have the <memory.h> header file. */ -+#define HAVE_MEMORY_H 1 -+ -+/* Define to 1 if you have the <stdint.h> header file. */ -+#define HAVE_STDINT_H 1 -+ -+/* Define to 1 if you have the <stdlib.h> header file. */ -+#define HAVE_STDLIB_H 1 -+ -+/* Define to 1 if you have the <strings.h> header file. */ -+#define HAVE_STRINGS_H 1 -+ -+/* Define to 1 if you have the <string.h> header file. */ -+#define HAVE_STRING_H 1 -+ -+/* Define to 1 if you have the <sys/stat.h> header file. */ -+#define HAVE_SYS_STAT_H 1 -+ -+/* Define to 1 if you have the <sys/types.h> header file. */ -+#define HAVE_SYS_TYPES_H 1 -+ -+/* Define to 1 if you have the <unistd.h> header file. */ -+#define HAVE_UNISTD_H 1 -+ -+/* Define as const if the declaration of iconv() needs const. */ -+#define ICONV_CONST -+ -+/* Name of package */ -+#define PACKAGE "libexif" -+ -+/* Define to the address where bug reports for this package should be sent. */ -+#define PACKAGE_BUGREPORT "libexif-devel@lists.sourceforge.net" -+ -+/* Define to the full name of this package. */ -+#define PACKAGE_NAME "EXIF library" -+ -+/* Define to the full name and version of this package. */ -+#define PACKAGE_STRING "EXIF library 0.6.21" -+ -+/* Define to the one symbol short name of this package. */ -+#define PACKAGE_TARNAME "libexif" -+ -+/* Define to the version of this package. */ -+#define PACKAGE_VERSION "0.6.21" -+ -+/* Define to 1 if you have the ANSI C header files. */ -+#define STDC_HEADERS 1 -+ -+/* Version number of package */ -+#define VERSION "0.6.21" -+ -+/* Define to empty if `const' does not conform to ANSI C. */ -+/* #undef const */ -+#else // defined(__APPLE__) -+ -+// We need different definitions for the iPhone from desktop OS X, -+// we get the necessary #define from TargetConditionals.h -+#include <TargetConditionals.h> -+ -+#if TARGET_OS_IPHONE -+ -+/* config.h. Generated from config.h.in by configure. */ -+/* config.h.in. Generated from configure.ac by autoheader. */ -+ -+/* Define to 1 if translation of program messages to the user's native -+ language is requested. */ -+/* #undef ENABLE_NLS */ -+ -+/* The gettext domain we're using */ -+/* #undef GETTEXT_PACKAGE "libexif-12" */ -+ -+/* Define locale directory. */ -+/* #undef LOCALEDIR "UTF-8" */ -+ -+/* Define to 1 if we want to bind text domain and enable GETTEXT_PACKAGE and -+ * LOCALE_DIR */ -+/* #undef BIND_TEXTDOMAIN 1 */ -+ -+/* Define if the GNU dcgettext() function is already present or preinstalled. -+ */ -+/* #undef HAVE_DCGETTEXT */ -+ -+/* Define to 1 if you have the <dlfcn.h> header file. */ -+#define HAVE_DLFCN_H 1 -+ -+/* Define if the GNU gettext() function is already present or preinstalled. */ -+/* #undef HAVE_GETTEXT */ -+ -+/* Define if you have the iconv() function. */ -+/* #undef HAVE_ICONV */ -+ -+/* Define to 1 if you have the <inttypes.h> header file. */ -+#define HAVE_INTTYPES_H 1 -+ -+/* Define to 1 if you have the <memory.h> header file. */ -+#define HAVE_MEMORY_H 1 -+ -+/* Define to 1 if you have the <stdint.h> header file. */ -+#define HAVE_STDINT_H 1 -+ -+/* Define to 1 if you have the <stdlib.h> header file. */ -+#define HAVE_STDLIB_H 1 -+ -+/* Define to 1 if you have the <strings.h> header file. */ -+#define HAVE_STRINGS_H 1 -+ -+/* Define to 1 if you have the <string.h> header file. */ -+#define HAVE_STRING_H 1 -+ -+/* Define to 1 if you have the <sys/stat.h> header file. */ -+#define HAVE_SYS_STAT_H 1 -+ -+/* Define to 1 if you have the <sys/types.h> header file. */ -+#define HAVE_SYS_TYPES_H 1 -+ -+/* Define to 1 if you have the <unistd.h> header file. */ -+#define HAVE_UNISTD_H 1 -+ -+/* Define as const if the declaration of iconv() needs const. */ -+/* #undef ICONV_CONST */ -+ -+/* Name of package */ -+#define PACKAGE "libexif" -+ -+/* Define to the address where bug reports for this package should be sent. */ -+#define PACKAGE_BUGREPORT "libexif-devel@lists.sourceforge.net" -+ -+/* Define to the full name of this package. */ -+#define PACKAGE_NAME "EXIF library" -+ -+/* Define to the full name and version of this package. */ -+#define PACKAGE_STRING "EXIF library 0.6.21" -+ -+/* Define to the one symbol short name of this package. */ -+#define PACKAGE_TARNAME "libexif" -+ -+/* Define to the version of this package. */ -+#define PACKAGE_VERSION "0.6.21" -+ -+/* Define to 1 if you have the ANSI C header files. */ -+#define STDC_HEADERS 1 -+ -+/* Version number of package */ -+#define VERSION "0.6.21" -+ -+/* Define to empty if `const' does not conform to ANSI C. */ -+/* #undef const */ -+#else // !TARGET_OS_IPHONE -+ -+/* config.h. Generated from config.h.in by configure. */ -+/* config.h.in. Generated from configure.ac by autoheader. */ -+ -+/* Define to 1 if translation of program messages to the user's native -+ language is requested. */ -+/* #undef ENABLE_NLS */ -+ -+/* The gettext domain we're using */ -+/* #undef GETTEXT_PACKAGE "libexif-12" */ -+ -+/* Define locale directory. */ -+/* #undef LOCALEDIR "UTF-8" */ -+ -+/* Define to 1 if we want to bind text domain and enable GETTEXT_PACKAGE and -+ * LOCALE_DIR */ -+/* #undef BIND_TEXTDOMAIN 1 */ -+ -+/* Define if the GNU dcgettext() function is already present or preinstalled. -+ */ -+/* #undef HAVE_DCGETTEXT */ -+ -+/* Define to 1 if you have the <dlfcn.h> header file. */ -+#define HAVE_DLFCN_H 1 -+ -+/* Define if the GNU gettext() function is already present or preinstalled. */ -+/* #undef HAVE_GETTEXT */ -+ -+/* Define if you have the iconv() function. */ -+#define HAVE_ICONV 1 -+ -+/* Define to 1 if you have the <inttypes.h> header file. */ -+#define HAVE_INTTYPES_H 1 -+ -+/* Define to 1 if you have the <memory.h> header file. */ -+#define HAVE_MEMORY_H 1 -+ -+/* Define to 1 if you have the <stdint.h> header file. */ -+#define HAVE_STDINT_H 1 -+ -+/* Define to 1 if you have the <stdlib.h> header file. */ -+#define HAVE_STDLIB_H 1 -+ -+/* Define to 1 if you have the <strings.h> header file. */ -+#define HAVE_STRINGS_H 1 -+ -+/* Define to 1 if you have the <string.h> header file. */ -+#define HAVE_STRING_H 1 -+ -+/* Define to 1 if you have the <sys/stat.h> header file. */ -+#define HAVE_SYS_STAT_H 1 -+ -+/* Define to 1 if you have the <sys/types.h> header file. */ -+#define HAVE_SYS_TYPES_H 1 -+ -+/* Define to 1 if you have the <unistd.h> header file. */ -+#define HAVE_UNISTD_H 1 -+ -+/* Define as const if the declaration of iconv() needs const. */ -+#define ICONV_CONST -+ -+/* Name of package */ -+#define PACKAGE "libexif" -+ -+/* Define to the address where bug reports for this package should be sent. */ -+#define PACKAGE_BUGREPORT "libexif-devel@lists.sourceforge.net" -+ -+/* Define to the full name of this package. */ -+#define PACKAGE_NAME "EXIF library" -+ -+/* Define to the full name and version of this package. */ -+#define PACKAGE_STRING "EXIF library 0.6.21" -+ -+/* Define to the one symbol short name of this package. */ -+#define PACKAGE_TARNAME "libexif" -+ -+/* Define to the version of this package. */ -+#define PACKAGE_VERSION "0.6.21" -+ -+/* Define to 1 if you have the ANSI C header files. */ -+#define STDC_HEADERS 1 -+ -+/* Version number of package */ -+#define VERSION "0.6.21" -+ -+/* Define to empty if `const' does not conform to ANSI C. */ -+/* #undef const */ -+#endif // TARGET_OS_IPHONE -+ -+#endif // _WIN32 -diff -urN libexif-0.6.21/libexif/canon/mnote-canon-tag.c libexif-0.6.21.modified/libexif/canon/mnote-canon-tag.c ---- libexif-0.6.21/libexif/canon/mnote-canon-tag.c 1969-12-31 16:00:00.000000000 -0800 -+++ libexif-0.6.21.modified/libexif/canon/mnote-canon-tag.c 1969-12-31 16:00:00.000000000 -0800 -@@ -160,7 +160,9 @@ - { - unsigned int i; - -+#if defined(BIND_TEXTDOMAIN) - bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR); -+#endif - for (i = 0; i < sizeof (table) / sizeof (table[0]); i++) - if (table[i].tag == t) return (_(table[i].title)); - return NULL; -@@ -194,7 +196,9 @@ - if (table[i].tag == t) { - if (!table[i].description || !*table[i].description) - return ""; -+#if defined(BIND_TEXTDOMAIN) - bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR); -+#endif - return _(table[i].description); - } - return NULL; -diff -urN libexif-0.6.21/libexif/exif-entry.c libexif-0.6.21.modified/libexif/exif-entry.c ---- libexif-0.6.21/libexif/exif-entry.c 1969-12-31 16:00:00.000000000 -0800 -+++ libexif-0.6.21.modified/libexif/exif-entry.c 1969-12-31 16:00:00.000000000 -0800 -@@ -860,7 +860,9 @@ - * - * bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8"); - */ -+#if defined(BIND_TEXTDOMAIN) - bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR); -+#endif - - if (!e || !e->parent || !e->parent->parent || !maxlen) - return val; -diff -urN libexif-0.6.21/libexif/exif-format.c libexif-0.6.21.modified/libexif/exif-format.c ---- libexif-0.6.21/libexif/exif-format.c 1969-12-31 16:00:00.000000000 -0800 -+++ libexif-0.6.21.modified/libexif/exif-format.c 1969-12-31 16:00:00.000000000 -0800 -@@ -61,7 +61,9 @@ - * - * bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8"); - */ -+#if defined(BIND_TEXTDOMAIN) - bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR); -+#endif - - for (i = 0; ExifFormatTable[i].name; i++) - if (ExifFormatTable[i].format == format) -diff -urN libexif-0.6.21/libexif/exif-mem.c libexif-0.6.21.modified/libexif/exif-mem.c ---- libexif-0.6.21/libexif/exif-mem.c 1969-12-31 16:00:00.000000000 -0800 -+++ libexif-0.6.21.modified/libexif/exif-mem.c 1969-12-31 16:00:00.000000000 -0800 -@@ -1,3 +1,23 @@ -+ /* exif-mem.c -+ * -+ * Copyright (c) 2003 Lutz Mueller <lutz@users.sourceforge.net> -+ * -+ * This library is free software; you can redistribute it and/or -+ * modify it under the terms of the GNU Lesser General Public -+ * License as published by the Free Software Foundation; either -+ * version 2 of the License, or (at your option) any later version. -+ * -+ * This library is distributed in the hope that it will be useful, -+ * but WITHOUT ANY WARRANTY; without even the implied warranty of -+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -+ * Lesser General Public License for more details. -+ * -+ * You should have received a copy of the GNU Lesser General Public -+ * License along with this library; if not, write to the -+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ * Boston, MA 02110-1301 USA. -+ */ -+ - #include <libexif/exif-mem.h> - - #include <stdlib.h> -diff -urN libexif-0.6.21/libexif/exif-tag.c libexif-0.6.21.modified/libexif/exif-tag.c ---- libexif-0.6.21/libexif/exif-tag.c 1969-12-31 16:00:00.000000000 -0800 -+++ libexif-0.6.21.modified/libexif/exif-tag.c 1969-12-31 16:00:00.000000000 -0800 -@@ -877,7 +877,7 @@ - * Return the number of entries in the EXIF tag table, including the - * terminating NULL entry. - */ --inline unsigned int -+unsigned int - exif_tag_table_count (void) - { - return sizeof (ExifTagTable) / sizeof (ExifTagTable[0]); -@@ -990,7 +990,9 @@ - * - * bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8"); - */ -+#if defined(BIND_TEXTDOMAIN) - bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR); -+#endif - return _(ExifTagTable[i].title); - } - -@@ -1024,7 +1026,9 @@ - * - * bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8"); - */ -+#if defined(BIND_TEXTDOMAIN) - bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR); -+#endif - return _(ExifTagTable[i].description); - } - -diff -urN libexif-0.6.21/libexif/exif-utils.h libexif-0.6.21.modified/libexif/exif-utils.h ---- libexif-0.6.21/libexif/exif-utils.h 1969-12-31 16:00:00.000000000 -0800 -+++ libexif-0.6.21.modified/libexif/exif-utils.h 1969-12-31 16:00:00.000000000 -0800 -@@ -31,6 +31,7 @@ - #include <libexif/exif-format.h> - #include <libexif/_stdint.h> - -+#include "config.h" - - /* If these definitions don't work for you, please let us fix the - * macro generating _stdint.h */ -diff -urN libexif-0.6.21/libexif/fuji/mnote-fuji-tag.c libexif-0.6.21.modified/libexif/fuji/mnote-fuji-tag.c ---- libexif-0.6.21/libexif/fuji/mnote-fuji-tag.c 1969-12-31 16:00:00.000000000 -0800 -+++ libexif-0.6.21.modified/libexif/fuji/mnote-fuji-tag.c 1969-12-31 16:00:00.000000000 -0800 -@@ -83,7 +83,9 @@ - { - unsigned int i; - -+#if defined(BIND_TEXTDOMAIN) - bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR); -+#endif - for (i = 0; i < sizeof (table) / sizeof (table[0]); i++) - if (table[i].tag == t) return (_(table[i].title)); - return NULL; -@@ -98,7 +100,9 @@ - if (table[i].tag == t) { - if (!table[i].description || !*table[i].description) - return ""; -+#if defined(BIND_TEXTDOMAIN) - bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR); -+#endif - return _(table[i].description); - } - return NULL; -diff -urN libexif-0.6.21/libexif/olympus/mnote-olympus-tag.c libexif-0.6.21.modified/libexif/olympus/mnote-olympus-tag.c ---- libexif-0.6.21/libexif/olympus/mnote-olympus-tag.c 1969-12-31 16:00:00.000000000 -0800 -+++ libexif-0.6.21.modified/libexif/olympus/mnote-olympus-tag.c 1969-12-31 16:00:00.000000000 -0800 -@@ -208,7 +208,9 @@ - { - unsigned int i; - -+#if defined(BIND_TEXTDOMAIN) - bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR); -+#endif - for (i = 0; i < sizeof (table) / sizeof (table[0]); i++) - if (table[i].tag == t) return (_(table[i].title)); - return NULL; -@@ -223,7 +225,9 @@ - if (table[i].tag == t) { - if (!table[i].description || !*table[i].description) - return ""; -+#if defined(BIND_TEXTDOMAIN) - bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR); -+#endif - return _(table[i].description); - } - return NULL; -diff -urN libexif-0.6.21/libexif/pentax/mnote-pentax-tag.c libexif-0.6.21.modified/libexif/pentax/mnote-pentax-tag.c ---- libexif-0.6.21/libexif/pentax/mnote-pentax-tag.c 1969-12-31 16:00:00.000000000 -0800 -+++ libexif-0.6.21.modified/libexif/pentax/mnote-pentax-tag.c 1969-12-31 16:00:00.000000000 -0800 -@@ -153,7 +153,9 @@ - { - unsigned int i; - -+#if defined(BIND_TEXTDOMAIN) - bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR); -+#endif - for (i = 0; i < sizeof (table) / sizeof (table[0]); i++) - if (table[i].tag == t) return (_(table[i].title)); - return NULL; -@@ -168,7 +170,9 @@ - if (table[i].tag == t) { - if (!table[i].description || !*table[i].description) - return ""; -+#if defined(BIND_TEXTDOMAIN) - bindtextdomain (GETTEXT_PACKAGE, LOCALEDIR); -+#endif - return _(table[i].description); - } - return NULL; -diff -urN libexif-0.6.21/libexif/_stdint.h libexif-0.6.21.modified/libexif/_stdint.h ---- libexif-0.6.21/libexif/_stdint.h 1969-12-31 16:00:00.000000000 -0800 -+++ libexif-0.6.21.modified/libexif/_stdint.h 1969-12-31 16:00:00.000000000 -0800 -@@ -1,2 +1,15 @@ - /* This file is generated automatically by configure */ -+#if defined(_WIN32) -+// Define C99 equivalent types. -+typedef signed char int8_t; -+typedef signed short int16_t; -+typedef signed int int32_t; -+typedef signed long long int64_t; -+typedef signed long long ssize_t; -+typedef unsigned char uint8_t; -+typedef unsigned short uint16_t; -+typedef unsigned int uint32_t; -+typedef unsigned long long uint64_t; -+#else - #include <stdint.h> -+#endif diff --git a/third_party/libexif/libexif.def b/third_party/libexif/libexif.def deleted file mode 100644 index e0238a1..0000000 --- a/third_party/libexif/libexif.def +++ /dev/null @@ -1,145 +0,0 @@ -LIBRARY "libexif" -EXPORTS - -exif_array_set_byte_order @1 -exif_byte_order_get_name @2 -exif_content_add_entry @3 -exif_content_dump @4 -exif_content_fix @5 -exif_content_foreach_entry @6 -exif_content_free @7 -exif_content_get_entry @8 -exif_content_get_ifd @9 -exif_content_log @10 -exif_content_new @11 -exif_content_new_mem @12 -exif_content_ref @13 -exif_content_remove_entry @14 -exif_content_unref @15 -exif_convert_utf16_to_utf8 @16 -exif_data_dump @17 -exif_data_fix @18 -exif_data_foreach_content @19 -exif_data_free @20 -exif_data_get_byte_order @21 -exif_data_get_data_type @22 -exif_data_get_log @23 -exif_data_get_mnote_data @24 -exif_data_load_data @25 -exif_data_log @26 -exif_data_new @27 -exif_data_new_from_data @28 -exif_data_new_from_file @29 -exif_data_new_mem @30 -exif_data_option_get_description @31 -exif_data_option_get_name @32 -exif_data_ref @33 -exif_data_save_data @34 -exif_data_set_byte_order @35 -exif_data_set_data_type @36 -exif_data_set_option @37 -exif_data_unref @38 -exif_data_unset_option @39 -exif_entry_dump @40 -exif_entry_fix @41 -exif_entry_free @42 -exif_entry_get_value @43 -exif_entry_initialize @44 -exif_entry_new @45 -exif_entry_new_mem @46 -exif_entry_ref @47 -exif_entry_unref @48 -exif_format_get_name @49 -exif_format_get_size @50 -exif_get_long @51 -exif_get_rational @52 -exif_get_short @53 -exif_get_slong @54 -exif_get_srational @55 -exif_get_sshort @56 -exif_ifd_get_name @57 -exif_loader_get_buf @58 -exif_loader_get_data @59 -exif_loader_log @60 -exif_loader_new @61 -exif_loader_new_mem @62 -exif_loader_ref @63 -exif_loader_reset @64 -exif_loader_unref @65 -exif_loader_write @66 -exif_loader_write_file @67 -exif_log @68 -exif_log_code_get_message @69 -exif_log_code_get_title @70 -exif_log_free @71 -exif_log_new @72 -exif_log_new_mem @73 -exif_log_ref @74 -exif_log_set_func @75 -exif_log_unref @76 -exif_logv @77 -exif_mem_alloc @78 -exif_mem_free @79 -exif_mem_new @80 -exif_mem_new_default @81 -exif_mem_realloc @82 -exif_mem_ref @83 -exif_mem_unref @84 -exif_mnote_data_canon_identify @85 -exif_mnote_data_canon_new @86 -exif_mnote_data_construct @87 -exif_mnote_data_count @88 -exif_mnote_data_fuji_identify @89 -exif_mnote_data_fuji_new @90 -exif_mnote_data_get_description @91 -exif_mnote_data_get_id @92 -exif_mnote_data_get_name @93 -exif_mnote_data_get_title @94 -exif_mnote_data_get_value @95 -exif_mnote_data_load @96 -exif_mnote_data_log @97 -exif_mnote_data_olympus_identify @98 -exif_mnote_data_olympus_new @99 -exif_mnote_data_pentax_identify @100 -exif_mnote_data_pentax_new @101 -exif_mnote_data_ref @102 -exif_mnote_data_save @103 -exif_mnote_data_set_byte_order @104 -exif_mnote_data_set_offset @105 -exif_mnote_data_unref @106 -exif_set_long @107 -exif_set_rational @108 -exif_set_short @109 -exif_set_slong @110 -exif_set_srational @111 -exif_set_sshort @112 -exif_tag_from_name @113 -exif_tag_get_description @114 -exif_tag_get_description_in_ifd @115 -exif_tag_get_name @116 -exif_tag_get_name_in_ifd @117 -exif_tag_get_support_level_in_ifd @118 -exif_tag_get_title @119 -exif_tag_get_title_in_ifd @120 -exif_tag_table_count @121 -exif_tag_table_get_name @122 -exif_tag_table_get_tag @123 -mnote_canon_entry_count_values @124 -mnote_canon_entry_get_value @125 -mnote_canon_tag_get_description @126 -mnote_canon_tag_get_name @127 -mnote_canon_tag_get_name_sub @128 -mnote_canon_tag_get_title @129 -mnote_canon_tag_get_title_sub @130 -mnote_fuji_entry_get_value @131 -mnote_fuji_tag_get_description @132 -mnote_fuji_tag_get_name @133 -mnote_fuji_tag_get_title @134 -mnote_olympus_entry_get_value @135 -mnote_olympus_tag_get_description @136 -mnote_olympus_tag_get_name @137 -mnote_olympus_tag_get_title @138 -mnote_pentax_entry_get_value @139 -mnote_pentax_tag_get_description @140 -mnote_pentax_tag_get_name @141 -mnote_pentax_tag_get_title @142 diff --git a/third_party/libexif/libexif.gyp b/third_party/libexif/libexif.gyp deleted file mode 100644 index 510e6f5..0000000 --- a/third_party/libexif/libexif.gyp +++ /dev/null @@ -1,133 +0,0 @@ -# Copyright (c) 2012 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. - -{ - 'variables': { - 'conditions': [ - ['OS == "linux" and chromeos==0', { - 'use_system_libexif%': 1, - }, { # OS != "linux" and chromeos==0 - 'use_system_libexif%': 0, - }], - ], - }, - 'conditions': [ - ['use_system_libexif==0', { - 'targets': [ - { - 'target_name': 'libexif', - 'type': 'loadable_module', - 'sources': [ - 'sources/libexif/exif-byte-order.c', - 'sources/libexif/exif-content.c', - 'sources/libexif/exif-data.c', - 'sources/libexif/exif-entry.c', - 'sources/libexif/exif-format.c', - 'sources/libexif/exif-ifd.c', - 'sources/libexif/exif-loader.c', - 'sources/libexif/exif-log.c', - 'sources/libexif/exif-mem.c', - 'sources/libexif/exif-mnote-data.c', - 'sources/libexif/exif-tag.c', - 'sources/libexif/exif-utils.c', - 'sources/libexif/canon/exif-mnote-data-canon.c', - 'sources/libexif/canon/mnote-canon-entry.c', - 'sources/libexif/canon/mnote-canon-tag.c', - 'sources/libexif/fuji/exif-mnote-data-fuji.c', - 'sources/libexif/fuji/mnote-fuji-entry.c', - 'sources/libexif/fuji/mnote-fuji-tag.c', - 'sources/libexif/olympus/exif-mnote-data-olympus.c', - 'sources/libexif/olympus/mnote-olympus-entry.c', - 'sources/libexif/olympus/mnote-olympus-tag.c', - 'sources/libexif/pentax/exif-mnote-data-pentax.c', - 'sources/libexif/pentax/mnote-pentax-entry.c', - 'sources/libexif/pentax/mnote-pentax-tag.c', - ], - 'include_dirs': [ - 'sources', - ], - 'direct_dependent_settings': { - 'include_dirs': [ - 'sources', - ], - }, - 'variables': { - 'clang_warning_flags': [ - '-Wno-enum-conversion', - '-Wno-switch', - '-Wno-format', - # libexif uses fabs(int) to cast to float. - '-Wno-absolute-value', - ], - }, - 'conditions': [ - ['os_posix==1 and OS!="mac"', { - 'cflags!': ['-fvisibility=hidden'], - 'libraries': ['-lm'], - }], - ['OS=="mac"', { - 'conditions': [ - ['mac_breakpad==1', { - 'variables': { - 'mac_real_dsym': 1, - }, - }], - ], - 'xcode_settings': { - 'GCC_SYMBOLS_PRIVATE_EXTERN': 'NO', # no -fvisibility=hidden - }, - }], - ['OS=="win"', { - 'product_name': 'libexif', - 'sources': [ - 'libexif.def', - ], - 'conditions': [ - ['MSVS_VERSION < "2015"', { - 'defines': [ - # This seems like a hack, but this is what Safari Win does. - # Luckily it is no longer needed/allowed with VS 2015. - 'snprintf=_snprintf', - ], - }], - ], - 'defines': [ - 'inline=__inline', - ], - 'msvs_disabled_warnings': [ - 4018, # size/unsigned mismatch - 4267, # size_t -> ExifLong truncation on amd64 - ], - # As of VS 2013 Update 3, building this project with /analyze hits - # an internal compiler error on exif-entry.c. This halts the build - # and prevents subsequent analysis. Therefore, /analyze is - # disabled for this project. See this bug for details: - # https://connect.microsoft.com/VisualStudio/feedback/details/1014689/internal-compiler-error - 'msvs_settings': { - 'VCCLCompilerTool': { - 'AdditionalOptions!': [ '/analyze:WX-' ] - }, - }, - }], - ], - }, - ], - }, { # 'use_system_libexif!=0 - 'targets': [ - { - 'target_name': 'libexif', - 'type': 'none', - 'direct_dependent_settings': { - 'cflags': [ - '<!@(<(pkg-config) --cflags libexif)', - ], - 'defines': [ - 'USE_SYSTEM_LIBEXIF', - ], - }, - } - ], - }], - ] -} |