mirror of
https://github.com/monero-project/monero.git
synced 2025-01-19 16:13:40 +02:00
brew: use latest protobuf
This commit is contained in:
parent
1179269478
commit
4cf19ec245
3
.github/workflows/build.yml
vendored
3
.github/workflows/build.yml
vendored
@ -44,8 +44,7 @@ jobs:
|
|||||||
restore-keys: ccache-${{ runner.os }}-build-
|
restore-keys: ccache-${{ runner.os }}-build-
|
||||||
- name: install dependencies
|
- name: install dependencies
|
||||||
run: |
|
run: |
|
||||||
HOMEBREW_NO_AUTO_UPDATE=1 brew install boost hidapi openssl zmq miniupnpc expat libunwind-headers protobuf@21 ccache
|
HOMEBREW_NO_AUTO_UPDATE=1 brew install boost hidapi openssl zmq miniupnpc expat libunwind-headers protobuf ccache
|
||||||
brew link protobuf@21 boost
|
|
||||||
- name: build
|
- name: build
|
||||||
run: |
|
run: |
|
||||||
${{env.CCACHE_SETTINGS}}
|
${{env.CCACHE_SETTINGS}}
|
||||||
|
@ -28,5 +28,5 @@ brew "doxygen"
|
|||||||
brew "graphviz"
|
brew "graphviz"
|
||||||
brew "libunwind-headers"
|
brew "libunwind-headers"
|
||||||
brew "xz"
|
brew "xz"
|
||||||
brew "protobuf@21", link: true
|
brew "protobuf"
|
||||||
brew "libusb"
|
brew "libusb"
|
||||||
|
@ -15,10 +15,9 @@ Please, refer to [monero readme](https://github.com/trezor/trezor-firmware/blob/
|
|||||||
|
|
||||||
## Dependencies
|
## Dependencies
|
||||||
|
|
||||||
Trezor uses [Protobuf](https://protobuf.dev/) library. Monero is now compiled with C++ 17 by default.
|
Trezor uses [Protobuf](https://protobuf.dev/) library.
|
||||||
Protobuf v21 is tested, older versions are not guaranteed to work. Note that Protobuf v23+ requires C++ 17.
|
|
||||||
|
|
||||||
If you are getting Trezor compilation errors, it may be caused by abseil (protobuf dependency) not being compiled with C++17.
|
Monero is now compiled with C++17 by default. If you are getting Trezor compilation errors, it may be caused by abseil (protobuf dependency) not being compiled with C++17.
|
||||||
To fix this try installing protobuf from sources:
|
To fix this try installing protobuf from sources:
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
@ -29,42 +28,22 @@ cmake --build .
|
|||||||
sudo make install
|
sudo make install
|
||||||
```
|
```
|
||||||
|
|
||||||
If Monero is compiled with C++14, Protobuf v21 is the latest compatible protobuf version for C++ 14.
|
### macOS
|
||||||
If you want to compile Monero with Trezor support with C++14, please make sure the Protobuf v21 is installed.
|
|
||||||
|
|
||||||
More about this limitation: [PR #8752](https://github.com/monero-project/monero/pull/8752),
|
|
||||||
[1](https://github.com/monero-project/monero/pull/8752#discussion_r1246174755), [2](https://github.com/monero-project/monero/pull/8752#discussion_r1246480393)
|
|
||||||
|
|
||||||
### OSX
|
|
||||||
|
|
||||||
To build with installed, but not linked Protobuf v21:
|
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
CMAKE_PREFIX_PATH=$(find /opt/homebrew/Cellar/protobuf@21 -maxdepth 1 -type d -name "21.*" -print -quit) \
|
|
||||||
make release
|
|
||||||
```
|
|
||||||
|
|
||||||
or to install and link as a default protobuf version:
|
|
||||||
```bash
|
|
||||||
# Either install all requirements as
|
|
||||||
brew update && brew bundle --file=contrib/brew/Brewfile
|
brew update && brew bundle --file=contrib/brew/Brewfile
|
||||||
|
|
||||||
# or install protobufv21 specifically
|
|
||||||
brew install protobuf@21 && brew link protobuf@21
|
|
||||||
```
|
```
|
||||||
|
|
||||||
### MSYS32
|
### MSYS32
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
curl -O https://repo.msys2.org/mingw/mingw64/mingw-w64-x86_64-protobuf-c-1.4.1-1-any.pkg.tar.zst
|
pacman -S mingw-w64-x86_64-protobuf
|
||||||
curl -O https://repo.msys2.org/mingw/mingw64/mingw-w64-x86_64-protobuf-21.9-1-any.pkg.tar.zst
|
|
||||||
pacman --noconfirm -U mingw-w64-x86_64-protobuf-c-1.4.1-1-any.pkg.tar.zst mingw-w64-x86_64-protobuf-21.9-1-any.pkg.tar.zst
|
|
||||||
```
|
```
|
||||||
|
|
||||||
### Other systems
|
### Other systems
|
||||||
|
|
||||||
- install Protobuf v21
|
- install Protobuf
|
||||||
- point `CMAKE_PREFIX_PATH` environment variable to Protobuf v21 installation.
|
- point `CMAKE_PREFIX_PATH` environment variable to Protobuf installation.
|
||||||
|
|
||||||
## Troubleshooting
|
## Troubleshooting
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user