[...cut...] > > 1. > The setargv.obj is added to all executables at last of CMakeLists.txt. > However, setargv.obj is actually applied to only svn.exe and > svnadmin.exe in build.conf. It is intentional, according to > https://svn.apache.org/r1577170 > > I think we should keep the behavior between build systems. > > [[[ > # Enable globbing for all executables > if(MSVC) > set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} setargv.obj") > endif() > ]]]
I agree with you, I didn't notice this before. I will fix this in the feature version of the patch. Thanks! > 2. > gen-make.py accepts --with-PKG=... options like the following, but all > options should be passed to cmake -B again. Why CMakeLists.txt is > generated instead of adding directly CMakeLists.txt, in the patch? That's a good question. I decided to just generate the CMake files based on build.conf. I think this approach is great because we can keep vcnet project files and Unix Makefiles until the CMake can fully replace them. The dependency searching is delegated to the CMake, so the CMakeLists.txt file can be generated from the release.py script and put into release tar-ball like 'configure', because it would not contain any paths and options. Additionally, we can also someday just simply put the generated CMakeLists.txt file into the repository, cut-off the gen-make build system, and use CMake as the main build system. About --with-PKG=... options; I think we should warn if any of them are specified, because they are ignored by the generator. > [[[ > python gen-make.py -t cmake ^ > --with-httpd=%CD%\..\win64-vs16\httpd ^ > --with-apr=%CD%\..\win64-vs16\httpd ^ > --with-apr-util=%CD%\..\win64-vs16\httpd ^ > --with-openssl=C:\usr\apps\vcpkg\installed\x64-windows-release ^ > --with-zlib==C:\usr\apps\vcpkg\installed\x64-windows-release ^ > --with-libintl=C:\usr\apps\vcpkg\installed\x64-windows-release ^ > --with-sqlite=C:\usr\apps\vcpkg\installed\x64-windows-release ^ > --with-serf=%CD%\..\win64-vs16\serf ^ > --with-swig=%CD%\..\swig\3.0.12 ^ > --with-jdk=C:\usr\apps\jdk-16.0.1 ^ > --with-junit=%CD%\..\junit-4.13.2.jar > ]]] > > Also, I get cmake failing on Windows yet. > > [[[ > C>cmake.exe -B out ^ > -D CMAKE_BUILD_TYPE=Release > -D APR_LIBRARY=%CD%\..\win64-vs16\httpd ^ > -D APRUTIL_LIBRARY=%CD%\..\win64-vs16\httpd ^ > -D APR_INCLUDE_DIR=%CD%\..\win64-vs16\httpd\include ^ > -D APRUTIL_INCLUDE_DIR=%CD%\..\win64-vs16\httpd ^ > -D ZLIB_INCLUDE_DIR=C:\usr\apps\vcpkg\installed\x64-windows-release\include > ^ > -D > ZLIB_LIBRARY=C:\usr\apps\vcpkg\installed\x64-windows-release\lib\zlib.lib ^ > -- Selecting Windows SDK version 10.0.20348.0 to target Windows 10.0.19045. > APR config not found. Looking for libraries and includes... > Found APR library: C:/usr/src/subversion/win64-vs16/httpd > Found APR include dir: C:/usr/src/subversion/win64-vs16/httpd > Found APR-Util library: C:/usr/src/subversion/win64-vs16/httpd > Found APR-Util include dir: C:/usr/src/subversion/win64-vs16/httpd > CMake Error at CMakeLists.txt:141 (find_package): > Could not find a package configuration file provided by "expat" with any of > the following names: > > expatConfig.cmake > expat-config.cmake > > Add the installation prefix of "expat" to CMAKE_PREFIX_PATH or set > "expat_DIR" to a directory containing one of the above files. If "expat" > provides a separate development package or SDK, be sure it has been > installed. > > > -- Configuring incomplete, errors occurred! > ]]] 1. You don't need to pass the options to the gen-make command, because the dependency searching is done via CMake, so the options are ignored. 2. Instead of specifying each include dir and library path, you could just specify the CMAKE_INSTALL_PREFIX variable to a path where the dependencies are installed. 3. The issue with EXPAT exists because you are using the pre-compiled binaries of Apache HTTPD, which include the EXPAT library. However, this distribution doesn't have a CMake config, which is currently needed. To resolve this, try installing the EXPAT library using CMake or vcpkg. I think I will try to support this, but there are some problems. So, the commands would be like the following: [[[ # Other arguments can be simply cut-out, because they are not used. $ python gen-make.py -t cmake # You can specify more than one directories with dependencies by using a semicolon between them. $ cmake.exe -B out -DCMAKE_INSTALL_PREFIX=C:/usr/src/subversion/win64-vs16/httpd;C:\usr\apps\vcpkg\installed\x64-windows-release ]]] -- Timofei Zhakov