summaryrefslogtreecommitdiff
path: root/var
diff options
context:
space:
mode:
authorWouter Deconinck <wdconinc@gmail.com>2024-11-04 07:20:09 -0600
committerGitHub <noreply@github.com>2024-11-04 07:20:09 -0600
commitb95936f752f55ae4e1a70d4301feab2406d9dea8 (patch)
tree72a7e280b922f11010151274581ea5251957e9cc /var
parent8d0856d1cc3f8d097b8f4a7e5a18ad662b8434c5 (diff)
downloadspack-b95936f752f55ae4e1a70d4301feab2406d9dea8.tar.gz
spack-b95936f752f55ae4e1a70d4301feab2406d9dea8.tar.bz2
spack-b95936f752f55ae4e1a70d4301feab2406d9dea8.tar.xz
spack-b95936f752f55ae4e1a70d4301feab2406d9dea8.zip
zabbix: add v5.0.44, v6.0.34, v7.0.4 (fix CVEs) (#47001)
* zabbix: add v5.0.44, v6.0.34, v7.0.4 (fix CVEs) * [@spackbot] updating style on behalf of wdconinc * zabbix: use f-string * zabbix: fix f-string quoting * zabbix: use mysql-client * @wdconic, this fixes the mysql client virtual for me --------- Co-authored-by: wdconinc <wdconinc@users.noreply.github.com> Co-authored-by: Bernhard Kaindl <bernhardkaindl7@gmail.com>
Diffstat (limited to 'var')
-rw-r--r--var/spack/repos/builtin/packages/mysql/package.py9
-rw-r--r--var/spack/repos/builtin/packages/zabbix/package.py46
2 files changed, 44 insertions, 11 deletions
diff --git a/var/spack/repos/builtin/packages/mysql/package.py b/var/spack/repos/builtin/packages/mysql/package.py
index 42288aaab7..1e7cb834d3 100644
--- a/var/spack/repos/builtin/packages/mysql/package.py
+++ b/var/spack/repos/builtin/packages/mysql/package.py
@@ -226,3 +226,12 @@ class Mysql(CMakePackage):
if "python" in self.spec and self.spec.satisfies("@:7"):
self._fix_dtrace_shebang(env)
+
+ @run_before("install")
+ def fixup_mysqlconfig(self):
+ if not self.spec.satisfies("platform=windows"):
+ # mysql uses spack libz but exports -lzlib to its dependencies. Fix that:
+ with working_dir(self.build_directory):
+ for config in ("scripts/mysql_config", "scripts/mysqlclient.pc"):
+ if os.path.exists(config):
+ filter_file(" -lzlib ", " -lz ", config)
diff --git a/var/spack/repos/builtin/packages/zabbix/package.py b/var/spack/repos/builtin/packages/zabbix/package.py
index aeb8bfd1d1..a84097c1c7 100644
--- a/var/spack/repos/builtin/packages/zabbix/package.py
+++ b/var/spack/repos/builtin/packages/zabbix/package.py
@@ -11,35 +11,59 @@ class Zabbix(AutotoolsPackage):
such as networks, servers, VMs, applications and the cloud."""
homepage = "https://www.zabbix.com"
- url = "https://github.com/zabbix/zabbix/archive/5.0.3.tar.gz"
+ url = "https://github.com/zabbix/zabbix/archive/refs/tags/5.0.3.tar.gz"
- license("GPL-2.0-or-later")
+ license("AGPL-3.0-only", when="@7:", checked_by="wdconinc")
+ license("GPL-2.0-or-later", when="@:6", checked_by="wdconinc")
- version("5.0.3", sha256="d579c5fa4e9065e8041396ace24d7132521ef5054ce30dfd9d151cbb7f0694ec")
- version("4.0.24", sha256="c7e4962d745277d67797d90e124555ce27d198822a7e65c55d86aee45d3e93fc")
- version("4.0.23", sha256="652143614f52411cad47db64e93bf3ba1cd547d6ca9591296223b5f0528b3b61")
+ version("7.0.4", sha256="73aa6b47bd4078587589b30f09671fb30c7743f5b57e81ea8e9bd5a7c5f221c7")
+ version("6.0.34", sha256="e60558911230d27ffad98850e414b46e318c9d41591a6ff65a255c0810cfcb8b")
+ version("5.0.44", sha256="f8ee86fd21f0f57e7fad68387271b995c1e5cc402d517cd7df5d5221fd6129fd")
+ with default_args(deprecated=True):
+ # https://nvd.nist.gov/vuln/detail/CVE-2023-32724
+ version("5.0.3", sha256="d579c5fa4e9065e8041396ace24d7132521ef5054ce30dfd9d151cbb7f0694ec")
+ # https://nvd.nist.gov/vuln/detail/CVE-2019-17382
+ version(
+ "4.0.24", sha256="c7e4962d745277d67797d90e124555ce27d198822a7e65c55d86aee45d3e93fc"
+ )
+ version(
+ "4.0.23", sha256="652143614f52411cad47db64e93bf3ba1cd547d6ca9591296223b5f0528b3b61"
+ )
- depends_on("c", type="build") # generated
- depends_on("cxx", type="build") # generated
+ depends_on("c", type="build")
+ depends_on("cxx", type="build")
depends_on("autoconf", type="build")
+ depends_on("autoconf-archive", type="build")
depends_on("automake", type="build")
depends_on("libtool", type="build")
depends_on("m4", type="build")
- depends_on("mysql")
+ depends_on("pkgconfig", type="build")
+ depends_on("mysql-client")
+ # Older versions of mysql use openssl-1.x, causing build issues:
+ depends_on("mysql@8.0.35:", when="^[virtuals=mysql-client] mysql")
depends_on("libevent")
depends_on("pcre")
depends_on("go")
+ def autoreconf(self, spec, prefix):
+ Executable("./bootstrap.sh")()
+
def configure_args(self):
+ mysql_prefix = self.spec["mysql-client"].prefix
+ if self.spec.satisfies("^[virtuals=mysql-client] mysql"):
+ mysql_config = mysql_prefix.bin.mysql_config
+ else:
+ mysql_config = mysql_prefix.bin.mariadb_config
+
args = [
"--enable-server",
"--enable-proxy",
"--enable-agent",
"--enable-agent2",
- "--with-mysql",
- "--with-libevent=%s" % self.spec["libevent"].prefix,
- "--with-libpcre=%s" % self.spec["pcre"].prefix,
+ f"--with-mysql={mysql_config}",
+ f"--with-libevent={self.spec['libevent'].prefix}",
+ f"--with-libpcre={self.spec['pcre'].prefix}",
]
return args