Date: Fri, 25 Aug 2006 23:20:50 +0800 From: "Yuan, Jue" <yuanjue02@gmail.com> To: LI Xin <delphij@delphij.net> Cc: freebsd-current@freebsd.org Subject: Re: How to change kernel version? Message-ID: <200608252320.50363.yuanjue02@gmail.com> In-Reply-To: <44EF13CA.2070003@delphij.net> References: <200608252000.07240.yuanjue02@gmail.com> <44EF13CA.2070003@delphij.net>
next in thread | previous in thread | raw e-mail | index | archive | help
On Friday 25 August 2006 23:14, LI Xin wrote: > Yuan, Jue wrote: > > Hi all. > > > > Could I change the kernel version tag manually? say, I have a kernel > > which is 7.0-CUREENT, but for some reasons I wanna it be something like > > 6.1-RELEASE, while the kernel itself does't change from 7.0-CURRENT to > > 6.1-RELEASE. All I want is the change of tag. For example, if this works, > > then when I type "uname -a" in console, I would get "6.1-RELEASE ..." > > instead of "7.0-CURRENT ...". > > > > I guess some config files in src/sys/ could take care of this. But I > > cannot find it out. Anybody knows how to get this job done? > > > > Any ideas are really appreciated. :-) > > > > BTW: I am not in this list. So if you reply, please CC a copy to me. > > Thanks. > > Changing the represented release name is not a generally wise idea. You > may also want to modify sys/sys/param.h, consult the FreeBSD Porters' > Handbook for more details. > > If you just want to cheat uname(1) and/or sysctl(8), perhaps renaming > them to _uname and _sysctl and use some sort of _uname $@ | sed -e > s/`_uname -r`/6.1-RELEASE/g trick will do. This also applies to the > rc.d motd script, which uses uname(1) to determine the current FreeBSD > version. This trick is less intrusive, but have no effect if your > application read the version themselves, e.g. the build process of > python, etc. > Thanks for this enlightment. Very helpful :-) -- Best Regards Yuan, Jue @ http://www.yuanjue.net
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200608252320.50363.yuanjue02>