Hey, I have a Kotlin multiplatform project which c...
# ios
t
Hey, I have a Kotlin multiplatform project which creates an Xcode-framework. I want to draw a class dependency graph of the framework. I found this tool for pure Objective-C sources https://github.com/nst/objc_dep And there are many tools out there which can process a .jar. Somebody knows a tool which can process an Xcode-framework or the Kotlin source files?
m
otherwise gradle has build in mechenism for libs dependecies
./gradlew app:dependencies
t
Thx, but I think my question was unclear. I want to draw the interaction of the classes from my framework. Like this:

https://github.com/nst/objc_dep/raw/master/pics/fswalker1.png

m
Now after reading your question more carefully ….. I don’t know anything special for kotlin, but I would probably go with JVM based tools for that, like e.g. http://blog.schauderhaft.de/degraph/ anyway interessting topic. I am answering in a context of a MPP project…
t
I try to write the complete code in kotlin. So I have an iosMain module using a commonMain Module. So I can only compile with kotlin/native. My problem is, I can't use JVM tools this way. 😉
m
Your topic is very interesting, I didn’t find anything you can use directly, but if there will be a solution, then it will be something to be able to deal with intermediate format of llvm or something on the beginning of compilation. There are some hints how to write kotlin compiler plugins like here https://kotlinlang.org/docs/reference/compiler-plugins.html also I’ve remember to see an annotation processor for kotlin (which can get enough information for generating of dependency graphs). I will check also llvm stuff.