about summary refs log tree commit diff
path: root/third_party (follow)
AgeCommit message (Collapse)AuthorFilesLines
2020-06-13 r/935 feat(3p/gerrit_plugins): Add derivations for Gerrit owners pluginVincent Ambo1-0/+16
Change-Id: I319f812746aea6069c45727f5afae8b9b79effdd Reviewed-on: https://cl.tvl.fyi/c/depot/+/221 Reviewed-by: q3k <q3k@q3k.org> Reviewed-by: lukegb <lukegb@tvl.fyi>
2020-06-13 r/924 feat(nixos/smtprelay): Add derivation & module for SMTP relayVincent Ambo1-0/+20
This adds a little tool that can be used to relay mail to Gmail (and other SMTP servers). It is intended to be used by Gerrit, which is incompatible with Gmail's SMTP servers. Configuration has been tested by performing a few sends through the tvlbot@tazj.in account. Note that this is using the standard Gmail SMTP server. Using the smtp-relay server relies on IP whitelisting, but camden.tazj.in has a larger number of IPv6 addresses than can be whitelisted (the maximum is 65k). This means that we are limited to 2000 mails per recipient per day, which should be fine. Change-Id: Ie43564d753030f5c800a9cdb4ae98292877d80dc Reviewed-on: https://cl.tvl.fyi/c/depot/+/101 Reviewed-by: edef <edef@edef.eu>
2020-06-11 r/900 chore(3p): Bump nixos-unstableVincent Ambo1-3/+3
2020-06-11 r/897 feat(ops/nixos): Add module for configuring Gerrit for the repoVincent Ambo1-0/+1
2020-06-11 r/895 chore(3p): Use nixos from unstableVincent Ambo1-1/+1
Machines can still override the *package set*, but not the modules.
2020-06-07 r/884 feat(3p/grpc): Build gRPC using LLVM10 & libcxxVincent Ambo2-2/+15
2020-06-07 r/883 feat(3p/protobuf): Check in derivation for proto 3.12 with libcxxVincent Ambo2-1/+14
2020-06-03 r/879 feat(3p/emacs): Check in derivation for explain-pause-modeVincent Ambo1-0/+20
This mode makes it possible to track down slowness in Emacs functions across the board. https://github.com/lastquestion/explain-pause-mode Very useful for some things I need to debug ...
2020-06-03 r/878 fix(3p/cgit): Fix compilation under ClangLuke Granger-Brown2-2/+2
Clang treats function-like macros "correctly", in that, per the C11 spec: "Each subsequent instance of the function-like macro name followed by a ( [...] is replaced by the replacement list [...]". Additionally, fprintf is also permitted to be defined as a function-like macro rather than as a true function: "Any function declared in a header may be additionally implemented as a function-like macro defined in the header [...]". The specification then suggests surrounding the name of the function in parens to avoid this, which is the technique we use here to avoid the function-like macro being invoked. The other fix here is to use uintptr_t for some arithmetic, since Git is expecting an int as the value here and not a pointer.
2020-05-31 r/877 fix(3p): Force all stdenvs to use LLVM10Vincent Ambo1-6/+8
2020-05-31 r/876 fix(3p/nix): passAsFile: leave out the hash prefixedef2-1/+2
Having a colon in the path may cause issues, and having the hash function indicated isn't actually necessary. We now verify the path format in the tests to prevent regressions. (cherry picked from commit c65a6fa86aef7bdf51fb4fba7bd31d265619ba3f)
2020-05-31 r/875 fix(3p/nix): passAsFile: hash the attribute name instead of numbering ↵Puck Meerburg1-2/+2
sequentially This makes the paths consistent without relying on ordering. Co-authored-by: edef <edef@edef.eu> (cherry picked from commit 515c0a263e137a00e82f7d981284dbe54db23247)
2020-05-30 r/873 chore(3p/nix): Clean up leftover Meson fileVincent Ambo1-78/+0
2020-05-30 r/872 chore(3p/nix): Clean up some unused definesVincent Ambo5-1529/+2
2020-05-29 r/871 feat(3p/nix): Configure CMake to generate compile commandsVincent Ambo1-0/+4
2020-05-29 r/870 fix(3p/nix): Build glog as included CMake projectVincent Ambo3-5/+9
2020-05-29 r/869 feat(3p/glog): Check in derivation for glogVincent Ambo1-0/+18
Instead of overriding the upstream one, lets keep it local.
2020-05-28 r/868 refactor(3p/nix): Introduce CMake as the build system for NixVincent Ambo10-22/+500
Completes the switch from Meson to CMake for the core build system in Nix. Meson was added originally because someone else had already done the work for integrating it in Nix and it was an upgrade from the previous setup. However over time it became clear that Meson is not quite mature enough for projects like Nix that have occasionally peculiar configuration constraints. Some issues encountered with Meson (some of these are due to the Meson setup in Nix): * Difficulty with generating correct compile_commands.json for external tools like clangd * Difficulty linking to libc++ when using clang * Ugly shell invocations for certain parts of the build system (I want these to be gone!!!) This CMake setup mimics the Meson configuration, but there are some differences (some temporary): * headers are now included separately for each library (see a previous commit that changes includes appropriately) * autoheaders-style configuration is currently hardcoded. Before blindly copying this I want to evaluate how much of it actually exists for portability concerns that I don't have (such as support for OS X). * Nix is built with libc++ by default. * [libstore] SQL schema is now inlined via a generated header, not an included string literal Abseil is still built as part of this build, rather than an external dependency, because it chokes on differently configured compiler invocations. Note that because of the move to libc++ an unwanted behaviour is introduced: glog log messages no longer have a body. I have yet to debug what is going on there.
2020-05-27 r/867 chore(3p/nix): Remove meson build files for core packagesVincent Ambo7-1188/+0
2020-05-27 r/866 chore(3p/nix): Move Abseil symlink one layer upVincent Ambo2-1/+1
This is required for upcoming build system changes.
2020-05-27 r/865 refactor(3p/nix): Anchor local includes at src/Vincent Ambo159-656/+661
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.
2020-05-27 r/864 refactor(3p/abseil_cpp): Inline Nix derivationVincent Ambo2-4/+14
2020-05-27 r/863 merge(3p/glog): Vendor glog from commit 'afe04691'Vincent Ambo133-0/+23455
2020-05-27 r/862 chore(3p): Remove glog overrideVincent Ambo2-16/+1
This library is being vendored, hence the override doesn't matter anymore.
2020-05-27 r/861 fix(3p/nix): Default-import depot from a relative pathVincent Ambo1-1/+1
2020-05-27 r/859 fix(3p/git): Use git derivation from stable channel as baseVincent Ambo1-1/+2
unstable is, of course, not working correctly at the moment
2020-05-26 r/857 chore(3p): Expose nixpkgs commit to depotVincent Ambo1-3/+3
2020-05-26 r/852 revert(3p/git): Revert merge of git upstream at v2.26.2Vincent Ambo1006-146045/+57858
This causes cgit to serve error pages, which is undesirable. This reverts commit 5229c9b232de5bfa959ad6ebbb4c8192ac513352, reversing changes made to f2b211131f2347342dde63975b09cf603149f1a3.
2020-05-25 r/850 feat(3p/hound): Init hound packageVincent Ambo1-0/+14
Hound is a code searching tool that I intend to use while finding something more fully featured.
2020-05-25 r/849 chore(3p/naersk): Update to latest 'master'Vincent Ambo2-6/+8
2020-05-25 r/847 docs(3p/nix): Add a README explaining the goals of the forkVincent Ambo1-12/+147
2020-05-25 r/846 refactor(3p/nix): Replace tokenizeStrings with absl::StrSplitVincent Ambo29-145/+146
This function was a custom (and inefficient in the case of single-character delimiters) string splitter which was used all over the codebase. Abseil provides an appropriate replacement function.
2020-05-25 r/845 refactor(3p/nix/libutil): Replace hasPrefix/Suffix with AbseilVincent Ambo21-57/+69
Uses the equivalent absl::StartsWith and absl::EndsWith functions instead.
2020-05-25 r/844 fix(3p/nix/libstore): Fix error condition when parsing generationsVincent Ambo1-1/+1
2020-05-25 r/843 refactor(3p/nix/libutil): Replace string2Int & trim functionsVincent Ambo19-72/+84
Replaces these functions with corresponding functions from Abseil, namely absl::StripAsciiWhitespace and absl::SimpleAtoi. In the course of doing this some minor things I encountered along the way were also refactored. This also changes the signatures of the various custom readFile functions to use absl::string_view types.
2020-05-24 r/842 chore(3p/nix/libstore): Remove progress bar remnants from downloadVincent Ambo1-19/+0
2020-05-24 r/841 style(3p/nix): Remove 'using std::*' from xml-writer.hhVincent Ambo2-7/+3
See previous commit for more details on why.
2020-05-24 r/840 style(3p/nix): Remove 'using std::*' from types.hhVincent Ambo85-824/+862
It is considered bad form to use things from includes in headers, as these directives propagate to everywhere else and can make it confusing. types.hh (which is includes almost literally everywhere) had some of these directives, which this commit removes.
2020-05-24 r/839 chore(3p/nix): Enable cross-file-rename in clangdVincent Ambo1-1/+1
2020-05-24 r/838 chore(3p/nix): Make build type configurableVincent Ambo1-3/+3
2020-05-24 r/835 refactor(3p/nix/libutil): Replace chomp() with absl::stringsVincent Ambo15-26/+40
2020-05-24 r/834 chore(3p/nix): Remove some OS X specific definesVincent Ambo9-281/+3
This project will be dropping OS X support until the core is simplified.
2020-05-24 r/833 fix(3p/nix): Fix long paths permanently breaking GCAlyssa Ross1-13/+45
Suppose I have a path /nix/store/[hash]-[name]/a/a/a/a/a/[...]/a, long enough that everything after "/nix/store/" is longer than 4096 (MAX_PATH) bytes. Nix will happily allow such a path to be inserted into the store, because it doesn't look at all the nested structure. It just cares about the /nix/store/[hash]-[name] part. But, when the path is deleted, we encounter a problem. Nix will move the path to /nix/store/trash, but then when it's trying to recursively delete the trash directory, it will at some point try to unlink /nix/store/trash/[hash]-[name]/a/a/a/a/a/[...]/a. This will fail, because the path is too long. After this has failed, any store deletion operation will never work again, because Nix needs to delete the trash directory before recreating it to move new things to it. (I assume this is because otherwise a path being deleted could already exist in the trash, and then moving it would fail.) This means that if I can trick somebody into just fetching a tarball containing a path of the right length, they won't be able to delete store paths or garbage collect ever again, until the offending path is manually removed from /nix/store/trash. (And even fixing this manually is quite difficult if you don't understand the issue, because the absolute path that Nix says it failed to remove is also too long for rm(1).) This patch fixes the issue by making Nix's recursive delete operation use unlinkat(2). This function takes a relative path and a directory file descriptor. We ensure that the relative path is always just the name of the directory entry, and therefore its length will never exceed 255 bytes. This means that it will never even come close to AX_PATH, and Nix will therefore be able to handle removing arbitrarily deep directory hierachies. Since the directory file descriptor is used for recursion after being used in readDirectory, I made a variant of readDirectory that takes an already open directory stream, to avoid the directory being opened multiple times. As we have seen from this issue, the less we have to interact with paths, the better, and so it's good to reuse file descriptors where possible. I left _deletePath as succeeding even if the parent directory doesn't exist, even though that feels wrong to me, because without that early return, the linux-sandbox test failed. Reported-by: Alyssa Ross <hi@alyssa.is> Thanks-to: Puck Meerburg <puck@puckipedia.com> Tested-by: Puck Meerburg <puck@puckipedia.com> Reviewed-by: Puck Meerburg <puck@puckipedia.com> (cherry picked from commit c05e20daa1abb3446e378331697938b78af2b3d7)
2020-05-23 r/832 style(3p/nix): Rename derivation to 'tazjix'Vincent Ambo1-1/+1
This makes it easier to distinguish which thing I'm dealing with in the store paths. It does not affect anything else.
2020-05-23 r/831 fix(3p/nix): Set Meson build type to 'release'Vincent Ambo1-0/+2
Gotta go fast ... (well, not while compiling)
2020-05-23 r/829 fix(3p/nix/libexpr): Ensure ExprOpUpdate merges into destinationVincent Ambo1-17/+5
... this fixes nixpkgs eval!
2020-05-23 r/828 refactor(3p/nix/libexpr): Make other 'const' in Bindings::mergeVincent Ambo2-8/+5
2020-05-23 r/827 fix(3p/nix/libexpr): Actually use AttributeMap type aliasVincent Ambo1-2/+2
Without this alias, the garbage-collecting allocator won't be used and allocated attribute set values won't be visible during GC.
2020-05-23 r/826 docs(3p/nix/libexpr): Add comment on ExprSelectVincent Ambo1-1/+8
2020-05-23 r/825 docs(3p/nix/libexpr): Add some comments about function callsVincent Ambo2-5/+10
These were things that took me a moment to realise.