-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
20 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,28 @@ | ||
# SPDX-License-Identifier: Apache-2.0 | ||
# SPDX-FileCopyrightText: 2024 Jiuyang Liu <[email protected]> | ||
|
||
{ buildFHSEnv | ||
, vcStaticHome | ||
# This is a bit dirty. | ||
# Since VCS are close source toolchains, we have no way to fix it for environment changes. | ||
# So here we have to lock the whole nixpkgs to a working version. | ||
# | ||
# For convenience, we still use the nixpkgs defined in flake to "callPackage" this derivation. | ||
# But the buildFHSEnv, targetPkgs is still from the locked nixpkgs. | ||
{ vcStaticHome | ||
, snpslmdLicenseFile | ||
, fetchFromGitHub | ||
}: | ||
buildFHSEnv { | ||
let | ||
nixpkgsSrcs = fetchFromGitHub { | ||
owner = "NixOS"; | ||
repo = "nixpkgs"; | ||
"rev" = "c374d94f1536013ca8e92341b540eba4c22f9c62"; | ||
"hash" = "sha256-Z/ELQhrSd7bMzTO8r7NZgi9g5emh+aRKoCdaAv5fiO0="; | ||
}; | ||
|
||
# The vcs we have only support x86-64_linux | ||
lockedPkgs = import nixpkgsSrcs { system = "x86_64-linux"; }; | ||
in | ||
lockedPkgs.buildFHSEnv { | ||
name = "vcs-fhs-env"; | ||
|
||
profile = '' | ||
|