From patchwork Wed Apr 1 23:20:15 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tyler Baker X-Patchwork-Id: 6143291 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 5E7B29F1BE for ; Wed, 1 Apr 2015 23:23:41 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 85B522034A for ; Wed, 1 Apr 2015 23:23:40 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id A397120328 for ; Wed, 1 Apr 2015 23:23:39 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1YdRwb-0007oQ-Vt; Wed, 01 Apr 2015 23:21:09 +0000 Received: from mail-pa0-f50.google.com ([209.85.220.50]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1YdRwL-0007aK-BX for linux-arm-kernel@lists.infradead.org; Wed, 01 Apr 2015 23:20:54 +0000 Received: by patj18 with SMTP id j18so65904814pat.2 for ; Wed, 01 Apr 2015 16:20:32 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=ACM3glHtcUsmuw+6LKcNiF+SugkY7qMbzoqJrIHzr4k=; b=BUhN8/1pUq8TeSmOKaJoWOOMNgujbICstSyXYrZ9dL8ex6WOfT4L78XyX4eRKV42jL aVrXjoQIbFScDUPpiDSXm09BPsJY+KzKJ4D26THMxe5UUFAZCvqQniMdhgJ2/+XHYk7n vplAlNl2Zq5/OOkS7I6Qo1zyGKsShjCKJDkAGfT8lM29crn4Y4T5vTqKGVTUiiH8EF/z a9GaJ1VIHU/1HbbZEtUguwK5tfUvMXth3MRgUgRRC2PSOfy/MFUByf11WDo+618dQ6WN EUQINUDi2DAoO7AZD+pqW3gUF7lL2h1lrZ1f7tX3M+24cpI9he1wLqWnnJ3w4eZUjkms amSw== X-Gm-Message-State: ALoCoQnP2X/7ipmf6FF+ISmRJW8WyJFW1M5/77zCoRpGgk/bXnWAoOhut39/2uTDSMRBoO92Krza X-Received: by 10.68.132.169 with SMTP id ov9mr81184594pbb.109.1427930431841; Wed, 01 Apr 2015 16:20:31 -0700 (PDT) Received: from localhost.localdomain ([173.14.250.228]) by mx.google.com with ESMTPSA id qz3sm3210197pab.13.2015.04.01.16.20.30 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 01 Apr 2015 16:20:30 -0700 (PDT) From: Tyler Baker To: Shuah Khan Subject: [PATCH 1/6] selftest/memfd: enable cross compilation Date: Wed, 1 Apr 2015 16:20:15 -0700 Message-Id: <1427930420-4762-2-git-send-email-tyler.baker@linaro.org> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1427930420-4762-1-git-send-email-tyler.baker@linaro.org> References: <1427930420-4762-1-git-send-email-tyler.baker@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20150401_162053_460426_2FF8802A X-CRM114-Status: UNSURE ( 8.51 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -0.7 (/) Cc: Kevin Hilman , Michael Ellerman , Tyler Baker , linux-kernel@vger.kernel.org, John Stultz , David Herrmann , Darren Hart , linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Use the CC variable instead of hard coding gcc. Also clean up the compiler options by creating a CFLAGS variable. Signed-off-by: Tyler Baker --- tools/testing/selftests/memfd/Makefile | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tools/testing/selftests/memfd/Makefile b/tools/testing/selftests/memfd/Makefile index 191dee9..69f08ab 100644 --- a/tools/testing/selftests/memfd/Makefile +++ b/tools/testing/selftests/memfd/Makefile @@ -1,17 +1,18 @@ +CC = $(CROSS_COMPILE)gcc CFLAGS += -D_FILE_OFFSET_BITS=64 CFLAGS += -I../../../../include/uapi/ CFLAGS += -I../../../../include/ all: - gcc $(CFLAGS) memfd_test.c -o memfd_test + $(CC) $(CFLAGS) memfd_test.c -o memfd_test TEST_PROGS := memfd_test include ../lib.mk build_fuse: - gcc $(CFLAGS) fuse_mnt.c `pkg-config fuse --cflags --libs` -o fuse_mnt - gcc $(CFLAGS) fuse_test.c -o fuse_test + $(CC) $(CFLAGS) fuse_mnt.c `pkg-config fuse --cflags --libs` -o fuse_mnt + $(CC) $(CFLAGS) fuse_test.c -o fuse_test run_fuse: build_fuse @./run_fuse_test.sh || echo "fuse_test: [FAIL]"