You can not select more than 25 topics
			Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
		
		
		
		
			
				
					28 lines
				
				901 B
			
		
		
			
		
	
	
					28 lines
				
				901 B
			| 
											4 years ago
										 | Import('env', 'arch', 'cereal', 'messaging', 'common', 'visionipc')
 | ||
| 
											5 years ago
										 | 
 | ||
| 
											4 years ago
										 | libs = [common, cereal, messaging, visionipc,
 | ||
| 
											5 years ago
										 |         'zmq', 'capnp', 'kj', 'z',
 | ||
| 
											5 years ago
										 |         'avformat', 'avcodec', 'swscale', 'avutil',
 | ||
| 
											4 years ago
										 |         'yuv', 'OpenCL', 'pthread']
 | ||
| 
											6 years ago
										 | 
 | ||
| 
											3 years ago
										 | src = ['logger.cc', 'video_writer.cc', 'encoder/encoder.cc', 'encoder/v4l_encoder.cc']
 | ||
|  | if arch != "larch64":
 | ||
| 
											4 years ago
										 |   src += ['encoder/ffmpeg_encoder.cc']
 | ||
| 
											6 years ago
										 | 
 | ||
| 
											5 years ago
										 | if arch == "Darwin":
 | ||
|  |   # fix OpenCL
 | ||
|  |   del libs[libs.index('OpenCL')]
 | ||
|  |   env['FRAMEWORKS'] = ['OpenCL']
 | ||
| 
											3 years ago
										 |   # exclude v4l
 | ||
|  |   del src[src.index('encoder/v4l_encoder.cc')]
 | ||
| 
											5 years ago
										 | 
 | ||
| 
											4 years ago
										 | logger_lib = env.Library('logger', src)
 | ||
|  | libs.insert(0, logger_lib)
 | ||
|  | 
 | ||
| 
											4 years ago
										 | env.Program('loggerd', ['loggerd.cc'], LIBS=libs)
 | ||
| 
											4 years ago
										 | env.Program('encoderd', ['encoderd.cc'], LIBS=libs)
 | ||
| 
											5 years ago
										 | env.Program('bootlog.cc', LIBS=libs)
 | ||
| 
											4 years ago
										 | 
 | ||
|  | if GetOption('test'):
 | ||
| 
											4 years ago
										 |   env.Program('tests/test_logger', ['tests/test_runner.cc', 'tests/test_logger.cc'], LIBS=libs + ['curl', 'crypto'])
 |