forked from kiss-community/repo
39 lines
948 B
Bash
Executable File
39 lines
948 B
Bash
Executable File
#!/bin/sh -e
|
|
|
|
# Fix build when libatomic.so does not exist in the system.
|
|
# This may be provided by compiler-rt which requires no additional
|
|
# linker flags to be used.
|
|
[ -r "$KISS_ROOT/usr/lib/libatomic.so" ] || {
|
|
sed 's/-latomic//' node.gyp > _
|
|
mv -f _ node.gyp
|
|
}
|
|
|
|
# Attempt to increase file descriptor limit
|
|
# as build may exhaust default (1024).
|
|
#
|
|
# -n is non-POSIX hence we "attempt".
|
|
# shellcheck disable=2039
|
|
ulimit -n 4096 2>/dev/null || :
|
|
|
|
./configure \
|
|
--shared-zlib \
|
|
--shared-openssl \
|
|
--with-intl=none \
|
|
--without-etw \
|
|
--without-dtrace \
|
|
--without-report \
|
|
--without-node-snapshot \
|
|
--without-node-code-cache \
|
|
--ninja
|
|
|
|
ninja -C out/Release
|
|
tools/install.py install "$1" /usr
|
|
|
|
# Remove unneeded files.
|
|
rm -rf \
|
|
"$1/usr/include/node/openssl" \
|
|
"$1/usr/share/doc" \
|
|
"$1/usr/share/systemtap" \
|
|
"$1/usr/lib/node_modules/npm/scripts" \
|
|
"$1/usr/lib/node_modules/npm/configure"
|