thrift-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peace <>
Subject Re: OSX - building universal library binaries
Date Fri, 30 Dec 2011 17:24:54 GMT

That would be terrific if you would consider adding an option to build
binaries.  I'll create a ticket in JIRA.

Thanks for the tip on setting the architecture. It's reporting link error
mismatches between i386 and x86_64.  I ran and started from
scratch to rule out stale object files. Is there another argument to inform
the linker of the architecture?

The 'make' output follows (preceding were dozens of similar ld warnings for
other .o files)
ld: warning: ignoring file thrift-t_delphi_generator.o, file was built for
i386 which is not the architecture being linked (x86_64)
ld: warning: ignoring file thrift-t_go_generator.o, file was built for i386
which is not the architecture being linked (x86_64)
Undefined symbols for architecture x86_64:
  "_yylex", referenced from:
      _main in libfl.a(libmain.o)
  "failure(char const*, ...)", referenced from:
in thrift-t_generator.o
ld: symbol(s) not found for architecture x86_64
collect2: ld returned 1 exit status
make[3]: *** [thrift] Error 1


*From:* Jake Farrell <>
*To:* "" <>
*Sent:* Thursday, December 29, 2011 5:01 PM
*Subject:* Re: OSX - building universal library binaries

The thrift build is not setup to create a universal binary currently. if
you would like to create a ticket for this we can take a look at making
this a global configure option. To set the arch you can pass
CPPFLAGS='-arch i386' to configure.  You should be able to use this for
each arch you want to create and then use lipo to combine them into a
universal binary.


On Dec 29, 2011, at 2:43 PM, Peace wrote:

> What is the procedure for creating a universal binary on OSX? That is, a
> libthrift binary that supports i386, x86_64 and ppc. I built it on an OSX
> 10.7.1 system which produces x86_64 binaries by default and
> doesn't accept -arch arguments.
> Hope I didn't miss an existing thread on this. Searched online and scanned
> the list but haven't found a good way to search it.
> Thanks,
> Peace

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message