diff --git a/Package.swift b/Package.swift index fb2b112..ba4ad37 100644 --- a/Package.swift +++ b/Package.swift @@ -17,10 +17,12 @@ let package = Package( ), ], targets: [ - .target(name: "ITKSuperBuilder"), .target( name: "InterposeKit", - dependencies: ["ITKSuperBuilder"] + dependencies: ["InterposeKitObjC"] + ), + .target( + name: "InterposeKitObjC" ), .testTarget( name: "InterposeKitTests", diff --git a/Package@swift-6.0.swift b/Package@swift-6.0.swift index ba62c5c..a9043cd 100644 --- a/Package@swift-6.0.swift +++ b/Package@swift-6.0.swift @@ -17,10 +17,12 @@ let package = Package( ), ], targets: [ - .target(name: "ITKSuperBuilder"), .target( name: "InterposeKit", - dependencies: ["ITKSuperBuilder"] + dependencies: ["InterposeKitObjC"] + ), + .target( + name: "InterposeKitObjC" ), .testTarget( name: "InterposeKitTests", diff --git a/README.md b/README.md index 4318d47..0900851 100644 --- a/README.md +++ b/README.md @@ -241,4 +241,4 @@ This library is released under the MIT license. See [LICENSE](LICENSE) for detai [^1]: Both applying and reverting a hook include safety checks. InterposeKit detects if the method was modified externally—such as by KVO or other swizzling—and prevents the operation if it would lead to inconsistent behavior. [^2]: There’s currently no runtime type checking. If the specified types don’t match, it will cause a runtime crash. -[^3]: The most advanced part of this library is `ITKSuperBuilder`, a component for constructing method implementations that simply call `super`, which is [surprisingly hard to do](https://steipete.me/posts/calling-super-at-runtime/). It’s written in Objective-C and assembly, lives in its own SPM target, and is invoked from Swift. All credit goes to Peter, who originally came up with this masterpiece! +[^3]: The most advanced part of this library is `ITKSuperBuilder`, a component for constructing method implementations that simply call `super`, which is [surprisingly hard to do](https://steipete.me/posts/calling-super-at-runtime/). It’s written in Objective-C and assembly, lives in an Objective-C SPM target, and is invoked from Swift. All credit goes to Peter, who originally came up with this masterpiece! diff --git a/Sources/InterposeKit/Hooks/HookStrategy/ObjectHookStrategy/ObjectHookStrategy.swift b/Sources/InterposeKit/Hooks/HookStrategy/ObjectHookStrategy/ObjectHookStrategy.swift index 576f976..fad1a96 100644 --- a/Sources/InterposeKit/Hooks/HookStrategy/ObjectHookStrategy/ObjectHookStrategy.swift +++ b/Sources/InterposeKit/Hooks/HookStrategy/ObjectHookStrategy/ObjectHookStrategy.swift @@ -1,4 +1,4 @@ -import ITKSuperBuilder +import InterposeKitObjC import ObjectiveC internal final class ObjectHookStrategy: HookStrategy { diff --git a/Sources/ITKSuperBuilder/include/ITKSuperBuilder.h b/Sources/InterposeKitObjC/include/ITKSuperBuilder.h similarity index 100% rename from Sources/ITKSuperBuilder/include/ITKSuperBuilder.h rename to Sources/InterposeKitObjC/include/ITKSuperBuilder.h diff --git a/Sources/ITKSuperBuilder/src/ITKSuperBuilder.m b/Sources/InterposeKitObjC/src/ITKSuperBuilder.m similarity index 100% rename from Sources/ITKSuperBuilder/src/ITKSuperBuilder.m rename to Sources/InterposeKitObjC/src/ITKSuperBuilder.m