]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Fix detection of CMake-built libuv on Windows
authorMichał Kępień <michal@isc.org>
Thu, 5 Nov 2020 10:45:19 +0000 (11:45 +0100)
committerMichał Kępień <michal@isc.org>
Thu, 5 Nov 2020 10:45:19 +0000 (11:45 +0100)
As of libuv 1.36.0, CMake is the only supported build method for libuv
on Windows.  Account for that fact by adjusting the relevant paths and
DLL file names used in the win32utils/Configure script.  Update
Windows-specific documentation accordingly.

win32utils/Configure
win32utils/build.txt

index f0189151601c16bec47f292f12173bc581fe4c86..1403e40dac55a9191171deb36c3463e470457f5f 100644 (file)
@@ -1319,14 +1319,14 @@ if ($use_libuv eq "yes") {
         die "can't find libuv uv.h include\n";
     }
     my $libuv_inc = File::Spec->catdir($libuv_path, "include");
-    my $libuv_libdir = File::Spec->catdir($libuv_path, "Release");
-    my $libuv_lib = File::Spec->catfile($libuv_libdir, "libuv.lib");
-    my $libuv_dll = File::Spec->catfile($libuv_libdir, "libuv.dll");
+    my $libuv_libdir = File::Spec->catdir($libuv_path, "build\\Release");
+    my $libuv_lib = File::Spec->catfile($libuv_libdir, "uv.lib");
+    my $libuv_dll = File::Spec->catfile($libuv_libdir, "uv.dll");
     if (!-f $libuv_lib) {
-       die "can't find libuv.lib library\n";
+       die "can't find uv.lib library\n";
     }
     if (!-f $libuv_dll) {
-       die "can't find libuv.dll library\n";
+       die "can't find uv.dll library\n";
     }
     $configvar{"LIBUV_PATH"} = "$libuv_path";
     $configinc{"LIBUV_INC"} = "$libuv_inc";
@@ -2460,7 +2460,7 @@ sub makeinstallfile {
     print LOUT "libdns.dll-BCFT\n";
     print LOUT "libirs.dll-BCFT\n";
     print LOUT "libns.dll-BCFT\n";
-    print LOUT "libuv.dll-BCFT\n";
+    print LOUT "uv.dll-BCFT\n";
     if ($use_openssl eq "yes") {
         my $v;
         my $d;
index 35ce02d5c5af489923d68f5d4a3239aa8a1decd3..7cf15a87039e9b44f28b3fa5a10dc5fafce6a475 100644 (file)
@@ -37,7 +37,7 @@ Step 1: Download and build libuv
 
   Download and untar the libuv sources from https://libuv.org/ in the same
   directory in which you extracted the BIND 9 source: if BIND 9 is in
-  \build\bind-9.16.0, for instance, libuv should be in \build\libuv-v1.34.2
+  \build\bind-9.16.9, for instance, libuv should be in \build\libuv-v1.40.0
   (subject to version number changes).
 
   As of this writing, a patch (win32utils/libuv.diff) needs to be applied
@@ -50,15 +50,14 @@ Step 1: Download and build libuv
   Applying the win32utils/libuv.diff patch will no longer be necessary
   for libuv versions released after this pull request has been merged.
 
-  To build libuv, use the vcbuild.bat script in the root directory of
-  libuv's source tree.  Here is a sample command which builds a 64-bit
-  shared libuv library:
+  On Windows, libuv is built using CMake.  Here is a sample sequence of
+  commands which builds a 64-bit shared libuv library:
 
-      cd libuv-v1.34.2
-      vcbuild.bat x64 shared
-
-  The vcbuild.bat script supports several command line switches which can
-  be listed by running "vcbuild.bat --help".
+      cd libuv-v1.40.0
+      mkdir build
+      cd build
+      cmake -DCMAKE_GENERATOR_PLATFORM=x64 ..
+      cmake --build . --config Release
 
 Step 2: Download and build OpenSSL