This is the mail archive of the
cygwin@cygwin.com
mailing list for the Cygwin project.
Re: DEBUG build of cygwin
- From: Joe Buehler <jbuehler at hekimian dot com>
- To: cygwin at cygwin dot com
- Date: Fri, 21 Mar 2003 16:13:14 -0500
- Subject: Re: DEBUG build of cygwin
- Organization: Spirent Communications, Inc.
- References: <F19APcDvk7eOdU8uudg00002c43@hotmail.com>
- Reply-to: jbuehler at hekimian dot com
Vishal Jain wrote:
Just typing make CFLAGS=-g does not help. It still adds -O2.
Removing -O2 from the top level makefile also does not help.
Here's what I do:
cat >$_BUILD/gcc <<-\! &&
#!/bin/bash
I=0
unset ARGV
for ARG; do
case "$ARG" in
-O*) ARGV[$I]=-g ;;
*) ARGV[$I]="$ARG" ;;
esac
I=$(expr $I + 1)
done
/bin/gcc -g "${ARGV[ at ]}"
!
chmod +x $_BUILD/gcc &&
cat >$_BUILD/c++ <<-\! &&
#!/bin/bash
I=0
unset ARGV
for ARG; do
case "$ARG" in
-O*) ARGV[$I]=-g ;;
*) ARGV[$I]="$ARG" ;;
esac
I=$(expr $I + 1)
done
/bin/c++ -g "${ARGV[ at ]}"
!
chmod +x $_BUILD/c++ &&
bash -x <<-\!
OPTIONS=
OPTIONS="$OPTIONS --enable-debugging"
#OPTIONS="$OPTIONS --enable-malloc-debugging"
export CC=$_BUILD/gcc
export CXX=$_BUILD/c++
export CFLAGS=-g
export CXXFLAGS=-g
cd $_BUILD &&
bash ../src.temp/configure --prefix=$_INSTALL --srcdir=$_HERE/src.temp $OPTIONS i686-pc-cygwin &&
make &&
make install &&
true
!
--
Joe Buehler
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/