Weak hydrogen bonds in solid hydroxides and hydrates