Hello,
Since release of package linux-image-5.4.0-1035-aws its source can no longer be compiled using the following set of commands:
$ apt-get source linux-image-5.4.0-1035-aws
$ cd linux-aws-5.4-5.4.0
$ fakeroot debian/rules binary
Where is fails is at:
CROSS_COMPILE= /bin/bash -e debian/scripts/dkms-build /usr/local/src/linux-aws-5.4-5.4.0/debian/build/build-aws/______________________________________dkms 5.4.0-1035-aws ' /usr/local/src/linux-aws-5.4-5.4.0/debian/build/build-aws/scripts/sign-file sha512 /usr/local/src/linux-aws-5.4-5.4.0/debian/build/build-aws/certs/signing_key.pem /usr/local/src/linux-aws-5.4-5.4.0/debian/build/build-aws/certs/signing_key.x509' linux-buildinfo-5.4.0-1035-aws /usr/local/src/linux-aws-5.4-5.4.0/debian/linux-buildinfo-5.4.0-1035-aws/usr/lib/linux/5.4.0-1035-aws/signatures "" nvidia-390 pool/restricted/n/nvidia-graphics-drivers-390/nvidia-kernel-source-390_390.141-0ubuntu0~0.20.04.1_amd64.deb pool/restricted/n/nvidia-graphics-drivers-390/nvidia-dkms-390_390.141-0ubuntu0~0.20.04.1_amd64.deb
II: dkms-build downloading nvidia-390 (nvidia-kernel-source-390_390.141-0ubuntu0~0.20.04.1_amd64.deb)
II: fetching https://launchpad.net/ubuntu/+archive/primary/+files/nvidia-kernel-source-390_390.141-0ubuntu0~0.20.04.1_amd64.deb
II: fetching http://ap-southeast-2.ec2.archive.ubuntu.com/ubuntu//pool/restricted/n/nvidia-graphics-drivers-390/nvidia-kernel-source-390_390.141-0ubuntu0~0.20.04.1_amd64.deb
II: fetching http://ap-southeast-2.ec2.archive.ubuntu.com/ubuntu//pool/main/n/nvidia-graphics-drivers-390/nvidia-kernel-source-390_390.141-0ubuntu0~0.20.04.1_amd64.deb
II: fetching http://security.ubuntu.com/ubuntu/pool/restricted/n/nvidia-graphics-drivers-390/nvidia-kernel-source-390_390.141-0ubuntu0~0.20.04.1_amd64.deb
II: fetching http://security.ubuntu.com/ubuntu/pool/main/n/nvidia-graphics-drivers-390/nvidia-kernel-source-390_390.141-0ubuntu0~0.20.04.1_amd64.deb
EE: nvidia-kernel-source-390 not found
debian/rules.d/2-binary-arch.mk:113: recipe for target 'install-aws' failed
The failure is related to task https://git.launchpad.net/~canonical-kernel/ubuntu/+source/linux-aws/+git/bionic/tree/debian/rules.d/2-binary-arch.mk?h=aws-5.4#n405 which is trying to download via http some source files for the Nvidia DKMS and it is failing, hence leading to the whole kernel build to fail.
Trying to fetch the file affected from other systems (using different internet providers) does not work. Example:
$ wget http://security.ubuntu.com/ubuntu/pool/main/n/nvidia-graphics-drivers-390/nvidia-kernel-source-390_390.141-0ubuntu0~0.20.04.1_amd64.deb
--2021-01-11 04:11:33-- http://security.ubuntu.com/ubuntu/pool/main/n/nvidia-graphics-drivers-390/nvidia-kernel-source-390_390.141-0ubuntu0~0.20.04.1_amd64.deb
Resolving security.ubuntu.com (security.ubuntu.com)... 91.189.91.39, 91.189.88.142, 91.189.88.152, ...
Connecting to security.ubuntu.com (security.ubuntu.com)|91.189.91.39|:80... connected.
HTTP request sent, awaiting response... 404 Not Found
2021-01-11 04:11:34 ERROR 404: Not Found.
Given that there is a recent commit to change exactly the above mentioned file versions: https://git.launchpad.net/~canonical-kernel/ubuntu/+source/linux-aws/+git/bionic/commit/debian?h=aws-5.4&id=3949e9f67d301762efc48e7f060427ec0e9ed0f3 I expect that this is what led to the problem.
Regards,
Alexandru Ionica
The build issue is due a mismatch in package versions for those nvidia drivers as you indicated. The driver contents are the same, the mismatch is in the version strings.
The version strings can be brought in sync by running:
$ apt-get source linux-image- 5.4.0-1035- aws version- dkms updates
$ cd linux-aws-5.4-5.4.0
$ bash ./update-
$ fakeroot debian/rules binary
Note: this will complain about not being a git tree, but will still update `debian/ dkms-versions` .