mirror of
https://github.com/3proxy/3proxy.git
synced 2026-05-13 13:30:12 +08:00
do not use static linking for .so
Some checks failed
C/C++ CI Linux / ${{ matrix.target }} (ubuntu-24.04-arm) (push) Has been cancelled
C/C++ CI Linux / ${{ matrix.target }} (ubuntu-latest) (push) Has been cancelled
C/C++ CI MacOS / ${{ matrix.target }} (macos-15) (push) Has been cancelled
C/C++ CI Windows / ${{ matrix.target }} (windows-2022) (push) Has been cancelled
C/C++ CI cmake / ${{ matrix.target }} (macos-15) (push) Has been cancelled
C/C++ CI cmake / ${{ matrix.target }} (ubuntu-24.04-arm) (push) Has been cancelled
C/C++ CI cmake / ${{ matrix.target }} (ubuntu-latest) (push) Has been cancelled
C/C++ CI cmake / ${{ matrix.target }} (windows-2022) (push) Has been cancelled
Some checks failed
C/C++ CI Linux / ${{ matrix.target }} (ubuntu-24.04-arm) (push) Has been cancelled
C/C++ CI Linux / ${{ matrix.target }} (ubuntu-latest) (push) Has been cancelled
C/C++ CI MacOS / ${{ matrix.target }} (macos-15) (push) Has been cancelled
C/C++ CI Windows / ${{ matrix.target }} (windows-2022) (push) Has been cancelled
C/C++ CI cmake / ${{ matrix.target }} (macos-15) (push) Has been cancelled
C/C++ CI cmake / ${{ matrix.target }} (ubuntu-24.04-arm) (push) Has been cancelled
C/C++ CI cmake / ${{ matrix.target }} (ubuntu-latest) (push) Has been cancelled
C/C++ CI cmake / ${{ matrix.target }} (windows-2022) (push) Has been cancelled
This commit is contained in:
parent
fb9337c030
commit
cbab76fe41
@ -9,18 +9,11 @@ add_3proxy_plugin(PamAuth
|
|||||||
SOURCES pamauth.c
|
SOURCES pamauth.c
|
||||||
)
|
)
|
||||||
|
|
||||||
if(3PROXY_STATIC_LINK)
|
if(TARGET PAM::PAM)
|
||||||
set(_saved_cmake_find_library_suffixes ${CMAKE_FIND_LIBRARY_SUFFIXES})
|
|
||||||
set(CMAKE_FIND_LIBRARY_SUFFIXES ".a")
|
|
||||||
find_library(_pam_static_lib pam)
|
|
||||||
set(CMAKE_FIND_LIBRARY_SUFFIXES ${_saved_cmake_find_library_suffixes})
|
|
||||||
if(_pam_static_lib)
|
|
||||||
target_link_libraries(PamAuth PRIVATE -Wl,-Bstatic ${_pam_static_lib} -Wl,-Bdynamic)
|
|
||||||
message(STATUS "PamAuth: static PAM")
|
|
||||||
else()
|
|
||||||
message(WARNING "3PROXY_STATIC_LINK is ON but static PAM not found, using dynamic")
|
|
||||||
target_link_libraries(PamAuth PRIVATE PAM::PAM)
|
|
||||||
endif()
|
|
||||||
else()
|
|
||||||
target_link_libraries(PamAuth PRIVATE PAM::PAM)
|
target_link_libraries(PamAuth PRIVATE PAM::PAM)
|
||||||
|
else()
|
||||||
|
target_link_libraries(PamAuth PRIVATE ${PAM_LIBRARIES})
|
||||||
|
if(PAM_INCLUDE_DIRS)
|
||||||
|
target_include_directories(PamAuth PRIVATE ${PAM_INCLUDE_DIRS})
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user