mirror of
https://github.com/nix-community/naersk
synced 2024-11-10 06:04:17 +00:00
readme: Add a section on CMake usage
This commit is contained in:
parent
ad0240bbc9
commit
711ebec4c2
2 changed files with 50 additions and 0 deletions
25
README.md
25
README.md
|
@ -287,6 +287,31 @@ naersk.buildPackage {
|
|||
}
|
||||
```
|
||||
|
||||
### Using CMake
|
||||
|
||||
If your application uses CMake, the build process might fail, saying:
|
||||
|
||||
```
|
||||
CMake Error: The current CMakeCache.txt directory ... is different than the directory ... where CMakeCache.txt was created.
|
||||
```
|
||||
|
||||
You can fix this problem by removing stale `CMakeCache.txt` files before the
|
||||
build:
|
||||
|
||||
``` nix
|
||||
naersk.buildPackage {
|
||||
# ...
|
||||
|
||||
preBuild = ''
|
||||
find \
|
||||
-name CMakeCache.txt \
|
||||
-exec rm {} \;
|
||||
'';
|
||||
}
|
||||
```
|
||||
|
||||
([context](https://github.com/nix-community/naersk/pull/288))
|
||||
|
||||
### Using OpenSSL
|
||||
|
||||
If your application uses OpenSSL (making the build process fail), try:
|
||||
|
|
|
@ -249,6 +249,31 @@ naersk.buildPackage {
|
|||
}
|
||||
```
|
||||
|
||||
### Using CMake
|
||||
|
||||
If your application uses CMake, the build process might fail, saying:
|
||||
|
||||
```
|
||||
CMake Error: The current CMakeCache.txt directory ... is different than the directory ... where CMakeCache.txt was created.
|
||||
```
|
||||
|
||||
You can fix this problem by removing stale `CMakeCache.txt` files before the
|
||||
build:
|
||||
|
||||
``` nix
|
||||
naersk.buildPackage {
|
||||
# ...
|
||||
|
||||
preBuild = ''
|
||||
find \
|
||||
-name CMakeCache.txt \
|
||||
-exec rm {} \;
|
||||
'';
|
||||
}
|
||||
```
|
||||
|
||||
([context](https://github.com/nix-community/naersk/pull/288))
|
||||
|
||||
### Using OpenSSL
|
||||
|
||||
If your application uses OpenSSL (making the build process fail), try:
|
||||
|
|
Loading…
Reference in a new issue