For OFED and ZFS builds the function $(find_linux_release) is used.
But it defined in $LBUILD_DIR/lbuild-$DISTRO that is not included
in case of build when kernel source tree was given on the command
line.
Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Change-Id: I5f7ae64f560c76e745dc7314465c7fa7d9ec275f
Reviewed-on: http://review.whamcloud.com/8421
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Minh Diep <minh.diep@intel.com>
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
+ [ -z "$TARGET" ] && TARGET=$(autodetect_target "$DISTRO")
+
if [ -z "$LINUX" ]; then
[ "$KERNELDIR" -o "$KERNELTREE" ] || \
usage 1 "A kernel directory must be specified with --kerneldir or --kerneltree."
if [ -z "$LINUX" ]; then
[ "$KERNELDIR" -o "$KERNELTREE" ] || \
usage 1 "A kernel directory must be specified with --kerneldir or --kerneltree."
[ -d "$KERNELDIR" -o -d "$KERNELTREE" ] || \
usage 1 "$KERNELDIR and $KERNELTREE are not a directory."
[ -d "$KERNELDIR" -o -d "$KERNELTREE" ] || \
usage 1 "$KERNELDIR and $KERNELTREE are not a directory."
- [ "$TARGET" ] || TARGET=$(autodetect_target "$DISTRO")
# TARGET_FILE="$TOPDIR/lustre/kernel_patches/targets/$TARGET.target"
# [ -r "$TARGET_FILE" ] || \
# usage 1 "Target '$TARGET' was not found."
# TARGET_FILE="$TOPDIR/lustre/kernel_patches/targets/$TARGET.target"
# [ -r "$TARGET_FILE" ] || \
# usage 1 "Target '$TARGET' was not found."
# if an unpacked kernel source tree was given on the command line
# just build lustre with it (nothing distro kernel specific here)
if [ -n "$LINUX" ]; then
# if an unpacked kernel source tree was given on the command line
# just build lustre with it (nothing distro kernel specific here)
if [ -n "$LINUX" ]; then
+ find_linux_release() {
+ _find_linux_release $LINUX
+ }
build_ofed "${LINUXOBJ:-$LINUX}" "$OFED_VERSION" ||
fatal 1 "error building OFED"
build_lustre "$LINUX" "$LINUXOBJ"
build_ofed "${LINUXOBJ:-$LINUX}" "$OFED_VERSION" ||
fatal 1 "error building OFED"
build_lustre "$LINUX" "$LINUXOBJ"