Something went wrong. Try again.
What happens if I push all of nixpkgs
Something went wrong. Try again.
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812diff --git a/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_12.m b/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_12.mindex 567172ba2..e2c1ac047 100644--- a/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_12.m+++ b/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_12.m@@ -8,6 +8,7 @@ bool vmCanStop(void *machine, void *queue) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { __block BOOL result; dispatch_sync((dispatch_queue_t)queue, ^{@@ -15,12 +16,13 @@ bool vmCanStop(void *machine, void *queue) }); return (bool)result; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } void stopWithCompletionHandler(void *machine, void *queue, void *completionHandler) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { vm_completion_handler_t handler = makeVMCompletionHandler(completionHandler); dispatch_sync((dispatch_queue_t)queue, ^{@@ -29,7 +31,7 @@ void stopWithCompletionHandler(void *machine, void *queue, void *completionHandl Block_release(handler); return; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -38,10 +40,11 @@ void stopWithCompletionHandler(void *machine, void *queue, void *completionHandl */ void *newVZGenericPlatformConfiguration() {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { return [[VZGenericPlatformConfiguration alloc] init]; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -51,11 +54,12 @@ void *newVZGenericPlatformConfiguration() */ void setDirectorySharingDevicesVZVirtualMachineConfiguration(void *config, void *directorySharingDevices) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { [(VZVirtualMachineConfiguration *)config setDirectorySharingDevices:[(NSMutableArray *)directorySharingDevices copy]]; return; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -66,11 +70,12 @@ void setDirectorySharingDevicesVZVirtualMachineConfiguration(void *config, void */ void setPlatformVZVirtualMachineConfiguration(void *config, void *platform) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { [(VZVirtualMachineConfiguration *)config setPlatform:(VZPlatformConfiguration *)platform]; return; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -80,11 +85,12 @@ void setPlatformVZVirtualMachineConfiguration(void *config, void *platform) */ void setGraphicsDevicesVZVirtualMachineConfiguration(void *config, void *graphicsDevices) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { [(VZVirtualMachineConfiguration *)config setGraphicsDevices:[(NSMutableArray *)graphicsDevices copy]]; return; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -94,11 +100,12 @@ void setGraphicsDevicesVZVirtualMachineConfiguration(void *config, void *graphic */ void setPointingDevicesVZVirtualMachineConfiguration(void *config, void *pointingDevices) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { [(VZVirtualMachineConfiguration *)config setPointingDevices:[(NSMutableArray *)pointingDevices copy]]; return; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -108,11 +115,12 @@ void setPointingDevicesVZVirtualMachineConfiguration(void *config, void *pointin */ void setKeyboardsVZVirtualMachineConfiguration(void *config, void *keyboards) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { [(VZVirtualMachineConfiguration *)config setKeyboards:[(NSMutableArray *)keyboards copy]]; return; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -122,11 +130,12 @@ void setKeyboardsVZVirtualMachineConfiguration(void *config, void *keyboards) */ void setAudioDevicesVZVirtualMachineConfiguration(void *config, void *audioDevices) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { [(VZVirtualMachineConfiguration *)config setAudioDevices:[(NSMutableArray *)audioDevices copy]]; return; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -136,10 +145,11 @@ void setAudioDevicesVZVirtualMachineConfiguration(void *config, void *audioDevic */ void *newVZVirtioSoundDeviceConfiguration() {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { return [[VZVirtioSoundDeviceConfiguration alloc] init]; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -148,11 +158,12 @@ void *newVZVirtioSoundDeviceConfiguration() */ void setStreamsVZVirtioSoundDeviceConfiguration(void *audioDeviceConfiguration, void *streams) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { [(VZVirtioSoundDeviceConfiguration *)audioDeviceConfiguration setStreams:[(NSMutableArray *)streams copy]]; return; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -162,10 +173,11 @@ void setStreamsVZVirtioSoundDeviceConfiguration(void *audioDeviceConfiguration, */ void *newVZVirtioSoundDeviceInputStreamConfiguration() {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { return [[VZVirtioSoundDeviceInputStreamConfiguration alloc] init]; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -174,12 +186,13 @@ void *newVZVirtioSoundDeviceInputStreamConfiguration() */ void *newVZVirtioSoundDeviceHostInputStreamConfiguration() {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { VZVirtioSoundDeviceInputStreamConfiguration *inputStream = (VZVirtioSoundDeviceInputStreamConfiguration *)newVZVirtioSoundDeviceInputStreamConfiguration(); [inputStream setSource:[[VZHostAudioInputStreamSource alloc] init]]; return inputStream; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -189,10 +202,11 @@ void *newVZVirtioSoundDeviceHostInputStreamConfiguration() */ void *newVZVirtioSoundDeviceOutputStreamConfiguration() {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { return [[VZVirtioSoundDeviceOutputStreamConfiguration alloc] init]; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -201,12 +215,13 @@ void *newVZVirtioSoundDeviceOutputStreamConfiguration() */ void *newVZVirtioSoundDeviceHostOutputStreamConfiguration() {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { VZVirtioSoundDeviceOutputStreamConfiguration *outputStream = (VZVirtioSoundDeviceOutputStreamConfiguration *)newVZVirtioSoundDeviceOutputStreamConfiguration(); [outputStream setSink:[[VZHostAudioOutputStreamSink alloc] init]]; return outputStream; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -220,12 +235,13 @@ void *newVZVirtioSoundDeviceHostOutputStreamConfiguration() */ void *newVZSharedDirectory(const char *dirPath, bool readOnly) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { NSString *dirPathNSString = [NSString stringWithUTF8String:dirPath]; NSURL *dirURL = [NSURL fileURLWithPath:dirPathNSString]; return [[VZSharedDirectory alloc] initWithURL:dirURL readOnly:(BOOL)readOnly]; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -237,10 +253,11 @@ void *newVZSharedDirectory(const char *dirPath, bool readOnly) */ void *newVZSingleDirectoryShare(void *sharedDirectory) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { return [[VZSingleDirectoryShare alloc] initWithDirectory:(VZSharedDirectory *)sharedDirectory]; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -252,10 +269,11 @@ void *newVZSingleDirectoryShare(void *sharedDirectory) */ void *newVZMultipleDirectoryShare(void *sharedDirectories) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { return [[VZMultipleDirectoryShare alloc] initWithDirectories:(NSDictionary<NSString *, VZSharedDirectory *> *)sharedDirectories]; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -267,6 +285,7 @@ void *newVZMultipleDirectoryShare(void *sharedDirectories) */ void *newVZVirtioFileSystemDeviceConfiguration(const char *tag, void **error) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { NSString *tagNSString = [NSString stringWithUTF8String:tag]; BOOL valid = [VZVirtioFileSystemDeviceConfiguration validateTag:tagNSString error:(NSError *_Nullable *_Nullable)error];@@ -275,7 +294,7 @@ void *newVZVirtioFileSystemDeviceConfiguration(const char *tag, void **error) } return [[VZVirtioFileSystemDeviceConfiguration alloc] initWithTag:tagNSString]; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -284,11 +303,12 @@ void *newVZVirtioFileSystemDeviceConfiguration(const char *tag, void **error) */ void setVZVirtioFileSystemDeviceConfigurationShare(void *config, void *share) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { [(VZVirtioFileSystemDeviceConfiguration *)config setShare:(VZDirectoryShare *)share]; return; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -298,10 +318,11 @@ void setVZVirtioFileSystemDeviceConfigurationShare(void *config, void *share) */ void *newVZUSBScreenCoordinatePointingDeviceConfiguration() {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { return [[VZUSBScreenCoordinatePointingDeviceConfiguration alloc] init]; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -311,10 +332,11 @@ void *newVZUSBScreenCoordinatePointingDeviceConfiguration() */ void *newVZUSBKeyboardConfiguration() {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { return [[VZUSBKeyboardConfiguration alloc] init]; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -328,6 +350,7 @@ void sharedApplication() void startVirtualMachineWindow(void *machine, double width, double height) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { @autoreleasepool { AppDelegate *appDelegate = [[[AppDelegate alloc]@@ -340,5 +363,6 @@ void startVirtualMachineWindow(void *machine, double width, double height) return; } }+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); }diff --git a/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_12_arm64.m b/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_12_arm64.mindex 4fbaf6cb7..452adb747 100644--- a/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_12_arm64.m+++ b/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_12_arm64.m@@ -30,6 +30,7 @@ */ void *newVZMacAuxiliaryStorageWithCreating(const char *storagePath, void *hardwareModel, void **error) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { NSString *storagePathNSString = [NSString stringWithUTF8String:storagePath]; NSURL *storageURL = [NSURL fileURLWithPath:storagePathNSString];@@ -38,7 +39,7 @@ void *newVZMacAuxiliaryStorageWithCreating(const char *storagePath, void *hardwa options:VZMacAuxiliaryStorageInitializationOptionAllowOverwrite error:(NSError *_Nullable *_Nullable)error]; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -49,6 +50,7 @@ void *newVZMacAuxiliaryStorageWithCreating(const char *storagePath, void *hardwa */ void *newVZMacAuxiliaryStorage(const char *storagePath) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { NSString *storagePathNSString = [NSString stringWithUTF8String:storagePath]; NSURL *storageURL = [NSURL fileURLWithPath:storagePathNSString];@@ -56,7 +58,7 @@ void *newVZMacAuxiliaryStorage(const char *storagePath) // https://developer.apple.com/documentation/virtualization/vzmacauxiliarystorage?language=objc return [[VZMacAuxiliaryStorage alloc] initWithContentsOfURL:storageURL]; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -80,10 +82,11 @@ void *newVZMacAuxiliaryStorage(const char *storagePath) */ void *newVZMacPlatformConfiguration() {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { return [[VZMacPlatformConfiguration alloc] init]; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -92,17 +95,19 @@ void *newVZMacPlatformConfiguration() */ void setHardwareModelVZMacPlatformConfiguration(void *config, void *hardwareModel) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { [(VZMacPlatformConfiguration *)config setHardwareModel:(VZMacHardwareModel *)hardwareModel]; return; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } // Store the hardware model to disk so that we can retrieve them for subsequent boots. void storeHardwareModelDataVZMacPlatformConfiguration(void *config, const char *filePath) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { VZMacPlatformConfiguration *macPlatformConfiguration = (VZMacPlatformConfiguration *)config; NSString *filePathNSString = [NSString stringWithUTF8String:filePath];@@ -110,7 +115,7 @@ void storeHardwareModelDataVZMacPlatformConfiguration(void *config, const char * [macPlatformConfiguration.hardwareModel.dataRepresentation writeToURL:fileURL atomically:YES]; return; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -121,17 +126,19 @@ void storeHardwareModelDataVZMacPlatformConfiguration(void *config, const char * */ void setMachineIdentifierVZMacPlatformConfiguration(void *config, void *machineIdentifier) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { [(VZMacPlatformConfiguration *)config setMachineIdentifier:(VZMacMachineIdentifier *)machineIdentifier]; return; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } // Store the machine identifier to disk so that we can retrieve them for subsequent boots. void storeMachineIdentifierDataVZMacPlatformConfiguration(void *config, const char *filePath) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { VZMacPlatformConfiguration *macPlatformConfiguration = (VZMacPlatformConfiguration *)config; NSString *filePathNSString = [NSString stringWithUTF8String:filePath];@@ -139,7 +146,7 @@ void storeMachineIdentifierDataVZMacPlatformConfiguration(void *config, const ch [macPlatformConfiguration.machineIdentifier.dataRepresentation writeToURL:fileURL atomically:YES]; return; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -151,11 +158,12 @@ void storeMachineIdentifierDataVZMacPlatformConfiguration(void *config, const ch */ void setAuxiliaryStorageVZMacPlatformConfiguration(void *config, void *auxiliaryStorage) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { [(VZMacPlatformConfiguration *)config setAuxiliaryStorage:(VZMacAuxiliaryStorage *)auxiliaryStorage]; return; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -169,10 +177,11 @@ void setAuxiliaryStorageVZMacPlatformConfiguration(void *config, void *auxiliary */ void *newVZMacOSBootLoader() {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { return [[VZMacOSBootLoader alloc] init]; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -182,10 +191,11 @@ void *newVZMacOSBootLoader() */ void *newVZMacGraphicsDeviceConfiguration() {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { return [[VZMacGraphicsDeviceConfiguration alloc] init]; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -194,11 +204,12 @@ void *newVZMacGraphicsDeviceConfiguration() */ void setDisplaysVZMacGraphicsDeviceConfiguration(void *graphicsConfiguration, void *displays) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { [(VZMacGraphicsDeviceConfiguration *)graphicsConfiguration setDisplays:[(NSMutableArray *)displays copy]]; return; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -210,13 +221,14 @@ void setDisplaysVZMacGraphicsDeviceConfiguration(void *graphicsConfiguration, vo */ void *newVZMacGraphicsDisplayConfiguration(NSInteger widthInPixels, NSInteger heightInPixels, NSInteger pixelsPerInch) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { return [[VZMacGraphicsDisplayConfiguration alloc] initWithWidthInPixels:widthInPixels heightInPixels:heightInPixels pixelsPerInch:pixelsPerInch]; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -226,6 +238,7 @@ void *newVZMacGraphicsDisplayConfiguration(NSInteger widthInPixels, NSInteger he */ void *newVZMacHardwareModelWithPath(const char *hardwareModelPath) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { VZMacHardwareModel *hardwareModel; NSString *hardwareModelPathNSString = [NSString stringWithUTF8String:hardwareModelPath];@@ -236,12 +249,13 @@ void *newVZMacHardwareModelWithPath(const char *hardwareModelPath) } return hardwareModel; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } void *newVZMacHardwareModelWithBytes(void *hardwareModelBytes, int len) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { VZMacHardwareModel *hardwareModel; @autoreleasepool {@@ -250,7 +264,7 @@ void *newVZMacHardwareModelWithBytes(void *hardwareModelBytes, int len) } return hardwareModel; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -259,10 +273,11 @@ void *newVZMacHardwareModelWithBytes(void *hardwareModelBytes, int len) */ void *newVZMacMachineIdentifier() {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { return [[VZMacMachineIdentifier alloc] init]; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -274,6 +289,7 @@ void *newVZMacMachineIdentifier() */ void *newVZMacMachineIdentifierWithPath(const char *machineIdentifierPath) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { VZMacMachineIdentifier *machineIdentifier; NSString *machineIdentifierPathNSString = [NSString stringWithUTF8String:machineIdentifierPath];@@ -284,12 +300,13 @@ void *newVZMacMachineIdentifierWithPath(const char *machineIdentifierPath) } return machineIdentifier; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } void *newVZMacMachineIdentifierWithBytes(void *machineIdentifierBytes, int len) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { VZMacMachineIdentifier *machineIdentifier; @autoreleasepool {@@ -298,12 +315,13 @@ void *newVZMacMachineIdentifierWithBytes(void *machineIdentifierBytes, int len) } return machineIdentifier; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } nbyteslice getVZMacMachineIdentifierDataRepresentation(void *machineIdentifierPtr) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { VZMacMachineIdentifier *machineIdentifier = (VZMacMachineIdentifier *)machineIdentifierPtr; NSData *data = [machineIdentifier dataRepresentation];@@ -313,12 +331,13 @@ nbyteslice getVZMacMachineIdentifierDataRepresentation(void *machineIdentifierPt }; return ret; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } VZMacOSRestoreImageStruct convertVZMacOSRestoreImage2Struct(void *restoreImagePtr) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { VZMacOSRestoreImage *restoreImage = (VZMacOSRestoreImage *)restoreImagePtr; VZMacOSRestoreImageStruct ret;@@ -329,12 +348,13 @@ VZMacOSRestoreImageStruct convertVZMacOSRestoreImage2Struct(void *restoreImagePt ret.mostFeaturefulSupportedConfiguration = (void *)CFBridgingRetain([restoreImage mostFeaturefulSupportedConfiguration]); return ret; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } void fetchLatestSupportedMacOSRestoreImageWithCompletionHandler(void *cgoHandler) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { [VZMacOSRestoreImage fetchLatestSupportedWithCompletionHandler:^(VZMacOSRestoreImage *restoreImage, NSError *error) { VZMacOSRestoreImageStruct restoreImageStruct = convertVZMacOSRestoreImage2Struct(restoreImage);@@ -342,12 +362,13 @@ void fetchLatestSupportedMacOSRestoreImageWithCompletionHandler(void *cgoHandler }]; return; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } void loadMacOSRestoreImageFile(const char *ipswPath, void *cgoHandler) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { NSString *ipswPathNSString = [NSString stringWithUTF8String:ipswPath]; NSURL *ipswURL = [NSURL fileURLWithPath:ipswPathNSString];@@ -358,12 +379,13 @@ void loadMacOSRestoreImageFile(const char *ipswPath, void *cgoHandler) }]; return; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } VZMacOSConfigurationRequirementsStruct convertVZMacOSConfigurationRequirements2Struct(void *requirementsPtr) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { VZMacOSConfigurationRequirements *requirements = (VZMacOSConfigurationRequirements *)requirementsPtr; VZMacOSConfigurationRequirementsStruct ret;@@ -373,12 +395,13 @@ VZMacOSConfigurationRequirementsStruct convertVZMacOSConfigurationRequirements2S ret.hardwareModel = (void *)CFBridgingRetain([requirements hardwareModel]); return ret; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } VZMacHardwareModelStruct convertVZMacHardwareModel2Struct(void *hardwareModelPtr) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { VZMacHardwareModel *hardwareModel = (VZMacHardwareModel *)hardwareModelPtr; VZMacHardwareModelStruct ret;@@ -391,7 +414,7 @@ VZMacHardwareModelStruct convertVZMacHardwareModel2Struct(void *hardwareModelPtr ret.dataRepresentation = retByteSlice; return ret; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -405,6 +428,7 @@ VZMacHardwareModelStruct convertVZMacHardwareModel2Struct(void *hardwareModelPtr */ void *newVZMacOSInstaller(void *virtualMachine, void *vmQueue, const char *restoreImageFilePath) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { __block VZMacOSInstaller *ret; NSString *restoreImageFilePathNSString = [NSString stringWithUTF8String:restoreImageFilePath];@@ -414,7 +438,7 @@ void *newVZMacOSInstaller(void *virtualMachine, void *vmQueue, const char *resto }); return ret; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -425,6 +449,7 @@ void *newProgressObserverVZMacOSInstaller() void installByVZMacOSInstaller(void *installerPtr, void *vmQueue, void *progressObserverPtr, void *completionHandler, void *fractionCompletedHandler) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { VZMacOSInstaller *installer = (VZMacOSInstaller *)installerPtr; dispatch_sync((dispatch_queue_t)vmQueue, ^{@@ -439,12 +464,13 @@ void installByVZMacOSInstaller(void *installerPtr, void *vmQueue, void *progress }); return; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } void cancelInstallVZMacOSInstaller(void *installerPtr) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { VZMacOSInstaller *installer = (VZMacOSInstaller *)installerPtr; if (installer.progress.cancellable) {@@ -452,7 +478,7 @@ void cancelInstallVZMacOSInstaller(void *installerPtr) } return; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } diff --git a/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_debug.m b/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_debug.mindex 67fe356ae..af81a46b0 100644--- a/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_debug.m+++ b/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_debug.m@@ -12,10 +12,11 @@ */ void *newVZGDBDebugStubConfiguration(uint32_t port) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { return [[_VZGDBDebugStubConfiguration alloc] initWithPort:(NSInteger)port]; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); } @@ -24,10 +25,11 @@ void *newVZGDBDebugStubConfiguration(uint32_t port) */ void setDebugStubVZVirtualMachineConfiguration(void *config, void *debugStub) {+#ifdef INCLUDE_TARGET_OSX_12 if (@available(macOS 12, *)) { [(VZVirtualMachineConfiguration *)config _setDebugStub:(_VZDebugStubConfiguration *)debugStub]; return; }-+#endif RAISE_UNSUPPORTED_MACOS_EXCEPTION(); }\ No newline at end of filediff --git a/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_helper.h b/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_helper.hindex 995b40882..9da0700b9 100644--- a/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_helper.h+++ b/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_helper.h@@ -18,6 +18,13 @@ NSDictionary *dumpProcessinfo(); __builtin_unreachable(); \ } while (0) +// for macOS 12 API+#if __MAC_OS_X_VERSION_MAX_ALLOWED >= 120000+#define INCLUDE_TARGET_OSX_12 1+#else+#pragma message("macOS 12 API has been disabled")+#endif+ // for macOS 12.3 API #if __MAC_OS_X_VERSION_MAX_ALLOWED >= 120300 #define INCLUDE_TARGET_OSX_12_3 1diff --git a/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_view.h b/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_view.hindex ab00b9225..15d306f66 100644--- a/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_view.h+++ b/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_view.h@@ -23,9 +23,11 @@ - (instancetype)init; @end +#ifdef INCLUDE_TARGET_OSX_12 API_AVAILABLE(macos(12.0)) @interface AppDelegate : NSObject <NSApplicationDelegate, NSWindowDelegate, VZVirtualMachineDelegate> - (instancetype)initWithVirtualMachine:(VZVirtualMachine *)virtualMachine windowWidth:(CGFloat)windowWidth windowHeight:(CGFloat)windowHeight;-@end\ No newline at end of file+@end+#endif\ No newline at end of filediff --git a/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_view.m b/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_view.mindex 9031c44f1..33b20d91b 100644--- a/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_view.m+++ b/src/cmd/linuxkit/vendor/github.com/Code-Hex/vz/v3/virtualization_view.m@@ -165,6 +165,7 @@ @end +#ifdef INCLUDE_TARGET_OSX_12 @implementation AppDelegate { VZVirtualMachine *_virtualMachine; VZVirtualMachineView *_virtualMachineView;@@ -372,3 +373,4 @@ [aboutPanel makeKeyAndOrderFront:nil]; } @end+#endif