Skip to content

Commit 93ebe03

Browse files
Remove btk references (opensim-org#3280)
* Removed BTK from opensim-core. * Merge branch 'opensim-org:master' into remove-btk-references * Merge branch 'opensim-org:master' into remove-btk-references * Merge branch 'opensim-org:master' into remove-btk-references * Removed block of code that only was executed with BTK. * Updated CHANGELOG.md * Merge branch 'master' into remove-btk-references * Update CHANGELOG.md
1 parent e2eee06 commit 93ebe03

21 files changed

+41
-385
lines changed

Bindings/CMakeLists.txt

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,6 @@ if(BUILD_PYTHON_WRAPPING OR BUILD_JAVA_WRAPPING)
33
endif()
44

55
# Flags are both Python and Java bindings will use.
6-
if(WITH_BTK)
7-
set(SWIG_FLAGS "-DWITH_BTK")
8-
endif()
96
if(WITH_EZC3D)
107
set(SWIG_FLAGS "-DWITH_EZC3D")
118
endif()

Bindings/Java/Matlab/tests/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ OpenSimAddMatlabTest(AccessSubcomponents testAccessSubcomponents.m)
9292
OpenSimAddMatlabTest(Simbody testSimbody.m)
9393
OpenSimAddMatlabTest(osimTableStruct testosimTableStruct.m)
9494
OpenSimAddMatlabTest(testOsimVec3 testOsimVec3.m)
95-
if(WITH_BTK OR WITH_EZC3D)
95+
if(WITH_EZC3D)
9696
OpenSimAddMatlabTest(testOsimC3D testOsimC3D.m)
9797
endif()
9898
OpenSimAddMatlabTest(testOsimList2MatlabCell testOsimList2MatlabCell.m)

Bindings/Java/tests/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ OpenSimAddJavaTest(TestTables)
143143
OpenSimAddJavaTest(TestModelBuilding)
144144
OpenSimAddJavaTest(TestEditMarkers)
145145
OpenSimAddJavaTest(TestIKInterfaces)
146-
if(WITH_BTK OR WITH_EZC3D)
146+
if(WITH_EZC3D)
147147
OpenSimAddJavaTest(TestC3DFileAdapter)
148148
endif()
149149
OpenSimAddJavaTest(TestReporter)

Bindings/common.i

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -420,7 +420,7 @@ namespace OpenSim {
420420
%include <OpenSim/Common/CSVFileAdapter.h>
421421
%include <OpenSim/Common/XsensDataReader.h>
422422

423-
#if defined WITH_EZC3D || defined (WITH_BTK)
423+
#if defined (WITH_EZC3D)
424424
%include <OpenSim/Common/C3DFileAdapter.h>
425425

426426
%extend OpenSim::C3DFileAdapter {

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ v4.4.1
1111

1212
- Made `Component::getSocketNames` a `const` member method (previously: non-const)
1313
- Modifed the swig interface files to make OpenSim::PathPointSet adopt new PathPoints inserted into it. (Issue #3276)
14+
- Remove references to obsoleted dependency BTK, use ezc3d exclusively.
1415
- Fixed an issue with IPOPT libraries when building OpenSim with `OPENSIM_WITH_CASADI = ON` but `OPENSIM_WITH_TROPTER = OFF` (Issue #3267).
1516

1617
v4.4

CMakeLists.txt

Lines changed: 6 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ from the internet, we turn this option OFF." ON)
135135
set(SIMBODY_HOME $ENV{SIMBODY_HOME} CACHE
136136
PATH "The location of the Simbody installation to use; you can change this. Set as empty to let CMake search for Simbody automatically.")
137137

138-
option(OPENSIM_COPY_DEPENDENCIES "Copy Simbody, ezc3d and BTK into the
138+
option(OPENSIM_COPY_DEPENDENCIES "Copy Simbody and ezc3d into the
139139
OpenSim installation. This should be set to ON when making a relocatable
140140
distribution, and should be set to OFF when packaging for Homebrew, Debian,
141141
etc. On Linux and macOS: we use relative RPATHs when ON, and absolute RPATHs
@@ -144,7 +144,7 @@ BUILD_PYTHON_WRAPPING is ON, so if this OFF, a warning is thrown." ON)
144144
mark_as_advanced(OPENSIM_COPY_DEPENDENCIES)
145145

146146
option(OPENSIM_PYTHON_STANDALONE "Make the Python package standalone, meaning
147-
the OpenSim (and Simbody, ezc3d and BTK) shared libraries it depends on are copied
147+
the OpenSim (and Simbody and ezc3d) shared libraries it depends on are copied
148148
into the package. If you are building OpenSim on the same machine on which you
149149
plan to use it, you can leave this OFF. If you are distributing OpenSim to
150150
other computers, you should turn this ON. If macOS, this option affects how
@@ -640,9 +640,9 @@ if(UNIX) # Linux and macOS
640640
# Add the automatically determined parts of the RPATH which point
641641
# to directories outside the build tree to the install RPATH.
642642
# If we are copying Simbody into OpenSim's installation, then
643-
# there's no need to link to the libraries in Simbody's, ezc3d's or BTK's
643+
# there's no need to link to the libraries in Simbody's or ezc3d's
644644
# original installations. Furthermore, we may be distributing OpenSim
645-
# to other computers that will not have our original Simbody, ezc3d or BTK
645+
# to other computers that will not have our original Simbody or ezc3d
646646
# installations, and so the RPATH would point to a nonexistant
647647
# directory on others' computers.
648648
set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE)
@@ -696,11 +696,10 @@ endif()
696696

697697

698698
set(OPENSIM_C3D_PARSER None CACHE STRING
699-
"Compile OpenSim with a C3D parser ? ezc3d or BTK provide C3D reading.")
700-
set_property(CACHE OPENSIM_C3D_PARSER PROPERTY STRINGS "ezc3d" "BTK" "None")
699+
"Compile OpenSim with a C3D parser ? ezc3d provide C3D reading.")
700+
set_property(CACHE OPENSIM_C3D_PARSER PROPERTY STRINGS "ezc3d" "None")
701701
if(${OPENSIM_C3D_PARSER} STREQUAL "ezc3d")
702702
set(WITH_EZC3D true)
703-
set(WITH_BTK false)
704703
set(ezc3d_hint "${OPENSIM_DEPENDENCIES_DIR}/ezc3d/lib/cmake/ezc3d")
705704
find_package(ezc3d REQUIRED HINTS "${ezc3d_hint}")
706705
add_definitions(-DWITH_EZC3D)
@@ -716,32 +715,12 @@ if(${OPENSIM_C3D_PARSER} STREQUAL "ezc3d")
716715
OpenSimInstallDependencyLibraries(ezc3d "${ezc3d_DIR}/../../../bin"
717716
"${ezc3d_DIR}/../../../lib" "${OPENSIM_INSTALL_PYTHONDIR}/opensim")
718717
endif()
719-
elseif(${OPENSIM_C3D_PARSER} STREQUAL "BTK")
720-
set(WITH_EZC3D false)
721-
unset(ezc3d_LIBRARY_DIR CACHE)
722-
unset(ezc3d_LIBRARY)
723-
unset(ezc3d_INCLUDE_DIR CACHE)
724-
set(WITH_BTK true)
725-
726-
# If compiling with BTK, find and use it.
727-
find_package(BTK
728-
REQUIRED
729-
HINTS "${OPENSIM_DEPENDENCIES_DIR}/BTK/share/btk-0.4dev")
730-
include(${BTK_USE_FILE})
731-
add_definitions(-DWITH_BTK)
732-
OpenSimCopyDependencyDLLsForWin(DEP_NAME BTK
733-
DEP_BIN_DIR ${BTK_INSTALL_PREFIX}/bin)
734-
if(BUILD_PYTHON_WRAPPING AND OPENSIM_PYTHON_STANDALONE)
735-
OpenSimInstallDependencyLibraries(BTK "${BTK_INSTALL_PREFIX}"
736-
"${BTK_LIBRARY_DIRS}" "${OPENSIM_INSTALL_PYTHONDIR}/opensim")
737-
endif()
738718

739719
else()
740720
set(WITH_EZC3D false)
741721
unset(ezc3d_LIBRARY_DIR CACHE)
742722
unset(ezc3d_LIBRARY)
743723
unset(ezc3d_INCLUDE_DIR CACHE)
744-
set(WITH_BTK false)
745724
endif()
746725

747726
find_package(spdlog REQUIRED
@@ -956,15 +935,6 @@ if(${OPENSIM_COPY_DEPENDENCIES})
956935
DESTINATION "${CMAKE_INSTALL_LIBDIR}")
957936
endif()
958937

959-
# BTK
960-
# ---
961-
if(NOT WIN32)
962-
# LIB: .so files on Linux, .dylib on macOS
963-
file(GLOB btk_desired_lib_files "${BTK_LIBRARY_DIRS}/*BTK*")
964-
install(FILES ${btk_desired_lib_files}
965-
DESTINATION "${CMAKE_INSTALL_LIBDIR}")
966-
endif()
967-
968938
# spdlog
969939
# ------
970940
install(DIRECTORY "${spdlog_DIR}/../../../"

DEVELOPING.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ documentation online.
7474
7575
The layout of the distribution on Windows is as follows:
7676
77-
- `bin/` OpenSim, SimTK, and BTK DLLs, opensim-cmd.exe, simbody-visualizer.exe
77+
- `bin/` OpenSim and SimTK DLLs, opensim-cmd.exe, simbody-visualizer.exe
7878
- `cmake/` OpenSimConfig.cmake, etc.
7979
- `sdk/`
8080
- `APIExamples/`: C++ examples.
@@ -99,7 +99,7 @@ if `OPENSIM_INSTALL_UNIX_FHS` is `ON`, as follows:
9999
- `include/`
100100
- `OpenSim/` OpenSim (and Lepton) headers.
101101
- `simbody/` Simbody headers.
102-
- `lib/` (on some Linux variants, `lib/<arch>/`) OpenSim, SimTK, and BTK shared libraries.
102+
- `lib/` (on some Linux variants, `lib/<arch>/`) OpenSim and SimTK shared libraries.
103103
- `cmake/` OpenSimConfig.cmake, SimbodyConfig.cmake, etc.
104104
- `python2.7/site-packages/` OpenSim Python bindings.
105105
- `libexec/simbody/simbody-visualizer`
@@ -151,7 +151,7 @@ interchangeably.
151151
152152
There are two types of dependencies: public, or those exposed through OpenSim's
153153
API (e.g., Simbody), and private, or those used internally by OpenSim
154-
(e.g., BTK and ezc3d):
154+
(e.g., ezc3d):
155155
156156
- **private**: OpenSim's binary distribution need only contain the
157157
dependency's dynamic libraries.

OpenSim/Common/Adapters.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
#include "STOFileAdapter.h"
2828
#include "CSVFileAdapter.h"
2929

30-
#if defined (WITH_EZC3D) || defined (WITH_BTK)
30+
#if defined (WITH_EZC3D)
3131

3232
#include "C3DFileAdapter.h"
3333

0 commit comments

Comments
 (0)