# port math/fftw broken



## rambetter (Sep 7, 2010)

I know this is an old an crufty port, but it's currently broken (tested on both FreeBSD 6.4 i386 and FreeBSD 8.1 i386, compiling from ports).  I already sent an email to the "maintainer" for this port, which is listed as ports@FreeBSD.org in the Makefile.  Is that the correct way to report a broken port?  Anyhow, the error I'm getting is along these lines:


```
libtool: compile:  gcc44 -DHAVE_CONFIG_H -I. -I. -I. -I. -I./../fftw -I. -O2 -fno-strict-aliasing -pipe -march=pentium4 -Wl,-
rpath=/usr/local/lib/gcc44 -MT wisdomio.lo -MD -MP -MF .deps/wisdomio.Tpo -c wisdomio.c  -fPIC -DPIC -o .libs/wisdomio.o
libtool: compile:  gcc44 -DHAVE_CONFIG_H -I. -I. -I. -I. -I./../fftw -I. -O2 -fno-strict-aliasing -pipe -march=pentium4 -Wl,-
rpath=/usr/local/lib/gcc44 -MT wisdomio.lo -MD -MP -MF .deps/wisdomio.Tpo -c wisdomio.c -o wisdomio.o >/dev/null 2>&1
if /bin/sh /usr/local/bin/libtool --mode=compile gcc44 -DHAVE_CONFIG_H -I. -I. -I. -I. -I./../fftw -I.    -O2 -fno-strict-aliasing -pipe -
march=pentium4 -Wl,-rpath=/usr/local/lib/gcc44 -MT putils.lo -MD -MP -MF ".deps/putils.Tpo" \
          -c -o putils.lo `test -f 'putils.c' || echo './'`putils.c; \
        then mv ".deps/putils.Tpo" ".deps/putils.Plo"; \
        else rm -f ".deps/putils.Tpo"; exit 1; \
        fi
libtool: compile:  gcc44 -DHAVE_CONFIG_H -I. -I. -I. -I. -I./../fftw -I. -O2 -fno-strict-aliasing -pipe -march=pentium4 -Wl,-
rpath=/usr/local/lib/gcc44 -MT putils.lo -MD -MP -MF .deps/putils.Tpo -c putils.c  -fPIC -DPIC -o .libs/putils.o
libtool: compile:  gcc44 -DHAVE_CONFIG_H -I. -I. -I. -I. -I./../fftw -I. -O2 -fno-strict-aliasing -pipe -march=pentium4 -Wl,-
rpath=/usr/local/lib/gcc44 -MT putils.lo -MD -MP -MF .deps/putils.Tpo -c putils.c -o putils.o >/dev/null 2>&1
if /bin/sh /usr/local/bin/libtool --mode=compile gcc44 -DHAVE_CONFIG_H -I. -I. -I. -I. -I./../fftw -I.    -O2 -fno-strict-aliasing -pipe -
march=pentium4 -Wl,-rpath=/usr/local/lib/gcc44 -MT rader.lo -MD -MP -MF ".deps/rader.Tpo" \
          -c -o rader.lo `test -f 'rader.c' || echo './'`rader.c; \
        then mv ".deps/rader.Tpo" ".deps/rader.Plo"; \
        else rm -f ".deps/rader.Tpo"; exit 1; \
        fi
libtool: compile:  gcc44 -DHAVE_CONFIG_H -I. -I. -I. -I. -I./../fftw -I. -O2 -fno-strict-aliasing -pipe -march=pentium4 -Wl,-
rpath=/usr/local/lib/gcc44 -MT rader.lo -MD -MP -MF .deps/rader.Tpo -c rader.c  -fPIC -DPIC -o .libs/rader.o
libtool: compile:  gcc44 -DHAVE_CONFIG_H -I. -I. -I. -I. -I./../fftw -I. -O2 -fno-strict-aliasing -pipe -march=pentium4 -Wl,-
rpath=/usr/local/lib/gcc44 -MT rader.lo -MD -MP -MF .deps/rader.Tpo -c rader.c -o rader.o >/dev/null 2>&1
if /bin/sh /usr/local/bin/libtool --mode=compile gcc44 -DHAVE_CONFIG_H -I. -I. -I. -I. -I./../fftw -I.    -O2 -fno-strict-aliasing -pipe -
march=pentium4 -Wl,-rpath=/usr/local/lib/gcc44 -MT fftwf77.lo -MD -MP -MF ".deps/fftwf77.Tpo" \
          -c -o fftwf77.lo `test -f 'fftwf77.c' || echo './'`fftwf77.c; \
        then mv ".deps/fftwf77.Tpo" ".deps/fftwf77.Plo"; \
        else rm -f ".deps/fftwf77.Tpo"; exit 1; \
        fi
libtool: compile:  gcc44 -DHAVE_CONFIG_H -I. -I. -I. -I. -I./../fftw -I. -O2 -fno-strict-aliasing -pipe -march=pentium4 -Wl,-
rpath=/usr/local/lib/gcc44 -MT fftwf77.lo -MD -MP -MF .deps/fftwf77.Tpo -c fftwf77.c  -fPIC -DPIC -o .libs/fftwf77.o
libtool: compile:  gcc44 -DHAVE_CONFIG_H -I. -I. -I. -I. -I./../fftw -I. -O2 -fno-strict-aliasing -pipe -march=pentium4 -Wl,-
rpath=/usr/local/lib/gcc44 -MT fftwf77.lo -MD -MP -MF .deps/fftwf77.Tpo -c fftwf77.c -o fftwf77.o >/dev/null 2>&1
/bin/sh /usr/local/bin/libtool --mode=link gcc44  -O2 -fno-strict-aliasing -pipe -march=pentium4 -Wl,-rpath=/usr/local/lib/gcc44   -o 
libfftw.la -rpath /usr/local/lib -version-info 2:7:0 fn_1.lo fn_2.lo fn_3.lo fn_4.lo fn_5.lo fn_6.lo fn_7.lo fn_8.lo fn_9.lo fn_10.lo fn_11.lo 
fn_12.lo fn_13.lo fn_14.lo fn_15.lo fn_16.lo fn_32.lo fn_64.lo ftw_2.lo ftw_3.lo ftw_4.lo ftw_5.lo ftw_6.lo ftw_7.lo ftw_8.lo ftw_9.lo 
ftw_10.lo ftw_16.lo ftw_32.lo ftw_64.lo fni_1.lo fni_2.lo fni_3.lo fni_4.lo fni_5.lo fni_6.lo fni_7.lo fni_8.lo fni_9.lo fni_10.lo fni_11.lo 
fni_12.lo fni_13.lo fni_14.lo fni_15.lo fni_16.lo fni_32.lo fni_64.lo ftwi_2.lo ftwi_3.lo ftwi_4.lo ftwi_5.lo ftwi_6.lo ftwi_7.lo ftwi_8.lo 
ftwi_9.lo ftwi_10.lo ftwi_16.lo ftwi_32.lo ftwi_64.lo timer.lo config.lo planner.lo twiddle.lo executor.lo generic.lo fftwnd.lo malloc.lo 
wisdom.lo wisdomio.lo putils.lo rader.lo fftwf77.lo  -lm 
libtool: link: cc -shared  .libs/fn_1.o .libs/fn_2.o .libs/fn_3.o .libs/fn_4.o .libs/fn_5.o .libs/fn_6.o .libs/fn_7.o .libs/fn_8.o .libs/fn_9.o 
.libs/fn_10.o .libs/fn_11.o .libs/fn_12.o .libs/fn_13.o .libs/fn_14.o .libs/fn_15.o .libs/fn_16.o .libs/fn_32.o .libs/fn_64.o .libs/ftw_2.o 
.libs/ftw_3.o .libs/ftw_4.o .libs/ftw_5.o .libs/ftw_6.o .libs/ftw_7.o .libs/ftw_8.o .libs/ftw_9.o .libs/ftw_10.o .libs/ftw_16.o .libs/ftw_32.o 
.libs/ftw_64.o .libs/fni_1.o .libs/fni_2.o .libs/fni_3.o .libs/fni_4.o .libs/fni_5.o .libs/fni_6.o .libs/fni_7.o .libs/fni_8.o .libs/fni_9.o 
.libs/fni_10.o .libs/fni_11.o .libs/fni_12.o .libs/fni_13.o .libs/fni_14.o .libs/fni_15.o .libs/fni_16.o .libs/fni_32.o .libs/fni_64.o 
.libs/ftwi_2.o .libs/ftwi_3.o .libs/ftwi_4.o .libs/ftwi_5.o .libs/ftwi_6.o .libs/ftwi_7.o .libs/ftwi_8.o .libs/ftwi_9.o .libs/ftwi_10.o 
.libs/ftwi_16.o .libs/ftwi_32.o .libs/ftwi_64.o .libs/timer.o .libs/config.o .libs/planner.o .libs/twiddle.o .libs/executor.o .libs/generic.o 
.libs/fftwnd.o .libs/malloc.o .libs/wisdom.o .libs/wisdomio.o .libs/putils.o .libs/rader.o .libs/fftwf77.o   -lm  -march=pentium4 -Wl,-
rpath=/usr/local/lib/gcc44   -Wl,-soname -Wl,libfftw.so.2 -o .libs/libfftw.so.2
.libs/fn_3.o(.text.__i686.get_pc_thunk.bx+0x0): In function `__i686.get_pc_thunk.bx':
: multiple definition of `__i686.get_pc_thunk.bx'
/usr/lib/crtbeginS.o(.gnu.linkonce.t.__i686.get_pc_thunk.bx+0x0): first defined here
gmake[2]: *** [libfftw.la] Error 1
gmake[2]: Leaving directory `/usr/ports/math/fftw/work/fftw-2.1.5/fftw'
gmake[1]: *** [all] Error 2
gmake[1]: Leaving directory `/usr/ports/math/fftw/work/fftw-2.1.5/fftw'
gmake: *** [all-recursive] Error 1
*** Error code 1

Stop in /usr/ports/math/fftw.
```


----------



## SirDice (Sep 7, 2010)

Don't compile it with GCC44. Remove the CFLAGS and other compiler options from /etc/make.conf.


----------



## DutchDaemon (Sep 7, 2010)

And don't report ports as broken when not using the base compilers...


----------



## rambetter (Sep 7, 2010)

I know that it used GCC 4.4, but honestly, I didn't do anything to tell it to explicitly use GCC 4.4 from ports.  On both my FreeBSD 6.4 and 8.1 machines it used GCC 4.4 automatically.  Do you think it's because of options I had in my make.conf?  I doubt it.

I had a look in /usr/ports/math/fftw/Makefile and didn't find anything that mentions GCC.  So why is it using GCC 4.4?  If you try to compile this yourself on a fresh system you might experience the same.

Anyhow I will remove all options from my /etc/make.conf tonight and try to recompile.  Do I need to recompile my entire system now?  Userland, kernel, and all ports?


----------



## rambetter (Sep 7, 2010)

I removed the relevant options from /etc/make.conf from another one of my systems (running FreeBSD 7.1).  (However I didn't recompile the base system and the other ports.)  Tried installing math/fftw and here's what I get:


```
root@speedy# cd /usr/ports/math/fftw
root@speedy# make install clean
===>  License check disabled, port has not defined LICENSE
=> fftw-2.1.5.tar.gz doesn't seem to exist in /usr/ports/distfiles/.
=> Attempting to fetch from ftp://ftp.fftw.org/pub/fftw/.
fftw-2.1.5.tar.gz                             100% of 1227 kB  187 kBps
===>  Extracting for fftw-2.1.5_6
=> MD5 Checksum OK for fftw-2.1.5.tar.gz.
=> SHA256 Checksum OK for fftw-2.1.5.tar.gz.
===>  Patching for fftw-2.1.5_6
===>  Applying FreeBSD patches for fftw-2.1.5_6
===>   fftw-2.1.5_6 depends on executable: gmake - found
===>   fftw-2.1.5_6 depends on executable: gcc44 - not found
===>    Verifying install for gcc44 in /usr/ports/lang/gcc44
Making GCC 4.4.5.20100831 for FreeBSD 7.1  target=i386-portbld-freebsd7.1
===>  License check disabled, port has not defined LICENSE
=> gcc-core-4.4-20100831.tar.bz2 doesn't seem to exist in /usr/ports/distfiles/.
=> Attempting to fetch from ftp://ftp-stud.fht-esslingen.de/pub/Mirrors/sources.redhat.com/gcc/snapshots/4.4-20100831/.
gcc-core-4.4-20100831.tar.bz2                   4% of   21 MB  326 kBps
```

I have no idea why it's trying to use gcc44.

My /etc/make.conf just for compiling this port:


```
#CPUTYPE?=pentium4
#CFLAGS= -O2 -fno-strict-aliasing -pipe
#COPTFLAGS= -O -pipe
WITHOUT_X11=yes
# added by use.perl 2009-12-03 15:20:52
PERL_VERSION=5.8.9
```


----------



## DutchDaemon (Sep 7, 2010)

Guess you're right:

```
[/usr/ports/math/fftw] $ make missing
lang/gcc44
```

The fact that ports@ is the maintainer usually means it's an abandoned port. Mailing that address usually doesn't lead to anything. You *may* get lucky with a package. (That sounds awful.)


----------



## SirDice (Sep 8, 2010)

Try math/fftw3, which is newer and should build fine.


----------

