4 sys.path += [sys.path[0]+'/scripts']
8 opts = Options('scripts/fobs.py')
9 opts.Add('FFMPEG_HOME', 'Path of a fresh ffmpeg build')
10 #opts.Add('JNI_H_PATH', 'Path of jni.h in your system')
11 #opts.Add('JNI_MD_H_PATH', 'Path of jni_md.h in your system (Optional for MacosX, MinGW and Linux)')
12 opts.Add('FOBS4JMF', 'Build Fobs4JMF plugin (yes|no)')
13 #opts.Add('EXTERNAL_LIBS', 'Link fobs with external libraries (Useful when ffmpeg has been compiled with support for faad, faac, lib52a, etc). Comma separated list of lib names (without -l prefix).')
14 #opts.Add('EXTERNAL_LIB_PATHS', 'Comma separated list of lib paths (without -L prefix).')
15 #opts.Add('EXTERNAL_INC_PATHS', 'Comma separated list of include paths (without -I prefix).')
16 opts.Add('OPTIMIZATIONS', 'Compile with optimizations (yes|no).')
17 opts.Add('DEBUG_SYMBOLS', 'Compile with debug symbols (yes|no).')
18 env = Environment(options = opts)
19 Help(opts.GenerateHelpText(env))
20 opts.Add('root','Unmutable variable')
21 opts.Add('SYSTEM_ROOT','Unmutable variable')
22 env = Environment(options = opts)
26 if ARGUMENTS.has_key('FFMPEG_HOME'):
27 env['FFMPEG_HOME'] = ARGUMENTS['FFMPEG_HOME']
29 if ARGUMENTS.has_key('JNI_H_PATH'):
30 env['JNI_H_PATH']=ARGUMENTS['JNI_H_PATH']
32 if ARGUMENTS.has_key('JNI_MD_H_PATH'):
33 env['JNI_MD_H_PATH']=ARGUMENTS['JNI_MD_H_PATH']
35 if ARGUMENTS.has_key('FOBS4JMF'):
36 env['FOBS4JMF']=ARGUMENTS['FOBS4JMF']
38 if ARGUMENTS.has_key('EXTERNAL_LIBS'):
39 #When a single item list is provided, Split does not return a list
40 tmp = Split(ARGUMENTS['EXTERNAL_LIBS'].replace(',',' '))
41 if(type(tmp)==type([])):
42 env['EXTERNAL_LIBS']=tmp
44 env['EXTERNAL_LIBS']=[tmp]
46 if ARGUMENTS.has_key('EXTERNAL_LIB_PATHS'):
47 tmp = Split(ARGUMENTS['EXTERNAL_LIB_PATHS'].replace(',',' '))
48 if(type(tmp)==type([])):
49 env['EXTERNAL_LIB_PATHS']=tmp
51 env['EXTERNAL_LIB_PATHS']=[tmp]
53 if ARGUMENTS.has_key('EXTERNAL_INC_PATHS'):
54 tmp = Split(ARGUMENTS['EXTERNAL_INC_PATHS'].replace(',',' '))
55 if(type(tmp)==type([])):
56 env['EXTERNAL_INC_PATHS']=tmp
58 env['EXTERNAL_INC_PATHS']=[tmp]
60 env['root']=os.getcwd()
62 if ARGUMENTS.has_key('SYSTEM_ROOT'):
63 env['SYSTEM_ROOT'] = ARGUMENTS['SYSTEM_ROOT']
65 opts.Save('scripts/fobs.py',env)