--- libunwind-0.99.orig/debian/shlibs.local
+++ libunwind-0.99/debian/shlibs.local
@@ -0,0 +1 @@
+libc	6.1	libc6.1 (>=2.3.2.ds1-8)
--- libunwind-0.99.orig/debian/libunwind-setjmp0.install
+++ libunwind-0.99/debian/libunwind-setjmp0.install
@@ -0,0 +1 @@
+debian/tmp/usr/lib/libunwind-setjmp.so.* usr/lib/
--- libunwind-0.99.orig/debian/libunwind7-dev.install
+++ libunwind-0.99/debian/libunwind7-dev.install
@@ -0,0 +1,5 @@
+debian/tmp/usr/include/* usr/include
+debian/tmp/usr/lib/libunwind-*.a usr/lib
+debian/tmp/usr/lib/libunwind-*.so usr/lib
+debian/tmp/usr/lib/libunwind.a usr/lib
+debian/tmp/usr/lib/libunwind.so usr/lib
--- libunwind-0.99.orig/debian/docs
+++ libunwind-0.99/debian/docs
@@ -0,0 +1,2 @@
+NEWS
+README
--- libunwind-0.99.orig/debian/libunwind7.install
+++ libunwind-0.99/debian/libunwind7.install
@@ -0,0 +1,2 @@
+debian/tmp/usr/lib/libunwind.so.* usr/lib
+debian/tmp/usr/lib/libunwind-*.so.* usr/lib
--- libunwind-0.99.orig/debian/rules
+++ libunwind-0.99/debian/rules
@@ -0,0 +1,133 @@
+#!/usr/bin/make -f
+# Sample debian/rules that uses debhelper.
+# GNU copyright 1997 to 1999 by Joey Hess.
+
+# Uncomment this to turn on verbose mode.
+#export DH_VERBOSE=1
+
+
+# These are used for cross-compiling and for saving the configure script
+# from having to guess our platform (since we know it already)
+DEB_HOST_GNU_TYPE   ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
+DEB_BUILD_GNU_TYPE  ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
+
+
+CFLAGS = -Wall -g
+
+ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
+	CFLAGS += -O0
+else
+	CFLAGS += -O2
+endif
+ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
+	INSTALL_PROGRAM += -s
+endif
+
+# shared library versions, option 1
+version=2.0.5
+major=2
+# option 2, assuming the library is created as src/.libs/libfoo.so.2.0.5 or so
+#version=`ls src/.libs/lib*.so.* | \
+# awk '{if (match($$0,/[0-9]+\.[0-9]+\.[0-9]+$$/)) print substr($$0,RSTART)}'`
+#major=`ls src/.libs/lib*.so.* | \
+# awk '{if (match($$0,/\.so\.[0-9]+$$/)) print substr($$0,RSTART+4)}'`
+
+config.status: configure
+	dh_testdir
+	# Add here commands to configure the package.
+	autoreconf --force --install --include=config
+	./configure --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) --prefix=/usr --mandir=\$${prefix}/share/man --infodir=\$${prefix}/share/info
+
+
+build: build-stamp
+build-stamp: patch config.status
+	dh_testdir
+
+	# Add here commands to compile the package.
+	$(MAKE)
+
+	touch build-stamp
+
+clean: clean1 unpatch
+clean1:
+	dh_testdir
+	dh_testroot
+	rm -f build-stamp 
+
+	# Add here commands to clean up after the build process.
+	[ ! -f Makefile ] || $(MAKE) distclean
+ifneq "$(wildcard /usr/share/misc/config.sub)" ""
+	cp -f /usr/share/misc/config.sub config.sub
+endif
+ifneq "$(wildcard /usr/share/misc/config.guess)" ""
+	cp -f /usr/share/misc/config.guess config.guess
+endif
+
+
+	dh_clean
+
+install: build
+	dh_testdir
+	dh_testroot
+	dh_clean -k
+	dh_installdirs
+
+	# Add here commands to install the package into debian/tmp
+	$(MAKE) install DESTDIR=$(CURDIR)/debian/tmp
+
+
+# Build architecture-independent files here.
+binary-indep: build install
+# We have nothing to do by default.
+
+# Build architecture-dependent files here.
+binary-arch: build install
+	dh_testdir
+	dh_testroot
+	dh_installchangelogs ChangeLog
+	dh_installdocs
+	dh_installexamples
+	dh_install
+	rm debian/libunwind7-dev/usr/lib/libunwind-setjmp.a
+	rm debian/libunwind7-dev/usr/lib/libunwind-setjmp.so
+	rm debian/libunwind7/usr/lib/libunwind-setjmp.so.*
+#	dh_installmenu
+#	dh_installdebconf	
+#	dh_installlogrotate
+#	dh_installemacsen
+#	dh_installpam
+#	dh_installmime
+#	dh_installinit
+#	dh_installcron
+#	dh_installinfo
+	dh_installman
+	rm debian/libunwind7-dev/usr/share/man/man3/libunwind-setjmp.*
+	dh_link
+	dh_strip
+	dh_compress
+	dh_fixperms
+#	dh_perl
+#	d_python
+	dh_makeshlibs
+	dh_installdeb
+	dh_shlibdeps -Llibunwind7
+	dh_gencontrol
+	dh_md5sums
+	dh_builddeb
+
+get-orig-source:
+	uscan --verbose --force-download --rename --repack --destdir=..
+
+patch: patch-stamp
+patch-stamp:
+	dpatch apply-all
+	dpatch cat-all >patch-stamp
+	touch patch-stamp
+
+unpatch:
+	dpatch deapply-all
+	rm -rf patch-stamp debian/patched
+
+binary: binary-indep binary-arch
+.PHONY: build clean binary-indep binary-arch binary install  get-orig-source \
+	patch unpatch clean1
--- libunwind-0.99.orig/debian/substvars
+++ libunwind-0.99/debian/substvars
@@ -0,0 +1 @@
+shlibs:Depends=libc6.1 (>=2.3.2.ds1-8)
--- libunwind-0.99.orig/debian/libunwind7.dirs
+++ libunwind-0.99/debian/libunwind7.dirs
@@ -0,0 +1,2 @@
+lib
+usr/lib
--- libunwind-0.99.orig/debian/libunwind-setjmp0-dev.manpages
+++ libunwind-0.99/debian/libunwind-setjmp0-dev.manpages
@@ -0,0 +1,2 @@
+debian/tmp/usr/share/man/man3/libunwind-setjmp.*
+
--- libunwind-0.99.orig/debian/dirs
+++ libunwind-0.99/debian/dirs
@@ -0,0 +1,3 @@
+usr/lib
+usr/share/man/man3
+usr/include
--- libunwind-0.99.orig/debian/libunwind-setjmp0.preinst
+++ libunwind-0.99/debian/libunwind-setjmp0.preinst
@@ -0,0 +1,7 @@
+#!/bin/sh
+set -e
+if [ install = "$1" ]; then
+	dpkg-divert --package libunwind-setjmp0 --add --rename --divert /usr/lib/libunwind-setjmp.so.0.0.0.old /usr/lib/libunwind-setjmp.so.0.0.0
+	dpkg-divert --package libunwind-setjmp0 --add --rename --divert /usr/lib/libunwind-setjmp.so.0.old /usr/lib/libunwind-setjmp.so.0
+fi
+#DEBHELPER#
--- libunwind-0.99.orig/debian/source.lintian-overrides
+++ libunwind-0.99/debian/source.lintian-overrides
@@ -0,0 +1,4 @@
+libunwind source: ancient-autotools-helper-file aux/config.sub 2002-03-07
+libunwind source: ancient-libtool aux/ltmain.sh 1.4.3
+libunwind source: ancient-autotools-helper-file aux/config.guess 2002-03-20
+
--- libunwind-0.99.orig/debian/libunwind7-dev.dirs
+++ libunwind-0.99/debian/libunwind7-dev.dirs
@@ -0,0 +1,3 @@
+usr/include
+usr/lib
+usr/share/man/man3
--- libunwind-0.99.orig/debian/libunwind-setjmp0.postrm
+++ libunwind-0.99/debian/libunwind-setjmp0.postrm
@@ -0,0 +1,7 @@
+#!/bin/sh
+set -e
+if [ remove = "$1" ]; then
+	dpkg-divert --package libunwind-setjmp0 --remove --rename --divert /usr/lib/libunwind-setjmp.so.0.0.0.old /usr/lib/libunwind-setjmp.so.0.0.0
+	dpkg-divert --package libunwind-setjmp0 --remove --rename --divert /usr/lib/libunwind-setjmp.so.0.old /usr/lib/libunwind-setjmp.so.0
+fi
+#DEBHELPER#
--- libunwind-0.99.orig/debian/copyright
+++ libunwind-0.99/debian/copyright
@@ -0,0 +1,27 @@
+This package was debianized by Matthieu Delahaye <matthieu@debian.org> on
+Tue, 01 Apr 2003 17:37:16 +0200.
+
+It was downloaded from http://www.hpl.hp.com/research/linux/libunwind/
+
+Upstream Author: David Mosberger <davidm@hpl.hp.com>
+
+Copyright (c) 2002 Hewlett-Packard Co.
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+"Software"), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
--- libunwind-0.99.orig/debian/compat
+++ libunwind-0.99/debian/compat
@@ -0,0 +1 @@
+4
--- libunwind-0.99.orig/debian/libunwind-setjmp0-dev.install
+++ libunwind-0.99/debian/libunwind-setjmp0-dev.install
@@ -0,0 +1,2 @@
+debian/tmp/usr/lib/libunwind-setjmp.so usr/lib
+debian/tmp/usr/lib/libunwind-setjmp.a usr/lib
--- libunwind-0.99.orig/debian/shlibs.libunwind7
+++ libunwind-0.99/debian/shlibs.libunwind7
@@ -0,0 +1 @@
+libc	6.1	libc6.1 (>= 2.3.2.ds1-8)
--- libunwind-0.99.orig/debian/libunwind7-dev.manpages
+++ libunwind-0.99/debian/libunwind7-dev.manpages
@@ -0,0 +1,24 @@
+debian/tmp/usr/share/man/man3/libunwind-*.*
+debian/tmp/usr/share/man/man3/libunwind.*
+debian/tmp/usr/share/man/man3/unw_destroy_addr_space.*
+debian/tmp/usr/share/man/man3/unw_flush_cache.*
+debian/tmp/usr/share/man/man3/unw_get_accessors.*
+debian/tmp/usr/share/man/man3/unw_get_fpreg.*
+debian/tmp/usr/share/man/man3/unw_get_proc_info.*
+debian/tmp/usr/share/man/man3/unw_get_proc_info_by_ip.*
+debian/tmp/usr/share/man/man3/unw_get_proc_name.*
+debian/tmp/usr/share/man/man3/unw_get_reg.*
+debian/tmp/usr/share/man/man3/unw_getcontext.*
+debian/tmp/usr/share/man/man3/unw_init_local.*
+debian/tmp/usr/share/man/man3/unw_init_remote.*
+debian/tmp/usr/share/man/man3/unw_is_fpreg.*
+debian/tmp/usr/share/man/man3/unw_is_signal_frame.*
+debian/tmp/usr/share/man/man3/unw_regname.*
+debian/tmp/usr/share/man/man3/unw_resume.*
+debian/tmp/usr/share/man/man3/unw_set_fpreg.*
+debian/tmp/usr/share/man/man3/unw_set_reg.*
+debian/tmp/usr/share/man/man3/unw_step.*
+debian/tmp/usr/share/man/man3/_U_dyn_cancel.*
+debian/tmp/usr/share/man/man3/_U_dyn_register.*
+debian/tmp/usr/share/man/man3/unw_create_addr_space.*
+debian/tmp/usr/share/man/man3/unw_set_caching_policy.*
--- libunwind-0.99.orig/debian/libunwind.ver
+++ libunwind-0.99/debian/libunwind.ver
@@ -0,0 +1,10 @@
+HIDDEN {
+  local:
+        __*;
+	_rest*;
+	_save*;
+};
+
+libunwind7 {
+	*;
+};
--- libunwind-0.99.orig/debian/control
+++ libunwind-0.99/debian/control
@@ -0,0 +1,65 @@
+Source: libunwind
+Priority: optional
+Section: libs
+Maintainer: Matthieu Delahaye <matthieu@debian.org>
+Uploaders: Al Stone <ahs3@debian.org>
+Build-Depends: debhelper (>> 4.0.0), libatomic-ops-dev (>> 0.5.1), dpatch, autoconf, automake, libtool
+Standards-Version: 3.6.1
+
+Package: libunwind7-dev
+Section: libdevel
+Architecture: ia64 i386 amd64 ppc64 powerpc
+Depends: libunwind7 (= ${binary:Version})
+Conflicts: libunwind1-dev
+Description: A library to determine the call-chain of a program - development
+ The primary goal of this project is to define a portable and efficient C
+ programming interface (API) to determine the call-chain of a program.
+ The API additionally provides the means to manipulate the preserved
+ (callee-saved) state of each call-frame and to resume execution at any
+ point in the call-chain (non-local goto). The API supports both local
+ (same-process) and remote (across-process) operation. As such, the API
+ is useful in a number of applications.
+ .
+ This package includes the development support files. 
+
+Package: libunwind7
+Section: libs
+Architecture: ia64 i386 amd64 ppc64 powerpc
+Depends: ${shlibs:Depends}
+Replaces: libgcc1 (<< 1:4.0.0-2)
+Description: A library to determine the call-chain of a program - runtime
+ The primary goal of this project is to define a portable and efficient C
+ programming interface (API) to determine the call-chain of a program.
+ The API additionally provides the means to manipulate the preserved
+ (callee-saved) state of each call-frame and to resume execution at any
+ point in the call-chain (non-local goto). The API supports both local
+ (same-process) and remote (across-process) operation. As such, the API
+ is useful in a number of applications.
+ .
+ This package includes the shared libraries
+
+Package: libunwind-setjmp0-dev
+Section: libdevel
+Architecture: ia64 i386 amd64 ppc64 powerpc
+Depends: libunwind7-dev (= ${binary:Version}), libunwind-setjmp0 (= ${binary:Version}) 
+Description: A libunwind-based non local goto - development
+ The unwind-setjmp library offers a libunwind-based implementation of
+ non-local gotos. This implementation is intended to be a drop-in
+ replacement for the normal, system-provided routines of the same name.
+ The main advantage of using the unwind-setjmp library is  that  setting
+ up a non-local goto via one of the setjmp() routines is very fast.
+ .
+ This package includes the development support files
+
+Package: libunwind-setjmp0
+Section: libs
+Architecture: ia64 i386 amd64 ppc64 powerpc
+Depends: ${shlibs:Depends}
+Description: A libunwind-based non local goto - runtime
+ The unwind-setjmp library offers a libunwind-based implementation of
+ non-local gotos. This implementation is intended to be a drop-in
+ replacement for the normal, system-provided routines of the same name.
+ The main advantage of using the unwind-setjmp library is  that  setting
+ up a non-local goto via one of the setjmp() routines is very fast.
+ .
+ This package includes the shared library 
--- libunwind-0.99.orig/debian/changelog
+++ libunwind-0.99/debian/changelog
@@ -0,0 +1,158 @@
+libunwind (0.99-0.3) unstable; urgency=low
+
+  * Non-maintainer upload.
+  * Don't ship .la files (Closes: #622440).
+  * Build for powerpc (Closes: #556909).
+
+ -- Luk Claes <luk@debian.org>  Sat, 25 Jun 2011 16:05:02 +0200
+
+libunwind (0.99-0.2) unstable; urgency=low
+
+  * Non-maintainer upload.
+  * debian/control: Fix "libunwind7 is not required on all archs but ia64"
+    The priority was erroneously set high. (Closes: #543346)
+  * i386 libraries are now provided. (Closes: #275639)
+  * debian/rules: use dpatch.
+  * debian/patches/090828-rpath.dpatch: fixed the rpath issue.
+
+ -- Daigo Moriwaki <daigo@debian.org>  Thu, 27 Aug 2009 23:58:37 +0900
+
+libunwind (0.99-0.1) unstable; urgency=low
+
+  [ Monty Taylor ]
+  * Non-maintainer upload. (Closes: #530885) 
+  * New upstream release (Closes: #487316)
+
+  [ Daigo Moriwaki ]
+  * debian/libunwind*.install: 
+    - libraries install into /usr/lib.
+    - regular packages contain shared libraries while -dev packages contain
+      static libraries.
+  * debian/control: libunwind7's section is now libs.
+
+ -- Daigo Moriwaki <daigo@debian.org>  Sun, 23 Aug 2009 10:37:50 +0900
+
+libunwind (0.98.5-8) unstable; urgency=low
+
+  * Set priority to package libunwind7 to required as libstdc++5 of
+    priority required depend on libunwind7. Close: bug#317375, bug#317374
+  * Do not force g++ version to 3.4
+
+ -- Matthieu Delahaye <matthieu@debian.org>  Fri, 15 Jul 2005 16:05:22 -0500
+
+libunwind (0.98.5-7) unstable; urgency=low
+
+  * Upload to unstable.
+
+ -- Matthias Klose <doko@debian.org>  Tue,  7 Jun 2005 12:33:57 +0000
+
+libunwind (0.98.5-6) experimental; urgency=low
+
+  * Fix libunwind7 shlibs version string.
+
+ -- Matthias Klose <doko@debian.org>  Wed,  4 May 2005 07:22:10 +0200
+
+libunwind (0.98.5-5) experimental; urgency=low
+
+  * Tighten libunwind7 shlibs version to 0.98.5-4 (the first version, which
+    includes libunwind.so.7.
+
+ -- Matthias Klose <doko@debian.org>  Wed,  4 May 2005 04:49:44 +0000
+
+libunwind (0.98.5-4) experimental; urgency=low
+
+  * Install the unwind library in the libunwind7 package, not libgcc1.
+
+ -- Matthias Klose <doko@debian.org>  Tue,  3 May 2005 14:50:20 +0000
+
+libunwind (0.98.5-1) unstable; urgency=low
+
+  * New upstream release - bug correction only:
+       - Fix an off-by-1 bug in the handling of the dynamic ALIAS directive.
+       - Fix a bug in libunwind-ptrace which could cause crash due to
+         extraneous munmap() calls.
+       - Fix a typo in the man-page of unw_create_addr_space()
+
+ -- Matthieu Delahaye <delahaym@debian.org>  Fri, 22 Apr 2005 11:12:14 -0500
+
+libunwind (0.98.4-1) unstable; urgency=low
+
+  * New upstream release
+
+ -- Matthieu Delahaye <matthieu@debian.org>  Thu, 24 Feb 2005 16:12:19 -0600
+
+libunwind (0.98.3-3) unstable; urgency=high
+
+  * Tighten dependency on libgcc1.
+
+ -- Matthias Klose <doko@debian.org>  Thu, 16 Dec 2004 15:36:15 -0800
+
+libunwind (0.98.3-2) unstable; urgency=low
+
+  * Depend on libgcc1, for the sarge release, libunwind.so.7 is built
+    by the gcc-3.4 source package.
+
+ -- Matthias Klose <doko@debian.org>  Fri, 26 Nov 2004 00:48:43 +0100
+
+libunwind (0.98.3-1) unstable; urgency=low
+
+  * New upstream release
+
+ -- Matthieu Delahaye <matthieu@debian.org>  Tue, 16 Nov 2004 16:38:54 -0600
+
+libunwind (0.98.2-2) unstable; urgency=low
+
+  * Remove libatomic-ops depedency
+
+ -- Matthieu Delahaye <matthieu@debian.org>  Tue,  16 Nov 2004 09:20:00 -0500
+
+libunwind (0.98.2-1) unstable; urgency=low
+
+  * New upstream release
+
+ -- Matthieu Delahaye <matthieu@debian.org>  Thu,  4 Nov 2004 19:08:59 -0600
+
+libunwind (0.98.1-1) unstable; urgency=low
+
+  * New upstream release
+  * Major soversion changed in upstream source: new packages libunwind7(-dev)
+    and libunwind-setjmp0(-dev)
+
+ -- Matthieu Delahaye <matthieu@debian.org>  Fri,  22 Oct 2004 15:03:30 -0500
+
+libunwind (0.98-1) unstable; urgency=low
+
+  * New upstream release
+
+ -- Matthieu Delahaye <matthieu@debian.org>  Thu,  9 Sep 2004 18:28:49 -0500
+
+libunwind (0.97-2) unstable; urgency=low
+
+  * Build libunwind against libatomic-ops
+
+ -- Matthieu Delahaye <matthieu@debian.org>  Fri,  28 May 2004 14:21:39 +0200
+
+libunwind (0.97-1) unstable; urgency=low
+
+  * New upstream release
+
+ -- Matthieu Delahaye <matthieu@debian.org>  Fri,  7 May 2004 14:25:39 +0200
+
+libunwind (0.96-2) unstable; urgency=low
+
+  * Removed --disable-__thread from configure options 
+  * Forced Deps to libc6.1 and libc6.1-dev (>=2.3.2-ds1-8) for NTPL support
+
+ -- Matthieu Delahaye <matthieu@debian.org>  Fri, 06 Feb 2004 10:29:30 +0100
+
+libunwind (0.96-1) unstable; urgency=low
+
+  * Initial Release with inputs from Al Stone <ahs3@fc.hp.com>. 
+  * Added Al Stone <ahs3@debian.org> to Uploaders.
+  * Closes: bug#184751 (Initial ITP)
+  * Closes: bug#215185 (ITP merged with #184751)
+  * Upgraded to latest rev of Debian policy
+
+ -- Matthieu Delahaye <matthieu@debian.org>  Thu, 11 Dec 2003 10:13:55 +0100
+
+
--- libunwind-0.99.orig/debian/libunwind-setjmp0.dirs
+++ libunwind-0.99/debian/libunwind-setjmp0.dirs
@@ -0,0 +1 @@
+usr/lib
--- libunwind-0.99.orig/debian/watch
+++ libunwind-0.99/debian/watch
@@ -0,0 +1,2 @@
+version=3
+http://nongnu.askapache.com/libunwind/libunwind-([0-9].[0-9]+\.?[0-9]*)\.tar\.gz
--- libunwind-0.99.orig/debian/libunwind-setjmp0-dev.dirs
+++ libunwind-0.99/debian/libunwind-setjmp0-dev.dirs
@@ -0,0 +1,2 @@
+usr/lib
+usr/share/man/man3
--- libunwind-0.99.orig/debian/patches/00list
+++ libunwind-0.99/debian/patches/00list
@@ -0,0 +1 @@
+090828-rpath
--- libunwind-0.99.orig/debian/patches/090828-rpath.dpatch
+++ libunwind-0.99/debian/patches/090828-rpath.dpatch
@@ -0,0 +1,33 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 090828-rpath.dpatch by Daigo Moriwaki <daigo@debian.org>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: rpath should not be used
+## DP: http://wiki.debian.org/RpathIssue
+
+@DPATCH@
+diff -urNad libunwind-0.99~/configure.in libunwind-0.99/configure.in
+--- libunwind-0.99~/configure.in	2009-05-09 01:34:10.000000000 +0900
++++ libunwind-0.99/configure.in	2009-08-29 10:41:18.000000000 +0900
+@@ -17,10 +17,20 @@
+ AC_PROG_CXX
+ AC_PROG_INSTALL
+ AC_PROG_MAKE_SET
+-AM_PROG_LIBTOOL
++AC_PROG_LIBTOOL
+ AM_PROG_AS
+ AM_PROG_CC_C_O
+ 
++case ${host} in
++  *-pc-linux-gnu)
++    AC_MSG_RESULT([Fixing libtool for -rpath problems.])
++    sed < libtool > libtool-2 \
++    's/^hardcode_libdir_flag_spec.*$'/'hardcode_libdir_flag_spec=" -D__LIBTOOL_IS_A_FOOL__ "/'
++    mv libtool-2 libtool
++    chmod 755 libtool
++  ;;
++esac
++
+ dnl Checks for libraries.
+ AC_CHECK_LIB(uca, __uc_get_grs)
+ CHECK_ATOMIC_OPS
