You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by iv...@apache.org on 2026/05/16 16:07:52 UTC
svn commit: r1934262 - apr/apr/trunk
Author: ivan
Date: Sat May 16 16:07:52 2026
New Revision: 1934262
Log:
* README: Document that CMake is only way to build APR on Windows.
Discussion:
https://lists.apache.org/thread/xsth1r443kd6odz43pyyo4k0jdwgtvy3
Modified:
apr/apr/trunk/README
Modified: apr/apr/trunk/README
==============================================================================
--- apr/apr/trunk/README Sat May 16 15:32:17 2026 (r1934261)
+++ apr/apr/trunk/README Sat May 16 16:07:52 2026 (r1934262)
@@ -154,38 +154,19 @@ Resolve dependencies as appropriate.
Configuring and Building APR on Windows
=======================================
-Using Visual Studio, you can build and run the test validation of APR.
-The Makefile.win make file has a bunch of documentation about it's
-options, but a trivial build is simply;
+APR uses CMake to build on Windows.
- nmake -f Makefile.win
- nmake -f Makefile.win PREFIX=c:\desired\path\of\apr install
-
-Note you must manually modify the include\apr.hw file before you
-build to change default options, see the #define APR_HAS_... or the
-#define APR_HAVE_... statements. Be careful, many of these aren't
-appropriate to be modified. The most common change is
-
-#define APR_HAVE_IPV6 1
-
-rather than 0 if this build of APR will be used strictly on machines
-with the IPv6 adapter support installed.
-
-It's trivial to include the apr.dsp (for a static library) or the
-libapr.dsp (for a dynamic library) in your own build project, or you
-can load apr.dsw in Visual Studio 2002 (.NET) or later, which will
-convert these for you into apr.sln and associated .vcproj files.
-
-When using APR as a dynamic library, nothing special is required,
-simply link to libapr-2.lib. To use it as a static library, simply
-define APR_DECLARE_STATIC before you include any apr header files
-in your source, and link to apr-2.lib instead.
-
-On windows, selection of database drivers is via the environment values
-DBD_LIST (for mysql, oracle, pgsql, sqlite2 and/or sqlite3)
-and DBM_LIST (db and/or gdbm). DBD odbc and DBM sdbm are unconditionally
-compiled and installed, do not include these in the list.
+Using command line:
+ cmake -B out/build -G Ninja -DCMAKE_INSTALL_PREFIX=out/install
+ cmake --build out/build
+ cmake --install out/build
+
+Using Visual Studio:
+ 1. Make sure that "C++ CMake tools for Windows" component is installed.
+ 2. Use Visual Studio Open Folder command to open APR source code directory.
+ 3. Use Build command to build APR
+Please refer to README.cmake for more information about CMake options.
Generating Test Coverage information with gcc
=============================================