Solved Change from 'installed as dependency' to 'explicitly installed'

Hi all,

Certain ports (BUILD_DEPENDS) are required to install other ports, but not to run them. This means that executing pkg autoremove will uninstall these packages.
However, many of these ports are needed for the installation of many other ports, which means that they are installed-uninstalled-reinstalled-etc.
For example, devel/llvm10 just got installed for the Nth time. And this port takes quite some time to compile...

Now, if I would like to change llvm10 from being installed as a dependency to being installed explicitly, without having to make deinstall && make reinstall, would it suffice to

Code:
# sqlite3 /var/db/pkg/local.sqlite 'update packages set automatic = 0 where origin = "devel/llvm10"'

Or would it take more than that?

Thanks in advance,
Rob
 
I tend to update my packages every now and then, so I'm never done building... :)

Thanks for the pkg set hint; looking at the command, I think it does the same as my solution, but it's a lot less typing.
 
I tend to update my packages every now and then
Any particular reason why you're not using packages and are building from ports? Unless you change default versions or various options there's nothing to gain by building from ports.

think it does the same as my solution, but it's a lot less typing.
Best not to muck around in that database directly. You don't want to cause more damage or inconsistencies. The various pkg(8) tools will do pretty much everything for you and will be updated accordingly should the structure change.
 
Any particular reason why you're not using packages and are building from ports?
I have installed many ports with custom options. When I want to play around with stuff (or really need certain options) I enable options, and I usually disable options I don't intend to use. I like to keep my system clean, and only install what I need.
 
Back
Top