Loading ...
Sorry, an error occurred while loading the content.

10.4 cross-compilation on 10.5

Expand Messages
  • Jjgod Jiang
    Hi, Ff we use the current configure script of vim, ./configure --with-mac-arch=both will not be able to found the 10.4u SDK correctly, because 10.5 has a bug
    Message 1 of 1 , Nov 2, 2007
    • 0 Attachment
      Hi,

      Ff we use the current configure script of vim, ./configure --with-mac-arch=both
      will not be able to found the 10.4u SDK correctly, because 10.5 has a bug on
      10.4 compilation, this bug can be demonstrated like this:

      $ vi hello.c # put some simple C code into hello.c
      $ gcc -isysroot /Developer/SDKs/MacOSX10.4u.sdk hello.c
      ld: library not found for -lcrt1.10.5.o
      collect2: ld returned 1 exit status

      But

      $ gcc -c -isysroot /Developer/SDKs/MacOSX10.4u.sdk hello.c
      $ gcc hello.o

      succeed.

      so we have to:

      $ sudo ln -s /Developer/SDKs/MacOSX10.4u.sdk/usr/lib/crt1.o
      /Developer/SDKs/MacOSX10.4u.sdk/usr/lib/crt1.10.5.o

      Now

      $ gcc -isysroot /Developer/SDKs/MacOSX10.4u.sdk hello.c

      succeed without an error. This problem will cause

      $ ./configure ... --with-mac-arch=both
      ...
      checking for 10.4 universal SDK... not found
      ...

      Now we have two options:

      1. Use /Developer/SDKs/MacOSX10.5.sdk instead of
      /Developer/SDKs/MacOSX10.4u.sdk if the former exists.
      (or maybe we can add an option to configure, allow the user to specify
      which SDK he wants to use)
      2. Reminds everyone who wants to build an universal binary to make
      that symbol link first.

      - Jiang

      --~--~---------~--~----~------------~-------~--~----~
      You received this message from the "vim_mac" maillist.
      For more information, visit http://www.vim.org/maillist.php
      -~----------~----~----~----~------~----~------~--~---
    Your message has been successfully submitted and would be delivered to recipients shortly.