Package: ltp
Severity: normal
Tags: patch

When building 'ltp' on amd64 with gcc-4.0,
I get the following error:

cc -Wall  -Wall -O -g -I../../../../include    shmat1.c  -lpthread -o shmat1
shmat1.c: In function 'write_to_mem':
shmat1.c:371: error: invalid lvalue in assignment
make[5]: *** [shmat1] Error 1
make[5]: Leaving directory 
`/ltp-20040804/build-tree/ltp-full-20040804/testcases/kernel/mem/mtest06'

With the attached patch 'ltp' can be compiled
on amd64 using gcc-4.0.

Regards
Andreas Jochens

diff -urN ../tmp-orig/ltp-20050107/debian/patches/35_gcc4_buildfix.patch 
./debian/patches/35_gcc4_buildfix.patch
--- ../tmp-orig/ltp-20050107/debian/patches/35_gcc4_buildfix.patch      
1970-01-01 01:00:00.000000000 +0100
+++ ./debian/patches/35_gcc4_buildfix.patch     2005-02-10 08:11:03.997411150 
+0100
@@ -0,0 +1,12 @@
+diff -urN tmp/testcases/kernel/mem/mtest06/shmat1.c 
ltp-full-20050107/testcases/kernel/mem/mtest06/shmat1.c
+--- tmp/testcases/kernel/mem/mtest06/shmat1.c  2004-02-23 22:23:01.000000000 
+0100
++++ ltp-full-20050107/testcases/kernel/mem/mtest06/shmat1.c    2005-02-10 
08:11:01.934814814 +0100
+@@ -368,7 +368,7 @@
+ 
+       fprintf(stdout, "write_to_mem(): memory address: [%p]\n", 
+               map_address);
+-      (char *)map_address = "Y";
++      map_address = "Y";
+         //memset(map_address, 'Y', fsize);
+         usleep(1);
+       sched_yield();


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to