From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from [87.239.111.99] (localhost [127.0.0.1]) by dev.tarantool.org (Postfix) with ESMTP id B20566EC5D; Fri, 9 Apr 2021 22:54:39 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org B20566EC5D DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1617998079; bh=X5UxiQhgNJlqmdK1FXboURFrmf2PG9wafs4jHtNwx58=; h=In-Reply-To:Date:Cc:References:To:Subject:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From:Reply-To:From; b=NZ5YA8lDQiTAELBp63ZCvU6eCZu+NPLGoUvItWdK4awEMMd8jEech8u70j+EyCLl+ sM3ya9ewomjnwnM9uduHqK9NfdbFXzcsQT3TxahQcbOzab0gpaoa8O5mVU+8FBqrbd Gd3+qIUIu4BZ5FghGXzkfH5l+62RASVLUwed3Z48= Received: from smtp44.i.mail.ru (smtp44.i.mail.ru [94.100.177.104]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id 5E8486EC5D for ; Fri, 9 Apr 2021 22:54:38 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 5E8486EC5D Received: by smtp44.i.mail.ru with esmtpa (envelope-from ) id 1lUxDB-0006AJ-I8; Fri, 09 Apr 2021 22:54:38 +0300 Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 13.4 \(3608.120.23.2.1\)) In-Reply-To: <20210401005240.dhw6sb3hyccsoo5t@tkn_work_nb> Date: Fri, 9 Apr 2021 22:54:36 +0300 Cc: tarantool-patches@dev.tarantool.org Content-Transfer-Encoding: quoted-printable Message-Id: <48779CE3-AA74-43DF-AA54-A418F8C5FDC3@tarantool.org> References: <20210319141308.98726-1-roman.habibov@tarantool.org> <20210319141308.98726-3-roman.habibov@tarantool.org> <20210401005240.dhw6sb3hyccsoo5t@tkn_work_nb> To: Alexander Turenko , Leonid Vasiliev X-Mailer: Apple Mail (2.3608.120.23.2.1) X-7564579A: B8F34718100C35BD X-77F55803: 4F1203BC0FB41BD92FFCB8E6708E74807BAE725B9AE625DE765B0E193B5B7687182A05F538085040D7CDC74EA1FF204D4E5C068A4C691ABD957229D26FEF665C1A9384E194F34069 X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE7D6964C9E324ABA58EA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F7900637AAEFEF2B38A4D0058638F802B75D45FF914D58D5BE9E6BC1A93B80C6DEB9DEE97C6FB206A91F05B2E7639821A58E7F85241EED47DD8763B9BDFBBEFFF4125B51D2E47CDBA5A96583C09775C1D3CA48CF17B107DEF921CE79117882F4460429724CE54428C33FAD30A8DF7F3B2552694AC26CFBAC0749D213D2E47CDBA5A9658378DA827A17800CE767883B903EA3BAEA9FA2833FD35BB23DF004C90652538430302FCEF25BFAB3454AD6D5ED66289B5278DA827A17800CE79C0E3D88F9512EADD32BA5DBAC0009BE395957E7521B51C20BC6067A898B09E4090A508E0FED6299176DF2183F8FC7C0D94E105876FE7799B3661434B16C20AC78D18283394535A9E827F84554CEF50127C277FBC8AE2E8BA83251EDC214901ED5E8D9A59859A8B6B1CFA6D474D4A6A4089D37D7C0E48F6C5571747095F342E88FB05168BE4CE3AF X-B7AD71C0: AC4F5C86D027EB782CDD5689AFBDA7A2368A440D3B0F6089093C9A16E5BC824A2A04A2ABAA09D25379311020FFC8D4ADED27546C620ED1492C38720E912A3347 X-C1DE0DAB: 0D63561A33F958A5AE360BABB2B07F4B335B3E6AA92A6673B607987F9412CAC3D59269BC5F550898D99A6476B3ADF6B47008B74DF8BB9EF7333BD3B22AA88B938A852937E12ACA7502E6951B79FF9A3F410CA545F18667F91A7EA1CDA0B5A7A0 X-C8649E89: 4E36BF7865823D7055A7F0CF078B5EC49A30900B95165D3480A9008907CB2FD0D07296509FA2AE446C315F00238BD878EE9367346E1B58B013AD5BC8FA05A2551D7E09C32AA3244CFF2ED2474AB95DAE58C2808D45CDA4D53C6EB905E3A8056BFACE5A9C96DEB163 X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2biojyO2lHpuZu4QiFvutE3rckQ== X-Mailru-Sender: ED747E36EB90C325A4602F7CA2CC58C1A0B63CC74B4BCE6AD9F720A2683EF8AE3FB1763410276AF21EC3B765AEBF8DFDC77752E0C033A69EF2501F26BCC01020D1D7FFF4A7B59B3C6C18EFA0BB12DBB0 X-Mras: Ok Subject: Re: [Tarantool-patches] [PATCH 2/3] build: enable smtp in libCURL X-BeenThere: tarantool-patches@dev.tarantool.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Roman Khabibov via Tarantool-patches Reply-To: Roman Khabibov Errors-To: tarantool-patches-bounces@dev.tarantool.org Sender: "Tarantool-patches" > On Apr 1, 2021, at 03:52, Alexander Turenko = wrote: >=20 > On Fri, Mar 19, 2021 at 05:13:07PM +0300, Roman Khabibov wrote: >> Enable smtp protocol in bundled libCURL. >> --- >> cmake/BuildLibCURL.cmake | 2 +- >> test/box-tap/curl-build.test.lua | 38 = +++++++++++++++++++++++++++++++- >> 2 files changed, 38 insertions(+), 2 deletions(-) >>=20 >> diff --git a/cmake/BuildLibCURL.cmake b/cmake/BuildLibCURL.cmake >> index 5f8b15a63..313adfb97 100644 >> --- a/cmake/BuildLibCURL.cmake >> +++ b/cmake/BuildLibCURL.cmake >> @@ -124,6 +124,7 @@ macro(curl_build) >> --enable-http-auth >> --enable-mime >> --enable-dateparse >> + --enable-smtp >>=20 >> ${DISABLED_DNS_OPT} >> --disable-ftp >> @@ -137,7 +138,6 @@ macro(curl_build) >> --disable-pop3 >> --disable-imap >> --disable-smb >> - --disable-smtp >> --disable-gopher >> --disable-manual >> --disable-sspi >=20 > It seems, it is quite straightforward backport of [1], so it is okay > after comments from the original patch ([2]). >=20 > Don't miss changelog entries on 1.10. >=20 > [1]: = https://lists.tarantool.org/pipermail/tarantool-patches/2021-March/022797.= html > [2]: = https://lists.tarantool.org/pipermail/tarantool-patches/2021-March/023177.= html >=20 > I performed tests 2 and 3 from [2] and the result looks the same. It > seems, we don't enable or disable something unintentionally here as > well. >=20 > WBR, Alexander Turenko. commit 41fb2d2ae39007ee47d90c49de77120c337ee267 Author: Roman Khabibov Date: Mon Jan 18 21:48:35 2021 +0300 build: enable smtp in libcurl =20 Enable smtp protocol in bundled libcurl. =20 Part of #4559 diff --git a/cmake/BuildLibCURL.cmake b/cmake/BuildLibCURL.cmake index 5f8b15a63..313adfb97 100644 --- a/cmake/BuildLibCURL.cmake +++ b/cmake/BuildLibCURL.cmake @@ -124,6 +124,7 @@ macro(curl_build) --enable-http-auth --enable-mime --enable-dateparse + --enable-smtp =20 ${DISABLED_DNS_OPT} --disable-ftp @@ -137,7 +138,6 @@ macro(curl_build) --disable-pop3 --disable-imap --disable-smb - --disable-smtp --disable-gopher --disable-manual --disable-sspi diff --git a/test/box-tap/curl-build.test.lua = b/test/box-tap/curl-build.test.lua index 300d60b07..640d5d143 100755 --- a/test/box-tap/curl-build.test.lua +++ b/test/box-tap/curl-build.test.lua @@ -56,7 +56,7 @@ ffi.cdef([[ =20 local info =3D ffi.C.curl_version_info(7) local test =3D tap.test('curl-features') -test:plan(3) +test:plan(5) =20 if test:ok(info.ssl_version ~=3D nil, 'Curl built with SSL support') = then test:diag('ssl_version: ' .. ffi.string(info.ssl_version)) @@ -174,4 +174,29 @@ test:test('curl_symbols', function(t) end end) =20 +local function has_protocol(protocol_str) + local i =3D 0 + -- curl_version_info_data.protocols is a null terminated array + -- of pointers to char. + -- See curl/lib/version.c: + -- static const char * const protocols[] + local info =3D ffi.C.curl_version_info(7) + local protocol =3D info.protocols[i] + while protocol ~=3D nil do + if ffi.string(protocol) =3D=3D protocol_str then + return true + end + i =3D i + 1 + protocol =3D info.protocols[i] + end + + return false +end + +-- +-- gh-4559: check if smtp and smtps protocols are enabled. +-- +test:ok(has_protocol('smtp'), 'smtp protocol is supported') +test:ok(has_protocol('smtps'), 'smtps protocol is supported') + os.exit(test:check() and 0 or 1)