Production of coffee and coffee substitutes