From patchwork Wed Sep 23 20:03:36 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Aaron Conole X-Patchwork-Id: 7120 Return-Path: X-Original-To: patchwork@dpdk.org Delivered-To: patchwork@dpdk.org Received: from [92.243.14.124] (localhost [IPv6:::1]) by dpdk.org (Postfix) with ESMTP id 6B1238E5D; Wed, 23 Sep 2015 22:03:43 +0200 (CEST) Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by dpdk.org (Postfix) with ESMTP id C46768E5A for ; Wed, 23 Sep 2015 22:03:41 +0200 (CEST) Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) by mx1.redhat.com (Postfix) with ESMTPS id CB511C0B91A9 for ; Wed, 23 Sep 2015 20:03:40 +0000 (UTC) Received: from aconole.bos.com (dhcp-25-190.bos.redhat.com [10.18.25.190]) by int-mx11.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id t8NK3d9B009323 for ; Wed, 23 Sep 2015 16:03:40 -0400 From: Aaron Conole To: dev@dpdk.org Date: Wed, 23 Sep 2015 16:03:36 -0400 Message-Id: <1443038616-28141-1-git-send-email-aconole@redhat.com> X-Scanned-By: MIMEDefang 2.68 on 10.5.11.24 Subject: [dpdk-dev] [PATCH] librte_vhost: eventfd_link: Update the makefile to build against an arbitrary kernel X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" The vHost eventlink driver is a kernel module that requires a kernel source/build directory to build the ko. Convert the fixed kernel build directory specifier to one which may be user specified on the command-line. Signed-off-by: Aaron Conole --- lib/librte_vhost/eventfd_link/Makefile | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lib/librte_vhost/eventfd_link/Makefile b/lib/librte_vhost/eventfd_link/Makefile index fc3927b..3140e8b 100644 --- a/lib/librte_vhost/eventfd_link/Makefile +++ b/lib/librte_vhost/eventfd_link/Makefile @@ -29,11 +29,13 @@ # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +RTE_KERNELDIR ?= /lib/modules/$(shell uname -r)/build + obj-m += eventfd_link.o all: - make -C /lib/modules/$(shell uname -r)/build M=$(PWD) modules + make -C $(RTE_KERNELDIR) M=$(PWD) modules clean: - make -C /lib/modules/$(shell uname -r)/build M=$(PWD) clean + make -C $(RTE_KERNELDIR) M=$(PWD) clean