Description
This is related to #1068
I encountered the same problem with zlib. Even after following the steps mentioned in the issue, I still run into problems when using ob run AND nix-build. When I try to use nix-build, the zlib issue reappears, because I need a frontend dependency in the backend executable. If I remove this dependency, I can't run the frontend app. I also tried serving the compiled frontend.jsexe statically, but without success.
Here's my default.nix:
{ system ? builtins.currentSystem
, obelisk ? import ./.obelisk/impl {
inherit system;
iosSdkVersion = "16.1";
# You must accept the Android Software Development Kit License Agreement at
# https://developer.android.com/studio/terms in order to build Android apps.
# Uncomment and set this to `true` to indicate your acceptance:
# config.android_sdk.accept_license = false;
# In order to use Let's Encrypt for HTTPS deployments you must accept
# their terms of service at https://letsencrypt.org/repository/.
# Uncomment and set this to `true` to indicate your acceptance:
# terms.security.acme.acceptTerms = false;
}
}:
with obelisk;
project ./. ({ pkgs, hackGet, ... }: {
android.applicationId = "systems.obsidian.obelisk.examples.minimal";
android.displayName = "Obelisk Minimal Example";
ios.bundleIdentifier = "systems.obsidian.obelisk.examples.minimal";
ios.bundleName = "Obelisk Minimal Example";
overrides = self: super: {
frontend = super.frontend.overrideScope (self: super: {
fsnotify = pkgs.haskell.lib.dontCheck (self.callHackage "fsnotify" "0.2.1.2" {});
zlib = pkgs.haskell.lib.dontHaddock (super.zlib.override { zlib = null; });
});
backend = super.backend.overrideScope (self: super: {
frontend = super.frontend;
zlib = pkgs.haskell.lib.dontHaddock (super.zlib.override {
zlib = pkgs.zlib;
});
});
};
})
Any suggestions or ideas on how to resolve this?