mirror of
https://github.com/NixOS/nix
synced 2025-06-27 21:01:16 +02:00
add libcurl to deps, builds now
This commit is contained in:
parent
ba417a2172
commit
87e0bc9e21
4 changed files with 8 additions and 7 deletions
|
@ -328,6 +328,8 @@ struct GitRepoImpl : GitRepo, std::enable_shared_from_this<GitRepoImpl>
|
|||
|
||||
std::vector<std::tuple<Submodule, Hash>> getSubmodules(const Hash & rev, bool exportIgnore) override;
|
||||
|
||||
void smudgeLfs() override;
|
||||
|
||||
std::string resolveSubmoduleUrl(const std::string & url) override
|
||||
{
|
||||
git_buf buf = GIT_BUF_INIT;
|
||||
|
@ -1103,8 +1105,8 @@ std::vector<std::tuple<GitRepoImpl::Submodule, Hash>> GitRepoImpl::getSubmodules
|
|||
}
|
||||
|
||||
void GitRepoImpl::smudgeLfs() {
|
||||
const auto metadatas = lfs::parse_lfs_files(this->repo);
|
||||
const auto [url, host, path] = lfs::get_lfs_endpoint_url(this->repo);
|
||||
const auto metadatas = lfs::parse_lfs_files(&(*repo));
|
||||
const auto [url, host, path] = lfs::get_lfs_endpoint_url(&(*repo));
|
||||
// TODO: handle public lfs repos without ssh?
|
||||
const auto token = lfs::get_lfs_api_token(host, path);
|
||||
auto urls = lfs::fetch_urls(url, token, metadatas);
|
||||
|
|
|
@ -74,10 +74,6 @@ struct GitRepo
|
|||
|
||||
virtual std::string resolveSubmoduleUrl(const std::string & url) = 0;
|
||||
|
||||
virtual std::string resolveSubmoduleUrl(
|
||||
const std::string & url,
|
||||
const std::string & base) = 0;
|
||||
|
||||
virtual bool hasObject(const Hash & oid) = 0;
|
||||
|
||||
virtual ref<SourceAccessor> getAccessor(const Hash & rev, bool exportIgnore) = 0;
|
||||
|
|
|
@ -12,6 +12,6 @@ INCLUDE_libfetchers := -I $(d)
|
|||
|
||||
libfetchers_CXXFLAGS += $(INCLUDE_libutil) $(INCLUDE_libstore) $(INCLUDE_libfetchers)
|
||||
|
||||
libfetchers_LDFLAGS += $(THREAD_LDFLAGS) $(LIBGIT2_LIBS) -larchive
|
||||
libfetchers_LDFLAGS += $(THREAD_LDFLAGS) $(LIBGIT2_LIBS) $(LIBCURL_LIBS) -larchive
|
||||
|
||||
libfetchers_LIBS = libutil libstore
|
||||
|
|
|
@ -34,6 +34,9 @@ deps_public += nlohmann_json
|
|||
libgit2 = dependency('libgit2')
|
||||
deps_private += libgit2
|
||||
|
||||
curl = dependency('libcurl', 'curl')
|
||||
deps_private += curl
|
||||
|
||||
add_project_arguments(
|
||||
# TODO(Qyriad): Yes this is how the autoconf+Make system did it.
|
||||
# It would be nice for our headers to be idempotent instead.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue