newbie needs guidance

I've managed to install 14.2 on a new i5 NUC13 and pkg install and configure a few things, but now I need guidance.

I want the latest Go 1.4.2 and GStreamer 1.26.0. I think they're in Ports.

One other thing: why use the Go port in favour of just following the instruction on go.dev?

Thank you.
 
One other thing: why use the Go port in favour of just following the instruction on go.dev?
Because the port (and by extension its package) is properly registered as being "installed" and can therefor be easily updated or removed. You will also have no problems with dependencies, or ports that depend on this particular port. In short, it makes everything easier to manage.

You could install everything by downloading their source code and compile everything from scratch yourself, but you will quickly find yourself in a so-called "dependency hell". Where some parts may or may not have the correct version, or you're stuck with a specific version because something else requires that version and can't work with anything else.
 
I don't see FreeBSD instructions on go.dev.

I was about to say that the sources from go.dev probably don't fit without patches in the port. But the port for 1.2.4 has no significant patches. I wonder how that came to be? Are the go devs taking FreeBSD patches upstream?
 
But the port for 1.2.4 has no significant patches.
That's also a good reason, in general, to use the FreeBSD port/package instead of downloading original sources and building everything yourself. Lots of ports require patches, some more than others, to build and work correctly on FreeBSD. The port submitter/maintainer already figured all this out, so you can simply do pkg install something or cd /usr/ports/example/something && make install and it'll work.
 
Thanks all, so packages it will. Any idea when these will be available?
lang/go124 does have a maintainer (go@freebsd.org, this info was gleaned from the Makefile for lang/go-devel.). If you look at the instructions for source-based installation, they are centered on processor architecture rather than specific OS/distro. FreeBSD most likely uses the instructions that are applicable to the amd64 arch / instruction set.

Looking at the git logs, there's several people who make commits for the golang port for FreeBSD. There's not that many committers for the Ports, while there are nearly 40,000 ports total. Sometimes, the maintainer for a given port is capable of keeping up with upstream and releasing a properly created FreeBSD port just a few days after upstream releases their latest stuff. Sometimes not. Port maintainers are volunteers. Most of the time, so are the programmers on the upstream projects.

Given all that, it's pretty much a system of honor and reputation. If you have a project like KDE, the reputation for KDE's high quality desktop is a motivating factor for the FreeBSD project to keep up with it, and prioritize resources for making sure KDE is packaged for FreeBSD, and runs correctly. But even with that, there may be a target schedule (which the FreeBSD project uses for OS releases), but it's not cut in stone. It's not out of question for showstoppers to crop up that mess that schedule up. FreeBSD does have -quarterly and -latest package repos. The -quarterly stuff gets built on a schedule. But even with that, it takes being willing to spend some time doing research and figuring out when your favorite port is going to have a package. Some people find it a fun rabbit hole to go down.
 
The Go/GStreamer project I'm working on resides on a Raspberry Pi 5 (Pi OS), but needs a more powerful computer. This is why I've bought the Intel i5 NUC13 and installed headless FreeBSD. I can wait a while for the latest Go & GStreamer and probably get by with the versions available today - assuming the GStreamer Bindings don't need porting. However, there a couple of other things I need to understand...

1 - Why VSCode, running on my Mac, isn't connecting to FreeBSD with Remote SSH extensions.
2 - Will I need to edit my bash scripts to run under sh, and where to export environment variables from.

As the title says, "newbie needs guidance" - at least on FreeBSD.
 
What are the versions of Go and GStreamer that you need and that are currently not in ports?

You can install bash, make it your user's login shell and set env vars in bash'es normal dotfiles. You can also run scripts in bash by starting them with
Code:
#! /usr/bin/env bash
 
What are the versions of Go and GStreamer that you need and that are currently not in ports?
I think the latest Go 1.4.2 and GStreamer 1.26.0 are already in Ports, but I've been advised in this tread to wait for the packages, as this will make my life easier. Thanks for the info on bash.
 
I think the latest Go 1.4.2 and GStreamer 1.26.0 are already in Ports, but I've been advised in this tread to wait for the packages, as this will make my life easier. Thanks for the info on bash.
In all honesty, if the stuff is in the FreeBSD ports tree, there's no real reason to wait for packages. Just grab the port from the cgit, put it into your own local copy, and you're good to type
make && make install. Do pay attention to versions, though: you keep typing 1.4.2, while even upstream's version is 1.24.2, and the ports tree shows 1.24.2...

But if you're trying to make a FreeBSD-specific GStreamer plugin in Golang, I think your best option is to get whatever's already available in Ports, and use that as your starting point, rather than upstream. If you want the plugin to work on other OSes, first check to see what versions of Golang and GStreamer their repos offer. Yeah, it's gonna be a lot of work, a lot of effort duplicated across OSes - that's just the nature of the beast, no way around it.

1 - Why VSCode, running on my Mac, isn't connecting to FreeBSD with Remote SSH extensions.
On your new installation, did you enable the SSHd daemon? if not, the easy way to do that is through bsdconfig. Just dig around the menus, the option to turn it on is definitely there.
 
you keep typing 1.4.2
Indeed, typing is not one my talents.
if you're trying to make a FreeBSD-specific GStreamer plugin in Golang
No, I'm wanting to carry on developing my Go/GStreamer application, but on better hardware and away from Linux. I'm attracted to FreeBSD's stability, when compared with Linux.
check to see what versions of Golang and GStreamer their repos offer
I'm using go-gst bindings which is actively supported. It has some known bugs, but what hasn't?
did you enable the SSHd daemon
Yes. I can ssh from my Mac into FreeBSD. VSCode doesn't support BSD. Some have work-arounds, but Microsoft keeps moving the goal post. This is probably the biggest problem for me and may force me to return to Linux - or spend months learning and configuring vim.
 
No, I'm wanting to carry on developing my Go/GStreamer application, but on better hardware and away from Linux. I'm attracted to FreeBSD's stability, when compared with Linux.
If you want to develp your own Go/GStreamer application, for your own use, that's nice, but you still have to decide on which OS you want to run it when everything is said and done. Because that's where you will need to do your development, as well.

If you insist on using Microsoft-based tools to develop something that is ultimately supposed to run on FreeBSD, there are ways to do that. Your FreeBSD installation is quite capable of hosting a git server, a Jupyter server, and frankly anything. Just take a look at what remote tools VSCode is capable of working with, and install the corresponding server software on your FreeBSD installation. But to take advantage of that, it makes sense to learn the ports/packages system. The same ideas and same workflow will apply even if you return to Linux. That's because exact same software is available in both BSDs and Linux.

FreeBSD does have development tools other than vim/emacs available in ports - there's a good chance you'll find something you like that has actually been ported to FreeBSD. The advantage of going with ports/packages that were prepared specifically for FreeBSD - that has been pointed out earlier in this thread. Not to mention that they are much better integrated with the FreeBSD development stack than tools making remote connections that originate from different OSes.
 
If you insist on using Microsoft-based tools
I'd prefer to get completely away from Microsoft. That's why my main machine is a Mac, but I'm short on desk space so I use VScode to access the target machine. IE. I would like the target machine to be a headless mini-pc running FreeBSD or Linux. The app will be open source for the amateur television community.
We had a thread on vscode and ssh here a couple months back IIRC.
I have read this. Too complicated and likely to break with every MS update.

Another IDE I've looked at is Zed. They are introducing remote ssh, but FreeBSD is not on list. I've posted a feature request on their GitHub QA. I think the BSD orgs need to push the mainstream harder. I haven't given up yet.
 
I'd prefer to get completely away from Microsoft. That's why my main machine is a Mac, but I'm short on desk space so I use VScode to access the target machine. IE. I would like the target machine to be a headless mini-pc running FreeBSD or Linux. The app will be open source for the amateur television community.
In which case, I think your best bet is to install devel/py-jupyter-server on that headless FreeBSD installation, and learn a bit about Jupyter Notebooks, how they work, and what are the benefits and pitfalls of using them.

It's not out of question for Jupyter to support Golang. I found this with an off-the-cuff Google search for setting up Golang support on Jupyter.

VSCode should be able to connect to a Jupyter Server on your headless installation, and handle the compilation/testing that way.

The alternative would be to install command-line utilities, and learn how to work with sed and awk - all of which is available in FreeBSD ports.

An even simpler strategy would be to just search the ports for equivalent functionality. You'll be surprised at how well GStreamer and other multimedia stuff works under FreeBSD.

One reason to stick with ports (as opposed to packages) is that pre-compiled ports are usually compiled with very minimal Makefile flags set. As a result, sometimes useful features are missing from pre-compiled packages. This is why I go with ports, I can turn everything on and get the full set of features.
 
Is that how you discovered FreeBSD, by using it without knowing?
Having owned a Commodore PET, Northstar Horizon, and a few Intel builds running anything I could get my hands on, including SVR4 and SCO, my first Apple product was the Macintosh LC.

I became interested in video editing, so was forced onto Windows for a period as it was the only option at the time. It was extremely difficult to keep it running for more than a couple of hours with crashing. Then Apple announced OS X, so I bought a Mac Pro and never looked back. My current desktop is an 11 year old 27inch iMac, but I tinker with Raspberry Pi's and Mini-PCs, writing software for Digital Amateur TeleVision.

DATV and Radio amateur software is mostly written for Windows or Linux, but the majority of users are obsessed with Windows, Windows and Windows, whilst constantly complaining after every update.

At 79 I struggle to remember the things I once knew. I suppose I'm a reborn newbie, so I'm finding the BSD community to be friendly, helpful and witty.
 
FWIW, FreeBSD does have a ton of ports relating to video editing and Digital Amateur TV. If you ask around, I'm sure you'll find that something useful is already in ports. My point is, sometimes it doesn't make sense to reinvent the wheel.
 
I only need a headless server for this application. The purpose of which is to control a microwave DATV repeater, situated at some remote location. Basically, RF in -> demodulate -> decode -> switching -> encode - modulate -> RF out. The switching part is there to insert a slideshow when no RF is being received. The RF parts are external to the mini-pc and there are multiple RF and Ethernet inputs and outputs.

Thank you, but I think most of the DATV ports are for USB Tuners and Players, so not relevant to my use case.
 
Some have work-arounds, but Microsoft keeps moving the goal post. This is probably the biggest problem for me and may force me to return to Linux - or spend months learning and configuring vim

Can I throw my 2 cents in.
Why vscode.
Gstreamer sounds awesome for open source TV application.
Why vscode?
Gstreamer code can be written in FreeBSD EasyEditor. No need to learn VIM. Just organize your files in a meanful mannor... Tooo much gets nitpicked.
Just like above. What exact version of Gstreamer or Go should not be relevant. You need to write for this. Not by a strict limitation of versions needed...
Unless some special feature was added that you 'must have' you should be able to write independently of versioning. Not all code does Py2 to Py3 disaster requiring rewrite.


Welcome Aboard.
I am not a programmer but hope to be one day...
 
Welcome Aboard.
What you say is correct, but I like the extra features an IDE provides, although I'd prefer one not owned by Microsoft.

The good new is, I've now got VSCode remoting into FreeBSD.

As for GStreamer, it's the most complex and difficult thing I've ever seen, but I need seamless switching between sources. If I were to try writing that myself, I'd be even more out of my depth. Anyhow. the app isn't just GStreamer code. There's quite a lot of other stuff too, such as control software, remote management, handling config files, logging, the list goes on.

I need to lay down now, before installing Go and GStreamer.
 
Back
Top