1
0
mirror of https://github.com/facebook/proxygen.git synced 2025-08-05 19:55:47 +03:00

jom (parallel nmake) build for openssl windows

Summary:
X-link: https://github.com/facebookincubator/zstrong/pull/1084

openssl build on windows is slow due to nmake being single threaded

fortunately the Qt developers had the same problem and produced jom - a nmake compatible make that adds the /j<parallelism> flag

add a jom manifest and use it for the openssl build on windows

Reviewed By: bigfootjon

Differential Revision: D66818562

fbshipit-source-id: 88938dbc862da18ae7f75df51aa99bb669aae71a
This commit is contained in:
Alex Hornby
2024-12-05 14:41:06 -08:00
committed by Facebook GitHub Bot
parent cd821146ab
commit 8f72b80c14
3 changed files with 27 additions and 3 deletions

View File

@@ -1165,9 +1165,14 @@ class OpenSSLBuilder(BuilderBase):
perl = typing.cast(str, path_search(env, "perl", "perl"))
make_j_args = []
extra_args = []
if self.build_opts.is_windows():
make = "nmake.exe"
# jom is compatible with nmake, adds the /j argument for parallel build
make = "jom.exe"
make_j_args = ["/j%s" % self.num_jobs]
args = ["VC-WIN64A-masm", "-utf-8"]
# fixes "if multiple CL.EXE write to the same .PDB file, please use /FS"
extra_args = ["/FS"]
elif self.build_opts.is_darwin():
make = "make"
make_j_args = ["-j%s" % self.num_jobs]
@@ -1200,11 +1205,14 @@ class OpenSSLBuilder(BuilderBase):
"no-unit-test",
"no-tests",
]
+ extra_args
)
# show the config produced
self._run_cmd([perl, "configdata.pm", "--dump"], env=env)
make_build = [make] + make_j_args
self._run_cmd(make_build)
self._run_cmd(make_build, env=env)
make_install = [make, "install_sw", "install_ssldirs"]
self._run_cmd(make_install)
self._run_cmd(make_install, env=env)
class Boost(BuilderBase):