Upload generate-derived-sources.sh Script

This commit is contained in:
Thomas A 2023-03-16 07:45:37 -07:00
parent f1fbbd06ad
commit c2ff328e96

View File

@ -0,0 +1,26 @@
#!/bin/sh
# Based on Scripts/generate-derived-sources.sh
set -e
ARGS=("$@")
export SRCROOT=$(cd ../.. && pwd)
export BUILT_PRODUCTS_DIR=$SRCROOT
mkdir -p "${BUILT_PRODUCTS_DIR}/DerivedSources/JavaScriptCore"
cd "${BUILT_PRODUCTS_DIR}/DerivedSources/JavaScriptCore"
if [[ -d JavaScriptCore ]]; then
rm -d JavaScriptCore
fi
/bin/ln -sf "${SRCROOT}" JavaScriptCore
export JavaScriptCore="JavaScriptCore"
if [ ! $CC ]; then
export CC="clang"
fi
make --no-builtin-rules -f "JavaScriptCore/DerivedSources.make" -j `grep -c ^processor /proc/cpuinfo` "${ARGS[@]}"