zookeeper: refactor to use finalAttrs

- wrap derivation in `stdenv.mkDerivation (finalAttrs: { ... })`
- replace `${pname}`/`${version}` with `${finalAttrs.version}` in `src` URL
- update `meta.changelog` to interpolate `finalAttrs.version`

This removes reliance on `rec` and ensures attribute references are
scoped through `finalAttrs`, improving clarity and consistency with
current Nixpkgs conventions.

+4 -4
+4 -4
pkgs/by-name/zo/zookeeper/package.nix
··· 13 13 # https://zookeeper.apache.org/doc/r3.9.2/zookeeperAdmin.html#sc_requiredSoftware 14 14 jre = jdk11_headless; 15 15 in 16 - stdenv.mkDerivation rec { 16 + stdenv.mkDerivation (finalAttrs: { 17 17 pname = "zookeeper"; 18 18 version = "3.9.3"; 19 19 20 20 src = fetchurl { 21 - url = "mirror://apache/zookeeper/${pname}-${version}/apache-${pname}-${version}-bin.tar.gz"; 21 + url = "mirror://apache/zookeeper/zookeeper-${finalAttrs.version}/apache-zookeeper-${finalAttrs.version}-bin.tar.gz"; 22 22 hash = "sha512-1E2HDBaRZi778ai68YWckBuCDcX/Fjs26BvrJ7b7880xtfHwdWl+2q9tPnpMsMyS+STc/2SylO8T1TVYm9rxQw=="; 23 23 }; 24 24 ··· 53 53 meta = { 54 54 homepage = "https://zookeeper.apache.org"; 55 55 description = "Apache Zookeeper"; 56 - changelog = "https://zookeeper.apache.org/doc/r${version}/releasenotes.html"; 56 + changelog = "https://zookeeper.apache.org/doc/r${finalAttrs.version}/releasenotes.html"; 57 57 license = lib.licenses.asl20; 58 58 maintainers = with lib.maintainers; [ 59 59 nathan-gs ··· 62 62 platforms = lib.platforms.unix; 63 63 sourceProvenance = with lib.sourceTypes; [ binaryBytecode ]; 64 64 }; 65 - } 65 + })