Skip to content

Commit c610879

Browse files
committed
Rename upstream directory to simply prebuilt
The name `upstream` doesn't have any meaning anymore now that there is no more fastcomp. It was removed from the SDK names in #1166 and this is the last usage of that name/term.
1 parent ae2664b commit c610879

8 files changed

+27
-30
lines changed

.flake8

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,7 @@ ignore =
88
exclude =
99
./llvm
1010
./gnu
11-
./upstream
12-
./fastcomp
11+
./prebuilt
1312
./fastcomp-clang
1413
./releases
1514
./clang

.gitignore

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,7 @@ __pycache__
1515
# File that get download/extracted by emsdk itself
1616
/ccache
1717
/gnu
18-
/upstream
19-
/fastcomp
20-
/fastcomp-clang/
18+
/prebuilt
2119
/llvm
2220
/ninja
2321
/releases

README.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -136,11 +136,11 @@ using git, and compile the package on demand.
136136
When you run `emsdk list`, it will group the Tools and SDKs under these two
137137
categories.
138138

139-
To obtain and build latest upstream wasm SDK from source, run
139+
To obtain and build latest wasm SDK from source, run
140140

141141
```
142-
emsdk install sdk-upstream-main-64bit
143-
emsdk activate sdk-upstream-main-64bit
142+
emsdk install sdk-main-64bit
143+
emsdk activate sdk-main-64bit
144144
```
145145

146146
You can use this target for example to bootstrap developing patches to LLVM,
@@ -156,7 +156,7 @@ https://emscripten.org/docs/contributing/developers_guide.html?highlight=develop
156156
### When working on git branches compiled from source, how do I update to a newer compiler version?
157157

158158
Unlike tags and precompiled versions, a few of the SDK packages are based on
159-
"moving" git branches and compiled from source (e.g. sdk-upstream-main,
159+
"moving" git branches and compiled from source (e.g. sdk-main,
160160
sdk-main, emscripten-main, binaryen-main). Because of that, the
161161
compiled versions will eventually go out of date as new commits are introduced
162162
to the development branches. To update an old compiled installation of one of
@@ -198,11 +198,11 @@ where you directly interact with the github repositories. This allows you to
198198
obtain new features and latest fixes immediately as they are pushed to the
199199
github repository, without having to wait for release to be tagged. You do not
200200
need a github account or a fork of Emscripten to do this. To switch to using the
201-
latest upstream git development branch `main`, run the following:
201+
latest git development branch `main`, run the following:
202202

203203
emsdk install git-1.9.4 # Install git. Skip if the system already has it.
204-
emsdk install sdk-upstream-main-64bit # Clone+pull the latest emscripten-core/emscripten/main.
205-
emsdk activate sdk-upstream-main-64bit # Set the main SDK as the currently active one.
204+
emsdk install sdk-main-64bit # Clone+pull the latest emscripten-core/emscripten/main.
205+
emsdk activate sdk-main-64bit # Set the main SDK as the currently active one.
206206

207207
### How do I use my own Emscripten github fork with the SDK?
208208

docker/Dockerfile

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,11 @@ RUN echo "## Install Emscripten" \
3232
RUN cd ${EMSDK} \
3333
&& echo "## Generate standard configuration" \
3434
&& ./emsdk activate ${EMSCRIPTEN_VERSION} \
35-
&& chmod 777 ${EMSDK}/upstream/emscripten \
36-
&& chmod -R 777 ${EMSDK}/upstream/emscripten/cache \
35+
&& chmod 777 ${EMSDK}/prebuilt/emscripten \
36+
&& chmod -R 777 ${EMSDK}/prebuilt/emscripten/cache \
3737
&& echo "int main() { return 0; }" > hello.c \
38-
&& ${EMSDK}/upstream/emscripten/emcc -c hello.c \
39-
&& cat ${EMSDK}/upstream/emscripten/cache/sanity.txt \
38+
&& ${EMSDK}/prebuilt/emscripten/emcc -c hello.c \
39+
&& cat ${EMSDK}/prebuilt/emscripten/cache/sanity.txt \
4040
&& echo "## Done"
4141

4242
# Cleanup Emscripten installation and strip some symbols
@@ -45,11 +45,11 @@ RUN echo "## Aggressive optimization: Remove debug symbols" \
4545
# Remove debugging symbols from embedded node (extra 7MB)
4646
&& strip -s `which node` \
4747
# Tests consume ~80MB disc space
48-
&& rm -fr ${EMSDK}/upstream/emscripten/tests \
48+
&& rm -fr ${EMSDK}/prebuilt/emscripten/tests \
4949
# Fastcomp is not supported
50-
&& rm -fr ${EMSDK}/upstream/fastcomp \
50+
&& rm -fr ${EMSDK}/prebuilt/fastcomp \
5151
# strip out symbols from clang (~extra 50MB disc space)
52-
&& find ${EMSDK}/upstream/bin -type f -exec strip -s {} + || true \
52+
&& find ${EMSDK}/prebuilt/bin -type f -exec strip -s {} + || true \
5353
&& echo "## Done"
5454

5555
# ------------------------------------------------------------------------------
@@ -65,7 +65,7 @@ COPY --from=stage_build /emsdk /emsdk
6565
# (sub-stages) or with custom / no entrypoint
6666
ENV EMSDK=/emsdk \
6767
EMSDK_NODE=/emsdk/node/14.18.2_64bit/bin/node \
68-
PATH="/emsdk:/emsdk/upstream/emscripten:/emsdk/upstream/bin:/emsdk/node/14.18.2_64bit/bin:${PATH}"
68+
PATH="/emsdk:/emsdk/prebuilt/emscripten:/emsdk/prebuilt/bin:/emsdk/node/14.18.2_64bit/bin:${PATH}"
6969

7070
# ------------------------------------------------------------------------------
7171
# Create a 'standard` 1000:1000 user

emsdk.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1919,9 +1919,9 @@ def install_sdk(self):
19191919
return False
19201920

19211921
if getattr(self, 'custom_install_script', None) == 'emscripten_npm_install':
1922-
# upstream tools have hardcoded paths that are not stored in emsdk_manifest.json registry
1923-
install_path = 'upstream'
1924-
emscripten_dir = os.path.join(EMSDK_PATH, install_path, 'emscripten')
1922+
# prebuilt sdk tools have hardcoded paths that are not stored in
1923+
# emsdk_manifest.json registry
1924+
emscripten_dir = os.path.join(EMSDK_PATH, 'prebuilt', 'emscripten')
19251925
# Older versions of the sdk did not include the node_modules directory
19261926
# and require `npm ci` to be run post-install
19271927
if not os.path.exists(os.path.join(emscripten_dir, 'node_modules')):
@@ -2244,7 +2244,7 @@ def load_releases_info():
22442244

22452245

22462246
def get_installed_sdk_version():
2247-
version_file = sdk_path(os.path.join('upstream', '.emsdk_version'))
2247+
version_file = sdk_path(os.path.join('prebuilt', '.emsdk_version'))
22482248
if not os.path.exists(version_file):
22492249
return None
22502250
with open(version_file) as f:

emsdk_manifest.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
"macos_url": "https://storage.googleapis.com/webassembly/emscripten-releases-builds/mac/%releases-tag%/wasm-binaries.tbz2",
3939
"windows_url": "https://storage.googleapis.com/webassembly/emscripten-releases-builds/win/%releases-tag%/wasm-binaries.zip",
4040
"zipfile_prefix": "%releases-tag%-",
41-
"install_path": "upstream",
41+
"install_path": "prebuilt",
4242
"activated_path": "%installation_dir%/emscripten",
4343
"activated_cfg": "LLVM_ROOT='%installation_dir%/bin';BINARYEN_ROOT='%installation_dir%';EMSCRIPTEN_ROOT='%installation_dir%/emscripten'",
4444
"emscripten_releases_hash": "%releases-tag%"
@@ -51,7 +51,7 @@
5151
"macos_url": "https://storage.googleapis.com/webassembly/emscripten-releases-builds/mac/%releases-tag%/wasm-binaries-arm64.tbz2",
5252
"linux_url": "https://storage.googleapis.com/webassembly/emscripten-releases-builds/linux/%releases-tag%/wasm-binaries-arm64.tbz2",
5353
"zipfile_prefix": "%releases-tag%-",
54-
"install_path": "upstream",
54+
"install_path": "prebuilt",
5555
"activated_path": "%installation_dir%/emscripten",
5656
"activated_cfg": "LLVM_ROOT='%installation_dir%/bin';BINARYEN_ROOT='%installation_dir%';EMSCRIPTEN_ROOT='%installation_dir%/emscripten'",
5757
"emscripten_releases_hash": "%releases-tag%"

test/test_activation.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,9 @@ try {
5858
throw "$repo_root\\node is not added to path."
5959
}
6060

61-
$EMSDK_UPSTREAM_Path = $path_split | Where-Object { $_ -like "$repo_root\upstream\emscripten*" }
61+
$EMSDK_UPSTREAM_Path = $path_split | Where-Object { $_ -like "$repo_root\prebuilt\emscripten*" }
6262
if (!$EMSDK_UPSTREAM_Path) {
63-
throw "$repo_root\\upstream\emscripten is not added to path."
63+
throw "$repo_root\\prebuilt\emscripten is not added to path."
6464
}
6565

6666

test/test_path_preservation.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ try {
4242
$EMSDK_NODE_Path = $path_arr | Where-Object { $_ -like "$repo_root\node*" }
4343
$EMSDK_PYTHON_Path = $path_arr | Where-Object { $_ -like "$repo_root\python*" }
4444
$EMSDK_JAVA_Path = $path_arr | Where-Object { $_ -like "$repo_root\java*" }
45-
$EMSDK_UPSTREAM_Path = $path_arr | Where-Object { $_ -like "$repo_root\upstream\emscripten*" }
45+
$EMSDK_UPSTREAM_Path = $path_arr | Where-Object { $_ -like "$repo_root\prebuilt\emscripten*" }
4646

4747
$number_of_items = $path_arr.count
4848
[System.Collections.ArrayList]$rest_of_path = @()
@@ -52,7 +52,7 @@ try {
5252
($item -like "$repo_root\node*") -or
5353
($item -like "$repo_root\python*") -or
5454
($item -like "$repo_root\java*") -or
55-
($item -like "$repo_root\upstream\emscripten*")
55+
($item -like "$repo_root\prebuilt\emscripten*")
5656
) {
5757
echo "$item is on the PATH"
5858
}

0 commit comments

Comments
 (0)