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

49 lines
1.4 KiB
Nix

{ pkgs, stdenv, fetchFromGitHub, appimagekit }:
with pkgs;
stdenv.mkDerivation rec {
pname = "linuxdeployqt";
version = "20181215";
owner = "probonopd";
repo = "linuxdeployqt";
rev = "600fc20ea73ee937a402a2bb6b3663d93fcc1d4b";
sha256 = "05kvkfbhsyadlcggl63rhrw5s36d8qxs8gyihrjn2cjk42xx8r7j";
src =
if stdenv.hostPlatform.system == "x86_64-linux" then
fetchFromGitHub {
name = "${repo}-${stdenv.lib.strings.substring 0 7 rev}-source";
inherit owner repo rev sha256;
}
else throw "${name} is not supported on ${stdenv.hostPlatform.system}";
# Add our own patch to make linuxdeployqt correctly include all /nix/store rpaths to LD_LIBRARY_PATH so we don't have to calculate that ourselves
patches = [ ./linuxdeployqt.patch ];
buildInputs = [ qt5.qtbase appimagekit ];
nativeBuildInputs = [ wget ];
buildPhase = ''
qmake
make
'';
installPhase = ''
runHook preInstall
mkdir -p $out/bin
cp -r bin/linuxdeployqt $out/bin/
runHook postInstall
'';
meta = {
description = "Makes Linux applications self-contained by copying in the libraries and plugins that the application uses, and optionally generates an AppImage. Can be used for Qt and other applications";
homepage = https://github.com/probonopd/linuxdeployqt/;
license = stdenv.lib.licenses.gpl3;
maintainers = [ stdenv.lib.maintainers.pombeirp ];
platforms = stdenv.lib.platforms.linux;
};
}