mirror of
https://github.com/rizinorg/rizin
synced 2026-08-22 20:26:16 -04:00
BUILDING.md improvements (#731)
* BUILDING.md - Add note about debugging and recommend build type * BUILDING.md - Add --buildtype=release in the code snippets * BUILDING.md - Add missing '=' for consistency with other snippets
This commit is contained in:
parent
7a4f9b3201
commit
7ce4721238
1 changed files with 10 additions and 6 deletions
16
BUILDING.md
16
BUILDING.md
|
|
@ -17,6 +17,10 @@ from `pip` with `pip install meson`. If necessary, also install `ninja` with
|
|||
If you are trying to build Rizin to create a package for a distribution,
|
||||
take a look at [doc/PACKAGERS.md][].
|
||||
|
||||
## Note about debugging
|
||||
|
||||
Unless you are interested in debugging Rizin, it is a good idea to pass the `--buildtype=release` flag to `meson` for increased performance and to prevent the buggy `mspdbsrv.exe` process from [blocking/breaking the building process](https://social.msdn.microsoft.com/Forums/en-US/9e58b7d1-a47d-4a76-943a-4f35090616e8/link-fatal-error-lnk1318?forum=vclanguage) when generating `PDB` files in Windows. See the first table in the [Running Meson Documentation](https://mesonbuild.com/Running-Meson.html#configuring-the-build-directory) for other build types.
|
||||
|
||||
## *NIX systems
|
||||
|
||||
### Build system-wide, in `/usr/local`
|
||||
|
|
@ -26,7 +30,7 @@ version while keeping, if provided, the Rizin version shipped by your
|
|||
distribution in `/usr`.
|
||||
|
||||
```
|
||||
$ meson build
|
||||
$ meson --buildtype=release build
|
||||
$ ninja -C build # or `meson compile -C build`
|
||||
$ sudo ninja -C build install # or `sudo meson install -C build`
|
||||
```
|
||||
|
|
@ -46,7 +50,7 @@ with all other binaries on your system, you can also install it system-wide in
|
|||
`/usr`.
|
||||
|
||||
```
|
||||
$ meson --prefix=/usr build
|
||||
$ meson --buildtype=release --prefix=/usr build
|
||||
$ ninja -C build
|
||||
$ sudo ninja -C build install
|
||||
```
|
||||
|
|
@ -63,7 +67,7 @@ available for your current user, without requiring you to have `sudo` access to
|
|||
the machine (or if you don't trust our build scripts enough).
|
||||
|
||||
```
|
||||
$ meson --prefix=~/.local build
|
||||
$ meson --buildtype=release --prefix=~/.local build
|
||||
$ ninja -C build
|
||||
$ ninja -C build install
|
||||
```
|
||||
|
|
@ -86,7 +90,7 @@ To install Meson on Windows, follow instructions
|
|||
[here](https://mesonbuild.com/Getting-meson.html).
|
||||
|
||||
```
|
||||
$ meson --prefix=%CD%\rizin-install build
|
||||
$ meson --buildtype=release --prefix=%CD%\rizin-install build
|
||||
$ ninja -C build
|
||||
$ ninja -C build install
|
||||
```
|
||||
|
|
@ -99,7 +103,7 @@ You can run rizin from `%CD%\rizin-install\bin`. If you don't specify any
|
|||
Use `-Db_sanitize=address,undefined` during the setup phase.
|
||||
|
||||
```
|
||||
$ meson -Db_sanitize=address,undefined build
|
||||
$ meson --buildtype=release -Db_sanitize=address,undefined build
|
||||
```
|
||||
|
||||
## Build fully-static binaries
|
||||
|
|
@ -109,7 +113,7 @@ copied on other systems if necessary. On *NIX systems, this adds the classic
|
|||
`-static` flag to the linker, while on Windows it uses `/MT`.
|
||||
|
||||
```
|
||||
$ meson --default-library=static -Dstatic_runtime=true build
|
||||
$ meson --buildtype=release --default-library=static -Dstatic_runtime=true build
|
||||
```
|
||||
|
||||
## Cross-compilation for Android
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue