[R-SIG-Mac] R-1.7.1 with gcc-3.3 and --with-x

Alex Buerkle buerkla at uwec.edu
Wed Jul 9 10:06:32 MEST 2003


Stefano's change to devQuartz.c gets the build process much further  
along, but it now fails on a conflict in the definition of _xerbla_  
between print.o and vecLib.  For some reason the compiler command for  
this line of the build has "-framework Carbon" in it.

-Alex

----------------- details ---------------

make

[....]

gcc  -I../../src/extra/bzip2 -I../../src/extra/pcre -no-cpp-precomp -I.  
-I../../
src/include -I../../src/include -I/sw/include -I/usr/local/include  
-DHAVE_CONFIG
_H   -g -O2 -c vfonts.c -o vfonts.o
gcc  -I../../src/extra/bzip2 -I../../src/extra/pcre -no-cpp-precomp -I.  
-I../../
src/include -I../../src/include -I/sw/include -I/usr/local/include  
-DHAVE_CONFIG
_H   -g -O2 -c registration.c -o registration.o
g77    -c xxxpr.f -o xxxpr.o
gcc -framework Carbon -mdynamic-no-pic -lcc_dynamic -o R.bin   
CConverters.o Rdyn
load.o RNG.o apply.o arithmetic.o apse.o array.o attrib.o base.o bind.o  
builtin.
o character.o coerce.o colors.o complex.o connections.o context.o cov.o  
cum.o dc
f.o datetime.o debug.o devPS.o devPicTeX.o deparse.o deriv.o devices.o  
dotcode.o
  dounzip.o dstruct.o duplicate.o engine.o envir.o errors.o eval.o  
format.o fouri
er.o gram.o gram-ex.o graphics.o identical.o internet.o iosupport.o  
lapack.o lis
t.o logic.o main.o mapply.o match.o memory.o model.o names.o objects.o  
optim.o o
ptimize.o options.o par.o paste.o pcre.o platform.o plot.o plot3d.o  
plotmath.o p
rint.o printarray.o printvector.o printutils.o qsort.o random.o regex.o  
relop.o
saveload.o scan.o seq.o serialize.o size.o sort.o source.o split.o  
sprintf.o sub
assign.o subscript.o subset.o summary.o unique.o util.o version.o  
vfonts.o regis
tration.o xxxpr.o ../unix/libunix.a ../appl/libappl.a  
../nmath/libnmath.a  -fram
ework vecLib    ../extra/bzip2/libbz2.a ../extra/pcre/libpcre.a -lz  
-lncurses -l
m
ld: warning multiple definitions of symbol _xerbla_
print.o definition of _xerbla_ in section (__TEXT,__text)
/System/Library/Frameworks/vecLib.framework/ 
vecLib(ProjectBuilderMasterObjectFil
e.o) definition of _xerbla_
ld: Undefined symbols:
_dlclose
_dlerror
_dlopen
_dlsym
make[3]: *** [R.bin] Error 1
make[2]: *** [R] Error 2
make[1]: *** [R] Error 1
make: *** [R] Error 1


On Wednesday, Jul 9, 2003, at 05:32 US/Central, Stefano Iacus wrote:

> This should fix the problem:
>
> #ifndef __QUARTZ_DEVICE__
> #define __QUARTZ_DEVICE__
>
>
> #ifdef HAVE_CONFIG_H
> #include <config.h>
> #endif
> #include <Defn.h>
> #include <Graphics.h>
> #include <Rdevices.h>
>
>
> #if defined(__APPLE_CC__) && defined(HAVE_AQUA)
>
> modifying the first lines of src/unix/devQuartz.c
>
> Can you please try?
>
> stefano
>
> On Mercoledì, lug 9, 2003, at 00:10 Europe/Rome, Alex Buerkle wrote:
>
>>
>> Building R-1.7.1 with gcc-3.3 (and g77 3.3) for X11 also fails,  
>> because the Carbon framework is being linked in the build process,  
>> even when the aqua device is not requested (--with-x >> --without-tcltk).
>>
>> It fails because of a problem in Debugging.h, as mentioned in the  
>> other thread on building with aqua.
>>
>> Why is devQuartz.c being compiled if the Aqua device is not requested  
>> (I see it is listed in src/unix/Makefile.in)?  Is this just a matter  
>> of the build process needing to evolve to accommodate both X11 and  
>> Aqua targets on Darwin?
>>
>> Details are below.
>>
>> -Alex Buerkle
>>
>> ---------------
>>
>> sudo gcc_select 3.3
>> export FPICFLAGS='-fno-common'
>> export LDFLAGS='-lcc_dynamic'
>> export MACOS_DEPLOYMENT_TARGET=10.2
>>
>> ./configure --with-blas=-'framework vecLib' --with-lapack --with-x \
>> --without-tcltk
>> [...]
>>
>> make
>> [...]
>> gcc -no-cpp-precomp -I. -I../../src/include -I../../src/include  
>> -I/usr/X11R6/include -I/sw/include -I/usr/local/include  
>> -DHAVE_CONFIG_H   -g -O2 -c devQuartz.c -o devQuartz.o
>> In file included from  
>> /System/Library/Frameworks/CoreServices.framework/Frameworks/ 
>> CarbonCore.framework/Headers/CarbonCore.h:113,
>>                  from  
>> /System/Library/Frameworks/CoreServices.framework/Headers/ 
>> CoreServices.h:21,
>>                  from  
>> /System/Library/Frameworks/Carbon.framework/Headers/Carbon.h:20,
>>                  from devQuartz.c:42:
>> /System/Library/Frameworks/CoreServices.framework/Frameworks/ 
>> CarbonCore.framework/Headers/Debugging.h:285:2: #else without #if
>> /System/Library/Frameworks/CoreServices.framework/Frameworks/ 
>> CarbonCore.framework/Headers/Debugging.h:287:2: #endif without #if
>> /System/Library/Frameworks/CoreServices.framework/Frameworks/ 
>> CarbonCore.framework/Headers/Debugging.h:301:1: missing binary  
>> operator before token "enum"
>> devQuartz.c:1156:1: unterminated #if
>> make[3]: *** [devQuartz.o] Error 1
>> make[2]: *** [R] Error 2
>> make[1]: *** [R] Error 1
>> make: *** [R] Error 1
>>
>> -----------------
>>
>> Commenting out the following lines in configure (the ones pertaining  
>> to the Carbon framework) didn't change the build and I get the same  
>> error:
>>
>> line 17792
>>     ## <FIXME>
>>     ## Needed because currently the Quartz device driver gets linked  
>> to
>>     ## the main binary.  Change once the driver is modularized.
>>     # main_ldflags="-framework Carbon"
>>     ## </FIXME>
>>
>> line 18065
>>     ## <FIXME>
>>     ## We need '-framework Carbon' because currently the Quartz device
>>     ## driver gets linked to the main binary and hence also the R  
>> dylib.
>>     ## Change once the driver is modularized.
>>     separator=""
>> 	#test -z "${separator}" && separator=" "
>> 	#if test -z "${LIBR_LDFLAGS}"; then
>> 	#  LIBR_LDFLAGS="-framework Carbon"
>> 	#else
>> 	#  LIBR_LDFLAGS="${LIBR_LDFLAGS}${separator}-framework Carbon"
>> 	#fi
>>     ## </FIXME>
>>
>> ------------------
>>
>> Incidentally, the configure option --without-aqua does not function  
>> properly at present and instead is equivalent to --with-aqua.
>>
>> _______________________________________________
>> R-SIG-Mac mailing list
>> R-SIG-Mac at stat.math.ethz.ch
>> https://www.stat.math.ethz.ch/mailman/listinfo/r-sig-mac
>>
>
>

~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~^~
C. Alex Buerkle                 Ph:  715-836-3383
Phillips Hall 330               Fax: 715-836-5089
Department of Biology
University of Wisconsin-Eau Claire
Eau Claire, WI 54702-4004
http://www.uwec.edu/buerkla      buerkla at uwec.edu



More information about the R-SIG-Mac mailing list