This reverts commit 394dcf1f3e
.
This commit is contained in:
parent
e485979ab9
commit
27c97daa7a
4 changed files with 0 additions and 76 deletions
|
@ -1,27 +0,0 @@
|
||||||
'use strict';
|
|
||||||
|
|
||||||
import * as process from 'process';
|
|
||||||
import * as child_process from 'child_process';
|
|
||||||
import * as url from 'url';
|
|
||||||
import * as path from 'path';
|
|
||||||
|
|
||||||
const originalPath = process.cwd();
|
|
||||||
|
|
||||||
process.chdir(
|
|
||||||
path.resolve(path.dirname(url.fileURLToPath(import.meta.url)), '..'),
|
|
||||||
);
|
|
||||||
|
|
||||||
if (
|
|
||||||
process.platform == 'win32' &&
|
|
||||||
(process.arch == 'ia32' || process.arch == 'x64')
|
|
||||||
) {
|
|
||||||
child_process.spawn('powershell.exe', [
|
|
||||||
'-ExecutionPolicy',
|
|
||||||
'Bypass',
|
|
||||||
'-File',
|
|
||||||
'install\\win32.ps1',
|
|
||||||
process.arch,
|
|
||||||
]);
|
|
||||||
}
|
|
||||||
|
|
||||||
process.chdir(originalPath);
|
|
|
@ -1,47 +0,0 @@
|
||||||
Set-Location ((Split-Path $MyInvocation.MyCommand.Path -Parent) + '\..\')
|
|
||||||
|
|
||||||
$libraries = @(
|
|
||||||
'libffi-8.dll',
|
|
||||||
'libglib-2.0-0.dll',
|
|
||||||
'libgobject-2.0-0.dll',
|
|
||||||
'libiconv-2.dll',
|
|
||||||
'libintl-8.dll',
|
|
||||||
'libpcre2-8-0.dll'
|
|
||||||
)
|
|
||||||
|
|
||||||
if (($libraries | foreach { Test-Path ([System.IO.Path]::Combine('./node_modules/sharp/build/Release', $_)) }) -contains $false) {
|
|
||||||
New-Item -Path temp -ItemType Directory
|
|
||||||
|
|
||||||
$urls = @(
|
|
||||||
'https://7-zip.org/a/7zr.exe',
|
|
||||||
'https://github.com/mcmilk/7-Zip-zstd/releases/download/v22.01-v1.5.5-R2/7z22.01-zstd-x64.exe'
|
|
||||||
)
|
|
||||||
|
|
||||||
if ($args[0] -eq 'ia32') {
|
|
||||||
$urls += @(
|
|
||||||
'https://repo.msys2.org/mingw/clang32/mingw-w64-clang-i686-glib2-2.76.1-1-any.pkg.tar.zst',
|
|
||||||
'https://repo.msys2.org/mingw/clang32/mingw-w64-clang-i686-gettext-0.21.1-1-any.pkg.tar.zst',
|
|
||||||
'https://repo.msys2.org/mingw/clang32/mingw-w64-clang-i686-libffi-3.4.4-1-any.pkg.tar.zst',
|
|
||||||
'https://repo.msys2.org/mingw/clang32/mingw-w64-clang-i686-libiconv-1.17-3-any.pkg.tar.zst',
|
|
||||||
'https://repo.msys2.org/mingw/clang32/mingw-w64-clang-i686-pcre2-10.42-1-any.pkg.tar.zst'
|
|
||||||
)
|
|
||||||
} else {
|
|
||||||
$urls += @(
|
|
||||||
'https://repo.msys2.org/mingw/clang64/mingw-w64-clang-x86_64-glib2-2.76.1-1-any.pkg.tar.zst',
|
|
||||||
'https://repo.msys2.org/mingw/clang64/mingw-w64-clang-x86_64-gettext-0.21.1-1-any.pkg.tar.zst',
|
|
||||||
'https://repo.msys2.org/mingw/clang64/mingw-w64-clang-x86_64-libffi-3.4.4-1-any.pkg.tar.zst',
|
|
||||||
'https://repo.msys2.org/mingw/clang64/mingw-w64-clang-x86_64-libiconv-1.17-3-any.pkg.tar.zst',
|
|
||||||
'https://repo.msys2.org/mingw/clang64/mingw-w64-clang-x86_64-pcre2-10.42-1-any.pkg.tar.zst'
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
$urls | foreach { Invoke-WebRequest $_ -OutFile ('temp\' + (Split-Path $_ -Leaf)) }
|
|
||||||
|
|
||||||
temp\7zr.exe x -otemp temp\7z22.01-zstd-x64.exe
|
|
||||||
|
|
||||||
Get-ChildItem temp\*.zst | foreach { temp\7z.exe e -otemp $_ }
|
|
||||||
|
|
||||||
Get-ChildItem temp\*.tar | foreach { temp\7z.exe e '-onode_modules/sharp/build/Release' $_ $libraries -r -y }
|
|
||||||
|
|
||||||
Remove-Item temp -Recurse
|
|
||||||
}
|
|
1
package-lock.json
generated
1
package-lock.json
generated
|
@ -7,7 +7,6 @@
|
||||||
"": {
|
"": {
|
||||||
"name": "tileserver-gl",
|
"name": "tileserver-gl",
|
||||||
"version": "4.4.10",
|
"version": "4.4.10",
|
||||||
"hasInstallScript": true,
|
|
||||||
"license": "BSD-2-Clause",
|
"license": "BSD-2-Clause",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@mapbox/glyph-pbf-composite": "0.0.3",
|
"@mapbox/glyph-pbf-composite": "0.0.3",
|
||||||
|
|
|
@ -6,7 +6,6 @@
|
||||||
"bin": "src/main.js",
|
"bin": "src/main.js",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"install": "node install/canvas_sharp_compatibility",
|
|
||||||
"test": "mocha test/**.js --timeout 10000",
|
"test": "mocha test/**.js --timeout 10000",
|
||||||
"lint:yml": "yamllint --schema=CORE_SCHEMA *.{yml,yaml}",
|
"lint:yml": "yamllint --schema=CORE_SCHEMA *.{yml,yaml}",
|
||||||
"lint:js": "npm run lint:eslint && npm run lint:prettier",
|
"lint:js": "npm run lint:eslint && npm run lint:prettier",
|
||||||
|
|
Loading…
Reference in a new issue