This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author trent
Recipients koobs, skrah, trent
Date 2012-08-21.21:58:19
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1345586300.5.0.087898850836.issue15757@psf.upfronthosting.co.za>
In-reply-to
Content
So, looks like FreeBSD's /usr/share/mk/sys.mk is to blame here.  It unconditionally sets CFLAGS to `-O2 -pipe`.


[trent@hydrogen/ttypts/1(~s/cpython)%] uname -a
FreeBSD hydrogen.snakebite.net 9.1-PRERELEASE FreeBSD 9.1-PRERELEASE #0 r0: Mon Jul 16 06:28:19 UTC 2012     root@hydrogen.snakebite.net:/usr/obj/src/freebsd/9/r238513m/sys/AMD64  amd64

[trent@hydrogen/ttypts/1(~s/cpython)%] grep -A3 'bsd_make_test' Makefile
bsd_make_test:
	@echo "CFLAGS: $(CFLAGS)"
	@echo "EXTRA_CFLAGS: $(EXTRA_CFLAGS)"

[trent@hydrogen/ttypts/1(~s/cpython)%] make bsd_make_test        
CFLAGS: -O2 -pipe 
EXTRA_CFLAGS: 

[trent@hydrogen/ttypts/1(~s/cpython)%] make CFLAGS= bsd_make_test
CFLAGS: 
EXTRA_CFLAGS: 

I can think of a few ways to work around this... some better than others.

1. Change the FreeBSD buildbots to always invoke make via `make CFLAGS=`.

2. Hack configure.* to automatically invoke make via `make CFLAGS=` when `-O2 -pipe` crops up in a `--with-pydebug` build.

Some of the less desirable ones:

3. Switch FreeBSD to gmake.

4. Patch FreeBSD make so that it is 'debug aware' and stops appending `-O2` everywhere.
History
Date User Action Args
2012-08-21 21:58:20trentsetrecipients: + trent, skrah, koobs
2012-08-21 21:58:20trentsetmessageid: <1345586300.5.0.087898850836.issue15757@psf.upfronthosting.co.za>
2012-08-21 21:58:20trentlinkissue15757 messages
2012-08-21 21:58:19trentcreate