diff options
author | Fathi Boudra <fabo@debian.org> | 2008-04-07 07:47:02 +0000 |
---|---|---|
committer | Fathi Boudra <fabo@debian.org> | 2008-04-07 07:47:02 +0000 |
commit | 63a0cbed46c40c24630eadb728f2e361acbe5c51 (patch) | |
tree | c82ae12bddd350cffd9e1ff4ecd9632e088c03cf | |
parent | f0fb0af80d9e6475cc2b2fa75eccaea21369416b (diff) | |
download | qt4-x11-63a0cbed46c40c24630eadb728f2e361acbe5c51.tar.gz |
Re-add hppa test. Removed by mistake.debian/4.4.0-rc1-1
hppa unaligned access patch doesn't fix the same issue.
-rw-r--r-- | debian/changelog | 4 | ||||
-rw-r--r-- | debian/patches/71_hppa_unaligned_access_fix_458133.diff | 2 | ||||
-rw-r--r-- | debian/readdir-hppa-test.c | 25 | ||||
-rwxr-xr-x | debian/rules | 18 |
4 files changed, 46 insertions, 3 deletions
diff --git a/debian/changelog b/debian/changelog index 9bb9c33..58c46b3 100644 --- a/debian/changelog +++ b/debian/changelog @@ -46,8 +46,8 @@ qt4-x11 (4.4.0~rc1-1) unstable; urgency=low architectures listed first. (Closes: #473348) * Add architectures availability list to libqt4-sql-ibase package. (Closes: #473348) - * Add patch to fix unaligned access that cause a bus error on hppa. - Thanks to Bernhard R. Link. (Closes: #458133) + * Add patch to fix unaligned access on hppa. Thanks to Bernhard R. Link. + (Closes: #458133) * Add patch to replace remaining qdbus by dbus. Fix libqtscriptdbus build. * Update configure options: * Replace -qdbus by -dbus. diff --git a/debian/patches/71_hppa_unaligned_access_fix_458133.diff b/debian/patches/71_hppa_unaligned_access_fix_458133.diff index eabb79d..2402781 100644 --- a/debian/patches/71_hppa_unaligned_access_fix_458133.diff +++ b/debian/patches/71_hppa_unaligned_access_fix_458133.diff @@ -1,6 +1,6 @@ author: Bernhard R. Link <brlink@debian.org> -Fix unaligned access that cause a bus error on hppa (ftbfs) +Fix unaligned access on hppa --- a/src/corelib/global/qnumeric_p.h +++ b/src/corelib/global/qnumeric_p.h diff --git a/debian/readdir-hppa-test.c b/debian/readdir-hppa-test.c new file mode 100644 index 0000000..eb893ba --- /dev/null +++ b/debian/readdir-hppa-test.c @@ -0,0 +1,25 @@ +#include <sys/types.h> +#include <dirent.h> +#include <errno.h> +#include <stdio.h> + +main() { + int return_code; + DIR *dir; + struct dirent entry; + struct dirent *result; + + if ((dir = opendir(".")) == NULL) + perror("opendir() error"); + else { + // puts("contents of .:"); + for (return_code = readdir_r(dir, &entry, &result); + result != NULL && return_code == 0; + return_code = readdir_r(dir, &entry, &result)) + printf("%s\n", entry.d_name); + if (return_code != 0) + perror("readdir_r() error"); + closedir(dir); + } +} + diff --git a/debian/rules b/debian/rules index 7af2df1..032e824 100755 --- a/debian/rules +++ b/debian/rules @@ -53,6 +53,21 @@ endif common-configure-arch:: config.status config.status: + # Test broken hppa kernel with glibc >= 2.5 +ifeq ($(DEB_HOST_ARCH),hppa) + mkdir -p debian/hppa-tmp + echo "Testing whether getdents kernel bug is present on this buildd - see #433768" + gcc -o debian/hppa-tmp/hppa-test-program debian/readdir-hppa-test.c + cd $(CURDIR)/doc/html && $(CURDIR)/debian/hppa-tmp/hppa-test-program | sort > $(CURDIR)/debian/hppa-tmp/readdir_r-out + cd $(CURDIR)/doc/html && ls -a | sort > $(CURDIR)/debian/hppa-tmp/ls-a-out + @if ! diff -q $(CURDIR)/debian/hppa-tmp/readdir_r-out $(CURDIR)/debian/hppa-tmp/ls-a-out ; \ + then \ + echo "Kernel bug present. This will misbuild qt4 if proceeding. Failing" ; \ + echo "Please update kernel and test again" ; \ + exit 5 ; \ + fi +endif + # Create mkspecs/glibc-g++ from mkspecs/linux-g++, needed by GNU/kFreeBSD # we cannot use directly linux-g++ due to src/corelib/io/io.pri rm -rf mkspecs/glibc-g++ @@ -118,6 +133,9 @@ clean:: plugins/ \ ; + # hppa test directory + rm -rf debian/hppa-tmp + # Leftover dirs find -depth -type d \( -false \ -o -name debug-shared \ |