root@marietto:/usr/ports/emulators/virtualbox-ose # cd /usr/ports/emulators/virtualbox-ose root@marietto:/usr/ports/emulators/virtualbox-ose # make install clean ..... kBuild: Linking VBoxC kBuild: Linking VBoxSVC kBuild: Installing VBoxC => /usr/ports/emulators/virtualbox-ose/work/VirtualBox-6.1.22/out/freebsd.amd64/debug/bin/components/VBoxC.so kBuild: Installing VBoxSVC => /usr/ports/emulators/virtualbox-ose/work/VirtualBox-6.1.22/out/freebsd.amd64/debug/bin/VBoxSVC /usr/local/bin/python3.8 -mcompileall /usr/ports/emulators/virtualbox-ose/work/VirtualBox-6.1.22/out/freebsd.amd64/debug/bin/sdk/bindings/xpcom/python/xpcom Listing '/usr/ports/emulators/virtualbox-ose/work/VirtualBox-6.1.22/out/freebsd.amd64/debug/bin/sdk/bindings/xpcom/python/xpcom'... Compiling '/usr/ports/emulators/virtualbox-ose/work/VirtualBox-6.1.22/out/freebsd.amd64/debug/bin/sdk/bindings/xpcom/python/xpcom/__init__.py'... Listing '/usr/ports/emulators/virtualbox-ose/work/VirtualBox-6.1.22/out/freebsd.amd64/debug/bin/sdk/bindings/xpcom/python/xpcom/client'... Compiling '/usr/ports/emulators/virtualbox-ose/work/VirtualBox-6.1.22/out/freebsd.amd64/debug/bin/sdk/bindings/xpcom/python/xpcom/client/__init__.py'... Compiling '/usr/ports/emulators/virtualbox-ose/work/VirtualBox-6.1.22/out/freebsd.amd64/debug/bin/sdk/bindings/xpcom/python/xpcom/components.py'... Compiling '/usr/ports/emulators/virtualbox-ose/work/VirtualBox-6.1.22/out/freebsd.amd64/debug/bin/sdk/bindings/xpcom/python/xpcom/file.py'... Compiling '/usr/ports/emulators/virtualbox-ose/work/VirtualBox-6.1.22/out/freebsd.amd64/debug/bin/sdk/bindings/xpcom/python/xpcom/nsError.py'... Compiling '/usr/ports/emulators/virtualbox-ose/work/VirtualBox-6.1.22/out/freebsd.amd64/debug/bin/sdk/bindings/xpcom/python/xpcom/primitives.py'... Listing '/usr/ports/emulators/virtualbox-ose/work/VirtualBox-6.1.22/out/freebsd.amd64/debug/bin/sdk/bindings/xpcom/python/xpcom/server'... Compiling '/usr/ports/emulators/virtualbox-ose/work/VirtualBox-6.1.22/out/freebsd.amd64/debug/bin/sdk/bindings/xpcom/python/xpcom/server/__init__.py'... Compiling '/usr/ports/emulators/virtualbox-ose/work/VirtualBox-6.1.22/out/freebsd.amd64/debug/bin/sdk/bindings/xpcom/python/xpcom/server/enumerator.py'... Compiling '/usr/ports/emulators/virtualbox-ose/work/VirtualBox-6.1.22/out/freebsd.amd64/debug/bin/sdk/bindings/xpcom/python/xpcom/server/factory.py'... Compiling '/usr/ports/emulators/virtualbox-ose/work/VirtualBox-6.1.22/out/freebsd.amd64/debug/bin/sdk/bindings/xpcom/python/xpcom/server/loader.py'... Compiling '/usr/ports/emulators/virtualbox-ose/work/VirtualBox-6.1.22/out/freebsd.amd64/debug/bin/sdk/bindings/xpcom/python/xpcom/server/module.py'... Compiling '/usr/ports/emulators/virtualbox-ose/work/VirtualBox-6.1.22/out/freebsd.amd64/debug/bin/sdk/bindings/xpcom/python/xpcom/server/policy.py'... Compiling '/usr/ports/emulators/virtualbox-ose/work/VirtualBox-6.1.22/out/freebsd.amd64/debug/bin/sdk/bindings/xpcom/python/xpcom/vboxxpcom.py'... Compiling '/usr/ports/emulators/virtualbox-ose/work/VirtualBox-6.1.22/out/freebsd.amd64/debug/bin/sdk/bindings/xpcom/python/xpcom/xpcom_consts.py'... Compiling '/usr/ports/emulators/virtualbox-ose/work/VirtualBox-6.1.22/out/freebsd.amd64/debug/bin/sdk/bindings/xpcom/python/xpcom/xpt.py'... ===> Staging for virtualbox-ose-6.1.22_1 ===> virtualbox-ose-6.1.22_1 depends on file: /usr/local/etc/rc.d/vboxnet - not found ┌─────────────────────── virtualbox-ose-kmod-6.1.22_1 ─────────────────────────┐ │ ┌──────────────────────────────────────────────────────────────────────────┐ │ │ │+[x] DEBUG Debug symbols, additional logs and assertions │ │ │ │+[x] VIMAGE VIMAGE virtual networking support │ │ │ └──────────────────────────────────────────────────────────────────────────┘ │ ├──────────────────────────────────────────────────────────────────────────────┤ │ < OK > <Cancel> │ └──────────────────────────────────────────────────────────────────────────────┘ ===> License GPLv2 accepted by the user ===> virtualbox-ose-kmod-6.1.22_1 depends on file: /usr/local/sbin/pkg - found ===> Fetching all distfiles required by virtualbox-ose-kmod-6.1.22_1 for building ===> Extracting for virtualbox-ose-kmod-6.1.22_1 => SHA256 Checksum OK for VirtualBox-6.1.22.tar.bz2. ===> Patching for virtualbox-ose-kmod-6.1.22_1 ===> Applying extra patch /usr/ports/emulators/virtualbox-ose-kmod/../virtualbox-ose/files/extrapatch-Config.kmk cat: /usr/ports/emulators/virtualbox-ose-kmod/../virtualbox-ose/files/extrapatch-Config.kmk: No such file or directory ===> FAILED Applying extra patch /usr/ports/emulators/virtualbox-ose-kmod/../virtualbox-ose/files/extrapatch-Config.kmk *** Error code 1 Stop. make[3]: stopped in /usr/ports/emulators/virtualbox-ose-kmod *** Error code 1 Stop. make[2]: stopped in /usr/ports/emulators/virtualbox-ose-kmod *** Error code 1 Stop. make[1]: stopped in /usr/ports/emulators/virtualbox-ose *** Error code 1 Stop. make: stopped in /usr/ports/emulators/virtualbox-ose
Looks like the "extrapatch-Config.kmk" was removed by mistake (maybe by me). Although it's required only if compiling virtualbox with the DEBUG option turned on. As a quick workaround, can you disable the debug option are you really needing it? Apart from that the file needs to be added back (once I check what it contained) or the requirement for it removed in case it's not needed anymore.
(In reply to Guido Falsi from comment #1) The file was removed in commit df5c241ed2d1f1c7b7fb7d5f98d8721f0a8c840c Author: Kyle Evans <kevans@FreeBSD.org> Date: Thu Mar 12 00:41:32 2020 +0000 Looks like only part of it is still relevant.
to be honest,I'm not expert. I play with FreeBSD as an hobby. I don't remember when I have activated the debug option. I don't remember which options I have enabled during the compilation of virtualbox. If u can show me which option should I disable,I can do it. But please,try to be very clear. I don't want to waste my and your time.
(In reply to mario felicioni from comment #3) The option you can debug to make it build is named "DEBUG" in the requester in the log you posted: ┌─────────────────────── virtualbox-ose-kmod-6.1.22_1 ─────────────────────────┐ │ ┌──────────────────────────────────────────────────────────────────────────┐ │ │ │+[x] DEBUG Debug symbols, additional logs and assertions │ │ │ │+[x] VIMAGE VIMAGE virtual networking support │ │ │ └──────────────────────────────────────────────────────────────────────────┘ │ ├──────────────────────────────────────────────────────────────────────────────┤ │ < OK > <Cancel> │ └──────────────────────────────────────────────────────────────────────────────┘ (sorry cut&paste mangles it a little) You almost certainly don't need that if you're not an expert. By personal experience I can tell you debugging virtualbox is quite hard and also that debug builds of virtualbox tend to be unusable for real work. Anyway I'm going to add back the file shortly.
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=ae60747f725e63a879a5c0225a485ebc536e6966 commit ae60747f725e63a879a5c0225a485ebc536e6966 Author: Guido Falsi <madpilot@FreeBSD.org> AuthorDate: 2021-08-11 21:46:20 +0000 Commit: Guido Falsi <madpilot@FreeBSD.org> CommitDate: 2021-08-11 21:49:43 +0000 emulators/virtualbox-ose: Add back missing extra patch file Looks like this patch was removed in commit df5c241ed2d1 It is required to build with the DEBUG optioni (not default). PR: 257777 Reported by: Mario Felicioni <marietto2008@gmail.com> emulators/virtualbox-ose/files/extrapatch-Config.kmk (new) | 11 +++++++++++ 1 file changed, 11 insertions(+)
I added back a revised version of the missing file to the tree, Thanks.