libxt: refactor, move to pkgs/by-name and rename from xorg.libXt

relevant changes:
- removes the `sed 's,^as_dummy.*,as_dummy="\$PATH",' -i configure`
because as in libx11 it probably doesn't do anything

+87 -63
+82
pkgs/by-name/li/libxt/package.nix
··· 1 + { 2 + lib, 3 + stdenv, 4 + fetchurl, 5 + buildPackages, 6 + pkg-config, 7 + xorgproto, 8 + libx11, 9 + libsm, 10 + writeScript, 11 + testers, 12 + }: 13 + stdenv.mkDerivation (finalAttrs: { 14 + pname = "libxt"; 15 + version = "1.3.1"; 16 + 17 + outputDoc = "devdoc"; 18 + outputs = [ 19 + "out" 20 + "dev" 21 + "devdoc" 22 + ]; 23 + 24 + src = fetchurl { 25 + url = "mirror://xorg/individual/lib/libXt-${finalAttrs.version}.tar.xz"; 26 + hash = "sha256-4Kd0szMk9NTAWxmepFBQ+HIGWG2BZV+L7026Q02TEog="; 27 + }; 28 + 29 + strictDeps = true; 30 + 31 + depsBuildBuild = [ buildPackages.stdenv.cc ]; 32 + 33 + nativeBuildInputs = [ pkg-config ]; 34 + 35 + buildInputs = [ 36 + xorgproto 37 + libx11 38 + libsm 39 + ]; 40 + 41 + propagatedBuildInputs = [ 42 + xorgproto 43 + libx11 44 + # needs to be propagated because of header file dependencies 45 + libsm 46 + ]; 47 + 48 + configureFlags = 49 + lib.optional (stdenv.hostPlatform != stdenv.buildPlatform) "--enable-malloc0returnsnull" 50 + ++ lib.optional (stdenv.targetPlatform.useLLVM or false) "ac_cv_path_RAWCPP=cpp"; 51 + 52 + env = { 53 + CPP = if stdenv.hostPlatform.isDarwin then "clang -E -" else "${stdenv.cc.targetPrefix}cc -E -"; 54 + }; 55 + 56 + passthru = { 57 + updateScript = writeScript "update-${finalAttrs.pname}" '' 58 + #!/usr/bin/env nix-shell 59 + #!nix-shell -i bash -p common-updater-scripts 60 + version="$(list-directory-versions --pname libXt \ 61 + --url https://xorg.freedesktop.org/releases/individual/lib/ \ 62 + | sort -V | tail -n1)" 63 + update-source-version ${finalAttrs.pname} "$version" 64 + ''; 65 + tests.pkg-config = testers.testMetaPkgConfig finalAttrs.finalPackage; 66 + }; 67 + 68 + meta = { 69 + description = "X Toolkit Intrinsics library"; 70 + homepage = "https://gitlab.freedesktop.org/xorg/lib/libxt"; 71 + license = with lib.licenses; [ 72 + mit 73 + hpndSellVariant 74 + hpnd 75 + mitOpenGroup 76 + x11 77 + ]; 78 + maintainers = [ ]; 79 + pkgConfigModules = [ "xt" ]; 80 + platforms = lib.platforms.unix; 81 + }; 82 + })
+2 -40
pkgs/servers/x11/xorg/default.nix
··· 25 25 libxfixes, 26 26 libxrandr, 27 27 libxrender, 28 + libxt, 28 29 libxv, 29 30 lndir, 30 31 luit, ··· 102 103 libXfixes = libxfixes; 103 104 libXrandr = libxrandr; 104 105 libXrender = libxrender; 106 + libXt = libxt; 105 107 libXv = libxv; 106 108 utilmacros = util-macros; 107 109 xcbproto = xcb-proto; ··· 2390 2392 passthru.tests.pkg-config = testers.testMetaPkgConfig finalAttrs.finalPackage; 2391 2393 meta = { 2392 2394 pkgConfigModules = [ "xres" ]; 2393 - platforms = lib.platforms.unix; 2394 - }; 2395 - }) 2396 - ) { }; 2397 - 2398 - # THIS IS A GENERATED FILE. DO NOT EDIT! 2399 - libXt = callPackage ( 2400 - { 2401 - stdenv, 2402 - pkg-config, 2403 - fetchurl, 2404 - libICE, 2405 - xorgproto, 2406 - libSM, 2407 - libX11, 2408 - testers, 2409 - }: 2410 - stdenv.mkDerivation (finalAttrs: { 2411 - pname = "libXt"; 2412 - version = "1.3.1"; 2413 - builder = ./builder.sh; 2414 - src = fetchurl { 2415 - url = "mirror://xorg/individual/lib/libXt-1.3.1.tar.xz"; 2416 - sha256 = "120jjd6l7fjdxy5myrc1dmc0cwpqa18a97hrbg0d9x146frp99z0"; 2417 - }; 2418 - hardeningDisable = [ 2419 - "bindnow" 2420 - "relro" 2421 - ]; 2422 - strictDeps = true; 2423 - nativeBuildInputs = [ pkg-config ]; 2424 - buildInputs = [ 2425 - libICE 2426 - xorgproto 2427 - libSM 2428 - libX11 2429 - ]; 2430 - passthru.tests.pkg-config = testers.testMetaPkgConfig finalAttrs.finalPackage; 2431 - meta = { 2432 - pkgConfigModules = [ "xt" ]; 2433 2395 platforms = lib.platforms.unix; 2434 2396 }; 2435 2397 })
+3
pkgs/servers/x11/xorg/generate-expr-from-tarballs.pl
··· 55 55 $pcMap{"xfixes"} = "libXfixes"; 56 56 $pcMap{"xrandr"} = "libXrandr"; 57 57 $pcMap{"xrender"} = "libXrender"; 58 + $pcMap{"xt"} = "libXt"; 58 59 $pcMap{"xtrans"} = "xtrans"; 59 60 $pcMap{"xv"} = "libXv"; 60 61 $pcMap{"\$PIXMAN"} = "pixman"; ··· 320 321 libxfixes, 321 322 libxrandr, 322 323 libxrender, 324 + libxt, 323 325 libxv, 324 326 lndir, 325 327 luit, ··· 397 399 libXfixes = libxfixes; 398 400 libXrandr = libxrandr; 399 401 libXrender = libxrender; 402 + libXt = libxt; 400 403 libXv = libxv; 401 404 utilmacros = util-macros; 402 405 xcbproto = xcb-proto;
-22
pkgs/servers/x11/xorg/overrides.nix
··· 217 217 }; 218 218 }); 219 219 220 - # Propagate some build inputs because of header file dependencies. 221 - # Note: most of these are in Requires.private, so maybe builder.sh 222 - # should propagate them automatically. 223 - libXt = super.libXt.overrideAttrs (attrs: { 224 - preConfigure = '' 225 - sed 's,^as_dummy.*,as_dummy="\$PATH",' -i configure 226 - ''; 227 - configureFlags = 228 - attrs.configureFlags or [ ] 229 - ++ malloc0ReturnsNullCrossFlag 230 - ++ lib.optional (stdenv.targetPlatform.useLLVM or false) "ac_cv_path_RAWCPP=cpp"; 231 - propagatedBuildInputs = attrs.propagatedBuildInputs or [ ] ++ [ xorg.libSM ]; 232 - depsBuildBuild = [ buildPackages.stdenv.cc ]; 233 - CPP = if stdenv.hostPlatform.isDarwin then "clang -E -" else "${stdenv.cc.targetPrefix}cc -E -"; 234 - outputDoc = "devdoc"; 235 - outputs = [ 236 - "out" 237 - "dev" 238 - "devdoc" 239 - ]; 240 - }); 241 - 242 220 libXcomposite = super.libXcomposite.overrideAttrs (attrs: { 243 221 outputs = [ 244 222 "out"
-1
pkgs/servers/x11/xorg/tarballs.list
··· 159 159 mirror://xorg/individual/lib/libXScrnSaver-1.2.4.tar.xz 160 160 mirror://xorg/individual/lib/libxshmfence-1.3.3.tar.xz 161 161 mirror://xorg/individual/lib/libXTrap-1.0.1.tar.bz2 162 - mirror://xorg/individual/lib/libXt-1.3.1.tar.xz 163 162 mirror://xorg/individual/lib/libXtst-1.2.5.tar.xz 164 163 mirror://xorg/individual/lib/libXvMC-1.0.14.tar.xz 165 164 mirror://xorg/individual/lib/libXxf86dga-1.1.6.tar.xz