From a5dc3fee6a5c51065f268cb19f686284752e69da Mon Sep 17 00:00:00 2001 From: Hyunjin Song Date: Fri, 25 Dec 2020 12:43:17 +0900 Subject: [PATCH] Fix some Wine detection errors --- cmake/modules/FindWine.cmake | 23 ++++++++--------------- src/3rdparty/ringbuffer | 2 +- src/3rdparty/rpmalloc/rpmalloc | 2 +- src/3rdparty/weakjack/weakjack | 2 +- 4 files changed, 11 insertions(+), 18 deletions(-) diff --git a/cmake/modules/FindWine.cmake b/cmake/modules/FindWine.cmake index f7f3b0aa647..024dac1ea50 100644 --- a/cmake/modules/FindWine.cmake +++ b/cmake/modules/FindWine.cmake @@ -3,7 +3,6 @@ # # WINE_FOUND - System has wine # WINE_INCLUDE_DIRS - The wine include directories -# WINE_LIBRARIES - The libraries needed to use wine # WINE_DEFINITIONS - Compiler switches required for using wine # @@ -60,16 +59,16 @@ IF(WINE_CXX) # WineHQ (/opt/wine-stable, /opt/wine-devel, /opt/wine-staging) STRING(REGEX REPLACE "/lib64/wine/$" "/lib/wine/" WINE_32_LIBRARY_DIR "${WINE_32_LIBRARY_DIR}") STRING(REGEX REPLACE "/lib/wine/$" "/lib64/wine/" WINE_64_LIBRARY_DIR "${WINE_64_LIBRARY_DIR}") - ELSEIF(WINE_32_LIBRARY_DIR MATCHES "/lib32/.*/wine/") + ELSEIF(WINE_32_LIBRARY_DIR MATCHES "/lib32/") # Systems with old multilib layout STRING(REPLACE "/lib32/" "/lib/" WINE_64_LIBRARY_DIR "${WINE_32_LIBRARY_DIR}") - ELSEIF(WINE_32_LIBRARY_DIR MATCHES "/lib64/.*/wine/") + ELSEIF(WINE_32_LIBRARY_DIR MATCHES "/lib64/") # We need to test if the corresponding 64bit library directory is lib or lib32 STRING(REPLACE "/lib64/" "/lib32/" WINE_32_LIBRARY_DIR "${WINE_64_LIBRARY_DIR}") IF(NOT EXISTS "${WINE_32_LIBRARY_DIR}") STRING(REPLACE "/lib64/" "/lib/" WINE_32_LIBRARY_DIR "${WINE_64_LIBRARY_DIR}") ENDIF() - ELSEIF(WINE_32_LIBRARY_DIR MATCHES "/lib/.*/wine/") + ELSEIF(WINE_32_LIBRARY_DIR MATCHES "/lib/") # Test if this directory is for 32bit or 64bit STRING(REPLACE "/lib/" "/lib32/" WINE_32_LIBRARY_DIR "${WINE_64_LIBRARY_DIR}") IF(NOT EXISTS "${WINE_32_LIBRARY_DIR}") @@ -89,18 +88,12 @@ FIND_PATH(WINE_INCLUDE_DIR wine/exception.h SET(_ARCHITECTURE ${CMAKE_LIBRARY_ARCHITECTURE}) -FIND_LIBRARY(WINE_LIBRARY NAMES wine - PATH_SUFFIXES wine i386-linux-gnu/wine - HINTS "${WINE_32_LIBRARY_DIR}" "${WINE_64_LIBRARY_DIR}" -) - SET(CMAKE_LIBRARY_ARCHITECTURE ${_ARCHITECTURE}) SET(WINE_INCLUDE_DIRS ${WINE_INCLUDE_DIR} ) -SET(WINE_LIBRARIES ${WINE_LIBRARY}) include(FindPackageHandleStandardArgs) -find_package_handle_standard_args(Wine DEFAULT_MSG WINE_CXX WINE_LIBRARIES WINE_INCLUDE_DIRS) +find_package_handle_standard_args(Wine DEFAULT_MSG WINE_CXX WINE_INCLUDE_DIRS) mark_as_advanced(WINE_INCLUDE_DIR WINE_LIBRARY WINE_CXX WINE_BUILD) @@ -109,8 +102,8 @@ IF(WINE_32_LIBRARY_DIR) SET(WINE_32_FLAGS "-L${WINE_32_LIBRARY_DIR} -L${WINE_32_LIBRARY_DIR}../") SET(WINE_32_LIBRARY_DIRS "${WINE_32_LIBRARY_DIR}:${WINE_32_LIBRARY_DIR}/..") ELSE() - SET(WINE_32_FLAGS "-L${WINE_32_LIBRARY_DIR}") - SET(WINE_32_LIBRARY_DIRS "${WINE_32_LIBRARY_DIR}") + SET(WINE_32_FLAGS "-L${WINE_32_LIBRARY_DIR} -L${WINE_32_LIBRARY_DIR}wine/") + SET(WINE_32_LIBRARY_DIRS "${WINE_32_LIBRARY_DIR}:${WINE_32_LIBRARY_DIR}wine/") ENDIF() ENDIF() @@ -119,8 +112,8 @@ IF(WINE_64_LIBRARY_DIR) SET(WINE_64_FLAGS "-L${WINE_64_LIBRARY_DIR} -L${WINE_64_LIBRARY_DIR}../") SET(WINE_64_LIBRARY_DIRS "${WINE_64_LIBRARY_DIR}:${WINE_64_LIBRARY_DIR}/..") ELSE() - SET(WINE_64_FLAGS "-L${WINE_64_LIBRARY_DIR}") - SET(WINE_64_LIBRARY_DIRS "${WINE_64_LIBRARY_DIR}") + SET(WINE_64_FLAGS "-L${WINE_64_LIBRARY_DIR} -L${WINE_64_LIBRARY_DIR}wine/") + SET(WINE_64_LIBRARY_DIRS "${WINE_64_LIBRARY_DIR}:${WINE_64_LIBRARY_DIR}wine/") ENDIF() ENDIF() diff --git a/src/3rdparty/ringbuffer b/src/3rdparty/ringbuffer index ea00e1fc2b8..82ed7cfb9ad 160000 --- a/src/3rdparty/ringbuffer +++ b/src/3rdparty/ringbuffer @@ -1 +1 @@ -Subproject commit ea00e1fc2b821a0e06d78e8cc13ac06e6b4f72f5 +Subproject commit 82ed7cfb9ad40467421d8b14ca1af0350e92613c diff --git a/src/3rdparty/rpmalloc/rpmalloc b/src/3rdparty/rpmalloc/rpmalloc index 8d790d2b45e..b5bdc18051b 160000 --- a/src/3rdparty/rpmalloc/rpmalloc +++ b/src/3rdparty/rpmalloc/rpmalloc @@ -1 +1 @@ -Subproject commit 8d790d2b45e1818e531c61bf649c5225556dd07a +Subproject commit b5bdc18051bb74a22f0bde4bcc90b01cf590b496 diff --git a/src/3rdparty/weakjack/weakjack b/src/3rdparty/weakjack/weakjack index fd11655be3b..cbb05c52561 160000 --- a/src/3rdparty/weakjack/weakjack +++ b/src/3rdparty/weakjack/weakjack @@ -1 +1 @@ -Subproject commit fd11655be3b2efd6082968ecfe53f9cfe88bda2b +Subproject commit cbb05c52561d921885ad6651af6c8dd9f514dc9a