Jump to content

Cannot get prefubundle bool on tweak.x


princessXZ

11 posts in this topic

Recommended Posts

Posted

Hey.

I have a problem when compile the my tweak.

I think it cause calling getPrefBool But I don't know what should I do:/

I tried to add ARCHS = armv7 arm64 to Makefile But still get error

Please help me ..

Error

mafu:~/mcohack root# make package install
> Making all for tweak mcohack…
==> Preprocessing Tweak.x…
==> Preprocessing Tweak.x…
==> Compiling Tweak.x (arm64)…
==> Compiling Tweak.x (armv7)…
==> Linking tweak mcohack (armv7)…
Undefined symbols for architecture armv7:
  "_GetPrefBool", referenced from:
      __logos_method$_ungrouped$AppController$applicationDidBecomeActive$ in Tweak.x.ad486fbc.o
ld: symbol(s) not found for architecture armv7
Not signing file
clang-10: error: linker command failed with exit code 1 (use -v to see invocation)
make[3]: *** [/var/root/theos/makefiles/instance/library.mk:33: /var/root/mcohack/.theos/obj/debug/armv7/mcohack.dylib] Error 1
==> Linking tweak mcohack (arm64)…
Undefined symbols for architecture arm64:
  "_GetPrefBool", referenced from:
      __logos_method$_ungrouped$AppController$applicationDidBecomeActive$ in Tweak.x.86cf346b.o
ld: symbol(s) not found for architecture arm64
Not signing file
clang-10: error: linker command failed with exit code 1 (use -v to see invocation)
make[3]: *** [/var/root/theos/makefiles/instance/library.mk:33: /var/root/mcohack/.theos/obj/debug/arm64/mcohack.dylib] Error 1
make[2]: *** [/var/root/theos/makefiles/instance/library.mk:33: /var/root/mcohack/.theos/obj/debug/arm64/mcohack.dylib] Error 2
make[2]: *** Waiting for unfinished jobs....
make[2]: *** [/var/root/theos/makefiles/instance/library.mk:33: /var/root/mcohack/.theos/obj/debug/armv7/mcohack.dylib] Error 2
make[1]: *** [/var/root/theos/makefiles/instance/library.mk:24: internal-library-all_] Error 2
make: *** [/var/root/theos/makefiles/master/rules.mk:111: mcohack.all.tweak.variables] Error 2

Tweak.x

#define PLIST_PATH @"/var/mobile/Library/Preferences/com.zorba.prefbundle.plist"

inline bool GetPrefBool(NSString *key)
{
return [[[NSDictionary dictionaryWithContentsOfFile:PLIST_PATH] valueForKey:key] boolValue];
}

%hook AppController
-(void)applicationDidBecomeActive:(id)argument {
  if(GetPrefBool(@"DetectOpened")) {
    UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Title" message:@"Detected App opened!" delegate:nil cancelButtonTitle:@"Continue" otherButtonTitles:nil];
    [alert show];
  } else {
    return %orig;
  }
}
%end

prefbundle's plist

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>items</key>
    <array>
        <dict>
            <key>cell</key>
            <string>PSGroupCell</string>
            <key>label</key>
            <string>Settings</string>
        </dict>
        <dict>
            <key>cell</key>
            <string>PSSwitchCell</string>
            <key>default</key>
            <true/>
            <key>defaults</key>
            <string>com.zorba.prefbundle</string>
            <key>key</key>
            <string>DetectOpened</string>
            <key>label</key>
            <string>DetectOpened</string>
        </dict>
        <dict>
            <key>cell</key>
            <string>PSGroupCell</string>
            <key>label</key>
            <string>Contact</string>
        </dict>
        <dict>
            <key>cell</key>
            <string>PSButtonCell</string>
            <key>label</key>
            <string>Twitter</string>
            <key>action</key>
            <string>OpenTwitter</string>
        </dict>
    </array>
    <key>title</key>
    <string>mcohack</string>
</dict>
</plist>

Theos Version: Latest Version got from https://github.com/theos/theos

Device Info iPhone8 / IOS13.3.1 / jailbroken

Posted

cd the project and then enter "export THEOS=/var/root/theos" before making the package install.  I also prefer sdk 9.3 and have had @Error. get it too. You should also try to run the command to update Theos just in case, even though you think you're up to date.

go to Group.pm, open it, and change this line

my $functionRetval = shift $args;
my $functionName = shift $args;

With

my $functionRetval = shift @{$args};
my $functionName = shift @{$args};

 

You can also try removing armv7 from the makefile and remove the # before arm64e. If that doesn't work, remove #arm64e from the ARCHS. There's also a command you can run to fix any missing theos files but I completely forgot it. Now I don't know the whole thing with prefubundle but those are the steps I tell people to take when they get any compiling errors in theos.

Posted
1 hour ago, ZoZo said:

cd the project and then enter "export THEOS=/var/root/theos" before making the package install.  I also prefer sdk 9.3 and have had @Error. get it too. You should also try to run the command to update Theos just in case, even though you think you're up to date.

go to Group.pm, open it, and change this line


my $functionRetval = shift $args;
my $functionName = shift $args;

With


my $functionRetval = shift @{$args};
my $functionName = shift @{$args};

 

You can also try removing armv7 from the makefile and remove the # before arm64e. If that doesn't work, remove #arm64e from the ARCHS. There's also a command you can run to fix any missing theos files but I completely forgot it. Now I don't know the whole thing with prefubundle but those are the steps I tell people to take when they get any compiling errors in theos.

Thank you for your reply.

I followed these steps but I still get Error ._.

I am concerned that the original code in Group.pm was "undef" instead of "shift $args".

I show what I did below

// Theos Update
mafu:~ root# $THEOS/bin/update-theos
Fetching origin
Already up to date.
==> Notice: Visit https://github.com/theos/theos/releases to see the changelog.

// export THEOS=/var/root/theos
mafu:~/mcohack root# export THEOS=/var/root/theos

// /var/root/theos/vendor/logos/bin/lib/Logos/Group.pm
my $functionRetval = undef;
my $functionName = undef;
 ↓↓↓↓↓↓↓↓↓↓
my $functionRetval = shift @{$args};
my $functionName = shift @{$args};

// change to only ARMv7 and only ARM64

Posted
18 minutes ago, mafusuke said:

Thank you for your reply.

I followed these steps but I still get Error ._.

I am concerned that the original code in Group.pm was "undef" instead of "shift $args".

I show what I did below

// Theos Update
mafu:~ root# $THEOS/bin/update-theos
Fetching origin
Already up to date.
==> Notice: Visit https://github.com/theos/theos/releases to see the changelog.

// export THEOS=/var/root/theos
mafu:~/mcohack root# export THEOS=/var/root/theos

// /var/root/theos/vendor/logos/bin/lib/Logos/Group.pm
my $functionRetval = undef;
my $functionName = undef;
 ↓↓↓↓↓↓↓↓↓↓
my $functionRetval = shift @{$args};
my $functionName = shift @{$args};

// change to only ARMv7 and only ARM64

Weird, perhaps try reinstalling a fresh theos manually?

Posted
24 minutes ago, ZoZo said:

Weird, perhaps try reinstalling a fresh theos manually?

I reinstalled to follow steps https://github.com/theos/theos/wiki/Installation-iOS

I checked Group.pm first but there are

my $functionRetval = undef;

my $functionName = undef;

:(

https://github.com/theos/logos/blob/a54760ea60acf45fa48267b9fb344c0317d9351c/bin/lib/Logos/Group.pm

Posted
22 minutes ago, mafusuke said:

I reinstalled to follow steps https://github.com/theos/theos/wiki/Installation-iOS

I checked Group.pm first but there are

my $functionRetval = undef;

my $functionName = undef;

:(

https://github.com/theos/logos/blob/a54760ea60acf45fa48267b9fb344c0317d9351c/bin/lib/Logos/Group.pm

Weird, maybe someone else who may has more knowledge about this can help.

@absolut1on @Kilmnar

Posted

I hope they solve my problem:)
And I show more details about how did I install theos

add repo http://repo.bingner.com/
add "Theos Dependencies" in BigBoss
$ echo "export THEOS=~/theos" >> ~/.profile
<Restar shell>
echo $THEOS
$ git clone --recursive https://github.com/theos/theos.git $THEOS
$ curl -LO https://github.com/theos/sdks/archive/master.zip
// fix sdks
$ TMP=$(mktemp -d)
$ unzip master.zip -d $TMP
$ mv $TMP/sdks-master/*.sdk $THEOS/sdks
$ rm -r master.zip $TMP
// fix fakeroot
"$THEOS/bin/fakeroot.sh"を開き一番最後の部分を
> $fakeroot perl /var/root/theos/bin/$cmd
に変更
// fix group.pm
$ vim /var/root/theos/vendor/logos/bin/lib/Logos/Group.pm
my $functionRetval = undef;
my $functionName = undef;
↓↓↓↓↓↓↓↓↓↓
my $functionRetval = shift @{$args};
my $functionName = shift @{$args};
// add to makefile
<tweak_name>_LIBRARIES = substrate

Posted

Omg I found a workaround

I just changed file name from Tweak.x to Tweak.xm

And change makefile from <projectname>_FILES = Tweak.x to <projectname>_FILES = Tweak.xm

mafu:~/mcohack root# make package install
> Making all for tweak mcohack…
==> Preprocessing Tweak.xm…
==> Preprocessing Tweak.xm…
==> Compiling Tweak.xm (arm64)…
==> Compiling Tweak.xm (armv7)…
==> Linking tweak mcohack (arm64)…
==> Generating debug symbols for mcohack…
==> Linking tweak mcohack (armv7)…
==> Generating debug symbols for mcohack…
rm /var/root/mcohack/.theos/obj/debug/arm64/Tweak.xm.mm
rm /var/root/mcohack/.theos/obj/debug/armv7/Tweak.xm.mm
==> Merging tweak mcohack…
==> Signing mcohack…
> Making all in prefbundle…
> Making all for bundle prefbundle…
==> Copying resource directories into the bundle wrapper…
==> Compiling XXXRootListController.m (arm64)…
==> Compiling XXXRootListController.m (armv7)…
==> Linking bundle prefbundle (armv7)…
==> Generating debug symbols for prefbundle…
==> Linking bundle prefbundle (arm64)…
==> Generating debug symbols for prefbundle…
==> Merging bundle prefbundle…
==> Signing prefbundle…
> Making stage for tweak mcohack…
> Making stage in prefbundle…
> Making stage for bundle prefbundle…
dm.pl: building package `com.zorba.mcohack:iphoneos-arm' in `./packages/com.zorba.mcohack_0.0.1-1+debug_iphoneos-arm.deb'
==> Installing…
dpkg: warning: downgrading com.zorba.mcohack from 0.0.1-2+debug to 0.0.1-1+debug
(Reading database ... 58411 files and directories currently installed.)
Preparing to unpack .../com.zorba.mcohack_0.0.1-1+debug_iphoneos-arm.deb ...
Unpacking com.zorba.mcohack (0.0.1-1+debug) over (0.0.1-2+debug) ...
Setting up com.zorba.mcohack (0.0.1-1+debug) ...
Processing triggers for com.saurik.substrate.safemode (1.1) ...
==> Unloading '-'…
> Making after-install in prefbundle…

My Problem solved but I want to know the difference between Tweak.x and Tweak.xm and why this happens
thank you.

Archived

This topic is now archived and is closed to further replies.

  • Our picks

    • Conquer Countries v9.30 +5 Jailed Cheats [ Unlimited Currencies ]
      Modded/Hacked App: Conquer Countries By SUPERSONIC STUDIOS LTD
      Bundle ID: com.ridgge.conquercountries
      iTunes Store Link: https://apps.apple.com/us/app/conquer-countries/id6480472116?uo=4

       
       

      Hack Features

      - Add Money*
      - Add People*
      - Add Knowledge*
      - Unlimited Gems -> Earn some.
      -- Gold Pass Purchased

      * - Head into Settings and toggle the Sound button. Only enable 1 feature at a time.


      Jailbreak required iOS hacks: [Mod Menu Hack] Conquer Countries v9.0 +5 Cheats [ Unlimited Currencies ] - Free Jailbroken Cydia Cheats - iOSGods
      Modded Android APKs: https://iosgods.com/forum/68-android-section/
      • 36 replies
    • Conquer Countries v9.30 +5 Cheats [ Unlimited Currencies ]
      Modded/Hacked App: Conquer Countries By SUPERSONIC STUDIOS LTD
      Bundle ID: com.ridgge.conquercountries
      iTunes Store Link: https://apps.apple.com/us/app/conquer-countries/id6480472116?uo=4

       
       

      Hack Features

      - Add Money*
      - Add People*
      - Add Knowledge*
      - Unlimited Gems -> Earn some.
      -- Gold Pass Purchased

      * - Head into Settings and toggle the Sound button. Only enable 1 feature at a time.


      For Non-Jailbroken & No Jailbreak required hacks: [IPA Mod Menu] Conquer Countries v9.0 +5 Jailed Cheats [ Unlimited Currencies ] - Free Non-Jailbroken IPA Cheats - iOSGods
      Modded Android APK(s): https://iosgods.com/forum/68-android-section/
      • 18 replies
    • Idle Zombie Miner: Gold Tycoon v2.243.1940 +1++ Jailed Cheat [ Currencies ]
      Modded/Hacked App: Idle Zombie Miner: Gold Tycoon By VISTREX LIMITED
      Bundle ID: com.zombie.idleminertycoon
      iTunes Store Link: https://apps.apple.com/us/app/idle-zombie-miner-gold-tycoon/id6471983323?uo=4


      Hack Features:
      - Unlimited Currencies -> Will increase instead of decrease.


      Jailbreak required hack(s): [Mod Menu Hack] Idle Zombie Miner: Gold Tycoon v2.53.1001 +1++ Cheat [ Unlimited Currencies ] - Free Jailbroken Cydia Cheats - iOSGods
      Modded Android APK(s): https://iosgods.com/forum/68-android-section/
      For more fun, check out the Club(s): https://iosgods.com/clubs/
      • 109 replies
    • Idle Zombie Miner: Gold Tycoon v2.243.1940 +1++ Cheat [ Currencies ]
      Modded/Hacked App: Idle Zombie Miner: Gold Tycoon By VISTREX LIMITED
      Bundle ID: com.zombie.idleminertycoon
      iTunes Store Link: https://apps.apple.com/us/app/idle-zombie-miner-gold-tycoon/id6471983323?uo=4


      Hack Features:
      - Unlimited Currencies -> Will increase instead of decrease.


      Non-Jailbroken & No Jailbreak required hack(s): [Non-Jailbroken Hack] Idle Zombie Miner: Gold Tycoon v2.53.1001 +1++ Jailed Cheat [ Unlimited Currencies ] - Free Non-Jailbroken IPA Cheats - iOSGods
      Modded Android APK(s): https://iosgods.com/forum/68-android-section/
      For more fun, check out the Club(s): https://iosgods.com/clubs/
      • 72 replies
    • Disney Emoji Blitz Game v70.2.1 +1++ Jailed Cheat [ Unlimited Currencies ]
      Modded/Hacked App: Disney Emoji Blitz Game By Jam City, Inc.
      Bundle ID: com.disney.emojimatch
      iTunes Store Link: https://apps.apple.com/us/app/disney-emoji-blitz-game/id1017551780
       

      Hack Features:
      - Unlimited Currencies -> Earn some.


      Jailbreak required hack(s): https://iosgods.com/topic/168886-disney-emoji-blitz-game-all-versions-1-cheats-unlimited-currencies/
      Modded Android APK(s): https://iosgods.com/forum/68-android-section/
      For more fun, check out the Club(s): https://iosgods.com/clubs/
      • 182 replies
    • Eterspire - Fantasy MMORPG v55.0 +2 Jailed Cheats [ Damage & Defence ]
      Modded/Hacked App: Eterspire - Fantasy MMORPG By Stonehollow Workshop LLC
      Bundle ID: com.stonehollow-workshop.Eterspire
      iTunes Store Link: https://apps.apple.com/us/app/eterspire-fantasy-mmorpg/id1658183817?uo=4

       
       

      🤩 Hack Features

      - Damage Multiplier
      - Defence Multiplier
      • 26 replies
    • Eterspire - Fantasy MMORPG v55.0 +2 Cheats [ Damage & Defence ]
      Modded/Hacked App: Eterspire - Fantasy MMORPG By Stonehollow Workshop LLC
      Bundle ID: com.stonehollow-workshop.Eterspire
      iTunes Store Link: https://apps.apple.com/us/app/eterspire-fantasy-mmorpg/id1658183817?uo=4

       
       

      🤩 Hack Features

      - Damage Multiplier
      - Defence Multiplier
      • 106 replies
    • Love Sparks: Make Me Blush v2.46.0 +2++ Jailed Cheats [ Unlimited Currencies ]
      Modded/Hacked App: Love Sparks: Make Me Blush By SVEG MASHA, OOO
      Bundle ID: com.swagmasha.lovespark
      iTunes Store Link: https://apps.apple.com/us/app/love-sparks-make-me-blush/id1580105392?uo=4
       

      Hack Features:
      - Unlimited Gems -> Earn some.
      - VIP Enabled


      Jailbreak required hack(s): [Mod Menu Hack] Love Sparks: My Secret Fantasy v2.17.0 +2 Cheats [ Unlimited Gems ] - Free Jailbroken Cydia Cheats - iOSGods
      Modded Android APK(s): https://iosgods.com/forum/68-android-section/
      For more fun, check out the Club(s): https://iosgods.com/clubs/
      • 911 replies
    • Love Sparks: Make Me Blush v2.46.0 +2++ Cheats [ Unlimited Currencies ]
      Modded/Hacked App: Love Sparks: Make Me Blush By SVEG MASHA, OOO
      Bundle ID: com.swagmasha.lovespark
      iTunes Store Link: https://apps.apple.com/us/app/love-sparks-make-me-blush/id1580105392?uo=4
       

      Hack Features:
      - Unlimited Gems -> Earn some.
      - VIP Enabled


      Non-Jailbroken & No Jailbreak required hack(s): [Non-Jailbroken Hack] Love Sparks: My Secret Fantasy v2.17.0 +3 Jailed Cheats [ Unlimited Gems ] - Free Non-Jailbroken IPA Cheats - iOSGods
      Modded Android APK(s): https://iosgods.com/forum/68-android-section/
      For more fun, check out the Club(s): https://iosgods.com/clubs/
      • 393 replies
    • Disney Emoji Blitz Game v70.2.1 +1++ Cheat [ Unlimited Currencies ]
      Modded/Hacked App: Disney Emoji Blitz Game By Jam City, Inc.
      Bundle ID: com.disney.emojimatch
      iTunes Store Link: https://apps.apple.com/us/app/disney-emoji-blitz-game/id1017551780
       

      Hack Features:
      - Unlimited Currencies -> Earn some.


      Non-Jailbroken & No Jailbreak required hack(s): https://iosgods.com/topic/168888-disney-emoji-blitz-game-v5320-1-jailed-cheat-unlimited-currencies/
      Modded Android APK(s): https://iosgods.com/forum/68-android-section/
      For more fun, check out the Club(s): https://iosgods.com/clubs/
      • 60 replies
    • Train Attack: Merge War v1.0.5 [+4 Jailed Cheats]
      Modded/Hacked App: Train Attack: Merge War By MAD PIXEL GAMES LTD
      Bundle ID: adventure.train.battle.survive
      App Store Link: https://apps.apple.com/us/app/train-attack-merge-war/id6747774853?uo=4



      🤩 Hack Features

      - Remove Ads (Can crash game open again)
      - Activate Vip
      - Add Currency
      - Never Die
      • 2 replies
    • Train Attack: Merge War v1.0.5 [+4 Cheats]
      Modded/Hacked App: Train Attack: Merge War By MAD PIXEL GAMES LTD
      Bundle ID: adventure.train.battle.survive
      App Store Link: https://apps.apple.com/us/app/train-attack-merge-war/id6747774853?uo=4



      🤩 Hack Features

      - Remove Ads (Can crash game open again)
      - Activate Vip
      - Add Currency
      - Never Die
      • 4 replies
×
  • Create New...

Important Information

We would like to place cookies on your device to help make this website better. The website cannot give you the best user experience without cookies. You can accept or decline our cookies. You may also adjust your cookie settings. Privacy Policy - Guidelines