[R-SIG-Mac] Error compiling 64 bit R-devel on Leopard (package graphics)

Simon Urbanek simon.urbanek at r-project.org
Tue Jun 30 03:10:08 CEST 2009


On Jun 29, 2009, at 3:11 PM, Raphael Gottardo at UBC wrote:

> Hi All,
>
> I am trying to compile R-devel on a new MacPro but I am having some  
> difficulties compiling from source.
> The problem appears when I add the option --with-acqua, see the  
> message error below. If I set --without-acqua, everything is fine.
> I have searched the list for related issues but I could not find  
> anything that would help me. There is an email from Vince Carey with  
> a similar issue, but no fix is posted as far as I could tell.
>

You have forgotten to set OBJC accordingly and thus you get the wrong  
architecture for Obj-C files (see the error message). For an example  
on how to build multiple archs (64-bit is just another architecture)  
see R for Mac FAQ 2.5.

Cheers,
Simon


> Here is the end of the building process:
>
> building package 'utils'
> all.R is unchanged
> make[4]: Nothing to be done for `iconvlist'.
> building package 'grDevices'
> all.R is unchanged
> make[6]: `Makedeps' is up to date.
> gcc -arch x86_64 -std=gnu99 -I../../../../include -I../../../include  
> -I../../../../src/include -DHAVE_CONFIG_H -I/usr/local/include    - 
> fPIC  -g -O2 -c chull.c -o chull.o
> gcc -arch x86_64 -std=gnu99 -I../../../../include -I../../../include  
> -I../../../../src/include -DHAVE_CONFIG_H -I/usr/local/include    - 
> fPIC  -g -O2 -c devNull.c -o devNull.o
> gcc -arch x86_64 -std=gnu99 -I../../../../include -I../../../include  
> -I../../../../src/include -DHAVE_CONFIG_H -I/usr/local/include    - 
> fPIC  -g -O2 -c devPicTeX.c -o devPicTeX.o
> gcc -arch x86_64 -std=gnu99 -I../../../../include -I../../../include  
> -I../../../../src/include -DHAVE_CONFIG_H -I/usr/local/include    - 
> fPIC  -g -O2 -c devPS.c -o devPS.o
> gcc -arch x86_64 -std=gnu99 -I../../../../include -I../../../include  
> -I../../../../src/include -DHAVE_CONFIG_H -I/usr/local/include    - 
> fPIC  -g -O2 -c devQuartz.c -o devQuartz.o
> gcc -arch x86_64 -std=gnu99 -I../../../../include -I../../../include  
> -I../../../../src/include -DHAVE_CONFIG_H -I/usr/local/include    - 
> fPIC  -g -O2 -c init.c -o init.o
> gcc -arch x86_64 -std=gnu99 -I../../../../include -I../../../include  
> -I../../../../src/include -DHAVE_CONFIG_H -I/usr/local/include    - 
> fPIC  -g -O2 -c qdBitmap.c -o qdBitmap.o
> gcc -arch x86_64 -std=gnu99 -I../../../../include -I../../../include  
> -I../../../../src/include -DHAVE_CONFIG_H -I/usr/local/include    - 
> fPIC  -g -O2 -c qdPDF.c -o qdPDF.o
> gcc -I../../../../include -I../../../include -I../../../../src/ 
> include -DHAVE_CONFIG_H -I/usr/local/include   -fPIC  -g -O2 -c  
> qdCocoa.m -o qdCocoa.o
> gcc -arch x86_64 -std=gnu99 -dynamiclib -Wl,- 
> headerpad_max_install_names -undefined dynamic_lookup -single_module  
> -multiply_defined suppress -L/usr/local/lib -o grDevices.so chull.o  
> devNull.o devPicTeX.o devPS.o devQuartz.o init.o qdBitmap.o qdPDF.o  
> qdCocoa.o -framework AppKit -L../../../../lib -lR -Wl,-framework - 
> Wl,CoreFoundation
> ld warning: in qdCocoa.o, file is not of required architecture
> building package 'graphics'
> all.R is unchanged
> Error in dyn.load(file, DLLpath = DLLpath, ...) :
>  unable to load shared library '/Users/gottarr/Downloads/trunk/ 
> library/grDevices/libs/grDevices.so':
>  dlopen(/Users/gottarr/Downloads/trunk/library/grDevices/libs/ 
> grDevices.so, 6): Symbol not found: _QuartzCocoa_DeviceCreate
>  Referenced from: /Users/gottarr/Downloads/trunk/library/grDevices/ 
> libs/grDevices.so
>  Expected in: dynamic lookup
> Calls: <Anonymous> ... namespaceImport -> loadNamespace ->  
> library.dynam -> dyn.load
> Execution halted
> make[4]: *** [mklazy] Error 1
> make[3]: *** [all] Error 2
> make[2]: *** [R] Error 1
> make[1]: *** [R] Error 1
> make: *** [R] Error 1
>
>
> Here is the options that I use during configure:
> ./configure CC='gcc -arch x86_64' CXX='g++ -arch x86_64'  
> F77='gfortran -arch x86_64' FC='gfortran -arch x86_64' --with-blas='- 
> framework vecLib' --with-lapack --with-aqua --with-readline -- 
> without-tcltk --with-system-zlib
>
>
> I have successfully compiled R-devel on my older MacPro running the  
> exact same version of Leopard with gcc/gfortran 4.2, just a few days  
> ago. So I don't really understand what's going on. Am I missing  
> something trivial?
> Note that the new machine I have has a "Nehalem" processor, could  
> this explains the difference?
>
>
> Here are some more info in case you need it:
> got10:trunk gottarr$ sw_versProductName:	Mac OS XProductVersion:	 
> 10.5.7
> BuildVersion:	9J61
> got10:trunk gottarr$ system_profiler | more
> Hardware:
>
>    Hardware Overview:
>
>      Model Name: Mac Pro
>      Model Identifier: MacPro4,1
>      Processor Name: Quad-Core Intel Xeon
>      Processor Speed: 2.93 GHz
>      Number Of Processors: 2
>      Total Number Of Cores: 8
>      L2 Cache (per core): 256 KB
>      L3 Cache (per processor): 8 MB
>      Memory: 16 GB
>      Processor Interconnect Speed: 6.4 GT/s
>      Boot ROM Version: MP41.0081.B04
>      SMC Version (system): 1.39f5
>      SMC Version (processor tray): 1.39f5
>
> Thanks in advance,
>
> Raphael
>
> _______________________________________________
> R-SIG-Mac mailing list
> R-SIG-Mac at stat.math.ethz.ch
> https://stat.ethz.ch/mailman/listinfo/r-sig-mac
>
>



More information about the R-SIG-Mac mailing list