General In Defence of Dependencies

Discussion in 'Jailbreaks and iOS Hacks' started by thelatinist, Jan 4, 2014.

  1. thelatinist, Jan 4, 2014
    Last edited: Jan 4, 2014

    thelatinist macrumors 603

    thelatinist

    Joined:
    Aug 15, 2009
    Location:
    Connecticut, USA
    #1
    I see in a lot of threads around here lately where people have been complaining about jailbreak tweaks and apps requiring them to install dependencies. I can understand concerns about things you don't know or understand being installed on your phone, but this bashing of dependencies has, I think, gotten out of hand.

    Dependencies aren't being added to your phone for the hell of it. Usually those dependencies are doing something vital that the app itself would otherwise have to do. As the jailbreak community is maturing, skilled devs have been creating tools which abstract certain commonly needed tasks so that tweaks will not have to duplicate functionality -- something that often leads to conflicts.

    Most of you are familiar with Cydia Substrate (formerly Mobile Substrate), the first and greatest of these tools. Cydia Substrate is a very sophisticated tool with numerous APIs that create a consistent way for developers to inject code into system applications. Without Cydia Substrate nearly every tweak would have to duplicate its functionality, using their own means to inject code and invariably causing conflicts. And can you imagine the additional overhead of running a code injector built into every tweak? Not only that, but when something changes in iOS, developers don't each have to rewrite the code injection portions of their apps; Saurik updates CydiaSubstrate and does it for them. Can you imagine how long it would take tweak developers to update their apps if they had to duplicate Saurik's work for every app they created?

    The same thing can be said of many of the other devendencies people complain about. Libactivate handles the interception of gestures and button presses so that you don't end up with competing tweaks battling over them. Libhide allows the hiding of application icons and is used by many tweaks. Icon Support provides a way for numerous tweaks to move and alter icons without creating conflicts. The new beta FlipSwitch library supports the addition of icons to the Control Center. The unfortunately-named RocketBootstrap creates a way for tweaks to look up and reference system addresses that are otherwise sandboxed in iOS 7. It was basic functionality needed for Activator, but it will be useful for many tweaks so rather than incorporate it into Activator itself the author made it into a library any developer could rely on. The list goes on.

    So before you start complaining about dependencies or avoiding tweaks that require them, take a moment to consider what those dependencies represent: a maturing ecosystem with a more efficient architecture where people work together to avoid duplicating work and creating conflicts, to make the creation and updating of tweaks faster and more efficient and, yes, even to reduce the impact of multiple tweaks on your phone's performance.
     
  2. Menneisyys2 macrumors 603

    Joined:
    Jun 7, 2011
    #2
    Also, let's not forget that it's very easy to track down a misbehaving dependency after you install a package that causes constant safe mode and uninstalling the given package doesn't help this.

    1. you can easily uninstall ALL (otherwise unused) depencencies using apt-get autoremove over OpenSSH. See my dedicated tutorial at http://forums.macrumors.com/showpost.php?p=18569011&postcount=13

    2, if you don't want to uninstall everything, just want to know what the dependencies are and manually uninstall them one-by-one, check out for example my quick tutorial HERE.

    Both approaches are safe and I've been using them frequently to track down trouble-causing dependencies.
     
  3. HankHowdy macrumors 68040

    HankHowdy

    Joined:
    Dec 2, 2012
    Location:
    Victorville CA
  4. thelatinist thread starter macrumors 603

    thelatinist

    Joined:
    Aug 15, 2009
    Location:
    Connecticut, USA
    #4
    You are by far not the only one around here complaining about dependencies.
     
  5. HankHowdy macrumors 68040

    HankHowdy

    Joined:
    Dec 2, 2012
    Location:
    Victorville CA
    #6

    My only issue with dependencies was with a certain tweak that I can't even remember. It wanted to install activator and I don't use it.

    I had bad experiences with it on ios 6.

    Something that I am noticing with ios 7 is that I have a lot more tweaks on my phone than with ios 6 and I can't see my phone slow down or act funny. It's running very well. Not really minding the dependencies this time around. Thanks for the lesson. :)
     
  6. thelatinist thread starter macrumors 603

    thelatinist

    Joined:
    Aug 15, 2009
    Location:
    Connecticut, USA
    #7
    But that's just the thing…you don't know why Activator was a dependency. It is probable that the tweak you were installing needed to intercept system events and Activator performed that function for it. So if you had used that tweak, you would have been using activator. Just because you don't open up Activator and reassign your system gestures doesn't mean it isn't serving a purpose.
     
  7. HankHowdy macrumors 68040

    HankHowdy

    Joined:
    Dec 2, 2012
    Location:
    Victorville CA
    #8

    But I have used activator before and I had issues with it. That's why I stayed away from it. Not because it was a dependency.
     

Share This Page