System no longer builds; need help interpreting the log

My system no longer builds and I’m not sure what is failing or why.

Output:

reading the Nix store...
checking path existence...
building the system configuration...
error: builder for '/nix/store/239sm7d4p8kmcg09diapgx9m8cnnfdkn-cvc4-1.8.drv' failed with exit code 2;
       last 10 log lines:
       > [  4%] Built target gen-theory
       > /build/source/src/expr/expr_template.h:0: error: undefined replacement ${getConst_instantiations}
       > make[2]: *** [src/expr/CMakeFiles/gen-expr.dir/build.make:114: src/expr/expr.h] Error 1
       > make[2]: *** Deleting file 'src/expr/expr.h'
       > make[2]: *** Waiting for unfinished jobs....
       > /build/source/src/expr/metakind_template.h:0: error: undefined replacement ${metakind_getConst_decls}
       > make[2]: *** [src/expr/CMakeFiles/gen-expr.dir/build.make:220: src/expr/metakind.h] Error 1
       > make[2]: *** Deleting file 'src/expr/metakind.h'
       > make[1]: *** [CMakeFiles/Makefile2:413: src/expr/CMakeFiles/gen-expr.dir/all] Error 2
       > make: *** [Makefile:146: all] Error 2
       For full logs, run 'nix log /nix/store/239sm7d4p8kmcg09diapgx9m8cnnfdkn-cvc4-1.8.drv'.
error: 1 dependencies of derivation '/nix/store/8izg7clnwf3qqy66b7lraarmcvxbfyy0-solc-0.8.13.drv' failed to build
error: 1 dependencies of derivation '/nix/store/ywywnr52a9yg5b2sjybwaj8jgglgb027-home-manager-path.drv' failed to build
error: 1 dependencies of derivation '/nix/store/qx8ba56yyxfs7870bdfysx4jikywgvax-home-manager-generation.drv' failed to build
error: 1 dependencies of derivation '/nix/store/y9849rlxvs6qwnqp4hah0x9n9gs5bnks-user-environment.drv' failed to build
error: 1 dependencies of derivation '/nix/store/knzpvrx0q7hl6yi9w8cc1qi8s66d28vf-etc.drv' failed to build
error: 1 dependencies of derivation '/nix/store/gvpixbgn50v5zwmvk7cv0fvvv9yf9nlp-nixos-system-main-23.05.20230115.6dccdc4.drv' failed to build

Full log:

@nix { "action": "setPhase", "phase": "unpackPhase" }
unpacking sources
unpacking source archive /nix/store/c1qgm04gnpk3a59kfy8nggp6hw0spwhz-source
source root is source
@nix { "action": "setPhase", "phase": "patchPhase" }
patching sources
patching file core/Main.cc
Hunk #1 succeeded at 80 (offset 2 lines).
patching file simp/Main.cc
Hunk #1 succeeded at 82 (offset 3 lines).
patching file utils/System.h
Hunk #1 succeeded at 22 with fuzz 1.
patching file core/Main.cc
Hunk #1 succeeded at 81 (offset 3 lines).
patching file simp/Main.cc
Hunk #1 succeeded at 81 (offset 2 lines).
patching file utils/System.h
Hunk #1 succeeded at 22 with fuzz 1.
@nix { "action": "setPhase", "phase": "configurePhase" }
configuring
patching script interpreter paths in ./src/
./src/base/genheader.sh: interpreter directive changed from "#!/bin/sh" to "/nix/store/pj1hnyxhcsw1krmhnbb9rjvqssbzliw8-bash-5.2-p15/bin/sh"
./src/base/gentags.sh: interpreter directive changed from "#!/bin/sh" to "/nix/store/pj1hnyxhcsw1krmhnbb9rjvqssbzliw8-bash-5.2-p15/bin/sh"
./src/base/gentmptags.sh: interpreter directive changed from "#!/bin/sh" to "/nix/store/pj1hnyxhcsw1krmhnbb9rjvqssbzliw8-bash-5.2-p15/bin/sh"
./src/base/mktagheaders: interpreter directive changed from "#!/bin/bash" to "/nix/store/pj1hnyxhcsw1krmhnbb9rjvqssbzliw8-bash-5.2-p15/bin/bash"
./src/base/mktags: interpreter directive changed from "#!/bin/bash" to "/nix/store/pj1hnyxhcsw1krmhnbb9rjvqssbzliw8-bash-5.2-p15/bin/bash"
./src/fix-install-headers.sh: interpreter directive changed from "#!/usr/bin/env bash" to "/nix/store/pj1hnyxhcsw1krmhnbb9rjvqssbzliw8-bash-5.2-p15/bin/bash"
./src/options/generate-toml-files.sh: interpreter directive changed from "#!/bin/bash" to "/nix/store/pj1hnyxhcsw1krmhnbb9rjvqssbzliw8-bash-5.2-p15/bin/bash"
./src/options/mkoptions.py: interpreter directive changed from "#!/usr/bin/env python" to "/nix/store/abax98471z8fshv4b9p46bkh3lxmpy0z-python3-3.10.9/bin/python"
./src/api/python/genkinds.py: interpreter directive changed from "#!/usr/bin/env python" to "/nix/store/abax98471z8fshv4b9p46bkh3lxmpy0z-python3-3.10.9/bin/python"
./src/theory/mkrewriter: interpreter directive changed from "#!/usr/bin/env bash" to "/nix/store/pj1hnyxhcsw1krmhnbb9rjvqssbzliw8-bash-5.2-p15/bin/bash"
./src/theory/mktheorytraits: interpreter directive changed from "#!/usr/bin/env bash" to "/nix/store/pj1hnyxhcsw1krmhnbb9rjvqssbzliw8-bash-5.2-p15/bin/bash"
./src/expr/mkexpr: interpreter directive changed from "#!/usr/bin/env bash" to "/nix/store/pj1hnyxhcsw1krmhnbb9rjvqssbzliw8-bash-5.2-p15/bin/bash"
./src/expr/mkkind: interpreter directive changed from "#!/usr/bin/env bash" to "/nix/store/pj1hnyxhcsw1krmhnbb9rjvqssbzliw8-bash-5.2-p15/bin/bash"
./src/expr/mkmetakind: interpreter directive changed from "#!/usr/bin/env bash" to "/nix/store/pj1hnyxhcsw1krmhnbb9rjvqssbzliw8-bash-5.2-p15/bin/bash"
fixing cmake files...
cmake flags: -DCMAKE_FIND_USE_SYSTEM_PACKAGE_REGISTRY=OFF -DCMAKE_FIND_USE_PACKAGE_REGISTRY=OFF -DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON -DCMAKE_BUILD_TYPE=Release -DBUILD_TESTING=OFF -DCMAKE_INSTALL_LOCALEDIR=/nix/store/5fcniq4zf77rmdw0ypli7gwngvgpy1hg-cvc4-1.8/share/locale -DCMAKE_INSTALL_LIBEXECDIR=/nix/store/5fcniq4zf77rmdw0ypli7gwngvgpy1hg-cvc4-1.8/libexec -DCMAKE_INSTALL_LIBDIR=/nix/store/5fcniq4zf77rmdw0ypli7gwngvgpy1hg-cvc4-1.8/lib -DCMAKE_INSTALL_DOCDIR=/nix/store/5fcniq4zf77rmdw0ypli7gwngvgpy1hg-cvc4-1.8/share/doc/cvc4 -DCMAKE_INSTALL_INFODIR=/nix/store/5fcniq4zf77rmdw0ypli7gwngvgpy1hg-cvc4-1.8/share/info -DCMAKE_INSTALL_MANDIR=/nix/store/5fcniq4zf77rmdw0ypli7gwngvgpy1hg-cvc4-1.8/share/man -DCMAKE_INSTALL_OLDINCLUDEDIR=/nix/store/5fcniq4zf77rmdw0ypli7gwngvgpy1hg-cvc4-1.8/include -DCMAKE_INSTALL_INCLUDEDIR=/nix/store/5fcniq4zf77rmdw0ypli7gwngvgpy1hg-cvc4-1.8/include -DCMAKE_INSTALL_SBINDIR=/nix/store/5fcniq4zf77rmdw0ypli7gwngvgpy1hg-cvc4-1.8/sbin -DCMAKE_INSTALL_BINDIR=/nix/store/5fcniq4zf77rmdw0ypli7gwngvgpy1hg-cvc4-1.8/bin -DCMAKE_INSTALL_NAME_DIR=/nix/store/5fcniq4zf77rmdw0ypli7gwngvgpy1hg-cvc4-1.8/lib -DCMAKE_POLICY_DEFAULT_CMP0025=NEW -DCMAKE_OSX_SYSROOT= -DCMAKE_FIND_FRAMEWORK=LAST -DCMAKE_STRIP=/nix/store/iiq295j1z4q1sxmdbrl2j8ma3l5ns4wr-gcc-wrapper-11.3.0/bin/strip -DCMAKE_RANLIB=/nix/store/iiq295j1z4q1sxmdbrl2j8ma3l5ns4wr-gcc-wrapper-11.3.0/bin/ranlib -DCMAKE_AR=/nix/store/iiq295j1z4q1sxmdbrl2j8ma3l5ns4wr-gcc-wrapper-11.3.0/bin/ar -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++ -DCMAKE_INSTALL_PREFIX=/nix/store/5fcniq4zf77rmdw0ypli7gwngvgpy1hg-cvc4-1.8 -DCMAKE_BUILD_TYPE=Production 
-- The C compiler identification is GNU 11.3.0
-- The CXX compiler identification is GNU 11.3.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /nix/store/iiq295j1z4q1sxmdbrl2j8ma3l5ns4wr-gcc-wrapper-11.3.0/bin/gcc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /nix/store/iiq295j1z4q1sxmdbrl2j8ma3l5ns4wr-gcc-wrapper-11.3.0/bin/g++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Building Production build
-- Performing Test HAVE_FLAG_O3
-- Performing Test HAVE_FLAG_O3 - Success
-- Configuring with C flag '-O3'
-- Configuring with CXX flag '-O3'
-- Performing Test HAVE_FLAG_Wall
-- Performing Test HAVE_FLAG_Wall - Success
-- Configuring with C flag '-Wall'
-- Configuring with CXX flag '-Wall'
-- Performing Test HAVE_FLAG_fexceptions
-- Performing Test HAVE_FLAG_fexceptions - Success
-- Configuring with C flag '-fexceptions'
-- Performing Test HAVE_FLAG_Wno_deprecated
-- Performing Test HAVE_FLAG_Wno_deprecated - Success
-- Configuring with C flag '-Wno-deprecated'
-- Configuring with CXX flag '-Wno-deprecated'
-- Performing Test HAVE_FLAG_Wsuggest_override
-- Performing Test HAVE_FLAG_Wsuggest_override - Success
-- Configuring with CXX flag '-Wsuggest-override'
-- Performing Test HAVE_FLAG_Wnon_virtual_dtor
-- Performing Test HAVE_FLAG_Wnon_virtual_dtor - Success
-- Configuring with CXX flag '-Wnon-virtual-dtor'
-- Performing Test HAVE_FLAG_Wimplicit_fallthrough
-- Performing Test HAVE_FLAG_Wimplicit_fallthrough - Success
-- Configuring with C flag '-Wimplicit-fallthrough'
-- Configuring with CXX flag '-Wimplicit-fallthrough'
-- Performing Test HAVE_FLAG_Wshadow
-- Performing Test HAVE_FLAG_Wshadow - Success
-- Configuring with C flag '-Wshadow'
-- Configuring with CXX flag '-Wshadow'
-- Performing Test HAVE_FLAG_Wno_class_memaccess
-- Performing Test HAVE_FLAG_Wno_class_memaccess - Success
-- Configuring with CXX flag '-Wno-class-memaccess'
-- Using GNU gold linker.
-- Found PythonInterp: /nix/store/abax98471z8fshv4b9p46bkh3lxmpy0z-python3-3.10.9/bin/python (found version "3.10.9") 
-- Found GMP: /nix/store/yj0ppwfqpvx4xjpp8kfz6c1w9im6fl3f-gmp-with-cxx-6.2.1-dev/include  
-- Found GMP libs: /nix/store/iqpqnl4fz14xsyfhv6950cxw10yfm04c-gmp-with-cxx-6.2.1/lib/libgmp.so
-- Performing Test CVC4_NEED_INT64_T_OVERLOADS
-- Performing Test CVC4_NEED_INT64_T_OVERLOADS - Failed
-- Performing Test CVC4_NEED_HASH_UINT64_T_OVERLOAD
-- Performing Test CVC4_NEED_HASH_UINT64_T_OVERLOAD - Failed
-- Looking for unistd.h
-- Looking for unistd.h - found
-- Looking for C++ include ext/stdio_filebuf.h
-- Looking for C++ include ext/stdio_filebuf.h - found
-- Looking for clock_gettime
-- Looking for clock_gettime - found
-- Looking for ffs
-- Looking for ffs - found
-- Looking for optreset
-- Looking for optreset - not found
-- Looking for sigaltstack
-- Looking for sigaltstack - found
-- Looking for strerror_r
-- Looking for strerror_r - found
-- Looking for strtok_r
-- Looking for strtok_r - found
-- Performing Test STRERROR_R_CHAR_P
-- Performing Test STRERROR_R_CHAR_P - Failed
-- Found Git: /nix/store/5207hz4f779nz4z62zaa5gdjqzqz1l4g-git-2.39.0/bin/git (found version "2.39.0") 
-- Looking for antlr3FileStreamNew
-- Looking for antlr3FileStreamNew - found
-- Found ANTLR: /nix/store/vpprf0pa0kpwl3i2s7adjm24zl73b6a4-antlr-3.4/bin/antlr3  
-- Found ANTLR libs: /nix/store/r5wcpabb6xhjvy4ix59c6sh269xxvbsv-libantlr3c-3.4/lib/libantlr3c.so
-- Found Java: /nix/store/ch095in4hr481iqv11s55ks9ksl2c49i-openjdk-19.0.1+10/bin/java (found version "19.0.1") found components: Runtime 
e[0mCVC4 1.8e[0m
e[0me[0m
e[0mBuild profile             : productione[0m
e[0me[0m
e[0mGPL                       : offe[0m
e[0mBest configuration        : offe[0m
e[0mOptimization level        : offe[0m
e[0me[0m
e[0mAssertions                : offe[0m
e[0mDebug symbols             : offe[0m
e[0mDebug context mem mgr     : offe[0m
e[0me[0m
e[0mDumping                   : one[0m
e[0mMuzzle                    : offe[0m
e[0mProofs                    : one[0m
e[0mStatistics                : one[0m
e[0mTracing                   : offe[0m
e[0me[0m
e[0mASan                      : offe[0m
e[0mUBSan                     : offe[0m
e[0mTSan                      : offe[0m
e[0mCoverage (gcov)           : offe[0m
e[0mProfiling (gprof)         : offe[0m
e[0mUnit tests                : offe[0m
e[0mValgrind                  : offe[0m
e[0me[0m
e[0mShared libs               : one[0m
e[0mStatic binary             : offe[0m
e[0mJava SWIG bindings        : offe[0m
e[0mPython SWIG bindings      : offe[0m
e[0mPython bindings           : offe[0m
e[0mPython2                   : offe[0m
e[0mPython3                   : offe[0m
e[0me[0m
e[0mABC                       : offe[0m
e[0mCaDiCaL                   : offe[0m
e[0mCryptoMiniSat             : offe[0m
e[0mdrat2er                   : offe[0m
e[0mGLPK                      : offe[0m
e[0mKissat                    : offe[0m
e[0mLFSC                      : offe[0m
e[0mMP library                : gmpe[0m
e[0mReadline                  : offe[0m
e[0mSymFPU                    : offe[0m
e[0me[0m
e[0me[0m
e[0mCPPLAGS (-D...)           : NDEBUG CVC4_DUMPING CVC4_PROOF CVC4_STATISTICS_ONe[0m
e[0mCXXFLAGS                  : -O3 -Wall -Wno-deprecated -Wsuggest-override -Wnon-virtual-dtor -Wimplicit-fallthrough -Wshadow -Wno-class-memaccesse[0m
e[0mCFLAGS                    : -O3 -Wall -fexceptions -Wno-deprecated -Wimplicit-fallthrough -Wshadowe[0m
e[0mLinker flags              :  -fuse-ld=golde[0m
e[0me[0m
e[0mInstall prefix            : /nix/store/5fcniq4zf77rmdw0ypli7gwngvgpy1hg-cvc4-1.8e[0m
e[0me[0m
e[0mCVC4 license              : modified BSD

Note that this configuration is NOT built against any GPL'ed libraries, so
it is covered by the (modified) BSD license.  This is, however, not the best
performing configuration of CVC4.  To build against GPL'ed libraries which
improve CVC4's performance, re-configure with '-DENABLE_GPL -DENABLE_BEST'.e[0m
e[0me[0m
e[0mNow just type 'make', followed by 'make check' or 'make install'.e[0m
e[0me[0m
-- Configuring done
-- Generating done
e[33mCMake Warning:
  Manually-specified variables were not used by the project:

    BUILD_TESTING
    CMAKE_EXPORT_NO_PACKAGE_REGISTRY
    CMAKE_INSTALL_BINDIR
    CMAKE_INSTALL_DOCDIR
    CMAKE_INSTALL_INCLUDEDIR
    CMAKE_INSTALL_INFODIR
    CMAKE_INSTALL_LIBDIR
    CMAKE_INSTALL_LIBEXECDIR
    CMAKE_INSTALL_LOCALEDIR
    CMAKE_INSTALL_MANDIR
    CMAKE_INSTALL_OLDINCLUDEDIR
    CMAKE_INSTALL_SBINDIR
    CMAKE_POLICY_DEFAULT_CMP0025

e[0m
-- Build files have been written to: /build/source/build
cmake: enabled parallel building
@nix { "action": "setPhase", "phase": "buildPhase" }
building
build flags: -j12 SHELL=/nix/store/pj1hnyxhcsw1krmhnbb9rjvqssbzliw8-bash-5.2-p15/bin/bash
[  1%] e[34me[1mGenerating type_enumerator.cppe[0m
[  1%] e[34me[1mGenerating git_versioninfo.cppe[0m
[  1%] e[34me[1mGenerating theory_traits.he[0m
[  1%] e[34me[1mGenerating rewriter_tables.he[0m
[  1%] e[34me[1mGenerating smt2_tokens.he[0m
[  1%] e[34me[1mGenerating cvc_tokens.he[0m
[  1%] e[34me[1mGenerating Trace_tags.tmpe[0m
[  1%] e[34me[1mGenerating kind.he[0m
[  1%] e[34me[1mGenerating metakind.he[0m
[  1%] e[34me[1mGenerating Debug_tags.tmpe[0m
[  1%] e[34me[1mGenerating options.cpp, options_holder.h, arith_options.cpp, arrays_options.cpp, base_options.cpp, booleans_options.cpp, builtin_options.cpp, bv_options.cpp, datatypes_options.cpp, decision_options.cpp, expr_options.cpp, fp_options.cpp, main_options.cpp, parser_options.cpp, printer_options.cpp, proof_options.cpp, prop_options.cpp, quantifiers_options.cpp, sep_options.cpp, sets_options.cpp, smt_options.cpp, strings_options.cpp, theory_options.cpp, uf_options.cpp, arith_options.h, arrays_options.h, base_options.h, booleans_options.h, builtin_options.h, bv_options.h, datatypes_options.h, decision_options.h, expr_options.h, fp_options.h, main_options.h, parser_options.h, printer_options.h, proof_options.h, prop_options.h, quantifiers_options.h, sep_options.h, sets_options.h, smt_options.h, strings_options.h, theory_options.h, uf_options.he[0m
[  1%] e[34me[1mGenerating tptp_tokens.he[0m
fatal: not a git repository (or any of the parent directories): .git
[  1%] e[34me[1mGenerating type_checker.cppe[0m
[  1%] Built target gen-gitinfo
[  2%] e[34me[1mGenerating type_properties.he[0m
[  2%] Built target gen-tokens
[  2%] e[34me[1mGenerating Debug_tagse[0m
[  2%] e[34me[1mGenerating Debug_tags.he[0m
[  3%] e[34me[1mGenerating Trace_tagse[0m
[  3%] e[34me[1mGenerating Trace_tags.he[0m
[  3%] Built target gen-tags
[  3%] Built target gen-options
[  4%] e[34me[1mGenerating kind.cppe[0m
[  4%] e[34me[1mGenerating expr.he[0m
[  4%] Built target gen-theory
/build/source/src/expr/expr_template.h:0: error: undefined replacement ${getConst_instantiations}
make[2]: *** [src/expr/CMakeFiles/gen-expr.dir/build.make:114: src/expr/expr.h] Error 1
make[2]: *** Deleting file 'src/expr/expr.h'
make[2]: *** Waiting for unfinished jobs....
/build/source/src/expr/metakind_template.h:0: error: undefined replacement ${metakind_getConst_decls}
make[2]: *** [src/expr/CMakeFiles/gen-expr.dir/build.make:220: src/expr/metakind.h] Error 1
make[2]: *** Deleting file 'src/expr/metakind.h'
make[1]: *** [CMakeFiles/Makefile2:413: src/expr/CMakeFiles/gen-expr.dir/all] Error 2
make: *** [Makefile:146: all] Error 2

Anyone able to help me interpret these?

What exact versions of NixOS/home-manager/etc. are you using?

Sorry, should’ve included that.

 - system: `"x86_64-linux"`
 - host os: `Linux 6.1.0, NixOS, 23.05 (Stoat), 23.05.20221218.04f574a`
 - multi-user?: `yes`
 - sandbox: `yes`
 - version: `nix-env (Nix) 2.12.0`
 - nixpkgs: `/etc/nix/flake-channels/nixpkgs` (unstable)

Yea definitely a nixpkgs issue, nothing on your end. Package has just been failing to build for a few days according to hydra.

Ah thanks. Good to know!