diff options
author | Matt A. Tobin <mattatobin@localhost.localdomain> | 2018-02-02 04:16:08 -0500 |
---|---|---|
committer | Matt A. Tobin <mattatobin@localhost.localdomain> | 2018-02-02 04:16:08 -0500 |
commit | 5f8de423f190bbb79a62f804151bc24824fa32d8 (patch) | |
tree | 10027f336435511475e392454359edea8e25895d /security/nss/coreconf/nspr.sh | |
parent | 49ee0794b5d912db1f95dce6eb52d781dc210db5 (diff) | |
download | UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.gz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.lz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.xz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.zip |
Add m-esr52 at 52.6.0
Diffstat (limited to 'security/nss/coreconf/nspr.sh')
-rw-r--r-- | security/nss/coreconf/nspr.sh | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/security/nss/coreconf/nspr.sh b/security/nss/coreconf/nspr.sh new file mode 100644 index 000000000..ff5e38363 --- /dev/null +++ b/security/nss/coreconf/nspr.sh @@ -0,0 +1,48 @@ +#!/bin/bash +# This script builds NSPR for NSS. +# +# This build system is still under development. It does not yet support all +# the features or platforms that the regular NSPR build supports. + +# variables +nspr_opt=() +nspr_cflags= +nspr_cxxflags= +nspr_ldflags= + +nspr_sanitizer() +{ + nspr_cflags="$nspr_cflags $(python $cwd/coreconf/sanitizers.py $1 $2)" + nspr_cxxflags="$nspr_cxxflags $(python $cwd/coreconf/sanitizers.py $1 $2)" + nspr_ldflags="$nspr_ldflags $(python $cwd/coreconf/sanitizers.py $1 $2)" +} + +verbose() +{ + CFLAGS=$nspr_cflags CXXFLAGS=$nspr_cxxflags LDFLAGS=$nspr_ldflags \ + CC=$CC CXX=$CCC ../configure "${nspr_opt[@]}" --prefix="$obj_dir" + make -C "$cwd/../nspr/$target" + make -C "$cwd/../nspr/$target" install +} + +silent() +{ + echo "[1/3] configure NSPR ..." + CFLAGS=$nspr_cflags CXXFLAGS=$nspr_cxxflags LDFLAGS=$nspr_ldflags \ + CC=$CC CXX=$CCC ../configure "${nspr_opt[@]}" --prefix="$obj_dir" 1> /dev/null + echo "[2/3] make NSPR ..." + make -C "$cwd/../nspr/$target" 1> /dev/null + echo "[3/3] install NSPR ..." + make -C "$cwd/../nspr/$target" install 1> /dev/null +} + +build_nspr() +{ + mkdir -p "$cwd/../nspr/$target" + cd "$cwd/../nspr/$target" + if [ "$1" == 1 ]; then + verbose + else + silent + fi +} |