[Python-Dev] Patch 640843 - split OPT into two parts

Guido van Rossum guido@python.org
Tue, 31 Dec 2002 12:26:26 -0500


> I took a break from my fiddling with the OPT make/configure variable when I
> discovered the problems with out-of-tree builds.  Andrew got that fixed a
> couple days ago, so I revisited my changes.  I'd like to check them in, but
> should probably wait until Guido bundles 2.3a1.  Changes are to these files:
> 
>     configure.in (and configure, of course)
>     setup.py
>     Makefile.pre.in
>     Misc/NEWS
> 
> There are some structural changes in configure.in that make it worth a
> careful look-see.  In particular, I hope I haven't bolluxed up Martin's SCO
> changes from September (I can't test on that platform).
> 
> Here's the new text from Misc/NEWS:
> 
> - On systems which build using the configure script, compiler flags which
>   used to be lumped together using the OPT flag have been split into two
>   groups, OPT and BASECFLAGS.  OPT is meant to carry just optimization- and
>   debug-related flags like "-g" and "-O3".  BASECFLAGS is meant to carry
>   compiler flags that are required to get a clean compile.  On some
>   platforms (many Linux flavors in particular) BASECFLAGS will be empty by
>   default.  On others, such as MacOSX and SCO, it will contain required
>   flags.  This change allows people building Python to override OPT without
>   fear of clobbering compiler flags which are required to get a clean build.
> 
> Everything passes on both MacOSX and Mandrake 8.1 from CVS as of a few
> minutes ago.
> 
> I uploaded a new context diff to SF so people can eyeball it, though I'll
> wait for Guido to say "check it in".  There's one itty-bitty change to
> setup.py that's unrelated.  It adds the fink directories /sw/lib and
> /sw/include to the relevant search lists when building on Darwin.

Are you sure you want to risk this right before the release?  If it
breaks some platform's build, we're hosed.

OTOH if you want to risk it, I'm not going to stop you -- I agree that
in principle the change is a desirable one.

--Guido van Rossum (home page: http://www.python.org/~guido/)