Compare commits

...

65 Commits

Author SHA1 Message Date
1269d0234d Add ASCC_REG_PREFIX substitution (#554) 2022-11-08 10:20:55 +02:00
c1f7e8f471 Merge branch hotfix/v7.2.1 into master 2022-10-20 13:04:51 +00:00
fe098a7ee7 Add desktop help installer build / Fix bug 58536 (#541) 2022-10-18 18:33:27 +03:00
aced6c5119 Fix server document-templates files (#540) 2022-10-18 16:58:24 +03:00
94cd21189e Merge branch release/v7.2.0 into hotfix/v7.2.1 2022-10-12 12:26:08 +00:00
4e07941e7a Merge branch release/v7.2.0 into master 2022-10-12 12:26:02 +00:00
a2fcf85e3b Add move_dir method 2022-10-12 10:12:38 +03:00
e830cb9141 Add embed worker to deploy 2022-10-04 15:27:07 +03:00
9bf3985fb2 Fix notes_dst variable (#533) 2022-10-03 11:49:59 +03:00
59ad11b0f4 Update hard-coded version to v7.2.1 2022-09-29 13:14:56 +00:00
ca7d92703e Keep desktop local help for windows xp (#532) 2022-09-29 14:53:39 +03:00
cd040fc148 Create sdkjs-plugins if folder doesn't present 2022-09-28 12:04:15 +03:00
56c6ff289e Fix macOS appcast (#529) 2022-09-27 14:24:20 +03:00
7f41b96e07 Merge branch release/v7.2.0 into master 2022-09-22 12:16:05 +00:00
41d2dfce6a Small fix macOS package build (#522) 2022-09-20 20:32:15 +03:00
0a712e3a68 Fix macOS generate appcast (#521)
* Fix macOS generate appcast

* Small fix
2022-09-20 18:23:17 +03:00
0eca5a6fba Add macOS package cache clean (#518) 2022-09-14 16:06:47 +03:00
8ab3f20eb8 Fix builder installer build (#517) 2022-09-09 14:54:27 +03:00
634119f66a Add windows builder 32-bit package (#516) 2022-09-08 17:26:15 +03:00
28718191d6 Fix deploy plugins (from store) 2022-09-06 13:59:41 +03:00
f5f40c4746 Add desktopeditors-help deploy (#514)
* Add desktopeditors-help deploy

* Fix desktopeditors-help deploy
2022-08-26 16:03:27 +03:00
f6f832a7dd Correct rpath for docbuilder 2022-08-26 09:49:33 +03:00
e50882881d Fix error code 2022-08-24 17:10:09 +03:00
2937163371 Add executable rights 2022-08-24 16:57:47 +03:00
0e6af8fc1b Add .system directory for old linux 2022-08-24 16:53:45 +03:00
4da15cc3bd Bugfix/Fix a bug of downloading vcredist_2013 2022-08-24 11:41:49 +03:00
96312f29e3 Put away vcredist_2013 removing (#512) 2022-08-23 12:42:03 +03:00
32e2956346 Move plugin-dev files to store repo 2022-08-17 13:21:32 +03:00
be820dc843 Merge pull request #511 from ONLYOFFICE/feature/option-to-skip-help-remove
added option to skip remove help from distrib
2022-08-17 13:17:38 +03:00
1a31d76034 debug 2022-08-17 13:15:07 +03:00
73f0fb77bf added option to skip remove help from distrib 2022-08-17 12:58:51 +03:00
263c857ca2 Change libraries dependencies 2022-08-16 19:43:24 +03:00
21e2a8f72e Fix typo 2022-08-16 13:10:03 +03:00
762eec7bf2 Enable vlc on windows for onlyoffice build 2022-08-16 12:08:45 +03:00
ad388af712 Add .net assembly for builder 2022-08-15 18:28:13 +03:00
9e6cd77650 Fix testing appcast urls (#507) 2022-08-10 14:07:58 +03:00
101bbebbe6 Remove '-existingfiles delete' option (#506) 2022-08-10 10:21:40 +03:00
2c27efe936 Feature/Update msi package build (#505)
* Update make_advinst()

* Fix paths

* Fix advinst config

* Add vcredist removing depends on architecture

* Fix advinst return code

* Fix comments

* Add branding to paths

Co-authored-by: Semyon Bezrukov <semen.bezrukov@onlyoffice.com>
2022-08-08 11:46:49 +03:00
6404e71e22 [tools] Escape xml chars 2022-08-05 19:16:38 +03:00
575f835475 Fix builds 2022-08-02 13:32:23 +03:00
ad2cdeebd8 Add package.config copying (#504) 2022-08-02 14:57:19 +05:00
66591ea617 Merge pull request #502 from ONLYOFFICE/feature/fix-params-for-desktop
[desktop] set external help url to linux app binary
2022-07-26 18:48:18 +03:00
e5f4ee1555 Fix deploy new files for builder 2022-07-26 12:01:33 +03:00
b1576abb74 [desktop] set external help url to linux app binary 2022-07-26 11:22:28 +03:00
35aa3e8ee2 Change neew files for builder 2022-07-25 19:39:56 +03:00
9b0c7a1008 Merge pull request #490 from ONLYOFFICE/feature/fix-params-for-desktop
[desktop] fix params for compiling desktop app
2022-07-18 16:05:14 +03:00
ebccbfbbe2 Merge branch 'hotfix/v7.1.1' into release/v7.2.0 2022-07-18 15:45:44 +03:00
e921585baa Merge branch hotfix/v7.1.1 into master 2022-07-18 09:55:05 +00:00
9662f10652 Fix marketpace deploy 2022-07-18 10:58:39 +03:00
9b374f2683 Add marketplace plugin to package (develop/server) 2022-07-15 15:29:40 +03:00
a5eceac4c5 Exclude .git folder from templates 2022-07-13 13:42:51 +03:00
1d26beacfb Clarify development info more (#494)
* Clarify development info more

Without both those folders docker run process is failed
2022-07-11 18:58:05 +03:00
e0352bdc4a Add some more notes 2022-07-11 18:25:46 +03:00
1d50755d9b Clarify develop run commands
We got a discussion to make it simpler with @trofim24
Because before it was not 100% clear that you *need* to
clone `build_tools` repo to run development server
2022-07-11 18:25:46 +03:00
200a3c698a Fix library dependency 2022-07-11 13:18:21 +03:00
3b3fa59307 Fix web-apps help version url (#492) 2022-07-08 17:56:48 +03:00
9ac28dfb65 Update hard-coded version to v7.2.0 2022-07-08 13:08:07 +00:00
5b265245a4 Update build.py 2022-07-08 09:58:42 +03:00
9e974d30db [desktop] fix params for compiling desktop app 2022-07-08 09:55:51 +03:00
7b8f8184b0 [desktop] for support external help in web-apps 2022-07-07 00:11:14 +03:00
254b413617 Fix encoding (#487) 2022-07-06 18:03:21 +03:00
afbe93c5cb Merge branch hotfix/v7.1.1 into master 2022-06-01 16:17:23 +00:00
554e6489e5 Update hard-coded version to v7.1.1 2022-05-18 16:08:22 +00:00
be06b3c2c8 Merge branch release/v7.1.0 into master 2022-05-12 13:16:07 +00:00
bfcc577df1 Merge branch hotfix/v7.0.2 into master 2022-04-05 12:20:30 +00:00
19 changed files with 355 additions and 129 deletions

View File

@ -29,12 +29,12 @@ core_android {
}
addSubProject(cryptopp, $$CORE_ROOT_DIR/Common/3dParty/cryptopp/project/cryptopp.pro)
addSubProject(kernel, $$CORE_ROOT_DIR/Common/kernel.pro,\
cryptopp)
addSubProject(unicodeconverter, $$CORE_ROOT_DIR/UnicodeConverter/UnicodeConverter.pro,\
kernel)
cryptopp)
addSubProject(kernel, $$CORE_ROOT_DIR/Common/kernel.pro,\
unicodeconverter)
addSubProject(network, $$CORE_ROOT_DIR/Common/Network/network.pro,\
kernel)
kernel unicodeconverter)
addSubProject(graphics, $$CORE_ROOT_DIR/DesktopEditor/graphics/pro/graphics.pro,\
kernel unicodeconverter)
addSubProject(pdfwriter, $$CORE_ROOT_DIR/PdfWriter/PdfWriter.pro,\

View File

@ -6,7 +6,7 @@ but don't want to compile pretty compilcated core product to make those changes.
## Installing ONLYOFFICE Docs
## How to use - Linux
## How to use - Linux or macOS
**Note**: You need the latest Docker version installed.
@ -23,9 +23,11 @@ docker pull onlyoffice/documentserver
### Create develop image
To create a image with the ability to include external non-minified sdkjs code,
use the following command from the dockerfile directory:
use the following command:
```bash
git clone https://github.com/ONLYOFFICE/build_tools.git
cd build_tools/develop
docker build -t documentserver-develop .
```
@ -35,9 +37,11 @@ docker build -t documentserver-develop .
To connect external folders to the container,
you need to pass the "-v" parameter
along with the relative paths to the required folders.
along with the relative paths to the required folders.
The folders `sdkjs` and `web-apps` are required for proper development workflow
**For example, let's connect the external folders "sdkjs" and "web-apps" to the container:**
* `sdkjs` repo is located [here](https://github.com/ONLYOFFICE/sdkjs/)
* `web-apps` repo is located [here](https://github.com/ONLYOFFICE/web-apps/)
```bash
docker run -i -t -d -p 80:80 --restart=always \

30
make.py
View File

@ -70,20 +70,26 @@ if ("1" == base.get_env("OO_ONLY_BUILD_JS")):
make_common.make()
# build updmodule for desktop (only for windows version)
if ("windows" == base.host_platform()) and (config.check_option("module", "desktop")):
config.extend_option("config", "updmodule")
config.extend_option("qmake_addon", "LINK=https://download.onlyoffice.com/install/desktop/editors/windows/onlyoffice/appcast.xml")
if config.check_option("module", "desktop"):
config.extend_option("qmake_addon", "URL_WEBAPPS_HELP=https://download.onlyoffice.com/install/desktop/editors/help/v" + base.get_env('PRODUCT_VERSION') + "-1/apps")
if not base.is_file(base_dir + "/tools/WinSparkle-0.7.0.zip"):
base.cmd("curl.exe", ["https://d2ettrnqo7v976.cloudfront.net/winsparkle/WinSparkle-0.7.0.zip", "--output", base_dir + "/tools/WinSparkle-0.7.0.zip"])
if not base.is_dir(base_dir + "/tools/WinSparkle-0.7.0"):
base.cmd("7z.exe", ["x", base_dir + "/tools/WinSparkle-0.7.0.zip", "-otools"])
if "windows" == base.host_platform():
config.extend_option("config", "updmodule")
config.extend_option("qmake_addon", "LINK=https://download.onlyoffice.com/install/desktop/editors/windows/onlyoffice/appcast.xml")
base.create_dir(base_dir + "/../desktop-apps/win-linux/3dparty/WinSparkle")
#base.copy_dir(base_dir + "/tools/WinSparkle-0.7.0/include", base_dir + "/../desktop-apps/win-linux/3dparty/WinSparkle/include")
base.copy_dir(base_dir + "/tools/WinSparkle-0.7.0/Release", base_dir + "/../desktop-apps/win-linux/3dparty/WinSparkle/win_32")
base.copy_dir(base_dir + "/tools/WinSparkle-0.7.0/x64/Release", base_dir + "/../desktop-apps/win-linux/3dparty/WinSparkle/win_64")
if not base.is_file(base_dir + "/tools/WinSparkle-0.7.0.zip"):
base.cmd("curl.exe", ["https://d2ettrnqo7v976.cloudfront.net/winsparkle/WinSparkle-0.7.0.zip", "--output", base_dir + "/tools/WinSparkle-0.7.0.zip"])
if not base.is_dir(base_dir + "/tools/WinSparkle-0.7.0"):
base.cmd("7z.exe", ["x", base_dir + "/tools/WinSparkle-0.7.0.zip", "-otools"])
base.create_dir(base_dir + "/../desktop-apps/win-linux/3dparty/WinSparkle")
#base.copy_dir(base_dir + "/tools/WinSparkle-0.7.0/include", base_dir + "/../desktop-apps/win-linux/3dparty/WinSparkle/include")
base.copy_dir(base_dir + "/tools/WinSparkle-0.7.0/Release", base_dir + "/../desktop-apps/win-linux/3dparty/WinSparkle/win_32")
base.copy_dir(base_dir + "/tools/WinSparkle-0.7.0/x64/Release", base_dir + "/../desktop-apps/win-linux/3dparty/WinSparkle/win_64")
if ("windows" == base.host_platform()):
base.set_env("VIDEO_PLAYER_VLC_DIR", base_dir + "/../desktop-sdk/ChromiumBasedEditors/videoplayerlib/vlc")
# build
build.make()

View File

@ -175,6 +175,14 @@ def create_dir(path):
os.makedirs(path2)
return
def move_dir(src, dst):
if is_dir(dst):
delete_dir(dst)
if is_dir(src):
copy_dir(src, dst)
delete_dir(src)
return
def copy_dir(src, dst):
if is_dir(dst):
delete_dir(dst)
@ -240,6 +248,9 @@ def copy_exe(src, dst, name):
return
def replaceInFile(path, text, textReplace):
if not is_file(path):
print("[replaceInFile] file not exist: " + path)
return
filedata = ""
with open(get_path(path), "r") as file:
filedata = file.read()
@ -249,6 +260,9 @@ def replaceInFile(path, text, textReplace):
file.write(filedata)
return
def replaceInFileRE(path, pattern, textReplace):
if not is_file(path):
print("[replaceInFile] file not exist: " + path)
return
filedata = ""
with open(get_path(path), "r") as file:
filedata = file.read()
@ -447,14 +461,13 @@ def get_repositories():
result["core"] = [False, False]
result["sdkjs"] = [False, False]
result.update(get_sdkjs_addons())
result.update(get_sdkjs_plugins())
result.update(get_sdkjs_plugins_server())
result["onlyoffice.github.io"] = [False, False]
result["web-apps"] = [False, False]
result.update(get_web_apps_addons())
result["dictionaries"] = [False, False]
if config.check_option("module", "builder"):
result["DocumentBuilder"] = [False, False]
result["document-templates"] = [False, False]
if config.check_option("module", "desktop"):
result["desktop-sdk"] = [False, False]
@ -824,22 +837,6 @@ def get_web_apps_addons():
result[name] = [True, False]
return result
def get_plugins(plugins_list=""):
result = {}
if ("" == plugins_list):
return result
plugins_list = plugins_list.rsplit(", ")
plugins_dir = get_script_dir() + "/../../sdkjs-plugins"
for name in plugins_list:
result["plugin-" + name] = [True, plugins_dir]
return result
def get_sdkjs_plugins():
return get_plugins(config.option("sdkjs-plugin"))
def get_sdkjs_plugins_server():
return get_plugins(config.option("sdkjs-plugin-server"))
def sdkjs_addons_param():
if ("" == config.option("sdkjs-addons")):
return []
@ -1006,7 +1003,7 @@ def get_file_last_modified_url(url):
def mac_correct_rpath_binary(path, libs):
for lib in libs:
cmd("install_name_tool", ["-change", "lib" + lib + ".dylib", "@rpath/lib" + lib + ".dylib", path])
cmd("install_name_tool", ["-change", "lib" + lib + ".dylib", "@rpath/lib" + lib + ".dylib", path], True)
return
def mac_correct_rpath_library(name, libs):
@ -1017,20 +1014,20 @@ def mac_correct_rpath_x2t(dir):
os.chdir(dir)
mac_correct_rpath_library("icudata.58", [])
mac_correct_rpath_library("icuuc.58", ["icudata.58"])
mac_correct_rpath_library("UnicodeConverter", ["icuuc.58", "icudata.58", "kernel"])
mac_correct_rpath_library("kernel", [])
mac_correct_rpath_library("kernel_network", ["kernel"])
mac_correct_rpath_library("UnicodeConverter", ["icuuc.58", "icudata.58"])
mac_correct_rpath_library("kernel", ["UnicodeConverter"])
mac_correct_rpath_library("kernel_network", ["UnicodeConverter", "kernel"])
mac_correct_rpath_library("graphics", ["UnicodeConverter", "kernel"])
mac_correct_rpath_library("doctrenderer", ["UnicodeConverter", "kernel", "kernel_network", "graphics"])
mac_correct_rpath_library("HtmlFile2", ["UnicodeConverter", "kernel", "kernel_network", "graphics"])
mac_correct_rpath_library("EpubFile", ["kernel", "HtmlFile2", "graphics"])
mac_correct_rpath_library("EpubFile", ["UnicodeConverter", "kernel", "HtmlFile2", "graphics"])
mac_correct_rpath_library("Fb2File", ["UnicodeConverter", "kernel", "graphics"])
mac_correct_rpath_library("HtmlRenderer", ["UnicodeConverter", "kernel", "graphics"])
mac_correct_rpath_library("PdfWriter", ["UnicodeConverter", "kernel", "graphics"])
mac_correct_rpath_library("DjVuFile", ["kernel", "UnicodeConverter", "graphics", "PdfWriter"])
mac_correct_rpath_library("PdfReader", ["kernel", "UnicodeConverter", "graphics", "PdfWriter", "HtmlRenderer"])
mac_correct_rpath_library("XpsFile", ["kernel", "UnicodeConverter", "graphics", "PdfWriter"])
mac_correct_rpath_library("DocxRenderer", ["kernel", "UnicodeConverter", "graphics"])
mac_correct_rpath_library("PdfWriter", ["UnicodeConverter", "kernel", "graphics", "kernel_network"])
mac_correct_rpath_library("DjVuFile", ["UnicodeConverter", "kernel", "graphics", "PdfWriter"])
mac_correct_rpath_library("PdfReader", ["UnicodeConverter", "kernel", "graphics", "PdfWriter", "HtmlRenderer"])
mac_correct_rpath_library("XpsFile", ["UnicodeConverter", "kernel", "graphics", "PdfWriter"])
mac_correct_rpath_library("DocxRenderer", ["UnicodeConverter", "kernel", "graphics"])
cmd("chmod", ["-v", "+x", "./x2t"])
cmd("install_name_tool", ["-add_rpath", "@executable_path", "./x2t"], True)
mac_correct_rpath_binary("./x2t", ["icudata.58", "icuuc.58", "UnicodeConverter", "kernel", "kernel_network", "graphics", "PdfWriter", "HtmlRenderer", "PdfReader", "XpsFile", "DjVuFile", "HtmlFile2", "Fb2File", "EpubFile", "doctrenderer", "DocxRenderer"])
@ -1045,6 +1042,15 @@ def mac_correct_rpath_x2t(dir):
os.chdir(cur_dir)
return
def mac_correct_rpath_docbuilder(dir):
cur_dir = os.getcwd()
os.chdir(dir)
cmd("chmod", ["-v", "+x", "./docbuilder"])
cmd("install_name_tool", ["-add_rpath", "@executable_path", "./docbuilder"], True)
mac_correct_rpath_binary("./docbuilder", ["icudata.58", "icuuc.58", "UnicodeConverter", "kernel", "kernel_network", "graphics", "PdfWriter", "HtmlRenderer", "PdfReader", "XpsFile", "DjVuFile", "HtmlFile2", "Fb2File", "EpubFile", "doctrenderer", "DocxRenderer"])
os.chdir(cur_dir)
return
def mac_correct_rpath_desktop(dir):
mac_correct_rpath_x2t(dir + "/converter")
cur_dir = os.getcwd()
@ -1088,7 +1094,7 @@ def common_check_version(name, good_version, clean_func):
return
def copy_sdkjs_plugin(src_dir, dst_dir, name, is_name_as_guid=False, is_desktop_local=False):
src_dir_path = src_dir + "/plugin-" + name
src_dir_path = src_dir + "/" + name
if not is_dir(src_dir_path):
src_dir_path = src_dir + "/" + name
if not is_file(src_dir_path + "/config.json"):
@ -1124,7 +1130,7 @@ def copy_sdkjs_plugin(src_dir, dst_dir, name, is_name_as_guid=False, is_desktop_
return
def copy_sdkjs_plugins(dst_dir, is_name_as_guid=False, is_desktop_local=False):
plugins_dir = get_script_dir() + "/../../sdkjs-plugins"
plugins_dir = get_script_dir() + "/../../onlyoffice.github.io/sdkjs-plugins/content"
plugins_list_config = config.option("sdkjs-plugin")
if ("" == plugins_list_config):
return
@ -1134,7 +1140,7 @@ def copy_sdkjs_plugins(dst_dir, is_name_as_guid=False, is_desktop_local=False):
return
def copy_sdkjs_plugins_server(dst_dir, is_name_as_guid=False, is_desktop_local=False):
plugins_dir = get_script_dir() + "/../../sdkjs-plugins"
plugins_dir = get_script_dir() + "/../../onlyoffice.github.io/sdkjs-plugins/content"
plugins_list_config = config.option("sdkjs-plugin-server")
if ("" == plugins_list_config):
return
@ -1231,6 +1237,16 @@ def make_sln(directory, args, is_no_errors):
os.environ.update(old_env)
return
def make_sln_project(directory, sln_path):
args = []
args.append(sln_path)
args.append("/Rebuild")
if (config.check_option("platform", "win_64")):
make_sln(directory, args + ["\"Release|x64\""], True)
if True:#(config.check_option("platform", "win_32")):
make_sln(directory, args + ["\"Release|Win32\""], True)
return
def get_android_sdk_home():
ndk_root_path = get_env("ANDROID_NDK_ROOT")
if (-1 != ndk_root_path.find("/ndk/")):
@ -1270,3 +1286,57 @@ def copy_v8_files(core_dir, deploy_dir, platform, is_xp=False):
else:
copy_files(directory_v8 + platform + "/icudt*.dat", deploy_dir + "/")
return
def clone_marketplace_plugin(out_dir, is_name_as_guid=False):
old_cur = os.getcwd()
os.chdir(out_dir)
git_update("onlyoffice.github.io", False, True)
os.chdir(old_cur)
dst_dir_name = "marketplace"
if is_name_as_guid:
config_content = readFile(out_dir + "/onlyoffice.github.io/store/plugin/config.json")
index_start = config_content.find("\"asc.{")
index_start += 5
index_end = config_content.find("}", index_start)
index_end += 1
guid = config_content[index_start:index_end]
dst_dir_name = guid
dst_dir_path = out_dir + "/" + dst_dir_name
if is_dir(dst_dir_path):
delete_dir(dst_dir_path)
copy_dir(out_dir + "/onlyoffice.github.io/store/plugin", dst_dir_path)
delete_dir_with_access_error(out_dir + "/onlyoffice.github.io")
return
def correctPathForBuilder(path):
replace_value = "../../../build/"
if (config.option("branding") != ""):
replace_value += (config.option("branding") + "/")
replace_value += "lib/"
if (config.check_option("config", "debug")):
replace_value += ("debug/")
if (replace_value == "../../../build/lib/"):
return ""
new_path = path + ".bak"
copy_file(path, new_path)
replaceInFile(path, "../../../build/lib/", replace_value)
return new_path
def restorePathForBuilder(new_path):
if ("" == new_path):
return
old_path = new_path[:-4]
delete_file(old_path)
copy_file(new_path, old_path)
delete_file(new_path);
return
def generate_check_linux_system(build_tools_dir, out_dir):
create_dir(out_dir + "/.system")
copy_file(build_tools_dir + "/tools/linux/check_system/check.sh", out_dir + "/.system/check.sh")
copy_file(build_tools_dir + "/tools/linux/check_system/libstdc++.so.6", out_dir + "/.system/libstdc++.so.6")
return

View File

@ -51,7 +51,7 @@ def make_pro_file(makefiles_dir, pro_file):
# qmake ADDON
qmake_addon = []
if ("" != config.option("qmake_addon")):
qmake_addon.append(config.option("qmake_addon"))
qmake_addon = config.option("qmake_addon").split()
if not base.is_file(qt_dir + "/bin/qmake") and not base.is_file(qt_dir + "/bin/qmake.exe"):
print("THIS PLATFORM IS NOT SUPPORTED")
@ -79,7 +79,7 @@ def make_pro_file(makefiles_dir, pro_file):
qmake_bat.append("if exist ./" + makefiles_dir + "/build.makefile_" + file_suff + " del /F ./" + makefiles_dir + "/build.makefile_" + file_suff)
qmake_addon_string = ""
if ("" != config.option("qmake_addon")):
qmake_addon_string = " \"" + config.option("qmake_addon") + "\""
qmake_addon_string = " " + (" ").join(["\"" + addon + "\"" for addon in qmake_addon])
qmake_bat.append("call \"" + qt_dir + "/bin/qmake\" -nocache " + pro_file + " \"CONFIG+=" + config_param + "\"" + qmake_addon_string)
if ("1" == config.option("clean")):
qmake_bat.append("call nmake clean -f " + makefiles_dir + "/build.makefile_" + file_suff)
@ -97,25 +97,17 @@ def make_pro_file(makefiles_dir, pro_file):
# make build.pro
def make():
is_no_brandind_build = base.is_file("config")
make_pro_file("makefiles", "build.pro")
if config.check_option("module", "builder") and base.is_windows() and is_no_brandind_build:
if config.check_option("module", "builder") and base.is_windows() and "onlyoffice" == config.branding():
# check replace
replace_path_lib = ""
replace_path_lib_file = os.getcwd() + "/../core/DesktopEditor/doctrenderer/docbuilder.com/docbuilder.h"
option_branding = config.option("branding")
if (option_branding != ""):
replace_path_lib = "../../../build/" + option_branding + "/lib/"
# replace
if (replace_path_lib != ""):
base.replaceInFile(replace_path_lib_file, "../../../build/lib/", replace_path_lib)
new_replace_path = base.correctPathForBuilder(os.getcwd() + "/../core/DesktopEditor/doctrenderer/docbuilder.com/docbuilder.h")
if ("2019" == config.option("vs-version")):
base.make_sln("../core/DesktopEditor/doctrenderer/docbuilder.com", ["docbuilder.com_2019.sln", "/Rebuild", "\"Release|x64\""], True)
base.make_sln("../core/DesktopEditor/doctrenderer/docbuilder.com", ["docbuilder.com_2019.sln", "/Rebuild", "\"Release|Win32\""], True)
base.make_sln_project("../core/DesktopEditor/doctrenderer/docbuilder.com", "docbuilder.com_2019.sln")
if (True):
new_path_net = base.correctPathForBuilder(os.getcwd() + "/../core/DesktopEditor/doctrenderer/docbuilder.net/src/docbuilder.net.cpp")
base.make_sln_project("../core/DesktopEditor/doctrenderer/docbuilder.net/src", "docbuilder.net.sln")
base.restorePathForBuilder(new_path_net)
else:
base.make_sln("../core/DesktopEditor/doctrenderer/docbuilder.com", ["docbuilder.com.sln", "/Rebuild", "\"Release|x64\""], True)
base.make_sln("../core/DesktopEditor/doctrenderer/docbuilder.com", ["docbuilder.com.sln", "/Rebuild", "\"Release|Win32\""], True)
# restore
if (replace_path_lib != ""):
base.replaceInFile(replace_path_lib_file, replace_path_lib, "../../../build/lib/")
base.make_sln_project("../core/DesktopEditor/doctrenderer/docbuilder.com", "docbuilder.com.sln")
base.restorePathForBuilder(new_replace_path)
return

View File

@ -51,6 +51,9 @@ def make():
else:
base.copy_exe(core_build_dir + "/bin/" + platform_postfix, root_dir, "x2t")
if (native_platform == "linux_64"):
base.generate_check_linux_system(git_dir + "/build_tools", root_dir)
# icu
if (0 == platform.find("win")):
base.copy_file(core_dir + "/Common/3dParty/icu/" + platform + "/build/icudt58.dll", root_dir + "/icudt58.dll")
@ -77,7 +80,7 @@ def make():
# app
base.copy_exe(core_build_dir + "/bin/" + platform_postfix, root_dir, "docbuilder")
base.generate_doctrenderer_config(root_dir + "/DoctRenderer.config", "./", "builder")
base.copy_dir(git_dir + "/DocumentBuilder/empty", root_dir + "/empty")
base.copy_dir(git_dir + "/document-templates/new/en-US", root_dir + "/empty")
# js
base.copy_dir(base_dir + "/js/" + branding + "/builder/sdkjs", root_dir + "/sdkjs")
@ -93,8 +96,10 @@ def make():
if ("win_64" == platform):
base.copy_file(core_dir + "/DesktopEditor/doctrenderer/docbuilder.com/x64/Release/docbuilder.com.dll", root_dir + "/docbuilder.com.dll")
base.copy_file(core_dir + "/DesktopEditor/doctrenderer/docbuilder.net/deploy/win_64/docbuilder.net.dll", root_dir + "/docbuilder.net.dll")
elif ("win_32" == platform):
base.copy_file(core_dir + "/DesktopEditor/doctrenderer/docbuilder.com/Win32/Release/docbuilder.com.dll", root_dir + "/docbuilder.com.dll")
base.copy_file(core_dir + "/DesktopEditor/doctrenderer/docbuilder.net/deploy/win_32/docbuilder.net.dll", root_dir + "/docbuilder.net.dll")
# correct ios frameworks
if ("ios" == platform):
@ -102,6 +107,7 @@ def make():
if (0 == platform.find("mac")):
base.mac_correct_rpath_x2t(root_dir)
base.mac_correct_rpath_docbuilder(root_dir)
return

View File

@ -62,10 +62,14 @@ def make():
else:
base.copy_exe(core_build_dir + "/bin/" + platform_postfix, root_dir + "/converter", "x2t")
if (native_platform == "linux_64"):
base.generate_check_linux_system(git_dir + "/build_tools", root_dir + "/converter")
# icu
if (0 == platform.find("win")):
base.copy_file(core_dir + "/Common/3dParty/icu/" + platform + "/build/icudt58.dll", root_dir + "/converter/icudt58.dll")
base.copy_file(core_dir + "/Common/3dParty/icu/" + platform + "/build/icuuc58.dll", root_dir + "/converter/icuuc58.dll")
base.copy_file(git_dir + "/desktop-apps/common/converter/package.config", root_dir + "/converter/package.config")
if (0 == platform.find("linux")):
base.copy_file(core_dir + "/Common/3dParty/icu/" + platform + "/build/libicudata.so.58", root_dir + "/converter/libicudata.so.58")
@ -153,13 +157,50 @@ def make():
elif (0 == platform.find("linux")):
base.copy_file(git_dir + "/desktop-apps/win-linux/" + apps_postfix + "/DesktopEditors", root_dir + "/DesktopEditors")
base.copy_lib(core_build_dir + "/lib/" + platform_postfix + ("/xp" if isWindowsXP else ""), root_dir, "videoplayer")
if ("" != base.get_env("VIDEO_PLAYER_VLC_DIR")):
vlc_dir = git_dir + "/desktop-sdk/ChromiumBasedEditors/videoplayerlib/vlc/"
if (0 == platform.find("win")):
base.copy_file(vlc_dir + platform + "/bin/libvlc.dll", root_dir + "/libvlc.dll")
base.copy_file(vlc_dir + platform + "/bin/libvlccore.dll", root_dir + "/libvlccore.dll")
base.copy_file(vlc_dir + platform + "/bin/VLCQtCore.dll", root_dir + "/VLCQtCore.dll")
base.copy_file(vlc_dir + platform + "/bin/VLCQtWidgets.dll", root_dir + "/VLCQtWidgets.dll")
else:
base.copy_file(vlc_dir + platform + "/bin/libvlc.so", root_dir + "/libvlc.so")
base.copy_file(vlc_dir + platform + "/bin/libvlc.so.5", root_dir + "/libvlc.so.5")
base.copy_file(vlc_dir + platform + "/bin/libvlccore.so", root_dir + "/libvlccore.so")
base.copy_file(vlc_dir + platform + "/bin/libvlccore.so.8", root_dir + "/libvlccore.so.8")
base.copy_file(vlc_dir + platform + "/bin/VLCQtCore.so", root_dir + "/VLCQtCore.so")
base.copy_file(vlc_dir + platform + "/bin/VLCQtWidgets.so", root_dir + "/VLCQtWidgets.so")
if isWindowsXP:
base.copy_lib(core_build_dir + "/lib/" + platform + "/mediaplayer/xp", root_dir, "videoplayer")
else:
base.copy_lib(core_build_dir + "/lib/" + platform + "/mediaplayer", root_dir, "videoplayer")
base.copy_dir(vlc_dir + platform + "/bin/plugins", root_dir + "/plugins")
else:
base.copy_lib(core_build_dir + "/lib/" + platform_postfix + ("/xp" if isWindowsXP else ""), root_dir, "videoplayer")
base.create_dir(root_dir + "/editors")
base.copy_dir(base_dir + "/js/" + branding + "/desktop/sdkjs", root_dir + "/editors/sdkjs")
base.copy_dir(base_dir + "/js/" + branding + "/desktop/web-apps", root_dir + "/editors/web-apps")
base.copy_dir(git_dir + "/desktop-sdk/ChromiumBasedEditors/resources/local", root_dir + "/editors/sdkjs/common/Images/local")
# desktopeditors-help
root_help_dir = root_dir + "-help"
if (base.is_dir(root_help_dir)):
base.delete_dir(root_help_dir)
for i in ["documenteditor", "presentationeditor", "spreadsheeteditor"]:
base.copy_dir(
base_dir + "/js/" + branding + "/desktop/web-apps/apps/%s/main/resources/help" % i,
root_help_dir + "/editors/web-apps/apps/%s/main/resources/help" % i)
if ("1" != config.option("preinstalled-help") and not isWindowsXP):
# remove help from install until web-apps containes help
base.delete_dir(root_dir + "/editors/web-apps/apps/documenteditor/main/resources/help")
base.delete_dir(root_dir + "/editors/web-apps/apps/presentationeditor/main/resources/help")
base.delete_dir(root_dir + "/editors/web-apps/apps/spreadsheeteditor/main/resources/help")
base.create_dir(root_dir + "/editors/sdkjs-plugins")
base.copy_sdkjs_plugins(root_dir + "/editors/sdkjs-plugins", True, True)
# remove some default plugins

View File

@ -87,6 +87,9 @@ def make():
base.copy_lib(core_build_dir + "/lib/" + platform_postfix, converter_dir, "DocxRenderer")
base.copy_exe(core_build_dir + "/bin/" + platform_postfix, converter_dir, "x2t")
if (native_platform == "linux_64"):
base.generate_check_linux_system(git_dir + "/build_tools", converter_dir)
base.generate_doctrenderer_config(converter_dir + "/DoctRenderer.config", "../../../", "server")
# icu
@ -106,12 +109,15 @@ def make():
# builder
base.copy_exe(core_build_dir + "/bin/" + platform_postfix, converter_dir, "docbuilder")
base.copy_dir(git_dir + "/DocumentBuilder/empty", converter_dir + "/empty")
base.copy_dir(git_dir + "/document-templates/new/en-US", converter_dir + "/empty")
# js
js_dir = root_dir
base.copy_dir(base_dir + "/js/" + branding + "/builder/sdkjs", js_dir + "/sdkjs")
base.copy_dir(base_dir + "/js/" + branding + "/builder/web-apps", js_dir + "/web-apps")
# add embed worker code
base.cmd_in_dir(git_dir + "/sdkjs/common/embed", "python", ["make.py", js_dir + "/web-apps/apps/api/documents/api.js"])
# plugins
base.create_dir(js_dir + "/sdkjs-plugins")
@ -122,6 +128,8 @@ def make():
base.download("https://onlyoffice.github.io/sdkjs-plugins/v1/plugins-ui.js", js_dir + "/sdkjs-plugins/v1/plugins-ui.js")
base.download("https://onlyoffice.github.io/sdkjs-plugins/v1/plugins.css", js_dir + "/sdkjs-plugins/v1/plugins.css")
base.support_old_versions_plugins(js_dir + "/sdkjs-plugins")
base.clone_marketplace_plugin(root_dir + "/sdkjs-plugins")
# tools
tools_dir = root_dir + "/server/tools"
@ -159,8 +167,8 @@ def make():
#document-templates
document_templates_files = server_dir + '/../document-templates'
document_templates = build_server_dir + '/../document-templates'
base.create_dir(document_templates)
base.copy_dir(document_templates_files, document_templates)
base.copy_dir(document_templates_files + '/new', document_templates + '/new')
base.copy_dir(document_templates_files + '/sample', document_templates + '/sample')
#license
license_file1 = server_dir + '/LICENSE.txt'

View File

@ -62,7 +62,12 @@ def make():
print("-----------------------------------------------------------")
base.generate_doctrenderer_config("./DoctRenderer.config", "../../../sdkjs/deploy/", "server", "../../../web-apps/vendor/")
if not base.is_dir(git_dir + "/sdkjs-plugins"):
base.create_dir(git_dir + "/sdkjs-plugins")
base.support_old_versions_plugins(git_dir + "/sdkjs-plugins")
base.clone_marketplace_plugin(git_dir + "/sdkjs-plugins")
if not base.is_dir(git_dir + "/fonts"):
base.create_dir(git_dir + "/fonts")

View File

@ -34,9 +34,6 @@ config.parse_defaults()
repositories = base.get_repositories()
# Add other plugins
repositories.update(base.get_plugins('autocomplete, easybib, wordpress'))
# Add other repositories
if config.check_option("module", "builder"):
repositories['document-builder-package'] = [False, False]

View File

@ -39,8 +39,6 @@ config.parse_defaults()
repositories = base.get_repositories()
# Add other plugins
repositories.update(base.get_plugins('autocomplete, easybib, glavred, wordpress'))
# Add other repositories
repositories['core-ext'] = [True, False]

View File

@ -17,7 +17,7 @@ if product == 'desktop':
product_name = 'Desktop Editors'
product_name_s = product_name.replace(' ','')
package_name = company_name + '_' + product_name_s
vcredist_list = ['2022']
vcredist_list = ['2022', '2013']
update_changes_list = {
'en': "changes",
'ru': "changes_ru"

View File

@ -76,7 +76,11 @@ def download_isxdl():
def make_innosetup():
log("\n=== Build innosetup project\n")
iscc_args = ["/DVERSION=" + package_version]
iscc_args = [
"/Qp",
"/DVERSION=" + package_version,
"/DARCH=" + arch
]
if not onlyoffice:
iscc_args.append("/DBRANDING_DIR=" + get_abspath(git_dir, branding, build_dir, "exe"))
if sign:

View File

@ -26,8 +26,9 @@ def make():
#
def make_windows():
global package_version, sign, machine, arch, xp, iscc_args, source_dir, \
innosetup_file, innosetup_update_file, advinst_file, portable_zip_file
global package_version, sign, machine, arch, xp, iscc_args, \
source_dir, source_help_dir, innosetup_file, innosetup_help_file, \
innosetup_update_file, advinst_file, portable_zip_file
set_cwd(get_abspath(git_dir, build_dir))
@ -58,6 +59,7 @@ def make_windows():
suffix = arch + ("_xp" if xp else "")
source_prefix = "win_" + machine + ("_xp" if xp else "")
source_dir = get_path("%s/%s/%s/%s" % (out_dir, source_prefix, company_name_l, product_name_s))
source_help_dir = source_dir + "-help"
if target.startswith('innosetup'):
for year in vcredist_list:
@ -73,6 +75,10 @@ def make_windows():
if 'winsparkle-files' in targets:
make_winsparkle_files()
if target.startswith('innosetup-help'):
innosetup_help_file = "%s_Help_%s_%s.exe" % (package_name, package_version, suffix)
make_innosetup_help()
if target.startswith('advinst'):
advinst_file = "%s_%s_%s.msi" % (package_name, package_version, suffix)
make_advinst()
@ -119,6 +125,29 @@ def make_innosetup():
cmd("iscc", iscc_args + ["common.iss"])
return
def make_innosetup_help():
log("\n=== Build innosetup help project\n")
global iscc_args
iscc_args = [
"/Qp",
"/DsAppVersion=" + package_version,
"/DDEPLOY_PATH=" + source_help_dir,
"/D_ARCH=" + machine
]
if onlyoffice:
iscc_args.append("/D_ONLYOFFICE=1")
else:
iscc_args.append("/DsBrandingFolder=" + get_abspath(git_dir, branding_dir))
if sign:
iscc_args.append("/DENABLE_SIGNING=1")
iscc_args.append("/Sbyparam=signtool.exe sign /v /n $q" + cert_name + "$q /t " + tsa_server + " $f")
log("--- " + innosetup_help_file)
if is_file(innosetup_help_file):
log("! file exist, skip")
return
cmd("iscc", iscc_args + ["help.iss"])
return
def make_innosetup_update():
log("\n=== Build innosetup update project\n")
log("--- " + innosetup_update_file)
@ -139,6 +168,7 @@ def make_winsparkle_files():
awk_args = [
"-v", "Version=" + version,
"-v", "Build=" + build,
"-v", "Branch=" + get_env("RELEASE_BRANCH"),
"-v", "Timestamp=" + timestamp,
"-i", get_path(build_branding_dir, awk_branding)
]
@ -190,22 +220,50 @@ def make_advinst():
if is_file(advinst_file):
log("! file exist, skip")
return
aic_content = [";aic"]
if not onlyoffice:
branding_path = get_abspath(git_dir, branding_dir)
copy_dir_content(
get_abspath(git_dir, branding_dir, "win-linux/package/windows/data"),
"data", ".bmp")
branding_path + "\\win-linux\\package\\windows\\data", "data", ".bmp")
copy_dir_content(
get_abspath(git_dir, branding_dir, "win-linux/package/windows/data"),
"data", ".png")
branding_path + "\\win-linux\\package\\windows\\data", "data", ".png")
copy_dir_content(
branding_path + "\\win-linux\\extras\\projicons\\res",
"..\\..\\extras\\projicons\\res", ".ico")
copy_file(
branding_path + "\\win-linux\\package\\windows\\dictionary.ail",
"dictionary.ail")
copy_file(
branding_path + "\\common\\package\\license\\eula_" + branding + ".rtf",
"..\\..\\..\\common\\package\\license\\agpl-3.0.rtf")
copy_file(
branding_path + "\\..\\multimedia\\videoplayer\\icons\\" + branding + ".ico",
"..\\..\\extras\\projicons\\res\\media.ico")
copy_file(
branding_path + "\\..\\multimedia\\imageviewer\\icons\\ico\\" + branding + ".ico",
"..\\..\\extras\\projicons\\res\\gallery.ico")
aic_content = [";aic"]
if not sign:
aic_content += [
"ResetSig"
]
if machine == '32':
aic_content += [
"SetPackageType x86",
"SetAppdir -buildname DefaultBuild -path [ProgramFilesFolder][MANUFACTURER_INSTALL_FOLDER]\\[PRODUCT_INSTALL_FOLDER]",
'DelPrerequisite "Microsoft Visual C++ 2015-2022 Redistributable (x64)"',
'DelPrerequisite "Microsoft Visual C++ 2013 Redistributable (x64)"'
]
if machine == '64':
aic_content += [
'DelPrerequisite "Microsoft Visual C++ 2015-2022 Redistributable (x86)"',
'DelPrerequisite "Microsoft Visual C++ 2013 Redistributable (x86)"'
]
if onlyoffice:
aic_content += [
"DelFolder CUSTOM_PATH"
]
else:
aic_content += [
"SetProperty ProductName=\"%s\"" % product_name_full,
"SetProperty Manufacturer=\"%s\"" % publisher_name.replace('"', '""'),
"SetProperty ARPURLINFOABOUT=\"%s\"" % info_about_url,
"SetProperty ARPURLUPDATEINFO=\"%s\"" % update_info_url,
"SetProperty ARPHELPLINK=\"%s\"" % help_url,
"SetProperty ARPHELPTELEPHONE=\"%s\"" % help_phone,
"SetProperty ARPCONTACT=\"%s\"" % publisher_address,
"DelLanguage 1029 -buildname DefaultBuild",
"DelLanguage 1031 -buildname DefaultBuild",
"DelLanguage 1041 -buildname DefaultBuild",
@ -214,21 +272,23 @@ def make_advinst():
"DelLanguage 1060 -buildname DefaultBuild",
"DelLanguage 1036 -buildname DefaultBuild",
"DelLanguage 3082 -buildname DefaultBuild",
"DelLanguage 1033 -buildname DefaultBuild"
"DelLanguage 1033 -buildname DefaultBuild",
"NewSync CUSTOM_PATH " + source_dir + "\\..\\MediaViewer",
"UpdateFile CUSTOM_PATH\\ImageViewer.exe " + source_dir + "\\..\\MediaViewer\\ImageViewer.exe",
"UpdateFile CUSTOM_PATH\\VideoPlayer.exe " + source_dir + "\\..\\MediaViewer\\VideoPlayer.exe",
"SetProperty ASCC_REG_PREFIX=" + ascc_reg_prefix
]
if not sign: aic_content.append("ResetSig")
if machine == '32': aic_content.append("SetPackageType x86")
aic_content += [
"AddOsLc -buildname DefaultBuild -arch " + arch,
"NewSync APPDIR " + source_dir + " -existingfiles delete",
"UpdateFile APPDIR\\DesktopEditors.exe " + get_path(source_dir, "DesktopEditors.exe"),
"NewSync APPDIR " + source_dir,
"UpdateFile APPDIR\\DesktopEditors.exe " + source_dir + "\\DesktopEditors.exe",
"SetVersion " + package_version,
"SetPackageName " + advinst_file + " -buildname DefaultBuild",
"Rebuild -buildslist DefaultBuild"
]
write_file("DesktopEditors.aic", "\r\n".join(aic_content), 'utf-8-sig')
cmd("AdvancedInstaller.com",
["/execute", "DesktopEditors.aip", "DesktopEditors.aic", "-nofail"])
["/execute", "DesktopEditors.aip", "DesktopEditors.aic"])
return
def make_win_portable():
@ -249,6 +309,11 @@ def make_macos():
set_cwd(git_dir + "/" + branding_build_dir)
if 'clean' in targets:
log("\n=== Clean\n")
delete_dir(get_env("HOME") + "/Library/Developer/Xcode/Archives")
delete_dir(get_env("HOME") + "/Library/Caches/Sparkle_generate_appcast")
for target in targets:
if not target.startswith('diskimage'):
continue
@ -284,26 +349,43 @@ def make_sparkle_updates():
updates_storage_dir = "%s/%s/_updates" % (get_env('ARCHIVES_DIR'), scheme)
create_dir(updates_dir)
copy_dir_content(updates_storage_dir, updates_dir, ".zip")
copy_dir_content(updates_storage_dir, updates_dir, ".html")
# copy_dir_content(updates_storage_dir, updates_dir, ".html")
copy_file(macos_zip, updates_dir)
for lang, base in update_changes_list.items():
notes_src = "%s/%s/%s.html" % (changes_dir, app_version, base)
if "en" in update_changes_list:
notes_src = "%s/%s/%s.html" % (changes_dir, app_version, update_changes_list["en"])
notes_dst = "%s/%s.html" % (updates_dir, zip_filename)
if lang == 'en':
encoding = 'en_US.UTF-8'
cur_date = proc_open("env LC_ALL=" + encoding + " date -u \"+%B %e, %Y\"")['stdout']
elif lang == 'ru':
encoding = 'ru_RU.UTF-8'
cur_date = proc_open("env LC_ALL=" + encoding + " date -u \"+%e %B %Y\"")['stdout']
if is_file(notes_src):
copy_file(notes_src, notes_dst)
cur_date = sh_output("env LC_ALL=en_US.UTF-8 date -u \"+%B %e, %Y\"", verbose=True)
replace_in_file(notes_dst,
r"(<span class=\"releasedate\">).+(</span>)",
"\\1 - " + cur_date + "\\2")
# else:
# write_file(notes_dst, "placeholder\n")
cmd(git_dir + "/" + build_dir + "/Vendor/Sparkle/bin/generate_appcast", [updates_dir])
else:
write_file(notes_dst, '<html></html>\n')
if "ru" in update_changes_list:
notes_src = "%s/%s/%s.html" % (changes_dir, app_version, update_changes_list["ru"])
if update_changes_list["ru"] != "ReleaseNotes":
notes_dst = "%s/%s.ru.html" % (updates_dir, zip_filename)
else:
notes_dst = "%s/%s.html" % (updates_dir, zip_filename)
if is_file(notes_src):
copy_file(notes_src, notes_dst)
cur_date = sh_output("env LC_ALL=ru_RU.UTF-8 date -u \"+%e %B %Y\"", verbose=True)
replace_in_file(notes_dst,
r"(<span class=\"releasedate\">).+(</span>)",
"\\1 - " + cur_date + "\\2")
else:
write_file(notes_dst, '<html></html>\n')
sparkle_download_url = "%s/%s/updates/" % (sparkle_base_url, suffix)
sparkle_release_notes_url = "%s/%s/updates/changes/%s/" % (sparkle_base_url, suffix, app_version)
cmd(git_dir + "/" + build_dir + "/Vendor/Sparkle/bin/generate_appcast", [
updates_dir,
"--download-url-prefix", sparkle_download_url,
"--release-notes-url-prefix", sparkle_release_notes_url
])
log("\n=== Edit Sparkle appcast links\n")
appcast_url = sparkle_base_url + "/" + suffix
@ -312,17 +394,12 @@ def make_sparkle_updates():
for lang, base in update_changes_list.items():
if base == "ReleaseNotes":
replace_in_file(appcast,
r"(<sparkle:releaseNotesLink>)(?:.+" + package_name + \
"-(?:x86|x86_64|v8|arm)-([0-9.]+)\..+)(</sparkle:releaseNotesLink>)",
"\\1" + appcast_url + "/updates/changes/\\2/" + base + ".html\\3")
r'(<sparkle:releaseNotesLink>.+/).+(\.html</sparkle:releaseNotesLink>)',
"\\1" + base + "\\2")
else:
replace_in_file(appcast,
r"(<sparkle:releaseNotesLink xml:lang=\"" + lang + "\">)(?:" + package_name + \
"-(?:x86|x86_64|v8|arm)-([0-9.]+)\..+)(</sparkle:releaseNotesLink>)",
"\\1" + appcast_url + "/updates/changes/\\2/" + base + ".html\\3")
replace_in_file(appcast,
r"(url=\")(?:.+/)(" + package_name + ".+\")",
"\\1" + appcast_url + "/updates/\\2")
r'(<sparkle:releaseNotesLink xml:lang="' + lang + r'">).+(\.html</sparkle:releaseNotesLink>)',
"\\1" + sparkle_release_notes_url + base + "\\2")
log("\n=== Delete unnecessary files\n")
for file in os.listdir(updates_dir):

View File

@ -46,7 +46,7 @@ def log(string, end='\n', bold=False):
out = '\033[1m' + string + '\033[0m' + end
else:
out = string + end
sys.stdout.write(out.encode("utf-8"))
sys.stdout.write(out)
sys.stdout.flush()
return
@ -249,6 +249,14 @@ def powershell(cmd):
sys.exit("! error: " + str(ret))
return ret
def sh_output(command, **kwargs):
if kwargs.get("verbose"):
log("- sh output: " + command)
ret = subprocess.check_output(
command, stderr=subprocess.STDOUT, shell=True
)
return ret.decode("utf-8").strip()
def get_platform(target):
xp = (-1 != target.find('-xp'))
if (-1 != target.find('-x64')):

View File

@ -5,6 +5,7 @@ sys.path.append('../../scripts')
import base
import os
import glob
from xml.sax.saxutils import escape
AVS_OFFICESTUDIO_FILE_DOCUMENT = 0x0040
AVS_OFFICESTUDIO_FILE_DOCUMENT_DOCX = AVS_OFFICESTUDIO_FILE_DOCUMENT + 0x0001
@ -135,8 +136,8 @@ def convertFile(directory_x2t, file_input, file_output, convert_params):
xml_convert = u"<?xml version=\"1.0\" encoding=\"UTF-8\"?>"
xml_convert += u"<TaskQueueDataConvert>"
xml_convert += (u"<m_sFileFrom>" + file_input + u"</m_sFileFrom>")
xml_convert += (u"<m_sFileTo>" + file_output + u"</m_sFileTo>")
xml_convert += (u"<m_sFileFrom>" + escape(file_input) + u"</m_sFileFrom>")
xml_convert += (u"<m_sFileTo>" + escape(file_output) + u"</m_sFileTo>")
xml_convert += u"<m_nFormatTo>" + str(getFormatByFile(file_output)) + u"</m_nFormatTo>"
xml_convert += (u"<m_sAllFontsPath>" + directory_fonts + u"/AllFonts.js</m_sAllFontsPath>")
xml_convert += (u"<m_sFontDir>" + directory_fonts + "</m_sFontDir>")

View File

@ -0,0 +1,9 @@
#!/bin/bash
SCRIPTPATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
DIR_X2T=$SCRIPTPATH/..
$("$DIR_X2T/x2t" &>/dev/null)
status=$?
[ $status -ne 88 ] && $(cp "$SCRIPTPATH/libstdc++.so.6" "$DIR_X2T/libstdc++.so.6")

Binary file not shown.

View File

@ -1 +1 @@
7.1.0
7.2.1