On Thu, Jun 10, 2021 at 07:52:23AM +0200, Willy Tarreau wrote: > Subject: Re: Speeding up opentracing build in CI ? > > On Thu, Jun 10, 2021 at 07:19:37AM +0200, Willy Tarreau wrote: > > On Thu, Jun 10, 2021 at 10:15:46AM +0500, ???? ??????? wrote: > > > OT takes about 30 sec (it is built with almost everything disabled). the > > > biggest time eater is openssl-3.0.0 > > > > Maybe that one could be sped up too, I haven't checked if it uses parallel > > builds. > > So I checked. Good news, it wasn't parallel either, and this alone: > > --- a/scripts/build-ssl.sh > +++ b/scripts/build-ssl.sh > @@ -21,7 +21,8 @@ build_openssl_linux () { > ( > cd "openssl-${OPENSSL_VERSION}/" > ./config shared --prefix="${HOME}/opt" --openssldir="${HOME}/opt" > -DPURIFY > - make all install_sw > + make -j$(nproc) all > + make install_sw > ) > } > > Is enough to drop from 4:52 to 1:28 on my machine. About 1/4 of this time > is used to build man and HTML pages that we don't use. Instead of the "all" > target, we should use "build_sw" > > --- a/scripts/build-ssl.sh > +++ b/scripts/build-ssl.sh > @@ -21,7 +21,8 @@ build_openssl_linux () { > ( > cd "openssl-${OPENSSL_VERSION}/" > ./config shared --prefix="${HOME}/opt" --openssldir="${HOME}/opt" > -DPURIFY > - make all install_sw > + make -j$(nproc) build_sw > + make install_sw > ) > } > > this further downs the time to 1:9, hence more than 4 times faster than > the initial one. It should probably be tested on macos to be certain it's > OK there as well, and I don't know how to get the CPU count there (or > maybe we could just force it to a low value like 2 or 4). > > Willy >
Looks fine to me, but from what I remember when debugging some reg-tests there was only one CPU available, I hope I'm wrong. -- William Lallemand