  Let $r\geq 2$ be an integer. The generalized BGW tau-function for the
Gelfand--Dickey hierarchy of $(r-1)$ dependent variables (aka the $r$-reduced
KP hierarchy) is defined as a particular tau-function that depends on $(r-1)$
constant parameters $d_1,\dots,d_{r-1}$. In this paper we show that this
tau-function satisfies a family of linear equations, called the $W$-constraints
of the second kind. The operators giving rise to the linear equations also
depend on $(r-1)$ constant parameters. We show that there is a one-to-one
correspondence between the two sets of parameters.
