Changeset 527
- Timestamp:
- 08/20/07 09:57:14 (16 years ago)
- Files:
-
- branches/libffado-scons_porting_work/config.h.in (modified) (1 diff)
- branches/libffado-scons_porting_work/SConstruct (modified) (5 diffs)
- branches/libffado-scons_porting_work/src/devicemanager.cpp (modified) (2 diffs)
- branches/libffado-scons_porting_work/src/SConscript (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
branches/libffado-scons_porting_work/config.h.in
r526 r527 25 25 #define VERSION "$VERSION" 26 26 27 #define CACHEDIR "$cachedir" 28 branches/libffado-scons_porting_work/SConstruct
r526 r527 43 43 opts.Save( "cache/options.cache", env ) 44 44 45 #env.Append( CCFLAGS = "-Wall -Werror -g -fpic" )46 45 env.Append( CCFLAGS = "-Wall -g -fpic" ) 47 48 46 49 47 if not env.GetOption('clean'): … … 76 74 env.AppendUnique( CCFLAGS=["-DDEBUG"] ) 77 75 78 env.AppendUnique( CCFLAGS=['-DCACHEDIR=\'\".\"\''] )79 80 76 if env['ENABLE_BEBOB']: 81 77 env.AppendUnique( CCFLAGS=["-DENABLE_BEBOB"] ) … … 98 94 env.MergeFlags( ["!pkg-config --cflags --libs liblo"] ) 99 95 96 #env.AppendUnique( CCFLAGS = "-Wall -Werror -g -fpic" ) 97 env.AppendUnique( CCFLAGS = env.Split("-Wall -g -fpic") ) 98 #env.AppendUnique( LINKFLAGS = env.Split("-Wl,-rpath $libdir -Wl,soname -Wl,libffado.so.1") ) 99 100 100 101 101 # … … 103 103 env.AppendUnique( CPPPATH=["#/"] ) 104 104 105 env['bindir'] = env['PREFIX'] + "/bin" 106 env['libdir'] = env['PREFIX'] + "/lib" 107 env['includedir'] = env['PREFIX'] + "/include" 105 env['bindir'] = os.path.join( env['PREFIX'], "bin" ) 106 env['libdir'] = os.path.join( env['PREFIX'], "lib" ) 107 env['includedir'] = os.path.join( env['PREFIX'], "include" ) 108 env['cachedir'] = os.path.join( env['PREFIX'] + "var/cache/libffado" ) 108 109 109 110 env.Alias( "install", env['libdir'] ) … … 122 123 env.Alias( "install", env.Install( env['libdir'] + '/pkgconfig', pkgconfig ) ) 123 124 125 if not os.path.exists( env['cachedir'] ): 126 env.Alias( "install", os.makedirs( env["cachedir"] ) ) 127 124 128 env.SConscript( dirs=['src','libffado','tests','support'], exports="env" ) 125 129 branches/libffado-scons_porting_work/src/devicemanager.cpp
r516 r527 23 23 */ 24 24 25 #include "config.h" 26 25 27 #include "fbtypes.h" 26 28 … … 520 522 Glib::ustring cachePath; 521 523 char* pCachePath; 522 if ( asprintf( &pCachePath, "%s/ cache/libffado/", CACHEDIR ) < 0 ) {524 if ( asprintf( &pCachePath, "%s/libffado/", CACHEDIR ) < 0 ) { 523 525 debugError( "Could not create path string for cache pool (trying '/var/cache/libffado' instead)\n" ); 524 526 cachePath == "/var/cache/libffado/"; branches/libffado-scons_porting_work/src/SConscript
r526 r527 5 5 Import( 'env' ) 6 6 7 env = env.Copy()7 env.AppendUnique( CPPPATH=["#/", "#/src"] ) 8 8 9 env .AppendUnique( CPPPATH=["#/src"])9 env1 = env.Copy() 10 10 11 11 ffado_source = env.Split( '\ … … 117 117 source += bounce_source 118 118 119 ffadolib = env.SharedLibrary( "ffado", source ) 119 env1.AppendUnique( LINKFLAGS = env.Split("-Wl,-rpath $libdir -Wl,-soname -Wl,libffado.so.1 --version-info=1:0:0") ) 120 ffadolib = env1.SharedLibrary( "ffado", source ) 120 121 121 env.Alias( "install", env.InstallAs( os.path.join('$libdir','libffado.so.$LIBVERSION'), ffadolib ) ) 122 env.Ignore( ffadolib, os.path.join('$libdir','libffado.so') ) 123 #env.Ignore( os.path.join('$libdir','libffado.so'), ffadolib ) 124 #env.Ignore( os.path.join('$libdir','libffado.so.0'), "install" ) 122 # 123 # All the following tries to emulate the versioning of installed libs as seen from libtool... 124 # 125 if False: 126 print "Trying to emulate libtools versioned install" 127 env1.Alias( "install", env1.InstallAs( os.path.join('$libdir','libffado.so.$LIBVERSION'), ffadolib ) ) 128 env1.Ignore( ffadolib, os.path.join('$libdir','libffado.so') ) 129 #env.Ignore( os.path.join('$libdir','libffado.so'), ffadolib ) 130 #env.Ignore( os.path.join('$libdir','libffado.so.0'), "install" ) 125 131 126 env.Alias( "install", env.Command( target=env['libdir']+"/libffado.so", source=env['libdir']+"/libffado.so.$LIBVERSION", action="ln -s libffado.so.%s $libdir/libffado.so" % env['LIBVERSION'] ) ) 127 env.Alias( "install", env.Command( target="$libdir/libffado.so.%s" % str(env['LIBVERSION']).rsplit('.',1)[0], source=env['libdir']+"/libffado.so.$LIBVERSION", action="ln -s $SOURCE $TARGET" ) ) 128 env.Alias( "install", env.Command( target="$libdir/libffado.so.%s" % str(env['LIBVERSION']).rsplit('.',2)[0], source=env['libdir']+"/libffado.so.$LIBVERSION", action="ln -s $SOURCE $TARGET" ) ) 132 env1.Alias( "install", env1.Command( 133 target="$libdir/libffado.so", 134 source=env1['libdir']+"/libffado.so.$LIBVERSION", 135 action="ln -s $SOURCE $TARGET" 136 ) ) 137 env1.Alias( "install", env1.Command( 138 target="$libdir/libffado.so.%s" % str(env1['LIBVERSION']).rsplit('.',1)[0], 139 source=env1['libdir']+"/libffado.so.$LIBVERSION", 140 action="ln -s $SOURCE $TARGET" 141 ) ) 142 env1.Alias( "install", env1.Command( 143 target="$libdir/libffado.so.%s" % str(env1['LIBVERSION']).rsplit('.',2)[0], 144 source=env1['libdir']+"/libffado.so.$LIBVERSION", 145 action="ln -s $SOURCE $TARGET" 146 ) ) 147 else: 148 print "Doing simple install" 149 env1.Alias( "install", env1.Install( "$libdir", ffadolib ) ) 150 129 151 130 152 # 131 153 # For the debugging apps 132 154 # 133 env.AppendUnique( LIBPATH="#/src" ) 134 env.AppendUnique( LIBS="ffado" ) 155 env2 = env.Copy() 156 env2.AppendUnique( LIBPATH="#/src" ) 157 env2.AppendUnique( LIBS="ffado" ) 135 158 136 159 apps = { \ … … 144 167 145 168 for app in apps.keys(): 146 env .Program( target=app, source = env.Split( apps[app] ) )169 env2.Program( target=app, source = env.Split( apps[app] ) ) 147 170