wait_until accepts a time point that may be in the past. This generally works fine unless the time point is before the machine booted up.
The boost implementation will first calculate the difference to the current time: https://github.com/boostorg/thread/blob/boost-1.70.0/include/boost/thread/pthread/condition_variable_fwd.hpp#L270
Right afterward, the difference is added to the internal clock (detail::internal_chrono_clock::now() + d). However, the internal clock only starts when the machine was booted up (and not when the unix epoch started). Thus, the resulting timeout that is passed to do_wait_until may be negative (in both values, seconds and nanoseconds). Then pthread_cond_timedwait throws "Invalid argument".