Wednesday, August 20, 2025

Linux Brew On Chrome OS Flex 2025

Linux Brew On Chrome OS Flex 2025

I like homebrew so much, that I try it out immediately when I knew about it. At that time, Linux brew is not so matured, I encounter a lot of issues, I didn't know much about ruby program, so I give up.

Now Linux brew is quite matured. It install on Linux without much problem.

There was one time, I was in doubt, why do I need a Linux brew. My Linux can installed a lot of open source packages. This is different from macOS, which doesn’t have a good channel to install those software.

Later I found out that I need it for development. Since homebrew install the software and library in a separated directory, I can create a different development environment apart from the system.

For example, the Java on my system now is mainly Java 17 or above, but I wanted to have Java 8 for developemnt.

This is how I do it, after setup Linux brew:

$ brew install openjdk@8
$ export JAVA_HOME=/home/linuxbrew/.linuxbrew/opt/openjdk@8
$ export PATH=$JAVA_HOME/bin:$PATH
$ java -version
$ openjdk version "1.8.0_462"
OpenJDK Runtime Environment (build 1.8.0_462-b08)
OpenJDK 64-Bit Server VM (build 25.462-b08, mixed mode)

This even works on Chromebook on ARM chips.

No comments: