The optical gains of strained-layer hexagonal and cubic GaN quantum wells are calculated within the multiband effective mass approximation. The 6x6 multiband effective-mass Hamiltonians are used to calculate the band structures of hexagonal and cubic quantum wells. Non-Markovian relaxation is taken into account in the optical gain calculation. Calculated results show that the optical gains of the cubic quantum well are larger in magnitudes than those of the hexagonal GaN quantum well over the wide range of carrier densities. The expected inferior performance of the wurtzite quantum-well laser as compared with the cubic structure is mainly due to the heavier effective mass of the HH1 band of the former at the zone center.