From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3421 invoked by alias); 15 Jul 2011 20:15:15 -0000 Received: (qmail 3409 invoked by uid 22791); 15 Jul 2011 20:15:12 -0000 X-SWARE-Spam-Status: No, hits=-6.1 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD,SPF_HELO_PASS X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 15 Jul 2011 20:14:53 +0000 Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id p6FKEpRV002206 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 15 Jul 2011 16:14:51 -0400 Received: from fche.csb (vpn-11-66.rdu.redhat.com [10.11.11.66]) by int-mx02.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id p6FKEpfV008953; Fri, 15 Jul 2011 16:14:51 -0400 Received: by fche.csb (Postfix, from userid 2569) id E860C58126; Fri, 15 Jul 2011 16:14:50 -0400 (EDT) To: Da Zheng Cc: Mark Wielaard , systemtap@sourceware.org Subject: Re: error to run systemtap in an ARM platform References: <4E1F90A8.2080000@gmail.com> <1310722941.4510.5.camel@springer.wildebeest.org> <4E209C3F.6060806@gmail.com> From: fche@redhat.com (Frank Ch. Eigler) Date: Fri, 15 Jul 2011 20:15:00 -0000 In-Reply-To: <4E209C3F.6060806@gmail.com> (Da Zheng's message of "Fri, 15 Jul 2011 12:59:59 -0700") Message-ID: User-Agent: Gnus/5.1008 (Gnus v5.10.8) Emacs/21.4 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Mailing-List: contact systemtap-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: systemtap-owner@sourceware.org X-SW-Source: 2011-q3/txt/msg00033.txt.bz2 Da Zheng writes: > I tried to compile my script with > $ stap -v syscalls_by_pid.stp -a arm -r > /build/tegra2_seaboard/tmp/portage/sys-kernel/chromeos-kernel-9999/work/chromeos-kernel-9999/build/tegra2_seaboard -p 4 -k > [...] > Pass 3: translated to C into "/tmp/stapsWo8wq/stap_23913.c" using > 159984virt/87692res/5400shr kb, in 240usr/0sys/237real ms. > cc1: error: unrecognized command line option "-mlittle-endian" > cc1: error: unrecognized command line option "-mapcs" > cc1: error: unrecognized command line option "-mno-sched-prolog" > cc1: error: unrecognized command line option "-mabi=aapcs-linux" > cc1: error: unrecognized command line option "-mno-thumb-interwork" > /tmp/stapsWo8wq/stap_23913.c:1: error: bad value (armv5t) for -march= switch > /tmp/stapsWo8wq/stap_23913.c:1: error: bad value (armv5t) for -mtune= switch > [...] > I use armv7a-cros-linux-gnueabi-gcc to cross compile the kernel and > other software. How can I specify the compiler for cross compile? I > tried to set the environment variable CC, but it doesn't work. How did you tell kbuild to use that compiler? Environment variables, or some kernel Makefile edit? Have you ever built an out-of-tree kernel module via cross compilation? - FChE