Here is the patch file that should create a Makefile.distro in the target directory and then include this file as part of the make process. It checks for the buildid option for ld using awk in buildtarget script. Then sets the appropriate flag in the file.
I do not check to see if the Makefile.distro is "current". It just checks to see if one is present or not.