X-Git-Url: http://gitweb.hugovil.com/?a=blobdiff_plain;f=stage2%2Fpkg%2Flinux;h=a3ee9f59243976113822d33030fd2a8011c7103b;hb=28d0870bca1d37d0428af01f1b44cc7f29199ba4;hp=dd0af0b8d271e0f2c76c426efe7abd11803953d4;hpb=88f5fb0c316fe9a38c3d05a2e2a2dcfbc5c95557;p=hvlinux.git diff --git a/stage2/pkg/linux b/stage2/pkg/linux index dd0af0b..a3ee9f5 100644 --- a/stage2/pkg/linux +++ b/stage2/pkg/linux @@ -2,25 +2,24 @@ hvbuild() { - # Check if kernel sources from stage0 are still there + # Check if kernel sources from stage0 are still in /usr/src. + # If not, recopy them. if [ ! -d /usr/src/${PACKAGE} ]; then - # If no, then copy them. We don't install headers and - # assume that it is a new kernel version installation. - mv ${LFS_TMP}/${PACKAGE} /usr/src - else - # Install headers - cd /usr/src/${PACKAGE} - make mrproper - make headers_check - - # Remove any previous headers install - rm -rf dest - make INSTALL_HDR_PATH=dest headers_install - cp -rv dest/include/* /usr/include - find /usr/include -name .install -or -name ..install.cmd | xargs rm -fv - rm -rf dest + cp -a ${LFS_TMP}/${PACKAGE} /usr/src fi + # Install headers + cd /usr/src/${PACKAGE} + make mrproper + make headers_check + + # Remove any previous headers install + rm -rf dest + make INSTALL_HDR_PATH=dest headers_install + cp -rv dest/include/* /usr/include + find /usr/include -name .install -or -name ..install.cmd | xargs rm -fv + rm -rf dest + # Install HV kernel compilation script: VERSION=$(get_pkg_ver ${PACKAGE}) SCRIPT=/usr/src/compile-kernel