There are only two solutions. Government grants, or restricting Freedom 0 (The freedom to run the program as you wish, for any purpose) and embracing a non-commercial model publication model. The latter model is undesirable because it turns everything into a subsidiary of Oracle.
These Silicon Valley companies are obscenely valuable. They should be taxed steeply.