diff options
78 files changed, 6236 insertions, 96 deletions
diff --git a/community-testing/balsa/PKGBUILD b/community-testing/balsa/PKGBUILD new file mode 100644 index 000000000..43eae5357 --- /dev/null +++ b/community-testing/balsa/PKGBUILD @@ -0,0 +1,47 @@ +# $Id: PKGBUILD 62015 2012-01-14 12:24:56Z ibiru $ +# Maintainer : Ionut Biru <ibiru@archlinux.org> +# Maintainer: Brad Fanella <bradfanella@archlinux.us> +# Contributor: Roman Kyrylych <roman@archlinux.org> + +pkgname=balsa +pkgver=2.4.11 +pkgrel=1 +pkgdesc="An e-mail client for GNOME" +arch=('i686' 'x86_64') +license=('GPL') +url='http://pawsa.fedorapeople.org/balsa/' +depends=('gmime' 'libwebkit' 'libesmtp' 'libnotify' 'gpgme' 'gtksourceview2' 'gtkspell' 'gnome-icon-theme' 'desktop-file-utils') +makedepends=('perlxml' 'gnome-doc-utils' 'intltool') +install=balsa.install +source=(http://pawsa.fedorapeople.org/${pkgname}/${pkgname}-${pkgver}.tar.bz2 + gmime26.patch) +md5sums=('915c622b6385aa4f83d5eee8f31ee8e8' + '108d33f533558a371189441edce7d7e6') + +build() { + cd "${srcdir}/${pkgname}-${pkgver}" + + patch -Np1 -i "${srcdir}/gmime26.patch" + autoreconf -fi + + ./configure --prefix=/usr \ + --sysconfdir=/etc \ + --localstatedir=/var \ + --with-ssl \ + --with-gpgme=gpgme-config \ + --with-gss \ + --with-ldap \ + --with-gtksourceview \ + --with-gtkspell \ + --with-rubrica \ + --with-sqlite \ + --without-nm \ + --without-gnome \ + --with-html-widget=webkit + make +} + +package() { + cd "${srcdir}/${pkgname}-${pkgver}" + make GTK_UPDATE_ICON_CACHE=/bin/true DESTDIR="${pkgdir}" install +} diff --git a/community-testing/balsa/balsa.install b/community-testing/balsa/balsa.install new file mode 100644 index 000000000..1f167b5e9 --- /dev/null +++ b/community-testing/balsa/balsa.install @@ -0,0 +1,12 @@ +post_install() { + gtk-update-icon-cache -q -t -f /usr/share/icons/hicolor + update-desktop-database -q +} + +post_upgrade() { + post_install $1 +} + +post_remove() { + post_install $1 +} diff --git a/community-testing/balsa/gmime26.patch b/community-testing/balsa/gmime26.patch new file mode 100644 index 000000000..fe4e6a9fa --- /dev/null +++ b/community-testing/balsa/gmime26.patch @@ -0,0 +1,1372 @@ +From 393d0077495cb750ee47bab6ec44a60906a95179 Mon Sep 17 00:00:00 2001 +From: Peter Bloomfield <PeterBloomfield@bellsouth.net> +Date: Mon, 28 Nov 2011 03:00:55 +0000 +Subject: Build with GMime 2.6.0 + + * configure.in: check for GMime >= 2.5.7 + * libbalsa/gmime-application-pkcs7.c + (g_mime_application_pkcs7_sign), (g_mime_application_pkcs7_verify), + (g_mime_application_pkcs7_encrypt), + (g_mime_application_pkcs7_decrypt): build with GMime >= 2.5.7. + * libbalsa/gmime-application-pkcs7.h: ditto. + * libbalsa/gmime-gpgme-context.c (g_mime_gpgme_context_get_type), + (g_mime_gpgme_context_class_init), (g_mime_gpgme_context_finalize), + (g_mime_gpgme_digest_id): ditto. + * libbalsa/gmime-gpgme-context.h: ditto. + * libbalsa/gmime-part-rfc2440.c (g_mime_part_rfc2440_sign_encrypt), + (g_mime_part_rfc2440_verify), (g_mime_part_rfc2440_decrypt): + ditto. + * libbalsa/gmime-part-rfc2440.h: ditto. + * libbalsa/rfc3156.c (password_request_func), + (libbalsa_sign_mime_object), (libbalsa_encrypt_mime_object), + (libbalsa_body_check_signature), (libbalsa_body_decrypt): ditto. +--- +diff --git a/ChangeLog b/ChangeLog +index bd95e68..d5c62f5 100644 +--- a/ChangeLog ++++ b/ChangeLog +@@ -1,3 +1,25 @@ ++2011-11-27 Peter Bloomfield ++ ++ Build with GMime 2.6.0 ++ ++ * configure.in: check for GMime >= 2.5.7 ++ * libbalsa/gmime-application-pkcs7.c ++ (g_mime_application_pkcs7_sign), (g_mime_application_pkcs7_verify), ++ (g_mime_application_pkcs7_encrypt), ++ (g_mime_application_pkcs7_decrypt): build with GMime >= 2.5.7. ++ * libbalsa/gmime-application-pkcs7.h: ditto. ++ * libbalsa/gmime-gpgme-context.c (g_mime_gpgme_context_get_type), ++ (g_mime_gpgme_context_class_init), (g_mime_gpgme_context_finalize), ++ (g_mime_gpgme_digest_id): ditto. ++ * libbalsa/gmime-gpgme-context.h: ditto. ++ * libbalsa/gmime-part-rfc2440.c (g_mime_part_rfc2440_sign_encrypt), ++ (g_mime_part_rfc2440_verify), (g_mime_part_rfc2440_decrypt): ++ ditto. ++ * libbalsa/gmime-part-rfc2440.h: ditto. ++ * libbalsa/rfc3156.c (password_request_func), ++ (libbalsa_sign_mime_object), (libbalsa_encrypt_mime_object), ++ (libbalsa_body_check_signature), (libbalsa_body_decrypt): ditto. ++ + 2011-11-22 Pawel Salek + + * NEWS, configure.in: release balsa-2.4.11 +diff --git a/configure.in b/configure.in +index 4a8320e..64d99f3 100644 +--- a/configure.in ++++ b/configure.in +@@ -307,7 +307,12 @@ fi + case "$with_gmime" in + 2.4) ;; + 2.6) AC_DEFINE([HAVE_GMIME_2_6], [1], +- [Defined to build with GMime version 2.5 or 2.6]) ;; ++ [Defined to build with GMime version 2.5 or 2.6]) ++ if $PKG_CONFIG --atleast-version=2.5.7 gmime-2.6; then ++ AC_DEFINE([HAVE_GMIME_2_5_7], [1], ++ [Defined when GMime version is at least 2.5.7]) ++ fi ++ ;; + *) AC_MSG_ERROR([unknown GMime version $with_gmime]) ;; + esac + +diff --git a/libbalsa/gmime-application-pkcs7.c b/libbalsa/gmime-application-pkcs7.c +index 12f4f8f..63b8087 100644 +--- a/libbalsa/gmime-application-pkcs7.c ++++ b/libbalsa/gmime-application-pkcs7.c +@@ -96,8 +96,14 @@ g_mime_application_pkcs7_sign (GMimePart *pkcs7, GMimeObject *content, + GMimeFilter *crlf_filter, *from_filter; + + g_return_val_if_fail (GMIME_IS_PART (pkcs7), -1); ++#ifndef HAVE_GMIME_2_5_7 + g_return_val_if_fail (GMIME_IS_CIPHER_CONTEXT (ctx), -1); + g_return_val_if_fail (ctx->sign_protocol != NULL, -1); ++#else /* HAVE_GMIME_2_5_7 */ ++ g_return_val_if_fail (GMIME_IS_CRYPTO_CONTEXT (ctx), -1); ++ g_return_val_if_fail(g_mime_crypto_context_get_signature_protocol(ctx) ++ != NULL, -1); ++#endif /* HAVE_GMIME_2_5_7 */ + g_return_val_if_fail (GMIME_IS_OBJECT (content), -1); + + /* Prepare all the parts for signing... */ +@@ -127,7 +133,14 @@ g_mime_application_pkcs7_sign (GMimePart *pkcs7, GMimeObject *content, + sig_data_stream = g_mime_stream_mem_new (); + + /* get the signed content */ +- if (g_mime_cipher_context_sign (ctx, userid, GMIME_CIPHER_HASH_DEFAULT, filtered_stream, sig_data_stream, err) == -1) { ++#ifndef HAVE_GMIME_2_5_7 ++ if (g_mime_cipher_context_sign (ctx, userid, GMIME_CIPHER_HASH_DEFAULT, filtered_stream, sig_data_stream, err) == -1) ++#else /* HAVE_GMIME_2_5_7 */ ++ if (g_mime_crypto_context_sign ++ (ctx, userid, GMIME_CIPHER_HASH_DEFAULT, filtered_stream, ++ sig_data_stream, err) == -1) ++#endif /* HAVE_GMIME_2_5_7 */ ++ { + g_object_unref (filtered_stream); + g_object_unref (sig_data_stream); + g_object_unref (stream); +@@ -168,9 +181,15 @@ g_mime_application_pkcs7_sign (GMimePart *pkcs7, GMimeObject *content, + * decrypting it again. In this case, validity is undefined. + */ + GMimeObject * ++#ifndef HAVE_GMIME_2_5_7 + g_mime_application_pkcs7_verify(GMimePart * pkcs7, + GMimeSignatureValidity ** validity, + GMimeCipherContext * ctx, GError ** err) ++#else /* HAVE_GMIME_2_5_7 */ ++g_mime_application_pkcs7_verify(GMimePart * pkcs7, ++ GMimeSignatureList ** list, ++ GMimeCryptoContext * ctx, GError ** err) ++#endif /* HAVE_GMIME_2_5_7 */ + { + GMimeObject *decrypted; + GMimeDataWrapper *wrapper; +@@ -181,8 +200,14 @@ g_mime_application_pkcs7_verify(GMimePart * pkcs7, + const char *smime_type; + + g_return_val_if_fail(GMIME_IS_PART(pkcs7), NULL); ++#ifndef HAVE_GMIME_2_5_7 + g_return_val_if_fail(GMIME_IS_CIPHER_CONTEXT(ctx), NULL); + g_return_val_if_fail(ctx->encrypt_protocol != NULL, NULL); ++#else /* HAVE_GMIME_2_5_7 */ ++ g_return_val_if_fail(GMIME_IS_CRYPTO_CONTEXT(ctx), NULL); ++ g_return_val_if_fail(g_mime_crypto_context_get_encryption_protocol(ctx) ++ != NULL, NULL); ++#endif /* HAVE_GMIME_2_5_7 */ + + /* some sanity checks */ + smime_type = +@@ -208,9 +233,16 @@ g_mime_application_pkcs7_verify(GMimePart * pkcs7, + g_object_unref(crlf_filter); + + /* get the cleartext */ ++#ifndef HAVE_GMIME_2_5_7 + *validity = g_mime_cipher_context_verify(ctx, GMIME_CIPHER_HASH_DEFAULT, + ciphertext, filtered_stream, err); +- if (!*validity) { ++ if (!*validity) ++#else /* HAVE_GMIME_2_5_7 */ ++ *list = g_mime_crypto_context_verify(ctx, GMIME_CIPHER_ALGO_DEFAULT, ++ ciphertext, filtered_stream, err); ++ if (!*list) ++#endif /* HAVE_GMIME_2_5_7 */ ++ { + g_object_unref(filtered_stream); + g_object_unref(ciphertext); + g_object_unref(stream); +@@ -248,7 +280,12 @@ g_mime_application_pkcs7_verify(GMimePart * pkcs7, + */ + int + g_mime_application_pkcs7_encrypt (GMimePart *pkcs7, GMimeObject *content, ++#ifndef HAVE_GMIME_2_5_7 + GMimeCipherContext *ctx, GPtrArray *recipients, ++#else /* HAVE_GMIME_2_5_7 */ ++ GMimeCryptoContext *ctx, ++ GPtrArray *recipients, ++#endif /* HAVE_GMIME_2_5_7 */ + GError **err) + { + GMimeDataWrapper *wrapper; +@@ -257,8 +294,14 @@ g_mime_application_pkcs7_encrypt (GMimePart *pkcs7, GMimeObject *content, + GMimeFilter *crlf_filter; + + g_return_val_if_fail (GMIME_IS_PART (pkcs7), -1); ++#ifndef HAVE_GMIME_2_5_7 + g_return_val_if_fail (GMIME_IS_CIPHER_CONTEXT (ctx), -1); + g_return_val_if_fail (ctx->encrypt_protocol != NULL, -1); ++#else /* HAVE_GMIME_2_5_7 */ ++ g_return_val_if_fail (GMIME_IS_CRYPTO_CONTEXT (ctx), -1); ++ g_return_val_if_fail(g_mime_crypto_context_get_encryption_protocol(ctx) ++ != NULL, -1); ++#endif /* HAVE_GMIME_2_5_7 */ + g_return_val_if_fail (GMIME_IS_OBJECT (content), -1); + + /* get the cleartext */ +@@ -279,7 +322,15 @@ g_mime_application_pkcs7_encrypt (GMimePart *pkcs7, GMimeObject *content, + + /* encrypt the content stream */ + ciphertext = g_mime_stream_mem_new (); +- if (g_mime_cipher_context_encrypt (ctx, FALSE, NULL, recipients, stream, ciphertext, err) == -1) { ++#ifndef HAVE_GMIME_2_5_7 ++ if (g_mime_cipher_context_encrypt (ctx, FALSE, NULL, recipients, stream, ciphertext, err) == -1) ++#else /* HAVE_GMIME_2_5_7 */ ++ if (g_mime_crypto_context_encrypt ++ (ctx, FALSE, NULL, ++ GMIME_CIPHER_ALGO_DEFAULT, ++ recipients, stream, ciphertext, err) == -1) ++#endif /* HAVE_GMIME_2_5_7 */ ++ { + g_object_unref (ciphertext); + g_object_unref (stream); + return -1; +@@ -313,8 +364,14 @@ g_mime_application_pkcs7_encrypt (GMimePart *pkcs7, GMimeObject *content, + * err with more information about the reason. + */ + GMimeObject * ++#ifndef HAVE_GMIME_2_5_7 + g_mime_application_pkcs7_decrypt (GMimePart *pkcs7, GMimeCipherContext *ctx, + GError **err) ++#else /* HAVE_GMIME_2_5_7 */ ++g_mime_application_pkcs7_decrypt (GMimePart *pkcs7, ++ GMimeCryptoContext *ctx, ++ GError **err) ++#endif /* HAVE_GMIME_2_5_7 */ + { + GMimeObject *decrypted; + GMimeDataWrapper *wrapper; +@@ -325,8 +382,14 @@ g_mime_application_pkcs7_decrypt (GMimePart *pkcs7, GMimeCipherContext *ctx, + const char *smime_type; + + g_return_val_if_fail(GMIME_IS_PART(pkcs7), NULL); ++#ifndef HAVE_GMIME_2_5_7 + g_return_val_if_fail(GMIME_IS_CIPHER_CONTEXT(ctx), NULL); + g_return_val_if_fail(ctx->encrypt_protocol != NULL, NULL); ++#else /* HAVE_GMIME_2_5_7 */ ++ g_return_val_if_fail(GMIME_IS_CRYPTO_CONTEXT(ctx), NULL); ++ g_return_val_if_fail(g_mime_crypto_context_get_encryption_protocol(ctx) ++ != NULL, NULL); ++#endif /* HAVE_GMIME_2_5_7 */ + + /* some sanity checks */ + smime_type = +@@ -353,7 +416,13 @@ g_mime_application_pkcs7_decrypt (GMimePart *pkcs7, GMimeCipherContext *ctx, + g_object_unref(crlf_filter); + + /* get the cleartext */ +- if (g_mime_cipher_context_decrypt(ctx, ciphertext, filtered_stream, err) == NULL) { ++#ifndef HAVE_GMIME_2_5_7 ++ if (g_mime_cipher_context_decrypt(ctx, ciphertext, filtered_stream, err) == NULL) ++#else /* HAVE_GMIME_2_5_7 */ ++ if (g_mime_crypto_context_decrypt ++ (ctx, ciphertext, filtered_stream, err) == NULL) ++#endif /* HAVE_GMIME_2_5_7 */ ++ { + g_object_unref(filtered_stream); + g_object_unref(ciphertext); + g_object_unref(stream); +diff --git a/libbalsa/gmime-application-pkcs7.h b/libbalsa/gmime-application-pkcs7.h +index 03fa401..6678ff5 100644 +--- a/libbalsa/gmime-application-pkcs7.h ++++ b/libbalsa/gmime-application-pkcs7.h +@@ -28,7 +28,11 @@ extern "C" { + #endif /* __cplusplus */ + + #include <gmime/gmime-part.h> ++#ifndef HAVE_GMIME_2_5_7 + #include <gmime/gmime-cipher-context.h> ++#else /* HAVE_GMIME_2_5_7 */ ++#include <gmime/gmime-crypto-context.h> ++#endif /* HAVE_GMIME_2_5_7 */ + + #undef HAS_APPLICATION_PKCS7_MIME_SIGNED_SUPPORT + +@@ -39,21 +43,40 @@ extern "C" { + * Balsa always encodes S/MIME signed stuff as multipart/signed. */ + int g_mime_application_pkcs7_sign(GMimePart * pkcs7, + GMimeObject * content, ++#ifndef HAVE_GMIME_2_5_7 + GMimeCipherContext * ctx, ++#else /* HAVE_GMIME_2_5_7 */ ++ GMimeCryptoContext * ctx, ++#endif /* HAVE_GMIME_2_5_7 */ + const char *userid, GError ** err); + #endif + ++#ifndef HAVE_GMIME_2_5_7 + GMimeObject *g_mime_application_pkcs7_verify(GMimePart * pkcs7, + GMimeSignatureValidity ** validity, + GMimeCipherContext * ctx, GError ** err); ++#else /* HAVE_GMIME_2_5_7 */ ++GMimeObject *g_mime_application_pkcs7_verify(GMimePart * pkcs7, ++ GMimeSignatureList ** validity, ++ GMimeCryptoContext * ctx, GError ** err); ++#endif /* HAVE_GMIME_2_5_7 */ + + int g_mime_application_pkcs7_encrypt(GMimePart * pkcs7, + GMimeObject * content, ++#ifndef HAVE_GMIME_2_5_7 + GMimeCipherContext * ctx, ++#else /* HAVE_GMIME_2_5_7 */ ++ GMimeCryptoContext * ctx, ++#endif /* HAVE_GMIME_2_5_7 */ + GPtrArray * recipients, GError ** err); + ++#ifndef HAVE_GMIME_2_5_7 + GMimeObject *g_mime_application_pkcs7_decrypt(GMimePart * pkcs7, + GMimeCipherContext * ctx, GError ** err); ++#else /* HAVE_GMIME_2_5_7 */ ++GMimeObject *g_mime_application_pkcs7_decrypt(GMimePart * pkcs7, ++ GMimeCryptoContext * ctx, GError ** err); ++#endif /* HAVE_GMIME_2_5_7 */ + + #ifdef __cplusplus + } +diff --git a/libbalsa/gmime-gpgme-context.c b/libbalsa/gmime-gpgme-context.c +index 24b140b..0c56f94 100644 +--- a/libbalsa/gmime-gpgme-context.c ++++ b/libbalsa/gmime-gpgme-context.c +@@ -27,6 +27,9 @@ + #include <unistd.h> + #include <glib.h> + #include <gmime/gmime.h> ++#ifdef HAVE_GMIME_2_5_7 ++#include <gmime/gmime-certificate.h> ++#endif /* HAVE_GMIME_2_5_7 */ + #include <gpgme.h> + #include <time.h> + #include <glib/gi18n.h> +@@ -44,6 +47,7 @@ static gboolean g_mime_gpgme_context_check_protocol(GMimeGpgmeContextClass + protocol, + GError ** error); + ++#ifndef HAVE_GMIME_2_5_7 + static GMimeCipherHash g_mime_gpgme_hash_id(GMimeCipherContext * ctx, + const char *hash); + +@@ -70,6 +74,46 @@ static GMimeSignatureValidity *g_mime_gpgme_decrypt(GMimeCipherContext * + GMimeStream * istream, + GMimeStream * ostream, + GError ** err); ++#else /* HAVE_GMIME_2_5_7 */ ++static GMimeDigestAlgo g_mime_gpgme_digest_id(GMimeCryptoContext * ctx, ++ const char *hash); ++ ++static const char *g_mime_gpgme_digest_name(GMimeCryptoContext * ctx, ++ GMimeDigestAlgo hash); ++ ++static const char ++ *g_mime_gpgme_get_signature_protocol(GMimeCryptoContext * context); ++static const char ++ *g_mime_gpgme_get_encryption_protocol(GMimeCryptoContext * context); ++static const char ++ *g_mime_gpgme_get_key_exchange_protocol(GMimeCryptoContext * context); ++ ++static int g_mime_gpgme_sign(GMimeCryptoContext * ctx, ++ const char * userid, ++ GMimeDigestAlgo hash, ++ GMimeStream * istream, ++ GMimeStream * ostream, ++ GError ** err); ++ ++static GMimeSignatureList *g_mime_gpgme_verify(GMimeCryptoContext * ctx, ++ GMimeDigestAlgo hash, ++ GMimeStream * istream, ++ GMimeStream * sigstream, ++ GError ** err); ++ ++static int g_mime_gpgme_encrypt(GMimeCryptoContext * ctx, ++ gboolean sign, ++ const char *userid, ++ GMimeDigestAlgo digest, ++ GPtrArray * recipients, ++ GMimeStream * istream, ++ GMimeStream * ostream, GError ** err); ++ ++static GMimeDecryptResult *g_mime_gpgme_decrypt(GMimeCryptoContext * ctx, ++ GMimeStream * istream, ++ GMimeStream * ostream, ++ GError ** err); ++#endif /* HAVE_GMIME_2_5_7 */ + + + /* internal passphrase callback */ +@@ -102,7 +146,11 @@ static void g_set_error_from_gpgme(GError ** error, gpgme_error_t gpgme_err, + const gchar * message); + + ++#ifndef HAVE_GMIME_2_5_7 + static GMimeCipherContextClass *parent_class = NULL; ++#else /* HAVE_GMIME_2_5_7 */ ++static GMimeCryptoContextClass *parent_class = NULL; ++#endif /* HAVE_GMIME_2_5_7 */ + + + GType +@@ -124,8 +172,13 @@ g_mime_gpgme_context_get_type(void) + }; + + type = ++#ifndef HAVE_GMIME_2_5_7 + g_type_register_static(GMIME_TYPE_CIPHER_CONTEXT, + "GMimeGpgmeContext", &info, 0); ++#else /* HAVE_GMIME_2_5_7 */ ++ g_type_register_static(GMIME_TYPE_CRYPTO_CONTEXT, ++ "GMimeGpgmeContext", &info, 0); ++#endif /* HAVE_GMIME_2_5_7 */ + } + + return type; +@@ -136,19 +189,39 @@ static void + g_mime_gpgme_context_class_init(GMimeGpgmeContextClass * klass) + { + GObjectClass *object_class = G_OBJECT_CLASS(klass); ++#ifndef HAVE_GMIME_2_5_7 + GMimeCipherContextClass *cipher_class = + GMIME_CIPHER_CONTEXT_CLASS(klass); ++#else /* HAVE_GMIME_2_5_7 */ ++ GMimeCryptoContextClass *crypto_class = ++ GMIME_CRYPTO_CONTEXT_CLASS(klass); ++#endif /* HAVE_GMIME_2_5_7 */ + + parent_class = g_type_class_ref(G_TYPE_OBJECT); + + object_class->finalize = g_mime_gpgme_context_finalize; + ++#ifndef HAVE_GMIME_2_5_7 + cipher_class->hash_id = g_mime_gpgme_hash_id; + cipher_class->hash_name = g_mime_gpgme_hash_name; + cipher_class->sign = g_mime_gpgme_sign; + cipher_class->verify = g_mime_gpgme_verify; + cipher_class->encrypt = g_mime_gpgme_encrypt; + cipher_class->decrypt = g_mime_gpgme_decrypt; ++#else /* HAVE_GMIME_2_5_7 */ ++ crypto_class->digest_id = g_mime_gpgme_digest_id; ++ crypto_class->digest_name = g_mime_gpgme_digest_name; ++ crypto_class->get_signature_protocol = ++ g_mime_gpgme_get_signature_protocol; ++ crypto_class->get_encryption_protocol = ++ g_mime_gpgme_get_encryption_protocol; ++ crypto_class->get_key_exchange_protocol = ++ g_mime_gpgme_get_key_exchange_protocol; ++ crypto_class->sign = g_mime_gpgme_sign; ++ crypto_class->verify = g_mime_gpgme_verify; ++ crypto_class->encrypt = g_mime_gpgme_encrypt; ++ crypto_class->decrypt = g_mime_gpgme_decrypt; ++#endif /* HAVE_GMIME_2_5_7 */ + + if (gpgme_engine_check_version(GPGME_PROTOCOL_OpenPGP) == + GPG_ERR_NO_ERROR) +@@ -190,7 +263,11 @@ g_mime_gpgme_context_finalize(GObject * object) + } + + #if !defined(HAVE_GMIME_2_6) ++#ifndef HAVE_GMIME_2_5_7 + g_object_unref(GMIME_CIPHER_CONTEXT(ctx)->session); ++#else /* HAVE_GMIME_2_5_7 */ ++ g_object_unref(GMIME_CRYPTO_CONTEXT(ctx)->session); ++#endif /* HAVE_GMIME_2_5_7 */ + #endif /* HAVE_GMIME_2_6 */ + + G_OBJECT_CLASS(parent_class)->finalize(object); +@@ -200,15 +277,26 @@ g_mime_gpgme_context_finalize(GObject * object) + /* + * Convert a hash algorithm name to a number + */ ++#ifndef HAVE_GMIME_2_5_7 + static GMimeCipherHash + g_mime_gpgme_hash_id(GMimeCipherContext * ctx, const char *hash) ++#else /* HAVE_GMIME_2_5_7 */ ++static GMimeDigestAlgo ++g_mime_gpgme_digest_id(GMimeCryptoContext * ctx, const char *hash) ++#endif /* HAVE_GMIME_2_5_7 */ + { ++#ifndef HAVE_GMIME_2_5_7 + if (hash == NULL) + return GMIME_CIPHER_HASH_DEFAULT; ++#else /* HAVE_GMIME_2_5_7 */ ++ if (hash == NULL) ++ return GMIME_DIGEST_ALGO_DEFAULT; ++#endif /* HAVE_GMIME_2_5_7 */ + + if (!g_ascii_strcasecmp(hash, "pgp-")) + hash += 4; + ++#ifndef HAVE_GMIME_2_5_7 + if (!g_ascii_strcasecmp(hash, "md2")) + return GMIME_CIPHER_HASH_MD2; + else if (!g_ascii_strcasecmp(hash, "md5")) +@@ -223,6 +311,22 @@ g_mime_gpgme_hash_id(GMimeCipherContext * ctx, const char *hash) + return GMIME_CIPHER_HASH_HAVAL5160; + + return GMIME_CIPHER_HASH_DEFAULT; ++#else /* HAVE_GMIME_2_5_7 */ ++ if (!g_ascii_strcasecmp(hash, "md2")) ++ return GMIME_DIGEST_ALGO_MD2; ++ else if (!g_ascii_strcasecmp(hash, "md5")) ++ return GMIME_DIGEST_ALGO_MD5; ++ else if (!g_ascii_strcasecmp(hash, "sha1")) ++ return GMIME_DIGEST_ALGO_SHA1; ++ else if (!g_ascii_strcasecmp(hash, "ripemd160")) ++ return GMIME_DIGEST_ALGO_RIPEMD160; ++ else if (!g_ascii_strcasecmp(hash, "tiger192")) ++ return GMIME_DIGEST_ALGO_TIGER192; ++ else if (!g_ascii_strcasecmp(hash, "haval-5-160")) ++ return GMIME_DIGEST_ALGO_HAVAL5160; ++ ++ return GMIME_DIGEST_ALGO_DEFAULT; ++#endif /* HAVE_GMIME_2_5_7 */ + } + + +@@ -230,7 +334,11 @@ g_mime_gpgme_hash_id(GMimeCipherContext * ctx, const char *hash) + * Convert a hash algorithm number to a string + */ + static const char * ++#ifndef HAVE_GMIME_2_5_7 + g_mime_gpgme_hash_name(GMimeCipherContext * context, GMimeCipherHash hash) ++#else /* HAVE_GMIME_2_5_7 */ ++g_mime_gpgme_digest_name(GMimeCryptoContext * context, GMimeDigestAlgo hash) ++#endif /* HAVE_GMIME_2_5_7 */ + { + GMimeGpgmeContext *ctx = GMIME_GPGME_CONTEXT(context); + char *p; +@@ -239,6 +347,7 @@ g_mime_gpgme_hash_name(GMimeCipherContext * context, GMimeCipherHash hash) + g_return_val_if_fail(ctx->gpgme_ctx, NULL); + + /* note: this is only a subset of the hash algorithms gpg(me) supports */ ++#ifndef HAVE_GMIME_2_5_7 + switch (hash) { + case GMIME_CIPHER_HASH_MD2: + p = "pgp-md2"; +@@ -258,6 +367,27 @@ g_mime_gpgme_hash_name(GMimeCipherContext * context, GMimeCipherHash hash) + case GMIME_CIPHER_HASH_HAVAL5160: + p = "pgp-haval-5-160"; + break; ++#else /* HAVE_GMIME_2_5_7 */ ++ switch (hash) { ++ case GMIME_DIGEST_ALGO_MD2: ++ p = "pgp-md2"; ++ break; ++ case GMIME_DIGEST_ALGO_MD5: ++ p = "pgp-md5"; ++ break; ++ case GMIME_DIGEST_ALGO_SHA1: ++ p = "pgp-sha1"; ++ break; ++ case GMIME_DIGEST_ALGO_RIPEMD160: ++ p = "pgp-ripemd160"; ++ break; ++ case GMIME_DIGEST_ALGO_TIGER192: ++ p = "pgp-tiger192"; ++ break; ++ case GMIME_DIGEST_ALGO_HAVAL5160: ++ p = "pgp-haval-5-160"; ++ break; ++#endif /* HAVE_GMIME_2_5_7 */ + default: + if (!(p = ctx->micalg)) + return p; +@@ -270,6 +400,29 @@ g_mime_gpgme_hash_name(GMimeCipherContext * context, GMimeCipherHash hash) + return p; + } + ++#ifdef HAVE_GMIME_2_5_7 ++static const char * ++g_mime_gpgme_get_signature_protocol(GMimeCryptoContext * context) ++{ ++ GMimeGpgmeContext *ctx = GMIME_GPGME_CONTEXT(context); ++ return ctx->sign_protocol; ++} ++ ++static const char * ++g_mime_gpgme_get_encryption_protocol(GMimeCryptoContext * context) ++{ ++ GMimeGpgmeContext *ctx = GMIME_GPGME_CONTEXT(context); ++ return ctx->encrypt_protocol; ++} ++ ++static const char * ++g_mime_gpgme_get_key_exchange_protocol(GMimeCryptoContext * context) ++{ ++ GMimeGpgmeContext *ctx = GMIME_GPGME_CONTEXT(context); ++ return ctx->key_protocol; ++} ++ ++#endif /* HAVE_GMIME_2_5_7 */ + + /* + * Wrapper to convert the passphrase returned from the gmime session to gpgme. +@@ -279,7 +432,11 @@ g_mime_session_passphrase(void *HOOK, const char *UID_HINT, + const char *PASSPHRASE_INFO, int PREV_WAS_BAD, + int FD) + { ++#ifndef HAVE_GMIME_2_5_7 + GMimeCipherContext *ctx = GMIME_CIPHER_CONTEXT(HOOK); ++#else /* HAVE_GMIME_2_5_7 */ ++ GMimeCryptoContext *ctx = GMIME_CRYPTO_CONTEXT(HOOK); ++#endif /* HAVE_GMIME_2_5_7 */ + #if defined(HAVE_GMIME_2_6) + GMimeStream *stream; + gboolean rc; +@@ -366,9 +523,15 @@ cb_data_release(void *handle) + * arg, but set the value in the context. + */ + static int ++#ifndef HAVE_GMIME_2_5_7 + g_mime_gpgme_sign(GMimeCipherContext * context, const char *userid, + GMimeCipherHash hash, GMimeStream * istream, + GMimeStream * ostream, GError ** error) ++#else /* HAVE_GMIME_2_5_7 */ ++g_mime_gpgme_sign(GMimeCryptoContext * context, const char *userid, ++ GMimeDigestAlgo hash, GMimeStream * istream, ++ GMimeStream * ostream, GError ** error) ++#endif /* HAVE_GMIME_2_5_7 */ + { + GMimeGpgmeContext *ctx = (GMimeGpgmeContext *) context; + gpgme_sig_mode_t sig_mode; +@@ -460,6 +623,7 @@ g_mime_gpgme_sign(GMimeCipherContext * context, const char *userid, + } + + ++#ifndef HAVE_GMIME_2_5_7 + /* + * In standard mode, verify that sigstream contains a detached signature for + * istream. In single-part mode (RFC 2440, RFC 2633 application/pkcs7-mime), +@@ -471,13 +635,33 @@ static GMimeSignatureValidity * + g_mime_gpgme_verify(GMimeCipherContext * context, GMimeCipherHash hash, + GMimeStream * istream, GMimeStream * sigstream, + GError ** error) ++#else /* HAVE_GMIME_2_5_7 */ ++/* ++ * In standard mode, verify that sigstream contains a detached signature for ++ * istream. In single-part mode (RFC 2440, RFC 2633 application/pkcs7-mime), ++ * istream contains clearsigned data, and sigstream will be filled with the ++ * verified plaintext. The routine returns a GMimeSignatureList object. ++ * More information is saved in the context's signature object. ++ * On error error is set accordingly. ++ */ ++static GMimeSignatureList * ++g_mime_gpgme_verify(GMimeCryptoContext * context, GMimeDigestAlgo hash, ++ GMimeStream * istream, GMimeStream * sigstream, ++ GError ** error) ++#endif /* HAVE_GMIME_2_5_7 */ + { + GMimeGpgmeContext *ctx = (GMimeGpgmeContext *) context; + gpgme_ctx_t gpgme_ctx; + gpgme_protocol_t protocol; + gpgme_error_t err; + gpgme_data_t msg, sig; ++#ifndef HAVE_GMIME_2_5_7 + GMimeSignatureValidity *validity; ++#else /* HAVE_GMIME_2_5_7 */ ++ GMimeSignatureList *list; ++ GMimeSignature *signature; ++ ++#endif /* HAVE_GMIME_2_5_7 */ + struct gpgme_data_cbs cbs = { + (gpgme_data_read_cb_t) g_mime_gpgme_stream_rd, /* read method */ + (gpgme_data_write_cb_t) g_mime_gpgme_stream_wr, /* write method */ +@@ -521,6 +705,7 @@ g_mime_gpgme_verify(GMimeCipherContext * context, GMimeCipherHash hash, + ctx->sig_state = + g_mime_gpgme_sigstat_new_from_gpgme_ctx(gpgme_ctx); + ++#ifndef HAVE_GMIME_2_5_7 + validity = g_mime_signature_validity_new(); + if (ctx->sig_state) { + switch (ctx->sig_state->status) +@@ -536,12 +721,44 @@ g_mime_gpgme_verify(GMimeCipherContext * context, GMimeCipherHash hash, + } + } else + g_mime_signature_validity_set_status(validity, GMIME_SIGNATURE_STATUS_UNKNOWN); ++#else /* HAVE_GMIME_2_5_7 */ ++ list = g_mime_signature_list_new(); ++ signature = g_mime_signature_new(); ++ g_mime_signature_list_add(list, signature); ++ ++ if (ctx->sig_state) { ++ switch (ctx->sig_state->status) ++ { ++ case GPG_ERR_NO_ERROR: ++ g_mime_signature_set_status(signature, ++ GMIME_SIGNATURE_STATUS_GOOD); ++ break; ++ case GPG_ERR_NOT_SIGNED: ++ g_mime_signature_set_status(signature, ++ GMIME_SIGNATURE_STATUS_ERROR); ++ g_mime_signature_set_errors(signature, ++ GMIME_SIGNATURE_ERROR_NONE); ++ break; ++ default: ++ g_mime_signature_set_status(signature, ++ GMIME_SIGNATURE_STATUS_BAD); ++ } ++ } else { ++ g_mime_signature_set_status(signature, ++ GMIME_SIGNATURE_STATUS_ERROR); ++ g_mime_signature_set_errors(signature, GMIME_SIGNATURE_ERROR_NONE); ++ } ++#endif /* HAVE_GMIME_2_5_7 */ + + /* release gmgme data buffers */ + gpgme_data_release(msg); + gpgme_data_release(sig); + ++#ifndef HAVE_GMIME_2_5_7 + return validity; ++#else /* HAVE_GMIME_2_5_7 */ ++ return list; ++#endif /* HAVE_GMIME_2_5_7 */ + } + + +@@ -549,10 +766,19 @@ g_mime_gpgme_verify(GMimeCipherContext * context, GMimeCipherHash hash, + * Encrypt istream to ostream for recipients. If sign is set, sign by userid. + */ + static int ++#ifndef HAVE_GMIME_2_5_7 + g_mime_gpgme_encrypt(GMimeCipherContext * context, gboolean sign, + const char *userid, GPtrArray * recipients, + GMimeStream * istream, GMimeStream * ostream, + GError ** error) ++#else /* HAVE_GMIME_2_5_7 */ ++g_mime_gpgme_encrypt(GMimeCryptoContext * context, gboolean sign, ++ const char *userid, ++ GMimeDigestAlgo digest, ++ GPtrArray * recipients, ++ GMimeStream * istream, GMimeStream * ostream, ++ GError ** error) ++#endif /* HAVE_GMIME_2_5_7 */ + { + GMimeGpgmeContext *ctx = (GMimeGpgmeContext *) context; + gpgme_ctx_t gpgme_ctx; +@@ -653,9 +879,15 @@ g_mime_gpgme_encrypt(GMimeCipherContext * context, gboolean sign, + * Decrypt istream to ostream. In RFC 2440 mode, also try to check an included + * signature (if any). + */ ++#ifndef HAVE_GMIME_2_5_7 + static GMimeSignatureValidity * + g_mime_gpgme_decrypt(GMimeCipherContext * context, GMimeStream * istream, + GMimeStream * ostream, GError ** error) ++#else /* HAVE_GMIME_2_5_7 */ ++static GMimeDecryptResult * ++g_mime_gpgme_decrypt(GMimeCryptoContext * context, GMimeStream * istream, ++ GMimeStream * ostream, GError ** error) ++#endif /* HAVE_GMIME_2_5_7 */ + { + GMimeGpgmeContext *ctx = (GMimeGpgmeContext *) context; + gpgme_ctx_t gpgme_ctx; +@@ -668,7 +900,13 @@ g_mime_gpgme_decrypt(GMimeCipherContext * context, GMimeStream * istream, + NULL, /* seek method */ + cb_data_release /* release method */ + }; ++#ifndef HAVE_GMIME_2_5_7 + GMimeSignatureValidity *validity; ++#else /* HAVE_GMIME_2_5_7 */ ++ GMimeDecryptResult *result; ++ GMimeSignatureList *list; ++ GMimeSignature *signature; ++#endif /* HAVE_GMIME_2_5_7 */ + + /* some paranoia checks */ + g_return_val_if_fail(ctx, NULL); +@@ -716,6 +954,7 @@ g_mime_gpgme_decrypt(GMimeCipherContext * context, GMimeStream * istream, + /* try to get information about the signature (if any) */ + ctx->sig_state = g_mime_gpgme_sigstat_new_from_gpgme_ctx(gpgme_ctx); + ++#ifndef HAVE_GMIME_2_5_7 + validity = g_mime_signature_validity_new(); + if (ctx->sig_state) { + switch (ctx->sig_state->status) +@@ -733,14 +972,57 @@ g_mime_gpgme_decrypt(GMimeCipherContext * context, GMimeStream * istream, + g_mime_signature_validity_set_status(validity, GMIME_SIGNATURE_STATUS_UNKNOWN); + + return validity; ++#else /* HAVE_GMIME_2_5_7 */ ++ list = g_mime_signature_list_new(); ++ signature = g_mime_signature_new(); ++ g_mime_signature_list_add(list, signature); ++ result = g_mime_decrypt_result_new(); ++ g_mime_decrypt_result_set_signatures(result, list); ++ ++ if (ctx->sig_state) { ++ switch (ctx->sig_state->status) ++ { ++ case GPG_ERR_NO_ERROR: ++ g_mime_signature_set_status(signature, ++ GMIME_SIGNATURE_STATUS_GOOD); ++ break; ++ case GPG_ERR_NOT_SIGNED: ++ g_mime_signature_set_status(signature, ++ GMIME_SIGNATURE_STATUS_ERROR); ++ g_mime_signature_set_errors(signature, ++ GMIME_SIGNATURE_ERROR_NONE); ++ break; ++ default: ++ g_mime_signature_set_status(signature, ++ GMIME_SIGNATURE_STATUS_BAD); ++ } ++ } else { ++ g_mime_signature_set_status(signature, ++ GMIME_SIGNATURE_STATUS_ERROR); ++ g_mime_signature_set_errors(signature, GMIME_SIGNATURE_ERROR_NONE); ++ } ++ ++ return result; ++#endif /* HAVE_GMIME_2_5_7 */ + } + + ++#ifndef HAVE_GMIME_2_5_7 + /* + * Create a new gpgme cipher context with protocol. If anything fails, return + * NULL and set error. + */ ++#else /* HAVE_GMIME_2_5_7 */ ++/* ++ * Create a new gpgme crypto context with protocol. If anything fails, return ++ * NULL and set error. ++ */ ++#endif /* HAVE_GMIME_2_5_7 */ ++#ifndef HAVE_GMIME_2_5_7 + GMimeCipherContext * ++#else /* HAVE_GMIME_2_5_7 */ ++GMimeCryptoContext * ++#endif /* HAVE_GMIME_2_5_7 */ + #if defined(HAVE_GMIME_2_6) + g_mime_gpgme_context_new(GMimePasswordRequestFunc request_passwd, + gpgme_protocol_t protocol, GError ** error) +@@ -749,7 +1031,11 @@ g_mime_gpgme_context_new(GMimeSession * session, + gpgme_protocol_t protocol, GError ** error) + #endif /* HAVE_GMIME_2_6 */ + { ++#ifndef HAVE_GMIME_2_5_7 + GMimeCipherContext *cipher; ++#else /* HAVE_GMIME_2_5_7 */ ++ GMimeCryptoContext *crypto; ++#endif /* HAVE_GMIME_2_5_7 */ + GMimeGpgmeContext *ctx; + gpgme_error_t err; + gpgme_ctx_t gpgme_ctx; +@@ -766,14 +1052,22 @@ g_mime_gpgme_context_new(GMimeSession * session, + return NULL; + } + ++#ifndef HAVE_GMIME_2_5_7 + /* create the cipher context */ ++#else /* HAVE_GMIME_2_5_7 */ ++ /* create the crypto context */ ++#endif /* HAVE_GMIME_2_5_7 */ + ctx = g_object_new(GMIME_TYPE_GPGME_CONTEXT, NULL, NULL); + if (!ctx) { + gpgme_release(gpgme_ctx); + return NULL; + } else + ctx->gpgme_ctx = gpgme_ctx; ++#ifndef HAVE_GMIME_2_5_7 + cipher = (GMimeCipherContext *) ctx; ++#else /* HAVE_GMIME_2_5_7 */ ++ crypto = (GMimeCryptoContext *) ctx; ++#endif /* HAVE_GMIME_2_5_7 */ + + /* check if the requested protocol is available */ + if (!g_mime_gpgme_context_check_protocol +@@ -785,23 +1079,47 @@ g_mime_gpgme_context_new(GMimeSession * session, + + /* setup according to requested protocol */ + #if defined(HAVE_GMIME_2_6) ++#ifndef HAVE_GMIME_2_5_7 + cipher->request_passwd = request_passwd; ++#else /* HAVE_GMIME_2_5_7 */ ++ crypto->request_passwd = request_passwd; ++#endif /* HAVE_GMIME_2_5_7 */ + #else /* HAVE_GMIME_2_6 */ ++#ifndef HAVE_GMIME_2_5_7 + cipher->session = session; ++#else /* HAVE_GMIME_2_5_7 */ ++ crypto->session = session; ++#endif /* HAVE_GMIME_2_5_7 */ + g_object_ref(session); + #endif /* HAVE_GMIME_2_6 */ + gpgme_set_protocol(gpgme_ctx, protocol); + if (protocol == GPGME_PROTOCOL_OpenPGP) { ++#ifndef HAVE_GMIME_2_5_7 + cipher->sign_protocol = "application/pgp-signature"; + cipher->encrypt_protocol = "application/pgp-encrypted"; + cipher->key_protocol = NULL; /* FIXME */ ++#else /* HAVE_GMIME_2_5_7 */ ++ ctx->sign_protocol = "application/pgp-signature"; ++ ctx->encrypt_protocol = "application/pgp-encrypted"; ++ ctx->key_protocol = NULL; /* FIXME */ ++#endif /* HAVE_GMIME_2_5_7 */ + } else { ++#ifndef HAVE_GMIME_2_5_7 + cipher->sign_protocol = "application/pkcs7-signature"; + cipher->encrypt_protocol = "application/pkcs7-mime"; + cipher->key_protocol = NULL; /* FIXME */ ++#else /* HAVE_GMIME_2_5_7 */ ++ ctx->sign_protocol = "application/pkcs7-signature"; ++ ctx->encrypt_protocol = "application/pkcs7-mime"; ++ ctx->key_protocol = NULL; /* FIXME */ ++#endif /* HAVE_GMIME_2_5_7 */ + } + ++#ifndef HAVE_GMIME_2_5_7 + return cipher; ++#else /* HAVE_GMIME_2_5_7 */ ++ return crypto; ++#endif /* HAVE_GMIME_2_5_7 */ + } + + +diff --git a/libbalsa/gmime-gpgme-context.h b/libbalsa/gmime-gpgme-context.h +index 585d927..19c5fae 100644 +--- a/libbalsa/gmime-gpgme-context.h ++++ b/libbalsa/gmime-gpgme-context.h +@@ -63,7 +63,11 @@ typedef gboolean(*GMimeGpgmeKeyTrustCB) (const gchar * name, + GMimeGpgmeContext * ctx); + + struct _GMimeGpgmeContext { ++#ifndef HAVE_GMIME_2_5_7 + GMimeCipherContext parent_object; ++#else /* HAVE_GMIME_2_5_7 */ ++ GMimeCryptoContext parent_object; ++#endif /* HAVE_GMIME_2_5_7 */ + + gpgme_ctx_t gpgme_ctx; /* gpgme context */ + gboolean singlepart_mode; /* set context to single-part mode (RFC 2440, 2633) */ +@@ -73,11 +77,21 @@ struct _GMimeGpgmeContext { + GMimeGpgmeKeySelectCB key_select_cb; /* key selection callback */ + GMimeGpgmeKeyTrustCB key_trust_cb; /* low trust key cb */ + gpgme_passphrase_cb_t passphrase_cb; /* passphrase callback */ ++#ifdef HAVE_GMIME_2_5_7 ++ ++ const gchar *sign_protocol; ++ const gchar *encrypt_protocol; ++ const gchar *key_protocol; ++#endif /* HAVE_GMIME_2_5_7 */ + }; + + + struct _GMimeGpgmeContextClass { ++#ifndef HAVE_GMIME_2_5_7 + GMimeCipherContextClass parent_class; ++#else /* HAVE_GMIME_2_5_7 */ ++ GMimeCryptoContextClass parent_class; ++#endif /* HAVE_GMIME_2_5_7 */ + + gboolean has_proto_openpgp; + gboolean has_proto_cms; +@@ -86,10 +100,17 @@ struct _GMimeGpgmeContextClass { + + GType g_mime_gpgme_context_get_type(void); + #if defined(HAVE_GMIME_2_6) ++#ifndef HAVE_GMIME_2_5_7 + GMimeCipherContext *g_mime_gpgme_context_new(GMimePasswordRequestFunc + request_passwd, + gpgme_protocol_t protocol, + GError ** error); ++#else /* HAVE_GMIME_2_5_7 */ ++GMimeCryptoContext *g_mime_gpgme_context_new(GMimePasswordRequestFunc ++ request_passwd, ++ gpgme_protocol_t protocol, ++ GError ** error); ++#endif /* HAVE_GMIME_2_5_7 */ + #else /* HAVE_GMIME_2_6 */ + GMimeCipherContext *g_mime_gpgme_context_new(GMimeSession * session, + gpgme_protocol_t protocol, +diff --git a/libbalsa/gmime-part-rfc2440.c b/libbalsa/gmime-part-rfc2440.c +index 795d2e1..e79c4cb 100644 +--- a/libbalsa/gmime-part-rfc2440.c ++++ b/libbalsa/gmime-part-rfc2440.c +@@ -112,8 +112,13 @@ g_mime_part_rfc2440_sign_encrypt(GMimePart * part, + + g_return_val_if_fail(GMIME_IS_PART(part), -1); + g_return_val_if_fail(GMIME_IS_GPGME_CONTEXT(ctx), -1); ++#ifndef HAVE_GMIME_2_5_7 + g_return_val_if_fail(GMIME_CIPHER_CONTEXT(ctx)->sign_protocol != NULL, + -1); ++#else /* HAVE_GMIME_2_5_7 */ ++ g_return_val_if_fail(g_mime_crypto_context_get_signature_protocol ++ (GMIME_CRYPTO_CONTEXT(ctx)) != NULL, -1); ++#endif /* HAVE_GMIME_2_5_7 */ + g_return_val_if_fail(recipients != NULL || sign_userid != NULL, -1); + + /* get the raw content */ +@@ -131,14 +136,27 @@ g_mime_part_rfc2440_sign_encrypt(GMimePart * part, + ctx->singlepart_mode = TRUE; + if (recipients == NULL) + result = ++#ifndef HAVE_GMIME_2_5_7 + g_mime_cipher_context_sign(GMIME_CIPHER_CONTEXT(ctx), sign_userid, + GMIME_CIPHER_HASH_DEFAULT, stream, + cipherstream, err); ++#else /* HAVE_GMIME_2_5_7 */ ++ g_mime_crypto_context_sign(GMIME_CRYPTO_CONTEXT(ctx), sign_userid, ++ GMIME_CIPHER_ALGO_DEFAULT, stream, ++ cipherstream, err); ++#endif /* HAVE_GMIME_2_5_7 */ + else + result = ++#ifndef HAVE_GMIME_2_5_7 + g_mime_cipher_context_encrypt(GMIME_CIPHER_CONTEXT(ctx), + sign_userid != NULL, sign_userid, + recipients, stream, cipherstream, err); ++#else /* HAVE_GMIME_2_5_7 */ ++ g_mime_crypto_context_encrypt(GMIME_CRYPTO_CONTEXT(ctx), ++ sign_userid != NULL, sign_userid, ++ GMIME_CIPHER_ALGO_DEFAULT, ++ recipients, stream, cipherstream, err); ++#endif /* HAVE_GMIME_2_5_7 */ + if (result == -1) { + g_object_unref(cipherstream); + return -1; +@@ -202,18 +220,31 @@ g_mime_part_rfc2440_sign_encrypt(GMimePart * part, + * set on err to provide more information. Upon success, the content + * of part is replaced by the verified output of the crypto engine. + */ ++#ifndef HAVE_GMIME_2_5_7 + GMimeSignatureValidity * ++#else /* HAVE_GMIME_2_5_7 */ ++GMimeSignatureList * ++#endif /* HAVE_GMIME_2_5_7 */ + g_mime_part_rfc2440_verify(GMimePart * part, + GMimeGpgmeContext * ctx, GError ** err) + { + GMimeStream *stream, *plainstream; + GMimeDataWrapper * wrapper; ++#ifndef HAVE_GMIME_2_5_7 + GMimeSignatureValidity *valid; ++#else /* HAVE_GMIME_2_5_7 */ ++ GMimeSignatureList *list; ++#endif /* HAVE_GMIME_2_5_7 */ + + g_return_val_if_fail(GMIME_IS_PART(part), NULL); + g_return_val_if_fail(GMIME_IS_GPGME_CONTEXT(ctx), NULL); ++#ifndef HAVE_GMIME_2_5_7 + g_return_val_if_fail(GMIME_CIPHER_CONTEXT(ctx)->sign_protocol != NULL, + NULL); ++#else /* HAVE_GMIME_2_5_7 */ ++ g_return_val_if_fail(g_mime_crypto_context_get_signature_protocol ++ (GMIME_CRYPTO_CONTEXT(ctx)) != NULL, NULL); ++#endif /* HAVE_GMIME_2_5_7 */ + + /* get the raw content */ + wrapper = g_mime_part_get_content_object(GMIME_PART(part)); +@@ -227,13 +258,25 @@ g_mime_part_rfc2440_verify(GMimePart * part, + + /* verify the signature */ + ctx->singlepart_mode = TRUE; ++#ifndef HAVE_GMIME_2_5_7 + valid = + g_mime_cipher_context_verify(GMIME_CIPHER_CONTEXT(ctx), + GMIME_CIPHER_HASH_DEFAULT, stream, + plainstream, err); ++#else /* HAVE_GMIME_2_5_7 */ ++ list = ++ g_mime_crypto_context_verify(GMIME_CRYPTO_CONTEXT(ctx), ++ GMIME_CIPHER_ALGO_DEFAULT, stream, ++ plainstream, err); ++#endif /* HAVE_GMIME_2_5_7 */ + + /* upon success, replace the signed content by the checked one */ +- if (valid) { ++#ifndef HAVE_GMIME_2_5_7 ++ if (valid) ++#else /* HAVE_GMIME_2_5_7 */ ++ if (list) ++#endif /* HAVE_GMIME_2_5_7 */ ++ { + GMimeDataWrapper *wrapper = g_mime_data_wrapper_new(); + + g_mime_data_wrapper_set_stream(wrapper, plainstream); +@@ -242,7 +285,11 @@ g_mime_part_rfc2440_verify(GMimePart * part, + } + g_object_unref(plainstream); + ++#ifndef HAVE_GMIME_2_5_7 + return valid; ++#else /* HAVE_GMIME_2_5_7 */ ++ return list; ++#endif /* HAVE_GMIME_2_5_7 */ + } + + +@@ -255,19 +302,32 @@ g_mime_part_rfc2440_verify(GMimePart * part, + * verified and the result is placed in ctx by the underlying gpgme + * context. + */ ++#ifndef HAVE_GMIME_2_5_7 + GMimeSignatureValidity * ++#else /* HAVE_GMIME_2_5_7 */ ++GMimeDecryptResult * ++#endif /* HAVE_GMIME_2_5_7 */ + g_mime_part_rfc2440_decrypt(GMimePart * part, + GMimeGpgmeContext * ctx, GError ** err) + { + GMimeStream *stream, *plainstream; + GMimeDataWrapper * wrapper; ++#ifndef HAVE_GMIME_2_5_7 + GMimeSignatureValidity *result; ++#else /* HAVE_GMIME_2_5_7 */ ++ GMimeDecryptResult *result; ++#endif /* HAVE_GMIME_2_5_7 */ + gchar *headbuf = g_malloc0(1024); + + g_return_val_if_fail(GMIME_IS_PART(part), NULL); + g_return_val_if_fail(GMIME_IS_GPGME_CONTEXT(ctx), NULL); ++#ifndef HAVE_GMIME_2_5_7 + g_return_val_if_fail(GMIME_CIPHER_CONTEXT(ctx)->encrypt_protocol != + NULL, NULL); ++#else /* HAVE_GMIME_2_5_7 */ ++ g_return_val_if_fail(g_mime_crypto_context_get_encryption_protocol ++ (GMIME_CRYPTO_CONTEXT(ctx)) != NULL, NULL); ++#endif /* HAVE_GMIME_2_5_7 */ + + /* get the raw content */ + wrapper = g_mime_part_get_content_object(part); +@@ -284,8 +344,13 @@ g_mime_part_rfc2440_decrypt(GMimePart * part, + + /* decrypt and (if possible) verify the input */ + result = ++#ifndef HAVE_GMIME_2_5_7 + g_mime_cipher_context_decrypt(GMIME_CIPHER_CONTEXT(ctx), stream, + plainstream, err); ++#else /* HAVE_GMIME_2_5_7 */ ++ g_mime_crypto_context_decrypt(GMIME_CRYPTO_CONTEXT(ctx), stream, ++ plainstream, err); ++#endif /* HAVE_GMIME_2_5_7 */ + + if (result != NULL) { + GMimeStream *filter_stream; +diff --git a/libbalsa/gmime-part-rfc2440.h b/libbalsa/gmime-part-rfc2440.h +index 48be5a4..cc1901a 100644 +--- a/libbalsa/gmime-part-rfc2440.h ++++ b/libbalsa/gmime-part-rfc2440.h +@@ -53,12 +53,21 @@ int g_mime_part_rfc2440_sign_encrypt(GMimePart * part, + GPtrArray * recipients, + const char *sign_userid, + GError ** err); ++#ifndef HAVE_GMIME_2_5_7 + GMimeSignatureValidity *g_mime_part_rfc2440_verify(GMimePart * part, + GMimeGpgmeContext * ctx, + GError ** err); + GMimeSignatureValidity *g_mime_part_rfc2440_decrypt(GMimePart * part, + GMimeGpgmeContext * + ctx, GError ** err); ++#else /* HAVE_GMIME_2_5_7 */ ++GMimeSignatureList *g_mime_part_rfc2440_verify(GMimePart * part, ++ GMimeGpgmeContext * ctx, ++ GError ** err); ++GMimeDecryptResult *g_mime_part_rfc2440_decrypt(GMimePart * part, ++ GMimeGpgmeContext * ctx, ++ GError ** err); ++#endif /* HAVE_GMIME_2_5_7 */ + + #ifdef __cplusplus + } +diff --git a/libbalsa/rfc3156.c b/libbalsa/rfc3156.c +index a56e12c..df4a2e1 100644 +--- a/libbalsa/rfc3156.c ++++ b/libbalsa/rfc3156.c +@@ -268,9 +268,15 @@ libbalsa_message_body_protection(LibBalsaMessageBody * body) + + #if defined(HAVE_GMIME_2_6) + static gboolean ++#ifndef HAVE_GMIME_2_5_7 + password_request_func(GMimeCipherContext * ctx, const char *user_id, + const char *prompt_ctx, gboolean reprompt, + GMimeStream * response, GError ** err) ++#else /* HAVE_GMIME_2_5_7 */ ++password_request_func(GMimeCryptoContext * ctx, const char *user_id, ++ const char *prompt_ctx, gboolean reprompt, ++ GMimeStream * response, GError ** err) ++#endif /* HAVE_GMIME_2_5_7 */ + { + gint fd; + gchar *name_used; +@@ -366,9 +372,16 @@ libbalsa_sign_mime_object(GMimeObject ** content, const gchar * rfc822_for, + return FALSE; + } + ++#ifndef HAVE_GMIME_2_5_7 + if (g_mime_multipart_signed_sign + (mps, *content, GMIME_CIPHER_CONTEXT(ctx), rfc822_for, +- GMIME_CIPHER_HASH_DEFAULT, error) != 0) { ++ GMIME_CIPHER_HASH_DEFAULT, error) != 0) ++#else /* HAVE_GMIME_2_5_7 */ ++ if (g_mime_multipart_signed_sign ++ (mps, *content, GMIME_CRYPTO_CONTEXT(ctx), rfc822_for, ++ GMIME_DIGEST_ALGO_DEFAULT, error) != 0) ++#endif /* HAVE_GMIME_2_5_7 */ ++ { + g_object_unref(mps); + g_object_unref(ctx); + #if !defined(HAVE_GMIME_2_6) +@@ -458,10 +471,18 @@ libbalsa_encrypt_mime_object(GMimeObject ** content, GList * rfc822_for, + + encrypted_obj = GMIME_OBJECT(mpe); + result = ++#ifndef HAVE_GMIME_2_5_7 + g_mime_multipart_encrypted_encrypt(mpe, *content, + GMIME_CIPHER_CONTEXT(ctx), + FALSE, NULL, + recipients, error); ++#else /* HAVE_GMIME_2_5_7 */ ++ g_mime_multipart_encrypted_encrypt(mpe, *content, ++ GMIME_CRYPTO_CONTEXT(ctx), ++ FALSE, NULL, ++ GMIME_DIGEST_ALGO_DEFAULT, ++ recipients, error); ++#endif /* HAVE_GMIME_2_5_7 */ + } + #ifdef HAVE_SMIME + else { +@@ -471,9 +492,15 @@ libbalsa_encrypt_mime_object(GMimeObject ** content, GList * rfc822_for, + encrypted_obj = GMIME_OBJECT(pkcs7); + ctx->singlepart_mode = TRUE; + result = ++#ifndef HAVE_GMIME_2_5_7 + g_mime_application_pkcs7_encrypt(pkcs7, *content, + GMIME_CIPHER_CONTEXT(ctx), + recipients, error); ++#else /* HAVE_GMIME_2_5_7 */ ++ g_mime_application_pkcs7_encrypt(pkcs7, *content, ++ GMIME_CRYPTO_CONTEXT(ctx), ++ recipients, error); ++#endif /* HAVE_GMIME_2_5_7 */ + } + #endif + +@@ -565,8 +592,14 @@ libbalsa_body_check_signature(LibBalsaMessageBody * body, + #if !defined(HAVE_GMIME_2_6) + GMimeSession *session; + #endif /* HAVE_GMIME_2_6 */ +- GMimeCipherContext *ctx; ++#ifndef HAVE_GMIME_2_5_7 ++ GMimeCipherContext *g_mime_ctx; + GMimeSignatureValidity *valid; ++#else /* HAVE_GMIME_2_5_7 */ ++ GMimeCryptoContext *g_mime_ctx; ++ GMimeSignatureList *valid; ++#endif /* HAVE_GMIME_2_5_7 */ ++ GMimeGpgmeContext *ctx; + GError *error = NULL; + + /* paranoia checks */ +@@ -592,12 +625,12 @@ libbalsa_body_check_signature(LibBalsaMessageBody * body, + /* try to create GMimeGpgMEContext */ + #if !defined(HAVE_GMIME_2_6) + session = g_object_new(g_mime_session_get_type(), NULL, NULL); +- ctx = g_mime_gpgme_context_new(session, protocol, &error); ++ g_mime_ctx = g_mime_gpgme_context_new(session, protocol, &error); + #else /* HAVE_GMIME_2_6 */ +- ctx = ++ g_mime_ctx = + g_mime_gpgme_context_new(password_request_func, protocol, &error); + #endif /* HAVE_GMIME_2_6 */ +- if (ctx == NULL) { ++ if (g_mime_ctx == NULL) { + if (error) { + libbalsa_information(LIBBALSA_INFORMATION_ERROR, "%s: %s", + _("creating a gpgme context failed"), +@@ -613,6 +646,7 @@ libbalsa_body_check_signature(LibBalsaMessageBody * body, + body->parts->next->sig_info->status = GPGME_SIG_STAT_ERROR; + return FALSE; + } ++ ctx = GMIME_GPGME_CONTEXT(g_mime_ctx); + + /* S/MIME uses the protocol application/pkcs7-signature, but some ancient + mailers, not yet knowing RFC 2633, use application/x-pkcs7-signature, +@@ -622,14 +656,19 @@ libbalsa_body_check_signature(LibBalsaMessageBody * body, + g_mime_object_get_content_type_parameter(GMIME_OBJECT (body->mime_part), + "protocol"); + if (!g_ascii_strcasecmp(cms_protocol, "application/x-pkcs7-signature")) ++#ifndef HAVE_GMIME_2_5_7 ++ g_mime_ctx->sign_protocol = cms_protocol; ++#else /* HAVE_GMIME_2_5_7 */ + ctx->sign_protocol = cms_protocol; ++#endif /* HAVE_GMIME_2_5_7 */ + } + + /* verify the signature */ + + libbalsa_mailbox_lock_store(body->message->mailbox); + valid = g_mime_multipart_signed_verify(GMIME_MULTIPART_SIGNED +- (body->mime_part), ctx, &error); ++ (body->mime_part), g_mime_ctx, ++ &error); + libbalsa_mailbox_unlock_store(body->message->mailbox); + + if (valid == NULL) { +@@ -642,12 +681,16 @@ libbalsa_body_check_signature(LibBalsaMessageBody * body, + libbalsa_information(LIBBALSA_INFORMATION_ERROR, + _("signature verification failed")); + } +- if (GMIME_GPGME_CONTEXT(ctx)->sig_state) { +- body->parts->next->sig_info = GMIME_GPGME_CONTEXT(ctx)->sig_state; ++ if (ctx->sig_state) { ++ body->parts->next->sig_info = ctx->sig_state; + g_object_ref(G_OBJECT(body->parts->next->sig_info)); + } ++#ifndef HAVE_GMIME_2_5_7 + g_mime_signature_validity_free(valid); +- g_object_unref(ctx); ++#else /* HAVE_GMIME_2_5_7 */ ++ g_object_unref(valid); ++#endif /* HAVE_GMIME_2_5_7 */ ++ g_object_unref(g_mime_ctx); + #if !defined(HAVE_GMIME_2_6) + g_object_unref(session); + #endif /* HAVE_GMIME_2_6 */ +@@ -747,14 +790,26 @@ libbalsa_body_decrypt(LibBalsaMessageBody * body, + libbalsa_mailbox_lock_store(body->message->mailbox); + if (protocol == GPGME_PROTOCOL_OpenPGP) + mime_obj = ++#ifndef HAVE_GMIME_2_5_7 + g_mime_multipart_encrypted_decrypt(GMIME_MULTIPART_ENCRYPTED(body->mime_part), + GMIME_CIPHER_CONTEXT(ctx), + &error); ++#else /* HAVE_GMIME_2_5_7 */ ++ g_mime_multipart_encrypted_decrypt(GMIME_MULTIPART_ENCRYPTED(body->mime_part), ++ GMIME_CRYPTO_CONTEXT(ctx), ++ NULL, ++ &error); ++#endif /* HAVE_GMIME_2_5_7 */ + #ifdef HAVE_SMIME + else if (smime_signed) { ++#ifndef HAVE_GMIME_2_5_7 + GMimeSignatureValidity *valid; ++#else /* HAVE_GMIME_2_5_7 */ ++ GMimeSignatureList *valid; ++#endif /* HAVE_GMIME_2_5_7 */ + + ctx->singlepart_mode = TRUE; ++#ifndef HAVE_GMIME_2_5_7 + mime_obj = + g_mime_application_pkcs7_verify(GMIME_PART(body->mime_part), + &valid, +@@ -766,6 +821,19 @@ libbalsa_body_decrypt(LibBalsaMessageBody * body, + g_mime_application_pkcs7_decrypt(GMIME_PART(body->mime_part), + GMIME_CIPHER_CONTEXT(ctx), + &error); ++#else /* HAVE_GMIME_2_5_7 */ ++ mime_obj = ++ g_mime_application_pkcs7_verify(GMIME_PART(body->mime_part), ++ &valid, ++ GMIME_CRYPTO_CONTEXT(ctx), ++ &error); ++ g_object_unref(valid); ++ } else ++ mime_obj = ++ g_mime_application_pkcs7_decrypt(GMIME_PART(body->mime_part), ++ GMIME_CRYPTO_CONTEXT(ctx), ++ &error); ++#endif /* HAVE_GMIME_2_5_7 */ + #endif + libbalsa_mailbox_unlock_store(body->message->mailbox); + +@@ -906,7 +974,11 @@ libbalsa_rfc2440_verify(GMimePart * part, GMimeGpgmeSigstat ** sig_info) + GMimeSession *session; + #endif /* HAVE_GMIME_2_6 */ + GMimeGpgmeContext *ctx; ++#ifndef HAVE_GMIME_2_5_7 + GMimeSignatureValidity *valid; ++#else /* HAVE_GMIME_2_5_7 */ ++ GMimeSignatureList *valid; ++#endif /* HAVE_GMIME_2_5_7 */ + GError *error = NULL; + gpgme_error_t retval; + +@@ -978,7 +1050,11 @@ libbalsa_rfc2440_verify(GMimePart * part, GMimeGpgmeSigstat ** sig_info) + } + + /* clean up */ ++#ifndef HAVE_GMIME_2_5_7 + g_mime_signature_validity_free(valid); ++#else /* HAVE_GMIME_2_5_7 */ ++ g_object_unref(valid); ++#endif /* HAVE_GMIME_2_5_7 */ + retval = ctx->sig_state->status; + g_object_unref(ctx); + #if !defined(HAVE_GMIME_2_6) +-- +cgit v0.9.0.2 diff --git a/community-testing/pinot/PKGBUILD b/community-testing/pinot/PKGBUILD new file mode 100644 index 000000000..8dd7c740a --- /dev/null +++ b/community-testing/pinot/PKGBUILD @@ -0,0 +1,50 @@ +# $Id: PKGBUILD 62017 2012-01-14 12:25:05Z ibiru $ +# Maintainer: Jaroslav Lichtblau <dragonlord@aur.archlinux.org> +# Contributor: Alexander Fehr <pizzapunk gmail com> +# Contributor: William Rea <sillywilly@gmail.com> +# Contributor: Daniel J Griffiths <ghost1227@archlinux.us> + +pkgname=pinot +pkgver=0.98 +pkgrel=2 +pkgdesc='Personal search and metasearch tool' +arch=('i686' 'x86_64') +url='http://pinot.berlios.de/' +license=('GPL') +depends=('gtkmm' 'xapian-core' 'libtextcat' 'sqlite3' 'libxml++' 'curl' + 'gmime' 'dbus-glib' 'shared-mime-info' 'libexif' 'taglib' + 'hicolor-icon-theme' 'cairo' 'exiv2') +makedepends=('boost' 'desktop-file-utils') +optdepends=('unzip: ZIP files extraction' + 'poppler: PDF to text conversion' + 'catdvi: DVI to text conversion' + 'djvulibre: DjVu text extraction' + 'unrtf: RTF to HTML conversion' + 'antiword: MS Word to text conversion' + 'catdoc: XLS and PPT to text conversion' + 'deskbar-applet: Pinot Deskbar-Applet module') +options=('!emptydirs') +install=$pkgname.install +changelog=$pkgname.changelog +source=(http://download.berlios.de/$pkgname/$pkgname-$pkgver.tar.gz) +sha256sums=('8a89a73a48344074aa8f4534ce68fd18e3d84553645cef864c137ab21d8d341c') + +build() { + cd ${srcdir}/$pkgname-$pkgver + sed -i 's|/usr/share/libtextcat/|/usr/share/libtextcat/LM/|' textcat_conf.txt + sed -i -e "s|.*russian$|/usr/share/libtextcat/LM/russian-iso8859_5.lm russian-iso8859_5\n\ +/usr/share/libtextcat/LM/russian-koi8_r.lm russian-koi8_r\n\ +/usr/share/libtextcat/LM/russian-windows1251.lm russian-windows1251|" textcat_conf.txt + + ./configure --prefix=/usr --sysconfdir=/etc --libexecdir=/usr/lib + make +} + +package() { + cd ${srcdir}/$pkgname-$pkgver + + make DESTDIR=${pkgdir} install + + # Remove Deskbar-Applet handler + rm -rf ${pkgdir}/usr/lib/deskbar-applet/handlers +} diff --git a/community-testing/pinot/pinot.changelog b/community-testing/pinot/pinot.changelog new file mode 100644 index 000000000..7d899cdb0 --- /dev/null +++ b/community-testing/pinot/pinot.changelog @@ -0,0 +1,2 @@ +2011-12-18 Jaroslav Lichtblau <dragonlord@aur.archlinux.org> + * pinot 0.98-1 diff --git a/community-testing/pinot/pinot.install b/community-testing/pinot/pinot.install new file mode 100644 index 000000000..55ab40426 --- /dev/null +++ b/community-testing/pinot/pinot.install @@ -0,0 +1,15 @@ +post_install() { + gtk-update-icon-cache -q -t -f usr/share/icons/hicolor + echo "Starting with 0.63, the service is auto-started. " + echo "The file that enables this is located at " + echo "/etc/xdg/autostart/pinot-dbus-daemon.desktop" + echo "Delete this file if you don't want the auto-start." +} + +post_upgrade() { + gtk-update-icon-cache -q -t -f usr/share/icons/hicolor +} + +post_remove() { + gtk-update-icon-cache -q -t -f usr/share/icons/hicolor +} diff --git a/community/linux-tools/PKGBUILD b/community/linux-tools/PKGBUILD index 345d8f9ad..026c0aa1d 100644 --- a/community/linux-tools/PKGBUILD +++ b/community/linux-tools/PKGBUILD @@ -1,12 +1,12 @@ -# $Id: PKGBUILD 61664 2012-01-06 00:12:09Z seblu $ -# Maintainer: Sebastien Luttringer <seblu+arch@seblu.net> +# $Id: PKGBUILD 62053 2012-01-15 02:27:29Z seblu $ +# Maintainer: Sébastien Luttringer <seblu@aur.archlinux.org> pkgbase=linux-tools pkgname=('perf' 'cpupower') pkgver=3.2 -kernver=${pkgver} +kernver=${pkgver}.1 [[ ${kernver##*rc} != $kernver ]] && testing='testing' -pkgrel=1 +pkgrel=2 license=('GPL2') arch=('i686' 'x86_64') url='http://www.kernel.org' @@ -16,16 +16,18 @@ makedepends=('asciidoc' 'xmlto') makedepends+=('python2' 'libnewt' 'elfutils' 'pciutils') source=("http://ftp.kernel.org/pub/linux/kernel/v3.0/$testing/linux-$kernver.tar.xz" 'cpupower.rc' - 'cpupower.conf') -md5sums=('364066fa18767ec0ae5f4e4abcf9dc51' - 'd8b119eff7dc1a2d655eb71a47fa6215' - '218fd36a7957d3170ed8bd1a0be1f62f') + 'cpupower.conf' + 'cpupower.service') +md5sums=('cd2f8b7752c85c337af809391f4afb94' + '26af384ca282bc0dc38ff65acc7bb4b9' + '857ccdd0598511e3bf4b63522754dc48' + '20870541e88109d2f153be3c58a277f1') build() { msg2 'Build perf' cd linux-$kernver/tools/perf - make PYTHON=python2 DESTDIR="${pkgdir}/usr" perfexecdir="lib/$pkgname" PERF_VERSION=$pkgver-$pkgrel \ - all man + make PYTHON=python2 DESTDIR="${pkgdir}/usr" perfexecdir="lib/$pkgname" \ + PERF_VERSION=$pkgver-$pkgrel all man msg2 'Build cpupower' # we cannot use --as-needed @@ -39,8 +41,8 @@ package_perf() { depends=('python2' 'libnewt' 'elfutils') cd linux-${kernver}/tools/perf - make PYTHON=python2 DESTDIR="${pkgdir}/usr" perfexecdir="lib/$pkgname" PERF_VERSION=$pkgver \ - install install-man + make PYTHON=python2 DESTDIR="${pkgdir}/usr" perfexecdir="lib/$pkgname" \ + PERF_VERSION=$pkgver install install-man } package_cpupower() { @@ -52,6 +54,7 @@ package_cpupower() { # install rc.d script install -D -m 755 cpupower.rc "$pkgdir/etc/rc.d/cpupower" install -D -m 644 cpupower.conf "$pkgdir/etc/conf.d/cpupower" + install -D -m 644 cpupower.service "$pkgdir/lib/systemd/system/cpupower.service" cd linux-$kernver/tools/power/cpupower make \ diff --git a/community/linux-tools/cpupower.conf b/community/linux-tools/cpupower.conf index 0f56836b1..ee8602953 100644 --- a/community/linux-tools/cpupower.conf +++ b/community/linux-tools/cpupower.conf @@ -1,14 +1,28 @@ -# valid governors: -# ondemand, performance, powersave, -# conservative, userspace -#governor="ondemand" +# Define CPUs governor +# valid governors: ondemand, performance, powersave, conservative, userspace. +#governor='ondemand' -# limit frequency range (optional) -# valid suffixes: Hz, kHz (default), MHz, GHz, THz +# Limit frequency range +# Valid suffixes: Hz, kHz (default), MHz, GHz, THz #min_freq="2.25GHz" #max_freq="3GHz" -# use freq to set up the exact cpu frequency using it with userspace governor +# Specific frequency to be set. +# Requires userspace governor to be available and loaded. #freq= +# Utilizes cores in one processor package/socket first before processes are +# scheduled to other processor packages/sockets. +# See man (1) CPUPOWER-SET for additional details. +#mc_scheduler= + +# Utilizes thread siblings of one processor core first before processes are +# scheduled to other cores. See man (1) CPUPOWER-SET for additional details. +#smp_scheduler= + +# Sets a register on supported Intel processore which allows software to convey +# its policy for the relative importance of performance versus energy savings to +# the processor. See man (1) CPUPOWER-SET for additional details. +#perf_bias= + # vim:set ts=2 sw=2 ft=sh et: diff --git a/community/linux-tools/cpupower.rc b/community/linux-tools/cpupower.rc index 812637b61..9b0bcddb7 100644 --- a/community/linux-tools/cpupower.rc +++ b/community/linux-tools/cpupower.rc @@ -8,19 +8,29 @@ case "$1" in start|restart) stat_busy "Setting cpupower rules" + declare -i fail=0 - declare params='' - if [[ "$governor" ]]; then - params="-g $governor " - params+="${min_freq:+-d $min_freq} " - params+="${max_freq:+-u $max_freq} " - params+="${freq:+-f $freq} " - cpupower frequency-set $params >/dev/null || { stat_fail; exit 1; } - stat_done - else - stat_append ': Invalid configuration' - stat_fail + # frequency-set options + declare -a params=() + params+=(${governor:+-g $governor}) + params+=(${min_freq:+-d $min_freq}) + params+=(${max_freq:+-u $max_freq}) + params+=(${freq:+-f $freq}) + if ((${#params[@]} > 0)); then + cpupower frequency-set "${params[@]}" >/dev/null || fail=1 fi + + # set options + declare -a params=() + params+=(${mc_scheduler:+-m $mc_scheduler}) + params+=(${smp_scheduler:+-s $smp_scheduler}) + params+=(${perf_bias:+-b $perf_bias}) + if ((${#params[@]} > 0)); then + cpupower set "${params[@]}" >/dev/null || fail=1 + fi + + # print failure if any + (($fail > 0)) && stat_fail && exit 1 || stat_done ;; *) echo "usage: $0 {start|restart}" diff --git a/community/linux-tools/cpupower.service b/community/linux-tools/cpupower.service new file mode 100644 index 000000000..f77cfdc97 --- /dev/null +++ b/community/linux-tools/cpupower.service @@ -0,0 +1,10 @@ +[Unit] +Description=Apply cpupower configuration + +[Service] +Type=oneshot +ExecStart=/etc/rc.d/cpupower start +RemainAfterExit=yes + +[Install] +WantedBy=multi-user.target diff --git a/community/percona-server/PKGBUILD b/community/percona-server/PKGBUILD index 4a03ded15..3eea37da6 100644 --- a/community/percona-server/PKGBUILD +++ b/community/percona-server/PKGBUILD @@ -1,7 +1,7 @@ # Maintainer: Massimiliano Torromeo <massimiliano.torromeo@gmail.com> pkgname=percona-server -pkgver=5.5.18_rel23.0 +pkgver=5.5.19_rel24.0 pkgrel=1 pkgdesc="A backwards-compatible drop-in replacement for MySQL that provides improved performance, diagnostics and instrumentation, and manageability of the server" arch=('i686' 'x86_64') @@ -17,7 +17,7 @@ url="http://www.percona.com/software/percona-server/" options=('!libtool' 'emptydirs') backup=('etc/mysql/my.cnf') install=percona.install -source=("http://www.percona.com/redir/downloads/Percona-Server-${pkgver%.*_*}/Percona-Server-${pkgver/_rel/-}/Percona-Server-${pkgver/_/-}.tar.gz" +source=("http://www.percona.com/downloads/Percona-Server-${pkgver%.*_*}/Percona-Server-${pkgver/_rel/-}/source/Percona-Server-${pkgver/_/-}.tar.gz" 'mysqld' 'my.cnf') @@ -98,6 +98,6 @@ package() { install -dm700 "${pkgdir}"/var/lib/mysql } -md5sums=('17b266f5c10d01838522188f313a1ead' +md5sums=('eb8c21bbb8179e0a4709d51c037e682c' '243864805611764a7e5883c1dba7afd8' '1c949c0dbea5206af0db14942d9927b6') diff --git a/community/redis/PKGBUILD b/community/redis/PKGBUILD index 44788d319..1d6f2f102 100644 --- a/community/redis/PKGBUILD +++ b/community/redis/PKGBUILD @@ -1,10 +1,10 @@ -# $Id: PKGBUILD 61232 2011-12-25 17:05:47Z spupykin $ +# $Id: PKGBUILD 62009 2012-01-14 09:42:42Z spupykin $ # Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com> # Maintainer: Jan-Erik Rediger <badboy at archlinux dot us> # Contributor: nofxx <x@<nick>.com> pkgname=redis -pkgver=2.4.5 +pkgver=2.4.6 pkgrel=1 pkgdesc="Advanced key-value store" arch=('i686' 'x86_64') @@ -18,7 +18,7 @@ backup=("etc/redis.conf" source=("http://redis.googlecode.com/files/${pkgname}-${pkgver}.tar.gz" "redis.d" "redis.logrotate") -md5sums=('babeb1a1d05281b5e00ca0a519cfc3f9' +md5sums=('41d394074bcde762872ecb5506f35aee' '9726d06d0a0c60cb5d55a31b3dc1e55d' '9e2d75b7a9dc421122d673fe520ef17f') diff --git a/extra/gjs/PKGBUILD b/extra/gjs/PKGBUILD index 37ba73ba9..b7dc6877c 100644 --- a/extra/gjs/PKGBUILD +++ b/extra/gjs/PKGBUILD @@ -1,7 +1,8 @@ -# $Id: PKGBUILD 139275 2011-10-01 18:57:14Z ibiru $ +# $Id: PKGBUILD 146616 2012-01-14 12:13:58Z ibiru $ # Maintainer: Ionut Biru <ibiru@archlinux.org> + pkgname=gjs -pkgver=1.30.0 +pkgver=1.30.1 pkgrel=1 pkgdesc="Javascript Bindings for GNOME" arch=('i686' 'x86_64') @@ -9,17 +10,17 @@ url="http://live.gnome.org/Gjs" license=('GPL') depends=('cairo' 'dbus-glib' 'gobject-introspection' 'js') options=('!libtool') -source=(http://download.gnome.org/sources/${pkgname}/1.30/${pkgname}-${pkgver}.tar.xz) -sha256sums=('ffe01980dd183abd96b2cc861d2e86ef12751d0a1af86daa4c491b82c74ac7b9') +source=(http://download.gnome.org/sources/$pkgname/${pkgver%.*}/$pkgname-$pkgver.tar.xz) +sha256sums=('f5db07ddf70458a33a5d0bdf83f84070fc234237ecb0d49a8676e67b52119a05') build() { - cd "${srcdir}/${pkgname}-${pkgver}" + cd "$srcdir/$pkgname-$pkgver" sed -i 's|python|python2|' scripts/make-tests ./configure --prefix=/usr --disable-static make } package() { - cd "${srcdir}/${pkgname}-${pkgver}" - make DESTDIR="${pkgdir}" install + cd "$srcdir/$pkgname-$pkgver" + make DESTDIR="$pkgdir" install } diff --git a/extra/libreoffice/PKGBUILD b/extra/libreoffice/PKGBUILD index 125c5eb13..53a37e5c8 100644 --- a/extra/libreoffice/PKGBUILD +++ b/extra/libreoffice/PKGBUILD @@ -1,4 +1,4 @@ -# $Id: PKGBUILD 146473 2012-01-11 15:22:18Z stephane $ +# $Id: PKGBUILD 146608 2012-01-14 08:15:18Z andyrtr $ # Maintainer: AndyRTR <andyrtr@archlinux.org> pkgbase="libreoffice" @@ -35,9 +35,9 @@ pkgname=('libreoffice-common' 'libreoffice-extension-validator' 'libreoffice-extension-watch-window' 'libreoffice-extension-wiki-publisher') -_LOver=3.4.4.2 -pkgver=3.4.4 -pkgrel=5 +_LOver=3.4.5.2 +pkgver=3.4.5 +pkgrel=1 arch=('i686' 'x86_64') #_LO_tree="3.4" _OFFICEUPD="340" @@ -61,8 +61,11 @@ makedepends=( # makedepends _mirror="http://download.documentfoundation.org/libreoffice/src/${pkgver}" #_mirror="http://dev-builds.libreoffice.org/pre-releases/src" +#_mirror="http://dev-builds.libreoffice.org/pre-releases-3-4/src" _additional_source_url="http://hg.services.openoffice.org/binaries" +_additional_source_url="http://dev-www.libreoffice.org/src" source=(${_mirror}/${pkgbase}-{artwork,base,bootstrap,calc,components,extensions,extras,filters,help,impress,libs-core,libs-extern,libs-extern-sys,libs-gui,postprocess,sdk,testing,ure,writer}-${_LOver}.tar.bz2 #,translations + ${_additional_source_url}/f02578f5218f217a9f20e9c30e119c6a-boost_1_44_0.tar.bz2 ${_additional_source_url}/1f24ab1d39f4a51faf22244c94a6203f-xmlsec1-1.2.14.tar.gz ${_additional_source_url}/35c94d2df8893241173de1d16b6034c0-swingExSrc.zip ${_additional_source_url}/798b2ffdc8bcfe7bca2cf92b62caf685-rhino1_5R5.zip @@ -102,11 +105,9 @@ source=(${_mirror}/${pkgbase}-{artwork,base,bootstrap,calc,components,extensions buildfix_boost.diff buildfix_ct2n.diff vbahelper.visibility.patch - scp2-more-reasonable-file-access-rights.diff - oracle-recognition.diff::http://cgit.freedesktop.org/libreoffice/core/patch/?id=549e54fb2f8113502743c443d6deadfe648dede1 - RemovetheoslSecuritygetHomeDircheck.diff::http://cgit.freedesktop.org/libreoffice/ure/patch/?id=bc9b86940a707e9e2e1076f2954f38075398b5d7 - gcc462_buildfix.diff) + scp2-more-reasonable-file-access-rights.diff) noextract=(185d60944ea767075d27247c3162b3bc-unowinreg.dll + f02578f5218f217a9f20e9c30e119c6a-boost_1_44_0.tar.bz2 0ff7d225d087793c8c2c680d77aac3e7-mdds_0.5.3.tar.bz2 ada24d37d8d638b3d8a9985e80bc2978-source-9.0.0.7-bj.zip 798b2ffdc8bcfe7bca2cf92b62caf685-rhino1_5R5.zip @@ -142,25 +143,26 @@ noextract=(185d60944ea767075d27247c3162b3bc-unowinreg.dll dbaafd21de055e582d92d7d32fe9da13-gdocs_2.3.1.oxt b7b2d0e04e142f26dd96119c80757d1f-oooblogger_0.1.oxt 90401bca927835b6fbae4a707ed187c8-nlpsolver-0.9.tar.bz2) -md5sums=('be8b13f83045f0a53b69fe76d6d72e9c' - 'db423cbb1cee416b718138044a5de930' - '31944d2139d6d81ef1131bd513530621' - 'f447fd4ffe54aab9561c6caa262754b3' - '97fe698737a35c8803712d4e08007620' - 'acff44d97a5106d9b53c747dabeb0800' - '620d43a0b9f36388f423e030513864ef' - '4c5b1ed870363eca2602f0cb42a8415a' - '702c6ca31525d7d2c2ded86c77b0bd2e' - 'ac9b3acf78f43c1395d0e2dedc860f30' - 'd8d2c41cb86bc8ba2a07e001a5317abb' - '4d4af2fc06dbe33ec2307df812f7abe1' - '1398a566eb76598bf3005e187fc2386c' - 'dd962d2d57f88b9e07e665adad3cabbc' - 'fff0fc9cd16ef1eb2b2ed5d0a6e77f95' - 'e54d41d39e63d04ac4a88ce79e37af98' - 'dbc71403040f447683bf55d1f0be3cad' - '69ce5b72f44b008d0e78767c5b1dbf39' - '34a2e8ae6b81a042966740263c53e135' +md5sums=('a75d7d4ebefb4c9a4bb256acf866fa81' + 'c1e2dabdf4cfcd5957779014a7f9787e' + '79c9c7fc208e7f56af09f284f261a7da' + 'c83a8a374d3d5cc83c6ac3b5ff613e46' + 'fa64799ebad8cbd2c160ac2f87bd5599' + 'b24fba57aa4185934e86a0a8db4a3433' + '4f98020088ab9b597fc21b617121bd47' + '3c3be7c5f923339c90b0d1d6ecad0243' + '3a0bb4bb096b7488533ed2ee466a2bc9' + 'f2b180aa1eff3884b4ca81c048f1e327' + 'a9af488ef92ad4442eafba874249c529' + 'db6a67c96a9090bc5e21b64e202a984e' + 'e00187ae0840e1f6a00fa3290cacf0d1' + '20fbf6cffd2b06e90a52105b75a57828' + '4af055f590732ec19a2534b2278ac49c' + 'c84693796d2b1d9c8269425b1fa53aef' + 'd4926dc27b6884656feec6753f4fdf22' + '770678ca19cca0f7985c1c82b2dccf48' + '97a1e3de430b124faf35bf334248ad53' + 'f02578f5218f217a9f20e9c30e119c6a' '1f24ab1d39f4a51faf22244c94a6203f' '35c94d2df8893241173de1d16b6034c0' '798b2ffdc8bcfe7bca2cf92b62caf685' @@ -200,10 +202,7 @@ md5sums=('be8b13f83045f0a53b69fe76d6d72e9c' 'bc228237108cab7745897a9f466b6d39' 'eee273f501ff45dc5f1365e78c6d57c0' '43b145db28e6c0d73578ae6fd35e510d' - '37638431e7e40baf2e47966ebb9bc0e9' - '3c6c62e77c30649a3dfe73512947cc9a' - 'eb35d4c715e0dfc23bbc706996033829' - '10600d04ee81014bc9b5cc04e615d799') + '37638431e7e40baf2e47966ebb9bc0e9') build() { @@ -233,10 +232,6 @@ build() { patch -Np1 -i ${srcdir}/buildfix_ct2n.diff patch -Np0 -i ${srcdir}/vbahelper.visibility.patch patch -Np0 -i ${srcdir}/scp2-more-reasonable-file-access-rights.diff - patch -Np1 -i ${srcdir}/oracle-recognition.diff - patch -Np1 -i ${srcdir}/RemovetheoslSecuritygetHomeDircheck.diff - # https://www.libreoffice.org/bugzilla/show_bug.cgi?id=43139 - patch -Np1 -i ${srcdir}/gcc462_buildfix.diff # unset C(XX)FLAGS # http://www.openoffice.org/issues/show_bug.cgi?id=103205 @@ -290,7 +285,6 @@ build() { --enable-lockdown\ --enable-opengl \ --enable-odk\ - --enable-opengl\ --enable-ext-barcode \ --enable-ext-diagram \ --enable-ext-google-docs \ @@ -333,7 +327,7 @@ build() { --with-external-libtextcat-data \ --with-openldap\ --with-ant-home="/usr/share/java/apache-ant"\ - --with-system-boost\ + --without-system-boost\ --with-system-cairo\ --with-system-libs\ --with-system-mozilla\ diff --git a/extra/qtwebkit/PKGBUILD b/extra/qtwebkit/PKGBUILD index 84a006909..c0c13dd98 100644 --- a/extra/qtwebkit/PKGBUILD +++ b/extra/qtwebkit/PKGBUILD @@ -1,9 +1,9 @@ -# $Id: PKGBUILD 145469 2011-12-22 22:02:51Z andrea $ +# $Id: PKGBUILD 146627 2012-01-14 15:25:15Z andrea $ # Maintainer: Andrea Scarpino <andrea@archlinux.org> pkgname=qtwebkit pkgver=2.2.1 -pkgrel=1 +pkgrel=2 arch=('i686' 'x86_64') url='http://trac.webkit.org/wiki/QtWebKit' pkgdesc='An open source web browser engine (Qt port)' @@ -13,8 +13,10 @@ makedepends=('python2' 'mesa' 'chrpath') conflicts=('qt<4.8') #source=("http://get.qt.nokia.com/${pkgname}/QtWebKit-${pkgver}.tar.gz" source=("ftp://ftp.archlinux.org/other/${pkgname}/QtWebKit-${pkgver}.tar.gz" + "ftp://ftp.archlinux.org/other/${pkgname}/qwebview-4.8.0.tar.bz2" 'python2-path.patch') sha1sums=('283fc116882157df0474af496be73bb9b34cb001' + '0e44b27a0f71aceb91a89a2c28ab6331126518d9' 'b0ef3d5596171e3900a685df9bcfac3068ad6330') build() { @@ -28,6 +30,11 @@ build() { --makeargs="${MAKEFLAGS}" \ --release \ --3d-canvas + + # Build the QWebView plugin (FS#27914) + cd "${srcdir}"/QtWebKit-${pkgver}/qwebview-4.8.0/plugins/qwebview + qmake + make } package() { @@ -36,4 +43,7 @@ package() { # Fix RPATH chrpath -r /usr/lib/ "${pkgdir}"/usr/lib/qt/imports/QtWebKit/libqmlwebkitplugin.so + + cd "${srcdir}"/QtWebKit-${pkgver}/qwebview-4.8.0/plugins/qwebview + make INSTALL_ROOT="${pkgdir}" install } diff --git a/extra/ristretto/PKGBUILD b/extra/ristretto/PKGBUILD index 7bd21048b..3c45bbd56 100644 --- a/extra/ristretto/PKGBUILD +++ b/extra/ristretto/PKGBUILD @@ -1,10 +1,10 @@ -# $Id: PKGBUILD 144969 2011-12-12 17:23:28Z andrea $ +# $Id: PKGBUILD 146610 2012-01-14 08:51:04Z eric $ # Maintainer: # Contributor: AndyRTR <andyrtr@archlinux.org> # Contributor: Ronald van Haren <ronald.archlinux.org> pkgname=ristretto -pkgver=0.3.0 +pkgver=0.3.1 pkgrel=1 pkgdesc="A fast and lightweight picture-viewer for Xfce" arch=('i686' 'x86_64') @@ -15,7 +15,7 @@ makedepends=('intltool') groups=('xfce4-goodies') install=ristretto.install source=("http://archive.xfce.org/src/apps/$pkgname/${pkgver%.*}/$pkgname-$pkgver.tar.bz2") -sha1sums=('c7034ad543bea3c1b99a2336dcee9d5ba480b2bb') +sha1sums=('1a0c4a5f0edf6594d14c7e24fb41a6127c4c1774') build() { cd "${srcdir}/$pkgname-$pkgver" diff --git a/multilib-staging/binutils-multilib/PKGBUILD b/multilib-staging/binutils-multilib/PKGBUILD new file mode 100644 index 000000000..4b8a09454 --- /dev/null +++ b/multilib-staging/binutils-multilib/PKGBUILD @@ -0,0 +1,79 @@ +# $Id: PKGBUILD 62031 2012-01-14 21:44:56Z heftig $ +# Maintainer: Jan "heftig" Steffens <jan.steffens@gmail.com> +# Contributor: Allan McRae <allan@archlinux.org> + +# toolchain build order: linux-api-headers->glibc->binutils->gcc->binutils->glibc + +pkgname=binutils-multilib +pkgver=2.22 +pkgrel=4.1 +_date=20111227 +pkgdesc="A set of programs to assemble and manipulate binary and object files for multilib" +arch=('x86_64') +url="http://www.gnu.org/software/binutils/" +license=('GPL') +groups=('multilib-devel') +provides=("binutils=$pkgver-$pkgrel") +conflicts=('binutils') +depends=('glibc>=2.14' 'zlib') +makedepends=('dejagnu' 'gcc-multilib') # Make sure we compile this with gcc-multilib +options=('!libtool' '!distcc' '!ccache') +install=binutils.install +source=(http://mirrors.kernel.org/archlinux/other/binutils/binutils-${pkgver}_${_date}.tar.bz2) +md5sums=('c2377089c15bb1a1bfaeca8d0e59dd4d') + +build() { + cd ${srcdir} + mkdir binutils-build && cd binutils-build + + ${srcdir}/binutils/configure --prefix=/usr \ + --enable-ld=default --enable-gold \ + --enable-plugins --enable-threads \ + --enable-shared \ + --enable-64-bit-bfd --enable-multilib + + # check the host environment and makes sure all the necessary tools are available + make configure-host + + make tooldir=${pkgdir}/usr + + # Rebuild libiberty.a with -fPIC + cp -a libiberty libiberty-pic + make -C libiberty-pic clean + make CFLAGS="$CFLAGS -fPIC" -C libiberty-pic + + # Rebuild libbfd.a with -fPIC + # hidden visability prevent 3rd party shared libraries exporting bfd non-stable API + cp -a bfd bfd-pic + make -C bfd-pic clean + make CFLAGS="$CFLAGS -fPIC -fvisibility=hidden" -C bfd-pic +} + +check() { + cd ${srcdir}/binutils-build + + # do not abort on errors - manually check log files + make -k -j1 check || true +} + +package() { + cd ${srcdir}/binutils-build + make prefix=${pkgdir}/usr tooldir=${pkgdir}/usr install + + # Add some useful headers + install -m644 ${srcdir}/binutils/include/libiberty.h ${pkgdir}/usr/include + install -m644 ${srcdir}/binutils/include/demangle.h ${pkgdir}/usr/include + + # install libraries rebuilt with -fPIC + install -m644 libiberty-pic/libiberty.a ${pkgdir}/usr/lib + install -m644 bfd-pic/libbfd.a ${pkgdir}/usr/lib + + # Remove Windows/Novell specific man pages + rm -f ${pkgdir}/usr/share/man/man1/{dlltool,nlmconv,windres,windmc}* + + # Remove these symlinks, they are not ABI stable. + # Programs should compile static to the .a file. + rm -f ${pkgdir}/usr/lib/lib{bfd,opcodes}.so + echo "INPUT ( /usr/lib/libbfd.a -liberty -lz )" >${pkgdir}/usr/lib/libbfd.so + echo "INPUT ( /usr/lib/libopcodes.a -lbfd )" >${pkgdir}/usr/lib/libopcodes.so +} diff --git a/multilib-staging/binutils-multilib/binutils.install b/multilib-staging/binutils-multilib/binutils.install new file mode 100644 index 000000000..8bf9f3a47 --- /dev/null +++ b/multilib-staging/binutils-multilib/binutils.install @@ -0,0 +1,17 @@ +infodir=usr/share/info +filelist=(as.info bfd.info binutils.info configure.info gprof.info ld.info standards.info) + +post_upgrade() { + [ -x usr/bin/install-info ] || return 0 + for file in ${filelist[@]}; do + install-info $infodir/$file.gz $infodir/dir 2> /dev/null + done +} + +pre_remove() { + [ -x usr/bin/install-info ] || return 0 + for file in ${filelist[@]}; do + install-info --delete $infodir/$file.gz $infodir/dir 2> /dev/null + done +} + diff --git a/multilib-staging/chuck/PKGBUILD b/multilib-staging/chuck/PKGBUILD new file mode 100644 index 000000000..333d7f73d --- /dev/null +++ b/multilib-staging/chuck/PKGBUILD @@ -0,0 +1,41 @@ +# $Id: PKGBUILD 62037 2012-01-14 23:38:40Z heftig $ +# Maintainer: Brad Fanella <bradfanella@archlinux.us> +# Contributor: SpepS <dreamspepser at yahoo dot it> +# Contributor: Jeff Mickey <jeff@archlinux.org> +# Contributor: tardo <tardo@nagi-fanboi.net> + +pkgname=chuck +pkgver=1.2.1.3 +pkgrel=5.1 +pkgdesc="Concurrent, on-the-fly audio programming language." +arch=('i686' 'x86_64') +url="http://chuck.cs.princeton.edu/" +license=('GPL') +depends=('gcc-libs' 'libsndfile' 'alsa-lib') +makedepends=('bison' 'flex') +source=(http://chuck.cs.princeton.edu/release/files/$pkgname-$pkgver.tgz) +md5sums=('ac8459b4067c2491fbdeb61d122a5985') + +if [[ $CARCH == x86_64 ]]; then + depends=('lib32-gcc-libs' 'lib32-libsndfile' 'lib32-alsa-lib') + makedepends+=('gcc-multilib') +fi + +build() { + if [[ $CARCH == x86_64 ]]; then + export CC='gcc -m32' + export CXX='g++ -m32' + export PKG_CONFIG_PATH=/usr/lib32/pkgconfig + fi + + cd $srcdir/$pkgname-$pkgver/src + CFLAGS="$CFLAGS -fno-strict-aliasing" + + # This can be linux-alsa linux-jack linux-oss osx win32 + make linux-alsa +} + +package() { + cd $srcdir/$pkgname-$pkgver/src + install -D -m 755 chuck $pkgdir/usr/bin/chuck +} diff --git a/multilib-staging/gcc-multilib/PKGBUILD b/multilib-staging/gcc-multilib/PKGBUILD new file mode 100644 index 000000000..7fed692d9 --- /dev/null +++ b/multilib-staging/gcc-multilib/PKGBUILD @@ -0,0 +1,303 @@ +# $Id: PKGBUILD 62033 2012-01-14 22:04:04Z heftig $ +# Maintainer: Jan "heftig" Steffens <jan.steffens@gmail.com> +# Contributor: Allan McRae <allan@archlinux.org> + +# toolchain build order: linux-api-headers->glibc->binutils->gcc->binutils->glibc +# NOTE: libtool requires rebuilt with each new gcc version + +pkgbase='gcc-multilib' +pkgname=('gcc-multilib' 'gcc-libs-multilib' 'lib32-gcc-libs' 'gcc-fortran-multilib' 'gcc-objc-multilib' 'gcc-ada-multilib' 'gcc-go-multilib') +pkgver=4.6.2 +pkgrel=5.1 +_snapshot=4.6-20111223 +_libstdcppmanver=20111215 +pkgdesc="The GNU Compiler Collection for multilib" +arch=('x86_64') +license=('GPL' 'LGPL' 'FDL' 'custom') +url="http://gcc.gnu.org" +makedepends=('binutils-multilib>=2.22' 'libmpc' 'cloog' 'ppl' 'gcc-ada-multilib' + 'lib32-glibc>=2.14') +checkdepends=('dejagnu') +options=('!libtool' '!emptydirs') +source=(#ftp://gcc.gnu.org/pub/gcc/releases/gcc-${pkgver}/gcc-${pkgver}.tar.bz2 + ftp://gcc.gnu.org/pub/gcc/snapshots/${_snapshot}/gcc-${_snapshot}.tar.bz2 + ftp://gcc.gnu.org/pub/gcc/libstdc++/doxygen/libstdc++-man.${_libstdcppmanver}.tar.bz2 + gcc_pure64-multilib.patch + gcc-hash-style-both.patch) +md5sums=('4755b9f6ac0abecbaa2097ed9738406a' + '450772ce32daed97d7383199f8797f33' + '7da5b7ab75b3c29993f953b18bc38579' + '4df25b623799b148a0703eaeec8fdf3f') + +if [ -n "${_snapshot}" ]; then + _basedir="${srcdir}/gcc-${_snapshot}" +else + _basedir="${srcdir}/gcc-${pkgver}" +fi + +build() { + cd ${_basedir} + + # Do not install libiberty + sed -i 's/install_to_$(INSTALL_DEST) //' libiberty/Makefile.in + + # Do not run fixincludes + sed -i 's@\./fixinc\.sh@-c true@' gcc/Makefile.in + + patch -Np1 -i ${srcdir}/gcc_pure64-multilib.patch + patch -Np0 -i ${srcdir}/gcc-hash-style-both.patch + + echo ${pkgver} > gcc/BASE-VER + + cd ${srcdir} + mkdir gcc-build && cd gcc-build + + ${_basedir}/configure --prefix=/usr \ + --libdir=/usr/lib --libexecdir=/usr/lib \ + --mandir=/usr/share/man --infodir=/usr/share/info \ + --with-bugurl=https://bugs.archlinux.org/ \ + --enable-languages=c,c++,ada,fortran,go,lto,objc,obj-c++ \ + --enable-shared --enable-threads=posix \ + --with-system-zlib --enable-__cxa_atexit \ + --disable-libunwind-exceptions --enable-clocale=gnu \ + --enable-gnu-unique-object --enable-linker-build-id \ + --with-ppl --enable-cloog-backend=isl \ + --enable-lto --enable-gold --enable-ld=default \ + --enable-plugin --with-plugin-ld=ld.gold \ + --enable-multilib --disable-libssp --disable-libstdcxx-pch \ + --enable-checking=release --with-fpmath=sse + make +} + +check() { + cd gcc-build + + # increase stack size to prevent test failures + # http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31827 + ulimit -s 32768 + + # do not abort on error as some are "expected" + make -k check || true + ${_basedir}/contrib/test_summary +} + +package_gcc-libs-multilib() +{ + pkgdesc="Runtime libraries shipped by GCC for multilib" + depends=('glibc>=2.14' "lib32-gcc-libs=$pkgver-$pkgrel") + provides=("gcc-libs=$pkgver-$pkgrel") + conflicts=('gcc-libs') + install=gcc-libs.install + + cd gcc-build + make -j1 -C $CHOST/libgcc DESTDIR=${pkgdir} install-shared + for lib in libmudflap libgomp libstdc++-v3/src; do + make -j1 -C $CHOST/$lib DESTDIR=${pkgdir} install-toolexeclibLTLIBRARIES + done + make -j1 -C $CHOST/libstdc++-v3/po DESTDIR=${pkgdir} install + make -j1 -C $CHOST/libgomp DESTDIR=${pkgdir} install-info + + make -j1 DESTDIR=${pkgdir} install-target-libquadmath + make -j1 DESTDIR=${pkgdir} install-target-libgfortran + make -j1 DESTDIR=${pkgdir} install-target-libobjc + + # remove unnecessary files installed by install-target-{libquadmath,libgfortran,libobjc} + rm -rf ${pkgdir}/usr/lib/{gcc/,libgfortran.spec} + + # remove stuff in lib32-gcc-libs + rm -rf ${pkgdir}/usr/lib32 + + # remove static libraries + find ${pkgdir} -name *.a -delete + + # Install Runtime Library Exception + install -Dm644 ${_basedir}/COPYING.RUNTIME \ + ${pkgdir}/usr/share/licenses/gcc-libs-multilib/RUNTIME.LIBRARY.EXCEPTION +} + +package_lib32-gcc-libs() +{ + pkgdesc="Runtime libraries shipped by GCC (32-bit)" + depends=('lib32-glibc>=2.14' "gcc-libs>=$pkgver") + + cd gcc-build + make -j1 -C $CHOST/32/libgcc DESTDIR=${pkgdir} install-shared + for lib in libmudflap libgomp libstdc++-v3/src; do + make -j1 -C $CHOST/32/$lib DESTDIR=${pkgdir} install-toolexeclibLTLIBRARIES + done + + make -j1 DESTDIR=${pkgdir} install-target-libquadmath + make -j1 DESTDIR=${pkgdir} install-target-libgfortran + make -j1 DESTDIR=${pkgdir} install-target-libobjc + + # remove unnecessary files installed by install-target-{libquadmath,libgfortran,libobjc} + rm ${pkgdir}/usr/lib32/libgfortran.spec + + # remove stuff in gcc-libs-multilib + rm -rf ${pkgdir}/usr/lib + rm -rf ${pkgdir}/usr/share/info + + # remove static libraries + find ${pkgdir} -name *.a -delete + + # Install Runtime Library Exception + install -Dm644 ${_basedir}/COPYING.RUNTIME \ + ${pkgdir}/usr/share/licenses/lib32-gcc-libs/RUNTIME.LIBRARY.EXCEPTION +} + +package_gcc-multilib() +{ + pkgdesc="The GNU Compiler Collection - C and C++ frontends for multilib" + depends=("gcc-libs-multilib=$pkgver-$pkgrel" 'binutils-multilib>=2.22' 'libmpc' 'cloog' 'ppl') + groups=('multilib-devel') + provides=("gcc=$pkgver-$pkgrel") + conflicts=('gcc') + install=gcc.install + + cd gcc-build + + # unfortunately it is much, much easier to install the lot and clean-up the mess... + make -j1 DESTDIR=${pkgdir} install + rm $pkgdir/usr/bin/{{$CHOST-,}gfortran,{$CHOST-,}gccgo,gnat*} + rm $pkgdir/usr/lib{,32}/*.so* + rm $pkgdir/usr/lib{,32}/lib{ffi,gfortran,go{,begin},objc,quadmath}.a + rm $pkgdir/usr/lib{,32}/libgfortran.spec + rm -r $pkgdir/usr/lib/gcc/$CHOST/${pkgver}/{{,32/}ada{include,lib},finclude,include/objc} + rm $pkgdir/usr/lib/gcc/$CHOST/${pkgver}/include/{ffi{,target}.h,quadmath{,_weak}.h} + rm $pkgdir/usr/lib/gcc/$CHOST/${pkgver}/{cc1obj{,plus},f951,gnat1,go1,{,32/}libgfortranbegin.a} + rm -r $pkgdir/usr/lib{,32}/go + rm $pkgdir/usr/share/info/{gccgo,gfortran,gnat*,libgomp,libquadmath}.info + rm $pkgdir/usr/share/locale/{de,fr}/LC_MESSAGES/libstdc++.mo + rm $pkgdir/usr/share/man/man1/{gccgo,gfortran}.1 + rm $pkgdir/usr/share/man/man3/ffi* + + # many packages require these symlinks + install -dm755 ${pkgdir}/lib + ln -sf /usr/bin/cpp ${pkgdir}/lib/cpp + ln -sf gcc ${pkgdir}/usr/bin/cc + ln -sf g++ ${pkgdir}/usr/bin/c++ + + # install gengtype for plugin support + install -m755 gcc/build/gengtype $pkgdir/usr/lib/gcc/$CHOST/${pkgver}/ + install -m644 gcc/gtype.state $pkgdir/usr/lib/gcc/$CHOST/${pkgver}/ + + # POSIX conformance launcher scripts for c89 and c99 + cat > $pkgdir/usr/bin/c89 <<"EOF" +#!/bin/sh +fl="-std=c89" +for opt; do + case "$opt" in + -ansi|-std=c89|-std=iso9899:1990) fl="";; + -std=*) echo "`basename $0` called with non ANSI/ISO C option $opt" >&2 + exit 1;; + esac +done +exec gcc $fl ${1+"$@"} +EOF + + cat > $pkgdir/usr/bin/c99 <<"EOF" +#!/bin/sh +fl="-std=c99" +for opt; do + case "$opt" in + -std=c99|-std=iso9899:1999) fl="";; + -std=*) echo "`basename $0` called with non ISO C99 option $opt" >&2 + exit 1;; + esac +done +exec gcc $fl ${1+"$@"} +EOF + + chmod 755 $pkgdir/usr/bin/c{8,9}9 + + # install the libstdc++ man pages + install -dm755 ${pkgdir}/usr/share/man/man3 + install -m644 ${srcdir}/man3/* ${pkgdir}/usr/share/man/man3/ + + # Install Runtime Library Exception + install -Dm644 ${_basedir}/COPYING.RUNTIME \ + ${pkgdir}/usr/share/licenses/gcc-multilib/RUNTIME.LIBRARY.EXCEPTION +} + +package_gcc-fortran-multilib() +{ + pkgdesc="Fortran front-end for GCC for multilib" + depends=("gcc-multilib=$pkgver-$pkgrel") + provides=("gcc-fortran=$pkgver-$pkgrel") + conflicts=('gcc-fortran') + install=gcc-fortran.install + + cd gcc-build + make -j1 DESTDIR=${pkgdir} install-target-libquadmath + make -j1 DESTDIR=$pkgdir install-target-libgfortran + make -j1 -C $CHOST/libgomp DESTDIR=$pkgdir install-nodist_fincludeHEADERS + make -j1 -C gcc DESTDIR=$pkgdir fortran.install-{common,man,info} + install -Dm755 gcc/f951 $pkgdir/usr/lib/gcc/$CHOST/$pkgver/f951 + + # remove libraries included in gcc-libs + rm ${pkgdir}/usr/lib{,32}/lib{gfortran,quadmath}.so* + rm ${pkgdir}/usr/share/info/libquadmath.info + + # Install Runtime Library Exception + install -Dm644 ${_basedir}/COPYING.RUNTIME \ + ${pkgdir}/usr/share/licenses/gcc-fortran-multilib/RUNTIME.LIBRARY.EXCEPTION +} + +package_gcc-objc-multilib() +{ + pkgdesc="Objective-C front-end for GCC for multilib" + depends=("gcc-multilib=$pkgver-$pkgrel") + provides=("gcc-objc=$pkgver-$pkgrel") + conflicts=('gcc-objc') + + cd gcc-build + make -j1 DESTDIR=$pkgdir install-target-libobjc + install -dm755 $pkgdir/usr/lib/gcc/$CHOST/$pkgver/ + install -m755 gcc/cc1obj{,plus} $pkgdir/usr/lib/gcc/$CHOST/$pkgver/ + + # remove libraries included in gcc-libs + rm ${pkgdir}/usr/lib{,32}/libobjc.so* + + # Install Runtime Library Exception + install -Dm644 ${_basedir}/COPYING.RUNTIME \ + ${pkgdir}/usr/share/licenses/gcc-objc-multilib/RUNTIME.LIBRARY.EXCEPTION +} + +package_gcc-ada-multilib() +{ + pkgdesc="Ada front-end for GCC (GNAT) for multilib" + depends=("gcc-multilib=$pkgver-$pkgrel") + provides=("gcc-ada=$pkgver-$pkgrel") + conflicts=('gcc-ada') + install=gcc-ada.install + + cd gcc-build/gcc + make -j1 DESTDIR=$pkgdir ada.install-{common,info} + install -m755 gnat1 $pkgdir/usr/lib/gcc/$CHOST/$pkgver + + cd ../$CHOST/32/libada + make -j1 DESTDIR=${pkgdir} INSTALL="install" \ + INSTALL_DATA="install -m644" install-gnatlib + + # Install Runtime Library Exception + install -Dm644 ${_basedir}/COPYING.RUNTIME \ + ${pkgdir}/usr/share/licenses/gcc-ada-multilib/RUNTIME.LIBRARY.EXCEPTION +} + +package_gcc-go-multilib() +{ + pkgdesc="Go front-end for GCC for multilib" + depends=("gcc-multilib=$pkgver-$pkgrel") + provides=("gcc-go=$pkgver-$pkgrel") + conflicts=('gcc-go') + install=gcc-go.install + + cd gcc-build + make -j1 DESTDIR=$pkgdir install-target-libgo + make -j1 -C gcc DESTDIR=$pkgdir go.install-{common,man,info} + install -Dm755 gcc/go1 $pkgdir/usr/lib/gcc/$CHOST/$pkgver/go1 + + # Install Runtime Library Exception + install -Dm644 ${_basedir}/COPYING.RUNTIME \ + ${pkgdir}/usr/share/licenses/gcc-go/RUNTIME.LIBRARY.EXCEPTION +} diff --git a/multilib-staging/gcc-multilib/gcc-ada.install b/multilib-staging/gcc-multilib/gcc-ada.install new file mode 100644 index 000000000..df0553a4f --- /dev/null +++ b/multilib-staging/gcc-multilib/gcc-ada.install @@ -0,0 +1,20 @@ +infodir=usr/share/info +filelist=(gnat-style.info gnat_rm.info gnat_ugn.info) + +post_install() { + [ -x usr/bin/install-info ] || return 0 + for file in ${filelist[@]}; do + install-info $infodir/$file.gz $infodir/dir 2> /dev/null + done +} + +post_upgrade() { + post_install $1 +} + +pre_remove() { + [ -x usr/bin/install-info ] || return 0 + for file in ${filelist[@]}; do + install-info --delete $infodir/$file.gz $infodir/dir 2> /dev/null + done +} diff --git a/multilib-staging/gcc-multilib/gcc-fortran.install b/multilib-staging/gcc-multilib/gcc-fortran.install new file mode 100644 index 000000000..b15d89a97 --- /dev/null +++ b/multilib-staging/gcc-multilib/gcc-fortran.install @@ -0,0 +1,16 @@ +infodir=usr/share/info +file="gfortran.info" + +post_install() { + [ -x usr/bin/install-info ] || return 0 + install-info $infodir/$file.gz $infodir/dir 2> /dev/null +} + +post_upgrade() { + post_install $1 +} + +pre_remove() { + [ -x usr/bin/install-info ] || return 0 + install-info --delete $infodir/$file.gz $infodir/dir 2> /dev/null +} diff --git a/multilib-staging/gcc-multilib/gcc-go.install b/multilib-staging/gcc-multilib/gcc-go.install new file mode 100644 index 000000000..7dc50dee5 --- /dev/null +++ b/multilib-staging/gcc-multilib/gcc-go.install @@ -0,0 +1,20 @@ +infodir=usr/share/info +filelist=(gccgo.info) + +post_install() { + [ -x usr/bin/install-info ] || return 0 + for file in ${filelist[@]}; do + install-info $infodir/$file.gz $infodir/dir 2> /dev/null + done +} + +post_upgrade() { + post_install $1 +} + +pre_remove() { + [ -x usr/bin/install-info ] || return 0 + for file in ${filelist[@]}; do + install-info --delete $infodir/$file.gz $infodir/dir 2> /dev/null + done +} diff --git a/multilib-staging/gcc-multilib/gcc-hash-style-both.patch b/multilib-staging/gcc-multilib/gcc-hash-style-both.patch new file mode 100644 index 000000000..8b59f4535 --- /dev/null +++ b/multilib-staging/gcc-multilib/gcc-hash-style-both.patch @@ -0,0 +1,122 @@ +--- gcc/config/alpha/linux-elf.h.orig 2010-12-09 23:27:07.000000000 +1000 ++++ gcc/config/alpha/linux-elf.h 2011-03-11 10:01:47.770000457 +1000 +@@ -41,7 +41,7 @@ + + #define ELF_DYNAMIC_LINKER LINUX_DYNAMIC_LINKER + +-#define LINK_SPEC "-m elf64alpha %{G*} %{relax:-relax} \ ++#define LINK_SPEC "-m elf64alpha --hash-style=both %{G*} %{relax:-relax} \ + %{O*:-O3} %{!O*:-O1} \ + %{shared:-shared} \ + %{!shared: \ +--- gcc/config/i386/linux64.h.orig 2011-03-03 08:35:36.000000000 +1000 ++++ gcc/config/i386/linux64.h 2011-03-11 10:01:47.770000457 +1000 +@@ -78,7 +78,7 @@ + %{!mno-sse2avx:%{mavx:-msse2avx}} %{msse2avx:%{!mavx:-msse2avx}}" + + #undef LINK_SPEC +-#define LINK_SPEC "%{" SPEC_64 ":-m elf_x86_64} %{" SPEC_32 ":-m elf_i386} \ ++#define LINK_SPEC "%{" SPEC_64 ":-m elf_x86_64} %{" SPEC_32 ":-m elf_i386} --hash-style=both \ + %{shared:-shared} \ + %{!shared: \ + %{!static: \ +--- gcc/config/i386/linux.h.orig 2011-01-15 04:45:06.000000000 +1000 ++++ gcc/config/i386/linux.h 2011-03-11 10:01:47.770000457 +1000 +@@ -104,7 +104,7 @@ + { "dynamic_linker", LINUX_DYNAMIC_LINKER } + + #undef LINK_SPEC +-#define LINK_SPEC "-m %(link_emulation) %{shared:-shared} \ ++#define LINK_SPEC "-m %(link_emulation) --hash-style=both %{shared:-shared} \ + %{!shared: \ + %{!static: \ + %{rdynamic:-export-dynamic} \ +--- gcc/config/ia64/linux.h.orig 2010-12-09 23:27:07.000000000 +1000 ++++ gcc/config/ia64/linux.h 2011-03-11 10:01:47.770000457 +1000 +@@ -64,7 +64,7 @@ + #define GLIBC_DYNAMIC_LINKER "/lib/ld-linux-ia64.so.2" + + #undef LINK_SPEC +-#define LINK_SPEC "\ ++#define LINK_SPEC "--hash-style=both \ + %{shared:-shared} \ + %{!shared: \ + %{!static: \ +--- gcc/config/rs6000/linux64.h.orig 2011-02-11 03:30:10.000000000 +1000 ++++ gcc/config/rs6000/linux64.h 2011-03-11 10:03:34.280000457 +1000 +@@ -389,11 +389,11 @@ + CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER64, UCLIBC_DYNAMIC_LINKER64) + + +-#define LINK_OS_LINUX_SPEC32 "-m elf32ppclinux %{!shared: %{!static: \ ++#define LINK_OS_LINUX_SPEC32 "-m elf32ppclinux --hash-style=both %{!shared: %{!static: \ + %{rdynamic:-export-dynamic} \ + -dynamic-linker " LINUX_DYNAMIC_LINKER32 "}}" + +-#define LINK_OS_LINUX_SPEC64 "-m elf64ppc %{!shared: %{!static: \ ++#define LINK_OS_LINUX_SPEC64 "-m elf64ppc --hash-style=both %{!shared: %{!static: \ + %{rdynamic:-export-dynamic} \ + -dynamic-linker " LINUX_DYNAMIC_LINKER64 "}}" + +--- gcc/config/rs6000/sysv4.h.orig 2011-01-28 04:36:03.000000000 +1000 ++++ gcc/config/rs6000/sysv4.h 2011-03-11 10:01:47.773333792 +1000 +@@ -830,7 +830,7 @@ + #define LINUX_DYNAMIC_LINKER \ + CHOOSE_DYNAMIC_LINKER (GLIBC_DYNAMIC_LINKER, UCLIBC_DYNAMIC_LINKER) + +-#define LINK_OS_LINUX_SPEC "-m elf32ppclinux %{!shared: %{!static: \ ++#define LINK_OS_LINUX_SPEC "-m elf32ppclinux --hash-style=both %{!shared: %{!static: \ + %{rdynamic:-export-dynamic} \ + -dynamic-linker " LINUX_DYNAMIC_LINKER "}}" + +--- gcc/config/s390/linux.h.orig 2010-12-09 23:27:07.000000000 +1000 ++++ gcc/config/s390/linux.h 2011-03-11 10:01:47.770000457 +1000 +@@ -77,7 +77,7 @@ + + #undef LINK_SPEC + #define LINK_SPEC \ +- "%{m31:-m elf_s390}%{m64:-m elf64_s390} \ ++ "%{m31:-m elf_s390}%{m64:-m elf64_s390} --hash-style=both \ + %{shared:-shared} \ + %{!shared: \ + %{static:-static} \ +--- gcc/config/sparc/linux64.h.orig 2011-02-17 23:57:21.000000000 +1000 ++++ gcc/config/sparc/linux64.h 2011-03-11 10:01:47.770000457 +1000 +@@ -113,7 +113,7 @@ + { "link_arch_default", LINK_ARCH_DEFAULT_SPEC }, \ + { "link_arch", LINK_ARCH_SPEC }, + +-#define LINK_ARCH32_SPEC "-m elf32_sparc -Y P,%R/usr/lib %{shared:-shared} \ ++#define LINK_ARCH32_SPEC "-m elf32_sparc --hash-style=both -Y P,%R/usr/lib %{shared:-shared} \ + %{!shared: \ + %{!static: \ + %{rdynamic:-export-dynamic} \ +@@ -121,7 +121,7 @@ + %{static:-static}} \ + " + +-#define LINK_ARCH64_SPEC "-m elf64_sparc -Y P,%R/usr/lib64 %{shared:-shared} \ ++#define LINK_ARCH64_SPEC "-m elf64_sparc --hash-style=both -Y P,%R/usr/lib64 %{shared:-shared} \ + %{!shared: \ + %{!static: \ + %{rdynamic:-export-dynamic} \ +@@ -193,7 +193,7 @@ + #else /* !SPARC_BI_ARCH */ + + #undef LINK_SPEC +-#define LINK_SPEC "-m elf64_sparc -Y P,%R/usr/lib64 %{shared:-shared} \ ++#define LINK_SPEC "-m elf64_sparc --hash-style=both -Y P,%R/usr/lib64 %{shared:-shared} \ + %{!shared: \ + %{!static: \ + %{rdynamic:-export-dynamic} \ +--- gcc/config/sparc/linux.h.orig 2011-01-27 06:30:12.000000000 +1000 ++++ gcc/config/sparc/linux.h 2011-03-11 10:01:47.770000457 +1000 +@@ -74,7 +74,7 @@ + #define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2" + + #undef LINK_SPEC +-#define LINK_SPEC "-m elf32_sparc -Y P,/usr/lib %{shared:-shared} \ ++#define LINK_SPEC "-m elf32_sparc --hash-style=both -Y P,/usr/lib %{shared:-shared} \ + %{!mno-relax:%{!r:-relax}} \ + %{!shared: \ + %{!static: \ diff --git a/multilib-staging/gcc-multilib/gcc-libs.install b/multilib-staging/gcc-multilib/gcc-libs.install new file mode 100644 index 000000000..23553b8f0 --- /dev/null +++ b/multilib-staging/gcc-multilib/gcc-libs.install @@ -0,0 +1,16 @@ +infodir=usr/share/info +filelist=(libgomp.info libquadmath.info) + +post_upgrade() { + [ -x usr/bin/install-info ] || return 0 + for file in ${filelist[@]}; do + install-info $infodir/$file.gz $infodir/dir 2> /dev/null + done +} + +pre_remove() { + [ -x usr/bin/install-info ] || return 0 + for file in ${filelist[@]}; do + install-info --delete $infodir/$file.gz $infodir/dir 2> /dev/null + done +} diff --git a/multilib-staging/gcc-multilib/gcc.install b/multilib-staging/gcc-multilib/gcc.install new file mode 100644 index 000000000..3407a5e1f --- /dev/null +++ b/multilib-staging/gcc-multilib/gcc.install @@ -0,0 +1,20 @@ +infodir=usr/share/info +filelist=(cpp.info cppinternals.info gcc.info gccinstall.info gccint.info) + +post_install() { + [ -x usr/bin/install-info ] || return 0 + for file in ${filelist[@]}; do + install-info $infodir/$file.gz $infodir/dir 2> /dev/null + done +} + +post_upgrade() { + post_install $1 +} + +pre_remove() { + [ -x usr/bin/install-info ] || return 0 + for file in ${filelist[@]}; do + install-info --delete $infodir/$file.gz $infodir/dir 2> /dev/null + done +} diff --git a/multilib-staging/gcc-multilib/gcc_pure64-multilib.patch b/multilib-staging/gcc-multilib/gcc_pure64-multilib.patch new file mode 100644 index 000000000..73df6b873 --- /dev/null +++ b/multilib-staging/gcc-multilib/gcc_pure64-multilib.patch @@ -0,0 +1,24 @@ +diff -u -r gcc-4.6-20111223/gcc/config/i386/linux64.h gcc-4.6-20111223-pure64/gcc/config/i386/linux64.h +--- gcc-4.6-20111223/gcc/config/i386/linux64.h 2011-09-08 11:12:35.000000000 +0200 ++++ gcc-4.6-20111223-pure64/gcc/config/i386/linux64.h 2012-01-14 19:52:33.688573352 +0100 +@@ -63,7 +63,7 @@ + done. */ + + #define GLIBC_DYNAMIC_LINKER32 "/lib/ld-linux.so.2" +-#define GLIBC_DYNAMIC_LINKER64 "/lib64/ld-linux-x86-64.so.2" ++#define GLIBC_DYNAMIC_LINKER64 "/lib/ld-linux-x86-64.so.2" + + #if TARGET_64BIT_DEFAULT + #define SPEC_32 "m32" +diff -u -r gcc-4.6-20111223/gcc/config/i386/t-linux64 gcc-4.6-20111223-pure64/gcc/config/i386/t-linux64 +--- gcc-4.6-20111223/gcc/config/i386/t-linux64 2009-04-21 21:03:23.000000000 +0200 ++++ gcc-4.6-20111223-pure64/gcc/config/i386/t-linux64 2012-01-14 19:50:27.346242617 +0100 +@@ -25,7 +25,7 @@ + + MULTILIB_OPTIONS = m64/m32 + MULTILIB_DIRNAMES = 64 32 +-MULTILIB_OSDIRNAMES = ../lib64 $(if $(wildcard $(shell echo $(SYSTEM_HEADER_DIR))/../../usr/lib32),../lib32,../lib) ++MULTILIB_OSDIRNAMES = ../lib ../lib32 + + LIBGCC = stmp-multilib + INSTALL_LIBGCC = install-multilib diff --git a/multilib-staging/jack2-multilib/40-hpet-permissions.rules b/multilib-staging/jack2-multilib/40-hpet-permissions.rules new file mode 100644 index 000000000..7af3780f9 --- /dev/null +++ b/multilib-staging/jack2-multilib/40-hpet-permissions.rules @@ -0,0 +1,2 @@ +KERNEL=="rtc0", GROUP="audio" +KERNEL=="hpet", GROUP="audio" diff --git a/multilib-staging/jack2-multilib/99-audio.conf b/multilib-staging/jack2-multilib/99-audio.conf new file mode 100644 index 000000000..eb76ef920 --- /dev/null +++ b/multilib-staging/jack2-multilib/99-audio.conf @@ -0,0 +1,2 @@ +@audio - rtprio 99 +@audio - memlock unlimited diff --git a/multilib-staging/jack2-multilib/PKGBUILD b/multilib-staging/jack2-multilib/PKGBUILD new file mode 100644 index 000000000..9c7e0fd6f --- /dev/null +++ b/multilib-staging/jack2-multilib/PKGBUILD @@ -0,0 +1,142 @@ +# $Id: PKGBUILD 52694 2011-07-27 17:23:48Z schiv $ +# Maintainer: Ray Rashif <schiv@archlinux.org> +# Contributor: SpepS <dreamspepser at yahoo dot it> + +# This one is in response to a need for an equivalent to lib32-jack for +# jack2. A lib32-jack2 would require much patching and invading the pure +# jack2 package, and what's more, the buildsystem provides a flag just to +# build a hybrid jack2 in full. As such, we have opted to provide multilib +# users with a replacement package instead of the usual lib32 add-on. +# +# See http://mailman.archlinux.org/pipermail/arch-multilib/2011-December/000251.html + +pkgbase=jack2-multilib +pkgname=('jack2-multilib' 'jack2-dbus-multilib') +#pkgname= # single build (overrides split) +_tarname=jack +pkgver=1.9.7 +pkgrel=2 +arch=('x86_64') +url="http://jackaudio.org/" +backup=(etc/security/limits.d/99-audio.conf) +license=('GPL') +makedepends=('python2' 'libffado' 'libsamplerate' 'celt' + 'doxygen' 'gcc-multilib' 'lib32-dbus-core') +source=("http://www.grame.fr/~letz/$_tarname-$pkgver.tar.bz2" + '99-audio.conf' + '40-hpet-permissions.rules') +md5sums=('9759670feecbd43eeccf1c0f743ec199' + 'ae65b7c9ebe0fff6c918ba9d97ae342d' + '471aad533ff56c5d3cbbf65ce32cadef') + +_pyfix() { + sed -i 's:bin/env python:bin/env python2:' \ + "$pkgdir/usr/bin/jack_control" +} + +_wafconf() { + python2 waf configure --prefix=/usr \ + --alsa \ + --firewire \ + --mixed \ + --doxygen $@ +} + +_isbuild() { + printf "%s\n" ${pkgname[@]} | grep -qx $1 +} + +_mklinks() { + ln -s /usr/lib32/libjack.so.0.1.0 "$pkgdir/usr/lib32/libjack.so.0" + ln -s /usr/lib32/libjack.so.0 "$pkgdir/usr/lib32/libjack.so" +} + +build() { + cd "$srcdir" + + # fix doxygen building + sed -i 's:build/default/html:html:' $_tarname-$pkgver/wscript + + # we may do 2 different builds + cp -r $_tarname-$pkgver $_tarname-dbus-$pkgver + + # mixed dbus/classic build + if _isbuild jack2-multilib; then + cd $_tarname-$pkgver + msg2 "Running Mixed D-Bus/Classic build" + _wafconf --classic --dbus + python2 waf build $MAKEFLAGS + cd .. + fi + + # dbus-ONLY build + if _isbuild jack2-dbus-multilib; then + cd $_tarname-dbus-$pkgver + msg2 "Running D-Bus-only build" + _wafconf --dbus + python2 waf build $MAKEFLAGS + cd .. + fi +} + +package_jack2-multilib() { + ! _isbuild jack2-multilib && return 0 + + pkgdesc="The next-generation JACK with SMP support & mixed mode" + depends=('libsamplerate' 'gcc-libs-multilib') + optdepends=('libffado: FireWire support' + 'celt: NetJACK2 driver' + 'lib32-dbus-core: jackdbus' + 'python2: jack_control') + conflicts=('jack' 'jack2' 'lib32-jack') + provides=('jack' 'jack2' 'lib32-jack' 'jackmp' + 'jackdmp' 'jackdbus' 'lib32-jack2') + + cd "$srcdir/$_tarname-$pkgver" + + python2 waf install --destdir="$pkgdir" + + # fix for major python transition + _pyfix + + # configure realtime access/scheduling + # see https://bugs.archlinux.org/task/26343 + install -Dm644 "$srcdir/99-audio.conf" \ + "$pkgdir/etc/security/limits.d/99-audio.conf" + + install -Dm644 "$srcdir/40-hpet-permissions.rules" \ + "$pkgdir/lib/udev/rules.d/40-hpet-permissions.rules" + + # should be done by upstream + # see http://trac.jackaudio.org/ticket/200 + _mklinks +} + +package_jack2-dbus-multilib() { + ! _isbuild jack2-dbus-multilib && return 0 + + pkgdesc="The next-generation JACK with SMP support & mixed mode (for D-BUS interaction only)" + depends=('libsamplerate' 'lib32-dbus-core') + optdepends=('libffado: FireWire support' + 'celt: NetJACK2 driver' + 'python2: jack_control') + conflicts=('jack' 'jack2' 'lib32-jack' 'jack2-multilib') + provides=('jack' 'jack2' 'lib32-jack' 'jack2-multilib' + 'jackmp' 'jackdmp' 'jackdbus' 'lib32-jack2') + + cd "$srcdir/$_tarname-dbus-$pkgver" + + python2 waf install --destdir="$pkgdir" + + _pyfix + + install -Dm644 "$srcdir/99-audio.conf" \ + "$pkgdir/etc/security/limits.d/99-audio.conf" + + install -Dm644 "$srcdir/40-hpet-permissions.rules" \ + "$pkgdir/lib/udev/rules.d/40-hpet-permissions.rules" + + _mklinks +} + +# vim:set ts=2 sw=2 et: diff --git a/multilib-staging/lib32-gdk-pixbuf2/PKGBUILD b/multilib-staging/lib32-gdk-pixbuf2/PKGBUILD new file mode 100644 index 000000000..eef9aca26 --- /dev/null +++ b/multilib-staging/lib32-gdk-pixbuf2/PKGBUILD @@ -0,0 +1,45 @@ +# $Id: PKGBUILD 91063 2010-09-21 19:21:24Z ibiru $ +# Maintainer: Ionut Biru <ibiru@archlinux.org> +_pkgbasename=gdk-pixbuf2 +pkgname=lib32-$_pkgbasename +pkgver=2.24.1 +pkgrel=1 +pkgdesc="An image loading library (32-bit)" +arch=('x86_64') +url="http://www.gtk.org/" +license=('GPL2') +depends=(lib32-glib2 lib32-libpng lib32-libtiff lib32-libjpeg lib32-libx11 + $_pkgbasename) +makedepends=(gcc-multilib) +options=('!libtool' '!docs') +install=gdk-pixbuf2.install +source=(http://download.gnome.org/sources/gdk-pixbuf/2.24/gdk-pixbuf-${pkgver}.tar.xz) +sha256sums=('da7a3f00db360913716368e19e336402755cafa93769f3cfa28a969303e4bee1') + +build() { + export CC="gcc -m32" + export CXX="g++ -m32" + export PKG_CONFIG_PATH="/usr/lib32/pkgconfig" + + cd "${srcdir}/gdk-pixbuf-${pkgver}" + + ./configure --prefix=/usr --libdir=/usr/lib32 \ + --without-libjasper \ + --with-x11 \ + --with-included-loaders=png + make +} + +package() { + cd "${srcdir}/gdk-pixbuf-${pkgver}" + + make DESTDIR="${pkgdir}" install + rm -rf "${pkgdir}"/etc + rm -rf "${pkgdir}"/usr/{include,share} + + cd "${pkgdir}"/usr/bin + mv gdk-pixbuf-query-loaders gdk-pixbuf-query-loaders-32 + rm gdk-pixbuf-csource +} + +# vim:set ts=2 sw=2 et: diff --git a/multilib-staging/lib32-gdk-pixbuf2/gdk-pixbuf2.install b/multilib-staging/lib32-gdk-pixbuf2/gdk-pixbuf2.install new file mode 100644 index 000000000..92d58ef04 --- /dev/null +++ b/multilib-staging/lib32-gdk-pixbuf2/gdk-pixbuf2.install @@ -0,0 +1,11 @@ +post_install() { + usr/bin/gdk-pixbuf-query-loaders-32 --update-cache +} + +post_upgrade() { + post_install +} + +pre_remove() { + rm -f usr/lib32/gdk-pixbuf-2.0/2.10.0/loaders/loaders.cache +} diff --git a/multilib-staging/lib32-glib2/PKGBUILD b/multilib-staging/lib32-glib2/PKGBUILD new file mode 100644 index 000000000..a1a1f36f3 --- /dev/null +++ b/multilib-staging/lib32-glib2/PKGBUILD @@ -0,0 +1,40 @@ +# $Id: PKGBUILD 62040 2012-01-14 23:44:48Z heftig $ +# Maintainer: Ionut Biru <ibiru@archlinux.org> +# Contributor: Pierre Schmitz <pierre@archlinux.de> +# Contributor: Mikko Seppälä <t-r-a-y@mbnet.fi> + +_pkgbasename=glib2 +pkgname=lib32-$_pkgbasename +pkgver=2.30.2 +pkgrel=2 +pkgdesc="Common C routines used by GTK+ 2.4 and other libs (32-bit)" +url="http://www.gtk.org/" +arch=('x86_64') +license=('LGPL') +depends=('lib32-pcre' 'lib32-zlib' 'lib32-dbus-core' lib32-libffi $_pkgbasename) +makedepends=('gcc-multilib' python2) +options=('!libtool' '!docs') +source=(http://ftp.gnome.org/pub/GNOME/sources/glib/2.30/glib-${pkgver}.tar.xz) +sha256sums=('f0e91e6333321ddb48fa12b5c66f56c3d5f05325748c66dd2e9016c278ff8e82') + +build() { + export CC="gcc -m32" + export CXX="g++ -m32" + export PKG_CONFIG_PATH="/usr/lib32/pkgconfig" + + cd "${srcdir}/glib-${pkgver}" + PYTHON=/usr/bin/python2 ./configure --prefix=/usr --sysconfdir=/etc --libdir=/usr/lib32 \ + --enable-static --enable-shared --with-pcre=system --disable-fam + make +} + +package() { + cd "${srcdir}/glib-${pkgver}" + make DESTDIR="${pkgdir}" install + rm -rf "${pkgdir}"/{etc,usr/{share,include}} + + cd "${pkgdir}"/usr/bin + mv gio-querymodules gio-querymodules-32 + rm -f gdbus glib* gobject-query gsettings gtester* + rm -rf "$pkgdir"/usr/{bin/gdbus-codegen,lib32/gdbus-2.0} +} diff --git a/multilib-staging/lib32-glibc/PKGBUILD b/multilib-staging/lib32-glibc/PKGBUILD new file mode 100644 index 000000000..ed4d6efa8 --- /dev/null +++ b/multilib-staging/lib32-glibc/PKGBUILD @@ -0,0 +1,176 @@ +# $Id: PKGBUILD 62030 2012-01-14 21:43:25Z heftig $ +# Maintainer: Jan "heftig" Steffens <jan.steffens@gmail.com> +# Contributor: Jan de Groot <jgc@archlinux.org> +# Contributor: Allan McRae <allan@archlinux.org> + +# toolchain build order: linux-api-headers->glibc->binutils->gcc->binutils->glibc +# NOTE: valgrind requires rebuilt with each major glibc version + +_pkgbasename=glibc +pkgname=lib32-$_pkgbasename +pkgver=2.15 +pkgrel=3.1 +_glibcdate=20111227 +pkgdesc="GNU C Library for multilib" +arch=('x86_64') +url="http://www.gnu.org/software/libc" +license=('GPL' 'LGPL') +depends=("glibc>=$pkgver") +makedepends=('gcc-multilib>=4.6') +options=('!strip' '!emptydirs') +source=(ftp://ftp.archlinux.org/other/glibc/${_pkgbasename}-${pkgver}_${_glibcdate}.tar.xz + glibc-2.10-dont-build-timezone.patch + glibc-2.10-bz4781.patch + glibc-__i686.patch + glibc-2.12.2-ignore-origin-of-privileged-program.patch + glibc-2.14-libdl-crash.patch + glibc-2.14-revert-4768ae77.patch + glibc-2.14-reexport-rpc-interface.patch + glibc-2.14-reinstall-nis-rpc-headers.patch + glibc-2.15-lddebug-scopes.patch + glibc-2.15-revert-c5a0802a.patch + glibc-2.15-math64crash.patch + lib32-glibc.conf) +md5sums=('6ffdf5832192b92f98bdd125317c0dfc' + '4dadb9203b69a3210d53514bb46f41c3' + '0c5540efc51c0b93996c51b57a8540ae' + '40cd342e21f71f5e49e32622b25acc52' + 'b042647ea7d6f22ad319e12e796bd13e' + '6970bcfeb3bf88913436d5112d16f588' + '7da8c554a3b591c7401d7023b1928afc' + 'c5de2a946215d647c8af5432ec4b0da0' + '55febbb72139ac7b65757df085024b83' + '3c219ddfb619b6df903cac4cc42c611d' + '7ae3e426251ae33e73dbad71f9c91378' + 'dc7550e659ddd685bd78a930d15a01f2' + '6e052f1cb693d5d3203f50f9d4e8c33b') + +build() { + cd ${srcdir}/glibc + + # timezone data is in separate package (tzdata) + patch -Np1 -i ${srcdir}/glibc-2.10-dont-build-timezone.patch + + # http://sources.redhat.com/bugzilla/show_bug.cgi?id=4781 + patch -Np1 -i ${srcdir}/glibc-2.10-bz4781.patch + + # http://sources.redhat.com/bugzilla/show_bug.cgi?id=411 + # http://sourceware.org/ml/libc-alpha/2009-07/msg00072.html + patch -Np1 -i ${srcdir}/glibc-__i686.patch + + # http://www.exploit-db.com/exploits/15274/ + # http://sourceware.org/git/?p=glibc.git;a=patch;h=d14e6b09 (only fedora branch...) + patch -Np1 -i ${srcdir}/glibc-2.12.2-ignore-origin-of-privileged-program.patch + + # http://sourceware.org/git/?p=glibc.git;a=commitdiff;h=675155e9 (only fedora branch...) + # http://sourceware.org/ml/libc-alpha/2011-06/msg00006.html + patch -Np1 -i ${srcdir}/glibc-2.14-libdl-crash.patch + + # Revert commit causing issues with crappy DNS servers... + # Will be removed when workaround becomes annoying to maintain - USE A BETTER DNS SERVER! + # Note that both these patches appear not to fix the issue completely: + # http://sourceware.org/bugzilla/show_bug.cgi?id=13013 + # http://sourceware.org/git/?p=glibc.git;a=commitdiff;h=032c0ee3 (only fedora branch...) + patch -Np1 -i ${srcdir}/glibc-2.14-revert-4768ae77.patch + + # re-export RPC interface until libtirpc is ready as a replacement + # http://sourceware.org/git/?p=glibc.git;a=commitdiff;h=acee4873 (only fedora branch...) + patch -Np1 -i ${srcdir}/glibc-2.14-reexport-rpc-interface.patch + # http://sourceware.org/git/?p=glibc.git;a=commitdiff;h=bdd816a3 (only fedora branch...) + patch -Np1 -i ${srcdir}/glibc-2.14-reinstall-nis-rpc-headers.patch + + # propriety nvidia crash - https://bugzilla.redhat.com/show_bug.cgi?id=737223 + # http://sourceware.org/git/?p=glibc.git;a=commitdiff;h=0c95ab64 (only fedora branch...) + patch -Np1 -i ${srcdir}/glibc-2.15-lddebug-scopes.patch + + # revert commit c5a0802a - causes various hangs + # https://bugzilla.redhat.com/show_bug.cgi?id=769421 + patch -Np1 -i ${srcdir}/glibc-2.15-revert-c5a0802a.patch + + # revert optimized math routines that can cause crashes (FS#27736, FS#27743) + # obviously not a real fix... + patch -Np1 -i ${srcdir}/glibc-2.15-math64crash.patch + + cd ${srcdir} + mkdir glibc-build + cd glibc-build + + export CC="gcc -m32" + + # Hack to fix NPTL issues with Xen, only required on 32bit platforms + export CFLAGS="${CFLAGS} -mno-tls-direct-seg-refs" + + echo "slibdir=/usr/lib32" >> configparms + + # remove hardening options from CFLAGS for building libraries + CFLAGS=${CFLAGS/-fstack-protector/} + CFLAGS=${CFLAGS/-D_FORTIFY_SOURCE=2/} + + ${srcdir}/glibc/configure --prefix=/usr \ + --libdir=/usr/lib32 --libexecdir=/usr/lib32 \ + --with-headers=/usr/include \ + --enable-add-ons=nptl,libidn \ + --enable-kernel=2.6.27 \ + --with-tls --with-__thread \ + --enable-bind-now --without-gd \ + --without-cvs --disable-profile \ + --enable-multi-arch i686-unknown-linux-gnu + + # build libraries with hardening disabled + echo "build-programs=no" >> configparms + make + + # re-enable hardening for programs + sed -i "s#=no#=yes#" configparms + echo "CC += -fstack-protector -D_FORTIFY_SOURCE=2" >> configparms + echo "CXX += -fstack-protector -D_FORTIFY_SOURCE=2" >> configparms + make + + # remove harding in preparation to run test-suite + sed -i '2,4d' configparms +} + +check() { + cd ${srcdir}/glibc-build + + # some errors are expected - manually check log files + make -k check || true +} + +package() { + cd ${srcdir}/glibc-build + make install_root=${pkgdir} install + + rm -rf ${pkgdir}/{etc,sbin,usr/{bin,sbin,share},var} + + # We need one 32 bit specific header file + find ${pkgdir}/usr/include -type f -not -name stubs-32.h -delete + + # Do not strip the following files for improved debugging support + # ("improved" as in not breaking gdb and valgrind...): + # ld-${pkgver}.so + # libc-${pkgver}.so + # libpthread-${pkgver}.so + # libthread_db-1.0.so + + cd $pkgdir + strip $STRIP_BINARIES usr/lib32/getconf/* + + strip $STRIP_STATIC usr/lib32/*.a + + strip $STRIP_SHARED usr/lib32/{libanl,libBrokenLocale,libcidn,libcrypt}-${pkgver}.so \ + usr/lib32/libnss_{compat,db,dns,files,hesiod,nis,nisplus}-${pkgver}.so \ + usr/lib32/{libdl,libm,libnsl,libresolv,librt,libutil}-${pkgver}.so \ + usr/lib32/{libmemusage,libpcprofile,libSegFault}.so \ + usr/lib32/{pt_chown,{audit,gconv}/*.so} + + # Dynamic linker + mkdir ${pkgdir}/lib + ln -s ../usr/lib32/ld-linux.so.2 ${pkgdir}/lib/ + + # Add lib32 paths to the default library search path + install -Dm644 "$srcdir/lib32-glibc.conf" "$pkgdir/etc/ld.so.conf.d/lib32-glibc.conf" + + # Symlink /usr/lib32/locale to /usr/lib/locale + ln -s ../lib/locale "$pkgdir/usr/lib32/locale" +} diff --git a/multilib-staging/lib32-glibc/glibc-2.10-bz4781.patch b/multilib-staging/lib32-glibc/glibc-2.10-bz4781.patch new file mode 100644 index 000000000..cf1a97a18 --- /dev/null +++ b/multilib-staging/lib32-glibc/glibc-2.10-bz4781.patch @@ -0,0 +1,42 @@ +diff -Naur glibc-old/sysdeps/unix/sysv/linux/i386/clone.S glibc/sysdeps/unix/sysv/linux/i386/clone.S +--- glibc-old/sysdeps/unix/sysv/linux/i386/clone.S 2009-05-09 13:35:30.000000000 +1000 ++++ glibc/sysdeps/unix/sysv/linux/i386/clone.S 2009-05-23 13:27:46.000000000 +1000 +@@ -120,9 +120,6 @@ + ret + + L(thread_start): +- cfi_startproc; +- /* Clearing frame pointer is insufficient, use CFI. */ +- cfi_undefined (eip); + /* Note: %esi is zero. */ + movl %esi,%ebp /* terminate the stack frame */ + #ifdef RESET_PID +@@ -155,7 +152,6 @@ + jmp L(haspid) + .previous + #endif +- cfi_endproc; + + cfi_startproc + PSEUDO_END (BP_SYM (__clone)) +diff -Naur glibc-old/sysdeps/unix/sysv/linux/x86_64/clone.S glibc/sysdeps/unix/sysv/linux/x86_64/clone.S +--- glibc-old/sysdeps/unix/sysv/linux/x86_64/clone.S 2009-05-09 13:35:30.000000000 +1000 ++++ glibc/sysdeps/unix/sysv/linux/x86_64/clone.S 2009-05-23 13:27:46.000000000 +1000 +@@ -89,9 +89,6 @@ + ret + + L(thread_start): +- cfi_startproc; +- /* Clearing frame pointer is insufficient, use CFI. */ +- cfi_undefined (rip); + /* Clear the frame pointer. The ABI suggests this be done, to mark + the outermost frame obviously. */ + xorl %ebp, %ebp +@@ -116,7 +113,6 @@ + /* Call exit with return value from function call. */ + movq %rax, %rdi + call HIDDEN_JUMPTARGET (_exit) +- cfi_endproc; + + cfi_startproc; + PSEUDO_END (BP_SYM (__clone)) diff --git a/multilib-staging/lib32-glibc/glibc-2.10-dont-build-timezone.patch b/multilib-staging/lib32-glibc/glibc-2.10-dont-build-timezone.patch new file mode 100644 index 000000000..d3abeff17 --- /dev/null +++ b/multilib-staging/lib32-glibc/glibc-2.10-dont-build-timezone.patch @@ -0,0 +1,13 @@ +timezone data has been split into the package sys-libs/timezone-data + +--- glibc-2.4/Makeconfig ++++ glibc-2.4/Makeconfig +@@ -931,7 +931,7 @@ + stdlib stdio-common libio malloc string wcsmbs time dirent \ + grp pwd posix io termios resource misc socket sysvipc gmon \ + gnulib iconv iconvdata wctype manual shadow gshadow po argp \ +- crypt nss localedata timezone rt conform debug \ ++ crypt nss localedata rt conform debug \ + $(add-on-subdirs) $(dlfcn) $(binfmt-subdir) + + ifndef avoid-generated diff --git a/multilib-staging/lib32-glibc/glibc-2.12.2-ignore-origin-of-privileged-program.patch b/multilib-staging/lib32-glibc/glibc-2.12.2-ignore-origin-of-privileged-program.patch new file mode 100644 index 000000000..ce089b49c --- /dev/null +++ b/multilib-staging/lib32-glibc/glibc-2.12.2-ignore-origin-of-privileged-program.patch @@ -0,0 +1,26 @@ +From d14e6b09d60d52cc12f0396c3106b14e1bd0fe8f Mon Sep 17 00:00:00 2001 +From: Andreas Schwab <schwab@redhat.com> +Date: Thu, 9 Dec 2010 15:00:59 +0100 +Subject: [PATCH 1/1] Ignore origin of privileged program + +--- + ChangeLog | 5 +++++ + elf/dl-object.c | 3 +++ + 2 files changed, 8 insertions(+), 0 deletions(-) + +diff --git a/elf/dl-object.c b/elf/dl-object.c +index 22a1635..7674d49 100644 +--- a/elf/dl-object.c ++++ b/elf/dl-object.c +@@ -214,6 +214,9 @@ _dl_new_object (char *realname, const char *libname, int type, + out: + new->l_origin = origin; + } ++ else if (INTUSE(__libc_enable_secure) && type == lt_executable) ++ /* The origin of a privileged program cannot be trusted. */ ++ new->l_origin = (char *) -1; + + return new; + } +-- +1.7.2 diff --git a/multilib-staging/lib32-glibc/glibc-2.14-libdl-crash.patch b/multilib-staging/lib32-glibc/glibc-2.14-libdl-crash.patch new file mode 100644 index 000000000..6c9d2718e --- /dev/null +++ b/multilib-staging/lib32-glibc/glibc-2.14-libdl-crash.patch @@ -0,0 +1,132 @@ +diff --git a/elf/dl-close.c b/elf/dl-close.c +index 73b2a2f..9bd91e3 100644 +--- a/elf/dl-close.c ++++ b/elf/dl-close.c +@@ -1,5 +1,5 @@ + /* Close a shared object opened by `_dl_open'. +- Copyright (C) 1996-2007, 2009, 2010, 2011 Free Software Foundation, Inc. ++ Copyright (C) 1996-2007, 2009, 2010 Free Software Foundation, Inc. + This file is part of the GNU C Library. + + The GNU C Library is free software; you can redistribute it and/or +@@ -119,17 +119,8 @@ _dl_close_worker (struct link_map *map) + if (map->l_direct_opencount > 0 || map->l_type != lt_loaded + || dl_close_state != not_pending) + { +- if (map->l_direct_opencount == 0) +- { +- if (map->l_type == lt_loaded) +- dl_close_state = rerun; +- else if (map->l_type == lt_library) +- { +- struct link_map **oldp = map->l_initfini; +- map->l_initfini = map->l_orig_initfini; +- _dl_scope_free (oldp); +- } +- } ++ if (map->l_direct_opencount == 0 && map->l_type == lt_loaded) ++ dl_close_state = rerun; + + /* There are still references to this object. Do nothing more. */ + if (__builtin_expect (GLRO(dl_debug_mask) & DL_DEBUG_FILES, 0)) +diff --git a/elf/dl-deps.c b/elf/dl-deps.c +index 9e30594..3890d00 100644 +--- a/elf/dl-deps.c ++++ b/elf/dl-deps.c +@@ -478,6 +478,7 @@ _dl_map_object_deps (struct link_map *map, + nneeded * sizeof needed[0]); + atomic_write_barrier (); + l->l_initfini = l_initfini; ++ l->l_free_initfini = 1; + } + + /* If we have no auxiliary objects just go on to the next map. */ +@@ -681,6 +682,7 @@ Filters not supported with LD_TRACE_PRELINKING")); + l_initfini[nlist] = NULL; + atomic_write_barrier (); + map->l_initfini = l_initfini; ++ map->l_free_initfini = 1; + if (l_reldeps != NULL) + { + atomic_write_barrier (); +@@ -689,5 +691,5 @@ Filters not supported with LD_TRACE_PRELINKING")); + _dl_scope_free (old_l_reldeps); + } + if (old_l_initfini != NULL) +- map->l_orig_initfini = old_l_initfini; ++ _dl_scope_free (old_l_initfini); + +diff --git a/elf/dl-libc.c b/elf/dl-libc.c +index 7be9483..a13fce3 100644 +--- a/elf/dl-libc.c ++++ b/elf/dl-libc.c +@@ -265,13 +265,13 @@ libc_freeres_fn (free_mem) + + for (Lmid_t ns = 0; ns < GL(dl_nns); ++ns) + { +- /* Remove all additional names added to the objects. */ + for (l = GL(dl_ns)[ns]._ns_loaded; l != NULL; l = l->l_next) + { + struct libname_list *lnp = l->l_libname->next; + + l->l_libname->next = NULL; + ++ /* Remove all additional names added to the objects. */ + while (lnp != NULL) + { + struct libname_list *old = lnp; +@@ -279,6 +279,10 @@ libc_freeres_fn (free_mem) + if (! old->dont_free) + free (old); + } ++ ++ /* Free the initfini dependency list. */ ++ if (l->l_free_initfini) ++ free (l->l_initfini); + } + + if (__builtin_expect (GL(dl_ns)[ns]._ns_global_scope_alloc, 0) != 0 +diff --git a/elf/rtld.c b/elf/rtld.c +index 4a9109e..617e30e 100644 +--- a/elf/rtld.c ++++ b/elf/rtld.c +@@ -2251,6 +2251,7 @@ ERROR: ld.so: object '%s' cannot be loaded as audit interface: %s; ignored.\n", + lnp->dont_free = 1; + lnp = lnp->next; + } ++ l->l_free_initfini = 0; + + if (l != &GL(dl_rtld_map)) + _dl_relocate_object (l, l->l_scope, GLRO(dl_lazy) ? RTLD_LAZY : 0, +diff --git a/include/link.h b/include/link.h +index e877104..051b99a 100644 +--- a/include/link.h ++++ b/include/link.h +@@ -1,6 +1,6 @@ + /* Data structure for communication from the run-time dynamic linker for + loaded ELF shared objects. +- Copyright (C) 1995-2006, 2007, 2009, 2010, 2011 Free Software Foundation, Inc. ++ Copyright (C) 1995-2006, 2007, 2009, 2010 Free Software Foundation, Inc. + This file is part of the GNU C Library. + + The GNU C Library is free software; you can redistribute it and/or +@@ -192,6 +192,9 @@ struct link_map + during LD_TRACE_PRELINKING=1 + contains any DT_SYMBOLIC + libraries. */ ++ unsigned int l_free_initfini:1; /* Nonzero if l_initfini can be ++ freed, ie. not allocated with ++ the dummy malloc in ld.so. */ + + /* Collected information about own RPATH directories. */ + struct r_search_path_struct l_rpath_dirs; +@@ -240,9 +243,6 @@ struct link_map + + /* List of object in order of the init and fini calls. */ + struct link_map **l_initfini; +- /* The init and fini list generated at startup, saved when the +- object is also loaded dynamically. */ +- struct link_map **l_orig_initfini; + + /* List of the dependencies introduced through symbol binding. */ + struct link_map_reldeps diff --git a/multilib-staging/lib32-glibc/glibc-2.14-reexport-rpc-interface.patch b/multilib-staging/lib32-glibc/glibc-2.14-reexport-rpc-interface.patch new file mode 100644 index 000000000..e2beea881 --- /dev/null +++ b/multilib-staging/lib32-glibc/glibc-2.14-reexport-rpc-interface.patch @@ -0,0 +1,26 @@ +diff --git a/include/libc-symbols.h b/include/libc-symbols.h +index 67e1ca2..5e7cca5 100644 +--- a/include/libc-symbols.h ++++ b/include/libc-symbols.h +@@ -635,7 +635,7 @@ for linking") + # define libc_hidden_proto(name, attrs...) hidden_proto (name, ##attrs) + # define libc_hidden_def(name) hidden_def (name) + # define libc_hidden_weak(name) hidden_weak (name) +-# define libc_hidden_nolink(name, version) hidden_nolink (name, libc, version) ++# define libc_hidden_nolink(name, version) hidden_def (name) + # define libc_hidden_ver(local, name) hidden_ver (local, name) + # define libc_hidden_data_def(name) hidden_data_def (name) + # define libc_hidden_data_weak(name) hidden_data_weak (name) +diff --git a/sunrpc/Makefile b/sunrpc/Makefile +index 5134ce9..40c73d1 100644 +--- a/sunrpc/Makefile ++++ b/sunrpc/Makefile +@@ -53,7 +53,7 @@ headers-in-tirpc = $(addprefix rpc/,auth.h auth_unix.h clnt.h pmap_clnt.h \ + des_crypt.h) + headers-not-in-tirpc = $(addprefix rpc/,key_prot.h rpc_des.h) \ + $(rpcsvc:%=rpcsvc/%) rpcsvc/bootparam.h +-headers = rpc/netdb.h ++headers = rpc/netdb.h $(headers-in-tirpc) $(headers-not-in-tirpc) + install-others = $(inst_sysconfdir)/rpc + generated = $(rpcsvc:%.x=rpcsvc/%.h) $(rpcsvc:%.x=x%.c) $(rpcsvc:%.x=x%.stmp) \ + $(rpcsvc:%.x=rpcsvc/%.stmp) rpcgen diff --git a/multilib-staging/lib32-glibc/glibc-2.14-reinstall-nis-rpc-headers.patch b/multilib-staging/lib32-glibc/glibc-2.14-reinstall-nis-rpc-headers.patch new file mode 100644 index 000000000..eb0fd822d --- /dev/null +++ b/multilib-staging/lib32-glibc/glibc-2.14-reinstall-nis-rpc-headers.patch @@ -0,0 +1,28 @@ +From bdd816a366c4e5bba5de7157d948e0c0737fb4fb Mon Sep 17 00:00:00 2001 +From: Andreas Schwab <schwab@redhat.com> +Date: Tue, 17 May 2011 17:42:30 +0200 +Subject: [PATCH] Reinstall NIS RPC headers + +--- + nis/Makefile | 4 ++-- + 1 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/nis/Makefile b/nis/Makefile +index b5c9609..d2934d9 100644 +--- a/nis/Makefile ++++ b/nis/Makefile +@@ -23,9 +23,9 @@ subdir := nis + + aux := nis_hash + ++headers := $(wildcard rpcsvc/*.[hx]) + distribute := nss-nis.h nss-nisplus.h nis_intern.h Banner \ +- nisplus-parser.h nis_xdr.h nss \ +- $(wildcard rpcsvc/*.[hx]) ++ nisplus-parser.h nis_xdr.h nss + + # These are the databases available for the nis (and perhaps later nisplus) + # service. This must be a superset of the services in nss. +-- +1.7.5.4 + diff --git a/multilib-staging/lib32-glibc/glibc-2.14-revert-4768ae77.patch b/multilib-staging/lib32-glibc/glibc-2.14-revert-4768ae77.patch new file mode 100644 index 000000000..11f087cb7 --- /dev/null +++ b/multilib-staging/lib32-glibc/glibc-2.14-revert-4768ae77.patch @@ -0,0 +1,37 @@ +diff -Naur glibc-orig//resolv/res_send.c glibc/resolv/res_send.c +--- glibc-orig//resolv/res_send.c 2011-06-10 18:59:03.041436996 +1000 ++++ glibc/resolv/res_send.c 2011-06-10 19:08:09.379309323 +1000 +@@ -549,7 +549,7 @@ + ns, ansp, ansp2, nansp2, resplen2); + if (n < 0) + return (-1); +- if (n == 0 && (buf2 == NULL || *resplen2 == 0)) ++ if (n == 0) + goto next_ns; + } else { + /* Use datagrams. */ +@@ -559,7 +559,7 @@ + ansp2, nansp2, resplen2); + if (n < 0) + return (-1); +- if (n == 0 && (buf2 == NULL || *resplen2 == 0)) ++ if (n == 0) + goto next_ns; + if (v_circuit) + // XXX Check whether both requests failed or +@@ -1275,14 +1275,10 @@ + (*thisresplenp > *thisanssizp) + ? *thisanssizp : *thisresplenp); + +- if (recvresp1 || (buf2 != NULL && recvresp2)) { +- *resplen2 = 0; ++ if (recvresp1 || (buf2 != NULL && recvresp2)) + return resplen; +- } + if (buf2 != NULL) + { +- /* No data from the first reply. */ +- resplen = 0; + /* We are waiting for a possible second reply. */ + if (hp->id == anhp->id) + recvresp1 = 1; diff --git a/multilib-staging/lib32-glibc/glibc-2.15-lddebug-scopes.patch b/multilib-staging/lib32-glibc/glibc-2.15-lddebug-scopes.patch new file mode 100644 index 000000000..808cf8d7c --- /dev/null +++ b/multilib-staging/lib32-glibc/glibc-2.15-lddebug-scopes.patch @@ -0,0 +1,27 @@ +From 0c95ab64cb4ec0d22bb222647d9d20c7b4903e38 Mon Sep 17 00:00:00 2001 +From: Andreas Schwab <schwab@redhat.com> +Date: Fri, 7 Oct 2011 09:31:27 +0200 +Subject: [PATCH] Horrible workaround for horribly broken software + +--- + elf/rtld.c | 4 +++- + 1 files changed, 3 insertions(+), 1 deletions(-) + +diff --git a/elf/rtld.c b/elf/rtld.c +index 978c609..8422b9f 100644 +--- a/elf/rtld.c ++++ b/elf/rtld.c +@@ -1393,7 +1393,9 @@ of this helper program; chances are you did not intend to run this program.\n\ + char *copy = malloc (len); + if (copy == NULL) + _dl_fatal_printf ("out of memory\n"); +- l->l_libname->name = l->l_name = memcpy (copy, dsoname, len); ++ l->l_libname->name = memcpy (copy, dsoname, len); ++ if (GLRO(dl_debug_mask)) ++ l->l_name = copy; + } + + /* Add the vDSO to the object list. */ +-- +1.7.3.4 + diff --git a/multilib-staging/lib32-glibc/glibc-2.15-math64crash.patch b/multilib-staging/lib32-glibc/glibc-2.15-math64crash.patch new file mode 100644 index 000000000..d315bf266 --- /dev/null +++ b/multilib-staging/lib32-glibc/glibc-2.15-math64crash.patch @@ -0,0 +1,184 @@ +diff --git a/sysdeps/x86_64/fpu/multiarch/Makefile b/sysdeps/x86_64/fpu/multiarch/Makefile +index be68903..a032da8 100644 +--- a/sysdeps/x86_64/fpu/multiarch/Makefile ++++ b/sysdeps/x86_64/fpu/multiarch/Makefile +@@ -1,5 +1,5 @@ + ifeq ($(subdir),math) +-libm-sysdep_routines += s_floor-c s_ceil-c s_floorf-c s_ceilf-c \ ++libm-sysdep_routines += s_floorf-c s_ceilf-c \ + s_rint-c s_rintf-c s_nearbyint-c s_nearbyintf-c + + ifeq ($(have-mfma4),yes) +diff --git a/sysdeps/x86_64/fpu/multiarch/s_ceil-c.c b/sysdeps/x86_64/fpu/multiarch/s_ceil-c.c +deleted file mode 100644 +index 6a5ea3f..0000000 +--- a/sysdeps/x86_64/fpu/multiarch/s_ceil-c.c ++++ /dev/null +@@ -1,2 +0,0 @@ +-#define __ceil __ceil_c +-#include <sysdeps/ieee754/dbl-64/wordsize-64/s_ceil.c> +diff --git a/sysdeps/x86_64/fpu/multiarch/s_ceil.S b/sysdeps/x86_64/fpu/multiarch/s_ceil.S +deleted file mode 100644 +index d0f8da3..0000000 +--- a/sysdeps/x86_64/fpu/multiarch/s_ceil.S ++++ /dev/null +@@ -1,40 +0,0 @@ +-/* Copyright (C) 2011 Free Software Foundation, Inc. +- This file is part of the GNU C Library. +- Contributed by Ulrich Drepper <drepper@gmail.come>, 2011. +- +- The GNU C 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.1 of the License, or (at your option) any later version. +- +- The GNU C 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 the GNU C Library; if not, write to the Free +- Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA +- 02111-1307 USA. */ +- +-#include <machine/asm.h> +-#include <init-arch.h> +- +- +-ENTRY(__ceil) +- .type __ceil, @gnu_indirect_function +- call __get_cpu_features@plt +- movq %rax, %rdx +- leaq __ceil_sse41(%rip), %rax +- testl $bit_SSE4_1, CPUID_OFFSET+index_SSE4_1(%rdx) +- jnz 2f +- leaq __ceil_c(%rip), %rax +-2: ret +-END(__ceil) +-weak_alias (__ceil, ceil) +- +- +-ENTRY(__ceil_sse41) +- roundsd $2, %xmm0, %xmm0 +- ret +-END(__ceil_sse41) +diff --git a/sysdeps/x86_64/fpu/multiarch/s_floor-c.c b/sysdeps/x86_64/fpu/multiarch/s_floor-c.c +deleted file mode 100644 +index 68733b6..0000000 +--- a/sysdeps/x86_64/fpu/multiarch/s_floor-c.c ++++ /dev/null +@@ -1,3 +0,0 @@ +-#undef __floor +-#define __floor __floor_c +-#include <sysdeps/ieee754/dbl-64/wordsize-64/s_floor.c> +diff --git a/sysdeps/x86_64/fpu/multiarch/s_floor.S b/sysdeps/x86_64/fpu/multiarch/s_floor.S +deleted file mode 100644 +index 514ea95..0000000 +--- a/sysdeps/x86_64/fpu/multiarch/s_floor.S ++++ /dev/null +@@ -1,40 +0,0 @@ +-/* Copyright (C) 2011 Free Software Foundation, Inc. +- This file is part of the GNU C Library. +- Contributed by Ulrich Drepper <drepper@gmail.come>, 2011. +- +- The GNU C 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.1 of the License, or (at your option) any later version. +- +- The GNU C 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 the GNU C Library; if not, write to the Free +- Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA +- 02111-1307 USA. */ +- +-#include <machine/asm.h> +-#include <init-arch.h> +- +- +-ENTRY(__floor) +- .type __floor, @gnu_indirect_function +- call __get_cpu_features@plt +- movq %rax, %rdx +- leaq __floor_sse41(%rip), %rax +- testl $bit_SSE4_1, CPUID_OFFSET+index_SSE4_1(%rdx) +- jnz 2f +- leaq __floor_c(%rip), %rax +-2: ret +-END(__floor) +-weak_alias (__floor, floor) +- +- +-ENTRY(__floor_sse41) +- roundsd $1, %xmm0, %xmm0 +- ret +-END(__floor_sse41) +diff --git a/sysdeps/x86_64/fpu/multiarch/s_sin.c b/sysdeps/x86_64/fpu/multiarch/s_sin.c +deleted file mode 100644 +index 1ba9dbc..0000000 +--- a/sysdeps/x86_64/fpu/multiarch/s_sin.c ++++ /dev/null +@@ -1,31 +0,0 @@ +-#if defined HAVE_FMA4_SUPPORT || defined HAVE_AVX_SUPPORT +-# include <init-arch.h> +-# include <math.h> +-# undef NAN +- +-extern double __cos_sse2 (double); +-extern double __sin_sse2 (double); +-extern double __cos_avx (double); +-extern double __sin_avx (double); +-# ifdef HAVE_FMA4_SUPPORT +-extern double __cos_fma4 (double); +-extern double __sin_fma4 (double); +-# else +-# undef HAS_FMA4 +-# define HAS_FMA4 0 +-# define __cos_fma4 ((void *) 0) +-# define __sin_fma4 ((void *) 0) +-# endif +- +-libm_ifunc (__cos, HAS_FMA4 ? __cos_fma4 : HAS_AVX ? __cos_avx : __cos_sse2); +-weak_alias (__cos, cos) +- +-libm_ifunc (__sin, HAS_FMA4 ? __sin_fma4 : HAS_AVX ? __sin_avx : __sin_sse2); +-weak_alias (__sin, sin) +- +-# define __cos __cos_sse2 +-# define __sin __sin_sse2 +-#endif +- +- +-#include <sysdeps/ieee754/dbl-64/s_sin.c> +diff --git a/sysdeps/x86_64/fpu/multiarch/s_tan.c b/sysdeps/x86_64/fpu/multiarch/s_tan.c +deleted file mode 100644 +index 8f6601e..0000000 +--- a/sysdeps/x86_64/fpu/multiarch/s_tan.c ++++ /dev/null +@@ -1,21 +0,0 @@ +-#if defined HAVE_FMA4_SUPPORT || defined HAVE_AVX_SUPPORT +-# include <init-arch.h> +-# include <math.h> +- +-extern double __tan_sse2 (double); +-extern double __tan_avx (double); +-# ifdef HAVE_FMA4_SUPPORT +-extern double __tan_fma4 (double); +-# else +-# undef HAS_FMA4 +-# define HAS_FMA4 0 +-# define __tan_fma4 ((void *) 0) +-# endif +- +-libm_ifunc (tan, HAS_FMA4 ? __tan_fma4 : HAS_AVX ? __tan_avx : __tan_sse2); +- +-# define tan __tan_sse2 +-#endif +- +- +-#include <sysdeps/ieee754/dbl-64/s_tan.c> diff --git a/multilib-staging/lib32-glibc/glibc-2.15-revert-c5a0802a.patch b/multilib-staging/lib32-glibc/glibc-2.15-revert-c5a0802a.patch new file mode 100644 index 000000000..f532b95e8 --- /dev/null +++ b/multilib-staging/lib32-glibc/glibc-2.15-revert-c5a0802a.patch @@ -0,0 +1,229 @@ +diff -rup a/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S b/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S +--- a/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S 2011-12-22 18:04:12.937212834 +0000 ++++ b/nptl/sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S 2011-12-22 18:04:42.104222278 +0000 +@@ -137,7 +137,6 @@ __pthread_cond_wait: + cmpl $PI_BIT, %eax + jne 18f + +-90: + movl $(FUTEX_WAIT_REQUEUE_PI|FUTEX_PRIVATE_FLAG), %ecx + movl %ebp, %edx + xorl %esi, %esi +@@ -151,9 +150,6 @@ __pthread_cond_wait: + sete 16(%esp) + je 19f + +- cmpl $-EAGAIN, %eax +- je 91f +- + /* Normal and PI futexes dont mix. Use normal futex functions only + if the kernel does not support the PI futex functions. */ + cmpl $-ENOSYS, %eax +@@ -398,78 +394,6 @@ __pthread_cond_wait: + #endif + call __lll_unlock_wake + jmp 11b +- +-91: +-.LcleanupSTART2: +- /* FUTEX_WAIT_REQUEUE_PI returned EAGAIN. We need to +- call it again. */ +- +- /* Get internal lock. */ +- movl $1, %edx +- xorl %eax, %eax +- LOCK +-#if cond_lock == 0 +- cmpxchgl %edx, (%ebx) +-#else +- cmpxchgl %edx, cond_lock(%ebx) +-#endif +- jz 92f +- +-#if cond_lock == 0 +- movl %ebx, %edx +-#else +- leal cond_lock(%ebx), %edx +-#endif +-#if (LLL_SHARED-LLL_PRIVATE) > 255 +- xorl %ecx, %ecx +-#endif +- cmpl $-1, dep_mutex(%ebx) +- setne %cl +- subl $1, %ecx +- andl $(LLL_SHARED-LLL_PRIVATE), %ecx +-#if LLL_PRIVATE != 0 +- addl $LLL_PRIVATE, %ecx +-#endif +- call __lll_lock_wait +- +-92: +- /* Increment the cond_futex value again, so it can be used as a new +- expected value. */ +- addl $1, cond_futex(%ebx) +- movl cond_futex(%ebx), %ebp +- +- /* Unlock. */ +- LOCK +-#if cond_lock == 0 +- subl $1, (%ebx) +-#else +- subl $1, cond_lock(%ebx) +-#endif +- je 93f +-#if cond_lock == 0 +- movl %ebx, %eax +-#else +- leal cond_lock(%ebx), %eax +-#endif +-#if (LLL_SHARED-LLL_PRIVATE) > 255 +- xorl %ecx, %ecx +-#endif +- cmpl $-1, dep_mutex(%ebx) +- setne %cl +- subl $1, %ecx +- andl $(LLL_SHARED-LLL_PRIVATE), %ecx +-#if LLL_PRIVATE != 0 +- addl $LLL_PRIVATE, %ecx +-#endif +- call __lll_unlock_wake +- +-93: +- /* Set the rest of SYS_futex args for FUTEX_WAIT_REQUEUE_PI. */ +- xorl %ecx, %ecx +- movl dep_mutex(%ebx), %edi +- jmp 90b +-.LcleanupEND2: +- + .size __pthread_cond_wait, .-__pthread_cond_wait + versioned_symbol (libpthread, __pthread_cond_wait, pthread_cond_wait, + GLIBC_2_3_2) +@@ -642,10 +566,6 @@ __condvar_w_cleanup: + .long .LcleanupEND-.Lsub_cond_futex + .long __condvar_w_cleanup-.LSTARTCODE + .uleb128 0 +- .long .LcleanupSTART2-.LSTARTCODE +- .long .LcleanupEND2-.LcleanupSTART2 +- .long __condvar_w_cleanup-.LSTARTCODE +- .uleb128 0 + .long .LcallUR-.LSTARTCODE + .long .LENDCODE-.LcallUR + .long 0 +Only in b/nptl/sysdeps/unix/sysv/linux/i386/i486: pthread_cond_wait.S.orig +diff -rup a/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S b/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S +--- a/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S 2011-12-22 18:04:12.941212837 +0000 ++++ b/nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S 2011-12-22 18:05:05.155229737 +0000 +@@ -23,7 +23,6 @@ + #include <lowlevelcond.h> + #include <tcb-offsets.h> + #include <pthread-pi-defines.h> +-#include <pthread-errnos.h> + + #include <kernel-features.h> + +@@ -137,14 +136,11 @@ __pthread_cond_wait: + cmpl $PI_BIT, %eax + jne 61f + +-90: + movl $(FUTEX_WAIT_REQUEUE_PI|FUTEX_PRIVATE_FLAG), %esi + movl $SYS_futex, %eax + syscall + + movl $1, %r8d +- cmpq $-EAGAIN, %rax +- je 91f + #ifdef __ASSUME_REQUEUE_PI + jmp 62f + #else +@@ -331,70 +327,6 @@ __pthread_cond_wait: + + 13: movq %r10, %rax + jmp 14b +- +-91: +-.LcleanupSTART2: +- /* FUTEX_WAIT_REQUEUE_PI returned EAGAIN. We need to +- call it again. */ +- movq 8(%rsp), %rdi +- +- /* Get internal lock. */ +- movl $1, %esi +- xorl %eax, %eax +- LOCK +-#if cond_lock == 0 +- cmpxchgl %esi, (%rdi) +-#else +- cmpxchgl %esi, cond_lock(%rdi) +-#endif +- jz 92f +- +-#if cond_lock != 0 +- addq $cond_lock, %rdi +-#endif +- cmpq $-1, dep_mutex-cond_lock(%rdi) +- movl $LLL_PRIVATE, %eax +- movl $LLL_SHARED, %esi +- cmovne %eax, %esi +- callq __lll_lock_wait +-#if cond_lock != 0 +- subq $cond_lock, %rdi +-#endif +-92: +- /* Increment the cond_futex value again, so it can be used as a new +- expected value. */ +- incl cond_futex(%rdi) +- movl cond_futex(%rdi), %edx +- +- /* Release internal lock. */ +- LOCK +-#if cond_lock == 0 +- decl (%rdi) +-#else +- decl cond_lock(%rdi) +-#endif +- jz 93f +- +-#if cond_lock != 0 +- addq $cond_lock, %rdi +-#endif +- cmpq $-1, dep_mutex-cond_lock(%rdi) +- movl $LLL_PRIVATE, %eax +- movl $LLL_SHARED, %esi +- cmovne %eax, %esi +- /* The call preserves %rdx. */ +- callq __lll_unlock_wake +-#if cond_lock != 0 +- subq $cond_lock, %rdi +-#endif +-93: +- /* Set the rest of SYS_futex args for FUTEX_WAIT_REQUEUE_PI. */ +- xorq %r10, %r10 +- movq dep_mutex(%rdi), %r8 +- leaq cond_futex(%rdi), %rdi +- jmp 90b +-.LcleanupEND2: +- + .size __pthread_cond_wait, .-__pthread_cond_wait + versioned_symbol (libpthread, __pthread_cond_wait, pthread_cond_wait, + GLIBC_2_3_2) +@@ -547,15 +479,11 @@ __condvar_cleanup1: + .uleb128 .LcleanupSTART-.LSTARTCODE + .uleb128 .LcleanupEND-.LcleanupSTART + .uleb128 __condvar_cleanup1-.LSTARTCODE +- .uleb128 0 +- .uleb128 .LcleanupSTART2-.LSTARTCODE +- .uleb128 .LcleanupEND2-.LcleanupSTART2 +- .uleb128 __condvar_cleanup1-.LSTARTCODE +- .uleb128 0 ++ .uleb128 0 + .uleb128 .LcallUR-.LSTARTCODE + .uleb128 .LENDCODE-.LcallUR + .uleb128 0 +- .uleb128 0 ++ .uleb128 0 + .Lcstend: + + +Only in b/nptl/sysdeps/unix/sysv/linux/x86_64: pthread_cond_wait.S.orig +Only in b/nptl/sysdeps/unix/sysv/linux/x86_64: pthread_cond_wait.S.rej diff --git a/multilib-staging/lib32-glibc/glibc-__i686.patch b/multilib-staging/lib32-glibc/glibc-__i686.patch new file mode 100644 index 000000000..28d5dd424 --- /dev/null +++ b/multilib-staging/lib32-glibc/glibc-__i686.patch @@ -0,0 +1,13 @@ +diff -Naur glibc-old//sysdeps/i386/Makefile glibc//sysdeps/i386/Makefile +--- glibc-old//sysdeps/i386/Makefile 2010-03-18 11:52:30.000000000 +1000 ++++ glibc//sysdeps/i386/Makefile 2010-04-16 15:05:50.000000000 +1000 +@@ -1,6 +1,7 @@ + # The mpn functions need a #define for asm syntax flavor. +-# Every i386 port in use uses gas syntax (I think). +-asm-CPPFLAGS += -DGAS_SYNTAX ++# Every i386 port in use uses gas syntax (I think). Don't replace ++# __i686 in __i686.get_pc_thunk.bx. ++asm-CPPFLAGS += -DGAS_SYNTAX -U __i686 + + # The i386 `long double' is a distinct type we support. + long-double-fcts = yes diff --git a/multilib-staging/lib32-glibc/lib32-glibc.conf b/multilib-staging/lib32-glibc/lib32-glibc.conf new file mode 100644 index 000000000..9b08c3f43 --- /dev/null +++ b/multilib-staging/lib32-glibc/lib32-glibc.conf @@ -0,0 +1 @@ +/usr/lib32 diff --git a/multilib-staging/lib32-gtk2/PKGBUILD b/multilib-staging/lib32-gtk2/PKGBUILD new file mode 100644 index 000000000..b9c9036ca --- /dev/null +++ b/multilib-staging/lib32-gtk2/PKGBUILD @@ -0,0 +1,57 @@ +# $Id: PKGBUILD 62043 2012-01-14 23:45:58Z bluewind $ +# Maintainer: Ionut Biru <ibiru@archlinux.org +# Contributor: Pierre Schmitz <pierre@archlinux.de> +# Contributor: Mikko Seppälä <t-r-a-y@mbnet.fi> + +_pkgbasename=gtk2 +pkgname=lib32-$_pkgbasename +pkgver=2.24.8 +pkgrel=2 +pkgdesc="The GTK+ Toolkit (v2) (32-bit)" +arch=('x86_64') +url="http://www.gtk.org/" +install=gtk2.install +depends=(lib32-{'atk>=1.30.0','pango>=1.28.0','cairo>=1.10.0','gdk-pixbuf2>=2.22.1'} + lib32-lib{'cups>=1.4.4',xcursor,'xrandr>=1.3','xi>=1.3',xinerama,xcomposite,xdamage} + $_pkgbasename) +makedepends=('pkgconfig' 'gcc-multilib') +options=('!libtool' '!docs') +license=('LGPL') +source=(http://ftp.gnome.org/pub/gnome/sources/gtk+/2.24/gtk+-${pkgver}.tar.xz + xid-collision-debug.patch + gtk-modules-32.patch) +sha256sums=('8a3b29f667933cf52eea2db7b066723edbc80443ca9c75b7cd7cbe8c8b90b93c' + 'd758bb93e59df15a4ea7732cf984d1c3c19dff67c94b957575efea132b8fe558' + '2effb13404442ae266d4c663347e88cd1ca19e9a83b452da1743bac16af9c7b0') + +build() { + export CC="gcc -m32" + export CXX="g++ -m32" + export PKG_CONFIG_PATH="/usr/lib32/pkgconfig" + + cd "${srcdir}/gtk+-${pkgver}" + patch -Np1 -i "${srcdir}/xid-collision-debug.patch" + patch -p1 -i ${srcdir}/gtk-modules-32.patch + + CXX=/bin/false ./configure --prefix=/usr \ + --sysconfdir=/etc \ + --localstatedir=/var \ + --libdir=/usr/lib32 \ + --with-xinput=yes + + #https://bugzilla.gnome.org/show_bug.cgi?id=655517 + sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool + + make +} + +package() { + cd "${srcdir}/gtk+-${pkgver}" + make DESTDIR="${pkgdir}" install + rm -rf "${pkgdir}"/etc + rm -rf "${pkgdir}"/usr/{include,share} + + cd "${pkgdir}"/usr/bin + mv gtk-query-immodules-2.0 gtk-query-immodules-2.0-32 + rm -f gtk-builder-convert gtk-demo gtk-update-icon-cache +} diff --git a/multilib-staging/lib32-gtk2/gtk-modules-32.patch b/multilib-staging/lib32-gtk2/gtk-modules-32.patch new file mode 100644 index 000000000..a2530c3bf --- /dev/null +++ b/multilib-staging/lib32-gtk2/gtk-modules-32.patch @@ -0,0 +1,12 @@ +diff -ur gtk+-2.20.1/gtk/gtkrc.c gtk+-2.20.1-32/gtk/gtkrc.c +--- gtk+-2.20.1/gtk/gtkrc.c 2010-05-03 01:28:21.000000000 +0200 ++++ gtk+-2.20.1-32/gtk/gtkrc.c 2010-08-26 07:22:42.316920033 +0200 +@@ -450,7 +450,7 @@ + if (im_module_file) + result = g_strdup (im_module_file); + else +- result = g_build_filename (GTK_SYSCONFDIR, "gtk-2.0", "gtk.immodules", NULL); ++ result = g_build_filename (GTK_SYSCONFDIR, "gtk-2.0", "gtk.immodules-32", NULL); + } + + return result; diff --git a/multilib-staging/lib32-gtk2/gtk2.install b/multilib-staging/lib32-gtk2/gtk2.install new file mode 100644 index 000000000..49f86f550 --- /dev/null +++ b/multilib-staging/lib32-gtk2/gtk2.install @@ -0,0 +1,16 @@ +post_install() { + GTK_PATH=/usr/lib32/gtk-2.0 usr/bin/gtk-query-immodules-2.0-32 > etc/gtk-2.0/gtk.immodules-32 +} + +pre_upgrade() { + pre_remove +} + +post_upgrade() { + post_install +} + +pre_remove() { + rm -f etc/gtk-2.0/gtk.immodules-32 &>/dev/null + rm -f etc/gtk-2.0/gdk-pixbuf.loaders-32 &>/dev/null +} diff --git a/multilib-staging/lib32-gtk2/xid-collision-debug.patch b/multilib-staging/lib32-gtk2/xid-collision-debug.patch new file mode 100644 index 000000000..d61238c3b --- /dev/null +++ b/multilib-staging/lib32-gtk2/xid-collision-debug.patch @@ -0,0 +1,15 @@ +--- gtk+-2.18.3/gdk/x11/gdkxid.c 2009-06-19 04:59:18.000000000 +0200 ++++ gtk+-2.18.3/gdk/x11/gdkxid.c.new 2009-07-22 11:30:12.000000000 +0200 +@@ -56,10 +56,10 @@ + if (!display_x11->xid_ht) + display_x11->xid_ht = g_hash_table_new ((GHashFunc) gdk_xid_hash, + (GEqualFunc) gdk_xid_equal); +- ++/* + if (g_hash_table_lookup (display_x11->xid_ht, xid)) + g_warning ("XID collision, trouble ahead"); +- ++*/ + g_hash_table_insert (display_x11->xid_ht, xid, data); + } + diff --git a/multilib-staging/lib32-pango/PKGBUILD b/multilib-staging/lib32-pango/PKGBUILD new file mode 100644 index 000000000..aa0488509 --- /dev/null +++ b/multilib-staging/lib32-pango/PKGBUILD @@ -0,0 +1,44 @@ +# $Id: PKGBUILD 62049 2012-01-14 23:53:37Z heftig $ +# Contributor: Pierre Schmitz <pierre@archlinux.de> +# Contributor: Mikko Seppälä <t-r-a-y@mbnet.fi> +# Maintainer: Biru Ionut <ionut@archlinux.ro> +_pkgbasename=pango +pkgname=lib32-$_pkgbasename +pkgver=1.29.4 +pkgrel=2 +pkgdesc="A library for layout and rendering of text (32-bit)" +arch=('x86_64') +license=('LGPL') +depends=('lib32-glib2>=2.25.15' 'lib32-cairo>=1.10.0' 'lib32-libxft>=2.1.14' + 'lib32-freetype2>=2.4.2' $_pkgbasename) +makedepends=("gcc-multilib") +options=('!libtool' '!emptydirs') +install=pango.install +source=(http://ftp.gnome.org/pub/gnome/sources/${_pkgbasename}/1.29/${_pkgbasename}-${pkgver}.tar.xz + pango-modules-conffile.patch) +url="http://www.pango.org/" +sha256sums=('7ae8d1953e6098a2706df58c1f84555c06ace7006bb34c0e54ab9acd98c1127f' + '4a178b60dd420ae53baeabbecfaaeca4070a4b777b2b3f36d137cd70b5a270c3') + +build() { + export CC="gcc -m32" + export CXX="g++ -m32" + export PKG_CONFIG_PATH="/usr/lib32/pkgconfig" + + cd "${srcdir}/${_pkgbasename}-${pkgver}" + patch -p0 < ${srcdir}/pango-modules-conffile.patch + # No libthai support yet + ./configure --prefix=/usr --libdir=/usr/lib32 --sysconfdir=/etc \ + --localstatedir=/var --with-included-modules=basic-fc \ + --with-dynamic-modules=arabic-fc,arabic-lang,basic-fc,basic-win32,basic-x,basic-atsui,hangul-fc,hebrew-fc,indic-fc,indic-lang,khmer-fc,syriac-fc,tibetan-fc \ + --disable-introspection + make +} + +package() { + cd "${srcdir}/${_pkgbasename}-${pkgver}" + make DESTDIR="${pkgdir}" install + rm -rf "$pkgdir"/etc + rm -rf "$pkgdir"/usr/{bin/pango-view,share,include} + mv "$pkgdir"/usr/bin/pango-querymodules "$pkgdir"/usr/bin/pango-querymodules-32 +} diff --git a/multilib-staging/lib32-pango/pango-modules-conffile.patch b/multilib-staging/lib32-pango/pango-modules-conffile.patch new file mode 100644 index 000000000..a959cf1c8 --- /dev/null +++ b/multilib-staging/lib32-pango/pango-modules-conffile.patch @@ -0,0 +1,20 @@ +--- pango/modules.c.orig 2010-08-26 06:45:49.329259966 +0200 ++++ pango/modules.c 2010-08-26 06:46:13.786685177 +0200 +@@ -529,7 +529,7 @@ + + if (!file_str) + file_str = g_build_filename (pango_get_sysconf_subdirectory (), +- "pango.modules", ++ "pango.modules-32", + NULL); + + files = pango_split_file_list (file_str); +@@ -640,7 +640,7 @@ + if (!no_module_warning) + { + gchar *filename = g_build_filename (pango_get_sysconf_subdirectory (), +- "pango.modules", ++ "pango.modules-32", + NULL); + g_critical ("No modules found:\n" + "No builtin or dynamically loaded modules were found.\n" diff --git a/multilib-staging/lib32-pango/pango.install b/multilib-staging/lib32-pango/pango.install new file mode 100644 index 000000000..173b6820f --- /dev/null +++ b/multilib-staging/lib32-pango/pango.install @@ -0,0 +1,21 @@ +# arg 1: the new package version +post_install() { + # we need to ldconfig first, in case xfree86's libs aren't + # in ld.so.cache yet + sbin/ldconfig -r . + usr/bin/pango-querymodules-32 >etc/pango/pango.modules-32 +} + +# arg 1: the new package version +# arg 2: the old package version +post_upgrade() { + if [ -f etc/pango/pango.modules-32 ]; then + rm etc/pango/pango.modules-32 + fi + post_install $1 +} + +# arg 1: the old package version +pre_remove() { + rm etc/pango/pango.modules-32 +} diff --git a/multilib-staging/libtool-multilib/PKGBUILD b/multilib-staging/libtool-multilib/PKGBUILD new file mode 100644 index 000000000..abdc50ebc --- /dev/null +++ b/multilib-staging/libtool-multilib/PKGBUILD @@ -0,0 +1,73 @@ +# $Id: PKGBUILD 62034 2012-01-14 22:04:47Z heftig $ +# Maintainer: Jan "heftig" Steffens <jan.steffens@gmail.com> +# Contributor: Allan McRae <allan@archlinux.org> +# Contributor: judd <jvinet@zeroflux.org> + +# NOTE: requires rebuild with each new gcc version + +pkgbase=libtool-multilib +pkgname=(libtool-multilib lib32-libltdl) +pkgver=2.4.2 +pkgrel=2.1 +pkgdesc="A generic library support script for multilib" +arch=('x86_64') +url="http://www.gnu.org/software/libtool" +license=('GPL') +_gccver=4.6.2 +makedepends=("gcc-multilib=$_gccver") +options=('!libtool') +source=(ftp://ftp.gnu.org/pub/gnu/libtool/libtool-${pkgver}.tar.xz{,.sig}) +md5sums=('2ec8997e0c07249eb4cbd072417d70fe' + '1e6ba57420c82c663c85e745d11c7eed') + +build() { + cd "$srcdir" + + rm -rf libtool-64 libtool-32 + mv libtool-$pkgver libtool-64 + cp -a libtool-64 libtool-32 + + msg2 "Building libtool-64..." + cd "$srcdir/libtool-64" + ./configure --prefix=/usr + make + + msg2 "Building libtool-32..." + export CC="gcc -m32" + export CXX="g++ -m32" + + cd "$srcdir/libtool-32" + ./configure --prefix=/usr --libdir=/usr/lib32 + make +} + +check() { + cd "$srcdir/libtool-64" + make check + cd "$srcdir/libtool-32" + make check +} + +package_libtool-multilib() { + depends=('sh' "libltdl=$pkgver" 'tar' "gcc-multilib=$_gccver" "lib32-libltdl=$pkgver") + groups=('multilib-devel') + install=libtool.install + provides=("libtool=$pkgver-$pkgrel") + conflicts=(libtool) + + cd "$srcdir/libtool-64" + make DESTDIR=${pkgdir} install-binSCRIPTS install-man install-info \ + install-data-local + rm -rf ${pkgdir}/usr/share/libtool/libltdl/ +} + +package_lib32-libltdl() { + pkgdesc="A system independent dlopen wrapper for GNU libtool (32-bit)" + depends=(lib32-glibc libltdl) + replaces=(lib32-libtool) + provides=("lib32-libtool=$pkgver-$pkgrel") + conflicts=(lib32-libtool) + + cd "$srcdir/libtool-32" + make DESTDIR="$pkgdir" install-libLTLIBRARIES +} diff --git a/multilib-staging/libtool-multilib/libtool.install b/multilib-staging/libtool-multilib/libtool.install new file mode 100644 index 000000000..424c8cb88 --- /dev/null +++ b/multilib-staging/libtool-multilib/libtool.install @@ -0,0 +1,22 @@ +infodir=/usr/share/info +filelist=(libtool.info libtool.info-1 libtool.info-2) + +post_install() { + [ -x usr/bin/install-info ] || return 0 + for file in ${filelist[@]}; do + install-info $infodir/$file.gz $infodir/dir 2> /dev/null + done +} + +post_upgrade() { + post_install $1 +} + +pre_remove() { + [ -x usr/bin/install-info ] || return 0 + for file in ${filelist[@]}; do + install-info --delete $infodir/$file.gz $infodir/dir 2> /dev/null + done +} + +# vim:set ts=2 sw=2 et: diff --git a/testing/gmime/PKGBUILD b/testing/gmime/PKGBUILD new file mode 100644 index 000000000..0cd358ce6 --- /dev/null +++ b/testing/gmime/PKGBUILD @@ -0,0 +1,32 @@ +# $Id: PKGBUILD 146618 2012-01-14 12:24:08Z ibiru $ +# Maintainer: Jan de Groot <jgc@archlinux.org> +# Contributor: Ben <ben@benmazer.net> + +pkgname=gmime +pkgver=2.6.4 +pkgrel=1 +pkgdesc="Core mime parsing library" +arch=('i686' 'x86_64') +license=('GPL') +url="http://spruce.sourceforge.net/gmime/" +depends=('glib2' 'gpgme' 'zlib') +makedepends=('gtk-sharp-2') +options=('!libtool') +source=(http://ftp.gnome.org/pub/GNOME/sources/$pkgname/${pkgver%.*}/$pkgname-$pkgver.tar.xz) +sha256sums=('2e85076c223fe8bf1392a7c1affa4454cb3bb6dec83016ad6e3230c65533f163') + +build() { + # get rid of that .wapi errors in fakeroot + export MONO_SHARED_DIR="$srcdir/weird" + mkdir -p "$MONO_SHARED_DIR" + + cd "$srcdir/$pkgname-$pkgver" + + ./configure --prefix=/usr --disable-static + make +} + +package() { + cd "$srcdir/$pkgname-$pkgver" + make DESTDIR="$pkgdir" install +} diff --git a/testing/grilo-plugins/PKGBUILD b/testing/grilo-plugins/PKGBUILD new file mode 100644 index 000000000..ddf708f84 --- /dev/null +++ b/testing/grilo-plugins/PKGBUILD @@ -0,0 +1,39 @@ +# $Id: PKGBUILD 146620 2012-01-14 12:24:10Z ibiru $ +# Maintainer: Jan "heftig" Steffens <jan.steffens@gmail.com> + +pkgname=grilo-plugins +pkgver=0.1.18 +pkgrel=2 +pkgdesc="Plugins for Grilo" +url="http://www.gnome.org" +arch=('i686' 'x86_64') +license=('LGPL') +depends=('grilo') +makedepends=('gupnp-av' 'libgdata' 'libquvi' 'sqlite3' 'gmime' 'libgcrypt' + 'rest' 'libtracker-sparql') +optdepends=('gupnp-av: uPnP plugin' + 'libgdata: Youtube plugin' + 'libquvi: Youtube plugin' + 'sqlite3: Podcasts plugin' + 'gmime: Podcasts plugin' + 'sqlite3: Bookmarks plugin' + 'sqlite3: Metadata store plugin' + 'libgcrypt: Vimeo plugin' + 'rest: Blip.tv plugin' + 'libtracker-sparql: Tracker plugin') +options=('!libtool' '!emptydirs') +source=(http://ftp.gnome.org/pub/gnome/sources/${pkgname}/${pkgver%.*}/${pkgname}-${pkgver}.tar.xz) +sha256sums=('7e382f402119f4f270380627a2f49b30a6c43a47ecd645bf5ffe4e0cd99a1c79') + +build() { + cd "${srcdir}/${pkgname}-${pkgver}" + + ./configure --prefix=/usr --sysconfdir=/etc --disable-static \ + --enable-shoutcast + make +} + +package() { + cd "${srcdir}/${pkgname}-${pkgver}" + make DESTDIR="${pkgdir}" install +} diff --git a/testing/mail-notification/PKGBUILD b/testing/mail-notification/PKGBUILD new file mode 100644 index 000000000..1ed5fa7f0 --- /dev/null +++ b/testing/mail-notification/PKGBUILD @@ -0,0 +1,85 @@ +# $Id: PKGBUILD 146622 2012-01-14 12:24:17Z ibiru $ +# Maintainer: Roman Kyrylych <roman@archlinux.org> + +pkgname=mail-notification +pkgver=5.4 +pkgrel=10 +pkgdesc="Tray icon application that informs you if you have new mail" +arch=('i686' 'x86_64') +url="http://www.nongnu.org/mailnotify/" +license=('GPL3' 'FDL') +depends=('gmime' 'libnotify' 'gnome-keyring' 'hicolor-icon-theme' 'notification-daemon' 'libgnome') +makedepends=('gob2' 'intltool' 'evolution' 'gnome-doc-utils' 'gtk2') +options=('!libtool' '!emptydirs') +install=mail-notification.install +source=(http://savannah.nongnu.org/download/mailnotify-orig/${pkgname}-${pkgver}.tar.bz2 + dont-update-cache.patch + remove-ubuntu-special-case.patch + mail-notification-5.4-evolution.patch + mail-notification-5.4-sasl_encode64.patch + mail-notification-5.4-evolution-gtkhtml.patch + mail-notification-5.4-camel_headers.patch + mail-notification-5.4-icons.patch + mail-notification-5.4-weak.patch + mail-notification-5.4-popup-attach.patch + mail-notification-5.4-kde-trayicon.patch + mail-notification-5.4-evolution-3-0-support.patch + mail-notification-5.4-gtk3-support.patch + mail-notification-5.4-add-fallback-icon.patch + mail-notification-5.4-gmime.patch + mail-notification-5.4-libx11.patch) +md5sums=('c8dc33a61251acb5474e56eab6b18f43' + '6007bc30e789dab0a8282038e0335eb9' + '9cadd61bbd9c324b2916ec980231e0f2' + 'aa6f80820899f904c25988772f70ade9' + '125513ed059f62469377eb0ab794dbed' + 'c595a3962ab13a65be24a941e28faa9c' + 'f79939f593b2e8659e302df72c2b54b1' + '244b7ef2aec7656e8df390be87c10e2b' + '31bde95dfd39449959d8b3316f91429c' + 'cdead6a88d1779f69a5f40dc75d5cb84' + 'c7991b831834724eddc1c6802c3e06a6' + 'b370b1085ebb2814bd5d345a6d2b45ea' + '1ba948759110787dd57097cff157b75a' + '09df61b4dc29c676ac81ff9054e840ac' + '0944695e9b9b30f39028f85c83c6a7e2' + 'c3f643ef16aab3b4fe9ff5b333bff41a') + +build() { + cd "${srcdir}/${pkgname}-${pkgver}" + + patch -Np0 -i "${srcdir}/dont-update-cache.patch" + patch -Np0 -i "${srcdir}/remove-ubuntu-special-case.patch" + patch -Np1 -i "${srcdir}/mail-notification-5.4-evolution.patch" + patch -Np1 -i "${srcdir}/mail-notification-5.4-sasl_encode64.patch" + patch -Np1 -i "${srcdir}/mail-notification-5.4-evolution-gtkhtml.patch" + patch -Np1 -i "${srcdir}/mail-notification-5.4-camel_headers.patch" + patch -Np1 -i "${srcdir}/mail-notification-5.4-icons.patch" + patch -Np1 -i "${srcdir}/mail-notification-5.4-weak.patch" + patch -Np1 -i "${srcdir}/mail-notification-5.4-popup-attach.patch" + patch -Np1 -i "${srcdir}/mail-notification-5.4-kde-trayicon.patch" + patch -Np0 -i "${srcdir}/mail-notification-5.4-evolution-3-0-support.patch" + patch -Np0 -i "${srcdir}/mail-notification-5.4-gtk3-support.patch" + patch -Np0 -i "${srcdir}/mail-notification-5.4-add-fallback-icon.patch" + patch -Np1 -i "${srcdir}/mail-notification-5.4-gmime.patch" + patch -Np1 -i "${srcdir}/mail-notification-5.4-libx11.patch" + + gtk-builder-convert ui/mailbox-properties-dialog.glade ui/mailbox-properties-dialog.ui + gtk-builder-convert ui/properties-dialog.glade ui/properties-dialog.ui + + ./jb configure prefix=/usr sysconfdir=/etc \ + localstatedir=/var destdir="${pkgdir}" \ + gconf-schemas-dir=/etc/gconf/schemas install-gconf-schemas=no \ + cflags="${CFLAGS}" cppflags="${CXXFLAGS}" ldflags="${LDFLAGS}" \ + library-mode=0755 + ./jb build + GCONF_DISABLE_MAKEFILE_SCHEMA_INSTALL=1 ./jb install + + rm -f "${pkgdir}/usr/share/mail-notification/"*.glade + install -m644 ui/mailbox-properties-dialog.ui "${pkgdir}/usr/share/mail-notification/" + install -m644 ui/properties-dialog.ui "${pkgdir}/usr/share/mail-notification/" + + install -m755 -d "${pkgdir}/usr/share/gconf/schemas" + gconf-merge-schema ${pkgdir}/usr/share/gconf/schemas/${pkgname}.schemas --domain mail-notification ${pkgdir}/etc/gconf/schemas/*.schemas + rm -f ${pkgdir}/etc/gconf/schemas/*.schemas +} diff --git a/testing/mail-notification/dont-update-cache.patch b/testing/mail-notification/dont-update-cache.patch new file mode 100644 index 000000000..81216835e --- /dev/null +++ b/testing/mail-notification/dont-update-cache.patch @@ -0,0 +1,22 @@ +--- jbsrc/jb.c.~1~ 2008-03-20 16:53:02.000000000 +0100 ++++ jbsrc/jb.c 2008-03-26 20:51:45.641363619 +0100 +@@ -327,7 +327,6 @@ + jb_package_add_resources (void) + { + JBGroup *group; +- JBRule *rule; + JBObject *object; + + if (jb_variable_get_bool("compile-warnings")) +@@ -362,11 +361,6 @@ + if (jb_variable_get_bool("hotmail")) + jb_group_add_data_file(group, "hotmail.png", "$pkgdatadir"); + +- rule = jb_rule_new(); +- jb_rule_set_install_message(rule, "updating the GTK+ icon cache"); +- jb_rule_add_install_command(rule, "-gtk-update-icon-cache -f -t $datadir/icons/hicolor"); +- jb_group_add_resource(group, JB_GROUP_RESOURCE(rule)); +- + jb_group_add(group); + + /*** data ******************************************************************/ diff --git a/testing/mail-notification/mail-notification-5.4-add-fallback-icon.patch b/testing/mail-notification/mail-notification-5.4-add-fallback-icon.patch new file mode 100644 index 000000000..41c28e870 --- /dev/null +++ b/testing/mail-notification/mail-notification-5.4-add-fallback-icon.patch @@ -0,0 +1,16 @@ +--- src/mn-stock.c.orig 2011-02-17 17:42:39.886767087 +0100 ++++ src/mn-stock.c 2011-02-17 17:49:37.415541177 +0100 +@@ -86,6 +86,13 @@ + gtk_icon_source_set_icon_name(icon_source, icons[i].icon_name); + gtk_icon_set_add_source(icon_set, icon_source); + gtk_icon_source_free(icon_source); ++ ++ /* Add a fallback icon */ ++ icon_source = gtk_icon_source_new(); ++ gtk_icon_source_set_icon_name(icon_source, "mail-notification"); ++ gtk_icon_source_set_state_wildcarded(icon_source, TRUE); ++ gtk_icon_set_add_source(icon_set, icon_source); ++ gtk_icon_source_free(icon_source); + } + else if (icons[i].source_stock_id) + { diff --git a/testing/mail-notification/mail-notification-5.4-camel_headers.patch b/testing/mail-notification/mail-notification-5.4-camel_headers.patch new file mode 100644 index 000000000..861e3d215 --- /dev/null +++ b/testing/mail-notification/mail-notification-5.4-camel_headers.patch @@ -0,0 +1,36 @@ +diff -Nrbu mail-notification-5.4/build/src/mn-evolution-message.c mail-notification-5.4-OK/build/src/mn-evolution-message.c +--- mail-notification-5.4/build/src/mn-evolution-message.c 2008-05-22 19:47:51.000000000 +0400 ++++ mail-notification-5.4-OK/build/src/mn-evolution-message.c 2010-05-04 18:13:31.000000000 +0400 +@@ -25,7 +25,7 @@ + #line 24 "src/mn-evolution-message.gob" + + #include <glib/gi18n.h> +-#include <camel/camel-folder-summary.h> ++#include <camel/camel.h> + #include "mn-evolution-mailbox.h" + #include "mn-message-private.h" + #include "mn-evolution-client.h" +diff -Nrbu mail-notification-5.4/build/src/mn-evolution-server.c mail-notification-5.4-OK/build/src/mn-evolution-server.c +--- mail-notification-5.4/build/src/mn-evolution-server.c 2010-05-04 18:12:56.000000000 +0400 ++++ mail-notification-5.4-OK/build/src/mn-evolution-server.c 2010-05-04 18:13:39.000000000 +0400 +@@ -28,7 +28,7 @@ + #include <libintl.h> + #include <gobject/gvaluecollector.h> + #include <libedataserver/eds-version.h> +-#include <camel/camel-folder.h> ++#include <camel/camel.h> + #if EDS_CHECK_VERSION(2,29,0) + #include <shell/e-shell.h> + #include <mail/e-mail-browser.h> +diff -Nrbu mail-notification-5.4/src/mn-evolution-plugin.c mail-notification-5.4-OK/src/mn-evolution-plugin.c +--- mail-notification-5.4/src/mn-evolution-plugin.c 2010-05-04 18:12:56.000000000 +0400 ++++ mail-notification-5.4-OK/src/mn-evolution-plugin.c 2010-05-04 18:13:20.000000000 +0400 +@@ -24,7 +24,7 @@ + #include <dbus/dbus.h> + #include <dbus/dbus-glib-lowlevel.h> + #include <dbus/dbus-glib-bindings.h> +-#include <camel/camel-folder.h> ++#include <camel/camel.h> + #include <mail/em-event.h> + #include <mail/mail-tools.h> + #include "mn-evolution.h" diff --git a/testing/mail-notification/mail-notification-5.4-evolution-3-0-support.patch b/testing/mail-notification/mail-notification-5.4-evolution-3-0-support.patch new file mode 100644 index 000000000..51938b5fa --- /dev/null +++ b/testing/mail-notification/mail-notification-5.4-evolution-3-0-support.patch @@ -0,0 +1,122 @@ +--- jbsrc/lib/src/extras/jb-evolution-plugin.c.evolution30 2011-02-02 00:09:33.945696868 +0100 ++++ jbsrc/lib/src/extras/jb-evolution-plugin.c 2011-02-02 00:28:09.096275028 +0100 +@@ -41,7 +41,7 @@ + if (! minversion) + minversion = "2.12"; + +- packages = g_strdup_printf("evolution-plugin >= %s libgtkhtml-3.15 gtkhtml-editor-3.14", minversion); ++ packages = g_strdup_printf("evolution-plugin-3.0 >= %s libgtkhtml-4.0 gtkhtml-editor-4.0", minversion); + result = jb_check_packages("Evolution", "evolution-plugin", packages); + g_free(packages); + +@@ -53,7 +53,7 @@ + char *plugindir; + + jb_message_checking("for the Evolution plugin directory"); +- plugindir = jb_get_package_variable("evolution-plugin", "plugindir"); ++ plugindir = jb_get_package_variable("evolution-plugin-3.0", "plugindir"); + jb_message_result_string(plugindir ? plugindir : "not found"); + + if (! plugindir) +--- src/mn-evolution-plugin.c.orig 2011-02-09 00:07:37.422002566 +0100 ++++ src/mn-evolution-plugin.c 2011-02-09 00:12:43.652678682 +0100 +@@ -25,6 +25,7 @@ + #include <dbus/dbus-glib-lowlevel.h> + #include <dbus/dbus-glib-bindings.h> + #include <camel/camel.h> ++#include <libedataserver/eds-version.h> + #include <mail/em-event.h> + #include <mail/mail-tools.h> + #include "mn-evolution.h" +@@ -240,7 +241,11 @@ + EMEventTargetFolder *folder) + { + if (evo_server) ++#if EDS_CHECK_VERSION(3,1,0) ++ mn_evolution_server_folder_changed(evo_server, e_mail_folder_uri_build(folder->store, folder->folder_name)); ++#else + mn_evolution_server_folder_changed(evo_server, folder->uri); ++#endif + } + + void +@@ -249,10 +250,16 @@ + { + if (evo_server) + { +- char *url; ++#if EDS_CHECK_VERSION(2,91,0) ++ const char *url = camel_folder_get_uri(message->folder); ++#else ++ char *url = mail_tools_folder_to_url(message->folder); ++#endif + +- url = mail_tools_folder_to_url(message->folder); + mn_evolution_server_message_reading(evo_server, url); ++ ++#if !EDS_CHECK_VERSION(2,91,0) + g_free(url); ++#endif + } + } +--- build/src/mn-evolution-server.c.orig 2011-02-09 00:17:38.850944227 +0100 ++++ build/src/mn-evolution-server.c 2011-02-09 22:21:54.155346478 +0100 +@@ -496,11 +496,15 @@ + + if (! folder) + { +- folder = mail_tool_uri_to_folder(uri, 0, + #if EDS_CHECK_VERSION(2,91,0) +- NULL, ++ static EMailSession * session = NULL; ++ if (!session) ++ session = e_mail_session_new(); ++ ++ folder = e_mail_session_uri_to_folder_sync(session, uri, 0, NULL, NULL); ++#else ++ folder = mail_tool_uri_to_folder(uri, 0, NULL); + #endif +- NULL); + if (folder) + self_cache_folder(uri, folder); + else +@@ -677,7 +681,12 @@ + folder = self_lookup_folder(folder_uri, err); + if (folder) + { ++#if EDS_CHECK_VERSION(3,1,0) ++ *ret = g_strdup(camel_folder_get_display_name(folder)); ++#else + *ret = g_strdup(camel_folder_get_name(folder)); ++#endif ++ + #if EDS_CHECK_VERSION(2,31,0) + g_object_unref(folder); + #else +@@ -725,8 +734,12 @@ + shell = e_shell_get_default (); + shell_backend = e_shell_get_backend_by_name (shell, "mail"); + +- browser = e_mail_browser_new (shell_backend); ++ browser = e_mail_browser_new (E_MAIL_BACKEND(shell_backend)); ++#if EDS_CHECK_VERSION(3,1,0) ++ e_mail_reader_set_folder (E_MAIL_READER (browser), folder); ++#else + e_mail_reader_set_folder (E_MAIL_READER (browser), folder, folder_uri); ++#endif + e_mail_reader_set_message (E_MAIL_READER (browser), message_uid); + gtk_widget_show (browser); + #else +--- build/src/mn-evolution-folder-tree-server.c.orig 2011-06-17 22:01:49.226886994 +0200 ++++ build/src/mn-evolution-folder-tree-server.c 2011-06-18 00:34:23.046889847 +0200 +@@ -444,7 +444,9 @@ + { + #line 61 "src/mn-evolution-folder-tree-server.gob" + +-#if EDS_CHECK_VERSION(2,91,0) ++#if EDS_CHECK_VERSION(3,1,0) ++ selfp->tree = em_folder_tree_new(NULL, NULL); ++#elif EDS_CHECK_VERSION(2,91,0) + selfp->session = e_mail_session_new(); + selfp->tree = em_folder_tree_new(selfp->session); + #elif EDS_CHECK_VERSION(2,29,0) diff --git a/testing/mail-notification/mail-notification-5.4-evolution-gtkhtml.patch b/testing/mail-notification/mail-notification-5.4-evolution-gtkhtml.patch new file mode 100644 index 000000000..283ef36d6 --- /dev/null +++ b/testing/mail-notification/mail-notification-5.4-evolution-gtkhtml.patch @@ -0,0 +1,12 @@ +diff -Nrbu mail-notification-5.4/jbsrc/lib/src/extras/jb-evolution-plugin.c mail-notification-5.4-OK/jbsrc/lib/src/extras/jb-evolution-plugin.c +--- mail-notification-5.4/jbsrc/lib/src/extras/jb-evolution-plugin.c 2008-04-27 18:47:43.000000000 +0400 ++++ mail-notification-5.4-OK/jbsrc/lib/src/extras/jb-evolution-plugin.c 2009-08-21 19:48:22.000000000 +0400 +@@ -41,7 +41,7 @@ + if (! minversion) + minversion = "2.12"; + +- packages = g_strdup_printf("evolution-plugin >= %s", minversion); ++ packages = g_strdup_printf("evolution-plugin >= %s libgtkhtml-3.15 gtkhtml-editor-3.14", minversion); + result = jb_check_packages("Evolution", "evolution-plugin", packages); + g_free(packages); + diff --git a/testing/mail-notification/mail-notification-5.4-evolution.patch b/testing/mail-notification/mail-notification-5.4-evolution.patch new file mode 100644 index 000000000..87514c22d --- /dev/null +++ b/testing/mail-notification/mail-notification-5.4-evolution.patch @@ -0,0 +1,244 @@ +diff -Nrbu mail-notification-5.4/build/src/mn-evolution-folder-tree-server.c mail-notification-5.4-OK/build/src/mn-evolution-folder-tree-server.c +--- mail-notification-5.4/build/src/mn-evolution-folder-tree-server.c 2008-05-22 19:47:48.000000000 +0400 ++++ mail-notification-5.4-OK/build/src/mn-evolution-folder-tree-server.c 2010-10-12 16:50:15.000000000 +0400 +@@ -25,7 +25,10 @@ + #line 24 "src/mn-evolution-folder-tree-server.gob" + + #include <dbus/dbus.h> ++#include <libedataserver/eds-version.h> ++#if !EDS_CHECK_VERSION(2,29,0) + #include <mail/mail-component.h> ++#endif + #include <mail/em-folder-tree.h> + #include "mn-evolution-plugin.h" + #include "mn-evolution.h" +@@ -441,10 +444,17 @@ + { + #line 61 "src/mn-evolution-folder-tree-server.gob" + ++#if EDS_CHECK_VERSION(2,91,0) ++ selfp->session = e_mail_session_new(); ++ selfp->tree = em_folder_tree_new(selfp->session); ++#elif EDS_CHECK_VERSION(2,29,0) ++ selfp->tree = em_folder_tree_new(); ++#else + EMFolderTreeModel *model; + + model = mail_component_peek_tree_model(mail_component_peek()); + selfp->tree = em_folder_tree_new_with_model(model); ++#endif + + selfp->plug = gtk_plug_new((GdkNativeWindow) selfp->id); + gtk_container_add(GTK_CONTAINER(selfp->plug), selfp->tree); +@@ -469,6 +479,10 @@ + { + #line 80 "src/mn-evolution-folder-tree-server.gob" + ++#if EDS_CHECK_VERSION(2,91,0) ++ g_object_unref(selfp->session); ++ selfp->session = NULL; ++#endif + g_signal_handlers_disconnect_by_func(selfp->plug, self_plug_destroy_h, self); + }} + #line 475 "mn-evolution-folder-tree-server.c" +diff -Nrbu mail-notification-5.4/build/src/mn-evolution-server.c mail-notification-5.4-OK/build/src/mn-evolution-server.c +--- mail-notification-5.4/build/src/mn-evolution-server.c 2008-05-22 19:47:48.000000000 +0400 ++++ mail-notification-5.4-OK/build/src/mn-evolution-server.c 2010-10-12 16:50:40.000000000 +0400 +@@ -27,12 +27,22 @@ + #include <stdio.h> + #include <libintl.h> + #include <gobject/gvaluecollector.h> ++#include <libedataserver/eds-version.h> + #include <camel/camel-folder.h> ++#if EDS_CHECK_VERSION(2,29,0) ++#include <shell/e-shell.h> ++#include <mail/e-mail-browser.h> ++#else + #include <mail/em-folder-view.h> + #include <mail/em-format.h> + #include <mail/em-message-browser.h> ++#endif + #include <mail/em-utils.h> ++#if EDS_CHECK_VERSION(2,91,0) ++#include <mail/e-mail-session.h> ++#else + #include <mail/mail-session.h> ++#endif + #include <mail/mail-tools.h> + #include "mn-evolution.h" + #include "mn-evolution-folder-tree-server.h" +@@ -391,10 +397,18 @@ + info = g_new0(FolderInfo, 1); + info->uri = g_strdup(uri); + info->folder = folder; ++#if EDS_CHECK_VERSION(2,31,0) ++ g_object_ref(folder); ++#else + camel_object_ref(folder); ++#endif + + /* uncache the folder when it is deleted */ ++#if EDS_CHECK_VERSION(2,31,0) ++ g_signal_connect(folder, "deleted", G_CALLBACK(self_folder_deleted_cb), info); ++#else + camel_object_hook_event(folder, "deleted", self_folder_deleted_cb, info); ++#endif + + g_hash_table_replace(folders, info->uri, info); + }} +@@ -413,8 +427,13 @@ + { + #line 105 "src/mn-evolution-server.gob" + ++#if EDS_CHECK_VERSION(2,31,0) ++ g_signal_handlers_disconnect_by_func(info->folder, self_folder_deleted_cb, info); ++ g_object_unref(info->folder); ++#else + camel_object_unhook_event(info->folder, "deleted", self_folder_deleted_cb, info); + camel_object_unref(info->folder); ++#endif + g_free(info->uri); + g_free(info); + }} +@@ -461,7 +480,11 @@ + if (info) + { + folder = info->folder; ++#if EDS_CHECK_VERSION(2,31,0) ++ g_object_ref(folder); ++#else + camel_object_ref(folder); ++#endif + } + } + else +@@ -469,7 +492,11 @@ + + if (! folder) + { +- folder = mail_tool_uri_to_folder(uri, 0, NULL); ++ folder = mail_tool_uri_to_folder(uri, 0, ++#if EDS_CHECK_VERSION(2,91,0) ++ NULL, ++#endif ++ NULL); + if (folder) + self_cache_folder(uri, folder); + else +@@ -595,14 +622,23 @@ + + for (i = 0; i < summary->len; i++) + { ++#if EDS_CHECK_VERSION(2,23,5) ++ char *uid = summary->pdata[i]; ++ CamelMessageInfo *info = camel_folder_get_message_info(folder, uid); ++#else + CamelMessageInfo *info = summary->pdata[i]; ++#endif + + if ((camel_message_info_flags(info) & CAMEL_MESSAGE_SEEN) == 0) + g_ptr_array_add(*ret, self_camel_message_info_to_dbus_struct(info)); + } + + camel_folder_free_summary(folder, summary); ++#if EDS_CHECK_VERSION(2,31,0) ++ g_object_unref(folder); ++#else + camel_object_unref(folder); ++#endif + } + + GDK_THREADS_LEAVE(); +@@ -638,7 +674,11 @@ + if (folder) + { + *ret = g_strdup(camel_folder_get_name(folder)); ++#if EDS_CHECK_VERSION(2,31,0) ++ g_object_unref(folder); ++#else + camel_object_unref(folder); ++#endif + } + + GDK_THREADS_LEAVE(); +@@ -673,6 +713,19 @@ + folder = self_lookup_folder(folder_uri, err); + if (folder) + { ++#if EDS_CHECK_VERSION(2,29,0) ++ EShell *shell; ++ EShellBackend *shell_backend; ++ GtkWidget *browser; ++ ++ shell = e_shell_get_default (); ++ shell_backend = e_shell_get_backend_by_name (shell, "mail"); ++ ++ browser = e_mail_browser_new (shell_backend); ++ e_mail_reader_set_folder (E_MAIL_READER (browser), folder, folder_uri); ++ e_mail_reader_set_message (E_MAIL_READER (browser), message_uid); ++ gtk_widget_show (browser); ++#else + GtkWidget *browser; + + /* modelled after Evolution's handleuri_got_folder() */ +@@ -683,8 +736,13 @@ + em_folder_view_set_folder((EMFolderView *) browser, folder, folder_uri); + em_folder_view_set_message((EMFolderView *) browser, message_uid, FALSE); + gtk_widget_show(((EMMessageBrowser *) browser)->window); ++#endif + ++#if EDS_CHECK_VERSION(2,31,0) ++ g_object_unref(folder); ++#else + camel_object_unref(folder); ++#endif + } + + GDK_THREADS_LEAVE(); +@@ -721,7 +779,11 @@ + if (folder) + { + status = camel_folder_set_message_flags(folder, message_uid, flags, flags); ++#if EDS_CHECK_VERSION(2,31,0) ++ g_object_unref(folder); ++#else + camel_object_unref(folder); ++#endif + + if (! status) + g_set_error(err, +diff -Nrbu mail-notification-5.4/src/mn-evolution-plugin.c mail-notification-5.4-OK/src/mn-evolution-plugin.c +--- mail-notification-5.4/src/mn-evolution-plugin.c 2008-05-22 19:45:35.000000000 +0400 ++++ mail-notification-5.4-OK/src/mn-evolution-plugin.c 2010-10-12 16:50:15.000000000 +0400 +@@ -204,7 +204,7 @@ + } + + int +-e_plugin_lib_enable (EPluginLib *ep, int enable) ++e_plugin_lib_enable (EPlugin *ep, int enable) + { + static gboolean enabled = FALSE; + GError *err = NULL; +--- mail-notification-5.4/build/src/mn-evolution-folder-tree-server-private.h.orig 2010-11-13 13:55:01.571934066 +0100 ++++ mail-notification-5.4/build/src/mn-evolution-folder-tree-server-private.h 2010-11-13 13:56:07.019487418 +0100 +@@ -4,6 +4,10 @@ + #define __MN_EVOLUTION_FOLDER_TREE_SERVER_PRIVATE_H__ + + #include "mn-evolution-folder-tree-server.h" ++#include <libedataserver/eds-version.h> ++#if EDS_CHECK_VERSION(2,91,0) ++#include <mail/e-mail-session.h> ++#endif + + #ifdef __cplusplus + extern "C" { +@@ -23,6 +23,9 @@ + #line 41 "src/mn-evolution-folder-tree-server.gob" + GtkWidget * tree; + #line 26 "mn-evolution-folder-tree-server-private.h" ++#if EDS_CHECK_VERSION(2,91,0) ++ EMailSession * session; ++#endif + }; + + #ifdef __cplusplus diff --git a/testing/mail-notification/mail-notification-5.4-gmime.patch b/testing/mail-notification/mail-notification-5.4-gmime.patch new file mode 100644 index 000000000..5f516a46b --- /dev/null +++ b/testing/mail-notification/mail-notification-5.4-gmime.patch @@ -0,0 +1,63 @@ +diff -Nrbu mail-notification-5.4/build/src/mn-base-mbox-mailbox-backend.c mail-notification-5.4-OK/build/src/mn-base-mbox-mailbox-backend.c +--- mail-notification-5.4/build/src/mn-base-mbox-mailbox-backend.c 2008-12-23 14:48:49.000000000 +0300 ++++ mail-notification-5.4-OK/build/src/mn-base-mbox-mailbox-backend.c 2008-12-23 14:48:28.000000000 +0300 +@@ -265,7 +265,7 @@ + mime_message = g_mime_parser_construct_message(parser); + if (mime_message) + { +- if (g_mime_message_get_header(mime_message, "X-Mozilla-Status")) ++ if (g_mime_object_get_header(mime_message, "X-Mozilla-Status")) + { + #if WITH_MOZILLA + type = MN_TYPE_MOZILLA_MAILBOX_BACKEND; +diff -Nrbu mail-notification-5.4/build/src/mn-mozilla-mailbox-backend.c mail-notification-5.4-OK/build/src/mn-mozilla-mailbox-backend.c +--- mail-notification-5.4/build/src/mn-mozilla-mailbox-backend.c 2008-12-23 14:48:49.000000000 +0300 ++++ mail-notification-5.4-OK/build/src/mn-mozilla-mailbox-backend.c 2008-12-23 14:46:47.000000000 +0300 +@@ -167,7 +167,7 @@ + + const char *header; + +- header = g_mime_message_get_header(mime_message, header_name); ++ header = g_mime_object_get_header(mime_message, header_name); + if (header && mn_str_ishex(header)) + return strtol(header, NULL, 16); + else +diff -Nrbu mail-notification-5.4/jbsrc/jb.c mail-notification-5.4-OK/jbsrc/jb.c +--- mail-notification-5.4/jbsrc/jb.c 2008-05-22 19:47:04.000000000 +0400 ++++ mail-notification-5.4-OK/jbsrc/jb.c 2008-12-23 14:43:09.000000000 +0300 +@@ -166,7 +166,7 @@ + jb_require_packages("GNOME", "gnome", "glib-2.0 >= 2.14 gthread-2.0 gconf-2.0 >= 2.4.0 gtk+-2.0 >= 2.12 libgnomeui-2.0 >= 2.14.0 gnome-vfs-2.0 libglade-2.0 libxml-2.0 libnotify >= 0.4.1"); + jb_require_packages("D-Bus", "dbus", "dbus-glib-1"); + +- jb_check_packages_for_options("GMime", "gmime", "gmime-2.0 >= 2.2.7", ++ jb_check_packages_for_options("GMime", "gmime", "gmime-2.6", + "hotmail", + "imap", + "maildir", +diff -Nrbu mail-notification-5.4/src/mn-message-mime.c mail-notification-5.4-OK/src/mn-message-mime.c +--- mail-notification-5.4/src/mn-message-mime.c 2008-05-22 19:45:35.000000000 +0400 ++++ mail-notification-5.4-OK/src/mn-message-mime.c 2008-12-23 14:46:35.000000000 +0300 +@@ -33,12 +33,12 @@ + g_return_val_if_fail(GMIME_IS_MESSAGE(mime_message), FALSE); + + /* SpamAssassin */ +- spam = g_mime_message_get_header(mime_message, "X-Spam-Status"); ++ spam = g_mime_object_get_header(mime_message, "X-Spam-Status"); + if (spam && mn_ascii_str_case_has_prefix(spam, "yes")) + return TRUE; + + /* bogofilter */ +- spam = g_mime_message_get_header(mime_message, "X-Bogosity"); ++ spam = g_mime_object_get_header(mime_message, "X-Bogosity"); + if (spam && mn_ascii_str_case_has_prefix(spam, "yes")) + return TRUE; + +@@ -89,7 +89,7 @@ + { + const char *status; + +- status = g_mime_message_get_header(mime_message, "Status"); ++ status = g_mime_object_get_header(mime_message, "Status"); + if (status && strchr(status, 'R')) + return NULL; /* the message was read */ + else if (status && strchr(status, 'O')) diff --git a/testing/mail-notification/mail-notification-5.4-gtk3-support.patch b/testing/mail-notification/mail-notification-5.4-gtk3-support.patch new file mode 100644 index 000000000..6a29f8622 --- /dev/null +++ b/testing/mail-notification/mail-notification-5.4-gtk3-support.patch @@ -0,0 +1,1416 @@ +--- build/src/mn-dialog.c.orig 2011-02-02 23:08:09.816659245 +0100 ++++ build/src/mn-dialog.c 2011-02-02 23:09:16.988113774 +0100 +@@ -106,8 +106,7 @@ + #line 27 "src/mn-dialog.gob" + + gtk_container_set_border_width(GTK_CONTAINER(self), 5); +- gtk_dialog_set_has_separator(GTK_DIALOG(self), FALSE); +- gtk_box_set_spacing(GTK_BOX(GTK_DIALOG(self)->vbox), 2); ++ gtk_box_set_spacing(GTK_BOX(gtk_dialog_get_content_area(GTK_DIALOG(self))), 2); + + #line 113 "mn-dialog.c" + } +--- jbsrc/jb.c.orig 2011-02-02 23:40:33.567924712 +0100 ++++ jbsrc/jb.c 2011-02-02 23:39:39.680803618 +0100 +@@ -163,7 +163,7 @@ + { + jb_check_glibc(); + +- jb_require_packages("GNOME", "gnome", "glib-2.0 >= 2.14 gthread-2.0 gconf-2.0 >= 2.4.0 gtk+-2.0 >= 2.12 libgnomeui-2.0 >= 2.14.0 gnome-vfs-2.0 libglade-2.0 libxml-2.0 libnotify >= 0.4.1"); ++ jb_require_packages("GNOME", "gnome", "glib-2.0 >= 2.14 gthread-2.0 gconf-2.0 >= 2.4.0 gtk+-3.0 libgnome-2.0 >= 2.14.0 gnome-vfs-2.0 libxml-2.0 libnotify >= 0.4.1"); + jb_require_packages("D-Bus", "dbus", "dbus-glib-1"); + + jb_check_packages_for_options("GMime", "gmime", "gmime-2.6", +--- build/src/mn-file-chooser-button.c.orig 2011-02-02 23:38:01.503049512 +0100 ++++ build/src/mn-file-chooser-button.c 2011-02-02 23:38:16.988222034 +0100 +@@ -358,7 +358,7 @@ + g_signal_connect(selfp->dialog, "response", G_CALLBACK(self_response_h), self); + } + +- if (! GTK_WIDGET_VISIBLE(selfp->dialog)) ++ if (! gtk_widget_get_visible(selfp->dialog)) + { + GtkWindow *parent; + +--- build/src/mn-sound-player.c.orig 2011-02-02 23:55:02.436500397 +0100 ++++ build/src/mn-sound-player.c 2011-02-02 23:55:09.125141055 +0100 +@@ -27,7 +27,7 @@ + #include <sys/types.h> + #include <signal.h> + #include <glib/gi18n.h> +-#include <gnome.h> ++#include <libgnome/libgnome.h> + #include "mn-conf.h" + #include "mn-locked-callback.h" + #include "mn-util.h" +--- build/src/mn-file-chooser-button.c.orig 2011-02-02 23:55:21.857457045 +0100 ++++ build/src/mn-file-chooser-button.c 2011-02-02 23:55:30.422996901 +0100 +@@ -25,7 +25,7 @@ + #line 39 "src/mn-file-chooser-button.gob" + + #include <glib/gi18n.h> +-#include <gnome.h> ++#include <libgnome/libgnome.h> + #include "mn-util.h" + + #line 32 "mn-file-chooser-button.c" +--- build/src/mn-message.c.orig 2011-02-02 23:55:41.160420099 +0100 ++++ build/src/mn-message.c 2011-02-02 23:55:47.755065850 +0100 +@@ -26,7 +26,7 @@ + + #include <errno.h> + #include <glib/gi18n.h> +-#include <gnome.h> ++#include <libgnome/libgnome.h> + #include <libgnomevfs/gnome-vfs.h> + #include "mn-conf.h" + #include "mn-util.h" +--- build/src/mn-file-chooser-button.c.orig 2011-02-03 00:15:16.178407712 +0100 ++++ build/src/mn-file-chooser-button.c 2011-02-03 00:18:17.865681563 +0100 +@@ -463,6 +463,7 @@ + + GDK_THREADS_ENTER(); + ++#if 0 + if (results) + { + GnomeVFSGetFileInfoResult *result = results->data; +@@ -494,6 +495,7 @@ + } + } + } ++#endif + + selfp->async_handle = NULL; + g_object_unref(self); +--- build/src/mn-evolution-folder-tree-server.c.orig 2011-02-07 20:17:09.574274620 +0100 ++++ build/src/mn-evolution-folder-tree-server.c 2011-02-07 20:23:25.196053994 +0100 +@@ -25,6 +25,7 @@ + #line 24 "src/mn-evolution-folder-tree-server.gob" + + #include <dbus/dbus.h> ++#include <gtk/gtkx.h> + #include <libedataserver/eds-version.h> + #if !EDS_CHECK_VERSION(2,29,0) + #include <mail/mail-component.h> +@@ -71,7 +72,7 @@ + static void mn_evolution_folder_tree_server_finalize (MNEvolutionFolderTreeServer * self); + #line 70 "mn-evolution-folder-tree-server.c" + #line 84 "src/mn-evolution-folder-tree-server.gob" +-static void mn_evolution_folder_tree_server_plug_destroy_h (GtkObject * object, gpointer user_data); ++static void mn_evolution_folder_tree_server_plug_destroy_h (GtkWidget * object, gpointer user_data); + #line 73 "mn-evolution-folder-tree-server.c" + #line 104 "src/mn-evolution-folder-tree-server.gob" + static void mn_evolution_folder_tree_server_selected_h (EMFolderTree * tree, const char * full_name, const char * uri, guint32 flags, gpointer user_data); +@@ -456,7 +457,7 @@ + selfp->tree = em_folder_tree_new_with_model(model); + #endif + +- selfp->plug = gtk_plug_new((GdkNativeWindow) selfp->id); ++ selfp->plug = gtk_plug_new((Window) selfp->id); + gtk_container_add(GTK_CONTAINER(selfp->plug), selfp->tree); + gtk_widget_show_all(selfp->plug); + +@@ -490,7 +491,7 @@ + + #line 84 "src/mn-evolution-folder-tree-server.gob" + static void +-mn_evolution_folder_tree_server_plug_destroy_h (GtkObject * object, gpointer user_data) ++mn_evolution_folder_tree_server_plug_destroy_h (GtkWidget * object, gpointer user_data) + { + #line 482 "mn-evolution-folder-tree-server.c" + #define __GOB_FUNCTION__ "MN:Evolution:Folder:Tree:Server::plug_destroy_h" +--- src/eggtrayicon.h.orig 2011-02-07 20:25:26.352057350 +0100 ++++ src/eggtrayicon.h 2011-02-07 20:27:54.495032920 +0100 +@@ -23,10 +23,9 @@ + #ifndef __EGG_TRAY_ICON_H__ + #define __EGG_TRAY_ICON_H__ + +-#include <gtk/gtkplug.h> +-#ifdef GDK_WINDOWING_X11 ++#include <gtk/gtk.h> ++#include <gtk/gtkx.h> + #include <gdk/gdkx.h> +-#endif + + G_BEGIN_DECLS + +--- build/src/mn-mail-icon.c.orig 2011-02-07 20:24:58.971663075 +0100 ++++ build/src/mn-mail-icon.c 2011-02-07 20:30:33.714401306 +0100 +@@ -833,11 +833,13 @@ + #line 239 "src/mn-mail-icon.gob" + + GtkWidget *widget = user_data; ++ GtkAllocation allocation; + +- gdk_window_get_origin(widget->window, x, y); ++ gdk_window_get_origin(gtk_widget_get_window(widget), x, y); ++ gtk_widget_get_allocation(widget, &allocation); + +- *x += widget->allocation.x; +- *y += widget->allocation.y; ++ *x += allocation.x; ++ *y += allocation.y; + + if (*y > gdk_screen_get_height(gtk_widget_get_screen(widget)) / 2) + { +@@ -847,7 +849,7 @@ + *y -= req.height; + } + else +- *y += widget->allocation.height; ++ *y += allocation.height; + + *push_in = TRUE; + }} +--- build/src/mn-mail-icon-widget.c.orig 2011-02-07 20:31:19.475816763 +0100 ++++ build/src/mn-mail-icon-widget.c 2011-02-07 21:53:48.858814715 +0100 +@@ -64,9 +64,13 @@ + #line 65 "mn-mail-icon-widget.c" + #line 110 "src/mn-mail-icon-widget.gob" + static void ___7_mn_mail_icon_widget_size_request (GtkWidget * widget, GtkRequisition * requisition); ++static void ++mn_mail_icon_widget_get_preferred_width(GtkWidget *widget, gint *minimal_width, gint *natural_width); ++static void ++mn_mail_icon_widget_get_preferred_height(GtkWidget *widget, gint *minimal_height, gint *natural_height); + #line 68 "mn-mail-icon-widget.c" + #line 132 "src/mn-mail-icon-widget.gob" +-static gboolean ___8_mn_mail_icon_widget_expose_event (GtkWidget * widget, GdkEventExpose * event); ++static gboolean ___8_mn_mail_icon_widget_draw (GtkWidget * widget, cairo_t *cr); + #line 71 "mn-mail-icon-widget.c" + #line 244 "src/mn-mail-icon-widget.gob" + static GdkPixbuf * mn_mail_icon_widget_render_icon (MNMailIconWidget * self); +@@ -187,9 +191,10 @@ + parent_class = g_type_class_ref (GTK_TYPE_WIDGET); + + #line 110 "src/mn-mail-icon-widget.gob" +- gtk_widget_class->size_request = ___7_mn_mail_icon_widget_size_request; ++ gtk_widget_class->get_preferred_width = mn_mail_icon_widget_get_preferred_width; ++ gtk_widget_class->get_preferred_height = mn_mail_icon_widget_get_preferred_height; + #line 132 "src/mn-mail-icon-widget.gob" +- gtk_widget_class->expose_event = ___8_mn_mail_icon_widget_expose_event; ++ gtk_widget_class->draw = ___8_mn_mail_icon_widget_draw; + #line 194 "mn-mail-icon-widget.c" + g_object_class->dispose = ___dispose; + g_object_class->finalize = ___finalize; +@@ -234,7 +239,7 @@ + { + #line 93 "src/mn-mail-icon-widget.gob" + +- GTK_WIDGET_SET_FLAGS(self, GTK_NO_WINDOW); ++ gtk_widget_set_has_window(GTK_WIDGET(self), FALSE); + + gtk_widget_set_name(GTK_WIDGET(self), "mn-mail-icon"); + +@@ -457,9 +462,28 @@ + #undef __GOB_FUNCTION__ + #undef PARENT_HANDLER + ++static void ++mn_mail_icon_widget_get_preferred_width(GtkWidget *widget, gint *minimal_width, gint *natural_width) ++{ ++ GtkRequisition requisition; ++ ++ ___7_mn_mail_icon_widget_size_request (widget, &requisition); ++ *minimal_width = *natural_width = requisition.width; ++} ++ ++static void ++mn_mail_icon_widget_get_preferred_height(GtkWidget *widget, gint *minimal_height, gint *natural_height) ++{ ++ GtkRequisition requisition; ++ ++ ___7_mn_mail_icon_widget_size_request (widget, &requisition); ++ ++ *minimal_height = *natural_height = requisition.height; ++} ++ + #line 132 "src/mn-mail-icon-widget.gob" + static gboolean +-___8_mn_mail_icon_widget_expose_event (GtkWidget * widget G_GNUC_UNUSED, GdkEventExpose * event) ++___8_mn_mail_icon_widget_draw (GtkWidget * widget G_GNUC_UNUSED, cairo_t *cr) + #line 464 "mn-mail-icon-widget.c" + #define PARENT_HANDLER(___widget,___event) \ + ((GTK_WIDGET_CLASS(parent_class)->expose_event)? \ +@@ -472,7 +496,7 @@ + + Self *self = SELF(widget); + +- if (! GTK_WIDGET_DRAWABLE(widget) || ! selfp->stock_id) ++ if (! gtk_widget_is_drawable(widget) || ! selfp->stock_id) + return FALSE; + + if (selfp->is_on) +@@ -480,23 +504,34 @@ + int x; + int y; + GdkRectangle image_area; ++ GtkAllocation allocation; ++ GtkRequisition requisition; + + /* note: widget->requisition is the pixbuf size, see size_request() */ + +- x = floor(widget->allocation.x + ((widget->allocation.width - widget->requisition.width) * ICON_XALIGN)); +- y = floor(widget->allocation.y + ((widget->allocation.height - widget->requisition.height) * ICON_YALIGN)); ++ gtk_widget_get_allocation(widget, &allocation); ++ gtk_widget_get_requisition(widget, &requisition); ++ ++ x = floor(allocation.x + ((allocation.width - requisition.width) * ICON_XALIGN)); ++ y = floor(allocation.y + ((allocation.height - requisition.height) * ICON_YALIGN)); + + image_area.x = x; + image_area.y = y; +- image_area.width = widget->requisition.width; +- image_area.height = widget->requisition.height; ++ image_area.width = requisition.width; ++ image_area.height = requisition.height; + ++#if 0 + if (gdk_rectangle_intersect(&event->area, &image_area, &image_area)) ++#endif + { + GdkPixbuf *pixbuf; + + pixbuf = self_render_icon(self); ++ gdk_cairo_set_source_pixbuf(cr, pixbuf, image_area.x, image_area.y); ++ cairo_move_to(cr, image_area.x - x, image_area.y - y); ++ cairo_paint(cr); + ++#if 0 + gdk_draw_pixbuf(widget->window, + NULL, + pixbuf, +@@ -509,6 +544,7 @@ + GDK_RGB_DITHER_NORMAL, + 0, + 0); ++#endif + + g_object_unref(pixbuf); + } +@@ -523,13 +559,16 @@ + int box_y; + int box_width; + int box_height; ++ GtkAllocation allocation; ++ ++ gtk_widget_get_allocation(widget, &allocation); + + if (! selfp->count_layout) + { + const char *size; + char *markup; + +- if (widget->allocation.height < 32) ++ if (allocation.height < 32) + size = "small"; + else + size = "medium"; +@@ -546,17 +585,16 @@ + box_width = count_rect.width + COUNT_BOX_XPAD * 2; + box_height = count_rect.height + COUNT_BOX_YPAD * 2; + +- box_x = widget->allocation.x + widget->allocation.width - box_width - COUNT_BOX_XMARGIN; +- box_y = widget->allocation.y + widget->allocation.height - box_height - COUNT_BOX_YMARGIN; ++ box_x = allocation.x + allocation.width - box_width - COUNT_BOX_XMARGIN; ++ box_y = allocation.y + allocation.height - box_height - COUNT_BOX_YMARGIN; + + count_x = box_x - count_rect.x + COUNT_BOX_XPAD; + count_y = box_y - count_rect.y + COUNT_BOX_YPAD; + +- gtk_paint_box(widget->style, +- widget->window, +- GTK_WIDGET_STATE(widget), ++ gtk_paint_box(gtk_widget_get_style(widget), ++ cr, ++ gtk_widget_get_state_flags(widget), + GTK_SHADOW_OUT, +- &event->area, + widget, + NULL, + box_x, +@@ -564,11 +602,10 @@ + box_width, + box_height); + +- gtk_paint_layout(widget->style, +- widget->window, +- GTK_WIDGET_STATE(widget), ++ gtk_paint_layout(gtk_widget_get_style(widget), ++ cr, ++ gtk_widget_get_state_flags(widget), + FALSE, +- &event->area, + widget, + NULL, + count_x, +--- build/src/mn-mailbox-properties-dialog.c.orig 2011-02-07 21:57:31.257251776 +0100 ++++ build/src/mn-mailbox-properties-dialog.c 2011-02-07 21:56:56.989854854 +0100 +@@ -456,7 +456,7 @@ + MNMailboxProperties *properties; + + mn_container_create_interface(GTK_CONTAINER(self), +- PKGDATADIR G_DIR_SEPARATOR_S "mailbox-properties-dialog.glade", ++ PKGDATADIR G_DIR_SEPARATOR_S "mailbox-properties-dialog.ui", + "notebook", + "mn_mailbox_properties_dialog_", + "notebook", &self->notebook, +@@ -1290,7 +1290,7 @@ + { + #line 686 "src/mn-mailbox-properties-dialog.gob" + +- if (GTK_WIDGET_IS_SENSITIVE(GTK_WINDOW(self)->default_widget)) ++ if (gtk_widget_is_sensitive(gtk_window_get_default_widget(GTK_WINDOW(self)))) + gtk_window_activate_default(GTK_WINDOW(self)); + else + { +@@ -1313,9 +1313,9 @@ + if (elem->data == entry) + break; + +- if (GTK_WIDGET_MAPPED(elem->data) +- && GTK_WIDGET_VISIBLE(elem->data) +- && GTK_WIDGET_SENSITIVE(elem->data)) ++ if (gtk_widget_get_mapped(elem->data) ++ && gtk_widget_get_visible(elem->data) ++ && gtk_widget_get_sensitive(elem->data)) + next = elem->data; + } + while (! next); +--- build/src/mn-mailbox-view.c.orig 2011-02-07 22:18:49.962462920 +0100 ++++ build/src/mn-mailbox-view.c 2011-02-07 23:01:39.990363248 +0100 +@@ -412,23 +412,23 @@ + binding_set = gtk_binding_set_by_class(class); + + /* Delete removes a row */ +- gtk_binding_entry_add_signal(binding_set, GDK_Delete, 0, "activate-remove", 0); +- gtk_binding_entry_add_signal(binding_set, GDK_KP_Delete, 0, "activate-remove", 0); ++ gtk_binding_entry_add_signal(binding_set, GDK_KEY_Delete, 0, "activate-remove", 0); ++ gtk_binding_entry_add_signal(binding_set, GDK_KEY_KP_Delete, 0, "activate-remove", 0); + + /* HIG 2.0 cut/copy/paste shortcuts */ +- gtk_binding_entry_add_signal(binding_set, GDK_x, GDK_CONTROL_MASK, "activate-cut", 0); +- gtk_binding_entry_add_signal(binding_set, GDK_c, GDK_CONTROL_MASK, "activate-copy", 0); +- gtk_binding_entry_add_signal(binding_set, GDK_v, GDK_CONTROL_MASK, "activate-paste", 0); ++ gtk_binding_entry_add_signal(binding_set, GDK_KEY_x, GDK_CONTROL_MASK, "activate-cut", 0); ++ gtk_binding_entry_add_signal(binding_set, GDK_KEY_c, GDK_CONTROL_MASK, "activate-copy", 0); ++ gtk_binding_entry_add_signal(binding_set, GDK_KEY_v, GDK_CONTROL_MASK, "activate-paste", 0); + + /* cut/copy/paste shortcuts taken from gtkentry.c */ +- gtk_binding_entry_add_signal(binding_set, GDK_Delete, GDK_SHIFT_MASK, "activate-cut", 0); +- gtk_binding_entry_add_signal(binding_set, GDK_Insert, GDK_CONTROL_MASK, "activate-copy", 0); +- gtk_binding_entry_add_signal(binding_set, GDK_Insert, GDK_SHIFT_MASK, "activate-paste", 0); ++ gtk_binding_entry_add_signal(binding_set, GDK_KEY_Delete, GDK_SHIFT_MASK, "activate-cut", 0); ++ gtk_binding_entry_add_signal(binding_set, GDK_KEY_Insert, GDK_CONTROL_MASK, "activate-copy", 0); ++ gtk_binding_entry_add_signal(binding_set, GDK_KEY_Insert, GDK_SHIFT_MASK, "activate-paste", 0); + + /* HIG 2.0 properties */ +- gtk_binding_entry_add_signal(binding_set, GDK_Return, GDK_MOD1_MASK, "activate-properties", 0); +- gtk_binding_entry_add_signal(binding_set, GDK_ISO_Enter, GDK_MOD1_MASK, "activate-properties", 0); +- gtk_binding_entry_add_signal(binding_set, GDK_KP_Enter, GDK_MOD1_MASK, "activate-properties", 0); ++ gtk_binding_entry_add_signal(binding_set, GDK_KEY_Return, GDK_MOD1_MASK, "activate-properties", 0); ++ gtk_binding_entry_add_signal(binding_set, GDK_KEY_ISO_Enter, GDK_MOD1_MASK, "activate-properties", 0); ++ gtk_binding_entry_add_signal(binding_set, GDK_KEY_KP_Enter, GDK_MOD1_MASK, "activate-properties", 0); + + #line 434 "mn-mailbox-view.c" + } +@@ -934,14 +934,13 @@ + #line 183 "src/mn-mailbox-view.gob" + + GtkSelectionData *data; +- + data = gtk_clipboard_wait_for_contents(global_clipboard, clipboard_info[TARGET_MAILBOXES].atom); + if (data) + { + GSList *configurations; + GSList *l; + +- memcpy(&configurations, data->data, data->length); ++ memcpy(&configurations, gtk_selection_data_get_data(data), gtk_selection_data_get_length(data)); + + MN_LIST_FOREACH(l, configurations) + { +@@ -962,14 +961,14 @@ + data = gtk_clipboard_wait_for_contents(global_clipboard, clipboard_info[TARGET_GNOME_COPIED_FILES].atom); + if (data) + { +- if (data->format == 8 && data->length > 0) ++ if (gtk_selection_data_get_format(data) == 8 && gtk_selection_data_get_length(data) > 0) + { + char *gnome_copied_files; + gboolean status; + MNGnomeCopiedFilesType type; + GSList *uri_list; + +- gnome_copied_files = g_strndup(data->data, data->length); ++ gnome_copied_files = g_strndup(gtk_selection_data_get_data(data), gtk_selection_data_get_length(data)); + status = mn_parse_gnome_copied_files(gnome_copied_files, &type, &uri_list); + g_free(gnome_copied_files); + +--- build/src/mn-shell.c.orig 2011-02-07 23:02:17.852293679 +0100 ++++ build/src/mn-shell.c 2011-02-07 23:04:39.223548403 +0100 +@@ -158,7 +158,7 @@ + static void mn_shell_icon_activate_about_h (MNMailIcon * icon, gpointer user_data); + #line 160 "mn-shell.c" + #line 499 "src/mn-shell.gob" +-static void mn_shell_icon_destroy_h (GtkObject * object, gpointer user_data); ++static void mn_shell_icon_destroy_h (GtkWidget * object, gpointer user_data); + #line 163 "mn-shell.c" + #line 508 "src/mn-shell.gob" + static void mn_shell_update_sensitivity (MNShell * self); +@@ -1006,7 +1006,7 @@ + + #line 499 "src/mn-shell.gob" + static void +-mn_shell_icon_destroy_h (GtkObject * object, gpointer user_data) ++mn_shell_icon_destroy_h (GtkWidget * object, gpointer user_data) + { + #line 1004 "mn-shell.c" + #define __GOB_FUNCTION__ "MN:Shell::icon_destroy_h" +--- build/src/mn-text-table.c.orig 2011-02-07 23:05:08.799927792 +0100 ++++ build/src/mn-text-table.c 2011-02-07 23:18:06.480056895 +0100 +@@ -69,9 +69,11 @@ + #line 70 "mn-text-table.c" + #line 104 "src/mn-text-table.gob" + static void ___4_mn_text_table_size_request (GtkWidget * widget, GtkRequisition * requisition); ++static void mn_text_table_get_preferred_width (GtkWidget * widget, gint * minimal_width, gint * natural_width); ++static void mn_text_table_get_preferred_height (GtkWidget * widget, gint * minimal_height, gint * natural_height); + #line 73 "mn-text-table.c" + #line 115 "src/mn-text-table.gob" +-static gboolean ___5_mn_text_table_expose_event (GtkWidget * widget, GdkEventExpose * event); ++static gboolean ___5_mn_text_table_draw (GtkWidget * widget, cairo_t *cr); + #line 76 "mn-text-table.c" + #line 165 "src/mn-text-table.gob" + static void mn_text_table_set_dirty (MNTextTable * self); +@@ -188,9 +190,10 @@ + parent_class = g_type_class_ref (GTK_TYPE_WIDGET); + + #line 104 "src/mn-text-table.gob" +- gtk_widget_class->size_request = ___4_mn_text_table_size_request; ++ gtk_widget_class->get_preferred_width = mn_text_table_get_preferred_width; ++ gtk_widget_class->get_preferred_height = mn_text_table_get_preferred_height; + #line 115 "src/mn-text-table.gob" +- gtk_widget_class->expose_event = ___5_mn_text_table_expose_event; ++ gtk_widget_class->draw = ___5_mn_text_table_draw; + #line 257 "src/mn-text-table.gob" + c->clear = ___real_mn_text_table_clear; + #line 197 "mn-text-table.c" +@@ -216,7 +219,7 @@ + { + #line 80 "src/mn-text-table.gob" + +- GTK_WIDGET_SET_FLAGS(self, GTK_NO_WINDOW); ++ gtk_widget_set_has_window(GTK_WIDGET(self), FALSE); + + g_object_connect(self, + "swapped-signal::style-set", self_context_changed, self, +@@ -290,9 +293,29 @@ + #undef __GOB_FUNCTION__ + #undef PARENT_HANDLER + ++static void ++mn_text_table_get_preferred_width (GtkWidget * widget, gint * minimal_width, gint * natural_width) ++{ ++ GtkRequisition requisition; ++ ++ ___4_mn_text_table_size_request (widget, &requisition); ++ ++ *minimal_width = *natural_width = requisition.width; ++} ++ ++static void ++mn_text_table_get_preferred_height (GtkWidget * widget, gint * minimal_height, gint * natural_height) ++{ ++ GtkRequisition requisition; ++ ++ ___4_mn_text_table_size_request (widget, &requisition); ++ ++ *minimal_height = *natural_height = requisition.height; ++} ++ + #line 115 "src/mn-text-table.gob" + static gboolean +-___5_mn_text_table_expose_event (GtkWidget * widget G_GNUC_UNUSED, GdkEventExpose * event) ++___5_mn_text_table_draw (GtkWidget * widget G_GNUC_UNUSED, cairo_t *cr) + #line 297 "mn-text-table.c" + #define PARENT_HANDLER(___widget,___event) \ + ((GTK_WIDGET_CLASS(parent_class)->expose_event)? \ +@@ -304,10 +327,14 @@ + #line 117 "src/mn-text-table.gob" + + Self *self = SELF(widget); ++ GtkAllocation allocation; + int i; +- int y = widget->allocation.y; ++ int y; ++ ++ gtk_widget_get_allocation(widget, &allocation); ++ y = 0; + +- if (! GTK_WIDGET_DRAWABLE(widget)) ++ if (! gtk_widget_is_drawable(widget)) + return FALSE; + + self_relayout(self); +@@ -316,7 +343,7 @@ + { + Row *row = g_ptr_array_index(selfp->rows, i); + int j; +- int x = widget->allocation.x; ++ int x = 0; + int column = 0; + + MN_ARRAY_FOREACH(j, row->cells) +@@ -324,11 +351,10 @@ + MNTextTableCell *cell = g_ptr_array_index(row->cells, j); + + if (cell->layout) +- gtk_paint_layout(widget->style, +- widget->window, +- GTK_WIDGET_STATE(widget), ++ gtk_paint_layout(gtk_widget_get_style(widget), ++ cr, ++ gtk_widget_get_state_flags(widget), + FALSE, +- &event->area, + widget, + NULL, + x, +--- build/src/mn-tooltips.c.orig 2011-02-07 23:19:05.903761972 +0100 ++++ build/src/mn-tooltips.c 2011-02-07 23:41:19.368621912 +0100 +@@ -104,7 +104,7 @@ + static void mn_tooltips_set_tip_widget_real (MNTooltips * self, GtkWidget * widget, GtkWidget * tip_widget, int border_width); + #line 106 "mn-tooltips.c" + #line 287 "src/mn-tooltips.gob" +-static gboolean mn_tooltips_paint_window (MNTooltips * self); ++static gboolean mn_tooltips_paint_window (MNTooltips * self, cairo_t *cr); + #line 109 "mn-tooltips.c" + #line 308 "src/mn-tooltips.gob" + static void mn_tooltips_draw_tips (MNTooltips * self); +@@ -422,7 +422,13 @@ + + if (! selfp->window) + { ++ GtkStyleContext *ctx; ++ + selfp->window = gtk_window_new(GTK_WINDOW_POPUP); ++ ++ ctx = gtk_widget_get_style_context(GTK_WIDGET(selfp->window)); ++ gtk_style_context_add_class(ctx, "tooltip"); ++ + self_update_screen(self, TRUE); + gtk_widget_set_app_paintable(selfp->window, TRUE); + gtk_window_set_resizable(GTK_WINDOW(selfp->window), FALSE); +@@ -430,7 +430,7 @@ + gtk_container_set_border_width(GTK_CONTAINER(selfp->window), selfp->border_width); + + g_signal_connect_swapped(selfp->window, +- "expose-event", ++ "draw", + G_CALLBACK(self_paint_window), + self); + +@@ -490,7 +490,7 @@ + + if (selfp->active_data + && selfp->active_data->widget == widget +- && GTK_WIDGET_DRAWABLE(selfp->active_data->widget)) ++ && gtk_widget_is_drawable(selfp->active_data->widget)) + { + if (data->tip_widget) + g_object_unref(data->tip_widget); +@@ -594,7 +594,7 @@ + + #line 287 "src/mn-tooltips.gob" + static gboolean +-mn_tooltips_paint_window (MNTooltips * self) ++mn_tooltips_paint_window (MNTooltips * self, cairo_t *cr) + { + #line 600 "mn-tooltips.c" + #define __GOB_FUNCTION__ "MN:Tooltips::paint_window" +@@ -608,18 +608,13 @@ + + GtkRequisition req; + +- gtk_widget_size_request(selfp->window, &req); +- gtk_paint_flat_box(selfp->window->style, +- selfp->window->window, +- GTK_STATE_NORMAL, +- GTK_SHADOW_OUT, +- NULL, +- selfp->window, +- "tooltip", +- 0, +- 0, +- req.width, +- req.height); ++ gtk_widget_size_request(GTK_WIDGET(selfp->window), &req); ++ gtk_render_background(gtk_widget_get_style_context(GTK_WIDGET(selfp->window)), ++ cr, ++ 0, ++ 0, ++ req.width, ++ req.height); + + return FALSE; + }} +@@ -651,10 +650,11 @@ + gint monitor_num, px, py; + GdkRectangle monitor; + int screen_width; ++ GtkAllocation allocation; + + if (! selfp->window) + self_force_window(self); +- else if (GTK_WIDGET_VISIBLE(selfp->window)) ++ else if (gtk_widget_get_visible(selfp->window)) + g_get_current_time(&selfp->last_popdown); + + gtk_widget_ensure_style(selfp->window); +@@ -670,7 +670,7 @@ + + data = selfp->active_data; + +- child = GTK_BIN(selfp->window)->child; ++ child = gtk_bin_get_child(GTK_BIN(selfp->window)); + if (child) + gtk_container_remove(GTK_CONTAINER(selfp->window), child); + +@@ -684,14 +684,16 @@ + w = requisition.width; + h = requisition.height; + +- gdk_window_get_origin(widget->window, &x, &y); +- if (GTK_WIDGET_NO_WINDOW(widget)) ++ gtk_widget_get_allocation(selfp->window, &allocation); ++ ++ gdk_window_get_origin(gtk_widget_get_window(widget), &x, &y); ++ if (! gtk_widget_get_has_window(widget)) + { +- x += widget->allocation.x; +- y += widget->allocation.y; ++ x += allocation.x; ++ y += allocation.y; + } + +- x += widget->allocation.width / 2; ++ x += allocation.width / 2; + + if (! keyboard_mode) + gdk_window_get_pointer(gdk_screen_get_root_window(screen), &x, NULL, NULL); +@@ -712,11 +714,11 @@ + else if (x < monitor.x) + x = monitor.x; + +- if ((y + h + widget->allocation.height + 4) > monitor.y + monitor.height ++ if ((y + h + allocation.height + 4) > monitor.y + monitor.height + && (y - 4) > monitor.y) + y = y - h - 4; + else +- y = y + widget->allocation.height + 4; ++ y = y + allocation.height + 4; + + /* + * The following block is not part of GTK+ and has been added to +@@ -760,7 +762,7 @@ + + Self *self = SELF(data); + +- if (selfp->active_data && GTK_WIDGET_DRAWABLE(selfp->active_data->widget)) ++ if (selfp->active_data && gtk_widget_is_drawable(selfp->active_data->widget)) + self_draw_tips(self); + + selfp->timeout_id = 0; +@@ -785,7 +787,7 @@ + + if (selfp->window) + { +- if (GTK_WIDGET_VISIBLE(selfp->window)) ++ if (gtk_widget_get_visible(selfp->window)) + g_get_current_time(&selfp->last_popdown); + gtk_widget_hide(selfp->window); + } +@@ -802,7 +804,7 @@ + { + TooltipsData *data = l->data; + +- if (data->widget == widget && GTK_WIDGET_DRAWABLE(widget)) ++ if (data->widget == widget && gtk_widget_is_drawable(widget)) + { + selfp->active_data = data; + break; +@@ -937,7 +939,7 @@ + + if (GTK_IS_WINDOW(toplevel)) + { +- GtkWidget *focus = GTK_WINDOW(toplevel)->focus_widget; ++ GtkWidget *focus = gtk_window_get_focus(GTK_WINDOW(toplevel)); + + g_object_set_data(G_OBJECT(toplevel), TOOLTIPS_KEYBOARD_MODE, GINT_TO_POINTER(TRUE)); + +@@ -966,7 +968,7 @@ + + if (GTK_IS_WINDOW(toplevel)) + { +- GtkWidget *focus = GTK_WINDOW(toplevel)->focus_widget; ++ GtkWidget *focus = gtk_window_get_focus(GTK_WINDOW(toplevel)); + + if (focus) + self_hide_tip(focus); +@@ -1057,24 +1059,24 @@ + break; + + case GDK_ENTER_NOTIFY: +- if (! (GTK_IS_MENU_ITEM(widget) && GTK_MENU_ITEM(widget)->submenu)) ++ if (! (GTK_IS_MENU_ITEM(widget) && gtk_menu_item_get_submenu(GTK_MENU_ITEM(widget)))) + self_start_delay(self, widget); + break; + + case GDK_LEAVE_NOTIFY: + self_set_active_widget(self, NULL); +- selfp->use_sticky_delay = selfp->window && GTK_WIDGET_VISIBLE(selfp->window); ++ selfp->use_sticky_delay = selfp->window && gtk_widget_get_visible(selfp->window); + break; + + case GDK_MOTION_NOTIFY: + /* Handle menu items specially ... pend popup for each motion + * on other widgets, we ignore motion. + */ +- if (GTK_IS_MENU_ITEM(widget) && ! GTK_MENU_ITEM(widget)->submenu) ++ if (GTK_IS_MENU_ITEM(widget) && ! gtk_menu_item_get_submenu(GTK_MENU_ITEM(widget))) + { + /* Completely evil hack to make sure we get the LEAVE_NOTIFY + */ +- GTK_PRIVATE_SET_FLAG(widget, GTK_LEAVE_PENDING); ++ //GTK_PRIVATE_SET_FLAG(widget, GTK_LEAVE_PENDING); + self_set_active_widget(self, NULL); + self_start_delay(self, widget); + break; +--- src/nautilus-cell-renderer-pixbuf-emblem.c.orig 2011-02-08 00:16:43.847831409 +0100 ++++ src/nautilus-cell-renderer-pixbuf-emblem.c 2011-02-08 00:32:59.128682767 +0100 +@@ -39,17 +39,16 @@ + GtkWidget *widget); + static void nautilus_cell_renderer_pixbuf_emblem_get_size (GtkCellRenderer *cell, + GtkWidget *widget, +- GdkRectangle *rectangle, ++ const GdkRectangle *rectangle, + gint *x_offset, + gint *y_offset, + gint *width, + gint *height); + static void nautilus_cell_renderer_pixbuf_emblem_render (GtkCellRenderer *cell, +- GdkWindow *window, ++ cairo_t *cr, + GtkWidget *widget, +- GdkRectangle *background_area, +- GdkRectangle *cell_area, +- GdkRectangle *expose_area, ++ const GdkRectangle *background_area, ++ const GdkRectangle *cell_area, + GtkCellRendererState flags); + + enum { +@@ -356,7 +355,7 @@ + static void + nautilus_cell_renderer_pixbuf_emblem_get_size (GtkCellRenderer *cell, + GtkWidget *widget, +- GdkRectangle *cell_area, ++ const GdkRectangle *cell_area, + gint *x_offset, + gint *y_offset, + gint *width, +@@ -368,6 +367,10 @@ + gint pixbuf_height = 0; + gint calc_width; + gint calc_height; ++ int xpad; ++ int ypad; ++ gfloat xalign; ++ gfloat yalign; + + if (!cellpixbuf->pixbuf && cellinfo->stock_id) + nautilus_cell_renderer_pixbuf_emblem_create_stock_pixbuf (cellpixbuf, widget); +@@ -385,8 +388,11 @@ + pixbuf_height = MAX (pixbuf_height, gdk_pixbuf_get_height (cellpixbuf->pixbuf_expander_closed)); + } + +- calc_width = (gint) cell->xpad * 2 + pixbuf_width; +- calc_height = (gint) cell->ypad * 2 + pixbuf_height; ++ gtk_cell_renderer_get_padding(cell, &xpad, &ypad); ++ gtk_cell_renderer_get_alignment(cell, &xalign, &yalign); ++ ++ calc_width = (gint) xpad * 2 + pixbuf_width; ++ calc_height = (gint) ypad * 2 + pixbuf_height; + + if (x_offset) *x_offset = 0; + if (y_offset) *y_offset = 0; +@@ -394,14 +400,14 @@ + if (cell_area && pixbuf_width > 0 && pixbuf_height > 0) { + if (x_offset) { + *x_offset = (((gtk_widget_get_direction (widget) == GTK_TEXT_DIR_RTL) ? +- 1.0 - cell->xalign : cell->xalign) * +- (cell_area->width - calc_width - 2 * cell->xpad)); +- *x_offset = MAX (*x_offset, 0) + cell->xpad; ++ 1.0 - xalign : xalign) * ++ (cell_area->width - calc_width - 2 * xpad)); ++ *x_offset = MAX (*x_offset, 0) + xpad; + } + if (y_offset) { +- *y_offset = (cell->yalign * +- (cell_area->height - calc_height - 2 * cell->ypad)); +- *y_offset = MAX (*y_offset, 0) + cell->ypad; ++ *y_offset = (yalign * ++ (cell_area->height - calc_height - 2 * ypad)); ++ *y_offset = MAX (*y_offset, 0) + ypad; + } + } + +@@ -414,11 +420,10 @@ + + static void + nautilus_cell_renderer_pixbuf_emblem_render (GtkCellRenderer *cell, +- GdkWindow *window, ++ cairo_t *cr, + GtkWidget *widget, +- GdkRectangle *background_area, +- GdkRectangle *cell_area, +- GdkRectangle *expose_area, ++ const GdkRectangle *background_area, ++ const GdkRectangle *cell_area, + GtkCellRendererState flags) + + { +@@ -429,13 +434,19 @@ + GdkRectangle pix_emblem_rect; + GdkRectangle draw_rect; + gboolean stock_pixbuf = FALSE; ++ gboolean is_expander = FALSE; ++ gboolean is_expanded = FALSE; ++ int xpad; ++ int ypad; ++ ++ g_object_get(cell, "is-expander", &is_expander, "is-expanded", &is_expanded, NULL); + + pixbuf = cellpixbuf->pixbuf; +- if (cell->is_expander) { +- if (cell->is_expanded && ++ if (is_expander) { ++ if (is_expanded && + cellpixbuf->pixbuf_expander_open != NULL) { + pixbuf = cellpixbuf->pixbuf_expander_open; +- } else if (!cell->is_expanded && ++ } else if (!is_expanded && + cellpixbuf->pixbuf_expander_closed != NULL) { + pixbuf = cellpixbuf->pixbuf_expander_closed; + } +@@ -456,15 +467,20 @@ + if (stock_pixbuf) + pixbuf = cellpixbuf->pixbuf; + ++ gtk_cell_renderer_get_padding(cell, &xpad, &ypad); ++ + pix_rect.x += cell_area->x; + pix_rect.y += cell_area->y; +- pix_rect.width -= cell->xpad * 2; +- pix_rect.height -= cell->ypad * 2; ++ pix_rect.width -= xpad * 2; ++ pix_rect.height -= ypad * 2; + ++ if (gdk_rectangle_intersect (cell_area, &pix_rect, &draw_rect)) { ++#if 0 + if (gdk_rectangle_intersect (cell_area, &pix_rect, &draw_rect) && + gdk_rectangle_intersect (expose_area, &draw_rect, &draw_rect)) { ++ + gdk_draw_pixbuf (window, +- widget->style->black_gc, ++ gtk_widget_get_style(widget)->black_gc, + pixbuf, + /* pixbuf 0, 0 is at pix_rect.x, pix_rect.y */ + draw_rect.x - pix_rect.x, +@@ -475,6 +491,11 @@ + draw_rect.height, + GDK_RGB_DITHER_NORMAL, + 0, 0); ++#endif ++ ++ cairo_move_to (cr, draw_rect.x - pix_rect.x, draw_rect.y - pix_rect.y); ++ gdk_cairo_set_source_pixbuf (cr, pixbuf, draw_rect.x, draw_rect.y); ++ cairo_paint (cr); + } + + if (cellpixbuf->pixbuf_emblem) { +@@ -482,8 +503,11 @@ + pix_emblem_rect.height = gdk_pixbuf_get_height (cellpixbuf->pixbuf_emblem); + pix_emblem_rect.x = pix_rect.x; + pix_emblem_rect.y = pix_rect.y + pix_rect.height - pix_emblem_rect.height; ++ if (gdk_rectangle_intersect (cell_area, &pix_emblem_rect, &draw_rect)) { ++#if 0 + if (gdk_rectangle_intersect (cell_area, &pix_emblem_rect, &draw_rect) && + gdk_rectangle_intersect (expose_area, &draw_rect, &draw_rect)) { ++ + gdk_draw_pixbuf (window, + widget->style->black_gc, + cellpixbuf->pixbuf_emblem, +@@ -496,6 +520,11 @@ + draw_rect.height, + GDK_RGB_DITHER_NORMAL, + 0, 0); ++#endif ++ ++ cairo_move_to (cr, draw_rect.x - pix_emblem_rect.x, draw_rect.y - pix_emblem_rect.y); ++ gdk_cairo_set_source_pixbuf (cr, cellpixbuf->pixbuf_emblem, draw_rect.x, draw_rect.y); ++ cairo_paint (cr); + } + } + } +--- src/nautilus-cell-renderer-pixbuf-emblem.h.orig 2011-02-07 22:18:12.336471764 +0100 ++++ src/nautilus-cell-renderer-pixbuf-emblem.h 2011-02-08 00:20:30.461758697 +0100 +@@ -25,18 +25,18 @@ + #ifndef NAUTILUS_CELL_RENDERER_PIXBUF_EMBLEM_H + #define NAUTILUS_CELL_RENDERER_PIXBUF_EMBLEM_H + +-#include <gtk/gtkcellrenderer.h> ++#include <gtk/gtk.h> + + #define NAUTILUS_TYPE_CELL_RENDERER_PIXBUF_EMBLEM \ + (nautilus_cell_renderer_pixbuf_emblem_get_type ()) + #define NAUTILUS_CELL_RENDERER_PIXBUF_EMBLEM(obj) \ +- (GTK_CHECK_CAST ((obj), NAUTILUS_TYPE_CELL_RENDERER_PIXBUF_EMBLEM, NautilusCellRendererPixbufEmblem)) ++ (G_TYPE_CHECK_INSTANCE_CAST ((obj), NAUTILUS_TYPE_CELL_RENDERER_PIXBUF_EMBLEM, NautilusCellRendererPixbufEmblem)) + #define NAUTILUS_CELL_RENDERER_PIXBUF_EMBLEM_CLASS(klass) \ +- (GTK_CHECK_CLASS_CAST ((klass), NAUTILUS_TYPE_CELL_RENDERER_PIXBUF_EMBLEM, NautilusCellRendererPixbufEmblemClass)) ++ (G_TYPE_CHECK_CLASS_CAST ((klass), NAUTILUS_TYPE_CELL_RENDERER_PIXBUF_EMBLEM, NautilusCellRendererPixbufEmblemClass)) + #define NAUTILUS_IS_CELL_RENDERER_PIXBUF_EMBLEM(obj) \ +- (GTK_CHECK_TYPE ((obj), NAUTILUS_TYPE_CELL_RENDERER_PIXBUF_EMBLEM)) ++ (G_TYPE_CHECK_INSTANCE_TYPE ((obj), NAUTILUS_TYPE_CELL_RENDERER_PIXBUF_EMBLEM)) + #define NAUTILUS_IS_CELL_RENDERER_PIXBUF_EMBLEM_CLASS(klass) \ +- (GTK_CHECK_CLASS_TYPE ((klass), NAUTILUS_TYPE_CELL_RENDERER_PIXBUF_EMBLEM)) ++ (G_TYPE_CHECK_CLASS_TYPE ((klass), NAUTILUS_TYPE_CELL_RENDERER_PIXBUF_EMBLEM)) + + typedef struct _NautilusCellRendererPixbufEmblem NautilusCellRendererPixbufEmblem; + typedef struct _NautilusCellRendererPixbufEmblemClass NautilusCellRendererPixbufEmblemClass; +--- build/src/mn-authenticated-mailbox.c.orig 2011-02-08 00:34:16.332610802 +0100 ++++ build/src/mn-authenticated-mailbox.c 2011-02-08 00:36:23.706936717 +0100 +@@ -25,7 +25,7 @@ + #line 29 "src/mn-authenticated-mailbox.gob" + + #include <glib/gi18n.h> +-#include <gnome.h> ++#include <libgnome/libgnome.h> + #include "mn-mailbox-private.h" + #include "mn-shell.h" + #include "mn-util.h" +@@ -859,6 +859,7 @@ + + /* keep the title in sync with gnome-authentication-manager */ + ++#if 0 + /* translators: header capitalization */ + selfp->auth_dialog = gnome_password_dialog_new(_("Authentication Required"), + message, +@@ -891,6 +892,9 @@ + gtk_widget_destroy(selfp->auth_dialog); + + return ok; ++#else ++ return FALSE; ++#endif + }} + #line 896 "mn-authenticated-mailbox.c" + #undef __GOB_FUNCTION__ +--- build/src/mn-about-dialog.c.orig 2011-02-08 22:20:54.469841262 +0100 ++++ build/src/mn-about-dialog.c 2011-02-08 22:21:13.309839037 +0100 +@@ -111,9 +111,11 @@ + { + #line 32 "src/mn-about-dialog.gob" + ++#if 0 + gtk_about_dialog_set_email_hook(self_activate_link_cb, "mailto:", NULL); + gtk_about_dialog_set_url_hook(self_activate_link_cb, NULL, NULL); +- ++#endif ++ + #line 118 "mn-about-dialog.c" + } + } +--- build/src/mn-autodetect-mailbox-properties.c.orig 2011-02-08 22:21:58.639427345 +0100 ++++ build/src/mn-autodetect-mailbox-properties.c 2011-02-08 22:22:43.564035901 +0100 +@@ -355,10 +355,9 @@ + + toplevel = gtk_widget_get_toplevel(GTK_WIDGET(button)); + /* translators: header capitalization */ +- selfp->chooser = gtk_file_chooser_dialog_new_with_backend(_("Select a File or Folder"), ++ selfp->chooser = gtk_file_chooser_dialog_new(_("Select a File or Folder"), + GTK_WINDOW(toplevel), + GTK_FILE_CHOOSER_ACTION_OPEN, +- "gnome-vfs", + GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, + GTK_STOCK_OPEN, 1, + NULL); +--- build/src/mn-pi-mailbox-properties.c.orig 2011-02-08 22:30:08.051375715 +0100 ++++ build/src/mn-pi-mailbox-properties.c 2011-02-08 22:30:21.398665261 +0100 +@@ -415,7 +415,7 @@ + int i; + + for (i = 0; i < MN_PI_MAILBOX_N_CONNECTION_TYPES; i++) +- gtk_widget_set_sensitive(self->port_spin[i], GTK_WIDGET_SENSITIVE(self->conn_radio[i]) && gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(self->conn_radio[i]))); ++ gtk_widget_set_sensitive(self->port_spin[i], gtk_widget_get_sensitive(self->conn_radio[i]) && gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(self->conn_radio[i]))); + + g_object_notify(G_OBJECT(self), "complete"); + }} +--- src/eggtrayicon.c.orig 2011-02-07 23:42:30.405791829 +0100 ++++ src/eggtrayicon.c 2011-02-08 23:06:16.092968325 +0100 +@@ -25,7 +25,7 @@ + + #include "eggtrayicon.h" + +-#include <gdkconfig.h> ++#include <gdk/gdk.h> + #if defined (GDK_WINDOWING_X11) + #include <gdk/gdkx.h> + #include <X11/Xatom.h> +@@ -258,7 +258,7 @@ + { + GdkWindow *gdkwin; + +- gdkwin = gdk_window_lookup_for_display (gtk_widget_get_display (widget), ++ gdkwin = gdk_x11_window_lookup_for_display (gtk_widget_get_display (widget), + icon->manager_window); + + gdk_window_remove_filter (gdkwin, egg_tray_icon_manager_filter, icon); +@@ -290,7 +290,7 @@ + ev.window = window; + ev.message_type = icon->system_tray_opcode_atom; + ev.format = 32; +- ev.data.l[0] = gdk_x11_get_server_time (GTK_WIDGET (icon)->window); ++ ev.data.l[0] = gdk_x11_get_server_time (gtk_widget_get_window(GTK_WIDGET (icon))); + ev.data.l[1] = message; + ev.data.l[2] = data1; + ev.data.l[3] = data2; +@@ -342,12 +342,12 @@ + { + GdkWindow *gdkwin; + +- gdkwin = gdk_window_lookup_for_display (gtk_widget_get_display (GTK_WIDGET (icon)), ++ gdkwin = gdk_x11_window_lookup_for_display (gtk_widget_get_display (GTK_WIDGET (icon)), + icon->manager_window); + + gdk_window_add_filter (gdkwin, egg_tray_icon_manager_filter, icon); + +- if (dock_if_realized && GTK_WIDGET_REALIZED (icon)) ++ if (dock_if_realized && gtk_widget_get_realized (GTK_WIDGET(icon))) + egg_tray_icon_send_dock_request (icon); + + egg_tray_icon_get_orientation_property (icon); +@@ -355,10 +355,16 @@ + } + + static gboolean +-transparent_expose_event (GtkWidget *widget, GdkEventExpose *event, gpointer user_data) ++transparent_draw (GtkWidget *widget, cairo_t *cr, gpointer user_data) + { +- gdk_window_clear_area (widget->window, event->area.x, event->area.y, ++#if 0 ++ gdk_window_clear_area (gtk_widget_get_window(widget), event->area.x, event->area.y, + event->area.width, event->area.height); ++#endif ++ cairo_set_operator (cr, CAIRO_OPERATOR_CLEAR); ++ //gdk_cairo_region (cr, event->region); ++ cairo_fill (cr); ++ + return FALSE; + } + +@@ -366,20 +372,20 @@ + make_transparent_again (GtkWidget *widget, GtkStyle *previous_style, + gpointer user_data) + { +- gdk_window_set_back_pixmap (widget->window, NULL, TRUE); ++ //gdk_window_set_back_pixmap (gtk_widget_get_window(widget), NULL, TRUE); + } + + static void + make_transparent (GtkWidget *widget, gpointer user_data) + { +- if (GTK_WIDGET_NO_WINDOW (widget) || GTK_WIDGET_APP_PAINTABLE (widget)) ++ if (! gtk_widget_get_has_window (widget) || gtk_widget_get_app_paintable (widget)) + return; + + gtk_widget_set_app_paintable (widget, TRUE); + gtk_widget_set_double_buffered (widget, FALSE); +- gdk_window_set_back_pixmap (widget->window, NULL, TRUE); +- g_signal_connect (widget, "expose_event", +- G_CALLBACK (transparent_expose_event), NULL); ++ //gdk_window_set_back_pixmap (gtk_widget_get_window(widget), NULL, TRUE); ++ g_signal_connect (widget, "draw", ++ G_CALLBACK (transparent_draw), NULL); + g_signal_connect_after (widget, "style_set", + G_CALLBACK (make_transparent_again), NULL); + } +@@ -391,7 +397,7 @@ + + g_return_if_fail (icon->manager_window != None); + +- gdkwin = gdk_window_lookup_for_display (gtk_widget_get_display (GTK_WIDGET (icon)), ++ gdkwin = gdk_x11_window_lookup_for_display (gtk_widget_get_display (GTK_WIDGET (icon)), + icon->manager_window); + + gdk_window_remove_filter (gdkwin, egg_tray_icon_manager_filter, icon); +--- build/src/mn-properties-dialog.c.orig 2011-02-08 23:37:12.605200174 +0100 ++++ build/src/mn-properties-dialog.c 2011-02-08 23:37:18.601881191 +0100 +@@ -183,7 +183,7 @@ + GtkTreeSelection *selection; + + mn_container_create_interface(GTK_CONTAINER(self), +- PKGDATADIR G_DIR_SEPARATOR_S "properties-dialog.glade", ++ PKGDATADIR G_DIR_SEPARATOR_S "properties-dialog.ui", + "main_vbox", + "mn_properties_dialog_", + "notebook", &selfp->notebook, +--- src/mn-util.c.orig 2011-02-08 00:01:25.167207512 +0100 ++++ src/mn-util.c 2011-02-09 00:01:35.718285446 +0100 +@@ -26,8 +26,7 @@ + #include <gmodule.h> + #include <glib/gi18n.h> + #include <gobject/gvaluecollector.h> +-#include <gnome.h> +-#include <glade/glade.h> ++#include <libgnome/libgnome.h> + #include "mn-util.h" + #include "mn-mailboxes.h" + #include "mn-shell.h" +@@ -303,49 +302,55 @@ + return pixbuf; + } + +-static GladeXML * ++static GtkBuilder * + mn_glade_xml_new (const char *filename, const char *root, const char *domain) + { +- GladeXML *xml; ++ GtkBuilder *builder; ++ GError *err = NULL; + + g_return_val_if_fail(filename != NULL, NULL); + +- xml = glade_xml_new(filename, root, domain); +- if (! xml) +- mn_show_fatal_error_dialog(NULL, "Unable to load interface \"%s\".", filename); ++ builder = gtk_builder_new(); ++ gtk_builder_set_translation_domain(builder, domain); ++ if (! gtk_builder_add_from_file(builder, filename, &err)) { ++ mn_show_fatal_error_dialog(NULL, "Unable to load interface \"%s\": %s.", filename, err->message); ++ g_error_free(err); ++ g_object_unref(builder); ++ return NULL; ++ } + +- return xml; ++ return builder; + } + + static GtkWidget * +-mn_glade_xml_get_widget (GladeXML *xml, const char *widget_name) ++mn_glade_xml_get_widget (GtkBuilder *builder, const char *widget_name) + { + GtkWidget *widget; + +- g_return_val_if_fail(GLADE_IS_XML(xml), NULL); ++ g_return_val_if_fail(GTK_IS_BUILDER(builder), NULL); + g_return_val_if_fail(widget_name != NULL, NULL); + +- widget = glade_xml_get_widget(xml, widget_name); ++ widget = GTK_WIDGET(gtk_builder_get_object(builder, widget_name)); + if (! widget) +- mn_show_fatal_error_dialog(NULL, "Widget \"%s\" not found in interface \"%s\".", widget_name, xml->filename); ++ mn_show_fatal_error_dialog(NULL, "Widget \"%s\" not found in interface.", widget_name); + + return widget; + } + + static void +-create_interface_connect_cb (const char *handler_name, ++create_interface_connect_cb (GtkBuilder *builder, + GObject *object, + const char *signal_name, +- const char *signal_data, ++ const char *handler_name, + GObject *connect_object, +- gboolean after, ++ GConnectFlags flags, + gpointer user_data) + { + static GModule *module = NULL; + ContainerCreateInterfaceConnectInfo *info = user_data; + char *cb_name; + GCallback cb; +- GConnectFlags flags; ++ GConnectFlags cflags; + + if (! module) + { +@@ -359,11 +364,9 @@ + mn_show_fatal_error_dialog(NULL, "Signal handler \"%s\" not found.", cb_name); + g_free(cb_name); + +- flags = G_CONNECT_SWAPPED; +- if (after) +- flags |= G_CONNECT_AFTER; ++ cflags = G_CONNECT_SWAPPED; + +- g_signal_connect_data(object, signal_name, cb, info->container, NULL, flags); ++ g_signal_connect_data(object, signal_name, cb, info->container, NULL, cflags); + } + + void +@@ -373,7 +376,7 @@ + const char *callback_prefix, + ...) + { +- GladeXML *xml; ++ GtkBuilder *xml; + GtkWidget *child; + ContainerCreateInterfaceConnectInfo info; + va_list args; +@@ -387,14 +390,16 @@ + xml = mn_glade_xml_new(filename, child_name, NULL); + child = mn_glade_xml_get_widget(xml, child_name); + +- if (GTK_IS_DIALOG(container)) +- gtk_box_pack_start(GTK_BOX(GTK_DIALOG(container)->vbox), child, TRUE, TRUE, 0); +- else ++ if (GTK_IS_DIALOG(container)) { ++ gtk_widget_unparent(child); ++ gtk_box_pack_start(GTK_BOX(gtk_dialog_get_content_area(GTK_DIALOG(container))), child, TRUE, TRUE, 0); ++ } else { + gtk_container_add(container, child); ++ } + + info.container = container; + info.callback_prefix = callback_prefix; +- glade_xml_signal_autoconnect_full(xml, create_interface_connect_cb, &info); ++ gtk_builder_connect_signals_full(xml, create_interface_connect_cb, &info); + + va_start(args, callback_prefix); + +@@ -422,7 +427,7 @@ + + toplevel = gtk_widget_get_toplevel(widget); + +- return GTK_WIDGET_TOPLEVEL(toplevel) ? GTK_WINDOW(toplevel) : NULL; ++ return gtk_widget_get_toplevel(toplevel) ? GTK_WINDOW(toplevel) : NULL; + } + + static void +@@ -493,9 +498,11 @@ + gpointer user_data) + { + GtkAdjustment *adjustment; ++ GtkAllocation allocation; + ++ gtk_widget_get_allocation(widget, &allocation); + adjustment = gtk_scrolled_window_get_vadjustment(GTK_SCROLLED_WINDOW(widget)); +- gtk_adjustment_set_value(adjustment, (double) y / (widget->allocation.height - 2) * (adjustment->upper - adjustment->page_size)); ++ gtk_adjustment_set_value(adjustment, (double) y / (allocation.height - 2) * (gtk_adjustment_get_upper(adjustment) - gtk_adjustment_get_page_size(adjustment))); + + return TRUE; /* we're forcibly in a drop zone */ + } +@@ -562,7 +569,7 @@ + MNMailbox *mailbox; + + /* text/x-moz-url is encoded in UCS-2 but in format 8: broken */ +- if (selection_data->format != 8 || selection_data->length <= 0 || (selection_data->length % 2) != 0) ++ if (gtk_selection_data_get_format(selection_data) != 8 || gtk_selection_data_get_length(selection_data) <= 0 || (gtk_selection_data_get_length(selection_data) % 2) != 0) + { + mn_show_error_dialog(mn_widget_get_parent_window(widget), + _("A drag and drop error has occurred"), +@@ -570,8 +577,8 @@ + return; + } + +- char_data = (const guint16 *) selection_data->data; +- char_len = selection_data->length / 2; ++ char_data = (const guint16 *) gtk_selection_data_get_data(selection_data); ++ char_len = gtk_selection_data_get_length(selection_data) / 2; + + url = g_string_new(NULL); + for (i = 0; i < char_len && char_data[i] != '\n'; i++) +@@ -1322,7 +1329,7 @@ + } + + static void +-dialog_run_nonmodal_destroy_h (GtkObject *object, gpointer user_data) ++dialog_run_nonmodal_destroy_h (GtkWidget *object, gpointer user_data) + { + RunNonmodalInfo *info = user_data; + +@@ -1375,7 +1382,7 @@ + + g_object_ref(dialog); + +- if (! GTK_WIDGET_VISIBLE(dialog)) ++ if (! gtk_widget_get_visible(dialog)) + gtk_widget_show(GTK_WIDGET(dialog)); + + g_object_connect(dialog, +--- src/mn-main.c.gtk3 2008-05-22 17:45:35.000000000 +0200 ++++ src/mn-main.c 2011-02-08 23:32:33.800030659 +0100 +@@ -21,7 +21,7 @@ + #include <stdlib.h> + #include <signal.h> + #include <glib/gi18n.h> +-#include <gnome.h> ++#include <libgnome/libgnome.h> + #include <libgnomevfs/gnome-vfs.h> + #include <libnotify/notify.h> + #include <dbus/dbus-glib-lowlevel.h> +@@ -452,7 +452,7 @@ + + gnome_program_init(PACKAGE, + VERSION, +- LIBGNOMEUI_MODULE, ++ LIBGNOME_MODULE, + argc, + argv, + GNOME_PARAM_HUMAN_READABLE_NAME, _("Mail Notification"), +@@ -460,6 +460,8 @@ + GNOME_PARAM_GOPTION_CONTEXT, option_context, + NULL); + ++ gtk_init(&argc, &argv); ++ + if (arg_version) + { + print_version(); +@@ -497,7 +499,9 @@ + if (! gnome_vfs_init()) + mn_show_fatal_error_dialog(NULL, _("Unable to initialize the GnomeVFS library.")); + ++#if 0 + gnome_authentication_manager_init(); ++#endif + + /* must be called before init_gmime() */ + mn_conf_init(); +--- src/mn-conf.c.gtk3 2008-05-22 17:45:35.000000000 +0200 ++++ src/mn-conf.c 2011-02-07 20:07:01.630580132 +0100 +@@ -23,7 +23,7 @@ + #include <errno.h> + #include <stdarg.h> + #include <glib/gi18n.h> +-#include <gnome.h> ++#include <libgnome/libgnome.h> + #include "mn-util.h" + #include "mn-conf.h" + #include "mn-shell.h" +--- data/mail-notification.desktop.in.orig 2011-07-08 13:46:52.327548264 +0200 ++++ data/mail-notification.desktop.in 2011-07-08 13:47:00.732704467 +0200 +@@ -5,7 +5,7 @@ + _Comment=Get notified when new mail arrives + Type=Application + Categories=GNOME;GTK;Network;Email; +-Exec=mail-notification --sm-disable ++Exec=mail-notification + Terminal=false + StartupNotify=true + X-GNOME-DocPath=mail-notification/mail-notification.xml diff --git a/testing/mail-notification/mail-notification-5.4-icons.patch b/testing/mail-notification/mail-notification-5.4-icons.patch new file mode 100644 index 000000000..48d54742a --- /dev/null +++ b/testing/mail-notification/mail-notification-5.4-icons.patch @@ -0,0 +1,39 @@ +diff -Nrbu mail-notification-5.4/src/mn-stock.c mail-notification-5.4-OK/src/mn-stock.c +--- mail-notification-5.4/src/mn-stock.c 2008-05-22 19:45:35.000000000 +0400 ++++ mail-notification-5.4-OK/src/mn-stock.c 2010-05-24 19:36:03.000000000 +0400 +@@ -32,11 +32,11 @@ + const char *icon_name; + const char *source_stock_id; + } icons[] = { +- { MN_STOCK_MAIL, NULL, "stock_mail" }, +- { MN_STOCK_NO_MAIL, NULL, "stock_inbox" }, +- { MN_STOCK_LOCAL, NULL, "stock_folder" }, +- { MN_STOCK_REMOTE, NULL, "stock_internet" }, +- { MN_STOCK_UNKNOWN, NULL, "stock_unknown" }, ++ { MN_STOCK_MAIL, NULL, "mail-message-new" }, ++ { MN_STOCK_NO_MAIL, NULL, "mail-notification" }, ++ { MN_STOCK_LOCAL, NULL, "folder" }, ++ { MN_STOCK_REMOTE, NULL, "applications-internet" }, ++ { MN_STOCK_UNKNOWN, NULL, "dialog-question" }, + { MN_STOCK_ERROR, NULL, NULL, GTK_STOCK_DIALOG_ERROR }, + #if WITH_GMAIL + { MN_STOCK_GMAIL, PKGDATADIR G_DIR_SEPARATOR_S "gmail.png" }, +@@ -48,14 +48,14 @@ + { MN_STOCK_HOTMAIL, PKGDATADIR G_DIR_SEPARATOR_S "hotmail.png" }, + #endif + #if WITH_MBOX || WITH_MOZILLA || WITH_MH || WITH_MAILDIR || WITH_SYLPHEED +- { MN_STOCK_SYSTEM_MAILBOX, NULL, "system" }, ++ { MN_STOCK_SYSTEM_MAILBOX, NULL, "applications-system" }, + #endif + #if WITH_EVOLUTION + { MN_STOCK_EVOLUTION_MAILBOX, NULL, "evolution" }, + #endif +- { MN_STOCK_MAIL_READER, NULL, "stock_mail-handling" }, +- { MN_STOCK_OPEN_MESSAGE, NULL, "stock_mail-open" }, +- { MN_STOCK_CONSIDER_NEW_MAIL_AS_READ, NULL, "stock_mark" } ++ { MN_STOCK_MAIL_READER, NULL, "mail-unread" }, ++ { MN_STOCK_OPEN_MESSAGE, NULL, "mail-read" }, ++ { MN_STOCK_CONSIDER_NEW_MAIL_AS_READ, NULL, "mail-mark-read" } + }; + GtkIconFactory *factory; + GtkIconTheme *icon_theme; diff --git a/testing/mail-notification/mail-notification-5.4-kde-trayicon.patch b/testing/mail-notification/mail-notification-5.4-kde-trayicon.patch new file mode 100644 index 000000000..a3bdc8372 --- /dev/null +++ b/testing/mail-notification/mail-notification-5.4-kde-trayicon.patch @@ -0,0 +1,72 @@ +diff -Nrbu mail-notification-5.4/build/src/mn-shell.c mail-notification-5.4-OK/build/src/mn-shell.c +--- mail-notification-5.4/build/src/mn-shell.c 2010-10-11 17:45:23.000000000 +0400 ++++ mail-notification-5.4-OK/build/src/mn-shell.c 2010-10-11 17:45:48.000000000 +0400 +@@ -313,6 +313,29 @@ + #undef __GOB_FUNCTION__ + + static void ++mn_shell_init_icon_base (MNShell * self) ++{ ++ g_return_if_fail (self != NULL); ++ g_return_if_fail (MN_IS_SHELL (self)); ++ ++ self->icon = MN_MAIL_ICON(mn_mail_icon_new()); ++ mn_add_weak_pointer(&self->icon); ++ ++ g_object_connect(self->icon, ++ "signal::activate", self_icon_activate_h, self, ++ "signal::activate-mail-reader", self_icon_activate_mail_reader_h, self, ++ "signal::activate-open-latest-message", self_icon_activate_open_latest_message_h, self, ++ "swapped-signal::activate-consider-new-mail-as-read", self_consider_new_mail_as_read, self, ++ "swapped-signal::activate-update", self_update, self, ++ "signal::activate-properties", self_icon_activate_properties_h, self, ++ "signal::activate-help", self_icon_activate_help_h, self, ++ "signal::activate-about", self_icon_activate_about_h, self, ++ "swapped-signal::activate-remove", self_quit, self, ++ "signal::destroy", self_icon_destroy_h, self, ++ NULL); ++} ++ ++static void + mn_shell_init (MNShell * o G_GNUC_UNUSED) + { + #define __GOB_FUNCTION__ "MN:Shell::init" +@@ -793,22 +816,7 @@ + { + #line 360 "src/mn-shell.gob" + +- self->icon = MN_MAIL_ICON(mn_mail_icon_new()); +- mn_add_weak_pointer(&self->icon); +- +- g_object_connect(self->icon, +- "signal::activate", self_icon_activate_h, self, +- "signal::activate-mail-reader", self_icon_activate_mail_reader_h, self, +- "signal::activate-open-latest-message", self_icon_activate_open_latest_message_h, self, +- "swapped-signal::activate-consider-new-mail-as-read", self_consider_new_mail_as_read, self, +- "swapped-signal::activate-update", self_update, self, +- "signal::activate-properties", self_icon_activate_properties_h, self, +- "signal::activate-help", self_icon_activate_help_h, self, +- "signal::activate-about", self_icon_activate_about_h, self, +- "swapped-signal::activate-remove", self_quit, self, +- "signal::destroy", self_icon_destroy_h, self, +- NULL); +- ++ mn_shell_init_icon_base(self); + self_update_sensitivity(self); + self_update_tooltip(self); + self_update_icon(self); +@@ -1094,7 +1102,13 @@ + } + else + { +- gtk_widget_hide(GTK_WIDGET(self->icon)); ++ /* Re-create the icon as a regular gtk_widget_hide causes the ++ * icon to remain visible on non-GNOME environments. We can't ++ * use the callback self_icon_destroy_h here as it can cause an ++ * endless recursion */ ++ g_signal_handlers_disconnect_by_func(self->icon, self_icon_destroy_h, self); ++ gtk_widget_destroy(GTK_WIDGET(self->icon)); ++ mn_shell_init_icon_base(self); + mn_mail_icon_set_blinking(self->icon, FALSE); + } + }} diff --git a/testing/mail-notification/mail-notification-5.4-libx11.patch b/testing/mail-notification/mail-notification-5.4-libx11.patch new file mode 100644 index 000000000..bb3574fda --- /dev/null +++ b/testing/mail-notification/mail-notification-5.4-libx11.patch @@ -0,0 +1,13 @@ +Link with libX11 explicitly. + +--- mail-notification-5.4.dfsg.1.orig/jbsrc/jb.c ++++ mail-notification-5.4.dfsg.1/jbsrc/jb.c +@@ -445,6 +445,8 @@ + + jb_compile_options_add_libs(object->compile_options, "-lm"); + ++ jb_compile_options_add_libs(object->compile_options, "-lX11"); ++ + jb_compile_options_add_package(object->compile_options, "gettext"); + jb_compile_options_add_package(object->compile_options, "gnome"); + jb_compile_options_add_package(object->compile_options, "dbus"); diff --git a/testing/mail-notification/mail-notification-5.4-popup-attach.patch b/testing/mail-notification/mail-notification-5.4-popup-attach.patch new file mode 100644 index 000000000..b8d5f6a09 --- /dev/null +++ b/testing/mail-notification/mail-notification-5.4-popup-attach.patch @@ -0,0 +1,45 @@ +diff -Nrbu mail-notification-5.4/build/src/mn-popup.c mail-notification-5.4-OK/build/src/mn-popup.c +--- mail-notification-5.4/build/src/mn-popup.c 2008-05-22 19:47:49.000000000 +0400 ++++ mail-notification-5.4-OK/build/src/mn-popup.c 2010-10-11 17:42:32.000000000 +0400 +@@ -177,6 +177,29 @@ + #undef __GOB_FUNCTION__ + + static void ++mn_popup_wait_for_icon_to_become_ready (void) ++{ ++ int x, y; ++ int count = 0; ++ ++ /* When the tray icon is created, it can still take some time before ++ * it has arrived at the correct position. This is especially the case ++ * on KDE environments. To work around this, add a little delay of at ++ * most 2 seconds before showing a popup which is attached to the notification */ ++ do { ++ gdk_window_get_origin (gtk_widget_get_window (mn_shell->icon), &x, &y); ++ ++ if (x != 0 || y != 0) { ++ break; ++ } ++ ++ g_usleep(G_USEC_PER_SEC / 10); ++ count++; ++ } while (count < 20); ++} ++ ++ ++static void + mn_popup_init (MNPopup * o G_GNUC_UNUSED) + { + #define __GOB_FUNCTION__ "MN:Popup::init" +@@ -299,8 +322,10 @@ + "icon-name", "stock_mail", + NULL); + +- if (mn_conf_get_enum_value(MN_TYPE_POPUP_POSITION, MN_CONF_POPUPS_POSITION) == MN_POPUP_POSITION_ATTACHED) ++ if (mn_conf_get_enum_value(MN_TYPE_POPUP_POSITION, MN_CONF_POPUPS_POSITION) == MN_POPUP_POSITION_ATTACHED) { ++ mn_popup_wait_for_icon_to_become_ready(); + g_object_set(self, "attach-widget", mn_shell->icon, NULL); ++ } + + g_string_free(body, TRUE); + diff --git a/testing/mail-notification/mail-notification-5.4-sasl_encode64.patch b/testing/mail-notification/mail-notification-5.4-sasl_encode64.patch new file mode 100644 index 000000000..80a7304d1 --- /dev/null +++ b/testing/mail-notification/mail-notification-5.4-sasl_encode64.patch @@ -0,0 +1,24 @@ +diff -up mail-notification-5.4/build/src/mn-pop3-mailbox.c mail-notification-5.4-OK/build/src/mn-pop3-mailbox.c +--- mail-notification-5.4/build/src/mn-pop3-mailbox.c 2009-05-19 10:29:58.448201837 +0200 ++++ mail-notification-5.4-OK/build/src/mn-pop3-mailbox.c 2009-05-19 10:23:29.356204287 +0200 +@@ -619,7 +619,7 @@ mn_pop3_mailbox_enter_auth_cb (MNClientS + + if (initial_clientoutlen > 0) + { +- char buf64[initial_clientoutlen * 2]; /* Base64 is 33% larger than the data it encodes */ ++ char buf64[initial_clientoutlen * 2 + 1]; /* Base64 is 33% larger than the data it encodes */ + unsigned int outlen; + int result; + char *str; +diff -up mail-notification-5.4/src/mn-client-session.c mail-notification-5.4-OK/src/mn-client-session.c +--- mail-notification-5.4/src/mn-client-session.c 2008-05-22 17:45:35.000000000 +0200 ++++ mail-notification-5.4-OK/src/mn-client-session.c 2009-05-19 10:29:09.112211055 +0200 +@@ -1030,7 +1030,7 @@ mn_client_session_write (MNClientSession + static int + write_base64 (MNClientSession *session, const char *buf, unsigned int len) + { +- char buf64[len * 2]; /* Base64 is 33% larger than the data it encodes */ ++ char buf64[len * 2 + 1]; /* Base64 is 33% larger than the data it encodes */ + unsigned int outlen; + int result; + char *str; diff --git a/testing/mail-notification/mail-notification-5.4-weak.patch b/testing/mail-notification/mail-notification-5.4-weak.patch new file mode 100644 index 000000000..2e2a233aa --- /dev/null +++ b/testing/mail-notification/mail-notification-5.4-weak.patch @@ -0,0 +1,11 @@ +diff -Nrbu mail-notification-5.4/build/src/mn-shell.c mail-notification-5.4-OK/build/src/mn-shell.c +--- mail-notification-5.4/build/src/mn-shell.c 2008-05-22 19:47:49.000000000 +0400 ++++ mail-notification-5.4-OK/build/src/mn-shell.c 2010-05-24 19:39:48.000000000 +0400 +@@ -1008,6 +1008,7 @@ + Self *self = user_data; + + /* The Notification Area applet has been terminated. Recreate the icon. */ ++ mn_remove_weak_pointer(&self->icon); + self_init_icon(self); + }} + #line 1014 "mn-shell.c" diff --git a/testing/mail-notification/mail-notification.install b/testing/mail-notification/mail-notification.install new file mode 100644 index 000000000..21cd94399 --- /dev/null +++ b/testing/mail-notification/mail-notification.install @@ -0,0 +1,24 @@ +pkgname=mail-notification + +post_install() { + usr/sbin/gconfpkg --install ${pkgname} + kill -s HUP `pidof bonobo-activation-server` > /dev/null 2>&1 + gtk-update-icon-cache -q -t -f usr/share/icons/hicolor +} + +pre_upgrade() { + pre_remove $1 +} + +post_upgrade() { + post_install $1 +} + +pre_remove() { + usr/sbin/gconfpkg --uninstall ${pkgname} +} + +post_remove() { + kill -s HUP `pidof bonobo-activation-server` > /dev/null 2>&1 + gtk-update-icon-cache -q -t -f usr/share/icons/hicolor +} diff --git a/testing/mail-notification/remove-ubuntu-special-case.patch b/testing/mail-notification/remove-ubuntu-special-case.patch new file mode 100644 index 000000000..4516f32c6 --- /dev/null +++ b/testing/mail-notification/remove-ubuntu-special-case.patch @@ -0,0 +1,33 @@ +--- jbsrc/lib/src/core/jb-feature.c.~1~ 2008-04-27 16:47:27.000000000 +0200 ++++ jbsrc/lib/src/core/jb-feature.c 2008-07-22 11:40:50.856886210 +0200 +@@ -164,8 +164,6 @@ + static void + gconf_configure (void) + { +- JBVariable *variable; +- + jb_require_program("gconftool-2"); + + if (! strcmp(jb_variable_get_string("gconf-config-source"), "autodetect")) +@@ -178,21 +176,6 @@ + jb_variable_set_string("gconf-config-source", config_source); + g_free(config_source); + } +- +- /* fix the default schemas dir on Ubuntu */ +- variable = jb_variable_get_variable_or_error("gconf-schemas-dir"); +- if (! variable->user_set) +- { +- static const char *ubuntu_dir = "$datadir/gconf/schemas"; +- char *expanded; +- +- expanded = jb_variable_expand(ubuntu_dir, NULL); +- +- if (g_file_test(expanded, G_FILE_TEST_IS_DIR)) +- jb_variable_set_string("gconf-schemas-dir", ubuntu_dir); +- +- g_free(expanded); +- } + } + + static void diff --git a/testing/systemd/0001-tmpfiles-fix-parsing-of-proc-net-unix-on-32Bit-machi.patch b/testing/systemd/0001-tmpfiles-fix-parsing-of-proc-net-unix-on-32Bit-machi.patch new file mode 100644 index 000000000..456d679ed --- /dev/null +++ b/testing/systemd/0001-tmpfiles-fix-parsing-of-proc-net-unix-on-32Bit-machi.patch @@ -0,0 +1,87 @@ +From fdcad0c25579a60061b1fda956686e878a80faef Mon Sep 17 00:00:00 2001 +From: Lennart Poettering <lennart@poettering.net> +Date: Wed, 11 Jan 2012 22:07:35 +0100 +Subject: [PATCH] tmpfiles: fix parsing of /proc/net/unix on 32Bit machines + +Tracked down by Michael Meeks +--- + src/tmpfiles.c | 30 ++++++++++++++++++++---------- + 1 files changed, 20 insertions(+), 10 deletions(-) + +diff --git a/src/tmpfiles.c b/src/tmpfiles.c +index 19a7c08..44e5c9d 100644 +--- a/src/tmpfiles.c ++++ b/src/tmpfiles.c +@@ -117,41 +117,50 @@ static void load_unix_sockets(void) { + /* We maintain a cache of the sockets we found in + * /proc/net/unix to speed things up a little. */ + +- if (!(unix_sockets = set_new(string_hash_func, string_compare_func))) ++ unix_sockets = set_new(string_hash_func, string_compare_func); ++ if (!unix_sockets) + return; + +- if (!(f = fopen("/proc/net/unix", "re"))) ++ f = fopen("/proc/net/unix", "re"); ++ if (!f) + return; + +- if (!(fgets(line, sizeof(line), f))) ++ /* Skip header */ ++ if (!fgets(line, sizeof(line), f)) + goto fail; + + for (;;) { + char *p, *s; + int k; + +- if (!(fgets(line, sizeof(line), f))) ++ if (!fgets(line, sizeof(line), f)) + break; + + truncate_nl(line); + +- if (strlen(line) < 53) ++ p = strchr(line, ':'); ++ if (!p) ++ continue; ++ ++ if (strlen(p) < 37) + continue; + +- p = line + 53; ++ p += 37; + p += strspn(p, WHITESPACE); +- p += strcspn(p, WHITESPACE); ++ p += strcspn(p, WHITESPACE); /* skip one more word */ + p += strspn(p, WHITESPACE); + + if (*p != '/') + continue; + +- if (!(s = strdup(p))) ++ s = strdup(p); ++ if (!s) + goto fail; + + path_kill_slashes(s); + +- if ((k = set_put(unix_sockets, s)) < 0) { ++ k = set_put(unix_sockets, s); ++ if (k < 0) { + free(s); + + if (k != -EEXIST) +@@ -1059,7 +1068,8 @@ int main(int argc, char *argv[]) { + Item *i; + Iterator iterator; + +- if ((r = parse_argv(argc, argv)) <= 0) ++ r = parse_argv(argc, argv); ++ if (r <= 0) + return r < 0 ? EXIT_FAILURE : EXIT_SUCCESS; + + log_set_target(LOG_TARGET_AUTO); +-- +1.7.8.3 + diff --git a/testing/systemd/0001-units-make-sure-syslog-socket-goes-away-early-during.patch b/testing/systemd/0001-units-make-sure-syslog-socket-goes-away-early-during.patch new file mode 100644 index 000000000..49248a6a4 --- /dev/null +++ b/testing/systemd/0001-units-make-sure-syslog-socket-goes-away-early-during.patch @@ -0,0 +1,26 @@ +From ead51eb4ed55981f290e40a871ffbca6480c4cd3 Mon Sep 17 00:00:00 2001 +From: Lennart Poettering <lennart@poettering.net> +Date: Thu, 12 Jan 2012 04:34:50 +0100 +Subject: [PATCH] units: make sure syslog socket goes away early during + shutdown + +--- + units/syslog.socket | 2 ++ + 1 files changed, 2 insertions(+), 0 deletions(-) + +diff --git a/units/syslog.socket b/units/syslog.socket +index 323fa86..657e791 100644 +--- a/units/syslog.socket ++++ b/units/syslog.socket +@@ -11,6 +11,8 @@ + Description=Syslog Socket + DefaultDependencies=no + Before=sockets.target syslog.target ++Conflicts=shutdown.target ++Before=shutdown.target + + # Pull in syslog.target to tell people that /dev/log is now accessible + Wants=syslog.target +-- +1.7.8.3 + diff --git a/testing/systemd/PKGBUILD b/testing/systemd/PKGBUILD index da1a936ae..1dea4b12a 100644 --- a/testing/systemd/PKGBUILD +++ b/testing/systemd/PKGBUILD @@ -1,15 +1,15 @@ -# $Id: PKGBUILD 146498 2012-01-12 03:32:19Z dreisner $ +# $Id: PKGBUILD 146631 2012-01-14 21:33:48Z dreisner $ # Maintainer: Dave Reisner <dreisner@archlinux.org> pkgname=systemd pkgver=38 -pkgrel=1 +pkgrel=2 pkgdesc="Session and Startup manager" arch=('i686' 'x86_64') url="http://www.freedesktop.org/wiki/Software/systemd" license=('GPL2') -depends=('dbus-core' 'kbd' 'libcap' 'util-linux>=2.19' 'udev>=172' 'xz') -makedepends=('acl' 'gperf' 'cryptsetup' 'intltool' 'linux-api-headers') +depends=('acl' 'dbus-core' 'kbd' 'libcap' 'util-linux>=2.19' 'udev>=172' 'xz') +makedepends=('gperf' 'cryptsetup' 'intltool' 'linux-api-headers') optdepends=('cryptsetup: required for encrypted block devices' 'dbus-python: systemd-analyze' 'initscripts: legacy support for hostname and vconsole setup' @@ -28,9 +28,13 @@ backup=(etc/dbus-1/system.d/org.freedesktop.systemd1.conf etc/systemd/systemd-logind.conf) install=systemd.install source=("http://www.freedesktop.org/software/$pkgname/$pkgname-$pkgver.tar.xz" - "os-release") + "os-release" + '0001-tmpfiles-fix-parsing-of-proc-net-unix-on-32Bit-machi.patch' + '0001-units-make-sure-syslog-socket-goes-away-early-during.patch') md5sums=('68c66dce5a28c0efd7c210af5d11efed' - '752636def0db3c03f121f8b4f44a63cd') + '752636def0db3c03f121f8b4f44a63cd' + '07437e70be65ef14fd4f13c5ec5bd1fe' + 'c567ce597f68c07b9bc5b7e835f80f7d') build() { cd "$pkgname-$pkgver" @@ -40,13 +44,14 @@ build() { sed -i -e '/^Environ.*LANG/s/^/#/' \ -e '/^ExecStart/s/agetty/& -8/' units/getty@.service.m4 + patch -Np1 < "$srcdir/0001-tmpfiles-fix-parsing-of-proc-net-unix-on-32Bit-machi.patch" + patch -Np1 < "$srcdir/0001-units-make-sure-syslog-socket-goes-away-early-during.patch" ./configure --sysconfdir=/etc \ --libexecdir=/usr/lib \ --libdir=/usr/lib \ --localstatedir=/var \ - --with-rootprefix= \ - --with-rootlibdir=/lib + --with-rootprefix= make diff --git a/testing/totem-plparser/PKGBUILD b/testing/totem-plparser/PKGBUILD index feac870e6..f63b5c140 100644 --- a/testing/totem-plparser/PKGBUILD +++ b/testing/totem-plparser/PKGBUILD @@ -1,15 +1,15 @@ -# $Id: PKGBUILD 146042 2012-01-04 16:37:02Z ibiru $ +# $Id: PKGBUILD 146624 2012-01-14 12:24:19Z ibiru $ # Maintainer: Jan de Groot <jgc@archlinux.org> pkgname=totem-plparser pkgver=2.32.6 -pkgrel=2 +pkgrel=3 url="http://www.hadess.net/totem.php3" pkgdesc="Totem playlist parser library" license=('LGPL') arch=(i686 x86_64) depends=('gmime' 'libsoup-gnome' 'libarchive') -makedepends=('intltool' 'pkgconfig' 'gobject-introspection') +makedepends=('intltool' 'gobject-introspection') options=('!libtool') source=(http://ftp.gnome.org/pub/gnome/sources/totem-pl-parser/2.32/totem-pl-parser-$pkgver.tar.xz) sha256sums=('8e6ccef547f1ad311474a975032d2482e621550ee3d4d22c725cdc6b496e4874') |