You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by mi...@apache.org on 2025/03/12 14:22:29 UTC

svn commit: r1924334 - /apr/apr-util/branches/1.7.x/CMakeLists.txt

Author: minfrin
Date: Wed Mar 12 14:22:29 2025
New Revision: 1924334

URL: http://svn.apache.org/viewvc?rev=1924334&view=rev
Log:
testldap: Reinstate Windows LDAP library for legacy tests

Modified:
    apr/apr-util/branches/1.7.x/CMakeLists.txt

Modified: apr/apr-util/branches/1.7.x/CMakeLists.txt
URL: http://svn.apache.org/viewvc/apr/apr-util/branches/1.7.x/CMakeLists.txt?rev=1924334&r1=1924333&r2=1924334&view=diff
==============================================================================
--- apr/apr-util/branches/1.7.x/CMakeLists.txt (original)
+++ apr/apr-util/branches/1.7.x/CMakeLists.txt Wed Mar 12 14:22:29 2025
@@ -410,7 +410,7 @@ IF(APU_BUILD_TEST)
   ENDFOREACH()
 
   ADD_EXECUTABLE(testall ${APR_TEST_SOURCES})
-  TARGET_LINK_LIBRARIES(testall ${whichapr})
+  TARGET_LINK_LIBRARIES(testall ${whichapr} ${LDAP_LIBRARIES})
   TARGET_COMPILE_DEFINITIONS(testall PRIVATE "BINPATH=$<TARGET_FILE_DIR:testall>")
 
   FOREACH(test ${APR_TEST_SUITES})



Re: svn commit: r1924334 - /apr/apr-util/branches/1.7.x/CMakeLists.txt

Posted by Ivan Zhakov via dev <de...@apr.apache.org>.
On Wed, 12 Mar 2025 at 17:01, Graham Leggett <mi...@sharp.fm> wrote:

> On 12 Mar 2025, at 15:37, Ivan Zhakov via dev <de...@apr.apache.org> wrote:
>
>    ADD_EXECUTABLE(testall ${APR_TEST_SOURCES})
>
>> -  TARGET_LINK_LIBRARIES(testall ${whichapr})
>> +  TARGET_LINK_LIBRARIES(testall ${whichapr} ${LDAP_LIBRARIES})
>>    TARGET_COMPILE_DEFINITIONS(testall PRIVATE
>> "BINPATH=$<TARGET_FILE_DIR:testall>")
>>
>> Dependencies should be configured for apr/apr-util library itself: CMake
> should use library dependencies when properly configured.
>
>
> The legacy tests access Windows LDAP functions directly, and as a result
> without the above linking fails and the build fails. Reinstating this made
> the build work again.
>
> Oops, I wasn't aware that legacy tests access Windows LDAP functions
directly. Yes, in this case they should be declared as dependency for
testall program.


> Note that the apr-trunk has no legacy tests, and no need to link to
> anything, this is purely an apr-util problem.
>
> ok


-- 
Ivan Zhakov

Re: svn commit: r1924334 - /apr/apr-util/branches/1.7.x/CMakeLists.txt

Posted by Graham Leggett via dev <de...@apr.apache.org>.
On 12 Mar 2025, at 15:37, Ivan Zhakov via dev <de...@apr.apache.org> wrote:

>    ADD_EXECUTABLE(testall ${APR_TEST_SOURCES})
>> -  TARGET_LINK_LIBRARIES(testall ${whichapr})
>> +  TARGET_LINK_LIBRARIES(testall ${whichapr} ${LDAP_LIBRARIES})
>>    TARGET_COMPILE_DEFINITIONS(testall PRIVATE "BINPATH=$<TARGET_FILE_DIR:testall>")
>> 
> Dependencies should be configured for apr/apr-util library itself: CMake should use library dependencies when properly configured.

The legacy tests access Windows LDAP functions directly, and as a result without the above linking fails and the build fails. Reinstating this made the build work again.

Note that the apr-trunk has no legacy tests, and no need to link to anything, this is purely an apr-util problem.

Regards,
Graham
--