[ 
https://issues.apache.org/jira/browse/AVRO-3944?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17819239#comment-17819239
 ] 

ASF subversion and git services commented on AVRO-3944:
-------------------------------------------------------

Commit ee34b456c9cafd6de66420678983e9c0d9f7c42c in avro's branch 
refs/heads/branch-1.11 from Mikhail Koviazin
[ https://gitbox.apache.org/repos/asf?p=avro.git;h=ee34b456c ]

[AVRO-3944] small CMake fixes (#2757)

* Bump cmake_minimum_required to 3.5.

Current version triggers a warning during configuration phase:

  CMake Deprecation Warning at CMakeLists.txt:19 (cmake_minimum_required):
    Compatibility with CMake < 3.5 will be removed from a future version of
    CMake.

    Update the VERSION argument <min> value or use a ...<max> suffix to tell
    CMake that the project does not need compatibility with older versions.

CMake 3.5.0 has been released in 2016, so it's safe to assume it's
available everywhere, which correlates with the information from
pkgs.org [1].

[1]: https://pkgs.org/search/?q=cmake&on=name

* CMake: fix the setting CMP0042 policy

The if-statement was always true since minimum cmake version was set to
3.1.
Instead, replace this condition with `if (APPLE)` since this policy
makes sense only on macOS.

(cherry picked from commit 3aec6f413e3c47536b33631af5c18e685df0b608)


> Fix CMake warning
> -----------------
>
>                 Key: AVRO-3944
>                 URL: https://issues.apache.org/jira/browse/AVRO-3944
>             Project: Apache Avro
>          Issue Type: Task
>          Components: c++
>            Reporter: Mikhail Koviazin
>            Assignee: Mikhail Koviazin
>            Priority: Minor
>              Labels: pull-request-available
>          Time Spent: 20m
>  Remaining Estimate: 0h
>
> Currently cmake_minimum_version is set to 3.1. This triggers the warning at 
> least with cmake 3.27.9:
>  
> {code:java}
> CMake Deprecation Warning at CMakeLists.txt:19 (cmake_minimum_required):
>   Compatibility with CMake < 3.5 will be removed from a future version of
>   CMake.  Update the VERSION argument <min> value or use a ...<max> suffix to 
> tell
>   CMake that the project does not need compatibility with older versions.
>  {code}
>  
> Updating cmake_minimum_version to 3.5 should be safe since 3.5.0 was released 
> in 2016, and is available on all supported distros according to 
> [https://pkgs.org/search/?q=cmake&on=name] .



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to