Hi Subrata, Mike,
I still couldn't build the LTP in a ppc64 machine even after apply the patch
you have mentioned. 'make all' fails with the following:
make[3]: Entering directory `/root/ltp/testcases/misc/tcore_patch_test_suites'
gcc -o tcore tcore.c -lm -lpthread
tcore.c:203:18: error: test.h: No such file or directory
tcore.c:204:21: error: usctest.h: No such file or directory
tcore.c: In function ‘main’:
tcore.c:209: error: ‘TCONF’ undeclared (first use in this function)
tcore.c:209: error: (Each undeclared identifier is reported only once
tcore.c:209: error: for each function it appears in.)
make[3]: *** [tcore] Error 1
make[3]: Leaving directory `/root/ltp/testcases/misc/tcore_patch_test_suites'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/root/ltp/testcases/misc'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/root/ltp/testcases'
make: *** [all] Error 2
Then, I included the ltp headers/libs on Makefile and *TCID variable on
tcore.c. Could you please review the attached patch?
Thanks for your help.
Subrata Modak wrote:
> Mike,
>
> Then the following Patch will be needed:
>
> On Thu, 2009-01-08 at 01:34 -0500, Mike Frysinger wrote:
>> On Wednesday 07 January 2009 16:53:09 Edjunior Barbosa Machado wrote:
>>> in a ppc64 machine running SLES11 RC1, I'm trying to build the December
>>> 2008 LTP release (ltp-full-20081231) but it fails on "make":
>>>
>>> ....
>>> make[3]: Entering directory
>>> `/root/ltp-full-20081231/testcases/misc/tcore_patch_test_suites' gcc -o
>>> tcore tcore.c -lm -lpthread
>>> /usr/local/autobench/var/tmp/18957/ccu7XRNb.s: Assembler messages:
>>> /usr/local/autobench/var/tmp/18957/ccu7XRNb.s:422: Error: Unrecognized
>>> opcode: `movups'
>> tcore only works on x86 systems ... building/running on other systems makes
>> no
>> sense
>
> Signed-Off-By: Subrata Modak <subr...@linux.vnet.ibm.com>,
> --
> ---
> ltp-intermediate-20090105/testcases/misc/tcore_patch_test_suites/tcore.c.orig
> 2009-01-08 14:05:49.000000000 +0530
> +++
> ltp-intermediate-20090105/testcases/misc/tcore_patch_test_suites/tcore.c
> 2009-01-08 14:12:09.000000000 +0530
> @@ -20,6 +20,8 @@
>
> // Use gcc -o xmm xmm.c -pthread -lm to compile.
>
> +#if defined __i386__ || defined(__x86_64__)
> +
> #include <stdio.h>
> #include <sys/types.h>
> #include <unistd.h>
> @@ -195,3 +197,17 @@ main (void)
> pthread_join (th_b, &retval);
> return 0;
> }
> +
> +#else /* Not __i386__ */
> +
> +#include "test.h"
> +#include "usctest.h"
> +
> +int TST_TOTAL = 0; /* Total number of test cases. */
> +
> +int main() {
> + tst_resm(TCONF, "tcore only works on x86 systems ...");
> + tst_exit();
> +}
> +
> +#endif /* __i386__ */
>
> Regards--
> Subrata
>
>> -mike
>> ------------------------------------------------------------------------------
>> Check out the new SourceForge.net Marketplace.
>> It is the best place to buy or sell services for
>> just about anything Open Source.
>> http://p.sf.net/sfu/Xq1LFB
>> _______________________________________________ Ltp-list mailing list
>> Ltp-list@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/ltp-list
--
Edjunior Barbosa Machado
IBM Linux Technology Center
Linux Defect Support Team
minor fixes on tcore.c
this patch includes LTP headers/libs to Makefile and defines
*TCID variable on tcore.c.
Signed-off-by: Edjunior B. Machado <emach...@linux.vnet.ibm.com>
diff --git a/testcases/misc/tcore_patch_test_suites/Makefile b/testcases/misc/tcore_patch_test_suites/Makefile
index 7fcb375..51e6543 100644
--- a/testcases/misc/tcore_patch_test_suites/Makefile
+++ b/testcases/misc/tcore_patch_test_suites/Makefile
@@ -1,4 +1,6 @@
CC=gcc
+CFLAGS+= -I../../../include
+LOADLIBES+= -L../../../lib -lltp -lm -lpthread
MODCFLAGS := -Wall -DLINUX -I/usr/src/linux/include
EXECS=tcore tcore.sh tcore.exp
@@ -8,7 +10,7 @@ install:
@set -e; for i in $(EXECS) ; do ln -f $$i ../../bin/$$i ; done ;
tcore: tcore.c
- $(CC) -o tcore tcore.c -lm -lpthread
+
clean:
rm -f tcore
diff --git a/testcases/misc/tcore_patch_test_suites/tcore.c b/testcases/misc/tcore_patch_test_suites/tcore.c
index bc51e10..e027e38 100644
--- a/testcases/misc/tcore_patch_test_suites/tcore.c
+++ b/testcases/misc/tcore_patch_test_suites/tcore.c
@@ -203,6 +203,8 @@ main (void)
#include "test.h"
#include "usctest.h"
+char *TCID="tcore";
+
int TST_TOTAL = 0; /* Total number of test cases. */
int main() {
------------------------------------------------------------------------------
This SF.net email is sponsored by:
SourcForge Community
SourceForge wants to tell your story.
http://p.sf.net/sfu/sf-spreadtheword
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list