From ec8b7e1b5cf663e561159b64628413d03846cfd7 Mon Sep 17 00:00:00 2001 From: Zameer Manji Date: Sat, 9 Sep 2023 00:06:23 -0400 Subject: [PATCH] Support CoreWLAN framework. --- crates/header-translator/framework-includes.h | 2 + crates/header-translator/src/data/CoreWLAN.rs | 2 + crates/header-translator/src/data/mod.rs | 1 + .../header-translator/translation-config.toml | 42 +++++++++++++++++++ crates/icrate/Cargo.toml | 27 ++++++++++++ crates/icrate/src/generated | 2 +- 6 files changed, 75 insertions(+), 1 deletion(-) create mode 100644 crates/header-translator/src/data/CoreWLAN.rs diff --git a/crates/header-translator/framework-includes.h b/crates/header-translator/framework-includes.h index 22b1d3410..0f77a986b 100644 --- a/crates/header-translator/framework-includes.h +++ b/crates/header-translator/framework-includes.h @@ -35,6 +35,8 @@ #import +#import + #import #import diff --git a/crates/header-translator/src/data/CoreWLAN.rs b/crates/header-translator/src/data/CoreWLAN.rs new file mode 100644 index 000000000..89a871f29 --- /dev/null +++ b/crates/header-translator/src/data/CoreWLAN.rs @@ -0,0 +1,2 @@ +data! { +} diff --git a/crates/header-translator/src/data/mod.rs b/crates/header-translator/src/data/mod.rs index 19a2ac37c..ab08f51bf 100644 --- a/crates/header-translator/src/data/mod.rs +++ b/crates/header-translator/src/data/mod.rs @@ -21,6 +21,7 @@ data! { mod CoreAnimation; mod CoreData; mod CoreLocation; + mod CoreWLAN; mod DataDetection; mod DeviceCheck; mod EventKit; diff --git a/crates/header-translator/translation-config.toml b/crates/header-translator/translation-config.toml index f0866a914..f586ef040 100644 --- a/crates/header-translator/translation-config.toml +++ b/crates/header-translator/translation-config.toml @@ -144,6 +144,10 @@ ios = "2.0" tvos = "9.0" watchos = "2.0" +[library.CoreWLAN] +imports = ["Foundation"] +macos = "10.6" + [library.DataDetection] imports = ["Foundation"] macos = "12.0" @@ -1614,3 +1618,41 @@ skipped-protocols = ["NSCopying", "NSMutableCopying"] # Will have to be a method that takes `MainThreadMarker`. [static.NSApp] skipped = true + +# Uses types from CoreFoundation +[fn.CWKeychainCopyEAPUsernameAndPassword] +skipped = true +[fn.CWKeychainCopyEAPIdentityList] +skipped = true +[fn.CWKeychainSetEAPUsernameAndPassword] +skipped = true +[fn.CWKeychainDeleteEAPUsernameAndPassword] +skipped = true +[fn.CWKeychainSetPassword] +skipped = true +[fn.CWKeychainDeletePassword] +skipped = true +[fn.CWKeychainCopyEAPIdentity] +skipped = true +[fn.CWKeychainSetEAPIdentity] +skipped = true +[fn.CWKeychainCopyPassword] +skipped = true +[fn.CWKeychainFindWiFiPassword] +skipped = true +[fn.CWKeychainSetWiFiPassword] +skipped = true +[fn.CWKeychainDeleteWiFiPassword] +skipped = true +[fn.CWKeychainFindWiFiEAPUsernameAndPassword] +skipped = true +[fn.CWKeychainSetWiFiEAPUsernameAndPassword] +skipped = true +[fn.CWKeychainDeleteWiFiEAPUsernameAndPassword] +skipped = true +[fn.CWKeychainCopyWiFiEAPIdentity] +skipped = true +[fn.CWKeychainSetWiFiEAPIdentity] +skipped = true +[class.CWInterface.methods.associateToEnterpriseNetwork_identity_username_password_error] +skipped = true diff --git a/crates/icrate/Cargo.toml b/crates/icrate/Cargo.toml index 92f527d2c..c6aa28141 100644 --- a/crates/icrate/Cargo.toml +++ b/crates/icrate/Cargo.toml @@ -2056,6 +2056,32 @@ CoreLocation_all = [ "CoreLocation_CLRegion", "CoreLocation_CLVisit", ] +CoreWLAN = [ + "Foundation", +] +CoreWLAN_CWChannel = [] +CoreWLAN_CWConfiguration = [] +CoreWLAN_CWInterface = [] +CoreWLAN_CWMutableConfiguration = [ + "CoreWLAN_CWConfiguration", +] +CoreWLAN_CWMutableNetworkProfile = [ + "CoreWLAN_CWNetworkProfile", +] +CoreWLAN_CWNetwork = [] +CoreWLAN_CWNetworkProfile = [] +CoreWLAN_CWWiFiClient = [] +CoreWLAN_all = [ + "CoreWLAN", + "CoreWLAN_CWChannel", + "CoreWLAN_CWConfiguration", + "CoreWLAN_CWInterface", + "CoreWLAN_CWMutableConfiguration", + "CoreWLAN_CWMutableNetworkProfile", + "CoreWLAN_CWNetwork", + "CoreWLAN_CWNetworkProfile", + "CoreWLAN_CWWiFiClient", +] DataDetection = [ "Foundation", ] @@ -5329,6 +5355,7 @@ unstable-frameworks-macos-10-7 = [ "Automator_all", "CoreAnimation_all", "CoreData_all", + "CoreWLAN_all", "ExceptionHandling_all", "Foundation_all", "InputMethodKit_all", diff --git a/crates/icrate/src/generated b/crates/icrate/src/generated index 845c371d2..542165e89 160000 --- a/crates/icrate/src/generated +++ b/crates/icrate/src/generated @@ -1 +1 @@ -Subproject commit 845c371d2154a052e9adb70f952266ce81e2a13f +Subproject commit 542165e89f8677df7554c0788cbb9a5021ac31c8