[
https://issues.apache.org/jira/browse/LOGCXX-510?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17144702#comment-17144702
]
Thorsten Schöning commented on LOGCXX-510:
------------------------------------------
{quote}CMake Error at
C:\Users\tschoening\Documents\Svn\Src\Libs\trunk\C++\Logging\log4cxx\0.11.0-SNAPSHOT\src\src\CMakeLists.txt:7
(target_link_libraries):
Attempt to add link library "odbc32.lib" to target "log4cxx" which is not
built in this directory.
This is allowed only when policy CMP0079 is set to NEW.
C:\Users\tschoening\Documents\Svn\Src\Libs\trunk\C++\Logging\log4cxx\0.11.0-SNAPSHOT\src\src\CMakeLists.txt
7
{quote}
https://cmake.org/cmake/help/v3.13/command/cmake_policy.html#command:cmake_policy
This can easily be fixed by adding the following line for Windows only, but I'm
not sure if that is the correct approach.
bq. cmake_policy(SET CMP0079 NEW)
> Build problems using CMAKE and Visual Studio 2019 Community
> -----------------------------------------------------------
>
> Key: LOGCXX-510
> URL: https://issues.apache.org/jira/browse/LOGCXX-510
> Project: Log4cxx
> Issue Type: Bug
> Components: Build
> Affects Versions: 0.11.0
> Reporter: Thorsten Schöning
> Priority: Major
> Attachments: CMP00079.png
>
>
> I just tested building log4cxx using CMAKE and Visual Studio 2019 Community.
> Things failed and I want to use this bug to document everything that I've
> found, because for some things I'm not sure how to handle them properly. Will
> create a new branch to maintain the fixes I came along, so that those can at
> best be later reviewed by others. The branch of interest is currently named
> "logcxx_510_cmake_vs2019_compat".
--
This message was sent by Atlassian Jira
(v8.3.4#803005)