summaryrefslogtreecommitdiffstats
path: root/remote/modules
diff options
context:
space:
mode:
Diffstat (limited to 'remote/modules')
-rw-r--r--remote/modules/vmware/vmware.build10
1 files changed, 6 insertions, 4 deletions
diff --git a/remote/modules/vmware/vmware.build b/remote/modules/vmware/vmware.build
index c1dd77ce..5d91b02d 100644
--- a/remote/modules/vmware/vmware.build
+++ b/remote/modules/vmware/vmware.build
@@ -21,17 +21,19 @@ fetch_source() {
}
build() {
+
# prepare the build directory with the files needed during the chroot
cp "${MODULE_DIR}/src/$VMWARE_BUNDLE_FILE" "${MODULE_BUILD_DIR}/$VMWARE_BUNDLE_FILE"
cp -r "${MODULE_DIR}/patches" "${MODULE_BUILD_DIR}"
+
+ # sanity check to see if KERNEL_HEADERS_PATH is set and exists
+ [ -z "${KERNEL_HEADERS_PATH}" -o ! -e "${KERNEL_HEADERS_PATH}" ] && perror "KERNEL_HEADERS_PATH ('"${KERNEL_HEADERS_PATH}"') not found. Was the kernel module built?"
pinfo "Installing vmware per chroot..."
chroot_run "${MODULE_BUILD_DIR}" <<-EOF
- # PS1='\[\e[1;33m\](chroot) \u@\h:\w\$ \[\e[1;32m\]' /bin/bash -norc # un-comment for debugging within chroot
yes | sh /"${VMWARE_BUNDLE_FILE}" --eulas-agreed --console --required
- vmware-modconfig --console --build-mod -k "${SYS_UTS_RELEASE}" vmnet $(which gcc) "${MODULES_DIR}"/kernel/ksrc/include/ vmplayer vmnet
- vmware-modconfig --console --build-mod -k "${SYS_UTS_RELEASE}" vmmon $(which gcc) "${MODULES_DIR}"/kernel/ksrc/include/ vmplayer vmmon
- # PS1='\[\e[1;33m\](chroot) \u@\h:\w\$ \[\e[1;32m\]' /bin/bash -norc # un-comment for debugging within chroot
+ vmware-modconfig --console --build-mod -k "${SYS_UTS_RELEASE}" vmnet $(which gcc) "${KERNEL_HEADERS_PATH}/include" vmplayer vmnet
+ vmware-modconfig --console --build-mod -k "${SYS_UTS_RELEASE}" vmmon $(which gcc) "${KERNEL_HEADERS_PATH}/include" vmplayer vmmon
EOF
# cleanup unneeded files