diff --git a/srcpkgs/linux4.0/template b/srcpkgs/linux4.0/template index 805a48e9a0f..71e8fb9d033 100644 --- a/srcpkgs/linux4.0/template +++ b/srcpkgs/linux4.0/template @@ -2,7 +2,7 @@ # pkgname=linux4.0 version=4.0.5 -revision=1 +revision=2 wrksrc="linux-${version}" maintainer="Juan RP " homepage="http://www.kernel.org" @@ -87,11 +87,11 @@ do_build() { make ARCH=$arch ${_cross} ${makejobs} ${_args} } do_install() { - local arch _args hdrdest + local arch subarch _args hdrdest case "$XBPS_TARGET_MACHINE" in - i686*) arch=i386;; - x86_64*) arch=x86_64;; + i686*) arch=x86; subarch=i386;; + x86_64*) arch=x86; subarch=x86_64;; armv7*) arch=arm;; esac @@ -107,7 +107,7 @@ do_install() { vinstall System.map 644 boot System.map-${_kernver} case "$arch" in - i386|x86_64) + x86) vinstall arch/x86/boot/bzImage 644 boot vmlinuz-${_kernver} ;; arm) @@ -143,19 +143,19 @@ do_install() { cd ${wrksrc} mkdir -p ${hdrdest}/arch/${arch} - cp -a arch/x86/include ${hdrdest}/arch/${arch} + cp -a arch/${arch}/include ${hdrdest}/arch/${arch} # Copy files necessary for later builds, like nvidia and vmware cp Module.symvers ${hdrdest} cp -a scripts ${hdrdest} mkdir -p ${hdrdest}/arch/${arch}/kernel - cp arch/x86/Makefile ${hdrdest}/arch/${arch} - if [ "$arch" = "i386" ]; then + cp arch/${arch}/Makefile ${hdrdest}/arch/${arch} + if [ "$subarch" = "i386" ]; then mkdir -p ${hdrdest}/arch/x86 cp arch/x86/Makefile_32.cpu ${hdrdest}/arch/x86 fi - if [ "$arch" = "i386" -o "$arch" = "x86_64" ]; then + if [ "$arch" = "x86" ]; then mkdir -p ${hdrdest}/arch/x86/kernel cp arch/x86/kernel/asm-offsets.s ${hdrdest}/arch/x86/kernel fi