monorepo/flake.nix

77 lines
2.4 KiB
Nix
Raw Permalink Normal View History

2022-12-31 17:07:58 +00:00
{
description = "Lumenescent Dreams Tools";
inputs = {
nixpkgs.url = "nixpkgs/nixos-22.11";
unstable.url = "nixpkgs/nixos-unstable";
2022-12-31 17:07:58 +00:00
oxalica.url = "https://github.com/oxalica/rust-overlay/archive/master.tar.gz";
};
outputs = { self, nixpkgs, unstable, oxalica }:
2022-12-31 17:07:58 +00:00
let
version = builtins.string 0 8 self.lastModifiedDate;
supportedSystems = [ "x86_64-linux" ];
in
{
devShell."x86_64-linux" =
let
rust_overlay = import oxalica;
pkgs = import nixpkgs { system = "x86_64-linux"; overlays = [ rust_overlay ]; };
2023-03-26 03:37:06 +00:00
pkgs-unstable = import unstable {
system = "x86_64-linux";
overlays = [ rust_overlay ];
config.android_sdk.accept_license = true;
config.allowUnfree = true;
};
2022-12-31 17:07:58 +00:00
rust = pkgs.rust-bin.stable."1.65.0".default.override {
extensions = [ "rust-src" ];
};
2023-03-26 03:37:06 +00:00
/*
androidComposition = pkgs-unstable.androidenv.composeAndroidPackages {
cmdLineToolsVersion = "8.0";
toolsVersion = "26.1.1";
platformToolsVersion = "33.0.3";
includeEmulator = true;
platformVersions = [ "28" "29" "30" ];
abiVersions = [ "arm64-v8a" ];
includeNDK = true;
};
*/
buildToolsVersion = "30.0.3";
androidsdk = pkgs-unstable.androidenv.androidPkgs_9_0.androidsdk;
2022-12-31 17:07:58 +00:00
in
2023-03-26 03:37:06 +00:00
pkgs.mkShell rec {
2022-12-31 17:07:58 +00:00
name = "ld-tools-devshell";
buildInputs = [
pkgs.clang
pkgs.entr
2023-02-06 14:36:02 +00:00
pkgs.glade
pkgs.glib
pkgs.gst_all_1.gst-plugins-bad
pkgs.gst_all_1.gst-plugins-base
pkgs.gst_all_1.gst-plugins-good
pkgs.gst_all_1.gst-plugins-ugly
pkgs.gst_all_1.gstreamer
2023-02-06 14:36:02 +00:00
pkgs.gtk4
pkgs.nodejs
2022-12-31 17:07:58 +00:00
pkgs.openssl
pkgs.pipewire
2023-02-06 14:36:02 +00:00
pkgs.pkg-config
pkgs.sqlite
2023-03-26 03:37:06 +00:00
pkgs-unstable.android-studio
pkgs-unstable.gradle
androidsdk
2022-12-31 17:07:58 +00:00
rust
];
LIBCLANG_PATH="${pkgs.llvmPackages.libclang.lib}/lib";
2023-03-26 03:37:06 +00:00
ANDROID_SDK_ROOT = "${androidsdk}/libexec/android-sdk";
ANDROID_NDK_ROOT = "${ANDROID_SDK_ROOT}/ndk-bundle";
GRADLE_OPTS = "-Dorg.gradle.project.android.aapt2FromMavenOverride=${ANDROID_SDK_ROOT}/build-tools/${buildToolsVersion}/aapt2";
2022-12-31 17:07:58 +00:00
};
};
}