mirror of
				https://github.com/bytecodealliance/wasm-micro-runtime.git
				synced 2025-10-26 19:01:17 +00:00 
			
		
		
		
	 f51d98f850
			
		
	
	
		f51d98f850
		
			
		
	
	
	
	
		
			
			This PR attempts to search for the system libuv and use it if found instead of downloading it. As reported in #1831, this is needed because some tools build in a sandbox and clear the extra sources.
		
			
				
	
	
		
			29 lines
		
	
	
		
			705 B
		
	
	
	
		
			CMake
		
	
	
	
	
	
			
		
		
	
	
			29 lines
		
	
	
		
			705 B
		
	
	
	
		
			CMake
		
	
	
	
	
	
| # Copyright (C) 2023 Intel Corporation.  All rights reserved.
 | |
| # SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
 | |
| 
 | |
| # Find libuv library
 | |
| # This module defines
 | |
| #  LIBUV_FOUND, if false, do not try to link to libuv
 | |
| #  LIBUV_LIBRARIES
 | |
| #  LIBUV_INCLUDE_DIR, where to find uv.h
 | |
| 
 | |
| find_path(LIBUV_INCLUDE_DIR NAMES uv.h)
 | |
| find_library(LIBUV_LIBRARIES NAMES uv libuv)
 | |
| 
 | |
| include(FindPackageHandleStandardArgs)
 | |
| 
 | |
| find_package_handle_standard_args(
 | |
|   LIBUV
 | |
|   FOUND_VAR LIBUV_FOUND
 | |
|   REQUIRED_VARS
 | |
|     LIBUV_LIBRARIES
 | |
|     LIBUV_INCLUDE_DIR
 | |
| )
 | |
| 
 | |
| if(WIN32)
 | |
|   list(APPEND LIBUV_LIBRARIES iphlpapi)
 | |
|   list(APPEND LIBUV_LIBRARIES psapi)
 | |
|   list(APPEND LIBUV_LIBRARIES userenv)
 | |
|   list(APPEND LIBUV_LIBRARIES ws2_32)
 | |
| endif()
 |