From 065cf8163398f8da177e9f09f5a5e97a063ca5c5 Mon Sep 17 00:00:00 2001 From: root Date: Wed, 9 May 2012 00:01:39 +0000 Subject: Wed May 9 00:01:39 UTC 2012 --- community/bitcoin/PKGBUILD | 20 +- community/libquvi/PKGBUILD | 11 +- community/quvi/PKGBUILD | 8 +- extra/glade/PKGBUILD | 6 +- extra/ifplugd/PKGBUILD | 6 +- extra/ifplugd/ifplugd | 6 +- extra/nautilus/PKGBUILD | 11 +- extra/nautilus/samba-crash.patch | 32 +++ extra/pidgin/PKGBUILD | 30 +- multilib-testing/gcc-multilib/PKGBUILD | 313 +++++++++++++++++++++ .../gcc-multilib/gcc-4.7.0-cloog-0.17.patch | 24 ++ multilib-testing/gcc-multilib/gcc-ada.install | 20 ++ multilib-testing/gcc-multilib/gcc-fortran.install | 16 ++ multilib-testing/gcc-multilib/gcc-go.install | 20 ++ multilib-testing/gcc-multilib/gcc-libs.install | 16 ++ multilib-testing/gcc-multilib/gcc.install | 20 ++ .../gcc-multilib/gcc_pure64-multilib.patch | 22 ++ testing/gcc/PKGBUILD | 265 +++++++++++++++++ testing/gcc/gcc-4.7.0-cloog-0.17.patch | 24 ++ testing/gcc/gcc-ada.install | 20 ++ testing/gcc/gcc-fortran.install | 16 ++ testing/gcc/gcc-go.install | 20 ++ testing/gcc/gcc-libs.install | 16 ++ testing/gcc/gcc.install | 20 ++ testing/gcc/gcc_pure64.patch | 26 ++ testing/gmp/PKGBUILD | 37 +++ testing/gmp/gmp.install | 20 ++ testing/libusb-compat/PKGBUILD | 27 ++ 28 files changed, 1019 insertions(+), 53 deletions(-) create mode 100644 extra/nautilus/samba-crash.patch create mode 100644 multilib-testing/gcc-multilib/PKGBUILD create mode 100644 multilib-testing/gcc-multilib/gcc-4.7.0-cloog-0.17.patch create mode 100644 multilib-testing/gcc-multilib/gcc-ada.install create mode 100644 multilib-testing/gcc-multilib/gcc-fortran.install create mode 100644 multilib-testing/gcc-multilib/gcc-go.install create mode 100644 multilib-testing/gcc-multilib/gcc-libs.install create mode 100644 multilib-testing/gcc-multilib/gcc.install create mode 100644 multilib-testing/gcc-multilib/gcc_pure64-multilib.patch create mode 100644 testing/gcc/PKGBUILD create mode 100644 testing/gcc/gcc-4.7.0-cloog-0.17.patch create mode 100644 testing/gcc/gcc-ada.install create mode 100644 testing/gcc/gcc-fortran.install create mode 100644 testing/gcc/gcc-go.install create mode 100644 testing/gcc/gcc-libs.install create mode 100644 testing/gcc/gcc.install create mode 100644 testing/gcc/gcc_pure64.patch create mode 100644 testing/gmp/PKGBUILD create mode 100644 testing/gmp/gmp.install create mode 100644 testing/libusb-compat/PKGBUILD diff --git a/community/bitcoin/PKGBUILD b/community/bitcoin/PKGBUILD index 00d2cc85f..260082f54 100644 --- a/community/bitcoin/PKGBUILD +++ b/community/bitcoin/PKGBUILD @@ -1,10 +1,11 @@ -# $Id: PKGBUILD 69400 2012-04-15 20:25:26Z tredaelli $ +# $Id: PKGBUILD 70450 2012-05-07 11:38:52Z tredaelli $ # Maintainer: Timothy Redaelli # Contributor: shahid pkgbase=bitcoin pkgname=('bitcoin-daemon' 'bitcoin-qt') -pkgver=0.6.0 +pkgver=0.6.1 +_commit=dbb656f pkgrel=1 arch=('i686' 'x86_64') url="http://www.bitcoin.org/" @@ -12,21 +13,18 @@ makedepends=('boost' 'automoc4' 'miniupnpc') conflicts=('bitcoin' 'bitcoin-bin' 'bitcoin-git') replaces=('bitcoin' 'bitcoin-bin' 'bitcoin-git') license=('MIT') -source=("http://downloads.sourceforge.net/sourceforge/${pkgbase}/${pkgbase}-${pkgver}-linux.tar.gz") -sha256sums=('13faa8b7c8c9ce3518ebe31ff2d97920f4feb4f06c1d08455b272fdaaeeb1f97') +source=("$pkgbase-$pkgver.tar.gz::https://github.com/bitcoin/$pkgbase/tarball/v$pkgver") +sha256sums=('bc37bc3c91ff39754cee511047d9ff7e8f76e06ac35bb345bcb1c0935e2b2eee') build() { - cd "$srcdir/$pkgbase-$pkgver-linux/src" - - # FIXME GCC 4.7.0 is too strict - echo "QMAKE_CXXFLAGS += $CXXFLAGS -fpermissive" >> bitcoin-qt.pro + cd "$srcdir/bitcoin-$pkgbase-$_commit" # and make qt gui qmake make # make bitcoind - make -f makefile.unix -C src CXXFLAGS="$CXXFLAGS -fpermissive" USE_UPNP=1 + make -f makefile.unix -C src CXXFLAGS="$CXXFLAGS" USE_UPNP=1 } @@ -35,7 +33,7 @@ package_bitcoin-qt() { depends=(boost-libs qt miniupnpc) install=bitcoin-qt.install - cd "$srcdir/$pkgbase-$pkgver-linux/src" + cd "$srcdir/bitcoin-$pkgbase-$_commit" install -Dm755 bitcoin-qt "$pkgdir"/usr/bin/bitcoin-qt install -Dm644 contrib/debian/bitcoin-qt.desktop \ "$pkgdir"/usr/share/applications/bitcoin.desktop @@ -49,7 +47,7 @@ package_bitcoin-daemon() { pkgdesc="Bitcoin is a peer-to-peer network based digital currency - daemon" depends=(boost-libs miniupnpc openssl) - cd "$srcdir/$pkgbase-$pkgver-linux/src" + cd "$srcdir/bitcoin-$pkgbase-$_commit" install -Dm755 src/bitcoind "$pkgdir"/usr/bin/bitcoind install -Dm644 contrib/debian/examples/bitcoin.conf \ "$pkgdir/usr/share/doc/$pkgname/examples/bitcoin.conf" diff --git a/community/libquvi/PKGBUILD b/community/libquvi/PKGBUILD index bc155076e..c9a3cffac 100644 --- a/community/libquvi/PKGBUILD +++ b/community/libquvi/PKGBUILD @@ -1,9 +1,9 @@ -# $Id: PKGBUILD 66396 2012-02-24 12:56:50Z lfleischer $ +# $Id: PKGBUILD 70444 2012-05-07 08:28:44Z lfleischer $ # Maintainer: Lukas Fleischer pkgname=libquvi -pkgver=0.4.0 -pkgrel=3 +pkgver=0.4.1 +pkgrel=1 pkgdesc='Library for parsing video download links.' arch=('i686' 'x86_64') url='http://quvi.sourceforge.net/' @@ -11,8 +11,9 @@ license=('LGPL') depends=('libquvi-scripts' 'curl' 'lua') conflicts=('quvi<0.4.0') options=('!libtool') -source=("http://downloads.sourceforge.net/sourceforge/quvi/${pkgname}-${pkgver}.tar.gz") -md5sums=('85c47035105b6b523a28793d4f6da9f1') +source=("http://downloads.sourceforge.net/sourceforge/quvi/${pkgname}-${pkgver}.tar.gz"{,.sig}) +md5sums=('a5fa8860c23655a529b3166f6e25c83a' + 'cc7f15518f8ab2fc134bc64f0e9d584b') build() { cd "${pkgname}-${pkgver}" diff --git a/community/quvi/PKGBUILD b/community/quvi/PKGBUILD index ea737ac4b..3bb48927d 100644 --- a/community/quvi/PKGBUILD +++ b/community/quvi/PKGBUILD @@ -1,9 +1,9 @@ -# $Id: PKGBUILD 59896 2011-12-02 07:00:15Z lfleischer $ +# $Id: PKGBUILD 70446 2012-05-07 08:29:18Z lfleischer $ # Maintainer: Lukas Fleischer # Contributor: joyfulgirl@archlinux.us pkgname=quvi -pkgver=0.4.1 +pkgver=0.4.2 pkgrel=1 pkgdesc='Command-line tool for parsing video download links.' arch=('i686' 'x86_64') @@ -12,8 +12,8 @@ license=('LGPL') depends=('libquvi') options=('!libtool') source=("http://downloads.sourceforge.net/sourceforge/${pkgname}/${pkgname}-${pkgver}.tar.gz"{,.sig}) -md5sums=('0975e3d8cdf570d2143c49c249e698c5' - '53e2e206c17cb6a38c8c6b7b427b8b4a') +md5sums=('05f1e2c711d1ca9d4bc68b8de553941d' + '523b17d5a9024c8b0a1636917d79e792') build() { cd "${pkgname}-${pkgver}" diff --git a/extra/glade/PKGBUILD b/extra/glade/PKGBUILD index 40b2f5361..af7b9d00e 100644 --- a/extra/glade/PKGBUILD +++ b/extra/glade/PKGBUILD @@ -1,8 +1,8 @@ -# $Id: PKGBUILD 156788 2012-04-23 09:05:39Z ibiru $ +# $Id: PKGBUILD 158695 2012-05-07 14:01:07Z ibiru $ # Maintainer: Douglas Soares de Andrade pkgname=glade -pkgver=3.12.0 +pkgver=3.12.1 pkgrel=1 pkgdesc="User interface builder for GTK+ and GNOME." arch=(i686 x86_64) @@ -14,7 +14,7 @@ options=('!libtool') url="http://glade.gnome.org/" install=glade.install source=(http://ftp.gnome.org/pub/GNOME/sources/$pkgname/${pkgver%.*}/$pkgname-$pkgver.tar.xz) -sha256sums=('70a820a0007fa3ed7761c92b011fe35ac1532038cab2f9ab30f4d29d5799d44d') +sha256sums=('27e89fb743adb9996c418aa70cde8ce3c0769103f3691cc8011e6c6846600e76') build() { cd "$pkgname-$pkgver" diff --git a/extra/ifplugd/PKGBUILD b/extra/ifplugd/PKGBUILD index cde1a503b..420bf90d5 100644 --- a/extra/ifplugd/PKGBUILD +++ b/extra/ifplugd/PKGBUILD @@ -1,11 +1,11 @@ -# $Id: PKGBUILD 157472 2012-04-28 18:54:17Z dreisner $ +# $Id: PKGBUILD 158689 2012-05-07 09:54:25Z dreisner $ # Contributor: Manolis Tzanidakis # Contributor: kevin # Maintainer: pkgname=ifplugd pkgver=0.28 -pkgrel=10 +pkgrel=11 pkgdesc="A daemon which brings up/down network interfaces upon cable insertion/removal." arch=('i686' 'x86_64') url="http://0pointer.de/lennart/projects/ifplugd" @@ -15,7 +15,7 @@ backup=('etc/ifplugd/ifplugd.conf' 'etc/ifplugd/ifplugd.action') options=('!makeflags') source=($url/${pkgname}-${pkgver}.tar.gz 'ifplugd' 'ifplugd.action' 'ifplugd-0.28-interface.patch' 'ifdown.01-route.sh' 'ifup.01-route.sh' 'ifup.02-ntpdate.sh') md5sums=('df6f4bab52f46ffd6eb1f5912d4ccee3' - 'ef27f40434ca85ccaf57a7e388eb001e' + '2281cd3eda9e3403857863e1a1bc00be' '6f98767c4ea2cf0580f73ced81efd21a' '54eb22844b5aeed161c0b80aa9008570' 'd6ce6c7bd481a0b3944c944c5b277c0b' diff --git a/extra/ifplugd/ifplugd b/extra/ifplugd/ifplugd index 667fc1f53..f7c34ade5 100644 --- a/extra/ifplugd/ifplugd +++ b/extra/ifplugd/ifplugd @@ -16,9 +16,11 @@ PID=$(pidof -o %PPID ifplugd) [[ -r $cfg ]] && . "$cfg" # discover interfaces to monitor -# (replacing INTERFACES with net_ifs, since AL +# (replacing INTERFACES with NET_IFS, since AL # already uses it in /etc/rc.conf) -if [[ -z $net_ifs ]]; then +if [[ $NET_IFS ]]; then + net_ifs=($NET_IFS) +else net_ifs=(/sys/class/net/!(lo)) net_ifs=("${net_ifs[@]##*/}") fi diff --git a/extra/nautilus/PKGBUILD b/extra/nautilus/PKGBUILD index d3df231ed..fa79432d3 100644 --- a/extra/nautilus/PKGBUILD +++ b/extra/nautilus/PKGBUILD @@ -1,9 +1,9 @@ -# $Id: PKGBUILD 156938 2012-04-23 09:09:28Z ibiru $ +# $Id: PKGBUILD 158697 2012-05-07 15:42:16Z ibiru $ # Maintainer: Jan de Groot pkgname=nautilus pkgver=3.4.1 -pkgrel=1 +pkgrel=2 pkgdesc="GNOME file manager" arch=('i686' 'x86_64') license=('GPL') @@ -13,11 +13,14 @@ url="http://www.gnome.org" groups=('gnome') options=('!libtool' '!emptydirs') install=nautilus.install -source=(http://ftp.gnome.org/pub/gnome/sources/$pkgname/${pkgver%.*}/$pkgname-$pkgver.tar.xz) -sha256sums=('02581c9475e9c4250960555b248378a6a1c63a5c029728ec48347c78ca77392d') +source=(http://ftp.gnome.org/pub/gnome/sources/$pkgname/${pkgver%.*}/$pkgname-$pkgver.tar.xz + samba-crash.patch) +sha256sums=('02581c9475e9c4250960555b248378a6a1c63a5c029728ec48347c78ca77392d' + 'e437ced7bbebe49d2454b4daecd10cff39d1c427e9631fe0fe5325072ed6aefd') build() { cd "$pkgname-$pkgver" + patch -Np1 -i "$srcdir/samba-crash.patch" ./configure --prefix=/usr --sysconfdir=/etc \ --localstatedir=/var --disable-static \ --libexecdir=/usr/lib/nautilus \ diff --git a/extra/nautilus/samba-crash.patch b/extra/nautilus/samba-crash.patch new file mode 100644 index 000000000..b10d39008 --- /dev/null +++ b/extra/nautilus/samba-crash.patch @@ -0,0 +1,32 @@ +From 4e59e4cfc7bc68534664d9f72d0c7ea680b79db3 Mon Sep 17 00:00:00 2001 +From: Cosimo Cecchi +Date: Fri, 04 May 2012 18:38:43 +0000 +Subject: places-sidebar: don't double unref GMount objects + +Fixes a lot of reported crashers with NFS/Samba volumes. + +https://bugzilla.gnome.org/show_bug.cgi?id=674659 +--- +diff --git a/src/nautilus-places-sidebar.c b/src/nautilus-places-sidebar.c +index 61f3658..672a4b0 100644 +--- a/src/nautilus-places-sidebar.c ++++ b/src/nautilus-places-sidebar.c +@@ -774,7 +774,7 @@ update_places (NautilusPlacesSidebar *sidebar) + root = g_mount_get_default_location (mount); + + if (!g_file_is_native (root)) { +- network_mounts = g_list_prepend (network_mounts, g_object_ref (mount)); ++ network_mounts = g_list_prepend (network_mounts, mount); + continue; + } + +@@ -856,7 +856,6 @@ update_places (NautilusPlacesSidebar *sidebar) + name, icon, mount_uri, + NULL, NULL, mount, 0, tooltip); + g_object_unref (root); +- g_object_unref (mount); + g_object_unref (icon); + g_free (name); + g_free (mount_uri); +-- +cgit v0.9.0.2 diff --git a/extra/pidgin/PKGBUILD b/extra/pidgin/PKGBUILD index 29d04ce3b..7f8df9a63 100644 --- a/extra/pidgin/PKGBUILD +++ b/extra/pidgin/PKGBUILD @@ -1,4 +1,4 @@ -# $Id: PKGBUILD 156957 2012-04-23 09:10:00Z ibiru $ +# $Id: PKGBUILD 158683 2012-05-07 06:27:02Z foutrelis $ # Maintainer: Evangelos Foutras # Contributor: Ionut Biru # Contributor: Andrea Scarpino @@ -6,8 +6,8 @@ # Contributor: Lucien Immink pkgname=('pidgin' 'libpurple' 'finch') -pkgver=2.10.3 -pkgrel=2 +pkgver=2.10.4 +pkgrel=1 arch=('i686' 'x86_64') url="http://pidgin.im/" license=('GPL') @@ -16,21 +16,12 @@ makedepends=('startup-notification' 'gtkspell' 'libxss' 'nss' 'libsasl' 'libsm' 'farstream' 'avahi' 'tk' 'ca-certificates' 'intltool' 'networkmanager') options=('!libtool') -source=(http://downloads.sourceforge.net/$pkgname/$pkgname-$pkgver.tar.bz2 - port-to-farstream-v3.patch) -sha256sums=('0f67d96231fea3945c2735e6a3b4bd92590ef489fa1511fa69aa6a543cb4168b' - '4c11c10da01855afe865408f29f514672b736830105523fe48aa74676d5052ca') +source=(http://downloads.sourceforge.net/$pkgname/$pkgname-$pkgver.tar.bz2) +sha256sums=('8fbef835c8dfa2281532ad7064d664477d72015d6dcd4345362dcfe658aaee0e') build() { cd "$srcdir/$pkgname-$pkgver" - # Apply patch for farsight -> farstream transition - # http://developer.pidgin.im/ticket/14936 - patch -Np1 -i "$srcdir/port-to-farstream-v3.patch" - - # The farstream patch changes configure.ac - autoreconf -vi - # Use Python 2 sed -i 's/env python$/&2/' */plugins/*.py \ libpurple/purple-{remote,notifications-example,url-handler} @@ -54,9 +45,7 @@ package_pidgin(){ depends=('libpurple' 'startup-notification' 'gtkspell' 'libxss' 'libsm' 'gstreamer0.10' 'hicolor-icon-theme') optdepends=('aspell: for spelling correction' - 'ca-certificates: SSL CA certificates' - 'gstreamer0.10-good-plugins: video and voice support' - 'tk: Tcl/Tk scripting support') + 'gstreamer0.10-good-plugins: video and voice support') install=pidgin.install cd "$srcdir/pidgin-$pkgver" @@ -79,7 +68,9 @@ package_libpurple(){ pkgdesc="IM library extracted from Pidgin" depends=('farstream' 'libsasl' 'libidn' 'dbus-glib' 'nss') optdepends=('avahi: Bonjour protocol support' - 'dbus-python: for purple-remote and purple-url-handler') + 'ca-certificates: SSL CA certificates' + 'dbus-python: for purple-remote and purple-url-handler' + 'tk: Tcl/Tk scripting support') cd "$srcdir/pidgin-$pkgver" @@ -91,9 +82,6 @@ package_libpurple(){ package_finch(){ pkgdesc="A ncurses-based messaging client" depends=("libpurple=$pkgver-$pkgrel" 'python2' 'gstreamer0.10') - optdepends=('avahi: Bonjour protocol support' - 'ca-certificates: SSL CA certificates' - 'tk: Tcl/Tk scripting support') cd "$srcdir/pidgin-$pkgver" diff --git a/multilib-testing/gcc-multilib/PKGBUILD b/multilib-testing/gcc-multilib/PKGBUILD new file mode 100644 index 000000000..20d562fe2 --- /dev/null +++ b/multilib-testing/gcc-multilib/PKGBUILD @@ -0,0 +1,313 @@ +# $Id: PKGBUILD 70454 2012-05-07 19:37:47Z heftig $ +# Maintainer: Jan "heftig" Steffens +# Contributor: Allan McRae + +# 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.7.0 +pkgrel=6 +_snapshot=4.7-20120505 +_libstdcppmanver=20120307 # Note: check source directory name when updating this +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++-api.${_libstdcppmanver}.man.tar.bz2 + gcc_pure64-multilib.patch + gcc-4.7.0-cloog-0.17.patch) +md5sums=('8e2df3b9a755c9262db0df019cc3542e' + '489d2f5311535800a120efd8d18db719' + 'ec24c32d3d1030c2bc8cb2ad2d1dc629' + '575f7d17b022e609447a590e481b18b5') + + +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 -p1 -i ${srcdir}/gcc_pure64-multilib.patch + + # compatibility with latest cloog + patch -p1 -i ${srcdir}/gcc-4.7.0-cloog-0.17.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 \ + --disable-libstdcxx-pch --enable-libstdcxx-time \ + --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 \ + --with-linker-hash-style=gnu \ + --enable-multilib --disable-libssp \ + --disable-build-with-cxx --disable-build-poststage1-with-cxx \ + --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.15' "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 libitm; 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 -r ${pkgdir}/usr/lib/{gcc/,libgfortran.spec} + + # remove stuff in lib32-gcc-libs + rm -r ${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.15' "gcc-libs>=$pkgver") + + cd gcc-build + make -j1 -C $CHOST/32/libgcc DESTDIR=${pkgdir} install-shared + for lib in libmudflap libgomp libstdc++-v3/src libitm; 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 -r ${pkgdir}/usr/lib + rm -r ${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 + + make -j1 DESTDIR=${pkgdir} install + + install -d $pkgdir/usr/share/gdb/auto-load/usr/lib + mv $pkgdir{,/usr/share/gdb/auto-load}/usr/lib/libstdc++.so.6.0.17-gdb.py + + # unfortunately it is much, much easier to install the lot and clean-up the mess... + 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} + rm $pkgdir/usr/lib/gcc/$CHOST/${pkgver}/{,32/}{libcaf_single,libgfortranbegin}.a + rm -r $pkgdir/usr/lib{,32}/go + rm $pkgdir/usr/share/info/{gccgo,gfortran,gnat*,libgomp,libquadmath,libitm}.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 -s /usr/bin/cpp ${pkgdir}/lib/cpp + ln -s gcc ${pkgdir}/usr/bin/cc + + # 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}/man/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 + + ln -s gfortran ${pkgdir}/usr/bin/f95 + + # 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 + + ln -s gcc ${pkgdir}/usr/bin/gnatgcc + + # 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-testing/gcc-multilib/gcc-4.7.0-cloog-0.17.patch b/multilib-testing/gcc-multilib/gcc-4.7.0-cloog-0.17.patch new file mode 100644 index 000000000..c7146fa04 --- /dev/null +++ b/multilib-testing/gcc-multilib/gcc-4.7.0-cloog-0.17.patch @@ -0,0 +1,24 @@ +diff -Naur gcc-4.6-20120120-orig/configure gcc-4.6-20120120/configure +--- gcc-4.6-20120120-orig/configure 2011-12-18 20:03:44.000000000 +1000 ++++ gcc-4.6-20120120/configure 2012-02-03 17:55:14.885990135 +1000 +@@ -6049,8 +6049,8 @@ + LDFLAGS="${_cloog_saved_LDFLAGS} ${clooglibs} ${ppllibs}" + + if test "${cloog_org}" = yes ; then +- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for version 0.16.1 of CLooG" >&5 +-$as_echo_n "checking for version 0.16.1 of CLooG... " >&6; } ++ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for version 0.17 of CLooG" >&5 ++$as_echo_n "checking for version 0.17 of CLooG... " >&6; } + if test "${gcc_cv_cloog_ct_0_14_0+set}" = set; then : + $as_echo_n "(cached) " >&6 + else +@@ -6061,8 +6061,7 @@ + main () + { + #if CLOOG_VERSION_MAJOR != 0 \ +- || CLOOG_VERSION_MINOR != 16 \ +- || CLOOG_VERSION_REVISION < 1 ++ || CLOOG_VERSION_MINOR != 17 + choke me + #endif + ; diff --git a/multilib-testing/gcc-multilib/gcc-ada.install b/multilib-testing/gcc-multilib/gcc-ada.install new file mode 100644 index 000000000..df0553a4f --- /dev/null +++ b/multilib-testing/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-testing/gcc-multilib/gcc-fortran.install b/multilib-testing/gcc-multilib/gcc-fortran.install new file mode 100644 index 000000000..b15d89a97 --- /dev/null +++ b/multilib-testing/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-testing/gcc-multilib/gcc-go.install b/multilib-testing/gcc-multilib/gcc-go.install new file mode 100644 index 000000000..7dc50dee5 --- /dev/null +++ b/multilib-testing/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-testing/gcc-multilib/gcc-libs.install b/multilib-testing/gcc-multilib/gcc-libs.install new file mode 100644 index 000000000..23553b8f0 --- /dev/null +++ b/multilib-testing/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-testing/gcc-multilib/gcc.install b/multilib-testing/gcc-multilib/gcc.install new file mode 100644 index 000000000..3407a5e1f --- /dev/null +++ b/multilib-testing/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-testing/gcc-multilib/gcc_pure64-multilib.patch b/multilib-testing/gcc-multilib/gcc_pure64-multilib.patch new file mode 100644 index 000000000..b5576ae0e --- /dev/null +++ b/multilib-testing/gcc-multilib/gcc_pure64-multilib.patch @@ -0,0 +1,22 @@ +diff -u -r gcc-4.7.0/gcc/config/i386/linux64.h gcc-4.7.0-pure64/gcc/config/i386/linux64.h +--- gcc-4.7.0/gcc/config/i386/linux64.h 2011-07-07 17:38:34.000000000 +0200 ++++ gcc-4.7.0-pure64/gcc/config/i386/linux64.h 2012-03-24 11:52:58.926204014 +0100 +@@ -29,5 +29,5 @@ + #define GNU_USER_LINK_EMULATIONX32 "elf32_x86_64" + + #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" + #define GLIBC_DYNAMIC_LINKERX32 "/libx32/ld-linux-x32.so.2" +diff -u -r gcc-4.7.0/gcc/config/i386/t-linux64 gcc-4.7.0-pure64/gcc/config/i386/t-linux64 +--- gcc-4.7.0/gcc/config/i386/t-linux64 2011-11-02 16:23:48.000000000 +0100 ++++ gcc-4.7.0-pure64/gcc/config/i386/t-linux64 2012-03-24 11:52:44.119651885 +0100 +@@ -34,6 +34,6 @@ + comma=, + MULTILIB_OPTIONS = $(subst $(comma),/,$(TM_MULTILIB_CONFIG)) + MULTILIB_DIRNAMES = $(patsubst m%, %, $(subst /, ,$(MULTILIB_OPTIONS))) +-MULTILIB_OSDIRNAMES = m64=../lib64 +-MULTILIB_OSDIRNAMES+= m32=$(if $(wildcard $(shell echo $(SYSTEM_HEADER_DIR))/../../usr/lib32),../lib32,../lib) ++MULTILIB_OSDIRNAMES = m64=../lib ++MULTILIB_OSDIRNAMES+= m32=../lib32 + MULTILIB_OSDIRNAMES+= mx32=../libx32 diff --git a/testing/gcc/PKGBUILD b/testing/gcc/PKGBUILD new file mode 100644 index 000000000..d77e3af1f --- /dev/null +++ b/testing/gcc/PKGBUILD @@ -0,0 +1,265 @@ +# $Id: PKGBUILD 158685 2012-05-07 06:38:30Z allan $ +# Maintainer: Allan McRae + +# toolchain build order: linux-api-headers->glibc->binutils->gcc->binutils->glibc +# NOTE: libtool requires rebuilt with each new gcc version + +pkgname=('gcc' 'gcc-libs' 'gcc-fortran' 'gcc-objc' 'gcc-ada' 'gcc-go') +pkgver=4.7.0 +pkgrel=6 +_snapshot=4.7-20120505 +_libstdcppmanver=20120307 # Note: check source directory name when updating this +pkgdesc="The GNU Compiler Collection" +arch=('i686' 'x86_64') +license=('GPL' 'LGPL' 'FDL' 'custom') +url="http://gcc.gnu.org" +makedepends=('binutils>=2.22' 'libmpc' 'cloog' 'ppl' 'gcc-ada') +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++-api.${_libstdcppmanver}.man.tar.bz2 + gcc_pure64.patch + gcc-4.7.0-cloog-0.17.patch) +md5sums=('8e2df3b9a755c9262db0df019cc3542e' + '489d2f5311535800a120efd8d18db719' + 'ced48436c1b3c981d721a829f1094de1' + '575f7d17b022e609447a590e481b18b5') + + +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 + + if [ "${CARCH}" = "x86_64" ]; then + patch -p1 -i ${srcdir}/gcc_pure64.patch + fi + + # compatibility with latest cloog + patch -p1 -i ${srcdir}/gcc-4.7.0-cloog-0.17.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 \ + --disable-libstdcxx-pch --enable-libstdcxx-time \ + --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 \ + --with-linker-hash-style=gnu \ + --disable-multilib --disable-libssp \ + --disable-build-with-cxx --disable-build-poststage1-with-cxx \ + --enable-checking=release + 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() +{ + pkgdesc="Runtime libraries shipped by GCC" + groups=('base') + depends=('glibc>=2.15') + install=gcc-libs.install + + cd gcc-build + make -j1 -C $CHOST/libgcc DESTDIR=${pkgdir} install-shared + for lib in libmudflap libgomp libstdc++-v3/src libitm; 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 -C $CHOST/libitm 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 -r ${pkgdir}/usr/lib/{gcc/,libgfortran.spec} + + # remove static libraries + find ${pkgdir} -name *.a -delete + + # Install Runtime Library Exception + install -Dm644 ${_basedir}/COPYING.RUNTIME \ + ${pkgdir}/usr/share/licenses/gcc-libs/RUNTIME.LIBRARY.EXCEPTION +} + +package_gcc() +{ + pkgdesc="The GNU Compiler Collection - C and C++ frontends" + depends=("gcc-libs=$pkgver-$pkgrel" 'binutils>=2.22' 'libmpc' 'cloog' 'ppl') + groups=('base-devel') + install=gcc.install + + cd gcc-build + + make -j1 DESTDIR=${pkgdir} install + + install -d $pkgdir/usr/share/gdb/auto-load/usr/lib + mv $pkgdir{,/usr/share/gdb/auto-load}/usr/lib/libstdc++.so.6.0.17-gdb.py + + # unfortunately it is much, much easier to install the lot and clean-up the mess... + rm $pkgdir/usr/bin/{{$CHOST-,}gfortran,{$CHOST-,}gccgo,gnat*} + rm $pkgdir/usr/lib/*.so* + rm $pkgdir/usr/lib/lib{ffi,gfortran,go{,begin},objc,quadmath}.a + rm $pkgdir/usr/lib/libgfortran.spec + rm -r $pkgdir/usr/lib/gcc/$CHOST/${pkgver}/{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} + rm $pkgdir/usr/lib/gcc/$CHOST/${pkgver}/{libcaf_single,libgfortranbegin}.a + rm -r $pkgdir/usr/lib/go + rm $pkgdir/usr/share/info/{gccgo,gfortran,gnat*,libgomp,libquadmath,libitm}.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 -s /usr/bin/cpp ${pkgdir}/lib/cpp + ln -s gcc ${pkgdir}/usr/bin/cc + + # 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}/man/man3/* ${pkgdir}/usr/share/man/man3/ + + # Install Runtime Library Exception + install -Dm644 ${_basedir}/COPYING.RUNTIME \ + ${pkgdir}/usr/share/licenses/gcc/RUNTIME.LIBRARY.EXCEPTION +} + +package_gcc-fortran() +{ + pkgdesc="Fortran front-end for GCC" + depends=("gcc=$pkgver-$pkgrel") + 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/lib{gfortran,quadmath}.so* + rm ${pkgdir}/usr/share/info/libquadmath.info + + ln -s gfortran ${pkgdir}/usr/bin/f95 + + # Install Runtime Library Exception + install -Dm644 ${_basedir}/COPYING.RUNTIME \ + ${pkgdir}/usr/share/licenses/gcc-fortran/RUNTIME.LIBRARY.EXCEPTION +} + +package_gcc-objc() +{ + pkgdesc="Objective-C front-end for GCC" + depends=("gcc=$pkgver-$pkgrel") + + 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/libobjc.so* + + # Install Runtime Library Exception + install -Dm644 ${_basedir}/COPYING.RUNTIME \ + ${pkgdir}/usr/share/licenses/gcc-objc/RUNTIME.LIBRARY.EXCEPTION +} + +package_gcc-ada() +{ + pkgdesc="Ada front-end for GCC (GNAT)" + depends=("gcc=$pkgver-$pkgrel") + 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 + + ln -s gcc ${pkgdir}/usr/bin/gnatgcc + + # Install Runtime Library Exception + install -Dm644 ${_basedir}/COPYING.RUNTIME \ + ${pkgdir}/usr/share/licenses/gcc-ada/RUNTIME.LIBRARY.EXCEPTION +} + +package_gcc-go() +{ + pkgdesc="Go front-end for GCC" + depends=("gcc=$pkgver-$pkgrel") + 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/testing/gcc/gcc-4.7.0-cloog-0.17.patch b/testing/gcc/gcc-4.7.0-cloog-0.17.patch new file mode 100644 index 000000000..c7146fa04 --- /dev/null +++ b/testing/gcc/gcc-4.7.0-cloog-0.17.patch @@ -0,0 +1,24 @@ +diff -Naur gcc-4.6-20120120-orig/configure gcc-4.6-20120120/configure +--- gcc-4.6-20120120-orig/configure 2011-12-18 20:03:44.000000000 +1000 ++++ gcc-4.6-20120120/configure 2012-02-03 17:55:14.885990135 +1000 +@@ -6049,8 +6049,8 @@ + LDFLAGS="${_cloog_saved_LDFLAGS} ${clooglibs} ${ppllibs}" + + if test "${cloog_org}" = yes ; then +- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for version 0.16.1 of CLooG" >&5 +-$as_echo_n "checking for version 0.16.1 of CLooG... " >&6; } ++ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for version 0.17 of CLooG" >&5 ++$as_echo_n "checking for version 0.17 of CLooG... " >&6; } + if test "${gcc_cv_cloog_ct_0_14_0+set}" = set; then : + $as_echo_n "(cached) " >&6 + else +@@ -6061,8 +6061,7 @@ + main () + { + #if CLOOG_VERSION_MAJOR != 0 \ +- || CLOOG_VERSION_MINOR != 16 \ +- || CLOOG_VERSION_REVISION < 1 ++ || CLOOG_VERSION_MINOR != 17 + choke me + #endif + ; diff --git a/testing/gcc/gcc-ada.install b/testing/gcc/gcc-ada.install new file mode 100644 index 000000000..df0553a4f --- /dev/null +++ b/testing/gcc/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/testing/gcc/gcc-fortran.install b/testing/gcc/gcc-fortran.install new file mode 100644 index 000000000..b15d89a97 --- /dev/null +++ b/testing/gcc/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/testing/gcc/gcc-go.install b/testing/gcc/gcc-go.install new file mode 100644 index 000000000..7dc50dee5 --- /dev/null +++ b/testing/gcc/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/testing/gcc/gcc-libs.install b/testing/gcc/gcc-libs.install new file mode 100644 index 000000000..23553b8f0 --- /dev/null +++ b/testing/gcc/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/testing/gcc/gcc.install b/testing/gcc/gcc.install new file mode 100644 index 000000000..3407a5e1f --- /dev/null +++ b/testing/gcc/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/testing/gcc/gcc_pure64.patch b/testing/gcc/gcc_pure64.patch new file mode 100644 index 000000000..a9b09bbcf --- /dev/null +++ b/testing/gcc/gcc_pure64.patch @@ -0,0 +1,26 @@ +diff -Naur gcc-orig/gcc/config/i386/linux64.h gcc/gcc/config/i386/linux64.h +--- gcc-orig/gcc/config/i386/linux64.h 2011-07-08 01:38:34.000000000 +1000 ++++ gcc/gcc/config/i386/linux64.h 2011-07-24 19:48:05.000000000 +1000 +@@ -28,6 +28,6 @@ + #define GNU_USER_LINK_EMULATION64 "elf_x86_64" + #define GNU_USER_LINK_EMULATIONX32 "elf32_x86_64" + +-#define GLIBC_DYNAMIC_LINKER32 "/lib/ld-linux.so.2" +-#define GLIBC_DYNAMIC_LINKER64 "/lib64/ld-linux-x86-64.so.2" ++#define GLIBC_DYNAMIC_LINKER32 "/lib32/ld-linux.so.2" ++#define GLIBC_DYNAMIC_LINKER64 "/lib/ld-linux-x86-64.so.2" + #define GLIBC_DYNAMIC_LINKERX32 "/libx32/ld-linux-x32.so.2" +diff -Naur gcc-orig/gcc/config/i386/t-linux64 gcc/gcc/config/i386/t-linux64 +--- gcc-orig/gcc/config/i386/t-linux64 2011-07-08 01:38:34.000000000 +1000 ++++ gcc/gcc/config/i386/t-linux64 2011-07-24 19:49:41.000000000 +1000 +@@ -34,8 +34,8 @@ + comma=, + MULTILIB_OPTIONS = $(subst $(comma),/,$(TM_MULTILIB_CONFIG)) + MULTILIB_DIRNAMES = $(patsubst m%, %, $(subst /, ,$(MULTILIB_OPTIONS))) +-MULTILIB_OSDIRNAMES = m64=../lib64 +-MULTILIB_OSDIRNAMES+= m32=$(if $(wildcard $(shell echo $(SYSTEM_HEADER_DIR))/../../usr/lib32),../lib32,../lib) ++MULTILIB_OSDIRNAMES = m64=../lib ++MULTILIB_OSDIRNAMES+= m32=../lib32 + MULTILIB_OSDIRNAMES+= mx32=../libx32 + + LIBGCC = stmp-multilib diff --git a/testing/gmp/PKGBUILD b/testing/gmp/PKGBUILD new file mode 100644 index 000000000..eb0da5a66 --- /dev/null +++ b/testing/gmp/PKGBUILD @@ -0,0 +1,37 @@ +# $Id: PKGBUILD 158687 2012-05-07 08:43:27Z allan $ +# Maintainer: Allan McRae +# Maintainer: Jan de Groot + +pkgname=gmp +pkgver=5.0.5 +pkgrel=1 +pkgdesc="A free library for arbitrary precision arithmetic" +arch=('i686' 'x86_64') +url="http://gmplib.org/" +depends=('gcc-libs' 'sh') +license=('LGPL3') +options=(!libtool) +install=gmp.install +source=(ftp://ftp.gnu.org/gnu/gmp/gmp-${pkgver}.tar.xz{,.sig}) +md5sums=('8aef50959acec2a1ad41d144ffe0f3b5' + '406e8878aadc51b134d1b3dd845261ee') + +build() { + cd "${srcdir}/${pkgname}-${pkgver}" + + [ "${CARCH}" = "i686" ] && export ABI="32" + ./configure --build=${CHOST} \ + --prefix=/usr --infodir=/usr/share/info \ + --enable-cxx + make +} + +check() { + cd "${srcdir}/${pkgname}-${pkgver}" + make check +} + +package() { + cd "${srcdir}/${pkgname}-${pkgver}" + make DESTDIR="${pkgdir}" install +} diff --git a/testing/gmp/gmp.install b/testing/gmp/gmp.install new file mode 100644 index 000000000..cad3354f9 --- /dev/null +++ b/testing/gmp/gmp.install @@ -0,0 +1,20 @@ +info_dir=usr/share/info +info_files=(gmp.info gmp.info-1 gmp.info-2) + +post_install() { + [ -x usr/bin/install-info ] || return 0 + for f in ${info_files[@]}; do + install-info ${info_dir}/$f.gz ${info_dir}/dir 2> /dev/null + done +} + +post_upgrade() { + post_install $1 +} + +pre_remove() { + [ -x usr/bin/install-info ] || return 0 + for f in ${info_files[@]}; do + install-info --delete ${info_dir}/$f.gz ${info_dir}/dir 2> /dev/null + done +} diff --git a/testing/libusb-compat/PKGBUILD b/testing/libusb-compat/PKGBUILD new file mode 100644 index 000000000..cd0722960 --- /dev/null +++ b/testing/libusb-compat/PKGBUILD @@ -0,0 +1,27 @@ +# $Id: PKGBUILD 158681 2012-05-07 05:49:00Z eric $ +# Maintainer: +# Contributor: Tobias Powalowski +# Contributor: arjan + +pkgname=libusb-compat +pkgver=0.1.4 +pkgrel=1 +pkgdesc="Library to enable user space application programs to communicate with USB devices" +arch=('i686' 'x86_64') +url="http://libusb.sourceforge.net/" +license=('LGPL') +depends=('libusb' 'sh') +options=('!libtool') +source=("http://downloads.sourceforge.net/${pkgname%-*}/${pkgname}-${pkgver%.*}/$pkgname-$pkgver/${pkgname}-${pkgver}.tar.bz2") +md5sums=('2ca521fffadd0c28fdf174e6ec73865b') + +build() { + cd "${srcdir}/${pkgname}-${pkgver}" + ./configure --prefix=/usr + make +} + +package() { + cd "${srcdir}/${pkgname}-${pkgver}" + make DESTDIR="${pkgdir}" install +} -- cgit v1.2.3-54-g00ecf From 1adfdd111d570a6dfc66543a2858d9554c73e7a7 Mon Sep 17 00:00:00 2001 From: root Date: Thu, 10 May 2012 00:01:51 +0000 Subject: Thu May 10 00:01:50 UTC 2012 --- community/lazarus/ChangeLog | 4 + community/lazarus/PKGBUILD | 7 +- community/mosh/PKGBUILD | 33 + community/roxterm/PKGBUILD | 8 +- community/sslh/PKGBUILD | 22 +- community/sslh/sslh.conf | 2 +- community/sslh/sslh.rc | 33 +- core/gcc/PKGBUILD | 12 +- core/gmp/PKGBUILD | 8 +- core/isl/PKGBUILD | 11 +- extra/cifs-utils/PKGBUILD | 14 +- ...s-fix-up-some-D_FORTIFY_SOURCE-2-warnings.patch | 72 + extra/kdeplasma-applets-networkmanagement/PKGBUILD | 4 +- extra/libvncserver/PKGBUILD | 8 +- extra/mpg123/PKGBUILD | 8 +- extra/mysql/PKGBUILD | 6 +- extra/ntfs-3g_ntfsprogs/PKGBUILD | 17 +- extra/php/PKGBUILD | 6 +- extra/qemu-kvm/PKGBUILD | 23 +- extra/qemu/PKGBUILD | 20 +- extra/slim/PKGBUILD | 63 +- extra/slim/pam.d | 1 - extra/slim/slim.service | 10 + testing/mpfr/PKGBUILD | 38 + testing/mpfr/mpfr-3.1.0.p10.patch | 1896 ++++++++++++++++++++ testing/mpfr/mpfr.install | 20 + testing/php/PKGBUILD | 6 +- 27 files changed, 2205 insertions(+), 147 deletions(-) create mode 100644 community/mosh/PKGBUILD create mode 100644 extra/cifs-utils/mount.cifs-fix-up-some-D_FORTIFY_SOURCE-2-warnings.patch create mode 100644 extra/slim/slim.service create mode 100644 testing/mpfr/PKGBUILD create mode 100644 testing/mpfr/mpfr-3.1.0.p10.patch create mode 100644 testing/mpfr/mpfr.install diff --git a/community/lazarus/ChangeLog b/community/lazarus/ChangeLog index 0a843b0ec..d435cb744 100644 --- a/community/lazarus/ChangeLog +++ b/community/lazarus/ChangeLog @@ -1,3 +1,7 @@ +2012-05-08 BlackIkeEagle + * fix FS#29807 + * should not have removed Makefiles + 2012-04-30 BlackIkeEagle * split pkgbuild * lazarus (can be used for compiling) diff --git a/community/lazarus/PKGBUILD b/community/lazarus/PKGBUILD index 6b3e8d720..0c471d0ed 100644 --- a/community/lazarus/PKGBUILD +++ b/community/lazarus/PKGBUILD @@ -1,4 +1,4 @@ -# $Id: PKGBUILD 70224 2012-05-02 13:40:21Z idevolder $ +# $Id: PKGBUILD 70466 2012-05-08 18:21:20Z idevolder $ # Maintainer: Sergej Pupykin # Contributor: Jens Adam (byte/jra) # Contributor: BlackIkeEagle @@ -6,7 +6,7 @@ pkgbase=lazarus pkgname=('lazarus' 'lazarus-gtk2' 'lazarus-qt') pkgver=0.9.30.4 -pkgrel=2 +pkgrel=3 url='http://www.lazarus.freepascal.org/' license=('GPL2' 'MPL' 'custom:LGPL') arch=('i686' 'x86_64') @@ -54,8 +54,7 @@ package_lazarus() { --exclude=".xvpics" --exclude="*.compiled" \ --exclude="killme*" --exclude=".gdb_hist*" \ --exclude="debian" --exclude="COPYING*" \ - --exclude="*.app" --exclude="Makefile*" \ - --exclude="tools/install" \ + --exclude="*.app" --exclude="tools/install" \ . "$pkgdir"/usr/lib/lazarus #remove some stuff, not needed or for in other package diff --git a/community/mosh/PKGBUILD b/community/mosh/PKGBUILD new file mode 100644 index 000000000..49a766641 --- /dev/null +++ b/community/mosh/PKGBUILD @@ -0,0 +1,33 @@ +# $Id: PKGBUILD 68685 2012-03-31 16:54:07Z arodseth $ +# Maintainer: Alexander Rødseth +# Contributor: Christian Neukirchen +# Contributor: Thomas Weißschuh + +pkgname=mosh +pkgver=1.2 +pkgrel=1 +pkgdesc='Mobile shell, surviving disconnects with local echo and line editing' +arch=('x86_64' 'i686') +url="http://mosh.mit.edu/" +license=('GPL3') +depends=('protobuf' 'ncurses' 'zlib' 'openssh' 'perl' 'perl-io-tty') +#optdepends=('libutempter: record of session in {u,t}wmp (recompile mosh afterwards)') +conflicts=('mosh-git') +source=("$pkgname-$pkgver.tgz::https://nodeload.github.com/keithw/mosh/tarball/master") +sha1sums=('690e301560808f13a8a7b19bd7740d81fecac262') + +build() { + cd "$srcdir/keithw-mosh-"* + + ./autogen.sh + ./configure --prefix=/usr + make +} + +package() { + cd "$srcdir/keithw-mosh-"* + + make DESTDIR="$pkgdir/" install +} + +# vim:set ts=2 sw=2 et: diff --git a/community/roxterm/PKGBUILD b/community/roxterm/PKGBUILD index b7d2648f2..4e8ddf8f0 100644 --- a/community/roxterm/PKGBUILD +++ b/community/roxterm/PKGBUILD @@ -1,9 +1,9 @@ -# $Id: PKGBUILD 69819 2012-04-23 17:44:21Z ttopper $ +# $Id: PKGBUILD 70468 2012-05-08 20:11:39Z ttopper $ # Maintainer: Thorsten Töpper # Contributor: Alexander Fehr pkgname=roxterm -pkgver=2.6.2 +pkgver=2.6.3 pkgrel=1 pkgdesc="Tabbed, VTE-based terminal emulator" arch=('i686' 'x86_64') @@ -13,8 +13,8 @@ depends=('dbus-glib' 'vte3' 'hicolor-icon-theme' 'libsm') makedepends=('docbook-xsl' 'xmlto' 'po4a' 'python2' 'python2-lockfile' 'imagemagick' 'librsvg') install=roxterm.install source=("http://downloads.sourceforge.net/roxterm/roxterm-$pkgver.tar.bz2") -sha1sums=('eca312666a1ff1412df2cddf93a12631c01d1a3a') -md5sums=('5e5dc51b3341855fdb392f736476d89d') +sha1sums=('f6f64cf35163338e539bdbc952d470b4a9217f9a') +md5sums=('3089fc54b3c9bb8f8e087280bf96b037') build() { diff --git a/community/sslh/PKGBUILD b/community/sslh/PKGBUILD index adac2e46a..7b4254d11 100644 --- a/community/sslh/PKGBUILD +++ b/community/sslh/PKGBUILD @@ -1,30 +1,35 @@ -# $Id: PKGBUILD 69659 2012-04-22 00:48:23Z seblu $ +# $Id: PKGBUILD 70458 2012-05-08 13:27:24Z seblu $ # Maintainer: Sébastien Luttringer # Contributor: Le_suisse # Contributor: Jason Rodriguez pkgname=sslh -pkgver=1.11 +pkgver=1.12 pkgrel=1 pkgdesc='SSL/SSH/OpenVPN/XMPP/tinc port multiplexer' arch=('i686' 'x86_64') url='http://www.rutschle.net/tech/sslh.shtml' license=('GPL2') -backup=('etc/conf.d/sslh') +depends=('libconfig') +backup=('etc/conf.d/sslh' 'etc/sslh.conf') source=("http://www.rutschle.net/tech/$pkgname-$pkgver.tar.gz" 'sslh.rc' 'sslh.conf' 'sslh.service') -md5sums=('4ea599f0fa31ae235646e5a200b8f8fb' - 'f64da291e97f1a99c33cb6ebf939b95b' - 'a098fb6b03a3435b223e16aed0e65e0b' +md5sums=('265014ecdae4512eacca91aaff0b9a81' + 'e1c44f8160b7fef397f81db63eec8421' + 'c51c63d2b28080bae4c1c7a0c469bab7' 'ee8a4fcfc1f6839f7c93deb6f59f7fd6') build() { cd $pkgname-$pkgver # fix archlinux path in manpage - sed -i -e "s/init.d/rc.d/" sslh.pod - sed -i -e "s+/etc/default+/etc/conf.d+" sslh.pod + sed -i 's/init.d/rc.d/' sslh.pod + sed -i 's+/etc/default+/etc/conf.d+' sslh.pod + # remove default pidfile in example + sed -i '/pidfile:/d' example.cfg + # daemon mode by default (as not overridable in command line) + sed -i 's/foreground: true;/foreground: false;/' example.cfg make } @@ -40,6 +45,7 @@ package() { install -Dm 0755 sslh-select "$pkgdir/usr/bin/sslh-select" ln -s sslh-fork "$pkgdir/usr/bin/sslh" install -Dm 0644 sslh.8.gz "$pkgdir/usr/share/man/man8/sslh.8.gz" + install -Dm 0644 example.cfg "$pkgdir/etc/sslh.conf" } # vim:set ts=2 sw=2 ft=sh et: diff --git a/community/sslh/sslh.conf b/community/sslh/sslh.conf index b22a325ef..d3a46d053 100644 --- a/community/sslh/sslh.conf +++ b/community/sslh/sslh.conf @@ -1,3 +1,3 @@ # vim:set ts=2 sw=2 ft=sh noet: -DAEMON_OPTS='-p 192.168.0.1:443 --ssh 127.0.0.1:22 --ssl 127.0.0.1:443 -u nobody' +DAEMON_OPTS='-F /etc/sslh.conf' diff --git a/community/sslh/sslh.rc b/community/sslh/sslh.rc index 9c31435a0..cd5397cad 100644 --- a/community/sslh/sslh.rc +++ b/community/sslh/sslh.rc @@ -4,31 +4,30 @@ . /etc/rc.d/functions . /etc/conf.d/${0##*/} -NAME=sslh DAEMON=/usr/bin/sslh PID=$(pidof -o %PPID $DAEMON) case "$1" in - start) - stat_busy "Starting $NAME daemon" - [[ ! $PID ]] && $DAEMON $DAEMON_OPTS && add_daemon $NAME && stat_done && exit 0 - stat_fail - ;; + start) + stat_busy "Starting ${0##*/} daemon" + [[ ! $PID ]] && $DAEMON $DAEMON_OPTS && add_daemon ${0##*/} && stat_done && exit 0 + stat_fail + ;; stop) - stat_busy "Stopping $NAME daemon" - [[ $PID ]] && kill $PID &> /dev/null && rm_daemon $NAME && stat_done && exit 0 - stat_fail - ;; + stat_busy "Stopping ${0##*/} daemon" + [[ $PID ]] && kill $PID &> /dev/null && rm_daemon ${0##*/} && stat_done && exit 0 + stat_fail + ;; restart) - $0 stop - $0 start - exit 0 - ;; + $0 stop + $0 start + exit 0 + ;; *) - echo "usage: ${0##*/} {start|stop|restart}" >&2 - ;; + echo "usage: ${0##*/} {start|stop|restart}" >&2 + ;; esac exit 1 -# vim:set ts=2 sw=2 ft=sh noet: +# vim:set ts=2 sw=2 ft=sh et: diff --git a/core/gcc/PKGBUILD b/core/gcc/PKGBUILD index eb8f9fc8a..cddfb1edc 100644 --- a/core/gcc/PKGBUILD +++ b/core/gcc/PKGBUILD @@ -1,4 +1,4 @@ -# $Id: PKGBUILD 156586 2012-04-21 10:26:57Z allan $ +# $Id: PKGBUILD 158746 2012-05-09 01:14:02Z allan $ # Maintainer: Allan McRae # toolchain build order: linux-api-headers->glibc->binutils->gcc->binutils->glibc @@ -6,8 +6,8 @@ pkgname=('gcc' 'gcc-libs' 'gcc-fortran' 'gcc-objc' 'gcc-ada' 'gcc-go') pkgver=4.7.0 -pkgrel=5 -_snapshot=4.7-20120414 +pkgrel=6 +_snapshot=4.7-20120505 _libstdcppmanver=20120307 # Note: check source directory name when updating this pkgdesc="The GNU Compiler Collection" arch=('i686' 'x86_64') @@ -21,7 +21,7 @@ source=(#ftp://gcc.gnu.org/pub/gcc/releases/gcc-${pkgver}/gcc-${pkgver}.tar.bz2 ftp://gcc.gnu.org/pub/gcc/libstdc++/doxygen/libstdc++-api.${_libstdcppmanver}.man.tar.bz2 gcc_pure64.patch gcc-4.7.0-cloog-0.17.patch) -md5sums=('9f9d082b64753d5908690500251fc52e' +md5sums=('8e2df3b9a755c9262db0df019cc3542e' '489d2f5311535800a120efd8d18db719' 'ced48436c1b3c981d721a829f1094de1' '575f7d17b022e609447a590e481b18b5') @@ -128,8 +128,8 @@ package_gcc() make -j1 DESTDIR=${pkgdir} install - install -d $pkgdir/usr/share/gdb/auto-load - mv $pkgdir/usr/{lib/libstdc++.so.6.0.17-gdb.py,share/gdb/auto-load} + install -d $pkgdir/usr/share/gdb/auto-load/usr/lib + mv $pkgdir{,/usr/share/gdb/auto-load}/usr/lib/libstdc++.so.6.0.17-gdb.py # unfortunately it is much, much easier to install the lot and clean-up the mess... rm $pkgdir/usr/bin/{{$CHOST-,}gfortran,{$CHOST-,}gccgo,gnat*} diff --git a/core/gmp/PKGBUILD b/core/gmp/PKGBUILD index 15158aa16..d0490e5be 100644 --- a/core/gmp/PKGBUILD +++ b/core/gmp/PKGBUILD @@ -1,9 +1,9 @@ -# $Id: PKGBUILD 156203 2012-04-16 03:46:32Z allan $ +# $Id: PKGBUILD 158748 2012-05-09 01:14:08Z allan $ # Maintainer: Allan McRae # Maintainer: Jan de Groot pkgname=gmp -pkgver=5.0.4 +pkgver=5.0.5 pkgrel=1 pkgdesc="A free library for arbitrary precision arithmetic" arch=('i686' 'x86_64') @@ -13,8 +13,8 @@ license=('LGPL3') options=(!libtool) install=gmp.install source=(ftp://ftp.gnu.org/gnu/gmp/gmp-${pkgver}.tar.xz{,.sig}) -md5sums=('0881f4ff2617226c673fc534ac39d448' - 'f9e448fff9eaeccdde6ee1f1df00c988') +md5sums=('8aef50959acec2a1ad41d144ffe0f3b5' + '406e8878aadc51b134d1b3dd845261ee') build() { cd "${srcdir}/${pkgname}-${pkgver}" diff --git a/core/isl/PKGBUILD b/core/isl/PKGBUILD index c4608bb5d..00a47106f 100644 --- a/core/isl/PKGBUILD +++ b/core/isl/PKGBUILD @@ -1,9 +1,9 @@ -# $Id: PKGBUILD 148648 2012-02-05 03:55:32Z allan $ +# $Id: PKGBUILD 158750 2012-05-09 01:14:11Z allan $ # Maintainer: Allan McRae pkgname=isl pkgver=0.09 -pkgrel=1 +pkgrel=2 pkgdesc="Library for manipulating sets and relations of integer points bounded by linear constraints" arch=('i686' 'x86_64') url="http://www.kotnet.org/~skimo/isl/" @@ -26,8 +26,7 @@ check() { package() { cd "$srcdir/$pkgname-$pkgver" make -j1 DESTDIR="$pkgdir/" install - - # this seems a better place for this file... - install -dm755 $pkgdir/usr/share/gdb/auto-load/ - mv $pkgdir/usr/{lib,share/gdb/auto-load}/libisl.so.9.0.0-gdb.py + + install -dm755 $pkgdir/usr/share/gdb/auto-load/usr/lib/ + mv $pkgdir/{,/usr/share/gdb/auto-load/}usr/lib/libisl.so.9.0.0-gdb.py } diff --git a/extra/cifs-utils/PKGBUILD b/extra/cifs-utils/PKGBUILD index b5043885f..da5512fa1 100644 --- a/extra/cifs-utils/PKGBUILD +++ b/extra/cifs-utils/PKGBUILD @@ -1,17 +1,20 @@ -# $Id: PKGBUILD 151756 2012-03-02 08:44:51Z tpowa $ +# $Id: PKGBUILD 158736 2012-05-08 14:32:25Z tpowa $ # Maintainer: Tobias Powalowski pkgname=cifs-utils -pkgver=5.3 -pkgrel=2 +pkgver=5.4 +pkgrel=1 pkgdesc="CIFS filesystem user-space tools" arch=(i686 x86_64) url="http://wiki.samba.org/index.php/LinuxCIFS_utils" license=('GPL') depends=('libcap-ng' 'keyutils' 'krb5' 'talloc' 'libwbclient') -source=(ftp://ftp.samba.org/pub/linux-cifs/cifs-utils/$pkgname-$pkgver.tar.bz2) +source=(ftp://ftp.samba.org/pub/linux-cifs/cifs-utils/$pkgname-$pkgver.tar.bz2 + mount.cifs-fix-up-some-D_FORTIFY_SOURCE-2-warnings.patch) build() { cd "$srcdir/$pkgname-$pkgver" + # add fedora build patch + patch -Np1 -i ../mount.cifs-fix-up-some-D_FORTIFY_SOURCE-2-warnings.patch ./configure --prefix=/usr make } @@ -22,4 +25,5 @@ package() { # set mount.cifs uid, to enable none root mounting form fstab chmod +s $pkgdir/sbin/mount.cifs } -md5sums=('e1a428558a96d2d28ccdaacdc47ea0b7') +md5sums=('dde98336c833b59777114145cb8f3c64' + 'b1b0a5a21aedd5421ff6e1e1a8720771') diff --git a/extra/cifs-utils/mount.cifs-fix-up-some-D_FORTIFY_SOURCE-2-warnings.patch b/extra/cifs-utils/mount.cifs-fix-up-some-D_FORTIFY_SOURCE-2-warnings.patch new file mode 100644 index 000000000..8ca3b2674 --- /dev/null +++ b/extra/cifs-utils/mount.cifs-fix-up-some-D_FORTIFY_SOURCE-2-warnings.patch @@ -0,0 +1,72 @@ +From 900875dbda261dd8a9283bdda3c3dbe551fe0f7c Mon Sep 17 00:00:00 2001 +From: Jeff Layton +Date: Wed, 18 Apr 2012 21:41:05 -0400 +Subject: [PATCH] mount.cifs: fix up some -D_FORTIFY_SOURCE=2 warnings + +...and add -D_FORTIFY_SOURCE=2 to the default $CFLAGS. + +Signed-off-by: Jeff Layton +--- + Makefile.am | 2 +- + mount.cifs.c | 10 ++++++---- + mtab.c | 4 +++- + 3 files changed, 10 insertions(+), 6 deletions(-) + +diff --git a/Makefile.am b/Makefile.am +index d95142a..05729ca 100644 +--- a/Makefile.am ++++ b/Makefile.am +@@ -1,4 +1,4 @@ +-AM_CFLAGS = -Wall -Wextra -Werror ++AM_CFLAGS = -Wall -Wextra -Werror -D_FORTIFY_SOURCE=2 + ACLOCAL_AMFLAGS = -I aclocal + + root_sbindir = $(ROOTSBINDIR) +diff --git a/mount.cifs.c b/mount.cifs.c +index f0b073e..4f1ea40 100644 +--- a/mount.cifs.c ++++ b/mount.cifs.c +@@ -928,9 +928,9 @@ parse_options(const char *data, struct parsed_mount_info *parsed_info) + } + } else { + /* domain/username%password */ +- const int max = MAX_DOMAIN_SIZE + +- MAX_USERNAME_SIZE + +- MOUNT_PASSWD_SIZE + 2; ++ const unsigned int max = MAX_DOMAIN_SIZE + ++ MAX_USERNAME_SIZE + ++ MOUNT_PASSWD_SIZE + 2; + if (strnlen(value, max + 1) >= max + 1) { + fprintf(stderr, "username too long\n"); + return EX_USAGE; +@@ -1603,8 +1603,10 @@ add_mtab(char *devname, char *mountpoint, unsigned long flags, const char *fstyp + mountent.mnt_passno = 0; + rc = addmntent(pmntfile, &mountent); + if (rc) { ++ int ignore __attribute__((unused)); ++ + fprintf(stderr, "unable to add mount entry to mtab\n"); +- ftruncate(fd, statbuf.st_size); ++ ignore = ftruncate(fd, statbuf.st_size); + rc = EX_FILEIO; + } + tmprc = my_endmntent(pmntfile, statbuf.st_size); +diff --git a/mtab.c b/mtab.c +index de545b7..3d42ac0 100644 +--- a/mtab.c ++++ b/mtab.c +@@ -271,8 +271,10 @@ my_endmntent(FILE *stream, off_t size) + + /* truncate file back to "size" -- best effort here */ + if (rc) { ++ int ignore __attribute__((unused)); ++ + rc = errno; +- ftruncate(fd, size); ++ ignore = ftruncate(fd, size); + } + + endmntent(stream); +-- +1.7.7.6 + diff --git a/extra/kdeplasma-applets-networkmanagement/PKGBUILD b/extra/kdeplasma-applets-networkmanagement/PKGBUILD index 2adb5bcc2..a773be13c 100644 --- a/extra/kdeplasma-applets-networkmanagement/PKGBUILD +++ b/extra/kdeplasma-applets-networkmanagement/PKGBUILD @@ -4,7 +4,7 @@ pkgname=kdeplasma-applets-networkmanagement epoch=1 -pkgver=0.9.0.1 +pkgver=0.9.0.2 pkgrel=1 pkgdesc="KDE control panel and widget network connections" arch=('i686' 'x86_64') @@ -17,7 +17,7 @@ optdepends=('mobile-broadband-provider-info: Database of mobile broadband servic 'openconnect: Cisco AnyConnect compatible VPN client') install=${pkgname}.install source=("http://download.kde.org/unstable/networkmanagement/${pkgver}/src/networkmanagement-${pkgver}.tar.bz2") -sha1sums=('75e16397d00de06947fa183f09632caed11d8857') +sha1sums=('58b530d0dc97cc742f24413a54c58f20318cfa14') build() { cd "${srcdir}" diff --git a/extra/libvncserver/PKGBUILD b/extra/libvncserver/PKGBUILD index c473d2bca..27a759d6f 100644 --- a/extra/libvncserver/PKGBUILD +++ b/extra/libvncserver/PKGBUILD @@ -1,19 +1,19 @@ -# $Id: PKGBUILD 145736 2011-12-29 15:45:13Z andrea $ +# $Id: PKGBUILD 158727 2012-05-08 13:54:05Z andrea $ # Maintainer: # Contributor: Andrea Scarpino # Contributor: Tobias Powalowski pkgname=libvncserver -pkgver=0.9.8.2 +pkgver=0.9.9 pkgrel=1 pkgdesc="A cross-platform C libraries that allow you to easily implement VNC server" arch=('i686' 'x86_64') url="http://libvncserver.sourceforge.net/" license=('GPL') -depends=('libjpeg' 'gnutls' 'libgcrypt') +depends=('libjpeg' 'gnutls' 'libgcrypt' 'openssl') options=('!libtool') source=("http://downloads.sourceforge.net/${pkgname}/LibVNCServer-${pkgver}.tar.gz") -md5sums=('dfed1dcc25cb338c7fdbcda2c3df7f50') +md5sums=('70422169b122765693d2a294d13e3714') build() { cd "${srcdir}/LibVNCServer-${pkgver}" diff --git a/extra/mpg123/PKGBUILD b/extra/mpg123/PKGBUILD index c0ca82929..354982b8b 100644 --- a/extra/mpg123/PKGBUILD +++ b/extra/mpg123/PKGBUILD @@ -1,8 +1,8 @@ -# $Id: PKGBUILD 158020 2012-05-01 05:58:27Z eric $ +# $Id: PKGBUILD 158702 2012-05-08 04:10:15Z eric $ # Maintainer: Eric Bélanger pkgname=mpg123 -pkgver=1.14.0 +pkgver=1.14.1 pkgrel=1 pkgdesc="A console based real time MPEG Audio Player for Layer 1, 2 and 3" arch=('i686' 'x86_64') @@ -17,8 +17,8 @@ conflicts=('mpg321') provides=('mpg321') options=('!libtool') source=(http://downloads.sourceforge.net/sourceforge/${pkgname}/${pkgname}-${pkgver}.tar.bz2{,.sig}) -sha1sums=('49a3d6791cc948336aa34914582f97ac6bb2a8ff' - '85386be9450abd66d8738f5cf1adc82aa8f5fb53') +sha1sums=('db1004f3318ce239e2972ae623563fe6e831e331' + '9e88254e099ff08ff8eb5bb7e8697ec5b5a2b825') build() { cd "${srcdir}/${pkgname}-${pkgver}" diff --git a/extra/mysql/PKGBUILD b/extra/mysql/PKGBUILD index 1913200bc..5958f8989 100644 --- a/extra/mysql/PKGBUILD +++ b/extra/mysql/PKGBUILD @@ -1,11 +1,11 @@ -# $Id: PKGBUILD 156076 2012-04-13 07:51:21Z andrea $ +# $Id: PKGBUILD 158713 2012-05-08 07:40:05Z andrea $ # Maintainer: # Contributor: Andrea Scarpino # Contributor: Douglas Soares de Andrade pkgbase=mysql pkgname=('libmysqlclient' 'mysql-clients' 'mysql') -pkgver=5.5.23 +pkgver=5.5.24 pkgrel=1 arch=('i686' 'x86_64') license=('GPL') @@ -15,7 +15,7 @@ options=('!libtool') source=("http://ftp.gwdg.de/pub/misc/mysql/Downloads/MySQL-5.5/${pkgbase}-${pkgver}.tar.gz" 'mysqld' 'my.cnf') -md5sums=('b614481967dc146c148027b598397b54' +md5sums=('dc84f8a0305e054c859533944e79f803' '2234207625baa29b2ff7d7b4f088abce' '1c949c0dbea5206af0db14942d9927b6') diff --git a/extra/ntfs-3g_ntfsprogs/PKGBUILD b/extra/ntfs-3g_ntfsprogs/PKGBUILD index 07a3fbf7d..18608fb56 100644 --- a/extra/ntfs-3g_ntfsprogs/PKGBUILD +++ b/extra/ntfs-3g_ntfsprogs/PKGBUILD @@ -1,4 +1,4 @@ -# $Id: PKGBUILD 156015 2012-04-11 14:16:02Z tomegun $ +# $Id: PKGBUILD 158725 2012-05-08 12:53:46Z tomegun $ # Maintainer: Tom Gundersen # Contributor: Ronald van Haren # Contributor: Thomas Bächler @@ -6,7 +6,7 @@ pkgbase=ntfs-3g_ntfsprogs pkgname=('ntfs-3g' 'ntfsprogs') pkgver=2012.1.15 -pkgrel=2 +pkgrel=3 url="http://www.tuxera.com" arch=('i686' 'x86_64') license=('GPL2') @@ -20,7 +20,7 @@ build() { cd "$srcdir/$pkgbase-$pkgver" ac_cv_path_LDCONFIG=/bin/true ./configure --prefix=/usr \ --with-fuse=external --disable-static \ - --mandir=/usr/share/man + --enable-posix-acls --mandir=/usr/share/man make } @@ -33,9 +33,13 @@ package_ntfs-3g() { done mv "$pkgdir"/lib/* "$pkgdir"/usr/lib/ - rm -rf "$pkgdir"/lib + mv "$pkgdir"/bin/* "$pkgdir"/usr/bin/ + rm -rf "$pkgdir"/{lib,{s,}bin} - ln -s /bin/ntfs-3g "$pkgdir/sbin/mount.ntfs" + cd "$pkgdir"/usr/bin + ln -s ntfs-3g mount.ntfs + ln -s ntfs-3g mount.ntfs-3g + ln -s lowntfs-3g mount.lowntfs-3g } package_ntfsprogs() { @@ -44,4 +48,7 @@ package_ntfsprogs() { cd "$srcdir/$pkgbase-$pkgver/ntfsprogs" make DESTDIR="$pkgdir" install + + mv "$pkgdir"/sbin/* "$pkgdir"/usr/bin/ + rm -rf "$pkgdir"/sbin } diff --git a/extra/php/PKGBUILD b/extra/php/PKGBUILD index 9eac85839..8fa916144 100644 --- a/extra/php/PKGBUILD +++ b/extra/php/PKGBUILD @@ -1,4 +1,4 @@ -# $Id: PKGBUILD 158338 2012-05-03 18:28:53Z pierre $ +# $Id: PKGBUILD 158740 2012-05-08 17:02:36Z pierre $ # Maintainer: Pierre Schmitz pkgbase=php @@ -21,7 +21,7 @@ pkgname=('php' 'php-sqlite' 'php-tidy' 'php-xsl') -pkgver=5.3.12 +pkgver=5.3.13 _suhosinver=5.3.9-0.9.10 pkgrel=1 arch=('i686' 'x86_64') @@ -36,7 +36,7 @@ source=("http://www.php.net/distributions/${pkgbase}-${pkgver}.tar.bz2" "http://download.suhosin.org/suhosin-patch-${_suhosinver}.patch.gz.sig" 'php.ini.patch' 'apache.conf' 'rc.d.php-fpm' 'php-fpm.conf.in.patch' 'logrotate.d.php-fpm' 'suhosin.patch') -md5sums=('cf02c29be279c506cbd4ffc2819d7c82' +md5sums=('370be99c5cdc2e756c82c44d774933c8' 'c099b3d7eac95018ababd41ded7f3066' 'c15d18f846be1d69144a5d0056ee6506' 'ffc338e8ce2a990f6f2a486355bbab65' diff --git a/extra/qemu-kvm/PKGBUILD b/extra/qemu-kvm/PKGBUILD index 43c91f938..4a38dd2c5 100644 --- a/extra/qemu-kvm/PKGBUILD +++ b/extra/qemu-kvm/PKGBUILD @@ -1,14 +1,14 @@ -# $Id: PKGBUILD 158632 2012-05-05 03:24:58Z allan $ +# $Id: PKGBUILD 158721 2012-05-08 10:22:47Z tpowa $ # Maintainer: Tobias Powalowski pkgname=qemu-kvm pkgver=1.0.1 -pkgrel=2 +pkgrel=3 pkgdesc="Latest KVM QEMU is a generic and open source processor emulator which achieves a good emulation speed by using dynamic translation." arch=(i686 x86_64) license=('GPL2' 'LGPL2.1') url="http://www.linux-kvm.org" -depends=('libjpeg' 'libpng' 'libsasl' 'curl' 'sdl' 'alsa-lib' 'nss' 'glib2' 'gnutls>=2.4.1' 'bluez' 'vde2' 'util-linux' 'libpulse') -makedepends=('git' 'iasl' 'texi2html' 'perl' 'python2') +depends=('libjpeg' 'libpng' 'libsasl' 'curl' 'sdl' 'alsa-lib' 'nss' 'glib2' 'gnutls>=2.4.1' 'bluez' 'vde2' 'util-linux' 'libpulse' 'seabios') +makedepends=('texi2html' 'perl' 'python2') backup=('etc/qemu/target-x86_64.conf') install=qemu-kvm.install conflicts=('qemu') @@ -29,26 +29,13 @@ build() --audio-card-list=ac97,sb16,es1370,hda \ --enable-docs make - - # Use latest seabios version - # https://bugs.archlinux.org/task/27616 - cd "${srcdir}/" - git clone git://git.seabios.org/seabios.git - cd seabios - #find 'tools/' 'contrib' -type f | xargs sed -i 's@^#!.*python$@#!/usr/bin/python2@' - sed -i -e 's/python/python2/g' Makefile - make clean - make } package() { cd "${srcdir}/${pkgname}-${pkgver}" make DESTDIR="${pkgdir}" install - - # Use latest seabios version - # https://bugs.archlinux.org/task/27616 - cp "${srcdir}/seabios/out/bios.bin" "${pkgdir}/usr/share/qemu/bios.bin" + rm "${pkgdir}/usr/share/qemu/bios.bin" # symbolic link for backwards compatibility ln -s qemu-system-x86_64 "${pkgdir}/usr/bin/qemu-kvm" diff --git a/extra/qemu/PKGBUILD b/extra/qemu/PKGBUILD index c96870137..5001efed8 100644 --- a/extra/qemu/PKGBUILD +++ b/extra/qemu/PKGBUILD @@ -1,14 +1,14 @@ -# $Id: PKGBUILD 158630 2012-05-05 03:24:55Z allan $ +# $Id: PKGBUILD 158723 2012-05-08 10:41:26Z tpowa $ # Maintainer: Tobias Powalowski pkgname=qemu pkgver=1.0.1 -pkgrel=2 +pkgrel=3 pkgdesc="A generic and open source processor emulator which achieves a good emulation speed by using dynamic translation." arch=('i686' 'x86_64') license=('GPL2' 'LGPL2.1') url="http://wiki.qemu.org/Index.html" -makedepends=('iasl' 'git' 'texi2html' 'perl' 'python2') -depends=('libjpeg' 'libpng' 'sdl' 'alsa-lib' 'nss' 'glib2' 'gnutls>=2.4.1' 'bluez' 'vde2' 'util-linux' 'curl' 'libsasl' 'libgl' 'libpulse') +makedepends=('texi2html' 'perl' 'python2') +depends=('libjpeg' 'libpng' 'sdl' 'alsa-lib' 'nss' 'glib2' 'gnutls>=2.4.1' 'bluez' 'vde2' 'util-linux' 'curl' 'libsasl' 'libgl' 'libpulse' 'seabios') backup=('etc/qemu/target-x86_64.conf') install=qemu.install source=(http://wiki.qemu.org/download/${pkgname}-${pkgver}.tar.gz @@ -24,22 +24,12 @@ build() --audio-card-list=ac97,sb16,es1370,hda \ --enable-docs make - # Use latest seabios version - # https://bugs.archlinux.org/task/27616 - cd "${srcdir}/" - git clone git://git.seabios.org/seabios.git - cd seabios - #find 'tools/' 'contrib' -type f | xargs sed -i 's@^#!.*python$@#!/usr/bin/python2@' - make clean - make PYTHON=python2 } package() { cd "${srcdir}/${pkgname}-${pkgver}" make DESTDIR="${pkgdir}" install - # Use latest seabios version - # https://bugs.archlinux.org/task/27616 - cp "${srcdir}/seabios/out/bios.bin" "${pkgdir}/usr/share/qemu/bios.bin" + rm "${pkgdir}/usr/share/qemu/bios.bin" install -D -m644 "${srcdir}/65-kvm.rules" \ "${pkgdir}/usr/lib/udev/rules.d/65-kvm.rules" diff --git a/extra/slim/PKGBUILD b/extra/slim/PKGBUILD index fc74689a8..f968b228c 100644 --- a/extra/slim/PKGBUILD +++ b/extra/slim/PKGBUILD @@ -1,62 +1,48 @@ -# $Id: PKGBUILD 148930 2012-02-05 11:56:28Z ibiru $ +# $Id: PKGBUILD 158739 2012-05-08 16:15:26Z tpowa $ # Maintainer: Gaetan Bisson # Contributor: Thayer Williams # Contributor: Alexander Fehr # Contributor: Hugo Ideler pkgname=slim -pkgver=1.3.2 -pkgrel=7 +pkgver=1.3.3 +pkgrel=2 pkgdesc='Desktop-independent graphical login manager for X11' arch=('i686' 'x86_64') url='http://slim.berlios.de/' license=('GPL2') -depends=('pam' 'libxmu' 'libpng' 'libjpeg' 'libxft') +depends=('consolekit' 'pam' 'libxmu' 'libpng' 'libjpeg' 'libxft') +makedepends=('cmake') backup=('etc/slim.conf' 'etc/logrotate.d/slim' 'etc/pam.d/slim') source=("http://download.berlios.de/${pkgname}/${pkgname}-${pkgver}.tar.gz" 'rc.d' 'pam.d' 'logrotate' + 'slim.service' 'ptr_pam.patch' - 'no-host.patch' - 'restart.patch' - 'sigterm.patch' - 'session-name.patch' - 'tty-slowness.patch' - 'slim-1.3.2-libpng15.patch') -sha1sums=('e421d5487732c8317f8f591906661e014b036358' - '6fe0ba83509af634bce47be34e30995965bffc79' - 'a0e991ef0ac5120465a3be014a26e70ba073b6ae' - 'b969cc902c1d9915a5609141a652c77b2732407b' - '640668c984a13593a1bfba8d3b503c005d5f401e' - 'b86eddd083fb9f6259e46c735f55ebe76c655bd3' - '2d526bc0c498bf307ee50e2d22b4f53ffa0c4435' - '0b35048723c527fb824c5e0f9b9064f751871785' - 'fdd35562ce010babaeb793f92f9906fdcdaf3f9f' - '213fefe8533c845ea8c40585b6a8097820d5e5d2' - '3cd674e548f4e0aadbbd32a67b4efd1ed263afef') + 'session-name.patch') + install=install build() { - cd "${srcdir}/${pkgname}-${pkgver}" - - sed -i -e 's/png12/png15/g' Makefile + cd "${srcdir}/${pkgname}-${pkgver}" patch -p1 -i ../ptr_pam.patch # FS#23995: pointer mishandling confuses PAM - patch -p1 -i ../no-host.patch # cf patch: do not set PAM host - patch -p1 -i ../restart.patch # cf patch: restart X server if killed - patch -p1 -i ../sigterm.patch # FS#23984: do not wait for input when SIGTERM'd patch -p1 -i ../session-name.patch # FS#26693: fix default session name - patch -p1 -i ../tty-slowness.patch # FS#18313: fix sluggish TTY after slim start - patch -p0 -i ../slim-1.3.2-libpng15.patch - - make USE_PAM=1 + cd ${srcdir} + mkdir build + cd build + cmake ../${pkgbase}-${pkgver} \ + -DCMAKE_BUILD_TYPE=Release \ + -DCMAKE_SKIP_RPATH=ON \ + -DCMAKE_INSTALL_PREFIX=/usr \ + -DUSE_PAM=yes -DUSE_CONSOLEKIT=yes + make } package() { - cd "${srcdir}/${pkgname}-${pkgver}" - - make DESTDIR="${pkgdir}" MANDIR=/usr/share/man install + cd ${srcdir}/build/ + make DESTDIR="${pkgdir}" install install -D -m755 ../rc.d "${pkgdir}"/etc/rc.d/slim install -D -m644 ../pam.d "${pkgdir}"/etc/pam.d/slim @@ -65,4 +51,13 @@ package() { # Provide sane defaults sed -i 's|#xserver_arguments.*|xserver_arguments -nolisten tcp vt07|' "${pkgdir}"/etc/slim.conf sed -i 's|/var/run/slim.lock|/var/lock/slim.lock|' "${pkgdir}"/etc/slim.conf + # install systemd files + install -D -m644 ${srcdir}/slim.service ${pkgdir}/usr/lib/systemd/system/slim.service } +md5sums=('ce53e44c1e4a2eacf5bb7688ee2a5de8' + 'd8ea9c4dee2811524b67f4f666311a1f' + 'ebfff3417058619a1328284ae0e2f48e' + '43da096480bf72c3ccec8ad8400f34f0' + 'aef560f5a765582b2a7fc1fac5b323a7' + 'ae4b237d472ec5d373e30080aa0ff804' + 'ebcb6829028615686de7b64ceeaaf8ed') diff --git a/extra/slim/pam.d b/extra/slim/pam.d index 78a981f74..4a6b53d0f 100644 --- a/extra/slim/pam.d +++ b/extra/slim/pam.d @@ -7,4 +7,3 @@ password required pam_unix.so session required pam_limits.so session required pam_unix.so session optional pam_loginuid.so -session optional pam_ck_connector.so diff --git a/extra/slim/slim.service b/extra/slim/slim.service new file mode 100644 index 000000000..26093a8bf --- /dev/null +++ b/extra/slim/slim.service @@ -0,0 +1,10 @@ +[Unit] +Description=SLiM Simple Login Manager +Requires=dev-tty7.device +After=dev-tty7.device systemd-user-sessions.service + +[Service] +ExecStart=/usr/bin/slim -nodaemon + +[Install] +WantedBy=graphical.target diff --git a/testing/mpfr/PKGBUILD b/testing/mpfr/PKGBUILD new file mode 100644 index 000000000..e079d2ebe --- /dev/null +++ b/testing/mpfr/PKGBUILD @@ -0,0 +1,38 @@ +# $Id: PKGBUILD 158716 2012-05-08 09:42:21Z allan $ +# Maintainer: Allan McRae +# Contributor: damir + +pkgname=mpfr +_pkgver=3.1.0 +_patchlevel=p10 +pkgver=${_pkgver}.${_patchlevel} +pkgrel=1 +pkgdesc="Multiple-precision floating-point library" +arch=('i686' 'x86_64') +url="http://www.mpfr.org/" +license=('LGPL') +depends=('gmp>=5.0') +options=('!libtool') +install=mpfr.install +source=(http://www.mpfr.org/mpfr-current/mpfr-${_pkgver}.tar.xz{,.asc} + mpfr-${_pkgver}.${_patchlevel}.patch) +md5sums=('6e495841bb026481567006cec0f821c3' + '293374ee4b01527f8f7889fdfa9016f8' + '776954381923739ef0e618d992188535') + +build() { + cd "${srcdir}/${pkgname}-${_pkgver}" + patch -Np1 -i $srcdir/mpfr-${_pkgver}.${_patchlevel}.patch + ./configure --prefix=/usr --enable-thread-safe --enable-shared + make +} + +check() { + cd "${srcdir}/${pkgname}-${_pkgver}" + make check +} + +package() { + cd "${srcdir}/${pkgname}-${_pkgver}" + make DESTDIR="${pkgdir}" install +} diff --git a/testing/mpfr/mpfr-3.1.0.p10.patch b/testing/mpfr/mpfr-3.1.0.p10.patch new file mode 100644 index 000000000..0073be709 --- /dev/null +++ b/testing/mpfr/mpfr-3.1.0.p10.patch @@ -0,0 +1,1896 @@ +diff -Naurd mpfr-3.1.0-a/PATCHES mpfr-3.1.0-b/PATCHES +--- mpfr-3.1.0-a/PATCHES 2011-10-05 21:39:57.000000000 +0000 ++++ mpfr-3.1.0-b/PATCHES 2011-10-05 21:39:57.000000000 +0000 +@@ -0,0 +1 @@ ++mpfr_unlikely +diff -Naurd mpfr-3.1.0-a/VERSION mpfr-3.1.0-b/VERSION +--- mpfr-3.1.0-a/VERSION 2011-10-03 08:17:15.000000000 +0000 ++++ mpfr-3.1.0-b/VERSION 2011-10-05 21:39:57.000000000 +0000 +@@ -1 +1 @@ +-3.1.0 ++3.1.0-p1 +diff -Naurd mpfr-3.1.0-a/src/mpfr-impl.h mpfr-3.1.0-b/src/mpfr-impl.h +--- mpfr-3.1.0-a/src/mpfr-impl.h 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/mpfr-impl.h 2011-10-05 21:39:57.000000000 +0000 +@@ -988,10 +988,11 @@ + ******************************************************/ + + /* Theses macros help the compiler to determine if a test is +- * likely or unlikely. */ ++ likely or unlikely. The !! is necessary in case x is larger ++ than a long. */ + #if __MPFR_GNUC(3,0) || __MPFR_ICC(8,1,0) + # define MPFR_LIKELY(x) (__builtin_expect(!!(x),1)) +-# define MPFR_UNLIKELY(x) (__builtin_expect((x),0)) ++# define MPFR_UNLIKELY(x) (__builtin_expect(!!(x),0)) + #else + # define MPFR_LIKELY(x) (x) + # define MPFR_UNLIKELY(x) (x) +diff -Naurd mpfr-3.1.0-a/src/mpfr.h mpfr-3.1.0-b/src/mpfr.h +--- mpfr-3.1.0-a/src/mpfr.h 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/mpfr.h 2011-10-05 21:39:57.000000000 +0000 +@@ -27,7 +27,7 @@ + #define MPFR_VERSION_MAJOR 3 + #define MPFR_VERSION_MINOR 1 + #define MPFR_VERSION_PATCHLEVEL 0 +-#define MPFR_VERSION_STRING "3.1.0" ++#define MPFR_VERSION_STRING "3.1.0-p1" + + /* Macros dealing with MPFR VERSION */ + #define MPFR_VERSION_NUM(a,b,c) (((a) << 16L) | ((b) << 8) | (c)) +diff -Naurd mpfr-3.1.0-a/src/version.c mpfr-3.1.0-b/src/version.c +--- mpfr-3.1.0-a/src/version.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/version.c 2011-10-05 21:39:57.000000000 +0000 +@@ -25,5 +25,5 @@ + const char * + mpfr_get_version (void) + { +- return "3.1.0"; ++ return "3.1.0-p1"; + } +diff -Naurd mpfr-3.1.0-a/PATCHES mpfr-3.1.0-b/PATCHES +--- mpfr-3.1.0-a/PATCHES 2011-10-14 10:43:32.000000000 +0000 ++++ mpfr-3.1.0-b/PATCHES 2011-10-14 10:43:32.000000000 +0000 +@@ -0,0 +1 @@ ++lib-search-path +diff -Naurd mpfr-3.1.0-a/VERSION mpfr-3.1.0-b/VERSION +--- mpfr-3.1.0-a/VERSION 2011-10-05 21:39:57.000000000 +0000 ++++ mpfr-3.1.0-b/VERSION 2011-10-14 10:43:32.000000000 +0000 +@@ -1 +1 @@ +-3.1.0-p1 ++3.1.0-p2 +diff -Naurd mpfr-3.1.0-a/src/mpfr.h mpfr-3.1.0-b/src/mpfr.h +--- mpfr-3.1.0-a/src/mpfr.h 2011-10-05 21:39:57.000000000 +0000 ++++ mpfr-3.1.0-b/src/mpfr.h 2011-10-14 10:43:32.000000000 +0000 +@@ -27,7 +27,7 @@ + #define MPFR_VERSION_MAJOR 3 + #define MPFR_VERSION_MINOR 1 + #define MPFR_VERSION_PATCHLEVEL 0 +-#define MPFR_VERSION_STRING "3.1.0-p1" ++#define MPFR_VERSION_STRING "3.1.0-p2" + + /* Macros dealing with MPFR VERSION */ + #define MPFR_VERSION_NUM(a,b,c) (((a) << 16L) | ((b) << 8) | (c)) +diff -Naurd mpfr-3.1.0-a/src/version.c mpfr-3.1.0-b/src/version.c +--- mpfr-3.1.0-a/src/version.c 2011-10-05 21:39:57.000000000 +0000 ++++ mpfr-3.1.0-b/src/version.c 2011-10-14 10:43:32.000000000 +0000 +@@ -25,5 +25,5 @@ + const char * + mpfr_get_version (void) + { +- return "3.1.0-p1"; ++ return "3.1.0-p2"; + } +diff -Naurd mpfr-3.1.0-a/tests/Makefile.am mpfr-3.1.0-b/tests/Makefile.am +--- mpfr-3.1.0-a/tests/Makefile.am 2011-10-03 08:17:14.000000000 +0000 ++++ mpfr-3.1.0-b/tests/Makefile.am 2011-10-03 08:17:14.000000000 +0000 +@@ -65,8 +65,24 @@ + TESTS = $(check_PROGRAMS) + TESTS_ENVIRONMENT = MPFR_QUIET=1 $(VALGRIND) + +-# Option to prevent libtool from generating wrapper scripts for the tests. ++# The -no-install option prevents libtool from generating wrapper scripts ++# for the tests. + # This is useful to easily run the test scripts under valgrind or gdb. + # See discussion http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/28033 + # http://article.gmane.org/gmane.comp.lib.gnulib.bugs/28140 in particular. +-AM_LDFLAGS = -no-install ++# ++# The -L$(top_builddir)/src/.libs option is necessary for some platforms, ++# such as HP-UX, when --with-gmp or --with-gmp-lib is used and an old MPFR ++# library is already installed in the corresponding lib directory: its ++# purpose is to make sure that the local .libs comes first in the library ++# search path (otherwise the tests are linked against the old MPFR library ++# by the LINK command -- see the generated Makefile). See: ++# http://websympa.loria.fr/wwsympa/arc/mpfr/2011-10/msg00042.html ++# http://websympa.loria.fr/wwsympa/arc/mpfr/2011-10/msg00043.html ++# http://websympa.loria.fr/wwsympa/arc/mpfr/2011-10/msg00044.html ++# http://websympa.loria.fr/wwsympa/arc/mpfr/2011-10/msg00066.html ++# http://websympa.loria.fr/wwsympa/arc/mpfr/2011-10/msg00065.html ++# and ++# http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9728 ++# ++AM_LDFLAGS = -no-install -L$(top_builddir)/src/.libs +diff -Naurd mpfr-3.1.0-a/tests/Makefile.in mpfr-3.1.0-b/tests/Makefile.in +--- mpfr-3.1.0-a/tests/Makefile.in 2011-10-03 08:17:35.000000000 +0000 ++++ mpfr-3.1.0-b/tests/Makefile.in 2011-10-03 08:17:35.000000000 +0000 +@@ -1124,11 +1124,27 @@ + TESTS = $(check_PROGRAMS) + TESTS_ENVIRONMENT = MPFR_QUIET=1 $(VALGRIND) + +-# Option to prevent libtool from generating wrapper scripts for the tests. ++# The -no-install option prevents libtool from generating wrapper scripts ++# for the tests. + # This is useful to easily run the test scripts under valgrind or gdb. + # See discussion http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/28033 + # http://article.gmane.org/gmane.comp.lib.gnulib.bugs/28140 in particular. +-AM_LDFLAGS = -no-install ++# ++# The -L$(top_builddir)/src/.libs option is necessary for some platforms, ++# such as HP-UX, when --with-gmp or --with-gmp-lib is used and an old MPFR ++# library is already installed in the corresponding lib directory: its ++# purpose is to make sure that the local .libs comes first in the library ++# search path (otherwise the tests are linked against the old MPFR library ++# by the LINK command -- see the generated Makefile). See: ++# http://websympa.loria.fr/wwsympa/arc/mpfr/2011-10/msg00042.html ++# http://websympa.loria.fr/wwsympa/arc/mpfr/2011-10/msg00043.html ++# http://websympa.loria.fr/wwsympa/arc/mpfr/2011-10/msg00044.html ++# http://websympa.loria.fr/wwsympa/arc/mpfr/2011-10/msg00066.html ++# http://websympa.loria.fr/wwsympa/arc/mpfr/2011-10/msg00065.html ++# and ++# http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9728 ++# ++AM_LDFLAGS = -no-install -L$(top_builddir)/src/.libs + all: all-am + + .SUFFIXES: +diff -Naurd mpfr-3.1.0-a/PATCHES mpfr-3.1.0-b/PATCHES +--- mpfr-3.1.0-a/PATCHES 2011-11-03 15:15:11.000000000 +0000 ++++ mpfr-3.1.0-b/PATCHES 2011-11-03 15:15:11.000000000 +0000 +@@ -0,0 +1 @@ ++vasprintf +diff -Naurd mpfr-3.1.0-a/VERSION mpfr-3.1.0-b/VERSION +--- mpfr-3.1.0-a/VERSION 2011-10-14 10:43:32.000000000 +0000 ++++ mpfr-3.1.0-b/VERSION 2011-11-03 15:15:11.000000000 +0000 +@@ -1 +1 @@ +-3.1.0-p2 ++3.1.0-p3 +diff -Naurd mpfr-3.1.0-a/src/mpfr.h mpfr-3.1.0-b/src/mpfr.h +--- mpfr-3.1.0-a/src/mpfr.h 2011-10-14 10:43:32.000000000 +0000 ++++ mpfr-3.1.0-b/src/mpfr.h 2011-11-03 15:15:11.000000000 +0000 +@@ -27,7 +27,7 @@ + #define MPFR_VERSION_MAJOR 3 + #define MPFR_VERSION_MINOR 1 + #define MPFR_VERSION_PATCHLEVEL 0 +-#define MPFR_VERSION_STRING "3.1.0-p2" ++#define MPFR_VERSION_STRING "3.1.0-p3" + + /* Macros dealing with MPFR VERSION */ + #define MPFR_VERSION_NUM(a,b,c) (((a) << 16L) | ((b) << 8) | (c)) +diff -Naurd mpfr-3.1.0-a/src/vasprintf.c mpfr-3.1.0-b/src/vasprintf.c +--- mpfr-3.1.0-a/src/vasprintf.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/vasprintf.c 2011-11-03 15:15:11.000000000 +0000 +@@ -1178,7 +1178,7 @@ + mpfr_exp_t exp; + char * str; + const int spec_g = (spec.spec == 'g' || spec.spec == 'G'); +- const int keep_trailing_zeros = spec_g && spec.alt; ++ const int keep_trailing_zeros = !spec_g || spec.alt; + + /* WARNING: an empty precision field is forbidden (it means precision = 6 + and it should have been changed to 6 before the function call) */ +@@ -1356,7 +1356,7 @@ + else + /* 1 <= |p| */ + { +- size_t nsd; /* Number of significant digits */ ++ size_t str_len; + + /* Determine the position of the most significant decimal digit. */ + exp = floor_log10 (p); +@@ -1365,12 +1365,10 @@ + /* P is too large to print all its integral part digits */ + return -1; + +- np->ip_size = exp + 1; +- +- nsd = spec.prec + np->ip_size; + if (dec_info == NULL) +- { +- str = mpfr_get_str (NULL, &exp, 10, nsd, p, spec.rnd_mode); ++ { /* this case occurs with mpfr_printf ("%.0RUf", x) with x=9.5 */ ++ str = ++ mpfr_get_str (NULL, &exp, 10, spec.prec+exp+1, p, spec.rnd_mode); + register_string (np->sl, str); + } + else +@@ -1379,81 +1377,60 @@ + str = dec_info->str; + } + np->ip_ptr = MPFR_IS_NEG (p) ? ++str : str; /* skip sign */ ++ str_len = strlen (str); ++ ++ /* integral part */ ++ if (exp > str_len) ++ /* mpfr_get_str gives no trailing zero when p is rounded up to the next ++ power of 10 (p integer, so no fractional part) */ ++ { ++ np->ip_trailing_zeros = exp - str_len; ++ np->ip_size = str_len; ++ } ++ else ++ np->ip_size = exp; + + if (spec.group) + /* thousands separator in integral part */ + np->thousands_sep = MPFR_THOUSANDS_SEPARATOR; + +- if (nsd == 0 || (spec_g && !spec.alt)) +- /* compute how much non-zero digits in integral and fractional +- parts */ ++ /* fractional part */ ++ str += np->ip_size; ++ str_len -= np->ip_size; ++ if (!keep_trailing_zeros) ++ /* remove trailing zeros, if any */ + { +- size_t str_len; +- str_len = strlen (str); /* note: the sign has been skipped */ +- +- if (exp > str_len) +- /* mpfr_get_str doesn't give the trailing zeros when p is a +- multiple of 10 (p integer, so no fractional part) */ +- { +- np->ip_trailing_zeros = exp - str_len; +- np->ip_size = str_len; +- if (spec.alt) +- np->point = MPFR_DECIMAL_POINT; +- } +- else +- /* str may contain some digits which are in fractional part */ ++ char *ptr = str + str_len - 1; /* pointer to the last digit of ++ str */ ++ while ((*ptr == '0') && (str_len != 0)) + { +- char *ptr; +- +- ptr = str + str_len - 1; /* points to the end of str */ +- str_len -= np->ip_size; /* number of digits in fractional +- part */ +- +- if (!keep_trailing_zeros) +- /* remove trailing zeros, if any */ +- { +- while ((*ptr == '0') && (str_len != 0)) +- { +- --ptr; +- --str_len; +- } +- } +- +- if (str_len > INT_MAX) +- /* too many digits in fractional part */ +- return -1; +- +- if (str_len != 0) +- /* some digits in fractional part */ +- { +- np->point = MPFR_DECIMAL_POINT; +- np->fp_ptr = str + np->ip_size; +- np->fp_size = str_len; +- } ++ --ptr; ++ --str_len; + } + } +- else +- /* spec.prec digits in fractional part */ ++ ++ if (str_len > 0) ++ /* some nonzero digits in fractional part */ + { +- if (np->ip_size == exp - 1) +- /* the absolute value of the number has been rounded up to a power +- of ten. +- Insert an additional zero in integral part and put the rest of +- them in fractional part. */ +- np->ip_trailing_zeros = 1; ++ if (str_len > INT_MAX) ++ /* too many digits in fractional part */ ++ return -1; + +- if (spec.prec != 0) +- { +- MPFR_ASSERTD (np->ip_size + np->ip_trailing_zeros == exp); +- MPFR_ASSERTD (np->ip_size + spec.prec == nsd); ++ np->point = MPFR_DECIMAL_POINT; ++ np->fp_ptr = str; ++ np->fp_size = str_len; ++ } + +- np->point = MPFR_DECIMAL_POINT; +- np->fp_ptr = str + np->ip_size; +- np->fp_size = spec.prec; +- } +- else if (spec.alt) +- np->point = MPFR_DECIMAL_POINT; ++ if (keep_trailing_zeros && str_len < spec.prec) ++ /* add missing trailing zeros */ ++ { ++ np->point = MPFR_DECIMAL_POINT; ++ np->fp_trailing_zeros = spec.prec - np->fp_size; + } ++ ++ if (spec.alt) ++ /* add decimal point even if no digits follow it */ ++ np->point = MPFR_DECIMAL_POINT; + } + + return 0; +diff -Naurd mpfr-3.1.0-a/src/version.c mpfr-3.1.0-b/src/version.c +--- mpfr-3.1.0-a/src/version.c 2011-10-14 10:43:32.000000000 +0000 ++++ mpfr-3.1.0-b/src/version.c 2011-11-03 15:15:11.000000000 +0000 +@@ -25,5 +25,5 @@ + const char * + mpfr_get_version (void) + { +- return "3.1.0-p2"; ++ return "3.1.0-p3"; + } +diff -Naurd mpfr-3.1.0-a/tests/tsprintf.c mpfr-3.1.0-b/tests/tsprintf.c +--- mpfr-3.1.0-a/tests/tsprintf.c 2011-10-03 08:17:14.000000000 +0000 ++++ mpfr-3.1.0-b/tests/tsprintf.c 2011-11-03 15:15:11.000000000 +0000 +@@ -475,6 +475,18 @@ + check_sprintf ("-1.", "%- #0.1RG", x); + + /* precision zero */ ++ mpfr_set_d (x, 9.5, MPFR_RNDN); ++ check_sprintf ("9", "%.0RDf", x); ++ check_sprintf ("10", "%.0RUf", x); ++ ++ mpfr_set_d (x, 19.5, MPFR_RNDN); ++ check_sprintf ("19", "%.0RDf", x); ++ check_sprintf ("20", "%.0RUf", x); ++ ++ mpfr_set_d (x, 99.5, MPFR_RNDN); ++ check_sprintf ("99", "%.0RDf", x); ++ check_sprintf ("100", "%.0RUf", x); ++ + mpfr_set_d (x, -9.5, MPFR_RNDN); + check_sprintf ("-10", "%.0RDf", x); + check_sprintf ("-10", "%.0RYf", x); +@@ -1078,6 +1090,23 @@ + mpfr_clear (x); + } + ++static void ++bug20111102 (void) ++{ ++ mpfr_t t; ++ char s[100]; ++ ++ mpfr_init2 (t, 84); ++ mpfr_set_str (t, "999.99999999999999999999", 10, MPFR_RNDN); ++ mpfr_sprintf (s, "%.20RNg", t); ++ if (strcmp (s, "1000") != 0) ++ { ++ printf ("Error in bug20111102, expected 1000, got %s\n", s); ++ exit (1); ++ } ++ mpfr_clear (t); ++} ++ + /* In particular, the following test makes sure that the rounding + * for %Ra and %Rb is not done on the MPFR number itself (as it + * would overflow). Note: it has been reported on comp.std.c that +@@ -1161,6 +1190,7 @@ + locale = setlocale (LC_ALL, "C"); + #endif + ++ bug20111102 (); + native_types (); + hexadecimal (); + binary (); +diff -Naurd mpfr-3.1.0-a/PATCHES mpfr-3.1.0-b/PATCHES +--- mpfr-3.1.0-a/PATCHES 2011-11-28 12:22:52.000000000 +0000 ++++ mpfr-3.1.0-b/PATCHES 2011-11-28 12:22:52.000000000 +0000 +@@ -0,0 +1 @@ ++gmp41compat +diff -Naurd mpfr-3.1.0-a/VERSION mpfr-3.1.0-b/VERSION +--- mpfr-3.1.0-a/VERSION 2011-11-03 15:15:11.000000000 +0000 ++++ mpfr-3.1.0-b/VERSION 2011-11-28 12:22:52.000000000 +0000 +@@ -1 +1 @@ +-3.1.0-p3 ++3.1.0-p4 +diff -Naurd mpfr-3.1.0-a/doc/mpfr.info mpfr-3.1.0-b/doc/mpfr.info +--- mpfr-3.1.0-a/doc/mpfr.info 2011-10-03 09:43:04.000000000 +0000 ++++ mpfr-3.1.0-b/doc/mpfr.info 2011-11-28 12:22:52.000000000 +0000 +@@ -2994,11 +2994,12 @@ + + * `mpfr_urandom' and `mpfr_urandomb' changed in MPFR 3.1. Their + behavior no longer depends on the platform (assuming this is also +- true for GMP's random generator). As a consequence, the returned +- values can be different between MPFR 3.1 and previous MPFR +- versions. Note: as the reproducibility of these functions was not +- specified before MPFR 3.1, the MPFR 3.1 behavior is _not_ regarded +- as backward incompatible with previous versions. ++ true for GMP's random generator, which is not the case between GMP ++ 4.1 and 4.2 if `gmp_randinit_default' is used). As a consequence, ++ the returned values can be different between MPFR 3.1 and previous ++ MPFR versions. Note: as the reproducibility of these functions ++ was not specified before MPFR 3.1, the MPFR 3.1 behavior is _not_ ++ regarded as backward incompatible with previous versions. + + +  +@@ -4239,13 +4240,13 @@ + Node: Type and Macro Changes129308 + Node: Added Functions132029 + Node: Changed Functions134972 +-Node: Removed Functions139167 +-Node: Other Changes139579 +-Node: Contributors141108 +-Node: References143574 +-Node: GNU Free Documentation License145315 +-Node: Concept Index167758 +-Node: Function and Type Index173677 ++Node: Removed Functions139253 ++Node: Other Changes139665 ++Node: Contributors141194 ++Node: References143660 ++Node: GNU Free Documentation License145401 ++Node: Concept Index167844 ++Node: Function and Type Index173763 +  + End Tag Table + +diff -Naurd mpfr-3.1.0-a/doc/mpfr.texi mpfr-3.1.0-b/doc/mpfr.texi +--- mpfr-3.1.0-a/doc/mpfr.texi 2011-10-03 08:17:14.000000000 +0000 ++++ mpfr-3.1.0-b/doc/mpfr.texi 2011-11-28 12:22:52.000000000 +0000 +@@ -3466,8 +3466,9 @@ + a lack of specification. + + @item @code{mpfr_urandom} and @code{mpfr_urandomb} changed in MPFR 3.1. +-Their behavior no longer depends on the platform (assuming this is also +-true for GMP's random generator). As a consequence, the returned values ++Their behavior no longer depends on the platform (assuming this is also true ++for GMP's random generator, which is not the case between GMP 4.1 and 4.2 if ++@code{gmp_randinit_default} is used). As a consequence, the returned values + can be different between MPFR 3.1 and previous MPFR versions. + Note: as the reproducibility of these functions was not specified + before MPFR 3.1, the MPFR 3.1 behavior is @emph{not} regarded as +diff -Naurd mpfr-3.1.0-a/src/mpfr.h mpfr-3.1.0-b/src/mpfr.h +--- mpfr-3.1.0-a/src/mpfr.h 2011-11-03 15:15:11.000000000 +0000 ++++ mpfr-3.1.0-b/src/mpfr.h 2011-11-28 12:22:52.000000000 +0000 +@@ -27,7 +27,7 @@ + #define MPFR_VERSION_MAJOR 3 + #define MPFR_VERSION_MINOR 1 + #define MPFR_VERSION_PATCHLEVEL 0 +-#define MPFR_VERSION_STRING "3.1.0-p3" ++#define MPFR_VERSION_STRING "3.1.0-p4" + + /* Macros dealing with MPFR VERSION */ + #define MPFR_VERSION_NUM(a,b,c) (((a) << 16L) | ((b) << 8) | (c)) +diff -Naurd mpfr-3.1.0-a/src/version.c mpfr-3.1.0-b/src/version.c +--- mpfr-3.1.0-a/src/version.c 2011-11-03 15:15:11.000000000 +0000 ++++ mpfr-3.1.0-b/src/version.c 2011-11-28 12:22:52.000000000 +0000 +@@ -25,5 +25,5 @@ + const char * + mpfr_get_version (void) + { +- return "3.1.0-p3"; ++ return "3.1.0-p4"; + } +diff -Naurd mpfr-3.1.0-a/tests/trandom.c mpfr-3.1.0-b/tests/trandom.c +--- mpfr-3.1.0-a/tests/trandom.c 2011-10-03 08:17:14.000000000 +0000 ++++ mpfr-3.1.0-b/tests/trandom.c 2011-11-28 12:22:52.000000000 +0000 +@@ -114,21 +114,29 @@ + mpfr_t x; + gmp_randstate_t s; + ++#if __MPFR_GMP(4,2,0) ++# define C1 "0.895943" ++# define C2 "0.848824" ++#else ++# define C1 "0.479652" ++# define C2 "0.648529" ++#endif ++ + gmp_randinit_default (s); + gmp_randseed_ui (s, 42); + mpfr_init2 (x, 17); + mpfr_urandomb (x, s); +- if (mpfr_cmp_str1 (x, "0.895943") != 0) ++ if (mpfr_cmp_str1 (x, C1) != 0) + { +- printf ("Error in bug20100914, expected 0.895943, got "); ++ printf ("Error in bug20100914, expected " C1 ", got "); + mpfr_out_str (stdout, 10, 0, x, MPFR_RNDN); + printf ("\n"); + exit (1); + } + mpfr_urandomb (x, s); +- if (mpfr_cmp_str1 (x, "0.848824") != 0) ++ if (mpfr_cmp_str1 (x, C2) != 0) + { +- printf ("Error in bug20100914, expected 0.848824, got "); ++ printf ("Error in bug20100914, expected " C2 ", got "); + mpfr_out_str (stdout, 10, 0, x, MPFR_RNDN); + printf ("\n"); + exit (1); +diff -Naurd mpfr-3.1.0-a/tests/turandom.c mpfr-3.1.0-b/tests/turandom.c +--- mpfr-3.1.0-a/tests/turandom.c 2011-10-03 08:17:14.000000000 +0000 ++++ mpfr-3.1.0-b/tests/turandom.c 2011-11-28 12:22:52.000000000 +0000 +@@ -160,23 +160,29 @@ + mpfr_t x; + gmp_randstate_t s; + ++#if __MPFR_GMP(4,2,0) ++# define C1 "0.8488312" ++# define C2 "0.8156509" ++#else ++# define C1 "0.6485367" ++# define C2 "0.9362717" ++#endif ++ + gmp_randinit_default (s); + gmp_randseed_ui (s, 42); + mpfr_init2 (x, 17); + mpfr_urandom (x, s, MPFR_RNDN); +- /* the following values are obtained on a 32-bit computer, we should get +- the same values on a 64-bit computer */ +- if (mpfr_cmp_str1 (x, "0.8488312") != 0) ++ if (mpfr_cmp_str1 (x, C1) != 0) + { +- printf ("Error in bug20100914, expected 0.8488312, got "); ++ printf ("Error in bug20100914, expected " C1 ", got "); + mpfr_out_str (stdout, 10, 0, x, MPFR_RNDN); + printf ("\n"); + exit (1); + } + mpfr_urandom (x, s, MPFR_RNDN); +- if (mpfr_cmp_str1 (x, "0.8156509") != 0) ++ if (mpfr_cmp_str1 (x, C2) != 0) + { +- printf ("Error in bug20100914, expected 0.8156509, got "); ++ printf ("Error in bug20100914, expected " C2 ", got "); + mpfr_out_str (stdout, 10, 0, x, MPFR_RNDN); + printf ("\n"); + exit (1); +diff -Naurd mpfr-3.1.0-a/PATCHES mpfr-3.1.0-b/PATCHES +--- mpfr-3.1.0-a/PATCHES 2012-02-24 12:44:49.000000000 +0000 ++++ mpfr-3.1.0-b/PATCHES 2012-02-24 12:44:49.000000000 +0000 +@@ -0,0 +1 @@ ++logging-freeze +diff -Naurd mpfr-3.1.0-a/VERSION mpfr-3.1.0-b/VERSION +--- mpfr-3.1.0-a/VERSION 2011-11-28 12:22:52.000000000 +0000 ++++ mpfr-3.1.0-b/VERSION 2012-02-24 12:44:49.000000000 +0000 +@@ -1 +1 @@ +-3.1.0-p4 ++3.1.0-p5 +diff -Naurd mpfr-3.1.0-a/src/add_d.c mpfr-3.1.0-b/src/add_d.c +--- mpfr-3.1.0-a/src/add_d.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/add_d.c 2012-02-24 12:44:49.000000000 +0000 +@@ -34,7 +34,7 @@ + (("b[%Pu]=%.*Rg c=%.20g rnd=%d", + mpfr_get_prec(b), mpfr_log_prec, b, c, rnd_mode), + ("a[%Pu]=%.*Rg inexact=%d", +- mpfr_get_prec (a), mpfr_get_prec, a, inexact)); ++ mpfr_get_prec (a), mpfr_log_prec, a, inexact)); + + MPFR_SAVE_EXPO_MARK (expo); + +diff -Naurd mpfr-3.1.0-a/src/add_ui.c mpfr-3.1.0-b/src/add_ui.c +--- mpfr-3.1.0-a/src/add_ui.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/add_ui.c 2012-02-24 12:44:49.000000000 +0000 +@@ -29,7 +29,7 @@ + MPFR_LOG_FUNC + (("x[%Pu]=%.*Rg u=%d rnd=%d", + mpfr_get_prec(x), mpfr_log_prec, x, u, rnd_mode), +- ("y[%Pu]=%.*Rg", mpfr_get_prec (y), mpfr_get_prec, y)); ++ ("y[%Pu]=%.*Rg", mpfr_get_prec (y), mpfr_log_prec, y)); + + if (MPFR_LIKELY(u != 0) ) /* if u=0, do nothing */ + { +diff -Naurd mpfr-3.1.0-a/src/mpfr.h mpfr-3.1.0-b/src/mpfr.h +--- mpfr-3.1.0-a/src/mpfr.h 2011-11-28 12:22:52.000000000 +0000 ++++ mpfr-3.1.0-b/src/mpfr.h 2012-02-24 12:44:49.000000000 +0000 +@@ -27,7 +27,7 @@ + #define MPFR_VERSION_MAJOR 3 + #define MPFR_VERSION_MINOR 1 + #define MPFR_VERSION_PATCHLEVEL 0 +-#define MPFR_VERSION_STRING "3.1.0-p4" ++#define MPFR_VERSION_STRING "3.1.0-p5" + + /* Macros dealing with MPFR VERSION */ + #define MPFR_VERSION_NUM(a,b,c) (((a) << 16L) | ((b) << 8) | (c)) +diff -Naurd mpfr-3.1.0-a/src/mul_d.c mpfr-3.1.0-b/src/mul_d.c +--- mpfr-3.1.0-a/src/mul_d.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/mul_d.c 2012-02-24 12:44:49.000000000 +0000 +@@ -34,7 +34,7 @@ + (("b[%Pu]=%.*Rg c=%.20g rnd=%d", + mpfr_get_prec(b), mpfr_log_prec, b, c, rnd_mode), + ("a[%Pu]=%.*Rg inexact=%d", +- mpfr_get_prec (a), mpfr_get_prec, a, inexact)); ++ mpfr_get_prec (a), mpfr_log_prec, a, inexact)); + + MPFR_SAVE_EXPO_MARK (expo); + +diff -Naurd mpfr-3.1.0-a/src/version.c mpfr-3.1.0-b/src/version.c +--- mpfr-3.1.0-a/src/version.c 2011-11-28 12:22:52.000000000 +0000 ++++ mpfr-3.1.0-b/src/version.c 2012-02-24 12:44:49.000000000 +0000 +@@ -25,5 +25,5 @@ + const char * + mpfr_get_version (void) + { +- return "3.1.0-p4"; ++ return "3.1.0-p5"; + } +diff -Naurd mpfr-3.1.0-a/PATCHES mpfr-3.1.0-b/PATCHES +--- mpfr-3.1.0-a/PATCHES 2012-02-24 13:50:05.000000000 +0000 ++++ mpfr-3.1.0-b/PATCHES 2012-02-24 13:50:05.000000000 +0000 +@@ -0,0 +1 @@ ++logging-varfmt +diff -Naurd mpfr-3.1.0-a/VERSION mpfr-3.1.0-b/VERSION +--- mpfr-3.1.0-a/VERSION 2012-02-24 12:44:49.000000000 +0000 ++++ mpfr-3.1.0-b/VERSION 2012-02-24 13:50:05.000000000 +0000 +@@ -1 +1 @@ +-3.1.0-p5 ++3.1.0-p6 +diff -Naurd mpfr-3.1.0-a/src/mpfr-impl.h mpfr-3.1.0-b/src/mpfr-impl.h +--- mpfr-3.1.0-a/src/mpfr-impl.h 2011-10-05 21:39:57.000000000 +0000 ++++ mpfr-3.1.0-b/src/mpfr-impl.h 2012-02-24 13:50:05.000000000 +0000 +@@ -1592,7 +1592,7 @@ + do \ + if ((MPFR_LOG_INTERNAL_F & mpfr_log_type) && \ + (mpfr_log_current <= mpfr_log_level)) \ +- LOG_PRINT ("%s.%d:%s[%#Pu]=%.*Rf\n", __func__, __LINE__, \ ++ LOG_PRINT ("%s.%d:%s[%#Pu]=%.*Rg\n", __func__, __LINE__, \ + #x, mpfr_get_prec (x), mpfr_log_prec, x); \ + while (0) + +diff -Naurd mpfr-3.1.0-a/src/mpfr.h mpfr-3.1.0-b/src/mpfr.h +--- mpfr-3.1.0-a/src/mpfr.h 2012-02-24 12:44:49.000000000 +0000 ++++ mpfr-3.1.0-b/src/mpfr.h 2012-02-24 13:50:05.000000000 +0000 +@@ -27,7 +27,7 @@ + #define MPFR_VERSION_MAJOR 3 + #define MPFR_VERSION_MINOR 1 + #define MPFR_VERSION_PATCHLEVEL 0 +-#define MPFR_VERSION_STRING "3.1.0-p5" ++#define MPFR_VERSION_STRING "3.1.0-p6" + + /* Macros dealing with MPFR VERSION */ + #define MPFR_VERSION_NUM(a,b,c) (((a) << 16L) | ((b) << 8) | (c)) +diff -Naurd mpfr-3.1.0-a/src/version.c mpfr-3.1.0-b/src/version.c +--- mpfr-3.1.0-a/src/version.c 2012-02-24 12:44:49.000000000 +0000 ++++ mpfr-3.1.0-b/src/version.c 2012-02-24 13:50:05.000000000 +0000 +@@ -25,5 +25,5 @@ + const char * + mpfr_get_version (void) + { +- return "3.1.0-p5"; ++ return "3.1.0-p6"; + } +diff -Naurd mpfr-3.1.0-a/PATCHES mpfr-3.1.0-b/PATCHES +--- mpfr-3.1.0-a/PATCHES 2012-03-08 15:17:03.000000000 +0000 ++++ mpfr-3.1.0-b/PATCHES 2012-03-08 15:17:03.000000000 +0000 +@@ -0,0 +1 @@ ++large-prec +diff -Naurd mpfr-3.1.0-a/VERSION mpfr-3.1.0-b/VERSION +--- mpfr-3.1.0-a/VERSION 2012-02-24 13:50:05.000000000 +0000 ++++ mpfr-3.1.0-b/VERSION 2012-03-08 15:17:03.000000000 +0000 +@@ -1 +1 @@ +-3.1.0-p6 ++3.1.0-p7 +diff -Naurd mpfr-3.1.0-a/src/add1.c mpfr-3.1.0-b/src/add1.c +--- mpfr-3.1.0-a/src/add1.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/add1.c 2012-03-08 15:17:03.000000000 +0000 +@@ -44,12 +44,12 @@ + bq = MPFR_PREC(b); + cq = MPFR_PREC(c); + +- an = (aq-1)/GMP_NUMB_BITS+1; /* number of limbs of a */ ++ an = MPFR_PREC2LIMBS (aq); /* number of limbs of a */ + aq2 = (mpfr_prec_t) an * GMP_NUMB_BITS; + sh = aq2 - aq; /* non-significant bits in low limb */ + +- bn = (bq-1)/GMP_NUMB_BITS+1; /* number of limbs of b */ +- cn = (cq-1)/GMP_NUMB_BITS+1; /* number of limbs of c */ ++ bn = MPFR_PREC2LIMBS (bq); /* number of limbs of b */ ++ cn = MPFR_PREC2LIMBS (cq); /* number of limbs of c */ + + ap = MPFR_MANT(a); + bp = MPFR_MANT(b); +@@ -124,7 +124,7 @@ + dif = aq2 - diff_exp; + /* dif is the number of bits of c which overlap with a' */ + +- difn = (dif-1)/GMP_NUMB_BITS + 1; ++ difn = MPFR_PREC2LIMBS (dif); + /* only the highest difn limbs from c have to be considered */ + if (MPFR_UNLIKELY(difn > cn)) + { +diff -Naurd mpfr-3.1.0-a/src/add1sp.c mpfr-3.1.0-b/src/add1sp.c +--- mpfr-3.1.0-a/src/add1sp.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/add1sp.c 2012-03-08 15:17:03.000000000 +0000 +@@ -107,7 +107,7 @@ + + /* Read prec and num of limbs */ + p = MPFR_PREC(b); +- n = (p+GMP_NUMB_BITS-1)/GMP_NUMB_BITS; ++ n = MPFR_PREC2LIMBS (p); + MPFR_UNSIGNED_MINUS_MODULO(sh, p); + bx = MPFR_GET_EXP(b); + d = (mpfr_uexp_t) (bx - MPFR_GET_EXP(c)); +diff -Naurd mpfr-3.1.0-a/src/agm.c mpfr-3.1.0-b/src/agm.c +--- mpfr-3.1.0-a/src/agm.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/agm.c 2012-03-08 15:17:03.000000000 +0000 +@@ -91,7 +91,7 @@ + q = MPFR_PREC(r); + p = q + MPFR_INT_CEIL_LOG2(q) + 15; + MPFR_ASSERTD (p >= 7); /* see algorithms.tex */ +- s = (p - 1) / GMP_NUMB_BITS + 1; ++ s = MPFR_PREC2LIMBS (p); + + /* b (op2) and a (op1) are the 2 operands but we want b >= a */ + compare = mpfr_cmp (op1, op2); +@@ -285,7 +285,7 @@ + + /* Next iteration */ + MPFR_ZIV_NEXT (loop, p); +- s = (p - 1) / GMP_NUMB_BITS + 1; ++ s = MPFR_PREC2LIMBS (p); + } + MPFR_ZIV_FREE (loop); + +diff -Naurd mpfr-3.1.0-a/src/eq.c mpfr-3.1.0-b/src/eq.c +--- mpfr-3.1.0-a/src/eq.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/eq.c 2012-03-08 15:17:03.000000000 +0000 +@@ -56,8 +56,8 @@ + if (uexp != vexp) + return 0; /* no bit agree */ + +- usize = (MPFR_PREC(u) - 1) / GMP_NUMB_BITS + 1; +- vsize = (MPFR_PREC(v) - 1) / GMP_NUMB_BITS + 1; ++ usize = MPFR_LIMB_SIZE (u); ++ vsize = MPFR_LIMB_SIZE (v); + + if (vsize > usize) /* exchange u and v */ + { +diff -Naurd mpfr-3.1.0-a/src/exp.c mpfr-3.1.0-b/src/exp.c +--- mpfr-3.1.0-a/src/exp.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/exp.c 2012-03-08 15:17:03.000000000 +0000 +@@ -133,7 +133,7 @@ + mp_size_t yn; + int sh; + +- yn = 1 + (MPFR_PREC(y) - 1) / GMP_NUMB_BITS; ++ yn = MPFR_LIMB_SIZE (y); + sh = (mpfr_prec_t) yn * GMP_NUMB_BITS - MPFR_PREC(y); + MPFR_MANT(y)[0] += MPFR_LIMB_ONE << sh; + inexact = 1; +diff -Naurd mpfr-3.1.0-a/src/get_d.c mpfr-3.1.0-b/src/get_d.c +--- mpfr-3.1.0-a/src/get_d.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/get_d.c 2012-03-08 15:17:03.000000000 +0000 +@@ -100,7 +100,7 @@ + nbits += (1021 + e); + MPFR_ASSERTD (nbits >= 1); + } +- np = (nbits + GMP_NUMB_BITS - 1) / GMP_NUMB_BITS; ++ np = MPFR_PREC2LIMBS (nbits); + MPFR_ASSERTD ( np <= MPFR_LIMBS_PER_DOUBLE ); + carry = mpfr_round_raw_4 (tp, MPFR_MANT(src), MPFR_PREC(src), negative, + nbits, rnd_mode); +diff -Naurd mpfr-3.1.0-a/src/get_flt.c mpfr-3.1.0-b/src/get_flt.c +--- mpfr-3.1.0-a/src/get_flt.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/get_flt.c 2012-03-08 15:17:03.000000000 +0000 +@@ -92,7 +92,7 @@ + nbits += (125 + e); + MPFR_ASSERTD (nbits >= 1); + } +- np = (nbits + GMP_NUMB_BITS - 1) / GMP_NUMB_BITS; ++ np = MPFR_PREC2LIMBS (nbits); + MPFR_ASSERTD(np <= MPFR_LIMBS_PER_FLT); + carry = mpfr_round_raw_4 (tp, MPFR_MANT(src), MPFR_PREC(src), negative, + nbits, rnd_mode); +diff -Naurd mpfr-3.1.0-a/src/get_str.c mpfr-3.1.0-b/src/get_str.c +--- mpfr-3.1.0-a/src/get_str.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/get_str.c 2012-03-08 15:17:03.000000000 +0000 +@@ -2351,7 +2351,7 @@ + + /* the first digit will contain only r bits */ + prec = (m - 1) * pow2 + r; /* total number of bits */ +- n = (prec - 1) / GMP_NUMB_BITS + 1; ++ n = MPFR_PREC2LIMBS (prec); + + MPFR_TMP_MARK (marker); + x1 = MPFR_TMP_LIMBS_ALLOC (n + 1); +@@ -2417,12 +2417,12 @@ + exact = 1; + + /* number of limbs */ +- n = 1 + (prec - 1) / GMP_NUMB_BITS; ++ n = MPFR_PREC2LIMBS (prec); + + /* a will contain the approximation of the mantissa */ + a = MPFR_TMP_LIMBS_ALLOC (n); + +- nx = 1 + (MPFR_PREC(x) - 1) / GMP_NUMB_BITS; ++ nx = MPFR_LIMB_SIZE (x); + + if ((mpfr_exp_t) m == g) /* final exponent is 0, no multiplication or + division to perform */ +diff -Naurd mpfr-3.1.0-a/src/init2.c mpfr-3.1.0-b/src/init2.c +--- mpfr-3.1.0-a/src/init2.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/init2.c 2012-03-08 15:17:03.000000000 +0000 +@@ -51,7 +51,7 @@ + which both have an odd mantissa */ + MPFR_ASSERTN(p >= MPFR_PREC_MIN && p <= MPFR_PREC_MAX); + +- xsize = (mp_size_t) ((p - 1) / GMP_NUMB_BITS) + 1; ++ xsize = MPFR_PREC2LIMBS (p); + tmp = (mpfr_limb_ptr) (*__gmp_allocate_func)(MPFR_MALLOC_SIZE(xsize)); + + MPFR_PREC(x) = p; /* Set prec */ +diff -Naurd mpfr-3.1.0-a/src/lngamma.c mpfr-3.1.0-b/src/lngamma.c +--- mpfr-3.1.0-a/src/lngamma.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/lngamma.c 2012-03-08 15:17:03.000000000 +0000 +@@ -67,7 +67,7 @@ + + /* Now, the unit bit is represented. */ + +- prec = ((prec - 1) / GMP_NUMB_BITS + 1) * GMP_NUMB_BITS - expo; ++ prec = MPFR_PREC2LIMBS (prec) * GMP_NUMB_BITS - expo; + /* number of represented fractional bits (including the trailing 0's) */ + + x0 = *(MPFR_MANT (x) + prec / GMP_NUMB_BITS); +diff -Naurd mpfr-3.1.0-a/src/mpfr-impl.h mpfr-3.1.0-b/src/mpfr-impl.h +--- mpfr-3.1.0-a/src/mpfr-impl.h 2012-02-24 13:50:05.000000000 +0000 ++++ mpfr-3.1.0-b/src/mpfr-impl.h 2012-03-09 12:06:26.000000000 +0000 +@@ -646,10 +646,24 @@ + **************** mpfr_t properties ******************* + ******************************************************/ + ++/* In the following macro, p is usually a mpfr_prec_t, but this macro ++ works with other integer types (without integer overflow). Checking ++ that p >= 1 in debug mode is useful here because this macro can be ++ used on a computed precision (in particular, this formula does not ++ work for a degenerate case p = 0, and could give different results ++ on different platforms). But let us not use an assertion checking ++ in the MPFR_LAST_LIMB() and MPFR_LIMB_SIZE() macros below to avoid ++ too much expansion for assertions (in practice, this should be a ++ problem just when testing MPFR with the --enable-assert configure ++ option and the -ansi -pedantic-errors gcc compiler flags). */ ++#define MPFR_PREC2LIMBS(p) \ ++ (MPFR_ASSERTD ((p) >= 1), ((p) - 1) / GMP_NUMB_BITS + 1) ++ + #define MPFR_PREC(x) ((x)->_mpfr_prec) + #define MPFR_EXP(x) ((x)->_mpfr_exp) + #define MPFR_MANT(x) ((x)->_mpfr_d) +-#define MPFR_LIMB_SIZE(x) ((MPFR_PREC((x))-1)/GMP_NUMB_BITS+1) ++#define MPFR_LAST_LIMB(x) ((MPFR_PREC (x) - 1) / GMP_NUMB_BITS) ++#define MPFR_LIMB_SIZE(x) (MPFR_LAST_LIMB (x) + 1) + + + /****************************************************** +@@ -749,7 +763,8 @@ + #define MPFR_IS_FP(x) (!MPFR_IS_NAN(x) && !MPFR_IS_INF(x)) + #define MPFR_IS_SINGULAR(x) (MPFR_EXP(x) <= MPFR_EXP_INF) + #define MPFR_IS_PURE_FP(x) (!MPFR_IS_SINGULAR(x) && \ +- (MPFR_ASSERTD (MPFR_MANT(x)[MPFR_LIMB_SIZE(x)-1] & MPFR_LIMB_HIGHBIT), 1)) ++ (MPFR_ASSERTD ((MPFR_MANT(x)[MPFR_LAST_LIMB(x)] \ ++ & MPFR_LIMB_HIGHBIT) != 0), 1)) + + #define MPFR_ARE_SINGULAR(x,y) \ + (MPFR_UNLIKELY(MPFR_IS_SINGULAR(x)) || MPFR_UNLIKELY(MPFR_IS_SINGULAR(y))) +@@ -1061,7 +1076,7 @@ + /* Set a number to 1 (Fast) - It doesn't check if 1 is in the exponent range */ + #define MPFR_SET_ONE(x) \ + do { \ +- mp_size_t _size = MPFR_LIMB_SIZE(x) - 1; \ ++ mp_size_t _size = MPFR_LAST_LIMB(x); \ + MPFR_SET_POS(x); \ + MPFR_EXP(x) = 1; \ + MPN_ZERO ( MPFR_MANT(x), _size); \ +@@ -1213,8 +1228,8 @@ + _destp = MPFR_MANT (dest); \ + if (MPFR_UNLIKELY (_destprec >= _srcprec)) \ + { \ +- _srcs = (_srcprec + GMP_NUMB_BITS-1)/GMP_NUMB_BITS; \ +- _dests = (_destprec + GMP_NUMB_BITS-1)/GMP_NUMB_BITS - _srcs; \ ++ _srcs = MPFR_PREC2LIMBS (_srcprec); \ ++ _dests = MPFR_PREC2LIMBS (_destprec) - _srcs; \ + MPN_COPY (_destp + _dests, srcp, _srcs); \ + MPN_ZERO (_destp, _dests); \ + inexact = 0; \ +@@ -1227,8 +1242,8 @@ + mp_limb_t _rb, _sb, _ulp; \ + \ + /* Compute Position and shift */ \ +- _srcs = (_srcprec + GMP_NUMB_BITS-1)/GMP_NUMB_BITS; \ +- _dests = (_destprec + GMP_NUMB_BITS-1)/GMP_NUMB_BITS; \ ++ _srcs = MPFR_PREC2LIMBS (_srcprec); \ ++ _dests = MPFR_PREC2LIMBS (_destprec); \ + MPFR_UNSIGNED_MINUS_MODULO (_sh, _destprec); \ + _sp = (srcp) + _srcs - _dests; \ + \ +@@ -1372,7 +1387,7 @@ + if (MPFR_LIKELY (MPFR_PREC (dest) == MPFR_PREC (src))) \ + { \ + MPN_COPY (MPFR_MANT (dest), MPFR_MANT (src), \ +- (MPFR_PREC (src) + GMP_NUMB_BITS-1)/GMP_NUMB_BITS); \ ++ MPFR_LIMB_SIZE (src)); \ + inexact = 0; \ + } \ + else \ +@@ -1682,7 +1697,7 @@ + MPFR_ASSERTD (_prec >= MPFR_PREC_MIN); \ + if (MPFR_UNLIKELY (_prec > MPFR_PREC_MAX)) \ + mpfr_abort_prec_max (); \ +- _size = (mpfr_prec_t) (_prec + GMP_NUMB_BITS - 1) / GMP_NUMB_BITS; \ ++ _size = MPFR_PREC2LIMBS (_prec); \ + if (MPFR_UNLIKELY (_size * (num) > MPFR_GROUP_STATIC_SIZE)) \ + { \ + (g).alloc = (num) * _size * sizeof (mp_limb_t); \ +@@ -1733,7 +1748,7 @@ + MPFR_ASSERTD (_prec >= MPFR_PREC_MIN); \ + if (MPFR_UNLIKELY (_prec > MPFR_PREC_MAX)) \ + mpfr_abort_prec_max (); \ +- _size = (mpfr_prec_t) (_prec + GMP_NUMB_BITS - 1) / GMP_NUMB_BITS; \ ++ _size = MPFR_PREC2LIMBS (_prec); \ + (g).alloc = (num) * _size * sizeof (mp_limb_t); \ + if (MPFR_LIKELY (_oalloc == 0)) \ + (g).mant = (mp_limb_t *) (*__gmp_allocate_func) ((g).alloc); \ +@@ -1886,7 +1901,7 @@ + MPFR_NORETURN_ATTR; + + __MPFR_DECLSPEC void mpfr_rand_raw _MPFR_PROTO((mpfr_limb_ptr, gmp_randstate_t, +- unsigned long)); ++ mpfr_prec_t)); + + __MPFR_DECLSPEC mpz_t* mpfr_bernoulli_internal _MPFR_PROTO((mpz_t*, + unsigned long)); +diff -Naurd mpfr-3.1.0-a/src/mpfr.h mpfr-3.1.0-b/src/mpfr.h +--- mpfr-3.1.0-a/src/mpfr.h 2012-02-24 13:50:05.000000000 +0000 ++++ mpfr-3.1.0-b/src/mpfr.h 2012-03-08 15:17:03.000000000 +0000 +@@ -27,7 +27,7 @@ + #define MPFR_VERSION_MAJOR 3 + #define MPFR_VERSION_MINOR 1 + #define MPFR_VERSION_PATCHLEVEL 0 +-#define MPFR_VERSION_STRING "3.1.0-p6" ++#define MPFR_VERSION_STRING "3.1.0-p7" + + /* Macros dealing with MPFR VERSION */ + #define MPFR_VERSION_NUM(a,b,c) (((a) << 16L) | ((b) << 8) | (c)) +diff -Naurd mpfr-3.1.0-a/src/mul.c mpfr-3.1.0-b/src/mul.c +--- mpfr-3.1.0-a/src/mul.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/mul.c 2012-03-08 15:17:03.000000000 +0000 +@@ -93,15 +93,15 @@ + + ax = MPFR_GET_EXP (b) + MPFR_GET_EXP (c); + +- bq = MPFR_PREC(b); +- cq = MPFR_PREC(c); ++ bq = MPFR_PREC (b); ++ cq = MPFR_PREC (c); + +- MPFR_ASSERTD(bq+cq > bq); /* PREC_MAX is /2 so no integer overflow */ ++ MPFR_ASSERTN ((mpfr_uprec_t) bq + cq <= MPFR_PREC_MAX); + +- bn = (bq+GMP_NUMB_BITS-1)/GMP_NUMB_BITS; /* number of limbs of b */ +- cn = (cq+GMP_NUMB_BITS-1)/GMP_NUMB_BITS; /* number of limbs of c */ ++ bn = MPFR_PREC2LIMBS (bq); /* number of limbs of b */ ++ cn = MPFR_PREC2LIMBS (cq); /* number of limbs of c */ + k = bn + cn; /* effective nb of limbs used by b*c (= tn or tn+1) below */ +- tn = (bq + cq + GMP_NUMB_BITS - 1) / GMP_NUMB_BITS; ++ tn = MPFR_PREC2LIMBS (bq + cq); + /* <= k, thus no int overflow */ + MPFR_ASSERTD(tn <= k); + +@@ -292,12 +292,12 @@ + bq = MPFR_PREC (b); + cq = MPFR_PREC (c); + +- MPFR_ASSERTD (bq+cq > bq); /* PREC_MAX is /2 so no integer overflow */ ++ MPFR_ASSERTN ((mpfr_uprec_t) bq + cq <= MPFR_PREC_MAX); + +- bn = (bq+GMP_NUMB_BITS-1)/GMP_NUMB_BITS; /* number of limbs of b */ +- cn = (cq+GMP_NUMB_BITS-1)/GMP_NUMB_BITS; /* number of limbs of c */ ++ bn = MPFR_PREC2LIMBS (bq); /* number of limbs of b */ ++ cn = MPFR_PREC2LIMBS (cq); /* number of limbs of c */ + k = bn + cn; /* effective nb of limbs used by b*c (= tn or tn+1) below */ +- tn = (bq + cq + GMP_NUMB_BITS - 1) / GMP_NUMB_BITS; ++ tn = MPFR_PREC2LIMBS (bq + cq); + MPFR_ASSERTD (tn <= k); /* tn <= k, thus no int overflow */ + + /* Check for no size_t overflow*/ +diff -Naurd mpfr-3.1.0-a/src/pow.c mpfr-3.1.0-b/src/pow.c +--- mpfr-3.1.0-a/src/pow.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/pow.c 2012-03-08 15:17:03.000000000 +0000 +@@ -136,7 +136,7 @@ + (b) all the 'z' bits are zero + */ + +- prec = ((prec - 1) / GMP_NUMB_BITS + 1) * GMP_NUMB_BITS - expo; ++ prec = MPFR_PREC2LIMBS (prec) * GMP_NUMB_BITS - expo; + /* number of z+0 bits */ + + yn = prec / GMP_NUMB_BITS; +diff -Naurd mpfr-3.1.0-a/src/print_raw.c mpfr-3.1.0-b/src/print_raw.c +--- mpfr-3.1.0-a/src/print_raw.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/print_raw.c 2012-03-08 15:17:03.000000000 +0000 +@@ -84,7 +84,7 @@ + int i; + mpfr_prec_t count = 0; + char c; +- mp_size_t n = (r - 1) / GMP_NUMB_BITS + 1; ++ mp_size_t n = MPFR_PREC2LIMBS (r); + + printf("%s ", str); + for(n-- ; n>=0 ; n--) +@@ -109,7 +109,7 @@ + int i; + mpfr_prec_t count = 0; + char c; +- mp_size_t n = (r - 1) / GMP_NUMB_BITS + 1; ++ mp_size_t n = MPFR_PREC2LIMBS (r); + + for(n-- ; n>=0 ; n--) + { +diff -Naurd mpfr-3.1.0-a/src/round_prec.c mpfr-3.1.0-b/src/round_prec.c +--- mpfr-3.1.0-a/src/round_prec.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/round_prec.c 2012-03-08 15:17:03.000000000 +0000 +@@ -55,12 +55,12 @@ + + MPFR_ASSERTN(prec >= MPFR_PREC_MIN && prec <= MPFR_PREC_MAX); + +- nw = 1 + (prec - 1) / GMP_NUMB_BITS; /* needed allocated limbs */ ++ nw = MPFR_PREC2LIMBS (prec); /* needed allocated limbs */ + + /* check if x has enough allocated space for the significand */ + /* Get the number of limbs from the precision. + (Compatible with all allocation methods) */ +- ow = (MPFR_PREC (x) + GMP_NUMB_BITS - 1) / GMP_NUMB_BITS; ++ ow = MPFR_LIMB_SIZE (x); + if (nw > ow) + { + /* FIXME: Variable can't be created using custom allocation, +diff -Naurd mpfr-3.1.0-a/src/round_raw_generic.c mpfr-3.1.0-b/src/round_raw_generic.c +--- mpfr-3.1.0-a/src/round_raw_generic.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/round_raw_generic.c 2012-03-08 15:17:03.000000000 +0000 +@@ -80,7 +80,7 @@ + (xprec <= yprec || MPFR_IS_LIKE_RNDZ (rnd_mode, neg))) + return 0; + +- xsize = (xprec-1)/GMP_NUMB_BITS + 1; ++ xsize = MPFR_PREC2LIMBS (xprec); + nw = yprec / GMP_NUMB_BITS; + rw = yprec & (GMP_NUMB_BITS - 1); + +diff -Naurd mpfr-3.1.0-a/src/set.c mpfr-3.1.0-b/src/set.c +--- mpfr-3.1.0-a/src/set.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/set.c 2012-03-08 15:17:03.000000000 +0000 +@@ -48,8 +48,7 @@ + /* Same precision and b is not singular: + * just copy the mantissa, and set the exponent and the sign + * The result is exact. */ +- MPN_COPY (MPFR_MANT (a), MPFR_MANT (b), +- (MPFR_PREC (b) + GMP_NUMB_BITS-1)/GMP_NUMB_BITS); ++ MPN_COPY (MPFR_MANT (a), MPFR_MANT (b), MPFR_LIMB_SIZE (b)); + MPFR_RET (0); + } + else +diff -Naurd mpfr-3.1.0-a/src/set_f.c mpfr-3.1.0-b/src/set_f.c +--- mpfr-3.1.0-a/src/set_f.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/set_f.c 2012-03-08 15:17:03.000000000 +0000 +@@ -43,7 +43,7 @@ + if (SIZ(x) * MPFR_FROM_SIGN_TO_INT(MPFR_SIGN(y)) < 0) + MPFR_CHANGE_SIGN (y); + +- sy = 1 + (MPFR_PREC(y) - 1) / GMP_NUMB_BITS; ++ sy = MPFR_LIMB_SIZE (y); + my = MPFR_MANT(y); + mx = PTR(x); + +diff -Naurd mpfr-3.1.0-a/src/set_prec.c mpfr-3.1.0-b/src/set_prec.c +--- mpfr-3.1.0-a/src/set_prec.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/set_prec.c 2012-03-08 15:17:03.000000000 +0000 +@@ -32,7 +32,7 @@ + MPFR_ASSERTN (p >= MPFR_PREC_MIN && p <= MPFR_PREC_MAX); + + /* Calculate the new number of limbs */ +- xsize = (p - 1) / GMP_NUMB_BITS + 1; ++ xsize = MPFR_PREC2LIMBS (p); + + /* Realloc only if the new size is greater than the old */ + xoldsize = MPFR_GET_ALLOC_SIZE (x); +diff -Naurd mpfr-3.1.0-a/src/setmax.c mpfr-3.1.0-b/src/setmax.c +--- mpfr-3.1.0-a/src/setmax.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/setmax.c 2012-03-08 15:17:03.000000000 +0000 +@@ -32,7 +32,7 @@ + mp_limb_t *xp; + + MPFR_SET_EXP (x, e); +- xn = 1 + (MPFR_PREC(x) - 1) / GMP_NUMB_BITS; ++ xn = MPFR_LIMB_SIZE (x); + sh = (mpfr_prec_t) xn * GMP_NUMB_BITS - MPFR_PREC(x); + xp = MPFR_MANT(x); + xp[0] = MP_LIMB_T_MAX << sh; +diff -Naurd mpfr-3.1.0-a/src/sqr.c mpfr-3.1.0-b/src/sqr.c +--- mpfr-3.1.0-a/src/sqr.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/sqr.c 2012-03-08 15:17:03.000000000 +0000 +@@ -56,11 +56,11 @@ + ax = 2 * MPFR_GET_EXP (b); + bq = MPFR_PREC(b); + +- MPFR_ASSERTD (2 * bq > bq); /* PREC_MAX is /2 so no integer overflow */ ++ MPFR_ASSERTN (2 * (mpfr_uprec_t) bq <= MPFR_PREC_MAX); + +- bn = MPFR_LIMB_SIZE(b); /* number of limbs of b */ +- tn = 1 + (2 * bq - 1) / GMP_NUMB_BITS; /* number of limbs of square, +- 2*bn or 2*bn-1 */ ++ bn = MPFR_LIMB_SIZE (b); /* number of limbs of b */ ++ tn = MPFR_PREC2LIMBS (2 * bq); /* number of limbs of square, ++ 2*bn or 2*bn-1 */ + + if (MPFR_UNLIKELY(bn > MPFR_SQR_THRESHOLD)) + return mpfr_mul (a, b, b, rnd_mode); +diff -Naurd mpfr-3.1.0-a/src/stack_interface.c mpfr-3.1.0-b/src/stack_interface.c +--- mpfr-3.1.0-a/src/stack_interface.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/stack_interface.c 2012-03-08 15:17:03.000000000 +0000 +@@ -26,7 +26,7 @@ + size_t + mpfr_custom_get_size (mpfr_prec_t prec) + { +- return (prec + GMP_NUMB_BITS -1) / GMP_NUMB_BITS * BYTES_PER_MP_LIMB; ++ return MPFR_PREC2LIMBS (prec) * BYTES_PER_MP_LIMB; + } + + #undef mpfr_custom_init +diff -Naurd mpfr-3.1.0-a/src/strtofr.c mpfr-3.1.0-b/src/strtofr.c +--- mpfr-3.1.0-a/src/strtofr.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/strtofr.c 2012-03-08 15:17:03.000000000 +0000 +@@ -467,7 +467,7 @@ + /* Set y to the value of the ~prec most significant bits of pstr->mant + (as long as we guarantee correct rounding, we don't need to get + exactly prec bits). */ +- ysize = (prec - 1) / GMP_NUMB_BITS + 1; ++ ysize = MPFR_PREC2LIMBS (prec); + /* prec bits corresponds to ysize limbs */ + ysize_bits = ysize * GMP_NUMB_BITS; + /* and to ysize_bits >= prec > MPFR_PREC (x) bits */ +diff -Naurd mpfr-3.1.0-a/src/sub1sp.c mpfr-3.1.0-b/src/sub1sp.c +--- mpfr-3.1.0-a/src/sub1sp.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/sub1sp.c 2012-03-08 15:17:03.000000000 +0000 +@@ -155,8 +155,8 @@ + MPFR_ASSERTD(MPFR_IS_PURE_FP(c)); + + /* Read prec and num of limbs */ +- p = MPFR_PREC(b); +- n = (p-1)/GMP_NUMB_BITS+1; ++ p = MPFR_PREC (b); ++ n = MPFR_PREC2LIMBS (p); + + /* Fast cmp of |b| and |c|*/ + bx = MPFR_GET_EXP (b); +diff -Naurd mpfr-3.1.0-a/src/urandomb.c mpfr-3.1.0-b/src/urandomb.c +--- mpfr-3.1.0-a/src/urandomb.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/urandomb.c 2012-03-08 15:17:03.000000000 +0000 +@@ -31,13 +31,20 @@ + a sufficient number of limbs */ + void + mpfr_rand_raw (mpfr_limb_ptr mp, gmp_randstate_t rstate, +- unsigned long int nbits) ++ mpfr_prec_t nbits) + { + mpz_t z; + ++ MPFR_ASSERTN (nbits >= 1); + /* To be sure to avoid the potential allocation of mpz_urandomb */ +- ALLOC(z) = SIZ(z) = ((nbits - 1) / GMP_NUMB_BITS) + 1; ++ ALLOC(z) = SIZ(z) = MPFR_PREC2LIMBS (nbits); + PTR(z) = mp; ++#if __MPFR_GMP(5,0,0) ++ /* Check for integer overflow (unless mp_bitcnt_t is signed, ++ but according to the GMP manual, this shouldn't happen). ++ Note: mp_bitcnt_t has been introduced in GMP 5.0.0. */ ++ MPFR_ASSERTN ((mp_bitcnt_t) -1 < 0 || nbits <= (mp_bitcnt_t) -1); ++#endif + mpz_urandomb (z, rstate, nbits); + } + +diff -Naurd mpfr-3.1.0-a/src/version.c mpfr-3.1.0-b/src/version.c +--- mpfr-3.1.0-a/src/version.c 2012-02-24 13:50:05.000000000 +0000 ++++ mpfr-3.1.0-b/src/version.c 2012-03-08 15:17:03.000000000 +0000 +@@ -25,5 +25,5 @@ + const char * + mpfr_get_version (void) + { +- return "3.1.0-p6"; ++ return "3.1.0-p7"; + } +diff -Naurd mpfr-3.1.0-a/tests/tinits.c mpfr-3.1.0-b/tests/tinits.c +--- mpfr-3.1.0-a/tests/tinits.c 2011-10-03 08:17:14.000000000 +0000 ++++ mpfr-3.1.0-b/tests/tinits.c 2012-03-08 15:17:03.000000000 +0000 +@@ -1,4 +1,4 @@ +-/* Test file for mpfr_inits, mpfr_inits2 and mpfr_clears. ++/* Test file for mpfr_init2, mpfr_inits, mpfr_inits2 and mpfr_clears. + + Copyright 2003, 2006, 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc. + Contributed by the Arenaire and Caramel projects, INRIA. +@@ -20,18 +20,43 @@ + http://www.gnu.org/licenses/ or write to the Free Software Foundation, Inc., + 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. */ + ++#include ++ + #include "mpfr-test.h" + + int + main (void) + { + mpfr_t a, b, c; ++ long large_prec; + + tests_start_mpfr (); ++ + mpfr_inits (a, b, c, (mpfr_ptr) 0); + mpfr_clears (a, b, c, (mpfr_ptr) 0); + mpfr_inits2 (200, a, b, c, (mpfr_ptr) 0); + mpfr_clears (a, b, c, (mpfr_ptr) 0); ++ ++ /* test for precision 2^31-1, see ++ https://gforge.inria.fr/tracker/index.php?func=detail&aid=13918 */ ++ large_prec = 2147483647; ++ if (getenv ("MPFR_CHECK_LARGEMEM") != NULL) ++ { ++ /* We assume that the precision won't be increased internally. */ ++ if (large_prec > MPFR_PREC_MAX) ++ large_prec = MPFR_PREC_MAX; ++ mpfr_inits2 (large_prec, a, b, (mpfr_ptr) 0); ++ mpfr_set_ui (a, 17, MPFR_RNDN); ++ mpfr_set (b, a, MPFR_RNDN); ++ if (mpfr_get_ui (a, MPFR_RNDN) != 17) ++ { ++ printf ("Error in mpfr_init2 with precision 2^31-1\n"); ++ exit (1); ++ } ++ mpfr_clears (a, b, (mpfr_ptr) 0); ++ } ++ + tests_end_mpfr (); ++ + return 0; + } +diff -Naurd mpfr-3.1.0-a/PATCHES mpfr-3.1.0-b/PATCHES +--- mpfr-3.1.0-a/PATCHES 2012-03-12 11:59:47.000000000 +0000 ++++ mpfr-3.1.0-b/PATCHES 2012-03-12 11:59:47.000000000 +0000 +@@ -0,0 +1 @@ ++__gmp_const +diff -Naurd mpfr-3.1.0-a/VERSION mpfr-3.1.0-b/VERSION +--- mpfr-3.1.0-a/VERSION 2012-03-08 15:17:03.000000000 +0000 ++++ mpfr-3.1.0-b/VERSION 2012-03-12 11:59:47.000000000 +0000 +@@ -1 +1 @@ +-3.1.0-p7 ++3.1.0-p8 +diff -Naurd mpfr-3.1.0-a/src/mpfr.h mpfr-3.1.0-b/src/mpfr.h +--- mpfr-3.1.0-a/src/mpfr.h 2012-03-08 15:17:03.000000000 +0000 ++++ mpfr-3.1.0-b/src/mpfr.h 2012-03-12 11:59:47.000000000 +0000 +@@ -27,7 +27,7 @@ + #define MPFR_VERSION_MAJOR 3 + #define MPFR_VERSION_MINOR 1 + #define MPFR_VERSION_PATCHLEVEL 0 +-#define MPFR_VERSION_STRING "3.1.0-p7" ++#define MPFR_VERSION_STRING "3.1.0-p8" + + /* Macros dealing with MPFR VERSION */ + #define MPFR_VERSION_NUM(a,b,c) (((a) << 16L) | ((b) << 8) | (c)) +@@ -39,6 +39,18 @@ + # include + #endif + ++/* GMP's internal __gmp_const macro has been removed on 2012-03-04: ++ http://gmplib.org:8000/gmp/rev/d287cfaf6732 ++ const is standard and now assumed to be available. If the __gmp_const ++ definition is no longer present in GMP, this probably means that GMP ++ assumes that const is available; thus let's define it to const. ++ Note: this is a temporary fix that can be backported to previous MPFR ++ versions. In the future, __gmp_const should be replaced by const like ++ in GMP. */ ++#ifndef __gmp_const ++# define __gmp_const const ++#endif ++ + /* Avoid some problems with macro expansion if the user defines macros + with the same name as keywords. By convention, identifiers and macro + names starting with mpfr_ are reserved by MPFR. */ +diff -Naurd mpfr-3.1.0-a/src/version.c mpfr-3.1.0-b/src/version.c +--- mpfr-3.1.0-a/src/version.c 2012-03-08 15:17:03.000000000 +0000 ++++ mpfr-3.1.0-b/src/version.c 2012-03-12 11:59:47.000000000 +0000 +@@ -25,5 +25,5 @@ + const char * + mpfr_get_version (void) + { +- return "3.1.0-p7"; ++ return "3.1.0-p8"; + } +diff -Naurd mpfr-3.1.0-a/PATCHES mpfr-3.1.0-b/PATCHES +--- mpfr-3.1.0-a/PATCHES 2012-04-27 01:13:15.000000000 +0000 ++++ mpfr-3.1.0-b/PATCHES 2012-04-27 01:13:15.000000000 +0000 +@@ -0,0 +1 @@ ++gamma-underflow +diff -Naurd mpfr-3.1.0-a/VERSION mpfr-3.1.0-b/VERSION +--- mpfr-3.1.0-a/VERSION 2012-03-12 11:59:47.000000000 +0000 ++++ mpfr-3.1.0-b/VERSION 2012-04-27 01:13:15.000000000 +0000 +@@ -1 +1 @@ +-3.1.0-p8 ++3.1.0-p9 +diff -Naurd mpfr-3.1.0-a/src/gamma.c mpfr-3.1.0-b/src/gamma.c +--- mpfr-3.1.0-a/src/gamma.c 2011-10-03 08:17:09.000000000 +0000 ++++ mpfr-3.1.0-b/src/gamma.c 2012-04-27 01:13:15.000000000 +0000 +@@ -296,7 +296,7 @@ + /* we want an upper bound for x * [log(2-x)-1]. + since x < 0, we need a lower bound on log(2-x) */ + mpfr_ui_sub (xp, 2, x, MPFR_RNDD); +- mpfr_log2 (xp, xp, MPFR_RNDD); ++ mpfr_log (xp, xp, MPFR_RNDD); + mpfr_sub_ui (xp, xp, 1, MPFR_RNDD); + mpfr_mul (xp, xp, x, MPFR_RNDU); + +diff -Naurd mpfr-3.1.0-a/src/mpfr.h mpfr-3.1.0-b/src/mpfr.h +--- mpfr-3.1.0-a/src/mpfr.h 2012-03-12 11:59:47.000000000 +0000 ++++ mpfr-3.1.0-b/src/mpfr.h 2012-04-27 01:13:15.000000000 +0000 +@@ -27,7 +27,7 @@ + #define MPFR_VERSION_MAJOR 3 + #define MPFR_VERSION_MINOR 1 + #define MPFR_VERSION_PATCHLEVEL 0 +-#define MPFR_VERSION_STRING "3.1.0-p8" ++#define MPFR_VERSION_STRING "3.1.0-p9" + + /* Macros dealing with MPFR VERSION */ + #define MPFR_VERSION_NUM(a,b,c) (((a) << 16L) | ((b) << 8) | (c)) +diff -Naurd mpfr-3.1.0-a/src/version.c mpfr-3.1.0-b/src/version.c +--- mpfr-3.1.0-a/src/version.c 2012-03-12 11:59:47.000000000 +0000 ++++ mpfr-3.1.0-b/src/version.c 2012-04-27 01:13:15.000000000 +0000 +@@ -25,5 +25,5 @@ + const char * + mpfr_get_version (void) + { +- return "3.1.0-p8"; ++ return "3.1.0-p9"; + } +diff -Naurd mpfr-3.1.0-a/tests/tgamma.c mpfr-3.1.0-b/tests/tgamma.c +--- mpfr-3.1.0-a/tests/tgamma.c 2011-10-03 08:17:14.000000000 +0000 ++++ mpfr-3.1.0-b/tests/tgamma.c 2012-04-27 01:13:15.000000000 +0000 +@@ -478,6 +478,36 @@ + mpfr_clear (x); + } + ++/* bug found by Giridhar Tammana */ ++static void ++test20120426 (void) ++{ ++ mpfr_t xa, xb; ++ int i; ++ mpfr_exp_t emin; ++ ++ mpfr_init2 (xa, 53); ++ mpfr_init2 (xb, 53); ++ mpfr_set_d (xb, -168.5, MPFR_RNDN); ++ emin = mpfr_get_emin (); ++ mpfr_set_emin (-1073); ++ i = mpfr_gamma (xa, xb, MPFR_RNDN); ++ i = mpfr_subnormalize (xa, i, MPFR_RNDN); /* new ternary value */ ++ mpfr_set_str (xb, "-9.5737343987585366746184749943e-304", 10, MPFR_RNDN); ++ if (!((i > 0) && (mpfr_cmp (xa, xb) == 0))) ++ { ++ printf ("Error in test20120426, i=%d\n", i); ++ printf ("expected "); ++ mpfr_print_binary (xb); putchar ('\n'); ++ printf ("got "); ++ mpfr_print_binary (xa); putchar ('\n'); ++ exit (1); ++ } ++ mpfr_set_emin (emin); ++ mpfr_clear (xa); ++ mpfr_clear (xb); ++} ++ + static void + exprange (void) + { +@@ -821,6 +851,7 @@ + gamma_integer (); + test20071231 (); + test20100709 (); ++ test20120426 (); + + data_check ("data/gamma", mpfr_gamma, "mpfr_gamma"); + +diff -Naurd mpfr-3.1.0-a/PATCHES mpfr-3.1.0-b/PATCHES +--- mpfr-3.1.0-a/PATCHES 2012-05-07 18:52:45.000000000 +0000 ++++ mpfr-3.1.0-b/PATCHES 2012-05-07 18:52:45.000000000 +0000 +@@ -0,0 +1 @@ ++gamma-overunderflow +diff -Naurd mpfr-3.1.0-a/VERSION mpfr-3.1.0-b/VERSION +--- mpfr-3.1.0-a/VERSION 2012-04-27 01:13:15.000000000 +0000 ++++ mpfr-3.1.0-b/VERSION 2012-05-07 18:52:45.000000000 +0000 +@@ -1 +1 @@ +-3.1.0-p9 ++3.1.0-p10 +diff -Naurd mpfr-3.1.0-a/src/gamma.c mpfr-3.1.0-b/src/gamma.c +--- mpfr-3.1.0-a/src/gamma.c 2012-04-27 01:13:15.000000000 +0000 ++++ mpfr-3.1.0-b/src/gamma.c 2012-05-07 18:52:45.000000000 +0000 +@@ -100,7 +100,8 @@ + mpfr_t xp, GammaTrial, tmp, tmp2; + mpz_t fact; + mpfr_prec_t realprec; +- int compared, inex, is_integer; ++ int compared, is_integer; ++ int inex = 0; /* 0 means: result gamma not set yet */ + MPFR_GROUP_DECL (group); + MPFR_SAVE_EXPO_DECL (expo); + MPFR_ZIV_DECL (loop); +@@ -377,6 +378,15 @@ + mpfr_mul (GammaTrial, tmp2, xp, MPFR_RNDN); /* Pi*(2-x), error (1+u)^2 */ + err_g = MPFR_GET_EXP(GammaTrial); + mpfr_sin (GammaTrial, GammaTrial, MPFR_RNDN); /* sin(Pi*(2-x)) */ ++ /* If tmp is +Inf, we compute exp(lngamma(x)). */ ++ if (mpfr_inf_p (tmp)) ++ { ++ inex = mpfr_explgamma (gamma, x, &expo, tmp, tmp2, rnd_mode); ++ if (inex) ++ goto end; ++ else ++ goto ziv_next; ++ } + err_g = err_g + 1 - MPFR_GET_EXP(GammaTrial); + /* let g0 the true value of Pi*(2-x), g the computed value. + We have g = g0 + h with |h| <= |(1+u^2)-1|*g. +@@ -411,11 +421,16 @@ + if (MPFR_LIKELY (MPFR_CAN_ROUND (GammaTrial, realprec - err_g, + MPFR_PREC(gamma), rnd_mode))) + break; ++ ++ ziv_next: + MPFR_ZIV_NEXT (loop, realprec); + } ++ ++ end: + MPFR_ZIV_FREE (loop); + +- inex = mpfr_set (gamma, GammaTrial, rnd_mode); ++ if (inex == 0) ++ inex = mpfr_set (gamma, GammaTrial, rnd_mode); + MPFR_GROUP_CLEAR (group); + mpz_clear (fact); + +diff -Naurd mpfr-3.1.0-a/src/lngamma.c mpfr-3.1.0-b/src/lngamma.c +--- mpfr-3.1.0-a/src/lngamma.c 2012-03-08 15:17:03.000000000 +0000 ++++ mpfr-3.1.0-b/src/lngamma.c 2012-05-07 18:52:45.000000000 +0000 +@@ -49,9 +49,72 @@ + mpfr_set_ui_2exp (s, 9, -1, MPFR_RNDN); /* 4.5 */ + } + +-#ifndef IS_GAMMA ++#ifdef IS_GAMMA ++ ++/* This function is called in case of intermediate overflow/underflow. ++ The s1 and s2 arguments are temporary MPFR numbers, having the ++ working precision. If the result could be determined, then the ++ flags are updated via pexpo, y is set to the result, and the ++ (non-zero) ternary value is returned. Otherwise 0 is returned ++ in order to perform the next Ziv iteration. */ + static int +-unit_bit (mpfr_srcptr (x)) ++mpfr_explgamma (mpfr_ptr y, mpfr_srcptr x, mpfr_save_expo_t *pexpo, ++ mpfr_ptr s1, mpfr_ptr s2, mpfr_rnd_t rnd) ++{ ++ mpfr_t t1, t2; ++ int inex1, inex2, sign; ++ MPFR_BLOCK_DECL (flags1); ++ MPFR_BLOCK_DECL (flags2); ++ MPFR_GROUP_DECL (group); ++ ++ MPFR_BLOCK (flags1, inex1 = mpfr_lgamma (s1, &sign, x, MPFR_RNDD)); ++ MPFR_ASSERTN (inex1 != 0); ++ /* s1 = RNDD(lngamma(x)), inexact */ ++ if (MPFR_UNLIKELY (MPFR_OVERFLOW (flags1))) ++ { ++ if (MPFR_SIGN (s1) > 0) ++ { ++ MPFR_SAVE_EXPO_UPDATE_FLAGS (*pexpo, MPFR_FLAGS_OVERFLOW); ++ return mpfr_overflow (y, rnd, sign); ++ } ++ else ++ { ++ MPFR_SAVE_EXPO_UPDATE_FLAGS (*pexpo, MPFR_FLAGS_UNDERFLOW); ++ return mpfr_underflow (y, rnd == MPFR_RNDN ? MPFR_RNDZ : rnd, sign); ++ } ++ } ++ ++ mpfr_set (s2, s1, MPFR_RNDN); /* exact */ ++ mpfr_nextabove (s2); /* v = RNDU(lngamma(z0)) */ ++ ++ if (sign < 0) ++ rnd = MPFR_INVERT_RND (rnd); /* since the result with be negated */ ++ MPFR_GROUP_INIT_2 (group, MPFR_PREC (y), t1, t2); ++ MPFR_BLOCK (flags1, inex1 = mpfr_exp (t1, s1, rnd)); ++ MPFR_BLOCK (flags2, inex2 = mpfr_exp (t2, s2, rnd)); ++ /* t1 is the rounding with mode 'rnd' of a lower bound on |Gamma(x)|, ++ t2 is the rounding with mode 'rnd' of an upper bound, thus if both ++ are equal, so is the wanted result. If t1 and t2 differ or the flags ++ differ, at some point of Ziv's loop they should agree. */ ++ if (mpfr_equal_p (t1, t2) && flags1 == flags2) ++ { ++ MPFR_ASSERTN ((inex1 > 0 && inex2 > 0) || (inex1 < 0 && inex2 < 0)); ++ mpfr_set4 (y, t1, MPFR_RNDN, sign); /* exact */ ++ if (sign < 0) ++ inex1 = - inex1; ++ MPFR_SAVE_EXPO_UPDATE_FLAGS (*pexpo, flags1); ++ } ++ else ++ inex1 = 0; /* couldn't determine the result */ ++ MPFR_GROUP_CLEAR (group); ++ ++ return inex1; ++} ++ ++#else ++ ++static int ++unit_bit (mpfr_srcptr x) + { + mpfr_exp_t expo; + mpfr_prec_t prec; +@@ -75,6 +138,7 @@ + + return (x0 >> (prec % GMP_NUMB_BITS)) & 1; + } ++ + #endif + + /* lngamma(x) = log(gamma(x)). +@@ -99,12 +163,14 @@ + mpfr_t s, t, u, v, z; + unsigned long m, k, maxm; + mpz_t *INITIALIZED(B); /* variable B declared as initialized */ +- int inexact, compared; ++ int compared; ++ int inexact = 0; /* 0 means: result y not set yet */ + mpfr_exp_t err_s, err_t; + unsigned long Bm = 0; /* number of allocated B[] */ + unsigned long oldBm; + double d; + MPFR_SAVE_EXPO_DECL (expo); ++ MPFR_ZIV_DECL (loop); + + compared = mpfr_cmp_ui (z0, 1); + +@@ -122,7 +188,7 @@ + if (MPFR_EXP(z0) <= - (mpfr_exp_t) MPFR_PREC(y)) + { + mpfr_t l, h, g; +- int ok, inex2; ++ int ok, inex1, inex2; + mpfr_prec_t prec = MPFR_PREC(y) + 14; + MPFR_ZIV_DECL (loop); + +@@ -157,14 +223,14 @@ + mpfr_sub (h, h, g, MPFR_RNDD); + mpfr_mul (g, z0, z0, MPFR_RNDU); + mpfr_add (h, h, g, MPFR_RNDU); +- inexact = mpfr_prec_round (l, MPFR_PREC(y), rnd); ++ inex1 = mpfr_prec_round (l, MPFR_PREC(y), rnd); + inex2 = mpfr_prec_round (h, MPFR_PREC(y), rnd); + /* Caution: we not only need l = h, but both inexact flags should + agree. Indeed, one of the inexact flags might be zero. In that + case if we assume lngamma(z0) cannot be exact, the other flag + should be correct. We are conservative here and request that both + inexact flags agree. */ +- ok = SAME_SIGN (inexact, inex2) && mpfr_cmp (l, h) == 0; ++ ok = SAME_SIGN (inex1, inex2) && mpfr_cmp (l, h) == 0; + if (ok) + mpfr_set (y, h, rnd); /* exact */ + mpfr_clear (l); +@@ -172,8 +238,9 @@ + mpfr_clear (g); + if (ok) + { ++ MPFR_ZIV_FREE (loop); + MPFR_SAVE_EXPO_FREE (expo); +- return mpfr_check_range (y, inexact, rnd); ++ return mpfr_check_range (y, inex1, rnd); + } + /* since we have log|gamma(x)| = - log|x| - gamma*x + O(x^2), + if x ~ 2^(-n), then we have a n-bit approximation, thus +@@ -205,9 +272,10 @@ + thus lngamma(x) = log(Pi*(x-1)/sin(Pi*(2-x))) - lngamma(2-x) */ + + w = precy + MPFR_INT_CEIL_LOG2 (precy); ++ w += MPFR_INT_CEIL_LOG2 (w) + 14; ++ MPFR_ZIV_INIT (loop, w); + while (1) + { +- w += MPFR_INT_CEIL_LOG2 (w) + 14; + MPFR_ASSERTD(w >= 3); + mpfr_set_prec (s, w); + mpfr_set_prec (t, w); +@@ -288,7 +356,9 @@ + + (rnd == MPFR_RNDN))) + goto end; + } ++ MPFR_ZIV_NEXT (loop, w); + } ++ MPFR_ZIV_FREE (loop); + } + + /* now z0 > 1 */ +@@ -298,10 +368,10 @@ + /* since k is O(w), the value of log(z0*...*(z0+k-1)) is about w*log(w), + so there is a cancellation of ~log(w) in the argument reconstruction */ + w = precy + MPFR_INT_CEIL_LOG2 (precy); +- +- do ++ w += MPFR_INT_CEIL_LOG2 (w) + 13; ++ MPFR_ZIV_INIT (loop, w); ++ while (1) + { +- w += MPFR_INT_CEIL_LOG2 (w) + 13; + MPFR_ASSERTD (w >= 3); + + /* argument reduction: we compute gamma(z0 + k), where the series +@@ -441,6 +511,15 @@ + #ifdef IS_GAMMA + err_s = MPFR_GET_EXP(s); + mpfr_exp (s, s, MPFR_RNDN); ++ /* If s is +Inf, we compute exp(lngamma(z0)). */ ++ if (mpfr_inf_p (s)) ++ { ++ inexact = mpfr_explgamma (y, z0, &expo, s, t, rnd); ++ if (inexact) ++ goto end0; ++ else ++ goto ziv_next; ++ } + /* before the exponential, we have s = s0 + h where + |h| <= (2m+48)*ulp(s), thus exp(s0) = exp(s) * exp(-h). + For |h| <= 1/4, we have |exp(h)-1| <= 1.2*|h| thus +@@ -480,16 +559,26 @@ + err_s = (err_t == err_s) ? 1 + err_s : ((err_t > err_s) ? err_t : err_s); + err_s += 1 - MPFR_GET_EXP(s); + #endif ++ if (MPFR_LIKELY (MPFR_CAN_ROUND (s, w - err_s, precy, rnd))) ++ break; ++#ifdef IS_GAMMA ++ ziv_next: ++#endif ++ MPFR_ZIV_NEXT (loop, w); + } +- while (MPFR_UNLIKELY (!MPFR_CAN_ROUND (s, w - err_s, precy, rnd))); + ++#ifdef IS_GAMMA ++ end0: ++#endif + oldBm = Bm; + while (Bm--) + mpz_clear (B[Bm]); + (*__gmp_free_func) (B, oldBm * sizeof (mpz_t)); + + end: +- inexact = mpfr_set (y, s, rnd); ++ if (inexact == 0) ++ inexact = mpfr_set (y, s, rnd); ++ MPFR_ZIV_FREE (loop); + + mpfr_clear (s); + mpfr_clear (t); +diff -Naurd mpfr-3.1.0-a/src/mpfr.h mpfr-3.1.0-b/src/mpfr.h +--- mpfr-3.1.0-a/src/mpfr.h 2012-04-27 01:13:15.000000000 +0000 ++++ mpfr-3.1.0-b/src/mpfr.h 2012-05-07 18:52:45.000000000 +0000 +@@ -27,7 +27,7 @@ + #define MPFR_VERSION_MAJOR 3 + #define MPFR_VERSION_MINOR 1 + #define MPFR_VERSION_PATCHLEVEL 0 +-#define MPFR_VERSION_STRING "3.1.0-p9" ++#define MPFR_VERSION_STRING "3.1.0-p10" + + /* Macros dealing with MPFR VERSION */ + #define MPFR_VERSION_NUM(a,b,c) (((a) << 16L) | ((b) << 8) | (c)) +diff -Naurd mpfr-3.1.0-a/src/version.c mpfr-3.1.0-b/src/version.c +--- mpfr-3.1.0-a/src/version.c 2012-04-27 01:13:15.000000000 +0000 ++++ mpfr-3.1.0-b/src/version.c 2012-05-07 18:52:45.000000000 +0000 +@@ -25,5 +25,5 @@ + const char * + mpfr_get_version (void) + { +- return "3.1.0-p9"; ++ return "3.1.0-p10"; + } +diff -Naurd mpfr-3.1.0-a/tests/tgamma.c mpfr-3.1.0-b/tests/tgamma.c +--- mpfr-3.1.0-a/tests/tgamma.c 2012-04-27 01:13:15.000000000 +0000 ++++ mpfr-3.1.0-b/tests/tgamma.c 2012-05-07 18:52:45.000000000 +0000 +@@ -838,6 +838,175 @@ + exit (1); + } + ++/* Test mpfr_gamma in precision p1 by comparing it with exp(lgamma(x)) ++ computing with a working precision p2. Assume that x is not an ++ integer <= 2. */ ++static void ++exp_lgamma (mpfr_t x, mpfr_prec_t p1, mpfr_prec_t p2) ++{ ++ mpfr_t yd, yu, zd, zu; ++ int inexd, inexu, sign; ++ int underflow = -1, overflow = -1; /* -1: we don't know */ ++ int got_underflow, got_overflow; ++ ++ if (mpfr_integer_p (x) && mpfr_cmp_si (x, 2) <= 0) ++ { ++ printf ("Warning! x is an integer <= 2 in exp_lgamma: "); ++ mpfr_out_str (stdout, 10, 0, x, MPFR_RNDN); putchar ('\n'); ++ return; ++ } ++ mpfr_inits2 (p2, yd, yu, (mpfr_ptr) 0); ++ inexd = mpfr_lgamma (yd, &sign, x, MPFR_RNDD); ++ mpfr_set (yu, yd, MPFR_RNDN); /* exact */ ++ if (inexd) ++ mpfr_nextabove (yu); ++ mpfr_clear_flags (); ++ mpfr_exp (yd, yd, MPFR_RNDD); ++ if (! mpfr_underflow_p ()) ++ underflow = 0; ++ if (mpfr_overflow_p ()) ++ overflow = 1; ++ mpfr_clear_flags (); ++ mpfr_exp (yu, yu, MPFR_RNDU); ++ if (mpfr_underflow_p ()) ++ underflow = 1; ++ if (! mpfr_overflow_p ()) ++ overflow = 0; ++ if (sign < 0) ++ { ++ mpfr_neg (yd, yd, MPFR_RNDN); /* exact */ ++ mpfr_neg (yu, yu, MPFR_RNDN); /* exact */ ++ mpfr_swap (yd, yu); ++ } ++ /* yd < Gamma(x) < yu (strict inequalities since x != 1 and x != 2) */ ++ mpfr_inits2 (p1, zd, zu, (mpfr_ptr) 0); ++ mpfr_clear_flags (); ++ inexd = mpfr_gamma (zd, x, MPFR_RNDD); /* zd <= Gamma(x) < yu */ ++ got_underflow = underflow == -1 ? -1 : !! mpfr_underflow_p (); ++ got_overflow = overflow == -1 ? -1 : !! mpfr_overflow_p (); ++ if (! mpfr_less_p (zd, yu) || inexd > 0 || ++ got_underflow != underflow || ++ got_overflow != overflow) ++ { ++ printf ("Error in exp_lgamma on x = "); ++ mpfr_out_str (stdout, 16, 0, x, MPFR_RNDN); putchar ('\n'); ++ printf ("yu = "); ++ mpfr_dump (yu); ++ printf ("zd = "); ++ mpfr_dump (zd); ++ printf ("got inexd = %d, expected <= 0\n", inexd); ++ printf ("got underflow = %d, expected %d\n", got_underflow, underflow); ++ printf ("got overflow = %d, expected %d\n", got_overflow, overflow); ++ exit (1); ++ } ++ mpfr_clear_flags (); ++ inexu = mpfr_gamma (zu, x, MPFR_RNDU); /* zu >= Gamma(x) > yd */ ++ got_underflow = underflow == -1 ? -1 : !! mpfr_underflow_p (); ++ got_overflow = overflow == -1 ? -1 : !! mpfr_overflow_p (); ++ if (! mpfr_greater_p (zu, yd) || inexu < 0 || ++ got_underflow != underflow || ++ got_overflow != overflow) ++ { ++ printf ("Error in exp_lgamma on x = "); ++ mpfr_out_str (stdout, 16, 0, x, MPFR_RNDN); putchar ('\n'); ++ printf ("yd = "); ++ mpfr_dump (yd); ++ printf ("zu = "); ++ mpfr_dump (zu); ++ printf ("got inexu = %d, expected >= 0\n", inexu); ++ printf ("got underflow = %d, expected %d\n", got_underflow, underflow); ++ printf ("got overflow = %d, expected %d\n", got_overflow, overflow); ++ exit (1); ++ } ++ if (mpfr_equal_p (zd, zu)) ++ { ++ if (inexd != 0 || inexu != 0) ++ { ++ printf ("Error in exp_lgamma on x = "); ++ mpfr_out_str (stdout, 16, 0, x, MPFR_RNDN); putchar ('\n'); ++ printf ("zd = zu, thus exact, but inexd = %d and inexu = %d\n", ++ inexd, inexu); ++ exit (1); ++ } ++ MPFR_ASSERTN (got_underflow == 0); ++ MPFR_ASSERTN (got_overflow == 0); ++ } ++ else if (inexd == 0 || inexu == 0) ++ { ++ printf ("Error in exp_lgamma on x = "); ++ mpfr_out_str (stdout, 16, 0, x, MPFR_RNDN); putchar ('\n'); ++ printf ("zd != zu, thus inexact, but inexd = %d and inexu = %d\n", ++ inexd, inexu); ++ exit (1); ++ } ++ mpfr_clears (yd, yu, zd, zu, (mpfr_ptr) 0); ++} ++ ++static void ++exp_lgamma_tests (void) ++{ ++ mpfr_t x; ++ mpfr_exp_t emin, emax; ++ int i; ++ ++ emin = mpfr_get_emin (); ++ emax = mpfr_get_emax (); ++ set_emin (MPFR_EMIN_MIN); ++ set_emax (MPFR_EMAX_MAX); ++ ++ mpfr_init2 (x, 96); ++ for (i = 3; i <= 8; i++) ++ { ++ mpfr_set_ui (x, i, MPFR_RNDN); ++ exp_lgamma (x, 53, 64); ++ mpfr_nextbelow (x); ++ exp_lgamma (x, 53, 64); ++ mpfr_nextabove (x); ++ mpfr_nextabove (x); ++ exp_lgamma (x, 53, 64); ++ } ++ mpfr_set_str (x, "1.7", 10, MPFR_RNDN); ++ exp_lgamma (x, 53, 64); ++ mpfr_set_str (x, "-4.6308260837372266e+07", 10, MPFR_RNDN); ++ exp_lgamma (x, 53, 64); ++ mpfr_set_str (x, "-90.6308260837372266e+15", 10, MPFR_RNDN); ++ exp_lgamma (x, 53, 64); ++ /* The following test gives a large positive result < +Inf */ ++ mpfr_set_str (x, "1.2b13fc45a92dea1@14", 16, MPFR_RNDN); ++ exp_lgamma (x, 53, 64); ++ /* Idem for a large negative result > -Inf */ ++ mpfr_set_str (x, "-1.2b13fc45a92de81@14", 16, MPFR_RNDN); ++ exp_lgamma (x, 53, 64); ++ /* The following two tests trigger an endless loop in r8186 ++ on 64-bit machines (64-bit exponent). The second one (due ++ to undetected overflow) is a direct consequence of the ++ first one, due to the call of Gamma(2-x) if x < 1. */ ++ mpfr_set_str (x, "1.2b13fc45a92dec8@14", 16, MPFR_RNDN); ++ exp_lgamma (x, 53, 64); ++ mpfr_set_str (x, "-1.2b13fc45a92dea8@14", 16, MPFR_RNDN); ++ exp_lgamma (x, 53, 64); ++ /* Similar tests (overflow threshold) for 32-bit machines. */ ++ mpfr_set_str (x, "2ab68d8.657542f855111c61", 16, MPFR_RNDN); ++ exp_lgamma (x, 12, 64); ++ mpfr_set_str (x, "-2ab68d6.657542f855111c61", 16, MPFR_RNDN); ++ exp_lgamma (x, 12, 64); ++ /* The following test is an overflow on 32-bit and 64-bit machines. ++ Revision r8189 fails on 64-bit machines as the flag is unset. */ ++ mpfr_set_str (x, "1.2b13fc45a92ded8@14", 16, MPFR_RNDN); ++ exp_lgamma (x, 53, 64); ++ /* On the following tests, with r8196, one gets an underflow on ++ 32-bit machines, while a normal result is expected (see FIXME ++ in gamma.c:382). */ ++ mpfr_set_str (x, "-2ab68d6.657542f855111c6104", 16, MPFR_RNDN); ++ exp_lgamma (x, 12, 64); /* failure on 32-bit machines */ ++ mpfr_set_str (x, "-12b13fc45a92deb.1c6c5bc964", 16, MPFR_RNDN); ++ exp_lgamma (x, 12, 64); /* failure on 64-bit machines */ ++ mpfr_clear (x); ++ ++ set_emin (emin); ++ set_emax (emax); ++} ++ + int + main (int argc, char *argv[]) + { +@@ -852,6 +1021,7 @@ + test20071231 (); + test20100709 (); + test20120426 (); ++ exp_lgamma_tests (); + + data_check ("data/gamma", mpfr_gamma, "mpfr_gamma"); + diff --git a/testing/mpfr/mpfr.install b/testing/mpfr/mpfr.install new file mode 100644 index 000000000..d6dd0475b --- /dev/null +++ b/testing/mpfr/mpfr.install @@ -0,0 +1,20 @@ +info_dir=usr/share/info +info_files=(mpfr.info) + +post_install() { + [ -x usr/bin/install-info ] || return 0 + for f in ${info_files[@]}; do + install-info ${info_dir}/$f.gz ${info_dir}/dir 2> /dev/null + done +} + +post_upgrade() { + post_install $1 +} + +pre_remove() { + [ -x usr/bin/install-info ] || return 0 + for f in ${info_files[@]}; do + install-info --delete ${info_dir}/$f.gz ${info_dir}/dir 2> /dev/null + done +} diff --git a/testing/php/PKGBUILD b/testing/php/PKGBUILD index b826a7cf8..5de077661 100644 --- a/testing/php/PKGBUILD +++ b/testing/php/PKGBUILD @@ -1,4 +1,4 @@ -# $Id: PKGBUILD 158342 2012-05-03 18:42:15Z pierre $ +# $Id: PKGBUILD 158742 2012-05-08 17:13:03Z pierre $ # Maintainer: Pierre Schmitz pkgbase=php @@ -21,7 +21,7 @@ pkgname=('php' 'php-sqlite' 'php-tidy' 'php-xsl') -pkgver=5.4.2 +pkgver=5.4.3 pkgrel=1 arch=('i686' 'x86_64') license=('PHP') @@ -33,7 +33,7 @@ makedepends=('apache' 'imap' 'postgresql-libs' 'libldap' 'postfix' 'libvpx' source=("http://www.php.net/distributions/${pkgbase}-${pkgver}.tar.bz2" 'php.ini.patch' 'apache.conf' 'rc.d.php-fpm' 'php-fpm.conf.in.patch' 'logrotate.d.php-fpm') -md5sums=('252a6546db3a26260b419a883c875615' +md5sums=('51f9488bf8682399b802c48656315cac' '0b0bc7a917fc592bdf11dcd3c5c255e9' 'dec2cbaad64e3abf4f0ec70e1de4e8e9' 'b01be5f816988fcee7e78225836e5e27' -- cgit v1.2.3-54-g00ecf From 2ced64d6aa5881fa575de1861c464c432deee26f Mon Sep 17 00:00:00 2001 From: root Date: Fri, 11 May 2012 00:03:00 +0000 Subject: Fri May 11 00:03:00 UTC 2012 --- community/bitcoin/PKGBUILD | 8 +-- community/cuda-sdk/PKGBUILD | 37 +++++++++++++ community/dos2unix/PKGBUILD | 5 +- community/luajit/PKGBUILD | 9 ++-- community/lxdm/PKGBUILD | 10 ++-- community/lxdm/greeter-session.patch | 13 +++++ community/minidlna/PKGBUILD | 5 +- community/mythplugins/PKGBUILD | 18 ++++--- community/mythplugins/mythplugins-mythweb.install | 4 ++ community/mythplugins/php54.patch | 35 ++++++++++++ community/php-geoip/PKGBUILD | 6 +-- community/php-memcache/PKGBUILD | 4 +- community/php-memcached/PKGBUILD | 4 +- community/pptpd/PKGBUILD | 11 ++-- community/pptpd/unrecognized-opt.patch | 13 +++++ community/qtcreator/PKGBUILD | 11 ++-- community/xdebug/PKGBUILD | 6 +-- core/glib2/PKGBUILD | 10 ++-- extra/ffmpeg/PKGBUILD | 6 +-- extra/graphviz/PKGBUILD | 4 +- extra/gtkhtml4/PKGBUILD | 11 ++-- .../fix-selection-behaviour-in-iframe.patch | 35 ++++++++++++ extra/kdebase-workspace/PKGBUILD | 12 +++-- extra/kdebase-workspace/fix-krunner-crash.patch | 13 +++++ extra/openconnect/PKGBUILD | 12 ++--- extra/php-apc/PKGBUILD | 4 +- extra/php-xcache/PKGBUILD | 40 ++++++++++++++ extra/php-xcache/xcache.ini | 3 ++ extra/php/PKGBUILD | 63 +++++++--------------- extra/php/php-fpm.conf.in.patch | 4 +- extra/php/php.ini.patch | 16 +++--- ...0001-Check-for-gio-to-avoid-linking-issue.patch | 29 ++++++++++ extra/telepathy-rakia/PKGBUILD | 18 ++++--- multilib/gcc-multilib/PKGBUILD | 12 ++--- multilib/lib32-glib2/PKGBUILD | 8 +-- 35 files changed, 356 insertions(+), 143 deletions(-) create mode 100644 community/cuda-sdk/PKGBUILD create mode 100644 community/lxdm/greeter-session.patch create mode 100644 community/mythplugins/mythplugins-mythweb.install create mode 100644 community/mythplugins/php54.patch create mode 100644 community/pptpd/unrecognized-opt.patch create mode 100644 extra/gtkhtml4/fix-selection-behaviour-in-iframe.patch create mode 100644 extra/kdebase-workspace/fix-krunner-crash.patch create mode 100644 extra/php-xcache/PKGBUILD create mode 100644 extra/php-xcache/xcache.ini create mode 100644 extra/telepathy-rakia/0001-Check-for-gio-to-avoid-linking-issue.patch diff --git a/community/bitcoin/PKGBUILD b/community/bitcoin/PKGBUILD index 260082f54..fc1930db8 100644 --- a/community/bitcoin/PKGBUILD +++ b/community/bitcoin/PKGBUILD @@ -1,11 +1,11 @@ -# $Id: PKGBUILD 70450 2012-05-07 11:38:52Z tredaelli $ +# $Id: PKGBUILD 70477 2012-05-09 10:21:50Z tredaelli $ # Maintainer: Timothy Redaelli # Contributor: shahid pkgbase=bitcoin pkgname=('bitcoin-daemon' 'bitcoin-qt') -pkgver=0.6.1 -_commit=dbb656f +pkgver=0.6.2 +_commit=06d764e pkgrel=1 arch=('i686' 'x86_64') url="http://www.bitcoin.org/" @@ -14,7 +14,7 @@ conflicts=('bitcoin' 'bitcoin-bin' 'bitcoin-git') replaces=('bitcoin' 'bitcoin-bin' 'bitcoin-git') license=('MIT') source=("$pkgbase-$pkgver.tar.gz::https://github.com/bitcoin/$pkgbase/tarball/v$pkgver") -sha256sums=('bc37bc3c91ff39754cee511047d9ff7e8f76e06ac35bb345bcb1c0935e2b2eee') +sha256sums=('03c72d7bcdec70cb88033abb785b50686880b95d4768e8586891a9728d498c5a') build() { cd "$srcdir/bitcoin-$pkgbase-$_commit" diff --git a/community/cuda-sdk/PKGBUILD b/community/cuda-sdk/PKGBUILD new file mode 100644 index 000000000..152b3add9 --- /dev/null +++ b/community/cuda-sdk/PKGBUILD @@ -0,0 +1,37 @@ +# Maintainer: Sven-Hendrik Haase +# Contributor: Thomas Jost +# Contributor: Carson Reynolds + +pkgname=cuda-sdk +pkgver=4.2.9 +pkgrel=1 +pkgdesc="NVIDIA's GPU programming sdk" +arch=('i686' 'x86_64') +url="http://www.nvidia.com/object/cuda_home.html" +license=('custom') +depends=('cuda-toolkit' 'nvidia' 'opencl-nvidia' 'freeglut' 'libxmu') +makedepends=('perl') +source=(http://developer.download.nvidia.com/compute/cuda/4_2/rel/sdk/gpucomputingsdk_${pkgver}_linux.run) +md5sums=('693d969aca8bb06a5a1d51ef5c3ca04b') + +build() { + cd "$srcdir" + + sh gpucomputingsdk_${pkgver}_linux.run --noexec --keep --nox11 --nochown --target sdk >/dev/null + cd sdk + + find . -name *.cu | xargs sed -i "1 i #undef _GLIBCXX_ATOMIC_BUILTINS" + find . -name *.cu | xargs sed -i "1 i #undef _GLIBCXX_USE_INT128" + + #find . -name 'Makefile*' -exec sed -i 's/^\tmake /\t$(MAKE) /g; s/^\t@make /\t@$(MAKE) /g' "{}" + + + # Sadly we need to install this first and compile afterwards, this is why we only have build() + install -dm755 "$pkgdir/opt/cuda-sdk" + ./install-sdk-linux.pl --prefix="$pkgdir/opt/cuda-sdk" --cudaprefix="/opt/cuda-toolkit" >/dev/null + + cd "$pkgdir/opt/cuda-sdk" + make CUDA_INSTALL_PATH=/opt/cuda-toolkit NO_MPI=1 + # simpleMPI sometimes causes segfaults when building... + + install -Dm755 "$pkgdir/opt/cuda-sdk/License.txt" "$pkgdir/usr/share/licenses/$pkgname/LICENSE" +} diff --git a/community/dos2unix/PKGBUILD b/community/dos2unix/PKGBUILD index e85d40e06..0a8bbf17f 100644 --- a/community/dos2unix/PKGBUILD +++ b/community/dos2unix/PKGBUILD @@ -1,9 +1,10 @@ +# $Id: PKGBUILD 70487 2012-05-09 15:02:28Z bpiotrowski $ # Maintainer: BartÅ‚omiej Piotrowski # Contributor: Renato Garcia # Contributor: Gerson E. Ruotolo pkgname=dos2unix -pkgver=5.3.3 +pkgver=6.0 pkgrel=1 pkgdesc='Text file format converter' arch=('i686' 'x86_64') @@ -13,7 +14,7 @@ depends=('glibc') makedepends=('perl') conflicts=('hd2u') source=("http://waterlan.home.xs4all.nl/${pkgname}/${pkgname}-${pkgver}.tar.gz") -md5sums=('f352d648b97197c8a786eccc832764d8') +md5sums=('2fc8d6ebe9f1a519b15ebe0850e9aabd') build() { cd "${srcdir}/${pkgname}-${pkgver}" diff --git a/community/luajit/PKGBUILD b/community/luajit/PKGBUILD index 8e1f0b122..7a9480d86 100644 --- a/community/luajit/PKGBUILD +++ b/community/luajit/PKGBUILD @@ -1,11 +1,11 @@ -# $Id: PKGBUILD 67115 2012-03-04 14:30:22Z bpiotrowski $ +# $Id: PKGBUILD 70509 2012-05-09 20:30:54Z bpiotrowski $ # Maintainer: Chris Brannon # Maintainer: BartÅ‚omiej Piotrowski # Contributor: Paulo Matias # Contributor: Anders Bergh pkgname=luajit -pkgver=2.0.0b9 +pkgver=2.0.0b10 pkgrel=1 pkgdesc="A Just-In-Time Compiler for Lua" arch=('i686' 'x86_64') @@ -13,18 +13,15 @@ url="http://luajit.org/" license=('MIT') depends=('gcc-libs') source=("http://luajit.org/download/LuaJIT-${pkgver/b/-beta}.tar.gz" - "http://luajit.org/download/beta${pkgver: -1}_hotfix1.patch" 'luaconf.patch' 'Makefile.patch') -md5sums=('e7e03e67e2550817358bc28b44270c6d' - '4920f04fcef1ce486891509faf26b4f1' +md5sums=('ed66689b96f7ad7bfeffe0b4ff2d63d4' 'c8da9c6790e20a12a0e2496f438d9dc3' '8997c5e5fa4f6e8e0b86cc6b888de631') build() { cd "$srcdir/LuaJIT-${pkgver/b/-beta}" - patch -Np1 -i "$srcdir/beta${pkgver: -1}_hotfix1.patch" patch -Np0 -i "$srcdir/luaconf.patch" patch -Np0 -i "$srcdir/Makefile.patch" diff --git a/community/lxdm/PKGBUILD b/community/lxdm/PKGBUILD index 9613a4eb0..0b729267c 100644 --- a/community/lxdm/PKGBUILD +++ b/community/lxdm/PKGBUILD @@ -1,11 +1,11 @@ -# $Id: PKGBUILD 68758 2012-04-01 15:10:08Z bpiotrowski $ +# $Id: PKGBUILD 70485 2012-05-09 14:58:36Z bpiotrowski $ # Maintainer: BartÅ‚omiej Piotrowski # Contributor: AndyRTR # Contributor: kiefer pkgname=lxdm pkgver=0.4.1 -pkgrel=9 +pkgrel=10 pkgdesc="Lightweight Display Manager (part of LXDE)" arch=('i686' 'x86_64') url="http://sourceforge.net/projects/lxdm/" @@ -19,18 +19,22 @@ backup=('etc/lxdm/lxdm.conf' 'etc/pam.d/lxdm' 'etc/lxdm/Xsession' 'etc/lxdm/PostLogout' 'etc/lxdm/PreReboot' 'etc/lxdm/PreShutdown') source=(http://downloads.sourceforge.net/lxde/$pkgname-$pkgver.tar.gz glib2-2.32.0.patch lxdm.patch lxdm.conf.patch Xsession.patch - lxdm-daemon lxdm-pam) + greeter-session.patch lxdm-daemon lxdm-pam) md5sums=('8da1cfc2be6dc9217c85a7cf51e1e821' 'a1e3c46a8bef691bc544028f5b6cfe22' 'baed9055e8825a5511712bc095197519' 'c50dd01b715b0a236407d48066191601' 'd2e4a4a22ee2aa1a986be154c647b6c6' + '28475239d0c8b4fd778ec49f5ec72962' '705f394052fdd0dec22e95321d170de0' 'b20fe3c8487a039050986d60e45233a9') build() { cd $srcdir/$pkgname-$pkgver + patch -Np1 -i $srcdir/glib2-2.32.0.patch + patch -Np1 -i $srcdir/greeter-session.patch + ./configure --sysconfdir=/etc --prefix=/usr --libexecdir=/usr/lib/lxdm make diff --git a/community/lxdm/greeter-session.patch b/community/lxdm/greeter-session.patch new file mode 100644 index 000000000..f3b94a57a --- /dev/null +++ b/community/lxdm/greeter-session.patch @@ -0,0 +1,13 @@ +diff --git a/src/greeter.c b/src/greeter.c +index c0c150d..1f6b88e 100644 +--- a/src/greeter.c ++++ b/src/greeter.c +@@ -114,7 +114,7 @@ static char *get_session_exec(void) + GtkTreeModel* model; + GtkTreeIter it; + gchar *res; +- if(!lang) ++ if(!sessions) + return g_strdup(""); + + if(!gtk_combo_box_get_active_iter(GTK_COMBO_BOX(sessions), &it)) diff --git a/community/minidlna/PKGBUILD b/community/minidlna/PKGBUILD index 23441c568..d2a3c9ee6 100644 --- a/community/minidlna/PKGBUILD +++ b/community/minidlna/PKGBUILD @@ -1,4 +1,4 @@ -# $Id: PKGBUILD 70262 2012-05-03 10:11:50Z spupykin $ +# $Id: PKGBUILD 70495 2012-05-09 17:17:28Z spupykin $ # Maintainer: Sergej Pupykin # Maintainer:Biginoz < biginoz AT free point fr> # Contributor: Ignacio Galmarino @@ -7,7 +7,7 @@ pkgname=minidlna pkgver=1.0.24 -pkgrel=3 +pkgrel=4 pkgdesc="A DLNA/UPnP-AV Media server (aka ReadyDLNA)" arch=('i686' 'x86_64') url="http://sourceforge.net/projects/minidlna/" @@ -28,6 +28,7 @@ md5sums=('be9b4c91e3fcde592dc3f9828098ca0f' build() { cd "$srcdir/$pkgname-$pkgver" + sed -i 's|DB_PATH=.*|DB_PATH=/var/cache/minidlna|' genconfig.sh make } diff --git a/community/mythplugins/PKGBUILD b/community/mythplugins/PKGBUILD index 05e3c04f0..4b2f94a44 100644 --- a/community/mythplugins/PKGBUILD +++ b/community/mythplugins/PKGBUILD @@ -1,4 +1,4 @@ -# $Id: PKGBUILD 69346 2012-04-14 12:26:30Z jconder $ +# $Id: PKGBUILD 70479 2012-05-09 10:48:34Z jconder $ # Maintainer: Jonathan Conder # Contributor: Giovanni Scafora @@ -14,7 +14,7 @@ pkgname=('mythplugins-mytharchive' 'mythplugins-mythweb' 'mythplugins-mythzoneminder') pkgver=0.25 -pkgrel=2 +pkgrel=3 epoch=1 arch=('i686' 'x86_64') url="http://www.mythtv.org" @@ -25,14 +25,17 @@ makedepends=('cdrkit' 'dvdauthor' 'dvd+rw-tools' 'ffmpeg' 'flac' 'libexif' 'perl-soap-lite' 'perl-xml-sax' 'perl-xml-simple' 'perl-xml-xpath' 'python2-oauth' 'python-imaging' 'python-pycurl' 'taglib' 'zlib') source=("ftp://ftp.osuosl.org/pub/mythtv/$pkgbase-$pkgver.tar.bz2" + 'php54.patch' 'mtd.rc') md5sums=('b3f2768372a38e92ca94841519daa05e' + '7a114c1b5a84ab5ee190e63cc9514086' '476c12ba074794ad7f4ae092bdf949d6') build() { cd "$srcdir/$pkgbase-$pkgver" find . -name '*.py' -type f | xargs sed -i 's@^#!.*python$@#!/usr/bin/python2@' + patch -d 'mythweb' -Np0 -i "$srcdir/php54.patch" sed -re 's@/usr/local.*/usr/share@/usr/share@' -i 'mythweb/mythweb.php' sed -re 's@cstdio@cstdio>\n#include + + channel->name = '[ '.t('Any').' ]';" ++ ini_set('error_reporting', E_ERROR); ++ + $prev_group = ''; + $cur_group = ''; + foreach ($the_schedules as $schedule) { diff --git a/community/php-geoip/PKGBUILD b/community/php-geoip/PKGBUILD index 5291e1d37..febea43d7 100644 --- a/community/php-geoip/PKGBUILD +++ b/community/php-geoip/PKGBUILD @@ -1,9 +1,9 @@ -# $Id: PKGBUILD 57315 2011-10-25 17:20:28Z foutrelis $ +# $Id: PKGBUILD 70501 2012-05-09 18:48:05Z pschmitz $ # Maintainer: Evangelos Foutras pkgname=php-geoip pkgver=1.0.8 -pkgrel=1 +pkgrel=2 pkgdesc="GeoIP module for PHP" arch=('i686' 'x86_64') url="http://pecl.php.net/package/geoip" @@ -11,7 +11,7 @@ license=('PHP') depends=('php' 'geoip') backup=('etc/php/conf.d/geoip.ini') source=(http://pecl.php.net/get/geoip-$pkgver.tgz) -sha1sums=('f8d17da3e192002332ab54b9b4ab0f5deeaf9f15') +sha256sums=('08beeb2cbe9ab729d06b026795f5b9084aead6a1762493b0be53c4393d68d08a') build() { cd "$srcdir/geoip-$pkgver" diff --git a/community/php-memcache/PKGBUILD b/community/php-memcache/PKGBUILD index b553f283e..88f4cd109 100644 --- a/community/php-memcache/PKGBUILD +++ b/community/php-memcache/PKGBUILD @@ -1,9 +1,9 @@ -# $Id: PKGBUILD 64649 2012-02-17 13:33:44Z foutrelis $ +# $Id: PKGBUILD 70503 2012-05-09 18:48:11Z pschmitz $ # Maintainer: Evangelos Foutras pkgname=php-memcache pkgver=3.0.6 -pkgrel=2 +pkgrel=3 pkgdesc="Memcache module for PHP" arch=('i686' 'x86_64') url="http://pecl.php.net/package/memcache" diff --git a/community/php-memcached/PKGBUILD b/community/php-memcached/PKGBUILD index 791027d20..b1cfddffb 100644 --- a/community/php-memcached/PKGBUILD +++ b/community/php-memcached/PKGBUILD @@ -1,9 +1,9 @@ -# $Id: PKGBUILD 69284 2012-04-12 09:18:59Z foutrelis $ +# $Id: PKGBUILD 70505 2012-05-09 18:48:15Z pschmitz $ # Maintainer: Evangelos Foutras pkgname=php-memcached pkgver=2.0.1 -pkgrel=3 +pkgrel=4 pkgdesc="PHP extension for interfacing with memcached via libmemcached library" arch=('i686' 'x86_64') url="http://pecl.php.net/package/memcached" diff --git a/community/pptpd/PKGBUILD b/community/pptpd/PKGBUILD index 59faabd19..66203ba7b 100644 --- a/community/pptpd/PKGBUILD +++ b/community/pptpd/PKGBUILD @@ -1,9 +1,9 @@ -# $Id: PKGBUILD 70218 2012-05-02 13:03:21Z spupykin $ +# $Id: PKGBUILD 70497 2012-05-09 17:18:35Z spupykin $ # Maintainer: Sergej Pupykin pkgname=pptpd pkgver=1.3.4 -pkgrel=6 +pkgrel=7 pkgdesc="Poptop server" arch=(i686 x86_64) url="http://poptop.sourceforge.net/" @@ -11,12 +11,15 @@ license=('GPL') depends=(ppp glibc) backup=(etc/pptpd.conf) source=(http://downloads.sourceforge.net/sourceforge/poptop/pptpd-$pkgver.tar.gz - pptpd) + pptpd + unrecognized-opt.patch) md5sums=('b38df9c431041922c997c1148bedf591' - 'e09f81beb5d59a0fdfba94e3a60d992b') + 'e09f81beb5d59a0fdfba94e3a60d992b' + 'cfa02c86d0413eb94fac15599986f54c') build() { cd $srcdir/$pkgname-$pkgver + patch -p1 <$srcdir/unrecognized-opt.patch autoreconf -i ./configure --prefix=/usr --libdir=/usr/lib --exec-prefix=/usr --mandir=/usr/share make diff --git a/community/pptpd/unrecognized-opt.patch b/community/pptpd/unrecognized-opt.patch new file mode 100644 index 000000000..17ec49e52 --- /dev/null +++ b/community/pptpd/unrecognized-opt.patch @@ -0,0 +1,13 @@ +diff -wbBur pptpd-1.3.4/pptpctrl.c pptpd-1.3.4.my/pptpctrl.c +--- pptpd-1.3.4/pptpctrl.c 2006-12-08 03:01:40.000000000 +0300 ++++ pptpd-1.3.4.my/pptpctrl.c 2012-05-09 21:13:30.000000000 +0400 +@@ -759,8 +759,8 @@ + syslog(LOG_DEBUG, "CTRL (PPPD Launcher): remote address = %s", pppaddrs[1]); + } + +- if (*pppaddrs[0] || *pppaddrs[1]) { + char pppInterfaceIPs[33]; ++ if (*pppaddrs[0] || *pppaddrs[1]) { + sprintf(pppInterfaceIPs, "%s:%s", pppaddrs[0], pppaddrs[1]); + pppd_argv[an++] = pppInterfaceIPs; + } diff --git a/community/qtcreator/PKGBUILD b/community/qtcreator/PKGBUILD index ffe67ea13..8f72aa041 100644 --- a/community/qtcreator/PKGBUILD +++ b/community/qtcreator/PKGBUILD @@ -1,4 +1,4 @@ -# $Id: PKGBUILD 63396 2012-02-01 14:18:50Z svenstaro $ +# $Id: PKGBUILD 70483 2012-05-09 14:56:54Z svenstaro $ # Maintainer: Imanol Celaya # Maintainer: Sven-Hendrik Haase # Contributor: Lukas Jirkovsky @@ -7,8 +7,8 @@ # Contributor: delor pkgname="qtcreator" -pkgver=2.4.1 -_pkgver=2.4.1 +pkgver=2.5.0 +_pkgver=2.5.0 pkgrel=1 pkgdesc='Lightweight, cross-platform integrated development environment' arch=('i686' 'x86_64') @@ -23,11 +23,12 @@ optdepends=('qt-doc: for the integrated Qt documentation' 'openssh-askpass: for ssh support' 'git: for git support' 'mercurial: for mercurial support' - 'bzr: for bazaar support') + 'bzr: for bazaar support' + 'valgrind: for analyze support') install=qtcreator.install source=("http://get.qt.nokia.com/qtcreator/qt-creator-${_pkgver}-src.tar.gz" 'qtcreator.desktop') -md5sums=('e3a95b86df5ce9151b40cfbb2b8bbf3b' +md5sums=('31e26cdd1e3eeb8c406382ebe886dcc5' 'f1f4680b9838ff0b8f4cf11eb850d662') build() { diff --git a/community/xdebug/PKGBUILD b/community/xdebug/PKGBUILD index 1eab91ed8..1318e46f8 100644 --- a/community/xdebug/PKGBUILD +++ b/community/xdebug/PKGBUILD @@ -1,11 +1,11 @@ -# $Id: PKGBUILD 68086 2012-03-17 18:57:19Z spupykin $ +# $Id: PKGBUILD 70507 2012-05-09 18:48:25Z pschmitz $ # Maintainer: Sergej Pupykin # Maintainer: Jonathan Wiersma # Contributor: Jonathan Wiersma # Contributor: sracker pkgname=xdebug -pkgver=2.1.4 +pkgver=2.2.0 pkgrel=1 pkgdesc="PHP debugging extension" arch=('i686' 'x86_64') @@ -17,7 +17,7 @@ backup=('etc/php/conf.d/xdebug.ini') source=(http://www.xdebug.org/files/$pkgname-$pkgver.tgz xdebug-5.2.ini xdebug.ini) -md5sums=('0a1339ad8053eface15ed6420a295939' +md5sums=('27d8ad8224ffab04d12eecb5997a4f5d' '6b7fdbbe0bf381bda40e77e29981f439' '68de800943369d4c76bdf7eb35c8463b') diff --git a/core/glib2/PKGBUILD b/core/glib2/PKGBUILD index 210621610..7fbbe5623 100644 --- a/core/glib2/PKGBUILD +++ b/core/glib2/PKGBUILD @@ -1,9 +1,9 @@ -# $Id: PKGBUILD 157381 2012-04-28 09:25:44Z allan $ +# $Id: PKGBUILD 158759 2012-05-09 08:41:45Z ibiru $ # Maintainer: Jan de Groot pkgname=glib2 -pkgver=2.32.1 -pkgrel=3 +pkgver=2.32.2 +pkgrel=2 pkgdesc="Common C routines used by GTK+ and other libs" url="http://www.gtk.org/" arch=(i686 x86_64) @@ -16,7 +16,7 @@ source=(http://ftp.gnome.org/pub/GNOME/sources/glib/${pkgver%.*}/glib-$pkgver.ta glib2.sh glib2.csh revert-warn-glib-compile-schemas.patch) -sha256sums=('484d5b7fc09f3fa398355adaf74b369768f5859866c299f229c99721990f8398' +sha256sums=('b1764abf00bac96e0e93e29fb9715ce75f3583579acac40648e18771d43d6136' '9456872cdedcc639fb679448d74b85b0facf81033e27157d2861b991823b5a2a' '8d5626ffa361304ad3696493c0ef041d0ab10c857f6ef32116b3e2878ecf89e3' '049240975cd2f1c88fbe7deb28af14d4ec7d2640495f7ca8980d873bb710cc97') @@ -24,7 +24,7 @@ sha256sums=('484d5b7fc09f3fa398355adaf74b369768f5859866c299f229c99721990f8398' build() { cd glib-$pkgver patch -Rp1 -i "$srcdir/revert-warn-glib-compile-schemas.patch" - PYTHON=/usr/bin/python2 ./configure --prefix=/usr \ + PYTHON=/usr/bin/python2 ./configure --prefix=/usr --libdir=/usr/lib \ --sysconfdir=/etc \ --with-pcre=system \ --disable-fam diff --git a/extra/ffmpeg/PKGBUILD b/extra/ffmpeg/PKGBUILD index b3a701783..458bfa5e4 100644 --- a/extra/ffmpeg/PKGBUILD +++ b/extra/ffmpeg/PKGBUILD @@ -1,10 +1,10 @@ -# $Id: PKGBUILD 153659 2012-03-17 13:50:07Z ibiru $ +# $Id: PKGBUILD 158782 2012-05-09 17:58:43Z ibiru $ # Maintainer : Ionut Biru # Contributor: Tom Newsom # Contributor: Paul Mattal pkgname=ffmpeg -pkgver=20120317 +pkgver=20120509 pkgrel=1 pkgdesc="Complete and free Internet live audio and video broadcasting solution for Linux/Unix" arch=('i686' 'x86_64') @@ -14,7 +14,7 @@ depends=(alsa-lib bzip2 gsm lame libpulse libtheora libva libvorbis libvpx openc makedepends=('yasm' 'git' 'libvdpau') #git clone git://git.videolan.org/ffmpeg.git source=(ftp://ftp.archlinux.org/other/ffmpeg/$pkgname-$pkgver.tar.xz) -md5sums=('2a2ef83ae73713fcef6bba8c430665ce') +md5sums=('a35359e424608f369d380f03e4dc9966') build() { cd "$pkgname" diff --git a/extra/graphviz/PKGBUILD b/extra/graphviz/PKGBUILD index 3dfefeadc..f0640f068 100644 --- a/extra/graphviz/PKGBUILD +++ b/extra/graphviz/PKGBUILD @@ -1,11 +1,11 @@ -# $Id: PKGBUILD 150341 2012-02-17 03:33:20Z bisson $ +# $Id: PKGBUILD 158786 2012-05-09 18:48:24Z pierre $ # Maintainer: Gaetan Bisson # Contributor: kevin # Contributor: John Proctor pkgname=graphviz pkgver=2.28.0 -pkgrel=8 +pkgrel=9 pkgdesc='Graph visualization software' url='http://www.graphviz.org/' license=('custom:EPL') diff --git a/extra/gtkhtml4/PKGBUILD b/extra/gtkhtml4/PKGBUILD index 12c5d4e62..f917c0682 100644 --- a/extra/gtkhtml4/PKGBUILD +++ b/extra/gtkhtml4/PKGBUILD @@ -1,10 +1,10 @@ -# $Id: PKGBUILD 156876 2012-04-23 09:08:07Z ibiru $ +# $Id: PKGBUILD 158752 2012-05-09 07:43:11Z jgc $ # Maintainer: Ionut Biru pkgname=gtkhtml4 _pkgbasename=gtkhtml pkgver=4.4.1 -pkgrel=1 +pkgrel=2 pkgdesc="A lightweight HTML renderer/editor widget for GTK3" arch=(i686 x86_64) license=('GPL') @@ -12,11 +12,14 @@ depends=('gtk3' 'enchant' 'iso-codes' 'gnome-icon-theme' 'libsoup') makedepends=('intltool') url="http://www.gnome.org" options=('!libtool') -source=(http://ftp.gnome.org/pub/gnome/sources/$_pkgbasename/${pkgver%.*}/$_pkgbasename-$pkgver.tar.xz) -sha256sums=('2fb3286c5ab8b6349a694156f803e1162c5a234d30548eb0afdf82e139923236') +source=(http://ftp.gnome.org/pub/gnome/sources/$_pkgbasename/${pkgver%.*}/$_pkgbasename-$pkgver.tar.xz + fix-selection-behaviour-in-iframe.patch) +sha256sums=('2fb3286c5ab8b6349a694156f803e1162c5a234d30548eb0afdf82e139923236' + 'ed1d9a4515f9137aaa94511f421b610af04091c56573ff9b74ba104a2ca1b207') build() { cd "$_pkgbasename-$pkgver" + patch -Np1 -i "${srcdir}/fix-selection-behaviour-in-iframe.patch" ./configure --prefix=/usr --sysconfdir=/etc \ --libexecdir=/usr/lib/gtkhtml4 \ --localstatedir=/var --disable-static diff --git a/extra/gtkhtml4/fix-selection-behaviour-in-iframe.patch b/extra/gtkhtml4/fix-selection-behaviour-in-iframe.patch new file mode 100644 index 000000000..06bce4a0f --- /dev/null +++ b/extra/gtkhtml4/fix-selection-behaviour-in-iframe.patch @@ -0,0 +1,35 @@ +From 9ec36544203d4c1b98aa843c2c3ff0a4f725da68 Mon Sep 17 00:00:00 2001 +From: Sam Thursfield +Date: Thu, 03 May 2012 19:04:20 +0000 +Subject: Bug 672582 - Fix selection behavior inside