General [Tutorial] [Magisk] Enabling 32-bit Support For Apps

Search This thread

Bulletro

Member
Jan 17, 2023
6
2
Just wanted to say I've been on the January update and just recently moved to the A13 Beta and I've had no problems, I've been on Magisk Delta this entire time, including the update process.

If I understand this correctly, You can install Custom Magisk Delta, but then switch to Magisk or Stock and 32 bit support would remain? even through updates? because the libraries have to just be initially setup because through the update (still staying on Custom Magisk Delta) from January to Beta 32 bit remained I just regularly updated my P7P without wiping, just replacing with the patched init_boot
 

t3chwizard

Senior Member
Jul 20, 2013
1,643
358
Asus Transformer TF300T
LG Optimus G Pro
Just wanted to say I've been on the January update and just recently moved to the A13 Beta and I've had no problems, I've been on Magisk Delta this entire time, including the update process.

That gives some hope that it might work. But I don't want to risk it on the off chance it doesn't, so I'm gonna wait for nameless to do their Magisk **pun intended** and go from there
 

Namelesswonder

Senior Member
Jan 26, 2014
411
683
Google Pixel XL
Google Pixel 7 Pro
That gives some hope that it might work. But I don't want to risk it on the off chance it doesn't, so I'm gonna wait for nameless to do their Magisk **pun intended** and go from there
I just upgraded from December to January while simulating an issue by installing the update but not flashing the patched Magisk init_boot, and I was able to recover it to get 32-bit apps functional again.

I upgraded to TQ1A.230105.002, didn't flash the patched Magisk init_boot, and let the phone boot. Flashed the patched Magisk init_boot, and 32-bit applications would crash on launch. Zygote32 was running, 32-bit apps could be installed, but 32-bit libraries were not functional and thus 32-bit apps wouldn't launch.
I downloaded TQ1A.230105.002.A1 and patched the init_boot from it, dirty flashed TQ1A.230105.002.A1 and flashed the patched Magisk init_boot before booting and now 32-bit applications are functional again.
Then I could dirty flash TQ1A.230105.002 and use the patched Magisk init_boot I originally created for TQ1A.230105.002 and 32-bit applications were still functional.

It seems that a dirty flash of a different build is capable of getting Android to setup the libraries again? This is something I'll have to test next month as I'll then be testing Android 13 QPR2 Beta 3 so I'll be wiping for best practice and in that time I should see if a wipe is not required when going from stock January -> patched February, or from stock January global -> patched January Telstra with dirty flashes.

So as for you upgrading, it seems like there might be a way to recover if the upgrade fails for whatever reason. I would still recommend backing up your data before doing so, in case things don't go as planned.


General News​

I have gotten around to making some new builds and they are available on my GitHub download repository.

Magisk 32-bit fork​

Notable is that I now have a regular Magisk fork with the patch, so Magisk Delta is no longer the only option. This development is thanks to Magisk switching to LSPlt from libxhook for Zygisk.

The sources for my Magisk 32-bit fork can be found here with the download available from my GitHub download repository.
This fork is tracking beyond Magisk Canary 25206, and is built straight from upstream. It is closer to the unreleased Magisk Canary 25207 than it is to 25206. I have been testing it and have not encountered any problems so far.
I have updated the original post with details on how to switch between my forks, this includes my previous "custom Magisk Delta".

If you are switching from Magisk Delta make sure you aren't using any modules that require early-mount, as I understand there are now a few that do.

Magisk Delta 32-bit fork updated but also deprecated​

@wowkazmir @Bulletro
Also I have updated my Magisk Delta 32-bit fork to the latest upstream, download available from my GitHub download repository.
With the introduction of my regular Magisk fork I am deprecating my Magisk Delta fork as testing both in-depth is something I don't feel like doing.
I am still providing it, and it will continue to be updated for as long as I can easily maintain it, but it will be provided as-is. I can test if it boots and starts the secondary Zygote process, but that is going to be the depth of my testing. Testing additional features for if they are functional is something I will not be providing.

The early-mount feature will still be retained, as anyone not wanting their persist partition being used by modules can run my regular Magisk fork.

Name change for the forks​

I have slightly modified the names of the forks to differentiate them a bit further. Currently the names are not very descriptive as to what changes they carry, so probably next month I'm thinking about renaming the forks to Magisk Zygote64_32 and Magisk Delta Zygote64_32, since they would then be a bit more descriptive as to what they are intended to do: enable the Zygote64_32 service.

Update Repository​

Coinciding with the name change next month will be the introduction of updates back into the apps. It'll be a good time as any to make the Magisk stub functional again and allow you to get notifications of any new releases via the app rather than from the thread.

January Update​

Yes, both forks work fine on the January update.
I'm going to presume they work fine on Android 13 QPR2 Beta 2 as it's just a feature update, I'll be doing testing on next month when QPR2 Beta 3 releases.
 

t3chwizard

Senior Member
Jul 20, 2013
1,643
358
Asus Transformer TF300T
LG Optimus G Pro
I just upgraded from December to January while simulating an issue by installing the update but not flashing the patched Magisk init_boot, and I was able to recover it to get 32-bit apps functional again.

I upgraded to TQ1A.230105.002, didn't flash the patched Magisk init_boot, and let the phone boot. Flashed the patched Magisk init_boot, and 32-bit applications would crash on launch. Zygote32 was running, 32-bit apps could be installed, but 32-bit libraries were not functional and thus 32-bit apps wouldn't launch.
I downloaded TQ1A.230105.002.A1 and patched the init_boot from it, dirty flashed TQ1A.230105.002.A1 and flashed the patched Magisk init_boot before booting and now 32-bit applications are functional again.
Then I could dirty flash TQ1A.230105.002 and use the patched Magisk init_boot I originally created for TQ1A.230105.002 and 32-bit applications were still functional.

It seems that a dirty flash of a different build is capable of getting Android to setup the libraries again? This is something I'll have to test next month as I'll then be testing Android 13 QPR2 Beta 3 so I'll be wiping for best practice and in that time I should see if a wipe is not required when going from stock January -> patched February, or from stock January global -> patched January Telstra with dirty flashes.

So as for you upgrading, it seems like there might be a way to recover if the upgrade fails for whatever reason. I would still recommend backing up your data before doing so, in case things don't go as planned.


General News​

I have gotten around to making some new builds and they are available on my GitHub download repository.

Magisk 32-bit fork​

Notable is that I now have a regular Magisk fork with the patch, so Magisk Delta is no longer the only option. This development is thanks to Magisk switching to LSPlt from libxhook for Zygisk.

The sources for my Magisk 32-bit fork can be found here with the download available from my GitHub download repository.
This fork is tracking beyond Magisk Canary 25206, and is built straight from upstream. It is closer to the unreleased Magisk Canary 25207 than it is to 25206. I have been testing it and have not encountered any problems so far.
I have updated the original post with details on how to switch between my forks, this includes my previous "custom Magisk Delta".

If you are switching from Magisk Delta make sure you aren't using any modules that require early-mount, as I understand there are now a few that do.

Magisk Delta 32-bit fork updated but also deprecated​

@wowkazmir @Bulletro
Also I have updated my Magisk Delta 32-bit fork to the latest upstream, download available from my GitHub download repository.
With the introduction of my regular Magisk fork I am deprecating my Magisk Delta fork as testing both in-depth is something I don't feel like doing.
I am still providing it, and it will continue to be updated for as long as I can easily maintain it, but it will be provided as-is. I can test if it boots and starts the secondary Zygote process, but that is going to be the depth of my testing. Testing additional features for if they are functional is something I will not be providing.

The early-mount feature will still be retained, as anyone not wanting their persist partition being used by modules can run my regular Magisk fork.

Name change for the forks​

I have slightly modified the names of the forks to differentiate them a bit further. Currently the names are not very descriptive as to what changes they carry, so probably next month I'm thinking about renaming the forks to Magisk Zygote64_32 and Magisk Delta Zygote64_32, since they would then be a bit more descriptive as to what they are intended to do: enable the Zygote64_32 service.

Update Repository​

Coinciding with the name change next month will be the introduction of updates back into the apps. It'll be a good time as any to make the Magisk stub functional again and allow you to get notifications of any new releases via the app rather than from the thread.

January Update​

Yes, both forks work fine on the January update.
I'm going to presume they work fine on Android 13 QPR2 Beta 2 as it's just a feature update, I'll be doing testing on next month when QPR2 Beta 3 releases.

I'll admit I don't really know the difference between vanilla magisk and magisk delta, but it seems promising to be able to use something closer to vanilla magisk with the 32-bit patch. Sounds like great news, looking forward to the new updates!
 

Iven321

Member
Nov 25, 2019
5
1
Hi, I was using the customized magisk delta recommended by you before, but there is a problem with delta, the magisk hide function is not compatible with the font module, so I plan to change to the new method you currently recommend, from the customized magisk delta Switching to the customized version magisk 32-bit, what do I need to do?
 

t3chwizard

Senior Member
Jul 20, 2013
1,643
358
Asus Transformer TF300T
LG Optimus G Pro
Hi, I was using the customized magisk delta recommended by you before, but there is a problem with delta, the magisk hide function is not compatible with the font module, so I plan to change to the new method you currently recommend, from the customized magisk delta Switching to the customized version magisk 32-bit, what do I need to do?
I would just wait a few days or a week or however it takes for nameless to finish testing the new methods and go from there. That way you don't have to redo anything if things change at all
 

nomfway

Member
Oct 29, 2022
36
13
Additionally if you are switching between my Magisk Delta 32-bit and Magisk you should flash your backed up persist.img
Just wondering, what is the ideal time to flash the backed up persist.img? After flashing the patched init_boot.img or at any time that is simply before rebooting the phone to set up Magisk 32bit support?
 

t3chwizard

Senior Member
Jul 20, 2013
1,643
358
Asus Transformer TF300T
LG Optimus G Pro
Just wondering, what is the ideal time to flash the backed up persist.img? After flashing the patched init_boot.img or at any time that is simply before rebooting the phone to set up Magisk 32bit support?

On first setup I believe you're supposed to do it before you boot the phone after skipping the reboot and flashing the new update on fastboot. At least that's what I tried to update to other builds and it didn't work.
 

Namelesswonder

Senior Member
Jan 26, 2014
411
683
Google Pixel XL
Google Pixel 7 Pro
Just wondering, what is the ideal time to flash the backed up persist.img? After flashing the patched init_boot.img or at any time that is simply before rebooting the phone to set up Magisk 32bit support?
Just flash it at the same time you're flashing the Magisk 32-bit init_boot when making the switch from Magisk Delta, or at any time after.
You don't even need to do it if: your device is working fine or you never installed any modules that used the feature. Your device in this state just has a couple extra empty directories on the partition.
Flashing the backup is a catch-all as not everyone is going to know what modules may or may not have used early-mount, they might potentially leave the partition with unused files or in an unknown or possibly corrupted state. It's just to bring the partition back to a known good state after it's been modified.

On first setup I believe you're supposed to do it before you boot the phone after skipping the reboot and flashing the new update on fastboot. At least that's what I tried to update to other builds and it didn't work.
No, the only time you should be flashing a persist backup is when you're no longer using Magisk Delta or the sensors or other components on your device are not functioning.

You especially don't want to be doing it while still using stock Magisk Delta + early-mount modified vendor build.prop (the setup the requires you to manually copy files to the persist partition).

Flashing the backup is restoring the partition back to the state at when you made the backup.

Flashing the partition when using my Magisk fork: no effect on 32-bit support.
Flashing the partition when using my Magisk Delta fork: if you have any modules that use early-mount then you've just wiped any files they put there, other than that no effect on your 32-bit support.
Flashing the partition while using stock Magisk Delta and modified vendor build.prop: you've just wiped the modified vendor build.prop and now when you boot your device it won't start the secondary Zygote process, and thus no 32-bit support.
 

t3chwizard

Senior Member
Jul 20, 2013
1,643
358
Asus Transformer TF300T
LG Optimus G Pro
Just flash it at the same time you're flashing the Magisk 32-bit init_boot when making the switch from Magisk Delta, or at any time after.
You don't even need to do it if: your device is working fine or you never installed any modules that used the feature. Your device in this state just has a couple extra empty directories on the partition.
Flashing the backup is a catch-all as not everyone is going to know what modules may or may not have used early-mount, they might potentially leave the partition with unused files or in an unknown or possibly corrupted state. It's just to bring the partition back to a known good state after it's been modified.


No, the only time you should be flashing a persist backup is when you're no longer using Magisk Delta or the sensors or other components on your device are not functioning.

You especially don't want to be doing it while still using stock Magisk Delta + early-mount modified vendor build.prop (the setup the requires you to manually copy files to the persist partition).

Flashing the backup is restoring the partition back to the state at when you made the backup.

Flashing the partition when using my Magisk fork: no effect on 32-bit support.
Flashing the partition when using my Magisk Delta fork: if you have any modules that use early-mount then you've just wiped any files they put there, other than that no effect on your 32-bit support.
Flashing the partition while using stock Magisk Delta and modified vendor build.prop: you've just wiped the modified vendor build.prop and now when you boot your device it won't start the secondary Zygote process, and thus no 32-bit support.

Sorry I read his message early in my day and didn't see it clearly. I was referring to when you're supposed to flash the patched init_boot.img file and not the backup persist. Apologies for the confusion
 

nomfway

Member
Oct 29, 2022
36
13
I flashed both persist.img and the newly patched init_boot.img by Magisk 32-bit fork, my phone has successfuly booted up!
 

wowkazmir

Senior Member
Aug 16, 2010
115
17
I just upgraded from December to January while simulating an issue by installing the update but not flashing the patched Magisk init_boot, and I was able to recover it to get 32-bit apps functional again.

I upgraded to TQ1A.230105.002, didn't flash the patched Magisk init_boot, and let the phone boot. Flashed the patched Magisk init_boot, and 32-bit applications would crash on launch. Zygote32 was running, 32-bit apps could be installed, but 32-bit libraries were not functional and thus 32-bit apps wouldn't launch.
I downloaded TQ1A.230105.002.A1 and patched the init_boot from it, dirty flashed TQ1A.230105.002.A1 and flashed the patched Magisk init_boot before booting and now 32-bit applications are functional again.
Then I could dirty flash TQ1A.230105.002 and use the patched Magisk init_boot I originally created for TQ1A.230105.002 and 32-bit applications were still functional.

It seems that a dirty flash of a different build is capable of getting Android to setup the libraries again? This is something I'll have to test next month as I'll then be testing Android 13 QPR2 Beta 3 so I'll be wiping for best practice and in that time I should see if a wipe is not required when going from stock January -> patched February, or from stock January global -> patched January Telstra with dirty flashes.

So as for you upgrading, it seems like there might be a way to recover if the upgrade fails for whatever reason. I would still recommend backing up your data before doing so, in case things don't go as planned.


General News​

I have gotten around to making some new builds and they are available on my GitHub download repository.

Magisk 32-bit fork​

Notable is that I now have a regular Magisk fork with the patch, so Magisk Delta is no longer the only option. This development is thanks to Magisk switching to LSPlt from libxhook for Zygisk.

The sources for my Magisk 32-bit fork can be found here with the download available from my GitHub download repository.
This fork is tracking beyond Magisk Canary 25206, and is built straight from upstream. It is closer to the unreleased Magisk Canary 25207 than it is to 25206. I have been testing it and have not encountered any problems so far.
I have updated the original post with details on how to switch between my forks, this includes my previous "custom Magisk Delta".

If you are switching from Magisk Delta make sure you aren't using any modules that require early-mount, as I understand there are now a few that do.

Magisk Delta 32-bit fork updated but also deprecated​

@wowkazmir @Bulletro
Also I have updated my Magisk Delta 32-bit fork to the latest upstream, download available from my GitHub download repository.
With the introduction of my regular Magisk fork I am deprecating my Magisk Delta fork as testing both in-depth is something I don't feel like doing.
I am still providing it, and it will continue to be updated for as long as I can easily maintain it, but it will be provided as-is. I can test if it boots and starts the secondary Zygote process, but that is going to be the depth of my testing. Testing additional features for if they are functional is something I will not be providing.

The early-mount feature will still be retained, as anyone not wanting their persist partition being used by modules can run my regular Magisk fork.

Name change for the forks​

I have slightly modified the names of the forks to differentiate them a bit further. Currently the names are not very descriptive as to what changes they carry, so probably next month I'm thinking about renaming the forks to Magisk Zygote64_32 and Magisk Delta Zygote64_32, since they would then be a bit more descriptive as to what they are intended to do: enable the Zygote64_32 service.

Update Repository​

Coinciding with the name change next month will be the introduction of updates back into the apps. It'll be a good time as any to make the Magisk stub functional again and allow you to get notifications of any new releases via the app rather than from the thread.

January Update​

Yes, both forks work fine on the January update.
I'm going to presume they work fine on Android 13 QPR2 Beta 2 as it's just a feature update, I'll be doing testing on next month when QPR2 Beta 3 releases.
I appreciate you taking the time to explain your choices and for putting the effort into maintaining the 32 bit-helper. I have restored my original persist and flashed the custom original magisk. I'd be more than happy to keep testing this as it seems 32 bit apps will still be used for some time to come.
 

bao_gg

Member
Aug 20, 2017
41
2
Thanks OP for making 32-bit apps available on Pixel 7 again.
I plan to use OP recommended Magisk 32-bit fork. The phone has bootloader unlocked with stock ROM on Jan update. Some confusions:
1, Do I still need to do step 3 "flash the stock init_boot.img" because the phone is already on stock?
2, What does step 8 "Flash and wipe via fastboot --skip-reboot -w update image-xxx.zip" mean? Is this "image-xxx.zip" the stock factory image zip file?
3, We "install the Magisk 32-bit app from my repository" on step 4 already, do we need to do step 12 "Do not open the Magisk stub (the default Android icon), install the Magisk 32-bit app from my repository" again?
4, After step 10 "Flash the patched Magisk init_boot.img and boot into Android", has the phone been rooted?
5, Does your Magisk support LSposed module (Zygisk version) so that I can install AOSP mods later?
6, How to backup my phone's persist partition although I do not use Magisk Delta fork? Just in case.
Sorry for so many dumb questions.
 

t3chwizard

Senior Member
Jul 20, 2013
1,643
358
Asus Transformer TF300T
LG Optimus G Pro
Thanks OP for making 32-bit apps available on Pixel 7 again.
I plan to use OP recommended Magisk 32-bit fork. The phone has bootloader unlocked with stock ROM on Jan update. Some confusions:
1, Do I still need to do step 3 "flash the stock init_boot.img" because the phone is already on stock?
2, What does step 8 "Flash and wipe via fastboot --skip-reboot -w update image-xxx.zip" mean? Is this "image-xxx.zip" the stock factory image zip file?
3, We "install the Magisk 32-bit app from my repository" on step 4 already, do we need to do step 12 "Do not open the Magisk stub (the default Android icon), install the Magisk 32-bit app from my repository" again?
4, After step 10 "Flash the patched Magisk init_boot.img and boot into Android", has the phone been rooted?
5, Does your Magisk support LSposed module (Zygisk version) so that I can install AOSP mods later?
6, How to backup my phone's persist partition although I do not use Magisk Delta fork? Just in case.
Sorry for so many dumb questions.

1. If you haven't rooted it yet with Magisk and have booted the device previously you probably are going to need to flash the stock ROM again right before you flash the patched init_boot.img (I could be mistaken though so some clarification from @Namelesswonder would be good here). You are probably going to need to root it with regular magisk, patch the init_boot.img and then wipe the device then flash the patched init_boot.img (unless someone here can upload a patched init_boot.img for you for whatever build you want to run) and you could just try flashing that (but you will probably need to wipe the device before flashing the patched init_boot.img).

2. Step 8 which talks about "image.xxx.zip" is referring to a zip file within the stock update zip you would download from Google for your device.

3. I am not sure about this step so some clarification from @Namelesswonder about the Magisk stub would be best here.

4. After you flash the patched init_boot.img the phone should be rooted, just make sure not to boot it until you have flashed the patched init_boot.img or you will have to wipe the device and start over if you boot

5. His Magisk fork is a fork of regular Magisk so it definitely supports Zygisk unless indicated otherwise, plus even his Delta fork worked with Zygisk for me so I would imagine it does (but again some clarification from @Namelesswonder would probably be best here).

6. Regardless if you use Magisk Delta fork or not the steps to backup your persist partition are identical. Just run the script to use it.

This was a lot so if anyone can correct any mistakes I made please do so
 
Last edited:
  • Like
Reactions: bao_gg

t3chwizard

Senior Member
Jul 20, 2013
1,643
358
Asus Transformer TF300T
LG Optimus G Pro
@Namelesswonder If we are currently on the deprecated 32-bit Magisk Delta fork (say November build) can we just install the apk for your new 32-bit Magisk Fork, patch the init_boot.img for the January build using your new 32-bit Magisk Fork and then update (without wiping) and flash the patched January init_boot.img to update?
 

Namelesswonder

Senior Member
Jan 26, 2014
411
683
Google Pixel XL
Google Pixel 7 Pro
Thanks OP for making 32-bit apps available on Pixel 7 again.
I plan to use OP recommended Magisk 32-bit fork. The phone has bootloader unlocked with stock ROM on Jan update. Some confusions:
1, Do I still need to do step 3 "flash the stock init_boot.img" because the phone is already on stock?
2, What does step 8 "Flash and wipe via fastboot --skip-reboot -w update image-xxx.zip" mean? Is this "image-xxx.zip" the stock factory image zip file?
3, We "install the Magisk 32-bit app from my repository" on step 4 already, do we need to do step 12 "Do not open the Magisk stub (the default Android icon), install the Magisk 32-bit app from my repository" again?
4, After step 10 "Flash the patched Magisk init_boot.img and boot into Android", has the phone been rooted?
5, Does your Magisk support LSposed module (Zygisk version) so that I can install AOSP mods later?
6, How to backup my phone's persist partition although I do not use Magisk Delta fork? Just in case.
Sorry for so many dumb questions.
1. If you're stock then you can skip it.

2. image-xxx.zip would be the system image zip from inside the factory image zip.
You don't need to actually do that if you are stock, just run fastboot -w instead.

3. Yes, because you've just wiped your device, and I haven't set up my repository JSON files yet so the stub app can't automatically download the full app.

4. Yes, but the full app needs to be installed so you can authorize root access.

5. Yes, my forks have no changes to the core functionality of Magisk, so all modules are supported.

6. As root dd if=/dev/block/by-name/persist of=/sdcard/persist.img

@Namelesswonder If we are currently on the deprecated 32-bit Magisk Delta fork (say November build) can we just install the apk for your new 32-bit Magisk Fork, patch the init_boot.img for the January build using your new 32-bit Magisk Fork and then update (without wiping) and flash the patched January init_boot.img to update?
Yes, that's fine. Just make sure you are following the system upgrade instructions and using the fastboot option to not automatically reboot after flashing the system image.
 
  • Like
Reactions: bao_gg

t3chwizard

Senior Member
Jul 20, 2013
1,643
358
Asus Transformer TF300T
LG Optimus G Pro
Yes, that's fine. Just make sure you are following the system upgrade instructions and using the fastboot option to not automatically reboot after flashing the system image.
Alright I'll give it a try today probably and see how it goes. If it goes wrong can I just flash the old update without wiping then flash the old 32-bit Magisk Delta init_boot.img after restoring the persist backup? (if I even need to restore persist since the new 32-bit Magisk Fork doesn't even touch it).
 

Namelesswonder

Senior Member
Jan 26, 2014
411
683
Google Pixel XL
Google Pixel 7 Pro
Alright I'll give it a try today probably and see how it goes. If it goes wrong can I just flash the old update without wiping then flash init_boot.img after restoring the persist backup?
In theory dirty flashing older factory images is possible, but your mileage may vary. Since you would be going from A13 QPR1 to A13 it might work, but the further apart the releases are the less chance it will work.

Just make sure if you do need to flash back to an old version that you are also flashing the bootloader and radio too, and that you have a patched init_boot for that version.
 

t3chwizard

Senior Member
Jul 20, 2013
1,643
358
Asus Transformer TF300T
LG Optimus G Pro
In theory dirty flashing older factory images is possible, but your mileage may vary. Since you would be going from A13 QPR1 to A13 it might work, but the further apart the releases are the less chance it will work.

Just make sure if you do need to flash back to an old version that you are also flashing the bootloader and radio too, and that you have a patched init_boot for that version.
Yea forgot about the bootloader/radio etc, but it would have reminded me when flashing because it doesn't let you flash without the minimum version from what I saw last time. I'll probably try to go to from November to December first maybe if January doesn't work but I'll see how it goes.
 

Top Liked Posts

  • There are no posts matching your filters.
  • 2

    Update News​

    Magisk 32-bit b27e4930-32bit (25210)

    An hour after I pushed out the last update the navigational issues in the app were resolved. This version is based off of fe6b658c.

    There's no changes outside of the app, so updating the Magisk in the init_boot is not necessary, although because of the version change the app will give the option to.

    Magisk 32-bit b8989a16-32bit (25210)

    New version is up that is based off of 1a164679.
    It aligns with canary 25210, however includes the latest commits that have fixed Magisk on Android 14 Developer Preview 2.

    I tested it and it works on A14 DP2, however that was with a dirty flash update from DP1. I don't know if it is functional after a clean flash.

    Known issue is that the patching/flashing log window can't be backed out of in the app, just close and reopen it if you need to do something else in Magisk before rebooting.
    2
    If the usual method of holding down the power button for a full minute or power button + volume down for a full minute doesn't work then you're going to have to try to get it replaced.
    At the moment nobody knows how to force the phone out of emergency download mode when it gets stuck in it.

    It's dumb that Google is still offering r34.0.0 of platform-tools, they've even mentioned an r34.0.1 that fixes the problem but the latest download is still only r34.0.0.
    Great news, I was able to get a replacement (not from google but the 3rd party I bought it from since I am in an unsupported country) after almost 6+ hours on phone arguing over it. I was able to get the GE2AE Model too so I get mmwave + sub 6ghz so everything is great, it should arrive tomorrow.

    From what I know if anyone else bricks their phone through the bug of r34.0.0 it should be fully under warranty, since most 3rd party's are providing support and so is first party google. Funny part is that after I warranty'd they updated their policies to add if "You have used a computer to flash, update, or modify the software on the phone it voids the warranty"
    1
    Can i get some help i keep running into this problem:
    C:\Users\Gogop\Desktop\platform-tools>fastboot --skip-reboot -w update image.zip
    --------------------------------------------
    Bootloader Version...: cloudripper-1.0-9288096
    Baseband Version.....: g5300g-220923-221028-B-9229469
    Serial Number......
    --------------------------------------------
    extracting android-info.txt (0 MB) to RAM...
    Checking 'product' OKAY [ 0.000s]
    Checking 'version-bootloader' OKAY [ 0.000s]
    Checking 'version-baseband' OKAY [ 0.000s]
    Setting current slot to 'b' OKAY [ 0.117s]
    extracting boot.img (64 MB) to disk... took 0.145s
    archive does not contain 'boot.sig'
    Sending 'boot_b' (65536 KB) OKAY [ 2.088s]
    Writing 'boot_b' OKAY [ 0.161s]
    extracting init_boot.img (8 MB) to disk... took 0.016s
    archive does not contain 'init_boot.sig'
    Sending 'init_boot_b' (8192 KB) OKAY [ 0.257s]
    Writing 'init_boot_b' OKAY [ 0.016s]
    extracting dtbo.img (16 MB) to disk... took 0.036s
    archive does not contain 'dtbo.sig'
    Sending 'dtbo_b' (16384 KB) OKAY [ 0.515s]
    Writing 'dtbo_b' OKAY [ 0.039s]
    archive does not contain 'dt.img'
    extracting pvmfw.img (1 MB) to disk... took 0.002s
    archive does not contain 'pvmfw.sig'
    Sending 'pvmfw_b' (1024 KB) OKAY [ 0.032s]
    Writing 'pvmfw_b' OKAY [ 0.005s]
    archive does not contain 'recovery.img'
    extracting vbmeta.img (0 MB) to disk... took 0.000s
    archive does not contain 'vbmeta.sig'
    Sending 'vbmeta_b' (12 KB) OKAY [ 0.000s]
    Writing 'vbmeta_b' OKAY [ 0.003s]
    extracting vbmeta_system.img (0 MB) to disk... took 0.000s
    archive does not contain 'vbmeta_system.sig'
    Sending 'vbmeta_system_b' (4 KB) OKAY [ 0.001s]
    Writing 'vbmeta_system_b' OKAY [ 0.003s]
    extracting vbmeta_vendor.img (0 MB) to disk... took 0.000s
    archive does not contain 'vbmeta_vendor.sig'
    Sending 'vbmeta_vendor_b' (4 KB) OKAY [ 0.000s]
    Writing 'vbmeta_vendor_b' OKAY [ 0.004s]
    extracting vendor_boot.img (64 MB) to disk... took 0.143s
    archive does not contain 'vendor_boot.sig'
    Sending 'vendor_boot_b' (65536 KB) OKAY [ 2.069s]
    Writing 'vendor_boot_b' OKAY [ 0.162s]
    extracting vendor_kernel_boot.img (64 MB) to disk... took 0.110s
    archive does not contain 'vendor_kernel_boot.sig'
    Sending 'vendor_kernel_boot_b' (65536 KB) OKAY [ 2.066s]
    Writing 'vendor_kernel_boot_b' OKAY [ 0.155s]
    extracting super_empty.img (0 MB) to disk... took 0.000s
    extracting product.img (2778 MB) to disk... took 7.526s
    extracting system.img (841 MB) to disk... took 2.387s
    extracting system_dlkm.img (0 MB) to disk... took 0.000s
    extracting system_ext.img (356 MB) to disk... took 1.017s
    extracting system_other.img (24 MB) to disk... took 0.079s
    extracting vendor.img (636 MB) to disk... took 1.678s
    extracting vendor_dlkm.img (40 MB) to disk... took 0.081s
    archive does not contain 'vendor_other.img'
    Sending sparse 'super' 1/1 (4194303 KB) FAILED (Sparse file is too large or invalid)
    fastboot: error: Command failed
    Download an older version of platform tools, 34.0.0 is bugged.

    1
    I was using platform tools 34.0.0 and got the exact same error, it corrupted and bricked my phone (also in this bug report in the comments shows another person whos phone also got bricked). Were you able to get it working and phone working using 33? If so how since I'm partially stuck with an unbootable phone.
    It depends on what you mean by bricked.
    It means has different meaning to different people.
    If you can get into bootloader mode, then it's not bricked and should be recoverable by flashing stock image with proper Android platform tools.
    A true bricked is when the phone does not respond to anything, it can't get into bootloader or recovery mode.
    Bootloop is not a brick.
  • 26

    The 32-bit apps are back!​

    Synopsis​

    The Pixel 7 line is Google's first "64-bit only" phones, along with being the highest profile release of a 64-bit only device so far. The device uses the Tensor G2 (GS201), which is a close descendant of the Tensor (GS101) from the Pixel 6 line. So close, that the only major change was swapping out the ARM Cortex-A76 cores for ARM Cortex-A78 cores. The SoC still has full 32-bit support.

    This was seemingly done at the last minute to get the ball rolling on switching Android to becoming 64-bit only at some point in the future. That future might be soon for other currently supported Pixel phones as the Android 13 QPR1 Beta includes optional firmware images that are 64-bit only. Given that it is currently optional on QPR1, there is a chance that at the earliest Android 14 will be 64-bit only across all supported Pixels, with a slimmer chance that it will be 64-bit only for AOSP also.

    The three items that are of importance are AArch32, what Zygote services are set to start, and whether the build supports multilib.

    AArch32​

    Is a mode starting with ARMv8 that provides support for the 32-bit ARM ABIs: armeabi and armeabi-v7a. An ABI is what defines how software is to be built and ran for specific instruction sets.​
    AArch32 is not required to be supported with ARMv9-A architectures, which would be processors starting with ARM Cortex-X2/X3/A715. These processors support AArch64 only.​
    The ARM Cortex-A510 is currently the only ARMv9-A processor that supports AArch32. This combination of processors (X2/X3/A715 with A510) results in asymmetric 32-bit support. This is the likely reason for Google expediting these changes. It is speculated that the Cortex-A520 will not support AArch32, which would put a stop to native 32-bit support completely for future devices.​
    Tensor G2 cores are still on ARMv8-A and thus still support AArch32.​

    Zygote​

    Is a service that handles creating VMs for starting applications, and is responsible for allowing resources to be shared to reduce memory bloat from duplication. There are two Zygote services, Zygote64 and Zygote (colloquially referred to as Zygote32). Each handle a "warm" VM that is preloaded with libraries, which gets cloned for starting an application. This is done via copy-on-write, which means a copy is only made and occupies memory when attempting to modify a resource. The untouched copies all point back to the original, saving memory.​
    Without Zygote32, 32-bit applications can't be started. Without Zygote64, 64-bit applications can't be started.​
    Having multiple Zygote processes is referred to as "Zygote64_32"​

    Multilib​

    Is a scheme that allows for 32-bit and 64-bit libraries to reside on the same device. This is required to support running 32-bit applications on 64-bit devices. Android has it's own implementation that differs from most Linux distributions, which may also differ between each other.​
    Obviously, without 32-bit libraries (or inversely without 64-bit libraries), a build does not support multilib.​
    Somewhat important to note is that the 64-bit only QPR1 Beta images for the Pixel 4a to 6 are true 64-bit only, they do not support multilib. However, as noted here by Google, the Pixel 7 is 64-bit only but does support multilib.

    The support matrix is as follows:
    Phone + SoC, Build
    SoC AArch32 Support
    Zygote Property
    Multilib
    32-bit Support?​
    Pixel 6 with Tensor​
    Yes​
    Zygote64_32​
    Yes​
    Native
    Pixel 6 with Tensor, 64-bit Only Build​
    Yes​
    Zygote64​
    No​
    Not Possible*​
    Pixel 7 with Tensor G2​
    Yes​
    Zygote64​
    Yes​
    With Modification
    Pixel 7 with Tensor G2, 64-bit Only Build**​
    Yes​
    Zygote64​
    No​
    Not Possible*​
    Phone with AArch64-only ARMv9-A​
    No​
    Zygote64​
    No​
    Not Possible***​
    * If no multilib build is also available. It may be possible with extensive work to use Treble to bring 32-bit libraries forward, assuming Android 14+ doesn't remove AArch32 and Zygote32. Emulation could be a possibility but has not been done yet.
    ** Build does not exist yet. It may be realized with Android 13 QPR2/3 or it may be done with Android 14 instead.
    *** Emulation could be a possibility but has not been done yet. Currently just the Pixel 6 and 7 have KVM built-in, but the Pixel 7 is the only one with it on by default. There is no graphics layer yet.

    This means that with the right changes 32-bit support can be enabled and used if 32-bit libraries are on the device and the SoC supports AArch32.


    Modifications​

    The changes required are as follows:

    ro.zygote=zygote64_32
    ro.vendor.product.cpu.abilist=arm64-v8a,armeabi-v7a,armeabi
    ro.vendor.product.cpu.abilist32=armeabi-v7a,armeabi
    Genuinely that simple, property changes. Because the libraries are already in the firmware images it is just the need to instruct Android to use them.
    Zygote64_32 refers to starting Zygote64 as the primary process, then starting Zygote32 as the secondary process. With this in place 32-bit applications can be installed and ran as 32-bit libraries are now able to be loaded.

    The changes that need to be done are to either be applied to /vendor/build.prop, or done with init.rc modifications, or applied in some way before init.rc is read.

    The last point is the critical issue that has halted this: there has not been any easy way to set properties very early in the boot process outside of simply just modifying the file on the partition.
    This can't be done easily due to dynamic partitions requiring a custom super partition, and with the larger issue being AVB.

    However two solutions have been brought forward:

    The first solution is thanks to ThomasKing2014, he has created Pixel 7 32-bit helper which is a modified Magisk that changes magiskinit to modify /vendor/build.prop early in boot​

    The patch he has created has been the start for this. The patch gets applied to Magisk and modifies magiskinit so that during boot Magisk will modify /vendor/build.prop with the values for the properties needed. magiskinit continues with initialization, hands off to the stock init which then reads ro.zygote to determine what Zygote rc file to load.
    Then Zygote64 and Zygote32 are started.

    The second solution is thanks to @huskydg for Magisk Delta which is a Magisk fork that implements many additional features​


    Currently I have repositories set up with rebased patches and modified versions of Magisk and Magisk Delta using the patch.​



    Forewarning​

    Currently, a wipe is required to get the modification to work fully.

    I do not know exactly why, but when a device is first booted with only Zygote64 it can't be switched over to use Zygote64_32. For some reason the 32-bit libraries inside APEXs are not discovered and loaded by Zygote32.
    It's a strange thing. If first boot is with Zygote64, then immediately rebooting to use Zygote64_32 will appear to work, but things are subtly broken in the background as only a few libraries don't have their 32-bit counterparts loaded. This gets exacerbated with preexisting systems, where lots of libraries have been used and their 32-bit counterparts are never discovered when switching to Zygote64_32. Ends up resulting in things like boot hangs or even the boot process aborting very early.


    Magisk Delta uses persist on the Pixel 7 and allows modules to write to it

    The persist partition is used by Magisk Delta to hold the early-mount.d directory for it's early-mount feature.
    Modifying persist has an inherent dangerous aspect due to the fact it is unique to each device. Corruption or modification of the calibration data in the partition can result in causing functions of your device to fail.
    Magisk Delta is not doing this inherently on all devices, this is actually because the Pixel 7's persist is the only partition that is not encrypted, is not checked by AVB, and is available early in the boot process. This is actually an extension of the functionality from stock Magisk, as stock Magisk is trying to do the same thing to store SELinux policy rules.


    Thus I recommend using my Magisk 32-bit fork instead. However if you need Magisk Delta for it's features then it is best practice before installing Magisk Delta to make a backup of your persist. There will be steps on how to do that before installing Magisk Delta.

    Support for custom ROMs is not guaranteed

    It may or may not work. As a matter of fact, doing this modification isn't necessary as custom ROMs could implement this change themselves.
    It is known that the modification does work on LineageOS.

    I have not tested all 32-bit applications

    I don't actually use any 32-bit apps. I have done testing with a few 32-bit apps I've gotten from APKMirror. So no, I don't know if your Instagram mod is working. I don't see any reason why it wouldn't.

    This modification is not 'install and forget'​

    Like with using custom kernels requiring you to keep on making sure verity and verification are off, this modification requires that you keep a finger on the pulse for any news or updates. You're essentially on the bleeding edge now. The hammer could drop next month and the update is true 64-bit without multilib. Performing an update and forgetting to flash the patched Magisk could require you to wipe your device.


    Download Links​

    All files are hosted at my download repository

    Magisk 32-bit:​

    Recommended:
    If you are having troubles and need to produce logs:​

    Magisk Delta 32-bit:​

    For Advanced Users:

    If you are having troubles and need to produce logs:​


    Installation Instructions​

    General Prerequisites:​

    A working platform-tools environment
    platform-tools 33.0.3 is required with the Pixel 7​
    The version you are running can be checked with adb --version and fastboot --version
    If you need assistance then read this thread by @roirraW "edor" ehT.​
    Tools like PixelFlasher can be used, just read into how to use it.​
    The factory image for the firmware version you are running or plan to run
    Part of the steps are going to be doing a flashing wipe on your device, to guarantee that you start with a reproducible blank slate.​
    Copy init_boot.img out from image-xxx.zip​

    Backup your data
    At the moment a wipe is required, so perform two backups: with Google Backup or your favorite backup app and a manual backup of any files.​

    With my Magisk 32-bit fork (Recommended)

    Magisk 32-bit with the rebased patch by me.​

    Direct download link for my Magisk 32-bit APK


    Steps:​

    Note: If you are unrooted and stock then skip to step 4​
    1. On your phone uninstall the stock Magisk app. Do not use the uninstall Magisk button from within the app, simply just uninstall the app itself.
    2. Reboot your phone into the bootloader.
    3. Flash the stock init_boot.img for your version and then boot into Android.
    4. Install the Magisk 32-bit app from my repository.
    5. Copy over the stock init_boot.img to your phone and patch it in the Magisk app.
    6. Copy the patched Magisk init_boot.img over to your computer
    7. Reboot your phone into the bootloader.
    8. Flash and wipe via fastboot --skip-reboot -w update image-xxx.zip
    9. Wait for it to finish, then reboot back into the bootloader either on the device or with fastboot reboot bootloader
    10. Flash the patched Magisk init_boot.img and boot into Android.
    11. Complete the setup wizard as normal
    12. Do not open the Magisk stub (the default Android icon), install the Magisk 32-bit app from my repository.
    13. Open the Magisk app and finish setup for Magisk.
    Attempt to install and run a 32-bit application. If you are unable to, then verify that you used my Magisk 32-bit app to patch your init_boot.img and that you flashed it to your phone. You will have to perform the steps including the wipe over again.

    With my Magisk Delta 32-bit fork (Not Recommended For General Use, Advanced Users Only)

    Magisk Delta 32-bit with the rebased patch by me.​

    Direct download link for my Magisk Delta 32-bit APK


    Warning:

    Magisk Delta will mount the persist partition for it's early-mount feature, meaning that modules using early-mount could inadvertently fill up the partition, leading to possible corruption.​
    The steps will take you through creating a backup of the partition to restore if you ever need to.​

    Prerequisites:​

    You need to already have root with Magisk so you can backup the persist partition

    Steps:​

    Note: If you already have backed up your persist partition then you can skip steps 4 to 7.​
    1. Install my Magisk Delta 32-bit app, it may be installed alongside stock Magisk without issue as it has a different package name.
    2. Copy over the stock init_boot.img to your phone and patch it in the Magisk Delta 32-bit app.
    3. Copy it back over to your computer
    4. Enter a root shell via either method
      • adb
        • adb shell
        • su
          • You will need to approve the attempt on your phone
      • Terminal emulator
        • su
    5. Run the following command:
      • dd if=/dev/block/by-name/persist of=/sdcard/persist.img
    6. Copy persist.img over to your computer, keep it safe, keep it in multiple places.
      • This is not the Google Pixel 7 persist image, this is uniquely your phone's persist image.
    7. Reboot phone to bootloader
    8. Flash and wipe via fastboot --skip-reboot -w update image-xxx.zip
    9. Wait for it to finish, then reboot back into the bootloader either on the device or with fastboot reboot bootloader
    10. Flash the patched Magisk init_boot.img and boot into Android.
    11. Complete the setup wizard as normal
    12. Install my Magisk Delta 32-bit app.
    13. Open the Magisk app and finish setup for Magisk.
    Attempt to install and run a 32-bit application. If you are unable to, then verify that you used my Magisk Delta 32-bit app to patch your init_boot.img and that you flashed it to your phone. You will have to perform the steps including the wipe over again.


    System Upgrade Instructions​

    Either of my Magisk 32-bit forks

    1. Extract the init_boot from image-xxx.zip of the firmware you want to upgrade to
    2. Patch it in the Magisk app that you are using
    3. Copy the patched Magisk image back over to your computer
    4. Reboot your phone into fastboot
    5. Update the bootloader and radio if necessary
    6. fastboot --skip-reboot update image-xxx.zip
      • No -w! That flag will wipe your userdata partition.
    7. Wait until it is finished
      • Don't boot the phone into Android!
    8. Flash the patched Magisk init_boot.img
      • This can be done from inside fastbootd


    Magisk Upgrade Instructions​

    Either of my Magisk 32-bit forks

    1. Unhide the Magisk app if you are currently hiding it
    2. Download and install the latest APK for the 'flavor' you are using from my repository
      • It may be required that you uninstall the app if Android won't let you upgrade it
    3. Perform a direct install from the install menu
    4. Reboot

    Changing Between My Magisk Forks​

    1. Download and install the app you want to switch to from my repository
      • Uninstalling the previous Magisk app is not necessary
    2. Copy the stock init_boot.img for your system version over to your phone
    3. Patch it in the Magisk app you want to switch to
    4. Copy the patched Magisk image back over to your computer
    5. Reboot your phone into fastboot
    6. Flash the patched Magisk init_boot.img
      • If moving from Magisk Delta 32-bit to Magisk 32-bit then at the same time you can flash your backed up persist fastboot flash persist persist.img
    7. Remove the other Magisk app
    8. Finish setup in the remaining Magisk app.


    Uninstallation Instructions​

    My Magisk 32-bit fork

    Flash the stock init_boot.img

    My Magisk Delta 32-bit fork

    1. Flash the stock init_boot.img
    2. fastboot flash persist persist.img

    Manual method on phone if without original persist image​

    1. Uninstall all Magisk modules, they will clean up any files they put into early-mount.d
    2. Enter a root shell via either method
      • adb (heavily preferred)
        1. adb shell
        2. su
        3. You will need to approve the attempt on your phone
      • Terminal Emulator
    3. Navigate to the persist mount
      • cd $(magisk --path)/.magisk/mirror/persist/
    4. Remove the directory early-mount.d
      • rm -ir early-mount.d
        • You will be prompted for each removal and descending into directories, respond with y to approve the action
    5. Can now reboot and flash stock init_boot


    Troubleshooting​

    Stuck at boot animation or bootlooping​

    Restore stock init_boot.​
    Grab a logcat with adb to determine what the problem may be.​
    You might not have wiped your device.​

    Booted after installing new Android update but forgot to flash Magisk​

    Usually there is a "carrier specific" firmware that can be downloaded each month. These are not truly "carrier specific", they can be ran just fine, download whatever is available for the monthly update you are running.​
    Follow the system update instructions using the new firmware you downloaded.​
    After performing the steps and booting you can then repeat the steps but this time use the firmware you originally wanted to run.​

    Unable to install 32-bit apps​

    Run getprop ro.zygote; getprop ro.vendor.product.cpu.abilist; getprop ro.vendor.product.cpu.abilist32
    If the values do not match these then the modification was not applied.​
    zygote64_32
    arm64-v8a,armeabi-v7a,armeabi
    armeabi-v7a,armeabi

    32-bit apps force close​

    This only happened in my testing when I did a first boot with Zygote64 and then installed the modification to use Zygote64_32. Wipe your device.​
    It is possible the app may just have issues, or will not work because of missing libraries.​

    Clobbered the persist partition​

    Follow the uninstall steps for Magisk Delta, easiest to use the fastboot steps.​
    If you didn't backup your persist partition, then RIP.​


    Questions​

    Will I have to wipe on every system update?​

    I'm glad to say no.​
    I've tested with my Magisk Delta 32-bit, going from October -> November, while keeping Zygisk/MagiskHide enabled along with the Magisk app being hidden.​
    I also tested December -> January with my Magisk 32-bit and even swapping to my Magisk Delta 32-bit in the process without issue.​

    Can I take OTAs instead of flashing factory images?​

    I would heavily recommend against doing so.​

    I booted with the patch, but then accidentally flashed over init_boot, what do I do?​

    Simply just flash the patched Magisk image back over. I've tested it, 32-bit applications are still kept, and I haven't encountered any issues once I flashed the patched Magisk image back onto it.​
    If this was because of an update then try the troubleshooting method above.that uses a different build of the update.​

    Will my persist partition be destroyed?​

    You shouldn't have to worry about that, a backup persist image will be able to completely restore it.​


    Thanks To​

    Thomas King for Pixel 7 32-bit Helper
    @huskydg for Magisk Delta and letting me know about the Zygisk implementation maru
    5ec1cff for maru
    @nickelnine for bringing attention to Pixel 7 32-bit Helper​
    4
    Dumb questions:
    - Does this support Pixel 7 Pro?
    Well the thread is in the Pixel 7 Pro forum, the post is completely full of direct references to the Pixel 7 Pro, the intro video was recorded on a Pixel 7 Pro, and the download page makes reference to that it enables 32-bit support on the Pixel 7. So I'd say yes. :)
    - Does this required to wipe after flashing patched init_boot.img with custom Magisk, I have rooted phone with default Magisk now?
    You do need to wipe the phone after flashing the custom Magisk image, just use fastboot -w as-is.
    You can try without a wipe but the majority of the time it will just bootloop. You will have to either flash back to the stock or your previous init_boot if you don't want to wipe your data or use the above fastboot command to continue with using the custom Magisk.
    - Are we able to enable Zygisk after flashing patched init_boot.img?
    If you need Zygisk, which you will need for Universal SafetyNet Fix, then yes.



    Some short news on the custom Magisk Delta fork.​

    Upstream Magisk Delta just removed maru, which isn't that great for us. :(

    For now my fork still works and will continue to have maru so we can continue to use Zygisk, however I do have a solution going forward:

    I'm just going to be creating a stock Magisk fork with the maru patches going forward.​

    This solves the issue of earlymount.d tainting the persist partition, however for the people that do use that feature I'm sorry but you are going to have to limited support. For now the custom Magisk Delta fork can still be used until it no longer works or Magisk gets a large enough update to necessitate moving. Keeping up with rebasing the maru patches onto Magisk Delta is going to get more difficult as time moves on, so it will just be easier to just use stock Magisk with the maru patches and my patch.

    This does mean that stock Magisk Delta will pose issues with Zygisk as it doesn't have maru, so I can't recommend using it going forward.

    My time frame for getting the new custom Magisk fork out will be sometime next week or the week after. Right now there isn't any pressing matters to get it out the door quickly as everything is still fine, but it's something I'm going to have to do sooner rather than later.
    3
    FYI - Corvus OS for Pixel 7's does have 32bit app support
    3
    Hello guys, it's me again. With the given steps I have successfully updated to January build!
    Screenshot_20230104-164101.png