forked from NixOS/nixpkgs
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request NixOS#329939 from gracicot/gracicot/vcpkg-bundle
vcpkg: support builtin-baseline without git
- Loading branch information
Showing
3 changed files
with
64 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
43 changes: 43 additions & 0 deletions
43
pkgs/by-name/vc/vcpkg-tool/read-bundle-info-from-root.patch
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 |
---|---|---|
@@ -0,0 +1,43 @@ | ||
diff --git a/include/vcpkg/vcpkgpaths.h b/include/vcpkg/vcpkgpaths.h | ||
index 90fd4d09..ebc6342b 100644 | ||
--- a/include/vcpkg/vcpkgpaths.h | ||
+++ b/include/vcpkg/vcpkgpaths.h | ||
@@ -28,6 +28,8 @@ | ||
|
||
namespace vcpkg | ||
{ | ||
+ Path exported_determine_root(const ReadOnlyFilesystem& fs, const Path& original_cwd, const VcpkgCmdArguments& args); | ||
+ | ||
struct ToolsetArchOption | ||
{ | ||
ZStringView name; | ||
diff --git a/src/vcpkg.cpp b/src/vcpkg.cpp | ||
index 2b62cb55..d7b8ead5 100644 | ||
--- a/src/vcpkg.cpp | ||
+++ b/src/vcpkg.cpp | ||
@@ -296,7 +296,8 @@ int main(const int argc, const char* const* const argv) | ||
Debug::println("To include the environment variables in debug output, pass --debug-env"); | ||
} | ||
args.check_feature_flag_consistency(); | ||
- const auto current_exe_path = get_exe_path_of_current_process(); | ||
+ const auto current_exe_path = | ||
+ exported_determine_root(real_filesystem, real_filesystem.current_path(VCPKG_LINE_INFO), args) / "vcpkg"; | ||
|
||
bool to_enable_metrics = true; | ||
{ | ||
diff --git a/src/vcpkg/vcpkgpaths.cpp b/src/vcpkg/vcpkgpaths.cpp | ||
index 77e107f5..132050ba 100644 | ||
--- a/src/vcpkg/vcpkgpaths.cpp | ||
+++ b/src/vcpkg/vcpkgpaths.cpp | ||
@@ -518,6 +518,11 @@ namespace | ||
|
||
namespace vcpkg | ||
{ | ||
+ Path exported_determine_root(const ReadOnlyFilesystem& fs, const Path& original_cwd, const VcpkgCmdArguments& args) | ||
+ { | ||
+ return determine_root(fs, original_cwd, args); | ||
+ } | ||
+ | ||
Path InstalledPaths::listfile_path(const BinaryParagraph& pgh) const | ||
{ | ||
return this->vcpkg_dir_info() / (pgh.fullstem() + ".list"); |
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