I get a kernel compilation error with gentoo-sources-3.8.13 during a Gentoo Linux installation: fs/built-in.o: In function `nfs_dns_resolve_name': (.text+0x1170cc): undefined reference to `dns_query' make: *** [vmlinux] Error 1 The linker is trying to resolve a symbol called dns_query, a kernel option not selected. Reproducible: Always Steps to Reproduce: 1. Chroot to a stage3 to install Gentoo Linux 2. emerge gentoo-sources 3. Try to compile linux kernel at first: $make && make modules_install ... LD init/built-in.o fs/built-in.o: In function `nfs_dns_resolve_name': (.text+0x1170cc): undefined reference to `dns_query' make: *** [vmlinux] Error 1 Expected Results: Kernel compilation should work fine with stable gentoo-sources. I attach the tested .config file
Created attachment 351326 [details] Config used to compile kernel
Thank you, I will try this soon.
Created attachment 351942 [details, diff] patch for nfs dep on dns_resolver If anyone wants to reproduce this, just start with unconfigured gentoo-sources-3.8.13, do "make menuconfig" and go mark CONFIG_NFS_V4 as modular, then save/exit, and make. What seems to be going on is: marking CONFIG_NFS_V4=m also selects CONFIG_DNS_RESOLVER=m, but it actually also causes the built-in CONFIG_NFS_FS=y (nfs.o) to use some functions (like dns_query) from the modular dns_resolv.o. This dependency problem still exists in 3.9.7 but is harder to hit, since defconfig includes CONFIG_NFS_v4=y. If you start with unconfigured 3.9.7 and use menuconfig to change to CONFIG_NFS_v4=m, then save/exit and make, you'll see the same problem. I've attached a possible fix, but I'm no Kconfig guru so this could use a few eyes on it. I does resolve the immediate dep problem, though.
Jaime, can you try his attached patch and let us know whether it works? If it does, I'll look into this into more detail to embed it in genpatches and upstream it so they can fix it there as well.
(In reply to Tom Wijsman (TomWij) from comment #4) > Jaime, can you try his attached patch and let us know whether it works? > > If it does, I'll look into this into more detail to embed it in genpatches > and upstream it so they can fix it there as well. I have tried the patch and works fine.
We still need to apply this ourselves or send this upstream; so, please don't mark it as resolved yet. Thank you in advance. :)
Tom, let me know if you sent this/are going to send this upstream.
(In reply to Mike Pagano from comment #7) > Tom, let me know if you sent this/are going to send this upstream. Filed upstream at https://bugzilla.kernel.org/show_bug.cgi?id=60841 and will apply this soon to genpatches.
This has been resolved in 3.11 due to commit c8d74d9b68b655e85ee4603f8918c3233a74f085.