|
Nix
2.93.0-dev
Lix: A modern, delicious implementation of the Nix package manager; unstable internal interfaces
|
#include "lix/libstore/common-protocol.hh"Go to the source code of this file.
Macros | |
| #define | WORKER_MAGIC_1 0x6e697863 |
| #define | WORKER_MAGIC_2 0x6478696f |
| #define | PROTOCOL_VERSION (1 << 8 | 35) |
| #define | MIN_SUPPORTED_MINOR_WORKER_PROTO_VERSION 21 |
| #define | MIN_SUPPORTED_WORKER_PROTO_VERSION (1 << 8 | MIN_SUPPORTED_MINOR_WORKER_PROTO_VERSION) |
| #define | GET_PROTOCOL_MAJOR(x) ((x) & 0xff00) |
| #define | GET_PROTOCOL_MINOR(x) ((x) & 0x00ff) |
| #define | REMOVE_AFTER_DROPPING_PROTO_MINOR(protoMinor) static_assert(MIN_SUPPORTED_MINOR_WORKER_PROTO_VERSION <= (protoMinor)) |
| #define | STDERR_NEXT 0x6f6c6d67 |
| #define | STDERR_READ 0x64617461 |
| #define | STDERR_WRITE 0x64617416 |
| #define | STDERR_LAST 0x616c7473 |
| #define | STDERR_ERROR 0x63787470 |
| #define | STDERR_START_ACTIVITY 0x53545254 |
| #define | STDERR_STOP_ACTIVITY 0x53544f50 |
| #define | STDERR_RESULT 0x52534c54 |
| #define | DECLARE_WORKER_SERIALISER(T) |
| #define | COMMA_ , |
Functions | |
| Sink & | nix::operator<< (Sink &sink, WorkerProto::Op op) |
| std::ostream & | nix::operator<< (std::ostream &s, WorkerProto::Op op) |
| #define DECLARE_WORKER_SERIALISER | ( | T | ) |
Declare a canonical serialiser pair for the worker protocol.
We specialise the struct merely to indicate that we are implementing the function for the given type.
Some sort of template<...> must be used with the caller for this to be legal specialization syntax. See below for what that looks like in practice.
|
inline |
Convenience for sending operation codes.
WorkerProto::Serialise instead probably. But this was not done at this time so there would be less churn.
|
inline |
Convenience for debugging.