mirror of
https://git.mirrors.martin98.com/https://github.com/slic3r/Slic3r.git
synced 2025-08-14 01:45:53 +08:00
try to fix macos build
This commit is contained in:
parent
078e902b00
commit
bb2a4c13fb
33
.github/workflows/ccpp_mac.yml
vendored
33
.github/workflows/ccpp_mac.yml
vendored
@ -43,40 +43,41 @@ jobs:
|
||||
- name: cmake
|
||||
working-directory: ./build
|
||||
run: cmake .. -DCMAKE_PREFIX_PATH="$PWD/../deps/build/destdir/usr/local" -DCMAKE_OSX_DEPLOYMENT_TARGET="10.13" -DSLIC3R_STATIC=1
|
||||
- name: make slic3r
|
||||
- name: make SuperSlicer
|
||||
working-directory: ./build
|
||||
run: make slic3r
|
||||
run: make SuperSlicer
|
||||
- name: update Info.plist
|
||||
working-directory: ./build/src
|
||||
run: sed "s/+UNKNOWN/_$(date '+%F')/" Info.plist >Info.date.plist
|
||||
- name: create directory and copy into it
|
||||
working-directory: ./build
|
||||
run: |
|
||||
mkdir SuperSlicer
|
||||
mkdir SuperSlicer/SuperSlicer.app
|
||||
mkdir SuperSlicer/SuperSlicer.app/Contents
|
||||
mkdir SuperSlicer/SuperSlicer.app/Contents/_CodeSignature
|
||||
mkdir SuperSlicer/SuperSlicer.app/Contents/Frameworks
|
||||
mkdir SuperSlicer/SuperSlicer.app/Contents/MacOS
|
||||
mkdir pack
|
||||
mkdir pack/SuperSlicer
|
||||
mkdir pack/SuperSlicer/SuperSlicer.app
|
||||
mkdir pack/SuperSlicer/SuperSlicer.app/Contents
|
||||
mkdir pack/SuperSlicer/SuperSlicer.app/Contents/_CodeSignature
|
||||
mkdir pack/SuperSlicer/SuperSlicer.app/Contents/Frameworks
|
||||
mkdir pack/SuperSlicer/SuperSlicer.app/Contents/MacOS
|
||||
- name: copy Resources
|
||||
working-directory: ./build
|
||||
run: |
|
||||
cp -Rf ../resources SuperSlicer/SuperSlicer.app/Contents/Resources
|
||||
cp SuperSlicer/SuperSlicer.app/Contents/Resources/icons/slic3r.icns SuperSlicer/SuperSlicer.app/Contents/resources/Slic3r.icns
|
||||
cp src/Info.date.plist SuperSlicer/SuperSlicer.app/Contents/Info.plist
|
||||
cp -Rf ../resources pack/SuperSlicer/SuperSlicer.app/Contents/Resources
|
||||
cp pack/SuperSlicer/SuperSlicer.app/Contents/Resources/icons/slic3r.icns pack/SuperSlicer/SuperSlicer.app/Contents/resources/Slic3r.icns
|
||||
cp src/Info.date.plist pack/SuperSlicer/SuperSlicer.app/Contents/Info.plist
|
||||
echo -n -e 'APPL????\x0a' > PkgInfo
|
||||
cp PkgInfo SuperSlicer/SuperSlicer.app/Contents/PkgInfo
|
||||
cp PkgInfo pack/SuperSlicer/SuperSlicer.app/Contents/PkgInfo
|
||||
# echo -n -e '\xff\xfeAPPL\x3f\x00\x3f\x00\x3f\x00\x3f\x00\x0a\x00' > PkgInfo
|
||||
- name: copy bin and do not let it lower case
|
||||
working-directory: ./build
|
||||
run: |
|
||||
cp -f src/superslicer SuperSlicer/SuperSlicer.app/Contents/MacOS/SuperSlicer
|
||||
chmod u+x SuperSlicer/SuperSlicer.app/Contents/MacOS/SuperSlicer
|
||||
tar -cvf SuperSlicer.tar SuperSlicer
|
||||
cp -f src/SuperSlicer pack/SuperSlicer/SuperSlicer.app/Contents/MacOS/SuperSlicer
|
||||
chmod u+x pack/SuperSlicer/SuperSlicer.app/Contents/MacOS/SuperSlicer
|
||||
tar -cvf SuperSlicer.tar pack/SuperSlicer
|
||||
- name: create dmg
|
||||
working-directory: ./build
|
||||
run: |
|
||||
hdiutil create -ov -fs HFS+ -volname "SuperSlicer" -srcfolder "SuperSlicer" temp.dmg
|
||||
hdiutil create -ov -fs HFS+ -volname "SuperSlicer" -srcfolder "pack/SuperSlicer" temp.dmg
|
||||
hdiutil convert temp.dmg -format UDZO -o SuperSlicer.dmg
|
||||
# - name: signing Resources (creating CodeResources inside _CodeSignature)
|
||||
# working-directory: .
|
||||
|
4
.github/workflows/ccpp_ubuntu.yml
vendored
4
.github/workflows/ccpp_ubuntu.yml
vendored
@ -44,9 +44,9 @@ jobs:
|
||||
- name: cmake
|
||||
working-directory: ./build
|
||||
run: cmake .. -DCMAKE_PREFIX_PATH="/home/runner/work/SuperSlicer/SuperSlicer/deps/build/destdir/usr/local" -DSLIC3R_STATIC=1
|
||||
- name: make slic3r
|
||||
- name: make SuperSlicer
|
||||
working-directory: ./build
|
||||
run: make slic3r
|
||||
run: make SuperSlicer
|
||||
- name: create directory and copy into it
|
||||
working-directory: ./build
|
||||
run: |
|
||||
|
@ -1,5 +1,5 @@
|
||||
cmake_minimum_required(VERSION 3.13)
|
||||
project(Slic3r)
|
||||
project(SuperSlicer)
|
||||
|
||||
include("version.inc")
|
||||
include(GNUInstallDirs)
|
||||
@ -22,11 +22,11 @@ else()
|
||||
endif()
|
||||
endif()
|
||||
|
||||
option(SLIC3R_STATIC "Compile Slic3r with static libraries (Boost, TBB, glew)" ${SLIC3R_STATIC_INITIAL})
|
||||
option(SLIC3R_GUI "Compile Slic3r with GUI components (OpenGL, wxWidgets)" 1)
|
||||
option(SLIC3R_FHS "Assume Slic3r is to be installed in a FHS directory structure" 0)
|
||||
option(SLIC3R_STATIC "Compile SuperSlicer with static libraries (Boost, TBB, glew)" ${SLIC3R_STATIC_INITIAL})
|
||||
option(SLIC3R_GUI "Compile SuperSlicer with GUI components (OpenGL, wxWidgets)" 1)
|
||||
option(SLIC3R_FHS "Assume SuperSlicer is to be installed in a FHS directory structure" 0)
|
||||
option(SLIC3R_WX_STABLE "Build against wxWidgets stable (3.0) as oppsed to dev (3.1) on Linux" 0)
|
||||
option(SLIC3R_PROFILE "Compile Slic3r with an invasive Shiny profiler" 0)
|
||||
option(SLIC3R_PROFILE "Compile SuperSlicer with an invasive Shiny profiler" 0)
|
||||
option(SLIC3R_PCH "Use precompiled headers" 1)
|
||||
option(SLIC3R_MSVC_COMPILE_PARALLEL "Compile on Visual Studio in parallel" 1)
|
||||
option(SLIC3R_MSVC_PDB "Generate PDB files on MSVC in Release mode" 1)
|
||||
@ -239,13 +239,13 @@ add_definitions(-DwxUSE_UNICODE -D_UNICODE -DUNICODE -DWXINTL_NO_GETTEXT_MACRO)
|
||||
add_definitions(-DwxNO_UNSAFE_WXSTRING_CONV)
|
||||
|
||||
if (SLIC3R_PROFILE)
|
||||
message("Slic3r will be built with a Shiny invasive profiler")
|
||||
message("SuperSlicer will be built with a Shiny invasive profiler")
|
||||
add_definitions(-DSLIC3R_PROFILE)
|
||||
endif ()
|
||||
|
||||
# Disable optimization even with debugging on.
|
||||
if (0)
|
||||
message(STATUS "Perl compiled without optimization. Disabling optimization for the Slic3r build.")
|
||||
message(STATUS "Perl compiled without optimization. Disabling optimization for the SuperSlicer build.")
|
||||
message("Old CMAKE_CXX_FLAGS_RELEASE: ${CMAKE_CXX_FLAGS_RELEASE}")
|
||||
message("Old CMAKE_CXX_FLAGS_RELWITHDEBINFO: ${CMAKE_CXX_FLAGS_RELEASE}")
|
||||
message("Old CMAKE_CXX_FLAGS: ${CMAKE_CXX_FLAGS_RELEASE}")
|
||||
@ -490,9 +490,9 @@ function(prusaslicer_copy_dlls target)
|
||||
endfunction()
|
||||
|
||||
|
||||
# libslic3r, Slic3r GUI and the slic3r executable.
|
||||
# libslic3r, SuperSlicer GUI and the SuperSlicer executable.
|
||||
add_subdirectory(src)
|
||||
set_property(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} PROPERTY VS_STARTUP_PROJECT slic3r_app_console)
|
||||
set_property(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} PROPERTY VS_STARTUP_PROJECT SuperSlicer_app_console)
|
||||
|
||||
# Perl bindings, currently only used for the unit / integration tests of libslic3r.
|
||||
# Also runs the unit / integration tests.
|
||||
|
@ -1,5 +1,5 @@
|
||||
cmake_minimum_required(VERSION 3.13)
|
||||
project(Slic3r-native)
|
||||
project(SuperSlicer-native)
|
||||
|
||||
add_subdirectory(build-utils)
|
||||
add_subdirectory(admesh)
|
||||
@ -89,56 +89,56 @@ if (SLIC3R_GUI)
|
||||
endif()
|
||||
|
||||
|
||||
# Create a slic3r executable
|
||||
# Create a SuperSlicer executable
|
||||
# Process mainfests for various platforms.
|
||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/platform/msw/SuperSlicer.rc.in ${CMAKE_CURRENT_BINARY_DIR}/slic3r.rc @ONLY)
|
||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/platform/msw/SuperSlicer.rc.in ${CMAKE_CURRENT_BINARY_DIR}/SuperSlicer.rc @ONLY)
|
||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/platform/msw/PrusaSlicer-gcodeviewer.rc.in ${CMAKE_CURRENT_BINARY_DIR}/PrusaSlicer-gcodeviewer.rc @ONLY)
|
||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/platform/msw/PrusaSlicer.manifest.in ${CMAKE_CURRENT_BINARY_DIR}/slic3r.manifest @ONLY)
|
||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/platform/msw/PrusaSlicer.manifest.in ${CMAKE_CURRENT_BINARY_DIR}/SuperSlicer.manifest @ONLY)
|
||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/platform/osx/Info.plist.in ${CMAKE_CURRENT_BINARY_DIR}/Info.plist @ONLY)
|
||||
if (WIN32)
|
||||
add_library(slic3r SHARED PrusaSlicer.cpp PrusaSlicer.hpp)
|
||||
add_library(SuperSlicer SHARED PrusaSlicer.cpp PrusaSlicer.hpp)
|
||||
else ()
|
||||
add_executable(slic3r PrusaSlicer.cpp PrusaSlicer.hpp)
|
||||
add_executable(SuperSlicer PrusaSlicer.cpp PrusaSlicer.hpp)
|
||||
endif ()
|
||||
|
||||
if (MINGW)
|
||||
target_link_options(slic3r PUBLIC "-Wl,-allow-multiple-definition")
|
||||
set_target_properties(slic3r PROPERTIES PREFIX "")
|
||||
target_link_options(SuperSlicer PUBLIC "-Wl,-allow-multiple-definition")
|
||||
set_target_properties(SuperSlicer PROPERTIES PREFIX "")
|
||||
endif (MINGW)
|
||||
|
||||
if (NOT WIN32 AND NOT APPLE)
|
||||
# Binary name on unix like systems (Linux, Unix)
|
||||
set_target_properties(slic3r PROPERTIES OUTPUT_NAME "superslicer")
|
||||
set_target_properties(SuperSlicer PROPERTIES OUTPUT_NAME "superslicer")
|
||||
endif ()
|
||||
|
||||
target_link_libraries(slic3r libslic3r cereal)
|
||||
target_link_libraries(SuperSlicer libslic3r cereal)
|
||||
if (APPLE)
|
||||
# add_compile_options(-stdlib=libc++)
|
||||
# add_definitions(-DBOOST_THREAD_DONT_USE_CHRONO -DBOOST_NO_CXX11_RVALUE_REFERENCES -DBOOST_THREAD_USES_MOVE)
|
||||
# -liconv: boost links to libiconv by default
|
||||
target_link_libraries(slic3r "-liconv -framework IOKit" "-framework CoreFoundation" -lc++)
|
||||
target_link_libraries(SuperSlicer "-liconv -framework IOKit" "-framework CoreFoundation" -lc++)
|
||||
elseif (MSVC)
|
||||
# Manifest is provided through slic3r.rc, don't generate your own.
|
||||
# Manifest is provided through SuperSlicer.rc, don't generate your own.
|
||||
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} /MANIFEST:NO")
|
||||
else ()
|
||||
# Boost on Raspberry-Pi does not link to pthreads explicitely.
|
||||
target_link_libraries(slic3r ${CMAKE_DL_LIBS} -lstdc++ Threads::Threads)
|
||||
target_link_libraries(SuperSlicer ${CMAKE_DL_LIBS} -lstdc++ Threads::Threads)
|
||||
endif ()
|
||||
|
||||
# Add the Slic3r GUI library, libcurl, OpenGL and GLU libraries.
|
||||
if (SLIC3R_GUI)
|
||||
# target_link_libraries(PrusaSlicer ws2_32 uxtheme setupapi libslic3r_gui ${wxWidgets_LIBRARIES})
|
||||
target_link_libraries(slic3r libslic3r_gui)
|
||||
target_link_libraries(SuperSlicer libslic3r_gui)
|
||||
if (MSVC)
|
||||
# Generate debug symbols even in release mode.
|
||||
target_link_options(slic3r PUBLIC "$<$<CONFIG:RELEASE>:/DEBUG>")
|
||||
target_link_libraries(slic3r user32.lib Setupapi.lib)
|
||||
target_link_options(SuperSlicer PUBLIC "$<$<CONFIG:RELEASE>:/DEBUG>")
|
||||
target_link_libraries(SuperSlicer user32.lib Setupapi.lib)
|
||||
elseif (MINGW)
|
||||
target_link_libraries(slic3r ws2_32 uxtheme setupapi)
|
||||
target_link_libraries(SuperSlicer ws2_32 uxtheme setupapi)
|
||||
elseif (APPLE)
|
||||
target_link_libraries(slic3r "-framework OpenGL")
|
||||
target_link_libraries(SuperSlicer "-framework OpenGL")
|
||||
else ()
|
||||
target_link_libraries(slic3r -ldl)
|
||||
target_link_libraries(SuperSlicer -ldl)
|
||||
endif ()
|
||||
endif ()
|
||||
|
||||
@ -149,25 +149,25 @@ if (WIN32)
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -municode")
|
||||
endif()
|
||||
|
||||
add_executable(slic3r_app_gui WIN32 PrusaSlicer_app_msvc.cpp ${CMAKE_CURRENT_BINARY_DIR}/slic3r.rc)
|
||||
add_executable(SuperSlicer_app_gui WIN32 PrusaSlicer_app_msvc.cpp ${CMAKE_CURRENT_BINARY_DIR}/SuperSlicer.rc)
|
||||
# Generate debug symbols even in release mode.
|
||||
if(MSVC)
|
||||
target_link_options(slic3r_app_gui PUBLIC "$<$<CONFIG:RELEASE>:/DEBUG>")
|
||||
target_link_options(SuperSlicer_app_gui PUBLIC "$<$<CONFIG:RELEASE>:/DEBUG>")
|
||||
endif()
|
||||
target_compile_definitions(slic3r_app_gui PRIVATE -DSLIC3R_WRAPPER_NOCONSOLE)
|
||||
add_dependencies(slic3r_app_gui slic3r)
|
||||
set_target_properties(slic3r_app_gui PROPERTIES OUTPUT_NAME "superslicer")
|
||||
target_link_libraries(slic3r_app_gui PRIVATE boost_headeronly)
|
||||
target_compile_definitions(SuperSlicer_app_gui PRIVATE -DSLIC3R_WRAPPER_NOCONSOLE)
|
||||
add_dependencies(SuperSlicer_app_gui SuperSlicer)
|
||||
set_target_properties(SuperSlicer_app_gui PROPERTIES OUTPUT_NAME "superslicer")
|
||||
target_link_libraries(SuperSlicer_app_gui PRIVATE boost_headeronly)
|
||||
|
||||
add_executable(slic3r_app_console PrusaSlicer_app_msvc.cpp ${CMAKE_CURRENT_BINARY_DIR}/slic3r.rc)
|
||||
add_executable(SuperSlicer_app_console PrusaSlicer_app_msvc.cpp ${CMAKE_CURRENT_BINARY_DIR}/SuperSlicer.rc)
|
||||
# Generate debug symbols even in release mode.
|
||||
if (MSVC)
|
||||
target_link_options(slic3r_app_console PUBLIC "$<$<CONFIG:RELEASE>:/DEBUG>")
|
||||
target_link_options(SuperSlicer_app_console PUBLIC "$<$<CONFIG:RELEASE>:/DEBUG>")
|
||||
endif ()
|
||||
target_compile_definitions(slic3r_app_console PRIVATE -DSLIC3R_WRAPPER_CONSOLE)
|
||||
add_dependencies(slic3r_app_console slic3r)
|
||||
set_target_properties(slic3r_app_console PROPERTIES OUTPUT_NAME "superslicer_console")
|
||||
target_link_libraries(slic3r_app_console PRIVATE boost_headeronly)
|
||||
target_compile_definitions(SuperSlicer_app_console PRIVATE -DSLIC3R_WRAPPER_CONSOLE)
|
||||
add_dependencies(SuperSlicer_app_console SuperSlicer)
|
||||
set_target_properties(SuperSlicer_app_console PROPERTIES OUTPUT_NAME "superslicer_console")
|
||||
target_link_libraries(SuperSlicer_app_console PRIVATE boost_headeronly)
|
||||
|
||||
add_executable(PrusaSlicer_app_gcodeviewer WIN32 PrusaSlicer_app_msvc.cpp ${CMAKE_CURRENT_BINARY_DIR}/PrusaSlicer-gcodeviewer.rc)
|
||||
# Generate debug symbols even in release mode.
|
||||
@ -175,7 +175,7 @@ if (WIN32)
|
||||
target_link_options(PrusaSlicer_app_gcodeviewer PUBLIC "$<$<CONFIG:RELEASE>:/DEBUG>")
|
||||
endif ()
|
||||
target_compile_definitions(PrusaSlicer_app_gcodeviewer PRIVATE -DSLIC3R_WRAPPER_NOCONSOLE -DSLIC3R_WRAPPER_GCODEVIEWER)
|
||||
add_dependencies(PrusaSlicer_app_gcodeviewer slic3r)
|
||||
add_dependencies(PrusaSlicer_app_gcodeviewer SuperSlicer)
|
||||
set_target_properties(PrusaSlicer_app_gcodeviewer PROPERTIES OUTPUT_NAME "prusa-gcodeviewer")
|
||||
target_link_libraries(PrusaSlicer_app_gcodeviewer PRIVATE boost_headeronly)
|
||||
endif ()
|
||||
@ -186,7 +186,7 @@ if (WIN32)
|
||||
foreach (CONF ${CMAKE_CONFIGURATION_TYPES})
|
||||
file(TO_NATIVE_PATH "${CMAKE_CURRENT_BINARY_DIR}/${CONF}" WIN_CONF_OUTPUT_DIR)
|
||||
file(TO_NATIVE_PATH "${CMAKE_CURRENT_BINARY_DIR}/${CONF}/resources" WIN_RESOURCES_SYMLINK)
|
||||
add_custom_command(TARGET slic3r POST_BUILD
|
||||
add_custom_command(TARGET SuperSlicer POST_BUILD
|
||||
COMMAND if exist "${WIN_CONF_OUTPUT_DIR}" "("
|
||||
if not exist "${WIN_RESOURCES_SYMLINK}" "("
|
||||
mklink /J "${WIN_RESOURCES_SYMLINK}" "${SLIC3R_RESOURCES_DIR_WIN}"
|
||||
@ -198,7 +198,7 @@ if (WIN32)
|
||||
endforeach ()
|
||||
else ()
|
||||
file(TO_NATIVE_PATH "${CMAKE_CURRENT_BINARY_DIR}/resources" WIN_RESOURCES_SYMLINK)
|
||||
add_custom_command(TARGET slic3r POST_BUILD
|
||||
add_custom_command(TARGET SuperSlicer POST_BUILD
|
||||
COMMAND if not exist "${WIN_RESOURCES_SYMLINK}" "(" mklink /J "${WIN_RESOURCES_SYMLINK}" "${SLIC3R_RESOURCES_DIR_WIN}" ")"
|
||||
COMMENT "Symlinking the resources directory into the build tree"
|
||||
VERBATIM
|
||||
@ -206,47 +206,49 @@ if (WIN32)
|
||||
endif ()
|
||||
|
||||
# This has to be a separate target due to the windows command line lenght limits
|
||||
add_custom_target(slic3rDllsCopy ALL DEPENDS slic3r)
|
||||
add_custom_target(slic3rDllsCopy ALL DEPENDS SuperSlicer)
|
||||
prusaslicer_copy_dlls(slic3rDllsCopy)
|
||||
|
||||
else ()
|
||||
if (APPLE)
|
||||
# On OSX, the name of the binary matches the name of the Application.
|
||||
add_custom_command(TARGET slic3r POST_BUILD
|
||||
COMMAND ln -sf slic3r superslicer
|
||||
COMMAND ln -sf slic3r prusa-gcodeviewer
|
||||
COMMAND ln -sf slic3r PrusaGCodeViewer
|
||||
WORKING_DIRECTORY "$<TARGET_FILE_DIR:slic3r>"
|
||||
COMMENT "Symlinking the G-code viewer to slic3r, symlinking to prusa-slicer and prusa-gcodeviewer"
|
||||
add_custom_command(TARGET SuperSlicer POST_BUILD
|
||||
COMMAND ls
|
||||
# COMMAND ln -sf SuperSlicer superslicer
|
||||
COMMAND ln -sf SuperSlicer prusa-gcodeviewer
|
||||
COMMAND ln -sf SuperSlicer PrusaGCodeViewer
|
||||
WORKING_DIRECTORY "$<TARGET_FILE_DIR:SuperSlicer>"
|
||||
COMMENT "Symlinking the G-code viewer to SuperSlicer, symlinking to prusa-slicer and prusa-gcodeviewer"
|
||||
VERBATIM)
|
||||
else ()
|
||||
add_custom_command(TARGET slic3r POST_BUILD
|
||||
add_custom_command(TARGET SuperSlicer POST_BUILD
|
||||
COMMAND ln -sf superslicer prusa-gcodeviewer
|
||||
WORKING_DIRECTORY "$<TARGET_FILE_DIR:slic3r>"
|
||||
COMMENT "Symlinking the G-code viewer to slic3r"
|
||||
WORKING_DIRECTORY "$<TARGET_FILE_DIR:SuperSlicer>"
|
||||
COMMENT "Symlinking the G-code viewer to SuperSlicer"
|
||||
VERBATIM)
|
||||
endif ()
|
||||
if (XCODE)
|
||||
# Because of Debug/Release/etc. configurations (similar to MSVC) the slic3r binary is located in an extra level
|
||||
# Because of Debug/Release/etc. configurations (similar to MSVC) the SuperSlicer binary is located in an extra level
|
||||
set(BIN_RESOURCES_DIR "${CMAKE_CURRENT_BINARY_DIR}/resources")
|
||||
else ()
|
||||
set(BIN_RESOURCES_DIR "${CMAKE_CURRENT_BINARY_DIR}/../resources")
|
||||
endif ()
|
||||
add_custom_command(TARGET slic3r POST_BUILD
|
||||
COMMAND ln -sfn "${SLIC3R_RESOURCES_DIR}" "${BIN_RESOURCES_DIR}"
|
||||
add_custom_command(TARGET SuperSlicer POST_BUILD
|
||||
# COMMAND ln -sfn "${SLIC3R_RESOURCES_DIR}" "${BIN_RESOURCES_DIR}" # make[3]: stat: src/SuperSlicer: Too many levels of symbolic links
|
||||
COMMAND cp -r "${SLIC3R_RESOURCES_DIR}" "${BIN_RESOURCES_DIR}"
|
||||
COMMENT "Symlinking the resources directory into the build tree"
|
||||
VERBATIM)
|
||||
endif ()
|
||||
|
||||
# Slic3r binary install target
|
||||
if (WIN32)
|
||||
install(TARGETS slic3r RUNTIME DESTINATION "${CMAKE_INSTALL_PREFIX}")
|
||||
install(TARGETS SuperSlicer RUNTIME DESTINATION "${CMAKE_INSTALL_PREFIX}")
|
||||
if (MSVC)
|
||||
install(TARGETS slic3r_app_gui RUNTIME DESTINATION "${CMAKE_INSTALL_PREFIX}")
|
||||
install(TARGETS slic3r_app_console RUNTIME DESTINATION "${CMAKE_INSTALL_PREFIX}")
|
||||
install(TARGETS SuperSlicer_app_gui RUNTIME DESTINATION "${CMAKE_INSTALL_PREFIX}")
|
||||
install(TARGETS SuperSlicer_app_console RUNTIME DESTINATION "${CMAKE_INSTALL_PREFIX}")
|
||||
endif ()
|
||||
else ()
|
||||
install(TARGETS slic3r RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}")
|
||||
install(TARGETS SuperSlicer RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}")
|
||||
|
||||
# Install the symlink for gcodeviewer
|
||||
install(CODE "execute_process(COMMAND ${CMAKE_COMMAND} -E create_symlink prusa-slicer prusa-gcodeviewer WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_BINDIR})")
|
||||
|
@ -22,4 +22,4 @@ PRODUCTVERSION @SLIC3R_RC_VERSION@
|
||||
}
|
||||
}
|
||||
2 ICON "@SLIC3R_RESOURCES_DIR@/icons/PrusaSlicer-gcodeviewer.ico"
|
||||
1 24 "slic3r.manifest"
|
||||
1 24 "SuperSlicer.manifest"
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
||||
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" xmlns:asmv3="urn:schemas-microsoft-com:asm.v3" manifestVersion="1.0">
|
||||
<assemblyIdentity version="@SLIC3R_RC_VERSION_DOTS@" name="Slic3r" type="Win32" />
|
||||
<description>Perl</description>
|
||||
<description>C++</description>
|
||||
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
|
||||
<security>
|
||||
<requestedPrivileges>
|
||||
|
@ -22,4 +22,4 @@ PRODUCTVERSION @SLIC3R_RC_VERSION@
|
||||
}
|
||||
}
|
||||
2 ICON "@SLIC3R_RESOURCES_DIR@/icons/slic3r.ico"
|
||||
1 24 "slic3r.manifest"
|
||||
1 24 "SuperSlicer.manifest"
|
||||
|
Loading…
x
Reference in New Issue
Block a user