mirror of
				https://github.com/bytecodealliance/wasm-micro-runtime.git
				synced 2025-10-27 03:11:18 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			35 lines
		
	
	
		
			759 B
		
	
	
	
		
			Python
		
	
	
	
	
	
			
		
		
	
	
			35 lines
		
	
	
		
			759 B
		
	
	
	
		
			Python
		
	
	
	
	
	
| #
 | |
| # Copyright (c) 2021, RT-Thread Development Team
 | |
| #
 | |
| # SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
 | |
| #
 | |
| 
 | |
| from building import *
 | |
| import os
 | |
| 
 | |
| cwd     = GetCurrentDir()
 | |
| 
 | |
| src = Split('''
 | |
| ''')
 | |
| 
 | |
| CPPPATH = [cwd,
 | |
|         cwd+'/sandboxed-system-primitives/include',
 | |
|         cwd+'/sandboxed-system-primitives/src']
 | |
| 
 | |
| def addSrcFiles(arr, path):
 | |
|     for f in os.listdir(path):
 | |
|         fpath = os.path.join(path, f);
 | |
|         if os.path.isfile(fpath):
 | |
|             ext = os.path.splitext(fpath)[-1]
 | |
|             if ext == '.c' or ext == '.cpp':
 | |
|                 arr += [fpath]
 | |
|         elif os.path.isdir(fpath):
 | |
|             addSrcFiles(arr, fpath)
 | |
| 
 | |
| 
 | |
| addSrcFiles(src, cwd)
 | |
| 
 | |
| group = DefineGroup('iwasm_libc_wasi', src, depend = [''], CPPPATH = CPPPATH)
 | |
| 
 | |
| Return('group')
 | 
