LSPosed / MagiskOnWSALocal

Integrate Magisk root and Google Apps into WSA (Windows Subsystem for Android)
GNU Affero General Public License v3.0
9.63k stars 23.18k forks source link

[Bug] unrecognized option `--remove-amazon` and `--gapps-brand` #773

Closed eladavron closed 8 months ago

eladavron commented 9 months ago

Steps to reproduce/复现步骤

  1. Run scripts/run.sh
  2. Select No to root and to keep amazon
  3. Try to build

Expected behaviour/预期行为

It should start building

Actual behaviour/实际行为

Shows the error:

COMMAND_LINE=--arch x64 --release-type retail --root-sol none --gapps-brand MindTheGapps --remove-amazon --compress --compress-format zip
build.sh: unrecognized option '--gapps-brand'
build.sh: unrecognized option '--remove-amazon'
ERROR: Failed to parse options, please check your input

Usage:
    --arch              Architecture of WSA.

                        Possible values: x64, arm64
                        Default: x64

    --release-type      Release type of WSA.
                        RP means Release Preview, WIS means Insider Slow, WIF means Insider Fast.

                        Possible values: retail, RP, WIS, WIF
                        Default: retail

    --magisk-ver        Magisk version.

                        Possible values: stable, beta, canary, debug, release
                        Default: stable

    --root-sol          Root solution.
                        "none" means no root.

                        Possible values: magisk, kernelsu, none
                        Default: magisk

    --compress-format   Compress format of output file.

                        Possible values: 7z, zip, none
                        Default: none

Additional Options:
    --offline           Build WSA offline
    --magisk-custom     Install custom Magisk
    --skip-download-wsa Skip download WSA
    --help              Show this help message and exit

Example:
    ./build.sh --release-type RP --magisk-ver beta
    ./build.sh --arch arm64 --release-type WIF
    ./build.sh --release-type WIS
    ./build.sh --offline --magisk-custom
    ./build.sh --release-type WIF --magisk-custom --magisk-ver releas

MagiskOnWSALocal commit full SHA/MagiskOnWSALocal 提交的完整哈希

44df7ca8ac4a755d05abe11ba44d621414b2a537

Linux distribution info/Linux 发行版信息

Ubuntu 22.04.4 on WSL2

Windows version/Windows 版本

10.0.22631.3155

Build Parameters/构建参数

COMMAND_LINE=--arch x64 --release-type retail --root-sol none --gapps-brand MindTheGapps --remove-amazon --compress --compress-format zip

Version requirement/版本要求

Logs/日志

[//]: <> (Don't modify above) ``` COMMAND_LINE=--arch x64 --release-type retail --root-sol none --gapps-brand MindTheGapps --remove-amazon --compress --compress-format zip build.sh: unrecognized option '--gapps-brand' build.sh: unrecognized option '--remove-amazon' ERROR: Failed to parse options, please check your input Usage: --arch Architecture of WSA. Possible values: x64, arm64 Default: x64 --release-type Release type of WSA. RP means Release Preview, WIS means Insider Slow, WIF means Insider Fast. Possible values: retail, RP, WIS, WIF Default: retail --magisk-ver Magisk version. Possible values: stable, beta, canary, debug, release Default: stable --root-sol Root solution. "none" means no root. Possible values: magisk, kernelsu, none Default: magisk --compress-format Compress format of output file. Possible values: 7z, zip, none Default: none Additional Options: --offline Build WSA offline --magisk-custom Install custom Magisk --skip-download-wsa Skip download WSA --help Show this help message and exit Example: ./build.sh --release-type RP --magisk-ver beta ./build.sh --arch arm64 --release-type WIF ./build.sh --release-type WIS ./build.sh --offline --magisk-custom ./build.sh --release-type WIF --magisk-custom --magisk-ver releas ``` [//]: <> (Don't modify below)
NolPixel commented 9 months ago

image

same here...

tolgamorf commented 9 months ago

same here trying to run it on Ubuntu 22.04.6 / WSL2

RFO1955 commented 9 months ago

Hello I have same problem :unrecognized option --gapps-brand and tested with any unbutu distro

cytoph commented 9 months ago

Same problem here

nonbot-bot commented 9 months ago

Same

NolPixel commented 9 months ago

Hey guys, if you are facing same problem. Click here for mirror download the WSA.

Anivie commented 9 months ago

problem still exists

trimeta commented 9 months ago

FYI, if your only contribution to this thread is "I'm experiencing this problem too," you can just subscribe for notifications. No need to make a comment.

MxBhn commented 8 months ago

Hey guys, if you are facing same problem. Click here for mirror download the WSA.

Hey Anivie not an expert at linux or such but wdym mirror download? At first i thought we just put it in the Linux user Directory but yeah thats stupid to assume only thing in the .7zip file is a run.bat file do i run that? Sorry for being dumb lmaoo

NolPixel commented 8 months ago

Hey guys, if you are facing same problem. Click here for mirror download the WSA.

Hey Anivie not an expert at linux or such but wdym mirror download? At first i thought we just put it in the Linux user Directory but yeah thats stupid to assume only thing in the .7zip file is a run.bat file do i run that? Sorry for being dumb lmaoo

Well I assume this repository is to bake our custom WSA then about mirror download is completely baking so we are not dealing with this issue just download the archive and run the script as usual. Mirror download just alternative for everyone who want to install WSA.

trimeta commented 8 months ago

Hey guys, if you are facing same problem. Click here for mirror download the WSA.

Hey Anivie not an expert at linux or such but wdym mirror download? At first i thought we just put it in the Linux user Directory but yeah thats stupid to assume only thing in the .7zip file is a run.bat file do i run that? Sorry for being dumb lmaoo

Well I assume this repository is to bake our custom WSA then about mirror download is completely baking so we are not dealing with this issue just download the archive and run the script as usual. Mirror download just alternative for everyone who want to install WSA.

If users want an alternative project that isn't broken, they'd be much better served by using a fork of this project which is in a working state (for example, https://github.com/sn-o-w/MagiskOnWSALocal), rather than switching to an entirely unrelated project.

rajarshikhatua100 commented 8 months ago

same thing

adun commented 8 months ago

Modifying the script in file scripts/run.sh allows the script to complete and process with the scripts/build.sh file.

On line 159, change from

COMMAND_LINE=(--arch "$ARCH" --release-type "${RELEASE_TYPE_MAP[$RELEASE_TYPE]}" --root-sol "$ROOT_SOL" --gapps-brand "$GAPPS_BRAND")

to

COMMAND_LINE=(--arch "$ARCH" --release-type "${RELEASE_TYPE_MAP[$RELEASE_TYPE]}" --root-sol "$ROOT_SOL" --install-gapps)

However, I've encountered another issue in file scripts/generateGappsLink.py which is called from the scripts/build.sh. Getting the latest package release fails as the repository is nonexistent (line 39):

https://api.github.com/repos/LSPosed/WSA-Addon/releases/latest

Execution logs:

COMMAND_LINE=--arch x64 --release-type retail --root-sol none --install-gapps
INFO: Architecture: x64
INFO: Release Type: retail
INFO: Magisk Version: stable
INFO: Root Solution: none
INFO: Compress Format: none
INFO: Release Name: Retail

Generating WSA Download Links
Generating WSA download link: arch=x64 release_type=Retail

WSA Build Version=2311.40000.5.0

download link: http://tlu.dl.delivery.mp.microsoft.com/filestreamingservice/files/c452d4ef-2486-4efe-9c99-36b3d23e0160?P1=1709394172&P2=404&P3=2&P4=bNMd3pddCQSxS13z75Eswsl%2biWN1%2bNEAKl3KWICDiRsSNer8Z4Rn9lXHVLAGLIR4yQeiCTrbwZWLxtEXLZ2NtQ%3d%3d
path: ../download/Microsoft.VCLibs.140.00_x64.appx

download link: http://tlu.dl.delivery.mp.microsoft.com/filestreamingservice/files/3695a927-e7a8-4d4e-9115-d750aee8faac?P1=1709394269&P2=404&P3=2&P4=OoqMxCVqjKrPnYbcnMWDerfo86zE7pQ3zN7ivNnYB0KSC8RcvquuSXPW8mOMTRRoReQEIl%2fn60yi3qrTPDh2Mw%3d%3d
path: ../download/Microsoft.VCLibs.140.00.UWPDesktop_x64.appx

download link: http://tlu.dl.delivery.mp.microsoft.com/filestreamingservice/files/251bbb12-dbfc-4820-b0ff-c4dfa70ffb09?P1=1709394261&P2=404&P3=2&P4=fwIRx1WQii155mqPbUQXSSwdhOJn2wc%2f4S34z8c5tOp8llqiIPvMetiq91zmIuZuBLluFdCjC%2fRmm1LU0ccovw%3d%3d
path: ../download/Microsoft.UI.Xaml.2.8_x64.appx

download link: http://tlu.dl.delivery.mp.microsoft.com/filestreamingservice/files/9f21fa47-fe2c-4f89-804e-e2b697f0bb14?P1=1709422239&P2=404&P3=2&P4=VmlqGTWJA0VYIMsqzp62lEQCjWddnmFTKfcACkdKvAz0m7dxkz4wb3U4zb9svD1xpfRJFsmIo4zzAUUlLB4MOA%3d%3d
path: ../download/wsa-retail.zip

Downloading WSA

03/02 16:32:59 [NOTICE] Downloading 4 item(s)

03/02 16:32:59 [NOTICE] GID#47ffe104ce1fdef9 - Download has already completed: ../download/Microsoft.UI.Xaml.2.8_x64.appx

03/02 16:32:59 [NOTICE] GID#9530ca1330f85ec4 - Download has already completed: ../download/wsa-retail.zip

03/02 16:32:59 [NOTICE] Download complete: ../download/Microsoft.UI.Xaml.2.8_x64.appx

03/02 16:32:59 [NOTICE] Download complete: ../download/wsa-retail.zip

03/02 16:32:59 [NOTICE] Download complete: ../download/Microsoft.VCLibs.140.00_x64.appx

03/02 16:32:59 [NOTICE] Download complete: ../download/Microsoft.VCLibs.140.00.UWPDesktop_x64.appx

Download Results:
gid   |stat|avg speed  |path/URI
======+====+===========+=======================================================
47ffe1|OK  |       0B/s|../download/Microsoft.UI.Xaml.2.8_x64.appx
9530ca|OK  |       0B/s|../download/wsa-retail.zip
f84ae2|OK  |   350KiB/s|../download/Microsoft.VCLibs.140.00_x64.appx
3ced74|OK  |   424KiB/s|../download/Microsoft.VCLibs.140.00.UWPDesktop_x64.appx

Status Legend:
(OK):download completed.
Extracting WSA
unzipping WsaPackage_2311.40000.5.0_x64_Release-Nightly.msix to /tmp/wsa-build-jOktUzCmeE_/wsa
unzipping from /tmp/wsa-build-jOktUzCmeE_/wsa/WsaPackage_2311.40000.5.0_x64_Release-Nightly.msix
done

Generating Download Links
Generating Magisk download link: release type=stable
download link: https://cdn.jsdelivr.net/gh/topjohnwu/magisk-files@27.0/app-release.apk
Generating GApps download link: arch=x64
Traceback (most recent call last):
  File "/home/adun/MagiskOnWSALocal/scripts/generateGappsLink.py", line 57, in <module>
    print(f"download link: {link}", flush=True)
NameError: name 'link' is not defined
Build: an error has occurred, exit

Cleanup Work Directory
Cleanup Download Directory
ForestSeo commented 8 months ago

I used this fork https://github.com/WSABuilds/MagiskOnWSALocal and successfully installed it.