diff options
author | Stanislaw Kardach <skardach@marvell.com> | 2020-04-23 15:16:53 +0200 |
---|---|---|
committer | Matias Elo <matias.elo@nokia.com> | 2020-06-23 08:53:43 +0300 |
commit | ceaad3a190d46a4193f87fb838b27ec6da134991 (patch) | |
tree | b445897870374f66f92accb3a99fa0340838702a /platform/linux-generic/m4 | |
parent | a2c38a27e67f36b5a11a3e3979dc34dd1d310346 (diff) |
build: allow per-platform lib name
So far the build system (helper, examples, tests) expected that the ODP
library is named libodp-linux. However that's only a recommended library
name. Therefore move the library name specification to the platform
automake files. More precisely platform has to define the following:
1. In configure.m4:
ODP_LIB_NAME=<name>
2. In Makefile.am:
lib_LTLIBRARIES += $(LIB)/lib<name>.la
Where <name> is the library name. Please note that lib_LTLIBRARIES has
to be explicitly named (cannot use ODP_LIB_NAME variable), otherwise
automake will fail to generate compile target.
Trying to perform a substitutions in it is only possible with full
library name substitution (see [1]), however then all possible library
names have to be defined in EXTRA_LTLIBRARIES which cannot contain
substitutions. This would effectively replace one hard-coded place with
another.
[1] https://www.gnu.org/software/automake/manual/
html_node/Conditional-Libtool-Libraries.html
Signed-off-by: Stanislaw Kardach <skardach@marvell.com>
Reviewed-by: Matias Elo <matias.elo@nokia.com>
Diffstat (limited to 'platform/linux-generic/m4')
-rw-r--r-- | platform/linux-generic/m4/configure.m4 | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/platform/linux-generic/m4/configure.m4 b/platform/linux-generic/m4/configure.m4 index bcd55b7c5..06bff0669 100644 --- a/platform/linux-generic/m4/configure.m4 +++ b/platform/linux-generic/m4/configure.m4 @@ -1,4 +1,5 @@ ODP_IMPLEMENTATION_NAME="odp-linux" +ODP_LIB_NAME="odp-linux" ODP_VISIBILITY ODP_ATOMIC |