-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Flake lock file updates: • Updated input 'nixpkgs': 'github:NixOS/nixpkgs/1e3deb3d8a86a870d925760db1a5adecc64d329d' (2024-06-27) → 'github:NixOS/nixpkgs/79ed718bf5fa685c44ed4607c314527ff832e53f' (2024-08-26) Upgrades libxml2 to 2.13, which includes some breaking changes. Since fixing them in older PHP versions would require extensive patching, let’s just pin the EOL PHP versions to a vendored libxml2 2.12. And because we just use it for PHP, we pare the libxml2 package down a bit (e.g. no Python or static support).
- Loading branch information
Showing
3 changed files
with
91 additions
and
8 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
{ | ||
stdenv, | ||
lib, | ||
fetchurl, | ||
pkg-config, | ||
autoreconfHook, | ||
findXMLCatalogs, | ||
libiconv, | ||
icuSupport ? false, | ||
icu, | ||
}: | ||
|
||
stdenv.mkDerivation (finalAttrs: { | ||
pname = "libxml2"; | ||
version = "2.12.9"; | ||
|
||
outputs = [ | ||
"bin" | ||
"dev" | ||
"out" | ||
]; | ||
outputMan = "bin"; | ||
|
||
src = fetchurl { | ||
url = "mirror://gnome/sources/libxml2/${lib.versions.majorMinor finalAttrs.version}/libxml2-${finalAttrs.version}.tar.xz"; | ||
hash = "sha256-WZEttTarVqOZZInqApl2jHvP/lcWnwI15/liqR9INZA="; | ||
}; | ||
|
||
strictDeps = true; | ||
|
||
nativeBuildInputs = [ | ||
pkg-config | ||
autoreconfHook | ||
]; | ||
|
||
propagatedBuildInputs = [ | ||
findXMLCatalogs | ||
] ++ lib.optionals stdenv.isDarwin [ libiconv ] ++ lib.optionals icuSupport [ icu ]; | ||
|
||
configureFlags = [ | ||
"--exec-prefix=${placeholder "dev"}" | ||
(lib.withFeature icuSupport "icu") | ||
"--without-python" | ||
]; | ||
|
||
enableParallelBuilding = true; | ||
|
||
doCheck = (stdenv.hostPlatform == stdenv.buildPlatform) && stdenv.hostPlatform.libc != "musl"; | ||
preCheck = lib.optional stdenv.isDarwin '' | ||
export DYLD_LIBRARY_PATH="$PWD/.libs:$DYLD_LIBRARY_PATH" | ||
''; | ||
|
||
preConfigure = lib.optionalString (lib.versionAtLeast stdenv.hostPlatform.darwinMinVersion "11") '' | ||
MACOSX_DEPLOYMENT_TARGET=10.16 | ||
''; | ||
|
||
postFixup = '' | ||
moveToOutput bin/xml2-config "$dev" | ||
moveToOutput lib/xml2Conf.sh "$dev" | ||
''; | ||
|
||
meta = with lib; { | ||
homepage = "https://gitlab.gnome.org/GNOME/libxml2"; | ||
description = "XML parsing library for C"; | ||
license = licenses.mit; | ||
platforms = platforms.all; | ||
maintainers = with maintainers; [ | ||
eelco | ||
jtojnar | ||
]; | ||
pkgConfigModules = [ "libxml-2.0" ]; | ||
}; | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters