diff options
author | piernov <piernov@piernov.org> | 2011-10-24 12:09:46 +0200 |
---|---|---|
committer | piernov <piernov@piernov.org> | 2011-10-24 12:09:46 +0200 |
commit | bc36a6898157fe2b404cec7afff5be00969dd126 (patch) | |
tree | f4f95789fd0d533bbb35bdd29d6be7bac2936191 | |
parent | 9cba53e3814f0acf16bbe456423994637c771309 (diff) | |
download | gnome3-bc36a6898157fe2b404cec7afff5be00969dd126.tar.gz gnome3-bc36a6898157fe2b404cec7afff5be00969dd126.tar.bz2 gnome3-bc36a6898157fe2b404cec7afff5be00969dd126.tar.xz gnome3-bc36a6898157fe2b404cec7afff5be00969dd126.zip |
taglib-sharp 2.0.4.0-1 ajout port
-rw-r--r-- | taglib-sharp/.footprint.i686 | 17 | ||||
-rw-r--r-- | taglib-sharp/.footprint.x86_64 | 17 | ||||
-rw-r--r-- | taglib-sharp/.md5sum.i686 | 3 | ||||
-rw-r--r-- | taglib-sharp/.md5sum.x86_64 | 3 | ||||
-rw-r--r-- | taglib-sharp/Pkgfile | 22 | ||||
-rw-r--r-- | taglib-sharp/extractKey.cpp | 41 | ||||
-rw-r--r-- | taglib-sharp/listData.cpp | 62 |
7 files changed, 165 insertions, 0 deletions
diff --git a/taglib-sharp/.footprint.i686 b/taglib-sharp/.footprint.i686 new file mode 100644 index 0000000..1b3c3ab --- /dev/null +++ b/taglib-sharp/.footprint.i686 @@ -0,0 +1,17 @@ +drwxr-xr-x root/root usr/ +drwxr-xr-x root/root usr/lib/ +drwxr-xr-x root/root usr/lib/mono/ +drwxr-xr-x root/root usr/lib/mono/gac/ +drwxr-xr-x root/root usr/lib/mono/gac/policy.2.0.taglib-sharp/ +drwxr-xr-x root/root usr/lib/mono/gac/policy.2.0.taglib-sharp/0.0.0.0__db62eba44689b5b0/ +-rw-r--r-- root/root usr/lib/mono/gac/policy.2.0.taglib-sharp/0.0.0.0__db62eba44689b5b0/policy.2.0.taglib-sharp.config +-rwxr-xr-x root/root usr/lib/mono/gac/policy.2.0.taglib-sharp/0.0.0.0__db62eba44689b5b0/policy.2.0.taglib-sharp.dll +drwxr-xr-x root/root usr/lib/mono/gac/taglib-sharp/ +drwxr-xr-x root/root usr/lib/mono/gac/taglib-sharp/2.0.4.0__db62eba44689b5b0/ +-rwxr-xr-x root/root usr/lib/mono/gac/taglib-sharp/2.0.4.0__db62eba44689b5b0/taglib-sharp.dll +-rw-r--r-- root/root usr/lib/mono/gac/taglib-sharp/2.0.4.0__db62eba44689b5b0/taglib-sharp.dll.mdb +drwxr-xr-x root/root usr/lib/mono/taglib-sharp/ +lrwxrwxrwx root/root usr/lib/mono/taglib-sharp/taglib-sharp.dll -> ../gac/taglib-sharp/2.0.4.0__db62eba44689b5b0/taglib-sharp.dll +drwxr-xr-x root/root usr/share/ +drwxr-xr-x root/root usr/share/pkgconfig/ +-rw-r--r-- root/root usr/share/pkgconfig/taglib-sharp.pc diff --git a/taglib-sharp/.footprint.x86_64 b/taglib-sharp/.footprint.x86_64 new file mode 100644 index 0000000..1b3c3ab --- /dev/null +++ b/taglib-sharp/.footprint.x86_64 @@ -0,0 +1,17 @@ +drwxr-xr-x root/root usr/ +drwxr-xr-x root/root usr/lib/ +drwxr-xr-x root/root usr/lib/mono/ +drwxr-xr-x root/root usr/lib/mono/gac/ +drwxr-xr-x root/root usr/lib/mono/gac/policy.2.0.taglib-sharp/ +drwxr-xr-x root/root usr/lib/mono/gac/policy.2.0.taglib-sharp/0.0.0.0__db62eba44689b5b0/ +-rw-r--r-- root/root usr/lib/mono/gac/policy.2.0.taglib-sharp/0.0.0.0__db62eba44689b5b0/policy.2.0.taglib-sharp.config +-rwxr-xr-x root/root usr/lib/mono/gac/policy.2.0.taglib-sharp/0.0.0.0__db62eba44689b5b0/policy.2.0.taglib-sharp.dll +drwxr-xr-x root/root usr/lib/mono/gac/taglib-sharp/ +drwxr-xr-x root/root usr/lib/mono/gac/taglib-sharp/2.0.4.0__db62eba44689b5b0/ +-rwxr-xr-x root/root usr/lib/mono/gac/taglib-sharp/2.0.4.0__db62eba44689b5b0/taglib-sharp.dll +-rw-r--r-- root/root usr/lib/mono/gac/taglib-sharp/2.0.4.0__db62eba44689b5b0/taglib-sharp.dll.mdb +drwxr-xr-x root/root usr/lib/mono/taglib-sharp/ +lrwxrwxrwx root/root usr/lib/mono/taglib-sharp/taglib-sharp.dll -> ../gac/taglib-sharp/2.0.4.0__db62eba44689b5b0/taglib-sharp.dll +drwxr-xr-x root/root usr/share/ +drwxr-xr-x root/root usr/share/pkgconfig/ +-rw-r--r-- root/root usr/share/pkgconfig/taglib-sharp.pc diff --git a/taglib-sharp/.md5sum.i686 b/taglib-sharp/.md5sum.i686 new file mode 100644 index 0000000..2535f5c --- /dev/null +++ b/taglib-sharp/.md5sum.i686 @@ -0,0 +1,3 @@ +96ab7b5e8d9b257c6766c817ab567e5d extractKey.cpp +d0a9d79fcfc4715ad6f8d33efbb003e1 listData.cpp +c7e3b2d064e0429d168fa7498c47970e taglib-sharp-2.0.4.0.tar.bz2 diff --git a/taglib-sharp/.md5sum.x86_64 b/taglib-sharp/.md5sum.x86_64 new file mode 100644 index 0000000..2535f5c --- /dev/null +++ b/taglib-sharp/.md5sum.x86_64 @@ -0,0 +1,3 @@ +96ab7b5e8d9b257c6766c817ab567e5d extractKey.cpp +d0a9d79fcfc4715ad6f8d33efbb003e1 listData.cpp +c7e3b2d064e0429d168fa7498c47970e taglib-sharp-2.0.4.0.tar.bz2 diff --git a/taglib-sharp/Pkgfile b/taglib-sharp/Pkgfile new file mode 100644 index 0000000..e61fec7 --- /dev/null +++ b/taglib-sharp/Pkgfile @@ -0,0 +1,22 @@ +# Description: Bibliothèque de gestion de métadonnées pour les formats audio et vidéo communs +# URL: http://download.banshee.fm/taglib-sharp +# Maintainer: NuTyX Core team +# Packager: piernov <piernov@piernov.org> +# Depends on: mono, exiv2 +# Run on: mono,exiv2 + +name=taglib-sharp +version=2.0.4.0 +release=1 +source=(http://download.banshee.fm/$name/$version/$name-$version.tar.bz2 + extractKey.cpp + listData.cpp) + +build() { + cd $name-$version + cp ../extractKey.cpp ../listData.cpp examples/ + ./configure --prefix=/usr + make + make DESTDIR=$PKG install + rm -rf $PKG/tmp/ +} diff --git a/taglib-sharp/extractKey.cpp b/taglib-sharp/extractKey.cpp new file mode 100644 index 0000000..859ea73 --- /dev/null +++ b/taglib-sharp/extractKey.cpp @@ -0,0 +1,41 @@ +#include <exiv2/image.hpp> +#include <exiv2/exif.hpp> +#include <iostream> +#include <iomanip> +#include <cassert> + +int main(int argc, char* const argv[]) + +try { + if (argc != 3) { + std::cout << "Usage: " << argv[0] << " file key\n"; + return 1; + } + + Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(argv[1]); + assert(image.get() != 0); + image->readMetadata(); + + try { + Exiv2::ExifData &exifData = image->exifData(); + const Exiv2::Value &value = exifData[argv[2]].value(); + std::cout << value; + } catch (Exiv2::AnyError &e) {} + + try { + Exiv2::IptcData &iptcData = image->iptcData(); + const Exiv2::Value &value = iptcData[argv[2]].value(); + std::cout << value; + } catch (Exiv2::AnyError &e) {} + + try { + Exiv2::XmpData &xmpData = image->xmpData(); + const Exiv2::Value &value = xmpData[argv[2]].value(); + std::cout << value; + } catch (Exiv2::AnyError &e) {} + + return 0; +} catch (Exiv2::AnyError& e) { + std::cout << "Caught Exiv2 exception '" << e << "'\n"; + return -1; +} diff --git a/taglib-sharp/listData.cpp b/taglib-sharp/listData.cpp new file mode 100644 index 0000000..50283d2 --- /dev/null +++ b/taglib-sharp/listData.cpp @@ -0,0 +1,62 @@ +#include <exiv2/image.hpp> +#include <exiv2/exif.hpp> +#include <iostream> +#include <iomanip> +#include <cassert> + +int main(int argc, char* const argv[]) + +try { + if (argc != 3) { + std::cout << "Usage: " << argv[0] << " mode file\n"; + return 1; + } + + Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(argv[2]); + assert(image.get() != 0); + image->readMetadata(); + + if (argv[1][0] == 'e') { + Exiv2::ExifData &exifData = image->exifData(); + if (!exifData.empty()) { + Exiv2::ExifData::const_iterator exifEnd = exifData.end(); + for (Exiv2::ExifData::const_iterator i = exifData.begin(); i != exifEnd; ++i) { + std::cout << i->tagName() << "\t" + << "0x" << std::setw(4) << std::setfill('0') << std::right + << std::hex << i->tag() << std::dec << "\t" + << i->groupName() << "\t" + << i->typeName() << "\t" + << i->count() << "\t" + << "\n"; + } + } + } + + if (argv[1][0] == 'i') { + Exiv2::IptcData &iptcData = image->iptcData(); + if (!iptcData.empty()) { + Exiv2::IptcData::const_iterator iptcEnd = iptcData.end(); + for (Exiv2::IptcData::const_iterator i = iptcData.begin(); i != iptcEnd; ++i) { + std::cout << i->key() << "\n"; + } + } + } + + if (argv[1][0] == 'x') { + Exiv2::XmpData &xmpData = image->xmpData(); + if (!xmpData.empty()) { + Exiv2::XmpData::const_iterator xmpEnd = xmpData.end(); + for (Exiv2::XmpData::const_iterator i = xmpData.begin(); i != xmpEnd; ++i) { + std::cout << i->key() << "\t" + << i->typeName() << "\t" + << i->count() << "\t" + << "\n"; + } + } + } + + return 0; +} catch (Exiv2::AnyError& e) { + std::cout << "Caught Exiv2 exception '" << e << "'\n"; + return -1; +} |