Theory and design of a photoinjector-driven chirped pulse free-electron maser