Mix salt, paprika, cinnamon, cumin and cayenne together in a small bowl. Set aside. Warm butter (or oil) and sugar together in a large skillet over medium heat; add pumpkin seeds and spice mixture to pan and stir until sugar is melted and the seeds are fragrant, 5 to 6 minutes (add a lid when seeds start to pop). Remove from heat, add fresh rosemary and sprinkle on additional salt (if desired) and toss. Immediately spread seeds out on a parchment-lined baking sheet and cool completely before serving.