libvbox icon indicating copy to clipboard operation
libvbox copied to clipboard

MacOS Silicon fails to build

Open nikole-dunixi opened this issue 3 months ago • 3 comments

Problem

I can't seem to be able to build this library. I'm not sure if this is just because I'm on macos arm, or if it's something I haven't set up correctly so any advice or guidance would be greatly appreciated!

System/Environment

MacOS

  • Apple M3
  • 15.7.1 (24G231)

VirtualBox:

  • Version 7.2.4 r170995 (Qt6.8.0 on cocoa)

VirtualBox SDK:

  • VirtualBoxSDK-7.2.4-170995.zip
    • I've attached this directly for reproducibility, but I got it with curl
      $ curl -JLO "https://download.virtualbox.org/virtualbox/7.2.4/VirtualBoxSDK-7.2.4-170995.zip"
      

NIX Flake (Optional):

  • I've tested this in both a vanilla environment and in a nix-flake with the exact same outcome but I'll include the flake I've been testing with to potentially save time with reproduction.
{

  description = "A basic flake with a shell";
  inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
  inputs.systems.url = "github:nix-systems/default";
  inputs.flake-utils = {
    url = "github:numtide/flake-utils";
    inputs.systems.follows = "systems";
  };
  inputs.libvbox = {
    url = "github:zrax/libvbox";
    flake = false;
  };

  outputs =
    { nixpkgs, flake-utils, libvbox, ... }:
    flake-utils.lib.eachDefaultSystem (
      system:
      let
        pkgs = nixpkgs.legacyPackages.${system};
        # VirtualBox SDK
        vboxsdk = pkgs.stdenv.mkDerivation rec {
          name = "virtualbox-sdk";
          src = pkgs.fetchzip {
            url = "https://download.virtualbox.org/virtualbox/7.2.4/VirtualBoxSDK-7.2.4-170995.zip";
            hash = "sha256-FxDNz10Y9Zqp30IkW8K4t7SAKyIfbw29mnf4G2M+Zy0=";
          };

          installPhase = ''
            runHook preInstall

            echo "Current directory contents:"
            ls -la

            # Create directory structure
            mkdir -p $out/bindings
            cp -r ./bindings/. $out/bindings/

            runHook postInstall
          '';
        };
        libvboxPkg = pkgs.stdenv.mkDerivation {
          pname = "libvbox";
          version = "1.0.0";
          src = libvbox;

          nativeBuildInputs = [ pkgs.cmake ];
          buildInputs = [ vboxsdk ];

          cmakeFlags = [
            # VirtualBox
            "-DVirtualBoxSDK_DIR=${vboxsdk}/"
            "-DVirtualBoxSDK_IDL_DIR=${vboxsdk}/bindings/xpcom/idl/"
            "-DVirtualBoxSDK_INCLUDE_DIR=${vboxsdk}/bindings/xpcom/include/"
            "-DVirtualBoxSDK_IID_LIB=${vboxsdk}/bindings/xpcom/lib/"
            "-DVirtualBoxSDK_VERSION=7.2.4"
            # FIXME: MacOS specific, but should be generalizable
            "-DCMAKE_OSX_DEPLOYMENT_TARGET=13.3"
            "-DVirtualBox_XPCOM_LIB=/Applications/VirtualBox.app/Contents/MacOS/VBoxXPCOM.dylib"
          ];

          installPhase = ''
            runHook preInstall

            mkdir -p $out/{lib,include}
            cp -r ../include/* $out/include/
            cp lib/* $out/lib/

            runHook postInstall
          '';
        };

      in
      {
        devShells.default = pkgs.mkShell {
          packages = [
            # Direct Dependencies
            pkgs.bashInteractive
            pkgs.llvm
            pkgs.cmake
          ];

          buildInputs = [
            vboxsdk
            libvboxPkg
          ];

          shellHook = ''
            export VBOX_SDK=${vboxsdk}
          '';
        };
      }
    );
}

Steps to Reproduce/Attempt

I've cloned this repo down and downloaded the zip. I can initialize the project and it appears to 100% compile but it appears to fail linking and I'm not sure why. It might be just a matter of arm64 not being supported, but I am not sure if I'm missing some configuration that should be obvious.

Here are the commands I executed to build:

$ export vboxsdk=~/sdk # <- this is where I extracted the zip directory
$ mkdir build
$ cd build
$ cmake .. "-DVirtualBoxSDK_DIR=${vboxsdk}/" \
            "-DVirtualBoxSDK_IDL_DIR=${vboxsdk}/bindings/xpcom/idl/" \
            "-DVirtualBoxSDK_INCLUDE_DIR=${vboxsdk}/bindings/xpcom/include/" \
            "-DVirtualBoxSDK_IID_LIB=${vboxsdk}/bindings/xpcom/lib/" \
            "-DVirtualBoxSDK_VERSION=7.2.4" \
            "-DCMAKE_OSX_DEPLOYMENT_TARGET=13.3" \
            "-DVirtualBox_XPCOM_LIB=/Applications/VirtualBox.app/Contents/MacOS/VBoxXPCOM.dylib"
$ cmake --build .
Image Image Image

Unabridged Error

(My apologies, this is GNARLY!)

Undefined symbols for architecture arm64:
  "_IID_IAdditionsFacility", referenced from:
      VBox::IAdditionsFacility::get_IID() in additionsfacility.cpp.o
  "_IID_IAdditionsStateChangedEvent", referenced from:
      VBox::IAdditionsStateChangedEvent::get_IID() in statechangedevent.cpp.o
  "_IID_IAppliance", referenced from:
      VBox::IAppliance::get_IID() in appliance.cpp.o
  "_IID_IAudioAdapter", referenced from:
      VBox::IAudioAdapter::get_IID() in audioadapter.cpp.o
  "_IID_IAudioAdapterChangedEvent", referenced from:
      VBox::IAudioAdapterChangedEvent::get_IID() in objchangedevent.cpp.o
  "_IID_IAudioSettings", referenced from:
      VBox::IAudioSettings::get_IID() in audiosettings.cpp.o
  "_IID_IBandwidthControl", referenced from:
      VBox::IBandwidthControl::get_IID() in bandwidthcontrol.cpp.o
  "_IID_IBandwidthGroup", referenced from:
      VBox::IBandwidthGroup::get_IID() in bandwidthgroup.cpp.o
  "_IID_IBandwidthGroupChangedEvent", referenced from:
      VBox::IBandwidthGroupChangedEvent::get_IID() in objchangedevent.cpp.o
  "_IID_IBooleanFormValue", referenced from:
      VBox::IBooleanFormValue::get_IID() in formvalue.cpp.o
  "_IID_ICPUChangedEvent", referenced from:
      VBox::ICPUChangedEvent::get_IID() in cpuchangedevent.cpp.o
  "_IID_ICPUExecutionCapChangedEvent", referenced from:
      VBox::ICPUExecutionCapChangedEvent::get_IID() in cpuchangedevent.cpp.o
  "_IID_ICPUProfile", referenced from:
      VBox::ICPUProfile::get_IID() in cpuprofile.cpp.o
  "_IID_ICanShowWindowEvent", referenced from:
      VBox::ICanShowWindowEvent::get_IID() in showwindowevent.cpp.o
  "_IID_ICertificate", referenced from:
      VBox::ICertificate::get_IID() in certificate.cpp.o
  "_IID_IChoiceFormValue", referenced from:
      VBox::IChoiceFormValue::get_IID() in formvalue.cpp.o
  "_IID_IClipboardErrorEvent", referenced from:
      VBox::IClipboardErrorEvent::get_IID() in clipboardevent.cpp.o
  "_IID_IClipboardEvent", referenced from:
      VBox::IClipboardEvent::get_IID() in clipboardevent.cpp.o
  "_IID_IClipboardFileTransferModeChangedEvent", referenced from:
      VBox::IClipboardFileTransferModeChangedEvent::get_IID() in modechangedevent.cpp.o
  "_IID_IClipboardModeChangedEvent", referenced from:
      VBox::IClipboardModeChangedEvent::get_IID() in modechangedevent.cpp.o
  "_IID_ICloudClient", referenced from:
      VBox::ICloudClient::get_IID() in cloudclient.cpp.o
  "_IID_ICloudMachine", referenced from:
      VBox::ICloudMachine::get_IID() in cloudmachine.cpp.o
  "_IID_ICloudNetwork", referenced from:
      VBox::ICloudNetwork::get_IID() in cloudnetwork.cpp.o
  "_IID_ICloudNetworkEnvironmentInfo", referenced from:
      VBox::ICloudNetworkEnvironmentInfo::get_IID() in cloudnetwork.cpp.o
  "_IID_ICloudNetworkGatewayInfo", referenced from:
      VBox::ICloudNetworkGatewayInfo::get_IID() in cloudnetwork.cpp.o
  "_IID_ICloudProfile", referenced from:
      VBox::ICloudProfile::get_IID() in cloudprofile.cpp.o
  "_IID_ICloudProfileChangedEvent", referenced from:
      VBox::ICloudProfileChangedEvent::get_IID() in cloudprofileevent.cpp.o
  "_IID_ICloudProfileRegisteredEvent", referenced from:
      VBox::ICloudProfileRegisteredEvent::get_IID() in cloudprofileevent.cpp.o
  "_IID_ICloudProvider", referenced from:
      VBox::ICloudProvider::get_IID() in cloudprovider.cpp.o
  "_IID_ICloudProviderListChangedEvent", referenced from:
      VBox::ICloudProviderListChangedEvent::get_IID() in cloudproviderevent.cpp.o
  "_IID_ICloudProviderManager", referenced from:
      VBox::ICloudProviderManager::get_IID() in cloudprovidermanager.cpp.o
  "_IID_ICloudProviderRegisteredEvent", referenced from:
      VBox::ICloudProviderRegisteredEvent::get_IID() in cloudproviderevent.cpp.o
  "_IID_ICloudProviderUninstallEvent", referenced from:
      VBox::ICloudProviderUninstallEvent::get_IID() in cloudproviderevent.cpp.o
  "_IID_IConsole", referenced from:
      VBox::IConsole::get_IID() in console.cpp.o
  "_IID_ICursorPositionChangedEvent", referenced from:
      VBox::ICursorPositionChangedEvent::get_IID() in cursorpositionchangedevent.cpp.o
  "_IID_IDHCPConfig", referenced from:
      VBox::IDHCPConfig::get_IID() in dhcpconfig.cpp.o
  "_IID_IDHCPGlobalConfig", referenced from:
      VBox::IDHCPGlobalConfig::get_IID() in dhcpconfig.cpp.o
  "_IID_IDHCPGroupCondition", referenced from:
      VBox::IDHCPGroupCondition::get_IID() in dhcpgroupcondition.cpp.o
  "_IID_IDHCPGroupConfig", referenced from:
      VBox::IDHCPGroupConfig::get_IID() in dhcpconfig.cpp.o
  "_IID_IDHCPIndividualConfig", referenced from:
      VBox::IDHCPIndividualConfig::get_IID() in dhcpconfig.cpp.o
  "_IID_IDHCPServer", referenced from:
      VBox::IDHCPServer::get_IID() in dhcpserver.cpp.o
  "_IID_IDataStream", referenced from:
      VBox::IDataStream::get_IID() in datastream.cpp.o
  "_IID_IDirectory", referenced from:
      VBox::IDirectory::get_IID() in directory.cpp.o
  "_IID_IDisplay", referenced from:
      VBox::IDisplay::get_IID() in display.cpp.o
  "_IID_IDisplaySourceBitmap", referenced from:
      VBox::IDisplaySourceBitmap::get_IID() in displaysourcebitmap.cpp.o
  "_IID_IDnDBase", referenced from:
      VBox::IDnDBase::get_IID() in dndbase.cpp.o
  "_IID_IDnDModeChangedEvent", referenced from:
      VBox::IDnDModeChangedEvent::get_IID() in modechangedevent.cpp.o
  "_IID_IDnDSource", referenced from:
      VBox::IDnDSource::get_IID() in dndsource.cpp.o
  "_IID_IDnDTarget", referenced from:
      VBox::IDnDTarget::get_IID() in dndtarget.cpp.o
  "_IID_IEmulatedUSB", referenced from:
      VBox::IEmulatedUSB::get_IID() in emulatedusb.cpp.o
  "_IID_IEvent", referenced from:
      VBox::IEvent::get_IID() in event.cpp.o
  "_IID_IEventListener", referenced from:
      VBox::IEventListener::get_IID() in eventlistener.cpp.o
  "_IID_IEventSource", referenced from:
      VBox::IEventSource::get_IID() in eventsource.cpp.o
  "_IID_IEventSourceChangedEvent", referenced from:
      VBox::IEventSourceChangedEvent::get_IID() in objchangedevent.cpp.o
  "_IID_IExtPack", referenced from:
      VBox::IExtPack::get_IID() in extpack.cpp.o
  "_IID_IExtPackBase", referenced from:
      VBox::IExtPackBase::get_IID() in extpack.cpp.o
  "_IID_IExtPackFile", referenced from:
      VBox::IExtPackFile::get_IID() in extpack.cpp.o
  "_IID_IExtPackInstalledEvent", referenced from:
      VBox::IExtPackInstalledEvent::get_IID() in extpackinstalledevent.cpp.o
  "_IID_IExtPackManager", referenced from:
      VBox::IExtPackManager::get_IID() in extpackmanager.cpp.o
  "_IID_IExtPackPlugIn", referenced from:
      VBox::IExtPackPlugIn::get_IID() in extpackplugin.cpp.o
  "_IID_IExtPackUninstalledEvent", referenced from:
      VBox::IExtPackUninstalledEvent::get_IID() in extpackinstalledevent.cpp.o
  "_IID_IExtraDataCanChangeEvent", referenced from:
      VBox::IExtraDataCanChangeEvent::get_IID() in extradatachangedevent.cpp.o
  "_IID_IExtraDataChangedEvent", referenced from:
      VBox::IExtraDataChangedEvent::get_IID() in extradatachangedevent.cpp.o
  "_IID_IFile", referenced from:
      VBox::IFile::get_IID() in file.cpp.o
  "_IID_IFirmwareSettings", referenced from:
      VBox::IFirmwareSettings::get_IID() in firmwaresettings.cpp.o
  "_IID_IForm", referenced from:
      VBox::IForm::get_IID() in form.cpp.o
  "_IID_IFormValue", referenced from:
      VBox::IFormValue::get_IID() in formvalue.cpp.o
  "_IID_IFramebuffer", referenced from:
      VBox::IFramebuffer::get_IID() in framebuffer.cpp.o
  "_IID_IFramebufferOverlay", referenced from:
      VBox::IFramebufferOverlay::get_IID() in framebufferoverlay.cpp.o
  "_IID_IFsInfo", referenced from:
      VBox::IFsInfo::get_IID() in fsinfo.cpp.o
  "_IID_IFsObjInfo", referenced from:
      VBox::IFsObjInfo::get_IID() in fsobjinfo.cpp.o
  "_IID_IGraphicsAdapter", referenced from:
      VBox::IGraphicsAdapter::get_IID() in graphicsadapter.cpp.o
  "_IID_IGuest", referenced from:
      VBox::IGuest::get_IID() in guest.cpp.o
  "_IID_IGuestAdditionsStatusChangedEvent", referenced from:
      VBox::IGuestAdditionsStatusChangedEvent::get_IID() in guestadditionsstatuschangedevent.cpp.o
  "_IID_IGuestDebugControl", referenced from:
      VBox::IGuestDebugControl::get_IID() in guestdebugcontrol.cpp.o
  "_IID_IGuestDebugControlChangedEvent", referenced from:
      VBox::IGuestDebugControlChangedEvent::get_IID() in guestdebugcontrolchangedevent.cpp.o
  "_IID_IGuestDirectory", referenced from:
      VBox::IGuestDirectory::get_IID() in directory.cpp.o
  "_IID_IGuestDirectoryEvent", referenced from:
      VBox::IGuestDirectoryEvent::get_IID() in guestdirectoryevent.cpp.o
  "_IID_IGuestDirectoryReadEvent", referenced from:
      VBox::IGuestDirectoryReadEvent::get_IID() in guestdirectoryevent.cpp.o
  "_IID_IGuestDirectoryRegisteredEvent", referenced from:
      VBox::IGuestDirectoryRegisteredEvent::get_IID() in guestdirectoryevent.cpp.o
  "_IID_IGuestDirectoryStateChangedEvent", referenced from:
      VBox::IGuestDirectoryStateChangedEvent::get_IID() in guestdirectoryevent.cpp.o
  "_IID_IGuestDnDSource", referenced from:
      VBox::IGuestDnDSource::get_IID() in dndsource.cpp.o
  "_IID_IGuestDnDTarget", referenced from:
      VBox::IGuestDnDTarget::get_IID() in dndtarget.cpp.o
  "_IID_IGuestFile", referenced from:
      VBox::IGuestFile::get_IID() in file.cpp.o
  "_IID_IGuestFileEvent", referenced from:
      VBox::IGuestFileEvent::get_IID() in guestfileevent.cpp.o
  "_IID_IGuestFileIOEvent", referenced from:
      VBox::IGuestFileIOEvent::get_IID() in guestfileioevent.cpp.o
  "_IID_IGuestFileOffsetChangedEvent", referenced from:
      VBox::IGuestFileOffsetChangedEvent::get_IID() in guestfileioevent.cpp.o
  "_IID_IGuestFileReadEvent", referenced from:
      VBox::IGuestFileReadEvent::get_IID() in guestfileioevent.cpp.o
  "_IID_IGuestFileRegisteredEvent", referenced from:
      VBox::IGuestFileRegisteredEvent::get_IID() in guestfileevent.cpp.o
  "_IID_IGuestFileSizeChangedEvent", referenced from:
      VBox::IGuestFileSizeChangedEvent::get_IID() in guestfileevent.cpp.o
  "_IID_IGuestFileStateChangedEvent", referenced from:
      VBox::IGuestFileStateChangedEvent::get_IID() in guestfileevent.cpp.o
  "_IID_IGuestFileWriteEvent", referenced from:
      VBox::IGuestFileWriteEvent::get_IID() in guestfileioevent.cpp.o
  "_IID_IGuestFsInfo", referenced from:
      VBox::IGuestFsInfo::get_IID() in fsinfo.cpp.o
  "_IID_IGuestFsObjInfo", referenced from:
      VBox::IGuestFsObjInfo::get_IID() in fsobjinfo.cpp.o
  "_IID_IGuestKeyboardEvent", referenced from:
      VBox::IGuestKeyboardEvent::get_IID() in guestkeyboardevent.cpp.o
  "_IID_IGuestMonitorChangedEvent", referenced from:
      VBox::IGuestMonitorChangedEvent::get_IID() in guestmonitorchangedevent.cpp.o
  "_IID_IGuestMonitorInfoChangedEvent", referenced from:
      VBox::IGuestMonitorInfoChangedEvent::get_IID() in guestmonitorchangedevent.cpp.o
  "_IID_IGuestMouseEvent", referenced from:
      VBox::IGuestMouseEvent::get_IID() in guestmouseevent.cpp.o
  "_IID_IGuestMultiTouchEvent", referenced from:
      VBox::IGuestMultiTouchEvent::get_IID() in guestmultitouchevent.cpp.o
  "_IID_IGuestOSType", referenced from:
      VBox::IGuestOSType::get_IID() in guestostype.cpp.o
  "_IID_IGuestProcess", referenced from:
      VBox::IGuestProcess::get_IID() in process.cpp.o
  "_IID_IGuestProcessEvent", referenced from:
      VBox::IGuestProcessEvent::get_IID() in guestprocessevent.cpp.o
  "_IID_IGuestProcessIOEvent", referenced from:
      VBox::IGuestProcessIOEvent::get_IID() in guestprocessioevent.cpp.o
  "_IID_IGuestProcessInputNotifyEvent", referenced from:
      VBox::IGuestProcessInputNotifyEvent::get_IID() in guestprocessioevent.cpp.o
  "_IID_IGuestProcessOutputEvent", referenced from:
      VBox::IGuestProcessOutputEvent::get_IID() in guestprocessioevent.cpp.o
  "_IID_IGuestProcessRegisteredEvent", referenced from:
      VBox::IGuestProcessRegisteredEvent::get_IID() in guestprocessevent.cpp.o
  "_IID_IGuestProcessStateChangedEvent", referenced from:
      VBox::IGuestProcessStateChangedEvent::get_IID() in guestprocessevent.cpp.o
  "_IID_IGuestPropertyChangedEvent", referenced from:
      VBox::IGuestPropertyChangedEvent::get_IID() in machineevent.cpp.o
  "_IID_IGuestScreenInfo", referenced from:
      VBox::IGuestScreenInfo::get_IID() in guestscreeninfo.cpp.o
  "_IID_IGuestSession", referenced from:
      VBox::IGuestSession::get_IID() in guestsession.cpp.o
  "_IID_IGuestSessionEvent", referenced from:
      VBox::IGuestSessionEvent::get_IID() in guestsessionevent.cpp.o
  "_IID_IGuestSessionRegisteredEvent", referenced from:
      VBox::IGuestSessionRegisteredEvent::get_IID() in guestsessionevent.cpp.o
  "_IID_IGuestSessionStateChangedEvent", referenced from:
      VBox::IGuestSessionStateChangedEvent::get_IID() in guestsessionevent.cpp.o
  "_IID_IGuestUserStateChangedEvent", referenced from:
      VBox::IGuestUserStateChangedEvent::get_IID() in guestuserstatechangedevent.cpp.o
  "_IID_IHost", referenced from:
      VBox::IHost::get_IID() in host.cpp.o
  "_IID_IHostAudioDevice", referenced from:
      VBox::IHostAudioDevice::get_IID() in hostaudiodevice.cpp.o
  "_IID_IHostAudioDeviceChangedEvent", referenced from:
      VBox::IHostAudioDeviceChangedEvent::get_IID() in hostaudiodevicechangedevent.cpp.o
  "_IID_IHostDrive", referenced from:
      VBox::IHostDrive::get_IID() in hostdrive.cpp.o
  "_IID_IHostDrivePartition", referenced from:
      VBox::IHostDrivePartition::get_IID() in hostdrivepartition.cpp.o
  "_IID_IHostNameResolutionConfigurationChangeEvent", referenced from:
      VBox::IHostNameResolutionConfigurationChangeEvent::get_IID() in objchangedevent.cpp.o
  "_IID_IHostNetworkInterface", referenced from:
      VBox::IHostNetworkInterface::get_IID() in hostnetworkinterface.cpp.o
  "_IID_IHostOnlyNetwork", referenced from:
      VBox::IHostOnlyNetwork::get_IID() in hostonlynetwork.cpp.o
  "_IID_IHostPCIDevicePlugEvent", referenced from:
      VBox::IHostPCIDevicePlugEvent::get_IID() in hostpcideviceplugevent.cpp.o
  "_IID_IHostUSBDevice", referenced from:
      VBox::IHostUSBDevice::get_IID() in usbdevice.cpp.o
  "_IID_IHostUSBDeviceFilter", referenced from:
      VBox::IHostUSBDeviceFilter::get_IID() in usbdevicefilter.cpp.o
  "_IID_IHostUpdateAgent", referenced from:
      VBox::IHostUpdateAgent::get_IID() in updateagent.cpp.o
  "_IID_IHostVideoInputDevice", referenced from:
      VBox::IHostVideoInputDevice::get_IID() in hostvideoinputdevice.cpp.o
  "_IID_IHostX86", referenced from:
      VBox::IHostX86::get_IID() in host.cpp.o
  "_IID_IInternalMachineControl", referenced from:
      VBox::IInternalMachineControl::get_IID() in internalmachinecontrol.cpp.o
  "_IID_IInternalProgressControl", referenced from:
      VBox::IInternalProgressControl::get_IID() in internalprogresscontrol.cpp.o
  "_IID_IInternalSessionControl", referenced from:
      VBox::IInternalSessionControl::get_IID() in internalsessioncontrol.cpp.o
  "_IID_IKeyboard", referenced from:
      VBox::IKeyboard::get_IID() in keyboard.cpp.o
  "_IID_IKeyboardLedsChangedEvent", referenced from:
      VBox::IKeyboardLedsChangedEvent::get_IID() in keyboardledschangedevent.cpp.o
  "_IID_ILanguageChangedEvent", referenced from:
      VBox::ILanguageChangedEvent::get_IID() in languagechangedevent.cpp.o
  "_IID_IMachine", referenced from:
      VBox::IMachine::get_IID() in machine.cpp.o
  "_IID_IMachineDataChangedEvent", referenced from:
      VBox::IMachineDataChangedEvent::get_IID() in machineevent.cpp.o
  "_IID_IMachineDebugger", referenced from:
      VBox::IMachineDebugger::get_IID() in machinedebugger.cpp.o
  "_IID_IMachineEvent", referenced from:
      VBox::IMachineEvent::get_IID() in machineevent.cpp.o
  "_IID_IMachineGroupsChangedEvent", referenced from:
      VBox::IMachineGroupsChangedEvent::get_IID() in machineevent.cpp.o
  "_IID_IMachineRegisteredEvent", referenced from:
      VBox::IMachineRegisteredEvent::get_IID() in machineevent.cpp.o
  "_IID_IMachineStateChangedEvent", referenced from:
      VBox::IMachineStateChangedEvent::get_IID() in machineevent.cpp.o
  "_IID_IMedium", referenced from:
      VBox::IMedium::get_IID() in medium.cpp.o
  "_IID_IMediumAttachment", referenced from:
      VBox::IMediumAttachment::get_IID() in mediumattachment.cpp.o
  "_IID_IMediumChangedEvent", referenced from:
      VBox::IMediumChangedEvent::get_IID() in objchangedevent.cpp.o
  "_IID_IMediumConfigChangedEvent", referenced from:
      VBox::IMediumConfigChangedEvent::get_IID() in mediumevent.cpp.o
  "_IID_IMediumFormat", referenced from:
      VBox::IMediumFormat::get_IID() in mediumformat.cpp.o
  "_IID_IMediumIO", referenced from:
      VBox::IMediumIO::get_IID() in mediumio.cpp.o
  "_IID_IMediumRegisteredEvent", referenced from:
      VBox::IMediumRegisteredEvent::get_IID() in mediumevent.cpp.o
  "_IID_IMouse", referenced from:
      VBox::IMouse::get_IID() in mouse.cpp.o
  "_IID_IMouseCapabilityChangedEvent", referenced from:
      VBox::IMouseCapabilityChangedEvent::get_IID() in mousecapabilitychangedevent.cpp.o
  "_IID_IMousePointerShape", referenced from:
      VBox::IMousePointerShape::get_IID() in mousepointershape.cpp.o
  "_IID_IMousePointerShapeChangedEvent", referenced from:
      VBox::IMousePointerShapeChangedEvent::get_IID() in mousepointershapechangedevent.cpp.o
  "_IID_INATEngine", referenced from:
      VBox::INATEngine::get_IID() in natengine.cpp.o
  "_IID_INATNetwork", referenced from:
      VBox::INATNetwork::get_IID() in natnetwork.cpp.o
  "_IID_INATNetworkAlterEvent", referenced from:
      VBox::INATNetworkAlterEvent::get_IID() in natnetworkchangedevent.cpp.o
  "_IID_INATNetworkChangedEvent", referenced from:
      VBox::INATNetworkChangedEvent::get_IID() in natnetworkchangedevent.cpp.o
  "_IID_INATNetworkCreationDeletionEvent", referenced from:
      VBox::INATNetworkCreationDeletionEvent::get_IID() in natnetworkchangedevent.cpp.o
  "_IID_INATNetworkPortForwardEvent", referenced from:
      VBox::INATNetworkPortForwardEvent::get_IID() in natnetworkchangedevent.cpp.o
  "_IID_INATNetworkSettingEvent", referenced from:
      VBox::INATNetworkSettingEvent::get_IID() in natnetworkchangedevent.cpp.o
  "_IID_INATNetworkStartStopEvent", referenced from:
      VBox::INATNetworkStartStopEvent::get_IID() in natnetworkchangedevent.cpp.o
  "_IID_INATRedirectEvent", referenced from:
      VBox::INATRedirectEvent::get_IID() in natredirectevent.cpp.o
  "_IID_INetworkAdapter", referenced from:
      VBox::INetworkAdapter::get_IID() in networkadapter.cpp.o
  "_IID_INetworkAdapterChangedEvent", referenced from:
      VBox::INetworkAdapterChangedEvent::get_IID() in objchangedevent.cpp.o
  "_IID_INvramStore", referenced from:
      VBox::INvramStore::get_IID() in nvramstore.cpp.o
  "_IID_IPCIAddress", referenced from:
      VBox::IPCIAddress::get_IID() in pciaddress.cpp.o
  "_IID_IPCIDeviceAttachment", referenced from:
      VBox::IPCIDeviceAttachment::get_IID() in pcideviceattachment.cpp.o
  "_IID_IParallelPort", referenced from:
      VBox::IParallelPort::get_IID() in parallelport.cpp.o
  "_IID_IParallelPortChangedEvent", referenced from:
      VBox::IParallelPortChangedEvent::get_IID() in objchangedevent.cpp.o
  "_IID_IPerformanceCollector", referenced from:
      VBox::IPerformanceCollector::get_IID() in performancecollector.cpp.o
  "_IID_IPerformanceMetric", referenced from:
      VBox::IPerformanceMetric::get_IID() in performancemetric.cpp.o
  "_IID_IPlatform", referenced from:
      VBox::IPlatform::get_IID() in platform.cpp.o
  "_IID_IPlatformARM", referenced from:
      VBox::IPlatformARM::get_IID() in platform.cpp.o
  "_IID_IPlatformProperties", referenced from:
      VBox::IPlatformProperties::get_IID() in platformproperties.cpp.o
  "_IID_IPlatformX86", referenced from:
      VBox::IPlatformX86::get_IID() in platformx86.cpp.o
  "_IID_IProcess", referenced from:
      VBox::IProcess::get_IID() in process.cpp.o
  "_IID_IProgress", referenced from:
      VBox::IProgress::get_IID() in progress.cpp.o
  "_IID_IProgressCreatedEvent", referenced from:
      VBox::IProgressCreatedEvent::get_IID() in progressevent.cpp.o
  "_IID_IProgressEvent", referenced from:
      VBox::IProgressEvent::get_IID() in progressevent.cpp.o
  "_IID_IProgressPercentageChangedEvent", referenced from:
      VBox::IProgressPercentageChangedEvent::get_IID() in progressevent.cpp.o
  "_IID_IProgressTaskCompletedEvent", referenced from:
      VBox::IProgressTaskCompletedEvent::get_IID() in progressevent.cpp.o
  "_IID_IRangedInteger64FormValue", referenced from:
      VBox::IRangedInteger64FormValue::get_IID() in formvalue.cpp.o
  "_IID_IRangedIntegerFormValue", referenced from:
      VBox::IRangedIntegerFormValue::get_IID() in formvalue.cpp.o
  "_IID_IRecordingScreenSettings", referenced from:
      VBox::IRecordingScreenSettings::get_IID() in recordingscreensettings.cpp.o
  "_IID_IRecordingScreenStateChangedEvent", referenced from:
      VBox::IRecordingScreenStateChangedEvent::get_IID() in recordingevent.cpp.o
  "_IID_IRecordingSettings", referenced from:
      VBox::IRecordingSettings::get_IID() in recordingsettings.cpp.o
  "_IID_IRecordingStateChangedEvent", referenced from:
      VBox::IRecordingStateChangedEvent::get_IID() in recordingevent.cpp.o
  "_IID_IResourceStore", referenced from:
      VBox::IResourceStore::get_IID() in resourcestore.cpp.o
  "_IID_IReusableEvent", referenced from:
      VBox::IReusableEvent::get_IID() in reusableevent.cpp.o
  "_IID_IRuntimeErrorEvent", referenced from:
      VBox::IRuntimeErrorEvent::get_IID() in runtimeerrorevent.cpp.o
  "_IID_ISerialPort", referenced from:
      VBox::ISerialPort::get_IID() in serialport.cpp.o
  "_IID_ISerialPortChangedEvent", referenced from:
      VBox::ISerialPortChangedEvent::get_IID() in objchangedevent.cpp.o
  "_IID_ISession", referenced from:
      VBox::ISession::get_IID() in session.cpp.o
  "_IID_ISessionStateChangedEvent", referenced from:
      VBox::ISessionStateChangedEvent::get_IID() in machineevent.cpp.o
  "_IID_ISharedFolder", referenced from:
      VBox::ISharedFolder::get_IID() in sharedfolder.cpp.o
  "_IID_ISharedFolderChangedEvent", referenced from:
      VBox::ISharedFolderChangedEvent::get_IID() in objchangedevent.cpp.o
  "_IID_IShowWindowEvent", referenced from:
      VBox::IShowWindowEvent::get_IID() in showwindowevent.cpp.o
  "_IID_ISnapshot", referenced from:
      VBox::ISnapshot::get_IID() in snapshot.cpp.o
  "_IID_ISnapshotChangedEvent", referenced from:
      VBox::ISnapshotChangedEvent::get_IID() in snapshotevent.cpp.o
  "_IID_ISnapshotDeletedEvent", referenced from:
      VBox::ISnapshotDeletedEvent::get_IID() in snapshotevent.cpp.o
  "_IID_ISnapshotEvent", referenced from:
      VBox::ISnapshotEvent::get_IID() in snapshotevent.cpp.o
  "_IID_ISnapshotRestoredEvent", referenced from:
      VBox::ISnapshotRestoredEvent::get_IID() in snapshotevent.cpp.o
  "_IID_ISnapshotTakenEvent", referenced from:
      VBox::ISnapshotTakenEvent::get_IID() in snapshotevent.cpp.o
  "_IID_IStateChangedEvent", referenced from:
      VBox::IStateChangedEvent::get_IID() in statechangedevent.cpp.o
  "_IID_IStorageController", referenced from:
      VBox::IStorageController::get_IID() in storagecontroller.cpp.o
  "_IID_IStorageControllerChangedEvent", referenced from:
      VBox::IStorageControllerChangedEvent::get_IID() in objchangedevent.cpp.o
  "_IID_IStorageDeviceChangedEvent", referenced from:
      VBox::IStorageDeviceChangedEvent::get_IID() in objchangedevent.cpp.o
  "_IID_IStringArray", referenced from:
      VBox::IStringArray::get_IID() in stringarray.cpp.o
  "_IID_IStringFormValue", referenced from:
      VBox::IStringFormValue::get_IID() in formvalue.cpp.o
  "_IID_ISystemProperties", referenced from:
      VBox::ISystemProperties::get_IID() in systemproperties.cpp.o
  "_IID_IToken", referenced from:
      VBox::IToken::get_IID() in token.cpp.o
  "_IID_ITrustedPlatformModule", referenced from:
      VBox::ITrustedPlatformModule::get_IID() in trustedplatformmodule.cpp.o
  "_IID_IUSBController", referenced from:
      VBox::IUSBController::get_IID() in usbcontroller.cpp.o
  "_IID_IUSBControllerChangedEvent", referenced from:
      VBox::IUSBControllerChangedEvent::get_IID() in objchangedevent.cpp.o
  "_IID_IUSBDevice", referenced from:
      VBox::IUSBDevice::get_IID() in usbdevice.cpp.o
  "_IID_IUSBDeviceFilter", referenced from:
      VBox::IUSBDeviceFilter::get_IID() in usbdevicefilter.cpp.o
  "_IID_IUSBDeviceFilters", referenced from:
      VBox::IUSBDeviceFilters::get_IID() in usbdevicefilters.cpp.o
  "_IID_IUSBDeviceStateChangedEvent", referenced from:
      VBox::IUSBDeviceStateChangedEvent::get_IID() in statechangedevent.cpp.o
  "_IID_IUSBProxyBackend", referenced from:
      VBox::IUSBProxyBackend::get_IID() in usbproxybackend.cpp.o
  "_IID_IUefiVariableStore", referenced from:
      VBox::IUefiVariableStore::get_IID() in uefivariablestore.cpp.o
  "_IID_IUnattended", referenced from:
      VBox::IUnattended::get_IID() in unattended.cpp.o
  "_IID_IUpdateAgent", referenced from:
      VBox::IUpdateAgent::get_IID() in updateagent.cpp.o
  "_IID_IUpdateAgentAvailableEvent", referenced from:
      VBox::IUpdateAgentAvailableEvent::get_IID() in updateagentavailableevent.cpp.o
  "_IID_IUpdateAgentErrorEvent", referenced from:
      VBox::IUpdateAgentErrorEvent::get_IID() in updateagentevent.cpp.o
  "_IID_IUpdateAgentEvent", referenced from:
      VBox::IUpdateAgentEvent::get_IID() in updateagentevent.cpp.o
  "_IID_IUpdateAgentSettingsChangedEvent", referenced from:
      VBox::IUpdateAgentSettingsChangedEvent::get_IID() in updateagentevent.cpp.o
  "_IID_IUpdateAgentStateChangedEvent", referenced from:
      VBox::IUpdateAgentStateChangedEvent::get_IID() in updateagentevent.cpp.o
  "_IID_IVBoxSVCAvailabilityChangedEvent", referenced from:
      VBox::IVBoxSVCAvailabilityChangedEvent::get_IID() in statechangedevent.cpp.o
  "_IID_IVFSExplorer", referenced from:
      VBox::IVFSExplorer::get_IID() in vfsexplorer.cpp.o
  "_IID_IVRDEServer", referenced from:
      VBox::IVRDEServer::get_IID() in vrdeserver.cpp.o
  "_IID_IVRDEServerChangedEvent", referenced from:
      VBox::IVRDEServerChangedEvent::get_IID() in objchangedevent.cpp.o
  "_IID_IVRDEServerInfo", referenced from:
      VBox::IVRDEServerInfo::get_IID() in vrdeserverinfo.cpp.o
  "_IID_IVRDEServerInfoChangedEvent", referenced from:
      VBox::IVRDEServerInfoChangedEvent::get_IID() in objchangedevent.cpp.o
  "_IID_IVetoEvent", referenced from:
      VBox::IVetoEvent::get_IID() in vetoevent.cpp.o
  "_IID_IVirtualBox", referenced from:
      VBox::IVirtualBox::get_IID() in virtualbox.cpp.o
  "_IID_IVirtualBoxClient", referenced from:
      VBox::API_Private::createVirtualBoxClient() in vboxwrap.cpp.o
      VBox::IVirtualBoxClient::get_IID() in virtualboxclient.cpp.o
  "_IID_IVirtualBoxErrorInfo", referenced from:
      VBox::IVirtualBoxErrorInfo::get_IID() in virtualboxerrorinfo.cpp.o
  "_IID_IVirtualSystemDescription", referenced from:
      VBox::IVirtualSystemDescription::get_IID() in virtualsystemdescription.cpp.o
  "_IID_IVirtualSystemDescriptionForm", referenced from:
      VBox::IVirtualSystemDescriptionForm::get_IID() in form.cpp.o
ld: symbol(s) not found for architecture arm64
clang++: error: linker command failed with exit code 1 (use -v to see invocation)
gmake[2]: *** [CMakeFiles/vbox.dir/build.make:2517: libvbox.dylib] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:87: CMakeFiles/vbox.dir/all] Error 2
gmake: *** [Makefile:136: all] Error 2

nikole-dunixi avatar Oct 24 '25 06:10 nikole-dunixi

Hmm, I don't have an arm64 mac to investigate or test with, but I wonder if the XPCOM library is x86_64 only...

zrax avatar Oct 24 '25 15:10 zrax

Hmm, I don't have an arm64 mac to investigate or test with

This might just be DOA for ARM if virtualbox itself doesn't support ARM like you hypothesize. Probably means there's nothing to do until Oracle decides its worth it. Either way, I'm probably on my own until another MacOS user happens to come across this. I'll continue posting content and reference as I find it in the optimistic hope this is useful down the line.

I wonder if the XPCOM library is x86_64 only...

That what I was thinking it might be as well, but I can compile their samples directly which is why I pause before giving up and reached out.

Image

And I can ripgrep for ARM rg --type 'c' -i '(arm|aarch)' | bat

Image

That said I haven't looked deep into the actual code, so it is completely possible this is to refer to the actual Guest systems and not the code itself.

nikole-dunixi avatar Oct 24 '25 17:10 nikole-dunixi

Actually, looking more closely, it looks like you specified a directory for VirtualBoxSDK_IID_LIB, which should instead be a path to the VirtualBox_i.c file in that directory. I believe that file contains the missing symbols from your error message. For reference, the FindVirtualBoxSDK.cmake expects you to only set VirtualBoxSDK_DIR manually, and it should find the rest automatically.

I'm a little surprised CMake doesn't complain about trying to add a directory as a source, but maybe there's a valid use case for that?

zrax avatar Oct 24 '25 18:10 zrax