Skip to content

Commit

Permalink
fix #523: support for the "mips64le" architecture
Browse files Browse the repository at this point in the history
  • Loading branch information
evanw committed Nov 16, 2020
1 parent d481e62 commit 4c72292
Show file tree
Hide file tree
Showing 6 changed files with 42 additions and 3 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
/npm/esbuild-linux-32/bin/esbuild
/npm/esbuild-linux-64/bin/esbuild
/npm/esbuild-linux-arm64/bin/esbuild
/npm/esbuild-linux-mips64le/bin/esbuild
/npm/esbuild-linux-ppc64le/bin/esbuild
/npm/esbuild-wasm/browser.js
/npm/esbuild-wasm/esbuild.wasm
Expand Down
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Changelog

## Unreleased

* Add support for the `mips64le` architecture ([#523](https://github.com/evanw/esbuild/issues/523))

You should now be able to install esbuild on the `mips64le` architecture. This build target is second-tier as it's not covered by CI, but I tested it in an emulator and it appears to work at the moment.

## 0.8.8

* Add the `--banner` and `--footer` options ([#482](https://github.com/evanw/esbuild/issues/482))
Expand Down
18 changes: 15 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ cmd/esbuild/version.go: version.txt
node -e 'console.log(`package main\n\nconst esbuildVersion = "$(ESBUILD_VERSION)"`)' > cmd/esbuild/version.go

platform-all: cmd/esbuild/version.go test-all
make -j11 \
make -j8 \
platform-windows \
platform-windows-32 \
platform-darwin \
Expand All @@ -65,6 +65,7 @@ platform-all: cmd/esbuild/version.go test-all
platform-linux \
platform-linux-32 \
platform-linux-arm64 \
platform-linux-mips64le \
platform-linux-ppc64le \
platform-wasm \
platform-neutral
Expand Down Expand Up @@ -101,6 +102,9 @@ platform-linux-32:
platform-linux-arm64:
make GOOS=linux GOARCH=arm64 NPMDIR=npm/esbuild-linux-arm64 platform-unixlike

platform-linux-mips64le:
make GOOS=linux GOARCH=mips64le NPMDIR=npm/esbuild-linux-mips64le platform-unixlike

platform-linux-ppc64le:
make GOOS=linux GOARCH=ppc64le NPMDIR=npm/esbuild-linux-ppc64le platform-unixlike

Expand Down Expand Up @@ -133,9 +137,13 @@ publish-all: cmd/esbuild/version.go test-prepublish
publish-linux \
publish-linux-32 \
publish-linux-arm64 \
publish-linux-ppc64le \
publish-linux-mips64le \
publish-linux-ppc64le
# Do these last to avoid race conditions
@echo Enter one-time password:
@read OTP && OTP="$$OTP" make -j2 \
publish-neutral \
publish-wasm
make publish-neutral # Do this after to avoid race conditions
git commit -am "publish $(ESBUILD_VERSION) to npm"
git tag "v$(ESBUILD_VERSION)"
git push origin master "v$(ESBUILD_VERSION)"
Expand Down Expand Up @@ -164,6 +172,9 @@ publish-linux-32: platform-linux-32
publish-linux-arm64: platform-linux-arm64
test -n "$(OTP)" && cd npm/esbuild-linux-arm64 && npm publish --otp="$(OTP)"

publish-linux-mips64le: platform-linux-mips64le
test -n "$(OTP)" && cd npm/esbuild-linux-mips64le && npm publish --otp="$(OTP)"

publish-linux-ppc64le: platform-linux-ppc64le
test -n "$(OTP)" && cd npm/esbuild-linux-ppc64le && npm publish --otp="$(OTP)"

Expand All @@ -183,6 +194,7 @@ clean:
rm -rf npm/esbuild-linux-32/bin
rm -rf npm/esbuild-linux-64/bin
rm -rf npm/esbuild-linux-arm64/bin
rm -rf npm/esbuild-linux-mips64le/bin
rm -rf npm/esbuild-linux-ppc64le/bin
rm -f npm/esbuild-wasm/esbuild.wasm npm/esbuild-wasm/wasm_exec.js
rm -rf npm/esbuild/lib
Expand Down
1 change: 1 addition & 0 deletions lib/install.ts
Original file line number Diff line number Diff line change
Expand Up @@ -259,6 +259,7 @@ const knownUnixlikePackages: Record<string, string> = {
'freebsd x64 LE': 'esbuild-freebsd-64',
'linux arm64 LE': 'esbuild-linux-arm64',
'linux ia32 LE': 'esbuild-linux-32',
'linux mips64el LE': 'esbuild-linux-mips64le',
'linux ppc64 LE': 'esbuild-linux-ppc64le',
'linux x64 LE': 'esbuild-linux-64',
};
Expand Down
3 changes: 3 additions & 0 deletions npm/esbuild-linux-mips64le/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# esbuild

This is the Linux MIPS 64-bit Little Endian binary for esbuild, a JavaScript bundler and minifier. See https://github.com/evanw/esbuild for details.
16 changes: 16 additions & 0 deletions npm/esbuild-linux-mips64le/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"name": "esbuild-linux-mips64le",
"version": "0.8.8",
"description": "The Linux MIPS 64-bit Little Endian binary for esbuild, a JavaScript bundler.",
"repository": "https://github.com/evanw/esbuild",
"license": "MIT",
"os": [
"linux"
],
"cpu": [
"mips64el"
],
"directories": {
"bin": "bin"
}
}

0 comments on commit 4c72292

Please sign in to comment.