From 6f79918babb9dddb47ee5639725fc4555372fe38 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 21 Sep 2023 19:43:53 -0400 Subject: [PATCH] copy FFMpeg binary into app bundle --- tools/lammps-gui/CMakeLists.txt | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/tools/lammps-gui/CMakeLists.txt b/tools/lammps-gui/CMakeLists.txt index 305e9872d2..504b5c6f60 100644 --- a/tools/lammps-gui/CMakeLists.txt +++ b/tools/lammps-gui/CMakeLists.txt @@ -169,9 +169,17 @@ if(APPLE) COMMENT "Copying additional files into macOS app bundle tree" WORKING_DIRECTORY ${CMAKE_BINARY_DIR} ) + if(FFMPEG_EXECUTABLE) + add_custom_target(copy-ffmpeg + COMMAND ${CMAKE_COMMAND} -E copy_if_different ${FFMPEG_EXECUTABLE} ${APP_CONTENTS}/bin/ + COMMENT "Copying FFMpeg into macOS app bundle tree" + DEPENDS complete-bundle + ) + set(FFMPEG_TARGET copy-ffmpeg) + endif() add_custom_target(dmg COMMAND ${LAMMPS_DIR}/cmake/packaging/build_macos_dmg.sh - DEPENDS complete-bundle + DEPENDS complete-bundle ${FFMPEG_TARGET} COMMENT "Create Drag-n-Drop installer disk image from app bundle" BYPRODUCT LAMMPS-macOS-multiarch.dmg WORKING_DIRECTORY ${CMAKE_BINARY_DIR}