[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <d65b1b151001191029o66794c24t228177a8ca544e44@mail.gmail.com>
Date: Tue, 19 Jan 2010 19:29:24 +0100
From: Glenn Sommer <glemsom@...il.com>
To: linux-kernel@...r.kernel.org
Subject: [PATCH] Use full path to dnsdomainname and domainname in
scripts/mkcompile_h
With reference to: http://bugzilla.kernel.org/show_bug.cgi?id=14920
I'll post my suggestion here.
Currently scripts/mkcompile_h checks for "/bin/dnsdomainname" and
"/bin/domainname" when trying to find the DNS name.
Though, when running the executable - the full path isn't used!
IMO if we check for "/bin/dnsdomainname", we should also use
"/bin/dnsdomainname" - and not blindly trust /bin is the first directory in
$PATH which contains a executable named "dnsdomainname"
I propose to use the full path, that we know is valid. Here's my proposed patch:
--- scripts/mkcompile_h.orig 2009-12-28 23:02:34.000000000 +0100
+++ scripts/mkcompile_h 2009-12-28 23:03:12.000000000 +0100
@@ -66,9 +66,9 @@
echo \#define LINUX_COMPILE_HOST \"`hostname | $UTS_TRUNCATE`\"
if [ -x /bin/dnsdomainname ]; then
- echo \#define LINUX_COMPILE_DOMAIN \"`dnsdomainname | $UTS_TRUNCATE`\"
+ echo \#define LINUX_COMPILE_DOMAIN \"`/bin/dnsdomainname | $UTS_TRUNCATE`\"
elif [ -x /bin/domainname ]; then
- echo \#define LINUX_COMPILE_DOMAIN \"`domainname | $UTS_TRUNCATE`\"
+ echo \#define LINUX_COMPILE_DOMAIN \"`/bin/domainname | $UTS_TRUNCATE`\"
else
echo \#define LINUX_COMPILE_DOMAIN
fi
Signed-off-by: Glenn Sommer <glemsom@...il.com>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists