Jump to content

mephisto

Community Members
  • Posts

    7
  • Joined

  • Last visited

Posts posted by mephisto

  1. Sounds like it should be fixed by r14141.

    As for SDL, I could build it with SDK 10.8 and MIN_OSX_VERSION="10.6" (In this case, liblzma is needed on after phase. my W/A for this is using homebrewed one (xz)).

    With SDK 10.9 and MIN_OSX_VERSION="10.6", I couldn't compile it, as I told previously.

    So I guess using SDK 10.8 is better solution to build on Mavericks.

  2. The game won't run yet, it segfaults, we think it's the tinygettext API using STL types and probably some compiler flags are different. Anyway it looks a lot like the same problem which can be encountered on Windows, until we fix tinygettext.

    Sounds like it should be fixed by r14141.

    At last, I could get same result (can build, but segv) as historic_buruno. So this is a report of compilation on Mac OSX 10.9 (Marvericks).

    Environment

    • EDITED: Source code: the latest commit of i18n ("Fixes tinygettext CMake script. Apparently it was only tested for gli…")
    • OS version: Mac OSX 10.9
    • SYSROOT= "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk"
    • CC="clang" CXX="clang++"
    • EDITED: C++ library: libstdc++

    Results

    Other modified things

    • Boost build
      • specify toolset, etc.
      • (./bootstrap.sh --with-toolset=darwin --with-libraries=filesystem,system,signals --prefix=$INSTALL_DIR && ./b2 toolset=darwin cflags="$CFLAGS" cxxflags="-stdlib=libstdc++ $CPPFLAGS" linkflags="-stdlib=libstdc++ -lc++abi $LDFLAGS" ${JOBS} -d2 --layout=tagged --debug-configuration link=static threading=multi variant=release,debug install)
      • maybe, "clang" is also okay at toolset.
      • I guess CPPFLAGS should be CXXFLAG...? :music:
      • without toolset option, boost scripts use gcc/g++ and this cause linker error which is related to boost filesystem on pyrogenesis linking phase (mangling problem?).
    • Premake
      • modified Premake4.lua at premake/build/gmake.macosx as
      • <   CFLAGS    += $(CPPFLAGS) -Wall -Os -mmacosx-version-min=10.4<   CXXFLAGS  += $(CPPFLAGS) -Wall -Os -mmacosx-version-min=10.4<   LDFLAGS   += -Wl,-x -mmacosx-version-min=10.4--->   CFLAGS    += $(CPPFLAGS) -Wall -Os -mmacosx-version-min=$(MIN_OSX_VERSION)>   CXXFLAGS  += $(CPPFLAGS) -Wall -Os -mmacosx-version-min=$(MIN_OSX_VERSION)>   LDFLAGS   += -Wl,-x -mmacosx-version-min=$(MIN_OSX_VERSION)

    BTW, I also whole build with LDFLAGS="-undefined suppress -flat_namespace", this gives me

    dyld: lazy symbol binding failed: Symbol not found: __ZN11tinygettext10Dictionary9translateERKSs  Referenced from: /Users/masamac/work/cc/0ad/leper/0ad/build/workspaces/0ad.app/Contents/MacOS/./pyrogenesis  Expected in: flat namespacedyld: Symbol not found: __ZN11tinygettext10Dictionary9translateERKSs  Referenced from: /Users/masamac/work/cc/0ad/leper/0ad/build/workspaces/0ad.app/Contents/MacOS/./pyrogenesis  Expected in: flat namespace

    on executing pyrogenesis. So, for some reasons "tinygettext::Dictionary::translate(std::string const&)" cannot see from pyrogenesis.

    I also tried otool, install_name_tool -change, and DYLD_LIBRARY_PATH, but they were not working. I don't know why...

  3. Please pull the latest changes from leper's i18n branch. These changes fixed the build for me on OS X Lion.

    Thank you very much and I will check it.

    By the way, In former experiment of mine (against commit: "Fixed generateLongStringTranslations.py ..." by Gallaecio), on OSX 10.9 (Mavericks), I had compile error on compiling SDL. Because SDL uses deleted API (ref. "Fixed bug 2085 - SDL 1.2.15 fails to build on OSX 10.9 Mavericks – deprecated CGDirectPaletteRef was removed

    ", http://hg.libsdl.org/SDL/rev/e9466ead70e5). So I guess some patches are needed for SDL to compile on Mavericks (and my W/A for this is using homebrewed-version of SDL. I confirmed that 0ad.app can play (this is not i18n).)

  4. Posting all errors would also help a bit.

    Uhm... The error is linker error only. So,

    ld: '__ZN4L10nD2Ev' in ../../../binaries/system/libengine.a(L10n.o) contains undefined reference for architecture x86_64clang: error: linker command failed with exit code 1 (use -v to see invocation)make[1]: *** [../../../binaries/system/pyrogenesis] Error 1make: *** [pyrogenesis] Error 2make: *** Waiting for unfinished jobs....

    This is all error messages which I got.

  5. Oh, thank you many replys.

    Actually, I have already installed scons (maybe it is not used?) and compiled libtinygettext.a by hand (due to CMakeFiles/tinygettext.dir/link.txt with modification and copy it into tinygettext/lib.) before trying to compile of i18n.

    'iconv' is expanded in libraries/osx/ and compiled by build script. And I am using icu libraries which is brew installed (by -L/usr/local/opt/icu4c/lib).

    Using actual Japanese characters? If so, you won't be able to check them because our fonts don't contain them yet.

    I guess this is not related to linker error, but I have also such problem in the next step after building i18n. Thank you.

  6. Hi guys.

    I am trying to build pyrogenesis to check my translations (japanese version of .po files from Transifex) are correct. But it was failed because of linker error. So, let me ask.

    I did git clone from https://github.com/leper/0ad.git and also checkout the branch 'i18n'. After struggling, I could compile for codes of branch 'master'. It works fine. I can play this binary.

    Then I am doing compile for codes of branch 'i18n' but I get linker error at linking pyrogenesis and test such as:

    > ld: '__ZN4L10nD2Ev' in ../../../binaries/system/libengine.a(L10n.o) contains undefined reference for architecture x86_64

    Are there any missing libraries which I have to link? I did 'nm -m' for gcc/engine_Release/L10n.o. Yes, there are 118 undefined references but I cannot find what libraries are needed (I guess these must be linked at linking final output (pyrogenesis or test), but It didn't).

    My environment is:

    • Mac OSX 10.9, Xcode 5.
    • The command to build which I executed is `CC="clang" CXX="clang++ -stdlib=libstdc++ -v -idirafter /usr/local/opt/icu4c/include" LDFLAGS="-L/usr/local/opt/icu4c/lib" ./build-osx-bundle.sh` in workspaces directory.
    • ld is executed as follows:

    "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld" -demangle -dynamic -arch x86_64 -macosx_version_min 10.6.0 -o ../../../binaries/system/pyrogenesis -lcrt1.10.6.o -L/usr/local/opt/icu4c/lib -L../../../binaries/system -L../../../libraries/osx/libjpg/lib -L../../../libraries/osx/libpng/lib -L../../../libraries/osx/zlib/lib -L../../../libraries/source/spidermonkey/lib -L../../../libraries/osx/boost/lib -L../../../libraries/source/cxxtest/lib -L../../../libraries/source/enet/lib -L../../../libraries/osx/libcurl/lib -L../../../libraries/source/tinygettext/lib -L../../../libraries/source/valgrind/lib -L../../../libraries/osx/libogg/lib -L../../../libraries/osx/vorbis/lib -L../../../libraries/source/nvtt/lib -L../../../libraries/source/miniupnpc/lib -L/usr/local/lib -L/Users/masamac/work/cc/0ad/leper/0ad/libraries/osx/libxml2/lib -L/Users/masamac/work/cc/0ad/leper/0ad/libraries/osx/zlib/lib -L/Users/masamac/work/cc/0ad/leper/0ad/libraries/osx/libiconv/lib -L/Users/masamac/work/cc/0ad/leper/0ad/libraries/osx/gloox/lib obj/pyrogenesis_Release/main.o -syslibroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk -framework OpenGL -framework OpenAL -framework ApplicationServices -framework Cocoa -framework CoreFoundation ../../../binaries/system/libmocks_real.a ../../../binaries/system/libnetwork.a ../../../binaries/system/liblobby.a ../../../binaries/system/libglooxwrapper.a ../../../binaries/system/libsimulation2.a ../../../binaries/system/libscriptinterface.a ../../../binaries/system/libengine.a ../../../binaries/system/libgraphics.a ../../../binaries/system/libatlas.a ../../../binaries/system/libgui.a ../../../binaries/system/liblowlevel.a ../../../binaries/system/libmongoose.a -lmocks_real -ljpeg -lpng15 -lz -lmozjs185-ps-release -lboost_filesystem-mt -lboost_system-mt -lenet -lcurl -ltinygettext -licui18n -licuuc -lvorbis -lvorbisenc -lvorbisfile -logg -lnvcore -lnvmath -lnvimage -lnvtt -lsquish -lminiupnpc -lpthread -lnetwork -llobby -lglooxwrapper -lsimulation2 -lscriptinterface -lengine -lgraphics -latlas -lgui -llowlevel -lmongoose -lSDLmain -lSDL -framework Cocoa -lxml2 -lz -lpthread -liconv -lm -lresolv -lresolv -lz -lgloox -lstdc++ -lSystem /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/clang/5.0/lib/darwin/libclang_rt.osx.a

×
×
  • Create New...