-
-
Notifications
You must be signed in to change notification settings - Fork 294
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
Build Rnote and Installer for Windows Arm64 #1211
Closed
Closed
Changes from 10 commits
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
d4413c5
Update meson_options.txt
OB0NE 276d443
Update rnote_inno.iss.in
OB0NE 3261db0
Update cargo_build.py
OB0NE cadf4d0
Update meson.build
OB0NE d690238
Update cargo_build.py
OB0NE 7b772e2
Create rnote-windows-arm64-build.md
OB0NE baa1dfb
Update meson_options.txt
OB0NE 8e4a1fc
Update meson.build
OB0NE 6c30b5b
Update rnote-windows-arm64-build.md
OB0NE bf3e1e0
replacing the user part with <user> in paths
OB0NE a9bb491
Merge branch 'flxzt:main' into main
OB0NE f45fd78
move logic back into the meson build file
Doublonmousse 2684850
Merge branch 'flxzt:main' into main
OB0NE File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,96 @@ | ||
# Build Instructions for Windows arm64 | ||
|
||
## Prerequisites | ||
### Clone the repository | ||
|
||
```bash | ||
git clone https://github.com/flxzt/rnote | ||
git submodule update --init --recursive | ||
``` | ||
|
||
### Install MSYS2 | ||
- Install MSYS2 (using CLANGARM64 environment) | ||
- Update MSYS2: | ||
```Bash | ||
pacman -Suy | ||
``` | ||
- Add MSYS2 binary directories `C:\msys64\clangarm64\bin` and `C:\msys64\usr\bin` to the system environment variable Path. | ||
|
||
### (Optional) Install Inno Setup (for building the installer) | ||
|
||
### Install Dependencies | ||
Run the following command in the MSYS2 CLANGARM64 terminal to install necessary dependencies: | ||
|
||
```bash | ||
pacman -S mingw-w64-clang-aarch64-xz mingw-w64-clang-aarch64-pkgconf mingw-w64-clang-aarch64-clang \ | ||
mingw-w64-clang-aarch64-toolchain mingw-w64-clang-aarch64-autotools mingw-w64-clang-aarch64-make mingw-w64-clang-aarch64-cmake \ | ||
mingw-w64-clang-aarch64-meson mingw-w64-clang-aarch64-desktop-file-utils mingw-w64-clang-aarch64-appstream \ | ||
mingw-w64-clang-aarch64-gtk4 mingw-w64-clang-aarch64-libadwaita mingw-w64-clang-aarch64-poppler mingw-w64-clang-aarch64-poppler-data \ | ||
mingw-w64-clang-aarch64-angleproject | ||
``` | ||
All the above packages are clang-aarch64 versions corresponding to x86_64 versions. | ||
The mingw-w64-x86_64-diffutils package doesn't have a corresponding clang-aarch64 version, so install mingw-w64-x86_64-diffutils directly: | ||
|
||
```bash | ||
pacman -S mingw-w64-x86_64-diffutils | ||
``` | ||
|
||
### Install Rust | ||
Install Rust provided by MSYS2 (important) | ||
```bash | ||
pacman -S mingw-w64-clang-aarch64-rust | ||
``` | ||
|
||
### Configuration | ||
|
||
Add the following line to the end of the `C:\msys64\home\<user>\.bashrc` file to add the Rust binary directory to MSYS2's `PATH`: | ||
|
||
``` | ||
export PATH=$PATH:/c/msys64/clangarm64/bin | ||
``` | ||
If you have installed Inno Setup, add the following line to the end of the `C:\msys64\home\<user>\.bashrc` file: | ||
|
||
``` | ||
export PATH=$PATH:/c/msys64/clangarm64/bin:/c/Program\ Files\ \(x86\)/Inno\ Setup\ 6 | ||
``` | ||
Apply the configuration: | ||
|
||
```bash | ||
source ~/.bashrc | ||
``` | ||
|
||
# Compile Rnote | ||
|
||
1. First, make sure you're in the correct directory: | ||
```bash | ||
cd /c/rnote | ||
``` | ||
|
||
2. Clean previous build files: | ||
```bash | ||
rm -rf _mesonbuild | ||
``` | ||
|
||
3. Reconfigure the project: | ||
```bash | ||
meson setup --prefix="C:/msys64/clangarm64" -Dwin-installer-name='windows_arm64_installer' -Dwin-build-environment-path='C:\\msys64\\clangarm64' _mesonbuild | ||
``` | ||
|
||
4. Compile the project: | ||
```bash | ||
meson compile -C _mesonbuild | ||
``` | ||
|
||
5. Install the project: | ||
```bash | ||
meson install -C _mesonbuild | ||
``` | ||
# Build the installer | ||
|
||
```bash | ||
meson compile rnote-gmo -C _mesonbuild | ||
``` | ||
|
||
```bash | ||
meson compile build-installer -C _mesonbuild | ||
``` |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would prefer that this logic is in the meson build file, not in this script.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the feedback about moving the logic to the meson build file. I want to be transparent - I've been using AI to help me adjust the code as I have very limited knowledge about Rust and the app building process. This approach has proven to be quite inefficient, and despite multiple attempts, I haven't been able to successfully move the logic to the meson build file.
Rather than continue with AI-assisted code adjustments that might not meet the project's standards, I think I can be more helpful by offering to test any changes you implement on my ARM64 device (Surface Pro 11). This would ensure the changes work correctly on ARM64 Windows hardware, which might be valuable for the project.
So, please feel free to change what I have adjusted and let me know if you'd like me to test any changes you make, and I'll be happy to provide detailed feedback about how it works on ARM64.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've pushed a few changes.
I think this does what's intended, by moving the logic back into the meson file (and using an extra argument in the
cargo_build.py
file).Feel free to check whether this builds or not on your side, though beware of #1228 (that should get fixed at some point)