Skip to content
This repository was archived by the owner on Nov 12, 2022. It is now read-only.

Commit c5a3b61

Browse files
author
bors-servo
authored
Auto merge of #288 - fitzgen:allow-custom-bindgen-path, r=Ms2ger
Allow a custom path to bindgen in etc/bindings.sh <!-- Reviewable:start --> This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/rust-mozjs/288) <!-- Reviewable:end -->
2 parents daffcfb + ce7cee8 commit c5a3b61

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

etc/bindings.sh

100644100755
Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,15 @@ if [[ "$1" == "msvc14" ]] ; then
1010
EXTRA_FLAGS="$EXTRA_FLAGS -fvisibility=hidden"
1111
fi
1212

13-
../../rust-bindgen/target/debug/bindgen \
13+
: ${BINDGEN:=../../rust-bindgen/target/debug/bindgen}
14+
15+
if [[ ! -x "$BINDGEN" ]]; then
16+
echo "error: BINDGEN does not exist or isn't executable!"
17+
echo "error: with BINDGEN=$BINDGEN"
18+
exit 1
19+
fi
20+
21+
$BINDGEN \
1422
${EXTRA_FLAGS} \
1523
-no-class-constants \
1624
-no-type-renaming \

0 commit comments

Comments
 (0)