Pyrolysis of biomass to produce fuels and chemical feedstocks