diff --git a/pkgs/development/libraries/ustr/default.nix b/pkgs/by-name/us/ustr/package.nix similarity index 69% rename from pkgs/development/libraries/ustr/default.nix rename to pkgs/by-name/us/ustr/package.nix index 69d74046d789..0da93206752b 100644 --- a/pkgs/development/libraries/ustr/default.nix +++ b/pkgs/by-name/us/ustr/package.nix @@ -1,4 +1,8 @@ -{ lib, stdenv, fetchgit }: +{ + lib, + stdenv, + fetchgit, +}: stdenv.mkDerivation (finalAttrs: { pname = "ustr"; @@ -18,15 +22,19 @@ stdenv.mkDerivation (finalAttrs: { # Fix detection of stdint.h postPatch = '' - sed -i 's,\(have_stdint_h\)=0,\1=1,g' Makefile - sed -i 's,\(USTR_CONF_HAVE_STDINT_H\) 0,\1 1,g' ustr-import.in + substituteInPlace Makefile \ + --replace-fail "have_stdint_h=0" "have_stdint_h=1" + + cat ustr-import.in | grep USTR_CONF + substituteInPlace ustr-import.in \ + --replace-fail "USTR_CONF_HAVE_STDINT_H 0" "USTR_CONF_HAVE_STDINT_H 1" ''; - preBuild = '' - makeFlagsArray+=("prefix=$out") - makeFlagsArray+=("LDCONFIG=echo") - makeFlagsArray+=("HIDE=") - ''; + makeFlags = [ + "prefix=${placeholder "out"}" + "LDCONFIG=echo" + "HIDE=" + ]; # Remove debug libraries postInstall = '' diff --git a/pkgs/development/libraries/ustr/va_args.patch b/pkgs/by-name/us/ustr/va_args.patch similarity index 100% rename from pkgs/development/libraries/ustr/va_args.patch rename to pkgs/by-name/us/ustr/va_args.patch diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index a38897c6125b..b9d42b592a6a 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -24804,8 +24804,6 @@ with pkgs; unixODBCDrivers = recurseIntoAttrs (callPackages ../development/libraries/unixODBCDrivers { }); - ustr = callPackage ../development/libraries/ustr { }; - usrsctp = callPackage ../development/libraries/usrsctp { }; usbredir = callPackage ../development/libraries/usbredir { };