Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fix 2304 build (#531)
Starting with WSA version 2304, the system image is now raw EROFS
wrapped with `vhdx`. In this case, the integration has moved to mount
EROFS and use the mounted directory as `lowerdir`, use OverlayFS to 
make it readable and writeable, and modify it in the merged directory.
  • Loading branch information
Howard20181 committed May 13, 2023
1 parent 285d43c commit cde01be
Show file tree
Hide file tree
Showing 5 changed files with 257 additions and 101 deletions.
25 changes: 25 additions & 0 deletions arm64/gapps/product/etc/sysconfig/component-overrides.xml
@@ -0,0 +1,25 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- This file is part of MagiskOnWSALocal.
MagiskOnWSALocal is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as
published by the Free Software Foundation, either version 3 of the
License, or (at your option) any later version.
MagiskOnWSALocal is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License
along with MagiskOnWSALocal. If not, see <https://www.gnu.org/licenses/>.
Copyright (C) 2023 LSPosed Contributors
-->
<config>
<component-override package="com.android.vending">
<component class="com.google.android.finsky.verifier.impl.PackageVerificationReceiver" enabled="false" />
<component class="com.google.android.finsky.verifier.impl.api.safetynet.PackageVerificationApiService" enabled="false" />
<component class="com.google.android.finsky.verifier.impl.PackageVerificationService" enabled="false" />
</component-override>
</config>

6 comments on commit cde01be

@sn-o-w
Copy link
Contributor

@sn-o-w sn-o-w commented on cde01be May 13, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Howard20181 I just tried to build 2304, but I get this:

Convert vhdx to RAW image
Convert vhdx to RAW image done

Mount images
mount: /tmp/wsa-build-ZBnsqfymSe_/erofs: unknown filesystem type 'erofs'.
Build: an error has occurred, exit

Not sure exactly what could be wrong. 🤔

@Howard20181
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Howard20181 I just tried to build 2304, but I get this:

Convert vhdx to RAW image
Convert vhdx to RAW image done

Mount images
mount: /tmp/wsa-build-ZBnsqfymSe_/erofs: unknown filesystem type 'erofs'.
Build: an error has occurred, exit

Not sure exactly what could be wrong. 🤔

What's your Linux kernel version? EROFS was first introduced in 4.19.

@sn-o-w
Copy link
Contributor

@sn-o-w sn-o-w commented on cde01be May 13, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's your Linux kernel version? EROFS was first introduced in 4.19.

5.15.

And yes, I also installed erofs-utils.

@Howard20181
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's your Linux kernel version? EROFS was first introduced in 4.19.

5.15.

And yes, I also installed erofs-utils.

What's the out put of cat /proc/filesystems?
Check if your kernel lacks erofs support.

@sn-o-w
Copy link
Contributor

@sn-o-w sn-o-w commented on cde01be May 13, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the out put of cat /proc/filesystems? Check if your kernel lacks erofs support.

nodev	sysfs
nodev	tmpfs
nodev	bdev
nodev	proc
nodev	cgroup
nodev	cgroup2
nodev	cpuset
nodev	devtmpfs
nodev	configfs
nodev	debugfs
nodev	tracefs
nodev	securityfs
nodev	sockfs
nodev	bpf
nodev	pipefs
nodev	ramfs
nodev	hugetlbfs
nodev	devpts
	ext3
	ext2
	ext4
	squashfs
	vfat
nodev	ecryptfs
	fuseblk
nodev	fuse
nodev	fusectl
nodev	mqueue
nodev	pstore
nodev	autofs
nodev	binfmt_misc
nodev	overlay

Hmmm... Any idea how can add erofs support?! 🤔

@sn-o-w
Copy link
Contributor

@sn-o-w sn-o-w commented on cde01be May 14, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Howard20181 Well, I managed to install linux-modules-extra-azure which seems to include the erofs filesystem I need. But now I get another weird error:

Convert vhdx to RAW image
Convert vhdx to RAW image done

Mount images
mount: /tmp/wsa-build-ZLpp2fLvKR_/erofs: wrong fs type, bad option, bad superblock on /dev/loop3, missing codepage or helper program, or other error.
Build: an error has occurred, exit

Cleanup Work Directory
Cleanup Mount Directory
umount: /tmp/wsa-build-ZLpp2fLvKR_/erofs: not mounted.

Any idea? 🤔

Please sign in to comment.