The Eichler integral of E2 and q-brackets of t-hook functions