[sldev] [HELP] Compiling on Mac
izze euler
izzee at hotmail.co.uk
Mon Sep 28 01:28:00 PDT 2009
Instructions for removing fmod can be found here: http://imprudenceviewer.org/wiki/How_to_compile.
Izze
> Subject: Re: [sldev] [HELP] Compiling on Mac
> From: schlenk at uni-oldenburg.de
> Date: Fri, 25 Sep 2009 20:00:24 +0200
> CC: SLDev at lists.secondlife.com
> To: izzee at hotmail.co.uk
>
>
> Am 25.09.2009 um 15:16 schrieb izze euler:
>
> > Hi,
> >
> > I'm trying to compile the Second Life source code on a Mac using
> > XCode, but I get the following error:
> >
> > GCC 4.2 is not compatible with the Mac OS X 10.4 SDK (file
> > audioengine.cpp)
> >
> Just open the project file in xcode and set the used sdk to 10.5 or
> 10.6?
>
> > Does anyone know how I can resolve this?
> >
> > The only change I've made to the source code is to remove Fmod
> > libraries as mentioned on the wiki.
>
> Where is that mentioned, haven't found it when trying to compile
> snowglobe with RLV patches and had some trouble to get it to compile
> with fmod ( duplicate symbols, but fixed it by adding the conflicting
> symbols to the already existing exception list in.)
>
> Should get you started.
>
> I also cranked up the optimization a bit in the CMAKE files, to get a
> faster binary:
>
> Index: indra/cmake/00-Common.cmake
> ===================================================================
> --- indra/cmake/00-Common.cmake (revision 2601)
> +++ indra/cmake/00-Common.cmake (working copy)
> @@ -171,6 +171,7 @@
>
> if (DARWIN)
> add_definitions(-DLL_DARWIN=1)
> + add_definitions(-fvisibility=hidden)
> set(CMAKE_CXX_LINK_FLAGS "-Wl,-headerpad_max_install_names,-
> search_paths_first")
> set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_CXX_LINK_FLAGS}")
> set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -mlong-branch")
> @@ -179,6 +180,8 @@
> # NOTE: it's critical to have both CXX_FLAGS and C_FLAGS covered.
> set(CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O0 $
> {CMAKE_CXX_FLAGS_RELWITHDEBINFO}")
> set(CMAKE_C_FLAGS_RELWITHDEBINFO "-O0 $
> {CMAKE_C_FLAGS_RELWITHDEBINFO}")
> + set(CMAKE_CXX_FLAGS_RELEASE "-Os -mssse3 -mfpmath=sse $
> {CMAKE_CXX_FLAGS_RELEASE}")
> + set(CMAKE_C_FLAGS_RELEASE "-0s -mssse3 -mfpmath=sse $
> {CMAKE_C_FLAGS_RELEASE}")
> endif (DARWIN)
>
>
> Index: indra/cmake/Variables.cmake
> ===================================================================
> --- indra/cmake/Variables.cmake (revision 2601)
> +++ indra/cmake/Variables.cmake (working copy)
> @@ -76,8 +76,8 @@
> # set this dynamically from the build system now -
> # NOTE: wont have a distributable build unless you add this on the
> configure line with:
> # -DCMAKE_OSX_ARCHITECTURES:STRING='i386;ppc'
> - #set(CMAKE_OSX_ARCHITECTURES i386;ppc)
> - set(CMAKE_OSX_SYSROOT /Developer/SDKs/MacOSX10.4u.sdk)
> + set(CMAKE_OSX_ARCHITECTURES i386)
> + set(CMAKE_OSX_SYSROOT /Developer/SDKs/MacOSX10.5.sdk)
> if (CMAKE_OSX_ARCHITECTURES MATCHES "i386" AND
> CMAKE_OSX_ARCHITECTURES MATCHES "ppc")
> set(ARCH universal)
> else (CMAKE_OSX_ARCHITECTURES MATCHES "i386" AND
> CMAKE_OSX_ARCHITECTURES MATCHES "ppc")
>
> Index: indra/newview/fmod_hidden_symbols.exp
> ===================================================================
> --- indra/newview/fmod_hidden_symbols.exp (revision 2601)
> +++ indra/newview/fmod_hidden_symbols.exp (working copy)
> @@ -8,6 +8,7 @@
> __make_words
> _lpc_clear
> _lpc_init
> +__vorbis_block_init
> __vorbis_block_alloc
> __vorbis_block_ripcord
> __vorbis_apply_window
> @@ -18,6 +19,7 @@
> _vorbis_block_clear
> _vorbis_block_init
> _vorbis_dsp_clear
> +_vorbis_synthesis_restart
> _vorbis_synthesis_blockin
> _vorbis_synthesis_init
> _vorbis_synthesis_pcmout
>
> Index: indra/llui/llresmgr.cpp
> ===================================================================
> --- indra/llui/llresmgr.cpp (revision 2601)
> +++ indra/llui/llresmgr.cpp (working copy)
> @@ -253,30 +253,9 @@
> LLLocale locale(LLLocale::USER_LOCALE);
> struct lconv *conv = localeconv();
>
> -#if LL_DARWIN
> - // On the Mac, locale support is broken before 10.4, which causes
> things to go all pear-shaped.
> - // Fake up a conv structure with some reasonable values for the
> fields this function uses.
> - struct lconv fakeconv;
> - if(conv->negative_sign[0] == 0) // Real locales all seem to have
> something here...
> - {
> - fakeconv = *conv; // start with what's there.
> - switch(mLocale)
> - {
> - default: // Unknown -- use the US defaults.
> - case LLLOCALE_USA:
> - case LLLOCALE_UK: // UK ends up being the same as US for the items
> used here.
> - fakeconv.negative_sign = "-";
> - fakeconv.mon_grouping = "\x03\x03\x00"; // commas every 3 digits
> - fakeconv.n_sign_posn = 1; // negative sign before the string
> - break;
> - }
> - conv = &fakeconv;
> - }
> -#endif
> -
> - char* negative_sign = conv->negative_sign;
> - char separator = getMonetaryThousandsSeparator();
> - char* grouping = conv->mon_grouping;
> + const char* negative_sign = conv->negative_sign;
> + const char separator = getMonetaryThousandsSeparator();
> + const char* grouping = conv->mon_grouping;
>
> // Note on mon_grouping:
> // Specifies a string that defines the size of each group of digits
> in formatted monetary quantities.
>
> Index: indra/mac_updater/mac_updater.cpp
> ===================================================================
> --- indra/mac_updater/mac_updater.cpp (revision 2601)
> +++ indra/mac_updater/mac_updater.cpp (working copy)
> @@ -68,9 +68,9 @@
> OSStatus gFailure = noErr;
> Boolean gCancelled = false;
>
> -char *gUpdateURL;
> -char *gProductName;
> -char *gBundleID;
> +const char *gUpdateURL;
> +const char *gProductName;
> +const char *gBundleID;
>
> void *updatethreadproc(void*);
>
> @@ -1048,7 +1048,7 @@
> if(!mountOutput.empty())
> {
> const char *s = mountOutput.c_str();
> - char *prefix = "/dev/";
> + const char *prefix = "/dev/";
> char *sub = strstr(s, prefix);
>
> if(sub != NULL)
>
>
>
>
_________________________________________________________________
MSN straight to your mobile - news, entertainment, videos and more.
http://clk.atdmt.com/UKM/go/147991039/direct/01/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.secondlife.com/pipermail/sldev/attachments/20090928/3bd82c5d/attachment.htm
More information about the SLDev
mailing list