Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 25 Jul 2008 16:09:10 +0300
From:      "V.Chukharev" <chukharev@mail.ru>
To:        "Dirk Meyer" <dirk.meyer@dinoex.sub.org>, freebsd-ports@freebsd.org
Subject:   Re: Mk/bsd.openssl.mk optimization
Message-ID:  <op.ueumske80g54sc@localhost>
In-Reply-To: <08GlBzRclM@dmeyer.dinoex.sub.org>
References:  <op.ueqfl1xy0g54sc@localhost> <08GlBzRclM@dmeyer.dinoex.sub.org>

next in thread | previous in thread | raw e-mail | index | archive | help
------------0VGlgWoVpBpJwBN94AoEPg
Content-Type: text/plain; charset=koi8-r
Content-Transfer-Encoding: 7bit

On Fri, 25 Jul 2008 07:30:18 +0300, Dirk Meyer <dirk.meyer@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@dinoex.sub.org],[dirk.meyer@guug.de],[dinoex@FreeBSD.org]
> http://people.freebsd.org/~dinoex/errorlogs/
> 


Best regards,
-- 
V. Chukharev
------------0VGlgWoVpBpJwBN94AoEPg
Content-Disposition: attachment; filename=Mk_bsd.openssl.mk_1.patch
Content-Type: application/octet-stream; name=Mk_bsd.openssl.mk_1.patch
Content-Transfer-Encoding: Base64

LS0tIC91c3IvcG9ydHMvTWsvYnNkLm9wZW5zc2wubWsub3JpZwkyMDA4LTA3LTIz
IDA5OjE0OjI5LjAwMDAwMDAwMCArMDMwMAorKysgL3Vzci9wb3J0cy9Nay9ic2Qu
b3BlbnNzbC5tawkyMDA4LTA3LTI1IDEyOjAyOjAxLjAwMDAwMDAwMCArMDMwMApA
QCAtMzMsNiArMzMsOSBAQAogIyBCVUlMRF9ERVBFTkRTCQktIGFyZSBhZGRlZCBp
ZiBuZWVkZWQKICMgUlVOX0RFUEVORFMJCS0gYXJlIGFkZGVkIGlmIG5lZWRlZAog
CisuaWYgIWRlZmluZWQoQlNEX09QRU5TU0xfTUspCitCU0RfT1BFTlNTTF9NSz15
ZXMKKwogT3BlblNTTF9JbmNsdWRlX01BSU5UQUlORVI9CWRpbm9leEBGcmVlQlNE
Lm9yZwogCiAjIGhvbm9yIG9ic29sZXRlIG9wdGlvbnMgZm9yIGEgYml0CkBAIC0x
MjEsMTMgKzEyNCwxOSBAQAogCWV4aXN0cygke0RFU1RESVJ9LyR7TE9DQUxCQVNF
fS9saWIvbGliY3J5cHRvLnNvKQogIyBmaW5kIGluc3RhbGxlZCBwb3J0IGFuZCB1
c2UgaXQgZm9yIGRlcGVuZGVuY3kKIFBLR19EQkRJUj89CQkke0RFU1RESVJ9L3Zh
ci9kYi9wa2cKKy5pZiAhZGVmaW5lZChPUEVOU1NMX0lOU1RBTExFRCkKIE9QRU5T
U0xfSU5TVEFMTEVEIT0JZ3JlcCAtbCAtciAiXmxpYi9saWJzc2wuc28uIiAiJHtQ
S0dfREJESVJ9IiB8IFwKIA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S9wa2ctZGVzY3IK
IAogLmluY2x1ZGUgIiR7UE9SVFNESVJ9L01rL2JzZC5jb21tYW5kcy5tayIKKyNj
YWNoZSB2YXJpYWJsZXMgZnJvbSBic2Qub3BlbnNzbC5taworLmlmICFkZWZpbmVk
KEJTRF9PUEVOU1NMX01LKQorLmluY2x1ZGUgIiR7UE9SVFNESVJ9L01rL2JzZC5v
cGVuc3NsLm1rIgorLmVuZGlmCiAKIC5NQUlOOiBhbGwKIAo=

------------0VGlgWoVpBpJwBN94AoEPg--




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?op.ueumske80g54sc>