Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
emscripten-core
GitHub Repository: emscripten-core/emscripten
Path: blob/main/emscan-deps.py
4091 views
1
#!/usr/bin/env python3
2
# Copyright 2025 The Emscripten Authors. All rights reserved.
3
# Emscripten is available under two separate licenses, the MIT license and the
4
# University of Illinois/NCSA Open Source License. Both these licenses can be
5
# found in the LICENSE file.
6
7
"""emscan-deps - clang-scan-deps helper script
8
9
This script acts as a frontend replacement for clang-scan-deps.
10
"""
11
12
import sys
13
14
from tools import shared, cmdline, compile
15
16
argv = sys.argv[1:]
17
18
# Parse and discard any emcc-specific flags (e.g. -sXXX).
19
newargs = cmdline.parse_arguments(argv)[1]
20
21
# Add any clang flags that emcc would add.
22
newargs += compile.get_cflags(tuple(argv))
23
24
shared.exec_process([shared.CLANG_SCAN_DEPS] + newargs)
25
26