#37647 closed defect (fixed)
R-framework depends on llvm-gcc42 but requires gfortran
Reported by: | gnw3 | Owned by: | kjellpk (Kjell Konis) |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.1.2 |
Keywords: | Cc: | cooljeanius (Eric Gallager) | |
Port: | R-framework |
Description
llvm-gcc42 2336.11_0 no longer provides llvm-gfortran-4.2. As a result, R-framework using compiler default llvm_gcc42 no longer builds, and source installs of R libraries that use fortran will also fail with existing R-framework installs. Not sure whether it is better to use a different compiler or ask that either llvm-gfortran-4.2 be included with llvm-gcc42 or perhaps made a separate package.
Attachments (2)
Change History (14)
comment:1 Changed 12 years ago by gnw3
comment:2 Changed 12 years ago by mf2k (Frank Schima)
Keywords: | gfortran llvm-gcc42 removed |
---|---|
Owner: | changed from macports-tickets@… to kjell.konis@… |
In the future, please Cc the port maintainer(s).
Changed 12 years ago by kjellpk (Kjell Konis)
Attachment: | Portfile.R-framework.diff added |
---|
comment:3 follow-up: 4 Changed 12 years ago by kjellpk (Kjell Konis)
Message to committer: I changed the default compiler to gcc45. If gcc46 or gcc47 would be more appropriate please feel free to change.
The attached patch removes the llvm-gcc42 variant and make gcc45 the default. This was on my list of changes for R 3.0.0 which is due in April but it looks like llvm-gcc42 is twisting my arm. The patch also removes tcltk from the default dependencies to (kind of) address bug #37107 and properly sets OBJCXX in etc/Makeconf to address bug #35845.
comment:4 Changed 12 years ago by crossd@…
Replying to kjell.konis@…:
Message to committer: I changed the default compiler to gcc45. If gcc46 or gcc47 would be more appropriate please feel free to change.
The attached patch removes the llvm-gcc42 variant and make gcc45 the default. This was on my list of changes for R 3.0.0 which is due in April but it looks like llvm-gcc42 is twisting my arm. The patch also removes tcltk from the default dependencies to (kind of) address bug #37107 and properly sets OBJCXX in etc/Makeconf to address bug #35845.
FYI, on my system, I had to add the following to the gcc47 variant:
configure.cflags-append -DOS_OBJECT_USE_OBJC=0
Otherwise, the C compiler ends up trying to parse an Objective-C header file through some transitive inclusion chain. Perhaps there's another way to effect the same thing, but since a patch is pending already....
comment:5 Changed 12 years ago by kjellpk (Kjell Konis)
Thanks, I'll build gcc47 and see if I can reproduce.
comment:6 follow-up: 7 Changed 12 years ago by kjellpk (Kjell Konis)
crossd@... can you be more specific about the problem you encountered? I am able to build R-framework with gcc47 and install packages with out any problems.
comment:7 follow-up: 10 Changed 12 years ago by crossd@…
[Edited for formatting and to mention Xcode version]
Replying to kjell.konis@…:
crossd@... can you be more specific about the problem you encountered? I am able to build R-framework with gcc47 and install packages with out any problems.
Certainly. Here's my system; 10.8.2 and Xcode 4.3.2. The Xcode version is not relevant for the compiler version, since that's clearly gcc47, but perhaps for include files that come with some SDK:
$ uname -a Darwin foo.bar.net 12.2.0 Darwin Kernel Version 12.2.0: Sat Aug 25 00:48:52 PDT 2012; root:xnu-2050.18.24~1/RELEASE_X86_64 x86_64 $ Without calling configure.cflags-append with -DOS_OBJECT_USE_OBJC=0, here's what I get: $ sudo port build R-framework +gcc47 ---> Computing dependencies for R-framework ---> Fetching distfiles for R-framework ---> Verifying checksum(s) for R-framework ---> Extracting R-framework ---> Configuring R-framework ---> Building R-framework Error: org.macports.build for port R-framework returned: command execution failed Please see the log file for port R-framework for details: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_math_R-framework/R-framework/main.log To report a bug, follow the instructions in the guide: http://guide.macports.org/#project.tickets Error: Processing of port R-framework failed $ cat /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_math_R-framework/R-framework/main.log [...snip...] :info:build making X11.d from X11.c :info:build making Rembedded.d from Rembedded.c :info:build making aqua.d from aqua.c :info:build make[3]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_math_R-framework/R-framework/work/R-2.15.2/src/unix' :info:build make[3]: Entering directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_math_R-framework/R-framework/work/R-2.15.2/src/unix' :info:build /opt/local/bin/gcc-mp-4.7 -std=gnu99 -I. -I../../src/include -I../../src/include -I/opt/local/include/X11 -I/opt/local/include -DHAVE_CONFIG_H -fopenmp -fPIC -pipe -O2 -m64 -c dynload.c -o dynload.o :info:build /opt/local/bin/gcc-mp-4.7 -std=gnu99 -I. -I../../src/include -I../../src/include -I/opt/local/include/X11 -I/opt/local/include -DHAVE_CONFIG_H -fopenmp -fPIC -pipe -O2 -m64 -c edit.c -o edit.o :info:build /opt/local/bin/gcc-mp-4.7 -std=gnu99 -I. -I../../src/include -I../../src/include -I/opt/local/include/X11 -I/opt/local/include -DHAVE_CONFIG_H -fopenmp -fPIC -pipe -O2 -m64 -c stubs.c -o stubs.o :info:build /opt/local/bin/gcc-mp-4.7 -std=gnu99 -I. -I../../src/include -I../../src/include -I/opt/local/include/X11 -I/opt/local/include -DHAVE_CONFIG_H -fopenmp -fPIC -pipe -O2 -m64 -c system.c -o system.o :info:build /opt/local/bin/gcc-mp-4.7 -std=gnu99 -I. -I../../src/include -I../../src/include -I/opt/local/include/X11 -I/opt/local/include -DHAVE_CONFIG_H -fopenmp -fPIC -pipe -O2 -m64 -c sys-unix.c -o sys-unix.o :info:build /opt/local/bin/gcc-mp-4.7 -std=gnu99 -I. -I../../src/include -I../../src/include -I/opt/local/include/X11 -I/opt/local/include -DHAVE_CONFIG_H -fopenmp -fPIC -pipe -O2 -m64 -c sys-std.c -o sys-std.o :info:build /opt/local/bin/gcc-mp-4.7 -std=gnu99 -I. -I../../src/include -I../../src/include -I/opt/local/include/X11 -I/opt/local/include -DHAVE_CONFIG_H -fopenmp -fPIC -pipe -O2 -m64 -c X11.c -o X11.o :info:build /opt/local/bin/gcc-mp-4.7 -std=gnu99 -I. -I../../src/include -I../../src/include -I/opt/local/include/X11 -I/opt/local/include -DHAVE_CONFIG_H -fopenmp -fPIC -pipe -O2 -m64 -c Rembedded.c -o Rembedded.o :info:build /opt/local/bin/gcc-mp-4.7 -std=gnu99 -I. -I../../src/include -I../../src/include -I/opt/local/include/X11 -I/opt/local/include -DHAVE_CONFIG_H -fopenmp -fPIC -pipe -O2 -m64 -c aqua.c -o aqua.o :info:build In file included from /System/Library/Frameworks/Foundation.framework/Headers/NSObject.h:5:0, :info:build from /usr/include/os/object.h:74, :info:build from /usr/include/dispatch/dispatch.h:48, :info:build from /System/Library/Frameworks/CoreFoundation.framework/Headers/CFMessagePort.h:11, :info:build from /System/Library/Frameworks/CoreFoundation.framework/Headers/CoreFoundation.h:68, :info:build from /System/Library/Frameworks/CoreServices.framework/Frameworks/CarbonCore.framework/Headers/CarbonCore.h:18, :info:build from /System/Library/Frameworks/CoreServices.framework/Frameworks/AE.framework/Headers/AE.h:20, :info:build from /System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:18, :info:build from /System/Library/Frameworks/ApplicationServices.framework/Headers/ApplicationServices.h:24, :info:build from ../../src/include/R_ext/QuartzDevice.h:101, :info:build from aqua.c:37: :info:build /System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h:409:1: error: stray '@' in program :info:build /System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h:409:2: error: unknown type name 'class' :info:build /System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h:411:28: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token :info:build /System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h:412:44: error: expected declaration specifiers or '...' before 'NSString' :info:build /System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h:414:28: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token :info:build /System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h:415:43: error: expected declaration specifiers or '...' before 'NSString' :info:build /System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h:417:28: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token :info:build /System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h:418:28: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token :info:build /System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h:422:30: error: expected declaration specifiers or '...' before 'NSString' :info:build /System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h:423:31: error: expected declaration specifiers or '...' before 'NSString' :info:build In file included from /System/Library/Frameworks/Foundation.framework/Headers/NSObject.h:6:0, :info:build from /usr/include/os/object.h:74, :info:build from /usr/include/dispatch/dispatch.h:48, :info:build from /System/Library/Frameworks/CoreFoundation.framework/Headers/CFMessagePort.h:11, :info:build from /System/Library/Frameworks/CoreFoundation.framework/Headers/CoreFoundation.h:68, :info:build from /System/Library/Frameworks/CoreServices.framework/Frameworks/CarbonCore.framework/Headers/CarbonCore.h:18, [...snip...]
Thanks!
comment:8 Changed 12 years ago by gnw3
I decided to use +gcc47
on SL.
sudo port -s install R-framework +gcc46
to get:
R-framework @2.15.2_0+accelerate+cairo+gcc47+recommended+tcltk+x11 (active)
After a long session of reinstalling the R packages that wanted the old gfortran dylib this version seems to work properly, but I haven't tried any large calculations or run systematic checks.
I choose gcc47 in part because gcc45 has had some problems building the hdf5 library which I need for netcdf4. Overall, considering linux and mac problem reports for stuff I use, gcc47 seems to have fixed a number of known problems in gcc45 and gcc46, but no doubt has new problems that are yet to be reported, and some of the issues for gcc45 and gcc46 have likely been addressed with recent updates to the compilers or by workarounds in the package sources.
I'd guess that gcc45 will be "stable" and should work well for most users. gcc47 is said to outperform gcc45 in some benchmarks, but may also get more updates, so may take a bit more work down the road. If you do use gcc47 and find problems (and report them), the future will be better for all of us.
I also searched for reports of people building R using dragonegg without much success.
Changed 12 years ago by kjellpk (Kjell Konis)
Attachment: | R-framework_1.Portfile.diff added |
---|
comment:9 Changed 12 years ago by kjellpk (Kjell Konis)
I did a little research into -DOS_OBJECT_USE_OBJC=0 and I can't really see this causing any problems so I decided to add it to the port as suggested above. It's in the just attached R-framework_1.Portfile.diff.
comment:10 Changed 12 years ago by ryandesign (Ryan Carsten Schmidt)
Replying to crossd@…:
Certainly. Here's my system; 10.8.2 and Xcode 4.3.2.
Xcode 4.4 or newer is required for OS X 10.8.x. Xcode 4.6 is recommended.
comment:11 Changed 12 years ago by larryv (Lawrence Velázquez)
Resolution: | → fixed |
---|---|
Status: | new → closed |
For the record, I should also note that installing llvm-gcc42 2336.11_0 will trigger the check for broken packages:
The key line in this log is: