]> 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 14:07:01 +0000 (15:07 +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.

(cherry picked from commit 64a091d587058641e0b7528054efd92cbb635f41)

win32utils/Configure
win32utils/build.txt

index 9120737903a8575a8bcefd9e31f0480e9bc30b39..98dad2e248ea073ba3628dc39377cea0a47bc8b1 100644 (file)
@@ -1304,14 +1304,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";
@@ -2652,7 +2652,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 22d0a6316509d034c3171c43054ee2c5e75d49af..0cb6818cba3ca2c5949b9ba414872430ef421cb0 100644 (file)
@@ -40,7 +40,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
@@ -53,15 +53,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