preheat an oven to 375 degrees f (190 degrees c). spread the rosemary sprigs and garlic cloves into a 9x13-inch baking dish. place the duck legs on top of the rosemary, and sprinkle with salt and five-spice powder. bake in the preheated oven for 1 hour.