Folks: Let's get Claude Code native installer working for FreeBSD

LOL - When you "buy" something you usually know what you are paying for :cool:

This seems like putting out a lot of money up front and then reaching into the "mystery bag" to see what you get.
and sometimes what you get is AI psychosis, which, big deal, talk to us long enough and we'll make you go psychotic for free
 
LOL - When you "buy" something you usually know what you are paying for :cool:

This seems like putting out a lot of money up front and then reaching into the "mystery bag" to see what you get.

Well, I'm in there. Cover me.

I am moderately miffed that they effectively restrict my choice of IDE. If I use one of their UIs or Visual Studio then I can run off the monthly plan. If I want Emacs I have to use their API plan.
 
Well, I'm in there. Cover me.

I am moderately miffed that they effectively restrict my choice of IDE. If I use one of their UIs or Visual Studio then I can run off the monthly plan. If I want Emacs I have to use their API plan.
Explain. Wouldn't you just run CC in the emacs-terminal-client? Use the @ and ! glyphs in CC to do those sorts of things. When you need to edit, edit? I don't use emacs, but would be happy to help.
 
Explain. Wouldn't you just run CC in the emacs-terminal-client? Use the @ and ! glyphs in CC to do those sorts of things. When you need to edit, edit? I don't use emacs, but would be happy to help.

I was too brief in my post. Yes, you can run claude code in emacs terminal.

But I was talking about gptel, which is its own interface for integrating LLMs with Emacs, and to use it with Anthropic you have to use the API. https://github.com/karthink/gptel

That is different in VSCode where Anthropic offers a binary module for it that uses the Claude Pro monthly account.
 
Latest status as of today for Claude Code on FreeBSD, as per https://github.com/anthropics/claude-code/issues/30640#issuecomment-4227236808:

Hey folks, a couple updates on where we are with Claude Code on FreeBSD:
  • Starting with Claude Code 2.1.101, you can run Claude Code under Linuxulator with this additional env var:
    Code:
    BUN_JSC_useBBQJIT=0 claude
  • Regarding a native FreeBSD build - a proper port means getting Bun building on FreeBSD. We're not quite there yet, but would like to get there in the future. For now you'll have to rely on Linuxulator.
 
So they want to support FreeBSD but it has to go through bun. As someone there said, "Now we have two problems."
They act all nice to us but then we have to do the work. They won't. So they're thumbing their nose at us.
 
So they want to support FreeBSD but it has to go through bun. As someone there said, "Now we have two problems."
They act all nice to us but then we have to do the work. They won't. So they're thumbing their nose at us.
Why does something even needs to be installed? Does it work offline? I see a closed web application...
 
What is Bun and why is it hard to port?

ETA: OK, some Javascript runtime and bundler. If it runs in Linuxulator it is probably not too hard to port. Doesn't mean it would be quick.
 
What is Bun and why is it hard to port?

ETA: OK, some Javascript runtime and bundler. If it runs in Linuxulator it is probably not too hard to port. Doesn't mean it would be quick.
The BUN (Blood Urea Nitrogen) test measures the level of nitrogenous urea in the blood to assess kidney function and hydration, helping to diagnose kidney disease, dehydration, or liver problems.
🤣
I am sorry
 
What is Bun and why is it hard to port?

ETA: OK, some Javascript runtime and bundler. If it runs in Linuxulator it is probably not too hard to port. Doesn't mean it would be quick.
The Anthropic guy said this:
to be upfront - porting Bun to FreeBSD is nontrivial to get right, and we're not planning to keep the (deprecated since January) JS build around.
So in my mind that's saying: "We're not going to support FreeBSD."
 
I asked about Bun support a few times with FreeBSD for a game (they switched from Node); this seems to be the main request thread: https://github.com/oven-sh/bun/issues/1524

Node ran under Wine on FreeBSD, but I couldn't figure out Bun (I'm thinking running it through winecmd to force Windows paths might do something different)



I've heard of Deno and another Js runtime; Node and Deno support BSD but I'm not sure how Bun's appealing with no BSD support (there was also some odd ticket with Bun about Windows metadata randomly disappearing on CIs)
 
Why can't the AI figure out how to do a port of itself?
Claude Code is written TypeScript, which transpiles to JavaScript and is packaged with the JavaScript Core runtime.

From Claude:
Claude Code is completely unusable on FreeBSD because all bash commands hang indefinitely. The root cause is that FreeBSD platform binaries are missing from the bundled distribution — specifically, bundled tools like ripgrep ship binaries for macOS, Linux, and Windows, but there's no x64-freebsd variant.
 
As a workaround for the lack of native support at the moment, and the manual setup/management required was annoying me, I've knocked up a shell script to manage Claude Code running under Linuxulator, tested on arm64 and aarch64 (under QEMU, not got a native host to test on at the moment) on 15.0p5 and latest 14.4/14.3 in VMs and jails. It's not a perfect solution, but will cleanly uninstall itself with a built-in command when we (hopefully) get the native port. Fairly heavily battle tested on the native installs and checks for common areas where you can shoot yourself in the foot, seems to work fine in jails too. Had Claude Code do the heavy lifting for me, but I've sanity checked it myself. Requires Linuxulator running and one of the Rocky/CentOS bases installed and configured correctly, included all the info required on the README, but it's mostly following the same info that's in the handbook, with a couple of extra notes.


Hopefully it'll make life easier for folk while we're stuck in the current situation, any feedback is welcome.
 
Back
Top