Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Installation rules for InfiniTAM libraries #72

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions InfiniTAM/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -44,3 +44,9 @@ ADD_SUBDIRECTORY(InputSource)
ADD_SUBDIRECTORY(ITMLib)
ADD_SUBDIRECTORY(MiniSlamGraphLib)
ADD_SUBDIRECTORY(ORUtils)

################################
# Uninstall any installed file #
################################

INCLUDE(${CMAKE_SOURCE_DIR}/cmake/SetUninstallTarget.cmake)
2 changes: 2 additions & 0 deletions InfiniTAM/cmake/SetCUDALibTarget.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,5 @@ IF(WITH_CUDA)
ELSE()
ADD_LIBRARY(${targetname} STATIC ${sources} ${headers} ${templates})
ENDIF()

INCLUDE(${CMAKE_SOURCE_DIR}/cmake/SetInstallTarget.cmake)
11 changes: 11 additions & 0 deletions InfiniTAM/cmake/SetInstallTarget.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
##########################
# SetInstallTarget.cmake #
##########################

#install target
INSTALL(TARGETS ${targetname}
DESTINATION lib/InfiniTAM/${targetname})
#install headers of target
INSTALL(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/. DESTINATION include/InfiniTAM/${targetname}
FILES_MATCHING REGEX "^.*\\.(h|hpp)$"
)
2 changes: 2 additions & 0 deletions InfiniTAM/cmake/SetLibTarget.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,5 @@
INCLUDE(${PROJECT_SOURCE_DIR}/cmake/Flags.cmake)

ADD_LIBRARY(${targetname} STATIC ${sources} ${headers} ${templates})

INCLUDE(${CMAKE_SOURCE_DIR}/cmake/SetInstallTarget.cmake)
12 changes: 12 additions & 0 deletions InfiniTAM/cmake/SetUninstallTarget.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
############################
# SetUninstallTarget.cmake #
############################

# uninstall target
CONFIGURE_FILE(
"${CMAKE_CURRENT_SOURCE_DIR}/cmake/cmake_uninstall.cmake.in"
"${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake"
IMMEDIATE @ONLY)

ADD_CUSTOM_TARGET(uninstall
COMMAND ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake)
26 changes: 26 additions & 0 deletions InfiniTAM/cmake/cmake_uninstall.cmake.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
#############################
## cmake_uninstall.cmake.in #
## Sourced from https://cmake.org/Wiki/CMake_FAQ#Can_I_do_.22make_uninstall.22_with_CMake.3F
#############################

IF(NOT EXISTS "@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt")
MESSAGE(FATAL_ERROR "Cannot find install manifest: @CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt")
ENDIF(NOT EXISTS "@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt")

FILE(READ "@CMAKE_CURRENT_BINARY_DIR@/install_manifest.txt" files)
STRING(REGEX REPLACE "\n" ";" files "${files}")
FOREACH(file ${files})
MESSAGE(STATUS "Uninstalling $ENV{DESTDIR}${file}")
IF(IS_SYMLINK "$ENV{DESTDIR}${file}" OR EXISTS "$ENV{DESTDIR}${file}")
EXEC_PROGRAM(
"@CMAKE_COMMAND@" ARGS "-E remove \"$ENV{DESTDIR}${file}\""
OUTPUT_VARIABLE rm_out
RETURN_VALUE rm_retval
)
IF(NOT "${rm_retval}" STREQUAL 0)
MESSAGE(FATAL_ERROR "Problem when removing $ENV{DESTDIR}${file}")
ENDIF(NOT "${rm_retval}" STREQUAL 0)
ELSE(IS_SYMLINK "$ENV{DESTDIR}${file}" OR EXISTS "$ENV{DESTDIR}${file}")
MESSAGE(STATUS "File $ENV{DESTDIR}${file} does not exist.")
ENDIF(IS_SYMLINK "$ENV{DESTDIR}${file}" OR EXISTS "$ENV{DESTDIR}${file}")
ENDFOREACH(file)
17 changes: 13 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ This is the main branch of the software bundle "InfiniTAM", the current version
Stuart Golodetz <[email protected]>
Michael Sapienza <[email protected]>
Tommaso Cavallari <[email protected]>

Previous maintainers and contributors are:

Carl Yuheng Ren <[email protected]>
Expand All @@ -17,7 +17,7 @@ Previous maintainers and contributors are:
Ian D Reid <[email protected]>
David W Murray <[email protected]>

For more information about InfiniTAM please visit the project website <http://www.infinitam.org>.
For more information about InfiniTAM please visit the project website <http://www.infinitam.org>.

Other related projects can be found in the Oxford Active Vision Library <http://www.oxvisionlib.org>.

Expand Down Expand Up @@ -76,6 +76,15 @@ Several 3rd party libraries are needed for compiling InfiniTAM. The given versio
$ cd build
$ cmake /path/to/InfiniTAM -DOPEN_NI_ROOT=/path/to/OpenNI2/
$ make
```
To install the libraries to a custom location on your system, compile with:
```
$ cmake /path/to/InfiniTAM -DOPEN_NI_ROOT=/path/to/OpenNI2/ -DCMAKE_PREFIX_PATH=/path/to/install/libs
$ make install
```
You can uninstall the libraries with:
```
$ make uninstall
```
To create a doxygen documentation, just run doxygen:
```
Expand All @@ -90,7 +99,7 @@ Padding the data structure ITMVoxel in ITMLibDefines.h with one extra byte may o

On Mac OS X 10.9 there are currently some issues with libc++ vs. libstdc++ in conjunction with CUDA. They eventually manifest in error messages like:
```
Undefined symbols for architecture x86_64:
Undefined symbols for architecture x86_64:
"std::ios_base::Init::Init()", referenced from:
__GLOBAL__I_a in libITMLib.a(ITMLib_generated_ITMColorTracker_CUDA.cu.o)
__GLOBAL__I_a in libITMLib.a(ITMLib_generated_ITMDepthTracker_CUDA.cu.o)
Expand Down Expand Up @@ -146,7 +155,7 @@ author = {{K{\"a}hler}, O. and
{Torr}, P.~H.~S and
{Murray}, D.~W.},
title = "{Very High Frame Rate Volumetric Integration of Depth Images on Mobile Device}",
journal = "{IEEE Transactions on Visualization and Computer Graphics
journal = "{IEEE Transactions on Visualization and Computer Graphics
(Proceedings International Symposium on Mixed and Augmented Reality 2015}",
volume = {22},
number = {11},
Expand Down