This commit is contained in:
Alon Zakai 2014-02-09 20:26:35 -08:00
Родитель dae556e5aa
Коммит 079f019c35
1 изменённых файлов: 4 добавлений и 2 удалений

6
emcc
Просмотреть файл

@ -56,7 +56,9 @@ from tools.response_file import read_response_file
# endings = dot + a suffix, safe to test by filename.endswith(endings)
C_ENDINGS = ('.c', '.C')
CXX_ENDINGS = ('.cpp', '.cxx', '.cc', '.CPP', '.CXX', '.CC')
SOURCE_ENDINGS = C_ENDINGS + CXX_ENDINGS + ('.m', '.mm')
OBJC_ENDINGS = ('.m',)
OBJCXX_ENDINGS = ('.mm',)
SOURCE_ENDINGS = C_ENDINGS + CXX_ENDINGS + OBJC_ENDINGS + OBJCXX_ENDINGS
BITCODE_ENDINGS = ('.bc', '.o', '.obj')
DYNAMICLIB_ENDINGS = ('.dylib', '.so', '.dll')
STATICLIB_ENDINGS = ('.a',)
@ -714,7 +716,7 @@ use_cxx = True
for i in range(1, len(sys.argv)):
arg = sys.argv[i]
if not arg.startswith('-'):
if arg.endswith(('.c','.m')):
if arg.endswith(C_ENDINGS + OBJC_ENDINGS):
use_cxx = False
if '-M' in sys.argv or '-MM' in sys.argv: