Skip to content
This repository was archived by the owner on Sep 5, 2024. It is now read-only.

Commit a3fbd18

Browse files
committed
Optimize build-js.sh
1 parent f6a1011 commit a3fbd18

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

build-js.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
set -e -o pipefail
44

5+
NPROC=$(grep -c ^processor /proc/cpuinfo)
56
BUILD_DIR=$PWD/build
67

78
build_x264() {
@@ -10,7 +11,7 @@ build_x264() {
1011
--disable-asm \
1112
--disable-thread \
1213
--prefix=$BUILD_DIR
13-
emmake make install-lib-static
14+
emmake make install-lib-static -j${NPROC}
1415
cd -
1516
}
1617

@@ -39,7 +40,6 @@ configure_ffmpeg() {
3940
}
4041

4142
make_ffmpeg() {
42-
NPROC=$(grep -c ^processor /proc/cpuinfo)
4343
emmake make -j${NPROC}
4444
}
4545

0 commit comments

Comments
 (0)