[OpenAFS-win32-devel] Winafsbld

Mickey Lane mlane@sinenomine.net
Mon, 29 Nov 2010 09:02:58 -0600


--_000_1171E06FDB4D8341937880DCD831A0E20173FED2F334093MBXC15me_
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

I'd like to open a design discussion about winafsbld here as it seems rathe=
r inappropriate to put it in the comments for a specific version of the cod=
e in gerrit 3332. Perhaps we can form a consensus and I can create a 3rd pa=
tch set that resolves all outstanding issues in one go.

Some of the outstanding comments I need to address:


First) Having the URL of the time stamp server in the batch file.

This is easy enough to move to an external environment variable. There is n=
o need to use a specific server with a specific signing certificate that I'=
m aware of. On at least one occasion, the preferred server was unavailable =
or taking too long to respond so I switched to another and everything worke=
d fine. I left the initial server URL commented out so I wouldn't have to l=
ook it up again.


Second) The requirement that a file needs to be edited to specify build opt=
ions.

The design goal of the current code was to put all of the adjustable things=
 at the top of the main script so the user only had part of one file to rev=
iew and edit. All of the adjustments are in a single block of code (lines 1=
7-25). The main script doesn't really do anything except call the subroutin=
e scripts.

I would like to know what would be preferable. I'm pretty sure the implemen=
tation wouldn't be that difficult.

Two options that come to mind are multiple top level files with the names r=
eflecting the function and command line arguments to a single file. I'm sur=
e many others exist.


Third) 32 vs 64-bit builds.

Winafsbld works on either platform provided you do 64-bit builds on a 64-bi=
t system and a 32 on a 32. The original design goal was to enable cross pla=
tform builds but there are a number of problems with that at the moment.

The intent of the winafsbld_everything script is to replace the winafsbld s=
cript and iteratively set the variables and call the subroutine scripts. Je=
ffry Altman points out some issues in the everything script that need to be=
 resolved.


Fourth) Timestamping

The line "rem set WINAFSBLD_CONFIG_TIMESTAMP=3DNO    (not functional yet)" =
in winafsbld.bat needs to be removed. This was added as part of a request b=
y Mike Meffie to disable time stamping for build verifications on a machine=
 that apparently couldn't see a public time stamp server. Setting "WINAFSBL=
D_CONFIG_SIGN=3DNO" serves the same purpose.


Fifth) Environment variable WINAFSBLD__VC2005

>From Jeffery Altman's comments...

In all the time I've been using this script, I never noticed that "VC" shou=
ld be "VS." I will change it. At the moment, the VC2008 variable is not nee=
ded if the build is using Visual Studio 2005. Likewise, if Visual Studio 20=
08 builds ever become supported, the VC2005 environment will not be needed.


Sixth) Possible combinations of VS, SDK & DDK

This is a major issue and one that winafsbld seems to do rather well with. =
The setting of environment variables for include and library locations are =
dealt with by the winafsbld_include and winafsbld_lib subroutine scripts re=
spectively. These files take a rather ponderous approach to the problem by =
defining specific sections to each of the major permutations. I haven't loo=
ked at it in a while but in at least one case, the script goes hunting for =
the paths to use based on what's installed on the build machine.
Debugging this sort of thing is very tedious but at least what's done for o=
ne configuration won't impact any of the others. If winafsbld is accepted, =
work needs to be done in this area.

Jeffery Altman's comments of 11/27 contain other items that I need to addre=
ss but I will do that in another posting.

Regards,
Mickey.


--_000_1171E06FDB4D8341937880DCD831A0E20173FED2F334093MBXC15me_
Content-Type: text/html; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

<html xmlns:v=3D"urn:schemas-microsoft-com:vml" xmlns:o=3D"urn:schemas-micr=
osoft-com:office:office" xmlns:w=3D"urn:schemas-microsoft-com:office:word" =
xmlns:m=3D"http://schemas.microsoft.com/office/2004/12/omml" xmlns=3D"http:=
//www.w3.org/TR/REC-html40"><head><meta http-equiv=3DContent-Type content=
=3D"text/html; charset=3Dus-ascii"><meta name=3DGenerator content=3D"Micros=
oft Word 12 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
	{font-family:"Cambria Math";
	panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
	{font-family:Calibri;
	panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
	{margin:0in;
	margin-bottom:.0001pt;
	font-size:11.0pt;
	font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
	{mso-style-priority:99;
	color:blue;
	text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
	{mso-style-priority:99;
	color:purple;
	text-decoration:underline;}
p.MsoListParagraph, li.MsoListParagraph, div.MsoListParagraph
	{mso-style-priority:34;
	margin-top:0in;
	margin-right:0in;
	margin-bottom:0in;
	margin-left:.5in;
	margin-bottom:.0001pt;
	font-size:11.0pt;
	font-family:"Calibri","sans-serif";}
span.EmailStyle17
	{mso-style-type:personal-compose;
	font-family:"Calibri","sans-serif";
	color:windowtext;}
.MsoChpDefault
	{mso-style-type:export-only;}
@page WordSection1
	{size:8.5in 11.0in;
	margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
	{page:WordSection1;}
/* List Definitions */
@list l0
	{mso-list-id:301083826;
	mso-list-type:hybrid;
	mso-list-template-ids:-1237835994 529537916 67698713 67698715 67698703 676=
98713 67698715 67698703 67698713 67698715;}
@list l0:level1
	{mso-level-text:%1-;
	mso-level-tab-stop:none;
	mso-level-number-position:left;
	text-indent:-.25in;}
@list l1
	{mso-list-id:647788656;
	mso-list-type:hybrid;
	mso-list-template-ids:764966776 67698705 67698713 67698715 67698703 676987=
13 67698715 67698703 67698713 67698715;}
@list l1:level1
	{mso-level-text:"%1\)";
	mso-level-tab-stop:none;
	mso-level-number-position:left;
	text-indent:-.25in;}
ol
	{margin-bottom:0in;}
ul
	{margin-bottom:0in;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext=3D"edit" spidmax=3D"1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext=3D"edit">
<o:idmap v:ext=3D"edit" data=3D"1" />
</o:shapelayout></xml><![endif]--></head><body lang=3DEN-US link=3Dblue vli=
nk=3Dpurple><div class=3DWordSection1><p class=3DMsoNormal><span style=3D'f=
ont-size:12.0pt'>I&#8217;d like to open a design discussion about winafsbld=
 here as it seems rather inappropriate to put it in the comments for a spec=
ific version of the code in gerrit 3332. Perhaps we can form a consensus an=
d I can create a 3<sup>rd</sup> patch set that resolves all outstanding iss=
ues in one go.<o:p></o:p></span></p><p class=3DMsoNormal><span style=3D'fon=
t-size:12.0pt'><o:p>&nbsp;</o:p></span></p><p class=3DMsoNormal><span style=
=3D'font-size:12.0pt'>Some of the outstanding comments I need to address:<o=
:p></o:p></span></p><p class=3DMsoNormal><span style=3D'font-size:12.0pt'><=
o:p>&nbsp;</o:p></span></p><p class=3DMsoNormal><span style=3D'font-size:12=
.0pt'><o:p>&nbsp;</o:p></span></p><p class=3DMsoNormal><span style=3D'font-=
size:12.0pt'>First) Having the URL of the time stamp server in the batch fi=
le.<o:p></o:p></span></p><p class=3DMsoNormal><span style=3D'font-size:12.0=
pt'><o:p>&nbsp;</o:p></span></p><p class=3DMsoNormal><span style=3D'font-si=
ze:12.0pt'>This is easy enough to move to an external environment variable.=
 There is no need to use a specific server with a specific signing certific=
ate that I&#8217;m aware of. On at least one occasion, the preferred server=
 was unavailable or taking too long to respond so I switched to another and=
 everything worked fine. I left the initial server URL commented out so I w=
ouldn&#8217;t have to look it up again.<o:p></o:p></span></p><p class=3DMso=
Normal><span style=3D'font-size:12.0pt'><o:p>&nbsp;</o:p></span></p><p clas=
s=3DMsoNormal><span style=3D'font-size:12.0pt'><o:p>&nbsp;</o:p></span></p>=
<p class=3DMsoNormal><span style=3D'font-size:12.0pt'>Second) The requireme=
nt that a file needs to be edited to specify build options.<o:p></o:p></spa=
n></p><p class=3DMsoNormal><span style=3D'font-size:12.0pt'><o:p>&nbsp;</o:=
p></span></p><p class=3DMsoNormal><span style=3D'font-size:12.0pt'>The desi=
gn goal of the current code was to put all of the adjustable things at the =
top of the main script so the user only had part of one file to review and =
edit. All of the adjustments are in a single block of code (lines 17-25). T=
he main script doesn&#8217;t really do anything except call the subroutine =
scripts.<o:p></o:p></span></p><p class=3DMsoNormal><span style=3D'font-size=
:12.0pt'><o:p>&nbsp;</o:p></span></p><p class=3DMsoNormal><span style=3D'fo=
nt-size:12.0pt'>I would like to know what would be preferable. I&#8217;m pr=
etty sure the implementation wouldn&#8217;t be that difficult.<o:p></o:p></=
span></p><p class=3DMsoNormal><span style=3D'font-size:12.0pt'><o:p>&nbsp;<=
/o:p></span></p><p class=3DMsoNormal><span style=3D'font-size:12.0pt'>Two o=
ptions that come to mind are multiple top level files with the names reflec=
ting the function and command line arguments to a single file. I&#8217;m su=
re many others exist.<o:p></o:p></span></p><p class=3DMsoNormal><span style=
=3D'font-size:12.0pt'><o:p>&nbsp;</o:p></span></p><p class=3DMsoNormal><spa=
n style=3D'font-size:12.0pt'><o:p>&nbsp;</o:p></span></p><p class=3DMsoNorm=
al><span style=3D'font-size:12.0pt'>Third) 32 vs 64-bit builds.<o:p></o:p><=
/span></p><p class=3DMsoNormal><span style=3D'font-size:12.0pt'><o:p>&nbsp;=
</o:p></span></p><p class=3DMsoNormal><span style=3D'font-size:12.0pt'>Wina=
fsbld works on either platform provided you do 64-bit builds on a 64-bit sy=
stem and a 32 on a 32. The original design goal was to enable cross platfor=
m builds but there are a number of problems with that at the moment.<o:p></=
o:p></span></p><p class=3DMsoNormal><span style=3D'font-size:12.0pt'><o:p>&=
nbsp;</o:p></span></p><p class=3DMsoNormal><span style=3D'font-size:12.0pt'=
>The intent of the winafsbld_everything script is to replace the winafsbld =
script and iteratively set the variables and call the subroutine scripts. J=
effry Altman points out some issues in the everything script that need to b=
e resolved.<o:p></o:p></span></p><p class=3DMsoNormal><span style=3D'font-s=
ize:12.0pt'><o:p>&nbsp;</o:p></span></p><p class=3DMsoNormal><span style=3D=
'font-size:12.0pt'><o:p>&nbsp;</o:p></span></p><p class=3DMsoNormal><span s=
tyle=3D'font-size:12.0pt'>Fourth) Timestamping<o:p></o:p></span></p><p clas=
s=3DMsoNormal><span style=3D'font-size:12.0pt'><o:p>&nbsp;</o:p></span></p>=
<p class=3DMsoNormal><span style=3D'font-size:12.0pt'>The line &#8220;rem s=
et WINAFSBLD_CONFIG_TIMESTAMP=3DNO&nbsp;&nbsp;&nbsp; (not functional yet)&#=
8221; in winafsbld.bat needs to be removed. This was added as part of a req=
uest by Mike Meffie to disable time stamping for build verifications on a m=
achine that apparently couldn&#8217;t see a public time stamp server. Setti=
ng &#8220;WINAFSBLD_CONFIG_SIGN=3DNO&#8221; serves the same purpose.<o:p></=
o:p></span></p><p class=3DMsoNormal><span style=3D'font-size:12.0pt'><o:p>&=
nbsp;</o:p></span></p><p class=3DMsoNormal><span style=3D'font-size:12.0pt'=
><o:p>&nbsp;</o:p></span></p><p class=3DMsoNormal><span style=3D'font-size:=
12.0pt'>Fifth) Environment variable WINAFSBLD__VC2005<o:p></o:p></span></p>=
<p class=3DMsoNormal><span style=3D'font-size:12.0pt'><o:p>&nbsp;</o:p></sp=
an></p><p class=3DMsoNormal><span style=3D'font-size:12.0pt'>From Jeffery A=
ltman&#8217;s comments&#8230;<o:p></o:p></span></p><p class=3DMsoNormal><sp=
an style=3D'font-size:12.0pt'><o:p>&nbsp;</o:p></span></p><p class=3DMsoNor=
mal><span style=3D'font-size:12.0pt'>In all the time I&#8217;ve been using =
this script, I never noticed that &#8220;VC&#8221; should be &#8220;VS.&#82=
21; I will change it. At the moment, the VC2008 variable is not needed if t=
he build is using Visual Studio 2005. Likewise, if Visual Studio 2008 build=
s ever become supported, the VC2005 environment will not be needed.<o:p></o=
:p></span></p><p class=3DMsoNormal><span style=3D'font-size:12.0pt'><o:p>&n=
bsp;</o:p></span></p><p class=3DMsoNormal><span style=3D'font-size:12.0pt'>=
<o:p>&nbsp;</o:p></span></p><p class=3DMsoNormal><span style=3D'font-size:1=
2.0pt'>Sixth) Possible combinations of VS, SDK &amp; DDK<o:p></o:p></span><=
/p><p class=3DMsoNormal><span style=3D'font-size:12.0pt'><o:p>&nbsp;</o:p><=
/span></p><p class=3DMsoNormal><span style=3D'font-size:12.0pt'>This is a m=
ajor issue and one that winafsbld seems to do rather well with. The setting=
 of environment variables for include and library locations are dealt with =
by the winafsbld_include and winafsbld_lib subroutine scripts respectively.=
 These files take a rather ponderous approach to the problem by defining sp=
ecific sections to each of the major permutations. I haven&#8217;t looked a=
t it in a while but in at least one case, the script goes hunting for the p=
aths to use based on what&#8217;s installed on the build machine.<o:p></o:p=
></span></p><p class=3DMsoNormal><span style=3D'font-size:12.0pt'>Debugging=
 this sort of thing is very tedious but at least what&#8217;s done for one =
configuration won&#8217;t impact any of the others. If winafsbld is accepte=
d, work needs to be done in this area.<o:p></o:p></span></p><p class=3DMsoN=
ormal><span style=3D'font-size:12.0pt'><o:p>&nbsp;</o:p></span></p><p class=
=3DMsoNormal><span style=3D'font-size:12.0pt'>Jeffery Altman&#8217;s commen=
ts of 11/27 contain other items that I need to address but I will do that i=
n another posting.<o:p></o:p></span></p><p class=3DMsoNormal><span style=3D=
'font-size:12.0pt'><o:p>&nbsp;</o:p></span></p><p class=3DMsoNormal><span s=
tyle=3D'font-size:12.0pt'>Regards,<o:p></o:p></span></p><p class=3DMsoNorma=
l><span style=3D'font-size:12.0pt'>Mickey.<o:p></o:p></span></p><p class=3D=
MsoNormal><span style=3D'font-size:12.0pt'><o:p>&nbsp;</o:p></span></p></di=
v></body></html>=

--_000_1171E06FDB4D8341937880DCD831A0E20173FED2F334093MBXC15me_--