Onset of terminal differentiation in adult stem cell lineages is commonly marked by robust activation of new transcriptional programs required to make the appropriate differentiated cell type(s). In the Drosophila male germ line stem cell lineage, the switch from proliferating spermatogonia to spermatocyte is accompanied by one of the most dramatic transcriptional changes in the fly, as over 1000 new transcripts turn on in preparation for meiosis and spermatid differentiation. Here we show that function of the coactivator complex Mediator is required for activation of hundreds of new transcripts in the spermatocyte program. Mediator appears to act in a sequential hierarchy, with the testis activating Complex (tMAC), a cell type specific form of the Mip/dREAM general repressor, required to recruit Mediator subunits to the chromatin, and Mediator function required to recruit the testis TAFs (tTAFs), spermatocyte specific homologs of subunits of TFIID. Mediator, tMAC and the tTAFs co-regulate expression of a major set of spermatid differentiation genes. The Mediator subunit Med22 binds the tMAC component Topi when the two are coexpressed in S2 cells, suggesting direct recruitment. Loss of Med22 function in spermatocytes causes meiosis I maturation arrest male infertility, similar to loss of function of the tMAC subunits or the tTAFs. Our results illuminate how cell type specific versions of the Mip/dREAM complex and the general transcription machinery cooperate to drive selective gene activation during differentiation in stem cell lineages.