[OpenAFS-devel] Compiling and running OpenAFS both optimized and debugged

Neulinger, Nathan nneul@umr.edu
Thu, 9 Jan 2003 11:41:14 -0600


Would there be any objection to cleaning this up by the following:

Four makefile options, shared across ALL generated makefiles, configured
in the osconf.m4=20

KDBG
KOPT
KOPT_FORCED
DBG
OPT
OPT_FORCED

And add --with[out]-optimization and --with[out]-debug. The _FORCED
would always have the standard optimization/debug flag for that platform
for the cases like in the linux kernel where it has to be compiled with
optimization. (Does libafs require that anywhere?)

STRIP would get set to do nothing if DBG was non-empty.=20

-- Nathan

------------------------------------------------------------
Nathan Neulinger                       EMail:  nneul@umr.edu
University of Missouri - Rolla         Phone: (573) 341-4841
Computing Services                       Fax: (573) 341-4216


> -----Original Message-----
> From: Neulinger, Nathan=20
> Sent: Thursday, January 09, 2003 11:34 AM
> To: 'Phil.Moore@morganstanley.com'; openafs-devel@openafs.org
> Subject: RE: [OpenAFS-devel] Compiling and running OpenAFS=20
> both optimized and debugged
>=20
>=20
> You're going to have to change it in several places... the=20
> makefiles are not quite yet consistent.=20
>=20
> I don't remember every place you have to do it. Are you=20
> concerned about purely user space code, or kernel module as well?
>=20
> -- Nathan
>=20
> ------------------------------------------------------------
> Nathan Neulinger                       EMail:  nneul@umr.edu
> University of Missouri - Rolla         Phone: (573) 341-4841
> Computing Services                       Fax: (573) 341-4216
>=20
>=20
> > -----Original Message-----
> > From: Phil.Moore@morganstanley.com=20
> > [mailto:Phil.Moore@morganstanley.com]=20
> > Sent: Thursday, January 09, 2003 11:26 AM
> > To: openafs-devel@openafs.org
> > Subject: [OpenAFS-devel] Compiling and running OpenAFS both=20
> > optimized and debugged
> >=20
> >=20
> >=20
> > In order to obtain the maximum amount of debugging information from
> > failure in our production environment, I want to build OpenAFS 1.2.8
> > with at least -g, and if it works, also with -O, and also=20
> ensure that
> > the installed binaries are NOT stripped.
> >=20
> > I can't find an easy way to do this.
> >=20
> > It would appear that turning off stripping is simply a matter of
> > setting=20
> >=20
> >     STRIP =3D /bin/true
> >=20
> > in the appropriate Makefile.sysname, but its not clear to me how to
> > get debugging and optimization simultaneously.   I can see that both
> > are defined:
> >=20
> >     OPTMZ=3D-O
> >     DBG=3D-g
> >=20
> > but I can NOT figure out the "right way" to get each=20
> invocation of CC
> > to use these.  INfact, I can't figure out how to get a debugging
> > version at *all*, let alone both debugged and optimized.
> >=20
> > Now, I suppose I can cheat, and set
> >=20
> >     OPTMZ=3D-g
> >=20
> > but then I'll just get a debugging version, without optimization (my
> > second preference).
> >=20
> > A search of the TWiki and the openafs-devel archives didn't turn up
> > the answer.
> >=20
> > What's the trick?????
> > _______________________________________________
> > OpenAFS-devel mailing list
> > OpenAFS-devel@openafs.org
> > https://lists.openafs.org/mailman/listinfo/openafs-devel
> >=20
>=20