This is the mail archive of the libffi-discuss@sourceware.org mailing list for the libffi project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: -m32 build of libffi head fails on darwin


On 01/15/2015 03:37 PM, Jack Howarth wrote:
> ../src/x86/sysv.S:1005:Rest of line ignored. 1st junk character valued 64 (@).
> Makefile:1230: recipe for target 'src/x86/sysv.lo' failed
> 
> Any ideas on how to fix this issue with sysv,S?

For some reason, the configure test

        echo '.text; foo: nop; .data; .long foo-.; .text' > conftest.s
...
        AC_DEFINE(HAVE_AS_X86_PCREL, 1,
                  [Define if your assembler supports PC relative relocs.])


fails on darwin.  Which leads to

#ifdef HAVE_AS_X86_PCREL
# define PCREL(X)       X - .
#else
# define PCREL(X)       X@rel
#endif

which leads to the error.  Curiously, "X-." does seem to work on Darwin,
and you ought to be able to get sysv.S to compile if you edit that ifdef.

If you could figure out why the assembly works, but the configure test
doesn't, that'd be great.


r~


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]