preview uname wrong

Simon 'corecode' Schubert corecode at fs.ei.tum.de
Fri Sep 2 08:24:55 PDT 2005


some people reported that uname reports "Preview-Preview".  I analyzed 
why this happens:

% sh -x newvers.sh
+ tag=$Name: DragonFly_Preview $
+ awk+ echo { print $2; } $Name:
 DragonFly_Preview $
+ BRANCH=DragonFly_Preview
+ BRANCH=Preview
+ BRANCH=Preview
+ [ XPreview = X$ ]
+ [ XPreview = XHEAD ]
+ [ XPreview = X ]
+ TYPE=DragonFly
+ SHORTTAG=Preview
+ REVISION=Preview
+ BRANCH=Preview
+ [ Preview != Preview ]
+ [ -f machine/../../../sys/conf/subvers-Preview ]
+ [ -f ../sys/conf/subvers-Preview ]
+ [ -f ../../sys/conf/subvers-Preview ]
+ [ -f ../../../sys/conf/subvers-Preview ]
+ [ -f /usr/src/sys/conf/subvers-Preview ]
+ RELEASE=Preview-Preview
+ VERSION=DragonFly Preview-Preview
+ [ X != X ]
+ dirname newvers.sh
+ awk /__DragonFly_version.*propagated to newvers/ {print $3} 
. /../sys/param.h
+ RELDATE=130004
+ b=share/examples/etc/bsd-style-copyright
+ date +%Y
+ year=2005

As you can see, BRANCH gets set to "Preview" and the same REVISION.  We 
either need to add special "Preview" handling, or we need to generalize 
the subvers handling a little bit, like
- add a mainver=1.3
- read subvers-$mainver to get subver
- use the checkout tag only to get the tag "-DEVELOPMENT, -PREVIEW, 
-RELEASE"

cheers
  simon
--
Serve - BSD     +++  RENT this banner advert  +++    ASCII Ribbon   /"\
Work - Mac      +++  space for low $$$ NOW!1  +++      Campaign     \ /
Party Enjoy Relax   |   http://dragonflybsd.org      Against  HTML   \
Dude 2c 2 the max   !   http://golden-apple.biz       Mail + News   / \




More information about the Bugs mailing list