Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

lineageos: allow prebuilt webview #268

Merged
merged 2 commits into from
Jan 6, 2025
Merged

Conversation

Atemu
Copy link
Contributor

@Atemu Atemu commented Dec 28, 2024

We don't have a working webview which would mean you'd need to install one
yourself at runtime. LOS ships a prebuilt webview, let's simply use that.

Fixes #246

@Atemu
Copy link
Contributor Author

Atemu commented Dec 28, 2024

Hm, this builds just fine for cheeseburger but it fails on the FP4:

FP4-ota_update> Running delta_generator with args: --out_file=/build/payload-o5d1vdvq.bin --partition_names=boot:dtbo:odm:product:recovery:system:system_ext:vbmeta:vbmeta_system:vendor --new_partitions=/build/boot.img.LqNVG6:/build/dtbo.img.27b1dQ:/build/odm.img.XlSDiy:/build/product.img.ioqUym:/build/recovery.img.kqH9tV:/build/system.img.mifyGQ:/build/system_ext.img.rlbm0m:/build/vbmeta.img.NN6n5G:/build/vbmeta_system.img.FBUnkf:/build/vendor.img.TYXGBy --new_mapfiles=::/build/odm.map.cprQZo:/build/product.map.NCcgcy::/build/system.map.2su3ni:/build/system_ext.map.I3H3mH:::/build/vendor.map.uSOZpE --major_version=2 --max_timestamp=1734679299 --partition_timestamps=boot:1734679299,odm:1734679299,product:1734679299,system:1734679299,system_ext:1734679299,vendor:1734679299 --new_postinstall_config_file=/build/postinstall_config.yL6LLQ --dynamic_partition_info_file=/build/dynamic_partitions_info.Lwm4MH --apex_info_file=/build/apex_info.1sxXF5
FP4-ota_update> [1228/164130.249254:ERROR:payload_generation_config.cc(236)] Sum of sizes in qti_dynamic_partitions_partition_list is 6665846784, which is greater than qti_dynamic_partitions_size (6438256640)
FP4-ota_update> [1228/164130.249268:FATAL:generate_delta_main.cc(659)] Check failed: payload_config.target.ValidateDynamicPartitionMetadata().
FP4-ota_update> /nix/store/x3n1y4449pz31r7xn0adpy5jmrksa7z6-ota-tools/bin/../lib64/libchrome.so(base::debug::StackTrace::StackTrace(unsigned long)+0x15) [0x7ffff7b6d645]
FP4-ota_update> /nix/store/x3n1y4449pz31r7xn0adpy5jmrksa7z6-ota-tools/bin/../lib64/libchrome.so(logging::LogMessage::~LogMessage()+0x97) [0x7ffff7af5af7]
FP4-ota_update> /nix/store/x3n1y4449pz31r7xn0adpy5jmrksa7z6-ota-tools/bin/delta_generator(+0xe4849) [0x555555638849]
FP4-ota_update> /nix/store/1zy01hjzwvvia6h9dq5xar88v77fgh9x-glibc-2.38-44/lib/libc.so.6(+0x27fce) [0x7ffff7656fce]
FP4-ota_update> /nix/store/1zy01hjzwvvia6h9dq5xar88v77fgh9x-glibc-2.38-44/lib/libc.so.6(__libc_start_main+0x89) [0x7ffff7657089]
FP4-ota_update> /nix/store/x3n1y4449pz31r7xn0adpy5jmrksa7z6-ota-tools/bin/delta_generator(+0xe0699) [0x555555634699]
FP4-ota_update> /nix/store/x3n1y4449pz31r7xn0adpy5jmrksa7z6-ota-tools/bin/brillo_update_payload: line 669:   485 Aborted                 (core dumped) LD_PRELOAD=${LD_PRELOAD}:${FLAGS_liblz4_path} "${GENERATOR}" "${GENERATOR_ARGS[@]}"

Is it becoming too large perhaps?

@Atemu
Copy link
Contributor Author

Atemu commented Dec 28, 2024

Yeah I think that's it :(

How is our image so large as to become too large for the device when you add a chromium?

@Atemu
Copy link
Contributor Author

Atemu commented Dec 28, 2024

When I tried applying it as an img, it succeeded until:

Resizing 'vendor_b'                                FAILED (remote: 'Not enough space to resize partition')

So it might be the contents of the vendor partition?

@Atemu
Copy link
Contributor Author

Atemu commented Dec 28, 2024

system and vendor are the same size as before but product has increased from 356MiB to 831MiB.

@Atemu
Copy link
Contributor Author

Atemu commented Dec 28, 2024

Found what's going wrong here: The APK exists twice. That's too much of course; one chromium is large enough as is.

We have to not use robotnix' webview handling at all for LOS' webview or stop LOS from installing theirs at the same time.

We don't have a working webview which would mean you'd need to install one
yourself at runtime. LOS ships a prebuilt webview, let's simply use that.

Fixes nix-community#246
This is required by LOS webview which is just plain chromium, so other modern
Chromiums probably need this too.
@Atemu
Copy link
Contributor Author

Atemu commented Jan 6, 2025

This works and is required for #271

@Atemu Atemu merged commit 4b3bfb3 into nix-community:master Jan 6, 2025
@Atemu Atemu deleted the webview branch January 6, 2025 16:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Provide a working webview again
1 participant