X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=SConstruct;h=79ac56b6f028e554a2d7df0a8372a87b9660f996;hb=a48a83ae5a017d103d9a410d8f63beb0ae918247;hp=160cd1f26ecd2bb72507efc747921de08561f983;hpb=e878b365193ad9315e557a8245b767d8a0fe568d;p=ardour.git diff --git a/SConstruct b/SConstruct index 160cd1f26e..79ac56b6f0 100644 --- a/SConstruct +++ b/SConstruct @@ -41,9 +41,10 @@ opts.AddOptions( PathOption('PREFIX', 'Set the install "prefix"', '/usr/local'), BoolOption('SURFACES', 'Build support for control surfaces', 1), BoolOption('SYSLIBS', 'USE AT YOUR OWN RISK: CANCELS ALL SUPPORT FROM ARDOUR AUTHORS: Use existing system versions of various libraries instead of internal ones', 0), + BoolOption('UNIVERSAL', 'Compile as universal binary. Requires that external libraries are already universal.', 0), BoolOption('VERSIONED', 'Add revision information to ardour/gtk executable name inside the build directory', 0), BoolOption('VST', 'Compile with support for VST', 0), - BoolOption('TRANZPORT', 'Compile with support for Frontier Designs (if libusb is available)', 0) + BoolOption('TRANZPORT', 'Compile with support for Frontier Designs (if libusb is available)', 1) ) #---------------------------------------------------------------------- @@ -660,14 +661,19 @@ opt_flags[:0] = [ "-fomit-frame-pointer", "-ffast-math", "-fstrength-reduce", - "-fno-strict-aliasing", "-pipe" ] if env['DEBUG'] == 1: env.Append(CCFLAGS=" ".join (debug_flags)) + env.Append(LINKFLAGS=" ".join (debug_flags)) else: env.Append(CCFLAGS=" ".join (opt_flags)) + env.Append(LINKFLAGS=" ".join (opt_flags)) + +if env['UNIVERSAL'] == 1: + env.Append(CCFLAGS="-arch i386 -arch ppc") + env.Append(LINKFLAGS="-arch i386 -arch ppc") # # warnings flags @@ -677,8 +683,9 @@ env.Append(CCFLAGS="-Wall") env.Append(CXXFLAGS="-Woverloaded-virtual") if env['EXTRA_WARN']: - env.Append(CCFLAGS="-Wextra -pedantic") + env.Append(CCFLAGS="-Wextra -pedantic -ansi") env.Append(CXXFLAGS="-ansi") +# env.Append(CFLAGS="-iso") if env['LIBLO']: env.Append(CCFLAGS="-DHAVE_LIBLO") @@ -831,7 +838,7 @@ if env['SYSLIBS']: libraries['sndfile-ardour'] = LibraryInfo(LIBS='libsndfile-ardour', LIBPATH='#libs/libsndfile', - CPPPATH=['#libs/libsndfile', '#libs/libsndfile/src']) + CPPPATH=['#libs/libsndfile/src']) # libraries['libglademm'] = LibraryInfo() # libraries['libglademm'].ParseConfig ('pkg-config --cflags --libs libglademm-2.4') @@ -955,7 +962,10 @@ surface_subdirs = [ 'libs/surfaces/control_protocol', 'libs/surfaces/generic_mid if env['SURFACES']: if have_libusb: - env['TRANZPORT'] = 'yes' + env['TRANZPORT'] = 1 + else: + env['TRANZPORT'] = 0 + print 'Disabled building Tranzport code because libusb could not be found' if os.access ('libs/surfaces/sony9pin', os.F_OK): surface_subdirs += [ 'libs/surfaces/sony9pin' ]