Mk/bsd.openssl.mk optimization

V.Chukharev chukharev at mail.ru
Fri Jul 25 13:07:36 UTC 2008


On Fri, 25 Jul 2008 07:30:18 +0300, Dirk Meyer <dirk.meyer at dinoex.sub.org> wrote:

> V.Chukharev schrieb:,
>
>> I should confess I do not understand how my patch works. I expected to see a
>> file /usr/ports/.openssl_installed or /tmp/index_something/.openssl_installed
>> or similar, but could not see it... But I hope this patch will inspire you
>> to do something really working.
>
> This patch breaks the desired funtion.

Yes, it does break things. It was intended only to demonstrate how big 
can be the speedup. I have mentioned I know very little about make.

> To speedup index build you can add in in your /etc/make.conf
> WITH_OPENSSL_BASE=yes
> or
> WITH_OPENSSL_PORT=yes

That's great! And is it possible to set some default value on installation,
and make each corresponding port change it accordingly? I mean, is there a 
procedure to ensure ports do such changes?

> The linker will pull in the latests version of libssl.so,
> So this check is necessary to detect an installed port version,
> and record the correct dependency.

Yes. Only, the detection can be done once per an index build.

> The result can be cached only if no other ports or package is installed.

You mean, my patch did not delete the cache at the end of the index build?
That's true. The patch was not a real one...

> So you are right that make index could be otimized,
> but it will take much more work.

Totally agree on this. I tryed to make caching in bsd.subdir.mk as Kris
proposed, and I got also considerable speedup, but not as good as
with the first patch. The grep on all packages is done once per port
category. I miss how to pass the results to a child make...

Anyway, I attach the new (better, but still not fully working) patch JFYI.

> kind regards Dirk
>
> - Dirk Meyer, Im Grund 4, 34317 Habichtswald, Germany
> - [dirk.meyer at dinoex.sub.org],[dirk.meyer at guug.de],[dinoex at FreeBSD.org]
> http://people.freebsd.org/~dinoex/errorlogs/
> 


Best regards,
-- 
V. Chukharev
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Mk_bsd.openssl.mk_1.patch
Type: application/octet-stream
Size: 1619 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-ports/attachments/20080725/207a2aa8/Mk_bsd.openssl.mk_1.obj


More information about the freebsd-ports mailing list