Skip to content

Commit 09abb04

Browse files
committed
Simplify low-memory build instructions.
1 parent 2697073 commit 09abb04

File tree

2 files changed

+6
-12
lines changed

2 files changed

+6
-12
lines changed

README.md

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -68,15 +68,12 @@ cmake --build .
6868
```
6969

7070
To build `TDLib` on low memory devices you can run [SplitSource.php](https://github.com/tdlib/td/blob/master/SplitSource.php) script
71-
before compiling main `TDLib` source code and compile only needed targets:
71+
before compiling `TDLib` source code and compile only needed targets:
7272
```
73+
php SplitSource.php
7374
mkdir build
7475
cd build
7576
cmake -DCMAKE_BUILD_TYPE=Release ..
76-
cmake --build . --target prepare_cross_compiling
77-
cd ..
78-
php SplitSource.php
79-
cd build
8077
cmake --build . --target tdjson
8178
cmake --build . --target tdjson_static
8279
cd ..

build.html

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -994,6 +994,10 @@
994994
}
995995
commands.push('cd ../..');
996996
} else {
997+
if (low_memory) {
998+
commands.push(php + ' SplitSource.php');
999+
}
1000+
9971001
commands.push(use_powershell ? 'Remove-Item build -Force -Recurse -ErrorAction SilentlyContinue' : 'rm -rf build');
9981002
commands.push('mkdir build');
9991003
commands.push('cd build');
@@ -1041,13 +1045,6 @@
10411045
}
10421046
commands.push(getCmakeInitCommand(cmake_init_options));
10431047

1044-
if (low_memory) {
1045-
commands.push(cmake + ' --build . --target prepare_cross_compiling');
1046-
commands.push('cd ..');
1047-
commands.push(php + ' SplitSource.php');
1048-
commands.push('cd build');
1049-
}
1050-
10511048
let build_command = cmake + ' --build .';
10521049
if (install_dir) {
10531050
build_command += ' --target install';

0 commit comments

Comments
 (0)