Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Build Fails on Mac OS X Lion #10

Closed
jsnyder opened this Issue Jul 25, 2011 · 8 comments

Comments

Projects
None yet
2 participants
Owner

jsnyder commented Jul 25, 2011

Build fails in libgcc when trying to build:

Configuring in arm-none-eabi/libgcc
configure: creating cache ./config.cache
checking for --enable-version-specific-runtime-libs... no
checking for a BSD-compatible install... /usr/bin/install -c
checking for gawk... gawk
checking build system type... x86_64-apple-darwin11.0.0
checking host system type... arm-none-eabi
checking for arm-none-eabi-ar... /Users/jsnyder/arm-cs-tools/arm-none-eabi/bin/ar
checking for arm-none-eabi-lipo... arm-none-eabi-lipo
checking for arm-none-eabi-nm... /Users/jsnyder/Sources/arm-eabi-toolchain/build/gcc/./gcc/nm
checking for arm-none-eabi-ranlib... /Users/jsnyder/arm-cs-tools/arm-none-eabi/bin/ranlib
checking for arm-none-eabi-strip... /Users/jsnyder/arm-cs-tools/arm-none-eabi/bin/strip
checking whether ln -s works... yes
checking for arm-none-eabi-gcc... /Users/jsnyder/Sources/arm-eabi-toolchain/build/gcc/./gcc/xgcc -B/Users/jsnyder/Sources/arm-eabi-toolchain/build/gcc/./gcc/ -B/Users/jsnyder/arm-cs-tools/arm-none-eabi/bin/ -B/Users/jsnyder/arm-cs-tools/arm-none-eabi/lib/ -isystem /Users/jsnyder/arm-cs-tools/arm-none-eabi/include -isystem /Users/jsnyder/arm-cs-tools/arm-none-eabi/sys-include   
checking for suffix of object files... configure: error: in `/Users/jsnyder/Sources/arm-eabi-toolchain/build/gcc/arm-none-eabi/libgcc':
configure: error: cannot compute suffix of object files: cannot compile
See `config.log' for more details.
make[2]: *** [configure-target-libgcc] Error 1
make[1]: *** [all] Error 2
make: *** [cross-gcc] Error 2
Owner

jsnyder commented Jul 25, 2011

Issue appears to be related to this one: https://trac.macports.org/ticket/29104

Owner

jsnyder commented Jul 25, 2011

Trying the following:
CC=clang make install-cross

This got past building C language GCC. Will update instructions if this successfully works around issue for XCode 4.1.

Owner

jsnyder commented Jul 25, 2011

Looks like that builds everything except for GDB, where clang errors on a null return for a non-null function. Frankly, I agree with it that it should be an error:

ARMword
ARMul_MRC (ARMul_State * state, ARMword instr)
{
  unsigned cpab;
  ARMword result = 0;

  if (! CP_ACCESS_ALLOWED (state, CPNum))
    {
      ARMul_UndefInstr (state, instr);
      return; //                                                        <--- CLANG THROWS A FIT HERE
    }

  cpab = (state->MRC[CPNum]) (state, ARMul_FIRST, instr, &result);
  while (cpab == ARMul_BUSY)
    {
      ARMul_Icycles (state, 1, 0);
      if (IntPending (state))
      {
        cpab = (state->MRC[CPNum]) (state, ARMul_INTERRUPT, instr, 0);
        return (0);
      }
      else
      cpab = (state->MRC[CPNum]) (state, ARMul_BUSY, instr, &result);
    }
  if (cpab == ARMul_CANT)
    {
      ARMul_Abort (state, ARMul_UndefinedInstrV);
      /* Parent will destroy the flags otherwise.  */
      result = ECC;
    }
  else
    {
      BUSUSEDINCPCN;
      ARMul_Ccycles (state, 1, 0);
      ARMul_Icycles (state, 1, 0);
    }

  return result;
}

@jsnyder jsnyder added a commit that referenced this issue Jul 25, 2011

@jsnyder jsnyder Workaround for issue #10 e78ab0f
Owner

jsnyder commented Jul 26, 2011

Since the workaround seems to address this issue for now. I'm going to close this issue until Apple update their compiler.

@jsnyder jsnyder closed this Jul 26, 2011

Hi - I'm having trouble building on OS X 10.7 with Xcode 4.1, and noticed that the changeset for the workaround above only adds a single empty line to the README. I was wondering if something perhaps didn't make it into that commit that should have?

In any event, I've followed your recommendations form the Makefile to build with clang and it chugs along for a quite while until I get:

/Users/liam/dev/arm-eabi-toolchain/build/gcc/./gcc/xgcc -B/Users/liam/dev/arm-eabi-toolchain/build/gcc/./gcc/ -B/Users/liam/arm-cs-tools/arm-none-eabi/bin/ -B/Users/liam/arm-cs-tools/arm-none-eabi/lib/ -isystem /Users/liam/arm-cs-tools/arm-none-eabi/include -isystem /Users/liam/arm-cs-tools/arm-none-eabi/sys-include    -g -O2 -mthumb -march=armv6-m -O2  -g -O2 -DIN_GCC -DCROSS_DIRECTORY_STRUCTURE  -W -Wall -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition  -isystem ./include  -fno-inline -Wno-missing-prototypes -g  -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED -Dinhibit_libc  -I. -I. -I../../.././gcc -I../../../../../gcc-4.5-2011.03/libgcc -I../../../../../gcc-4.5-2011.03/libgcc/. -I../../../../../gcc-4.5-2011.03/libgcc/../gcc -I../../../../../gcc-4.5-2011.03/libgcc/../include  -DHAVE_CC_TLS  -o _fractunsUSAUDI.o -MT _fractunsUSAUDI.o -MD -MP -MF _fractunsUSAUDI.dep -DL_fractuns -DFROM_USA -DTO_UDI -c ../../../../../gcc-4.5-2011.03/libgcc/../gcc/config/fixed-bit.c 
xgcc: error trying to exec '/Users/liam/dev/arm-eabi-toolchain/build/gcc/./gcc/cc1': execv: Permission denied

I apologize in advance for being a bit lame, but I haven't dug into it at all yet - might be something totally silly.

Owner

jsnyder commented Sep 23, 2011

Sorry, that was bad form on my part, I actually made the edit in the
previous commit and then realized I hadn't made a comment or closed
the issue and foolishly just fixed a line editing problem on that one
and marked it as fixing something.

On Fri, Sep 23, 2011 at 10:00 AM, liam
reply@reply.github.com
wrote:

Hi - I'm having trouble building on OS X 10.7 with Xcode 4.1, and noticed that the changeset for the workaround above only adds a single empty line to the README. I was wondering if something perhaps didn't make it into that commit that should have?

In any event, I've followed your recommendations form the Makefile to build with clang and it chugs along for a quite while until I get:

   /Users/liam/dev/arm-eabi-toolchain/build/gcc/./gcc/xgcc -B/Users/liam/dev/arm-eabi-toolchain/build/gcc/./gcc/ -B/Users/liam/arm-cs-tools/arm-none-eabi/bin/ -B/Users/liam/arm-cs-tools/arm-none-eabi/lib/ -isystem /Users/liam/arm-cs-tools/arm-none-eabi/include -isystem /Users/liam/arm-cs-tools/arm-none-eabi/sys-include    -g -O2 -mthumb -march=armv6-m -O2  -g -O2 -DIN_GCC -DCROSS_DIRECTORY_STRUCTURE  -W -Wall -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition  -isystem ./include  -fno-inline -Wno-missing-prototypes -g  -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED -Dinhibit_libc  -I. -I. -I../../.././gcc -I../../../../../gcc-4.5-2011.03/libgcc -I../../../../../gcc-4.5-2011.03/libgcc/. -I../../../../../gcc-4.5-2011.03/libgcc/../gcc -I../../../../../gcc-4.5-2011.03/libgcc/../include  -DHAVE_CC_TLS  -o _fractunsUSAUDI.o -MT _fractunsUSAUDI.o -MD -MP -MF _fractunsUSAUDI.dep -DL_fractuns -DFROM_USA -DTO_UDI -c ../../../../../gcc-4.5-2011.03/libgcc
 /../gcc/config/fixed-bit.c
   xgcc: error trying to exec '/Users/liam/dev/arm-eabi-toolchain/build/gcc/./gcc/cc1': execv: Permission denied

I apologize in advance for being a bit lame, but I haven't dug into it at all yet - might be something totally silly.

I'll have to give this another try to see if I can reproduce what
you've described here. The last error makes it sound like a
permissions issue, but perhaps not?

In any case, you can also try building with:
CC=gcc-4.2 make install-cross

You may want to do a make clean first though to clear out all the
stuff that was partially built with clang though.

-jsnyder

Reply to this email directly or view it on GitHub:
#10 (comment)

Ah, please disregard - I think I had some junk in the target directory that was making it unhappy. I have cleared everything out in there, rebuilt, and things are proceeding beyond that now, based on the instructions in the main README. Thanks, and sorry for the noise!

Owner

jsnyder commented Sep 25, 2011

No problem. I wasn't able to reproduce the issue but didn't get around to a reply after testing a few build options. Glad it's working for you now.

James Snyder
Biomedical Engineering
Northwestern University
http://fanplastic.org/key.txt
ph: (847) 448-0386

On Sep 25, 2011, at 12:48, liamreply@reply.github.com wrote:

Ah, please disregard - I think I had some junk in the target directory that was making it unhappy. I have cleared everything out in there, rebuilt, and things are proceeding beyond that now, based on the instructions in the main README. Thanks, and sorry for the noise!

Reply to this email directly or view it on GitHub:
#10 (comment)

@larstobi larstobi referenced this issue in pebble/arm-eabi-toolchain Mar 18, 2014

Open

Update to release 2013.11 #5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment