Skip to content

Commit

Permalink
pcre cmake
Browse files Browse the repository at this point in the history
  • Loading branch information
svlobanov committed Aug 31, 2024
1 parent b35a4cd commit f5633c6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 12 deletions.
10 changes: 0 additions & 10 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -23,16 +23,6 @@ ENDIF (NOT DEFINED LIB_SUFFIX)
#color console example message(FATAL_ERROR "${Esc}[31m Red Text ${Esc}[m Restore Normal Text")
string(ASCII 27 Esc)

#Check libpcre
find_library(PCRE_LIBRARY pcre
HINTS ${CMAKE_SOURCE_DIR}/lib/linux/gcc/${BIT}/lib
PATHS ${CMAKE_SOURCE_DIR}/lib/linux/gcc/${BIT}/lib
)

IF(NOT PCRE_LIBRARY)
message(FATAL_ERROR "${Esc}[31mRequired libpcre not found.\n Install libpcre3-dev and run cmake again${Esc}[m")
ENDIF(NOT PCRE_LIBRARY)

#Check libpcre2
find_library(PCRE2_LIBRARY pcre2-8
HINTS ${CMAKE_SOURCE_DIR}/lib/linux/gcc/${BIT}/lib
Expand Down
4 changes: 2 additions & 2 deletions accel-pppd/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -163,9 +163,9 @@ CHECK_FUNCTION_EXISTS(getcontext HAVE_GETCONTEXT)
CHECK_FUNCTION_EXISTS(setcontext HAVE_SETCONTEXT)

IF (HAVE_GETCONTEXT AND HAVE_SETCONTEXT)
TARGET_LINK_LIBRARIES(accel-pppd triton rt pthread ${crypto_lib} pcre pcre2-8)
TARGET_LINK_LIBRARIES(accel-pppd triton rt pthread ${crypto_lib} pcre2-8)
ELSE (HAVE_GETCONTEXT AND HAVE_SETCONTEXT)
TARGET_LINK_LIBRARIES(accel-pppd triton rt pthread ${crypto_lib} pcre pcre2-8 ucontext)
TARGET_LINK_LIBRARIES(accel-pppd triton rt pthread ${crypto_lib} pcre2-8 ucontext)
ENDIF (HAVE_GETCONTEXT AND HAVE_SETCONTEXT)

set_property(TARGET accel-pppd PROPERTY CMAKE_SKIP_BUILD_RPATH FALSE)
Expand Down

0 comments on commit f5633c6

Please sign in to comment.