libzmq: add variants "docs", "libbsd" (#28503)
This commit is contained in:
parent
03e93345b1
commit
7e5afd1e73
1 changed files with 14 additions and 4 deletions
|
@ -34,6 +34,13 @@ class Libzmq(AutotoolsPackage):
|
||||||
variant("drafts", default=False,
|
variant("drafts", default=False,
|
||||||
description="Build and install draft classes and methods")
|
description="Build and install draft classes and methods")
|
||||||
|
|
||||||
|
variant("docs", default=True,
|
||||||
|
description="Build documentation")
|
||||||
|
|
||||||
|
variant("libbsd", default=True,
|
||||||
|
description="Use strlcpy from libbsd " +
|
||||||
|
"(will use own implementation if false)")
|
||||||
|
|
||||||
depends_on("libsodium", when='+libsodium')
|
depends_on("libsodium", when='+libsodium')
|
||||||
depends_on("libsodium@:1.0.3", when='+libsodium@:4.1.2')
|
depends_on("libsodium@:1.0.3", when='+libsodium@:4.1.2')
|
||||||
|
|
||||||
|
@ -41,11 +48,11 @@ class Libzmq(AutotoolsPackage):
|
||||||
depends_on('automake', type='build', when='@develop')
|
depends_on('automake', type='build', when='@develop')
|
||||||
depends_on('libtool', type='build', when='@develop')
|
depends_on('libtool', type='build', when='@develop')
|
||||||
depends_on('pkgconfig', type='build')
|
depends_on('pkgconfig', type='build')
|
||||||
depends_on('docbook-xml', type='build')
|
depends_on('docbook-xml', type='build', when='+docs')
|
||||||
depends_on('docbook-xsl', type='build')
|
depends_on('docbook-xsl', type='build', when='+docs')
|
||||||
|
|
||||||
depends_on('libbsd', type='link', when='@4.3.3: platform=linux')
|
depends_on('libbsd', when='@4.3.3: platform=linux +libbsd')
|
||||||
depends_on('libbsd', type='link', when='@4.3.3: platform=cray')
|
depends_on('libbsd', when='@4.3.3: platform=cray +libbsd')
|
||||||
|
|
||||||
conflicts('%gcc@8:', when='@:4.2.2')
|
conflicts('%gcc@8:', when='@:4.2.2')
|
||||||
|
|
||||||
|
@ -68,9 +75,12 @@ def configure_args(self):
|
||||||
config_args = []
|
config_args = []
|
||||||
|
|
||||||
config_args.extend(self.enable_or_disable("drafts"))
|
config_args.extend(self.enable_or_disable("drafts"))
|
||||||
|
config_args.extend(self.enable_or_disable("libbsd"))
|
||||||
|
|
||||||
if '+libsodium' in self.spec:
|
if '+libsodium' in self.spec:
|
||||||
config_args.append('--with-libsodium')
|
config_args.append('--with-libsodium')
|
||||||
|
if '~docs' in self.spec:
|
||||||
|
config_args.append('--without-docs')
|
||||||
if 'clang' in self.compiler.cc:
|
if 'clang' in self.compiler.cc:
|
||||||
config_args.append("CFLAGS=-Wno-gnu")
|
config_args.append("CFLAGS=-Wno-gnu")
|
||||||
config_args.append("CXXFLAGS=-Wno-gnu")
|
config_args.append("CXXFLAGS=-Wno-gnu")
|
||||||
|
|
Loading…
Reference in a new issue