Note that there are some explanatory texts on larger screens.

plurals
  1. POR-Perl Install Problems with GCC 4.0: How do you remove unnecessary -arch flags
    primarykey
    data
    text
    <p>I want to install the R-Perl module to use R from within Perl, but am not having success with the command <code>sudo R CMD INSTALL --configure-args='--with-in-perl' RSPerl/</code> as documented here: <a href="http://www.omegahat.org/RSPerl/RFromPerl.html" rel="nofollow">http://www.omegahat.org/RSPerl/RFromPerl.html</a>. I posted earlier regarding this issue, and determined that I was having problems with the new GCC 4.2. However, I'm now using GCC 4.0.1 and am having different issues. Here is the output of the command above:</p> <pre><code>* installing to library ‘/Library/Frameworks/R.framework/Versions/2.13/Resources/library’ * installing *source* package ‘RSPerl’ ... checking for perl... /usr/bin/perl No support for any of the Perl modules from calling Perl from R. ***************************************************** Set PERL5LIB to /Library/Frameworks/R.framework/Versions/2.13/Resources/library/RSPerl/perl ***************************************************** Testing: -F/Library/Frameworks/R.framework/.. -framework R Using '/usr/bin/perl' as the perl executable Perl modules (no): Adding R package to list of Perl modules to enable callbacks to R from Perl Creating the C code for dynamically loading modules with native code for Perl: R modules: R; linking: checking for gcc... gcc checking for C compiler default output file name... a.out checking whether the C compiler works... yes checking whether we are cross compiling... no checking for suffix of executables... checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether gcc accepts -g... yes checking for gcc option to accept ISO C89... none needed Support R in Perl: yes configure: creating ./config.status config.status: creating src/Makevars config.status: creating inst/scripts/RSPerl.csh config.status: creating inst/scripts/RSPerl.bsh config.status: creating src/RinPerlMakefile config.status: creating src/Makefile.PL config.status: creating cleanup config.status: creating src/R.pm config.status: creating R/perl5lib.R making target all in RinPerlMakefile RinPerlMakefile:5: /Library/Frameworks/R.framework/Resources/etc/Makeconf: No such file or directory make: *** No rule to make target `/Library/Frameworks/R.framework/Resources/etc/Makeconf'. Stop. calling make -f Makefile.perl install make: Makefile.perl: No such file or directory make: *** No rule to make target `Makefile.perl'. Stop. chmod: blib/lib/R.pm: No such file or directory Finished configuration ** libs *** arch - x86_64 gcc-4.2 -arch x86_64 -std=gnu99 -I/Library/Frameworks/R.framework/Resources/include -I/Library/Frameworks/R.framework/Resources/include/x86_64 -I. -arch x86_64 -arch i386 -arch ppc -g -pipe -fno-common -DPERL_DARWIN -fno-strict-aliasing -I/usr/local/include -I/System/Library/Perl/5.10.0/darwin-thread-multi-2level/CORE -DPERL_POLLUTE -D_R_=1 -DUSE_R=1 -DUSE_TOPLEVEL_EXEC=1 -DWITH_R_IN_PERL=1 -I/usr/local/include -fPIC -g -O2 -c Converters.c -o Converters.o In file included from /Library/Frameworks/R.framework/Resources/include/R_ext/RS.h:27, from /Library/Frameworks/R.framework/Resources/include/Rdefines.h:26, from RSCommon.h:55, from RSPerl.h:8, from Converters.h:4, from Converters.c:1: /Library/Frameworks/R.framework/Resources/include/Rconfig.h:5:25: error: ppc/Rconfig.h: No such file or directory In file included from RSCommon.h:72, from RSPerl.h:8, from Converters.h:4, from Converters.c:1: /Library/Frameworks/R.framework/Resources/include/Rversion.h:5:26: error: ppc/Rversion.h: No such file or directory In file included from RSPerl.h:8, from Converters.h:4, from Converters.c:1: RSCommon.h:73:28: error: missing binary operator before token "(" lipo: can't open input file: /var/tmp//ccd76npm.out (No such file or directory) make: *** [Converters.o] Error 1 ERROR: compilation failed for package ‘RSPerl’ * removing ‘/Library/Frameworks/R.framework/Versions/2.13/Resources/library/RSPerl’ </code></pre> <p>And here is the config.log contents:</p> <pre><code>This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. It was created by configure, which was generated by GNU Autoconf 2.60. Invocation command line was $ ./configure --with-in-perl ## --------- ## ## Platform. ## ## --------- ## hostname = N01-0006-_MBP.local uname -m = x86_64 uname -r = 10.8.0 uname -s = Darwin uname -v = Darwin Kernel Version 10.8.0: Tue Jun 7 16:32:41 PDT 2011; root:xnu-1504.15.3~1/RELEASE_X86_64 /usr/bin/uname -p = i386 /bin/uname -X = unknown /bin/arch = unknown /usr/bin/arch -k = unknown /usr/convex/getsysinfo = unknown /usr/bin/hostinfo = Mach kernel version: Darwin Kernel Version 10.8.0: Tue Jun 7 16:32:41 PDT 2011; root:xnu-1504.15.3~1/RELEASE_X86_64 Kernel configured for up to 4 processors. 2 processors are physically available. 4 processors are logically available. Processor type: i486 (Intel 80486) Processors active: 0 1 2 3 Primary memory available: 4.00 gigabytes Default processor set: 79 tasks, 365 threads, 4 processors Load average: 0.52, Mach factor: 3.46 /bin/machine = unknown /usr/bin/oslevel = unknown /bin/universe = unknown PATH: /usr/local/bin PATH: /usr/local/sbin PATH: /usr/local/mysql/bin PATH: /opt/local/bin PATH: /opt/local/sbin PATH: /opt/local/bin PATH: /opt/local/sbin PATH: /usr/bin PATH: /bin PATH: /usr/sbin PATH: /sbin PATH: /usr/local/bin PATH: /usr/X11/bin ## ----------- ## ## Core tests. ## ## ----------- ## configure:1645: checking for perl configure:1663: found /usr/bin/perl configure:1675: result: /usr/bin/perl configure:2013: checking for gcc configure:2029: found /usr/bin/gcc configure:2040: result: gcc configure:2278: checking for C compiler version configure:2285: gcc --version &gt;&amp;5 i686-apple-darwin10-gcc-4.0.1 (GCC) 4.0.1 (Apple Inc. build 5494) Copyright (C) 2005 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. configure:2288: $? = 0 configure:2295: gcc -v &gt;&amp;5 Using built-in specs. Target: i686-apple-darwin10 Configured with: /var/tmp/gcc_40/gcc_40-5494~315/src/configure --disable-checking -enable-werror --prefix=/usr --mandir=/share/man --enable-languages=c,objc,c++,obj-c++ --program-transform-name=/^[cg][^.-]*$/s/$/-4.0/ --with-gxx-include-dir=/include/c++/4.0.0 --with-slibdir=/usr/lib --build=i686-apple-darwin10 --with-arch=apple --with-tune=generic --host=i686-apple-darwin10 --target=i686-apple-darwin10 Thread model: posix gcc version 4.0.1 (Apple Inc. build 5494) configure:2298: $? = 0 configure:2305: gcc -V &gt;&amp;5 gcc-4.0: argument to `-V' is missing configure:2308: $? = 1 configure:2331: checking for C compiler default output file name configure:2358: gcc -arch x86_64 -arch i386 -arch ppc -g -pipe -fno-common -DPERL_DARWIN -fno-strict-aliasing -I/usr/local/include -I/System/Library/Perl/5.10.0/darwin-thread-multi-2level/CORE -DPERL_POLLUTE conftest.c &gt;&amp;5 configure:2361: $? = 0 configure:2407: result: a.out configure:2412: checking whether the C compiler works configure:2422: ./a.out configure:2425: $? = 0 configure:2442: result: yes configure:2449: checking whether we are cross compiling configure:2451: result: no configure:2454: checking for suffix of executables configure:2461: gcc -o conftest -arch x86_64 -arch i386 -arch ppc -g -pipe -fno-common -DPERL_DARWIN -fno-strict-aliasing -I/usr/local/include -I/System/Library/Perl/5.10.0/darwin-thread-multi-2level/CORE -DPERL_POLLUTE conftest.c &gt;&amp;5 configure:2464: $? = 0 configure:2488: result: configure:2494: checking for suffix of object files configure:2520: gcc -c -arch x86_64 -arch i386 -arch ppc -g -pipe -fno-common -DPERL_DARWIN -fno-strict-aliasing -I/usr/local/include -I/System/Library/Perl/5.10.0/darwin-thread-multi-2level/CORE -DPERL_POLLUTE conftest.c &gt;&amp;5 configure:2523: $? = 0 configure:2546: result: o configure:2550: checking whether we are using the GNU C compiler configure:2579: gcc -c -arch x86_64 -arch i386 -arch ppc -g -pipe -fno-common -DPERL_DARWIN -fno-strict-aliasing -I/usr/local/include -I/System/Library/Perl/5.10.0/darwin-thread-multi-2level/CORE -DPERL_POLLUTE conftest.c &gt;&amp;5 configure:2585: $? = 0 configure:2592: test -z "$ac_c_werror_flag" || test ! -s conftest.err configure:2595: $? = 0 configure:2602: test -s conftest.o configure:2605: $? = 0 configure:2619: result: yes configure:2624: checking whether gcc accepts -g configure:2654: gcc -c -g conftest.c &gt;&amp;5 configure:2660: $? = 0 configure:2667: test -z "$ac_c_werror_flag" || test ! -s conftest.err configure:2670: $? = 0 configure:2677: test -s conftest.o configure:2680: $? = 0 configure:2810: result: yes configure:2827: checking for gcc option to accept ISO C89 configure:2901: gcc -c -arch x86_64 -arch i386 -arch ppc -g -pipe -fno-common -DPERL_DARWIN -fno-strict-aliasing -I/usr/local/include -I/System/Library/Perl/5.10.0/darwin-thread-multi-2level/CORE -DPERL_POLLUTE conftest.c &gt;&amp;5 configure:2907: $? = 0 configure:2914: test -z "$ac_c_werror_flag" || test ! -s conftest.err configure:2917: $? = 0 configure:2924: test -s conftest.o configure:2927: $? = 0 configure:2947: result: none needed configure:2988: gcc -c -arch x86_64 -arch i386 -arch ppc -g -pipe -fno-common -DPERL_DARWIN -fno-strict-aliasing -I/usr/local/include -I/System/Library/Perl/5.10.0/darwin-thread-multi-2level/CORE -DPERL_POLLUTE conftest.c &gt;&amp;5 configure:2994: $? = 0 configure:3001: test -z "$ac_c_werror_flag" || test ! -s conftest.err configure:3004: $? = 0 configure:3011: test -s conftest.o configure:3014: $? = 0 configure:3211: creating ./config.status ## ---------------------- ## ## Running config.status. ## ## ---------------------- ## This file was extended by config.status, which was generated by GNU Autoconf 2.60. Invocation command line was CONFIG_FILES = CONFIG_HEADERS = CONFIG_LINKS = CONFIG_COMMANDS = $ ./config.status on N01-0006-_MBP.local config.status:584: creating src/Makevars config.status:584: creating inst/scripts/RSPerl.csh config.status:584: creating inst/scripts/RSPerl.bsh config.status:584: creating src/RinPerlMakefile config.status:584: creating src/Makefile.PL config.status:584: creating cleanup config.status:584: creating src/R.pm config.status:584: creating R/perl5lib.R ## ---------------- ## ## Cache variables. ## ## ---------------- ## ac_cv_c_compiler_gnu=yes ac_cv_env_CC_set= ac_cv_env_CC_value= ac_cv_env_CFLAGS_set= ac_cv_env_CFLAGS_value= ac_cv_env_CPPFLAGS_set= ac_cv_env_CPPFLAGS_value= ac_cv_env_LDFLAGS_set= ac_cv_env_LDFLAGS_value= ac_cv_env_build_alias_set= ac_cv_env_build_alias_value= ac_cv_env_host_alias_set= ac_cv_env_host_alias_value= ac_cv_env_target_alias_set= ac_cv_env_target_alias_value= ac_cv_objext=o ac_cv_path_PERL=/usr/bin/perl ac_cv_prog_ac_ct_CC=gcc ac_cv_prog_cc_c89= ac_cv_prog_cc_g=yes ## ----------------- ## ## Output variables. ## ## ----------------- ## CC='gcc' CFLAGS='' CPPFLAGS='' DEFS='-DPACKAGE_NAME=\"\" -DPACKAGE_TARNAME=\"\" -DPACKAGE_VERSION=\"\" -DPACKAGE_STRING=\"\" -DPACKAGE_BUGREPORT=\"\"' ECHO_C='ECHO_N='' ECHO_T='' EXEEXT='' LANGUAGE_DEFS=' -D_R_=1 -DUSE_R=1 -DUSE_TOPLEVEL_EXEC=1 -DWITH_R_IN_PERL=1' LDFLAGS='' LD_PATH='/Library/Frameworks/R.framework/Versions/2.13/Resources/library/RSPerl/libs' LD_PATH_VAR='DYLD_LIBRARY_PATH' LIBOBJS='' LIBS='' LTLIBOBJS='' NO_SUPPORT_R_IN_PERL='0' OBJEXT='o' OTHERLDFLAGS='-F/Library/Frameworks/R.framework/.. -framework R' PACKAGE_BUGREPORT='' PACKAGE_NAME='' PACKAGE_STRING='' PACKAGE_TARNAME='' PACKAGE_VERSION='' PATH_SEPARATOR=':' PERL5_PATH='/Library/Frameworks/R.framework/Versions/2.13/Resources/library/RSPerl/perl' PERL='/usr/bin/perl' PERL_INSTALL_PREFIX='PREFIX=/Library/Frameworks/R.framework/Versions/2.13/Resources/library/RSPerl LIB=/Library/Frameworks/R.framework/Versions/2.13/Resources/library/RSPerl/perl' PERL_LD_MAKE_ARG='LD=/usr/bin/gcc' PERL_MODULE_SO_DIRS='' R_HOME='/Library/Frameworks/R.framework/Resources' R_IN_PERL_DEFINES='-DWITH_R_IN_PERL=1' R_IN_PERL_LIBRARY='RinPerl' R_LIBRARY_DIR='/Library/Frameworks/R.framework/Versions/2.13/Resources/library' R_PACKAGE_DIR='/Library/Frameworks/R.framework/Versions/2.13/Resources/library/RSPerl' R_PERL_MODULES='c("R")' R_SHLIB_CPPFLAGS='-I/Library/Frameworks/R.framework/Resources/include -I/Library/Frameworks/R.framework/Resources/include/x86_64' R_SHLIB_LDFLAGS='-F/Library/Frameworks/R.framework/.. -framework R' R_SO_DIR='-F/Library/Frameworks/R.framework/.. -framework R' SHELL='/bin/sh' ac_ct_CC='gcc' bindir='${exec_prefix}/bin' build_alias='' datadir='${datarootdir}' datarootdir='${prefix}/share' docdir='${datarootdir}/doc/${PACKAGE}' dvidir='${docdir}' exec_prefix='${prefix}' host_alias='' htmldir='${docdir}' includedir='${prefix}/include' infodir='${datarootdir}/info' libdir='${exec_prefix}/lib' libexecdir='${exec_prefix}/libexec' localedir='${datarootdir}/locale' localstatedir='${prefix}/var' mandir='${datarootdir}/man' oldincludedir='/usr/include' pdfdir='${docdir}' prefix='/usr/local' program_transform_name='s,x,x,' psdir='${docdir}' sbindir='${exec_prefix}/sbin' sharedstatedir='${prefix}/com' sysconfdir='${prefix}/etc' target_alias='' configure: exit 0 </code></pre> <p>Based off of some information I read on <a href="http://passingcuriosity.com/2009/installing-pil-on-mac-os-x-leopard/" rel="nofollow">http://passingcuriosity.com/2009/installing-pil-on-mac-os-x-leopard/</a>, I deleted the <code>-arch ppc</code> and <code>-arch i386</code> flags from the gcc call, and it worked without error. However, I am not sure how to edit the source of R-Perl to make sure that when this GCC call runs, it runs without the unnecessary flags. I tried <code>sudo R --arch=x86_64 CMD INSTALL ...</code>, however this does not remove the other architectures from that GCC call still.</p> <p>Any insight those with more experience than I can give would be greatly appreciated. Thank you!</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload