Other countries such as USA work in a similar manner. Work permits such as green card, to name an example.
The people who complain about regulations and law either don't understand why they exist or how they work, or they have an interest in the abolishment of it because they benefit from that.
Then you get that BS about how USA is better off than EU. Well, if you're healthy, educated, and employed, sure. Otherwise? You can just use your eyes. Go drive through a rich and poor neighborhood in both. The poverty in USA is horrendous, and the effects are shown. We got poverty too, but not as severe. No need to go to that area between West and East coast. You can experience this right near the Bay Area. San Jose is supposedly a mess. I'd love to compare my visit to a Fry's in San Jose 2005 with today's.
Fry's closed in 2021.
This has nothing to do with US vs EU or any other trope you seek to my comment as being on a particular side of of a particular issue in order to get people of a certain bent to support whatever your side is (isn't team politics great).
Ask yourself this. If the license Spain is trying to enforce here had the exact same requirements but was granted by some 3rd party (industry consortium or whatever) and the government didn't care whether they held it would you still be acting like it's such a big deal for them to have it or not?
Does holding the license or not fundamentally change the nature of the business the license holder is in?
The government is essentially granting legitimacy to a bad thing here in exchange for some money being spent in the right directions and enough of it on "good things" that it's plausibly deniable.