mirror of
https://github.com/zen-browser/surfer.git
synced 2025-07-08 01:10:03 +02:00
bump version to 1.6.1 and refactor platform compatibility handling in update logic
This commit is contained in:
parent
4e9b9d3880
commit
c49501d8fe
3 changed files with 13 additions and 47 deletions
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@zen-browser/surfer",
|
"name": "@zen-browser/surfer",
|
||||||
"version": "1.6.0",
|
"version": "1.6.1",
|
||||||
"description": "Simplifying building firefox forks!",
|
"description": "Simplifying building firefox forks!",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"bin": {
|
"bin": {
|
||||||
|
|
|
@ -427,31 +427,16 @@ function setUpdateURLs() {
|
||||||
if (compatMode == 'x86_64') {
|
if (compatMode == 'x86_64') {
|
||||||
suffix = '-generic';
|
suffix = '-generic';
|
||||||
}
|
}
|
||||||
else if (compatMode == 'x86_64-v3') {
|
|
||||||
suffix = '';
|
|
||||||
}
|
|
||||||
else if (compatMode == 'aarch64') {
|
|
||||||
suffix = '-aarch64';
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
if ((process as any).surferPlatform == 'darwin') {
|
if ((process as any).surferPlatform == 'darwin') {
|
||||||
if (compatMode == 'x86_64') {
|
if (compatMode == 'x86_64') {
|
||||||
suffix = '-generic';
|
suffix = '-generic';
|
||||||
}
|
}
|
||||||
else if (compatMode == 'aarch64') {
|
|
||||||
suffix = '';
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
if ((process as any).surferPlatform == 'linux') {
|
if ((process as any).surferPlatform == 'linux') {
|
||||||
if (compatMode == 'x86_64') {
|
if (compatMode == 'x86_64') {
|
||||||
suffix = '-generic';
|
suffix = '-generic';
|
||||||
}
|
}
|
||||||
else if (compatMode == 'x86_64-v3') {
|
|
||||||
suffix = '';
|
|
||||||
}
|
|
||||||
else if (compatMode == 'aarch64') {
|
|
||||||
suffix = '-aarch64';
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
const baseURL = `URL=https://@MOZ_APPUPDATE_HOST@/updates/browser/%BUILD_TARGET%/%CHANNEL%${suffix}/update.xml`
|
const baseURL = `URL=https://@MOZ_APPUPDATE_HOST@/updates/browser/%BUILD_TARGET%/%CHANNEL%${suffix}/update.xml`
|
||||||
const appIni = join(ENGINE_DIR, 'build', 'application.ini.in')
|
const appIni = join(ENGINE_DIR, 'build', 'application.ini.in')
|
||||||
|
|
|
@ -24,22 +24,17 @@ import {
|
||||||
* https://searchfox.org/mozilla-central/source/taskcluster/gecko_taskgraph/util/partials.py
|
* https://searchfox.org/mozilla-central/source/taskcluster/gecko_taskgraph/util/partials.py
|
||||||
*/
|
*/
|
||||||
const ausPlatformsMap = {
|
const ausPlatformsMap = {
|
||||||
linux: [
|
linux64: ['Linux_x86_64-gcc3'],
|
||||||
'Linux_x86_64-gcc3',
|
linuxArm: ['Linux_aarch64-gcc3'],
|
||||||
'Linux_aarch64-gcc3',
|
macosIntel: [
|
||||||
],
|
|
||||||
macos: [
|
|
||||||
'Darwin_x86_64-gcc3-u-i386-x86_64',
|
'Darwin_x86_64-gcc3-u-i386-x86_64',
|
||||||
'Darwin_x86-gcc3-u-i386-x86_64',
|
'Darwin_x86-gcc3-u-i386-x86_64',
|
||||||
'Darwin_x86-gcc3',
|
'Darwin_x86-gcc3',
|
||||||
'Darwin_x86_64-gcc3',
|
'Darwin_x86_64-gcc3',
|
||||||
'Darwin_aarch64-gcc3',
|
|
||||||
],
|
|
||||||
windows: [
|
|
||||||
'WINNT_x86_64-msvc',
|
|
||||||
'WINNT_x86_64-msvc-x64',
|
|
||||||
'WINNT_aarch64-msvc-aarch64',
|
|
||||||
],
|
],
|
||||||
|
macosArm: ['Darwin_aarch64-gcc3'],
|
||||||
|
win64: ['WINNT_x86_64-msvc', 'WINNT_x86_64-msvc-x64'],
|
||||||
|
winArm: ['WINNT_aarch64-msvc-aarch64']
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function getPlatformConfig() {
|
export async function getPlatformConfig() {
|
||||||
|
@ -129,36 +124,21 @@ async function writeUpdateFileToDisk(
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
) {
|
) {
|
||||||
let suffix;
|
let suffix = '';
|
||||||
if ((process as any).surferPlatform == 'win32') {
|
if ((process as any).surferPlatform == 'win32') {
|
||||||
if (compatMode == 'x86_64') {
|
if (compatMode == 'x86_64') {
|
||||||
suffix = '-generic';
|
suffix = '-generic';
|
||||||
}
|
}
|
||||||
else if (compatMode == 'x86_64-v3') {
|
|
||||||
suffix = '';
|
|
||||||
}
|
|
||||||
else if (compatMode == 'aarch64') {
|
|
||||||
suffix = '-aarch64';
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
if ((process as any).surferPlatform == 'linux') {
|
if ((process as any).surferPlatform == 'linux') {
|
||||||
if (compatMode == 'x86_64') {
|
if (compatMode == 'x86_64') {
|
||||||
suffix = '-generic';
|
suffix = '-generic';
|
||||||
}
|
}
|
||||||
else if (compatMode == 'x86_64-v3') {
|
|
||||||
suffix = '';
|
|
||||||
}
|
|
||||||
else if (compatMode == 'aarch64') {
|
|
||||||
suffix = '-aarch64';
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
if ((process as any).surferPlatform == 'darwin') {
|
if ((process as any).surferPlatform == 'darwin') {
|
||||||
if (compatMode == 'x86_64') {
|
if (compatMode == 'x86_64') {
|
||||||
suffix = '-generic';
|
suffix = '-generic';
|
||||||
}
|
}
|
||||||
else if (compatMode == 'aarch64') {
|
|
||||||
suffix = '';
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
const xmlPath = join(
|
const xmlPath = join(
|
||||||
DIST_DIR,
|
DIST_DIR,
|
||||||
|
@ -176,17 +156,18 @@ async function writeUpdateFileToDisk(
|
||||||
|
|
||||||
function getTargets(): string[] {
|
function getTargets(): string[] {
|
||||||
if ((process as any).surferPlatform == 'win32') {
|
if ((process as any).surferPlatform == 'win32') {
|
||||||
return ausPlatformsMap.windows
|
return compatMode == 'aarch64' ? ausPlatformsMap.winArm : ausPlatformsMap.win64;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((process as any).surferPlatform == 'linux') {
|
if ((process as any).surferPlatform == 'linux') {
|
||||||
return ausPlatformsMap.linux
|
return compatMode == 'aarch64' ? ausPlatformsMap.linuxArm : ausPlatformsMap.linux64;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((process as any).surferPlatform == 'darwin') {
|
if ((process as any).surferPlatform == 'darwin') {
|
||||||
return ausPlatformsMap.macos
|
return compatMode == 'aarch64' ? ausPlatformsMap.macosArm : ausPlatformsMap.macosIntel;
|
||||||
}
|
}
|
||||||
return ausPlatformsMap.macos
|
log.error('Unknown platform')
|
||||||
|
return [];
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function generateBrowserUpdateFiles() {
|
export async function generateBrowserUpdateFiles() {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue