Even pretty draconian legislation can stand if it doesn't affect the majority of the country and is supported by powerful industry groups. I could definitely see some kind of compiler licensing requirement meeting these criteria.
[1] https://en.wikipedia.org/wiki/DeCSS#Legal_response
[2] https://en.wikipedia.org/wiki/AACS_encryption_key_controvers...