From patchwork Tue Mar 31 06:51:36 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joonas Lahtinen X-Patchwork-Id: 6127591 Return-Path: X-Original-To: patchwork-intel-gfx@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id C051CBF4A6 for ; Tue, 31 Mar 2015 06:52:13 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id D551C201CD for ; Tue, 31 Mar 2015 06:52:12 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id 76A23201C0 for ; Tue, 31 Mar 2015 06:52:11 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 5CA296E0D3; Mon, 30 Mar 2015 23:52:10 -0700 (PDT) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by gabe.freedesktop.org (Postfix) with ESMTP id 59CDB6E0D3 for ; Mon, 30 Mar 2015 23:52:09 -0700 (PDT) Received: from orsmga003.jf.intel.com ([10.7.209.27]) by orsmga102.jf.intel.com with ESMTP; 30 Mar 2015 23:52:08 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.11,499,1422950400"; d="scan'208";a="548762912" Received: from shenkel-mobl1.ger.corp.intel.com (HELO [10.252.11.179]) ([10.252.11.179]) by orsmga003.jf.intel.com with ESMTP; 30 Mar 2015 23:52:07 -0700 Message-ID: <1427784696.8718.6.camel@jlahtine-mobl1> From: Joonas Lahtinen To: intel-gfx@lists.freedesktop.org In-Reply-To: <1427446585.4966.6.camel@jlahtine-mobl1> References: <1427446260.4966.3.camel@jlahtine-mobl1> <1427446585.4966.6.camel@jlahtine-mobl1> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo Date: Tue, 31 Mar 2015 09:51:36 +0300 Mime-Version: 1.0 X-Mailer: Evolution 3.10.4 (3.10.4-4.fc20) Cc: Thomas Wood Subject: [Intel-gfx] [PATCH i-g-t v4] tests: install test programs to libexec X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" 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 Install the test programs by default so that they can be packaged. Tested with the testdisplay test so that it still runs after the modifications as it depends on a data file to be present. Packaging is useful when building a complete software stack for a DUT from scratch. This should bring us closer to achieving a built-from-scratch testing workflow. Package maintainers can always decide to ignore the installed files. v2: - Install more tests including scripts and their data v3: - Add clarification to commit message about why we do this. (Chris Wilson & Thomas Wood) - Change libexec into pkglibexec to comply to standard (Thomas Wood) - Do not install $(common_files). (Thomas Wood) - Make it really obvious the installed files are tests by using tests directory name to avoid any confusion with packagers. v4: - Fixed commit message. Cc: Chris Wilson Cc: Thomas Wood Signed-off-by: Joonas Lahtinen --- tests/Makefile.am | 21 ++++++++++++++++++--- tests/Makefile.sources | 16 ++++++++++++++-- 2 files changed, 32 insertions(+), 5 deletions(-) diff --git a/tests/Makefile.am b/tests/Makefile.am index f45c6c9..5cce450 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -27,8 +27,23 @@ multi-tests.txt: Makefile.sources @echo ${multi_kernel_tests} >> $@ @echo END TESTLIST >> $@ -EXTRA_PROGRAMS = $(TESTS_progs) $(TESTS_progs_M) $(HANG) -EXTRA_DIST = $(TESTS_scripts) $(TESTS_scripts_M) $(scripts) $(IMAGES) $(common_files) +igt_tests_bin_PROGRAMS += \ + $(TESTS_progs) \ + $(TESTS_progs_M) \ + $(NULL) + +igt_tests_bin_SCRIPTS += \ + $(TESTS_scripts) \ + $(TESTS_scripts_M) \ + $(scripts) \ + $(NULL) + +igt_tests_data_DATA += \ + $(IMAGES) \ + $(NULL) + +EXTRA_PROGRAMS = $(HANG) +EXTRA_DIST = $(common_files) CLEANFILES = $(EXTRA_PROGRAMS) single-tests.txt multi-tests.txt @@ -36,7 +51,7 @@ AM_CFLAGS = $(DRM_CFLAGS) $(CWARNFLAGS) $(DEBUG_CFLAGS)\ -I$(srcdir)/.. \ -I$(srcdir)/../lib \ -include "$(srcdir)/../lib/check-ndebug.h" \ - -DIGT_DATADIR=\""$(abs_srcdir)"\" \ + -DIGT_DATADIR=\""$(igt_tests_datadir)"\" \ $(LIBUNWIND_CFLAGS) \ $(NULL) diff --git a/tests/Makefile.sources b/tests/Makefile.sources index 0a974a6..e8297dd 100644 --- a/tests/Makefile.sources +++ b/tests/Makefile.sources @@ -1,10 +1,22 @@ +igt_tests_bindir = $(pkglibexecdir)/tests +igt_tests_datadir = $(pkgdatadir)/tests + noinst_PROGRAMS = \ + $(HANG) \ + $(TESTS_testsuite) \ + $(NULL) + +igt_tests_bin_PROGRAMS = \ gem_alive \ gem_stress \ $(TESTS_progs) \ $(TESTS_progs_M) \ - $(HANG) \ - $(TESTS_testsuite) \ + $(NULL) + +igt_tests_bin_SCRIPTS = \ + $(NULL) + +igt_tests_data_DATA = \ $(NULL) NOUVEAU_TESTS_M = \