Commit graph

16 commits

Author SHA1 Message Date
Mukilan Thiyagarajan
88a35b3cc9
mach: adopt uv and avoid system python (#34632)
This allows us to use `uv` for:
1. Installing a pinned Python version
2. Installing the dependency packages using `uv`'s pip compatible interface.
4. Bootstrapping `mach` without a Python installion on the host, using `uv
   run`

This change also introduces a new 'composite' GitHub action to setup
python in the different CI workflows. There is no support for externally
managed python installations and virtual environments. These could be
added in the future.

Fixes #34095, #34547

Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com>
2024-12-16 09:20:37 +00:00
Jonathan Schwender
f757fa46ac
Bump bindgen to 0.71.1 (#34562)
* Bump bindgen to 0.71.1

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>

* Set SCCACHE_GHA_VERSION to allow purging cache

changing the version allows us to purge the cache.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>

* android CI: Enable sccache again

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2024-12-16 07:13:20 +00:00
Mukilan Thiyagarajan
2f64dde623
Revert "mach: switch to uv for managing python venv (#34504)" (#34548)
This reverts commit 4103421ba5.

Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com>
2024-12-10 03:43:50 +00:00
Mukilan Thiyagarajan
4103421ba5
mach: switch to uv for managing python venv (#34504)
This patch switches servo to use `uv` for both installing a pinned
Python version as well as installing the dependency packages using
`uv`'s pip compatible interface. It also introduces a new 'composite'
GitHub action to setup python in the different CI workflows.

There is no support for externally managed python installations and
virtual environments. These could be added in the future.

Fixes #34095

Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com>
2024-12-09 14:52:06 +00:00
Jonathan Schwender
096439b35e
ohos: Specify SDK version more accurately. (#34431)
SDK Version 5.0.1 was recently released and bumps the
API-version to 13.
This means hvigor will refuse to package the app, since
we currently specify that our app targets API 12.
Hence, we clarify our version by also specifying the patch level.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2024-11-29 21:19:02 +00:00
Jonathan Schwender
538ac61a82
ohos: Add basic IME and keyboard support (#34188)
* ohos: Add basic IME and keyboard support

- Add extremely basic support for keyboard events
- Add basic IME support
   - Showing and hiding the IME
   - inserting text
   - deleting characters
   - very basic configuration of the IME

Signed-off-by: Jonathan Schwender <jonathan.schwender@huawei.com>

* Apply suggestions from code review

Improve the log message

Co-authored-by: Josh Matthews <josh@joshmatthews.net>
Signed-off-by: Jonathan Schwender <55576758+jschwe@users.noreply.github.com>

* Update ports/servoshell/egl/ohos.rs

Co-authored-by: Mukilan Thiyagarajan <mukilanthiagarajan@gmail.com>
Signed-off-by: Jonathan Schwender <55576758+jschwe@users.noreply.github.com>

* ohos: Bump the minimum required SDK version to 5.0

Signed-off-by: Jonathan Schwender <jonathan.schwender@huawei.com>

* ohos: Remove pub from callbacks

The callbacks don't need to be public, as we will be registering them.

Signed-off-by: Jonathan Schwender <jonathan.schwender@huawei.com>

* Rename composition event

Signed-off-by: Jonathan Schwender <jonathan.schwender@huawei.com>

* ohos: clippy in log

Signed-off-by: Jonathan Schwender <jonathan.schwender@huawei.com>

* ohos: address some clippy warnings

Signed-off-by: Jonathan Schwender <jonathan.schwender@huawei.com>

* ohos: Raise Error in mach if unsupported SDK version is used.

Signed-off-by: Jonathan Schwender <jonathan.schwender@huawei.com>

* Add keyboard-types dependency for android

Signed-off-by: Jonathan Schwender <jonathan.schwender@huawei.com>

---------

Signed-off-by: Jonathan Schwender <jonathan.schwender@huawei.com>
Signed-off-by: Jonathan Schwender <55576758+jschwe@users.noreply.github.com>
Co-authored-by: Josh Matthews <josh@joshmatthews.net>
Co-authored-by: Mukilan Thiyagarajan <mukilanthiagarajan@gmail.com>
2024-11-15 15:04:48 +00:00
Jonathan Schwender
efaba0472a
CI: Bump setup-ohos-sdk to v0.1.4 (#33739)
* CI: Bump setup-ohos-sdk to v0.1.4

v0.1.3 had a bug when the SDK was restored from cache.
This was fixed upstream, andcache-hit behavior is now also
tested in upstream CI.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>

* CI: Use major tag again for setup-ohos-sdk

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2024-10-13 07:17:24 +00:00
Mukilan Thiyagarajan
febe7de0bf
ohos: publish nightly builds (#33801)
Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com>
2024-10-11 10:11:51 +00:00
Mukilan Thiyagarajan
946fa9cdee
ohos: pin version of setup-ohos-sdk action to fix CI (#33719)
The most recent [v0.1.3] release seems to not set the expected
OHOS_SDK_NATIVE and OHOS_BASE_SDK_HOME environment variables.

This is causing the OHOS builds to fail in CI and blocking the merge
queue. This change pins he action to the last known good version until
the error can be addressed upstream.

Fixes #33712.

Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com>
2024-10-08 06:16:02 +00:00
Jonathan Schwender
f96a62f0ce
Bump sccache-action to v0.0.6 (#33566)
Interesting changes since v0.0.4

- fix: avoid downloading package when local cache exists in https://github.com/Mozilla-Actions/sccache-action/pull/123
- Output sccache stats as a notice and a summary table in https://github.com/Mozilla-Actions/sccache-action/pull/113

v0.0.6 changelog: https://github.com/Mozilla-Actions/sccache-action/releases/tag/v0.0.6

v0.0.5 changelog: https://github.com/Mozilla-Actions/sccache-action/releases/tag/v0.0.5

Signed-off-by: Jonathan Schwender <jonathan.schwender@huawei.com>
2024-09-27 15:22:35 +00:00
Mukilan Thiyagarajan
157e28c59b
openharmony: add servoshell for ohos (#33295)
* openharmony: add servoshell for ohos

Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com>

* ohos: handle missing signing config on forks

Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com>

---------

Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com>
2024-09-20 08:20:27 +00:00
Samson
ebdae6094e
CI: Add separate Lint&Tidy check and remove test-tidy from linux (#33150)
* Create separate Lint&Tidy check

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>

* Remove quick-check as it's not longer relevant

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>

* Add clippy to rust-toolchain

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>

* fix try parser test expectations

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>

* use lint in result

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>

* Lint & Tidy -> Lint

Co-authored-by: Martin Robinson <mrobinson@igalia.com>
Signed-off-by: Samson <16504129+sagudev@users.noreply.github.com>

---------

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
Signed-off-by: Samson <16504129+sagudev@users.noreply.github.com>
Co-authored-by: Martin Robinson <mrobinson@igalia.com>
2024-08-23 08:58:12 +00:00
Jonathan Schwender
3aef023368
ohos: Fix x86_64-unknown-linux-ohos (#33029)
* ohos: Fix compilation for x86_64

Signed-off-by: Jonathan Schwender <jonathan.schwender@huawei.com>

* ohos: Use the SDK compiler-wrapper

When compiling for x86_64-unknown-linux-ohos without the compiler
wrapper, for some reason mozjs_sys will be refercing a wrong mangled symbol
resulting in the following error when loading the .so at runtime:

```
_ZNSt3__111this_thread9sleep_forERKNS_6chrono8durationIxNS_5ratioILl1ELl1000000000EEEEE: symbol not found
```

This problem does not occur when compiling for aarch64 or when using the compiler wrapper.
In this case the correct symbol
`_ZNSt4__n111this_thread9sleep_forERKNS_6chrono8durationIxNS_5ratioILl1ELl1000000000EEEEE`
is referenced.
It's unclear why manually passing the flags via CFLAGS / CXXFLAGS does not work.

Signed-off-by: Jonathan Schwender <jonathan.schwender@huawei.com>

---------

Signed-off-by: Jonathan Schwender <jonathan.schwender@huawei.com>
2024-08-14 01:30:04 +00:00
Mukilan Thiyagarajan
b243457ccc
ci: fix security issue in try job workflow (#32724)
This [issue][1] was reported by GitHub user @RedYetiDev via the Security
Advisory reporting mechanism on GitHub. The fix is also based on their
proposed solution.

The issue is that `refs/pull/{pr_number}/head` points to the latest
commit of a PR and so it could be different than the commit that was
reviewed when the try label was applied. The fix is to use the exact commit
sha at the point when the try job is triggered, which is available in
the `github` context as  `github.event.pull_request.head.sha`.

[1]: https://github.com/servo/servo/security/advisories/GHSA-fxqr-xgh8-3577

Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com>
Co-authored-by: Aviv Keller <38299977+RedYetiDev@users.noreply.github.com>
2024-07-08 10:08:23 +00:00
Jonathan Schwender
1d2949f2b3
CI: Cache cargo-deny (#32543)
Use the `cargo-install` action to cache the cargo-deny output.
`cargo-deny` is currently unconditionally installed during bootstrap,
and takes around 2 minutes to install, so caching should give a
significant speedup

Signed-off-by: Jonathan Schwender <jonathan.schwender@huawei.com>
2024-06-18 09:55:13 +00:00
Jonathan Schwender
3381f2a704
Add OpenHarmony support to mach and CI (#32507)
* Add ohos to mach

Signed-off-by: Jonathan Schwender <jonathan.schwender@huawei.com>

* Add OpenHarmony build to CI

* Rename ohos sdk action

I decided to rename the upstream ohos sdk action to
setup-ohos-sdk, making it clearer that is a github
action repository.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>

* Remove commented line

Signed-off-by: Jonathan Schwender <jonathan.schwender@huawei.com>

---------

Signed-off-by: Jonathan Schwender <jonathan.schwender@huawei.com>
Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2024-06-17 11:27:23 +00:00