From patchwork Fri Oct 27 12:49:51 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Eremin-Solenikov X-Patchwork-Id: 117327 Delivered-To: patch@linaro.org Received: by 10.140.22.164 with SMTP id 33csp740231qgn; Fri, 27 Oct 2017 05:59:00 -0700 (PDT) X-Google-Smtp-Source: ABhQp+Tmf3f1vvTmyBX1Fl/SF3NGh+ux01KCpToeZI7v30L8K8nU25JqfERIyBNuKe4sUL49crS4 X-Received: by 10.107.180.199 with SMTP id d190mr490954iof.114.1509109140386; Fri, 27 Oct 2017 05:59:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1509109140; cv=none; d=google.com; s=arc-20160816; b=WoPWUBbCLipeyzY+LJpiEH2LsiJdRhcU2rdrT8nLBktXZuW1c7hnIepWI9R1XGOJQQ qRtBDuz3FnLK/TztXE/KLCcBdz+H4SbaxtG8YAiEzotLww88S/oF7rq93N5PCaisZUyf qJFCvmtIWl/uedXeoo7kNKD8TAcaujGd4Gzy4t8+obtpcKZ4Ghd234tmRuQu3IKkjEZC SmUDbOLjbXCBT1pltK/eiakLEVgU8uq8WRFbKyz7DezUwzp7705lzLKWT6CF2S7xOa7M 9OXSKfQUUdBvsYRzBj0GxGEiw+BYxD0r8A1691OWMkg+V5KqADL17pq8bURnEYzCil6n 0Q0A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject:references:in-reply-to :message-id:date:to:from:delivered-to:arc-authentication-results; bh=xcRiRUKrEQ/95O8UsrLWtGIfaCyYsQS8iUaDv2xBqes=; b=c4kOsTK7qGm3hmvl93fWPOmYDDdvIqhrShf8w/Ev4ZZlBepyrVp1YFtmtnCEXqJ2qP yCsriFv1jX+ljsHk+9OTlE+QDMWY21+B0Omfq+wh9T4Xazn7EhRsFLS6TiE6qA2Jw8Jj 4GaO+2lYeHGJUcGqSYQ6blISf745GFpTTE74OAOo6VC+/AEj1fCSVBea+BSKOd7cIZkY 1Cj72sqRTPdFm5PCvFbLyW43qEinXr8U+DDK0NaRzya098EhBuzyl+F0Hakri1T9730u 9F3YDlh2COvr3NEi6pMFZx9WDRYoMm6Uv4RM8mwX3Tc1Q4Vq8audLP5IXutrwRH+DjhA UWFA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.197.127.237 as permitted sender) smtp.mailfrom=lng-odp-bounces@lists.linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.linaro.org (ec2-54-197-127-237.compute-1.amazonaws.com. [54.197.127.237]) by mx.google.com with ESMTP id e3si1199570itb.151.2017.10.27.05.59.00; Fri, 27 Oct 2017 05:59:00 -0700 (PDT) Received-SPF: pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.197.127.237 as permitted sender) client-ip=54.197.127.237; Authentication-Results: mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.197.127.237 as permitted sender) smtp.mailfrom=lng-odp-bounces@lists.linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id F07D56294D; Fri, 27 Oct 2017 12:58:59 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on ip-10-142-244-252 X-Spam-Level: X-Spam-Status: No, score=-1.4 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, RCVD_IN_SORBS_SPAM, URIBL_BLOCKED autolearn=disabled version=3.4.0 Received: from [127.0.0.1] (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id E492A60C15; Fri, 27 Oct 2017 12:51:26 +0000 (UTC) X-Original-To: lng-odp@lists.linaro.org Delivered-To: lng-odp@lists.linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 05C9C6297B; Fri, 27 Oct 2017 12:51:22 +0000 (UTC) Received: from mail-lf0-f65.google.com (mail-lf0-f65.google.com [209.85.215.65]) by lists.linaro.org (Postfix) with ESMTPS id 2A6E860B5A for ; Fri, 27 Oct 2017 12:50:29 +0000 (UTC) Received: by mail-lf0-f65.google.com with SMTP id p184so7270217lfe.12 for ; Fri, 27 Oct 2017 05:50:29 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references; bh=xcRiRUKrEQ/95O8UsrLWtGIfaCyYsQS8iUaDv2xBqes=; b=aNr+KfbtzS42EZhkBtsj3kv+DXHu4plpYGiqyaoJoWS3F9KOjrIfWXy7xqwEKivGeO hEA62HY8hBPlXHL7g1Je11V+HUbkd3KxkemBfu5TZmeQmk2OHR9iN9S6wiPKNZKU3T5P 1Z5mvVtmH4DWqoI1RjatjXTT/OwBXRdqZNX1kt7RllL9gDdTUxe07CR/CZwsk/zn1fZ9 WD8nL+cMAaGiZIUlE/M1CoCg70DTv/V/lYijAhkLDzpKVtDranQcNPxqc3QnInhxK8GK tuTvjwK/1clG4+xYH+UXEsh5nd5rOepVGIhbeFGq1ErQXPwhbcOQGCGYb3htNj7w63O4 pXDQ== X-Gm-Message-State: AMCzsaXAZQ39wrNE+xhGBw1lOnaOPpfeye3v5jQBQ8k0ASw3CinzTZ7V tTFI/O6pKSRl7vko/bJTGVB1ySAmwxHnGg== X-Received: by 10.46.5.130 with SMTP id 124mr168153ljf.116.1509108627728; Fri, 27 Oct 2017 05:50:27 -0700 (PDT) Received: from rhovanion.lumag.spb.ru ([94.25.228.222]) by smtp.gmail.com with ESMTPSA id l194sm1584690lfl.11.2017.10.27.05.50.26 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 27 Oct 2017 05:50:27 -0700 (PDT) From: Dmitry Eremin-Solenikov To: lng-odp@lists.linaro.org Date: Fri, 27 Oct 2017 15:49:51 +0300 Message-Id: <20171027125014.27313-8-dmitry.ereminsolenikov@linaro.org> X-Mailer: git-send-email 2.14.2 In-Reply-To: <20171027125014.27313-1-dmitry.ereminsolenikov@linaro.org> References: <20171027125014.27313-1-dmitry.ereminsolenikov@linaro.org> Subject: [lng-odp] [PATCH v10 07/30] build: move ODP include path to common Makefile.inc X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: "The OpenDataPlane \(ODP\) List" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: lng-odp-bounces@lists.linaro.org Sender: "lng-odp" Signed-off-by: Dmitry Eremin-Solenikov --- Makefile.inc | 12 ++++++++++++ example/Makefile.inc | 12 ++++-------- helper/Makefile.am | 12 ++++-------- helper/test/Makefile.am | 18 +++++------------- platform/Makefile.inc | 2 +- platform/linux-generic/Makefile.am | 8 +------- platform/linux-generic/test/Makefile.inc | 12 ++---------- platform/linux-generic/test/ring/Makefile.am | 2 +- .../test/validation/api/shmem/Makefile.am | 4 ++-- test/Makefile.inc | 17 +++++------------ 10 files changed, 37 insertions(+), 62 deletions(-) create mode 100644 Makefile.inc -- 2.14.2 diff --git a/Makefile.inc b/Makefile.inc new file mode 100644 index 000000000000..10e4041fe662 --- /dev/null +++ b/Makefile.inc @@ -0,0 +1,12 @@ +ODP_INCLUDES = \ + -I$(top_builddir)/platform/@with_platform@/include \ + -I$(top_srcdir)/platform/@with_platform@/include \ + -I$(top_srcdir)/platform/@with_platform@/arch/@ARCH_DIR@ \ + -I$(top_builddir)/include \ + -I$(top_srcdir)/include/odp/arch/@ARCH_ABI@ \ + -I$(top_srcdir)/include + +HELPER_INCLUDES = \ + -I$(top_srcdir)/helper/include + +LIB = $(top_builddir)/lib diff --git a/example/Makefile.inc b/example/Makefile.inc index 1609066e64c2..498f656faa66 100644 --- a/example/Makefile.inc +++ b/example/Makefile.inc @@ -1,16 +1,12 @@ +include $(top_srcdir)/Makefile.inc + TESTS_ENVIRONMENT = EXEEXT=${EXEEXT} -LIB = $(top_builddir)/lib LDADD = $(LIB)/libodp-linux.la $(LIB)/libodphelper.la $(DPDK_PMDS) AM_CFLAGS = \ -I$(srcdir) \ -I$(top_srcdir)/example \ - -I$(top_srcdir)/platform/@with_platform@/include \ - -I$(top_srcdir)/include/ \ - -I$(top_srcdir)/include/odp/arch/@ARCH_ABI@ \ - -I$(top_srcdir)/helper/include \ - -I$(top_builddir)/platform/@with_platform@/include \ - -I$(top_srcdir)/platform/@with_platform@/arch/@ARCH_DIR@ \ - -I$(top_builddir)/include + $(ODP_INCLUDES) \ + $(HELPER_INCLUDES) AM_LDFLAGS = -L$(LIB) -static diff --git a/helper/Makefile.am b/helper/Makefile.am index ee1c17d6d0a3..2321a2d4f24c 100644 --- a/helper/Makefile.am +++ b/helper/Makefile.am @@ -1,15 +1,11 @@ +include $(top_srcdir)/Makefile.inc + pkgconfigdir = $(libdir)/pkgconfig pkgconfig_DATA = libodphelper.pc -LIB = $(top_builddir)/lib AM_CPPFLAGS = \ - -I$(top_builddir)/platform/@with_platform@/include \ - -I$(top_srcdir)/helper/include \ - -I$(top_srcdir)/include \ - -I$(top_srcdir)/include/odp/arch/@ARCH_ABI@ \ - -I$(top_srcdir)/platform/@with_platform@/include \ - -I$(top_srcdir)/platform/@with_platform@/arch/@ARCH_DIR@ \ - -I$(top_builddir)/include + $(ODP_INCLUDES) \ + $(HELPER_INCLUDES) AM_LDFLAGS = -version-number '$(ODPHELPER_LIBSO_VERSION)' diff --git a/helper/test/Makefile.am b/helper/test/Makefile.am index 8eee643bee39..27c414aa7461 100644 --- a/helper/test/Makefile.am +++ b/helper/test/Makefile.am @@ -1,25 +1,17 @@ -TESTS_ENVIRONMENT = EXEEXT=${EXEEXT} +include $(top_srcdir)/Makefile.inc -LIB = $(top_builddir)/lib +TESTS_ENVIRONMENT = EXEEXT=${EXEEXT} #in the following line, the libs using the symbols should come before #the libs containing them! The includer is given a chance to add things #before libodp by setting PRE_LDADD before the inclusion. LDADD = $(PRE_LDADD) $(LIB)/libodphelper.la $(LIB)/libodp-linux.la -INCFLAGS = \ - -I$(top_builddir)/platform/@with_platform@/include \ - -I$(top_srcdir)/helper/include \ - -I$(top_srcdir)/include \ - -I$(top_srcdir)/include/odp/arch/@ARCH_ABI@ \ - -I$(top_srcdir)/platform/@with_platform@/include \ - -I$(top_srcdir)/platform/@with_platform@/arch/@ARCH_DIR@ \ - -I$(top_builddir)/include \ - -I$(top_srcdir)/helper - ODP_PLATFORM=${with_platform} -AM_CPPFLAGS = $(INCFLAGS) +AM_CPPFLAGS = \ + $(ODP_INCLUDES) \ + $(HELPER_INCLUDES) AM_LDFLAGS = -static EXECUTABLES = chksum \ diff --git a/platform/Makefile.inc b/platform/Makefile.inc index 0086db779897..4714de0ee805 100644 --- a/platform/Makefile.inc +++ b/platform/Makefile.inc @@ -1,4 +1,4 @@ -LIB = $(top_builddir)/lib +include $(top_srcdir)/Makefile.inc pkgconfigdir = $(libdir)/pkgconfig pkgconfig_DATA = libodp-linux.pc diff --git a/platform/linux-generic/Makefile.am b/platform/linux-generic/Makefile.am index c5406760935e..703b12c702ea 100644 --- a/platform/linux-generic/Makefile.am +++ b/platform/linux-generic/Makefile.am @@ -3,14 +3,8 @@ include $(top_srcdir)/platform/Makefile.inc -AM_CPPFLAGS = -I$(srcdir)/include -AM_CPPFLAGS += -I$(top_srcdir)/include -AM_CPPFLAGS += -I$(top_srcdir)/include/odp/arch/@ARCH_ABI@ -AM_CPPFLAGS += -I$(top_builddir)/include -AM_CPPFLAGS += -Iinclude -AM_CPPFLAGS += -I$(top_srcdir)/platform/$(with_platform)/arch/$(ARCH_DIR) +AM_CPPFLAGS = $(ODP_INCLUDES) AM_CPPFLAGS += -I$(top_srcdir)/platform/$(with_platform)/arch/default -AM_CPPFLAGS += -Iinclude AM_CPPFLAGS += -DSYSCONFDIR=\"@sysconfdir@\" AM_CPPFLAGS += $(OPENSSL_CPPFLAGS) diff --git a/platform/linux-generic/test/Makefile.inc b/platform/linux-generic/test/Makefile.inc index dd21917ebfa7..05c89c9132cd 100644 --- a/platform/linux-generic/test/Makefile.inc +++ b/platform/linux-generic/test/Makefile.inc @@ -1,3 +1,5 @@ +include $(top_srcdir)/Makefile.inc + # The following definitions may be used by platform tests that wish to # build specific ODP applications, (i.e those whose do more than validation # test wrapping) @@ -7,16 +9,6 @@ AM_LDFLAGS = -static AM_CFLAGS = $(CUNIT_CFLAGS) LIBCUNIT_COMMON = $(top_builddir)/test/common/libcunit_common.la -LIB = $(top_builddir)/lib LIBODP = $(LIB)/libodphelper.la $(LIB)/libodp-linux.la $(DPDK_PMDS) INCCUNIT_COMMON = -I$(top_srcdir)/test/common -INCODP = \ - -I$(top_builddir)/include \ - -I$(top_builddir)/platform/@with_platform@/include \ - -I$(top_srcdir)/helper/include \ - -I$(top_srcdir)/include \ - -I$(top_srcdir)/include/odp/arch/@ARCH_ABI@ \ - -I$(top_srcdir)/platform/@with_platform@/arch/$(ARCH_DIR) \ - -I$(top_srcdir)/platform/@with_platform@/include \ - -I$(top_srcdir)/test diff --git a/platform/linux-generic/test/ring/Makefile.am b/platform/linux-generic/test/ring/Makefile.am index 376047559cc7..c08959d04f53 100644 --- a/platform/linux-generic/test/ring/Makefile.am +++ b/platform/linux-generic/test/ring/Makefile.am @@ -7,5 +7,5 @@ ring_main_SOURCES = \ ring_basic.c ring_stress.c ring_main_CPPFLAGS = $(AM_CPPFLAGS) -I$(top_builddir)/include \ - $(INCCUNIT_COMMON) $(INCODP) + $(INCCUNIT_COMMON) $(ODP_INCLUDES) $(HELPER_INCLUDES) ring_main_LDADD = $(LIBCUNIT_COMMON) $(LIBODP) diff --git a/platform/linux-generic/test/validation/api/shmem/Makefile.am b/platform/linux-generic/test/validation/api/shmem/Makefile.am index 131a511be73b..8753331e0dd2 100644 --- a/platform/linux-generic/test/validation/api/shmem/Makefile.am +++ b/platform/linux-generic/test/validation/api/shmem/Makefile.am @@ -12,11 +12,11 @@ shmem_linux_LDFLAGS = $(AM_LDFLAGS) -lrt shmem_odp1_SOURCES = shmem_odp1.c shmem_odp1.h shmem_common.h shmem_odp1_CFLAGS = $(AM_CFLAGS) \ $(INCCUNIT_COMMON) \ - $(INCODP) + $(ODP_INCLUDES) shmem_odp1_LDADD = $(LIBCUNIT_COMMON) $(LIBODP) shmem_odp2_SOURCES = shmem_odp2.c shmem_odp2.h shmem_common.h shmem_odp2_CFLAGS = $(AM_CFLAGS) \ $(INCCUNIT_COMMON) \ - $(INCODP) + $(ODP_INCLUDES) shmem_odp2_LDADD = $(LIBCUNIT_COMMON) $(LIBODP) diff --git a/test/Makefile.inc b/test/Makefile.inc index f7c0da21496c..26e188e7d969 100644 --- a/test/Makefile.inc +++ b/test/Makefile.inc @@ -1,21 +1,14 @@ -LIB = $(top_builddir)/lib +include $(top_srcdir)/Makefile.inc #in the following line, the libs using the symbols should come before #the libs containing them! The includer is given a chance to add things #before libodp by setting PRE_LDADD before the inclusion. LDADD = $(PRE_LDADD) $(LIB)/libodphelper.la $(LIB)/libodp-linux.la $(DPDK_PMDS) -INCFLAGS = \ - -I$(top_builddir)/platform/@with_platform@/include \ - -I$(top_srcdir)/helper/include \ - -I$(top_srcdir)/include \ - -I$(top_srcdir)/include/odp/arch/@ARCH_ABI@ \ - -I$(top_srcdir)/platform/@with_platform@/include \ - -I$(top_srcdir)/platform/@with_platform@/arch/@ARCH_DIR@ \ - -I$(top_srcdir)/test/common \ - -I$(top_builddir)/include - -AM_CPPFLAGS = $(INCFLAGS) +AM_CPPFLAGS = \ + $(ODP_INCLUDES) \ + $(HELPER_INCLUDES) \ + -I$(top_srcdir)/test/common AM_CFLAGS = $(CUNIT_CFLAGS) AM_LDFLAGS = -L$(LIB) -static