Files
monero_c/README.md

43 lines
1.9 KiB
Markdown
Raw Normal View History

2023-12-26 21:43:14 +01:00
# wallet2_api.h (but this time C compatible)
2023-12-27 22:04:19 +01:00
Wrapper around wallet2_api.h that can be called using C api.
## Contributing
To contribute you can visit git.mrcyjanek.net/mrcyjanek/monero_c and open a PR, alternatively use any other code mirror or send patches directly.
## Building (android)
Builds are provided in the [release tab](https://git.mrcyjanek.net/mrcyjanek/monero_c/releases), built using Gitea Runners. Building locally is possible as well, althought it is rather a heavy task which takes ~2 hours to finish (excluding enviroment setup and some downloads).
2024-01-05 14:36:33 +01:00
Base image for the runner is `git.mrcyjanek.net/mrcyjanek/androidndk:r17c`, which contains preinstalled NDK. `Dockerfile` can be obtained from [mrcyjanek/CIimages](https://git.mrcyjanek.net/mrcyjanek/CIimages/src/branch/master/Dockerfile.androidndk-r17c) repository.
2023-12-27 22:04:19 +01:00
Then to build `.github/workflows/*.yml` files are used.
Local build?
```bash
2024-01-05 14:36:33 +01:00
$ act --pull=false -Pandroidndk-r17c=git.mrcyjanek.net/mrcyjanek/androidndk:r17c
2023-12-27 22:04:19 +01:00
```
For development?
```bash
2024-01-05 14:36:33 +01:00
$ timeout 5 act --pull=false -Pandroidndk-r17c=git.mrcyjanek.net/mrcyjanek/androidndk:r17c # needed to clear cache.
$ act --pull=false -Pandroidndk-r17c=git.mrcyjanek.net/mrcyjanek/androidndk:r17c --reuse
2023-12-27 22:04:19 +01:00
$ docker ps
CONTAINER ID IMAGE .....................................
2024-01-05 14:36:33 +01:00
d0626dcd8c5d git.mrcyjanek.net/mrcyjanek/androidndk:r17c ....
2023-12-27 22:04:19 +01:00
$ docker commit d0626dcd8c5d monero_c:dev
$ docker run --rm -it \
-v $PWD/libbridge:/opt/wspace/libbridge_up \
--entrypoint /bin/bash \
monero_c:dev
2024-01-07 14:38:45 +01:00
[docker] $ export 'PATH=/usr/cmake-3.14.6-Linux-x86_64/bin:/opt/android/toolchain/aarch64-linux-android/bin:/opt/android/toolchain/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin' \
&& cd /opt/wspace/libbridge_up \
&& rm -rf build && mkdir build && cd build \
&& env CC=clang CXX=clang++ cmake -DANDROID_ABI=-arm64-v8a .. \
&& make
2023-12-27 22:04:19 +01:00
# Resulting file will be available in the current directory.
```