Commit 1088ad2a authored by schultezub's avatar schultezub
Browse files

fixed cmake macros

git-svn-id: https://camplinux.in.tum.de/svn/campvis/trunk@178 bb408c1c-ae56-11e1-83d9-df6b3e0c105e
parent c56d5c41
...@@ -18,7 +18,7 @@ ENDMACRO(LIST_SUBDIRECTORIES) ...@@ -18,7 +18,7 @@ ENDMACRO(LIST_SUBDIRECTORIES)
MACRO(COPY_EXTERNAL_DLLS DebugDLLs ReleaseDLLs failOnError) MACRO(COPY_EXTERNAL_DLLS DebugDLLs ReleaseDLLs failOnError)
MESSAGE(STATUS "Copying external DLLs") MESSAGE(STATUS "Copying external DLLs")
SET(debug_dir "${VRN_HOME}/bin/Debug") SET(debug_dir "${TUMVIS_HOME}/bin/Debug")
IF(NOT EXISTS ${debug_dir}) IF(NOT EXISTS ${debug_dir})
FILE(MAKE_DIRECTORY ${debug_dir}) FILE(MAKE_DIRECTORY ${debug_dir})
ENDIF() ENDIF()
...@@ -36,7 +36,7 @@ MACRO(COPY_EXTERNAL_DLLS DebugDLLs ReleaseDLLs failOnError) ...@@ -36,7 +36,7 @@ MACRO(COPY_EXTERNAL_DLLS DebugDLLs ReleaseDLLs failOnError)
ENDIF() ENDIF()
ENDFOREACH() ENDFOREACH()
SET(release_dir "${VRN_HOME}/bin/Release") SET(release_dir "${TUMVIS_HOME}/bin/Release")
IF(NOT EXISTS ${release_dir}) IF(NOT EXISTS ${release_dir})
FILE(MAKE_DIRECTORY ${release_dir}) FILE(MAKE_DIRECTORY ${release_dir})
ENDIF() ENDIF()
...@@ -64,13 +64,13 @@ MACRO(ADD_COPY_DLL_COMMAND Target DebugDLLs ReleaseDLLs) ...@@ -64,13 +64,13 @@ MACRO(ADD_COPY_DLL_COMMAND Target DebugDLLs ReleaseDLLs)
MESSAGE(${dll}) MESSAGE(${dll})
ADD_CUSTOM_COMMAND( ADD_CUSTOM_COMMAND(
TARGET ${Target} TARGET ${Target}
COMMAND ${CMAKE_COMMAND} -E copy ${dll} ${VRN_HOME}/bin/Debug COMMAND ${CMAKE_COMMAND} -E copy ${dll} ${TUMVIS_HOME}/bin/Debug
) )
ENDFOREACH() ENDFOREACH()
FOREACH(dll ${${ReleaseDLLs}}) FOREACH(dll ${${ReleaseDLLs}})
ADD_CUSTOM_COMMAND( ADD_CUSTOM_COMMAND(
TARGET ${Target} TARGET ${Target}
COMMAND ${CMAKE_COMMAND} -E copy ${dll} ${VRN_HOME}/bin/Release COMMAND ${CMAKE_COMMAND} -E copy ${dll} ${TUMVIS_HOME}/bin/Release
) )
ENDFOREACH() ENDFOREACH()
ENDMACRO(ADD_COPY_DLL_COMMAND) ENDMACRO(ADD_COPY_DLL_COMMAND)
......
...@@ -39,7 +39,7 @@ namespace TUMVis { ...@@ -39,7 +39,7 @@ namespace TUMVis {
// open file and prepare for read // open file and prepare for read
std::ifstream file(_url.c_str(), std::ios::in | std::ios::binary | std::ios::ate); std::ifstream file(_url.c_str(), std::ios::in | std::ios::binary | std::ios::ate);
if (file.is_open()) { if (file.is_open()) {
size_t fileSize = file.tellg(); size_t fileSize = static_cast<size_t>(file.tellg());
if (fileSize < numBytes) { if (fileSize < numBytes) {
LERROR("File is smaller than expected."); LERROR("File is smaller than expected.");
return WeaklyTypedPointer(_type, 0); return WeaklyTypedPointer(_type, 0);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment