mirror of
https://github.com/simplex-chat/simplex-chat.git
synced 2026-11-11 11:47:44 +00:00
Apply the API 26 dependency before planning every ghc914-sh Android project, including the auxiliary iserv projects and evalWith variants. Preserve the GNU headers and library paths in the plan and ghc-internal registration, and compile the static iconv archives with PIC for libsimplex.so. Validated Nix parsing, duplicate module handling, the actual ARMv7 iserv plan arguments, and a real static/PIC libiconv build. The focused ghc-internal build remains pending.
17 lines
730 B
Nix
17 lines
730 B
Nix
final: prev:
|
|
prev.lib.optionalAttrs prev.stdenv.hostPlatform.isAndroid {
|
|
# haskell.nix supplies static-only GNU libiconv on Android. Its objects
|
|
# also become part of libsimplex.so, so build the archive with PIC.
|
|
libiconv = prev.libiconv.overrideAttrs (old: {
|
|
configureFlags = old.configureFlags ++ [ "--with-pic" ];
|
|
});
|
|
haskell-nix = prev.haskell-nix // {
|
|
# iserv has its own boot-library projects, including evalWith variants.
|
|
# Add the paths before each plan, rather than only to the app's modules.
|
|
cabalProject' = projectModule: prev.haskell-nix.cabalProject' (
|
|
[ ./android-iconv-project.nix ]
|
|
++ (if builtins.isList projectModule then projectModule else [ projectModule ])
|
|
);
|
|
};
|
|
}
|