Jakub Sokołowski 42fb40476c
nix: reafactoring of status-go builds
Changes:
- Fixed `nix/status-go/desktop` builds
- Dropped nimbus wrapper for `status-go` for now
- Split `status-go` builds into subfolders: `mobile`, `desktop`
- Fixed shells for desktop builds: `linux`,`macos`,`windows`
- Added `make status-go-*` targets for building them
- Moved source management to `nix/status-go/source.nix`
- Moved `nix/status-go/build.nix` into `nix/status-go/mobile`
- Moved `nix/desktop/cmake/qtkeychain` to `nix/pkgs/qtkeychain-src`
- Moved `nix/desktop/linux/linuxdeployqt` to `nix/pkgs`
- Moved `nix/desktop/linux/appimagekit` to `nix/pkgs`
- Dropped `nix/tools/mkShell.nix` since it did almost nothing
- Dropped `nix/desktop/cmake/snorenotify` since it's broken
- Moved setup from `nix/tools/mkShell.nix` to `nix/shells.nix`
- Simplified `nix/mobile/ios/status-go-shell.nix`
- Simplified `nix/status-go/default.nix`
- Updated the `nix/DETAILS.md` and `nix/README.md`
- Moved known issues to `nix/KNOWN_ISSUES.md`
- Improved output of `nix/scripts/build.sh`

Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-05-04 20:55:07 +02:00

33 lines
845 B
Nix

{ stdenv, lib, callPackage, mkShell,
gnupg22, darwin, qt5custom, status-go, baseImageFactory }:
assert lib.assertMsg stdenv.isDarwin "Building MacOS app can work only on MacOS!";
let
inherit (lib) concatStrings catAttrs;
inherit (darwin.apple_sdk.frameworks)
AppKit Cocoa Foundation OpenGL CoreFoundation;
baseImage = baseImageFactory "macos";
in {
shell = mkShell {
buildInputs = [
gnupg22 baseImage qt5custom
darwin.cf-private
AppKit Cocoa Foundation OpenGL
];
inputsFrom = [
status-go baseImage
];
shellHook = ''
export NIX_TARGET_LDFLAGS="-F${CoreFoundation}/Library/Frameworks -framework CoreFoundation $NIX_TARGET_LDFLAGS"
export QT_PATH="${qt5custom}"
export QT_BASEBIN_PATH="${qt5custom}/bin"
export PATH="$QT_BASEBIN_PATH/bin:$PATH"
'';
};
}