@@ -392,32 +392,46 @@ if(BUNDLE_DEPENDENCIES)
392
392
#
393
393
394
394
file (GLOB _bundled1 "${MYSQL_LIB_DIR} /*${CMAKE_SHARED_LIBRARY_SUFFIX} *" )
395
- file (GLOB _bundled2 "${MYSQL_LIB_DIR} /private/*${CMAKE_SHARED_LIBRARY_SUFFIX} *" )
395
+
396
+ # In Windows we need to bundle libraries from bin directory instead
397
+ # of private.
398
+
399
+ if (WIN32 )
400
+ set (_bundled2_path "${MYSQL_LIB_DIR} /../bin" )
401
+ set (_bundled_dest "bin" )
402
+ else ()
403
+ set (_bundled2_path "${MYSQL_LIB_DIR} /private" )
404
+ set (_bundled_dest "${INSTALL_LIB_DIR} /private" )
405
+ endif ()
406
+
407
+ file (GLOB _bundled2 "${_bundled2_path} /*${CMAKE_SHARED_LIBRARY_SUFFIX} *" )
396
408
397
409
foreach (lib IN LISTS _bundled1 _bundled2 )
398
410
399
411
get_filename_component (lib_name ${lib} NAME_WE )
400
412
401
413
# ssl|crypto are bundled on cdk/cmake/DepFindSSL.cmake
402
- if (NOT lib_name MATCHES "mysql|libprotobuf|liblber|libldap_r|libssl|libcrypto" )
403
-
404
- message ("found bundled libs: ${lib} " )
414
+ if (NOT lib_name MATCHES "mysql|libprotobuf|liblber|libldap_r|libssl|libcrypto|libcurl|libmecab" )
415
+ message ("found bundled libs: ${lib} " )
405
416
406
- install (FILES "${lib} "
407
- DESTINATION " ${INSTALL_LIB_DIR} /private"
408
- COMPONENT JDBCDll
409
- )
417
+ install (FILES "${lib} "
418
+ DESTINATION ${_bundled_dest}
419
+ COMPONENT JDBCDll
420
+ )
410
421
411
422
endif ()
412
423
413
- # Also bundle modules required by the SASL library if it is bundled
424
+ if (NOT WIN32 )
425
+ # Also bundle modules required by the SASL library if it is bundled
414
426
415
- if (lib_name MATCHES "libsasl" )
427
+ if (lib_name MATCHES "libsasl" )
416
428
417
- install (DIRECTORY "${MYSQL_LIB_DIR} /private/sasl2"
418
- DESTINATION "${INSTALL_LIB_DIR} /private"
419
- COMPONENT JDBCDll
420
- )
429
+ install (DIRECTORY "${_bundled2_path} /sasl2"
430
+ DESTINATION ${_bundled_dest}
431
+ COMPONENT JDBCDll
432
+ )
433
+
434
+ endif ()
421
435
422
436
endif ()
423
437
0 commit comments