Hi, A possible fix has been to re-install the Xcode command line tools: rpy2 seems now to install and work, though I confess that all the reports of the Xcode tools show no change in version number etc following the re-install. Still, it has worked. Jeremy
On 24 Jan 2013, at 15:55, Jeremy Harbinson <jeremy_harbin...@me.com> wrote: > The previous post ended up with no line breaks - hopefully this one, with > breaks, will be readable. > > Hi, > I have had a problem installing Rpy2 versions 2.1.8 and 2.3.1 and Mac OSX > version 10.8.2 using Xcode 3.2 (this is the version that > is in my 'Developer' directory) and the Enthought Python Distribution. I am > not sure if the problem lies with Rpy2 or with R, > so my apologies if I have made a mistake in posting here. > > When I first tried to instal Rpy2 2.3.1 I got the following error message: > > python setup.py build install > running build > running build_py > running build_ext > /Library/Frameworks/R.framework/Resources/bin/config: line 142: make: command > not found > /Library/Frameworks/R.framework/Resources/bin/config: line 143: make: command > not found > R was not built as a library > Traceback (most recent call last): > File "setup.py", line 372, in <module> > [os.path.join('doc', 'source', 'rpy2_logo.png')])] > File > "/Library/Frameworks/EPD64.framework/Versions/7.3/lib/python2.7/distutils/core.py", > line 152, in setup > dist.run_commands() > File > "/Library/Frameworks/EPD64.framework/Versions/7.3/lib/python2.7/distutils/dist.py", > line 953, in run_commands > self.run_command(cmd) > File > "/Library/Frameworks/EPD64.framework/Versions/7.3/lib/python2.7/distutils/dist.py", > line 972, in run_command > cmd_obj.run() > File > "/Library/Frameworks/EPD64.framework/Versions/7.3/lib/python2.7/distutils/command/build.py", > line 127, in run > self.run_command(cmd_name) > File > "/Library/Frameworks/EPD64.framework/Versions/7.3/lib/python2.7/distutils/cmd.py", > line 326, in run_command > self.distribution.run_command(command) > File > "/Library/Frameworks/EPD64.framework/Versions/7.3/lib/python2.7/distutils/dist.py", > line 971, in run_command > cmd_obj.ensure_finalized() > File > "/Library/Frameworks/EPD64.framework/Versions/7.3/lib/python2.7/distutils/cmd.py", > line 109, in ensure_finalized > self.finalize_options() > File "setup.py", line 111, in finalize_options > config += get_rconfig(r_home, about) > File "setup.py", line 264, in get_rconfig > rc = RConfig.from_string(rconfig) > File "setup.py", line 252, in from_string > + '\nin string\n' + string) > ValueError: Invalid substring > > in string > > > This is a reasonably widely reported problem. I got the same result with rpy > 2.1.8. I checked I had a 'make' and I checked the > path statement in my Terminal app and sure enough the directory (there were > two) in which make was located was not in the path, > so I added one to the Terminal window path (hopefully this was the right > thing to do). Repeating the install, but using a > different procedure, in a terminal wondow with the new path allowed the > install to proceed further, but still ending in an > error: > > sudo easy_install rpy2 > Password: > Searching for rpy2 > Reading http://pypi.python.org/simple/rpy2/ > Reading http://rpy.sourceforge.net > Best match: rpy2 2.3.1 > Downloading > http://pypi.python.org/packages/source/r/rpy2/rpy2-2.3.1.tar.gz#md5=8d68dbd8947931975304dc633bbb843c > Processing rpy2-2.3.1.tar.gz > Writing /tmp/easy_install-66vvZU/rpy2-2.3.1/setup.cfg > Running rpy2-2.3.1/setup.py -q bdist_egg --dist-dir > /tmp/easy_install-66vvZU/rpy2-2.3.1/egg-dist-tmp-xJsNct > > returned an empty string. > > > returned an empty string. > > Configuration for R as a library: > include_dirs: ('/Library/Frameworks/R.framework/Resources/include', > '/Library/Frameworks/R.framework/Resources/include/i386') > libraries: () > library_dirs: ('/Library/Frameworks/R.framework/Resources/lib/i386',) > extra_link_args: ('-framework R', '-F/Library/Frameworks/R.framework/..') > # OSX-specific (included in extra_link_args) > framework_dirs: ('-F/Library/Frameworks/R.framework/..',) > frameworks: ('-framework R',) > warning: no previously-included files matching '*patch*' found anywhere in > distribution > warning: no previously-included files matching '*diff*' found anywhere in > distribution > warning: no previously-included files matching '.hg' found anywhere in > distribution > no previously-included directories found matching 'dist' > ./rpy/rinterface/_rinterface.c: In function ‘init_rinterface’: > ./rpy/rinterface/_rinterface.c:3550: warning: passing argument 1 of > ‘PyLong_FromLong’ makes integer from pointer without a cast > ld: library not found for -lbundle1.o > collect2: ld returned 1 exit status > error: Setup script exited with error: command 'gcc' failed with exit status 1 > > > Searching for the -lbundle1.o message on the web got some hits: > > http://lists.apple.com/archives/darwin-dev/2011/Apr/msg00018.html > > The suggestion was to replace the -l switch with the full path to bundle1.o > except I cannot find any reference to bundle1.oin > the rpy2 code. There is, nonetheless, a bundle1.o on my system: > > /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk/usr/lib/bundle1.o > > but this path is not in the path of my Terminal window. I could add it, but I > guess I find it odd that this should necessary and > I wonder if something else is going wrong. Maybe my Xcode installation is > broken, or I am doing something fundamentally > misguided. I have little experience of compiling code so I also feel that at > the moment I am just tampering with things > in a rather naive way > > all the best, > Jeremy ------------------------------------------------------------------------------ Master Visual Studio, SharePoint, SQL, ASP.NET, C# 2012, HTML5, CSS, MVC, Windows 8 Apps, JavaScript and much more. Keep your skills current with LearnDevNow - 3,200 step-by-step video tutorials by Microsoft MVPs and experts. ON SALE this month only -- learn more at: http://p.sf.net/sfu/learnnow-d2d _______________________________________________ rpy-list mailing list rpy-list@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rpy-list