Trivially with robots.txt, which is standardized and so well known among anybody doing webservers that not having such a rule ought to be considered as consent.
About the same as the rule here in Sweden on filming - you're free to film in any private venue until told not to.
Can't anyone exclude their pages from being scraped by google if they so desire?
If you post something on a site that allows itself to be scraped, only then it will go on google.