I run on three different machines, two 2009 Mac Pros and a late 2008 Macbook Pro. They are configured as similarly as possible (not counting hardware), all now running OS X 10.6.8. I recently tried to "get current" with the 4.7.4 version of the link parser, and have the following odd problem.
On the Macbook Pro, everything works fine. I downloaded the .gz file, expanded it, moved into that directory, ran ./configure without errors, ran make and then sudo make install, and all is as it should be. However, repeating the same steps on either Mac Pro causes an error during the ./configure process:
> checking for a BSD-compatible install... /usr/bin/install -c
> checking whether build environment is sane... yes
> checking for a thread-safe mkdir -p... ./install-sh -c -d
> checking for gawk... no
> checking for mawk... no
> checking for nawk... no
> checking for awk... awk
> checking whether make sets $(MAKE)... yes
> checking whether to enable maintainer-specific portions of Makefiles... no
> checking for style of include used by make... GNU
> checking for gcc... gcc
> checking for C compiler default output file name...
> configure: error: in `/Users/psz/Downloads/link-grammar-4.7.4':
> configure: error: C compiler cannot create executables
> See `config.log' for more details.
>
config.log contains the following:
> configure:3097: gcc conftest.c >&5
> ld: library not found for -lcrt1.10.6.o
> collect2: ld returned 1 exit status
>
After this, of course, make fails with tons of errors.
However, when I do a find on "crt1.10.6.o", I discover that on both machines the file exists at
/Developer/SDKs/MacOSX10.6.sdk/usr/lib/crt1.10.6.o
I have also checked that the two files are identical. I have also checked, and the shell's PATH on both systems is the same, though neither seems to include these Mac OS X SDK directories.
In addition, I have tried to copy the directory after the ./config from my Macbook Pro to a Mac Pro and then do make there, but that fails as well.
I cannot explain what the difference(s) might be between these systems, or why I am unable to build the link parser on either Mac Pro.
Solutions or guidance would be much appreciated. Thank you. --Peter Szolovits
If you look at the lines just above configure:3097 you will see
that its trying to compile a program that looks like this:
int
main ()
{
;
return 0;
}
using gcc ... and this fails. If you do this from the command line,
does it work?
The location of such low-level files is usually wired in deeply into gcc, at
the time that it got installed. Did you change/modify gcc recently? Upgrade?
such paths can be over-ridden with LD_LIBRARY_PATH (or the analogous
on Macs), and can be specified in /etc/ldconfig.conf (or analogous) but
these shouldn't really require tweaking.
--linas
> --
> You received this message because you are subscribed to the Google Groups "link-grammar" group.
> To post to this group, send email to link-g...@googlegroups.com.
> To unsubscribe from this group, send email to link-grammar...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/link-grammar?hl=en.
>
>
--linas
On 28 June 2011 11:12, Peter Szolovits <p...@mit.edu> wrote:
export C_INCLUDE_PATH=/Developer/SDKs/MacOSX10.6.sdk/usr/include
export LIBRARY_PATH=/Developer/SDKs/MacOSX10.6.sdk/usr/lib
(actually, the advice was older, and for 10.5, but I can transpose!) This works. I'm still mystified why I was having this problem on the Mac Pros but not the Macbook Pro. But at least I'm back in operation. Thanks again. --Pete
On 29 June 2011 05:22, Peter Szolovits <p...@mit.edu> wrote:
> Thank you very much. Googling the problem helped, as I found a suggestion to add the following lines to my .profile file:
>
> export C_INCLUDE_PATH=/Developer/SDKs/MacOSX10.6.sdk/usr/include
>
> export LIBRARY_PATH=/Developer/SDKs/MacOSX10.6.sdk/usr/lib
>
> (actually, the advice was older, and for 10.5, but I can transpose!) This works. I'm still mystified why I was having this problem on the Mac Pros but not the Macbook Pro. But at least I'm back in operation. Thanks again. --Pete
If you're working with dynamic libraries, it may be worth reading
about dyld and DYLD_LIBRARY_PATH at some point. I had to use these
extensively in porting a large project to OSX 10.6 (OpenCog).
J