[R-SIG-Mac] building R under Lion

Kasper Daniel Hansen kasperdanielhansen at gmail.com
Tue Aug 28 23:22:43 CEST 2012


I am running Lion, with the newest version of Xcode, and the 5666
build of gcc+gfortran from Simon's page.  This is on Macbook pro last
generation, with a quad core i7.  I have installed the latest stable
release of Xquartz.

I am building R, not as a framework (--disable-framework), but I am
using --with-blas='-framework vecLib' which at least used to be much
better than the built-in BLAS.

My entire configure call is
../${SRCDIR}/configure SHELL='/bin/bash' \
  --prefix=/usr/local/R/R-${R_VERSION} --disable-R-framework\
  CC="/usr/bin/gcc-4.2 -arch x86_64 -std=gnu99" \
  CFLAGS="-g -O2 -std=gnu99 -march=nocona" \
  CXX="/usr/bin/g++-4.2 -arch x86_64" \
  CXXFLAGS="-g -O2 -march=nocona" \
  OBJC="/usr/bin/gcc-4.2 -arch x86_64" \
  F77="/usr/bin/gfortran-4.2 -arch x86_64" \
  FFLAGS="-g -O2 -march=nocona" \
  FC="/usr/bin/gfortran-4.2 -arch x86_64" \
  FCFLAGS="-g -O2 -march=nocona" \
  --enable-memory-profiling\
  --x-includes=/usr/X11/include --x-libraries=/usr/X11/lib\
  --with-system-zlib\
  --with-blas='-framework vecLib' --with-lapack

When I build R-2.15.1-patched, I get

making internet.d from ../../../../R-2.15.x-src/src/modules/internet/internet.c
In file included from
../../../../R-2.15.x-src/src/modules/lapack/vecLibg95c.c:5:
/System/Library/Frameworks/vecLib.framework/Headers/vecLib.h:22:4:
error: #error "<vecLib/vecLib.h> is deprecated.  Please #include
<Accelerate/Accelerate.h> and link to Accelerate.framework."
make[3]: *** [vecLibg95c.d] Error 1
make[2]: *** [make.lapack] Error 2
make[2]: *** Waiting for unfinished jobs....
making nanoftp.d from ../../../../R-2.15.x-src/src/modules/internet/nanoftp.c

<SNIP>

/usr/bin/gcc-4.2 -arch x86_64 -std=gnu99 -I. -I../../../src/include
-I../../../../R-2.15.x-src/src/include -I/usr/local/include
-DHAVE_CONFIG_H   -fopenmp -fPIC  -g -O2 -std=gnu99 -march=nocona   -c
../../../../R-2.15.x-src/src/modules/internet/sockconn.c -o sockconn.o
/usr/bin/gcc-4.2 -arch x86_64 -std=gnu99 -dynamiclib
-Wl,-headerpad_max_install_names  -undefined dynamic_lookup
-single_module -multiply_defined suppress -L/usr/local/lib -o
internet.so Rhttpd.o Rsock.o internet.o nanoftp.o nanohttp.o sock.o
sockconn.o   -Wl,-framework -Wl,CoreFoundation
mkdir /Users/khansen/build/R/R-2.15.x-build/modules
make[1]: *** [R] Error 1
make: *** [R] Error 1

So it seems that it does not like -framework vecLib.  I tried with
-framework Accelerate, but I get the same error.

My guess is that there is some new thing I have to do here, but I
tried reading the admin guide for R-devel and could not see anything
particular (except I do not need -arch x86_64 anymore).

Thanks,
Kasper



More information about the R-SIG-Mac mailing list