Am 06.05.2014 um 08:21 schrieb Daiki Ueno: > Peter Dyballa <[email protected]> writes: > >> time env LANG=C >> PATH=/Developer45/usr/bin:/usr/local/texlive/2013/bin/x86_64-darwin:$PATH >> ./configure --target=ppc-apple-darwin10.8.0 --build=i686-apple-darwin10.8.0 >> --prefix=.../wp2latex.3.65/build --libdir=.../wp2latex.3.65/build/lib-G4 >> --enable-shared=no --disable-csharp --disable-openmp --disable-acl >> --disable-libasprintf --disable-rpath --with-pic >> CPPFLAGS="-I.../wp2latex.3.65/build/include" CFLAGS="-arch ppc -isysroot >> /Developer45/SDKs/MacOSX10.4u.sdk -mmacosx-version-min=10.4 -mcpu=G4 -m32 -H >> -pipe -fPIC -fast -mtune=G4 -mpowerpc-gfxopt -faltivec -maltivec >> -mabi=altivec -pthread -finline-functions" LDFLAGS="-arch ppc >> -Wl,-dead_strip_dylibs -Wl,-bind_at_load -Wl,-t" CC=gcc-4.0 CPP=cpp-4.0 >> CXX=g++-4.0 CXXCPP="g++-4.0 -E" LD=gcc-4.0 OBJDUMP=gobjdump > > I'm totally unfamiliar with the cross compiling on Mac OS X, but is the > above supposed to work?
Yes! The Apple augmented GCC is invoked N times to produce N different object files. The the Apple tool lipo is used to stitch the N object files to one big fat object file. And also to build one big fat library from N platform related libraries. This works with libiconv or libunistring, and I also produce the WP2LaTeX Mac binaries this way. > > Are you able to check what is happening there by writing some small test > programs? For example, similar to the one used in the configure script: > > $ cat >test-unsetenv.c <<EOF > #undef _BSD > #define _BSD 1 /* unhide unsetenv declaration in OSF/1 5.1 <stdlib.h> */ > #include <stdlib.h> > extern > #ifdef __cplusplus > "C" > #endif > int unsetenv (const char *name); > EOF > > $ gcc ...ppc64 CFLAGS... -c test-unsetenv.c I almost forgot my skills of a C programmer, but I still can compile C or C++ source files (better than ever). There is also the opportunity to compile the test files on my PowerBook G4 (with a Motorola/Freescale PowerPC 7447A processor). Then we could find whether the SDKs for cross-compilation are OK or not. -- Greetings Pete A blizzard is when it snows sideways.
