Skip to content

Commit

Permalink
deal with opensuse cbindgen
Browse files Browse the repository at this point in the history
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
  • Loading branch information
fabbione committed Jun 17, 2021
1 parent cc804ca commit 483dbac
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -55,3 +55,4 @@ cov*
*libknet/bindings/rust/src/sys/libknet.rs
*libnozzle/bindings/rust/src/sys/libnozzle.rs
*build.rs
build-aux/rust-regen.sh
2 changes: 1 addition & 1 deletion build-aux/rust-regen.sh → build-aux/rust-regen.sh.in
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ srcheader="$1"
dstrs="$2"
filter="$3"

bindgen \
@BINDGEN@ \
--size_t-is-usize \
--no-recursive-whitelist \
--no-prepend-enum-name \
Expand Down
4 changes: 3 additions & 1 deletion configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,7 @@ if test "x$enable_rust_bindings" = "xyes"; then
AC_MSG_ERROR(["rustc command not found"])
fi

AC_PATH_PROG([BINDGEN], [bindgen], [no])
AC_CHECK_PROGS([BINDGEN], [bindgen cbindgen], [no])
if test "x$BINDGEN" = xno; then
AC_MSG_ERROR(["bindgen command not found"])
fi
Expand Down Expand Up @@ -430,6 +430,8 @@ AS_IF([test -n "$SOURCE_EPOCH"],
])
AC_MSG_NOTICE([using source epoch $($UTC_DATE_AT$SOURCE_EPOCH +'%F %T %Z')])

AC_CONFIG_FILES([build-aux/rust-regen.sh], [chmod +x build-aux/rust-regen.sh])

AC_CONFIG_FILES([
Makefile
libnozzle/Makefile
Expand Down

0 comments on commit 483dbac

Please sign in to comment.