From owner-freebsd-ports@freebsd.org Sat Feb 22 19:18:54 2020 Return-Path: Delivered-To: freebsd-ports@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 2D7D2249B77 for ; Sat, 22 Feb 2020 19:18:54 +0000 (UTC) (envelope-from marklmi@yahoo.com) Received: from sonic312-24.consmr.mail.gq1.yahoo.com (sonic312-24.consmr.mail.gq1.yahoo.com [98.137.69.205]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 48PymX5Hlkz439T for ; Sat, 22 Feb 2020 19:18:52 +0000 (UTC) (envelope-from marklmi@yahoo.com) X-YMail-OSG: 1BsXAXgVM1nIiFrkI8ArpeD6caFY3nL4dYOa2W.bgmZ.5ZkRnsYh0wExYzngucc xXAp8XL44FIkUW7Mi52KeOUCrGObyytNUEwdzkK0Nu1kywizTwOpP6nCssL5GlRu9lJ.1fyJY2dl wZKL_PGKak6kcdyWyDG8v5o2GLEg9EsWXTMg9_d6CDFs71tr7EhoD4sQ9wxM4GMXW1UVU74zQmmL oLqghcW0Y2WZk4WqViZ16Ucp5btEmSmgZ8TOGTG4rqumZH_3zWt8P1N9ubh2XFrDyootMUXik5te cBJb4iyXK6RoSWf1jaN11O6kaIOVhlz2NP37D4deAhJKGgCrczFVx4X4rUr.qgJgB5HYEogabkw0 CF8ivmkcYpDpSKp4skoBYPU06opbOqza17F0l5Xq1qMY1_GzpJJATF9CARK96hHTk3HQ3XoXyuiv U1AtinEYic8_bSC4nkTtWvCmABhfWAOoKdyff02xQLly297C0oIuf2.pZUDHWhQUBvfx678e7CMb NnwbQQsOg.PZ_GhzwWyjRACw33Oy3Md0eCKL_nDN6xNxgW6oT22jabSKPK.jmQvI_pxskR6mozrT NAbdnIbB4_rUSdLNbR0Pbcn6Vbs_gOLNSrsCW4IOb5CEwdz1RO.tzOyQ8KEXAOyyeZtk22_b98nK MweJkvpUM3_Sn4ROifti7grtPOulaqL.dD2pZWr4LHH877pHDFw_hpUuYj1u4nw56qJ8xqSceSoH bvOqB2i9avb1ju2neCqXUk9ym7_x_9KZVnvp_w4r3B7lyaxiDxv0n80hgxBCsNhSzm0JY9M_ztEv WBfpEqjPZOYzapC1si92VGrtY91wC6K.kcaVHocB4FUqvpCuoakwPNx1gBVoN0V6ayKKz1Xl_Kmn LDrCIyNRQbF8gK9JC6cQZNO3ty0ZrUnGCUSLTydA69aMd0O_i6SQpNIll3raKXWMsuvTJ1NBG.HP 0Krfagx94b5fIWwhfvR40JML1YM6CHXf9K6Uhb8pRGdBnsiyZXOCxiJFZ1uVYnFOTJ610P_0ziLx l1UifrrBX.sZKxTnKpDnJf1QCzqxTX.5u2KyRoXPNsKwvnUUWe6HPxBeWYJbjwQStH5X0CRDDoV1 PGjHTNp3FB6qE1TIsF02_A2nkfeTmS.WtSQ4KBfwhp_9QNp.8UkCW2pFG4s1_NHb3Mv3vc7vA_Db rUz12rPWQPaO7h2z7kEK.ZJpENcndj_naWby2aiRnQtUMT9WNQWpFqrq4mOrvR_zQm1k8TH8Hxip tYNko.KJljwsSo6rgkYA59u1_Ez0b31Rb6GBKbWC.RcfTnGojPFLOkcQeaipSyyjSnxNW.qUrxvu 7np0YX6I7TuGbRzClraImi2KVe7AwTs.tUw4apuaYzlcRxaXxAEDM2D8ZAey7a1c5N8y6prV.jh6 3kPtljSVwsZZV0X5zh5ty40OY5NVVdGSuNzHznPohA3RxQGR7myfcu9U- Received: from sonic.gate.mail.ne1.yahoo.com by sonic312.consmr.mail.gq1.yahoo.com with HTTP; Sat, 22 Feb 2020 19:18:51 +0000 Received: by smtp417.mail.ne1.yahoo.com (Oath Hermes SMTP Server) with ESMTPA ID dd9d58ca547031b8afe61624e34bbdbe; Sat, 22 Feb 2020 19:18:49 +0000 (UTC) Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 13.0 \(3608.60.0.2.5\)) Subject: Re: svn commit: r358166 - head From: Mark Millard In-Reply-To: Date: Sat, 22 Feb 2020 11:18:47 -0800 Cc: FreeBSD ports , Kevin Oberman , yasu@utahime.org Content-Transfer-Encoding: quoted-printable Message-Id: <43FA0F10-9F02-4D99-B0FB-3F329477205D@yahoo.com> References: <27EABC0F-6D78-47E1-810B-FAB282D430A3.ref@yahoo.com> <27EABC0F-6D78-47E1-810B-FAB282D430A3@yahoo.com> To: =?utf-8?Q?Stefan_E=C3=9Fer?= X-Mailer: Apple Mail (2.3608.60.0.2.5) X-Rspamd-Queue-Id: 48PymX5Hlkz439T X-Spamd-Bar: -- X-Spamd-Result: default: False [-2.27 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.81)[-0.808,0]; R_DKIM_ALLOW(-0.20)[yahoo.com:s=s2048]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[4]; R_SPF_ALLOW(-0.20)[+ptr:yahoo.com]; FREEMAIL_FROM(0.00)[yahoo.com]; MIME_GOOD(-0.10)[text/plain]; MV_CASE(0.50)[]; NEURAL_HAM_LONG(-0.96)[-0.961,0]; TO_DN_SOME(0.00)[]; IP_SCORE_FREEMAIL(0.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; DKIM_TRACE(0.00)[yahoo.com:+]; DMARC_POLICY_ALLOW(-0.50)[yahoo.com,reject]; RCVD_IN_DNSWL_NONE(0.00)[205.69.137.98.list.dnswl.org : 127.0.5.0]; RCVD_TLS_LAST(0.00)[]; RCVD_COUNT_TWO(0.00)[2]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[yahoo.com]; ASN(0.00)[asn:36647, ipnet:98.137.64.0/21, country:US]; MID_RHS_MATCH_FROM(0.00)[]; IP_SCORE(0.00)[ip: (2.29), ipnet: 98.137.64.0/21(0.83), asn: 36647(0.66), country: US(-0.05)]; DWL_DNSWL_NONE(0.00)[yahoo.com.dwl.dnswl.org : 127.0.5.0] X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Feb 2020 19:18:54 -0000 On 2020-Feb-22, at 09:29, Stefan E=C3=9Fer wrote: > Am 22.02.20 um 03:50 schrieb Mark Millard via freebsd-ports: >>=20 >>=20 >> . . . >>=20 >> In the style of my prior examples (including the change that >> found libedit and such), analogous would be: >>=20 >> # find /usr/local/*bin* /usr/local/lib* -type f \ >> | xargs -n1 file -F ' ' | grep 'ELF' | cut -f1 -d' ' \ >> | xargs ldd -f '%A %p\n' 2>&1 | grep ncurses\.so\.8 | cut -f1 -d' ' \ >> | xargs pkg which | cut -f6 -d' ' | sort -u | more >> bison-3.5.2,1 >> gdbm-1.18.1_1 >> gettext-tools-0.20.1_1 >> gnuplot-5.2.8 >> libedit-3.1.20191211,1 >> libtextstyle-0.20.1 >> llvm10-10.0.0.r2 >> llvm80-8.0.1_3 >> lua52-5.2.4 >> mesa-dri-18.3.2_9 >> ruby-2.6.5,1 >> sqlite3-3.30.1,1 >> xterm-353_1 >>=20 >> Looks like I'll be reasonably ready when I get to the point >> of wanting to deal with this. >=20 > While technically correct, the extra test for the ELF format of each > single file is not required for correct results, AFAICT. >=20 > The ldd command will just emit an error message for files it cannot > process, and the error output is trivially suppressed. >=20 >=20 > The following pipeline should only need a fraction of the time = required > by the one suggested above: >=20 > # find /usr/local/*bin* /usr/local/lib* -type f \ > | xargs ldd -f '%o %A\n' 2>/dev/null \ > | grep ^libncurses\.so\.8 | cut -w -f2 \ > | xargs pkg which -q | sort -u | more >=20 > It completes in 13 seconds on my system, and I plan to add it to > portmaster as another option to select the ports to be updated. >=20 > The test of each file for ELF format requires one invocation of the > file command for each, which leads to 217 seconds real time (178 user, > 39 system) for me - so my version is faster by a factor of at least = 15. >=20 Nice. I executed my example in a chroot that does not by default have /dev/null present. That is why I avoided that specific alternative. There is also /lib/libncursesw.so.8 that I'd forgotten. So, for my context, . . . # find /usr/local/*bin* /usr/local/lib* -type f \ | xargs ldd -f '%p %A\n' 2>&1 | grep "^/lib/libncurses[^ ]*\.so\.8" | = cut -w -f2 \ | xargs pkg which -q | sort -u | more bison-3.5.2,1 dialog4ports-0.1.6 gdb-8.3.1 gdbm-1.18.1_1 gettext-tools-0.20.1_1 gnuplot-5.2.8 libedit-3.1.20191211,1 libtextstyle-0.20.1 llvm10-10.0.0.r2 llvm80-8.0.1_3 lua52-5.2.4 mesa-dri-18.3.2_9 python37-3.7.6 readline-8.0.1 ruby-2.6.5,1 spidermonkey60-60.9.0_1 sqlite3-3.30.1,1 texinfo-6.7_1,1 xterm-353_1 That picked up dialog4ports and other items. =3D=3D=3D Mark Millard marklmi at yahoo.com ( dsl-only.net went away in early 2018-Mar)