refactor(3p/nix): Anchor local includes at src/

Previously all includes were anchored in one global mess of header
files. This moves the includes into filesystem "namespaces" (if you
will) for each sub-package of Nix.

Note: This commit does not introduce the relevant build system changes.
This commit is contained in:
Vincent Ambo 2020-05-27 21:56:34 +01:00
parent 86a35d963d
commit 3652326ed2
159 changed files with 659 additions and 654 deletions

View file

@ -1,9 +1,9 @@
#include "affinity.hh"
#include "libutil/affinity.hh"
#include <glog/logging.h>
#include "types.hh"
#include "util.hh"
#include "libutil/types.hh"
#include "libutil/util.hh"
#if __linux__
#include <sched.h>

View file

@ -1,4 +1,4 @@
#include "archive.hh"
#include "libutil/archive.hh"
#include <algorithm>
#include <cerrno>
@ -7,14 +7,14 @@
#include <dirent.h>
#include <fcntl.h>
#include <glog/logging.h>
#include <strings.h> // for strcasecmp
#include <sys/stat.h>
#include <sys/types.h>
#include <unistd.h>
#include "config.hh"
#include "glog/logging.h"
#include "util.hh"
#include "libutil/config.hh"
#include "libutil/util.hh"
namespace nix {

View file

@ -1,7 +1,7 @@
#pragma once
#include "serialise.hh"
#include "types.hh"
#include "libutil/serialise.hh"
#include "libutil/types.hh"
namespace nix {

View file

@ -1,6 +1,6 @@
#include "args.hh"
#include "libutil/args.hh"
#include "hash.hh"
#include "libutil/hash.hh"
namespace nix {

View file

@ -6,7 +6,7 @@
#include <absl/strings/numbers.h>
#include "util.hh"
#include "libutil/util.hh"
namespace nix {

View file

@ -1,4 +1,4 @@
#include "compression.hh"
#include "libutil/compression.hh"
#include <cstdio>
#include <cstring>
@ -7,11 +7,11 @@
#include <brotli/decode.h>
#include <brotli/encode.h>
#include <bzlib.h>
#include <glog/logging.h>
#include <lzma.h>
#include "finally.hh"
#include "glog/logging.h"
#include "util.hh"
#include "libutil/finally.hh"
#include "libutil/util.hh"
namespace nix {

View file

@ -2,9 +2,9 @@
#include <string>
#include "ref.hh"
#include "serialise.hh"
#include "types.hh"
#include "libutil/ref.hh"
#include "libutil/serialise.hh"
#include "libutil/types.hh"
namespace nix {

View file

@ -1,4 +1,4 @@
#include "config.hh"
#include "libutil/config.hh"
#include <string>
#include <utility>
@ -9,8 +9,8 @@
#include <absl/strings/string_view.h>
#include <glog/logging.h>
#include "args.hh"
#include "json.hh"
#include "libutil/args.hh"
#include "libutil/json.hh"
namespace nix {

View file

@ -1,7 +1,7 @@
#include <map>
#include <set>
#include "types.hh"
#include "libutil/types.hh"
#pragma once

View file

@ -1,4 +1,4 @@
#include "hash.hh"
#include "libutil/hash.hh"
#include <cstring>
#include <iostream>
@ -9,9 +9,9 @@
#include <sys/stat.h>
#include <sys/types.h>
#include "archive.hh"
#include "istringstream_nocopy.hh"
#include "util.hh"
#include "libutil/archive.hh"
#include "libutil/istringstream_nocopy.hh"
#include "libutil/util.hh"
namespace nix {

View file

@ -1,7 +1,7 @@
#pragma once
#include "serialise.hh"
#include "types.hh"
#include "libutil/serialise.hh"
#include "libutil/types.hh"
namespace nix {

View file

@ -1,4 +1,4 @@
#include "json.hh"
#include "libutil/json.hh"
#include <cstring>
#include <iomanip>

View file

@ -6,8 +6,8 @@
#include <list>
#include <memory>
#include "ref.hh"
#include "sync.hh"
#include "libutil/ref.hh"
#include "libutil/sync.hh"
namespace nix {

View file

@ -1,4 +1,4 @@
#include "serialise.hh"
#include "libutil/serialise.hh"
#include <boost/coroutine2/coroutine.hpp>
#include <cerrno>
@ -6,8 +6,9 @@
#include <memory>
#include <utility>
#include "glog/logging.h"
#include "util.hh"
#include <glog/logging.h>
#include "libutil/util.hh"
namespace nix {

View file

@ -2,8 +2,8 @@
#include <memory>
#include "types.hh"
#include "util.hh"
#include "libutil/types.hh"
#include "libutil/util.hh"
namespace nix {

View file

@ -1,7 +1,8 @@
#include "thread-pool.hh"
#include "libutil/thread-pool.hh"
#include "affinity.hh"
#include "glog/logging.h"
#include <glog/logging.h>
#include "libutil/affinity.hh"
namespace nix {

View file

@ -6,8 +6,8 @@
#include <queue>
#include <thread>
#include "sync.hh"
#include "util.hh"
#include "libutil/sync.hh"
#include "libutil/util.hh"
namespace nix {

View file

@ -7,7 +7,7 @@
#include <set>
#include <string>
#include "ref.hh"
#include "libutil/ref.hh"
/* Before 4.7, gcc's std::exception uses empty throw() specifiers for
* its (virtual) destructor and what() in c++11 mode, in violation of spec

View file

@ -1,4 +1,4 @@
#include "util.hh"
#include "libutil/util.hh"
#include <cctype>
#include <cerrno>
@ -15,6 +15,7 @@
#include <absl/strings/str_split.h>
#include <absl/strings/string_view.h>
#include <fcntl.h>
#include <glog/logging.h>
#include <grp.h>
#include <pwd.h>
#include <sys/ioctl.h>
@ -23,12 +24,12 @@
#include <sys/wait.h>
#include <unistd.h>
#include "affinity.hh"
#include "finally.hh"
#include "glog/logging.h"
#include "lazy.hh"
#include "serialise.hh"
#include "sync.hh"
#include "libutil/affinity.hh"
#include "libutil/finally.hh"
#include "libutil/lazy.hh"
#include "libutil/serialise.hh"
#include "libutil/sync.hh"
#include "nix_config.h"
namespace nix {

View file

@ -15,7 +15,7 @@
#include <sys/types.h>
#include <unistd.h>
#include "types.hh"
#include "libutil/types.hh"
#ifndef HAVE_STRUCT_DIRENT_D_TYPE
#define DT_UNKNOWN 0

View file

@ -1,4 +1,4 @@
#include "xml-writer.hh"
#include "libutil/xml-writer.hh"
#include <cassert>