Add dmalloc debug library facility.
Add patches for dmalloc.
Ignore the generated config/debug.in
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/config/debug/dmalloc.in Fri May 18 15:57:16 2007 +0000
1.3 @@ -0,0 +1,35 @@
1.4 +# dmalloc debug facility
1.5 +
1.6 +menuconfig DMALLOC
1.7 + bool
1.8 + prompt "dmalloc"
1.9 + default n
1.10 + depends on EXPERIMENTAL
1.11 +
1.12 +if DMALLOC
1.13 +
1.14 +choice
1.15 + bool
1.16 + prompt "dmalloc version"
1.17 +
1.18 +config DMALLOC_V_5_4_3
1.19 + bool
1.20 + prompt "5.4.3"
1.21 + depends on OBSOLETE
1.22 +
1.23 +config DMALLOC_V_5_5_2
1.24 + bool
1.25 + prompt "5.5.2"
1.26 +
1.27 +# CT_INSERT_VERSION_ABOVE
1.28 +# Don't remove above line!
1.29 +endchoice
1.30 +
1.31 +config DMALLOC_VERSION
1.32 + string
1.33 + default "5.4.3" if DMALLOC_V_5_4_3
1.34 + default "5.5.2" if DMALLOC_V_5_5_2
1.35 +# CT_INSERT_VERSION_STRING_ABOVE
1.36 +# Don't remove above line!
1.37 +
1.38 +endif
2.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2.2 +++ b/patches/dmalloc/5.5.2/100-use-xtools.patch Fri May 18 15:57:16 2007 +0000
2.3 @@ -0,0 +1,58 @@
2.4 +This patch makes configure use the cross ld and ar rather than the native tools.
2.5 +
2.6 +It was build up by Yann E. MORIN <yann.morin.1998@anciens.enib.fr> from some
2.7 +bits gathered from buildroot, which is LGPL v2.1
2.8 +License for dmalloc is:
2.9 + * Permission to use, copy, modify, and distribute this software for
2.10 + * any purpose and without fee is hereby granted, provided that the
2.11 + * above copyright notice and this permission notice appear in all
2.12 + * copies, and that the name of Gray Watson not be used in advertising
2.13 + * or publicity pertaining to distribution of the document or software
2.14 + * without specific, written prior permission.
2.15 + *
2.16 + * Gray Watson makes no representations about the suitability of the
2.17 + * software described herein for any purpose. It is provided "as is"
2.18 + * without express or implied warranty.
2.19 +
2.20 +I personnaly believe that the resulting code should therefore be
2.21 +LGPL v2.1, but don't believe me, ask your lawyers!
2.22 +
2.23 +diff -dur dmalloc-5.5.2.orig/configure dmalloc-5.5.2/configure
2.24 +--- dmalloc-5.5.2.orig/configure 2007-05-14 19:26:14.000000000 +0200
2.25 ++++ dmalloc-5.5.2/configure 2007-05-18 11:38:25.000000000 +0200
2.26 +@@ -4418,14 +4418,14 @@
2.27 + (exit $ac_status); }; }; then
2.28 +
2.29 + # so now we try to create an archive from the compiled .o file
2.30 +- (ar cr conftest.a conftest.o) 2>&5
2.31 ++ (${AR} cr conftest.a conftest.o) 2>&5
2.32 + # see which shared-library ld commands work
2.33 + #
2.34 + # Darwin/Mac OS X - Terry Teague
2.35 + # username terry_teague at domain users.sourceforge.net
2.36 + ac_cv_shared_lib_link_objs=no
2.37 + if test `uname` = "Darwin"; then
2.38 +- if (ld -dylib -o conftest.so.t -lc conftest.a) 2>&5; then
2.39 ++ if (${LD} -dylib -o conftest.so.t -lc conftest.a) 2>&5; then
2.40 + # By convention on some platforms
2.41 + # libLLL.so, libLLL.X.so are symlinks to libLLL.X.Y.Z.so
2.42 + # where X.Y.Z is version # (major.minor.increment) of the library
2.43 +@@ -4443,12 +4443,12 @@
2.44 + ac_cv_shared_link_args='# Could not configure shlib linking'
2.45 + enable_shlib=no
2.46 + fi
2.47 +- elif (ld -shared --whole-archive -soname conftest.so -o conftest.so.t conftest.a) 2>&5; then
2.48 +- ac_cv_shared_link_args='ld -shared --whole-archive -soname $@ -o $@.t'
2.49 +- elif (ld -shared -o conftest.so.t -all -soname conftest.so.t -none -lc -all conftest.a) 2>&5; then
2.50 +- ac_cv_shared_link_args='ld -shared -o $@.t -all -soname $@ -none -lc -all'
2.51 +- elif (ld -G -o conftest.so.t conftest.a) 2>&5; then
2.52 +- ac_cv_shared_link_args='ld -G -o $@.t'
2.53 ++ elif (${LD} -shared --whole-archive -soname conftest.so -o conftest.so.t conftest.a) 2>&5; then
2.54 ++ ac_cv_shared_link_args="${LD}"' -shared --whole-archive -soname $@ -o $@.t'
2.55 ++ elif (${LD} -shared -o conftest.so.t -all -soname conftest.so.t -none -lc -all conftest.a) 2>&5; then
2.56 ++ ac_cv_shared_link_args="${LD}"' -shared -o $@.t -all -soname $@ -none -lc -all'
2.57 ++ elif (${LD} -G -o conftest.so.t conftest.a) 2>&5; then
2.58 ++ ac_cv_shared_link_args="${LD}"' -G -o $@.t'
2.59 + else
2.60 + # oh well, toss an error
2.61 + ac_cv_shared_link_args='# Could not configure shlib linking'
3.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
3.2 +++ b/patches/dmalloc/5.5.2/110-block_size.patch Fri May 18 15:57:16 2007 +0000
3.3 @@ -0,0 +1,32 @@
3.4 +This patch sets the page size to a default 12, that is a 4KiB block size.
3.5 +Testing for the correct block-size is impossible when cross-compiling.
3.6 +
3.7 +It was build up by Yann E. MORIN <yann.morin.1998@anciens.enib.fr> from some
3.8 +bits gathered from buildroot, which is LGPL v2.1
3.9 +License for dmalloc is:
3.10 + * Permission to use, copy, modify, and distribute this software for
3.11 + * any purpose and without fee is hereby granted, provided that the
3.12 + * above copyright notice and this permission notice appear in all
3.13 + * copies, and that the name of Gray Watson not be used in advertising
3.14 + * or publicity pertaining to distribution of the document or software
3.15 + * without specific, written prior permission.
3.16 + *
3.17 + * Gray Watson makes no representations about the suitability of the
3.18 + * software described herein for any purpose. It is provided "as is"
3.19 + * without express or implied warranty.
3.20 +
3.21 +I personnaly believe that the resulting code should therefore be
3.22 +LGPL v2.1, but don't believe me, ask your lawyers!
3.23 +
3.24 +diff -dur dmalloc-5.5.2.orig/configure dmalloc-5.5.2/configure
3.25 +--- dmalloc-5.5.2.orig/configure 2007-05-14 19:26:14.000000000 +0200
3.26 ++++ dmalloc-5.5.2/configure 2007-05-18 11:38:25.000000000 +0200
3.27 +@@ -5306,7 +5306,7 @@
3.28 +
3.29 + echo "$as_me:$LINENO: checking basic-block size" >&5
3.30 + echo $ECHO_N "checking basic-block size... $ECHO_C" >&6
3.31 +-ac_cv_page_size=0
3.32 ++ac_cv_page_size=12
3.33 + if test $ac_cv_page_size = 0; then
3.34 + if test "$cross_compiling" = yes; then
3.35 + { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
4.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
4.2 +++ b/patches/dmalloc/5.5.2/120-g++_check.patch Fri May 18 15:57:16 2007 +0000
4.3 @@ -0,0 +1,17 @@
4.4 +Correctly check for g++ existence.
4.5 +
4.6 +Copyright 2007 Yann E. MORIN <yann.morin.1998@anciens.enib.fr>
4.7 +Licensed to you as dmalloc-5.5.2 is.
4.8 +
4.9 +diff -dur dmalloc-5.5.2.orig/configure dmalloc-5.5.2/configure
4.10 +--- dmalloc-5.5.2.orig/configure 2007-05-18 11:40:31.000000000 +0200
4.11 ++++ dmalloc-5.5.2/configure 2007-05-18 11:42:02.000000000 +0200
4.12 +@@ -2643,7 +2643,7 @@
4.13 +
4.14 +
4.15 + # see if we actually have a CXX program
4.16 +-if test "$ac_cv_prog_CXX" = "" -o ! -x "$ac_cv_prog_CXX"; then
4.17 ++if test "$ac_cv_prog_CXX" = "" -o ! -x `which "$ac_cv_prog_CXX"`; then
4.18 + { echo "$as_me:$LINENO: WARNING: could not find C++ compiler $ac_cv_prog_CXX" >&5
4.19 + echo "$as_me: WARNING: could not find C++ compiler $ac_cv_prog_CXX" >&2;}
4.20 + enable_cxx=no
5.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
5.2 +++ b/patches/dmalloc/5.5.2/200-mips.patch Fri May 18 15:57:16 2007 +0000
5.3 @@ -0,0 +1,64 @@
5.4 +Patch to correctly handle the MIPS case.
5.5 +
5.6 +It was build up by Yann E. MORIN <yann.morin.1998@anciens.enib.fr> from some
5.7 +bits gathered from buildroot, which is LGPL v2.1
5.8 +License for dmalloc is:
5.9 + * Permission to use, copy, modify, and distribute this software for
5.10 + * any purpose and without fee is hereby granted, provided that the
5.11 + * above copyright notice and this permission notice appear in all
5.12 + * copies, and that the name of Gray Watson not be used in advertising
5.13 + * or publicity pertaining to distribution of the document or software
5.14 + * without specific, written prior permission.
5.15 + *
5.16 + * Gray Watson makes no representations about the suitability of the
5.17 + * software described herein for any purpose. It is provided "as is"
5.18 + * without express or implied warranty.
5.19 +
5.20 +I personnaly believe that the resulting code should therefore be
5.21 +LGPL v2.1, but don't believe me, ask your lawyers!
5.22 +
5.23 +diff -dur dmalloc-5.5.2.orig/configure dmalloc-5.5.2/configure
5.24 +--- dmalloc-5.5.2.orig/configure 2007-05-18 12:15:39.000000000 +0200
5.25 ++++ dmalloc-5.5.2/configure 2007-05-18 12:15:48.000000000 +0200
5.26 +@@ -7107,7 +7107,7 @@
5.27 + echo $ECHO_N "checking return.h macros work... $ECHO_C" >&6
5.28 + if test "$cross_compiling" = yes; then
5.29 + cat >>confdefs.h <<\_ACEOF
5.30 +-#define RETURN_MACROS_WORK 0
5.31 ++#define RETURN_MACROS_WORK 1
5.32 + _ACEOF
5.33 + echo "$as_me:$LINENO: result: no" >&5
5.34 + echo "${ECHO_T}no" >&6
5.35 +diff -dur dmalloc-5.5.2.orig/return.h dmalloc-5.5.2/return.h
5.36 +--- dmalloc-5.5.2.orig/return.h 2007-05-14 19:26:14.000000000 +0200
5.37 ++++ dmalloc-5.5.2/return.h 2007-05-18 12:15:48.000000000 +0200
5.38 +@@ -106,26 +106,16 @@
5.39 + /*************************************/
5.40 +
5.41 + /*
5.42 +- * For DEC Mips machines running Ultrix
5.43 ++ * For Mips machines running Linux
5.44 + */
5.45 + #if __mips
5.46 +
5.47 + /*
5.48 +- * I have no idea how to get inline assembly with the default cc.
5.49 +- * Anyone know how?
5.50 +- */
5.51 +-
5.52 +-#if 0
5.53 +-
5.54 +-/*
5.55 + * NOTE: we assume here that file is global.
5.56 + *
5.57 +- * $31 is the frame pointer. $2 looks to be the return address but maybe
5.58 +- * not consistently.
5.59 ++ * $31 is the return address.
5.60 + */
5.61 +-#define GET_RET_ADDR(file) asm("sw $2, file")
5.62 +-
5.63 +-#endif
5.64 ++#define GET_RET_ADDR(file) asm("sw $31, %0" : "=m" (file))
5.65 +
5.66 + #endif /* __mips */
5.67 +
6.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
6.2 +++ b/patches/dmalloc/5.5.2/300-shared_library.patch Fri May 18 15:57:16 2007 +0000
6.3 @@ -0,0 +1,44 @@
6.4 +This patch makes building the shared library possible.
6.5 +
6.6 +Copyright 2007 Yann E. MORIN <yann.morin.1998@anciens.enib.fr>
6.7 +Licensed to you as dmalloc-5.5.2 is.
6.8 +
6.9 +diff -dur dmalloc-5.5.2.orig/Makefile.in dmalloc-5.5.2/Makefile.in
6.10 +--- dmalloc-5.5.2.orig/Makefile.in 2007-05-14 19:26:14.000000000 +0200
6.11 ++++ dmalloc-5.5.2/Makefile.in 2007-05-18 15:54:04.000000000 +0200
6.12 +@@ -257,7 +257,7 @@
6.13 + # via: http://256.com/gray/email.html
6.14 + $(LIB_SL) : $(LIBRARY)
6.15 + rm -f $@ $@.t
6.16 +- @shlinkargs@ $(LIBRARY) $(OBJS) $(NORMAL_OBJS)
6.17 ++ @shlinkargs@ $(LIBRARY)
6.18 + mv $@.t $@
6.19 +
6.20 + $(LIBRARY) : $(OBJS) $(NORMAL_OBJS)
6.21 +@@ -270,7 +270,7 @@
6.22 +
6.23 + $(LIB_TH_SL) : $(LIB_TH)
6.24 + rm -f $@ $@.t
6.25 +- @shlinkargs@ $(LIB_TH) $(OBJS) $(THREAD_OBJS)
6.26 ++ @shlinkargs@ $(LIB_TH)
6.27 + mv $@.t $@
6.28 +
6.29 + $(LIB_CXX) : $(OBJS) $(NORMAL_OBJS) $(CXX_OBJS)
6.30 +@@ -279,7 +279,7 @@
6.31 +
6.32 + $(LIB_CXX_SL) : $(LIB_CXX)
6.33 + rm -f $@ $@.t
6.34 +- @shlinkargs@ $(LIB_CXX) $(OBJS) $(NORMAL_OBJS) $(CXX_OBJS)
6.35 ++ @shlinkargs@ $(LIB_CXX)
6.36 + mv $@.t $@
6.37 +
6.38 + $(LIB_TH_CXX) : $(OBJS) $(THREAD_OBJS) $(CXX_OBJS)
6.39 +@@ -288,7 +288,7 @@
6.40 +
6.41 + $(LIB_TH_CXX_SL) : $(LIB_TH_CXX)
6.42 + rm -f $@ $@.t
6.43 +- @shlinkargs@ $(LIB_TH_CXX) $(OBJS) $(THREAD_OBJS) $(CXX_OBJS)
6.44 ++ @shlinkargs@ $(LIB_TH_CXX)
6.45 + mv $@.t $@
6.46 +
6.47 + threadssl : $(LIB_TH_SL)
7.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
7.2 +++ b/patches/dmalloc/5.5.2/400-use_DESTDIR.patch Fri May 18 15:57:16 2007 +0000
7.3 @@ -0,0 +1,105 @@
7.4 +Make install rules use DESTDIR.
7.5 +Split installation of the utilitity from the global install.
7.6 +
7.7 +Copyright 2007 Yann E. MORIN <yann.morin.1998@anciens.enib.fr>
7.8 +Licensed to you as dmalloc-5.5.2 is.
7.9 +
7.10 +diff -dur dmalloc-5.5.2.orig/Makefile.in dmalloc-5.5.2/Makefile.in
7.11 +--- dmalloc-5.5.2.orig/Makefile.in 2007-05-18 16:03:31.000000000 +0200
7.12 ++++ dmalloc-5.5.2/Makefile.in 2007-05-18 16:22:59.000000000 +0200
7.13 +@@ -174,66 +174,67 @@
7.14 + # rm -f configure
7.15 +
7.16 + installdirs :
7.17 +- $(srcdir)/mkinstalldirs $(includedir) $(libdir) $(bindir)
7.18 ++ $(srcdir)/mkinstalldirs $(DESTDIR)/$(includedir) $(DESTDIR)/$(libdir) $(DESTDIR)/$(bindir)
7.19 +
7.20 + installincs : $(HFLS)
7.21 +- $(srcdir)/mkinstalldirs $(includedir)
7.22 +- $(INSTALL_DATA) $(HFLS) $(includedir)
7.23 ++ $(srcdir)/mkinstalldirs $(DESTDIR)/$(includedir)
7.24 ++ $(INSTALL_DATA) $(HFLS) $(DESTDIR)/$(includedir)
7.25 +
7.26 + installthsl : $(LIB_TH_SL)
7.27 +- $(srcdir)/mkinstalldirs $(libdir)
7.28 +- $(INSTALL_PROGRAM) $(LIB_TH_SL) $(libdir)
7.29 ++ $(srcdir)/mkinstalldirs $(DESTDIR)/$(libdir)
7.30 ++ $(INSTALL_PROGRAM) $(LIB_TH_SL) $(DESTDIR)/$(libdir)
7.31 +
7.32 + installth : $(INSTALL_THREADS)
7.33 +- $(srcdir)/mkinstalldirs $(libdir)
7.34 +- $(INSTALL_PROGRAM) $(LIB_TH) $(libdir)
7.35 ++ $(srcdir)/mkinstalldirs $(DESTDIR)/$(libdir)
7.36 ++ $(INSTALL_PROGRAM) $(LIB_TH) $(DESTDIR)/$(libdir)
7.37 + @CXX_OFF@ @echo "Enter 'make installthcxx' to install the threaded C++ library"
7.38 + @SL_OFF@ @echo "Enter 'make installthsl' to install the threaded shared-library"
7.39 +
7.40 + installthcxxsl : $(LIB_TH_CXX_SL)
7.41 +- $(srcdir)/mkinstalldirs $(shlibdir)
7.42 +- $(INSTALL_PROGRAM) $(LIB_TH_CXX_SL) $(shlibdir)
7.43 ++ $(srcdir)/mkinstalldirs $(DESTDIR)/$(shlibdir)
7.44 ++ $(INSTALL_PROGRAM) $(LIB_TH_CXX_SL) $(DESTDIR)/$(shlibdir)
7.45 +
7.46 + installthcxx : $(INSTALL_TH_CXX)
7.47 +- $(srcdir)/mkinstalldirs $(libdir)
7.48 +- $(INSTALL_PROGRAM) $(LIB_TH_CXX) $(libdir)
7.49 ++ $(srcdir)/mkinstalldirs $(DESTDIR)/$(libdir)
7.50 ++ $(INSTALL_PROGRAM) $(LIB_TH_CXX) $(DESTDIR)/$(libdir)
7.51 + @SL_OFF@ @echo "Enter 'make installthcxxsl' to install the threaded C++ shared-library"
7.52 +
7.53 + installcxxsl : $(LIB_CXX_SL)
7.54 +- $(srcdir)/mkinstalldirs $(libdir)
7.55 +- $(INSTALL_PROGRAM) $(LIB_CXX_SL) $(libdir)
7.56 ++ $(srcdir)/mkinstalldirs $(DESTDIR)/$(libdir)
7.57 ++ $(INSTALL_PROGRAM) $(LIB_CXX_SL) $(DESTDIR)/$(libdir)
7.58 +
7.59 + installcxx : $(INSTALL_CXX)
7.60 +- $(srcdir)/mkinstalldirs $(libdir)
7.61 +- $(INSTALL_PROGRAM) $(LIB_CXX) $(libdir)
7.62 ++ $(srcdir)/mkinstalldirs $(DESTDIR)/$(libdir)
7.63 ++ $(INSTALL_PROGRAM) $(LIB_CXX) $(DESTDIR)/$(libdir)
7.64 + @TH_OFF@ @echo "Enter 'make installthcxx' to install the threaded C++ library"
7.65 + @SL_OFF@ @echo "Enter 'make installcxxsl' to install the C++ shared-library"
7.66 +
7.67 + installsl : $(LIB_SL)
7.68 +- $(srcdir)/mkinstalldirs $(shlibdir)
7.69 +- $(INSTALL_PROGRAM) $(LIB_SL) $(shlibdir)
7.70 ++ $(srcdir)/mkinstalldirs $(DESTDIR)/$(shlibdir)
7.71 ++ $(INSTALL_PROGRAM) $(LIB_SL) $(DESTDIR)/$(shlibdir)
7.72 + @CXX_OFF@ @echo "Enter 'make installcxxsl' to install the C++ shared-library"
7.73 + @TH_OFF@ @echo "Enter 'make installthsl' to install thread shared-library"
7.74 +
7.75 + installlib : $(INSTALL_LIB)
7.76 +- $(srcdir)/mkinstalldirs $(libdir)
7.77 +- $(INSTALL_PROGRAM) $(LIBRARY) $(libdir)
7.78 +- @RANLIB@ $(libdir)/$(LIBRARY)
7.79 ++ $(srcdir)/mkinstalldirs $(DESTDIR)/$(libdir)
7.80 ++ $(INSTALL_PROGRAM) $(LIBRARY) $(DESTDIR)/$(libdir)
7.81 ++ @RANLIB@ $(DESTDIR)/$(libdir)/$(LIBRARY)
7.82 + @SL_OFF@ @echo "Enter 'make installsl' to install $(LIB_SL) in $(shlibdir)"
7.83 + @CXX_OFF@ @echo "Enter 'make installcxx' to install the C++ library"
7.84 + @TH_OFF@ @echo "Enter 'make installth' to install thread library"
7.85 +
7.86 + installdocs : $(srcdir)/docs/$(HTMLFILE) $(srcdir)/docs/$(TEXIFILE) \
7.87 + $(srcdir)/docs/$(PDFFILE)
7.88 +- $(srcdir)/mkinstalldirs $(docdir)
7.89 +- $(INSTALL_DATA) $(srcdir)/docs/$(HTMLFILE) $(docdir)
7.90 +- $(INSTALL_DATA) $(srcdir)/docs/$(TEXIFILE) $(docdir)
7.91 +- $(INSTALL_DATA) $(srcdir)/docs/$(PDFFILE) $(docdir)
7.92 ++ $(srcdir)/mkinstalldirs $(DESTDIR)/$(docdir)
7.93 ++ $(INSTALL_DATA) $(srcdir)/docs/$(HTMLFILE) $(DESTDIR)/$(docdir)
7.94 ++ $(INSTALL_DATA) $(srcdir)/docs/$(TEXIFILE) $(DESTDIR)/$(docdir)
7.95 ++ $(INSTALL_DATA) $(srcdir)/docs/$(PDFFILE) $(DESTDIR)/$(docdir)
7.96 +
7.97 +-install : installincs installlib $(UTIL)
7.98 +- $(srcdir)/mkinstalldirs $(bindir)
7.99 +- $(INSTALL_PROGRAM) $(UTIL) $(bindir)
7.100 +- @echo "Enter 'make installdocs' to install $(DOCFILES) in $(docdir)"
7.101 ++installutil : $(UTIL)
7.102 ++ $(srcdir)/mkinstalldirs $(DESTDIR)/$(bindir)
7.103 ++ $(INSTALL_PROGRAM) $(UTIL) $(DESTDIR)/$(bindir)
7.104 ++
7.105 ++install : installincs installlib installutil installdocs
7.106 +
7.107 + dmalloc.h.2 : $(srcdir)/configure
7.108 + $(SHELL) $(srcdir)/configure
8.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
8.2 +++ b/scripts/build/debug/dmalloc.sh Fri May 18 15:57:16 2007 +0000
8.3 @@ -0,0 +1,53 @@
8.4 +# Build script for the dmalloc debug library facility
8.5 +
8.6 +is_enabled="${CT_DMALLOC}"
8.7 +
8.8 +do_debug_dmalloc_get() {
8.9 + CT_GetFile "dmalloc-${CT_DMALLOC_VERSION}" http://dmalloc.com/releases/
8.10 +}
8.11 +
8.12 +do_debug_dmalloc_extract() {
8.13 + CT_ExtractAndPatch "dmalloc-${CT_DMALLOC_VERSION}"
8.14 +}
8.15 +
8.16 +do_debug_dmalloc_build() {
8.17 + CT_DoStep INFO "Installing dmalloc"
8.18 + CT_DoLog EXTRA "Configuring dmalloc"
8.19 +
8.20 + mkdir -p "${CT_BUILD_DIR}/build-dmalloc"
8.21 + cd "${CT_BUILD_DIR}/build-dmalloc"
8.22 +
8.23 + extra_config=
8.24 + case "${CT_CC_LANG_CXX}" in
8.25 + y) extra_config="${extra_config} --enable-cxx";;
8.26 + *) extra_config="${extra_config} --disable-cxx";;
8.27 + esac
8.28 + case "${CT_LIBC_THREADS_NONE}" in
8.29 + y) extra_config="${extra_config} --disable-threads";;
8.30 + *) extra_config="${extra_config} --enable-threads";;
8.31 + esac
8.32 + case "${CT_SHARED_LIBS}" in
8.33 + y) extra_config="${extra_config} --enable-shlib";;
8.34 + *) extra_config="${extra_config} --disable-shlib";;
8.35 + esac
8.36 +
8.37 + CT_DoLog DEBUG "Extra config passed: \"${extra_config}\""
8.38 +
8.39 + LD="${CT_TARGET}-ld" \
8.40 + AR="${CT_TARGET}-ar" \
8.41 + "${CT_SRC_DIR}/dmalloc-${CT_DMALLOC_VERSION}/configure" \
8.42 + --prefix=/usr \
8.43 + --build="${CT_BUILD}" \
8.44 + --host="${CT_TARGET}" \
8.45 + ${extra_config} 2>&1 |CT_DoLog ALL
8.46 +
8.47 + CT_DoLog EXTRA "Building dmalloc"
8.48 + make ${PARALLELMFLAGS} 2>&1 |CT_DoLog ALL
8.49 +
8.50 + CT_DoLog EXTRA "Building dmalloc"
8.51 + make DESTDIR="${CT_SYSROOT_DIR}" installincs \
8.52 + installlib 2>&1 |CT_DoLog ALL
8.53 + make DESTDIR="${CT_DEBUG_INSTALL_DIR}" installutil 2>&1 |CT_DoLog ALL
8.54 +
8.55 + CT_EndStep
8.56 +}
9.1 --- a/tools/addToolVersion.sh Fri May 18 15:54:42 2007 +0000
9.2 +++ b/tools/addToolVersion.sh Fri May 18 15:57:16 2007 +0000
9.3 @@ -7,7 +7,8 @@
9.4 cat <<-EOF
9.5 Usage: ${myname} <tool> [option] <version>
9.6 'tool' in one of:
9.7 - --gcc, --binutils, --glibc, --uClibc, --linux, --gdb
9.8 + --gcc, --binutils, --glibc, --uClibc, --linux,
9.9 + --gdb, --dmalloc
9.10
9.11 Valid options for all tools:
9.12 --experimental, -x
9.13 @@ -53,6 +54,7 @@
9.14 --uClibc) cat=LIBC; tool=uClibc; tool_prefix=libc_; tool_suffix=;;
9.15 --linux) cat=KERNEL; tool=linux; tool_prefix=kernel_; tool_suffix=;;
9.16 --gdb) cat=GDB; tool=gdb; tool_prefix=debug/ tool_suffix=;;
9.17 + --dmalloc) cat=DMALLOC; tool=dmalloc; tool_prefix=debug/ tool_suffix=;;
9.18 # Tools options:
9.19 -x|--experimental) EXP=1; OBS=;;
9.20 -o|--obsolete) OBS=1; EXP=;;