root/tags/2.0.0/SConstruct

Revision 1750, 19.6 kB (checked in by ppalmers, 2 years ago)

update version to 2.0.0

Line 
1 #! /usr/bin/python
2 # -*- coding: utf-8 -*-
3 #
4 # Copyright (C) 2007-2008 Arnold Krille
5 # Copyright (C) 2007-2008 Pieter Palmers
6 # Copyright (C) 2008 Jonathan Woithe
7 #
8 # This file is part of FFADO
9 # FFADO = Free Firewire (pro-)audio drivers for linux
10 #
11 # FFADO is based upon FreeBoB.
12 #
13 # This program is free software: you can redistribute it and/or modify
14 # it under the terms of the GNU General Public License as published by
15 # the Free Software Foundation, either version 2 of the License, or
16 # (at your option) version 3 of the License.
17 #
18 # This program is distributed in the hope that it will be useful,
19 # but WITHOUT ANY WARRANTY; without even the implied warranty of
20 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
21 # GNU General Public License for more details.
22 #
23 # You should have received a copy of the GNU General Public License
24 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
25 #
26
27 FFADO_API_VERSION = "8"
28 FFADO_VERSION = "2.0.0"
29
30 import os
31 import re
32 from string import Template
33 import imp
34
35 if not os.path.isdir( "cache" ):
36         os.makedirs( "cache" )
37
38 opts = Options( "cache/options.cache" )
39
40 opts.AddOptions(
41         BoolOption( "DEBUG", """\
42 Toggle debug-build. DEBUG means \"-g -Wall\" and more, otherwise we will use
43   \"-O2\" to optimize.""", False ),
44         BoolOption( "PROFILE", "Build with symbols and other profiling info", False ),
45         PathOption( "PREFIX", "The prefix where ffado will be installed to.", "/usr/local", PathOption.PathAccept ),
46         PathOption( "BINDIR", "Overwrite the directory where apps are installed to.", "$PREFIX/bin", PathOption.PathAccept ),
47         PathOption( "LIBDIR", "Overwrite the directory where libs are installed to.", "$PREFIX/lib", PathOption.PathAccept ),
48         PathOption( "INCLUDEDIR", "Overwrite the directory where headers are installed to.", "$PREFIX/include", PathOption.PathAccept ),
49         PathOption( "SHAREDIR", "Overwrite the directory where misc shared files are installed to.", "$PREFIX/share/libffado", PathOption.PathAccept ),
50         BoolOption( "ENABLE_BEBOB", "Enable/Disable the bebob part.", True ),
51         BoolOption( "ENABLE_FIREWORKS", "Enable/Disable the ECHO Audio FireWorks AV/C part.", True ),
52         BoolOption( "ENABLE_MOTU", "Enable/Disable the MOTU part.", True ),
53         BoolOption( "ENABLE_GENERICAVC", """\
54 Enable/Disable the the generic avc part (mainly used by apple).
55   Note that disabling this option might be overwritten by other devices needing
56   this code.""", False ),
57         BoolOption( "ENABLE_ALL", "Enable/Disable support for all devices.", False ),
58         BoolOption( "SERIALIZE_USE_EXPAT", "Use libexpat for XML serialization.", False ),
59         BoolOption( "BUILD_TESTS", """\
60 Build the tests in their directory. As some contain quite some functionality,
61   this is on by default.
62   If you just want to use ffado with jack without the tools, you can disable this.\
63 """, True ),
64     BoolOption( "BUILD_STATIC_TOOLS", "Build a statically linked version of the FFADO tools.", False ),
65     EnumOption('DIST_TARGET', 'Build target for cross compiling packagers', 'auto', allowed_values=('auto', 'i386', 'i686', 'x86_64', 'powerpc', 'powerpc64', 'none' ), ignorecase=2),
66     BoolOption( "ENABLE_OPTIMIZATIONS", "Enable optimizations and the use of processor specific extentions (MMX/SSE/...).", False ),
67
68         )
69
70 ## Load the builders in config
71 buildenv=os.environ
72 vars_to_check = [
73         'PATH',
74         'PKG_CONFIG_PATH',
75         'LD_LIBRARY_PATH',
76         'XDG_CONFIG_DIRS',
77         'XDG_DATA_DIRS',
78         'HOME',
79         'CC',
80         'CFLAGS',
81         'CXX',
82         'CXXFLAGS',
83         'CPPFLAGS',
84 ]
85 for var in vars_to_check:
86         if os.environ.has_key(var):
87                 buildenv[var]=os.environ[var]
88         else:
89                 buildenv[var]=''
90
91 env = Environment( tools=['default','scanreplace','pyuic','pyuic4','dbus','doxygen','pkgconfig'], toolpath=['admin'], ENV = buildenv, options=opts )
92
93 if os.environ.has_key('LDFLAGS'):
94         env['LINKFLAGS'] = os.environ['LDFLAGS']
95
96 # grab OS CFLAGS / CCFLAGS
97 env['OS_CFLAGS']=[]
98 if os.environ.has_key('CFLAGS'):
99         env['OS_CFLAGS'] = os.environ['CFLAGS']
100 env['OS_CCFLAGS']=[]
101 if os.environ.has_key('CCFLAGS'):
102         env['OS_CCFLAGS'] = os.environ['CCFLAGS']
103
104 Help( """
105 For building ffado you can set different options as listed below. You have to
106 specify them only once, scons will save the last value you used and re-use
107 that.
108 To really undo your settings and return to the factory defaults, remove the
109 "cache"-folder and the file ".sconsign.dblite" from this directory.
110 For example with: "rm -Rf .sconsign.dblite cache"
111
112 Note that this is a development version! Don't complain if its not working!
113 See www.ffado.org for stable releases.
114 """ )
115 Help( opts.GenerateHelpText( env ) )
116
117 # make sure the necessary dirs exist
118 if not os.path.isdir( "cache" ):
119         os.makedirs( "cache" )
120 if not os.path.isdir( 'cache/objects' ):
121         os.makedirs( 'cache/objects' )
122
123 CacheDir( 'cache/objects' )
124
125 opts.Save( 'cache/options.cache', env )
126
127 def ConfigGuess( context ):
128         context.Message( "Trying to find the system triple: " )
129         ret = os.popen( "admin/config.guess" ).read()[:-1]
130         context.Result( ret )
131         return ret
132
133 def CheckForApp( context, app ):
134         context.Message( "Checking whether '" + app + "' executes " )
135         ret = context.TryAction( app )
136         context.Result( ret[0] )
137         return ret[0]
138
139 def CheckForPyModule( context, module ):
140         context.Message( "Checking for the python module '" + module + "' " )
141         ret = context.TryAction( "python $SOURCE", "import %s" % module, ".py" )
142         context.Result( ret[0] )
143         return ret[0]
144
145 def CompilerCheck( context ):
146         context.Message( "Checking for a working C-compiler " )
147         ret = context.TryRun( """
148 #include <stdlib.h>
149
150 int main() {
151         printf( "Hello World!" );
152         return 0;
153 }""", '.c' )[0]
154         context.Result( ret )
155         if ret == 0:
156                 return False;
157         context.Message( "Checking for a working C++-compiler " )
158         ret = context.TryRun( """
159 #include <iostream>
160
161 int main() {
162         std::cout << "Hello World!" << std::endl;
163         return 0;
164 }""", ".cpp" )[0]
165         context.Result( ret )
166         return ret
167
168 tests = {
169         "ConfigGuess" : ConfigGuess,
170         "CheckForApp" : CheckForApp,
171         "CheckForPyModule": CheckForPyModule,
172         "CompilerCheck" : CompilerCheck,
173 }
174 tests.update( env['PKGCONFIG_TESTS'] )
175 tests.update( env['PYUIC_TESTS'] )
176 tests.update( env['PYUIC4_TESTS'] )
177
178 conf = Configure( env,
179         custom_tests = tests,
180         conf_dir = "cache/",
181         log_file = 'cache/config.log' )
182
183 if env['SERIALIZE_USE_EXPAT']:
184         env['SERIALIZE_USE_EXPAT']=1
185 else:
186         env['SERIALIZE_USE_EXPAT']=0
187
188 if not env.GetOption('clean'):
189         #
190         # Check for working gcc and g++ compilers and their environment.
191         #
192         if not conf.CompilerCheck():
193                 print "\nIt seems as if your system isn't even able to compile any C-/C++-programs. Probably you don't have gcc and g++ installed. Compiling a package from source without a working compiler is very hard to do, please install the needed packages.\nHint: on *ubuntu you need both gcc- and g++-packages installed, easiest solution is to install build-essential which depends on gcc and g++."
194                 Exit( 1 )
195
196         # Check for pkg-config before using pkg-config to check for other dependencies.
197         if not conf.CheckForPKGConfig():
198                 print "\nThe program 'pkg-config' could not be found.\nEither you have to install the corresponding package first or make sure that PATH points to the right directions."
199                 Exit( 1 )
200
201         #
202         # The following checks are for headers and libs and packages we need.
203         #
204         allpresent = 1;
205         # for DBUS C++ bindings
206         allpresent &= conf.CheckHeader( "expat.h" )
207         allpresent &= conf.CheckLib( 'expat', 'XML_ExpatVersion', '#include <expat.h>' )
208        
209         pkgs = {
210                 'libraw1394' : '1.3.0',
211                 'libiec61883' : '1.1.0',
212                 'dbus-1' : '1.0',
213                 }
214         if not env['SERIALIZE_USE_EXPAT']:
215                 pkgs['libxml++-2.6'] = '2.13.0'
216
217         for pkg in pkgs:
218                 name2 = pkg.replace("+","").replace(".","").replace("-","").upper()
219                 env['%s_FLAGS' % name2] = conf.GetPKGFlags( pkg, pkgs[pkg] )
220                 if env['%s_FLAGS'%name2] == 0:
221                         allpresent &= 0
222
223         if not allpresent:
224                 print """
225 (At least) One of the dependencies is missing. I can't go on without it, please
226 install the needed packages for each of the lines saying "no".
227 (Remember to also install the *-devel packages!)
228
229 And remember to remove the cache with "rm -Rf .sconsign.dblite cache" so the
230 results above get rechecked.
231 """
232                 Exit( 1 )
233
234         # Check for C99 lrint() and lrintf() functions used to convert from
235         # float to integer more efficiently via float_cast.h.  If not
236         # present the standard slower methods will be used instead.  This
237         # might not be the best way of testing for these but it's the only
238         # way which seems to work properly.  CheckFunc() fails due to
239         # argument count problems.
240         if env.has_key( 'CFLAGS' ):
241                 oldcf = env['CFLAGS']
242         else:
243                 oldcf = ""
244         oldcf = env.Append(CFLAGS = '-std=c99')
245         if conf.CheckLibWithHeader( "m", "math.h", "c", "lrint(3.2);" ):
246                 HAVE_LRINT = 1
247         else:
248                 HAVE_LRINT = 0
249         if conf.CheckLibWithHeader( "m", "math.h", "c", "lrintf(3.2);" ):
250                 HAVE_LRINTF = 1
251         else:
252                 HAVE_LRINTF = 0
253         env['HAVE_LRINT'] = HAVE_LRINT;
254         env['HAVE_LRINTF'] = HAVE_LRINTF;
255         env.Replace(CFLAGS=oldcf)
256
257 #
258 # Optional checks follow:
259 #
260
261 # PyQT checks
262 build_mixer = False
263 if conf.CheckForApp( 'which pyuic4' ) and conf.CheckForPyModule( 'dbus' ) and conf.CheckForPyModule( 'PyQt4' ) and conf.CheckForPyModule( 'dbus.mainloop.qt' ):
264         env['PYUIC4'] = True
265         build_mixer = True
266
267 if conf.CheckForApp( 'which pyuic' ) and conf.CheckForPyModule( 'dbus' ) and conf.CheckForPyModule( 'qt' ):
268         env['PYUIC'] = True
269         build_mixer = True
270
271 if conf.CheckForApp( 'xdg-desktop-menu --help' ):
272         env['XDG_TOOLS'] = True
273 else:
274         print """
275 I couldn't find the program 'xdg-desktop-menu'. Together with xdg-icon-resource
276 this is needed to add the fancy entry to your menu. But the mixer will be installed, you can start it by executing "ffado-mixer".
277 """
278
279 if not build_mixer and not env.GetOption('clean'):
280         print """
281 I couldn't find all the prerequisites ('pyuic' / 'pyuic4' and the python-modules 'dbus' and
282 'qt' / 'PyQt4', the packages could be named like dbus-python and PyQt) to build the mixer.
283 Therefor neither the qt3 nor the qt4 mixer will get installed.
284 """
285
286 config_guess = conf.ConfigGuess()
287
288 env = conf.Finish()
289
290 if env['DEBUG']:
291         print "Doing a DEBUG build"
292         env.MergeFlags( "-DDEBUG -Wall -g" )
293 else:
294         env.MergeFlags( "-O2 -DNDEBUG" )
295
296 if env['PROFILE']:
297         print "Doing a PROFILE build"
298         env.MergeFlags( "-Wall -g" )
299
300
301 # this is required to indicate that the DBUS version we use has support
302 # for platform dependent threading init functions
303 # this is true for DBUS >= 0.96 or so. Since we require >= 1.0 it is
304 # always true
305 env.MergeFlags( "-DDBUS_HAS_THREADS_INIT_DEFAULT" )
306
307 if env['ENABLE_ALL']:
308         env['ENABLE_BEBOB'] = True
309         env['ENABLE_FIREWORKS'] = True
310         env['ENABLE_MOTU'] = True
311
312 if env['ENABLE_BEBOB'] or env['ENABLE_FIREWORKS']:
313         env['ENABLE_GENERICAVC'] = True
314
315 env['BUILD_STATIC_LIB'] = False
316 if env['BUILD_STATIC_TOOLS']:
317     print "Building static versions of the tools..."
318     env['BUILD_STATIC_LIB'] = True
319
320 env['build_base']="#/"
321
322 #
323 # Get the DESTDIR (if wanted) from the commandline
324 #
325 env.destdir = ARGUMENTS.get( 'DESTDIR', "" )
326
327 #
328 # Uppercase variables are for usage in code, lowercase versions for usage in
329 # scons-files for installing.
330 #
331 env['BINDIR'] = Template( env['BINDIR'] ).safe_substitute( env )
332 env['LIBDIR'] = Template( env['LIBDIR'] ).safe_substitute( env )
333 env['INCLUDEDIR'] = Template( env['INCLUDEDIR'] ).safe_substitute( env )
334 env['SHAREDIR'] = Template( env['SHAREDIR'] ).safe_substitute( env )
335 env['bindir'] = Template( env.destdir + env['BINDIR'] ).safe_substitute( env )
336 env['libdir'] = Template( env.destdir + env['LIBDIR'] ).safe_substitute( env )
337 env['includedir'] = Template( env.destdir + env['INCLUDEDIR'] ).safe_substitute( env )
338 env['sharedir'] = Template( env.destdir + env['SHAREDIR'] ).safe_substitute( env )
339
340 env.Command( target=env['sharedir'], source="", action=Mkdir( env['sharedir'] ) )
341
342 env.Alias( "install", env['libdir'] )
343 env.Alias( "install", env['includedir'] )
344 env.Alias( "install", env['sharedir'] )
345 env.Alias( "install", env['bindir'] )
346
347 #
348 # shamelessly copied from the Ardour scons file
349 #
350
351 opt_flags = []
352 env['USE_SSE'] = 0
353
354 # guess at the platform, used to define compiler flags
355
356 config_cpu = 0
357 config_arch = 1
358 config_kernel = 2
359 config_os = 3
360 config = config_guess.split ("-")
361
362 needs_fPIC = False
363
364 # Autodetect
365 if env['DIST_TARGET'] == 'auto':
366     if re.search ("x86_64", config[config_cpu]) != None:
367         env['DIST_TARGET'] = 'x86_64'
368     elif re.search("i[0-5]86", config[config_cpu]) != None:
369         env['DIST_TARGET'] = 'i386'
370     elif re.search("i686", config[config_cpu]) != None:
371         env['DIST_TARGET'] = 'i686'
372     elif re.search("powerpc64", config[config_cpu]) != None:
373         env['DIST_TARGET'] = 'powerpc64'
374     elif re.search("powerpc", config[config_cpu]) != None:
375         env['DIST_TARGET'] = 'powerpc'
376     else:
377         env['DIST_TARGET'] = config[config_cpu]
378     print "Detected DIST_TARGET = " + env['DIST_TARGET']
379
380 if ((re.search ("i[0-9]86", config[config_cpu]) != None) or (re.search ("x86_64", config[config_cpu]) != None) or (re.search ("powerpc", config[config_cpu]) != None)):
381    
382     build_host_supports_sse = 0
383     build_host_supports_sse2 = 0
384     build_host_supports_sse3 = 0
385
386     if config[config_kernel] == 'linux' :
387        
388         if (env['DIST_TARGET'] == 'i686') or (env['DIST_TARGET'] == 'x86_64'):
389            
390             flag_line = os.popen ("cat /proc/cpuinfo | grep '^flags'").read()[:-1]
391             x86_flags = flag_line.split (": ")[1:][0].split ()
392            
393             if "mmx" in x86_flags:
394                 opt_flags.append ("-mmmx")
395             if "sse" in x86_flags:
396                 build_host_supports_sse = 1
397             if "sse2" in x86_flags:
398                 build_host_supports_sse2 = 1
399             #if "sse3" in x86_flags:
400                 #build_host_supports_sse3 = 1
401             if "3dnow" in x86_flags:
402                 opt_flags.append ("-m3dnow")
403            
404             if config[config_cpu] == "i586":
405                 opt_flags.append ("-march=i586")
406             elif config[config_cpu] == "i686":
407                 opt_flags.append ("-march=i686")
408
409         elif (env['DIST_TARGET'] == 'powerpc') or (env['DIST_TARGET'] == 'powerpc64'):
410
411             cpu_line = os.popen ("cat /proc/cpuinfo | grep '^cpu'").read()[:-1]
412
413             ppc_type = cpu_line.split (": ")[1]
414             if re.search ("altivec", ppc_type) != None:
415                 opt_flags.append ("-maltivec")
416                 opt_flags.append ("-mabi=altivec")
417
418             ppc_type = ppc_type.split (", ")[0]
419             if re.match ("74[0145][0578]A?", ppc_type) != None:
420                 opt_flags.append ("-mcpu=7400")
421                 opt_flags.append ("-mtune=7400")
422             elif re.match ("750", ppc_type) != None:
423                 opt_flags.append ("-mcpu=750")
424                 opt_flags.append ("-mtune=750")
425             elif re.match ("PPC970", ppc_type) != None:
426                 opt_flags.append ("-mcpu=970")
427                 opt_flags.append ("-mtune=970")
428             elif re.match ("Cell Broadband Engine", ppc_type) != None:
429                 opt_flags.append ("-mcpu=cell")
430                 opt_flags.append ("-mtune=cell")
431
432     if ((env['DIST_TARGET'] == 'i686') or (env['DIST_TARGET'] == 'x86_64')) \
433        and build_host_supports_sse and env['ENABLE_OPTIMIZATIONS']:
434         opt_flags.extend (["-msse", "-mfpmath=sse"])
435         env['USE_SSE'] = 1
436
437     if ((env['DIST_TARGET'] == 'i686') or (env['DIST_TARGET'] == 'x86_64')) \
438        and build_host_supports_sse2 and env['ENABLE_OPTIMIZATIONS']:
439         opt_flags.extend (["-msse2"])
440         env['USE_SSE2'] = 1
441
442     #if ((env['DIST_TARGET'] == 'i686') or (env['DIST_TARGET'] == 'x86_64')) \
443        #and build_host_supports_sse2 and env['ENABLE_OPTIMIZATIONS']:
444         #opt_flags.extend (["-msse3"])
445         #env['USE_SSE3'] = 1
446
447     # build for 64-bit userland?
448     if env['DIST_TARGET'] == "powerpc64":
449         print "Doing a 64-bit PowerPC build"
450         env.MergeFlags( "-m64" )
451     elif env['DIST_TARGET'] == "x86_64":
452         print "Doing a 64-bit x86 build"
453         env.MergeFlags( "-m64" )
454         needs_fPIC = True
455     else:
456         print "Doing a 32-bit build"
457         env.MergeFlags( "-m32" )
458
459 if needs_fPIC or '-fPIC' in env['OS_CFLAGS'] or "-fPIC" in env['OS_CCFLAGS']:
460     env.MergeFlags( "-fPIC" )
461
462 # end of processor-specific section
463 if env['ENABLE_OPTIMIZATIONS']:
464     opt_flags.extend (["-fomit-frame-pointer","-ffast-math","-funroll-loops"])
465     env.MergeFlags( opt_flags )
466     print "Doing an optimized build..."
467
468 env['REVISION'] = os.popen('svnversion .').read()[:-1]
469 # This may be as simple as '89' or as complex as '4123:4184M'.
470 # We'll just use the last bit.
471 env['REVISION'] = env['REVISION'].split(':')[-1]
472
473 # try to circumvent localized versions
474 if len(env['REVISION']) >= 5 and env['REVISION'][0:6] == 'export':
475         env['REVISION'] = ''
476
477 # avoid the 1.999.41- type of version for exported versions
478 if env['REVISION'] != '':
479         env['REVISIONSTRING'] = '-' + env['REVISION']
480 else:
481         env['REVISIONSTRING'] = ''
482
483 env['FFADO_API_VERSION'] = FFADO_API_VERSION
484
485 env['PACKAGE'] = "libffado"
486 env['VERSION'] = FFADO_VERSION
487 env['LIBVERSION'] = "1.0.0"
488
489 env['CONFIGDIR'] = "~/.ffado"
490 env['CACHEDIR'] = "~/.ffado"
491
492 env['USER_CONFIG_FILE'] = env['CONFIGDIR'] + "/configuration"
493 env['SYSTEM_CONFIG_FILE'] = env['SHAREDIR'] + "/configuration"
494
495 env['REGISTRATION_URL'] = "http://ffado.org/deviceregistration/register.php?action=register"
496
497 #
498 # To have the top_srcdir as the doxygen-script is used from auto*
499 #
500 env['top_srcdir'] = env.Dir( "." ).abspath
501
502 #
503 # Start building
504 #
505 env.ScanReplace( "config.h.in" )
506 # ensure that the config.h is updated with the version
507
508 env.Depends( "config.h", "SConstruct" )
509 env.Depends( "config.h", 'cache/options.cache' )
510
511 # update config.h whenever the SVN revision changes
512 env.Depends( "config.h", env.Value(env['REVISION']))
513
514 env.Depends( "libffado.pc", "SConstruct" )
515 pkgconfig = env.ScanReplace( "libffado.pc.in" )
516 env.Install( env['libdir'] + '/pkgconfig', pkgconfig )
517
518 env.Install( env['sharedir'], 'configuration' )
519
520 subdirs=['external','src','libffado','support','doc']
521 if env['BUILD_TESTS']:
522         subdirs.append('tests')
523
524 env.SConscript( dirs=subdirs, exports="env" )
525
526 # By default only src is built but all is cleaned
527 if not env.GetOption('clean'):
528     Default( 'src' )
529     Default( 'support' )
530     if env['BUILD_TESTS']:
531         Default( 'tests' )
532
533 #
534 # Deal with the DESTDIR vs. xdg-tools conflict (which is basicely that the
535 # xdg-tools can't deal with DESTDIR, so the packagers have to deal with this
536 # their own :-/
537 #
538 if len(env.destdir) > 0:
539         if not len( ARGUMENTS.get( "WILL_DEAL_WITH_XDG_MYSELF", "" ) ) > 0:
540                 print """
541 WARNING!
542 You are using the (packagers) option DESTDIR to install this package to a
543 different place than the real prefix. As the xdg-tools can't cope with
544 that, the .desktop-files are not installed by this build, you have to
545 deal with them your own.
546 (And you have to look into the SConstruct to learn how to disable this
547 message.)
548 """
549 else:
550
551         def CleanAction( action ):
552                 if env.GetOption( "clean" ):
553                         env.Execute( action )
554
555         if env.has_key( 'XDG_TOOLS' ) and env.has_key( 'PYUIC4' ):
556                 if not env.GetOption("clean"):
557                         action = "install"
558                 else:
559                         action = "uninstall"
560                 mixerdesktopaction = env.Action( "xdg-desktop-menu %s support/xdg/ffado.org-ffadomixer.desktop" % action )
561                 mixericonaction = env.Action( "xdg-icon-resource %s --size 64 --novendor --context apps support/xdg/hi64-apps-ffado.png ffado" % action )
562                 env.Command( "__xdgstuff1", None, mixerdesktopaction )
563                 env.Command( "__xdgstuff2", None, mixericonaction )
564                 env.Alias( "install", ["__xdgstuff1", "__xdgstuff2" ] )
565                 CleanAction( mixerdesktopaction )
566                 CleanAction( mixericonaction )
567
568 #
569 # Create a tags-file for easier emacs/vim-source-browsing
570 #  I don't know if the dependency is right...
571 #
572 findcommand = "find . \( -path \"*.h\" -o -path \"*.cpp\" -o -path \"*.c\" \) \! -path \"*.svn*\" \! -path \"./doc*\" \! -path \"./cache*\""
573 env.Command( "tags", "", findcommand + " |xargs ctags" )
574 env.Command( "TAGS", "", findcommand + " |xargs etags" )
575 env.AlwaysBuild( "tags", "TAGS" )
576 if 'NoCache' in dir(env):
577     env.NoCache( "tags", "TAGS" )
578
579 # Another convinience target
580 if env.GetOption( "clean" ):
581         env.Execute( "rm cache/objects -Rf" )
582
Note: See TracBrowser for help on using the browser.