From 55983e62b083f00c6f3c3c42b10953265ea7854e Mon Sep 17 00:00:00 2001 From: Isuru Fernando Date: Mon, 25 Mar 2024 14:17:04 -0500 Subject: [PATCH] fix cmake syntax --- .../0001-Do-not-override-CXXFLAGS-for-the-libraries.patch | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/recipe/0001-Do-not-override-CXXFLAGS-for-the-libraries.patch b/recipe/0001-Do-not-override-CXXFLAGS-for-the-libraries.patch index 2e938f0..aecf319 100644 --- a/recipe/0001-Do-not-override-CXXFLAGS-for-the-libraries.patch +++ b/recipe/0001-Do-not-override-CXXFLAGS-for-the-libraries.patch @@ -17,16 +17,16 @@ index b06ac4575..a88f8114f 100644 ADD_LIBRARY(${SHARED_TARGET} SHARED ${SOURCE_FILES} ${SOURCE_INCLUDE_FILES} ${API_ABS_INCLUDE_FILES}) - SET_TARGET_PROPERTIES(${SHARED_TARGET} PROPERTIES LINK_FLAGS "${EXTRA_LINK_FLAGS}" COMPILE_FLAGS "${EXTRA_COMPILE_FLAGS} -DOPENMM_BUILDING_SHARED_LIBRARY -DLEPTON_BUILDING_SHARED_LIBRARY -DPTHREAD_BUILDING_SHARED_LIBRARY" SOVERSION "${OPENMM_MAJOR_VERSION}.${OPENMM_MINOR_VERSION}") + SET_TARGET_PROPERTIES(${SHARED_TARGET} PROPERTIES SOVERSION "${OPENMM_MAJOR_VERSION}.${OPENMM_MINOR_VERSION}") -+ TARGET_LINK_OPTIONS(${SHARED_TARGET} PRIVATE "${EXTRA_LINK_FLAGS}") -+ TARGET_COMPILE_OPTIONS(${SHARED_TARGET} PRIVATE "${EXTRA_COMPILE_FLAGS} -DOPENMM_BUILDING_SHARED_LIBRARY -DLEPTON_BUILDING_SHARED_LIBRARY -DPTHREAD_BUILDING_SHARED_LIBRARY") ++ TARGET_LINK_OPTIONS(${SHARED_TARGET} PRIVATE ${EXTRA_LINK_FLAGS}) ++ TARGET_COMPILE_OPTIONS(${SHARED_TARGET} PRIVATE ${EXTRA_COMPILE_FLAGS} -DOPENMM_BUILDING_SHARED_LIBRARY -DLEPTON_BUILDING_SHARED_LIBRARY -DPTHREAD_BUILDING_SHARED_LIBRARY) ENDIF(OPENMM_BUILD_SHARED_LIB) IF(OPENMM_BUILD_STATIC_LIB) ADD_LIBRARY(${STATIC_TARGET} STATIC ${SOURCE_FILES} ${SOURCE_INCLUDE_FILES} ${API_ABS_INCLUDE_FILES}) SET(EXTRA_COMPILE_FLAGS "${EXTRA_COMPILE_FLAGS} -DOPENMM_USE_STATIC_LIBRARIES -DLEPTON_USE_STATIC_LIBRARIES -DPTW32_STATIC_LIB") - SET_TARGET_PROPERTIES(${STATIC_TARGET} PROPERTIES LINK_FLAGS "${EXTRA_LINK_FLAGS}" COMPILE_FLAGS "${EXTRA_COMPILE_FLAGS} -DOPENMM_BUILDING_STATIC_LIBRARY -DLEPTON_BUILDING_STATIC_LIBRARY -DPTHREAD_BUILDING_STATIC_LIBRARY") -+ TARGET_LINK_OPTIONS(${STATIC_TARGET} PRIVATE "${EXTRA_LINK_FLAGS}") -+ TARGET_COMPILE_OPTIONS(${STATIC_TARGET} PRIVATE "${EXTRA_COMPILE_FLAGS} -DOPENMM_BUILDING_STATIC_LIBRARY -DLEPTON_BUILDING_STATIC_LIBRARY -DPTHREAD_BUILDING_STATIC_LIBRARY") ++ TARGET_LINK_OPTIONS(${STATIC_TARGET} PRIVATE ${EXTRA_LINK_FLAGS}) ++ TARGET_COMPILE_OPTIONS(${STATIC_TARGET} PRIVATE ${EXTRA_COMPILE_FLAGS} -DOPENMM_BUILDING_STATIC_LIBRARY -DLEPTON_BUILDING_STATIC_LIBRARY -DPTHREAD_BUILDING_STATIC_LIBRARY) ENDIF(OPENMM_BUILD_STATIC_LIB) IF(OPENMM_BUILD_C_AND_FORTRAN_WRAPPERS)