From: Igor Munkin <imun@tarantool.org> To: Olga Arkhangelskaia <arkholga@tarantool.org> Cc: tarantool-patches@dev.tarantool.org Subject: Re: [Tarantool-patches] [PATCH] cmake: set CMP0037 policy to NEW by default Date: Mon, 25 May 2020 15:28:47 +0300 [thread overview] Message-ID: <20200525122847.GH5455@tarantool.org> (raw) In-Reply-To: <cc96d61a-7bc5-e001-2e23-bf5d784921af@tarantool.org> Olya, Thanks for the patch! The warning is gone (I checked the patch manually on Gentoo with Cmake 3.14.6), but I see configuration failures on some platforms (e.g. Ubuntu 18.04[1]). It looks like the problem occurs when NEW policy is used for CMake older than 3.11 (Ubuntu 18.04 default repos provides 3.10.2). I reproduced the failure manually with Ubuntu docker. After reverting your patch, configuration succeeds with no warnings. It looks like we need a custom behaviour for different CMake versions, doesn't it? Furthermore, I left several nits regarding commit message below, please consider them. On 21.05.20, Olga Arkhangelskaia wrote: > Hi Igor! Thanks for the review. > > I did not get Sasha's approach. However, according to cmake > documentations name test in > > add_custom_target can be used if the modules CTest or CPAck is enabled. > > https://cmake.org/cmake/help/latest/policy/CMP0037.html?highlight=cmp0037 > > So we just need to use NEW behaviour and cmake 3.11 and above. > > See: Please also include the commit message whether it was changed: | cmake: set CMP0037 policy to NEW | | To stop deprecation warning CMP0037 policy was changed to NEW. Typo: s/stop/fix/. | Deprecation warnings tells us that OLD behaviour will be dropped in the Minor: s/tells/inform/. | next versions. | | CMP0037 old behavior (cmake 2.8.12) allowed taget names such as test, Typo: s/taget/target/. | however in versions 3.10 and below names test, help and etc. were Typo: consider line break right after <were> to fit 72 symbols. | complitely anavailable because cmake always reserved them. Typo: s/complitely/completely/. Typo: s/anavailable/unavailable/. Minor: I guess <always> can be omitted considering the past tense. | Starting from cmake 3.11 this names only reserved when the corresponding Typo: s/this names only reserved/these names are only reserved/. | feature is enabled (e.g. by including the CTest or CPack modules). | Tarantool does not use CTest so the name test can be used. | Users have to use cmake 3.11 and above. Side note: Do we need to update Tarantool build requirements anywhere? | | Closes: #3587 Please, don't use ':' in gh tags. It just doesn't respect our commit message style. > > -if(POLICY CMP0037) > - cmake_policy(SET CMP0037 OLD) > -endif(POLICY CMP0037) > - > > + if(POLICY CMP0037) > + cmake_policy(SET CMP0037 NEW) > + endif(POLICY CMP0037) > + > Side note: there is no whitespace change on the branch. > <snipped> [1]: https://gitlab.com/tarantool/tarantool/-/jobs/562530585 -- Best regards, IM
next prev parent reply other threads:[~2020-05-25 12:37 UTC|newest] Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top 2020-03-16 12:15 Olga Arkhangelskaia 2020-04-27 17:09 ` Igor Munkin 2020-05-21 15:33 ` Olga Arkhangelskaia 2020-05-25 12:28 ` Igor Munkin [this message] 2020-05-25 16:19 ` Olga Arkhangelskaia 2020-05-26 8:59 ` Igor Munkin 2020-05-26 9:12 ` Igor Munkin 2020-05-27 10:17 ` Olga Arkhangelskaia 2020-05-27 10:15 ` Olga Arkhangelskaia 2020-06-14 22:22 ` Alexander Turenko
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20200525122847.GH5455@tarantool.org \ --to=imun@tarantool.org \ --cc=arkholga@tarantool.org \ --cc=tarantool-patches@dev.tarantool.org \ --subject='Re: [Tarantool-patches] [PATCH] cmake: set CMP0037 policy to NEW by default' \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox