From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 95D11A0555; Wed, 19 Feb 2020 20:13:40 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id BBF831B951; Wed, 19 Feb 2020 20:13:39 +0100 (CET) Received: from mail-pg1-f195.google.com (mail-pg1-f195.google.com [209.85.215.195]) by dpdk.org (Postfix) with ESMTP id AAE593B5 for ; Wed, 19 Feb 2020 20:13:38 +0100 (CET) Received: by mail-pg1-f195.google.com with SMTP id w21so564714pgl.9 for ; Wed, 19 Feb 2020 11:13:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=babayev.com; s=google; h=from:to:cc:subject:date:message-id; bh=BPNMco1N07iGa15TKIxpYBFF+pv09wCR6HrWkzZMFIs=; b=MH4TVY5oKOSVgI6vpVJevi6IPDW+MFtUqtQqRD74I8ZQYN0ErXmLtoIJYkbFzFgDrV MllFv6iaOELfSpEi0/QgPnGrxx1q9TsuRx3cpaoBYYvjH2Op/55fkzUqYCTps/p+Ds7M mW/PqlUoe288QFtCy8y8tGof6xi1h3nRd90m4= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=BPNMco1N07iGa15TKIxpYBFF+pv09wCR6HrWkzZMFIs=; b=fIvUqHOXMt5Sz9yXw0vO08njzvylefbiYq8IE5KpCoEl9HPmXx+N4NKLGoOhGdtAGS p5NZ070/ApWUO7DEbgsmx47bgEFOg/c/ZxYq+MZZ4jlSxUsxOY98LTsOISkipMR1vdd1 Mal6caSCP9pRH6qlq1LA4THFTMfVwTxpz7St/GPDk4AKk/QbdnFTsq1FIKOxEfyQkRpt DgBbvuZJa/EnUEdqomF43xmze9uiRkR4TlRnqXfhkazPl/BxctKoAeARdleWy/RrgRD1 WoenDLliEZfchT92UqlUzEvrSs/swISnJpabXYWMCSrHpszLGESbBc3PAaKvWIIgqneL heDg== X-Gm-Message-State: APjAAAUZE4RtjEpLFBlfaJkzYfJW1OhXFMqJwAu00dqBuhDD8YDgxQht XZonfmhY9ANnP4/bGU/vBzottG2Nxlkjug== X-Google-Smtp-Source: APXvYqzvDX5MfR1AAZgIP0jryEFJPyZVcIsfU8g5Pn2T1BgKU+D16sdK05Rhyll5LkfpyoclGIJ8fA== X-Received: by 2002:a63:790f:: with SMTP id u15mr28131764pgc.172.1582139617247; Wed, 19 Feb 2020 11:13:37 -0800 (PST) Received: from baku.babayev.lan (50-47-143-95.evrt.wa.frontiernet.net. [50.47.143.95]) by smtp.gmail.com with ESMTPSA id c26sm405068pfj.8.2020.02.19.11.13.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 19 Feb 2020 11:13:36 -0800 (PST) From: Ruslan Babayev To: dev@dpdk.org Cc: Ruslan Babayev Date: Wed, 19 Feb 2020 11:13:26 -0800 Message-Id: <20200219191326.35842-1-ruslan@babayev.com> X-Mailer: git-send-email 2.17.1 Subject: [dpdk-dev] [PATCH] build: add combined libs X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Add combined libdpdk.a and libdpdk.so libs for Meson similar to how it's done for Make builds Signed-off-by: Ruslan Babayev --- buildtools/group-libs.sh | 2 ++ buildtools/meson.build | 1 + meson.build | 17 +++++++++++++++++ 3 files changed, 20 insertions(+) create mode 100755 buildtools/group-libs.sh diff --git a/buildtools/group-libs.sh b/buildtools/group-libs.sh new file mode 100755 index 000000000..b6e4c1c35 --- /dev/null +++ b/buildtools/group-libs.sh @@ -0,0 +1,2 @@ +#!/bin/sh +echo 'GROUP (' $(echo $* | xargs -n1 basename | sort | xargs) ')' diff --git a/buildtools/meson.build b/buildtools/meson.build index 9812917e5..eac8bc4ff 100644 --- a/buildtools/meson.build +++ b/buildtools/meson.build @@ -6,6 +6,7 @@ subdir('pmdinfogen') pkgconf = find_program('pkg-config', 'pkgconf', required: false) pmdinfo = find_program('gen-pmdinfo-cfile.sh') list_dir_globs = find_program('list-dir-globs.py') +group_libs = find_program('group-libs.sh') check_experimental_syms = find_program('check-experimental-syms.sh') ldflags_ibverbs_static = find_program('options-ibverbs-static.sh') diff --git a/meson.build b/meson.build index b7ae9c8d9..eb6974d35 100644 --- a/meson.build +++ b/meson.build @@ -61,6 +61,23 @@ configure_file(output: build_cfg, install_dir: join_paths(get_option('includedir'), get_option('include_subdir_arch'))) + +custom_target('group_shared_libs', + input: dpdk_libraries, + output: 'libdpdk.so', + capture: true, + install: true, + install_dir: get_option('libdir'), + command: [group_libs, '@INPUT@']) + +custom_target('group_static_libs', + input: dpdk_static_libraries + dpdk_drivers, + output: 'libdpdk.a', + capture: true, + install: true, + install_dir: get_option('libdir'), + command: [group_libs, '@INPUT@']) + # for static builds, include the drivers as libs and we need to "whole-archive" # them. dpdk_drivers = ['-Wl,--whole-archive'] + dpdk_drivers + ['-Wl,--no-whole-archive'] -- 2.17.1