From: Jeff W. <we...@ya...> - 2004-10-07 23:36:07
|
Robin, I haven't had time to dig into this, but one thing for sure: DO NOT USE ANOTHER DISTRIBUTION OF MESCHACH! I fixed a serious memory leak in that code. I reported it to the maintainers of the package, but I never saw they did anything about it. I will try to find out how the meschach archive you found is different from the one I found (and fixed). At first glance it looks like someone cleaned it up to use ANSI-C, which is good, but I don't know if they fixed the memory leak. Cheers, Jeff Welty Robin Cook wrote: >Ok I seem to have gotten it working by replacing the meschach that is in >gwc-0.20-07.tgz with the mesch12b.tar.gz from >http://www.math.uiowa.edu/~dstewart/meschach/ and changing the >Makefile.in a bit more (see attached Makefile.in.diff.) > >Only difference from what I posted before is this > > >@@ -46,7 +46,7 @@ > cp meschach/meschach.a . > > meschach/meschach.a : >- (cd meschach ; ./configure --with-sparse ; make part1 ; make >part2 ; make part3 ; cp machine.h ..) >+ (cd meschach ; ./configure --with-sparse --with-float ; make >all ; cp machine.h ..) > > test : test.c > $(CC) test.c $(LFLAGS) -g -lrfftw -lfftw -lm -o test > > >Without changing the make parts to make all, I was getting a linking >error of undefined zv_free and zm_free. I also set the --with-float >since the fftw3 is also compiled that way. Not sure if that is correct >or not. > >Though I don't think the configure for meschach 12b is working correctly >because of this error.... > > >cc -DCONFIGDIR=\"/gnome_wave_cleaner/config/\" -DDATADIR=\"/usr/share\" >-DLIBDIR=\"/usr/lib\" -DAPPNAME=\"gnome_wave_cleaner\" -O >-march=athlon-mp -mmmx -mfpmath=sse -msse -m3dnow -pipe -O3 -Wall >-DHAVE_ALSA -DHAVE_FFTW3 -DFFTWPREC=1 `pkg-config --cflags libgnome-2.0 >libgnomeui-2.0 gtk+-2.0` `pkg-config --cflags sndfile` -c -o >soundfile.o soundfile.c >(cd meschach ; ./configure --with-sparse --with-float ; make all ; cp >machine.h ..) >creating cache ./config.cache >checking for acc... no >checking for cc... (cached) no >checking for gcc... (cached) no >checking for cc... (cached) no >configure: error: no acceptable cc found in $PATH >make[2]: Entering directory `/usr/src/gwc-0.20-07/meschach' >make[2]: warning: jobserver unavailable: using -j1. Add `+' to parent >make rule. > > >CuZnDragon >Robin Cook > >On Wed, 2004-10-06 at 23:21 -0500, Robin Cook wrote: > > >>Compiling this with gcc 3.4.2 and glibc 2.3.3 with nptl enabled >> >>================================================= >> >>This really doesn't effect the compiling error but something I needed to >>do. >> >>Modified Makefile.in to not over write my environment variable CFLAGS >>and to not install in /usr/local as this is for a distribution. >> >>see attached patch file Makefile.in.diff >> >>================================================= >> >>Then was getting this error..... >> >>computing machine epsilon(s) >>cc -o macheps dmacheps.c >>./configure: line 675: macheps: command not found >>./configure: line 679: macheps: command not found >>./configure: line 679: macheps: command not found >>./configure: line 679: macheps: command not found >>cc -o macheps fmacheps.c >>./configure: line 687: macheps: command not found >>./configure: line 691: macheps: command not found >>./configure: line 691: macheps: command not found >>./configure: line 691: macheps: command not found >>computing M_MAX_INT >>cc -o maxint maxint.c >>./configure: line 700: maxint: command not found >>./configure: line 704: maxint: command not found >>./configure: line 704: maxint: command not found >>./configure: line 704: maxint: command not found >>checking char \\0 vs. float zeros >> >> >>Fixed by modifying configure in the meschach directory >> >>see attached patch file configure-mach.diff >> >>======================================================================== >> >>Now I am getting this error and not sure how to fix it. >> >>cp meschach/meschach.a . >>cc dialog.o gwc.o audio_device.o audio_edit.o audio_util.o gtkled.o >>gtkledbar.o preferences.o drawing.o amplify.o denoise.o undo.o declick.o >>sample_block.o decrackle.o stat.o dethunk.o i0.o i1.o chbevl.o markers.o >>encode.o soundfile.o -g `pkg-config --cflags --libs libgnome-2.0 >>libgnomeui-2.0 gtk+-2.0` `pkg-config --libs sndfile` meschach.a -lasound >>-lfftw3f -lm -o gwc >>meschach.a(memory.o)(.text+0xa0b): In function `m_resize': >>: undefined reference to `MEM_COPY' >>meschach.a(memory.o)(.text+0xaff): In function `m_resize': >>: undefined reference to `MEM_COPY' >>meschach.a(memory.o)(.text+0xc7b): In function `m_resize': >>: undefined reference to `MEM_COPY' >>meschach.a(matop.o)(.text+0x1055): In function `ms_mltadd': >>: undefined reference to `MEM_COPY' >>meschach.a(matop.o)(.text+0x109b): In function `ms_mltadd': >>: undefined reference to `MEM_COPY' >>meschach.a(matop.o)(.text+0x11ed): more undefined references to >>`MEM_COPY' follow >>meschach.a(machine.o)(.text+0xf9): In function `__zero__': >>: undefined reference to `MEM_ZERO' >>meschach.a(lufactor.o)(.text+0x68f): In function `m_inverse': >>: undefined reference to `MEM_COPY' >>meschach.a(lufactor.o)(.text+0x6ea): In function `m_inverse': >>: undefined reference to `MEM_COPY' >>meschach.a(lufactor.o)(.text+0x75f): In function `m_inverse': >>: undefined reference to `MEM_COPY' >>meschach.a(lufactor.o)(.text+0x86d): In function `m_inverse': >>: undefined reference to `MEM_COPY' >>make[1]: Leaving directory `/usr/src/gwc-0.20-07' >>meschach.a(lufactor.o)(.text+0x956): In function `m_inverse': >>: undefined reference to `MEM_COPY' >>meschach.a(lufactor.o)(.text+0x9b1): more undefined references to >>`MEM_COPY' follow >>meschach.a(sprow.o)(.text+0x3e3): In function `sprow_xpd': >>: undefined reference to `MEM_ZERO' >>meschach.a(sprow.o)(.text+0x1db2): In function `sprow_set_val': >>: undefined reference to `MEM_COPY' >>meschach.a(iter0.o)(.text+0x552): In function `iter_copy2': >>: undefined reference to `MEM_COPY' >>meschach.a(iter0.o)(.text+0x69f): In function `iter_copy': >>: undefined reference to `MEM_COPY' >>meschach.a(copy.o)(.text+0xab): In function `_m_copy': >>: undefined reference to `MEM_COPY' >>meschach.a(copy.o)(.text+0x14c): In function `_v_copy': >>: undefined reference to `MEM_COPY' >>meschach.a(copy.o)(.text+0x205): more undefined references to `MEM_COPY' >>follow >>collect2: ld returned 1 exit status >> >> > > > >------------------------------------------------------------------------ > >--- Makefile.in.orig 2004-10-07 00:26:53.607824232 -0500 >+++ Makefile.in 2004-10-07 00:27:59.232847712 -0500 >@@ -4,7 +4,7 @@ > PREFIX=/usr > SYSCONFDIR=/etc > >-CFLAGS = -DCONFIGDIR=\"/$(APPNAME)/config/\" -DDATADIR=\"$(DATADIR)\" -DLIBDIR=\"$(LIBDIR)\" -DAPPNAME=\"$(APPNAME)\" -O3 -Wall @ALSAHDR@ @FFTWHDR@ @FFTWPREC@ -mcpu=@UNAME_MACHINE@ -march=@UNAME_MACHINE@ `pkg-config --cflags libgnome-2.0 libgnomeui-2.0 gtk+-2.0` `pkg-config --cflags sndfile` >+CFLAGS = -DCONFIGDIR=\"/$(APPNAME)/config/\" -DDATADIR=\"$(DATADIR)\" -DLIBDIR=\"$(LIBDIR)\" -DAPPNAME=\"$(APPNAME)\" @CFLAGS@ -Wall @ALSAHDR@ @FFTWHDR@ @FFTWPREC@ `pkg-config --cflags libgnome-2.0 libgnomeui-2.0 gtk+-2.0` `pkg-config --cflags sndfile` > LFLAGS = -g `pkg-config --cflags --libs libgnome-2.0 libgnomeui-2.0 gtk+-2.0` `pkg-config --libs sndfile` > LIBS= meschach.a @ALSALIB@ @FFTWLIB@ -lm > >@@ -24,7 +24,7 @@ > gwc : $(OBJS) meschach.a > $(CC) $(OBJS) $(LFLAGS) $(LIBS) -o gwc > >-DESTDIR=/usr/local >+DESTDIR=/usr > HELPDIR=$(DATADIR)/gnome/help/$(APPNAME) > > install : gwc >@@ -46,7 +46,7 @@ > cp meschach/meschach.a . > > meschach/meschach.a : >- (cd meschach ; ./configure --with-sparse ; make part1 ; make part2 ; make part3 ; cp machine.h ..) >+ (cd meschach ; ./configure --with-sparse --with-float ; make all ; cp machine.h ..) > > test : test.c > $(CC) test.c $(LFLAGS) -g -lrfftw -lfftw -lm -o test > > |