Skip to content

Commit

Permalink
Fix CMake-config for SDK-examples
Browse files Browse the repository at this point in the history
  • Loading branch information
martinweismann committed Apr 24, 2018
1 parent 0ebbad7 commit 8e451c0
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions SDK/Examples/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@ cmake_minimum_required (VERSION 2.6)

if (WIN32)
set(LSUFFIX "dll")
set(LPREFIX "")
set(LSUFFIXOUT ".dll")
elseif(UNIX AND NOT APPLE)
set(LSUFFIX "so")
set(LPREFIX "lib")
set(LSUFFIXOUT ".so.1")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -O2")
else()
set(LSUFFIX "dylib")
set(LPREFIX "lib")
set(LSUFFIXOUT ".1.dylib")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -O2")
endif()

Expand All @@ -30,7 +30,7 @@ else()
endif()

function(CopySharedLibrary MyTarget)
add_custom_command(TARGET ${MyTarget} POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different "${CMAKE_CURRENT_SOURCE_DIR}/../Lib/lib3MF.${LSUFFIX}" $<TARGET_FILE_DIR:${MyTarget}>/${LPREFIX}lib3MF.${LSUFFIX})
add_custom_command(TARGET ${MyTarget} POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different "${CMAKE_CURRENT_SOURCE_DIR}/../Lib/lib3MF.${LSUFFIX}" $<TARGET_FILE_DIR:${MyTarget}>/lib3MF${LSUFFIXOUT})
endfunction(CopySharedLibrary)

add_executable(Example_ColorCube Source/ColorCube.cpp)
Expand Down
2 changes: 1 addition & 1 deletion SDK/Examples/Source/TextureCube.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ LIB3MFRESULT fnLoadModelTexture(PLib3MFModel * pModel, const char * pszPath, con
bool SimpleCallback(int step, ProgressIdentifier identifier, void * pUserData) {

std::cout << "Step = " << step;
if (identifier != ProgressIdentifier::PROGRESS_QUERYCANCELED) {
if (identifier != PROGRESS_QUERYCANCELED) {
const char * progressMessage;
NMR::lib3mf_retrieveprogressmessage(identifier, &progressMessage);
std::cout << " \"" << progressMessage << "\"\n";
Expand Down

0 comments on commit 8e451c0

Please sign in to comment.